dify/web/app/components/education-verify-action-recorder.tsx
2026-06-19 13:51:45 +00:00

19 lines
613 B
TypeScript

'use client'
import { useEffect } from 'react'
import { EDUCATION_VERIFY_URL_SEARCHPARAMS_ACTION } from '@/app/education-apply/constants'
import { useSetEducationVerifying } from '@/app/education-apply/storage'
import { useSearchParams } from '@/next/navigation'
export function EducationVerifyActionRecorder() {
const searchParams = useSearchParams()
const setEducationVerifying = useSetEducationVerifying()
useEffect(() => {
if (searchParams.get('action') === EDUCATION_VERIFY_URL_SEARCHPARAMS_ACTION)
setEducationVerifying('yes')
}, [searchParams, setEducationVerifying])
return null
}