@finsemble/finsemble-ui 6.6.3 → 7.0.0-beta-X
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/package.json +31 -43
- package/react/actions/favoriteActions.d.ts +1 -0
- package/react/actions/favoriteActions.js +1 -0
- package/react/actions/favoriteActions.js.map +1 -1
- package/react/actions/menuActions.d.ts +1 -0
- package/react/actions/menuActions.js +1 -0
- package/react/actions/menuActions.js.map +1 -1
- package/react/actions/rootActions.d.ts +1 -0
- package/react/actions/rootActions.js +1 -0
- package/react/actions/rootActions.js.map +1 -1
- package/react/actions/searchActions.d.ts +1 -0
- package/react/actions/searchActions.js +1 -0
- package/react/actions/searchActions.js.map +1 -1
- package/react/actions/toolbarActions.d.ts +34 -0
- package/react/actions/toolbarActions.js +17 -0
- package/react/actions/toolbarActions.js.map +1 -1
- package/react/actions/workspaceActions.d.ts +1 -0
- package/react/actions/workspaceActions.js +1 -0
- package/react/actions/workspaceActions.js.map +1 -1
- package/react/assets/css/advancedAppLauncher.css +22 -19
- package/react/assets/css/appCatalog.css +67 -72
- package/react/assets/css/authentication.css +4 -3
- package/react/assets/css/button.css +4 -11
- package/react/assets/css/core/formElements.css +1 -1
- package/react/assets/css/core/icons.css +3 -2
- package/react/assets/css/core/notifications.css +2 -2
- package/react/assets/css/core/windowFrame.css +9 -9
- package/react/assets/css/dashbar.css +1 -1
- package/react/assets/css/defaultTheme.css +9 -53
- package/react/assets/css/dialogs.css +13 -11
- package/react/assets/css/favorites.css +3 -48
- package/react/assets/css/finsemble.css +6 -2
- package/react/assets/css/font-finance.css +233 -120
- package/react/assets/css/fonts/Open_Sans/OpenSans-Definition.css +10 -10
- package/react/assets/css/linkerWindow.css +15 -3
- package/react/assets/css/menus.css +12 -12
- package/react/assets/css/notificationsCenter.css +49 -33
- package/react/assets/css/processMonitor.css +7 -4
- package/react/assets/css/search.css +1 -1
- package/react/assets/css/shared/animations.css +10 -4
- package/react/assets/css/shared/common.css +40 -0
- package/react/assets/css/tags.css +10 -10
- package/react/assets/css/toolbar.css +22 -19
- package/react/assets/css/userPreferences.css +29 -26
- package/react/assets/css/windowTitleBar.css +86 -40
- package/react/assets/icons/server.svg +26 -0
- package/react/componentTemplateGenerator.js +3 -2
- package/react/componentTemplateGenerator.js.map +1 -1
- package/react/components/FinsembleProvider.d.ts +7 -0
- package/react/components/FinsembleProvider.js +2 -0
- package/react/components/FinsembleProvider.js.map +1 -1
- package/react/components/appCatalog/AppCatalog.d.ts +4 -0
- package/react/components/appCatalog/AppCatalog.js +4 -0
- package/react/components/appCatalog/AppCatalog.js.map +1 -1
- package/react/components/appCatalog/AppCatalogComponent.d.ts +58 -0
- package/react/components/appCatalog/AppCatalogComponent.js +70 -1
- package/react/components/appCatalog/AppCatalogComponent.js.map +1 -1
- package/react/components/appCatalog/components/AppCard.d.ts +35 -0
- package/react/components/appCatalog/components/AppCard.js +42 -0
- package/react/components/appCatalog/components/AppCard.js.map +1 -1
- package/react/components/appCatalog/components/AppResults.d.ts +10 -0
- package/react/components/appCatalog/components/AppResults.js +24 -0
- package/react/components/appCatalog/components/AppResults.js.map +1 -1
- package/react/components/appCatalog/components/Carousel.d.ts +26 -0
- package/react/components/appCatalog/components/Carousel.js +34 -0
- package/react/components/appCatalog/components/Carousel.js.map +1 -1
- package/react/components/appCatalog/components/EmptyResults.d.ts +4 -0
- package/react/components/appCatalog/components/EmptyResults.js +8 -0
- package/react/components/appCatalog/components/EmptyResults.js.map +1 -1
- package/react/components/appCatalog/components/Hero.d.ts +15 -0
- package/react/components/appCatalog/components/Hero.js +15 -0
- package/react/components/appCatalog/components/Hero.js.map +1 -1
- package/react/components/appCatalog/components/Home.d.ts +6 -4
- package/react/components/appCatalog/components/Home.js +10 -0
- package/react/components/appCatalog/components/Home.js.map +1 -1
- package/react/components/appCatalog/components/SearchBar.d.ts +31 -0
- package/react/components/appCatalog/components/SearchBar.js +33 -0
- package/react/components/appCatalog/components/SearchBar.js.map +1 -1
- package/react/components/appCatalog/components/Showcase/AppDescription.d.ts +5 -0
- package/react/components/appCatalog/components/Showcase/AppDescription.js +9 -0
- package/react/components/appCatalog/components/Showcase/AppDescription.js.map +1 -1
- package/react/components/appCatalog/components/Showcase/AppDevNotes.d.ts +7 -0
- package/react/components/appCatalog/components/Showcase/AppDevNotes.js +15 -0
- package/react/components/appCatalog/components/Showcase/AppDevNotes.js.map +1 -1
- package/react/components/appCatalog/components/Showcase/AppShowcase.d.ts +17 -0
- package/react/components/appCatalog/components/Showcase/AppShowcase.js +25 -0
- package/react/components/appCatalog/components/Showcase/AppShowcase.js.map +1 -1
- package/react/components/appCatalog/components/Showcase/Header.d.ts +7 -0
- package/react/components/appCatalog/components/Showcase/Header.js +12 -0
- package/react/components/appCatalog/components/Showcase/Header.js.map +1 -1
- package/react/components/appCatalog/components/Showcase/ImageCarousel.d.ts +7 -0
- package/react/components/appCatalog/components/Showcase/ImageCarousel.js +11 -0
- package/react/components/appCatalog/components/Showcase/ImageCarousel.js.map +1 -1
- package/react/components/appCatalog/components/Showcase/Modal.d.ts +10 -0
- package/react/components/appCatalog/components/Showcase/Modal.js +10 -0
- package/react/components/appCatalog/components/Showcase/Modal.js.map +1 -1
- package/react/components/appCatalog/components/Showcase/ReleaseNotes.d.ts +5 -0
- package/react/components/appCatalog/components/Showcase/ReleaseNotes.js +9 -0
- package/react/components/appCatalog/components/Showcase/ReleaseNotes.js.map +1 -1
- package/react/components/appCatalog/components/Showcase/SupportNotes.d.ts +6 -0
- package/react/components/appCatalog/components/Showcase/SupportNotes.js +11 -0
- package/react/components/appCatalog/components/Showcase/SupportNotes.js.map +1 -1
- package/react/components/appCatalog/components/Showcase/VersionNotes.d.ts +5 -0
- package/react/components/appCatalog/components/Showcase/VersionNotes.js +9 -0
- package/react/components/appCatalog/components/Showcase/VersionNotes.js.map +1 -1
- package/react/components/appCatalog/components/Tag.d.ts +6 -0
- package/react/components/appCatalog/components/Tag.js +10 -0
- package/react/components/appCatalog/components/Tag.js.map +1 -1
- package/react/components/appCatalog/components/Toast.d.ts +5 -0
- package/react/components/appCatalog/components/Toast.js +9 -0
- package/react/components/appCatalog/components/Toast.js.map +1 -1
- package/react/components/appCatalog/components/helpers.js +1 -0
- package/react/components/appCatalog/components/helpers.js.map +1 -1
- package/react/components/appCatalog/modules/AppDirectory.d.ts +5 -0
- package/react/components/appCatalog/modules/AppDirectory.js +5 -0
- package/react/components/appCatalog/modules/AppDirectory.js.map +1 -1
- package/react/components/appCatalog/modules/FDC3.d.ts +37 -0
- package/react/components/appCatalog/modules/FDC3.js +40 -0
- package/react/components/appCatalog/modules/FDC3.js.map +1 -1
- package/react/components/appCatalog/stores/appStore.js +1 -0
- package/react/components/appCatalog/stores/appStore.js.map +1 -1
- package/react/components/appCatalog/stores/storeActions.d.ts +91 -0
- package/react/components/appCatalog/stores/storeActions.js +116 -1
- package/react/components/appCatalog/stores/storeActions.js.map +1 -1
- package/react/components/common/ButtonIcon.js +1 -1
- package/react/components/common/ButtonIcon.js.map +1 -1
- package/react/components/common/ButtonRow.js +2 -2
- package/react/components/common/ButtonRow.js.map +1 -1
- package/react/components/common/Checkbox.d.ts +1 -0
- package/react/components/common/Checkbox.js +3 -3
- package/react/components/common/Checkbox.js.map +1 -1
- package/react/components/common/ColorPicker.d.ts +5 -0
- package/react/components/common/ColorPicker.js +56 -15
- package/react/components/common/ColorPicker.js.map +1 -1
- package/react/components/common/DropZone.d.ts +11 -0
- package/react/components/common/DropZone.js +21 -1
- package/react/components/common/DropZone.js.map +1 -1
- package/react/components/common/DropdownButton.d.ts +4 -0
- package/react/components/common/DropdownButton.js +4 -0
- package/react/components/common/DropdownButton.js.map +1 -1
- package/react/components/common/ErrorBoundary.d.ts +34 -0
- package/react/components/common/ErrorBoundary.js +43 -0
- package/react/components/common/ErrorBoundary.js.map +1 -0
- package/react/components/common/FileInput.d.ts +8 -1
- package/react/components/common/FileInput.js +19 -4
- package/react/components/common/FileInput.js.map +1 -1
- package/react/components/common/FinsembleIcon.d.ts +13 -2
- package/react/components/common/FinsembleIcon.js +61 -5
- package/react/components/common/FinsembleIcon.js.map +1 -1
- package/react/components/common/FinsembleLink.d.ts +6 -0
- package/react/components/common/FinsembleLink.js +12 -0
- package/react/components/common/FinsembleLink.js.map +1 -0
- package/react/components/common/FinsembleSelect.js +5 -1
- package/react/components/common/FinsembleSelect.js.map +1 -1
- package/react/components/common/FinsembleToggle.d.ts +1 -2
- package/react/components/common/FinsembleToggle.js +2 -6
- package/react/components/common/FinsembleToggle.js.map +1 -1
- package/react/components/common/FinsembleToggleButtonBar.d.ts +13 -0
- package/react/components/common/FinsembleToggleButtonBar.js +44 -0
- package/react/components/common/FinsembleToggleButtonBar.js.map +1 -0
- package/react/components/common/InputTable.d.ts +10 -3
- package/react/components/common/InputTable.js +20 -13
- package/react/components/common/InputTable.js.map +1 -1
- package/react/components/common/Tab.js +36 -5
- package/react/components/common/Tab.js.map +1 -1
- package/react/components/common/TimeSelect.js +34 -3
- package/react/components/common/TimeSelect.js.map +1 -1
- package/react/components/common/Tooltip.js +2 -0
- package/react/components/common/Tooltip.js.map +1 -1
- package/react/components/common/css/FinsembleToggle.css +22 -0
- package/react/components/common/css/accordion.css +9 -6
- package/react/components/common/css/application-edit-page.css +48 -45
- package/react/components/common/css/button.css +10 -5
- package/react/components/common/css/color-picker.css +3 -3
- package/react/components/common/css/drop-zone.css +2 -6
- package/react/components/common/css/file-input.css +5 -5
- package/react/components/common/css/header.css +3 -2
- package/react/components/common/css/icon.css +1 -1
- package/react/components/common/css/loading-spinner.css +7 -12
- package/react/components/common/css/selector.css +4 -4
- package/react/components/common/css/styles.css +22 -16
- package/react/components/common/css/tab.css +14 -14
- package/react/components/common/css/time-select.css +2 -1
- package/react/components/common/css/toggle.css +4 -12
- package/react/components/common/css/tooltip.css +2 -3
- package/react/components/common/file_helpers.js +2 -0
- package/react/components/common/file_helpers.js.map +1 -1
- package/react/components/common/helpers.js +12 -1
- package/react/components/common/helpers.js.map +1 -1
- package/react/components/common/stories/ColorPicker.stories.js +9 -11
- package/react/components/common/stories/ColorPicker.stories.js.map +1 -1
- package/react/components/common/stories/FileInput.stories.d.ts +3 -1
- package/react/components/common/stories/FileInput.stories.js +12 -0
- package/react/components/common/stories/FileInput.stories.js.map +1 -1
- package/react/components/common/stories/FinsembleToggle.stories.d.ts +1 -2
- package/react/components/common/stories/FinsembleToggle.stories.js +0 -7
- package/react/components/common/stories/FinsembleToggle.stories.js.map +1 -1
- package/react/components/common/stories/FinsembleToggleButtonBar.stories.d.ts +14 -0
- package/react/components/common/stories/FinsembleToggleButtonBar.stories.js +97 -0
- package/react/components/common/stories/FinsembleToggleButtonBar.stories.js.map +1 -0
- package/react/components/common/stories/InputTable.stories.d.ts +4 -3
- package/react/components/common/stories/InputTable.stories.js +18 -8
- package/react/components/common/stories/InputTable.stories.js.map +1 -1
- package/react/components/common/tests/Accordion.spec.js +6 -0
- package/react/components/common/tests/Accordion.spec.js.map +1 -1
- package/react/components/common/tests/ButtonRow.spec.js +5 -0
- package/react/components/common/tests/ButtonRow.spec.js.map +1 -1
- package/react/components/common/tests/Checkbox.spec.js +1 -0
- package/react/components/common/tests/Checkbox.spec.js.map +1 -1
- package/react/components/common/tests/ColorPicker.spec.js +6 -0
- package/react/components/common/tests/ColorPicker.spec.js.map +1 -1
- package/react/components/common/tests/DropZone.spec.js +1 -0
- package/react/components/common/tests/DropZone.spec.js.map +1 -1
- package/react/components/common/tests/FileInput.spec.js +22 -0
- package/react/components/common/tests/FileInput.spec.js.map +1 -1
- package/react/components/common/tests/FinsembleSelect.spec.js +1 -0
- package/react/components/common/tests/FinsembleSelect.spec.js.map +1 -1
- package/react/components/common/tests/FinsembleToggle.spec.js +2 -6
- package/react/components/common/tests/FinsembleToggle.spec.js.map +1 -1
- package/react/components/common/tests/FinsembleToggleButtonBar.spec.d.ts +1 -0
- package/react/components/common/tests/FinsembleToggleButtonBar.spec.js +41 -0
- package/react/components/common/tests/FinsembleToggleButtonBar.spec.js.map +1 -0
- package/react/components/common/tests/InputTable.spec.js +3 -3
- package/react/components/common/tests/InputTable.spec.js.map +1 -1
- package/react/components/common/tests/TimeSelect.spec.js +4 -0
- package/react/components/common/tests/TimeSelect.spec.js.map +1 -1
- package/react/components/common/tests/Tooltip.spec.js +16 -0
- package/react/components/common/tests/Tooltip.spec.js.map +1 -1
- package/react/components/favorites/FavoriteMaker.d.ts +8 -0
- package/react/components/favorites/FavoriteMaker.js +10 -1
- package/react/components/favorites/FavoriteMaker.js.map +1 -1
- package/react/components/favorites/FavoritesShell.d.ts +4 -0
- package/react/components/favorites/FavoritesShell.js +13 -1
- package/react/components/favorites/FavoritesShell.js.map +1 -1
- package/react/components/favorites/FavoritesShell.spec.js +3 -0
- package/react/components/favorites/FavoritesShell.spec.js.map +1 -1
- package/react/components/fdc3Resolver/ResolverContainer.js +12 -7
- package/react/components/fdc3Resolver/ResolverContainer.js.map +1 -1
- package/react/components/fdc3Resolver/ResolverDialog.css +16 -3
- package/react/components/fdc3Resolver/ResolverDialog.js +7 -2
- package/react/components/fdc3Resolver/ResolverDialog.js.map +1 -1
- package/react/components/fdc3Resolver/ResolverDialog.spec.js +3 -2
- package/react/components/fdc3Resolver/ResolverDialog.spec.js.map +1 -1
- package/react/components/fdc3Resolver/ResolverDialog.stories.js +2 -0
- package/react/components/fdc3Resolver/ResolverDialog.stories.js.map +1 -1
- package/react/components/icon/Icon.d.ts +14 -1
- package/react/components/icon/Icon.js +42 -1
- package/react/components/icon/Icon.js.map +1 -1
- package/react/components/legacyControls/FinsembleDialog.d.ts +4 -0
- package/react/components/legacyControls/FinsembleDialog.js +16 -1
- package/react/components/legacyControls/FinsembleDialog.js.map +1 -1
- package/react/components/legacyControls/FinsembleDialogButton.d.ts +3 -0
- package/react/components/legacyControls/FinsembleDialogButton.js +6 -1
- package/react/components/legacyControls/FinsembleDialogButton.js.map +1 -1
- package/react/components/legacyControls/FinsembleDialogQuestion.d.ts +7 -0
- package/react/components/legacyControls/FinsembleDialogQuestion.js +7 -0
- package/react/components/legacyControls/FinsembleDialogQuestion.js.map +1 -1
- package/react/components/legacyControls/FinsembleDialogTextInput.d.ts +3 -0
- package/react/components/legacyControls/FinsembleDialogTextInput.js +14 -0
- package/react/components/legacyControls/FinsembleDialogTextInput.js.map +1 -1
- package/react/components/legacyControls/FinsembleDnDContext.d.ts +19 -0
- package/react/components/legacyControls/FinsembleDnDContext.js +133 -8
- package/react/components/legacyControls/FinsembleDnDContext.js.map +1 -1
- package/react/components/legacyControls/FinsembleDraggable.d.ts +3 -0
- package/react/components/legacyControls/FinsembleDraggable.js +3 -0
- package/react/components/legacyControls/FinsembleDraggable.js.map +1 -1
- package/react/components/legacyControls/FinsembleHoverDetector.d.ts +15 -0
- package/react/components/legacyControls/FinsembleHoverDetector.js +26 -1
- package/react/components/legacyControls/FinsembleHoverDetector.js.map +1 -1
- package/react/components/legacyControls/FinsembleMenuSection.d.ts +4 -0
- package/react/components/legacyControls/FinsembleMenuSection.js +38 -0
- package/react/components/legacyControls/FinsembleMenuSection.js.map +1 -1
- package/react/components/legacyControls/tests/FinsembleDialogButton.spec.js +1 -0
- package/react/components/legacyControls/tests/FinsembleDialogButton.spec.js.map +1 -1
- package/react/components/legacyControls/tests/FinsembleDialogTextInput.spec.js +1 -0
- package/react/components/legacyControls/tests/FinsembleDialogTextInput.spec.js.map +1 -1
- package/react/components/linker/LinkerMenu.d.ts +3 -0
- package/react/components/linker/LinkerMenu.js +21 -0
- package/react/components/linker/LinkerMenu.js.map +1 -1
- package/react/components/linker/LinkerMenuDeprecated.d.ts +3 -0
- package/react/components/linker/LinkerMenuDeprecated.js +9 -0
- package/react/components/linker/LinkerMenuDeprecated.js.map +1 -1
- package/react/components/linker/remoteRedux.js +1 -0
- package/react/components/linker/remoteRedux.js.map +1 -1
- package/react/components/menu/Menu.d.ts +15 -0
- package/react/components/menu/Menu.js +15 -0
- package/react/components/menu/Menu.js.map +1 -1
- package/react/components/menu/MenuAutoResizer.d.ts +7 -0
- package/react/components/menu/MenuAutoResizer.js +27 -0
- package/react/components/menu/MenuAutoResizer.js.map +1 -1
- package/react/components/menu/MenuContent.d.ts +4 -0
- package/react/components/menu/MenuContent.js +4 -0
- package/react/components/menu/MenuContent.js.map +1 -1
- package/react/components/menu/MenuHotKey.d.ts +14 -0
- package/react/components/menu/MenuHotKey.js +15 -0
- package/react/components/menu/MenuHotKey.js.map +1 -1
- package/react/components/menu/MenuItem.d.ts +8 -0
- package/react/components/menu/MenuItem.js +13 -2
- package/react/components/menu/MenuItem.js.map +1 -1
- package/react/components/menu/MenuPortal.js +125 -24
- package/react/components/menu/MenuPortal.js.map +1 -1
- package/react/components/menu/MenuShell.d.ts +16 -0
- package/react/components/menu/MenuShell.js +26 -0
- package/react/components/menu/MenuShell.js.map +1 -1
- package/react/components/menu/MenuToggle.d.ts +3 -0
- package/react/components/menu/MenuToggle.js +5 -2
- package/react/components/menu/MenuToggle.js.map +1 -1
- package/react/components/menu/keyboardNavigation.d.ts +13 -22
- package/react/components/menu/keyboardNavigation.js +165 -160
- package/react/components/menu/keyboardNavigation.js.map +1 -1
- package/react/components/menu/menuContext.d.ts +6 -0
- package/react/components/menu/menuContext.js +6 -0
- package/react/components/menu/menuContext.js.map +1 -1
- package/react/components/menu/menuHelpers.d.ts +22 -0
- package/react/components/menu/menuHelpers.js +58 -1
- package/react/components/menu/menuHelpers.js.map +1 -1
- package/react/components/notifications/components/drawer/DrawerControls.js +47 -25
- package/react/components/notifications/components/drawer/DrawerControls.js.map +1 -1
- package/react/components/notifications/components/drawer/DrawerHeader.js +5 -0
- package/react/components/notifications/components/drawer/DrawerHeader.js.map +1 -1
- package/react/components/notifications/components/notificationsCenter/NotificationsCenter.js +37 -6
- package/react/components/notifications/components/notificationsCenter/NotificationsCenter.js.map +1 -1
- package/react/components/notifications/components/notificationsToasts/NotificationsToasts.js +3 -0
- package/react/components/notifications/components/notificationsToasts/NotificationsToasts.js.map +1 -1
- package/react/components/notifications/components/shared/CheckButton.js +19 -8
- package/react/components/notifications/components/shared/CheckButton.js.map +1 -1
- package/react/components/notifications/components/shared/NotificationCardShell.d.ts +9 -0
- package/react/components/notifications/components/shared/NotificationCardShell.js +15 -7
- package/react/components/notifications/components/shared/NotificationCardShell.js.map +1 -1
- package/react/components/notifications/components/shared/OverflowMenu.d.ts +4 -0
- package/react/components/notifications/components/shared/OverflowMenu.js +16 -2
- package/react/components/notifications/components/shared/OverflowMenu.js.map +1 -1
- package/react/components/notifications/components/shared/notificationCard/NotificationCardBodyShell.js +2 -1
- package/react/components/notifications/components/shared/notificationCard/NotificationCardBodyShell.js.map +1 -1
- package/react/components/notifications/components/shared/notificationCard/NotificationCardHeaderShell.js +2 -1
- package/react/components/notifications/components/shared/notificationCard/NotificationCardHeaderShell.js.map +1 -1
- package/react/components/notifications/components/views/CardView.js +8 -3
- package/react/components/notifications/components/views/CardView.js.map +1 -1
- package/react/components/notifications/components/views/ListView.js +11 -1
- package/react/components/notifications/components/views/ListView.js.map +1 -1
- package/react/components/notifications/notificationsContext.d.ts +4 -0
- package/react/components/notifications/notificationsContext.js +4 -0
- package/react/components/notifications/notificationsContext.js.map +1 -1
- package/react/components/notifications/types.d.ts +6 -0
- package/react/components/notifications/types.js.map +1 -1
- package/react/components/notifications/utils.d.ts +4 -0
- package/react/components/notifications/utils.js +4 -0
- package/react/components/notifications/utils.js.map +1 -1
- package/react/components/processMonitor/ProcessMonitor.d.ts +3 -0
- package/react/components/processMonitor/ProcessMonitor.js +21 -3
- package/react/components/processMonitor/ProcessMonitor.js.map +1 -1
- package/react/components/processMonitor/components/ChildWindow.d.ts +3 -0
- package/react/components/processMonitor/components/ChildWindow.js +5 -0
- package/react/components/processMonitor/components/ChildWindow.js.map +1 -1
- package/react/components/processMonitor/components/ListHeader.d.ts +5 -0
- package/react/components/processMonitor/components/ListHeader.js +7 -0
- package/react/components/processMonitor/components/ListHeader.js.map +1 -1
- package/react/components/processMonitor/components/ProcessStatistics.js +12 -3
- package/react/components/processMonitor/components/ProcessStatistics.js.map +1 -1
- package/react/components/processMonitor/constants.js +6 -0
- package/react/components/processMonitor/constants.js.map +1 -1
- package/react/components/processMonitor/helpers.d.ts +13 -0
- package/react/components/processMonitor/helpers.js +27 -6
- package/react/components/processMonitor/helpers.js.map +1 -1
- package/react/components/processMonitor/helpers.spec.js +7 -3
- package/react/components/processMonitor/helpers.spec.js.map +1 -1
- package/react/components/processMonitor/stores/ProcessMonitorStore.d.ts +39 -0
- package/react/components/processMonitor/stores/ProcessMonitorStore.js +50 -0
- package/react/components/processMonitor/stores/ProcessMonitorStore.js.map +1 -1
- package/react/components/quickComponentForm/QuickComponentForm.d.ts +3 -0
- package/react/components/quickComponentForm/QuickComponentForm.js +20 -0
- package/react/components/quickComponentForm/QuickComponentForm.js.map +1 -1
- package/react/components/quickComponentForm/quickComponent.css +1 -1
- package/react/components/sdd/AddApp.d.ts +7 -4
- package/react/components/sdd/AddApp.js +144 -34
- package/react/components/sdd/AddApp.js.map +1 -1
- package/react/components/sdd/AppEditAccess.d.ts +4 -3
- package/react/components/sdd/AppEditAccess.js +8 -0
- package/react/components/sdd/AppEditAccess.js.map +1 -1
- package/react/components/sdd/AppEditPage.d.ts +6 -4
- package/react/components/sdd/AppEditPage.js +205 -393
- package/react/components/sdd/AppEditPage.js.map +1 -1
- package/react/components/sdd/Appearance.css +1 -1
- package/react/components/sdd/Appearance.d.ts +2 -1
- package/react/components/sdd/Appearance.js +18 -7
- package/react/components/sdd/Appearance.js.map +1 -1
- package/react/components/sdd/Application.d.ts +5 -4
- package/react/components/sdd/Application.js +94 -44
- package/react/components/sdd/Application.js.map +1 -1
- package/react/components/sdd/Applications.d.ts +12 -11
- package/react/components/sdd/Applications.js +110 -15
- package/react/components/sdd/Applications.js.map +1 -1
- package/react/components/sdd/AssetsPage.css +3 -3
- package/react/components/sdd/Authentication.js +1 -6
- package/react/components/sdd/Authentication.js.map +1 -1
- package/react/components/sdd/AuthenticationProviderConfig.js +5 -3
- package/react/components/sdd/AuthenticationProviderConfig.js.map +1 -1
- package/react/components/sdd/EditPreload.d.ts +4 -3
- package/react/components/sdd/EditPreload.js +49 -22
- package/react/components/sdd/EditPreload.js.map +1 -1
- package/react/components/sdd/Export.d.ts +7 -6
- package/react/components/sdd/Export.js +4 -3
- package/react/components/sdd/Export.js.map +1 -1
- package/react/components/sdd/ExportCloud.js +4 -0
- package/react/components/sdd/ExportCloud.js.map +1 -1
- package/react/components/sdd/GettingStarted.js +3 -3
- package/react/components/sdd/GettingStarted.js.map +1 -1
- package/react/components/sdd/Navigation.js +28 -4
- package/react/components/sdd/Navigation.js.map +1 -1
- package/react/components/sdd/OptionalSettingsView.d.ts +6 -5
- package/react/components/sdd/OptionalSettingsView.js +2 -10
- package/react/components/sdd/OptionalSettingsView.js.map +1 -1
- package/react/components/sdd/ProjectErrors.js +1 -1
- package/react/components/sdd/ProjectErrors.js.map +1 -1
- package/react/components/sdd/Publish.js +4 -2
- package/react/components/sdd/Publish.js.map +1 -1
- package/react/components/sdd/PublishProgress.js +11 -1
- package/react/components/sdd/PublishProgress.js.map +1 -1
- package/react/components/sdd/SmartDesktopDesigner.d.ts +17 -16
- package/react/components/sdd/SmartDesktopDesigner.js +54 -34
- package/react/components/sdd/SmartDesktopDesigner.js.map +1 -1
- package/react/components/sdd/ThemePage.css +6 -23
- package/react/components/sdd/ThemePage.js +8 -5
- package/react/components/sdd/ThemePage.js.map +1 -1
- package/react/components/sdd/Themes.d.ts +2 -1
- package/react/components/sdd/Themes.js +4 -2
- package/react/components/sdd/Themes.js.map +1 -1
- package/react/components/sdd/Toolbar.d.ts +5 -4
- package/react/components/sdd/Toolbar.js +18 -9
- package/react/components/sdd/Toolbar.js.map +1 -1
- package/react/components/sdd/appEditPage/Behavior.d.ts +34 -0
- package/react/components/sdd/appEditPage/Behavior.js +134 -0
- package/react/components/sdd/appEditPage/Behavior.js.map +1 -0
- package/react/components/sdd/appEditPage/Component.d.ts +22 -0
- package/react/components/sdd/appEditPage/Component.js +76 -0
- package/react/components/sdd/appEditPage/Component.js.map +1 -0
- package/react/components/sdd/appEditPage/DebugToolkit.d.ts +9 -0
- package/react/components/sdd/appEditPage/DebugToolkit.js +20 -0
- package/react/components/sdd/appEditPage/DebugToolkit.js.map +1 -0
- package/react/components/sdd/appEditPage/Interop.d.ts +10 -0
- package/react/components/sdd/appEditPage/Interop.js +40 -0
- package/react/components/sdd/appEditPage/Interop.js.map +1 -0
- package/react/components/sdd/appEditPage/Position.d.ts +18 -0
- package/react/components/sdd/appEditPage/Position.js +72 -0
- package/react/components/sdd/appEditPage/Position.js.map +1 -0
- package/react/components/sdd/appEditPage/Preloads.d.ts +9 -0
- package/react/components/sdd/appEditPage/Preloads.js +16 -0
- package/react/components/sdd/appEditPage/Preloads.js.map +1 -0
- package/react/components/sdd/appEditPage/SelectConnect.d.ts +15 -0
- package/react/components/sdd/appEditPage/SelectConnect.js +28 -0
- package/react/components/sdd/appEditPage/SelectConnect.js.map +1 -0
- package/react/components/sdd/appEditPage/Workspace.d.ts +12 -0
- package/react/components/sdd/appEditPage/Workspace.js +30 -0
- package/react/components/sdd/appEditPage/Workspace.js.map +1 -0
- package/react/components/sdd/common/getCSSVars.js +7 -2
- package/react/components/sdd/common/getCSSVars.js.map +1 -1
- package/react/components/sdd/common/setPreloadDefaults.d.ts +1 -1
- package/react/components/sdd/common/setPreloadDefaults.js +9 -4
- package/react/components/sdd/common/setPreloadDefaults.js.map +1 -1
- package/react/components/sdd/common/views.js +7 -4
- package/react/components/sdd/common/views.js.map +1 -1
- package/react/components/sdd/css/addApp.css +65 -0
- package/react/components/sdd/css/appearance.css +6 -0
- package/react/components/sdd/css/applications.css +27 -34
- package/react/components/sdd/css/authentication.css +7 -6
- package/react/components/sdd/css/buttons.css +1 -1
- package/react/components/sdd/css/export.css +5 -3
- package/react/components/sdd/css/getting-started.css +2 -2
- package/react/components/sdd/css/nav.css +11 -14
- package/react/components/sdd/css/project-header.css +5 -7
- package/react/components/sdd/css/styles.css +29 -23
- package/react/components/sdd/css/views.css +4 -3
- package/react/components/sdd/fixtures/apps.js +12 -0
- package/react/components/sdd/fixtures/apps.js.map +1 -1
- package/react/components/sdd/fixtures/authenticationProps.js +15 -1
- package/react/components/sdd/fixtures/authenticationProps.js.map +1 -1
- package/react/components/sdd/fixtures/configTemplate.js +1 -0
- package/react/components/sdd/fixtures/configTemplate.js.map +1 -1
- package/react/components/sdd/fixtures/preloads.js +14 -12
- package/react/components/sdd/fixtures/preloads.js.map +1 -1
- package/react/components/sdd/fixtures/publishProgress.js +40 -0
- package/react/components/sdd/fixtures/publishProgress.js.map +1 -1
- package/react/components/sdd/sdd_helpers.d.ts +6 -0
- package/react/components/sdd/sdd_helpers.js +6 -0
- package/react/components/sdd/sdd_helpers.js.map +1 -1
- package/react/components/sdd/smartDesktopClient.d.ts +466 -0
- package/react/components/sdd/smartDesktopClient.js +906 -0
- package/react/components/sdd/smartDesktopClient.js.map +1 -0
- package/react/components/sdd/smartDesktopClient.spec.d.ts +1 -0
- package/react/components/sdd/smartDesktopClient.spec.js +64 -0
- package/react/components/sdd/smartDesktopClient.spec.js.map +1 -0
- package/react/components/sdd/stories/AddApp.stories.d.ts +11 -0
- package/react/components/sdd/stories/AddApp.stories.js +26 -0
- package/react/components/sdd/stories/AddApp.stories.js.map +1 -0
- package/react/components/sdd/stories/AppEditPage.stories.d.ts +5 -1
- package/react/components/sdd/stories/AppEditPage.stories.js +5 -0
- package/react/components/sdd/stories/AppEditPage.stories.js.map +1 -1
- package/react/components/sdd/stories/Appearance.stories.d.ts +1 -1
- package/react/components/sdd/stories/Appearance.stories.js +2 -0
- package/react/components/sdd/stories/Appearance.stories.js.map +1 -1
- package/react/components/sdd/stories/Authentication.stories.js +2 -16
- package/react/components/sdd/stories/Authentication.stories.js.map +1 -1
- package/react/components/sdd/stories/OptionalSettingsView.stories.js +1 -1
- package/react/components/sdd/stories/OptionalSettingsView.stories.js.map +1 -1
- package/react/components/sdd/stories/SmartDesktopDesigner.stories.d.ts +1 -1
- package/react/components/sdd/stories/SmartDesktopDesigner.stories.js +3 -0
- package/react/components/sdd/stories/SmartDesktopDesigner.stories.js.map +1 -1
- package/react/components/sdd/stories/Themes.stories.d.ts +1 -1
- package/react/components/sdd/stories/Themes.stories.js +1 -0
- package/react/components/sdd/stories/Themes.stories.js.map +1 -1
- package/react/components/sdd/tests/AddApp.spec.d.ts +1 -0
- package/react/components/sdd/tests/AddApp.spec.js +133 -0
- package/react/components/sdd/tests/AddApp.spec.js.map +1 -0
- package/react/components/sdd/tests/AppEditPage.spec.js +108 -23
- package/react/components/sdd/tests/AppEditPage.spec.js.map +1 -1
- package/react/components/sdd/tests/Application.spec.js +351 -369
- package/react/components/sdd/tests/Application.spec.js.map +1 -1
- package/react/components/sdd/tests/Applications.spec.d.ts +1 -1
- package/react/components/sdd/tests/Applications.spec.js +30 -50
- package/react/components/sdd/tests/Applications.spec.js.map +1 -1
- package/react/components/sdd/tests/Authentication.spec.js +8 -1
- package/react/components/sdd/tests/Authentication.spec.js.map +1 -1
- package/react/components/sdd/tests/ContentHeader.spec.js +2 -0
- package/react/components/sdd/tests/ContentHeader.spec.js.map +1 -1
- package/react/components/sdd/tests/EditPreload.spec.js +63 -7
- package/react/components/sdd/tests/EditPreload.spec.js.map +1 -1
- package/react/components/sdd/tests/Export.spec.js +8 -1
- package/react/components/sdd/tests/Export.spec.js.map +1 -1
- package/react/components/sdd/tests/ItemList.spec.js +4 -0
- package/react/components/sdd/tests/ItemList.spec.js.map +1 -1
- package/react/components/sdd/tests/Navigation.spec.js +2 -2
- package/react/components/sdd/tests/Navigation.spec.js.map +1 -1
- package/react/components/sdd/tests/OptionalSettingsView.spec.js +264 -0
- package/react/components/sdd/tests/OptionalSettingsView.spec.js.map +1 -1
- package/react/components/sdd/tests/ProjectErrors.spec.js +3 -1
- package/react/components/sdd/tests/ProjectErrors.spec.js.map +1 -1
- package/react/components/sdd/tests/SmartDesktopDesigner.spec.js +2 -2
- package/react/components/sdd/tests/SmartDesktopDesigner.spec.js.map +1 -1
- package/react/components/sdd/tests/Themes.spec.js +1 -1
- package/react/components/sdd/tests/Themes.spec.js.map +1 -1
- package/react/components/sdd/tests/Toolbar.spec.js +53 -0
- package/react/components/sdd/tests/Toolbar.spec.js.map +1 -1
- package/react/components/sdd/tests/a11y_helper.js +8 -0
- package/react/components/sdd/tests/a11y_helper.js.map +1 -1
- package/react/components/search/Highlight.d.ts +6 -0
- package/react/components/search/Highlight.js +19 -0
- package/react/components/search/Highlight.js.map +1 -1
- package/react/components/search/Highlight.stories.js +1 -1
- package/react/components/search/Highlight.stories.js.map +1 -1
- package/react/components/search/Search.js +1 -1
- package/react/components/search/Search.js.map +1 -1
- package/react/components/search/SearchBestMatch.d.ts +4 -0
- package/react/components/search/SearchBestMatch.js +11 -0
- package/react/components/search/SearchBestMatch.js.map +1 -1
- package/react/components/search/SearchInput.d.ts +5 -0
- package/react/components/search/SearchInput.js +6 -0
- package/react/components/search/SearchInput.js.map +1 -1
- package/react/components/search/SearchProviderResults.js +2 -0
- package/react/components/search/SearchProviderResults.js.map +1 -1
- package/react/components/search/SearchResult.d.ts +5 -0
- package/react/components/search/SearchResult.js +6 -0
- package/react/components/search/SearchResult.js.map +1 -1
- package/react/components/search/SearchResult.spec.d.ts +1 -0
- package/react/components/search/SearchResult.spec.js +46 -0
- package/react/components/search/SearchResult.spec.js.map +1 -0
- package/react/components/search/SearchResult.stories.d.ts +16 -0
- package/react/components/search/SearchResult.stories.js +113 -0
- package/react/components/search/SearchResult.stories.js.map +1 -0
- package/react/components/search/SearchResults.js +5 -1
- package/react/components/search/SearchResults.js.map +1 -1
- package/react/components/search/SearchResults.spec.d.ts +1 -0
- package/react/components/search/SearchResults.spec.js +35 -0
- package/react/components/search/SearchResults.spec.js.map +1 -0
- package/react/components/search/SearchResults.stories.d.ts +11 -0
- package/react/components/search/SearchResults.stories.js +458 -0
- package/react/components/search/SearchResults.stories.js.map +1 -0
- package/react/components/shared/Animate.d.ts +5 -0
- package/react/components/shared/Animate.js +12 -1
- package/react/components/shared/Animate.js.map +1 -1
- package/react/components/shared/DefaultDropdownButton.js +26 -6
- package/react/components/shared/DefaultDropdownButton.js.map +1 -1
- package/react/components/shared/Tag.d.ts +0 -4
- package/react/components/shared/Tag.js +4 -0
- package/react/components/shared/Tag.js.map +1 -1
- package/react/components/shared/TagsMenu.d.ts +6 -0
- package/react/components/shared/TagsMenu.js +7 -0
- package/react/components/shared/TagsMenu.js.map +1 -1
- package/react/components/shared/addProtocolToValidURL.d.ts +6 -0
- package/react/components/shared/addProtocolToValidURL.js +6 -0
- package/react/components/shared/addProtocolToValidURL.js.map +1 -1
- package/react/components/shared/openQuitConfirmationDialog.d.ts +1 -1
- package/react/components/shared/openQuitConfirmationDialog.js +4 -4
- package/react/components/shared/openQuitConfirmationDialog.js.map +1 -1
- package/react/components/shared/tests/DefaultDropdownButton.spec.js +12 -0
- package/react/components/shared/tests/DefaultDropdownButton.spec.js.map +1 -1
- package/react/components/shared/tests/addProtocolToValidURL.spec.js +1 -0
- package/react/components/shared/tests/addProtocolToValidURL.spec.js.map +1 -1
- package/react/components/shared/validateURL.d.ts +18 -0
- package/react/components/shared/validateURL.js +24 -5
- package/react/components/shared/validateURL.js.map +1 -1
- package/react/components/singleInputDialog/SingleInputDialog.css +1 -1
- package/react/components/singleInputDialog/SingleInputDialog.d.ts +3 -0
- package/react/components/singleInputDialog/SingleInputDialog.js +46 -0
- package/react/components/singleInputDialog/SingleInputDialog.js.map +1 -1
- package/react/components/singleInputDialog/SingleInputDialog.stories.js +2 -2
- package/react/components/singleInputDialog/SingleInputDialog.stories.js.map +1 -1
- package/react/components/smartDesktopDesigner/SmartDesktopDesigner.d.ts +1 -16
- package/react/components/smartDesktopDesigner/SmartDesktopDesigner.js +5 -3
- package/react/components/smartDesktopDesigner/SmartDesktopDesigner.js.map +1 -1
- package/react/components/system/System.d.ts +22 -0
- package/react/components/system/System.js +23 -1
- package/react/components/system/System.js.map +1 -1
- package/react/components/system/System.stories.js +1 -0
- package/react/components/system/System.stories.js.map +1 -1
- package/react/components/system/SystemTrayComponentShell.d.ts +6 -0
- package/react/components/system/SystemTrayComponentShell.js +9 -0
- package/react/components/system/SystemTrayComponentShell.js.map +1 -1
- package/react/components/toolbar/AutoArrange.d.ts +5 -0
- package/react/components/toolbar/AutoArrange.js +8 -1
- package/react/components/toolbar/AutoArrange.js.map +1 -1
- package/react/components/toolbar/AutoArrange.spec.js +10 -4
- package/react/components/toolbar/AutoArrange.spec.js.map +1 -1
- package/react/components/toolbar/AutoArrange.stories.js +1 -0
- package/react/components/toolbar/AutoArrange.stories.js.map +1 -1
- package/react/components/toolbar/DragHandle.d.ts +4 -0
- package/react/components/toolbar/DragHandle.js +11 -0
- package/react/components/toolbar/DragHandle.js.map +1 -1
- package/react/components/toolbar/DragHandle.spec.js +1 -0
- package/react/components/toolbar/DragHandle.spec.js.map +1 -1
- package/react/components/toolbar/DragHandle.stories.js +1 -0
- package/react/components/toolbar/DragHandle.stories.js.map +1 -1
- package/react/components/toolbar/MinimizeAll.d.ts +4 -0
- package/react/components/toolbar/MinimizeAll.js +7 -1
- package/react/components/toolbar/MinimizeAll.js.map +1 -1
- package/react/components/toolbar/MinimizeAll.spec.js +1 -0
- package/react/components/toolbar/MinimizeAll.spec.js.map +1 -1
- package/react/components/toolbar/MinimizeAll.stories.js +1 -0
- package/react/components/toolbar/MinimizeAll.stories.js.map +1 -1
- package/react/components/toolbar/NotificationControl.d.ts +5 -0
- package/react/components/toolbar/NotificationControl.js +8 -1
- package/react/components/toolbar/NotificationControl.js.map +1 -1
- package/react/components/toolbar/RevealAll.d.ts +4 -0
- package/react/components/toolbar/RevealAll.js +7 -1
- package/react/components/toolbar/RevealAll.js.map +1 -1
- package/react/components/toolbar/RevealAll.spec.js +1 -0
- package/react/components/toolbar/RevealAll.spec.js.map +1 -1
- package/react/components/toolbar/RevealAll.stories.js +1 -0
- package/react/components/toolbar/RevealAll.stories.js.map +1 -1
- package/react/components/toolbar/SddButton.d.ts +4 -0
- package/react/components/toolbar/SddButton.js +4 -0
- package/react/components/toolbar/SddButton.js.map +1 -1
- package/react/components/toolbar/ToolbarIcon.d.ts +4 -0
- package/react/components/toolbar/ToolbarIcon.js +6 -2
- package/react/components/toolbar/ToolbarIcon.js.map +1 -1
- package/react/components/toolbar/ToolbarSection.d.ts +8 -9
- package/react/components/toolbar/ToolbarSection.js +21 -7
- package/react/components/toolbar/ToolbarSection.js.map +1 -1
- package/react/components/toolbar/ToolbarShell.d.ts +5 -0
- package/react/components/toolbar/ToolbarShell.js +7 -0
- package/react/components/toolbar/ToolbarShell.js.map +1 -1
- package/react/components/toolbar/advancedAppLauncher/AdvancedAppLauncher.d.ts +16 -0
- package/react/components/toolbar/advancedAppLauncher/AdvancedAppLauncher.js +20 -0
- package/react/components/toolbar/advancedAppLauncher/AdvancedAppLauncher.js.map +1 -1
- package/react/components/toolbar/advancedAppLauncher/components/AddNewAppForm.d.ts +52 -0
- package/react/components/toolbar/advancedAppLauncher/components/AddNewAppForm.js +58 -0
- package/react/components/toolbar/advancedAppLauncher/components/AddNewAppForm.js.map +1 -1
- package/react/components/toolbar/advancedAppLauncher/components/AddNewFolder.d.ts +5 -0
- package/react/components/toolbar/advancedAppLauncher/components/AddNewFolder.js +5 -0
- package/react/components/toolbar/advancedAppLauncher/components/AddNewFolder.js.map +1 -1
- package/react/components/toolbar/advancedAppLauncher/components/AppActionsMenu.d.ts +27 -0
- package/react/components/toolbar/advancedAppLauncher/components/AppActionsMenu.js +49 -0
- package/react/components/toolbar/advancedAppLauncher/components/AppActionsMenu.js.map +1 -1
- package/react/components/toolbar/advancedAppLauncher/components/AppDefinition.d.ts +13 -0
- package/react/components/toolbar/advancedAppLauncher/components/AppDefinition.js +14 -0
- package/react/components/toolbar/advancedAppLauncher/components/AppDefinition.js.map +1 -1
- package/react/components/toolbar/advancedAppLauncher/components/Content.d.ts +5 -0
- package/react/components/toolbar/advancedAppLauncher/components/Content.js +19 -0
- package/react/components/toolbar/advancedAppLauncher/components/Content.js.map +1 -1
- package/react/components/toolbar/advancedAppLauncher/components/FilterSort.d.ts +4 -0
- package/react/components/toolbar/advancedAppLauncher/components/FilterSort.js +4 -0
- package/react/components/toolbar/advancedAppLauncher/components/FilterSort.js.map +1 -1
- package/react/components/toolbar/advancedAppLauncher/components/FoldersList.d.ts +16 -0
- package/react/components/toolbar/advancedAppLauncher/components/FoldersList.js +39 -0
- package/react/components/toolbar/advancedAppLauncher/components/FoldersList.js.map +1 -1
- package/react/components/toolbar/advancedAppLauncher/components/LeftNavBottomLinks.d.ts +4 -0
- package/react/components/toolbar/advancedAppLauncher/components/LeftNavBottomLinks.js +9 -0
- package/react/components/toolbar/advancedAppLauncher/components/LeftNavBottomLinks.js.map +1 -1
- package/react/components/toolbar/advancedAppLauncher/components/SearchBox.js +3 -0
- package/react/components/toolbar/advancedAppLauncher/components/SearchBox.js.map +1 -1
- package/react/components/toolbar/advancedAppLauncher/components/TagsMenu.d.ts +6 -0
- package/react/components/toolbar/advancedAppLauncher/components/TagsMenu.js +7 -0
- package/react/components/toolbar/advancedAppLauncher/components/TagsMenu.js.map +1 -1
- package/react/components/toolbar/advancedAppLauncher/components/ToggleFavoriteDropdown.d.ts +5 -0
- package/react/components/toolbar/advancedAppLauncher/components/ToggleFavoriteDropdown.js +5 -0
- package/react/components/toolbar/advancedAppLauncher/components/ToggleFavoriteDropdown.js.map +1 -1
- package/react/components/toolbar/advancedAppLauncher/modules/AppDirectory.d.ts +5 -0
- package/react/components/toolbar/advancedAppLauncher/modules/AppDirectory.js +5 -0
- package/react/components/toolbar/advancedAppLauncher/modules/AppDirectory.js.map +1 -1
- package/react/components/toolbar/advancedAppLauncher/modules/FDC3.d.ts +37 -0
- package/react/components/toolbar/advancedAppLauncher/modules/FDC3.js +40 -0
- package/react/components/toolbar/advancedAppLauncher/modules/FDC3.js.map +1 -1
- package/react/components/toolbar/advancedAppLauncher/stores/StoreActions.d.ts +3 -0
- package/react/components/toolbar/advancedAppLauncher/stores/StoreActions.js +83 -1
- package/react/components/toolbar/advancedAppLauncher/stores/StoreActions.js.map +1 -1
- package/react/components/toolbar/advancedAppLauncher/utils/sort-functions.d.ts +10 -0
- package/react/components/toolbar/advancedAppLauncher/utils/sort-functions.js +12 -3
- package/react/components/toolbar/advancedAppLauncher/utils/sort-functions.js.map +1 -1
- package/react/components/toolbar/appLauncher/AppLauncherMenu.d.ts +18 -0
- package/react/components/toolbar/appLauncher/AppLauncherMenu.js +20 -0
- package/react/components/toolbar/appLauncher/AppLauncherMenu.js.map +1 -1
- package/react/components/toolbar/appLauncher/StaticAppLauncherMenu.d.ts +9 -0
- package/react/components/toolbar/appLauncher/StaticAppLauncherMenu.js +12 -0
- package/react/components/toolbar/appLauncher/StaticAppLauncherMenu.js.map +1 -1
- package/react/components/toolbar/appLauncher/appLauncher.css +1 -1
- package/react/components/toolbar/appLauncher/components/componentList.d.ts +3 -0
- package/react/components/toolbar/appLauncher/components/componentList.js +17 -3
- package/react/components/toolbar/appLauncher/components/componentList.js.map +1 -1
- package/react/components/toolbar/appLauncher/stores/appLauncherStore.d.ts +6 -0
- package/react/components/toolbar/appLauncher/stores/appLauncherStore.js +26 -0
- package/react/components/toolbar/appLauncher/stores/appLauncherStore.js.map +1 -1
- package/react/components/toolbar/dashbar/Dashbar.js +91 -15
- package/react/components/toolbar/dashbar/Dashbar.js.map +1 -1
- package/react/components/toolbar/dashbar/DashbarItem.js +5 -0
- package/react/components/toolbar/dashbar/DashbarItem.js.map +1 -1
- package/react/components/toolbar/workspaceManagementMenu/WorkspaceManagementMenu.d.ts +8 -1
- package/react/components/toolbar/workspaceManagementMenu/WorkspaceManagementMenu.js +7 -0
- package/react/components/toolbar/workspaceManagementMenu/WorkspaceManagementMenu.js.map +1 -1
- package/react/components/toolbar/workspaceManagementMenu/components/Workspace.d.ts +17 -1
- package/react/components/toolbar/workspaceManagementMenu/components/Workspace.js +21 -1
- package/react/components/toolbar/workspaceManagementMenu/components/Workspace.js.map +1 -1
- package/react/components/toolbar/workspaceManagementMenu/components/WorkspaceActions.d.ts +26 -0
- package/react/components/toolbar/workspaceManagementMenu/components/WorkspaceActions.js +29 -0
- package/react/components/toolbar/workspaceManagementMenu/components/WorkspaceActions.js.map +1 -1
- package/react/components/toolbar/workspaceManagementMenu/components/WorkspaceList.d.ts +6 -1
- package/react/components/toolbar/workspaceManagementMenu/components/WorkspaceList.js +6 -0
- package/react/components/toolbar/workspaceManagementMenu/components/WorkspaceList.js.map +1 -1
- package/react/components/toolbar/workspaceManagementMenu/stores/workspaceManagementMenuStore.d.ts +78 -2
- package/react/components/toolbar/workspaceManagementMenu/stores/workspaceManagementMenuStore.js +191 -40
- package/react/components/toolbar/workspaceManagementMenu/stores/workspaceManagementMenuStore.js.map +1 -1
- package/react/components/toolbar/workspaceManagementMenu/workspaceManagementMenu.css +8 -18
- package/react/components/userPreferences/NotificationsPreferencesContext.d.ts +4 -0
- package/react/components/userPreferences/NotificationsPreferencesContext.js +4 -0
- package/react/components/userPreferences/NotificationsPreferencesContext.js.map +1 -1
- package/react/components/userPreferences/UserPreferenceTypes.d.ts +3 -0
- package/react/components/userPreferences/UserPreferences.d.ts +8 -0
- package/react/components/userPreferences/UserPreferences.js +8 -0
- package/react/components/userPreferences/UserPreferences.js.map +1 -1
- package/react/components/userPreferences/UserPreferencesBase.js +4 -0
- package/react/components/userPreferences/UserPreferencesBase.js.map +1 -1
- package/react/components/userPreferences/components/ContentSection.d.ts +5 -0
- package/react/components/userPreferences/components/ContentSection.js +1 -1
- package/react/components/userPreferences/components/ContentSection.js.map +1 -1
- package/react/components/userPreferences/components/LeftNav.d.ts +4 -0
- package/react/components/userPreferences/components/content/DashbarEditor.js +3 -0
- package/react/components/userPreferences/components/content/DashbarEditor.js.map +1 -1
- package/react/components/userPreferences/components/content/Notifications.js +3 -0
- package/react/components/userPreferences/components/content/Notifications.js.map +1 -1
- package/react/components/userPreferences/components/content/Workspaces.d.ts +14 -2
- package/react/components/userPreferences/components/content/Workspaces.js +78 -38
- package/react/components/userPreferences/components/content/Workspaces.js.map +1 -1
- package/react/components/userPreferences/components/content/notificationViews/NotificationsPreferencesHome.js +7 -3
- package/react/components/userPreferences/components/content/notificationViews/NotificationsPreferencesHome.js.map +1 -1
- package/react/components/userPreferences/components/content/notificationViews/NotificationsSourceTypes.js +3 -0
- package/react/components/userPreferences/components/content/notificationViews/NotificationsSourceTypes.js.map +1 -1
- package/react/components/userPreferences/components/content/notificationViews/NotificationsSourcesPreferences.js +3 -0
- package/react/components/userPreferences/components/content/notificationViews/NotificationsSourcesPreferences.js.map +1 -1
- package/react/components/userPreferences/components/general/ScheduledClose.js +26 -5
- package/react/components/userPreferences/components/general/ScheduledClose.js.map +1 -1
- package/react/components/userPreferences/components/workspaces/WorkspaceButton.js +1 -1
- package/react/components/userPreferences/components/workspaces/WorkspaceButton.js.map +1 -1
- package/react/components/userPreferences/components/workspaces/WorkspaceItem.d.ts +1 -1
- package/react/components/userPreferences/components/workspaces/WorkspaceItem.js +20 -10
- package/react/components/userPreferences/components/workspaces/WorkspaceItem.js.map +1 -1
- package/react/components/userPreferences/stores/UserPreferencesStore.d.ts +18 -1
- package/react/components/userPreferences/stores/UserPreferencesStore.js +35 -6
- package/react/components/userPreferences/stores/UserPreferencesStore.js.map +1 -1
- package/react/components/userPreferences/tests/LeftNav.spec.js +15 -1
- package/react/components/userPreferences/tests/LeftNav.spec.js.map +1 -1
- package/react/components/userPreferences/tests/NotificationsPreferencesHome.spec.js +1 -0
- package/react/components/userPreferences/tests/NotificationsPreferencesHome.spec.js.map +1 -1
- package/react/components/userPreferences/tests/UserPreferencesBase.spec.d.ts +1 -0
- package/react/components/userPreferences/tests/UserPreferencesBase.spec.js +42 -0
- package/react/components/userPreferences/tests/UserPreferencesBase.spec.js.map +1 -0
- package/react/components/userPreferences/tests/Workspace.spec.d.ts +1 -0
- package/react/components/userPreferences/tests/Workspace.spec.js +139 -0
- package/react/components/userPreferences/tests/Workspace.spec.js.map +1 -0
- package/react/components/windowTitleBar/WindowTitleBarShell.d.ts +130 -2
- package/react/components/windowTitleBar/WindowTitleBarShell.js +386 -27
- package/react/components/windowTitleBar/WindowTitleBarShell.js.map +1 -1
- package/react/components/windowTitleBar/components/center/Tab.d.ts +3 -0
- package/react/components/windowTitleBar/components/center/Tab.js +3 -0
- package/react/components/windowTitleBar/components/center/Tab.js.map +1 -1
- package/react/components/windowTitleBar/components/center/TabList.d.ts +90 -0
- package/react/components/windowTitleBar/components/center/TabList.js +170 -4
- package/react/components/windowTitleBar/components/center/TabList.js.map +1 -1
- package/react/components/windowTitleBar/components/left/LinkerButton.d.ts +9 -1
- package/react/components/windowTitleBar/components/left/LinkerButton.js +27 -5
- package/react/components/windowTitleBar/components/left/LinkerButton.js.map +1 -1
- package/react/components/windowTitleBar/components/left/LinkerButtonDeprecated.d.ts +47 -0
- package/react/components/windowTitleBar/components/left/LinkerButtonDeprecated.js +76 -1
- package/react/components/windowTitleBar/components/left/LinkerButtonDeprecated.js.map +1 -1
- package/react/components/windowTitleBar/components/left/LinkerGroups.d.ts +4 -0
- package/react/components/windowTitleBar/components/left/LinkerGroups.js +5 -0
- package/react/components/windowTitleBar/components/left/LinkerGroups.js.map +1 -1
- package/react/components/windowTitleBar/components/left/LinkerGroupsDeprecated.d.ts +18 -0
- package/react/components/windowTitleBar/components/left/LinkerGroupsDeprecated.js +49 -0
- package/react/components/windowTitleBar/components/left/LinkerGroupsDeprecated.js.map +1 -1
- package/react/components/windowTitleBar/components/left/ShareButton.d.ts +17 -0
- package/react/components/windowTitleBar/components/left/ShareButton.js +39 -0
- package/react/components/windowTitleBar/components/left/ShareButton.js.map +1 -1
- package/react/components/windowTitleBar/components/right/AlwaysOnTopButton.js +4 -0
- package/react/components/windowTitleBar/components/right/AlwaysOnTopButton.js.map +1 -1
- package/react/components/windowTitleBar/components/right/CloseButton.d.ts +27 -0
- package/react/components/windowTitleBar/components/right/CloseButton.js +27 -0
- package/react/components/windowTitleBar/components/right/CloseButton.js.map +1 -1
- package/react/components/windowTitleBar/components/right/GroupingButton.d.ts +37 -0
- package/react/components/windowTitleBar/components/right/GroupingButton.js +40 -0
- package/react/components/windowTitleBar/components/right/GroupingButton.js.map +1 -1
- package/react/components/windowTitleBar/components/right/MaximizeButton.d.ts +46 -0
- package/react/components/windowTitleBar/components/right/MaximizeButton.js +54 -0
- package/react/components/windowTitleBar/components/right/MaximizeButton.js.map +1 -1
- package/react/components/windowTitleBar/components/right/MinimizeButton.d.ts +26 -0
- package/react/components/windowTitleBar/components/right/MinimizeButton.js +26 -0
- package/react/components/windowTitleBar/components/right/MinimizeButton.js.map +1 -1
- package/react/components/windowTitleBar/components/windowTitle.d.ts +40 -0
- package/react/components/windowTitleBar/components/windowTitle.js +245 -48
- package/react/components/windowTitleBar/components/windowTitle.js.map +1 -1
- package/react/components/windowTitleBar/stores/windowTitleBarStore.d.ts +5 -0
- package/react/components/windowTitleBar/stores/windowTitleBarStore.js +81 -6
- package/react/components/windowTitleBar/stores/windowTitleBarStore.js.map +1 -1
- package/react/components/yesNoDialog/YesNoDialog.css +1 -1
- package/react/components/yesNoDialog/YesNoDialog.d.ts +3 -0
- package/react/components/yesNoDialog/YesNoDialog.js +64 -1
- package/react/components/yesNoDialog/YesNoDialog.js.map +1 -1
- package/react/components/yesNoDialog/YesNoDialog.spec.js +4 -0
- package/react/components/yesNoDialog/YesNoDialog.spec.js.map +1 -1
- package/react/components/yesNoDialog/YesNoDialog.stories.js +2 -2
- package/react/components/yesNoDialog/YesNoDialog.stories.js.map +1 -1
- package/react/components/yesNoDialog/timer.js +2 -0
- package/react/components/yesNoDialog/timer.js.map +1 -1
- package/react/enzymeSetup.js +10 -0
- package/react/enzymeSetup.js.map +1 -1
- package/react/hooks/useDashbar.js +10 -0
- package/react/hooks/useDashbar.js.map +1 -1
- package/react/hooks/useDeepEffect.d.ts +4 -0
- package/react/hooks/useDeepEffect.js +21 -0
- package/react/hooks/useDeepEffect.js.map +1 -1
- package/react/hooks/useFavorites.d.ts +15 -0
- package/react/hooks/useFavorites.js +3 -0
- package/react/hooks/useFavorites.js.map +1 -1
- package/react/hooks/useFavoritesShell.d.ts +4 -0
- package/react/hooks/useFavoritesShell.js +23 -0
- package/react/hooks/useFavoritesShell.js.map +1 -1
- package/react/hooks/useHotkey.d.ts +6 -0
- package/react/hooks/useHotkey.js +9 -0
- package/react/hooks/useHotkey.js.map +1 -1
- package/react/hooks/useLinker.js +14 -0
- package/react/hooks/useLinker.js.map +1 -1
- package/react/hooks/useMenu.d.ts +29 -0
- package/react/hooks/useMenu.js +12 -1
- package/react/hooks/useMenu.js.map +1 -1
- package/react/hooks/useNotifications.d.ts +44 -0
- package/react/hooks/useNotifications.js +104 -12
- package/react/hooks/useNotifications.js.map +1 -1
- package/react/hooks/useOutsideClickDetector.d.ts +3 -0
- package/react/hooks/useOutsideClickDetector.js +3 -0
- package/react/hooks/useOutsideClickDetector.js.map +1 -1
- package/react/hooks/usePubSub.d.ts +17 -0
- package/react/hooks/usePubSub.js +18 -0
- package/react/hooks/usePubSub.js.map +1 -1
- package/react/hooks/useSearch.d.ts +5 -0
- package/react/hooks/useSearch.js +30 -0
- package/react/hooks/useSearch.js.map +1 -1
- package/react/hooks/useToolbar.d.ts +1 -1
- package/react/hooks/useToolbar.js +54 -2
- package/react/hooks/useToolbar.js.map +1 -1
- package/react/reducers/favoriteReducer.d.ts +3 -0
- package/react/reducers/linkerReducer.d.ts +3 -0
- package/react/reducers/linkerReducer.js +4 -0
- package/react/reducers/linkerReducer.js.map +1 -1
- package/react/reducers/menuReducer.d.ts +28 -0
- package/react/reducers/menuReducer.js +34 -0
- package/react/reducers/menuReducer.js.map +1 -1
- package/react/reducers/rootReducer.d.ts +2 -2
- package/react/reducers/rootReducer.js +3 -0
- package/react/reducers/rootReducer.js.map +1 -1
- package/react/reducers/searchReducer.d.ts +7 -0
- package/react/reducers/searchReducer.js +6 -0
- package/react/reducers/searchReducer.js.map +1 -1
- package/react/reducers/workspaceReducer.js +1 -0
- package/react/reducers/workspaceReducer.js.map +1 -1
- package/react/store.d.ts +8 -4
- package/react/store.js +11 -0
- package/react/store.js.map +1 -1
- package/react/tsconfig.tsbuildinfo +1 -0
- package/react/types/fdc3.d.ts +2 -0
- package/react/types/linkerTypes.d.ts +13 -0
- package/react/types/linkerTypes.js +1 -0
- package/react/types/linkerTypes.js.map +1 -1
- package/react/types/smartDesktopDesignerTypes.d.ts +8 -0
- package/react/types/smartDesktopDesignerTypes.js.map +1 -1
- package/react/types/workspaceTypes.d.ts +8 -0
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"StoreActions.js","sourceRoot":"","sources":["../../../../../src/components/toolbar/advancedAppLauncher/stores/StoreActions.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,SAAS,EAAE,MAAM,QAAQ,CAAC;AACnC,OAAO,EAAE,QAAQ,EAAE,MAAM,iBAAiB,CAAC;AAC3C,OAAO,YAAY,MAAM,yBAAyB,CAAC;AACnD,OAAO,IAAI,MAAM,iBAAiB,CAAC;AACnC,OAAO,EAAE,cAAc,EAAE,MAAM,oBAAoB,CAAC;AAIpD,MAAM,KAAK,GAAG,OAAO,CAAC,OAAO,CAAC,CAAC;AAC/B,IAAI,UAAgB,CAAC;AACrB,IAAI,IAAS,CAAC;AACd,IAAI,YAAiB,CAAC;AAsCtB,eAAe;IACd,UAAU;IACV,MAAM;IACN,YAAY;IACZ,cAAc;IACd,mBAAmB;IACnB,YAAY;IACZ,YAAY;IACZ,SAAS;IACT,SAAS;IACT,cAAc;IACd,UAAU;IACV,cAAc;IACd,mBAAmB;IACnB,eAAe;IACf,eAAe;IACf,cAAc;IACd,UAAU;IACV,oBAAoB;IACpB,aAAa;IACb,aAAa;IACb,SAAS;IACT,MAAM;IACN,OAAO;IACP,MAAM;IACN,eAAe;IACf,YAAY;IACZ,cAAc;IACd,OAAO;IACP,qBAAqB;CACrB,CAAC;AAEF,IAAI,IAAI,GAAa,EAAE,CAAC;AACxB,MAAM,qBAAqB,GAAG,uBAAuB,CAAC;AACtD,MA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M,CAAC,IAAI,CAAC,gBAAgB,CAAQ,CAAC,CAAC;IAE1F,IAAI,CAAC,OAAO,CAAC,CAAC,GAAG,EAAE,EAAE;QACpB,IAAI,GAAG,IAAI,CAAC,MAAM,CAAC,GAAG,CAAC,IAAI,CAAC,CAAC;IAC9B,CAAC,CAAC,CAAC;IAEH,OAAO,IAAI,CAAC,MAAM,CAAC,CAAC,GAAG,EAAE,KAAK,EAAE,EAAE,CAAC,IAAI,CAAC,OAAO,CAAC,GAAG,CAAC,KAAK,KAAK,CAAC,CAAC;AACjE,CAAC;AAED,SAAS,MAAM,CAAC,GAAW;IAE1B,IAAI,CAAC,IAAI,CAAC,OAAO,CAAC,GAAG,CAAC,GAAG,CAAC,IAAI,IAAI,CAAC,IAAI,CAAC,IAAI,CAAC,GAAG,CAAC,CAAC;IAElD,SAAS,CAAC,oBAAoB,EAAE,IAAI,CAAC,IAAI,EAAE,GAAG,EAAE,GAAE,CAAC,CAAC,CAAC;AACtD,CAAC;AAED,SAAS,SAAS,CAAC,GAAW;IAE7B,IAAI,CAAC,IAAI,CAAC,MAAM,CAAC,IAAI,CAAC,IAAI,CAAC,OAAO,CAAC,GAAG,CAAC,EAAE,CAAC,CAAC,CAAC;IAE5C,SAAS,CAAC,oBAAoB,EAAE,IAAI,CAAC,IAAI,EAAE,GAAG,EAAE,GAAE,CAAC,CAAC,CAAC;AACtD,CAAC","sourcesContent":["/* eslint-disable @typescript-eslint/no-use-before-define */\nimport { findIndex } from \"lodash\";\nimport { getStore } from \"./LauncherStore\";\nimport AppDirectory from \"../modules/AppDirectory\";\nimport FDC3 from \"../modules/FDC3\";\nimport { iconFromConfig } from \"../../../icon/Icon\";\nimport { FoldersType, FolderAppType } from \"../../../../types/advancedAppLauncherTypes\";\nimport { StandardError } from \"@finsemble/finsemble-api/types/types\";\nimport sortFunctions from \"../utils/sort-functions\";\nconst async = require(\"async\");\nlet FDC3Client: FDC3;\nlet appd: any;\nlet appDEndpoint: any;\n\ntype ComponentDescriptor = Record<string, any>;\ntype ComponentList = Record<string, ComponentDescriptor>;\n\ntype AppsType = {\n\tappID: string;\n\ttags: string[];\n\tname: string;\n\turl: string;\n\ttype: string;\n\tcanDelete: boolean;\n\tdisplayName?: string;\n};\ntype ConfigType = {\n\tappID: string;\n\ticon: any;\n\tname: string;\n\tdisplayName: string;\n\tsource: string;\n\ttags: string[];\n};\ntype DataType = {\n\tfolders: FoldersType[\"folders\"];\n\tfoldersList: FoldersType[\"list\"];\n\tapps: {\n\t\t[field: string]: AppsType;\n\t};\n\ttags: string[];\n\tactiveFolder: string;\n\tfilterText: string;\n\tsortBy: keyof typeof sortFunctions;\n\tisFormVisible: boolean;\n\tconfigComponents: {\n\t\t[field: string]: ConfigType;\n\t};\n};\n\nexport default {\n\tinitialize,\n\taddApp,\n\taddNewFolder,\n\taddAppToFolder,\n\tremoveAppFromFolder,\n\trenameFolder,\n\tdeleteFolder,\n\tdeleteApp,\n\tdeleteTag,\n\treorderFolders,\n\tgetFolders,\n\tgetFoldersList,\n\tgetActiveFolderName,\n\tgetActiveFolder,\n\tgetSingleFolder,\n\tgetAllAppsTags,\n\tgetAllApps,\n\tgetAllAppsFromFolder,\n\tgetFormStatus,\n\tgetSearchText,\n\tgetSortBy,\n\taddTag,\n\tgetTags,\n\tgetApp,\n\tgetDragDisabled,\n\tgetConstants,\n\tfindAppByField,\n\tgetApps,\n\trefreshAppDefinitions,\n};\n\nlet data = <DataType>{};\nconst ADVANCED_APP_LAUNCHER = \"Advanced App Launcher\";\nconst NEW_FOLDER_NAME = \"New folder\";\n// returns names of default folders.\nfunction getConstants() {\n\tconst DASHBOARDS = \"Dashboards\";\n\tconst FAVORITES = \"Favorites\";\n\treturn { ADVANCED_APP_LAUNCHER, DASHBOARDS, FAVORITES };\n}\n\n// Add to here if you want to disable dragging on a folder.\nfunction getDragDisabled() {\n\tconst { DASHBOARDS, FAVORITES } = getConstants();\n\treturn [ADVANCED_APP_LAUNCHER, DASHBOARDS, FAVORITES];\n}\n\nfunction initialize(callback = Function.prototype) {\n\tFSBL.Clients.ConfigClient.getValue({ field: \"finsemble.appDirectoryEndpoint\" }, (_, appDirectoryEndpoint) => {\n\t\t// cache value globally to be used in the event that we need to fetch data for a given component.\n\t\tappDEndpoint = appDirectoryEndpoint;\n\t\tconst store = getStore();\n\t\tdata.folders = store?.values.appFolders.folders;\n\t\tdata.foldersList = store?.values.appFolders.list;\n\t\tvalidateFolderDataStructure();\n\t\tdata.apps = store?.values.appDefinitions;\n\t\tdata.tags = store?.values.activeLauncherTags;\n\t\tdata.activeFolder = store?.values.activeFolder;\n\t\tdata.filterText = store?.values.filterText;\n\t\tdata.sortBy = store?.values.sortBy;\n\t\tdata.isFormVisible = store?.values.isFormVisible;\n\t\tdata.configComponents = {};\n\n\t\t// Add listeners to keep our copy up to date\n\t\tstore?.addListener({ field: \"appFolders.folders\" }, (foldersErr, dt) => {\n\t\t\tdata.folders = dt.value;\n\t\t});\n\t\tstore?.addListener({ field: \"appFolders.list\" }, (folderListErr, dt) => (data.foldersList = dt.value));\n\t\tstore?.addListener({ field: \"appDefinitions\" }, (appDefinitionsErr, dt) => (data.apps = dt.value));\n\t\tstore?.addListener({ field: \"activeFolder\" }, (activeFolderErr, dt) => {\n\t\t\tdata.activeFolder = dt.value;\n\t\t});\n\t\tstore?.addListener({ field: \"isFormVisible\" }, (visibilityErr, dt) => (data.isFormVisible = dt.value));\n\t\tstore?.addListener({ field: \"sortBy\" }, (sortErr, dt) => (data.sortBy = dt.value));\n\t\tstore?.addListener({ field: \"activeLauncherTags\" }, (launcherTagsErr, dt) => (data.tags = dt.value));\n\t\tstore?.addListener({ field: \"filterText\" }, (filterTextErr, dt) => (data.filterText = dt.value));\n\n\t\tFSBL.Clients.RouterClient.subscribe(\"Launcher.update\", (err, response) => {\n\t\t\tFSBL.Clients.Logger.debug(\"list updated\", err, response);\n\t\t\tif (err) {\n\t\t\t\treturn console.error(err);\n\t\t\t}\n\t\t\trefreshAppDefinitions(response.data.componentList);\n\t\t});\n\n\t\t// @deprecate in favor of SystemManagerClient.waitForStartup()\n\t\tFSBL.Clients.RouterClient.subscribe(\"Finsemble.Service.State.launcherService\", (unsubscribeErr) => {\n\t\t\tif (unsubscribeErr) {\n\t\t\t\tFSBL.Clients.Logger.error(\n\t\t\t\t\t\"App Launcher encountered an error unsubscribing from the launcher service\",\n\t\t\t\t\tunsubscribeErr\n\t\t\t\t);\n\t\t\t}\n\n\t\t\tloadInstalledComponentsFromStore(() => {\n\t\t\t\t// We load our stored components(config driven) here\n\t\t\t\tloadInstalledConfigComponents(() => {\n\t\t\t\t\tupdateAppsInFolders(callback);\n\t\t\t\t});\n\t\t\t});\n\t\t});\n\t});\n}\n\n// This gets a specific app in FDC3 and returns the results\nfunction getApp(appID: string, cb = Function.prototype) {\n\tappd\n\t\t.get(appID)\n\t\t.then((app: any) => cb(null, app))\n\t\t.catch((err: StandardError) => cb(err));\n}\n/**\n * Ensures all 'apps' properties on folders conform\n * to the new structure (Array vs object)\n */\nfunction validateFolderDataStructure() {\n\tObject.keys(data.folders).forEach((folderName) => {\n\t\tconst folder = data.folders[folderName];\n\t\tif (!Array.isArray(folder.apps)) {\n\t\t\tconst warning =\n\t\t\t\t\"Application Launcher Persistent Store has data stored in deprecated format. Please check distributedStore configs\";\n\t\t\t// If the structure is wrong, notify the user in hopes that the foundation will be fixed\n\t\t\tFSBL.Clients.Logger.warn(warning);\n\t\t\tFSBL.UserNotification.alert(\"system\", \"ONCE-SINCE-STARTUP\", \"Distributed Store Type Mismatch\", warning);\n\t\t\tlet newApps: FolderAppType[] = [];\n\t\t\tObject.values(folder.apps).forEach((app: any) => {\n\t\t\t\tnewApps.push(app);\n\t\t\t});\n\t\t\tfolder.apps = newApps;\n\t\t}\n\t});\n\t_setFolders();\n}\n\n// Update apps in folders with updated config information\nfunction updateAppsInFolders(cb = Function.prototype) {\n\t// Loop through folders and update apps with new info\n\tconst { ADVANCED_APP_LAUNCHER: advancedAppLauncherFolderName } = getConstants();\n\tObject.keys(data.folders).forEach((folderName) => {\n\t\tif (folderName === advancedAppLauncherFolderName) return;\n\t\telse {\n\t\t\tconst folder = data.folders[folderName];\n\t\t\tObject.values(data.configComponents).forEach((configComp) => {\n\t\t\t\tlet index = -1;\n\t\t\t\tfolder.apps.forEach((folderApp, i) => {\n\t\t\t\t\tif (folderApp.appID.toString().trim() === configComp.appID.toString().trim()) {\n\t\t\t\t\t\tindex = i;\n\t\t\t\t\t}\n\t\t\t\t});\n\n\t\t\t\tif (index > -1) {\n\t\t\t\t\tdata.folders[folderName].apps.splice(index, 1, configComp);\n\t\t\t\t}\n\t\t\t});\n\t\t}\n\t});\n\t_setFolders(cb);\n}\n\n/**\n * Given a component config, will return tags, or an empty array.\n *\n * @param {*} componentConfig\n * @returns\n */\nfunction extractTagsFromFinsembleComponentConfig(componentConfig: ComponentDescriptor) {\n\tif (!componentConfig.foreign) return [];\n\tif (!componentConfig.foreign.components) return [];\n\tif (!componentConfig.foreign.components[\"App Launcher\"]) return [];\n\n\tconst { tags } = componentConfig.foreign.components[\"App Launcher\"];\n\n\tif (tags) {\n\t\tif (typeof tags === \"string\") {\n\t\t\treturn [tags];\n\t\t}\n\t\treturn tags;\n\t}\n\n\treturn [];\n}\n/**\n * Instantiates classes needed to interact with the appD server.\n * Only done when needed. If there are no components with source 'FDC3', this code will not execute.\n */\nfunction lazyLoadAppD() {\n\tif (!FDC3Client) FDC3Client = new FDC3({ url: appDEndpoint });\n\tif (!appd) appd = new AppDirectory(FDC3Client) as FDC3;\n}\n\n/**\n * Here we load apps from FDC3\n * @param {*} cb\n */\nfunction loadInstalledComponentsFromStore(cb = Function.prototype) {\n\tasync.map(\n\t\tObject.values(data.apps),\n\t\t(component: any, componentDone: any) => {\n\t\t\t// Load FDC3 components here\n\t\t\tif (component.source && component.source === \"FDC3\") {\n\t\t\t\tlazyLoadAppD();\n\t\t\t\t// get the app info so we can load it into the launcher\n\t\t\t\treturn getApp(component.appID, (err: StandardError) => {\n\t\t\t\t\tif (err) {\n\t\t\t\t\t\t// don't want to kill this;\n\t\t\t\t\t\tdeleteApp(component.appID);\n\t\t\t\t\t\tconsole.error(\"there was an error loading from FDC3\", component, err);\n\t\t\t\t\t}\n\t\t\t\t\treturn componentDone();\n\t\t\t\t});\n\t\t\t}\n\n\t\t\t// Assumption - component is always a user defined component\n\t\t\t// when testing I was never able to get any other component types in this method\n\t\t\tFSBL.Clients.LauncherClient.addUserDefinedComponent(component, (compAddErr) => {\n\t\t\t\tif (compAddErr) {\n\t\t\t\t\tconsole.warn(\"Failed to add new app:\", compAddErr);\n\t\t\t\t}\n\t\t\t\tcomponentDone(compAddErr);\n\t\t\t});\n\t\t},\n\t\t(err: StandardError) => {\n\t\t\tcb(err);\n\t\t}\n\t);\n}\n\n// We load our apps that were loaded from the config.\nfunction loadInstalledConfigComponents(cb = Function.prototype) {\n\t// Get the list of components from the launcher service\n\tFSBL.Clients.LauncherClient.getComponentList((err, componentList) => {\n\t\t/*\n\t\t * Update the folders under the \"App\" menu and delete any apps in the folder\n\t\t * that are no longer in the config and are not user defined components.\n\t\t */\n\t\trefreshAppDefinitions(componentList || {});\n\t\tcb();\n\t});\n}\n\nfunction getApps() {\n\treturn data.apps;\n}\n\nfunction refreshAppDefinitions(componentList: ComponentList) {\n\tconst componentTypeList = Object.keys(componentList);\n\n\tconst { folders } = data;\n\t// Get the user defined apps\n\tconst apps = Object.keys(data.apps);\n\tObject.keys(folders).forEach((folderName) => {\n\t\tfolders[folderName].apps.forEach((configDefinedApp, i) => {\n\t\t\tconst { name, appID } = configDefinedApp;\n\t\t\t// If the component is not in the config component list and is not a user defined component\n\t\t\tif (!componentTypeList.includes(name) && !apps.includes(appID)) {\n\t\t\t\t// Delete app from the folder\n\t\t\t\tfolders[folderName].apps.splice(i, 1);\n\t\t\t}\n\t\t});\n\t});\n\n\tcomponentTypeList.forEach((componentType) => {\n\t\tconst component = componentList?.[componentType];\n\t\tif (component && component.component) {\n\t\t\tconst launchableByUser = component?.foreign?.components?.[\"App Launcher\"]?.launchableByUser;\n\n\t\t\tconst displayName = component.component.displayName ?? componentType;\n\t\t\tconst iconObject = iconFromConfig(component?.foreign?.components?.Toolbar, displayName);\n\t\t\t// Make sure the app is launchable by user\n\t\t\tif (launchableByUser && !component.component.isUserDefined) {\n\t\t\t\tdata.configComponents[componentType] = {\n\t\t\t\t\tappID: componentType,\n\t\t\t\t\ticon: iconObject,\n\t\t\t\t\tname: componentType,\n\t\t\t\t\tdisplayName,\n\t\t\t\t\tsource: \"config\",\n\t\t\t\t\ttags: extractTagsFromFinsembleComponentConfig(component),\n\t\t\t\t};\n\t\t\t} else if (!launchableByUser && data.configComponents[componentType]) {\n\t\t\t\tdelete data.configComponents[componentType];\n\t\t\t}\n\t\t}\n\t});\n}\n\nfunction _setValue(field: string, value: any, cb: any) {\n\tgetStore()?.setValue(\n\t\t{\n\t\t\tfield: field,\n\t\t\tvalue: value,\n\t\t},\n\t\t(error) => {\n\t\t\tif (error) {\n\t\t\t\tFSBL.Clients.Logger.error(`Advanced App Launcher: Failed to save: ${field}:${value}`);\n\t\t\t} else {\n\t\t\t\tcb && cb();\n\t\t\t}\n\t\t}\n\t);\n}\n\nfunction _setFolders(cb = Function.prototype) {\n\t_setValue(\"appFolders.folders\", data.folders, (err: StandardError) => {\n\t\tif (err) {\n\t\t\tFSBL.Clients.Logger.error(`Advanced App Launcher: Failed to set folders: ${err}`);\n\t\t\treturn;\n\t\t}\n\n\t\tcb();\n\t});\n}\n\nfunction _findAppIndexInFolders(appID: string, folderName: string) {\n\treturn findIndex(data.folders[folderName].apps, (app) => app.appID === appID);\n}\n\nfunction getFolders() {\n\treturn data.folders;\n}\n\nfunction getFoldersList() {\n\treturn data.foldersList;\n}\n\nfunction getAllApps() {\n\treturn Object.assign({}, data.apps, data.configComponents);\n}\n\nfunction getFormStatus() {\n\treturn data.isFormVisible;\n}\n\nfunction getSingleFolder(folderName: string) {\n\treturn data.folders[folderName];\n}\n\nfunction reorderFolders(destIndex: number, srcIndex: number) {\n\t// There are two types of folders: Those that can be arranged, and those that cannot. We don't want to reorder the folders relative to the unorderable folders. Split them out, and then combine them after doing the filtering/swapping.\n\tconst dragDisabled = getDragDisabled();\n\tconst unorderableFolders = data.foldersList.filter((folderName) => dragDisabled.includes(folderName));\n\tconst orderableFolders = data.foldersList.filter((folderName) => !dragDisabled.includes(folderName));\n\tconst movedFolder = orderableFolders[destIndex];\n\tconst remainingItems = orderableFolders.filter((item, index) => index !== destIndex);\n\tdata.foldersList = [\n\t\t...unorderableFolders,\n\t\t...remainingItems.slice(0, srcIndex),\n\t\tmovedFolder,\n\t\t...remainingItems.slice(srcIndex),\n\t];\n\t_setValue(\"appFolders.list\", data.foldersList, () => {});\n\treturn data.foldersList;\n}\n\nfunction addApp(app = <AppsType>{}, cb: any) {\n\tconst appID = `${new Date().getTime()}`;\n\tconst folder = data.activeFolder;\n\tconst newAppData = {\n\t\tappID,\n\t\ttags: app.tags,\n\t\tname: app.name,\n\t\turl: app.url,\n\t\ttype: \"component\",\n\t\tcanDelete: true,\n\t};\n\n\t/**\n\t * Note, the advanced app launcher can currently only keep track of apps that\n\t * are added by itself. Apps added by the basic launcher, or any other means,\n\t * will not be detected. A reconciliation process would need to be added that\n\t * listens on the distributed store similar to how the basic app launcher works.\n\t *\n\t * FSBL.Clients.RouterClient.subscribe(\"Launcher.update\", (err, response) => {\n\t\t\tFSBL.Clients.Logger.debug(\"list updated\", err, response);\n\t\t\tif (err) {\n\t\t\t\treturn console.error(err);\n\t\t\t}\n\t\t\tself.filterComponents(response.data.componentList);\n\t\t});\n\t */\n\tFSBL.Clients.LauncherClient.addUserDefinedComponent(newAppData, (compAddErr) => {\n\t\tif (compAddErr) {\n\t\t\tcb({ code: \"failed_to_add_app\", message: compAddErr });\n\t\t\tconsole.warn(\"Failed to add new app:\", compAddErr);\n\t\t\treturn;\n\t\t}\n\t\tdata.apps[appID] = newAppData;\n\n\t\t// Add to ADVANCED_APP_LAUNCHER folder\n\t\tdata.folders[ADVANCED_APP_LAUNCHER].apps.push(newAppData);\n\n\t\t// Check if we need to add to another folder as well\n\t\tif (folder !== ADVANCED_APP_LAUNCHER) {\n\t\t\tdata.folders[folder].apps.push(newAppData);\n\t\t}\n\t\t// Save appDefinitions and then folders\n\t\t_setValue(\"appDefinitions\", data.apps, () => {\n\t\t\t_setFolders();\n\t\t\tcb && cb();\n\t\t});\n\t});\n}\n\nfunction deleteApp(appID: string) {\n\t// Delete app from any folder that has it\n\tfor (const key in data.folders) {\n\t\tconst appIndex = _findAppIndexInFolders(appID, key);\n\t\tdata.folders[key].apps.splice(appIndex, 1);\n\t}\n\n\t// Delete app from the apps list\n\tFSBL.Clients.LauncherClient.removeUserDefinedComponent(data.apps[appID], () => {\n\t\tdelete data.apps[appID];\n\t\t// Save appDefinitions and then folders\n\t\t_setValue(\"appDefinitions\", data.apps, () => {\n\t\t\t_setFolders();\n\t\t});\n\t});\n}\n\nfunction addNewFolder(name?: string) {\n\t// Each new folder is given a number, lets store them here\n\t// to get the highest one and then increment\n\t// result of this will be [0, 1, 2] etc\n\tconst newFoldersNums = [\n\t\t0,\n\t\t// Find folders that have a name of \"New folder\" or \"New folder #\"\n\t\t...data.foldersList\n\t\t\t.filter((folder) => folder.startsWith(NEW_FOLDER_NAME))\n\t\t\t.map((folder) => {\n\t\t\t\tconst numbers: any[] = folder.match(/\\d+/g) || [];\n\t\t\t\treturn Math.max(...numbers);\n\t\t\t}),\n\t];\n\tconst highestFolderNumber = Math.max(...newFoldersNums);\n\tconst folderName: string = name ?? `${NEW_FOLDER_NAME} ${highestFolderNumber + 1}`;\n\tconst newFolder = {\n\t\tdisableUserRemove: true,\n\t\ticon: \"ff-adp-hamburger\",\n\t\tcanEdit: true,\n\t\tcanDelete: true,\n\t\tapps: [],\n\t};\n\tdata.folders[folderName] = newFolder;\n\t_setFolders(() => {\n\t\t// Update folders order if adding was successful\n\t\tdata.foldersList.push(folderName);\n\t\t_setValue(\"appFolders.list\", data.foldersList, () => {});\n\t});\n}\n\nfunction deleteFolder(folderName: string) {\n\t// Check if user is trying to delete the active folder\n\tif (folderName === data.activeFolder) {\n\t\tdata.activeFolder = ADVANCED_APP_LAUNCHER;\n\t\t_setValue(\"activeFolder\", data.activeFolder, () => {});\n\t}\n\n\tdelete data.folders[folderName] &&\n\t\t_setFolders(() => {\n\t\t\t// Update the order of folders\n\t\t\tconst index = data.foldersList.indexOf(folderName);\n\t\t\tdata.foldersList.splice(index, 1);\n\t\t\t_setValue(\"appFolders.list\", data.foldersList, () => {});\n\t\t});\n}\n\nfunction renameFolder(oldName: string, newName: string) {\n\tlet indexOfOld = data.foldersList.findIndex((folderName) => folderName === oldName);\n\n\tif (indexOfOld > -1) {\n\t\tlet oldFolder = data.folders[oldName];\n\t\tdata.folders[newName] = oldFolder;\n\t\tdata.foldersList.splice(indexOfOld, 1, newName);\n\n\t\t_setFolders(() => {\n\t\t\t_setValue(\"appFolders.list\", data.foldersList, () => {});\n\n\t\t\tif (data.activeFolder === oldName) {\n\t\t\t\t_setValue(\"activeFolder\", newName, () => {});\n\t\t\t}\n\n\t\t\tdelete data.folders[oldName];\n\t\t});\n\t}\n}\n\nfunction addAppToFolder(folderName: string, app: FolderAppType) {\n\tconst appIndex = _findAppIndexInFolders(app.appID, folderName);\n\n\tif (appIndex < 0) {\n\t\tdata.folders[folderName].apps.push({\n\t\t\tname: app.name,\n\t\t\tdisplayName: app.displayName,\n\t\t\tappID: app.appID,\n\t\t});\n\t\t_setFolders();\n\t}\n}\n\nfunction removeAppFromFolder(folderName: string, app: FolderAppType) {\n\tconst appIndex = _findAppIndexInFolders(app.appID, folderName);\n\tdata.folders[folderName].apps.splice(appIndex, 1);\n\t_setFolders();\n}\n\nfunction getAllAppsFromFolder(folderName: string) {\n\treturn data.folders[folderName].apps;\n}\n\n/**\n * Given a field, search through FDC3 apps and apps pulled in via config and return that app.\n * */\nfunction findAppByField(field: keyof AppsType | keyof ConfigType, value: any) {\n\treturn (\n\t\tObject.values(data.apps).find((app) => (app ? (app as any)[field] === value : false)) ||\n\t\tObject.values(data.configComponents).find((app) => (app ? (app as any)[field] === value : false))\n\t);\n}\n\nfunction getActiveFolder() {\n\tconst folder = data.folders[data.activeFolder];\n\n\tif (!folder) {\n\t\tFSBL.Clients.Logger.error(`activeFolder:\"${data.activeFolder}\" not found! Defaulting to empty folder`);\n\t\treturn {\n\t\t\tname: data.activeFolder,\n\t\t\tapps: [],\n\t\t};\n\t}\n\n\tObject.values(folder.apps).forEach((app) => {\n\t\tconst appData = findAppByField(\"appID\", app.appID);\n\t\tif (!appData) {\n\t\t\tapp.tags = [];\n\t\t} else {\n\t\t\tapp.tags = appData.tags;\n\t\t}\n\t});\n\t// Need a name for the AppDefinition/AppActionsMenu rendering\n\tfolder.name = data.activeFolder;\n\treturn folder;\n}\n\nfunction getActiveFolderName() {\n\treturn data.activeFolder;\n}\n\nfunction getSearchText() {\n\treturn data.filterText;\n}\n\nfunction getSortBy() {\n\treturn data.sortBy;\n}\n\nfunction getTags() {\n\treturn data.tags;\n}\n\nfunction getAllAppsTags() {\n\tlet tags: any[] = [];\n\t// Pull tags from applications installed via FDC3 and the component config.\n\tconst apps = Object.values(data.apps).concat(Object.values(data.configComponents) as any);\n\n\tapps.forEach((app) => {\n\t\ttags = tags.concat(app.tags);\n\t});\n\t// return unique ones only\n\treturn tags.filter((tag, index) => tags.indexOf(tag) === index);\n}\n\nfunction addTag(tag: string) {\n\t// Push new tag to list\n\tdata.tags.indexOf(tag) < 0 && data.tags.push(tag);\n\t// Update tags in store\n\t_setValue(\"activeLauncherTags\", data.tags, () => {});\n}\n\nfunction deleteTag(tag: string) {\n\t// Push new tag to list\n\tdata.tags.splice(data.tags.indexOf(tag), 1);\n\t// Update tags in store\n\t_setValue(\"activeLauncherTags\", data.tags, () => {});\n}\n"]}
|
|
1
|
+
{"version":3,"file":"StoreActions.js","sourceRoot":"","sources":["../../../../../src/components/toolbar/advancedAppLauncher/stores/StoreActions.ts"],"names":[],"mappings":"AAAA,4DAA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-before-define */\nimport { findIndex } from \"lodash\";\nimport { getStore } from \"./LauncherStore\";\nimport AppDirectory from \"../modules/AppDirectory\";\nimport FDC3 from \"../modules/FDC3\";\nimport { iconFromConfig } from \"../../../icon/Icon\";\nimport { FoldersType, FolderAppType } from \"../../../../types/advancedAppLauncherTypes\";\nimport { StandardError } from \"@finsemble/finsemble-api/types/types\";\nimport sortFunctions from \"../utils/sort-functions\";\nconst async = require(\"async\");\nlet FDC3Client: FDC3;\nlet appd: any;\nlet appDEndpoint: any;\n\ntype ComponentDescriptor = Record<string, any>;\ntype ComponentList = Record<string, ComponentDescriptor>;\n\ntype AppsType = {\n\tappID: string;\n\ttags: string[];\n\tname: string;\n\turl: string;\n\ttype: string;\n\tcanDelete: boolean;\n\tdisplayName?: string;\n};\ntype ConfigType = {\n\tappID: string;\n\ticon: any;\n\tname: string;\n\tdisplayName: string;\n\tsource: string;\n\ttags: string[];\n};\ntype DataType = {\n\tfolders: FoldersType[\"folders\"];\n\tfoldersList: FoldersType[\"list\"];\n\tapps: {\n\t\t[field: string]: AppsType;\n\t};\n\ttags: string[];\n\tactiveFolder: string;\n\tfilterText: string;\n\tsortBy: keyof typeof sortFunctions;\n\tisFormVisible: boolean;\n\tconfigComponents: {\n\t\t[field: string]: ConfigType;\n\t};\n};\n\nexport default {\n\tinitialize,\n\taddApp,\n\taddNewFolder,\n\taddAppToFolder,\n\tremoveAppFromFolder,\n\trenameFolder,\n\tdeleteFolder,\n\tdeleteApp,\n\tdeleteTag,\n\treorderFolders,\n\tgetFolders,\n\tgetFoldersList,\n\tgetActiveFolderName,\n\tgetActiveFolder,\n\tgetSingleFolder,\n\tgetAllAppsTags,\n\tgetAllApps,\n\tgetAllAppsFromFolder,\n\tgetFormStatus,\n\tgetSearchText,\n\tgetSortBy,\n\taddTag,\n\tgetTags,\n\tgetApp,\n\tgetDragDisabled,\n\tgetConstants,\n\tfindAppByField,\n\tgetApps,\n\trefreshAppDefinitions,\n};\n\nlet data = <DataType>{};\nconst ADVANCED_APP_LAUNCHER = \"Advanced App Launcher\";\nconst NEW_FOLDER_NAME = \"New folder\";\n// returns names of default folders.\nfunction getConstants() {\n\tconst DASHBOARDS = \"Dashboards\";\n\tconst FAVORITES = \"Favorites\";\n\treturn { ADVANCED_APP_LAUNCHER, DASHBOARDS, FAVORITES };\n}\n\n// Add to here if you want to disable dragging on a folder.\nfunction getDragDisabled() {\n\tconst { DASHBOARDS, FAVORITES } = getConstants();\n\treturn [ADVANCED_APP_LAUNCHER, DASHBOARDS, FAVORITES];\n}\n\nfunction initialize(callback = Function.prototype) {\n\tFSBL.Clients.ConfigClient.getValue({ field: \"finsemble.appDirectoryEndpoint\" }, (_, appDirectoryEndpoint) => {\n\t\t// cache value globally to be used in the event that we need to fetch data for a given component.\n\t\tappDEndpoint = appDirectoryEndpoint;\n\t\tconst store = getStore();\n\t\tdata.folders = store?.values.appFolders.folders;\n\t\tdata.foldersList = store?.values.appFolders.list;\n\t\tvalidateFolderDataStructure();\n\t\tdata.apps = store?.values.appDefinitions;\n\t\tdata.tags = store?.values.activeLauncherTags;\n\t\tdata.activeFolder = store?.values.activeFolder;\n\t\tdata.filterText = store?.values.filterText;\n\t\tdata.sortBy = store?.values.sortBy;\n\t\tdata.isFormVisible = store?.values.isFormVisible;\n\t\tdata.configComponents = {};\n\n\t\t// Add listeners to keep our copy up to date\n\t\tstore?.addListener({ field: \"appFolders.folders\" }, (foldersErr, dt) => {\n\t\t\tdata.folders = dt.value;\n\t\t});\n\t\tstore?.addListener({ field: \"appFolders.list\" }, (folderListErr, dt) => (data.foldersList = dt.value));\n\t\tstore?.addListener({ field: \"appDefinitions\" }, (appDefinitionsErr, dt) => (data.apps = dt.value));\n\t\tstore?.addListener({ field: \"activeFolder\" }, (activeFolderErr, dt) => {\n\t\t\tdata.activeFolder = dt.value;\n\t\t});\n\t\tstore?.addListener({ field: \"isFormVisible\" }, (visibilityErr, dt) => (data.isFormVisible = dt.value));\n\t\tstore?.addListener({ field: \"sortBy\" }, (sortErr, dt) => (data.sortBy = dt.value));\n\t\tstore?.addListener({ field: \"activeLauncherTags\" }, (launcherTagsErr, dt) => (data.tags = dt.value));\n\t\tstore?.addListener({ field: \"filterText\" }, (filterTextErr, dt) => (data.filterText = dt.value));\n\n\t\tFSBL.Clients.RouterClient.subscribe(\"Launcher.update\", (err, response) => {\n\t\t\tFSBL.Clients.Logger.debug(\"list updated\", err, response);\n\t\t\tif (err) {\n\t\t\t\treturn console.error(err);\n\t\t\t}\n\t\t\trefreshAppDefinitions(response.data.componentList);\n\t\t});\n\n\t\t// @deprecate in favor of SystemManagerClient.waitForStartup()\n\t\tFSBL.Clients.RouterClient.subscribe(\"Finsemble.Service.State.launcherService\", (unsubscribeErr) => {\n\t\t\tif (unsubscribeErr) {\n\t\t\t\tFSBL.Clients.Logger.error(\n\t\t\t\t\t\"App Launcher encountered an error unsubscribing from the launcher service\",\n\t\t\t\t\tunsubscribeErr\n\t\t\t\t);\n\t\t\t}\n\n\t\t\tloadInstalledComponentsFromStore(() => {\n\t\t\t\t// We load our stored components(config driven) here\n\t\t\t\tloadInstalledConfigComponents(() => {\n\t\t\t\t\tupdateAppsInFolders(callback);\n\t\t\t\t});\n\t\t\t});\n\t\t});\n\t});\n}\n\n// This gets a specific app in FDC3 and returns the results\nfunction getApp(appID: string, cb = Function.prototype) {\n\tappd\n\t\t.get(appID)\n\t\t.then((app: any) => cb(null, app))\n\t\t.catch((err: StandardError) => cb(err));\n}\n/**\n * Ensures all 'apps' properties on folders conform\n * to the new structure (Array vs object)\n */\nfunction validateFolderDataStructure() {\n\tObject.keys(data.folders).forEach((folderName) => {\n\t\tconst folder = data.folders[folderName];\n\t\tif (!Array.isArray(folder.apps)) {\n\t\t\tconst warning =\n\t\t\t\t\"Application Launcher Persistent Store has data stored in deprecated format. Please check distributedStore configs\";\n\t\t\t// If the structure is wrong, notify the user in hopes that the foundation will be fixed\n\t\t\tFSBL.Clients.Logger.warn(warning);\n\t\t\tFSBL.UserNotification.alert(\"system\", \"ONCE-SINCE-STARTUP\", \"Distributed Store Type Mismatch\", warning);\n\t\t\tlet newApps: FolderAppType[] = [];\n\t\t\tObject.values(folder.apps).forEach((app: any) => {\n\t\t\t\tnewApps.push(app);\n\t\t\t});\n\t\t\tfolder.apps = newApps;\n\t\t}\n\t});\n\t_setFolders();\n}\n\n// Update apps in folders with updated config information\nfunction updateAppsInFolders(cb = Function.prototype) {\n\t// Loop through folders and update apps with new info\n\tconst { ADVANCED_APP_LAUNCHER: advancedAppLauncherFolderName } = getConstants();\n\tObject.keys(data.folders).forEach((folderName) => {\n\t\tif (folderName === advancedAppLauncherFolderName) return;\n\t\telse {\n\t\t\tconst folder = data.folders[folderName];\n\t\t\tObject.values(data.configComponents).forEach((configComp) => {\n\t\t\t\tlet index = -1;\n\t\t\t\tfolder.apps.forEach((folderApp, i) => {\n\t\t\t\t\tif (folderApp.appID.toString().trim() === configComp.appID.toString().trim()) {\n\t\t\t\t\t\tindex = i;\n\t\t\t\t\t}\n\t\t\t\t});\n\n\t\t\t\tif (index > -1) {\n\t\t\t\t\tdata.folders[folderName].apps.splice(index, 1, configComp);\n\t\t\t\t}\n\t\t\t});\n\t\t}\n\t});\n\t_setFolders(cb);\n}\n\n/**\n * Given a component config, will return tags, or an empty array.\n *\n * @param {*} componentConfig\n * @returns\n */\nfunction extractTagsFromFinsembleComponentConfig(componentConfig: ComponentDescriptor) {\n\tif (!componentConfig.foreign) return [];\n\tif (!componentConfig.foreign.components) return [];\n\tif (!componentConfig.foreign.components[\"App Launcher\"]) return [];\n\n\tconst { tags } = componentConfig.foreign.components[\"App Launcher\"];\n\n\tif (tags) {\n\t\tif (typeof tags === \"string\") {\n\t\t\treturn [tags];\n\t\t}\n\t\treturn tags;\n\t}\n\n\treturn [];\n}\n/**\n * Instantiates classes needed to interact with the appD server.\n * Only done when needed. If there are no components with source 'FDC3', this code will not execute.\n */\nfunction lazyLoadAppD() {\n\tif (!FDC3Client) FDC3Client = new FDC3({ url: appDEndpoint });\n\tif (!appd) appd = new AppDirectory(FDC3Client) as FDC3;\n}\n\n/**\n * Here we load apps from FDC3\n * @param {*} cb\n */\nfunction loadInstalledComponentsFromStore(cb = Function.prototype) {\n\tasync.map(\n\t\tObject.values(data.apps),\n\t\t(component: any, componentDone: any) => {\n\t\t\t// Load FDC3 components here\n\t\t\tif (component.source && component.source === \"FDC3\") {\n\t\t\t\tlazyLoadAppD();\n\t\t\t\t// get the app info so we can load it into the launcher\n\t\t\t\treturn getApp(component.appID, (err: StandardError) => {\n\t\t\t\t\tif (err) {\n\t\t\t\t\t\t// don't want to kill this;\n\t\t\t\t\t\tdeleteApp(component.appID);\n\t\t\t\t\t\tconsole.error(\"there was an error loading from FDC3\", component, err);\n\t\t\t\t\t}\n\t\t\t\t\treturn componentDone();\n\t\t\t\t});\n\t\t\t}\n\n\t\t\t// Assumption - component is always a user defined component\n\t\t\t// when testing I was never able to get any other component types in this method\n\t\t\tFSBL.Clients.LauncherClient.addUserDefinedComponent(component, (compAddErr) => {\n\t\t\t\tif (compAddErr) {\n\t\t\t\t\tconsole.warn(\"Failed to add new app:\", compAddErr);\n\t\t\t\t}\n\t\t\t\tcomponentDone(compAddErr);\n\t\t\t});\n\t\t},\n\t\t(err: StandardError) => {\n\t\t\tcb(err);\n\t\t}\n\t);\n}\n\n// We load our apps that were loaded from the config.\nfunction loadInstalledConfigComponents(cb = Function.prototype) {\n\t// Get the list of components from the launcher service\n\tFSBL.Clients.LauncherClient.getComponentList((err, componentList) => {\n\t\t/*\n\t\t * Update the folders under the \"App\" menu and delete any apps in the folder\n\t\t * that are no longer in the config and are not user defined components.\n\t\t */\n\t\trefreshAppDefinitions(componentList || {});\n\t\tcb();\n\t});\n}\n\nfunction getApps() {\n\treturn data.apps;\n}\n\nfunction refreshAppDefinitions(componentList: ComponentList) {\n\tconst componentTypeList = Object.keys(componentList);\n\n\tconst { folders } = data;\n\t// Get the user defined apps\n\tconst apps = Object.keys(data.apps);\n\tObject.keys(folders).forEach((folderName) => {\n\t\tfolders[folderName].apps.forEach((configDefinedApp, i) => {\n\t\t\tconst { name, appID } = configDefinedApp;\n\t\t\t// If the component is not in the config component list and is not a user defined component\n\t\t\tif (!componentTypeList.includes(name) && !apps.includes(appID)) {\n\t\t\t\t// Delete app from the folder\n\t\t\t\tfolders[folderName].apps.splice(i, 1);\n\t\t\t}\n\t\t});\n\t});\n\n\tcomponentTypeList.forEach((componentType) => {\n\t\tconst component = componentList?.[componentType];\n\t\tif (component && component.component) {\n\t\t\tconst launchableByUser = component?.foreign?.components?.[\"App Launcher\"]?.launchableByUser;\n\n\t\t\tconst displayName = component.component.displayName ?? componentType;\n\t\t\tconst iconObject = iconFromConfig(component?.foreign?.components?.Toolbar, displayName, component?.appDConfig);\n\t\t\t// Make sure the app is launchable by user\n\t\t\tif (launchableByUser && !component.component.isUserDefined) {\n\t\t\t\tdata.configComponents[componentType] = {\n\t\t\t\t\tappID: componentType,\n\t\t\t\t\ticon: iconObject,\n\t\t\t\t\tname: componentType,\n\t\t\t\t\tdisplayName,\n\t\t\t\t\tsource: \"config\",\n\t\t\t\t\ttags: extractTagsFromFinsembleComponentConfig(component),\n\t\t\t\t};\n\t\t\t} else if (!launchableByUser && data.configComponents[componentType]) {\n\t\t\t\tdelete data.configComponents[componentType];\n\t\t\t}\n\t\t}\n\t});\n}\n\nfunction _setValue(field: string, value: any, cb: any) {\n\tgetStore()?.setValue(\n\t\t{\n\t\t\tfield: field,\n\t\t\tvalue: value,\n\t\t},\n\t\t(error) => {\n\t\t\tif (error) {\n\t\t\t\tFSBL.Clients.Logger.error(`Advanced App Launcher: Failed to save: ${field}:${value}`);\n\t\t\t} else {\n\t\t\t\tcb && cb();\n\t\t\t}\n\t\t}\n\t);\n}\n\nfunction _setFolders(cb = Function.prototype) {\n\t_setValue(\"appFolders.folders\", data.folders, (err: StandardError) => {\n\t\tif (err) {\n\t\t\tFSBL.Clients.Logger.error(`Advanced App Launcher: Failed to set folders: ${err}`);\n\t\t\treturn;\n\t\t}\n\n\t\tcb();\n\t});\n}\n\nfunction _findAppIndexInFolders(appID: string, folderName: string) {\n\treturn findIndex(data.folders[folderName].apps, (app) => app.appID === appID);\n}\n\nfunction getFolders() {\n\treturn data.folders;\n}\n\nfunction getFoldersList() {\n\treturn data.foldersList;\n}\n\nfunction getAllApps() {\n\treturn Object.assign({}, data.apps, data.configComponents);\n}\n\nfunction getFormStatus() {\n\treturn data.isFormVisible;\n}\n\nfunction getSingleFolder(folderName: string) {\n\treturn data.folders[folderName];\n}\n\nfunction reorderFolders(destIndex: number, srcIndex: number) {\n\t// There are two types of folders: Those that can be arranged, and those that cannot. We don't want to reorder the folders relative to the unorderable folders. Split them out, and then combine them after doing the filtering/swapping.\n\tconst dragDisabled = getDragDisabled();\n\tconst unorderableFolders = data.foldersList.filter((folderName) => dragDisabled.includes(folderName));\n\tconst orderableFolders = data.foldersList.filter((folderName) => !dragDisabled.includes(folderName));\n\tconst movedFolder = orderableFolders[destIndex];\n\tconst remainingItems = orderableFolders.filter((item, index) => index !== destIndex);\n\tdata.foldersList = [\n\t\t...unorderableFolders,\n\t\t...remainingItems.slice(0, srcIndex),\n\t\tmovedFolder,\n\t\t...remainingItems.slice(srcIndex),\n\t];\n\t_setValue(\"appFolders.list\", data.foldersList, () => {});\n\treturn data.foldersList;\n}\n\nfunction addApp(app = <AppsType>{}, cb: any) {\n\tconst appID = `${new Date().getTime()}`;\n\tconst folder = data.activeFolder;\n\tconst newAppData = {\n\t\tappID,\n\t\ttags: app.tags,\n\t\tname: app.name,\n\t\turl: app.url,\n\t\ttype: \"component\",\n\t\tcanDelete: true,\n\t};\n\n\t/**\n\t * Note, the advanced app launcher can currently only keep track of apps that\n\t * are added by itself. Apps added by the basic launcher, or any other means,\n\t * will not be detected. A reconciliation process would need to be added that\n\t * listens on the distributed store similar to how the basic app launcher works.\n\t *\n\t * FSBL.Clients.RouterClient.subscribe(\"Launcher.update\", (err, response) => {\n\t\t\tFSBL.Clients.Logger.debug(\"list updated\", err, response);\n\t\t\tif (err) {\n\t\t\t\treturn console.error(err);\n\t\t\t}\n\t\t\tself.filterComponents(response.data.componentList);\n\t\t});\n\t */\n\tFSBL.Clients.LauncherClient.addUserDefinedComponent(newAppData, (compAddErr) => {\n\t\tif (compAddErr) {\n\t\t\tcb({ code: \"failed_to_add_app\", message: compAddErr });\n\t\t\tconsole.warn(\"Failed to add new app:\", compAddErr);\n\t\t\treturn;\n\t\t}\n\t\tdata.apps[appID] = newAppData;\n\n\t\t// Add to ADVANCED_APP_LAUNCHER folder\n\t\tdata.folders[ADVANCED_APP_LAUNCHER].apps.push(newAppData);\n\n\t\t// Check if we need to add to another folder as well\n\t\tif (folder !== ADVANCED_APP_LAUNCHER) {\n\t\t\tdata.folders[folder].apps.push(newAppData);\n\t\t}\n\t\t// Save appDefinitions and then folders\n\t\t_setValue(\"appDefinitions\", data.apps, () => {\n\t\t\t_setFolders();\n\t\t\tcb && cb();\n\t\t});\n\t});\n}\n\nfunction deleteApp(appID: string) {\n\t// Delete app from any folder that has it\n\tfor (const key in data.folders) {\n\t\tconst appIndex = _findAppIndexInFolders(appID, key);\n\t\tdata.folders[key].apps.splice(appIndex, 1);\n\t}\n\n\t// Delete app from the apps list\n\tFSBL.Clients.LauncherClient.removeUserDefinedComponent(data.apps[appID], () => {\n\t\tdelete data.apps[appID];\n\t\t// Save appDefinitions and then folders\n\t\t_setValue(\"appDefinitions\", data.apps, () => {\n\t\t\t_setFolders();\n\t\t});\n\t});\n}\n\nfunction addNewFolder(name?: string) {\n\t// Each new folder is given a number, lets store them here\n\t// to get the highest one and then increment\n\t// result of this will be [0, 1, 2] etc\n\tconst newFoldersNums = [\n\t\t0,\n\t\t// Find folders that have a name of \"New folder\" or \"New folder #\"\n\t\t...data.foldersList\n\t\t\t.filter((folder) => folder.startsWith(NEW_FOLDER_NAME))\n\t\t\t.map((folder) => {\n\t\t\t\tconst numbers: any[] = folder.match(/\\d+/g) || [];\n\t\t\t\treturn Math.max(...numbers);\n\t\t\t}),\n\t];\n\tconst highestFolderNumber = Math.max(...newFoldersNums);\n\tconst folderName: string = name ?? `${NEW_FOLDER_NAME} ${highestFolderNumber + 1}`;\n\tconst newFolder = {\n\t\tdisableUserRemove: true,\n\t\ticon: \"ff-adp-hamburger\",\n\t\tcanEdit: true,\n\t\tcanDelete: true,\n\t\tapps: [],\n\t};\n\tdata.folders[folderName] = newFolder;\n\t_setFolders(() => {\n\t\t// Update folders order if adding was successful\n\t\tdata.foldersList.push(folderName);\n\t\t_setValue(\"appFolders.list\", data.foldersList, () => {});\n\t});\n}\n\nfunction deleteFolder(folderName: string) {\n\t// Check if user is trying to delete the active folder\n\tif (folderName === data.activeFolder) {\n\t\tdata.activeFolder = ADVANCED_APP_LAUNCHER;\n\t\t_setValue(\"activeFolder\", data.activeFolder, () => {});\n\t}\n\n\tdelete data.folders[folderName] &&\n\t\t_setFolders(() => {\n\t\t\t// Update the order of folders\n\t\t\tconst index = data.foldersList.indexOf(folderName);\n\t\t\tdata.foldersList.splice(index, 1);\n\t\t\t_setValue(\"appFolders.list\", data.foldersList, () => {});\n\t\t});\n}\n\nfunction renameFolder(oldName: string, newName: string) {\n\tlet indexOfOld = data.foldersList.findIndex((folderName) => folderName === oldName);\n\n\tif (indexOfOld > -1) {\n\t\tlet oldFolder = data.folders[oldName];\n\t\tdata.folders[newName] = oldFolder;\n\t\tdata.foldersList.splice(indexOfOld, 1, newName);\n\n\t\t_setFolders(() => {\n\t\t\t_setValue(\"appFolders.list\", data.foldersList, () => {});\n\n\t\t\tif (data.activeFolder === oldName) {\n\t\t\t\t_setValue(\"activeFolder\", newName, () => {});\n\t\t\t}\n\n\t\t\tdelete data.folders[oldName];\n\t\t});\n\t}\n}\n\nfunction addAppToFolder(folderName: string, app: FolderAppType) {\n\tconst appIndex = _findAppIndexInFolders(app.appID, folderName);\n\n\tif (appIndex < 0) {\n\t\tdata.folders[folderName].apps.push({\n\t\t\tname: app.name,\n\t\t\tdisplayName: app.displayName,\n\t\t\tappID: app.appID,\n\t\t});\n\t\t_setFolders();\n\t}\n}\n\nfunction removeAppFromFolder(folderName: string, app: FolderAppType) {\n\tconst appIndex = _findAppIndexInFolders(app.appID, folderName);\n\tdata.folders[folderName].apps.splice(appIndex, 1);\n\t_setFolders();\n}\n\nfunction getAllAppsFromFolder(folderName: string) {\n\treturn data.folders[folderName].apps;\n}\n\n/**\n * Given a field, search through FDC3 apps and apps pulled in via config and return that app.\n * */\nfunction findAppByField(field: keyof AppsType | keyof ConfigType, value: any) {\n\treturn (\n\t\tObject.values(data.apps).find((app) => (app ? (app as any)[field] === value : false)) ||\n\t\tObject.values(data.configComponents).find((app) => (app ? (app as any)[field] === value : false))\n\t);\n}\n\nfunction getActiveFolder() {\n\tconst folder = data.folders[data.activeFolder];\n\n\tif (!folder) {\n\t\tFSBL.Clients.Logger.error(`activeFolder:\"${data.activeFolder}\" not found! Defaulting to empty folder`);\n\t\treturn {\n\t\t\tname: data.activeFolder,\n\t\t\tapps: [],\n\t\t};\n\t}\n\n\tObject.values(folder.apps).forEach((app) => {\n\t\tconst appData = findAppByField(\"appID\", app.appID);\n\t\tif (!appData) {\n\t\t\tapp.tags = [];\n\t\t} else {\n\t\t\tapp.tags = appData.tags;\n\t\t}\n\t});\n\t// Need a name for the AppDefinition/AppActionsMenu rendering\n\tfolder.name = data.activeFolder;\n\treturn folder;\n}\n\nfunction getActiveFolderName() {\n\treturn data.activeFolder;\n}\n\nfunction getSearchText() {\n\treturn data.filterText;\n}\n\nfunction getSortBy() {\n\treturn data.sortBy;\n}\n\nfunction getTags() {\n\treturn data.tags;\n}\n\nfunction getAllAppsTags() {\n\tlet tags: any[] = [];\n\t// Pull tags from applications installed via FDC3 and the component config.\n\tconst apps = Object.values(data.apps).concat(Object.values(data.configComponents) as any);\n\n\tapps.forEach((app) => {\n\t\ttags = tags.concat(app.tags);\n\t});\n\t// return unique ones only\n\treturn tags.filter((tag, index) => tags.indexOf(tag) === index);\n}\n\nfunction addTag(tag: string) {\n\t// Push new tag to list\n\tdata.tags.indexOf(tag) < 0 && data.tags.push(tag);\n\t// Update tags in store\n\t_setValue(\"activeLauncherTags\", data.tags, () => {});\n}\n\nfunction deleteTag(tag: string) {\n\t// Push new tag to list\n\tdata.tags.splice(data.tags.indexOf(tag), 1);\n\t// Update tags in store\n\t_setValue(\"activeLauncherTags\", data.tags, () => {});\n}\n"]}
|
|
@@ -2,7 +2,17 @@ import { FolderAppType } from "../../../../types/advancedAppLauncherTypes";
|
|
|
2
2
|
export declare const findAppIndexInFolder: (appID: FolderAppType["appID"], folderName: string) => number;
|
|
3
3
|
export declare const isAppInFavorites: (appID: FolderAppType["appID"]) => boolean;
|
|
4
4
|
declare const _default: {
|
|
5
|
+
/**
|
|
6
|
+
* Sorts list by name alphabetically
|
|
7
|
+
*/
|
|
5
8
|
Alphabetical: (list: FolderAppType[]) => FolderAppType[];
|
|
9
|
+
/**
|
|
10
|
+
* Sorts a list of application by Favorites.
|
|
11
|
+
* It gets a list of apps from Favorites folder
|
|
12
|
+
* then in the sort function, it checks where a, b apps
|
|
13
|
+
* are in favorite folder or not, giving a lower index
|
|
14
|
+
* for apps that are in Favorite folder
|
|
15
|
+
*/
|
|
6
16
|
Favorites: (list: FolderAppType[]) => FolderAppType[];
|
|
7
17
|
};
|
|
8
18
|
export default _default;
|
|
@@ -6,15 +6,24 @@ export const findAppIndexInFolder = (appID, folderName) => {
|
|
|
6
6
|
};
|
|
7
7
|
export const isAppInFavorites = (appID) => {
|
|
8
8
|
const index = findAppIndexInFolder(appID, "Favorites");
|
|
9
|
-
|
|
10
|
-
return false;
|
|
11
|
-
return true;
|
|
9
|
+
return index >= 0;
|
|
12
10
|
};
|
|
13
11
|
export default {
|
|
12
|
+
/**
|
|
13
|
+
* Sorts list by name alphabetically
|
|
14
|
+
*/
|
|
14
15
|
Alphabetical: (list) => list.sort((a, b) => a.name.localeCompare(b.name)),
|
|
16
|
+
/**
|
|
17
|
+
* Sorts a list of application by Favorites.
|
|
18
|
+
* It gets a list of apps from Favorites folder
|
|
19
|
+
* then in the sort function, it checks where a, b apps
|
|
20
|
+
* are in favorite folder or not, giving a lower index
|
|
21
|
+
* for apps that are in Favorite folder
|
|
22
|
+
*/
|
|
15
23
|
Favorites: (list) => list.sort((a, b) => {
|
|
16
24
|
const aInFavorites = isAppInFavorites(a.appID);
|
|
17
25
|
const bInFavorites = isAppInFavorites(b.appID);
|
|
26
|
+
// a component being in favorites means it is "less than" another component not in favorites, so return -1
|
|
18
27
|
if (aInFavorites && !bInFavorites) {
|
|
19
28
|
return -1;
|
|
20
29
|
}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"sort-functions.js","sourceRoot":"","sources":["../../../../../src/components/toolbar/advancedAppLauncher/utils/sort-functions.ts"],"names":[],"mappings":"AAAA,OAAO,YAAY,MAAM,wBAAwB,CAAC;AAClD,OAAO,EAAE,SAAS,EAAE,MAAM,QAAQ,CAAC;AAGnC,MAAM,CAAC,MAAM,oBAAoB,GAAG,CAAC,KAA6B,EAAE,UAAkB,EAAE,EAAE;IACzF,MAAM,MAAM,GAAG,YAAY,CAAC,eAAe,CAAC,UAAU,CAAC,CAAC;IACxD,OAAO,SAAS,CAAC,MAAM,CAAC,IAAI,EAAE,CAAC,GAAkB,EAAE,EAAE,CAAC,GAAG,CAAC,KAAK,KAAK,KAAK,CAAC,CAAC;AAC5E,CAAC,CAAC;AAEF,MAAM,CAAC,MAAM,gBAAgB,GAAG,CAAC,KAA6B,EAAE,EAAE;IACjE,MAAM,KAAK,GAAG,oBAAoB,CAAC,KAAK,EAAE,WAAW,CAAC,CAAC;IAEvD,
|
|
1
|
+
{"version":3,"file":"sort-functions.js","sourceRoot":"","sources":["../../../../../src/components/toolbar/advancedAppLauncher/utils/sort-functions.ts"],"names":[],"mappings":"AAAA,OAAO,YAAY,MAAM,wBAAwB,CAAC;AAClD,OAAO,EAAE,SAAS,EAAE,MAAM,QAAQ,CAAC;AAGnC,MAAM,CAAC,MAAM,oBAAoB,GAAG,C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{ FolderAppType } from \"../../../../types/advancedAppLauncherTypes\";\n\nexport const findAppIndexInFolder = (appID: FolderAppType[\"appID\"], folderName: string) => {\n\tconst folder = storeActions.getSingleFolder(folderName);\n\treturn findIndex(folder.apps, (app: FolderAppType) => app.appID === appID);\n};\n\nexport const isAppInFavorites = (appID: FolderAppType[\"appID\"]) => {\n\tconst index = findAppIndexInFolder(appID, \"Favorites\");\n\n\treturn index >= 0;\n};\n\nexport default {\n\t/**\n\t * Sorts list by name alphabetically\n\t */\n\tAlphabetical: (list: FolderAppType[]) => list.sort((a, b) => a.name.localeCompare(b.name)),\n\n\t/**\n\t * Sorts a list of application by Favorites.\n\t * It gets a list of apps from Favorites folder\n\t * then in the sort function, it checks where a, b apps\n\t * are in favorite folder or not, giving a lower index\n\t * for apps that are in Favorite folder\n\t */\n\tFavorites: (list: FolderAppType[]) =>\n\t\tlist.sort((a, b) => {\n\t\t\tconst aInFavorites = isAppInFavorites(a.appID);\n\t\t\tconst bInFavorites = isAppInFavorites(b.appID);\n\t\t\t// a component being in favorites means it is \"less than\" another component not in favorites, so return -1\n\t\t\tif (aInFavorites && !bInFavorites) {\n\t\t\t\treturn -1;\n\t\t\t} else if (!aInFavorites && bInFavorites) {\n\t\t\t\treturn 1;\n\t\t\t}\n\t\t\treturn a.name.localeCompare(b.name);\n\t\t}),\n};\n"]}
|
|
@@ -6,5 +6,23 @@ declare type AppLauncherMenuType = MenuProps & {
|
|
|
6
6
|
suppressFavorites?: boolean;
|
|
7
7
|
dynamic?: boolean;
|
|
8
8
|
};
|
|
9
|
+
/**
|
|
10
|
+
* The menu, or collection of menus, that lists all configured Finsemble applications, and provides
|
|
11
|
+
* the ability to launch any listed app.
|
|
12
|
+
*
|
|
13
|
+
* @param {boolean} [enableQuickComponents=false] DEPRECATED: Set to true to allow users to create their own components
|
|
14
|
+
* @param {string} [title] The title of the menu that appears in the menu's <MenuToggle> button, as viewed in the toolbar. Can be string or any ReactNode.
|
|
15
|
+
* @param {string[]} [componentFilter] Custom list of menu items to display
|
|
16
|
+
* @param {boolean} [suppressFavorites=false]
|
|
17
|
+
* @param {boolean} [dynamic=false] If dynamic=true, get list of menus from manifest, as well as listening for updates to list
|
|
18
|
+
* @param {string} [className] - Custom body class for the menu contents. These classes will be set on the <body> tag for the Menu's drop down window.
|
|
19
|
+
* @param {string} [id] - Unique ID for the menu. Defaults to a random string.
|
|
20
|
+
* @param {number} [maxHeight=Infinity] - Maximum height of the menu.
|
|
21
|
+
* @param {number} [minHeight] - Minimum height of the menu
|
|
22
|
+
* @param {array} [openHotkey] - A hotkey combination to open the menu.
|
|
23
|
+
* @param {array} [closeHotkey=["escape"] ] - A hotkey combination to close the menu. Defaults to ["escape"].
|
|
24
|
+
* @param {number} [width=180] - Custom width for the menu.
|
|
25
|
+
* @param {number} [height] - Custom height for the menu. If not set then the height will be automatically calculated based on the content height and available monitor space.
|
|
26
|
+
*/
|
|
9
27
|
export declare const AppLauncherMenu: (props: AppLauncherMenuType) => JSX.Element;
|
|
10
28
|
export {};
|
|
@@ -1,5 +1,23 @@
|
|
|
1
1
|
import React, { useEffect, useState } from "react";
|
|
2
2
|
import { StaticAppLauncherMenu } from "./StaticAppLauncherMenu";
|
|
3
|
+
/**
|
|
4
|
+
* The menu, or collection of menus, that lists all configured Finsemble applications, and provides
|
|
5
|
+
* the ability to launch any listed app.
|
|
6
|
+
*
|
|
7
|
+
* @param {boolean} [enableQuickComponents=false] DEPRECATED: Set to true to allow users to create their own components
|
|
8
|
+
* @param {string} [title] The title of the menu that appears in the menu's <MenuToggle> button, as viewed in the toolbar. Can be string or any ReactNode.
|
|
9
|
+
* @param {string[]} [componentFilter] Custom list of menu items to display
|
|
10
|
+
* @param {boolean} [suppressFavorites=false]
|
|
11
|
+
* @param {boolean} [dynamic=false] If dynamic=true, get list of menus from manifest, as well as listening for updates to list
|
|
12
|
+
* @param {string} [className] - Custom body class for the menu contents. These classes will be set on the <body> tag for the Menu's drop down window.
|
|
13
|
+
* @param {string} [id] - Unique ID for the menu. Defaults to a random string.
|
|
14
|
+
* @param {number} [maxHeight=Infinity] - Maximum height of the menu.
|
|
15
|
+
* @param {number} [minHeight] - Minimum height of the menu
|
|
16
|
+
* @param {array} [openHotkey] - A hotkey combination to open the menu.
|
|
17
|
+
* @param {array} [closeHotkey=["escape"] ] - A hotkey combination to close the menu. Defaults to ["escape"].
|
|
18
|
+
* @param {number} [width=180] - Custom width for the menu.
|
|
19
|
+
* @param {number} [height] - Custom height for the menu. If not set then the height will be automatically calculated based on the content height and available monitor space.
|
|
20
|
+
*/
|
|
3
21
|
export const AppLauncherMenu = (props) => {
|
|
4
22
|
const [menus, setMenus] = useState({});
|
|
5
23
|
const updateMenu = () => {
|
|
@@ -9,8 +27,10 @@ export const AppLauncherMenu = (props) => {
|
|
|
9
27
|
};
|
|
10
28
|
useEffect(() => {
|
|
11
29
|
updateMenu();
|
|
30
|
+
// Listen for notifications that the menu has changed
|
|
12
31
|
FSBL.Clients.ConfigClient.addListener({ field: "finsemble.toolbarMenus" }, updateMenu);
|
|
13
32
|
}, []);
|
|
33
|
+
// dynamic menu
|
|
14
34
|
if (Object.values(menus).length > 0) {
|
|
15
35
|
return (React.createElement(React.Fragment, null, Object.values(menus)
|
|
16
36
|
.sort((a, b) => a.position - b.position)
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"AppLauncherMenu.js","sourceRoot":"","sources":["../../../../src/components/toolbar/appLauncher/AppLauncherMenu.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,EAAE,SAAS,EAAE,QAAQ,EAAE,MAAM,OAAO,CAAC;AACnD,OAAO,EAAE,qBAAqB,EAAE,MAAM,yBAAyB,CAAC;
|
|
1
|
+
{"version":3,"file":"AppLauncherMenu.js","sourceRoot":"","sources":["../../../../src/components/toolbar/appLauncher/AppLauncherMenu.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,EAAE,SAAS,EAAE,QAAQ,EAAE,MAAM,OAAO,CAAC;AACn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GAAG,CAAC,GACzE,CACF,CAAC,CACD,CACH,CAAC;KACF;SAAM;QACN,OAAO,oBAAC,qBAAqB,oBAAK,KAAK,EAAI,CAAC;KAC5C;AACF,CAAC,CAAC","sourcesContent":["import React, { useEffect, useState } from \"react\";\nimport { StaticAppLauncherMenu } from \"./StaticAppLauncherMenu\";\nimport { MenuProps } from \"../../menu/Menu\";\nimport { MenuObjType, MenuType } from \"../../../types/smartDesktopDesignerTypes\";\n\ntype AppLauncherMenuType = MenuProps & {\n\tenableQuickComponents?: boolean; // DEPRECATED: Quick Components will be removed in a future version\n\tcomponentFilter?: string[];\n\tsuppressFavorites?: boolean;\n\tdynamic?: boolean; //DEPRECATED\n};\n\n/**\n * The menu, or collection of menus, that lists all configured Finsemble applications, and provides\n * the ability to launch any listed app.\n *\n * @param {boolean} [enableQuickComponents=false] DEPRECATED: Set to true to allow users to create their own components\n * @param {string} [title] The title of the menu that appears in the menu's <MenuToggle> button, as viewed in the toolbar. Can be string or any ReactNode.\n * @param {string[]} [componentFilter] Custom list of menu items to display\n * @param {boolean} [suppressFavorites=false]\n * @param {boolean} [dynamic=false] If dynamic=true, get list of menus from manifest, as well as listening for updates to list\n * @param {string} [className] - Custom body class for the menu contents. These classes will be set on the <body> tag for the Menu's drop down window.\n * @param {string} [id] - Unique ID for the menu. Defaults to a random string.\n * @param {number} [maxHeight=Infinity] - Maximum height of the menu.\n * @param {number} [minHeight] - Minimum height of the menu\n * @param {array} [openHotkey] - A hotkey combination to open the menu.\n * @param {array} [closeHotkey=[\"escape\"] ] - A hotkey combination to close the menu. Defaults to [\"escape\"].\n * @param {number} [width=180] - Custom width for the menu.\n * @param {number} [height] - Custom height for the menu. If not set then the height will be automatically calculated based on the content height and available monitor space.\n */\nexport const AppLauncherMenu = (props: AppLauncherMenuType) => {\n\tconst [menus, setMenus] = useState<MenuType>({});\n\n\tconst updateMenu = () => {\n\t\tFSBL.Clients.ConfigClient.getValue(\"finsemble.toolbarMenus\").then(({ data }) => {\n\t\t\tsetMenus(data);\n\t\t});\n\t};\n\n\tuseEffect(() => {\n\t\tupdateMenu();\n\n\t\t// Listen for notifications that the menu has changed\n\t\tFSBL.Clients.ConfigClient.addListener({ field: \"finsemble.toolbarMenus\" }, updateMenu);\n\t}, []);\n\n\t// dynamic menu\n\tif (Object.values(menus).length > 0) {\n\t\treturn (\n\t\t\t<>\n\t\t\t\t{Object.values(menus)\n\t\t\t\t\t.sort((a: MenuObjType, b: MenuObjType) => a.position - b.position)\n\t\t\t\t\t.map((menuObj: MenuObjType, index: number) => (\n\t\t\t\t\t\t<StaticAppLauncherMenu\n\t\t\t\t\t\t\tkey={index}\n\t\t\t\t\t\t\tid={`AppLauncher-${index}`}\n\t\t\t\t\t\t\ttitle={menuObj.displayName}\n\t\t\t\t\t\t\tcomponentFilter={menuObj.applications}\n\t\t\t\t\t\t\tsuppressFavorites={menuObj.applications && menuObj.applications.length > 0}\n\t\t\t\t\t\t/>\n\t\t\t\t\t))}\n\t\t\t</>\n\t\t);\n\t} else {\n\t\treturn <StaticAppLauncherMenu {...props} />;\n\t}\n};\n"]}
|
|
@@ -18,6 +18,15 @@ interface IProps {
|
|
|
18
18
|
interface IState {
|
|
19
19
|
initialized: boolean;
|
|
20
20
|
}
|
|
21
|
+
/**
|
|
22
|
+
* The "app" button that launches the AppLauncher menu from the toolbar.
|
|
23
|
+
* The app launcher lists all configured Finsemble applications.
|
|
24
|
+
*
|
|
25
|
+
* @param {boolean} [enableQuickComponents=false] DEPRECATED: Set to true to allow users to create their own components
|
|
26
|
+
* @param {string} [title] The title of the menu, as viewed in the toolbar
|
|
27
|
+
* @param {string[]} [componentFilter] Custom list of menu items to display
|
|
28
|
+
* @param {boolean} [suppressFavorites=false]
|
|
29
|
+
*/
|
|
21
30
|
export declare class StaticAppLauncherMenu extends React.Component<IProps, IState> {
|
|
22
31
|
constructor(props: IProps);
|
|
23
32
|
onInitialized(): void;
|
|
@@ -4,6 +4,15 @@ import { MenuItem } from "../../menu/MenuItem";
|
|
|
4
4
|
import ComponentList from "./components/componentList";
|
|
5
5
|
import { storeManager } from "./stores/appLauncherStore";
|
|
6
6
|
import "./appLauncher.css";
|
|
7
|
+
/**
|
|
8
|
+
* The "app" button that launches the AppLauncher menu from the toolbar.
|
|
9
|
+
* The app launcher lists all configured Finsemble applications.
|
|
10
|
+
*
|
|
11
|
+
* @param {boolean} [enableQuickComponents=false] DEPRECATED: Set to true to allow users to create their own components
|
|
12
|
+
* @param {string} [title] The title of the menu, as viewed in the toolbar
|
|
13
|
+
* @param {string[]} [componentFilter] Custom list of menu items to display
|
|
14
|
+
* @param {boolean} [suppressFavorites=false]
|
|
15
|
+
*/
|
|
7
16
|
export class StaticAppLauncherMenu extends React.Component {
|
|
8
17
|
constructor(props) {
|
|
9
18
|
super(props);
|
|
@@ -20,6 +29,7 @@ export class StaticAppLauncherMenu extends React.Component {
|
|
|
20
29
|
componentDidMount() {
|
|
21
30
|
storeManager.addInitializedListener(this.onInitialized);
|
|
22
31
|
storeManager.initialize();
|
|
32
|
+
// Focus on the window when it is shown so that a click elsewhere will trigger a blur.
|
|
23
33
|
finsembleWindow.addEventListener("shown", () => {
|
|
24
34
|
finsembleWindow.focus();
|
|
25
35
|
});
|
|
@@ -30,7 +40,9 @@ export class StaticAppLauncherMenu extends React.Component {
|
|
|
30
40
|
componentWillUnmount() {
|
|
31
41
|
storeManager.removeInitializedListener(this.onInitialized);
|
|
32
42
|
}
|
|
43
|
+
// @deprecated - Quick Components will be removed in a future version
|
|
33
44
|
openQuickComponent() {
|
|
45
|
+
// FSBL.Clients.LauncherClient.spawn("QuickComponentForm", { monitor: "mine" });
|
|
34
46
|
FSBL.Clients.DialogManager.open("QuickComponentForm", {}, () => { });
|
|
35
47
|
}
|
|
36
48
|
render() {
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"StaticAppLauncherMenu.js","sourceRoot":"","sources":["../../../../src/components/toolbar/appLauncher/StaticAppLauncherMenu.tsx"],"names":[],"mappings":"A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C;CACD","sourcesContent":["import * as React from \"react\";\nimport { Menu } from \"../../menu/Menu\";\nimport { MenuItem } from \"../../menu/MenuItem\";\nimport ComponentList from \"./components/componentList\";\nimport { storeManager } from \"./stores/appLauncherStore\";\n\nimport \"./appLauncher.css\";\ninterface IProps {\n\tclassName?: string;\n\tcloseHotkey?: Array<string>;\n\theight?: number;\n\tid?: string;\n\tmaxHeight?: number;\n\tminHeight?: number;\n\topenHotkey?: Array<string>;\n\twidth?: number;\n\ttitle?: React.ReactNode | string | null;\n\tenableQuickComponents?: boolean; // DEPRECATED: Quick Components will be removed in a future version\n\tcomponentFilter?: string[];\n\tsuppressFavorites?: boolean;\n\tdynamic?: boolean;\n}\n\ninterface IState {\n\tinitialized: boolean;\n}\n\n/**\n * The \"app\" button that launches the AppLauncher menu from the toolbar.\n * The app launcher lists all configured Finsemble applications.\n *\n * @param {boolean} [enableQuickComponents=false] DEPRECATED: Set to true to allow users to create their own components\n * @param {string} [title] The title of the menu, as viewed in the toolbar\n * @param {string[]} [componentFilter] Custom list of menu items to display\n * @param {boolean} [suppressFavorites=false]\n */\nexport class StaticAppLauncherMenu extends React.Component<IProps, IState> {\n\tconstructor(props: IProps) {\n\t\tsuper(props);\n\n\t\tthis.state = {\n\t\t\tinitialized: false,\n\t\t};\n\t\tthis.onInitialized = this.onInitialized.bind(this);\n\t}\n\n\tonInitialized() {\n\t\tthis.setState({\n\t\t\tinitialized: true,\n\t\t});\n\t}\n\n\tcomponentDidMount() {\n\t\tstoreManager.addInitializedListener(this.onInitialized);\n\t\tstoreManager.initialize();\n\n\t\t// Focus on the window when it is shown so that a click elsewhere will trigger a blur.\n\t\tfinsembleWindow.addEventListener(\"shown\", () => {\n\t\t\tfinsembleWindow.focus();\n\t\t});\n\n\t\tif (this.props.enableQuickComponents) {\n\t\t\tFSBL.Clients.Logger.system.error(\"QuickComponents are deprecated and will be removed in a future release.\");\n\t\t}\n\t}\n\n\tcomponentWillUnmount() {\n\t\tstoreManager.removeInitializedListener(this.onInitialized);\n\t}\n\n\t// @deprecated - Quick Components will be removed in a future version\n\topenQuickComponent() {\n\t\t// FSBL.Clients.LauncherClient.spawn(\"QuickComponentForm\", { monitor: \"mine\" });\n\t\tFSBL.Clients.DialogManager.open(\"QuickComponentForm\", {}, () => {});\n\t}\n\n\trender() {\n\t\tconst completeProps = {\n\t\t\t...this.props,\n\t\t\twidth: this.props.width ?? 300,\n\t\t\tid: this.props.id ?? \"AppLauncherMenu\",\n\t\t\ttitle: this.props.title ?? \"Apps\",\n\t\t\tclassName: this.props.className ?? \"menu-portal app-launcher\",\n\t\t};\n\n\t\treturn (\n\t\t\t<Menu {...completeProps}>\n\t\t\t\t{this.props.enableQuickComponents ? (\n\t\t\t\t\t<div className=\"menu-secondary\">\n\t\t\t\t\t\t<MenuItem onClick={this.openQuickComponent}>New App</MenuItem>\n\t\t\t\t\t</div>\n\t\t\t\t) : null}\n\t\t\t\t{this.state.initialized && (\n\t\t\t\t\t<ComponentList\n\t\t\t\t\t\tcomponentFilter={this.props.componentFilter}\n\t\t\t\t\t\tsuppressFavorites={this.props.suppressFavorites}\n\t\t\t\t\t/>\n\t\t\t\t)}\n\t\t\t</Menu>\n\t\t);\n\t}\n}\n"]}
|
|
@@ -10,7 +10,7 @@
|
|
|
10
10
|
padding-top: 4px;
|
|
11
11
|
}
|
|
12
12
|
|
|
13
|
-
/* hover must be set again after overwriting focus for highlight to continue to work on hover after favoriting*/
|
|
13
|
+
/* hover must be set again after overwriting focus for highlight to continue to work on hover after favoriting */
|
|
14
14
|
.app-launcher-list .menu-item:hover {
|
|
15
15
|
background: var(--menu-content-hover-color);
|
|
16
16
|
outline: none;
|
|
@@ -2,6 +2,9 @@
|
|
|
2
2
|
* Copyright 2017 by ChartIQ, Inc.
|
|
3
3
|
* All rights reserved.
|
|
4
4
|
*/
|
|
5
|
+
/**
|
|
6
|
+
* This is the list of all components in the appLauncher.
|
|
7
|
+
*/
|
|
5
8
|
import React from "react";
|
|
6
9
|
import { StandardError } from "@finsemble/finsemble-api/types/types";
|
|
7
10
|
import { WindowIdentifier } from "@finsemble/finsemble-api";
|
|
@@ -2,12 +2,19 @@
|
|
|
2
2
|
* Copyright 2017 by ChartIQ, Inc.
|
|
3
3
|
* All rights reserved.
|
|
4
4
|
*/
|
|
5
|
+
/**
|
|
6
|
+
* This is the list of all components in the appLauncher.
|
|
7
|
+
*/
|
|
5
8
|
import React from "react";
|
|
6
9
|
import { getStore, Actions as appLauncherActions } from "../stores/appLauncherStore";
|
|
7
10
|
import { MenuItem } from "../../../menu/MenuItem";
|
|
8
11
|
import { FavoriteMaker } from "../../../favorites/FavoriteMaker";
|
|
9
12
|
import { useFavorites } from "../../../../hooks/useFavorites";
|
|
10
13
|
let appLauncherStore;
|
|
14
|
+
/**
|
|
15
|
+
* Handles deleting a component and removing it from favorites if necessary
|
|
16
|
+
* @param {} props
|
|
17
|
+
*/
|
|
11
18
|
const DeleteComponent = ({ name }) => {
|
|
12
19
|
const { isFavorited, removeFavorite } = useFavorites();
|
|
13
20
|
const doDeleteComponent = (e) => {
|
|
@@ -28,6 +35,7 @@ export default class appLauncherContainer extends React.Component {
|
|
|
28
35
|
super(props);
|
|
29
36
|
this.state = {
|
|
30
37
|
componentList: {},
|
|
38
|
+
// list of components to display instead of all components
|
|
31
39
|
filteredListOfComponents: (_a = props.componentFilter) !== null && _a !== void 0 ? _a : [],
|
|
32
40
|
};
|
|
33
41
|
this.bindCorrectContext();
|
|
@@ -69,6 +77,7 @@ export default class appLauncherContainer extends React.Component {
|
|
|
69
77
|
appLauncherStore === null || appLauncherStore === void 0 ? void 0 : appLauncherStore.removeListener({ field: "componentList" }, this.onComponentListUpdate);
|
|
70
78
|
}
|
|
71
79
|
launchComponent(component, params, cb) {
|
|
80
|
+
// If we are launching a group
|
|
72
81
|
if (component.group) {
|
|
73
82
|
for (let i of Object.keys(component.list)) {
|
|
74
83
|
const cloneParams = Object.assign({}, params);
|
|
@@ -87,10 +96,11 @@ export default class appLauncherContainer extends React.Component {
|
|
|
87
96
|
}
|
|
88
97
|
}
|
|
89
98
|
buildComponentItem(params) {
|
|
90
|
-
var _a, _b, _c, _d;
|
|
99
|
+
var _a, _b, _c, _d, _e;
|
|
91
100
|
const { key, isUserDefined } = params;
|
|
92
101
|
const config = (_a = this.state.componentList) === null || _a === void 0 ? void 0 : _a[key];
|
|
93
102
|
let displayName = key;
|
|
103
|
+
// If the app isn't launchable by the user, don't show it
|
|
94
104
|
if ((!config ||
|
|
95
105
|
!config.window ||
|
|
96
106
|
!config.foreign ||
|
|
@@ -100,19 +110,21 @@ export default class appLauncherContainer extends React.Component {
|
|
|
100
110
|
!(config === null || config === void 0 ? void 0 : config.group)) {
|
|
101
111
|
return;
|
|
102
112
|
}
|
|
113
|
+
// If the app is temporary (actively being configured in the Smart Desktop Designer), don't show it
|
|
103
114
|
if ((_c = (_b = config.appDConfig) === null || _b === void 0 ? void 0 : _b.manifest) === null || _c === void 0 ? void 0 : _c.temporary) {
|
|
104
115
|
return;
|
|
105
116
|
}
|
|
117
|
+
// Component developers can define a display name that will show instead of the component's type.
|
|
106
118
|
if (config.component && config.component.displayName) {
|
|
107
119
|
({ displayName } = config.component);
|
|
108
120
|
}
|
|
109
121
|
const iconDescriptor = config.icons.toolbarIcon;
|
|
110
|
-
return (React.createElement(MenuItem, { key: key, onClick: () => this.launchComponent(config, {}) },
|
|
122
|
+
return (React.createElement(MenuItem, { key: key, onClick: () => this.launchComponent(config, {}), lang: (_d = config.appDConfig) === null || _d === void 0 ? void 0 : _d.lang },
|
|
111
123
|
React.createElement("div", { className: "menu-item-row" },
|
|
112
124
|
React.createElement("span", { className: "app-name", title: displayName }, displayName),
|
|
113
125
|
React.createElement("span", { className: "menu-item-row-push-right" },
|
|
114
126
|
isUserDefined && React.createElement(DeleteComponent, { name: displayName }),
|
|
115
|
-
!this.props.suppressFavorites && (React.createElement(FavoriteMaker, { id: (
|
|
127
|
+
!this.props.suppressFavorites && (React.createElement(FavoriteMaker, { id: (_e = config === null || config === void 0 ? void 0 : config.component) === null || _e === void 0 ? void 0 : _e.type, category: "Application", name: displayName, icon: iconDescriptor, className: "menu-item-icon" }))))));
|
|
116
128
|
}
|
|
117
129
|
renderComponentsList() {
|
|
118
130
|
var _a;
|
|
@@ -123,6 +135,8 @@ export default class appLauncherContainer extends React.Component {
|
|
|
123
135
|
}
|
|
124
136
|
return true;
|
|
125
137
|
});
|
|
138
|
+
// if this is greater than 0, we don't show a note telling the user to check their configs.
|
|
139
|
+
// iterate through componentList and render a componentItem for each one.
|
|
126
140
|
const componentList = components.map((key, i) => {
|
|
127
141
|
const { component } = state.componentList[key];
|
|
128
142
|
const isUserDefined = Boolean(component && component.isUserDefined);
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"componentList.js","sourceRoot":"","sources":["../../../../../src/components/toolbar/appLauncher/components/componentList.tsx"],"names":[],"mappings":"AAAA;;;GAGG;AAIH,OAAO,KAAK,MAAM,OAAO,CAAC;AAC1B,OAAO,EAAE,QAAQ,EAAE,OAAO,IAAI,kBAAkB,EAAE,MAAM,4BAA4B,CAAC;AACrF,OAAO,EAAE,QAAQ,EAAE,MAAM,wBAAwB,CAAC;AAClD,OAAO,EAAE,aAAa,EAAE,MAAM,kCAAkC,CAAC;AACjE,OAAO,EAAE,YAAY,EAAE,MAAM,gCAAgC,CAAC;AAK9D,IAAI,gBAAwC,CAAC;AAU7C,MAAM,eAAe,GAAG,CAAC,EAAE,IAAI,EAAwB,EAAE,EAAE;IAC1D,MAAM,EAAE,WAAW,EAAE,cAAc,EAAE,GAAG,YAAY,EAAE,CAAC;IACvD,MAAM,iBAAiB,GAAG,CAAC,CAAoC,EAAE,EAAE;QAClE,CAAC,CAAC,cAAc,EAAE,CAAC;QACnB,CAAC,CAAC,eAAe,EAAE,CAAC;QACpB,kBAAkB,CAAC,2BAA2B,CAAC,IAAI,EAAE,CAAC,UAAmB,EAAE,EAAE;YAC5E,IAAI,UAAU,IAAI,WAAW,CAAC,IAAI,CAA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AG,EAAE,aAAa,EAAE,CAAC,CAAC;QAC3D,CAAC,CAAC,CAAC;QACH,OAAO,CACN,6BAAK,SAAS,EAAC,mBAAmB,IAChC,aAAa,CAAC,MAAM,CAAC,CAAC,CAAC,CACvB,aAAa,CACb,CAAC,CAAC,CAAC,CACH;YACE,GAAG;8HAGD,CACJ,CACI,CACN,CAAC;IACH,CAAC;IAED,MAAM;QACL,OAAO,IAAI,CAAC,KAAK,CAAC,aAAa,CAAC,CAAC,CAAC,IAAI,CAAC,oBAAoB,EAAE,CAAC,CAAC,CAAC,gCAAW,CAAC;IAC7E,CAAC;CACD","sourcesContent":["/*!\n * Copyright 2017 by ChartIQ, Inc.\n * All rights reserved.\n */\n/**\n * This is the list of all components in the appLauncher.\n */\nimport React from \"react\";\nimport { getStore, Actions as appLauncherActions } from \"../stores/appLauncherStore\";\nimport { MenuItem } from \"../../../menu/MenuItem\";\nimport { FavoriteMaker } from \"../../../favorites/FavoriteMaker\";\nimport { useFavorites } from \"../../../../hooks/useFavorites\";\nimport StoreModel from \"@finsemble/finsemble-api/types/clients/StoreModel\";\nimport { StandardError } from \"@finsemble/finsemble-api/types/types\";\nimport { WindowIdentifier } from \"@finsemble/finsemble-api\";\n\nlet appLauncherStore: StoreModel | undefined;\n\ntype DeleteComponentProps = {\n\tname: string;\n};\n\n/**\n * Handles deleting a component and removing it from favorites if necessary\n * @param {} props\n */\nconst DeleteComponent = ({ name }: DeleteComponentProps) => {\n\tconst { isFavorited, removeFavorite } = useFavorites();\n\tconst doDeleteComponent = (e: React.MouseEvent<HTMLSpanElement>) => {\n\t\te.preventDefault();\n\t\te.stopPropagation();\n\t\tappLauncherActions.handleRemoveCustomComponent(name, (wasDeleted: boolean) => {\n\t\t\tif (wasDeleted && isFavorited(name)) {\n\t\t\t\tremoveFavorite(name);\n\t\t\t}\n\t\t});\n\t};\n\treturn (\n\t\t<span onClick={doDeleteComponent} className=\"menu-item-icon\">\n\t\t\t<i className=\"ff-adp-trash-outline\" title=\"Delete\"></i>\n\t\t</span>\n\t);\n};\n\ntype AppLauncherContainerProps = {\n\tcomponentFilter?: string[];\n\tsuppressFavorites?: boolean;\n};\ntype ComponentDescriptor = Record<string, any>;\ntype ComponentList = Record<string, ComponentDescriptor>;\n\ninterface IState {\n\tcomponentList: ComponentList;\n\tfilteredListOfComponents: string[];\n}\n\nexport default class appLauncherContainer extends React.Component<AppLauncherContainerProps, IState> {\n\tconstructor(props: AppLauncherContainerProps) {\n\t\tsuper(props);\n\n\t\tthis.state = {\n\t\t\tcomponentList: {},\n\t\t\t// list of components to display instead of all components\n\t\t\tfilteredListOfComponents: props.componentFilter ?? [],\n\t\t};\n\t\tthis.bindCorrectContext();\n\t}\n\n\tcomponentDidUpdate(prevProps: AppLauncherContainerProps) {\n\t\tif (this.props.componentFilter !== prevProps.componentFilter) {\n\t\t\tthis.setState({\n\t\t\t\tfilteredListOfComponents: this.props.componentFilter ?? [],\n\t\t\t});\n\t\t}\n\t}\n\n\tbindCorrectContext() {\n\t\tthis.onComponentListUpdate = this.onComponentListUpdate.bind(this);\n\t\tthis.buildComponentItem = this.buildComponentItem.bind(this);\n\t}\n\n\tonComponentListUpdate(err: StandardError, data: { field: string; value: ComponentList }) {\n\t\tFSBL.Clients.Logger.system.debug(\"appLauncher onComponentListUpdate\");\n\t\tthis.setState({\n\t\t\tcomponentList: data.value,\n\t\t});\n\t}\n\n\tsetInitialState() {\n\t\tlet self = this;\n\t\tappLauncherStore?.getValue({ field: \"componentList\" }, (err: StandardError, data?: ComponentList) => {\n\t\t\tif (typeof data !== \"undefined\") {\n\t\t\t\tself.setState({\n\t\t\t\t\tcomponentList: data,\n\t\t\t\t});\n\t\t\t}\n\t\t});\n\t}\n\n\tcomponentDidMount() {\n\t\tappLauncherStore = getStore();\n\t\tthis.setInitialState();\n\t\tappLauncherStore?.addListener({ field: \"componentList\" }, this.onComponentListUpdate);\n\t}\n\n\tcomponentWillUnmount() {\n\t\tappLauncherStore?.removeListener({ field: \"componentList\" }, this.onComponentListUpdate);\n\t}\n\n\tlaunchComponent(component: any, params: any, cb?: (win?: WindowIdentifier) => void) {\n\t\t// If we are launching a group\n\t\tif (component.group) {\n\t\t\tfor (let i of Object.keys(component.list)) {\n\t\t\t\tconst cloneParams = Object.assign({}, params);\n\t\t\t\tconst c = component.list[i];\n\t\t\t\tif (c.component.windowGroup) {\n\t\t\t\t\tcloneParams.groupName = c.component.windowGroup;\n\t\t\t\t}\n\t\t\t\tappLauncherActions.launchComponent(component.list[i], params, cb);\n\t\t\t}\n\t\t} else {\n\t\t\tif (component.component.windowGroup) {\n\t\t\t\tparams.groupName = component.component.windowGroup;\n\t\t\t}\n\t\t\tappLauncherActions.launchComponent(component, params, cb);\n\t\t}\n\t}\n\n\tbuildComponentItem(params: { i: number; key: string; isUserDefined: boolean }) {\n\t\tconst { key, isUserDefined } = params;\n\t\tconst config = this.state.componentList?.[key];\n\t\tlet displayName = key;\n\n\t\t// If the app isn't launchable by the user, don't show it\n\t\tif (\n\t\t\t(!config ||\n\t\t\t\t!config.window ||\n\t\t\t\t!config.foreign ||\n\t\t\t\t!config.foreign.components ||\n\t\t\t\t!config.foreign.components[\"App Launcher\"] ||\n\t\t\t\t!config.foreign.components[\"App Launcher\"].launchableByUser) &&\n\t\t\t!config?.group\n\t\t) {\n\t\t\treturn;\n\t\t}\n\n\t\t// If the app is temporary (actively being configured in the Smart Desktop Designer), don't show it\n\t\tif (config.appDConfig?.manifest?.temporary) {\n\t\t\treturn;\n\t\t}\n\n\t\t// Component developers can define a display name that will show instead of the component's type.\n\t\tif (config.component && config.component.displayName) {\n\t\t\t({ displayName } = config.component);\n\t\t}\n\t\tconst iconDescriptor = config.icons.toolbarIcon;\n\t\treturn (\n\t\t\t<MenuItem key={key} onClick={() => this.launchComponent(config, {})}>\n\t\t\t\t<div className=\"menu-item-row\">\n\t\t\t\t\t<span className=\"app-name\" title={displayName}>\n\t\t\t\t\t\t{displayName}\n\t\t\t\t\t</span>\n\t\t\t\t\t<span className=\"menu-item-row-push-right\">\n\t\t\t\t\t\t{isUserDefined && <DeleteComponent name={displayName} />}\n\t\t\t\t\t\t{!this.props.suppressFavorites && (\n\t\t\t\t\t\t\t<FavoriteMaker\n\t\t\t\t\t\t\t\tid={config?.component?.type}\n\t\t\t\t\t\t\t\tcategory=\"Application\"\n\t\t\t\t\t\t\t\tname={displayName}\n\t\t\t\t\t\t\t\ticon={iconDescriptor}\n\t\t\t\t\t\t\t\tclassName=\"menu-item-icon\"\n\t\t\t\t\t\t\t/>\n\t\t\t\t\t\t)}\n\t\t\t\t\t</span>\n\t\t\t\t</div>\n\t\t\t</MenuItem>\n\t\t);\n\t}\n\n\trenderComponentsList() {\n\t\tconst { state } = this;\n\t\tconst components = Object.keys(state.componentList ?? {}).filter((componentType) => {\n\t\t\tif (state.filteredListOfComponents.length) {\n\t\t\t\treturn state.filteredListOfComponents.includes(componentType);\n\t\t\t}\n\t\t\treturn true;\n\t\t});\n\t\t// if this is greater than 0, we don't show a note telling the user to check their configs.\n\t\t// iterate through componentList and render a componentItem for each one.\n\t\tconst componentList = components.map((key, i) => {\n\t\t\tconst { component } = state.componentList[key];\n\t\t\tconst isUserDefined = Boolean(component && component.isUserDefined);\n\t\t\treturn this.buildComponentItem({ i, key, isUserDefined });\n\t\t});\n\t\treturn (\n\t\t\t<div className=\"app-launcher-list\">\n\t\t\t\t{componentList.length ? (\n\t\t\t\t\tcomponentList\n\t\t\t\t) : (\n\t\t\t\t\t<p>\n\t\t\t\t\t\t{\" \"}\n\t\t\t\t\t\tNo components loaded. Make sure to check ./src/components.json to make sure you've set everything up\n\t\t\t\t\t\tcorrectly.\n\t\t\t\t\t</p>\n\t\t\t\t)}\n\t\t\t</div>\n\t\t);\n\t}\n\n\trender() {\n\t\treturn this.state.componentList ? this.renderComponentsList() : <div></div>;\n\t}\n}\n"]}
|
|
1
|
+
{"version":3,"file":"componentList.js","sourceRoot":"","sources":["../../../../../src/components/toolbar/appLauncher/components/componentList.tsx"],"names":[],"mappings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,CAAC;CACD","sourcesContent":["/*!\n * Copyright 2017 by ChartIQ, Inc.\n * All rights reserved.\n */\n/**\n * This is the list of all components in the appLauncher.\n */\nimport React from \"react\";\nimport { getStore, Actions as appLauncherActions } from \"../stores/appLauncherStore\";\nimport { MenuItem } from \"../../../menu/MenuItem\";\nimport { FavoriteMaker } from \"../../../favorites/FavoriteMaker\";\nimport { useFavorites } from \"../../../../hooks/useFavorites\";\nimport StoreModel from \"@finsemble/finsemble-api/types/clients/StoreModel\";\nimport { StandardError } from \"@finsemble/finsemble-api/types/types\";\nimport { WindowIdentifier } from \"@finsemble/finsemble-api\";\n\nlet appLauncherStore: StoreModel | undefined;\n\ntype DeleteComponentProps = {\n\tname: string;\n};\n\n/**\n * Handles deleting a component and removing it from favorites if necessary\n * @param {} props\n */\nconst DeleteComponent = ({ name }: DeleteComponentProps) => {\n\tconst { isFavorited, removeFavorite } = useFavorites();\n\tconst doDeleteComponent = (e: React.MouseEvent<HTMLSpanElement>) => {\n\t\te.preventDefault();\n\t\te.stopPropagation();\n\t\tappLauncherActions.handleRemoveCustomComponent(name, (wasDeleted: boolean) => {\n\t\t\tif (wasDeleted && isFavorited(name)) {\n\t\t\t\tremoveFavorite(name);\n\t\t\t}\n\t\t});\n\t};\n\treturn (\n\t\t<span onClick={doDeleteComponent} className=\"menu-item-icon\">\n\t\t\t<i className=\"ff-adp-trash-outline\" title=\"Delete\"></i>\n\t\t</span>\n\t);\n};\n\ntype AppLauncherContainerProps = {\n\tcomponentFilter?: string[];\n\tsuppressFavorites?: boolean;\n};\ntype ComponentDescriptor = Record<string, any>;\ntype ComponentList = Record<string, ComponentDescriptor>;\n\ninterface IState {\n\tcomponentList: ComponentList;\n\tfilteredListOfComponents: string[];\n}\n\nexport default class appLauncherContainer extends React.Component<AppLauncherContainerProps, IState> {\n\tconstructor(props: AppLauncherContainerProps) {\n\t\tsuper(props);\n\n\t\tthis.state = {\n\t\t\tcomponentList: {},\n\t\t\t// list of components to display instead of all components\n\t\t\tfilteredListOfComponents: props.componentFilter ?? [],\n\t\t};\n\t\tthis.bindCorrectContext();\n\t}\n\n\tcomponentDidUpdate(prevProps: AppLauncherContainerProps) {\n\t\tif (this.props.componentFilter !== prevProps.componentFilter) {\n\t\t\tthis.setState({\n\t\t\t\tfilteredListOfComponents: this.props.componentFilter ?? [],\n\t\t\t});\n\t\t}\n\t}\n\n\tbindCorrectContext() {\n\t\tthis.onComponentListUpdate = this.onComponentListUpdate.bind(this);\n\t\tthis.buildComponentItem = this.buildComponentItem.bind(this);\n\t}\n\n\tonComponentListUpdate(err: StandardError, data: { field: string; value: ComponentList }) {\n\t\tFSBL.Clients.Logger.system.debug(\"appLauncher onComponentListUpdate\");\n\t\tthis.setState({\n\t\t\tcomponentList: data.value,\n\t\t});\n\t}\n\n\tsetInitialState() {\n\t\tlet self = this;\n\t\tappLauncherStore?.getValue({ field: \"componentList\" }, (err: StandardError, data?: ComponentList) => {\n\t\t\tif (typeof data !== \"undefined\") {\n\t\t\t\tself.setState({\n\t\t\t\t\tcomponentList: data,\n\t\t\t\t});\n\t\t\t}\n\t\t});\n\t}\n\n\tcomponentDidMount() {\n\t\tappLauncherStore = getStore();\n\t\tthis.setInitialState();\n\t\tappLauncherStore?.addListener({ field: \"componentList\" }, this.onComponentListUpdate);\n\t}\n\n\tcomponentWillUnmount() {\n\t\tappLauncherStore?.removeListener({ field: \"componentList\" }, this.onComponentListUpdate);\n\t}\n\n\tlaunchComponent(component: any, params: any, cb?: (win?: WindowIdentifier) => void) {\n\t\t// If we are launching a group\n\t\tif (component.group) {\n\t\t\tfor (let i of Object.keys(component.list)) {\n\t\t\t\tconst cloneParams = Object.assign({}, params);\n\t\t\t\tconst c = component.list[i];\n\t\t\t\tif (c.component.windowGroup) {\n\t\t\t\t\tcloneParams.groupName = c.component.windowGroup;\n\t\t\t\t}\n\t\t\t\tappLauncherActions.launchComponent(component.list[i], params, cb);\n\t\t\t}\n\t\t} else {\n\t\t\tif (component.component.windowGroup) {\n\t\t\t\tparams.groupName = component.component.windowGroup;\n\t\t\t}\n\t\t\tappLauncherActions.launchComponent(component, params, cb);\n\t\t}\n\t}\n\n\tbuildComponentItem(params: { i: number; key: string; isUserDefined: boolean }) {\n\t\tconst { key, isUserDefined } = params;\n\t\tconst config = this.state.componentList?.[key];\n\t\tlet displayName = key;\n\n\t\t// If the app isn't launchable by the user, don't show it\n\t\tif (\n\t\t\t(!config ||\n\t\t\t\t!config.window ||\n\t\t\t\t!config.foreign ||\n\t\t\t\t!config.foreign.components ||\n\t\t\t\t!config.foreign.components[\"App Launcher\"] ||\n\t\t\t\t!config.foreign.components[\"App Launcher\"].launchableByUser) &&\n\t\t\t!config?.group\n\t\t) {\n\t\t\treturn;\n\t\t}\n\n\t\t// If the app is temporary (actively being configured in the Smart Desktop Designer), don't show it\n\t\tif (config.appDConfig?.manifest?.temporary) {\n\t\t\treturn;\n\t\t}\n\n\t\t// Component developers can define a display name that will show instead of the component's type.\n\t\tif (config.component && config.component.displayName) {\n\t\t\t({ displayName } = config.component);\n\t\t}\n\t\tconst iconDescriptor = config.icons.toolbarIcon;\n\t\treturn (\n\t\t\t<MenuItem key={key} onClick={() => this.launchComponent(config, {})} lang={config.appDConfig?.lang}>\n\t\t\t\t<div className=\"menu-item-row\">\n\t\t\t\t\t<span className=\"app-name\" title={displayName}>\n\t\t\t\t\t\t{displayName}\n\t\t\t\t\t</span>\n\t\t\t\t\t<span className=\"menu-item-row-push-right\">\n\t\t\t\t\t\t{isUserDefined && <DeleteComponent name={displayName} />}\n\t\t\t\t\t\t{!this.props.suppressFavorites && (\n\t\t\t\t\t\t\t<FavoriteMaker\n\t\t\t\t\t\t\t\tid={config?.component?.type}\n\t\t\t\t\t\t\t\tcategory=\"Application\"\n\t\t\t\t\t\t\t\tname={displayName}\n\t\t\t\t\t\t\t\ticon={iconDescriptor}\n\t\t\t\t\t\t\t\tclassName=\"menu-item-icon\"\n\t\t\t\t\t\t\t/>\n\t\t\t\t\t\t)}\n\t\t\t\t\t</span>\n\t\t\t\t</div>\n\t\t\t</MenuItem>\n\t\t);\n\t}\n\n\trenderComponentsList() {\n\t\tconst { state } = this;\n\t\tconst components = Object.keys(state.componentList ?? {}).filter((componentType) => {\n\t\t\tif (state.filteredListOfComponents.length) {\n\t\t\t\treturn state.filteredListOfComponents.includes(componentType);\n\t\t\t}\n\t\t\treturn true;\n\t\t});\n\t\t// if this is greater than 0, we don't show a note telling the user to check their configs.\n\t\t// iterate through componentList and render a componentItem for each one.\n\t\tconst componentList = components.map((key, i) => {\n\t\t\tconst { component } = state.componentList[key];\n\t\t\tconst isUserDefined = Boolean(component && component.isUserDefined);\n\t\t\treturn this.buildComponentItem({ i, key, isUserDefined });\n\t\t});\n\t\treturn (\n\t\t\t<div className=\"app-launcher-list\">\n\t\t\t\t{componentList.length ? (\n\t\t\t\t\tcomponentList\n\t\t\t\t) : (\n\t\t\t\t\t<p>\n\t\t\t\t\t\t{\" \"}\n\t\t\t\t\t\tNo components loaded. Make sure to check ./src/components.json to make sure you've set everything up\n\t\t\t\t\t\tcorrectly.\n\t\t\t\t\t</p>\n\t\t\t\t)}\n\t\t\t</div>\n\t\t);\n\t}\n\n\trender() {\n\t\treturn this.state.componentList ? this.renderComponentsList() : <div></div>;\n\t}\n}\n"]}
|
|
@@ -15,6 +15,12 @@ declare const Actions: {
|
|
|
15
15
|
initializeComponentList(cb: VoidCallback): void;
|
|
16
16
|
getUserDefinedComponentList(cb: VoidCallback): void;
|
|
17
17
|
saveCustomComponents(): void;
|
|
18
|
+
/**
|
|
19
|
+
* Produce a filtered component list based on the settings for this menu (either "mode" or "list").
|
|
20
|
+
*
|
|
21
|
+
* Components will only be added to the returned list if they match the specified mode or
|
|
22
|
+
* are found in the specified list
|
|
23
|
+
*/
|
|
18
24
|
processSettings(settings: any, components: ComponentList): ComponentList;
|
|
19
25
|
filterComponents(components?: ComponentList): void;
|
|
20
26
|
handleRemoveCustomComponent(componentName: string, cb?: (wasDeconsted: boolean) => void): void;
|