@skiddph/prui 0.11.0 → 0.13.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/core/index.d.ts +1 -0
- package/dist/core/input.d.ts +5 -1
- package/dist/core/input.js +61 -37
- package/dist/core/tag-input.d.ts +47 -0
- package/dist/core/tag-input.js +140 -0
- package/dist/core.js +140 -137
- package/dist/i18n/index.d.ts +3 -0
- package/dist/i18n.js +27 -24
- package/dist/index.js +240 -237
- package/dist/prui-utilities.css +1 -1
- package/dist/prui.css +1 -1
- package/package.json +1 -1
package/dist/core.js
CHANGED
|
@@ -1,159 +1,162 @@
|
|
|
1
1
|
import { cn as r } from "./core/cn.js";
|
|
2
2
|
import { resolveSurface as a, withSurface as p } from "./core/surface.js";
|
|
3
|
-
import { Portal as i, getFocusable as
|
|
3
|
+
import { Portal as i, getFocusable as m, isTopOverlay as l, overlayCount as P, overlayPropsMeta as c, pushOverlay as n, removeOverlay as d, useEscapeKey as x, useFocusTrap as M, useInertBackground as f, useOverlay as u, useOverlayStack as g, useReducedMotion as b, useScrollLock as T } from "./core/overlay.js";
|
|
4
4
|
import { endIndex as D, homeIndex as S, moveIndex as v, typeaheadIndex as C } from "./core/list-nav.js";
|
|
5
|
-
import { Button as h, buttonPropsMeta as
|
|
5
|
+
import { Button as h, buttonPropsMeta as I } from "./core/button.js";
|
|
6
6
|
import { Input as A, Textarea as B, inputPropsMeta as R, textareaPropsMeta as F } from "./core/input.js";
|
|
7
|
-
import {
|
|
8
|
-
import {
|
|
9
|
-
import {
|
|
10
|
-
import {
|
|
11
|
-
import {
|
|
12
|
-
import {
|
|
13
|
-
import {
|
|
14
|
-
import {
|
|
15
|
-
import {
|
|
16
|
-
import {
|
|
17
|
-
import {
|
|
18
|
-
import {
|
|
19
|
-
import {
|
|
20
|
-
import {
|
|
21
|
-
import {
|
|
22
|
-
import {
|
|
23
|
-
import {
|
|
24
|
-
import {
|
|
25
|
-
import {
|
|
26
|
-
import {
|
|
27
|
-
import {
|
|
28
|
-
import {
|
|
29
|
-
import {
|
|
30
|
-
import {
|
|
31
|
-
import {
|
|
32
|
-
import {
|
|
33
|
-
import {
|
|
34
|
-
import {
|
|
35
|
-
import {
|
|
7
|
+
import { TagInput as K, tagInputPropsMeta as L } from "./core/tag-input.js";
|
|
8
|
+
import { Label as E, Separator as G, labelPropsMeta as H, separatorPropsMeta as U } from "./core/label.js";
|
|
9
|
+
import { Select as q, SelectContent as z, SelectItem as J, SelectTrigger as N, SelectValue as Q, selectPropsMeta as W } from "./core/select.js";
|
|
10
|
+
import { Switch as Y, switchPropsMeta as Z } from "./core/switch.js";
|
|
11
|
+
import { Tabs as $, TabsContent as ee, TabsList as oe, TabsTrigger as re, tabsPropsMeta as te } from "./core/tabs.js";
|
|
12
|
+
import { Avatar as pe, Badge as se, Card as ie, CardContent as me, CardDescription as le, CardFooter as Pe, CardHeader as ce, CardTitle as ne, avatarPropsMeta as de, badgePropsMeta as xe, cardPropsMeta as Me } from "./core/card.js";
|
|
13
|
+
import { Dialog as ue, DialogBody as ge, DialogContent as be, DialogDescription as Te, DialogFooter as ke, DialogHeader as De, DialogTitle as Se, dialogBodyPropsMeta as ve, dialogPropsMeta as Ce } from "./core/dialog.js";
|
|
14
|
+
import { Dropdown as he, dropdownPropsMeta as Ie } from "./core/dropdown.js";
|
|
15
|
+
import { ScrollArea as Ae, scrollAreaPropsMeta as Be } from "./core/scroll-area.js";
|
|
16
|
+
import { Modal as Fe, confirmModal as Oe, confirmModalPropsMeta as Ke, modalPropsMeta as Le } from "./core/modal.js";
|
|
17
|
+
import { computePosition as Ee, useAnchoredPosition as Ge } from "./core/anchor.js";
|
|
18
|
+
import { Spinner as Ue, spinnerPropsMeta as je } from "./core/spinner.js";
|
|
19
|
+
import { Skeleton as ze, skeletonPropsMeta as Je } from "./core/skeleton.js";
|
|
20
|
+
import { Alert as Qe, alertPropsMeta as We } from "./core/alert.js";
|
|
21
|
+
import { Progress as Ye, progressPropsMeta as Ze } from "./core/progress.js";
|
|
22
|
+
import { Toaster as $e, dismissAllToasts as eo, toast as oo, toastPropsMeta as ro, toasterPropsMeta as to } from "./core/toast.js";
|
|
23
|
+
import { Tooltip as po, tooltipPropsMeta as so } from "./core/tooltip.js";
|
|
24
|
+
import { Popover as mo, popoverPropsMeta as lo } from "./core/popover.js";
|
|
25
|
+
import { Drawer as co, Sheet as no, drawerPropsMeta as xo, sheetPropsMeta as Mo } from "./core/drawer.js";
|
|
26
|
+
import { Checkbox as uo, checkboxPropsMeta as go } from "./core/checkbox.js";
|
|
27
|
+
import { Radio as To, RadioGroup as ko, radioGroupPropsMeta as Do } from "./core/radio.js";
|
|
28
|
+
import { Combobox as vo, comboboxPropsMeta as Co } from "./core/combobox.js";
|
|
29
|
+
import { Accordion as ho, AccordionItem as Io, accordionPropsMeta as wo } from "./core/accordion.js";
|
|
30
|
+
import { Breadcrumb as Bo, BreadcrumbEllipsis as Ro, BreadcrumbItem as Fo, breadcrumbPropsMeta as Oo } from "./core/breadcrumb.js";
|
|
31
|
+
import { TreeView as Lo, treeViewPropsMeta as Vo } from "./core/tree-view.js";
|
|
32
|
+
import { Timeline as Go, timelinePropsMeta as Ho } from "./core/timeline.js";
|
|
33
|
+
import { Calendar as jo, calendarPropsMeta as qo, fromDateKey as zo, toDateKey as Jo } from "./core/calendar.js";
|
|
34
|
+
import { DatePicker as Qo, DateRangePicker as Wo, datePickerPropsMeta as Xo, dateRangePickerPropsMeta as Yo } from "./core/date-picker.js";
|
|
35
|
+
import { TimePanel as _o, TimePicker as $o, TimeRangePicker as er, timePickerPropsMeta as or, timeRangePickerPropsMeta as rr } from "./core/time-picker.js";
|
|
36
|
+
import { FileUpload as ar, fileUploadPropsMeta as pr } from "./core/file-upload.js";
|
|
36
37
|
export {
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
38
|
+
ho as Accordion,
|
|
39
|
+
Io as AccordionItem,
|
|
40
|
+
Qe as Alert,
|
|
41
|
+
pe as Avatar,
|
|
42
|
+
se as Badge,
|
|
43
|
+
Bo as Breadcrumb,
|
|
44
|
+
Ro as BreadcrumbEllipsis,
|
|
45
|
+
Fo as BreadcrumbItem,
|
|
45
46
|
h as Button,
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
|
|
47
|
+
jo as Calendar,
|
|
48
|
+
ie as Card,
|
|
49
|
+
me as CardContent,
|
|
50
|
+
le as CardDescription,
|
|
51
|
+
Pe as CardFooter,
|
|
52
|
+
ce as CardHeader,
|
|
53
|
+
ne as CardTitle,
|
|
54
|
+
uo as Checkbox,
|
|
55
|
+
vo as Combobox,
|
|
56
|
+
Qo as DatePicker,
|
|
57
|
+
Wo as DateRangePicker,
|
|
58
|
+
ue as Dialog,
|
|
59
|
+
ge as DialogBody,
|
|
60
|
+
be as DialogContent,
|
|
61
|
+
Te as DialogDescription,
|
|
62
|
+
ke as DialogFooter,
|
|
63
|
+
De as DialogHeader,
|
|
64
|
+
Se as DialogTitle,
|
|
65
|
+
co as Drawer,
|
|
66
|
+
he as Dropdown,
|
|
67
|
+
ar as FileUpload,
|
|
67
68
|
A as Input,
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
|
|
69
|
+
E as Label,
|
|
70
|
+
Fe as Modal,
|
|
71
|
+
mo as Popover,
|
|
71
72
|
i as Portal,
|
|
72
|
-
|
|
73
|
-
|
|
74
|
-
|
|
75
|
-
|
|
76
|
-
|
|
77
|
-
|
|
78
|
-
|
|
79
|
-
|
|
80
|
-
|
|
81
|
-
|
|
82
|
-
|
|
83
|
-
|
|
84
|
-
|
|
85
|
-
|
|
86
|
-
|
|
87
|
-
|
|
88
|
-
|
|
89
|
-
|
|
73
|
+
Ye as Progress,
|
|
74
|
+
To as Radio,
|
|
75
|
+
ko as RadioGroup,
|
|
76
|
+
Ae as ScrollArea,
|
|
77
|
+
q as Select,
|
|
78
|
+
z as SelectContent,
|
|
79
|
+
J as SelectItem,
|
|
80
|
+
N as SelectTrigger,
|
|
81
|
+
Q as SelectValue,
|
|
82
|
+
G as Separator,
|
|
83
|
+
no as Sheet,
|
|
84
|
+
ze as Skeleton,
|
|
85
|
+
Ue as Spinner,
|
|
86
|
+
Y as Switch,
|
|
87
|
+
$ as Tabs,
|
|
88
|
+
ee as TabsContent,
|
|
89
|
+
oe as TabsList,
|
|
90
|
+
re as TabsTrigger,
|
|
91
|
+
K as TagInput,
|
|
90
92
|
B as Textarea,
|
|
91
|
-
|
|
92
|
-
|
|
93
|
-
|
|
94
|
-
|
|
95
|
-
|
|
96
|
-
|
|
97
|
-
|
|
98
|
-
|
|
99
|
-
|
|
100
|
-
|
|
101
|
-
|
|
102
|
-
|
|
103
|
-
|
|
104
|
-
|
|
105
|
-
|
|
106
|
-
|
|
93
|
+
_o as TimePanel,
|
|
94
|
+
$o as TimePicker,
|
|
95
|
+
er as TimeRangePicker,
|
|
96
|
+
Go as Timeline,
|
|
97
|
+
$e as Toaster,
|
|
98
|
+
po as Tooltip,
|
|
99
|
+
Lo as TreeView,
|
|
100
|
+
wo as accordionPropsMeta,
|
|
101
|
+
We as alertPropsMeta,
|
|
102
|
+
de as avatarPropsMeta,
|
|
103
|
+
xe as badgePropsMeta,
|
|
104
|
+
Oo as breadcrumbPropsMeta,
|
|
105
|
+
I as buttonPropsMeta,
|
|
106
|
+
qo as calendarPropsMeta,
|
|
107
|
+
Me as cardPropsMeta,
|
|
108
|
+
go as checkboxPropsMeta,
|
|
107
109
|
r as cn,
|
|
108
|
-
|
|
109
|
-
|
|
110
|
-
|
|
111
|
-
|
|
112
|
-
|
|
113
|
-
|
|
114
|
-
|
|
115
|
-
|
|
116
|
-
|
|
117
|
-
|
|
118
|
-
|
|
110
|
+
Co as comboboxPropsMeta,
|
|
111
|
+
Ee as computePosition,
|
|
112
|
+
Oe as confirmModal,
|
|
113
|
+
Ke as confirmModalPropsMeta,
|
|
114
|
+
Xo as datePickerPropsMeta,
|
|
115
|
+
Yo as dateRangePickerPropsMeta,
|
|
116
|
+
ve as dialogBodyPropsMeta,
|
|
117
|
+
Ce as dialogPropsMeta,
|
|
118
|
+
eo as dismissAllToasts,
|
|
119
|
+
xo as drawerPropsMeta,
|
|
120
|
+
Ie as dropdownPropsMeta,
|
|
119
121
|
D as endIndex,
|
|
120
|
-
|
|
121
|
-
|
|
122
|
-
|
|
122
|
+
pr as fileUploadPropsMeta,
|
|
123
|
+
zo as fromDateKey,
|
|
124
|
+
m as getFocusable,
|
|
123
125
|
S as homeIndex,
|
|
124
126
|
R as inputPropsMeta,
|
|
125
|
-
|
|
126
|
-
|
|
127
|
-
|
|
127
|
+
l as isTopOverlay,
|
|
128
|
+
H as labelPropsMeta,
|
|
129
|
+
Le as modalPropsMeta,
|
|
128
130
|
v as moveIndex,
|
|
129
131
|
P as overlayCount,
|
|
130
132
|
c as overlayPropsMeta,
|
|
131
|
-
|
|
132
|
-
|
|
133
|
-
|
|
134
|
-
|
|
135
|
-
|
|
133
|
+
lo as popoverPropsMeta,
|
|
134
|
+
Ze as progressPropsMeta,
|
|
135
|
+
n as pushOverlay,
|
|
136
|
+
Do as radioGroupPropsMeta,
|
|
137
|
+
d as removeOverlay,
|
|
136
138
|
a as resolveSurface,
|
|
137
|
-
|
|
138
|
-
|
|
139
|
-
|
|
140
|
-
|
|
141
|
-
|
|
142
|
-
|
|
143
|
-
|
|
144
|
-
|
|
139
|
+
Be as scrollAreaPropsMeta,
|
|
140
|
+
W as selectPropsMeta,
|
|
141
|
+
U as separatorPropsMeta,
|
|
142
|
+
Mo as sheetPropsMeta,
|
|
143
|
+
Je as skeletonPropsMeta,
|
|
144
|
+
je as spinnerPropsMeta,
|
|
145
|
+
Z as switchPropsMeta,
|
|
146
|
+
te as tabsPropsMeta,
|
|
147
|
+
L as tagInputPropsMeta,
|
|
145
148
|
F as textareaPropsMeta,
|
|
146
|
-
|
|
147
|
-
|
|
148
|
-
|
|
149
|
-
|
|
150
|
-
|
|
151
|
-
|
|
152
|
-
|
|
153
|
-
|
|
154
|
-
|
|
149
|
+
or as timePickerPropsMeta,
|
|
150
|
+
rr as timeRangePickerPropsMeta,
|
|
151
|
+
Ho as timelinePropsMeta,
|
|
152
|
+
Jo as toDateKey,
|
|
153
|
+
oo as toast,
|
|
154
|
+
ro as toastPropsMeta,
|
|
155
|
+
to as toasterPropsMeta,
|
|
156
|
+
so as tooltipPropsMeta,
|
|
157
|
+
Vo as treeViewPropsMeta,
|
|
155
158
|
C as typeaheadIndex,
|
|
156
|
-
|
|
159
|
+
Ge as useAnchoredPosition,
|
|
157
160
|
x as useEscapeKey,
|
|
158
161
|
M as useFocusTrap,
|
|
159
162
|
f as useInertBackground,
|
package/dist/i18n/index.d.ts
CHANGED
|
@@ -45,6 +45,9 @@ export interface PruiDictionary {
|
|
|
45
45
|
deleteConfirmMessage: string;
|
|
46
46
|
dismiss: string;
|
|
47
47
|
notifications: string;
|
|
48
|
+
showPassword: string;
|
|
49
|
+
hidePassword: string;
|
|
50
|
+
removeTag: string;
|
|
48
51
|
mainNavigation: string;
|
|
49
52
|
openNavigation: string;
|
|
50
53
|
closeNavigation: string;
|
package/dist/i18n.js
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { jsx as m } from "react/jsx-runtime";
|
|
2
|
-
import * as
|
|
3
|
-
const
|
|
2
|
+
import * as a from "react";
|
|
3
|
+
const i = {
|
|
4
4
|
close: "Close",
|
|
5
5
|
closeDialog: "Close dialog",
|
|
6
6
|
cancel: "Cancel",
|
|
@@ -37,6 +37,9 @@ const s = {
|
|
|
37
37
|
deleteConfirmMessage: "This action cannot be undone.",
|
|
38
38
|
dismiss: "Dismiss",
|
|
39
39
|
notifications: "Notifications",
|
|
40
|
+
showPassword: "Show password",
|
|
41
|
+
hidePassword: "Hide password",
|
|
42
|
+
removeTag: "Remove {label}",
|
|
40
43
|
mainNavigation: "Main",
|
|
41
44
|
openNavigation: "Open navigation",
|
|
42
45
|
closeNavigation: "Close navigation",
|
|
@@ -57,49 +60,49 @@ const s = {
|
|
|
57
60
|
removeFile: "Remove file",
|
|
58
61
|
of: "of"
|
|
59
62
|
};
|
|
60
|
-
let o =
|
|
61
|
-
const
|
|
62
|
-
function
|
|
63
|
-
for (const e of
|
|
63
|
+
let o = i;
|
|
64
|
+
const s = /* @__PURE__ */ new Set();
|
|
65
|
+
function n() {
|
|
66
|
+
for (const e of s) e();
|
|
64
67
|
}
|
|
65
68
|
function u(e) {
|
|
66
|
-
o = { ...o, ...e },
|
|
69
|
+
o = { ...o, ...e }, n();
|
|
67
70
|
}
|
|
68
71
|
function f() {
|
|
69
|
-
o =
|
|
72
|
+
o = i, n();
|
|
70
73
|
}
|
|
71
74
|
function p() {
|
|
72
75
|
return o;
|
|
73
76
|
}
|
|
74
|
-
const l =
|
|
75
|
-
function
|
|
77
|
+
const l = a.createContext(null);
|
|
78
|
+
function w({
|
|
76
79
|
dictionary: e,
|
|
77
|
-
children:
|
|
80
|
+
children: r
|
|
78
81
|
}) {
|
|
79
|
-
|
|
82
|
+
a.useEffect(() => {
|
|
80
83
|
if (!e) return;
|
|
81
84
|
const c = o;
|
|
82
85
|
return u(e), () => {
|
|
83
|
-
o = c,
|
|
86
|
+
o = c, n();
|
|
84
87
|
};
|
|
85
88
|
}, [e]);
|
|
86
|
-
const t =
|
|
87
|
-
return /* @__PURE__ */ m(l.Provider, { value: t, children:
|
|
89
|
+
const t = a.useMemo(() => ({ ...o, ...e }), [e]);
|
|
90
|
+
return /* @__PURE__ */ m(l.Provider, { value: t, children: r });
|
|
88
91
|
}
|
|
89
|
-
function
|
|
90
|
-
const e =
|
|
91
|
-
return
|
|
92
|
-
const t =
|
|
93
|
-
return
|
|
94
|
-
|
|
92
|
+
function g() {
|
|
93
|
+
const e = a.useContext(l), [, r] = a.useReducer((t) => t + 1, 0);
|
|
94
|
+
return a.useEffect(() => {
|
|
95
|
+
const t = r;
|
|
96
|
+
return s.add(t), () => {
|
|
97
|
+
s.delete(t);
|
|
95
98
|
};
|
|
96
99
|
}, []), { t: e ?? o };
|
|
97
100
|
}
|
|
98
101
|
export {
|
|
99
|
-
|
|
100
|
-
|
|
102
|
+
w as PruiProvider,
|
|
103
|
+
i as defaultDictionary,
|
|
101
104
|
p as getPruiDictionary,
|
|
102
105
|
f as resetPruiDictionary,
|
|
103
106
|
u as setPruiDictionary,
|
|
104
|
-
|
|
107
|
+
g as usePruiI18n
|
|
105
108
|
};
|