@pantograph/vue 0.10.0 → 0.10.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/ActionButton/index.js.js +1 -1
- package/dist/ActionButton/index.umd.cjs.js +1 -1
- package/dist/{ActionButton.vue_vue_type_script_setup_true_lang-Db3ryil1.js → ActionButton.vue_vue_type_script_setup_true_lang-BVtP6mpl.js} +1 -1
- package/dist/{ActionButton.vue_vue_type_script_setup_true_lang-ClxZJxTh.js → ActionButton.vue_vue_type_script_setup_true_lang-KL8JuFlI.js} +2 -2
- package/dist/Avatar/index.js.js +1 -1
- package/dist/Avatar/index.umd.cjs.js +1 -1
- package/dist/{Avatar.vue_vue_type_style_index_0_lang-B538jct0.js → Avatar.vue_vue_type_style_index_0_lang-BHYcXGuX.js} +2 -2
- package/dist/{Avatar.vue_vue_type_style_index_0_lang-BSi0qbuq.js → Avatar.vue_vue_type_style_index_0_lang-DKGY3npY.js} +1 -1
- package/dist/AvatarGroup/index.js.js +1 -1
- package/dist/AvatarGroup/index.umd.cjs.js +1 -1
- package/dist/Badge/index.js.js +1 -1
- package/dist/Badge/index.umd.cjs.js +1 -1
- package/dist/{Badge.vue_vue_type_script_setup_true_lang-CKxCSXXL.js → Badge.vue_vue_type_script_setup_true_lang-BcdNUohN.js} +1 -1
- package/dist/{Badge.vue_vue_type_script_setup_true_lang-CfA3dSJr.js → Badge.vue_vue_type_script_setup_true_lang-nmw9qfJ_.js} +1 -1
- package/dist/{BaseButton.vue_vue_type_style_index_0_lang-s4G57j5o.js → BaseButton.vue_vue_type_style_index_0_lang-BrQJfrgg.js} +1 -1
- package/dist/{BaseButton.vue_vue_type_style_index_0_lang-gzePKYHN.js → BaseButton.vue_vue_type_style_index_0_lang-CTK5nNR6.js} +1 -1
- package/dist/Button/index.js.js +1 -1
- package/dist/Button/index.umd.cjs.js +1 -1
- package/dist/{Button.vue_vue_type_script_setup_true_lang-BVCP3jP3.js → Button.vue_vue_type_script_setup_true_lang-7V57ztN4.js} +1 -1
- package/dist/{Button.vue_vue_type_script_setup_true_lang-B8DWC8Du.js → Button.vue_vue_type_script_setup_true_lang-DIj3gT2D.js} +2 -2
- package/dist/Checkbox/index.js.js +1 -1
- package/dist/Checkbox/index.umd.cjs.js +1 -1
- package/dist/{Checkbox.vue_vue_type_style_index_0_lang-Bm6sm_wm.js → Checkbox.vue_vue_type_style_index_0_lang-C6Mdufam.js} +1 -1
- package/dist/{Checkbox.vue_vue_type_style_index_0_lang-maH6mbC5.js → Checkbox.vue_vue_type_style_index_0_lang-DNlvOQmv.js} +2 -2
- package/dist/CheckboxGroup/index.js.js +1 -1
- package/dist/CheckboxGroup/index.umd.cjs.js +1 -1
- package/dist/ColorPicker/index.js.js +1 -1
- package/dist/ColorPicker/index.umd.cjs.js +1 -1
- package/dist/ColorPicker.vue_vue_type_style_index_0_lang-C36JPo4m.js +1 -0
- package/dist/ColorPicker.vue_vue_type_style_index_0_lang-Dq-kFXox.js +541 -0
- package/dist/ColorSwatch/index.js.js +1 -1
- package/dist/ColorSwatch/index.umd.cjs.js +1 -1
- package/dist/{ColorSwatch.vue_vue_type_style_index_0_lang-Dki5150Z.js → ColorSwatch.vue_vue_type_style_index_0_lang-Bo-zDAyc.js} +1 -1
- package/dist/{ColorSwatch.vue_vue_type_style_index_0_lang-Bf0glWPU.js → ColorSwatch.vue_vue_type_style_index_0_lang-DmLhCPh4.js} +3 -3
- package/dist/ColorSwatchGroup/index.js.js +3 -163
- package/dist/ColorSwatchGroup/index.umd.cjs.js +1 -1
- package/dist/ColorSwatchGroup.vue_vue_type_style_index_0_lang-CIkTvqD_.js +165 -0
- package/dist/ColorSwatchGroup.vue_vue_type_style_index_0_lang-T_L-D2SS.js +1 -0
- package/dist/ColorTrigger/index.js.js +4 -90
- package/dist/ColorTrigger/index.umd.cjs.js +1 -1
- package/dist/ColorTrigger.vue_vue_type_style_index_0_lang-DSZ8fAZ9.js +91 -0
- package/dist/ColorTrigger.vue_vue_type_style_index_0_lang-DwyinKNj.js +1 -0
- package/dist/FloatButton/index.js.js +1 -1
- package/dist/FloatButton/index.umd.cjs.js +1 -1
- package/dist/{FloatButton.vue_vue_type_script_setup_true_lang-iElZdgSE.js → FloatButton.vue_vue_type_script_setup_true_lang-Bapsnc_p.js} +2 -2
- package/dist/{FloatButton.vue_vue_type_script_setup_true_lang-DARsq4US.js → FloatButton.vue_vue_type_script_setup_true_lang-C56u1xaL.js} +1 -1
- package/dist/GraphicalObject/index.js.js +1 -1
- package/dist/GraphicalObject/index.umd.cjs.js +1 -1
- package/dist/{GraphicalObject.vue_vue_type_script_setup_true_lang-Cc4PxUnd.js → GraphicalObject.vue_vue_type_script_setup_true_lang-B3FouRlw.js} +1 -1
- package/dist/{GraphicalObject.vue_vue_type_script_setup_true_lang-Bouixpu2.js → GraphicalObject.vue_vue_type_script_setup_true_lang-DlMeNk_1.js} +1 -1
- package/dist/IconButton/index.js.js +1 -1
- package/dist/IconButton/index.umd.cjs.js +1 -1
- package/dist/{IconButton.vue_vue_type_script_setup_true_lang-CufKPHFD.js → IconButton.vue_vue_type_script_setup_true_lang-7QB-mmyg.js} +1 -1
- package/dist/{IconButton.vue_vue_type_script_setup_true_lang-D1nK8pEU.js → IconButton.vue_vue_type_script_setup_true_lang-dI6-RNyi.js} +2 -2
- package/dist/IndentLevel/index.js.js +1 -1
- package/dist/IndentLevel/index.umd.cjs.js +1 -1
- package/dist/{IndentLevel.vue_vue_type_style_index_0_lang-C9mNx1Zx.js → IndentLevel.vue_vue_type_style_index_0_lang-CM6s5E6c.js} +1 -1
- package/dist/{IndentLevel.vue_vue_type_style_index_0_lang-CKJpRLV6.js → IndentLevel.vue_vue_type_style_index_0_lang-nGsyFkwr.js} +1 -1
- package/dist/Indicator/index.js.js +1 -1
- package/dist/Indicator/index.umd.cjs.js +1 -1
- package/dist/{Indicator.vue_vue_type_script_setup_true_lang-DpPAMjWw.js → Indicator.vue_vue_type_script_setup_true_lang-C4Ecg4iy.js} +1 -1
- package/dist/{Indicator.vue_vue_type_script_setup_true_lang-DURlzRTQ.js → Indicator.vue_vue_type_script_setup_true_lang-ICqvLVbq.js} +1 -1
- package/dist/Input/index.d.ts +2 -0
- package/dist/Input/index.js.js +7 -0
- package/dist/Input/index.umd.cjs.js +1 -0
- package/dist/Input.vue_vue_type_style_index_0_lang-D0zx-hd_.js +1 -0
- package/dist/Input.vue_vue_type_style_index_0_lang-cjYJlwXf.js +413 -0
- package/dist/Menu/index.js.js +1 -1
- package/dist/Menu/index.umd.cjs.js +1 -1
- package/dist/{Menu.vue_vue_type_style_index_0_lang-Danl_w4K.js → Menu.vue_vue_type_style_index_0_lang-DHGED80D.js} +17 -16
- package/dist/Menu.vue_vue_type_style_index_0_lang-DU0Rexv8.js +1 -0
- package/dist/MenuItem/MenuItem.d.ts +1 -1
- package/dist/MenuItem/index.js.js +1 -1
- package/dist/MenuItem/index.umd.cjs.js +1 -1
- package/dist/Popover/index.js.js +1 -1
- package/dist/Popover/index.umd.cjs.js +1 -1
- package/dist/{Popover.vue_vue_type_style_index_0_lang-DkM_Ynrg.js → Popover.vue_vue_type_style_index_0_lang-C0IwnsU5.js} +2 -2
- package/dist/{Popover.vue_vue_type_style_index_0_lang-pSXmj4z1.js → Popover.vue_vue_type_style_index_0_lang-CM8qMFEi.js} +1 -1
- package/dist/RadioGroup/index.js.js +1 -1
- package/dist/RadioGroup/index.umd.cjs.js +1 -1
- package/dist/{RadioGroup.vue_vue_type_script_setup_true_lang-NNLg5ogX.js → RadioGroup.vue_vue_type_script_setup_true_lang-DWfKIuDH.js} +1 -1
- package/dist/{RadioGroup.vue_vue_type_script_setup_true_lang-8BgnVYlc.js → RadioGroup.vue_vue_type_script_setup_true_lang-s-m7W1By.js} +1 -1
- package/dist/Switch/index.js.js +1 -1
- package/dist/Switch/index.umd.cjs.js +1 -1
- package/dist/{Switch.vue_vue_type_style_index_0_lang-_FIrRkI7.js → Switch.vue_vue_type_style_index_0_lang-BzC8-ylY.js} +1 -1
- package/dist/{Switch.vue_vue_type_style_index_0_lang-B9_IPFyg.js → Switch.vue_vue_type_style_index_0_lang-DnNHGn1c.js} +1 -1
- package/dist/Tree/index.js.js +1 -1
- package/dist/Tree/index.umd.cjs.js +1 -1
- package/dist/{Tree.vue_vue_type_style_index_0_lang-D9GBs86I.js → Tree.vue_vue_type_style_index_0_lang-B-BPV_p7.js} +19 -19
- package/dist/Tree.vue_vue_type_style_index_0_lang-BIpFWo5L.js +1 -0
- package/dist/_flatRest-CHX8vV1P.js +556 -0
- package/dist/_flatRest-R59G2N4m.js +1 -0
- package/dist/{cloneDeep-7ho7cOLj.js → cloneDeep-BMA7VTX1.js} +1 -1
- package/dist/cloneDeep-BcKVMzWC.js +1 -0
- package/dist/get-B4UJlXpC.js +1 -0
- package/dist/{get-CdoyK4GU.js → get-Q8GXlj-L.js} +1 -1
- package/dist/index.d.ts +5 -0
- package/dist/index.js.js +117 -100
- package/dist/index.umd.cjs.js +1 -1
- package/dist/omit-BEkBWXra.js +212 -0
- package/dist/omit-BKPbELUG.js +1 -0
- package/dist/pick-C-ap2Lj0.js +1 -0
- package/dist/{pick-BHVX8oMF.js → pick-DLskPTKb.js} +1 -1
- package/dist/style/index.css +1 -1
- package/package.json +6 -1
- package/dist/ColorPicker.vue_vue_type_style_index_0_lang-CROQzfNe.js +0 -944
- package/dist/ColorPicker.vue_vue_type_style_index_0_lang-IZSWne-0.js +0 -1
- package/dist/Menu.vue_vue_type_style_index_0_lang-eKNVzfnz.js +0 -1
- package/dist/Tree.vue_vue_type_style_index_0_lang-B3ZzwkLN.js +0 -1
- package/dist/cloneDeep-C6tiVz1k.js +0 -1
- package/dist/get-BULsy4gy.js +0 -1
- package/dist/omit-BHZMfUBv.js +0 -757
- package/dist/omit-DlH5U9Jc.js +0 -1
- package/dist/pick-DpwC5mlg.js +0 -1
|
@@ -1,165 +1,5 @@
|
|
|
1
|
-
import {
|
|
2
|
-
import { g as W } from "../options-JBqnVZUl.js";
|
|
3
|
-
import { P as X } from "../Primitive-nOVjbfuc.js";
|
|
4
|
-
import { useEmitAsProps as Y } from "radix-vue";
|
|
5
|
-
import { _ as k, C as Z } from "../ColorSwatch.vue_vue_type_style_index_0_lang-Bf0glWPU.js";
|
|
6
|
-
import { i as B } from "../isString-BVAZt9W3.js";
|
|
7
|
-
import { i as y, o as x } from "../omit-BHZMfUBv.js";
|
|
8
|
-
import { useVModel as ee } from "@vueuse/core";
|
|
9
|
-
import { g as oe, a as te, b as S } from "../class-DziTeW9B.js";
|
|
10
|
-
import { cva as re } from "class-variance-authority";
|
|
11
|
-
import { _ as se } from "../Popover.vue_vue_type_style_index_0_lang-DkM_Ynrg.js";
|
|
12
|
-
import { _ as le } from "../ColorPicker.vue_vue_type_style_index_0_lang-CROQzfNe.js";
|
|
13
|
-
import { p as j } from "../pick-BHVX8oMF.js";
|
|
14
|
-
const ke = /* @__PURE__ */ D({
|
|
15
|
-
...W("ColorSwatchGroup"),
|
|
16
|
-
__name: "ColorSwatchGroup",
|
|
17
|
-
props: {
|
|
18
|
-
as: {},
|
|
19
|
-
format: {},
|
|
20
|
-
defaultFormat: {},
|
|
21
|
-
hideAlpha: { type: Boolean },
|
|
22
|
-
size: { default: "md" },
|
|
23
|
-
customPickerIcon: {},
|
|
24
|
-
icon: {},
|
|
25
|
-
class: {},
|
|
26
|
-
noRemover: { type: Boolean },
|
|
27
|
-
noCustomPicker: { type: Boolean },
|
|
28
|
-
modelValue: {},
|
|
29
|
-
headerCls: {},
|
|
30
|
-
header: {},
|
|
31
|
-
colorsCls: {},
|
|
32
|
-
defaultValue: {},
|
|
33
|
-
colors: {},
|
|
34
|
-
colorMode: { default: "bold" },
|
|
35
|
-
popoverProps: {}
|
|
36
|
-
},
|
|
37
|
-
emits: ["update:format", "update:modelValue"],
|
|
38
|
-
setup(w, { emit: I }) {
|
|
39
|
-
const o = w, A = L(), h = I, s = ee(
|
|
40
|
-
o,
|
|
41
|
-
"modelValue",
|
|
42
|
-
h,
|
|
43
|
-
{
|
|
44
|
-
defaultValue: o.defaultValue,
|
|
45
|
-
passive: o.modelValue === void 0
|
|
46
|
-
}
|
|
47
|
-
), E = (e) => {
|
|
48
|
-
if (B(e))
|
|
49
|
-
return {
|
|
50
|
-
selected: s.value === e,
|
|
51
|
-
icon: o.icon,
|
|
52
|
-
bg: e
|
|
53
|
-
};
|
|
54
|
-
if (y(e))
|
|
55
|
-
return {
|
|
56
|
-
...x(e, "value"),
|
|
57
|
-
icon: e.icon ?? o.icon,
|
|
58
|
-
selected: s.value === e.value
|
|
59
|
-
};
|
|
60
|
-
}, u = oe("color_swatch_group"), N = re(u, {
|
|
61
|
-
variants: {
|
|
62
|
-
size: te(Z, u)
|
|
63
|
-
}
|
|
64
|
-
}), M = U(!1), d = (e) => y(e) ? e.value : e ?? void 0, P = (e) => {
|
|
65
|
-
const t = d(e);
|
|
66
|
-
s.value = t, M.value = !t;
|
|
67
|
-
}, p = f(() => {
|
|
68
|
-
if (o.colors) return o.colors;
|
|
69
|
-
const e = ["red", "orange", "yellow", "lime", "green", "sky", "blue", "violet"];
|
|
70
|
-
return o.colorMode === "subtle" ? e.map((t) => `${t}-subtle`) : typeof o.colorMode == "object" && o.colorMode.value && (o.colorMode.bg || o.colorMode.br || o.colorMode.fg) ? e.map((t) => {
|
|
71
|
-
const r = {
|
|
72
|
-
value: typeof o.colorMode == "object" && o.colorMode.value === "subtle" ? `${t}-subtle` : t
|
|
73
|
-
};
|
|
74
|
-
return typeof o.colorMode == "object" && o.colorMode.bg && (r.bg = o.colorMode.bg === "subtle" ? `${t}-subtle` : t), typeof o.colorMode == "object" && o.colorMode.br && (r.br = o.colorMode.br === "subtle" ? `${t}-subtle` : t), typeof o.colorMode == "object" && o.colorMode.fg && (r.fg = o.colorMode.fg === "subtle" ? `${t}-subtle` : t), r;
|
|
75
|
-
}) : e;
|
|
76
|
-
}), O = f(() => {
|
|
77
|
-
var e;
|
|
78
|
-
if (!((e = p.value) != null && e.length && p.value.some(
|
|
79
|
-
(t) => B(t) && t === s.value || y(t) && s.value === t.value
|
|
80
|
-
)))
|
|
81
|
-
return s.value;
|
|
82
|
-
}), F = (e) => {
|
|
83
|
-
e && (s.value = e);
|
|
84
|
-
}, G = Y(h), R = f(() => ({
|
|
85
|
-
...j(G, "onUpdate:format"),
|
|
86
|
-
...j(o, "format", "defaultFormat", "hideAlpha")
|
|
87
|
-
}));
|
|
88
|
-
return (e, t) => (a(), c(l(X), {
|
|
89
|
-
as: e.as,
|
|
90
|
-
class: v([o.class, l(N)({ size: e.size })])
|
|
91
|
-
}, {
|
|
92
|
-
default: n(() => [
|
|
93
|
-
A.header || e.header ? (a(), z("div", {
|
|
94
|
-
key: 0,
|
|
95
|
-
class: v([l(S)(l(u), "header"), e.headerCls])
|
|
96
|
-
}, [
|
|
97
|
-
g(e.$slots, "header", {}, () => [
|
|
98
|
-
q(H(e.header), 1)
|
|
99
|
-
])
|
|
100
|
-
], 2)) : b("", !0),
|
|
101
|
-
T("div", {
|
|
102
|
-
class: v([l(S)(l(u), "colors"), e.colorsCls])
|
|
103
|
-
}, [
|
|
104
|
-
e.noRemover ? b("", !0) : (a(), c(k, {
|
|
105
|
-
key: 0,
|
|
106
|
-
type: "remover",
|
|
107
|
-
size: e.size,
|
|
108
|
-
onClick: t[0] || (t[0] = (r) => P()),
|
|
109
|
-
selected: !l(s) && M.value
|
|
110
|
-
}, null, 8, ["size", "selected"])),
|
|
111
|
-
(a(!0), z(J, null, C(p.value, (r) => (a(), c(k, m({
|
|
112
|
-
type: "color",
|
|
113
|
-
size: e.size,
|
|
114
|
-
icon: e.icon,
|
|
115
|
-
ref_for: !0
|
|
116
|
-
}, E(r), {
|
|
117
|
-
key: d(r),
|
|
118
|
-
onClick: (i) => P(r)
|
|
119
|
-
}), V({ _: 2 }, [
|
|
120
|
-
C(Object.keys(e.$slots), (i) => ({
|
|
121
|
-
name: i,
|
|
122
|
-
fn: n((_) => [
|
|
123
|
-
g(e.$slots, i, m({ ref_for: !0 }, { ..._, value: d(r) }))
|
|
124
|
-
])
|
|
125
|
-
}))
|
|
126
|
-
]), 1040, ["size", "icon", "onClick"]))), 128)),
|
|
127
|
-
e.noCustomPicker ? b("", !0) : (a(), c(se, m({
|
|
128
|
-
key: 1,
|
|
129
|
-
trigger: "click",
|
|
130
|
-
"reverse-placement-on-dir": "rtl",
|
|
131
|
-
placement: "right-start",
|
|
132
|
-
"side-offset": 4
|
|
133
|
-
}, e.popoverProps || {}), {
|
|
134
|
-
content: n(() => [
|
|
135
|
-
$(le, m({
|
|
136
|
-
defaultColor: O.value,
|
|
137
|
-
"onUpdate:color": F
|
|
138
|
-
}, R.value), null, 16, ["defaultColor"])
|
|
139
|
-
]),
|
|
140
|
-
default: n(() => [
|
|
141
|
-
$(k, {
|
|
142
|
-
type: "custom-picker",
|
|
143
|
-
size: e.size,
|
|
144
|
-
customPickerIcon: e.customPickerIcon
|
|
145
|
-
}, V({ _: 2 }, [
|
|
146
|
-
C(Object.keys(e.$slots), (r) => ({
|
|
147
|
-
name: r,
|
|
148
|
-
fn: n((i) => [
|
|
149
|
-
g(e.$slots, r, K(Q(i)))
|
|
150
|
-
])
|
|
151
|
-
}))
|
|
152
|
-
]), 1032, ["size", "customPickerIcon"])
|
|
153
|
-
]),
|
|
154
|
-
_: 3
|
|
155
|
-
}, 16))
|
|
156
|
-
], 2)
|
|
157
|
-
]),
|
|
158
|
-
_: 3
|
|
159
|
-
}, 8, ["as", "class"]));
|
|
160
|
-
}
|
|
161
|
-
});
|
|
1
|
+
import { _ as r, _ as t } from "../ColorSwatchGroup.vue_vue_type_style_index_0_lang-CIkTvqD_.js";
|
|
162
2
|
export {
|
|
163
|
-
|
|
164
|
-
|
|
3
|
+
r as ColorSwatchGroup,
|
|
4
|
+
t as default
|
|
165
5
|
};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";Object.defineProperties(exports,{__esModule:{value:!0},[Symbol.toStringTag]:{value:"Module"}});const e=require("
|
|
1
|
+
"use strict";Object.defineProperties(exports,{__esModule:{value:!0},[Symbol.toStringTag]:{value:"Module"}});const e=require("../ColorSwatchGroup.vue_vue_type_style_index_0_lang-T_L-D2SS.js");exports.ColorSwatchGroup=e._sfc_main;exports.default=e._sfc_main;
|
|
@@ -0,0 +1,165 @@
|
|
|
1
|
+
import { defineComponent as G, useSlots as L, ref as U, computed as f, createBlock as m, openBlock as a, unref as l, normalizeClass as v, withCtx as n, createElementBlock as z, createCommentVNode as b, createElementVNode as T, renderSlot as g, createTextVNode as q, toDisplayString as H, Fragment as J, renderList as C, mergeProps as c, createSlots as V, createVNode as $, normalizeProps as K, guardReactiveProps as Q } from "vue";
|
|
2
|
+
import { g as W } from "./options-JBqnVZUl.js";
|
|
3
|
+
import { P as X } from "./Primitive-nOVjbfuc.js";
|
|
4
|
+
import { useEmitAsProps as Y } from "radix-vue";
|
|
5
|
+
import { _ as k, C as Z } from "./ColorSwatch.vue_vue_type_style_index_0_lang-DmLhCPh4.js";
|
|
6
|
+
import { i as B } from "./isString-BVAZt9W3.js";
|
|
7
|
+
import { i as y } from "./_flatRest-CHX8vV1P.js";
|
|
8
|
+
import { useVModel as x } from "@vueuse/core";
|
|
9
|
+
import { g as ee, a as oe, b as j } from "./class-DziTeW9B.js";
|
|
10
|
+
import { cva as te } from "class-variance-authority";
|
|
11
|
+
import { o as re } from "./omit-BEkBWXra.js";
|
|
12
|
+
import { _ as se } from "./Popover.vue_vue_type_style_index_0_lang-C0IwnsU5.js";
|
|
13
|
+
import { _ as le } from "./ColorPicker.vue_vue_type_style_index_0_lang-Dq-kFXox.js";
|
|
14
|
+
import { p as S } from "./pick-DLskPTKb.js";
|
|
15
|
+
const ye = /* @__PURE__ */ G({
|
|
16
|
+
...W("ColorSwatchGroup"),
|
|
17
|
+
__name: "ColorSwatchGroup",
|
|
18
|
+
props: {
|
|
19
|
+
as: {},
|
|
20
|
+
format: {},
|
|
21
|
+
defaultFormat: {},
|
|
22
|
+
hideAlpha: { type: Boolean },
|
|
23
|
+
size: { default: "md" },
|
|
24
|
+
customPickerIcon: {},
|
|
25
|
+
icon: {},
|
|
26
|
+
class: {},
|
|
27
|
+
noRemover: { type: Boolean },
|
|
28
|
+
noCustomPicker: { type: Boolean },
|
|
29
|
+
modelValue: {},
|
|
30
|
+
headerCls: {},
|
|
31
|
+
header: {},
|
|
32
|
+
colorsCls: {},
|
|
33
|
+
defaultValue: {},
|
|
34
|
+
colors: {},
|
|
35
|
+
colorMode: { default: "bold" },
|
|
36
|
+
popoverProps: {}
|
|
37
|
+
},
|
|
38
|
+
emits: ["update:format", "update:modelValue"],
|
|
39
|
+
setup(w, { emit: I }) {
|
|
40
|
+
const o = w, A = L(), M = I, s = x(
|
|
41
|
+
o,
|
|
42
|
+
"modelValue",
|
|
43
|
+
M,
|
|
44
|
+
{
|
|
45
|
+
defaultValue: o.defaultValue,
|
|
46
|
+
passive: o.modelValue === void 0
|
|
47
|
+
}
|
|
48
|
+
), E = (e) => {
|
|
49
|
+
if (B(e))
|
|
50
|
+
return {
|
|
51
|
+
selected: s.value === e,
|
|
52
|
+
icon: o.icon,
|
|
53
|
+
bg: e
|
|
54
|
+
};
|
|
55
|
+
if (y(e))
|
|
56
|
+
return {
|
|
57
|
+
...re(e, "value"),
|
|
58
|
+
icon: e.icon ?? o.icon,
|
|
59
|
+
selected: s.value === e.value
|
|
60
|
+
};
|
|
61
|
+
}, u = ee("color_swatch_group"), N = te(u, {
|
|
62
|
+
variants: {
|
|
63
|
+
size: oe(Z, u)
|
|
64
|
+
}
|
|
65
|
+
}), h = U(!1), d = (e) => y(e) ? e.value : e ?? void 0, P = (e) => {
|
|
66
|
+
const t = d(e);
|
|
67
|
+
s.value = t, h.value = !t;
|
|
68
|
+
}, p = f(() => {
|
|
69
|
+
if (o.colors) return o.colors;
|
|
70
|
+
const e = ["red", "orange", "yellow", "lime", "green", "sky", "blue", "violet"];
|
|
71
|
+
return o.colorMode === "subtle" ? e.map((t) => `${t}-subtle`) : typeof o.colorMode == "object" && o.colorMode.value && (o.colorMode.bg || o.colorMode.br || o.colorMode.fg) ? e.map((t) => {
|
|
72
|
+
const r = {
|
|
73
|
+
value: typeof o.colorMode == "object" && o.colorMode.value === "subtle" ? `${t}-subtle` : t
|
|
74
|
+
};
|
|
75
|
+
return typeof o.colorMode == "object" && o.colorMode.bg && (r.bg = o.colorMode.bg === "subtle" ? `${t}-subtle` : t), typeof o.colorMode == "object" && o.colorMode.br && (r.br = o.colorMode.br === "subtle" ? `${t}-subtle` : t), typeof o.colorMode == "object" && o.colorMode.fg && (r.fg = o.colorMode.fg === "subtle" ? `${t}-subtle` : t), r;
|
|
76
|
+
}) : e;
|
|
77
|
+
}), O = f(() => {
|
|
78
|
+
var e;
|
|
79
|
+
if (!((e = p.value) != null && e.length && p.value.some(
|
|
80
|
+
(t) => B(t) && t === s.value || y(t) && s.value === t.value
|
|
81
|
+
)))
|
|
82
|
+
return s.value;
|
|
83
|
+
}), _ = (e) => {
|
|
84
|
+
e && (s.value = e);
|
|
85
|
+
}, F = Y(M), R = f(() => ({
|
|
86
|
+
...S(F, "onUpdate:format"),
|
|
87
|
+
...S(o, "format", "defaultFormat", "hideAlpha")
|
|
88
|
+
}));
|
|
89
|
+
return (e, t) => (a(), m(l(X), {
|
|
90
|
+
as: e.as,
|
|
91
|
+
class: v([o.class, l(N)({ size: e.size })])
|
|
92
|
+
}, {
|
|
93
|
+
default: n(() => [
|
|
94
|
+
A.header || e.header ? (a(), z("div", {
|
|
95
|
+
key: 0,
|
|
96
|
+
class: v([l(j)(l(u), "header"), e.headerCls])
|
|
97
|
+
}, [
|
|
98
|
+
g(e.$slots, "header", {}, () => [
|
|
99
|
+
q(H(e.header), 1)
|
|
100
|
+
])
|
|
101
|
+
], 2)) : b("", !0),
|
|
102
|
+
T("div", {
|
|
103
|
+
class: v([l(j)(l(u), "colors"), e.colorsCls])
|
|
104
|
+
}, [
|
|
105
|
+
e.noRemover ? b("", !0) : (a(), m(k, {
|
|
106
|
+
key: 0,
|
|
107
|
+
type: "remover",
|
|
108
|
+
size: e.size,
|
|
109
|
+
onClick: t[0] || (t[0] = (r) => P()),
|
|
110
|
+
selected: !l(s) && h.value
|
|
111
|
+
}, null, 8, ["size", "selected"])),
|
|
112
|
+
(a(!0), z(J, null, C(p.value, (r) => (a(), m(k, c({
|
|
113
|
+
type: "color",
|
|
114
|
+
size: e.size,
|
|
115
|
+
icon: e.icon,
|
|
116
|
+
ref_for: !0
|
|
117
|
+
}, E(r), {
|
|
118
|
+
key: d(r),
|
|
119
|
+
onClick: (i) => P(r)
|
|
120
|
+
}), V({ _: 2 }, [
|
|
121
|
+
C(Object.keys(e.$slots), (i) => ({
|
|
122
|
+
name: i,
|
|
123
|
+
fn: n((D) => [
|
|
124
|
+
g(e.$slots, i, c({ ref_for: !0 }, { ...D, value: d(r) }))
|
|
125
|
+
])
|
|
126
|
+
}))
|
|
127
|
+
]), 1040, ["size", "icon", "onClick"]))), 128)),
|
|
128
|
+
e.noCustomPicker ? b("", !0) : (a(), m(se, c({
|
|
129
|
+
key: 1,
|
|
130
|
+
trigger: "click",
|
|
131
|
+
"reverse-placement-on-dir": "rtl",
|
|
132
|
+
placement: "right-start",
|
|
133
|
+
"side-offset": 4
|
|
134
|
+
}, e.popoverProps || {}), {
|
|
135
|
+
content: n(() => [
|
|
136
|
+
$(le, c({
|
|
137
|
+
defaultColor: O.value,
|
|
138
|
+
"onUpdate:color": _
|
|
139
|
+
}, R.value), null, 16, ["defaultColor"])
|
|
140
|
+
]),
|
|
141
|
+
default: n(() => [
|
|
142
|
+
$(k, {
|
|
143
|
+
type: "custom-picker",
|
|
144
|
+
size: e.size,
|
|
145
|
+
customPickerIcon: e.customPickerIcon
|
|
146
|
+
}, V({ _: 2 }, [
|
|
147
|
+
C(Object.keys(e.$slots), (r) => ({
|
|
148
|
+
name: r,
|
|
149
|
+
fn: n((i) => [
|
|
150
|
+
g(e.$slots, r, K(Q(i)))
|
|
151
|
+
])
|
|
152
|
+
}))
|
|
153
|
+
]), 1032, ["size", "customPickerIcon"])
|
|
154
|
+
]),
|
|
155
|
+
_: 3
|
|
156
|
+
}, 16))
|
|
157
|
+
], 2)
|
|
158
|
+
]),
|
|
159
|
+
_: 3
|
|
160
|
+
}, 8, ["as", "class"]));
|
|
161
|
+
}
|
|
162
|
+
});
|
|
163
|
+
export {
|
|
164
|
+
ye as _
|
|
165
|
+
};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
"use strict";const e=require("vue"),S=require("./options-B4iSAKol.js"),q=require("./Primitive-BT1RjuGS.js"),$=require("radix-vue"),i=require("./ColorSwatch.vue_vue_type_style_index_0_lang-Bo-zDAyc.js"),g=require("./isString-CKmTJsel.js"),m=require("./_flatRest-R59G2N4m.js"),j=require("@vueuse/core"),u=require("./class-CjZYGZDW.js"),w=require("class-variance-authority"),N=require("./omit-BKPbELUG.js"),E=require("./Popover.vue_vue_type_style_index_0_lang-CM8qMFEi.js"),O=require("./ColorPicker.vue_vue_type_style_index_0_lang-C36JPo4m.js"),k=require("./pick-C-ap2Lj0.js"),A=e.defineComponent({...S.getComponentOptions("ColorSwatchGroup"),__name:"ColorSwatchGroup",props:{as:{},format:{},defaultFormat:{},hideAlpha:{type:Boolean},size:{default:"md"},customPickerIcon:{},icon:{},class:{},noRemover:{type:Boolean},noCustomPicker:{type:Boolean},modelValue:{},headerCls:{},header:{},colorsCls:{},defaultValue:{},colors:{},colorMode:{default:"bold"},popoverProps:{}},emits:["update:format","update:modelValue"],setup(C,{emit:b}){const t=C,_=e.useSlots(),p=b,l=j.useVModel(t,"modelValue",p,{defaultValue:t.defaultValue,passive:t.modelValue===void 0}),y=o=>{if(g.isString(o))return{selected:l.value===o,icon:t.icon,bg:o};if(m.isObject(o))return{...N.omit(o,"value"),icon:o.icon??t.icon,selected:l.value===o.value}},a=u.getBemBlock("color_swatch_group"),h=w.cva(a,{variants:{size:u.generateVariantClassList(i.ColorSwatchSizes,a)}}),f=e.ref(!1),c=o=>m.isObject(o)?o.value:o??void 0,v=o=>{const r=c(o);l.value=r,f.value=!r},d=e.computed(()=>{if(t.colors)return t.colors;const o=["red","orange","yellow","lime","green","sky","blue","violet"];return t.colorMode==="subtle"?o.map(r=>`${r}-subtle`):typeof t.colorMode=="object"&&t.colorMode.value&&(t.colorMode.bg||t.colorMode.br||t.colorMode.fg)?o.map(r=>{const s={value:typeof t.colorMode=="object"&&t.colorMode.value==="subtle"?`${r}-subtle`:r};return typeof t.colorMode=="object"&&t.colorMode.bg&&(s.bg=t.colorMode.bg==="subtle"?`${r}-subtle`:r),typeof t.colorMode=="object"&&t.colorMode.br&&(s.br=t.colorMode.br==="subtle"?`${r}-subtle`:r),typeof t.colorMode=="object"&&t.colorMode.fg&&(s.fg=t.colorMode.fg==="subtle"?`${r}-subtle`:r),s}):o}),P=e.computed(()=>{var o;if(!((o=d.value)!=null&&o.length&&d.value.some(r=>g.isString(r)&&r===l.value||m.isObject(r)&&l.value===r.value)))return l.value}),V=o=>{o&&(l.value=o)},B=$.useEmitAsProps(p),M=e.computed(()=>({...k.pick(B,"onUpdate:format"),...k.pick(t,"format","defaultFormat","hideAlpha")}));return(o,r)=>(e.openBlock(),e.createBlock(e.unref(q.Primitive),{as:o.as,class:e.normalizeClass([t.class,e.unref(h)({size:o.size})])},{default:e.withCtx(()=>[_.header||o.header?(e.openBlock(),e.createElementBlock("div",{key:0,class:e.normalizeClass([e.unref(u.getBemElement)(e.unref(a),"header"),o.headerCls])},[e.renderSlot(o.$slots,"header",{},()=>[e.createTextVNode(e.toDisplayString(o.header),1)])],2)):e.createCommentVNode("",!0),e.createElementVNode("div",{class:e.normalizeClass([e.unref(u.getBemElement)(e.unref(a),"colors"),o.colorsCls])},[o.noRemover?e.createCommentVNode("",!0):(e.openBlock(),e.createBlock(i._sfc_main,{key:0,type:"remover",size:o.size,onClick:r[0]||(r[0]=s=>v()),selected:!e.unref(l)&&f.value},null,8,["size","selected"])),(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(d.value,s=>(e.openBlock(),e.createBlock(i._sfc_main,e.mergeProps({type:"color",size:o.size,icon:o.icon,ref_for:!0},y(s),{key:c(s),onClick:n=>v(s)}),e.createSlots({_:2},[e.renderList(Object.keys(o.$slots),n=>({name:n,fn:e.withCtx(z=>[e.renderSlot(o.$slots,n,e.mergeProps({ref_for:!0},{...z,value:c(s)}))])}))]),1040,["size","icon","onClick"]))),128)),o.noCustomPicker?e.createCommentVNode("",!0):(e.openBlock(),e.createBlock(E._sfc_main,e.mergeProps({key:1,trigger:"click","reverse-placement-on-dir":"rtl",placement:"right-start","side-offset":4},o.popoverProps||{}),{content:e.withCtx(()=>[e.createVNode(O._sfc_main,e.mergeProps({defaultColor:P.value,"onUpdate:color":V},M.value),null,16,["defaultColor"])]),default:e.withCtx(()=>[e.createVNode(i._sfc_main,{type:"custom-picker",size:o.size,customPickerIcon:o.customPickerIcon},e.createSlots({_:2},[e.renderList(Object.keys(o.$slots),s=>({name:s,fn:e.withCtx(n=>[e.renderSlot(o.$slots,s,e.normalizeProps(e.guardReactiveProps(n)))])}))]),1032,["size","customPickerIcon"])]),_:3},16))],2)]),_:3},8,["as","class"]))}});exports._sfc_main=A;
|
|
@@ -1,92 +1,6 @@
|
|
|
1
|
-
import {
|
|
2
|
-
import { _ as w } from "../GraphicalObject.vue_vue_type_script_setup_true_lang-Cc4PxUnd.js";
|
|
3
|
-
import { g as y } from "../options-JBqnVZUl.js";
|
|
4
|
-
import { g as O, a as u } from "../class-DziTeW9B.js";
|
|
5
|
-
import { cva as P } from "class-variance-authority";
|
|
6
|
-
import { P as T } from "../Primitive-nOVjbfuc.js";
|
|
7
|
-
import { _ as $ } from "../Icon.vue_vue_type_style_index_0_lang-BfPcw6PU.js";
|
|
8
|
-
import { i as V } from "../isString-BVAZt9W3.js";
|
|
9
|
-
import { p as G } from "../pick-BHVX8oMF.js";
|
|
10
|
-
const d = ["sm", "md", "lg"], J = /* @__PURE__ */ S({
|
|
11
|
-
...y("ColorTrigger"),
|
|
12
|
-
__name: "ColorTrigger",
|
|
13
|
-
props: {
|
|
14
|
-
icon: {},
|
|
15
|
-
bg: {},
|
|
16
|
-
br: {},
|
|
17
|
-
fg: {},
|
|
18
|
-
as: {},
|
|
19
|
-
class: {},
|
|
20
|
-
size: { default: "md" },
|
|
21
|
-
borderless: { type: Boolean },
|
|
22
|
-
suffixIcon: { type: [Boolean, String], default: "tabler:chevron-down" }
|
|
23
|
-
},
|
|
24
|
-
setup(p) {
|
|
25
|
-
const e = p, r = O("color_trigger"), z = P(r, {
|
|
26
|
-
variants: {
|
|
27
|
-
size: u(d, r),
|
|
28
|
-
borderless: u("borderless", r)
|
|
29
|
-
}
|
|
30
|
-
}), b = o(
|
|
31
|
-
() => e.size && d.includes(e.size) ? e.size : "md"
|
|
32
|
-
), C = o(() => ({
|
|
33
|
-
size: (() => {
|
|
34
|
-
switch (e.size) {
|
|
35
|
-
case "sm":
|
|
36
|
-
return "2xsm";
|
|
37
|
-
case "md":
|
|
38
|
-
return "xsm";
|
|
39
|
-
case "lg":
|
|
40
|
-
return "sm";
|
|
41
|
-
}
|
|
42
|
-
})(),
|
|
43
|
-
...G(e, "icon", "bg", "br", "fg")
|
|
44
|
-
})), n = _(), v = o(() => {
|
|
45
|
-
switch (e.size) {
|
|
46
|
-
case "sm":
|
|
47
|
-
return "2xsm";
|
|
48
|
-
case "md":
|
|
49
|
-
case "lg":
|
|
50
|
-
return "xsm";
|
|
51
|
-
}
|
|
52
|
-
});
|
|
53
|
-
return (s, L) => (m(), c(i(T), {
|
|
54
|
-
as: s.as,
|
|
55
|
-
class: x([
|
|
56
|
-
i(z)({
|
|
57
|
-
size: b.value,
|
|
58
|
-
borderless: s.borderless
|
|
59
|
-
}),
|
|
60
|
-
e.class
|
|
61
|
-
]),
|
|
62
|
-
tabindex: "0"
|
|
63
|
-
}, {
|
|
64
|
-
default: t(() => [
|
|
65
|
-
B(w, l(f(C.value)), I({ _: 2 }, [
|
|
66
|
-
h(Object.keys(n), (a) => ({
|
|
67
|
-
name: a,
|
|
68
|
-
fn: t(() => [
|
|
69
|
-
g(s.$slots, a, l(f(e)))
|
|
70
|
-
])
|
|
71
|
-
}))
|
|
72
|
-
]), 1040),
|
|
73
|
-
s.suffixIcon || n.suffixIcon ? (m(), c($, {
|
|
74
|
-
key: 0,
|
|
75
|
-
icon: i(V)(s.suffixIcon) ? s.suffixIcon : void 0,
|
|
76
|
-
size: v.value
|
|
77
|
-
}, {
|
|
78
|
-
default: t(() => [
|
|
79
|
-
g(s.$slots, "suffixIcon")
|
|
80
|
-
]),
|
|
81
|
-
_: 3
|
|
82
|
-
}, 8, ["icon", "size"])) : k("", !0)
|
|
83
|
-
]),
|
|
84
|
-
_: 3
|
|
85
|
-
}, 8, ["as", "class"]));
|
|
86
|
-
}
|
|
87
|
-
});
|
|
1
|
+
import { _ as e, C as a, _ as g } from "../ColorTrigger.vue_vue_type_style_index_0_lang-DSZ8fAZ9.js";
|
|
88
2
|
export {
|
|
89
|
-
|
|
90
|
-
|
|
91
|
-
|
|
3
|
+
e as ColorTrigger,
|
|
4
|
+
a as ColorTriggerSizes,
|
|
5
|
+
g as default
|
|
92
6
|
};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";Object.defineProperties(exports,{__esModule:{value:!0},[Symbol.toStringTag]:{value:"Module"}});const e=require("
|
|
1
|
+
"use strict";Object.defineProperties(exports,{__esModule:{value:!0},[Symbol.toStringTag]:{value:"Module"}});const e=require("../ColorTrigger.vue_vue_type_style_index_0_lang-DwyinKNj.js");exports.ColorTrigger=e._sfc_main;exports.ColorTriggerSizes=e.ColorTriggerSizes;exports.default=e._sfc_main;
|
|
@@ -0,0 +1,91 @@
|
|
|
1
|
+
import { defineComponent as S, computed as o, useSlots as _, createBlock as c, openBlock as m, unref as i, normalizeClass as x, withCtx as t, createVNode as B, createCommentVNode as k, normalizeProps as l, guardReactiveProps as f, createSlots as I, renderList as h, renderSlot as u } from "vue";
|
|
2
|
+
import { _ as w } from "./GraphicalObject.vue_vue_type_script_setup_true_lang-B3FouRlw.js";
|
|
3
|
+
import { g as y } from "./options-JBqnVZUl.js";
|
|
4
|
+
import { g as O, a as g } from "./class-DziTeW9B.js";
|
|
5
|
+
import { cva as P } from "class-variance-authority";
|
|
6
|
+
import { P as $ } from "./Primitive-nOVjbfuc.js";
|
|
7
|
+
import { _ as T } from "./Icon.vue_vue_type_style_index_0_lang-BfPcw6PU.js";
|
|
8
|
+
import { i as V } from "./isString-BVAZt9W3.js";
|
|
9
|
+
import { p as G } from "./pick-DLskPTKb.js";
|
|
10
|
+
const p = ["sm", "md", "lg"], J = /* @__PURE__ */ S({
|
|
11
|
+
...y("ColorTrigger"),
|
|
12
|
+
__name: "ColorTrigger",
|
|
13
|
+
props: {
|
|
14
|
+
icon: {},
|
|
15
|
+
bg: {},
|
|
16
|
+
br: {},
|
|
17
|
+
fg: {},
|
|
18
|
+
as: {},
|
|
19
|
+
class: {},
|
|
20
|
+
size: { default: "md" },
|
|
21
|
+
borderless: { type: Boolean },
|
|
22
|
+
suffixIcon: { type: [Boolean, String], default: "tabler:chevron-down" }
|
|
23
|
+
},
|
|
24
|
+
setup(d) {
|
|
25
|
+
const e = d, r = O("color_trigger"), z = P(r, {
|
|
26
|
+
variants: {
|
|
27
|
+
size: g(p, r),
|
|
28
|
+
borderless: g("borderless", r)
|
|
29
|
+
}
|
|
30
|
+
}), b = o(
|
|
31
|
+
() => e.size && p.includes(e.size) ? e.size : "md"
|
|
32
|
+
), C = o(() => ({
|
|
33
|
+
size: (() => {
|
|
34
|
+
switch (e.size) {
|
|
35
|
+
case "sm":
|
|
36
|
+
return "2xsm";
|
|
37
|
+
case "md":
|
|
38
|
+
return "xsm";
|
|
39
|
+
case "lg":
|
|
40
|
+
return "sm";
|
|
41
|
+
}
|
|
42
|
+
})(),
|
|
43
|
+
...G(e, "icon", "bg", "br", "fg")
|
|
44
|
+
})), n = _(), v = o(() => {
|
|
45
|
+
switch (e.size) {
|
|
46
|
+
case "sm":
|
|
47
|
+
return "2xsm";
|
|
48
|
+
case "md":
|
|
49
|
+
case "lg":
|
|
50
|
+
return "xsm";
|
|
51
|
+
}
|
|
52
|
+
});
|
|
53
|
+
return (s, L) => (m(), c(i($), {
|
|
54
|
+
as: s.as,
|
|
55
|
+
class: x([
|
|
56
|
+
i(z)({
|
|
57
|
+
size: b.value,
|
|
58
|
+
borderless: s.borderless
|
|
59
|
+
}),
|
|
60
|
+
e.class
|
|
61
|
+
]),
|
|
62
|
+
tabindex: "0"
|
|
63
|
+
}, {
|
|
64
|
+
default: t(() => [
|
|
65
|
+
B(w, l(f(C.value)), I({ _: 2 }, [
|
|
66
|
+
h(Object.keys(n), (a) => ({
|
|
67
|
+
name: a,
|
|
68
|
+
fn: t(() => [
|
|
69
|
+
u(s.$slots, a, l(f(e)))
|
|
70
|
+
])
|
|
71
|
+
}))
|
|
72
|
+
]), 1040),
|
|
73
|
+
s.suffixIcon || n.suffixIcon ? (m(), c(T, {
|
|
74
|
+
key: 0,
|
|
75
|
+
icon: i(V)(s.suffixIcon) ? s.suffixIcon : void 0,
|
|
76
|
+
size: v.value
|
|
77
|
+
}, {
|
|
78
|
+
default: t(() => [
|
|
79
|
+
u(s.$slots, "suffixIcon")
|
|
80
|
+
]),
|
|
81
|
+
_: 3
|
|
82
|
+
}, 8, ["icon", "size"])) : k("", !0)
|
|
83
|
+
]),
|
|
84
|
+
_: 3
|
|
85
|
+
}, 8, ["as", "class"]));
|
|
86
|
+
}
|
|
87
|
+
});
|
|
88
|
+
export {
|
|
89
|
+
p as C,
|
|
90
|
+
J as _
|
|
91
|
+
};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
"use strict";const e=require("vue"),d=require("./GraphicalObject.vue_vue_type_script_setup_true_lang-DlMeNk_1.js"),f=require("./options-B4iSAKol.js"),o=require("./class-CjZYGZDW.js"),p=require("class-variance-authority"),_=require("./Primitive-BT1RjuGS.js"),z=require("./Icon.vue_vue_type_style_index_0_lang-BvHCdzZP.js"),v=require("./isString-CKmTJsel.js"),C=require("./pick-C-ap2Lj0.js"),i=["sm","md","lg"],b=e.defineComponent({...f.getComponentOptions("ColorTrigger"),__name:"ColorTrigger",props:{icon:{},bg:{},br:{},fg:{},as:{},class:{},size:{default:"md"},borderless:{type:Boolean},suffixIcon:{type:[Boolean,String],default:"tabler:chevron-down"}},setup(a){const s=a,t=o.getBemBlock("color_trigger"),l=p.cva(t,{variants:{size:o.generateVariantClassList(i,t),borderless:o.generateVariantClassList("borderless",t)}}),u=e.computed(()=>s.size&&i.includes(s.size)?s.size:"md"),g=e.computed(()=>({size:(()=>{switch(s.size){case"sm":return"2xsm";case"md":return"xsm";case"lg":return"sm"}})(),...C.pick(s,"icon","bg","br","fg")})),n=e.useSlots(),m=e.computed(()=>{switch(s.size){case"sm":return"2xsm";case"md":case"lg":return"xsm"}});return(r,S)=>(e.openBlock(),e.createBlock(e.unref(_.Primitive),{as:r.as,class:e.normalizeClass([e.unref(l)({size:u.value,borderless:r.borderless}),s.class]),tabindex:"0"},{default:e.withCtx(()=>[e.createVNode(d._sfc_main,e.normalizeProps(e.guardReactiveProps(g.value)),e.createSlots({_:2},[e.renderList(Object.keys(n),c=>({name:c,fn:e.withCtx(()=>[e.renderSlot(r.$slots,c,e.normalizeProps(e.guardReactiveProps(s)))])}))]),1040),r.suffixIcon||n.suffixIcon?(e.openBlock(),e.createBlock(z._sfc_main,{key:0,icon:e.unref(v.isString)(r.suffixIcon)?r.suffixIcon:void 0,size:m.value},{default:e.withCtx(()=>[e.renderSlot(r.$slots,"suffixIcon")]),_:3},8,["icon","size"])):e.createCommentVNode("",!0)]),_:3},8,["as","class"]))}});exports.ColorTriggerSizes=i;exports._sfc_main=b;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";Object.defineProperties(exports,{__esModule:{value:!0},[Symbol.toStringTag]:{value:"Module"}});const e=require("../FloatButton.vue_vue_type_script_setup_true_lang-
|
|
1
|
+
"use strict";Object.defineProperties(exports,{__esModule:{value:!0},[Symbol.toStringTag]:{value:"Module"}});const e=require("../FloatButton.vue_vue_type_script_setup_true_lang-C56u1xaL.js");exports.FloatButton=e._sfc_main;exports.default=e._sfc_main;
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { defineComponent as i, useAttrs as l, computed as m, ref as u, createBlock as f, openBlock as _, mergeProps as d, createSlots as b, renderList as g, withCtx as v, renderSlot as B, normalizeProps as k, guardReactiveProps as x } from "vue";
|
|
2
|
-
import { o as y } from "./omit-
|
|
3
|
-
import { _ as C } from "./BaseButton.vue_vue_type_style_index_0_lang-
|
|
2
|
+
import { o as y } from "./omit-BEkBWXra.js";
|
|
3
|
+
import { _ as C } from "./BaseButton.vue_vue_type_style_index_0_lang-BrQJfrgg.js";
|
|
4
4
|
import { g as P } from "./options-JBqnVZUl.js";
|
|
5
5
|
const I = /* @__PURE__ */ i({
|
|
6
6
|
...P("FloatButton", !1),
|
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";const e=require("vue"),l=require("./omit-
|
|
1
|
+
"use strict";const e=require("vue"),l=require("./omit-BKPbELUG.js"),p=require("./BaseButton.vue_vue_type_style_index_0_lang-CTK5nNR6.js"),_=require("./options-B4iSAKol.js"),f=e.defineComponent({..._.getComponentOptions("FloatButton",!1),__name:"FloatButton",props:{as:{},class:{},color:{},loading:{type:Boolean},size:{},icon:{},type:{}},setup(s,{expose:r}){const a=s,c=e.useAttrs(),i=e.computed(()=>({...l.omit(c,"variant","text","preIcon","postIcon","action","active","badgeText"),...a})),o=e.ref();return r({focus(){var t;(t=o.value)==null||t.focus()},blur(){var t;(t=o.value)==null||t.blur()}}),(t,m)=>(e.openBlock(),e.createBlock(p._sfc_main,e.mergeProps(i.value,{variant:"float",ref_key:"buttonRef",ref:o}),e.createSlots({_:2},[e.renderList(Object.keys(t.$slots),n=>({name:n,fn:e.withCtx(u=>[e.renderSlot(t.$slots,n,e.normalizeProps(e.guardReactiveProps(u)))])}))]),1040))}});exports._sfc_main=f;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";Object.defineProperties(exports,{__esModule:{value:!0},[Symbol.toStringTag]:{value:"Module"}});const e=require("../GraphicalObject.vue_vue_type_script_setup_true_lang-
|
|
1
|
+
"use strict";Object.defineProperties(exports,{__esModule:{value:!0},[Symbol.toStringTag]:{value:"Module"}});const e=require("../GraphicalObject.vue_vue_type_script_setup_true_lang-DlMeNk_1.js");exports.GraphicalObject=e._sfc_main;exports.default=e._sfc_main;
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { defineComponent as i, computed as n, useAttrs as m, createBlock as b, openBlock as f, mergeProps as u, createSlots as d, renderList as y, withCtx as _, renderSlot as h, normalizeProps as C, guardReactiveProps as O } from "vue";
|
|
2
|
-
import { o as j } from "./omit-
|
|
2
|
+
import { o as j } from "./omit-BEkBWXra.js";
|
|
3
3
|
import { a as B, B as $, _ as k } from "./BaseBadge.vue_vue_type_style_index_0_lang-MM6bsdzR.js";
|
|
4
4
|
import { g as v } from "./options-JBqnVZUl.js";
|
|
5
5
|
import { getCssVar as t } from "@pantograph/tokens";
|
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";const e=require("vue"),u=require("./omit-
|
|
1
|
+
"use strict";const e=require("vue"),u=require("./omit-BKPbELUG.js"),g=require("./BaseBadge.vue_vue_type_style_index_0_lang-OEeJw0Sy.js"),b=require("./options-B4iSAKol.js"),t=require("@pantograph/tokens"),m=e.defineComponent({...b.getComponentOptions("GraphicalObject",!1),__name:"GraphicalObject",props:{as:{},class:{},icon:{},fg:{},bg:{},br:{},size:{}},setup(c){const s=c,i=e.computed(()=>{const a=Object.fromEntries(g.BadgeColors.map(r=>[r,t.getCssVar(`${r}-5`)])),o={...a,...Object.fromEntries(g.BadgeColorsSubtle.map(r=>[r,t.getCssVar(`${r.replace("-subtle","")}-0`)])),transparent:"transparent","gray-subtle":t.getCssVar("gray-1")},n={...a,gray:t.getCssVar("gray-6"),default:t.getCssVar("gray-8"),"default-subtle":t.getCssVar("gray-5"),white:t.getCssVar("grayscale-light-0"),black:t.getCssVar("grayscale-light-10")};return{bg:o[s.bg]??s.bg,br:o[s.br]??(s.bg==="transparent"?t.getCssVar("gray-2"):void 0),fg:n[s.fg??"default"]??s.fg}}),l=e.useAttrs(),p=e.computed(()=>({...u.omit(l,"type","text"),...s,...i.value}));return(a,o)=>(e.openBlock(),e.createBlock(g._sfc_main,e.mergeProps(p.value,{type:"rect"}),e.createSlots({_:2},[e.renderList(Object.keys(a.$slots),n=>({name:n,fn:e.withCtx(r=>[e.renderSlot(a.$slots,n,e.normalizeProps(e.guardReactiveProps(r)))])}))]),1040))}});exports._sfc_main=m;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";Object.defineProperties(exports,{__esModule:{value:!0},[Symbol.toStringTag]:{value:"Module"}});const e=require("../IconButton.vue_vue_type_script_setup_true_lang-
|
|
1
|
+
"use strict";Object.defineProperties(exports,{__esModule:{value:!0},[Symbol.toStringTag]:{value:"Module"}});const e=require("../IconButton.vue_vue_type_script_setup_true_lang-7QB-mmyg.js");exports.IconButton=e._sfc_main;exports.default=e._sfc_main;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";const e=require("vue"),p=require("./omit-
|
|
1
|
+
"use strict";const e=require("vue"),p=require("./omit-BKPbELUG.js"),l=require("./BaseButton.vue_vue_type_style_index_0_lang-CTK5nNR6.js"),_=require("./options-B4iSAKol.js"),f=e.defineComponent({..._.getComponentOptions("IconButton",!1),__name:"IconButton",props:{as:{},class:{},type:{},color:{},loading:{type:Boolean},icon:{},size:{}},setup(s,{expose:r}){const c=s,a=e.useAttrs(),i=e.computed(()=>({...p.omit(a,"variant","preIcon","postIcon","text","action","active","badgeText"),...c})),o=e.ref();return r({focus(){var t;(t=o.value)==null||t.focus()},blur(){var t;(t=o.value)==null||t.blur()}}),(t,m)=>(e.openBlock(),e.createBlock(l._sfc_main,e.mergeProps(i.value,{variant:"icon",ref_key:"buttonRef",ref:o}),e.createSlots({_:2},[e.renderList(Object.keys(t.$slots),n=>({name:n,fn:e.withCtx(u=>[e.renderSlot(t.$slots,n,e.normalizeProps(e.guardReactiveProps(u)))])}))]),1040))}});exports._sfc_main=f;
|