@nice2dev/ui 1.0.5 → 1.0.6
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/NiceButton-B5RXLDwI.cjs +1 -0
- package/dist/NiceButton-DmTHNHet.js +450 -0
- package/dist/NiceErrorBoundary-D1hh5GGe.js +732 -0
- package/dist/NiceErrorBoundary-Dta4TGee.cjs +1 -0
- package/dist/NiceModuleLifecyclePanel-BapdidD6.js +4776 -0
- package/dist/NiceModuleLifecyclePanel-CsFsm534.cjs +1 -0
- package/dist/NicePinCodeInput-4q8yULuo.js +13359 -0
- package/dist/NicePinCodeInput-eD2q8nGa.cjs +692 -0
- package/dist/NicePinCodeInput.css +1 -0
- package/dist/NiceSavedQueryPanel-DUw8plYP.js +5666 -0
- package/dist/NiceSavedQueryPanel-xpk09zy1.cjs +596 -0
- package/dist/NiceSavedQueryPanel.css +1 -0
- package/dist/NiceStockChart-CHlOnWzN.cjs +287 -0
- package/dist/NiceStockChart-Cpmv9_Cc.js +2341 -0
- package/dist/NiceStockChart.css +1 -0
- package/dist/NiceToggle-C1UKGXmJ.js +209 -0
- package/dist/NiceToggle-lVi-ETi0.cjs +1 -0
- package/dist/NiceWindow-D1awkyFl.js +1636 -0
- package/dist/NiceWindow-yARTUJsg.cjs +1 -0
- package/dist/charts.cjs +1 -0
- package/dist/charts.d.ts +1043 -0
- package/dist/charts.mjs +23 -0
- package/dist/core-CfXsl755.js +16305 -0
- package/dist/core-DGJSUW64.cjs +96 -0
- package/dist/data.cjs +1 -0
- package/dist/data.d.ts +2003 -0
- package/dist/data.mjs +21 -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-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 +1160 -2
- package/dist/index.mjs +972 -105889
- package/dist/navigation.cjs +1 -0
- package/dist/navigation.d.ts +1862 -0
- package/dist/navigation.mjs +519 -0
- package/dist/overlays.cjs +1 -0
- package/dist/overlays.d.ts +706 -0
- package/dist/overlays.mjs +26 -0
- package/package.json +31 -1
package/dist/editors.mjs
ADDED
|
@@ -0,0 +1,66 @@
|
|
|
1
|
+
import { N as a, a as c, b as s } from "./NiceButton-DmTHNHet.js";
|
|
2
|
+
import { N as o, a as t, b as r, c as n, d, e as u, f as l, g as p, h as P, i as I, j as k, k as m, l as C, m as E, n as g, o as x, p as T, q as A, r as S, s as b, t as D, u as L, v as R, w as f, x as B, y as F, z as M, A as w, B as h, C as y, D as G, E as H, F as j, G as v, H as K, I as O, J as U, K as V, L as W, M as q, O as z, P as J, Q, R as X, S as Y, T as Z, U as _, V as $, W as ee, X as ie, Y as ae, Z as ce, _ as se, $ as Ne, a0 as oe } from "./NicePinCodeInput-4q8yULuo.js";
|
|
3
|
+
import { N as re, a as ne, b as de } from "./NiceToggle-C1UKGXmJ.js";
|
|
4
|
+
export {
|
|
5
|
+
o as NiceAccountPicker,
|
|
6
|
+
t as NiceAddressInput,
|
|
7
|
+
r as NiceAutocomplete,
|
|
8
|
+
n as NiceCalendar,
|
|
9
|
+
d as NiceCascadeSelect,
|
|
10
|
+
re as NiceCheckbox,
|
|
11
|
+
u as NiceCodeEditor,
|
|
12
|
+
l as NiceCodeEditorAI,
|
|
13
|
+
p as NiceColorPalette,
|
|
14
|
+
a as NiceColorPicker,
|
|
15
|
+
P as NiceContactPicker,
|
|
16
|
+
I as NiceCountryPicker,
|
|
17
|
+
k as NiceCropEditor,
|
|
18
|
+
m as NiceCurrencyInput,
|
|
19
|
+
C as NiceDatePicker,
|
|
20
|
+
E as NiceDateRangeBox,
|
|
21
|
+
g as NiceDateTimePicker,
|
|
22
|
+
x as NiceDocumentEditor,
|
|
23
|
+
T as NiceDropDownBox,
|
|
24
|
+
A as NiceEmojiPicker,
|
|
25
|
+
S as NiceFileUpload,
|
|
26
|
+
b as NiceFloatingLabelInput,
|
|
27
|
+
D as NiceForm,
|
|
28
|
+
L as NiceGradientPicker,
|
|
29
|
+
R as NiceHtmlEditor,
|
|
30
|
+
f as NiceHtmlEditorAI,
|
|
31
|
+
B as NiceImageAnnotator,
|
|
32
|
+
F as NiceImageEditor,
|
|
33
|
+
M as NiceInPlaceEditor,
|
|
34
|
+
w as NiceInputOtp,
|
|
35
|
+
h as NiceInvoiceLineEditor,
|
|
36
|
+
y as NiceKnob,
|
|
37
|
+
G as NiceLookup,
|
|
38
|
+
H as NiceMarkdownEditor,
|
|
39
|
+
j as NiceMaskedInput,
|
|
40
|
+
v as NiceMention,
|
|
41
|
+
K as NiceMultiColumnComboBox,
|
|
42
|
+
ne as NiceNumberInput,
|
|
43
|
+
O as NicePDFAnnotationEditor,
|
|
44
|
+
U as NicePasswordInput,
|
|
45
|
+
V as NicePhoneInput,
|
|
46
|
+
W as NicePickList,
|
|
47
|
+
q as NicePinCodeInput,
|
|
48
|
+
z as NiceRadioGroup,
|
|
49
|
+
J as NiceRangeSlider,
|
|
50
|
+
Q as NiceRating,
|
|
51
|
+
X as NiceScannerControl,
|
|
52
|
+
c as NiceSelect,
|
|
53
|
+
Y as NiceSignature,
|
|
54
|
+
Z as NiceSignaturePad,
|
|
55
|
+
_ as NiceSlider,
|
|
56
|
+
$ as NiceTagBox,
|
|
57
|
+
ee as NiceTaxRatePicker,
|
|
58
|
+
ie as NiceTextArea,
|
|
59
|
+
s as NiceTextInput,
|
|
60
|
+
ae as NiceTimePicker,
|
|
61
|
+
de as NiceToggle,
|
|
62
|
+
ce as NiceTransferList,
|
|
63
|
+
se as NiceTreeSelect,
|
|
64
|
+
Ne as NiceVatInput,
|
|
65
|
+
oe as NiceWiki
|
|
66
|
+
};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const e=require("./NiceErrorBoundary-Dta4TGee.cjs");exports.NiceAlert=e.NiceAlert;exports.NiceConfirmDialog=e.NiceConfirmDialog;exports.NiceCookieConsent=e.NiceCookieConsent;exports.NiceDrawer=e.NiceDrawer;exports.NiceErrorBoundary=e.NiceErrorBoundary;exports.NiceLoginForm=e.NiceLoginForm;exports.NiceModal=e.NiceModal;exports.NiceOfflineBanner=e.NiceOfflineBanner;exports.NiceRetryPanel=e.NiceRetryPanel;exports.NiceTimeoutFeedback=e.NiceTimeoutFeedback;exports.NiceToastContainer=e.NiceToastContainer;exports.alertIcons=e.alertIcons;exports.useNiceToast=e.useNiceToast;
|
|
@@ -0,0 +1,339 @@
|
|
|
1
|
+
import { Component } from 'react';
|
|
2
|
+
import { default as default_2 } from 'react';
|
|
3
|
+
import { ForwardRefExoticComponent } from 'react';
|
|
4
|
+
import { JSX as JSX_2 } from 'react/jsx-runtime';
|
|
5
|
+
import { RefAttributes } from 'react';
|
|
6
|
+
|
|
7
|
+
export declare const alertIcons: Record<string, default_2.ReactNode>;
|
|
8
|
+
|
|
9
|
+
/**
|
|
10
|
+
* Per-component visibility & interaction level used by the access control system.
|
|
11
|
+
* - `'full'` — fully interactive (default)
|
|
12
|
+
* - `'readOnly'` — renders but cannot be edited
|
|
13
|
+
* - `'disabled'` — renders greyed-out
|
|
14
|
+
* - `'hidden'` — not rendered at all
|
|
15
|
+
*/
|
|
16
|
+
declare type NiceAccessMode = 'full' | 'readOnly' | 'disabled' | 'hidden';
|
|
17
|
+
|
|
18
|
+
export declare const NiceAlert: default_2.FC<NiceAlertProps>;
|
|
19
|
+
|
|
20
|
+
/** Props for the {@link NiceAlert} component — a status message bar (info/success/warning/error). */
|
|
21
|
+
export declare interface NiceAlertProps extends NiceBaseProps {
|
|
22
|
+
/** Alert size. */
|
|
23
|
+
size?: NiceSize;
|
|
24
|
+
/** Visual variant determining color and icon. */
|
|
25
|
+
variant?: 'info' | 'success' | 'warning' | 'error';
|
|
26
|
+
/** Bold title text. */
|
|
27
|
+
title?: string;
|
|
28
|
+
/** Alert body content. */
|
|
29
|
+
children: default_2.ReactNode;
|
|
30
|
+
/** Show a dismiss (✕) button. */
|
|
31
|
+
closable?: boolean;
|
|
32
|
+
/** Called when the dismiss button is clicked. */
|
|
33
|
+
onClose?: () => void;
|
|
34
|
+
/** Custom icon overriding the default variant icon. */
|
|
35
|
+
icon?: default_2.ReactNode;
|
|
36
|
+
}
|
|
37
|
+
|
|
38
|
+
/** Base props inherited by every NiceToDev component. */
|
|
39
|
+
declare interface NiceBaseProps {
|
|
40
|
+
/** Additional CSS class name(s). */
|
|
41
|
+
className?: string;
|
|
42
|
+
/** Inline style object. */
|
|
43
|
+
style?: React.CSSProperties;
|
|
44
|
+
/** HTML `id` attribute. When omitted a stable auto-generated id is used. */
|
|
45
|
+
id?: string;
|
|
46
|
+
/** Tooltip text shown on hover. */
|
|
47
|
+
title?: string;
|
|
48
|
+
/** Test identifier for integration / e2e test selectors. */
|
|
49
|
+
'data-testid'?: string;
|
|
50
|
+
/** Controls component visibility and interaction — see {@link NiceAccessMode}. */
|
|
51
|
+
accessMode?: NiceAccessMode;
|
|
52
|
+
/**
|
|
53
|
+
* Visual presentation style override.
|
|
54
|
+
* When set, overrides the global `displayStyle` from `NiceThemeProvider`.
|
|
55
|
+
* @see NiceDisplayStyle
|
|
56
|
+
*/
|
|
57
|
+
displayStyle?: NiceDisplayStyle;
|
|
58
|
+
}
|
|
59
|
+
|
|
60
|
+
export declare const NiceConfirmDialog: default_2.FC<NiceConfirmDialogProps>;
|
|
61
|
+
|
|
62
|
+
/** Props for the {@link NiceConfirmDialog} component — a confirmation modal with accept / reject buttons. */
|
|
63
|
+
export declare interface NiceConfirmDialogProps extends NiceBaseProps {
|
|
64
|
+
/** Size variant. */
|
|
65
|
+
size?: NiceSize;
|
|
66
|
+
/** Whether the dialog is visible. */
|
|
67
|
+
visible: boolean;
|
|
68
|
+
/** Confirmation message */
|
|
69
|
+
message: default_2.ReactNode;
|
|
70
|
+
/** Dialog header/title */
|
|
71
|
+
header?: string;
|
|
72
|
+
/** Icon displayed next to the message */
|
|
73
|
+
icon?: default_2.ReactNode;
|
|
74
|
+
/** Variant affects icon color and accept button style */
|
|
75
|
+
variant?: 'info' | 'warning' | 'error' | 'success';
|
|
76
|
+
/** Label for accept button */
|
|
77
|
+
acceptLabel?: string;
|
|
78
|
+
/** Label for reject button */
|
|
79
|
+
rejectLabel?: string;
|
|
80
|
+
/** Called when user accepts */
|
|
81
|
+
onAccept: () => void;
|
|
82
|
+
/** Called when user rejects or closes */
|
|
83
|
+
onReject: () => void;
|
|
84
|
+
/** Close on overlay click (default: false) */
|
|
85
|
+
closeOnOverlay?: boolean;
|
|
86
|
+
/** Close on Escape key (default: true) */
|
|
87
|
+
closeOnEscape?: boolean;
|
|
88
|
+
}
|
|
89
|
+
|
|
90
|
+
/** Cookie category types for the {@link NiceCookieConsent} banner. */
|
|
91
|
+
declare type NiceCookieCategory = 'necessary' | 'analytics' | 'marketing' | 'preferences';
|
|
92
|
+
|
|
93
|
+
export declare const NiceCookieConsent: ForwardRefExoticComponent<NiceCookieConsentProps & RefAttributes<HTMLDivElement>>;
|
|
94
|
+
|
|
95
|
+
/** Props for the {@link NiceCookieConsent} component — a GDPR-style cookie consent banner with category toggles. */
|
|
96
|
+
export declare interface NiceCookieConsentProps extends NiceBaseProps {
|
|
97
|
+
/** Show the banner when `true`. */
|
|
98
|
+
visible?: boolean;
|
|
99
|
+
/** Called when the user accepts all categories. */
|
|
100
|
+
onAcceptAll?: () => void;
|
|
101
|
+
/** Called when the user rejects all non-necessary categories. */
|
|
102
|
+
onRejectAll?: () => void;
|
|
103
|
+
/** Called when the user saves custom category selections. */
|
|
104
|
+
onSave?: (categories: Record<NiceCookieCategory, boolean>) => void;
|
|
105
|
+
/** Which cookie categories to show. */
|
|
106
|
+
categories?: NiceCookieCategory[];
|
|
107
|
+
/** Default toggle states for each category. */
|
|
108
|
+
defaults?: Partial<Record<NiceCookieCategory, boolean>>;
|
|
109
|
+
/** Banner position. */
|
|
110
|
+
position?: 'bottom' | 'top' | 'center';
|
|
111
|
+
/** Size preset. */
|
|
112
|
+
size?: NiceSize;
|
|
113
|
+
/** Link to privacy / cookie policy page. */
|
|
114
|
+
policyUrl?: string;
|
|
115
|
+
/** Show the category details section. */
|
|
116
|
+
showDetails?: boolean;
|
|
117
|
+
}
|
|
118
|
+
|
|
119
|
+
/**
|
|
120
|
+
* Cross-component visual presentation style.
|
|
121
|
+
* Each style maps 1:1 to a ThemeVariantConfig preset controlling
|
|
122
|
+
* buttons, inputs, cards, badges, tabs, toggles, tooltips, tables, etc.
|
|
123
|
+
*/
|
|
124
|
+
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';
|
|
125
|
+
|
|
126
|
+
export declare const NiceDrawer: default_2.FC<NiceDrawerProps>;
|
|
127
|
+
|
|
128
|
+
/** Props for the {@link NiceDrawer} component — a slide-in panel from any edge. */
|
|
129
|
+
export declare interface NiceDrawerProps extends NiceBaseProps {
|
|
130
|
+
/** Whether the drawer is open. */
|
|
131
|
+
open: boolean;
|
|
132
|
+
/** Called when the user requests to close. */
|
|
133
|
+
onClose: () => void;
|
|
134
|
+
/** Drawer header title. */
|
|
135
|
+
title?: string;
|
|
136
|
+
/** Edge from which the drawer slides in. */
|
|
137
|
+
position?: 'left' | 'right' | 'top' | 'bottom';
|
|
138
|
+
/** Width/height preset. */
|
|
139
|
+
size?: NiceSize;
|
|
140
|
+
/** Drawer body content. */
|
|
141
|
+
children: default_2.ReactNode;
|
|
142
|
+
/** Content rendered in the drawer footer. */
|
|
143
|
+
footer?: default_2.ReactNode;
|
|
144
|
+
/** Custom transition duration in ms */
|
|
145
|
+
transitionDuration?: number;
|
|
146
|
+
}
|
|
147
|
+
|
|
148
|
+
/**
|
|
149
|
+
* {@link NiceErrorBoundary} — React error boundary with customizable fallback,
|
|
150
|
+
* retry mechanism, and error reporting callback.
|
|
151
|
+
*/
|
|
152
|
+
export declare class NiceErrorBoundary extends Component<NiceErrorBoundaryProps, NiceErrorBoundaryState> {
|
|
153
|
+
static displayName: string;
|
|
154
|
+
state: NiceErrorBoundaryState;
|
|
155
|
+
static getDerivedStateFromError(error: Error): NiceErrorBoundaryState;
|
|
156
|
+
componentDidCatch(error: Error, errorInfo: default_2.ErrorInfo): void;
|
|
157
|
+
handleReset: () => void;
|
|
158
|
+
render(): string | number | boolean | Iterable<default_2.ReactNode> | JSX_2.Element | null | undefined;
|
|
159
|
+
}
|
|
160
|
+
|
|
161
|
+
/** Props for the {@link NiceErrorBoundary} component. */
|
|
162
|
+
export declare interface NiceErrorBoundaryProps {
|
|
163
|
+
/** Custom fallback UI. If not provided, a default error panel is shown. */
|
|
164
|
+
fallback?: default_2.ReactNode | ((error: Error, reset: () => void) => default_2.ReactNode);
|
|
165
|
+
/** Fires when an error is caught. */
|
|
166
|
+
onError?: (error: Error, errorInfo: default_2.ErrorInfo) => void;
|
|
167
|
+
/** Whether to show a retry button in the default fallback. */
|
|
168
|
+
showRetry?: boolean;
|
|
169
|
+
/** Label for the retry button. */
|
|
170
|
+
retryLabel?: string;
|
|
171
|
+
/** Title for the default fallback. */
|
|
172
|
+
title?: string;
|
|
173
|
+
/** Child components to wrap. */
|
|
174
|
+
children: default_2.ReactNode;
|
|
175
|
+
}
|
|
176
|
+
|
|
177
|
+
declare interface NiceErrorBoundaryState {
|
|
178
|
+
hasError: boolean;
|
|
179
|
+
error: Error | null;
|
|
180
|
+
}
|
|
181
|
+
|
|
182
|
+
export declare const NiceLoginForm: ForwardRefExoticComponent<NiceLoginFormProps & RefAttributes<HTMLFormElement>>;
|
|
183
|
+
|
|
184
|
+
/** Props for the {@link NiceLoginForm} component — a pre-built login form with username, password, remember-me, and social links. */
|
|
185
|
+
export declare interface NiceLoginFormProps extends NiceBaseProps {
|
|
186
|
+
/** Called with credentials on form submit. */
|
|
187
|
+
onSubmit?: (credentials: {
|
|
188
|
+
username: string;
|
|
189
|
+
password: string;
|
|
190
|
+
rememberMe: boolean;
|
|
191
|
+
}) => void;
|
|
192
|
+
/** Forgot-password link handler. */
|
|
193
|
+
onForgotPassword?: () => void;
|
|
194
|
+
/** Register link handler. */
|
|
195
|
+
onRegister?: () => void;
|
|
196
|
+
/** Show a loading spinner on the submit button. */
|
|
197
|
+
loading?: boolean;
|
|
198
|
+
/** Error message displayed above the form. */
|
|
199
|
+
error?: string;
|
|
200
|
+
/** Visual variant. */
|
|
201
|
+
variant?: NiceVariant;
|
|
202
|
+
/** Size preset. */
|
|
203
|
+
size?: NiceSize;
|
|
204
|
+
/** Show “Remember me” checkbox. */
|
|
205
|
+
showRememberMe?: boolean;
|
|
206
|
+
/** Show “Forgot password?” link. */
|
|
207
|
+
showForgotPassword?: boolean;
|
|
208
|
+
/** Show a “Register” link. */
|
|
209
|
+
showRegister?: boolean;
|
|
210
|
+
/** Form title. */
|
|
211
|
+
title?: string;
|
|
212
|
+
/** Logo element above the title. */
|
|
213
|
+
logo?: React.ReactNode;
|
|
214
|
+
/** Username field label. */
|
|
215
|
+
usernameLabel?: string;
|
|
216
|
+
/** Password field label. */
|
|
217
|
+
passwordLabel?: string;
|
|
218
|
+
/** Username input placeholder. */
|
|
219
|
+
usernamePlaceholder?: string;
|
|
220
|
+
/** Password input placeholder. */
|
|
221
|
+
passwordPlaceholder?: string;
|
|
222
|
+
}
|
|
223
|
+
|
|
224
|
+
export declare const NiceModal: default_2.FC<NiceModalProps>;
|
|
225
|
+
|
|
226
|
+
/** Props for the {@link NiceModal} component — a dialog overlay with focus trapping. */
|
|
227
|
+
export declare interface NiceModalProps extends NiceBaseProps {
|
|
228
|
+
/** Whether the modal is currently visible. */
|
|
229
|
+
open: boolean;
|
|
230
|
+
/** Called when the user requests to close the modal. */
|
|
231
|
+
onClose: () => void;
|
|
232
|
+
/** Title rendered in the modal header. */
|
|
233
|
+
title?: string;
|
|
234
|
+
/** Width preset. */
|
|
235
|
+
size?: NiceSize;
|
|
236
|
+
/** Modal body content. */
|
|
237
|
+
children: default_2.ReactNode;
|
|
238
|
+
/** Content rendered in the modal footer (actions, buttons). */
|
|
239
|
+
footer?: default_2.ReactNode;
|
|
240
|
+
/** Close on overlay/backdrop click (default `true`). */
|
|
241
|
+
closeOnOverlay?: boolean;
|
|
242
|
+
/** Close on Escape key (default `true`). */
|
|
243
|
+
closeOnEscape?: boolean;
|
|
244
|
+
/** Allow toggling fullscreen mode */
|
|
245
|
+
fullscreenable?: boolean;
|
|
246
|
+
/** Stacking order for multiple modals */
|
|
247
|
+
zIndex?: number;
|
|
248
|
+
}
|
|
249
|
+
|
|
250
|
+
export declare const NiceOfflineBanner: default_2.FC<NiceOfflineBannerProps>;
|
|
251
|
+
|
|
252
|
+
export declare interface NiceOfflineBannerProps extends NiceBaseProps {
|
|
253
|
+
size?: NiceSize;
|
|
254
|
+
message?: string;
|
|
255
|
+
variant?: 'warning' | 'error';
|
|
256
|
+
icon?: default_2.ReactNode;
|
|
257
|
+
}
|
|
258
|
+
|
|
259
|
+
export declare const NiceRetryPanel: default_2.FC<NiceRetryPanelProps>;
|
|
260
|
+
|
|
261
|
+
export declare interface NiceRetryPanelProps extends NiceBaseProps {
|
|
262
|
+
size?: NiceSize;
|
|
263
|
+
error: string | Error;
|
|
264
|
+
onRetry: () => void;
|
|
265
|
+
retryLabel?: string;
|
|
266
|
+
title?: string;
|
|
267
|
+
/** Auto-retry interval in seconds. Disabled when 0 or undefined. */
|
|
268
|
+
autoRetrySeconds?: number;
|
|
269
|
+
variant?: 'info' | 'warning' | 'error';
|
|
270
|
+
icon?: default_2.ReactNode;
|
|
271
|
+
}
|
|
272
|
+
|
|
273
|
+
/** T-shirt sizing used across all components for consistent visual density. */
|
|
274
|
+
declare type NiceSize = 'xxs' | 'xs' | 'sm' | 'md' | 'lg' | 'xl' | 'xxl';
|
|
275
|
+
|
|
276
|
+
export declare const NiceTimeoutFeedback: default_2.FC<NiceTimeoutFeedbackProps>;
|
|
277
|
+
|
|
278
|
+
export declare interface NiceTimeoutFeedbackProps extends NiceBaseProps {
|
|
279
|
+
size?: NiceSize;
|
|
280
|
+
timeoutMs?: number;
|
|
281
|
+
slowThresholdMs?: number;
|
|
282
|
+
onTimeout?: () => void;
|
|
283
|
+
onRetry?: () => void;
|
|
284
|
+
autoRetry?: boolean;
|
|
285
|
+
autoRetryCount?: number;
|
|
286
|
+
showProgress?: boolean;
|
|
287
|
+
slowMessage?: string;
|
|
288
|
+
timeoutMessage?: string;
|
|
289
|
+
children: default_2.ReactNode;
|
|
290
|
+
loading: boolean;
|
|
291
|
+
}
|
|
292
|
+
|
|
293
|
+
export declare const NiceToastContainer: default_2.FC<ToastContainerProps>;
|
|
294
|
+
|
|
295
|
+
/** Data object describing a single toast notification. */
|
|
296
|
+
export declare interface NiceToastItem {
|
|
297
|
+
/** Unique identifier for the toast. */
|
|
298
|
+
id: string;
|
|
299
|
+
/** Visual variant. */
|
|
300
|
+
variant: 'info' | 'success' | 'warning' | 'error';
|
|
301
|
+
/** Optional bold title. */
|
|
302
|
+
title?: string;
|
|
303
|
+
/** Toast body text. */
|
|
304
|
+
message: string;
|
|
305
|
+
/** Auto-dismiss delay in ms. Omit to keep until manually dismissed. */
|
|
306
|
+
duration?: number;
|
|
307
|
+
}
|
|
308
|
+
|
|
309
|
+
/** Visual style variant for buttons, alerts, badges and other themed controls. */
|
|
310
|
+
declare type NiceVariant = 'primary' | 'secondary' | 'success' | 'warning' | 'error' | 'info' | 'ghost' | 'outline';
|
|
311
|
+
|
|
312
|
+
declare interface ToastContainerProps {
|
|
313
|
+
toasts: NiceToastItem[];
|
|
314
|
+
onDismiss: (id: string) => void;
|
|
315
|
+
position?: 'top-right' | 'top-left' | 'bottom-right' | 'bottom-left' | 'top-center';
|
|
316
|
+
}
|
|
317
|
+
|
|
318
|
+
export declare function useNiceToast(): {
|
|
319
|
+
toasts: NiceToastItem[];
|
|
320
|
+
dismiss: (id: string) => void;
|
|
321
|
+
info: (msg: string, opts?: {
|
|
322
|
+
title?: string;
|
|
323
|
+
duration?: number;
|
|
324
|
+
}) => string;
|
|
325
|
+
success: (msg: string, opts?: {
|
|
326
|
+
title?: string;
|
|
327
|
+
duration?: number;
|
|
328
|
+
}) => string;
|
|
329
|
+
warning: (msg: string, opts?: {
|
|
330
|
+
title?: string;
|
|
331
|
+
duration?: number;
|
|
332
|
+
}) => string;
|
|
333
|
+
error: (msg: string, opts?: {
|
|
334
|
+
title?: string;
|
|
335
|
+
duration?: number;
|
|
336
|
+
}) => string;
|
|
337
|
+
};
|
|
338
|
+
|
|
339
|
+
export { }
|
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
import { N as i, a as s, b as o, c, d as r, e as N, f as n, g as t, h as l, i as f, j as d, k as m, u } from "./NiceErrorBoundary-D1hh5GGe.js";
|
|
2
|
+
export {
|
|
3
|
+
i as NiceAlert,
|
|
4
|
+
s as NiceConfirmDialog,
|
|
5
|
+
o as NiceCookieConsent,
|
|
6
|
+
c as NiceDrawer,
|
|
7
|
+
r as NiceErrorBoundary,
|
|
8
|
+
N as NiceLoginForm,
|
|
9
|
+
n as NiceModal,
|
|
10
|
+
t as NiceOfflineBanner,
|
|
11
|
+
l as NiceRetryPanel,
|
|
12
|
+
f as NiceTimeoutFeedback,
|
|
13
|
+
d as NiceToastContainer,
|
|
14
|
+
m as alertIcons,
|
|
15
|
+
u as useNiceToast
|
|
16
|
+
};
|