@bigbinary/neeto-thank-you-frontend 3.1.8 → 3.1.10

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (102) hide show
  1. package/README.md +0 -2
  2. package/dist/.ready +1 -0
  3. package/dist/BrandingInfo-C-YUyKe_.js +17 -0
  4. package/dist/BrandingInfo-C-YUyKe_.js.map +1 -0
  5. package/dist/ConfigureThankYou.js +4 -5
  6. package/dist/ConfigureThankYou.js.map +1 -1
  7. package/dist/ShowThankYou.js +2 -1
  8. package/dist/ShowThankYou.js.map +1 -1
  9. package/dist/SocialShare-B0luKbFP.js +93 -0
  10. package/dist/SocialShare-B0luKbFP.js.map +1 -0
  11. package/dist/SocialShare-Djluum5G.js +93 -0
  12. package/dist/SocialShare-Djluum5G.js.map +1 -0
  13. package/dist/application-DJ9yVgd0.js +5 -0
  14. package/dist/application-DJ9yVgd0.js.map +1 -0
  15. package/dist/cjs/BrandingInfo-CxPUChPj.js +19 -0
  16. package/dist/cjs/BrandingInfo-CxPUChPj.js.map +1 -0
  17. package/dist/cjs/ConfigureThankYou.js +3 -4
  18. package/dist/cjs/ConfigureThankYou.js.map +1 -1
  19. package/dist/cjs/ShowThankYou.js +2 -1
  20. package/dist/cjs/ShowThankYou.js.map +1 -1
  21. package/dist/cjs/SocialShare-BFeAkgVT.js +100 -0
  22. package/dist/cjs/SocialShare-BFeAkgVT.js.map +1 -0
  23. package/dist/cjs/SocialShare-CVIbFf_m.js +100 -0
  24. package/dist/cjs/SocialShare-CVIbFf_m.js.map +1 -0
  25. package/dist/cjs/application-S-s0L8VC.js +7 -0
  26. package/dist/cjs/application-S-s0L8VC.js.map +1 -0
  27. package/dist/cjs/constants.js +1 -1
  28. package/dist/cjs/constants.js.map +1 -1
  29. package/dist/cjs/index.js +9 -7
  30. package/dist/{SocialShare-C4rOGmnp.js → cjs/thank-you-BAOIUbgZ.js} +3 -92
  31. package/dist/cjs/thank-you-BAOIUbgZ.js.map +1 -0
  32. package/dist/cjs/thank-you-BYHzj8zD.js +7 -0
  33. package/dist/cjs/thank-you-BYHzj8zD.js.map +1 -0
  34. package/dist/cjs/v2/ConfigureThankYou.js +698 -0
  35. package/dist/cjs/v2/ConfigureThankYou.js.map +1 -0
  36. package/dist/cjs/v2/ShowThankYou.js +281 -0
  37. package/dist/cjs/v2/ShowThankYou.js.map +1 -0
  38. package/dist/cjs/v2/commons.js +10 -0
  39. package/dist/cjs/v2/commons.js.map +1 -0
  40. package/dist/cjs/v2/constants.js +12 -0
  41. package/dist/cjs/v2/constants.js.map +1 -0
  42. package/dist/cjs/v2/index.js +58 -0
  43. package/dist/cjs/v2/index.js.map +1 -0
  44. package/dist/cjs/v2/query.js +8 -0
  45. package/dist/cjs/v2/query.js.map +1 -0
  46. package/dist/cjs/v2/useCreateThankYouConfiguration.js +16 -0
  47. package/dist/cjs/v2/useCreateThankYouConfiguration.js.map +1 -0
  48. package/dist/cjs/v2/useDeleteThankYouConfiguration.js +16 -0
  49. package/dist/cjs/v2/useDeleteThankYouConfiguration.js.map +1 -0
  50. package/dist/cjs/v2/useFetchThankYouConfigurations.js +16 -0
  51. package/dist/cjs/v2/useFetchThankYouConfigurations.js.map +1 -0
  52. package/dist/cjs/v2/useShowThankYouConfiguration.js +16 -0
  53. package/dist/cjs/v2/useShowThankYouConfiguration.js.map +1 -0
  54. package/dist/cjs/v2/useShowThankYouPage.js +12 -0
  55. package/dist/cjs/v2/useShowThankYouPage.js.map +1 -0
  56. package/dist/cjs/v2/useUpdateThankYouConfiguration.js +16 -0
  57. package/dist/cjs/v2/useUpdateThankYouConfiguration.js.map +1 -0
  58. package/dist/cjs/v2/utils.js +3 -0
  59. package/dist/cjs/v2/utils.js.map +1 -0
  60. package/dist/constants.js +1 -1
  61. package/dist/constants.js.map +1 -1
  62. package/dist/index.js +9 -9
  63. package/dist/thank-you-B9agG0DC.js +5 -0
  64. package/dist/thank-you-B9agG0DC.js.map +1 -0
  65. package/dist/{cjs/SocialShare-abuXAsLb.js → thank-you-CtNe3oCq.js} +2 -101
  66. package/dist/thank-you-CtNe3oCq.js.map +1 -0
  67. package/dist/useCreateThankYouConfiguration.js +1 -1
  68. package/dist/useDeleteThankYouConfiguration.js +1 -1
  69. package/dist/useFetchThankYouConfigurations.js +1 -1
  70. package/dist/useShowThankYouConfiguration.js +1 -1
  71. package/dist/{useThankYouConfigurationApi-DSQ3IBbq.js → useThankYouConfigurationApi-CCdlqC6e.js} +2 -2
  72. package/dist/{useThankYouConfigurationApi-DSQ3IBbq.js.map → useThankYouConfigurationApi-CCdlqC6e.js.map} +1 -1
  73. package/dist/useUpdateThankYouConfiguration.js +1 -1
  74. package/dist/v2/ConfigureThankYou.js +677 -0
  75. package/dist/v2/ConfigureThankYou.js.map +1 -0
  76. package/dist/v2/ShowThankYou.js +279 -0
  77. package/dist/v2/ShowThankYou.js.map +1 -0
  78. package/dist/v2/commons.js +4 -0
  79. package/dist/v2/commons.js.map +1 -0
  80. package/dist/v2/constants.js +9 -0
  81. package/dist/v2/constants.js.map +1 -0
  82. package/dist/v2/index.js +45 -0
  83. package/dist/v2/index.js.map +1 -0
  84. package/dist/v2/query.js +2 -0
  85. package/dist/v2/query.js.map +1 -0
  86. package/dist/v2/useCreateThankYouConfiguration.js +10 -0
  87. package/dist/v2/useCreateThankYouConfiguration.js.map +1 -0
  88. package/dist/v2/useDeleteThankYouConfiguration.js +10 -0
  89. package/dist/v2/useDeleteThankYouConfiguration.js.map +1 -0
  90. package/dist/v2/useFetchThankYouConfigurations.js +10 -0
  91. package/dist/v2/useFetchThankYouConfigurations.js.map +1 -0
  92. package/dist/v2/useShowThankYouConfiguration.js +10 -0
  93. package/dist/v2/useShowThankYouConfiguration.js.map +1 -0
  94. package/dist/v2/useShowThankYouPage.js +6 -0
  95. package/dist/v2/useShowThankYouPage.js.map +1 -0
  96. package/dist/v2/useUpdateThankYouConfiguration.js +10 -0
  97. package/dist/v2/useUpdateThankYouConfiguration.js.map +1 -0
  98. package/dist/v2/utils.js +2 -0
  99. package/dist/v2/utils.js.map +1 -0
  100. package/package.json +43 -33
  101. package/dist/SocialShare-C4rOGmnp.js.map +0 -1
  102. package/dist/cjs/SocialShare-abuXAsLb.js.map +0 -1
@@ -1 +1 @@
1
- {"version":3,"file":"ShowThankYou.js","sources":["../../app/javascript/src/components/ShowThankYou/utils.js","../../app/javascript/src/components/ShowThankYou/CustomMessage.jsx","../../app/javascript/src/components/ShowThankYou/ExternalLink.jsx","../../app/javascript/src/components/ShowThankYou/index.jsx"],"sourcesContent":["import DOMPurify from \"dompurify\";\nimport { findBy } from \"neetocist\";\n\nimport { VARIABLE_SPAN_REGEX } from \"components/constants\";\n\nexport const buildDraftUrl = url => `${url}?draftPreview=true`;\n\nexport const getSafeURL = url => {\n try {\n const parsed = new URL(url);\n if (parsed.protocol !== \"https:\" && parsed.protocol !== \"http:\") {\n return undefined;\n }\n\n return DOMPurify.sanitize(url);\n } catch {\n return undefined;\n }\n};\n\nexport const substituteVariables = (highlightedContent = \"\", variables = []) =>\n highlightedContent.replace(VARIABLE_SPAN_REGEX, (matchedSpan, dataLabel) => {\n const dataLabelSplitted = dataLabel.split(\".\");\n\n if (dataLabelSplitted.length > 1) {\n const category = findBy({ category: dataLabelSplitted[0] }, variables);\n const variable = findBy(\n { key: dataLabelSplitted[1] },\n category?.variables || []\n );\n\n return variable?.value ? variable.value : matchedSpan;\n }\n\n const variable = findBy({ key: dataLabelSplitted[0] }, variables);\n\n return variable?.value ? variable.value : matchedSpan;\n });\n","import { memo } from \"react\";\n\nimport { isPresent } from \"neetocist\";\nimport { EditorContent } from \"neetoeditor\";\nimport { useTranslation } from \"react-i18next\";\n\nimport CallToAction from \"components/commons/CallToAction\";\nimport SocialShare from \"components/ConfigureThankYou/Customize/SocialShare\";\n\nimport { buildDraftUrl, substituteVariables } from \"./utils\";\n\nconst MemoizedEditorContent = memo(EditorContent);\n\nconst CustomMessage = ({\n isDraftPreview,\n publicLinkId,\n resubmitLink,\n socialHandles,\n thankYouConfiguration,\n editorProps,\n appName,\n ctaProps = {},\n}) => {\n const { t } = useTranslation();\n\n const message = substituteVariables(\n thankYouConfiguration?.message,\n editorProps.variables\n );\n\n return (\n <>\n {thankYouConfiguration?.message && (\n <div className=\"neeto-thank-you-configuration__description neeto-ui-text-gray-800\">\n <MemoizedEditorContent\n content={message}\n data-testid=\"thank-you-page-message\"\n {...editorProps}\n />\n </div>\n )}\n {thankYouConfiguration?.showResubmitLink && (\n <a\n className=\"neeto-thank-you-configuration__resubmit\"\n data-testid=\"thank-you-page-resubmit-link\"\n href={isDraftPreview ? buildDraftUrl(resubmitLink) : resubmitLink}\n >\n {thankYouConfiguration?.resubmitLinkText ??\n t(\"neetoThankYou.common.resubmit\")}\n </a>\n )}\n {thankYouConfiguration?.socialSharingEnabled && (\n <SocialShare {...{ publicLinkId, socialHandles }} />\n )}\n {isDraftPreview && (\n <p className=\"neeto-thank-you-configuration__draft-preview-message\">\n {t(\"neetoThankYou.thankYou.draftVersionForm\")}\n </p>\n )}\n {isPresent(ctaProps) && <CallToAction {...{ appName, ...ctaProps }} />}\n </>\n );\n};\n\nexport default CustomMessage;\n","import { useEffect, useState, memo } from \"react\";\n\nimport { isPresent, filterNonNull } from \"neetocist\";\nimport { EditorContent } from \"neetoeditor\";\nimport { dec, toPairs } from \"ramda\";\nimport { Trans, useTranslation } from \"react-i18next\";\n\nimport CallToAction from \"components/commons/CallToAction\";\nimport { REDIRECT_DELAY } from \"components/commons/constants\";\n\nimport { getSafeURL, substituteVariables } from \"./utils\";\n\nconst MemoizedEditorContent = memo(EditorContent);\n\nconst ExternalLink = ({\n thankYouConfiguration = {},\n editorProps,\n enableTopLevelRedirect,\n eventDetails,\n appName,\n ctaProps = {},\n}) => {\n const [countdown, setCountdown] = useState(REDIRECT_DELAY);\n const [isUnableToRedirect, setIsUnableToRedirect] = useState(false);\n\n const { t } = useTranslation();\n\n const {\n redirectUrl = \"\",\n redirectMessage = \"\",\n passEventDetailsToRedirectUrl = false,\n } = thankYouConfiguration;\n const message = substituteVariables(redirectMessage, editorProps.variables);\n const redirectFailureAnchorProps = enableTopLevelRedirect\n ? { target: \"_top\", rel: \"noreferrer\" }\n : {};\n\n const buildRedirectUrlWithParams = () => {\n try {\n const redirectUrlWithParams = new URL(redirectUrl);\n\n if (passEventDetailsToRedirectUrl && isPresent(eventDetails)) {\n toPairs(filterNonNull(eventDetails)).forEach(([key, value]) => {\n redirectUrlWithParams.searchParams.set(key, value);\n });\n }\n\n return redirectUrlWithParams.toString();\n } catch {\n return redirectUrl;\n }\n };\n\n useEffect(() => {\n if (countdown === 0) {\n try {\n const redirectUrlWithParams = buildRedirectUrlWithParams();\n const redirectTarget = enableTopLevelRedirect\n ? window.top.location\n : window.location;\n\n redirectTarget.href = getSafeURL(redirectUrlWithParams);\n } catch {\n setIsUnableToRedirect(true);\n }\n\n return undefined;\n }\n\n const timer = setInterval(() => {\n setCountdown(dec);\n }, 1000);\n\n return () => clearInterval(timer);\n }, [\n countdown,\n redirectUrl,\n passEventDetailsToRedirectUrl,\n enableTopLevelRedirect,\n ]);\n\n return (\n <>\n {redirectMessage && (\n <div className=\"neeto-thank-you-configuration__description mt-6\">\n <MemoizedEditorContent\n content={message}\n data-testid=\"thank-you-page-message\"\n {...editorProps}\n />\n </div>\n )}\n {isUnableToRedirect && (\n <p className=\"neeto-thank-you-configuration__redirect-failure-message\">\n <Trans\n i18nKey=\"neetoThankYou.thankYou.redirectFailureMessage\"\n components={{\n Link: (\n <a\n href={getSafeURL(buildRedirectUrlWithParams())}\n {...redirectFailureAnchorProps}\n />\n ),\n }}\n />\n </p>\n )}\n {!isUnableToRedirect && countdown > 0 && (\n <p className=\"neeto-thank-you-configuration__redirect-message\">\n {t(\"neetoThankYou.thankYou.redirectingInSecondsMessage\", {\n seconds: countdown,\n })}\n </p>\n )}\n {isPresent(ctaProps) && <CallToAction {...{ appName, ...ctaProps }} />}\n </>\n );\n};\n\nexport default ExternalLink;\n","import classNames from \"classnames\";\nimport NeetoUIPageLoader from \"neetomolecules/PageLoader\";\n\nimport BrandingInfo from \"components/commons/BrandingInfo\";\nimport {\n FORM_OPTIONS,\n THANK_YOU_TEXT_ALIGNMENTS,\n} from \"components/commons/constants\";\nimport { IS_PRO_ORGANIZATION } from \"components/constants\";\nimport { useShowThankYouPage } from \"hooks/reactQuery/useThankYouPageApi\";\n// eslint-disable-next-line import/extensions\nimport \"stylesheets/layout/thank-you.css\";\n\nimport CustomMessage from \"./CustomMessage\";\nimport ExternalLink from \"./ExternalLink\";\n\nconst DefaultPageLoader = () => (\n <div className=\"neeto-thank-you-configuration\">\n <NeetoUIPageLoader />\n </div>\n);\n\nconst ShowThankYou = ({\n entityId,\n isDraftPreview,\n resubmitLink,\n socialHandles,\n isThankYouPageLoading,\n publicLinkId,\n resourceId,\n appName,\n appIcon,\n customPageLoader: CustomPageLoader,\n thankYouTextAlignment = THANK_YOU_TEXT_ALIGNMENTS.center,\n editorProps = {},\n enableTopLevelRedirect = true,\n eventDetails = {},\n ctaProps = {},\n}) => {\n const { data: { thankYouConfiguration } = {}, isFetching } =\n useShowThankYouPage({ entityId, resourceId });\n\n const PageLoader = CustomPageLoader || DefaultPageLoader;\n\n const isCtaVisible =\n !IS_PRO_ORGANIZATION && thankYouConfiguration?.brandingEnabled;\n\n if (isFetching && isThankYouPageLoading) {\n return <PageLoader />;\n }\n\n return (\n <div className=\"neeto-thank-you-configuration\">\n <main\n className={classNames(\"neeto-thank-you-configuration__main\", {\n \"neeto-thank-you-configuration-alignment--left\":\n thankYouTextAlignment === THANK_YOU_TEXT_ALIGNMENTS.left,\n \"neeto-thank-you-configuration-alignment--center\":\n thankYouTextAlignment === THANK_YOU_TEXT_ALIGNMENTS.center,\n })}\n >\n <div\n data-testid=\"thank-you-page-content\"\n className={classNames(\"neeto-thank-you-configuration__box\", {\n \"neeto-thank-you-configuration__box--is-cta-visible\": isCtaVisible,\n })}\n >\n {thankYouConfiguration?.kind === FORM_OPTIONS.customize.kind ? (\n <CustomMessage\n {...{\n appName,\n editorProps,\n isDraftPreview,\n publicLinkId,\n resubmitLink,\n socialHandles,\n thankYouConfiguration,\n ...(isCtaVisible && { ctaProps }),\n }}\n />\n ) : (\n <ExternalLink\n {...{\n appName,\n editorProps,\n enableTopLevelRedirect,\n eventDetails,\n thankYouConfiguration,\n ...(isCtaVisible && { ctaProps }),\n }}\n />\n )}\n </div>\n </main>\n {!IS_PRO_ORGANIZATION && thankYouConfiguration?.brandingEnabled && (\n <BrandingInfo {...{ appIcon, appName }} />\n )}\n </div>\n );\n};\n\nexport default ShowThankYou;\n"],"names":["buildDraftUrl","url","concat","getSafeURL","parsed","URL","protocol","undefined","DOMPurify","sanitize","_unused","substituteVariables","highlightedContent","arguments","length","variables","replace","VARIABLE_SPAN_REGEX","matchedSpan","dataLabel","dataLabelSplitted","split","category","findBy","variable","key","value","MemoizedEditorContent","memo","EditorContent","CustomMessage","_ref","_thankYouConfiguratio","isDraftPreview","publicLinkId","resubmitLink","socialHandles","thankYouConfiguration","editorProps","appName","_ref$ctaProps","ctaProps","_useTranslation","useTranslation","t","message","_jsxs","_Fragment","children","_jsx","className","_objectSpread","content","showResubmitLink","href","resubmitLinkText","socialSharingEnabled","SocialShare","isPresent","CallToAction","ExternalLink","_ref$thankYouConfigur","enableTopLevelRedirect","eventDetails","_useState","useState","REDIRECT_DELAY","_useState2","_slicedToArray","countdown","setCountdown","_useState3","_useState4","isUnableToRedirect","setIsUnableToRedirect","redirectUrl","_thankYouConfiguratio2","redirectMessage","_thankYouConfiguratio3","passEventDetailsToRedirectUrl","redirectFailureAnchorProps","target","rel","buildRedirectUrlWithParams","redirectUrlWithParams","toPairs","filterNonNull","forEach","_ref2","_ref3","searchParams","set","toString","useEffect","redirectTarget","window","top","location","_unused2","timer","setInterval","dec","clearInterval","Trans","i18nKey","components","Link","seconds","DefaultPageLoader","NeetoUIPageLoader","ShowThankYou","entityId","isThankYouPageLoading","resourceId","appIcon","CustomPageLoader","customPageLoader","_ref$thankYouTextAlig","thankYouTextAlignment","THANK_YOU_TEXT_ALIGNMENTS","center","_ref$editorProps","_ref$enableTopLevelRe","_ref$eventDetails","_useShowThankYouPage","useShowThankYouPage","_useShowThankYouPage$","data","_useShowThankYouPage$2","isFetching","PageLoader","isCtaVisible","IS_PRO_ORGANIZATION","brandingEnabled","classNames","left","kind","FORM_OPTIONS","customize","BrandingInfo"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;AAKO,IAAMA,aAAa,GAAG,SAAhBA,aAAaA,CAAGC,GAAG,EAAA;EAAA,OAAA,EAAA,CAAAC,MAAA,CAAOD,GAAG,EAAA,oBAAA,CAAA;AAAA,CAAoB;AAEvD,IAAME,UAAU,GAAG,SAAbA,UAAUA,CAAGF,GAAG,EAAI;EAC/B,IAAI;AACF,IAAA,IAAMG,MAAM,GAAG,IAAIC,GAAG,CAACJ,GAAG,CAAC;IAC3B,IAAIG,MAAM,CAACE,QAAQ,KAAK,QAAQ,IAAIF,MAAM,CAACE,QAAQ,KAAK,OAAO,EAAE;AAC/D,MAAA,OAAOC,SAAS;AAClB,IAAA;AAEA,IAAA,OAAOC,SAAS,CAACC,QAAQ,CAACR,GAAG,CAAC;EAChC,CAAC,CAAC,OAAAS,OAAA,EAAM;AACN,IAAA,OAAOH,SAAS;AAClB,EAAA;AACF,CAAC;AAEM,IAAMI,mBAAmB,GAAG,SAAtBA,mBAAmBA,GAAA;AAAA,EAAA,IAAIC,kBAAkB,GAAAC,SAAA,CAAAC,MAAA,GAAA,CAAA,IAAAD,SAAA,CAAA,CAAA,CAAA,KAAAN,SAAA,GAAAM,SAAA,CAAA,CAAA,CAAA,GAAG,EAAE;AAAA,EAAA,IAAEE,SAAS,GAAAF,SAAA,CAAAC,MAAA,GAAA,CAAA,IAAAD,SAAA,CAAA,CAAA,CAAA,KAAAN,SAAA,GAAAM,SAAA,CAAA,CAAA,CAAA,GAAG,EAAE;EAAA,OACzED,kBAAkB,CAACI,OAAO,CAACC,6BAAmB,EAAE,U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AA,IAArBA,qBAAqB,KAAA,MAAA,GAAA,MAAA,GAArBA,qBAAqB,CAAEmG,IAAI,MAAKC,wBAAY,CAACC,SAAS,CAACF,IAAI,gBAC1DvF,cAAA,CAACnB,aAAa,EAAAqB,aAAA,CAAA,EAAA,EAAAA,aAAA,CAAA;AAEVZ,UAAAA,OAAO,EAAPA,OAAO;AACPD,UAAAA,WAAW,EAAXA,WAAW;AACXL,UAAAA,cAAc,EAAdA,cAAc;AACdC,UAAAA,YAAY,EAAZA,YAAY;AACZC,UAAAA,YAAY,EAAZA,YAAY;AACZC,UAAAA,aAAa,EAAbA,aAAa;AACbC,UAAAA,qBAAqB,EAArBA;AAAqB,SAAA,EACjB8F,YAAY,IAAI;AAAE1F,UAAAA,QAAQ,EAARA;SAAU,CAAA,CAEnC,CAAC,gBAEFQ,cAAA,CAACW,YAAY,EAAAT,aAAA,CAAA,EAAA,EAAAA,aAAA,CAAA;AAETZ,UAAAA,OAAO,EAAPA,OAAO;AACPD,UAAAA,WAAW,EAAXA,WAAW;AACXwB,UAAAA,sBAAsB,EAAtBA,sBAAsB;AACtBC,UAAAA,YAAY,EAAZA,YAAY;AACZ1B,UAAAA,qBAAqB,EAArBA;AAAqB,SAAA,EACjB8F,YAAY,IAAI;AAAE1F,UAAAA,QAAQ,EAARA;AAAS,SAAC,CAAA,CAEnC;OAEA;AAAC,KACF,CAAC,EACN,CAAC2F,6BAAmB,KAAI/F,qBAAqB,KAAA,IAAA,IAArBA,qBAAqB,KAAA,MAAA,GAAA,MAAA,GAArBA,qBAAqB,CAAEgG,eAAe,CAAA,iBAC7DpF,cAAA,CAAC0F,yBAAY,EAAA;AAAOzB,MAAAA,OAAO,EAAPA,OAAO;AAAE3E,MAAAA,OAAO,EAAPA;AAAO,KAAK,CAC1C;AAAA,GACE,CAAC;AAEV;;;;"}
1
+ {"version":3,"file":"ShowThankYou.js","sources":["../../app/javascript/src/components/ShowThankYou/utils.js","../../app/javascript/src/components/ShowThankYou/CustomMessage.jsx","../../app/javascript/src/components/ShowThankYou/ExternalLink.jsx","../../app/javascript/src/components/ShowThankYou/index.jsx"],"sourcesContent":["import DOMPurify from \"dompurify\";\nimport { findBy } from \"neetocist\";\n\nimport { VARIABLE_SPAN_REGEX } from \"components/constants\";\n\nexport const buildDraftUrl = url => `${url}?draftPreview=true`;\n\nexport const getSafeURL = url => {\n try {\n const parsed = new URL(url);\n if (parsed.protocol !== \"https:\" && parsed.protocol !== \"http:\") {\n return undefined;\n }\n\n return DOMPurify.sanitize(url);\n } catch {\n return undefined;\n }\n};\n\nexport const substituteVariables = (highlightedContent = \"\", variables = []) =>\n highlightedContent.replace(VARIABLE_SPAN_REGEX, (matchedSpan, dataLabel) => {\n const dataLabelSplitted = dataLabel.split(\".\");\n\n if (dataLabelSplitted.length > 1) {\n const category = findBy({ category: dataLabelSplitted[0] }, variables);\n const variable = findBy(\n { key: dataLabelSplitted[1] },\n category?.variables || []\n );\n\n return variable?.value ? variable.value : matchedSpan;\n }\n\n const variable = findBy({ key: dataLabelSplitted[0] }, variables);\n\n return variable?.value ? variable.value : matchedSpan;\n });\n","import { memo } from \"react\";\n\nimport { isPresent } from \"neetocist\";\nimport { EditorContent } from \"neetoeditor\";\nimport { useTranslation } from \"react-i18next\";\n\nimport CallToAction from \"components/commons/CallToAction\";\nimport SocialShare from \"components/ConfigureThankYou/Customize/SocialShare\";\n\nimport { buildDraftUrl, substituteVariables } from \"./utils\";\n\nconst MemoizedEditorContent = memo(EditorContent);\n\nconst CustomMessage = ({\n isDraftPreview,\n publicLinkId,\n resubmitLink,\n socialHandles,\n thankYouConfiguration,\n editorProps,\n appName,\n ctaProps = {},\n}) => {\n const { t } = useTranslation();\n\n const message = substituteVariables(\n thankYouConfiguration?.message,\n editorProps.variables\n );\n\n return (\n <>\n {thankYouConfiguration?.message && (\n <div className=\"neeto-thank-you-configuration__description neeto-ui-text-gray-800\">\n <MemoizedEditorContent\n content={message}\n data-testid=\"thank-you-page-message\"\n {...editorProps}\n />\n </div>\n )}\n {thankYouConfiguration?.showResubmitLink && (\n <a\n className=\"neeto-thank-you-configuration__resubmit\"\n data-testid=\"thank-you-page-resubmit-link\"\n href={isDraftPreview ? buildDraftUrl(resubmitLink) : resubmitLink}\n >\n {thankYouConfiguration?.resubmitLinkText ??\n t(\"neetoThankYou.common.resubmit\")}\n </a>\n )}\n {thankYouConfiguration?.socialSharingEnabled && (\n <SocialShare {...{ publicLinkId, socialHandles }} />\n )}\n {isDraftPreview && (\n <p className=\"neeto-thank-you-configuration__draft-preview-message\">\n {t(\"neetoThankYou.thankYou.draftVersionForm\")}\n </p>\n )}\n {isPresent(ctaProps) && <CallToAction {...{ appName, ...ctaProps }} />}\n </>\n );\n};\n\nexport default CustomMessage;\n","import { useEffect, useState, memo } from \"react\";\n\nimport { isPresent, filterNonNull } from \"neetocist\";\nimport { EditorContent } from \"neetoeditor\";\nimport { dec, toPairs } from \"ramda\";\nimport { Trans, useTranslation } from \"react-i18next\";\n\nimport CallToAction from \"components/commons/CallToAction\";\nimport { REDIRECT_DELAY } from \"components/commons/constants\";\n\nimport { getSafeURL, substituteVariables } from \"./utils\";\n\nconst MemoizedEditorContent = memo(EditorContent);\n\nconst ExternalLink = ({\n thankYouConfiguration = {},\n editorProps,\n enableTopLevelRedirect,\n eventDetails,\n appName,\n ctaProps = {},\n}) => {\n const [countdown, setCountdown] = useState(REDIRECT_DELAY);\n const [isUnableToRedirect, setIsUnableToRedirect] = useState(false);\n\n const { t } = useTranslation();\n\n const {\n redirectUrl = \"\",\n redirectMessage = \"\",\n passEventDetailsToRedirectUrl = false,\n } = thankYouConfiguration;\n const message = substituteVariables(redirectMessage, editorProps.variables);\n const redirectFailureAnchorProps = enableTopLevelRedirect\n ? { target: \"_top\", rel: \"noreferrer\" }\n : {};\n\n const buildRedirectUrlWithParams = () => {\n try {\n const redirectUrlWithParams = new URL(redirectUrl);\n\n if (passEventDetailsToRedirectUrl && isPresent(eventDetails)) {\n toPairs(filterNonNull(eventDetails)).forEach(([key, value]) => {\n redirectUrlWithParams.searchParams.set(key, value);\n });\n }\n\n return redirectUrlWithParams.toString();\n } catch {\n return redirectUrl;\n }\n };\n\n useEffect(() => {\n if (countdown === 0) {\n try {\n const redirectUrlWithParams = buildRedirectUrlWithParams();\n const redirectTarget = enableTopLevelRedirect\n ? window.top.location\n : window.location;\n\n redirectTarget.href = getSafeURL(redirectUrlWithParams);\n } catch {\n setIsUnableToRedirect(true);\n }\n\n return undefined;\n }\n\n const timer = setInterval(() => {\n setCountdown(dec);\n }, 1000);\n\n return () => clearInterval(timer);\n }, [\n countdown,\n redirectUrl,\n passEventDetailsToRedirectUrl,\n enableTopLevelRedirect,\n ]);\n\n return (\n <>\n {redirectMessage && (\n <div className=\"neeto-thank-you-configuration__description mt-6\">\n <MemoizedEditorContent\n content={message}\n data-testid=\"thank-you-page-message\"\n {...editorProps}\n />\n </div>\n )}\n {isUnableToRedirect && (\n <p className=\"neeto-thank-you-configuration__redirect-failure-message\">\n <Trans\n i18nKey=\"neetoThankYou.thankYou.redirectFailureMessage\"\n components={{\n Link: (\n <a\n href={getSafeURL(buildRedirectUrlWithParams())}\n {...redirectFailureAnchorProps}\n />\n ),\n }}\n />\n </p>\n )}\n {!isUnableToRedirect && countdown > 0 && (\n <p className=\"neeto-thank-you-configuration__redirect-message\">\n {t(\"neetoThankYou.thankYou.redirectingInSecondsMessage\", {\n seconds: countdown,\n })}\n </p>\n )}\n {isPresent(ctaProps) && <CallToAction {...{ appName, ...ctaProps }} />}\n </>\n );\n};\n\nexport default ExternalLink;\n","import classNames from \"classnames\";\nimport NeetoUIPageLoader from \"neetomolecules/PageLoader\";\n\nimport BrandingInfo from \"components/commons/BrandingInfo\";\nimport {\n FORM_OPTIONS,\n THANK_YOU_TEXT_ALIGNMENTS,\n} from \"components/commons/constants\";\nimport { IS_PRO_ORGANIZATION } from \"components/constants\";\nimport { useShowThankYouPage } from \"hooks/reactQuery/useThankYouPageApi\";\n// eslint-disable-next-line import/extensions\nimport \"stylesheets/layout/thank-you.css\";\n\nimport CustomMessage from \"./CustomMessage\";\nimport ExternalLink from \"./ExternalLink\";\n\nconst DefaultPageLoader = () => (\n <div className=\"neeto-thank-you-configuration\">\n <NeetoUIPageLoader />\n </div>\n);\n\nconst ShowThankYou = ({\n entityId,\n isDraftPreview,\n resubmitLink,\n socialHandles,\n isThankYouPageLoading,\n publicLinkId,\n resourceId,\n appName,\n appIcon,\n customPageLoader: CustomPageLoader,\n thankYouTextAlignment = THANK_YOU_TEXT_ALIGNMENTS.center,\n editorProps = {},\n enableTopLevelRedirect = true,\n eventDetails = {},\n ctaProps = {},\n}) => {\n const { data: { thankYouConfiguration } = {}, isFetching } =\n useShowThankYouPage({ entityId, resourceId });\n\n const PageLoader = CustomPageLoader || DefaultPageLoader;\n\n const isCtaVisible =\n !IS_PRO_ORGANIZATION && thankYouConfiguration?.brandingEnabled;\n\n if (isFetching && isThankYouPageLoading) {\n return <PageLoader />;\n }\n\n return (\n <div className=\"neeto-thank-you-configuration\">\n <main\n className={classNames(\"neeto-thank-you-configuration__main\", {\n \"neeto-thank-you-configuration-alignment--left\":\n thankYouTextAlignment === THANK_YOU_TEXT_ALIGNMENTS.left,\n \"neeto-thank-you-configuration-alignment--center\":\n thankYouTextAlignment === THANK_YOU_TEXT_ALIGNMENTS.center,\n })}\n >\n <div\n data-testid=\"thank-you-page-content\"\n className={classNames(\"neeto-thank-you-configuration__box\", {\n \"neeto-thank-you-configuration__box--is-cta-visible\": isCtaVisible,\n })}\n >\n {thankYouConfiguration?.kind === FORM_OPTIONS.customize.kind ? (\n <CustomMessage\n {...{\n appName,\n editorProps,\n isDraftPreview,\n publicLinkId,\n resubmitLink,\n socialHandles,\n thankYouConfiguration,\n ...(isCtaVisible && { ctaProps }),\n }}\n />\n ) : (\n <ExternalLink\n {...{\n appName,\n editorProps,\n enableTopLevelRedirect,\n eventDetails,\n thankYouConfiguration,\n ...(isCtaVisible && { ctaProps }),\n }}\n />\n )}\n </div>\n </main>\n {!IS_PRO_ORGANIZATION && thankYouConfiguration?.brandingEnabled && (\n <BrandingInfo {...{ appIcon, appName }} />\n )}\n </div>\n );\n};\n\nexport default ShowThankYou;\n"],"names":["buildDraftUrl","url","concat","getSafeURL","parsed","URL","protocol","undefined","DOMPurify","sanitize","_unused","substituteVariables","highlightedContent","arguments","length","variables","replace","VARIABLE_SPAN_REGEX","matchedSpan","dataLabel","dataLabelSplitted","split","category","findBy","variable","key","value","MemoizedEditorContent","memo","EditorContent","CustomMessage","_ref","_thankYouConfiguratio","isDraftPreview","publicLinkId","resubmitLink","socialHandles","thankYouConfiguration","editorProps","appName","_ref$ctaProps","ctaProps","_useTranslation","useTranslation","t","message","_jsxs","_Fragment","children","_jsx","className","_objectSpread","content","showResubmitLink","href","resubmitLinkText","socialSharingEnabled","SocialShare","isPresent","CallToAction","ExternalLink","_ref$thankYouConfigur","enableTopLevelRedirect","eventDetails","_useState","useState","REDIRECT_DELAY","_useState2","_slicedToArray","countdown","setCountdown","_useState3","_useState4","isUnableToRedirect","setIsUnableToRedirect","redirectUrl","_thankYouConfiguratio2","redirectMessage","_thankYouConfiguratio3","passEventDetailsToRedirectUrl","redirectFailureAnchorProps","target","rel","buildRedirectUrlWithParams","redirectUrlWithParams","toPairs","filterNonNull","forEach","_ref2","_ref3","searchParams","set","toString","useEffect","redirectTarget","window","top","location","_unused2","timer","setInterval","dec","clearInterval","Trans","i18nKey","components","Link","seconds","DefaultPageLoader","NeetoUIPageLoader","ShowThankYou","entityId","isThankYouPageLoading","resourceId","appIcon","CustomPageLoader","customPageLoader","_ref$thankYouTextAlig","thankYouTextAlignment","THANK_YOU_TEXT_ALIGNMENTS","center","_ref$editorProps","_ref$enableTopLevelRe","_ref$eventDetails","_useShowThankYouPage","useShowThankYouPage","_useShowThankYouPage$","data","_useShowThankYouPage$2","isFetching","PageLoader","isCtaVisible","IS_PRO_ORGANIZATION","brandingEnabled","classNames","left","kind","FORM_OPTIONS","customize","BrandingInfo"],"mappings":";;;;;;;;;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ACXL,UAAAA,cAAc,EAAdA,cAAc;AACdC,UAAAA,YAAY,EAAZA,YAAY;AACZC,UAAAA,YAAY,EAAZA,YAAY;AACZC,UAAAA,aAAa,EAAbA,aAAa;AACbC,UAAAA,qBAAqB,EAArBA;AAAqB,SAAA,EACjB8F,YAAY,IAAI;AAAE1F,UAAAA,QAAQ,EAARA;SAAU,CAAA,CAEnC,CAAC,gBAEFQ,cAAA,CAACW,YAAY,EAAAT,aAAA,CAAA,EAAA,EAAAA,aAAA,CAAA;AAETZ,UAAAA,OAAO,EAAPA,OAAO;AACPD,UAAAA,WAAW,EAAXA,WAAW;AACXwB,UAAAA,sBAAsB,EAAtBA,sBAAsB;AACtBC,UAAAA,YAAY,EAAZA,YAAY;AACZ1B,UAAAA,qBAAqB,EAArBA;AAAqB,SAAA,EACjB8F,YAAY,IAAI;AAAE1F,UAAAA,QAAQ,EAARA;AAAS,SAAC,CAAA,CAEnC;OAEA;AAAC,KACF,CAAC,EACN,CAAC2F,6BAAmB,KAAI/F,qBAAqB,KAAA,IAAA,IAArBA,qBAAqB,KAAA,MAAA,GAAA,MAAA,GAArBA,qBAAqB,CAAEgG,eAAe,CAAA,iBAC7DpF,cAAA,CAAC0F,yBAAY,EAAA;AAAOzB,MAAAA,OAAO,EAAPA,OAAO;AAAE3E,MAAAA,OAAO,EAAPA;AAAO,KAAK,CAC1C;AAAA,GACE,CAAC;AAEV;;;;"}
@@ -0,0 +1,100 @@
1
+ 'use strict';
2
+
3
+ var initializers = require('@bigbinary/neeto-commons-frontend/v2/initializers');
4
+ var i18next = require('i18next');
5
+ var jsxRuntime = require('react/jsx-runtime');
6
+ var reactUtils = require('@bigbinary/neeto-commons-frontend/v2/react-utils');
7
+
8
+ var THANK_YOU_KINDS = {
9
+ CUSTOM_MESSAGE: "custom_message",
10
+ REDIRECT_TO_URL: "redirect_to_url"
11
+ };
12
+ var FORM_OPTIONS = {
13
+ customize: {
14
+ label: i18next.t("neetoThankYou.thankYou.customize"),
15
+ description: i18next.t("neetoThankYou.thankYou.customizeDescription"),
16
+ kind: THANK_YOU_KINDS.CUSTOM_MESSAGE
17
+ },
18
+ externalLink: {
19
+ label: i18next.t("neetoThankYou.thankYou.externalLink"),
20
+ description: i18next.t("neetoThankYou.thankYou.externalLinkDescription"),
21
+ kind: THANK_YOU_KINDS.REDIRECT_TO_URL
22
+ }
23
+ };
24
+ var THANK_YOU_TEXT_ALIGNMENTS = {
25
+ left: "left",
26
+ center: "center"
27
+ };
28
+ var REDIRECT_DELAY = 5;
29
+ var NEETO = "Neeto";
30
+ var NEETO_BASE_URL = "https://www.neeto.com";
31
+ var UTM_SOURCE = "utm_source=cta";
32
+ var UTM_CAMPAIGN_PARAM = "utm_campaign";
33
+
34
+ var generateUtmParams = function generateUtmParams() {
35
+ var _globalProps$organiza;
36
+ var subdomain = (_globalProps$organiza = initializers.globalProps.organization) === null || _globalProps$organiza === void 0 ? void 0 : _globalProps$organiza.subdomain;
37
+ return "".concat(UTM_SOURCE).concat(subdomain ? "&".concat(UTM_CAMPAIGN_PARAM, "=").concat(subdomain) : "");
38
+ };
39
+ var generateProductPageUrl = function generateProductPageUrl(appName) {
40
+ var name = appName || initializers.globalProps.appName || NEETO;
41
+ var utmParams = generateUtmParams();
42
+ return "".concat(NEETO_BASE_URL, "/").concat(name.toLowerCase(), "?").concat(utmParams);
43
+ };
44
+
45
+ var CallToAction = function CallToAction(_ref) {
46
+ var appName = _ref.appName,
47
+ message = _ref.message,
48
+ buttonLabel = _ref.buttonLabel;
49
+ return /*#__PURE__*/jsxRuntime.jsxs("div", {
50
+ className: "neeto-thank-you-configuration__cta",
51
+ children: [/*#__PURE__*/jsxRuntime.jsx("p", {
52
+ className: "neeto-thank-you-configuration__cta-message",
53
+ children: message
54
+ }), /*#__PURE__*/jsxRuntime.jsx("a", {
55
+ className: "neeto-thank-you-configuration__cta-button",
56
+ "data-testid": "neeto-thank-you-configuration-cta-button",
57
+ href: generateProductPageUrl(appName),
58
+ rel: "noopener noreferrer",
59
+ target: "_blank",
60
+ children: buttonLabel
61
+ })]
62
+ });
63
+ };
64
+
65
+ var SocialShare = reactUtils.withT(function (_ref) {
66
+ var t = _ref.t,
67
+ socialHandles = _ref.socialHandles,
68
+ publicLinkId = _ref.publicLinkId;
69
+ return /*#__PURE__*/jsxRuntime.jsxs("div", {
70
+ className: "neeto-thank-you-configuration__social-share",
71
+ children: [/*#__PURE__*/jsxRuntime.jsx("h4", {
72
+ className: "neeto-thank-you-configuration__social-share-title",
73
+ children: t("neetoThankYou.thankYou.socialShareHeading")
74
+ }), /*#__PURE__*/jsxRuntime.jsx("div", {
75
+ className: "neeto-thank-you-configuration-social-follow",
76
+ "data-testid": "social-share-icons",
77
+ children: socialHandles === null || socialHandles === void 0 ? void 0 : socialHandles.map(function (data, idx) {
78
+ var Icon = data.icon,
79
+ generateShareUrl = data.generateShareUrl;
80
+ return /*#__PURE__*/jsxRuntime.jsx("div", {
81
+ className: "neeto-thank-you-configuration-social-follow__item",
82
+ children: /*#__PURE__*/jsxRuntime.jsx("a", {
83
+ href: generateShareUrl(publicLinkId),
84
+ rel: "noreferrer",
85
+ target: "_blank",
86
+ children: /*#__PURE__*/jsxRuntime.jsx(Icon, {})
87
+ })
88
+ }, idx);
89
+ })
90
+ })]
91
+ });
92
+ });
93
+
94
+ exports.CallToAction = CallToAction;
95
+ exports.FORM_OPTIONS = FORM_OPTIONS;
96
+ exports.REDIRECT_DELAY = REDIRECT_DELAY;
97
+ exports.SocialShare = SocialShare;
98
+ exports.THANK_YOU_KINDS = THANK_YOU_KINDS;
99
+ exports.THANK_YOU_TEXT_ALIGNMENTS = THANK_YOU_TEXT_ALIGNMENTS;
100
+ //# sourceMappingURL=SocialShare-BFeAkgVT.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"SocialShare-BFeAkgVT.js","sources":["../../app/javascript/src/v2/components/commons/constants.js","../../app/javascript/src/v2/components/commons/utils.js","../../app/javascript/src/v2/components/commons/CallToAction.jsx","../../app/javascript/src/v2/components/ConfigureThankYou/Customize/SocialShare.jsx"],"sourcesContent":["import { t } from \"i18next\";\n\nexport const THANK_YOU_KINDS = {\n CUSTOM_MESSAGE: \"custom_message\",\n REDIRECT_TO_URL: \"redirect_to_url\",\n};\n\nexport const FORM_OPTIONS = {\n customize: {\n label: t(\"neetoThankYou.thankYou.customize\"),\n description: t(\"neetoThankYou.thankYou.customizeDescription\"),\n kind: THANK_YOU_KINDS.CUSTOM_MESSAGE,\n },\n externalLink: {\n label: t(\"neetoThankYou.thankYou.externalLink\"),\n description: t(\"neetoThankYou.thankYou.externalLinkDescription\"),\n kind: THANK_YOU_KINDS.REDIRECT_TO_URL,\n },\n};\n\nexport const THANK_YOU_TEXT_ALIGNMENTS = {\n left: \"left\",\n center: \"center\",\n};\n\nexport const REDIRECT_DELAY = 5;\n\nexport const NEETO = \"Neeto\";\nexport const NEETO_BASE_URL = \"https://www.neeto.com\";\nexport const UTM_SOURCE = \"utm_source=cta\";\nexport const UTM_CAMPAIGN_PARAM = \"utm_campaign\";\n","import { globalProps } from \"neetocommons/v2/initializers\";\n\nimport {\n UTM_SOURCE,\n UTM_CAMPAIGN_PARAM,\n NEETO,\n NEETO_BASE_URL,\n} from \"./constants\";\n\nexport const generateUtmParams = () => {\n const subdomain = globalProps.organization?.subdomain;\n\n return `${UTM_SOURCE}${subdomain ? `&${UTM_CAMPAIGN_PARAM}=${subdomain}` : \"\"}`;\n};\n\nexport const generateProductPageUrl = appName => {\n const name = appName || globalProps.appName || NEETO;\n const utmParams = generateUtmParams();\n\n return `${NEETO_BASE_URL}/${name.toLowerCase()}?${utmParams}`;\n};\n","import { generateProductPageUrl } from \"./utils\";\n\nconst CallToAction = ({ appName, message, buttonLabel }) => (\n <div className=\"neeto-thank-you-configuration__cta\">\n <p className=\"neeto-thank-you-configuration__cta-message\">{message}</p>\n <a\n className=\"neeto-thank-you-configuration__cta-button\"\n data-testid=\"neeto-thank-you-configuration-cta-button\"\n href={generateProductPageUrl(appName)}\n rel=\"noopener noreferrer\"\n target=\"_blank\"\n >\n {buttonLabel}\n </a>\n </div>\n);\n\nexport default CallToAction;\n","import { withT } from \"neetocommons/v2/react-utils\";\n\nconst SocialShare = withT(({ t, socialHandles, publicLinkId }) => (\n <div className=\"neeto-thank-you-configuration__social-share\">\n <h4 className=\"neeto-thank-you-configuration__social-share-title\">\n {t(\"neetoThankYou.thankYou.socialShareHeading\")}\n </h4>\n <div\n className=\"neeto-thank-you-configuration-social-follow\"\n data-testid=\"social-share-icons\"\n >\n {socialHandles?.map((data, idx) => {\n const { icon: Icon, generateShareUrl } = data;\n\n return (\n <div\n className=\"neeto-thank-you-configuration-social-follow__item\"\n key={idx}\n >\n <a\n href={generateShareUrl(publicLinkId)}\n rel=\"noreferrer\"\n target=\"_blank\"\n >\n <Icon />\n </a>\n </div>\n );\n })}\n </div>\n </div>\n));\n\nexport default SocialShare;\n"],"names":["THANK_YOU_KINDS","CUSTOM_MESSAGE","REDIRECT_TO_URL","FORM_OPTIONS","customize","label","t","description","kind","externalLink","THANK_YOU_TEXT_ALIGNMENTS","left","center","REDIRECT_DELAY","NEETO","NEETO_BASE_URL","UTM_SOURCE","UTM_CAMPAIGN_PARAM","generateUtmParams","_globalProps$organiza","subdomain","globalProps","organization","concat","generateProductPageUrl","appName","name","utmParams","toLowerCase","CallToAction","_ref","message","buttonLabel","_jsxs","className","children","_jsx","href","rel","target","SocialShare","withT","socialHandles","publicLinkId","map","data","idx","Icon","icon","generateShareUrl"],"mappings":";;;;;;;AAEO,IAAMA,eAAe,GAAG;AAC7BC,EAAAA,cAAc,EAAE,gBAAgB;AAChCC,EAAAA,eAAe,EAAE;AACnB;AAEO,IAAMC,YAAY,GAAG;AAC1BC,EAAAA,SAAS,EAAE;AACTC,IAAAA,KAAK,EAAEC,SAAC,CAAC,kCAAkC,CAAC;AAC5CC,IAAAA,WAAW,EAAED,SAAC,CAAC,6CAA6C,CAAC;IAC7DE,IAAI,EAAER,eAAe,CAACC;GACvB;AACDQ,EAA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,IAAbA,aAAa,KAAA,MAAA,GAAA,MAAA,GAAbA,aAAa,CAAEE,GAAG,CAAC,UAACC,IAAI,EAAEC,GAAG,EAAK;AACjC,QAAA,IAAcC,IAAI,GAAuBF,IAAI,CAArCG,IAAI;UAAQC,gBAAgB,GAAKJ,IAAI,CAAzBI,gBAAgB;AAEpC,QAAA,oBACEb,cAAA,CAAA,KAAA,EAAA;AACEF,UAAAA,SAAS,EAAC,mDAAmD;AAAAC,UAAAA,QAAA,eAG7DC,cAAA,CAAA,GAAA,EAAA;AACEC,YAAAA,IAAI,EAAEY,gBAAgB,CAACN,YAAY,CAAE;AACrCL,YAAAA,GAAG,EAAC,YAAY;AAChBC,YAAAA,MAAM,EAAC,QAAQ;AAAAJ,YAAAA,QAAA,eAEfC,cAAA,CAACW,IAAI,EAAA,EAAE;WACN;AAAC,SAAA,EARCD,GASF,CAAC;MAEV,CAAC;AAAC,KACC,CAAC;AAAA,GACH,CAAC;AAAA,CACP;;;;;;;;;"}
@@ -0,0 +1,100 @@
1
+ 'use strict';
2
+
3
+ var initializers = require('@bigbinary/neeto-commons-frontend/initializers');
4
+ var i18next = require('i18next');
5
+ var jsxRuntime = require('react/jsx-runtime');
6
+ var reactUtils = require('@bigbinary/neeto-commons-frontend/react-utils');
7
+
8
+ var THANK_YOU_KINDS = {
9
+ CUSTOM_MESSAGE: "custom_message",
10
+ REDIRECT_TO_URL: "redirect_to_url"
11
+ };
12
+ var FORM_OPTIONS = {
13
+ customize: {
14
+ label: i18next.t("neetoThankYou.thankYou.customize"),
15
+ description: i18next.t("neetoThankYou.thankYou.customizeDescription"),
16
+ kind: THANK_YOU_KINDS.CUSTOM_MESSAGE
17
+ },
18
+ externalLink: {
19
+ label: i18next.t("neetoThankYou.thankYou.externalLink"),
20
+ description: i18next.t("neetoThankYou.thankYou.externalLinkDescription"),
21
+ kind: THANK_YOU_KINDS.REDIRECT_TO_URL
22
+ }
23
+ };
24
+ var THANK_YOU_TEXT_ALIGNMENTS = {
25
+ left: "left",
26
+ center: "center"
27
+ };
28
+ var REDIRECT_DELAY = 5;
29
+ var NEETO = "Neeto";
30
+ var NEETO_BASE_URL = "https://www.neeto.com";
31
+ var UTM_SOURCE = "utm_source=cta";
32
+ var UTM_CAMPAIGN_PARAM = "utm_campaign";
33
+
34
+ var generateUtmParams = function generateUtmParams() {
35
+ var _globalProps$organiza;
36
+ var subdomain = (_globalProps$organiza = initializers.globalProps.organization) === null || _globalProps$organiza === void 0 ? void 0 : _globalProps$organiza.subdomain;
37
+ return "".concat(UTM_SOURCE).concat(subdomain ? "&".concat(UTM_CAMPAIGN_PARAM, "=").concat(subdomain) : "");
38
+ };
39
+ var generateProductPageUrl = function generateProductPageUrl(appName) {
40
+ var name = appName || initializers.globalProps.appName || NEETO;
41
+ var utmParams = generateUtmParams();
42
+ return "".concat(NEETO_BASE_URL, "/").concat(name.toLowerCase(), "?").concat(utmParams);
43
+ };
44
+
45
+ var CallToAction = function CallToAction(_ref) {
46
+ var appName = _ref.appName,
47
+ message = _ref.message,
48
+ buttonLabel = _ref.buttonLabel;
49
+ return /*#__PURE__*/jsxRuntime.jsxs("div", {
50
+ className: "neeto-thank-you-configuration__cta",
51
+ children: [/*#__PURE__*/jsxRuntime.jsx("p", {
52
+ className: "neeto-thank-you-configuration__cta-message",
53
+ children: message
54
+ }), /*#__PURE__*/jsxRuntime.jsx("a", {
55
+ className: "neeto-thank-you-configuration__cta-button",
56
+ "data-testid": "neeto-thank-you-configuration-cta-button",
57
+ href: generateProductPageUrl(appName),
58
+ rel: "noopener noreferrer",
59
+ target: "_blank",
60
+ children: buttonLabel
61
+ })]
62
+ });
63
+ };
64
+
65
+ var SocialShare = reactUtils.withT(function (_ref) {
66
+ var t = _ref.t,
67
+ socialHandles = _ref.socialHandles,
68
+ publicLinkId = _ref.publicLinkId;
69
+ return /*#__PURE__*/jsxRuntime.jsxs("div", {
70
+ className: "neeto-thank-you-configuration__social-share",
71
+ children: [/*#__PURE__*/jsxRuntime.jsx("h4", {
72
+ className: "neeto-thank-you-configuration__social-share-title",
73
+ children: t("neetoThankYou.thankYou.socialShareHeading")
74
+ }), /*#__PURE__*/jsxRuntime.jsx("div", {
75
+ className: "neeto-thank-you-configuration-social-follow",
76
+ "data-testid": "social-share-icons",
77
+ children: socialHandles === null || socialHandles === void 0 ? void 0 : socialHandles.map(function (data, idx) {
78
+ var Icon = data.icon,
79
+ generateShareUrl = data.generateShareUrl;
80
+ return /*#__PURE__*/jsxRuntime.jsx("div", {
81
+ className: "neeto-thank-you-configuration-social-follow__item",
82
+ children: /*#__PURE__*/jsxRuntime.jsx("a", {
83
+ href: generateShareUrl(publicLinkId),
84
+ rel: "noreferrer",
85
+ target: "_blank",
86
+ children: /*#__PURE__*/jsxRuntime.jsx(Icon, {})
87
+ })
88
+ }, idx);
89
+ })
90
+ })]
91
+ });
92
+ });
93
+
94
+ exports.CallToAction = CallToAction;
95
+ exports.FORM_OPTIONS = FORM_OPTIONS;
96
+ exports.REDIRECT_DELAY = REDIRECT_DELAY;
97
+ exports.SocialShare = SocialShare;
98
+ exports.THANK_YOU_KINDS = THANK_YOU_KINDS;
99
+ exports.THANK_YOU_TEXT_ALIGNMENTS = THANK_YOU_TEXT_ALIGNMENTS;
100
+ //# sourceMappingURL=SocialShare-CVIbFf_m.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"SocialShare-CVIbFf_m.js","sources":["../../app/javascript/src/components/commons/constants.js","../../app/javascript/src/components/commons/utils.js","../../app/javascript/src/components/commons/CallToAction.jsx","../../app/javascript/src/components/ConfigureThankYou/Customize/SocialShare.jsx"],"sourcesContent":["import { t } from \"i18next\";\n\nexport const THANK_YOU_KINDS = {\n CUSTOM_MESSAGE: \"custom_message\",\n REDIRECT_TO_URL: \"redirect_to_url\",\n};\n\nexport const FORM_OPTIONS = {\n customize: {\n label: t(\"neetoThankYou.thankYou.customize\"),\n description: t(\"neetoThankYou.thankYou.customizeDescription\"),\n kind: THANK_YOU_KINDS.CUSTOM_MESSAGE,\n },\n externalLink: {\n label: t(\"neetoThankYou.thankYou.externalLink\"),\n description: t(\"neetoThankYou.thankYou.externalLinkDescription\"),\n kind: THANK_YOU_KINDS.REDIRECT_TO_URL,\n },\n};\n\nexport const THANK_YOU_TEXT_ALIGNMENTS = {\n left: \"left\",\n center: \"center\",\n};\n\nexport const REDIRECT_DELAY = 5;\n\nexport const NEETO = \"Neeto\";\nexport const NEETO_BASE_URL = \"https://www.neeto.com\";\nexport const UTM_SOURCE = \"utm_source=cta\";\nexport const UTM_CAMPAIGN_PARAM = \"utm_campaign\";\n","import { globalProps } from \"neetocommons/initializers\";\n\nimport {\n UTM_SOURCE,\n UTM_CAMPAIGN_PARAM,\n NEETO,\n NEETO_BASE_URL,\n} from \"./constants\";\n\nexport const generateUtmParams = () => {\n const subdomain = globalProps.organization?.subdomain;\n\n return `${UTM_SOURCE}${subdomain ? `&${UTM_CAMPAIGN_PARAM}=${subdomain}` : \"\"}`;\n};\n\nexport const generateProductPageUrl = appName => {\n const name = appName || globalProps.appName || NEETO;\n const utmParams = generateUtmParams();\n\n return `${NEETO_BASE_URL}/${name.toLowerCase()}?${utmParams}`;\n};\n","import { generateProductPageUrl } from \"./utils\";\n\nconst CallToAction = ({ appName, message, buttonLabel }) => (\n <div className=\"neeto-thank-you-configuration__cta\">\n <p className=\"neeto-thank-you-configuration__cta-message\">{message}</p>\n <a\n className=\"neeto-thank-you-configuration__cta-button\"\n data-testid=\"neeto-thank-you-configuration-cta-button\"\n href={generateProductPageUrl(appName)}\n rel=\"noopener noreferrer\"\n target=\"_blank\"\n >\n {buttonLabel}\n </a>\n </div>\n);\n\nexport default CallToAction;\n","import { withT } from \"neetocommons/react-utils\";\n\nconst SocialShare = withT(({ t, socialHandles, publicLinkId }) => (\n <div className=\"neeto-thank-you-configuration__social-share\">\n <h4 className=\"neeto-thank-you-configuration__social-share-title\">\n {t(\"neetoThankYou.thankYou.socialShareHeading\")}\n </h4>\n <div\n className=\"neeto-thank-you-configuration-social-follow\"\n data-testid=\"social-share-icons\"\n >\n {socialHandles?.map((data, idx) => {\n const { icon: Icon, generateShareUrl } = data;\n\n return (\n <div\n className=\"neeto-thank-you-configuration-social-follow__item\"\n key={idx}\n >\n <a\n href={generateShareUrl(publicLinkId)}\n rel=\"noreferrer\"\n target=\"_blank\"\n >\n <Icon />\n </a>\n </div>\n );\n })}\n </div>\n </div>\n));\n\nexport default SocialShare;\n"],"names":["THANK_YOU_KINDS","CUSTOM_MESSAGE","REDIRECT_TO_URL","FORM_OPTIONS","customize","label","t","description","kind","externalLink","THANK_YOU_TEXT_ALIGNMENTS","left","center","REDIRECT_DELAY","NEETO","NEETO_BASE_URL","UTM_SOURCE","UTM_CAMPAIGN_PARAM","generateUtmParams","_globalProps$organiza","subdomain","globalProps","organization","concat","generateProductPageUrl","appName","name","utmParams","toLowerCase","CallToAction","_ref","message","buttonLabel","_jsxs","className","children","_jsx","href","rel","target","SocialShare","withT","socialHandles","publicLinkId","map","data","idx","Icon","icon","generateShareUrl"],"mappings":";;;;;;;AAEO,IAAMA,eAAe,GAAG;AAC7BC,EAAAA,cAAc,EAAE,gBAAgB;AAChCC,EAAAA,eAAe,EAAE;AACnB;AAEO,IAAMC,YAAY,GAAG;AAC1BC,EAAAA,SAAS,EAAE;AACTC,IAAAA,KAAK,EAAEC,SAAC,CAAC,kCAAkC,CAAC;AAC5CC,IAAAA,WAAW,EAAED,SAAC,CAAC,6CAA6C,CAAC;IAC7DE,IAAI,EAAER,eAAe,CAACC;GACvB;AACDQ,EAAAA,YAAY,EAAE;AACZJ,IAAAA,KAAK,EAAEC,SAAC,CAAC,qCAAqC,CAAC;AAC/CC,IAAAA,WAAW,EAAED,SAAC,CAAC,gDAAgD,CAAC;IAChEE,IAAI,EAAER,eAAe,CAACE;AACxB;AACF;AAEO,IAAMQ,yBAAyB,GAAG;AACvCC,EAAAA,IAAI,EAAE,MAAM;AACZC,EAAAA,MAAM,EAAE;AACV;AAEO,IAAMC,cAAc,GAAG;AAEvB,I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AA,QAAA,eAG7DC,cAAA,CAAA,GAAA,EAAA;AACEC,YAAAA,IAAI,EAAEY,gBAAgB,CAACN,YAAY,CAAE;AACrCL,YAAAA,GAAG,EAAC,YAAY;AAChBC,YAAAA,MAAM,EAAC,QAAQ;AAAAJ,YAAAA,QAAA,eAEfC,cAAA,CAACW,IAAI,EAAA,EAAE;WACN;AAAC,SAAA,EARCD,GASF,CAAC;MAEV,CAAC;AAAC,KACC,CAAC;AAAA,GACH,CAAC;AAAA,CACP;;;;;;;;;"}
@@ -0,0 +1,7 @@
1
+ 'use strict';
2
+
3
+ var thankYou = require('./thank-you-BAOIUbgZ.js');
4
+
5
+ var css = "/*! tailwindcss v4.1.17 | MIT License | https://tailwindcss.com */@layer properties{@supports ((-webkit-hyphens:none) and (not (margin-trim:inline))) or ((-moz-orient:inline) and (not (color:rgb(from red r g b)))){*,::backdrop,:after,:before{--tw-rotate-x:initial;--tw-rotate-y:initial;--tw-rotate-z:initial;--tw-skew-x:initial;--tw-skew-y:initial;--tw-space-x-reverse:0;--tw-leading:initial;--tw-font-weight:initial;--tw-shadow:0 0 #0000;--tw-shadow-color:initial;--tw-shadow-alpha:100%;--tw-inset-shadow:0 0 #0000;--tw-inset-shadow-color:initial;--tw-inset-shadow-alpha:100%;--tw-ring-color:initial;--tw-ring-shadow:0 0 #0000;--tw-inset-ring-color:initial;--tw-inset-ring-shadow:0 0 #0000;--tw-ring-inset:initial;--tw-ring-offset-width:0px;--tw-ring-offset-color:#fff;--tw-ring-offset-shadow:0 0 #0000;--tw-outline-style:solid}}}@layer theme{:host,:root{--font-sans:ui-sans-serif,system-ui,sans-serif,\"Apple Color Emoji\",\"Segoe UI Emoji\",\"Segoe UI Symbol\",\"Noto Color Emoji\";--font-mono:ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,\"Liberation Mono\",\"Courier New\",monospace;--spacing:.25rem;--text-xs:.75rem;--text-xs--line-height:1.33333;--font-weight-normal:400;--leading-snug:1.375;--leading-normal:1.5;--default-font-family:var(--font-sans);--default-mono-font-family:var(--font-mono)}}@layer base{*,::backdrop,:after,:before{border:0 solid;box-sizing:border-box;margin:0;padding:0}::file-selector-button{border:0 solid;box-sizing:border-box;margin:0;padding:0}:host,html{-webkit-text-size-adjust:100%;font-feature-settings:normal;font-feature-settings:var(--default-font-feature-settings,normal);-webkit-tap-highlight-color:transparent;font-family:ui-sans-serif,system-ui,sans-serif,Apple Color Emoji,Segoe UI Emoji,Segoe UI Symbol,Noto Color Emoji;font-family:var(--default-font-family,ui-sans-serif,system-ui,sans-serif,\"Apple Color Emoji\",\"Segoe UI Emoji\",\"Segoe UI Symbol\",\"Noto Color Emoji\");font-variation-settings:normal;font-variation-settings:var(--default-font-variation-settings,normal);line-height:1.5;-moz-tab-size:4;-o-tab-size:4;tab-size:4}hr{border-top-width:1px;color:inherit;height:0}abbr:where([title]){-webkit-text-decoration:underline dotted;text-decoration:underline dotted}h1,h2,h3,h4,h5,h6{font-size:inherit;font-weight:inherit}a{color:inherit;-webkit-text-decoration:inherit;text-decoration:inherit}b,strong{font-weight:bolder}code,kbd,pre,samp{font-feature-settings:normal;font-feature-settings:var(--default-mono-font-feature-settings,normal);font-family:ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,Liberation Mono,Courier New,monospace;font-family:var(--default-mono-font-family,ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,\"Liberation Mono\",\"Courier New\",monospace);font-size:1em;font-variation-settings:normal;font-variation-settings:var(--default-mono-font-variation-settings,normal)}small{font-size:80%}sub,sup{font-size:75%;line-height:0;position:relative;vertical-align:baseline}sub{bottom:-.25em}sup{top:-.5em}table{border-collapse:collapse;border-color:inherit;text-indent:0}:-moz-focusring{outline:auto}progress{vertical-align:baseline}summary{display:list-item}menu,ol,ul{list-style:none}audio,canvas,embed,iframe,img,object,svg,video{display:block;vertical-align:middle}img,video{height:auto;max-width:100%}button,input,optgroup,select,textarea{font-feature-settings:inherit;background-color:#0000;border-radius:0;color:inherit;font:inherit;font-variation-settings:inherit;letter-spacing:inherit;opacity:1}::file-selector-button{font-feature-settings:inherit;background-color:#0000;border-radius:0;color:inherit;font:inherit;font-variation-settings:inherit;letter-spacing:inherit;opacity:1}:where(select:is([multiple],[size])) optgroup{font-weight:bolder}:where(select:is([multiple],[size])) optgroup option{padding-inline-start:20px}::file-selector-button{margin-inline-end:4px}::-moz-placeholder{opacity:1}::placeholder{opacity:1}@supports (not (-webkit-appearance:-apple-pay-button)) or (contain-intrinsic-size:1px){::-moz-placeholder{color:currentColor}::placeholder{color:currentColor}@supports (color:color-mix(in lab,red,red)){::-moz-placeholder{color:color-mix(in oklab,currentcolor 50%,transparent)}::placeholder{color:color-mix(in oklab,currentcolor 50%,transparent)}}}textarea{resize:vertical}::-webkit-search-decoration{-webkit-appearance:none}::-webkit-date-and-time-value{min-height:1lh;text-align:inherit}::-webkit-datetime-edit{display:inline-flex}::-webkit-datetime-edit-fields-wrapper{padding:0}::-webkit-datetime-edit,::-webkit-datetime-edit-day-field,::-webkit-datetime-edit-month-field,::-webkit-datetime-edit-year-field{padding-block:0}::-webkit-datetime-edit-hour-field,::-webkit-datetime-edit-millisecond-field,::-webkit-datetime-edit-minute-field,::-webkit-datetime-edit-second-field{padding-block:0}::-webkit-datetime-edit-meridiem-field{padding-block:0}::-webkit-calendar-picker-indicator{line-height:1}:-moz-ui-invalid{box-shadow:none}button,input:where([type=button],[type=reset],[type=submit]){-webkit-appearance:button;-moz-appearance:button;appearance:button}::file-selector-button{-webkit-appearance:button;-moz-appearance:button;appearance:button}::-webkit-inner-spin-button,::-webkit-outer-spin-button{height:auto}[hidden]:where(:not([hidden=until-found])){display:none!important}}@layer components;@layer utilities{.static{position:static}.sticky{position:sticky}.bottom-0{bottom:calc(var(--spacing)*0)}.isolate{isolation:isolate}.mt-6{margin-top:calc(var(--spacing)*6)}.mb-3{margin-bottom:calc(var(--spacing)*3)}.mb-6{margin-bottom:calc(var(--spacing)*6)}.block{display:block}.contents{display:contents}.flex{display:flex}.grid{display:grid}.inline{display:inline}.h-full{height:100%}.w-full{width:100%}.shrink-0{flex-shrink:0}.grow-0{flex-grow:0}.transform{transform:var(--tw-rotate-x,)var(--tw-rotate-y,)var(--tw-rotate-z,)var(--tw-skew-x,)var(--tw-skew-y,)}.grid-cols-1{grid-template-columns:repeat(1,minmax(0,1fr))}.flex-col{flex-direction:column}.items-center{align-items:center}.items-stretch{align-items:stretch}.justify-center{justify-content:center}.justify-start{justify-content:flex-start}.gap-2{gap:calc(var(--spacing)*2)}.gap-4{gap:calc(var(--spacing)*4)}.gap-6{gap:calc(var(--spacing)*6)}:where(.space-x-2>:not(:last-child)){--tw-space-x-reverse:0;margin-inline-end:calc(var(--spacing)*2*(1 - var(--tw-space-x-reverse)));margin-inline-start:calc(var(--spacing)*2*var(--tw-space-x-reverse))}:where(.space-x-4>:not(:last-child)){--tw-space-x-reverse:0;margin-inline-end:calc(var(--spacing)*4*(1 - var(--tw-space-x-reverse)));margin-inline-start:calc(var(--spacing)*4*var(--tw-space-x-reverse))}.overflow-y-auto{overflow-y:auto}.px-5{padding-inline:calc(var(--spacing)*5)}.px-6{padding-inline:calc(var(--spacing)*6)}.py-5{padding-block:calc(var(--spacing)*5)}.py-10{padding-block:calc(var(--spacing)*10)}.text-xs{font-size:var(--text-xs);line-height:var(--text-xs--line-height);line-height:var(--tw-leading,var(--text-xs--line-height))}.leading-normal{--tw-leading:var(--leading-normal);line-height:var(--leading-normal)}.leading-snug{--tw-leading:var(--leading-snug);line-height:var(--leading-snug)}.font-normal{--tw-font-weight:var(--font-weight-normal);font-weight:var(--font-weight-normal)}.lowercase{text-transform:lowercase}.shadow{--tw-shadow:0 1px 3px 0 var(--tw-shadow-color,#0000001a),0 1px 2px -1px var(--tw-shadow-color,#0000001a);box-shadow:var(--tw-inset-shadow),var(--tw-inset-ring-shadow),var(--tw-ring-offset-shadow),var(--tw-ring-shadow),var(--tw-shadow)}.outline{outline-style:var(--tw-outline-style);outline-width:1px}@media (min-width:40rem){.sm\\:grid-cols-2{grid-template-columns:repeat(2,minmax(0,1fr))}}@media (min-width:48rem){.md\\:hidden{display:none}.md\\:px-10{padding-inline:calc(var(--spacing)*10)}}@media (min-width:64rem){.lg\\:hidden{display:none}.lg\\:h-full{height:100%}.lg\\:w-1\\/2{width:50%}.lg\\:flex-row{flex-direction:row}.lg\\:overflow-y-auto{overflow-y:auto}}}:root{--neeto-thank-you-editor-content-color:0,0,0;--neeto-thank-you-background-color:255,255,255;--neeto-thank-you-background-image-position:center;--neeto-thank-you-gray-100:248,249,249;--neeto-thank-you-gray-800:31,31,31;--thankyou-branding-info-section-height:2.5rem}.neeto-thank-you-configuration-preview__wrapper{display:flex;flex-direction:column}.neeto-thank-you-configuration{height:100dvh;position:relative;width:100%}.neeto-thank-you-configuration__main{height:100%;overflow-y:auto}.neeto-thank-you-configuration__box{container:thank-you-configuration-box/inline-size;margin-inline:auto;margin-bottom:3.5rem;margin-top:3.5rem;max-width:51.25rem;padding:3.5rem .9375rem;position:relative;text-align:center;width:100%}.neeto-thank-you-configuration__redirect-message{font-size:.75rem;opacity:.75}.neeto-thank-you-configuration__redirect-failure-message a[href]{color:#2d36d4!important}.neeto-thank-you-configuration__default-img-wrap{font-size:2.5rem;text-align:center}.neeto-thank-you-configuration-alignment--left .neeto-thank-you-configuration__box{align-items:flex-start;text-align:start}.neeto-thank-you-configuration__title{font-size:2rem;line-height:1.25;margin:.67em 0}.neeto-thank-you-configuration__description{font-size:1rem;line-height:1.5;margin:0 0 2rem}.neeto-thank-you-configuration__description a[href]{color:#2d36d4}.neeto-thank-you-configuration__social-share{margin-top:2rem}.neeto-thank-you-configuration__social-share .neeto-thank-you-configuration-social-follow{align-items:center;display:inline-flex;flex-wrap:wrap;gap:1rem;justify-content:center}.neeto-thank-you-configuration__social-share .neeto-thank-you-configuration-social-follow__item{font-size:1.5rem;width:-moz-fit-content;width:fit-content}.neeto-thank-you-configuration__social-share-title{font-size:1.25rem;font-weight:500;line-height:1.2;margin:.8rem 0}.neeto-thank-you-configuration__resubmit{border-bottom:1px solid;font-weight:600}.neeto-thank-you-configuration__box--is-cta-visible{padding-bottom:.9375rem}.neeto-thank-you-configuration__cta{align-items:center;background-color:#f6f7f8;border:1px solid #025e7033;border-radius:.5rem;display:flex;flex-wrap:wrap;gap:.5rem;justify-content:space-between;margin-top:4rem;padding:1.25rem}@container thank-you-configuration-box not (min-width:780px){.neeto-thank-you-configuration__cta{gap:1rem;justify-content:center!important}}.neeto-thank-you-configuration__cta .neeto-thank-you-configuration__cta-message{color:#344054!important;font-size:1rem;font-weight:400;line-height:1.5}.neeto-thank-you-configuration__cta-button{align-items:center;background-color:#008068!important;border-radius:.25rem;color:#fff!important;cursor:pointer;display:flex;font-size:1rem!important;font-weight:500;height:2.5rem;justify-content:center;line-height:1.2;opacity:1!important;padding:.25rem 1rem;text-decoration:none;text-decoration:none!important;transition:all .3s;-webkit-user-select:none;-moz-user-select:none;user-select:none;white-space:nowrap}.neeto-thank-you-configuration__cta-button:focus,.neeto-thank-you-configuration__cta-button:focus-visible,.neeto-thank-you-configuration__cta-button:hover{background-color:#007a64!important}.neeto-thankyou-nano__right-panel .neeto-molecules-browser-preview{height:100%;min-height:500px}.neeto-thankyou-nano__right-panel .neeto-molecules-browser-preview .neeto-thank-you-configuration{flex-grow:1;height:100%;max-height:100%}.neeto-thankyou-nano__right-panel .neeto-molecules-browser-preview .neeto-thank-you-configuration .neeto-thank-you-configuration__main{height:100%}.neeto-thankyou-nano__right-panel .neeto-molecules-browser-preview .neeto-thank-you-configuration__branding-wrapper{position:absolute}.neeto-thankyou-nano__right-panel .neeto-molecules-browser-preview .neeto-thank-you-configuration__box{pointer-events:none}.neeto-thank-you-configuration__branding-wrapper{bottom:.75rem;inset-inline-start:.75rem;position:fixed}.neeto-thank-you-configuration__draft-preview-message{font-size:.75rem;line-height:1.5}.neeto-thank-you-configuration-radio__item{align-items:flex-start;background-color:rgb(var(--neeto-ui-white));border:1px solid rgb(var(--neeto-ui-gray-300));border-radius:var(--neeto-ui-rounded);padding:.75rem 1rem}.neeto-thank-you-configuration-radio__item.neeto-ui-radio__item:not(:last-child){margin-inline-end:0!important}.neeto-thank-you-configuration-radio__item.neeto-ui-radio__item{align-items:flex-start!important}.neeto-thank-you-configuration-radio__item.neeto-ui-radio__item .neeto-ui-radio{margin-top:.1875rem}.neeto-thank-you-configuration-radio__item.active{border:1.5px solid rgb(var(--neeto-ui-primary-800))}@property --tw-rotate-x{syntax:\"*\";inherits:false}@property --tw-rotate-y{syntax:\"*\";inherits:false}@property --tw-rotate-z{syntax:\"*\";inherits:false}@property --tw-skew-x{syntax:\"*\";inherits:false}@property --tw-skew-y{syntax:\"*\";inherits:false}@property --tw-space-x-reverse{syntax:\"*\";inherits:false;initial-value:0}@property --tw-leading{syntax:\"*\";inherits:false}@property --tw-font-weight{syntax:\"*\";inherits:false}@property --tw-shadow{syntax:\"*\";inherits:false;initial-value:0 0 #0000}@property --tw-shadow-color{syntax:\"*\";inherits:false}@property --tw-shadow-alpha{syntax:\"<percentage>\";inherits:false;initial-value:100%}@property --tw-inset-shadow{syntax:\"*\";inherits:false;initial-value:0 0 #0000}@property --tw-inset-shadow-color{syntax:\"*\";inherits:false}@property --tw-inset-shadow-alpha{syntax:\"<percentage>\";inherits:false;initial-value:100%}@property --tw-ring-color{syntax:\"*\";inherits:false}@property --tw-ring-shadow{syntax:\"*\";inherits:false;initial-value:0 0 #0000}@property --tw-inset-ring-color{syntax:\"*\";inherits:false}@property --tw-inset-ring-shadow{syntax:\"*\";inherits:false;initial-value:0 0 #0000}@property --tw-ring-inset{syntax:\"*\";inherits:false}@property --tw-ring-offset-width{syntax:\"<length>\";inherits:false;initial-value:0}@property --tw-ring-offset-color{syntax:\"*\";inherits:false;initial-value:#fff}@property --tw-ring-offset-shadow{syntax:\"*\";inherits:false;initial-value:0 0 #0000}@property --tw-outline-style{syntax:\"*\";inherits:false;initial-value:solid}";
6
+ thankYou.n(css,{});
7
+ //# sourceMappingURL=application-S-s0L8VC.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"application-S-s0L8VC.js","sources":[],"sourcesContent":[],"names":[],"mappings":";;;;;;;"}
@@ -5,7 +5,7 @@ var ramda = require('ramda');
5
5
 
6
6
  var _globalProps$organiza;
7
7
  var VARIABLE_SPAN_REGEX = /<span[^>]*data-variable[^>]*data-id="([^"]+)"[^>]*>{{([^}]+)}}<\/span>/g;
8
- var IS_PRO_ORGANIZATION = ramda.includes((_globalProps$organiza = initializers.globalProps.organization) === null || _globalProps$organiza === void 0 ? void 0 : _globalProps$organiza.subdomain, initializers.globalProps.proOrganizations || []);
8
+ var IS_PRO_ORGANIZATION = initializers.globalProps.isProOrganization || ramda.includes((_globalProps$organiza = initializers.globalProps.organization) === null || _globalProps$organiza === void 0 ? void 0 : _globalProps$organiza.subdomain, initializers.globalProps.proOrganizations || []);
9
9
 
10
10
  exports.IS_PRO_ORGANIZATION = IS_PRO_ORGANIZATION;
11
11
  exports.VARIABLE_SPAN_REGEX = VARIABLE_SPAN_REGEX;
@@ -1 +1 @@
1
- {"version":3,"file":"constants.js","sources":["../../app/javascript/src/components/constants.js"],"sourcesContent":["import { globalProps } from \"neetocommons/initializers\";\nimport { includes } from \"ramda\";\n\nexport const VARIABLE_SPAN_REGEX =\n /<span[^>]*data-variable[^>]*data-id=\"([^\"]+)\"[^>]*>{{([^}]+)}}<\\/span>/g;\n\nexport const IS_PRO_ORGANIZATION = includes(\n globalProps.organization?.subdomain,\n globalProps.proOrganizations || []\n);\n"],"names":["VARIABLE_SPAN_REGEX","IS_PRO_ORGANIZATION","includes","_globalProps$organiza","globalProps","organization","subdomain","proOrganizations"],"mappings":";;;;;;AAGO,IAAMA,mBAAmB,GAC9B;AAEK,IAAMC,mBAAmB,GAAGC,cAAQ,EAAAC,qBAAA,GACzCC,wBAAW,CAACC,YAAY,MAAA,IAAA,IAAAF,qBAAA,KAAA,MAAA,GAAA,MAAA,GAAxBA,qBAAA,CAA0BG,SAAS,EACnCF,wBAAW,CAACG,gBAAgB,IAAI,EAClC;;;;;"}
1
+ {"version":3,"file":"constants.js","sources":["../../app/javascript/src/components/constants.js"],"sourcesContent":["import { globalProps } from \"neetocommons/initializers\";\nimport { includes } from \"ramda\";\n\nexport const VARIABLE_SPAN_REGEX =\n /<span[^>]*data-variable[^>]*data-id=\"([^\"]+)\"[^>]*>{{([^}]+)}}<\\/span>/g;\n\nexport const IS_PRO_ORGANIZATION =\n globalProps.isProOrganization ||\n includes(\n globalProps.organization?.subdomain,\n globalProps.proOrganizations || []\n );\n"],"names":["VARIABLE_SPAN_REGEX","IS_PRO_ORGANIZATION","globalProps","isProOrganization","includes","_globalProps$organiza","organization","subdomain","proOrganizations"],"mappings":";;;;;;AAGO,IAAMA,mBAAmB,GAC9B;AAEK,IAAMC,mBAAmB,GAC9BC,wBAAW,CAACC,iBAAiB,IAC7BC,cAAQ,CAAA,CAAAC,qBAAA,GACNH,wBAAW,CAACI,YAAY,MAAA,IAAA,IAAAD,qBAAA,KAAA,MAAA,GAAA,MAAA,GAAxBA,qBAAA,CAA0BE,SAAS,EACnCL,wBAAW,CAACM,gBAAgB,IAAI,EAClC;;;;;"}
package/dist/cjs/index.js CHANGED
@@ -4,8 +4,15 @@ var ConfigureThankYou = require('./ConfigureThankYou.js');
4
4
  var ShowThankYou = require('./ShowThankYou.js');
5
5
  var useThankYouConfigurationApi = require('./useThankYouConfigurationApi-Bx8hQqrm.js');
6
6
  var useThankYouPageApi = require('./useThankYouPageApi-DeHETkcA.js');
7
- var SocialShare = require('./SocialShare-abuXAsLb.js');
7
+ require('./application-S-s0L8VC.js');
8
8
  require('@bigbinary/neeto-cist');
9
+ require('./SocialShare-CVIbFf_m.js');
10
+ require('@bigbinary/neeto-commons-frontend/initializers');
11
+ require('i18next');
12
+ require('react/jsx-runtime');
13
+ require('@bigbinary/neeto-commons-frontend/react-utils');
14
+ require('./thank-you-BYHzj8zD.js');
15
+ require('./thank-you-BAOIUbgZ.js');
9
16
  require('@babel/runtime/helpers/defineProperty');
10
17
  require('@babel/runtime/helpers/slicedToArray');
11
18
  require('react');
@@ -23,23 +30,19 @@ require('@bigbinary/neeto-editor/FormikEditor');
23
30
  require('@bigbinary/neetoui/formik/Input');
24
31
  require('@bigbinary/neetoui/formik/Switch');
25
32
  require('react-i18next');
26
- require('@bigbinary/neeto-commons-frontend/react-utils');
27
33
  require('@bigbinary/neetoui/Button');
28
34
  require('@bigbinary/neetoui/Typography');
29
35
  require('@bigbinary/neetoui/Modal');
30
- require('react/jsx-runtime');
31
36
  require('@bigbinary/neeto-molecules/BrowserPreview');
32
37
  require('./BrandingInfo-quX3BPdQ.js');
33
38
  require('@bigbinary/neeto-molecules/MadeWith');
34
39
  require('./constants.js');
35
- require('@bigbinary/neeto-commons-frontend/initializers');
36
40
  require('@bigbinary/neeto-editor/EditorContent');
37
41
  require('@bigbinary/neeto-icons/Link');
38
42
  require('@bigbinary/neeto-molecules/HelpPopover');
39
43
  require('@babel/runtime/helpers/objectWithoutProperties');
40
44
  require('@bigbinary/neetoui/Label');
41
45
  require('@bigbinary/neeto-molecules/Header');
42
- require('i18next');
43
46
  require('@bigbinary/neeto-editor/utils');
44
47
  require('yup');
45
48
  require('@bigbinary/neeto-molecules/PageLoader');
@@ -50,8 +53,7 @@ require('@bigbinary/neeto-commons-frontend/utils');
50
53
  require('./index-Bp2NY-mY.js');
51
54
  require('./query.js');
52
55
 
53
- var css = "/*! tailwindcss v4.1.17 | MIT License | https://tailwindcss.com */@layer properties{@supports ((-webkit-hyphens:none) and (not (margin-trim:inline))) or ((-moz-orient:inline) and (not (color:rgb(from red r g b)))){*,::backdrop,:after,:before{--tw-rotate-x:initial;--tw-rotate-y:initial;--tw-rotate-z:initial;--tw-skew-x:initial;--tw-skew-y:initial;--tw-space-x-reverse:0;--tw-leading:initial;--tw-font-weight:initial;--tw-shadow:0 0 #0000;--tw-shadow-color:initial;--tw-shadow-alpha:100%;--tw-inset-shadow:0 0 #0000;--tw-inset-shadow-color:initial;--tw-inset-shadow-alpha:100%;--tw-ring-color:initial;--tw-ring-shadow:0 0 #0000;--tw-inset-ring-color:initial;--tw-inset-ring-shadow:0 0 #0000;--tw-ring-inset:initial;--tw-ring-offset-width:0px;--tw-ring-offset-color:#fff;--tw-ring-offset-shadow:0 0 #0000}}}@layer theme{:host,:root{--font-sans:ui-sans-serif,system-ui,sans-serif,\"Apple Color Emoji\",\"Segoe UI Emoji\",\"Segoe UI Symbol\",\"Noto Color Emoji\";--font-mono:ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,\"Liberation Mono\",\"Courier New\",monospace;--spacing:.25rem;--text-xs:.75rem;--text-xs--line-height:1.33333;--font-weight-normal:400;--leading-snug:1.375;--default-font-family:var(--font-sans);--default-mono-font-family:var(--font-mono)}}@layer base{*,::backdrop,:after,:before{border:0 solid;box-sizing:border-box;margin:0;padding:0}::file-selector-button{border:0 solid;box-sizing:border-box;margin:0;padding:0}:host,html{-webkit-text-size-adjust:100%;font-feature-settings:normal;font-feature-settings:var(--default-font-feature-settings,normal);-webkit-tap-highlight-color:transparent;font-family:ui-sans-serif,system-ui,sans-serif,Apple Color Emoji,Segoe UI Emoji,Segoe UI Symbol,Noto Color Emoji;font-family:var(--default-font-family,ui-sans-serif,system-ui,sans-serif,\"Apple Color Emoji\",\"Segoe UI Emoji\",\"Segoe UI Symbol\",\"Noto Color Emoji\");font-variation-settings:normal;font-variation-settings:var(--default-font-variation-settings,normal);line-height:1.5;-moz-tab-size:4;-o-tab-size:4;tab-size:4}hr{border-top-width:1px;color:inherit;height:0}abbr:where([title]){-webkit-text-decoration:underline dotted;text-decoration:underline dotted}h1,h2,h3,h4,h5,h6{font-size:inherit;font-weight:inherit}a{color:inherit;-webkit-text-decoration:inherit;text-decoration:inherit}b,strong{font-weight:bolder}code,kbd,pre,samp{font-feature-settings:normal;font-feature-settings:var(--default-mono-font-feature-settings,normal);font-family:ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,Liberation Mono,Courier New,monospace;font-family:var(--default-mono-font-family,ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,\"Liberation Mono\",\"Courier New\",monospace);font-size:1em;font-variation-settings:normal;font-variation-settings:var(--default-mono-font-variation-settings,normal)}small{font-size:80%}sub,sup{font-size:75%;line-height:0;position:relative;vertical-align:baseline}sub{bottom:-.25em}sup{top:-.5em}table{border-collapse:collapse;border-color:inherit;text-indent:0}:-moz-focusring{outline:auto}progress{vertical-align:baseline}summary{display:list-item}menu,ol,ul{list-style:none}audio,canvas,embed,iframe,img,object,svg,video{display:block;vertical-align:middle}img,video{height:auto;max-width:100%}button,input,optgroup,select,textarea{font-feature-settings:inherit;background-color:#0000;border-radius:0;color:inherit;font:inherit;font-variation-settings:inherit;letter-spacing:inherit;opacity:1}::file-selector-button{font-feature-settings:inherit;background-color:#0000;border-radius:0;color:inherit;font:inherit;font-variation-settings:inherit;letter-spacing:inherit;opacity:1}:where(select:is([multiple],[size])) optgroup{font-weight:bolder}:where(select:is([multiple],[size])) optgroup option{padding-inline-start:20px}::file-selector-button{margin-inline-end:4px}::-moz-placeholder{opacity:1}::placeholder{opacity:1}@supports (not (-webkit-appearance:-apple-pay-button)) or (contain-intrinsic-size:1px){::-moz-placeholder{color:currentColor}::placeholder{color:currentColor}@supports (color:color-mix(in lab,red,red)){::-moz-placeholder{color:color-mix(in oklab,currentcolor 50%,transparent)}::placeholder{color:color-mix(in oklab,currentcolor 50%,transparent)}}}textarea{resize:vertical}::-webkit-search-decoration{-webkit-appearance:none}::-webkit-date-and-time-value{min-height:1lh;text-align:inherit}::-webkit-datetime-edit{display:inline-flex}::-webkit-datetime-edit-fields-wrapper{padding:0}::-webkit-datetime-edit,::-webkit-datetime-edit-day-field,::-webkit-datetime-edit-month-field,::-webkit-datetime-edit-year-field{padding-block:0}::-webkit-datetime-edit-hour-field,::-webkit-datetime-edit-millisecond-field,::-webkit-datetime-edit-minute-field,::-webkit-datetime-edit-second-field{padding-block:0}::-webkit-datetime-edit-meridiem-field{padding-block:0}::-webkit-calendar-picker-indicator{line-height:1}:-moz-ui-invalid{box-shadow:none}button,input:where([type=button],[type=reset],[type=submit]){-webkit-appearance:button;-moz-appearance:button;appearance:button}::file-selector-button{-webkit-appearance:button;-moz-appearance:button;appearance:button}::-webkit-inner-spin-button,::-webkit-outer-spin-button{height:auto}[hidden]:where(:not([hidden=until-found])){display:none!important}}@layer components;@layer utilities{.static{position:static}.sticky{position:sticky}.bottom-0{bottom:calc(var(--spacing)*0)}.isolate{isolation:isolate}.mt-6{margin-top:calc(var(--spacing)*6)}.mb-3{margin-bottom:calc(var(--spacing)*3)}.mb-6{margin-bottom:calc(var(--spacing)*6)}.block{display:block}.contents{display:contents}.flex{display:flex}.grid{display:grid}.inline{display:inline}.h-full{height:100%}.w-full{width:100%}.shrink-0{flex-shrink:0}.grow-0{flex-grow:0}.transform{transform:var(--tw-rotate-x,)var(--tw-rotate-y,)var(--tw-rotate-z,)var(--tw-skew-x,)var(--tw-skew-y,)}.grid-cols-1{grid-template-columns:repeat(1,minmax(0,1fr))}.flex-col{flex-direction:column}.items-center{align-items:center}.items-stretch{align-items:stretch}.justify-center{justify-content:center}.justify-start{justify-content:flex-start}.gap-2{gap:calc(var(--spacing)*2)}.gap-4{gap:calc(var(--spacing)*4)}.gap-6{gap:calc(var(--spacing)*6)}:where(.space-x-2>:not(:last-child)){--tw-space-x-reverse:0;margin-inline-end:calc(var(--spacing)*2*(1 - var(--tw-space-x-reverse)));margin-inline-start:calc(var(--spacing)*2*var(--tw-space-x-reverse))}:where(.space-x-4>:not(:last-child)){--tw-space-x-reverse:0;margin-inline-end:calc(var(--spacing)*4*(1 - var(--tw-space-x-reverse)));margin-inline-start:calc(var(--spacing)*4*var(--tw-space-x-reverse))}.overflow-y-auto{overflow-y:auto}.px-5{padding-inline:calc(var(--spacing)*5)}.px-6{padding-inline:calc(var(--spacing)*6)}.py-5{padding-block:calc(var(--spacing)*5)}.py-10{padding-block:calc(var(--spacing)*10)}.text-xs{font-size:var(--text-xs);line-height:var(--text-xs--line-height);line-height:var(--tw-leading,var(--text-xs--line-height))}.leading-snug{--tw-leading:var(--leading-snug);line-height:var(--leading-snug)}.font-normal{--tw-font-weight:var(--font-weight-normal);font-weight:var(--font-weight-normal)}.lowercase{text-transform:lowercase}.shadow{--tw-shadow:0 1px 3px 0 var(--tw-shadow-color,#0000001a),0 1px 2px -1px var(--tw-shadow-color,#0000001a);box-shadow:var(--tw-inset-shadow),var(--tw-inset-ring-shadow),var(--tw-ring-offset-shadow),var(--tw-ring-shadow),var(--tw-shadow)}@media (min-width:40rem){.sm\\:grid-cols-2{grid-template-columns:repeat(2,minmax(0,1fr))}}@media (min-width:48rem){.md\\:hidden{display:none}.md\\:px-10{padding-inline:calc(var(--spacing)*10)}}@media (min-width:64rem){.lg\\:hidden{display:none}.lg\\:h-full{height:100%}.lg\\:w-1\\/2{width:50%}.lg\\:flex-row{flex-direction:row}.lg\\:overflow-y-auto{overflow-y:auto}}}:root{--neeto-thank-you-editor-content-color:0,0,0;--neeto-thank-you-background-color:255,255,255;--neeto-thank-you-background-image-position:center;--neeto-thank-you-gray-100:248,249,249;--neeto-thank-you-gray-800:31,31,31;--thankyou-branding-info-section-height:2.5rem}.neeto-thank-you-configuration-preview__wrapper{display:flex;flex-direction:column}.neeto-thank-you-configuration{height:100dvh;position:relative;width:100%}.neeto-thank-you-configuration__main{height:100%;overflow-y:auto}.neeto-thank-you-configuration__box{container:thank-you-configuration-box/inline-size;margin-inline:auto;margin-bottom:3.5rem;margin-top:3.5rem;max-width:51.25rem;padding:3.5rem .9375rem;position:relative;text-align:center;width:100%}.neeto-thank-you-configuration__redirect-message{font-size:.75rem;opacity:.75}.neeto-thank-you-configuration__redirect-failure-message a[href]{color:#2d36d4!important}.neeto-thank-you-configuration__default-img-wrap{font-size:2.5rem;text-align:center}.neeto-thank-you-configuration-alignment--left .neeto-thank-you-configuration__box{align-items:flex-start;text-align:start}.neeto-thank-you-configuration__title{font-size:2rem;line-height:1.25;margin:.67em 0}.neeto-thank-you-configuration__description{font-size:1rem;line-height:1.5;margin:0 0 2rem}.neeto-thank-you-configuration__description a[href]{color:#2d36d4}.neeto-thank-you-configuration__social-share{margin-top:2rem}.neeto-thank-you-configuration__social-share .neeto-thank-you-configuration-social-follow{align-items:center;display:inline-flex;flex-wrap:wrap;gap:1rem;justify-content:center}.neeto-thank-you-configuration__social-share .neeto-thank-you-configuration-social-follow__item{font-size:1.5rem;width:-moz-fit-content;width:fit-content}.neeto-thank-you-configuration__social-share-title{font-size:1.25rem;font-weight:500;line-height:1.2;margin:.8rem 0}.neeto-thank-you-configuration__resubmit{border-bottom:1px solid;font-weight:600}.neeto-thank-you-configuration__box--is-cta-visible{padding-bottom:.9375rem}.neeto-thank-you-configuration__cta{align-items:center;background-color:#f6f7f8;border:1px solid #025e7033;border-radius:.5rem;display:flex;flex-wrap:wrap;gap:.5rem;justify-content:space-between;margin-top:4rem;padding:1.25rem}@container thank-you-configuration-box not (min-width:780px){.neeto-thank-you-configuration__cta{gap:1rem;justify-content:center!important}}.neeto-thank-you-configuration__cta .neeto-thank-you-configuration__cta-message{color:#344054!important;font-size:1rem;font-weight:400;line-height:1.5}.neeto-thank-you-configuration__cta-button{align-items:center;background-color:#008068!important;border-radius:.25rem;color:#fff!important;cursor:pointer;display:flex;font-size:1rem!important;font-weight:500;height:2.5rem;justify-content:center;line-height:1.2;opacity:1!important;padding:.25rem 1rem;text-decoration:none;text-decoration:none!important;transition:all .3s;-webkit-user-select:none;-moz-user-select:none;user-select:none;white-space:nowrap}.neeto-thank-you-configuration__cta-button:focus,.neeto-thank-you-configuration__cta-button:focus-visible,.neeto-thank-you-configuration__cta-button:hover{background-color:#007a64!important}.neeto-thankyou-nano__right-panel .neeto-molecules-browser-preview{height:100%;min-height:500px}.neeto-thankyou-nano__right-panel .neeto-molecules-browser-preview .neeto-thank-you-configuration{flex-grow:1;height:100%;max-height:100%}.neeto-thankyou-nano__right-panel .neeto-molecules-browser-preview .neeto-thank-you-configuration .neeto-thank-you-configuration__main{height:100%}.neeto-thankyou-nano__right-panel .neeto-molecules-browser-preview .neeto-thank-you-configuration__branding-wrapper{position:absolute}.neeto-thankyou-nano__right-panel .neeto-molecules-browser-preview .neeto-thank-you-configuration__box{pointer-events:none}.neeto-thank-you-configuration__branding-wrapper{bottom:.75rem;inset-inline-start:.75rem;position:fixed}.neeto-thank-you-configuration__draft-preview-message{font-size:.75rem;line-height:1.5}.neeto-thank-you-configuration-radio__item{align-items:flex-start;background-color:rgb(var(--neeto-ui-white));border:1px solid rgb(var(--neeto-ui-gray-300));border-radius:var(--neeto-ui-rounded);padding:.75rem 1rem}.neeto-thank-you-configuration-radio__item.neeto-ui-radio__item:not(:last-child){margin-inline-end:0!important}.neeto-thank-you-configuration-radio__item.neeto-ui-radio__item{align-items:flex-start!important}.neeto-thank-you-configuration-radio__item.neeto-ui-radio__item .neeto-ui-radio{margin-top:.1875rem}.neeto-thank-you-configuration-radio__item.active{border:1.5px solid rgb(var(--neeto-ui-primary-800))}@property --tw-rotate-x{syntax:\"*\";inherits:false}@property --tw-rotate-y{syntax:\"*\";inherits:false}@property --tw-rotate-z{syntax:\"*\";inherits:false}@property --tw-skew-x{syntax:\"*\";inherits:false}@property --tw-skew-y{syntax:\"*\";inherits:false}@property --tw-space-x-reverse{syntax:\"*\";inherits:false;initial-value:0}@property --tw-leading{syntax:\"*\";inherits:false}@property --tw-font-weight{syntax:\"*\";inherits:false}@property --tw-shadow{syntax:\"*\";inherits:false;initial-value:0 0 #0000}@property --tw-shadow-color{syntax:\"*\";inherits:false}@property --tw-shadow-alpha{syntax:\"<percentage>\";inherits:false;initial-value:100%}@property --tw-inset-shadow{syntax:\"*\";inherits:false;initial-value:0 0 #0000}@property --tw-inset-shadow-color{syntax:\"*\";inherits:false}@property --tw-inset-shadow-alpha{syntax:\"<percentage>\";inherits:false;initial-value:100%}@property --tw-ring-color{syntax:\"*\";inherits:false}@property --tw-ring-shadow{syntax:\"*\";inherits:false;initial-value:0 0 #0000}@property --tw-inset-ring-color{syntax:\"*\";inherits:false}@property --tw-inset-ring-shadow{syntax:\"*\";inherits:false;initial-value:0 0 #0000}@property --tw-ring-inset{syntax:\"*\";inherits:false}@property --tw-ring-offset-width{syntax:\"<length>\";inherits:false;initial-value:0}@property --tw-ring-offset-color{syntax:\"*\";inherits:false;initial-value:#fff}@property --tw-ring-offset-shadow{syntax:\"*\";inherits:false;initial-value:0 0 #0000}";
54
- SocialShare.n(css,{});
56
+
55
57
 
56
58
  exports.ConfigureThankYou = ConfigureThankYou;
57
59
  exports.ShowThankYou = ShowThankYou;
@@ -1,98 +1,9 @@
1
- import { globalProps } from '@bigbinary/neeto-commons-frontend/initializers';
2
- import { t as t$1 } from 'i18next';
3
- import { jsxs, jsx } from 'react/jsx-runtime';
4
- import { withT } from '@bigbinary/neeto-commons-frontend/react-utils';
5
-
6
- var THANK_YOU_KINDS = {
7
- CUSTOM_MESSAGE: "custom_message",
8
- REDIRECT_TO_URL: "redirect_to_url"
9
- };
10
- var FORM_OPTIONS = {
11
- customize: {
12
- label: t$1("neetoThankYou.thankYou.customize"),
13
- description: t$1("neetoThankYou.thankYou.customizeDescription"),
14
- kind: THANK_YOU_KINDS.CUSTOM_MESSAGE
15
- },
16
- externalLink: {
17
- label: t$1("neetoThankYou.thankYou.externalLink"),
18
- description: t$1("neetoThankYou.thankYou.externalLinkDescription"),
19
- kind: THANK_YOU_KINDS.REDIRECT_TO_URL
20
- }
21
- };
22
- var THANK_YOU_TEXT_ALIGNMENTS = {
23
- left: "left",
24
- center: "center"
25
- };
26
- var REDIRECT_DELAY = 5;
27
- var NEETO = "Neeto";
28
- var NEETO_BASE_URL = "https://www.neeto.com";
29
- var UTM_SOURCE = "utm_source=cta";
30
- var UTM_CAMPAIGN_PARAM = "utm_campaign";
1
+ 'use strict';
31
2
 
32
3
  var e=[],t=[];function n(n,r){if(n&&"undefined"!=typeof document){var a,s=true===r.prepend?"prepend":"append",d=true===r.singleTag,i="string"==typeof r.container?document.querySelector(r.container):document.getElementsByTagName("head")[0];if(d){var u=e.indexOf(i);-1===u&&(u=e.push(i)-1,t[u]={}),a=t[u]&&t[u][s]?t[u][s]:t[u][s]=c();}else a=c();65279===n.charCodeAt(0)&&(n=n.substring(1)),a.styleSheet?a.styleSheet.cssText+=n:a.appendChild(document.createTextNode(n));}function c(){var e=document.createElement("style");if(e.setAttribute("type","text/css"),r.attributes)for(var t=Object.keys(r.attributes),n=0;n<t.length;n++)e.setAttribute(t[n],r.attributes[t[n]]);var a="prepend"===s?"afterbegin":"beforeend";return i.insertAdjacentElement(a,e),e}}
33
4
 
34
5
  var css = ".neeto-thank-you-configuration-preview__wrapper{display:flex;flex-direction:column}.neeto-thank-you-configuration{height:100dvh;position:relative;width:100%}.neeto-thank-you-configuration__main{height:100%;overflow-y:auto}.neeto-thank-you-configuration__box{container-name:thank-you-configuration-box;container-type:inline-size;margin-inline-end:auto;margin-inline-start:auto;margin-bottom:3.5rem;margin-top:3.5rem;max-width:51.25rem;padding:3.5rem .9375rem;position:relative;text-align:center;width:100%}.neeto-thank-you-configuration__redirect-message{font-size:.75rem;opacity:.75}.neeto-thank-you-configuration__redirect-failure-message a[href]{color:#2d36d4!important}.neeto-thank-you-configuration__default-img-wrap{font-size:2.5rem;text-align:center}.neeto-thank-you-configuration-alignment--left .neeto-thank-you-configuration__box{align-items:flex-start;text-align:start}.neeto-thank-you-configuration__title{font-size:2rem;line-height:1.25;margin:.67em 0}.neeto-thank-you-configuration__description{font-size:1rem;line-height:1.5;margin:0 0 2rem}.neeto-thank-you-configuration__description a[href]{color:#2d36d4}.neeto-thank-you-configuration__social-share{margin-top:2rem}.neeto-thank-you-configuration__social-share .neeto-thank-you-configuration-social-follow{align-items:center;display:inline-flex;flex-wrap:wrap;gap:1rem;justify-content:center}.neeto-thank-you-configuration__social-share .neeto-thank-you-configuration-social-follow__item{font-size:1.5rem;width:-moz-fit-content;width:fit-content}.neeto-thank-you-configuration__social-share-title{font-size:1.25rem;font-weight:500;line-height:1.2;margin:.8rem 0}.neeto-thank-you-configuration__resubmit{border-bottom:1px solid;font-weight:600}.neeto-thank-you-configuration__box--is-cta-visible{padding-bottom:.9375rem}.neeto-thank-you-configuration__cta{align-items:center;background-color:#f6f7f8;border:1px solid rgba(2,94,112,.2);border-radius:.5rem;display:flex;flex-wrap:wrap;gap:.5rem;justify-content:space-between;margin-top:4rem;padding:1.25rem}@container thank-you-configuration-box (width < 780px){.neeto-thank-you-configuration__cta{gap:1rem;justify-content:center!important}}.neeto-thank-you-configuration__cta .neeto-thank-you-configuration__cta-message{color:#344054!important;font-size:1rem;font-weight:400;line-height:1.5}.neeto-thank-you-configuration__cta-button{align-items:center;background-color:#008068!important;border-radius:.25rem;color:#fff!important;cursor:pointer;display:flex;font-size:1rem!important;font-weight:500;height:2.5rem;justify-content:center;line-height:1.2;opacity:1!important;padding:.25rem 1rem;text-decoration:none;text-decoration:none!important;transition:all .3s ease;-webkit-user-select:none;-moz-user-select:none;user-select:none;white-space:nowrap}.neeto-thank-you-configuration__cta-button:focus,.neeto-thank-you-configuration__cta-button:focus-visible,.neeto-thank-you-configuration__cta-button:hover{background-color:#007a64!important}.neeto-thankyou-nano__right-panel .neeto-molecules-browser-preview{height:100%;min-height:500px}.neeto-thankyou-nano__right-panel .neeto-molecules-browser-preview .neeto-thank-you-configuration{flex-grow:1;height:100%;max-height:100%}.neeto-thankyou-nano__right-panel .neeto-molecules-browser-preview .neeto-thank-you-configuration .neeto-thank-you-configuration__main{height:100%}.neeto-thankyou-nano__right-panel .neeto-molecules-browser-preview .neeto-thank-you-configuration__branding-wrapper{position:absolute}.neeto-thankyou-nano__right-panel .neeto-molecules-browser-preview .neeto-thank-you-configuration__box{pointer-events:none}.neeto-thank-you-configuration__branding-wrapper{bottom:.75rem;inset-inline-start:.75rem;position:fixed}.neeto-thank-you-configuration__draft-preview-message{font-size:.75rem;line-height:1.5}";
35
6
  n(css,{});
36
7
 
37
- var generateUtmParams = function generateUtmParams() {
38
- var _globalProps$organiza;
39
- var subdomain = (_globalProps$organiza = globalProps.organization) === null || _globalProps$organiza === void 0 ? void 0 : _globalProps$organiza.subdomain;
40
- return "".concat(UTM_SOURCE).concat(subdomain ? "&".concat(UTM_CAMPAIGN_PARAM, "=").concat(subdomain) : "");
41
- };
42
- var generateProductPageUrl = function generateProductPageUrl(appName) {
43
- var name = appName || globalProps.appName || NEETO;
44
- var utmParams = generateUtmParams();
45
- return "".concat(NEETO_BASE_URL, "/").concat(name.toLowerCase(), "?").concat(utmParams);
46
- };
47
-
48
- var CallToAction = function CallToAction(_ref) {
49
- var appName = _ref.appName,
50
- message = _ref.message,
51
- buttonLabel = _ref.buttonLabel;
52
- return /*#__PURE__*/jsxs("div", {
53
- className: "neeto-thank-you-configuration__cta",
54
- children: [/*#__PURE__*/jsx("p", {
55
- className: "neeto-thank-you-configuration__cta-message",
56
- children: message
57
- }), /*#__PURE__*/jsx("a", {
58
- className: "neeto-thank-you-configuration__cta-button",
59
- "data-testid": "neeto-thank-you-configuration-cta-button",
60
- href: generateProductPageUrl(appName),
61
- rel: "noopener noreferrer",
62
- target: "_blank",
63
- children: buttonLabel
64
- })]
65
- });
66
- };
67
-
68
- var SocialShare = withT(function (_ref) {
69
- var t = _ref.t,
70
- socialHandles = _ref.socialHandles,
71
- publicLinkId = _ref.publicLinkId;
72
- return /*#__PURE__*/jsxs("div", {
73
- className: "neeto-thank-you-configuration__social-share",
74
- children: [/*#__PURE__*/jsx("h4", {
75
- className: "neeto-thank-you-configuration__social-share-title",
76
- children: t("neetoThankYou.thankYou.socialShareHeading")
77
- }), /*#__PURE__*/jsx("div", {
78
- className: "neeto-thank-you-configuration-social-follow",
79
- "data-testid": "social-share-icons",
80
- children: socialHandles === null || socialHandles === void 0 ? void 0 : socialHandles.map(function (data, idx) {
81
- var Icon = data.icon,
82
- generateShareUrl = data.generateShareUrl;
83
- return /*#__PURE__*/jsx("div", {
84
- className: "neeto-thank-you-configuration-social-follow__item",
85
- children: /*#__PURE__*/jsx("a", {
86
- href: generateShareUrl(publicLinkId),
87
- rel: "noreferrer",
88
- target: "_blank",
89
- children: /*#__PURE__*/jsx(Icon, {})
90
- })
91
- }, idx);
92
- })
93
- })]
94
- });
95
- });
96
-
97
- export { CallToAction as C, FORM_OPTIONS as F, REDIRECT_DELAY as R, SocialShare as S, THANK_YOU_TEXT_ALIGNMENTS as T, THANK_YOU_KINDS as a, n };
98
- //# sourceMappingURL=SocialShare-C4rOGmnp.js.map
8
+ exports.n = n;
9
+ //# sourceMappingURL=thank-you-BAOIUbgZ.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"thank-you-BAOIUbgZ.js","sources":["../../node_modules/rollup-plugin-styles/dist/runtime/inject-css.js"],"sourcesContent":["var e=[],t=[];function n(n,r){if(n&&\"undefined\"!=typeof document){var a,s=!0===r.prepend?\"prepend\":\"append\",d=!0===r.singleTag,i=\"string\"==typeof r.container?document.querySelector(r.container):document.getElementsByTagName(\"head\")[0];if(d){var u=e.indexOf(i);-1===u&&(u=e.push(i)-1,t[u]={}),a=t[u]&&t[u][s]?t[u][s]:t[u][s]=c()}else a=c();65279===n.charCodeAt(0)&&(n=n.substring(1)),a.styleSheet?a.styleSheet.cssText+=n:a.appendChild(document.createTextNode(n))}function c(){var e=document.createElement(\"style\");if(e.setAttribute(\"type\",\"text/css\"),r.attributes)for(var t=Object.keys(r.attributes),n=0;n<t.length;n++)e.setAttribute(t[n],r.attributes[t[n]]);var a=\"prepend\"===s?\"afterbegin\":\"beforeend\";return i.insertAdjacentElement(a,e),e}}export{n as default};\n"],"names":[],"mappings":";;AAAA,IAAI,CAAC,CAAC,EAAE,CAAC,CAAC,CAAC,EAAE,CAAC,SAAS,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,GAAG,CAAC,EAAE,WAAW,EAAE,OAAO,QAAQ,CAAC,CAAC,IAAI,CAAC,CAAC,CAAC,CAAC,IAAE,GAAG,CAAC,CAAC,OAAO,CAAC,SAAS,CAAC,QAAQ,CAAC,CAAC,CAA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