@quidgest/ui 0.16.46 → 0.16.47
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/json/api.json +23 -1
- package/dist/ui.css +5 -4
- package/dist/ui.esm.js +14 -10
- package/dist/ui.js +12 -12
- package/dist/ui.min.css +1 -1
- package/dist/ui.min.js +7 -7
- package/dist/ui.scss +5 -5
- package/esm/components/QCheckbox/QCheckbox.d.ts +1 -0
- package/esm/components/QCheckbox/QCheckbox.d.ts.map +1 -1
- package/esm/components/QCheckbox/QCheckbox.vue.js +25 -23
- package/esm/components/QCheckbox/index.d.ts +6 -0
- package/esm/components/QCheckbox/index.d.ts.map +1 -1
- package/esm/components/QCheckbox/types.d.ts +6 -0
- package/esm/components/QCheckbox/types.d.ts.map +1 -1
- package/esm/components/QOverlay/QOverlay.d.ts.map +1 -1
- package/esm/components/QOverlay/QOverlay.vue.js +40 -40
- package/esm/components/QRadioGroup/QRadioGroup.d.ts +1 -0
- package/esm/components/QRadioGroup/QRadioGroup.d.ts.map +1 -1
- package/esm/components/QRadioGroup/QRadioGroup.vue.js +21 -19
- package/esm/components/QRadioGroup/index.d.ts +6 -0
- package/esm/components/QRadioGroup/index.d.ts.map +1 -1
- package/esm/components/QRadioGroup/types.d.ts +6 -0
- package/esm/components/QRadioGroup/types.d.ts.map +1 -1
- package/esm/symbols/dismissibleLayer.d.ts.map +1 -1
- package/esm/symbols/dismissibleLayer.js +1 -1
- package/package.json +1 -1
package/dist/ui.scss
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
/*!
|
|
2
|
-
* Quidgest UI v0.16.
|
|
2
|
+
* Quidgest UI v0.16.47
|
|
3
3
|
* (c) 2025 Quidgest - Consultores de Gestão, S.A.
|
|
4
4
|
* Released under the MIT License.
|
|
5
5
|
*/
|
|
@@ -1205,7 +1205,7 @@ $q-carousel-height-md: 300px;
|
|
|
1205
1205
|
width: fit-content;
|
|
1206
1206
|
color: var(--q-theme-neutral-dark);
|
|
1207
1207
|
cursor: pointer;
|
|
1208
|
-
|
|
1208
|
+
&--focus-style:focus-within {
|
|
1209
1209
|
outline: $outline;
|
|
1210
1210
|
}
|
|
1211
1211
|
label {
|
|
@@ -2639,9 +2639,6 @@ $base-border: 1px solid rgb(var(--q-theme-neutral-light-rgb) / 50%);
|
|
|
2639
2639
|
align-items: center;
|
|
2640
2640
|
gap: 0.5em;
|
|
2641
2641
|
cursor: pointer;
|
|
2642
|
-
&:focus-within {
|
|
2643
|
-
outline: $outline;
|
|
2644
|
-
}
|
|
2645
2642
|
label {
|
|
2646
2643
|
line-height: 1;
|
|
2647
2644
|
cursor: pointer;
|
|
@@ -2743,6 +2740,9 @@ $base-border: 1px solid rgb(var(--q-theme-neutral-light-rgb) / 50%);
|
|
|
2743
2740
|
padding: 0.625rem;
|
|
2744
2741
|
}
|
|
2745
2742
|
}
|
|
2743
|
+
.q-radio-group--focus-style .q-radio-button:focus-within {
|
|
2744
|
+
outline: $outline;
|
|
2745
|
+
}
|
|
2746
2746
|
.q-select {
|
|
2747
2747
|
$this: &;
|
|
2748
2748
|
&:not(#{$this}--readonly):not(#{$this}--disabled) {
|
|
@@ -26,6 +26,7 @@ declare const __VLS_component: import('vue').DefineComponent<__VLS_PublicProps,
|
|
|
26
26
|
color: string;
|
|
27
27
|
icons: typeof DEFAULT_ICONS;
|
|
28
28
|
labelPlacement: import('./types').QCheckboxLabelPlacement;
|
|
29
|
+
hasFocusOutline: boolean;
|
|
29
30
|
}, {}, {}, {}, string, import('vue').ComponentProvideOptions, false, {
|
|
30
31
|
inputEl: HTMLInputElement;
|
|
31
32
|
buttonEl: HTMLButtonElement;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"QCheckbox.vue.d.ts","sourceRoot":"","sources":["../../../src/components/QCheckbox/QCheckbox.vue"],"names":[],"mappings":"AA8DA;
|
|
1
|
+
{"version":3,"file":"QCheckbox.vue.d.ts","sourceRoot":"","sources":["../../../src/components/QCheckbox/QCheckbox.vue"],"names":[],"mappings":"AA8DA;AA4IC,OAAO,EAAE,aAAa,EAAE,MAAM,aAAa,CAAA;AAU3C,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,SAAS,CAAA;AAK7C,KAAK,WAAW,GAAG,cAAc,CAAC;AAoEnC,KAAK,iBAAiB,GAAG;IACzB,UAAU,CAAC,EAAE,OAAO,CAAC;CACpB,GAAG,WAAW,CAAC;AAKhB,iBAAS,cAAc;WAuHT,OAAO,IAA6B;;wBAdtB,GAAG;wBACF,GAAG;;;;;;;EAkB/B;AAiBD,KAAK,oBAAoB,GAAG,UAAU,CAAC,OAAO,cAAc,CAAC,CAAC;AAC9D,QAAA,MAAM,eAAe;;;;;;;;;;;;;OASnB,CAAC;wBACkB,uBAAuB,CAAC,OAAO,eAAe,EAAE,oBAAoB,CAAC,OAAO,CAAC,CAAC;AAAnG,wBAAoG;AAapG,KAAK,uBAAuB,CAAC,CAAC,EAAE,CAAC,IAAI,CAAC,GAAG;IACxC,QAAO;QACN,MAAM,EAAE,CAAC,CAAC;KAEV,CAAA;CACD,CAAC"}
|
|
@@ -1,12 +1,12 @@
|
|
|
1
|
-
import { defineComponent as
|
|
1
|
+
import { defineComponent as E, mergeModels as _, useModel as g, toRef as w, useTemplateRef as f, computed as $, watch as M, createElementBlock as V, openBlock as r, withModifiers as a, normalizeClass as P, createBlock as s, createCommentVNode as n, createElementVNode as m, unref as l, createSlots as p, withCtx as h, renderSlot as k, mergeProps as y, withKeys as v } from "vue";
|
|
2
2
|
import { DEFAULT_ICONS as R } from "./constants.js";
|
|
3
3
|
import { QIcon as z } from "../QIcon/index.js";
|
|
4
4
|
import { QCheckboxLabel as q } from "./index.js";
|
|
5
|
-
import { useId as
|
|
6
|
-
const
|
|
5
|
+
import { useId as F } from "../../composables/uid.js";
|
|
6
|
+
const I = ["checked", "disabled", "required", "aria-readonly"], K = ["id", "aria-checked", "disabled", "onKeydown"], L = /* @__PURE__ */ E({
|
|
7
7
|
inheritAttrs: !1,
|
|
8
8
|
__name: "QCheckbox",
|
|
9
|
-
props: /* @__PURE__ */
|
|
9
|
+
props: /* @__PURE__ */ _({
|
|
10
10
|
id: {},
|
|
11
11
|
class: {},
|
|
12
12
|
label: {},
|
|
@@ -18,14 +18,15 @@ const K = ["checked", "disabled", "required", "aria-readonly"], N = ["id", "aria
|
|
|
18
18
|
disabled: { type: Boolean },
|
|
19
19
|
readonly: { type: Boolean },
|
|
20
20
|
indeterminate: { type: Boolean },
|
|
21
|
-
icons: { default: () => R }
|
|
21
|
+
icons: { default: () => R },
|
|
22
|
+
hasFocusOutline: { type: Boolean, default: !0 }
|
|
22
23
|
}, {
|
|
23
24
|
modelValue: { type: Boolean },
|
|
24
25
|
modelModifiers: {}
|
|
25
26
|
}),
|
|
26
27
|
emits: ["update:modelValue"],
|
|
27
28
|
setup(c) {
|
|
28
|
-
const e = c, t =
|
|
29
|
+
const e = c, t = g(c, "modelValue"), i = F(w(e, "id")), u = f("inputEl"), x = f("buttonEl"), C = $(() => [
|
|
29
30
|
"q-checkbox",
|
|
30
31
|
`q-checkbox--${e.size}`,
|
|
31
32
|
`q-checkbox--${e.color}`,
|
|
@@ -33,28 +34,29 @@ const K = ["checked", "disabled", "required", "aria-readonly"], N = ["id", "aria
|
|
|
33
34
|
"q-checkbox--readonly": e.readonly,
|
|
34
35
|
"q-checkbox--disabled": e.disabled,
|
|
35
36
|
"q-checkbox--checked": t.value,
|
|
36
|
-
"q-checkbox--indeterminate": e.indeterminate
|
|
37
|
+
"q-checkbox--indeterminate": e.indeterminate,
|
|
38
|
+
"q-checkbox--focus-style": e.hasFocusOutline
|
|
37
39
|
},
|
|
38
40
|
e.class
|
|
39
41
|
]);
|
|
40
42
|
function d() {
|
|
41
43
|
!e.disabled && !e.readonly && (t.value = !t.value);
|
|
42
44
|
}
|
|
43
|
-
function
|
|
45
|
+
function B() {
|
|
44
46
|
var o;
|
|
45
47
|
(o = x.value) == null || o.focus();
|
|
46
48
|
}
|
|
47
49
|
return M(t, (o) => {
|
|
48
50
|
u.value && (u.value.checked = !!o);
|
|
49
|
-
}), (o, b) => (
|
|
51
|
+
}), (o, b) => (r(), V(
|
|
50
52
|
"div",
|
|
51
53
|
{
|
|
52
54
|
class: P(C.value),
|
|
53
55
|
onClick: a(d, ["prevent"]),
|
|
54
|
-
onMousedown: a(
|
|
56
|
+
onMousedown: a(B, ["prevent"])
|
|
55
57
|
},
|
|
56
58
|
[
|
|
57
|
-
e.label && e.labelPlacement !== "right" ? (
|
|
59
|
+
e.label && e.labelPlacement !== "right" ? (r(), s(l(q), {
|
|
58
60
|
key: 0,
|
|
59
61
|
for: l(i),
|
|
60
62
|
label: e.label,
|
|
@@ -70,9 +72,9 @@ const K = ["checked", "disabled", "required", "aria-readonly"], N = ["id", "aria
|
|
|
70
72
|
]),
|
|
71
73
|
key: "0"
|
|
72
74
|
} : void 0
|
|
73
|
-
]), 1032, ["for", "label", "required"])) :
|
|
74
|
-
|
|
75
|
-
|
|
75
|
+
]), 1032, ["for", "label", "required"])) : n("v-if", !0),
|
|
76
|
+
n(" Hidden native input for form submission "),
|
|
77
|
+
m("input", {
|
|
76
78
|
ref: "inputEl",
|
|
77
79
|
type: "checkbox",
|
|
78
80
|
class: "q-checkbox__native-input",
|
|
@@ -82,9 +84,9 @@ const K = ["checked", "disabled", "required", "aria-readonly"], N = ["id", "aria
|
|
|
82
84
|
"aria-readonly": e.readonly,
|
|
83
85
|
tabindex: "-1",
|
|
84
86
|
"aria-hidden": "true"
|
|
85
|
-
}, null, 8,
|
|
86
|
-
|
|
87
|
-
|
|
87
|
+
}, null, 8, I),
|
|
88
|
+
n(" Custom interactive button "),
|
|
89
|
+
m("button", y({
|
|
88
90
|
id: l(i),
|
|
89
91
|
ref: "buttonEl",
|
|
90
92
|
role: "checkbox",
|
|
@@ -101,15 +103,15 @@ const K = ["checked", "disabled", "required", "aria-readonly"], N = ["id", "aria
|
|
|
101
103
|
}, ["prevent"]), ["enter"]))
|
|
102
104
|
]
|
|
103
105
|
}), [
|
|
104
|
-
t.value || o.indeterminate ? (
|
|
106
|
+
t.value || o.indeterminate ? (r(), s(
|
|
105
107
|
l(z),
|
|
106
108
|
y({ key: 0 }, t.value ? e.icons.checked : e.icons.indeterminate, { class: "q-checkbox__input-icon" }),
|
|
107
109
|
null,
|
|
108
110
|
16
|
|
109
111
|
/* FULL_PROPS */
|
|
110
|
-
)) :
|
|
111
|
-
], 16,
|
|
112
|
-
e.label && e.labelPlacement === "right" ? (
|
|
112
|
+
)) : n("v-if", !0)
|
|
113
|
+
], 16, K),
|
|
114
|
+
e.label && e.labelPlacement === "right" ? (r(), s(l(q), {
|
|
113
115
|
key: 1,
|
|
114
116
|
for: l(i),
|
|
115
117
|
label: e.label,
|
|
@@ -125,7 +127,7 @@ const K = ["checked", "disabled", "required", "aria-readonly"], N = ["id", "aria
|
|
|
125
127
|
]),
|
|
126
128
|
key: "0"
|
|
127
129
|
} : void 0
|
|
128
|
-
]), 1032, ["for", "label", "required"])) :
|
|
130
|
+
]), 1032, ["for", "label", "required"])) : n("v-if", !0)
|
|
129
131
|
],
|
|
130
132
|
34
|
|
131
133
|
/* CLASS, NEED_HYDRATION */
|
|
@@ -133,5 +135,5 @@ const K = ["checked", "disabled", "required", "aria-readonly"], N = ["id", "aria
|
|
|
133
135
|
}
|
|
134
136
|
});
|
|
135
137
|
export {
|
|
136
|
-
|
|
138
|
+
L as default
|
|
137
139
|
};
|
|
@@ -13,6 +13,7 @@ declare const QCheckbox: {
|
|
|
13
13
|
readonly?: boolean;
|
|
14
14
|
indeterminate?: boolean;
|
|
15
15
|
icons?: typeof import('./constants').DEFAULT_ICONS;
|
|
16
|
+
hasFocusOutline?: boolean;
|
|
16
17
|
}> & Readonly<{
|
|
17
18
|
"onUpdate:modelValue"?: ((value: boolean) => any) | undefined;
|
|
18
19
|
}>, {}, {}, {}, {}, import('vue').ComponentOptionsMixin, import('vue').ComponentOptionsMixin, {
|
|
@@ -22,6 +23,7 @@ declare const QCheckbox: {
|
|
|
22
23
|
color: string;
|
|
23
24
|
icons: typeof import('./constants').DEFAULT_ICONS;
|
|
24
25
|
labelPlacement: import('./types').QCheckboxLabelPlacement;
|
|
26
|
+
hasFocusOutline: boolean;
|
|
25
27
|
}, false, {}, {}, import('vue').GlobalComponents, import('vue').GlobalDirectives, string, {
|
|
26
28
|
inputEl: HTMLInputElement;
|
|
27
29
|
buttonEl: HTMLButtonElement;
|
|
@@ -46,6 +48,7 @@ declare const QCheckbox: {
|
|
|
46
48
|
readonly?: boolean;
|
|
47
49
|
indeterminate?: boolean;
|
|
48
50
|
icons?: typeof import('./constants').DEFAULT_ICONS;
|
|
51
|
+
hasFocusOutline?: boolean;
|
|
49
52
|
}> & Readonly<{
|
|
50
53
|
"onUpdate:modelValue"?: ((value: boolean) => any) | undefined;
|
|
51
54
|
}>, {}, {}, {}, {}, {
|
|
@@ -53,6 +56,7 @@ declare const QCheckbox: {
|
|
|
53
56
|
color: string;
|
|
54
57
|
icons: typeof import('./constants').DEFAULT_ICONS;
|
|
55
58
|
labelPlacement: import('./types').QCheckboxLabelPlacement;
|
|
59
|
+
hasFocusOutline: boolean;
|
|
56
60
|
}>;
|
|
57
61
|
__isFragment?: never;
|
|
58
62
|
__isTeleport?: never;
|
|
@@ -71,6 +75,7 @@ declare const QCheckbox: {
|
|
|
71
75
|
readonly?: boolean;
|
|
72
76
|
indeterminate?: boolean;
|
|
73
77
|
icons?: typeof import('./constants').DEFAULT_ICONS;
|
|
78
|
+
hasFocusOutline?: boolean;
|
|
74
79
|
}> & Readonly<{
|
|
75
80
|
"onUpdate:modelValue"?: ((value: boolean) => any) | undefined;
|
|
76
81
|
}>, {}, {}, {}, {}, import('vue').ComponentOptionsMixin, import('vue').ComponentOptionsMixin, {
|
|
@@ -80,6 +85,7 @@ declare const QCheckbox: {
|
|
|
80
85
|
color: string;
|
|
81
86
|
icons: typeof import('./constants').DEFAULT_ICONS;
|
|
82
87
|
labelPlacement: import('./types').QCheckboxLabelPlacement;
|
|
88
|
+
hasFocusOutline: boolean;
|
|
83
89
|
}, {}, string, {}, import('vue').GlobalComponents, import('vue').GlobalDirectives, string, import('vue').ComponentProvideOptions> & import('vue').VNodeProps & import('vue').AllowedComponentProps & import('vue').ComponentCustomProps & (new () => {
|
|
84
90
|
$slots: {
|
|
85
91
|
extras?(_: {}): any;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/components/QCheckbox/index.ts"],"names":[],"mappings":"AAOA,QAAA,MAAM,SAAS
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/components/QCheckbox/index.ts"],"names":[],"mappings":"AAOA,QAAA,MAAM,SAAS;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;EAA8B,CAAA;AAC7C,QAAA,MAAM,cAAc;;;;;;;;;;;;;;;;EAAmC,CAAA;AAGvD,OAAO,EAAE,SAAS,EAAE,cAAc,EAAE,CAAA;AAGpC,cAAc,SAAS,CAAA"}
|
|
@@ -46,5 +46,11 @@ export type QCheckboxProps = QCheckboxLabelProps & {
|
|
|
46
46
|
* @category Configuration
|
|
47
47
|
*/
|
|
48
48
|
icons?: typeof DEFAULT_ICONS;
|
|
49
|
+
/**
|
|
50
|
+
* Indicates whether the control will have an outline when focused.
|
|
51
|
+
*
|
|
52
|
+
* @category Behavior
|
|
53
|
+
*/
|
|
54
|
+
hasFocusOutline?: boolean;
|
|
49
55
|
};
|
|
50
56
|
//# sourceMappingURL=types.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"types.d.ts","sourceRoot":"","sources":["../../../src/components/QCheckbox/types.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,aAAa,EAAE,MAAM,aAAa,CAAA;AAG3C,OAAO,KAAK,EAAE,WAAW,EAAE,MAAM,WAAW,CAAA;AAE5C,MAAM,MAAM,mBAAmB,GAAG,WAAW,CAAA;AAE7C,MAAM,MAAM,uBAAuB,GAAG,MAAM,GAAG,OAAO,CAAA;AAEtD,MAAM,MAAM,kBAAkB,GAAG,OAAO,GAAG,SAAS,GAAG,OAAO,CAAA;AAE9D,MAAM,MAAM,cAAc,GAAG,mBAAmB,GAAG;IAClD;;;;OAIG;IACH,cAAc,CAAC,EAAE,uBAAuB,CAAA;IAExC;;;;OAIG;IACH,KAAK,CAAC,EAAE,MAAM,CAAA;IAEd;;;;OAIG;IACH,IAAI,CAAC,EAAE,kBAAkB,CAAA;IAEzB;;;;OAIG;IACH,QAAQ,CAAC,EAAE,OAAO,CAAA;IAElB;;;;OAIG;IACH,QAAQ,CAAC,EAAE,OAAO,CAAA;IAElB;;;;OAIG;IACH,aAAa,CAAC,EAAE,OAAO,CAAA;IAEvB;;;;OAIG;IACH,KAAK,CAAC,EAAE,OAAO,aAAa,CAAA;
|
|
1
|
+
{"version":3,"file":"types.d.ts","sourceRoot":"","sources":["../../../src/components/QCheckbox/types.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,aAAa,EAAE,MAAM,aAAa,CAAA;AAG3C,OAAO,KAAK,EAAE,WAAW,EAAE,MAAM,WAAW,CAAA;AAE5C,MAAM,MAAM,mBAAmB,GAAG,WAAW,CAAA;AAE7C,MAAM,MAAM,uBAAuB,GAAG,MAAM,GAAG,OAAO,CAAA;AAEtD,MAAM,MAAM,kBAAkB,GAAG,OAAO,GAAG,SAAS,GAAG,OAAO,CAAA;AAE9D,MAAM,MAAM,cAAc,GAAG,mBAAmB,GAAG;IAClD;;;;OAIG;IACH,cAAc,CAAC,EAAE,uBAAuB,CAAA;IAExC;;;;OAIG;IACH,KAAK,CAAC,EAAE,MAAM,CAAA;IAEd;;;;OAIG;IACH,IAAI,CAAC,EAAE,kBAAkB,CAAA;IAEzB;;;;OAIG;IACH,QAAQ,CAAC,EAAE,OAAO,CAAA;IAElB;;;;OAIG;IACH,QAAQ,CAAC,EAAE,OAAO,CAAA;IAElB;;;;OAIG;IACH,aAAa,CAAC,EAAE,OAAO,CAAA;IAEvB;;;;OAIG;IACH,KAAK,CAAC,EAAE,OAAO,aAAa,CAAA;IAE5B;;;;OAIG;IACH,eAAe,CAAC,EAAE,OAAO,CAAA;CACzB,CAAA"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"QOverlay.vue.d.ts","sourceRoot":"","sources":["../../../src/components/QOverlay/QOverlay.vue"],"names":[],"mappings":"AA8DA;
|
|
1
|
+
{"version":3,"file":"QOverlay.vue.d.ts","sourceRoot":"","sources":["../../../src/components/QOverlay/QOverlay.vue"],"names":[],"mappings":"AA8DA;AAuhBC,OAAO,KAAK,EAAE,aAAa,EAAE,MAAM,SAAS,CAAA;AAM5C,KAAK,WAAW,GAAG,aAAa,CAAC;AA0clC,KAAK,iBAAiB,GAAG;IACzB,UAAU,CAAC,EAAE,OAAO,CAAC;CACpB,GAAG,WAAW,CAAC;AAKhB,iBAAS,cAAc;WA6KT,OAAO,IAA6B;;yBAdpB,GAAG;;;;;;;;EAmBhC;AA+BD,KAAK,oBAAoB,GAAG,UAAU,CAAC,OAAO,cAAc,CAAC,CAAC;AAC9D,QAAA,MAAM,eAAe;;;;;;;;;;;;;;;;;;;;;;;;OASnB,CAAC;wBACkB,uBAAuB,CAAC,OAAO,eAAe,EAAE,oBAAoB,CAAC,OAAO,CAAC,CAAC;AAAnG,wBAAoG;AAapG,KAAK,uBAAuB,CAAC,CAAC,EAAE,CAAC,IAAI,CAAC,GAAG;IACxC,QAAO;QACN,MAAM,EAAE,CAAC,CAAC;KAEV,CAAA;CACD,CAAC"}
|
|
@@ -1,8 +1,8 @@
|
|
|
1
|
-
import { defineComponent as de, mergeModels as F, useModel as fe, computed as
|
|
1
|
+
import { defineComponent as de, mergeModels as F, useModel as fe, computed as u, reactive as I, watch as P, ref as _, nextTick as g, onMounted as ve, onBeforeUnmount as pe, createElementBlock as k, openBlock as c, Fragment as me, createBlock as b, createCommentVNode as y, Teleport as ye, createVNode as B, Transition as z, withCtx as L, normalizeClass as U, normalizeStyle as N, unref as T, createElementVNode as he, mergeProps as we, renderSlot as ge } from "vue";
|
|
2
2
|
import { QDismissibleLayer as ke } from "../QDismissibleLayer/index.js";
|
|
3
3
|
import { QRemoveScrollBar as Le } from "../QRemoveScrollBar/index.js";
|
|
4
4
|
import { FocusTrap as Ee } from "../../vendors/focus-trap-vue/dist/focus-trap-vue.esm-browser.js";
|
|
5
|
-
import { getSideFromPlacement as
|
|
5
|
+
import { getSideFromPlacement as _e, computePosition as be } from "../../composables/overlay.js";
|
|
6
6
|
import { useTheme as Be } from "../../composables/theme.js";
|
|
7
7
|
import { getElement as Te } from "../../utils/getElement.js";
|
|
8
8
|
const Ce = ["id"], xe = ["role"], Ae = /* @__PURE__ */ de({
|
|
@@ -38,17 +38,17 @@ const Ce = ["id"], xe = ["role"], Ae = /* @__PURE__ */ de({
|
|
|
38
38
|
}),
|
|
39
39
|
emits: /* @__PURE__ */ F(["enter", "leave"], ["update:modelValue"]),
|
|
40
40
|
setup(C, { emit: Q }) {
|
|
41
|
-
const t = C, x = Q, r = fe(C, "modelValue"), { class: W } = Be(), j =
|
|
41
|
+
const t = C, x = Q, r = fe(C, "modelValue"), { class: W } = Be(), j = u(() => [
|
|
42
42
|
"q-overlay",
|
|
43
|
-
`q-overlay--${
|
|
43
|
+
`q-overlay--${_e(o.placement)}`,
|
|
44
44
|
W.value,
|
|
45
45
|
{
|
|
46
|
-
"q-overlay--independent":
|
|
46
|
+
"q-overlay--independent": v.value,
|
|
47
47
|
"q-overlay--inverted": t.appearance === "inverted",
|
|
48
48
|
"q-overlay--center": t.centerVertically
|
|
49
49
|
},
|
|
50
50
|
t.class
|
|
51
|
-
]),
|
|
51
|
+
]), v = u(() => t.anchor === void 0), D = u(() => r.value && !t.nonModal), G = u(() => (r.value || o.animating) && t.scrollLock), H = u(() => !t.inline && (r.value || o.animating)), O = () => d.value ? d.value ?? void 0 : "#" + t.id, o = I({
|
|
52
52
|
animating: !1,
|
|
53
53
|
top: 0,
|
|
54
54
|
left: 0,
|
|
@@ -60,37 +60,37 @@ const Ce = ["id"], xe = ["role"], Ae = /* @__PURE__ */ de({
|
|
|
60
60
|
hidden: !0
|
|
61
61
|
});
|
|
62
62
|
P(r, te);
|
|
63
|
-
const J =
|
|
64
|
-
if (
|
|
65
|
-
const e =
|
|
63
|
+
const J = u(() => {
|
|
64
|
+
if (v.value) return;
|
|
65
|
+
const e = l(), s = t.width === "anchor", n = s ? e == null ? void 0 : e.getBoundingClientRect().width : void 0;
|
|
66
66
|
return {
|
|
67
67
|
top: `${o.top}px`,
|
|
68
68
|
left: `${o.left}px`,
|
|
69
69
|
width: n !== void 0 ? `${n}px` : void 0
|
|
70
70
|
};
|
|
71
|
-
}), K =
|
|
71
|
+
}), K = u(() => {
|
|
72
72
|
if (t.arrow)
|
|
73
73
|
return {
|
|
74
74
|
top: a.top !== void 0 ? `${a.top}px` : void 0,
|
|
75
75
|
left: a.left !== void 0 ? `${a.left}px` : void 0,
|
|
76
76
|
opacity: a.hidden ? 0 : 1
|
|
77
77
|
};
|
|
78
|
-
}), h =
|
|
78
|
+
}), h = _(null), S = _(null), d = _(null);
|
|
79
79
|
function i() {
|
|
80
|
-
const e =
|
|
81
|
-
if (!e || !
|
|
80
|
+
const e = l();
|
|
81
|
+
if (!e || !d.value)
|
|
82
82
|
return;
|
|
83
|
-
const
|
|
83
|
+
const s = {
|
|
84
84
|
placement: t.placement,
|
|
85
85
|
width: t.width,
|
|
86
86
|
offset: t.offset,
|
|
87
87
|
crossOffset: t.crossOffset,
|
|
88
88
|
arrow: t.arrow
|
|
89
|
-
}, n =
|
|
89
|
+
}, n = be(
|
|
90
90
|
e,
|
|
91
|
-
|
|
91
|
+
d.value,
|
|
92
92
|
(h == null ? void 0 : h.value) ?? void 0,
|
|
93
|
-
|
|
93
|
+
s
|
|
94
94
|
);
|
|
95
95
|
o.left = n.overlayCoords.x, o.top = n.overlayCoords.y, o.placement = n.placement, a.hidden = n.arrowCoords === void 0, n.arrowCoords && (a.top = n.arrowCoords.y, a.left = n.arrowCoords.x);
|
|
96
96
|
}
|
|
@@ -110,9 +110,9 @@ const Ce = ["id"], xe = ["role"], Ae = /* @__PURE__ */ de({
|
|
|
110
110
|
r.value = !0;
|
|
111
111
|
}, e);
|
|
112
112
|
}
|
|
113
|
-
function
|
|
113
|
+
function f() {
|
|
114
114
|
if (p && M(), r.value = !1, t.anchor && t.trigger === "click") {
|
|
115
|
-
const e =
|
|
115
|
+
const e = l();
|
|
116
116
|
g(() => e == null ? void 0 : e.focus());
|
|
117
117
|
}
|
|
118
118
|
}
|
|
@@ -137,7 +137,7 @@ const Ce = ["id"], xe = ["role"], Ae = /* @__PURE__ */ de({
|
|
|
137
137
|
function V() {
|
|
138
138
|
o.animating = !1;
|
|
139
139
|
}
|
|
140
|
-
function
|
|
140
|
+
function l() {
|
|
141
141
|
return t.anchor ? Te(t.anchor) : null;
|
|
142
142
|
}
|
|
143
143
|
function ne(e) {
|
|
@@ -149,21 +149,21 @@ const Ce = ["id"], xe = ["role"], Ae = /* @__PURE__ */ de({
|
|
|
149
149
|
e.preventDefault();
|
|
150
150
|
return;
|
|
151
151
|
}
|
|
152
|
-
let
|
|
153
|
-
e.defaultPrevented || e.detail.originalEvent.type === "pointerdown" && (
|
|
152
|
+
let s = !1;
|
|
153
|
+
e.defaultPrevented || e.detail.originalEvent.type === "pointerdown" && (s = !0);
|
|
154
154
|
const n = e.detail.originalEvent.target;
|
|
155
|
-
if ((A =
|
|
155
|
+
if ((A = l()) == null ? void 0 : A.contains(n)) {
|
|
156
156
|
e.preventDefault();
|
|
157
157
|
return;
|
|
158
158
|
}
|
|
159
|
-
e.detail.originalEvent.type === "focusin" &&
|
|
159
|
+
e.detail.originalEvent.type === "focusin" && s && e.preventDefault();
|
|
160
160
|
}
|
|
161
161
|
function re() {
|
|
162
|
-
|
|
162
|
+
f();
|
|
163
163
|
}
|
|
164
164
|
let m;
|
|
165
165
|
function ae() {
|
|
166
|
-
const e =
|
|
166
|
+
const e = l();
|
|
167
167
|
if (e)
|
|
168
168
|
switch (m = new MutationObserver(i), m.observe(e, {
|
|
169
169
|
attributes: !1,
|
|
@@ -175,19 +175,19 @@ const Ce = ["id"], xe = ["role"], Ae = /* @__PURE__ */ de({
|
|
|
175
175
|
e.addEventListener("click", w);
|
|
176
176
|
break;
|
|
177
177
|
case "hover":
|
|
178
|
-
e.addEventListener("mouseenter", q), e.addEventListener("mouseleave",
|
|
178
|
+
e.addEventListener("mouseenter", q), e.addEventListener("mouseleave", f), e.addEventListener("focusin", w), e.addEventListener("focusout", f);
|
|
179
179
|
break;
|
|
180
180
|
}
|
|
181
181
|
}
|
|
182
182
|
function ie() {
|
|
183
|
-
const e =
|
|
183
|
+
const e = l();
|
|
184
184
|
if (e)
|
|
185
185
|
switch (m == null || m.disconnect(), t.trigger) {
|
|
186
186
|
case "click":
|
|
187
187
|
e.removeEventListener("click", w);
|
|
188
188
|
break;
|
|
189
189
|
case "hover":
|
|
190
|
-
e.removeEventListener("mouseenter", q), e.removeEventListener("mouseleave",
|
|
190
|
+
e.removeEventListener("mouseenter", q), e.removeEventListener("mouseleave", f), e.removeEventListener("focusin", w), e.removeEventListener("focusout", f);
|
|
191
191
|
break;
|
|
192
192
|
}
|
|
193
193
|
}
|
|
@@ -199,22 +199,22 @@ const Ce = ["id"], xe = ["role"], Ae = /* @__PURE__ */ de({
|
|
|
199
199
|
}
|
|
200
200
|
let E;
|
|
201
201
|
function $() {
|
|
202
|
-
|
|
202
|
+
l() ? (i(), E = window.setTimeout($, 100)) : f();
|
|
203
203
|
}
|
|
204
204
|
function ue() {
|
|
205
205
|
var e;
|
|
206
|
-
|
|
206
|
+
v.value || (le(), t.spy ? $() : i()), (v.value || t.trigger === "click") && ((e = S.value) == null || e.focus());
|
|
207
207
|
}
|
|
208
208
|
function ce() {
|
|
209
|
-
|
|
209
|
+
v.value || se(), t.spy && (clearTimeout(E), E = void 0);
|
|
210
210
|
}
|
|
211
211
|
return ve(() => {
|
|
212
212
|
g(ae);
|
|
213
|
-
}), pe(ie), (e,
|
|
213
|
+
}), pe(ie), (e, s) => (c(), k(
|
|
214
214
|
me,
|
|
215
215
|
null,
|
|
216
216
|
[
|
|
217
|
-
(c(),
|
|
217
|
+
(c(), b(ye, {
|
|
218
218
|
disabled: !H.value,
|
|
219
219
|
to: t.attach
|
|
220
220
|
}, [
|
|
@@ -254,7 +254,7 @@ const Ce = ["id"], xe = ["role"], Ae = /* @__PURE__ */ de({
|
|
|
254
254
|
key: 0,
|
|
255
255
|
id: t.id,
|
|
256
256
|
ref_key: "overlayContainerRef",
|
|
257
|
-
ref:
|
|
257
|
+
ref: d,
|
|
258
258
|
tabindex: "-1",
|
|
259
259
|
class: U(j.value),
|
|
260
260
|
style: N(J.value)
|
|
@@ -265,11 +265,11 @@ const Ce = ["id"], xe = ["role"], Ae = /* @__PURE__ */ de({
|
|
|
265
265
|
onPointerDownOutside: ne
|
|
266
266
|
}, {
|
|
267
267
|
default: L(() => [
|
|
268
|
-
|
|
268
|
+
d.value ? (c(), b(T(Ee), {
|
|
269
269
|
key: 0,
|
|
270
270
|
active: !t.nonModal && r.value && t.focusTrap,
|
|
271
|
-
"fallback-focus": O
|
|
272
|
-
"initial-focus": O
|
|
271
|
+
"fallback-focus": O,
|
|
272
|
+
"initial-focus": O,
|
|
273
273
|
"return-focus-on-deactivate": t.returnFocusOnDeactivate
|
|
274
274
|
}, {
|
|
275
275
|
default: L(() => [
|
|
@@ -299,7 +299,7 @@ const Ce = ["id"], xe = ["role"], Ae = /* @__PURE__ */ de({
|
|
|
299
299
|
]),
|
|
300
300
|
_: 3
|
|
301
301
|
/* FORWARDED */
|
|
302
|
-
}, 8, ["active", "
|
|
302
|
+
}, 8, ["active", "return-focus-on-deactivate"])) : y("v-if", !0)
|
|
303
303
|
]),
|
|
304
304
|
_: 3
|
|
305
305
|
/* FORWARDED */
|
|
@@ -310,7 +310,7 @@ const Ce = ["id"], xe = ["role"], Ae = /* @__PURE__ */ de({
|
|
|
310
310
|
/* FORWARDED */
|
|
311
311
|
}, 8, ["name"])
|
|
312
312
|
], 8, ["disabled", "to"])),
|
|
313
|
-
G.value ? (c(),
|
|
313
|
+
G.value ? (c(), b(T(Le), { key: 0 })) : y("v-if", !0)
|
|
314
314
|
],
|
|
315
315
|
64
|
|
316
316
|
/* STABLE_FRAGMENT */
|
|
@@ -19,6 +19,7 @@ declare const __VLS_component: import('vue').DefineComponent<__VLS_PublicProps,
|
|
|
19
19
|
"onUpdate:modelValue"?: ((value: any) => any) | undefined;
|
|
20
20
|
}>, {
|
|
21
21
|
size: import('./types').QRadioButtonSize;
|
|
22
|
+
hasFocusOutline: boolean;
|
|
22
23
|
orientation: import('./types').QRadioButtonOrientation;
|
|
23
24
|
columns: number;
|
|
24
25
|
}, {}, {}, {}, string, import('vue').ComponentProvideOptions, false, {}, any>;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"QRadioGroup.vue.d.ts","sourceRoot":"","sources":["../../../src/components/QRadioGroup/QRadioGroup.vue"],"names":[],"mappings":"AAuBA;
|
|
1
|
+
{"version":3,"file":"QRadioGroup.vue.d.ts","sourceRoot":"","sources":["../../../src/components/QRadioGroup/QRadioGroup.vue"],"names":[],"mappings":"AAuBA;AA8GC,OAAO,KAAK,EAAE,gBAAgB,EAAE,MAAM,SAAS,CAAA;AAK/C,KAAK,WAAW,GAAG,gBAAgB,CAAC;AAsErC,KAAK,iBAAiB,GAAG;IACzB,UAAU,CAAC,EAAE,GAAG,CAAC;CAChB,GAAG,WAAW,CAAC;AAKhB,iBAAS,cAAc;WAsDT,OAAO,IAA6B;;yBAZrB,GAAG;wBACJ,GAAG;;;;EAgB9B;AAcD,KAAK,oBAAoB,GAAG,UAAU,CAAC,OAAO,cAAc,CAAC,CAAC;AAC9D,QAAA,MAAM,eAAe;;;;;;;;;6EAQnB,CAAC;wBACkB,uBAAuB,CAAC,OAAO,eAAe,EAAE,oBAAoB,CAAC,OAAO,CAAC,CAAC;AAAnG,wBAAoG;AAapG,KAAK,uBAAuB,CAAC,CAAC,EAAE,CAAC,IAAI,CAAC,GAAG;IACxC,QAAO;QACN,MAAM,EAAE,CAAC,CAAC;KAEV,CAAA;CACD,CAAC"}
|
|
@@ -1,15 +1,15 @@
|
|
|
1
|
-
import { defineComponent as
|
|
1
|
+
import { defineComponent as g, mergeModels as q, useModel as b, watch as h, toRef as r, computed as d, createElementBlock as n, openBlock as l, normalizeClass as B, createBlock as _, createCommentVNode as u, createElementVNode as z, unref as a, mergeProps as k, renderSlot as c } from "vue";
|
|
2
2
|
import { QLabel as V } from "../QLabel/index.js";
|
|
3
3
|
import { provideDefaults as $ } from "../../composables/defaults.js";
|
|
4
|
-
import { useId as
|
|
4
|
+
import { useId as m } from "../../composables/uid.js";
|
|
5
5
|
import { useGroup as C } from "../../composables/useGroup/index.js";
|
|
6
6
|
const M = ["id"], Q = {
|
|
7
7
|
key: 1,
|
|
8
8
|
class: "q-field__extras"
|
|
9
|
-
},
|
|
9
|
+
}, S = /* @__PURE__ */ g({
|
|
10
10
|
inheritAttrs: !1,
|
|
11
11
|
__name: "QRadioGroup",
|
|
12
|
-
props: /* @__PURE__ */
|
|
12
|
+
props: /* @__PURE__ */ q({
|
|
13
13
|
id: {},
|
|
14
14
|
class: {},
|
|
15
15
|
label: {},
|
|
@@ -21,24 +21,26 @@ const M = ["id"], Q = {
|
|
|
21
21
|
columns: { default: 1 },
|
|
22
22
|
disabled: { type: Boolean },
|
|
23
23
|
readonly: { type: Boolean },
|
|
24
|
-
invalid: { type: Boolean }
|
|
24
|
+
invalid: { type: Boolean },
|
|
25
|
+
hasFocusOutline: { type: Boolean, default: !0 }
|
|
25
26
|
}, {
|
|
26
27
|
modelValue: {},
|
|
27
28
|
modelModifiers: {}
|
|
28
29
|
}),
|
|
29
30
|
emits: ["update:modelValue"],
|
|
30
31
|
setup(t) {
|
|
31
|
-
const e = t,
|
|
32
|
-
|
|
33
|
-
|
|
32
|
+
const e = t, s = b(t, "modelValue"), { active: p } = C({ active: s, required: !0 });
|
|
33
|
+
h(p, (o) => {
|
|
34
|
+
s.value = o;
|
|
34
35
|
});
|
|
35
|
-
const
|
|
36
|
+
const i = m(r(e, "id")), f = m(r(e, "name")), v = d(() => [
|
|
36
37
|
"q-radio-group",
|
|
37
38
|
{
|
|
38
|
-
"q-radio-group--horizontal": e.orientation === "horizontal"
|
|
39
|
+
"q-radio-group--horizontal": e.orientation === "horizontal",
|
|
40
|
+
"q-radio-group--focus-style": e.hasFocusOutline
|
|
39
41
|
},
|
|
40
42
|
e.class
|
|
41
|
-
]),
|
|
43
|
+
]), y = d(() => e.columns > 1 ? {
|
|
42
44
|
"--q-radio-group-columns": e.columns
|
|
43
45
|
} : {
|
|
44
46
|
undefined: void 0
|
|
@@ -54,25 +56,25 @@ const M = ["id"], Q = {
|
|
|
54
56
|
}), (o, R) => (l(), n(
|
|
55
57
|
"div",
|
|
56
58
|
{
|
|
57
|
-
class:
|
|
59
|
+
class: B(v.value)
|
|
58
60
|
},
|
|
59
61
|
[
|
|
60
|
-
e.label ? (l(),
|
|
62
|
+
e.label ? (l(), _(a(V), {
|
|
61
63
|
key: 0,
|
|
62
|
-
for: a(
|
|
64
|
+
for: a(i),
|
|
63
65
|
label: e.label,
|
|
64
66
|
required: e.required
|
|
65
67
|
}, null, 8, ["for", "label", "required"])) : u("v-if", !0),
|
|
66
68
|
z("div", k({
|
|
67
|
-
id: a(
|
|
69
|
+
id: a(i),
|
|
68
70
|
class: ["q-radio-group__group", { "q-radio-group--grid": e.columns > 1 }],
|
|
69
71
|
role: "radiogroup",
|
|
70
|
-
style:
|
|
72
|
+
style: y.value
|
|
71
73
|
}, o.$attrs), [
|
|
72
|
-
|
|
74
|
+
c(o.$slots, "default")
|
|
73
75
|
], 16, M),
|
|
74
76
|
o.$slots.extras ? (l(), n("div", Q, [
|
|
75
|
-
|
|
77
|
+
c(o.$slots, "extras")
|
|
76
78
|
])) : u("v-if", !0)
|
|
77
79
|
],
|
|
78
80
|
2
|
|
@@ -81,5 +83,5 @@ const M = ["id"], Q = {
|
|
|
81
83
|
}
|
|
82
84
|
});
|
|
83
85
|
export {
|
|
84
|
-
|
|
86
|
+
S as default
|
|
85
87
|
};
|
|
@@ -45,12 +45,14 @@ declare const QRadioGroup: {
|
|
|
45
45
|
disabled?: boolean;
|
|
46
46
|
readonly?: boolean;
|
|
47
47
|
invalid?: boolean;
|
|
48
|
+
hasFocusOutline?: boolean;
|
|
48
49
|
}> & Readonly<{
|
|
49
50
|
"onUpdate:modelValue"?: ((value: any) => any) | undefined;
|
|
50
51
|
}>, {}, {}, {}, {}, import('vue').ComponentOptionsMixin, import('vue').ComponentOptionsMixin, {
|
|
51
52
|
"update:modelValue": (value: any) => any;
|
|
52
53
|
}, import('vue').PublicProps, {
|
|
53
54
|
size: import('./types').QRadioButtonSize;
|
|
55
|
+
hasFocusOutline: boolean;
|
|
54
56
|
orientation: import('./types').QRadioButtonOrientation;
|
|
55
57
|
columns: number;
|
|
56
58
|
}, false, {}, {}, import('vue').GlobalComponents, import('vue').GlobalDirectives, string, {}, any, import('vue').ComponentProvideOptions, {
|
|
@@ -74,10 +76,12 @@ declare const QRadioGroup: {
|
|
|
74
76
|
disabled?: boolean;
|
|
75
77
|
readonly?: boolean;
|
|
76
78
|
invalid?: boolean;
|
|
79
|
+
hasFocusOutline?: boolean;
|
|
77
80
|
}> & Readonly<{
|
|
78
81
|
"onUpdate:modelValue"?: ((value: any) => any) | undefined;
|
|
79
82
|
}>, {}, {}, {}, {}, {
|
|
80
83
|
size: import('./types').QRadioButtonSize;
|
|
84
|
+
hasFocusOutline: boolean;
|
|
81
85
|
orientation: import('./types').QRadioButtonOrientation;
|
|
82
86
|
columns: number;
|
|
83
87
|
}>;
|
|
@@ -98,12 +102,14 @@ declare const QRadioGroup: {
|
|
|
98
102
|
disabled?: boolean;
|
|
99
103
|
readonly?: boolean;
|
|
100
104
|
invalid?: boolean;
|
|
105
|
+
hasFocusOutline?: boolean;
|
|
101
106
|
}> & Readonly<{
|
|
102
107
|
"onUpdate:modelValue"?: ((value: any) => any) | undefined;
|
|
103
108
|
}>, {}, {}, {}, {}, import('vue').ComponentOptionsMixin, import('vue').ComponentOptionsMixin, {
|
|
104
109
|
"update:modelValue": (value: any) => any;
|
|
105
110
|
}, string, {
|
|
106
111
|
size: import('./types').QRadioButtonSize;
|
|
112
|
+
hasFocusOutline: boolean;
|
|
107
113
|
orientation: import('./types').QRadioButtonOrientation;
|
|
108
114
|
columns: number;
|
|
109
115
|
}, {}, string, {}, import('vue').GlobalComponents, import('vue').GlobalDirectives, string, import('vue').ComponentProvideOptions> & import('vue').VNodeProps & import('vue').AllowedComponentProps & import('vue').ComponentCustomProps & (new () => {
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/components/QRadioGroup/index.ts"],"names":[],"mappings":"AAOA,QAAA,MAAM,YAAY;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;EAAiC,CAAA;AACnD,QAAA,MAAM,WAAW
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/components/QRadioGroup/index.ts"],"names":[],"mappings":"AAOA,QAAA,MAAM,YAAY;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;EAAiC,CAAA;AACnD,QAAA,MAAM,WAAW;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;EAAgC,CAAA;AAGjD,OAAO,EAAE,YAAY,EAAE,WAAW,EAAE,CAAA;AAGpC,cAAc,SAAS,CAAA"}
|