@quidgest/ui 0.14.5 → 0.14.7
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/manifest/components.json +2 -0
- package/dist/ui.css +162 -25
- package/dist/ui.esm.js +1363 -1103
- package/dist/ui.js +44 -7
- package/dist/ui.min.css +1 -1
- package/dist/ui.min.js +143 -119
- package/dist/ui.scss +175 -26
- package/esm/components/QAccordion/QAccordion.d.ts +27 -0
- package/esm/components/QAccordion/QAccordion.d.ts.map +1 -0
- package/esm/components/QAccordion/QAccordion.vue.js +27 -0
- package/esm/components/QAccordion/QAccordion.vue2.js +4 -0
- package/esm/components/QAccordion/index.d.ts +4 -0
- package/esm/components/QAccordion/index.d.ts.map +1 -0
- package/esm/components/QAccordion/index.js +6 -0
- package/esm/components/QAccordion/types.d.ts +7 -0
- package/esm/components/QAccordion/types.d.ts.map +1 -0
- package/esm/components/QBadge/QBadge.d.ts +3 -2
- package/esm/components/QBadge/QBadge.d.ts.map +1 -1
- package/esm/components/QBadge/QBadge.vue.js +11 -11
- package/esm/components/QButton/QButton.d.ts +3 -2
- package/esm/components/QButton/QButton.d.ts.map +1 -1
- package/esm/components/QButton/QButton.vue.js +14 -14
- package/esm/components/QButtonGroup/QButtonGroup.d.ts +3 -2
- package/esm/components/QButtonGroup/QButtonGroup.d.ts.map +1 -1
- package/esm/components/QButtonGroup/QButtonGroup.vue.js +3 -3
- package/esm/components/QButtonToggle/QButtonToggle.d.ts +7 -6
- package/esm/components/QButtonToggle/QButtonToggle.d.ts.map +1 -1
- package/esm/components/QButtonToggle/QButtonToggle.vue.js +6 -6
- package/esm/components/QCard/QCard.d.ts +3 -2
- package/esm/components/QCard/QCard.d.ts.map +1 -1
- package/esm/components/QCard/QCard.vue.js +30 -30
- package/esm/components/QCheckbox/QCheckbox.d.ts +4 -4
- package/esm/components/QCheckbox/QCheckbox.d.ts.map +1 -1
- package/esm/components/QCheckbox/QCheckbox.vue.js +4 -4
- package/esm/components/QCollapsible/QCollapsible.d.ts +36 -0
- package/esm/components/QCollapsible/QCollapsible.d.ts.map +1 -0
- package/esm/components/QCollapsible/QCollapsible.vue.js +143 -0
- package/esm/components/QCollapsible/QCollapsible.vue2.js +4 -0
- package/esm/components/QCollapsible/index.d.ts +6 -0
- package/esm/components/QCollapsible/index.d.ts.map +1 -0
- package/esm/components/QCollapsible/index.js +6 -0
- package/esm/components/QCollapsible/types.d.ts +43 -0
- package/esm/components/QCollapsible/types.d.ts.map +1 -0
- package/esm/components/QCollapsible/types.js +8 -0
- package/esm/components/QCombobox/QCombobox.d.ts +40 -39
- package/esm/components/QCombobox/QCombobox.d.ts.map +1 -1
- package/esm/components/QCombobox/QCombobox.vue.js +80 -80
- package/esm/components/QDialog/QDialog.d.ts +6 -5
- package/esm/components/QDialog/QDialog.d.ts.map +1 -1
- package/esm/components/QDialog/QDialog.vue.js +7 -7
- package/esm/components/QField/QField.d.ts +2 -1
- package/esm/components/QField/QField.d.ts.map +1 -1
- package/esm/components/QField/QField.vue.js +9 -9
- package/esm/components/QIcon/InlineSvg.d.ts +1 -1
- package/esm/components/QIcon/QIcon.d.ts.map +1 -1
- package/esm/components/QIcon/QIcon.vue.js +9 -9
- package/esm/components/QIcon/QIconFont.d.ts +2 -2
- package/esm/components/QIcon/QIconFont.d.ts.map +1 -1
- package/esm/components/QIcon/QIconFont.vue.js +5 -5
- package/esm/components/QIcon/QIconImg.d.ts +1 -1
- package/esm/components/QIcon/QIconImg.d.ts.map +1 -1
- package/esm/components/QIcon/QIconImg.vue.js +5 -5
- package/esm/components/QIcon/QIconSvg.d.ts +2 -2
- package/esm/components/QIcon/QIconSvg.d.ts.map +1 -1
- package/esm/components/QIcon/QIconSvg.vue.js +17 -17
- package/esm/components/QInputGroup/QInputGroup.d.ts +2 -1
- package/esm/components/QInputGroup/QInputGroup.d.ts.map +1 -1
- package/esm/components/QInputGroup/QInputGroup.vue.js +24 -24
- package/esm/components/QLineLoader/QLineLoader.d.ts +1 -1
- package/esm/components/QLineLoader/QLineLoader.d.ts.map +1 -1
- package/esm/components/QLineLoader/QLineLoader.vue.js +4 -4
- package/esm/components/QList/QList.d.ts +6 -5
- package/esm/components/QList/QList.d.ts.map +1 -1
- package/esm/components/QList/QList.vue.js +1 -1
- package/esm/components/QList/QListItem.d.ts +3 -2
- package/esm/components/QList/QListItem.d.ts.map +1 -1
- package/esm/components/QList/QListItem.vue.js +18 -18
- package/esm/components/QList/QListItemGroup.d.ts +3 -2
- package/esm/components/QList/QListItemGroup.d.ts.map +1 -1
- package/esm/components/QOverlay/QOverlay.d.ts +6 -5
- package/esm/components/QOverlay/QOverlay.d.ts.map +1 -1
- package/esm/components/QOverlay/QOverlay.vue.js +148 -138
- package/esm/components/QPopover/QPopover.d.ts +6 -5
- package/esm/components/QPopover/QPopover.d.ts.map +1 -1
- package/esm/components/QPropertyList/QPropertyList.d.ts +3 -2
- package/esm/components/QPropertyList/QPropertyList.d.ts.map +1 -1
- package/esm/components/QPropertyList/QPropertyList.vue.js +22 -22
- package/esm/components/QPropertyList/QPropertyListGroup.d.ts +1 -1
- package/esm/components/QPropertyList/QPropertyListGroup.d.ts.map +1 -1
- package/esm/components/QPropertyList/QPropertyListPanel.d.ts +3 -2
- package/esm/components/QPropertyList/QPropertyListPanel.d.ts.map +1 -1
- package/esm/components/QPropertyList/QPropertyListPanel.vue.js +4 -4
- package/esm/components/QPropertyList/QPropertyListRow.d.ts +3 -2
- package/esm/components/QPropertyList/QPropertyListRow.d.ts.map +1 -1
- package/esm/components/QRemoveScrollBar/QRemoveScrollBar.d.ts +24 -0
- package/esm/components/QRemoveScrollBar/QRemoveScrollBar.d.ts.map +1 -0
- package/esm/components/QRemoveScrollBar/QRemoveScrollBar.vue.js +72 -0
- package/esm/components/QRemoveScrollBar/QRemoveScrollBar.vue2.js +4 -0
- package/esm/components/QRemoveScrollBar/constants.d.ts +10 -0
- package/esm/components/QRemoveScrollBar/constants.d.ts.map +1 -0
- package/esm/components/QRemoveScrollBar/constants.js +8 -0
- package/esm/components/QRemoveScrollBar/index.d.ts +4 -0
- package/esm/components/QRemoveScrollBar/index.d.ts.map +1 -0
- package/esm/components/QRemoveScrollBar/index.js +6 -0
- package/esm/components/QRemoveScrollBar/types.d.ts +18 -0
- package/esm/components/QRemoveScrollBar/types.d.ts.map +1 -0
- package/esm/components/QRemoveScrollBar/utils/gap.d.ts +15 -0
- package/esm/components/QRemoveScrollBar/utils/gap.d.ts.map +1 -0
- package/esm/components/QRemoveScrollBar/utils/gap.js +23 -0
- package/esm/components/QRemoveScrollBar/utils/stylesheet.d.ts +5 -0
- package/esm/components/QRemoveScrollBar/utils/stylesheet.d.ts.map +1 -0
- package/esm/components/QRemoveScrollBar/utils/stylesheet.js +24 -0
- package/esm/components/QSelect/QSelect.d.ts +11 -10
- package/esm/components/QSelect/QSelect.d.ts.map +1 -1
- package/esm/components/QSelect/QSelect.vue.js +33 -33
- package/esm/components/QSkeletonLoader/QSkeletonLoader.d.ts +1 -1
- package/esm/components/QSkeletonLoader/QSkeletonLoader.d.ts.map +1 -1
- package/esm/components/QSkeletonLoader/QSkeletonLoader.vue.js +11 -11
- package/esm/components/QSpinnerLoader/QSpinnerLoader.d.ts +1 -1
- package/esm/components/QSpinnerLoader/QSpinnerLoader.d.ts.map +1 -1
- package/esm/components/QSpinnerLoader/QSpinnerLoader.vue.js +6 -6
- package/esm/components/QTextField/QTextField.d.ts +7 -6
- package/esm/components/QTextField/QTextField.d.ts.map +1 -1
- package/esm/components/QTextField/QTextField.vue.js +15 -15
- package/esm/components/QThemeProvider/QThemeProvider.d.ts +3 -2
- package/esm/components/QThemeProvider/QThemeProvider.d.ts.map +1 -1
- package/esm/components/QTooltip/QTooltip.d.ts +7 -6
- package/esm/components/QTooltip/QTooltip.d.ts.map +1 -1
- package/esm/components/QTooltip/QTooltip.vue.js +15 -15
- package/esm/components/index.d.ts +2 -0
- package/esm/components/index.d.ts.map +1 -1
- package/esm/components/index.js +56 -52
- package/esm/composables/defaults.js +5 -5
- package/esm/composables/group.d.ts +16 -0
- package/esm/composables/group.d.ts.map +1 -0
- package/esm/composables/group.js +34 -0
- package/esm/composables/overlay.js +11 -11
- package/esm/framework.js +2 -2
- package/esm/index.d.ts +2 -0
- package/esm/utils/color.js +6 -6
- package/package.json +34 -30
package/esm/components/index.js
CHANGED
|
@@ -1,54 +1,58 @@
|
|
|
1
|
-
import {
|
|
2
|
-
import {
|
|
3
|
-
import {
|
|
4
|
-
import {
|
|
5
|
-
import {
|
|
6
|
-
import {
|
|
7
|
-
import {
|
|
8
|
-
import {
|
|
9
|
-
import {
|
|
10
|
-
import {
|
|
11
|
-
import {
|
|
12
|
-
import {
|
|
13
|
-
import {
|
|
14
|
-
import {
|
|
15
|
-
import {
|
|
16
|
-
import {
|
|
17
|
-
import {
|
|
18
|
-
import {
|
|
19
|
-
import {
|
|
20
|
-
import {
|
|
21
|
-
import {
|
|
22
|
-
import {
|
|
1
|
+
import { QAccordion as e } from "./QAccordion/index.js";
|
|
2
|
+
import { QBadge as p } from "./QBadge/index.js";
|
|
3
|
+
import { QButton as m } from "./QButton/index.js";
|
|
4
|
+
import { QButtonGroup as f } from "./QButtonGroup/index.js";
|
|
5
|
+
import { QButtonToggle as n } from "./QButtonToggle/index.js";
|
|
6
|
+
import { QCard as L } from "./QCard/index.js";
|
|
7
|
+
import { QCheckbox as d } from "./QCheckbox/index.js";
|
|
8
|
+
import { QCollapsible as s } from "./QCollapsible/index.js";
|
|
9
|
+
import { QCombobox as I } from "./QCombobox/index.js";
|
|
10
|
+
import { QDialog as g } from "./QDialog/index.js";
|
|
11
|
+
import { QField as b } from "./QField/index.js";
|
|
12
|
+
import { QIcon as B, QIconFont as C, QIconImg as G, QIconSvg as S } from "./QIcon/index.js";
|
|
13
|
+
import { QInputGroup as F } from "./QInputGroup/index.js";
|
|
14
|
+
import { QLineLoader as k } from "./QLineLoader/index.js";
|
|
15
|
+
import { QList as A, QListItem as D, QListItemGroup as O } from "./QList/index.js";
|
|
16
|
+
import { QOverlay as j } from "./QOverlay/index.js";
|
|
17
|
+
import { QPopover as z } from "./QPopover/index.js";
|
|
18
|
+
import { QPropertyList as H, QPropertyListGroup as J, QPropertyListPanel as K, QPropertyListRow as M } from "./QPropertyList/index.js";
|
|
19
|
+
import { QSelect as U } from "./QSelect/index.js";
|
|
20
|
+
import { QSkeletonLoader as W } from "./QSkeletonLoader/index.js";
|
|
21
|
+
import { QSpinnerLoader as Y } from "./QSpinnerLoader/index.js";
|
|
22
|
+
import { QTextField as _ } from "./QTextField/index.js";
|
|
23
|
+
import { QThemeProvider as oo } from "./QThemeProvider/index.js";
|
|
24
|
+
import { QTooltip as eo } from "./QTooltip/index.js";
|
|
23
25
|
export {
|
|
24
|
-
e as
|
|
25
|
-
p as
|
|
26
|
-
m as
|
|
27
|
-
f as
|
|
28
|
-
n as
|
|
29
|
-
|
|
30
|
-
d as
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
g as
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
F as
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
D as
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
z as
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
M as
|
|
50
|
-
U as
|
|
51
|
-
W as
|
|
52
|
-
Y as
|
|
53
|
-
_ as
|
|
26
|
+
e as QAccordion,
|
|
27
|
+
p as QBadge,
|
|
28
|
+
m as QButton,
|
|
29
|
+
f as QButtonGroup,
|
|
30
|
+
n as QButtonToggle,
|
|
31
|
+
L as QCard,
|
|
32
|
+
d as QCheckbox,
|
|
33
|
+
s as QCollapsible,
|
|
34
|
+
I as QCombobox,
|
|
35
|
+
g as QDialog,
|
|
36
|
+
b as QField,
|
|
37
|
+
B as QIcon,
|
|
38
|
+
C as QIconFont,
|
|
39
|
+
G as QIconImg,
|
|
40
|
+
S as QIconSvg,
|
|
41
|
+
F as QInputGroup,
|
|
42
|
+
k as QLineLoader,
|
|
43
|
+
A as QList,
|
|
44
|
+
D as QListItem,
|
|
45
|
+
O as QListItemGroup,
|
|
46
|
+
j as QOverlay,
|
|
47
|
+
z as QPopover,
|
|
48
|
+
H as QPropertyList,
|
|
49
|
+
J as QPropertyListGroup,
|
|
50
|
+
K as QPropertyListPanel,
|
|
51
|
+
M as QPropertyListRow,
|
|
52
|
+
U as QSelect,
|
|
53
|
+
W as QSkeletonLoader,
|
|
54
|
+
Y as QSpinnerLoader,
|
|
55
|
+
_ as QTextField,
|
|
56
|
+
oo as QThemeProvider,
|
|
57
|
+
eo as QTooltip
|
|
54
58
|
};
|
|
@@ -1,20 +1,20 @@
|
|
|
1
1
|
import { isEmpty as s } from "../utils/isEmpty.js";
|
|
2
|
-
import { merge as
|
|
3
|
-
import { getCurrentInstance as
|
|
2
|
+
import { merge as f } from "../utils/merge.js";
|
|
3
|
+
import { getCurrentInstance as d, computed as a, ref as m, provide as p, inject as v } from "vue";
|
|
4
4
|
const i = "q-defaults";
|
|
5
5
|
function E() {
|
|
6
6
|
var r, u;
|
|
7
|
-
const e =
|
|
7
|
+
const e = d();
|
|
8
8
|
if (!e)
|
|
9
9
|
throw new Error("[Quidgest UI] useDefaults must be called from inside a setup function");
|
|
10
10
|
const t = e.type.name ?? e.type.__name;
|
|
11
11
|
if (!t) throw new Error("[Quidgest UI] Could not determine component name");
|
|
12
12
|
const n = l(), o = (r = n.value) == null ? void 0 : r.Global, c = (u = n.value) == null ? void 0 : u[t];
|
|
13
|
-
return
|
|
13
|
+
return a(() => f(o, c));
|
|
14
14
|
}
|
|
15
15
|
function I(e) {
|
|
16
16
|
if (s(e)) return;
|
|
17
|
-
const t = l(), n =
|
|
17
|
+
const t = l(), n = m(e), o = a(() => s(n.value) ? t.value : f(t.value, n.value));
|
|
18
18
|
p(i, o);
|
|
19
19
|
}
|
|
20
20
|
function l() {
|
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
import { ComputedRef, Ref } from 'vue';
|
|
2
|
+
export interface Group {
|
|
3
|
+
active: Ref<unknown>;
|
|
4
|
+
multiple: ComputedRef<boolean>;
|
|
5
|
+
}
|
|
6
|
+
export interface GroupProps {
|
|
7
|
+
active?: Ref<unknown>;
|
|
8
|
+
multiple?: Ref<boolean>;
|
|
9
|
+
}
|
|
10
|
+
export interface GroupProvide {
|
|
11
|
+
toggle: () => void;
|
|
12
|
+
isActive: ComputedRef<boolean>;
|
|
13
|
+
}
|
|
14
|
+
export declare function useGroup(options: GroupProps): Group;
|
|
15
|
+
export declare function useGroupItem(itemId: string): GroupProvide | undefined;
|
|
16
|
+
//# sourceMappingURL=group.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"group.d.ts","sourceRoot":"","sources":["../../src/composables/group.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAE,WAAW,EAAE,GAAG,EAAE,MAAM,KAAK,CAAA;AAO3C,MAAM,WAAW,KAAK;IACrB,MAAM,EAAE,GAAG,CAAC,OAAO,CAAC,CAAA;IACpB,QAAQ,EAAE,WAAW,CAAC,OAAO,CAAC,CAAA;CAC9B;AAED,MAAM,WAAW,UAAU;IAC1B,MAAM,CAAC,EAAE,GAAG,CAAC,OAAO,CAAC,CAAA;IACrB,QAAQ,CAAC,EAAE,GAAG,CAAC,OAAO,CAAC,CAAA;CACvB;AAED,MAAM,WAAW,YAAY;IAC5B,MAAM,EAAE,MAAM,IAAI,CAAA;IAClB,QAAQ,EAAE,WAAW,CAAC,OAAO,CAAC,CAAA;CAC9B;AAED,wBAAgB,QAAQ,CAAC,OAAO,EAAE,UAAU,GAAG,KAAK,CAoBnD;AAED,wBAAgB,YAAY,CAAC,MAAM,EAAE,MAAM,GAAG,YAAY,GAAG,SAAS,CAuBrE"}
|
|
@@ -0,0 +1,34 @@
|
|
|
1
|
+
import { ref as c, computed as t, watch as n, provide as s, inject as f } from "vue";
|
|
2
|
+
const i = "q-group";
|
|
3
|
+
function p(u) {
|
|
4
|
+
var l, v;
|
|
5
|
+
const e = {
|
|
6
|
+
active: c(((l = u.active) == null ? void 0 : l.value) ?? ((v = u.multiple) == null ? void 0 : v.value) ? [] : null),
|
|
7
|
+
multiple: t(() => {
|
|
8
|
+
var a;
|
|
9
|
+
return ((a = u.multiple) == null ? void 0 : a.value) || !1;
|
|
10
|
+
})
|
|
11
|
+
};
|
|
12
|
+
return n(
|
|
13
|
+
() => e.multiple.value,
|
|
14
|
+
(a) => {
|
|
15
|
+
a && e.active.value ? e.active.value = [e.active.value] : a ? e.active.value = [] : Array.isArray(e.active.value) && e.active.value.length === 1 ? e.active.value = e.active.value[0] : e.active.value = null;
|
|
16
|
+
}
|
|
17
|
+
), s(i, e), e;
|
|
18
|
+
}
|
|
19
|
+
function g(u) {
|
|
20
|
+
const e = f(i, void 0);
|
|
21
|
+
if (!e) return;
|
|
22
|
+
const l = t(() => {
|
|
23
|
+
var a;
|
|
24
|
+
return Array.isArray(e.active.value) ? (a = e.active.value) == null ? void 0 : a.includes(u) : e.active.value === u;
|
|
25
|
+
});
|
|
26
|
+
return { isActive: l, toggle: () => {
|
|
27
|
+
var a;
|
|
28
|
+
Array.isArray(e.active.value) ? l.value ? e.active.value = (a = e.active.value) == null ? void 0 : a.filter((r) => r !== u) : e.active.value.push(u) : e.active.value = u;
|
|
29
|
+
} };
|
|
30
|
+
}
|
|
31
|
+
export {
|
|
32
|
+
p as useGroup,
|
|
33
|
+
g as useGroupItem
|
|
34
|
+
};
|
|
@@ -1,10 +1,10 @@
|
|
|
1
1
|
function M(t, i, n, e) {
|
|
2
|
-
const d = (e == null ? void 0 : e.offset) ?? 0, o = (e == null ? void 0 : e.placement) ?? "bottom",
|
|
2
|
+
const d = (e == null ? void 0 : e.offset) ?? 0, o = (e == null ? void 0 : e.placement) ?? "bottom", u = t.getBoundingClientRect(), s = i.getBoundingClientRect(), g = n == null ? void 0 : n.getBoundingClientRect(), r = b(u, s, o, d), h = k(u, s, r), f = C(h, r, d), m = p(f, s, r);
|
|
3
3
|
let a;
|
|
4
4
|
if (e != null && e.arrow) {
|
|
5
|
-
if (!
|
|
5
|
+
if (!g)
|
|
6
6
|
throw new Error("[Quidgest UI] The arrow element must exist to compute its position");
|
|
7
|
-
a = A(m,
|
|
7
|
+
a = A(m, u, s, g, r);
|
|
8
8
|
}
|
|
9
9
|
return { overlayCoords: m, arrowCoords: a, placement: r };
|
|
10
10
|
}
|
|
@@ -16,13 +16,13 @@ function b(t, i, n, e) {
|
|
|
16
16
|
bottom: "top",
|
|
17
17
|
left: "right",
|
|
18
18
|
right: "left"
|
|
19
|
-
}[o],
|
|
19
|
+
}[o], g = c(
|
|
20
20
|
t,
|
|
21
21
|
i,
|
|
22
22
|
s,
|
|
23
23
|
e
|
|
24
24
|
);
|
|
25
|
-
if (x(
|
|
25
|
+
if (x(g))
|
|
26
26
|
return n;
|
|
27
27
|
const r = O(n);
|
|
28
28
|
return r ? `${s}-${r}` : s;
|
|
@@ -30,7 +30,7 @@ function b(t, i, n, e) {
|
|
|
30
30
|
return n;
|
|
31
31
|
}
|
|
32
32
|
function p(t, i, n) {
|
|
33
|
-
const e = l(n), d = (
|
|
33
|
+
const e = l(n), d = (u, s, g) => Math.min(Math.max(u, s), g), o = { ...t };
|
|
34
34
|
return e === "x" ? o.x = d(t.x, 8, window.innerWidth - i.width - 8) : o.y = d(t.y, 8, window.innerHeight - i.height - 8), o;
|
|
35
35
|
}
|
|
36
36
|
function C(t, i, n) {
|
|
@@ -42,13 +42,13 @@ function C(t, i, n) {
|
|
|
42
42
|
}
|
|
43
43
|
function A(t, i, n, e, d) {
|
|
44
44
|
if (l(d) === "y") {
|
|
45
|
-
const
|
|
45
|
+
const u = i.top + i.height / 2, s = t.y + n.height / 2, g = s - u, r = n.height / 2 - g - e.height / 2 + 2;
|
|
46
46
|
if (r > 0 && r < n.height - e.height)
|
|
47
47
|
return {
|
|
48
48
|
y: r
|
|
49
49
|
};
|
|
50
50
|
} else {
|
|
51
|
-
const
|
|
51
|
+
const u = i.left + i.width / 2, s = t.x + n.width / 2, g = s - u, r = n.width / 2 - g - e.width / 2 + 2;
|
|
52
52
|
if (r > 0 && r < n.width - e.width)
|
|
53
53
|
return {
|
|
54
54
|
x: r
|
|
@@ -56,7 +56,7 @@ function A(t, i, n, e, d) {
|
|
|
56
56
|
}
|
|
57
57
|
}
|
|
58
58
|
function k(t, i, n) {
|
|
59
|
-
const [e, d] = n.split("-"), o = t.x + t.width / 2 - i.width / 2,
|
|
59
|
+
const [e, d] = n.split("-"), o = t.x + t.width / 2 - i.width / 2, u = t.y + t.height / 2 - i.height / 2;
|
|
60
60
|
let s;
|
|
61
61
|
switch (e) {
|
|
62
62
|
case "top":
|
|
@@ -66,10 +66,10 @@ function k(t, i, n) {
|
|
|
66
66
|
s = { x: o, y: t.y + t.height };
|
|
67
67
|
break;
|
|
68
68
|
case "left":
|
|
69
|
-
s = { x: t.x - i.width, y:
|
|
69
|
+
s = { x: t.x - i.width, y: u };
|
|
70
70
|
break;
|
|
71
71
|
case "right":
|
|
72
|
-
s = { x: t.x + t.width, y:
|
|
72
|
+
s = { x: t.x + t.width, y: u };
|
|
73
73
|
break;
|
|
74
74
|
default:
|
|
75
75
|
throw new Error(`[Quidgest UI] Invalid placement value: ${n}`);
|
package/esm/framework.js
CHANGED
|
@@ -3,7 +3,7 @@ import { THEME_SYMBOL as i } from "./composables/theme.js";
|
|
|
3
3
|
import { defaultLightColorScheme as a, defaultDarkColorScheme as h } from "./templates/theme.js";
|
|
4
4
|
import { ref as n, watch as f } from "vue";
|
|
5
5
|
import { generateRootStyle as d } from "./utils/theme.js";
|
|
6
|
-
function
|
|
6
|
+
function v(m = {}) {
|
|
7
7
|
return { install: (o) => {
|
|
8
8
|
const t = m.components || {};
|
|
9
9
|
for (const l in t)
|
|
@@ -43,5 +43,5 @@ function p(m) {
|
|
|
43
43
|
s.className = t.join(" "), s.classList.add(`q-theme--${m}`);
|
|
44
44
|
}
|
|
45
45
|
export {
|
|
46
|
-
|
|
46
|
+
v as createFramework
|
|
47
47
|
};
|
package/esm/index.d.ts
CHANGED
|
@@ -7,12 +7,14 @@ export * from './composables';
|
|
|
7
7
|
//# sourceMappingURL=index.d.ts.map
|
|
8
8
|
declare module '@vue/runtime-core' {
|
|
9
9
|
export interface GlobalComponents {
|
|
10
|
+
QAccordion: typeof import('@quidgest/ui/components')['QAccordion']
|
|
10
11
|
QBadge: typeof import('@quidgest/ui/components')['QBadge']
|
|
11
12
|
QButton: typeof import('@quidgest/ui/components')['QButton']
|
|
12
13
|
QButtonGroup: typeof import('@quidgest/ui/components')['QButtonGroup']
|
|
13
14
|
QButtonToggle: typeof import('@quidgest/ui/components')['QButtonToggle']
|
|
14
15
|
QCard: typeof import('@quidgest/ui/components')['QCard']
|
|
15
16
|
QCheckbox: typeof import('@quidgest/ui/components')['QCheckbox']
|
|
17
|
+
QCollapsible: typeof import('@quidgest/ui/components')['QCollapsible']
|
|
16
18
|
QCombobox: typeof import('@quidgest/ui/components')['QCombobox']
|
|
17
19
|
QDialog: typeof import('@quidgest/ui/components')['QDialog']
|
|
18
20
|
QField: typeof import('@quidgest/ui/components')['QField']
|
package/esm/utils/color.js
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
|
-
function
|
|
1
|
+
function u(t) {
|
|
2
2
|
return /^#([a-fA-F0-9]{6}|[a-fA-F0-9]{3})$/.test(t);
|
|
3
3
|
}
|
|
4
|
-
function
|
|
4
|
+
function o(t) {
|
|
5
5
|
const n = t.match(/^rgb\((\d+),\s*(\d+),\s*(\d+)\)$/);
|
|
6
6
|
if (n) {
|
|
7
7
|
const s = parseInt(n[1], 10), e = parseInt(n[2], 10), r = parseInt(n[3], 10);
|
|
@@ -9,12 +9,12 @@ function u(t) {
|
|
|
9
9
|
}
|
|
10
10
|
}
|
|
11
11
|
function d(t) {
|
|
12
|
-
if (
|
|
12
|
+
if (u(t)) {
|
|
13
13
|
t.length === 4 && (t = "#" + t[1] + t[1] + t[2] + t[2] + t[3] + t[3]);
|
|
14
14
|
const n = parseInt(t.slice(1, 3), 16), s = parseInt(t.slice(3, 5), 16), e = parseInt(t.slice(5, 7), 16);
|
|
15
15
|
return { r: n, g: s, b: e };
|
|
16
16
|
} else {
|
|
17
|
-
const n =
|
|
17
|
+
const n = o(t);
|
|
18
18
|
if (n) return n;
|
|
19
19
|
}
|
|
20
20
|
throw new Error("Invalid color format");
|
|
@@ -51,8 +51,8 @@ function g(t) {
|
|
|
51
51
|
}
|
|
52
52
|
export {
|
|
53
53
|
g as getContrastingColor,
|
|
54
|
-
|
|
54
|
+
u as isValidHex,
|
|
55
55
|
d as parseColor,
|
|
56
56
|
b as rgbToHsl,
|
|
57
|
-
|
|
57
|
+
o as tryParseRgb
|
|
58
58
|
};
|
package/package.json
CHANGED
|
@@ -1,11 +1,14 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@quidgest/ui",
|
|
3
3
|
"description": "Quidgest's UI framework",
|
|
4
|
-
"version": "0.14.
|
|
4
|
+
"version": "0.14.7",
|
|
5
5
|
"private": false,
|
|
6
6
|
"type": "module",
|
|
7
7
|
"author": "Quidgest",
|
|
8
8
|
"license": "MIT",
|
|
9
|
+
"engines": {
|
|
10
|
+
"node": ">=22.0.0"
|
|
11
|
+
},
|
|
9
12
|
"keywords": [
|
|
10
13
|
"vue",
|
|
11
14
|
"component-library",
|
|
@@ -42,52 +45,53 @@
|
|
|
42
45
|
"./*": "./*"
|
|
43
46
|
},
|
|
44
47
|
"devDependencies": {
|
|
45
|
-
"@fortawesome/fontawesome-free": "^6.7.
|
|
46
|
-
"@rollup/plugin-node-resolve": "^
|
|
48
|
+
"@fortawesome/fontawesome-free": "^6.7.2",
|
|
49
|
+
"@rollup/plugin-node-resolve": "^16.0.0",
|
|
47
50
|
"@rollup/plugin-terser": "^0.4.4",
|
|
48
|
-
"@storybook/addon-essentials": "^8.4.
|
|
49
|
-
"@storybook/addon-interactions": "^8.4.
|
|
50
|
-
"@storybook/addon-links": "^8.4.
|
|
51
|
-
"@storybook/blocks": "^8.4.
|
|
52
|
-
"@storybook/manager-api": "^8.4.
|
|
53
|
-
"@storybook/test": "^8.4.
|
|
54
|
-
"@storybook/theming": "^8.4.
|
|
55
|
-
"@storybook/vue3": "^8.4.
|
|
56
|
-
"@storybook/vue3-vite": "^8.4.
|
|
51
|
+
"@storybook/addon-essentials": "^8.4.7",
|
|
52
|
+
"@storybook/addon-interactions": "^8.4.7",
|
|
53
|
+
"@storybook/addon-links": "^8.4.7",
|
|
54
|
+
"@storybook/blocks": "^8.4.7",
|
|
55
|
+
"@storybook/manager-api": "^8.4.7",
|
|
56
|
+
"@storybook/test": "^8.4.7",
|
|
57
|
+
"@storybook/theming": "^8.4.7",
|
|
58
|
+
"@storybook/vue3": "^8.4.7",
|
|
59
|
+
"@storybook/vue3-vite": "^8.4.7",
|
|
57
60
|
"@tsconfig/node20": "^20.1.4",
|
|
58
|
-
"@types/node": "^22.10.
|
|
59
|
-
"@typescript-eslint/eslint-plugin": "^
|
|
60
|
-
"@typescript-eslint/parser": "^
|
|
61
|
+
"@types/node": "^22.10.5",
|
|
62
|
+
"@typescript-eslint/eslint-plugin": "^8.19.0",
|
|
63
|
+
"@typescript-eslint/parser": "^8.19.0",
|
|
61
64
|
"@vitejs/plugin-vue": "^5.2.1",
|
|
62
65
|
"@vitest/coverage-v8": "^2.1.8",
|
|
66
|
+
"@vitest/eslint-plugin": "^1.1.24",
|
|
63
67
|
"@vitest/ui": "^2.1.8",
|
|
64
|
-
"@vue/eslint-config-
|
|
68
|
+
"@vue/eslint-config-prettier": "^10.1.0",
|
|
69
|
+
"@vue/eslint-config-typescript": "^14.2.0",
|
|
65
70
|
"@vue/test-utils": "^2.4.6",
|
|
66
71
|
"@vue/tsconfig": "^0.7.0",
|
|
67
72
|
"acorn-walk": "^8.3.4",
|
|
68
73
|
"autoprefixer": "^10.4.20",
|
|
69
74
|
"cssnano": "^7.0.6",
|
|
70
|
-
"eslint": "^
|
|
71
|
-
"eslint-config-prettier": "^9.1.0",
|
|
75
|
+
"eslint": "^9.17.0",
|
|
72
76
|
"eslint-plugin-prettier": "^5.2.1",
|
|
73
|
-
"eslint-plugin-storybook": "^0.11.
|
|
77
|
+
"eslint-plugin-storybook": "^0.11.2",
|
|
74
78
|
"eslint-plugin-vue": "^9.32.0",
|
|
75
|
-
"happy-dom": "^
|
|
79
|
+
"happy-dom": "^16.3.0",
|
|
76
80
|
"husky": "^9.1.7",
|
|
77
|
-
"lint-staged": "^15.
|
|
81
|
+
"lint-staged": "^15.3.0",
|
|
78
82
|
"postcss": "^8.4.49",
|
|
79
|
-
"prettier": "^3.4.
|
|
83
|
+
"prettier": "^3.4.2",
|
|
80
84
|
"rimraf": "^6.0.1",
|
|
81
|
-
"sass": "^1.
|
|
82
|
-
"storybook": "^8.4.
|
|
83
|
-
"stylelint": "^16.
|
|
85
|
+
"sass": "^1.83.1",
|
|
86
|
+
"storybook": "^8.4.7",
|
|
87
|
+
"stylelint": "^16.12.0",
|
|
84
88
|
"stylelint-config-sass-guidelines": "^12.1.0",
|
|
85
89
|
"typescript": "~5.6.3",
|
|
86
|
-
"vite": "^6.0.
|
|
87
|
-
"vite-plugin-dts": "^4.
|
|
90
|
+
"vite": "^6.0.7",
|
|
91
|
+
"vite-plugin-dts": "^4.4.0",
|
|
88
92
|
"vitest": "^2.1.8",
|
|
89
93
|
"vue-eslint-parser": "^9.4.3",
|
|
90
|
-
"vue-tsc": "^2.
|
|
94
|
+
"vue-tsc": "^2.2.0"
|
|
91
95
|
},
|
|
92
96
|
"peerDependencies": {
|
|
93
97
|
"vue": "^3.4.15"
|
|
@@ -101,8 +105,8 @@
|
|
|
101
105
|
"type-check": "vue-tsc --noEmit -p tsconfig.dev.json --composite false",
|
|
102
106
|
"format": "prettier . --check",
|
|
103
107
|
"format:fix": "prettier . --write",
|
|
104
|
-
"lint": "eslint --max-warnings 0
|
|
105
|
-
"lint:fix": "eslint
|
|
108
|
+
"lint": "eslint --max-warnings 0 .",
|
|
109
|
+
"lint:fix": "eslint . --fix",
|
|
106
110
|
"lint:style": "stylelint \"**/*.scss\"",
|
|
107
111
|
"test": "vitest",
|
|
108
112
|
"test:coverage": "vitest run --coverage",
|