@bigbinary/neeto-molecules 1.1.10 → 1.1.12
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.
- package/dist/AutoSaveInput/autosaveinput.scss +15 -0
- package/dist/AutoSaveInput/constants.js +13 -0
- package/dist/AutoSaveInput/index.js +124 -0
- package/dist/AutoSaveInput/utils.js +10 -0
- package/dist/Breadcrumbs/breadcrumbs.scss +33 -0
- package/dist/Breadcrumbs/index.js +31 -0
- package/dist/BrowserSupport/Callout.js +15 -0
- package/dist/BrowserSupport/ContactUs.js +21 -0
- package/dist/BrowserSupport/DownloadLink.js +17 -0
- package/dist/BrowserSupport/PartialSupportedBrowserVersion.js +17 -0
- package/dist/BrowserSupport/UnknownBrowser.js +13 -0
- package/dist/BrowserSupport/UnsupportedBrowser.js +24 -0
- package/dist/BrowserSupport/UnsupportedBrowserMessage.js +22 -0
- package/dist/BrowserSupport/UnsupportedBrowserVersion.js +27 -0
- package/dist/BrowserSupport/UnsupportedVersionMessage.js +30 -0
- package/dist/BrowserSupport/browsersupport.scss +71 -0
- package/dist/BrowserSupport/constants.js +63 -0
- package/dist/BrowserSupport/index.js +58 -0
- package/dist/BrowserSupport/utils.js +32 -0
- package/dist/CalendarView/CustomDatePicker.js +87 -0
- package/dist/CalendarView/Header.js +53 -0
- package/dist/CalendarView/constants.js +19 -0
- package/dist/CalendarView/index.js +83 -0
- package/dist/CalendarView/utils.js +50 -0
- package/dist/Codeblock/index.js +30 -0
- package/dist/{Columns.js → Columns/index.js} +13 -130
- package/dist/Columns/utils.js +20 -0
- package/dist/ConfirmationModal/constants.js +3 -0
- package/dist/{ConfirmationModal.js → ConfirmationModal/index.js} +7 -23
- package/dist/ConfirmationModal/utils.js +10 -0
- package/dist/Container/container.scss +21 -0
- package/dist/Container/index.js +23 -0
- package/dist/CopyToClipboardButton/constants.js +13 -0
- package/dist/CopyToClipboardButton/copyToClipboard.scss +22 -0
- package/dist/CopyToClipboardButton/index.js +59 -0
- package/dist/CustomDomain/index.js +98 -0
- package/dist/CustomDomainDashboard/DeleteAlert.js +28 -0
- package/dist/CustomDomainDashboard/Header.js +32 -0
- package/dist/CustomDomainDashboard/Manage/Record.js +42 -0
- package/dist/CustomDomainDashboard/Manage/StatusInfo.js +21 -0
- package/dist/CustomDomainDashboard/Manage/TagBlock.js +36 -0
- package/dist/CustomDomainDashboard/Manage/constants.js +4 -0
- package/dist/CustomDomainDashboard/Manage/index.js +124 -0
- package/dist/CustomDomainDashboard/Manage/utils.js +8 -0
- package/dist/CustomDomainDashboard/api.js +35 -0
- package/dist/CustomDomainDashboard/constants.js +2 -0
- package/dist/CustomDomainDashboard/index.js +118 -0
- package/dist/CustomDomainDashboard/useCustomDomainApi.js +71 -0
- package/dist/CustomDomainDashboard/utils.js +84 -0
- package/dist/{DateFormat.js → DateFormat/index.js} +8 -25
- package/dist/DateRangeFilter/index.js +60 -0
- package/dist/DateRangeFilter/utils.js +113 -0
- package/dist/DynamicVariables/dynamic-variables.scss +34 -0
- package/dist/DynamicVariables/index.js +59 -0
- package/dist/DynamicVariables/utils.js +37 -0
- package/dist/EmailForm/EmailForm.js +97 -0
- package/dist/EmailForm/EmailFormProvider.js +45 -0
- package/dist/EmailForm/EmailPreview.js +129 -0
- package/dist/EmailForm/ReplyToField.js +55 -0
- package/dist/EmailForm/SendToField.js +27 -0
- package/dist/EmailForm/SubjectField.js +64 -0
- package/dist/EmailForm/constants.js +33 -0
- package/dist/EmailForm/contexts/EmailForm.js +7 -0
- package/dist/EmailForm/index.js +4 -0
- package/dist/EmailForm/utils.js +10 -0
- package/dist/EmailPreview/index.js +2 -0
- package/dist/{ErrorPage.js → ErrorPage/constants.js} +36 -175
- package/dist/ErrorPage/index.js +78 -0
- package/dist/Header/Breadcrumbs.js +31 -0
- package/dist/Header/Dropdown.js +12 -0
- package/dist/Header/constants.js +6 -0
- package/dist/Header/header.scss +121 -0
- package/dist/Header/index.js +61 -0
- package/dist/IconPicker/Icon.js +34 -0
- package/dist/IconPicker/NoResults.js +12 -0
- package/dist/IconPicker/constants.js +8 -0
- package/dist/IconPicker/icon-picker.scss +1 -0
- package/dist/IconPicker/index.js +164 -0
- package/dist/ImageWithFallback/ImagePlaceholder.js +16 -0
- package/dist/ImageWithFallback/index.js +31 -0
- package/dist/IntegrationCard/Dropdown.js +45 -0
- package/dist/IntegrationCard/Status.js +25 -0
- package/dist/IntegrationCard/index.js +128 -0
- package/dist/IntegrationDisconnectAlert/index.js +36 -0
- package/dist/{IntegrationWalkthroughModal.js → IntegrationWalkthroughModal/index.js} +6 -8
- package/dist/IpRestriction/AllowedIpRanges.js +75 -0
- package/dist/IpRestriction/CurrentIp.js +26 -0
- package/dist/IpRestriction/FormRow.js +84 -0
- package/dist/IpRestriction/Row.js +91 -0
- package/dist/IpRestriction/apis/allowed_ip_ranges.js +28 -0
- package/dist/IpRestriction/apis/current_ip.js +11 -0
- package/dist/IpRestriction/apis/ip_restriction.js +16 -0
- package/dist/IpRestriction/constants.js +20 -0
- package/dist/IpRestriction/hooks/reactQuery/useAllowedIpRanges.js +34 -0
- package/dist/IpRestriction/hooks/reactQuery/useCurrentIp.js +10 -0
- package/dist/IpRestriction/hooks/reactQuery/useIpRestrictions.js +18 -0
- package/dist/IpRestriction/index.js +102 -0
- package/dist/IpRestriction/utils.js +85 -0
- package/dist/KeyboardShortcuts/Pane/HotKey.js +44 -0
- package/dist/KeyboardShortcuts/Pane/HotKeyList.js +42 -0
- package/dist/KeyboardShortcuts/Pane/constants.js +25 -0
- package/dist/KeyboardShortcuts/Pane/index.js +61 -0
- package/dist/KeyboardShortcuts/Pane/keyboard-shortcuts.scss +5 -0
- package/dist/KeyboardShortcuts/Pane/utils.js +66 -0
- package/dist/KeyboardShortcuts/hooks/useKeyboardShortcutsPaneState.js +31 -0
- package/dist/KeyboardShortcuts/index.js +9 -0
- package/dist/LoginPage/Form.js +57 -0
- package/dist/LoginPage/constants.js +12 -0
- package/dist/LoginPage/index.js +103 -0
- package/dist/MenuBar/AddNew.js +25 -0
- package/dist/MenuBar/Block.js +60 -0
- package/dist/MenuBar/Item.js +32 -0
- package/dist/MenuBar/Search.js +39 -0
- package/dist/MenuBar/SubTitle.js +23 -0
- package/dist/MenuBar/index.js +46 -0
- package/dist/MenuBar/menubar.scss +154 -0
- package/dist/Metadata/Block.js +30 -0
- package/dist/Metadata/DetailsBlock.js +86 -0
- package/dist/Metadata/constants.js +9 -0
- package/dist/Metadata/index.js +29 -0
- package/dist/Metadata/metadata.scss +15 -0
- package/dist/MoreDropdown/constants.js +25 -0
- package/dist/{MoreDropdown.js → MoreDropdown/index.js} +9 -102
- package/dist/NavigationHeader/LeftBlock.js +32 -0
- package/dist/NavigationHeader/Navigation.js +24 -0
- package/dist/NavigationHeader/RightBlock.js +68 -0
- package/dist/NavigationHeader/constants.js +11 -0
- package/dist/NavigationHeader/index.js +19 -0
- package/dist/NavigationHeader/navigation-header.scss +3 -0
- package/dist/NeetoWidget/CodeBlock.js +57 -0
- package/dist/NeetoWidget/CodeSnippet.js +119 -0
- package/dist/NeetoWidget/EmbedCode.js +281 -0
- package/dist/NeetoWidget/Main.js +19 -0
- package/dist/NeetoWidget/SelectionSwitches/TooltipSwitch.js +25 -0
- package/dist/NeetoWidget/SelectionSwitches/index.js +44 -0
- package/dist/NeetoWidget/SyntaxHighlighter.js +17 -0
- package/dist/NeetoWidget/api.js +20 -0
- package/dist/NeetoWidget/constants.js +62 -0
- package/dist/NeetoWidget/hooks/useForceUpdate.js +14 -0
- package/dist/NeetoWidget/index.js +7 -0
- package/dist/NeetoWidget/mutations.js +9 -0
- package/dist/NeetoWidget/queries.js +32 -0
- package/dist/NeetoWidget/utils.js +83 -0
- package/dist/PageLoader/index.js +81 -0
- package/dist/PageLoader/page-loader.scss +95 -0
- package/dist/PhoneNumber/CountryPicker/SingleValue.js +21 -0
- package/dist/PhoneNumber/CountryPicker/constants.js +26 -0
- package/dist/PhoneNumber/CountryPicker/index.js +59 -0
- package/dist/PhoneNumber/FormikPhoneNumberInput.js +21 -0
- package/dist/PhoneNumber/PhoneNumber.js +30 -0
- package/dist/PhoneNumber/PhoneNumberInput.js +79 -0
- package/dist/PhoneNumber/index.js +5 -0
- package/dist/PhoneNumber/utils.js +55 -0
- package/dist/PublishBlock/AlertBlock.js +14 -0
- package/dist/PublishBlock/index.js +100 -0
- package/dist/PublishBlock/publish-block.scss +25 -0
- package/dist/Rename/DummySpan.js +21 -0
- package/dist/Rename/constants.js +1 -0
- package/dist/Rename/index.js +191 -0
- package/dist/Rename/rename.scss +69 -0
- package/dist/Rename/utils.js +10 -0
- package/dist/ResponsiveDevicePicker/constants.js +19 -0
- package/dist/ResponsiveDevicePicker/index.js +36 -0
- package/dist/Schedule/DisplayAvailability.js +58 -0
- package/dist/Schedule/Fields.js +43 -0
- package/dist/Schedule/Form/ScheduleRow.js +125 -0
- package/dist/Schedule/Form/constants.js +20 -0
- package/dist/Schedule/Form/index.js +144 -0
- package/dist/Schedule/Form/utils.js +63 -0
- package/dist/Schedule/Header.js +76 -0
- package/dist/Schedule/ScheduleContext.js +8 -0
- package/dist/Schedule/constants.js +8 -0
- package/dist/Schedule/dayjsExtended/constants.js +1 -0
- package/dist/Schedule/dayjsExtended/index.js +14 -0
- package/dist/Schedule/dayjsExtended/range.js +73 -0
- package/dist/Schedule/index.js +80 -0
- package/dist/Schedule/utils.js +152 -0
- package/dist/Scrollable/constants.js +8 -0
- package/dist/Scrollable/index.js +26 -0
- package/dist/Scrollable/scrollable.scss +32 -0
- package/dist/Search/index.js +52 -0
- package/dist/Security/AllowedKeywords/Add.js +38 -0
- package/dist/Security/AllowedKeywords/index.js +38 -0
- package/dist/Security/PasswordBlock.js +31 -0
- package/dist/Security/RadioBlock.js +38 -0
- package/dist/Security/api.js +12 -0
- package/dist/Security/constants.js +58 -0
- package/dist/Security/index.js +68 -0
- package/dist/Security/useSecurityApi.js +22 -0
- package/dist/Security/utils.js +31 -0
- package/dist/SendToFields/FilePicker.js +34 -0
- package/dist/SendToFields/constants.js +6 -0
- package/dist/SendToFields/index.js +102 -0
- package/dist/SendToFields/utils.js +54 -0
- package/dist/Settings/Category.js +30 -0
- package/dist/Settings/Item.js +38 -0
- package/dist/Settings/index.js +37 -0
- package/dist/Settings/utils.js +4 -0
- package/dist/ShareViaEmail/EmailBodyEditor.js +22 -0
- package/dist/ShareViaEmail/FilePicker.js +43 -0
- package/dist/ShareViaEmail/Form.js +101 -0
- package/dist/ShareViaEmail/FormikDatePicker.js +24 -0
- package/dist/ShareViaEmail/constants.js +14 -0
- package/dist/ShareViaEmail/index.js +89 -0
- package/dist/ShareViaEmail/utils.js +72 -0
- package/dist/ShareViaLink/EditURL.js +74 -0
- package/dist/ShareViaLink/Link.js +105 -0
- package/dist/ShareViaLink/QRCode.js +41 -0
- package/dist/ShareViaLink/RegenerateURL.js +47 -0
- package/dist/ShareViaLink/SocialMedia.js +52 -0
- package/dist/ShareViaLink/constants.js +25 -0
- package/dist/ShareViaLink/edit-url.scss +8 -0
- package/dist/ShareViaLink/index.js +46 -0
- package/dist/ShareViaLink/utils.js +47 -0
- package/dist/Sidebar/AppSwitcher/AppLink.js +45 -0
- package/dist/Sidebar/AppSwitcher/Backdrop.js +13 -0
- package/dist/Sidebar/AppSwitcher/Body.js +65 -0
- package/dist/Sidebar/AppSwitcher/Portal.js +27 -0
- package/dist/Sidebar/AppSwitcher/appswitcher.scss +164 -0
- package/dist/Sidebar/AppSwitcher/index.js +47 -0
- package/dist/Sidebar/AppSwitcher/utils.js +25 -0
- package/dist/Sidebar/Chevron.js +14 -0
- package/dist/Sidebar/FeaturedTooltip.js +19 -0
- package/dist/Sidebar/Footer/AppSwitcherButton.js +48 -0
- package/dist/Sidebar/Footer/ProfileButton.js +30 -0
- package/dist/Sidebar/Footer/index.js +56 -0
- package/dist/Sidebar/Footer/utils.js +39 -0
- package/dist/Sidebar/Header.js +33 -0
- package/dist/Sidebar/HelpSection/HelpSectionMenu.js +52 -0
- package/dist/Sidebar/HelpSection/index.js +32 -0
- package/dist/Sidebar/Links.js +112 -0
- package/dist/Sidebar/NavIconWrapper.js +20 -0
- package/dist/Sidebar/ProfileSection/LinkSection.js +36 -0
- package/dist/Sidebar/ProfileSection/ProfileMenu.js +48 -0
- package/dist/Sidebar/ProfileSection/index.js +42 -0
- package/dist/Sidebar/constants.js +40 -0
- package/dist/Sidebar/index.js +94 -0
- package/dist/Sidebar/sidebar.scss +379 -0
- package/dist/Sidebar/utils.js +18 -0
- package/dist/SubHeader/RightBlock/Columns.js +35 -0
- package/dist/SubHeader/RightBlock/Download.js +28 -0
- package/dist/SubHeader/RightBlock/Filter.js +31 -0
- package/dist/SubHeader/RightBlock/index.js +21 -0
- package/dist/SubHeader/RightBlock/utils.js +13 -0
- package/dist/SubHeader/index.js +28 -0
- package/dist/SubHeader/subheader.scss +78 -0
- package/dist/TableWrapper/index.js +18 -0
- package/dist/ThemeSidebar/Customize/Logo.js +39 -0
- package/dist/ThemeSidebar/Customize/Properties.js +170 -0
- package/dist/ThemeSidebar/Customize/index.js +66 -0
- package/dist/ThemeSidebar/Themes/ThemeCard.js +135 -0
- package/dist/ThemeSidebar/Themes/index.js +110 -0
- package/dist/ThemeSidebar/TitleBar.js +62 -0
- package/dist/ThemeSidebar/constants.js +127 -0
- package/dist/ThemeSidebar/fields/AlignmentBlock.js +50 -0
- package/dist/ThemeSidebar/fields/Card.js +19 -0
- package/dist/ThemeSidebar/fields/ColorBlock.js +19 -0
- package/dist/ThemeSidebar/fields/FontPickerBlock.js +35 -0
- package/dist/ThemeSidebar/fields/ImageBlock/ImageUploader.js +67 -0
- package/dist/ThemeSidebar/fields/ImageBlock/ProgressBar.js +22 -0
- package/dist/ThemeSidebar/fields/ImageBlock/index.js +55 -0
- package/dist/ThemeSidebar/fields/SelectBlock.js +24 -0
- package/dist/ThemeSidebar/fields/SliderBlock.js +30 -0
- package/dist/ThemeSidebar/fields/SwitchBlock.js +17 -0
- package/dist/ThemeSidebar/fields/TextBlock.js +13 -0
- package/dist/ThemeSidebar/fields/slider.scss +199 -0
- package/dist/ThemeSidebar/hooks/useDirectUploadDropzone.js +149 -0
- package/dist/ThemeSidebar/index.js +118 -0
- package/dist/ThemeSidebar/themeSidebar.scss +45 -0
- package/dist/ThemeSidebar/utils.js +169 -0
- package/dist/TimeFormat/index.js +3 -0
- package/dist/TimezoneMismatchModal/apis/time_zone.js +9 -0
- package/dist/TimezoneMismatchModal/index.js +83 -0
- package/dist/TimezoneMismatchModal/useTimeZoneApi.js +10 -0
- package/dist/TimezoneMismatchModal/utils.js +12 -0
- package/dist/ToggleFeatureCard/ToolTipSwitch.js +31 -0
- package/dist/ToggleFeatureCard/constants.js +5 -0
- package/dist/ToggleFeatureCard/hooks/useScrollIntoView.js +11 -0
- package/dist/ToggleFeatureCard/index.js +148 -0
- package/dist/ToggleFeatureCard/toggleFeatureCard.scss +4 -0
- package/package.json +28 -34
- package/src/translations/en.json +5 -1
- package/types/Search.d.ts +19 -0
- package/dist/AutoSaveInput.cjs.js +0 -724
- package/dist/AutoSaveInput.cjs.js.map +0 -1
- package/dist/AutoSaveInput.js +0 -718
- package/dist/AutoSaveInput.js.map +0 -1
- package/dist/Breadcrumbs.cjs.js +0 -44
- package/dist/Breadcrumbs.cjs.js.map +0 -1
- package/dist/Breadcrumbs.js +0 -38
- package/dist/Breadcrumbs.js.map +0 -1
- package/dist/BrowserSupport.cjs.js +0 -1731
- package/dist/BrowserSupport.cjs.js.map +0 -1
- package/dist/BrowserSupport.js +0 -1725
- package/dist/BrowserSupport.js.map +0 -1
- package/dist/CalendarView.cjs.js +0 -610
- package/dist/CalendarView.cjs.js.map +0 -1
- package/dist/CalendarView.js +0 -598
- package/dist/CalendarView.js.map +0 -1
- package/dist/Codeblock.cjs.js +0 -302
- package/dist/Codeblock.cjs.js.map +0 -1
- package/dist/Codeblock.js +0 -296
- package/dist/Codeblock.js.map +0 -1
- package/dist/Columns.cjs.js +0 -248
- package/dist/Columns.cjs.js.map +0 -1
- package/dist/Columns.js.map +0 -1
- package/dist/ConfirmationModal.cjs.js +0 -87
- package/dist/ConfirmationModal.cjs.js.map +0 -1
- package/dist/ConfirmationModal.js.map +0 -1
- package/dist/Container.cjs.js +0 -1277
- package/dist/Container.cjs.js.map +0 -1
- package/dist/Container.js +0 -1271
- package/dist/Container.js.map +0 -1
- package/dist/CopyToClipboardButton.cjs.js +0 -275
- package/dist/CopyToClipboardButton.cjs.js.map +0 -1
- package/dist/CopyToClipboardButton.js +0 -269
- package/dist/CopyToClipboardButton.js.map +0 -1
- package/dist/CustomDomain.cjs.js +0 -774
- package/dist/CustomDomain.cjs.js.map +0 -1
- package/dist/CustomDomain.js +0 -747
- package/dist/CustomDomain.js.map +0 -1
- package/dist/CustomDomainDashboard.cjs.js +0 -2370
- package/dist/CustomDomainDashboard.cjs.js.map +0 -1
- package/dist/CustomDomainDashboard.js +0 -2342
- package/dist/CustomDomainDashboard.js.map +0 -1
- package/dist/DateFormat.cjs.js +0 -51
- package/dist/DateFormat.cjs.js.map +0 -1
- package/dist/DateFormat.js.map +0 -1
- package/dist/DateRangeFilter.cjs.js +0 -236
- package/dist/DateRangeFilter.cjs.js.map +0 -1
- package/dist/DateRangeFilter.js +0 -229
- package/dist/DateRangeFilter.js.map +0 -1
- package/dist/DynamicVariables.cjs.js +0 -189
- package/dist/DynamicVariables.cjs.js.map +0 -1
- package/dist/DynamicVariables.js +0 -183
- package/dist/DynamicVariables.js.map +0 -1
- package/dist/EmailForm.cjs.js +0 -4295
- package/dist/EmailForm.cjs.js.map +0 -1
- package/dist/EmailForm.js +0 -4265
- package/dist/EmailForm.js.map +0 -1
- package/dist/EmailPreview.cjs.js +0 -1419
- package/dist/EmailPreview.cjs.js.map +0 -1
- package/dist/EmailPreview.js +0 -1413
- package/dist/EmailPreview.js.map +0 -1
- package/dist/ErrorPage.cjs.js +0 -226
- package/dist/ErrorPage.cjs.js.map +0 -1
- package/dist/ErrorPage.js.map +0 -1
- package/dist/Header.cjs.js +0 -188
- package/dist/Header.cjs.js.map +0 -1
- package/dist/Header.js +0 -182
- package/dist/Header.js.map +0 -1
- package/dist/IconPicker.cjs.js +0 -1308
- package/dist/IconPicker.cjs.js.map +0 -1
- package/dist/IconPicker.js +0 -1302
- package/dist/IconPicker.js.map +0 -1
- package/dist/ImageWithFallback.cjs.js +0 -247
- package/dist/ImageWithFallback.cjs.js.map +0 -1
- package/dist/ImageWithFallback.js +0 -241
- package/dist/ImageWithFallback.js.map +0 -1
- package/dist/IntegrationCard.cjs.js +0 -409
- package/dist/IntegrationCard.cjs.js.map +0 -1
- package/dist/IntegrationCard.js +0 -403
- package/dist/IntegrationCard.js.map +0 -1
- package/dist/IntegrationDisconnectAlert.cjs.js +0 -89
- package/dist/IntegrationDisconnectAlert.cjs.js.map +0 -1
- package/dist/IntegrationDisconnectAlert.js +0 -80
- package/dist/IntegrationDisconnectAlert.js.map +0 -1
- package/dist/IntegrationWalkthroughModal.cjs.js +0 -50
- package/dist/IntegrationWalkthroughModal.cjs.js.map +0 -1
- package/dist/IntegrationWalkthroughModal.js.map +0 -1
- package/dist/IpRestriction.cjs.js +0 -3931
- package/dist/IpRestriction.cjs.js.map +0 -1
- package/dist/IpRestriction.js +0 -3905
- package/dist/IpRestriction.js.map +0 -1
- package/dist/KeyboardShortcuts.cjs.js +0 -2263
- package/dist/KeyboardShortcuts.cjs.js.map +0 -1
- package/dist/KeyboardShortcuts.js +0 -2256
- package/dist/KeyboardShortcuts.js.map +0 -1
- package/dist/LoginPage.cjs.js +0 -618
- package/dist/LoginPage.cjs.js.map +0 -1
- package/dist/LoginPage.js +0 -593
- package/dist/LoginPage.js.map +0 -1
- package/dist/MenuBar.cjs.js +0 -34273
- package/dist/MenuBar.cjs.js.map +0 -1
- package/dist/MenuBar.js +0 -34267
- package/dist/MenuBar.js.map +0 -1
- package/dist/Metadata.cjs.js +0 -272
- package/dist/Metadata.cjs.js.map +0 -1
- package/dist/Metadata.js +0 -266
- package/dist/Metadata.js.map +0 -1
- package/dist/MoreDropdown.cjs.js +0 -168
- package/dist/MoreDropdown.cjs.js.map +0 -1
- package/dist/MoreDropdown.js.map +0 -1
- package/dist/NavigationHeader.cjs.js +0 -756
- package/dist/NavigationHeader.cjs.js.map +0 -1
- package/dist/NavigationHeader.js +0 -750
- package/dist/NavigationHeader.js.map +0 -1
- package/dist/NeetoWidget.cjs.js +0 -3375
- package/dist/NeetoWidget.cjs.js.map +0 -1
- package/dist/NeetoWidget.js +0 -3348
- package/dist/NeetoWidget.js.map +0 -1
- package/dist/PageLoader.cjs.js +0 -158
- package/dist/PageLoader.cjs.js.map +0 -1
- package/dist/PageLoader.js +0 -134
- package/dist/PageLoader.js.map +0 -1
- package/dist/PhoneNumber.cjs.js +0 -7021
- package/dist/PhoneNumber.cjs.js.map +0 -1
- package/dist/PhoneNumber.js +0 -6989
- package/dist/PhoneNumber.js.map +0 -1
- package/dist/PublishBlock.cjs.js +0 -224
- package/dist/PublishBlock.cjs.js.map +0 -1
- package/dist/PublishBlock.js +0 -218
- package/dist/PublishBlock.js.map +0 -1
- package/dist/Rename.cjs.js +0 -516
- package/dist/Rename.cjs.js.map +0 -1
- package/dist/Rename.js +0 -510
- package/dist/Rename.js.map +0 -1
- package/dist/ResponsiveDevicePicker.cjs.js +0 -260
- package/dist/ResponsiveDevicePicker.cjs.js.map +0 -1
- package/dist/ResponsiveDevicePicker.js +0 -254
- package/dist/ResponsiveDevicePicker.js.map +0 -1
- package/dist/Schedule.cjs.js +0 -1077
- package/dist/Schedule.cjs.js.map +0 -1
- package/dist/Schedule.js +0 -1046
- package/dist/Schedule.js.map +0 -1
- package/dist/Scrollable.cjs.js +0 -188
- package/dist/Scrollable.cjs.js.map +0 -1
- package/dist/Scrollable.js +0 -182
- package/dist/Scrollable.js.map +0 -1
- package/dist/Security.cjs.js +0 -1921
- package/dist/Security.cjs.js.map +0 -1
- package/dist/Security.js +0 -1895
- package/dist/Security.js.map +0 -1
- package/dist/SendToFields.cjs.js +0 -2524
- package/dist/SendToFields.cjs.js.map +0 -1
- package/dist/SendToFields.js +0 -2517
- package/dist/SendToFields.js.map +0 -1
- package/dist/Settings.cjs.js +0 -501
- package/dist/Settings.cjs.js.map +0 -1
- package/dist/Settings.js +0 -495
- package/dist/Settings.js.map +0 -1
- package/dist/ShareViaEmail.cjs.js +0 -4272
- package/dist/ShareViaEmail.cjs.js.map +0 -1
- package/dist/ShareViaEmail.js +0 -4246
- package/dist/ShareViaEmail.js.map +0 -1
- package/dist/ShareViaLink.cjs.js +0 -1512
- package/dist/ShareViaLink.cjs.js.map +0 -1
- package/dist/ShareViaLink.js +0 -1486
- package/dist/ShareViaLink.js.map +0 -1
- package/dist/Sidebar.cjs.js +0 -34985
- package/dist/Sidebar.cjs.js.map +0 -1
- package/dist/Sidebar.js +0 -34959
- package/dist/Sidebar.js.map +0 -1
- package/dist/SubHeader.cjs.js +0 -283
- package/dist/SubHeader.cjs.js.map +0 -1
- package/dist/SubHeader.js +0 -276
- package/dist/SubHeader.js.map +0 -1
- package/dist/TableWrapper.cjs.js +0 -87
- package/dist/TableWrapper.cjs.js.map +0 -1
- package/dist/TableWrapper.js +0 -81
- package/dist/TableWrapper.js.map +0 -1
- package/dist/ThemeSidebar.cjs.js +0 -13705
- package/dist/ThemeSidebar.cjs.js.map +0 -1
- package/dist/ThemeSidebar.js +0 -13680
- package/dist/ThemeSidebar.js.map +0 -1
- package/dist/TimeFormat.cjs.js +0 -53
- package/dist/TimeFormat.cjs.js.map +0 -1
- package/dist/TimeFormat.js +0 -47
- package/dist/TimeFormat.js.map +0 -1
- package/dist/TimezoneMismatchModal.cjs.js +0 -176
- package/dist/TimezoneMismatchModal.cjs.js.map +0 -1
- package/dist/TimezoneMismatchModal.js +0 -168
- package/dist/TimezoneMismatchModal.js.map +0 -1
- package/dist/ToggleFeatureCard.cjs.js +0 -389
- package/dist/ToggleFeatureCard.cjs.js.map +0 -1
- package/dist/ToggleFeatureCard.js +0 -383
- package/dist/ToggleFeatureCard.js.map +0 -1
|
@@ -0,0 +1,78 @@
|
|
|
1
|
+
$neeto-molecules-sub-header-height: 37px;
|
|
2
|
+
$neeto-molecules-sub-header-bottom-margin: 20px;
|
|
3
|
+
|
|
4
|
+
:root {
|
|
5
|
+
--neeto-molecules-sub-header-height: #{$neeto-molecules-sub-header-height};
|
|
6
|
+
--neeto-molecules-sub-header-bottom-margin: #{$neeto-molecules-sub-header-bottom-margin};
|
|
7
|
+
}
|
|
8
|
+
|
|
9
|
+
.neeto-molecules-subheader {
|
|
10
|
+
width: 100%;
|
|
11
|
+
display: flex;
|
|
12
|
+
flex-direction: row;
|
|
13
|
+
justify-content: space-between;
|
|
14
|
+
align-items: center;
|
|
15
|
+
min-height: var(--neeto-molecules-sub-header-height);
|
|
16
|
+
margin-bottom: var(--neeto-molecules-sub-header-bottom-margin);
|
|
17
|
+
background-color: rgb(var(--neeto-ui-white));
|
|
18
|
+
|
|
19
|
+
.neeto-molecules-subheader__left-wrapper {
|
|
20
|
+
display: flex;
|
|
21
|
+
flex-grow: 1;
|
|
22
|
+
|
|
23
|
+
.neeto-molecules-subheader__left {
|
|
24
|
+
display: flex;
|
|
25
|
+
flex-direction: row;
|
|
26
|
+
justify-content: flex-start;
|
|
27
|
+
align-items: center;
|
|
28
|
+
|
|
29
|
+
.neeto-molecules-input__prefix {
|
|
30
|
+
color: rgb(var(--neeto-ui-gray-400));
|
|
31
|
+
}
|
|
32
|
+
}
|
|
33
|
+
}
|
|
34
|
+
|
|
35
|
+
.neeto-molecules-subheader__right {
|
|
36
|
+
display: flex;
|
|
37
|
+
flex-direction: row;
|
|
38
|
+
justify-content: flex-end;
|
|
39
|
+
align-items: center;
|
|
40
|
+
gap: 12px;
|
|
41
|
+
|
|
42
|
+
&-actions {
|
|
43
|
+
display: flex;
|
|
44
|
+
flex-direction: row;
|
|
45
|
+
justify-content: flex-end;
|
|
46
|
+
align-items: center;
|
|
47
|
+
gap: 8px;
|
|
48
|
+
|
|
49
|
+
& > :not([hidden]) ~ :not([hidden]) {
|
|
50
|
+
border-left: thin solid rgb(var(--neeto-ui-gray-300));
|
|
51
|
+
padding-left: 8px;
|
|
52
|
+
}
|
|
53
|
+
}
|
|
54
|
+
}
|
|
55
|
+
|
|
56
|
+
&__download {
|
|
57
|
+
position: relative;
|
|
58
|
+
|
|
59
|
+
&-count {
|
|
60
|
+
position: absolute;
|
|
61
|
+
right: -2px;
|
|
62
|
+
top: -2px;
|
|
63
|
+
min-width: 16px;
|
|
64
|
+
min-height: 16px;
|
|
65
|
+
|
|
66
|
+
display: inline-flex;
|
|
67
|
+
justify-content: center;
|
|
68
|
+
align-items: center;
|
|
69
|
+
text-align: center;
|
|
70
|
+
|
|
71
|
+
background-color: rgb(var(--neeto-ui-primary-500));
|
|
72
|
+
color: rgb(var(--neeto-ui-white));
|
|
73
|
+
border-radius: var(--neeto-ui-rounded-full);
|
|
74
|
+
font-size: 10px;
|
|
75
|
+
z-index: 1;
|
|
76
|
+
}
|
|
77
|
+
}
|
|
78
|
+
}
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
import React from "react";
|
|
2
|
+
import classNames from "classnames";
|
|
3
|
+
var TableWrapper = function TableWrapper(_ref) {
|
|
4
|
+
var children = _ref.children,
|
|
5
|
+
_ref$className = _ref.className,
|
|
6
|
+
className = _ref$className === void 0 ? "" : _ref$className,
|
|
7
|
+
_ref$hasPagination = _ref.hasPagination,
|
|
8
|
+
hasPagination = _ref$hasPagination === void 0 ? false : _ref$hasPagination;
|
|
9
|
+
return /*#__PURE__*/React.createElement("div", {
|
|
10
|
+
"data-testid": "table-wrapper",
|
|
11
|
+
className: classNames("flex min-h-0 w-full flex-grow flex-col pb-6", className)
|
|
12
|
+
}, /*#__PURE__*/React.createElement("div", {
|
|
13
|
+
className: classNames("min-h-0 flex-grow", {
|
|
14
|
+
"pb-11": hasPagination
|
|
15
|
+
})
|
|
16
|
+
}, children));
|
|
17
|
+
};
|
|
18
|
+
export default TableWrapper;
|
|
@@ -0,0 +1,39 @@
|
|
|
1
|
+
import React from "react";
|
|
2
|
+
import { findBy } from "@bigbinary/neeto-commons-frontend/pure";
|
|
3
|
+
import { mergeLeft, isEmpty } from "ramda";
|
|
4
|
+
import { useTranslation } from "react-i18next";
|
|
5
|
+
import { POSITION_OPTIONS } from "../constants";
|
|
6
|
+
import Card from "../fields/Card";
|
|
7
|
+
import ImageBlock from "../fields/ImageBlock";
|
|
8
|
+
import SelectBlock from "../fields/SelectBlock";
|
|
9
|
+
var Logo = function Logo(_ref) {
|
|
10
|
+
var logo = _ref.logo,
|
|
11
|
+
_onChange = _ref.onChange;
|
|
12
|
+
var _useTranslation = useTranslation(),
|
|
13
|
+
t = _useTranslation.t;
|
|
14
|
+
return /*#__PURE__*/React.createElement(Card, {
|
|
15
|
+
title: t("neetoMolecules.themeSidebar.logo")
|
|
16
|
+
}, /*#__PURE__*/React.createElement("div", {
|
|
17
|
+
className: "divide-y divide-gray-200"
|
|
18
|
+
}, /*#__PURE__*/React.createElement(ImageBlock, {
|
|
19
|
+
imageData: logo,
|
|
20
|
+
name: "logo",
|
|
21
|
+
onChange: function onChange(name, value) {
|
|
22
|
+
return _onChange(name, isEmpty(value) ? {
|
|
23
|
+
position: logo.position
|
|
24
|
+
} : mergeLeft(value, logo));
|
|
25
|
+
}
|
|
26
|
+
}), logo.url && /*#__PURE__*/React.createElement(SelectBlock, {
|
|
27
|
+
label: t("neetoMolecules.themeSidebar.logoPosition"),
|
|
28
|
+
options: POSITION_OPTIONS,
|
|
29
|
+
placeholder: t("neetoMolecules.themeSidebar.left"),
|
|
30
|
+
value: findBy({
|
|
31
|
+
value: logo.position || "left"
|
|
32
|
+
}, POSITION_OPTIONS),
|
|
33
|
+
onChange: function onChange(_ref2) {
|
|
34
|
+
var value = _ref2.value;
|
|
35
|
+
return _onChange("logo.position", value);
|
|
36
|
+
}
|
|
37
|
+
})));
|
|
38
|
+
};
|
|
39
|
+
export default /*#__PURE__*/React.memo(Logo);
|
|
@@ -0,0 +1,170 @@
|
|
|
1
|
+
import React, { useEffect } from "react";
|
|
2
|
+
import { findBy } from "@bigbinary/neeto-commons-frontend/pure";
|
|
3
|
+
import { useTranslation } from "react-i18next";
|
|
4
|
+
import { BACKGROUND_POSITION_OPTIONS, FONT_OPTIONS } from "../constants";
|
|
5
|
+
import AlignmentBlock from "../fields/AlignmentBlock";
|
|
6
|
+
import Card from "../fields/Card";
|
|
7
|
+
import ColorBlock from "../fields/ColorBlock";
|
|
8
|
+
import FontPickerBlock from "../fields/FontPickerBlock";
|
|
9
|
+
import ImageBlock from "../fields/ImageBlock";
|
|
10
|
+
import SelectBlock from "../fields/SelectBlock";
|
|
11
|
+
import SliderBlock from "../fields/SliderBlock";
|
|
12
|
+
import SwitchBlock from "../fields/SwitchBlock";
|
|
13
|
+
import { getContrast, hexToRgb } from "../utils";
|
|
14
|
+
var Properties = function Properties(_ref) {
|
|
15
|
+
var handleChange = _ref.handleChange,
|
|
16
|
+
values = _ref.values;
|
|
17
|
+
var _useTranslation = useTranslation(),
|
|
18
|
+
t = _useTranslation.t;
|
|
19
|
+
var backgroundColor = values.backgroundColor,
|
|
20
|
+
questionColor = values.questionColor,
|
|
21
|
+
buttonBackgroundColor = values.buttonBackgroundColor,
|
|
22
|
+
buttonTextColor = values.buttonTextColor,
|
|
23
|
+
answerColor = values.answerColor,
|
|
24
|
+
backgroundImage = values.backgroundImage,
|
|
25
|
+
isContentBackgroundEnabled = values.isContentBackgroundEnabled,
|
|
26
|
+
contentBackgroundColor = values.contentBackgroundColor,
|
|
27
|
+
isDominantBackgroundColorEnabled = values.isDominantBackgroundColorEnabled,
|
|
28
|
+
backgroundOverlayOpacity = values.backgroundOverlayOpacity,
|
|
29
|
+
buttonBorderRadius = values.buttonBorderRadius;
|
|
30
|
+
var handleOverlayChange = function handleOverlayChange(value) {
|
|
31
|
+
handleChange("backgroundOverlayOpacity", value, Math.abs(value / 100));
|
|
32
|
+
if (value < 0) {
|
|
33
|
+
handleChange("backgroundOverlayColor", "#000000");
|
|
34
|
+
} else if (value > 0) {
|
|
35
|
+
handleChange("backgroundOverlayColor", "#ffffff");
|
|
36
|
+
}
|
|
37
|
+
};
|
|
38
|
+
useEffect(function () {
|
|
39
|
+
if (isContentBackgroundEnabled) {
|
|
40
|
+
var color = contentBackgroundColor || backgroundColor;
|
|
41
|
+
handleChange("contentBackgroundColor", color);
|
|
42
|
+
} else {
|
|
43
|
+
handleChange("contentBackgroundColor", contentBackgroundColor);
|
|
44
|
+
}
|
|
45
|
+
}, [isContentBackgroundEnabled]);
|
|
46
|
+
useEffect(function () {
|
|
47
|
+
if (isDominantBackgroundColorEnabled && backgroundImage !== null && backgroundImage !== void 0 && backgroundImage.dominantColor) {
|
|
48
|
+
handleChange("backgroundColor", backgroundImage.dominantColor, backgroundImage.dominantColor ? hexToRgb(backgroundImage.dominantColor) : "initial");
|
|
49
|
+
}
|
|
50
|
+
}, [isDominantBackgroundColorEnabled, backgroundImage === null || backgroundImage === void 0 ? void 0 : backgroundImage.dominantColor]);
|
|
51
|
+
var handleColorChange = function handleColorChange(name) {
|
|
52
|
+
return function (_ref2) {
|
|
53
|
+
var hex = _ref2.hex,
|
|
54
|
+
rgb = _ref2.rgb;
|
|
55
|
+
handleChange(name, hex, "".concat(rgb.r, ", ").concat(rgb.g, ", ").concat(rgb.b));
|
|
56
|
+
};
|
|
57
|
+
};
|
|
58
|
+
var handleAnswerColorChange = function handleAnswerColorChange(_ref3) {
|
|
59
|
+
var hex = _ref3.hex,
|
|
60
|
+
rgb = _ref3.rgb;
|
|
61
|
+
handleColorChange("answerColor")({
|
|
62
|
+
hex: hex,
|
|
63
|
+
rgb: rgb
|
|
64
|
+
});
|
|
65
|
+
var contrastColor = getContrast(hex);
|
|
66
|
+
handleColorChange("answerTextColor")({
|
|
67
|
+
hex: contrastColor,
|
|
68
|
+
rgb: hexToRgb(contrastColor)
|
|
69
|
+
});
|
|
70
|
+
};
|
|
71
|
+
return /*#__PURE__*/React.createElement(Card, {
|
|
72
|
+
title: t("neetoMolecules.themeSidebar.style")
|
|
73
|
+
}, /*#__PURE__*/React.createElement("div", {
|
|
74
|
+
className: "divide-y divide-gray-200"
|
|
75
|
+
}, /*#__PURE__*/React.createElement(FontPickerBlock, {
|
|
76
|
+
label: t("neetoMolecules.themeSidebar.font"),
|
|
77
|
+
options: FONT_OPTIONS,
|
|
78
|
+
value: findBy({
|
|
79
|
+
value: values.fontFamily
|
|
80
|
+
}, FONT_OPTIONS) || null,
|
|
81
|
+
onChange: function onChange(_ref4) {
|
|
82
|
+
var value = _ref4.value;
|
|
83
|
+
return handleChange("fontFamily", value);
|
|
84
|
+
}
|
|
85
|
+
}), /*#__PURE__*/React.createElement(ColorBlock, {
|
|
86
|
+
color: questionColor,
|
|
87
|
+
label: t("neetoMolecules.themeSidebar.questions"),
|
|
88
|
+
onChange: handleColorChange("questionColor")
|
|
89
|
+
}), /*#__PURE__*/React.createElement(ColorBlock, {
|
|
90
|
+
color: answerColor,
|
|
91
|
+
label: t("neetoMolecules.themeSidebar.answerColor"),
|
|
92
|
+
onChange: handleAnswerColorChange
|
|
93
|
+
}), /*#__PURE__*/React.createElement(ColorBlock, {
|
|
94
|
+
color: buttonBackgroundColor,
|
|
95
|
+
label: t("neetoMolecules.themeSidebar.buttons"),
|
|
96
|
+
onChange: handleColorChange("buttonBackgroundColor")
|
|
97
|
+
}), /*#__PURE__*/React.createElement(ColorBlock, {
|
|
98
|
+
color: buttonTextColor,
|
|
99
|
+
label: t("neetoMolecules.themeSidebar.buttonText"),
|
|
100
|
+
onChange: handleColorChange("buttonTextColor")
|
|
101
|
+
}), /*#__PURE__*/React.createElement(SliderBlock, {
|
|
102
|
+
defaultValue: buttonBorderRadius,
|
|
103
|
+
label: t("neetoMolecules.themeSidebar.buttonBorderRadius"),
|
|
104
|
+
max: 50,
|
|
105
|
+
min: 0,
|
|
106
|
+
onChange: function onChange(borderRadius) {
|
|
107
|
+
return handleChange("buttonBorderRadius", borderRadius, "".concat(borderRadius, "px"));
|
|
108
|
+
}
|
|
109
|
+
}), /*#__PURE__*/React.createElement(ColorBlock, {
|
|
110
|
+
color: backgroundColor,
|
|
111
|
+
label: t("neetoMolecules.themeSidebar.backgroundColor"),
|
|
112
|
+
onChange: function onChange(_ref5) {
|
|
113
|
+
var hex = _ref5.hex,
|
|
114
|
+
rgb = _ref5.rgb;
|
|
115
|
+
handleColorChange("backgroundColor")({
|
|
116
|
+
hex: hex,
|
|
117
|
+
rgb: rgb
|
|
118
|
+
});
|
|
119
|
+
handleChange("isDominantBackgroundColorEnabled", false);
|
|
120
|
+
}
|
|
121
|
+
}), /*#__PURE__*/React.createElement(SwitchBlock, {
|
|
122
|
+
label: t("neetoMolecules.themeSidebar.enableContentBackground"),
|
|
123
|
+
name: "isContentBackgroundEnabled"
|
|
124
|
+
}), isContentBackgroundEnabled && /*#__PURE__*/React.createElement(ColorBlock, {
|
|
125
|
+
color: contentBackgroundColor,
|
|
126
|
+
label: t("neetoMolecules.themeSidebar.formBackgroundColor"),
|
|
127
|
+
onChange: handleColorChange("contentBackgroundColor")
|
|
128
|
+
}), /*#__PURE__*/React.createElement(ImageBlock, {
|
|
129
|
+
imageData: backgroundImage,
|
|
130
|
+
label: t("neetoMolecules.themeSidebar.backgroundImage"),
|
|
131
|
+
name: "backgroundImage",
|
|
132
|
+
onChange: function onChange(name, value, variableValue) {
|
|
133
|
+
handleChange(name, value, variableValue);
|
|
134
|
+
handleChange("backgroundOverlayOpacity", 0);
|
|
135
|
+
}
|
|
136
|
+
}), (backgroundImage === null || backgroundImage === void 0 ? void 0 : backgroundImage.url) && /*#__PURE__*/React.createElement(React.Fragment, null, /*#__PURE__*/React.createElement(SliderBlock, {
|
|
137
|
+
defaultValue: backgroundOverlayOpacity,
|
|
138
|
+
label: t("neetoMolecules.themeSidebar.backgroundOverlay"),
|
|
139
|
+
marks: {
|
|
140
|
+
0: " "
|
|
141
|
+
},
|
|
142
|
+
max: 100,
|
|
143
|
+
min: -100,
|
|
144
|
+
onChange: handleOverlayChange
|
|
145
|
+
}), /*#__PURE__*/React.createElement(SwitchBlock, {
|
|
146
|
+
name: "isDominantBackgroundColorEnabled",
|
|
147
|
+
label: t("neetoMolecules.themeSidebar.enableDominantBackgroundColor")
|
|
148
|
+
}), /*#__PURE__*/React.createElement(SelectBlock, {
|
|
149
|
+
label: t("neetoMolecules.themeSidebar.backgroundPosition"),
|
|
150
|
+
options: BACKGROUND_POSITION_OPTIONS,
|
|
151
|
+
placeholder: t("neetoMolecules.themeSidebar.left"),
|
|
152
|
+
value: findBy({
|
|
153
|
+
value: backgroundImage.backgroundPosition || "center"
|
|
154
|
+
}, BACKGROUND_POSITION_OPTIONS),
|
|
155
|
+
onChange: function onChange(_ref6) {
|
|
156
|
+
var value = _ref6.value;
|
|
157
|
+
return handleChange("backgroundImage.backgroundPosition", value);
|
|
158
|
+
}
|
|
159
|
+
})), /*#__PURE__*/React.createElement(AlignmentBlock, {
|
|
160
|
+
label: t("neetoMolecules.themeSidebar.thankYouTextAlignment"),
|
|
161
|
+
name: "thankYouTextAlignment"
|
|
162
|
+
}), /*#__PURE__*/React.createElement(AlignmentBlock, {
|
|
163
|
+
label: t("neetoMolecules.themeSidebar.welcomeTextAlignment"),
|
|
164
|
+
name: "welcomeTextAlignment"
|
|
165
|
+
}), /*#__PURE__*/React.createElement(AlignmentBlock, {
|
|
166
|
+
label: t("neetoMolecules.themeSidebar.questionsTextAlignment"),
|
|
167
|
+
name: "questionsTextAlignment"
|
|
168
|
+
})));
|
|
169
|
+
};
|
|
170
|
+
export default Properties;
|
|
@@ -0,0 +1,66 @@
|
|
|
1
|
+
import React from "react";
|
|
2
|
+
import { Button } from "@bigbinary/neetoui";
|
|
3
|
+
import { Form } from "@bigbinary/neetoui/formik";
|
|
4
|
+
import { useTranslation } from "react-i18next";
|
|
5
|
+
import Logo from "./Logo";
|
|
6
|
+
import Properties from "./Properties";
|
|
7
|
+
import { INITIAL_STATE, THEME_VALIDATION_SCHEMA } from "../constants";
|
|
8
|
+
import Card from "../fields/Card";
|
|
9
|
+
import TextBlock from "../fields/TextBlock";
|
|
10
|
+
import { parseTheme } from "../utils";
|
|
11
|
+
var Customize = function Customize(_ref) {
|
|
12
|
+
var theme = _ref.theme,
|
|
13
|
+
handleFormSubmit = _ref.handleFormSubmit;
|
|
14
|
+
var _useTranslation = useTranslation(),
|
|
15
|
+
t = _useTranslation.t;
|
|
16
|
+
var getInitialValues = function getInitialValues() {
|
|
17
|
+
return theme ? parseTheme(theme) : INITIAL_STATE;
|
|
18
|
+
};
|
|
19
|
+
return /*#__PURE__*/React.createElement(Form, {
|
|
20
|
+
formikProps: {
|
|
21
|
+
enableReinitialize: true,
|
|
22
|
+
initialValues: getInitialValues(),
|
|
23
|
+
onSubmit: handleFormSubmit,
|
|
24
|
+
validationSchema: THEME_VALIDATION_SCHEMA,
|
|
25
|
+
validateOnBlur: true,
|
|
26
|
+
validateOnChange: true
|
|
27
|
+
}
|
|
28
|
+
}, function (_ref2) {
|
|
29
|
+
var values = _ref2.values,
|
|
30
|
+
dirty = _ref2.dirty,
|
|
31
|
+
isSubmitting = _ref2.isSubmitting,
|
|
32
|
+
setFieldValue = _ref2.setFieldValue;
|
|
33
|
+
return /*#__PURE__*/React.createElement("div", {
|
|
34
|
+
className: "neeto-molecules-theme-design-sidebar__scroll"
|
|
35
|
+
}, /*#__PURE__*/React.createElement("div", {
|
|
36
|
+
className: "flex flex-col gap-6 p-4"
|
|
37
|
+
}, /*#__PURE__*/React.createElement(Card, {
|
|
38
|
+
title: t("neetoMolecules.themeSidebar.name")
|
|
39
|
+
}, /*#__PURE__*/React.createElement(TextBlock, {
|
|
40
|
+
autoFocus: true,
|
|
41
|
+
name: "name"
|
|
42
|
+
})), /*#__PURE__*/React.createElement(Properties, {
|
|
43
|
+
handleChange: setFieldValue,
|
|
44
|
+
values: values
|
|
45
|
+
}), /*#__PURE__*/React.createElement(Logo, {
|
|
46
|
+
logo: values.logo,
|
|
47
|
+
onChange: setFieldValue
|
|
48
|
+
})), /*#__PURE__*/React.createElement("div", {
|
|
49
|
+
className: "neeto-ui-bg-white neeto-ui-shadow-s sticky bottom-0 left-0 right-0 py-6 px-4"
|
|
50
|
+
}, /*#__PURE__*/React.createElement(Button, {
|
|
51
|
+
"data-cy": "save-changes-button",
|
|
52
|
+
disabled: !dirty && theme.id,
|
|
53
|
+
label: t("neetoMolecules.common.actions.save"),
|
|
54
|
+
loading: isSubmitting,
|
|
55
|
+
type: "submit"
|
|
56
|
+
}), /*#__PURE__*/React.createElement(Button, {
|
|
57
|
+
className: "ml-2",
|
|
58
|
+
"data-cy": "reset-button",
|
|
59
|
+
disabled: !dirty,
|
|
60
|
+
label: t("neetoMolecules.common.actions.reset"),
|
|
61
|
+
style: "text",
|
|
62
|
+
type: "reset"
|
|
63
|
+
})));
|
|
64
|
+
});
|
|
65
|
+
};
|
|
66
|
+
export default Customize;
|
|
@@ -0,0 +1,135 @@
|
|
|
1
|
+
import _objectWithoutProperties from "@babel/runtime/helpers/objectWithoutProperties";
|
|
2
|
+
var _excluded = ["name"];
|
|
3
|
+
import React from "react";
|
|
4
|
+
import classnames from "classnames";
|
|
5
|
+
import { isPresent } from "@bigbinary/neeto-commons-frontend/pure";
|
|
6
|
+
import { Typography, Tag, Button } from "@bigbinary/neetoui";
|
|
7
|
+
import { path } from "ramda";
|
|
8
|
+
import { useTranslation } from "react-i18next";
|
|
9
|
+
import MoreDropdown from "../../MoreDropdown";
|
|
10
|
+
var ThemeCard = function ThemeCard(_ref) {
|
|
11
|
+
var _ref$active = _ref.active,
|
|
12
|
+
active = _ref$active === void 0 ? false : _ref$active,
|
|
13
|
+
isPreviewing = _ref.isPreviewing,
|
|
14
|
+
onSetPreviewTheme = _ref.onSetPreviewTheme,
|
|
15
|
+
onDeleteTheme = _ref.onDeleteTheme,
|
|
16
|
+
onEditTheme = _ref.onEditTheme,
|
|
17
|
+
onApplyTheme = _ref.onApplyTheme,
|
|
18
|
+
onCloneTheme = _ref.onCloneTheme,
|
|
19
|
+
theme = _ref.theme,
|
|
20
|
+
isHighLightedTheme = _ref.isHighLightedTheme,
|
|
21
|
+
isApplyingTheme = _ref.isApplyingTheme;
|
|
22
|
+
var _useTranslation = useTranslation(),
|
|
23
|
+
t = _useTranslation.t;
|
|
24
|
+
var name = theme.name,
|
|
25
|
+
styles = _objectWithoutProperties(theme, _excluded);
|
|
26
|
+
var handleApplyTheme = function handleApplyTheme() {
|
|
27
|
+
if (isApplyingTheme) return;
|
|
28
|
+
onApplyTheme(theme);
|
|
29
|
+
};
|
|
30
|
+
var moreMenuItems = [{
|
|
31
|
+
"data-cy": "theme-edit-button",
|
|
32
|
+
key: "theme-edit-button",
|
|
33
|
+
onClick: function onClick() {
|
|
34
|
+
return onEditTheme(theme);
|
|
35
|
+
},
|
|
36
|
+
label: t("neetoMolecules.common.actions.edit"),
|
|
37
|
+
isVisible: isPresent(onEditTheme)
|
|
38
|
+
}, {
|
|
39
|
+
isVisible: isPresent(onCloneTheme),
|
|
40
|
+
"data-cy": "theme-clone-button",
|
|
41
|
+
key: "theme-clone-button",
|
|
42
|
+
onClick: function onClick() {
|
|
43
|
+
return onCloneTheme(theme);
|
|
44
|
+
},
|
|
45
|
+
label: t("neetoMolecules.themeSidebar.themeOptions.clone")
|
|
46
|
+
}, {
|
|
47
|
+
isVisible: isPresent(onDeleteTheme),
|
|
48
|
+
type: "divider",
|
|
49
|
+
key: "divider"
|
|
50
|
+
}, {
|
|
51
|
+
isVisible: isPresent(onDeleteTheme),
|
|
52
|
+
"data-cy": "theme-delete-button",
|
|
53
|
+
key: "theme-delete-button",
|
|
54
|
+
onClick: function onClick() {
|
|
55
|
+
return onDeleteTheme(theme);
|
|
56
|
+
},
|
|
57
|
+
label: t("neetoMolecules.themeSidebar.themeOptions.delete")
|
|
58
|
+
}];
|
|
59
|
+
return /*#__PURE__*/React.createElement("div", {
|
|
60
|
+
className: "group space-y-2",
|
|
61
|
+
"data-cy": active ? "active-theme-card" : "theme-card",
|
|
62
|
+
id: theme.id
|
|
63
|
+
}, /*#__PURE__*/React.createElement("div", {
|
|
64
|
+
className: classnames("neeto-molecules-theme-thumbnail neeto-ui-rounded-lg border transition-all duration-300 ease-in-out", {
|
|
65
|
+
"neeto-ui-border-gray-400": !active,
|
|
66
|
+
"neeto-ui-border-gray-800 neeto-molecules-theme-thumbnail--active": active,
|
|
67
|
+
"neeto-molecules-theme-thumbnail--preview-active": isPreviewing,
|
|
68
|
+
"neeto-molecules-theme-thumbnail--highlight-active": isHighLightedTheme
|
|
69
|
+
}),
|
|
70
|
+
style: {
|
|
71
|
+
backgroundColor: path(["colorScheme", "backgroundColor"], styles),
|
|
72
|
+
backgroundImage: path(["backgroundImage", "url"], styles) ? "url(".concat(path(["backgroundImage", "url"], styles), ")") : "initial",
|
|
73
|
+
backgroundSize: "cover"
|
|
74
|
+
},
|
|
75
|
+
onClick: function onClick() {
|
|
76
|
+
return onSetPreviewTheme(theme);
|
|
77
|
+
}
|
|
78
|
+
}, /*#__PURE__*/React.createElement("div", {
|
|
79
|
+
className: "group-hover:opacity-85 neeto-ui-rounded-lg cursor-pointer p-6 transition-all duration-300 ease-in-out"
|
|
80
|
+
}, /*#__PURE__*/React.createElement("div", {
|
|
81
|
+
className: "mb-3"
|
|
82
|
+
}, /*#__PURE__*/React.createElement(Typography, {
|
|
83
|
+
style: "h3",
|
|
84
|
+
weight: "semibold"
|
|
85
|
+
}, /*#__PURE__*/React.createElement("span", {
|
|
86
|
+
style: {
|
|
87
|
+
color: path(["colorScheme", "questionColor"], styles)
|
|
88
|
+
}
|
|
89
|
+
}, t("neetoMolecules.themeSidebar.themeCard.question"))), /*#__PURE__*/React.createElement(Typography, {
|
|
90
|
+
className: "neeto-ui-text-gray-600",
|
|
91
|
+
style: "body2"
|
|
92
|
+
}, /*#__PURE__*/React.createElement("span", {
|
|
93
|
+
style: {
|
|
94
|
+
color: path(["colorScheme", "answerColor"], styles)
|
|
95
|
+
}
|
|
96
|
+
}, t("neetoMolecules.themeSidebar.themeCard.answer")))), /*#__PURE__*/React.createElement("div", {
|
|
97
|
+
className: "neeto-ui-rounded-lg h-5 w-12",
|
|
98
|
+
style: {
|
|
99
|
+
backgroundColor: path(["colorScheme", "buttonBackgroundColor"], styles)
|
|
100
|
+
}
|
|
101
|
+
}))), /*#__PURE__*/React.createElement("div", {
|
|
102
|
+
className: "flex items-start justify-between gap-1"
|
|
103
|
+
}, /*#__PURE__*/React.createElement(Typography, {
|
|
104
|
+
className: "min-w-0 flex-grow break-words pt-1 line-clamp-2",
|
|
105
|
+
"data-cy": "theme-name",
|
|
106
|
+
lineHeight: "snug",
|
|
107
|
+
style: "body2"
|
|
108
|
+
}, name), /*#__PURE__*/React.createElement("div", {
|
|
109
|
+
className: "flex items-center gap-2"
|
|
110
|
+
}, active ? /*#__PURE__*/React.createElement(Tag, {
|
|
111
|
+
className: "flex-shrink-0",
|
|
112
|
+
"data-cy": "active-theme-label",
|
|
113
|
+
label: t("neetoMolecules.themeSidebar.active"),
|
|
114
|
+
style: "success"
|
|
115
|
+
}) : /*#__PURE__*/React.createElement(Button, {
|
|
116
|
+
className: "flex-shrink-0",
|
|
117
|
+
"data-cy": "apply-theme-button",
|
|
118
|
+
disabled: isApplyingTheme,
|
|
119
|
+
label: t("neetoMolecules.common.actions.apply"),
|
|
120
|
+
loading: isApplyingTheme,
|
|
121
|
+
size: "small",
|
|
122
|
+
style: "link",
|
|
123
|
+
onClick: handleApplyTheme
|
|
124
|
+
}), /*#__PURE__*/React.createElement(MoreDropdown, {
|
|
125
|
+
buttonProps: {
|
|
126
|
+
buttonSize: "small"
|
|
127
|
+
},
|
|
128
|
+
menuItems: moreMenuItems,
|
|
129
|
+
dropdownButtonProps: {
|
|
130
|
+
"data-cy": "theme-card-options",
|
|
131
|
+
strategy: "fixed"
|
|
132
|
+
}
|
|
133
|
+
}))));
|
|
134
|
+
};
|
|
135
|
+
export default ThemeCard;
|
|
@@ -0,0 +1,110 @@
|
|
|
1
|
+
import _slicedToArray from "@babel/runtime/helpers/slicedToArray";
|
|
2
|
+
import React, { useEffect, useState } from "react";
|
|
3
|
+
import { isNotEmpty } from "@bigbinary/neeto-commons-frontend/pure";
|
|
4
|
+
import { Search } from "@bigbinary/neeto-icons";
|
|
5
|
+
import { Input, Typography } from "@bigbinary/neetoui";
|
|
6
|
+
import { isEmpty } from "ramda";
|
|
7
|
+
import { useTranslation } from "react-i18next";
|
|
8
|
+
import ThemeCard from "./ThemeCard";
|
|
9
|
+
import { scrollElementIntoView } from "../utils";
|
|
10
|
+
var Themes = function Themes(_ref) {
|
|
11
|
+
var currentTheme = _ref.currentTheme,
|
|
12
|
+
onCloneTheme = _ref.onCloneTheme,
|
|
13
|
+
_ref$customThemes = _ref.customThemes,
|
|
14
|
+
customThemes = _ref$customThemes === void 0 ? [] : _ref$customThemes,
|
|
15
|
+
_ref$defaultThemes = _ref.defaultThemes,
|
|
16
|
+
defaultThemes = _ref$defaultThemes === void 0 ? [] : _ref$defaultThemes,
|
|
17
|
+
onDeleteTheme = _ref.onDeleteTheme,
|
|
18
|
+
onEditTheme = _ref.onEditTheme,
|
|
19
|
+
onApplyTheme = _ref.onApplyTheme,
|
|
20
|
+
previewingTheme = _ref.previewingTheme,
|
|
21
|
+
setPreviewingTheme = _ref.setPreviewingTheme,
|
|
22
|
+
themeToHighlight = _ref.themeToHighlight,
|
|
23
|
+
didScrollActiveThemeIntoView = _ref.didScrollActiveThemeIntoView,
|
|
24
|
+
applyingThemeId = _ref.applyingThemeId;
|
|
25
|
+
var _useTranslation = useTranslation(),
|
|
26
|
+
t = _useTranslation.t;
|
|
27
|
+
var _useState = useState(""),
|
|
28
|
+
_useState2 = _slicedToArray(_useState, 2),
|
|
29
|
+
searchQuery = _useState2[0],
|
|
30
|
+
setSearchQuery = _useState2[1];
|
|
31
|
+
var filteredDefaultThemes = defaultThemes.filter(function (theme) {
|
|
32
|
+
return theme.name.toLowerCase().includes(searchQuery.toLowerCase());
|
|
33
|
+
});
|
|
34
|
+
var filteredThemes = customThemes.filter(function (theme) {
|
|
35
|
+
return theme.name.toLowerCase().includes(searchQuery.toLowerCase());
|
|
36
|
+
});
|
|
37
|
+
var isSearchFieldVisible = (customThemes === null || customThemes === void 0 ? void 0 : customThemes.length) + (defaultThemes === null || defaultThemes === void 0 ? void 0 : defaultThemes.length) > 10;
|
|
38
|
+
useEffect(function () {
|
|
39
|
+
if (didScrollActiveThemeIntoView.current || !(currentTheme !== null && currentTheme !== void 0 && currentTheme.id)) return;
|
|
40
|
+
didScrollActiveThemeIntoView.current = true;
|
|
41
|
+
setTimeout(function () {
|
|
42
|
+
scrollElementIntoView(currentTheme.id);
|
|
43
|
+
}, 200);
|
|
44
|
+
}, [didScrollActiveThemeIntoView, currentTheme === null || currentTheme === void 0 ? void 0 : currentTheme.id]);
|
|
45
|
+
return /*#__PURE__*/React.createElement("div", {
|
|
46
|
+
className: "neeto-molecules-theme-design-sidebar__scroll"
|
|
47
|
+
}, /*#__PURE__*/React.createElement("div", {
|
|
48
|
+
className: "mb-6 space-y-3"
|
|
49
|
+
}, isSearchFieldVisible && /*#__PURE__*/React.createElement(Input, {
|
|
50
|
+
autoFocus: true,
|
|
51
|
+
autoComplete: "off",
|
|
52
|
+
className: "mb-4 mt-1 px-6",
|
|
53
|
+
placeholder: t("neetoMolecules.themeSidebar.searchThemes"),
|
|
54
|
+
prefix: /*#__PURE__*/React.createElement(Search, null),
|
|
55
|
+
type: "search",
|
|
56
|
+
value: searchQuery,
|
|
57
|
+
onChange: function onChange(e) {
|
|
58
|
+
return setSearchQuery(e.target.value);
|
|
59
|
+
}
|
|
60
|
+
}), isEmpty(filteredThemes) && isEmpty(filteredDefaultThemes) && /*#__PURE__*/React.createElement(Typography, {
|
|
61
|
+
className: "text-center",
|
|
62
|
+
style: "body2"
|
|
63
|
+
}, t("neetoMolecules.common.notFound.title", {
|
|
64
|
+
entity: t("neetoMolecules.themeSidebar.theme", {
|
|
65
|
+
count: 2
|
|
66
|
+
})
|
|
67
|
+
})), isNotEmpty(filteredDefaultThemes) && /*#__PURE__*/React.createElement(React.Fragment, null, /*#__PURE__*/React.createElement(Typography, {
|
|
68
|
+
className: "my-4 px-6 uppercase",
|
|
69
|
+
"data-cy": "system-themes-header",
|
|
70
|
+
style: "h6",
|
|
71
|
+
weight: "semibold"
|
|
72
|
+
}, t("neetoMolecules.themeSidebar.systemThemes")), /*#__PURE__*/React.createElement("div", {
|
|
73
|
+
className: "flex flex-col gap-4 px-6"
|
|
74
|
+
}, filteredDefaultThemes.map(function (theme) {
|
|
75
|
+
return /*#__PURE__*/React.createElement(ThemeCard, {
|
|
76
|
+
active: (currentTheme === null || currentTheme === void 0 ? void 0 : currentTheme.id) === theme.id,
|
|
77
|
+
isApplyingTheme: applyingThemeId === theme.id,
|
|
78
|
+
isPreviewing: (previewingTheme === null || previewingTheme === void 0 ? void 0 : previewingTheme.id) === theme.id,
|
|
79
|
+
key: theme.id,
|
|
80
|
+
onApplyTheme: onApplyTheme,
|
|
81
|
+
onCloneTheme: onCloneTheme,
|
|
82
|
+
theme: theme,
|
|
83
|
+
onSetPreviewTheme: setPreviewingTheme
|
|
84
|
+
});
|
|
85
|
+
})))), isNotEmpty(filteredThemes) && /*#__PURE__*/React.createElement("div", {
|
|
86
|
+
className: "mb-6 space-y-3"
|
|
87
|
+
}, /*#__PURE__*/React.createElement(Typography, {
|
|
88
|
+
className: "my-4 px-6 uppercase",
|
|
89
|
+
"data-cy": "custom-themes-header",
|
|
90
|
+
style: "h6",
|
|
91
|
+
weight: "semibold"
|
|
92
|
+
}, t("neetoMolecules.themeSidebar.customThemes")), /*#__PURE__*/React.createElement("div", {
|
|
93
|
+
className: "flex flex-col gap-4 px-6"
|
|
94
|
+
}, filteredThemes.map(function (theme) {
|
|
95
|
+
var isActive = (currentTheme === null || currentTheme === void 0 ? void 0 : currentTheme.id) === theme.id;
|
|
96
|
+
return /*#__PURE__*/React.createElement(ThemeCard, {
|
|
97
|
+
active: isActive,
|
|
98
|
+
isHighLightedTheme: theme.id === themeToHighlight,
|
|
99
|
+
isPreviewing: (previewingTheme === null || previewingTheme === void 0 ? void 0 : previewingTheme.id) === theme.id,
|
|
100
|
+
key: theme.id,
|
|
101
|
+
onApplyTheme: onApplyTheme,
|
|
102
|
+
onCloneTheme: onCloneTheme,
|
|
103
|
+
onEditTheme: onEditTheme,
|
|
104
|
+
theme: theme,
|
|
105
|
+
onDeleteTheme: !isActive ? onDeleteTheme : null,
|
|
106
|
+
onSetPreviewTheme: setPreviewingTheme
|
|
107
|
+
});
|
|
108
|
+
}))));
|
|
109
|
+
};
|
|
110
|
+
export default Themes;
|
|
@@ -0,0 +1,62 @@
|
|
|
1
|
+
import React from "react";
|
|
2
|
+
import classnames from "classnames";
|
|
3
|
+
import { capitalize } from "@bigbinary/neeto-commons-frontend/pure";
|
|
4
|
+
import { LeftArrow, Plus } from "@bigbinary/neeto-icons";
|
|
5
|
+
import { Button, Typography } from "@bigbinary/neetoui";
|
|
6
|
+
import { useTranslation } from "react-i18next";
|
|
7
|
+
import { DESIGN_SCREENS } from "./constants";
|
|
8
|
+
var TitleBar = function TitleBar(_ref) {
|
|
9
|
+
var currentScreen = _ref.currentScreen,
|
|
10
|
+
handleBackPress = _ref.handleBackPress,
|
|
11
|
+
handleCreateNewTheme = _ref.handleCreateNewTheme,
|
|
12
|
+
isNewTheme = _ref.isNewTheme;
|
|
13
|
+
var _useTranslation = useTranslation(),
|
|
14
|
+
t = _useTranslation.t;
|
|
15
|
+
if (currentScreen === DESIGN_SCREENS.CUSTOMIZE) {
|
|
16
|
+
return /*#__PURE__*/React.createElement("div", {
|
|
17
|
+
className: classnames("neeto-molecules-theme-design-sidebar__header px-4")
|
|
18
|
+
}, /*#__PURE__*/React.createElement("div", {
|
|
19
|
+
className: "flex items-center justify-start space-x-2"
|
|
20
|
+
}, /*#__PURE__*/React.createElement(Button, {
|
|
21
|
+
"data-cy": "customise-themes-back-button",
|
|
22
|
+
icon: LeftArrow,
|
|
23
|
+
iconPosition: "left",
|
|
24
|
+
style: "text",
|
|
25
|
+
tooltipProps: {
|
|
26
|
+
content: t("neetoMolecules.themeSidebar.backToThemes"),
|
|
27
|
+
position: "top"
|
|
28
|
+
},
|
|
29
|
+
onClick: handleBackPress
|
|
30
|
+
}), /*#__PURE__*/React.createElement(Typography, {
|
|
31
|
+
"data-cy": "themes-header",
|
|
32
|
+
lineHeight: "normal",
|
|
33
|
+
style: "h3",
|
|
34
|
+
weight: "semibold"
|
|
35
|
+
}, isNewTheme ? t("neetoMolecules.themeSidebar.createTheme.title") : t("neetoMolecules.themeSidebar.editTheme.title"))));
|
|
36
|
+
}
|
|
37
|
+
return /*#__PURE__*/React.createElement("div", {
|
|
38
|
+
className: classnames("neeto-molecules-theme-design-sidebar__header px-6")
|
|
39
|
+
}, /*#__PURE__*/React.createElement("div", {
|
|
40
|
+
className: "flex items-center justify-between space-x-2"
|
|
41
|
+
}, /*#__PURE__*/React.createElement(Typography, {
|
|
42
|
+
"data-cy": "themes-header",
|
|
43
|
+
lineHeight: "normal",
|
|
44
|
+
style: "h3",
|
|
45
|
+
weight: "semibold"
|
|
46
|
+
}, capitalize(t("neetoMolecules.themeSidebar.theme", {
|
|
47
|
+
count: 2
|
|
48
|
+
}))), /*#__PURE__*/React.createElement("div", {
|
|
49
|
+
className: "self-end"
|
|
50
|
+
}, /*#__PURE__*/React.createElement(Button, {
|
|
51
|
+
"data-cy": "customise-themes-add-theme-button",
|
|
52
|
+
icon: Plus,
|
|
53
|
+
iconPosition: "left",
|
|
54
|
+
style: "text",
|
|
55
|
+
tooltipProps: {
|
|
56
|
+
content: t("neetoMolecules.themeSidebar.addNewTheme"),
|
|
57
|
+
position: "top"
|
|
58
|
+
},
|
|
59
|
+
onClick: handleCreateNewTheme
|
|
60
|
+
}))));
|
|
61
|
+
};
|
|
62
|
+
export default TitleBar;
|