@finsemble/finsemble-ui 7.0.1 → 7.1.0
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 +36 -3
- 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.d.ts +1 -1
- package/react/components/userPreferences/components/workspaces/WorkspaceItem.js +20 -10
- package/react/components/userPreferences/components/workspaces/WorkspaceItem.js.map +1 -1
- package/react/components/userPreferences/stores/UserPreferencesStore.d.ts +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 +111 -0
- package/react/components/windowTitleBar/WindowTitleBarShell.js +218 -47
- 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 +100 -4
- 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,17 +1,32 @@
|
|
|
1
1
|
import { SIMPLE_MODE_STATISTICS } from "./constants";
|
|
2
|
+
// This Is Proper Case
|
|
2
3
|
export function toProperCase(str) {
|
|
3
4
|
return (str
|
|
4
5
|
.replace(/([A-Z])/g, " $1")
|
|
6
|
+
// uppercase the first character
|
|
5
7
|
.replace(/^./, (char) => char.toUpperCase()));
|
|
6
8
|
}
|
|
9
|
+
/**
|
|
10
|
+
* Given a number, will return a nice string, 1,024 will return 1KB, 100 will return 100 Bytes, and so on.
|
|
11
|
+
*
|
|
12
|
+
* The result is displayed with 2 decimal points of precision.
|
|
13
|
+
*/
|
|
7
14
|
export function bytesToSize(bytes) {
|
|
8
15
|
if (bytes === 0)
|
|
9
16
|
return "0 Bytes";
|
|
17
|
+
// Size powers, in English
|
|
10
18
|
const sizes = ["Bytes", "KB", "MB", "GB", "TB"];
|
|
19
|
+
// Determine the size power for the number of bytes
|
|
11
20
|
const i = Math.floor(Math.log(bytes) / Math.log(1024));
|
|
21
|
+
// Adjusted down to how many KB, MB, GB, etc...
|
|
12
22
|
const bytesByScale = bytes / Math.pow(1024, i);
|
|
23
|
+
// Return the size, rounded, with 2 decimal points of precision
|
|
13
24
|
return `${Math.round(bytesByScale * 100) / 100} ${sizes[i]}`;
|
|
14
25
|
}
|
|
26
|
+
/**
|
|
27
|
+
* Handler for Array.reduce. It takes the array of statistics and sums each value.
|
|
28
|
+
* This outputs an object that has total CPU and memory consumption.
|
|
29
|
+
*/
|
|
15
30
|
export const statReducer = (prev, curr) => {
|
|
16
31
|
const statistics = {};
|
|
17
32
|
SIMPLE_MODE_STATISTICS.forEach((stat) => {
|
|
@@ -28,9 +43,14 @@ export const statReducer = (prev, curr) => {
|
|
|
28
43
|
statistics,
|
|
29
44
|
};
|
|
30
45
|
};
|
|
46
|
+
/**
|
|
47
|
+
* Convenience function for rounding decimals to a given precision
|
|
48
|
+
* Note that "precision" here means "number of digits to the right of the decimal point"
|
|
49
|
+
*/
|
|
31
50
|
export const roundDecimalToPrecision = (number, precision) => {
|
|
32
|
-
|
|
33
|
-
const
|
|
34
|
-
|
|
51
|
+
// Example: number = .12345, precision = 2
|
|
52
|
+
const shiftedNumber = number * Math.pow(10, precision); // example: 12.345
|
|
53
|
+
const roundedShiftedNumber = Math.round(shiftedNumber); // example: 12
|
|
54
|
+
return roundedShiftedNumber / Math.pow(10, precision); // example: .12
|
|
35
55
|
};
|
|
36
56
|
//# sourceMappingURL=helpers.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"helpers.js","sourceRoot":"","sources":["../../../src/components/processMonitor/helpers.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,sBAAsB,EAAE,MAAM,aAAa,CAAC;
|
|
1
|
+
{"version":3,"file":"helpers.js","sourceRoot":"","sources":["../../../src/components/processMonitor/helpers.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,sBAAsB,EAAE,MAAM,aAAa,CAAC;AAGrD,sBAAsB;AACtB,MAAM,UAAU,YAAY,CAAC,GAAW;IACvC,OAAO,CACN,GAAG;SACD,OAAO,CAAC,UAAU,EAAE,KAAK,CAAC;QAC3B,gCAAgC;SAC/B,OAAO,CAAC,IAAI,EAAE,CAAC,IAAY,EAAE,EAAE,CAAC,IAAI,CAAC,WAAW,EAAE,CAAC,CACrD,CAAC;AACH,CAAC;AACD;;;;GAIG;AACH,MAAM,UAAU,WAAW,CAAC,KAAa;IACxC,IAAI,KAAK,KAAK,CAAC;QAAE,OAAO,SAAS,CAAC;IAElC,0BAA0B;IAC1B,MAAM,KAAK,GAAG,CAAC,OAAO,EAAE,IAAI,EAAE,IAAI,EAAE,IAAI,EAAE,IAAI,CAAC,CAAC;IAEhD,mDAAmD;IACnD,MAAM,CAAC,GAAG,IAAI,CAAC,KAAK,CAAC,IAAI,CAAC,GAAG,CAAC,KAAK,CAAC,GAAG,IAAI,CAAC,GAAG,CAAC,IAAI,CAAC,CAAC,CAAC;IAEvD,+CAA+C;IAC/C,MAAM,YAAY,GAAG,KAAK,GAAG,IAAI,CAAC,GAAG,CAAC,IAAI,EAAE,CAAC,CAAC,CAAC;IAE/C,+DAA+D;IAC/D,OAAO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AAI,CAAC,GAAG,CAAC,EAAE,EAAE,SAAS,CAAC,CAAC,CAAC,eAAe;AACvE,CAAC,CAAC","sourcesContent":["import { SIMPLE_MODE_STATISTICS } from \"./constants\";\nimport { ProcessStatisticsType, ProcessType } from \"./ProcessMonitorTypes\";\n\n// This Is Proper Case\nexport function toProperCase(str: string) {\n\treturn (\n\t\tstr\n\t\t\t.replace(/([A-Z])/g, \" $1\")\n\t\t\t// uppercase the first character\n\t\t\t.replace(/^./, (char: string) => char.toUpperCase())\n\t);\n}\n/**\n * Given a number, will return a nice string, 1,024 will return 1KB, 100 will return 100 Bytes, and so on.\n *\n * The result is displayed with 2 decimal points of precision.\n */\nexport function bytesToSize(bytes: number) {\n\tif (bytes === 0) return \"0 Bytes\";\n\n\t// Size powers, in English\n\tconst sizes = [\"Bytes\", \"KB\", \"MB\", \"GB\", \"TB\"];\n\n\t// Determine the size power for the number of bytes\n\tconst i = Math.floor(Math.log(bytes) / Math.log(1024));\n\n\t// Adjusted down to how many KB, MB, GB, etc...\n\tconst bytesByScale = bytes / Math.pow(1024, i);\n\n\t// Return the size, rounded, with 2 decimal points of precision\n\treturn `${Math.round(bytesByScale * 100) / 100} ${sizes[i]}`;\n}\n\n/**\n * Handler for Array.reduce. It takes the array of statistics and sums each value.\n * This outputs an object that has total CPU and memory consumption.\n */\nexport const statReducer = (prev: ProcessType, curr: ProcessType): ProcessType => {\n\tconst statistics: ProcessStatisticsType[\"statistics\"] = {};\n\tSIMPLE_MODE_STATISTICS.forEach((stat) => {\n\t\tif (typeof prev.statistics[stat.value] === \"undefined\" || typeof curr.statistics[stat.value] === \"undefined\") {\n\t\t\tstatistics[stat.value] = undefined;\n\t\t\treturn;\n\t\t}\n\n\t\tstatistics[stat.value] = (prev.statistics[stat.value] ?? 0) + (curr.statistics[stat.value] ?? 0);\n\t});\n\n\tstatistics.name = \"Totals\";\n\n\treturn {\n\t\tvisible: curr.visible,\n\t\tstatistics,\n\t};\n};\n\n/**\n * Convenience function for rounding decimals to a given precision\n * Note that \"precision\" here means \"number of digits to the right of the decimal point\"\n */\nexport const roundDecimalToPrecision = (number: number, precision: number): number => {\n\t// Example: number = .12345, precision = 2\n\tconst shiftedNumber = number * Math.pow(10, precision); // example: 12.345\n\tconst roundedShiftedNumber = Math.round(shiftedNumber); // example: 12\n\treturn roundedShiftedNumber / Math.pow(10, precision); // example: .12\n};\n"]}
|
|
@@ -6,18 +6,57 @@ declare let ProcessMonitorStore: StoreModel | undefined;
|
|
|
6
6
|
declare type VoidCallback = () => void;
|
|
7
7
|
export declare let storeWrapper: StoreModel | null | undefined;
|
|
8
8
|
declare const Actions: {
|
|
9
|
+
/**
|
|
10
|
+
* Creates the local store, then gets the first cut at stats for the process list.
|
|
11
|
+
*/
|
|
9
12
|
initialize: (cb: VoidCallback) => void;
|
|
13
|
+
/**
|
|
14
|
+
* Gets the process list, pulls the statistics out, and renders the app. Also sets up an interval where we'll retrieve more stats from the system.
|
|
15
|
+
*/
|
|
10
16
|
getInitialData: () => void;
|
|
17
|
+
/**
|
|
18
|
+
* Sets the sort field; if it's the same field as we had previously, we flip the sort direction.
|
|
19
|
+
*/
|
|
11
20
|
setSort: (field: string) => void;
|
|
21
|
+
/**
|
|
22
|
+
* Extracts data from the process list (via the createDataModel function), and then sets the processList value on the store. This causes the UI to re-render.
|
|
23
|
+
*/
|
|
12
24
|
extractData: (processes: ProcessInfo[]) => void;
|
|
25
|
+
/**
|
|
26
|
+
* Converts the system.getProcessList response into something that's easily render-able.
|
|
27
|
+
*/
|
|
13
28
|
createDataModel: (processes: ProcessInfo[], cb: (procs: ProcessType[]) => void) => void;
|
|
29
|
+
/**
|
|
30
|
+
* Sorting function. Handles ascending and descending.
|
|
31
|
+
*/
|
|
14
32
|
sortProcesses: (procs: ProcessType[]) => ProcessType[];
|
|
33
|
+
/**
|
|
34
|
+
* Toggles advanced/simple mode
|
|
35
|
+
*/
|
|
15
36
|
toggleViewMode: () => void;
|
|
37
|
+
/**
|
|
38
|
+
* Gets the current "flashing" state - whether the process monitor is currently flashing a window
|
|
39
|
+
*/
|
|
16
40
|
getFlashingState: (cb?: StandardCallback<StandardError, any> | undefined) => void;
|
|
41
|
+
/**
|
|
42
|
+
* Gets the current "flashing" state for the process monitor
|
|
43
|
+
*/
|
|
17
44
|
setFlashingState: (value: boolean, cb?: StandardCallback<StandardError, any> | undefined) => void;
|
|
45
|
+
/**
|
|
46
|
+
* Make the window flash a couple of times so that the user can identify it.
|
|
47
|
+
*/
|
|
18
48
|
identifyWindow: (winID: ChildWindowType) => void;
|
|
49
|
+
/**
|
|
50
|
+
* Terminates a process group. Containing windows for browser views will be closed.
|
|
51
|
+
*/
|
|
19
52
|
terminateProcess: (webContents: ProcessType["statistics"]["webContents"]) => void;
|
|
53
|
+
/**
|
|
54
|
+
* This function exists to make the UI feel snappy. May take a second or so for the window to close properly and for the change to flow to system.getProcessList. To make that lag go away, we immediately render the change.
|
|
55
|
+
*/
|
|
20
56
|
removeWindowLocally: (windowName: string) => void;
|
|
57
|
+
/**
|
|
58
|
+
* Try to close the window. If that fails, try to force close the window. If that fails, ask if they'd like to terminate the parent process.
|
|
59
|
+
*/
|
|
21
60
|
closeWindow: (windowName: string, force?: boolean) => void;
|
|
22
61
|
};
|
|
23
62
|
export { ProcessMonitorStore as Store, Actions };
|
|
@@ -1,5 +1,6 @@
|
|
|
1
1
|
import async from "async";
|
|
2
2
|
let ProcessMonitorStore;
|
|
3
|
+
//Regex code taken from https://gist.github.com/mattheyan/46a230da86a0894a5ff654b9139ec5f2
|
|
3
4
|
const DEFAULT_SORT_DIRECTION = "ascending";
|
|
4
5
|
const DEFAULT_STORE_DATA = {
|
|
5
6
|
viewMode: "simple",
|
|
@@ -21,22 +22,32 @@ function createLocalStore(done) {
|
|
|
21
22
|
});
|
|
22
23
|
}
|
|
23
24
|
const Actions = {
|
|
25
|
+
/**
|
|
26
|
+
* Creates the local store, then gets the first cut at stats for the process list.
|
|
27
|
+
*/
|
|
24
28
|
initialize: (cb) => {
|
|
25
29
|
createLocalStore(() => {
|
|
26
30
|
Actions.getInitialData();
|
|
27
31
|
cb();
|
|
28
32
|
});
|
|
29
33
|
},
|
|
34
|
+
/**
|
|
35
|
+
* Gets the process list, pulls the statistics out, and renders the app. Also sets up an interval where we'll retrieve more stats from the system.
|
|
36
|
+
*/
|
|
30
37
|
getInitialData: () => {
|
|
31
38
|
FSBL.System.getProcessList(Actions.extractData);
|
|
32
39
|
setInterval(() => {
|
|
33
40
|
FSBL.System.getProcessList(Actions.extractData);
|
|
34
41
|
}, 1000);
|
|
35
42
|
},
|
|
43
|
+
/**
|
|
44
|
+
* Sets the sort field; if it's the same field as we had previously, we flip the sort direction.
|
|
45
|
+
*/
|
|
36
46
|
setSort: (field) => {
|
|
37
47
|
const currentSort = ProcessMonitorStore === null || ProcessMonitorStore === void 0 ? void 0 : ProcessMonitorStore.getValue({ field: "sort" });
|
|
38
48
|
let procs = ProcessMonitorStore === null || ProcessMonitorStore === void 0 ? void 0 : ProcessMonitorStore.getValue({ field: "processList" });
|
|
39
49
|
let newSort;
|
|
50
|
+
//If it's the same field as before, flip the direction
|
|
40
51
|
if (currentSort.field === field) {
|
|
41
52
|
newSort = currentSort;
|
|
42
53
|
if (currentSort.direction == "ascending") {
|
|
@@ -53,15 +64,23 @@ const Actions = {
|
|
|
53
64
|
};
|
|
54
65
|
}
|
|
55
66
|
ProcessMonitorStore === null || ProcessMonitorStore === void 0 ? void 0 : ProcessMonitorStore.setValue({ field: "sort", value: newSort }, () => {
|
|
67
|
+
// When changing sort we'll re-render the UI immediately instead of waiting for the process list to update. Without this step, it could be 999ms until the next update, which makes the process monitor feel very unresponsive and very bad.
|
|
56
68
|
procs = Actions.sortProcesses(procs);
|
|
57
69
|
ProcessMonitorStore === null || ProcessMonitorStore === void 0 ? void 0 : ProcessMonitorStore.setValue({ field: "processList", value: procs });
|
|
58
70
|
});
|
|
59
71
|
},
|
|
72
|
+
/**
|
|
73
|
+
* Extracts data from the process list (via the createDataModel function), and then sets the processList value on the store. This causes the UI to re-render.
|
|
74
|
+
*/
|
|
60
75
|
extractData: (processes) => {
|
|
61
76
|
Actions.createDataModel(processes, (procs) => {
|
|
77
|
+
//set store.
|
|
62
78
|
ProcessMonitorStore === null || ProcessMonitorStore === void 0 ? void 0 : ProcessMonitorStore.setValue({ field: "processList", value: procs });
|
|
63
79
|
});
|
|
64
80
|
},
|
|
81
|
+
/**
|
|
82
|
+
* Converts the system.getProcessList response into something that's easily render-able.
|
|
83
|
+
*/
|
|
65
84
|
createDataModel: (processes, cb) => {
|
|
66
85
|
const mode = ProcessMonitorStore === null || ProcessMonitorStore === void 0 ? void 0 : ProcessMonitorStore.getValue({ field: "viewMode" });
|
|
67
86
|
const sortWindow = (a, b) => {
|
|
@@ -111,6 +130,9 @@ const Actions = {
|
|
|
111
130
|
});
|
|
112
131
|
cb(Actions.sortProcesses(procs));
|
|
113
132
|
},
|
|
133
|
+
/**
|
|
134
|
+
* Sorting function. Handles ascending and descending.
|
|
135
|
+
*/
|
|
114
136
|
sortProcesses: (procs) => {
|
|
115
137
|
let currentSort = ProcessMonitorStore === null || ProcessMonitorStore === void 0 ? void 0 : ProcessMonitorStore.getValue({ field: "sort" });
|
|
116
138
|
let sortFN = (a, b) => {
|
|
@@ -119,6 +141,7 @@ const Actions = {
|
|
|
119
141
|
if (typeof aValue === "undefined" || typeof bValue === "undefined") {
|
|
120
142
|
return 0;
|
|
121
143
|
}
|
|
144
|
+
//Comparing upper and lowercase names makes the sort look wrong. we equalize all strings here.
|
|
122
145
|
if (typeof aValue === "string") {
|
|
123
146
|
aValue = aValue.toLowerCase();
|
|
124
147
|
}
|
|
@@ -140,6 +163,9 @@ const Actions = {
|
|
|
140
163
|
};
|
|
141
164
|
return procs.sort(sortFN);
|
|
142
165
|
},
|
|
166
|
+
/**
|
|
167
|
+
* Toggles advanced/simple mode
|
|
168
|
+
*/
|
|
143
169
|
toggleViewMode: () => {
|
|
144
170
|
const mode = ProcessMonitorStore === null || ProcessMonitorStore === void 0 ? void 0 : ProcessMonitorStore.getValue({ field: "viewMode" });
|
|
145
171
|
ProcessMonitorStore === null || ProcessMonitorStore === void 0 ? void 0 : ProcessMonitorStore.setValue({
|
|
@@ -147,12 +173,21 @@ const Actions = {
|
|
|
147
173
|
value: mode === "advanced" ? "simple" : "advanced",
|
|
148
174
|
});
|
|
149
175
|
},
|
|
176
|
+
/**
|
|
177
|
+
* Gets the current "flashing" state - whether the process monitor is currently flashing a window
|
|
178
|
+
*/
|
|
150
179
|
getFlashingState: (cb) => {
|
|
151
180
|
ProcessMonitorStore === null || ProcessMonitorStore === void 0 ? void 0 : ProcessMonitorStore.getValue("flashing", cb);
|
|
152
181
|
},
|
|
182
|
+
/**
|
|
183
|
+
* Gets the current "flashing" state for the process monitor
|
|
184
|
+
*/
|
|
153
185
|
setFlashingState: (value, cb) => {
|
|
154
186
|
ProcessMonitorStore === null || ProcessMonitorStore === void 0 ? void 0 : ProcessMonitorStore.setValue({ field: "flashing", value }, cb);
|
|
155
187
|
},
|
|
188
|
+
/**
|
|
189
|
+
* Make the window flash a couple of times so that the user can identify it.
|
|
190
|
+
*/
|
|
156
191
|
identifyWindow: function (winID) {
|
|
157
192
|
if (winID.windowName.includes("Service"))
|
|
158
193
|
return;
|
|
@@ -172,9 +207,11 @@ const Actions = {
|
|
|
172
207
|
}, OPACITY_ANIMATION_DURATION / 1.5);
|
|
173
208
|
}
|
|
174
209
|
win.isShowing({}, (error, isVisible) => {
|
|
210
|
+
//cache the visible state of the window prior to making it flash. If it was hidden before, hide it when the flashing is done.
|
|
175
211
|
windowState = isVisible ? "visible" : "hidden";
|
|
176
212
|
win.show(() => {
|
|
177
213
|
win.bringToFront(() => {
|
|
214
|
+
//Flash 5 times, in series.
|
|
178
215
|
async.timesSeries(5, flash, () => {
|
|
179
216
|
if (windowState === "hidden") {
|
|
180
217
|
win.hide();
|
|
@@ -186,15 +223,20 @@ const Actions = {
|
|
|
186
223
|
});
|
|
187
224
|
});
|
|
188
225
|
},
|
|
226
|
+
/**
|
|
227
|
+
* Terminates a process group. Containing windows for browser views will be closed.
|
|
228
|
+
*/
|
|
189
229
|
terminateProcess: (webContents) => {
|
|
190
230
|
const forceCloseProcess = () => {
|
|
191
231
|
if (!webContents)
|
|
192
232
|
return;
|
|
233
|
+
// De-duped array of window names from both windows and browser views
|
|
193
234
|
const windowNames = new Set(Object.values(webContents).map((item) => item.windowName));
|
|
194
235
|
windowNames.forEach((windowName) => {
|
|
195
236
|
Actions.closeWindow(windowName, true);
|
|
196
237
|
});
|
|
197
238
|
};
|
|
239
|
+
//Ask user if they're sure. If they says "yes", close it.
|
|
198
240
|
FSBL.Clients.DialogManager.open("yesNo", {
|
|
199
241
|
title: "Terminate Process?",
|
|
200
242
|
question: "Terminating the process may close other apps. Are you sure you want to continue?",
|
|
@@ -206,6 +248,9 @@ const Actions = {
|
|
|
206
248
|
}
|
|
207
249
|
});
|
|
208
250
|
},
|
|
251
|
+
/**
|
|
252
|
+
* This function exists to make the UI feel snappy. May take a second or so for the window to close properly and for the change to flow to system.getProcessList. To make that lag go away, we immediately render the change.
|
|
253
|
+
*/
|
|
209
254
|
removeWindowLocally: function (windowName) {
|
|
210
255
|
let procs = ProcessMonitorStore === null || ProcessMonitorStore === void 0 ? void 0 : ProcessMonitorStore.getValue({ field: "processList" });
|
|
211
256
|
procs = procs.map((proc) => {
|
|
@@ -217,9 +262,13 @@ const Actions = {
|
|
|
217
262
|
});
|
|
218
263
|
ProcessMonitorStore === null || ProcessMonitorStore === void 0 ? void 0 : ProcessMonitorStore.setValue({ field: "processList", value: procs });
|
|
219
264
|
},
|
|
265
|
+
/**
|
|
266
|
+
* Try to close the window. If that fails, try to force close the window. If that fails, ask if they'd like to terminate the parent process.
|
|
267
|
+
*/
|
|
220
268
|
closeWindow: function (windowName, force = false) {
|
|
221
269
|
const win = FSBL.System.Window.wrap(windowName);
|
|
222
270
|
const onCloseFailure = () => {
|
|
271
|
+
//If Actions.closeWindow was called with force === true, and the close failed.
|
|
223
272
|
if (force) {
|
|
224
273
|
alert("Cannot close window");
|
|
225
274
|
}
|
|
@@ -227,6 +276,7 @@ const Actions = {
|
|
|
227
276
|
Actions.closeWindow(windowName, true);
|
|
228
277
|
}
|
|
229
278
|
};
|
|
279
|
+
//If we can't close within 4 seconds, something's wrong - try to force close it.
|
|
230
280
|
const closeTimeout = setTimeout(() => {
|
|
231
281
|
onCloseFailure();
|
|
232
282
|
}, MAGIC_NUMBER_TERMINATION_TIMEOUT);
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"ProcessMonitorStore.js","sourceRoot":"","sources":["../../../../src/components/processMonitor/stores/ProcessMonitorStore.ts"],"names":[],"mappings":"AAKA,OAAO,KAAK,MAAM,OAAO,CAAC;AAE1B,IAAI,mBAA2C,CAAC;AAKhD,MAAM,sBAAsB,GAAG,WAAW,CAAC;AAC3C,MAAM,kBAAkB,GAAG;IAC1B,QAAQ,EAAE,QAAQ;IAClB,IAAI,EAAE;QACL,KAAK,EAAE,MAAM;QACb,SAAS,EAAE,WAAW;KACtB;CACD,CAAC;AACF,MAAM,gCAAgC,GAAG,IAAI,CAAC;AAE9C,MAAM,CAAC,IAAI,YAA2C,CAAC;AAEvD,SAAS,gBAAgB,CAAC,IAAkB;IAC3C,IAAI,CAAC,OAAO,CAAC,sBAAsB,CAAC,WAAW,CAC9C;QACC,KAAK,EAAE,sCAAsC;QAC7C,MAAM,EAAE,kBAAkB;KAC1B,EACD,CAAC,GAAkB,EAAE,KAAkB,EAAE,EAAE;QAC1C,mBAAmB,GAAG,KAAK,CAAC;QAC5B,YAAY,GAAG,KAAK,CAAC;QACrB,IAAI,EAAE,CAAC;IACR,CAAC,CACD,CAAC;AACH,CAAC;AAED,MAAM,OAAO,GAAG;IAIf,UAAU,EAAE,CAAC,EAAgB,EAAE,EAAE;QAChC,gBAAgB,CAAC,GAAG,EAAE;YACrB,OAAO,CAAC,cAAc,EAAE,CAAC;YACzB,EAAE,EAAE,CAAC;QACN,CA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AGF,MAAM,YAAY,GAAG,UAAU,CAAC,GAAG,EAAE;YACpC,cAAc,EAAE,CAAC;QAClB,CAAC,EAAE,gCAAgC,CAAC,CAAC;QAErC,MAAM,cAAc,GAAG,GAAG,EAAE;YAC3B,OAAO,CAAC,mBAAmB,CAAC,UAAU,CAAC,CAAC;YACxC,YAAY,CAAC,YAAY,CAAC,CAAC;QAC5B,CAAC,CAAC;QAEF,GAAG,CAAC,KAAK,CAAC,KAAK,EAAE,cAAc,EAAE,cAAc,CAAC,CAAC;IAClD,CAAC;CACD,CAAC;AAEF,OAAO,EAAE,mBAAmB,IAAI,KAAK,EAAE,OAAO,EAAE,CAAC","sourcesContent":["import { ChildWindowType, ProcessType, SortObjectType } from \"../ProcessMonitorTypes\";\nimport StoreModel from \"@finsemble/finsemble-api/types/clients/StoreModel\";\nimport { StandardCallback, StandardError } from \"@finsemble/finsemble-api/types/types\";\nimport { ProcessInfo } from \"@finsemble/finsemble-api/types/FEA\";\nimport { FinsembleWindow } from \"@finsemble/finsemble-api/types/main\";\nimport async from \"async\";\n\nlet ProcessMonitorStore: StoreModel | undefined;\n\ntype VoidCallback = () => void;\n\n//Regex code taken from https://gist.github.com/mattheyan/46a230da86a0894a5ff654b9139ec5f2\nconst DEFAULT_SORT_DIRECTION = \"ascending\";\nconst DEFAULT_STORE_DATA = {\n\tviewMode: \"simple\",\n\tsort: {\n\t\tfield: \"name\",\n\t\tdirection: \"ascending\",\n\t},\n};\nconst MAGIC_NUMBER_TERMINATION_TIMEOUT = 4000;\n\nexport let storeWrapper: StoreModel | null | undefined;\n\nfunction createLocalStore(done: VoidCallback) {\n\tFSBL.Clients.DistributedStoreClient.createStore(\n\t\t{\n\t\t\tstore: \"Finsemble-ProcessMonitor-Local-Store\",\n\t\t\tvalues: DEFAULT_STORE_DATA,\n\t\t},\n\t\t(err: StandardError, store?: StoreModel) => {\n\t\t\tProcessMonitorStore = store;\n\t\t\tstoreWrapper = store;\n\t\t\tdone();\n\t\t}\n\t);\n}\n\nconst Actions = {\n\t/**\n\t * Creates the local store, then gets the first cut at stats for the process list.\n\t */\n\tinitialize: (cb: VoidCallback) => {\n\t\tcreateLocalStore(() => {\n\t\t\tActions.getInitialData();\n\t\t\tcb();\n\t\t});\n\t},\n\n\t/**\n\t * Gets the process list, pulls the statistics out, and renders the app. Also sets up an interval where we'll retrieve more stats from the system.\n\t */\n\tgetInitialData: () => {\n\t\tFSBL.System.getProcessList(Actions.extractData);\n\t\tsetInterval(() => {\n\t\t\tFSBL.System.getProcessList(Actions.extractData);\n\t\t}, 1000);\n\t},\n\n\t/**\n\t * Sets the sort field; if it's the same field as we had previously, we flip the sort direction.\n\t */\n\tsetSort: (field: string) => {\n\t\tconst currentSort = ProcessMonitorStore?.getValue({ field: \"sort\" });\n\t\tlet procs = ProcessMonitorStore?.getValue({ field: \"processList\" });\n\t\tlet newSort;\n\t\t//If it's the same field as before, flip the direction\n\t\tif (currentSort.field === field) {\n\t\t\tnewSort = currentSort;\n\t\t\tif (currentSort.direction == \"ascending\") {\n\t\t\t\tnewSort.direction = \"descending\";\n\t\t\t} else {\n\t\t\t\tnewSort.direction = \"ascending\";\n\t\t\t}\n\t\t} else {\n\t\t\tnewSort = {\n\t\t\t\tfield,\n\t\t\t\tdirection: DEFAULT_SORT_DIRECTION,\n\t\t\t};\n\t\t}\n\n\t\tProcessMonitorStore?.setValue({ field: \"sort\", value: newSort }, () => {\n\t\t\t// When changing sort we'll re-render the UI immediately instead of waiting for the process list to update. Without this step, it could be 999ms until the next update, which makes the process monitor feel very unresponsive and very bad.\n\t\t\tprocs = Actions.sortProcesses(procs);\n\t\t\tProcessMonitorStore?.setValue({ field: \"processList\", value: procs });\n\t\t});\n\t},\n\n\t/**\n\t * Extracts data from the process list (via the createDataModel function), and then sets the processList value on the store. This causes the UI to re-render.\n\t */\n\textractData: (processes: ProcessInfo[]) => {\n\t\tActions.createDataModel(processes, (procs) => {\n\t\t\t//set store.\n\t\t\tProcessMonitorStore?.setValue({ field: \"processList\", value: procs });\n\t\t});\n\t},\n\n\t/**\n\t * Converts the system.getProcessList response into something that's easily render-able.\n\t */\n\tcreateDataModel: (processes: ProcessInfo[], cb: (procs: ProcessType[]) => void) => {\n\t\tconst mode = ProcessMonitorStore?.getValue({ field: \"viewMode\" });\n\n\t\ttype WebContentsEntry = ProcessInfo[\"webContents\"][0];\n\n\t\tconst sortWindow = (a: { webContentsName: string }, b: { webContentsName: string }) => {\n\t\t\tif (a.webContentsName < b.webContentsName) return -1;\n\t\t\tif (a.webContentsName > b.webContentsName) return 1;\n\t\t\treturn 0;\n\t\t};\n\n\t\tconst viewOrWindowToProc = (item: WebContentsEntry) => {\n\t\t\treturn {\n\t\t\t\twebContentsName: item.webContentsName,\n\t\t\t\twindowName: item.windowName,\n\t\t\t\ttype: item.type,\n\t\t\t};\n\t\t};\n\n\t\tconst allowAdvanced = (item: WebContentsEntry) => {\n\t\t\tconst windowName: string = item.webContentsName.toLowerCase();\n\t\t\tconst windowIsService = windowName.includes(\"service\");\n\t\t\tconst windowIsSystem = windowName.includes(\"system\");\n\t\t\tconst windowIsUnnamed = windowName.includes(\"unnamed\");\n\t\t\tconst windowIsSimple = windowIsService || windowIsSystem || windowIsUnnamed;\n\t\t\treturn mode !== \"simple\" || !windowIsSimple;\n\t\t};\n\n\t\tconst procs: ProcessType[] = processes.map((proc) => {\n\t\t\tconst procName = proc.name.toLowerCase();\n\t\t\tconst isService = procName.includes(\"service\");\n\t\t\tconst isSystem = procName.includes(\"system\");\n\t\t\tconst isUnnamed = procName.includes(\"unnamed\");\n\t\t\tconst procIsSimple = isService || isSystem || isUnnamed;\n\t\t\tif (mode === \"simple\" && procIsSimple) {\n\t\t\t\treturn {\n\t\t\t\t\tstatistics: proc,\n\t\t\t\t\tvisible: false,\n\t\t\t\t};\n\t\t\t}\n\n\t\t\tconst childWindows: ChildWindowType[] = [...Object.values(proc.webContents)]\n\t\t\t\t.filter(allowAdvanced)\n\t\t\t\t.map(viewOrWindowToProc)\n\t\t\t\t.sort(sortWindow);\n\n\t\t\treturn {\n\t\t\t\tstatistics: proc,\n\t\t\t\tvisible: true,\n\t\t\t\ttype: proc.type,\n\t\t\t\tchildWindows,\n\t\t\t};\n\t\t});\n\n\t\tcb(Actions.sortProcesses(procs));\n\t},\n\n\t/**\n\t * Sorting function. Handles ascending and descending.\n\t */\n\tsortProcesses: (procs: ProcessType[]) => {\n\t\tlet currentSort: SortObjectType = ProcessMonitorStore?.getValue({ field: \"sort\" });\n\t\tlet sortFN = (a: ProcessType, b: ProcessType) => {\n\t\t\tlet aValue = a.statistics[currentSort.field];\n\t\t\tlet bValue = b.statistics[currentSort.field];\n\n\t\t\tif (typeof aValue === \"undefined\" || typeof bValue === \"undefined\") {\n\t\t\t\treturn 0;\n\t\t\t}\n\n\t\t\t//Comparing upper and lowercase names makes the sort look wrong. we equalize all strings here.\n\t\t\tif (typeof aValue === \"string\") {\n\t\t\t\taValue = aValue.toLowerCase();\n\t\t\t}\n\t\t\tif (typeof bValue === \"string\") {\n\t\t\t\tbValue = bValue.toLowerCase();\n\t\t\t}\n\n\t\t\tif (currentSort.direction === \"ascending\") {\n\t\t\t\tif (aValue < bValue) return -1;\n\t\t\t\tif (aValue > bValue) return 1;\n\t\t\t\treturn 0;\n\t\t\t}\n\n\t\t\tif (aValue > bValue) return -1;\n\t\t\tif (aValue < bValue) return 1;\n\t\t\treturn 0;\n\t\t};\n\t\treturn procs.sort(sortFN);\n\t},\n\n\t/**\n\t * Toggles advanced/simple mode\n\t */\n\ttoggleViewMode: () => {\n\t\tconst mode = ProcessMonitorStore?.getValue({ field: \"viewMode\" });\n\t\tProcessMonitorStore?.setValue({\n\t\t\tfield: \"viewMode\",\n\t\t\tvalue: mode === \"advanced\" ? \"simple\" : \"advanced\",\n\t\t});\n\t},\n\n\t/**\n\t * Gets the current \"flashing\" state - whether the process monitor is currently flashing a window\n\t */\n\tgetFlashingState: (cb?: StandardCallback) => {\n\t\tProcessMonitorStore?.getValue(\"flashing\", cb);\n\t},\n\n\t/**\n\t * Gets the current \"flashing\" state for the process monitor\n\t */\n\tsetFlashingState: (value: boolean, cb?: StandardCallback) => {\n\t\tProcessMonitorStore?.setValue({ field: \"flashing\", value }, cb);\n\t},\n\n\t/**\n\t * Make the window flash a couple of times so that the user can identify it.\n\t */\n\tidentifyWindow: function (winID: ChildWindowType) {\n\t\tif (winID.windowName.includes(\"Service\")) return;\n\n\t\tthis.setFlashingState(true);\n\n\t\tconst OPACITY_ANIMATION_DURATION = 200;\n\t\tFSBL.FinsembleWindow.getInstance({ name: winID.windowName }, (err: StandardError, win: FinsembleWindow) => {\n\t\t\tlet windowState = \"hidden\";\n\t\t\tfunction flash(n: any, done: any) {\n\t\t\t\tsetTimeout(() => {\n\t\t\t\t\twin.hide(() => {\n\t\t\t\t\t\tsetTimeout(() => {\n\t\t\t\t\t\t\twin.show(() => {\n\t\t\t\t\t\t\t\tdone(null);\n\t\t\t\t\t\t\t});\n\t\t\t\t\t\t}, OPACITY_ANIMATION_DURATION / 1.5);\n\t\t\t\t\t});\n\t\t\t\t}, OPACITY_ANIMATION_DURATION / 1.5);\n\t\t\t}\n\t\t\twin.isShowing({}, (error: StandardError, isVisible: boolean) => {\n\t\t\t\t//cache the visible state of the window prior to making it flash. If it was hidden before, hide it when the flashing is done.\n\t\t\t\twindowState = isVisible ? \"visible\" : \"hidden\";\n\t\t\t\twin.show(() => {\n\t\t\t\t\twin.bringToFront(() => {\n\t\t\t\t\t\t//Flash 5 times, in series.\n\t\t\t\t\t\tasync.timesSeries(5, flash, () => {\n\t\t\t\t\t\t\tif (windowState === \"hidden\") {\n\t\t\t\t\t\t\t\twin.hide();\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\tthis.setFlashingState(false);\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},\n\n\t/**\n\t * Terminates a process group. Containing windows for browser views will be closed.\n\t */\n\tterminateProcess: (webContents: ProcessType[\"statistics\"][\"webContents\"]) => {\n\t\tconst forceCloseProcess = () => {\n\t\t\tif (!webContents) return;\n\t\t\t// De-duped array of window names from both windows and browser views\n\t\t\tconst windowNames = new Set(Object.values(webContents).map((item) => item.windowName));\n\t\t\twindowNames.forEach((windowName) => {\n\t\t\t\tActions.closeWindow(windowName, true);\n\t\t\t});\n\t\t};\n\n\t\t//Ask user if they're sure. If they says \"yes\", close it.\n\t\tFSBL.Clients.DialogManager.open(\n\t\t\t\"yesNo\",\n\t\t\t{\n\t\t\t\ttitle: \"Terminate Process?\",\n\t\t\t\tquestion: \"Terminating the process may close other apps. Are you sure you want to continue?\",\n\t\t\t\taffirmativeResponseLabel: \"Terminate\",\n\t\t\t\tshowNegativeButton: false,\n\t\t\t},\n\t\t\t(err: StandardError, response: { choice: string }) => {\n\t\t\t\tif (err || response.choice === \"affirmative\") {\n\t\t\t\t\tforceCloseProcess();\n\t\t\t\t}\n\t\t\t}\n\t\t);\n\t},\n\n\t/**\n\t * This function exists to make the UI feel snappy. May take a second or so for the window to close properly and for the change to flow to system.getProcessList. To make that lag go away, we immediately render the change.\n\t */\n\tremoveWindowLocally: function (windowName: string) {\n\t\tlet procs: ProcessType[] = ProcessMonitorStore?.getValue({ field: \"processList\" });\n\t\tprocs = procs.map((proc) => {\n\t\t\tif (proc.childWindows) {\n\t\t\t\tconst cwIndex = proc.childWindows.findIndex((cw) => cw.windowName === windowName);\n\t\t\t\tproc.childWindows.splice(cwIndex, 1);\n\t\t\t}\n\t\t\treturn proc;\n\t\t});\n\t\tProcessMonitorStore?.setValue({ field: \"processList\", value: procs });\n\t},\n\n\t/**\n\t * Try to close the window. If that fails, try to force close the window. If that fails, ask if they'd like to terminate the parent process.\n\t */\n\tcloseWindow: function (windowName: string, force = false) {\n\t\tconst win = FSBL.System.Window.wrap(windowName);\n\n\t\tconst onCloseFailure = () => {\n\t\t\t//If Actions.closeWindow was called with force === true, and the close failed.\n\t\t\tif (force) {\n\t\t\t\talert(\"Cannot close window\");\n\t\t\t} else {\n\t\t\t\tActions.closeWindow(windowName, true);\n\t\t\t}\n\t\t};\n\n\t\t//If we can't close within 4 seconds, something's wrong - try to force close it.\n\t\tconst closeTimeout = setTimeout(() => {\n\t\t\tonCloseFailure();\n\t\t}, MAGIC_NUMBER_TERMINATION_TIMEOUT);\n\n\t\tconst onCloseSuccess = () => {\n\t\t\tActions.removeWindowLocally(windowName);\n\t\t\tclearTimeout(closeTimeout);\n\t\t};\n\n\t\twin.close(force, onCloseSuccess, onCloseFailure);\n\t},\n};\n\nexport { ProcessMonitorStore as Store, Actions };\n"]}
|
|
1
|
+
{"version":3,"file":"ProcessMonitorStore.js","sourceRoot":"","sources":["../../../../src/components/processMonitor/stores/ProcessMonitorStore.ts"],"names":[],"mappings":"AAKA,OAAO,KAAK,MAAM,OAAO,CAAC;AAE1B,IAAI,mBAA2C,CAAC;AAIhD,0FAA0F;AAC1F,MAAM,sBAAsB,GAAG,WAAW,CAAC;AAC3C,MAAM,kBAAkB,GAAG;IAC1B,QAAQ,EAAE,QAAQ;IAClB,IAAI,EAAE;QACL,KAAK,EAAE,MAAM;QACb,SAAS,EAAE,WAAW;KACtB;CACD,CAAC;AACF,MAAM,gCAAgC,GAAG,IAAI,CAAC;AAE9C,MAAM,CAAC,IAAI,YAA2C,CAAC;AAEvD,SAAS,gBAAgB,CAAC,IAAkB;IAC3C,IAAI,CAAC,OAAO,CAAC,sBAAsB,CAAC,WAAW,CAC9C;QACC,KAAK,EAAE,sCAAsC;QAC7C,MAAM,EAAE,kBAAkB;KAC1B,EACD,CAAC,GAAkB,EAAE,KAAkB,EAAE,EAAE;QAC1C,mBAAmB,GAAG,KAAK,CAAC;QAC5B,YAAY,GAAG,KAAK,CAAC;QACrB,IAAI,EAAE,CAAC;IACR,CAAC,CACD,CAAC;AACH,CAAC;AAED,MAAM,OAAO,GAAG;IACf;;OAEG;IACH,UAAU,EAAE,CAAC,EAAgB,EAAE,EAAE;QAChC,gBAAgB,CAAC,GAAG,EAAE;YACrB,O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AAK,GAAG,KAAK;QACvD,MAAM,GAAG,GAAG,IAAI,CAAC,MAAM,CAAC,MAAM,CAAC,IAAI,CAAC,UAAU,CAAC,CAAC;QAEhD,MAAM,cAAc,GAAG,GAAG,EAAE;YAC3B,8EAA8E;YAC9E,IAAI,KAAK,EAAE;gBACV,KAAK,CAAC,qBAAqB,CAAC,CAAC;aAC7B;iBAAM;gBACN,OAAO,CAAC,WAAW,CAAC,UAAU,EAAE,IAAI,CAAC,CAAC;aACtC;QACF,CAAC,CAAC;QAEF,gFAAgF;QAChF,MAAM,YAAY,GAAG,UAAU,CAAC,GAAG,EAAE;YACpC,cAAc,EAAE,CAAC;QAClB,CAAC,EAAE,gCAAgC,CAAC,CAAC;QAErC,MAAM,cAAc,GAAG,GAAG,EAAE;YAC3B,OAAO,CAAC,mBAAmB,CAAC,UAAU,CAAC,CAAC;YACxC,YAAY,CAAC,YAAY,CAAC,CAAC;QAC5B,CAAC,CAAC;QAEF,GAAG,CAAC,KAAK,CAAC,KAAK,EAAE,cAAc,EAAE,cAAc,CAAC,CAAC;IAClD,CAAC;CACD,CAAC;AAEF,OAAO,EAAE,mBAAmB,IAAI,KAAK,EAAE,OAAO,EAAE,CAAC","sourcesContent":["import { ChildWindowType, ProcessType, SortObjectType } from \"../ProcessMonitorTypes\";\nimport StoreModel from \"@finsemble/finsemble-api/types/clients/StoreModel\";\nimport { StandardCallback, StandardError } from \"@finsemble/finsemble-api/types/types\";\nimport { ProcessInfo } from \"@finsemble/finsemble-api/types/FEA\";\nimport { FinsembleWindow } from \"@finsemble/finsemble-api/types/main\";\nimport async from \"async\";\n\nlet ProcessMonitorStore: StoreModel | undefined;\n\ntype VoidCallback = () => void;\n\n//Regex code taken from https://gist.github.com/mattheyan/46a230da86a0894a5ff654b9139ec5f2\nconst DEFAULT_SORT_DIRECTION = \"ascending\";\nconst DEFAULT_STORE_DATA = {\n\tviewMode: \"simple\",\n\tsort: {\n\t\tfield: \"name\",\n\t\tdirection: \"ascending\",\n\t},\n};\nconst MAGIC_NUMBER_TERMINATION_TIMEOUT = 4000;\n\nexport let storeWrapper: StoreModel | null | undefined;\n\nfunction createLocalStore(done: VoidCallback) {\n\tFSBL.Clients.DistributedStoreClient.createStore(\n\t\t{\n\t\t\tstore: \"Finsemble-ProcessMonitor-Local-Store\",\n\t\t\tvalues: DEFAULT_STORE_DATA,\n\t\t},\n\t\t(err: StandardError, store?: StoreModel) => {\n\t\t\tProcessMonitorStore = store;\n\t\t\tstoreWrapper = store;\n\t\t\tdone();\n\t\t}\n\t);\n}\n\nconst Actions = {\n\t/**\n\t * Creates the local store, then gets the first cut at stats for the process list.\n\t */\n\tinitialize: (cb: VoidCallback) => {\n\t\tcreateLocalStore(() => {\n\t\t\tActions.getInitialData();\n\t\t\tcb();\n\t\t});\n\t},\n\n\t/**\n\t * Gets the process list, pulls the statistics out, and renders the app. Also sets up an interval where we'll retrieve more stats from the system.\n\t */\n\tgetInitialData: () => {\n\t\tFSBL.System.getProcessList(Actions.extractData);\n\t\tsetInterval(() => {\n\t\t\tFSBL.System.getProcessList(Actions.extractData);\n\t\t}, 1000);\n\t},\n\n\t/**\n\t * Sets the sort field; if it's the same field as we had previously, we flip the sort direction.\n\t */\n\tsetSort: (field: string) => {\n\t\tconst currentSort = ProcessMonitorStore?.getValue({ field: \"sort\" });\n\t\tlet procs = ProcessMonitorStore?.getValue({ field: \"processList\" });\n\t\tlet newSort;\n\t\t//If it's the same field as before, flip the direction\n\t\tif (currentSort.field === field) {\n\t\t\tnewSort = currentSort;\n\t\t\tif (currentSort.direction == \"ascending\") {\n\t\t\t\tnewSort.direction = \"descending\";\n\t\t\t} else {\n\t\t\t\tnewSort.direction = \"ascending\";\n\t\t\t}\n\t\t} else {\n\t\t\tnewSort = {\n\t\t\t\tfield,\n\t\t\t\tdirection: DEFAULT_SORT_DIRECTION,\n\t\t\t};\n\t\t}\n\n\t\tProcessMonitorStore?.setValue({ field: \"sort\", value: newSort }, () => {\n\t\t\t// When changing sort we'll re-render the UI immediately instead of waiting for the process list to update. Without this step, it could be 999ms until the next update, which makes the process monitor feel very unresponsive and very bad.\n\t\t\tprocs = Actions.sortProcesses(procs);\n\t\t\tProcessMonitorStore?.setValue({ field: \"processList\", value: procs });\n\t\t});\n\t},\n\n\t/**\n\t * Extracts data from the process list (via the createDataModel function), and then sets the processList value on the store. This causes the UI to re-render.\n\t */\n\textractData: (processes: ProcessInfo[]) => {\n\t\tActions.createDataModel(processes, (procs) => {\n\t\t\t//set store.\n\t\t\tProcessMonitorStore?.setValue({ field: \"processList\", value: procs });\n\t\t});\n\t},\n\n\t/**\n\t * Converts the system.getProcessList response into something that's easily render-able.\n\t */\n\tcreateDataModel: (processes: ProcessInfo[], cb: (procs: ProcessType[]) => void) => {\n\t\tconst mode = ProcessMonitorStore?.getValue({ field: \"viewMode\" });\n\n\t\ttype WebContentsEntry = ProcessInfo[\"webContents\"][0];\n\n\t\tconst sortWindow = (a: { webContentsName: string }, b: { webContentsName: string }) => {\n\t\t\tif (a.webContentsName < b.webContentsName) return -1;\n\t\t\tif (a.webContentsName > b.webContentsName) return 1;\n\t\t\treturn 0;\n\t\t};\n\n\t\tconst viewOrWindowToProc = (item: WebContentsEntry) => {\n\t\t\treturn {\n\t\t\t\twebContentsName: item.webContentsName,\n\t\t\t\twindowName: item.windowName,\n\t\t\t\ttype: item.type,\n\t\t\t};\n\t\t};\n\n\t\tconst allowAdvanced = (item: WebContentsEntry) => {\n\t\t\tconst windowName: string = item.webContentsName.toLowerCase();\n\t\t\tconst windowIsService = windowName.includes(\"service\");\n\t\t\tconst windowIsSystem = windowName.includes(\"system\");\n\t\t\tconst windowIsUnnamed = windowName.includes(\"unnamed\");\n\t\t\tconst windowIsSimple = windowIsService || windowIsSystem || windowIsUnnamed;\n\t\t\treturn mode !== \"simple\" || !windowIsSimple;\n\t\t};\n\n\t\tconst procs: ProcessType[] = processes.map((proc) => {\n\t\t\tconst procName = proc.name.toLowerCase();\n\t\t\tconst isService = procName.includes(\"service\");\n\t\t\tconst isSystem = procName.includes(\"system\");\n\t\t\tconst isUnnamed = procName.includes(\"unnamed\");\n\t\t\tconst procIsSimple = isService || isSystem || isUnnamed;\n\t\t\tif (mode === \"simple\" && procIsSimple) {\n\t\t\t\treturn {\n\t\t\t\t\tstatistics: proc,\n\t\t\t\t\tvisible: false,\n\t\t\t\t};\n\t\t\t}\n\n\t\t\tconst childWindows: ChildWindowType[] = [...Object.values(proc.webContents)]\n\t\t\t\t.filter(allowAdvanced)\n\t\t\t\t.map(viewOrWindowToProc)\n\t\t\t\t.sort(sortWindow);\n\n\t\t\treturn {\n\t\t\t\tstatistics: proc,\n\t\t\t\tvisible: true,\n\t\t\t\ttype: proc.type,\n\t\t\t\tchildWindows,\n\t\t\t};\n\t\t});\n\n\t\tcb(Actions.sortProcesses(procs));\n\t},\n\n\t/**\n\t * Sorting function. Handles ascending and descending.\n\t */\n\tsortProcesses: (procs: ProcessType[]) => {\n\t\tlet currentSort: SortObjectType = ProcessMonitorStore?.getValue({ field: \"sort\" });\n\t\tlet sortFN = (a: ProcessType, b: ProcessType) => {\n\t\t\tlet aValue = a.statistics[currentSort.field];\n\t\t\tlet bValue = b.statistics[currentSort.field];\n\n\t\t\tif (typeof aValue === \"undefined\" || typeof bValue === \"undefined\") {\n\t\t\t\treturn 0;\n\t\t\t}\n\n\t\t\t//Comparing upper and lowercase names makes the sort look wrong. we equalize all strings here.\n\t\t\tif (typeof aValue === \"string\") {\n\t\t\t\taValue = aValue.toLowerCase();\n\t\t\t}\n\t\t\tif (typeof bValue === \"string\") {\n\t\t\t\tbValue = bValue.toLowerCase();\n\t\t\t}\n\n\t\t\tif (currentSort.direction === \"ascending\") {\n\t\t\t\tif (aValue < bValue) return -1;\n\t\t\t\tif (aValue > bValue) return 1;\n\t\t\t\treturn 0;\n\t\t\t}\n\n\t\t\tif (aValue > bValue) return -1;\n\t\t\tif (aValue < bValue) return 1;\n\t\t\treturn 0;\n\t\t};\n\t\treturn procs.sort(sortFN);\n\t},\n\n\t/**\n\t * Toggles advanced/simple mode\n\t */\n\ttoggleViewMode: () => {\n\t\tconst mode = ProcessMonitorStore?.getValue({ field: \"viewMode\" });\n\t\tProcessMonitorStore?.setValue({\n\t\t\tfield: \"viewMode\",\n\t\t\tvalue: mode === \"advanced\" ? \"simple\" : \"advanced\",\n\t\t});\n\t},\n\n\t/**\n\t * Gets the current \"flashing\" state - whether the process monitor is currently flashing a window\n\t */\n\tgetFlashingState: (cb?: StandardCallback) => {\n\t\tProcessMonitorStore?.getValue(\"flashing\", cb);\n\t},\n\n\t/**\n\t * Gets the current \"flashing\" state for the process monitor\n\t */\n\tsetFlashingState: (value: boolean, cb?: StandardCallback) => {\n\t\tProcessMonitorStore?.setValue({ field: \"flashing\", value }, cb);\n\t},\n\n\t/**\n\t * Make the window flash a couple of times so that the user can identify it.\n\t */\n\tidentifyWindow: function (winID: ChildWindowType) {\n\t\tif (winID.windowName.includes(\"Service\")) return;\n\n\t\tthis.setFlashingState(true);\n\n\t\tconst OPACITY_ANIMATION_DURATION = 200;\n\t\tFSBL.FinsembleWindow.getInstance({ name: winID.windowName }, (err: StandardError, win: FinsembleWindow) => {\n\t\t\tlet windowState = \"hidden\";\n\t\t\tfunction flash(n: any, done: any) {\n\t\t\t\tsetTimeout(() => {\n\t\t\t\t\twin.hide(() => {\n\t\t\t\t\t\tsetTimeout(() => {\n\t\t\t\t\t\t\twin.show(() => {\n\t\t\t\t\t\t\t\tdone(null);\n\t\t\t\t\t\t\t});\n\t\t\t\t\t\t}, OPACITY_ANIMATION_DURATION / 1.5);\n\t\t\t\t\t});\n\t\t\t\t}, OPACITY_ANIMATION_DURATION / 1.5);\n\t\t\t}\n\t\t\twin.isShowing({}, (error: StandardError, isVisible: boolean) => {\n\t\t\t\t//cache the visible state of the window prior to making it flash. If it was hidden before, hide it when the flashing is done.\n\t\t\t\twindowState = isVisible ? \"visible\" : \"hidden\";\n\t\t\t\twin.show(() => {\n\t\t\t\t\twin.bringToFront(() => {\n\t\t\t\t\t\t//Flash 5 times, in series.\n\t\t\t\t\t\tasync.timesSeries(5, flash, () => {\n\t\t\t\t\t\t\tif (windowState === \"hidden\") {\n\t\t\t\t\t\t\t\twin.hide();\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\tthis.setFlashingState(false);\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},\n\n\t/**\n\t * Terminates a process group. Containing windows for browser views will be closed.\n\t */\n\tterminateProcess: (webContents: ProcessType[\"statistics\"][\"webContents\"]) => {\n\t\tconst forceCloseProcess = () => {\n\t\t\tif (!webContents) return;\n\t\t\t// De-duped array of window names from both windows and browser views\n\t\t\tconst windowNames = new Set(Object.values(webContents).map((item) => item.windowName));\n\t\t\twindowNames.forEach((windowName) => {\n\t\t\t\tActions.closeWindow(windowName, true);\n\t\t\t});\n\t\t};\n\n\t\t//Ask user if they're sure. If they says \"yes\", close it.\n\t\tFSBL.Clients.DialogManager.open(\n\t\t\t\"yesNo\",\n\t\t\t{\n\t\t\t\ttitle: \"Terminate Process?\",\n\t\t\t\tquestion: \"Terminating the process may close other apps. Are you sure you want to continue?\",\n\t\t\t\taffirmativeResponseLabel: \"Terminate\",\n\t\t\t\tshowNegativeButton: false,\n\t\t\t},\n\t\t\t(err: StandardError, response: { choice: string }) => {\n\t\t\t\tif (err || response.choice === \"affirmative\") {\n\t\t\t\t\tforceCloseProcess();\n\t\t\t\t}\n\t\t\t}\n\t\t);\n\t},\n\n\t/**\n\t * This function exists to make the UI feel snappy. May take a second or so for the window to close properly and for the change to flow to system.getProcessList. To make that lag go away, we immediately render the change.\n\t */\n\tremoveWindowLocally: function (windowName: string) {\n\t\tlet procs: ProcessType[] = ProcessMonitorStore?.getValue({ field: \"processList\" });\n\t\tprocs = procs.map((proc) => {\n\t\t\tif (proc.childWindows) {\n\t\t\t\tconst cwIndex = proc.childWindows.findIndex((cw) => cw.windowName === windowName);\n\t\t\t\tproc.childWindows.splice(cwIndex, 1);\n\t\t\t}\n\t\t\treturn proc;\n\t\t});\n\t\tProcessMonitorStore?.setValue({ field: \"processList\", value: procs });\n\t},\n\n\t/**\n\t * Try to close the window. If that fails, try to force close the window. If that fails, ask if they'd like to terminate the parent process.\n\t */\n\tcloseWindow: function (windowName: string, force = false) {\n\t\tconst win = FSBL.System.Window.wrap(windowName);\n\n\t\tconst onCloseFailure = () => {\n\t\t\t//If Actions.closeWindow was called with force === true, and the close failed.\n\t\t\tif (force) {\n\t\t\t\talert(\"Cannot close window\");\n\t\t\t} else {\n\t\t\t\tActions.closeWindow(windowName, true);\n\t\t\t}\n\t\t};\n\n\t\t//If we can't close within 4 seconds, something's wrong - try to force close it.\n\t\tconst closeTimeout = setTimeout(() => {\n\t\t\tonCloseFailure();\n\t\t}, MAGIC_NUMBER_TERMINATION_TIMEOUT);\n\n\t\tconst onCloseSuccess = () => {\n\t\t\tActions.removeWindowLocally(windowName);\n\t\t\tclearTimeout(closeTimeout);\n\t\t};\n\n\t\twin.close(force, onCloseSuccess, onCloseFailure);\n\t},\n};\n\nexport { ProcessMonitorStore as Store, Actions };\n"]}
|
|
@@ -1,4 +1,7 @@
|
|
|
1
1
|
/// <reference types="react" />
|
|
2
2
|
import "../../assets/css/dialogs.css";
|
|
3
3
|
import "./quickComponent.css";
|
|
4
|
+
/**
|
|
5
|
+
* A form that allows the user to add a quick component. It provides one field for the name of the quick component, and another field for its URL.
|
|
6
|
+
*/
|
|
4
7
|
export declare const QuickComponentForm: () => JSX.Element;
|
|
@@ -6,6 +6,7 @@ import "../../assets/css/dialogs.css";
|
|
|
6
6
|
import "./quickComponent.css";
|
|
7
7
|
import { isValidURL } from "../shared/validateURL";
|
|
8
8
|
import { addProtocolToValidURL } from "../shared/addProtocolToValidURL";
|
|
9
|
+
// @deprecated - Quick Components will be removed in a future version
|
|
9
10
|
class QuickComponentFormBase extends React.Component {
|
|
10
11
|
constructor(props) {
|
|
11
12
|
super(props);
|
|
@@ -20,6 +21,9 @@ class QuickComponentFormBase extends React.Component {
|
|
|
20
21
|
this.setURL = this.setURL.bind(this);
|
|
21
22
|
this.onkeydown = this.onkeydown.bind(this);
|
|
22
23
|
}
|
|
24
|
+
/**
|
|
25
|
+
* Adds eventListeners on keydown, sets the height of the component.
|
|
26
|
+
*/
|
|
23
27
|
componentDidMount() {
|
|
24
28
|
FSBL.Clients.WindowClient.fitToDOM();
|
|
25
29
|
document.body.addEventListener("keydown", this.onkeydown);
|
|
@@ -28,6 +32,9 @@ class QuickComponentFormBase extends React.Component {
|
|
|
28
32
|
componentWillUnmount() {
|
|
29
33
|
document.body.removeEventListener("keydown", this.onkeydown);
|
|
30
34
|
}
|
|
35
|
+
/**
|
|
36
|
+
* Matches the enter and escape keys with the corresponding function to invoke.
|
|
37
|
+
*/
|
|
31
38
|
onkeydown(e) {
|
|
32
39
|
if (e.code === "Enter" && e.shiftKey === false) {
|
|
33
40
|
this.save();
|
|
@@ -36,9 +43,15 @@ class QuickComponentFormBase extends React.Component {
|
|
|
36
43
|
this.cancel();
|
|
37
44
|
}
|
|
38
45
|
}
|
|
46
|
+
/**
|
|
47
|
+
* Hides the window when the save button is clicked.
|
|
48
|
+
*/
|
|
39
49
|
hideWindow() {
|
|
40
50
|
finsembleWindow.hide();
|
|
41
51
|
}
|
|
52
|
+
/**
|
|
53
|
+
* Persists the quick component to storage.
|
|
54
|
+
*/
|
|
42
55
|
save() {
|
|
43
56
|
if (!this.state)
|
|
44
57
|
return FSBL.Clients.DialogManager.respondToOpener({});
|
|
@@ -58,6 +71,7 @@ class QuickComponentFormBase extends React.Component {
|
|
|
58
71
|
if (err) {
|
|
59
72
|
console.error(err);
|
|
60
73
|
}
|
|
74
|
+
// FSBL.Clients.WindowClient.close(false);
|
|
61
75
|
FSBL.Clients.DialogManager.respondToOpener({});
|
|
62
76
|
});
|
|
63
77
|
Array.from(document.querySelectorAll("input")).forEach((el) => (el.value = ""));
|
|
@@ -66,6 +80,9 @@ class QuickComponentFormBase extends React.Component {
|
|
|
66
80
|
url: "",
|
|
67
81
|
});
|
|
68
82
|
}
|
|
83
|
+
/**
|
|
84
|
+
* Kills the window.
|
|
85
|
+
*/
|
|
69
86
|
cancel() {
|
|
70
87
|
Array.from(document.querySelectorAll("input")).forEach((el) => (el.value = ""));
|
|
71
88
|
FSBL.Clients.DialogManager.respondToOpener({});
|
|
@@ -90,5 +107,8 @@ class QuickComponentFormBase extends React.Component {
|
|
|
90
107
|
React.createElement(FinsembleDialogButton, { className: "fsbl-button-affirmative", onClick: this.save, show: true }, "Confirm"))));
|
|
91
108
|
}
|
|
92
109
|
}
|
|
110
|
+
/**
|
|
111
|
+
* A form that allows the user to add a quick component. It provides one field for the name of the quick component, and another field for its URL.
|
|
112
|
+
*/
|
|
93
113
|
export const QuickComponentForm = () => React.createElement(QuickComponentFormBase, null);
|
|
94
114
|
//# sourceMappingURL=QuickComponentForm.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"QuickComponentForm.js","sourceRoot":"","sources":["../../../src/components/quickComponentForm/QuickComponentForm.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,MAAM,OAAO,CAAC;AAC1B,OAAO,EAAE,eAAe,EAAE,MAAM,mCAAmC,CAAC;AACpE,OAAO,EAAE,wBAAwB,EAAE,MAAM,4CAA4C,CAAC;AACtF,OAAO,EAAE,qBAAqB,EAAE,MAAM,yCAAyC,CAAC;AAChF,OAAO,8BAA8B,CAAC;AACtC,OAAO,sBAAsB,CAAC;AAC9B,OAAO,EAAE,UAAU,EAAE,MAAM,uBAAuB,CAAC;AACnD,OAAO,EAAE,qBAAqB,EAAE,MAAM,iCAAiC,CAAC;
|
|
1
|
+
{"version":3,"file":"QuickComponentForm.js","sourceRoot":"","sources":["../../../src/components/quickComponentForm/QuickComponentForm.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,MAAM,OAAO,CAAC;AAC1B,OAAO,EAAE,eAAe,EAAE,MAAM,mCAAmC,CAAC;AACpE,OAAO,EAAE,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AAS,EAAC,cAAc,yCAAyC;YACtE,oBAAC,wBAAwB,IACxB,aAAa,EAAE,IAAI,CAAC,OAAO,EAC3B,WAAW,EAAC,MAAM,EAClB,SAAS,QACT,KAAK,EAAE,IAAI,CAAC,KAAK,CAAC,IAAI,EACtB,WAAW,EAAE,IAAI,GAChB;YACF,oBAAC,wBAAwB,IACxB,aAAa,EAAE,IAAI,CAAC,MAAM,EAC1B,WAAW,EAAC,KAAK,EACjB,KAAK,EAAE,IAAI,CAAC,KAAK,CAAC,GAAG,EACrB,SAAS,EAAE,KAAK,GACf;YACF,6BAAK,SAAS,EAAC,gBAAgB;gBAC9B,oBAAC,qBAAqB,IAAC,SAAS,EAAC,qBAAqB,EAAC,OAAO,EAAE,IAAI,CAAC,MAAM,EAAE,IAAI,EAAE,IAAI,aAE/D;gBAExB,oBAAC,qBAAqB,IAAC,SAAS,EAAC,yBAAyB,EAAC,OAAO,EAAE,IAAI,CAAC,IAAI,EAAE,IAAI,EAAE,IAAI,cAEjE,CACnB,CACW,CAClB,CAAC;IACH,CAAC;CACD;AAED;;GAEG;AACH,MAAM,CAAC,MAAM,kBAAkB,GAAG,GAAG,EAAE,CAAC,oBAAC,sBAAsB,OAAG,CAAC","sourcesContent":["import React from \"react\";\nimport { FinsembleDialog } from \"../legacyControls/FinsembleDialog\";\nimport { FinsembleDialogTextInput } from \"../legacyControls/FinsembleDialogTextInput\";\nimport { FinsembleDialogButton } from \"../legacyControls/FinsembleDialogButton\";\nimport \"../../assets/css/dialogs.css\";\nimport \"./quickComponent.css\";\nimport { isValidURL } from \"../shared/validateURL\";\nimport { addProtocolToValidURL } from \"../shared/addProtocolToValidURL\";\n\ninterface IProps {}\n\ninterface IState {\n\tname: string;\n\turl: string;\n}\n\n// @deprecated - Quick Components will be removed in a future version\nclass QuickComponentFormBase extends React.Component<IProps, IState> {\n\tconstructor(props: IProps) {\n\t\tsuper(props);\n\t\tFSBL.Clients.Logger.system.deprecated(\n\t\t\t\"Quick Components have been deprecated and will not be available in a future release.\"\n\t\t);\n\t\tthis.state = {\n\t\t\tname: \"\",\n\t\t\turl: \"\",\n\t\t};\n\t\tthis.save = this.save.bind(this);\n\t\tthis.cancel = this.cancel.bind(this);\n\t\tthis.setName = this.setName.bind(this);\n\t\tthis.setURL = this.setURL.bind(this);\n\t\tthis.onkeydown = this.onkeydown.bind(this);\n\t}\n\n\t/**\n\t * Adds eventListeners on keydown, sets the height of the component.\n\t */\n\tcomponentDidMount() {\n\t\tFSBL.Clients.WindowClient.fitToDOM();\n\t\tdocument.body.addEventListener(\"keydown\", this.onkeydown);\n\t\tFSBL.Clients.WindowClient.setAlwaysOnTop(true);\n\t}\n\n\tcomponentWillUnmount() {\n\t\tdocument.body.removeEventListener(\"keydown\", this.onkeydown);\n\t}\n\n\t/**\n\t * Matches the enter and escape keys with the corresponding function to invoke.\n\t */\n\tonkeydown(e: KeyboardEvent) {\n\t\tif (e.code === \"Enter\" && e.shiftKey === false) {\n\t\t\tthis.save();\n\t\t}\n\n\t\tif (e.code === \"Escape\") {\n\t\t\tthis.cancel();\n\t\t}\n\t}\n\n\t/**\n\t * Hides the window when the save button is clicked.\n\t */\n\thideWindow() {\n\t\tfinsembleWindow.hide();\n\t}\n\n\t/**\n\t * Persists the quick component to storage.\n\t */\n\tsave() {\n\t\tif (!this.state) return FSBL.Clients.DialogManager.respondToOpener({});\n\t\tlet { name, url } = this.state;\n\t\tif (!name || !url) return FSBL.Clients.DialogManager.respondToOpener({});\n\n\t\tif (!isValidURL(url)) {\n\t\t\treturn FSBL.Clients.DialogManager.respondToOpener({\n\t\t\t\terror: \"Invalid URL\",\n\t\t\t});\n\t\t}\n\t\tconst urlWithProtocol = addProtocolToValidURL(url);\n\n\t\tFSBL.Clients.LauncherClient.addUserDefinedComponent(\n\t\t\t{\n\t\t\t\tname: name,\n\t\t\t\turl: urlWithProtocol,\n\t\t\t},\n\t\t\t(err: Error | string | null | undefined) => {\n\t\t\t\tif (err) {\n\t\t\t\t\tconsole.error(err);\n\t\t\t\t}\n\t\t\t\t// FSBL.Clients.WindowClient.close(false);\n\t\t\t\tFSBL.Clients.DialogManager.respondToOpener({});\n\t\t\t}\n\t\t);\n\t\tArray.from(document.querySelectorAll(\"input\")).forEach((el) => (el.value = \"\"));\n\t\tthis.setState({\n\t\t\tname: \"\",\n\t\t\turl: \"\",\n\t\t});\n\t}\n\n\t/**\n\t * Kills the window.\n\t */\n\tcancel() {\n\t\tArray.from(document.querySelectorAll(\"input\")).forEach((el) => (el.value = \"\"));\n\n\t\tFSBL.Clients.DialogManager.respondToOpener({});\n\t}\n\n\tsetName(e: React.ChangeEvent<HTMLInputElement>) {\n\t\tthis.setState({ name: e.target.value });\n\t}\n\n\tsetURL(e: React.ChangeEvent<HTMLInputElement>) {\n\t\tthis.setState({ url: e.target.value });\n\t}\n\n\trender() {\n\t\treturn (\n\t\t\t<FinsembleDialog\n\t\t\t\tbehaviorOnResponse=\"hide\"\n\t\t\t\tonShowRequested={() => {\n\t\t\t\t\tFSBL.Clients.WindowClient.fitToDOM(null, () => {\n\t\t\t\t\t\tFSBL.Clients.DialogManager.showDialog();\n\t\t\t\t\t});\n\t\t\t\t}}\n\t\t\t\tisModal={true}\n\t\t\t>\n\t\t\t\t<div className=\"dialog-title\">Enter a name and URL for your app.</div>\n\t\t\t\t<FinsembleDialogTextInput\n\t\t\t\t\tonInputChange={this.setName}\n\t\t\t\t\tplaceholder=\"Name\"\n\t\t\t\t\tautoFocus\n\t\t\t\t\tvalue={this.state.name}\n\t\t\t\t\tfocusOnShow={true}\n\t\t\t\t/>\n\t\t\t\t<FinsembleDialogTextInput\n\t\t\t\t\tonInputChange={this.setURL}\n\t\t\t\t\tplaceholder=\"URL\"\n\t\t\t\t\tvalue={this.state.url}\n\t\t\t\t\tautoFocus={false}\n\t\t\t\t/>\n\t\t\t\t<div className=\"button-wrapper\">\n\t\t\t\t\t<FinsembleDialogButton className=\"fsbl-button-neutral\" onClick={this.cancel} show={true}>\n\t\t\t\t\t\tCancel\n\t\t\t\t\t</FinsembleDialogButton>\n\n\t\t\t\t\t<FinsembleDialogButton className=\"fsbl-button-affirmative\" onClick={this.save} show={true}>\n\t\t\t\t\t\tConfirm\n\t\t\t\t\t</FinsembleDialogButton>\n\t\t\t\t</div>\n\t\t\t</FinsembleDialog>\n\t\t);\n\t}\n}\n\n/**\n * A form that allows the user to add a quick component. It provides one field for the name of the quick component, and another field for its URL.\n */\nexport const QuickComponentForm = () => <QuickComponentFormBase />;\n"]}
|
|
@@ -8,8 +8,10 @@ export declare type AddAppProps = {
|
|
|
8
8
|
checkValidURL: (url: string) => boolean;
|
|
9
9
|
addAppByUrl: (url: string, name: string) => void;
|
|
10
10
|
addAppByPath: (path: string, name: string, apiAccess: boolean) => void;
|
|
11
|
-
addAppCitrix: (alias: string, name: string) => void;
|
|
12
11
|
close: () => void;
|
|
13
12
|
show: boolean;
|
|
13
|
+
addAppCitrix?: (alias: string, name: string) => void;
|
|
14
|
+
includeCitrix?: boolean;
|
|
15
|
+
idKey?: string;
|
|
14
16
|
};
|
|
15
|
-
export declare const AddApp: (
|
|
17
|
+
export declare const AddApp: ({ checkValidURL, addAppByPath, addAppByUrl, addAppCitrix, close, show, includeCitrix, idKey, }: AddAppProps) => JSX.Element;
|