@tpc-mare/mare-ui-components-react 0.1.24 → 0.1.25
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/index.js +1 -1
- package/dist/banner/index.js +1 -1
- package/dist/button/index.js +1 -1
- package/dist/combobox/index.js +1 -1
- package/dist/confirm-dialog/index.js +1 -1
- package/dist/counter/index.js +1 -1
- package/dist/dialog/index.js +1 -1
- package/dist/drawer/index.js +1 -1
- package/dist/expandable-counter/index.js +1 -1
- package/dist/filter-chip-dropdown-single/index.js +1 -1
- package/dist/floating-action-button/index.js +1 -1
- package/dist/index/index.js +19 -19
- package/dist/message/index.js +1 -1
- package/dist/multi-select/index.js +1 -1
- package/dist/overlay-badge/index.js +1 -1
- package/dist/paginator/index.js +1 -1
- package/dist/segmented-control/index.js +1 -1
- package/dist/select-field/index.js +1 -1
- package/dist/shared/{Accordion-BLQ1mWZZ.js → Accordion-BSmOrxH6.js} +4 -4
- package/dist/shared/{Banner-B_4xUzqu.js → Banner-C4wLe6N0.js} +2 -2
- package/dist/shared/{Button-BDnOdO_d.js → Button-DwJ5RTfQ.js} +2 -5
- package/dist/shared/{Combobox-SkrEe5He.js → Combobox-CcmWgRYZ.js} +1 -0
- package/dist/shared/{ConfirmDialog-DBX-JpDu.js → ConfirmDialog-DLHY-c70.js} +1 -1
- package/dist/shared/{Counter-DRUUEj_u.js → Counter-DjIoe4h3.js} +1 -1
- package/dist/shared/{DialogHeader-DhmbjN0J.js → DialogHeader-M5Bfyxos.js} +1 -1
- package/dist/shared/{DrawerFooter-DoOWN-f3.js → DrawerFooter-B9-Vrgd3.js} +1 -1
- package/dist/shared/{ExpandableCounter-DkmezZIB.js → ExpandableCounter-DZxbdqRa.js} +2 -2
- package/dist/shared/FilterChipDropdownSingle-C7ahD-_3.js +138 -0
- package/dist/shared/{FloatingActionButton-DPWP3O5C.js → FloatingActionButton-D4FK6uSs.js} +1 -1
- package/dist/shared/{Message-D7kmscvR.js → Message-BNsFuQU1.js} +1 -1
- package/dist/shared/{MultiSelect-DtsCymNB.js → MultiSelect-Dowp0_FX.js} +57 -55
- package/dist/shared/OverlayBadge-DLskqll7.js +70 -0
- package/dist/shared/{Paginator-Bxe9nv_5.js → Paginator-DxZdCXSC.js} +2 -2
- package/dist/shared/SegmentedControl-Ct5ZLXpN.js +100 -0
- package/dist/shared/{SelectField-CvKaukCG.js → SelectField-B-g52vHx.js} +5 -5
- package/dist/shared/{Snackbar-CfFmZUci.js → Snackbar-CjTqCOaV.js} +1 -1
- package/dist/shared/{Switch-D6E2OmgE.js → Switch-DNCn0xjb.js} +3 -3
- package/dist/snackbar/index.js +1 -1
- package/dist/styles.css +1 -1
- package/dist/switch/index.js +1 -1
- package/package.json +1 -1
- package/dist/shared/FilterChipDropdownSingle-4G5LDRCw.js +0 -135
- package/dist/shared/OverlayBadge-jHzuklUb.js +0 -60
- package/dist/shared/SegmentedControl-BpH7DANc.js +0 -94
package/dist/accordion/index.js
CHANGED
package/dist/banner/index.js
CHANGED
package/dist/button/index.js
CHANGED
package/dist/combobox/index.js
CHANGED
package/dist/counter/index.js
CHANGED
package/dist/dialog/index.js
CHANGED
package/dist/drawer/index.js
CHANGED
package/dist/index/index.js
CHANGED
|
@@ -1,21 +1,21 @@
|
|
|
1
|
-
import { A as e } from "../shared/Accordion-
|
|
1
|
+
import { A as e } from "../shared/Accordion-BSmOrxH6.js";
|
|
2
2
|
import { A as t } from "../shared/Avatar-D3QlO3Tz.js";
|
|
3
3
|
import { B as p } from "../shared/Badge-WC6my4Aw.js";
|
|
4
|
-
import { O as x } from "../shared/OverlayBadge-
|
|
4
|
+
import { O as x } from "../shared/OverlayBadge-DLskqll7.js";
|
|
5
5
|
import { T as i } from "../shared/Tag-BtbmgIwL.js";
|
|
6
6
|
import { T as l } from "../shared/TagChip-Bs7srjIL.js";
|
|
7
7
|
import { F as d } from "../shared/FilterChip-eECL3oO7.js";
|
|
8
8
|
import { F as C } from "../shared/FilterChipGroup-BzE-EQsA.js";
|
|
9
|
-
import { F as c } from "../shared/FilterChipDropdownSingle-
|
|
9
|
+
import { F as c } from "../shared/FilterChipDropdownSingle-C7ahD-_3.js";
|
|
10
10
|
import { F as D } from "../shared/FilterChipDropdownMultiple-D2eMYXyS.js";
|
|
11
|
-
import { B as P } from "../shared/Banner-
|
|
12
|
-
import { M as B } from "../shared/Message-
|
|
13
|
-
import { B as h } from "../shared/Button-
|
|
14
|
-
import { F as M } from "../shared/FloatingActionButton-
|
|
11
|
+
import { B as P } from "../shared/Banner-C4wLe6N0.js";
|
|
12
|
+
import { M as B } from "../shared/Message-BNsFuQU1.js";
|
|
13
|
+
import { B as h } from "../shared/Button-DwJ5RTfQ.js";
|
|
14
|
+
import { F as M } from "../shared/FloatingActionButton-D4FK6uSs.js";
|
|
15
15
|
import { B as A } from "../shared/Breadcrumbs-Cqr3Jitd.js";
|
|
16
|
-
import { S as v } from "../shared/SelectField-
|
|
17
|
-
import { C as E } from "../shared/Combobox-
|
|
18
|
-
import { M as R } from "../shared/MultiSelect-
|
|
16
|
+
import { S as v } from "../shared/SelectField-B-g52vHx.js";
|
|
17
|
+
import { C as E } from "../shared/Combobox-CcmWgRYZ.js";
|
|
18
|
+
import { M as R } from "../shared/MultiSelect-Dowp0_FX.js";
|
|
19
19
|
import { T as L } from "../shared/Tabs-BqIorZYD.js";
|
|
20
20
|
import { P as j } from "../shared/ProgressSpinner-B-lrS-tu.js";
|
|
21
21
|
import { P as z } from "../shared/ProgressBar-Dxm0L3-R.js";
|
|
@@ -26,24 +26,24 @@ import { S as rr } from "../shared/SearchField-DjJHDaR4.js";
|
|
|
26
26
|
import { P as er, a as ar } from "../shared/Password-BMKy8dAy.js";
|
|
27
27
|
import { I as sr } from "../shared/InputNumber-D48wsE-o.js";
|
|
28
28
|
import { I as mr } from "../shared/InputOtp-CUXXVP2E.js";
|
|
29
|
-
import { C as fr } from "../shared/Counter-
|
|
30
|
-
import { E as nr } from "../shared/ExpandableCounter-
|
|
29
|
+
import { C as fr } from "../shared/Counter-DjIoe4h3.js";
|
|
30
|
+
import { E as nr } from "../shared/ExpandableCounter-DZxbdqRa.js";
|
|
31
31
|
import { C as Sr } from "../shared/Checkbox-BXnSN2vK.js";
|
|
32
32
|
import { R as Fr } from "../shared/RadioGroup-lw27DCoV.js";
|
|
33
|
-
import { S as gr } from "../shared/Switch-
|
|
33
|
+
import { S as gr } from "../shared/Switch-DNCn0xjb.js";
|
|
34
34
|
import { D as ur, a as Dr } from "../shared/DialogFooter-DyltZzK-.js";
|
|
35
|
-
import { D as Pr } from "../shared/DialogHeader-
|
|
36
|
-
import { C as Br } from "../shared/ConfirmDialog-
|
|
37
|
-
import { D as hr, a as wr, b as Mr } from "../shared/DrawerFooter-
|
|
35
|
+
import { D as Pr } from "../shared/DialogHeader-M5Bfyxos.js";
|
|
36
|
+
import { C as Br } from "../shared/ConfirmDialog-DLHY-c70.js";
|
|
37
|
+
import { D as hr, a as wr, b as Mr } from "../shared/DrawerFooter-B9-Vrgd3.js";
|
|
38
38
|
import { M as Ar } from "../shared/Menu-Cv9dU1iA.js";
|
|
39
39
|
import { P as vr } from "../shared/PanelMenu-BpjNM7O_.js";
|
|
40
|
-
import { S as Er, c as Gr } from "../shared/Snackbar-
|
|
40
|
+
import { S as Er, c as Gr } from "../shared/Snackbar-CjTqCOaV.js";
|
|
41
41
|
import { S as yr } from "../shared/Stepper-By8M5bs0.js";
|
|
42
42
|
import { D as Nr } from "../shared/DatePicker-CwAISvNc.js";
|
|
43
|
-
import { P as qr } from "../shared/Paginator-
|
|
43
|
+
import { P as qr } from "../shared/Paginator-DxZdCXSC.js";
|
|
44
44
|
import { I as Jr } from "../shared/ImageItem-BBy5fOl3.js";
|
|
45
45
|
import { I as Qr } from "../shared/ImageSlider-Bgb1kNQ4.js";
|
|
46
|
-
import { S as Vr } from "../shared/SegmentedControl-
|
|
46
|
+
import { S as Vr } from "../shared/SegmentedControl-Ct5ZLXpN.js";
|
|
47
47
|
import { S as Xr } from "../shared/Skeleton-CAjoF-T2.js";
|
|
48
48
|
import { S as Zr } from "../shared/Slider-CXFkperZ.js";
|
|
49
49
|
import { D as $r } from "../shared/Divider-UgKI7dtK.js";
|
package/dist/message/index.js
CHANGED
package/dist/paginator/index.js
CHANGED
|
@@ -14,11 +14,11 @@ const d = "mare:w-full", u = (t) => `
|
|
|
14
14
|
`, p = "mare:flex mare:flex-col mare:items-start mare:gap-0.5 mare:text-left", b = "mare:tpc-typography-body-s mare:text-weak", h = `
|
|
15
15
|
mare:flex mare:items-center mare:justify-center mare:shrink-0 mare:text-default
|
|
16
16
|
mare:transition-transform mare:ark-open:rotate-180 mare:[&>svg]:size-5
|
|
17
|
-
`,
|
|
18
|
-
mare:overflow-hidden
|
|
17
|
+
`, v = `
|
|
18
|
+
mare:overflow-hidden
|
|
19
19
|
mare:ark-open:[animation:mare-panel-menu-branch-open_250ms_ease-out]
|
|
20
20
|
mare:ark-closed:[animation:mare-panel-menu-branch-close_200ms_ease-in]
|
|
21
|
-
|
|
21
|
+
`, x = "mare:pb-4";
|
|
22
22
|
function w({
|
|
23
23
|
items: t,
|
|
24
24
|
value: n,
|
|
@@ -50,7 +50,7 @@ function w({
|
|
|
50
50
|
] }),
|
|
51
51
|
/* @__PURE__ */ a(r.ItemIndicator, { className: h, children: /* @__PURE__ */ a(c, {}) })
|
|
52
52
|
] }),
|
|
53
|
-
/* @__PURE__ */ a(r.ItemContent, { className: x, children: e.content })
|
|
53
|
+
/* @__PURE__ */ a(r.ItemContent, { className: v, children: /* @__PURE__ */ a("div", { className: x, children: e.content }) })
|
|
54
54
|
]
|
|
55
55
|
},
|
|
56
56
|
e.value
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { jsxs as t, jsx as a } from "react/jsx-runtime";
|
|
2
|
-
import { B as d } from "./Button-
|
|
2
|
+
import { B as d } from "./Button-DwJ5RTfQ.js";
|
|
3
3
|
import { I as o } from "./IconX-CpPADKjZ.js";
|
|
4
4
|
const c = `
|
|
5
5
|
mare:w-full mare:max-w-md mare:rounded-tpc-container-s mare:p-4
|
|
@@ -9,7 +9,7 @@ const c = `
|
|
|
9
9
|
mare:data-severity-positive:bg-positive-weak
|
|
10
10
|
mare:data-severity-warning:bg-warning-weak
|
|
11
11
|
mare:data-severity-danger:bg-danger-weak
|
|
12
|
-
`, p = "mare:flex mare:grow mare:items-start mare:gap-4", g = "mare:shrink-0 mare:text-default mare:[&>svg]:size-
|
|
12
|
+
`, p = "mare:flex mare:grow mare:items-start mare:gap-4", g = "mare:flex mare:shrink-0 mare:items-center mare:justify-center mare:text-default mare:[&>svg]:size-6", f = "mare:flex mare:grow mare:flex-col mare:gap-2", v = "mare:tpc-typography-label-m mare:text-default", y = (e) => `mare:tpc-typography-body-s ${e ? "mare:text-disabled" : "mare:text-default"}`, x = (e, r) => r ? "disabled" : e;
|
|
13
13
|
function h({
|
|
14
14
|
severity: e = "neutral",
|
|
15
15
|
title: r,
|
|
@@ -9,10 +9,8 @@ const w = {
|
|
|
9
9
|
primary: "mare:stroke-on-accent",
|
|
10
10
|
secondary: "mare:stroke-default",
|
|
11
11
|
ghost: "mare:stroke-default",
|
|
12
|
-
danger: "mare:stroke-on-danger"
|
|
13
|
-
|
|
14
|
-
}, _ = (e) => e === "bordered" ? `mare:data-severity-neutral:border mare:data-severity-neutral:border-strong
|
|
15
|
-
mare:data-severity-ghost:border mare:data-severity-ghost:border-strong mare:not-p-disabled:data-severity-ghost:hover:bg-transparent` : `
|
|
12
|
+
danger: "mare:stroke-on-danger"
|
|
13
|
+
}, _ = (e) => e === "bordered" ? "mare:data-severity-ghost:border mare:data-severity-ghost:border-strong mare:not-p-disabled:data-severity-ghost:hover:bg-transparent" : `
|
|
16
14
|
mare:not-p-disabled:not-data-link:[&[data-severity~='ghost']:active]:bg-active
|
|
17
15
|
mare:not-p-disabled:not-data-link:[&[data-severity~='danger']:active]:bg-danger-active`, L = (e, a) => `
|
|
18
16
|
mare:group/button
|
|
@@ -39,7 +37,6 @@ const w = {
|
|
|
39
37
|
mare:not-p-disabled:not-data-link:[&[data-severity~='secondary']:active]:bg-active
|
|
40
38
|
mare:not-p-disabled:not-data-link:[&[data-severity~='danger']:active]:bg-danger-active
|
|
41
39
|
|
|
42
|
-
mare:data-severity-neutral:bg-default mare:data-severity-neutral:text-default
|
|
43
40
|
${_(e)}
|
|
44
41
|
mare:data-size-small:py-2.5 mare:data-size-small:px-3.5 mare:data-size-small:gap-1
|
|
45
42
|
mare:data-size-small:icon-only:rounded:p-2.5 mare:data-size-small:h-10 mare:data-size-small:icon-only:w-10 mare:data-size-small:icon-only:min-w-10
|
|
@@ -35,6 +35,7 @@ const G = {
|
|
|
35
35
|
mare:max-h-72 mare:overflow-y-auto
|
|
36
36
|
mare:min-w-[var(--reference-width)]
|
|
37
37
|
mare:z-50
|
|
38
|
+
mare:[&[hidden]]:hidden
|
|
38
39
|
`, ee = `
|
|
39
40
|
mare:group/option mare:flex mare:items-center mare:justify-between mare:gap-2
|
|
40
41
|
mare:w-full mare:min-h-8 mare:py-2 mare:px-3 mare:cursor-pointer mare:rounded-menu-item
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { jsx as r, jsxs as t } from "react/jsx-runtime";
|
|
2
2
|
import { D as g, a as h } from "./DialogFooter-DyltZzK-.js";
|
|
3
|
-
import { B as n } from "./Button-
|
|
3
|
+
import { B as n } from "./Button-DwJ5RTfQ.js";
|
|
4
4
|
const u = (e) => `
|
|
5
5
|
mare:w-full mare:h-full
|
|
6
6
|
${e === "column" ? "mare:pt-10 mare:pb-4" : "mare:pt-8"}
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { jsxs as h, jsx as r } from "react/jsx-runtime";
|
|
2
2
|
import { NumberInput as a } from "@ark-ui/react/number-input";
|
|
3
|
-
import { B as i } from "./Button-
|
|
3
|
+
import { B as i } from "./Button-DwJ5RTfQ.js";
|
|
4
4
|
import { I as x } from "./IconMinus-fS_GL0Et.js";
|
|
5
5
|
import { c as I } from "./createReactComponent-Cb6Pzf10.js";
|
|
6
6
|
const v = [["path", { d: "M12 5l0 14", key: "svg-0" }], ["path", { d: "M5 12l14 0", key: "svg-1" }]], C = I("outline", "plus", "Plus", v), N = {
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { jsxs as t, jsx as s } from "react/jsx-runtime";
|
|
2
2
|
import { Dialog as l } from "@ark-ui/react/dialog";
|
|
3
3
|
import { l as h, i as o, n as d, s as u } from "./DialogFooter-DyltZzK-.js";
|
|
4
|
-
import { B as r } from "./Button-
|
|
4
|
+
import { B as r } from "./Button-DwJ5RTfQ.js";
|
|
5
5
|
import { I as p } from "./IconX-CpPADKjZ.js";
|
|
6
6
|
function y({
|
|
7
7
|
title: e,
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { jsx as r, jsxs as i } from "react/jsx-runtime";
|
|
2
2
|
import { Dialog as t } from "@ark-ui/react/dialog";
|
|
3
3
|
import { Portal as g } from "@ark-ui/react/portal";
|
|
4
|
-
import { B as d } from "./Button-
|
|
4
|
+
import { B as d } from "./Button-DwJ5RTfQ.js";
|
|
5
5
|
import { I as y } from "./IconX-CpPADKjZ.js";
|
|
6
6
|
const _ = (e) => {
|
|
7
7
|
switch (e) {
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { jsx as r } from "react/jsx-runtime";
|
|
2
|
-
import { B as p } from "./Button-
|
|
3
|
-
import { C as x, I as d } from "./Counter-
|
|
2
|
+
import { B as p } from "./Button-DwJ5RTfQ.js";
|
|
3
|
+
import { C as x, I as d } from "./Counter-DjIoe4h3.js";
|
|
4
4
|
const m = `
|
|
5
5
|
mare:inline-flex mare:origin-left mare:[animation:mare-expandable-counter-enter_100ms_ease-out]
|
|
6
6
|
`, C = (e, a) => e > a;
|
|
@@ -0,0 +1,138 @@
|
|
|
1
|
+
import { jsxs as r, jsx as a } from "react/jsx-runtime";
|
|
2
|
+
import { useState as k, useMemo as u } from "react";
|
|
3
|
+
import { createListCollection as y, SelectRoot as S, SelectControl as I, SelectTrigger as N, SelectValueText as C, SelectClearTrigger as z, SelectIndicator as T, SelectPositioner as D, SelectContent as _, SelectItem as j, SelectItemText as L, SelectItemIndicator as V } from "@ark-ui/react/select";
|
|
4
|
+
import { I as $ } from "./IconX-CpPADKjZ.js";
|
|
5
|
+
import { I as q } from "./IconChevronDown-ev2ML7Ex.js";
|
|
6
|
+
import { I as E } from "./IconSearch-CgM6jEUh.js";
|
|
7
|
+
import { I as F } from "./IconCheck-DzZA6b2U.js";
|
|
8
|
+
const P = {
|
|
9
|
+
medium: "mare:h-10",
|
|
10
|
+
large: "mare:h-12"
|
|
11
|
+
}, B = {
|
|
12
|
+
medium: "mare:pl-3.5",
|
|
13
|
+
large: "mare:pl-4"
|
|
14
|
+
}, K = () => "mare:relative mare:inline-flex mare:items-center mare:max-w-full", M = (t, o) => `
|
|
15
|
+
mare:w-full mare:flex mare:items-center mare:cursor-pointer mare:select-none mare:text-left mare:min-w-0
|
|
16
|
+
mare:rounded-full mare:border
|
|
17
|
+
mare:tpc-typography-body-s mare:transition-colors mare:duration-150
|
|
18
|
+
${P[t]}
|
|
19
|
+
${B[t]} ${o ? "mare:pr-14" : "mare:pr-8"}
|
|
20
|
+
mare:bg-default mare:text-default mare:border-default
|
|
21
|
+
mare:focus-visible:outline-solid mare:focus-visible:outline-2 mare:focus-visible:outline-accent mare:focus-visible:-outline-offset-2
|
|
22
|
+
mare:not-ark-disabled:hover:bg-hover
|
|
23
|
+
mare:ark-disabled:cursor-not-allowed mare:ark-disabled:text-disabled mare:ark-disabled:border-disabled-default
|
|
24
|
+
mare:data-[invalid]:outline-solid mare:data-[invalid]:outline-2 mare:data-[invalid]:outline-danger mare:data-[invalid]:-outline-offset-2
|
|
25
|
+
`, Q = "mare:truncate mare:data-[placeholder-shown]:text-weak", R = "mare:absolute mare:right-3.5 mare:top-1/2 mare:-translate-y-1/2 mare:flex mare:items-center mare:gap-1.5 mare:pointer-events-none", X = "mare:pointer-events-auto mare:flex mare:items-center mare:shrink-0 mare:text-base mare:cursor-pointer mare:hover:text-weak", A = "mare:flex mare:items-center mare:shrink-0 mare:[&>svg]:size-4 mare:transition-transform mare:ark-open:rotate-180", G = `
|
|
26
|
+
mare:flex mare:flex-col mare:gap-0.5 mare:p-1
|
|
27
|
+
mare:rounded-input mare:border mare:border-default mare:bg-raised
|
|
28
|
+
mare:shadow-[0_2px_6px_0_rgba(0,0,0,0.16)]
|
|
29
|
+
mare:max-h-72 mare:overflow-y-auto
|
|
30
|
+
mare:min-w-[var(--reference-width)]
|
|
31
|
+
mare:z-50
|
|
32
|
+
`, H = `
|
|
33
|
+
mare:flex mare:items-center mare:gap-2 mare:mb-1 mare:px-3 mare:h-10
|
|
34
|
+
mare:rounded-input mare:border mare:border-strong mare:bg-default
|
|
35
|
+
mare:focus-within:outline-solid mare:focus-within:outline-2 mare:focus-within:outline-accent mare:focus-within:-outline-offset-2
|
|
36
|
+
`, J = "mare:flex-auto mare:bg-transparent mare:outline-none mare:text-default mare:placeholder:text-weak mare:tpc-typography-body-s", O = "mare:flex mare:items-center mare:shrink-0 mare:text-weak", U = `
|
|
37
|
+
mare:group/option mare:flex mare:items-center mare:justify-between mare:gap-2
|
|
38
|
+
mare:w-full mare:min-h-8 mare:py-2 mare:px-3 mare:cursor-pointer mare:rounded-menu-item
|
|
39
|
+
mare:tpc-typography-body-s mare:text-default
|
|
40
|
+
mare:ark-highlighted:bg-hover
|
|
41
|
+
mare:ark-selected:bg-accent-weak mare:ark-selected:text-accent
|
|
42
|
+
mare:ark-disabled:text-disabled mare:ark-disabled:cursor-not-allowed
|
|
43
|
+
`, W = "mare:flex mare:items-center mare:text-accent", Y = "mare:py-2 mare:px-3 mare:tpc-typography-body-s mare:text-weak";
|
|
44
|
+
function oe({
|
|
45
|
+
value: t = null,
|
|
46
|
+
onValueChange: o,
|
|
47
|
+
options: m,
|
|
48
|
+
placeholder: f = "Select…",
|
|
49
|
+
size: p = "medium",
|
|
50
|
+
disabled: h = !1,
|
|
51
|
+
invalid: b = !1,
|
|
52
|
+
filter: i = !1,
|
|
53
|
+
clearable: s = !1,
|
|
54
|
+
renderOption: c,
|
|
55
|
+
checkIcon: x,
|
|
56
|
+
clearIcon: g
|
|
57
|
+
}) {
|
|
58
|
+
const [n, d] = k(""), l = u(() => {
|
|
59
|
+
if (!i) return m;
|
|
60
|
+
const e = n.trim().toLowerCase();
|
|
61
|
+
return e ? m.filter((v) => v.label.toLowerCase().includes(e)) : m;
|
|
62
|
+
}, [i, n, m]), w = u(
|
|
63
|
+
() => y({
|
|
64
|
+
items: l,
|
|
65
|
+
itemToValue: (e) => e.value,
|
|
66
|
+
itemToString: (e) => e.label,
|
|
67
|
+
isItemDisabled: (e) => !!e.disabled
|
|
68
|
+
}),
|
|
69
|
+
[l]
|
|
70
|
+
);
|
|
71
|
+
return /* @__PURE__ */ r(
|
|
72
|
+
S,
|
|
73
|
+
{
|
|
74
|
+
collection: w,
|
|
75
|
+
value: t == null ? [] : [t],
|
|
76
|
+
disabled: h,
|
|
77
|
+
invalid: b,
|
|
78
|
+
onValueChange: (e) => o?.(e.value[0] ?? null),
|
|
79
|
+
onOpenChange: (e) => {
|
|
80
|
+
e.open || d("");
|
|
81
|
+
},
|
|
82
|
+
children: [
|
|
83
|
+
/* @__PURE__ */ r(I, { className: K(), children: [
|
|
84
|
+
/* @__PURE__ */ a(N, { className: M(p, s), children: /* @__PURE__ */ a(
|
|
85
|
+
C,
|
|
86
|
+
{
|
|
87
|
+
className: Q,
|
|
88
|
+
placeholder: f
|
|
89
|
+
}
|
|
90
|
+
) }),
|
|
91
|
+
/* @__PURE__ */ r("div", { className: R, children: [
|
|
92
|
+
s && /* @__PURE__ */ a(z, { className: X, children: g ?? /* @__PURE__ */ a($, { size: "1em" }) }),
|
|
93
|
+
/* @__PURE__ */ a(T, { className: A, children: /* @__PURE__ */ a(q, { size: "1em" }) })
|
|
94
|
+
] })
|
|
95
|
+
] }),
|
|
96
|
+
/* @__PURE__ */ a(D, { children: /* @__PURE__ */ r(_, { className: G, children: [
|
|
97
|
+
i && /* @__PURE__ */ r("div", { className: H, children: [
|
|
98
|
+
/* @__PURE__ */ a(
|
|
99
|
+
"input",
|
|
100
|
+
{
|
|
101
|
+
className: J,
|
|
102
|
+
value: n,
|
|
103
|
+
onChange: (e) => d(e.target.value),
|
|
104
|
+
onKeyDown: (e) => {
|
|
105
|
+
e.key === "Enter" && e.preventDefault(), e.key !== "Escape" && e.stopPropagation();
|
|
106
|
+
},
|
|
107
|
+
placeholder: "Buscar…"
|
|
108
|
+
}
|
|
109
|
+
),
|
|
110
|
+
/* @__PURE__ */ a("span", { className: O, children: /* @__PURE__ */ a(E, { size: "1em" }) })
|
|
111
|
+
] }),
|
|
112
|
+
l.length === 0 && /* @__PURE__ */ a("div", { className: Y, children: "Sin resultados" }),
|
|
113
|
+
l.map((e) => /* @__PURE__ */ r(
|
|
114
|
+
j,
|
|
115
|
+
{
|
|
116
|
+
item: e,
|
|
117
|
+
className: U,
|
|
118
|
+
children: [
|
|
119
|
+
/* @__PURE__ */ a(L, { children: c ? c(e) : e.label }),
|
|
120
|
+
/* @__PURE__ */ a(
|
|
121
|
+
V,
|
|
122
|
+
{
|
|
123
|
+
className: W,
|
|
124
|
+
children: x ?? /* @__PURE__ */ a(F, { size: "1em" })
|
|
125
|
+
}
|
|
126
|
+
)
|
|
127
|
+
]
|
|
128
|
+
},
|
|
129
|
+
e.value
|
|
130
|
+
))
|
|
131
|
+
] }) })
|
|
132
|
+
]
|
|
133
|
+
}
|
|
134
|
+
);
|
|
135
|
+
}
|
|
136
|
+
export {
|
|
137
|
+
oe as F
|
|
138
|
+
};
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { jsxs as s, jsx as t } from "react/jsx-runtime";
|
|
2
|
-
import { B as o } from "./Button-
|
|
2
|
+
import { B as o } from "./Button-DwJ5RTfQ.js";
|
|
3
3
|
import { I as p } from "./IconX-CpPADKjZ.js";
|
|
4
4
|
const c = (e) => e === "filled" ? `mare:w-full mare:max-w-md mare:rounded-tpc-container-s mare:p-4
|
|
5
5
|
mare:flex mare:items-start mare:justify-between mare:gap-4
|