@finsemble/finsemble-ui 7.0.0 → 7.1.0-beta.2
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 +13 -11
- 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 +3 -10
- 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 -1
- package/react/assets/css/finsemble.css +3 -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 +2 -2
- package/react/assets/css/menus.css +10 -10
- package/react/assets/css/notificationsCenter.css +16 -31
- 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 +2 -2
- package/react/assets/css/tags.css +10 -10
- package/react/assets/css/toolbar.css +22 -19
- package/react/assets/css/userPreferences.css +12 -14
- package/react/assets/css/windowTitleBar.css +75 -36
- 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/Checkbox.d.ts +1 -0
- package/react/components/common/Checkbox.js +2 -2
- package/react/components/common/Checkbox.js.map +1 -1
- package/react/components/common/ColorPicker.d.ts +5 -0
- package/react/components/common/ColorPicker.js +40 -0
- 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 +18 -0
- package/react/components/common/ErrorBoundary.js +21 -0
- package/react/components/common/ErrorBoundary.js.map +1 -1
- 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 +10 -0
- package/react/components/common/FinsembleIcon.js +51 -2
- package/react/components/common/FinsembleIcon.js.map +1 -1
- package/react/components/common/FinsembleSelect.js +5 -1
- package/react/components/common/FinsembleSelect.js.map +1 -1
- package/react/components/common/FinsembleToggleButtonBar.js +1 -1
- package/react/components/common/FinsembleToggleButtonBar.js.map +1 -1
- package/react/components/common/InputTable.d.ts +7 -0
- package/react/components/common/InputTable.js +7 -0
- package/react/components/common/InputTable.js.map +1 -1
- package/react/components/common/Tab.js +3 -0
- package/react/components/common/Tab.js.map +1 -1
- package/react/components/common/TimeSelect.js +24 -0
- 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/accordion.css +9 -6
- package/react/components/common/css/application-edit-page.css +39 -44
- 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 +8 -8
- package/react/components/common/css/time-select.css +1 -0
- package/react/components/common/css/toggle.css +4 -4
- 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 +1 -0
- package/react/components/common/helpers.js.map +1 -1
- package/react/components/common/stories/ColorPicker.stories.js +3 -0
- 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/tests/Accordion.spec.js +6 -0
- package/react/components/common/tests/Accordion.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 +1 -0
- package/react/components/common/tests/FinsembleToggle.spec.js.map +1 -1
- package/react/components/common/tests/FinsembleToggleButtonBar.spec.js +1 -0
- package/react/components/common/tests/FinsembleToggleButtonBar.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 +9 -0
- 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 +8 -0
- 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 +13 -0
- package/react/components/icon/Icon.js +34 -0
- package/react/components/icon/Icon.js.map +1 -1
- package/react/components/legacyControls/FinsembleDialog.d.ts +4 -0
- package/react/components/legacyControls/FinsembleDialog.js +15 -0
- 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 +126 -1
- 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/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 +112 -2
- 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 +3 -0
- package/react/components/menu/MenuToggle.js.map +1 -1
- package/react/components/menu/keyboardNavigation.d.ts +12 -0
- package/react/components/menu/keyboardNavigation.js +55 -0
- 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 +8 -0
- 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 +18 -0
- 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 +1 -1
- 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 +13 -6
- 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/views/CardView.js +3 -0
- package/react/components/notifications/components/views/CardView.js.map +1 -1
- package/react/components/notifications/components/views/ListView.js +8 -0
- 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 +3 -0
- 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 +17 -2
- 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 -1
- 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 +23 -3
- package/react/components/processMonitor/helpers.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 +4 -2
- package/react/components/sdd/AddApp.js +57 -49
- package/react/components/sdd/AddApp.js.map +1 -1
- package/react/components/sdd/AppEditAccess.js +8 -0
- package/react/components/sdd/AppEditAccess.js.map +1 -1
- package/react/components/sdd/AppEditPage.d.ts +2 -1
- package/react/components/sdd/AppEditPage.js +148 -361
- package/react/components/sdd/AppEditPage.js.map +1 -1
- package/react/components/sdd/Appearance.css +1 -1
- package/react/components/sdd/Appearance.js +3 -0
- package/react/components/sdd/Appearance.js.map +1 -1
- package/react/components/sdd/Application.js +39 -7
- package/react/components/sdd/Application.js.map +1 -1
- package/react/components/sdd/Applications.js +89 -13
- package/react/components/sdd/Applications.js.map +1 -1
- package/react/components/sdd/AssetsPage.css +3 -3
- package/react/components/sdd/EditPreload.js +10 -0
- package/react/components/sdd/EditPreload.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/Publish.js +2 -0
- 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.js +17 -0
- package/react/components/sdd/SmartDesktopDesigner.js.map +1 -1
- package/react/components/sdd/ThemePage.css +6 -23
- package/react/components/sdd/ThemePage.js +1 -1
- package/react/components/sdd/ThemePage.js.map +1 -1
- package/react/components/sdd/Themes.js +2 -0
- package/react/components/sdd/Themes.js.map +1 -1
- package/react/components/sdd/Toolbar.js +7 -0
- 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.js +4 -0
- package/react/components/sdd/common/setPreloadDefaults.js.map +1 -1
- package/react/components/sdd/css/addApp.css +18 -5
- package/react/components/sdd/css/appearance.css +6 -0
- package/react/components/sdd/css/applications.css +27 -14
- 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 +8 -11
- 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/configTemplate.js +1 -0
- package/react/components/sdd/fixtures/configTemplate.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 +303 -0
- package/react/components/sdd/smartDesktopClient.js +334 -1
- package/react/components/sdd/smartDesktopClient.js.map +1 -1
- package/react/components/sdd/smartDesktopClient.spec.js +5 -2
- package/react/components/sdd/smartDesktopClient.spec.js.map +1 -1
- package/react/components/sdd/stories/AddApp.stories.d.ts +2 -1
- package/react/components/sdd/stories/AddApp.stories.js +8 -0
- package/react/components/sdd/stories/AddApp.stories.js.map +1 -1
- package/react/components/sdd/stories/AppEditPage.stories.d.ts +3 -1
- package/react/components/sdd/stories/AppEditPage.stories.js +3 -0
- package/react/components/sdd/stories/AppEditPage.stories.js.map +1 -1
- package/react/components/sdd/stories/Appearance.stories.js +1 -0
- package/react/components/sdd/stories/Appearance.stories.js.map +1 -1
- package/react/components/sdd/tests/AddApp.spec.js +40 -3
- package/react/components/sdd/tests/AddApp.spec.js.map +1 -1
- package/react/components/sdd/tests/AppEditPage.spec.js +16 -0
- package/react/components/sdd/tests/AppEditPage.spec.js.map +1 -1
- package/react/components/sdd/tests/Application.spec.js +33 -438
- 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 +29 -5
- package/react/components/sdd/tests/Applications.spec.js.map +1 -1
- package/react/components/sdd/tests/Authentication.spec.js +7 -0
- 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 +13 -0
- package/react/components/sdd/tests/EditPreload.spec.js.map +1 -1
- package/react/components/sdd/tests/Export.spec.js +2 -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/OptionalSettingsView.spec.js +29 -0
- package/react/components/sdd/tests/OptionalSettingsView.spec.js.map +1 -1
- package/react/components/sdd/tests/ProjectErrors.spec.js +2 -0
- package/react/components/sdd/tests/ProjectErrors.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/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.js +6 -0
- package/react/components/search/SearchResult.js.map +1 -1
- package/react/components/search/SearchResult.spec.js +7 -0
- package/react/components/search/SearchResult.spec.js.map +1 -1
- package/react/components/search/SearchResult.stories.js +4 -0
- package/react/components/search/SearchResult.stories.js.map +1 -1
- package/react/components/search/SearchResults.js +5 -1
- package/react/components/search/SearchResults.js.map +1 -1
- package/react/components/search/SearchResults.spec.js +7 -0
- package/react/components/search/SearchResults.spec.js.map +1 -1
- 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 +9 -0
- 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/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 +44 -0
- package/react/components/singleInputDialog/SingleInputDialog.js.map +1 -1
- package/react/components/smartDesktopDesigner/SmartDesktopDesigner.js +6 -0
- 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 +1 -0
- 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 +4 -0
- package/react/components/toolbar/ToolbarIcon.js.map +1 -1
- package/react/components/toolbar/ToolbarSection.d.ts +7 -0
- package/react/components/toolbar/ToolbarSection.js +19 -1
- 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 +82 -0
- 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 +11 -0
- 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 +70 -3
- 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 +7 -0
- 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 +16 -0
- package/react/components/toolbar/workspaceManagementMenu/components/Workspace.js +20 -0
- 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 +5 -0
- 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 +76 -0
- package/react/components/toolbar/workspaceManagementMenu/stores/workspaceManagementMenuStore.js +140 -1
- 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/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 +12 -0
- package/react/components/userPreferences/components/content/Workspaces.js +33 -1
- package/react/components/userPreferences/components/content/Workspaces.js.map +1 -1
- package/react/components/userPreferences/components/content/notificationViews/NotificationsPreferencesHome.js +3 -0
- 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 +11 -0
- package/react/components/userPreferences/components/general/ScheduledClose.js.map +1 -1
- package/react/components/userPreferences/components/workspaces/WorkspaceItem.js +3 -0
- package/react/components/userPreferences/components/workspaces/WorkspaceItem.js.map +1 -1
- package/react/components/userPreferences/stores/UserPreferencesStore.d.ts +17 -0
- package/react/components/userPreferences/stores/UserPreferencesStore.js +27 -0
- package/react/components/userPreferences/stores/UserPreferencesStore.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/Workspace.spec.js +20 -0
- package/react/components/userPreferences/tests/Workspace.spec.js.map +1 -1
- package/react/components/windowTitleBar/WindowTitleBarShell.d.ts +124 -0
- package/react/components/windowTitleBar/WindowTitleBarShell.js +284 -35
- 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 +25 -9
- 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 +172 -10
- 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 +72 -1
- 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 +63 -0
- 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/timer.js +2 -0
- package/react/components/yesNoDialog/timer.js.map +1 -1
- package/react/enzymeSetup.js +5 -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 +90 -0
- 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.js +52 -0
- 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.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 +4 -0
- package/react/store.js +11 -0
- package/react/store.js.map +1 -1
- package/react/tsconfig.tsbuildinfo +1 -1
- 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 +5 -0
- package/react/types/smartDesktopDesignerTypes.js.map +1 -1
- package/react/types/workspaceTypes.d.ts +8 -0
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"LinkerMenu.js","sourceRoot":"","sources":["../../../src/components/linker/LinkerMenu.tsx"],"names":[],"mappings":"AAIA,OAAO,KAAK,EAAE,EAAE,SAAS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G,KAAK,QAAQ,EAAE;YAChC,UAAU,EAAE,CAAC;SACb;IACF,CAAC,CAAC;IAEF,OAAO,CACN,6BACC,SAAS,EAAC,iBAAiB,EAC3B,QAAQ,EAAE,CAAC,EACX,IAAI,EAAC,MAAM,EACX,SAAS,EAAE,wBAAwB,EACnC,GAAG,EAAE,gBAAgB,IAEpB,eAAe,CACX,CACN,CAAC;AACH,CAAC,CAAC;AAQF,MAAM,WAAW,GAAG,GAAG,EAAE;IACxB,MAAM,CAAC,WAAW,EAAE,cAAc,CAAC,GAAG,KAAK,CAAC,QAAQ,CAAC,EAAE,CAAC,CAAC;IAEzD,SAAS,CAAC,GAAG,EAAE;QACd,CAAC,KAAK,IAAI,EAAE;YACX,MAAM,EAAE,IAAI,EAAE,GAAG,MAAM,IAAI,CAAC,OAAO,CAAC,YAAY,CAAC,QAAQ,CAAC;gBACzD,KAAK,EAAE,yCAAyC;aAChD,CAAC,CAAC;YACH,IAAI,IAAI,EAAE;gBACT,cAAc,CAAC,yBAAyB,CAAC,CAAC;aAC1C;iBAAM;gBACN,cAAc,CAAC,eAAe,CAAC,CAAC;aAChC;QACF,CAAC,CAAC,EAAE,CAAC;IACN,CAAC,EAAE,EAAE,CAAC,CAAC;IAEP,OAAO,CACN;QACE,WAAW,KAAK,eAAe,IAAI,CACnC,oBAAC,QAAQ,IAAC,KAAK,EAAE,KAAK;YACrB,oBAAC,aAAa,OAAG,CACP,CACX;QACA,WAAW,KAAK,yBAAyB,IAAI,oBAAC,uBAAuB,OAAG,CACvE,CACH,CAAC;AACH,CAAC,CAAC;AAKF,MAAM,CAAC,MAAM,UAAU,GAAG,GAAG,EAAE,CAAC,CAC/B,oBAAC,iBAAiB;IACjB,oBAAC,WAAW,OAAG,CACI,CACpB,CAAC","sourcesContent":["/*!\n * Copyright 2020 by ChartIQ, Inc.\n * All rights reserved.\n */\nimport React, { useEffect, useState, useRef } from \"react\";\nimport { FinsembleProvider } from \"../FinsembleProvider\";\nimport { useDispatch, useSelector, Provider } from \"react-redux\";\nimport { LinkerStore, actions, store } from \"./remoteRedux\";\nimport \"../../assets/css/linkerWindow.css\";\nimport { LinkerElement as LinkerElementDeprecated } from \"./LinkerMenuDeprecated\";\n\ntype Channel = LinkerStore[\"allChannels\"][0];\ntype JoinedChannels = string[];\n\nconst LinkerElement: React.FunctionComponent = () => {\n\tconst state: LinkerStore = useSelector((currentState: any) => currentState);\n\tconst dispatch = useDispatch();\n\tconst { activeWindowName } = state;\n\tconst joinedChannels: JoinedChannels = state?.clients?.[activeWindowName ?? \"\"]?.joinedChannels ?? [];\n\tconst allChannels: Channel[] = state?.allChannels ?? [];\n\t// Track which menu item has focus for keyboard users\n\tconst [focusedMenuIndex, setFocusedMenuIndex] = useState(0);\n\tconst containerElement = useRef<HTMLDivElement>(null);\n\n\tconst hideWindow = () => {\n\t\t// Must blur or you end up having to click twice to show the window.\n\t\t// If you just hide, the first time the user clicks\n\t\t// on the linker button, the blur will trigger, which will hide the window.\n\t\tfinsembleWindow.blur();\n\t\tfinsembleWindow.hide();\n\t\tsetFocusedMenuIndex(0);\n\t};\n\n\tuseEffect(() => {\n\t\t// Move focus to container element, so that keystrokes can be captured for keyboard users (accessibility)\n\t\tcontainerElement.current && containerElement.current.focus();\n\n\t\t// Without these events, the linker menu is opened but doesn't focus, so the blur event never fires, and the menu is left\n\t\t// orphaned and sad.\n\n\t\tconst focusWindow = () => {\n\t\t\tfinsembleWindow.focus();\n\t\t};\n\n\t\tFSBL.Clients.Logger.system.log(\"Linker component is mounted. Initializing.\");\n\t\tfinsembleWindow.addEventListener(\"blurred\", hideWindow);\n\t\tfinsembleWindow.addEventListener(\"shown\", focusWindow);\n\n\t\treturn () => {\n\t\t\tFSBL.Clients.Logger.system.log(\"Linker component is unmounted. Cleaning up the event listeners.\");\n\t\t\tfinsembleWindow.removeEventListener(\"blurred\", hideWindow);\n\t\t\tfinsembleWindow.removeEventListener(\"shown\", focusWindow);\n\t\t};\n\t}, []);\n\n\tconst toggleChannel = (name: string) => {\n\t\t// These action creators can now be imported from finsemble-api\n\t\tif (activeWindowName) {\n\t\t\tif (joinedChannels.includes(name)) {\n\t\t\t\tdispatch(\n\t\t\t\t\tactions.unlinkChannels({\n\t\t\t\t\t\ttype: \"linker/unlinkChannels\",\n\t\t\t\t\t\tpayload: {\n\t\t\t\t\t\t\tchannels: [name],\n\t\t\t\t\t\t},\n\t\t\t\t\t\tmeta: {\n\t\t\t\t\t\t\twindowName: activeWindowName,\n\t\t\t\t\t\t},\n\t\t\t\t\t})\n\t\t\t\t);\n\t\t\t} else {\n\t\t\t\tdispatch(\n\t\t\t\t\tactions.linkChannels({\n\t\t\t\t\t\ttype: \"linker/linkChannels\",\n\t\t\t\t\t\tpayload: {\n\t\t\t\t\t\t\tchannels: [name],\n\t\t\t\t\t\t},\n\t\t\t\t\t\tmeta: {\n\t\t\t\t\t\t\twindowName: activeWindowName,\n\t\t\t\t\t\t},\n\t\t\t\t\t})\n\t\t\t\t);\n\t\t\t}\n\t\t}\n\t\thideWindow();\n\t};\n\n\tconst channelElements =\n\t\tactiveWindowName &&\n\t\tallChannels.map(({ name, cssClassName }, index: number) => {\n\t\t\tconst active = joinedChannels.includes(name);\n\n\t\t\treturn (\n\t\t\t\t<div\n\t\t\t\t\tkey={name}\n\t\t\t\t\tclassName={`channel-wrapper ${cssClassName} ${focusedMenuIndex === index ? \"focused\" : \"\"}`}\n\t\t\t\t\tonClick={() => toggleChannel(name)}\n\t\t\t\t>\n\t\t\t\t\t<div className=\"channel-label\">{name}</div>\n\t\t\t\t\t<div className=\"linker-glyph\">{active ? <i className=\"active-linker-group ff-check-mark\"></i> : null}</div>\n\t\t\t\t</div>\n\t\t\t);\n\t\t});\n\n\tconst manageKeyboardNavigation = (evt: React.KeyboardEvent<HTMLDivElement>) => {\n\t\tconst lastChannelIndex = allChannels.length - 1;\n\t\tif (evt.key === \"ArrowDown\") {\n\t\t\tsetFocusedMenuIndex(focusedMenuIndex >= lastChannelIndex ? 0 : focusedMenuIndex + 1);\n\t\t} else if (evt.key === \"ArrowUp\") {\n\t\t\tsetFocusedMenuIndex(focusedMenuIndex <= 0 ? lastChannelIndex : focusedMenuIndex - 1);\n\t\t} else if (evt.key === \"Enter\") {\n\t\t\ttoggleChannel(allChannels[focusedMenuIndex].name);\n\t\t} else if (evt.key === \"Escape\") {\n\t\t\thideWindow();\n\t\t}\n\t};\n\n\treturn (\n\t\t<div\n\t\t\tclassName=\"linkerContainer\"\n\t\t\ttabIndex={0}\n\t\t\trole=\"menu\"\n\t\t\tonKeyDown={manageKeyboardNavigation}\n\t\t\tref={containerElement}\n\t\t>\n\t\t\t{channelElements}\n\t\t</div>\n\t);\n};\n\n/**\n * Picks whether to display the current or deprecated LinkerElement.\n * If config `finsemble.servicesConfig.linker.enabled` is set to true then the deprecated version will be used.\n *\n * This code should be removed once the linkerClient is removed from Finsemble.\n */\nconst WhichLinker = () => {\n\tconst [whichLinker, setWhichLinker] = React.useState(\"\");\n\n\tuseEffect(() => {\n\t\t(async () => {\n\t\t\tconst { data } = await FSBL.Clients.ConfigClient.getValue({\n\t\t\t\tfield: \"finsemble.servicesConfig.linker.enabled\",\n\t\t\t});\n\t\t\tif (data) {\n\t\t\t\tsetWhichLinker(\"LinkerElementDeprecated\");\n\t\t\t} else {\n\t\t\t\tsetWhichLinker(\"LinkerElement\");\n\t\t\t}\n\t\t})();\n\t}, []);\n\n\treturn (\n\t\t<>\n\t\t\t{whichLinker === \"LinkerElement\" && (\n\t\t\t\t<Provider store={store}>\n\t\t\t\t\t<LinkerElement />\n\t\t\t\t</Provider>\n\t\t\t)}\n\t\t\t{whichLinker === \"LinkerElementDeprecated\" && <LinkerElementDeprecated />}\n\t\t</>\n\t);\n};\n\n/**\n * The Linker icon on the window titlebar that launches the linker menu.\n */\nexport const LinkerMenu = () => (\n\t<FinsembleProvider>\n\t\t<WhichLinker />\n\t</FinsembleProvider>\n);\n"]}
|
|
1
|
+
{"version":3,"file":"LinkerMenu.js","sourceRoot":"","sources":["../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AU,GAAG,GAAG,EAAE,CAAC,CAC/B,oBAAC,iBAAiB;IACjB,oBAAC,WAAW,OAAG,CACI,CACpB,CAAC","sourcesContent":["/*!\n * Copyright 2020 by ChartIQ, Inc.\n * All rights reserved.\n */\nimport React, { useEffect, useState, useRef } from \"react\";\nimport { FinsembleProvider } from \"../FinsembleProvider\";\nimport { useDispatch, useSelector, Provider } from \"react-redux\";\nimport { LinkerStore, actions, store } from \"./remoteRedux\";\nimport \"../../assets/css/linkerWindow.css\";\nimport { LinkerElement as LinkerElementDeprecated } from \"./LinkerMenuDeprecated\";\n\ntype Channel = LinkerStore[\"allChannels\"][0];\ntype JoinedChannels = string[];\n\nconst LinkerElement: React.FunctionComponent = () => {\n\tconst state: LinkerStore = useSelector((currentState: any) => currentState);\n\tconst dispatch = useDispatch();\n\tconst { activeWindowName } = state;\n\tconst joinedChannels: JoinedChannels = state?.clients?.[activeWindowName ?? \"\"]?.joinedChannels ?? [];\n\tconst allChannels: Channel[] = state?.allChannels ?? [];\n\t// Track which menu item has focus for keyboard users\n\tconst [focusedMenuIndex, setFocusedMenuIndex] = useState(0);\n\tconst containerElement = useRef<HTMLDivElement>(null);\n\n\tconst hideWindow = () => {\n\t\t// Must blur or you end up having to click twice to show the window.\n\t\t// If you just hide, the first time the user clicks\n\t\t// on the linker button, the blur will trigger, which will hide the window.\n\t\tfinsembleWindow.blur();\n\t\tfinsembleWindow.hide();\n\t\tsetFocusedMenuIndex(0);\n\t};\n\n\tuseEffect(() => {\n\t\t// Move focus to container element, so that keystrokes can be captured for keyboard users (accessibility)\n\t\tcontainerElement.current && containerElement.current.focus();\n\n\t\t// Without these events, the linker menu is opened but doesn't focus, so the blur event never fires, and the menu is left\n\t\t// orphaned and sad.\n\n\t\tconst focusWindow = () => {\n\t\t\tfinsembleWindow.focus();\n\t\t};\n\n\t\tFSBL.Clients.Logger.system.log(\"Linker component is mounted. Initializing.\");\n\t\tfinsembleWindow.addEventListener(\"blurred\", hideWindow);\n\t\tfinsembleWindow.addEventListener(\"shown\", focusWindow);\n\n\t\treturn () => {\n\t\t\tFSBL.Clients.Logger.system.log(\"Linker component is unmounted. Cleaning up the event listeners.\");\n\t\t\tfinsembleWindow.removeEventListener(\"blurred\", hideWindow);\n\t\t\tfinsembleWindow.removeEventListener(\"shown\", focusWindow);\n\t\t};\n\t}, []);\n\n\tconst toggleChannel = (name: string) => {\n\t\t// These action creators can now be imported from finsemble-api\n\t\tif (activeWindowName) {\n\t\t\tif (joinedChannels.includes(name)) {\n\t\t\t\tdispatch(\n\t\t\t\t\tactions.unlinkChannels({\n\t\t\t\t\t\ttype: \"linker/unlinkChannels\",\n\t\t\t\t\t\tpayload: {\n\t\t\t\t\t\t\tchannels: [name],\n\t\t\t\t\t\t},\n\t\t\t\t\t\tmeta: {\n\t\t\t\t\t\t\twindowName: activeWindowName,\n\t\t\t\t\t\t},\n\t\t\t\t\t})\n\t\t\t\t);\n\t\t\t} else {\n\t\t\t\tdispatch(\n\t\t\t\t\tactions.linkChannels({\n\t\t\t\t\t\ttype: \"linker/linkChannels\",\n\t\t\t\t\t\tpayload: {\n\t\t\t\t\t\t\tchannels: [name],\n\t\t\t\t\t\t},\n\t\t\t\t\t\tmeta: {\n\t\t\t\t\t\t\twindowName: activeWindowName,\n\t\t\t\t\t\t},\n\t\t\t\t\t})\n\t\t\t\t);\n\t\t\t}\n\t\t}\n\t\thideWindow();\n\t};\n\n\tconst channelElements =\n\t\tactiveWindowName &&\n\t\tallChannels.map(({ name, cssClassName }, index: number) => {\n\t\t\tconst active = joinedChannels.includes(name);\n\n\t\t\treturn (\n\t\t\t\t<div\n\t\t\t\t\tkey={name}\n\t\t\t\t\tclassName={`channel-wrapper ${cssClassName} ${focusedMenuIndex === index ? \"focused\" : \"\"}`}\n\t\t\t\t\tonClick={() => toggleChannel(name)}\n\t\t\t\t>\n\t\t\t\t\t<div className=\"channel-label\">{name}</div>\n\t\t\t\t\t<div className=\"linker-glyph\">{active ? <i className=\"active-linker-group ff-check-mark\"></i> : null}</div>\n\t\t\t\t</div>\n\t\t\t);\n\t\t});\n\n\tconst manageKeyboardNavigation = (evt: React.KeyboardEvent<HTMLDivElement>) => {\n\t\tconst lastChannelIndex = allChannels.length - 1;\n\t\tif (evt.key === \"ArrowDown\") {\n\t\t\tsetFocusedMenuIndex(focusedMenuIndex >= lastChannelIndex ? 0 : focusedMenuIndex + 1);\n\t\t} else if (evt.key === \"ArrowUp\") {\n\t\t\tsetFocusedMenuIndex(focusedMenuIndex <= 0 ? lastChannelIndex : focusedMenuIndex - 1);\n\t\t} else if (evt.key === \"Enter\") {\n\t\t\ttoggleChannel(allChannels[focusedMenuIndex].name);\n\t\t} else if (evt.key === \"Escape\") {\n\t\t\thideWindow();\n\t\t}\n\t};\n\n\treturn (\n\t\t<div\n\t\t\tclassName=\"linkerContainer\"\n\t\t\ttabIndex={0}\n\t\t\trole=\"menu\"\n\t\t\tonKeyDown={manageKeyboardNavigation}\n\t\t\tref={containerElement}\n\t\t>\n\t\t\t{channelElements}\n\t\t</div>\n\t);\n};\n\n/**\n * Picks whether to display the current or deprecated LinkerElement.\n * If config `finsemble.servicesConfig.linker.enabled` is set to true then the deprecated version will be used.\n *\n * This code should be removed once the linkerClient is removed from Finsemble.\n */\nconst WhichLinker = () => {\n\tconst [whichLinker, setWhichLinker] = React.useState(\"\");\n\n\tuseEffect(() => {\n\t\t(async () => {\n\t\t\tconst { data } = await FSBL.Clients.ConfigClient.getValue({\n\t\t\t\tfield: \"finsemble.servicesConfig.linker.enabled\",\n\t\t\t});\n\t\t\tif (data) {\n\t\t\t\tsetWhichLinker(\"LinkerElementDeprecated\");\n\t\t\t} else {\n\t\t\t\tsetWhichLinker(\"LinkerElement\");\n\t\t\t}\n\t\t})();\n\t}, []);\n\n\treturn (\n\t\t<>\n\t\t\t{whichLinker === \"LinkerElement\" && (\n\t\t\t\t<Provider store={store}>\n\t\t\t\t\t<LinkerElement />\n\t\t\t\t</Provider>\n\t\t\t)}\n\t\t\t{whichLinker === \"LinkerElementDeprecated\" && <LinkerElementDeprecated />}\n\t\t</>\n\t);\n};\n\n/**\n * The Linker icon on the window titlebar that launches the linker menu.\n */\nexport const LinkerMenu = () => (\n\t<FinsembleProvider>\n\t\t<WhichLinker />\n\t</FinsembleProvider>\n);\n"]}
|
|
@@ -1,4 +1,7 @@
|
|
|
1
1
|
/// <reference types="react" />
|
|
2
2
|
import "../../assets/css/linkerWindow.css";
|
|
3
3
|
export declare const LinkerElement: () => JSX.Element;
|
|
4
|
+
/**
|
|
5
|
+
* The Linker icon on the window titlebar that launches the linker menu.
|
|
6
|
+
*/
|
|
4
7
|
export declare const LinkerMenu: () => JSX.Element;
|
|
@@ -1,3 +1,9 @@
|
|
|
1
|
+
/*!
|
|
2
|
+
* Copyright 2020 by ChartIQ, Inc.
|
|
3
|
+
* All rights reserved.
|
|
4
|
+
*
|
|
5
|
+
* This is a deprecated version of LinkerMenu which uses the linkerClient. It is not compatible with FDC3 interop.
|
|
6
|
+
*/
|
|
1
7
|
import * as React from "react";
|
|
2
8
|
import { useLinker } from "../../hooks/useLinker";
|
|
3
9
|
import { FinsembleProvider } from "../FinsembleProvider";
|
|
@@ -24,6 +30,9 @@ export const LinkerElement = () => {
|
|
|
24
30
|
});
|
|
25
31
|
return React.createElement("div", { className: "linkerContainer" }, channelElements);
|
|
26
32
|
};
|
|
33
|
+
/**
|
|
34
|
+
* The Linker icon on the window titlebar that launches the linker menu.
|
|
35
|
+
*/
|
|
27
36
|
export const LinkerMenu = () => (React.createElement(FinsembleProvider, null,
|
|
28
37
|
React.createElement(LinkerElement, null)));
|
|
29
38
|
//# sourceMappingURL=LinkerMenuDeprecated.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"LinkerMenuDeprecated.js","sourceRoot":"","sources":["../../../src/components/linker/LinkerMenuDeprecated.tsx"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"LinkerMenuDeprecated.js","sourceRoot":"","sources":["../../../src/components/linker/LinkerM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AAS,EAAC,eAAe,IAAE,IAAI,CAAO,CAAC,CAAC,CAAC,IAAI;YAC9E,6BAAK,SAAS,EAAE,UAAU,EAAE,KAAK,EAAE,KAAK,IACtC,MAAM,CAAC,CAAC,CAAC,2BAAG,SAAS,EAAC,mCAAmC,GAAK,CAAC,CAAC,CAAC,IAAI,CACjE,CACD,CACN,CAAC;IACH,CAAC,CAAC,CAAC;IAEH,OAAO,6BAAK,SAAS,EAAC,iBAAiB,IAAE,eAAe,CAAO,CAAC;AACjE,CAAC,CAAC;AAEF;;GAEG;AACH,MAAM,CAAC,MAAM,UAAU,GAAG,GAAG,EAAE,CAAC,CAC/B,oBAAC,iBAAiB;IACjB,oBAAC,aAAa,OAAG,CACE,CACpB,CAAC","sourcesContent":["/*!\n * Copyright 2020 by ChartIQ, Inc.\n * All rights reserved.\n *\n * This is a deprecated version of LinkerMenu which uses the linkerClient. It is not compatible with FDC3 interop.\n */\nimport * as React from \"react\";\n\nimport { Channel } from \"../../types/linkerTypes\";\nimport { useLinker } from \"../../hooks/useLinker\";\nimport { FinsembleProvider } from \"../FinsembleProvider\";\nimport \"../../assets/css/linkerWindow.css\";\n\nconst MAXIMUM_CHANNEL_SELECTIONS = 20;\nconst HIT_MAXIMUM_CHANNEL_SELECTIONS_ERROR_MESSAGE = `Attempted to render more channels than allowed. UI may look bad displaying more than ${MAXIMUM_CHANNEL_SELECTIONS} channels`;\n\nexport const LinkerElement = () => {\n\tFSBL.Clients.Logger.deprecated(\n\t\t\"This is a deprecated version of LinkerMenu which uses the linkerClient. It will be removed in a future Finsemble version. It is not compatible with FDC3 interop.\"\n\t);\n\tconst { state, toggleChannel } = useLinker();\n\n\tconst allChannels = Object.values(state.channels) as Channel[];\n\tconst channelElements = allChannels.map(({ color, border, name, active, id }, index) => {\n\t\tif (index > MAXIMUM_CHANNEL_SELECTIONS - 1) {\n\t\t\tFSBL.Clients.Logger.error(HIT_MAXIMUM_CHANNEL_SELECTIONS_ERROR_MESSAGE);\n\t\t\treturn;\n\t\t}\n\t\tconst groupClass = `linkerGroup ${color}`;\n\t\tconst style = {\n\t\t\tbackgroundColor: color,\n\t\t\tborder: `1px solid ${border ?? color}`,\n\t\t};\n\t\treturn (\n\t\t\t<div key={id} className=\"channel-wrapper\" onClick={() => toggleChannel(id)}>\n\t\t\t\t{state.isAccessibleLinker ? <div className=\"channel-label\">{name}</div> : null}\n\t\t\t\t<div className={groupClass} style={style}>\n\t\t\t\t\t{active ? <i className=\"active-linker-group ff-check-mark\"></i> : null}\n\t\t\t\t</div>\n\t\t\t</div>\n\t\t);\n\t});\n\n\treturn <div className=\"linkerContainer\">{channelElements}</div>;\n};\n\n/**\n * The Linker icon on the window titlebar that launches the linker menu.\n */\nexport const LinkerMenu = () => (\n\t<FinsembleProvider>\n\t\t<LinkerElement />\n\t</FinsembleProvider>\n);\n"]}
|
|
@@ -10,4 +10,19 @@ export declare type MenuProps = {
|
|
|
10
10
|
width?: number;
|
|
11
11
|
title?: React.ReactNode | string;
|
|
12
12
|
};
|
|
13
|
+
/**
|
|
14
|
+
* A convenience component that fully encapsulates a menu by constructing a <MenuShell> and its contents.
|
|
15
|
+
* All of the props are passed to MenuShell.
|
|
16
|
+
*
|
|
17
|
+
* @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.
|
|
18
|
+
* @param {array} [closeHotkey=["escape"] ] - A hotkey combination to close the menu. Defaults to ["escape"].
|
|
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
|
+
* @param {string} [id] - Unique ID for the menu. Defaults to a random string.
|
|
21
|
+
* @param {number} [maxHeight=Infinity] - Maximum height of the menu.
|
|
22
|
+
* @param {number} [minHeight] - Minimum height of the menu
|
|
23
|
+
* @param {array} [openHotkey] - A hotkey combination to open the menu.
|
|
24
|
+
* @param {number} [width=180] - Custom width for the menu.
|
|
25
|
+
* @param {title} [string] - Name that appears in the menu's <MenuToggle> button.
|
|
26
|
+
*
|
|
27
|
+
*/
|
|
13
28
|
export declare const Menu: React.FunctionComponent<MenuProps>;
|
|
@@ -2,6 +2,21 @@ import * as React from "react";
|
|
|
2
2
|
import { MenuShell } from "./MenuShell";
|
|
3
3
|
import { MenuToggle } from "./MenuToggle";
|
|
4
4
|
import { MenuContent } from "./MenuContent";
|
|
5
|
+
/**
|
|
6
|
+
* A convenience component that fully encapsulates a menu by constructing a <MenuShell> and its contents.
|
|
7
|
+
* All of the props are passed to MenuShell.
|
|
8
|
+
*
|
|
9
|
+
* @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.
|
|
10
|
+
* @param {array} [closeHotkey=["escape"] ] - A hotkey combination to close the menu. Defaults to ["escape"].
|
|
11
|
+
* @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.
|
|
12
|
+
* @param {string} [id] - Unique ID for the menu. Defaults to a random string.
|
|
13
|
+
* @param {number} [maxHeight=Infinity] - Maximum height of the menu.
|
|
14
|
+
* @param {number} [minHeight] - Minimum height of the menu
|
|
15
|
+
* @param {array} [openHotkey] - A hotkey combination to open the menu.
|
|
16
|
+
* @param {number} [width=180] - Custom width for the menu.
|
|
17
|
+
* @param {title} [string] - Name that appears in the menu's <MenuToggle> button.
|
|
18
|
+
*
|
|
19
|
+
*/
|
|
5
20
|
export const Menu = (props) => {
|
|
6
21
|
const { children, title } = props;
|
|
7
22
|
return (React.createElement(MenuShell, Object.assign({}, props),
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"Menu.js","sourceRoot":"","sources":["../../../src/components/menu/Menu.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,KAAK,MAAM,OAAO,CAAC;AAC/B,OAAO,EAAE,SAAS,EAAE,MAAM,aAAa,CAAC;AACxC,OAAO,EAAE,UAAU,EAAE,MAAM,cAAc,CAAC;AAC1C,OAAO,EAAE,WAAW,EAAE,MAAM,eAAe,CAAC;
|
|
1
|
+
{"version":3,"file":"Menu.js","sourceRoot":"","sources":["../../../src/components/menu/Menu.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,KAAK,MAAM,OAAO,CAAC;AAC/B,OAAO,EAAE,SAAS,EAAE,MAAM,aAAa,CAAC;AACxC,OAAO,EAAE,UAAU,EAAE,MAAM,cAAc,CAAC;AAC1C,OAAO,EAAE,WAAW,EAAE,MAAM,eAAe,CAAC;AAc5C;;;;;;;;;;;;;;GAcG;AAEH,MAAM,CAAC,MAAM,IAAI,GAAuC,CAAC,KAAK,EAAE,EAAE;IACjE,MAAM,EAAE,QAAQ,EAAE,KAAK,EAAE,GAAG,KAAK,CAAC;IAElC,OAAO,CACN,oBAAC,SAAS,oBAAK,KAAK;QACnB,oBAAC,UAAU,QAAE,KAAK,CAAc;QAChC,oBAAC,WAAW,QAAE,QAAQ,CAAe,CAC1B,CACZ,CAAC;AACH,CAAC,CAAC","sourcesContent":["import * as React from \"react\";\nimport { MenuShell } from \"./MenuShell\";\nimport { MenuToggle } from \"./MenuToggle\";\nimport { MenuContent } from \"./MenuContent\";\n\nexport type MenuProps = {\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;\n};\n\n/**\n * A convenience component that fully encapsulates a menu by constructing a <MenuShell> and its contents.\n * All of the props are passed to MenuShell.\n *\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 {array} [closeHotkey=[\"escape\"] ] - A hotkey combination to close the menu. Defaults to [\"escape\"].\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 * @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 {number} [width=180] - Custom width for the menu.\n * @param {title} [string] - Name that appears in the menu's <MenuToggle> button.\n *\n */\n\nexport const Menu: React.FunctionComponent<MenuProps> = (props) => {\n\tconst { children, title } = props;\n\n\treturn (\n\t\t<MenuShell {...props}>\n\t\t\t<MenuToggle>{title}</MenuToggle>\n\t\t\t<MenuContent>{children}</MenuContent>\n\t\t</MenuShell>\n\t);\n};\n"]}
|
|
@@ -1,3 +1,7 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* To make sure that MenuPortal.tsx remain small
|
|
3
|
+
* I have isolated the auto resize logic in this class.
|
|
4
|
+
*/
|
|
1
5
|
export declare class MenuAutoResizer {
|
|
2
6
|
private width;
|
|
3
7
|
private maxHeight;
|
|
@@ -7,5 +11,8 @@ export declare class MenuAutoResizer {
|
|
|
7
11
|
private minHeight;
|
|
8
12
|
constructor(childWindow: Window, menuId: string, width: number, maxHeight?: number, minHeight?: number);
|
|
9
13
|
disconnect(): void;
|
|
14
|
+
/**
|
|
15
|
+
* Callback for MutationObserver
|
|
16
|
+
*/
|
|
10
17
|
private updateWindowDimensions;
|
|
11
18
|
}
|
|
@@ -1,4 +1,8 @@
|
|
|
1
1
|
import { calculateDimensions } from "./menuHelpers";
|
|
2
|
+
/**
|
|
3
|
+
* To make sure that MenuPortal.tsx remain small
|
|
4
|
+
* I have isolated the auto resize logic in this class.
|
|
5
|
+
*/
|
|
2
6
|
export class MenuAutoResizer {
|
|
3
7
|
constructor(childWindow, menuId, width, maxHeight = Infinity, minHeight = 0) {
|
|
4
8
|
this.width = width;
|
|
@@ -7,18 +11,36 @@ export class MenuAutoResizer {
|
|
|
7
11
|
this.childWindow = childWindow;
|
|
8
12
|
this.menuId = menuId;
|
|
9
13
|
this.updateWindowDimensions = this.updateWindowDimensions.bind(this);
|
|
14
|
+
/* The external window does not have a URL and so its origin
|
|
15
|
+
will not match the toolbar's origin, in that case
|
|
16
|
+
we won't have onload, DOMContentLoaded or any other events.
|
|
17
|
+
That makes it hard to know when the content are loaded, we cant
|
|
18
|
+
even inject custom JS as it will be already late.
|
|
19
|
+
The only way to know about a DOM change was MutationObserver!
|
|
20
|
+
*/
|
|
10
21
|
this.observer = new MutationObserver(this.updateWindowDimensions);
|
|
22
|
+
/* Now we watch for any DOM changes in the childWindow
|
|
23
|
+
Knowing the height of the window contents is crucial for
|
|
24
|
+
making decision about its position (below/above the toolbar).
|
|
25
|
+
*/
|
|
11
26
|
this.observer.observe(this.childWindow.document, {
|
|
12
27
|
childList: true,
|
|
13
28
|
characterData: false,
|
|
14
29
|
subtree: true,
|
|
15
30
|
});
|
|
31
|
+
// Initialize the window to the correct height
|
|
16
32
|
setTimeout(this.updateWindowDimensions, 0);
|
|
17
33
|
}
|
|
18
34
|
disconnect() {
|
|
19
35
|
this.observer.disconnect();
|
|
20
36
|
}
|
|
37
|
+
/**
|
|
38
|
+
* Callback for MutationObserver
|
|
39
|
+
*/
|
|
21
40
|
async updateWindowDimensions() {
|
|
41
|
+
// If the original menu button has been removed then bypass updating the window dimensions.
|
|
42
|
+
// Probably the menu itself is in the process of being removed but the mutation observer has
|
|
43
|
+
// not yet disconnected
|
|
22
44
|
if (!document.querySelector(`#${this.menuId}-menu-toggle`)) {
|
|
23
45
|
return;
|
|
24
46
|
}
|
|
@@ -33,6 +55,11 @@ export class MenuAutoResizer {
|
|
|
33
55
|
setBoundsOnly: true,
|
|
34
56
|
forceOntoMonitor: "monitorRect",
|
|
35
57
|
};
|
|
58
|
+
/**
|
|
59
|
+
* See comment in MenuPortal.tsx on why we use showWindow() here instead of childWindow.moveTo()
|
|
60
|
+
*/
|
|
61
|
+
//this.childWindow.moveTo(left, top);
|
|
62
|
+
//this.childWindow.resizeTo(this.width, height);
|
|
36
63
|
FSBL.Clients.LauncherClient.showWindow({ windowName: this.childWindow.window.name }, params);
|
|
37
64
|
this.childWindow.document.body.setAttribute("resizing", "false");
|
|
38
65
|
}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"MenuAutoResizer.js","sourceRoot":"","sources":["../../../src/components/menu/MenuAutoResizer.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,mBAAmB,EAAE,MAAM,eAAe,CAAC;
|
|
1
|
+
{"version":3,"file":"MenuAutoResizer.js","sourceRoot":"","sources":["../../../src/components/menu/MenuAutoResizer.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,mBAAmB,EAAE,MAAM,eAAe,CAAC;AAKpD;;;GAGG;AACH,MAAM,OAAO,eAAe;IAa3B,YAAY,WAAmB,EAAE,MAAc,EAAE,KAAa,EAAE,YAAoB,QAAQ,EAAE,YAAoB,CAAC;QAClH,IAAI,CAAC,KAAK,GAAG,KAAK,CAAC;QACnB,IAAI,CAAC,SAAS,GAAG,SAAS,CAAC;QAC3B,IAAI,CAAC,SAAS,GAAG,SAAS,CAAC;QAC3B,IAAI,CAAC,WAAW,GAAG,WAAW,CAAC;QAC/B,IAAI,CAAC,MAAM,GAAG,MAAM,CAAC;QACrB,IAAI,CAAC,sBAAsB,GAAG,IAAI,CAAC,sBAAsB,CAAC,IAAI,CAAC,IAAI,CAAC,CAAC;QACrE;;;;;;UAME;QACF,IAAI,CAAC,QAAQ,GAAG,IAAI,gBAAgB,CAAC,IAAI,CAAC,sBAAsB,CAAC,CAAC;QAClE;;;UAGE;QACF,IAAI,CAAC,QAAQ,CAAC,OAAO,CAAC,IAAI,CAAC,WAAW,CAAC,QAAQ,EAAE;YAChD,SAAS,EAAE,IAAI;YACf,aAAa,EAAE,KAAK;YACpB,OAAO,EAAE,IAAI;SACb,CAAC,CAAC;QAEH,8CAA8C;QAC9C,UAAU,CAAC,IAAI,CAAC,sBAAsB,EAAE,CAAC,CAAC,CAAC;IAC5C,CAAC;IAED,UAAU;QACT,IAAI,CAAC,QAAQ,CAAC,UAAU,EAAE,CAAC;IAC5B,CAAC;IAED;;OAEG;IACK,KAAK,CAAC,sBAAsB;QACnC,2FAA2F;QAC3F,4FAA4F;QAC5F,uBAAuB;QACvB,IAAI,CAAC,QAAQ,CAAC,aAAa,CAAC,IAAI,IAAI,CAAC,MAAM,cAAc,CAAC,EAAE;YAC3D,OAAO;SACP;QACD,MAAM,EAAE,IAAI,EAAE,GAAG,EAAE,MAAM,EAAE,GAAG,MAAM,mBAAmB,CACtD,IAAI,CAAC,WAAW,EAChB,IAAI,CAAC,MAAM,EACX,CAAC,EACD,IAAI,CAAC,SAAS,EACd,IAAI,CAAC,SAAS,CACd,CAAC;QAEF,MAAM,MAAM,GAAgB;YAC3B,OAAO,EAAE,MAAM;YACf,QAAQ,EAAE,UAAU;YACpB,IAAI,EAAE,IAAI;YACV,GAAG,EAAE,GAAG;YACR,KAAK,EAAE,IAAI,CAAC,KAAK;YACjB,MAAM,EAAE,MAAM;YACd,aAAa,EAAE,IAAI;YACnB,gBAAgB,EAAE,aAAa;SAC/B,CAAC;QAEF;;WAEG;QACH,qCAAqC;QACrC,gDAAgD;QAChD,IAAI,CAAC,OAAO,CAAC,cAAc,CAAC,UAAU,CAAC,EAAE,UAAU,EAAE,IAAI,CAAC,WAAW,CAAC,MAAM,CAAC,IAAI,EAAE,EAAE,MAAM,CAAC,CAAC;QAC7F,IAAI,CAAC,WAAW,CAAC,QAAQ,CAAC,IAAI,CAAC,YAAY,CAAC,UAAU,EAAE,OAAO,CAAC,CAAC;IAClE,CAAC;CACD","sourcesContent":["import { calculateDimensions } from \"./menuHelpers\";\nimport { services } from \"@finsemble/finsemble-api\";\n\ntype SpawnParams = services.window.types.SpawnParams;\n\n/**\n * To make sure that MenuPortal.tsx remain small\n * I have isolated the auto resize logic in this class.\n */\nexport class MenuAutoResizer {\n\tprivate width: number;\n\n\tprivate maxHeight: number;\n\n\tprivate childWindow: Window;\n\n\tprivate menuId: string;\n\n\tprivate observer: MutationObserver;\n\n\tprivate minHeight: number;\n\n\tconstructor(childWindow: Window, menuId: string, width: number, maxHeight: number = Infinity, minHeight: number = 0) {\n\t\tthis.width = width;\n\t\tthis.maxHeight = maxHeight;\n\t\tthis.minHeight = minHeight;\n\t\tthis.childWindow = childWindow;\n\t\tthis.menuId = menuId;\n\t\tthis.updateWindowDimensions = this.updateWindowDimensions.bind(this);\n\t\t/* The external window does not have a URL and so its origin\n\t\twill not match the toolbar's origin, in that case\n\t\twe won't have onload, DOMContentLoaded or any other events.\n\t\tThat makes it hard to know when the content are loaded, we cant\n\t\teven inject custom JS as it will be already late.\n\t\tThe only way to know about a DOM change was MutationObserver!\n\t\t*/\n\t\tthis.observer = new MutationObserver(this.updateWindowDimensions);\n\t\t/* Now we watch for any DOM changes in the childWindow\n\t\tKnowing the height of the window contents is crucial for\n\t\tmaking decision about its position (below/above the toolbar).\n\t\t*/\n\t\tthis.observer.observe(this.childWindow.document, {\n\t\t\tchildList: true,\n\t\t\tcharacterData: false,\n\t\t\tsubtree: true,\n\t\t});\n\n\t\t// Initialize the window to the correct height\n\t\tsetTimeout(this.updateWindowDimensions, 0);\n\t}\n\n\tdisconnect() {\n\t\tthis.observer.disconnect();\n\t}\n\n\t/**\n\t * Callback for MutationObserver\n\t */\n\tprivate async updateWindowDimensions() {\n\t\t// If the original menu button has been removed then bypass updating the window dimensions.\n\t\t// Probably the menu itself is in the process of being removed but the mutation observer has\n\t\t// not yet disconnected\n\t\tif (!document.querySelector(`#${this.menuId}-menu-toggle`)) {\n\t\t\treturn;\n\t\t}\n\t\tconst { left, top, height } = await calculateDimensions(\n\t\t\tthis.childWindow,\n\t\t\tthis.menuId,\n\t\t\t0,\n\t\t\tthis.maxHeight,\n\t\t\tthis.minHeight\n\t\t);\n\n\t\tconst params: SpawnParams = {\n\t\t\tmonitor: \"mine\",\n\t\t\tposition: \"absolute\",\n\t\t\tleft: left,\n\t\t\ttop: top,\n\t\t\twidth: this.width,\n\t\t\theight: height,\n\t\t\tsetBoundsOnly: true,\n\t\t\tforceOntoMonitor: \"monitorRect\",\n\t\t};\n\n\t\t/**\n\t\t * See comment in MenuPortal.tsx on why we use showWindow() here instead of childWindow.moveTo()\n\t\t */\n\t\t//this.childWindow.moveTo(left, top);\n\t\t//this.childWindow.resizeTo(this.width, height);\n\t\tFSBL.Clients.LauncherClient.showWindow({ windowName: this.childWindow.window.name }, params);\n\t\tthis.childWindow.document.body.setAttribute(\"resizing\", \"false\");\n\t}\n}\n"]}
|
|
@@ -1,4 +1,8 @@
|
|
|
1
1
|
import * as React from "react";
|
|
2
|
+
/**
|
|
3
|
+
* Holds all the menu contents
|
|
4
|
+
* @param {string} style - The custom CSS style for the menu. This is necessary because the DOM's style will be lost when this is sent through a React portal.
|
|
5
|
+
*/
|
|
2
6
|
export declare const MenuContent: React.FunctionComponent<{
|
|
3
7
|
style?: React.CSSProperties;
|
|
4
8
|
}>;
|
|
@@ -2,6 +2,10 @@ import * as React from "react";
|
|
|
2
2
|
import { MenuContext } from "./menuContext";
|
|
3
3
|
import { MenuPortal } from "./MenuPortal";
|
|
4
4
|
import { useMenu } from "../../hooks/useMenu";
|
|
5
|
+
/**
|
|
6
|
+
* Holds all the menu contents
|
|
7
|
+
* @param {string} style - The custom CSS style for the menu. This is necessary because the DOM's style will be lost when this is sent through a React portal.
|
|
8
|
+
*/
|
|
5
9
|
export const MenuContent = ({ children, style }) => {
|
|
6
10
|
const { thisMenuId } = React.useContext(MenuContext);
|
|
7
11
|
const { isMenuActive } = useMenu();
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"MenuContent.js","sourceRoot":"","sources":["../../../src/components/menu/MenuContent.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,KAAK,MAAM,OAAO,CAAC;AAC/B,OAAO,EAAE,WAAW,EAAE,MAAM,eAAe,CAAC;AAC5C,OAAO,EAAE,UAAU,EAAE,MAAM,cAAc,CAAC;AAC1C,OAAO,EAAE,OAAO,EAAE,MAAM,qBAAqB,CAAC;
|
|
1
|
+
{"version":3,"file":"MenuContent.js","sourceRoot":"","sources":["../../../src/components/menu/MenuContent.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,KAAK,MAAM,OAAO,CAAC;AAC/B,OAAO,EAAE,WAAW,EAAE,MAAM,eAAe,CAAC;AAC5C,OAAO,EAAE,UAAU,EAAE,MAAM,cAAc,CAAC;AAC1C,OAAO,EAAE,OAAO,EAAE,MAAM,qBAAqB,CAAC;AAE9C;;;GAGG;AACH,MAAM,CAAC,MAAM,WAAW,GAEnB,CAAC,EAAE,QAAQ,EAAE,KAAK,EAAE,EAAE,EAAE;IAC5B,MAAM,EAAE,UAAU,EAAE,GAAG,KAAK,CAAC,UAAU,CAAC,WAAW,CAAC,CAAC;IACrD,MAAM,EAAE,YAAY,EAAE,GAAG,OAAO,EAAE,CAAC;IAEnC,OAAO,CACN,oBAAC,UAAU,IAAC,IAAI,EAAE,YAAY,EAAE;QAC/B,6BAAK,EAAE,EAAE,UAAU,EAAE,SAAS,EAAC,mBAAmB,EAAC,KAAK,EAAE,KAAK,IAC7D,QAAQ,CACJ,CACM,CACb,CAAC;AACH,CAAC,CAAC","sourcesContent":["import * as React from \"react\";\nimport { MenuContext } from \"./menuContext\";\nimport { MenuPortal } from \"./MenuPortal\";\nimport { useMenu } from \"../../hooks/useMenu\";\n\n/**\n * Holds all the menu contents\n * @param {string} style - The custom CSS style for the menu. This is necessary because the DOM's style will be lost when this is sent through a React portal.\n */\nexport const MenuContent: React.FunctionComponent<{\n\tstyle?: React.CSSProperties;\n}> = ({ children, style }) => {\n\tconst { thisMenuId } = React.useContext(MenuContext);\n\tconst { isMenuActive } = useMenu();\n\n\treturn (\n\t\t<MenuPortal show={isMenuActive()}>\n\t\t\t<div id={thisMenuId} className=\"menu menu-primary\" style={style}>\n\t\t\t\t{children}\n\t\t\t</div>\n\t\t</MenuPortal>\n\t);\n};\n"]}
|
|
@@ -1,4 +1,18 @@
|
|
|
1
1
|
import * as React from "react";
|
|
2
|
+
/**
|
|
3
|
+
* A component that registers a custom hotkeys pattern for opening and closing the menu.
|
|
4
|
+
* This component is used privately by <MenuShell>
|
|
5
|
+
*
|
|
6
|
+
* Note that a design decision was made to keep registry of "close" hotkeys simple.
|
|
7
|
+
* We *could* have written extra logic so that the close hotkey is only registered
|
|
8
|
+
* when the window is open but that seems unnecessary. Instead, every menu is always
|
|
9
|
+
* registered with its hotkey. The net effect is that every menu will dispatch a CLOSE_MENU
|
|
10
|
+
* action when "escape" is called. This creates a lot of dispatches but results in no operations
|
|
11
|
+
* since all the other menus will already be closed. This was preferable over the potential
|
|
12
|
+
* complication of logic that registers/unregisters a close hotkey with every menu open/close.
|
|
13
|
+
* @param {string[]} [open] - An array of key names for opening the menu.
|
|
14
|
+
* @param {string[]} [close="escape" ] - An array of key names for closing the menu. Defaults to `["escape"]` unless overridden with `null`.
|
|
15
|
+
*/
|
|
2
16
|
export declare const MenuHotKey: React.FunctionComponent<{
|
|
3
17
|
open?: string[];
|
|
4
18
|
close?: string[];
|
|
@@ -1,10 +1,25 @@
|
|
|
1
1
|
import { useMenu } from "../../hooks/useMenu";
|
|
2
2
|
import { useHotkey } from "../../hooks/useHotkey";
|
|
3
|
+
/**
|
|
4
|
+
* A component that registers a custom hotkeys pattern for opening and closing the menu.
|
|
5
|
+
* This component is used privately by <MenuShell>
|
|
6
|
+
*
|
|
7
|
+
* Note that a design decision was made to keep registry of "close" hotkeys simple.
|
|
8
|
+
* We *could* have written extra logic so that the close hotkey is only registered
|
|
9
|
+
* when the window is open but that seems unnecessary. Instead, every menu is always
|
|
10
|
+
* registered with its hotkey. The net effect is that every menu will dispatch a CLOSE_MENU
|
|
11
|
+
* action when "escape" is called. This creates a lot of dispatches but results in no operations
|
|
12
|
+
* since all the other menus will already be closed. This was preferable over the potential
|
|
13
|
+
* complication of logic that registers/unregisters a close hotkey with every menu open/close.
|
|
14
|
+
* @param {string[]} [open] - An array of key names for opening the menu.
|
|
15
|
+
* @param {string[]} [close="escape" ] - An array of key names for closing the menu. Defaults to `["escape"]` unless overridden with `null`.
|
|
16
|
+
*/
|
|
3
17
|
export const MenuHotKey = ({ open, close }) => {
|
|
4
18
|
const { openMenu, closeMenu, isMenuActive } = useMenu();
|
|
5
19
|
useHotkey(open, openMenu);
|
|
6
20
|
function removeHotKeyAndCloseMenu() {
|
|
7
21
|
FSBL.Clients.HotkeyClient.removeGlobalHotkey(close || [], removeHotKeyAndCloseMenu, closeMenu);
|
|
22
|
+
// Once menu closes, return focus to the component that launched the menu
|
|
8
23
|
finsembleWindow.bringToFront(null, (err) => {
|
|
9
24
|
if (err) {
|
|
10
25
|
FSBL.Clients.Logger.system.error("failed to bringToFront, error:", err);
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"MenuHotKey.js","sourceRoot":"","sources":["../../../src/components/menu/MenuHotKey.tsx"],"names":[],"mappings":"AACA,OAAO,EAAE,OAAO,EAAE,MAAM,qBAAqB,CAAC;AAC9C,OAAO,EAAE,SAAS,EAAE,MAAM,uBAAuB,CAAC;
|
|
1
|
+
{"version":3,"file":"MenuHotKey.js","sourceRoot":"","sources":["../../../src/components/menu/MenuHotKey.tsx"],"names":[],"mappings":"AACA,OAAO,EAAE,OAAO,EAAE,MAAM,qBAAqB,CAAC;AAC9C,OAAO,EAAE,SAAS,EAAE,MAAM,uBAAuB,CAAC;AAElD;;;;;;;;;;;;;GAaG;AACH,MAAM,CAAC,MAAM,UAAU,GAGlB,CAAC,EAAE,IAAI,EAAE,KAAK,EAAE,EAAQ,EAAE;IAC9B,MAAM,EAAE,QAAQ,EAAE,SAAS,EAAE,YAAY,EAAE,GAAG,OAAO,EAAE,CAAC;IACxD,SAAS,CAAC,IAAI,EAAE,QAAQ,CAAC,CAAC;IAE1B,SAAS,wBAAwB;QAChC,IAAI,CAAC,OAAO,CAAC,YAAY,CAAC,kBAAkB,CAAC,KAAK,IAAI,EAAE,EAAE,wBAAwB,EAAE,SAAS,CAAC,CAAC;QAE/F,yEAAyE;QACzE,eAAe,CAAC,YAAY,CAAC,IAAI,EAAE,CAAC,GAAQ,EAAE,EAAE;YAC/C,IAAI,GAAG,EAAE;gBACR,IAAI,CAAC,OAAO,CAAC,MAAM,CAAC,MAAM,CAAC,KAAK,CAAC,gCAAgC,EAAE,GAAG,CAAC,CAAC;aACxE;YAED,eAAe,CAAC,KAAK,EAAE,CAAC;QACzB,CAAC,CAAC,CAAC;IACJ,CAAC;IAED,IAAI,KAAK,CAAC,OAAO,CAAC,KAAK,CAAC,IAAI,KAAK,CAAC,MAAM,GAAG,CAAC,IAAI,YAAY,EAAE,EAAE;QAC/D,IAAI,CAAC,OAAO,CAAC,YAAY,CAAC,eAAe,CAAC,KAAK,IAAI,EAAE,EAAE,wBAAwB,CAAC,CAAC;KACjF;IAED,OAAO,IAAI,CAAC;AACb,CAAC,CAAC","sourcesContent":["import * as React from \"react\";\nimport { useMenu } from \"../../hooks/useMenu\";\nimport { useHotkey } from \"../../hooks/useHotkey\";\n\n/**\n * A component that registers a custom hotkeys pattern for opening and closing the menu.\n * This component is used privately by <MenuShell>\n *\n * Note that a design decision was made to keep registry of \"close\" hotkeys simple.\n * We *could* have written extra logic so that the close hotkey is only registered\n * when the window is open but that seems unnecessary. Instead, every menu is always\n * registered with its hotkey. The net effect is that every menu will dispatch a CLOSE_MENU\n * action when \"escape\" is called. This creates a lot of dispatches but results in no operations\n * since all the other menus will already be closed. This was preferable over the potential\n * complication of logic that registers/unregisters a close hotkey with every menu open/close.\n * @param {string[]} [open] - An array of key names for opening the menu.\n * @param {string[]} [close=\"escape\" ] - An array of key names for closing the menu. Defaults to `[\"escape\"]` unless overridden with `null`.\n */\nexport const MenuHotKey: React.FunctionComponent<{\n\topen?: string[];\n\tclose?: string[];\n}> = ({ open, close }): null => {\n\tconst { openMenu, closeMenu, isMenuActive } = useMenu();\n\tuseHotkey(open, openMenu);\n\n\tfunction removeHotKeyAndCloseMenu() {\n\t\tFSBL.Clients.HotkeyClient.removeGlobalHotkey(close || [], removeHotKeyAndCloseMenu, closeMenu);\n\n\t\t// Once menu closes, return focus to the component that launched the menu\n\t\tfinsembleWindow.bringToFront(null, (err: any) => {\n\t\t\tif (err) {\n\t\t\t\tFSBL.Clients.Logger.system.error(\"failed to bringToFront, error:\", err);\n\t\t\t}\n\n\t\t\tfinsembleWindow.focus();\n\t\t});\n\t}\n\n\tif (Array.isArray(close) && close.length > 0 && isMenuActive()) {\n\t\tFSBL.Clients.HotkeyClient.addGlobalHotkey(close || [], removeHotKeyAndCloseMenu);\n\t}\n\n\treturn null;\n};\n"]}
|
|
@@ -1,8 +1,16 @@
|
|
|
1
1
|
import * as React from "react";
|
|
2
|
+
/**
|
|
3
|
+
* Individual menu item.
|
|
4
|
+
* @param {function} [onClick] - Custom onClick handler function for when the menu item is clicked.
|
|
5
|
+
* @param {string} [className] - Custom css class name for the menu item. Defaults to "menu-item".
|
|
6
|
+
* @param {string} [style] - Custom css styles for the menu item. This is necessary because the DOM's styles will be lost when this component is sent through a React portal.
|
|
7
|
+
* @param {boolean} [noClose=false] - If set to true, prevents the menu from closing when an item is clicked on.
|
|
8
|
+
*/
|
|
2
9
|
export declare const MenuItem: React.FunctionComponent<{
|
|
3
10
|
onClick?: () => void;
|
|
4
11
|
onKeyDown?: () => void;
|
|
5
12
|
className?: string;
|
|
6
13
|
style?: object;
|
|
7
14
|
noClose?: boolean;
|
|
15
|
+
lang?: string;
|
|
8
16
|
}>;
|
|
@@ -1,11 +1,22 @@
|
|
|
1
1
|
import * as React from "react";
|
|
2
2
|
import { useMenu } from "../../hooks/useMenu";
|
|
3
|
-
|
|
3
|
+
/**
|
|
4
|
+
* Individual menu item.
|
|
5
|
+
* @param {function} [onClick] - Custom onClick handler function for when the menu item is clicked.
|
|
6
|
+
* @param {string} [className] - Custom css class name for the menu item. Defaults to "menu-item".
|
|
7
|
+
* @param {string} [style] - Custom css styles for the menu item. This is necessary because the DOM's styles will be lost when this component is sent through a React portal.
|
|
8
|
+
* @param {boolean} [noClose=false] - If set to true, prevents the menu from closing when an item is clicked on.
|
|
9
|
+
*/
|
|
10
|
+
export const MenuItem = ({ children, onClick, style, noClose, className = "menu-item", onKeyDown, lang }) => {
|
|
4
11
|
const { closeMenu } = useMenu();
|
|
12
|
+
// Combines the passed onClick handler with our
|
|
13
|
+
// default onClick handler (which closes the menu)
|
|
5
14
|
const combinedOnClick = () => {
|
|
15
|
+
// Call the developer's custom onClick handler
|
|
6
16
|
onClick && onClick();
|
|
17
|
+
// Do not close menu when noClose attributes exist
|
|
7
18
|
!noClose && closeMenu();
|
|
8
19
|
};
|
|
9
|
-
return (React.createElement("div", { tabIndex: 0, role: "menuitem", className: className, onClick: combinedOnClick, style: style, onKeyDown: onKeyDown }, children));
|
|
20
|
+
return (React.createElement("div", { tabIndex: 0, role: "menuitem", className: className, onClick: combinedOnClick, style: style, onKeyDown: onKeyDown, lang: lang }, children));
|
|
10
21
|
};
|
|
11
22
|
//# sourceMappingURL=MenuItem.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"MenuItem.js","sourceRoot":"","sources":["../../../src/components/menu/MenuItem.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,KAAK,MAAM,OAAO,CAAC;AAC/B,OAAO,EAAE,OAAO,EAAE,MAAM,qBAAqB,CAAC;
|
|
1
|
+
{"version":3,"file":"MenuItem.js","sourceRoot":"","sources":["../../../src/components/menu/MenuItem.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,KAAK,MAAM,OAAO,CAAC;AAC/B,OAAO,EAAE,OAAO,EAAE,MAAM,qBAAqB,CAAC;AAE9C;;;;;;GAMG;AACH,MAAM,CAAC,MAAM,QAAQ,GAOhB,CAAC,EAAE,QAAQ,EAAE,OAAO,EAAE,KAAK,EAAE,OAAO,EAAE,SAAS,GAAG,WAAW,EAAE,SAAS,EAAE,IAAI,EAAE,EAAO,EAAE;IAC7F,MAAM,EAAE,SAAS,EAAE,GAAG,OAAO,EAAE,CAAC;IAEhC,+CAA+C;IAC/C,kDAAkD;IAClD,MAAM,eAAe,GAAG,GAAG,EAAE;QAC5B,8CAA8C;QAC9C,OAAO,IAAI,OAAO,EAAE,CAAC;QAErB,kDAAkD;QAClD,CAAC,OAAO,IAAI,SAAS,EAAE,CAAC;IACzB,CAAC,CAAC;IAEF,OAAO,CACN,6BACC,QAAQ,EAAE,CAAC,EACX,IAAI,EAAC,UAAU,EACf,SAAS,EAAE,SAAS,EACpB,OAAO,EAAE,eAAe,EACxB,KAAK,EAAE,KAAK,EACZ,SAAS,EAAE,SAAS,EACpB,IAAI,EAAE,IAAI,IAET,QAAQ,CACJ,CACN,CAAC;AACH,CAAC,CAAC","sourcesContent":["import * as React from \"react\";\nimport { useMenu } from \"../../hooks/useMenu\";\n\n/**\n * Individual menu item.\n * @param {function} [onClick] - Custom onClick handler function for when the menu item is clicked.\n * @param {string} [className] - Custom css class name for the menu item. Defaults to \"menu-item\".\n * @param {string} [style] - Custom css styles for the menu item. This is necessary because the DOM's styles will be lost when this component is sent through a React portal.\n * @param {boolean} [noClose=false] - If set to true, prevents the menu from closing when an item is clicked on.\n */\nexport const MenuItem: React.FunctionComponent<{\n\tonClick?: () => void;\n\tonKeyDown?: () => void;\n\tclassName?: string;\n\tstyle?: object;\n\tnoClose?: boolean;\n\tlang?: string;\n}> = ({ children, onClick, style, noClose, className = \"menu-item\", onKeyDown, lang }): any => {\n\tconst { closeMenu } = useMenu();\n\n\t// Combines the passed onClick handler with our\n\t// default onClick handler (which closes the menu)\n\tconst combinedOnClick = () => {\n\t\t// Call the developer's custom onClick handler\n\t\tonClick && onClick();\n\n\t\t// Do not close menu when noClose attributes exist\n\t\t!noClose && closeMenu();\n\t};\n\n\treturn (\n\t\t<div\n\t\t\ttabIndex={0}\n\t\t\trole=\"menuitem\"\n\t\t\tclassName={className}\n\t\t\tonClick={combinedOnClick}\n\t\t\tstyle={style}\n\t\t\tonKeyDown={onKeyDown}\n\t\t\tlang={lang}\n\t\t>\n\t\t\t{children}\n\t\t</div>\n\t);\n};\n"]}
|