mhz-ui 1.3.21 → 1.3.23

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.
Files changed (59) hide show
  1. package/dist/UiBreadcrumbs/UiBreadcrumbs.css +1 -1
  2. package/dist/UiBreadcrumbs/UiBreadcrumbs.js +61 -63
  3. package/dist/UiButton/UiButton.css +1 -1
  4. package/dist/UiButton/UiButton.js +2 -41
  5. package/dist/UiButton-DkJNVTgF.js +45 -0
  6. package/dist/UiButtongroup/UiButtongroup.css +1 -1
  7. package/dist/UiButtongroup/UiButtongroup.js +50 -60
  8. package/dist/UiCalendar/UiCalendar.css +1 -1
  9. package/dist/UiCalendar/UiCalendar.js +128 -157
  10. package/dist/UiChart/UiChart.css +1 -1
  11. package/dist/UiChart/UiChart.js +7573 -8093
  12. package/dist/UiCheckbox/UiCheckbox.css +1 -1
  13. package/dist/UiCheckbox/UiCheckbox.js +116 -105
  14. package/dist/UiChip/UiChip.css +1 -1
  15. package/dist/UiChip/UiChip.js +48 -56
  16. package/dist/UiClose/UiClose.css +1 -1
  17. package/dist/UiClose/UiClose.js +2 -33
  18. package/dist/UiClose-BQmeCbRi.js +22 -0
  19. package/dist/UiEditor/UiEditor.css +1 -1
  20. package/dist/UiEditor/UiEditor.js +13012 -16496
  21. package/dist/UiField/UiField.css +1 -1
  22. package/dist/UiField/UiField.js +29 -42
  23. package/dist/UiFlex/UiFlex.css +1 -1
  24. package/dist/UiFlex/UiFlex.js +42 -43
  25. package/dist/UiInput/UiInput.css +1 -1
  26. package/dist/UiInput/UiInput.js +2 -125
  27. package/dist/UiInput-DHFttLTG.js +133 -0
  28. package/dist/UiModal/UiModal.css +1 -1
  29. package/dist/UiModal/UiModal.js +74 -106
  30. package/dist/UiPagination/UiPagination.css +1 -1
  31. package/dist/UiPagination/UiPagination.js +50 -58
  32. package/dist/UiRange/UiRange.css +1 -1
  33. package/dist/UiRange/UiRange.js +1384 -918
  34. package/dist/UiSearch/UiSearch.css +1 -1
  35. package/dist/UiSearch/UiSearch.js +118 -143
  36. package/dist/UiSelect/UiSelect.css +1 -1
  37. package/dist/UiSelect/UiSelect.js +167 -171
  38. package/dist/UiSlider/UiSlider.css +1 -1
  39. package/dist/UiSlider/UiSlider.js +41 -56
  40. package/dist/UiSpoiler/UiSpoiler.css +1 -1
  41. package/dist/UiSpoiler/UiSpoiler.js +51 -79
  42. package/dist/UiTable/UiTable.css +1 -1
  43. package/dist/UiTable/UiTable.js +76 -97
  44. package/dist/UiTabs/UiTabs.css +1 -1
  45. package/dist/UiTabs/UiTabs.js +24 -32
  46. package/dist/UiTextarea/UiTextarea.css +1 -1
  47. package/dist/UiTextarea/UiTextarea.js +25 -31
  48. package/dist/UiUpload/UiUpload.css +1 -1
  49. package/dist/UiUpload/UiUpload.js +123 -166
  50. package/dist/_plugin-vue_export-helper-Bt71PsSa.js +6 -0
  51. package/dist/dist-CLA-k87a.js +109 -0
  52. package/dist/locales-DIKIa9I3.js +29 -0
  53. package/dist/stubs/stubs.js +13 -15
  54. package/dist/toast/toast.css +1 -1
  55. package/dist/toast/toast.js +43 -41
  56. package/package.json +29 -29
  57. package/dist/_plugin-vue_export-helper-CHgC5LLL.js +0 -9
  58. package/dist/index-DajWja1y.js +0 -31
  59. package/dist/index-Dvnq-rTV.js +0 -109
@@ -1,176 +1,172 @@
1
1
  import "./UiSelect.css";
2
- import { createElementBlock as l, openBlock as s, createElementVNode as B, defineComponent as W, ref as u, computed as b, normalizeClass as p, createCommentVNode as F, createVNode as M, unref as m, Fragment as X, renderList as Y, withKeys as f, withModifiers as D, toDisplayString as T } from "vue";
3
- import { o as Z } from "../index-Dvnq-rTV.js";
4
- import N from "../UiInput/UiInput.js";
5
- import { M as O } from "../index-DajWja1y.js";
6
- import { _ as x } from "../_plugin-vue_export-helper-CHgC5LLL.js";
7
- const ee = {
8
- xmlns: "http://www.w3.org/2000/svg",
9
- width: "16",
10
- height: "16",
11
- fill: "none"
2
+ import { t as _plugin_vue_export_helper_default } from "../_plugin-vue_export-helper-Bt71PsSa.js";
3
+ import { t as UiInput_default } from "../UiInput-DHFttLTG.js";
4
+ import { t as MESSAGES } from "../locales-DIKIa9I3.js";
5
+ import { t as onClickOutside } from "../dist-CLA-k87a.js";
6
+ import { Fragment, computed, createCommentVNode, createElementBlock, createElementVNode, createVNode, defineComponent, normalizeClass, openBlock, ref, renderList, toDisplayString, unref, withKeys, withModifiers } from "vue";
7
+ var _hoisted_1$2 = {
8
+ xmlns: "http://www.w3.org/2000/svg",
9
+ width: "16",
10
+ height: "16",
11
+ fill: "none"
12
12
  };
13
- function te(h, i) {
14
- return s(), l("svg", ee, [...i[0] || (i[0] = [
15
- B("path", {
16
- stroke: "#1F1F1F",
17
- "stroke-linecap": "round",
18
- "stroke-linejoin": "round",
19
- d: "m1 5 7.17 6L15 5"
20
- }, null, -1)
21
- ])]);
13
+ function render$1(e, t) {
14
+ return openBlock(), createElementBlock("svg", _hoisted_1$2, [...t[0] ||= [createElementVNode("path", {
15
+ stroke: "#1F1F1F",
16
+ "stroke-linecap": "round",
17
+ "stroke-linejoin": "round",
18
+ d: "m1 5 7.17 6L15 5"
19
+ }, null, -1)]]);
22
20
  }
23
- const oe = { render: te }, ne = {
24
- xmlns: "http://www.w3.org/2000/svg",
25
- width: "16",
26
- height: "16",
27
- fill: "none"
21
+ var closed_default = { render: render$1 }, _hoisted_1$1 = {
22
+ xmlns: "http://www.w3.org/2000/svg",
23
+ width: "16",
24
+ height: "16",
25
+ fill: "none"
28
26
  };
29
- function le(h, i) {
30
- return s(), l("svg", ne, [...i[0] || (i[0] = [
31
- B("path", {
32
- stroke: "#1F1F1F",
33
- "stroke-linecap": "round",
34
- "stroke-linejoin": "round",
35
- d: "m1 11 7.17-6L15 11"
36
- }, null, -1)
37
- ])]);
27
+ function render(e, t) {
28
+ return openBlock(), createElementBlock("svg", _hoisted_1$1, [...t[0] ||= [createElementVNode("path", {
29
+ stroke: "#1F1F1F",
30
+ "stroke-linecap": "round",
31
+ "stroke-linejoin": "round",
32
+ d: "m1 11 7.17-6L15 11"
33
+ }, null, -1)]]);
38
34
  }
39
- const se = { render: le }, ie = { key: 0 }, re = ["onClick", "onKeydown", "onMouseenter", "data-current"], j = 240, ae = /* @__PURE__ */ W({
40
- __name: "UiSelect",
41
- props: {
42
- modelValue: { default: void 0 },
43
- options: { default: () => [] },
44
- isFilter: { type: Boolean },
45
- isDisabled: { type: Boolean },
46
- lang: { default: "ru" },
47
- isLocaleField: { type: Boolean },
48
- isClearable: { type: Boolean }
49
- },
50
- emits: ["update:modelValue", "reachedBottom"],
51
- setup(h, { emit: i }) {
52
- const t = h, k = i, v = u(""), c = u(!1), V = u(!1), d = u(), r = u(), g = u(), E = u([]), $ = b(() => {
53
- const e = t.options?.[0];
54
- return e != null && typeof e == "object";
55
- }), I = (e) => e !== null && (typeof e == "string" || typeof e == "number"), w = b(() => {
56
- if (!t.options?.length) return [];
57
- const e = $.value ? [...t.options] : t.options.map((o) => ({ _id: String(o), title: String(o) }));
58
- return t.isFilter ? e.filter((o) => o.title.toLowerCase().includes(v.value.toLowerCase())) : e;
59
- }), A = b(() => {
60
- if (I(t.modelValue)) return t.modelValue;
61
- if (!t.modelValue) return "";
62
- const e = t.modelValue;
63
- return t.isLocaleField ? e.title_en ?? "" : e.title ?? "";
64
- }), H = (e, o) => `${e._id || e.title}-${o}`, K = (e) => t.isLocaleField ? e.title_en : e.title, P = (e) => I(t.modelValue) ? t.modelValue === (e._id || e.title) : t.modelValue ? t.modelValue._id === e._id : !1, _ = (e) => {
65
- e < 0 || e >= w.value.length || t.isFilter || E.value[e]?.focus();
66
- }, G = () => k("update:modelValue", void 0), S = () => {
67
- c.value ? y() : Q();
68
- }, z = () => {
69
- if (!d.value) return !1;
70
- const e = d.value.closest("dialog");
71
- if (!e) {
72
- const R = d.value.getBoundingClientRect(), U = window.innerHeight - R.bottom, J = R.top;
73
- return U < j && J > U;
74
- }
75
- const o = e.getBoundingClientRect(), n = d.value.getBoundingClientRect(), a = o.bottom - n.bottom, q = n.top - o.top;
76
- return a < j && q > a;
77
- };
78
- function y() {
79
- r.value?.removeEventListener("scroll", L, !0), v.value = "", c.value = !1, V.value = !1;
80
- }
81
- function Q() {
82
- t.isDisabled || (V.value = z(), c.value = !0, t.isFilter || setTimeout(() => {
83
- r.value?.scrollTo(0, 0), _(0), r.value?.addEventListener("scroll", L, !0);
84
- }, 100));
85
- }
86
- function C(e) {
87
- const o = $.value ? e : e._id || e.title;
88
- k("update:modelValue", o), y();
89
- }
90
- function L() {
91
- if (!r.value || !g.value) return;
92
- r.value.getBoundingClientRect().y - g.value.getBoundingClientRect().y - g.value.scrollHeight + r.value.getBoundingClientRect().height > -100 && k("reachedBottom");
93
- }
94
- return Z(d, y), (e, o) => (s(), l("div", {
95
- class: p(e.$style.container),
96
- ref_key: "containerElement",
97
- ref: d
98
- }, [
99
- B("div", {
100
- class: p(e.$style.input)
101
- }, [
102
- M(N, {
103
- modelValue: A.value,
104
- disabled: t.isDisabled,
105
- onToggle: S,
106
- mode: "select",
107
- placeholder: m(O)[t.lang].choose,
108
- appendIcon: c.value ? m(se) : m(oe)
109
- }, null, 8, ["modelValue", "disabled", "placeholder", "appendIcon"]),
110
- t.isFilter && c.value ? (s(), l("div", ie, [
111
- M(N, {
112
- modelValue: v.value,
113
- "onUpdate:modelValue": o[0] || (o[0] = (n) => v.value = n),
114
- disabled: t.isDisabled,
115
- placeholder: m(O)[t.lang].filter,
116
- isFocus: ""
117
- }, null, 8, ["modelValue", "disabled", "placeholder"])
118
- ])) : F("", !0),
119
- t.isClearable && t.modelValue ? (s(), l("button", {
120
- key: 1,
121
- onClick: G,
122
- type: "button",
123
- class: p(e.$style.clear)
124
- }, " × ", 2)) : F("", !0)
125
- ], 2),
126
- c.value ? (s(), l("div", {
127
- key: 0,
128
- class: p([e.$style.options, { [e.$style.optionsUp]: V.value }]),
129
- ref_key: "optionsElement",
130
- ref: r
131
- }, [
132
- w.value.length > 0 ? (s(), l("div", {
133
- key: 0,
134
- ref_key: "optionsInnerElement",
135
- ref: g
136
- }, [
137
- (s(!0), l(X, null, Y(w.value, (n, a) => (s(), l("div", {
138
- key: H(n, a),
139
- onClick: () => C(n),
140
- onKeydown: [
141
- f(() => C(n), ["enter"]),
142
- f(() => C(n), ["space"]),
143
- f(D(() => _(a - 1), ["prevent"]), ["up"]),
144
- f(D(() => _(a + 1), ["prevent"]), ["down"]),
145
- f(S, ["esc"])
146
- ],
147
- onMouseenter: () => _(a),
148
- class: p(e.$style.option),
149
- tabindex: "0",
150
- ref_for: !0,
151
- ref_key: "optionElement",
152
- ref: E,
153
- "data-current": P(n)
154
- }, T(K(n)), 43, re))), 128))
155
- ], 512)) : (s(), l("div", {
156
- key: 1,
157
- onClick: y,
158
- class: p(e.$style.option),
159
- tabindex: "0"
160
- }, T(m(O)[t.lang].noResults), 3))
161
- ], 2)) : F("", !0)
162
- ], 2));
163
- }
164
- }), ue = "_container_1m448_1", ce = "_input_1m448_10", de = "_clear_1m448_16", pe = "_options_1m448_31", me = "_optionsUp_1m448_44", fe = "_option_1m448_31", ve = {
165
- container: ue,
166
- input: ce,
167
- clear: de,
168
- options: pe,
169
- optionsUp: me,
170
- option: fe
171
- }, ge = {
172
- $style: ve
173
- }, we = /* @__PURE__ */ x(ae, [["__cssModules", ge]]);
174
- export {
175
- we as default
176
- };
35
+ var opened_default = { render }, _hoisted_1 = { key: 0 }, _hoisted_2 = [
36
+ "onClick",
37
+ "onKeydown",
38
+ "onMouseenter",
39
+ "data-current"
40
+ ], MIN_OPTIONS_HEIGHT = 240, UiSelect_default = /* @__PURE__ */ _plugin_vue_export_helper_default(/* @__PURE__ */ defineComponent({
41
+ __name: "UiSelect",
42
+ props: {
43
+ modelValue: { default: void 0 },
44
+ options: { default: () => [] },
45
+ isFilter: { type: Boolean },
46
+ isDisabled: { type: Boolean },
47
+ lang: { default: "ru" },
48
+ isLocaleField: { type: Boolean },
49
+ isClearable: { type: Boolean }
50
+ },
51
+ emits: ["update:modelValue", "reachedBottom"],
52
+ setup(e, { emit: a }) {
53
+ let o = e, s = a, c = ref(""), l = ref(!1), u = ref(!1), d = ref(), f = ref(), p = ref(), m = ref([]), h = computed(() => {
54
+ let e = o.options?.[0];
55
+ return typeof e == "object" && !!e;
56
+ }), g = (e) => e !== null && (typeof e == "string" || typeof e == "number"), _ = computed(() => {
57
+ if (!o.options?.length) return [];
58
+ let e = h.value ? [...o.options] : o.options.map((e) => ({
59
+ _id: String(e),
60
+ title: String(e)
61
+ }));
62
+ return o.isFilter ? e.filter((e) => e.title.toLowerCase().includes(c.value.toLowerCase())) : e;
63
+ }), v = computed(() => {
64
+ if (g(o.modelValue)) return o.modelValue;
65
+ if (!o.modelValue) return "";
66
+ let e = o.modelValue;
67
+ return o.isLocaleField ? e.title_en ?? "" : e.title ?? "";
68
+ }), y = (e, t) => `${e._id || e.title}-${t}`, b = (e) => o.isLocaleField ? e.title_en : e.title, x = (e) => g(o.modelValue) ? o.modelValue === (e._id || e.title) : o.modelValue ? o.modelValue._id === e._id : !1, S = (e) => {
69
+ e < 0 || e >= _.value.length || o.isFilter || m.value[e]?.focus();
70
+ }, C = () => s("update:modelValue", void 0), w = () => {
71
+ l.value ? E() : D();
72
+ }, T = () => {
73
+ if (!d.value) return !1;
74
+ let e = d.value.closest("dialog");
75
+ if (!e) {
76
+ let e = d.value.getBoundingClientRect(), t = window.innerHeight - e.bottom, n = e.top;
77
+ return t < MIN_OPTIONS_HEIGHT && n > t;
78
+ }
79
+ let t = e.getBoundingClientRect(), n = d.value.getBoundingClientRect(), r = t.bottom - n.bottom, i = n.top - t.top;
80
+ return r < MIN_OPTIONS_HEIGHT && i > r;
81
+ };
82
+ function E() {
83
+ f.value?.removeEventListener("scroll", k, !0), c.value = "", l.value = !1, u.value = !1;
84
+ }
85
+ function D() {
86
+ o.isDisabled || (u.value = T(), l.value = !0, o.isFilter || setTimeout(() => {
87
+ f.value?.scrollTo(0, 0), S(0), f.value?.addEventListener("scroll", k, !0);
88
+ }, 100));
89
+ }
90
+ function O(e) {
91
+ s("update:modelValue", h.value ? e : e._id || e.title), E();
92
+ }
93
+ function k() {
94
+ !f.value || !p.value || f.value.getBoundingClientRect().y - p.value.getBoundingClientRect().y - p.value.scrollHeight + f.value.getBoundingClientRect().height > -100 && s("reachedBottom");
95
+ }
96
+ return onClickOutside(d, E), (e, r) => (openBlock(), createElementBlock("div", {
97
+ class: normalizeClass(e.$style.container),
98
+ ref_key: "containerElement",
99
+ ref: d
100
+ }, [createElementVNode("div", { class: normalizeClass(e.$style.input) }, [
101
+ createVNode(UiInput_default, {
102
+ modelValue: v.value,
103
+ disabled: o.isDisabled,
104
+ onToggle: w,
105
+ mode: "select",
106
+ placeholder: unref(MESSAGES)[o.lang].choose,
107
+ appendIcon: l.value ? unref(opened_default) : unref(closed_default)
108
+ }, null, 8, [
109
+ "modelValue",
110
+ "disabled",
111
+ "placeholder",
112
+ "appendIcon"
113
+ ]),
114
+ o.isFilter && l.value ? (openBlock(), createElementBlock("div", _hoisted_1, [createVNode(UiInput_default, {
115
+ modelValue: c.value,
116
+ "onUpdate:modelValue": r[0] ||= (e) => c.value = e,
117
+ disabled: o.isDisabled,
118
+ placeholder: unref(MESSAGES)[o.lang].filter,
119
+ isFocus: ""
120
+ }, null, 8, [
121
+ "modelValue",
122
+ "disabled",
123
+ "placeholder"
124
+ ])])) : createCommentVNode("", !0),
125
+ o.isClearable && o.modelValue ? (openBlock(), createElementBlock("button", {
126
+ key: 1,
127
+ onClick: C,
128
+ type: "button",
129
+ class: normalizeClass(e.$style.clear)
130
+ }, " × ", 2)) : createCommentVNode("", !0)
131
+ ], 2), l.value ? (openBlock(), createElementBlock("div", {
132
+ key: 0,
133
+ class: normalizeClass([e.$style.options, { [e.$style.optionsUp]: u.value }]),
134
+ ref_key: "optionsElement",
135
+ ref: f
136
+ }, [_.value.length > 0 ? (openBlock(), createElementBlock("div", {
137
+ key: 0,
138
+ ref_key: "optionsInnerElement",
139
+ ref: p
140
+ }, [(openBlock(!0), createElementBlock(Fragment, null, renderList(_.value, (t, n) => (openBlock(), createElementBlock("div", {
141
+ key: y(t, n),
142
+ onClick: () => O(t),
143
+ onKeydown: [
144
+ withKeys(() => O(t), ["enter"]),
145
+ withKeys(() => O(t), ["space"]),
146
+ withKeys(withModifiers(() => S(n - 1), ["prevent"]), ["up"]),
147
+ withKeys(withModifiers(() => S(n + 1), ["prevent"]), ["down"]),
148
+ withKeys(w, ["esc"])
149
+ ],
150
+ onMouseenter: () => S(n),
151
+ class: normalizeClass(e.$style.option),
152
+ tabindex: "0",
153
+ ref_for: !0,
154
+ ref_key: "optionElement",
155
+ ref: m,
156
+ "data-current": x(t)
157
+ }, toDisplayString(b(t)), 43, _hoisted_2))), 128))], 512)) : (openBlock(), createElementBlock("div", {
158
+ key: 1,
159
+ onClick: E,
160
+ class: normalizeClass(e.$style.option),
161
+ tabindex: "0"
162
+ }, toDisplayString(unref(MESSAGES)[o.lang].noResults), 3))], 2)) : createCommentVNode("", !0)], 2));
163
+ }
164
+ }), [["__cssModules", { $style: {
165
+ container: "_container_1m448_1",
166
+ input: "_input_1m448_10",
167
+ clear: "_clear_1m448_16",
168
+ options: "_options_1m448_31",
169
+ optionsUp: "_optionsUp_1m448_44",
170
+ option: "_option_1m448_31"
171
+ } }]]);
172
+ export { UiSelect_default as default };
@@ -1 +1 @@
1
- ._container_zamf0_1{display:flex;gap:8px}._thumbs_zamf0_6{display:flex;flex-shrink:0;flex-direction:column;gap:8px}._thumb_zamf0_6{padding:8px;cursor:pointer;background:none;border:1px solid var(--color-gray);border-radius:8px}._thumb_zamf0_6:hover,._thumb_zamf0_6[data-active=true]{border:1px solid var(--color-gray-dark-extra)}._slide_zamf0_24{flex-grow:1}@media(max-width:960px){._container_zamf0_1{flex-direction:column;gap:16px}._thumbs_zamf0_6{flex-direction:row}}
1
+ ._container_zamf0_1{gap:8px;display:flex}._thumbs_zamf0_6{flex-direction:column;flex-shrink:0;gap:8px;display:flex}._thumb_zamf0_6{cursor:pointer;border:1px solid var(--color-gray);background:0 0;border-radius:8px;padding:8px}._thumb_zamf0_6:hover,._thumb_zamf0_6[data-active=true]{border:1px solid var(--color-gray-dark-extra)}._slide_zamf0_24{flex-grow:1}@media (max-width:960px){._container_zamf0_1{flex-direction:column;gap:16px}._thumbs_zamf0_6{flex-direction:row}}
@@ -1,57 +1,42 @@
1
1
  import "./UiSlider.css";
2
- import { defineComponent as u, ref as d, createElementBlock as i, openBlock as c, normalizeClass as a, createElementVNode as l, Fragment as m, renderList as _ } from "vue";
3
- import { _ as h } from "../_plugin-vue_export-helper-CHgC5LLL.js";
4
- const p = ["onClick", "data-active"], v = ["src", "alt"], $ = ["src", "alt", "data-slide"], b = /* @__PURE__ */ u({
5
- __name: "UiSlider",
6
- props: {
7
- thumbs: {},
8
- slides: {},
9
- path: {}
10
- },
11
- setup(r) {
12
- const s = r, t = d(0);
13
- return (e, S) => (c(), i("div", {
14
- class: a(e.$style.container)
15
- }, [
16
- l("div", {
17
- class: a(e.$style.thumbs)
18
- }, [
19
- (c(!0), i(m, null, _(s.thumbs, (o, n) => (c(), i("button", {
20
- key: o,
21
- onClick: (B) => t.value = n,
22
- type: "button",
23
- class: a(e.$style.thumb),
24
- "data-active": t.value === n
25
- }, [
26
- l("img", {
27
- src: s.path ? `${s.path}${o}` : o,
28
- width: "64",
29
- height: "64",
30
- alt: `thumb-${n}`,
31
- crossorigin: "anonymous"
32
- }, null, 8, v)
33
- ], 10, p))), 128))
34
- ], 2),
35
- l("div", {
36
- class: a(e.$style.slide)
37
- }, [
38
- l("img", {
39
- src: s.path ? `${s.path}${s.slides[t.value]}` : s.slides[t.value],
40
- alt: `slide-${t.value}`,
41
- crossorigin: "anonymous",
42
- "data-slide": t.value
43
- }, null, 8, $)
44
- ], 2)
45
- ], 2));
46
- }
47
- }), f = "_container_zamf0_1", y = "_thumbs_zamf0_6", g = "_thumb_zamf0_6", k = "_slide_zamf0_24", z = {
48
- container: f,
49
- thumbs: y,
50
- thumb: g,
51
- slide: k
52
- }, C = {
53
- $style: z
54
- }, U = /* @__PURE__ */ h(b, [["__cssModules", C]]);
55
- export {
56
- U as default
57
- };
2
+ import { t as _plugin_vue_export_helper_default } from "../_plugin-vue_export-helper-Bt71PsSa.js";
3
+ import { Fragment, createElementBlock, createElementVNode, defineComponent, normalizeClass, openBlock, ref, renderList } from "vue";
4
+ var _hoisted_1 = ["onClick", "data-active"], _hoisted_2 = ["src", "alt"], _hoisted_3 = [
5
+ "src",
6
+ "alt",
7
+ "data-slide"
8
+ ], UiSlider_default = /* @__PURE__ */ _plugin_vue_export_helper_default(/* @__PURE__ */ defineComponent({
9
+ __name: "UiSlider",
10
+ props: {
11
+ thumbs: {},
12
+ slides: {},
13
+ path: {}
14
+ },
15
+ setup(e) {
16
+ let n = e, i = ref(0);
17
+ return (e, r) => (openBlock(), createElementBlock("div", { class: normalizeClass(e.$style.container) }, [createElementVNode("div", { class: normalizeClass(e.$style.thumbs) }, [(openBlock(!0), createElementBlock(Fragment, null, renderList(n.thumbs, (t, r) => (openBlock(), createElementBlock("button", {
18
+ key: t,
19
+ onClick: (e) => i.value = r,
20
+ type: "button",
21
+ class: normalizeClass(e.$style.thumb),
22
+ "data-active": i.value === r
23
+ }, [createElementVNode("img", {
24
+ src: n.path ? `${n.path}${t}` : t,
25
+ width: "64",
26
+ height: "64",
27
+ alt: `thumb-${r}`,
28
+ crossorigin: "anonymous"
29
+ }, null, 8, _hoisted_2)], 10, _hoisted_1))), 128))], 2), createElementVNode("div", { class: normalizeClass(e.$style.slide) }, [createElementVNode("img", {
30
+ src: n.path ? `${n.path}${n.slides[i.value]}` : n.slides[i.value],
31
+ alt: `slide-${i.value}`,
32
+ crossorigin: "anonymous",
33
+ "data-slide": i.value
34
+ }, null, 8, _hoisted_3)], 2)], 2));
35
+ }
36
+ }), [["__cssModules", { $style: {
37
+ container: "_container_zamf0_1",
38
+ thumbs: "_thumbs_zamf0_6",
39
+ thumb: "_thumb_zamf0_6",
40
+ slide: "_slide_zamf0_24"
41
+ } }]]);
42
+ export { UiSlider_default as default };
@@ -1 +1 @@
1
- ._container_1hyai_1{display:flex;flex-direction:column;width:100%}._titleBlock_1hyai_7{display:flex;gap:8px;align-items:center;padding:0;background-color:var(--color-gray-light-extra);border:0;border-radius:4px}._titleBlock_1hyai_7:hover{background-color:var(--color-gray-light)}._title_1hyai_7{position:relative;z-index:1;display:flex;flex-grow:1;gap:8px;align-items:center;height:40px;padding:0 12px;font-size:1rem;text-align:left;cursor:pointer;background:none;border:none}._titleText_1hyai_36{display:-webkit-box;overflow:hidden;-webkit-line-clamp:2;font-size:.875rem;line-height:1.2;color:var(--color-black);-webkit-box-orient:vertical}._icon_1hyai_46{display:flex;flex-shrink:0;align-items:center;transform:rotate(-90deg);transition:transform .3s ease}._icon_1hyai_46[data-expanded=true]{transform:rotate(0)}._spoilerWrapper_1hyai_57{display:grid;grid-template-rows:0fr;transition:grid-template-rows .3s ease}._spoilerWrapper_1hyai_57[data-expanded=true]{grid-template-rows:1fr}._spoilerContent_1hyai_66{overflow:hidden}._spoilerContent_1hyai_66[data-expanded=true]{overflow:visible}._spoilerInner_1hyai_73{padding:8px 0}.dark ._titleBlock_1hyai_7{color:var(--color-white);background-color:var(--color-gray-dark-extra)}.dark ._titleText_1hyai_36,.dark ._spoilerInner_1hyai_73{color:var(--color-white)}
1
+ ._container_1hyai_1{flex-direction:column;width:100%;display:flex}._titleBlock_1hyai_7{background-color:var(--color-gray-light-extra);border:0;border-radius:4px;align-items:center;gap:8px;padding:0;display:flex}._titleBlock_1hyai_7:hover{background-color:var(--color-gray-light)}._title_1hyai_7{z-index:1;text-align:left;cursor:pointer;background:0 0;border:none;flex-grow:1;align-items:center;gap:8px;height:40px;padding:0 12px;font-size:1rem;display:flex;position:relative}._titleText_1hyai_36{-webkit-line-clamp:2;color:var(--color-black);-webkit-box-orient:vertical;font-size:.875rem;line-height:1.2;display:-webkit-box;overflow:hidden}._icon_1hyai_46{flex-shrink:0;align-items:center;transition:transform .3s;display:flex;transform:rotate(-90deg)}._icon_1hyai_46[data-expanded=true]{transform:rotate(0)}._spoilerWrapper_1hyai_57{grid-template-rows:0fr;transition:grid-template-rows .3s;display:grid}._spoilerWrapper_1hyai_57[data-expanded=true]{grid-template-rows:1fr}._spoilerContent_1hyai_66{overflow:hidden}._spoilerContent_1hyai_66[data-expanded=true]{overflow:visible}._spoilerInner_1hyai_73{padding:8px 0}.dark ._titleBlock_1hyai_7{color:var(--color-white);background-color:var(--color-gray-dark-extra)}.dark ._titleText_1hyai_36,.dark ._spoilerInner_1hyai_73{color:var(--color-white)}
@@ -1,82 +1,54 @@
1
1
  import "./UiSpoiler.css";
2
- import { createElementBlock as r, openBlock as a, createElementVNode as o, defineComponent as p, normalizeClass as t, createVNode as c, unref as _, toDisplayString as u, renderSlot as m } from "vue";
3
- import { _ as y } from "../_plugin-vue_export-helper-CHgC5LLL.js";
4
- const h = {
5
- xmlns: "http://www.w3.org/2000/svg",
6
- width: "16",
7
- height: "16",
8
- fill: "none"
2
+ import { t as _plugin_vue_export_helper_default } from "../_plugin-vue_export-helper-Bt71PsSa.js";
3
+ import { createElementBlock, createElementVNode, createVNode, defineComponent, normalizeClass, openBlock, renderSlot, toDisplayString, unref } from "vue";
4
+ var _hoisted_1$1 = {
5
+ xmlns: "http://www.w3.org/2000/svg",
6
+ width: "16",
7
+ height: "16",
8
+ fill: "none"
9
9
  };
10
- function $(s, n) {
11
- return a(), r("svg", h, [...n[0] || (n[0] = [
12
- o("path", {
13
- stroke: "currentColor",
14
- "stroke-linecap": "round",
15
- "stroke-linejoin": "round",
16
- d: "m1 5 7.17 6L15 5"
17
- }, null, -1)
18
- ])]);
10
+ function render(e, t) {
11
+ return openBlock(), createElementBlock("svg", _hoisted_1$1, [...t[0] ||= [createElementVNode("path", {
12
+ stroke: "currentColor",
13
+ "stroke-linecap": "round",
14
+ "stroke-linejoin": "round",
15
+ d: "m1 5 7.17 6L15 5"
16
+ }, null, -1)]]);
19
17
  }
20
- const f = { render: $ }, k = ["data-expanded"], V = ["data-expanded"], v = /* @__PURE__ */ p({
21
- __name: "UiSpoiler",
22
- props: {
23
- modelValue: { type: Boolean },
24
- title: {}
25
- },
26
- emits: ["update:modelValue"],
27
- setup(s, { emit: n }) {
28
- const l = s, d = n;
29
- return (e, i) => (a(), r("div", {
30
- class: t(e.$style.container)
31
- }, [
32
- o("button", {
33
- onClick: i[0] || (i[0] = (E) => d("update:modelValue", !l.modelValue)),
34
- class: t(e.$style.titleBlock),
35
- type: "button"
36
- }, [
37
- o("div", {
38
- class: t(e.$style.title)
39
- }, [
40
- c(_(f), {
41
- "data-expanded": l.modelValue,
42
- class: t(e.$style.icon),
43
- width: "16",
44
- height: "16"
45
- }, null, 8, ["data-expanded", "class"]),
46
- o("span", {
47
- class: t(e.$style.titleText)
48
- }, u(l.title), 3)
49
- ], 2)
50
- ], 2),
51
- o("div", {
52
- class: t(e.$style.spoilerWrapper),
53
- "data-expanded": l.modelValue
54
- }, [
55
- o("div", {
56
- class: t(e.$style.spoilerContent),
57
- "data-expanded": l.modelValue
58
- }, [
59
- o("div", {
60
- class: t(e.$style.spoilerInner)
61
- }, [
62
- m(e.$slots, "default")
63
- ], 2)
64
- ], 10, V)
65
- ], 10, k)
66
- ], 2));
67
- }
68
- }), C = "_container_1hyai_1", w = "_titleBlock_1hyai_7", B = "_title_1hyai_7", g = "_titleText_1hyai_36", x = "_icon_1hyai_46", I = "_spoilerWrapper_1hyai_57", S = "_spoilerContent_1hyai_66", T = "_spoilerInner_1hyai_73", W = {
69
- container: C,
70
- titleBlock: w,
71
- title: B,
72
- titleText: g,
73
- icon: x,
74
- spoilerWrapper: I,
75
- spoilerContent: S,
76
- spoilerInner: T
77
- }, b = {
78
- $style: W
79
- }, U = /* @__PURE__ */ y(v, [["__cssModules", b]]);
80
- export {
81
- U as default
82
- };
18
+ var arrow_default = { render }, _hoisted_1 = ["data-expanded"], _hoisted_2 = ["data-expanded"], UiSpoiler_default = /* @__PURE__ */ _plugin_vue_export_helper_default(/* @__PURE__ */ defineComponent({
19
+ __name: "UiSpoiler",
20
+ props: {
21
+ modelValue: { type: Boolean },
22
+ title: {}
23
+ },
24
+ emits: ["update:modelValue"],
25
+ setup(e, { emit: n }) {
26
+ let r = e, i = n;
27
+ return (e, n) => (openBlock(), createElementBlock("div", { class: normalizeClass(e.$style.container) }, [createElementVNode("button", {
28
+ onClick: n[0] ||= (e) => i("update:modelValue", !r.modelValue),
29
+ class: normalizeClass(e.$style.titleBlock),
30
+ type: "button"
31
+ }, [createElementVNode("div", { class: normalizeClass(e.$style.title) }, [createVNode(unref(arrow_default), {
32
+ "data-expanded": r.modelValue,
33
+ class: normalizeClass(e.$style.icon),
34
+ width: "16",
35
+ height: "16"
36
+ }, null, 8, ["data-expanded", "class"]), createElementVNode("span", { class: normalizeClass(e.$style.titleText) }, toDisplayString(r.title), 3)], 2)], 2), createElementVNode("div", {
37
+ class: normalizeClass(e.$style.spoilerWrapper),
38
+ "data-expanded": r.modelValue
39
+ }, [createElementVNode("div", {
40
+ class: normalizeClass(e.$style.spoilerContent),
41
+ "data-expanded": r.modelValue
42
+ }, [createElementVNode("div", { class: normalizeClass(e.$style.spoilerInner) }, [renderSlot(e.$slots, "default")], 2)], 10, _hoisted_2)], 10, _hoisted_1)], 2));
43
+ }
44
+ }), [["__cssModules", { $style: {
45
+ container: "_container_1hyai_1",
46
+ titleBlock: "_titleBlock_1hyai_7",
47
+ title: "_title_1hyai_7",
48
+ titleText: "_titleText_1hyai_36",
49
+ icon: "_icon_1hyai_46",
50
+ spoilerWrapper: "_spoilerWrapper_1hyai_57",
51
+ spoilerContent: "_spoilerContent_1hyai_66",
52
+ spoilerInner: "_spoilerInner_1hyai_73"
53
+ } }]]);
54
+ export { UiSpoiler_default as default };
@@ -1 +1 @@
1
- ._tableBlock_nw50b_1{width:100%;overflow-x:auto}._scrollMessage_nw50b_6{margin-bottom:8px}._table_nw50b_1{width:100%;border:1px solid var(--color-gray);border-radius:8px}._table_nw50b_1 td{padding:6px 16px;vertical-align:top;border-top:1px solid var(--color-gray)}._table_nw50b_1 td[data-grow]{width:100%}._table_nw50b_1 td[data-no-wrap]{text-wrap:nowrap}._th_nw50b_27{padding:8px 16px;text-align:left;background-color:var(--color-gray-light-extra)}._th_nw50b_27:first-child{border-top-left-radius:8px}._th_nw50b_27:last-child{border-top-right-radius:8px}._label_nw50b_39{display:flex;gap:4px;align-items:center;width:fit-content;font-size:1rem;font-weight:700;color:var(--color-black);text-wrap:nowrap;cursor:pointer;user-select:none}._label_nw50b_39[data-loading=true]{color:var(--color-transparent)}._sort_nw50b_55{display:flex;padding:0;cursor:pointer;background-color:var(--color-transparent);border:none}._arrow_nw50b_63{color:var(--color-black)}._arrow_nw50b_63[data-loading=true]{color:var(--color-transparent)}._arrow_nw50b_63[data-current=true]:not(._arrow_nw50b_63[data-loading=true]){color:var(--color-primary)}.dark ._table_nw50b_1{border:1px solid var(--color-gray-dark-extra)}.dark ._table_nw50b_1 td{border-top:1px solid var(--color-gray-dark-extra)}.dark ._th_nw50b_27{background-color:var(--color-primary-dark)}.dark ._label_nw50b_39{color:var(--color-white)}
1
+ ._tableBlock_nw50b_1{width:100%;overflow-x:auto}._scrollMessage_nw50b_6{margin-bottom:8px}._table_nw50b_1{border:1px solid var(--color-gray);border-radius:8px;width:100%}._table_nw50b_1 td{vertical-align:top;border-top:1px solid var(--color-gray);padding:6px 16px}._table_nw50b_1 td[data-grow]{width:100%}._table_nw50b_1 td[data-no-wrap]{text-wrap:nowrap}._th_nw50b_27{text-align:left;background-color:var(--color-gray-light-extra);padding:8px 16px}._th_nw50b_27:first-child{border-top-left-radius:8px}._th_nw50b_27:last-child{border-top-right-radius:8px}._label_nw50b_39{width:-moz-fit-content;width:fit-content;color:var(--color-black);text-wrap:nowrap;cursor:pointer;-webkit-user-select:none;user-select:none;align-items:center;gap:4px;font-size:1rem;font-weight:700;display:flex}._label_nw50b_39[data-loading=true]{color:var(--color-transparent)}._sort_nw50b_55{cursor:pointer;background-color:var(--color-transparent);border:none;padding:0;display:flex}._arrow_nw50b_63{color:var(--color-black)}._arrow_nw50b_63[data-loading=true]{color:var(--color-transparent)}._arrow_nw50b_63[data-current=true]:not(._arrow_nw50b_63[data-loading=true]){color:var(--color-primary)}.dark ._table_nw50b_1{border:1px solid var(--color-gray-dark-extra)}.dark ._table_nw50b_1 td{border-top:1px solid var(--color-gray-dark-extra)}.dark ._th_nw50b_27{background-color:var(--color-primary-dark)}.dark ._label_nw50b_39{color:var(--color-white)}