@koide-labs/ui 0.1.1 → 0.1.2
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/accordion.css +1 -1
- package/dist/alert-dialog.css +1 -1
- package/dist/anchor.css +1 -1
- package/dist/avatar.css +1 -1
- package/dist/badge.css +1 -1
- package/dist/button.css +1 -1
- package/dist/checkbox.css +1 -1
- package/dist/code.css +1 -1
- package/dist/collapse.css +1 -1
- package/dist/command.css +1 -1
- package/dist/components/accordion/accordion.js +40 -40
- package/dist/components/alert-dialog/alert-dialog.js +9 -9
- package/dist/components/anchor/anchor.js +5 -5
- package/dist/components/avatar/avatar.js +26 -26
- package/dist/components/badge/badge.js +13 -13
- package/dist/components/button/button.js +13 -13
- package/dist/components/checkbox/checkbox.js +1 -1
- package/dist/components/code/code.js +48 -48
- package/dist/components/collapse/collapse.js +14 -14
- package/dist/components/command/command.js +121 -121
- package/dist/components/context-menu/context-menu.js +6 -6
- package/dist/components/dialog/dialog.js +1 -1
- package/dist/components/heading/heading.js +6 -6
- package/dist/components/icon/icon.js +12 -12
- package/dist/components/icon-button/icon-button.js +26 -26
- package/dist/components/inline-code/inline-code.js +2 -2
- package/dist/components/input/input.js +1 -1
- package/dist/components/meter/meter.js +40 -40
- package/dist/components/multiline-input/multiline-input.js +1 -1
- package/dist/components/number-input/number-input.js +7 -7
- package/dist/components/password-input/password-input.js +2 -2
- package/dist/components/pill/pill.js +11 -11
- package/dist/components/popover/popover.js +21 -21
- package/dist/components/preview-card/preview-card.js +2 -2
- package/dist/components/radio-group/radio-group.js +54 -54
- package/dist/components/search-bar/search-bar.js +8 -8
- package/dist/components/select/select.js +75 -75
- package/dist/components/separator/index.js +1 -1
- package/dist/components/separator/separator.js +1 -1
- package/dist/components/slider/slider.js +128 -128
- package/dist/components/spinner/spinner.js +4 -4
- package/dist/components/stacked-avatars/stacked-avatars.js +35 -35
- package/dist/components/status-banner/status-banner.js +22 -22
- package/dist/components/surface/surface.js +14 -14
- package/dist/components/switch/switch.js +28 -28
- package/dist/components/tabs/tabs.js +132 -132
- package/dist/components/text/text.js +15 -15
- package/dist/components/timestamp/timestamp.js +73 -73
- package/dist/components/toaster/toaster.js +165 -165
- package/dist/components/tooltip/index.js +1 -1
- package/dist/components/tooltip/tooltip.js +1 -1
- package/dist/components/view/view.js +40 -40
- package/dist/context-menu.css +1 -1
- package/dist/dialog.css +1 -1
- package/dist/{dialog.module-DsbQRp-d.js → dialog.module-Pi1eHwli.js} +13 -13
- package/dist/heading.css +1 -1
- package/dist/icon-button.css +1 -1
- package/dist/icon.css +1 -1
- package/dist/index.js +2 -2
- package/dist/inline-code.css +1 -1
- package/dist/input.css +1 -1
- package/dist/input.module-zw1dlr1_.js +8 -0
- package/dist/integrations/react-markdown/index.js +1 -1
- package/dist/meter.css +1 -1
- package/dist/number-input.css +1 -1
- package/dist/password-input.css +1 -1
- package/dist/pill.css +1 -1
- package/dist/popover.css +1 -1
- package/dist/preview-card.css +1 -1
- package/dist/radio-group.css +1 -1
- package/dist/search-bar.css +1 -1
- package/dist/select.css +1 -1
- package/dist/{separator-fh_wDZNf.js → separator-wNYojB9q.js} +8 -8
- package/dist/separator.css +1 -1
- package/dist/slider.css +1 -1
- package/dist/spinner.css +1 -1
- package/dist/stacked-avatars.css +1 -1
- package/dist/status-banner.css +1 -1
- package/dist/styles/core.css +1 -1
- package/dist/surface.css +1 -1
- package/dist/switch.css +1 -1
- package/dist/tabs.css +1 -1
- package/dist/text.css +1 -1
- package/dist/timestamp.css +1 -1
- package/dist/toaster.css +1 -1
- package/dist/{tooltip-oCp-elli.js → tooltip-DZkByWDR.js} +63 -63
- package/dist/tooltip.css +1 -1
- package/dist/view.css +1 -1
- package/dist/view.module-DlwuNdUj.js +6 -0
- package/dist/view2.css +1 -1
- package/package.json +1 -1
- package/dist/input.module-CtE19OH8.js +0 -8
- package/dist/view.module-Dj7wj0kk.js +0 -6
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { jsx as P, jsxs as q } from "react/jsx-runtime";
|
|
2
2
|
import { c as pe } from "../../clsx-OuTLNxxd.js";
|
|
3
|
-
import { t as z, T as fe } from "../../tooltip-
|
|
3
|
+
import { t as z, T as fe } from "../../tooltip-DZkByWDR.js";
|
|
4
4
|
import { d as me, e as Pe, f as Ce, p as U, t as ge } from "../../transitions.module-D9mMAtfI.js";
|
|
5
5
|
import { Surface as we } from "../surface/surface.js";
|
|
6
6
|
import * as e from "react";
|
|
@@ -352,7 +352,7 @@ const ie = /* @__PURE__ */ e.forwardRef(function(s, u) {
|
|
|
352
352
|
});
|
|
353
353
|
process.env.NODE_ENV !== "production" && (ie.displayName = "PreviewCardArrow");
|
|
354
354
|
const Be = {
|
|
355
|
-
"preview-card": "_preview-
|
|
355
|
+
"preview-card": "_preview-card_3k0u3_2"
|
|
356
356
|
};
|
|
357
357
|
function ct({
|
|
358
358
|
align: t,
|
|
@@ -4,24 +4,24 @@ import * as o from "react";
|
|
|
4
4
|
import { createContext as Ee, useContext as Ne } from "react";
|
|
5
5
|
import { u as Ve } from "../../useControlled-Du4sJyMj.js";
|
|
6
6
|
import { E as ce, b as de, u as re, N as F, d as fe, m as Pe } from "../../useRenderElement-DngNDu_P.js";
|
|
7
|
-
import { u as
|
|
7
|
+
import { u as S } from "../../useStableCallback-DKZHlUAT.js";
|
|
8
8
|
import { v as pe } from "../../visuallyHidden-CpJ-mhai.js";
|
|
9
9
|
import { u as me } from "../../useBaseUiId-B7WyxtIE.js";
|
|
10
10
|
import { S as Ie } from "../../composite-BwEK5cWH.js";
|
|
11
11
|
import { u as ke, A as Oe, C as Me } from "../../CompositeRoot-CCgh2M64.js";
|
|
12
12
|
import { f as Ce, a as he, u as Re, c as Fe, b as Te } from "../../LabelableContext-Be1u-eFg.js";
|
|
13
|
-
import { f as
|
|
14
|
-
import { u as
|
|
15
|
-
import { f as
|
|
16
|
-
import { View as
|
|
13
|
+
import { f as ge } from "../../formatErrorMessage-BqPuTBN-.js";
|
|
14
|
+
import { u as we } from "../../useValueChanged-MJRmEWz1.js";
|
|
15
|
+
import { f as Ge } from "../../element-u5WgOZX1.js";
|
|
16
|
+
import { View as Se } from "../view/view.js";
|
|
17
17
|
import { Text as qe } from "../text/text.js";
|
|
18
18
|
import { t as De, u as Be } from "../../useOpenChangeComplete-BHd-N7Ig.js";
|
|
19
19
|
import { u as Ke } from "../../useTransitionStatus-CmMyUh74.js";
|
|
20
20
|
import { u as Le } from "../../useIsoLayoutEffect-CIDbvm3Q.js";
|
|
21
21
|
import { c as Ue, n as Ye } from "../../createBaseUIEventDetails-CCSfZ2vM.js";
|
|
22
22
|
import { u as je } from "../../FieldItemContext-DAvk99to.js";
|
|
23
|
-
import { u as
|
|
24
|
-
import { u as
|
|
23
|
+
import { u as He } from "../../useLabelableId-CX4tcfzK.js";
|
|
24
|
+
import { u as ze } from "../../useButton-d3_JgBNr.js";
|
|
25
25
|
import '../../radio-group.css';function Je(e) {
|
|
26
26
|
const {
|
|
27
27
|
render: n,
|
|
@@ -32,7 +32,7 @@ import '../../radio-group.css';function Je(e) {
|
|
|
32
32
|
metadata: r,
|
|
33
33
|
stateAttributesMapping: a,
|
|
34
34
|
tag: s = "div",
|
|
35
|
-
...
|
|
35
|
+
...g
|
|
36
36
|
} = e, {
|
|
37
37
|
compositeProps: b,
|
|
38
38
|
compositeRef: _
|
|
@@ -42,21 +42,21 @@ import '../../radio-group.css';function Je(e) {
|
|
|
42
42
|
return re(s, e, {
|
|
43
43
|
state: h,
|
|
44
44
|
ref: [...m, _],
|
|
45
|
-
props: [b, ...R,
|
|
45
|
+
props: [b, ...R, g],
|
|
46
46
|
stateAttributesMapping: a
|
|
47
47
|
});
|
|
48
48
|
}
|
|
49
|
-
const
|
|
49
|
+
const ye = /* @__PURE__ */ o.createContext({
|
|
50
50
|
legendId: void 0,
|
|
51
51
|
setLegendId: () => {
|
|
52
52
|
},
|
|
53
53
|
disabled: void 0
|
|
54
54
|
});
|
|
55
|
-
process.env.NODE_ENV !== "production" && (
|
|
55
|
+
process.env.NODE_ENV !== "production" && (ye.displayName = "FieldsetRootContext");
|
|
56
56
|
function We(e = !1) {
|
|
57
|
-
const n = o.useContext(
|
|
57
|
+
const n = o.useContext(ye);
|
|
58
58
|
if (!n && !e)
|
|
59
|
-
throw new Error(process.env.NODE_ENV !== "production" ? "Base UI: FieldsetRootContext is missing. Fieldset parts must be placed within <Fieldset.Root>." :
|
|
59
|
+
throw new Error(process.env.NODE_ENV !== "production" ? "Base UI: FieldsetRootContext is missing. Fieldset parts must be placed within <Fieldset.Root>." : ge(86));
|
|
60
60
|
return n;
|
|
61
61
|
}
|
|
62
62
|
let le = /* @__PURE__ */ (function(e) {
|
|
@@ -93,7 +93,7 @@ process.env.NODE_ENV !== "production" && (se.displayName = "RadioRootContext");
|
|
|
93
93
|
function Ae() {
|
|
94
94
|
const e = o.useContext(se);
|
|
95
95
|
if (e === void 0)
|
|
96
|
-
throw new Error(process.env.NODE_ENV !== "production" ? "Base UI: RadioRootContext is missing. Radio parts must be placed within <Radio.Root>." :
|
|
96
|
+
throw new Error(process.env.NODE_ENV !== "production" ? "Base UI: RadioRootContext is missing. Radio parts must be placed within <Radio.Root>." : ge(52));
|
|
97
97
|
return e;
|
|
98
98
|
}
|
|
99
99
|
const be = /* @__PURE__ */ o.forwardRef(function(n, u) {
|
|
@@ -104,7 +104,7 @@ const be = /* @__PURE__ */ o.forwardRef(function(n, u) {
|
|
|
104
104
|
readOnly: r = !1,
|
|
105
105
|
required: a = !1,
|
|
106
106
|
value: s,
|
|
107
|
-
inputRef:
|
|
107
|
+
inputRef: g,
|
|
108
108
|
nativeButton: b = !1,
|
|
109
109
|
id: _,
|
|
110
110
|
...E
|
|
@@ -113,8 +113,8 @@ const be = /* @__PURE__ */ o.forwardRef(function(n, u) {
|
|
|
113
113
|
readOnly: V,
|
|
114
114
|
required: q,
|
|
115
115
|
checkedValue: T,
|
|
116
|
-
setCheckedValue:
|
|
117
|
-
touched:
|
|
116
|
+
setCheckedValue: w,
|
|
117
|
+
touched: z,
|
|
118
118
|
setTouched: J,
|
|
119
119
|
validation: W,
|
|
120
120
|
registerControlRef: P
|
|
@@ -126,13 +126,13 @@ const be = /* @__PURE__ */ o.forwardRef(function(n, u) {
|
|
|
126
126
|
state: K,
|
|
127
127
|
disabled: $
|
|
128
128
|
} = he(), A = je(), {
|
|
129
|
-
labelId:
|
|
129
|
+
labelId: y,
|
|
130
130
|
getDescriptionProps: v
|
|
131
|
-
} = Re(), i = $ || A.disabled || N || m, t = V || r, x = q || a, c = T === s, k = o.useRef(null), C = o.useRef(null),
|
|
131
|
+
} = Re(), i = $ || A.disabled || N || m, t = V || r, x = q || a, c = T === s, k = o.useRef(null), C = o.useRef(null), G = fe(g, C);
|
|
132
132
|
Le(() => {
|
|
133
133
|
C.current?.checked && I(!0);
|
|
134
134
|
}, [I]);
|
|
135
|
-
const L = me(), O =
|
|
135
|
+
const L = me(), O = He({
|
|
136
136
|
id: _,
|
|
137
137
|
implicit: !1,
|
|
138
138
|
controlRef: k
|
|
@@ -142,7 +142,7 @@ const be = /* @__PURE__ */ o.forwardRef(function(n, u) {
|
|
|
142
142
|
"aria-required": x || void 0,
|
|
143
143
|
"aria-disabled": i || void 0,
|
|
144
144
|
"aria-readonly": t || void 0,
|
|
145
|
-
"aria-labelledby":
|
|
145
|
+
"aria-labelledby": y,
|
|
146
146
|
[Oe]: c ? "" : void 0,
|
|
147
147
|
id: L,
|
|
148
148
|
disabled: i,
|
|
@@ -153,17 +153,17 @@ const be = /* @__PURE__ */ o.forwardRef(function(n, u) {
|
|
|
153
153
|
f.defaultPrevented || i || t || (f.preventDefault(), C.current?.click());
|
|
154
154
|
},
|
|
155
155
|
onFocus(f) {
|
|
156
|
-
f.defaultPrevented || i || t || !
|
|
156
|
+
f.defaultPrevented || i || t || !z || (C.current?.click(), J(!1));
|
|
157
157
|
}
|
|
158
158
|
}, {
|
|
159
159
|
getButtonProps: X,
|
|
160
160
|
buttonRef: U
|
|
161
|
-
} =
|
|
161
|
+
} = ze({
|
|
162
162
|
disabled: i,
|
|
163
163
|
native: b
|
|
164
164
|
}), Z = o.useMemo(() => ({
|
|
165
165
|
type: "radio",
|
|
166
|
-
ref:
|
|
166
|
+
ref: G,
|
|
167
167
|
id: O,
|
|
168
168
|
tabIndex: -1,
|
|
169
169
|
style: pe,
|
|
@@ -176,18 +176,18 @@ const be = /* @__PURE__ */ o.forwardRef(function(n, u) {
|
|
|
176
176
|
if (f.nativeEvent.defaultPrevented || i || t || s === void 0)
|
|
177
177
|
return;
|
|
178
178
|
const ie = Ue(Ye, f.nativeEvent);
|
|
179
|
-
ie.isCanceled || (B(!0), l(s !== D.initialValue), I(!0),
|
|
179
|
+
ie.isCanceled || (B(!0), l(s !== D.initialValue), I(!0), w(s, ie));
|
|
180
180
|
},
|
|
181
181
|
onFocus() {
|
|
182
182
|
k.current?.focus();
|
|
183
183
|
}
|
|
184
|
-
}), [c, i, O,
|
|
184
|
+
}), [c, i, O, G, t, x, w, l, B, I, D.initialValue, s]), M = o.useMemo(() => ({
|
|
185
185
|
...K,
|
|
186
186
|
required: x,
|
|
187
187
|
disabled: i,
|
|
188
188
|
readOnly: t,
|
|
189
189
|
checked: c
|
|
190
|
-
}), [K, i, t, c, x]), ee = o.useMemo(() => M, [M]), Y =
|
|
190
|
+
}), [K, i, t, c, x]), ee = o.useMemo(() => M, [M]), Y = w !== F, j = [u, P, k, U], d = [Q, v, W?.getValidationProps ?? ce, E, X], H = re("span", n, {
|
|
191
191
|
enabled: !Y,
|
|
192
192
|
state: M,
|
|
193
193
|
ref: j,
|
|
@@ -204,7 +204,7 @@ const be = /* @__PURE__ */ o.forwardRef(function(n, u) {
|
|
|
204
204
|
refs: j,
|
|
205
205
|
props: d,
|
|
206
206
|
stateAttributesMapping: oe
|
|
207
|
-
}) :
|
|
207
|
+
}) : H, /* @__PURE__ */ p("input", {
|
|
208
208
|
...Z
|
|
209
209
|
})]
|
|
210
210
|
});
|
|
@@ -217,12 +217,12 @@ const _e = /* @__PURE__ */ o.forwardRef(function(n, u) {
|
|
|
217
217
|
keepMounted: m = !1,
|
|
218
218
|
...r
|
|
219
219
|
} = n, a = Ae(), s = a.checked, {
|
|
220
|
-
transitionStatus:
|
|
220
|
+
transitionStatus: g,
|
|
221
221
|
setMounted: b
|
|
222
222
|
} = Ke(s), _ = o.useMemo(() => ({
|
|
223
223
|
...a,
|
|
224
|
-
transitionStatus:
|
|
225
|
-
}), [a,
|
|
224
|
+
transitionStatus: g
|
|
225
|
+
}), [a, g]), E = o.useRef(null), N = m || s, V = re("span", n, {
|
|
226
226
|
enabled: N,
|
|
227
227
|
ref: [u, E],
|
|
228
228
|
state: _,
|
|
@@ -246,7 +246,7 @@ const Qe = [Ie], ve = /* @__PURE__ */ o.forwardRef(function(n, u) {
|
|
|
246
246
|
readOnly: r,
|
|
247
247
|
required: a,
|
|
248
248
|
onValueChange: s,
|
|
249
|
-
value:
|
|
249
|
+
value: g,
|
|
250
250
|
defaultValue: b,
|
|
251
251
|
name: _,
|
|
252
252
|
inputRef: E,
|
|
@@ -255,8 +255,8 @@ const Qe = [Ie], ve = /* @__PURE__ */ o.forwardRef(function(n, u) {
|
|
|
255
255
|
} = n, {
|
|
256
256
|
setTouched: q,
|
|
257
257
|
setFocused: T,
|
|
258
|
-
shouldValidateOnChange:
|
|
259
|
-
validationMode:
|
|
258
|
+
shouldValidateOnChange: w,
|
|
259
|
+
validationMode: z,
|
|
260
260
|
name: J,
|
|
261
261
|
disabled: W,
|
|
262
262
|
state: P,
|
|
@@ -268,14 +268,14 @@ const Qe = [Ie], ve = /* @__PURE__ */ o.forwardRef(function(n, u) {
|
|
|
268
268
|
labelId: K
|
|
269
269
|
} = Re(), {
|
|
270
270
|
clearErrors: $
|
|
271
|
-
} = Fe(), A = We(!0),
|
|
272
|
-
controlled:
|
|
271
|
+
} = Fe(), A = We(!0), y = W || m, v = J ?? _, i = me(N), [t, x] = Ve({
|
|
272
|
+
controlled: g,
|
|
273
273
|
default: b,
|
|
274
274
|
name: "RadioGroup",
|
|
275
275
|
state: "value"
|
|
276
|
-
}), c =
|
|
277
|
-
c(d,
|
|
278
|
-
}), C = o.useRef(null),
|
|
276
|
+
}), c = S(s), k = S((d, H) => {
|
|
277
|
+
c(d, H), !H.isCanceled && x(d);
|
|
278
|
+
}), C = o.useRef(null), G = S((d) => {
|
|
279
279
|
C.current == null && d != null && (C.current = d);
|
|
280
280
|
});
|
|
281
281
|
Te({
|
|
@@ -285,19 +285,19 @@ const Qe = [Ie], ve = /* @__PURE__ */ o.forwardRef(function(n, u) {
|
|
|
285
285
|
controlRef: C,
|
|
286
286
|
name: v,
|
|
287
287
|
getValue: () => t ?? null
|
|
288
|
-
}),
|
|
289
|
-
$(v), D(t !== I.initialValue), B(t != null),
|
|
288
|
+
}), we(t, () => {
|
|
289
|
+
$(v), D(t !== I.initialValue), B(t != null), w() ? l.commit(t) : l.commit(t, !0);
|
|
290
290
|
});
|
|
291
|
-
const [L, O] = o.useState(!1), Q =
|
|
292
|
-
|
|
293
|
-
}), X =
|
|
291
|
+
const [L, O] = o.useState(!1), Q = S((d) => {
|
|
292
|
+
Ge(d.currentTarget, d.relatedTarget) || (q(!0), T(!1), z === "onBlur" && l.commit(t));
|
|
293
|
+
}), X = S((d) => {
|
|
294
294
|
d.key.startsWith("Arrow") && (q(!0), O(!0), T(!0));
|
|
295
295
|
}), U = o.useMemo(() => t == null ? "" : typeof t == "string" ? t : JSON.stringify(t), [t]), Z = fe(l.inputRef, E), M = Pe({
|
|
296
296
|
value: U,
|
|
297
297
|
ref: Z,
|
|
298
298
|
id: i,
|
|
299
299
|
name: U ? v : void 0,
|
|
300
|
-
disabled:
|
|
300
|
+
disabled: y,
|
|
301
301
|
readOnly: r,
|
|
302
302
|
required: a,
|
|
303
303
|
"aria-labelledby": V["aria-labelledby"] ?? A?.legendId,
|
|
@@ -311,26 +311,26 @@ const Qe = [Ie], ve = /* @__PURE__ */ o.forwardRef(function(n, u) {
|
|
|
311
311
|
}
|
|
312
312
|
}, l.getInputValidationProps), ee = o.useMemo(() => ({
|
|
313
313
|
...P,
|
|
314
|
-
disabled:
|
|
314
|
+
disabled: y ?? !1,
|
|
315
315
|
required: a ?? !1,
|
|
316
316
|
readOnly: r ?? !1
|
|
317
|
-
}), [P,
|
|
317
|
+
}), [P, y, r, a]), Y = o.useMemo(() => ({
|
|
318
318
|
...P,
|
|
319
319
|
checkedValue: t,
|
|
320
|
-
disabled:
|
|
320
|
+
disabled: y,
|
|
321
321
|
validation: l,
|
|
322
322
|
name: v,
|
|
323
323
|
onValueChange: c,
|
|
324
324
|
readOnly: r,
|
|
325
|
-
registerControlRef:
|
|
325
|
+
registerControlRef: G,
|
|
326
326
|
required: a,
|
|
327
327
|
setCheckedValue: k,
|
|
328
328
|
setTouched: O,
|
|
329
329
|
touched: L
|
|
330
|
-
}), [t,
|
|
330
|
+
}), [t, y, l, P, v, c, r, G, a, k, O, L]), j = {
|
|
331
331
|
role: "radiogroup",
|
|
332
332
|
"aria-required": a || void 0,
|
|
333
|
-
"aria-disabled":
|
|
333
|
+
"aria-disabled": y || void 0,
|
|
334
334
|
"aria-readonly": r || void 0,
|
|
335
335
|
"aria-labelledby": K,
|
|
336
336
|
onFocus() {
|
|
@@ -357,8 +357,8 @@ const Qe = [Ie], ve = /* @__PURE__ */ o.forwardRef(function(n, u) {
|
|
|
357
357
|
});
|
|
358
358
|
process.env.NODE_ENV !== "production" && (ve.displayName = "RadioGroup");
|
|
359
359
|
const Xe = {
|
|
360
|
-
"radio-group": "_radio-
|
|
361
|
-
}, Ze = "
|
|
360
|
+
"radio-group": "_radio-group_k4tg5_2"
|
|
361
|
+
}, Ze = "_radio_2wsa2_2", et = "_radio__indicator_2wsa2_9", tt = "_radio__label_2wsa2_32", te = {
|
|
362
362
|
radio: Ze,
|
|
363
363
|
radio__indicator: et,
|
|
364
364
|
radio__label: tt
|
|
@@ -383,7 +383,7 @@ function nt({
|
|
|
383
383
|
...h
|
|
384
384
|
}) {
|
|
385
385
|
const R = Ne(xe), m = e || R || "primary", r = /* @__PURE__ */ p(
|
|
386
|
-
|
|
386
|
+
Se,
|
|
387
387
|
{
|
|
388
388
|
render: /* @__PURE__ */ p(be, { ...h }),
|
|
389
389
|
interactive: "fill-outline",
|
|
@@ -7,13 +7,13 @@ import { Icon as m } from "../icon/icon.js";
|
|
|
7
7
|
import { Spinner as t } from "../spinner/spinner.js";
|
|
8
8
|
import { IconButton as h } from "../icon-button/icon-button.js";
|
|
9
9
|
import '../../search-bar.css';const a = {
|
|
10
|
-
"search-bar": "_search-
|
|
11
|
-
"search-bar__input": "_search-
|
|
12
|
-
"search-bar__icon": "_search-
|
|
13
|
-
"search-bar__icon_close": "_search-
|
|
10
|
+
"search-bar": "_search-bar_lia0r_2",
|
|
11
|
+
"search-bar__input": "_search-bar__input_lia0r_7",
|
|
12
|
+
"search-bar__icon": "_search-bar__icon_lia0r_15",
|
|
13
|
+
"search-bar__icon_close": "_search-bar__icon_close_lia0r_27"
|
|
14
14
|
};
|
|
15
|
-
function
|
|
16
|
-
return /* @__PURE__ */ n(s, { className: _(a["search-bar"],
|
|
15
|
+
function j({ loading: e, onClear: i, className: l, ...c }) {
|
|
16
|
+
return /* @__PURE__ */ n(s, { className: _(a["search-bar"], l), children: [
|
|
17
17
|
/* @__PURE__ */ r(o, { className: a["search-bar__input"], ...c }),
|
|
18
18
|
!e && !c.value ? /* @__PURE__ */ r(s, { className: a["search-bar__icon"], children: /* @__PURE__ */ r(m, { name: "search-line" }) }) : null,
|
|
19
19
|
e ? /* @__PURE__ */ r(t, { className: a["search-bar__icon"] }) : null,
|
|
@@ -31,7 +31,7 @@ function I({ loading: e, onClear: l, className: i, ...c }) {
|
|
|
31
31
|
alt: "Clear",
|
|
32
32
|
size: "sm",
|
|
33
33
|
disabled: c.disabled,
|
|
34
|
-
onClick:
|
|
34
|
+
onClick: i
|
|
35
35
|
}
|
|
36
36
|
)
|
|
37
37
|
}
|
|
@@ -39,5 +39,5 @@ function I({ loading: e, onClear: l, className: i, ...c }) {
|
|
|
39
39
|
] });
|
|
40
40
|
}
|
|
41
41
|
export {
|
|
42
|
-
|
|
42
|
+
j as SearchBar
|
|
43
43
|
};
|