@nice2dev/ui 1.0.5 → 1.0.8
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 +253 -207
- package/dist/NiceAPIFlow.doc-DnQLPUie.js +30 -0
- package/dist/NiceAPIFlow.doc-Dx4qw1lm.cjs +6 -0
- package/dist/NiceBranchManager.doc-BXjiENlD.cjs +6 -0
- package/dist/NiceBranchManager.doc-xLB82YwU.js +30 -0
- package/dist/NiceButton-B5RXLDwI.cjs +1 -0
- package/dist/NiceButton-CDiS45Ya.cjs +1 -0
- package/dist/NiceButton-D9l39Rs7.js +595 -0
- package/dist/NiceButton-DmTHNHet.js +450 -0
- package/dist/NiceCodeTemplate.doc-BWxTE4C_.cjs +6 -0
- package/dist/NiceCodeTemplate.doc-CA2U5F-v.js +30 -0
- package/dist/NiceDataBranchGraph.doc-CkitupWc.js +29 -0
- package/dist/NiceDataBranchGraph.doc-DDUgipqH.cjs +5 -0
- package/dist/NiceDataBranchManager.doc-B0ODKOs4.js +30 -0
- package/dist/NiceDataBranchManager.doc-CC5o8ihs.cjs +6 -0
- package/dist/NiceDataConflictResolver.doc-CdzScNie.cjs +5 -0
- package/dist/NiceDataConflictResolver.doc-V8vxYAeo.js +29 -0
- package/dist/NiceDataDiffViewer.doc-CR14Bq3A.cjs +6 -0
- package/dist/NiceDataDiffViewer.doc-w2I2QjhX.js +30 -0
- package/dist/NiceDataMapper.doc-C7jSyHRM.js +30 -0
- package/dist/NiceDataMapper.doc-DXjQHz87.cjs +6 -0
- package/dist/NiceDataMergeBuilder.doc-CV32WC_w.cjs +6 -0
- package/dist/NiceDataMergeBuilder.doc-DtuYb3nx.js +30 -0
- package/dist/NiceDataSnapshot.doc-CFLkY3ry.js +30 -0
- package/dist/NiceDataSnapshot.doc-CpZyQ17u.cjs +6 -0
- package/dist/NiceErrorBoundary-BAeqfoSc.cjs +1 -0
- package/dist/NiceErrorBoundary-D1hh5GGe.js +732 -0
- package/dist/NiceErrorBoundary-Dta4TGee.cjs +1 -0
- package/dist/NiceErrorBoundary-niMx1aSJ.js +837 -0
- package/dist/NiceEventOrchestrator.doc-C4SJfIDV.js +30 -0
- package/dist/NiceEventOrchestrator.doc-CxjsLxBG.cjs +6 -0
- package/dist/NiceGitBlame.doc-BG3_K9_0.cjs +6 -0
- package/dist/NiceGitBlame.doc-DrJABEat.js +30 -0
- package/dist/NiceGitConflictResolver.doc-BK7hAfz6.js +30 -0
- package/dist/NiceGitConflictResolver.doc-CgroGM9_.cjs +6 -0
- package/dist/NiceGitDiffViewer.doc-BAwgcY_3.cjs +6 -0
- package/dist/NiceGitDiffViewer.doc-BXKJeP-E.js +30 -0
- package/dist/NiceGitGraph.doc-B-WtGuzn.cjs +5 -0
- package/dist/NiceGitGraph.doc-DxnDPCgC.js +29 -0
- package/dist/NiceGitHooks.doc-BrEizvMp.js +29 -0
- package/dist/NiceGitHooks.doc-C4EdV5zj.cjs +5 -0
- package/dist/NiceMergeRequestBuilder.doc-C5p8mYuh.cjs +6 -0
- package/dist/NiceMergeRequestBuilder.doc-Ct9RCmU8.js +30 -0
- package/dist/NiceModuleLifecyclePanel-BapdidD6.js +4776 -0
- package/dist/NiceModuleLifecyclePanel-Brg1RLwi.cjs +1 -0
- package/dist/NiceModuleLifecyclePanel-CsFsm534.cjs +1 -0
- package/dist/NiceModuleLifecyclePanel-I_TXRiiY.js +5053 -0
- package/dist/NicePinCodeInput-4q8yULuo.js +13359 -0
- package/dist/NicePinCodeInput-CrMfdxxc.js +15287 -0
- package/dist/NicePinCodeInput-D0aF9MK8.cjs +692 -0
- package/dist/NicePinCodeInput-eD2q8nGa.cjs +692 -0
- package/dist/NicePinCodeInput.css +1 -0
- package/dist/NicePipelineEditor.doc-0eGt8zbX.cjs +5 -0
- package/dist/NicePipelineEditor.doc-DTmaOebn.js +29 -0
- package/dist/NicePipelineMonitor.doc-67CmsRcf.cjs +5 -0
- package/dist/NicePipelineMonitor.doc-mSMdhuG8.js +29 -0
- package/dist/NiceSavedQueryPanel-BZNvqSQW.cjs +596 -0
- package/dist/NiceSavedQueryPanel-CUAsdOjJ.js +6190 -0
- package/dist/NiceSavedQueryPanel-DUw8plYP.js +5666 -0
- package/dist/NiceSavedQueryPanel-xpk09zy1.cjs +596 -0
- package/dist/NiceSavedQueryPanel.css +1 -0
- package/dist/NiceStateDesigner.doc-B36u0hNU.js +29 -0
- package/dist/NiceStateDesigner.doc-MPmvNHSx.cjs +5 -0
- package/dist/NiceStockChart-CHlOnWzN.cjs +287 -0
- package/dist/NiceStockChart-Cpmv9_Cc.js +2341 -0
- package/dist/NiceStockChart.css +1 -0
- package/dist/NiceTestBuilder.doc-BFInj8GJ.js +30 -0
- package/dist/NiceTestBuilder.doc-CB03U_uR.cjs +6 -0
- package/dist/NiceToggle-C1UKGXmJ.js +209 -0
- package/dist/NiceToggle-CaY1u82g.js +277 -0
- package/dist/NiceToggle-DFJFQv_Z.cjs +1 -0
- package/dist/NiceToggle-lVi-ETi0.cjs +1 -0
- package/dist/NiceWindow-D1awkyFl.js +1636 -0
- package/dist/NiceWindow-IdHAcP70.cjs +1 -0
- package/dist/NiceWindow-SiCaREbq.js +1408 -0
- package/dist/NiceWindow-yARTUJsg.cjs +1 -0
- package/dist/charts-Bx_kNBsE.js +4280 -0
- package/dist/charts-DECVsCHX.cjs +754 -0
- package/dist/charts.cjs +1 -0
- package/dist/charts.css +1 -0
- package/dist/charts.d.ts +1043 -0
- package/dist/charts.mjs +23 -0
- package/dist/core-BZBTsGWN.cjs +96 -0
- package/dist/core-BpghV7Ls.js +17555 -0
- package/dist/core-CfXsl755.js +16305 -0
- package/dist/core-DGJSUW64.cjs +96 -0
- package/dist/data-branching-De4ExX-S.cjs +1 -0
- package/dist/data-branching-DiRfob1f.js +6071 -0
- package/dist/data-branching.cjs +1 -0
- package/dist/data-branching.d.ts +401 -0
- package/dist/data-branching.mjs +9 -0
- package/dist/data.cjs +1 -0
- package/dist/data.d.ts +2003 -0
- package/dist/data.mjs +21 -0
- package/dist/devops-BnYinjkT.cjs +17 -0
- package/dist/devops-Ckh57eti.js +7198 -0
- package/dist/devops.cjs +1 -0
- package/dist/devops.d.ts +758 -0
- package/dist/devops.mjs +12 -0
- package/dist/editors.cjs +1 -0
- package/dist/editors.d.ts +2728 -0
- package/dist/editors.mjs +66 -0
- package/dist/feedback.cjs +1 -0
- package/dist/feedback.d.ts +339 -0
- package/dist/feedback.mjs +16 -0
- package/dist/index-C853adw1.cjs +6199 -0
- package/dist/index-CBIZ6mTQ.cjs +5734 -0
- package/dist/index-CIl98Vbm.js +72951 -0
- package/dist/index-CNwVELPJ.js +62857 -0
- package/dist/index-CUx_-gKK.cjs +1 -0
- package/dist/index-x8mRM4Jc.js +17 -0
- package/dist/index.cjs +1 -7866
- package/dist/index.css +1 -0
- package/dist/index.d.ts +4888 -180
- package/dist/index.mjs +1021 -105889
- package/dist/lazy.cjs +1 -0
- package/dist/lazy.d.ts +1880 -0
- package/dist/lazy.mjs +98 -0
- package/dist/navigation.cjs +1 -0
- package/dist/navigation.d.ts +1862 -0
- package/dist/navigation.mjs +576 -0
- package/dist/no-code-BCuadkm4.cjs +332 -0
- package/dist/no-code-TL7PyulA.js +7005 -0
- package/dist/no-code.cjs +1 -0
- package/dist/no-code.d.ts +870 -0
- package/dist/no-code.mjs +13 -0
- package/dist/overlays.cjs +1 -0
- package/dist/overlays.d.ts +706 -0
- package/dist/overlays.mjs +482 -0
- package/package.json +51 -1
|
@@ -0,0 +1,706 @@
|
|
|
1
|
+
import { default as default_2 } from 'react';
|
|
2
|
+
import { ForwardRefExoticComponent } from 'react';
|
|
3
|
+
import { ReactNode } from 'react';
|
|
4
|
+
import { RefAttributes } from 'react';
|
|
5
|
+
|
|
6
|
+
/**
|
|
7
|
+
* Per-component visibility & interaction level used by the access control system.
|
|
8
|
+
* - `'full'` — fully interactive (default)
|
|
9
|
+
* - `'readOnly'` — renders but cannot be edited
|
|
10
|
+
* - `'disabled'` — renders greyed-out
|
|
11
|
+
* - `'hidden'` — not rendered at all
|
|
12
|
+
*/
|
|
13
|
+
declare type NiceAccessMode = 'full' | 'readOnly' | 'disabled' | 'hidden';
|
|
14
|
+
|
|
15
|
+
export declare const NiceActionSheet: default_2.FC<NiceActionSheetProps>;
|
|
16
|
+
|
|
17
|
+
/** An action item in the {@link NiceActionSheet}. */
|
|
18
|
+
declare interface NiceActionSheetItem {
|
|
19
|
+
/** Button text. */
|
|
20
|
+
text: string;
|
|
21
|
+
/** Optional leading icon. */
|
|
22
|
+
icon?: default_2.ReactNode;
|
|
23
|
+
/** Visual type (danger shows in red). */
|
|
24
|
+
type?: 'normal' | 'danger';
|
|
25
|
+
/** Disable the item. */
|
|
26
|
+
disabled?: boolean;
|
|
27
|
+
/** Click handler. */
|
|
28
|
+
onClick?: () => void;
|
|
29
|
+
}
|
|
30
|
+
|
|
31
|
+
/** Props for the {@link NiceActionSheet} component — a mobile-style bottom action sheet. */
|
|
32
|
+
export declare interface NiceActionSheetProps extends NiceBaseProps {
|
|
33
|
+
/** Whether the sheet is visible. */
|
|
34
|
+
visible: boolean;
|
|
35
|
+
/** Called when the sheet is dismissed. */
|
|
36
|
+
onClose: () => void;
|
|
37
|
+
/** Optional header title. */
|
|
38
|
+
title?: string;
|
|
39
|
+
/** Action items. */
|
|
40
|
+
items: NiceActionSheetItem[];
|
|
41
|
+
/** Show a cancel button at the bottom. */
|
|
42
|
+
showCancelButton?: boolean;
|
|
43
|
+
/** Cancel button text. */
|
|
44
|
+
cancelText?: string;
|
|
45
|
+
}
|
|
46
|
+
|
|
47
|
+
/** Base props inherited by every NiceToDev component. */
|
|
48
|
+
declare interface NiceBaseProps {
|
|
49
|
+
/** Additional CSS class name(s). */
|
|
50
|
+
className?: string;
|
|
51
|
+
/** Inline style object. */
|
|
52
|
+
style?: React.CSSProperties;
|
|
53
|
+
/** HTML `id` attribute. When omitted a stable auto-generated id is used. */
|
|
54
|
+
id?: string;
|
|
55
|
+
/** Tooltip text shown on hover. */
|
|
56
|
+
title?: string;
|
|
57
|
+
/** Test identifier for integration / e2e test selectors. */
|
|
58
|
+
'data-testid'?: string;
|
|
59
|
+
/** Controls component visibility and interaction — see {@link NiceAccessMode}. */
|
|
60
|
+
accessMode?: NiceAccessMode;
|
|
61
|
+
/**
|
|
62
|
+
* Visual presentation style override.
|
|
63
|
+
* When set, overrides the global `displayStyle` from `NiceThemeProvider`.
|
|
64
|
+
* @see NiceDisplayStyle
|
|
65
|
+
*/
|
|
66
|
+
displayStyle?: NiceDisplayStyle;
|
|
67
|
+
}
|
|
68
|
+
|
|
69
|
+
export declare const NiceBlockUI: default_2.ForwardRefExoticComponent<NiceBlockUIProps & default_2.RefAttributes<HTMLDivElement>>;
|
|
70
|
+
|
|
71
|
+
/** Props for the {@link NiceBlockUI} component — an overlay that blocks user interaction on its children. */
|
|
72
|
+
export declare interface NiceBlockUIProps extends NiceBaseProps {
|
|
73
|
+
/** Block the content when `true`. */
|
|
74
|
+
blocked: boolean;
|
|
75
|
+
/** Custom overlay message or spinner. */
|
|
76
|
+
message?: default_2.ReactNode;
|
|
77
|
+
/** Content to be blocked. */
|
|
78
|
+
children: default_2.ReactNode;
|
|
79
|
+
}
|
|
80
|
+
|
|
81
|
+
/**
|
|
82
|
+
* Mobile-first bottom sheet component.
|
|
83
|
+
* Supports drag-to-dismiss and snap points.
|
|
84
|
+
*/
|
|
85
|
+
export declare const NiceBottomSheet: default_2.FC<NiceBottomSheetProps>;
|
|
86
|
+
|
|
87
|
+
declare interface NiceBottomSheetProps extends NiceOverlayBaseProps {
|
|
88
|
+
/** Sheet content */
|
|
89
|
+
children: default_2.ReactNode;
|
|
90
|
+
/** Sheet title */
|
|
91
|
+
title?: string;
|
|
92
|
+
/** Show drag handle (default true) */
|
|
93
|
+
showHandle?: boolean;
|
|
94
|
+
/** Snap points as percentages of viewport height (default [0.5, 0.9]) */
|
|
95
|
+
snapPoints?: number[];
|
|
96
|
+
/** Initial snap point index (default 0) */
|
|
97
|
+
initialSnap?: number;
|
|
98
|
+
/** Allow full expansion (default true) */
|
|
99
|
+
expandable?: boolean;
|
|
100
|
+
/** Enable haptic feedback on snap (default true) */
|
|
101
|
+
hapticFeedback?: boolean;
|
|
102
|
+
}
|
|
103
|
+
|
|
104
|
+
export declare const NiceBox: default_2.FC<NiceBoxProps>;
|
|
105
|
+
|
|
106
|
+
/** Props for the {@link NiceBox} component — a flex-based layout container. */
|
|
107
|
+
export declare interface NiceBoxProps extends NiceBaseProps {
|
|
108
|
+
/** Flex direction. */
|
|
109
|
+
direction?: 'row' | 'column';
|
|
110
|
+
/** Cross-axis alignment. */
|
|
111
|
+
align?: 'flex-start' | 'center' | 'flex-end' | 'stretch';
|
|
112
|
+
/** Main-axis alignment. */
|
|
113
|
+
justify?: 'flex-start' | 'center' | 'flex-end' | 'space-between' | 'space-around' | 'space-evenly';
|
|
114
|
+
/** Allow wrapping. */
|
|
115
|
+
wrap?: boolean;
|
|
116
|
+
/** Gap between children (px or CSS value). */
|
|
117
|
+
gap?: number | string;
|
|
118
|
+
/** CSS flex shorthand. */
|
|
119
|
+
flex?: number | string;
|
|
120
|
+
/** Box content. */
|
|
121
|
+
children?: default_2.ReactNode;
|
|
122
|
+
}
|
|
123
|
+
|
|
124
|
+
export declare interface NiceCommand {
|
|
125
|
+
id: string;
|
|
126
|
+
label: string;
|
|
127
|
+
action: () => void | Promise<void>;
|
|
128
|
+
category?: string;
|
|
129
|
+
shortcut?: string;
|
|
130
|
+
icon?: ReactNode;
|
|
131
|
+
description?: string;
|
|
132
|
+
keywords?: string[];
|
|
133
|
+
disabled?: boolean;
|
|
134
|
+
hidden?: boolean;
|
|
135
|
+
}
|
|
136
|
+
|
|
137
|
+
declare interface NiceCommandPaletteContextValue {
|
|
138
|
+
registerCommand: (command: NiceCommand) => void;
|
|
139
|
+
unregisterCommand: (id: string) => void;
|
|
140
|
+
registerCommands: (commands: NiceCommand[]) => void;
|
|
141
|
+
open: () => void;
|
|
142
|
+
close: () => void;
|
|
143
|
+
toggle: () => void;
|
|
144
|
+
isOpen: boolean;
|
|
145
|
+
executeCommand: (id: string) => void;
|
|
146
|
+
}
|
|
147
|
+
|
|
148
|
+
export declare interface NiceCommandPaletteProps {
|
|
149
|
+
/** Placeholder text for the search input */
|
|
150
|
+
placeholder?: string;
|
|
151
|
+
/** Maximum items shown before scrolling */
|
|
152
|
+
maxVisible?: number;
|
|
153
|
+
/** Maximum recent commands to remember */
|
|
154
|
+
maxRecent?: number;
|
|
155
|
+
/** Custom class name */
|
|
156
|
+
className?: string;
|
|
157
|
+
/** Custom empty state text */
|
|
158
|
+
emptyText?: string;
|
|
159
|
+
/** Close on action execution */
|
|
160
|
+
closeOnAction?: boolean;
|
|
161
|
+
/** Called when palette opens */
|
|
162
|
+
onOpen?: () => void;
|
|
163
|
+
/** Called when palette closes */
|
|
164
|
+
onClose?: () => void;
|
|
165
|
+
}
|
|
166
|
+
|
|
167
|
+
export declare const NiceCommandPaletteProvider: default_2.FC<NiceCommandPaletteProviderProps>;
|
|
168
|
+
|
|
169
|
+
export declare interface NiceCommandPaletteProviderProps extends NiceCommandPaletteProps {
|
|
170
|
+
children: ReactNode;
|
|
171
|
+
/** Pre-registered commands */
|
|
172
|
+
commands?: NiceCommand[];
|
|
173
|
+
}
|
|
174
|
+
|
|
175
|
+
/**
|
|
176
|
+
* Context menu that appears on right-click.
|
|
177
|
+
*/
|
|
178
|
+
export declare const NiceContextMenu: default_2.FC<NiceContextMenuProps>;
|
|
179
|
+
|
|
180
|
+
declare interface NiceContextMenuItem {
|
|
181
|
+
key: string;
|
|
182
|
+
label: default_2.ReactNode;
|
|
183
|
+
icon?: default_2.ReactNode;
|
|
184
|
+
disabled?: boolean;
|
|
185
|
+
danger?: boolean;
|
|
186
|
+
divider?: boolean;
|
|
187
|
+
onClick?: () => void;
|
|
188
|
+
children?: NiceContextMenuItem[];
|
|
189
|
+
}
|
|
190
|
+
|
|
191
|
+
declare interface NiceContextMenuProps {
|
|
192
|
+
/** Menu items */
|
|
193
|
+
items: NiceContextMenuItem[];
|
|
194
|
+
/** Content to wrap with context menu */
|
|
195
|
+
children: default_2.ReactNode;
|
|
196
|
+
/** Callback when menu opens */
|
|
197
|
+
onOpen?: () => void;
|
|
198
|
+
/** Callback when menu closes */
|
|
199
|
+
onClose?: () => void;
|
|
200
|
+
/** Additional className for menu */
|
|
201
|
+
className?: string;
|
|
202
|
+
}
|
|
203
|
+
|
|
204
|
+
/**
|
|
205
|
+
* Cross-component visual presentation style.
|
|
206
|
+
* Each style maps 1:1 to a ThemeVariantConfig preset controlling
|
|
207
|
+
* buttons, inputs, cards, badges, tabs, toggles, tooltips, tables, etc.
|
|
208
|
+
*/
|
|
209
|
+
declare type NiceDisplayStyle = 'default' | 'minimal' | 'rounded' | 'sharp' | 'glass' | 'neumorphic' | 'playful' | 'enterprise' | 'modern3d' | 'brutalist' | 'luxe' | 'pill' | 'flat' | 'editorial' | 'dashboard' | 'softCloud' | 'cosmic' | 'corporate' | 'bank' | 'government' | 'military' | 'legal' | 'medical' | 'swiss' | 'scandinavian' | 'bauhaus' | 'notebook' | 'origami' | 'watercolor' | 'monochrome' | 'paper' | 'zen' | 'terminal' | 'hacker' | 'retro8bit' | 'synthwave' | 'cyberpunk' | 'steampunk' | 'vapor' | 'neon' | 'windows95' | 'material' | 'fluent' | 'cupertino' | 'ant' | 'bootstrap' | 'chakra' | 'notion' | 'linear' | 'vercel' | 'candy' | 'bubblegum' | 'cartoon' | 'kawaii' | 'circus' | 'gaming' | 'kiddo' | 'disco' | 'clown';
|
|
210
|
+
|
|
211
|
+
/**
|
|
212
|
+
* Drawer component that slides in from screen edges.
|
|
213
|
+
* Supports swipe-to-close on touch devices.
|
|
214
|
+
*/
|
|
215
|
+
export declare const NiceDrawer: default_2.FC<NiceOverlayDrawerProps>;
|
|
216
|
+
|
|
217
|
+
export declare const NiceLoadPanel: default_2.FC<NiceLoadPanelProps>;
|
|
218
|
+
|
|
219
|
+
/** Props for the {@link NiceLoadPanel} component — a full-screen or container-bound loading overlay. */
|
|
220
|
+
export declare interface NiceLoadPanelProps extends NiceBaseProps {
|
|
221
|
+
/** Show the panel when `true`. */
|
|
222
|
+
visible: boolean;
|
|
223
|
+
/** Loading message text. */
|
|
224
|
+
message?: string;
|
|
225
|
+
/** Container element to confine the overlay. */
|
|
226
|
+
container?: default_2.RefObject<HTMLElement | null>;
|
|
227
|
+
/** Show a spinning indicator. */
|
|
228
|
+
showIndicator?: boolean;
|
|
229
|
+
/** Show a semi-transparent backdrop. */
|
|
230
|
+
shading?: boolean;
|
|
231
|
+
}
|
|
232
|
+
|
|
233
|
+
/**
|
|
234
|
+
* Modal component with focus trap, backdrop, and keyboard handling.
|
|
235
|
+
*/
|
|
236
|
+
export declare const NiceModal: default_2.FC<NiceOverlayModalProps>;
|
|
237
|
+
|
|
238
|
+
export declare const NiceModalBody: default_2.FC<NiceModalBodyProps>;
|
|
239
|
+
|
|
240
|
+
declare interface NiceModalBodyProps {
|
|
241
|
+
children: default_2.ReactNode;
|
|
242
|
+
className?: string;
|
|
243
|
+
}
|
|
244
|
+
|
|
245
|
+
export declare const NiceModalFooter: default_2.FC<NiceModalFooterProps>;
|
|
246
|
+
|
|
247
|
+
declare interface NiceModalFooterProps {
|
|
248
|
+
children: default_2.ReactNode;
|
|
249
|
+
className?: string;
|
|
250
|
+
}
|
|
251
|
+
|
|
252
|
+
export declare const NiceModalHeader: default_2.FC<NiceModalHeaderProps>;
|
|
253
|
+
|
|
254
|
+
declare interface NiceModalHeaderProps {
|
|
255
|
+
children: default_2.ReactNode;
|
|
256
|
+
/** Show close button */
|
|
257
|
+
showClose?: boolean;
|
|
258
|
+
/** Close handler (required if showClose) */
|
|
259
|
+
onClose?: () => void;
|
|
260
|
+
className?: string;
|
|
261
|
+
}
|
|
262
|
+
|
|
263
|
+
export declare interface NiceOverlayBaseProps {
|
|
264
|
+
/** Whether the overlay is visible */
|
|
265
|
+
open: boolean;
|
|
266
|
+
/** Callback when overlay should close */
|
|
267
|
+
onClose: () => void;
|
|
268
|
+
/** Whether to close on backdrop click (default true) */
|
|
269
|
+
closeOnBackdropClick?: boolean;
|
|
270
|
+
/** Whether to close on Escape key (default true) */
|
|
271
|
+
closeOnEscape?: boolean;
|
|
272
|
+
/** Z-index for the overlay (default 1000) */
|
|
273
|
+
zIndex?: number;
|
|
274
|
+
/** Additional className */
|
|
275
|
+
className?: string;
|
|
276
|
+
/** Additional styles */
|
|
277
|
+
style?: default_2.CSSProperties;
|
|
278
|
+
}
|
|
279
|
+
|
|
280
|
+
export declare interface NiceOverlayDrawerProps extends NiceOverlayBaseProps {
|
|
281
|
+
/** Drawer content */
|
|
282
|
+
children: default_2.ReactNode;
|
|
283
|
+
/** Position the drawer appears from */
|
|
284
|
+
position?: 'left' | 'right' | 'top' | 'bottom';
|
|
285
|
+
/** Drawer size (width for left/right, height for top/bottom) */
|
|
286
|
+
size?: number | string;
|
|
287
|
+
/** Drawer title (for aria-label) */
|
|
288
|
+
title?: string;
|
|
289
|
+
/** Enable swipe to close (default true on touch devices) */
|
|
290
|
+
swipeToClose?: boolean;
|
|
291
|
+
}
|
|
292
|
+
|
|
293
|
+
export declare interface NiceOverlayModalProps extends NiceOverlayBaseProps {
|
|
294
|
+
/** Modal content */
|
|
295
|
+
children: default_2.ReactNode;
|
|
296
|
+
/** Modal title (for aria-label) */
|
|
297
|
+
title?: string;
|
|
298
|
+
/** Modal size */
|
|
299
|
+
size?: 'sm' | 'md' | 'lg' | 'xl' | 'full';
|
|
300
|
+
/** Disable focus trap (default false) */
|
|
301
|
+
disableFocusTrap?: boolean;
|
|
302
|
+
/** Disable body scroll when modal is open (default true) */
|
|
303
|
+
disableBodyScroll?: boolean;
|
|
304
|
+
}
|
|
305
|
+
|
|
306
|
+
/**
|
|
307
|
+
* Popover component with positioning and various trigger modes.
|
|
308
|
+
*/
|
|
309
|
+
export declare const NiceOverlayPopover: default_2.FC<NicePopoverProps_2>;
|
|
310
|
+
|
|
311
|
+
export declare const NicePopover: default_2.FC<NicePopoverProps>;
|
|
312
|
+
|
|
313
|
+
/** Placement of the {@link NicePopover} relative to its target. */
|
|
314
|
+
declare type NicePopoverPosition = 'top' | 'bottom' | 'left' | 'right';
|
|
315
|
+
|
|
316
|
+
/** Props for the {@link NicePopover} component — a positioned popup attached to a target element. */
|
|
317
|
+
export declare interface NicePopoverProps extends NiceBaseProps {
|
|
318
|
+
/** Whether the popover is visible. */
|
|
319
|
+
visible: boolean;
|
|
320
|
+
/** Called when the popover should close. */
|
|
321
|
+
onClose: () => void;
|
|
322
|
+
/** Reference to the target element the popover is anchored to. */
|
|
323
|
+
targetRef: default_2.RefObject<HTMLElement | null>;
|
|
324
|
+
/** Placement relative to target. */
|
|
325
|
+
position?: NicePopoverPosition;
|
|
326
|
+
/** Optional header title. */
|
|
327
|
+
title?: string;
|
|
328
|
+
/** Show an arrow pointing toward the target. */
|
|
329
|
+
showArrow?: boolean;
|
|
330
|
+
/** Popover width. */
|
|
331
|
+
width?: number | string;
|
|
332
|
+
/** Popover content. */
|
|
333
|
+
children?: default_2.ReactNode;
|
|
334
|
+
}
|
|
335
|
+
|
|
336
|
+
declare interface NicePopoverProps_2 {
|
|
337
|
+
/** Trigger element */
|
|
338
|
+
trigger: default_2.ReactNode;
|
|
339
|
+
/** Popover content */
|
|
340
|
+
children: default_2.ReactNode;
|
|
341
|
+
/** Placement relative to trigger */
|
|
342
|
+
placement?: PopoverPlacement;
|
|
343
|
+
/** Open trigger mode */
|
|
344
|
+
triggerMode?: 'click' | 'hover' | 'manual';
|
|
345
|
+
/** Controlled open state */
|
|
346
|
+
open?: boolean;
|
|
347
|
+
/** Callback when open state changes */
|
|
348
|
+
onOpenChange?: (open: boolean) => void;
|
|
349
|
+
/** Hover delay in ms */
|
|
350
|
+
hoverDelay?: number;
|
|
351
|
+
/** Offset from trigger (px) */
|
|
352
|
+
offset?: number;
|
|
353
|
+
/** Additional className */
|
|
354
|
+
className?: string;
|
|
355
|
+
/** Arrow visible */
|
|
356
|
+
showArrow?: boolean;
|
|
357
|
+
}
|
|
358
|
+
|
|
359
|
+
export declare const NiceResizable: default_2.FC<NiceResizableProps>;
|
|
360
|
+
|
|
361
|
+
/** Props for the {@link NiceResizable} component — a wrapper that adds drag resize handles to its children. */
|
|
362
|
+
export declare interface NiceResizableProps extends NiceBaseProps {
|
|
363
|
+
/** Current width in px. */
|
|
364
|
+
width?: number;
|
|
365
|
+
/** Current height in px. */
|
|
366
|
+
height?: number;
|
|
367
|
+
/** Minimum width in px. */
|
|
368
|
+
minWidth?: number;
|
|
369
|
+
/** Minimum height in px. */
|
|
370
|
+
minHeight?: number;
|
|
371
|
+
/** Maximum width in px. */
|
|
372
|
+
maxWidth?: number;
|
|
373
|
+
/** Maximum height in px. */
|
|
374
|
+
maxHeight?: number;
|
|
375
|
+
/** Which handles to show. */
|
|
376
|
+
handles?: NiceResizeHandle[];
|
|
377
|
+
/** Called when the element is resized. */
|
|
378
|
+
onResize?: (size: {
|
|
379
|
+
width: number;
|
|
380
|
+
height: number;
|
|
381
|
+
}) => void;
|
|
382
|
+
/** Content to be made resizable. */
|
|
383
|
+
children?: default_2.ReactNode;
|
|
384
|
+
}
|
|
385
|
+
|
|
386
|
+
/** Resize handle position for the {@link NiceResizable} component. */
|
|
387
|
+
declare type NiceResizeHandle = 'top' | 'right' | 'bottom' | 'left' | 'topRight' | 'bottomRight' | 'bottomLeft' | 'topLeft';
|
|
388
|
+
|
|
389
|
+
export declare const NiceResponsiveBox: default_2.FC<NiceResponsiveBoxProps>;
|
|
390
|
+
|
|
391
|
+
/** A flex item within the {@link NiceResponsiveBox}. */
|
|
392
|
+
declare interface NiceResponsiveBoxItem {
|
|
393
|
+
/** Flex grow ratio. */
|
|
394
|
+
ratio?: number;
|
|
395
|
+
/** Fixed base size (px or CSS value). */
|
|
396
|
+
baseSize?: number | string;
|
|
397
|
+
/** Flex shrink factor. */
|
|
398
|
+
shrink?: number;
|
|
399
|
+
/** Item content. */
|
|
400
|
+
children: default_2.ReactNode;
|
|
401
|
+
}
|
|
402
|
+
|
|
403
|
+
/** Props for the {@link NiceResponsiveBox} component — a flex container with configurable ratios and base sizes. */
|
|
404
|
+
export declare interface NiceResponsiveBoxProps extends NiceBaseProps {
|
|
405
|
+
/** Flex direction. */
|
|
406
|
+
direction?: 'row' | 'column';
|
|
407
|
+
/** Flex items. */
|
|
408
|
+
items: NiceResponsiveBoxItem[];
|
|
409
|
+
/** Gap between items (px or CSS value). */
|
|
410
|
+
gap?: number | string;
|
|
411
|
+
}
|
|
412
|
+
|
|
413
|
+
export declare const NiceScrollView: default_2.FC<NiceScrollViewProps>;
|
|
414
|
+
|
|
415
|
+
/** Props for the {@link NiceScrollView} component — a styled scrollable container with configurable scrollbar visibility. */
|
|
416
|
+
export declare interface NiceScrollViewProps extends NiceBaseProps {
|
|
417
|
+
/** Scroll direction. */
|
|
418
|
+
direction?: 'horizontal' | 'vertical' | 'both';
|
|
419
|
+
/** When to show scrollbars. */
|
|
420
|
+
showScrollbar?: 'always' | 'onInteraction' | 'never';
|
|
421
|
+
/** Container width (px or CSS value). */
|
|
422
|
+
width?: number | string;
|
|
423
|
+
/** Container height (px or CSS value). */
|
|
424
|
+
height?: number | string;
|
|
425
|
+
/** Called on scroll. */
|
|
426
|
+
onScroll?: (e: default_2.UIEvent<HTMLDivElement>) => void;
|
|
427
|
+
/** Scrollable content. */
|
|
428
|
+
children?: default_2.ReactNode;
|
|
429
|
+
}
|
|
430
|
+
|
|
431
|
+
/** T-shirt sizing used across all components for consistent visual density. */
|
|
432
|
+
declare type NiceSize = 'xxs' | 'xs' | 'sm' | 'md' | 'lg' | 'xl' | 'xxl';
|
|
433
|
+
|
|
434
|
+
export declare const NiceTutorial: default_2.FC<NiceTutorialProps>;
|
|
435
|
+
|
|
436
|
+
/** Props for the {@link NiceTutorial} component — a guided walkthrough overlay with step-by-step highlighting. */
|
|
437
|
+
export declare interface NiceTutorialProps {
|
|
438
|
+
/** Array of ordered tutorial steps */
|
|
439
|
+
steps: NiceTutorialStep[];
|
|
440
|
+
/** Starts the tutorial when true */
|
|
441
|
+
active: boolean;
|
|
442
|
+
/** Called when tutorial finishes (last step completed) */
|
|
443
|
+
onFinish?: () => void;
|
|
444
|
+
/** Called when tutorial is skipped */
|
|
445
|
+
onSkip?: () => void;
|
|
446
|
+
/** Called on step change */
|
|
447
|
+
onStepChange?: (stepIndex: number) => void;
|
|
448
|
+
/** Close on pressing Escape (default true) */
|
|
449
|
+
closeOnEscape?: boolean;
|
|
450
|
+
/** Close on overlay click (default false) */
|
|
451
|
+
closeOnOverlayClick?: boolean;
|
|
452
|
+
/** Show step progress indicator (default true) */
|
|
453
|
+
showProgress?: boolean;
|
|
454
|
+
/** Show skip button (default true) */
|
|
455
|
+
showSkipButton?: boolean;
|
|
456
|
+
/** Custom labels */
|
|
457
|
+
labels?: {
|
|
458
|
+
next?: string;
|
|
459
|
+
back?: string;
|
|
460
|
+
finish?: string;
|
|
461
|
+
skip?: string;
|
|
462
|
+
stepOf?: string;
|
|
463
|
+
};
|
|
464
|
+
/** Animation duration in ms (default 300) */
|
|
465
|
+
animationDuration?: number;
|
|
466
|
+
/** Overlay opacity (default 0.6) */
|
|
467
|
+
overlayOpacity?: number;
|
|
468
|
+
/** Z-index for the overlay (default 10000) */
|
|
469
|
+
zIndex?: number;
|
|
470
|
+
}
|
|
471
|
+
|
|
472
|
+
export declare const NiceTutorialProvider: default_2.FC<NiceTutorialProviderProps>;
|
|
473
|
+
|
|
474
|
+
/** Props for the {@link NiceTutorialProvider} component — a React context provider for imperative tutorial control. */
|
|
475
|
+
export declare interface NiceTutorialProviderProps {
|
|
476
|
+
/** Application content. */
|
|
477
|
+
children: default_2.ReactNode;
|
|
478
|
+
}
|
|
479
|
+
|
|
480
|
+
/** A single step in a {@link NiceTutorial} flow. */
|
|
481
|
+
export declare interface NiceTutorialStep {
|
|
482
|
+
/** CSS selector or ref-based query to find the target element */
|
|
483
|
+
target: string;
|
|
484
|
+
/** Step title displayed in the tooltip */
|
|
485
|
+
title: string;
|
|
486
|
+
/** Step description / instructions (supports HTML) */
|
|
487
|
+
content: string;
|
|
488
|
+
/** Tooltip placement relative to target element */
|
|
489
|
+
placement?: 'top' | 'bottom' | 'left' | 'right' | 'auto';
|
|
490
|
+
/** Highlight inset padding around the target (default 8) */
|
|
491
|
+
highlightPadding?: number;
|
|
492
|
+
/** If true, wait for user action (e.g. click) before advancing */
|
|
493
|
+
waitForAction?: boolean;
|
|
494
|
+
/** Show an arrow pointing from tooltip to target (default true) */
|
|
495
|
+
showArrow?: boolean;
|
|
496
|
+
/** Called when this step becomes active */
|
|
497
|
+
onEnter?: () => void;
|
|
498
|
+
/** Called when this step is left */
|
|
499
|
+
onLeave?: () => void;
|
|
500
|
+
/** Optional event on target that auto-advances to next step */
|
|
501
|
+
advanceOn?: {
|
|
502
|
+
event: string;
|
|
503
|
+
};
|
|
504
|
+
/** If true, scroll target into view on step entry */
|
|
505
|
+
scrollIntoView?: boolean;
|
|
506
|
+
/** Disable interaction with highlighted element (no click-through) */
|
|
507
|
+
disableInteraction?: boolean;
|
|
508
|
+
}
|
|
509
|
+
|
|
510
|
+
export declare const NiceWindow: ForwardRefExoticComponent<NiceWindowProps & RefAttributes<HTMLDivElement>>;
|
|
511
|
+
|
|
512
|
+
export declare const NiceWindowManager: ForwardRefExoticComponent<NiceWindowManagerProps & RefAttributes<HTMLDivElement>>;
|
|
513
|
+
|
|
514
|
+
/** Props for the {@link NiceWindowManager} component — a multi-window manager with taskbar and z-index stacking. */
|
|
515
|
+
export declare interface NiceWindowManagerProps extends NiceBaseProps {
|
|
516
|
+
/** Managed window entries. */
|
|
517
|
+
windows: NiceWindowState_2[];
|
|
518
|
+
/** Called when the window list changes (drag, resize, minimize, etc.). */
|
|
519
|
+
onChange?: (windows: NiceWindowState_2[]) => void;
|
|
520
|
+
/** Called when a window is closed. */
|
|
521
|
+
onClose?: (key: string) => void;
|
|
522
|
+
/** Called when a window gains focus. */
|
|
523
|
+
onFocus?: (key: string) => void;
|
|
524
|
+
/** Show a taskbar at the bottom with window buttons. */
|
|
525
|
+
showTaskbar?: boolean;
|
|
526
|
+
/** Size preset. */
|
|
527
|
+
size?: NiceSize;
|
|
528
|
+
}
|
|
529
|
+
|
|
530
|
+
/** X/Y coordinates of a {@link NiceWindow}. */
|
|
531
|
+
export declare interface NiceWindowPosition {
|
|
532
|
+
/** Horizontal offset in px. */
|
|
533
|
+
x: number;
|
|
534
|
+
/** Vertical offset in px. */
|
|
535
|
+
y: number;
|
|
536
|
+
}
|
|
537
|
+
|
|
538
|
+
/** Props for the {@link NiceWindow} component — a draggable, resizable, snappable desktop window with title bar controls. */
|
|
539
|
+
export declare interface NiceWindowProps extends NiceBaseProps {
|
|
540
|
+
/** Unique window identifier. */
|
|
541
|
+
windowKey: string;
|
|
542
|
+
/** Window title. */
|
|
543
|
+
title: string;
|
|
544
|
+
/** Icon displayed in title bar */
|
|
545
|
+
icon?: React.ReactNode;
|
|
546
|
+
/** Window content */
|
|
547
|
+
children?: React.ReactNode;
|
|
548
|
+
/** Footer content */
|
|
549
|
+
footer?: React.ReactNode;
|
|
550
|
+
/** Initial or controlled x position */
|
|
551
|
+
x?: number;
|
|
552
|
+
/** Initial or controlled y position */
|
|
553
|
+
y?: number;
|
|
554
|
+
/** Initial or controlled width */
|
|
555
|
+
width?: number;
|
|
556
|
+
/** Initial or controlled height */
|
|
557
|
+
height?: number;
|
|
558
|
+
/** Minimum width */
|
|
559
|
+
minWidth?: number;
|
|
560
|
+
/** Minimum height */
|
|
561
|
+
minHeight?: number;
|
|
562
|
+
/** Maximum width */
|
|
563
|
+
maxWidth?: number;
|
|
564
|
+
/** Maximum height */
|
|
565
|
+
maxHeight?: number;
|
|
566
|
+
/** Z-index for stacking */
|
|
567
|
+
zIndex?: number;
|
|
568
|
+
/** Allow closing */
|
|
569
|
+
closable?: boolean;
|
|
570
|
+
/** Allow minimizing */
|
|
571
|
+
minimizable?: boolean;
|
|
572
|
+
/** Allow maximizing */
|
|
573
|
+
maximizable?: boolean;
|
|
574
|
+
/** Allow full screen */
|
|
575
|
+
fullscreenable?: boolean;
|
|
576
|
+
/** Allow pinning (always on top) */
|
|
577
|
+
pinnable?: boolean;
|
|
578
|
+
/** Allow resizing */
|
|
579
|
+
resizable?: boolean;
|
|
580
|
+
/** Allow dragging */
|
|
581
|
+
draggable?: boolean;
|
|
582
|
+
/** Allow snap to edges */
|
|
583
|
+
snappable?: boolean;
|
|
584
|
+
/** Snap threshold in px */
|
|
585
|
+
snapThreshold?: number;
|
|
586
|
+
/** Whether minimized */
|
|
587
|
+
minimized?: boolean;
|
|
588
|
+
/** Whether maximized */
|
|
589
|
+
maximized?: boolean;
|
|
590
|
+
/** Whether fullscreen */
|
|
591
|
+
fullscreen?: boolean;
|
|
592
|
+
/** Whether pinned (always on top) */
|
|
593
|
+
pinned?: boolean;
|
|
594
|
+
/** Whether focused/active */
|
|
595
|
+
focused?: boolean;
|
|
596
|
+
onClose?: (key: string) => void;
|
|
597
|
+
onMinimize?: (key: string) => void;
|
|
598
|
+
onMaximize?: (key: string, maximized: boolean) => void;
|
|
599
|
+
onFullscreen?: (key: string, fullscreen: boolean) => void;
|
|
600
|
+
onPin?: (key: string, pinned: boolean) => void;
|
|
601
|
+
onFocus?: (key: string) => void;
|
|
602
|
+
onMove?: (key: string, position: NiceWindowPosition) => void;
|
|
603
|
+
onResize?: (key: string, size: NiceWindowSize) => void;
|
|
604
|
+
onSnap?: (key: string, snap: NiceWindowSnapPosition) => void;
|
|
605
|
+
/** Called on double-click of title bar (toggle maximize) */
|
|
606
|
+
onTitleBarDoubleClick?: (key: string) => void;
|
|
607
|
+
/** Window size preset */
|
|
608
|
+
size?: NiceSize;
|
|
609
|
+
/** Status bar content */
|
|
610
|
+
statusBar?: React.ReactNode;
|
|
611
|
+
/** Additional title bar actions */
|
|
612
|
+
titleBarActions?: React.ReactNode;
|
|
613
|
+
}
|
|
614
|
+
|
|
615
|
+
/** Dimensions of a {@link NiceWindow}. */
|
|
616
|
+
export declare interface NiceWindowSize {
|
|
617
|
+
/** Width in px. */
|
|
618
|
+
width: number;
|
|
619
|
+
/** Height in px. */
|
|
620
|
+
height: number;
|
|
621
|
+
}
|
|
622
|
+
|
|
623
|
+
/** Snap positions for the {@link NiceWindow} component. */
|
|
624
|
+
export declare type NiceWindowSnapPosition = 'none' | 'left' | 'right' | 'top' | 'bottom' | 'top-left' | 'top-right' | 'bottom-left' | 'bottom-right';
|
|
625
|
+
|
|
626
|
+
/** Full runtime state of a {@link NiceWindow}. */
|
|
627
|
+
export declare interface NiceWindowState {
|
|
628
|
+
/** Current position. */
|
|
629
|
+
position: NiceWindowPosition;
|
|
630
|
+
/** Current size. */
|
|
631
|
+
size: NiceWindowSize;
|
|
632
|
+
/** Whether minimized. */
|
|
633
|
+
minimized: boolean;
|
|
634
|
+
/** Whether maximized. */
|
|
635
|
+
maximized: boolean;
|
|
636
|
+
/** Whether fullscreen. */
|
|
637
|
+
fullscreen: boolean;
|
|
638
|
+
/** Whether pinned (always-on-top). */
|
|
639
|
+
pinned: boolean;
|
|
640
|
+
/** Snap position. */
|
|
641
|
+
snapped: NiceWindowSnapPosition;
|
|
642
|
+
/** Stacking z-index. */
|
|
643
|
+
zIndex: number;
|
|
644
|
+
/** Whether focused. */
|
|
645
|
+
focused: boolean;
|
|
646
|
+
}
|
|
647
|
+
|
|
648
|
+
/** A managed window entry for the {@link NiceWindowManager}. */
|
|
649
|
+
declare interface NiceWindowState_2 {
|
|
650
|
+
/** Unique key. */
|
|
651
|
+
key: string;
|
|
652
|
+
/** Window title. */
|
|
653
|
+
title: string;
|
|
654
|
+
/** Window body content. */
|
|
655
|
+
content: React.ReactNode;
|
|
656
|
+
/** X position. */
|
|
657
|
+
x: number;
|
|
658
|
+
/** Y position. */
|
|
659
|
+
y: number;
|
|
660
|
+
/** Width in px. */
|
|
661
|
+
width: number;
|
|
662
|
+
/** Height in px. */
|
|
663
|
+
height: number;
|
|
664
|
+
/** Whether minimized. */
|
|
665
|
+
minimized?: boolean;
|
|
666
|
+
/** Whether maximized. */
|
|
667
|
+
maximized?: boolean;
|
|
668
|
+
/** Stacking z-index. */
|
|
669
|
+
zIndex?: number;
|
|
670
|
+
/** Title bar icon. */
|
|
671
|
+
icon?: React.ReactNode;
|
|
672
|
+
/** Allow resizing. */
|
|
673
|
+
resizable?: boolean;
|
|
674
|
+
/** Allow closing. */
|
|
675
|
+
closable?: boolean;
|
|
676
|
+
/** Allow minimizing. */
|
|
677
|
+
minimizable?: boolean;
|
|
678
|
+
/** Allow maximizing. */
|
|
679
|
+
maximizable?: boolean;
|
|
680
|
+
}
|
|
681
|
+
|
|
682
|
+
declare type PopoverPlacement = 'top' | 'top-start' | 'top-end' | 'bottom' | 'bottom-start' | 'bottom-end' | 'left' | 'left-start' | 'left-end' | 'right' | 'right-start' | 'right-end';
|
|
683
|
+
|
|
684
|
+
/** Context value provided by the {@link NiceTutorialProvider} for imperative tutorial control. */
|
|
685
|
+
export declare interface TutorialContextValue {
|
|
686
|
+
/** Start a tutorial with the given steps */
|
|
687
|
+
startTutorial: (steps: NiceTutorialStep[]) => void;
|
|
688
|
+
/** Stop the current tutorial */
|
|
689
|
+
stopTutorial: () => void;
|
|
690
|
+
/** Whether a tutorial is currently active */
|
|
691
|
+
isActive: boolean;
|
|
692
|
+
/** Current step index */
|
|
693
|
+
currentStep: number;
|
|
694
|
+
/** Go to next step */
|
|
695
|
+
nextStep: () => void;
|
|
696
|
+
/** Go to previous step */
|
|
697
|
+
prevStep: () => void;
|
|
698
|
+
/** Go to a specific step */
|
|
699
|
+
goToStep: (index: number) => void;
|
|
700
|
+
}
|
|
701
|
+
|
|
702
|
+
export declare function useCommandPalette(): NiceCommandPaletteContextValue;
|
|
703
|
+
|
|
704
|
+
export declare function useRegisterCommands(commands: NiceCommand[]): void;
|
|
705
|
+
|
|
706
|
+
export { }
|