@launchdarkly/toolbar 2.0.0-beta.1 → 2.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/README.md +7 -5
- package/cdn/toolbar.min.js +984 -10
- package/cdn/toolbar.min.js.LICENSE.txt +14 -0
- package/dist/core/services/DevServerClient.d.ts +10 -8
- package/dist/core/services/FlagStateManager.d.ts +2 -0
- package/dist/core/tests/mocks/providers.d.ts +132 -0
- package/dist/core/types/devServer.d.ts +2 -3
- package/dist/core/ui/{Toolbar/components → Buttons}/IconButton.d.ts +2 -1
- package/dist/core/ui/{Toolbar/components → Buttons}/StarButton.css.d.ts +1 -0
- package/dist/core/ui/JsonEditor/JsonEditor.d.ts +2 -1
- package/dist/core/ui/Toolbar/LaunchDarklyToolbar.d.ts +0 -1
- package/dist/core/ui/Toolbar/components/{AuthenticationModal.d.ts → AuthenticationModal/AuthenticationModal.d.ts} +1 -1
- package/dist/core/ui/Toolbar/components/CopyableText.css.d.ts +4 -0
- package/dist/core/ui/Toolbar/components/CopyableText.d.ts +18 -0
- package/dist/core/ui/Toolbar/components/FilterOptions/FilterOptions.css.d.ts +1 -0
- package/dist/core/ui/Toolbar/components/FilterOptions/FilterOptions.d.ts +1 -0
- package/dist/core/ui/Toolbar/components/FilterOptions/ShareUrlButton.css.d.ts +2 -0
- package/dist/core/ui/Toolbar/components/FilterOptions/ShareUrlButton.d.ts +7 -0
- package/dist/core/ui/Toolbar/components/LoadingScreen/LoadingScreen.css.d.ts +7 -0
- package/dist/core/ui/Toolbar/components/LoadingScreen/LoadingScreen.d.ts +5 -0
- package/dist/core/ui/Toolbar/components/LoadingScreen/index.d.ts +1 -0
- package/dist/core/ui/Toolbar/components/ShareStatePopover/ShareStatePopover.css.d.ts +10 -0
- package/dist/core/ui/Toolbar/components/ShareStatePopover/ShareStatePopover.d.ts +15 -0
- package/dist/core/ui/Toolbar/components/ShareStatePopover/index.d.ts +2 -0
- package/dist/core/ui/Toolbar/components/icons/ChartHistogram.d.ts +5 -0
- package/dist/core/ui/Toolbar/components/icons/ChipAiIcon.d.ts +5 -0
- package/dist/core/ui/Toolbar/components/icons/ClickIcon.d.ts +5 -0
- package/dist/core/ui/Toolbar/components/icons/CursorIcon.d.ts +7 -0
- package/dist/core/ui/Toolbar/components/icons/ExternalLinkIcon.d.ts +6 -0
- package/dist/core/ui/Toolbar/components/icons/FilterTuneIcon.d.ts +5 -0
- package/dist/core/ui/Toolbar/components/icons/FlaskIcon.d.ts +5 -0
- package/dist/core/ui/Toolbar/components/icons/Icon.css.d.ts +1 -0
- package/dist/core/ui/Toolbar/components/icons/InfoIcon.d.ts +5 -0
- package/dist/core/ui/Toolbar/components/icons/ShareIcon.d.ts +5 -0
- package/dist/core/ui/Toolbar/components/icons/index.d.ts +10 -0
- package/dist/core/ui/Toolbar/components/index.d.ts +3 -4
- package/dist/core/ui/Toolbar/components/{ExpandedToolbarContent.d.ts → legacy/ExpandedToolbarContentLegacy.d.ts} +4 -3
- package/dist/core/ui/Toolbar/components/{FlagControls.d.ts → legacy/FlagControls.d.ts} +1 -1
- package/dist/core/ui/Toolbar/{Header → components/legacy/Header}/Header.d.ts +1 -1
- package/dist/core/ui/Toolbar/components/{LocalFlagControls.d.ts → legacy/LocalFlagControls.d.ts} +2 -2
- package/dist/core/ui/Toolbar/components/{LocalObjectFlagControlListItem.d.ts → legacy/LocalObjectFlagControlListItem.d.ts} +2 -2
- package/dist/core/ui/Toolbar/{TabContent → components/legacy/TabContent}/EventsTabContent.d.ts +1 -1
- package/dist/core/ui/Toolbar/{TabContent → components/legacy/TabContent}/FlagSdkOverrideTabContent.d.ts +1 -1
- package/dist/core/ui/Toolbar/{TabContent → components/legacy/TabContent}/SettingsTabContent.d.ts +1 -1
- package/dist/core/ui/Toolbar/components/{TabContentRenderer.d.ts → legacy/TabContentRenderer.d.ts} +2 -2
- package/dist/core/ui/Toolbar/components/legacy/index.d.ts +1 -0
- package/dist/core/ui/Toolbar/components/new/AnalyticsConsentToast/AnalyticsConsentToast.d.ts +5 -0
- package/dist/core/ui/Toolbar/components/new/AnalyticsConsentToast/AnalyticsConsentToast.module.css.d.ts +13 -0
- package/dist/core/ui/Toolbar/components/new/AnalyticsConsentToast/index.d.ts +1 -0
- package/dist/core/ui/Toolbar/components/new/ContentActions.d.ts +1 -0
- package/dist/core/ui/Toolbar/components/new/ContentActions.module.css.d.ts +8 -0
- package/dist/core/ui/Toolbar/components/new/ContentRenderer.d.ts +1 -0
- package/dist/core/ui/Toolbar/components/new/Contexts/AddContextForm.d.ts +6 -0
- package/dist/core/ui/Toolbar/components/new/Contexts/AddContextForm.module.css.d.ts +14 -0
- package/dist/core/ui/Toolbar/components/new/Contexts/ContextItem.d.ts +9 -0
- package/dist/core/ui/Toolbar/components/new/Contexts/ContextItem.module.css.d.ts +19 -0
- package/dist/core/ui/Toolbar/components/new/Contexts/ContextList.d.ts +1 -0
- package/dist/core/ui/Toolbar/components/new/Contexts/ContextList.module.css.d.ts +8 -0
- package/dist/core/ui/Toolbar/components/new/Contexts/ContextListContent.d.ts +1 -0
- package/dist/core/ui/Toolbar/components/new/Contexts/index.d.ts +4 -0
- package/dist/core/ui/Toolbar/components/new/ExpandedToolbarContent.d.ts +10 -0
- package/dist/core/ui/Toolbar/components/new/ExpandedToolbarContent.module.css.d.ts +2 -0
- package/dist/core/ui/Toolbar/components/new/FeatureFlags/FlagControls.d.ts +37 -0
- package/dist/core/ui/Toolbar/components/new/FeatureFlags/FlagControls.module.css.d.ts +9 -0
- package/dist/core/ui/Toolbar/components/new/FeatureFlags/FlagItem.d.ts +12 -0
- package/dist/core/ui/Toolbar/components/new/FeatureFlags/FlagItem.module.css.d.ts +18 -0
- package/dist/core/ui/Toolbar/components/new/FeatureFlags/FlagList.d.ts +1 -0
- package/dist/core/ui/Toolbar/components/new/FeatureFlags/FlagList.module.css.d.ts +5 -0
- package/dist/core/ui/Toolbar/components/new/FeatureFlags/FlagListContent.d.ts +1 -0
- package/dist/core/ui/Toolbar/components/new/FeatureFlags/types.d.ts +9 -0
- package/dist/core/ui/Toolbar/components/new/FilterOverlay/FilterOverlay.d.ts +11 -0
- package/dist/core/ui/Toolbar/components/new/FilterOverlay/FilterOverlay.module.css.d.ts +17 -0
- package/dist/core/ui/Toolbar/components/new/FilterOverlay/index.d.ts +1 -0
- package/dist/core/ui/Toolbar/components/new/Header/ToolbarHeader.d.ts +7 -0
- package/dist/core/ui/Toolbar/components/new/Header/ToolbarHeader.module.css.d.ts +6 -0
- package/dist/core/ui/Toolbar/components/new/IconBar/IconBar.d.ts +6 -0
- package/dist/core/ui/Toolbar/components/new/IconBar/IconBar.module.css.d.ts +6 -0
- package/dist/core/ui/Toolbar/components/new/Interactive/InteractiveContent.d.ts +1 -0
- package/dist/core/ui/Toolbar/components/new/Interactive/InteractiveContent.module.css.d.ts +4 -0
- package/dist/core/ui/Toolbar/components/new/Interactive/InteractiveWrapper.d.ts +10 -0
- package/dist/core/ui/Toolbar/components/new/Interactive/MCPSetupAlert.d.ts +10 -0
- package/dist/core/ui/Toolbar/components/new/Interactive/MCPSetupAlert.module.css.d.ts +12 -0
- package/dist/core/ui/Toolbar/components/new/Interactive/SelectedElementInfo.d.ts +1 -0
- package/dist/core/ui/Toolbar/components/new/Interactive/SelectedElementInfo.module.css.d.ts +21 -0
- package/dist/core/ui/Toolbar/components/new/Interactive/SelectionModeBar.d.ts +1 -0
- package/dist/core/ui/Toolbar/components/new/Interactive/SelectionOverlay.d.ts +2 -0
- package/dist/core/ui/Toolbar/components/new/Interactive/WorkflowCard.d.ts +13 -0
- package/dist/core/ui/Toolbar/components/new/Interactive/WorkflowCard.module.css.d.ts +27 -0
- package/dist/core/ui/Toolbar/components/new/Interactive/WorkflowSection.d.ts +6 -0
- package/dist/core/ui/Toolbar/components/new/Interactive/WorkflowSection.module.css.d.ts +5 -0
- package/dist/core/ui/Toolbar/components/new/Interactive/index.d.ts +9 -0
- package/dist/core/ui/Toolbar/components/new/Interactive/utils/elementUtils.d.ts +56 -0
- package/dist/core/ui/Toolbar/components/new/Interactive/utils/ideLinks.d.ts +58 -0
- package/dist/core/ui/Toolbar/components/new/Interactive/utils/promptBuilder.d.ts +26 -0
- package/dist/core/ui/Toolbar/components/new/Interactive/utils/throttle.d.ts +10 -0
- package/dist/core/ui/Toolbar/components/new/Interactive/workflowConfigs.d.ts +36 -0
- package/dist/core/ui/Toolbar/components/new/Monitoring/EventsContent.d.ts +1 -0
- package/dist/core/ui/Toolbar/components/new/Monitoring/EventsContent.module.css.d.ts +25 -0
- package/dist/core/ui/Toolbar/components/new/SearchSection.d.ts +8 -0
- package/dist/core/ui/Toolbar/components/new/SearchSection.module.css.d.ts +3 -0
- package/dist/core/ui/Toolbar/components/new/Settings/ConnectionStatus.d.ts +5 -0
- package/dist/core/ui/Toolbar/components/new/Settings/ConnectionStatus.module.css.d.ts +6 -0
- package/dist/core/ui/Toolbar/components/new/Settings/EnvironmentSelector.d.ts +1 -0
- package/dist/core/ui/Toolbar/components/new/Settings/GeneralSettings.d.ts +1 -0
- package/dist/core/ui/Toolbar/components/new/Settings/LogoutButton.d.ts +1 -0
- package/dist/core/ui/Toolbar/components/new/Settings/LogoutButton.module.css.d.ts +1 -0
- package/dist/core/ui/Toolbar/components/new/Settings/PositionSelector.d.ts +6 -0
- package/dist/core/ui/Toolbar/components/new/Settings/Privacy/PrivacySettings.d.ts +1 -0
- package/dist/core/ui/Toolbar/components/new/Settings/ProjectSelector.d.ts +1 -0
- package/dist/core/ui/Toolbar/components/new/Settings/SettingsContent.module.css.d.ts +5 -0
- package/dist/core/ui/Toolbar/components/new/Settings/SettingsItem.d.ts +8 -0
- package/dist/core/ui/Toolbar/components/new/Settings/SettingsItem.module.css.d.ts +6 -0
- package/dist/core/ui/Toolbar/components/new/Settings/SettingsSection.d.ts +7 -0
- package/dist/core/ui/Toolbar/components/new/Settings/SettingsSection.module.css.d.ts +3 -0
- package/dist/core/ui/Toolbar/components/new/Settings/ShareButton.d.ts +5 -0
- package/dist/core/ui/Toolbar/components/new/Settings/ShareButton.module.css.d.ts +1 -0
- package/dist/core/ui/Toolbar/components/new/Settings/index.d.ts +8 -0
- package/dist/core/ui/Toolbar/components/new/SubtabDropdown.d.ts +8 -0
- package/dist/core/ui/Toolbar/components/new/SubtabDropdown.module.css.d.ts +10 -0
- package/dist/core/ui/Toolbar/components/new/TabBar.d.ts +1 -0
- package/dist/core/ui/Toolbar/components/new/TabBar.module.css.d.ts +4 -0
- package/dist/core/ui/Toolbar/components/new/Tooltip.d.ts +9 -0
- package/dist/core/ui/Toolbar/components/new/Tooltip.module.css.d.ts +2 -0
- package/dist/core/ui/Toolbar/components/new/context/ActiveSubtabProvider.d.ts +12 -0
- package/dist/core/ui/Toolbar/components/new/context/FiltersProvider.d.ts +41 -0
- package/dist/core/ui/Toolbar/components/new/context/TabSearchProvider.d.ts +12 -0
- package/dist/core/ui/Toolbar/components/new/context/index.d.ts +3 -0
- package/dist/core/ui/Toolbar/components/new/index.d.ts +10 -0
- package/dist/core/ui/Toolbar/components/new/types.d.ts +16 -0
- package/dist/core/ui/Toolbar/constants/animations.d.ts +14 -0
- package/dist/core/ui/Toolbar/constants/virtualization.d.ts +1 -0
- package/dist/core/ui/Toolbar/context/DevServerProvider.d.ts +2 -0
- package/dist/core/ui/Toolbar/context/ElementSelectionProvider.d.ts +52 -0
- package/dist/core/ui/Toolbar/context/FlagSdkOverrideProvider.d.ts +5 -1
- package/dist/core/ui/Toolbar/context/api/ApiBundleProvider.d.ts +8 -0
- package/dist/core/ui/Toolbar/context/{ApiProvider.d.ts → api/ApiProvider.d.ts} +1 -2
- package/dist/core/ui/Toolbar/context/{AuthProvider.d.ts → api/AuthProvider.d.ts} +3 -3
- package/dist/core/ui/Toolbar/context/api/ContextsProvider.d.ts +19 -0
- package/dist/core/ui/Toolbar/context/api/EnvironmentProvider.d.ts +12 -0
- package/dist/core/ui/Toolbar/context/{FlagsProvider.d.ts → api/FlagsProvider.d.ts} +5 -4
- package/dist/core/ui/Toolbar/context/{ProjectProvider.d.ts → api/ProjectProvider.d.ts} +4 -3
- package/dist/core/ui/Toolbar/context/api/index.d.ts +8 -0
- package/dist/core/ui/Toolbar/context/index.d.ts +7 -7
- package/dist/core/ui/Toolbar/context/{ActiveTabProvider.d.ts → state/ActiveTabProvider.d.ts} +3 -3
- package/dist/core/ui/Toolbar/context/state/PluginsProvider.d.ts +16 -0
- package/dist/core/ui/Toolbar/context/{SearchProvider.d.ts → state/SearchProvider.d.ts} +2 -2
- package/dist/core/ui/Toolbar/context/state/ToolbarStateBundleProvider.d.ts +13 -0
- package/dist/core/ui/Toolbar/context/state/ToolbarStateProvider.d.ts +35 -0
- package/dist/core/ui/Toolbar/context/{ToolbarUIProvider.d.ts → state/ToolbarUIProvider.d.ts} +1 -1
- package/dist/core/ui/Toolbar/context/state/index.d.ts +6 -0
- package/dist/core/ui/Toolbar/context/telemetry/AnalyticsPreferencesProvider.d.ts +14 -0
- package/dist/core/ui/Toolbar/context/{AnalyticsProvider.d.ts → telemetry/AnalyticsProvider.d.ts} +2 -2
- package/dist/core/ui/Toolbar/context/{InternalClientProvider.d.ts → telemetry/InternalClientProvider.d.ts} +15 -1
- package/dist/core/ui/Toolbar/context/telemetry/TelemetryBundleProvider.d.ts +13 -0
- package/dist/core/ui/Toolbar/context/telemetry/index.d.ts +4 -0
- package/dist/core/ui/Toolbar/hooks/index.d.ts +2 -1
- package/dist/core/ui/Toolbar/hooks/useLocalStorage.d.ts +10 -0
- package/dist/core/ui/Toolbar/hooks/useReducedMotion.d.ts +5 -0
- package/dist/core/ui/Toolbar/hooks/useToolbarAnimations.d.ts +1 -1
- package/dist/core/ui/Toolbar/types/toolbar.d.ts +3 -2
- package/dist/core/ui/Toolbar/utils/clipboard.d.ts +6 -0
- package/dist/core/ui/Toolbar/utils/context.d.ts +33 -0
- package/dist/core/ui/Toolbar/utils/localStorage.d.ts +29 -1
- package/dist/core/utils/analytics.d.ts +56 -2
- package/dist/core/utils/feedback.d.ts +18 -0
- package/dist/core/utils/urlOverrides.d.ts +105 -0
- package/dist/flags/toolbarFlags.d.ts +7 -1
- package/dist/index.cjs +8 -6
- package/dist/index.cjs.map +1 -1
- package/dist/js/263.js +88 -0
- package/dist/js/263.js.map +1 -0
- package/dist/js/758.js +446 -0
- package/dist/js/758.js.map +1 -0
- package/dist/js/index.js +3 -527
- package/dist/js/index.js.map +1 -1
- package/dist/js/plugins.js +1 -0
- package/dist/js/react.js +1 -0
- package/dist/js/types-entry.js +0 -0
- package/dist/plugins.cjs +483 -0
- package/dist/plugins.cjs.map +1 -0
- package/dist/plugins.d.ts +21 -0
- package/dist/react/useLaunchDarklyToolbar.d.ts +1 -1
- package/dist/react.cjs +125 -0
- package/dist/react.cjs.map +1 -0
- package/dist/react.d.ts +25 -0
- package/dist/types-entry.cjs +20 -0
- package/dist/types-entry.cjs.map +1 -0
- package/dist/types-entry.d.ts +12 -0
- package/package.json +98 -50
- package/dist/core/ui/Toolbar/components/Popover.css.d.ts +0 -2
- package/dist/core/ui/Toolbar/hooks/useToolbarState.d.ts +0 -25
- package/dist/core/ui/{Toolbar/components → Buttons}/IconButton.css.d.ts +0 -0
- package/dist/core/ui/{Toolbar/components → Buttons}/IconLinkButton.d.ts +0 -0
- package/dist/core/ui/{Toolbar/components → Buttons}/StarButton.d.ts +0 -0
- package/dist/core/ui/{Toolbar/components → Select}/Select.css.d.ts +0 -0
- package/dist/core/ui/{Toolbar/components → Select}/Select.d.ts +0 -0
- package/dist/core/ui/Toolbar/components/{AuthenticationModal.css.d.ts → AuthenticationModal/AuthenticationModal.css.d.ts} +0 -0
- package/dist/core/ui/Toolbar/components/{LoginScreen.css.d.ts → LoginScreen/LoginScreen.css.d.ts} +0 -0
- package/dist/core/ui/Toolbar/components/{LoginScreen.d.ts → LoginScreen/LoginScreen.d.ts} +0 -0
- package/dist/core/ui/Toolbar/components/{ActionButtonsContainer.css.d.ts → legacy/ActionButtonsContainer.css.d.ts} +0 -0
- package/dist/core/ui/Toolbar/components/{ActionButtonsContainer.d.ts → legacy/ActionButtonsContainer.d.ts} +0 -0
- package/dist/core/ui/Toolbar/components/{FlagControls.css.d.ts → legacy/FlagControls.css.d.ts} +0 -0
- package/dist/core/ui/Toolbar/{Header → components/legacy/Header}/Header.css.d.ts +0 -0
- package/dist/core/ui/Toolbar/{Header → components/legacy/Header}/components/ActionButtons.d.ts +0 -0
- package/dist/core/ui/Toolbar/{Header → components/legacy/Header}/components/EnvironmentLabel.d.ts +0 -0
- package/dist/core/ui/Toolbar/{Header → components/legacy/Header}/components/LogoSection.d.ts +0 -0
- package/dist/core/ui/Toolbar/{Header → components/legacy/Header}/components/SearchSection.d.ts +0 -0
- package/dist/core/ui/Toolbar/{Header → components/legacy/Header}/components/index.d.ts +1 -1
- /package/dist/core/ui/Toolbar/components/{LocalFlagControls.css.d.ts → legacy/LocalFlagControls.css.d.ts} +0 -0
- /package/dist/core/ui/Toolbar/components/{LocalObjectFlagControlListItem.css.d.ts → legacy/LocalObjectFlagControlListItem.css.d.ts} +0 -0
- /package/dist/core/ui/Toolbar/{TabContent → components/legacy/TabContent}/EventsTabContent.css.d.ts +0 -0
- /package/dist/core/ui/Toolbar/{TabContent → components/legacy/TabContent}/FlagDevServerTabContent.css.d.ts +0 -0
- /package/dist/core/ui/Toolbar/{TabContent → components/legacy/TabContent}/FlagDevServerTabContent.d.ts +0 -0
- /package/dist/core/ui/Toolbar/{TabContent → components/legacy/TabContent}/SettingsTab.css.d.ts +0 -0
- /package/dist/core/ui/Toolbar/components/{TabContentRenderer.css.d.ts → legacy/TabContentRenderer.css.d.ts} +0 -0
- /package/dist/core/ui/Toolbar/context/{IFrameProvider.d.ts → api/IFrameProvider.d.ts} +0 -0
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export declare function EnvironmentSelector(): import("react/jsx-runtime").JSX.Element;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export declare function GeneralSettings(): import("react/jsx-runtime").JSX.Element;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export declare function LogoutButton(): import("react/jsx-runtime").JSX.Element;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export declare const button: string;
|
|
@@ -0,0 +1,6 @@
|
|
|
1
|
+
import { ToolbarPosition } from '../../../types/toolbar';
|
|
2
|
+
interface PositionSelectorProps {
|
|
3
|
+
currentPosition: ToolbarPosition;
|
|
4
|
+
}
|
|
5
|
+
export declare function PositionSelector({ currentPosition }: PositionSelectorProps): import("react/jsx-runtime").JSX.Element;
|
|
6
|
+
export {};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export declare function PrivacySettings(): import("react/jsx-runtime").JSX.Element;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export declare function ProjectSelector(): import("react/jsx-runtime").JSX.Element;
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
import React from 'react';
|
|
2
|
+
interface SettingsItemProps {
|
|
3
|
+
label: string;
|
|
4
|
+
description?: string;
|
|
5
|
+
children: React.ReactNode;
|
|
6
|
+
}
|
|
7
|
+
export declare function SettingsItem({ label, description, children }: SettingsItemProps): import("react/jsx-runtime").JSX.Element;
|
|
8
|
+
export {};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export declare const button: string;
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
export * from './GeneralSettings';
|
|
2
|
+
export * from './Privacy/PrivacySettings';
|
|
3
|
+
export * from './SettingsSection';
|
|
4
|
+
export * from './SettingsItem';
|
|
5
|
+
export * from './ProjectSelector';
|
|
6
|
+
export * from './PositionSelector';
|
|
7
|
+
export * from './ConnectionStatus';
|
|
8
|
+
export * from './LogoutButton';
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
import { SubTab, TabConfig } from './types';
|
|
2
|
+
interface SubtabDropdownProps {
|
|
3
|
+
subtabs: TabConfig[];
|
|
4
|
+
activeSubtab: SubTab | undefined;
|
|
5
|
+
onSelectSubtab: (subtab: SubTab) => void;
|
|
6
|
+
}
|
|
7
|
+
export declare function SubtabDropdown({ subtabs, activeSubtab, onSelectSubtab }: SubtabDropdownProps): import("react/jsx-runtime").JSX.Element;
|
|
8
|
+
export {};
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
export declare const container: string;
|
|
2
|
+
export declare const trigger: string;
|
|
3
|
+
export declare const triggerOpen: string;
|
|
4
|
+
export declare const filterIcon: string;
|
|
5
|
+
export declare const label: string;
|
|
6
|
+
export declare const chevron: string;
|
|
7
|
+
export declare const chevronIcon: string;
|
|
8
|
+
export declare const menu: string;
|
|
9
|
+
export declare const menuItem: string;
|
|
10
|
+
export declare const menuItemActive: string;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export declare function TabBar(): import("react/jsx-runtime").JSX.Element | null;
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
import React from 'react';
|
|
2
|
+
interface TooltipProps {
|
|
3
|
+
content: string;
|
|
4
|
+
children: React.ReactNode;
|
|
5
|
+
offsetTop?: number;
|
|
6
|
+
offsetLeft?: number;
|
|
7
|
+
}
|
|
8
|
+
export declare function Tooltip({ content, children, offsetTop, offsetLeft }: TooltipProps): import("react/jsx-runtime").JSX.Element;
|
|
9
|
+
export {};
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
import { ReactNode } from 'react';
|
|
2
|
+
import { SubTab } from '../types';
|
|
3
|
+
interface ActiveSubtabContextValue {
|
|
4
|
+
activeSubtab: SubTab | undefined;
|
|
5
|
+
setActiveSubtab: (subtab: SubTab) => void;
|
|
6
|
+
}
|
|
7
|
+
export interface ActiveSubtabProviderProps {
|
|
8
|
+
children: ReactNode;
|
|
9
|
+
}
|
|
10
|
+
export declare function ActiveSubtabProvider({ children }: ActiveSubtabProviderProps): import("react/jsx-runtime").JSX.Element;
|
|
11
|
+
export declare function useActiveSubtabContext(): ActiveSubtabContextValue;
|
|
12
|
+
export {};
|
|
@@ -0,0 +1,41 @@
|
|
|
1
|
+
import { ReactNode } from 'react';
|
|
2
|
+
import { SubTab } from '../types';
|
|
3
|
+
export interface FilterOption {
|
|
4
|
+
id: string;
|
|
5
|
+
label: string;
|
|
6
|
+
description?: string;
|
|
7
|
+
}
|
|
8
|
+
export interface SubtabFilterConfig {
|
|
9
|
+
subtab: SubTab;
|
|
10
|
+
options: FilterOption[];
|
|
11
|
+
defaultSelected: string[];
|
|
12
|
+
allowMultiple: boolean;
|
|
13
|
+
}
|
|
14
|
+
export declare const SUBTAB_FILTER_CONFIGS: Record<string, SubtabFilterConfig>;
|
|
15
|
+
interface FiltersContextValue {
|
|
16
|
+
getActiveFilters: (subtab: SubTab) => Set<string>;
|
|
17
|
+
getFilterConfig: (subtab: SubTab) => SubtabFilterConfig | null;
|
|
18
|
+
toggleFilter: (subtab: SubTab, filterId: string) => void;
|
|
19
|
+
setFilters: (subtab: SubTab, filterIds: string[]) => void;
|
|
20
|
+
resetFilters: (subtab: SubTab) => void;
|
|
21
|
+
hasFilters: (subtab: SubTab) => boolean;
|
|
22
|
+
hasActiveNonDefaultFilters: (subtab: SubTab) => boolean;
|
|
23
|
+
isFilterOverlayOpen: boolean;
|
|
24
|
+
openFilterOverlay: () => void;
|
|
25
|
+
closeFilterOverlay: () => void;
|
|
26
|
+
toggleFilterOverlay: () => void;
|
|
27
|
+
}
|
|
28
|
+
interface FiltersProviderProps {
|
|
29
|
+
children: ReactNode;
|
|
30
|
+
}
|
|
31
|
+
export declare function FiltersProvider({ children }: FiltersProviderProps): import("react/jsx-runtime").JSX.Element;
|
|
32
|
+
export declare function useFilters(): FiltersContextValue;
|
|
33
|
+
export declare function useSubtabFilters(subtab: SubTab): {
|
|
34
|
+
activeFilters: Set<string>;
|
|
35
|
+
config: SubtabFilterConfig | null;
|
|
36
|
+
toggle: (filterId: string) => void;
|
|
37
|
+
reset: () => void;
|
|
38
|
+
hasFilters: boolean;
|
|
39
|
+
hasActiveNonDefaultFilters: boolean;
|
|
40
|
+
};
|
|
41
|
+
export {};
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
import { SubTab } from '../types';
|
|
2
|
+
type SubTabSearchContextType = {
|
|
3
|
+
searchTerms: Record<SubTab, string>;
|
|
4
|
+
setSearchTerm: (subtab: SubTab, searchTerm: string) => void;
|
|
5
|
+
clearSearchTerm: (subtab: SubTab) => void;
|
|
6
|
+
clearAllSearchTerms: () => void;
|
|
7
|
+
};
|
|
8
|
+
export declare function TabSearchProvider({ children }: {
|
|
9
|
+
children: React.ReactNode;
|
|
10
|
+
}): import("react/jsx-runtime").JSX.Element;
|
|
11
|
+
export declare function useTabSearchContext(): SubTabSearchContextType;
|
|
12
|
+
export {};
|
|
@@ -0,0 +1,3 @@
|
|
|
1
|
+
export { ActiveSubtabProvider, useActiveSubtabContext } from './ActiveSubtabProvider';
|
|
2
|
+
export { TabSearchProvider, useTabSearchContext } from './TabSearchProvider';
|
|
3
|
+
export { FiltersProvider, useFilters, useSubtabFilters, SUBTAB_FILTER_CONFIGS, type FilterOption, type SubtabFilterConfig, } from './FiltersProvider';
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
export * from './ExpandedToolbarContent';
|
|
2
|
+
export * from './IconBar/IconBar';
|
|
3
|
+
export * from './TabBar';
|
|
4
|
+
export * from './ContentActions';
|
|
5
|
+
export * from './Tooltip';
|
|
6
|
+
export * from './ContentRenderer';
|
|
7
|
+
export * from './context';
|
|
8
|
+
export * from './types';
|
|
9
|
+
export * from './Settings';
|
|
10
|
+
export * from './FilterOverlay';
|
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
export type FlagsSubtab = 'flags' | 'contexts';
|
|
2
|
+
export type MonitoringSubtab = 'events';
|
|
3
|
+
export type SettingsSubtab = 'general' | 'privacy';
|
|
4
|
+
export type InteractiveSubtab = 'workflows';
|
|
5
|
+
export type SubTab = FlagsSubtab | MonitoringSubtab | SettingsSubtab | InteractiveSubtab;
|
|
6
|
+
export interface TabConfig {
|
|
7
|
+
id: string;
|
|
8
|
+
label: string;
|
|
9
|
+
}
|
|
10
|
+
export declare const TAB_SUBTABS_MAP: {
|
|
11
|
+
readonly flags: TabConfig[];
|
|
12
|
+
readonly monitoring: TabConfig[];
|
|
13
|
+
readonly settings: TabConfig[];
|
|
14
|
+
readonly interactive: TabConfig[];
|
|
15
|
+
};
|
|
16
|
+
export declare function getDefaultSubtab(mainTab: string): SubTab;
|
|
@@ -40,6 +40,20 @@ export declare const ANIMATION_CONFIG: {
|
|
|
40
40
|
readonly ease: "easeInOut";
|
|
41
41
|
};
|
|
42
42
|
};
|
|
43
|
+
readonly containerInstant: {
|
|
44
|
+
readonly width: {
|
|
45
|
+
readonly duration: 0.01;
|
|
46
|
+
};
|
|
47
|
+
readonly height: {
|
|
48
|
+
readonly duration: 0.01;
|
|
49
|
+
};
|
|
50
|
+
readonly borderRadius: {
|
|
51
|
+
readonly duration: 0.01;
|
|
52
|
+
};
|
|
53
|
+
readonly boxShadow: {
|
|
54
|
+
readonly duration: 0.01;
|
|
55
|
+
};
|
|
56
|
+
};
|
|
43
57
|
readonly container: {
|
|
44
58
|
readonly width: {
|
|
45
59
|
readonly duration: 0.25;
|
|
@@ -1,4 +1,5 @@
|
|
|
1
1
|
import type { FC, ReactNode } from 'react';
|
|
2
|
+
import { DevServerClient } from '../../../services/DevServerClient';
|
|
2
3
|
import { LdToolbarConfig, ToolbarState } from '../../../types/devServer';
|
|
3
4
|
interface DevServerContextValue {
|
|
4
5
|
state: ToolbarState;
|
|
@@ -6,6 +7,7 @@ interface DevServerContextValue {
|
|
|
6
7
|
clearOverride: (flagKey: string) => Promise<void>;
|
|
7
8
|
clearAllOverrides: () => Promise<void>;
|
|
8
9
|
refresh: () => Promise<void>;
|
|
10
|
+
devServerClient: DevServerClient | null;
|
|
9
11
|
}
|
|
10
12
|
export declare const useDevServerContext: () => DevServerContextValue;
|
|
11
13
|
export interface DevServerProviderProps {
|
|
@@ -0,0 +1,52 @@
|
|
|
1
|
+
import { ReactNode } from 'react';
|
|
2
|
+
import { ElementInfo } from '../components/new/Interactive/utils/elementUtils';
|
|
3
|
+
/**
|
|
4
|
+
* Context value for element selection functionality.
|
|
5
|
+
* Provides state and actions for selecting DOM elements in the interactive mode.
|
|
6
|
+
*/
|
|
7
|
+
export interface ElementSelectionContextValue {
|
|
8
|
+
/** Whether the user is currently in element selection mode */
|
|
9
|
+
isSelecting: boolean;
|
|
10
|
+
/** The currently selected DOM element, or null if none selected */
|
|
11
|
+
selectedElement: HTMLElement | null;
|
|
12
|
+
/** Extracted information about the selected element */
|
|
13
|
+
selectedElementInfo: ElementInfo | null;
|
|
14
|
+
/** The element currently being hovered over during selection */
|
|
15
|
+
hoveredElement: HTMLElement | null;
|
|
16
|
+
/** Start element selection mode */
|
|
17
|
+
startSelection: () => void;
|
|
18
|
+
/** Exit element selection mode without selecting an element */
|
|
19
|
+
exitSelection: () => void;
|
|
20
|
+
/** Select an element and exit selection mode */
|
|
21
|
+
selectElement: (element: HTMLElement) => void;
|
|
22
|
+
/** Clear the current selection */
|
|
23
|
+
clearSelection: () => void;
|
|
24
|
+
/** Set the currently hovered element (used internally by SelectionOverlay) */
|
|
25
|
+
setHoveredElement: (element: HTMLElement | null) => void;
|
|
26
|
+
}
|
|
27
|
+
export interface ElementSelectionProviderProps {
|
|
28
|
+
/** Child components that will have access to the element selection context */
|
|
29
|
+
children: ReactNode;
|
|
30
|
+
/** Optional callback invoked when selection mode starts */
|
|
31
|
+
onSelectionStart?: () => void;
|
|
32
|
+
/** Optional callback invoked when selection mode ends (either by selecting or exiting) */
|
|
33
|
+
onSelectionEnd?: () => void;
|
|
34
|
+
}
|
|
35
|
+
/**
|
|
36
|
+
* Provider component that manages element selection state for the interactive mode.
|
|
37
|
+
* Wraps components that need access to element selection functionality.
|
|
38
|
+
*
|
|
39
|
+
* @param props - The provider props
|
|
40
|
+
* @param props.children - Child components
|
|
41
|
+
* @param props.onSelectionStart - Optional callback when selection starts
|
|
42
|
+
* @param props.onSelectionEnd - Optional callback when selection ends
|
|
43
|
+
*/
|
|
44
|
+
export declare function ElementSelectionProvider({ children, onSelectionStart, onSelectionEnd, }: ElementSelectionProviderProps): import("react/jsx-runtime").JSX.Element;
|
|
45
|
+
/**
|
|
46
|
+
* Hook to access the element selection context.
|
|
47
|
+
* Must be used within an ElementSelectionProvider.
|
|
48
|
+
*
|
|
49
|
+
* @returns The element selection context value
|
|
50
|
+
* @throws Error if used outside of ElementSelectionProvider
|
|
51
|
+
*/
|
|
52
|
+
export declare function useElementSelection(): ElementSelectionContextValue;
|
|
@@ -1,14 +1,18 @@
|
|
|
1
1
|
import { IFlagOverridePlugin } from '../../../../types';
|
|
2
|
+
import { ApiVariation } from '../types/ldApi';
|
|
2
3
|
interface LocalFlag {
|
|
3
4
|
key: string;
|
|
4
5
|
name: string;
|
|
5
6
|
currentValue: any;
|
|
6
7
|
isOverridden: boolean;
|
|
7
|
-
type: 'boolean' | 'string' | 'number' | 'object';
|
|
8
|
+
type: 'boolean' | 'multivariate' | 'string' | 'number' | 'object';
|
|
9
|
+
availableVariations: ApiVariation[];
|
|
8
10
|
}
|
|
9
11
|
interface FlagSdkOverrideContextType {
|
|
10
12
|
flags: Record<string, LocalFlag>;
|
|
11
13
|
isLoading: boolean;
|
|
14
|
+
setOverride: (flagKey: string, value: any) => void;
|
|
15
|
+
removeOverride: (flagKey: string) => void;
|
|
12
16
|
}
|
|
13
17
|
interface FlagSdkOverrideProviderProps {
|
|
14
18
|
children: React.ReactNode;
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
interface ApiBundleProviderProps {
|
|
2
|
+
authUrl: string;
|
|
3
|
+
clientSideId?: string;
|
|
4
|
+
providedProjectKey?: string;
|
|
5
|
+
children: React.ReactNode;
|
|
6
|
+
}
|
|
7
|
+
export declare function ApiBundleProvider(props: ApiBundleProviderProps): import("react/jsx-runtime").JSX.Element;
|
|
8
|
+
export {};
|
|
@@ -1,7 +1,6 @@
|
|
|
1
|
-
import { FlagsPaginationParams, FlagsResponse,
|
|
1
|
+
import { FlagsPaginationParams, FlagsResponse, ProjectsResponse } from '../../types/ldApi';
|
|
2
2
|
interface ApiProviderContextValue {
|
|
3
3
|
apiReady: boolean;
|
|
4
|
-
getFlag: (flagKey: string) => Promise<ApiFlag>;
|
|
5
4
|
getProjects: () => Promise<ProjectsResponse>;
|
|
6
5
|
getFlags: (projectKey: string, params?: FlagsPaginationParams) => Promise<FlagsResponse>;
|
|
7
6
|
}
|
|
@@ -1,13 +1,13 @@
|
|
|
1
1
|
import { Dispatch, SetStateAction } from 'react';
|
|
2
|
-
|
|
2
|
+
interface AuthContextType {
|
|
3
3
|
authenticated: boolean;
|
|
4
4
|
authenticating: boolean;
|
|
5
5
|
loading: boolean;
|
|
6
6
|
setAuthenticating: Dispatch<SetStateAction<boolean>>;
|
|
7
7
|
logout: () => void;
|
|
8
|
-
}
|
|
8
|
+
}
|
|
9
9
|
export declare function AuthProvider({ children }: {
|
|
10
10
|
children: React.ReactNode;
|
|
11
11
|
}): import("react/jsx-runtime").JSX.Element;
|
|
12
|
-
export declare function useAuthContext():
|
|
12
|
+
export declare function useAuthContext(): AuthContextType;
|
|
13
13
|
export {};
|
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
import type { LDContext } from 'launchdarkly-js-client-sdk';
|
|
2
|
+
interface ContextsContextType {
|
|
3
|
+
contexts: LDContext[];
|
|
4
|
+
filter: string;
|
|
5
|
+
setFilter: (filter: string) => void;
|
|
6
|
+
addContext: (context: LDContext) => void;
|
|
7
|
+
removeContext: (contextId: string) => void;
|
|
8
|
+
updateContext: (contextId: string, newContext: LDContext) => void;
|
|
9
|
+
setContext: (context: LDContext) => Promise<void>;
|
|
10
|
+
activeContext: LDContext | null;
|
|
11
|
+
isAddFormOpen: boolean;
|
|
12
|
+
setIsAddFormOpen: (isOpen: boolean) => void;
|
|
13
|
+
clearContexts: () => void;
|
|
14
|
+
}
|
|
15
|
+
export declare const ContextsProvider: ({ children }: {
|
|
16
|
+
children: React.ReactNode;
|
|
17
|
+
}) => import("react/jsx-runtime").JSX.Element;
|
|
18
|
+
export declare function useContextsContext(): ContextsContextType;
|
|
19
|
+
export {};
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
import { FC } from 'react';
|
|
2
|
+
interface EnvironmentContextType {
|
|
3
|
+
environment: string;
|
|
4
|
+
setEnvironment: (environment: string) => void;
|
|
5
|
+
}
|
|
6
|
+
interface EnvironmentProviderProps {
|
|
7
|
+
children: React.ReactNode;
|
|
8
|
+
clientSideId?: string;
|
|
9
|
+
}
|
|
10
|
+
export declare const EnvironmentProvider: FC<EnvironmentProviderProps>;
|
|
11
|
+
export declare function useEnvironmentContext(): EnvironmentContextType;
|
|
12
|
+
export {};
|
|
@@ -1,12 +1,13 @@
|
|
|
1
|
-
import { ApiFlag, FlagsResponse } from '
|
|
2
|
-
|
|
1
|
+
import { ApiFlag, FlagsResponse } from '../../types/ldApi';
|
|
2
|
+
interface FlagsContextType {
|
|
3
3
|
flags: ApiFlag[];
|
|
4
4
|
loading: boolean;
|
|
5
5
|
getProjectFlags: (projectKey: string) => Promise<FlagsResponse>;
|
|
6
6
|
resetFlags: () => void;
|
|
7
|
-
|
|
7
|
+
refreshFlags: () => Promise<void>;
|
|
8
|
+
}
|
|
8
9
|
export declare const FlagsProvider: ({ children }: {
|
|
9
10
|
children: React.ReactNode;
|
|
10
11
|
}) => import("react/jsx-runtime").JSX.Element;
|
|
11
|
-
export declare
|
|
12
|
+
export declare function useFlagsContext(): FlagsContextType;
|
|
12
13
|
export {};
|
|
@@ -1,11 +1,12 @@
|
|
|
1
|
-
import { ApiProject, ProjectsResponse } from '
|
|
2
|
-
|
|
1
|
+
import { ApiProject, ProjectsResponse, ApiEnvironment } from '../../types/ldApi';
|
|
2
|
+
interface ProjectContextType {
|
|
3
3
|
projectKey: string;
|
|
4
4
|
setProjectKey: (projectKey: string) => void;
|
|
5
5
|
getProjects: () => Promise<ProjectsResponse>;
|
|
6
6
|
projects: ApiProject[];
|
|
7
|
+
environments: ApiEnvironment[];
|
|
7
8
|
loading: boolean;
|
|
8
|
-
}
|
|
9
|
+
}
|
|
9
10
|
interface ProjectProviderProps {
|
|
10
11
|
children: React.ReactNode;
|
|
11
12
|
clientSideId?: string;
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
export * from './ApiBundleProvider';
|
|
2
|
+
export * from './ApiProvider';
|
|
3
|
+
export * from './AuthProvider';
|
|
4
|
+
export * from './ContextsProvider';
|
|
5
|
+
export * from './EnvironmentProvider';
|
|
6
|
+
export * from './FlagsProvider';
|
|
7
|
+
export * from './IFrameProvider';
|
|
8
|
+
export * from './ProjectProvider';
|
|
@@ -1,7 +1,7 @@
|
|
|
1
|
-
export
|
|
2
|
-
export
|
|
3
|
-
export
|
|
4
|
-
export
|
|
5
|
-
export
|
|
6
|
-
export
|
|
7
|
-
export
|
|
1
|
+
export * from './api';
|
|
2
|
+
export * from './state';
|
|
3
|
+
export * from './telemetry';
|
|
4
|
+
export * from './DevServerProvider';
|
|
5
|
+
export * from './FlagSdkOverrideProvider';
|
|
6
|
+
export * from './StarredFlagsProvider';
|
|
7
|
+
export * from './ElementSelectionProvider';
|
package/dist/core/ui/Toolbar/context/{ActiveTabProvider.d.ts → state/ActiveTabProvider.d.ts}
RENAMED
|
@@ -1,8 +1,8 @@
|
|
|
1
|
-
import type { ActiveTabId } from '
|
|
2
|
-
|
|
1
|
+
import type { ActiveTabId } from '../../types';
|
|
2
|
+
interface ActiveTabContextType {
|
|
3
3
|
activeTab: ActiveTabId;
|
|
4
4
|
setActiveTab: (tab: ActiveTabId) => void;
|
|
5
|
-
}
|
|
5
|
+
}
|
|
6
6
|
export declare function ActiveTabProvider({ children }: {
|
|
7
7
|
children: React.ReactNode;
|
|
8
8
|
}): import("react/jsx-runtime").JSX.Element;
|
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
import { ReactNode } from 'react';
|
|
2
|
+
import { IEventInterceptionPlugin, IFlagOverridePlugin } from '../../../../../types';
|
|
3
|
+
interface PluginsContextValue {
|
|
4
|
+
baseUrl: string;
|
|
5
|
+
flagOverridePlugin?: IFlagOverridePlugin;
|
|
6
|
+
eventInterceptionPlugin?: IEventInterceptionPlugin;
|
|
7
|
+
}
|
|
8
|
+
export interface PluginsProviderProps {
|
|
9
|
+
children: ReactNode;
|
|
10
|
+
baseUrl: string;
|
|
11
|
+
flagOverridePlugin?: IFlagOverridePlugin;
|
|
12
|
+
eventInterceptionPlugin?: IEventInterceptionPlugin;
|
|
13
|
+
}
|
|
14
|
+
export declare function PluginsProvider({ children, baseUrl, flagOverridePlugin, eventInterceptionPlugin, }: PluginsProviderProps): import("react/jsx-runtime").JSX.Element;
|
|
15
|
+
export declare function usePlugins(): PluginsContextValue;
|
|
16
|
+
export {};
|
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
import React, { Dispatch, type SetStateAction } from 'react';
|
|
2
|
-
|
|
2
|
+
interface SearchContextType {
|
|
3
3
|
searchTerm: string;
|
|
4
4
|
setSearchTerm: Dispatch<SetStateAction<string>>;
|
|
5
|
-
}
|
|
5
|
+
}
|
|
6
6
|
export declare function SearchProvider({ children }: {
|
|
7
7
|
children: React.ReactNode;
|
|
8
8
|
}): import("react/jsx-runtime").JSX.Element;
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
import { IEventInterceptionPlugin, IFlagOverridePlugin } from '../../../../../types';
|
|
2
|
+
import { ToolbarPosition } from '../../types';
|
|
3
|
+
interface ToolbarStateBundleProviderProps {
|
|
4
|
+
initialPosition?: ToolbarPosition;
|
|
5
|
+
domId: string;
|
|
6
|
+
devServerUrl?: string;
|
|
7
|
+
baseUrl: string;
|
|
8
|
+
flagOverridePlugin?: IFlagOverridePlugin;
|
|
9
|
+
eventInterceptionPlugin?: IEventInterceptionPlugin;
|
|
10
|
+
children: React.ReactNode;
|
|
11
|
+
}
|
|
12
|
+
export declare function ToolbarStateBundleProvider(props: ToolbarStateBundleProviderProps): import("react/jsx-runtime").JSX.Element;
|
|
13
|
+
export {};
|
|
@@ -0,0 +1,35 @@
|
|
|
1
|
+
import React, { Dispatch, SetStateAction, ReactNode } from 'react';
|
|
2
|
+
import { ActiveTabId, ToolbarMode } from '../../types';
|
|
3
|
+
export interface ToolbarStateContextValue {
|
|
4
|
+
isExpanded: boolean;
|
|
5
|
+
previousTab: ActiveTabId;
|
|
6
|
+
isAnimating: boolean;
|
|
7
|
+
searchIsExpanded: boolean;
|
|
8
|
+
slideDirection: number;
|
|
9
|
+
hasBeenExpanded: boolean;
|
|
10
|
+
reloadOnFlagChangeIsEnabled: boolean;
|
|
11
|
+
isAutoCollapseEnabled: boolean;
|
|
12
|
+
mode: ToolbarMode;
|
|
13
|
+
isOptedInToAnalytics: boolean;
|
|
14
|
+
isOptedInToEnhancedAnalytics: boolean;
|
|
15
|
+
isOptedInToSessionReplay: boolean;
|
|
16
|
+
toolbarRef: React.RefObject<HTMLDivElement | null>;
|
|
17
|
+
handleTabChange: (tabId: string) => void;
|
|
18
|
+
handleClose: () => void;
|
|
19
|
+
handleSearch: (newSearchTerm: string) => void;
|
|
20
|
+
handleToggleReloadOnFlagChange: () => void;
|
|
21
|
+
handleToggleAutoCollapse: () => void;
|
|
22
|
+
handleCircleClick: () => void;
|
|
23
|
+
setIsAnimating: Dispatch<SetStateAction<boolean>>;
|
|
24
|
+
setSearchIsExpanded: Dispatch<SetStateAction<boolean>>;
|
|
25
|
+
handleToggleAnalyticsOptOut: (enabled: boolean) => void;
|
|
26
|
+
handleToggleEnhancedAnalyticsOptOut: (enabled: boolean) => void;
|
|
27
|
+
handleToggleSessionReplayOptOut: (enabled: boolean) => void;
|
|
28
|
+
}
|
|
29
|
+
export interface ToolbarStateProviderProps {
|
|
30
|
+
children: ReactNode;
|
|
31
|
+
domId: string;
|
|
32
|
+
devServerUrl?: string;
|
|
33
|
+
}
|
|
34
|
+
export declare function ToolbarStateProvider({ children, domId, devServerUrl }: ToolbarStateProviderProps): import("react/jsx-runtime").JSX.Element;
|
|
35
|
+
export declare function useToolbarState(): ToolbarStateContextValue;
|
package/dist/core/ui/Toolbar/context/{ToolbarUIProvider.d.ts → state/ToolbarUIProvider.d.ts}
RENAMED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import type { FC, ReactNode } from 'react';
|
|
2
|
-
import
|
|
2
|
+
import { ToolbarPosition } from '../../types';
|
|
3
3
|
interface ToolbarUIContextValue {
|
|
4
4
|
position: ToolbarPosition;
|
|
5
5
|
handlePositionChange: (position: ToolbarPosition) => void;
|