{"version":3,"file":"TryForFree-BX8S6UFW.js","sources":["../../../../../../../../app/frontend/features/TryForFreeButton/ui/TryForFree.tsx"],"sourcesContent":["import { t } from 'i18next'\nimport { useMemo } from 'react'\n\nimport { COMPONENTS } from '~/shared/constants/pages'\nimport { cn } from '~/shared/lib/utils'\nimport { useAppLanding, useAppSelector } from '~/shared/models/hooks'\nimport Link from '~/shared/ui/Link'\n\ntype TryForFreeButtonType = {\n callback?: () => void\n link?: string\n isLoggedIn?: boolean\n className?: string\n text?: string\n}\n\nconst TryForFreeButton = ({\n text = '',\n isLoggedIn = false,\n className = '',\n link = '',\n callback,\n}: TryForFreeButtonType) => {\n const activePage = useAppSelector((state) => state.common.activePage)\n\n const isLoginPage = useMemo(\n () => activePage === COMPONENTS.App.location || activePage === COMPONENTS.App.root,\n [activePage]\n )\n const { isRestrictedPrimaryLogoPage } = useAppLanding()\n\n return (\n \n {text || t('global.buttons.try_for_free')}\n \n )\n}\n\nexport default TryForFreeButton\n"],"names":["TryForFreeButton","text","isLoggedIn","className","link","callback","activePage","useAppSelector","state","isLoginPage","useMemo","COMPONENTS","isRestrictedPrimaryLogoPage","useAppLanding","jsx","Link","cn","t"],"mappings":"2cAgBA,MAAMA,EAAmB,CAAC,CACxB,KAAAC,EAAO,GACP,WAAAC,EAAa,GACb,UAAAC,EAAY,GACZ,KAAAC,EAAO,GACP,SAAAC,CACF,IAA4B,CAC1B,MAAMC,EAAaC,EAAgBC,GAAUA,EAAM,OAAO,UAAU,EAE9DC,EAAcC,EAAA,QAClB,IAAMJ,IAAeK,EAAW,IAAI,UAAYL,IAAeK,EAAW,IAAI,KAC9E,CAACL,CAAU,CAAA,EAEP,CAAE,4BAAAM,GAAgCC,IAGtC,OAAAC,EAAA,IAACC,EAAA,CACC,KAAMX,GAAQ,OACd,QAASC,EACT,UAAWW,EACT,4IACAb,EACCS,EAA6C,GAAf,aAC/BV,GAAcO,EAAc,SAAW,EACzC,EAEC,SAAAR,GAAQgB,EAAE,6BAA6B,CAAA,CAAA,CAG9C"}