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,QAAU,CAAC,UAAY,+BAA+B,aAAe,kCAAkC,iBAAmB,wC,kBCAjID,EAAOC,QAAU,CAAC,OAAS,6BAA6B,QAAU,8BAA8B,SAAW","sources":["webpack://_N_E/./node_modules/next-translate/lib/esm/formatElements.js","webpack://_N_E/./node_modules/next-translate/lib/esm/Trans.js","webpack://_N_E/./src/components/Auth/Consents/ConsentBody/index.tsx","webpack://_N_E/./src/components/Auth/Consents/ConsentModal/index.tsx","webpack://_N_E/./src/components/Auth/Consents/ConsentBody/ConsentBody.module.scss","webpack://_N_E/./src/components/Auth/Consents/ConsentModal/ConsentModal.module.scss"],"sourcesContent":["import React, { cloneElement, Fragment } from 'react';\nvar tagRe = /<(\\w+)>(.*?)<\\/\\1>|<(\\w+)\\/>/;\nvar nlRe = /(?:\\r\\n|\\r|\\n)/g;\nfunction getElements(parts) {\n if (!parts.length)\n return [];\n var _a = parts.slice(0, 4), paired = _a[0], children = _a[1], unpaired = _a[2], after = _a[3];\n return [\n [(paired || unpaired), children || '', after],\n ].concat(getElements(parts.slice(4, parts.length)));\n}\nexport default function formatElements(value, elements) {\n if (elements === void 0) { elements = []; }\n var parts = value.replace(nlRe, '').split(tagRe);\n if (parts.length === 1)\n return value;\n var tree = [];\n var before = parts.shift();\n if (before)\n tree.push(before);\n getElements(parts).forEach(function (_a, realIndex) {\n var key = _a[0], children = _a[1], after = _a[2];\n var element = elements[key] || React.createElement(Fragment, null);\n tree.push(cloneElement(element, { key: realIndex }, children ? formatElements(children, elements) : element.props.children));\n if (after)\n tree.push(after);\n });\n return tree;\n}\n","import { useMemo } from 'react';\nimport useTranslation from './useTranslation';\nimport formatElements from './formatElements';\nexport default function Trans(_a) {\n var i18nKey = _a.i18nKey, values = _a.values, components = _a.components, fallback = _a.fallback, defaultTrans = _a.defaultTrans, ns = _a.ns;\n var _b = useTranslation(ns), t = _b.t, lang = _b.lang;\n var result = useMemo(function () {\n var text = t(i18nKey, values, { fallback: fallback, default: defaultTrans });\n if (!components || components.length === 0)\n return text;\n return formatElements(text, components);\n }, [i18nKey, values, components, lang]);\n return result;\n}\n","import React from 'react';\n\nimport useTranslation from 'next-translate/useTranslation';\n\nimport styles from './ConsentBody.module.scss';\n\nimport Button, { ButtonType } from '@/dls/Button/Button';\n\ntype Props = {\n children: React.ReactNode;\n isLoading?: boolean;\n onButtonClicked: (consented: boolean) => void;\n};\n\nconst ConsentBody: React.FC<Props> = ({ children, isLoading = false, onButtonClicked }) => {\n const { t } = useTranslation('common');\n return (\n <div className={styles.container}>\n {children}\n <div className={styles.buttonsContainer}>\n <Button\n isDisabled={isLoading}\n isLoading={isLoading}\n onClick={() => {\n onButtonClicked(true);\n }}\n type={ButtonType.Primary}\n className={styles.submitButton}\n >\n {t('allow')}\n </Button>\n <Button\n isDisabled={isLoading}\n isLoading={isLoading}\n onClick={() => {\n onButtonClicked(false);\n }}\n type={ButtonType.Secondary}\n className={styles.submitButton}\n >\n {t('not-now')}\n </Button>\n </div>\n </div>\n );\n};\n\nexport default ConsentBody;\n","import React from 'react';\n\nimport Trans from 'next-translate/Trans';\n\nimport ConsentBody from '../ConsentBody';\n\nimport styles from './ConsentModal.module.scss';\n\nimport ConsentType from '@/types/auth/ConsentType';\nimport { logButtonClick } from '@/utils/eventLogger';\n\ntype Props = {\n consentType: ConsentType;\n isLoading: boolean;\n onCompleted: (consentType: ConsentType, consented: boolean) => void;\n};\n\nconst ConsentModal: React.FC<Props> = ({ onCompleted, consentType, isLoading }) => {\n const onButtonClicked = (consented: boolean) => {\n logButtonClick(`${consentType}_${consentType}`);\n onCompleted(consentType, consented);\n };\n\n return (\n <ConsentBody onButtonClicked={onButtonClicked} isLoading={isLoading}>\n <p className={styles.header}>\n <Trans\n components={{ boldSpan: <span key={0} className={styles.boldSpan} /> }}\n i18nKey={`common:consents.${consentType}.header`}\n />\n </p>\n <Trans\n components={{\n br: <br key={0} />,\n boldSpan: <span key={1} className={styles.boldSpan} />,\n }}\n i18nKey={`common:consents.${consentType}.body`}\n />\n </ConsentBody>\n );\n};\n\nexport default ConsentModal;\n","// extracted by mini-css-extract-plugin\nmodule.exports = {\"container\":\"ConsentBody_container__2tilb\",\"submitButton\":\"ConsentBody_submitButton___FDKe\",\"buttonsContainer\":\"ConsentBody_buttonsContainer__MmEPO\"};","// extracted by mini-css-extract-plugin\nmodule.exports = {\"header\":\"ConsentModal_header__KvKFy\",\"section\":\"ConsentModal_section__elTDE\",\"boldSpan\":\"ConsentModal_boldSpan__zjwWk\"};"],"names":["tagRe","nlRe","getElements","parts","length","_a","slice","paired","children","unpaired","concat","formatElements","value","elements","replace","split","tree","before","shift","push","forEach","realIndex","key","after","element","Fragment","cloneElement","props","Trans","i18nKey","values","components","fallback","defaultTrans","ns","_b","useTranslation","t","lang","useMemo","text","default","isLoading","onButtonClicked","div","className","styles","Button","isDisabled","onClick","type","ButtonType","onCompleted","consentType","ConsentBody","consented","logButtonClick","p","boldSpan","span","br","module","exports"],"sourceRoot":""}