@oneb/ui-vue 0.3.19 → 0.3.21
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/OneHelpMenu-7f53fa30.cjs +1 -0
- package/dist/{OneHelpMenu-d7a39a69.js → OneHelpMenu-a9131cb1.js} +241 -220
- package/dist/dataTable/dataTable.d.ts +5 -1
- package/dist/dataTable/index.cjs +1 -1
- package/dist/dataTable/index.js +454 -441
- package/dist/dataTable/util.d.ts +2 -2
- package/dist/dropdown/dropdown.d.ts +8 -0
- package/dist/dropdown/index.cjs +1 -1
- package/dist/dropdown/index.js +2 -2
- package/dist/icons/unsorted/SidebarLeftCollapseIcon.d.ts +3 -0
- package/dist/icons/unsorted/SidebarLeftCollapseIcon.js +23 -0
- package/dist/icons/unsorted/esm/SidebarLeftCollapseIcon.d.ts +3 -0
- package/dist/icons/unsorted/esm/SidebarLeftCollapseIcon.js +23 -0
- package/dist/icons/unsorted/esm/index.d.ts +2 -1
- package/dist/icons/unsorted/esm/index.js +2 -1
- package/dist/icons/unsorted/index.d.ts +2 -1
- package/dist/icons/unsorted/index.js +2 -1
- package/dist/index.cjs +1 -1
- package/dist/index.js +64 -63
- package/dist/layout/OneIsland.vue.d.ts +2 -0
- package/dist/layout/index.cjs +1 -1
- package/dist/layout/index.d.ts +1 -0
- package/dist/layout/index.js +1010 -526
- package/dist/layout/layout.d.ts +13 -0
- package/dist/style.css +1 -1
- package/dist/tooltip/index.cjs +47 -1
- package/dist/tooltip/index.js +97 -13
- package/package.json +1 -1
- package/dist/OneHelpMenu-66a2d4c2.cjs +0 -1
|
@@ -1,7 +1,7 @@
|
|
|
1
|
-
import { defineComponent as
|
|
1
|
+
import { defineComponent as E, ref as S, provide as Y, watch as Z, nextTick as ee, onBeforeUnmount as te, computed as F, openBlock as t, createElementBlock as o, createElementVNode as e, renderSlot as H, normalizeProps as I, guardReactiveProps as R, createBlock as M, Teleport as oe, createCommentVNode as p, createVNode as _, Transition as W, withCtx as P, normalizeClass as j, toDisplayString as d, Fragment as $, inject as ne, withModifiers as se, resolveDynamicComponent as V, renderList as L, mergeProps as le, unref as A } from "vue";
|
|
2
2
|
import { a as re, c as ie, o as ae, s as ce } from "./floating-ui.dom-4509432e.js";
|
|
3
3
|
import { flip as ue } from "@floating-ui/vue";
|
|
4
|
-
import { _ as
|
|
4
|
+
import { _ as O } from "./OneAvatar.vue_vue_type_script_setup_true_lang-08ab80dd.js";
|
|
5
5
|
import { r as G } from "./XMarkIcon-51ef0691.js";
|
|
6
6
|
import { r as J } from "./ChevronDownIcon-6805ce6c.js";
|
|
7
7
|
import { r as Q, a as de } from "./ChevronRightIcon-4549a26b.js";
|
|
@@ -18,6 +18,14 @@ const he = {
|
|
|
18
18
|
appendBody: {
|
|
19
19
|
type: Boolean,
|
|
20
20
|
default: !1
|
|
21
|
+
},
|
|
22
|
+
trigger: {
|
|
23
|
+
type: String,
|
|
24
|
+
default: "click"
|
|
25
|
+
},
|
|
26
|
+
offset: {
|
|
27
|
+
type: Number,
|
|
28
|
+
default: 5
|
|
21
29
|
}
|
|
22
30
|
}, fe = {
|
|
23
31
|
variant: {
|
|
@@ -94,80 +102,91 @@ const he = {
|
|
|
94
102
|
type: String,
|
|
95
103
|
default: "default"
|
|
96
104
|
}
|
|
97
|
-
},
|
|
105
|
+
}, ve = ["data-opened"], me = {
|
|
98
106
|
key: 0,
|
|
99
107
|
class: "text-sm text-secondary-content px-3 py-2 text-left"
|
|
100
108
|
}, ye = {
|
|
101
109
|
key: 0,
|
|
102
110
|
class: "text-sm text-secondary-content px-3 py-2 text-left"
|
|
103
|
-
},
|
|
111
|
+
}, ge = /* @__PURE__ */ E({
|
|
104
112
|
__name: "OneDropdown",
|
|
105
113
|
props: he,
|
|
106
114
|
emits: ["open", "close"],
|
|
107
|
-
setup(w, { emit:
|
|
108
|
-
const
|
|
109
|
-
|
|
115
|
+
setup(w, { emit: m }) {
|
|
116
|
+
const u = S(!1), y = S(null), c = S(null), l = S(null), h = m, s = w, f = () => {
|
|
117
|
+
u.value = !u.value, u.value ? h("open") : h("close");
|
|
118
|
+
};
|
|
119
|
+
let a = null;
|
|
120
|
+
const g = () => {
|
|
121
|
+
s.trigger === "hover" && (a && (clearTimeout(a), a = null), u.value || (u.value = !0, h("open")));
|
|
122
|
+
}, k = () => {
|
|
123
|
+
s.trigger === "hover" && (a = setTimeout(() => {
|
|
124
|
+
u.value && (u.value = !1, h("close"));
|
|
125
|
+
}, 100));
|
|
110
126
|
};
|
|
111
127
|
Y("OneDropdown", {
|
|
112
|
-
onToggle:
|
|
128
|
+
onToggle: f
|
|
113
129
|
});
|
|
114
|
-
let
|
|
115
|
-
function
|
|
130
|
+
let x = null;
|
|
131
|
+
function r() {
|
|
116
132
|
!c.value || !l.value || ie(c.value, l.value, {
|
|
117
133
|
placement: s.stick ? s.stick : "bottom-start",
|
|
118
134
|
strategy: "fixed",
|
|
119
|
-
middleware: [ae(
|
|
120
|
-
}).then(({ x: n, y }) => {
|
|
135
|
+
middleware: [ae(s.offset), ue(), ce({ padding: 8 })]
|
|
136
|
+
}).then(({ x: n, y: C }) => {
|
|
121
137
|
l.value && Object.assign(l.value.style, {
|
|
122
138
|
left: `${n}px`,
|
|
123
|
-
top: `${
|
|
139
|
+
top: `${C}px`,
|
|
140
|
+
visibility: "visible"
|
|
124
141
|
});
|
|
125
142
|
});
|
|
126
143
|
}
|
|
127
|
-
Z(
|
|
128
|
-
s.appendBody && (n ? (await ee(), c.value && l.value && (
|
|
144
|
+
Z(u, async (n) => {
|
|
145
|
+
s.appendBody && (n ? (await ee(), c.value && l.value && (l.value.style.visibility = "hidden", r(), x = re(c.value, l.value, r))) : x && (x(), x = null));
|
|
129
146
|
}), te(() => {
|
|
130
|
-
|
|
147
|
+
x && x();
|
|
131
148
|
});
|
|
132
|
-
const
|
|
133
|
-
var
|
|
149
|
+
const v = F(() => {
|
|
150
|
+
var z;
|
|
134
151
|
if (s.appendBody)
|
|
135
152
|
return "";
|
|
136
|
-
const n = (
|
|
137
|
-
return n && n.top + 270 > window.innerHeight ? "up" + (
|
|
138
|
-
}), b =
|
|
153
|
+
const n = (z = y.value) == null ? void 0 : z.getBoundingClientRect(), C = n ? n.x < 270 : !1;
|
|
154
|
+
return n && n.top + 270 > window.innerHeight ? "up" + (C ? "-right" : "-left") : "down" + (C ? "-right" : "-left");
|
|
155
|
+
}), b = F(() => {
|
|
139
156
|
const n = [
|
|
140
157
|
"absolute z-10 w-fit rounded-md bg-white",
|
|
141
158
|
"py-1 shadow-lg ring-1 ring-black ring-opacity-5 focus:outline-none",
|
|
142
159
|
"overflow-auto max-h-[540px] min-w-[150px] max-w-[540px]"
|
|
143
160
|
];
|
|
144
|
-
return
|
|
145
|
-
}),
|
|
161
|
+
return v.value.startsWith("up") ? n.push("bottom-1 mb-10") : v.value.startsWith("down") && n.push("top-1 mt-10"), s.stick === "right" ? n.push("right-0") : s.stick === "left" && n.push("left-0"), n;
|
|
162
|
+
}), B = F(() => [
|
|
146
163
|
"fixed z-[10000] w-fit rounded-md bg-white",
|
|
147
164
|
"py-1 shadow-lg ring-1 ring-black ring-opacity-5 focus:outline-none",
|
|
148
165
|
"overflow-auto max-h-[540px] min-w-[150px] max-w-[540px]"
|
|
149
166
|
]);
|
|
150
|
-
return (n,
|
|
167
|
+
return (n, C) => (t(), o("div", {
|
|
151
168
|
class: "relative inline-block",
|
|
152
169
|
ref_key: "containerRef",
|
|
153
|
-
ref:
|
|
154
|
-
"data-opened":
|
|
170
|
+
ref: y,
|
|
171
|
+
"data-opened": u.value,
|
|
172
|
+
onMouseenter: g,
|
|
173
|
+
onMouseleave: k
|
|
155
174
|
}, [
|
|
156
175
|
e("div", {
|
|
157
176
|
ref_key: "buttonRef",
|
|
158
177
|
ref: c
|
|
159
178
|
}, [
|
|
160
|
-
|
|
179
|
+
H(n.$slots, "button", I(R({ onToggle: f, isExpanded: u.value })))
|
|
161
180
|
], 512),
|
|
162
|
-
s.appendBody ? (t(),
|
|
181
|
+
s.appendBody ? (t(), M(oe, {
|
|
163
182
|
key: 0,
|
|
164
183
|
to: "body"
|
|
165
184
|
}, [
|
|
166
|
-
|
|
185
|
+
u.value && n.trigger === "click" ? (t(), o("div", {
|
|
167
186
|
key: 0,
|
|
168
187
|
class: "fixed top-0 left-0 w-screen h-screen z-[9999]",
|
|
169
|
-
onClick:
|
|
170
|
-
})) :
|
|
188
|
+
onClick: f
|
|
189
|
+
})) : p("", !0),
|
|
171
190
|
_(W, {
|
|
172
191
|
"enter-active-class": "transition ease-out duration-100",
|
|
173
192
|
"enter-from-class": "transform opacity-0 scale-95",
|
|
@@ -176,28 +195,30 @@ const he = {
|
|
|
176
195
|
"leave-from-class": "transform opacity-100 scale-100",
|
|
177
196
|
"leave-to-class": "transform opacity-0 scale-95"
|
|
178
197
|
}, {
|
|
179
|
-
default:
|
|
180
|
-
|
|
198
|
+
default: P(() => [
|
|
199
|
+
u.value ? (t(), o("div", {
|
|
181
200
|
key: 0,
|
|
182
201
|
ref_key: "menuRef",
|
|
183
202
|
ref: l,
|
|
184
|
-
class: j(["menu",
|
|
203
|
+
class: j(["menu", B.value]),
|
|
185
204
|
role: "menu",
|
|
186
205
|
"aria-orientation": "vertical",
|
|
187
|
-
tabindex: "-1"
|
|
206
|
+
tabindex: "-1",
|
|
207
|
+
onMouseenter: g,
|
|
208
|
+
onMouseleave: k
|
|
188
209
|
}, [
|
|
189
|
-
n.title ? (t(), o("div",
|
|
190
|
-
|
|
191
|
-
],
|
|
210
|
+
n.title ? (t(), o("div", me, d(n.title), 1)) : p("", !0),
|
|
211
|
+
H(n.$slots, "menu", I(R({ onToggle: f })))
|
|
212
|
+
], 34)) : p("", !0)
|
|
192
213
|
]),
|
|
193
214
|
_: 3
|
|
194
215
|
})
|
|
195
|
-
])) : (t(), o(
|
|
196
|
-
|
|
216
|
+
])) : (t(), o($, { key: 1 }, [
|
|
217
|
+
u.value && n.trigger === "click" ? (t(), o("div", {
|
|
197
218
|
key: 0,
|
|
198
219
|
class: "fixed top-0 left-0 w-screen h-screen z-10",
|
|
199
|
-
onClick:
|
|
200
|
-
})) :
|
|
220
|
+
onClick: f
|
|
221
|
+
})) : p("", !0),
|
|
201
222
|
_(W, {
|
|
202
223
|
"enter-active-class": "transition ease-out duration-100",
|
|
203
224
|
"enter-from-class": "transform opacity-0 scale-95",
|
|
@@ -206,47 +227,47 @@ const he = {
|
|
|
206
227
|
"leave-from-class": "transform opacity-100 scale-100",
|
|
207
228
|
"leave-to-class": "transform opacity-0 scale-95"
|
|
208
229
|
}, {
|
|
209
|
-
default:
|
|
210
|
-
|
|
230
|
+
default: P(() => [
|
|
231
|
+
u.value ? (t(), o("div", {
|
|
211
232
|
key: 0,
|
|
212
233
|
class: j(["menu", b.value]),
|
|
213
234
|
role: "menu",
|
|
214
235
|
"aria-orientation": "vertical",
|
|
215
236
|
tabindex: "-1"
|
|
216
237
|
}, [
|
|
217
|
-
n.title ? (t(), o("div", ye,
|
|
218
|
-
|
|
219
|
-
], 2)) :
|
|
238
|
+
n.title ? (t(), o("div", ye, d(n.title), 1)) : p("", !0),
|
|
239
|
+
H(n.$slots, "menu", I(R({ onToggle: f })))
|
|
240
|
+
], 2)) : p("", !0)
|
|
220
241
|
]),
|
|
221
242
|
_: 3
|
|
222
243
|
})
|
|
223
244
|
], 64))
|
|
224
|
-
],
|
|
245
|
+
], 40, ve));
|
|
225
246
|
}
|
|
226
|
-
}), K = /* @__PURE__ */
|
|
247
|
+
}), K = /* @__PURE__ */ E({
|
|
227
248
|
__name: "OneDropdownItem",
|
|
228
249
|
props: fe,
|
|
229
250
|
emits: ["click"],
|
|
230
|
-
setup(w, { emit:
|
|
231
|
-
const
|
|
232
|
-
c !== void 0 && c.onToggle(),
|
|
233
|
-
},
|
|
251
|
+
setup(w, { emit: m }) {
|
|
252
|
+
const u = m, y = w, c = ne("OneDropdown"), l = () => {
|
|
253
|
+
c !== void 0 && c.onToggle(), u("click");
|
|
254
|
+
}, h = F(() => {
|
|
234
255
|
const s = [];
|
|
235
|
-
return
|
|
256
|
+
return y.variant === "secondary" ? s.push("text-secondary-content hover:bg-secondary-body-hover") : y.variant === "danger" ? s.push("text-danger-content hover:bg-danger-10") : y.variant === "warning" ? s.push("text-warning-content hover:bg-warning-10") : y.variant === "info" ? s.push("text-info-content hover:bg-info-10") : s.push("hover:bg-secondary-body-hover"), s;
|
|
236
257
|
});
|
|
237
|
-
return (s,
|
|
238
|
-
class: j(["px-3 py-1.5 flex items-center space-x-3 w-full whitespace-nowrap",
|
|
258
|
+
return (s, f) => (t(), o("button", {
|
|
259
|
+
class: j(["px-3 py-1.5 flex items-center space-x-3 w-full whitespace-nowrap", h.value]),
|
|
239
260
|
onClick: se(l, ["prevent"])
|
|
240
261
|
}, [
|
|
241
|
-
s.icon ? (t(),
|
|
262
|
+
s.icon ? (t(), M(V(s.icon), {
|
|
242
263
|
key: 0,
|
|
243
264
|
class: "w-4 h-4"
|
|
244
|
-
})) :
|
|
245
|
-
e("span", null,
|
|
265
|
+
})) : p("", !0),
|
|
266
|
+
e("span", null, d(s.label), 1)
|
|
246
267
|
], 2));
|
|
247
268
|
}
|
|
248
269
|
});
|
|
249
|
-
function
|
|
270
|
+
function xe(w, m) {
|
|
250
271
|
return t(), o("svg", {
|
|
251
272
|
xmlns: "http://www.w3.org/2000/svg",
|
|
252
273
|
fill: "none",
|
|
@@ -331,37 +352,37 @@ const _e = {
|
|
|
331
352
|
type: Object,
|
|
332
353
|
required: !0
|
|
333
354
|
}
|
|
334
|
-
}, be = ["onClick"], Ce = { class: "flex flex-col items-center pt-5 pb-2 h-full" }, $e = { class: "flex flex-col px-10 py-1 mt-2 text-center" }, Ae = { class: "self-center text-base font-medium tracking-wide text-black" }, Se = { class: "mt-1 text-xs leading-5 text-blue-500 font-light" }, Fe = { class: "text-left w-full mt-5 px-3" },
|
|
355
|
+
}, be = ["onClick"], Ce = { class: "flex flex-col items-center pt-5 pb-2 h-full" }, $e = { class: "flex flex-col px-10 py-1 mt-2 text-center" }, Ae = { class: "self-center text-base font-medium tracking-wide text-black" }, Se = { class: "mt-1 text-xs leading-5 text-blue-500 font-light" }, Fe = { class: "text-left w-full mt-5 px-3" }, Le = { class: "-mb-2 flex-shrink-0 mt-auto pt-6 text-[8px] leading-3 text-gray-400" }, Nt = /* @__PURE__ */ E({
|
|
335
356
|
__name: "OneUserMenu",
|
|
336
357
|
props: _e,
|
|
337
358
|
setup(w) {
|
|
338
|
-
const
|
|
359
|
+
const m = w, u = F(() => {
|
|
339
360
|
var l;
|
|
340
|
-
return (l =
|
|
341
|
-
let s = { label:
|
|
342
|
-
|
|
343
|
-
const
|
|
361
|
+
return (l = m.menu) == null ? void 0 : l.map((h) => {
|
|
362
|
+
let s = { label: h.label };
|
|
363
|
+
h.icon != null && (s = { ...s, icon: h.icon });
|
|
364
|
+
const f = typeof h.click == "function" ? h.click : () => {
|
|
344
365
|
};
|
|
345
366
|
return {
|
|
346
|
-
key:
|
|
367
|
+
key: h.label,
|
|
347
368
|
args: s,
|
|
348
|
-
click:
|
|
369
|
+
click: f
|
|
349
370
|
};
|
|
350
371
|
});
|
|
351
|
-
}),
|
|
352
|
-
typeof
|
|
372
|
+
}), y = () => {
|
|
373
|
+
typeof m.onAccount == "function" && m.onAccount();
|
|
353
374
|
}, c = () => {
|
|
354
|
-
typeof
|
|
375
|
+
typeof m.onLogout == "function" && m.onLogout();
|
|
355
376
|
};
|
|
356
|
-
return (l,
|
|
357
|
-
button:
|
|
377
|
+
return (l, h) => (t(), M(ge, { stick: "right" }, {
|
|
378
|
+
button: P(({ onToggle: s, isExpanded: f }) => {
|
|
358
379
|
var a, g;
|
|
359
380
|
return [
|
|
360
381
|
e("button", {
|
|
361
382
|
onClick: s,
|
|
362
|
-
class: j(["p-1 rounded-full hover:bg-secondary-10", [
|
|
383
|
+
class: j(["p-1 rounded-full hover:bg-secondary-10", [f ? "bg-secondary-25" : ""]])
|
|
363
384
|
}, [
|
|
364
|
-
_(
|
|
385
|
+
_(O, {
|
|
365
386
|
text: ((a = l.user) == null ? void 0 : a.name) || "",
|
|
366
387
|
size: l.iconSize,
|
|
367
388
|
src: (g = l.user) == null ? void 0 : g.photo_url,
|
|
@@ -370,45 +391,45 @@ const _e = {
|
|
|
370
391
|
], 10, be)
|
|
371
392
|
];
|
|
372
393
|
}),
|
|
373
|
-
menu:
|
|
374
|
-
var s,
|
|
394
|
+
menu: P(() => {
|
|
395
|
+
var s, f, a, g, k;
|
|
375
396
|
return [
|
|
376
397
|
e("div", Ce, [
|
|
377
|
-
_(
|
|
398
|
+
_(O, {
|
|
378
399
|
text: ((s = l.user) == null ? void 0 : s.name) || "",
|
|
379
400
|
size: 80,
|
|
380
|
-
src: (
|
|
401
|
+
src: (f = l.user) == null ? void 0 : f.photo_url,
|
|
381
402
|
rounded: !0,
|
|
382
403
|
class: "mx-auto"
|
|
383
404
|
}, null, 8, ["text", "src"]),
|
|
384
405
|
e("div", $e, [
|
|
385
|
-
e("div", Ae,
|
|
386
|
-
e("div", Se,
|
|
406
|
+
e("div", Ae, d((a = l.user) == null ? void 0 : a.name), 1),
|
|
407
|
+
e("div", Se, d((g = l.user) == null ? void 0 : g.email), 1)
|
|
387
408
|
]),
|
|
388
|
-
typeof
|
|
409
|
+
typeof m.onAccount == "function" ? (t(), o("a", {
|
|
389
410
|
key: 0,
|
|
390
|
-
onClick:
|
|
411
|
+
onClick: y,
|
|
391
412
|
class: "cursor-pointer justify-center px-8 py-2 mt-3 text-xs font-semibold tracking-wide leading-5 text-gray-600 border border-solid bg-neutral-100 border-slate-200 rounded-[50px] hover:bg-neutral-200"
|
|
392
|
-
},
|
|
413
|
+
}, d(l.accountLabel), 1)) : p("", !0),
|
|
393
414
|
e("div", Fe, [
|
|
394
|
-
(t(!0), o(
|
|
395
|
-
key:
|
|
396
|
-
}, { ref_for: !0 },
|
|
397
|
-
onClick:
|
|
415
|
+
(t(!0), o($, null, L(u.value, (x) => (t(), M(K, le({
|
|
416
|
+
key: x.key
|
|
417
|
+
}, { ref_for: !0 }, x.args, {
|
|
418
|
+
onClick: x.click
|
|
398
419
|
}), null, 16, ["onClick"]))), 128)),
|
|
399
|
-
typeof l.onLogout == "function" ? (t(),
|
|
420
|
+
typeof l.onLogout == "function" ? (t(), M(K, {
|
|
400
421
|
key: 0,
|
|
401
|
-
icon:
|
|
422
|
+
icon: A(xe),
|
|
402
423
|
label: l.logoutLabel,
|
|
403
424
|
class: "rounded py-3",
|
|
404
425
|
onClick: c
|
|
405
|
-
}, null, 8, ["icon", "label"])) :
|
|
426
|
+
}, null, 8, ["icon", "label"])) : p("", !0)
|
|
406
427
|
]),
|
|
407
|
-
|
|
428
|
+
h[0] || (h[0] = e("div", {
|
|
408
429
|
class: "space-y-2 text-center",
|
|
409
430
|
style: { width: "240px" }
|
|
410
431
|
}, null, -1)),
|
|
411
|
-
e("div",
|
|
432
|
+
e("div", Le, d((k = l.app) == null ? void 0 : k.version), 1)
|
|
412
433
|
])
|
|
413
434
|
];
|
|
414
435
|
}),
|
|
@@ -416,7 +437,7 @@ const _e = {
|
|
|
416
437
|
}));
|
|
417
438
|
}
|
|
418
439
|
});
|
|
419
|
-
function
|
|
440
|
+
function Be(w, m) {
|
|
420
441
|
return t(), o("svg", {
|
|
421
442
|
xmlns: "http://www.w3.org/2000/svg",
|
|
422
443
|
fill: "none",
|
|
@@ -508,50 +529,50 @@ function Le(w, f) {
|
|
|
508
529
|
})
|
|
509
530
|
]);
|
|
510
531
|
}
|
|
511
|
-
const
|
|
532
|
+
const Me = ["data-opened"], je = {
|
|
512
533
|
key: 1,
|
|
513
534
|
class: "absolute top-0 right-0 h-screen overflow-y-auto max-w-96 bg-white px-3 z-10"
|
|
514
|
-
},
|
|
535
|
+
}, ze = { class: "flex justify-between items-center pt-3 mb-3" }, Oe = { class: "font-semibold text-xl px-3" }, Ee = { class: "grid" }, Pe = { class: "rounded-lg m-3 border" }, Te = {
|
|
515
536
|
class: "space-x-2 flex items-center px-3 py-2",
|
|
516
537
|
style: { width: "300px" }
|
|
517
|
-
},
|
|
538
|
+
}, He = { class: "flex justify-between relative" }, Ie = { class: "flex items-center justify-between w-full text-left text-sm font-semibold" }, Re = { key: 0 }, Ve = { class: "text-xs font-semibold" }, De = { class: "px-3 py-2" }, Ne = { class: "text-secondary-content text-left pb-1 text-xs uppercase" }, qe = { class: "overflow-auto max-h-full" }, Ue = {
|
|
518
539
|
key: 0,
|
|
519
540
|
class: "space-y-2"
|
|
520
541
|
}, We = ["onClick"], Ke = { class: "flex" }, Ge = { class: "border border-secondary-stroke rounded-2xl w-14 h-14 md:w-14 md:h-14 flex items-center justify-center" }, Je = { class: "pl-2" }, Qe = { class: "text-sm mt-1 font-semibold" }, Xe = { class: "text9 mt-1" }, Ye = {
|
|
521
542
|
key: 1,
|
|
522
543
|
class: "mt-2 w-full bg-[#FAFAFA] hover:bg-secondary-10 p-2 rounded-lg mb-5 text-xs hidden"
|
|
523
|
-
}, Ze = /* @__PURE__ */
|
|
544
|
+
}, Ze = /* @__PURE__ */ E({
|
|
524
545
|
__name: "OneBrowserMenu",
|
|
525
546
|
props: we,
|
|
526
547
|
emits: ["open", "close"],
|
|
527
|
-
setup(w, { emit:
|
|
528
|
-
const
|
|
529
|
-
c.value = !c.value, c.value ?
|
|
530
|
-
},
|
|
531
|
-
|
|
548
|
+
setup(w, { emit: m }) {
|
|
549
|
+
const u = m, y = w, c = S(!1), l = () => {
|
|
550
|
+
c.value = !c.value, c.value ? u("open") : u("close");
|
|
551
|
+
}, h = S(!1);
|
|
552
|
+
F(() => h.value ? Q : J);
|
|
532
553
|
const s = () => {
|
|
533
|
-
typeof
|
|
534
|
-
},
|
|
535
|
-
typeof
|
|
554
|
+
typeof y.onChange == "function" && y.onChange();
|
|
555
|
+
}, f = (a) => {
|
|
556
|
+
typeof y.onApp == "function" && y.onApp(a);
|
|
536
557
|
};
|
|
537
558
|
return (a, g) => {
|
|
538
|
-
var k,
|
|
559
|
+
var k, x, r, v, b, B;
|
|
539
560
|
return t(), o("div", { "data-opened": c.value }, [
|
|
540
561
|
e("button", {
|
|
541
562
|
onClick: l,
|
|
542
563
|
class: j(["sm:p-1 sm:w-[44px] sm:h-[44px] w-8 h-8 rounded-md hover:bg-secondary-10 flex", { "bg-secondary-10": c.value }])
|
|
543
564
|
}, [
|
|
544
|
-
_(
|
|
565
|
+
_(A(Be), { class: "text-secondary-base w-full p-1 hover:text-blue-600 m-auto" })
|
|
545
566
|
], 2),
|
|
546
567
|
c.value ? (t(), o("div", {
|
|
547
568
|
key: 0,
|
|
548
569
|
class: "fixed top-0 left-0 w-screen h-screen z-10 bg-black/10",
|
|
549
570
|
onClick: l
|
|
550
|
-
})) :
|
|
551
|
-
c.value ? (t(), o("div",
|
|
552
|
-
e("div",
|
|
553
|
-
e("div", Oe,
|
|
554
|
-
_(
|
|
571
|
+
})) : p("", !0),
|
|
572
|
+
c.value ? (t(), o("div", je, [
|
|
573
|
+
e("div", ze, [
|
|
574
|
+
e("div", Oe, d((k = a.workspace) == null ? void 0 : k.title), 1),
|
|
575
|
+
_(A(G), {
|
|
555
576
|
class: "w-6 cursor-pointer",
|
|
556
577
|
onClick: l
|
|
557
578
|
})
|
|
@@ -559,81 +580,81 @@ const je = ["data-opened"], ze = {
|
|
|
559
580
|
e("div", Ee, [
|
|
560
581
|
e("div", Pe, [
|
|
561
582
|
e("div", Te, [
|
|
562
|
-
e("div",
|
|
563
|
-
_(
|
|
564
|
-
text: ((
|
|
565
|
-
src: (
|
|
583
|
+
e("div", He, [
|
|
584
|
+
_(O, {
|
|
585
|
+
text: ((x = a.workspace) == null ? void 0 : x.name) || "",
|
|
586
|
+
src: (r = a.workspace) == null ? void 0 : r.photo_url,
|
|
566
587
|
size: 44,
|
|
567
588
|
rounded: !1,
|
|
568
589
|
class: "mx-auto"
|
|
569
590
|
}, null, 8, ["text", "src"])
|
|
570
591
|
]),
|
|
571
|
-
e("div",
|
|
592
|
+
e("div", Ie, d((v = a.workspace) == null ? void 0 : v.name), 1)
|
|
572
593
|
]),
|
|
573
|
-
|
|
574
|
-
(t(!0), o(
|
|
575
|
-
key:
|
|
594
|
+
h.value ? (t(), o("div", Re, [
|
|
595
|
+
(t(!0), o($, null, L(a.workspaces, (n) => (t(), o("div", {
|
|
596
|
+
key: n.name,
|
|
576
597
|
class: "flex items-center space-x-3 border-t px-5 py-2 hover:bg-secondary-10"
|
|
577
598
|
}, [
|
|
578
|
-
_(
|
|
579
|
-
text:
|
|
580
|
-
src:
|
|
599
|
+
_(O, {
|
|
600
|
+
text: n.name,
|
|
601
|
+
src: n.photo_url,
|
|
581
602
|
size: 30,
|
|
582
603
|
rounded: !1
|
|
583
604
|
}, null, 8, ["text", "src"]),
|
|
584
|
-
e("span",
|
|
605
|
+
e("span", Ve, d(n.name), 1)
|
|
585
606
|
]))), 128))
|
|
586
|
-
])) :
|
|
607
|
+
])) : p("", !0),
|
|
587
608
|
g[0] || (g[0] = e("hr", null, null, -1)),
|
|
588
609
|
e("div", {
|
|
589
610
|
onClick: s,
|
|
590
611
|
class: "text-center py-2 cursor-pointer",
|
|
591
612
|
style: { "font-size": "10px" }
|
|
592
|
-
},
|
|
613
|
+
}, d((b = a.workspace) == null ? void 0 : b.changeLabel), 1)
|
|
593
614
|
])
|
|
594
615
|
]),
|
|
595
616
|
e("div", De, [
|
|
596
|
-
e("div",
|
|
597
|
-
e("div",
|
|
617
|
+
e("div", Ne, d((B = a.workspace) == null ? void 0 : B.appsLabel), 1),
|
|
618
|
+
e("div", qe, [
|
|
598
619
|
a.apps && a.apps.length ? (t(), o("div", Ue, [
|
|
599
|
-
(t(!0), o(
|
|
600
|
-
key:
|
|
601
|
-
onClick: (
|
|
620
|
+
(t(!0), o($, null, L(a.apps, (n) => (t(), o("div", {
|
|
621
|
+
key: n.id,
|
|
622
|
+
onClick: (C) => f(n),
|
|
602
623
|
class: "flex justify-between items-center rounded-lg hover:bg-secondary-10 p-2 bg-[#FAFAFA] cursor-pointer"
|
|
603
624
|
}, [
|
|
604
625
|
e("div", Ke, [
|
|
605
626
|
e("div", Ge, [
|
|
606
|
-
_(
|
|
607
|
-
text:
|
|
608
|
-
src:
|
|
627
|
+
_(O, {
|
|
628
|
+
text: n.name,
|
|
629
|
+
src: n.photo_url,
|
|
609
630
|
size: 44,
|
|
610
631
|
rounded: !1
|
|
611
632
|
}, null, 8, ["text", "src"])
|
|
612
633
|
]),
|
|
613
634
|
e("div", Je, [
|
|
614
|
-
e("p", Qe,
|
|
615
|
-
e("p", Xe,
|
|
635
|
+
e("p", Qe, d(n.name), 1),
|
|
636
|
+
e("p", Xe, d(n == null ? void 0 : n.short), 1)
|
|
616
637
|
])
|
|
617
638
|
]),
|
|
618
639
|
e("div", null, [
|
|
619
640
|
_(pe, {
|
|
620
641
|
variant: "touch",
|
|
621
|
-
icon:
|
|
622
|
-
onClick: (
|
|
642
|
+
icon: A(de),
|
|
643
|
+
onClick: (C) => f(n)
|
|
623
644
|
}, null, 8, ["icon", "onClick"])
|
|
624
645
|
])
|
|
625
646
|
], 8, We))), 128))
|
|
626
|
-
])) :
|
|
627
|
-
a.apps && a.apps.length ? (t(), o("button", Ye,
|
|
647
|
+
])) : p("", !0),
|
|
648
|
+
a.apps && a.apps.length ? (t(), o("button", Ye, d("Дивитися всі"))) : p("", !0)
|
|
628
649
|
])
|
|
629
650
|
])
|
|
630
|
-
])) :
|
|
631
|
-
], 8,
|
|
651
|
+
])) : p("", !0)
|
|
652
|
+
], 8, Me);
|
|
632
653
|
};
|
|
633
654
|
}
|
|
634
655
|
});
|
|
635
|
-
const
|
|
636
|
-
function et(w,
|
|
656
|
+
const qt = /* @__PURE__ */ X(Ze, [["__scopeId", "data-v-9e75279e"]]);
|
|
657
|
+
function et(w, m) {
|
|
637
658
|
return t(), o("svg", {
|
|
638
659
|
xmlns: "http://www.w3.org/2000/svg",
|
|
639
660
|
fill: "none",
|
|
@@ -649,7 +670,7 @@ function et(w, f) {
|
|
|
649
670
|
})
|
|
650
671
|
]);
|
|
651
672
|
}
|
|
652
|
-
function tt(w,
|
|
673
|
+
function tt(w, m) {
|
|
653
674
|
return t(), o("svg", {
|
|
654
675
|
xmlns: "http://www.w3.org/2000/svg",
|
|
655
676
|
fill: "none",
|
|
@@ -670,7 +691,7 @@ function tt(w, f) {
|
|
|
670
691
|
})
|
|
671
692
|
]);
|
|
672
693
|
}
|
|
673
|
-
function ot(w,
|
|
694
|
+
function ot(w, m) {
|
|
674
695
|
return t(), o("svg", {
|
|
675
696
|
xmlns: "http://www.w3.org/2000/svg",
|
|
676
697
|
fill: "none",
|
|
@@ -695,162 +716,162 @@ const nt = ["data-opened"], st = {
|
|
|
695
716
|
}, at = ["onClick"], ct = { class: "uppercase text-[8px]" }, ut = { class: "overflow-y-auto grid rounded-xl" }, dt = { class: "max-h-full bg-[#FAFAFA]" }, pt = {
|
|
696
717
|
key: 0,
|
|
697
718
|
class: "space-y-2"
|
|
698
|
-
}, ht = ["onClick"], ft = { class: "flex" },
|
|
719
|
+
}, ht = ["onClick"], ft = { class: "flex" }, vt = { class: "pl-2" }, mt = { class: "text-sm mt-1 font-semibold" }, yt = { class: "text-[10px] mt-1 text-[#979CA9]" }, gt = { class: "mt-auto" }, xt = { key: 0 }, _t = ["onClick"], wt = { class: "flex items-center space-x-3" }, kt = { class: "h-16" }, bt = {
|
|
699
720
|
key: 0,
|
|
700
721
|
class: "bg-[#FAFAFA] rounded-lg p-3"
|
|
701
722
|
}, Ct = { class: "flex justify-between" }, $t = ["onClick"], At = {
|
|
702
723
|
key: 0,
|
|
703
724
|
class: "tooltip-text min-w-[70px]"
|
|
704
|
-
}, St = { class: "flex justify-between mb-4" }, Ft = ["href"],
|
|
725
|
+
}, St = { class: "flex justify-between mb-4" }, Ft = ["href"], Lt = { class: "flex flex-nowrap items-center w-max h-[24px]" }, Bt = { class: "whitespace-nowrap overflow-hidden text-ellipsis text-left flex-shrink w-full text-[#525B66]" }, Mt = { class: "py-[8px] pl-0 pr-[8px]" }, jt = /* @__PURE__ */ E({
|
|
705
726
|
__name: "OneHelpMenu",
|
|
706
727
|
props: ke,
|
|
707
728
|
emits: ["open", "close"],
|
|
708
|
-
setup(w, { emit:
|
|
709
|
-
const
|
|
710
|
-
c.value = !c.value, c.value ?
|
|
711
|
-
},
|
|
712
|
-
var
|
|
713
|
-
const
|
|
714
|
-
return s.value ===
|
|
729
|
+
setup(w, { emit: m }) {
|
|
730
|
+
const u = m, y = w, c = S(!1), l = () => {
|
|
731
|
+
c.value = !c.value, c.value ? u("open") : u("close");
|
|
732
|
+
}, h = F(() => k.value ? Q : J), s = S(3), f = F(() => {
|
|
733
|
+
var v, b;
|
|
734
|
+
const r = ((b = (v = y.help) == null ? void 0 : v.helpList) == null ? void 0 : b.length) || 0;
|
|
735
|
+
return s.value === r;
|
|
715
736
|
});
|
|
716
|
-
|
|
717
|
-
var
|
|
718
|
-
return (((
|
|
737
|
+
F(() => {
|
|
738
|
+
var v;
|
|
739
|
+
return (((v = y.help) == null ? void 0 : v.helpList) || []).slice(0, s.value);
|
|
719
740
|
});
|
|
720
741
|
const a = () => {
|
|
721
|
-
var
|
|
722
|
-
const
|
|
723
|
-
s.value =
|
|
724
|
-
}, g = (
|
|
725
|
-
|
|
726
|
-
}, k =
|
|
742
|
+
var v, b;
|
|
743
|
+
const r = ((b = (v = y.help) == null ? void 0 : v.helpList) == null ? void 0 : b.length) || 0;
|
|
744
|
+
s.value = f.value ? 3 : r;
|
|
745
|
+
}, g = (r, v) => {
|
|
746
|
+
r && v && typeof v.openLink == "function" ? v.openLink(v) : r && window.open(r, "_blank");
|
|
747
|
+
}, k = S(!1), x = () => {
|
|
727
748
|
k.value = !k.value;
|
|
728
749
|
};
|
|
729
|
-
return (
|
|
730
|
-
var
|
|
750
|
+
return (r, v) => {
|
|
751
|
+
var b, B, n, C, z, D, N, q, U;
|
|
731
752
|
return t(), o("div", { "data-opened": c.value }, [
|
|
732
753
|
e("button", {
|
|
733
754
|
onClick: l,
|
|
734
755
|
class: j(["sm:p-1 sm:w-[44px] sm:h-[44px] w-8 h-8 rounded-md hover:bg-secondary-10 flex", { "bg-secondary-10": c.value }])
|
|
735
756
|
}, [
|
|
736
|
-
_(
|
|
757
|
+
_(A(et), { class: "text-secondary-base w-full p-1 hover:text-blue-600 m-auto" })
|
|
737
758
|
], 2),
|
|
738
759
|
c.value ? (t(), o("div", {
|
|
739
760
|
key: 0,
|
|
740
761
|
class: "fixed top-0 left-0 w-screen h-screen z-10 bg-black/10 flex flex-col",
|
|
741
762
|
onClick: l
|
|
742
|
-
})) :
|
|
763
|
+
})) : p("", !0),
|
|
743
764
|
c.value ? (t(), o("div", st, [
|
|
744
765
|
e("div", lt, [
|
|
745
|
-
e("div", rt,
|
|
746
|
-
_(
|
|
766
|
+
e("div", rt, d((b = r.help) == null ? void 0 : b.label), 1),
|
|
767
|
+
_(A(G), {
|
|
747
768
|
class: "w-6 cursor-pointer",
|
|
748
769
|
onClick: l
|
|
749
770
|
})
|
|
750
771
|
]),
|
|
751
|
-
(
|
|
752
|
-
(t(!0), o(
|
|
753
|
-
key:
|
|
754
|
-
onClick: (
|
|
772
|
+
(B = r.help) != null && B.helpButton ? (t(), o("div", it, [
|
|
773
|
+
(t(!0), o($, null, L((n = r.help) == null ? void 0 : n.helpButton, (i) => (t(), o("button", {
|
|
774
|
+
key: i.name,
|
|
775
|
+
onClick: (T) => g(i.link, i),
|
|
755
776
|
class: "grid justify-center space-y-2 hover:bg-slate-100 p-3 rounded-xl hover:text-blue-500"
|
|
756
777
|
}, [
|
|
757
778
|
e("div", null, [
|
|
758
|
-
(t(),
|
|
779
|
+
(t(), M(V(i == null ? void 0 : i.icon), { class: "w-[16px] h-[16px] mx-auto" }))
|
|
759
780
|
]),
|
|
760
|
-
e("span", ct,
|
|
781
|
+
e("span", ct, d(i.name), 1)
|
|
761
782
|
], 8, at))), 128))
|
|
762
|
-
])) :
|
|
783
|
+
])) : p("", !0),
|
|
763
784
|
e("div", ut, [
|
|
764
785
|
e("div", dt, [
|
|
765
|
-
(
|
|
766
|
-
(t(!0), o(
|
|
767
|
-
key:
|
|
768
|
-
onClick: (
|
|
786
|
+
(C = r.help) != null && C.helpList && r.help.helpList.length ? (t(), o("div", pt, [
|
|
787
|
+
(t(!0), o($, null, L(r.help.helpList, (i) => (t(), o("div", {
|
|
788
|
+
key: i.id,
|
|
789
|
+
onClick: (T) => g(i.link, i),
|
|
769
790
|
class: "flex justify-between items-center rounded-lg hover:bg-slate-100 p-2 cursor-pointer hover:text-[#4089E0]"
|
|
770
791
|
}, [
|
|
771
792
|
e("div", ft, [
|
|
772
|
-
e("div",
|
|
773
|
-
e("p",
|
|
774
|
-
e("p", yt,
|
|
793
|
+
e("div", vt, [
|
|
794
|
+
e("p", mt, d(i.name), 1),
|
|
795
|
+
e("p", yt, d(i.category), 1)
|
|
775
796
|
])
|
|
776
797
|
])
|
|
777
798
|
], 8, ht))), 128))
|
|
778
|
-
])) :
|
|
799
|
+
])) : p("", !0)
|
|
779
800
|
])
|
|
780
801
|
]),
|
|
781
|
-
(
|
|
802
|
+
(z = r.help) != null && z.helpList && r.help.helpList.length < 0 ? (t(), o("button", {
|
|
782
803
|
key: 1,
|
|
783
804
|
onClick: a,
|
|
784
805
|
class: "h-11 w-full bg-[#FAFAFA] hover:bg-slate-100 p-3 text-[#525B66] rounded-b-xl text-xs hover:text-[#4089E0] font-medium"
|
|
785
|
-
},
|
|
786
|
-
e("div",
|
|
787
|
-
(D =
|
|
788
|
-
(t(!0), o(
|
|
789
|
-
key:
|
|
790
|
-
onClick: (
|
|
806
|
+
}, d(f.value ? r.help.buttNoMore : r.help.buttMore), 1)) : p("", !0),
|
|
807
|
+
e("div", gt, [
|
|
808
|
+
(D = r.help) != null && D.video ? (t(), o("div", xt, [
|
|
809
|
+
(t(!0), o($, null, L(r.help.video, (i) => (t(), o("button", {
|
|
810
|
+
key: i.id,
|
|
811
|
+
onClick: (T) => g(i.link, i),
|
|
791
812
|
class: "flex items-center space-x-3 mt-2 w-full bg-[#FAFAFA] hover:bg-slate-100 p-4 text-[#525B66] rounded-lg text-sm hover:text-[#4089E0] font-medium"
|
|
792
813
|
}, [
|
|
793
|
-
_(
|
|
794
|
-
e("span", null,
|
|
814
|
+
_(A(tt), { class: "w-6 h-6" }),
|
|
815
|
+
e("span", null, d(i.name), 1)
|
|
795
816
|
], 8, _t))), 128))
|
|
796
|
-
])) :
|
|
797
|
-
(
|
|
817
|
+
])) : p("", !0),
|
|
818
|
+
(N = r.help) != null && N.socialList ? (t(), o("button", {
|
|
798
819
|
key: 1,
|
|
799
|
-
onClick:
|
|
820
|
+
onClick: x,
|
|
800
821
|
class: "flex items-center justify-between mt-2 w-full bg-[#FAFAFA] hover:bg-slate-100 p-4 text-[#525B66] rounded-lg text-sm hover:text-[#4089E0] font-medium"
|
|
801
822
|
}, [
|
|
802
823
|
e("div", wt, [
|
|
803
|
-
_(
|
|
804
|
-
e("span", null,
|
|
824
|
+
_(A(ot), { class: "w-6 h-6" }),
|
|
825
|
+
e("span", null, d(r.help.socialButt), 1)
|
|
805
826
|
]),
|
|
806
|
-
_(
|
|
807
|
-
])) :
|
|
827
|
+
_(A(h), { class: "w-4 h-4" })
|
|
828
|
+
])) : p("", !0),
|
|
808
829
|
e("div", kt, [
|
|
809
830
|
k.value ? (t(), o("div", bt, [
|
|
810
831
|
e("div", Ct, [
|
|
811
|
-
(t(!0), o(
|
|
812
|
-
key:
|
|
813
|
-
onClick: (
|
|
832
|
+
(t(!0), o($, null, L((q = r.help) == null ? void 0 : q.socialList, (i) => (t(), o("button", {
|
|
833
|
+
key: i.id,
|
|
834
|
+
onClick: (T) => g(i.link, i),
|
|
814
835
|
class: "flex items-center space-x-2 p-2 rounded-lg hover:bg-slate-100 hover:text-blue-500 tooltip"
|
|
815
836
|
}, [
|
|
816
837
|
e("div", null, [
|
|
817
|
-
|
|
818
|
-
(t(),
|
|
838
|
+
i.name ? (t(), o("div", At, d(i.name), 1)) : p("", !0),
|
|
839
|
+
(t(), M(V(i == null ? void 0 : i.icon), { class: "w-[24px] h-[24px] mx-auto" }))
|
|
819
840
|
])
|
|
820
841
|
], 8, $t))), 128))
|
|
821
842
|
])
|
|
822
|
-
])) :
|
|
843
|
+
])) : p("", !0)
|
|
823
844
|
]),
|
|
824
845
|
e("div", St, [
|
|
825
|
-
(t(!0), o(
|
|
826
|
-
key:
|
|
846
|
+
(t(!0), o($, null, L((U = r.help) == null ? void 0 : U.termsOffer, (i) => (t(), o("a", {
|
|
847
|
+
key: i.name,
|
|
827
848
|
target: "_blank",
|
|
828
|
-
href:
|
|
849
|
+
href: i.link,
|
|
829
850
|
class: "ml-2 flex items-center rounded-lg text-xs hover:underline font-extralight cursor-pointer"
|
|
830
851
|
}, [
|
|
831
|
-
e("div",
|
|
832
|
-
e("div",
|
|
833
|
-
e("span",
|
|
852
|
+
e("div", Lt, [
|
|
853
|
+
e("div", Bt, [
|
|
854
|
+
e("span", Mt, d(i.name), 1)
|
|
834
855
|
])
|
|
835
856
|
])
|
|
836
857
|
], 8, Ft))), 128))
|
|
837
858
|
])
|
|
838
859
|
])
|
|
839
|
-
])) :
|
|
860
|
+
])) : p("", !0)
|
|
840
861
|
], 8, nt);
|
|
841
862
|
};
|
|
842
863
|
}
|
|
843
864
|
});
|
|
844
|
-
const Ut = /* @__PURE__ */ X(
|
|
865
|
+
const Ut = /* @__PURE__ */ X(jt, [["__scopeId", "data-v-f5d2b453"]]);
|
|
845
866
|
export {
|
|
846
|
-
|
|
847
|
-
|
|
867
|
+
qt as O,
|
|
868
|
+
ge as _,
|
|
848
869
|
K as a,
|
|
849
|
-
|
|
870
|
+
Nt as b,
|
|
850
871
|
Ut as c,
|
|
851
872
|
he as d,
|
|
852
873
|
we as e,
|
|
853
874
|
Dt as f,
|
|
854
875
|
ot as g,
|
|
855
|
-
|
|
876
|
+
Be as r
|
|
856
877
|
};
|