@webiny/app-admin 0.0.0-unstable.eb196ccd2f → 0.0.0-unstable.f6dc066313
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/README.md +7 -17
- package/base/Admin.d.ts +5 -2
- package/base/Admin.js +34 -16
- package/base/Admin.js.map +1 -1
- package/base/Base/LexicalPreset.d.ts +2 -0
- package/base/Base/LexicalPreset.js +67 -0
- package/base/Base/LexicalPreset.js.map +1 -0
- package/base/Base/Menus/SupportMenuItems.d.ts +2 -2
- package/base/Base/Menus/SupportMenuItems.js +2 -4
- package/base/Base/Menus/SupportMenuItems.js.map +1 -1
- package/base/Base/Menus/WebinyVersion.js +4 -4
- package/base/Base/Menus/WebinyVersion.js.map +1 -1
- package/base/Base/Menus.js +37 -42
- package/base/Base/Menus.js.map +1 -1
- package/base/Base/RoutesConfig.d.ts +2 -0
- package/base/Base/RoutesConfig.js +30 -0
- package/base/Base/RoutesConfig.js.map +1 -0
- package/base/Base/Tenant/wby-horizontal.svg +23 -0
- package/base/Base/Tenant.js +14 -9
- package/base/Base/Tenant.js.map +1 -1
- package/base/Base/UserMenu/ExitTenant.d.ts +20 -0
- package/base/Base/UserMenu/ExitTenant.js +37 -0
- package/base/Base/UserMenu/ExitTenant.js.map +1 -0
- package/base/Base/UserMenu/SignOut.d.ts +2 -0
- package/base/Base/UserMenu/SignOut.js +19 -0
- package/base/Base/UserMenu/SignOut.js.map +1 -0
- package/base/Base/UserMenu/UserInfo.d.ts +6 -0
- package/base/Base/UserMenu/UserInfo.js +43 -0
- package/base/Base/UserMenu/UserInfo.js.map +1 -0
- package/base/Base/UserMenu.d.ts +2 -0
- package/base/Base/UserMenu.js +21 -0
- package/base/Base/UserMenu.js.map +1 -0
- package/base/Base.js +6 -8
- package/base/Base.js.map +1 -1
- package/base/TelemetryAdminAppStart.d.ts +1 -0
- package/base/TelemetryAdminAppStart.js +19 -0
- package/base/TelemetryAdminAppStart.js.map +1 -0
- package/base/WebinyVersion.js +4 -4
- package/base/WebinyVersion.js.map +1 -1
- package/base/createRootContainer.d.ts +2 -0
- package/base/createRootContainer.js +55 -0
- package/base/createRootContainer.js.map +1 -0
- package/base/plugins/AddGraphQLQuerySelection.js +1 -1
- package/base/plugins/AddGraphQLQuerySelection.js.map +1 -1
- package/base/providers/AdminUiStateProvider.js +1 -1
- package/base/providers/AdminUiStateProvider.js.map +1 -1
- package/base/providers/ApolloProvider.d.ts +1 -1
- package/base/providers/ApolloProvider.js +2 -5
- package/base/providers/ApolloProvider.js.map +1 -1
- package/base/providers/UiProviders.js +24 -3
- package/base/providers/UiProviders.js.map +1 -1
- package/base/providers/UiStateProvider.js +1 -1
- package/base/providers/UiStateProvider.js.map +1 -1
- package/base/ui/CenteredView.d.ts +1 -1
- package/base/ui/CenteredView.js +2 -2
- package/base/ui/CenteredView.js.map +1 -1
- package/base/ui/FileManager.d.ts +9 -21
- package/base/ui/FileManager.js +18 -12
- package/base/ui/FileManager.js.map +1 -1
- package/base/ui/LoginScreen.d.ts +19 -0
- package/base/ui/LoginScreen.js +2 -1
- package/base/ui/LoginScreen.js.map +1 -1
- package/base/ui/Navigation.js +1 -1
- package/base/ui/Navigation.js.map +1 -1
- package/base/ui/UserMenu/UserMenuItem.d.ts +5 -5
- package/base/ui/UserMenu/UserMenuItem.js +1 -1
- package/base/ui/UserMenu/UserMenuItem.js.map +1 -1
- package/base/ui/UserMenu/UserMenuLink.d.ts +5 -5
- package/base/ui/UserMenu/UserMenuLink.js +1 -1
- package/base/ui/UserMenu/UserMenuLink.js.map +1 -1
- package/base/ui/UserMenu/UserMenuSeparator.d.ts +8 -8
- package/base/ui/UserMenu/UserMenuSeparator.js +1 -1
- package/base/ui/UserMenu/UserMenuSeparator.js.map +1 -1
- package/base/ui/UserMenu.d.ts +3 -3
- package/base/ui/UserMenu.js +3 -3
- package/base/ui/UserMenu.js.map +1 -1
- package/components/AdminLayout.js +1 -1
- package/components/AdminLayout.js.map +1 -1
- package/components/BulkActions/Worker.d.ts +0 -1
- package/components/BulkActions/Worker.js +1 -1
- package/components/BulkActions/Worker.js.map +1 -1
- package/components/BulkActions/index.d.ts +2 -2
- package/components/BulkActions/index.js +2 -2
- package/components/BulkActions/index.js.map +1 -1
- package/components/BulkActions/useDialogWithReport/DialogMessage.d.ts +1 -1
- package/components/BulkActions/useDialogWithReport/DialogMessage.js +2 -2
- package/components/BulkActions/useDialogWithReport/DialogMessage.js.map +1 -1
- package/components/BulkActions/useDialogWithReport/index.d.ts +1 -1
- package/components/BulkActions/useDialogWithReport/index.js +1 -1
- package/components/BulkActions/useDialogWithReport/index.js.map +1 -1
- package/components/BulkActions/useDialogWithReport/useDialogWithReport.d.ts +1 -1
- package/components/BulkActions/useDialogWithReport/useDialogWithReport.js +2 -2
- package/components/BulkActions/useDialogWithReport/useDialogWithReport.js.map +1 -1
- package/components/Buttons/Buttons.d.ts +1 -1
- package/components/Buttons/Buttons.js +4 -4
- package/components/Buttons/Buttons.js.map +1 -1
- package/components/Buttons/Buttons.styles.d.ts +2 -3
- package/components/Buttons/Buttons.styles.js +1 -2
- package/components/Buttons/Buttons.styles.js.map +1 -1
- package/components/Buttons/index.d.ts +2 -2
- package/components/Buttons/index.js +2 -2
- package/components/Buttons/index.js.map +1 -1
- package/components/Buttons/useButtons.d.ts +1 -1
- package/components/Buttons/useButtons.js +1 -1
- package/components/Buttons/useButtons.js.map +1 -1
- package/components/DeveloperMode/DeveloperMode.d.ts +11 -0
- package/components/DeveloperMode/DeveloperMode.js +17 -0
- package/components/DeveloperMode/DeveloperMode.js.map +1 -0
- package/components/DeveloperMode/index.d.ts +2 -0
- package/components/DeveloperMode/index.js +3 -0
- package/components/DeveloperMode/index.js.map +1 -0
- package/components/Dialogs/Dialog.js +2 -2
- package/components/Dialogs/Dialog.js.map +1 -1
- package/components/Dialogs/DialogsContext.d.ts +1 -6
- package/components/Dialogs/DialogsContext.js +14 -23
- package/components/Dialogs/DialogsContext.js.map +1 -1
- package/components/Dialogs/useDialogs.d.ts +1 -2
- package/components/Dialogs/useDialogs.js +1 -2
- package/components/Dialogs/useDialogs.js.map +1 -1
- package/components/EmptyView.d.ts +1 -2
- package/components/EmptyView.js +6 -7
- package/components/EmptyView.js.map +1 -1
- package/components/Filters/Filters.d.ts +1 -1
- package/components/Filters/Filters.js +2 -2
- package/components/Filters/Filters.js.map +1 -1
- package/components/Filters/index.d.ts +2 -2
- package/components/Filters/index.js +2 -2
- package/components/Filters/index.js.map +1 -1
- package/components/FloatingActionButton.js +1 -1
- package/components/FloatingActionButton.js.map +1 -1
- package/components/FloatingPanel.js +4 -6
- package/components/FloatingPanel.js.map +1 -1
- package/components/IconPicker/IconPicker.d.ts +3 -3
- package/components/IconPicker/IconPicker.js +6 -6
- package/components/IconPicker/IconPicker.js.map +1 -1
- package/components/IconPicker/IconPickerComponent.d.ts +3 -3
- package/components/IconPicker/IconPickerComponent.js +4 -4
- package/components/IconPicker/IconPickerComponent.js.map +1 -1
- package/components/IconPicker/IconPickerPresenter.d.ts +3 -3
- package/components/IconPicker/IconPickerPresenter.js.map +1 -1
- package/components/IconPicker/IconPickerPresenter.test.js +3 -2
- package/components/IconPicker/IconPickerPresenter.test.js.map +1 -1
- package/components/IconPicker/IconPickerPresenterProvider.d.ts +1 -1
- package/components/IconPicker/IconPickerPresenterProvider.js.map +1 -1
- package/components/IconPicker/IconPickerTab.d.ts +1 -1
- package/components/IconPicker/IconPickerTab.js +10 -10
- package/components/IconPicker/IconPickerTab.js.map +1 -1
- package/components/IconPicker/IconRenderer.d.ts +1 -1
- package/components/IconPicker/IconRenderer.js.map +1 -1
- package/components/IconPicker/IconRepository.d.ts +2 -2
- package/components/IconPicker/IconRepository.js +2 -2
- package/components/IconPicker/IconRepository.js.map +1 -1
- package/components/IconPicker/IconRepository.test.js +2 -1
- package/components/IconPicker/IconRepository.test.js.map +1 -1
- package/components/IconPicker/IconRepositoryFactory.d.ts +2 -2
- package/components/IconPicker/IconRepositoryFactory.js +1 -1
- package/components/IconPicker/IconRepositoryFactory.js.map +1 -1
- package/components/IconPicker/components/IconPickerCell.d.ts +2 -2
- package/components/IconPicker/components/IconPickerCell.js +3 -3
- package/components/IconPicker/components/IconPickerCell.js.map +1 -1
- package/components/IconPicker/components/IconPickerContent.d.ts +1 -1
- package/components/IconPicker/components/IconPickerContent.js +4 -4
- package/components/IconPicker/components/IconPickerContent.js.map +1 -1
- package/components/IconPicker/components/IconPickerRow.js +1 -1
- package/components/IconPicker/components/IconPickerRow.js.map +1 -1
- package/components/IconPicker/components/IconPickerTrigger.d.ts +1 -1
- package/components/IconPicker/components/IconPickerTrigger.js +7 -7
- package/components/IconPicker/components/IconPickerTrigger.js.map +1 -1
- package/components/IconPicker/components/index.d.ts +4 -4
- package/components/IconPicker/components/index.js +4 -4
- package/components/IconPicker/components/index.js.map +1 -1
- package/components/IconPicker/config/Emojis.js +1 -1
- package/components/IconPicker/config/Emojis.js.map +1 -1
- package/components/IconPicker/config/FontAwesomeIcons.js +1 -1
- package/components/IconPicker/config/FontAwesomeIcons.js.map +1 -1
- package/components/IconPicker/config/IconPackProvider.d.ts +1 -1
- package/components/IconPicker/config/IconPackProvider.js.map +1 -1
- package/components/IconPicker/config/IconType.js +2 -2
- package/components/IconPicker/config/IconType.js.map +1 -1
- package/components/IconPicker/config/index.d.ts +3 -3
- package/components/IconPicker/config/index.js +7 -7
- package/components/IconPicker/config/index.js.map +1 -1
- package/components/IconPicker/index.d.ts +7 -7
- package/components/IconPicker/index.js +6 -6
- package/components/IconPicker/index.js.map +1 -1
- package/components/IconPicker/plugins/customPlugin.js +19 -24
- package/components/IconPicker/plugins/customPlugin.js.map +1 -1
- package/components/IconPicker/plugins/emojisPlugin.js +9 -9
- package/components/IconPicker/plugins/emojisPlugin.js.map +1 -1
- package/components/IconPicker/plugins/iconsPlugin.js +4 -4
- package/components/IconPicker/plugins/iconsPlugin.js.map +1 -1
- package/components/IconPicker/types.js.map +1 -1
- package/components/LexicalEditor/LexicalEditor.d.ts +9 -5
- package/components/LexicalEditor/LexicalEditor.js +32 -21
- package/components/LexicalEditor/LexicalEditor.js.map +1 -1
- package/components/LexicalEditor/LexicalLinkForm.d.ts +6 -0
- package/components/LexicalEditor/LexicalLinkForm.js +92 -0
- package/components/LexicalEditor/LexicalLinkForm.js.map +1 -0
- package/components/LexicalEditor/index.d.ts +3 -1
- package/components/LexicalEditor/index.js +3 -1
- package/components/LexicalEditor/index.js.map +1 -1
- package/components/LexicalEditor/lexicalValueWithHtml.d.ts +7 -0
- package/components/LexicalEditor/lexicalValueWithHtml.js +36 -0
- package/components/LexicalEditor/lexicalValueWithHtml.js.map +1 -0
- package/components/NavigationPrompt.d.ts +27 -0
- package/components/NavigationPrompt.js +39 -0
- package/components/NavigationPrompt.js.map +1 -0
- package/components/NotAuthorizedError/NotAuthorizedError.d.ts +2 -0
- package/components/NotAuthorizedError/NotAuthorizedError.js +20 -0
- package/components/NotAuthorizedError/NotAuthorizedError.js.map +1 -0
- package/components/NotAuthorizedError/SecureRouteError.svg +1 -0
- package/components/NotAuthorizedError/index.d.ts +1 -0
- package/components/NotAuthorizedError/index.js +3 -0
- package/components/NotAuthorizedError/index.js.map +1 -0
- package/components/OptionsMenu/OptionsMenu.js +1 -1
- package/components/OptionsMenu/OptionsMenu.js.map +1 -1
- package/components/OptionsMenu/index.d.ts +4 -4
- package/components/OptionsMenu/index.js +4 -4
- package/components/OptionsMenu/index.js.map +1 -1
- package/components/OptionsMenu/useOptionsMenuItem.d.ts +2 -2
- package/components/OptionsMenu/useOptionsMenuItem.js +2 -2
- package/components/OptionsMenu/useOptionsMenuItem.js.map +1 -1
- package/components/OverlayLayout/OverlayLayout.d.ts +1 -1
- package/components/OverlayLayout/OverlayLayout.js +8 -11
- package/components/OverlayLayout/OverlayLayout.js.map +1 -1
- package/components/OverlayLayout/components/OverlayBackdrop.js +1 -1
- package/components/OverlayLayout/components/OverlayBackdrop.js.map +1 -1
- package/components/OverlayLayout/components/OverlayContent.js +1 -1
- package/components/OverlayLayout/components/OverlayContent.js.map +1 -1
- package/components/OverlayLayout/components/OverlayHeader.js +3 -3
- package/components/OverlayLayout/components/OverlayHeader.js.map +1 -1
- package/components/OverlayLayout/components/OverlayRoot.js +1 -1
- package/components/OverlayLayout/components/OverlayRoot.js.map +1 -1
- package/components/OverlayLayout/components/index.d.ts +4 -4
- package/components/OverlayLayout/components/index.js +4 -4
- package/components/OverlayLayout/components/index.js.map +1 -1
- package/components/OverlayLayout/index.d.ts +1 -1
- package/components/OverlayLayout/index.js +1 -1
- package/components/OverlayLayout/index.js.map +1 -1
- package/components/Permissions/Permissions.d.ts +1 -3
- package/components/Permissions/Permissions.js +37 -31
- package/components/Permissions/Permissions.js.map +1 -1
- package/components/Permissions/PermissionsGroup.js +2 -2
- package/components/Permissions/PermissionsGroup.js.map +1 -1
- package/components/Permissions/StyledComponents.js +1 -1
- package/components/Permissions/StyledComponents.js.map +1 -1
- package/components/Permissions/index.d.ts +4 -4
- package/components/Permissions/index.js +4 -4
- package/components/Permissions/index.js.map +1 -1
- package/components/RegisterFeature.d.ts +11 -0
- package/components/RegisterFeature.js +26 -0
- package/components/RegisterFeature.js.map +1 -0
- package/components/ResizablePanels/index.d.ts +1 -1
- package/components/ResizablePanels/index.js +1 -1
- package/components/ResizablePanels/index.js.map +1 -1
- package/components/RoleAutocomplete/graphql.d.ts +1 -0
- package/components/RoleAutocomplete/graphql.js +18 -0
- package/components/RoleAutocomplete/graphql.js.map +1 -0
- package/components/RoleAutocomplete/index.d.ts +5 -0
- package/components/RoleAutocomplete/index.js +18 -0
- package/components/RoleAutocomplete/index.js.map +1 -0
- package/components/RolesMultiAutocomplete/graphql.d.ts +1 -0
- package/components/RolesMultiAutocomplete/graphql.js +23 -0
- package/components/RolesMultiAutocomplete/graphql.js.map +1 -0
- package/components/RolesMultiAutocomplete/index.d.ts +5 -0
- package/components/RolesMultiAutocomplete/index.js +19 -0
- package/components/RolesMultiAutocomplete/index.js.map +1 -0
- package/components/SearchUI.d.ts +1 -2
- package/components/SearchUI.js +1 -2
- package/components/SearchUI.js.map +1 -1
- package/components/SimpleForm/SimpleForm.d.ts +1 -1
- package/components/SimpleForm/SimpleForm.js +10 -10
- package/components/SimpleForm/SimpleForm.js.map +1 -1
- package/components/SimpleForm/index.d.ts +1 -1
- package/components/SimpleForm/index.js +1 -1
- package/components/SimpleForm/index.js.map +1 -1
- package/components/SimpleUI/InputField.js +3 -3
- package/components/SimpleUI/InputField.js.map +1 -1
- package/components/SingleImageUpload.d.ts +3 -8
- package/components/SingleImageUpload.js +1 -1
- package/components/SingleImageUpload.js.map +1 -1
- package/components/SplitView/SplitView.d.ts +7 -7
- package/components/SplitView/SplitView.js +20 -12
- package/components/SplitView/SplitView.js.map +1 -1
- package/components/SplitView/index.d.ts +1 -1
- package/components/SplitView/index.js +1 -1
- package/components/SplitView/index.js.map +1 -1
- package/components/StateInspector.js +1 -1
- package/components/StateInspector.js.map +1 -1
- package/components/TeamAutocomplete/graphql.d.ts +1 -0
- package/components/TeamAutocomplete/graphql.js +18 -0
- package/components/TeamAutocomplete/graphql.js.map +1 -0
- package/components/TeamAutocomplete/index.d.ts +5 -0
- package/components/TeamAutocomplete/index.js +18 -0
- package/components/TeamAutocomplete/index.js.map +1 -0
- package/components/TeamsMultiAutocomplete/graphql.d.ts +1 -0
- package/components/TeamsMultiAutocomplete/graphql.js +23 -0
- package/components/TeamsMultiAutocomplete/graphql.js.map +1 -0
- package/components/TeamsMultiAutocomplete/index.d.ts +5 -0
- package/components/TeamsMultiAutocomplete/index.js +19 -0
- package/components/TeamsMultiAutocomplete/index.js.map +1 -0
- package/components/Wcp.d.ts +4 -0
- package/components/Wcp.js +16 -2
- package/components/Wcp.js.map +1 -1
- package/components/index.d.ts +30 -3
- package/components/index.js +29 -3
- package/components/index.js.map +1 -1
- package/config/AdminConfig/Dashboard.d.ts +3 -0
- package/config/AdminConfig/Dashboard.js +6 -0
- package/config/AdminConfig/Dashboard.js.map +1 -0
- package/config/AdminConfig/LexicalTheme/Color.d.ts +11 -0
- package/config/AdminConfig/LexicalTheme/Color.js +45 -0
- package/config/AdminConfig/LexicalTheme/Color.js.map +1 -0
- package/config/AdminConfig/LexicalTheme/Typography.d.ts +30 -0
- package/config/AdminConfig/LexicalTheme/Typography.js +79 -0
- package/config/AdminConfig/LexicalTheme/Typography.js.map +1 -0
- package/config/AdminConfig/LexicalTheme.d.ts +9 -0
- package/config/AdminConfig/LexicalTheme.js +8 -0
- package/config/AdminConfig/LexicalTheme.js.map +1 -0
- package/config/AdminConfig/Logo.d.ts +24 -0
- package/config/AdminConfig/Logo.js +21 -0
- package/config/AdminConfig/Logo.js.map +1 -0
- package/config/AdminConfig/Menu/MenuGroup.d.ts +10 -10
- package/config/AdminConfig/Menu/MenuGroup.js +1 -1
- package/config/AdminConfig/Menu/MenuGroup.js.map +1 -1
- package/config/AdminConfig/Menu/MenuItem.d.ts +9 -9
- package/config/AdminConfig/Menu/MenuItem.js +1 -1
- package/config/AdminConfig/Menu/MenuItem.js.map +1 -1
- package/config/AdminConfig/Menu/MenuLink.d.ts +14 -14
- package/config/AdminConfig/Menu/MenuLink.js +10 -4
- package/config/AdminConfig/Menu/MenuLink.js.map +1 -1
- package/config/AdminConfig/Menu/SupportMenu/SupportMenuItem.d.ts +2 -2
- package/config/AdminConfig/Menu/SupportMenu/SupportMenuItem.js +1 -1
- package/config/AdminConfig/Menu/SupportMenu/SupportMenuItem.js.map +1 -1
- package/config/AdminConfig/Menu/SupportMenu/SupportMenuLink.d.ts +1 -1
- package/config/AdminConfig/Menu/SupportMenu/SupportMenuLink.js +1 -1
- package/config/AdminConfig/Menu/SupportMenu/SupportMenuLink.js.map +1 -1
- package/config/AdminConfig/Menu/SupportMenu.d.ts +15 -15
- package/config/AdminConfig/Menu/SupportMenu.js +3 -3
- package/config/AdminConfig/Menu/SupportMenu.js.map +1 -1
- package/config/AdminConfig/Menu/UserMenu/UserMenuItem.d.ts +14 -15
- package/config/AdminConfig/Menu/UserMenu/UserMenuItem.js +1 -1
- package/config/AdminConfig/Menu/UserMenu/UserMenuItem.js.map +1 -1
- package/config/AdminConfig/Menu/UserMenu/UserMenuLink.d.ts +14 -15
- package/config/AdminConfig/Menu/UserMenu/UserMenuLink.js +1 -1
- package/config/AdminConfig/Menu/UserMenu/UserMenuLink.js.map +1 -1
- package/config/AdminConfig/Menu/UserMenu/UserMenuSeparator.d.ts +1 -1
- package/config/AdminConfig/Menu/UserMenu/UserMenuSeparator.js +1 -1
- package/config/AdminConfig/Menu/UserMenu/UserMenuSeparator.js.map +1 -1
- package/config/AdminConfig/Menu/UserMenu.d.ts +31 -31
- package/config/AdminConfig/Menu/UserMenu.js +4 -4
- package/config/AdminConfig/Menu/UserMenu.js.map +1 -1
- package/config/AdminConfig/Menu.d.ts +105 -103
- package/config/AdminConfig/Menu.js +17 -7
- package/config/AdminConfig/Menu.js.map +1 -1
- package/config/AdminConfig/Route.d.ts +1 -1
- package/config/AdminConfig/Route.js +2 -2
- package/config/AdminConfig/Route.js.map +1 -1
- package/config/AdminConfig/Security.d.ts +3 -0
- package/config/AdminConfig/Security.js +6 -0
- package/config/AdminConfig/Security.js.map +1 -0
- package/config/AdminConfig/SecurityPermissions.d.ts +17 -0
- package/config/AdminConfig/SecurityPermissions.js +31 -0
- package/config/AdminConfig/SecurityPermissions.js.map +1 -0
- package/config/AdminConfig/Tenant/TenantLogo.d.ts +8 -7
- package/config/AdminConfig/Tenant/TenantLogo.js +14 -6
- package/config/AdminConfig/Tenant/TenantLogo.js.map +1 -1
- package/config/AdminConfig/Tenant/TenantName.d.ts +1 -1
- package/config/AdminConfig/Tenant/TenantName.js +5 -2
- package/config/AdminConfig/Tenant/TenantName.js.map +1 -1
- package/config/AdminConfig/Tenant.d.ts +14 -31
- package/config/AdminConfig/Tenant.js +4 -13
- package/config/AdminConfig/Tenant.js.map +1 -1
- package/config/AdminConfig/Theme/assignColor.d.ts +1 -1
- package/config/AdminConfig/Theme/assignColor.js +1 -1
- package/config/AdminConfig/Theme/assignColor.js.map +1 -1
- package/config/AdminConfig/Theme/types.d.ts +1 -1
- package/config/AdminConfig/Theme/types.js.map +1 -1
- package/config/AdminConfig/Theme.d.ts +1 -1
- package/config/AdminConfig/Theme.js +1 -1
- package/config/AdminConfig/Theme.js.map +1 -1
- package/config/AdminConfig/Title.d.ts +23 -0
- package/config/AdminConfig/Title.js +16 -0
- package/config/AdminConfig/Title.js.map +1 -0
- package/config/AdminConfig/Widget.d.ts +15 -0
- package/config/AdminConfig/Widget.js +36 -0
- package/config/AdminConfig/Widget.js.map +1 -0
- package/config/AdminConfig.d.ts +202 -150
- package/config/AdminConfig.js +35 -9
- package/config/AdminConfig.js.map +1 -1
- package/config/createAdminConfig.js.map +1 -1
- package/css/tokens.css +379 -0
- package/css/typography.css +70 -0
- package/domain/Identity.d.ts +59 -0
- package/domain/Identity.js +96 -0
- package/domain/Identity.js.map +1 -0
- package/errors/ErrorOverlayNetworkErrorHandler.d.ts +11 -0
- package/errors/ErrorOverlayNetworkErrorHandler.js +66 -0
- package/errors/ErrorOverlayNetworkErrorHandler.js.map +1 -0
- package/errors/TenantIsDisabled.d.ts +2 -0
- package/errors/TenantIsDisabled.js +23 -0
- package/errors/TenantIsDisabled.js.map +1 -0
- package/exports/admin/build-params.d.ts +1 -0
- package/exports/admin/build-params.js +3 -0
- package/exports/admin/build-params.js.map +1 -0
- package/exports/admin/configs.d.ts +1 -0
- package/exports/admin/configs.js +3 -0
- package/exports/admin/configs.js.map +1 -0
- package/exports/admin/form.d.ts +11 -0
- package/exports/admin/form.js +12 -0
- package/exports/admin/form.js.map +1 -0
- package/exports/admin/security.d.ts +8 -0
- package/exports/admin/security.js +10 -0
- package/exports/admin/security.js.map +1 -0
- package/exports/admin/tenancy.d.ts +2 -0
- package/exports/admin/tenancy.js +4 -0
- package/exports/admin/tenancy.js.map +1 -0
- package/exports/admin/ui.d.ts +4 -0
- package/exports/admin/ui.js +6 -0
- package/exports/admin/ui.js.map +1 -0
- package/exports/admin.d.ts +7 -0
- package/exports/admin.js +9 -0
- package/exports/admin.js.map +1 -0
- package/features/apolloClient/abstraction.d.ts +5 -0
- package/features/apolloClient/abstraction.js +4 -0
- package/features/apolloClient/abstraction.js.map +1 -0
- package/features/apolloClient/feature.d.ts +2 -0
- package/features/apolloClient/feature.js +39 -0
- package/features/apolloClient/feature.js.map +1 -0
- package/features/buildParams/BuildParams.d.ts +9 -0
- package/features/buildParams/BuildParams.js +18 -0
- package/features/buildParams/BuildParams.js.map +1 -0
- package/features/buildParams/abstractions.d.ts +15 -0
- package/features/buildParams/abstractions.js +5 -0
- package/features/buildParams/abstractions.js.map +1 -0
- package/features/buildParams/feature.d.ts +1 -0
- package/features/buildParams/feature.js +10 -0
- package/features/buildParams/feature.js.map +1 -0
- package/features/buildParams/index.d.ts +2 -0
- package/features/buildParams/index.js +4 -0
- package/features/buildParams/index.js.map +1 -0
- package/features/security/AuthenticationContext/AuthenticationContext.d.ts +15 -0
- package/features/security/AuthenticationContext/AuthenticationContext.js +31 -0
- package/features/security/AuthenticationContext/AuthenticationContext.js.map +1 -0
- package/features/security/AuthenticationContext/GraphQLClientDecorator.d.ts +12 -0
- package/features/security/AuthenticationContext/GraphQLClientDecorator.js +30 -0
- package/features/security/AuthenticationContext/GraphQLClientDecorator.js.map +1 -0
- package/features/security/AuthenticationContext/InternalIdTokenProvider.d.ts +10 -0
- package/features/security/AuthenticationContext/InternalIdTokenProvider.js +17 -0
- package/features/security/AuthenticationContext/InternalIdTokenProvider.js.map +1 -0
- package/features/security/AuthenticationContext/abstractions.d.ts +26 -0
- package/features/security/AuthenticationContext/abstractions.js +5 -0
- package/features/security/AuthenticationContext/abstractions.js.map +1 -0
- package/features/security/AuthenticationContext/feature.d.ts +3 -0
- package/features/security/AuthenticationContext/feature.js +20 -0
- package/features/security/AuthenticationContext/feature.js.map +1 -0
- package/features/security/AuthenticationContext/index.d.ts +1 -0
- package/features/security/AuthenticationContext/index.js +3 -0
- package/features/security/AuthenticationContext/index.js.map +1 -0
- package/features/security/AuthenticationContext/types.d.ts +11 -0
- package/features/security/AuthenticationContext/types.js.map +1 -0
- package/features/security/IdentityContext/IdentityContext.d.ts +13 -0
- package/features/security/IdentityContext/IdentityContext.js +24 -0
- package/features/security/IdentityContext/IdentityContext.js.map +1 -0
- package/features/security/IdentityContext/abstractions.d.ts +10 -0
- package/features/security/IdentityContext/abstractions.js +4 -0
- package/features/security/IdentityContext/abstractions.js.map +1 -0
- package/features/security/IdentityContext/feature.d.ts +3 -0
- package/features/security/IdentityContext/feature.js +16 -0
- package/features/security/IdentityContext/feature.js.map +1 -0
- package/features/security/IdentityContext/index.d.ts +2 -0
- package/features/security/IdentityContext/index.js +4 -0
- package/features/security/IdentityContext/index.js.map +1 -0
- package/features/security/LogIn/IdentityMapper.d.ts +9 -0
- package/features/security/LogIn/IdentityMapper.js +13 -0
- package/features/security/LogIn/IdentityMapper.js.map +1 -0
- package/features/security/LogIn/LogInGateway.d.ts +11 -0
- package/features/security/LogIn/LogInGateway.js +27 -0
- package/features/security/LogIn/LogInGateway.js.map +1 -0
- package/features/security/LogIn/LogInRepository.d.ts +14 -0
- package/features/security/LogIn/LogInRepository.js +19 -0
- package/features/security/LogIn/LogInRepository.js.map +1 -0
- package/features/security/LogIn/LogInUseCase.d.ts +15 -0
- package/features/security/LogIn/LogInUseCase.js +40 -0
- package/features/security/LogIn/LogInUseCase.js.map +1 -0
- package/features/security/LogIn/abstractions.d.ts +48 -0
- package/features/security/LogIn/abstractions.js +19 -0
- package/features/security/LogIn/abstractions.js.map +1 -0
- package/features/security/LogIn/createLoginMutation.d.ts +1 -0
- package/features/security/LogIn/createLoginMutation.js +49 -0
- package/features/security/LogIn/createLoginMutation.js.map +1 -0
- package/features/security/LogIn/feature.d.ts +3 -0
- package/features/security/LogIn/feature.js +22 -0
- package/features/security/LogIn/feature.js.map +1 -0
- package/features/security/LogIn/index.d.ts +1 -0
- package/features/security/LogIn/index.js +3 -0
- package/features/security/LogIn/index.js.map +1 -0
- package/features/security/LogOut/LogOutUseCase.d.ts +13 -0
- package/features/security/LogOut/LogOutUseCase.js +23 -0
- package/features/security/LogOut/LogOutUseCase.js.map +1 -0
- package/features/security/LogOut/abstractions.d.ts +7 -0
- package/features/security/LogOut/abstractions.js +4 -0
- package/features/security/LogOut/abstractions.js.map +1 -0
- package/features/security/LogOut/feature.d.ts +3 -0
- package/features/security/LogOut/feature.js +16 -0
- package/features/security/LogOut/feature.js.map +1 -0
- package/features/security/LogOut/index.d.ts +2 -0
- package/features/security/LogOut/index.js +4 -0
- package/features/security/LogOut/index.js.map +1 -0
- package/features/security/SecurityFeature.d.ts +1 -0
- package/features/security/SecurityFeature.js +16 -0
- package/features/security/SecurityFeature.js.map +1 -0
- package/features/telemetry/TelemetryService.d.ts +6 -0
- package/features/telemetry/TelemetryService.js +20 -0
- package/features/telemetry/TelemetryService.js.map +1 -0
- package/features/telemetry/abstractions.d.ts +7 -0
- package/features/telemetry/abstractions.js +4 -0
- package/features/telemetry/abstractions.js.map +1 -0
- package/features/telemetry/feature.d.ts +3 -0
- package/features/telemetry/feature.js +16 -0
- package/features/telemetry/feature.js.map +1 -0
- package/features/telemetry/index.d.ts +2 -0
- package/features/telemetry/index.js +4 -0
- package/features/telemetry/index.js.map +1 -0
- package/features/tenancy/GraphQLClientDecorator.d.ts +12 -0
- package/features/tenancy/GraphQLClientDecorator.js +27 -0
- package/features/tenancy/GraphQLClientDecorator.js.map +1 -0
- package/features/tenancy/TenantContext.d.ts +17 -0
- package/features/tenancy/TenantContext.js +61 -0
- package/features/tenancy/TenantContext.js.map +1 -0
- package/features/tenancy/abstractions.d.ts +14 -0
- package/features/tenancy/abstractions.js +4 -0
- package/features/tenancy/abstractions.js.map +1 -0
- package/features/tenancy/feature.d.ts +5 -0
- package/features/tenancy/feature.js +41 -0
- package/features/tenancy/feature.js.map +1 -0
- package/features/tenancy/types.d.ts +4 -0
- package/features/tenancy/types.js +3 -0
- package/features/tenancy/types.js.map +1 -0
- package/features/wcp/ReactLicense.d.ts +19 -0
- package/features/wcp/ReactLicense.js +46 -0
- package/features/wcp/ReactLicense.js.map +1 -0
- package/features/wcp/WcpGateway.d.ts +10 -0
- package/features/wcp/WcpGateway.js +73 -0
- package/features/wcp/WcpGateway.js.map +1 -0
- package/features/wcp/WcpService.d.ts +20 -0
- package/features/wcp/WcpService.js +84 -0
- package/features/wcp/WcpService.js.map +1 -0
- package/features/wcp/abstractions.d.ts +19 -0
- package/features/wcp/abstractions.js +5 -0
- package/features/wcp/abstractions.js.map +1 -0
- package/features/wcp/feature.d.ts +3 -0
- package/features/wcp/feature.js +18 -0
- package/features/wcp/feature.js.map +1 -0
- package/features/wcp/types.d.ts +21 -0
- package/features/wcp/types.js +3 -0
- package/features/wcp/types.js.map +1 -0
- package/hooks/index.d.ts +11 -10
- package/hooks/index.js +11 -10
- package/hooks/index.js.map +1 -1
- package/hooks/useConfirmationDialog.js +3 -3
- package/hooks/useConfirmationDialog.js.map +1 -1
- package/hooks/useDialog.js +1 -1
- package/hooks/useDialog.js.map +1 -1
- package/hooks/useKeyHandler.js +1 -1
- package/hooks/useKeyHandler.js.map +1 -1
- package/hooks/useModKey.js +1 -2
- package/hooks/useModKey.js.map +1 -1
- package/hooks/useShiftKey.js +1 -1
- package/hooks/useShiftKey.js.map +1 -1
- package/hooks/useStateIfMounted.d.ts +0 -1
- package/hooks/useStateIfMounted.js +1 -1
- package/hooks/useStateIfMounted.js.map +1 -1
- package/hooks/useToggler.d.ts +7 -0
- package/hooks/useToggler.js +15 -0
- package/hooks/useToggler.js.map +1 -0
- package/index.d.ts +34 -45
- package/index.js +36 -43
- package/index.js.map +1 -1
- package/lexical.css +2 -0
- package/package.json +42 -47
- package/permissions/PermissionRenderer.d.ts +6 -0
- package/permissions/PermissionRenderer.js +219 -0
- package/permissions/PermissionRenderer.js.map +1 -0
- package/permissions/PermissionValueContext.d.ts +11 -0
- package/permissions/PermissionValueContext.js +23 -0
- package/permissions/PermissionValueContext.js.map +1 -0
- package/permissions/createHasPermission.d.ts +3 -0
- package/permissions/createHasPermission.js +36 -0
- package/permissions/createHasPermission.js.map +1 -0
- package/permissions/createPermissionSchema.d.ts +2 -0
- package/permissions/createPermissionSchema.js +8 -0
- package/permissions/createPermissionSchema.js.map +1 -0
- package/permissions/index.d.ts +8 -0
- package/permissions/index.js +8 -0
- package/permissions/index.js.map +1 -0
- package/permissions/types.d.ts +242 -0
- package/permissions/types.js +3 -0
- package/permissions/types.js.map +1 -0
- package/permissions/usePermissionForm.d.ts +17 -0
- package/permissions/usePermissionForm.js +256 -0
- package/permissions/usePermissionForm.js.map +1 -0
- package/permissions/usePermissions.d.ts +3 -0
- package/permissions/usePermissions.js +180 -0
- package/permissions/usePermissions.js.map +1 -0
- package/presentation/installation/components/SystemInstaller/SystemInstaller.d.ts +8 -0
- package/presentation/installation/components/SystemInstaller/SystemInstaller.js +70 -0
- package/presentation/installation/components/SystemInstaller/SystemInstaller.js.map +1 -0
- package/presentation/installation/components/SystemInstaller/SystemInstallerProvider.d.ts +2 -0
- package/presentation/installation/components/SystemInstaller/SystemInstallerProvider.js +17 -0
- package/presentation/installation/components/SystemInstaller/SystemInstallerProvider.js.map +1 -0
- package/presentation/installation/components/SystemInstaller/index.d.ts +1 -0
- package/presentation/installation/components/SystemInstaller/index.js +3 -0
- package/presentation/installation/components/SystemInstaller/index.js.map +1 -0
- package/presentation/installation/components/SystemInstaller/steps/AdminUserStep/createPasswordValidator.d.ts +8 -0
- package/presentation/installation/components/SystemInstaller/steps/AdminUserStep/createPasswordValidator.js +32 -0
- package/presentation/installation/components/SystemInstaller/steps/AdminUserStep/createPasswordValidator.js.map +1 -0
- package/presentation/installation/components/SystemInstaller/steps/AdminUserStep/usePasswordValidator.d.ts +1 -0
- package/presentation/installation/components/SystemInstaller/steps/AdminUserStep/usePasswordValidator.js +15 -0
- package/presentation/installation/components/SystemInstaller/steps/AdminUserStep/usePasswordValidator.js.map +1 -0
- package/presentation/installation/components/SystemInstaller/steps/AdminUserStep.d.ts +7 -0
- package/presentation/installation/components/SystemInstaller/steps/AdminUserStep.js +69 -0
- package/presentation/installation/components/SystemInstaller/steps/AdminUserStep.js.map +1 -0
- package/presentation/installation/components/SystemInstaller/steps/BasicInfoStep.d.ts +7 -0
- package/presentation/installation/components/SystemInstaller/steps/BasicInfoStep.js +95 -0
- package/presentation/installation/components/SystemInstaller/steps/BasicInfoStep.js.map +1 -0
- package/presentation/installation/components/SystemInstaller/steps/Center.d.ts +4 -0
- package/presentation/installation/components/SystemInstaller/steps/Center.js +10 -0
- package/presentation/installation/components/SystemInstaller/steps/Center.js.map +1 -0
- package/presentation/installation/components/SystemInstaller/steps/Container.d.ts +8 -0
- package/presentation/installation/components/SystemInstaller/steps/Container.js +28 -0
- package/presentation/installation/components/SystemInstaller/steps/Container.js.map +1 -0
- package/presentation/installation/components/SystemInstaller/steps/FinishSetup.d.ts +11 -0
- package/presentation/installation/components/SystemInstaller/steps/FinishSetup.js +58 -0
- package/presentation/installation/components/SystemInstaller/steps/FinishSetup.js.map +1 -0
- package/presentation/installation/components/SystemInstaller/steps/IntroductionStep.d.ts +7 -0
- package/presentation/installation/components/SystemInstaller/steps/IntroductionStep.js +21 -0
- package/presentation/installation/components/SystemInstaller/steps/IntroductionStep.js.map +1 -0
- package/presentation/installation/components/SystemInstaller/steps/introduction.svg +154 -0
- package/presentation/installation/components/SystemInstaller/steps/referralSources.d.ts +1 -0
- package/presentation/installation/components/SystemInstaller/steps/referralSources.js +3 -0
- package/presentation/installation/components/SystemInstaller/steps/referralSources.js.map +1 -0
- package/presentation/installation/presenters/SystemInstaller/SystemInstallerGateway.d.ts +10 -0
- package/presentation/installation/presenters/SystemInstaller/SystemInstallerGateway.js +63 -0
- package/presentation/installation/presenters/SystemInstaller/SystemInstallerGateway.js.map +1 -0
- package/presentation/installation/presenters/SystemInstaller/SystemInstallerPresenter.d.ts +24 -0
- package/presentation/installation/presenters/SystemInstaller/SystemInstallerPresenter.js +138 -0
- package/presentation/installation/presenters/SystemInstaller/SystemInstallerPresenter.js.map +1 -0
- package/presentation/installation/presenters/SystemInstaller/SystemInstallerRepository.d.ts +11 -0
- package/presentation/installation/presenters/SystemInstaller/SystemInstallerRepository.js +30 -0
- package/presentation/installation/presenters/SystemInstaller/SystemInstallerRepository.js.map +1 -0
- package/presentation/installation/presenters/SystemInstaller/abstractions.d.ts +59 -0
- package/presentation/installation/presenters/SystemInstaller/abstractions.js +6 -0
- package/presentation/installation/presenters/SystemInstaller/abstractions.js.map +1 -0
- package/presentation/installation/presenters/SystemInstaller/feature.d.ts +3 -0
- package/presentation/installation/presenters/SystemInstaller/feature.js +20 -0
- package/presentation/installation/presenters/SystemInstaller/feature.js.map +1 -0
- package/presentation/installation/presenters/SystemInstaller/index.d.ts +3 -0
- package/presentation/installation/presenters/SystemInstaller/index.js +4 -0
- package/presentation/installation/presenters/SystemInstaller/index.js.map +1 -0
- package/presentation/security/components/HasPermission.d.ts +10 -0
- package/presentation/security/components/HasPermission.js +31 -0
- package/presentation/security/components/HasPermission.js.map +1 -0
- package/presentation/security/components/SecureRoute.d.ts +7 -0
- package/presentation/security/components/SecureRoute.js +16 -0
- package/presentation/security/components/SecureRoute.js.map +1 -0
- package/presentation/security/hooks/useAuthentication.d.ts +9 -0
- package/presentation/security/hooks/useAuthentication.js +24 -0
- package/presentation/security/hooks/useAuthentication.js.map +1 -0
- package/presentation/security/hooks/useIdentity.d.ts +6 -0
- package/presentation/security/hooks/useIdentity.js +25 -0
- package/presentation/security/hooks/useIdentity.js.map +1 -0
- package/presentation/security/hooks/useSecurity.d.ts +10 -0
- package/presentation/security/hooks/useSecurity.js +28 -0
- package/presentation/security/hooks/useSecurity.js.map +1 -0
- package/presentation/tenancy/TenancyProvider.d.ts +6 -0
- package/presentation/tenancy/TenancyProvider.js +43 -0
- package/presentation/tenancy/TenancyProvider.js.map +1 -0
- package/presentation/tenancy/createTenancyProvider.d.ts +1 -0
- package/presentation/tenancy/createTenancyProvider.js +14 -0
- package/presentation/tenancy/createTenancyProvider.js.map +1 -0
- package/presentation/tenancy/useTenantContext.d.ts +5 -0
- package/presentation/tenancy/useTenantContext.js +24 -0
- package/presentation/tenancy/useTenantContext.js.map +1 -0
- package/presentation/wcp/WcpProvider.d.ts +7 -0
- package/presentation/wcp/WcpProvider.js +26 -0
- package/presentation/wcp/WcpProvider.js.map +1 -0
- package/presentation/wcp/useWcp.d.ts +2 -0
- package/presentation/wcp/useWcp.js +18 -0
- package/presentation/wcp/useWcp.js.map +1 -0
- package/routes.d.ts +6 -0
- package/routes.js +17 -0
- package/routes.js.map +1 -0
- package/types.d.ts +3 -76
- package/types.js +1 -5
- package/types.js.map +1 -1
- package/base/Base/Routes.d.ts +0 -2
- package/base/Base/Routes.js +0 -24
- package/base/Base/Routes.js.map +0 -1
- package/base/providers/TelemetryProvider.d.ts +0 -1
- package/base/providers/TelemetryProvider.js +0 -22
- package/base/providers/TelemetryProvider.js.map +0 -1
- package/base/providers/ViewCompositionProvider.d.ts +0 -21
- package/base/providers/ViewCompositionProvider.js +0 -47
- package/base/providers/ViewCompositionProvider.js.map +0 -1
- package/base/ui/LocaleSelector.d.ts +0 -39
- package/base/ui/LocaleSelector.js +0 -8
- package/base/ui/LocaleSelector.js.map +0 -1
- package/components/AppInstaller/AppInstaller.d.ts +0 -11
- package/components/AppInstaller/AppInstaller.js +0 -113
- package/components/AppInstaller/AppInstaller.js.map +0 -1
- package/components/AppInstaller/Sidebar.d.ts +0 -9
- package/components/AppInstaller/Sidebar.js +0 -108
- package/components/AppInstaller/Sidebar.js.map +0 -1
- package/components/AppInstaller/assets/sign-in-divider.svg +0 -19
- package/components/AppInstaller/index.d.ts +0 -2
- package/components/AppInstaller/index.js +0 -17
- package/components/AppInstaller/index.js.map +0 -1
- package/components/AppInstaller/styled.d.ts +0 -19
- package/components/AppInstaller/styled.js +0 -75
- package/components/AppInstaller/styled.js.map +0 -1
- package/components/AppInstaller/useInstaller.d.ts +0 -25
- package/components/AppInstaller/useInstaller.js +0 -169
- package/components/AppInstaller/useInstaller.js.map +0 -1
- package/components/Dialogs/CustomDialog.d.ts +0 -17
- package/components/Dialogs/CustomDialog.js +0 -48
- package/components/Dialogs/CustomDialog.js.map +0 -1
- package/components/RichTextEditor/RichTextEditor.d.ts +0 -3
- package/components/RichTextEditor/RichTextEditor.js +0 -16
- package/components/RichTextEditor/RichTextEditor.js.map +0 -1
- package/components/RichTextEditor/index.d.ts +0 -2
- package/components/RichTextEditor/index.js +0 -4
- package/components/RichTextEditor/index.js.map +0 -1
- package/components/RichTextEditor/styles.scss +0 -96
- package/components/RichTextEditor/tools/header/index.d.ts +0 -228
- package/components/RichTextEditor/tools/header/index.js +0 -615
- package/components/RichTextEditor/tools/header/index.js.map +0 -1
- package/components/RichTextEditor/tools/header/styles.scss +0 -48
- package/components/RichTextEditor/tools/image/index.d.ts +0 -122
- package/components/RichTextEditor/tools/image/index.js +0 -202
- package/components/RichTextEditor/tools/image/index.js.map +0 -1
- package/components/RichTextEditor/tools/image/styles.scss +0 -90
- package/components/RichTextEditor/tools/image/svgs.d.ts +0 -6
- package/components/RichTextEditor/tools/image/svgs.js +0 -7
- package/components/RichTextEditor/tools/image/svgs.js.map +0 -1
- package/components/RichTextEditor/tools/image/tunes.d.ts +0 -55
- package/components/RichTextEditor/tools/image/tunes.js +0 -103
- package/components/RichTextEditor/tools/image/tunes.js.map +0 -1
- package/components/RichTextEditor/tools/image/types.d.ts +0 -29
- package/components/RichTextEditor/tools/image/types.js.map +0 -1
- package/components/RichTextEditor/tools/image/ui.d.ts +0 -120
- package/components/RichTextEditor/tools/image/ui.js +0 -245
- package/components/RichTextEditor/tools/image/ui.js.map +0 -1
- package/components/RichTextEditor/tools/paragraph/index.d.ts +0 -208
- package/components/RichTextEditor/tools/paragraph/index.js +0 -435
- package/components/RichTextEditor/tools/paragraph/index.js.map +0 -1
- package/components/RichTextEditor/tools/paragraph/styles.scss +0 -29
- package/components/RichTextEditor/tools/textColor/index.d.ts +0 -61
- package/components/RichTextEditor/tools/textColor/index.js +0 -197
- package/components/RichTextEditor/tools/textColor/index.js.map +0 -1
- package/components/RichTextEditor/tools/textColor/styles.scss +0 -21
- package/components/RichTextEditor/tools/utils.d.ts +0 -19
- package/components/RichTextEditor/tools/utils.js +0 -24
- package/components/RichTextEditor/tools/utils.js.map +0 -1
- package/components/Routes.d.ts +0 -6
- package/components/Routes.js +0 -34
- package/components/Routes.js.map +0 -1
- package/plugins/PermissionRendererPlugin.d.ts +0 -22
- package/plugins/PermissionRendererPlugin.js +0 -19
- package/plugins/PermissionRendererPlugin.js.map +0 -1
- package/plugins/uiLayoutRenderer/index.d.ts +0 -2
- package/plugins/uiLayoutRenderer/index.js +0 -53
- package/plugins/uiLayoutRenderer/index.js.map +0 -1
- package/ui/UIElement.d.ts +0 -2
- package/ui/UIElement.js +0 -3
- package/ui/UIElement.js.map +0 -1
- package/ui/UILayout.d.ts +0 -1
- package/ui/UILayout.js +0 -3
- package/ui/UILayout.js.map +0 -1
- package/ui/UIRenderer.d.ts +0 -2
- package/ui/UIRenderer.js +0 -3
- package/ui/UIRenderer.js.map +0 -1
- package/ui/UIView.d.ts +0 -2
- package/ui/UIView.js +0 -3
- package/ui/UIView.js.map +0 -1
- package/ui/elements/AccordionElement.d.ts +0 -28
- package/ui/elements/AccordionElement.js +0 -48
- package/ui/elements/AccordionElement.js.map +0 -1
- package/ui/elements/ButtonElement.d.ts +0 -25
- package/ui/elements/ButtonElement.js +0 -52
- package/ui/elements/ButtonElement.js.map +0 -1
- package/ui/elements/ButtonGroupElement.d.ts +0 -7
- package/ui/elements/ButtonGroupElement.js +0 -29
- package/ui/elements/ButtonGroupElement.js.map +0 -1
- package/ui/elements/GenericElement.d.ts +0 -1
- package/ui/elements/GenericElement.js +0 -3
- package/ui/elements/GenericElement.js.map +0 -1
- package/ui/elements/LabelElement.d.ts +0 -17
- package/ui/elements/LabelElement.js +0 -23
- package/ui/elements/LabelElement.js.map +0 -1
- package/ui/elements/NavigationMenuElement.d.ts +0 -34
- package/ui/elements/NavigationMenuElement.js +0 -88
- package/ui/elements/NavigationMenuElement.js.map +0 -1
- package/ui/elements/PanelElement.d.ts +0 -3
- package/ui/elements/PanelElement.js +0 -4
- package/ui/elements/PanelElement.js.map +0 -1
- package/ui/elements/PlaceholderElement.d.ts +0 -6
- package/ui/elements/PlaceholderElement.js +0 -11
- package/ui/elements/PlaceholderElement.js.map +0 -1
- package/ui/elements/SmallButtonElement.d.ts +0 -8
- package/ui/elements/SmallButtonElement.js +0 -24
- package/ui/elements/SmallButtonElement.js.map +0 -1
- package/ui/elements/TypographyElement.d.ts +0 -14
- package/ui/elements/TypographyElement.js +0 -23
- package/ui/elements/TypographyElement.js.map +0 -1
- package/ui/elements/ViewElement.d.ts +0 -1
- package/ui/elements/ViewElement.js +0 -3
- package/ui/elements/ViewElement.js.map +0 -1
- package/ui/elements/form/DynamicFieldsetElement/DynamicFieldsetRowElement.d.ts +0 -7
- package/ui/elements/form/DynamicFieldsetElement/DynamicFieldsetRowElement.js +0 -26
- package/ui/elements/form/DynamicFieldsetElement/DynamicFieldsetRowElement.js.map +0 -1
- package/ui/elements/form/DynamicFieldsetElement.d.ts +0 -44
- package/ui/elements/form/DynamicFieldsetElement.js +0 -97
- package/ui/elements/form/DynamicFieldsetElement.js.map +0 -1
- package/ui/elements/form/FileManagerElement/EmptyStateElement.d.ts +0 -4
- package/ui/elements/form/FileManagerElement/EmptyStateElement.js +0 -10
- package/ui/elements/form/FileManagerElement/EmptyStateElement.js.map +0 -1
- package/ui/elements/form/FileManagerElement/EmptyStateElementRenderer.d.ts +0 -8
- package/ui/elements/form/FileManagerElement/EmptyStateElementRenderer.js +0 -47
- package/ui/elements/form/FileManagerElement/EmptyStateElementRenderer.js.map +0 -1
- package/ui/elements/form/FileManagerElement/FileManagerElementRenderer.d.ts +0 -14
- package/ui/elements/form/FileManagerElement/FileManagerElementRenderer.js +0 -73
- package/ui/elements/form/FileManagerElement/FileManagerElementRenderer.js.map +0 -1
- package/ui/elements/form/FileManagerElement/styled.d.ts +0 -23
- package/ui/elements/form/FileManagerElement/styled.js +0 -108
- package/ui/elements/form/FileManagerElement/styled.js.map +0 -1
- package/ui/elements/form/FileManagerElement.d.ts +0 -25
- package/ui/elements/form/FileManagerElement.js +0 -46
- package/ui/elements/form/FileManagerElement.js.map +0 -1
- package/ui/elements/form/FormElement.d.ts +0 -22
- package/ui/elements/form/FormElement.js +0 -20
- package/ui/elements/form/FormElement.js.map +0 -1
- package/ui/elements/form/FormFieldElement.d.ts +0 -57
- package/ui/elements/form/FormFieldElement.js +0 -113
- package/ui/elements/form/FormFieldElement.js.map +0 -1
- package/ui/elements/form/HiddenElement.d.ts +0 -7
- package/ui/elements/form/HiddenElement.js +0 -25
- package/ui/elements/form/HiddenElement.js.map +0 -1
- package/ui/elements/form/InputElement.d.ts +0 -8
- package/ui/elements/form/InputElement.js +0 -32
- package/ui/elements/form/InputElement.js.map +0 -1
- package/ui/elements/form/PasswordElement.d.ts +0 -6
- package/ui/elements/form/PasswordElement.js +0 -29
- package/ui/elements/form/PasswordElement.js.map +0 -1
- package/ui/elements/form/README.md +0 -2
- package/ui/elements/form/SelectElement.d.ts +0 -16
- package/ui/elements/form/SelectElement.js +0 -42
- package/ui/elements/form/SelectElement.js.map +0 -1
- package/ui/elements/form/TextareaElement.d.ts +0 -16
- package/ui/elements/form/TextareaElement.js +0 -34
- package/ui/elements/form/TextareaElement.js.map +0 -1
- package/ui/views/AdminView/ContentElement.d.ts +0 -4
- package/ui/views/AdminView/ContentElement.js +0 -37
- package/ui/views/AdminView/ContentElement.js.map +0 -1
- package/ui/views/AdminView/HeaderElement.d.ts +0 -13
- package/ui/views/AdminView/HeaderElement.js +0 -68
- package/ui/views/AdminView/HeaderElement.js.map +0 -1
- package/ui/views/AdminView/HeaderSectionCenterElement.d.ts +0 -7
- package/ui/views/AdminView/HeaderSectionCenterElement.js +0 -21
- package/ui/views/AdminView/HeaderSectionCenterElement.js.map +0 -1
- package/ui/views/AdminView/HeaderSectionLeftElement.d.ts +0 -7
- package/ui/views/AdminView/HeaderSectionLeftElement.js +0 -21
- package/ui/views/AdminView/HeaderSectionLeftElement.js.map +0 -1
- package/ui/views/AdminView/HeaderSectionRightElement.d.ts +0 -7
- package/ui/views/AdminView/HeaderSectionRightElement.js +0 -21
- package/ui/views/AdminView/HeaderSectionRightElement.js.map +0 -1
- package/ui/views/AdminView/components/Dialog.d.ts +0 -2
- package/ui/views/AdminView/components/Dialog.js +0 -41
- package/ui/views/AdminView/components/Dialog.js.map +0 -1
- package/ui/views/AdminView/components/Hamburger.d.ts +0 -3
- package/ui/views/AdminView/components/Hamburger.js +0 -23
- package/ui/views/AdminView/components/Hamburger.js.map +0 -1
- package/ui/views/FormView/FormContainerElement.d.ts +0 -13
- package/ui/views/FormView/FormContainerElement.js +0 -19
- package/ui/views/FormView/FormContainerElement.js.map +0 -1
- package/ui/views/FormView/FormContentElement.d.ts +0 -6
- package/ui/views/FormView/FormContentElement.js +0 -10
- package/ui/views/FormView/FormContentElement.js.map +0 -1
- package/ui/views/FormView/FormFooterElement.d.ts +0 -7
- package/ui/views/FormView/FormFooterElement.js +0 -14
- package/ui/views/FormView/FormFooterElement.js.map +0 -1
- package/ui/views/FormView/FormHeaderElement.d.ts +0 -15
- package/ui/views/FormView/FormHeaderElement.js +0 -30
- package/ui/views/FormView/FormHeaderElement.js.map +0 -1
- package/ui/views/FormView.d.ts +0 -40
- package/ui/views/FormView.js +0 -121
- package/ui/views/FormView.js.map +0 -1
- package/ui/views/OverlayView/ContentElement.d.ts +0 -7
- package/ui/views/OverlayView/ContentElement.js +0 -29
- package/ui/views/OverlayView/ContentElement.js.map +0 -1
- package/ui/views/OverlayView/HeaderElement.d.ts +0 -25
- package/ui/views/OverlayView/HeaderElement.js +0 -72
- package/ui/views/OverlayView/HeaderElement.js.map +0 -1
- package/ui/views/OverlayView/HeaderTitleElement.d.ts +0 -15
- package/ui/views/OverlayView/HeaderTitleElement.js +0 -25
- package/ui/views/OverlayView/HeaderTitleElement.js.map +0 -1
- package/ui/views/OverlayView/useOverlayView.d.ts +0 -5
- package/ui/views/OverlayView/useOverlayView.js +0 -34
- package/ui/views/OverlayView/useOverlayView.js.map +0 -1
- package/ui/views/OverlayView.d.ts +0 -30
- package/ui/views/OverlayView.js +0 -109
- package/ui/views/OverlayView.js.map +0 -1
- package/ui/views/SplitView/SplitViewPanelElement.d.ts +0 -12
- package/ui/views/SplitView/SplitViewPanelElement.js +0 -32
- package/ui/views/SplitView/SplitViewPanelElement.js.map +0 -1
- package/ui/views/SplitView.d.ts +0 -21
- package/ui/views/SplitView.js +0 -86
- package/ui/views/SplitView.js.map +0 -1
- /package/base/Base/Tenant/{wby-logo.svg → wby-square.svg} +0 -0
- /package/{components/RichTextEditor/tools/image → features/security/AuthenticationContext}/types.js +0 -0
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"names":["React","useApolloClient","observer","Button","FileManager","IconPickerTab","useIcon","useIconPicker","IconPickerConfig","LIST_CUSTOM_ICONS","CustomIcon","icon","size","createElement","width","height","src","value","alt","name","style","verticalAlign","IconFilePicker","onUpload","onChange","onUploadCompletion","file","scope","accept","showFileManager","variant","text","onClick","
|
|
1
|
+
{"version":3,"names":["React","useApolloClient","observer","Button","FileManager","IconPickerTab","useIcon","useIconPicker","IconPickerConfig","LIST_CUSTOM_ICONS","CustomIcon","icon","size","createElement","width","height","src","value","alt","name","style","verticalAlign","IconFilePicker","onUpload","onChange","onUploadCompletion","file","scope","accept","render","showFileManager","variant","text","onClick","CustomIconTab","presenter","onIconSelect","setIcon","closeMenu","onIconFileSelect","type","onIconFileUpload","addIcon","label","actions","CustomIconPlugin","client","IconPack","provider","data","response","query","variables","limit","Error","error","fileManager","listFiles","message","map","customIcon","IconType","Icon","element","Tab"],"sources":["customPlugin.tsx"],"sourcesContent":["import React from \"react\";\nimport { useApolloClient } from \"@apollo/react-hooks\";\nimport { observer } from \"mobx-react-lite\";\nimport { Button } from \"@webiny/admin-ui\";\nimport type { FileManagerFileItem } from \"~/base/ui/FileManager.js\";\nimport { FileManager } from \"~/base/ui/FileManager.js\";\nimport { IconPickerTab } from \"../IconPickerTab.js\";\nimport { useIcon } from \"../index.js\";\nimport { useIconPicker } from \"../IconPickerPresenterProvider.js\";\nimport { IconPickerConfig } from \"../config/index.js\";\nimport type { ListCustomIconsQueryResponse } from \"./graphql.js\";\nimport { LIST_CUSTOM_ICONS } from \"./graphql.js\";\nimport type { Icon } from \"../types.js\";\n\n/**\n * NOTE: Avoid using `@emotion/styled` in icon renderer components across all plugins.\n * This is crucial for serializing component rendering into a string value as plain HTML,\n * which is necessary for usage in the website application. Please use inline styles here\n * to ensure proper serialization.\n */\n\nconst CustomIcon = () => {\n const { icon, size } = useIcon<Icon>();\n\n return (\n <img\n width={size}\n height={size}\n src={icon.value}\n alt={icon.name}\n style={{\n verticalAlign: \"middle\"\n }}\n />\n );\n};\n\ninterface IconFilePickerProps {\n onUpload: (file: FileManagerFileItem) => void;\n onChange: (file: FileManagerFileItem) => void;\n}\n\nconst IconFilePicker = ({ onUpload, onChange }: IconFilePickerProps) => {\n return (\n <FileManager\n onUploadCompletion={([file]) => {\n onUpload(file);\n }}\n onChange={onChange}\n scope=\"scope:iconPicker\"\n accept={[\"image/svg+xml\"]}\n render={({ showFileManager }) => (\n <Button\n variant={\"primary\"}\n text={\"Browse\"}\n onClick={() => {\n showFileManager();\n }}\n />\n )}\n ></FileManager>\n );\n};\n\nconst CustomIconTab = observer(() => {\n const presenter = useIconPicker();\n\n const onIconSelect = (icon: Icon) => {\n presenter.setIcon(icon);\n presenter.closeMenu();\n };\n\n const onIconFileSelect = (file: FileManagerFileItem) => {\n presenter.setIcon({\n type: \"custom\",\n name: file.name,\n value: file.src\n });\n presenter.closeMenu();\n };\n\n const onIconFileUpload = (file: FileManagerFileItem) => {\n const icon = {\n type: \"custom\",\n name: file.name,\n value: file.src\n };\n\n presenter.addIcon(icon);\n presenter.setIcon(icon);\n presenter.closeMenu();\n };\n\n return (\n <IconPickerTab\n value={\"custom\"}\n label={\"Custom\"}\n onChange={onIconSelect}\n actions={<IconFilePicker onChange={onIconFileSelect} onUpload={onIconFileUpload} />}\n />\n );\n});\n\nexport const CustomIconPlugin = () => {\n const client = useApolloClient();\n\n return (\n <IconPickerConfig>\n <IconPickerConfig.IconPack\n name=\"custom\"\n provider={async () => {\n const { data: response } = await client.query<ListCustomIconsQueryResponse>({\n query: LIST_CUSTOM_ICONS,\n variables: {\n limit: 10000\n }\n });\n\n if (!response) {\n throw new Error(\"Network error while listing custom icons.\");\n }\n\n const { data, error } = response.fileManager.listFiles;\n\n if (!data) {\n throw new Error(error?.message || \"Could not fetch custom icons.\");\n }\n\n return data.map(customIcon => ({\n type: \"custom\",\n name: customIcon.name,\n value: customIcon.src\n }));\n }}\n />\n <IconPickerConfig.IconType name={\"custom\"}>\n <IconPickerConfig.IconType.Icon element={<CustomIcon />} />\n <IconPickerConfig.IconType.Tab element={<CustomIconTab />} />\n </IconPickerConfig.IconType>\n </IconPickerConfig>\n );\n};\n"],"mappings":"AAAA,OAAOA,KAAK,MAAM,OAAO;AACzB,SAASC,eAAe,QAAQ,qBAAqB;AACrD,SAASC,QAAQ,QAAQ,iBAAiB;AAC1C,SAASC,MAAM,QAAQ,kBAAkB;AAEzC,SAASC,WAAW;AACpB,SAASC,aAAa;AACtB,SAASC,OAAO;AAChB,SAASC,aAAa;AACtB,SAASC,gBAAgB;AAEzB,SAASC,iBAAiB;AAG1B;AACA;AACA;AACA;AACA;AACA;;AAEA,MAAMC,UAAU,GAAGA,CAAA,KAAM;EACrB,MAAM;IAAEC,IAAI;IAAEC;EAAK,CAAC,GAAGN,OAAO,CAAO,CAAC;EAEtC,oBACIN,KAAA,CAAAa,aAAA;IACIC,KAAK,EAAEF,IAAK;IACZG,MAAM,EAAEH,IAAK;IACbI,GAAG,EAAEL,IAAI,CAACM,KAAM;IAChBC,GAAG,EAAEP,IAAI,CAACQ,IAAK;IACfC,KAAK,EAAE;MACHC,aAAa,EAAE;IACnB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IAAI;QACrBF,KAAK,EAAE2C,UAAU,CAAC5C;MACtB,CAAC,CAAC,CAAC;IACP;EAAE,CACL,CAAC,eACFhB,KAAA,CAAAa,aAAA,CAACL,gBAAgB,CAACqD,QAAQ;IAAC1C,IAAI,EAAE;EAAS,gBACtCnB,KAAA,CAAAa,aAAA,CAACL,gBAAgB,CAACqD,QAAQ,CAACC,IAAI;IAACC,OAAO,eAAE/D,KAAA,CAAAa,aAAA,CAACH,UAAU,MAAE;EAAE,CAAE,CAAC,eAC3DV,KAAA,CAAAa,aAAA,CAACL,gBAAgB,CAACqD,QAAQ,CAACG,GAAG;IAACD,OAAO,eAAE/D,KAAA,CAAAa,aAAA,CAACqB,aAAa,MAAE;EAAE,CAAE,CACrC,CACb,CAAC;AAE3B,CAAC","ignoreList":[]}
|
|
@@ -1,15 +1,15 @@
|
|
|
1
1
|
import React, { useState } from "react";
|
|
2
2
|
import { observer } from "mobx-react-lite";
|
|
3
3
|
import { cn, PopoverPrimitive } from "@webiny/admin-ui";
|
|
4
|
-
import { useIcon } from "
|
|
5
|
-
import { IconPickerTab } from "../IconPickerTab";
|
|
6
|
-
import { IconProvider } from "../IconRenderer";
|
|
7
|
-
import { useIconPicker } from "../IconPickerPresenterProvider";
|
|
8
|
-
import { IconPickerConfig } from "../config";
|
|
4
|
+
import { useIcon } from "../index.js";
|
|
5
|
+
import { IconPickerTab } from "../IconPickerTab.js";
|
|
6
|
+
import { IconProvider } from "../IconRenderer.js";
|
|
7
|
+
import { useIconPicker } from "../IconPickerPresenterProvider.js";
|
|
8
|
+
import { IconPickerConfig } from "../config/index.js";
|
|
9
9
|
const SKIN_TONES = ["", "\u{1f3fb}", "\u{1f3fc}", "\u{1f3fd}", "\u{1f3fe}", "\u{1f3ff}"];
|
|
10
10
|
const SkinToneSelectWrapper = props => {
|
|
11
11
|
return /*#__PURE__*/React.createElement("div", {
|
|
12
|
-
className: cn("
|
|
12
|
+
className: cn("size-xl rounded-sm pointer border-solid border-sm border-neutral-muted flex justify-center items-center text-center")
|
|
13
13
|
}, props.children);
|
|
14
14
|
};
|
|
15
15
|
|
|
@@ -55,18 +55,18 @@ const SkinToneSelect = ({
|
|
|
55
55
|
open: open,
|
|
56
56
|
onOpenChange: open => setOpen(open)
|
|
57
57
|
}, /*#__PURE__*/React.createElement(PopoverPrimitive.Trigger, {
|
|
58
|
-
className: "
|
|
58
|
+
className: "outline-none"
|
|
59
59
|
}, /*#__PURE__*/React.createElement(SkinToneSelectWrapper, null, /*#__PURE__*/React.createElement(IconProvider, {
|
|
60
60
|
icon: icon,
|
|
61
61
|
size: 24
|
|
62
62
|
}, /*#__PURE__*/React.createElement(Emoji, null)))), /*#__PURE__*/React.createElement(PopoverPrimitive.Content, null, /*#__PURE__*/React.createElement("div", {
|
|
63
|
-
className: "
|
|
63
|
+
className: "bg-neutral-base grid gap-xs p-xs text-center"
|
|
64
64
|
}, SKIN_TONES.map((skinTone, index) => /*#__PURE__*/React.createElement("div", {
|
|
65
65
|
key: index,
|
|
66
66
|
onClick: () => {
|
|
67
67
|
onChange(skinTone);
|
|
68
68
|
},
|
|
69
|
-
className: "
|
|
69
|
+
className: "cursor-pointer"
|
|
70
70
|
}, /*#__PURE__*/React.createElement(IconProvider, {
|
|
71
71
|
icon: {
|
|
72
72
|
...icon,
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"names":["React","useState","observer","cn","PopoverPrimitive","useIcon","IconPickerTab","IconProvider","useIconPicker","IconPickerConfig","SKIN_TONES","SkinToneSelectWrapper","props","createElement","className","children","Emoji","icon","size","style","display","width","height","fontSize","lineHeight","color","skinTone","value","SkinToneSelect","hasSkinToneSupport","onChange","open","setOpen","isEmoji","onOpenChange","Trigger","Content","map","index","key","onClick","type","EmojiTab","presenter","selectedIcon","vm","onSkinToneChange","setIcon","onIconSelect","closeMenu","skinToneSupport","label","actions","EmojiPlugin","IconType","name","Icon","element","Tab"],"sources":["emojisPlugin.tsx"],"sourcesContent":["import React, { useState } from \"react\";\nimport { observer } from \"mobx-react-lite\";\nimport { cn, PopoverPrimitive } from \"@webiny/admin-ui\";\nimport { useIcon } from \"
|
|
1
|
+
{"version":3,"names":["React","useState","observer","cn","PopoverPrimitive","useIcon","IconPickerTab","IconProvider","useIconPicker","IconPickerConfig","SKIN_TONES","SkinToneSelectWrapper","props","createElement","className","children","Emoji","icon","size","style","display","width","height","fontSize","lineHeight","color","skinTone","value","SkinToneSelect","hasSkinToneSupport","onChange","open","setOpen","isEmoji","onOpenChange","Trigger","Content","map","index","key","onClick","type","EmojiTab","presenter","selectedIcon","vm","onSkinToneChange","setIcon","onIconSelect","closeMenu","skinToneSupport","label","actions","EmojiPlugin","IconType","name","Icon","element","Tab"],"sources":["emojisPlugin.tsx"],"sourcesContent":["import React, { useState } from \"react\";\nimport { observer } from \"mobx-react-lite\";\nimport { cn, PopoverPrimitive } from \"@webiny/admin-ui\";\nimport { useIcon } from \"../index.js\";\nimport { IconPickerTab } from \"../IconPickerTab.js\";\nimport { IconProvider } from \"../IconRenderer.js\";\nimport { useIconPicker } from \"../IconPickerPresenterProvider.js\";\nimport { IconPickerConfig } from \"../config/index.js\";\nimport type { Icon } from \"../types.js\";\n\nconst SKIN_TONES = [\"\", \"\\u{1f3fb}\", \"\\u{1f3fc}\", \"\\u{1f3fd}\", \"\\u{1f3fe}\", \"\\u{1f3ff}\"];\n\nconst SkinToneSelectWrapper = (props: React.HTMLAttributes<HTMLDivElement>) => {\n return (\n <div\n className={cn(\n \"size-xl rounded-sm pointer border-solid border-sm border-neutral-muted flex justify-center items-center text-center\"\n )}\n >\n {props.children}\n </div>\n );\n};\n\n/**\n * NOTE: Avoid using `@emotion/styled` in icon renderer components across all plugins.\n * This is crucial for serializing component rendering into a string value as plain HTML,\n * which is necessary for usage in the website application. Please use inline styles here\n * to ensure proper serialization.\n */\n\ninterface Emoji extends Icon {\n skinTone: string;\n skinToneSupport: boolean;\n}\n\nconst Emoji = () => {\n const { icon, size } = useIcon<Emoji>();\n\n return (\n <div\n style={{\n display: \"inline-block\",\n width: `${size}px`,\n height: `${size}px`,\n fontSize: `${(size * 4) / 5}px`,\n lineHeight: `${size}px`,\n color: \"black\"\n }}\n >\n {icon.skinTone ? icon.value + icon.skinTone : icon.value}\n </div>\n );\n};\n\ninterface SkinToneSelectProps {\n icon: Icon | null;\n hasSkinToneSupport: boolean;\n onChange: (skinTone: string) => void;\n}\n\nconst SkinToneSelect = ({ icon, hasSkinToneSupport, onChange }: SkinToneSelectProps) => {\n const [open, setOpen] = useState(false);\n\n if (!icon || !isEmoji(icon)) {\n return <SkinToneSelectWrapper />;\n }\n\n if (!hasSkinToneSupport) {\n return (\n <SkinToneSelectWrapper>\n <IconProvider icon={icon} size={24}>\n <Emoji />\n </IconProvider>\n </SkinToneSelectWrapper>\n );\n }\n\n return (\n <PopoverPrimitive open={open} onOpenChange={open => setOpen(open)}>\n <PopoverPrimitive.Trigger className={\"outline-none\"}>\n <SkinToneSelectWrapper>\n <IconProvider icon={icon} size={24}>\n <Emoji />\n </IconProvider>\n </SkinToneSelectWrapper>\n </PopoverPrimitive.Trigger>\n <PopoverPrimitive.Content>\n <div className={\"bg-neutral-base grid gap-xs p-xs text-center\"}>\n {SKIN_TONES.map((skinTone, index) => (\n <div\n key={index}\n onClick={() => {\n onChange(skinTone);\n }}\n className={\"cursor-pointer\"}\n >\n <IconProvider icon={{ ...icon, skinTone }} size={24}>\n <Emoji />\n </IconProvider>\n </div>\n ))}\n </div>\n </PopoverPrimitive.Content>\n </PopoverPrimitive>\n );\n};\n\n/**\n * @see https://www.typescriptlang.org/docs/handbook/2/narrowing.html#using-type-predicates\n */\nconst isEmoji = (icon: Icon | null): icon is Emoji => {\n if (!icon) {\n return false;\n }\n return icon.type === \"emoji\";\n};\n\nconst EmojiTab = observer(() => {\n const presenter = useIconPicker();\n const { selectedIcon } = presenter.vm;\n\n const onSkinToneChange = (skinTone: string) => {\n if (isEmoji(selectedIcon)) {\n presenter.setIcon({ ...selectedIcon, skinTone });\n }\n };\n\n const onIconSelect = (icon: Icon) => {\n presenter.setIcon(icon);\n presenter.closeMenu();\n };\n\n const hasSkinToneSupport = isEmoji(selectedIcon) ? selectedIcon.skinToneSupport : false;\n\n return (\n <IconPickerTab\n value={\"emoji\"}\n label={\"Emojis\"}\n onChange={onIconSelect}\n actions={\n <SkinToneSelect\n icon={selectedIcon}\n hasSkinToneSupport={hasSkinToneSupport}\n onChange={onSkinToneChange}\n />\n }\n />\n );\n});\n\nexport const EmojiPlugin = () => {\n return (\n <IconPickerConfig>\n <IconPickerConfig.IconType name={\"emoji\"}>\n <IconPickerConfig.IconType.Icon element={<Emoji />} />\n <IconPickerConfig.IconType.Tab element={<EmojiTab />} />\n </IconPickerConfig.IconType>\n </IconPickerConfig>\n );\n};\n"],"mappings":"AAAA,OAAOA,KAAK,IAAIC,QAAQ,QAAQ,OAAO;AACvC,SAASC,QAAQ,QAAQ,iBAAiB;AAC1C,SAASC,EAAE,EAAEC,gBAAgB,QAAQ,kBAAkB;AACvD,SAASC,OAAO;AAChB,SAASC,aAAa;AACtB,SAASC,YAAY;AACrB,SAASC,aAAa;AACtB,SAASC,gBAAgB;AAGzB,MAAMC,UAAU,GAAG,CAAC,EAAE,EAAE,WAAW,EAAE,WAAW,EAAE,WAAW,EAAE,WAAW,EAAE,WAAW,CAAC;AAExF,MAAMC,qBAAqB,GAAIC,KAA2C,IAAK;EAC3E,oBACIZ,KAAA,CAAAa,aAAA;IACIC,SAAS,EAAEX,EAAE,CACT,qHACJ;EAAE,GAEDS,KAAK,CAACG,QACN,CAAC;AAEd,CAAC;;AAED;AACA;AACA;AACA;AACA;AACA;;AAOA,MAAMC,KAAK,GAAGA,CAAA,KAAM;EAChB,MAAM;IAAEC,IAAI;IAAEC;EAAK,CAAC,GAAGb,OAAO,CAAQ,CAAC;EAEvC,oBACIL,KAAA,CAAAa,aAAA;IACIM,KAAK,EAAE;MACHC,OAAO,EAAE,cAAc;MACvBC,KAAK,EAAE,GAAGH,IAAI,IAAI;MAClBI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AGI,OAAO,CAACW,YAAY,CAAC,GAAGA,YAAY,CAACM,eAAe,GAAG,KAAK;EAEvF,oBACIlD,KAAA,CAAAa,aAAA,CAACP,aAAa;IACVqB,KAAK,EAAE,OAAQ;IACfwB,KAAK,EAAE,QAAS;IAChBrB,QAAQ,EAAEkB,YAAa;IACvBI,OAAO,eACHpD,KAAA,CAAAa,aAAA,CAACe,cAAc;MACXX,IAAI,EAAE2B,YAAa;MACnBf,kBAAkB,EAAEA,kBAAmB;MACvCC,QAAQ,EAAEgB;IAAiB,CAC9B;EACJ,CACJ,CAAC;AAEV,CAAC,CAAC;AAEF,OAAO,MAAMO,WAAW,GAAGA,CAAA,KAAM;EAC7B,oBACIrD,KAAA,CAAAa,aAAA,CAACJ,gBAAgB,qBACbT,KAAA,CAAAa,aAAA,CAACJ,gBAAgB,CAAC6C,QAAQ;IAACC,IAAI,EAAE;EAAQ,gBACrCvD,KAAA,CAAAa,aAAA,CAACJ,gBAAgB,CAAC6C,QAAQ,CAACE,IAAI;IAACC,OAAO,eAAEzD,KAAA,CAAAa,aAAA,CAACG,KAAK,MAAE;EAAE,CAAE,CAAC,eACtDhB,KAAA,CAAAa,aAAA,CAACJ,gBAAgB,CAAC6C,QAAQ,CAACI,GAAG;IAACD,OAAO,eAAEzD,KAAA,CAAAa,aAAA,CAAC6B,QAAQ,MAAE;EAAE,CAAE,CAChC,CACb,CAAC;AAE3B,CAAC","ignoreList":[]}
|
|
@@ -1,10 +1,10 @@
|
|
|
1
1
|
import React, { useState, useEffect } from "react";
|
|
2
2
|
import { observer } from "mobx-react-lite";
|
|
3
3
|
import { DelayedOnChange, ColorPicker } from "@webiny/admin-ui";
|
|
4
|
-
import { useIcon } from "
|
|
5
|
-
import { IconPickerTab } from "../IconPickerTab";
|
|
6
|
-
import { useIconPicker } from "../IconPickerPresenterProvider";
|
|
7
|
-
import { IconPickerConfig } from "../config";
|
|
4
|
+
import { useIcon } from "../index.js";
|
|
5
|
+
import { IconPickerTab } from "../IconPickerTab.js";
|
|
6
|
+
import { useIconPicker } from "../IconPickerPresenterProvider.js";
|
|
7
|
+
import { IconPickerConfig } from "../config/index.js";
|
|
8
8
|
|
|
9
9
|
/**
|
|
10
10
|
* NOTE: Avoid using `@emotion/styled` in icon renderer components across all plugins.
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"names":["React","useState","useEffect","observer","DelayedOnChange","ColorPicker","useIcon","IconPickerTab","useIconPicker","IconPickerConfig","IconSvg","icon","size","createElement","width","height","viewBox","color","dangerouslySetInnerHTML","__html","value","style","verticalAlign","IconColorPicker","onChange","align","isSimpleIcon","type","IconTab","presenter","selectedIcon","vm","setColor","onColorChange","setIcon","onIconSelect","closeMenu","label","cellDecorator","cell","actions","SimpleIconPlugin","IconType","name","Icon","element","Tab"],"sources":["iconsPlugin.tsx"],"sourcesContent":["import React, { useState, useEffect } from \"react\";\nimport { observer } from \"mobx-react-lite\";\nimport { DelayedOnChange, ColorPicker } from \"@webiny/admin-ui\";\n\nimport { useIcon } from \"
|
|
1
|
+
{"version":3,"names":["React","useState","useEffect","observer","DelayedOnChange","ColorPicker","useIcon","IconPickerTab","useIconPicker","IconPickerConfig","IconSvg","icon","size","createElement","width","height","viewBox","color","dangerouslySetInnerHTML","__html","value","style","verticalAlign","IconColorPicker","onChange","align","isSimpleIcon","type","IconTab","presenter","selectedIcon","vm","setColor","onColorChange","setIcon","onIconSelect","closeMenu","label","cellDecorator","cell","actions","SimpleIconPlugin","IconType","name","Icon","element","Tab"],"sources":["iconsPlugin.tsx"],"sourcesContent":["import React, { useState, useEffect } from \"react\";\nimport { observer } from \"mobx-react-lite\";\nimport { DelayedOnChange, ColorPicker } from \"@webiny/admin-ui\";\n\nimport { useIcon } from \"../index.js\";\nimport { IconPickerTab } from \"../IconPickerTab.js\";\nimport { useIconPicker } from \"../IconPickerPresenterProvider.js\";\nimport { IconPickerConfig } from \"../config/index.js\";\nimport type { Icon } from \"../types.js\";\n\n/**\n * NOTE: Avoid using `@emotion/styled` in icon renderer components across all plugins.\n * This is crucial for serializing component rendering into a string value as plain HTML,\n * which is necessary for usage in the website application. Please use inline styles here\n * to ensure proper serialization.\n */\n\ninterface SimpleIcon extends Icon {\n color: string;\n}\n\nconst IconSvg = () => {\n const { icon, size } = useIcon<SimpleIcon>();\n\n return (\n <svg\n width={size}\n height={size}\n viewBox={`0 0 ${icon.width || 512} 512`}\n color={icon?.color || \"inherit\"}\n dangerouslySetInnerHTML={{ __html: icon.value || \"\" }}\n style={{\n verticalAlign: \"middle\",\n width: \"100%\",\n height: \"100%\"\n }}\n />\n );\n};\n\ninterface IconColorPickerProps {\n color: string;\n onChange: (value: string) => void;\n}\n\nconst IconColorPicker = ({ color, onChange }: IconColorPickerProps) => {\n return (\n <DelayedOnChange value={color} onChange={onChange}>\n {({ value, onChange }) => (\n <ColorPicker align={\"end\"} value={value} onChange={onChange} />\n )}\n </DelayedOnChange>\n );\n};\n\n/**\n * @see https://www.typescriptlang.org/docs/handbook/2/narrowing.html#using-type-predicates\n */\nconst isSimpleIcon = (icon: Icon | null): icon is SimpleIcon => {\n if (!icon) {\n return false;\n }\n return icon.type === \"icon\";\n};\n\nconst IconTab = observer(() => {\n const presenter = useIconPicker();\n const { selectedIcon } = presenter.vm;\n\n const [color, setColor] = useState(\"inherit\");\n\n useEffect(() => {\n if (color === \"inherit\" && isSimpleIcon(selectedIcon)) {\n setColor(selectedIcon.color);\n }\n }, [selectedIcon]);\n\n const onColorChange = (color: string) => {\n setColor(color);\n\n if (isSimpleIcon(selectedIcon)) {\n presenter.setIcon({ ...selectedIcon, color });\n }\n };\n\n const onIconSelect = (icon: Icon) => {\n // Set icon and assign current color.\n presenter.setIcon({ ...icon, color });\n presenter.closeMenu();\n };\n\n return (\n <IconPickerTab\n value={\"icon\"}\n label={\"Icons\"}\n onChange={onIconSelect}\n cellDecorator={cell => <span style={{ color }}>{cell}</span>}\n actions={<IconColorPicker color={color} onChange={onColorChange} />}\n />\n );\n});\n\nexport const SimpleIconPlugin = () => {\n return (\n <IconPickerConfig>\n <IconPickerConfig.IconType name={\"icon\"}>\n <IconPickerConfig.IconType.Icon element={<IconSvg />} />\n <IconPickerConfig.IconType.Tab element={<IconTab />} />\n </IconPickerConfig.IconType>\n </IconPickerConfig>\n );\n};\n"],"mappings":"AAAA,OAAOA,KAAK,IAAIC,QAAQ,EAAEC,SAAS,QAAQ,OAAO;AAClD,SAASC,QAAQ,QAAQ,iBAAiB;AAC1C,SAASC,eAAe,EAAEC,WAAW,QAAQ,kBAAkB;AAE/D,SAASC,OAAO;AAChB,SAASC,aAAa;AACtB,SAASC,aAAa;AACtB,SAASC,gBAAgB;;AAGzB;AACA;AACA;AACA;AACA;AACA;;AAMA,MAAMC,OAAO,GAAGA,CAAA,KAAM;EAClB,MAAM;IAAEC,IAAI;IAAEC;EAAK,CAAC,GAAGN,OAAO,CAAa,CAAC;EAE5C,oBACIN,KAAA,CAAAa,aAAA;IACIC,KAAK,EAAEF,IAAK;IACZG,MAAM,EAAEH,IAAK;IACbI,OAAO,EAAE,OAAOL,IAAI,CAACG,KAAK,IAAI,GAAG,MAAO;IACxCG,KAAK,EAAEN,IAAI,EAAEM,KAAK,IAAI,SAAU;IAChCC,uBAAuB,EAAE;MAAEC,MAAM,EAAER,IAAI,CAACS,KAAK,IAAI;IAAG,CAAE;IACtDC,KAAK,EAAE;MACHC,aAAa,EAAE,QAAQ;MACvBR,KAAK,EAAE,MAAM;MACbC,MAAM,EAAE;IACZ;EAAE,CACL,CAAC;AAEV,CAAC;AAOD,MAAMQ,eAAe,GAAGA,CAAC;EAAEN,KAAK;EAAEO;AAA+B,CAAC,KAAK;EACnE,oBACIxB,KAAA,CAAAa,aAAA,CAACT,eAAe;IAACgB,KAAK,EAAEH,KAAM;IAACO,QAAQ,EAAEA;EAAS,GAC7C,CAAC;IAAEJ,KAAK;IAAEI;EAAS,CAAC,kBACjBxB,KAAA,CAAAa,aAAA,CAACR,WAAW;IAACoB,KAAK,EAAE,KAAM;IAACL,K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,EAAE;QAAEJ;MAAM;IAAE,GAAEsB,IAAW,CAAE;IAC7DC,OAAO,eAAExC,KAAA,CAAAa,aAAA,CAACU,eAAe;MAACN,KAAK,EAAEA,KAAM;MAACO,QAAQ,EAAES;IAAc,CAAE;EAAE,CACvE,CAAC;AAEV,CAAC,CAAC;AAEF,OAAO,MAAMQ,gBAAgB,GAAGA,CAAA,KAAM;EAClC,oBACIzC,KAAA,CAAAa,aAAA,CAACJ,gBAAgB,qBACbT,KAAA,CAAAa,aAAA,CAACJ,gBAAgB,CAACiC,QAAQ;IAACC,IAAI,EAAE;EAAO,gBACpC3C,KAAA,CAAAa,aAAA,CAACJ,gBAAgB,CAACiC,QAAQ,CAACE,IAAI;IAACC,OAAO,eAAE7C,KAAA,CAAAa,aAAA,CAACH,OAAO,MAAE;EAAE,CAAE,CAAC,eACxDV,KAAA,CAAAa,aAAA,CAACJ,gBAAgB,CAACiC,QAAQ,CAACI,GAAG;IAACD,OAAO,eAAE7C,KAAA,CAAAa,aAAA,CAACe,OAAO,MAAE;EAAE,CAAE,CAC/B,CACb,CAAC;AAE3B,CAAC","ignoreList":[]}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"names":["ICON_PICKER_SIZE"],"sources":["types.ts"],"sourcesContent":["/**\n * We want to have an abstract type, which does not define specifics of each possible icon (like color or skin tone).\n */\nexport type Icon = {\n
|
|
1
|
+
{"version":3,"names":["ICON_PICKER_SIZE"],"sources":["types.ts"],"sourcesContent":["/**\n * We want to have an abstract type, which does not define specifics of each possible icon (like color or skin tone).\n */\nexport type Icon = {\n type: \"icon\" | \"emoji\" | \"custom\" | (string & {});\n name: string;\n value?: string;\n [key: string]: any;\n};\n\ntype IconsRow = {\n type: \"icons\";\n icons: Icon[];\n};\n\ntype CategoryNameRow = {\n type: \"category-name\";\n name: string;\n};\n\nexport type IconPickerGridRow = IconsRow | CategoryNameRow;\n\nexport enum ICON_PICKER_SIZE {\n SMALL = \"sm\"\n}\n"],"mappings":"AAAA;AACA;AACA;;AAoBA,WAAYA,gBAAgB,0BAAhBA,gBAAgB;EAAhBA,gBAAgB;EAAA,OAAhBA,gBAAgB;AAAA","ignoreList":[]}
|
|
@@ -1,8 +1,12 @@
|
|
|
1
1
|
import React from "react";
|
|
2
|
-
import type { RichTextEditorProps } from "@webiny/lexical-editor/types";
|
|
3
|
-
import type
|
|
4
|
-
interface LexicalEditorProps extends Omit<RichTextEditorProps, "theme"> {
|
|
5
|
-
|
|
2
|
+
import type { RichTextEditorProps } from "@webiny/lexical-editor/types.js";
|
|
3
|
+
import { type RichTextValueWithHtml } from "./lexicalValueWithHtml.js";
|
|
4
|
+
export interface LexicalEditorProps extends Omit<RichTextEditorProps, "value" | "onChange" | "theme"> {
|
|
5
|
+
value?: RichTextValueWithHtml;
|
|
6
|
+
onChange?: (value: RichTextValueWithHtml) => void;
|
|
7
|
+
theme?: RichTextEditorProps["theme"];
|
|
6
8
|
}
|
|
7
9
|
export declare const LexicalEditor: (props: LexicalEditorProps) => React.JSX.Element;
|
|
8
|
-
export {
|
|
10
|
+
export declare namespace LexicalEditor {
|
|
11
|
+
type Props = LexicalEditorProps;
|
|
12
|
+
}
|
|
@@ -1,29 +1,40 @@
|
|
|
1
|
-
import React from "react";
|
|
2
|
-
import { FileManager } from "
|
|
1
|
+
import React, { useMemo, useRef } from "react";
|
|
2
|
+
import { FileManager } from "../index.js";
|
|
3
3
|
import { RichTextEditor as BaseEditor } from "@webiny/lexical-editor";
|
|
4
|
-
import {
|
|
4
|
+
import { DelayedOnChange } from "@webiny/admin-ui";
|
|
5
|
+
import { useAdminConfig } from "../../config/AdminConfig.js";
|
|
6
|
+
import { lexicalValueWithHtml } from "./lexicalValueWithHtml.js";
|
|
5
7
|
const imagesOnly = ["image/*"];
|
|
8
|
+
const noop = () => {};
|
|
6
9
|
export const LexicalEditor = props => {
|
|
7
10
|
const {
|
|
8
|
-
|
|
9
|
-
} =
|
|
10
|
-
const
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
...(props.theme || {})
|
|
15
|
-
};
|
|
11
|
+
lexicalTheme
|
|
12
|
+
} = useAdminConfig();
|
|
13
|
+
const configRef = useRef(undefined);
|
|
14
|
+
const onChange = useMemo(() => {
|
|
15
|
+
return lexicalValueWithHtml(configRef, props.onChange ?? noop);
|
|
16
|
+
}, [props.onChange]);
|
|
16
17
|
return /*#__PURE__*/React.createElement(FileManager, {
|
|
17
|
-
accept: imagesOnly
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
18
|
+
accept: imagesOnly,
|
|
19
|
+
render: ({
|
|
20
|
+
showFileManager
|
|
21
|
+
}) => /*#__PURE__*/React.createElement(DelayedOnChange, {
|
|
22
|
+
value: props.value?.state,
|
|
23
|
+
onChange: onChange
|
|
24
|
+
}, ({
|
|
25
|
+
value,
|
|
26
|
+
onChange
|
|
27
|
+
}) => /*#__PURE__*/React.createElement(BaseEditor, Object.assign({}, props, {
|
|
28
|
+
value: value,
|
|
29
|
+
onChange: onChange,
|
|
30
|
+
theme: props.theme ?? lexicalTheme,
|
|
31
|
+
configRef: configRef,
|
|
32
|
+
toolbarActionPlugins: [...(props.toolbarActionPlugins || []), {
|
|
33
|
+
targetAction: "image-action",
|
|
34
|
+
plugin: showFileManager
|
|
35
|
+
}]
|
|
36
|
+
})))
|
|
37
|
+
});
|
|
27
38
|
};
|
|
28
39
|
|
|
29
40
|
//# sourceMappingURL=LexicalEditor.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"names":["React","FileManager","RichTextEditor","BaseEditor","
|
|
1
|
+
{"version":3,"names":["React","useMemo","useRef","FileManager","RichTextEditor","BaseEditor","DelayedOnChange","useAdminConfig","lexicalValueWithHtml","imagesOnly","noop","LexicalEditor","props","lexicalTheme","configRef","undefined","onChange","createElement","accept","render","showFileManager","value","state","Object","assign","theme","toolbarActionPlugins","targetAction","plugin"],"sources":["LexicalEditor.tsx"],"sourcesContent":["import React, { useMemo, useRef } from \"react\";\nimport { FileManager } from \"~/components/index.js\";\nimport { RichTextEditor as BaseEditor } from \"@webiny/lexical-editor\";\nimport type { RichTextEditorProps } from \"@webiny/lexical-editor/types.js\";\nimport { DelayedOnChange } from \"@webiny/admin-ui\";\nimport { useAdminConfig } from \"~/config/AdminConfig.js\";\nimport { lexicalValueWithHtml, type RichTextValueWithHtml } from \"./lexicalValueWithHtml.js\";\n\nexport interface LexicalEditorProps\n extends Omit<RichTextEditorProps, \"value\" | \"onChange\" | \"theme\"> {\n value?: RichTextValueWithHtml;\n onChange?: (value: RichTextValueWithHtml) => void;\n theme?: RichTextEditorProps[\"theme\"];\n}\n\nconst imagesOnly = [\"image/*\"];\nconst noop = () => {};\n\nexport const LexicalEditor = (props: LexicalEditorProps) => {\n const { lexicalTheme } = useAdminConfig();\n const configRef = useRef<BaseEditor.InitialConfig | undefined>(undefined);\n\n const onChange = useMemo(() => {\n return lexicalValueWithHtml(configRef, props.onChange ?? noop);\n }, [props.onChange]);\n\n return (\n <FileManager\n accept={imagesOnly}\n render={({ showFileManager }) => (\n <DelayedOnChange value={props.value?.state} onChange={onChange}>\n {({ value, onChange }) => (\n <BaseEditor\n {...props}\n value={value}\n onChange={onChange}\n theme={props.theme ?? lexicalTheme}\n configRef={configRef}\n toolbarActionPlugins={[\n ...(props.toolbarActionPlugins || []),\n { targetAction: \"image-action\", plugin: showFileManager }\n ]}\n />\n )}\n </DelayedOnChange>\n )}\n />\n );\n};\n\nexport namespace LexicalEditor {\n export type Props = LexicalEditorProps;\n}\n"],"mappings":"AAAA,OAAOA,KAAK,IAAIC,OAAO,EAAEC,MAAM,QAAQ,OAAO;AAC9C,SAASC,WAAW;AACpB,SAASC,cAAc,IAAIC,UAAU,QAAQ,wBAAwB;AAErE,SAASC,eAAe,QAAQ,kBAAkB;AAClD,SAASC,cAAc;AACvB,SAASC,oBAAoB;AAS7B,MAAMC,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LinkForm = NonNullable<React.ComponentProps<typeof FloatingLinkEditorPlugin>["LinkForm"]>;
|
|
4
|
+
type LinkFormProps = React.ComponentProps<LexicalLinkForm>;
|
|
5
|
+
export declare const LexicalLinkForm: ({ linkData, onSave, removeLink }: LinkFormProps) => React.JSX.Element;
|
|
6
|
+
export {};
|
|
@@ -0,0 +1,92 @@
|
|
|
1
|
+
import React, { useEffect, useRef } from "react";
|
|
2
|
+
import { Button, Grid, Icon, IconButton, Input, Switch } from "@webiny/admin-ui";
|
|
3
|
+
import { Form, useBind } from "@webiny/form";
|
|
4
|
+
import { validation } from "@webiny/validation";
|
|
5
|
+
import { ReactComponent as GlobeIcon } from "@webiny/icons/language.svg";
|
|
6
|
+
import { ReactComponent as OpenInNew } from "@webiny/icons/open_in_new.svg";
|
|
7
|
+
import { ReactComponent as RemoveLink } from "@webiny/icons/link_off.svg";
|
|
8
|
+
export const LexicalLinkForm = ({
|
|
9
|
+
linkData,
|
|
10
|
+
onSave,
|
|
11
|
+
removeLink
|
|
12
|
+
}) => {
|
|
13
|
+
const onSubmit = data => {
|
|
14
|
+
onSave(data);
|
|
15
|
+
};
|
|
16
|
+
return /*#__PURE__*/React.createElement(Form, {
|
|
17
|
+
data: linkData,
|
|
18
|
+
onSubmit: onSubmit,
|
|
19
|
+
validateOnFirstSubmit: true,
|
|
20
|
+
submitOnEnter: true
|
|
21
|
+
}, form => /*#__PURE__*/React.createElement("div", {
|
|
22
|
+
className: "p-md"
|
|
23
|
+
}, /*#__PURE__*/React.createElement(Grid, {
|
|
24
|
+
gap: "small"
|
|
25
|
+
}, /*#__PURE__*/React.createElement(Grid.Column, {
|
|
26
|
+
span: 12
|
|
27
|
+
}, /*#__PURE__*/React.createElement(UrlInput, null))), /*#__PURE__*/React.createElement("div", {
|
|
28
|
+
className: "flex w-full items-center justify-between mt-sm gap-sm"
|
|
29
|
+
}, /*#__PURE__*/React.createElement(TargetSwitch, null), /*#__PURE__*/React.createElement(Button, {
|
|
30
|
+
variant: "ghost",
|
|
31
|
+
text: `Remove link`,
|
|
32
|
+
className: "text-destructive-primary! [&_svg]:fill-destructive",
|
|
33
|
+
onClick: removeLink,
|
|
34
|
+
icon: /*#__PURE__*/React.createElement(Icon, {
|
|
35
|
+
label: "Remove link",
|
|
36
|
+
icon: /*#__PURE__*/React.createElement(RemoveLink, null)
|
|
37
|
+
})
|
|
38
|
+
}), /*#__PURE__*/React.createElement(Button, {
|
|
39
|
+
variant: "primary",
|
|
40
|
+
text: `Save`,
|
|
41
|
+
onClick: form.submit
|
|
42
|
+
}))));
|
|
43
|
+
};
|
|
44
|
+
const UrlInput = () => {
|
|
45
|
+
const inputRef = useRef(null);
|
|
46
|
+
const urlBind = useBind({
|
|
47
|
+
name: "url",
|
|
48
|
+
validators: validation.create("required,url:allowRelative:allowHref")
|
|
49
|
+
});
|
|
50
|
+
useEffect(() => {
|
|
51
|
+
if (inputRef.current) {
|
|
52
|
+
setTimeout(() => {
|
|
53
|
+
inputRef.current?.focus();
|
|
54
|
+
}, 10);
|
|
55
|
+
}
|
|
56
|
+
}, []);
|
|
57
|
+
const openInNewTab = () => {
|
|
58
|
+
if (urlBind.validation.isValid !== false && urlBind.value) {
|
|
59
|
+
window.open(urlBind.value, "_blank");
|
|
60
|
+
}
|
|
61
|
+
};
|
|
62
|
+
return /*#__PURE__*/React.createElement(Input, Object.assign({}, urlBind, {
|
|
63
|
+
inputRef: ref => inputRef.current = ref,
|
|
64
|
+
variant: "secondary",
|
|
65
|
+
placeholder: "Enter link",
|
|
66
|
+
autoFocus: true,
|
|
67
|
+
startIcon: /*#__PURE__*/React.createElement(Icon, {
|
|
68
|
+
label: "globe",
|
|
69
|
+
icon: /*#__PURE__*/React.createElement(GlobeIcon, null)
|
|
70
|
+
}),
|
|
71
|
+
endIcon: /*#__PURE__*/React.createElement(IconButton, {
|
|
72
|
+
variant: "ghost",
|
|
73
|
+
icon: /*#__PURE__*/React.createElement(OpenInNew, null),
|
|
74
|
+
onClick: openInNewTab
|
|
75
|
+
})
|
|
76
|
+
}));
|
|
77
|
+
};
|
|
78
|
+
const TargetSwitch = () => {
|
|
79
|
+
const targetBind = useBind({
|
|
80
|
+
name: "target",
|
|
81
|
+
defaultValue: "_self"
|
|
82
|
+
});
|
|
83
|
+
return /*#__PURE__*/React.createElement(Switch, {
|
|
84
|
+
checked: targetBind.value === "_blank",
|
|
85
|
+
label: "Open in new tab",
|
|
86
|
+
onChange: value => {
|
|
87
|
+
targetBind.onChange(value === true ? "_blank" : "_self");
|
|
88
|
+
}
|
|
89
|
+
});
|
|
90
|
+
};
|
|
91
|
+
|
|
92
|
+
//# sourceMappingURL=LexicalLinkForm.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"names":["React","useEffect","useRef","Button","Grid","Icon","IconButton","Input","Switch","Form","useBind","validation","ReactComponent","GlobeIcon","OpenInNew","RemoveLink","LexicalLinkForm","linkData","onSave","removeLink","onSubmit","data","createElement","validateOnFirstSubmit","submitOnEnter","form","className","gap","Column","span","UrlInput","TargetSwitch","variant","text","onClick","icon","label","submit","inputRef","urlBind","name","validators","create","current","setTimeout","focus","openInNewTab","isValid","value","window","open","Object","assign","ref","placeholder","autoFocus","startIcon","endIcon","targetBind","defaultValue","checked","onChange"],"sources":["LexicalLinkForm.tsx"],"sourcesContent":["import React, { useEffect, useRef } from \"react\";\nimport type { FloatingLinkEditorPlugin } from \"@webiny/lexical-editor\";\nimport { Button, Grid, Icon, IconButton, Input, Switch } from \"@webiny/admin-ui\";\nimport { Form, useBind } from \"@webiny/form\";\nimport { validation } from \"@webiny/validation\";\nimport { ReactComponent as GlobeIcon } from \"@webiny/icons/language.svg\";\nimport { ReactComponent as OpenInNew } from \"@webiny/icons/open_in_new.svg\";\nimport { ReactComponent as RemoveLink } from \"@webiny/icons/link_off.svg\";\n\ntype LexicalLinkForm = NonNullable<\n React.ComponentProps<typeof FloatingLinkEditorPlugin>[\"LinkForm\"]\n>;\ntype LinkFormProps = React.ComponentProps<LexicalLinkForm>;\n\nexport const LexicalLinkForm = ({ linkData, onSave, removeLink }: LinkFormProps) => {\n const onSubmit = (data: LinkFormProps[\"linkData\"]) => {\n onSave(data);\n };\n\n return (\n <Form data={linkData} onSubmit={onSubmit} validateOnFirstSubmit submitOnEnter>\n {form => (\n <div className={\"p-md\"}>\n <Grid gap={\"small\"}>\n <Grid.Column span={12}>\n <UrlInput />\n </Grid.Column>\n </Grid>\n <div className={\"flex w-full items-center justify-between mt-sm gap-sm\"}>\n <TargetSwitch />\n <Button\n variant={\"ghost\"}\n text={`Remove link`}\n className={\"text-destructive-primary! [&_svg]:fill-destructive\"}\n onClick={removeLink}\n icon={<Icon label={\"Remove link\"} icon={<RemoveLink />} />}\n />\n <Button variant={\"primary\"} text={`Save`} onClick={form.submit} />\n </div>\n </div>\n )}\n </Form>\n );\n};\n\nconst UrlInput = () => {\n const inputRef = useRef<HTMLInputElement | null>(null);\n\n const urlBind = useBind({\n name: \"url\",\n validators: validation.create(\"required,url:allowRelative:allowHref\")\n });\n\n useEffect(() => {\n if (inputRef.current) {\n setTimeout(() => {\n inputRef.current?.focus();\n }, 10);\n }\n }, []);\n\n const openInNewTab = () => {\n if (urlBind.validation.isValid !== false && urlBind.value) {\n window.open(urlBind.value, \"_blank\");\n }\n };\n\n return (\n <Input\n {...urlBind}\n inputRef={ref => (inputRef.current = ref)}\n variant={\"secondary\"}\n placeholder={\"Enter link\"}\n autoFocus={true}\n startIcon={<Icon label=\"globe\" icon={<GlobeIcon />} />}\n endIcon={<IconButton variant=\"ghost\" icon={<OpenInNew />} onClick={openInNewTab} />}\n />\n );\n};\n\nconst TargetSwitch = () => {\n const targetBind = useBind({\n name: \"target\",\n defaultValue: \"_self\"\n });\n\n return (\n <Switch\n checked={targetBind.value === \"_blank\"}\n label={\"Open in new tab\"}\n onChange={value => {\n targetBind.onChange(value === true ? \"_blank\" : \"_self\");\n }}\n />\n );\n};\n"],"mappings":"AAAA,OAAOA,KAAK,IAAIC,SAAS,EAAEC,M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,CAACjB,IAAI;MAAC+B,KAAK,EAAC,OAAO;MAACD,IAAI,eAAEnC,KAAA,CAAAsB,aAAA,CAACT,SAAS,MAAE;IAAE,CAAE,CAAE;IACvD4C,OAAO,eAAEzD,KAAA,CAAAsB,aAAA,CAAChB,UAAU;MAAC0B,OAAO,EAAC,OAAO;MAACG,IAAI,eAAEnC,KAAA,CAAAsB,aAAA,CAACR,SAAS,MAAE,CAAE;MAACoB,OAAO,EAAEY;IAAa,CAAE;EAAE,EACvF,CAAC;AAEV,CAAC;AAED,MAAMf,YAAY,GAAGA,CAAA,KAAM;EACvB,MAAM2B,UAAU,GAAGhD,OAAO,CAAC;IACvB8B,IAAI,EAAE,QAAQ;IACdmB,YAAY,EAAE;EAClB,CAAC,CAAC;EAEF,oBACI3D,KAAA,CAAAsB,aAAA,CAACd,MAAM;IACHoD,OAAO,EAAEF,UAAU,CAACV,KAAK,KAAK,QAAS;IACvCZ,KAAK,EAAE,iBAAkB;IACzByB,QAAQ,EAAEb,KAAK,IAAI;MACfU,UAAU,CAACG,QAAQ,CAACb,KAAK,KAAK,IAAI,GAAG,QAAQ,GAAG,OAAO,CAAC;IAC5D;EAAE,CACL,CAAC;AAEV,CAAC","ignoreList":[]}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"names":["LexicalEditor"],"sources":["index.ts"],"sourcesContent":["export { LexicalEditor } from \"./LexicalEditor\";\n"],"mappings":"AAAA,SAASA,aAAa","ignoreList":[]}
|
|
1
|
+
{"version":3,"names":["LexicalEditor","LexicalLinkForm","lexicalValueWithHtml"],"sources":["index.ts"],"sourcesContent":["export { LexicalEditor } from \"./LexicalEditor.js\";\nexport { LexicalLinkForm } from \"./LexicalLinkForm.js\";\nexport { lexicalValueWithHtml, type RichTextValueWithHtml } from \"./lexicalValueWithHtml.js\";\n"],"mappings":"AAAA,SAASA,aAAa;AACtB,SAASC,eAAe;AACxB,SAASC,oBAAoB","ignoreList":[]}
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
import { RichTextEditor } from "@webiny/lexical-editor";
|
|
2
|
+
export type RichTextValueWithHtml = {
|
|
3
|
+
state: string;
|
|
4
|
+
html: string;
|
|
5
|
+
};
|
|
6
|
+
export type EditorConfigRef = React.MutableRefObject<RichTextEditor.InitialConfig | undefined>;
|
|
7
|
+
export declare const lexicalValueWithHtml: (editorConfigRef: EditorConfigRef, onChange: (value: RichTextValueWithHtml) => void) => (value: string) => void;
|
|
@@ -0,0 +1,36 @@
|
|
|
1
|
+
import { createLexicalStateTransformer } from "@webiny/lexical-converter";
|
|
2
|
+
const transformerCache = new Map();
|
|
3
|
+
const getOrCreate = editorConfigRef => {
|
|
4
|
+
if (!editorConfigRef.current) {
|
|
5
|
+
return undefined;
|
|
6
|
+
}
|
|
7
|
+
const id = editorConfigRef.current.editorId;
|
|
8
|
+
if (!transformerCache.has(id)) {
|
|
9
|
+
const transformer = createLexicalStateTransformer({
|
|
10
|
+
editorConfig: {
|
|
11
|
+
nodes: editorConfigRef.current.nodes,
|
|
12
|
+
theme: editorConfigRef.current.theme
|
|
13
|
+
}
|
|
14
|
+
});
|
|
15
|
+
transformerCache.set(id, transformer);
|
|
16
|
+
}
|
|
17
|
+
return transformerCache.get(id);
|
|
18
|
+
};
|
|
19
|
+
export const lexicalValueWithHtml = (editorConfigRef, onChange) => {
|
|
20
|
+
return value => {
|
|
21
|
+
const transformer = getOrCreate(editorConfigRef);
|
|
22
|
+
if (!transformer) {
|
|
23
|
+
onChange({
|
|
24
|
+
state: value,
|
|
25
|
+
html: ""
|
|
26
|
+
});
|
|
27
|
+
return;
|
|
28
|
+
}
|
|
29
|
+
onChange({
|
|
30
|
+
state: value,
|
|
31
|
+
html: transformer.toHtml(value)
|
|
32
|
+
});
|
|
33
|
+
};
|
|
34
|
+
};
|
|
35
|
+
|
|
36
|
+
//# sourceMappingURL=lexicalValueWithHtml.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"names":["createLexicalStateTransformer","transformerCache","Map","getOrCreate","editorConfigRef","current","undefined","id","editorId","has","transformer","editorConfig","nodes","theme","set","get","lexicalValueWithHtml","onChange","value","state","html","toHtml"],"sources":["lexicalValueWithHtml.ts"],"sourcesContent":["import { createLexicalStateTransformer } from \"@webiny/lexical-converter\";\nimport { RichTextEditor } from \"@webiny/lexical-editor\";\n\ntype LexicalStateTransformer = ReturnType<typeof createLexicalStateTransformer>;\n\nexport type RichTextValueWithHtml = {\n state: string;\n html: string;\n};\n\nexport type EditorConfigRef = React.MutableRefObject<RichTextEditor.InitialConfig | undefined>;\n\nconst transformerCache = new Map<string, LexicalStateTransformer>();\n\nconst getOrCreate = (editorConfigRef: EditorConfigRef) => {\n if (!editorConfigRef.current) {\n return undefined;\n }\n\n const id = editorConfigRef.current.editorId;\n\n if (!transformerCache.has(id)) {\n const transformer = createLexicalStateTransformer({\n editorConfig: {\n nodes: editorConfigRef.current.nodes,\n theme: editorConfigRef.current.theme\n }\n });\n\n transformerCache.set(id, transformer);\n }\n\n return transformerCache.get(id);\n};\n\nexport const lexicalValueWithHtml = (\n editorConfigRef: EditorConfigRef,\n onChange: (value: RichTextValueWithHtml) => void\n) => {\n return (value: string) => {\n const transformer = getOrCreate(editorConfigRef);\n\n if (!transformer) {\n onChange({\n state: value,\n html: \"\"\n });\n return;\n }\n\n onChange({\n state: value,\n html: transformer.toHtml(value)\n });\n };\n};\n"],"mappings":"AAAA,SAASA,6BAA6B,QAAQ,2BAA2B;AAYzE,MAAMC,gBAAgB,GAAG,IAAIC,GAAG,CAAkC,CAAC;AAEnE,MAAMC,WAAW,GAAIC,eAAgC,IAAK;EACtD,IAAI,CAACA,eAAe,CAACC,OAAO,EAAE;IAC1B,OAAOC,SAAS;EACpB;EAEA,MAAMC,EAAE,GAAGH,eAAe,CAACC,OAAO,CAACG,QAAQ;EAE3C,IAAI,CAACP,gBAAgB,CAACQ,GAAG,CAACF,EAAE,CAAC,EAAE;IAC3B,MAAMG,WAAW,GAAGV,6BAA6B,CAAC;MAC9CW,YAAY,EAAE;QACVC,KAAK,EAAER,eAAe,CAACC,OAAO,CAACO,KAAK;QACpCC,KAAK,EAAET,eAAe,CAACC,OAAO,CAACQ;MACnC;IACJ,CAAC,CAAC;IAEFZ,gBAAgB,CAACa,GAAG,CAACP,EAAE,EAAEG,WAAW,CAAC;EACzC;EAEA,OAAOT,gBAAgB,CAACc,GAAG,CAACR,EAAE,CAAC;AACnC,CAAC;AAED,OAAO,MAAMS,oBAAoB,GAAGA,CAChCZ,eAAgC,EAChCa,QAAgD,KAC/C;EACD,OAAQC,KAAa,IAAK;IACtB,MAAMR,WAAW,GAAGP,WAAW,CAACC,eAAe,CAAC;IAEhD,IAAI,CAACM,WAAW,EAAE;MACdO,QAAQ,CAAC;QACLE,KAAK,EAAED,KAAK;QACZE,IAAI,EAAE;MACV,CAAC,CAAC;MACF;IACJ;IAEAH,QAAQ,CAAC;MACLE,KAAK,EAAED,KAAK;MACZE,IAAI,EAAEV,WAAW,CAACW,MAAM,CAACH,KAAK;IAClC,CAAC,CAAC;EACN,CAAC;AACL,CAAC","ignoreList":[]}
|
|
@@ -0,0 +1,27 @@
|
|
|
1
|
+
import React from "react";
|
|
2
|
+
interface NavigationPromptProps {
|
|
3
|
+
when: boolean | (() => boolean);
|
|
4
|
+
message: React.ReactNode;
|
|
5
|
+
confirmLabel?: string;
|
|
6
|
+
cancelLabel?: string;
|
|
7
|
+
}
|
|
8
|
+
export declare const NavigationPrompt: (({ when, message, confirmLabel, cancelLabel }: NavigationPromptProps) => null) & {
|
|
9
|
+
original: ({ when, message, confirmLabel, cancelLabel }: NavigationPromptProps) => null;
|
|
10
|
+
originalName: string;
|
|
11
|
+
displayName: string;
|
|
12
|
+
} & {
|
|
13
|
+
original: (({ when, message, confirmLabel, cancelLabel }: NavigationPromptProps) => null) & {
|
|
14
|
+
original: ({ when, message, confirmLabel, cancelLabel }: NavigationPromptProps) => null;
|
|
15
|
+
originalName: string;
|
|
16
|
+
displayName: string;
|
|
17
|
+
};
|
|
18
|
+
originalName: string;
|
|
19
|
+
displayName: string;
|
|
20
|
+
} & {
|
|
21
|
+
createDecorator: (decorator: import("@webiny/app").ComponentDecorator<(({ when, message, confirmLabel, cancelLabel }: NavigationPromptProps) => null) & {
|
|
22
|
+
original: ({ when, message, confirmLabel, cancelLabel }: NavigationPromptProps) => null;
|
|
23
|
+
originalName: string;
|
|
24
|
+
displayName: string;
|
|
25
|
+
}>) => (props: unknown) => React.JSX.Element;
|
|
26
|
+
};
|
|
27
|
+
export {};
|
|
@@ -0,0 +1,39 @@
|
|
|
1
|
+
import { useEffect, useRef } from "react";
|
|
2
|
+
import { useRouter } from "@webiny/app";
|
|
3
|
+
import { makeDecoratable } from "@webiny/react-composition";
|
|
4
|
+
import { useDialogs } from "./Dialogs/useDialogs.js";
|
|
5
|
+
export const NavigationPrompt = makeDecoratable("NavigationPrompt", ({
|
|
6
|
+
when,
|
|
7
|
+
message,
|
|
8
|
+
confirmLabel,
|
|
9
|
+
cancelLabel
|
|
10
|
+
}) => {
|
|
11
|
+
const whenRef = useRef(when);
|
|
12
|
+
const router = useRouter();
|
|
13
|
+
const dialogs = useDialogs();
|
|
14
|
+
|
|
15
|
+
// Update the ref synchronously on every render to ensure we always have the latest value
|
|
16
|
+
whenRef.current = when;
|
|
17
|
+
useEffect(() => {
|
|
18
|
+
router.onRouteExit(transition => {
|
|
19
|
+
const condition = whenRef.current;
|
|
20
|
+
const shouldConfirm = typeof condition === "function" ? condition() : condition;
|
|
21
|
+
if (shouldConfirm) {
|
|
22
|
+
dialogs.showDialog({
|
|
23
|
+
title: "Confirm Navigation",
|
|
24
|
+
content: message,
|
|
25
|
+
acceptLabel: confirmLabel ?? "Yes!",
|
|
26
|
+
cancelLabel: cancelLabel ?? "No, stay here.",
|
|
27
|
+
onAccept: () => {
|
|
28
|
+
transition.continue();
|
|
29
|
+
}
|
|
30
|
+
});
|
|
31
|
+
} else {
|
|
32
|
+
transition.continue();
|
|
33
|
+
}
|
|
34
|
+
});
|
|
35
|
+
}, []);
|
|
36
|
+
return null;
|
|
37
|
+
});
|
|
38
|
+
|
|
39
|
+
//# sourceMappingURL=NavigationPrompt.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"names":["useEffect","useRef","useRouter","makeDecoratable","useDialogs","NavigationPrompt","when","message","confirmLabel","cancelLabel","whenRef","router","dialogs","current","onRouteExit","transition","condition","shouldConfirm","showDialog","title","content","acceptLabel","onAccept","continue"],"sources":["NavigationPrompt.tsx"],"sourcesContent":["import React, { useEffect, useRef } from \"react\";\nimport { useRouter } from \"@webiny/app\";\nimport { makeDecoratable } from \"@webiny/react-composition\";\nimport { useDialogs } from \"~/components/Dialogs/useDialogs.js\";\n\ninterface NavigationPromptProps {\n when: boolean | (() => boolean);\n message: React.ReactNode;\n confirmLabel?: string;\n cancelLabel?: string;\n}\n\nexport const NavigationPrompt = makeDecoratable(\n \"NavigationPrompt\",\n ({ when, message, confirmLabel, cancelLabel }: NavigationPromptProps) => {\n const whenRef = useRef(when);\n const router = useRouter();\n const dialogs = useDialogs();\n\n // Update the ref synchronously on every render to ensure we always have the latest value\n whenRef.current = when;\n\n useEffect(() => {\n router.onRouteExit(transition => {\n const condition = whenRef.current;\n const shouldConfirm = typeof condition === \"function\" ? condition() : condition;\n\n if (shouldConfirm) {\n dialogs.showDialog({\n title: \"Confirm Navigation\",\n content: message,\n acceptLabel: confirmLabel ?? \"Yes!\",\n cancelLabel: cancelLabel ?? \"No, stay here.\",\n onAccept: () => {\n transition.continue();\n }\n });\n } else {\n transition.continue();\n }\n });\n }, []);\n\n return null;\n }\n);\n"],"mappings":"AAAA,SAAgBA,SAAS,EAAEC,MAAM,QAAQ,OAAO;AAChD,SAASC,SAAS,QAAQ,aAAa;AACvC,SAASC,eAAe,QAAQ,2BAA2B;AAC3D,SAASC,UAAU;AASnB,OAAO,MAAMC,gBAAgB,GAAGF,eAAe,CAC3C,kBAAkB,EAClB,CAAC;EAAEG,IAAI;EAAEC,OAAO;EAAEC,YAAY;EAAEC;AAAmC,CAAC,KAAK;EACrE,MAAMC,OAAO,GAAGT,MAAM,CAACK,IAAI,CAAC;EAC5B,MAAMK,MAAM,GAAGT,SAAS,CAAC,CAAC;EAC1B,MAAMU,OAAO,GAAGR,UAAU,CAAC,CAAC;;EAE5B;EACAM,OAAO,CAACG,OAAO,GAAGP,IAAI;EAEtBN,SAAS,CAAC,MAAM;IACZW,MAAM,CAACG,WAAW,CAACC,UAAU,IAAI;MAC7B,MAAMC,SAAS,GAAGN,OAAO,CAACG,OAAO;MACjC,MAAMI,aAAa,GAAG,OAAOD,SAAS,KAAK,UAAU,GAAGA,SAAS,CAAC,CAAC,GAAGA,SAAS;MAE/E,IAAIC,aAAa,EAAE;QACfL,OAAO,CAACM,UAAU,CAAC;UACfC,KAAK,EAAE,oBAAoB;UAC3BC,OAAO,EAAEb,OAAO;UAChBc,WAAW,EAAEb,YAAY,IAAI,MAAM;UACnCC,WAAW,EAAEA,WAAW,IAAI,gBAAgB;UAC5Ca,QAAQ,EAAEA,CAAA,KAAM;YACZP,UAAU,CAACQ,QAAQ,CAAC,CAAC;UACzB;QACJ,CAAC,CAAC;MACN,CAAC,MAAM;QACHR,UAAU,CAACQ,QAAQ,CAAC,CAAC;MACzB;IACJ,CAAC,CAAC;EACN,CAAC,EAAE,EAAE,CAAC;EAEN,OAAO,IAAI;AACf,CACJ,CAAC","ignoreList":[]}
|
|
@@ -0,0 +1,20 @@
|
|
|
1
|
+
import * as React from "react";
|
|
2
|
+
import { Link, Text } from "@webiny/admin-ui";
|
|
3
|
+
import authErrorImg from "./SecureRouteError.svg";
|
|
4
|
+
export const NotAuthorizedError = () => {
|
|
5
|
+
return /*#__PURE__*/React.createElement("div", {
|
|
6
|
+
className: "flex-1"
|
|
7
|
+
}, /*#__PURE__*/React.createElement("div", {
|
|
8
|
+
className: "h-full flex flex-col items-center justify-center text-center gap-xs"
|
|
9
|
+
}, /*#__PURE__*/React.createElement("img", {
|
|
10
|
+
width: 200,
|
|
11
|
+
height: 200,
|
|
12
|
+
src: authErrorImg,
|
|
13
|
+
alt: "Not Authorized",
|
|
14
|
+
className: "mb-xl"
|
|
15
|
+
}), /*#__PURE__*/React.createElement(Text, null, "You are not authorized to view this route."), /*#__PURE__*/React.createElement(Text, null, "Please contact your administrator to request access."), /*#__PURE__*/React.createElement(Link, {
|
|
16
|
+
to: "/"
|
|
17
|
+
}, "Take me back.")));
|
|
18
|
+
};
|
|
19
|
+
|
|
20
|
+
//# sourceMappingURL=NotAuthorizedError.js.map
|