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.
- package/CHANGELOG.md +41 -2
- package/dist/{Input-D2bee2LU.js → Input-BErawS7K.js} +1 -5
- package/dist/InputNumber-DjbXtTzR.js +245 -0
- package/dist/{Pagination-DpNOb0CS.js → Pagination-B8WYoL2a.js} +1 -1
- package/dist/{Popover-Bnz7KNZq.js → Popover-zQChu00_.js} +6 -1
- package/dist/{Select-q4X2ff_M.js → Select-BaFKBeIh.js} +2 -2
- package/dist/{Textarea-DsFOAtPd.js → Textarea-WCEgpzbq.js} +1 -5
- package/dist/accordion/style.css +6 -15
- package/dist/affix/style.css +6 -15
- package/dist/alert/style.css +6 -15
- package/dist/anchor/style.css +6 -15
- package/dist/auto-complete/style.css +6 -15
- package/dist/avatar/style.css +6 -15
- package/dist/badge/style.css +6 -15
- package/dist/block-ui/style.css +6 -15
- package/dist/breadcrumb/style.css +6 -15
- package/dist/button/style.css +6 -15
- package/dist/calendar/index.js +1 -1
- package/dist/calendar/style.css +6 -15
- package/dist/card/style.css +6 -15
- package/dist/carousel/style.css +6 -15
- package/dist/cascade-select/style.css +6 -15
- package/dist/checkbox/style.css +6 -15
- package/dist/chip/style.css +6 -15
- package/dist/color-picker/index.js +676 -0
- package/dist/{input-color → color-picker}/style.css +1406 -83
- package/dist/color-picker/style.js +8 -0
- package/dist/command-menu/index.js +73 -66
- package/dist/command-menu/style.css +6 -15
- package/dist/components/ColorPicker/ColorPicker.vue.d.ts +41 -0
- package/dist/components/ColorPicker/ColorPicker.vue.d.ts.map +1 -0
- package/dist/components/ColorPicker/colorUtils.d.ts +23 -0
- package/dist/components/ColorPicker/colorUtils.d.ts.map +1 -0
- package/dist/components/ColorPicker/gradientUtils.d.ts +9 -0
- package/dist/components/ColorPicker/gradientUtils.d.ts.map +1 -0
- package/dist/components/ColorPicker/index.d.ts +3 -0
- package/dist/components/ColorPicker/index.d.ts.map +1 -0
- package/dist/components/ColorPicker/styles.css +405 -0
- package/dist/components/ColorPicker/types.d.ts +60 -0
- package/dist/components/ColorPicker/types.d.ts.map +1 -0
- package/dist/components/CommandMenu/CommandMenu.vue.d.ts.map +1 -1
- package/dist/components/ContextMenu/ContextMenuNodes.vue.d.ts.map +1 -1
- package/dist/components/ContextMenu/styles.css +1 -1
- package/dist/components/Dock/Dock.vue.d.ts.map +1 -1
- package/dist/components/Dropdown/DropdownNodes.vue.d.ts.map +1 -1
- package/dist/components/Dropdown/styles.css +1 -1
- package/dist/components/Input/Input.vue.d.ts +0 -1
- package/dist/components/Input/Input.vue.d.ts.map +1 -1
- package/dist/components/Input/types.d.ts +0 -2
- package/dist/components/Input/types.d.ts.map +1 -1
- package/dist/components/InputNumber/styles.css +28 -10
- package/dist/components/InputPassword/InputPassword.vue.d.ts +0 -1
- package/dist/components/InputPassword/InputPassword.vue.d.ts.map +1 -1
- package/dist/components/InputPassword/types.d.ts +0 -2
- package/dist/components/InputPassword/types.d.ts.map +1 -1
- package/dist/components/MegaMenu/MegaMenu.vue.d.ts.map +1 -1
- package/dist/components/Mentions/Mentions.vue.d.ts +0 -1
- package/dist/components/Mentions/Mentions.vue.d.ts.map +1 -1
- package/dist/components/Mentions/types.d.ts +0 -2
- package/dist/components/Mentions/types.d.ts.map +1 -1
- package/dist/components/Menu/Menu.vue.d.ts.map +1 -1
- package/dist/components/Menu/MenuNodes.vue.d.ts.map +1 -1
- package/dist/components/Menu/styles.css +45 -3
- package/dist/components/Menu/types.d.ts +3 -1
- package/dist/components/Menu/types.d.ts.map +1 -1
- package/dist/components/Menubar/Menubar.vue.d.ts +2 -2
- package/dist/components/Menubar/Menubar.vue.d.ts.map +1 -1
- package/dist/components/Menubar/styles.css +1 -1
- package/dist/components/Popover/Popover.vue.d.ts.map +1 -1
- package/dist/components/Rating/Rating.vue.d.ts +1 -1
- package/dist/components/Rating/types.d.ts +2 -2
- package/dist/components/Rating/types.d.ts.map +1 -1
- package/dist/components/Select/Select.vue.d.ts +1 -1
- package/dist/components/Select/types.d.ts +1 -1
- package/dist/components/Select/types.d.ts.map +1 -1
- package/dist/components/Sidebar/Sidebar.vue.d.ts.map +1 -1
- package/dist/components/SpeedDial/SpeedDial.vue.d.ts +3 -3
- package/dist/components/SpeedDial/SpeedDial.vue.d.ts.map +1 -1
- package/dist/components/SplitButton/SplitButton.vue.d.ts.map +1 -1
- package/dist/components/Textarea/Textarea.vue.d.ts +0 -1
- package/dist/components/Textarea/Textarea.vue.d.ts.map +1 -1
- package/dist/components/Textarea/types.d.ts +0 -2
- package/dist/components/Textarea/types.d.ts.map +1 -1
- package/dist/components/TieredMenu/styles.css +2 -2
- package/dist/components/Tooltip/styles.css +15 -2
- package/dist/config-provider/style.css +6 -15
- package/dist/confirm-dialog/style.css +6 -15
- package/dist/confirm-popup/style.css +6 -15
- package/dist/context-menu/index.js +92 -84
- package/dist/context-menu/style.css +7 -16
- package/dist/data-view/index.js +1 -1
- package/dist/data-view/style.css +6 -15
- package/dist/date-picker/style.css +6 -15
- package/dist/descriptions/style.css +6 -15
- package/dist/dialog/style.css +6 -15
- package/dist/divider/style.css +6 -15
- package/dist/dock/index.js +21 -18
- package/dist/dock/style.css +6 -15
- package/dist/drawer/style.css +6 -15
- package/dist/dropdown/index.js +103 -95
- package/dist/dropdown/style.css +7 -16
- package/dist/empty/style.css +6 -15
- package/dist/fieldset/style.css +6 -15
- package/dist/file-upload/style.css +6 -15
- package/dist/flex/style.css +6 -15
- package/dist/float-label/style.css +6 -15
- package/dist/fluid/style.css +6 -15
- package/dist/form/style.css +6 -15
- package/dist/gallery/style.css +6 -15
- package/dist/grid/style.css +6 -15
- package/dist/icon/style.css +6 -15
- package/dist/{icon-H8prbteT.js → icon-CUrSaD8r.js} +4 -1
- package/dist/icon-field/style.css +6 -15
- package/dist/image/style.css +6 -15
- package/dist/index.d.ts +2 -2
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js +4047 -3420
- package/dist/inplace/style.css +6 -15
- package/dist/input/index.js +1 -1
- package/dist/input/style.css +6 -15
- package/dist/input-group/style.css +6 -15
- package/dist/input-number/index.js +2 -245
- package/dist/input-number/style.css +34 -25
- package/dist/input-otp/style.css +6 -15
- package/dist/input-password/index.js +1 -5
- package/dist/input-password/style.css +6 -15
- package/dist/input-tags/style.css +6 -15
- package/dist/knob/style.css +6 -15
- package/dist/label/style.css +6 -15
- package/dist/layout/style.css +6 -15
- package/dist/list/index.js +1 -1
- package/dist/list/style.css +6 -15
- package/dist/listbox/style.css +6 -15
- package/dist/loading/style.css +6 -15
- package/dist/mega-menu/index.js +94 -87
- package/dist/mega-menu/style.css +6 -15
- package/dist/mentions/index.js +35 -39
- package/dist/mentions/style.css +6 -15
- package/dist/menu/index.js +235 -213
- package/dist/menu/style.css +66 -20
- package/dist/menubar/index.js +107 -99
- package/dist/menubar/style.css +7 -16
- package/dist/message/style.css +6 -15
- package/dist/meter-group/style.css +6 -15
- package/dist/order-list/style.css +6 -15
- package/dist/page/style.css +6 -15
- package/dist/pagination/index.js +1 -1
- package/dist/pagination/style.css +6 -15
- package/dist/panel/style.css +6 -15
- package/dist/pick-list/style.css +6 -15
- package/dist/popover/index.js +1 -1
- package/dist/popover/style.css +6 -15
- package/dist/progress-bar/style.css +6 -15
- package/dist/progress-spinner/style.css +6 -15
- package/dist/qr-code/style.css +6 -15
- package/dist/radio/style.css +6 -15
- package/dist/rating/index.js +2 -2
- package/dist/rating/style.css +6 -15
- package/dist/resolver.js +1 -1
- package/dist/result/style.css +6 -15
- package/dist/scroll-top/style.css +6 -15
- package/dist/scrollbar/style.css +6 -15
- package/dist/segmented/style.css +6 -15
- package/dist/select/index.js +1 -1
- package/dist/select/style.css +6 -15
- package/dist/select-button/style.css +6 -15
- package/dist/shared/menu/icon.d.ts +3 -0
- package/dist/shared/menu/icon.d.ts.map +1 -1
- package/dist/shared/menu/index.d.ts +2 -2
- package/dist/shared/menu/index.d.ts.map +1 -1
- package/dist/shared/menu/types.d.ts +3 -1
- package/dist/shared/menu/types.d.ts.map +1 -1
- package/dist/sidebar/index.js +37 -29
- package/dist/sidebar/style.css +6 -15
- package/dist/skeleton/style.css +6 -15
- package/dist/slider/style.css +6 -15
- package/dist/space/style.css +6 -15
- package/dist/speed-dial/index.js +101 -94
- package/dist/speed-dial/style.css +6 -15
- package/dist/split-button/index.js +3 -3
- package/dist/split-button/style.css +6 -15
- package/dist/splitter/style.css +6 -15
- package/dist/statistic/style.css +6 -15
- package/dist/status/style.css +6 -15
- package/dist/stepper/style.css +6 -15
- package/dist/styles/base.css +6 -15
- package/dist/styles.css +1 -1
- package/dist/switch/style.css +6 -15
- package/dist/table/index.js +3 -3
- package/dist/table/style.css +6 -15
- package/dist/tabs/style.css +6 -15
- package/dist/tag/style.css +6 -15
- package/dist/terminal/style.css +6 -15
- package/dist/textarea/index.js +1 -1
- package/dist/textarea/style.css +6 -15
- package/dist/tiered-menu/style.css +8 -17
- package/dist/time-picker/style.css +6 -15
- package/dist/timeline/style.css +6 -15
- package/dist/toast/style.css +6 -15
- package/dist/toggle-button/index.js +1 -1
- package/dist/toggle-button/style.css +6 -15
- package/dist/toolbar/style.css +6 -15
- package/dist/tooltip/style.css +21 -17
- package/dist/tour/style.css +6 -15
- package/dist/tree/style.css +6 -15
- package/dist/tree-select/style.css +6 -15
- package/dist/typography/index.js +1 -1
- package/dist/typography/style.css +6 -15
- package/dist/virtual-scroller/style.css +6 -15
- package/dist/watermark/style.css +6 -15
- package/package.json +8 -8
- package/dist/components/InputColor/InputColor.vue.d.ts +0 -24
- package/dist/components/InputColor/InputColor.vue.d.ts.map +0 -1
- package/dist/components/InputColor/index.d.ts +0 -3
- package/dist/components/InputColor/index.d.ts.map +0 -1
- package/dist/components/InputColor/styles.css +0 -139
- package/dist/components/InputColor/types.d.ts +0 -19
- package/dist/components/InputColor/types.d.ts.map +0 -1
- package/dist/input-color/index.js +0 -118
- 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
|
|
4
|
-
import { t as
|
|
5
|
-
import { t as
|
|
6
|
-
import { t as
|
|
7
|
-
import { t as
|
|
8
|
-
import { t as
|
|
9
|
-
import { l as
|
|
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
|
|
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
|
|
14
|
+
var D = ["aria-label"], O = ["placeholder", "aria-label"], k = [
|
|
15
15
|
"aria-selected",
|
|
16
16
|
"disabled",
|
|
17
17
|
"onClick",
|
|
18
18
|
"onMouseenter"
|
|
19
|
-
],
|
|
19
|
+
], A = {
|
|
20
20
|
key: 0,
|
|
21
21
|
class: "m-commandmenu__icon",
|
|
22
22
|
"aria-hidden": "true"
|
|
23
|
-
},
|
|
23
|
+
}, j = { class: "m-commandmenu__label" }, M = {
|
|
24
24
|
key: 1,
|
|
25
25
|
class: "m-commandmenu__shortcut"
|
|
26
|
-
},
|
|
26
|
+
}, N = {
|
|
27
27
|
key: 0,
|
|
28
28
|
class: "m-commandmenu__empty"
|
|
29
|
-
},
|
|
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(
|
|
52
|
-
let
|
|
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: () =>
|
|
54
|
+
local: () => F.transition,
|
|
55
55
|
componentName: "CommandMenu",
|
|
56
56
|
fallback: "fade"
|
|
57
|
-
}),
|
|
58
|
-
function
|
|
59
|
-
|
|
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.
|
|
65
|
+
return typeof e.icon == "string" ? o(e.icon) : void 0;
|
|
63
66
|
}
|
|
64
67
|
function $(e) {
|
|
65
|
-
return
|
|
68
|
+
return a(e.icon);
|
|
69
|
+
}
|
|
70
|
+
function ue(e) {
|
|
71
|
+
return !!(Q(e) || $(e));
|
|
66
72
|
}
|
|
67
|
-
function
|
|
68
|
-
if (e.key === "ArrowDown" && (e.preventDefault(),
|
|
69
|
-
let t =
|
|
70
|
-
t && (e.preventDefault(),
|
|
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
|
|
74
|
-
open:
|
|
75
|
-
container:
|
|
79
|
+
return te({
|
|
80
|
+
open: y(F, "modelValue"),
|
|
81
|
+
container: G,
|
|
76
82
|
blockScroll: !0,
|
|
77
83
|
autoFocus: !1,
|
|
78
|
-
onEscape:
|
|
84
|
+
onEscape: X,
|
|
79
85
|
onOpen: () => {
|
|
80
|
-
|
|
86
|
+
W.value = "", q.value = 0;
|
|
81
87
|
}
|
|
82
|
-
}),
|
|
83
|
-
e && (await
|
|
84
|
-
}),
|
|
85
|
-
|
|
86
|
-
}), (e, t) => (
|
|
87
|
-
to:
|
|
88
|
-
disabled:
|
|
89
|
-
}, [
|
|
90
|
-
name:
|
|
91
|
-
css:
|
|
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:
|
|
99
|
+
default: w(() => [h.modelValue ? (g(), f("div", ae({ key: 0 }, b(R), {
|
|
94
100
|
class: "m-commandmenu-backdrop",
|
|
95
|
-
onClick:
|
|
96
|
-
}), [
|
|
101
|
+
onClick: E(X, ["self"])
|
|
102
|
+
}), [p("div", {
|
|
97
103
|
ref_key: "panelRef",
|
|
98
|
-
ref:
|
|
104
|
+
ref: G,
|
|
99
105
|
class: "m-commandmenu",
|
|
100
106
|
role: "dialog",
|
|
101
107
|
"aria-modal": "true",
|
|
102
|
-
"aria-label":
|
|
108
|
+
"aria-label": b(H).commandPalette,
|
|
103
109
|
tabindex: "-1",
|
|
104
|
-
onKeydown:
|
|
105
|
-
}, [
|
|
110
|
+
onKeydown: de
|
|
111
|
+
}, [T(p("input", {
|
|
106
112
|
ref_key: "inputRef",
|
|
107
|
-
ref:
|
|
108
|
-
"onUpdate:modelValue": t[0] ||= (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:
|
|
112
|
-
"aria-label":
|
|
113
|
-
}, null, 8,
|
|
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:
|
|
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
|
-
}, [
|
|
129
|
+
}, [p("button", {
|
|
124
130
|
type: "button",
|
|
125
|
-
class:
|
|
131
|
+
class: se(["m-commandmenu__item", { "m-commandmenu__item--active": t === q.value }]),
|
|
126
132
|
role: "option",
|
|
127
|
-
"aria-selected": t ===
|
|
133
|
+
"aria-selected": t === q.value,
|
|
128
134
|
disabled: e.disabled,
|
|
129
|
-
onClick: (t) =>
|
|
130
|
-
onMouseenter: (e) =>
|
|
135
|
+
onClick: (t) => Z(e),
|
|
136
|
+
onMouseenter: (e) => q.value = t
|
|
131
137
|
}, [
|
|
132
|
-
|
|
133
|
-
|
|
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"])])) :
|
|
136
|
-
|
|
137
|
-
e.shortcut ? (
|
|
138
|
-
], 42,
|
|
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,
|
|
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 {
|
|
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-
|
|
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-
|
|
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 @@
|
|
|
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"}
|