@quidgest/ui 0.16.68 → 0.16.70
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 +6 -1
- package/dist/ui.css +12 -0
- package/dist/ui.esm.js +4050 -4111
- package/dist/ui.js +24 -24
- package/dist/ui.min.css +1 -1
- package/dist/ui.min.js +187 -203
- package/dist/ui.scss +15 -3
- package/esm/components/QDialog/QDialog.d.ts +2 -0
- package/esm/components/QDialog/QDialog.d.ts.map +1 -1
- package/esm/components/QDialog/QDialog.vue.js +19 -19
- package/esm/components/QDialog/QDialogProvider.d.ts.map +1 -1
- package/esm/components/QDialog/QDialogProvider.vue.js +19 -15
- package/esm/components/QDialog/index.d.ts +5 -0
- package/esm/components/QDialog/index.d.ts.map +1 -1
- package/esm/components/QDialog/types.d.ts +7 -0
- package/esm/components/QDialog/types.d.ts.map +1 -1
- package/esm/components/QTextArea/QTextArea.d.ts.map +1 -1
- package/esm/components/QTextArea/QTextArea.vue.js +18 -18
- package/esm/composables/useDialog/index.d.ts +1 -0
- package/esm/composables/useDialog/index.d.ts.map +1 -1
- package/esm/composables/useTextareaAutosize/index.d.ts +11 -0
- package/esm/composables/useTextareaAutosize/index.d.ts.map +1 -0
- package/esm/composables/useTextareaAutosize/index.js +22 -0
- package/package.json +1 -3
- package/esm/vendors/@vueuse/core/index.js +0 -85
- package/esm/vendors/@vueuse/shared/index.js +0 -20
package/dist/ui.scss
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
/*!
|
|
2
|
-
* Quidgest UI v0.16.
|
|
2
|
+
* Quidgest UI v0.16.70
|
|
3
3
|
* (c) 2026 Quidgest - Consultores de Gestão, S.A.
|
|
4
4
|
* Released under the MIT License.
|
|
5
5
|
*/
|
|
@@ -483,6 +483,12 @@ $transition-duration: 0.2s !default;
|
|
|
483
483
|
border-radius: inherit;
|
|
484
484
|
opacity: 0.1;
|
|
485
485
|
}
|
|
486
|
+
&__content {
|
|
487
|
+
white-space: normal;
|
|
488
|
+
.q-icon {
|
|
489
|
+
min-width: fit-content;
|
|
490
|
+
}
|
|
491
|
+
}
|
|
486
492
|
&__content,
|
|
487
493
|
&__content.q-button {
|
|
488
494
|
display: inline-flex;
|
|
@@ -508,6 +514,7 @@ $transition-duration: 0.2s !default;
|
|
|
508
514
|
}
|
|
509
515
|
&__remove.q-button {
|
|
510
516
|
padding: 0.25rem;
|
|
517
|
+
min-width: fit-content;
|
|
511
518
|
}
|
|
512
519
|
&:not(:has(button.q-badge__content)) {
|
|
513
520
|
|
|
@@ -582,8 +589,13 @@ $transition-duration: 0.2s !default;
|
|
|
582
589
|
display: inline-flex;
|
|
583
590
|
}
|
|
584
591
|
}
|
|
585
|
-
.q-button-group
|
|
586
|
-
|
|
592
|
+
.q-button-group {
|
|
593
|
+
& > .q-button:not(:first-child).q-badge__remove {
|
|
594
|
+
margin-left: 1px;
|
|
595
|
+
}
|
|
596
|
+
.q-badge__content {
|
|
597
|
+
white-space: normal;
|
|
598
|
+
}
|
|
587
599
|
}
|
|
588
600
|
.q-badge-indicator {
|
|
589
601
|
$this: &;
|
|
@@ -17,8 +17,10 @@ declare function __VLS_template(): {
|
|
|
17
17
|
type __VLS_TemplateResult = ReturnType<typeof __VLS_template>;
|
|
18
18
|
declare const __VLS_component: import('vue').DefineComponent<QDialogProps, {}, {}, {}, {}, import('vue').ComponentOptionsMixin, import('vue').ComponentOptionsMixin, {} & {
|
|
19
19
|
"update:modelValue": (val: boolean) => any;
|
|
20
|
+
action: (val: string) => any;
|
|
20
21
|
}, string, import('vue').PublicProps, Readonly<QDialogProps> & Readonly<{
|
|
21
22
|
"onUpdate:modelValue"?: ((val: boolean) => any) | undefined;
|
|
23
|
+
onAction?: ((val: string) => any) | undefined;
|
|
22
24
|
}>, {
|
|
23
25
|
size: import('./types').QDialogSize;
|
|
24
26
|
html: boolean;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"QDialog.vue.d.ts","sourceRoot":"","sources":["../../../src/components/QDialog/QDialog.vue"],"names":[],"mappings":"AAwGA;
|
|
1
|
+
{"version":3,"file":"QDialog.vue.d.ts","sourceRoot":"","sources":["../../../src/components/QDialog/QDialog.vue"],"names":[],"mappings":"AAwGA;AA0LC,OAAO,EAAiC,aAAa,EAAE,MAAM,aAAa,CAAA;AAS1E,OAAO,KAAK,EAAE,YAAY,EAAE,YAAY,EAAE,MAAM,SAAS,CAAA;AAmF1D,iBAAS,cAAc;WAgQT,OAAO,IAA6B;;wBAhBrB,GAAG;kCACO,GAAG;iCACJ,GAAG;sBACd,GAAG;6BACI,GAAG;+BACD,GAAG;iCACD,GAAG;;;;EAexC;AAsBD,KAAK,oBAAoB,GAAG,UAAU,CAAC,OAAO,cAAc,CAAC,CAAC;AAC9D,QAAA,MAAM,eAAe;;;;;;;;;;;;;;;;;6EASnB,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,6 +1,6 @@
|
|
|
1
|
-
import { defineComponent as E, ref as
|
|
1
|
+
import { defineComponent as E, ref as k, computed as g, createBlock as d, openBlock as t, unref as a, normalizeClass as B, withCtx as p, createElementVNode as V, createElementBlock as i, createCommentVNode as s, renderSlot as n, toDisplayString as m, createVNode as _, normalizeProps as b, guardReactiveProps as $, createTextVNode as L, Fragment as U, renderList as w, mergeProps as q } from "vue";
|
|
2
2
|
import { DEFAULT_ICONS as Q, DEFAULT_BUTTONS as M, DEFAULT_ICON as S } from "./constants.js";
|
|
3
|
-
import { QButton as
|
|
3
|
+
import { QButton as F } from "../QButton/index.js";
|
|
4
4
|
import { QIcon as f } from "../QIcon/index.js";
|
|
5
5
|
import { QOverlay as W } from "../QOverlay/index.js";
|
|
6
6
|
import { QTextField as I } from "../QTextField/index.js";
|
|
@@ -50,26 +50,26 @@ const P = {
|
|
|
50
50
|
input: {},
|
|
51
51
|
icons: { default: () => Q }
|
|
52
52
|
},
|
|
53
|
-
emits: ["update:modelValue"],
|
|
54
|
-
setup(C, { emit:
|
|
55
|
-
const e = C,
|
|
53
|
+
emits: ["update:modelValue", "action"],
|
|
54
|
+
setup(C, { emit: T }) {
|
|
55
|
+
const e = C, y = T, u = k(""), r = k(""), D = g(() => ["q-dialog", e.class]), O = g(() => `q-overlay--${e.size}`);
|
|
56
56
|
function N() {
|
|
57
57
|
v(!0);
|
|
58
58
|
}
|
|
59
|
-
function
|
|
59
|
+
function h() {
|
|
60
60
|
v(!1);
|
|
61
61
|
}
|
|
62
62
|
function z(o) {
|
|
63
63
|
var c, l;
|
|
64
|
-
if (o.action) {
|
|
64
|
+
if (y("action", o.id), o.action) {
|
|
65
65
|
if ((c = e.input) != null && c.validator && (r.value = e.input.validator(a(u)), a(r)))
|
|
66
66
|
return;
|
|
67
67
|
(l = o.action) == null || l.call(o, a(u));
|
|
68
68
|
}
|
|
69
|
-
|
|
69
|
+
h();
|
|
70
70
|
}
|
|
71
71
|
function v(o) {
|
|
72
|
-
|
|
72
|
+
y("update:modelValue", o);
|
|
73
73
|
}
|
|
74
74
|
return (o, c) => (t(), d(a(W), {
|
|
75
75
|
id: e.id,
|
|
@@ -86,15 +86,15 @@ const P = {
|
|
|
86
86
|
"focus-within-on-activate": e.focusWithinOnActivate,
|
|
87
87
|
"closing-focus": e.closingFocus,
|
|
88
88
|
"return-focus-on-deactivate": e.returnFocusOnDeactivate,
|
|
89
|
-
class:
|
|
89
|
+
class: B(O.value),
|
|
90
90
|
onEnter: N,
|
|
91
91
|
"onUpdate:modelValue": v
|
|
92
92
|
}, {
|
|
93
93
|
default: p(() => [
|
|
94
|
-
|
|
94
|
+
V(
|
|
95
95
|
"div",
|
|
96
96
|
{
|
|
97
|
-
class:
|
|
97
|
+
class: B(D.value)
|
|
98
98
|
},
|
|
99
99
|
[
|
|
100
100
|
e.title || o.$slots.header || o.$slots["header.prepend"] || o.$slots["header.append"] ? (t(), i("div", P, [
|
|
@@ -118,14 +118,14 @@ const P = {
|
|
|
118
118
|
e.icon ? (t(), i("span", R, [
|
|
119
119
|
_(
|
|
120
120
|
a(f),
|
|
121
|
-
|
|
121
|
+
b($(e.icon)),
|
|
122
122
|
null,
|
|
123
123
|
16
|
|
124
124
|
/* FULL_PROPS */
|
|
125
125
|
)
|
|
126
126
|
])) : s("v-if", !0)
|
|
127
127
|
]),
|
|
128
|
-
|
|
128
|
+
V("div", j, [
|
|
129
129
|
e.html ? (t(), i("div", {
|
|
130
130
|
key: 0,
|
|
131
131
|
innerHTML: e.text
|
|
@@ -169,14 +169,14 @@ const P = {
|
|
|
169
169
|
(t(!0), i(
|
|
170
170
|
U,
|
|
171
171
|
null,
|
|
172
|
-
w(e.buttons, (l) => (t(), d(a(
|
|
172
|
+
w(e.buttons, (l) => (t(), d(a(F), q({ ref_for: !0 }, l.props, {
|
|
173
173
|
key: l.id,
|
|
174
174
|
onClick: () => z(l)
|
|
175
175
|
}), {
|
|
176
176
|
default: p(() => [
|
|
177
177
|
l.icon ? (t(), d(
|
|
178
178
|
a(f),
|
|
179
|
-
|
|
179
|
+
q({
|
|
180
180
|
key: 0,
|
|
181
181
|
ref_for: !0
|
|
182
182
|
}, l.icon),
|
|
@@ -194,16 +194,16 @@ const P = {
|
|
|
194
194
|
])) : s("v-if", !0),
|
|
195
195
|
n(o.$slots, "footer.append")
|
|
196
196
|
])) : s("v-if", !0),
|
|
197
|
-
e.dismissible ? (t(), d(a(
|
|
197
|
+
e.dismissible ? (t(), d(a(F), {
|
|
198
198
|
key: 3,
|
|
199
199
|
class: "q-dialog__close",
|
|
200
200
|
variant: "text",
|
|
201
|
-
onClick:
|
|
201
|
+
onClick: h
|
|
202
202
|
}, {
|
|
203
203
|
default: p(() => [
|
|
204
204
|
_(
|
|
205
205
|
a(f),
|
|
206
|
-
|
|
206
|
+
b($(e.icons.close)),
|
|
207
207
|
null,
|
|
208
208
|
16
|
|
209
209
|
/* FULL_PROPS */
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"QDialogProvider.vue.d.ts","sourceRoot":"","sources":["../../../src/components/QDialog/QDialogProvider.vue"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"QDialogProvider.vue.d.ts","sourceRoot":"","sources":["../../../src/components/QDialog/QDialogProvider.vue"],"names":[],"mappings":"AAUA;AAiDC,OAAO,KAAK,EAAE,oBAAoB,EAAE,MAAM,SAAS,CAAA;;;;;;AAuFpD,wBAOG"}
|
|
@@ -1,28 +1,32 @@
|
|
|
1
|
-
import { defineComponent as
|
|
1
|
+
import { defineComponent as d, createElementBlock as _, openBlock as r, Fragment as g, renderList as k, unref as i, createBlock as v, mergeProps as A } from "vue";
|
|
2
2
|
import { QDialog as B } from "./index.js";
|
|
3
3
|
import { useDialog as D } from "../../composables/useDialog/index.js";
|
|
4
|
-
const x = /* @__PURE__ */
|
|
4
|
+
const x = /* @__PURE__ */ d({
|
|
5
5
|
inheritAttrs: !1,
|
|
6
6
|
__name: "QDialogProvider",
|
|
7
7
|
props: {
|
|
8
8
|
inline: { type: Boolean }
|
|
9
9
|
},
|
|
10
10
|
emits: ["leave"],
|
|
11
|
-
setup(
|
|
12
|
-
const
|
|
13
|
-
function u(
|
|
14
|
-
|
|
11
|
+
setup(l, { emit: a }) {
|
|
12
|
+
const m = l, p = a, { dialogs: s, removeDialog: c } = D();
|
|
13
|
+
function u(n, o) {
|
|
14
|
+
o || (c(n), p("leave", n));
|
|
15
15
|
}
|
|
16
|
-
return (
|
|
17
|
-
|
|
16
|
+
return (n, o) => (r(!0), _(
|
|
17
|
+
g,
|
|
18
18
|
null,
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
19
|
+
k(i(s), (e) => {
|
|
20
|
+
var t;
|
|
21
|
+
return r(), v(i(B), A({
|
|
22
|
+
key: e.id,
|
|
23
|
+
ref_for: !0
|
|
24
|
+
}, e.props, {
|
|
25
|
+
inline: m.inline,
|
|
26
|
+
onAction: (t = e.handlers) == null ? void 0 : t.onAction,
|
|
27
|
+
"onUpdate:modelValue": (f) => u(e.id, f)
|
|
28
|
+
}), null, 16, ["inline", "onAction", "onUpdate:modelValue"]);
|
|
29
|
+
}),
|
|
26
30
|
128
|
|
27
31
|
/* KEYED_FRAGMENT */
|
|
28
32
|
));
|
|
@@ -1,8 +1,10 @@
|
|
|
1
1
|
declare const QDialog: {
|
|
2
2
|
new (...args: any[]): import('vue').CreateComponentPublicInstanceWithMixins<Readonly<import('./types').QDialogProps> & Readonly<{
|
|
3
3
|
"onUpdate:modelValue"?: ((val: boolean) => any) | undefined;
|
|
4
|
+
onAction?: ((val: string) => any) | undefined;
|
|
4
5
|
}>, {}, {}, {}, {}, import('vue').ComponentOptionsMixin, import('vue').ComponentOptionsMixin, {} & {
|
|
5
6
|
"update:modelValue": (val: boolean) => any;
|
|
7
|
+
action: (val: string) => any;
|
|
6
8
|
}, import('vue').PublicProps, {
|
|
7
9
|
size: import('./types').QDialogSize;
|
|
8
10
|
html: boolean;
|
|
@@ -23,6 +25,7 @@ declare const QDialog: {
|
|
|
23
25
|
Defaults: {};
|
|
24
26
|
}, Readonly<import('./types').QDialogProps> & Readonly<{
|
|
25
27
|
"onUpdate:modelValue"?: ((val: boolean) => any) | undefined;
|
|
28
|
+
onAction?: ((val: string) => any) | undefined;
|
|
26
29
|
}>, {}, {}, {}, {}, {
|
|
27
30
|
size: import('./types').QDialogSize;
|
|
28
31
|
html: boolean;
|
|
@@ -40,8 +43,10 @@ declare const QDialog: {
|
|
|
40
43
|
__isSuspense?: never;
|
|
41
44
|
} & import('vue').ComponentOptionsBase<Readonly<import('./types').QDialogProps> & Readonly<{
|
|
42
45
|
"onUpdate:modelValue"?: ((val: boolean) => any) | undefined;
|
|
46
|
+
onAction?: ((val: string) => any) | undefined;
|
|
43
47
|
}>, {}, {}, {}, {}, import('vue').ComponentOptionsMixin, import('vue').ComponentOptionsMixin, {} & {
|
|
44
48
|
"update:modelValue": (val: boolean) => any;
|
|
49
|
+
action: (val: string) => any;
|
|
45
50
|
}, string, {
|
|
46
51
|
size: import('./types').QDialogSize;
|
|
47
52
|
html: boolean;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/components/QDialog/index.ts"],"names":[],"mappings":"AAOA,QAAA,MAAM,OAAO
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/components/QDialog/index.ts"],"names":[],"mappings":"AAOA,QAAA,MAAM,OAAO;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;EAA4B,CAAA;AACzC,QAAA,MAAM,eAAe;;;;kFAAoC,CAAA;AAGzD,OAAO,EAAE,OAAO,EAAE,eAAe,EAAE,CAAA;AAGnC,cAAc,SAAS,CAAA"}
|
|
@@ -199,5 +199,12 @@ export type QDialogHandlers = {
|
|
|
199
199
|
* @category Behavior
|
|
200
200
|
*/
|
|
201
201
|
onLeave?: () => boolean | void;
|
|
202
|
+
/**
|
|
203
|
+
* Handler for 'action' event.
|
|
204
|
+
*
|
|
205
|
+
* @category Behavior
|
|
206
|
+
* @param val - The ID of the button pressed
|
|
207
|
+
*/
|
|
208
|
+
onAction?: (val: string) => void;
|
|
202
209
|
};
|
|
203
210
|
//# sourceMappingURL=types.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"types.d.ts","sourceRoot":"","sources":["../../../src/components/QDialog/types.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAE,mBAAmB,EAAE,MAAM,uBAAuB,CAAA;AAChE,OAAO,KAAK,EAAE,YAAY,EAAE,MAAM,YAAY,CAAA;AAC9C,OAAO,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CAC5B,CAAA;AAED,MAAM,MAAM,YAAY,GAAG;IAC1B;;OAEG;IACH,EAAE,EAAE,MAAM,CAAA;IAEV;;OAEG;IACH,IAAI,CAAC,EAAE,IAAI,CAAA;IAEX;;OAEG;IACH,MAAM,CAAC,EAAE;QAAE,CAAC,KAAK,CAAC,EAAE,MAAM,GAAG,IAAI,CAAA;KAAE,CAAA;IAEnC;;OAEG;IACH,KAAK,EAAE,YAAY,CAAA;CACnB,CAAA;AAED,MAAM,MAAM,cAAc,GAAG;IAC5B;;;;OAIG;IACH,IAAI,CAAC,EAAE,WAAW,CAAA;IAElB;;;;OAIG;IACH,WAAW,CAAC,EAAE,OAAO,CAAA;IAErB;;OAEG;IACH,KAAK,CAAC,EAAE,kBAAkB,CAAA;CAC1B,CAAA;AAED,MAAM,MAAM,kBAAkB,GAAG;IAChC;;OAEG;IACH,IAAI,EAAE,MAAM,CAAA;IAEZ;;OAEG;IACH,WAAW,CAAC,EAAE,MAAM,CAAA;IAEpB;;OAEG;IACH,SAAS,CAAC,EAAE,CAAC,KAAK,EAAE,MAAM,KAAK,MAAM,GAAG,SAAS,CAAA;CACjD,CAAA;AAED,MAAM,MAAM,oBAAoB,GAAG;IAClC;;;;OAIG;IACH,MAAM,CAAC,EAAE,OAAO,CAAA;CAChB,CAAA;AAED,MAAM,MAAM,eAAe,GAAG;IAC7B;;;;OAIG;IACH,OAAO,CAAC,EAAE,MAAM,IAAI,CAAA;IAEpB;;;;OAIG;IACH,OAAO,CAAC,EAAE,MAAM,OAAO,GAAG,IAAI,CAAA;IAE9B;;;;;OAKG;IACH,QAAQ,CAAC,EAAE,CAAC,GAAG,EAAE,MAAM,KAAK,IAAI,CAAA;CAChC,CAAA"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"QTextArea.vue.d.ts","sourceRoot":"","sources":["../../../src/components/QTextArea/QTextArea.vue"],"names":[],"mappings":"AAiDA;
|
|
1
|
+
{"version":3,"file":"QTextArea.vue.d.ts","sourceRoot":"","sources":["../../../src/components/QTextArea/QTextArea.vue"],"names":[],"mappings":"AAiDA;AAsHC,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,SAAS,CAAA;AAO7C,KAAK,WAAW,GAAG,cAAc,CAAC;AA2DnC,KAAK,iBAAiB,GAAG;IACzB,UAAU,CAAC,EAAE,MAAM,CAAC;CACnB,GAAG,WAAW,CAAC;AAKhB,iBAAS,cAAc;WA4GT,OAAO,IAA6B;;iCAhBb,GAAG;gCACJ,GAAG;yBACV,GAAG;wBACJ,GAAG;wBACF,GAAG;;;;;;EAiB/B;AAgBD,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,11 +1,11 @@
|
|
|
1
|
-
import { defineComponent as
|
|
2
|
-
import { QField as
|
|
3
|
-
import { useId as
|
|
4
|
-
import { useTextareaAutosize as
|
|
5
|
-
const
|
|
1
|
+
import { defineComponent as h, mergeModels as z, useModel as x, computed as t, watch as g, toRef as w, ref as q, onBeforeUnmount as $, createBlock as B, openBlock as v, unref as n, normalizeClass as k, createSlots as M, withCtx as a, withDirectives as V, createElementVNode as P, mergeProps as R, toHandlers as A, vModelText as C, renderSlot as r } from "vue";
|
|
2
|
+
import { QField as H } from "../QField/index.js";
|
|
3
|
+
import { useId as L } from "../../composables/uid.js";
|
|
4
|
+
import { useTextareaAutosize as T } from "../../composables/useTextareaAutosize/index.js";
|
|
5
|
+
const I = ["id", "required", "placeholder", "readonly", "disabled", "maxlength", "rows", "cols", "resize", "wrap"], E = /* @__PURE__ */ h({
|
|
6
6
|
inheritAttrs: !1,
|
|
7
7
|
__name: "QTextArea",
|
|
8
|
-
props: /* @__PURE__ */
|
|
8
|
+
props: /* @__PURE__ */ z({
|
|
9
9
|
id: {},
|
|
10
10
|
class: {},
|
|
11
11
|
label: {},
|
|
@@ -29,22 +29,22 @@ const L = ["id", "required", "placeholder", "readonly", "disabled", "maxlength",
|
|
|
29
29
|
}),
|
|
30
30
|
emits: ["update:modelValue"],
|
|
31
31
|
setup(i) {
|
|
32
|
-
const e = i, s =
|
|
32
|
+
const e = i, s = x(i, "modelValue"), d = t({
|
|
33
33
|
get: () => s.value,
|
|
34
34
|
set: (l) => {
|
|
35
35
|
const o = e.maxLength;
|
|
36
36
|
s.value = o ? l == null ? void 0 : l.slice(0, o) : l;
|
|
37
37
|
}
|
|
38
38
|
});
|
|
39
|
-
|
|
40
|
-
const p =
|
|
39
|
+
g(s, (l) => d.value = l, { immediate: !0 });
|
|
40
|
+
const p = L(w(e, "id")), m = t(
|
|
41
41
|
() => e.readonly || e.disabled ? void 0 : e.placeholder
|
|
42
|
-
), f = t(() => ({ input: e.autosize ? c : null })), u =
|
|
42
|
+
), f = t(() => ({ input: e.autosize ? c : null })), u = q(), { triggerResize: c, stop: b } = T({
|
|
43
43
|
element: t(() => e.autosize ? u.value : void 0),
|
|
44
44
|
styleProp: "minHeight"
|
|
45
45
|
});
|
|
46
|
-
return (l, o) => (
|
|
47
|
-
class:
|
|
46
|
+
return $(b), (l, o) => (v(), B(n(H), {
|
|
47
|
+
class: k(["q-text-area", e.class]),
|
|
48
48
|
for: n(p),
|
|
49
49
|
label: e.label,
|
|
50
50
|
"label-position": e.labelPosition,
|
|
@@ -52,7 +52,7 @@ const L = ["id", "required", "placeholder", "readonly", "disabled", "maxlength",
|
|
|
52
52
|
readonly: e.readonly,
|
|
53
53
|
disabled: e.disabled,
|
|
54
54
|
required: e.required
|
|
55
|
-
},
|
|
55
|
+
}, M({
|
|
56
56
|
"label.prepend": a(() => [
|
|
57
57
|
r(l.$slots, "label.prepend")
|
|
58
58
|
]),
|
|
@@ -60,11 +60,11 @@ const L = ["id", "required", "placeholder", "readonly", "disabled", "maxlength",
|
|
|
60
60
|
r(l.$slots, "label.append")
|
|
61
61
|
]),
|
|
62
62
|
default: a(() => [
|
|
63
|
-
|
|
63
|
+
V(P("textarea", R({
|
|
64
64
|
id: n(p),
|
|
65
65
|
ref_key: "textareaRef",
|
|
66
66
|
ref: u,
|
|
67
|
-
"onUpdate:modelValue": o[0] || (o[0] = (
|
|
67
|
+
"onUpdate:modelValue": o[0] || (o[0] = (y) => d.value = y),
|
|
68
68
|
class: "q-text-area__input",
|
|
69
69
|
required: e.required,
|
|
70
70
|
placeholder: m.value,
|
|
@@ -75,8 +75,8 @@ const L = ["id", "required", "placeholder", "readonly", "disabled", "maxlength",
|
|
|
75
75
|
cols: e.cols,
|
|
76
76
|
resize: e.resize,
|
|
77
77
|
wrap: e.wrap
|
|
78
|
-
}, l.$attrs,
|
|
79
|
-
[
|
|
78
|
+
}, l.$attrs, A(f.value, !0)), null, 16, I), [
|
|
79
|
+
[C, d.value]
|
|
80
80
|
])
|
|
81
81
|
]),
|
|
82
82
|
_: 2
|
|
@@ -107,5 +107,5 @@ const L = ["id", "required", "placeholder", "readonly", "disabled", "maxlength",
|
|
|
107
107
|
}
|
|
108
108
|
});
|
|
109
109
|
export {
|
|
110
|
-
|
|
110
|
+
E as default
|
|
111
111
|
};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/composables/useDialog/index.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,EACX,YAAY,EACZ,cAAc,EACd,eAAe,EACf,MAAM,mCAAmC,CAAA;AAS1C;;;;GAIG;AACH,wBAAgB,SAAS;uBAWhB,YAAY,OACd,MAAM,YACD,cAAc,aACb,eAAe;uBAyBD,MAAM;;;;;;;;;;;;;;;;;;;;;;;;;;;;0BAmBm7B,CAAC
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/composables/useDialog/index.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,EACX,YAAY,EACZ,cAAc,EACd,eAAe,EACf,MAAM,mCAAmC,CAAA;AAS1C;;;;GAIG;AACH,wBAAgB,SAAS;uBAWhB,YAAY,OACd,MAAM,YACD,cAAc,aACb,eAAe;uBAyBD,MAAM;;;;;;;;;;;;;;;;;;;;;;;;;;;;0BAmBm7B,CAAC;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;EADp9B"}
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
import { ComputedRef } from 'vue';
|
|
2
|
+
interface UseTextareaAutosizeOptions {
|
|
3
|
+
element: ComputedRef<HTMLTextAreaElement | undefined>;
|
|
4
|
+
styleProp?: 'height' | 'minHeight';
|
|
5
|
+
}
|
|
6
|
+
export declare function useTextareaAutosize(options: UseTextareaAutosizeOptions): {
|
|
7
|
+
triggerResize: () => void;
|
|
8
|
+
stop: () => void;
|
|
9
|
+
};
|
|
10
|
+
export {};
|
|
11
|
+
//# sourceMappingURL=index.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/composables/useTextareaAutosize/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAS,KAAK,WAAW,EAAE,MAAM,KAAK,CAAA;AAE7C,UAAU,0BAA0B;IACnC,OAAO,EAAE,WAAW,CAAC,mBAAmB,GAAG,SAAS,CAAC,CAAA;IACrD,SAAS,CAAC,EAAE,QAAQ,GAAG,WAAW,CAAA;CAClC;AAED,wBAAgB,mBAAmB,CAAC,OAAO,EAAE,0BAA0B;;;EA+BtE"}
|
|
@@ -0,0 +1,22 @@
|
|
|
1
|
+
import { watch as l } from "vue";
|
|
2
|
+
function i(r) {
|
|
3
|
+
const { element: e, styleProp: s = "height" } = r, o = () => {
|
|
4
|
+
const t = e.value;
|
|
5
|
+
if (!t) return;
|
|
6
|
+
t.style[s] = "auto";
|
|
7
|
+
const a = t.scrollHeight;
|
|
8
|
+
t.style[s] = `${a}px`;
|
|
9
|
+
}, c = l(e, o), n = l(() => {
|
|
10
|
+
var t;
|
|
11
|
+
return (t = e.value) == null ? void 0 : t.value;
|
|
12
|
+
}, o);
|
|
13
|
+
return {
|
|
14
|
+
triggerResize: o,
|
|
15
|
+
stop: () => {
|
|
16
|
+
c(), n();
|
|
17
|
+
}
|
|
18
|
+
};
|
|
19
|
+
}
|
|
20
|
+
export {
|
|
21
|
+
i as useTextareaAutosize
|
|
22
|
+
};
|
package/package.json
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@quidgest/ui",
|
|
3
3
|
"description": "Quidgest's UI framework",
|
|
4
|
-
"version": "0.16.
|
|
4
|
+
"version": "0.16.70",
|
|
5
5
|
"private": false,
|
|
6
6
|
"type": "module",
|
|
7
7
|
"author": "Quidgest",
|
|
@@ -72,8 +72,6 @@
|
|
|
72
72
|
},
|
|
73
73
|
"dependencies": {
|
|
74
74
|
"@vuepic/vue-datepicker": "^11.0.3",
|
|
75
|
-
"@vueuse/core": "^13.0.0",
|
|
76
|
-
"@vueuse/integrations": "^13.0.0",
|
|
77
75
|
"maska": "^3.1.0",
|
|
78
76
|
"uuid": "^13.0.0"
|
|
79
77
|
},
|
|
@@ -1,85 +0,0 @@
|
|
|
1
|
-
import { toRef as y, isClient as x, tryOnScopeDispose as _ } from "../shared/index.js";
|
|
2
|
-
import { noop as C } from "../shared/index.js";
|
|
3
|
-
import { shallowRef as m, watch as v, nextTick as b, toValue as h, computed as w, getCurrentInstance as R, onMounted as z } from "vue";
|
|
4
|
-
const p = x ? window : void 0;
|
|
5
|
-
function g(e) {
|
|
6
|
-
var t;
|
|
7
|
-
const r = h(e);
|
|
8
|
-
return (t = r == null ? void 0 : r.$el) != null ? t : r;
|
|
9
|
-
}
|
|
10
|
-
function A() {
|
|
11
|
-
const e = m(!1), t = R();
|
|
12
|
-
return t && z(() => {
|
|
13
|
-
e.value = !0;
|
|
14
|
-
}, t), e;
|
|
15
|
-
}
|
|
16
|
-
function O(e) {
|
|
17
|
-
const t = A();
|
|
18
|
-
return w(() => (t.value, !!e()));
|
|
19
|
-
}
|
|
20
|
-
function M(e, t, r = {}) {
|
|
21
|
-
const { window: d = p, ...u } = r;
|
|
22
|
-
let l;
|
|
23
|
-
const o = O(() => d && "ResizeObserver" in d), a = () => {
|
|
24
|
-
l && (l.disconnect(), l = void 0);
|
|
25
|
-
}, f = w(() => {
|
|
26
|
-
const i = h(e);
|
|
27
|
-
return Array.isArray(i) ? i.map((s) => g(s)) : [g(i)];
|
|
28
|
-
}), c = v(
|
|
29
|
-
f,
|
|
30
|
-
(i) => {
|
|
31
|
-
if (a(), o.value && d) {
|
|
32
|
-
l = new ResizeObserver(t);
|
|
33
|
-
for (const s of i)
|
|
34
|
-
s && l.observe(s, u);
|
|
35
|
-
}
|
|
36
|
-
},
|
|
37
|
-
{ immediate: !0, flush: "post" }
|
|
38
|
-
), n = () => {
|
|
39
|
-
a(), c();
|
|
40
|
-
};
|
|
41
|
-
return _(n), {
|
|
42
|
-
isSupported: o,
|
|
43
|
-
stop: n
|
|
44
|
-
};
|
|
45
|
-
}
|
|
46
|
-
function S(e = p, t) {
|
|
47
|
-
e && typeof e.requestAnimationFrame == "function" ? e.requestAnimationFrame(t) : t();
|
|
48
|
-
}
|
|
49
|
-
function F(e = {}) {
|
|
50
|
-
var t, r;
|
|
51
|
-
const { window: d = p } = e, u = y(e == null ? void 0 : e.element), l = y((t = e == null ? void 0 : e.input) != null ? t : ""), o = (r = e == null ? void 0 : e.styleProp) != null ? r : "height", a = m(1), f = m(0);
|
|
52
|
-
function c() {
|
|
53
|
-
var n;
|
|
54
|
-
if (!u.value)
|
|
55
|
-
return;
|
|
56
|
-
let i = "";
|
|
57
|
-
u.value.style[o] = "1px", a.value = (n = u.value) == null ? void 0 : n.scrollHeight;
|
|
58
|
-
const s = h(e == null ? void 0 : e.styleTarget);
|
|
59
|
-
s ? s.style[o] = `${a.value}px` : i = `${a.value}px`, u.value.style[o] = i;
|
|
60
|
-
}
|
|
61
|
-
return v([l, u], () => b(c), { immediate: !0 }), v(a, () => {
|
|
62
|
-
var n;
|
|
63
|
-
return (n = e == null ? void 0 : e.onResize) == null ? void 0 : n.call(e);
|
|
64
|
-
}), M(u, ([{ contentRect: n }]) => {
|
|
65
|
-
f.value !== n.width && S(d, () => {
|
|
66
|
-
f.value = n.width, c();
|
|
67
|
-
});
|
|
68
|
-
}), e != null && e.watch && v(e.watch, c, { immediate: !0, deep: !0 }), {
|
|
69
|
-
textarea: u,
|
|
70
|
-
input: l,
|
|
71
|
-
triggerResize: c
|
|
72
|
-
};
|
|
73
|
-
}
|
|
74
|
-
export {
|
|
75
|
-
p as defaultWindow,
|
|
76
|
-
x as isClient,
|
|
77
|
-
C as noop,
|
|
78
|
-
y as toRef,
|
|
79
|
-
_ as tryOnScopeDispose,
|
|
80
|
-
g as unrefElement,
|
|
81
|
-
A as useMounted,
|
|
82
|
-
M as useResizeObserver,
|
|
83
|
-
O as useSupported,
|
|
84
|
-
F as useTextareaAutosize
|
|
85
|
-
};
|
|
@@ -1,20 +0,0 @@
|
|
|
1
|
-
import { toRef as n, readonly as t, ref as f, customRef as r, getCurrentScope as i, onScopeDispose as c } from "vue";
|
|
2
|
-
function s(e) {
|
|
3
|
-
return i() ? (c(e), !0) : !1;
|
|
4
|
-
}
|
|
5
|
-
const l = typeof window < "u" && typeof document < "u";
|
|
6
|
-
typeof WorkerGlobalScope < "u" && globalThis instanceof WorkerGlobalScope;
|
|
7
|
-
const p = () => {
|
|
8
|
-
};
|
|
9
|
-
function d(...e) {
|
|
10
|
-
if (e.length !== 1)
|
|
11
|
-
return n(...e);
|
|
12
|
-
const o = e[0];
|
|
13
|
-
return typeof o == "function" ? t(r(() => ({ get: o, set: p }))) : f(o);
|
|
14
|
-
}
|
|
15
|
-
export {
|
|
16
|
-
l as isClient,
|
|
17
|
-
p as noop,
|
|
18
|
-
d as toRef,
|
|
19
|
-
s as tryOnScopeDispose
|
|
20
|
-
};
|