morya-ui 0.4.5 → 0.5.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.
Files changed (220) hide show
  1. package/CHANGELOG.md +41 -2
  2. package/dist/{Input-D2bee2LU.js → Input-BErawS7K.js} +1 -5
  3. package/dist/InputNumber-DjbXtTzR.js +245 -0
  4. package/dist/{Pagination-DpNOb0CS.js → Pagination-B8WYoL2a.js} +1 -1
  5. package/dist/{Popover-Bnz7KNZq.js → Popover-zQChu00_.js} +6 -1
  6. package/dist/{Select-q4X2ff_M.js → Select-BaFKBeIh.js} +2 -2
  7. package/dist/{Textarea-DsFOAtPd.js → Textarea-WCEgpzbq.js} +1 -5
  8. package/dist/accordion/style.css +6 -15
  9. package/dist/affix/style.css +6 -15
  10. package/dist/alert/style.css +6 -15
  11. package/dist/anchor/style.css +6 -15
  12. package/dist/auto-complete/style.css +6 -15
  13. package/dist/avatar/style.css +6 -15
  14. package/dist/badge/style.css +6 -15
  15. package/dist/block-ui/style.css +6 -15
  16. package/dist/breadcrumb/style.css +6 -15
  17. package/dist/button/style.css +6 -15
  18. package/dist/calendar/index.js +1 -1
  19. package/dist/calendar/style.css +6 -15
  20. package/dist/card/style.css +6 -15
  21. package/dist/carousel/style.css +6 -15
  22. package/dist/cascade-select/style.css +6 -15
  23. package/dist/checkbox/style.css +6 -15
  24. package/dist/chip/style.css +6 -15
  25. package/dist/color-picker/index.js +676 -0
  26. package/dist/{input-color → color-picker}/style.css +1406 -83
  27. package/dist/color-picker/style.js +8 -0
  28. package/dist/command-menu/index.js +73 -66
  29. package/dist/command-menu/style.css +6 -15
  30. package/dist/components/ColorPicker/ColorPicker.vue.d.ts +41 -0
  31. package/dist/components/ColorPicker/ColorPicker.vue.d.ts.map +1 -0
  32. package/dist/components/ColorPicker/colorUtils.d.ts +23 -0
  33. package/dist/components/ColorPicker/colorUtils.d.ts.map +1 -0
  34. package/dist/components/ColorPicker/gradientUtils.d.ts +9 -0
  35. package/dist/components/ColorPicker/gradientUtils.d.ts.map +1 -0
  36. package/dist/components/ColorPicker/index.d.ts +3 -0
  37. package/dist/components/ColorPicker/index.d.ts.map +1 -0
  38. package/dist/components/ColorPicker/styles.css +405 -0
  39. package/dist/components/ColorPicker/types.d.ts +60 -0
  40. package/dist/components/ColorPicker/types.d.ts.map +1 -0
  41. package/dist/components/CommandMenu/CommandMenu.vue.d.ts.map +1 -1
  42. package/dist/components/ContextMenu/ContextMenuNodes.vue.d.ts.map +1 -1
  43. package/dist/components/ContextMenu/styles.css +1 -1
  44. package/dist/components/Dock/Dock.vue.d.ts.map +1 -1
  45. package/dist/components/Dropdown/DropdownNodes.vue.d.ts.map +1 -1
  46. package/dist/components/Dropdown/styles.css +1 -1
  47. package/dist/components/Input/Input.vue.d.ts +0 -1
  48. package/dist/components/Input/Input.vue.d.ts.map +1 -1
  49. package/dist/components/Input/types.d.ts +0 -2
  50. package/dist/components/Input/types.d.ts.map +1 -1
  51. package/dist/components/InputNumber/styles.css +28 -10
  52. package/dist/components/InputPassword/InputPassword.vue.d.ts +0 -1
  53. package/dist/components/InputPassword/InputPassword.vue.d.ts.map +1 -1
  54. package/dist/components/InputPassword/types.d.ts +0 -2
  55. package/dist/components/InputPassword/types.d.ts.map +1 -1
  56. package/dist/components/MegaMenu/MegaMenu.vue.d.ts.map +1 -1
  57. package/dist/components/Mentions/Mentions.vue.d.ts +0 -1
  58. package/dist/components/Mentions/Mentions.vue.d.ts.map +1 -1
  59. package/dist/components/Mentions/types.d.ts +0 -2
  60. package/dist/components/Mentions/types.d.ts.map +1 -1
  61. package/dist/components/Menu/Menu.vue.d.ts.map +1 -1
  62. package/dist/components/Menu/MenuNodes.vue.d.ts.map +1 -1
  63. package/dist/components/Menu/styles.css +45 -3
  64. package/dist/components/Menu/types.d.ts +3 -1
  65. package/dist/components/Menu/types.d.ts.map +1 -1
  66. package/dist/components/Menubar/Menubar.vue.d.ts +2 -2
  67. package/dist/components/Menubar/Menubar.vue.d.ts.map +1 -1
  68. package/dist/components/Menubar/styles.css +1 -1
  69. package/dist/components/Popover/Popover.vue.d.ts.map +1 -1
  70. package/dist/components/Rating/Rating.vue.d.ts +1 -1
  71. package/dist/components/Rating/types.d.ts +2 -2
  72. package/dist/components/Rating/types.d.ts.map +1 -1
  73. package/dist/components/Select/Select.vue.d.ts +1 -1
  74. package/dist/components/Select/types.d.ts +1 -1
  75. package/dist/components/Select/types.d.ts.map +1 -1
  76. package/dist/components/Sidebar/Sidebar.vue.d.ts.map +1 -1
  77. package/dist/components/SpeedDial/SpeedDial.vue.d.ts +3 -3
  78. package/dist/components/SpeedDial/SpeedDial.vue.d.ts.map +1 -1
  79. package/dist/components/SplitButton/SplitButton.vue.d.ts.map +1 -1
  80. package/dist/components/Textarea/Textarea.vue.d.ts +0 -1
  81. package/dist/components/Textarea/Textarea.vue.d.ts.map +1 -1
  82. package/dist/components/Textarea/types.d.ts +0 -2
  83. package/dist/components/Textarea/types.d.ts.map +1 -1
  84. package/dist/components/TieredMenu/styles.css +2 -2
  85. package/dist/components/Tooltip/styles.css +15 -2
  86. package/dist/config-provider/style.css +6 -15
  87. package/dist/confirm-dialog/style.css +6 -15
  88. package/dist/confirm-popup/style.css +6 -15
  89. package/dist/context-menu/index.js +92 -84
  90. package/dist/context-menu/style.css +7 -16
  91. package/dist/data-view/index.js +1 -1
  92. package/dist/data-view/style.css +6 -15
  93. package/dist/date-picker/style.css +6 -15
  94. package/dist/descriptions/style.css +6 -15
  95. package/dist/dialog/style.css +6 -15
  96. package/dist/divider/style.css +6 -15
  97. package/dist/dock/index.js +21 -18
  98. package/dist/dock/style.css +6 -15
  99. package/dist/drawer/style.css +6 -15
  100. package/dist/dropdown/index.js +103 -95
  101. package/dist/dropdown/style.css +7 -16
  102. package/dist/empty/style.css +6 -15
  103. package/dist/fieldset/style.css +6 -15
  104. package/dist/file-upload/style.css +6 -15
  105. package/dist/flex/style.css +6 -15
  106. package/dist/float-label/style.css +6 -15
  107. package/dist/fluid/style.css +6 -15
  108. package/dist/form/style.css +6 -15
  109. package/dist/gallery/style.css +6 -15
  110. package/dist/grid/style.css +6 -15
  111. package/dist/icon/style.css +6 -15
  112. package/dist/{icon-H8prbteT.js → icon-CUrSaD8r.js} +4 -1
  113. package/dist/icon-field/style.css +6 -15
  114. package/dist/image/style.css +6 -15
  115. package/dist/index.d.ts +2 -2
  116. package/dist/index.d.ts.map +1 -1
  117. package/dist/index.js +4047 -3420
  118. package/dist/inplace/style.css +6 -15
  119. package/dist/input/index.js +1 -1
  120. package/dist/input/style.css +6 -15
  121. package/dist/input-group/style.css +6 -15
  122. package/dist/input-number/index.js +2 -245
  123. package/dist/input-number/style.css +34 -25
  124. package/dist/input-otp/style.css +6 -15
  125. package/dist/input-password/index.js +1 -5
  126. package/dist/input-password/style.css +6 -15
  127. package/dist/input-tags/style.css +6 -15
  128. package/dist/knob/style.css +6 -15
  129. package/dist/label/style.css +6 -15
  130. package/dist/layout/style.css +6 -15
  131. package/dist/list/index.js +1 -1
  132. package/dist/list/style.css +6 -15
  133. package/dist/listbox/style.css +6 -15
  134. package/dist/loading/style.css +6 -15
  135. package/dist/mega-menu/index.js +94 -87
  136. package/dist/mega-menu/style.css +6 -15
  137. package/dist/mentions/index.js +35 -39
  138. package/dist/mentions/style.css +6 -15
  139. package/dist/menu/index.js +235 -213
  140. package/dist/menu/style.css +66 -20
  141. package/dist/menubar/index.js +107 -99
  142. package/dist/menubar/style.css +7 -16
  143. package/dist/message/style.css +6 -15
  144. package/dist/meter-group/style.css +6 -15
  145. package/dist/order-list/style.css +6 -15
  146. package/dist/page/style.css +6 -15
  147. package/dist/pagination/index.js +1 -1
  148. package/dist/pagination/style.css +6 -15
  149. package/dist/panel/style.css +6 -15
  150. package/dist/pick-list/style.css +6 -15
  151. package/dist/popover/index.js +1 -1
  152. package/dist/popover/style.css +6 -15
  153. package/dist/progress-bar/style.css +6 -15
  154. package/dist/progress-spinner/style.css +6 -15
  155. package/dist/qr-code/style.css +6 -15
  156. package/dist/radio/style.css +6 -15
  157. package/dist/rating/index.js +2 -2
  158. package/dist/rating/style.css +6 -15
  159. package/dist/resolver.js +1 -1
  160. package/dist/result/style.css +6 -15
  161. package/dist/scroll-top/style.css +6 -15
  162. package/dist/scrollbar/style.css +6 -15
  163. package/dist/segmented/style.css +6 -15
  164. package/dist/select/index.js +1 -1
  165. package/dist/select/style.css +6 -15
  166. package/dist/select-button/style.css +6 -15
  167. package/dist/shared/menu/icon.d.ts +3 -0
  168. package/dist/shared/menu/icon.d.ts.map +1 -1
  169. package/dist/shared/menu/index.d.ts +2 -2
  170. package/dist/shared/menu/index.d.ts.map +1 -1
  171. package/dist/shared/menu/types.d.ts +3 -1
  172. package/dist/shared/menu/types.d.ts.map +1 -1
  173. package/dist/sidebar/index.js +37 -29
  174. package/dist/sidebar/style.css +6 -15
  175. package/dist/skeleton/style.css +6 -15
  176. package/dist/slider/style.css +6 -15
  177. package/dist/space/style.css +6 -15
  178. package/dist/speed-dial/index.js +101 -94
  179. package/dist/speed-dial/style.css +6 -15
  180. package/dist/split-button/index.js +3 -3
  181. package/dist/split-button/style.css +6 -15
  182. package/dist/splitter/style.css +6 -15
  183. package/dist/statistic/style.css +6 -15
  184. package/dist/status/style.css +6 -15
  185. package/dist/stepper/style.css +6 -15
  186. package/dist/styles/base.css +6 -15
  187. package/dist/styles.css +1 -1
  188. package/dist/switch/style.css +6 -15
  189. package/dist/table/index.js +3 -3
  190. package/dist/table/style.css +6 -15
  191. package/dist/tabs/style.css +6 -15
  192. package/dist/tag/style.css +6 -15
  193. package/dist/terminal/style.css +6 -15
  194. package/dist/textarea/index.js +1 -1
  195. package/dist/textarea/style.css +6 -15
  196. package/dist/tiered-menu/style.css +8 -17
  197. package/dist/time-picker/style.css +6 -15
  198. package/dist/timeline/style.css +6 -15
  199. package/dist/toast/style.css +6 -15
  200. package/dist/toggle-button/index.js +1 -1
  201. package/dist/toggle-button/style.css +6 -15
  202. package/dist/toolbar/style.css +6 -15
  203. package/dist/tooltip/style.css +21 -17
  204. package/dist/tour/style.css +6 -15
  205. package/dist/tree/style.css +6 -15
  206. package/dist/tree-select/style.css +6 -15
  207. package/dist/typography/index.js +1 -1
  208. package/dist/typography/style.css +6 -15
  209. package/dist/virtual-scroller/style.css +6 -15
  210. package/dist/watermark/style.css +6 -15
  211. package/package.json +8 -8
  212. package/dist/components/InputColor/InputColor.vue.d.ts +0 -24
  213. package/dist/components/InputColor/InputColor.vue.d.ts.map +0 -1
  214. package/dist/components/InputColor/index.d.ts +0 -3
  215. package/dist/components/InputColor/index.d.ts.map +0 -1
  216. package/dist/components/InputColor/styles.css +0 -139
  217. package/dist/components/InputColor/types.d.ts +0 -19
  218. package/dist/components/InputColor/types.d.ts.map +0 -1
  219. package/dist/input-color/index.js +0 -118
  220. package/dist/input-color/style.js +0 -3
@@ -0,0 +1,8 @@
1
+ import '../theme/styles.css'
2
+ import '../styles/base.css'
3
+ import '../components/Icon/styles.css'
4
+ import '../components/Input/styles.css'
5
+ import '../components/InputNumber/styles.css'
6
+ import '../components/Segmented/styles.css'
7
+ import '../components/Select/styles.css'
8
+ import '../components/ColorPicker/styles.css'
@@ -1,32 +1,32 @@
1
1
  import { a as e } from "../useComponentAttrs-e-5QAjdw.js";
2
2
  import { t } from "../filterByQuery-Bczaxzih.js";
3
- import { n as ee } from "../overlay-oR-5MDuE.js";
4
- import { t as n } from "../useMotionTransition-DohkfWRB.js";
5
- import { t as te } from "../Icon-CmHjx7W8.js";
6
- import { t as ne } from "../Scrollbar-DTeJ8P5b.js";
7
- import { t as r } from "../icon-H8prbteT.js";
8
- import { t as i } from "../useModalOverlay-Beo3CEAt.js";
9
- import { l as a } from "../config-Cd20zAyW.js";
3
+ import { n } from "../overlay-oR-5MDuE.js";
4
+ import { t as r } from "../useMotionTransition-DohkfWRB.js";
5
+ import { t as i } from "../Icon-CmHjx7W8.js";
6
+ import { t as ee } from "../Scrollbar-DTeJ8P5b.js";
7
+ import { n as a, t as o } from "../icon-CUrSaD8r.js";
8
+ import { t as te } from "../useModalOverlay-Beo3CEAt.js";
9
+ import { l as ne } from "../config-Cd20zAyW.js";
10
10
  import { n as re } from "../locale-BcxMPufl.js";
11
11
  import "./style.js";
12
- import { Fragment as o, Teleport as s, Transition as c, computed as l, createBlock as ie, createCommentVNode as u, createElementBlock as d, createElementVNode as f, createVNode as p, defineComponent as m, mergeProps as h, nextTick as g, normalizeClass as _, openBlock as v, ref as y, renderList as ae, toDisplayString as b, toRef as oe, unref as x, useAttrs as S, vModelText as C, watch as w, withCtx as T, withDirectives as E, withModifiers as D } from "vue";
12
+ import { Fragment as ie, Teleport as s, Transition as c, computed as l, createBlock as u, createCommentVNode as d, createElementBlock as f, createElementVNode as p, createVNode as m, defineComponent as h, mergeProps as ae, nextTick as oe, normalizeClass as se, openBlock as g, ref as _, renderList as ce, resolveDynamicComponent as le, toDisplayString as v, toRef as y, unref as b, useAttrs as x, vModelText as S, watch as C, withCtx as w, withDirectives as T, withModifiers as E } from "vue";
13
13
  //#region src/components/CommandMenu/CommandMenu.vue?vue&type=script&setup=true&lang.ts
14
- var O = ["aria-label"], k = ["placeholder", "aria-label"], A = [
14
+ var D = ["aria-label"], O = ["placeholder", "aria-label"], k = [
15
15
  "aria-selected",
16
16
  "disabled",
17
17
  "onClick",
18
18
  "onMouseenter"
19
- ], j = {
19
+ ], A = {
20
20
  key: 0,
21
21
  class: "m-commandmenu__icon",
22
22
  "aria-hidden": "true"
23
- }, M = { class: "m-commandmenu__label" }, N = {
23
+ }, j = { class: "m-commandmenu__label" }, M = {
24
24
  key: 1,
25
25
  class: "m-commandmenu__shortcut"
26
- }, P = {
26
+ }, N = {
27
27
  key: 0,
28
28
  class: "m-commandmenu__empty"
29
- }, F = /* @__PURE__ */ m({
29
+ }, P = /* @__PURE__ */ h({
30
30
  inheritAttrs: !1,
31
31
  __name: "CommandMenu",
32
32
  props: {
@@ -48,99 +48,106 @@ var O = ["aria-label"], k = ["placeholder", "aria-label"], A = [
48
48
  }
49
49
  },
50
50
  emits: ["update:modelValue"],
51
- setup(m, { emit: F }) {
52
- let I = m, L = F, R = S(), { rootAttrs: z } = e(R, () => I.pt), B = a(), { transitionName: V, transitionCss: H } = n({
51
+ setup(h, { emit: P }) {
52
+ let F = h, I = P, L = x(), { rootAttrs: R } = e(L, () => F.pt), z = ne(), { transitionName: B, transitionCss: V } = r({
53
53
  role: "tooltip",
54
- local: () => I.transition,
54
+ local: () => F.transition,
55
55
  componentName: "CommandMenu",
56
56
  fallback: "fade"
57
- }), U = re(), W = l(() => I.placeholder ?? U.value.searchCommands), G = y(""), K = y(null), q = y(null), J = y(0), Y = l(() => ee(I, B.value.appendTo)), X = l(() => t(I.model, G.value));
58
- function Z() {
59
- L("update:modelValue", !1);
57
+ }), H = re(), U = l(() => F.placeholder ?? H.value.searchCommands), W = _(""), G = _(null), K = _(null), q = _(0), J = l(() => n(F, z.value.appendTo)), Y = l(() => t(F.model, W.value));
58
+ function X() {
59
+ I("update:modelValue", !1);
60
+ }
61
+ function Z(e) {
62
+ e.disabled || (e.command?.(), X());
60
63
  }
61
64
  function Q(e) {
62
- e.disabled || (e.command?.(), Z());
65
+ return typeof e.icon == "string" ? o(e.icon) : void 0;
63
66
  }
64
67
  function $(e) {
65
- return r(e.icon);
68
+ return a(e.icon);
69
+ }
70
+ function ue(e) {
71
+ return !!(Q(e) || $(e));
66
72
  }
67
- function se(e) {
68
- if (e.key === "ArrowDown" && (e.preventDefault(), J.value = Math.min(X.value.length - 1, J.value + 1)), e.key === "ArrowUp" && (e.preventDefault(), J.value = Math.max(0, J.value - 1)), e.key === "Enter") {
69
- let t = X.value[J.value];
70
- t && (e.preventDefault(), Q(t));
73
+ function de(e) {
74
+ if (e.key === "ArrowDown" && (e.preventDefault(), q.value = Math.min(Y.value.length - 1, q.value + 1)), e.key === "ArrowUp" && (e.preventDefault(), q.value = Math.max(0, q.value - 1)), e.key === "Enter") {
75
+ let t = Y.value[q.value];
76
+ t && (e.preventDefault(), Z(t));
71
77
  }
72
78
  }
73
- return i({
74
- open: oe(I, "modelValue"),
75
- container: K,
79
+ return te({
80
+ open: y(F, "modelValue"),
81
+ container: G,
76
82
  blockScroll: !0,
77
83
  autoFocus: !1,
78
- onEscape: Z,
84
+ onEscape: X,
79
85
  onOpen: () => {
80
- G.value = "", J.value = 0;
86
+ W.value = "", q.value = 0;
81
87
  }
82
- }), w(() => I.modelValue, async (e) => {
83
- e && (await g(), q.value?.focus());
84
- }), w(X, () => {
85
- J.value = 0;
86
- }), (e, t) => (v(), ie(s, {
87
- to: Y.value.to,
88
- disabled: Y.value.disabled
89
- }, [p(c, {
90
- name: x(V),
91
- css: x(H)
88
+ }), C(() => F.modelValue, async (e) => {
89
+ e && (await oe(), K.value?.focus());
90
+ }), C(Y, () => {
91
+ q.value = 0;
92
+ }), (e, t) => (g(), u(s, {
93
+ to: J.value.to,
94
+ disabled: J.value.disabled
95
+ }, [m(c, {
96
+ name: b(B),
97
+ css: b(V)
92
98
  }, {
93
- default: T(() => [m.modelValue ? (v(), d("div", h({ key: 0 }, x(z), {
99
+ default: w(() => [h.modelValue ? (g(), f("div", ae({ key: 0 }, b(R), {
94
100
  class: "m-commandmenu-backdrop",
95
- onClick: D(Z, ["self"])
96
- }), [f("div", {
101
+ onClick: E(X, ["self"])
102
+ }), [p("div", {
97
103
  ref_key: "panelRef",
98
- ref: K,
104
+ ref: G,
99
105
  class: "m-commandmenu",
100
106
  role: "dialog",
101
107
  "aria-modal": "true",
102
- "aria-label": x(U).commandPalette,
108
+ "aria-label": b(H).commandPalette,
103
109
  tabindex: "-1",
104
- onKeydown: se
105
- }, [E(f("input", {
110
+ onKeydown: de
111
+ }, [T(p("input", {
106
112
  ref_key: "inputRef",
107
- ref: q,
108
- "onUpdate:modelValue": t[0] ||= (e) => G.value = e,
113
+ ref: K,
114
+ "onUpdate:modelValue": t[0] ||= (e) => W.value = e,
109
115
  class: "m-commandmenu__input",
110
116
  type: "search",
111
- placeholder: W.value,
112
- "aria-label": x(U).searchCommands
113
- }, null, 8, k), [[C, G.value]]), p(ne, {
117
+ placeholder: U.value,
118
+ "aria-label": b(H).searchCommands
119
+ }, null, 8, O), [[S, W.value]]), m(ee, {
114
120
  tag: "ul",
115
121
  role: "listbox",
116
122
  class: "m-commandmenu__list",
117
123
  "fit-content": "",
118
124
  "view-class": "m-commandmenu__list-view"
119
125
  }, {
120
- default: T(() => [(v(!0), d(o, null, ae(X.value, (e, t) => (v(), d("li", {
126
+ default: w(() => [(g(!0), f(ie, null, ce(Y.value, (e, t) => (g(), f("li", {
121
127
  key: `${e.label}-${t}`,
122
128
  role: "presentation"
123
- }, [f("button", {
129
+ }, [p("button", {
124
130
  type: "button",
125
- class: _(["m-commandmenu__item", { "m-commandmenu__item--active": t === J.value }]),
131
+ class: se(["m-commandmenu__item", { "m-commandmenu__item--active": t === q.value }]),
126
132
  role: "option",
127
- "aria-selected": t === J.value,
133
+ "aria-selected": t === q.value,
128
134
  disabled: e.disabled,
129
- onClick: (t) => Q(e),
130
- onMouseenter: (e) => J.value = t
135
+ onClick: (t) => Z(e),
136
+ onMouseenter: (e) => q.value = t
131
137
  }, [
132
- $(e) ? (v(), d("span", j, [p(te, {
133
- name: $(e),
138
+ ue(e) ? (g(), f("span", A, [Q(e) ? (g(), u(i, {
139
+ key: 0,
140
+ name: Q(e),
134
141
  size: "sm"
135
- }, null, 8, ["name"])])) : u("", !0),
136
- f("span", M, b(e.label), 1),
137
- e.shortcut ? (v(), d("span", N, b(e.shortcut), 1)) : u("", !0)
138
- ], 42, A)]))), 128)), X.value.length ? u("", !0) : (v(), d("li", P, b(x(U).noMatch), 1))]),
142
+ }, null, 8, ["name"])) : $(e) ? (g(), u(le($(e)), { key: 1 })) : d("", !0)])) : d("", !0),
143
+ p("span", j, v(e.label), 1),
144
+ e.shortcut ? (g(), f("span", M, v(e.shortcut), 1)) : d("", !0)
145
+ ], 42, k)]))), 128)), Y.value.length ? d("", !0) : (g(), f("li", N, v(b(H).noMatch), 1))]),
139
146
  _: 1
140
- })], 40, O)], 16)) : u("", !0)]),
147
+ })], 40, D)], 16)) : d("", !0)]),
141
148
  _: 1
142
149
  }, 8, ["name", "css"])], 8, ["to", "disabled"]));
143
150
  }
144
151
  });
145
152
  //#endregion
146
- export { F as MCommandMenu };
153
+ export { P as MCommandMenu };
@@ -405,7 +405,7 @@
405
405
 
406
406
  :root {
407
407
  /* Shared minimum width for menu-like panels (select/orderlist/picklist) */
408
- --m-menu-min-width: 12rem;
408
+ --m-overlay-menu-min-width: 12rem;
409
409
  }
410
410
 
411
411
  .m-button,
@@ -463,7 +463,7 @@
463
463
  .m-progress-spinner,
464
464
  .m-cascadeselect,
465
465
  .m-treeselect,
466
- .m-inputcolor,
466
+ .m-colorpicker,
467
467
  .m-inputtags,
468
468
  .m-label,
469
469
  .m-speeddial,
@@ -489,8 +489,7 @@
489
489
  .m-password__input:disabled,
490
490
  .m-inputnumber__input:disabled,
491
491
  .m-inputotp__input:disabled,
492
- .m-inputcolor__text:disabled,
493
- .m-inputcolor__swatch:disabled,
492
+ .m-colorpicker__trigger:disabled,
494
493
  .m-inputtags--disabled {
495
494
  background-color: var(--m-color-bg-disabled);
496
495
  color: var(--m-color-text-disabled);
@@ -513,8 +512,7 @@
513
512
  .m-textarea::placeholder,
514
513
  .m-password__input::placeholder,
515
514
  .m-inputnumber__input::placeholder,
516
- .m-inputtags__input::placeholder,
517
- .m-inputcolor__text::placeholder {
515
+ .m-inputtags__input::placeholder {
518
516
  color: var(--m-color-text-muted);
519
517
  opacity: 1;
520
518
  }
@@ -858,9 +856,7 @@
858
856
  font-family: var(--m-font-sans);
859
857
  gap: var(--m-space-2);
860
858
  max-width: 100%;
861
- min-width: var(--m-menu-min-width);
862
859
  position: relative;
863
- width: fit-content;
864
860
  }
865
861
 
866
862
  .m-textarea-field--fluid,
@@ -1051,7 +1047,7 @@
1051
1047
  flex: 1;
1052
1048
  max-height: 16rem;
1053
1049
  min-height: 12rem;
1054
- min-width: var(--m-menu-min-width);
1050
+ min-width: var(--m-overlay-menu-min-width);
1055
1051
  }
1056
1052
 
1057
1053
  .m-orderlist__list,
@@ -1119,7 +1115,6 @@
1119
1115
  .m-cascadeselect__trigger:hover:not(:disabled):not(:focus):not(:focus-visible),
1120
1116
  .m-treeselect:not(.m-treeselect--open)
1121
1117
  .m-treeselect__trigger:hover:not(:disabled):not(:focus):not(:focus-visible),
1122
- .m-inputcolor__text:hover:not(:disabled):not(:focus),
1123
1118
  .m-inputtags:hover:not(.m-inputtags--disabled):not(:focus-within),
1124
1119
  .m-togglebutton:hover:not(:disabled):not(.m-togglebutton--checked):not(:focus-visible),
1125
1120
  .m-inplace__display:hover:not(:focus-visible) {
@@ -1134,8 +1129,6 @@
1134
1129
  .m-treeselect--open .m-treeselect__trigger,
1135
1130
  .m-treeselect__trigger:focus,
1136
1131
  .m-treeselect__trigger:focus-visible,
1137
- .m-inputcolor__text:focus,
1138
- .m-inputcolor__text:focus-visible,
1139
1132
  .m-inputtags:focus-within,
1140
1133
  .m-togglebutton:focus-visible,
1141
1134
  .m-selectbutton__button:focus-visible,
@@ -1150,9 +1143,7 @@
1150
1143
 
1151
1144
  .m-inputotp--invalid .m-inputotp__input:focus,
1152
1145
  .m-inputotp--invalid .m-inputotp__input:focus-visible,
1153
- .m-inputtags--invalid:focus-within,
1154
- .m-inputcolor--invalid .m-inputcolor__text:focus,
1155
- .m-inputcolor--invalid .m-inputcolor__text:focus-visible {
1146
+ .m-inputtags--invalid:focus-within {
1156
1147
  border-color: var(--m-color-danger);
1157
1148
  box-shadow: var(--m-focus-shadow-danger);
1158
1149
  }
@@ -0,0 +1,41 @@
1
+ import { ColorPickerFormat, ColorPickerProps, ColorPickerPlacement, ColorPickerPreset } from './types';
2
+ import { DefineComponent, ComponentOptionsMixin, PublicProps, ComponentProvideOptions } from 'vue';
3
+ import { MSizeInput, MotionPresetId } from '../..';
4
+ import { FieldPassThrough } from '../../shared/passThrough';
5
+ declare function openPanel(): void;
6
+ declare function closePanel(): void;
7
+ declare function togglePanel(): void;
8
+ declare const __VLS_export: DefineComponent<ColorPickerProps, {
9
+ open: typeof openPanel;
10
+ close: typeof closePanel;
11
+ toggle: typeof togglePanel;
12
+ }, {}, {}, {}, ComponentOptionsMixin, ComponentOptionsMixin, {} & {
13
+ "update:modelValue": (value: string) => any;
14
+ clear: () => any;
15
+ change: (value: string) => any;
16
+ show: () => any;
17
+ hide: () => any;
18
+ }, string, PublicProps, Readonly<ColorPickerProps> & Readonly<{
19
+ "onUpdate:modelValue"?: ((value: string) => any) | undefined;
20
+ onClear?: (() => any) | undefined;
21
+ onChange?: ((value: string) => any) | undefined;
22
+ onShow?: (() => any) | undefined;
23
+ onHide?: (() => any) | undefined;
24
+ }>, {
25
+ size: MSizeInput;
26
+ pt: FieldPassThrough;
27
+ modelValue: string;
28
+ disabled: boolean;
29
+ transition: MotionPresetId | false;
30
+ clearable: boolean;
31
+ teleport: boolean;
32
+ placement: ColorPickerPlacement;
33
+ format: ColorPickerFormat;
34
+ gradient: boolean;
35
+ disabledAlpha: boolean;
36
+ presets: ColorPickerPreset[];
37
+ showText: boolean;
38
+ }, {}, {}, {}, string, ComponentProvideOptions, false, {}, any>;
39
+ declare const _default: typeof __VLS_export;
40
+ export default _default;
41
+ //# sourceMappingURL=ColorPicker.vue.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"ColorPicker.vue.d.ts","sourceRoot":"","sources":["../../../src/components/ColorPicker/ColorPicker.vue"],"names":[],"mappings":";;;AAuvBA,OAAO,KAAK,EAAE,iBAAiB,EAAE,gBAAgB,EAA+B,MAAM,SAAS,CAAA;AA8gB/F,iBAAS,SAAS,SAQjB;AAED,iBAAS,UAAU,SAOlB;AAED,iBAAS,WAAW,SAGnB;AAyiBD,QAAA,MAAM,YAAY;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;6EAKhB,CAAC;wBACkB,OAAO,YAAY;AAAxC,wBAAyC"}
@@ -0,0 +1,23 @@
1
+ export interface RGB {
2
+ r: number;
3
+ g: number;
4
+ b: number;
5
+ }
6
+ export interface HSB {
7
+ h: number;
8
+ s: number;
9
+ b: number;
10
+ }
11
+ export interface HSV extends HSB {
12
+ }
13
+ export declare function clamp(value: number, min: number, max: number): number;
14
+ export declare function round(value: number, precision?: number): number;
15
+ export declare function hexToRgb(hex: string): RGB | null;
16
+ export declare function rgbToHex(rgb: RGB): string;
17
+ export declare function rgbToHsb(rgb: RGB): HSB;
18
+ export declare function hsbToRgb(hsb: HSB): RGB;
19
+ export declare function rgbToHsvString(rgb: RGB): string;
20
+ export declare function hsbToHsvString(hsb: HSB): string;
21
+ export declare function isValidHex(value: string): boolean;
22
+ export declare function normalizeHex(value: string): string;
23
+ //# sourceMappingURL=colorUtils.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"colorUtils.d.ts","sourceRoot":"","sources":["../../../src/components/ColorPicker/colorUtils.ts"],"names":[],"mappings":"AAAA,MAAM,WAAW,GAAG;IAClB,CAAC,EAAE,MAAM,CAAA;IACT,CAAC,EAAE,MAAM,CAAA;IACT,CAAC,EAAE,MAAM,CAAA;CACV;AAED,MAAM,WAAW,GAAG;IAClB,CAAC,EAAE,MAAM,CAAA;IACT,CAAC,EAAE,MAAM,CAAA;IACT,CAAC,EAAE,MAAM,CAAA;CACV;AAED,MAAM,WAAW,GAAI,SAAQ,GAAG;CAAG;AAEnC,wBAAgB,KAAK,CAAC,KAAK,EAAE,MAAM,EAAE,GAAG,EAAE,MAAM,EAAE,GAAG,EAAE,MAAM,GAAG,MAAM,CAErE;AAED,wBAAgB,KAAK,CAAC,KAAK,EAAE,MAAM,EAAE,SAAS,SAAI,GAAG,MAAM,CAG1D;AAED,wBAAgB,QAAQ,CAAC,GAAG,EAAE,MAAM,GAAG,GAAG,GAAG,IAAI,CAQhD;AAED,wBAAgB,QAAQ,CAAC,GAAG,EAAE,GAAG,GAAG,MAAM,CAGzC;AAED,wBAAgB,QAAQ,CAAC,GAAG,EAAE,GAAG,GAAG,GAAG,CAetC;AAED,wBAAgB,QAAQ,CAAC,GAAG,EAAE,GAAG,GAAG,GAAG,CAmBtC;AAED,wBAAgB,cAAc,CAAC,GAAG,EAAE,GAAG,GAAG,MAAM,CAE/C;AAED,wBAAgB,cAAc,CAAC,GAAG,EAAE,GAAG,GAAG,MAAM,CAE/C;AAED,wBAAgB,UAAU,CAAC,KAAK,EAAE,MAAM,GAAG,OAAO,CAEjD;AAED,wBAAgB,YAAY,CAAC,KAAK,EAAE,MAAM,GAAG,MAAM,CAKlD"}
@@ -0,0 +1,9 @@
1
+ import { GradientStop, GradientValue } from './types';
2
+ export declare function createStopId(): string;
3
+ export declare function isGradient(value: string): boolean;
4
+ export declare function parseGradient(value: string): GradientValue | null;
5
+ export declare function gradientToString(gradient: GradientValue): string;
6
+ export declare function normalizeColor(color: string): string;
7
+ export declare function createDefaultGradient(): GradientValue;
8
+ export declare function stopsToGradientPreview(stops: GradientStop[]): string;
9
+ //# sourceMappingURL=gradientUtils.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"gradientUtils.d.ts","sourceRoot":"","sources":["../../../src/components/ColorPicker/gradientUtils.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,YAAY,EAAE,aAAa,EAAE,MAAM,SAAS,CAAA;AAI1D,wBAAgB,YAAY,IAAI,MAAM,CAErC;AAED,wBAAgB,UAAU,CAAC,KAAK,EAAE,MAAM,GAAG,OAAO,CAEjD;AAED,wBAAgB,aAAa,CAAC,KAAK,EAAE,MAAM,GAAG,aAAa,GAAG,IAAI,CA2FjE;AAED,wBAAgB,gBAAgB,CAAC,QAAQ,EAAE,aAAa,GAAG,MAAM,CAShE;AAED,wBAAgB,cAAc,CAAC,KAAK,EAAE,MAAM,GAAG,MAAM,CAmBpD;AAED,wBAAgB,qBAAqB,IAAI,aAAa,CASrD;AAED,wBAAgB,sBAAsB,CAAC,KAAK,EAAE,YAAY,EAAE,GAAG,MAAM,CAGpE"}
@@ -0,0 +1,3 @@
1
+ export { default as MColorPicker } from './ColorPicker.vue';
2
+ export type { ColorPickerEmits, ColorPickerFormat, ColorPickerMode, ColorPickerPreset, ColorPickerProps, GradientStop, GradientType, GradientValue, } from './types';
3
+ //# sourceMappingURL=index.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/components/ColorPicker/index.ts"],"names":[],"mappings":"AAAA,OAAO,SAAS,CAAA;AAChB,OAAO,EAAE,OAAO,IAAI,YAAY,EAAE,MAAM,mBAAmB,CAAA;AAC3D,YAAY,EACV,gBAAgB,EAChB,iBAAiB,EACjB,eAAe,EACf,iBAAiB,EACjB,gBAAgB,EAChB,YAAY,EACZ,YAAY,EACZ,aAAa,GACd,MAAM,SAAS,CAAA"}