vue-amazing-ui 2.2.11 → 2.2.13

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 (193) hide show
  1. package/dist/index.iife.js +144 -69
  2. package/dist/index.js +4925 -4804
  3. package/dist/index.umd.cjs +139 -64
  4. package/dist/style.css +1 -1
  5. package/es/backtop/BackTop.css +1 -1
  6. package/es/backtop/BackTop.vue.js +1 -1
  7. package/es/backtop/BackTop.vue2.js +7 -7
  8. package/es/button/Button.css +1 -1
  9. package/es/button/Button.vue.js +2 -2
  10. package/es/button/Button.vue2.js +34 -34
  11. package/es/calendar/Calendar.css +1 -1
  12. package/es/calendar/Calendar.d.ts +6 -0
  13. package/es/calendar/Calendar.vue.js +2 -2
  14. package/es/calendar/Calendar.vue2.js +130 -126
  15. package/es/calendar/index.d.ts +9 -0
  16. package/es/collapse/Collapse.css +1 -1
  17. package/es/collapse/Collapse.vue.js +2 -2
  18. package/es/colorpicker/ColorPicker.css +1 -1
  19. package/es/colorpicker/ColorPicker.d.ts +4 -0
  20. package/es/colorpicker/ColorPicker.vue.js +2 -2
  21. package/es/colorpicker/ColorPicker.vue2.js +244 -234
  22. package/es/colorpicker/index.d.ts +6 -0
  23. package/es/floatbutton/FloatButton.css +1 -1
  24. package/es/floatbutton/FloatButton.vue.js +2 -2
  25. package/es/floatbutton/FloatButton.vue2.js +5 -3
  26. package/es/image/Image.css +1 -1
  27. package/es/image/Image.vue.js +1 -1
  28. package/es/image/Image.vue2.js +25 -21
  29. package/es/input/Input.css +1 -1
  30. package/es/input/Input.vue.js +2 -2
  31. package/es/input/Input.vue2.js +35 -29
  32. package/es/inputnumber/InputNumber.css +1 -1
  33. package/es/inputnumber/InputNumber.vue.js +2 -2
  34. package/es/inputnumber/InputNumber.vue2.js +41 -35
  35. package/es/inputsearch/InputSearch.css +1 -1
  36. package/es/inputsearch/InputSearch.vue.js +1 -1
  37. package/es/inputsearch/InputSearch.vue2.js +31 -25
  38. package/es/message/Message.css +1 -1
  39. package/es/message/Message.vue.js +2 -2
  40. package/es/message/Message.vue2.js +38 -32
  41. package/es/modal/Modal.css +1 -1
  42. package/es/modal/Modal.vue.js +1 -1
  43. package/es/modal/Modal.vue2.js +39 -29
  44. package/es/notification/Notification.css +1 -1
  45. package/es/notification/Notification.vue.js +1 -1
  46. package/es/notification/Notification.vue2.js +36 -27
  47. package/es/pagination/Pagination.css +1 -1
  48. package/es/pagination/Pagination.d.ts +5 -0
  49. package/es/pagination/Pagination.vue.js +1 -1
  50. package/es/pagination/Pagination.vue2.js +123 -103
  51. package/es/pagination/index.d.ts +7 -0
  52. package/es/popconfirm/Popconfirm.css +1 -1
  53. package/es/popconfirm/Popconfirm.vue.js +1 -1
  54. package/es/popconfirm/Popconfirm.vue2.js +20 -14
  55. package/es/progress/Progress.css +1 -1
  56. package/es/progress/Progress.vue.js +2 -2
  57. package/es/progress/Progress.vue2.js +13 -12
  58. package/es/qrcode/QRCode.css +1 -1
  59. package/es/qrcode/QRCode.vue.js +2 -2
  60. package/es/rate/Rate.css +1 -1
  61. package/es/rate/Rate.vue.js +2 -2
  62. package/es/rate/Rate.vue2.js +1 -1
  63. package/es/scrollbar/Scrollbar.css +1 -1
  64. package/es/scrollbar/Scrollbar.d.ts +1 -7
  65. package/es/scrollbar/Scrollbar.vue.js +2 -2
  66. package/es/scrollbar/index.d.ts +3 -21
  67. package/es/select/Select.css +1 -1
  68. package/es/select/Select.d.ts +2 -14
  69. package/es/select/Select.vue.js +2 -2
  70. package/es/select/Select.vue2.js +91 -82
  71. package/es/select/index.d.ts +2 -14
  72. package/es/slider/Slider.css +1 -1
  73. package/es/slider/Slider.vue.js +2 -2
  74. package/es/slider/Slider.vue2.js +18 -18
  75. package/es/spin/Spin.css +1 -1
  76. package/es/spin/Spin.vue.js +2 -2
  77. package/es/spin/Spin.vue2.js +32 -32
  78. package/es/steps/Steps.css +1 -1
  79. package/es/steps/Steps.vue.js +2 -2
  80. package/es/steps/Steps.vue2.js +22 -16
  81. package/es/style/global.css +1 -1
  82. package/es/switch/Switch.css +1 -1
  83. package/es/switch/Switch.vue.js +2 -2
  84. package/es/switch/Switch.vue2.js +19 -15
  85. package/es/table/Table.d.ts +4 -28
  86. package/es/table/index.d.ts +2 -14
  87. package/es/tabs/Tabs.css +1 -1
  88. package/es/tabs/Tabs.vue.js +2 -2
  89. package/es/tabs/Tabs.vue2.js +14 -13
  90. package/es/textarea/Textarea.css +1 -1
  91. package/es/textarea/Textarea.vue.js +4 -4
  92. package/es/textarea/Textarea.vue2.js +41 -35
  93. package/es/textscroll/TextScroll.css +1 -1
  94. package/es/textscroll/TextScroll.vue.js +1 -1
  95. package/es/textscroll/TextScroll.vue2.js +71 -71
  96. package/es/upload/Upload.css +1 -1
  97. package/es/upload/Upload.vue.js +1 -1
  98. package/es/upload/Upload.vue2.js +35 -30
  99. package/lib/backtop/BackTop.css +1 -1
  100. package/lib/backtop/BackTop.vue.cjs +1 -1
  101. package/lib/backtop/BackTop.vue2.cjs +1 -1
  102. package/lib/button/Button.css +1 -1
  103. package/lib/button/Button.vue.cjs +1 -1
  104. package/lib/button/Button.vue2.cjs +11 -11
  105. package/lib/calendar/Calendar.css +1 -1
  106. package/lib/calendar/Calendar.d.ts +6 -0
  107. package/lib/calendar/Calendar.vue.cjs +1 -1
  108. package/lib/calendar/Calendar.vue2.cjs +5 -1
  109. package/lib/calendar/index.d.ts +9 -0
  110. package/lib/collapse/Collapse.css +1 -1
  111. package/lib/collapse/Collapse.vue.cjs +1 -1
  112. package/lib/colorpicker/ColorPicker.css +1 -1
  113. package/lib/colorpicker/ColorPicker.d.ts +4 -0
  114. package/lib/colorpicker/ColorPicker.vue.cjs +1 -1
  115. package/lib/colorpicker/ColorPicker.vue2.cjs +10 -3
  116. package/lib/colorpicker/index.d.ts +6 -0
  117. package/lib/floatbutton/FloatButton.css +1 -1
  118. package/lib/floatbutton/FloatButton.vue.cjs +1 -1
  119. package/lib/floatbutton/FloatButton.vue2.cjs +4 -2
  120. package/lib/image/Image.css +1 -1
  121. package/lib/image/Image.vue.cjs +1 -1
  122. package/lib/image/Image.vue2.cjs +1 -1
  123. package/lib/input/Input.css +1 -1
  124. package/lib/input/Input.vue.cjs +1 -1
  125. package/lib/input/Input.vue2.cjs +6 -1
  126. package/lib/inputnumber/InputNumber.css +1 -1
  127. package/lib/inputnumber/InputNumber.vue.cjs +1 -1
  128. package/lib/inputnumber/InputNumber.vue2.cjs +7 -1
  129. package/lib/inputsearch/InputSearch.css +1 -1
  130. package/lib/inputsearch/InputSearch.vue.cjs +1 -1
  131. package/lib/inputsearch/InputSearch.vue2.cjs +6 -1
  132. package/lib/message/Message.css +1 -1
  133. package/lib/message/Message.vue.cjs +1 -1
  134. package/lib/message/Message.vue2.cjs +7 -1
  135. package/lib/modal/Modal.css +1 -1
  136. package/lib/modal/Modal.vue.cjs +1 -1
  137. package/lib/modal/Modal.vue2.cjs +8 -1
  138. package/lib/notification/Notification.css +1 -1
  139. package/lib/notification/Notification.vue.cjs +1 -1
  140. package/lib/notification/Notification.vue2.cjs +6 -1
  141. package/lib/pagination/Pagination.css +1 -1
  142. package/lib/pagination/Pagination.d.ts +5 -0
  143. package/lib/pagination/Pagination.vue.cjs +1 -1
  144. package/lib/pagination/Pagination.vue2.cjs +1 -1
  145. package/lib/pagination/index.d.ts +7 -0
  146. package/lib/popconfirm/Popconfirm.css +1 -1
  147. package/lib/popconfirm/Popconfirm.vue.cjs +1 -1
  148. package/lib/popconfirm/Popconfirm.vue2.cjs +6 -1
  149. package/lib/progress/Progress.css +1 -1
  150. package/lib/progress/Progress.vue.cjs +1 -1
  151. package/lib/progress/Progress.vue2.cjs +5 -4
  152. package/lib/qrcode/QRCode.css +1 -1
  153. package/lib/qrcode/QRCode.vue.cjs +1 -1
  154. package/lib/rate/Rate.css +1 -1
  155. package/lib/rate/Rate.vue.cjs +1 -1
  156. package/lib/rate/Rate.vue2.cjs +1 -1
  157. package/lib/scrollbar/Scrollbar.css +1 -1
  158. package/lib/scrollbar/Scrollbar.d.ts +1 -7
  159. package/lib/scrollbar/Scrollbar.vue.cjs +1 -1
  160. package/lib/scrollbar/index.d.ts +3 -21
  161. package/lib/select/Select.css +1 -1
  162. package/lib/select/Select.d.ts +2 -14
  163. package/lib/select/Select.vue.cjs +1 -1
  164. package/lib/select/Select.vue2.cjs +8 -1
  165. package/lib/select/index.d.ts +2 -14
  166. package/lib/slider/Slider.css +1 -1
  167. package/lib/slider/Slider.vue.cjs +1 -1
  168. package/lib/slider/Slider.vue2.cjs +20 -20
  169. package/lib/spin/Spin.css +1 -1
  170. package/lib/spin/Spin.vue.cjs +1 -1
  171. package/lib/spin/Spin.vue2.cjs +2 -2
  172. package/lib/steps/Steps.css +1 -1
  173. package/lib/steps/Steps.vue.cjs +1 -1
  174. package/lib/steps/Steps.vue2.cjs +7 -1
  175. package/lib/style/global.css +1 -1
  176. package/lib/switch/Switch.css +1 -1
  177. package/lib/switch/Switch.vue.cjs +1 -1
  178. package/lib/switch/Switch.vue2.cjs +5 -1
  179. package/lib/table/Table.d.ts +4 -28
  180. package/lib/table/index.d.ts +2 -14
  181. package/lib/tabs/Tabs.css +1 -1
  182. package/lib/tabs/Tabs.vue.cjs +1 -1
  183. package/lib/tabs/Tabs.vue2.cjs +1 -1
  184. package/lib/textarea/Textarea.css +1 -1
  185. package/lib/textarea/Textarea.vue.cjs +1 -1
  186. package/lib/textarea/Textarea.vue2.cjs +6 -1
  187. package/lib/textscroll/TextScroll.css +1 -1
  188. package/lib/textscroll/TextScroll.vue.cjs +1 -1
  189. package/lib/textscroll/TextScroll.vue2.cjs +18 -18
  190. package/lib/upload/Upload.css +1 -1
  191. package/lib/upload/Upload.vue.cjs +1 -1
  192. package/lib/upload/Upload.vue2.cjs +1 -1
  193. package/package.json +3 -2
@@ -1,26 +1,28 @@
1
- import { defineComponent as $l, ref as A, computed as v, watch as xe, watchEffect as Sl, createBlock as K, openBlock as b, unref as T, mergeProps as Al, withCtx as se, createElementVNode as s, normalizeStyle as h, normalizeClass as Ve, createElementBlock as R, createCommentVNode as H, renderSlot as Ie, createTextVNode as ne, toDisplayString as me, Fragment as ge, withModifiers as Ml, renderList as Le } from "vue";
2
- import { toRgbaString as z, toHexString as Q, rgba as U, rgb2hsv as be, hsla as G, hsl2hsv as Ne, hsva as P, hsl2rgb as ke, hsv2rgb as N, rgb2hsl as ye, hsv2hsl as ue, toHexaString as B, toHslaString as _, toRgbString as we, toHslString as $e, toHsvaString as X, toHsvString as Se } from "seemly";
3
- import Cl from "../tooltip/index.js";
4
- import Be from "../input/index.js";
5
- import _e from "../button/index.js";
6
- import { useSlotsExist as Rl } from "../utils/index.js";
7
- const Hl = { class: "color-picker-preview" }, El = { class: "color-picker-preview-sliders" }, zl = {
1
+ import { defineComponent as Sl, ref as A, computed as d, watch as Ie, watchEffect as Al, createBlock as J, openBlock as b, unref as T, normalizeStyle as p, withCtx as se, createElementVNode as n, mergeProps as me, createElementBlock as R, createCommentVNode as H, renderSlot as Le, createTextVNode as ne, toDisplayString as ge, Fragment as be, normalizeClass as Ml, withModifiers as Cl, renderList as Ne } from "vue";
2
+ import { toRgbaString as z, toHexString as K, rgba as U, rgb2hsv as ke, hsla as G, hsl2hsv as Be, hsva as F, hsl2rgb as ye, hsv2rgb as N, rgb2hsl as we, hsv2hsl as ue, toHexaString as B, toHslaString as _, toRgbString as $e, toHslString as Se, toHsvaString as X, toHsvString as Ae } from "seemly";
3
+ import Rl from "../tooltip/index.js";
4
+ import _e from "../input/index.js";
5
+ import Pe from "../button/index.js";
6
+ import { useSlotsExist as Hl } from "../utils/index.js";
7
+ const El = { class: "color-picker-preview" }, zl = { class: "color-picker-preview-sliders" }, Ul = {
8
8
  key: 0,
9
9
  class: "color-picker-preview-circle"
10
- }, Ul = ["value"], xl = { class: "color-picker-input" }, Vl = { class: "color-picker-input-group" }, Il = {
10
+ }, xl = ["value"], Vl = { class: "color-picker-input" }, Il = { class: "color-picker-input-group" }, Ll = {
11
11
  key: 0,
12
12
  class: "color-picker-swatches"
13
- }, Ll = ["onClick"], Nl = {
13
+ }, Nl = ["onClick"], Bl = {
14
14
  key: 0,
15
15
  class: "color-picker-actions"
16
- }, Bl = {
16
+ }, _l = {
17
17
  key: 1,
18
18
  class: "color-picker-footer"
19
- }, _l = { class: "color-picker-wrap" }, Dl = { class: "color-picker-fill" }, k = "12px", De = 12, f = "6px", Fl = 6, Yl = /* @__PURE__ */ $l({
19
+ }, Pl = { class: "color-picker-wrap" }, Dl = { class: "color-picker-fill" }, k = "12px", De = 12, f = "6px", Fl = 6, Yl = /* @__PURE__ */ Sl({
20
20
  __name: "ColorPicker",
21
21
  props: {
22
+ width: { default: "100%" },
22
23
  label: { type: Function, default: void 0 },
23
24
  tooltipStyle: { default: () => ({}) },
25
+ inputProps: { default: () => ({}) },
24
26
  showAlpha: { type: Boolean, default: !0 },
25
27
  showPreview: { type: Boolean, default: !1 },
26
28
  size: { default: "middle" },
@@ -32,233 +34,233 @@ const Hl = { class: "color-picker-preview" }, El = { class: "color-picker-previe
32
34
  footer: { default: void 0 }
33
35
  },
34
36
  emits: ["update:value", "complete", "confirm", "clear"],
35
- setup(Fe, { emit: Pe }) {
36
- const u = Fe, ie = A(), W = A(null), ee = A(null), le = A(null), E = A(0), ce = A(1), te = A([0, 0]), Y = A(), i = A(u.value), m = A(oe(i.value) || u.modes[0] || "rgb"), re = A(), x = A([]), D = Pe, Xe = Rl("footer"), Oe = v(() => Xe.value || u.footer), Ze = v(() => ({
37
+ setup(Fe, { emit: Xe }) {
38
+ const s = Fe, ie = A(), Q = A(null), ee = A(null), le = A(null), E = A(0), ce = A(1), te = A([0, 0]), W = A(), i = A(s.value), m = A(oe(i.value) || s.modes[0] || "rgb"), re = A(), x = A([]), P = Xe, Oe = Hl("footer"), Ze = d(() => Oe.value || s.footer), Te = d(() => ({
37
39
  width: k,
38
40
  height: k,
39
41
  borderRadius: f,
40
42
  left: `calc(${te.value[0]}% - ${f})`,
41
43
  bottom: `calc(${te.value[1]}% - ${f})`
42
- })), Te = v(() => p.value ? `rgb(${p.value[0]}, ${p.value[1]}, ${p.value[2]})` : ""), Ge = v(() => ({
43
- backgroundColor: Te.value,
44
+ })), Ge = d(() => h.value ? `rgb(${h.value[0]}, ${h.value[1]}, ${h.value[2]})` : ""), We = d(() => ({
45
+ backgroundColor: Ge.value,
44
46
  borderRadius: f,
45
47
  width: k,
46
48
  height: k
47
- })), Ae = v(() => ({
49
+ })), Me = d(() => ({
48
50
  height: k,
49
51
  borderRadius: f
50
- })), Ye = v(() => ({
52
+ })), Ye = d(() => ({
51
53
  position: "relative",
52
54
  boxShadow: "inset 0 0 2px 0 rgba(0, 0, 0, 0.24)",
53
55
  backgroundImage: "linear-gradient(90deg, red, #ff0 16.66%, #0f0 33.33%, #0ff 50%, #00f 66.66%, #f0f 83.33%, red)",
54
56
  height: k,
55
57
  borderRadius: f
56
- })), je = v(() => ({
58
+ })), je = d(() => ({
57
59
  left: `calc((${E.value}%) / 359 * 100 - ${f})`,
58
60
  borderRadius: f,
59
61
  width: k,
60
62
  height: k
61
- })), qe = v(() => ({
63
+ })), qe = d(() => ({
62
64
  backgroundColor: `hsl(${E.value}, 100%, 50%)`,
63
65
  borderRadius: f,
64
66
  width: k,
65
67
  height: k
66
- })), Je = v(() => p.value ? `linear-gradient(to right, rgba(${p.value[0]}, ${p.value[1]}, ${p.value[2]}, 0) 0%, rgba(${p.value[0]}, ${p.value[1]}, ${p.value[2]}, 1) 100%)` : ""), Ke = v(() => ({
68
+ })), Je = d(() => h.value ? `linear-gradient(to right, rgba(${h.value[0]}, ${h.value[1]}, ${h.value[2]}, 0) 0%, rgba(${h.value[0]}, ${h.value[1]}, ${h.value[2]}, 1) 100%)` : ""), Ke = d(() => ({
67
69
  left: `calc(${ce.value * 100}% - ${f})`,
68
70
  borderRadius: f,
69
71
  width: k,
70
72
  height: k
71
- })), Qe = v(() => ({
72
- backgroundColor: p.value ? z(p.value) : void 0,
73
+ })), Qe = d(() => ({
74
+ backgroundColor: h.value ? z(h.value) : void 0,
73
75
  borderRadius: f,
74
76
  width: k,
75
77
  height: k
76
- })), Me = v(() => p.value && Q(p.value)), de = v(() => `${{
78
+ })), Ce = d(() => h.value && K(h.value)), Re = d(() => typeof s.width == "number" ? `${s.width}px` : s.width), de = d(() => `${{
77
79
  small: 24,
78
80
  middle: 32,
79
81
  large: 40
80
- }[u.size]}px`), We = v(() => {
82
+ }[s.size]}px`), el = d(() => {
81
83
  const e = {
82
84
  small: 6,
83
85
  middle: 8,
84
86
  large: 10
85
87
  };
86
- return `calc((${de.value} - ${e[u.size]}px) / 3)`;
87
- }), ve = v(() => oe(i.value)), j = v(() => m.value.toUpperCase() + (u.showAlpha ? "A" : "")), el = v(() => j.value.split(""));
88
+ return `calc((${de.value} - ${e[s.size]}px) / 3)`;
89
+ }), ve = d(() => oe(i.value)), Y = d(() => m.value.toUpperCase() + (s.showAlpha ? "A" : "")), ll = d(() => Y.value.split(""));
88
90
  let y, w, O, Z, V, I, L, $;
89
- const M = v(() => {
91
+ const M = d(() => {
90
92
  if (!i.value) return null;
91
93
  switch (ve.value) {
92
94
  case "hsv":
93
- return P(i.value);
95
+ return F(i.value);
94
96
  case "hsl":
95
- return [y, w, O, $] = G(i.value), [...Ne(y, w, O), $];
97
+ return [y, w, O, $] = G(i.value), [...Be(y, w, O), $];
96
98
  case "rgb":
97
99
  case "hex":
98
- return [V, I, L, $] = U(i.value), [...be(V, I, L), $];
100
+ return [V, I, L, $] = U(i.value), [...ke(V, I, L), $];
99
101
  }
100
- }), p = v(() => {
102
+ }), h = d(() => {
101
103
  if (!i.value) return null;
102
104
  switch (ve.value) {
103
105
  case "rgb":
104
106
  case "hex":
105
107
  return U(i.value);
106
108
  case "hsv":
107
- return [y, w, Z, $] = P(i.value), [...N(y, w, Z), $];
109
+ return [y, w, Z, $] = F(i.value), [...N(y, w, Z), $];
108
110
  case "hsl":
109
- return [y, w, O, $] = G(i.value), [...ke(y, w, O), $];
111
+ return [y, w, O, $] = G(i.value), [...ye(y, w, O), $];
110
112
  }
111
- }), F = v(() => {
113
+ }), D = d(() => {
112
114
  if (!i.value) return null;
113
115
  switch (ve.value) {
114
116
  case "hsl":
115
117
  return G(i.value);
116
118
  case "hsv":
117
- return [y, w, Z, $] = P(i.value), [...ue(y, w, Z), $];
119
+ return [y, w, Z, $] = F(i.value), [...ue(y, w, Z), $];
118
120
  case "rgb":
119
121
  case "hex":
120
- return [V, I, L, $] = U(i.value), [...ye(V, I, L), $];
122
+ return [V, I, L, $] = U(i.value), [...we(V, I, L), $];
121
123
  }
122
- }), C = v(() => {
124
+ }), C = d(() => {
123
125
  switch (m.value) {
124
126
  case "rgb":
125
127
  case "hex":
126
- return p.value;
128
+ return h.value;
127
129
  case "hsv":
128
130
  return M.value;
129
131
  case "hsl":
130
- return F.value;
132
+ return D.value;
131
133
  }
132
- }), Ce = v(
133
- () => u.swatches.map((e) => {
134
+ }), He = d(
135
+ () => s.swatches.map((e) => {
134
136
  const l = oe(e);
135
137
  return {
136
138
  value: e,
137
139
  mode: l,
138
- legalValue: ml(e, l)
140
+ legalValue: gl(e, l)
139
141
  };
140
142
  })
141
143
  );
142
- xe(
143
- () => u.value,
144
+ Ie(
145
+ () => s.value,
144
146
  (e) => {
145
147
  i.value = e;
146
148
  }
147
- ), xe(
149
+ ), Ie(
148
150
  () => [m.value, C.value],
149
151
  () => {
150
- m.value === "hex" ? re.value = C.value === null ? void 0 : (u.showAlpha ? B : Q)(C.value) : C.value === null ? x.value = new Array(u.showAlpha ? 4 : 3).fill(void 0) : x.value = C.value.map((e, l) => u.showAlpha && l === 3 ? `${Math.floor(e * 100)}%` : `${Math.floor(e)}`);
152
+ m.value === "hex" ? re.value = C.value === null ? void 0 : (s.showAlpha ? B : K)(C.value) : C.value === null ? x.value = new Array(s.showAlpha ? 4 : 3).fill(void 0) : x.value = C.value.map((e, l) => s.showAlpha && l === 3 ? `${Math.floor(e * 100)}%` : `${Math.floor(e)}`);
151
153
  },
152
154
  {
153
155
  immediate: !0,
154
156
  deep: !0
155
157
  }
156
- ), Sl(() => {
157
- (Y.value === void 0 || Y.value !== i.value) && M.value && (E.value = M.value[0], ce.value = M.value[3], te.value = [M.value[1], M.value[2]]), Y.value = void 0;
158
+ ), Al(() => {
159
+ (W.value === void 0 || W.value !== i.value) && M.value && (E.value = M.value[0], ce.value = M.value[3], te.value = [M.value[1], M.value[2]]), W.value = void 0;
158
160
  });
159
161
  function g(e, l) {
160
- l === "cursor" ? Y.value = e : Y.value = void 0, i.value = e, D("update:value", e), l === "input" && D("complete", e);
162
+ l === "cursor" ? W.value = e : W.value = void 0, i.value = e, P("update:value", e), l === "input" && P("complete", e);
161
163
  }
162
- function ll(e, l) {
164
+ function tl(e, l) {
163
165
  const t = M.value ? M.value[3] : 1;
164
166
  switch (te.value = [e, l], m.value) {
165
167
  case "hsv":
166
- g((u.showAlpha ? X : Se)([E.value, e, l, t]), "cursor");
168
+ g((s.showAlpha ? X : Ae)([E.value, e, l, t]), "cursor");
167
169
  break;
168
170
  case "hsl":
169
171
  g(
170
- (u.showAlpha ? _ : $e)([...ue(E.value, e, l), t]),
172
+ (s.showAlpha ? _ : Se)([...ue(E.value, e, l), t]),
171
173
  "cursor"
172
174
  );
173
175
  break;
174
176
  case "rgb":
175
177
  g(
176
- (u.showAlpha ? z : we)([...N(E.value, e, l), t]),
178
+ (s.showAlpha ? z : $e)([...N(E.value, e, l), t]),
177
179
  "cursor"
178
180
  );
179
181
  break;
180
182
  case "hex":
181
183
  g(
182
- (u.showAlpha ? B : Q)([...N(E.value, e, l), t]),
184
+ (s.showAlpha ? B : K)([...N(E.value, e, l), t]),
183
185
  "cursor"
184
186
  );
185
187
  break;
186
188
  }
187
189
  }
188
- function tl(e) {
189
- W.value && (document.addEventListener("mousemove", he), document.addEventListener("mouseup", Re), he(e));
190
+ function rl(e) {
191
+ Q.value && (document.addEventListener("mousemove", he), document.addEventListener("mouseup", Ee), he(e));
190
192
  }
191
193
  function he(e) {
192
- if (!W.value) return;
193
- const { width: l, height: t, left: o, bottom: S } = W.value.getBoundingClientRect(), r = (S - e.clientY) / t, a = (e.clientX - o) / l, n = 100 * (a > 1 ? 1 : a < 0 ? 0 : a), c = 100 * (r > 1 ? 1 : r < 0 ? 0 : r);
194
- ll(n, c);
194
+ if (!Q.value) return;
195
+ const { width: l, height: t, left: o, bottom: S } = Q.value.getBoundingClientRect(), r = (S - e.clientY) / t, a = (e.clientX - o) / l, u = 100 * (a > 1 ? 1 : a < 0 ? 0 : a), c = 100 * (r > 1 ? 1 : r < 0 ? 0 : r);
196
+ tl(u, c);
195
197
  }
196
- function Re() {
197
- document.removeEventListener("mousemove", he), document.removeEventListener("mouseup", Re), D("complete", i.value);
198
+ function Ee() {
199
+ document.removeEventListener("mousemove", he), document.removeEventListener("mouseup", Ee), P("complete", i.value);
198
200
  }
199
- function rl(e) {
201
+ function ol(e) {
200
202
  if (E.value = e, !M.value)
201
203
  return;
202
204
  const [, l, t, o] = M.value;
203
205
  switch (m.value) {
204
206
  case "hsv":
205
- g((u.showAlpha ? X : Se)([e, l, t, o]), "cursor");
207
+ g((s.showAlpha ? X : Ae)([e, l, t, o]), "cursor");
206
208
  break;
207
209
  case "rgb":
208
- g((u.showAlpha ? z : we)([...N(e, l, t), o]), "cursor");
210
+ g((s.showAlpha ? z : $e)([...N(e, l, t), o]), "cursor");
209
211
  break;
210
212
  case "hex":
211
- g((u.showAlpha ? B : Q)([...N(e, l, t), o]), "cursor");
213
+ g((s.showAlpha ? B : K)([...N(e, l, t), o]), "cursor");
212
214
  break;
213
215
  case "hsl":
214
- g((u.showAlpha ? _ : $e)([...ue(e, l, t), o]), "cursor");
216
+ g((s.showAlpha ? _ : Se)([...ue(e, l, t), o]), "cursor");
215
217
  break;
216
218
  }
217
219
  }
218
- function ol(e) {
219
- ee.value && (document.addEventListener("mousemove", pe), document.addEventListener("mouseup", He), pe(e));
220
- }
221
220
  function al(e) {
221
+ ee.value && (document.addEventListener("mousemove", pe), document.addEventListener("mouseup", ze), pe(e));
222
+ }
223
+ function sl(e) {
222
224
  return e = Math.round(e), e >= 360 ? 359 : e < 0 ? 0 : e;
223
225
  }
224
226
  function pe(e) {
225
227
  if (!ee.value) return;
226
- const { width: l, left: t } = ee.value.getBoundingClientRect(), o = al((e.clientX - t - Fl) / (l - De) * 360);
227
- rl(o);
228
+ const { width: l, left: t } = ee.value.getBoundingClientRect(), o = sl((e.clientX - t - Fl) / (l - De) * 360);
229
+ ol(o);
228
230
  }
229
- function He() {
230
- document.removeEventListener("mousemove", pe), document.removeEventListener("mouseup", He), D("complete", i.value);
231
+ function ze() {
232
+ document.removeEventListener("mousemove", pe), document.removeEventListener("mouseup", ze), P("complete", i.value);
231
233
  }
232
- function sl(e) {
234
+ function nl(e) {
233
235
  switch (m.value) {
234
236
  case "hsv":
235
237
  [y, w, Z] = M.value, g(X([y, w, Z, e]), "cursor");
236
238
  break;
237
239
  case "rgb":
238
- [V, I, L] = p.value, g(z([V, I, L, e]), "cursor");
240
+ [V, I, L] = h.value, g(z([V, I, L, e]), "cursor");
239
241
  break;
240
242
  case "hex":
241
- [V, I, L] = p.value, g(B([V, I, L, e]), "cursor");
243
+ [V, I, L] = h.value, g(B([V, I, L, e]), "cursor");
242
244
  break;
243
245
  case "hsl":
244
- [y, w, O] = F.value, g(_([y, w, O, e]), "cursor");
246
+ [y, w, O] = D.value, g(_([y, w, O, e]), "cursor");
245
247
  break;
246
248
  }
247
249
  ce.value = e;
248
250
  }
249
- function nl(e) {
250
- !le.value || !p.value || (document.addEventListener("mousemove", fe), document.addEventListener("mouseup", Ee), fe(e));
251
- }
252
251
  function ul(e) {
252
+ !le.value || !h.value || (document.addEventListener("mousemove", fe), document.addEventListener("mouseup", Ue), fe(e));
253
+ }
254
+ function il(e) {
253
255
  return e = Math.round(e * 100) / 100, e > 1 ? 1 : e < 0 ? 0 : e;
254
256
  }
255
257
  function fe(e) {
256
258
  if (!le.value) return;
257
- const { width: l, left: t } = le.value.getBoundingClientRect(), o = ul((e.clientX - t) / (l - De));
258
- sl(o);
259
+ const { width: l, left: t } = le.value.getBoundingClientRect(), o = il((e.clientX - t) / (l - De));
260
+ nl(o);
259
261
  }
260
- function Ee() {
261
- document.removeEventListener("mousemove", fe), document.removeEventListener("mouseup", Ee), D("complete", i.value);
262
+ function Ue() {
263
+ document.removeEventListener("mousemove", fe), document.removeEventListener("mouseup", Ue), P("complete", i.value);
262
264
  }
263
265
  function oe(e) {
264
266
  if (e !== void 0) {
@@ -268,108 +270,108 @@ const Hl = { class: "color-picker-preview" }, El = { class: "color-picker-previe
268
270
  if (e.includes("hsv")) return "hsv";
269
271
  }
270
272
  }
271
- function il() {
272
- const e = u.modes.findIndex((l) => l === m.value);
273
- e !== -1 ? m.value = u.modes[(e + 1) % u.modes.length] : m.value = "rgb";
273
+ function cl() {
274
+ const e = s.modes.findIndex((l) => l === m.value);
275
+ e !== -1 ? m.value = s.modes[(e + 1) % s.modes.length] : m.value = "rgb";
274
276
  }
275
- function cl(e) {
276
- const l = e.target, t = Ue(l.value.toUpperCase(), m.value, "hex");
277
+ function dl(e) {
278
+ const l = e.target, t = Ve(l.value.toUpperCase(), m.value, "hex");
277
279
  g(t, "input");
278
280
  }
279
- function dl(e) {
281
+ function vl(e) {
280
282
  const l = e.trim();
281
283
  return /^#[0-9a-fA-F]+$/.test(l) ? [4, 5, 7, 9].includes(l.length) : !1;
282
284
  }
283
- function vl(e) {
285
+ function hl(e) {
284
286
  return /^\d{1,3}\.?\d*$/.test(e.trim()) ? Math.max(0, Math.min(Number.parseInt(e), 360)) : !1;
285
287
  }
286
- function hl(e) {
288
+ function pl(e) {
287
289
  return /^\d{1,3}\.?\d*$/.test(e.trim()) ? Math.max(0, Math.min(Number.parseInt(e), 100)) : !1;
288
290
  }
289
- function pl(e) {
291
+ function fl(e) {
290
292
  return /^\d{1,3}\.?\d*%$/.test(e.trim()) ? Math.max(0, Math.min(Number.parseInt(e) / 100, 100)) : !1;
291
293
  }
292
- function fl(e) {
294
+ function ml(e) {
293
295
  return /^\d{1,3}\.?\d*$/.test(e.trim()) ? Math.max(0, Math.min(Number.parseInt(e), 255)) : !1;
294
296
  }
295
- function q(e, l) {
297
+ function j(e, l) {
296
298
  return e === void 0 ? "" : l === "HEX" || l === "HEXA" ? e : l === "A" ? `${Math.floor(Number(e) * 100)}%` : String(Math.floor(Number(e)));
297
299
  }
298
300
  function ae(e) {
299
301
  g(e, "input");
300
302
  }
301
- function J(e, l) {
303
+ function q(e, l) {
302
304
  if (m.value === "hex") {
303
- ae((u.showAlpha ? B : Q)(l));
305
+ ae((s.showAlpha ? B : K)(l));
304
306
  return;
305
307
  }
306
308
  let t;
307
309
  switch (C.value === null ? t = [0, 0, 0, 0] : t = [...C.value], m.value) {
308
310
  case "hsv":
309
- t[e] = l, ae((u.showAlpha ? X : Se)(t));
311
+ t[e] = l, ae((s.showAlpha ? X : Ae)(t));
310
312
  break;
311
313
  case "rgb":
312
- t[e] = l, ae((u.showAlpha ? z : we)(t));
314
+ t[e] = l, ae((s.showAlpha ? z : $e)(t));
313
315
  break;
314
316
  case "hsl":
315
- t[e] = l, ae((u.showAlpha ? _ : $e)(t));
317
+ t[e] = l, ae((s.showAlpha ? _ : Se)(t));
316
318
  break;
317
319
  }
318
320
  }
319
- function ze(e, l) {
320
- var c, d;
321
+ function xe(e, l) {
322
+ var c, v;
321
323
  const t = e.target;
322
324
  let o, S, r;
323
325
  const a = t.value;
324
- l === void 0 ? r = C.value === null ? void 0 : C.value : r = ((c = C.value) == null ? void 0 : c[l]) === void 0 || (d = C.value) == null ? void 0 : d[l].toString();
325
- const n = l === void 0 ? j.value : j.value[l];
326
- switch (n) {
326
+ l === void 0 ? r = C.value === null ? void 0 : C.value : r = ((c = C.value) == null ? void 0 : c[l]) === void 0 || (v = C.value) == null ? void 0 : v[l].toString();
327
+ const u = l === void 0 ? Y.value : Y.value[l];
328
+ switch (u) {
327
329
  case "HEX":
328
330
  case "HEXA":
329
- S = dl(a), S && J(0, a), re.value = q(a, n);
331
+ S = vl(a), S && q(0, a), re.value = j(a, u);
330
332
  break;
331
333
  case "H":
332
- o = vl(a), o === !1 ? x.value[l] = q(r, n) : J(l, o);
334
+ o = hl(a), o === !1 ? x.value[l] = j(r, u) : q(l, o);
333
335
  break;
334
336
  case "S":
335
337
  case "L":
336
338
  case "V":
337
- o = hl(a), o === !1 ? x.value[l] = q(r, n) : J(l, o);
339
+ o = pl(a), o === !1 ? x.value[l] = j(r, u) : q(l, o);
338
340
  break;
339
341
  case "A":
340
- o = pl(a), o === !1 ? x.value[l] = q(r, n) : J(l, o);
342
+ o = fl(a), o === !1 ? x.value[l] = j(r, u) : q(l, o);
341
343
  break;
342
344
  case "R":
343
345
  case "G":
344
346
  case "B":
345
- o = fl(a), o === !1 ? x.value[l] = q(r, n) : J(l, o);
347
+ o = ml(a), o === !1 ? x.value[l] = j(r, u) : q(l, o);
346
348
  break;
347
349
  }
348
350
  }
349
- function ml(e, l) {
351
+ function gl(e, l) {
350
352
  if (l === "hsv") {
351
- const [t, o, S, r] = P(e);
353
+ const [t, o, S, r] = F(e);
352
354
  return z([...N(t, o, S), r]);
353
355
  }
354
356
  return e;
355
357
  }
356
- function gl(e) {
358
+ function bl(e) {
357
359
  const l = document.createElement("canvas").getContext("2d");
358
360
  return l ? (l.fillStyle = e, l.fillStyle) : "#000000";
359
361
  }
360
- function Ue(e, l, t) {
362
+ function Ve(e, l, t) {
361
363
  return t = t || oe(e), t ? t === l ? e : {
362
364
  rgb: {
363
365
  hex(r) {
364
366
  return B(U(r));
365
367
  },
366
368
  hsl(r) {
367
- const [a, n, c, d] = U(r);
368
- return _([...ye(a, n, c), d]);
369
+ const [a, u, c, v] = U(r);
370
+ return _([...we(a, u, c), v]);
369
371
  },
370
372
  hsv(r) {
371
- const [a, n, c, d] = U(r);
372
- return X([...be(a, n, c), d]);
373
+ const [a, u, c, v] = U(r);
374
+ return X([...ke(a, u, c), v]);
373
375
  }
374
376
  },
375
377
  hex: {
@@ -377,61 +379,61 @@ const Hl = { class: "color-picker-preview" }, El = { class: "color-picker-previe
377
379
  return z(U(r));
378
380
  },
379
381
  hsl(r) {
380
- const [a, n, c, d] = U(r);
381
- return _([...ye(a, n, c), d]);
382
+ const [a, u, c, v] = U(r);
383
+ return _([...we(a, u, c), v]);
382
384
  },
383
385
  hsv(r) {
384
- const [a, n, c, d] = U(r);
385
- return X([...be(a, n, c), d]);
386
+ const [a, u, c, v] = U(r);
387
+ return X([...ke(a, u, c), v]);
386
388
  }
387
389
  },
388
390
  hsl: {
389
391
  hex(r) {
390
- const [a, n, c, d] = G(r);
391
- return B([...ke(a, n, c), d]);
392
+ const [a, u, c, v] = G(r);
393
+ return B([...ye(a, u, c), v]);
392
394
  },
393
395
  rgb(r) {
394
- const [a, n, c, d] = G(r);
395
- return z([...ke(a, n, c), d]);
396
+ const [a, u, c, v] = G(r);
397
+ return z([...ye(a, u, c), v]);
396
398
  },
397
399
  hsv(r) {
398
- const [a, n, c, d] = G(r);
399
- return X([...Ne(a, n, c), d]);
400
+ const [a, u, c, v] = G(r);
401
+ return X([...Be(a, u, c), v]);
400
402
  }
401
403
  },
402
404
  hsv: {
403
405
  hex(r) {
404
- const [a, n, c, d] = P(r);
405
- return B([...N(a, n, c), d]);
406
+ const [a, u, c, v] = F(r);
407
+ return B([...N(a, u, c), v]);
406
408
  },
407
409
  rgb(r) {
408
- const [a, n, c, d] = P(r);
409
- return z([...N(a, n, c), d]);
410
+ const [a, u, c, v] = F(r);
411
+ return z([...N(a, u, c), v]);
410
412
  },
411
413
  hsl(r) {
412
- const [a, n, c, d] = P(r);
413
- return _([...ue(a, n, c), d]);
414
+ const [a, u, c, v] = F(r);
415
+ return _([...ue(a, u, c), v]);
414
416
  }
415
417
  }
416
418
  }[t][l](e) : void 0;
417
419
  }
418
- function bl(e) {
419
- let { value: l, mode: t } = e;
420
- return t || (t = "hex", /^[a-zA-Z]+$/.test(l) ? l = gl(l) : (console.warn("color-picker", `color ${l} in swatches is invalid.`), l = "#000000")), t === m.value ? l : Ue(l, m.value, t);
421
- }
422
420
  function kl(e) {
423
- g(bl(e), "input");
421
+ let { value: l, mode: t } = e;
422
+ return t || (t = "hex", /^[a-zA-Z]+$/.test(l) ? l = bl(l) : (console.warn("color-picker", `color ${l} in swatches is invalid.`), l = "#000000")), t === m.value ? l : Ve(l, m.value, t);
424
423
  }
425
- function yl() {
426
- D("confirm", i.value), ie.value.hide();
424
+ function yl(e) {
425
+ g(kl(e), "input");
427
426
  }
428
427
  function wl() {
429
- g(void 0, "input"), D("clear"), ie.value.hide();
428
+ P("confirm", i.value), ie.value.hide();
429
+ }
430
+ function $l() {
431
+ g(void 0, "input"), P("clear"), ie.value.hide();
430
432
  }
431
- return (e, l) => (b(), K(T(Cl), Al({
433
+ return (e, l) => (b(), J(T(Rl), {
432
434
  ref_key: "tooltipRef",
433
435
  ref: ie,
434
- style: `width: 100%; height: ${de.value};`,
436
+ style: p(`width: ${Re.value}; height: ${de.value};`),
435
437
  "max-width": "none",
436
438
  arrow: !1,
437
439
  placement: "bottom",
@@ -446,58 +448,58 @@ const Hl = { class: "color-picker-preview" }, El = { class: "color-picker-previe
446
448
  "content-style": { width: "100%", height: "100%" },
447
449
  trigger: "click",
448
450
  "transition-duration": 200
449
- }, e.$attrs), {
451
+ }, {
450
452
  tooltip: se(() => [
451
- e.disabled ? H("", !0) : (b(), R(ge, { key: 0 }, [
452
- s("div", {
453
- class: Ve(["color-picker-panel", { "panel-with-actions": e.actions.length }])
453
+ e.disabled ? H("", !0) : (b(), R(be, { key: 0 }, [
454
+ n("div", {
455
+ class: Ml(["color-picker-panel", { "panel-with-actions": e.actions.length }])
454
456
  }, [
455
- s("div", {
457
+ n("div", {
456
458
  ref_key: "palleteRef",
457
- ref: W,
459
+ ref: Q,
458
460
  class: "color-picker-pallete",
459
- onMousedown: tl
461
+ onMousedown: rl
460
462
  }, [
461
- s("div", {
463
+ n("div", {
462
464
  class: "color-picker-pallete-layer",
463
- style: h({ backgroundImage: `linear-gradient(90deg, white, hsl(${E.value}, 100%, 50%))` })
465
+ style: p({ backgroundImage: `linear-gradient(90deg, white, hsl(${E.value}, 100%, 50%))` })
464
466
  }, null, 4),
465
- l[1] || (l[1] = s("div", {
467
+ l[1] || (l[1] = n("div", {
466
468
  class: "color-picker-pallete-layer pallete-layer-shadowed",
467
469
  style: { "background-image": "linear-gradient(180deg, rgba(0, 0, 0, 0%), rgba(0, 0, 0, 100%))" }
468
470
  }, null, -1)),
469
- s("div", {
471
+ n("div", {
470
472
  class: "color-picker-handle",
471
- style: h(Ze.value)
473
+ style: p(Te.value)
472
474
  }, [
473
- s("div", {
475
+ n("div", {
474
476
  class: "color-picker-handle-fill",
475
- style: h(Ge.value)
477
+ style: p(We.value)
476
478
  }, null, 4)
477
479
  ], 4)
478
480
  ], 544),
479
- s("div", Hl, [
480
- s("div", El, [
481
- s("div", {
481
+ n("div", El, [
482
+ n("div", zl, [
483
+ n("div", {
482
484
  class: "color-picker-slider",
483
- style: h(Ae.value)
485
+ style: p(Me.value)
484
486
  }, [
485
- s("div", {
487
+ n("div", {
486
488
  ref_key: "hueRailRef",
487
489
  ref: ee,
488
- style: h(Ye.value),
489
- onMousedown: ol
490
+ style: p(Ye.value),
491
+ onMousedown: al
490
492
  }, [
491
- s("div", {
492
- style: h(`position: absolute; top: 0px; bottom: 0; left: ${f}; right: ${f}`)
493
+ n("div", {
494
+ style: p(`position: absolute; top: 0px; bottom: 0; left: ${f}; right: ${f}`)
493
495
  }, [
494
- s("div", {
496
+ n("div", {
495
497
  class: "color-picker-handle",
496
- style: h(je.value)
498
+ style: p(je.value)
497
499
  }, [
498
- s("div", {
500
+ n("div", {
499
501
  class: "color-picker-handle-fill",
500
- style: h(qe.value)
502
+ style: p(qe.value)
501
503
  }, null, 4)
502
504
  ], 4)
503
505
  ], 4)
@@ -508,11 +510,11 @@ const Hl = { class: "color-picker-preview" }, El = { class: "color-picker-previe
508
510
  ref_key: "alphaRailRef",
509
511
  ref: le,
510
512
  class: "color-picker-slider",
511
- style: h(Ae.value),
512
- onMousedown: nl
513
+ style: p(Me.value),
514
+ onMousedown: ul
513
515
  }, [
514
- s("div", {
515
- style: h(`
516
+ n("div", {
517
+ style: p(`
516
518
  border-radius: ${f};
517
519
  position: absolute;
518
520
  top: 0px;
@@ -522,98 +524,99 @@ const Hl = { class: "color-picker-preview" }, El = { class: "color-picker-previe
522
524
  overflow: hidden;
523
525
  `)
524
526
  }, [
525
- l[2] || (l[2] = s("div", { class: "color-picker-checkboard" }, null, -1)),
526
- s("div", {
527
+ l[2] || (l[2] = n("div", { class: "color-picker-checkboard" }, null, -1)),
528
+ n("div", {
527
529
  class: "color-picker-slider-image",
528
- style: h(`background-image: ${Je.value}`)
530
+ style: p(`background-image: ${Je.value}`)
529
531
  }, null, 4)
530
532
  ], 4),
531
- p.value ? (b(), R("div", {
533
+ h.value ? (b(), R("div", {
532
534
  key: 0,
533
- style: h(`position: absolute; top: 0px; bottom: 0; left: ${f}; right: ${f}`)
535
+ style: p(`position: absolute; top: 0px; bottom: 0; left: ${f}; right: ${f}`)
534
536
  }, [
535
- s("div", {
537
+ n("div", {
536
538
  class: "color-picker-handle",
537
- style: h(Ke.value)
539
+ style: p(Ke.value)
538
540
  }, [
539
- s("div", {
541
+ n("div", {
540
542
  class: "color-picker-handle-fill",
541
- style: h(Qe.value)
543
+ style: p(Qe.value)
542
544
  }, null, 4)
543
545
  ], 4)
544
546
  ], 4)) : H("", !0)
545
547
  ], 36)) : H("", !0)
546
548
  ]),
547
- e.showPreview ? (b(), R("div", zl, [
548
- s("span", {
549
+ e.showPreview ? (b(), R("div", Ul, [
550
+ n("span", {
549
551
  class: "color-picker-circle-fill",
550
- style: h(`background: ${Me.value || "#000000"};`)
552
+ style: p(`background: ${Ce.value || "#000000"};`)
551
553
  }, null, 4),
552
- s("input", {
554
+ n("input", {
553
555
  class: "color-picker-circle-input",
554
556
  type: "color",
555
- value: Me.value,
556
- onChange: Ml(cl, ["stop"])
557
- }, null, 40, Ul)
557
+ value: Ce.value,
558
+ onChange: Cl(dl, ["stop"])
559
+ }, null, 40, xl)
558
560
  ])) : H("", !0)
559
561
  ]),
560
- s("div", xl, [
561
- s("div", {
562
+ n("div", Vl, [
563
+ n("div", {
562
564
  class: "color-picker-input-mode",
563
- style: h({ cursor: e.modes.length === 1 ? "" : "pointer" }),
564
- onClick: il
565
- }, me(j.value), 5),
566
- s("div", Vl, [
567
- m.value === "hex" ? (b(), K(T(Be), {
565
+ style: p({ cursor: e.modes.length === 1 ? "" : "pointer" }),
566
+ onClick: cl
567
+ }, ge(Y.value), 5),
568
+ n("div", Il, [
569
+ m.value === "hex" ? (b(), J(T(_e), me({
568
570
  key: 0,
569
571
  size: "small",
570
- placeholder: j.value,
572
+ placeholder: Y.value,
571
573
  value: re.value,
572
574
  "onUpdate:value": l[0] || (l[0] = (t) => re.value = t),
573
575
  valueModifiers: { lazy: !0 },
574
- onChange: ze
575
- }, null, 8, ["placeholder", "value"])) : (b(!0), R(ge, { key: 1 }, Le(el.value, (t, o) => (b(), K(T(Be), {
576
+ onChange: xe
577
+ }, e.inputProps), null, 16, ["placeholder", "value"])) : (b(!0), R(be, { key: 1 }, Ne(ll.value, (t, o) => (b(), J(T(_e), me({
576
578
  size: "small",
577
- style: h(`${t === "A" ? "flex-grow: 1.25" : ""}`),
579
+ style: `${t === "A" ? "flex-grow: 1.25" : ""}`,
580
+ key: o,
578
581
  placeholder: t,
579
582
  value: x.value[o],
580
583
  "onUpdate:value": (S) => x.value[o] = S,
581
584
  valueModifiers: { lazy: !0 },
582
- onChange: (S) => ze(S, o),
583
- key: o
584
- }, null, 8, ["style", "placeholder", "value", "onUpdate:value", "onChange"]))), 128))
585
+ onChange: (S) => xe(S, o),
586
+ ref_for: !0
587
+ }, e.inputProps), null, 16, ["style", "placeholder", "value", "onUpdate:value", "onChange"]))), 128))
585
588
  ])
586
589
  ]),
587
- Ce.value.length ? (b(), R("div", Il, [
588
- (b(!0), R(ge, null, Le(Ce.value, (t, o) => (b(), R("div", {
590
+ He.value.length ? (b(), R("div", Ll, [
591
+ (b(!0), R(be, null, Ne(He.value, (t, o) => (b(), R("div", {
589
592
  tabindex: "0",
590
593
  class: "color-picker-swatch",
591
594
  key: o,
592
- onClick: (S) => kl(t)
595
+ onClick: (S) => yl(t)
593
596
  }, [
594
- s("div", {
597
+ n("div", {
595
598
  class: "color-picker-swatch-fill",
596
- style: h(`background: ${t.legalValue};`)
599
+ style: p(`background: ${t.legalValue};`)
597
600
  }, null, 4)
598
- ], 8, Ll))), 128))
601
+ ], 8, Nl))), 128))
599
602
  ])) : H("", !0)
600
603
  ], 2),
601
- e.actions.length ? (b(), R("div", Nl, [
602
- e.actions.includes("confirm") ? (b(), K(T(_e), {
604
+ e.actions.length ? (b(), R("div", Bl, [
605
+ e.actions.includes("confirm") ? (b(), J(T(Pe), {
603
606
  key: 0,
604
607
  type: "primary",
605
608
  size: "small",
606
- onClick: yl
609
+ onClick: wl
607
610
  }, {
608
611
  default: se(() => l[3] || (l[3] = [
609
612
  ne("确认")
610
613
  ])),
611
614
  _: 1
612
615
  })) : H("", !0),
613
- e.actions.includes("clear") ? (b(), K(T(_e), {
616
+ e.actions.includes("clear") ? (b(), J(T(Pe), {
614
617
  key: 1,
615
618
  size: "small",
616
- onClick: wl
619
+ onClick: $l
617
620
  }, {
618
621
  default: se(() => l[4] || (l[4] = [
619
622
  ne("清除")
@@ -621,40 +624,47 @@ const Hl = { class: "color-picker-preview" }, El = { class: "color-picker-previe
621
624
  _: 1
622
625
  })) : H("", !0)
623
626
  ])) : H("", !0),
624
- Oe.value ? (b(), R("div", Bl, [
625
- Ie(e.$slots, "footer", {}, () => [
626
- ne(me(e.footer), 1)
627
+ Ze.value ? (b(), R("div", _l, [
628
+ Le(e.$slots, "footer", {}, () => [
629
+ ne(ge(e.footer), 1)
627
630
  ], !0)
628
631
  ])) : H("", !0)
629
632
  ], 64))
630
633
  ]),
631
634
  default: se(() => [
632
- s("div", {
635
+ n("div", me({
633
636
  tabindex: "1",
634
- class: Ve(["color-picker-display", [`color-picker-${e.size}`, { "color-picker-disabled": e.disabled }]]),
635
- style: h(`--color-picker-height: ${de.value}; --color-picker-block-size: ${We.value};`)
636
- }, [
637
- s("div", _l, [
638
- s("div", Dl, [
639
- l[5] || (l[5] = s("div", { class: "color-picker-checkboard" }, null, -1)),
640
- s("div", {
641
- style: h(`position: absolute; left: 0; right: 0; top: 0; bottom: 0; background-color: ${F.value ? T(_)(F.value) : ""};`)
637
+ class: ["color-picker-display", [`color-picker-${e.size}`, { "color-picker-disabled": e.disabled }]],
638
+ style: `
639
+ --color-picker-width: ${Re.value};
640
+ --color-picker-height: ${de.value};
641
+ --color-picker-block-size: ${el.value};
642
+ --color-picker-primary-color-hover: #4096ff;
643
+ --color-picker-primary-color-focus: #4096ff;
644
+ --color-picker-primary-shadow-color: rgba(5, 145, 255, 0.1);
645
+ `
646
+ }, e.$attrs), [
647
+ n("div", Pl, [
648
+ n("div", Dl, [
649
+ l[5] || (l[5] = n("div", { class: "color-picker-checkboard" }, null, -1)),
650
+ n("div", {
651
+ style: p(`position: absolute; left: 0; right: 0; top: 0; bottom: 0; background-color: ${D.value ? T(_)(D.value) : ""};`)
642
652
  }, null, 4),
643
- i.value && F.value ? (b(), R("div", {
653
+ i.value && D.value ? (b(), R("div", {
644
654
  key: 0,
645
655
  class: "color-picker-value",
646
- style: h({ color: F.value[2] > 50 || F.value[3] < 0.5 ? "black" : "white" })
656
+ style: p({ color: D.value[2] > 50 || D.value[3] < 0.5 ? "black" : "white" })
647
657
  }, [
648
- Ie(e.$slots, "label", { color: i.value }, () => [
649
- ne(me(e.label ? e.label(i.value) : i.value), 1)
658
+ Le(e.$slots, "label", { color: i.value }, () => [
659
+ ne(ge(e.label ? e.label(i.value) : i.value), 1)
650
660
  ], !0)
651
661
  ], 4)) : H("", !0)
652
662
  ])
653
663
  ])
654
- ], 6)
664
+ ], 16)
655
665
  ]),
656
666
  _: 3
657
- }, 16, ["style", "tooltip-style"]));
667
+ }, 8, ["style", "tooltip-style"]));
658
668
  }
659
669
  });
660
670
  export {