@nice2dev/ui 1.0.18 → 1.0.20

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.
Files changed (101) hide show
  1. package/CHANGELOG.md +64 -0
  2. package/dist/NiceErrorBoundary-Bzx-bOeb.cjs +1 -0
  3. package/dist/NiceErrorBoundary-DBCCmeyl.js +770 -0
  4. package/dist/NiceErrorBoundary-DvA00DOz.cjs +1 -0
  5. package/dist/NiceErrorBoundary-V6wkSSLP.cjs +1 -0
  6. package/dist/NiceErrorBoundary-eTwBEuSH.js +770 -0
  7. package/dist/NiceErrorBoundary-qp4IJ18o.js +770 -0
  8. package/dist/NiceForm-B1Okz7SW.cjs +382 -0
  9. package/dist/NiceForm-BXHPoTcH.cjs +382 -0
  10. package/dist/NiceForm-DL7Kxsi2.js +5383 -0
  11. package/dist/NiceForm-DLADlHAQ.js +5383 -0
  12. package/dist/NiceForm-DUkduLqG.cjs +382 -0
  13. package/dist/NiceForm-D_XZxq3a.js +5383 -0
  14. package/dist/NiceForm.css +1 -1
  15. package/dist/NiceModal-0Sg2HxIb.cjs +1 -0
  16. package/dist/NiceModal-BRih_XEH.js +95 -0
  17. package/dist/NiceModal-C4HIsjrn.js +95 -0
  18. package/dist/NiceModal-CUdeVj-j.js +95 -0
  19. package/dist/NiceModal-Cc8R-DpX.cjs +1 -0
  20. package/dist/NiceModal-DieswZtd.cjs +1 -0
  21. package/dist/NiceModuleLifecyclePanel-4UEsYB5r.js +6553 -0
  22. package/dist/NiceModuleLifecyclePanel-C6agdtTI.cjs +1 -0
  23. package/dist/NiceModuleLifecyclePanel-CEfeJxw_.cjs +1 -0
  24. package/dist/NiceModuleLifecyclePanel-D4xWUswk.js +6777 -0
  25. package/dist/NiceModuleLifecyclePanel-jDzEfvDM.js +6553 -0
  26. package/dist/NiceModuleLifecyclePanel-sBJLlhJp.cjs +1 -0
  27. package/dist/NiceModuleLifecyclePanel.css +1 -1
  28. package/dist/NicePagination-B2TC6MTL.cjs +1 -0
  29. package/dist/NicePagination-BAywVGwT.js +171 -0
  30. package/dist/NicePagination-Cqr3Pe_F.js +171 -0
  31. package/dist/NicePagination-DnnypBiE.js +171 -0
  32. package/dist/NicePagination-DyWWdtb3.cjs +1 -0
  33. package/dist/NicePagination-F8NyMfgc.cjs +1 -0
  34. package/dist/NicePinCodeInput-Bo8Ahkae.js +12240 -0
  35. package/dist/NicePinCodeInput-C6zJxUVf.cjs +419 -0
  36. package/dist/NicePinCodeInput-CpPtHZsK.js +12240 -0
  37. package/dist/NicePinCodeInput-Cpa01Yfg.cjs +419 -0
  38. package/dist/NicePinCodeInput-JvYd_LB_.cjs +419 -0
  39. package/dist/NicePinCodeInput-ltwzQf4r.js +12240 -0
  40. package/dist/NicePinCodeInput.css +1 -1
  41. package/dist/NiceSavedQueryPanel-BIXW0y1X.js +6455 -0
  42. package/dist/NiceSavedQueryPanel-BOBULytX.js +6455 -0
  43. package/dist/NiceSavedQueryPanel-CFHwMDIx.cjs +596 -0
  44. package/dist/NiceSavedQueryPanel-CTfC-qwV.cjs +596 -0
  45. package/dist/NiceSavedQueryPanel-DuonbEem.js +6584 -0
  46. package/dist/NiceSavedQueryPanel-MdKdGYNg.cjs +596 -0
  47. package/dist/NiceSavedQueryPanel.css +1 -1
  48. package/dist/NiceTabs-B9zxj6qd.js +1657 -0
  49. package/dist/NiceTabs-BjBtazRn.cjs +1 -0
  50. package/dist/NiceTabs-C-VQXNIa.cjs +1 -0
  51. package/dist/NiceTabs-CJ8G2t0-.js +1657 -0
  52. package/dist/NiceTabs-CNauJ4fu.cjs +1 -0
  53. package/dist/NiceTabs-v7HfeXIw.js +1657 -0
  54. package/dist/NiceWindow-BMiF-so6.cjs +1 -0
  55. package/dist/NiceWindow-Bo_yCa1o.js +1418 -0
  56. package/dist/NiceWindow-CysIgnn3.js +1418 -0
  57. package/dist/NiceWindow-D6SjpDc4.cjs +1 -0
  58. package/dist/NiceWindow-DPzJxOfx.cjs +1 -0
  59. package/dist/NiceWindow-DUTRQOaP.js +1418 -0
  60. package/dist/charts-C60va95_.js +4657 -0
  61. package/dist/charts-CJlMAHJG.cjs +761 -0
  62. package/dist/charts-CX4jiyVh.cjs +761 -0
  63. package/dist/charts-CYpqDxHd.js +4657 -0
  64. package/dist/charts-D_I1iwel.cjs +761 -0
  65. package/dist/charts-P6qura0j.js +4657 -0
  66. package/dist/charts.cjs +1 -1
  67. package/dist/charts.css +1 -1
  68. package/dist/charts.mjs +1 -1
  69. package/dist/core-Bcc4sz15.cjs +96 -0
  70. package/dist/core-BfeyB9A8.cjs +96 -0
  71. package/dist/core-BgGSTko-.js +22401 -0
  72. package/dist/core-DDJKu5LZ.cjs +96 -0
  73. package/dist/core-Da1dGJN3.js +22401 -0
  74. package/dist/core-XsWxyBHD.js +22767 -0
  75. package/dist/data.cjs +1 -1
  76. package/dist/data.d.ts +5 -0
  77. package/dist/data.mjs +1 -1
  78. package/dist/editors.cjs +1 -1
  79. package/dist/editors.d.ts +44 -1
  80. package/dist/editors.mjs +3 -3
  81. package/dist/feedback.cjs +1 -1
  82. package/dist/feedback.mjs +2 -2
  83. package/dist/index-CQIDqjZp.cjs +5194 -0
  84. package/dist/index-CXVXf_HY.cjs +5194 -0
  85. package/dist/index-CtikFbFa.js +64337 -0
  86. package/dist/index-DCDfWfAt.js +64336 -0
  87. package/dist/index-DpiCo0_e.cjs +5194 -0
  88. package/dist/index-xVJiF843.js +65040 -0
  89. package/dist/index.cjs +1 -1
  90. package/dist/index.css +1 -1
  91. package/dist/index.d.ts +450 -6
  92. package/dist/index.mjs +874 -860
  93. package/dist/lazy.cjs +1 -1
  94. package/dist/lazy.mjs +3 -3
  95. package/dist/navigation.cjs +1 -1
  96. package/dist/navigation.d.ts +50 -3
  97. package/dist/navigation.mjs +30 -30
  98. package/dist/overlays.cjs +1 -1
  99. package/dist/overlays.mjs +53 -53
  100. package/dist/style.css +6 -6
  101. package/package.json +3 -3
package/dist/index.d.ts CHANGED
@@ -63,6 +63,7 @@ import { createUserPreferencesStore } from '@nice2dev/ui-core';
63
63
  import { createWebSocketDataSource } from '@nice2dev/ui-core';
64
64
  import { createZustandAdapter } from '@nice2dev/ui-core';
65
65
  import { CrossTabMessage } from '@nice2dev/ui-core';
66
+ import { CSSProperties } from 'react';
66
67
  import { default as default_2 } from 'react';
67
68
  import { DEFAULT_VARIANT_CONFIG } from '@nice2dev/ui-core';
68
69
  import { DENSITY_VALUES } from '@nice2dev/ui-core';
@@ -1766,6 +1767,20 @@ export { buildFormFieldAria }
1766
1767
  /** Build the iCalendar text body for the given events. */
1767
1768
  export declare function buildIcs(events: NiceIcsEvent[], options?: ExportIcsOptions): string;
1768
1769
 
1770
+ /** Build resolved `SidebarNavView` items with translated labels. */
1771
+ export declare function buildPrefsCategoryViews(t: (key: string, defaultValue: string) => string): SidebarNavView[];
1772
+
1773
+ /**
1774
+ * Returns a `Record<route, ReactNode>` of the built-in sidebar preference
1775
+ * routes (`preferences/general`, `preferences/display`, `preferences/order`,
1776
+ * `preferences/hidden`, `preferences/reset`) — ready to be merged into
1777
+ * `NiceNavShell`'s `routes` prop.
1778
+ *
1779
+ * NavShell auto-merges these when `includeSidebarPreferenceRoutes` is left at
1780
+ * its default `true`. Call this manually when you want fine-grained control.
1781
+ */
1782
+ export declare function buildSidebarPrefsRoutes(): Record<string, ReactNode>;
1783
+
1769
1784
  /** Bulk operation */
1770
1785
  export declare interface BulkOperation {
1771
1786
  id: string;
@@ -9035,6 +9050,29 @@ export declare interface NiceColorPaletteProps extends NiceBaseProps {
9035
9050
  label?: string;
9036
9051
  /** Disabled state */
9037
9052
  disabled?: boolean;
9053
+ /**
9054
+ * Target number of colors in the generated palette. Overrides the natural
9055
+ * count of the active harmony mode (clamped between `minColors` and
9056
+ * `maxColors`). When omitted, the harmony's natural angle count is used.
9057
+ */
9058
+ colorCount?: number;
9059
+ /**
9060
+ * Step size (HSV value delta) between adjacent colors in the `shade-chain`
9061
+ * mode. Default 0.12.
9062
+ */
9063
+ shadeStep?: number;
9064
+ /** Called when the user changes the shade step via the in-component control. */
9065
+ onShadeStepChange?: (step: number) => void;
9066
+ /**
9067
+ * Custom harmony schemes. Appended to the built-in mode list in the
9068
+ * selector and persisted via `localStorage` when `persistCustomSchemes`
9069
+ * is true.
9070
+ */
9071
+ customSchemes?: NiceCustomHarmonyScheme[];
9072
+ /** Called when the user edits the custom-schemes list. */
9073
+ onCustomSchemesChange?: (schemes: NiceCustomHarmonyScheme[]) => void;
9074
+ /** Persist custom schemes to `localStorage["nice-palette-custom-schemes"]`. Default true. */
9075
+ persistCustomSchemes?: boolean;
9038
9076
  }
9039
9077
 
9040
9078
  export declare const NiceColorPicker: default_2.ForwardRefExoticComponent<NiceColorPickerProps & default_2.RefAttributes<HTMLInputElement>>;
@@ -9936,6 +9974,12 @@ export declare interface NiceCountryPickerProps extends NiceFormFieldProps, Dual
9936
9974
  * false (except flag) and ignoring `controlWidth`. Default: false.
9937
9975
  */
9938
9976
  compact?: boolean;
9977
+ /**
9978
+ * Visual variant. `'ghost'` removes border, background and the dropdown
9979
+ * arrow — only the flag/icon is shown. Designed for dense toolbars
9980
+ * (e.g. NiceTopNav narrow mode). Default: `'default'`.
9981
+ */
9982
+ variant?: 'default' | 'ghost';
9939
9983
  /**
9940
9984
  * Dropdown horizontal alignment relative to the trigger. `'auto'` picks
9941
9985
  * the side with more available viewport space (right-edge preferred).
@@ -10105,6 +10149,15 @@ export { NiceCursorPaginationConfig }
10105
10149
 
10106
10150
  export { NiceCustomDataSourceHandlers }
10107
10151
 
10152
+ /** A user-defined harmony scheme (hue angles + optional lightness offsets). */
10153
+ declare interface NiceCustomHarmonyScheme {
10154
+ id: string;
10155
+ name: string;
10156
+ angles: number[];
10157
+ /** Optional per-color lightness deltas applied on top of preset/base V. */
10158
+ lightnessOffsets?: number[];
10159
+ }
10160
+
10108
10161
  export declare const NiceDashboardLayout: default_2.ForwardRefExoticComponent<NiceDashboardLayoutProps & default_2.RefAttributes<HTMLDivElement>>;
10109
10162
 
10110
10163
  /** Props for the {@link NiceDashboardLayout} component — a CSS-grid dashboard with draggable, resizable panels. */
@@ -10838,6 +10891,8 @@ export declare interface NiceDisplayStylePickerProps extends NiceBaseProps {
10838
10891
  label?: string;
10839
10892
  /** Filter to show only specific styles. */
10840
10893
  styles?: NiceDisplayStyle[];
10894
+ /** Compact mode — forces dropdown layout for tight spaces. */
10895
+ compact?: boolean;
10841
10896
  }
10842
10897
 
10843
10898
  export declare const NiceDivider: default_2.FC<NiceDividerProps>;
@@ -12815,7 +12870,7 @@ export declare interface NiceGradientValue {
12815
12870
 
12816
12871
  export { NiceGraphQLConfig }
12817
12872
 
12818
- export declare type NiceHarmonyMode = 'monochromatic' | 'complementary' | 'split-complementary' | 'analogous' | 'triadic' | 'tetradic' | 'square' | 'custom';
12873
+ export declare type NiceHarmonyMode = 'monochromatic' | 'complementary' | 'split-complementary' | 'analogous' | 'triadic' | 'tetradic' | 'square' | 'shade-chain' | 'custom';
12819
12874
 
12820
12875
  /**
12821
12876
  * Semantic heading with decoupled visual scale. Renders the correct
@@ -13704,6 +13759,12 @@ export declare interface NiceLanguagePickerProps extends NiceFormFieldProps, Dua
13704
13759
  * dropdown alignment. Default: false.
13705
13760
  */
13706
13761
  compact?: boolean;
13762
+ /**
13763
+ * Visual variant. `'ghost'` removes border, background and the dropdown
13764
+ * arrow — only the flag is shown. Designed for dense toolbars
13765
+ * (e.g. NiceTopNav narrow mode). Default: `'default'`.
13766
+ */
13767
+ variant?: 'default' | 'ghost';
13707
13768
  /**
13708
13769
  * Dropdown horizontal alignment relative to trigger. `'auto'` picks the
13709
13770
  * side with more available viewport space. Default: `'auto'` in compact
@@ -14944,6 +15005,12 @@ export declare interface NiceMenuProps extends NiceBaseProps {
14944
15005
  renderTriggerLabel?: (item: NiceMenuItem) => default_2.ReactNode;
14945
15006
  /** Optional renderer for panel-entry label. */
14946
15007
  renderEntryLabel?: (item: NiceMenuItem) => default_2.ReactNode;
15008
+ /**
15009
+ * Maximum depth of nested flyouts rendered. `1` = top-level only, `2` = level-1 panel,
15010
+ * `3` = level-2 subpanel (default — preserves legacy behavior), up to `10`. Items with
15011
+ * `children` beyond this depth are rendered as leaves (no flyout arrow, no hover-open).
15012
+ */
15013
+ maxDepth?: number;
14947
15014
  }
14948
15015
 
14949
15016
  /**
@@ -15615,7 +15682,14 @@ export declare const NiceNavShell: ForwardRefExoticComponent<NiceNavShellProps &
15615
15682
  export declare interface NiceNavShellApi {
15616
15683
  activeRoute: string | undefined;
15617
15684
  tabs: NiceNavShellTab[];
15618
- openRoute: (route: string, opts?: Partial<NiceNavShellTab>) => void;
15685
+ /** True when the shell is in narrow/mobile layout (viewport ≤ `mobileBreakpoint`
15686
+ * or `forceMobileLayout`). Render-prop slot consumers should forward this to
15687
+ * any embedded `NiceTopNav` (`forceMobileLayout={isMobile}`) so the hamburger
15688
+ * switch happens at the same width the sidebar disappears. */
15689
+ isMobile: boolean;
15690
+ openRoute: (route: string, opts?: Partial<NiceNavShellTab> & {
15691
+ forceNew?: boolean;
15692
+ }) => void;
15619
15693
  closeTab: (id: string) => void;
15620
15694
  closeOthers: (id: string) => void;
15621
15695
  closeAll: () => void;
@@ -15623,6 +15697,59 @@ export declare interface NiceNavShellApi {
15623
15697
  setDirty: (id: string, dirty?: boolean) => void;
15624
15698
  }
15625
15699
 
15700
+ export declare function NiceNavShellHome({ userName, userId, openTabs, routes, routeLabels, routeIcons, shortcuts, onNavigate, showGreeting, showOpenTabs, showShortcuts, showRoutes, maxItemsPerSection, header, footer, className, style, }: NiceNavShellHomeProps): default_2.ReactElement;
15701
+
15702
+ export declare namespace NiceNavShellHome {
15703
+ var displayName: string;
15704
+ }
15705
+
15706
+ /** Props for {@link NiceNavShellHome} — default `homeContent` rendered by NiceNavShell. */
15707
+ export declare interface NiceNavShellHomeProps {
15708
+ /** Display name used in the greeting. */
15709
+ userName?: string;
15710
+ /** User id used to derive shortcuts from NiceSidebarNav's localStorage prefs when `shortcuts` is omitted. */
15711
+ userId?: string;
15712
+ /** Currently open tabs (typically NavShell's `tabs` minus the home tab). */
15713
+ openTabs?: NiceNavShellTab[];
15714
+ /** Map of all available routes (just the keys are read). */
15715
+ routes?: Record<string, unknown>;
15716
+ /** Per-route label overrides. */
15717
+ routeLabels?: Record<string, ReactNode>;
15718
+ /** Per-route icon overrides. */
15719
+ routeIcons?: Record<string, ReactNode>;
15720
+ /** Explicit shortcut list. When set, suppresses auto-derived sidebar favorites. */
15721
+ shortcuts?: NiceNavShellHomeShortcut[];
15722
+ /** Called when a tile is clicked. Receives the route key. */
15723
+ onNavigate?: (route: string) => void;
15724
+ /** Default `true`. */
15725
+ showGreeting?: boolean;
15726
+ /** Default `true`. */
15727
+ showOpenTabs?: boolean;
15728
+ /** Default `true`. */
15729
+ showShortcuts?: boolean;
15730
+ /** Default `true`. */
15731
+ showRoutes?: boolean;
15732
+ /** Cap per section. Default `12`. */
15733
+ maxItemsPerSection?: number;
15734
+ /** Custom header content (replaces the greeting block). */
15735
+ header?: ReactNode;
15736
+ /** Custom footer content (e.g. announcement banner). */
15737
+ footer?: ReactNode;
15738
+ className?: string;
15739
+ style?: CSSProperties;
15740
+ }
15741
+
15742
+ /** A pinned shortcut tile rendered in the shortcuts section. */
15743
+ export declare interface NiceNavShellHomeShortcut {
15744
+ id: string;
15745
+ label: ReactNode;
15746
+ icon?: ReactNode;
15747
+ /** Route to navigate to when clicked. Ignored if `onClick` is given. */
15748
+ route?: string;
15749
+ /** Override the default navigate behaviour. */
15750
+ onClick?: () => void;
15751
+ }
15752
+
15626
15753
  export declare type NiceNavShellPersistence = 'memory' | 'localStorage' | 'session';
15627
15754
 
15628
15755
  export declare interface NiceNavShellProps {
@@ -15638,6 +15765,60 @@ export declare interface NiceNavShellProps {
15638
15765
  topNavProps?: NiceTopNavProps;
15639
15766
  /** Sidebar navigation slot. */
15640
15767
  sidebar?: Slot;
15768
+ /**
15769
+ * Shared navigation model. When provided, the shell renders an internal
15770
+ * `NiceSidebarNav` in the sidebar slot (unless an explicit `sidebar` slot
15771
+ * is given) AND forwards the same model to the embedded mobile hamburger
15772
+ * inside `NiceTopNav`. This guarantees one source of truth for both layouts.
15773
+ */
15774
+ sidebarData?: SidebarNavDataNode[];
15775
+ /** User id forwarded to NiceSidebarNav (preferences scope). */
15776
+ sidebarUserId?: string;
15777
+ /** Active route highlighted in the sidebar (defaults to `activeRoute`). */
15778
+ sidebarActiveRoute?: string;
15779
+ /**
15780
+ * Fired when a view is clicked anywhere in the sidebar (desktop or mobile).
15781
+ *
15782
+ * The optional third arg carries the sidebar's `leftClickBehavior` pref
15783
+ * (or `forceNew: true` when the "Open in new tab" context-menu action is
15784
+ * used). NavShell honours it automatically when `autoOpenSidebarRoutes`
15785
+ * is enabled — handlers can ignore it for backward compat.
15786
+ */
15787
+ onSidebarNavigate?: (route: string, view: SidebarNavView, opts?: {
15788
+ forceNew?: boolean;
15789
+ }) => void;
15790
+ /**
15791
+ * When true (default when tabs are enabled), NavShell auto-calls
15792
+ * `openRoute(route, { forceNew })` whenever the sidebar fires
15793
+ * `onNavigate`. Disable to keep the legacy "consumer must wire up
15794
+ * navigation manually" behaviour.
15795
+ */
15796
+ autoOpenSidebarRoutes?: boolean;
15797
+ /**
15798
+ * Resolves a route key to a URL. Forwarded to the auto-rendered
15799
+ * `NiceSidebarNav` so its right-click context menu can show "Open in
15800
+ * new browser tab" and "Copy link".
15801
+ */
15802
+ routeToUrl?: (route: string) => string;
15803
+ /**
15804
+ * Auto-merge the built-in sidebar preference page routes
15805
+ * (`preferences/general`, `/display`, `/order`, `/hidden`, `/reset`) into
15806
+ * `routes`. Defaults to `true` when `sidebarData` is provided. User-defined
15807
+ * routes with matching keys still win.
15808
+ */
15809
+ includeSidebarPreferenceRoutes?: boolean;
15810
+ /**
15811
+ * Viewport breakpoint (px). At or below this width, the desktop sidebar is
15812
+ * hidden and the navigation is delegated to the top-nav hamburger drawer
15813
+ * (which uses the same `sidebarData`). Default `720` — matches
15814
+ * `NiceTopNav`'s own `mobileBreakpoint` so the sidebar disappears at the
15815
+ * exact same width the hamburger appears (no dead zone where neither is
15816
+ * visible). Override on BOTH components together if you need a different
15817
+ * value.
15818
+ */
15819
+ mobileBreakpoint?: number;
15820
+ /** Force the shell into the mobile layout regardless of viewport. */
15821
+ forceMobileLayout?: boolean;
15641
15822
  /** Map of route → content (ReactNode or factory). */
15642
15823
  routes: Record<string, ReactNode | (() => ReactNode)>;
15643
15824
  /** Initial / default route (used when uncontrolled). */
@@ -15686,6 +15867,26 @@ export declare interface NiceNavShellProps {
15686
15867
  initialTabs?: NiceNavShellTab[];
15687
15868
  /** Routes auto-opened as pinned on first mount. */
15688
15869
  pinnedRoutes?: string[];
15870
+ /** Pin a non-closable Home tab as the first tab. Default `true` (when tabs are enabled). */
15871
+ showHomeTab?: boolean;
15872
+ /** Route key for the Home tab. Default `'home'`. */
15873
+ homeRoute?: string;
15874
+ /** Icon rendered in the Home tab. Defaults to a built-in inline house SVG. */
15875
+ homeIcon?: ReactNode;
15876
+ /** Optional label next to the icon. Default `undefined` (icon-only tab). */
15877
+ homeLabel?: ReactNode;
15878
+ /** Content rendered for the Home route. Defaults to a smart `NiceNavShellHome` dashboard. */
15879
+ homeContent?: ReactNode;
15880
+ /** Display name passed to the default Home dashboard greeting. Ignored when `homeContent` is set. */
15881
+ homeUserName?: string;
15882
+ /** Extra props forwarded to the default `NiceNavShellHome` dashboard. Ignored when `homeContent` is set. */
15883
+ homeDashboardProps?: Partial<NiceNavShellHomeProps>;
15884
+ /** Show the built-in `?` button in the embedded top-nav and wire the default help flow. Default `false`. */
15885
+ showHelpButton?: boolean;
15886
+ /** Override default help steps. When omitted, NavShell auto-generates steps from visible elements. */
15887
+ helpSteps?: NiceTutorialStep[];
15888
+ /** Disable individual default steps by key. */
15889
+ helpStepsExclude?: Array<'topNav' | 'sidebar' | 'tabs' | 'content'>;
15689
15890
  className?: string;
15690
15891
  contentClassName?: string;
15691
15892
  'data-testid'?: string;
@@ -15890,6 +16091,12 @@ export declare interface NiceNotificationsProps {
15890
16091
  badgeMax?: number;
15891
16092
  /** Size variant of the trigger. */
15892
16093
  size?: 'sm' | 'md' | 'lg';
16094
+ /**
16095
+ * Visual variant. `'ghost'` removes border, background and hover-border
16096
+ * — only the bell icon (with badge) is shown. Designed for dense toolbars
16097
+ * (e.g. NiceTopNav narrow mode). Default: `'default'`.
16098
+ */
16099
+ variant?: 'default' | 'ghost';
15893
16100
  className?: string;
15894
16101
  style?: default_2.CSSProperties;
15895
16102
  id?: string;
@@ -18898,8 +19105,25 @@ export declare interface NiceSidebarNavProps {
18898
19105
  userId?: string;
18899
19106
  /** Currently active route (for item highlighting) */
18900
19107
  activeRoute?: string;
18901
- /** Called when user clicks a navigable view */
18902
- onNavigate?: (route: string, view: SidebarNavView) => void;
19108
+ /**
19109
+ * Called when user clicks a navigable view.
19110
+ *
19111
+ * `opts.forceNew` mirrors the user's `leftClickBehavior` preference (or the
19112
+ * "Open in new tab" context-menu action). Hosts that don't care about this
19113
+ * — e.g. a single-pane layout — can ignore the third argument; nothing else
19114
+ * changes for them.
19115
+ */
19116
+ onNavigate?: (route: string, view: SidebarNavView, opts?: {
19117
+ forceNew?: boolean;
19118
+ }) => void;
19119
+ /**
19120
+ * Resolves a route key to a URL. When provided, the right-click menu shows
19121
+ * "Open in new browser tab" (via `window.open`) and "Copy link". When
19122
+ * omitted, both items are hidden.
19123
+ */
19124
+ routeToUrl?: (route: string) => string;
19125
+ /** Enable the right-click context menu on view nodes. Default `true`. */
19126
+ contextMenu?: boolean;
18903
19127
  /**
18904
19128
  * Override the initial enableModeIcons flag.
18905
19129
  * Can be toggled later via Preferences.
@@ -18929,6 +19153,14 @@ export declare interface NiceSidebarNavProps {
18929
19153
  * Default `false`.
18930
19154
  */
18931
19155
  minimal?: boolean;
19156
+ /**
19157
+ * **Embedded mode** — render the sidebar inside another container (e.g. a
19158
+ * mobile drawer / hamburger menu). Forces full width, drops the footer with
19159
+ * the collapse-btn (there is nothing to collapse to inside a drawer) and
19160
+ * ignores `collapsed` / `width` / `collapsedWidth`. The mode strip and the
19161
+ * full navigation tree stay intact. Default `false`.
19162
+ */
19163
+ embedded?: boolean;
18932
19164
  /** Optional header slot rendered above the mode strip / tree (e.g. workspace switcher). */
18933
19165
  header?: ReactNode;
18934
19166
  /** Optional footer slot rendered below the standard footer-toggle row. */
@@ -18951,6 +19183,58 @@ export declare interface NiceSidebarNavProps {
18951
19183
  'data-testid'?: string;
18952
19184
  }
18953
19185
 
19186
+ export declare function NiceSidebarPrefsDisplay({ userId: userIdProp, }?: NiceSidebarPrefsDisplayProps): default_2.ReactElement;
19187
+
19188
+ export declare namespace NiceSidebarPrefsDisplay {
19189
+ var displayName: string;
19190
+ }
19191
+
19192
+ export declare interface NiceSidebarPrefsDisplayProps {
19193
+ userId?: string;
19194
+ }
19195
+
19196
+ export declare function NiceSidebarPrefsGeneral({ userId: userIdProp, }?: NiceSidebarPrefsGeneralProps): default_2.ReactElement;
19197
+
19198
+ export declare namespace NiceSidebarPrefsGeneral {
19199
+ var displayName: string;
19200
+ }
19201
+
19202
+ export declare interface NiceSidebarPrefsGeneralProps {
19203
+ /** Explicit override — used when consuming this page outside a NavShell scope. */
19204
+ userId?: string;
19205
+ }
19206
+
19207
+ export declare function NiceSidebarPrefsHidden({ userId: userIdProp, }?: NiceSidebarPrefsHiddenProps): default_2.ReactElement;
19208
+
19209
+ export declare namespace NiceSidebarPrefsHidden {
19210
+ var displayName: string;
19211
+ }
19212
+
19213
+ export declare interface NiceSidebarPrefsHiddenProps {
19214
+ userId?: string;
19215
+ }
19216
+
19217
+ export declare function NiceSidebarPrefsOrder({ userId: userIdProp, data: dataProp, }?: NiceSidebarPrefsOrderProps): default_2.ReactElement;
19218
+
19219
+ export declare namespace NiceSidebarPrefsOrder {
19220
+ var displayName: string;
19221
+ }
19222
+
19223
+ export declare interface NiceSidebarPrefsOrderProps {
19224
+ userId?: string;
19225
+ data?: SidebarNavDataNode[];
19226
+ }
19227
+
19228
+ export declare function NiceSidebarPrefsReset({ userId: userIdProp, }?: NiceSidebarPrefsResetProps): default_2.ReactElement;
19229
+
19230
+ export declare namespace NiceSidebarPrefsReset {
19231
+ var displayName: string;
19232
+ }
19233
+
19234
+ export declare interface NiceSidebarPrefsResetProps {
19235
+ userId?: string;
19236
+ }
19237
+
18954
19238
  export { NiceSignalRConfig }
18955
19239
 
18956
19240
  export declare const NiceSignature: default_2.ForwardRefExoticComponent<NiceSignatureProps & default_2.RefAttributes<NiceSignatureRef>>;
@@ -20355,10 +20639,14 @@ export declare interface NiceThemeBuilderProps extends NiceBaseProps {
20355
20639
  livePreview?: boolean;
20356
20640
  /** Currently focused token from NiceThemePreview (auto-switches section + scrolls) */
20357
20641
  focusedToken?: string;
20642
+ /** Show the embedded NiceThemePreview pane (default: true) */
20643
+ showPreview?: boolean;
20644
+ /** Layout placement of the preview pane (default: 'right') */
20645
+ previewPlacement?: 'right' | 'bottom';
20358
20646
  }
20359
20647
 
20360
20648
  /** Editable sections in the {@link NiceThemeBuilder}. */
20361
- export declare type NiceThemeBuilderSection = 'general' | 'colors' | 'backgrounds' | 'background-image' | 'text' | 'borders' | 'spacing' | 'typography' | 'shadows' | 'transitions';
20649
+ export declare type NiceThemeBuilderSection = 'general' | 'colors' | 'backgrounds' | 'background-image' | 'text' | 'borders' | 'spacing' | 'typography' | 'shadows' | 'transitions' | 'nesting';
20362
20650
 
20363
20651
  export { NiceThemeColors }
20364
20652
 
@@ -20507,6 +20795,12 @@ export declare interface NiceThemePickerProps extends NiceFormFieldProps, DualVi
20507
20795
  * dropdown alignment. Default: false.
20508
20796
  */
20509
20797
  compact?: boolean;
20798
+ /**
20799
+ * Visual variant. `'ghost'` removes border, background and the dropdown
20800
+ * arrow — only the preview swatch is shown. Designed for dense toolbars
20801
+ * (e.g. NiceTopNav narrow mode). Default: `'default'`.
20802
+ */
20803
+ variant?: 'default' | 'ghost';
20510
20804
  /** Dropdown horizontal alignment. Default: `'auto'` in compact, `'left'` otherwise. */
20511
20805
  dropdownAlign?: DropdownAlign;
20512
20806
  /**
@@ -21065,6 +21359,33 @@ export declare interface NiceTopNavProps {
21065
21359
  userMenu?: NiceTopNavMenuItem[];
21066
21360
  onProfile?: () => void;
21067
21361
  onLogout?: () => void;
21362
+ /**
21363
+ * Whether to render the workspace `<select>` row above the navigation tree
21364
+ * in the hamburger pull-down panel. Visibility is ALWAYS prop-controlled
21365
+ * (not auto-derived from `mobilePanels.length`) — consumers decide when it
21366
+ * makes sense to show it. Requires signed-in `user`. Default: `false`.
21367
+ */
21368
+ showMobilePanelSelector?: boolean;
21369
+ /** List of panels/workspaces the user has access to. */
21370
+ mobilePanels?: Array<{
21371
+ id: string;
21372
+ label: string;
21373
+ icon?: default_2.ReactNode;
21374
+ }>;
21375
+ /** Currently active panel id (controls the workspace `<select>` value). */
21376
+ activeMobilePanelId?: string;
21377
+ /** Notified when user picks a different panel from the workspace selector. */
21378
+ onMobilePanelChange?: (id: string) => void;
21379
+ /**
21380
+ * Render a mode toolbar (favorites / all / …) row above the navigation
21381
+ * in the hamburger pull-down panel. Requires signed-in `user`. NOTE: when
21382
+ * panel renders `<NiceSidebarNav embedded enableModeIcons>` (i.e. you
21383
+ * pass `sidebarData`), the sidebar already has its own mode strip — leave
21384
+ * this `false` for that branch to avoid a duplicate bar. Default: `false`.
21385
+ */
21386
+ showMobilePanelModes?: boolean;
21387
+ /** Optional custom mode toolbar; replaces the default cosmetic pills. */
21388
+ mobilePanelModes?: default_2.ReactNode;
21068
21389
  showLogin?: boolean;
21069
21390
  loginLabel?: string;
21070
21391
  onLoginClick?: () => void;
@@ -21086,6 +21407,16 @@ export declare interface NiceTopNavProps {
21086
21407
  settingsMenuItems?: UserMenuItem[];
21087
21408
  /** Settings button aria-label / tooltip. */
21088
21409
  settingsLabel?: string;
21410
+ /**
21411
+ * Show a built-in `?` help button in the right cluster. Used by
21412
+ * `NiceNavShell` to launch the contextual help walkthrough.
21413
+ * Default `false`.
21414
+ */
21415
+ showHelpButton?: boolean;
21416
+ /** Help button click handler — required when `showHelpButton` is true. */
21417
+ onHelpClick?: () => void;
21418
+ /** Help button aria-label / tooltip. Defaults to translated "Help". */
21419
+ helpLabel?: string;
21089
21420
  /**
21090
21421
  * Wrap search + language + theme pickers in a collapsible cluster with a
21091
21422
  * chevron toggle. When `true` (default), the cluster starts collapsed and
@@ -21098,6 +21429,26 @@ export declare interface NiceTopNavProps {
21098
21429
  rightClusterDefaultOpen?: boolean;
21099
21430
  leftContent?: default_2.ReactNode;
21100
21431
  rightContent?: default_2.ReactNode;
21432
+ /**
21433
+ * Full navigation data shared with `NiceSidebarNav`. When provided, the
21434
+ * hamburger drawer renders an embedded `NiceSidebarNav` (full mode strip +
21435
+ * multi-level tree + search/favorites/preferences) instead of the legacy
21436
+ * flat menu. Lets a parent shell drive both the desktop sidebar and the
21437
+ * mobile hamburger from one model.
21438
+ */
21439
+ sidebarData?: SidebarNavDataNode[];
21440
+ /** User id forwarded to the embedded `NiceSidebarNav` (preferences scope). */
21441
+ sidebarUserId?: string;
21442
+ /** Active route highlighted in the mobile sidebar drawer. */
21443
+ sidebarActiveRoute?: string;
21444
+ /** Fired when a view is clicked in the mobile sidebar drawer. Closes the drawer. */
21445
+ onSidebarNavigate?: (route: string, view: SidebarNavView) => void;
21446
+ /**
21447
+ * Force the narrow "2-row" mobile layout regardless of viewport width. Use
21448
+ * from `NiceNavShell` to keep the breakpoint decision in one place when the
21449
+ * shell already hides the sidebar.
21450
+ */
21451
+ forceMobileLayout?: boolean;
21101
21452
  className?: string;
21102
21453
  style?: default_2.CSSProperties;
21103
21454
  id?: string;
@@ -21381,6 +21732,11 @@ export declare interface NiceTreeSelectProps extends NiceFormFieldProps {
21381
21732
  /** Only allow selection of leaf nodes */
21382
21733
  selectableLeafsOnly?: boolean;
21383
21734
  clearable?: boolean;
21735
+ /**
21736
+ * Maximum nesting depth rendered (1..10). Beyond this, nodes are treated as
21737
+ * leaves (children not rendered, no expand toggle). Default: unlimited.
21738
+ */
21739
+ maxDepth?: number;
21384
21740
  }
21385
21741
 
21386
21742
  export declare const NiceTreeView: default_2.FC<NiceTreeViewProps>;
@@ -21427,6 +21783,11 @@ export declare interface NiceTreeViewProps extends NiceBaseProps {
21427
21783
  editable?: boolean;
21428
21784
  /** Called when a node label is edited. */
21429
21785
  onNodeEdit?: (key: string, newText: string) => void;
21786
+ /**
21787
+ * Maximum nesting depth rendered (1..10). Beyond this, nodes are treated as
21788
+ * leaves (children not rendered, no expand toggle). Default: unlimited.
21789
+ */
21790
+ maxDepth?: number;
21430
21791
  }
21431
21792
 
21432
21793
  /**
@@ -23603,6 +23964,9 @@ export { PreferencesStorageAdapter }
23603
23964
 
23604
23965
  export { PreferencesSyncAdapter }
23605
23966
 
23967
+ /** Ordered list of preference categories rendered as a navigable tree. */
23968
+ export declare const PREFS_CATEGORIES: SidebarPrefsCategory[];
23969
+
23606
23970
  /**
23607
23971
  * Preload all heavy components
23608
23972
  *
@@ -24945,6 +25309,9 @@ export declare type ShapeType = 'rectangle' | 'ellipse' | 'polygon' | 'freehand'
24945
25309
 
24946
25310
  export declare const ShopifyConnector: ConnectorDefinition;
24947
25311
 
25312
+ /** Route keys produced by {@link buildSidebarPrefsRoutes}. */
25313
+ export declare const SIDEBAR_PREFS_ROUTE_KEYS: ReadonlyArray<string>;
25314
+
24948
25315
  /**
24949
25316
  * Top-level data node: one data source with all its navigation children.
24950
25317
  * modules → used in 'all' mode (depth: source → module → view)
@@ -24983,6 +25350,26 @@ export declare interface SidebarNavFavorite {
24983
25350
  addedAt: number;
24984
25351
  }
24985
25352
 
25353
+ export declare interface SidebarNavHelpers {
25354
+ setMode: (mode: SidebarNavMode) => void;
25355
+ setEnableModeIcons: (enabled: boolean) => void;
25356
+ toggleMode: (mode: SidebarNavMode) => void;
25357
+ pinSource: (mode: SidebarNavMode, sourceId: string) => void;
25358
+ unpinSource: (mode: SidebarNavMode, sourceId: string) => void;
25359
+ hideItem: (item: SidebarNavHiddenItem) => void;
25360
+ restoreItem: (id: string) => void;
25361
+ addFavorite: (fav: SidebarNavFavorite) => void;
25362
+ removeFavorite: (id: string) => void;
25363
+ setMaxDepth: (mode: SidebarNavMode, depth: number) => void;
25364
+ toggleCollapse: (nodeId: string) => void;
25365
+ setAutoExpand: (v: boolean) => void;
25366
+ /** Set the user's preferred left-click behaviour for sidebar items. */
25367
+ setLeftClickBehavior: (v: 'focus-existing' | 'open-new') => void;
25368
+ /** Replace the per-mode ordering of item ids. Pass `null` to clear (revert to data-defined order). */
25369
+ reorderItems: (mode: SidebarNavMode, orderedIds: string[] | null) => void;
25370
+ resetAll: () => void;
25371
+ }
25372
+
24986
25373
  export declare interface SidebarNavHiddenItem {
24987
25374
  /** The id of the hidden entity (source/module/view/role/unit id) */
24988
25375
  id: string;
@@ -24993,7 +25380,7 @@ export declare interface SidebarNavHiddenItem {
24993
25380
  }
24994
25381
 
24995
25382
  /** Display mode for the sidebar navigation */
24996
- export declare type SidebarNavMode = 'all' | 'by-role' | 'by-unit' | 'favorites' | 'preferences';
25383
+ export declare type SidebarNavMode = 'all' | 'by-role' | 'by-unit' | 'favorites' | 'search' | 'preferences';
24997
25384
 
24998
25385
  /** A module containing multiple views */
24999
25386
  export declare interface SidebarNavModule {
@@ -25050,6 +25437,22 @@ export declare interface SidebarNavUserPrefs {
25050
25437
  collapsedIds: string[];
25051
25438
  /** Start everything expanded (default: true) */
25052
25439
  autoExpand: boolean;
25440
+ /**
25441
+ * What left-click does when the route is already open in a tab.
25442
+ * - `'focus-existing'` (default): focus the existing tab (no duplicate)
25443
+ * - `'open-new'`: always open a new tab (duplicates allowed)
25444
+ *
25445
+ * Communicated to the host via the third arg of `onNavigate`
25446
+ * (`{ forceNew: boolean }`). NavShell honours it when
25447
+ * `autoOpenSidebarRoutes` is enabled.
25448
+ */
25449
+ leftClickBehavior: 'focus-existing' | 'open-new';
25450
+ /**
25451
+ * User-chosen ordering of item ids for each mode. Items not present
25452
+ * keep their original (data-defined) order after the listed ones.
25453
+ * Edited from the "Order" page in preferences.
25454
+ */
25455
+ itemOrder: Partial<Record<SidebarNavMode, string[]>>;
25053
25456
  }
25054
25457
 
25055
25458
  /** A single navigable view / entity view */
@@ -25066,6 +25469,39 @@ export declare interface SidebarNavView {
25066
25469
  moduleId?: string;
25067
25470
  }
25068
25471
 
25472
+ /**
25473
+ * Definition of a single navigable preferences category. Mirrors the shape
25474
+ * of a `SidebarNavView` so it can be rendered by the existing sidebar tree
25475
+ * code without special-casing.
25476
+ */
25477
+ export declare interface SidebarPrefsCategory {
25478
+ id: string;
25479
+ /** Route key — passed to `onNavigate`. Convention: `preferences/<slug>`. */
25480
+ route: string;
25481
+ /** Translation key for the visible label. */
25482
+ labelKey: string;
25483
+ /** English fallback for the label. */
25484
+ labelDefault: string;
25485
+ /** Inline SVG icon node. */
25486
+ icon: ReactNode;
25487
+ }
25488
+
25489
+ export declare function SidebarPrefsScopeProvider({ userId, data, children, }: SidebarPrefsScopeProviderProps): default_2.ReactElement;
25490
+
25491
+ export declare interface SidebarPrefsScopeProviderProps extends SidebarPrefsScopeValue {
25492
+ children: ReactNode;
25493
+ }
25494
+
25495
+ /**
25496
+ * Shared scope wiring needed by the preferences pages rendered as NavShell
25497
+ * routes. NavShell sets this whenever `sidebarUserId` and/or `sidebarData`
25498
+ * are provided; pages also accept explicit prop overrides.
25499
+ */
25500
+ export declare interface SidebarPrefsScopeValue {
25501
+ userId?: string;
25502
+ data?: SidebarNavDataNode[];
25503
+ }
25504
+
25069
25505
  export declare interface SignalRLiveChartSourceConfig {
25070
25506
  /** SignalR hub connection. */
25071
25507
  hubConnection: {
@@ -27374,6 +27810,14 @@ export { useShowAt }
27374
27810
 
27375
27811
  export { UseShowAtOptions }
27376
27812
 
27813
+ export declare function useSidebarNavPrefs(userId: string | undefined, initialEnableModeIcons: boolean | undefined, controlledPrefs: Partial<SidebarNavUserPrefs> | undefined, onChange: ((prefs: SidebarNavUserPrefs) => void) | undefined): [SidebarNavUserPrefs, SidebarNavHelpers];
27814
+
27815
+ /** Resolve `{ userId, data }` for a preferences page. Props override context. */
27816
+ export declare function useSidebarPrefsScope(overrides?: SidebarPrefsScopeValue): SidebarPrefsScopeValue;
27817
+
27818
+ /** Shortcut for pages that only need the userId. */
27819
+ export declare function useSidebarUserId(override?: string): string | undefined;
27820
+
27377
27821
  /**
27378
27822
  * Hook to get a namespaced storage adapter.
27379
27823
  */