@nice2dev/ui 1.4.20 → 1.4.22

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 (42) hide show
  1. package/CHANGELOG.md +90 -0
  2. package/dist/NiceCodeEditor-CBgbzwjx.cjs +297 -0
  3. package/dist/NiceGantt-Drl4gvw9.cjs +1 -0
  4. package/dist/{NiceGantt.doc-B6YZcJvG.cjs → NiceGantt.doc-DTv0r7bP.cjs} +2 -2
  5. package/dist/{NiceMention-DhaTUqvR.cjs → NiceMention-D330ovOt.cjs} +1 -1
  6. package/dist/NiceModuleLifecyclePanel-jckyVqqt.cjs +1 -0
  7. package/dist/NiceWindow-DQyf5wat.cjs +1 -0
  8. package/dist/{core-lazy-BhQxFuLf.cjs → core-lazy-CUnBYI-T.cjs} +1 -1
  9. package/dist/display/NiceDocumentApprovalFlow.mjs +67 -89
  10. package/dist/display/NiceLeaderboard.mjs +47 -40
  11. package/dist/display/NiceQuestCard.mjs +93 -76
  12. package/dist/docs/NiceGantt.doc.json.mjs +9 -9
  13. package/dist/documentation/utils.mjs +1 -1
  14. package/dist/editors/rich/NiceCodeEditor.mjs +525 -504
  15. package/dist/editors.cjs +1 -1
  16. package/dist/index.cjs +99 -94
  17. package/dist/index.d.ts +63 -2
  18. package/dist/index.mjs +778 -776
  19. package/dist/navigation/NiceMenu.mjs +249 -248
  20. package/dist/navigation.cjs +1 -1
  21. package/dist/navigation.d.ts +6 -0
  22. package/dist/overlays/NiceResponsiveBox.mjs +51 -24
  23. package/dist/overlays/NiceTutorial.mjs +136 -127
  24. package/dist/overlays.cjs +1 -1
  25. package/dist/overlays.d.ts +25 -2
  26. package/dist/planning/NiceGantt.mjs +130 -121
  27. package/dist/planning/NiceStepper.mjs +36 -35
  28. package/dist/style.css +2 -2
  29. package/dist/tools/NiceDraggable.mjs +44 -29
  30. package/dist/tools/NiceGitManager.mjs +5 -0
  31. package/dist/tools/NiceSortable.mjs +66 -48
  32. package/dist/tools/NiceSpeechToText.mjs +67 -52
  33. package/dist/tools/NiceValidationBuilder.mjs +210 -119
  34. package/dist/tools/NiceViewRegistry.mjs +67 -34
  35. package/dist/workflow/NiceTaskInbox.mjs +14 -12
  36. package/package.json +4 -4
  37. package/dist/NiceBottomSheet.doc-keq-Fzlz.cjs +0 -8
  38. package/dist/NiceCodeEditor-DhdjnDLV.cjs +0 -289
  39. package/dist/NiceGantt-BygumlaY.cjs +0 -1
  40. package/dist/NiceModuleLifecyclePanel-DAIbzfZd.cjs +0 -1
  41. package/dist/NiceWindow-BklnkBpu.cjs +0 -1
  42. package/dist/docs/NiceBottomSheet.doc.json.mjs +0 -32
package/dist/index.d.ts CHANGED
@@ -423,6 +423,7 @@ import { NiceUserMenuResponse } from '@nice2dev/ui-core';
423
423
  import { NiceUserPreferences } from '@nice2dev/ui-core';
424
424
  import { NiceUserPreferencesProvider } from '@nice2dev/ui-core';
425
425
  import { NiceUserPreferencesProviderProps } from '@nice2dev/ui-core';
426
+ import { NiceValidationOptions } from '@nice2dev/ui-core';
426
427
  import { NiceValidationStatus } from '@nice2dev/ui-core';
427
428
  import { NiceVariant } from '@nice2dev/ui-core';
428
429
  import { NiceVisuallyHidden } from '@nice2dev/ui-core';
@@ -7478,6 +7479,9 @@ export { NICE_DISPLAY_STYLE_INFO }
7478
7479
 
7479
7480
  export { NICE_DISPLAY_STYLES }
7480
7481
 
7482
+ /** The drag data's type in `dataTransfer` (1.4.21). */
7483
+ export declare const NICE_DRAG_MIME = "application/nice-drag";
7484
+
7481
7485
  export { NICE_INPUT_DEFAULTS }
7482
7486
 
7483
7487
  export { NICE_INTENT_EVENT }
@@ -9940,6 +9944,11 @@ export declare interface NiceCodeDiffEditorProps {
9940
9944
  onModifiedChange?: (value: string) => void;
9941
9945
  /** Loading content */
9942
9946
  loading?: default_2.ReactNode;
9947
+ /**
9948
+ * Extra Monaco diff-editor options, merged over the defaults (1.4.22) — e.g.
9949
+ * `{ scrollBeyondLastLine: true }` or `{ minimap: { enabled: true } }`.
9950
+ */
9951
+ options?: Record<string, unknown>;
9943
9952
  /** Additional CSS class */
9944
9953
  className?: string;
9945
9954
  /** Test ID */
@@ -17189,6 +17198,12 @@ export declare interface NiceMenuProps extends NiceBaseProps {
17189
17198
  showDividers?: boolean;
17190
17199
  /** Top-item alignment for dropdown panels. */
17191
17200
  panelAlign?: NiceMenuAlign;
17201
+ /**
17202
+ * What `panelAlign` lines a dropdown panel up with (1.4.21): the item it opens from (default) or
17203
+ * the whole menu bar — `start` / `center` / `end` of the bar. Horizontal menus in portal mode (the
17204
+ * default); without a portal the panel stays at its item.
17205
+ */
17206
+ panelAnchor?: 'item' | 'menu';
17192
17207
  /** Min width for dropdown / sub-panel (px). */
17193
17208
  panelMinWidth?: number;
17194
17209
  /** Max width for dropdown / sub-panel (px). */
@@ -20991,6 +21006,11 @@ export declare interface NiceResponseContract {
20991
21006
  fields?: NiceFieldExpectation[];
20992
21007
  }
20993
21008
 
21009
+ /**
21010
+ * {@link NiceResponsiveBox} — a flex row of items with ratios that adapts to the room it has (1.4.21:
21011
+ * "kompletnie nieresponsywne" — it was a fixed row): it stacks into a column when narrower than
21012
+ * `stackBelow` and, with `minItemWidth`, wraps items onto new lines rather than squeezing them.
21013
+ */
20994
21014
  export declare const NiceResponsiveBox: default_2.FC<NiceResponsiveBoxProps>;
20995
21015
 
20996
21016
  /** A flex item within the {@link NiceResponsiveBox}. */
@@ -21007,12 +21027,22 @@ export declare interface NiceResponsiveBoxItem {
21007
21027
 
21008
21028
  /** Props for the {@link NiceResponsiveBox} component — a flex container with configurable ratios and base sizes. */
21009
21029
  export declare interface NiceResponsiveBoxProps extends NiceBaseProps {
21010
- /** Flex direction. */
21030
+ /** Flex direction (while the box is wide enough — see `stackBelow`). */
21011
21031
  direction?: 'row' | 'column';
21012
21032
  /** Flex items. */
21013
21033
  items?: NiceResponsiveBoxItem[];
21014
21034
  /** Gap between items (px or CSS value). */
21015
21035
  gap?: number | string;
21036
+ /**
21037
+ * Below this width of the box (px) a row stacks into a column (1.4.21; default 480, `0` never). The
21038
+ * box's own width counts, not the window's, so it adapts wherever it is placed.
21039
+ */
21040
+ stackBelow?: number;
21041
+ /**
21042
+ * Items never shrink below this width (px): they wrap onto the next line instead (1.4.21). Unset:
21043
+ * no wrapping.
21044
+ */
21045
+ minItemWidth?: number;
21016
21046
  }
21017
21047
 
21018
21048
  export { NiceResponsiveValue }
@@ -22977,6 +23007,8 @@ export declare interface NiceSpeechToTextProps extends NiceBaseProps {
22977
23007
  activeLabel?: string;
22978
23008
  /** Show the visible text label next to the icon. Defaults to `false` (icon-only). The aria-label is always present. */
22979
23009
  showLabel?: boolean;
23010
+ /** Called with the browser's error code (`not-allowed`, `audio-capture`, `no-speech`, `network`, …). */
23011
+ onError?: (code: string) => void;
22980
23012
  }
22981
23013
 
22982
23014
  export declare const NiceSpeedDialAction: default_2.FC<NiceSpeedDialProps>;
@@ -23349,8 +23381,18 @@ export declare interface NiceStepperStep {
23349
23381
  content?: default_2.ReactNode;
23350
23382
  /** Mark the step as optional. */
23351
23383
  optional?: boolean;
23384
+ /**
23385
+ * The step's state, overriding the one its place gives (1.4.21): `error` shows a cross in the error
23386
+ * colour, `skipped` a muted, dashed indicator.
23387
+ */
23388
+ status?: NiceStepperStepStatus;
23389
+ /** More under the subtitle — a note, a comment (1.4.21). */
23390
+ description?: default_2.ReactNode;
23352
23391
  }
23353
23392
 
23393
+ /** A step's state in a {@link NiceStepper} (1.4.21). */
23394
+ export declare type NiceStepperStepStatus = 'completed' | 'active' | 'pending' | 'error' | 'skipped';
23395
+
23354
23396
  export declare const NiceStockChart: default_2.ForwardRefExoticComponent<NiceStockChartProps & default_2.RefAttributes<HTMLDivElement>> & {
23355
23397
  displayName: string;
23356
23398
  };
@@ -25654,10 +25696,18 @@ export declare interface NiceTutorialProps {
25654
25696
  closeOnEscape?: boolean;
25655
25697
  /** Close on overlay click (default false) */
25656
25698
  closeOnOverlayClick?: boolean;
25657
- /** Show step progress indicator (default true) */
25699
+ /** Show the "1 of 5" step counter (default true) */
25658
25700
  showProgress?: boolean;
25659
25701
  /** Show skip button (default true) */
25660
25702
  showSkipButton?: boolean;
25703
+ /** Show the Back button from the second step on (default true). 1.4.21. */
25704
+ showBackButton?: boolean;
25705
+ /** Show the close (×) icon in the tooltip header (default: follows `showSkipButton`). 1.4.21. */
25706
+ showCloseButton?: boolean;
25707
+ /** Show the progress bar (default: follows `showAutoplay`). 1.4.21. */
25708
+ showProgressBar?: boolean;
25709
+ /** Show the autoplay speed slider next to Play (default true). 1.4.21. */
25710
+ showSpeedControl?: boolean;
25661
25711
  /** Custom labels */
25662
25712
  labels?: {
25663
25713
  next?: string;
@@ -26061,6 +26111,8 @@ export declare interface NiceValidationIssue {
26061
26111
  path?: string;
26062
26112
  }
26063
26113
 
26114
+ export { NiceValidationOptions }
26115
+
26064
26116
  /** Validation report. */
26065
26117
  export declare interface NiceValidationReport {
26066
26118
  /** View id. */
@@ -28185,6 +28237,15 @@ export declare type RbacAction = 'create' | 'read' | 'update' | 'delete' | 'expo
28185
28237
 
28186
28238
  export { ReactQueryAdapterConfig }
28187
28239
 
28240
+ /**
28241
+ * What a {@link NiceDraggable} carries, read in a drop target's `onDrop` (1.4.21): its `data` and
28242
+ * `group`, or `null` for a drag that did not come from one.
28243
+ */
28244
+ export declare function readNiceDrag(event: Pick<DragEvent, 'dataTransfer'> | default_2.DragEvent): {
28245
+ data: unknown;
28246
+ group?: string;
28247
+ } | null;
28248
+
28188
28249
  export declare interface RealtimeDataPoint {
28189
28250
  timestamp: number;
28190
28251
  value: number;