@devalok/shilp-sutra 0.34.0 → 0.34.1
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/_chunks/badge-group.js +306 -246
- package/dist/_chunks/chat.js +513 -0
- package/dist/_chunks/date-picker.js +748 -0
- package/dist/_chunks/document-preview.js +109 -90
- package/dist/_chunks/file-preview.js +492 -504
- package/dist/_chunks/framer.js +5564 -5613
- package/dist/_chunks/image-preview.js +127 -88
- package/dist/_chunks/keybinding.js +12 -14
- package/dist/_chunks/link-context.js +19 -16
- package/dist/_chunks/mention-suggestion.js +353 -350
- package/dist/_chunks/motion-provider.js +26 -20
- package/dist/_chunks/popover.js +127 -0
- package/dist/_chunks/primitives.js +7584 -6425
- package/dist/_chunks/rich-chat-input.js +2070 -0
- package/dist/_chunks/rolldown-runtime.js +21 -0
- package/dist/_chunks/shared.js +126 -0
- package/dist/_chunks/sonner.js +605 -734
- package/dist/_chunks/stat-row.js +418 -440
- package/dist/_chunks/tiptap.js +15850 -19964
- package/dist/_chunks/tree-view.js +231 -290
- package/dist/_chunks/use-calendar.js +161 -208
- package/dist/_chunks/vendor-client.js +314 -2199
- package/dist/_chunks/vendor-utils.js +1721 -2978
- package/dist/ai/ai-command-provider.js +23 -17
- package/dist/ai/block-renderer.js +68 -51
- package/dist/ai/blocks/index.js +2 -12
- package/dist/ai/command-bar.js +470 -519
- package/dist/ai/conversation.js +241 -227
- package/dist/ai/index.js +181 -167
- package/dist/ai/types.js +0 -1
- package/dist/composed/activity-feed.js +232 -202
- package/dist/composed/avatar-group.js +164 -222
- package/dist/composed/bulk-action-bar.js +174 -165
- package/dist/composed/command-palette.js +290 -308
- package/dist/composed/confirm-dialog.js +28 -48
- package/dist/composed/content-card.js +69 -108
- package/dist/composed/date-picker/index.js +3 -13
- package/dist/composed/deadline-indicator.js +68 -74
- package/dist/composed/emoji-picker.js +83 -110
- package/dist/composed/empty-state.js +64 -103
- package/dist/composed/error-boundary.js +129 -127
- package/dist/composed/file-preview.js +2 -12
- package/dist/composed/filter-bar.js +98 -130
- package/dist/composed/form-section.js +61 -45
- package/dist/composed/global-loading.js +34 -47
- package/dist/composed/index.js +34 -92
- package/dist/composed/inline-edit.js +92 -107
- package/dist/composed/lib/string-utils.js +8 -8
- package/dist/composed/loading-skeleton.js +103 -171
- package/dist/composed/markdown-viewer.js +187 -139
- package/dist/composed/master-detail.js +147 -156
- package/dist/composed/member-picker.js +46 -49
- package/dist/composed/multi-select-popover.js +181 -179
- package/dist/composed/page-header.js +54 -76
- package/dist/composed/page-skeletons.js +143 -127
- package/dist/composed/priority-indicator.js +105 -111
- package/dist/composed/responsive-overlay.js +36 -41
- package/dist/composed/rich-chat-input.js +2 -1860
- package/dist/composed/rich-text-editor.js +561 -424
- package/dist/composed/schedule-view.js +134 -185
- package/dist/composed/simple-tooltip.js +21 -21
- package/dist/composed/status-badge.js +133 -137
- package/dist/hooks/index.js +7 -12
- package/dist/hooks/use-color-mode.js +28 -25
- package/dist/hooks/use-mobile.js +13 -13
- package/dist/hooks/use-toast.js +2 -4
- package/dist/hooks/use-touch-device.js +9 -11
- package/dist/hooks/use-viewport-height.js +14 -14
- package/dist/motion/index.js +3 -11
- package/dist/motion/primitives-index.js +226 -186
- package/dist/shell/app-command-palette.js +203 -234
- package/dist/shell/bottom-navbar.js +150 -190
- package/dist/shell/command-registry.js +13 -14
- package/dist/shell/index.js +10 -20
- package/dist/shell/link-context.js +2 -5
- package/dist/shell/notification-center.js +238 -259
- package/dist/shell/notification-preferences.js +241 -184
- package/dist/shell/sidebar.js +251 -281
- package/dist/shell/top-bar.js +203 -237
- package/dist/tailwind/index.cjs +426 -442
- package/dist/tailwind/index.js +2 -4
- package/dist/tailwind/preset.js +443 -459
- package/dist/ui/accordion.js +52 -60
- package/dist/ui/alert-dialog.js +111 -156
- package/dist/ui/alert.js +177 -99
- package/dist/ui/aspect-ratio.js +13 -16
- package/dist/ui/autocomplete.js +112 -148
- package/dist/ui/avatar.js +196 -169
- package/dist/ui/badge-group.js +2 -7
- package/dist/ui/badge-indicator.js +42 -51
- package/dist/ui/badge.js +2 -15
- package/dist/ui/banner.js +76 -68
- package/dist/ui/breadcrumb.js +65 -84
- package/dist/ui/button-group.js +109 -102
- package/dist/ui/button-processing.js +69 -73
- package/dist/ui/button.js +393 -279
- package/dist/ui/card.js +151 -157
- package/dist/ui/charts/index.js +1002 -1319
- package/dist/ui/chat/index.js +2 -11
- package/dist/ui/checkbox.js +77 -100
- package/dist/ui/code.js +18 -32
- package/dist/ui/collapsible.js +21 -29
- package/dist/ui/color-input.js +453 -372
- package/dist/ui/color-swatch.js +60 -90
- package/dist/ui/combobox.js +244 -293
- package/dist/ui/container.js +18 -24
- package/dist/ui/context-menu.js +154 -203
- package/dist/ui/data-table-body.js +116 -213
- package/dist/ui/data-table-bulk-actions.js +43 -59
- package/dist/ui/data-table-card.js +84 -71
- package/dist/ui/data-table-context.js +39 -42
- package/dist/ui/data-table-header.js +98 -139
- package/dist/ui/data-table-pagination.js +69 -82
- package/dist/ui/data-table-toolbar.js +104 -130
- package/dist/ui/data-table.js +278 -354
- package/dist/ui/devalok-grain.js +77 -66
- package/dist/ui/dialog.js +122 -151
- package/dist/ui/dropdown-menu.js +152 -203
- package/dist/ui/file-upload.js +242 -266
- package/dist/ui/form.js +60 -56
- package/dist/ui/hover-card.js +54 -54
- package/dist/ui/icon-button.js +21 -26
- package/dist/ui/icon-context.js +17 -17
- package/dist/ui/icon-group.js +22 -29
- package/dist/ui/icon.js +201 -121
- package/dist/ui/index.js +74 -350
- package/dist/ui/input-otp.js +44 -48
- package/dist/ui/input.js +92 -169
- package/dist/ui/label.js +17 -22
- package/dist/ui/lib/date-utils.js +14 -11
- package/dist/ui/lib/motion.js +77 -36
- package/dist/ui/lib/utils.js +39 -16
- package/dist/ui/link.js +13 -24
- package/dist/ui/menubar.js +132 -210
- package/dist/ui/navigation-menu.js +163 -193
- package/dist/ui/number-input.js +72 -95
- package/dist/ui/pagination.js +122 -159
- package/dist/ui/popover.js +2 -131
- package/dist/ui/progress-ring.js +133 -143
- package/dist/ui/progress.js +51 -95
- package/dist/ui/radio.js +41 -50
- package/dist/ui/search-input.js +51 -53
- package/dist/ui/segmented-control.js +93 -114
- package/dist/ui/select.js +131 -157
- package/dist/ui/separator.js +15 -25
- package/dist/ui/sheet.js +135 -163
- package/dist/ui/sidebar.js +357 -600
- package/dist/ui/skeleton.js +179 -231
- package/dist/ui/slider.js +24 -34
- package/dist/ui/spinner.js +226 -205
- package/dist/ui/split-button.js +227 -276
- package/dist/ui/stack.js +56 -70
- package/dist/ui/stat-card.js +259 -251
- package/dist/ui/status-dot.js +67 -63
- package/dist/ui/stepper.js +119 -168
- package/dist/ui/switch.js +51 -54
- package/dist/ui/table.js +57 -90
- package/dist/ui/tabs.js +139 -156
- package/dist/ui/text.js +52 -59
- package/dist/ui/textarea.js +40 -57
- package/dist/ui/toast-types.js +0 -1
- package/dist/ui/toast.js +554 -536
- package/dist/ui/toaster.js +23 -33
- package/dist/ui/toggle-group.js +37 -41
- package/dist/ui/toggle.js +36 -40
- package/dist/ui/tooltip.js +80 -65
- package/dist/ui/tree-view/index.js +2 -6
- package/dist/ui/visually-hidden.js +12 -10
- package/llms-full.txt +1 -1
- package/package.json +1 -1
- package/dist/_chunks/date-time-picker.js +0 -851
- package/dist/_chunks/typing-indicator.js +0 -565
package/dist/ui/progress-ring.js
CHANGED
|
@@ -1,144 +1,134 @@
|
|
|
1
1
|
"use client";
|
|
2
|
-
import {
|
|
3
|
-
import
|
|
4
|
-
import {
|
|
5
|
-
import
|
|
6
|
-
import {
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
|
|
71
|
-
|
|
72
|
-
|
|
73
|
-
|
|
74
|
-
|
|
75
|
-
|
|
76
|
-
|
|
77
|
-
|
|
78
|
-
|
|
79
|
-
|
|
80
|
-
|
|
81
|
-
|
|
82
|
-
|
|
83
|
-
|
|
84
|
-
|
|
85
|
-
|
|
86
|
-
|
|
87
|
-
|
|
88
|
-
|
|
89
|
-
|
|
90
|
-
|
|
91
|
-
|
|
92
|
-
|
|
93
|
-
|
|
94
|
-
|
|
95
|
-
|
|
96
|
-
|
|
97
|
-
|
|
98
|
-
|
|
99
|
-
|
|
100
|
-
|
|
101
|
-
|
|
102
|
-
|
|
103
|
-
|
|
104
|
-
|
|
105
|
-
|
|
106
|
-
|
|
107
|
-
|
|
108
|
-
|
|
109
|
-
|
|
110
|
-
|
|
111
|
-
|
|
112
|
-
|
|
113
|
-
|
|
114
|
-
|
|
115
|
-
|
|
116
|
-
|
|
117
|
-
|
|
118
|
-
|
|
119
|
-
|
|
120
|
-
|
|
121
|
-
|
|
122
|
-
|
|
123
|
-
|
|
124
|
-
|
|
125
|
-
|
|
126
|
-
|
|
127
|
-
|
|
128
|
-
|
|
129
|
-
|
|
130
|
-
|
|
131
|
-
|
|
132
|
-
|
|
133
|
-
|
|
134
|
-
|
|
135
|
-
})
|
|
136
|
-
}
|
|
137
|
-
);
|
|
138
|
-
}
|
|
139
|
-
);
|
|
140
|
-
V.displayName = "MultiProgressRing";
|
|
141
|
-
export {
|
|
142
|
-
V as MultiProgressRing,
|
|
143
|
-
B as ProgressRing
|
|
144
|
-
};
|
|
2
|
+
import { a as e, i as t, n, r, t as i } from "../_chunks/framer.js";
|
|
3
|
+
import { springs as a } from "./lib/motion.js";
|
|
4
|
+
import { cn as o } from "./lib/utils.js";
|
|
5
|
+
import * as s from "react";
|
|
6
|
+
import { jsx as c, jsxs as l } from "react/jsx-runtime";
|
|
7
|
+
//#region src/ui/progress-ring.tsx
|
|
8
|
+
var u = {
|
|
9
|
+
default: "var(--color-accent-9)",
|
|
10
|
+
success: "var(--color-success-9)",
|
|
11
|
+
warning: "var(--color-warning-9)",
|
|
12
|
+
error: "var(--color-error-9)",
|
|
13
|
+
info: "var(--color-info-9)"
|
|
14
|
+
}, d = {
|
|
15
|
+
sm: {
|
|
16
|
+
size: 32,
|
|
17
|
+
strokeWidth: 3,
|
|
18
|
+
fontSize: "text-ds-xs"
|
|
19
|
+
},
|
|
20
|
+
md: {
|
|
21
|
+
size: 48,
|
|
22
|
+
strokeWidth: 3.5,
|
|
23
|
+
fontSize: "text-ds-sm"
|
|
24
|
+
},
|
|
25
|
+
lg: {
|
|
26
|
+
size: 64,
|
|
27
|
+
strokeWidth: 4,
|
|
28
|
+
fontSize: "text-ds-md"
|
|
29
|
+
}
|
|
30
|
+
}, f = s.forwardRef(({ value: f, max: p = 100, size: m = "md", color: h = "default", showValue: g = !1, label: _, className: v, ...y }, b) => {
|
|
31
|
+
let x = n(), S = d[m], C = (S.size - S.strokeWidth) / 2, w = 2 * Math.PI * C, T = Math.min(Math.max(f / p, 0), 1), E = w * (1 - T), D = S.size / 2, O = Math.round(T * 100), k = t(0), A = r(k, (e) => `${Math.round(e)}%`);
|
|
32
|
+
return s.useEffect(() => {
|
|
33
|
+
let e = i(k, T * 100, x ? {
|
|
34
|
+
type: "tween",
|
|
35
|
+
duration: 0
|
|
36
|
+
} : {
|
|
37
|
+
stiffness: 100,
|
|
38
|
+
damping: 30,
|
|
39
|
+
type: "spring"
|
|
40
|
+
});
|
|
41
|
+
return () => e.stop();
|
|
42
|
+
}, [
|
|
43
|
+
T,
|
|
44
|
+
k,
|
|
45
|
+
x
|
|
46
|
+
]), /* @__PURE__ */ l("svg", {
|
|
47
|
+
ref: b,
|
|
48
|
+
width: S.size,
|
|
49
|
+
height: S.size,
|
|
50
|
+
viewBox: `0 0 ${S.size} ${S.size}`,
|
|
51
|
+
role: "progressbar",
|
|
52
|
+
"aria-valuenow": f,
|
|
53
|
+
"aria-valuemin": 0,
|
|
54
|
+
"aria-valuemax": p,
|
|
55
|
+
"aria-label": _ ?? `${O}% progress`,
|
|
56
|
+
className: o("shrink-0", v),
|
|
57
|
+
...y,
|
|
58
|
+
children: [
|
|
59
|
+
/* @__PURE__ */ c("circle", {
|
|
60
|
+
cx: D,
|
|
61
|
+
cy: D,
|
|
62
|
+
r: C,
|
|
63
|
+
fill: "none",
|
|
64
|
+
stroke: "var(--color-surface-raised-hover)",
|
|
65
|
+
strokeWidth: S.strokeWidth
|
|
66
|
+
}),
|
|
67
|
+
/* @__PURE__ */ c(e.circle, {
|
|
68
|
+
cx: D,
|
|
69
|
+
cy: D,
|
|
70
|
+
r: C,
|
|
71
|
+
fill: "none",
|
|
72
|
+
stroke: u[h],
|
|
73
|
+
strokeWidth: S.strokeWidth,
|
|
74
|
+
strokeLinecap: "round",
|
|
75
|
+
strokeDasharray: w,
|
|
76
|
+
initial: { strokeDashoffset: w },
|
|
77
|
+
animate: { strokeDashoffset: E },
|
|
78
|
+
transition: x ? { duration: 0 } : a.smooth,
|
|
79
|
+
transform: `rotate(-90 ${D} ${D})`
|
|
80
|
+
}),
|
|
81
|
+
g && /* @__PURE__ */ c(e.text, {
|
|
82
|
+
x: D,
|
|
83
|
+
y: D,
|
|
84
|
+
textAnchor: "middle",
|
|
85
|
+
dominantBaseline: "central",
|
|
86
|
+
className: o(S.fontSize, "fill-surface-fg font-sans font-semibold"),
|
|
87
|
+
children: A
|
|
88
|
+
})
|
|
89
|
+
]
|
|
90
|
+
});
|
|
91
|
+
});
|
|
92
|
+
f.displayName = "ProgressRing";
|
|
93
|
+
var p = s.forwardRef(({ rings: t, size: r = "md", className: i, ...f }, p) => {
|
|
94
|
+
let m = n(), h = d[r], g = h.size / 2, _ = h.strokeWidth + 2;
|
|
95
|
+
return /* @__PURE__ */ c("svg", {
|
|
96
|
+
ref: p,
|
|
97
|
+
width: h.size,
|
|
98
|
+
height: h.size,
|
|
99
|
+
viewBox: `0 0 ${h.size} ${h.size}`,
|
|
100
|
+
role: "group",
|
|
101
|
+
"aria-label": "Progress rings",
|
|
102
|
+
className: o("shrink-0", i),
|
|
103
|
+
...f,
|
|
104
|
+
children: t.map((t, n) => {
|
|
105
|
+
let r = (h.size - h.strokeWidth) / 2 - n * _;
|
|
106
|
+
if (r <= 0) return null;
|
|
107
|
+
let i = 2 * Math.PI * r, o = i * (1 - Math.min(Math.max(t.value / (t.max ?? 100), 0), 1));
|
|
108
|
+
return /* @__PURE__ */ l(s.Fragment, { children: [/* @__PURE__ */ c("circle", {
|
|
109
|
+
cx: g,
|
|
110
|
+
cy: g,
|
|
111
|
+
r,
|
|
112
|
+
fill: "none",
|
|
113
|
+
stroke: "var(--color-surface-raised-hover)",
|
|
114
|
+
strokeWidth: h.strokeWidth
|
|
115
|
+
}), /* @__PURE__ */ c(e.circle, {
|
|
116
|
+
cx: g,
|
|
117
|
+
cy: g,
|
|
118
|
+
r,
|
|
119
|
+
fill: "none",
|
|
120
|
+
stroke: u[t.color ?? "default"],
|
|
121
|
+
strokeWidth: h.strokeWidth,
|
|
122
|
+
strokeLinecap: "round",
|
|
123
|
+
strokeDasharray: i,
|
|
124
|
+
initial: { strokeDashoffset: i },
|
|
125
|
+
animate: { strokeDashoffset: o },
|
|
126
|
+
transition: m ? { duration: 0 } : a.smooth,
|
|
127
|
+
transform: `rotate(-90 ${g} ${g})`
|
|
128
|
+
})] }, n);
|
|
129
|
+
})
|
|
130
|
+
});
|
|
131
|
+
});
|
|
132
|
+
p.displayName = "MultiProgressRing";
|
|
133
|
+
//#endregion
|
|
134
|
+
export { p as MultiProgressRing, f as ProgressRing };
|
package/dist/ui/progress.js
CHANGED
|
@@ -1,96 +1,52 @@
|
|
|
1
1
|
"use client";
|
|
2
|
-
import {
|
|
3
|
-
import
|
|
4
|
-
import {
|
|
5
|
-
import {
|
|
6
|
-
import { cn as
|
|
7
|
-
import
|
|
8
|
-
import {
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
),
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
...h,
|
|
54
|
-
children: e ? /* @__PURE__ */ a(
|
|
55
|
-
d,
|
|
56
|
-
{
|
|
57
|
-
className: s(
|
|
58
|
-
l({ color: i }),
|
|
59
|
-
"w-2/5 animate-progress-indeterminate motion-reduce:animate-none",
|
|
60
|
-
t
|
|
61
|
-
)
|
|
62
|
-
}
|
|
63
|
-
) : /* @__PURE__ */ a(
|
|
64
|
-
d,
|
|
65
|
-
{
|
|
66
|
-
className: s("h-full", t),
|
|
67
|
-
asChild: !0,
|
|
68
|
-
children: /* @__PURE__ */ a(
|
|
69
|
-
b.div,
|
|
70
|
-
{
|
|
71
|
-
className: s(
|
|
72
|
-
l({ color: i }),
|
|
73
|
-
"transition-colors duration-moderate-01 ease-productive-standard"
|
|
74
|
-
),
|
|
75
|
-
initial: !1,
|
|
76
|
-
animate: { width: `${r || 0}%` },
|
|
77
|
-
transition: N.smooth
|
|
78
|
-
}
|
|
79
|
-
)
|
|
80
|
-
}
|
|
81
|
-
)
|
|
82
|
-
}
|
|
83
|
-
),
|
|
84
|
-
o && !e && /* @__PURE__ */ n("span", { className: "shrink-0 text-ds-xs text-surface-fg-muted tabular-nums", children: [
|
|
85
|
-
r,
|
|
86
|
-
"%"
|
|
87
|
-
] })
|
|
88
|
-
] });
|
|
89
|
-
}
|
|
90
|
-
);
|
|
91
|
-
V.displayName = c.displayName;
|
|
92
|
-
export {
|
|
93
|
-
V as Progress,
|
|
94
|
-
l as progressIndicatorVariants,
|
|
95
|
-
v as progressTrackVariants
|
|
96
|
-
};
|
|
2
|
+
import { F as e, P as t } from "../_chunks/primitives.js";
|
|
3
|
+
import { a as n } from "../_chunks/framer.js";
|
|
4
|
+
import { springs as r } from "./lib/motion.js";
|
|
5
|
+
import { t as i } from "../_chunks/vendor-utils.js";
|
|
6
|
+
import { cn as a } from "./lib/utils.js";
|
|
7
|
+
import * as o from "react";
|
|
8
|
+
import { jsx as s, jsxs as c } from "react/jsx-runtime";
|
|
9
|
+
//#region src/ui/progress.tsx
|
|
10
|
+
var l = i("relative w-full overflow-hidden rounded-ds-full bg-surface-raised", {
|
|
11
|
+
variants: { size: {
|
|
12
|
+
sm: "h-1",
|
|
13
|
+
md: "h-2",
|
|
14
|
+
lg: "h-3"
|
|
15
|
+
} },
|
|
16
|
+
defaultVariants: { size: "md" }
|
|
17
|
+
}), u = i("h-full w-full flex-1 transition-[width] duration-moderate-02 ease-expressive-standard", {
|
|
18
|
+
variants: { color: {
|
|
19
|
+
default: "bg-accent-9",
|
|
20
|
+
success: "bg-success-9",
|
|
21
|
+
warning: "bg-warning-9",
|
|
22
|
+
error: "bg-error-9"
|
|
23
|
+
} },
|
|
24
|
+
defaultVariants: { color: "default" }
|
|
25
|
+
}), d = o.forwardRef(({ className: i, value: o, size: d, color: f, indicatorClassName: p, showLabel: m, autoColor: h, ...g }, _) => {
|
|
26
|
+
let v = o == null, y = h && o != null ? o > 100 ? "error" : o >= 85 ? "success" : o >= 60 ? "warning" : "default" : f;
|
|
27
|
+
return /* @__PURE__ */ c("div", {
|
|
28
|
+
className: a("flex items-center gap-ds-03", m && "w-full"),
|
|
29
|
+
children: [/* @__PURE__ */ s(e, {
|
|
30
|
+
ref: _,
|
|
31
|
+
value: v ? null : o,
|
|
32
|
+
className: a(l({ size: d }), i),
|
|
33
|
+
...g,
|
|
34
|
+
children: v ? /* @__PURE__ */ s(t, { className: a(u({ color: y }), "w-2/5 animate-progress-indeterminate motion-reduce:animate-none", p) }) : /* @__PURE__ */ s(t, {
|
|
35
|
+
className: a("h-full", p),
|
|
36
|
+
asChild: !0,
|
|
37
|
+
children: /* @__PURE__ */ s(n.div, {
|
|
38
|
+
className: a(u({ color: y }), "transition-colors duration-moderate-01 ease-productive-standard"),
|
|
39
|
+
initial: !1,
|
|
40
|
+
animate: { width: `${o || 0}%` },
|
|
41
|
+
transition: r.smooth
|
|
42
|
+
})
|
|
43
|
+
})
|
|
44
|
+
}), m && !v && /* @__PURE__ */ c("span", {
|
|
45
|
+
className: "shrink-0 text-ds-xs text-surface-fg-muted tabular-nums",
|
|
46
|
+
children: [o, "%"]
|
|
47
|
+
})]
|
|
48
|
+
});
|
|
49
|
+
});
|
|
50
|
+
d.displayName = e.displayName;
|
|
51
|
+
//#endregion
|
|
52
|
+
export { d as Progress, u as progressIndicatorVariants, l as progressTrackVariants };
|
package/dist/ui/radio.js
CHANGED
|
@@ -1,51 +1,42 @@
|
|
|
1
1
|
"use client";
|
|
2
|
-
import {
|
|
3
|
-
import {
|
|
4
|
-
import {
|
|
5
|
-
import
|
|
6
|
-
import
|
|
7
|
-
import {
|
|
8
|
-
import {
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
}
|
|
44
|
-
) })
|
|
45
|
-
}
|
|
46
|
-
));
|
|
47
|
-
b.displayName = t.displayName;
|
|
48
|
-
export {
|
|
49
|
-
u as RadioGroup,
|
|
50
|
-
b as RadioGroupItem
|
|
51
|
-
};
|
|
2
|
+
import { ct as e, ot as t, st as n } from "../_chunks/primitives.js";
|
|
3
|
+
import { a as r } from "../_chunks/framer.js";
|
|
4
|
+
import { springs as i } from "./lib/motion.js";
|
|
5
|
+
import { cn as a } from "./lib/utils.js";
|
|
6
|
+
import * as o from "react";
|
|
7
|
+
import { jsx as s } from "react/jsx-runtime";
|
|
8
|
+
import { IconCircle as c } from "@tabler/icons-react";
|
|
9
|
+
//#region src/ui/radio.tsx
|
|
10
|
+
var l = o.forwardRef(({ className: t, ...n }, r) => /* @__PURE__ */ s(e, {
|
|
11
|
+
className: a("grid gap-ds-03", t),
|
|
12
|
+
...n,
|
|
13
|
+
ref: r
|
|
14
|
+
}));
|
|
15
|
+
l.displayName = e.displayName;
|
|
16
|
+
var u = {
|
|
17
|
+
sm: "h-5 w-5",
|
|
18
|
+
md: "h-6 w-6",
|
|
19
|
+
lg: "h-7 w-7"
|
|
20
|
+
}, d = {
|
|
21
|
+
sm: "h-1.5 w-1.5",
|
|
22
|
+
md: "h-ds-03 w-ds-03",
|
|
23
|
+
lg: "h-2.5 w-2.5"
|
|
24
|
+
}, f = o.forwardRef(({ className: e, size: o = "md", ...l }, f) => /* @__PURE__ */ s(n, {
|
|
25
|
+
ref: f,
|
|
26
|
+
className: a("touch-target aspect-square rounded-ds-full", u[o], "border border-surface-border-strong bg-surface-raised-hover", "transition-colors duration-fast-01", "focus-visible:outline-hidden focus-visible:ring-2 focus-visible:ring-accent-9 focus-visible:ring-offset-2", "disabled:cursor-not-allowed disabled:opacity-action-disabled", "hover:border-accent-7 hover:bg-surface-raised-active", "data-[state=checked]:border-accent-7", e),
|
|
27
|
+
...l,
|
|
28
|
+
children: /* @__PURE__ */ s(t, {
|
|
29
|
+
asChild: !0,
|
|
30
|
+
className: "flex items-center justify-center",
|
|
31
|
+
children: /* @__PURE__ */ s(r.span, {
|
|
32
|
+
className: "flex items-center justify-center",
|
|
33
|
+
initial: { scale: 0 },
|
|
34
|
+
animate: { scale: 1 },
|
|
35
|
+
transition: i.bouncy,
|
|
36
|
+
children: /* @__PURE__ */ s(c, { className: a(d[o], "fill-accent-9 text-accent-11") })
|
|
37
|
+
})
|
|
38
|
+
})
|
|
39
|
+
}));
|
|
40
|
+
f.displayName = n.displayName;
|
|
41
|
+
//#endregion
|
|
42
|
+
export { l as RadioGroup, f as RadioGroupItem };
|
package/dist/ui/search-input.js
CHANGED
|
@@ -1,54 +1,52 @@
|
|
|
1
1
|
"use client";
|
|
2
|
-
import {
|
|
3
|
-
import {
|
|
4
|
-
import
|
|
5
|
-
import {
|
|
6
|
-
import {
|
|
7
|
-
import {
|
|
8
|
-
import
|
|
9
|
-
import {
|
|
10
|
-
import {
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
export {
|
|
53
|
-
C as SearchInput
|
|
54
|
-
};
|
|
2
|
+
import { a as e, c as t } from "../_chunks/framer.js";
|
|
3
|
+
import { springs as n } from "./lib/motion.js";
|
|
4
|
+
import { Spinner as r } from "./spinner.js";
|
|
5
|
+
import { Icon as i } from "./icon.js";
|
|
6
|
+
import { Button as a } from "./button.js";
|
|
7
|
+
import { Input as o } from "./input.js";
|
|
8
|
+
import * as s from "react";
|
|
9
|
+
import { jsx as c } from "react/jsx-runtime";
|
|
10
|
+
import { IconSearch as l, IconX as u } from "@tabler/icons-react";
|
|
11
|
+
//#region src/ui/search-input.tsx
|
|
12
|
+
var d = s.forwardRef(({ className: s, value: d, onClear: f, loading: p, size: m = "md", placeholder: h, ...g }, _) => {
|
|
13
|
+
let v = d !== void 0 && d !== "", y = p ? /* @__PURE__ */ c(r, { size: "sm" }) : /* @__PURE__ */ c(t, { children: v && f && /* @__PURE__ */ c(e.div, {
|
|
14
|
+
initial: {
|
|
15
|
+
opacity: 0,
|
|
16
|
+
scale: .8
|
|
17
|
+
},
|
|
18
|
+
animate: {
|
|
19
|
+
opacity: 1,
|
|
20
|
+
scale: 1
|
|
21
|
+
},
|
|
22
|
+
exit: {
|
|
23
|
+
opacity: 0,
|
|
24
|
+
scale: .8
|
|
25
|
+
},
|
|
26
|
+
transition: n.snappy,
|
|
27
|
+
children: /* @__PURE__ */ c(a, {
|
|
28
|
+
type: "button",
|
|
29
|
+
variant: "ghost",
|
|
30
|
+
size: "icon-xs",
|
|
31
|
+
onClick: f,
|
|
32
|
+
"aria-label": "Clear search",
|
|
33
|
+
title: "Clear",
|
|
34
|
+
children: /* @__PURE__ */ c(i, { icon: u })
|
|
35
|
+
})
|
|
36
|
+
}) });
|
|
37
|
+
return /* @__PURE__ */ c(o, {
|
|
38
|
+
ref: _,
|
|
39
|
+
size: m,
|
|
40
|
+
startSection: /* @__PURE__ */ c(i, { icon: l }),
|
|
41
|
+
endSection: y,
|
|
42
|
+
endSectionClickable: !!v && !p,
|
|
43
|
+
placeholder: h,
|
|
44
|
+
value: d,
|
|
45
|
+
"aria-busy": p || void 0,
|
|
46
|
+
className: s,
|
|
47
|
+
...g
|
|
48
|
+
});
|
|
49
|
+
});
|
|
50
|
+
d.displayName = "SearchInput";
|
|
51
|
+
//#endregion
|
|
52
|
+
export { d as SearchInput };
|