@quidgest/ui 0.26.0 → 0.27.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 +34 -0
- package/dist/json/api.json +487 -155
- package/dist/manifest/components.json +3 -0
- package/dist/ui.css +1016 -141
- package/dist/ui.esm.js +994 -942
- package/dist/ui.js +1235 -1186
- package/dist/ui.min.css +1 -1
- package/dist/ui.min.js +1235 -1186
- package/dist/ui.scss +1266 -157
- package/esm/components/QAccordion/QAccordion.d.ts.map +1 -1
- package/esm/components/QAccordion/QAccordion.vue.js +19 -18
- package/esm/components/QAccordion/QAccordionItem.vue.js +4 -4
- package/esm/components/QBadge/QBadge.d.ts.map +1 -1
- package/esm/components/QBadge/QBadge.vue.js +58 -55
- package/esm/components/QBadgeIndicator/QBadgeIndicator.d.ts.map +1 -1
- package/esm/components/QBadgeIndicator/QBadgeIndicator.vue.js +17 -16
- package/esm/components/QBreadcrumbs/QBreadcrumb.d.ts +81 -0
- package/esm/components/QBreadcrumbs/QBreadcrumb.d.ts.map +1 -0
- package/esm/components/QBreadcrumbs/QBreadcrumb.vue.js +85 -0
- package/esm/components/QBreadcrumbs/QBreadcrumb2.vue.js +5 -0
- package/esm/components/QBreadcrumbs/QBreadcrumbs.d.ts +22 -0
- package/esm/components/QBreadcrumbs/QBreadcrumbs.d.ts.map +1 -0
- package/esm/components/QBreadcrumbs/QBreadcrumbs.vue.js +74 -0
- package/esm/components/QBreadcrumbs/QBreadcrumbs2.vue.js +5 -0
- package/esm/components/QBreadcrumbs/constants.d.ts +20 -0
- package/esm/components/QBreadcrumbs/constants.d.ts.map +1 -0
- package/esm/components/QBreadcrumbs/constants.js +10 -0
- package/esm/components/QBreadcrumbs/context.d.ts +103 -0
- package/esm/components/QBreadcrumbs/context.d.ts.map +1 -0
- package/esm/components/QBreadcrumbs/context.js +4 -0
- package/esm/components/QBreadcrumbs/index.d.ts +108 -0
- package/esm/components/QBreadcrumbs/index.d.ts.map +1 -0
- package/esm/components/QBreadcrumbs/index.js +7 -0
- package/esm/components/QBreadcrumbs/types.d.ts +100 -0
- package/esm/components/QBreadcrumbs/types.d.ts.map +1 -0
- package/esm/components/QButton/QButton.d.ts.map +1 -1
- package/esm/components/QButton/QButton.vue.js +55 -52
- package/esm/components/QButtonGroup/QButtonGroup.d.ts.map +1 -1
- package/esm/components/QButtonGroup/QButtonGroup.vue.js +16 -15
- package/esm/components/QCard/QCard.d.ts.map +1 -1
- package/esm/components/QCard/QCard.vue.js +51 -52
- package/esm/components/QCarousel/QCarousel.d.ts.map +1 -1
- package/esm/components/QCarousel/QCarousel.vue.js +119 -115
- package/esm/components/QCheckbox/QCheckbox.d.ts.map +1 -1
- package/esm/components/QCheckbox/QCheckbox.vue.js +10 -14
- package/esm/components/QCollapsible/QCollapsible.d.ts.map +1 -1
- package/esm/components/QCollapsible/QCollapsible.vue.js +52 -51
- package/esm/components/QColorPicker/QColorPicker.d.ts.map +1 -1
- package/esm/components/QColorPicker/QColorPicker.vue.js +48 -47
- package/esm/components/QCombobox/QCombobox.d.ts +6 -4
- package/esm/components/QCombobox/QCombobox.d.ts.map +1 -1
- package/esm/components/QCombobox/QCombobox.vue.js +119 -116
- package/esm/components/QCombobox/index.d.ts +3 -2
- package/esm/components/QCombobox/index.d.ts.map +1 -1
- package/esm/components/QDateTimePicker/QDateTimePicker.d.ts.map +1 -1
- package/esm/components/QDateTimePicker/QDateTimePicker.vue.js +468 -429
- package/esm/components/QDateTimePicker/constants.d.ts +5 -0
- package/esm/components/QDateTimePicker/constants.d.ts.map +1 -1
- package/esm/components/QDateTimePicker/constants.js +5 -0
- package/esm/components/QDialog/QDialog.d.ts +2 -1
- package/esm/components/QDialog/QDialog.d.ts.map +1 -1
- package/esm/components/QDialog/QDialog.vue.js +84 -65
- package/esm/components/QDialog/constants.d.ts +6 -1
- package/esm/components/QDialog/constants.d.ts.map +1 -1
- package/esm/components/QDialog/constants.js +6 -2
- package/esm/components/QDialog/index.d.ts +6 -0
- package/esm/components/QDialog/index.d.ts.map +1 -1
- package/esm/components/QDialog/types.d.ts +13 -1
- package/esm/components/QDialog/types.d.ts.map +1 -1
- package/esm/components/QDivider/QDivider.d.ts.map +1 -1
- package/esm/components/QDivider/QDivider.vue.js +22 -21
- package/esm/components/QDropdownMenu/QDropdownMenuContent.d.ts +8 -6
- package/esm/components/QDropdownMenu/QDropdownMenuContent.d.ts.map +1 -1
- package/esm/components/QDropdownMenu/QDropdownMenuContent.vue.js +126 -125
- package/esm/components/QField/QField.d.ts.map +1 -1
- package/esm/components/QField/QField.vue.js +36 -34
- package/esm/components/QFileUpload/QFileUpload.vue.js +16 -16
- package/esm/components/QGauge/QGauge.d.ts +1 -1
- package/esm/components/QGauge/QGauge.d.ts.map +1 -1
- package/esm/components/QGauge/QGauge.vue.js +9 -9
- package/esm/components/QIcon/QIcon.d.ts.map +1 -1
- package/esm/components/QIcon/QIcon.vue.js +20 -19
- package/esm/components/QIcon/QIconFont.d.ts.map +1 -1
- package/esm/components/QIcon/QIconFont.vue.js +13 -12
- package/esm/components/QIcon/QIconImg.d.ts.map +1 -1
- package/esm/components/QIcon/QIconImg.vue.js +12 -11
- package/esm/components/QIcon/QIconSvg.d.ts.map +1 -1
- package/esm/components/QIcon/QIconSvg.vue.js +19 -18
- package/esm/components/QIcon/QSvgSymbol.d.ts +54 -0
- package/esm/components/QIcon/QSvgSymbol.d.ts.map +1 -0
- package/esm/components/QIcon/QSvgSymbol.vue.js +76 -0
- package/esm/components/QIcon/QSvgSymbol2.vue.js +5 -0
- package/esm/components/QIcon/utils/svgSource.d.ts +18 -0
- package/esm/components/QIcon/utils/svgSource.d.ts.map +1 -0
- package/esm/components/QIcon/utils/svgSource.js +27 -0
- package/esm/components/QInputGroup/QInputGroup.d.ts.map +1 -1
- package/esm/components/QInputGroup/QInputGroup.vue.js +30 -29
- package/esm/components/QLabel/QLabel.d.ts.map +1 -1
- package/esm/components/QLabel/QLabel.vue.js +20 -19
- package/esm/components/QLineLoader/QLineLoader.d.ts.map +1 -1
- package/esm/components/QLineLoader/QLineLoader.vue.js +14 -13
- package/esm/components/QList/QList.d.ts +4 -4
- package/esm/components/QList/QList.d.ts.map +1 -1
- package/esm/components/QList/QList.vue.js +135 -135
- package/esm/components/QList/QListItem.d.ts.map +1 -1
- package/esm/components/QList/QListItem.vue.js +42 -40
- package/esm/components/QList/QListItemGroup.d.ts +1 -1
- package/esm/components/QList/QListItemGroup.d.ts.map +1 -1
- package/esm/components/QList/index.d.ts +2 -2
- package/esm/components/QList/types.d.ts +6 -0
- package/esm/components/QList/types.d.ts.map +1 -1
- package/esm/components/QMeter/QMeter.d.ts.map +1 -1
- package/esm/components/QMeter/QMeter.vue.js +20 -19
- package/esm/components/QObfuscation/QObfuscation.d.ts.map +1 -1
- package/esm/components/QObfuscation/QObfuscation.vue.js +53 -53
- package/esm/components/QOverflow/QOverflow.d.ts +1 -1
- package/esm/components/QOverflow/QOverflow.d.ts.map +1 -1
- package/esm/components/QOverflow/QOverflow.vue.js +10 -10
- package/esm/components/QOverlay/QOverlay.d.ts.map +1 -1
- package/esm/components/QOverlay/QOverlay.vue.js +139 -138
- package/esm/components/QPasswordField/QPasswordField.d.ts +2 -0
- package/esm/components/QPasswordField/QPasswordField.d.ts.map +1 -1
- package/esm/components/QPasswordField/QPasswordField.vue.js +63 -60
- package/esm/components/QPasswordField/QPasswordFieldMeterOverlay.vue.js +1 -1
- package/esm/components/QPasswordField/constants.d.ts +4 -0
- package/esm/components/QPasswordField/constants.d.ts.map +1 -1
- package/esm/components/QPasswordField/constants.js +4 -1
- package/esm/components/QPasswordField/index.d.ts +6 -0
- package/esm/components/QPasswordField/index.d.ts.map +1 -1
- package/esm/components/QPasswordField/types.d.ts +7 -1
- package/esm/components/QPasswordField/types.d.ts.map +1 -1
- package/esm/components/QPhoneField/QPhoneField.d.ts +7 -5
- package/esm/components/QPhoneField/QPhoneField.d.ts.map +1 -1
- package/esm/components/QPhoneField/QPhoneField.vue.js +88 -88
- package/esm/components/QPhoneField/index.d.ts +3 -2
- package/esm/components/QPhoneField/index.d.ts.map +1 -1
- package/esm/components/QPopover/QPopover.d.ts.map +1 -1
- package/esm/components/QPopover/QPopover.vue.js +51 -28
- package/esm/components/QProgress/QProgress.vue.js +3 -3
- package/esm/components/QPropertyList/QPropertyList.d.ts.map +1 -1
- package/esm/components/QPropertyList/QPropertyList.vue.js +65 -55
- package/esm/components/QPropertyList/QPropertyListGroup.d.ts +8 -4
- package/esm/components/QPropertyList/QPropertyListGroup.d.ts.map +1 -1
- package/esm/components/QPropertyList/QPropertyListGroup.vue.js +31 -28
- package/esm/components/QPropertyList/QPropertyListPanel.d.ts.map +1 -1
- package/esm/components/QPropertyList/QPropertyListPanel.vue.js +13 -12
- package/esm/components/QPropertyList/QPropertyListRow.d.ts.map +1 -1
- package/esm/components/QPropertyList/QPropertyListRow.vue.js +41 -16
- package/esm/components/QPropertyList/constants.d.ts +2 -0
- package/esm/components/QPropertyList/constants.d.ts.map +1 -1
- package/esm/components/QPropertyList/constants.js +5 -1
- package/esm/components/QPropertyList/index.d.ts +16 -4
- package/esm/components/QPropertyList/index.d.ts.map +1 -1
- package/esm/components/QSection/QSection.d.ts.map +1 -1
- package/esm/components/QSection/QSection.vue.js +19 -18
- package/esm/components/QSelect/QSelect.d.ts +6 -4
- package/esm/components/QSelect/QSelect.d.ts.map +1 -1
- package/esm/components/QSelect/QSelect.vue.js +129 -124
- package/esm/components/QSelect/index.d.ts +3 -2
- package/esm/components/QSelect/index.d.ts.map +1 -1
- package/esm/components/QSidebar/QSidebar.d.ts +1 -1
- package/esm/components/QSidebar/QSidebar.d.ts.map +1 -1
- package/esm/components/QSidebar/QSidebar.vue.js +68 -67
- package/esm/components/QSidebar/QSidebarItem.d.ts +1 -1
- package/esm/components/QSidebar/QSidebarItem.d.ts.map +1 -1
- package/esm/components/QSidebar/QSidebarItem.vue.js +8 -8
- package/esm/components/QSidebar/QSidebarPanel.d.ts.map +1 -1
- package/esm/components/QSidebar/QSidebarPanel.vue.js +40 -36
- package/esm/components/QSidebar/context.d.ts +1 -1
- package/esm/components/QSidebar/context.d.ts.map +1 -1
- package/esm/components/QSidebar/types.d.ts +8 -0
- package/esm/components/QSidebar/types.d.ts.map +1 -1
- package/esm/components/QSkeletonLoader/QSkeletonLoader.d.ts.map +1 -1
- package/esm/components/QSkeletonLoader/QSkeletonLoader.vue.js +15 -14
- package/esm/components/QSpinnerLoader/QSpinnerLoader.d.ts.map +1 -1
- package/esm/components/QSpinnerLoader/QSpinnerLoader.vue.js +11 -10
- package/esm/components/QSteps/QStepHeader.d.ts +58 -0
- package/esm/components/QSteps/QStepHeader.d.ts.map +1 -0
- package/esm/components/QSteps/QStepHeader.vue.js +49 -0
- package/esm/components/QSteps/QStepHeader2.vue.js +5 -0
- package/esm/components/QSteps/QSteps.d.ts +269 -0
- package/esm/components/QSteps/QSteps.d.ts.map +1 -0
- package/esm/components/QSteps/QSteps.vue.js +260 -0
- package/esm/components/QSteps/QSteps2.vue.js +5 -0
- package/esm/components/QSteps/QStepsNav.d.ts +59 -0
- package/esm/components/QSteps/QStepsNav.d.ts.map +1 -0
- package/esm/components/QSteps/QStepsNav.vue.js +42 -0
- package/esm/components/QSteps/QStepsNav2.vue.js +5 -0
- package/esm/components/QSteps/constants.d.ts +28 -0
- package/esm/components/QSteps/constants.d.ts.map +1 -0
- package/esm/components/QSteps/constants.js +16 -0
- package/esm/components/QSteps/index.d.ts +228 -0
- package/esm/components/QSteps/index.d.ts.map +1 -0
- package/esm/components/QSteps/index.js +6 -0
- package/esm/components/QSteps/types.d.ts +190 -0
- package/esm/components/QSteps/types.d.ts.map +1 -0
- package/esm/components/QSwitch/QSwitch.vue.js +3 -3
- package/esm/components/QTabs/QTab.d.ts +1 -1
- package/esm/components/QTabs/QTab.d.ts.map +1 -1
- package/esm/components/QTabs/QTab.vue.js +10 -12
- package/esm/components/QTabs/QTabs.d.ts +1 -1
- package/esm/components/QTabs/QTabs.d.ts.map +1 -1
- package/esm/components/QTabs/QTabs.vue.js +108 -107
- package/esm/components/QTabs/context.d.ts +1 -1
- package/esm/components/QTabs/context.d.ts.map +1 -1
- package/esm/components/QTabs/types.d.ts +1 -1
- package/esm/components/QTextArea/QTextArea.d.ts +1 -1
- package/esm/components/QTextArea/index.d.ts +3 -3
- package/esm/components/QThemeProvider/QThemeProvider.vue.js +3 -3
- package/esm/components/QToast/QToast.d.ts +2 -1
- package/esm/components/QToast/QToast.d.ts.map +1 -1
- package/esm/components/QToast/QToast.vue.js +95 -78
- package/esm/components/QToast/QToaster.d.ts.map +1 -1
- package/esm/components/QToast/QToaster.vue.js +20 -19
- package/esm/components/QToast/constants.d.ts +3 -0
- package/esm/components/QToast/constants.d.ts.map +1 -1
- package/esm/components/QToast/constants.js +2 -2
- package/esm/components/QToast/index.d.ts +6 -0
- package/esm/components/QToast/index.d.ts.map +1 -1
- package/esm/components/QToast/types.d.ts +7 -1
- package/esm/components/QToast/types.d.ts.map +1 -1
- package/esm/components/QToggle/QToggle.d.ts.map +1 -1
- package/esm/components/QToggle/QToggle.vue.js +52 -15
- package/esm/components/QToggleGroup/QToggleGroup.d.ts.map +1 -1
- package/esm/components/QToggleGroup/QToggleGroup.vue.js +21 -20
- package/esm/components/QTooltip/QTooltip.vue.js +5 -5
- package/esm/components/__internal__/QChevron/QChevron.d.ts.map +1 -1
- package/esm/components/__internal__/QChevron/QChevron.vue.js +16 -15
- package/esm/components/__internal__/QClearButton/QClearButton.d.ts.map +1 -1
- package/esm/components/__internal__/QClearButton/QClearButton.vue.js +19 -18
- package/esm/components/index.d.ts +2 -0
- package/esm/components/index.d.ts.map +1 -1
- package/esm/components/index.js +108 -103
- package/esm/composables/useColor/index.d.ts +2 -0
- package/esm/composables/useColor/index.d.ts.map +1 -1
- package/esm/composables/useColor/index.js +49 -39
- package/esm/composables/useColor/types.d.ts +15 -0
- package/esm/composables/useColor/types.d.ts.map +1 -1
- package/esm/index.d.ts +3 -0
- package/esm/utils/color/contrast.d.ts +20 -0
- package/esm/utils/color/contrast.d.ts.map +1 -1
- package/esm/utils/color/contrast.js +24 -13
- package/esm/utils/color/merge.js +8 -8
- package/esm/utils/index.js +56 -54
- package/package.json +12 -6
- package/esm/components/QIcon/InlineSvg.d.ts +0 -110
- package/esm/components/QIcon/InlineSvg.d.ts.map +0 -1
- package/esm/components/QIcon/InlineSvg.js +0 -95
- package/esm/utils/time.d.ts +0 -36
- package/esm/utils/time.d.ts.map +0 -1
|
@@ -1,17 +1,18 @@
|
|
|
1
|
-
import {
|
|
2
|
-
import {
|
|
3
|
-
import {
|
|
4
|
-
import {
|
|
5
|
-
import {
|
|
1
|
+
import { useId as e } from "../../composables/useId/index.js";
|
|
2
|
+
import { QIcon as t } from "../QIcon/index.js";
|
|
3
|
+
import { DEFAULT_ICONS as n } from "./constants.js";
|
|
4
|
+
import { QList as r } from "../QList/index.js";
|
|
5
|
+
import { QOverlay as i } from "../QOverlay/index.js";
|
|
6
|
+
import { QSafeTriangle as ee } from "../__internal__/QSafeTriangle/index.js";
|
|
6
7
|
import { useSafeTriangle as a } from "../../composables/useSafeTriangle/index.js";
|
|
7
|
-
import { Fragment as
|
|
8
|
+
import { Fragment as te, computed as o, createBlock as s, createCommentVNode as c, createElementBlock as l, createElementVNode as ne, createVNode as u, defineComponent as d, guardReactiveProps as f, mergeModels as p, mergeProps as re, nextTick as m, normalizeClass as ie, normalizeProps as h, openBlock as g, ref as _, renderSlot as v, resolveComponent as y, toDisplayString as ae, toRef as oe, unref as b, useModel as x, useTemplateRef as S, watch as C, withCtx as w, withModifiers as T } from "vue";
|
|
8
9
|
//#region src/components/QDropdownMenu/QDropdownMenuContent.vue?vue&type=script&setup=true&lang.ts
|
|
9
|
-
var
|
|
10
|
+
var E = {
|
|
10
11
|
key: 0,
|
|
11
12
|
class: "q-dropdown-menu__extra"
|
|
12
|
-
},
|
|
13
|
+
}, D = /*@__PURE__*/ d({
|
|
13
14
|
__name: "QDropdownMenuContent",
|
|
14
|
-
props: /*@__PURE__*/
|
|
15
|
+
props: /*@__PURE__*/ p({
|
|
15
16
|
id: {},
|
|
16
17
|
class: {},
|
|
17
18
|
activator: {},
|
|
@@ -26,7 +27,7 @@ var oe = {
|
|
|
26
27
|
delay: { default: 500 },
|
|
27
28
|
trigger: { default: "hover" },
|
|
28
29
|
depth: { default: 0 },
|
|
29
|
-
icons: { default: () =>
|
|
30
|
+
icons: { default: () => n },
|
|
30
31
|
offset: { default: 6 },
|
|
31
32
|
crossOffset: { default: -5 }
|
|
32
33
|
}, {
|
|
@@ -35,54 +36,54 @@ var oe = {
|
|
|
35
36
|
highlighted: {},
|
|
36
37
|
highlightedModifiers: {}
|
|
37
38
|
}),
|
|
38
|
-
emits: /*@__PURE__*/
|
|
39
|
+
emits: /*@__PURE__*/ p([
|
|
39
40
|
"select",
|
|
40
41
|
"open",
|
|
41
42
|
"hide",
|
|
42
43
|
"focus-previous"
|
|
43
44
|
], ["update:modelValue", "update:highlighted"]),
|
|
44
|
-
setup(
|
|
45
|
-
let
|
|
46
|
-
function
|
|
45
|
+
setup(n, { expose: d, emit: p }) {
|
|
46
|
+
let D = n, O = p, k = x(n, "modelValue"), A = x(n, "highlighted"), se = e(oe(D, "id")), j = _(void 0), M = _([]), ce = o(() => D.depth === 0 ? 4 : D.offset), le = o(() => D.depth === 0 ? void 0 : D.crossOffset), N = S("list"), P = S("body"), F = _(null), I = o(() => "right-start"), L = o(() => D.trigger !== "hover" || j.value === void 0 ? !1 : ((D.items?.find((e) => e[D.itemValue] === j.value))?.items?.length ?? 0) > 0);
|
|
47
|
+
function R(e) {
|
|
47
48
|
return "syncHoverFromPoint" in e && "getMenuRect" in e && "getMenuRoot" in e && "hasOpenSubmenu" in e;
|
|
48
49
|
}
|
|
49
|
-
function
|
|
50
|
-
if (e &&
|
|
51
|
-
|
|
50
|
+
function z(e, t) {
|
|
51
|
+
if (e && j.value === t && R(e)) {
|
|
52
|
+
F.value = e, m(() => {
|
|
52
53
|
G();
|
|
53
|
-
let { x: e, y: t } =
|
|
54
|
-
|
|
54
|
+
let { x: e, y: t } = me();
|
|
55
|
+
F.value?.syncHoverFromPoint(e, t);
|
|
55
56
|
});
|
|
56
57
|
return;
|
|
57
58
|
}
|
|
58
|
-
!e &&
|
|
59
|
+
!e && j.value === t && (F.value = null);
|
|
59
60
|
}
|
|
60
|
-
function
|
|
61
|
-
return
|
|
61
|
+
function B() {
|
|
62
|
+
return F.value?.getMenuRect() ?? null;
|
|
62
63
|
}
|
|
63
|
-
function
|
|
64
|
-
return
|
|
64
|
+
function V() {
|
|
65
|
+
return F.value?.getMenuRoot() ?? null;
|
|
65
66
|
}
|
|
66
|
-
function
|
|
67
|
-
return
|
|
67
|
+
function H() {
|
|
68
|
+
return F.value?.hasOpenSubmenu() ?? !1;
|
|
68
69
|
}
|
|
69
|
-
let { visible:
|
|
70
|
-
enabled:
|
|
71
|
-
placement:
|
|
72
|
-
getParentRect: () =>
|
|
73
|
-
getContentRect:
|
|
74
|
-
getContentRoot:
|
|
75
|
-
shouldSuppressLeave:
|
|
70
|
+
let { visible: U, top: W, left: ue, width: de, height: fe, path: pe, refresh: G, getLastPointer: me } = a({
|
|
71
|
+
enabled: L,
|
|
72
|
+
placement: I,
|
|
73
|
+
getParentRect: () => P.value?.getBoundingClientRect() ?? null,
|
|
74
|
+
getContentRect: B,
|
|
75
|
+
getContentRoot: V,
|
|
76
|
+
shouldSuppressLeave: H,
|
|
76
77
|
onLeave: X,
|
|
77
78
|
onEnterContent: (e, t) => {
|
|
78
|
-
|
|
79
|
+
F.value?.syncHoverFromPoint(e, t);
|
|
79
80
|
}
|
|
80
81
|
});
|
|
81
|
-
|
|
82
|
-
|
|
82
|
+
C(j, () => {
|
|
83
|
+
F.value = null;
|
|
83
84
|
});
|
|
84
|
-
function
|
|
85
|
-
let n =
|
|
85
|
+
function he(e, t) {
|
|
86
|
+
let n = P.value;
|
|
86
87
|
if (!n) return;
|
|
87
88
|
let r = document.elementsFromPoint(e, t);
|
|
88
89
|
for (let e of r) {
|
|
@@ -91,27 +92,27 @@ var oe = {
|
|
|
91
92
|
if (!t || !n.contains(t) || t.closest(".q-dropdown-menu__body") !== n) continue;
|
|
92
93
|
let r = t.getAttribute("data-key");
|
|
93
94
|
if (r === null) continue;
|
|
94
|
-
let i =
|
|
95
|
-
if (i) return i[
|
|
95
|
+
let i = D.items?.find((e) => String(e[D.itemValue]) === r);
|
|
96
|
+
if (i) return i[D.itemValue];
|
|
96
97
|
}
|
|
97
98
|
}
|
|
98
99
|
function K(e, t) {
|
|
99
|
-
if (
|
|
100
|
-
let n =
|
|
101
|
-
n !== void 0 &&
|
|
100
|
+
if (D.trigger !== "hover") return;
|
|
101
|
+
let n = he(e, t);
|
|
102
|
+
n !== void 0 && J(n);
|
|
102
103
|
}
|
|
103
|
-
function
|
|
104
|
+
function ge(e) {
|
|
104
105
|
G(e.clientX, e.clientY), K(e.clientX, e.clientY);
|
|
105
106
|
}
|
|
106
|
-
function
|
|
107
|
-
|
|
107
|
+
function _e(e) {
|
|
108
|
+
L.value && K(e.clientX, e.clientY), G(e.clientX, e.clientY);
|
|
108
109
|
}
|
|
109
|
-
function
|
|
110
|
-
|
|
111
|
-
let t =
|
|
112
|
-
|
|
110
|
+
function ve(e) {
|
|
111
|
+
M.value = D.items?.find((t) => t[D.itemValue] === e)?.items ?? [];
|
|
112
|
+
let t = M.value.length > 0;
|
|
113
|
+
A.value = e, t ? $(e) : Y(e);
|
|
113
114
|
}
|
|
114
|
-
function
|
|
115
|
+
function q(e) {
|
|
115
116
|
if (e.key) switch ([
|
|
116
117
|
"Enter",
|
|
117
118
|
"ArrowDown",
|
|
@@ -120,8 +121,8 @@ var oe = {
|
|
|
120
121
|
"ArrowRight"
|
|
121
122
|
].includes(e.key) && (e.preventDefault(), e.stopPropagation()), e.key) {
|
|
122
123
|
case "ArrowRight":
|
|
123
|
-
let e =
|
|
124
|
-
|
|
124
|
+
let e = N.value?.getActiveItemIndex();
|
|
125
|
+
D.items && (e || e === 0) && D.items[e] && (A.value = D.items[e].key, $(D.items[e].key));
|
|
125
126
|
break;
|
|
126
127
|
case "ArrowLeft":
|
|
127
128
|
Z();
|
|
@@ -133,111 +134,111 @@ var oe = {
|
|
|
133
134
|
default: break;
|
|
134
135
|
}
|
|
135
136
|
}
|
|
136
|
-
function q(e) {
|
|
137
|
-
T.trigger === "hover" && (O.value = e, $(e));
|
|
138
|
-
}
|
|
139
137
|
function J(e) {
|
|
140
|
-
|
|
138
|
+
D.trigger === "hover" && (A.value = e, $(e));
|
|
139
|
+
}
|
|
140
|
+
function Y(e) {
|
|
141
|
+
O("select", e), Q();
|
|
141
142
|
}
|
|
142
|
-
function
|
|
143
|
+
function ye() {
|
|
143
144
|
Z();
|
|
144
145
|
}
|
|
145
146
|
function X() {
|
|
146
|
-
|
|
147
|
+
j.value = void 0, A.value = void 0;
|
|
147
148
|
}
|
|
148
149
|
function Z() {
|
|
149
|
-
X(),
|
|
150
|
+
X(), k.value = !1, O("focus-previous");
|
|
150
151
|
}
|
|
151
152
|
function Q() {
|
|
152
|
-
Z(),
|
|
153
|
+
Z(), O("hide");
|
|
153
154
|
}
|
|
154
155
|
function $(e) {
|
|
155
|
-
|
|
156
|
+
j.value = (D.items?.find((t) => t[D.itemValue] === e))?.items?.length ? e : void 0;
|
|
156
157
|
}
|
|
157
|
-
function
|
|
158
|
-
let e =
|
|
158
|
+
function be() {
|
|
159
|
+
let e = D.items?.findIndex((e) => e[D.itemValue] === j.value);
|
|
159
160
|
if (!e && e !== 0) return;
|
|
160
|
-
let t =
|
|
161
|
-
|
|
161
|
+
let t = N.value?.getItem(e);
|
|
162
|
+
j.value = void 0, A.value = void 0, t?.focus();
|
|
162
163
|
}
|
|
163
|
-
function
|
|
164
|
-
|
|
164
|
+
function xe() {
|
|
165
|
+
m(() => N.value?.$el.focus());
|
|
165
166
|
}
|
|
166
|
-
function
|
|
167
|
-
|
|
167
|
+
function Se() {
|
|
168
|
+
O("open"), xe();
|
|
168
169
|
}
|
|
169
|
-
return
|
|
170
|
+
return d({
|
|
170
171
|
getMenuRect: () => {
|
|
171
|
-
let e =
|
|
172
|
+
let e = P.value;
|
|
172
173
|
return e ? (e.closest(".q-overlay") ?? e).getBoundingClientRect() : null;
|
|
173
174
|
},
|
|
174
|
-
getMenuRoot: () =>
|
|
175
|
-
hasOpenSubmenu: () =>
|
|
175
|
+
getMenuRoot: () => P.value?.closest(".q-overlay") ?? P.value,
|
|
176
|
+
hasOpenSubmenu: () => j.value === void 0 ? !1 : ((D.items?.find((e) => e[D.itemValue] === j.value))?.items?.length ?? 0) > 0,
|
|
176
177
|
syncHoverFromPoint: K
|
|
177
|
-
}), (
|
|
178
|
-
let
|
|
179
|
-
return
|
|
180
|
-
id:
|
|
181
|
-
modelValue:
|
|
182
|
-
"onUpdate:modelValue":
|
|
183
|
-
anchor:
|
|
184
|
-
appearance:
|
|
185
|
-
inline:
|
|
186
|
-
delay:
|
|
187
|
-
offset:
|
|
188
|
-
"cross-offset":
|
|
189
|
-
placement:
|
|
190
|
-
transition:
|
|
191
|
-
class:
|
|
178
|
+
}), (e, n) => {
|
|
179
|
+
let a = y("q-dropdown-menu-content", !0);
|
|
180
|
+
return g(), s(b(i), {
|
|
181
|
+
id: b(se),
|
|
182
|
+
modelValue: k.value,
|
|
183
|
+
"onUpdate:modelValue": n[0] ||= (e) => k.value = e,
|
|
184
|
+
anchor: D.activator,
|
|
185
|
+
appearance: D.appearance,
|
|
186
|
+
inline: D.inline,
|
|
187
|
+
delay: D.delay,
|
|
188
|
+
offset: ce.value,
|
|
189
|
+
"cross-offset": le.value,
|
|
190
|
+
placement: D.placement,
|
|
191
|
+
transition: D.transition,
|
|
192
|
+
class: ie(D.class),
|
|
192
193
|
trigger: "click",
|
|
193
194
|
"scroll-lock": "",
|
|
194
195
|
"non-modal": "",
|
|
195
|
-
onEnter:
|
|
196
|
-
onLeave:
|
|
196
|
+
onEnter: Se,
|
|
197
|
+
onLeave: ye
|
|
197
198
|
}, {
|
|
198
|
-
default: w(() => [
|
|
199
|
+
default: w(() => [ne("div", {
|
|
199
200
|
ref: "body",
|
|
200
201
|
class: "q-dropdown-menu__body",
|
|
201
202
|
"data-testid": "dropdown-content",
|
|
202
203
|
tabindex: "-1",
|
|
203
|
-
onPointerenter:
|
|
204
|
-
onPointermove:
|
|
205
|
-
onKeydown:
|
|
204
|
+
onPointerenter: ge,
|
|
205
|
+
onPointermove: _e,
|
|
206
|
+
onKeydown: T(q, ["stop"])
|
|
206
207
|
}, [
|
|
207
|
-
|
|
208
|
-
|
|
208
|
+
v(e.$slots, "prepend"),
|
|
209
|
+
u(b(r), {
|
|
209
210
|
ref: "list",
|
|
210
211
|
class: "q-dropdown-menu__items",
|
|
211
|
-
highlighted:
|
|
212
|
-
items:
|
|
213
|
-
groups:
|
|
214
|
-
"item-label":
|
|
215
|
-
"item-value":
|
|
212
|
+
highlighted: A.value,
|
|
213
|
+
items: D.items,
|
|
214
|
+
groups: D.groups,
|
|
215
|
+
"item-label": D.itemLabel,
|
|
216
|
+
"item-value": D.itemValue,
|
|
216
217
|
selectable: !1,
|
|
217
218
|
"select-on-tab": !1,
|
|
218
|
-
onClick:
|
|
219
|
-
"onMouseenter:item":
|
|
219
|
+
onClick: ve,
|
|
220
|
+
"onMouseenter:item": J
|
|
220
221
|
}, {
|
|
221
|
-
item: w(({ item:
|
|
222
|
-
"item.append": w(({ item:
|
|
222
|
+
item: w(({ item: t }) => [v(e.$slots, "item", { item: t })]),
|
|
223
|
+
"item.append": w(({ item: n, element: r }) => [v(e.$slots, "item.append", { item: n }, () => [n.extraInfo ? (g(), l("span", E, ae(n.extraInfo), 1)) : c("v-if", !0)]), n.items?.length > 0 ? (g(), l(te, { key: 0 }, [u(b(t), h(f(D.icons.expand)), null, 16), j.value === n.key ? (g(), s(a, re({
|
|
223
224
|
key: 0,
|
|
224
|
-
ref: (e) =>
|
|
225
|
+
ref: (e) => z(e, n.key),
|
|
225
226
|
"model-value": ""
|
|
226
|
-
},
|
|
227
|
-
activator:
|
|
228
|
-
items:
|
|
229
|
-
groups:
|
|
230
|
-
depth:
|
|
231
|
-
delay:
|
|
227
|
+
}, D, {
|
|
228
|
+
activator: r,
|
|
229
|
+
items: n.items,
|
|
230
|
+
groups: n.groups,
|
|
231
|
+
depth: D.depth + 1,
|
|
232
|
+
delay: D.delay,
|
|
232
233
|
placement: "right-start",
|
|
233
234
|
"non-modal": "",
|
|
234
235
|
inline: "",
|
|
235
236
|
onHide: Q,
|
|
236
|
-
onSelect:
|
|
237
|
-
onFocusPrevious:
|
|
237
|
+
onSelect: Y,
|
|
238
|
+
onFocusPrevious: be
|
|
238
239
|
}), {
|
|
239
|
-
item: w((
|
|
240
|
-
"item.append": w((
|
|
240
|
+
item: w((t) => [v(e.$slots, "item", h(f(t)))]),
|
|
241
|
+
"item.append": w((t) => [v(e.$slots, "item.append", h(f(t)))]),
|
|
241
242
|
_: 3
|
|
242
243
|
}, 16, [
|
|
243
244
|
"activator",
|
|
@@ -254,14 +255,14 @@ var oe = {
|
|
|
254
255
|
"item-label",
|
|
255
256
|
"item-value"
|
|
256
257
|
]),
|
|
257
|
-
|
|
258
|
-
], 544),
|
|
258
|
+
v(e.$slots, "append")
|
|
259
|
+
], 544), b(U) ? (g(), s(b(ee), {
|
|
259
260
|
key: 0,
|
|
260
|
-
top:
|
|
261
|
-
left:
|
|
262
|
-
width:
|
|
263
|
-
height:
|
|
264
|
-
path:
|
|
261
|
+
top: b(W),
|
|
262
|
+
left: b(ue),
|
|
263
|
+
width: b(de),
|
|
264
|
+
height: b(fe),
|
|
265
|
+
path: b(pe)
|
|
265
266
|
}, null, 8, [
|
|
266
267
|
"top",
|
|
267
268
|
"left",
|
|
@@ -287,4 +288,4 @@ var oe = {
|
|
|
287
288
|
}
|
|
288
289
|
});
|
|
289
290
|
//#endregion
|
|
290
|
-
export {
|
|
291
|
+
export { D as default };
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"QField.vue.d.ts","sourceRoot":"","sources":["../../../src/components/QField/QField.vue"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"QField.vue.d.ts","sourceRoot":"","sources":["../../../src/components/QField/QField.vue"],"names":[],"mappings":"AA4CA;AAqGC,OAAO,KAAK,EAAE,WAAW,EAAE,MAAM,GAAG,CAAA;AAiDrC,iBAAS,cAAc;WAiGT,OAAO,IAA6B;;iCAlBb,GAAG;gCACJ,GAAG;yBACV,GAAG;yBACH,GAAG;yBACF,GAAG;wBACJ,GAAG;wBACH,GAAG;;;;;;EAiB/B;AAaD,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,16 +1,17 @@
|
|
|
1
|
-
import {
|
|
2
|
-
import {
|
|
1
|
+
import { useId as e } from "../../composables/useId/index.js";
|
|
2
|
+
import { QLabel as t } from "../QLabel/index.js";
|
|
3
|
+
import { computed as n, createBlock as r, createCommentVNode as i, createElementBlock as a, createElementVNode as o, defineComponent as s, mergeProps as c, normalizeClass as l, openBlock as u, renderSlot as d, toRef as f, unref as p, useTemplateRef as m, withCtx as h } from "vue";
|
|
3
4
|
//#region src/components/QField/QField.vue?vue&type=script&setup=true&lang.ts
|
|
4
|
-
var
|
|
5
|
+
var g = ["id", "aria-disabled"], _ = {
|
|
5
6
|
key: 0,
|
|
6
7
|
class: "q-field__prepend"
|
|
7
|
-
},
|
|
8
|
+
}, v = {
|
|
8
9
|
key: 1,
|
|
9
10
|
class: "q-field__append"
|
|
10
|
-
},
|
|
11
|
+
}, y = {
|
|
11
12
|
key: 1,
|
|
12
13
|
class: "q-field__extras"
|
|
13
|
-
},
|
|
14
|
+
}, b = /*@__PURE__*/ s({
|
|
14
15
|
inheritAttrs: !1,
|
|
15
16
|
__name: "QField",
|
|
16
17
|
props: {
|
|
@@ -25,51 +26,52 @@ var m = ["id"], h = {
|
|
|
25
26
|
disabled: { type: Boolean },
|
|
26
27
|
invalid: { type: Boolean }
|
|
27
28
|
},
|
|
28
|
-
setup(
|
|
29
|
-
let
|
|
29
|
+
setup(s, { expose: b }) {
|
|
30
|
+
let x = s, S = e(f(x, "id")), C = m("field"), w = n(() => x.required && !x.readonly && !x.disabled), T = n(() => [
|
|
30
31
|
"q-field",
|
|
31
|
-
`q-field--${
|
|
32
|
-
`q-field--label-${
|
|
32
|
+
`q-field--${x.size}`,
|
|
33
|
+
`q-field--label-${x.labelPosition}`,
|
|
33
34
|
{
|
|
34
|
-
"q-field--readonly":
|
|
35
|
-
"q-field--disabled":
|
|
36
|
-
"q-field--required":
|
|
37
|
-
"q-field--invalid":
|
|
35
|
+
"q-field--readonly": x.readonly,
|
|
36
|
+
"q-field--disabled": x.disabled,
|
|
37
|
+
"q-field--required": w.value,
|
|
38
|
+
"q-field--invalid": x.invalid
|
|
38
39
|
},
|
|
39
|
-
|
|
40
|
+
x.class
|
|
40
41
|
]);
|
|
41
|
-
return
|
|
42
|
-
id:
|
|
43
|
-
class:
|
|
42
|
+
return b({ fieldRef: C }), (e, n) => (u(), a("div", {
|
|
43
|
+
id: p(S),
|
|
44
|
+
class: l(T.value),
|
|
45
|
+
"aria-disabled": x.disabled || void 0
|
|
44
46
|
}, [
|
|
45
|
-
|
|
47
|
+
x.label ? (u(), r(p(t), {
|
|
46
48
|
key: 0,
|
|
47
49
|
class: "q-field__label",
|
|
48
|
-
label:
|
|
49
|
-
"label-position":
|
|
50
|
-
for:
|
|
51
|
-
required:
|
|
50
|
+
label: x.label,
|
|
51
|
+
"label-position": x.labelPosition,
|
|
52
|
+
for: x.for,
|
|
53
|
+
required: w.value
|
|
52
54
|
}, {
|
|
53
|
-
prepend:
|
|
54
|
-
append:
|
|
55
|
+
prepend: h(() => [d(e.$slots, "label.prepend")]),
|
|
56
|
+
append: h(() => [d(e.$slots, "label.append")]),
|
|
55
57
|
_: 3
|
|
56
58
|
}, 8, [
|
|
57
59
|
"label",
|
|
58
60
|
"label-position",
|
|
59
61
|
"for",
|
|
60
62
|
"required"
|
|
61
|
-
])) :
|
|
62
|
-
|
|
63
|
+
])) : i("v-if", !0),
|
|
64
|
+
d(e.$slots, "control", {}, () => [o("div", c({
|
|
63
65
|
ref: "field",
|
|
64
66
|
class: "q-field__control"
|
|
65
|
-
},
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
|
|
67
|
+
}, e.$attrs), [
|
|
68
|
+
e.$slots.prepend ? (u(), a("div", _, [d(e.$slots, "prepend")])) : i("v-if", !0),
|
|
69
|
+
d(e.$slots, "default"),
|
|
70
|
+
e.$slots.append ? (u(), a("div", v, [d(e.$slots, "append")])) : i("v-if", !0)
|
|
69
71
|
], 16)]),
|
|
70
|
-
|
|
71
|
-
], 10,
|
|
72
|
+
e.$slots.extras ? (u(), a("div", y, [d(e.$slots, "extras")])) : i("v-if", !0)
|
|
73
|
+
], 10, g));
|
|
72
74
|
}
|
|
73
75
|
});
|
|
74
76
|
//#endregion
|
|
75
|
-
export {
|
|
77
|
+
export { b as default };
|
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
import {
|
|
2
|
-
import {
|
|
3
|
-
import {
|
|
1
|
+
import { useId as e } from "../../composables/useId/index.js";
|
|
2
|
+
import { QButton as t } from "../QButton/index.js";
|
|
3
|
+
import { QIcon as n } from "../QIcon/index.js";
|
|
4
4
|
import { QField as r } from "../QField/index.js";
|
|
5
5
|
import { DEFAULT_ICONS as i, DEFAULT_TEXTS as a } from "./constants.js";
|
|
6
6
|
import { useDropZone as o } from "../../composables/useDropZone/index.js";
|
|
@@ -51,7 +51,7 @@ var j = [
|
|
|
51
51
|
}),
|
|
52
52
|
emits: ["update:modelValue"],
|
|
53
53
|
setup(i) {
|
|
54
|
-
let a = i, g = O(i, "modelValue"), v =
|
|
54
|
+
let a = i, g = O(i, "modelValue"), v = e(E(a, "id")), H = c(() => !a.readonly && !a.disabled), U = C(null);
|
|
55
55
|
k(g, (e) => {
|
|
56
56
|
U.value && URL.revokeObjectURL(U.value), U.value = e && e.type.startsWith("image/") ? URL.createObjectURL(e) : null;
|
|
57
57
|
});
|
|
@@ -84,7 +84,7 @@ var j = [
|
|
|
84
84
|
{ "q-file-input--highlighted": $.value && ee.value },
|
|
85
85
|
a.class
|
|
86
86
|
]);
|
|
87
|
-
return (
|
|
87
|
+
return (e, i) => (S(), l(D(r), {
|
|
88
88
|
for: D(v),
|
|
89
89
|
label: a.label,
|
|
90
90
|
"label-position": a.labelPosition,
|
|
@@ -108,38 +108,38 @@ var j = [
|
|
|
108
108
|
required: a.required,
|
|
109
109
|
readonly: a.readonly,
|
|
110
110
|
disabled: a.disabled
|
|
111
|
-
},
|
|
112
|
-
h(D(
|
|
111
|
+
}, e.$attrs, { onChange: K }), null, 16, j), !g.value && H.value ? (S(), d("div", M, [
|
|
112
|
+
h(D(n), x(_(a.icons.upload)), null, 16),
|
|
113
113
|
f("span", null, T(a.texts.dropHereOr), 1),
|
|
114
|
-
h(D(
|
|
114
|
+
h(D(t), {
|
|
115
115
|
label: a.texts.chooseFile,
|
|
116
116
|
onClick: G
|
|
117
117
|
}, null, 8, ["label"])
|
|
118
118
|
])) : g.value ? (S(), d("div", N, [f("div", P, [U.value ? (S(), d("div", F, [f("img", {
|
|
119
119
|
src: U.value,
|
|
120
120
|
alt: a.texts.preview
|
|
121
|
-
}, null, 8, I)])) : (S(), l(D(
|
|
121
|
+
}, null, 8, I)])) : (S(), l(D(n), y({
|
|
122
122
|
key: 1,
|
|
123
123
|
class: "q-file-input__preview"
|
|
124
|
-
}, a.icons.file), null, 16)), f("div", L, [f("span", R, T(g.value.name), 1), f("span", z, T(g.value.type), 1)])]), H.value ? (S(), d("div", B, [h(D(
|
|
124
|
+
}, a.icons.file), null, 16)), f("div", L, [f("span", R, T(g.value.name), 1), f("span", z, T(g.value.type), 1)])]), H.value ? (S(), d("div", B, [h(D(t), {
|
|
125
125
|
title: a.texts.download,
|
|
126
126
|
borderless: "",
|
|
127
127
|
onClick: q
|
|
128
128
|
}, {
|
|
129
|
-
default: A(() => [h(D(
|
|
129
|
+
default: A(() => [h(D(n), x(_(a.icons.download)), null, 16)]),
|
|
130
130
|
_: 1
|
|
131
|
-
}, 8, ["title"]), h(D(
|
|
131
|
+
}, 8, ["title"]), h(D(t), {
|
|
132
132
|
title: a.texts.remove,
|
|
133
133
|
borderless: "",
|
|
134
134
|
onClick: J
|
|
135
135
|
}, {
|
|
136
|
-
default: A(() => [h(D(
|
|
136
|
+
default: A(() => [h(D(n), x(_(a.icons.remove)), null, 16)]),
|
|
137
137
|
_: 1
|
|
138
|
-
}, 8, ["title"])])) : u("v-if", !0)])) : (S(), d("div", V, [h(D(
|
|
138
|
+
}, 8, ["title"])])) : u("v-if", !0)])) : (S(), d("div", V, [h(D(n), x(_(a.icons.empty)), null, 16), m(" " + T(a.texts.empty), 1)]))], 2)]),
|
|
139
139
|
_: 2
|
|
140
|
-
}, [
|
|
140
|
+
}, [e.$slots.extras ? {
|
|
141
141
|
name: "extras",
|
|
142
|
-
fn: A(() => [w(
|
|
142
|
+
fn: A(() => [w(e.$slots, "extras")]),
|
|
143
143
|
key: "0"
|
|
144
144
|
} : void 0]), 1032, [
|
|
145
145
|
"for",
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"QGauge.vue.d.ts","sourceRoot":"","sources":["../../../src/components/QGauge/QGauge.vue"],"names":[],"mappings":"AA+JA;AAugBC,OAAO,EAAE,aAAa,EAAE,MAAM,aAAa,CAAA;AAO3C,OAAO,KAAK,EAAE,WAAW,EAAE,MAAM,
|
|
1
|
+
{"version":3,"file":"QGauge.vue.d.ts","sourceRoot":"","sources":["../../../src/components/QGauge/QGauge.vue"],"names":[],"mappings":"AA+JA;AAugBC,OAAO,EAAE,aAAa,EAAE,MAAM,aAAa,CAAA;AAO3C,OAAO,KAAK,EAAE,WAAW,EAAE,MAAM,GAAG,CAAA;AA4BpC,KAAK,WAAW,GAAG,WAAW,CAAC;AA6UhC,KAAK,iBAAiB,GAAG;IACzB,UAAU,CAAC,EAAE,MAAM,CAAC;CACnB,GAAG,WAAW,CAAC;AAKhB,iBAAS,cAAc;WA6LT,OAAO,IAA6B;;QAngBhD;;;;WAIG;gBACK,CAAC,KAAK,EAAE;YAAE,KAAK,EAAE,MAAM,CAAC;YAAC,GAAG,EAAE,MAAM,CAAC;YAAC,GAAG,EAAE,MAAM,CAAA;SAAE,KAAK,OAAO;;QALvE;;;;WAIG;gBACK,CAAC,KAAK,EAAE;YAAE,KAAK,EAAE,MAAM,CAAC;YAAC,GAAG,EAAE,MAAM,CAAC;YAAC,GAAG,EAAE,MAAM,CAAA;SAAE,KAAK,OAAO;;;;EAmgBxE;AAkCD,KAAK,oBAAoB,GAAG,UAAU,CAAC,OAAO,cAAc,CAAC,CAAC;AAC9D,QAAA,MAAM,eAAe;;;;;;;;;;;;wFASnB,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 {
|
|
2
|
-
import {
|
|
3
|
-
import {
|
|
1
|
+
import { useId as e } from "../../composables/useId/index.js";
|
|
2
|
+
import { useTheme as t } from "../../composables/theme.js";
|
|
3
|
+
import { resolveColor as n } from "../../composables/useColor/index.js";
|
|
4
4
|
import { DEFAULT_TEXTS as r } from "./constants.js";
|
|
5
5
|
import { Fragment as i, computed as a, createCommentVNode as o, createElementBlock as s, createElementVNode as c, createTextVNode as l, defineComponent as u, mergeModels as d, normalizeClass as f, normalizeStyle as ee, openBlock as p, renderList as m, renderSlot as te, toDisplayString as h, toRef as g, unref as _, useModel as ne } from "vue";
|
|
6
6
|
//#region src/components/QGauge/QGauge.vue?vue&type=script&setup=true&lang.ts
|
|
@@ -79,7 +79,7 @@ var re = [
|
|
|
79
79
|
}),
|
|
80
80
|
emits: ["update:modelValue"],
|
|
81
81
|
setup(r) {
|
|
82
|
-
let u = r, d = ne(r, "modelValue"), A = k - O, j =
|
|
82
|
+
let u = r, d = ne(r, "modelValue"), A = k - O, j = e(g(u, "id")), Te = t(), M = a(() => Number.isFinite(u.min) ? u.min : 0), N = a(() => Number.isFinite(u.max) && u.max > M.value ? u.max : M.value + 1), P = a(() => Number.isFinite(d.value) ? d.value : M.value), F = a(() => Math.min(N.value, Math.max(M.value, P.value))), I = a(() => typeof u.target == "number" && Number.isFinite(u.target) ? u.target : void 0), L = a(() => `${j.value}-label`), R = a(() => !!u.label), Ee = a(() => !!u.unit), De = a(() => !!u.secondaryLabel), z = a(() => typeof u.valueLabel == "string" ? u.valueLabel : u.valueLabel ? u.valueLabel(P.value, M.value, N.value) : String(P.value)), B = a(() => {
|
|
83
83
|
if (I.value === void 0) return;
|
|
84
84
|
if (typeof u.targetLabel == "string") return u.targetLabel;
|
|
85
85
|
if (u.targetLabel) return u.targetLabel(I.value, M.value, N.value);
|
|
@@ -96,13 +96,13 @@ var re = [
|
|
|
96
96
|
if (H.value) return H.value === "achieved" ? u.texts.targetAchieved : u.texts.targetNotAchieved;
|
|
97
97
|
}), U = a(() => (u.ranges ?? []).flatMap((e) => {
|
|
98
98
|
if (!Number.isFinite(e.from) || !Number.isFinite(e.to) || e.to <= e.from) return [];
|
|
99
|
-
let
|
|
100
|
-
return r <=
|
|
101
|
-
from:
|
|
99
|
+
let t = Math.max(M.value, e.from), r = Math.min(N.value, e.to);
|
|
100
|
+
return r <= t ? [] : [{
|
|
101
|
+
from: t,
|
|
102
102
|
to: r,
|
|
103
|
-
color:
|
|
103
|
+
color: n(e.color, Te.current.value.scheme),
|
|
104
104
|
label: e.label,
|
|
105
|
-
path: Z(Y(
|
|
105
|
+
path: Z(Y(t), Y(r), b)
|
|
106
106
|
}];
|
|
107
107
|
})), W = a(() => U.value.flatMap((e) => e.label ? [{
|
|
108
108
|
from: e.from,
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"QIcon.vue.d.ts","sourceRoot":"","sources":["../../../src/components/QIcon/QIcon.vue"],"names":[],"mappings":"AAQA;
|
|
1
|
+
{"version":3,"file":"QIcon.vue.d.ts","sourceRoot":"","sources":["../../../src/components/QIcon/QIcon.vue"],"names":[],"mappings":"AAQA;AAsEC,OAAO,KAAK,EAAE,UAAU,EAAE,MAAM,GAAG,CAAA;;;;AAmGpC,wBAQG"}
|