@eodash/eodash 5.0.0-rc.3 → 5.1.0
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/README.md +1 -0
- package/core/client/App.vue +8 -2
- package/core/client/asWebComponent.js +5 -5
- package/core/client/components/DashboardLayout.vue +42 -25
- package/core/client/components/EodashOverlay.vue +1 -1
- package/core/client/components/ErrorAlert.vue +2 -2
- package/core/client/components/Footer.vue +4 -4
- package/core/client/components/Header.vue +3 -3
- package/core/client/components/MobileLayout.vue +9 -10
- package/core/client/composables/DefineEodash.js +38 -43
- package/core/client/composables/DefineTemplate.js +4 -2
- package/core/client/composables/DefineWidgets.js +14 -8
- package/core/client/composables/index.js +273 -23
- package/core/client/eodashSTAC/EodashCollection.js +80 -47
- package/core/client/eodashSTAC/helpers.js +136 -27
- package/core/client/eodashSTAC/parquet.js +145 -0
- package/core/client/eodashSTAC/triggers.js +6 -3
- package/core/client/plugins/index.js +4 -3
- package/core/client/plugins/vuetify.js +3 -0
- package/core/client/store/actions.js +21 -4
- package/core/client/store/stac.js +93 -56
- package/core/client/store/states.js +15 -5
- package/core/client/types.ts +59 -43
- package/core/client/utils/index.js +79 -0
- package/core/client/utils/keys.js +2 -2
- package/core/client/utils/states.js +30 -5
- package/core/client/views/Dashboard.vue +36 -32
- package/core/client/vite-env.d.ts +7 -0
- package/dist/client/{DashboardLayout-t_PavJPO.js → DashboardLayout-ByVs1DrY.js} +23 -12
- package/dist/client/{DynamicWebComponent-y07rVJch.js → DynamicWebComponent-C3W7HSQm.js} +1 -1
- package/dist/client/{EodashDatePicker-CcOfyzGD.js → EodashDatePicker-BIAf1sMT.js} +59 -32
- package/dist/client/{EodashItemFilter-B9HCvIMi.js → EodashItemFilter-DPznh8UB.js} +20 -10
- package/dist/client/{EodashLayerControl-KStn7Nb_.js → EodashLayerControl-Bhxjw4V2.js} +29 -16
- package/dist/client/EodashLayoutSwitcher-C5qTEffW.js +61 -0
- package/dist/client/EodashMapBtns-WoGq8MuV.js +173 -0
- package/dist/client/{EodashStacInfo-C_hDy6Pd.js → EodashStacInfo-CSvvF2jI.js} +3 -18
- package/dist/client/{EodashTools-BXflvRf8.js → EodashTools-Cv1SXQ5y.js} +13 -13
- package/dist/client/{ExportState-C0QRemK1.js → ExportState-D-iuwaad.js} +58 -52
- package/dist/client/{Footer-7VGyGUAs.js → Footer-CyF0zRAk.js} +15 -13
- package/dist/client/{Header-BQJnXHYq.js → Header-CgD8jDKU.js} +33 -28
- package/dist/client/{MobileLayout-b8nQ-Vyl.js → MobileLayout-EKQ_kpSh.js} +69 -60
- package/dist/client/{PopUp-DgNrh9Df.js → PopUp-BsYLvWch.js} +19 -10
- package/dist/client/ProcessList-C2xsLU2_.js +191 -0
- package/dist/client/{VImg-D4eT3IQ1.js → VImg-OHe8YTs2.js} +24 -24
- package/dist/client/{VMain-C3hN2-H3.js → VMain-PryTLU4a.js} +7 -7
- package/dist/client/{VOverlay-tAeNygaA.js → VOverlay-yUn7p-Uf.js} +64 -27
- package/dist/client/{VTooltip-B0Q3iHMZ.js → VTooltip-DZ0fjpB3.js} +13 -10
- package/dist/client/{WidgetsContainer-CtDHfCYf.js → WidgetsContainer-B9LBadcC.js} +1 -1
- package/dist/client/asWebComponent-By_7_JjS.js +19193 -0
- package/dist/client/async-DkSu_u2K.js +740 -0
- package/dist/client/eo-dash.js +1 -1
- package/dist/client/{forwardRefs-CIFAqXaZ.js → forwardRefs-BXxrv98s.js} +31 -4
- package/dist/client/handling-CgmFXkW6.js +1212 -0
- package/dist/client/helpers-Dy0Q13tP.js +4534 -0
- package/dist/client/{index-DvcUndod.js → index-BuhOHXKv.js} +2 -4
- package/dist/client/{index-BQ16n4Sk.js → index-Ch_HchK3.js} +39 -32
- package/dist/client/{index-Cv7HBz49.js → index-Dqj4tbx2.js} +2 -2
- package/dist/client/index-skjhlH8u.js +376 -0
- package/dist/client/{ssrBoot-BP7SYRyC.js → ssrBoot-Zgc_Ttvi.js} +2 -2
- package/dist/client/templates.js +850 -0
- package/dist/client/transition-C98Yn4Vo.js +40 -0
- package/dist/node/cli.js +16 -6
- package/dist/node/types.d.ts +1 -1
- package/dist/types/core/client/App.vue.d.ts +2 -2
- package/dist/types/core/client/asWebComponent.d.ts +1 -1
- package/dist/types/core/client/components/DynamicWebComponent.vue.d.ts +1 -3
- package/dist/types/core/client/components/Footer.vue.d.ts +1 -105
- package/dist/types/core/client/components/IframeWrapper.vue.d.ts +1 -1
- package/dist/types/core/client/components/MobileLayout.vue.d.ts +1 -324
- package/dist/types/core/client/composables/DefineEodash.d.ts +2 -2
- package/dist/types/core/client/composables/DefineTemplate.d.ts +1 -1
- package/dist/types/core/client/composables/DefineWidgets.d.ts +4 -4
- package/dist/types/core/client/composables/index.d.ts +24 -2
- package/dist/types/core/client/eodashSTAC/EodashCollection.d.ts +9 -6
- package/dist/types/core/client/eodashSTAC/helpers.d.ts +20 -5
- package/dist/types/core/client/eodashSTAC/parquet.d.ts +2 -0
- package/dist/types/core/client/plugins/vuetify.d.ts +7 -4
- package/dist/types/core/client/store/actions.d.ts +3 -2
- package/dist/types/core/client/store/stac.d.ts +16 -13
- package/dist/types/core/client/store/states.d.ts +14 -4
- package/dist/types/core/client/types.d.ts +45 -30
- package/dist/types/core/client/utils/index.d.ts +2 -0
- package/dist/types/core/client/utils/keys.d.ts +4 -4
- package/dist/types/core/client/utils/states.d.ts +59 -47
- package/dist/types/core/client/views/Dashboard.vue.d.ts +2 -2
- package/dist/types/templates/baseConfig.d.ts +4 -0
- package/dist/types/templates/compare.d.ts +210 -0
- package/dist/types/templates/expert.d.ts +151 -0
- package/dist/types/templates/index.d.ts +6 -0
- package/dist/types/templates/light.d.ts +145 -0
- package/dist/types/widgets/EodashDatePicker.vue.d.ts +1 -458
- package/dist/types/widgets/EodashItemFilter.vue.d.ts +3 -3
- package/dist/types/widgets/EodashLayerControl.vue.d.ts +14 -7
- package/dist/types/widgets/EodashLayoutSwitcher.vue.d.ts +1 -3
- package/dist/types/widgets/EodashMap/index.vue.d.ts +1 -4
- package/dist/types/widgets/EodashMapBtns.vue.d.ts +8 -8
- package/dist/types/widgets/EodashProcess/ProcessList.vue.d.ts +8 -1
- package/dist/types/widgets/EodashProcess/index.vue.d.ts +8 -4
- package/dist/types/widgets/EodashProcess/methods/async.d.ts +18 -18
- package/dist/types/widgets/EodashProcess/methods/composables.d.ts +3 -2
- package/dist/types/widgets/EodashProcess/methods/custom-endpoints/chart/index.d.ts +1 -0
- package/dist/types/widgets/EodashProcess/methods/custom-endpoints/chart/sentinelhub-endpoint.d.ts +6 -0
- package/dist/types/widgets/EodashProcess/methods/custom-endpoints/chart/veda-endpoint.d.ts +4 -0
- package/dist/types/widgets/EodashProcess/methods/custom-endpoints/layers/eoxhub-workspaces-endpoint.d.ts +5 -0
- package/dist/types/widgets/EodashProcess/methods/custom-endpoints/layers/index.d.ts +1 -0
- package/dist/types/widgets/EodashProcess/methods/handling.d.ts +12 -5
- package/dist/types/widgets/EodashProcess/methods/outputs.d.ts +72 -41
- package/dist/types/widgets/EodashProcess/methods/utils.d.ts +41 -21
- package/dist/types/widgets/EodashProcess/states.d.ts +11 -0
- package/dist/types/widgets/EodashProcess/types.d.ts +41 -0
- package/dist/types/widgets/EodashStacInfo.vue.d.ts +14 -14
- package/dist/types/widgets/EodashTools.vue.d.ts +3 -3
- package/dist/types/widgets/ExportState.vue.d.ts +1 -1
- package/dist/types/widgets/PopUp.vue.d.ts +11 -16
- package/dist/types/widgets/WidgetsContainer.vue.d.ts +3 -6
- package/package.json +53 -45
- package/templates/baseConfig.js +68 -0
- package/templates/compare.js +162 -0
- package/templates/expert.js +123 -0
- package/templates/index.js +8 -0
- package/templates/light.js +130 -0
- package/widgets/EodashDatePicker.vue +80 -31
- package/widgets/EodashItemFilter.vue +26 -11
- package/widgets/EodashLayerControl.vue +20 -11
- package/widgets/EodashLayoutSwitcher.vue +6 -3
- package/widgets/EodashMap/index.vue +3 -8
- package/widgets/EodashMap/methods/create-layers-config.js +4 -3
- package/widgets/EodashMap/methods/index.js +33 -23
- package/widgets/EodashMapBtns.vue +83 -41
- package/widgets/EodashProcess/ProcessList.vue +34 -10
- package/widgets/EodashProcess/index.vue +55 -20
- package/widgets/EodashProcess/methods/async.js +77 -59
- package/widgets/EodashProcess/methods/composables.js +21 -14
- package/widgets/EodashProcess/methods/custom-endpoints/chart/index.js +35 -0
- package/widgets/EodashProcess/methods/custom-endpoints/chart/sentinelhub-endpoint.js +275 -0
- package/widgets/EodashProcess/methods/custom-endpoints/chart/veda-endpoint.js +116 -0
- package/widgets/EodashProcess/methods/custom-endpoints/layers/eoxhub-workspaces-endpoint.js +94 -0
- package/widgets/EodashProcess/methods/custom-endpoints/layers/index.js +33 -0
- package/widgets/EodashProcess/methods/handling.js +127 -80
- package/widgets/EodashProcess/methods/outputs.js +376 -125
- package/widgets/EodashProcess/methods/utils.js +398 -10
- package/widgets/EodashProcess/states.js +13 -0
- package/widgets/EodashProcess/types.ts +46 -0
- package/widgets/EodashStacInfo.vue +2 -17
- package/widgets/EodashTools.vue +13 -13
- package/widgets/WidgetsContainer.vue +1 -1
- package/core/client/eodash.js +0 -454
- package/dist/client/EodashLayoutSwitcher-DqeFO3RN.js +0 -52
- package/dist/client/EodashMapBtns-5BF27qJB.js +0 -131
- package/dist/client/ProcessList-C62SOVO6.js +0 -484
- package/dist/client/asWebComponent-BJ2NWunV.js +0 -12479
- package/dist/client/eo-dash.css +0 -5
- package/dist/client/index-Da5xXX6Q.js +0 -780
- package/dist/client/transition-Cdb4K27U.js +0 -37
- package/dist/types/core/client/eodash.d.ts +0 -8
|
@@ -0,0 +1,191 @@
|
|
|
1
|
+
import { ref, createVNode, normalizeStyle, normalizeClass, createElementVNode, toRefs, onMounted, createElementBlock, openBlock, createBlock, createCommentVNode, unref, withCtx, Fragment, renderList, toDisplayString, withDirectives, toRef } from 'vue';
|
|
2
|
+
import { mdiUploadBox, mdiDownloadBox, mdiTrashCanOutline } from '@mdi/js';
|
|
3
|
+
import { g as genericComponent, p as propsFactory, b as provideTheme, A as useDensity, a as useRender, f as makeThemeProps, h as makeTagProps, D as makeDensityProps, i as makeComponentProps, q as convertToUnit, _ as _export_sfc, Y as useSTAcStore, a6 as useOnLayersUpdate, V as VBtn } from './asWebComponent-By_7_JjS.js';
|
|
4
|
+
import { C as compareIndicator, B as indicator } from './helpers-Dy0Q13tP.js';
|
|
5
|
+
import { u as updateJobsStatus, l as loadProcess, j as downloadPreviousResults, k as deleteJob } from './async-DkSu_u2K.js';
|
|
6
|
+
import { T as Tooltip } from './index-Dqj4tbx2.js';
|
|
7
|
+
|
|
8
|
+
/**
|
|
9
|
+
* The list of job result from the server
|
|
10
|
+
* {job_start_datetime: string, job_end_datetime: string,status: string}
|
|
11
|
+
* @type {import("vue").Ref<import("./types").AsyncJob[]>}
|
|
12
|
+
**/
|
|
13
|
+
const jobs = ref([]);
|
|
14
|
+
/**
|
|
15
|
+
* The list of jobs results from the server for the compare map
|
|
16
|
+
* @type {import("vue").Ref<import("./types").AsyncJob[]>}
|
|
17
|
+
*/
|
|
18
|
+
const compareJobs = ref([]);
|
|
19
|
+
|
|
20
|
+
const _style_0 = "div.v-table__wrapper{overflow:hidden!important;height:max-content!important}";
|
|
21
|
+
|
|
22
|
+
const makeVTableProps = propsFactory({
|
|
23
|
+
fixedHeader: Boolean,
|
|
24
|
+
fixedFooter: Boolean,
|
|
25
|
+
height: [Number, String],
|
|
26
|
+
hover: Boolean,
|
|
27
|
+
striped: {
|
|
28
|
+
type: String,
|
|
29
|
+
default: null,
|
|
30
|
+
validator: v => ['even', 'odd'].includes(v)
|
|
31
|
+
},
|
|
32
|
+
...makeComponentProps(),
|
|
33
|
+
...makeDensityProps(),
|
|
34
|
+
...makeTagProps(),
|
|
35
|
+
...makeThemeProps()
|
|
36
|
+
}, 'VTable');
|
|
37
|
+
const VTable = genericComponent()({
|
|
38
|
+
name: 'VTable',
|
|
39
|
+
props: makeVTableProps(),
|
|
40
|
+
setup(props, _ref) {
|
|
41
|
+
let {
|
|
42
|
+
slots} = _ref;
|
|
43
|
+
const {
|
|
44
|
+
themeClasses
|
|
45
|
+
} = provideTheme(props);
|
|
46
|
+
const {
|
|
47
|
+
densityClasses
|
|
48
|
+
} = useDensity(props);
|
|
49
|
+
useRender(() => createVNode(props.tag, {
|
|
50
|
+
"class": normalizeClass(['v-table', {
|
|
51
|
+
'v-table--fixed-height': !!props.height,
|
|
52
|
+
'v-table--fixed-header': props.fixedHeader,
|
|
53
|
+
'v-table--fixed-footer': props.fixedFooter,
|
|
54
|
+
'v-table--has-top': !!slots.top,
|
|
55
|
+
'v-table--has-bottom': !!slots.bottom,
|
|
56
|
+
'v-table--hover': props.hover,
|
|
57
|
+
'v-table--striped-even': props.striped === 'even',
|
|
58
|
+
'v-table--striped-odd': props.striped === 'odd'
|
|
59
|
+
}, themeClasses.value, densityClasses.value, props.class]),
|
|
60
|
+
"style": normalizeStyle(props.style)
|
|
61
|
+
}, {
|
|
62
|
+
default: () => [slots.top?.(), slots.default ? createElementVNode("div", {
|
|
63
|
+
"class": "v-table__wrapper",
|
|
64
|
+
"style": {
|
|
65
|
+
height: convertToUnit(props.height)
|
|
66
|
+
}
|
|
67
|
+
}, [createElementVNode("table", null, [slots.default()])]) : slots.wrapper?.(), slots.bottom?.()]
|
|
68
|
+
}));
|
|
69
|
+
return {};
|
|
70
|
+
}
|
|
71
|
+
});
|
|
72
|
+
|
|
73
|
+
const _hoisted_1 = { style: {"padding":"0px"} };
|
|
74
|
+
const _hoisted_2 = { style: {"padding":"0px"} };
|
|
75
|
+
const _hoisted_3 = { style: {"padding":"0px"} };
|
|
76
|
+
|
|
77
|
+
const _sfc_main = {
|
|
78
|
+
__name: 'ProcessList',
|
|
79
|
+
props: {
|
|
80
|
+
enableCompare: {
|
|
81
|
+
type: Boolean,
|
|
82
|
+
default: false,
|
|
83
|
+
},
|
|
84
|
+
mapElement: {
|
|
85
|
+
/** @type {import("vue").PropType<import("@eox/map").EOxMap | null>} */
|
|
86
|
+
type: Object,
|
|
87
|
+
default: () => null,
|
|
88
|
+
},
|
|
89
|
+
},
|
|
90
|
+
setup(__props) {
|
|
91
|
+
|
|
92
|
+
|
|
93
|
+
const { selectedStac, selectedCompareStac } = toRefs(useSTAcStore());
|
|
94
|
+
const currentJobs = __props.enableCompare ? compareJobs : jobs;
|
|
95
|
+
const currentIndicator = __props.enableCompare ? compareIndicator : indicator;
|
|
96
|
+
const currentStac = __props.enableCompare ? selectedCompareStac : selectedStac;
|
|
97
|
+
|
|
98
|
+
onMounted(() => {
|
|
99
|
+
updateJobsStatus(currentJobs, currentIndicator.value);
|
|
100
|
+
});
|
|
101
|
+
|
|
102
|
+
useOnLayersUpdate(() => updateJobsStatus(currentJobs, currentIndicator.value));
|
|
103
|
+
|
|
104
|
+
return (_ctx, _cache) => {
|
|
105
|
+
|
|
106
|
+
|
|
107
|
+
|
|
108
|
+
|
|
109
|
+
return (openBlock(), createElementBlock("div", null, [
|
|
110
|
+
(unref(currentJobs).length)
|
|
111
|
+
? (openBlock(), createBlock(VTable, {
|
|
112
|
+
key: 0,
|
|
113
|
+
density: "compact",
|
|
114
|
+
style: {"background-color":"transparent"}
|
|
115
|
+
}, {
|
|
116
|
+
default: withCtx(() => [
|
|
117
|
+
_cache[0] || (_cache[0] = createElementVNode("thead", null, [
|
|
118
|
+
createElementVNode("tr", null, [
|
|
119
|
+
createElementVNode("th", { class: "text-left" }, "Executed on"),
|
|
120
|
+
createElementVNode("th", { class: "text-left" }, "Status"),
|
|
121
|
+
createElementVNode("th", { class: "text-left" }),
|
|
122
|
+
createElementVNode("th", { class: "text-left" }),
|
|
123
|
+
createElementVNode("th", { class: "text-left" })
|
|
124
|
+
])
|
|
125
|
+
], -1 /* CACHED */)),
|
|
126
|
+
createElementVNode("tbody", null, [
|
|
127
|
+
(openBlock(true), createElementBlock(Fragment, null, renderList(unref(currentJobs), (item) => {
|
|
128
|
+
return (openBlock(), createElementBlock("tr", {
|
|
129
|
+
key: item.jobID
|
|
130
|
+
}, [
|
|
131
|
+
createElementVNode("td", null, toDisplayString(new Date(item.job_start_datetime).toISOString().slice(0, 16)), 1 /* TEXT */),
|
|
132
|
+
createElementVNode("td", null, toDisplayString(item.status), 1 /* TEXT */),
|
|
133
|
+
createElementVNode("td", _hoisted_1, [
|
|
134
|
+
withDirectives(createVNode(VBtn, {
|
|
135
|
+
disabled: item.status !== 'successful',
|
|
136
|
+
color: "primary",
|
|
137
|
+
onClick: $event => (unref(loadProcess)(item, unref(currentStac), __props.mapElement)),
|
|
138
|
+
icon: [unref(mdiUploadBox)],
|
|
139
|
+
variant: "text"
|
|
140
|
+
}, null, 8 /* PROPS */, ["disabled", "onClick", "icon"]), [
|
|
141
|
+
[Tooltip, 'Load results to map']
|
|
142
|
+
])
|
|
143
|
+
]),
|
|
144
|
+
createElementVNode("td", _hoisted_2, [
|
|
145
|
+
withDirectives(createVNode(VBtn, {
|
|
146
|
+
disabled: item.status !== 'successful',
|
|
147
|
+
color: "primary",
|
|
148
|
+
onClick: $event => (unref(downloadPreviousResults)(item, unref(currentStac))),
|
|
149
|
+
icon: [unref(mdiDownloadBox)],
|
|
150
|
+
variant: "text"
|
|
151
|
+
}, null, 8 /* PROPS */, ["disabled", "onClick", "icon"]), [
|
|
152
|
+
[Tooltip, 'Download results']
|
|
153
|
+
])
|
|
154
|
+
]),
|
|
155
|
+
createElementVNode("td", _hoisted_3, [
|
|
156
|
+
withDirectives(createVNode(VBtn, {
|
|
157
|
+
color: "#ff5252",
|
|
158
|
+
onClick: $event => (
|
|
159
|
+
unref(deleteJob)(
|
|
160
|
+
toRef(() => unref(currentJobs)),
|
|
161
|
+
item,
|
|
162
|
+
unref(currentIndicator),
|
|
163
|
+
)
|
|
164
|
+
),
|
|
165
|
+
icon: [unref(mdiTrashCanOutline)],
|
|
166
|
+
variant: "text"
|
|
167
|
+
}, null, 8 /* PROPS */, ["onClick", "icon"]), [
|
|
168
|
+
[Tooltip, 'Remove job']
|
|
169
|
+
])
|
|
170
|
+
])
|
|
171
|
+
]))
|
|
172
|
+
}), 128 /* KEYED_FRAGMENT */))
|
|
173
|
+
])
|
|
174
|
+
]),
|
|
175
|
+
_: 1 /* STABLE */,
|
|
176
|
+
__: [0]
|
|
177
|
+
}))
|
|
178
|
+
: createCommentVNode("v-if", true)
|
|
179
|
+
]))
|
|
180
|
+
}
|
|
181
|
+
}
|
|
182
|
+
|
|
183
|
+
};
|
|
184
|
+
const ProcessList = /*#__PURE__*/_export_sfc(_sfc_main, [['styles',[_style_0]]]);
|
|
185
|
+
|
|
186
|
+
const ProcessList$1 = /*#__PURE__*/Object.freeze(/*#__PURE__*/Object.defineProperty({
|
|
187
|
+
__proto__: null,
|
|
188
|
+
default: ProcessList
|
|
189
|
+
}, Symbol.toStringTag, { value: 'Module' }));
|
|
190
|
+
|
|
191
|
+
export { ProcessList as P, ProcessList$1 as a, compareJobs as c, jobs as j };
|
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
import {
|
|
2
|
-
import {
|
|
3
|
-
import { m as makeTransitionProps, M as MaybeTransition } from './transition-
|
|
1
|
+
import { createElementVNode, normalizeStyle, normalizeClass, computed, shallowRef, ref, watch, onBeforeMount, nextTick, onBeforeUnmount, toRef, withDirectives, createVNode, mergeProps, Fragment, vShow } from 'vue';
|
|
2
|
+
import { at as SUPPORTS_INTERSECTION, g as genericComponent, p as propsFactory, H as useDimension, a as useRender, J as makeDimensionProps, i as makeComponentProps, B as useBackgroundColor, M as useRounded, au as getCurrentInstance, q as convertToUnit, O as makeRoundedProps } from './asWebComponent-By_7_JjS.js';
|
|
3
|
+
import { m as makeTransitionProps, M as MaybeTransition } from './transition-C98Yn4Vo.js';
|
|
4
4
|
|
|
5
5
|
// Utilities
|
|
6
6
|
function mounted(el, binding) {
|
|
@@ -77,16 +77,16 @@ const VResponsive = genericComponent()({
|
|
|
77
77
|
const {
|
|
78
78
|
dimensionStyles
|
|
79
79
|
} = useDimension(props);
|
|
80
|
-
useRender(() =>
|
|
81
|
-
"class": ['v-responsive', {
|
|
80
|
+
useRender(() => createElementVNode("div", {
|
|
81
|
+
"class": normalizeClass(['v-responsive', {
|
|
82
82
|
'v-responsive--inline': props.inline
|
|
83
|
-
}, props.class],
|
|
84
|
-
"style": [dimensionStyles.value, props.style]
|
|
85
|
-
}, [
|
|
83
|
+
}, props.class]),
|
|
84
|
+
"style": normalizeStyle([dimensionStyles.value, props.style])
|
|
85
|
+
}, [createElementVNode("div", {
|
|
86
86
|
"class": "v-responsive__sizer",
|
|
87
|
-
"style": aspectStyles.value
|
|
88
|
-
}, null), slots.additional?.(), slots.default &&
|
|
89
|
-
"class": ['v-responsive__content', props.contentClass]
|
|
87
|
+
"style": normalizeStyle(aspectStyles.value)
|
|
88
|
+
}, null), slots.additional?.(), slots.default && createElementVNode("div", {
|
|
89
|
+
"class": normalizeClass(['v-responsive__content', props.contentClass])
|
|
90
90
|
}, [slots.default()])]));
|
|
91
91
|
return {};
|
|
92
92
|
}
|
|
@@ -132,7 +132,7 @@ const makeVImgProps = propsFactory({
|
|
|
132
132
|
const VImg = genericComponent()({
|
|
133
133
|
name: 'VImg',
|
|
134
134
|
directives: {
|
|
135
|
-
|
|
135
|
+
vIntersect: Intersect
|
|
136
136
|
},
|
|
137
137
|
props: makeVImgProps(),
|
|
138
138
|
emits: {
|
|
@@ -148,7 +148,7 @@ const VImg = genericComponent()({
|
|
|
148
148
|
const {
|
|
149
149
|
backgroundColorClasses,
|
|
150
150
|
backgroundColorStyles
|
|
151
|
-
} = useBackgroundColor(
|
|
151
|
+
} = useBackgroundColor(() => props.color);
|
|
152
152
|
const {
|
|
153
153
|
roundedClasses
|
|
154
154
|
} = useRounded(props);
|
|
@@ -255,14 +255,14 @@ const VImg = genericComponent()({
|
|
|
255
255
|
};
|
|
256
256
|
poll();
|
|
257
257
|
}
|
|
258
|
-
const containClasses =
|
|
258
|
+
const containClasses = toRef(() => ({
|
|
259
259
|
'v-img__img--cover': props.cover,
|
|
260
260
|
'v-img__img--contain': !props.cover
|
|
261
261
|
}));
|
|
262
262
|
const __image = () => {
|
|
263
263
|
if (!normalisedSrc.value.src || state.value === 'idle') return null;
|
|
264
|
-
const img =
|
|
265
|
-
"class": ['v-img__img', containClasses.value],
|
|
264
|
+
const img = createElementVNode("img", {
|
|
265
|
+
"class": normalizeClass(['v-img__img', containClasses.value]),
|
|
266
266
|
"style": {
|
|
267
267
|
objectPosition: props.position
|
|
268
268
|
},
|
|
@@ -282,7 +282,7 @@ const VImg = genericComponent()({
|
|
|
282
282
|
"transition": props.transition,
|
|
283
283
|
"appear": true
|
|
284
284
|
}, {
|
|
285
|
-
default: () => [withDirectives(sources ?
|
|
285
|
+
default: () => [withDirectives(sources ? createElementVNode("picture", {
|
|
286
286
|
"class": "v-img__picture"
|
|
287
287
|
}, [sources, img]) : img, [[vShow, state.value === 'loaded']])]
|
|
288
288
|
});
|
|
@@ -290,8 +290,8 @@ const VImg = genericComponent()({
|
|
|
290
290
|
const __preloadImage = () => createVNode(MaybeTransition, {
|
|
291
291
|
"transition": props.transition
|
|
292
292
|
}, {
|
|
293
|
-
default: () => [normalisedSrc.value.lazySrc && state.value !== 'loaded' &&
|
|
294
|
-
"class": ['v-img__img', 'v-img__img--preload', containClasses.value],
|
|
293
|
+
default: () => [normalisedSrc.value.lazySrc && state.value !== 'loaded' && createElementVNode("img", {
|
|
294
|
+
"class": normalizeClass(['v-img__img', 'v-img__img--preload', containClasses.value]),
|
|
295
295
|
"style": {
|
|
296
296
|
objectPosition: props.position
|
|
297
297
|
},
|
|
@@ -308,7 +308,7 @@ const VImg = genericComponent()({
|
|
|
308
308
|
"transition": props.transition,
|
|
309
309
|
"appear": true
|
|
310
310
|
}, {
|
|
311
|
-
default: () => [(state.value === 'loading' || state.value === 'error' && !slots.error) &&
|
|
311
|
+
default: () => [(state.value === 'loading' || state.value === 'error' && !slots.error) && createElementVNode("div", {
|
|
312
312
|
"class": "v-img__placeholder"
|
|
313
313
|
}, [slots.placeholder()])]
|
|
314
314
|
});
|
|
@@ -319,14 +319,14 @@ const VImg = genericComponent()({
|
|
|
319
319
|
"transition": props.transition,
|
|
320
320
|
"appear": true
|
|
321
321
|
}, {
|
|
322
|
-
default: () => [state.value === 'error' &&
|
|
322
|
+
default: () => [state.value === 'error' && createElementVNode("div", {
|
|
323
323
|
"class": "v-img__error"
|
|
324
324
|
}, [slots.error()])]
|
|
325
325
|
});
|
|
326
326
|
};
|
|
327
327
|
const __gradient = () => {
|
|
328
328
|
if (!props.gradient) return null;
|
|
329
|
-
return
|
|
329
|
+
return createElementVNode("div", {
|
|
330
330
|
"class": "v-img__gradient",
|
|
331
331
|
"style": {
|
|
332
332
|
backgroundImage: `linear-gradient(${props.gradient})`
|
|
@@ -362,9 +362,9 @@ const VImg = genericComponent()({
|
|
|
362
362
|
"aria-label": props.alt,
|
|
363
363
|
"role": props.alt ? 'img' : undefined
|
|
364
364
|
}), {
|
|
365
|
-
additional: () =>
|
|
365
|
+
additional: () => createElementVNode(Fragment, null, [createVNode(__image, null, null), createVNode(__preloadImage, null, null), createVNode(__gradient, null, null), createVNode(__placeholder, null, null), createVNode(__error, null, null)]),
|
|
366
366
|
default: slots.default
|
|
367
|
-
}), [[
|
|
367
|
+
}), [[Intersect, {
|
|
368
368
|
handler: init,
|
|
369
369
|
options: props.options
|
|
370
370
|
}, null, {
|
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
import { createVNode } from 'vue';
|
|
2
|
-
import { g as genericComponent, p as propsFactory, H as useDimension, G as useLayout, a as useRender, h as makeTagProps, J as makeDimensionProps, i as makeComponentProps } from './asWebComponent-
|
|
3
|
-
import { u as useSsrBoot } from './ssrBoot-
|
|
1
|
+
import { createVNode, normalizeStyle, normalizeClass, createElementVNode } from 'vue';
|
|
2
|
+
import { g as genericComponent, p as propsFactory, H as useDimension, G as useLayout, a as useRender, h as makeTagProps, J as makeDimensionProps, i as makeComponentProps } from './asWebComponent-By_7_JjS.js';
|
|
3
|
+
import { u as useSsrBoot } from './ssrBoot-Zgc_Ttvi.js';
|
|
4
4
|
|
|
5
5
|
const makeVMainProps = propsFactory({
|
|
6
6
|
scrollable: Boolean,
|
|
@@ -27,12 +27,12 @@ const VMain = genericComponent()({
|
|
|
27
27
|
ssrBootStyles
|
|
28
28
|
} = useSsrBoot();
|
|
29
29
|
useRender(() => createVNode(props.tag, {
|
|
30
|
-
"class": ['v-main', {
|
|
30
|
+
"class": normalizeClass(['v-main', {
|
|
31
31
|
'v-main--scrollable': props.scrollable
|
|
32
|
-
}, props.class],
|
|
33
|
-
"style": [mainStyles.value, ssrBootStyles.value, dimensionStyles.value, props.style]
|
|
32
|
+
}, props.class]),
|
|
33
|
+
"style": normalizeStyle([mainStyles.value, ssrBootStyles.value, dimensionStyles.value, props.style])
|
|
34
34
|
}, {
|
|
35
|
-
default: () => [props.scrollable ?
|
|
35
|
+
default: () => [props.scrollable ? createElementVNode("div", {
|
|
36
36
|
"class": "v-main__scroller"
|
|
37
37
|
}, [slots.default?.()]) : slots.default?.()]
|
|
38
38
|
}));
|
|
@@ -1,7 +1,7 @@
|
|
|
1
|
-
import { computed, watch, onScopeDispose, nextTick, ref, watchEffect, effectScope, inject, mergeProps, shallowRef, onMounted, reactive, provide, toRaw, readonly, warn,
|
|
2
|
-
import {
|
|
3
|
-
import { g as getTargetBox, B as Box,
|
|
4
|
-
import { m as makeTransitionProps, M as MaybeTransition } from './transition-
|
|
1
|
+
import { computed, watch, onScopeDispose, nextTick, ref, watchEffect, effectScope, inject, mergeProps, shallowRef, onMounted, reactive, provide, toValue, toRaw, toRef, readonly, warn, onBeforeUnmount, createElementVNode, Fragment, createVNode, Teleport, withDirectives, vShow, Transition } from 'vue';
|
|
2
|
+
import { aw as isOn, ax as eventName, p as propsFactory, ay as destructComputed, az as parseAnchor, aA as flipSide, aB as flipAlign, aC as flipCorner, aD as CircularBuffer, aE as deepEqual, a9 as consoleError, aF as getAxis, q as convertToUnit, R as clamp, I as IN_BROWSER, T as useToggleScope, aG as defer, au as getCurrentInstance, aH as templateRef, aI as matchesSelector, r as useDisplay, f as makeThemeProps, J as makeDimensionProps, i as makeComponentProps, g as genericComponent, j as useProxiedModel, b as provideTheme, c as useRtl, B as useBackgroundColor, H as useDimension, aJ as useRouter, aK as useBackButton, a as useRender } from './asWebComponent-By_7_JjS.js';
|
|
3
|
+
import { g as getTargetBox, e as getElementBox, B as Box, h as getOverflow, n as nullifyTransforms, m as makeLazyProps, u as useLazy, b as useScopeId, a as animate, s as standardEasing } from './forwardRefs-BXxrv98s.js';
|
|
4
|
+
import { m as makeTransitionProps, M as MaybeTransition } from './transition-C98Yn4Vo.js';
|
|
5
5
|
|
|
6
6
|
// Utilities
|
|
7
7
|
const handlers = new WeakMap();
|
|
@@ -283,11 +283,19 @@ function useLocationStrategies(props, data) {
|
|
|
283
283
|
watch(() => props.locationStrategy, reset);
|
|
284
284
|
onScopeDispose(() => {
|
|
285
285
|
window.removeEventListener('resize', onResize);
|
|
286
|
+
visualViewport?.removeEventListener('resize', onVisualResize);
|
|
287
|
+
visualViewport?.removeEventListener('scroll', onVisualScroll);
|
|
286
288
|
updateLocation.value = undefined;
|
|
287
289
|
});
|
|
288
290
|
window.addEventListener('resize', onResize, {
|
|
289
291
|
passive: true
|
|
290
292
|
});
|
|
293
|
+
visualViewport?.addEventListener('resize', onVisualResize, {
|
|
294
|
+
passive: true
|
|
295
|
+
});
|
|
296
|
+
visualViewport?.addEventListener('scroll', onVisualScroll, {
|
|
297
|
+
passive: true
|
|
298
|
+
});
|
|
291
299
|
if (typeof props.locationStrategy === 'function') {
|
|
292
300
|
updateLocation.value = props.locationStrategy(data, props, contentStyles)?.updateLocation;
|
|
293
301
|
} else {
|
|
@@ -298,6 +306,12 @@ function useLocationStrategies(props, data) {
|
|
|
298
306
|
function onResize(e) {
|
|
299
307
|
updateLocation.value?.(e);
|
|
300
308
|
}
|
|
309
|
+
function onVisualResize(e) {
|
|
310
|
+
updateLocation.value?.(e);
|
|
311
|
+
}
|
|
312
|
+
function onVisualScroll(e) {
|
|
313
|
+
updateLocation.value?.(e);
|
|
314
|
+
}
|
|
301
315
|
return {
|
|
302
316
|
contentStyles,
|
|
303
317
|
updateLocation
|
|
@@ -387,8 +401,27 @@ function connectedLocationStrategy(data, props, contentStyles) {
|
|
|
387
401
|
return typeof props.offset === 'number' ? [props.offset, 0] : [0, 0];
|
|
388
402
|
});
|
|
389
403
|
let observe = false;
|
|
404
|
+
let lastFrame = -1;
|
|
405
|
+
const flipped = new CircularBuffer(4);
|
|
390
406
|
const observer = new ResizeObserver(() => {
|
|
391
|
-
if (observe)
|
|
407
|
+
if (!observe) return;
|
|
408
|
+
|
|
409
|
+
// Detect consecutive frames
|
|
410
|
+
requestAnimationFrame(newTime => {
|
|
411
|
+
if (newTime !== lastFrame) flipped.clear();
|
|
412
|
+
requestAnimationFrame(newNewTime => {
|
|
413
|
+
lastFrame = newNewTime;
|
|
414
|
+
});
|
|
415
|
+
});
|
|
416
|
+
if (flipped.isFull) {
|
|
417
|
+
const values = flipped.values();
|
|
418
|
+
if (deepEqual(values.at(-1), values.at(-3)) && !deepEqual(values.at(-1), values.at(-2))) {
|
|
419
|
+
// Flipping is causing a container resize loop
|
|
420
|
+
return;
|
|
421
|
+
}
|
|
422
|
+
}
|
|
423
|
+
const result = updateLocation();
|
|
424
|
+
if (result) flipped.push(result.flipped);
|
|
392
425
|
});
|
|
393
426
|
watch([data.target, data.contentEl], (_ref, _ref2) => {
|
|
394
427
|
let [newTarget, newContentEl] = _ref;
|
|
@@ -403,13 +436,22 @@ function connectedLocationStrategy(data, props, contentStyles) {
|
|
|
403
436
|
onScopeDispose(() => {
|
|
404
437
|
observer.disconnect();
|
|
405
438
|
});
|
|
439
|
+
let targetBox = new Box({
|
|
440
|
+
x: 0,
|
|
441
|
+
y: 0,
|
|
442
|
+
width: 0,
|
|
443
|
+
height: 0
|
|
444
|
+
});
|
|
406
445
|
|
|
407
446
|
// eslint-disable-next-line max-statements
|
|
408
447
|
function updateLocation() {
|
|
409
448
|
observe = false;
|
|
410
449
|
requestAnimationFrame(() => observe = true);
|
|
411
450
|
if (!data.target.value || !data.contentEl.value) return;
|
|
412
|
-
|
|
451
|
+
if (Array.isArray(data.target.value) || data.target.value.offsetParent || data.target.value.getClientRects().length) {
|
|
452
|
+
targetBox = getTargetBox(data.target.value);
|
|
453
|
+
} // Otherwise target element is hidden, use last known value
|
|
454
|
+
|
|
413
455
|
const contentBox = getIntrinsicSize(data.contentEl.value, data.isRtl.value);
|
|
414
456
|
const scrollParents = getScrollParents(data.contentEl.value);
|
|
415
457
|
const viewportMargin = 12;
|
|
@@ -421,13 +463,7 @@ function connectedLocationStrategy(data, props, contentStyles) {
|
|
|
421
463
|
}
|
|
422
464
|
}
|
|
423
465
|
const viewport = scrollParents.reduce((box, el) => {
|
|
424
|
-
const
|
|
425
|
-
const scrollBox = new Box({
|
|
426
|
-
x: el === document.documentElement ? 0 : rect.x,
|
|
427
|
-
y: el === document.documentElement ? 0 : rect.y,
|
|
428
|
-
width: el.clientWidth,
|
|
429
|
-
height: el.clientHeight
|
|
430
|
-
});
|
|
466
|
+
const scrollBox = getElementBox(el);
|
|
431
467
|
if (box) {
|
|
432
468
|
return new Box({
|
|
433
469
|
x: Math.max(box.left, scrollBox.left),
|
|
@@ -594,7 +630,8 @@ function connectedLocationStrategy(data, props, contentStyles) {
|
|
|
594
630
|
});
|
|
595
631
|
return {
|
|
596
632
|
available,
|
|
597
|
-
contentBox
|
|
633
|
+
contentBox,
|
|
634
|
+
flipped
|
|
598
635
|
};
|
|
599
636
|
}
|
|
600
637
|
watch(() => [preferredAnchor.value, preferredOrigin.value, props.offset, props.minWidth, props.minHeight, props.maxWidth, props.maxHeight], () => updateLocation());
|
|
@@ -1112,10 +1149,10 @@ function useStack(isActive, zIndex, disableGlobalStack) {
|
|
|
1112
1149
|
activeChildren: new Set()
|
|
1113
1150
|
});
|
|
1114
1151
|
provide(StackSymbol, stack);
|
|
1115
|
-
const _zIndex = shallowRef(Number(zIndex
|
|
1152
|
+
const _zIndex = shallowRef(Number(toValue(zIndex)));
|
|
1116
1153
|
useToggleScope(isActive, () => {
|
|
1117
1154
|
const lastZIndex = globalStack.at(-1)?.[1];
|
|
1118
|
-
_zIndex.value = lastZIndex ? lastZIndex + 10 : Number(zIndex
|
|
1155
|
+
_zIndex.value = lastZIndex ? lastZIndex + 10 : Number(toValue(zIndex));
|
|
1119
1156
|
if (createStackEntry) {
|
|
1120
1157
|
globalStack.push([vm.uid, _zIndex.value]);
|
|
1121
1158
|
}
|
|
@@ -1135,11 +1172,11 @@ function useStack(isActive, zIndex, disableGlobalStack) {
|
|
|
1135
1172
|
setTimeout(() => globalTop.value = _isTop);
|
|
1136
1173
|
});
|
|
1137
1174
|
}
|
|
1138
|
-
const localTop =
|
|
1175
|
+
const localTop = toRef(() => !stack.activeChildren.size);
|
|
1139
1176
|
return {
|
|
1140
1177
|
globalTop: readonly(globalTop),
|
|
1141
1178
|
localTop,
|
|
1142
|
-
stackStyles:
|
|
1179
|
+
stackStyles: toRef(() => ({
|
|
1143
1180
|
zIndex: _zIndex.value
|
|
1144
1181
|
}))
|
|
1145
1182
|
};
|
|
@@ -1178,7 +1215,7 @@ function Scrim(props) {
|
|
|
1178
1215
|
"name": "fade-transition",
|
|
1179
1216
|
"appear": true
|
|
1180
1217
|
}, {
|
|
1181
|
-
default: () => [props.modelValue &&
|
|
1218
|
+
default: () => [props.modelValue && createElementVNode("div", mergeProps({
|
|
1182
1219
|
"class": ['v-overlay__scrim', props.color.backgroundColorClasses.value],
|
|
1183
1220
|
"style": props.color.backgroundColorStyles.value
|
|
1184
1221
|
}, rest), null)]
|
|
@@ -1219,7 +1256,7 @@ const makeVOverlayProps = propsFactory({
|
|
|
1219
1256
|
const VOverlay = genericComponent()({
|
|
1220
1257
|
name: 'VOverlay',
|
|
1221
1258
|
directives: {
|
|
1222
|
-
ClickOutside
|
|
1259
|
+
vClickOutside: ClickOutside
|
|
1223
1260
|
},
|
|
1224
1261
|
inheritAttrs: false,
|
|
1225
1262
|
props: {
|
|
@@ -1261,14 +1298,14 @@ const VOverlay = genericComponent()({
|
|
|
1261
1298
|
hasContent,
|
|
1262
1299
|
onAfterLeave: _onAfterLeave
|
|
1263
1300
|
} = useLazy(props, isActive);
|
|
1264
|
-
const scrimColor = useBackgroundColor(
|
|
1301
|
+
const scrimColor = useBackgroundColor(() => {
|
|
1265
1302
|
return typeof props.scrim === 'string' ? props.scrim : null;
|
|
1266
|
-
})
|
|
1303
|
+
});
|
|
1267
1304
|
const {
|
|
1268
1305
|
globalTop,
|
|
1269
1306
|
localTop,
|
|
1270
1307
|
stackStyles
|
|
1271
|
-
} = useStack(isActive,
|
|
1308
|
+
} = useStack(isActive, () => props.zIndex, props._disableGlobalStack);
|
|
1272
1309
|
const {
|
|
1273
1310
|
activatorEl,
|
|
1274
1311
|
activatorRef,
|
|
@@ -1399,7 +1436,7 @@ const VOverlay = genericComponent()({
|
|
|
1399
1436
|
_onAfterLeave();
|
|
1400
1437
|
emit('afterLeave');
|
|
1401
1438
|
}
|
|
1402
|
-
useRender(() =>
|
|
1439
|
+
useRender(() => createElementVNode(Fragment, null, [slots.activator?.({
|
|
1403
1440
|
isActive: isActive.value,
|
|
1404
1441
|
targetRef,
|
|
1405
1442
|
props: mergeProps({
|
|
@@ -1409,7 +1446,7 @@ const VOverlay = genericComponent()({
|
|
|
1409
1446
|
"disabled": !teleportTarget.value,
|
|
1410
1447
|
"to": teleportTarget.value
|
|
1411
1448
|
}, {
|
|
1412
|
-
default: () => [
|
|
1449
|
+
default: () => [createElementVNode("div", mergeProps({
|
|
1413
1450
|
"class": ['v-overlay', {
|
|
1414
1451
|
'v-overlay--absolute': props.absolute || props.contained,
|
|
1415
1452
|
'v-overlay--active': isActive.value,
|
|
@@ -1433,13 +1470,13 @@ const VOverlay = genericComponent()({
|
|
|
1433
1470
|
"onAfterEnter": onAfterEnter,
|
|
1434
1471
|
"onAfterLeave": onAfterLeave
|
|
1435
1472
|
}, {
|
|
1436
|
-
default: () => [withDirectives(
|
|
1473
|
+
default: () => [withDirectives(createElementVNode("div", mergeProps({
|
|
1437
1474
|
"ref": contentEl,
|
|
1438
1475
|
"class": ['v-overlay__content', props.contentClass],
|
|
1439
1476
|
"style": [dimensionStyles.value, contentStyles.value]
|
|
1440
1477
|
}, contentEvents.value, props.contentProps), [slots.default?.({
|
|
1441
1478
|
isActive
|
|
1442
|
-
})]), [[vShow, isActive.value], [
|
|
1479
|
+
})]), [[vShow, isActive.value], [ClickOutside, {
|
|
1443
1480
|
handler: onClickOutside,
|
|
1444
1481
|
closeConditional,
|
|
1445
1482
|
include: () => [activatorEl.value]
|
|
@@ -1,10 +1,11 @@
|
|
|
1
|
-
import {
|
|
2
|
-
import { m as makeVOverlayProps, V as VOverlay } from './VOverlay-
|
|
3
|
-
import { b as useScopeId, f as forwardRefs } from './forwardRefs-
|
|
4
|
-
import { g as genericComponent, p as propsFactory, j as useProxiedModel,
|
|
1
|
+
import { useId, toRef, ref, computed, mergeProps, createVNode } from 'vue';
|
|
2
|
+
import { m as makeVOverlayProps, V as VOverlay } from './VOverlay-yUn7p-Uf.js';
|
|
3
|
+
import { b as useScopeId, f as forwardRefs } from './forwardRefs-BXxrv98s.js';
|
|
4
|
+
import { g as genericComponent, p as propsFactory, j as useProxiedModel, a as useRender, o as omit } from './asWebComponent-By_7_JjS.js';
|
|
5
5
|
|
|
6
6
|
const makeVTooltipProps = propsFactory({
|
|
7
7
|
id: String,
|
|
8
|
+
interactive: Boolean,
|
|
8
9
|
text: String,
|
|
9
10
|
...omit(makeVOverlayProps({
|
|
10
11
|
closeOnBack: false,
|
|
@@ -18,7 +19,7 @@ const makeVTooltipProps = propsFactory({
|
|
|
18
19
|
origin: 'auto',
|
|
19
20
|
scrim: false,
|
|
20
21
|
scrollStrategy: 'reposition',
|
|
21
|
-
transition:
|
|
22
|
+
transition: null
|
|
22
23
|
}), ['absolute', 'persistent'])
|
|
23
24
|
}, 'VTooltip');
|
|
24
25
|
const VTooltip = genericComponent()({
|
|
@@ -35,8 +36,8 @@ const VTooltip = genericComponent()({
|
|
|
35
36
|
const {
|
|
36
37
|
scopeId
|
|
37
38
|
} = useScopeId();
|
|
38
|
-
const uid =
|
|
39
|
-
const id =
|
|
39
|
+
const uid = useId();
|
|
40
|
+
const id = toRef(() => props.id || `v-tooltip-${uid}`);
|
|
40
41
|
const overlay = ref();
|
|
41
42
|
const location = computed(() => {
|
|
42
43
|
return props.location.split(' ').length > 1 ? props.location : props.location + ' center';
|
|
@@ -44,8 +45,8 @@ const VTooltip = genericComponent()({
|
|
|
44
45
|
const origin = computed(() => {
|
|
45
46
|
return props.origin === 'auto' || props.origin === 'overlap' || props.origin.split(' ').length > 1 || props.location.split(' ').length > 1 ? props.origin : props.origin + ' center';
|
|
46
47
|
});
|
|
47
|
-
const transition =
|
|
48
|
-
if (props.transition) return props.transition;
|
|
48
|
+
const transition = toRef(() => {
|
|
49
|
+
if (props.transition != null) return props.transition;
|
|
49
50
|
return isActive.value ? 'scale-transition' : 'fade-transition';
|
|
50
51
|
});
|
|
51
52
|
const activatorProps = computed(() => mergeProps({
|
|
@@ -55,7 +56,9 @@ const VTooltip = genericComponent()({
|
|
|
55
56
|
const overlayProps = VOverlay.filterProps(props);
|
|
56
57
|
return createVNode(VOverlay, mergeProps({
|
|
57
58
|
"ref": overlay,
|
|
58
|
-
"class": ['v-tooltip',
|
|
59
|
+
"class": ['v-tooltip', {
|
|
60
|
+
'v-tooltip--interactive': props.interactive
|
|
61
|
+
}, props.class],
|
|
59
62
|
"style": props.style,
|
|
60
63
|
"id": id.value
|
|
61
64
|
}, overlayProps, {
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { ref, onMounted, nextTick, createElementBlock, openBlock, Fragment, renderList, unref, createElementVNode, toDisplayString, normalizeStyle, createBlock, resolveDynamicComponent, mergeProps } from 'vue';
|
|
2
|
-
import {
|
|
2
|
+
import { av as useDefineWidgets, G as useLayout } from './asWebComponent-By_7_JjS.js';
|
|
3
3
|
import 'animated-details';
|
|
4
4
|
|
|
5
5
|
const _sfc_main = {
|