@solibo/solibo-ui 0.3.39 → 0.3.40
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/assets/index.css +1 -1
- package/dist/assets/index20.css +1 -1
- package/dist/assets/index22.css +1 -1
- package/dist/assets/index41.css +1 -1
- package/dist/components/_collapsible/index.cjs +1 -1
- package/dist/components/_collapsible/index.cjs.map +1 -1
- package/dist/components/_collapsible/index.js +19 -15
- package/dist/components/_collapsible/index.js.map +1 -1
- package/dist/components/_dropdown/index.cjs +1 -1
- package/dist/components/_dropdown/index.cjs.map +1 -1
- package/dist/components/_dropdown/index.js +149 -136
- package/dist/components/_dropdown/index.js.map +1 -1
- package/dist/components/checkbox/index.cjs +1 -1
- package/dist/components/checkbox/index.js +1 -1
- package/dist/components/icon/index.cjs +1 -1
- package/dist/components/icon/index.js +1 -1
- package/dist/components/input/index.cjs +1 -1
- package/dist/components/input/index.js +2 -2
- package/dist/components/nav/index.cjs +1 -1
- package/dist/components/nav/index.js +1 -1
- package/dist/components/select/index.cjs +1 -1
- package/dist/components/select/index.js +3 -2
- package/dist/components/select/index.js.map +1 -1
- package/dist/components/table/index.cjs +1 -1
- package/dist/components/table/index.cjs.map +1 -1
- package/dist/components/table/index.js +10 -10
- package/dist/components/table/index.js.map +1 -1
- package/dist/components/textarea/index.cjs +1 -1
- package/dist/components/textarea/index.js +1 -1
- package/dist/{icons-CMoejLkL.cjs → icons-C_cX1FYp.cjs} +2 -2
- package/dist/{icons-CMoejLkL.cjs.map → icons-C_cX1FYp.cjs.map} +1 -1
- package/dist/{icons-BqQRUUWn.js → icons-DfmpRbxE.js} +2 -2
- package/dist/{icons-BqQRUUWn.js.map → icons-DfmpRbxE.js.map} +1 -1
- package/dist/{index-xRmXVWAN.js → index-C_OgUYu-.js} +25 -18
- package/dist/index-C_OgUYu-.js.map +1 -0
- package/dist/index-CfK1ATlt.cjs +2 -0
- package/dist/index-CfK1ATlt.cjs.map +1 -0
- package/dist/index.cjs +1 -1
- package/dist/index.js +1 -1
- package/dist/utils-BFlnRYx7.js +34 -0
- package/dist/utils-BFlnRYx7.js.map +1 -0
- package/dist/utils-DqVa4K58.cjs +2 -0
- package/dist/utils-DqVa4K58.cjs.map +1 -0
- package/package.json +1 -1
- package/dist/index-HNd9cEc6.cjs +0 -2
- package/dist/index-HNd9cEc6.cjs.map +0 -1
- package/dist/index-xRmXVWAN.js.map +0 -1
- package/dist/utils-DXIJVVzz.js +0 -14
- package/dist/utils-DXIJVVzz.js.map +0 -1
- package/dist/utils-D_TJ8wDc.cjs +0 -2
- package/dist/utils-D_TJ8wDc.cjs.map +0 -1
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.cjs","sources":["../../../src/components/table/index.tsx"],"sourcesContent":["import { Children, cloneElement, isValidElement, useCallback, useRef } from 'react';\n\nimport { Icon } from '../icon';\nimport styles from './styles.module.css';\n\nexport type TableProps = React.TableHTMLAttributes<HTMLTableElement> & {\n children?: React.ReactNode;\n locale?: string | string[];\n};\n\ntype SortType = 'date' | 'number' | 'text';\n\ntype TableChildProps = {\n children?: React.ReactNode;\n colSpan?: number;\n 'data-span'?: string;\n 'data-type'?: SortType;\n};\n\nconst isTableElement = (child: React.ReactNode): child is React.ReactElement<TableChildProps> =>\n isValidElement<TableChildProps>(child);\n\nconst countCells = (children: React.ReactNode): number =>\n Children.toArray(children).reduce<number>((count, child) => {\n if (!isTableElement(child)) return count;\n return (\n count + (child.type === 'td' || child.type === 'th' ? 1 : countCells(child.props.children))\n );\n }, 0);\n\nconst getFirstRowCellCount = (children: React.ReactNode): number | null => {\n for (const child of Children.toArray(children)) {\n if (!isTableElement(child)) continue;\n\n if (child.type === 'tr') return countCells(child.props.children);\n\n const nestedCount = getFirstRowCellCount(child.props.children);\n if (nestedCount !== null) return nestedCount;\n }\n\n return null;\n};\n\nconst normalizeChildren = (children: React.ReactNode, columnCount: number): React.ReactNode =>\n Children.map(children, (child) => {\n if (!isTableElement(child)) return child;\n\n let nextChildren =\n child.props.children === undefined\n ? child.props.children\n : normalizeChildren(child.props.children, columnCount);\n let nextProps: Partial<TableChildProps> | undefined;\n\n if (child.type === 'td' && child.props['data-span'] === 'all') {\n nextProps = { colSpan: columnCount };\n }\n\n if (child.type === 'th' && child.props['data-type']) {\n nextChildren = (\n <span className={styles.sortable}>\n {nextChildren}\n <Icon\n aria-hidden='true'\n name='updown'\n
|
|
1
|
+
{"version":3,"file":"index.cjs","sources":["../../../src/components/table/index.tsx"],"sourcesContent":["import { Children, cloneElement, isValidElement, useCallback, useRef } from 'react';\n\nimport { Icon } from '../icon';\nimport styles from './styles.module.css';\n\nexport type TableProps = React.TableHTMLAttributes<HTMLTableElement> & {\n children?: React.ReactNode;\n locale?: string | string[];\n};\n\ntype SortType = 'date' | 'number' | 'text';\n\ntype TableChildProps = {\n children?: React.ReactNode;\n colSpan?: number;\n 'data-span'?: string;\n 'data-type'?: SortType;\n};\n\nconst isTableElement = (child: React.ReactNode): child is React.ReactElement<TableChildProps> =>\n isValidElement<TableChildProps>(child);\n\nconst countCells = (children: React.ReactNode): number =>\n Children.toArray(children).reduce<number>((count, child) => {\n if (!isTableElement(child)) return count;\n return (\n count + (child.type === 'td' || child.type === 'th' ? 1 : countCells(child.props.children))\n );\n }, 0);\n\nconst getFirstRowCellCount = (children: React.ReactNode): number | null => {\n for (const child of Children.toArray(children)) {\n if (!isTableElement(child)) continue;\n\n if (child.type === 'tr') return countCells(child.props.children);\n\n const nestedCount = getFirstRowCellCount(child.props.children);\n if (nestedCount !== null) return nestedCount;\n }\n\n return null;\n};\n\nconst normalizeChildren = (children: React.ReactNode, columnCount: number): React.ReactNode =>\n Children.map(children, (child) => {\n if (!isTableElement(child)) return child;\n\n let nextChildren =\n child.props.children === undefined\n ? child.props.children\n : normalizeChildren(child.props.children, columnCount);\n let nextProps: Partial<TableChildProps> | undefined;\n\n if (child.type === 'td' && child.props['data-span'] === 'all') {\n nextProps = { colSpan: columnCount };\n }\n\n if (child.type === 'th' && child.props['data-type']) {\n nextChildren = (\n <span className={styles.sortable}>\n {nextChildren}\n <Icon\n aria-hidden='true'\n name='updown'\n variant='primary'\n />\n </span>\n );\n }\n\n return nextProps || nextChildren !== child.props.children\n ? cloneElement(child, nextProps, nextChildren)\n : child;\n });\n\n/**\n * Sortable columns must provide data-type (text, number, or date) in the `th` element.\n */\n\nconst compare = (a: string, b: string, type: SortType, locale?: string | string[], dir = 1) => {\n if (type === 'text') {\n return a.localeCompare(b, locale, { sensitivity: 'base' }) * dir;\n }\n\n const left = type === 'date' ? Date.parse(a) : Number.parseFloat(a);\n const right = type === 'date' ? Date.parse(b) : Number.parseFloat(b);\n\n if (Number.isNaN(left) && Number.isNaN(right)) return 0;\n if (Number.isNaN(left)) return 1;\n if (Number.isNaN(right)) return -1;\n return (left - right) * dir;\n};\n\nexport const Table = ({ children, locale, ...props }: TableProps) => {\n const ref = useRef<HTMLTableElement | null>(null);\n const columnCount = getFirstRowCellCount(children);\n const normalizedChildren =\n columnCount && columnCount > 0 ? normalizeChildren(children, columnCount) : children;\n\n const setSortState = (\n thead: HTMLTableSectionElement,\n active: HTMLTableCellElement,\n dir: 'asc' | 'desc'\n ) => {\n const ths = thead.querySelectorAll<HTMLTableCellElement>('th[data-type]');\n\n ths.forEach((th) => {\n if (th === active) {\n th.dataset.dir = dir;\n th.setAttribute('aria-sort', dir === 'asc' ? 'ascending' : 'descending');\n } else {\n delete th.dataset.dir;\n th.setAttribute('aria-sort', 'none');\n }\n });\n };\n\n const onClick = useCallback(\n (e: React.MouseEvent<HTMLTableElement>) => {\n const table = ref.current;\n if (!table) return;\n\n const th = (e.target as HTMLElement | null)?.closest('th');\n if (!th) return;\n\n const thead = table.tHead;\n if (!thead || !thead.contains(th)) return;\n\n const col = th.cellIndex;\n if (col < 0) return;\n\n const tbody = table.tBodies?.[0];\n if (!tbody) return;\n\n const type = th.getAttribute('data-type') as SortType | null;\n if (!type) return;\n\n const direction = th.dataset.dir === 'asc' ? 'desc' : 'asc';\n setSortState(thead, th, direction);\n const dir = direction === 'asc' ? 1 : -1;\n\n const rows = Array.from(tbody.rows);\n\n rows.sort((a, b) => {\n const av = (a.cells[col]?.textContent ?? '').trim();\n const bv = (b.cells[col]?.textContent ?? '').trim();\n return compare(av, bv, type, locale, dir);\n });\n\n tbody.append(...rows);\n },\n [locale]\n );\n\n return (\n <table\n className={styles.table}\n onClick={onClick}\n ref={ref}\n {...props}\n >\n {normalizedChildren}\n </table>\n );\n};\n"],"names":["isTableElement","child","isValidElement","countCells","children","Children","toArray","reduce","count","type","props","getFirstRowCellCount","nestedCount","normalizeChildren","columnCount","map","nextChildren","undefined","nextProps","colSpan","jsxs","styles","sortable","Icon","cloneElement","compare","a","b","locale","dir","localeCompare","sensitivity","left","Date","parse","Number","parseFloat","right","isNaN","Table","ref","useRef","normalizedChildren","setSortState","thead","active","querySelectorAll","forEach","th","dataset","setAttribute","onClick","useCallback","e","table","current","target","closest","tHead","contains","col","cellIndex","tbody","tBodies","getAttribute","direction","rows","Array","from","sort","av","cells","textContent","trim","bv","append","jsx"],"mappings":"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"}
|
|
@@ -1,25 +1,25 @@
|
|
|
1
1
|
import { jsx as _, jsxs as I } from "react/jsx-runtime";
|
|
2
|
-
import { useRef as R, useCallback as T, Children as
|
|
2
|
+
import { useRef as R, useCallback as T, Children as f, cloneElement as q, isValidElement as B } from "react";
|
|
3
3
|
import { Icon as H } from "../icon/index.js";
|
|
4
4
|
import '../../assets/index3.css';const P = "_table_18uji_1", V = "_sortable_18uji_27", h = {
|
|
5
5
|
table: P,
|
|
6
6
|
sortable: V
|
|
7
|
-
},
|
|
8
|
-
for (const e of
|
|
9
|
-
if (!
|
|
7
|
+
}, m = (r) => B(r), v = (r) => f.toArray(r).reduce((e, t) => m(t) ? e + (t.type === "td" || t.type === "th" ? 1 : v(t.props.children)) : e, 0), j = (r) => {
|
|
8
|
+
for (const e of f.toArray(r)) {
|
|
9
|
+
if (!m(e)) continue;
|
|
10
10
|
if (e.type === "tr") return v(e.props.children);
|
|
11
11
|
const t = j(e.props.children);
|
|
12
12
|
if (t !== null) return t;
|
|
13
13
|
}
|
|
14
14
|
return null;
|
|
15
|
-
}, w = (r, e) =>
|
|
16
|
-
if (!
|
|
15
|
+
}, w = (r, e) => f.map(r, (t) => {
|
|
16
|
+
if (!m(t)) return t;
|
|
17
17
|
let s = t.props.children === void 0 ? t.props.children : w(t.props.children, e), n;
|
|
18
18
|
return t.type === "td" && t.props["data-span"] === "all" && (n = {
|
|
19
19
|
colSpan: e
|
|
20
20
|
}), t.type === "th" && t.props["data-type"] && (s = /* @__PURE__ */ I("span", { className: h.sortable, children: [
|
|
21
21
|
s,
|
|
22
|
-
/* @__PURE__ */ _(H, { "aria-hidden": "true", name: "updown",
|
|
22
|
+
/* @__PURE__ */ _(H, { "aria-hidden": "true", name: "updown", variant: "primary" })
|
|
23
23
|
] })), n || s !== t.props.children ? q(t, n, s) : t;
|
|
24
24
|
}), G = (r, e, t, s, n = 1) => {
|
|
25
25
|
if (t === "text")
|
|
@@ -54,10 +54,10 @@ import '../../assets/index3.css';const P = "_table_18uji_1", V = "_sortable_18uj
|
|
|
54
54
|
const N = o.dataset.dir === "asc" ? "desc" : "asc";
|
|
55
55
|
l(p, o, N);
|
|
56
56
|
const S = N === "asc" ? 1 : -1, y = Array.from(d.rows);
|
|
57
|
-
y.sort((
|
|
57
|
+
y.sort((F, k) => {
|
|
58
58
|
var A, g;
|
|
59
|
-
const
|
|
60
|
-
return G(
|
|
59
|
+
const z = (((A = F.cells[a]) == null ? void 0 : A.textContent) ?? "").trim(), D = (((g = k.cells[a]) == null ? void 0 : g.textContent) ?? "").trim();
|
|
60
|
+
return G(z, D, b, e, S);
|
|
61
61
|
}), d.append(...y);
|
|
62
62
|
}, [e]);
|
|
63
63
|
return /* @__PURE__ */ _("table", { className: h.table, onClick: E, ref: s, ...t, "data-component": "table", children: i });
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","sources":["../../../src/components/table/index.tsx"],"sourcesContent":["import { Children, cloneElement, isValidElement, useCallback, useRef } from 'react';\n\nimport { Icon } from '../icon';\nimport styles from './styles.module.css';\n\nexport type TableProps = React.TableHTMLAttributes<HTMLTableElement> & {\n children?: React.ReactNode;\n locale?: string | string[];\n};\n\ntype SortType = 'date' | 'number' | 'text';\n\ntype TableChildProps = {\n children?: React.ReactNode;\n colSpan?: number;\n 'data-span'?: string;\n 'data-type'?: SortType;\n};\n\nconst isTableElement = (child: React.ReactNode): child is React.ReactElement<TableChildProps> =>\n isValidElement<TableChildProps>(child);\n\nconst countCells = (children: React.ReactNode): number =>\n Children.toArray(children).reduce<number>((count, child) => {\n if (!isTableElement(child)) return count;\n return (\n count + (child.type === 'td' || child.type === 'th' ? 1 : countCells(child.props.children))\n );\n }, 0);\n\nconst getFirstRowCellCount = (children: React.ReactNode): number | null => {\n for (const child of Children.toArray(children)) {\n if (!isTableElement(child)) continue;\n\n if (child.type === 'tr') return countCells(child.props.children);\n\n const nestedCount = getFirstRowCellCount(child.props.children);\n if (nestedCount !== null) return nestedCount;\n }\n\n return null;\n};\n\nconst normalizeChildren = (children: React.ReactNode, columnCount: number): React.ReactNode =>\n Children.map(children, (child) => {\n if (!isTableElement(child)) return child;\n\n let nextChildren =\n child.props.children === undefined\n ? child.props.children\n : normalizeChildren(child.props.children, columnCount);\n let nextProps: Partial<TableChildProps> | undefined;\n\n if (child.type === 'td' && child.props['data-span'] === 'all') {\n nextProps = { colSpan: columnCount };\n }\n\n if (child.type === 'th' && child.props['data-type']) {\n nextChildren = (\n <span className={styles.sortable}>\n {nextChildren}\n <Icon\n aria-hidden='true'\n name='updown'\n
|
|
1
|
+
{"version":3,"file":"index.js","sources":["../../../src/components/table/index.tsx"],"sourcesContent":["import { Children, cloneElement, isValidElement, useCallback, useRef } from 'react';\n\nimport { Icon } from '../icon';\nimport styles from './styles.module.css';\n\nexport type TableProps = React.TableHTMLAttributes<HTMLTableElement> & {\n children?: React.ReactNode;\n locale?: string | string[];\n};\n\ntype SortType = 'date' | 'number' | 'text';\n\ntype TableChildProps = {\n children?: React.ReactNode;\n colSpan?: number;\n 'data-span'?: string;\n 'data-type'?: SortType;\n};\n\nconst isTableElement = (child: React.ReactNode): child is React.ReactElement<TableChildProps> =>\n isValidElement<TableChildProps>(child);\n\nconst countCells = (children: React.ReactNode): number =>\n Children.toArray(children).reduce<number>((count, child) => {\n if (!isTableElement(child)) return count;\n return (\n count + (child.type === 'td' || child.type === 'th' ? 1 : countCells(child.props.children))\n );\n }, 0);\n\nconst getFirstRowCellCount = (children: React.ReactNode): number | null => {\n for (const child of Children.toArray(children)) {\n if (!isTableElement(child)) continue;\n\n if (child.type === 'tr') return countCells(child.props.children);\n\n const nestedCount = getFirstRowCellCount(child.props.children);\n if (nestedCount !== null) return nestedCount;\n }\n\n return null;\n};\n\nconst normalizeChildren = (children: React.ReactNode, columnCount: number): React.ReactNode =>\n Children.map(children, (child) => {\n if (!isTableElement(child)) return child;\n\n let nextChildren =\n child.props.children === undefined\n ? child.props.children\n : normalizeChildren(child.props.children, columnCount);\n let nextProps: Partial<TableChildProps> | undefined;\n\n if (child.type === 'td' && child.props['data-span'] === 'all') {\n nextProps = { colSpan: columnCount };\n }\n\n if (child.type === 'th' && child.props['data-type']) {\n nextChildren = (\n <span className={styles.sortable}>\n {nextChildren}\n <Icon\n aria-hidden='true'\n name='updown'\n variant='primary'\n />\n </span>\n );\n }\n\n return nextProps || nextChildren !== child.props.children\n ? cloneElement(child, nextProps, nextChildren)\n : child;\n });\n\n/**\n * Sortable columns must provide data-type (text, number, or date) in the `th` element.\n */\n\nconst compare = (a: string, b: string, type: SortType, locale?: string | string[], dir = 1) => {\n if (type === 'text') {\n return a.localeCompare(b, locale, { sensitivity: 'base' }) * dir;\n }\n\n const left = type === 'date' ? Date.parse(a) : Number.parseFloat(a);\n const right = type === 'date' ? Date.parse(b) : Number.parseFloat(b);\n\n if (Number.isNaN(left) && Number.isNaN(right)) return 0;\n if (Number.isNaN(left)) return 1;\n if (Number.isNaN(right)) return -1;\n return (left - right) * dir;\n};\n\nexport const Table = ({ children, locale, ...props }: TableProps) => {\n const ref = useRef<HTMLTableElement | null>(null);\n const columnCount = getFirstRowCellCount(children);\n const normalizedChildren =\n columnCount && columnCount > 0 ? normalizeChildren(children, columnCount) : children;\n\n const setSortState = (\n thead: HTMLTableSectionElement,\n active: HTMLTableCellElement,\n dir: 'asc' | 'desc'\n ) => {\n const ths = thead.querySelectorAll<HTMLTableCellElement>('th[data-type]');\n\n ths.forEach((th) => {\n if (th === active) {\n th.dataset.dir = dir;\n th.setAttribute('aria-sort', dir === 'asc' ? 'ascending' : 'descending');\n } else {\n delete th.dataset.dir;\n th.setAttribute('aria-sort', 'none');\n }\n });\n };\n\n const onClick = useCallback(\n (e: React.MouseEvent<HTMLTableElement>) => {\n const table = ref.current;\n if (!table) return;\n\n const th = (e.target as HTMLElement | null)?.closest('th');\n if (!th) return;\n\n const thead = table.tHead;\n if (!thead || !thead.contains(th)) return;\n\n const col = th.cellIndex;\n if (col < 0) return;\n\n const tbody = table.tBodies?.[0];\n if (!tbody) return;\n\n const type = th.getAttribute('data-type') as SortType | null;\n if (!type) return;\n\n const direction = th.dataset.dir === 'asc' ? 'desc' : 'asc';\n setSortState(thead, th, direction);\n const dir = direction === 'asc' ? 1 : -1;\n\n const rows = Array.from(tbody.rows);\n\n rows.sort((a, b) => {\n const av = (a.cells[col]?.textContent ?? '').trim();\n const bv = (b.cells[col]?.textContent ?? '').trim();\n return compare(av, bv, type, locale, dir);\n });\n\n tbody.append(...rows);\n },\n [locale]\n );\n\n return (\n <table\n className={styles.table}\n onClick={onClick}\n ref={ref}\n {...props}\n >\n {normalizedChildren}\n </table>\n );\n};\n"],"names":["isTableElement","child","isValidElement","countCells","children","Children","toArray","reduce","count","type","props","getFirstRowCellCount","nestedCount","normalizeChildren","columnCount","map","nextChildren","undefined","nextProps","colSpan","jsxs","styles","sortable","Icon","cloneElement","compare","a","b","locale","dir","localeCompare","sensitivity","left","Date","parse","Number","parseFloat","right","isNaN","Table","ref","useRef","normalizedChildren","setSortState","thead","active","ths","querySelectorAll","forEach","th","dataset","setAttribute","onClick","useCallback","e","table","current","target","closest","tHead","contains","col","cellIndex","tbody","tBodies","getAttribute","direction","rows","Array","from","sort","av","cells","textContent","trim","bv","append","jsx"],"mappings":"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"}
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});require('../../assets/index42.css');const e=require("react/jsx-runtime"),r=require("../../classix-5H4IWnMA.cjs"),y=require("../../utils-
|
|
1
|
+
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});require('../../assets/index42.css');const e=require("react/jsx-runtime"),r=require("../../classix-5H4IWnMA.cjs"),y=require("../../utils-DqVa4K58.cjs"),l=require("../../styles.module-CwroCNAt.cjs"),d="_label_b5yys_1",b="_textarea_b5yys_5",n={label:d,textarea:b},m=({label:t,maxRows:o=12,minRows:c=3,required:s,value:a,...u})=>{const{touched:i,onBlur:x}=y.useTouched(a==="");return e.jsxs("label",{"data-component":"textarea",children:[t&&e.jsx("span",{className:r.t(n.label,s&&l.inputStyles.required),children:t}),e.jsx("textarea",{className:r.t(l.inputStyles.input,n.textarea,i&&"touched"),onBlur:x,...u,required:s,style:{"--min-rows":c,"--max-rows":o},value:a})]})};exports.Textarea=m;
|
|
2
2
|
//# sourceMappingURL=index.cjs.map
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { jsxs as p, jsx as s } from "react/jsx-runtime";
|
|
2
2
|
import { t as r } from "../../classix-DG18itHa.js";
|
|
3
|
-
import { u } from "../../utils-
|
|
3
|
+
import { u } from "../../utils-BFlnRYx7.js";
|
|
4
4
|
import { i as o } from "../../styles.module-C_Z8FrR5.js";
|
|
5
5
|
import '../../assets/index42.css';const y = "_label_b5yys_1", b = "_textarea_b5yys_5", l = {
|
|
6
6
|
label: y,
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
"use strict";const M={bold:"M6.75 3.744h-.753v8.25h7.125a4.125 4.125 0 0 0 0-8.25H6.75Zm0 0v.38m0 16.122h6.747a4.5 4.5 0 0 0 0-9.001h-7.5v9h.753Zm0 0v-.37m0-15.751h6a3.75 3.75 0 1 1 0 7.5h-6m0-7.5v7.5m0 0v8.25m0-8.25h6.375a4.125 4.125 0 0 1 0 8.25H6.75m.747-15.38h4.875a3.375 3.375 0 0 1 0 6.75H7.497v-6.75Zm0 7.5h5.25a3.75 3.75 0 0 1 0 7.5h-5.25v-7.5Z",buildings:"M2.25 21h19.5m-18-18v18m10.5-18v18m6-13.5V21M6.75 6.75h.75m-.75 3h.75m-.75 3h.75m3-6h.75m-.75 3h.75m-.75 3h.75M6.75 21v-3.375c0-.621.504-1.125 1.125-1.125h2.25c.621 0 1.125.504 1.125 1.125V21M3 3h12m-.75 4.5H21m-3.75 3.75h.008v.008h-.008v-.008Zm0 3h.008v.008h-.008v-.008Zm0 3h.008v.008h-.008v-.008Z",card:"M15 9h3.75M15 12h3.75M15 15h3.75M4.5 19.5h15a2.25 2.25 0 0 0 2.25-2.25V6.75A2.25 2.25 0 0 0 19.5 4.5h-15a2.25 2.25 0 0 0-2.25 2.25v10.5A2.25 2.25 0 0 0 4.5 19.5Zm6-10.125a1.875 1.875 0 1 1-3.75 0 1.875 1.875 0 0 1 3.75 0Zm1.294 6.336a6.721 6.721 0 0 1-3.17.789 6.721 6.721 0 0 1-3.168-.789 3.376 3.376 0 0 1 6.338 0Z",check:"m4.5 12.75 6 6 9-13.5",chevron:"m19.5 8.25-7.5 7.5-7.5-7.5",clipboard:{filled:"M10.5 3A1.501 1.501 0 0 0 9 4.5h6A1.5 1.5 0 0 0 13.5 3h-3Zm-2.693.178A3 3 0 0 1 10.5 1.5h3a3 3 0 0 1 2.694 1.678c.497.042.992.092 1.486.15 1.497.173 2.57 1.46 2.57 2.929V19.5a3 3 0 0 1-3 3H6.75a3 3 0 0 1-3-3V6.257c0-1.47 1.073-2.756 2.57-2.93.493-.057.989-.107 1.487-.15Z",outline:"M11.35 3.836c-.065.21-.1.433-.1.664 0 .414.336.75.75.75h4.5a.75.75 0 0 0 .75-.75 2.25 2.25 0 0 0-.1-.664m-5.8 0A2.251 2.251 0 0 1 13.5 2.25H15c1.012 0 1.867.668 2.15 1.586m-5.8 0c-.376.023-.75.05-1.124.08C9.095 4.01 8.25 4.973 8.25 6.108V8.25m8.9-4.414c.376.023.75.05 1.124.08 1.131.094 1.976 1.057 1.976 2.192V16.5A2.25 2.25 0 0 1 18 18.75h-2.25m-7.5-10.5H4.875c-.621 0-1.125.504-1.125 1.125v11.25c0 .621.504 1.125 1.125 1.125h9.75c.621 0 1.125-.504 1.125-1.125V18.75m-7.5-10.5h6.375c.621 0 1.125.504 1.125 1.125v9.375m-8.25-3 1.5 1.5 3-3.75"},document:"M19.5 14.25v-2.625a3.375 3.375 0 0 0-3.375-3.375h-1.5A1.125 1.125 0 0 1 13.5 7.125v-1.5a3.375 3.375 0 0 0-3.375-3.375H8.25m2.25 0H5.625c-.621 0-1.125.504-1.125 1.125v17.25c0 .621.504 1.125 1.125 1.125h12.75c.621 0 1.125-.504 1.125-1.125V11.25a9 9 0 0 0-9-9Z",error:"M12 9v3.75m-9.303 3.376c-.866 1.5.217 3.374 1.948 3.374h14.71c1.73 0 2.813-1.874 1.948-3.374L13.949 3.378c-.866-1.5-3.032-1.5-3.898 0L2.697 16.126ZM12 15.75h.007v.008H12v-.008Z",gear:"M2.3 11.2C2.3 16.2 6.4 20.3 11.4 20.3C16.4 20.3 20.4 16.2 20.4 11.2M2.3 11.2C2.3 6.2 6.4 2.1 11.4 2.1C16.4 2.1 20.4 6.2 20.4 11.2M2.3 11.2L0.5 11.2M20.4 11.2L22.2 11.2M20.4 11.2L11.4 11.2M1.2 14.9L2.9 14.3M19.9 8.1L21.6 7.5M3 18.2L4.4 17M18.3 5.4L19.7 4.2M5.9 20.6L6.8 19.1M15.9 3.4L16.8 1.8M9.5 21.9L9.8 20.1M12.9 2.3L13.3 0.5M13.3 21.9L12.9 20.1M9.8 2.3L9.5 0.5M16.8 20.6L15.9 19.1M5.9 1.8L11.4 11.2M19.7 18.2L18.3 17M4.4 5.4L3 4.2M21.6 14.9L19.9 14.3M2.9 8.1L1.2 7.5M11.4 11.2L6.8 19.1",goTo:"M13.5 6H5.25A2.25 2.25 0 0 0 3 8.25v10.5A2.25 2.25 0 0 0 5.25 21h10.5A2.25 2.25 0 0 0 18 18.75V10.5m-10.5 6L21 3m0 0h-5.25M21 3v5.25",home:"m2.25 12 8.954-8.955c.44-.439 1.152-.439 1.591 0L21.75 12M4.5 9.75v10.125c0 .621.504 1.125 1.125 1.125H9.75v-4.875c0-.621.504-1.125 1.125-1.125h2.25c.621 0 1.125.504 1.125 1.125V21h4.125c.621 0 1.125-.504 1.125-1.125V9.75M8.25 21h8.25",image:"m2.25 15.75 5.159-5.159a2.25 2.25 0 0 1 3.182 0l5.159 5.159m-1.5-1.5 1.409-1.409a2.25 2.25 0 0 1 3.182 0l2.909 2.909m-18 3.75h16.5a1.5 1.5 0 0 0 1.5-1.5V6a1.5 1.5 0 0 0-1.5-1.5H3.75A1.5 1.5 0 0 0 2.25 6v12a1.5 1.5 0 0 0 1.5 1.5Zm10.5-11.25h.008v.008h-.008V8.25Zm.375 0a.375.375 0 1 1-.75 0 .375.375 0 0 1 .75 0Z",info:"m11.25 11.25.041-.02a.75.75 0 0 1 1.063.852l-.708 2.836a.75.75 0 0 0 1.063.853l.041-.021M21 12a9 9 0 1 1-18 0 9 9 0 0 1 18 0Zm-9-3.75h.008v.008H12V8.25Z",italic:"M5.248 20.246H9.05m0 0h3.696m-3.696 0 5.893-16.502m0 0h-3.697m3.697 0h3.803",link:"M13.19 8.688a4.5 4.5 0 0 1 1.242 7.244l-4.5 4.5a4.5 4.5 0 0 1-6.364-6.364l1.757-1.757m13.35-.622 1.757-1.757a4.5 4.5 0 0 0-6.364-6.364l-4.5 4.5a4.5 4.5 0 0 0 1.242 7.244",list:"M8.25 6.75h12M8.25 12h12m-12 5.25h12M3.75 6.75h.007v.008H3.75V6.75Zm.375 0a.375.375 0 1 1-.75 0 .375.375 0 0 1 .75 0ZM3.75 12h.007v.008H3.75V12Zm.375 0a.375.375 0 1 1-.75 0 .375.375 0 0 1 .75 0Zm-.375 5.25h.007v.008H3.75v-.008Zm.375 0a.375.375 0 1 1-.75 0 .375.375 0 0 1 .75 0Z",megaphone:{filled:"M16.881 4.345A23.112 23.112 0 0 1 8.25 6H7.5a5.25 5.25 0 0 0-.88 10.427 21.593 21.593 0 0 0 1.378 3.94c.464 1.004 1.674 1.32 2.582.796l.657-.379c.88-.508 1.165-1.593.772-2.468a17.116 17.116 0 0 1-.628-1.607c1.918.258 3.76.75 5.5 1.446A21.727 21.727 0 0 0 18 11.25c0-2.414-.393-4.735-1.119-6.905ZM18.26 3.74a23.22 23.22 0 0 1 1.24 7.51 23.22 23.22 0 0 1-1.41 7.992.75.75 0 1 0 1.409.516 24.555 24.555 0 0 0 1.415-6.43 2.992 2.992 0 0 0 .836-2.078c0-.807-.319-1.54-.836-2.078a24.65 24.65 0 0 0-1.415-6.43.75.75 0 1 0-1.409.516c.059.16.116.321.17.483Z",outline:""},menu:"M3.75 6.75h16.5M3.75 12h16.5m-16.5 5.25h16.5",mobile:"M10.5 1.5H8.25A2.25 2.25 0 0 0 6 3.75v16.5a2.25 2.25 0 0 0 2.25 2.25h7.5A2.25 2.25 0 0 0 18 20.25V3.75a2.25 2.25 0 0 0-2.25-2.25H13.5m-3 0V3h3V1.5m-3 0h3m-3 18.75h3",pencil:"M21.731 2.269a2.625 2.625 0 0 0-3.712 0l-1.157 1.157 3.712 3.712 1.157-1.157a2.625 2.625 0 0 0 0-3.712ZM19.513 8.199l-3.712-3.712-12.15 12.15a5.25 5.25 0 0 0-1.32 2.214l-.8 2.685a.75.75 0 0 0 .933.933l2.685-.8a5.25 5.25 0 0 0 2.214-1.32L19.513 8.2Z",people:"M15 19.128a9.38 9.38 0 0 0 2.625.372 9.337 9.337 0 0 0 4.121-.952 4.125 4.125 0 0 0-7.533-2.493M15 19.128v-.003c0-1.113-.285-2.16-.786-3.07M15 19.128v.106A12.318 12.318 0 0 1 8.624 21c-2.331 0-4.512-.645-6.374-1.766l-.001-.109a6.375 6.375 0 0 1 11.964-3.07M12 6.375a3.375 3.375 0 1 1-6.75 0 3.375 3.375 0 0 1 6.75 0Zm8.25 2.25a2.625 2.625 0 1 1-5.25 0 2.625 2.625 0 0 1 5.25 0Z",phone:"M2.25 6.75c0 8.284 6.716 15 15 15h2.25a2.25 2.25 0 0 0 2.25-2.25v-1.372c0-.516-.351-.966-.852-1.091l-4.423-1.106c-.44-.11-.902.055-1.173.417l-.97 1.293c-.282.376-.769.542-1.21.38a12.035 12.035 0 0 1-7.143-7.143c-.162-.441.004-.928.38-1.21l1.293-.97c.363-.271.527-.734.417-1.173L6.963 3.102a1.125 1.125 0 0 0-1.091-.852H4.5A2.25 2.25 0 0 0 2.25 4.5v2.25Z",plane:{filled:"M3.478 2.404a.75.75 0 0 0-.926.941l2.432 7.905H13.5a.75.75 0 0 1 0 1.5H4.984l-2.432 7.905a.75.75 0 0 0 .926.94 60.519 60.519 0 0 0 18.445-8.986.75.75 0 0 0 0-1.218A60.517 60.517 0 0 0 3.478 2.404Z",outline:"M6 12 3.269 3.125A59.769 59.769 0 0 1 21.485 12 59.768 59.768 0 0 1 3.27 20.875L5.999 12Zm0 0h7.5"},plus:"M12 4.5v15m7.5-7.5h-15",search:"m21 21-5.197-5.197m0 0A7.5 7.5 0 1 0 5.196 5.196a7.5 7.5 0 0 0 10.607 10.607Z",success:"M9 12.75 11.25 15 15 9.75M21 12a9 9 0 1 1-18 0 9 9 0 0 1 18 0Z",trash:"m14.74 9-.346 9m-4.788 0L9.26 9m9.968-3.21c.342.052.682.107 1.022.166m-1.022-.165L18.16 19.673a2.25 2.25 0 0 1-2.244 2.077H8.084a2.25 2.25 0 0 1-2.244-2.077L4.772 5.79m14.456 0a48.108 48.108 0 0 0-3.478-.397m-12 .562c.34-.059.68-.114 1.022-.165m0 0a48.11 48.11 0 0 1 3.478-.397m7.5 0v-.916c0-1.18-.91-2.164-2.09-2.201a51.964 51.964 0 0 0-3.32 0c-1.18.037-2.09 1.022-2.09 2.201v.916m7.5 0a48.667 48.667 0 0 0-7.5 0",updown:"M8.25 15 12 18.75 15.75 15m-7.5-6L12 5.25 15.75 9",upload:"M3 16.5v2.25A2.25 2.25 0 0 0 5.25 21h13.5A2.25 2.25 0 0 0 21 18.75V16.5m-13.5-9L12 3m0 0 4.5 4.5M12 3v13.5",user:"M15.75 6a3.75 3.75 0 1 1-7.5 0 3.75 3.75 0 0 1 7.5 0ZM4.501 20.118a7.5 7.5 0 0 1 14.998 0A17.933 17.933 0 0 1 12 21.75c-2.676 0-5.216-.584-7.499-1.632Z",x:"M6 18 18 6M6 6l12 12"};function v(a,m){return`url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' fill='${m?"currentColor":"none"}' viewBox='0 0 24 24' stroke-width='
|
|
2
|
-
//# sourceMappingURL=icons-
|
|
1
|
+
"use strict";const M={bold:"M6.75 3.744h-.753v8.25h7.125a4.125 4.125 0 0 0 0-8.25H6.75Zm0 0v.38m0 16.122h6.747a4.5 4.5 0 0 0 0-9.001h-7.5v9h.753Zm0 0v-.37m0-15.751h6a3.75 3.75 0 1 1 0 7.5h-6m0-7.5v7.5m0 0v8.25m0-8.25h6.375a4.125 4.125 0 0 1 0 8.25H6.75m.747-15.38h4.875a3.375 3.375 0 0 1 0 6.75H7.497v-6.75Zm0 7.5h5.25a3.75 3.75 0 0 1 0 7.5h-5.25v-7.5Z",buildings:"M2.25 21h19.5m-18-18v18m10.5-18v18m6-13.5V21M6.75 6.75h.75m-.75 3h.75m-.75 3h.75m3-6h.75m-.75 3h.75m-.75 3h.75M6.75 21v-3.375c0-.621.504-1.125 1.125-1.125h2.25c.621 0 1.125.504 1.125 1.125V21M3 3h12m-.75 4.5H21m-3.75 3.75h.008v.008h-.008v-.008Zm0 3h.008v.008h-.008v-.008Zm0 3h.008v.008h-.008v-.008Z",card:"M15 9h3.75M15 12h3.75M15 15h3.75M4.5 19.5h15a2.25 2.25 0 0 0 2.25-2.25V6.75A2.25 2.25 0 0 0 19.5 4.5h-15a2.25 2.25 0 0 0-2.25 2.25v10.5A2.25 2.25 0 0 0 4.5 19.5Zm6-10.125a1.875 1.875 0 1 1-3.75 0 1.875 1.875 0 0 1 3.75 0Zm1.294 6.336a6.721 6.721 0 0 1-3.17.789 6.721 6.721 0 0 1-3.168-.789 3.376 3.376 0 0 1 6.338 0Z",check:"m4.5 12.75 6 6 9-13.5",chevron:"m19.5 8.25-7.5 7.5-7.5-7.5",clipboard:{filled:"M10.5 3A1.501 1.501 0 0 0 9 4.5h6A1.5 1.5 0 0 0 13.5 3h-3Zm-2.693.178A3 3 0 0 1 10.5 1.5h3a3 3 0 0 1 2.694 1.678c.497.042.992.092 1.486.15 1.497.173 2.57 1.46 2.57 2.929V19.5a3 3 0 0 1-3 3H6.75a3 3 0 0 1-3-3V6.257c0-1.47 1.073-2.756 2.57-2.93.493-.057.989-.107 1.487-.15Z",outline:"M11.35 3.836c-.065.21-.1.433-.1.664 0 .414.336.75.75.75h4.5a.75.75 0 0 0 .75-.75 2.25 2.25 0 0 0-.1-.664m-5.8 0A2.251 2.251 0 0 1 13.5 2.25H15c1.012 0 1.867.668 2.15 1.586m-5.8 0c-.376.023-.75.05-1.124.08C9.095 4.01 8.25 4.973 8.25 6.108V8.25m8.9-4.414c.376.023.75.05 1.124.08 1.131.094 1.976 1.057 1.976 2.192V16.5A2.25 2.25 0 0 1 18 18.75h-2.25m-7.5-10.5H4.875c-.621 0-1.125.504-1.125 1.125v11.25c0 .621.504 1.125 1.125 1.125h9.75c.621 0 1.125-.504 1.125-1.125V18.75m-7.5-10.5h6.375c.621 0 1.125.504 1.125 1.125v9.375m-8.25-3 1.5 1.5 3-3.75"},document:"M19.5 14.25v-2.625a3.375 3.375 0 0 0-3.375-3.375h-1.5A1.125 1.125 0 0 1 13.5 7.125v-1.5a3.375 3.375 0 0 0-3.375-3.375H8.25m2.25 0H5.625c-.621 0-1.125.504-1.125 1.125v17.25c0 .621.504 1.125 1.125 1.125h12.75c.621 0 1.125-.504 1.125-1.125V11.25a9 9 0 0 0-9-9Z",error:"M12 9v3.75m-9.303 3.376c-.866 1.5.217 3.374 1.948 3.374h14.71c1.73 0 2.813-1.874 1.948-3.374L13.949 3.378c-.866-1.5-3.032-1.5-3.898 0L2.697 16.126ZM12 15.75h.007v.008H12v-.008Z",gear:"M2.3 11.2C2.3 16.2 6.4 20.3 11.4 20.3C16.4 20.3 20.4 16.2 20.4 11.2M2.3 11.2C2.3 6.2 6.4 2.1 11.4 2.1C16.4 2.1 20.4 6.2 20.4 11.2M2.3 11.2L0.5 11.2M20.4 11.2L22.2 11.2M20.4 11.2L11.4 11.2M1.2 14.9L2.9 14.3M19.9 8.1L21.6 7.5M3 18.2L4.4 17M18.3 5.4L19.7 4.2M5.9 20.6L6.8 19.1M15.9 3.4L16.8 1.8M9.5 21.9L9.8 20.1M12.9 2.3L13.3 0.5M13.3 21.9L12.9 20.1M9.8 2.3L9.5 0.5M16.8 20.6L15.9 19.1M5.9 1.8L11.4 11.2M19.7 18.2L18.3 17M4.4 5.4L3 4.2M21.6 14.9L19.9 14.3M2.9 8.1L1.2 7.5M11.4 11.2L6.8 19.1",goTo:"M13.5 6H5.25A2.25 2.25 0 0 0 3 8.25v10.5A2.25 2.25 0 0 0 5.25 21h10.5A2.25 2.25 0 0 0 18 18.75V10.5m-10.5 6L21 3m0 0h-5.25M21 3v5.25",home:"m2.25 12 8.954-8.955c.44-.439 1.152-.439 1.591 0L21.75 12M4.5 9.75v10.125c0 .621.504 1.125 1.125 1.125H9.75v-4.875c0-.621.504-1.125 1.125-1.125h2.25c.621 0 1.125.504 1.125 1.125V21h4.125c.621 0 1.125-.504 1.125-1.125V9.75M8.25 21h8.25",image:"m2.25 15.75 5.159-5.159a2.25 2.25 0 0 1 3.182 0l5.159 5.159m-1.5-1.5 1.409-1.409a2.25 2.25 0 0 1 3.182 0l2.909 2.909m-18 3.75h16.5a1.5 1.5 0 0 0 1.5-1.5V6a1.5 1.5 0 0 0-1.5-1.5H3.75A1.5 1.5 0 0 0 2.25 6v12a1.5 1.5 0 0 0 1.5 1.5Zm10.5-11.25h.008v.008h-.008V8.25Zm.375 0a.375.375 0 1 1-.75 0 .375.375 0 0 1 .75 0Z",info:"m11.25 11.25.041-.02a.75.75 0 0 1 1.063.852l-.708 2.836a.75.75 0 0 0 1.063.853l.041-.021M21 12a9 9 0 1 1-18 0 9 9 0 0 1 18 0Zm-9-3.75h.008v.008H12V8.25Z",italic:"M5.248 20.246H9.05m0 0h3.696m-3.696 0 5.893-16.502m0 0h-3.697m3.697 0h3.803",link:"M13.19 8.688a4.5 4.5 0 0 1 1.242 7.244l-4.5 4.5a4.5 4.5 0 0 1-6.364-6.364l1.757-1.757m13.35-.622 1.757-1.757a4.5 4.5 0 0 0-6.364-6.364l-4.5 4.5a4.5 4.5 0 0 0 1.242 7.244",list:"M8.25 6.75h12M8.25 12h12m-12 5.25h12M3.75 6.75h.007v.008H3.75V6.75Zm.375 0a.375.375 0 1 1-.75 0 .375.375 0 0 1 .75 0ZM3.75 12h.007v.008H3.75V12Zm.375 0a.375.375 0 1 1-.75 0 .375.375 0 0 1 .75 0Zm-.375 5.25h.007v.008H3.75v-.008Zm.375 0a.375.375 0 1 1-.75 0 .375.375 0 0 1 .75 0Z",megaphone:{filled:"M16.881 4.345A23.112 23.112 0 0 1 8.25 6H7.5a5.25 5.25 0 0 0-.88 10.427 21.593 21.593 0 0 0 1.378 3.94c.464 1.004 1.674 1.32 2.582.796l.657-.379c.88-.508 1.165-1.593.772-2.468a17.116 17.116 0 0 1-.628-1.607c1.918.258 3.76.75 5.5 1.446A21.727 21.727 0 0 0 18 11.25c0-2.414-.393-4.735-1.119-6.905ZM18.26 3.74a23.22 23.22 0 0 1 1.24 7.51 23.22 23.22 0 0 1-1.41 7.992.75.75 0 1 0 1.409.516 24.555 24.555 0 0 0 1.415-6.43 2.992 2.992 0 0 0 .836-2.078c0-.807-.319-1.54-.836-2.078a24.65 24.65 0 0 0-1.415-6.43.75.75 0 1 0-1.409.516c.059.16.116.321.17.483Z",outline:""},menu:"M3.75 6.75h16.5M3.75 12h16.5m-16.5 5.25h16.5",mobile:"M10.5 1.5H8.25A2.25 2.25 0 0 0 6 3.75v16.5a2.25 2.25 0 0 0 2.25 2.25h7.5A2.25 2.25 0 0 0 18 20.25V3.75a2.25 2.25 0 0 0-2.25-2.25H13.5m-3 0V3h3V1.5m-3 0h3m-3 18.75h3",pencil:"M21.731 2.269a2.625 2.625 0 0 0-3.712 0l-1.157 1.157 3.712 3.712 1.157-1.157a2.625 2.625 0 0 0 0-3.712ZM19.513 8.199l-3.712-3.712-12.15 12.15a5.25 5.25 0 0 0-1.32 2.214l-.8 2.685a.75.75 0 0 0 .933.933l2.685-.8a5.25 5.25 0 0 0 2.214-1.32L19.513 8.2Z",people:"M15 19.128a9.38 9.38 0 0 0 2.625.372 9.337 9.337 0 0 0 4.121-.952 4.125 4.125 0 0 0-7.533-2.493M15 19.128v-.003c0-1.113-.285-2.16-.786-3.07M15 19.128v.106A12.318 12.318 0 0 1 8.624 21c-2.331 0-4.512-.645-6.374-1.766l-.001-.109a6.375 6.375 0 0 1 11.964-3.07M12 6.375a3.375 3.375 0 1 1-6.75 0 3.375 3.375 0 0 1 6.75 0Zm8.25 2.25a2.625 2.625 0 1 1-5.25 0 2.625 2.625 0 0 1 5.25 0Z",phone:"M2.25 6.75c0 8.284 6.716 15 15 15h2.25a2.25 2.25 0 0 0 2.25-2.25v-1.372c0-.516-.351-.966-.852-1.091l-4.423-1.106c-.44-.11-.902.055-1.173.417l-.97 1.293c-.282.376-.769.542-1.21.38a12.035 12.035 0 0 1-7.143-7.143c-.162-.441.004-.928.38-1.21l1.293-.97c.363-.271.527-.734.417-1.173L6.963 3.102a1.125 1.125 0 0 0-1.091-.852H4.5A2.25 2.25 0 0 0 2.25 4.5v2.25Z",plane:{filled:"M3.478 2.404a.75.75 0 0 0-.926.941l2.432 7.905H13.5a.75.75 0 0 1 0 1.5H4.984l-2.432 7.905a.75.75 0 0 0 .926.94 60.519 60.519 0 0 0 18.445-8.986.75.75 0 0 0 0-1.218A60.517 60.517 0 0 0 3.478 2.404Z",outline:"M6 12 3.269 3.125A59.769 59.769 0 0 1 21.485 12 59.768 59.768 0 0 1 3.27 20.875L5.999 12Zm0 0h7.5"},plus:"M12 4.5v15m7.5-7.5h-15",search:"m21 21-5.197-5.197m0 0A7.5 7.5 0 1 0 5.196 5.196a7.5 7.5 0 0 0 10.607 10.607Z",success:"M9 12.75 11.25 15 15 9.75M21 12a9 9 0 1 1-18 0 9 9 0 0 1 18 0Z",trash:"m14.74 9-.346 9m-4.788 0L9.26 9m9.968-3.21c.342.052.682.107 1.022.166m-1.022-.165L18.16 19.673a2.25 2.25 0 0 1-2.244 2.077H8.084a2.25 2.25 0 0 1-2.244-2.077L4.772 5.79m14.456 0a48.108 48.108 0 0 0-3.478-.397m-12 .562c.34-.059.68-.114 1.022-.165m0 0a48.11 48.11 0 0 1 3.478-.397m7.5 0v-.916c0-1.18-.91-2.164-2.09-2.201a51.964 51.964 0 0 0-3.32 0c-1.18.037-2.09 1.022-2.09 2.201v.916m7.5 0a48.667 48.667 0 0 0-7.5 0",updown:"M8.25 15 12 18.75 15.75 15m-7.5-6L12 5.25 15.75 9",upload:"M3 16.5v2.25A2.25 2.25 0 0 0 5.25 21h13.5A2.25 2.25 0 0 0 21 18.75V16.5m-13.5-9L12 3m0 0 4.5 4.5M12 3v13.5",user:"M15.75 6a3.75 3.75 0 1 1-7.5 0 3.75 3.75 0 0 1 7.5 0ZM4.501 20.118a7.5 7.5 0 0 1 14.998 0A17.933 17.933 0 0 1 12 21.75c-2.676 0-5.216-.584-7.499-1.632Z",x:"M6 18 18 6M6 6l12 12"};function v(a,m){return`url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' fill='${m?"currentColor":"none"}' viewBox='0 0 24 24' stroke-width='1.5' stroke='${m?"none":"currentColor"}'%3E%3Cpath stroke-linecap='round' stroke-linejoin='round' d='${a}' /%3E%3C/svg%3E%0A")`}const e=(a,m=!1)=>{const h=M[a],c=typeof h=="string"?h:m?h.filled:h.outline,l=m&&typeof h=="object"&&!!h.filled;return v(c,l)};exports.iconPaths=M;exports.iconSVG=e;
|
|
2
|
+
//# sourceMappingURL=icons-C_cX1FYp.cjs.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"icons-
|
|
1
|
+
{"version":3,"file":"icons-C_cX1FYp.cjs","sources":["../src/components/icon/icons.ts"],"sourcesContent":["export type IconName = keyof typeof iconPaths;\n\nexport const iconPaths = {\n bold: 'M6.75 3.744h-.753v8.25h7.125a4.125 4.125 0 0 0 0-8.25H6.75Zm0 0v.38m0 16.122h6.747a4.5 4.5 0 0 0 0-9.001h-7.5v9h.753Zm0 0v-.37m0-15.751h6a3.75 3.75 0 1 1 0 7.5h-6m0-7.5v7.5m0 0v8.25m0-8.25h6.375a4.125 4.125 0 0 1 0 8.25H6.75m.747-15.38h4.875a3.375 3.375 0 0 1 0 6.75H7.497v-6.75Zm0 7.5h5.25a3.75 3.75 0 0 1 0 7.5h-5.25v-7.5Z',\n buildings:\n 'M2.25 21h19.5m-18-18v18m10.5-18v18m6-13.5V21M6.75 6.75h.75m-.75 3h.75m-.75 3h.75m3-6h.75m-.75 3h.75m-.75 3h.75M6.75 21v-3.375c0-.621.504-1.125 1.125-1.125h2.25c.621 0 1.125.504 1.125 1.125V21M3 3h12m-.75 4.5H21m-3.75 3.75h.008v.008h-.008v-.008Zm0 3h.008v.008h-.008v-.008Zm0 3h.008v.008h-.008v-.008Z',\n card: 'M15 9h3.75M15 12h3.75M15 15h3.75M4.5 19.5h15a2.25 2.25 0 0 0 2.25-2.25V6.75A2.25 2.25 0 0 0 19.5 4.5h-15a2.25 2.25 0 0 0-2.25 2.25v10.5A2.25 2.25 0 0 0 4.5 19.5Zm6-10.125a1.875 1.875 0 1 1-3.75 0 1.875 1.875 0 0 1 3.75 0Zm1.294 6.336a6.721 6.721 0 0 1-3.17.789 6.721 6.721 0 0 1-3.168-.789 3.376 3.376 0 0 1 6.338 0Z',\n check: 'm4.5 12.75 6 6 9-13.5',\n chevron: 'm19.5 8.25-7.5 7.5-7.5-7.5',\n clipboard: {\n filled:\n 'M10.5 3A1.501 1.501 0 0 0 9 4.5h6A1.5 1.5 0 0 0 13.5 3h-3Zm-2.693.178A3 3 0 0 1 10.5 1.5h3a3 3 0 0 1 2.694 1.678c.497.042.992.092 1.486.15 1.497.173 2.57 1.46 2.57 2.929V19.5a3 3 0 0 1-3 3H6.75a3 3 0 0 1-3-3V6.257c0-1.47 1.073-2.756 2.57-2.93.493-.057.989-.107 1.487-.15Z',\n outline:\n 'M11.35 3.836c-.065.21-.1.433-.1.664 0 .414.336.75.75.75h4.5a.75.75 0 0 0 .75-.75 2.25 2.25 0 0 0-.1-.664m-5.8 0A2.251 2.251 0 0 1 13.5 2.25H15c1.012 0 1.867.668 2.15 1.586m-5.8 0c-.376.023-.75.05-1.124.08C9.095 4.01 8.25 4.973 8.25 6.108V8.25m8.9-4.414c.376.023.75.05 1.124.08 1.131.094 1.976 1.057 1.976 2.192V16.5A2.25 2.25 0 0 1 18 18.75h-2.25m-7.5-10.5H4.875c-.621 0-1.125.504-1.125 1.125v11.25c0 .621.504 1.125 1.125 1.125h9.75c.621 0 1.125-.504 1.125-1.125V18.75m-7.5-10.5h6.375c.621 0 1.125.504 1.125 1.125v9.375m-8.25-3 1.5 1.5 3-3.75',\n },\n document:\n 'M19.5 14.25v-2.625a3.375 3.375 0 0 0-3.375-3.375h-1.5A1.125 1.125 0 0 1 13.5 7.125v-1.5a3.375 3.375 0 0 0-3.375-3.375H8.25m2.25 0H5.625c-.621 0-1.125.504-1.125 1.125v17.25c0 .621.504 1.125 1.125 1.125h12.75c.621 0 1.125-.504 1.125-1.125V11.25a9 9 0 0 0-9-9Z',\n error:\n 'M12 9v3.75m-9.303 3.376c-.866 1.5.217 3.374 1.948 3.374h14.71c1.73 0 2.813-1.874 1.948-3.374L13.949 3.378c-.866-1.5-3.032-1.5-3.898 0L2.697 16.126ZM12 15.75h.007v.008H12v-.008Z',\n gear: 'M2.3 11.2C2.3 16.2 6.4 20.3 11.4 20.3C16.4 20.3 20.4 16.2 20.4 11.2M2.3 11.2C2.3 6.2 6.4 2.1 11.4 2.1C16.4 2.1 20.4 6.2 20.4 11.2M2.3 11.2L0.5 11.2M20.4 11.2L22.2 11.2M20.4 11.2L11.4 11.2M1.2 14.9L2.9 14.3M19.9 8.1L21.6 7.5M3 18.2L4.4 17M18.3 5.4L19.7 4.2M5.9 20.6L6.8 19.1M15.9 3.4L16.8 1.8M9.5 21.9L9.8 20.1M12.9 2.3L13.3 0.5M13.3 21.9L12.9 20.1M9.8 2.3L9.5 0.5M16.8 20.6L15.9 19.1M5.9 1.8L11.4 11.2M19.7 18.2L18.3 17M4.4 5.4L3 4.2M21.6 14.9L19.9 14.3M2.9 8.1L1.2 7.5M11.4 11.2L6.8 19.1',\n goTo: 'M13.5 6H5.25A2.25 2.25 0 0 0 3 8.25v10.5A2.25 2.25 0 0 0 5.25 21h10.5A2.25 2.25 0 0 0 18 18.75V10.5m-10.5 6L21 3m0 0h-5.25M21 3v5.25',\n home: 'm2.25 12 8.954-8.955c.44-.439 1.152-.439 1.591 0L21.75 12M4.5 9.75v10.125c0 .621.504 1.125 1.125 1.125H9.75v-4.875c0-.621.504-1.125 1.125-1.125h2.25c.621 0 1.125.504 1.125 1.125V21h4.125c.621 0 1.125-.504 1.125-1.125V9.75M8.25 21h8.25',\n image:\n 'm2.25 15.75 5.159-5.159a2.25 2.25 0 0 1 3.182 0l5.159 5.159m-1.5-1.5 1.409-1.409a2.25 2.25 0 0 1 3.182 0l2.909 2.909m-18 3.75h16.5a1.5 1.5 0 0 0 1.5-1.5V6a1.5 1.5 0 0 0-1.5-1.5H3.75A1.5 1.5 0 0 0 2.25 6v12a1.5 1.5 0 0 0 1.5 1.5Zm10.5-11.25h.008v.008h-.008V8.25Zm.375 0a.375.375 0 1 1-.75 0 .375.375 0 0 1 .75 0Z',\n info: 'm11.25 11.25.041-.02a.75.75 0 0 1 1.063.852l-.708 2.836a.75.75 0 0 0 1.063.853l.041-.021M21 12a9 9 0 1 1-18 0 9 9 0 0 1 18 0Zm-9-3.75h.008v.008H12V8.25Z',\n italic: 'M5.248 20.246H9.05m0 0h3.696m-3.696 0 5.893-16.502m0 0h-3.697m3.697 0h3.803',\n link: 'M13.19 8.688a4.5 4.5 0 0 1 1.242 7.244l-4.5 4.5a4.5 4.5 0 0 1-6.364-6.364l1.757-1.757m13.35-.622 1.757-1.757a4.5 4.5 0 0 0-6.364-6.364l-4.5 4.5a4.5 4.5 0 0 0 1.242 7.244',\n list: 'M8.25 6.75h12M8.25 12h12m-12 5.25h12M3.75 6.75h.007v.008H3.75V6.75Zm.375 0a.375.375 0 1 1-.75 0 .375.375 0 0 1 .75 0ZM3.75 12h.007v.008H3.75V12Zm.375 0a.375.375 0 1 1-.75 0 .375.375 0 0 1 .75 0Zm-.375 5.25h.007v.008H3.75v-.008Zm.375 0a.375.375 0 1 1-.75 0 .375.375 0 0 1 .75 0Z',\n megaphone: {\n filled:\n 'M16.881 4.345A23.112 23.112 0 0 1 8.25 6H7.5a5.25 5.25 0 0 0-.88 10.427 21.593 21.593 0 0 0 1.378 3.94c.464 1.004 1.674 1.32 2.582.796l.657-.379c.88-.508 1.165-1.593.772-2.468a17.116 17.116 0 0 1-.628-1.607c1.918.258 3.76.75 5.5 1.446A21.727 21.727 0 0 0 18 11.25c0-2.414-.393-4.735-1.119-6.905ZM18.26 3.74a23.22 23.22 0 0 1 1.24 7.51 23.22 23.22 0 0 1-1.41 7.992.75.75 0 1 0 1.409.516 24.555 24.555 0 0 0 1.415-6.43 2.992 2.992 0 0 0 .836-2.078c0-.807-.319-1.54-.836-2.078a24.65 24.65 0 0 0-1.415-6.43.75.75 0 1 0-1.409.516c.059.16.116.321.17.483Z',\n outline: '',\n },\n menu: 'M3.75 6.75h16.5M3.75 12h16.5m-16.5 5.25h16.5',\n mobile:\n 'M10.5 1.5H8.25A2.25 2.25 0 0 0 6 3.75v16.5a2.25 2.25 0 0 0 2.25 2.25h7.5A2.25 2.25 0 0 0 18 20.25V3.75a2.25 2.25 0 0 0-2.25-2.25H13.5m-3 0V3h3V1.5m-3 0h3m-3 18.75h3',\n pencil:\n 'M21.731 2.269a2.625 2.625 0 0 0-3.712 0l-1.157 1.157 3.712 3.712 1.157-1.157a2.625 2.625 0 0 0 0-3.712ZM19.513 8.199l-3.712-3.712-12.15 12.15a5.25 5.25 0 0 0-1.32 2.214l-.8 2.685a.75.75 0 0 0 .933.933l2.685-.8a5.25 5.25 0 0 0 2.214-1.32L19.513 8.2Z',\n people:\n 'M15 19.128a9.38 9.38 0 0 0 2.625.372 9.337 9.337 0 0 0 4.121-.952 4.125 4.125 0 0 0-7.533-2.493M15 19.128v-.003c0-1.113-.285-2.16-.786-3.07M15 19.128v.106A12.318 12.318 0 0 1 8.624 21c-2.331 0-4.512-.645-6.374-1.766l-.001-.109a6.375 6.375 0 0 1 11.964-3.07M12 6.375a3.375 3.375 0 1 1-6.75 0 3.375 3.375 0 0 1 6.75 0Zm8.25 2.25a2.625 2.625 0 1 1-5.25 0 2.625 2.625 0 0 1 5.25 0Z',\n phone:\n 'M2.25 6.75c0 8.284 6.716 15 15 15h2.25a2.25 2.25 0 0 0 2.25-2.25v-1.372c0-.516-.351-.966-.852-1.091l-4.423-1.106c-.44-.11-.902.055-1.173.417l-.97 1.293c-.282.376-.769.542-1.21.38a12.035 12.035 0 0 1-7.143-7.143c-.162-.441.004-.928.38-1.21l1.293-.97c.363-.271.527-.734.417-1.173L6.963 3.102a1.125 1.125 0 0 0-1.091-.852H4.5A2.25 2.25 0 0 0 2.25 4.5v2.25Z',\n plane: {\n filled:\n 'M3.478 2.404a.75.75 0 0 0-.926.941l2.432 7.905H13.5a.75.75 0 0 1 0 1.5H4.984l-2.432 7.905a.75.75 0 0 0 .926.94 60.519 60.519 0 0 0 18.445-8.986.75.75 0 0 0 0-1.218A60.517 60.517 0 0 0 3.478 2.404Z',\n outline:\n 'M6 12 3.269 3.125A59.769 59.769 0 0 1 21.485 12 59.768 59.768 0 0 1 3.27 20.875L5.999 12Zm0 0h7.5',\n },\n plus: 'M12 4.5v15m7.5-7.5h-15',\n search: 'm21 21-5.197-5.197m0 0A7.5 7.5 0 1 0 5.196 5.196a7.5 7.5 0 0 0 10.607 10.607Z',\n success: 'M9 12.75 11.25 15 15 9.75M21 12a9 9 0 1 1-18 0 9 9 0 0 1 18 0Z',\n trash:\n 'm14.74 9-.346 9m-4.788 0L9.26 9m9.968-3.21c.342.052.682.107 1.022.166m-1.022-.165L18.16 19.673a2.25 2.25 0 0 1-2.244 2.077H8.084a2.25 2.25 0 0 1-2.244-2.077L4.772 5.79m14.456 0a48.108 48.108 0 0 0-3.478-.397m-12 .562c.34-.059.68-.114 1.022-.165m0 0a48.11 48.11 0 0 1 3.478-.397m7.5 0v-.916c0-1.18-.91-2.164-2.09-2.201a51.964 51.964 0 0 0-3.32 0c-1.18.037-2.09 1.022-2.09 2.201v.916m7.5 0a48.667 48.667 0 0 0-7.5 0',\n updown: 'M8.25 15 12 18.75 15.75 15m-7.5-6L12 5.25 15.75 9',\n upload:\n 'M3 16.5v2.25A2.25 2.25 0 0 0 5.25 21h13.5A2.25 2.25 0 0 0 21 18.75V16.5m-13.5-9L12 3m0 0 4.5 4.5M12 3v13.5',\n user: 'M15.75 6a3.75 3.75 0 1 1-7.5 0 3.75 3.75 0 0 1 7.5 0ZM4.501 20.118a7.5 7.5 0 0 1 14.998 0A17.933 17.933 0 0 1 12 21.75c-2.676 0-5.216-.584-7.499-1.632Z',\n x: 'M6 18 18 6M6 6l12 12',\n};\n\nexport function embedSVG(iconPath: string, fill?: boolean): string {\n return `url(\"data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' fill='${fill ? 'currentColor' : 'none'}' viewBox='0 0 24 24' stroke-width='1.5' stroke='${fill ? 'none' : 'currentColor'}'%3E%3Cpath stroke-linecap='round' stroke-linejoin='round' d='${iconPath}' /%3E%3C/svg%3E%0A\")`;\n}\n\nexport const iconSVG = (name: IconName, fill = false) => {\n const icon = iconPaths[name];\n const path = typeof icon === 'string' ? icon : fill ? icon.filled : icon.outline;\n const hasFilled = fill && typeof icon === 'object' && !!icon.filled;\n\n return embedSVG(path, hasFilled);\n};\n"],"names":["iconPaths","bold","buildings","card","check","chevron","clipboard","filled","outline","document","error","gear","goTo","home","image","info","italic","link","list","megaphone","menu","mobile","pencil","people","phone","plane","plus","search","success","trash","updown","upload","user","x","embedSVG","iconPath","fill","iconSVG","name","icon","path","hasFilled"],"mappings":"aAEO,MAAMA,EAAY,CACvBC,KAAM,uUACNC,UACE,6SACFC,KAAM,+TACNC,MAAO,wBACPC,QAAS,6BACTC,UAAW,CACTC,OACE,kRACFC,QACE,giBAAA,EAEJC,SACE,oQACFC,MACE,mLACFC,KAAM,2eACNC,KAAM,uIACNC,KAAM,6OACNC,MACE,0TACFC,KAAM,2JACNC,OAAQ,8EACRC,KAAM,4KACNC,KAAM,wRACNC,UAAW,CACTZ,OACE,uiBACFC,QAAS,EAAA,EAEXY,KAAM,+CACNC,OACE,uKACFC,OACE,2PACFC,OACE,4XACFC,MACE,oWACFC,MAAO,CACLlB,OACE,uMACFC,QACE,mGAAA,EAEJkB,KAAM,yBACNC,OAAQ,gFACRC,QAAS,iEACTC,MACE,gaACFC,OAAQ,oDACRC,OACE,6GACFC,KAAM,0JACNC,EAAG,sBACL,EAEO,SAASC,EAASC,EAAkBC,EAAwB,CACjE,MAAO,2EAA2EA,EAAO,eAAiB,MAAM,oDAAoDA,EAAO,OAAS,cAAc,iEAAiED,CAAQ,uBAC7Q,CAEO,MAAME,EAAUA,CAACC,EAAgBF,EAAO,KAAU,CACvD,MAAMG,EAAOvC,EAAUsC,CAAI,EACrBE,EAAO,OAAOD,GAAS,SAAWA,EAAOH,EAAOG,EAAKhC,OAASgC,EAAK/B,QACnEiC,EAAYL,GAAQ,OAAOG,GAAS,UAAY,CAAC,CAACA,EAAKhC,OAE7D,OAAO2B,EAASM,EAAMC,CAAS,CACjC"}
|
|
@@ -41,7 +41,7 @@ const l = {
|
|
|
41
41
|
x: "M6 18 18 6M6 6l12 12"
|
|
42
42
|
};
|
|
43
43
|
function v(h, m) {
|
|
44
|
-
return `url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' fill='${m ? "currentColor" : "none"}' viewBox='0 0 24 24' stroke-width='
|
|
44
|
+
return `url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' fill='${m ? "currentColor" : "none"}' viewBox='0 0 24 24' stroke-width='1.5' stroke='${m ? "none" : "currentColor"}'%3E%3Cpath stroke-linecap='round' stroke-linejoin='round' d='${h}' /%3E%3C/svg%3E%0A")`;
|
|
45
45
|
}
|
|
46
46
|
const e = (h, m = !1) => {
|
|
47
47
|
const a = l[h], M = typeof a == "string" ? a : m ? a.filled : a.outline, c = m && typeof a == "object" && !!a.filled;
|
|
@@ -51,4 +51,4 @@ export {
|
|
|
51
51
|
l as a,
|
|
52
52
|
e as i
|
|
53
53
|
};
|
|
54
|
-
//# sourceMappingURL=icons-
|
|
54
|
+
//# sourceMappingURL=icons-DfmpRbxE.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"icons-
|
|
1
|
+
{"version":3,"file":"icons-DfmpRbxE.js","sources":["../src/components/icon/icons.ts"],"sourcesContent":["export type IconName = keyof typeof iconPaths;\n\nexport const iconPaths = {\n bold: 'M6.75 3.744h-.753v8.25h7.125a4.125 4.125 0 0 0 0-8.25H6.75Zm0 0v.38m0 16.122h6.747a4.5 4.5 0 0 0 0-9.001h-7.5v9h.753Zm0 0v-.37m0-15.751h6a3.75 3.75 0 1 1 0 7.5h-6m0-7.5v7.5m0 0v8.25m0-8.25h6.375a4.125 4.125 0 0 1 0 8.25H6.75m.747-15.38h4.875a3.375 3.375 0 0 1 0 6.75H7.497v-6.75Zm0 7.5h5.25a3.75 3.75 0 0 1 0 7.5h-5.25v-7.5Z',\n buildings:\n 'M2.25 21h19.5m-18-18v18m10.5-18v18m6-13.5V21M6.75 6.75h.75m-.75 3h.75m-.75 3h.75m3-6h.75m-.75 3h.75m-.75 3h.75M6.75 21v-3.375c0-.621.504-1.125 1.125-1.125h2.25c.621 0 1.125.504 1.125 1.125V21M3 3h12m-.75 4.5H21m-3.75 3.75h.008v.008h-.008v-.008Zm0 3h.008v.008h-.008v-.008Zm0 3h.008v.008h-.008v-.008Z',\n card: 'M15 9h3.75M15 12h3.75M15 15h3.75M4.5 19.5h15a2.25 2.25 0 0 0 2.25-2.25V6.75A2.25 2.25 0 0 0 19.5 4.5h-15a2.25 2.25 0 0 0-2.25 2.25v10.5A2.25 2.25 0 0 0 4.5 19.5Zm6-10.125a1.875 1.875 0 1 1-3.75 0 1.875 1.875 0 0 1 3.75 0Zm1.294 6.336a6.721 6.721 0 0 1-3.17.789 6.721 6.721 0 0 1-3.168-.789 3.376 3.376 0 0 1 6.338 0Z',\n check: 'm4.5 12.75 6 6 9-13.5',\n chevron: 'm19.5 8.25-7.5 7.5-7.5-7.5',\n clipboard: {\n filled:\n 'M10.5 3A1.501 1.501 0 0 0 9 4.5h6A1.5 1.5 0 0 0 13.5 3h-3Zm-2.693.178A3 3 0 0 1 10.5 1.5h3a3 3 0 0 1 2.694 1.678c.497.042.992.092 1.486.15 1.497.173 2.57 1.46 2.57 2.929V19.5a3 3 0 0 1-3 3H6.75a3 3 0 0 1-3-3V6.257c0-1.47 1.073-2.756 2.57-2.93.493-.057.989-.107 1.487-.15Z',\n outline:\n 'M11.35 3.836c-.065.21-.1.433-.1.664 0 .414.336.75.75.75h4.5a.75.75 0 0 0 .75-.75 2.25 2.25 0 0 0-.1-.664m-5.8 0A2.251 2.251 0 0 1 13.5 2.25H15c1.012 0 1.867.668 2.15 1.586m-5.8 0c-.376.023-.75.05-1.124.08C9.095 4.01 8.25 4.973 8.25 6.108V8.25m8.9-4.414c.376.023.75.05 1.124.08 1.131.094 1.976 1.057 1.976 2.192V16.5A2.25 2.25 0 0 1 18 18.75h-2.25m-7.5-10.5H4.875c-.621 0-1.125.504-1.125 1.125v11.25c0 .621.504 1.125 1.125 1.125h9.75c.621 0 1.125-.504 1.125-1.125V18.75m-7.5-10.5h6.375c.621 0 1.125.504 1.125 1.125v9.375m-8.25-3 1.5 1.5 3-3.75',\n },\n document:\n 'M19.5 14.25v-2.625a3.375 3.375 0 0 0-3.375-3.375h-1.5A1.125 1.125 0 0 1 13.5 7.125v-1.5a3.375 3.375 0 0 0-3.375-3.375H8.25m2.25 0H5.625c-.621 0-1.125.504-1.125 1.125v17.25c0 .621.504 1.125 1.125 1.125h12.75c.621 0 1.125-.504 1.125-1.125V11.25a9 9 0 0 0-9-9Z',\n error:\n 'M12 9v3.75m-9.303 3.376c-.866 1.5.217 3.374 1.948 3.374h14.71c1.73 0 2.813-1.874 1.948-3.374L13.949 3.378c-.866-1.5-3.032-1.5-3.898 0L2.697 16.126ZM12 15.75h.007v.008H12v-.008Z',\n gear: 'M2.3 11.2C2.3 16.2 6.4 20.3 11.4 20.3C16.4 20.3 20.4 16.2 20.4 11.2M2.3 11.2C2.3 6.2 6.4 2.1 11.4 2.1C16.4 2.1 20.4 6.2 20.4 11.2M2.3 11.2L0.5 11.2M20.4 11.2L22.2 11.2M20.4 11.2L11.4 11.2M1.2 14.9L2.9 14.3M19.9 8.1L21.6 7.5M3 18.2L4.4 17M18.3 5.4L19.7 4.2M5.9 20.6L6.8 19.1M15.9 3.4L16.8 1.8M9.5 21.9L9.8 20.1M12.9 2.3L13.3 0.5M13.3 21.9L12.9 20.1M9.8 2.3L9.5 0.5M16.8 20.6L15.9 19.1M5.9 1.8L11.4 11.2M19.7 18.2L18.3 17M4.4 5.4L3 4.2M21.6 14.9L19.9 14.3M2.9 8.1L1.2 7.5M11.4 11.2L6.8 19.1',\n goTo: 'M13.5 6H5.25A2.25 2.25 0 0 0 3 8.25v10.5A2.25 2.25 0 0 0 5.25 21h10.5A2.25 2.25 0 0 0 18 18.75V10.5m-10.5 6L21 3m0 0h-5.25M21 3v5.25',\n home: 'm2.25 12 8.954-8.955c.44-.439 1.152-.439 1.591 0L21.75 12M4.5 9.75v10.125c0 .621.504 1.125 1.125 1.125H9.75v-4.875c0-.621.504-1.125 1.125-1.125h2.25c.621 0 1.125.504 1.125 1.125V21h4.125c.621 0 1.125-.504 1.125-1.125V9.75M8.25 21h8.25',\n image:\n 'm2.25 15.75 5.159-5.159a2.25 2.25 0 0 1 3.182 0l5.159 5.159m-1.5-1.5 1.409-1.409a2.25 2.25 0 0 1 3.182 0l2.909 2.909m-18 3.75h16.5a1.5 1.5 0 0 0 1.5-1.5V6a1.5 1.5 0 0 0-1.5-1.5H3.75A1.5 1.5 0 0 0 2.25 6v12a1.5 1.5 0 0 0 1.5 1.5Zm10.5-11.25h.008v.008h-.008V8.25Zm.375 0a.375.375 0 1 1-.75 0 .375.375 0 0 1 .75 0Z',\n info: 'm11.25 11.25.041-.02a.75.75 0 0 1 1.063.852l-.708 2.836a.75.75 0 0 0 1.063.853l.041-.021M21 12a9 9 0 1 1-18 0 9 9 0 0 1 18 0Zm-9-3.75h.008v.008H12V8.25Z',\n italic: 'M5.248 20.246H9.05m0 0h3.696m-3.696 0 5.893-16.502m0 0h-3.697m3.697 0h3.803',\n link: 'M13.19 8.688a4.5 4.5 0 0 1 1.242 7.244l-4.5 4.5a4.5 4.5 0 0 1-6.364-6.364l1.757-1.757m13.35-.622 1.757-1.757a4.5 4.5 0 0 0-6.364-6.364l-4.5 4.5a4.5 4.5 0 0 0 1.242 7.244',\n list: 'M8.25 6.75h12M8.25 12h12m-12 5.25h12M3.75 6.75h.007v.008H3.75V6.75Zm.375 0a.375.375 0 1 1-.75 0 .375.375 0 0 1 .75 0ZM3.75 12h.007v.008H3.75V12Zm.375 0a.375.375 0 1 1-.75 0 .375.375 0 0 1 .75 0Zm-.375 5.25h.007v.008H3.75v-.008Zm.375 0a.375.375 0 1 1-.75 0 .375.375 0 0 1 .75 0Z',\n megaphone: {\n filled:\n 'M16.881 4.345A23.112 23.112 0 0 1 8.25 6H7.5a5.25 5.25 0 0 0-.88 10.427 21.593 21.593 0 0 0 1.378 3.94c.464 1.004 1.674 1.32 2.582.796l.657-.379c.88-.508 1.165-1.593.772-2.468a17.116 17.116 0 0 1-.628-1.607c1.918.258 3.76.75 5.5 1.446A21.727 21.727 0 0 0 18 11.25c0-2.414-.393-4.735-1.119-6.905ZM18.26 3.74a23.22 23.22 0 0 1 1.24 7.51 23.22 23.22 0 0 1-1.41 7.992.75.75 0 1 0 1.409.516 24.555 24.555 0 0 0 1.415-6.43 2.992 2.992 0 0 0 .836-2.078c0-.807-.319-1.54-.836-2.078a24.65 24.65 0 0 0-1.415-6.43.75.75 0 1 0-1.409.516c.059.16.116.321.17.483Z',\n outline: '',\n },\n menu: 'M3.75 6.75h16.5M3.75 12h16.5m-16.5 5.25h16.5',\n mobile:\n 'M10.5 1.5H8.25A2.25 2.25 0 0 0 6 3.75v16.5a2.25 2.25 0 0 0 2.25 2.25h7.5A2.25 2.25 0 0 0 18 20.25V3.75a2.25 2.25 0 0 0-2.25-2.25H13.5m-3 0V3h3V1.5m-3 0h3m-3 18.75h3',\n pencil:\n 'M21.731 2.269a2.625 2.625 0 0 0-3.712 0l-1.157 1.157 3.712 3.712 1.157-1.157a2.625 2.625 0 0 0 0-3.712ZM19.513 8.199l-3.712-3.712-12.15 12.15a5.25 5.25 0 0 0-1.32 2.214l-.8 2.685a.75.75 0 0 0 .933.933l2.685-.8a5.25 5.25 0 0 0 2.214-1.32L19.513 8.2Z',\n people:\n 'M15 19.128a9.38 9.38 0 0 0 2.625.372 9.337 9.337 0 0 0 4.121-.952 4.125 4.125 0 0 0-7.533-2.493M15 19.128v-.003c0-1.113-.285-2.16-.786-3.07M15 19.128v.106A12.318 12.318 0 0 1 8.624 21c-2.331 0-4.512-.645-6.374-1.766l-.001-.109a6.375 6.375 0 0 1 11.964-3.07M12 6.375a3.375 3.375 0 1 1-6.75 0 3.375 3.375 0 0 1 6.75 0Zm8.25 2.25a2.625 2.625 0 1 1-5.25 0 2.625 2.625 0 0 1 5.25 0Z',\n phone:\n 'M2.25 6.75c0 8.284 6.716 15 15 15h2.25a2.25 2.25 0 0 0 2.25-2.25v-1.372c0-.516-.351-.966-.852-1.091l-4.423-1.106c-.44-.11-.902.055-1.173.417l-.97 1.293c-.282.376-.769.542-1.21.38a12.035 12.035 0 0 1-7.143-7.143c-.162-.441.004-.928.38-1.21l1.293-.97c.363-.271.527-.734.417-1.173L6.963 3.102a1.125 1.125 0 0 0-1.091-.852H4.5A2.25 2.25 0 0 0 2.25 4.5v2.25Z',\n plane: {\n filled:\n 'M3.478 2.404a.75.75 0 0 0-.926.941l2.432 7.905H13.5a.75.75 0 0 1 0 1.5H4.984l-2.432 7.905a.75.75 0 0 0 .926.94 60.519 60.519 0 0 0 18.445-8.986.75.75 0 0 0 0-1.218A60.517 60.517 0 0 0 3.478 2.404Z',\n outline:\n 'M6 12 3.269 3.125A59.769 59.769 0 0 1 21.485 12 59.768 59.768 0 0 1 3.27 20.875L5.999 12Zm0 0h7.5',\n },\n plus: 'M12 4.5v15m7.5-7.5h-15',\n search: 'm21 21-5.197-5.197m0 0A7.5 7.5 0 1 0 5.196 5.196a7.5 7.5 0 0 0 10.607 10.607Z',\n success: 'M9 12.75 11.25 15 15 9.75M21 12a9 9 0 1 1-18 0 9 9 0 0 1 18 0Z',\n trash:\n 'm14.74 9-.346 9m-4.788 0L9.26 9m9.968-3.21c.342.052.682.107 1.022.166m-1.022-.165L18.16 19.673a2.25 2.25 0 0 1-2.244 2.077H8.084a2.25 2.25 0 0 1-2.244-2.077L4.772 5.79m14.456 0a48.108 48.108 0 0 0-3.478-.397m-12 .562c.34-.059.68-.114 1.022-.165m0 0a48.11 48.11 0 0 1 3.478-.397m7.5 0v-.916c0-1.18-.91-2.164-2.09-2.201a51.964 51.964 0 0 0-3.32 0c-1.18.037-2.09 1.022-2.09 2.201v.916m7.5 0a48.667 48.667 0 0 0-7.5 0',\n updown: 'M8.25 15 12 18.75 15.75 15m-7.5-6L12 5.25 15.75 9',\n upload:\n 'M3 16.5v2.25A2.25 2.25 0 0 0 5.25 21h13.5A2.25 2.25 0 0 0 21 18.75V16.5m-13.5-9L12 3m0 0 4.5 4.5M12 3v13.5',\n user: 'M15.75 6a3.75 3.75 0 1 1-7.5 0 3.75 3.75 0 0 1 7.5 0ZM4.501 20.118a7.5 7.5 0 0 1 14.998 0A17.933 17.933 0 0 1 12 21.75c-2.676 0-5.216-.584-7.499-1.632Z',\n x: 'M6 18 18 6M6 6l12 12',\n};\n\nexport function embedSVG(iconPath: string, fill?: boolean): string {\n return `url(\"data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' fill='${fill ? 'currentColor' : 'none'}' viewBox='0 0 24 24' stroke-width='1.5' stroke='${fill ? 'none' : 'currentColor'}'%3E%3Cpath stroke-linecap='round' stroke-linejoin='round' d='${iconPath}' /%3E%3C/svg%3E%0A\")`;\n}\n\nexport const iconSVG = (name: IconName, fill = false) => {\n const icon = iconPaths[name];\n const path = typeof icon === 'string' ? icon : fill ? icon.filled : icon.outline;\n const hasFilled = fill && typeof icon === 'object' && !!icon.filled;\n\n return embedSVG(path, hasFilled);\n};\n"],"names":["iconPaths","bold","buildings","card","check","chevron","clipboard","filled","outline","document","error","gear","goTo","home","image","info","italic","link","list","megaphone","menu","mobile","pencil","people","phone","plane","plus","search","success","trash","updown","upload","user","x","embedSVG","iconPath","fill","iconSVG","name","icon","path","hasFilled"],"mappings":"AAEO,MAAMA,IAAY;AAAA,EACvBC,MAAM;AAAA,EACNC,WACE;AAAA,EACFC,MAAM;AAAA,EACNC,OAAO;AAAA,EACPC,SAAS;AAAA,EACTC,WAAW;AAAA,IACTC,QACE;AAAA,IACFC,SACE;AAAA,EAAA;AAAA,EAEJC,UACE;AAAA,EACFC,OACE;AAAA,EACFC,MAAM;AAAA,EACNC,MAAM;AAAA,EACNC,MAAM;AAAA,EACNC,OACE;AAAA,EACFC,MAAM;AAAA,EACNC,QAAQ;AAAA,EACRC,MAAM;AAAA,EACNC,MAAM;AAAA,EACNC,WAAW;AAAA,IACTZ,QACE;AAAA,IACFC,SAAS;AAAA,EAAA;AAAA,EAEXY,MAAM;AAAA,EACNC,QACE;AAAA,EACFC,QACE;AAAA,EACFC,QACE;AAAA,EACFC,OACE;AAAA,EACFC,OAAO;AAAA,IACLlB,QACE;AAAA,IACFC,SACE;AAAA,EAAA;AAAA,EAEJkB,MAAM;AAAA,EACNC,QAAQ;AAAA,EACRC,SAAS;AAAA,EACTC,OACE;AAAA,EACFC,QAAQ;AAAA,EACRC,QACE;AAAA,EACFC,MAAM;AAAA,EACNC,GAAG;AACL;AAEO,SAASC,EAASC,GAAkBC,GAAwB;AACjE,SAAO,2EAA2EA,IAAO,iBAAiB,MAAM,oDAAoDA,IAAO,SAAS,cAAc,iEAAiED,CAAQ;AAC7Q;AAEO,MAAME,IAAUA,CAACC,GAAgBF,IAAO,OAAU;AACvD,QAAMG,IAAOvC,EAAUsC,CAAI,GACrBE,IAAO,OAAOD,KAAS,WAAWA,IAAOH,IAAOG,EAAKhC,SAASgC,EAAK/B,SACnEiC,IAAYL,KAAQ,OAAOG,KAAS,YAAY,CAAC,CAACA,EAAKhC;AAE7D,SAAO2B,EAASM,GAAMC,CAAS;AACjC;"}
|
|
@@ -1,34 +1,41 @@
|
|
|
1
|
-
import { jsxs as
|
|
1
|
+
import { jsxs as i, jsx as n } from "react/jsx-runtime";
|
|
2
2
|
import { t as l } from "./classix-DG18itHa.js";
|
|
3
|
-
import {
|
|
4
|
-
import
|
|
5
|
-
|
|
6
|
-
|
|
3
|
+
import { i as b } from "./icons-DfmpRbxE.js";
|
|
4
|
+
import { u as f, r as v } from "./utils-BFlnRYx7.js";
|
|
5
|
+
import './assets/index41.css';const y = /* @__PURE__ */ new Set(["aria-activedescendant", "aria-autocomplete", "aria-busy", "aria-controls", "aria-describedby", "aria-details", "aria-disabled", "aria-errormessage", "aria-expanded", "aria-haspopup", "aria-hidden", "aria-invalid", "aria-keyshortcuts", "aria-label", "aria-labelledby", "aria-live", "aria-owns", "aria-required", "aria-roledescription", "autoComplete", "autoFocus", "className", "defaultValue", "dir", "disabled", "form", "id", "multiple", "name", "onBlur", "onChange", "onClick", "onFocus", "onInput", "onInvalid", "onKeyDown", "onKeyUp", "onMouseDown", "onMouseUp", "onPointerDown", "onPointerUp", "required", "role", "size", "style", "tabIndex", "title", "value"]);
|
|
6
|
+
function _(a) {
|
|
7
|
+
return Object.fromEntries(Object.entries(a).filter(([e]) => e.startsWith("data-") || e.startsWith("aria-") || y.has(e)));
|
|
7
8
|
}
|
|
8
|
-
const
|
|
9
|
-
select:
|
|
10
|
-
label:
|
|
11
|
-
required:
|
|
12
|
-
},
|
|
9
|
+
const q = "_select_1gu7m_1", g = "_label_1gu7m_24", w = "_required_1gu7m_28", t = {
|
|
10
|
+
select: q,
|
|
11
|
+
label: g,
|
|
12
|
+
required: w
|
|
13
|
+
}, j = ({
|
|
13
14
|
children: a,
|
|
14
15
|
label: e,
|
|
15
|
-
placeholder:
|
|
16
|
+
placeholder: o,
|
|
16
17
|
...r
|
|
17
18
|
}) => {
|
|
18
19
|
const {
|
|
19
20
|
touched: c,
|
|
20
|
-
onBlur:
|
|
21
|
-
} =
|
|
22
|
-
|
|
21
|
+
onBlur: u
|
|
22
|
+
} = f(r.value === ""), d = _(r), {
|
|
23
|
+
style: m,
|
|
24
|
+
...p
|
|
25
|
+
} = d, h = {
|
|
26
|
+
...m,
|
|
27
|
+
"--icon-svg": b("chevron").replace("currentColor", v("--color-icon"))
|
|
28
|
+
}, s = /* @__PURE__ */ i("select", { className: l(t.select, c && "touched"), onBlur: u, style: h, ...p, children: [
|
|
29
|
+
o && /* @__PURE__ */ n("option", { value: "", hidden: !0, children: o }, "placeholder"),
|
|
23
30
|
a
|
|
24
31
|
] });
|
|
25
|
-
return e ? /* @__PURE__ */
|
|
32
|
+
return e ? /* @__PURE__ */ i("label", { "data-component": "select", children: [
|
|
26
33
|
/* @__PURE__ */ n("span", { className: l(t.label, r.required && t.required), children: e }),
|
|
27
34
|
s
|
|
28
35
|
] }) : s;
|
|
29
36
|
};
|
|
30
37
|
export {
|
|
31
|
-
|
|
32
|
-
|
|
38
|
+
j as S,
|
|
39
|
+
_ as s
|
|
33
40
|
};
|
|
34
|
-
//# sourceMappingURL=index-
|
|
41
|
+
//# sourceMappingURL=index-C_OgUYu-.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index-C_OgUYu-.js","sources":["../src/components/select/sanitizeSelectProps.ts","../src/components/select/index.tsx"],"sourcesContent":["const selectKeys = new Set([\n 'aria-activedescendant',\n 'aria-autocomplete',\n 'aria-busy',\n 'aria-controls',\n 'aria-describedby',\n 'aria-details',\n 'aria-disabled',\n 'aria-errormessage',\n 'aria-expanded',\n 'aria-haspopup',\n 'aria-hidden',\n 'aria-invalid',\n 'aria-keyshortcuts',\n 'aria-label',\n 'aria-labelledby',\n 'aria-live',\n 'aria-owns',\n 'aria-required',\n 'aria-roledescription',\n 'autoComplete',\n 'autoFocus',\n 'className',\n 'defaultValue',\n 'dir',\n 'disabled',\n 'form',\n 'id',\n 'multiple',\n 'name',\n 'onBlur',\n 'onChange',\n 'onClick',\n 'onFocus',\n 'onInput',\n 'onInvalid',\n 'onKeyDown',\n 'onKeyUp',\n 'onMouseDown',\n 'onMouseUp',\n 'onPointerDown',\n 'onPointerUp',\n 'required',\n 'role',\n 'size',\n 'style',\n 'tabIndex',\n 'title',\n 'value',\n]);\n\nexport function sanitizeSelectProps<T extends Record<string, unknown>>(props: T) {\n return Object.fromEntries(\n Object.entries(props).filter(\n ([key]) => key.startsWith('data-') || key.startsWith('aria-') || selectKeys.has(key)\n )\n ) as Partial<T>;\n}\n","import cx from 'classix';\n\nimport { iconSVG } from '@/components/icon/icons.ts';\nimport { resolveColor, useTouched } from '@/utils.ts';\n\nimport { sanitizeSelectProps } from './sanitizeSelectProps';\nimport styles from './styles.module.css';\n\nexport type SelectProps = React.SelectHTMLAttributes<HTMLSelectElement> & {\n children: React.ReactNode;\n label?: string;\n placeholder?: string;\n};\n\ntype withVars = React.CSSProperties & {\n '--icon-svg'?: string;\n};\n\nexport const Select = ({ children, label, placeholder, ...props }: SelectProps) => {\n const { touched, onBlur } = useTouched(props.value === '');\n const selectProps = sanitizeSelectProps(props);\n const { style, ...restSelectProps } = selectProps;\n const withVars = {\n ...style,\n '--icon-svg': iconSVG('chevron').replace('currentColor', resolveColor('--color-icon')),\n } satisfies withVars;\n\n const selectElement = (\n <select\n className={cx(styles.select, touched && 'touched')}\n onBlur={onBlur}\n style={withVars}\n {...restSelectProps}\n >\n {placeholder && (\n <option\n key='placeholder'\n value={''}\n hidden\n >\n {placeholder}\n </option>\n )}\n {children}\n </select>\n );\n\n if (!label) {\n return selectElement;\n }\n\n return (\n <label>\n <span className={cx(styles.label, props.required && styles.required)}>{label}</span>\n {selectElement}\n </label>\n );\n};\n"],"names":["selectKeys","Set","sanitizeSelectProps","props","Object","fromEntries","entries","filter","key","startsWith","has","Select","children","label","placeholder","touched","onBlur","useTouched","value","selectProps","style","restSelectProps","withVars","iconSVG","replace","resolveColor","selectElement","jsxs","cx","styles","select","jsx","required"],"mappings":";;;;AAAA,MAAMA,IAAa,oBAAIC,IAAI,CACzB,yBACA,qBACA,aACA,iBACA,oBACA,gBACA,iBACA,qBACA,iBACA,iBACA,eACA,gBACA,qBACA,cACA,mBACA,aACA,aACA,iBACA,wBACA,gBACA,aACA,aACA,gBACA,OACA,YACA,QACA,MACA,YACA,QACA,UACA,YACA,WACA,WACA,WACA,aACA,aACA,WACA,eACA,aACA,iBACA,eACA,YACA,QACA,QACA,SACA,YACA,SACA,OAAO,CACR;AAEM,SAASC,EAAuDC,GAAU;AAC/E,SAAOC,OAAOC,YACZD,OAAOE,QAAQH,CAAK,EAAEI,OACpB,CAAC,CAACC,CAAG,MAAMA,EAAIC,WAAW,OAAO,KAAKD,EAAIC,WAAW,OAAO,KAAKT,EAAWU,IAAIF,CAAG,CACrF,CACF;AACF;;;;;GCvCaG,IAASA,CAAC;AAAA,EAAEC,UAAAA;AAAAA,EAAUC,OAAAA;AAAAA,EAAOC,aAAAA;AAAAA,EAAa,GAAGX;AAAmB,MAAM;AACjF,QAAM;AAAA,IAAEY,SAAAA;AAAAA,IAASC,QAAAA;AAAAA,EAAAA,IAAWC,EAAWd,EAAMe,UAAU,EAAE,GACnDC,IAAcjB,EAAoBC,CAAK,GACvC;AAAA,IAAEiB,OAAAA;AAAAA,IAAO,GAAGC;AAAAA,EAAAA,IAAoBF,GAChCG,IAAW;AAAA,IACf,GAAGF;AAAAA,IACH,cAAcG,EAAQ,SAAS,EAAEC,QAAQ,gBAAgBC,EAAa,cAAc,CAAC;AAAA,EAAA,GAGjFC,IACJ,gBAAAC,EAAC,UAAA,EACC,WAAWC,EAAGC,EAAOC,QAAQf,KAAW,SAAS,GACjD,QAAAC,GACA,OAAOM,GACP,GAAID,GAEHP,UAAAA;AAAAA,IAAAA,uBACE,UAAA,EAEC,OAAO,IACP,QAAM,IAELA,eAJG,aAKN;AAAA,IAEDF;AAAAA,EAAAA,GACH;AAGF,SAAKC,IAKH,gBAAAc,EAAC,SAAA,EAAK,kBAAA,UACJ,UAAA;AAAA,IAAA,gBAAAI,EAAC,QAAA,EAAK,WAAWH,EAAGC,EAAOhB,OAAOV,EAAM6B,YAAYH,EAAOG,QAAQ,GAAInB,UAAAA,EAAAA,CAAM;AAAA,IAC5Ea;AAAAA,EAAAA,GACH,IAPOA;AASX;"}
|
|
@@ -0,0 +1,2 @@
|
|
|
1
|
+
"use strict";require('./assets/index41.css');const t=require("react/jsx-runtime"),n=require("./classix-5H4IWnMA.cjs"),q=require("./icons-C_cX1FYp.cjs"),l=require("./utils-DqVa4K58.cjs"),v=new Set(["aria-activedescendant","aria-autocomplete","aria-busy","aria-controls","aria-describedby","aria-details","aria-disabled","aria-errormessage","aria-expanded","aria-haspopup","aria-hidden","aria-invalid","aria-keyshortcuts","aria-label","aria-labelledby","aria-live","aria-owns","aria-required","aria-roledescription","autoComplete","autoFocus","className","defaultValue","dir","disabled","form","id","multiple","name","onBlur","onChange","onClick","onFocus","onInput","onInvalid","onKeyDown","onKeyUp","onMouseDown","onMouseUp","onPointerDown","onPointerUp","required","role","size","style","tabIndex","title","value"]);function c(r){return Object.fromEntries(Object.entries(r).filter(([e])=>e.startsWith("data-")||e.startsWith("aria-")||v.has(e)))}const y="_select_1gu7m_1",_="_label_1gu7m_24",x="_required_1gu7m_28",s={select:y,label:_,required:x},j=({children:r,label:e,placeholder:i,...a})=>{const{touched:u,onBlur:d}=l.useTouched(a.value===""),h=c(a),{style:m,...p}=h,b={...m,"--icon-svg":q.iconSVG("chevron").replace("currentColor",l.resolveColor("--color-icon"))},o=t.jsxs("select",{className:n.t(s.select,u&&"touched"),onBlur:d,style:b,...p,children:[i&&t.jsx("option",{value:"",hidden:!0,children:i},"placeholder"),r]});return e?t.jsxs("label",{"data-component":"select",children:[t.jsx("span",{className:n.t(s.label,a.required&&s.required),children:e}),o]}):o};exports.Select=j;exports.sanitizeSelectProps=c;
|
|
2
|
+
//# sourceMappingURL=index-CfK1ATlt.cjs.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index-CfK1ATlt.cjs","sources":["../src/components/select/sanitizeSelectProps.ts","../src/components/select/index.tsx"],"sourcesContent":["const selectKeys = new Set([\n 'aria-activedescendant',\n 'aria-autocomplete',\n 'aria-busy',\n 'aria-controls',\n 'aria-describedby',\n 'aria-details',\n 'aria-disabled',\n 'aria-errormessage',\n 'aria-expanded',\n 'aria-haspopup',\n 'aria-hidden',\n 'aria-invalid',\n 'aria-keyshortcuts',\n 'aria-label',\n 'aria-labelledby',\n 'aria-live',\n 'aria-owns',\n 'aria-required',\n 'aria-roledescription',\n 'autoComplete',\n 'autoFocus',\n 'className',\n 'defaultValue',\n 'dir',\n 'disabled',\n 'form',\n 'id',\n 'multiple',\n 'name',\n 'onBlur',\n 'onChange',\n 'onClick',\n 'onFocus',\n 'onInput',\n 'onInvalid',\n 'onKeyDown',\n 'onKeyUp',\n 'onMouseDown',\n 'onMouseUp',\n 'onPointerDown',\n 'onPointerUp',\n 'required',\n 'role',\n 'size',\n 'style',\n 'tabIndex',\n 'title',\n 'value',\n]);\n\nexport function sanitizeSelectProps<T extends Record<string, unknown>>(props: T) {\n return Object.fromEntries(\n Object.entries(props).filter(\n ([key]) => key.startsWith('data-') || key.startsWith('aria-') || selectKeys.has(key)\n )\n ) as Partial<T>;\n}\n","import cx from 'classix';\n\nimport { iconSVG } from '@/components/icon/icons.ts';\nimport { resolveColor, useTouched } from '@/utils.ts';\n\nimport { sanitizeSelectProps } from './sanitizeSelectProps';\nimport styles from './styles.module.css';\n\nexport type SelectProps = React.SelectHTMLAttributes<HTMLSelectElement> & {\n children: React.ReactNode;\n label?: string;\n placeholder?: string;\n};\n\ntype withVars = React.CSSProperties & {\n '--icon-svg'?: string;\n};\n\nexport const Select = ({ children, label, placeholder, ...props }: SelectProps) => {\n const { touched, onBlur } = useTouched(props.value === '');\n const selectProps = sanitizeSelectProps(props);\n const { style, ...restSelectProps } = selectProps;\n const withVars = {\n ...style,\n '--icon-svg': iconSVG('chevron').replace('currentColor', resolveColor('--color-icon')),\n } satisfies withVars;\n\n const selectElement = (\n <select\n className={cx(styles.select, touched && 'touched')}\n onBlur={onBlur}\n style={withVars}\n {...restSelectProps}\n >\n {placeholder && (\n <option\n key='placeholder'\n value={''}\n hidden\n >\n {placeholder}\n </option>\n )}\n {children}\n </select>\n );\n\n if (!label) {\n return selectElement;\n }\n\n return (\n <label>\n <span className={cx(styles.label, props.required && styles.required)}>{label}</span>\n {selectElement}\n </label>\n );\n};\n"],"names":["selectKeys","Set","sanitizeSelectProps","props","Object","fromEntries","entries","filter","key","startsWith","has","Select","children","label","placeholder","touched","onBlur","useTouched","value","selectProps","style","restSelectProps","withVars","iconSVG","replace","resolveColor","selectElement","jsxs","cx","styles","select","jsx","required"],"mappings":"0JAAMA,EAAa,IAAIC,IAAI,CACzB,wBACA,oBACA,YACA,gBACA,mBACA,eACA,gBACA,oBACA,gBACA,gBACA,cACA,eACA,oBACA,aACA,kBACA,YACA,YACA,gBACA,uBACA,eACA,YACA,YACA,eACA,MACA,WACA,OACA,KACA,WACA,OACA,SACA,WACA,UACA,UACA,UACA,YACA,YACA,UACA,cACA,YACA,gBACA,cACA,WACA,OACA,OACA,QACA,WACA,QACA,OAAO,CACR,EAEM,SAASC,EAAuDC,EAAU,CAC/E,OAAOC,OAAOC,YACZD,OAAOE,QAAQH,CAAK,EAAEI,OACpB,CAAC,CAACC,CAAG,IAAMA,EAAIC,WAAW,OAAO,GAAKD,EAAIC,WAAW,OAAO,GAAKT,EAAWU,IAAIF,CAAG,CACrF,CACF,CACF,sGCvCaG,EAASA,CAAC,CAAEC,SAAAA,EAAUC,MAAAA,EAAOC,YAAAA,EAAa,GAAGX,CAAmB,IAAM,CACjF,KAAM,CAAEY,QAAAA,EAASC,OAAAA,CAAAA,EAAWC,aAAWd,EAAMe,QAAU,EAAE,EACnDC,EAAcjB,EAAoBC,CAAK,EACvC,CAAEiB,MAAAA,EAAO,GAAGC,CAAAA,EAAoBF,EAChCG,EAAW,CACf,GAAGF,EACH,aAAcG,EAAAA,QAAQ,SAAS,EAAEC,QAAQ,eAAgBC,EAAAA,aAAa,cAAc,CAAC,CAAA,EAGjFC,EACJC,EAAAA,KAAC,SAAA,CACC,UAAWC,EAAAA,EAAGC,EAAOC,OAAQf,GAAW,SAAS,EACjD,OAAAC,EACA,MAAOM,EACP,GAAID,EAEHP,SAAAA,CAAAA,SACE,SAAA,CAEC,MAAO,GACP,OAAM,GAELA,YAJG,aAKN,EAEDF,CAAAA,EACH,EAGF,OAAKC,EAKHc,EAAAA,KAAC,QAAA,CAAK,iBAAA,SACJ,SAAA,CAAAI,EAAAA,IAAC,OAAA,CAAK,UAAWH,EAAAA,EAAGC,EAAOhB,MAAOV,EAAM6B,UAAYH,EAAOG,QAAQ,EAAInB,SAAAA,CAAAA,CAAM,EAC5Ea,CAAAA,EACH,EAPOA,CASX"}
|
package/dist/index.cjs
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});require('./assets/index.css');const e=require("./components/_avatar/index.cjs"),n=require("./components/_card/index.cjs"),o=require("./components/_collapsible/index.cjs"),r=require("./components/_croppable/index.cjs"),t=require("./components/_dropdown/index.cjs"),i=require("./components/_dropzone/index.cjs"),s=require("./components/_editor/index.cjs"),c=require("./components/_messages/index.cjs"),_=require("./components/_portal/index.cjs"),a=require("./components/_sortable/index.cjs"),d=require("./components/_toasts/index.cjs"),p=require("./components/_widget/index.cjs"),u=require("./components/accordion/index.cjs"),m=require("./components/app-link/index.cjs"),x=require("./components/aside/index.cjs"),l=require("./components/badge/index.cjs"),q=require("./components/banner/index.cjs"),g=require("./components/branding/index.cjs"),b=require("./components/button/index.cjs"),T=require("./components/checkbox/index.cjs"),L=require("./components/controls/index.cjs"),C=require("./components/dialog/index.cjs"),k=require("./components/figure/index.cjs"),A=require("./components/file/index.cjs"),B=require("./components/footer/index.cjs"),F=require("./components/form/index.cjs"),h=require("./components/graph/index.cjs"),v=require("./components/group/index.cjs"),D=require("./components/header/index.cjs"),I=require("./components/icon/index.cjs"),S=require("./components/image/index.cjs"),f=require("./components/input/index.cjs"),y=require("./components/layout/index.cjs"),M=require("./components/link/index.cjs"),w=require("./components/list/index.cjs"),G=require("./components/loading/index.cjs"),z=require("./components/message/index.cjs"),P=require("./components/nav/index.cjs"),E=require("./index-
|
|
1
|
+
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});require('./assets/index.css');const e=require("./components/_avatar/index.cjs"),n=require("./components/_card/index.cjs"),o=require("./components/_collapsible/index.cjs"),r=require("./components/_croppable/index.cjs"),t=require("./components/_dropdown/index.cjs"),i=require("./components/_dropzone/index.cjs"),s=require("./components/_editor/index.cjs"),c=require("./components/_messages/index.cjs"),_=require("./components/_portal/index.cjs"),a=require("./components/_sortable/index.cjs"),d=require("./components/_toasts/index.cjs"),p=require("./components/_widget/index.cjs"),u=require("./components/accordion/index.cjs"),m=require("./components/app-link/index.cjs"),x=require("./components/aside/index.cjs"),l=require("./components/badge/index.cjs"),q=require("./components/banner/index.cjs"),g=require("./components/branding/index.cjs"),b=require("./components/button/index.cjs"),T=require("./components/checkbox/index.cjs"),L=require("./components/controls/index.cjs"),C=require("./components/dialog/index.cjs"),k=require("./components/figure/index.cjs"),A=require("./components/file/index.cjs"),B=require("./components/footer/index.cjs"),F=require("./components/form/index.cjs"),h=require("./components/graph/index.cjs"),v=require("./components/group/index.cjs"),D=require("./components/header/index.cjs"),I=require("./components/icon/index.cjs"),S=require("./components/image/index.cjs"),f=require("./components/input/index.cjs"),y=require("./components/layout/index.cjs"),M=require("./components/link/index.cjs"),w=require("./components/list/index.cjs"),G=require("./components/loading/index.cjs"),z=require("./components/message/index.cjs"),P=require("./components/nav/index.cjs"),E=require("./index-CfK1ATlt.cjs"),H=require("./components/table/index.cjs"),N=require("./components/textarea/index.cjs"),W=require("./components/toast/index.cjs"),j=require("./components/toggle/index.cjs"),O=require("./components/toolbar/index.cjs");exports.Avatar=e.Avatar;exports.Card=n.Card;exports.Collapsible=o.Collapsible;exports.Croppable=r.Croppable;exports.Dropdown=t.Dropdown;exports.Dropzone=i.Dropzone;exports.Editor=s.Editor;exports.Messages=c.Messages;exports.Portal=_.Portal;exports.Sortable=a.Sortable;exports.Toasts=d.Toasts;exports.Widget=p.Widget;exports.Accordion=u.Accordion;exports.AppLink=m.AppLink;exports.Aside=x.Aside;exports.Badge=l.Badge;exports.Banner=q.Banner;exports.Branding=g.Branding;exports.Button=b.Button;exports.Checkbox=T.Checkbox;exports.Controls=L.Controls;exports.Dialog=C.Dialog;exports.Figure=k.Figure;exports.File=A.File;exports.Footer=B.Footer;exports.Form=F.Form;exports.Graph=h.Graph;exports.Group=v.Group;exports.Header=D.Header;exports.Icon=I.Icon;exports.Image=S.Image;exports.Input=f.Input;exports.Layout=y.Layout;exports.Link=M.Link;exports.List=w.List;exports.Loading=G.Loading;exports.Message=z.Message;exports.Nav=P.Nav;exports.Select=E.Select;exports.Table=H.Table;exports.Textarea=N.Textarea;exports.Toast=W.Toast;exports.Toggle=j.Toggle;exports.Toolbar=O.Toolbar;
|
|
2
2
|
//# sourceMappingURL=index.cjs.map
|
package/dist/index.js
CHANGED
|
@@ -36,7 +36,7 @@ import { List as co } from "./components/list/index.js";
|
|
|
36
36
|
import { Loading as Co } from "./components/loading/index.js";
|
|
37
37
|
import { Message as Ao } from "./components/message/index.js";
|
|
38
38
|
import { Nav as Fo } from "./components/nav/index.js";
|
|
39
|
-
import { S as Do } from "./index-
|
|
39
|
+
import { S as Do } from "./index-C_OgUYu-.js";
|
|
40
40
|
import { Table as So } from "./components/table/index.js";
|
|
41
41
|
import { Textarea as vo } from "./components/textarea/index.js";
|
|
42
42
|
import { Toast as Mo } from "./components/toast/index.js";
|
|
@@ -0,0 +1,34 @@
|
|
|
1
|
+
import { useState as d, useCallback as f, useEffect as m } from "react";
|
|
2
|
+
function b(o, n = "currentColor") {
|
|
3
|
+
var l;
|
|
4
|
+
const r = /^--[\w-]+$/, u = /^var\(\s*(--[\w-]+)\s*(?:,\s*(.+))?\)$/;
|
|
5
|
+
if (typeof document > "u")
|
|
6
|
+
return n;
|
|
7
|
+
const i = getComputedStyle(document.documentElement), c = /* @__PURE__ */ new Set();
|
|
8
|
+
let e = o.trim();
|
|
9
|
+
for (; e; ) {
|
|
10
|
+
const t = e.match(u), s = (t == null ? void 0 : t[1]) ?? (r.test(e) ? e : null), a = (l = t == null ? void 0 : t[2]) == null ? void 0 : l.trim();
|
|
11
|
+
if (!s)
|
|
12
|
+
return e;
|
|
13
|
+
if (c.has(s)) {
|
|
14
|
+
e = a ?? "";
|
|
15
|
+
continue;
|
|
16
|
+
}
|
|
17
|
+
c.add(s), e = i.getPropertyValue(s).trim() || a || "";
|
|
18
|
+
}
|
|
19
|
+
return n;
|
|
20
|
+
}
|
|
21
|
+
function w(o) {
|
|
22
|
+
const [n, r] = d(!1), u = f(() => r(!0), []);
|
|
23
|
+
return m(() => {
|
|
24
|
+
r(!1);
|
|
25
|
+
}, [o]), {
|
|
26
|
+
touched: n,
|
|
27
|
+
onBlur: u
|
|
28
|
+
};
|
|
29
|
+
}
|
|
30
|
+
export {
|
|
31
|
+
b as r,
|
|
32
|
+
w as u
|
|
33
|
+
};
|
|
34
|
+
//# sourceMappingURL=utils-BFlnRYx7.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"utils-BFlnRYx7.js","sources":["../src/utils.ts"],"sourcesContent":["import { useCallback, useEffect, useState } from 'react';\n\nexport function resolveColor(input: `--${string}` | string, fallback = 'currentColor'): string {\n const cssVariablePattern = /^--[\\w-]+$/;\n const cssVariableReferencePattern = /^var\\(\\s*(--[\\w-]+)\\s*(?:,\\s*(.+))?\\)$/;\n\n if (typeof document === 'undefined') {\n return fallback;\n }\n\n const styles = getComputedStyle(document.documentElement);\n const seen = new Set<string>();\n let current = input.trim();\n\n while (current) {\n const match = current.match(cssVariableReferencePattern);\n const variableName = match?.[1] ?? (cssVariablePattern.test(current) ? current : null);\n const nestedFallback = match?.[2]?.trim();\n\n if (!variableName) {\n return current;\n }\n\n if (seen.has(variableName)) {\n current = nestedFallback ?? '';\n continue;\n }\n\n seen.add(variableName);\n\n current = styles.getPropertyValue(variableName).trim() || nestedFallback || '';\n }\n\n return fallback;\n}\n\nexport function useTouched(resetKey?: unknown) {\n const [touched, setTouched] = useState(false);\n const onBlur = useCallback(() => setTouched(true), []);\n\n useEffect(() => {\n setTouched(false);\n }, [resetKey]);\n\n return { touched, onBlur };\n}\n"],"names":["resolveColor","input","fallback","cssVariablePattern","cssVariableReferencePattern","document","styles","getComputedStyle","documentElement","seen","Set","current","trim","match","variableName","test","nestedFallback","has","add","getPropertyValue","useTouched","resetKey","touched","setTouched","useState","onBlur","useCallback","useEffect"],"mappings":";AAEO,SAASA,EAAaC,GAA+BC,IAAW,gBAAwB;;AAC7F,QAAMC,IAAqB,cACrBC,IAA8B;AAEpC,MAAI,OAAOC,WAAa;AACtB,WAAOH;AAGT,QAAMI,IAASC,iBAAiBF,SAASG,eAAe,GAClDC,wBAAWC,IAAAA;AACjB,MAAIC,IAAUV,EAAMW,KAAAA;AAEpB,SAAOD,KAAS;AACd,UAAME,IAAQF,EAAQE,MAAMT,CAA2B,GACjDU,KAAeD,KAAAA,gBAAAA,EAAQ,QAAOV,EAAmBY,KAAKJ,CAAO,IAAIA,IAAU,OAC3EK,KAAiBH,IAAAA,KAAAA,gBAAAA,EAAQ,OAARA,gBAAAA,EAAYD;AAEnC,QAAI,CAACE;AACH,aAAOH;AAGT,QAAIF,EAAKQ,IAAIH,CAAY,GAAG;AAC1BH,MAAAA,IAAUK,KAAkB;AAC5B;AAAA,IACF;AAEAP,IAAAA,EAAKS,IAAIJ,CAAY,GAErBH,IAAUL,EAAOa,iBAAiBL,CAAY,EAAEF,KAAAA,KAAUI,KAAkB;AAAA,EAC9E;AAEA,SAAOd;AACT;AAEO,SAASkB,EAAWC,GAAoB;AAC7C,QAAM,CAACC,GAASC,CAAU,IAAIC,EAAS,EAAK,GACtCC,IAASC,EAAY,MAAMH,EAAW,EAAI,GAAG,CAAA,CAAE;AAErDI,SAAAA,EAAU,MAAM;AACdJ,IAAAA,EAAW,EAAK;AAAA,EAClB,GAAG,CAACF,CAAQ,CAAC,GAEN;AAAA,IAAEC,SAAAA;AAAAA,IAASG,QAAAA;AAAAA,EAAAA;AACpB;"}
|
|
@@ -0,0 +1,2 @@
|
|
|
1
|
+
"use strict";const c=require("react");function f(o,n="currentColor"){var a;const s=/^--[\w-]+$/,u=/^var\(\s*(--[\w-]+)\s*(?:,\s*(.+))?\)$/;if(typeof document>"u")return n;const d=getComputedStyle(document.documentElement),l=new Set;let e=o.trim();for(;e;){const t=e.match(u),r=(t==null?void 0:t[1])??(s.test(e)?e:null),i=(a=t==null?void 0:t[2])==null?void 0:a.trim();if(!r)return e;if(l.has(r)){e=i??"";continue}l.add(r),e=d.getPropertyValue(r).trim()||i||""}return n}function m(o){const[n,s]=c.useState(!1),u=c.useCallback(()=>s(!0),[]);return c.useEffect(()=>{s(!1)},[o]),{touched:n,onBlur:u}}exports.resolveColor=f;exports.useTouched=m;
|
|
2
|
+
//# sourceMappingURL=utils-DqVa4K58.cjs.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"utils-DqVa4K58.cjs","sources":["../src/utils.ts"],"sourcesContent":["import { useCallback, useEffect, useState } from 'react';\n\nexport function resolveColor(input: `--${string}` | string, fallback = 'currentColor'): string {\n const cssVariablePattern = /^--[\\w-]+$/;\n const cssVariableReferencePattern = /^var\\(\\s*(--[\\w-]+)\\s*(?:,\\s*(.+))?\\)$/;\n\n if (typeof document === 'undefined') {\n return fallback;\n }\n\n const styles = getComputedStyle(document.documentElement);\n const seen = new Set<string>();\n let current = input.trim();\n\n while (current) {\n const match = current.match(cssVariableReferencePattern);\n const variableName = match?.[1] ?? (cssVariablePattern.test(current) ? current : null);\n const nestedFallback = match?.[2]?.trim();\n\n if (!variableName) {\n return current;\n }\n\n if (seen.has(variableName)) {\n current = nestedFallback ?? '';\n continue;\n }\n\n seen.add(variableName);\n\n current = styles.getPropertyValue(variableName).trim() || nestedFallback || '';\n }\n\n return fallback;\n}\n\nexport function useTouched(resetKey?: unknown) {\n const [touched, setTouched] = useState(false);\n const onBlur = useCallback(() => setTouched(true), []);\n\n useEffect(() => {\n setTouched(false);\n }, [resetKey]);\n\n return { touched, onBlur };\n}\n"],"names":["resolveColor","input","fallback","cssVariablePattern","cssVariableReferencePattern","document","styles","getComputedStyle","documentElement","seen","Set","current","trim","match","variableName","test","nestedFallback","has","add","getPropertyValue","useTouched","resetKey","touched","setTouched","useState","onBlur","useCallback","useEffect"],"mappings":"sCAEO,SAASA,EAAaC,EAA+BC,EAAW,eAAwB,OAC7F,MAAMC,EAAqB,aACrBC,EAA8B,yCAEpC,GAAI,OAAOC,SAAa,IACtB,OAAOH,EAGT,MAAMI,EAASC,iBAAiBF,SAASG,eAAe,EAClDC,MAAWC,IACjB,IAAIC,EAAUV,EAAMW,KAAAA,EAEpB,KAAOD,GAAS,CACd,MAAME,EAAQF,EAAQE,MAAMT,CAA2B,EACjDU,GAAeD,GAAAA,YAAAA,EAAQ,MAAOV,EAAmBY,KAAKJ,CAAO,EAAIA,EAAU,MAC3EK,GAAiBH,EAAAA,GAAAA,YAAAA,EAAQ,KAARA,YAAAA,EAAYD,OAEnC,GAAI,CAACE,EACH,OAAOH,EAGT,GAAIF,EAAKQ,IAAIH,CAAY,EAAG,CAC1BH,EAAUK,GAAkB,GAC5B,QACF,CAEAP,EAAKS,IAAIJ,CAAY,EAErBH,EAAUL,EAAOa,iBAAiBL,CAAY,EAAEF,KAAAA,GAAUI,GAAkB,EAC9E,CAEA,OAAOd,CACT,CAEO,SAASkB,EAAWC,EAAoB,CAC7C,KAAM,CAACC,EAASC,CAAU,EAAIC,EAAAA,SAAS,EAAK,EACtCC,EAASC,EAAAA,YAAY,IAAMH,EAAW,EAAI,EAAG,CAAA,CAAE,EAErDI,OAAAA,EAAAA,UAAU,IAAM,CACdJ,EAAW,EAAK,CAClB,EAAG,CAACF,CAAQ,CAAC,EAEN,CAAEC,QAAAA,EAASG,OAAAA,CAAAA,CACpB"}
|
package/package.json
CHANGED
package/dist/index-HNd9cEc6.cjs
DELETED
|
@@ -1,2 +0,0 @@
|
|
|
1
|
-
"use strict";require('./assets/index41.css');const a=require("react/jsx-runtime"),l=require("./classix-5H4IWnMA.cjs"),m=require("./utils-D_TJ8wDc.cjs"),b=new Set(["aria-activedescendant","aria-autocomplete","aria-busy","aria-controls","aria-describedby","aria-details","aria-disabled","aria-errormessage","aria-expanded","aria-haspopup","aria-hidden","aria-invalid","aria-keyshortcuts","aria-label","aria-labelledby","aria-live","aria-owns","aria-required","aria-roledescription","autoComplete","autoFocus","className","defaultValue","dir","disabled","form","id","multiple","name","onBlur","onChange","onClick","onFocus","onInput","onInvalid","onKeyDown","onKeyUp","onMouseDown","onMouseUp","onPointerDown","onPointerUp","required","role","size","style","tabIndex","title","value"]);function o(t){return Object.fromEntries(Object.entries(t).filter(([e])=>e.startsWith("data-")||e.startsWith("aria-")||b.has(e)))}const h="_select_10mqf_1",p="_label_10mqf_21",q="_required_10mqf_25",r={select:h,label:p,required:q},f=({children:t,label:e,placeholder:i,...s})=>{const{touched:c,onBlur:u}=m.useTouched(s.value===""),d=o(s),n=a.jsxs("select",{className:l.t(r.select,c&&"touched"),onBlur:u,...d,children:[i&&a.jsx("option",{value:"",hidden:!0,children:i}),t]});return e?a.jsxs("label",{"data-component":"select",children:[a.jsx("span",{className:l.t(r.label,s.required&&r.required),children:e}),n]}):n};exports.Select=f;exports.sanitizeSelectProps=o;
|
|
2
|
-
//# sourceMappingURL=index-HNd9cEc6.cjs.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"index-HNd9cEc6.cjs","sources":["../src/components/select/sanitizeSelectProps.ts","../src/components/select/index.tsx"],"sourcesContent":["const selectKeys = new Set([\n 'aria-activedescendant',\n 'aria-autocomplete',\n 'aria-busy',\n 'aria-controls',\n 'aria-describedby',\n 'aria-details',\n 'aria-disabled',\n 'aria-errormessage',\n 'aria-expanded',\n 'aria-haspopup',\n 'aria-hidden',\n 'aria-invalid',\n 'aria-keyshortcuts',\n 'aria-label',\n 'aria-labelledby',\n 'aria-live',\n 'aria-owns',\n 'aria-required',\n 'aria-roledescription',\n 'autoComplete',\n 'autoFocus',\n 'className',\n 'defaultValue',\n 'dir',\n 'disabled',\n 'form',\n 'id',\n 'multiple',\n 'name',\n 'onBlur',\n 'onChange',\n 'onClick',\n 'onFocus',\n 'onInput',\n 'onInvalid',\n 'onKeyDown',\n 'onKeyUp',\n 'onMouseDown',\n 'onMouseUp',\n 'onPointerDown',\n 'onPointerUp',\n 'required',\n 'role',\n 'size',\n 'style',\n 'tabIndex',\n 'title',\n 'value',\n]);\n\nexport function sanitizeSelectProps<T extends Record<string, unknown>>(props: T) {\n return Object.fromEntries(\n Object.entries(props).filter(\n ([key]) => key.startsWith('data-') || key.startsWith('aria-') || selectKeys.has(key)\n )\n ) as Partial<T>;\n}\n","import cx from 'classix';\n\nimport { useTouched } from '@/utils.ts';\n\nimport { sanitizeSelectProps } from './sanitizeSelectProps';\nimport styles from './styles.module.css';\n\nexport type SelectProps = React.SelectHTMLAttributes<HTMLSelectElement> & {\n children: React.ReactNode;\n label?: string;\n placeholder?: string;\n};\n\nexport const Select = ({ children, label, placeholder, ...props }: SelectProps) => {\n const { touched, onBlur } = useTouched(props.value === '');\n const selectProps = sanitizeSelectProps(props);\n\n const selectElement = (\n <select\n className={cx(styles.select, touched && 'touched')}\n onBlur={onBlur}\n {...selectProps}\n >\n {placeholder && (\n <option\n value={''}\n hidden\n >\n {placeholder}\n </option>\n )}\n {children}\n </select>\n );\n\n if (!label) {\n return selectElement;\n }\n\n return (\n <label>\n <span className={cx(styles.label, props.required && styles.required)}>{label}</span>\n {selectElement}\n </label>\n );\n};\n"],"names":["selectKeys","Set","sanitizeSelectProps","props","Object","fromEntries","entries","filter","key","startsWith","has","Select","children","label","placeholder","touched","onBlur","useTouched","value","selectProps","selectElement","jsxs","cx","styles","select","jsx","required"],"mappings":"wHAAMA,EAAa,IAAIC,IAAI,CACzB,wBACA,oBACA,YACA,gBACA,mBACA,eACA,gBACA,oBACA,gBACA,gBACA,cACA,eACA,oBACA,aACA,kBACA,YACA,YACA,gBACA,uBACA,eACA,YACA,YACA,eACA,MACA,WACA,OACA,KACA,WACA,OACA,SACA,WACA,UACA,UACA,UACA,YACA,YACA,UACA,cACA,YACA,gBACA,cACA,WACA,OACA,OACA,QACA,WACA,QACA,OAAO,CACR,EAEM,SAASC,EAAuDC,EAAU,CAC/E,OAAOC,OAAOC,YACZD,OAAOE,QAAQH,CAAK,EAAEI,OACpB,CAAC,CAACC,CAAG,IAAMA,EAAIC,WAAW,OAAO,GAAKD,EAAIC,WAAW,OAAO,GAAKT,EAAWU,IAAIF,CAAG,CACrF,CACF,CACF,sGC5CaG,EAASA,CAAC,CAAEC,SAAAA,EAAUC,MAAAA,EAAOC,YAAAA,EAAa,GAAGX,CAAmB,IAAM,CACjF,KAAM,CAAEY,QAAAA,EAASC,OAAAA,CAAAA,EAAWC,aAAWd,EAAMe,QAAU,EAAE,EACnDC,EAAcjB,EAAoBC,CAAK,EAEvCiB,EACJC,EAAAA,KAAC,SAAA,CACC,UAAWC,EAAAA,EAAGC,EAAOC,OAAQT,GAAW,SAAS,EACjD,OAAAC,EACA,GAAIG,EAEHL,SAAAA,CAAAA,SACE,SAAA,CACC,MAAO,GACP,OAAM,GAELA,SAAAA,EACH,EAEDF,CAAAA,EACH,EAGF,OAAKC,EAKHQ,EAAAA,KAAC,QAAA,CAAK,iBAAA,SACJ,SAAA,CAAAI,EAAAA,IAAC,OAAA,CAAK,UAAWH,EAAAA,EAAGC,EAAOV,MAAOV,EAAMuB,UAAYH,EAAOG,QAAQ,EAAIb,SAAAA,CAAAA,CAAM,EAC5EO,CAAAA,EACH,EAPOA,CASX"}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"index-xRmXVWAN.js","sources":["../src/components/select/sanitizeSelectProps.ts","../src/components/select/index.tsx"],"sourcesContent":["const selectKeys = new Set([\n 'aria-activedescendant',\n 'aria-autocomplete',\n 'aria-busy',\n 'aria-controls',\n 'aria-describedby',\n 'aria-details',\n 'aria-disabled',\n 'aria-errormessage',\n 'aria-expanded',\n 'aria-haspopup',\n 'aria-hidden',\n 'aria-invalid',\n 'aria-keyshortcuts',\n 'aria-label',\n 'aria-labelledby',\n 'aria-live',\n 'aria-owns',\n 'aria-required',\n 'aria-roledescription',\n 'autoComplete',\n 'autoFocus',\n 'className',\n 'defaultValue',\n 'dir',\n 'disabled',\n 'form',\n 'id',\n 'multiple',\n 'name',\n 'onBlur',\n 'onChange',\n 'onClick',\n 'onFocus',\n 'onInput',\n 'onInvalid',\n 'onKeyDown',\n 'onKeyUp',\n 'onMouseDown',\n 'onMouseUp',\n 'onPointerDown',\n 'onPointerUp',\n 'required',\n 'role',\n 'size',\n 'style',\n 'tabIndex',\n 'title',\n 'value',\n]);\n\nexport function sanitizeSelectProps<T extends Record<string, unknown>>(props: T) {\n return Object.fromEntries(\n Object.entries(props).filter(\n ([key]) => key.startsWith('data-') || key.startsWith('aria-') || selectKeys.has(key)\n )\n ) as Partial<T>;\n}\n","import cx from 'classix';\n\nimport { useTouched } from '@/utils.ts';\n\nimport { sanitizeSelectProps } from './sanitizeSelectProps';\nimport styles from './styles.module.css';\n\nexport type SelectProps = React.SelectHTMLAttributes<HTMLSelectElement> & {\n children: React.ReactNode;\n label?: string;\n placeholder?: string;\n};\n\nexport const Select = ({ children, label, placeholder, ...props }: SelectProps) => {\n const { touched, onBlur } = useTouched(props.value === '');\n const selectProps = sanitizeSelectProps(props);\n\n const selectElement = (\n <select\n className={cx(styles.select, touched && 'touched')}\n onBlur={onBlur}\n {...selectProps}\n >\n {placeholder && (\n <option\n value={''}\n hidden\n >\n {placeholder}\n </option>\n )}\n {children}\n </select>\n );\n\n if (!label) {\n return selectElement;\n }\n\n return (\n <label>\n <span className={cx(styles.label, props.required && styles.required)}>{label}</span>\n {selectElement}\n </label>\n );\n};\n"],"names":["selectKeys","Set","sanitizeSelectProps","props","Object","fromEntries","entries","filter","key","startsWith","has","Select","children","label","placeholder","touched","onBlur","useTouched","value","selectProps","selectElement","jsxs","cx","styles","select","jsx","required"],"mappings":";;;AAAA,MAAMA,IAAa,oBAAIC,IAAI,CACzB,yBACA,qBACA,aACA,iBACA,oBACA,gBACA,iBACA,qBACA,iBACA,iBACA,eACA,gBACA,qBACA,cACA,mBACA,aACA,aACA,iBACA,wBACA,gBACA,aACA,aACA,gBACA,OACA,YACA,QACA,MACA,YACA,QACA,UACA,YACA,WACA,WACA,WACA,aACA,aACA,WACA,eACA,aACA,iBACA,eACA,YACA,QACA,QACA,SACA,YACA,SACA,OAAO,CACR;AAEM,SAASC,EAAuDC,GAAU;AAC/E,SAAOC,OAAOC,YACZD,OAAOE,QAAQH,CAAK,EAAEI,OACpB,CAAC,CAACC,CAAG,MAAMA,EAAIC,WAAW,OAAO,KAAKD,EAAIC,WAAW,OAAO,KAAKT,EAAWU,IAAIF,CAAG,CACrF,CACF;AACF;;;;;GC5CaG,IAASA,CAAC;AAAA,EAAEC,UAAAA;AAAAA,EAAUC,OAAAA;AAAAA,EAAOC,aAAAA;AAAAA,EAAa,GAAGX;AAAmB,MAAM;AACjF,QAAM;AAAA,IAAEY,SAAAA;AAAAA,IAASC,QAAAA;AAAAA,EAAAA,IAAWC,EAAWd,EAAMe,UAAU,EAAE,GACnDC,IAAcjB,EAAoBC,CAAK,GAEvCiB,IACJ,gBAAAC,EAAC,UAAA,EACC,WAAWC,EAAGC,EAAOC,QAAQT,KAAW,SAAS,GACjD,QAAAC,GACA,GAAIG,GAEHL,UAAAA;AAAAA,IAAAA,uBACE,UAAA,EACC,OAAO,IACP,QAAM,IAELA,UAAAA,GACH;AAAA,IAEDF;AAAAA,EAAAA,GACH;AAGF,SAAKC,IAKH,gBAAAQ,EAAC,SAAA,EAAK,kBAAA,UACJ,UAAA;AAAA,IAAA,gBAAAI,EAAC,QAAA,EAAK,WAAWH,EAAGC,EAAOV,OAAOV,EAAMuB,YAAYH,EAAOG,QAAQ,GAAIb,UAAAA,EAAAA,CAAM;AAAA,IAC5EO;AAAAA,EAAAA,GACH,IAPOA;AASX;"}
|
package/dist/utils-DXIJVVzz.js
DELETED
|
@@ -1,14 +0,0 @@
|
|
|
1
|
-
import { useState as s, useCallback as c, useEffect as r } from "react";
|
|
2
|
-
function f(t) {
|
|
3
|
-
const [u, e] = s(!1), o = c(() => e(!0), []);
|
|
4
|
-
return r(() => {
|
|
5
|
-
e(!1);
|
|
6
|
-
}, [t]), {
|
|
7
|
-
touched: u,
|
|
8
|
-
onBlur: o
|
|
9
|
-
};
|
|
10
|
-
}
|
|
11
|
-
export {
|
|
12
|
-
f as u
|
|
13
|
-
};
|
|
14
|
-
//# sourceMappingURL=utils-DXIJVVzz.js.map
|