@synopackageland/sdk 0.9.7 → 0.9.9
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 +12 -1
- package/dist/i18n/background/de.json +0 -1
- package/dist/i18n/background/en.json +0 -1
- package/dist/i18n/background/es.json +0 -1
- package/dist/i18n/background/fr.json +0 -1
- package/dist/i18n/background/it.json +0 -1
- package/dist/i18n/background/ja.json +2 -3
- package/dist/i18n/background/ko.json +0 -1
- package/dist/i18n/background/zh-CN.json +0 -1
- package/dist/i18n/background/zh-TW.json +0 -1
- package/dist/i18n/delegate/de.json +10 -2
- package/dist/i18n/delegate/en.json +10 -2
- package/dist/i18n/delegate/es.json +10 -2
- package/dist/i18n/delegate/fr.json +10 -2
- package/dist/i18n/delegate/it.json +10 -2
- package/dist/i18n/delegate/ja.json +10 -2
- package/dist/i18n/delegate/ko.json +10 -2
- package/dist/i18n/delegate/zh-CN.json +10 -2
- package/dist/i18n/delegate/zh-TW.json +10 -2
- package/dist/i18n/files/de.json +1 -0
- package/dist/i18n/files/en.json +1 -0
- package/dist/i18n/files/es.json +1 -0
- package/dist/i18n/files/fr.json +1 -0
- package/dist/i18n/files/it.json +1 -0
- package/dist/i18n/files/ja.json +1 -0
- package/dist/i18n/files/ko.json +1 -0
- package/dist/i18n/files/zh-CN.json +1 -0
- package/dist/i18n/files/zh-TW.json +1 -0
- package/dist/i18n/identity/de.json +2 -0
- package/dist/i18n/identity/en.json +2 -0
- package/dist/i18n/identity/es.json +2 -0
- package/dist/i18n/identity/fr.json +2 -0
- package/dist/i18n/identity/it.json +2 -0
- package/dist/i18n/identity/ja.json +2 -0
- package/dist/i18n/identity/ko.json +2 -0
- package/dist/i18n/identity/zh-CN.json +2 -0
- package/dist/i18n/identity/zh-TW.json +2 -0
- package/dist/i18n/portal/de.json +21 -0
- package/dist/i18n/portal/en.json +21 -0
- package/dist/i18n/portal/es.json +21 -0
- package/dist/i18n/portal/fr.json +21 -0
- package/dist/i18n/portal/it.json +21 -0
- package/dist/i18n/portal/ja.json +21 -0
- package/dist/i18n/portal/ko.json +21 -0
- package/dist/i18n/portal/zh-CN.json +21 -0
- package/dist/i18n/portal/zh-TW.json +21 -0
- package/dist/i18n/save/de.json +12 -2
- package/dist/i18n/save/en.json +12 -2
- package/dist/i18n/save/es.json +12 -2
- package/dist/i18n/save/fr.json +12 -2
- package/dist/i18n/save/it.json +12 -2
- package/dist/i18n/save/ja.json +12 -2
- package/dist/i18n/save/ko.json +12 -2
- package/dist/i18n/save/zh-CN.json +12 -2
- package/dist/i18n/save/zh-TW.json +12 -2
- package/dist/index.js +2622 -2162
- package/dist/src/background/BackgroundPanel.vue.d.ts +4 -1
- package/dist/src/background/i18n.d.ts +0 -1
- package/dist/src/background/picker-provider.d.ts +1 -1
- package/dist/src/context.d.ts +4 -1
- package/dist/src/delegate/BackgroundSavePanel.vue.d.ts +6 -1
- package/dist/src/delegate/DelegatePanel.vue.d.ts +3 -1
- package/dist/src/delegate/ExecutorSettings.vue.d.ts +4 -1
- package/dist/src/delegate/copy.d.ts +18 -2
- package/dist/src/delegate/save-copy.d.ts +34 -4
- package/dist/src/i18n.d.ts +2 -0
- package/dist/src/identity/i18n.d.ts +2 -0
- package/dist/src/index.d.ts +4 -1
- package/dist/src/nas/NasPicker.vue.d.ts +3 -0
- package/dist/src/nas/locale.d.ts +1 -0
- package/dist/src/nas/provider.d.ts +2 -2
- package/dist/src/portal/access.d.ts +16 -0
- package/dist/src/portal/i18n.d.ts +3 -0
- package/dist/style.css +1 -1
- package/dist/vue.js +1828 -1574
- package/package.json +3 -3
package/dist/vue.js
CHANGED
|
@@ -1,11 +1,11 @@
|
|
|
1
|
-
import { shellCopy as
|
|
2
|
-
import { FILE_STATION_APP as
|
|
3
|
-
import { inject as
|
|
4
|
-
import { AppLayout as
|
|
5
|
-
import { Timer as
|
|
6
|
-
const
|
|
7
|
-
function
|
|
8
|
-
return
|
|
1
|
+
import { shellCopy as aa, nasCopy as be, nasErrorCopy as Le, format as Ae, uiLocale as ta, saveCopy as Ne, saveError as Ie, createNasProvider as Me, identityCopy as la, backgroundCopy as sa, createBackgroundPickerProvider as na, backgroundErrorCopy as ia, requestKey as Be, delegateCopy as Ke, labelSeparator as He, errorCopy as oa, scopedPicker as ua, openFolderInFileStation as ra, authorizationCopy as da } from "./index.js";
|
|
2
|
+
import { DEFAULT_REQUEST_TIMEOUT as ts, FILE_STATION_APP as ls, activePage as ss, authorizationCatalogs as ns, backgroundCatalogs as is, catalogs as os, clientTimeout as us, createBackgroundSaveFacade as rs, createFileTransfers as ds, createPortalAccess as vs, decodeResponse as cs, delegateCatalogs as ps, encodeRequest as fs, fileStationPath as ys, identityCatalogs as ms, mergeCatalogs as bs, nasCatalogs as gs, openFileInFileStation as hs, portalCatalogs as ks, portalMessages as _s, protocolCodes as ws, protocolOps as xs, protocolSchemas as Cs, saveCatalogs as $s, shellCatalogs as Ss, shellPages as zs, uiLocales as Ps } from "./index.js";
|
|
3
|
+
import { inject as Ge, ref as b, onBeforeUnmount as ye, defineComponent as oe, computed as L, openBlock as s, createBlock as x, unref as e, withCtx as l, createVNode as d, renderSlot as De, createElementVNode as $, markRaw as va, h as ca, onMounted as ge, createElementBlock as V, createTextVNode as g, toDisplayString as t, createCommentVNode as h, watch as Je, Fragment as ne, createSlots as Xe, withModifiers as Se, onUnmounted as Qe, nextTick as pa, renderList as ke, provide as fa } from "vue";
|
|
4
|
+
import { AppLayout as ya, PageContent as ma, PageHeader as ba, AppSidebar as ga, FileTypeIcon as Ee, IconButton as Ue, Breadcrumb as ha, FilePicker as ka, Button as U, Callout as X, TreeView as _a, DataGrid as wa, Dialog as qe, SettingsSection as he, PathDisplay as pe, Link as Ye, Form as ze, FormItem as fe, Input as _e, FormActions as Pe, Card as Fe, Badge as $e, Select as Ze, Checkbox as xa, KeyValueRow as Ce, DataTable as Ca, formatFileSize as $a, Pagination as Sa, SettingsRow as za } from "@synopackageland/ui";
|
|
5
|
+
import { Timer as Pa, Info as Va, ChevronLeft as Ia, ChevronRight as Ta, RotateCw as Ea, FolderOpen as Ua, ShieldCheck as Aa } from "@lucide/vue";
|
|
6
|
+
const Da = /* @__PURE__ */ Symbol("executor-setup");
|
|
7
|
+
function We() {
|
|
8
|
+
return Ge(Da, {
|
|
9
9
|
async status() {
|
|
10
10
|
return { state: "blocked", reason: "setup-unavailable" };
|
|
11
11
|
},
|
|
@@ -17,102 +17,102 @@ function Ca() {
|
|
|
17
17
|
}
|
|
18
18
|
});
|
|
19
19
|
}
|
|
20
|
-
function
|
|
21
|
-
const
|
|
22
|
-
let
|
|
23
|
-
function
|
|
24
|
-
clearTimeout(
|
|
20
|
+
function Ml(y) {
|
|
21
|
+
const q = b(!1), f = b(!1), a = b(), o = b("");
|
|
22
|
+
let m = !1, i = 0, n, u;
|
|
23
|
+
function r() {
|
|
24
|
+
clearTimeout(n), clearTimeout(u);
|
|
25
25
|
}
|
|
26
|
-
function v(
|
|
27
|
-
|
|
26
|
+
function v(N = "") {
|
|
27
|
+
i++, r(), a.value = void 0, o.value = N;
|
|
28
28
|
}
|
|
29
|
-
function
|
|
30
|
-
if (
|
|
31
|
-
const
|
|
32
|
-
if (!Number.isFinite(
|
|
29
|
+
function k(N) {
|
|
30
|
+
if (m) return;
|
|
31
|
+
const K = Date.parse(N.expiresAt) - Date.now();
|
|
32
|
+
if (!Number.isFinite(K) || K <= 0) {
|
|
33
33
|
v("expired");
|
|
34
34
|
return;
|
|
35
35
|
}
|
|
36
|
-
|
|
37
|
-
const
|
|
38
|
-
|
|
36
|
+
r(), a.value = N, o.value = "", n = setTimeout(() => v("expired"), K);
|
|
37
|
+
const O = i;
|
|
38
|
+
u = setTimeout(async () => {
|
|
39
39
|
try {
|
|
40
|
-
const
|
|
41
|
-
!
|
|
40
|
+
const Z = await y.call("identity.session");
|
|
41
|
+
!m && i === O && k(Z);
|
|
42
42
|
} catch {
|
|
43
|
-
!
|
|
43
|
+
!m && i === O && v("expired");
|
|
44
44
|
}
|
|
45
|
-
}, Math.min(6e4,
|
|
45
|
+
}, Math.min(6e4, K));
|
|
46
46
|
}
|
|
47
|
-
async function
|
|
47
|
+
async function D() {
|
|
48
48
|
try {
|
|
49
|
-
const
|
|
50
|
-
if (
|
|
51
|
-
if (
|
|
49
|
+
const N = await y.call("identity.status");
|
|
50
|
+
if (m) return;
|
|
51
|
+
if (q.value = N.enabled === !0, q.value)
|
|
52
52
|
try {
|
|
53
|
-
|
|
53
|
+
k(await y.call("identity.session", { bootstrap: !0 }));
|
|
54
54
|
} catch {
|
|
55
|
-
|
|
55
|
+
m || v();
|
|
56
56
|
}
|
|
57
|
-
} catch (
|
|
58
|
-
const
|
|
59
|
-
|
|
57
|
+
} catch (N) {
|
|
58
|
+
const K = N?.code;
|
|
59
|
+
q.value = !["unknown_method", "admin_required", "app_privilege_denied", "session_required"].includes(K || ""), q.value && (o.value = "unavailable");
|
|
60
60
|
} finally {
|
|
61
|
-
|
|
61
|
+
m || (f.value = !0);
|
|
62
62
|
}
|
|
63
63
|
}
|
|
64
|
-
async function
|
|
65
|
-
const
|
|
64
|
+
async function S(N, K) {
|
|
65
|
+
const O = i;
|
|
66
66
|
try {
|
|
67
|
-
const
|
|
68
|
-
if (
|
|
69
|
-
return
|
|
70
|
-
} catch (
|
|
71
|
-
const
|
|
72
|
-
throw !
|
|
67
|
+
const Z = await y.call(N, K);
|
|
68
|
+
if (m || q.value && O !== i) throw { code: "session_required" };
|
|
69
|
+
return Z;
|
|
70
|
+
} catch (Z) {
|
|
71
|
+
const ae = Z?.code;
|
|
72
|
+
throw !m && O === i && q.value && ["session_required", "session_revalidation_required"].includes(ae || "") && v(ae === "session_revalidation_required" ? "revalidate" : "expired"), Z;
|
|
73
73
|
}
|
|
74
74
|
}
|
|
75
|
-
async function
|
|
76
|
-
const
|
|
77
|
-
|
|
75
|
+
async function c(N, K, O) {
|
|
76
|
+
const Z = await y.call("identity.login", { account: N, password: K, otp: O });
|
|
77
|
+
m || (i++, k(Z));
|
|
78
78
|
}
|
|
79
|
-
async function
|
|
80
|
-
const
|
|
81
|
-
|
|
79
|
+
async function w() {
|
|
80
|
+
const N = await y.call("identity.session", { bootstrap: !0 });
|
|
81
|
+
m || (i++, k(N));
|
|
82
82
|
}
|
|
83
|
-
async function
|
|
84
|
-
await
|
|
83
|
+
async function z() {
|
|
84
|
+
await y.call("identity.logout"), m || v();
|
|
85
85
|
}
|
|
86
|
-
function
|
|
87
|
-
|
|
86
|
+
function M() {
|
|
87
|
+
m = !0, v();
|
|
88
88
|
}
|
|
89
|
-
return { enabled:
|
|
89
|
+
return { enabled: q, ready: f, subject: a, notice: o, start: D, call: S, login: c, bootstrap: w, logout: z, dispose: M };
|
|
90
90
|
}
|
|
91
|
-
function
|
|
92
|
-
const
|
|
93
|
-
let
|
|
94
|
-
function
|
|
95
|
-
|
|
91
|
+
function Ra() {
|
|
92
|
+
const y = b(!1), q = b();
|
|
93
|
+
let f = !1, a = 0, o;
|
|
94
|
+
function m() {
|
|
95
|
+
a++, o?.abort(), o = void 0, y.value = !1, q.value = void 0;
|
|
96
96
|
}
|
|
97
|
-
async function
|
|
98
|
-
if (
|
|
99
|
-
const
|
|
100
|
-
|
|
97
|
+
async function i(n) {
|
|
98
|
+
if (f || y.value) return;
|
|
99
|
+
const u = ++a, r = new AbortController();
|
|
100
|
+
o = r, y.value = !0, q.value = void 0;
|
|
101
101
|
try {
|
|
102
|
-
const v = await
|
|
103
|
-
return !
|
|
102
|
+
const v = await n(r.signal);
|
|
103
|
+
return !f && u === a ? v : void 0;
|
|
104
104
|
} catch (v) {
|
|
105
|
-
!
|
|
105
|
+
!f && u === a && (q.value = v);
|
|
106
106
|
return;
|
|
107
107
|
} finally {
|
|
108
|
-
!
|
|
108
|
+
!f && u === a && (y.value = !1, o = void 0);
|
|
109
109
|
}
|
|
110
110
|
}
|
|
111
|
-
return
|
|
112
|
-
|
|
113
|
-
}), { busy:
|
|
111
|
+
return ye(() => {
|
|
112
|
+
f = !0, m();
|
|
113
|
+
}), { busy: y, error: q, run: i, cancel: m };
|
|
114
114
|
}
|
|
115
|
-
const
|
|
115
|
+
const qa = { class: "app-page-content" }, Ba = /* @__PURE__ */ oe({
|
|
116
116
|
__name: "AppShell",
|
|
117
117
|
props: {
|
|
118
118
|
locale: {},
|
|
@@ -121,36 +121,36 @@ const xa = { class: "app-page-content" }, Sa = /* @__PURE__ */ le({
|
|
|
121
121
|
description: {}
|
|
122
122
|
},
|
|
123
123
|
emits: ["update:modelValue"],
|
|
124
|
-
setup(
|
|
125
|
-
const
|
|
126
|
-
items:
|
|
127
|
-
}]),
|
|
128
|
-
return (
|
|
124
|
+
setup(y, { emit: q }) {
|
|
125
|
+
const f = y, a = q, o = L(() => aa(f.locale)), m = { status: Va, background: Pa }, i = L(() => [{
|
|
126
|
+
items: f.pages.map((u) => ({ key: u, label: o.value[u], icon: m[u] }))
|
|
127
|
+
}]), n = L(() => o.value[f.modelValue] ?? o.value.status);
|
|
128
|
+
return (u, r) => (s(), x(e(ya), {
|
|
129
129
|
class: "app-shell",
|
|
130
130
|
"min-height": "0",
|
|
131
131
|
"wide-layout": "window"
|
|
132
132
|
}, {
|
|
133
|
-
sidebar:
|
|
134
|
-
|
|
135
|
-
"model-value":
|
|
136
|
-
groups:
|
|
137
|
-
"onUpdate:modelValue":
|
|
133
|
+
sidebar: l(() => [
|
|
134
|
+
d(e(ga), {
|
|
135
|
+
"model-value": y.modelValue,
|
|
136
|
+
groups: i.value,
|
|
137
|
+
"onUpdate:modelValue": r[0] || (r[0] = (v) => a("update:modelValue", v))
|
|
138
138
|
}, null, 8, ["model-value", "groups"])
|
|
139
139
|
]),
|
|
140
|
-
default:
|
|
141
|
-
|
|
142
|
-
default:
|
|
143
|
-
|
|
144
|
-
title:
|
|
145
|
-
description:
|
|
140
|
+
default: l(() => [
|
|
141
|
+
d(e(ma), { class: "app-page" }, {
|
|
142
|
+
default: l(() => [
|
|
143
|
+
d(e(ba), {
|
|
144
|
+
title: n.value,
|
|
145
|
+
description: y.description
|
|
146
146
|
}, {
|
|
147
|
-
actions:
|
|
148
|
-
|
|
147
|
+
actions: l(() => [
|
|
148
|
+
De(u.$slots, "actions", {}, void 0, !0)
|
|
149
149
|
]),
|
|
150
150
|
_: 3
|
|
151
151
|
}, 8, ["title", "description"]),
|
|
152
|
-
|
|
153
|
-
|
|
152
|
+
$("div", qa, [
|
|
153
|
+
De(u.$slots, "default", {}, void 0, !0)
|
|
154
154
|
])
|
|
155
155
|
]),
|
|
156
156
|
_: 3
|
|
@@ -159,32 +159,32 @@ const xa = { class: "app-page-content" }, Sa = /* @__PURE__ */ le({
|
|
|
159
159
|
_: 3
|
|
160
160
|
}));
|
|
161
161
|
}
|
|
162
|
-
}),
|
|
163
|
-
const
|
|
164
|
-
for (const [
|
|
165
|
-
a
|
|
166
|
-
return
|
|
167
|
-
},
|
|
168
|
-
function
|
|
169
|
-
let
|
|
170
|
-
for (;
|
|
171
|
-
|
|
172
|
-
return `${new Intl.NumberFormat(
|
|
162
|
+
}), ue = (y, q) => {
|
|
163
|
+
const f = y.__vccOpts || y;
|
|
164
|
+
for (const [a, o] of q)
|
|
165
|
+
f[a] = o;
|
|
166
|
+
return f;
|
|
167
|
+
}, Kl = /* @__PURE__ */ ue(Ba, [["__scopeId", "data-v-05f63ca5"]]), Oe = ["B", "KB", "MB", "GB", "TB", "PB"];
|
|
168
|
+
function Re(y, q) {
|
|
169
|
+
let f = 0, a = y;
|
|
170
|
+
for (; a >= 1024 && f < Oe.length - 1; )
|
|
171
|
+
a /= 1024, f++;
|
|
172
|
+
return `${new Intl.NumberFormat(q, { maximumFractionDigits: f ? 1 : 0 }).format(a)} ${Oe[f]}`;
|
|
173
173
|
}
|
|
174
|
-
const
|
|
174
|
+
const Fa = ["aria-busy", "aria-label"], Oa = { class: "file-toolbar file-location" }, La = ["aria-label"], Na = {
|
|
175
175
|
key: 0,
|
|
176
176
|
class: "file-toolbar"
|
|
177
|
-
},
|
|
177
|
+
}, Ma = {
|
|
178
178
|
key: 1,
|
|
179
179
|
role: "status"
|
|
180
|
-
},
|
|
180
|
+
}, Ka = { role: "alert" }, Ha = {
|
|
181
181
|
key: 4,
|
|
182
182
|
role: "status"
|
|
183
|
-
},
|
|
183
|
+
}, Ga = { class: "file-columns" }, Ja = ["aria-label"], Xa = { class: "file-content" }, Qa = { class: "file-name" }, Ya = { class: "file-empty" }, Za = { class: "file-bytes" }, Wa = {
|
|
184
184
|
key: 5,
|
|
185
185
|
class: "file-selection",
|
|
186
186
|
role: "status"
|
|
187
|
-
},
|
|
187
|
+
}, ja = /* @__PURE__ */ oe({
|
|
188
188
|
__name: "FileBrowser",
|
|
189
189
|
props: {
|
|
190
190
|
provider: {},
|
|
@@ -193,310 +193,310 @@ const za = ["aria-busy", "aria-label"], Pa = { class: "file-toolbar file-locatio
|
|
|
193
193
|
transfers: { type: Boolean, default: !1 }
|
|
194
194
|
},
|
|
195
195
|
emits: ["selected"],
|
|
196
|
-
setup(
|
|
197
|
-
const
|
|
198
|
-
let
|
|
199
|
-
async function
|
|
200
|
-
const
|
|
201
|
-
!
|
|
196
|
+
setup(y, { emit: q }) {
|
|
197
|
+
const f = y, a = q, o = L(() => be(f.locale)), m = Ra(), { busy: i, error: n } = m, u = b([]), r = b([]), v = b([]), k = b(), D = b(), S = b(), c = b([]), w = b(), z = b({ key: "name", direction: "asc" }), M = b(0), N = b([]), K = b(!1);
|
|
198
|
+
let O = new AbortController();
|
|
199
|
+
async function Z() {
|
|
200
|
+
const C = k.value;
|
|
201
|
+
!C || C.isDir || !f.provider.download || await m.run(async (P) => (await f.provider.info(C.path, P), f.provider.download(C.path), !0));
|
|
202
202
|
}
|
|
203
|
-
async function
|
|
204
|
-
const
|
|
205
|
-
if (!
|
|
206
|
-
|
|
203
|
+
async function ae() {
|
|
204
|
+
const C = v.value.at(-1)?.path, P = N.value[0];
|
|
205
|
+
if (!C || !P || !f.provider.upload) return;
|
|
206
|
+
K.value = !1, await m.run(async (p) => (await f.provider.upload(C, P, p), !0)) && (N.value = [], await re(v.value), K.value = !0);
|
|
207
207
|
}
|
|
208
|
-
const
|
|
209
|
-
{ key: "name", label:
|
|
210
|
-
{ key: "kind", label:
|
|
211
|
-
{ key: "bytes", label:
|
|
212
|
-
]), H =
|
|
213
|
-
function
|
|
214
|
-
return { id:
|
|
208
|
+
const W = L(() => [
|
|
209
|
+
{ key: "name", label: o.value.nameColumn, sortable: !0 },
|
|
210
|
+
{ key: "kind", label: o.value.kindColumn },
|
|
211
|
+
{ key: "bytes", label: o.value.sizeColumn, align: "right", sortable: !0 }
|
|
212
|
+
]), H = va((C, { attrs: P }) => ca(Ee, { ...P, kind: "folder" }));
|
|
213
|
+
function j(C) {
|
|
214
|
+
return { id: C.path, label: C.name, icon: H, data: C };
|
|
215
215
|
}
|
|
216
|
-
function
|
|
217
|
-
|
|
216
|
+
function te(C) {
|
|
217
|
+
k.value = C, a("selected", C?.path);
|
|
218
218
|
}
|
|
219
|
-
function
|
|
220
|
-
|
|
219
|
+
function se(C) {
|
|
220
|
+
D.value = C.path, te(f.mode === "folder" ? C.isDir ? C : v.value.at(-1) : C.isDir ? void 0 : C);
|
|
221
221
|
}
|
|
222
|
-
function
|
|
223
|
-
|
|
222
|
+
function Q(C) {
|
|
223
|
+
C.isDir ? ve(C) : se(C);
|
|
224
224
|
}
|
|
225
|
-
const
|
|
226
|
-
function
|
|
227
|
-
for (const
|
|
228
|
-
const
|
|
229
|
-
if (
|
|
230
|
-
const
|
|
231
|
-
if (
|
|
225
|
+
const Y = (C) => u.value.find((P) => P.path === C);
|
|
226
|
+
function G(C, P, I = []) {
|
|
227
|
+
for (const p of C) {
|
|
228
|
+
const B = [...I, p.data];
|
|
229
|
+
if (p.id === P) return B;
|
|
230
|
+
const _ = G(p.children ?? [], P, B);
|
|
231
|
+
if (_) return _;
|
|
232
232
|
}
|
|
233
233
|
}
|
|
234
|
-
function
|
|
235
|
-
for (const
|
|
236
|
-
if (
|
|
237
|
-
const
|
|
238
|
-
if (
|
|
234
|
+
function le(C, P) {
|
|
235
|
+
for (const I of C) {
|
|
236
|
+
if (I.id === P) return I;
|
|
237
|
+
const p = le(I.children ?? [], P);
|
|
238
|
+
if (p) return p;
|
|
239
239
|
}
|
|
240
240
|
}
|
|
241
|
-
function
|
|
242
|
-
return
|
|
241
|
+
function R(C, P, I) {
|
|
242
|
+
return C.map((p) => p.id === P ? { ...p, children: I } : p.children ? { ...p, children: R(p.children, P, I) } : p);
|
|
243
243
|
}
|
|
244
|
-
let
|
|
245
|
-
async function
|
|
246
|
-
const
|
|
247
|
-
for (const
|
|
248
|
-
const
|
|
249
|
-
if (!
|
|
250
|
-
if (
|
|
251
|
-
const
|
|
252
|
-
if (
|
|
253
|
-
|
|
244
|
+
let T = 0;
|
|
245
|
+
async function E(C) {
|
|
246
|
+
const P = ++T;
|
|
247
|
+
for (const I of C.slice(0, -1)) {
|
|
248
|
+
const p = le(r.value, I.path);
|
|
249
|
+
if (!p) break;
|
|
250
|
+
if (p.children === void 0) {
|
|
251
|
+
const B = await J(p);
|
|
252
|
+
if (P !== T || !B) return;
|
|
253
|
+
r.value = R(r.value, p.id, B);
|
|
254
254
|
}
|
|
255
|
-
|
|
255
|
+
c.value.includes(p.id) || (c.value = [...c.value, p.id]);
|
|
256
256
|
}
|
|
257
|
-
|
|
257
|
+
w.value = C.at(-1)?.path;
|
|
258
258
|
}
|
|
259
|
-
async function
|
|
260
|
-
const
|
|
259
|
+
async function J(C) {
|
|
260
|
+
const P = M.value, I = O.signal;
|
|
261
261
|
try {
|
|
262
|
-
const
|
|
263
|
-
let
|
|
264
|
-
for (;
|
|
265
|
-
const
|
|
266
|
-
if (
|
|
267
|
-
|
|
262
|
+
const p = [];
|
|
263
|
+
let B = 0;
|
|
264
|
+
for (; B !== void 0; ) {
|
|
265
|
+
const _ = await f.provider.list(C.id, { offset: B, sortBy: "name", sortDirection: "ASC" }, I);
|
|
266
|
+
if (I.aborted || P !== M.value) return;
|
|
267
|
+
p.push(..._.entries.filter((ie) => ie.isDir).map(j)), B = _.nextOffset;
|
|
268
268
|
}
|
|
269
|
-
return
|
|
270
|
-
} catch (
|
|
271
|
-
!
|
|
269
|
+
return p;
|
|
270
|
+
} catch (p) {
|
|
271
|
+
!I.aborted && P === M.value && (n.value = p, te());
|
|
272
272
|
return;
|
|
273
273
|
}
|
|
274
274
|
}
|
|
275
|
-
async function
|
|
276
|
-
if (
|
|
277
|
-
|
|
278
|
-
const
|
|
279
|
-
v.value =
|
|
280
|
-
const
|
|
281
|
-
|
|
275
|
+
async function re(C, P = !1) {
|
|
276
|
+
if (i.value) return;
|
|
277
|
+
te(), D.value = void 0, u.value = P ? u.value : [], S.value = P ? S.value : void 0;
|
|
278
|
+
const I = P ? S.value ?? 0 : 0, p = C.at(-1)?.path;
|
|
279
|
+
v.value = C;
|
|
280
|
+
const B = await m.run((_) => p ? f.provider.list(p, { offset: I, sortBy: z.value.key, sortDirection: z.value.direction === "asc" ? "ASC" : "DESC" }, _) : f.provider.shares(I, _));
|
|
281
|
+
B && (u.value = P ? [...u.value, ...B.entries] : B.entries, S.value = B.nextOffset, p ? f.mode === "folder" && !P && te(C.at(-1)) : r.value = u.value.filter((_) => _.isDir).map(j), P || E(C));
|
|
282
282
|
}
|
|
283
|
-
const
|
|
284
|
-
function
|
|
285
|
-
const
|
|
286
|
-
|
|
283
|
+
const we = L(() => [{ id: "", display: o.value.roots }, ...v.value.map((C) => ({ id: C.path, display: C.name }))]);
|
|
284
|
+
function xe(C) {
|
|
285
|
+
const P = we.value.findIndex((I) => I.id === C.id);
|
|
286
|
+
P < v.value.length && me(v.value.slice(0, P));
|
|
287
287
|
}
|
|
288
|
-
function
|
|
289
|
-
|
|
288
|
+
function ve(C) {
|
|
289
|
+
me([...v.value, C]);
|
|
290
290
|
}
|
|
291
|
-
const
|
|
292
|
-
function
|
|
293
|
-
|
|
291
|
+
const ce = b([[]]), de = b(0);
|
|
292
|
+
function me(C) {
|
|
293
|
+
i.value || (C.at(-1)?.path !== v.value.at(-1)?.path && (ce.value = [...ce.value.slice(0, de.value + 1), C], de.value++), re(C));
|
|
294
294
|
}
|
|
295
|
-
function
|
|
296
|
-
|
|
295
|
+
function F(C) {
|
|
296
|
+
i.value || (de.value += C, re(ce.value[de.value]));
|
|
297
297
|
}
|
|
298
|
-
function
|
|
299
|
-
|
|
298
|
+
function ee(C) {
|
|
299
|
+
z.value = { key: C?.key === "bytes" ? "size" : "name", direction: C?.direction ?? "asc" }, re(v.value);
|
|
300
300
|
}
|
|
301
|
-
function
|
|
302
|
-
|
|
301
|
+
function A() {
|
|
302
|
+
i.value || (M.value++, O.abort(), O = new AbortController(), r.value = [], c.value = [], w.value = void 0, ce.value = [[]], de.value = 0, re([]));
|
|
303
303
|
}
|
|
304
|
-
return
|
|
305
|
-
|
|
306
|
-
}),
|
|
307
|
-
|
|
308
|
-
}), (
|
|
304
|
+
return ge(() => {
|
|
305
|
+
re([]);
|
|
306
|
+
}), ye(() => {
|
|
307
|
+
M.value++, O.abort();
|
|
308
|
+
}), (C, P) => (s(), V("section", {
|
|
309
309
|
class: "file-browser",
|
|
310
|
-
"aria-busy": e(
|
|
311
|
-
"aria-label":
|
|
310
|
+
"aria-busy": e(i),
|
|
311
|
+
"aria-label": o.value.title
|
|
312
312
|
}, [
|
|
313
|
-
|
|
314
|
-
|
|
315
|
-
label:
|
|
313
|
+
$("div", Oa, [
|
|
314
|
+
d(e(Ue), {
|
|
315
|
+
label: o.value.back,
|
|
316
316
|
size: "sm",
|
|
317
|
-
disabled: e(
|
|
318
|
-
onClick:
|
|
317
|
+
disabled: e(i) || de.value === 0,
|
|
318
|
+
onClick: P[0] || (P[0] = (I) => F(-1))
|
|
319
319
|
}, {
|
|
320
|
-
default:
|
|
321
|
-
|
|
320
|
+
default: l(() => [
|
|
321
|
+
d(e(Ia), {
|
|
322
322
|
size: 16,
|
|
323
323
|
"aria-hidden": "true"
|
|
324
324
|
})
|
|
325
325
|
]),
|
|
326
326
|
_: 1
|
|
327
327
|
}, 8, ["label", "disabled"]),
|
|
328
|
-
|
|
329
|
-
label:
|
|
328
|
+
d(e(Ue), {
|
|
329
|
+
label: o.value.forward,
|
|
330
330
|
size: "sm",
|
|
331
|
-
disabled: e(
|
|
332
|
-
onClick:
|
|
331
|
+
disabled: e(i) || de.value === ce.value.length - 1,
|
|
332
|
+
onClick: P[1] || (P[1] = (I) => F(1))
|
|
333
333
|
}, {
|
|
334
|
-
default:
|
|
335
|
-
|
|
334
|
+
default: l(() => [
|
|
335
|
+
d(e(Ta), {
|
|
336
336
|
size: 16,
|
|
337
337
|
"aria-hidden": "true"
|
|
338
338
|
})
|
|
339
339
|
]),
|
|
340
340
|
_: 1
|
|
341
341
|
}, 8, ["label", "disabled"]),
|
|
342
|
-
|
|
343
|
-
label:
|
|
342
|
+
d(e(Ue), {
|
|
343
|
+
label: o.value.refresh,
|
|
344
344
|
size: "sm",
|
|
345
|
-
disabled: e(
|
|
346
|
-
onClick:
|
|
345
|
+
disabled: e(i),
|
|
346
|
+
onClick: A
|
|
347
347
|
}, {
|
|
348
|
-
default:
|
|
349
|
-
|
|
348
|
+
default: l(() => [
|
|
349
|
+
d(e(Ea), {
|
|
350
350
|
size: 14,
|
|
351
351
|
"aria-hidden": "true"
|
|
352
352
|
})
|
|
353
353
|
]),
|
|
354
354
|
_: 1
|
|
355
355
|
}, 8, ["label", "disabled"]),
|
|
356
|
-
|
|
356
|
+
$("nav", {
|
|
357
357
|
class: "file-path",
|
|
358
|
-
"aria-label":
|
|
358
|
+
"aria-label": o.value.location
|
|
359
359
|
}, [
|
|
360
|
-
|
|
361
|
-
items:
|
|
362
|
-
"collapsed-label":
|
|
363
|
-
onClickItem:
|
|
360
|
+
d(e(ha), {
|
|
361
|
+
items: we.value,
|
|
362
|
+
"collapsed-label": o.value.fullPath,
|
|
363
|
+
onClickItem: xe
|
|
364
364
|
}, null, 8, ["items", "collapsed-label"])
|
|
365
|
-
], 8,
|
|
365
|
+
], 8, La)
|
|
366
366
|
]),
|
|
367
|
-
|
|
368
|
-
|
|
369
|
-
modelValue:
|
|
370
|
-
"onUpdate:modelValue":
|
|
367
|
+
y.transfers && y.provider.upload && v.value.length ? (s(), V("div", Na, [
|
|
368
|
+
d(e(ka), {
|
|
369
|
+
modelValue: N.value,
|
|
370
|
+
"onUpdate:modelValue": P[2] || (P[2] = (I) => N.value = I),
|
|
371
371
|
variant: "compact",
|
|
372
|
-
disabled: e(
|
|
372
|
+
disabled: e(i),
|
|
373
373
|
"max-files": 1,
|
|
374
374
|
"max-size": 16 * 1024 ** 3,
|
|
375
|
-
title:
|
|
376
|
-
onRejected:
|
|
375
|
+
title: o.value.upload,
|
|
376
|
+
onRejected: P[3] || (P[3] = (I) => n.value = { code: "upload_size_required" })
|
|
377
377
|
}, null, 8, ["modelValue", "disabled", "title"]),
|
|
378
|
-
|
|
378
|
+
d(e(U), {
|
|
379
379
|
variant: "primary",
|
|
380
|
-
disabled: e(
|
|
381
|
-
onClick:
|
|
380
|
+
disabled: e(i) || !N.value.length,
|
|
381
|
+
onClick: ae
|
|
382
382
|
}, {
|
|
383
|
-
default:
|
|
384
|
-
g(
|
|
383
|
+
default: l(() => [
|
|
384
|
+
g(t(o.value.upload), 1)
|
|
385
385
|
]),
|
|
386
386
|
_: 1
|
|
387
387
|
}, 8, ["disabled"])
|
|
388
|
-
])) :
|
|
389
|
-
|
|
390
|
-
|
|
388
|
+
])) : h("", !0),
|
|
389
|
+
K.value ? (s(), V("p", Ma, t(o.value.uploaded), 1)) : h("", !0),
|
|
390
|
+
y.transfers && y.provider.download && k.value && !k.value.isDir && !e(n) ? (s(), x(e(U), {
|
|
391
391
|
key: 2,
|
|
392
392
|
variant: "secondary",
|
|
393
|
-
disabled: e(
|
|
394
|
-
onClick:
|
|
393
|
+
disabled: e(i),
|
|
394
|
+
onClick: Z
|
|
395
395
|
}, {
|
|
396
|
-
default:
|
|
397
|
-
g(
|
|
396
|
+
default: l(() => [
|
|
397
|
+
g(t(o.value.download), 1)
|
|
398
398
|
]),
|
|
399
399
|
_: 1
|
|
400
|
-
}, 8, ["disabled"])) :
|
|
401
|
-
e(
|
|
400
|
+
}, 8, ["disabled"])) : h("", !0),
|
|
401
|
+
e(n) ? (s(), x(e(X), {
|
|
402
402
|
key: 3,
|
|
403
403
|
tone: "danger"
|
|
404
404
|
}, {
|
|
405
|
-
default:
|
|
406
|
-
|
|
405
|
+
default: l(() => [
|
|
406
|
+
$("span", Ka, t(e(Le)(e(n), o.value)), 1)
|
|
407
407
|
]),
|
|
408
408
|
_: 1
|
|
409
|
-
})) :
|
|
410
|
-
e(
|
|
411
|
-
|
|
412
|
-
|
|
409
|
+
})) : h("", !0),
|
|
410
|
+
e(i) ? (s(), V("p", Ha, t(o.value.loading), 1)) : h("", !0),
|
|
411
|
+
$("div", Ga, [
|
|
412
|
+
$("aside", {
|
|
413
413
|
class: "file-tree",
|
|
414
|
-
"aria-label":
|
|
414
|
+
"aria-label": o.value.roots
|
|
415
415
|
}, [
|
|
416
|
-
|
|
417
|
-
key:
|
|
416
|
+
r.value.length ? (s(), x(e(_a), {
|
|
417
|
+
key: M.value,
|
|
418
418
|
"selection-style": "background",
|
|
419
|
-
modelValue:
|
|
420
|
-
"onUpdate:modelValue":
|
|
421
|
-
nodes:
|
|
422
|
-
"onUpdate:nodes":
|
|
423
|
-
expanded:
|
|
424
|
-
"onUpdate:expanded":
|
|
425
|
-
"load-children":
|
|
426
|
-
"expand-label": (
|
|
427
|
-
onSelect:
|
|
428
|
-
}, null, 8, ["modelValue", "nodes", "expanded", "expand-label"])) :
|
|
429
|
-
], 8,
|
|
430
|
-
|
|
431
|
-
e(
|
|
419
|
+
modelValue: w.value,
|
|
420
|
+
"onUpdate:modelValue": P[4] || (P[4] = (I) => w.value = I),
|
|
421
|
+
nodes: r.value,
|
|
422
|
+
"onUpdate:nodes": P[5] || (P[5] = (I) => r.value = I),
|
|
423
|
+
expanded: c.value,
|
|
424
|
+
"onUpdate:expanded": P[6] || (P[6] = (I) => c.value = I),
|
|
425
|
+
"load-children": J,
|
|
426
|
+
"expand-label": (I, p) => e(Ae)(p ? o.value.collapse : o.value.expand, { name: I.label }),
|
|
427
|
+
onSelect: P[7] || (P[7] = (I) => me(G(r.value, I.id) ?? [I.data]))
|
|
428
|
+
}, null, 8, ["modelValue", "nodes", "expanded", "expand-label"])) : h("", !0)
|
|
429
|
+
], 8, Ja),
|
|
430
|
+
$("div", Xa, [
|
|
431
|
+
e(n) ? h("", !0) : (s(), x(e(wa), {
|
|
432
432
|
key: 0,
|
|
433
|
-
columns:
|
|
434
|
-
rows:
|
|
433
|
+
columns: W.value,
|
|
434
|
+
rows: u.value.map((I) => ({ ...I, kind: I.isDir ? o.value.directoryKind : o.value.fileKind })),
|
|
435
435
|
"row-key": "path",
|
|
436
436
|
footer: !1,
|
|
437
437
|
resizable: !1,
|
|
438
438
|
"local-sort": !1,
|
|
439
439
|
"local-pagination": !1,
|
|
440
|
-
loading: e(
|
|
441
|
-
"loading-text":
|
|
442
|
-
sort: { key:
|
|
443
|
-
labels: { empty:
|
|
440
|
+
loading: e(i),
|
|
441
|
+
"loading-text": o.value.loading,
|
|
442
|
+
sort: { key: z.value.key === "size" ? "bytes" : z.value.key, direction: z.value.direction },
|
|
443
|
+
labels: { empty: o.value.emptyFolder },
|
|
444
444
|
"single-select": "",
|
|
445
|
-
"selected-keys":
|
|
446
|
-
"onUpdate:sort":
|
|
447
|
-
"onUpdate:selectedKeys":
|
|
448
|
-
e(
|
|
445
|
+
"selected-keys": D.value ? [D.value] : [],
|
|
446
|
+
"onUpdate:sort": ee,
|
|
447
|
+
"onUpdate:selectedKeys": P[8] || (P[8] = (I) => {
|
|
448
|
+
e(i) || se(Y(I[0]));
|
|
449
449
|
}),
|
|
450
|
-
onRowActivate:
|
|
451
|
-
e(
|
|
450
|
+
onRowActivate: P[9] || (P[9] = (I) => {
|
|
451
|
+
e(i) || Q(Y(I.path));
|
|
452
452
|
}),
|
|
453
|
-
onRowDblclick:
|
|
454
|
-
e(
|
|
453
|
+
onRowDblclick: P[10] || (P[10] = (I) => {
|
|
454
|
+
e(i) || Q(Y(I.path));
|
|
455
455
|
})
|
|
456
456
|
}, {
|
|
457
|
-
"cell-name":
|
|
458
|
-
|
|
459
|
-
|
|
460
|
-
kind:
|
|
461
|
-
name:
|
|
457
|
+
"cell-name": l(({ row: I }) => [
|
|
458
|
+
$("span", Qa, [
|
|
459
|
+
d(e(Ee), {
|
|
460
|
+
kind: I.isDir ? "folder" : "file",
|
|
461
|
+
name: I.name
|
|
462
462
|
}, null, 8, ["kind", "name"]),
|
|
463
|
-
g(
|
|
463
|
+
g(t(I.name), 1)
|
|
464
464
|
])
|
|
465
465
|
]),
|
|
466
|
-
empty:
|
|
467
|
-
|
|
468
|
-
|
|
466
|
+
empty: l(() => [
|
|
467
|
+
$("div", Ya, [
|
|
468
|
+
d(e(Ee), {
|
|
469
469
|
kind: "folder",
|
|
470
470
|
size: [40, 40]
|
|
471
471
|
}),
|
|
472
|
-
|
|
472
|
+
$("span", null, t(o.value.emptyFolder), 1)
|
|
473
473
|
])
|
|
474
474
|
]),
|
|
475
|
-
"cell-bytes":
|
|
476
|
-
|
|
475
|
+
"cell-bytes": l(({ row: I }) => [
|
|
476
|
+
$("span", Za, t(I.isDir || I.bytes === void 0 ? "—" : e(Re)(I.bytes, e(ta)(y.locale))), 1)
|
|
477
477
|
]),
|
|
478
478
|
_: 1
|
|
479
479
|
}, 8, ["columns", "rows", "loading", "loading-text", "sort", "labels", "selected-keys"])),
|
|
480
|
-
|
|
480
|
+
S.value !== void 0 && !e(n) ? (s(), x(e(U), {
|
|
481
481
|
key: 1,
|
|
482
482
|
variant: "secondary",
|
|
483
|
-
disabled: e(
|
|
484
|
-
onClick:
|
|
483
|
+
disabled: e(i),
|
|
484
|
+
onClick: P[11] || (P[11] = (I) => re(v.value, !0))
|
|
485
485
|
}, {
|
|
486
|
-
default:
|
|
487
|
-
g(
|
|
486
|
+
default: l(() => [
|
|
487
|
+
g(t(o.value.loadMore), 1)
|
|
488
488
|
]),
|
|
489
489
|
_: 1
|
|
490
|
-
}, 8, ["disabled"])) :
|
|
490
|
+
}, 8, ["disabled"])) : h("", !0)
|
|
491
491
|
])
|
|
492
492
|
]),
|
|
493
|
-
|
|
494
|
-
], 8,
|
|
493
|
+
k.value && !e(n) ? (s(), V("p", Wa, t(e(Ae)(o.value.selected, { name: k.value.path })), 1)) : h("", !0)
|
|
494
|
+
], 8, Fa));
|
|
495
495
|
}
|
|
496
|
-
}),
|
|
496
|
+
}), je = /* @__PURE__ */ ue(ja, [["__scopeId", "data-v-c689761c"]]), et = {
|
|
497
497
|
key: 0,
|
|
498
498
|
class: "save-consent"
|
|
499
|
-
},
|
|
499
|
+
}, at = ["aria-busy", "inert"], tt = /* @__PURE__ */ oe({
|
|
500
500
|
__name: "NasPicker",
|
|
501
501
|
props: {
|
|
502
502
|
open: { type: Boolean },
|
|
@@ -505,537 +505,565 @@ const za = ["aria-busy", "aria-label"], Pa = { class: "file-toolbar file-locatio
|
|
|
505
505
|
mode: {},
|
|
506
506
|
title: {},
|
|
507
507
|
description: {},
|
|
508
|
-
destination: {}
|
|
508
|
+
destination: {},
|
|
509
|
+
errorText: { type: Function }
|
|
509
510
|
},
|
|
510
|
-
emits: ["update:open", "selected", "authorized"],
|
|
511
|
-
setup(
|
|
512
|
-
const
|
|
513
|
-
let
|
|
514
|
-
|
|
515
|
-
|
|
516
|
-
}),
|
|
517
|
-
v = !0,
|
|
511
|
+
emits: ["update:open", "selected", "authorized", "refused"],
|
|
512
|
+
setup(y, { emit: q }) {
|
|
513
|
+
const f = y, a = q, o = b(), m = L(() => be(f.locale)), i = L(() => Ne(f.locale)), n = b(!1), u = b();
|
|
514
|
+
let r = 0, v = !1;
|
|
515
|
+
Je(() => f.open, () => {
|
|
516
|
+
r++, o.value = void 0, u.value = void 0;
|
|
517
|
+
}), ye(() => {
|
|
518
|
+
v = !0, r++;
|
|
518
519
|
});
|
|
519
|
-
function
|
|
520
|
-
|
|
520
|
+
function k() {
|
|
521
|
+
n.value || (o.value = void 0, a("update:open", !1));
|
|
521
522
|
}
|
|
522
|
-
async function
|
|
523
|
-
const
|
|
524
|
-
if (!(!
|
|
525
|
-
if (!
|
|
526
|
-
|
|
523
|
+
async function D() {
|
|
524
|
+
const S = o.value, c = f.destination, w = r;
|
|
525
|
+
if (!(!S || n.value || !f.open || v || c && f.mode !== "folder")) {
|
|
526
|
+
if (!c) {
|
|
527
|
+
a("selected", S), k();
|
|
527
528
|
return;
|
|
528
529
|
}
|
|
529
|
-
|
|
530
|
+
n.value = !0, u.value = void 0;
|
|
530
531
|
try {
|
|
531
|
-
const
|
|
532
|
-
if (v ||
|
|
533
|
-
if (!
|
|
534
|
-
|
|
535
|
-
} catch (
|
|
536
|
-
|
|
532
|
+
const z = await c.selectDestination({ key: c.key, path: S });
|
|
533
|
+
if (v || w !== r) return;
|
|
534
|
+
if (!z || typeof z.id != "string" || !z.id || typeof z.username != "string" || !z.username || z.path !== S || z.key !== c.key || z.lifetime !== "until-revoked") throw { code: "commit-uncertain" };
|
|
535
|
+
a("authorized", z), n.value = !1, k();
|
|
536
|
+
} catch (z) {
|
|
537
|
+
if (v || w !== r) return;
|
|
538
|
+
if (z?.code === "APP_DENIED") {
|
|
539
|
+
n.value = !1, a("refused", z), k();
|
|
540
|
+
return;
|
|
541
|
+
}
|
|
542
|
+
u.value = z;
|
|
537
543
|
} finally {
|
|
538
|
-
v || (
|
|
544
|
+
v || (n.value = !1);
|
|
539
545
|
}
|
|
540
546
|
}
|
|
541
547
|
}
|
|
542
|
-
return (
|
|
543
|
-
open:
|
|
544
|
-
title:
|
|
545
|
-
description:
|
|
546
|
-
"close-label":
|
|
547
|
-
"show-close": !
|
|
548
|
+
return (S, c) => (s(), x(e(qe), {
|
|
549
|
+
open: y.open,
|
|
550
|
+
title: y.title ?? (y.mode === "folder" ? m.value.choose : m.value.chooseFile),
|
|
551
|
+
description: y.description ?? m.value.ownPermissions,
|
|
552
|
+
"close-label": m.value.close,
|
|
553
|
+
"show-close": !n.value,
|
|
548
554
|
width: "800px",
|
|
549
|
-
onEscapeKeyDown:
|
|
550
|
-
|
|
555
|
+
onEscapeKeyDown: c[1] || (c[1] = (w) => {
|
|
556
|
+
n.value && w.preventDefault();
|
|
551
557
|
}),
|
|
552
|
-
onInteractOutside:
|
|
553
|
-
|
|
558
|
+
onInteractOutside: c[2] || (c[2] = (w) => {
|
|
559
|
+
n.value && w.preventDefault();
|
|
554
560
|
}),
|
|
555
|
-
"onUpdate:open":
|
|
556
|
-
|
|
561
|
+
"onUpdate:open": c[3] || (c[3] = (w) => {
|
|
562
|
+
w || k();
|
|
557
563
|
})
|
|
558
564
|
}, {
|
|
559
|
-
footer:
|
|
560
|
-
|
|
565
|
+
footer: l(() => [
|
|
566
|
+
d(e(U), {
|
|
561
567
|
variant: "secondary",
|
|
562
|
-
disabled:
|
|
563
|
-
onClick:
|
|
568
|
+
disabled: n.value,
|
|
569
|
+
onClick: k
|
|
564
570
|
}, {
|
|
565
|
-
default:
|
|
566
|
-
g(
|
|
571
|
+
default: l(() => [
|
|
572
|
+
g(t(m.value.cancel), 1)
|
|
567
573
|
]),
|
|
568
574
|
_: 1
|
|
569
575
|
}, 8, ["disabled"]),
|
|
570
|
-
|
|
576
|
+
d(e(U), {
|
|
571
577
|
variant: "primary",
|
|
572
|
-
disabled: !
|
|
573
|
-
onClick:
|
|
578
|
+
disabled: !o.value || n.value || !!y.destination && y.mode !== "folder",
|
|
579
|
+
onClick: D
|
|
574
580
|
}, {
|
|
575
|
-
default:
|
|
576
|
-
g(
|
|
581
|
+
default: l(() => [
|
|
582
|
+
g(t(m.value.confirm), 1)
|
|
577
583
|
]),
|
|
578
584
|
_: 1
|
|
579
585
|
}, 8, ["disabled"])
|
|
580
586
|
]),
|
|
581
|
-
default:
|
|
582
|
-
|
|
583
|
-
|
|
587
|
+
default: l(() => [
|
|
588
|
+
y.destination ? (s(), V("p", et, t(i.value.selection), 1)) : h("", !0),
|
|
589
|
+
u.value ? (s(), x(e(X), {
|
|
584
590
|
key: 1,
|
|
585
591
|
tone: "danger",
|
|
586
592
|
role: "alert",
|
|
587
593
|
class: "save-message"
|
|
588
594
|
}, {
|
|
589
|
-
default:
|
|
590
|
-
g(
|
|
595
|
+
default: l(() => [
|
|
596
|
+
g(t(y.errorText?.(u.value) ?? e(Ie)(u.value, i.value, "select")), 1)
|
|
591
597
|
]),
|
|
592
598
|
_: 1
|
|
593
|
-
})) :
|
|
594
|
-
|
|
599
|
+
})) : h("", !0),
|
|
600
|
+
$("div", {
|
|
595
601
|
class: "nas-picker-content",
|
|
596
|
-
"aria-busy":
|
|
597
|
-
inert:
|
|
602
|
+
"aria-busy": n.value,
|
|
603
|
+
inert: n.value
|
|
598
604
|
}, [
|
|
599
|
-
|
|
605
|
+
y.open ? (s(), x(je, {
|
|
600
606
|
key: 0,
|
|
601
|
-
provider:
|
|
602
|
-
locale:
|
|
603
|
-
mode:
|
|
604
|
-
onSelected:
|
|
605
|
-
}, null, 8, ["provider", "locale", "mode"])) :
|
|
606
|
-
], 8,
|
|
607
|
+
provider: y.provider,
|
|
608
|
+
locale: y.locale,
|
|
609
|
+
mode: y.mode,
|
|
610
|
+
onSelected: c[0] || (c[0] = (w) => o.value = w)
|
|
611
|
+
}, null, 8, ["provider", "locale", "mode"])) : h("", !0)
|
|
612
|
+
], 8, at)
|
|
607
613
|
]),
|
|
608
614
|
_: 1
|
|
609
615
|
}, 8, ["open", "title", "description", "close-label", "show-close"]));
|
|
610
616
|
}
|
|
611
|
-
}),
|
|
617
|
+
}), Te = /* @__PURE__ */ ue(tt, [["__scopeId", "data-v-6ed8b8f6"]]), lt = { role: "alert" }, st = { class: "files-actions" }, nt = {
|
|
612
618
|
key: 0,
|
|
613
619
|
class: "files-path",
|
|
614
620
|
role: "status"
|
|
615
|
-
},
|
|
621
|
+
}, it = /* @__PURE__ */ oe({
|
|
616
622
|
__name: "FilesPage",
|
|
617
623
|
props: {
|
|
618
624
|
ctx: {}
|
|
619
625
|
},
|
|
620
|
-
setup(
|
|
621
|
-
const
|
|
622
|
-
let
|
|
623
|
-
async function
|
|
624
|
-
if (!
|
|
625
|
-
|
|
626
|
+
setup(y) {
|
|
627
|
+
const q = y, f = b(), a = b(!1), o = b("folder"), m = b(!1), i = b(""), n = b(0), u = Me(q.ctx);
|
|
628
|
+
let r = !1, v;
|
|
629
|
+
async function k() {
|
|
630
|
+
if (!r) {
|
|
631
|
+
f.value = void 0, a.value = !1, i.value = "", m.value = !1, n.value++;
|
|
626
632
|
try {
|
|
627
|
-
await
|
|
628
|
-
} catch (
|
|
629
|
-
!
|
|
633
|
+
await q.ctx.call("nas.session.status"), r || (a.value = !0);
|
|
634
|
+
} catch (D) {
|
|
635
|
+
!r && D?.code !== "unknown_method" && (f.value = D);
|
|
630
636
|
}
|
|
631
637
|
}
|
|
632
638
|
}
|
|
633
|
-
return
|
|
634
|
-
v =
|
|
635
|
-
|
|
636
|
-
}),
|
|
637
|
-
}),
|
|
638
|
-
|
|
639
|
-
}), (
|
|
640
|
-
|
|
639
|
+
return ge(() => {
|
|
640
|
+
v = q.ctx.reopen(() => {
|
|
641
|
+
k();
|
|
642
|
+
}), k();
|
|
643
|
+
}), ye(() => {
|
|
644
|
+
r = !0, v?.(), u.dispose();
|
|
645
|
+
}), (D, S) => (s(), V(ne, null, [
|
|
646
|
+
f.value ? (s(), x(e(X), {
|
|
641
647
|
key: 0,
|
|
642
648
|
tone: "danger"
|
|
643
649
|
}, {
|
|
644
|
-
default:
|
|
645
|
-
|
|
646
|
-
|
|
650
|
+
default: l(() => [
|
|
651
|
+
$("span", lt, t(e(Le)(f.value, e(be)(y.ctx.locale))), 1),
|
|
652
|
+
d(e(U), {
|
|
647
653
|
variant: "secondary",
|
|
648
|
-
onClick:
|
|
654
|
+
onClick: k
|
|
649
655
|
}, {
|
|
650
|
-
default:
|
|
651
|
-
g(
|
|
656
|
+
default: l(() => [
|
|
657
|
+
g(t(e(be)(y.ctx.locale).refresh), 1)
|
|
652
658
|
]),
|
|
653
659
|
_: 1
|
|
654
660
|
})
|
|
655
661
|
]),
|
|
656
662
|
_: 1
|
|
657
|
-
})) :
|
|
658
|
-
|
|
663
|
+
})) : h("", !0),
|
|
664
|
+
a.value ? (s(), x(e(he), {
|
|
659
665
|
key: 1,
|
|
660
|
-
title: e(
|
|
666
|
+
title: e(be)(y.ctx.locale).title,
|
|
667
|
+
description: e(be)(y.ctx.locale).ownPermissions,
|
|
661
668
|
collapsible: !1
|
|
662
669
|
}, {
|
|
663
|
-
default:
|
|
664
|
-
|
|
665
|
-
|
|
666
|
-
h(e(A), {
|
|
670
|
+
default: l(() => [
|
|
671
|
+
$("div", st, [
|
|
672
|
+
d(e(U), {
|
|
667
673
|
variant: "secondary",
|
|
668
|
-
onClick:
|
|
669
|
-
|
|
674
|
+
onClick: S[0] || (S[0] = (c) => {
|
|
675
|
+
o.value = "folder", m.value = !0;
|
|
670
676
|
})
|
|
671
677
|
}, {
|
|
672
|
-
default:
|
|
673
|
-
g(
|
|
678
|
+
default: l(() => [
|
|
679
|
+
g(t(e(be)(y.ctx.locale).choose), 1)
|
|
674
680
|
]),
|
|
675
681
|
_: 1
|
|
676
682
|
}),
|
|
677
|
-
|
|
683
|
+
d(e(U), {
|
|
678
684
|
variant: "secondary",
|
|
679
|
-
onClick:
|
|
680
|
-
|
|
685
|
+
onClick: S[1] || (S[1] = (c) => {
|
|
686
|
+
o.value = "file", m.value = !0;
|
|
681
687
|
})
|
|
682
688
|
}, {
|
|
683
|
-
default:
|
|
684
|
-
g(
|
|
689
|
+
default: l(() => [
|
|
690
|
+
g(t(e(be)(y.ctx.locale).chooseFile), 1)
|
|
685
691
|
]),
|
|
686
692
|
_: 1
|
|
687
693
|
})
|
|
688
694
|
]),
|
|
689
|
-
|
|
690
|
-
|
|
691
|
-
|
|
692
|
-
|
|
693
|
-
|
|
695
|
+
i.value ? (s(), V("p", nt, [
|
|
696
|
+
d(e(pe), { path: i.value }, null, 8, ["path"])
|
|
697
|
+
])) : h("", !0),
|
|
698
|
+
(s(), x(je, {
|
|
699
|
+
key: n.value,
|
|
700
|
+
provider: e(u),
|
|
701
|
+
locale: y.ctx.locale,
|
|
694
702
|
transfers: ""
|
|
695
703
|
}, null, 8, ["provider", "locale"])),
|
|
696
|
-
|
|
697
|
-
provider: e(
|
|
698
|
-
locale:
|
|
699
|
-
mode:
|
|
700
|
-
open:
|
|
701
|
-
"onUpdate:open":
|
|
702
|
-
onSelected:
|
|
704
|
+
d(Te, {
|
|
705
|
+
provider: e(u),
|
|
706
|
+
locale: y.ctx.locale,
|
|
707
|
+
mode: o.value,
|
|
708
|
+
open: m.value,
|
|
709
|
+
"onUpdate:open": S[2] || (S[2] = (c) => m.value = c),
|
|
710
|
+
onSelected: S[3] || (S[3] = (c) => i.value = c)
|
|
703
711
|
}, null, 8, ["provider", "locale", "mode", "open"])
|
|
704
712
|
]),
|
|
705
713
|
_: 1
|
|
706
|
-
}, 8, ["title"])) :
|
|
714
|
+
}, 8, ["title", "description"])) : h("", !0)
|
|
707
715
|
], 64));
|
|
708
716
|
}
|
|
709
|
-
}),
|
|
717
|
+
}), Hl = /* @__PURE__ */ ue(it, [["__scopeId", "data-v-15f9eb8e"]]), ot = { key: 0 }, ut = { key: 1 }, rt = { key: 0 }, dt = { key: 3 }, vt = { role: "alert" }, ct = 5e3, pt = /* @__PURE__ */ oe({
|
|
710
718
|
__name: "PortalSettings",
|
|
711
719
|
props: {
|
|
712
720
|
portal: {}
|
|
713
721
|
},
|
|
714
|
-
setup(
|
|
715
|
-
const
|
|
716
|
-
let
|
|
717
|
-
function r(
|
|
718
|
-
|
|
722
|
+
setup(y) {
|
|
723
|
+
const q = y, f = We(), a = q.portal.messages, o = b(), m = b(""), i = b(!1), n = b("");
|
|
724
|
+
let u = !1;
|
|
725
|
+
function r(S) {
|
|
726
|
+
u || (o.value = S, m.value = S.alias || S.defaultAlias);
|
|
719
727
|
}
|
|
720
|
-
const
|
|
721
|
-
async function
|
|
722
|
-
if (
|
|
723
|
-
|
|
724
|
-
const
|
|
728
|
+
const v = /* @__PURE__ */ Symbol("late");
|
|
729
|
+
async function k(S) {
|
|
730
|
+
if (i.value) return;
|
|
731
|
+
i.value = !0, n.value = "";
|
|
732
|
+
const c = S();
|
|
725
733
|
try {
|
|
726
|
-
const
|
|
727
|
-
if (
|
|
728
|
-
r(
|
|
734
|
+
const w = await Promise.race([c, new Promise((z) => setTimeout(() => z(v), ct))]);
|
|
735
|
+
if (w !== v) {
|
|
736
|
+
r(w);
|
|
729
737
|
return;
|
|
730
738
|
}
|
|
731
|
-
|
|
732
|
-
|
|
733
|
-
|
|
734
|
-
|
|
739
|
+
r(await q.portal.status());
|
|
740
|
+
try {
|
|
741
|
+
await c;
|
|
742
|
+
} finally {
|
|
743
|
+
r(await q.portal.status());
|
|
744
|
+
}
|
|
745
|
+
} catch (w) {
|
|
746
|
+
u || (n.value = a[w?.code || ""] || a.portal_unavailable);
|
|
735
747
|
} finally {
|
|
736
|
-
|
|
748
|
+
u || (i.value = !1);
|
|
737
749
|
}
|
|
738
750
|
}
|
|
739
|
-
|
|
740
|
-
|
|
741
|
-
|
|
742
|
-
|
|
743
|
-
|
|
751
|
+
function D() {
|
|
752
|
+
i.value || q.portal.status().then(r, () => {
|
|
753
|
+
});
|
|
754
|
+
}
|
|
755
|
+
return ge(() => {
|
|
756
|
+
f.subscribe?.(D), D();
|
|
757
|
+
}), ye(() => {
|
|
758
|
+
u = !0;
|
|
759
|
+
}), (S, c) => o.value ? (s(), x(e(he), {
|
|
744
760
|
key: 0,
|
|
745
761
|
title: e(a).title,
|
|
746
762
|
collapsible: !1,
|
|
747
|
-
"aria-busy":
|
|
748
|
-
}, {
|
|
749
|
-
default:
|
|
750
|
-
|
|
751
|
-
g(
|
|
752
|
-
|
|
753
|
-
href:
|
|
763
|
+
"aria-busy": i.value
|
|
764
|
+
}, Xe({
|
|
765
|
+
default: l(() => [
|
|
766
|
+
o.value.state === "active" ? (s(), V("p", ot, [
|
|
767
|
+
g(t(e(a).link) + " ", 1),
|
|
768
|
+
d(e(Ye), {
|
|
769
|
+
href: o.value.url,
|
|
754
770
|
external: ""
|
|
755
771
|
}, {
|
|
756
|
-
default:
|
|
757
|
-
g(
|
|
772
|
+
default: l(() => [
|
|
773
|
+
g(t(o.value.url), 1)
|
|
758
774
|
]),
|
|
759
775
|
_: 1
|
|
760
776
|
}, 8, ["href"])
|
|
761
|
-
])) :
|
|
762
|
-
|
|
763
|
-
|
|
764
|
-
|
|
765
|
-
|
|
766
|
-
|
|
767
|
-
|
|
768
|
-
onClick: z[0] || (z[0] = (x) => v(() => p.portal.register()))
|
|
777
|
+
])) : h("", !0),
|
|
778
|
+
o.value.canManage && o.value.entry && o.value.entry !== "registered" ? (s(), V("p", ut, t(o.value.entry === "unregistered" ? e(a).entryOff : e(a).cleanupRequired), 1)) : o.value.canManage ? (s(), V(ne, { key: 2 }, [
|
|
779
|
+
o.value.state !== "active" ? (s(), V("p", rt, t(e(a).inactive), 1)) : h("", !0),
|
|
780
|
+
d(e(ze), {
|
|
781
|
+
direction: "vertical",
|
|
782
|
+
class: "portal-form",
|
|
783
|
+
onSubmit: c[4] || (c[4] = Se((w) => k(() => y.portal.apply(m.value)), ["prevent"]))
|
|
769
784
|
}, {
|
|
770
|
-
default:
|
|
771
|
-
|
|
772
|
-
]),
|
|
773
|
-
_: 1
|
|
774
|
-
}, 8, ["disabled"])) : (t(), $(e(A), {
|
|
775
|
-
key: 1,
|
|
776
|
-
variant: "primary",
|
|
777
|
-
disabled: d.value,
|
|
778
|
-
onClick: z[1] || (z[1] = (x) => v(() => p.portal.unregister()))
|
|
779
|
-
}, {
|
|
780
|
-
default: n(() => [
|
|
781
|
-
g(l(e(a).unregister), 1)
|
|
782
|
-
]),
|
|
783
|
-
_: 1
|
|
784
|
-
}, 8, ["disabled"]))
|
|
785
|
-
], 64)) : m.value.canManage ? (t(), S(Z, { key: 2 }, [
|
|
786
|
-
m.value.state !== "active" ? (t(), S("p", Ya, l(e(a).inactive), 1)) : k("", !0),
|
|
787
|
-
h(e(be), {
|
|
788
|
-
onSubmit: z[4] || (z[4] = me((x) => v(() => p.portal.apply(i.value)), ["prevent"]))
|
|
789
|
-
}, {
|
|
790
|
-
default: n(() => [
|
|
791
|
-
h(e(oe), {
|
|
785
|
+
default: l(() => [
|
|
786
|
+
d(e(fe), {
|
|
792
787
|
label: e(a).alias,
|
|
793
788
|
"label-for": "portal-alias"
|
|
794
789
|
}, {
|
|
795
|
-
default:
|
|
796
|
-
|
|
790
|
+
default: l(() => [
|
|
791
|
+
d(e(_e), {
|
|
797
792
|
id: "portal-alias",
|
|
798
|
-
modelValue:
|
|
799
|
-
"onUpdate:modelValue":
|
|
793
|
+
modelValue: m.value,
|
|
794
|
+
"onUpdate:modelValue": c[0] || (c[0] = (w) => m.value = w),
|
|
800
795
|
maxlength: "64",
|
|
801
796
|
autocomplete: "off",
|
|
802
|
-
disabled:
|
|
797
|
+
disabled: i.value
|
|
803
798
|
}, null, 8, ["modelValue", "disabled"])
|
|
804
799
|
]),
|
|
805
800
|
_: 1
|
|
806
801
|
}, 8, ["label"]),
|
|
807
|
-
|
|
808
|
-
default:
|
|
809
|
-
|
|
802
|
+
d(e(Pe), null, {
|
|
803
|
+
default: l(() => [
|
|
804
|
+
d(e(U), {
|
|
810
805
|
type: "submit",
|
|
811
806
|
variant: "primary",
|
|
812
|
-
disabled:
|
|
807
|
+
disabled: i.value
|
|
813
808
|
}, {
|
|
814
|
-
default:
|
|
815
|
-
g(
|
|
809
|
+
default: l(() => [
|
|
810
|
+
g(t(e(a).apply), 1)
|
|
816
811
|
]),
|
|
817
812
|
_: 1
|
|
818
813
|
}, 8, ["disabled"]),
|
|
819
|
-
|
|
814
|
+
o.value.state === "active" ? (s(), x(e(U), {
|
|
820
815
|
key: 0,
|
|
821
816
|
variant: "secondary",
|
|
822
|
-
disabled:
|
|
823
|
-
onClick:
|
|
817
|
+
disabled: i.value,
|
|
818
|
+
onClick: c[1] || (c[1] = (w) => k(() => y.portal.disable()))
|
|
824
819
|
}, {
|
|
825
|
-
default:
|
|
826
|
-
g(
|
|
820
|
+
default: l(() => [
|
|
821
|
+
g(t(e(a).disable), 1)
|
|
827
822
|
]),
|
|
828
823
|
_: 1
|
|
829
|
-
}, 8, ["disabled"])) :
|
|
824
|
+
}, 8, ["disabled"])) : h("", !0),
|
|
825
|
+
d(e(U), {
|
|
826
|
+
variant: "secondary",
|
|
827
|
+
onClick: c[2] || (c[2] = (w) => y.portal.openControlPanel())
|
|
828
|
+
}, {
|
|
829
|
+
default: l(() => [
|
|
830
|
+
g(t(e(a).advanced), 1)
|
|
831
|
+
]),
|
|
832
|
+
_: 1
|
|
833
|
+
}),
|
|
834
|
+
o.value.entry ? (s(), x(e(U), {
|
|
835
|
+
key: 1,
|
|
836
|
+
variant: "secondary",
|
|
837
|
+
disabled: i.value,
|
|
838
|
+
onClick: c[3] || (c[3] = (w) => k(() => y.portal.unregister()))
|
|
839
|
+
}, {
|
|
840
|
+
default: l(() => [
|
|
841
|
+
g(t(e(a).unregister), 1)
|
|
842
|
+
]),
|
|
843
|
+
_: 1
|
|
844
|
+
}, 8, ["disabled"])) : h("", !0)
|
|
830
845
|
]),
|
|
831
846
|
_: 1
|
|
832
847
|
})
|
|
833
848
|
]),
|
|
834
849
|
_: 1
|
|
835
|
-
})
|
|
836
|
-
|
|
837
|
-
|
|
838
|
-
|
|
850
|
+
})
|
|
851
|
+
], 64)) : !o.value.controlPanel && o.value.state !== "active" ? (s(), V("p", dt, t(e(a).askAdmin), 1)) : h("", !0),
|
|
852
|
+
n.value ? (s(), x(e(X), {
|
|
853
|
+
key: 4,
|
|
854
|
+
tone: "danger"
|
|
855
|
+
}, {
|
|
856
|
+
default: l(() => [
|
|
857
|
+
$("span", vt, t(n.value), 1)
|
|
858
|
+
]),
|
|
859
|
+
_: 1
|
|
860
|
+
})) : h("", !0)
|
|
861
|
+
]),
|
|
862
|
+
_: 2
|
|
863
|
+
}, [
|
|
864
|
+
o.value?.canManage && o.value.entry && o.value.entry !== "registered" ? {
|
|
865
|
+
name: "footer",
|
|
866
|
+
fn: l(() => [
|
|
867
|
+
o.value.entry === "unregistered" ? (s(), x(e(U), {
|
|
868
|
+
key: 0,
|
|
869
|
+
variant: "primary",
|
|
870
|
+
disabled: i.value,
|
|
871
|
+
onClick: c[5] || (c[5] = (w) => k(() => y.portal.register()))
|
|
839
872
|
}, {
|
|
840
|
-
default:
|
|
841
|
-
g(
|
|
873
|
+
default: l(() => [
|
|
874
|
+
g(t(e(a).register), 1)
|
|
842
875
|
]),
|
|
843
876
|
_: 1
|
|
844
|
-
}),
|
|
845
|
-
m.value.entry ? (t(), $(e(A), {
|
|
877
|
+
}, 8, ["disabled"])) : (s(), x(e(U), {
|
|
846
878
|
key: 1,
|
|
879
|
+
variant: "primary",
|
|
880
|
+
disabled: i.value,
|
|
881
|
+
onClick: c[6] || (c[6] = (w) => k(() => y.portal.unregister()))
|
|
882
|
+
}, {
|
|
883
|
+
default: l(() => [
|
|
884
|
+
g(t(e(a).unregister), 1)
|
|
885
|
+
]),
|
|
886
|
+
_: 1
|
|
887
|
+
}, 8, ["disabled"]))
|
|
888
|
+
]),
|
|
889
|
+
key: "0"
|
|
890
|
+
} : o.value && !o.value.canManage && o.value.controlPanel ? {
|
|
891
|
+
name: "footer",
|
|
892
|
+
fn: l(() => [
|
|
893
|
+
d(e(U), {
|
|
847
894
|
variant: "secondary",
|
|
848
|
-
|
|
849
|
-
onClick: z[6] || (z[6] = (x) => v(() => p.portal.unregister()))
|
|
895
|
+
onClick: c[7] || (c[7] = (w) => y.portal.openControlPanel())
|
|
850
896
|
}, {
|
|
851
|
-
default:
|
|
852
|
-
g(
|
|
897
|
+
default: l(() => [
|
|
898
|
+
g(t(e(a).controlPanel), 1)
|
|
853
899
|
]),
|
|
854
900
|
_: 1
|
|
855
|
-
}
|
|
856
|
-
]
|
|
857
|
-
|
|
858
|
-
|
|
859
|
-
|
|
860
|
-
}, {
|
|
861
|
-
default: n(() => [
|
|
862
|
-
g(l(e(a).controlPanel), 1)
|
|
863
|
-
]),
|
|
864
|
-
_: 1
|
|
865
|
-
})) : m.value.state !== "active" ? (t(), S("p", Wa, l(e(a).askAdmin), 1)) : k("", !0),
|
|
866
|
-
s.value ? (t(), $(e(Q), {
|
|
867
|
-
key: 5,
|
|
868
|
-
tone: "danger"
|
|
869
|
-
}, {
|
|
870
|
-
default: n(() => [
|
|
871
|
-
C("span", Za, l(s.value), 1)
|
|
872
|
-
]),
|
|
873
|
-
_: 1
|
|
874
|
-
})) : k("", !0)
|
|
875
|
-
]),
|
|
876
|
-
_: 1
|
|
877
|
-
}, 8, ["title", "aria-busy"])) : k("", !0);
|
|
901
|
+
})
|
|
902
|
+
]),
|
|
903
|
+
key: "1"
|
|
904
|
+
} : void 0
|
|
905
|
+
]), 1032, ["title", "aria-busy"])) : h("", !0);
|
|
878
906
|
}
|
|
879
|
-
}),
|
|
907
|
+
}), Gl = /* @__PURE__ */ ue(pt, [["__scopeId", "data-v-d803ac7c"]]), ft = ["aria-busy"], yt = {
|
|
880
908
|
key: 1,
|
|
881
909
|
role: "status"
|
|
882
|
-
},
|
|
910
|
+
}, mt = { role: "alert" }, bt = { role: "status" }, gt = /* @__PURE__ */ oe({
|
|
883
911
|
__name: "LoginPage",
|
|
884
912
|
props: {
|
|
885
913
|
session: {},
|
|
886
914
|
locale: {}
|
|
887
915
|
},
|
|
888
|
-
setup(
|
|
889
|
-
const
|
|
890
|
-
let
|
|
891
|
-
function z
|
|
892
|
-
const
|
|
893
|
-
return
|
|
916
|
+
setup(y) {
|
|
917
|
+
const q = y, f = L(() => la(q.locale)), a = b(""), o = b(""), m = b(""), i = b(!1), n = b(!1), u = b(""), r = b(), v = L(() => window.location.protocol === "https:");
|
|
918
|
+
let k = !1;
|
|
919
|
+
function D(z) {
|
|
920
|
+
const M = z?.code;
|
|
921
|
+
return f.value.errors[M || ""] || f.value.errors.failed;
|
|
894
922
|
}
|
|
895
|
-
async function
|
|
896
|
-
if (!(
|
|
897
|
-
|
|
923
|
+
async function S() {
|
|
924
|
+
if (!(n.value || !v.value || !a.value || !o.value || i.value && !m.value)) {
|
|
925
|
+
n.value = !0, u.value = "";
|
|
898
926
|
try {
|
|
899
|
-
await
|
|
900
|
-
} catch (
|
|
901
|
-
if (
|
|
902
|
-
|
|
927
|
+
await q.session.login(a.value, o.value, m.value), o.value = "", m.value = "";
|
|
928
|
+
} catch (z) {
|
|
929
|
+
if (k) return;
|
|
930
|
+
m.value = "", z?.code === "otp_required" ? i.value = !0 : (u.value = D(z), o.value = "", i.value = !1);
|
|
903
931
|
} finally {
|
|
904
|
-
|
|
932
|
+
k || (n.value = !1, i.value && (await pa(), k || r.value?.querySelector("input")?.focus()));
|
|
905
933
|
}
|
|
906
934
|
}
|
|
907
935
|
}
|
|
908
|
-
async function
|
|
909
|
-
if (!
|
|
910
|
-
|
|
936
|
+
async function c() {
|
|
937
|
+
if (!n.value) {
|
|
938
|
+
n.value = !0, u.value = "";
|
|
911
939
|
try {
|
|
912
|
-
await
|
|
913
|
-
} catch (
|
|
914
|
-
|
|
940
|
+
await q.session.bootstrap();
|
|
941
|
+
} catch (z) {
|
|
942
|
+
k || (u.value = D(z));
|
|
915
943
|
} finally {
|
|
916
|
-
|
|
944
|
+
k || (n.value = !1);
|
|
917
945
|
}
|
|
918
946
|
}
|
|
919
947
|
}
|
|
920
|
-
function
|
|
921
|
-
|
|
948
|
+
function w() {
|
|
949
|
+
o.value = "", m.value = "", i.value = !1, u.value = "";
|
|
922
950
|
}
|
|
923
|
-
return
|
|
924
|
-
|
|
925
|
-
}), (
|
|
951
|
+
return Qe(() => {
|
|
952
|
+
k = !0, o.value = "", m.value = "";
|
|
953
|
+
}), (z, M) => (s(), V("main", {
|
|
926
954
|
class: "identity-login",
|
|
927
|
-
"aria-busy":
|
|
955
|
+
"aria-busy": n.value
|
|
928
956
|
}, [
|
|
929
|
-
|
|
930
|
-
title:
|
|
957
|
+
d(e(he), {
|
|
958
|
+
title: f.value.title,
|
|
959
|
+
description: f.value.intro,
|
|
931
960
|
collapsible: !1
|
|
932
961
|
}, {
|
|
933
|
-
default:
|
|
934
|
-
|
|
935
|
-
v.value ? k("", !0) : (t(), $(e(Q), {
|
|
962
|
+
default: l(() => [
|
|
963
|
+
v.value ? h("", !0) : (s(), x(e(X), {
|
|
936
964
|
key: 0,
|
|
937
965
|
tone: "warning",
|
|
938
|
-
title:
|
|
966
|
+
title: f.value.httpsTitle
|
|
939
967
|
}, {
|
|
940
|
-
default:
|
|
941
|
-
g(
|
|
968
|
+
default: l(() => [
|
|
969
|
+
g(t(f.value.errors.https_required), 1)
|
|
942
970
|
]),
|
|
943
971
|
_: 1
|
|
944
972
|
}, 8, ["title"])),
|
|
945
|
-
|
|
946
|
-
|
|
973
|
+
y.session.notice.value ? (s(), V("p", yt, t(f.value.notices[y.session.notice.value]), 1)) : h("", !0),
|
|
974
|
+
u.value ? (s(), x(e(X), {
|
|
947
975
|
key: 2,
|
|
948
976
|
tone: "danger",
|
|
949
|
-
title:
|
|
977
|
+
title: f.value.failedTitle
|
|
950
978
|
}, {
|
|
951
|
-
default:
|
|
952
|
-
|
|
979
|
+
default: l(() => [
|
|
980
|
+
$("span", mt, t(u.value), 1)
|
|
953
981
|
]),
|
|
954
982
|
_: 1
|
|
955
|
-
}, 8, ["title"])) :
|
|
956
|
-
|
|
957
|
-
onSubmit:
|
|
983
|
+
}, 8, ["title"])) : h("", !0),
|
|
984
|
+
d(e(ze), {
|
|
985
|
+
onSubmit: Se(S, ["prevent"])
|
|
958
986
|
}, {
|
|
959
|
-
default:
|
|
960
|
-
|
|
961
|
-
label:
|
|
987
|
+
default: l(() => [
|
|
988
|
+
d(e(fe), {
|
|
989
|
+
label: f.value.account
|
|
962
990
|
}, {
|
|
963
|
-
default:
|
|
964
|
-
|
|
965
|
-
modelValue:
|
|
966
|
-
"onUpdate:modelValue":
|
|
991
|
+
default: l(() => [
|
|
992
|
+
d(e(_e), {
|
|
993
|
+
modelValue: a.value,
|
|
994
|
+
"onUpdate:modelValue": M[0] || (M[0] = (N) => a.value = N),
|
|
967
995
|
autocomplete: "username",
|
|
968
|
-
disabled:
|
|
996
|
+
disabled: n.value || i.value || !v.value
|
|
969
997
|
}, null, 8, ["modelValue", "disabled"])
|
|
970
998
|
]),
|
|
971
999
|
_: 1
|
|
972
1000
|
}, 8, ["label"]),
|
|
973
|
-
|
|
974
|
-
|
|
975
|
-
|
|
1001
|
+
i.value ? (s(), V(ne, { key: 1 }, [
|
|
1002
|
+
$("p", bt, t(f.value.otpPrompt), 1),
|
|
1003
|
+
$("div", {
|
|
976
1004
|
ref_key: "otpField",
|
|
977
|
-
ref:
|
|
1005
|
+
ref: r
|
|
978
1006
|
}, [
|
|
979
|
-
|
|
980
|
-
label:
|
|
1007
|
+
d(e(fe), {
|
|
1008
|
+
label: f.value.otp
|
|
981
1009
|
}, {
|
|
982
|
-
default:
|
|
983
|
-
|
|
984
|
-
modelValue:
|
|
985
|
-
"onUpdate:modelValue":
|
|
1010
|
+
default: l(() => [
|
|
1011
|
+
d(e(_e), {
|
|
1012
|
+
modelValue: m.value,
|
|
1013
|
+
"onUpdate:modelValue": M[2] || (M[2] = (N) => m.value = N),
|
|
986
1014
|
inputmode: "numeric",
|
|
987
1015
|
autocomplete: "one-time-code",
|
|
988
|
-
disabled:
|
|
1016
|
+
disabled: n.value
|
|
989
1017
|
}, null, 8, ["modelValue", "disabled"])
|
|
990
1018
|
]),
|
|
991
1019
|
_: 1
|
|
992
1020
|
}, 8, ["label"])
|
|
993
1021
|
], 512)
|
|
994
|
-
], 64)) : (
|
|
1022
|
+
], 64)) : (s(), x(e(fe), {
|
|
995
1023
|
key: 0,
|
|
996
|
-
label:
|
|
1024
|
+
label: f.value.password
|
|
997
1025
|
}, {
|
|
998
|
-
default:
|
|
999
|
-
|
|
1000
|
-
modelValue:
|
|
1001
|
-
"onUpdate:modelValue":
|
|
1026
|
+
default: l(() => [
|
|
1027
|
+
d(e(_e), {
|
|
1028
|
+
modelValue: o.value,
|
|
1029
|
+
"onUpdate:modelValue": M[1] || (M[1] = (N) => o.value = N),
|
|
1002
1030
|
type: "password",
|
|
1003
1031
|
autocomplete: "current-password",
|
|
1004
|
-
disabled:
|
|
1032
|
+
disabled: n.value || !v.value
|
|
1005
1033
|
}, null, 8, ["modelValue", "disabled"])
|
|
1006
1034
|
]),
|
|
1007
1035
|
_: 1
|
|
1008
1036
|
}, 8, ["label"])),
|
|
1009
|
-
|
|
1010
|
-
default:
|
|
1011
|
-
|
|
1037
|
+
d(e(Pe), null, {
|
|
1038
|
+
default: l(() => [
|
|
1039
|
+
d(e(U), {
|
|
1012
1040
|
type: "submit",
|
|
1013
1041
|
variant: "primary",
|
|
1014
|
-
disabled:
|
|
1042
|
+
disabled: n.value || !v.value || !a.value || !o.value || i.value && !m.value
|
|
1015
1043
|
}, {
|
|
1016
|
-
default:
|
|
1017
|
-
g(
|
|
1044
|
+
default: l(() => [
|
|
1045
|
+
g(t(n.value ? f.value.signingIn : i.value ? f.value.verify : f.value.signIn), 1)
|
|
1018
1046
|
]),
|
|
1019
1047
|
_: 1
|
|
1020
1048
|
}, 8, ["disabled"]),
|
|
1021
|
-
|
|
1049
|
+
i.value ? (s(), x(e(U), {
|
|
1022
1050
|
key: 0,
|
|
1023
1051
|
variant: "secondary",
|
|
1024
|
-
disabled:
|
|
1025
|
-
onClick:
|
|
1052
|
+
disabled: n.value,
|
|
1053
|
+
onClick: w
|
|
1026
1054
|
}, {
|
|
1027
|
-
default:
|
|
1028
|
-
g(
|
|
1055
|
+
default: l(() => [
|
|
1056
|
+
g(t(f.value.otherAccount), 1)
|
|
1029
1057
|
]),
|
|
1030
1058
|
_: 1
|
|
1031
|
-
}, 8, ["disabled"])) : (
|
|
1059
|
+
}, 8, ["disabled"])) : (s(), x(e(U), {
|
|
1032
1060
|
key: 1,
|
|
1033
1061
|
variant: "secondary",
|
|
1034
|
-
disabled:
|
|
1035
|
-
onClick:
|
|
1062
|
+
disabled: n.value || !v.value,
|
|
1063
|
+
onClick: c
|
|
1036
1064
|
}, {
|
|
1037
|
-
default:
|
|
1038
|
-
g(
|
|
1065
|
+
default: l(() => [
|
|
1066
|
+
g(t(f.value.continueDSM), 1)
|
|
1039
1067
|
]),
|
|
1040
1068
|
_: 1
|
|
1041
1069
|
}, 8, ["disabled"]))
|
|
@@ -1047,372 +1075,389 @@ const za = ["aria-busy", "aria-label"], Pa = { class: "file-toolbar file-locatio
|
|
|
1047
1075
|
})
|
|
1048
1076
|
]),
|
|
1049
1077
|
_: 1
|
|
1050
|
-
}, 8, ["title"])
|
|
1051
|
-
], 8,
|
|
1078
|
+
}, 8, ["title", "description"])
|
|
1079
|
+
], 8, ft));
|
|
1052
1080
|
}
|
|
1053
|
-
}),
|
|
1081
|
+
}), Jl = /* @__PURE__ */ ue(gt, [["__scopeId", "data-v-1c0358cd"]]), ht = { role: "status" }, kt = { class: "integration-help" }, _t = { class: "integration-help" }, wt = { class: "integration-help" }, xt = { class: "integration-actions" }, Ct = {
|
|
1054
1082
|
key: 0,
|
|
1055
1083
|
role: "status",
|
|
1056
|
-
"data-bg-picked": ""
|
|
1057
|
-
|
|
1058
|
-
|
|
1059
|
-
|
|
1060
|
-
|
|
1084
|
+
"data-bg-picked": "",
|
|
1085
|
+
class: "bg-path"
|
|
1086
|
+
}, $t = { class: "integration-actions" }, St = { key: 2 }, zt = {
|
|
1087
|
+
key: 3,
|
|
1088
|
+
class: "bg-cards"
|
|
1089
|
+
}, Pt = { class: "bg-card-body" }, Vt = {
|
|
1061
1090
|
key: 0,
|
|
1062
1091
|
class: "integration-help"
|
|
1063
|
-
},
|
|
1092
|
+
}, It = {
|
|
1064
1093
|
key: 1,
|
|
1065
1094
|
class: "integration-help"
|
|
1066
|
-
},
|
|
1095
|
+
}, Tt = {
|
|
1067
1096
|
key: 2,
|
|
1068
|
-
class: "integration-help"
|
|
1069
|
-
},
|
|
1097
|
+
class: "integration-help bg-path"
|
|
1098
|
+
}, Et = {
|
|
1070
1099
|
key: 3,
|
|
1071
1100
|
class: "integration-help"
|
|
1072
|
-
},
|
|
1073
|
-
key:
|
|
1101
|
+
}, Ut = {
|
|
1102
|
+
key: 4,
|
|
1074
1103
|
class: "integration-help"
|
|
1075
|
-
},
|
|
1104
|
+
}, At = { class: "integration-actions" }, Dt = ["aria-label"], Rt = { class: "integration-help" }, qt = { key: 1 }, Bt = {
|
|
1076
1105
|
key: 2,
|
|
1077
|
-
class: "
|
|
1078
|
-
},
|
|
1106
|
+
class: "bg-cards"
|
|
1107
|
+
}, Ft = { class: "bg-card-body" }, Ot = {
|
|
1079
1108
|
key: 0,
|
|
1080
1109
|
class: "integration-help"
|
|
1081
|
-
},
|
|
1110
|
+
}, Lt = {
|
|
1082
1111
|
key: 1,
|
|
1083
1112
|
class: "integration-help"
|
|
1084
|
-
},
|
|
1113
|
+
}, Nt = { class: "integration-help" }, Mt = { class: "integration-actions" }, Kt = { class: "integration-actions" }, Ht = { class: "integration-actions" }, Gt = /* @__PURE__ */ oe({
|
|
1085
1114
|
__name: "BackgroundPanel",
|
|
1086
1115
|
props: {
|
|
1087
1116
|
ctx: {}
|
|
1088
1117
|
},
|
|
1089
|
-
setup(
|
|
1090
|
-
const
|
|
1091
|
-
let
|
|
1092
|
-
const
|
|
1093
|
-
async function
|
|
1118
|
+
setup(y, { expose: q }) {
|
|
1119
|
+
const f = y, a = L(() => sa(f.ctx.locale)), o = (p, B) => Ae(p, B, f.ctx.locale), m = b(), i = b([]), n = b(), u = b(!1), r = b(!1), v = b([]), k = b(), D = b(!1), S = b("3600"), c = b(), w = b(), z = b(), M = b(!1), N = b(!1), K = b(), O = b(""), Z = b(""), ae = na(f.ctx);
|
|
1120
|
+
let W, H = !1;
|
|
1121
|
+
const j = (p) => !["queued", "running"].includes(p.state), te = (p) => j(p) && p.state !== "paused", se = (p) => p.state === "running" && p.pauseRequested, Q = (p) => se(p) ? a.value.pausing : a.value[`state_${p.state}`], Y = (p) => se(p) ? "warning" : { queued: "info", running: "info", paused: "warning", succeeded: "success", failed: "danger", canceled: "neutral", interrupted: "danger" }[p.state];
|
|
1122
|
+
async function G(p, B) {
|
|
1094
1123
|
try {
|
|
1095
|
-
return await
|
|
1096
|
-
} catch (
|
|
1097
|
-
if (
|
|
1098
|
-
|
|
1124
|
+
return await f.ctx.call(p, B);
|
|
1125
|
+
} catch (_) {
|
|
1126
|
+
if (H) return;
|
|
1127
|
+
_?.code === "unsupported" ? (u.value = !0, i.value = [], v.value = [], k.value = void 0, c.value = void 0, w.value = void 0, m.value = void 0, z.value = void 0, K.value = void 0, O.value && URL.revokeObjectURL(O.value), O.value = "") : H || (n.value = _);
|
|
1099
1128
|
return;
|
|
1100
1129
|
}
|
|
1101
1130
|
}
|
|
1102
|
-
async function
|
|
1103
|
-
if (!(
|
|
1104
|
-
|
|
1131
|
+
async function le() {
|
|
1132
|
+
if (!(H || M.value)) {
|
|
1133
|
+
M.value = !0;
|
|
1105
1134
|
try {
|
|
1106
|
-
const
|
|
1107
|
-
if (!
|
|
1108
|
-
if (!
|
|
1109
|
-
|
|
1135
|
+
const p = await G("bg.status");
|
|
1136
|
+
if (!p || H) return;
|
|
1137
|
+
if (!p.limits || typeof p.admin != "boolean") {
|
|
1138
|
+
n.value = { code: "unavailable" };
|
|
1110
1139
|
return;
|
|
1111
1140
|
}
|
|
1112
|
-
|
|
1113
|
-
const
|
|
1114
|
-
|
|
1115
|
-
const
|
|
1116
|
-
|
|
1141
|
+
u.value = !1, m.value = p;
|
|
1142
|
+
const B = await G("bg.jobs.list");
|
|
1143
|
+
B && !H && (i.value = B.jobs ?? []);
|
|
1144
|
+
const _ = await G("bg.schedules.list");
|
|
1145
|
+
_ && !H && (v.value = _.schedules ?? []), !H && i.value.every(j) && v.value.every((ie) => !ie.enabled) && W && (clearInterval(W), W = void 0);
|
|
1117
1146
|
} finally {
|
|
1118
|
-
|
|
1147
|
+
M.value = !1;
|
|
1119
1148
|
}
|
|
1120
1149
|
}
|
|
1121
1150
|
}
|
|
1122
|
-
function
|
|
1123
|
-
|
|
1124
|
-
|
|
1151
|
+
function R() {
|
|
1152
|
+
W || (W = setInterval(() => {
|
|
1153
|
+
le();
|
|
1125
1154
|
}, 3e3));
|
|
1126
1155
|
}
|
|
1127
|
-
async function
|
|
1156
|
+
async function T(p) {
|
|
1128
1157
|
if (!r.value) {
|
|
1129
|
-
r.value = !0,
|
|
1158
|
+
r.value = !0, n.value = void 0;
|
|
1130
1159
|
try {
|
|
1131
|
-
await
|
|
1160
|
+
await p(), await le(), (v.value.some((B) => B.enabled) || i.value.some((B) => !j(B))) && R();
|
|
1132
1161
|
} finally {
|
|
1133
|
-
|
|
1162
|
+
H || (r.value = !1);
|
|
1134
1163
|
}
|
|
1135
1164
|
}
|
|
1136
1165
|
}
|
|
1137
|
-
const
|
|
1138
|
-
if (!
|
|
1139
|
-
await
|
|
1140
|
-
}),
|
|
1141
|
-
|
|
1142
|
-
},
|
|
1143
|
-
if (!
|
|
1144
|
-
await
|
|
1145
|
-
}),
|
|
1146
|
-
if (!
|
|
1147
|
-
await
|
|
1148
|
-
}),
|
|
1149
|
-
if (!
|
|
1150
|
-
await
|
|
1151
|
-
}),
|
|
1152
|
-
const
|
|
1153
|
-
return Number.isFinite(
|
|
1154
|
-
},
|
|
1155
|
-
const
|
|
1156
|
-
|
|
1157
|
-
},
|
|
1158
|
-
if (!
|
|
1159
|
-
await
|
|
1166
|
+
const E = () => T(async () => {
|
|
1167
|
+
if (!z.value) return;
|
|
1168
|
+
await G("bg.jobs.purge", { owner: z.value }) && (z.value = void 0);
|
|
1169
|
+
}), J = L(() => [{ value: "3600", label: a.value.hourly }, { value: "86400", label: a.value.daily }, { value: "604800", label: a.value.weekly }]), re = (p) => {
|
|
1170
|
+
k.value = p, D.value = !1, S.value = "3600";
|
|
1171
|
+
}, we = () => T(async () => {
|
|
1172
|
+
if (!k.value || !D.value) return;
|
|
1173
|
+
await G("bg.schedules.create", { key: Be(), jobId: k.value.id, intervalSeconds: Number(S.value), consent: !0 }) && (k.value = void 0);
|
|
1174
|
+
}), xe = (p) => T(() => G("bg.schedules.disable", { id: p })), ve = () => T(async () => {
|
|
1175
|
+
if (!c.value) return;
|
|
1176
|
+
await G("bg.schedules.delete", { id: c.value.id }) && (c.value = void 0);
|
|
1177
|
+
}), ce = () => T(async () => {
|
|
1178
|
+
if (!w.value) return;
|
|
1179
|
+
await G("bg.schedules.enable", { id: w.value.id, consent: !0 }) && (w.value = void 0);
|
|
1180
|
+
}), de = (p) => {
|
|
1181
|
+
const B = new Date(p);
|
|
1182
|
+
return Number.isFinite(B.getTime()) ? B.toLocaleString() : a.value.unknownTime;
|
|
1183
|
+
}, me = (p) => p.copyRetained && p.state === "succeeded" && !p.scheduleId && p.submitter?.user === m.value?.owner?.user && p.submitter?.uid === m.value?.owner?.uid, F = (p) => T(() => G("bg.jobs.cancel", { id: p })), ee = (p) => T(() => G("bg.jobs.pause", { id: p })), A = (p) => T(() => G("bg.jobs.resume", { id: p })), C = (p) => {
|
|
1184
|
+
const B = p.lastIndexOf("/");
|
|
1185
|
+
K.value = { folder: p.slice(0, B), relative: p.slice(B + 1) };
|
|
1186
|
+
}, P = () => T(async () => {
|
|
1187
|
+
if (!K.value) return;
|
|
1188
|
+
await G("bg.jobs.submit", { key: Be(), ...K.value }) && (K.value = void 0);
|
|
1160
1189
|
});
|
|
1161
|
-
async function
|
|
1162
|
-
const
|
|
1163
|
-
!
|
|
1190
|
+
async function I(p) {
|
|
1191
|
+
const B = await G("bg.jobs.result", { id: p.id });
|
|
1192
|
+
!B || H || (O.value && URL.revokeObjectURL(O.value), O.value = URL.createObjectURL(new Blob([JSON.stringify(B.result, null, 2)], { type: "application/json" })), Z.value = `${p.name || p.id}.sha256.json`);
|
|
1164
1193
|
}
|
|
1165
|
-
return
|
|
1166
|
-
|
|
1167
|
-
(
|
|
1194
|
+
return q({ refresh: le }), ge(() => {
|
|
1195
|
+
le().then(() => {
|
|
1196
|
+
(v.value.some((p) => p.enabled) || i.value.some((p) => !j(p))) && R();
|
|
1168
1197
|
});
|
|
1169
|
-
}),
|
|
1170
|
-
|
|
1171
|
-
}), (
|
|
1172
|
-
"aria-busy": r.value ||
|
|
1198
|
+
}), ye(() => {
|
|
1199
|
+
H = !0, ae.dispose(), W && clearInterval(W), O.value && URL.revokeObjectURL(O.value);
|
|
1200
|
+
}), (p, B) => (s(), x(e(he), {
|
|
1201
|
+
"aria-busy": r.value || M.value,
|
|
1173
1202
|
title: a.value.title,
|
|
1203
|
+
description: u.value ? void 0 : a.value.help,
|
|
1204
|
+
loading: !m.value && !n.value && !u.value,
|
|
1174
1205
|
collapsible: !1,
|
|
1175
1206
|
"data-background-panel": ""
|
|
1176
1207
|
}, {
|
|
1177
|
-
default:
|
|
1178
|
-
|
|
1208
|
+
default: l(() => [
|
|
1209
|
+
u.value ? (s(), x(e(X), {
|
|
1179
1210
|
key: 0,
|
|
1180
1211
|
tone: "warning"
|
|
1181
1212
|
}, {
|
|
1182
|
-
default:
|
|
1183
|
-
g(
|
|
1213
|
+
default: l(() => [
|
|
1214
|
+
g(t(a.value.unsupported), 1)
|
|
1184
1215
|
]),
|
|
1185
1216
|
_: 1
|
|
1186
|
-
})) : (
|
|
1187
|
-
|
|
1188
|
-
s.value ? (t(), $(e(Q), {
|
|
1217
|
+
})) : (s(), V(ne, { key: 1 }, [
|
|
1218
|
+
n.value ? (s(), x(e(X), {
|
|
1189
1219
|
key: 0,
|
|
1190
1220
|
tone: "danger",
|
|
1191
1221
|
role: "alert"
|
|
1192
1222
|
}, {
|
|
1193
|
-
default:
|
|
1194
|
-
g(
|
|
1223
|
+
default: l(() => [
|
|
1224
|
+
g(t(e(ia)(n.value, a.value)), 1)
|
|
1195
1225
|
]),
|
|
1196
1226
|
_: 1
|
|
1197
|
-
})) :
|
|
1198
|
-
|
|
1199
|
-
|
|
1200
|
-
|
|
1201
|
-
|
|
1202
|
-
|
|
1203
|
-
|
|
1204
|
-
|
|
1227
|
+
})) : h("", !0),
|
|
1228
|
+
m.value ? (s(), V(ne, { key: 1 }, [
|
|
1229
|
+
$("p", ht, t(m.value.worker?.alive ? o(a.value.workerRunning, { user: m.value.worker.username }) : a.value.workerStopped), 1),
|
|
1230
|
+
$("p", kt, t(o(a.value.limits, { size: m.value.limits.maxInputBytes / 1024, queue: m.value.limits.maxQueued, seconds: m.value.limits.jobTimeoutSeconds })), 1),
|
|
1231
|
+
$("p", _t, t(m.value.admin ? a.value.adminScope : a.value.ownerScope), 1),
|
|
1232
|
+
$("p", wt, t(o(a.value.ownerLimits, { jobs: m.value.limits.maxOwnerPending, size: m.value.limits.maxOwnerBytes / 1024 })), 1),
|
|
1233
|
+
$("div", xt, [
|
|
1234
|
+
d(e(U), {
|
|
1205
1235
|
variant: "secondary",
|
|
1206
1236
|
disabled: r.value,
|
|
1207
|
-
onClick:
|
|
1237
|
+
onClick: B[0] || (B[0] = (_) => N.value = !0)
|
|
1208
1238
|
}, {
|
|
1209
|
-
default:
|
|
1210
|
-
g(
|
|
1239
|
+
default: l(() => [
|
|
1240
|
+
g(t(a.value.chooseFile), 1)
|
|
1241
|
+
]),
|
|
1242
|
+
_: 1
|
|
1243
|
+
}, 8, ["disabled"]),
|
|
1244
|
+
d(e(U), {
|
|
1245
|
+
variant: "primary",
|
|
1246
|
+
disabled: r.value || !K.value,
|
|
1247
|
+
onClick: P
|
|
1248
|
+
}, {
|
|
1249
|
+
default: l(() => [
|
|
1250
|
+
g(t(a.value.submit), 1)
|
|
1211
1251
|
]),
|
|
1212
1252
|
_: 1
|
|
1213
1253
|
}, 8, ["disabled"])
|
|
1214
1254
|
]),
|
|
1215
|
-
|
|
1216
|
-
|
|
1217
|
-
|
|
1218
|
-
|
|
1219
|
-
|
|
1220
|
-
|
|
1221
|
-
|
|
1222
|
-
|
|
1223
|
-
|
|
1224
|
-
|
|
1225
|
-
|
|
1226
|
-
|
|
1227
|
-
|
|
1228
|
-
|
|
1229
|
-
|
|
1230
|
-
|
|
1231
|
-
|
|
1232
|
-
|
|
1233
|
-
g(l(a.value.submit), 1)
|
|
1234
|
-
]),
|
|
1235
|
-
_: 1
|
|
1236
|
-
}, 8, ["disabled"])
|
|
1237
|
-
]),
|
|
1238
|
-
E.value ? (t(), S("p", cl, l(m(a.value.chosen, { path: `${E.value.folder}/${E.value.relative}` })), 1)) : k("", !0),
|
|
1239
|
-
h(_e, {
|
|
1240
|
-
open: L.value,
|
|
1241
|
-
"onUpdate:open": f[1] || (f[1] = (c) => L.value = c),
|
|
1242
|
-
locale: p.ctx.locale,
|
|
1243
|
-
provider: e(G),
|
|
1244
|
-
mode: "file",
|
|
1245
|
-
title: a.value.pickerTitle,
|
|
1246
|
-
description: a.value.pickerConsent,
|
|
1247
|
-
onSelected: $e
|
|
1248
|
-
}, null, 8, ["open", "locale", "provider", "title", "description"])
|
|
1249
|
-
]),
|
|
1250
|
-
D.value && i.value.admin ? (t(), $(e(Q), {
|
|
1251
|
-
key: 0,
|
|
1255
|
+
K.value ? (s(), V("p", Ct, [
|
|
1256
|
+
g(t(o(a.value.chosen, { path: "" }).trim()) + " ", 1),
|
|
1257
|
+
d(e(pe), {
|
|
1258
|
+
path: `${K.value.folder}/${K.value.relative}`
|
|
1259
|
+
}, null, 8, ["path"])
|
|
1260
|
+
])) : h("", !0),
|
|
1261
|
+
d(Te, {
|
|
1262
|
+
open: N.value,
|
|
1263
|
+
"onUpdate:open": B[1] || (B[1] = (_) => N.value = _),
|
|
1264
|
+
locale: y.ctx.locale,
|
|
1265
|
+
provider: e(ae),
|
|
1266
|
+
mode: "file",
|
|
1267
|
+
title: a.value.pickerTitle,
|
|
1268
|
+
description: a.value.pickerConsent,
|
|
1269
|
+
onSelected: C
|
|
1270
|
+
}, null, 8, ["open", "locale", "provider", "title", "description"]),
|
|
1271
|
+
z.value && m.value.admin ? (s(), x(e(X), {
|
|
1272
|
+
key: 1,
|
|
1252
1273
|
tone: "warning"
|
|
1253
1274
|
}, {
|
|
1254
|
-
default:
|
|
1255
|
-
|
|
1256
|
-
|
|
1257
|
-
|
|
1275
|
+
default: l(() => [
|
|
1276
|
+
$("p", null, t(o(a.value.purgeConfirm, { user: z.value.user, uid: z.value.uid })), 1),
|
|
1277
|
+
$("div", $t, [
|
|
1278
|
+
d(e(U), {
|
|
1258
1279
|
variant: "secondary",
|
|
1259
1280
|
disabled: r.value,
|
|
1260
|
-
onClick:
|
|
1281
|
+
onClick: E
|
|
1261
1282
|
}, {
|
|
1262
|
-
default:
|
|
1263
|
-
g(
|
|
1283
|
+
default: l(() => [
|
|
1284
|
+
g(t(a.value.confirmPurge), 1)
|
|
1264
1285
|
]),
|
|
1265
1286
|
_: 1
|
|
1266
1287
|
}, 8, ["disabled"]),
|
|
1267
|
-
|
|
1288
|
+
d(e(U), {
|
|
1268
1289
|
variant: "secondary",
|
|
1269
1290
|
disabled: r.value,
|
|
1270
|
-
onClick:
|
|
1291
|
+
onClick: B[2] || (B[2] = (_) => z.value = void 0)
|
|
1271
1292
|
}, {
|
|
1272
|
-
default:
|
|
1273
|
-
g(
|
|
1293
|
+
default: l(() => [
|
|
1294
|
+
g(t(a.value.keepJobs), 1)
|
|
1274
1295
|
]),
|
|
1275
1296
|
_: 1
|
|
1276
1297
|
}, 8, ["disabled"])
|
|
1277
1298
|
])
|
|
1278
1299
|
]),
|
|
1279
1300
|
_: 1
|
|
1280
|
-
})) :
|
|
1281
|
-
|
|
1282
|
-
(
|
|
1283
|
-
key:
|
|
1284
|
-
|
|
1285
|
-
"
|
|
1286
|
-
|
|
1287
|
-
|
|
1288
|
-
|
|
1289
|
-
|
|
1290
|
-
|
|
1291
|
-
|
|
1292
|
-
|
|
1293
|
-
|
|
1294
|
-
|
|
1295
|
-
|
|
1296
|
-
|
|
1297
|
-
|
|
1298
|
-
|
|
1299
|
-
|
|
1300
|
-
|
|
1301
|
-
|
|
1302
|
-
|
|
1303
|
-
|
|
1304
|
-
|
|
1305
|
-
|
|
1306
|
-
|
|
1307
|
-
|
|
1308
|
-
|
|
1309
|
-
|
|
1310
|
-
|
|
1311
|
-
|
|
1312
|
-
|
|
1313
|
-
|
|
1314
|
-
|
|
1315
|
-
|
|
1316
|
-
|
|
1317
|
-
|
|
1318
|
-
|
|
1319
|
-
|
|
1320
|
-
|
|
1321
|
-
|
|
1322
|
-
|
|
1323
|
-
|
|
1324
|
-
|
|
1325
|
-
|
|
1326
|
-
|
|
1327
|
-
|
|
1328
|
-
|
|
1329
|
-
|
|
1330
|
-
|
|
1331
|
-
|
|
1332
|
-
|
|
1333
|
-
|
|
1334
|
-
|
|
1335
|
-
|
|
1336
|
-
|
|
1337
|
-
|
|
1338
|
-
|
|
1339
|
-
|
|
1340
|
-
|
|
1341
|
-
|
|
1342
|
-
|
|
1343
|
-
|
|
1344
|
-
|
|
1345
|
-
|
|
1346
|
-
|
|
1347
|
-
|
|
1348
|
-
|
|
1349
|
-
|
|
1350
|
-
|
|
1351
|
-
|
|
1352
|
-
|
|
1353
|
-
|
|
1354
|
-
|
|
1355
|
-
|
|
1356
|
-
|
|
1357
|
-
|
|
1358
|
-
|
|
1359
|
-
|
|
1360
|
-
|
|
1361
|
-
|
|
1301
|
+
})) : h("", !0),
|
|
1302
|
+
i.value.length ? (s(), V("div", zt, [
|
|
1303
|
+
(s(!0), V(ne, null, ke(i.value, (_) => (s(), x(e(Fe), {
|
|
1304
|
+
key: _.id,
|
|
1305
|
+
title: _.name,
|
|
1306
|
+
"layout-type": "compact",
|
|
1307
|
+
"data-job-state": _.state,
|
|
1308
|
+
"data-job-id": _.id
|
|
1309
|
+
}, {
|
|
1310
|
+
"header-actions": l(() => [
|
|
1311
|
+
d(e($e), {
|
|
1312
|
+
tone: Y(_),
|
|
1313
|
+
"data-bg-state": ""
|
|
1314
|
+
}, {
|
|
1315
|
+
default: l(() => [
|
|
1316
|
+
g(t(Q(_)), 1)
|
|
1317
|
+
]),
|
|
1318
|
+
_: 2
|
|
1319
|
+
}, 1032, ["tone"])
|
|
1320
|
+
]),
|
|
1321
|
+
default: l(() => [
|
|
1322
|
+
$("div", Pt, [
|
|
1323
|
+
_.progress?.total ? (s(), V("span", Vt, t(o(a.value.progressItems, { done: _.progress.done, count: _.progress.total })), 1)) : h("", !0),
|
|
1324
|
+
_.progress?.totalBytes ? (s(), V("span", It, t(o(a.value.progressBytes, { done: e(Re)(_.progress.bytes, y.ctx.locale), total: e(Re)(_.progress.totalBytes, y.ctx.locale) })), 1)) : h("", !0),
|
|
1325
|
+
_.progress?.item ? (s(), V("span", Tt, [
|
|
1326
|
+
g(t(o(a.value.progressItem, { item: "" }).trim()) + " ", 1),
|
|
1327
|
+
d(e(pe), {
|
|
1328
|
+
path: _.progress.item
|
|
1329
|
+
}, null, 8, ["path"])
|
|
1330
|
+
])) : h("", !0),
|
|
1331
|
+
m.value.admin && _.submitter ? (s(), V("span", Et, t(o(a.value.owner, { user: _.submitter.user, uid: _.submitter.uid })), 1)) : h("", !0),
|
|
1332
|
+
_.scheduleId ? (s(), V("span", Ut, t(a.value.scheduledJob), 1)) : h("", !0),
|
|
1333
|
+
$("div", At, [
|
|
1334
|
+
m.value.admin && _.submitter ? (s(), x(e(U), {
|
|
1335
|
+
key: 0,
|
|
1336
|
+
variant: "secondary",
|
|
1337
|
+
disabled: r.value,
|
|
1338
|
+
onClick: (ie) => z.value = _.submitter
|
|
1339
|
+
}, {
|
|
1340
|
+
default: l(() => [
|
|
1341
|
+
g(t(a.value.purgeOwner), 1)
|
|
1342
|
+
]),
|
|
1343
|
+
_: 1
|
|
1344
|
+
}, 8, ["disabled", "onClick"])) : h("", !0),
|
|
1345
|
+
!j(_) && !_.pauseRequested && !_.delegation_id ? (s(), x(e(U), {
|
|
1346
|
+
key: 1,
|
|
1347
|
+
variant: "secondary",
|
|
1348
|
+
disabled: r.value,
|
|
1349
|
+
onClick: (ie) => ee(_.id)
|
|
1350
|
+
}, {
|
|
1351
|
+
default: l(() => [
|
|
1352
|
+
g(t(a.value.pause), 1)
|
|
1353
|
+
]),
|
|
1354
|
+
_: 1
|
|
1355
|
+
}, 8, ["disabled", "onClick"])) : h("", !0),
|
|
1356
|
+
_.state === "paused" || se(_) ? (s(), x(e(U), {
|
|
1357
|
+
key: 2,
|
|
1358
|
+
variant: "secondary",
|
|
1359
|
+
disabled: r.value,
|
|
1360
|
+
onClick: (ie) => A(_.id)
|
|
1361
|
+
}, {
|
|
1362
|
+
default: l(() => [
|
|
1363
|
+
g(t(a.value.resume), 1)
|
|
1364
|
+
]),
|
|
1365
|
+
_: 1
|
|
1366
|
+
}, 8, ["disabled", "onClick"])) : h("", !0),
|
|
1367
|
+
te(_) ? h("", !0) : (s(), x(e(U), {
|
|
1368
|
+
key: 3,
|
|
1369
|
+
variant: "secondary",
|
|
1370
|
+
disabled: r.value,
|
|
1371
|
+
onClick: (ie) => F(_.id)
|
|
1372
|
+
}, {
|
|
1373
|
+
default: l(() => [
|
|
1374
|
+
g(t(a.value.cancel), 1)
|
|
1375
|
+
]),
|
|
1376
|
+
_: 1
|
|
1377
|
+
}, 8, ["disabled", "onClick"])),
|
|
1378
|
+
me(_) ? (s(), x(e(U), {
|
|
1379
|
+
key: 4,
|
|
1380
|
+
variant: "secondary",
|
|
1381
|
+
disabled: r.value,
|
|
1382
|
+
onClick: (ie) => re(_)
|
|
1383
|
+
}, {
|
|
1384
|
+
default: l(() => [
|
|
1385
|
+
g(t(a.value.scheduleCopy), 1)
|
|
1386
|
+
]),
|
|
1387
|
+
_: 1
|
|
1388
|
+
}, 8, ["disabled", "onClick"])) : h("", !0),
|
|
1389
|
+
_.state === "succeeded" ? (s(), x(e(U), {
|
|
1390
|
+
key: 5,
|
|
1391
|
+
variant: "secondary",
|
|
1392
|
+
disabled: r.value,
|
|
1393
|
+
onClick: (ie) => I(_)
|
|
1394
|
+
}, {
|
|
1395
|
+
default: l(() => [
|
|
1396
|
+
g(t(a.value.result), 1)
|
|
1397
|
+
]),
|
|
1398
|
+
_: 1
|
|
1399
|
+
}, 8, ["disabled", "onClick"])) : h("", !0)
|
|
1400
|
+
])
|
|
1401
|
+
])
|
|
1402
|
+
]),
|
|
1403
|
+
_: 2
|
|
1404
|
+
}, 1032, ["title", "data-job-state", "data-job-id"]))), 128))
|
|
1405
|
+
])) : (s(), V("p", St, t(a.value.noJobs), 1)),
|
|
1406
|
+
$("section", {
|
|
1362
1407
|
"data-bg-schedules": "",
|
|
1363
1408
|
class: "bg-schedules",
|
|
1364
1409
|
"aria-label": a.value.schedulesTitle
|
|
1365
1410
|
}, [
|
|
1366
|
-
|
|
1367
|
-
|
|
1368
|
-
|
|
1411
|
+
$("h3", null, t(a.value.schedulesTitle), 1),
|
|
1412
|
+
$("p", Rt, t(a.value.scheduleHelp), 1),
|
|
1413
|
+
k.value ? (s(), x(e(ze), {
|
|
1369
1414
|
key: 0,
|
|
1370
1415
|
class: "bg-schedule-form",
|
|
1371
|
-
onSubmit:
|
|
1416
|
+
onSubmit: Se(we, ["prevent"])
|
|
1372
1417
|
}, {
|
|
1373
|
-
default:
|
|
1374
|
-
|
|
1375
|
-
|
|
1418
|
+
default: l(() => [
|
|
1419
|
+
$("p", null, t(o(a.value.scheduleSource, { name: k.value.name })), 1),
|
|
1420
|
+
d(e(fe), {
|
|
1376
1421
|
label: a.value.interval
|
|
1377
1422
|
}, {
|
|
1378
|
-
default:
|
|
1379
|
-
|
|
1380
|
-
modelValue:
|
|
1381
|
-
"onUpdate:modelValue":
|
|
1423
|
+
default: l(() => [
|
|
1424
|
+
d(e(Ze), {
|
|
1425
|
+
modelValue: S.value,
|
|
1426
|
+
"onUpdate:modelValue": B[3] || (B[3] = (_) => S.value = _),
|
|
1382
1427
|
"data-schedule-interval": "",
|
|
1383
|
-
options:
|
|
1428
|
+
options: J.value,
|
|
1384
1429
|
disabled: r.value
|
|
1385
1430
|
}, null, 8, ["modelValue", "options", "disabled"])
|
|
1386
1431
|
]),
|
|
1387
1432
|
_: 1
|
|
1388
1433
|
}, 8, ["label"]),
|
|
1389
|
-
|
|
1390
|
-
modelValue:
|
|
1391
|
-
"onUpdate:modelValue":
|
|
1434
|
+
d(e(xa), {
|
|
1435
|
+
modelValue: D.value,
|
|
1436
|
+
"onUpdate:modelValue": B[4] || (B[4] = (_) => D.value = _),
|
|
1392
1437
|
"data-schedule-consent": "",
|
|
1393
1438
|
disabled: r.value,
|
|
1394
1439
|
label: a.value.scheduleConsent
|
|
1395
1440
|
}, null, 8, ["modelValue", "disabled", "label"]),
|
|
1396
|
-
|
|
1397
|
-
default:
|
|
1398
|
-
|
|
1441
|
+
d(e(Pe), null, {
|
|
1442
|
+
default: l(() => [
|
|
1443
|
+
d(e(U), {
|
|
1399
1444
|
type: "submit",
|
|
1400
1445
|
variant: "primary",
|
|
1401
|
-
disabled: r.value || !
|
|
1446
|
+
disabled: r.value || !D.value
|
|
1402
1447
|
}, {
|
|
1403
|
-
default:
|
|
1404
|
-
g(
|
|
1448
|
+
default: l(() => [
|
|
1449
|
+
g(t(a.value.createSchedule), 1)
|
|
1405
1450
|
]),
|
|
1406
1451
|
_: 1
|
|
1407
1452
|
}, 8, ["disabled"]),
|
|
1408
|
-
|
|
1453
|
+
d(e(U), {
|
|
1409
1454
|
type: "button",
|
|
1410
1455
|
variant: "secondary",
|
|
1411
1456
|
disabled: r.value,
|
|
1412
|
-
onClick:
|
|
1457
|
+
onClick: B[5] || (B[5] = (_) => k.value = void 0)
|
|
1413
1458
|
}, {
|
|
1414
|
-
default:
|
|
1415
|
-
g(
|
|
1459
|
+
default: l(() => [
|
|
1460
|
+
g(t(a.value.cancel), 1)
|
|
1416
1461
|
]),
|
|
1417
1462
|
_: 1
|
|
1418
1463
|
}, 8, ["disabled"])
|
|
@@ -1421,148 +1466,171 @@ const za = ["aria-busy", "aria-label"], Pa = { class: "file-toolbar file-locatio
|
|
|
1421
1466
|
})
|
|
1422
1467
|
]),
|
|
1423
1468
|
_: 1
|
|
1424
|
-
})) :
|
|
1425
|
-
|
|
1426
|
-
(
|
|
1427
|
-
key:
|
|
1428
|
-
|
|
1429
|
-
|
|
1430
|
-
|
|
1431
|
-
|
|
1432
|
-
|
|
1433
|
-
|
|
1434
|
-
|
|
1435
|
-
|
|
1436
|
-
tone: "warning"
|
|
1437
|
-
}, {
|
|
1438
|
-
default: n(() => [
|
|
1439
|
-
g(l(a.value.revisionChanged), 1)
|
|
1440
|
-
]),
|
|
1441
|
-
_: 1
|
|
1442
|
-
})) : c.reason === "input-unavailable" ? (t(), $(e(Q), {
|
|
1443
|
-
key: 3,
|
|
1444
|
-
tone: "warning"
|
|
1445
|
-
}, {
|
|
1446
|
-
default: n(() => [
|
|
1447
|
-
g(l(a.value.errors["input-unavailable"]), 1)
|
|
1448
|
-
]),
|
|
1449
|
-
_: 1
|
|
1450
|
-
})) : k("", !0),
|
|
1451
|
-
C("div", Al, [
|
|
1452
|
-
c.enabled ? (t(), $(e(A), {
|
|
1453
|
-
key: 0,
|
|
1454
|
-
variant: "secondary",
|
|
1455
|
-
disabled: r.value,
|
|
1456
|
-
onClick: (X) => se(c.id)
|
|
1457
|
-
}, {
|
|
1458
|
-
default: n(() => [
|
|
1459
|
-
g(l(a.value.disableSchedule), 1)
|
|
1460
|
-
]),
|
|
1461
|
-
_: 1
|
|
1462
|
-
}, 8, ["disabled", "onClick"])) : i.value.admin ? (t(), $(e(A), {
|
|
1463
|
-
key: 1,
|
|
1464
|
-
variant: "secondary",
|
|
1465
|
-
disabled: r.value,
|
|
1466
|
-
onClick: (X) => b.value = c
|
|
1467
|
-
}, {
|
|
1468
|
-
default: n(() => [
|
|
1469
|
-
g(l(a.value.enableSchedule), 1)
|
|
1470
|
-
]),
|
|
1471
|
-
_: 1
|
|
1472
|
-
}, 8, ["disabled", "onClick"])) : k("", !0),
|
|
1473
|
-
h(e(A), {
|
|
1474
|
-
variant: "secondary",
|
|
1475
|
-
disabled: r.value,
|
|
1476
|
-
onClick: (X) => x.value = c
|
|
1469
|
+
})) : h("", !0),
|
|
1470
|
+
v.value.length ? (s(), V("div", Bt, [
|
|
1471
|
+
(s(!0), V(ne, null, ke(v.value, (_) => (s(), x(e(Fe), {
|
|
1472
|
+
key: _.id,
|
|
1473
|
+
title: _.name,
|
|
1474
|
+
"layout-type": "compact",
|
|
1475
|
+
"data-schedule-id": _.id
|
|
1476
|
+
}, {
|
|
1477
|
+
"header-actions": l(() => [
|
|
1478
|
+
d(e($e), {
|
|
1479
|
+
tone: _.enabled ? "success" : "neutral",
|
|
1480
|
+
"data-bg-state": ""
|
|
1477
1481
|
}, {
|
|
1478
|
-
default:
|
|
1479
|
-
g(
|
|
1482
|
+
default: l(() => [
|
|
1483
|
+
g(t(_.enabled ? a.value.scheduleOn : a.value.scheduleOff), 1)
|
|
1480
1484
|
]),
|
|
1481
|
-
_:
|
|
1482
|
-
},
|
|
1483
|
-
])
|
|
1484
|
-
|
|
1485
|
-
|
|
1486
|
-
|
|
1485
|
+
_: 2
|
|
1486
|
+
}, 1032, ["tone"])
|
|
1487
|
+
]),
|
|
1488
|
+
default: l(() => [
|
|
1489
|
+
$("div", Ft, [
|
|
1490
|
+
m.value.admin ? (s(), V("span", Ot, t(o(a.value.owner, { user: _.owner.user, uid: _.owner.uid })), 1)) : h("", !0),
|
|
1491
|
+
_.enabled ? (s(), V("span", Lt, t(o(a.value.nextRun, { time: de(_.nextAt) })), 1)) : h("", !0),
|
|
1492
|
+
$("span", Nt, t(o(a.value.missedRuns, { count: _.missed })), 1),
|
|
1493
|
+
_.reason === "worker-changed" ? (s(), x(e(X), {
|
|
1494
|
+
key: 2,
|
|
1495
|
+
tone: "warning"
|
|
1496
|
+
}, {
|
|
1497
|
+
default: l(() => [
|
|
1498
|
+
g(t(a.value.revisionChanged), 1)
|
|
1499
|
+
]),
|
|
1500
|
+
_: 1
|
|
1501
|
+
})) : _.reason === "input-unavailable" ? (s(), x(e(X), {
|
|
1502
|
+
key: 3,
|
|
1503
|
+
tone: "warning"
|
|
1504
|
+
}, {
|
|
1505
|
+
default: l(() => [
|
|
1506
|
+
g(t(a.value.errors["input-unavailable"]), 1)
|
|
1507
|
+
]),
|
|
1508
|
+
_: 1
|
|
1509
|
+
})) : h("", !0),
|
|
1510
|
+
$("div", Mt, [
|
|
1511
|
+
_.enabled ? (s(), x(e(U), {
|
|
1512
|
+
key: 0,
|
|
1513
|
+
variant: "secondary",
|
|
1514
|
+
disabled: r.value,
|
|
1515
|
+
onClick: (ie) => xe(_.id)
|
|
1516
|
+
}, {
|
|
1517
|
+
default: l(() => [
|
|
1518
|
+
g(t(a.value.disableSchedule), 1)
|
|
1519
|
+
]),
|
|
1520
|
+
_: 1
|
|
1521
|
+
}, 8, ["disabled", "onClick"])) : m.value.admin ? (s(), x(e(U), {
|
|
1522
|
+
key: 1,
|
|
1523
|
+
variant: "secondary",
|
|
1524
|
+
disabled: r.value,
|
|
1525
|
+
onClick: (ie) => w.value = _
|
|
1526
|
+
}, {
|
|
1527
|
+
default: l(() => [
|
|
1528
|
+
g(t(a.value.enableSchedule), 1)
|
|
1529
|
+
]),
|
|
1530
|
+
_: 1
|
|
1531
|
+
}, 8, ["disabled", "onClick"])) : h("", !0),
|
|
1532
|
+
d(e(U), {
|
|
1533
|
+
variant: "secondary",
|
|
1534
|
+
disabled: r.value,
|
|
1535
|
+
onClick: (ie) => c.value = _
|
|
1536
|
+
}, {
|
|
1537
|
+
default: l(() => [
|
|
1538
|
+
g(t(a.value.deleteSchedule), 1)
|
|
1539
|
+
]),
|
|
1540
|
+
_: 1
|
|
1541
|
+
}, 8, ["disabled", "onClick"])
|
|
1542
|
+
])
|
|
1543
|
+
])
|
|
1544
|
+
]),
|
|
1545
|
+
_: 2
|
|
1546
|
+
}, 1032, ["title", "data-schedule-id"]))), 128))
|
|
1547
|
+
])) : (s(), V("p", qt, t(a.value.noSchedules), 1)),
|
|
1548
|
+
c.value ? (s(), x(e(X), {
|
|
1487
1549
|
key: 3,
|
|
1488
1550
|
tone: "warning"
|
|
1489
1551
|
}, {
|
|
1490
|
-
default:
|
|
1491
|
-
|
|
1492
|
-
|
|
1493
|
-
|
|
1552
|
+
default: l(() => [
|
|
1553
|
+
$("p", null, t(o(a.value.deleteScheduleConsent, { name: c.value.name })), 1),
|
|
1554
|
+
$("div", Kt, [
|
|
1555
|
+
d(e(U), {
|
|
1494
1556
|
variant: "danger",
|
|
1495
1557
|
disabled: r.value,
|
|
1496
|
-
onClick:
|
|
1558
|
+
onClick: ve
|
|
1497
1559
|
}, {
|
|
1498
|
-
default:
|
|
1499
|
-
g(
|
|
1560
|
+
default: l(() => [
|
|
1561
|
+
g(t(a.value.confirmDeleteSchedule), 1)
|
|
1500
1562
|
]),
|
|
1501
1563
|
_: 1
|
|
1502
1564
|
}, 8, ["disabled"]),
|
|
1503
|
-
|
|
1565
|
+
d(e(U), {
|
|
1504
1566
|
variant: "secondary",
|
|
1505
1567
|
disabled: r.value,
|
|
1506
|
-
onClick:
|
|
1568
|
+
onClick: B[6] || (B[6] = (_) => c.value = void 0)
|
|
1507
1569
|
}, {
|
|
1508
|
-
default:
|
|
1509
|
-
g(
|
|
1570
|
+
default: l(() => [
|
|
1571
|
+
g(t(a.value.cancel), 1)
|
|
1510
1572
|
]),
|
|
1511
1573
|
_: 1
|
|
1512
1574
|
}, 8, ["disabled"])
|
|
1513
1575
|
])
|
|
1514
1576
|
]),
|
|
1515
1577
|
_: 1
|
|
1516
|
-
})) :
|
|
1517
|
-
|
|
1578
|
+
})) : h("", !0),
|
|
1579
|
+
w.value ? (s(), x(e(X), {
|
|
1518
1580
|
key: 4,
|
|
1519
1581
|
tone: "warning"
|
|
1520
1582
|
}, {
|
|
1521
|
-
default:
|
|
1522
|
-
|
|
1523
|
-
|
|
1524
|
-
|
|
1583
|
+
default: l(() => [
|
|
1584
|
+
$("p", null, t(o(a.value.enableScheduleConsent, { name: w.value.name })), 1),
|
|
1585
|
+
$("div", Ht, [
|
|
1586
|
+
d(e(U), {
|
|
1525
1587
|
variant: "primary",
|
|
1526
1588
|
disabled: r.value,
|
|
1527
|
-
onClick:
|
|
1589
|
+
onClick: ce
|
|
1528
1590
|
}, {
|
|
1529
|
-
default:
|
|
1530
|
-
g(
|
|
1591
|
+
default: l(() => [
|
|
1592
|
+
g(t(a.value.confirmEnableSchedule), 1)
|
|
1531
1593
|
]),
|
|
1532
1594
|
_: 1
|
|
1533
1595
|
}, 8, ["disabled"]),
|
|
1534
|
-
|
|
1596
|
+
d(e(U), {
|
|
1535
1597
|
variant: "secondary",
|
|
1536
1598
|
disabled: r.value,
|
|
1537
|
-
onClick:
|
|
1599
|
+
onClick: B[7] || (B[7] = (_) => w.value = void 0)
|
|
1538
1600
|
}, {
|
|
1539
|
-
default:
|
|
1540
|
-
g(
|
|
1601
|
+
default: l(() => [
|
|
1602
|
+
g(t(a.value.cancel), 1)
|
|
1541
1603
|
]),
|
|
1542
1604
|
_: 1
|
|
1543
1605
|
}, 8, ["disabled"])
|
|
1544
1606
|
])
|
|
1545
1607
|
]),
|
|
1546
1608
|
_: 1
|
|
1547
|
-
})) :
|
|
1548
|
-
], 8,
|
|
1549
|
-
|
|
1550
|
-
key:
|
|
1551
|
-
href:
|
|
1552
|
-
download:
|
|
1609
|
+
})) : h("", !0)
|
|
1610
|
+
], 8, Dt),
|
|
1611
|
+
O.value ? (s(), x(e(Ye), {
|
|
1612
|
+
key: 4,
|
|
1613
|
+
href: O.value,
|
|
1614
|
+
download: Z.value
|
|
1553
1615
|
}, {
|
|
1554
|
-
default:
|
|
1555
|
-
g(
|
|
1616
|
+
default: l(() => [
|
|
1617
|
+
g(t(a.value.download), 1)
|
|
1556
1618
|
]),
|
|
1557
1619
|
_: 1
|
|
1558
|
-
}, 8, ["href", "download"])) :
|
|
1559
|
-
], 64)) :
|
|
1620
|
+
}, 8, ["href", "download"])) : h("", !0)
|
|
1621
|
+
], 64)) : h("", !0)
|
|
1560
1622
|
], 64))
|
|
1561
1623
|
]),
|
|
1562
1624
|
_: 1
|
|
1563
|
-
}, 8, ["aria-busy", "title"]));
|
|
1625
|
+
}, 8, ["aria-busy", "title", "description", "loading"]));
|
|
1564
1626
|
}
|
|
1565
|
-
}),
|
|
1627
|
+
}), Xl = /* @__PURE__ */ ue(Gt, [["__scopeId", "data-v-fa2b6101"]]), Jt = { class: "executor-alert" }, Xt = {
|
|
1628
|
+
key: 1,
|
|
1629
|
+
class: "executor-summary"
|
|
1630
|
+
}, Qt = ["data-executor-status"], Yt = { class: "executor-help" }, Zt = {
|
|
1631
|
+
key: 0,
|
|
1632
|
+
class: "executor-hint"
|
|
1633
|
+
}, Wt = /* @__PURE__ */ oe({
|
|
1566
1634
|
__name: "ExecutorSettings",
|
|
1567
1635
|
props: {
|
|
1568
1636
|
admin: { type: Boolean },
|
|
@@ -1570,301 +1638,381 @@ const za = ["aria-busy", "aria-label"], Pa = { class: "file-toolbar file-locatio
|
|
|
1570
1638
|
ctx: {}
|
|
1571
1639
|
},
|
|
1572
1640
|
emits: ["confirmed"],
|
|
1573
|
-
setup(
|
|
1574
|
-
const a =
|
|
1575
|
-
let
|
|
1576
|
-
async function
|
|
1577
|
-
const
|
|
1578
|
-
if (
|
|
1579
|
-
const
|
|
1580
|
-
if (
|
|
1581
|
-
const
|
|
1582
|
-
let
|
|
1583
|
-
for (let
|
|
1584
|
-
const
|
|
1585
|
-
if (
|
|
1586
|
-
if (!Array.isArray(
|
|
1587
|
-
for (const
|
|
1588
|
-
|
|
1589
|
-
if (
|
|
1590
|
-
if (
|
|
1641
|
+
setup(y, { expose: q, emit: f }) {
|
|
1642
|
+
const a = y, o = f, m = We(), i = L(() => Ke(a.locale)), n = b(), u = b(""), r = b(!1), v = b(!1), k = b(!1), D = b(), S = b(""), c = b([]), w = L(() => D.value?.scope_mode === "install-selected"), z = L(() => [{ label: i.value.homeScope, value: "home" }, ...c.value]), M = L(() => !w.value || !!S.value && z.value.some((Q) => Q.value === S.value)), N = L(() => w.value && !D.value?.selection), K = L(() => S.value !== D.value?.selection?.scope);
|
|
1643
|
+
let O = !1;
|
|
1644
|
+
async function Z(Q) {
|
|
1645
|
+
const Y = Q ?? await m.status();
|
|
1646
|
+
if (O || (n.value = Y, !a.ctx)) return;
|
|
1647
|
+
const G = await a.ctx.call("delegate.status");
|
|
1648
|
+
if (O || (D.value = G, G.scope_mode !== "install-selected")) return;
|
|
1649
|
+
const le = [];
|
|
1650
|
+
let R = 0;
|
|
1651
|
+
for (let T = 0; T < 128; T++) {
|
|
1652
|
+
const E = await a.ctx.call("bg.browse", { offset: R });
|
|
1653
|
+
if (O) return;
|
|
1654
|
+
if (!Array.isArray(E.shares) || !Number.isSafeInteger(E.total) || E.total < 0 || !E.shares.length && R < E.total) throw { code: "EXECUTOR_PROTOCOL" };
|
|
1655
|
+
for (const J of E.shares)
|
|
1656
|
+
J.isdir && J.path === "/" + J.name && !["home", "homes"].includes(J.name.toLowerCase()) && le.push({ label: J.name, value: "shared:" + J.name });
|
|
1657
|
+
if (R += E.shares.length, R >= E.total) break;
|
|
1658
|
+
if (T === 127) throw { code: "EXECUTOR_PROTOCOL" };
|
|
1591
1659
|
}
|
|
1592
|
-
|
|
1660
|
+
c.value = le, S.value = G.selection?.scope ?? G.preselection ?? "";
|
|
1593
1661
|
}
|
|
1594
|
-
async function
|
|
1662
|
+
async function ae() {
|
|
1595
1663
|
if (!(!a.admin || r.value)) {
|
|
1596
|
-
r.value = !0,
|
|
1664
|
+
r.value = !0, k.value = !1;
|
|
1597
1665
|
try {
|
|
1598
|
-
await
|
|
1666
|
+
await Z();
|
|
1599
1667
|
} catch {
|
|
1600
|
-
|
|
1668
|
+
O || (k.value = !0);
|
|
1601
1669
|
} finally {
|
|
1602
|
-
|
|
1670
|
+
O || (r.value = !1);
|
|
1603
1671
|
}
|
|
1604
1672
|
}
|
|
1605
1673
|
}
|
|
1606
|
-
async function
|
|
1607
|
-
if (!a.admin || r.value || !
|
|
1608
|
-
r.value = !0,
|
|
1609
|
-
const
|
|
1610
|
-
|
|
1674
|
+
async function W() {
|
|
1675
|
+
if (!a.admin || r.value || !u.value || !M.value || k.value) return;
|
|
1676
|
+
r.value = !0, k.value = !1;
|
|
1677
|
+
const Q = u.value;
|
|
1678
|
+
u.value = "", v.value = !0;
|
|
1611
1679
|
try {
|
|
1612
|
-
let
|
|
1613
|
-
await
|
|
1680
|
+
let Y = w.value ? await m.authorize(Q, S.value) : await m.authorize(Q);
|
|
1681
|
+
await Z(Y), !O && w.value && Y.state === "ready" && N.value && (Y = await m.authorize(Q, S.value), await Z(Y)), O || o("confirmed");
|
|
1614
1682
|
} catch {
|
|
1615
|
-
|
|
1683
|
+
O || (k.value = !0);
|
|
1616
1684
|
} finally {
|
|
1617
|
-
|
|
1685
|
+
O || (r.value = !1, v.value = !1);
|
|
1618
1686
|
}
|
|
1619
1687
|
}
|
|
1620
|
-
|
|
1621
|
-
|
|
1622
|
-
|
|
1623
|
-
|
|
1624
|
-
|
|
1625
|
-
|
|
1626
|
-
|
|
1688
|
+
const H = L(() => v.value ? "confirming" : n.value ? n.value.state === "ready" ? N.value ? "scope" : "ready" : n.value.state === "needs-admin-approval" ? "needs" : "blocked" : void 0), j = L(() => ({ ready: { tone: "success", text: i.value.statusReady }, scope: { tone: "warning", text: i.value.statusScope }, needs: { tone: "warning", text: i.value.statusNeeds }, blocked: { tone: "danger", text: i.value.statusBlocked }, confirming: { tone: "info", text: i.value.statusConfirming } })[H.value ?? "confirming"]), te = L(() => w.value && !!D.value?.selection && !K.value), se = L(() => r.value || k.value ? "" : te.value ? i.value.hintUnchanged : u.value ? "" : i.value.hintPassword);
|
|
1689
|
+
return q({ refresh: ae }), ge(() => {
|
|
1690
|
+
m.subscribe?.((Q) => {
|
|
1691
|
+
O || (n.value = Q);
|
|
1692
|
+
}), ae();
|
|
1693
|
+
}), ye(() => {
|
|
1694
|
+
O = !0, u.value = "";
|
|
1695
|
+
}), (Q, Y) => y.admin ? (s(), x(e(he), {
|
|
1627
1696
|
key: 0,
|
|
1628
|
-
title:
|
|
1697
|
+
title: i.value.setupTitle,
|
|
1698
|
+
description: i.value.setupHelp,
|
|
1699
|
+
loading: !n.value && !v.value && !k.value,
|
|
1629
1700
|
collapsible: !1,
|
|
1630
1701
|
"aria-busy": r.value
|
|
1631
1702
|
}, {
|
|
1632
|
-
default:
|
|
1633
|
-
|
|
1634
|
-
v.value ? (t(), $(e(Q), {
|
|
1703
|
+
default: l(() => [
|
|
1704
|
+
k.value ? (s(), x(e(X), {
|
|
1635
1705
|
key: 0,
|
|
1636
1706
|
tone: "danger",
|
|
1637
1707
|
role: "alert"
|
|
1638
1708
|
}, {
|
|
1639
|
-
default:
|
|
1640
|
-
|
|
1709
|
+
default: l(() => [
|
|
1710
|
+
$("span", Jt, [
|
|
1711
|
+
g(t(i.value.setupError), 1),
|
|
1712
|
+
d(e(U), {
|
|
1713
|
+
variant: "secondary",
|
|
1714
|
+
size: "sm",
|
|
1715
|
+
disabled: r.value,
|
|
1716
|
+
onClick: ae
|
|
1717
|
+
}, {
|
|
1718
|
+
default: l(() => [
|
|
1719
|
+
g(t(i.value.retry), 1)
|
|
1720
|
+
]),
|
|
1721
|
+
_: 1
|
|
1722
|
+
}, 8, ["disabled"])
|
|
1723
|
+
])
|
|
1724
|
+
]),
|
|
1725
|
+
_: 1
|
|
1726
|
+
})) : h("", !0),
|
|
1727
|
+
n.value || v.value ? (s(), V("div", Xt, [
|
|
1728
|
+
d(e(Ce), {
|
|
1729
|
+
label: i.value.status,
|
|
1730
|
+
"label-width": "10rem"
|
|
1731
|
+
}, {
|
|
1732
|
+
default: l(() => [
|
|
1733
|
+
$("span", {
|
|
1734
|
+
role: "status",
|
|
1735
|
+
"data-executor-status": H.value
|
|
1736
|
+
}, [
|
|
1737
|
+
d(e($e), {
|
|
1738
|
+
tone: j.value.tone
|
|
1739
|
+
}, {
|
|
1740
|
+
default: l(() => [
|
|
1741
|
+
g(t(j.value.text), 1)
|
|
1742
|
+
]),
|
|
1743
|
+
_: 1
|
|
1744
|
+
}, 8, ["tone"])
|
|
1745
|
+
], 8, Qt)
|
|
1746
|
+
]),
|
|
1747
|
+
_: 1
|
|
1748
|
+
}, 8, ["label"]),
|
|
1749
|
+
n.value?.reason && (n.value.state === "blocked" || n.value.state === "unsupported") ? (s(), x(e(Ce), {
|
|
1750
|
+
key: 0,
|
|
1751
|
+
label: i.value.details,
|
|
1752
|
+
"label-width": "10rem"
|
|
1753
|
+
}, {
|
|
1754
|
+
default: l(() => [
|
|
1755
|
+
g(t(n.value.reason), 1)
|
|
1756
|
+
]),
|
|
1757
|
+
_: 1
|
|
1758
|
+
}, 8, ["label"])) : h("", !0),
|
|
1759
|
+
D.value?.selection ? (s(), x(e(Ce), {
|
|
1760
|
+
key: 1,
|
|
1761
|
+
label: i.value.protectedScope,
|
|
1762
|
+
"label-width": "10rem"
|
|
1763
|
+
}, {
|
|
1764
|
+
default: l(() => [
|
|
1765
|
+
d(e(pe), {
|
|
1766
|
+
path: D.value.selection.root
|
|
1767
|
+
}, null, 8, ["path"])
|
|
1768
|
+
]),
|
|
1769
|
+
_: 1
|
|
1770
|
+
}, 8, ["label"])) : h("", !0)
|
|
1771
|
+
])) : h("", !0),
|
|
1772
|
+
H.value === "needs" ? (s(), x(e(X), {
|
|
1773
|
+
key: 2,
|
|
1774
|
+
tone: "info"
|
|
1775
|
+
}, {
|
|
1776
|
+
default: l(() => [
|
|
1777
|
+
g(t(i.value.needs), 1)
|
|
1641
1778
|
]),
|
|
1642
1779
|
_: 1
|
|
1643
|
-
})) :
|
|
1644
|
-
C("p", Rl, l(P.value ? d.value.confirming : s.value ? s.value.state === "ready" ? L.value ? d.value.scopeNeeds : d.value.ready : s.value.state === "needs-admin-approval" ? d.value.needs : d.value.blocked : d.value.loading), 1),
|
|
1645
|
-
s.value?.reason && (s.value.state === "blocked" || s.value.state === "unsupported") ? (t(), S("p", ql, l(d.value.details) + ": " + l(s.value.reason), 1)) : k("", !0),
|
|
1646
|
-
_.value?.selection ? (t(), S("p", Bl, l(d.value.protectedScope) + ": " + l(_.value.selection.root), 1)) : k("", !0),
|
|
1647
|
-
_.value?.mismatch ? (t(), $(e(Q), {
|
|
1780
|
+
})) : H.value === "scope" ? (s(), x(e(X), {
|
|
1648
1781
|
key: 3,
|
|
1649
1782
|
tone: "warning"
|
|
1650
1783
|
}, {
|
|
1651
|
-
default:
|
|
1652
|
-
g(
|
|
1784
|
+
default: l(() => [
|
|
1785
|
+
g(t(i.value.scopeNeeds), 1)
|
|
1653
1786
|
]),
|
|
1654
1787
|
_: 1
|
|
1655
|
-
})) :
|
|
1656
|
-
s.value?.state === "needs-admin-approval" || s.value?.retry || b.value && s.value?.state === "ready" ? (t(), $(e(be), {
|
|
1788
|
+
})) : H.value === "blocked" ? (s(), x(e(X), {
|
|
1657
1789
|
key: 4,
|
|
1658
|
-
|
|
1790
|
+
tone: "warning"
|
|
1659
1791
|
}, {
|
|
1660
|
-
default:
|
|
1661
|
-
|
|
1662
|
-
|
|
1663
|
-
|
|
1664
|
-
|
|
1792
|
+
default: l(() => [
|
|
1793
|
+
g(t(i.value.blocked), 1)
|
|
1794
|
+
]),
|
|
1795
|
+
_: 1
|
|
1796
|
+
})) : h("", !0),
|
|
1797
|
+
D.value?.mismatch ? (s(), x(e(X), {
|
|
1798
|
+
key: 5,
|
|
1799
|
+
tone: "warning"
|
|
1800
|
+
}, {
|
|
1801
|
+
default: l(() => [
|
|
1802
|
+
g(t(i.value.scopeMismatch), 1)
|
|
1803
|
+
]),
|
|
1804
|
+
_: 1
|
|
1805
|
+
})) : h("", !0),
|
|
1806
|
+
n.value?.state === "needs-admin-approval" || n.value?.retry || w.value && n.value?.state === "ready" ? (s(), x(e(ze), {
|
|
1807
|
+
key: 6,
|
|
1808
|
+
direction: "vertical",
|
|
1809
|
+
class: "executor-form",
|
|
1810
|
+
onSubmit: Se(W, ["prevent"])
|
|
1811
|
+
}, {
|
|
1812
|
+
default: l(() => [
|
|
1813
|
+
w.value ? (s(), V(ne, { key: 0 }, [
|
|
1814
|
+
$("p", Yt, t(D.value?.selection ? i.value.scopeChangeHelp : i.value.preselectionHelp), 1),
|
|
1815
|
+
d(e(fe), {
|
|
1816
|
+
label: i.value.scopeLabel,
|
|
1665
1817
|
"label-for": "delegate-scope"
|
|
1666
1818
|
}, {
|
|
1667
|
-
default:
|
|
1668
|
-
|
|
1819
|
+
default: l(() => [
|
|
1820
|
+
d(e(Ze), {
|
|
1669
1821
|
id: "delegate-scope",
|
|
1670
|
-
modelValue:
|
|
1671
|
-
"onUpdate:modelValue":
|
|
1672
|
-
options:
|
|
1673
|
-
disabled: r.value ||
|
|
1822
|
+
modelValue: S.value,
|
|
1823
|
+
"onUpdate:modelValue": Y[0] || (Y[0] = (G) => S.value = G),
|
|
1824
|
+
options: z.value,
|
|
1825
|
+
disabled: r.value || k.value
|
|
1674
1826
|
}, null, 8, ["modelValue", "options", "disabled"])
|
|
1675
1827
|
]),
|
|
1676
1828
|
_: 1
|
|
1677
1829
|
}, 8, ["label"])
|
|
1678
|
-
], 64)) :
|
|
1679
|
-
|
|
1680
|
-
label:
|
|
1830
|
+
], 64)) : h("", !0),
|
|
1831
|
+
d(e(fe), {
|
|
1832
|
+
label: i.value.password,
|
|
1681
1833
|
"label-for": "delegate-password"
|
|
1682
1834
|
}, {
|
|
1683
|
-
default:
|
|
1684
|
-
|
|
1835
|
+
default: l(() => [
|
|
1836
|
+
d(e(_e), {
|
|
1685
1837
|
id: "delegate-password",
|
|
1686
|
-
modelValue:
|
|
1687
|
-
"onUpdate:modelValue":
|
|
1838
|
+
modelValue: u.value,
|
|
1839
|
+
"onUpdate:modelValue": Y[1] || (Y[1] = (G) => u.value = G),
|
|
1688
1840
|
type: "password",
|
|
1689
1841
|
autocomplete: "current-password",
|
|
1690
|
-
disabled: r.value ||
|
|
1842
|
+
disabled: r.value || k.value
|
|
1691
1843
|
}, null, 8, ["modelValue", "disabled"])
|
|
1692
1844
|
]),
|
|
1693
1845
|
_: 1
|
|
1694
1846
|
}, 8, ["label"]),
|
|
1695
|
-
|
|
1696
|
-
default:
|
|
1697
|
-
|
|
1847
|
+
d(e(Pe), null, {
|
|
1848
|
+
default: l(() => [
|
|
1849
|
+
d(e(U), {
|
|
1698
1850
|
type: "submit",
|
|
1699
1851
|
variant: "primary",
|
|
1700
|
-
disabled: r.value ||
|
|
1852
|
+
disabled: r.value || k.value || !u.value || !M.value || te.value
|
|
1701
1853
|
}, {
|
|
1702
|
-
default:
|
|
1703
|
-
g(
|
|
1854
|
+
default: l(() => [
|
|
1855
|
+
g(t(w.value ? D.value?.selection ? i.value.confirmScope : i.value.confirmShare : i.value.authorize), 1)
|
|
1704
1856
|
]),
|
|
1705
1857
|
_: 1
|
|
1706
|
-
}, 8, ["disabled"])
|
|
1858
|
+
}, 8, ["disabled"]),
|
|
1859
|
+
se.value ? (s(), V("span", Zt, t(se.value), 1)) : h("", !0)
|
|
1707
1860
|
]),
|
|
1708
1861
|
_: 1
|
|
1709
1862
|
})
|
|
1710
1863
|
]),
|
|
1711
1864
|
_: 1
|
|
1712
|
-
})) :
|
|
1713
|
-
h(e(A), {
|
|
1714
|
-
variant: "secondary",
|
|
1715
|
-
disabled: r.value,
|
|
1716
|
-
onClick: G
|
|
1717
|
-
}, {
|
|
1718
|
-
default: n(() => [
|
|
1719
|
-
g(l(d.value.refresh), 1)
|
|
1720
|
-
]),
|
|
1721
|
-
_: 1
|
|
1722
|
-
}, 8, ["disabled"])
|
|
1865
|
+
})) : h("", !0)
|
|
1723
1866
|
]),
|
|
1724
1867
|
_: 1
|
|
1725
|
-
}, 8, ["title", "aria-busy"])) :
|
|
1868
|
+
}, 8, ["title", "description", "loading", "aria-busy"])) : h("", !0);
|
|
1726
1869
|
}
|
|
1727
|
-
}),
|
|
1870
|
+
}), Ql = /* @__PURE__ */ ue(Wt, [["__scopeId", "data-v-868f9f3a"]]), jt = {
|
|
1728
1871
|
key: 1,
|
|
1729
1872
|
role: "status"
|
|
1730
|
-
},
|
|
1873
|
+
}, el = {
|
|
1731
1874
|
key: 2,
|
|
1732
1875
|
role: "status"
|
|
1733
|
-
},
|
|
1876
|
+
}, al = {
|
|
1734
1877
|
key: 0,
|
|
1735
1878
|
role: "status",
|
|
1736
1879
|
class: "destination"
|
|
1737
|
-
},
|
|
1880
|
+
}, tl = { key: 3 }, ll = {
|
|
1738
1881
|
key: 4,
|
|
1739
1882
|
class: "records"
|
|
1740
|
-
},
|
|
1883
|
+
}, sl = ["data-job-state"], nl = ["role"], il = { key: 5 }, ol = {
|
|
1741
1884
|
key: 6,
|
|
1742
1885
|
class: "records"
|
|
1743
|
-
},
|
|
1886
|
+
}, ul = /* @__PURE__ */ oe({
|
|
1744
1887
|
__name: "DelegatePanel",
|
|
1745
1888
|
props: {
|
|
1746
1889
|
ctx: {}
|
|
1747
1890
|
},
|
|
1748
|
-
setup(
|
|
1749
|
-
const
|
|
1750
|
-
let
|
|
1751
|
-
|
|
1752
|
-
|
|
1891
|
+
setup(y, { expose: q }) {
|
|
1892
|
+
const f = y, a = L(() => Ke(f.ctx.locale)), o = L(() => He(f.ctx.locale)), m = Me(f.ctx), i = b(), n = b([]), u = b([]), r = b(!1), v = b(), k = b(""), D = b(!1), S = b(""), c = b(""), w = b("");
|
|
1893
|
+
let z = !1, M, N;
|
|
1894
|
+
Je([c, S, w], () => {
|
|
1895
|
+
N = void 0;
|
|
1753
1896
|
}, { flush: "sync" });
|
|
1754
|
-
const
|
|
1755
|
-
async function
|
|
1756
|
-
if (
|
|
1757
|
-
const [
|
|
1758
|
-
if (!
|
|
1759
|
-
|
|
1760
|
-
for (const
|
|
1897
|
+
const K = (R) => ["queued", "running", "waiting_executor"].includes(R.state), O = L(() => u.value.some((R) => R.state === "waiting_executor")), Z = ["EXECUTOR_UNAVAILABLE", "EXECUTOR_TIMEOUT"], ae = L(() => O.value && Z.includes(v.value?.code ?? "")), W = L(() => i.value && i.value.state !== "ready" && !(O.value && i.value.state === "needs-admin-approval" && Z.includes(i.value.reason ?? "")));
|
|
1898
|
+
async function H() {
|
|
1899
|
+
if (z) return;
|
|
1900
|
+
const [R, T, E] = await Promise.allSettled([f.ctx.call("delegate.status"), f.ctx.call("delegate.list"), f.ctx.call("delegate.jobs.list")]);
|
|
1901
|
+
if (!z) {
|
|
1902
|
+
R.status === "fulfilled" && (i.value = R.value), T.status === "fulfilled" && (n.value = (T.value.delegations ?? []).filter((J) => !J.revoked)), E.status === "fulfilled" && (u.value = E.value.jobs ?? []);
|
|
1903
|
+
for (const J of [R, T, E]) if (J.status === "rejected") throw J.reason;
|
|
1761
1904
|
}
|
|
1762
1905
|
}
|
|
1763
|
-
async function
|
|
1764
|
-
if (!(
|
|
1765
|
-
|
|
1906
|
+
async function j(R) {
|
|
1907
|
+
if (!(r.value || z)) {
|
|
1908
|
+
r.value = !0, v.value = void 0;
|
|
1766
1909
|
try {
|
|
1767
|
-
await
|
|
1768
|
-
} catch (
|
|
1769
|
-
|
|
1910
|
+
await R();
|
|
1911
|
+
} catch (T) {
|
|
1912
|
+
z || (v.value = T);
|
|
1770
1913
|
} finally {
|
|
1771
|
-
|
|
1914
|
+
z || (r.value = !1);
|
|
1772
1915
|
}
|
|
1773
1916
|
}
|
|
1774
1917
|
}
|
|
1775
|
-
const
|
|
1776
|
-
await
|
|
1777
|
-
}),
|
|
1778
|
-
const
|
|
1779
|
-
|
|
1780
|
-
}),
|
|
1781
|
-
|
|
1782
|
-
}),
|
|
1783
|
-
const
|
|
1784
|
-
return Number.isNaN(
|
|
1918
|
+
const te = () => j(H), se = (R) => j(async () => {
|
|
1919
|
+
await f.ctx.call("delegate.revoke", { delegation_id: R }), await H();
|
|
1920
|
+
}), Q = (R) => j(async () => {
|
|
1921
|
+
const T = await f.ctx.call("delegate.jobs.cancel", { id: R });
|
|
1922
|
+
z || (k.value = T.revocation_pending ? a.value.pending : ""), await H();
|
|
1923
|
+
}), Y = L(() => i.value?.state === "ready" && !!S.value && !!c.value && !!w.value), G = () => j(async () => {
|
|
1924
|
+
Y.value && (await f.ctx.call("delegate.jobs.submit", { key: N ?? (N = crypto.randomUUID()), url: c.value, dest: S.value, name: w.value }), z || (c.value = "", w.value = "", S.value = ""), await H());
|
|
1925
|
+
}), le = (R) => {
|
|
1926
|
+
const T = new Date(R);
|
|
1927
|
+
return Number.isNaN(T.getTime()) ? "—" : T.toLocaleString(f.ctx.locale);
|
|
1785
1928
|
};
|
|
1786
|
-
return
|
|
1787
|
-
|
|
1788
|
-
|
|
1929
|
+
return q({ refresh: te }), ge(() => {
|
|
1930
|
+
te(), M = setInterval(() => {
|
|
1931
|
+
u.value.some(K) && te();
|
|
1789
1932
|
}, 3e3);
|
|
1790
|
-
}),
|
|
1791
|
-
|
|
1792
|
-
}), (
|
|
1933
|
+
}), ye(() => {
|
|
1934
|
+
z = !0, M && clearInterval(M), m.dispose();
|
|
1935
|
+
}), (R, T) => (s(), x(e(he), {
|
|
1793
1936
|
title: a.value.title,
|
|
1937
|
+
description: a.value.help,
|
|
1938
|
+
loading: !i.value && r.value,
|
|
1794
1939
|
collapsible: !1,
|
|
1795
|
-
"aria-busy":
|
|
1940
|
+
"aria-busy": r.value,
|
|
1796
1941
|
class: "delegate-panel"
|
|
1797
1942
|
}, {
|
|
1798
|
-
default:
|
|
1799
|
-
|
|
1800
|
-
r.value && !J.value ? (t(), $(e(Q), {
|
|
1943
|
+
default: l(() => [
|
|
1944
|
+
v.value && !ae.value ? (s(), x(e(X), {
|
|
1801
1945
|
key: 0,
|
|
1802
1946
|
tone: "danger",
|
|
1803
1947
|
role: "alert"
|
|
1804
1948
|
}, {
|
|
1805
|
-
default:
|
|
1806
|
-
g(
|
|
1949
|
+
default: l(() => [
|
|
1950
|
+
g(t(e(oa)(v.value, a.value)), 1)
|
|
1807
1951
|
]),
|
|
1808
1952
|
_: 1
|
|
1809
|
-
})) :
|
|
1810
|
-
|
|
1811
|
-
|
|
1812
|
-
|
|
1813
|
-
|
|
1953
|
+
})) : h("", !0),
|
|
1954
|
+
k.value ? (s(), V("p", jt, t(k.value), 1)) : h("", !0),
|
|
1955
|
+
W.value ? (s(), V("p", el, t(i.value?.state === "needs-admin-approval" ? a.value.needs : a.value.blocked), 1)) : h("", !0),
|
|
1956
|
+
d(e(ze), {
|
|
1957
|
+
direction: "vertical",
|
|
1958
|
+
onSubmit: Se(G, ["prevent"])
|
|
1814
1959
|
}, {
|
|
1815
|
-
default:
|
|
1816
|
-
|
|
1960
|
+
default: l(() => [
|
|
1961
|
+
d(e(fe), {
|
|
1817
1962
|
label: a.value.url,
|
|
1818
1963
|
"label-for": "delegate-url"
|
|
1819
1964
|
}, {
|
|
1820
|
-
default:
|
|
1821
|
-
|
|
1965
|
+
default: l(() => [
|
|
1966
|
+
d(e(_e), {
|
|
1822
1967
|
id: "delegate-url",
|
|
1823
|
-
modelValue:
|
|
1824
|
-
"onUpdate:modelValue":
|
|
1968
|
+
modelValue: c.value,
|
|
1969
|
+
"onUpdate:modelValue": T[0] || (T[0] = (E) => c.value = E),
|
|
1825
1970
|
type: "url",
|
|
1826
|
-
disabled:
|
|
1971
|
+
disabled: r.value || i.value?.state !== "ready"
|
|
1827
1972
|
}, null, 8, ["modelValue", "disabled"])
|
|
1828
1973
|
]),
|
|
1829
1974
|
_: 1
|
|
1830
1975
|
}, 8, ["label"]),
|
|
1831
|
-
|
|
1976
|
+
d(e(fe), {
|
|
1832
1977
|
label: a.value.name,
|
|
1833
1978
|
"label-for": "delegate-name"
|
|
1834
1979
|
}, {
|
|
1835
|
-
default:
|
|
1836
|
-
|
|
1980
|
+
default: l(() => [
|
|
1981
|
+
d(e(_e), {
|
|
1837
1982
|
id: "delegate-name",
|
|
1838
|
-
modelValue:
|
|
1839
|
-
"onUpdate:modelValue":
|
|
1983
|
+
modelValue: w.value,
|
|
1984
|
+
"onUpdate:modelValue": T[1] || (T[1] = (E) => w.value = E),
|
|
1840
1985
|
"data-file-name": "",
|
|
1841
|
-
disabled:
|
|
1986
|
+
disabled: r.value || i.value?.state !== "ready"
|
|
1842
1987
|
}, null, 8, ["modelValue", "disabled"])
|
|
1843
1988
|
]),
|
|
1844
1989
|
_: 1
|
|
1845
1990
|
}, 8, ["label"]),
|
|
1846
|
-
|
|
1847
|
-
|
|
1848
|
-
|
|
1849
|
-
|
|
1850
|
-
|
|
1991
|
+
$("p", null, t(a.value.size), 1),
|
|
1992
|
+
S.value ? (s(), V("p", al, [
|
|
1993
|
+
g(t(a.value.destination) + t(o.value), 1),
|
|
1994
|
+
d(e(pe), { path: S.value }, null, 8, ["path"])
|
|
1995
|
+
])) : h("", !0),
|
|
1996
|
+
d(e(Pe), null, {
|
|
1997
|
+
default: l(() => [
|
|
1998
|
+
d(e(U), {
|
|
1851
1999
|
type: "button",
|
|
1852
2000
|
variant: "secondary",
|
|
1853
|
-
disabled:
|
|
1854
|
-
onClick:
|
|
2001
|
+
disabled: r.value || i.value?.state !== "ready",
|
|
2002
|
+
onClick: T[2] || (T[2] = (E) => D.value = !0)
|
|
1855
2003
|
}, {
|
|
1856
|
-
default:
|
|
1857
|
-
g(
|
|
2004
|
+
default: l(() => [
|
|
2005
|
+
g(t(a.value.choose), 1)
|
|
1858
2006
|
]),
|
|
1859
2007
|
_: 1
|
|
1860
2008
|
}, 8, ["disabled"]),
|
|
1861
|
-
|
|
2009
|
+
d(e(U), {
|
|
1862
2010
|
type: "submit",
|
|
1863
2011
|
variant: "primary",
|
|
1864
|
-
disabled:
|
|
2012
|
+
disabled: r.value || !Y.value
|
|
1865
2013
|
}, {
|
|
1866
|
-
default:
|
|
1867
|
-
g(
|
|
2014
|
+
default: l(() => [
|
|
2015
|
+
g(t(a.value.submit), 1)
|
|
1868
2016
|
]),
|
|
1869
2017
|
_: 1
|
|
1870
2018
|
}, 8, ["disabled"])
|
|
@@ -1874,64 +2022,54 @@ const za = ["aria-busy", "aria-label"], Pa = { class: "file-toolbar file-locatio
|
|
|
1874
2022
|
]),
|
|
1875
2023
|
_: 1
|
|
1876
2024
|
}),
|
|
1877
|
-
|
|
1878
|
-
open:
|
|
1879
|
-
"onUpdate:open":
|
|
1880
|
-
locale:
|
|
2025
|
+
d(Te, {
|
|
2026
|
+
open: D.value,
|
|
2027
|
+
"onUpdate:open": T[3] || (T[3] = (E) => D.value = E),
|
|
2028
|
+
locale: y.ctx.locale,
|
|
1881
2029
|
provider: e(m),
|
|
1882
2030
|
mode: "folder",
|
|
1883
|
-
onSelected:
|
|
2031
|
+
onSelected: T[4] || (T[4] = (E) => S.value = E)
|
|
1884
2032
|
}, null, 8, ["open", "locale", "provider"]),
|
|
1885
|
-
|
|
1886
|
-
|
|
1887
|
-
|
|
1888
|
-
|
|
1889
|
-
|
|
1890
|
-
onClick: H
|
|
1891
|
-
}, {
|
|
1892
|
-
default: n(() => [
|
|
1893
|
-
g(l(a.value.refresh), 1)
|
|
1894
|
-
]),
|
|
1895
|
-
_: 1
|
|
1896
|
-
}, 8, ["disabled"])
|
|
1897
|
-
]),
|
|
1898
|
-
!s.value.length && !r.value ? (t(), S("p", Ml, l(a.value.noJobs), 1)) : (t(), S("ul", Kl, [
|
|
1899
|
-
(t(!0), S(Z, null, de(s.value, (U) => (t(), S("li", {
|
|
1900
|
-
key: U.id,
|
|
1901
|
-
"data-job-state": U.state
|
|
2033
|
+
$("h3", null, t(a.value.downloads), 1),
|
|
2034
|
+
!u.value.length && !v.value ? (s(), V("p", tl, t(a.value.noJobs), 1)) : (s(), V("ul", ll, [
|
|
2035
|
+
(s(!0), V(ne, null, ke(u.value, (E) => (s(), V("li", {
|
|
2036
|
+
key: E.id,
|
|
2037
|
+
"data-job-state": E.state
|
|
1902
2038
|
}, [
|
|
1903
|
-
|
|
1904
|
-
role:
|
|
1905
|
-
},
|
|
1906
|
-
|
|
2039
|
+
$("span", {
|
|
2040
|
+
role: E.state === "waiting_executor" ? "status" : void 0
|
|
2041
|
+
}, t(E.name) + " · " + t(a.value[E.state]), 9, nl),
|
|
2042
|
+
K(E) ? (s(), x(e(U), {
|
|
1907
2043
|
key: 0,
|
|
1908
2044
|
variant: "secondary",
|
|
1909
|
-
disabled:
|
|
1910
|
-
onClick: (
|
|
2045
|
+
disabled: r.value,
|
|
2046
|
+
onClick: (J) => Q(E.id)
|
|
1911
2047
|
}, {
|
|
1912
|
-
default:
|
|
1913
|
-
g(
|
|
2048
|
+
default: l(() => [
|
|
2049
|
+
g(t(a.value.cancel), 1)
|
|
1914
2050
|
]),
|
|
1915
2051
|
_: 1
|
|
1916
|
-
}, 8, ["disabled", "onClick"])) :
|
|
1917
|
-
], 8,
|
|
2052
|
+
}, 8, ["disabled", "onClick"])) : h("", !0)
|
|
2053
|
+
], 8, sl))), 128))
|
|
1918
2054
|
])),
|
|
1919
|
-
|
|
1920
|
-
!
|
|
1921
|
-
(
|
|
1922
|
-
key:
|
|
2055
|
+
$("h3", null, t(a.value.delegations), 1),
|
|
2056
|
+
!n.value.length && !v.value ? (s(), V("p", il, t(a.value.noDelegations), 1)) : (s(), V("ul", ol, [
|
|
2057
|
+
(s(!0), V(ne, null, ke(n.value, (E) => (s(), V("li", {
|
|
2058
|
+
key: E.delegation_id
|
|
1923
2059
|
}, [
|
|
1924
|
-
|
|
1925
|
-
|
|
1926
|
-
|
|
2060
|
+
$("div", null, [
|
|
2061
|
+
d(e(pe), {
|
|
2062
|
+
path: E.path
|
|
2063
|
+
}, null, 8, ["path"]),
|
|
2064
|
+
$("p", null, t(a.value.expires) + t(o.value) + t(le(E.expires_at)), 1)
|
|
1927
2065
|
]),
|
|
1928
|
-
|
|
2066
|
+
d(e(U), {
|
|
1929
2067
|
variant: "secondary",
|
|
1930
|
-
disabled:
|
|
1931
|
-
onClick: (
|
|
2068
|
+
disabled: r.value,
|
|
2069
|
+
onClick: (J) => se(E.delegation_id)
|
|
1932
2070
|
}, {
|
|
1933
|
-
default:
|
|
1934
|
-
g(
|
|
2071
|
+
default: l(() => [
|
|
2072
|
+
g(t(a.value.revoke), 1)
|
|
1935
2073
|
]),
|
|
1936
2074
|
_: 1
|
|
1937
2075
|
}, 8, ["disabled", "onClick"])
|
|
@@ -1939,460 +2077,570 @@ const za = ["aria-busy", "aria-label"], Pa = { class: "file-toolbar file-locatio
|
|
|
1939
2077
|
]))
|
|
1940
2078
|
]),
|
|
1941
2079
|
_: 1
|
|
1942
|
-
}, 8, ["title", "aria-busy"]));
|
|
2080
|
+
}, 8, ["title", "description", "loading", "aria-busy"]));
|
|
1943
2081
|
}
|
|
1944
|
-
}),
|
|
1945
|
-
key: 1,
|
|
1946
|
-
role: "status"
|
|
1947
|
-
}, Wl = {
|
|
2082
|
+
}), Yl = /* @__PURE__ */ ue(ul, [["__scopeId", "data-v-c590f505"]]), rl = { class: "save-alert" }, dl = { "data-save-error": "" }, vl = {
|
|
1948
2083
|
key: 2,
|
|
1949
|
-
|
|
1950
|
-
},
|
|
2084
|
+
class: "save-summary"
|
|
2085
|
+
}, cl = ["data-save-status"], pl = {
|
|
1951
2086
|
key: 7,
|
|
1952
|
-
|
|
1953
|
-
},
|
|
1954
|
-
key:
|
|
2087
|
+
class: "save-help"
|
|
2088
|
+
}, fl = {
|
|
2089
|
+
key: 8,
|
|
2090
|
+
class: "save-records"
|
|
2091
|
+
}, yl = { class: "save-record" }, ml = { class: "save-note" }, bl = {
|
|
2092
|
+
key: 9,
|
|
1955
2093
|
class: "save-actions"
|
|
1956
|
-
},
|
|
2094
|
+
}, gl = {
|
|
2095
|
+
key: 11,
|
|
2096
|
+
class: "save-example"
|
|
2097
|
+
}, hl = { class: "save-help" }, kl = { class: "save-actions" }, _l = {
|
|
2098
|
+
key: 12,
|
|
2099
|
+
class: "save-help"
|
|
2100
|
+
}, wl = {
|
|
2101
|
+
key: 13,
|
|
2102
|
+
"data-save-operations": ""
|
|
2103
|
+
}, xl = ["data-save-job", "title"], Cl = {
|
|
2104
|
+
key: 0,
|
|
2105
|
+
class: "save-note"
|
|
2106
|
+
}, $l = {
|
|
2107
|
+
key: 1,
|
|
2108
|
+
class: "save-note"
|
|
2109
|
+
}, Sl = ["data-save-state"], zl = { key: 1 }, Pl = {
|
|
2110
|
+
class: "save-danger",
|
|
2111
|
+
"data-save-danger": ""
|
|
2112
|
+
}, Ve = 10, Vl = /* @__PURE__ */ oe({
|
|
1957
2113
|
__name: "BackgroundSavePanel",
|
|
1958
2114
|
props: {
|
|
1959
2115
|
sdk: {},
|
|
1960
2116
|
admin: { type: Boolean },
|
|
1961
2117
|
locale: {},
|
|
1962
|
-
picker: {}
|
|
2118
|
+
picker: {},
|
|
2119
|
+
pickerErrorText: { type: Function },
|
|
2120
|
+
sampleSave: { type: Boolean }
|
|
1963
2121
|
},
|
|
1964
2122
|
emits: ["authorized"],
|
|
1965
|
-
setup(
|
|
1966
|
-
const a =
|
|
1967
|
-
let
|
|
1968
|
-
const
|
|
1969
|
-
function
|
|
1970
|
-
|
|
2123
|
+
setup(y, { expose: q, emit: f }) {
|
|
2124
|
+
const a = y, o = f, m = b(!1), i = b(""), n = L(() => Ne(a.locale)), u = b(), r = b([]), v = b([]), k = b(!1), D = b(), S = b(""), c = b(!1), w = b([]), z = L(() => a.picker && (u.value?.selection ? ua(a.picker.provider, u.value.selection.root) : u.value?.scopeMode === "install-selected" ? void 0 : a.picker.provider));
|
|
2125
|
+
let M = !1, N;
|
|
2126
|
+
const K = (F) => F.state === "copying" && F.code === "CANCEL_REQUESTED", O = (F) => K(F) ? "canceling" : F.state === "committed" && !F.receipt?.path ? "uncertain" : F.state, Z = (F) => ["queued", "copying"].includes(F.state) && !K(F);
|
|
2127
|
+
function ae() {
|
|
2128
|
+
u.value = void 0, r.value = [], v.value = [], w.value = [], m.value = !1;
|
|
1971
2129
|
}
|
|
1972
|
-
async function
|
|
1973
|
-
const [
|
|
1974
|
-
if (!
|
|
1975
|
-
if (!
|
|
1976
|
-
(
|
|
2130
|
+
async function W() {
|
|
2131
|
+
const [F, ee, A, C] = await Promise.all([a.sdk.status(), a.sdk.list(), a.sdk.operations(), Promise.all((a.picker?.keys ?? []).map((P) => a.sdk.destination(P)))]);
|
|
2132
|
+
if (!M) {
|
|
2133
|
+
if (!F || typeof F.disabled != "boolean" || !Array.isArray(ee) || !Array.isArray(A)) throw { code: "unavailable" };
|
|
2134
|
+
(u.value?.selection?.generation !== F.selection?.generation || u.value?.selection?.scope !== F.selection?.scope) && (m.value = !1), u.value = F, r.value = C.length ? ee.filter((P) => C.some((I) => I.status === "active" && I.destination?.id === P.id)) : ee, v.value = A, w.value = C;
|
|
1977
2135
|
}
|
|
1978
2136
|
}
|
|
1979
|
-
async function
|
|
1980
|
-
if (!(
|
|
1981
|
-
|
|
2137
|
+
async function H(F) {
|
|
2138
|
+
if (!(M || k.value)) {
|
|
2139
|
+
k.value = !0, D.value = void 0, S.value = "", c.value = !1;
|
|
1982
2140
|
try {
|
|
1983
|
-
await
|
|
1984
|
-
} catch (
|
|
1985
|
-
|
|
2141
|
+
await F();
|
|
2142
|
+
} catch (ee) {
|
|
2143
|
+
M || (ae(), D.value = ee);
|
|
1986
2144
|
} finally {
|
|
1987
|
-
|
|
2145
|
+
M || (k.value = !1);
|
|
1988
2146
|
}
|
|
1989
2147
|
}
|
|
1990
2148
|
}
|
|
1991
|
-
const
|
|
1992
|
-
function
|
|
1993
|
-
|
|
2149
|
+
const j = () => H(W);
|
|
2150
|
+
function te(F) {
|
|
2151
|
+
o("authorized", F), j();
|
|
1994
2152
|
}
|
|
1995
|
-
|
|
1996
|
-
|
|
1997
|
-
|
|
1998
|
-
|
|
1999
|
-
await a.sdk.
|
|
2000
|
-
|
|
2001
|
-
|
|
2002
|
-
|
|
2003
|
-
|
|
2004
|
-
|
|
2005
|
-
|
|
2006
|
-
|
|
2007
|
-
await
|
|
2008
|
-
})
|
|
2009
|
-
|
|
2010
|
-
|
|
2011
|
-
|
|
2153
|
+
function se(F) {
|
|
2154
|
+
M || (S.value = "", D.value = F, c.value = !0);
|
|
2155
|
+
}
|
|
2156
|
+
const Q = L(() => c.value ? a.pickerErrorText?.(D.value) ?? Ie(D.value, n.value, "select") : Ie(D.value, n.value)), Y = (F) => H(async () => {
|
|
2157
|
+
if ((await a.sdk.revoke({ delegation_id: F }))?.revoked !== !0) throw { code: "commit-uncertain" };
|
|
2158
|
+
await W(), M || (S.value = n.value.revoked);
|
|
2159
|
+
}), G = (F) => H(async () => {
|
|
2160
|
+
await a.sdk.cancel({ delegation_id: F.delegation_id, job_id: F.job_id }), await W();
|
|
2161
|
+
}), le = () => H(async () => {
|
|
2162
|
+
if (!a.admin || !u.value) return;
|
|
2163
|
+
const F = u.value.disabled;
|
|
2164
|
+
if ((F ? await a.sdk.enable() : await a.sdk.disable())?.disabled !== !F) throw { code: "commit-uncertain" };
|
|
2165
|
+
await W();
|
|
2166
|
+
}), R = (F) => H(async () => {
|
|
2167
|
+
const ee = "example-" + Array.from(crypto.getRandomValues(new Uint8Array(16)), (A) => A.toString(16).padStart(2, "0")).join("");
|
|
2168
|
+
await a.sdk.exportExample({ key: F, job_id: ee }), await W();
|
|
2169
|
+
}), T = b(1), E = L(() => v.value.slice((T.value - 1) * Ve, T.value * Ve)), J = L(() => [{ key: "name", label: n.value.file }, { key: "state", label: n.value.status, width: "6.5rem" }, { key: "size", label: n.value.size, width: "6rem", align: "right" }, { key: "location", label: n.value.location, width: "30%" }, { key: "actions", label: "", width: "7.5rem" }]), re = (F) => ({ committed: "success", canceled: "neutral", canceling: "neutral", interrupted: "danger", uncertain: "warning" })[O(F)] ?? "info", we = (F) => F.slice(0, F.lastIndexOf("/")) || "/", xe = L(() => u.value?.scopeMode === "install-selected" && !u.value.selection), ve = L(() => u.value ? u.value.disabled ? "disabled" : xe.value ? "needs-scope" : "enabled" : void 0), ce = (F) => a.picker?.labels?.[F] ? `${n.value.choose}${me.value}${a.picker.labels[F]}` : n.value.choose, de = (F) => a.picker?.labels?.[F] ? `${n.value.example}${me.value}${a.picker.labels[F]}` : n.value.example, me = L(() => He(a.locale));
|
|
2170
|
+
return q({ refresh: j }), ge(() => {
|
|
2171
|
+
j(), N = setInterval(() => {
|
|
2172
|
+
v.value.some(Z) && j();
|
|
2012
2173
|
}, 3e3);
|
|
2013
|
-
}),
|
|
2014
|
-
|
|
2015
|
-
}), (
|
|
2016
|
-
title:
|
|
2174
|
+
}), ye(() => {
|
|
2175
|
+
M = !0, N && clearInterval(N);
|
|
2176
|
+
}), (F, ee) => (s(), x(e(he), {
|
|
2177
|
+
title: n.value.title,
|
|
2178
|
+
description: n.value.help,
|
|
2179
|
+
loading: k.value && !u.value && !D.value,
|
|
2017
2180
|
collapsible: !1,
|
|
2018
|
-
"aria-busy":
|
|
2181
|
+
"aria-busy": k.value,
|
|
2019
2182
|
class: "background-save-panel"
|
|
2020
|
-
}, {
|
|
2021
|
-
default:
|
|
2022
|
-
|
|
2023
|
-
_.value ? (t(), $(e(Q), {
|
|
2183
|
+
}, Xe({
|
|
2184
|
+
default: l(() => [
|
|
2185
|
+
D.value ? (s(), x(e(X), {
|
|
2024
2186
|
key: 0,
|
|
2025
2187
|
tone: "danger",
|
|
2026
2188
|
role: "alert",
|
|
2027
2189
|
class: "save-message"
|
|
2028
2190
|
}, {
|
|
2029
|
-
default:
|
|
2030
|
-
|
|
2191
|
+
default: l(() => [
|
|
2192
|
+
$("span", rl, [
|
|
2193
|
+
$("span", dl, t(Q.value), 1),
|
|
2194
|
+
d(e(U), {
|
|
2195
|
+
variant: "secondary",
|
|
2196
|
+
size: "sm",
|
|
2197
|
+
disabled: k.value,
|
|
2198
|
+
onClick: j
|
|
2199
|
+
}, {
|
|
2200
|
+
default: l(() => [
|
|
2201
|
+
g(t(n.value.retry), 1)
|
|
2202
|
+
]),
|
|
2203
|
+
_: 1
|
|
2204
|
+
}, 8, ["disabled"])
|
|
2205
|
+
])
|
|
2031
2206
|
]),
|
|
2032
2207
|
_: 1
|
|
2033
|
-
})) :
|
|
2034
|
-
|
|
2035
|
-
|
|
2036
|
-
|
|
2037
|
-
|
|
2038
|
-
|
|
2039
|
-
|
|
2040
|
-
|
|
2041
|
-
|
|
2208
|
+
})) : h("", !0),
|
|
2209
|
+
S.value ? (s(), x(e(X), {
|
|
2210
|
+
key: 1,
|
|
2211
|
+
tone: "success",
|
|
2212
|
+
role: "status"
|
|
2213
|
+
}, {
|
|
2214
|
+
default: l(() => [
|
|
2215
|
+
g(t(S.value), 1)
|
|
2216
|
+
]),
|
|
2217
|
+
_: 1
|
|
2218
|
+
})) : h("", !0),
|
|
2219
|
+
u.value ? (s(), V("div", vl, [
|
|
2220
|
+
d(e(Ce), {
|
|
2221
|
+
label: n.value.status,
|
|
2222
|
+
"label-width": "10rem"
|
|
2223
|
+
}, {
|
|
2224
|
+
default: l(() => [
|
|
2225
|
+
$("span", {
|
|
2226
|
+
role: "status",
|
|
2227
|
+
"data-save-status": ve.value
|
|
2228
|
+
}, [
|
|
2229
|
+
d(e($e), {
|
|
2230
|
+
tone: ve.value === "enabled" ? "success" : ve.value === "disabled" ? "neutral" : "warning"
|
|
2231
|
+
}, {
|
|
2232
|
+
default: l(() => [
|
|
2233
|
+
g(t(ve.value === "enabled" ? n.value.statusEnabled : ve.value === "disabled" ? n.value.statusDisabled : n.value.statusNeedsScope), 1)
|
|
2234
|
+
]),
|
|
2235
|
+
_: 1
|
|
2236
|
+
}, 8, ["tone"])
|
|
2237
|
+
], 8, cl)
|
|
2238
|
+
]),
|
|
2239
|
+
_: 1
|
|
2240
|
+
}, 8, ["label"]),
|
|
2241
|
+
u.value.selection ? (s(), x(e(Ce), {
|
|
2242
|
+
key: 0,
|
|
2243
|
+
label: n.value.scope,
|
|
2244
|
+
"label-width": "10rem",
|
|
2245
|
+
"data-save-scope": ""
|
|
2246
|
+
}, {
|
|
2247
|
+
default: l(() => [
|
|
2248
|
+
d(e(pe), {
|
|
2249
|
+
path: u.value.selection.root
|
|
2250
|
+
}, null, 8, ["path"])
|
|
2251
|
+
]),
|
|
2252
|
+
_: 1
|
|
2253
|
+
}, 8, ["label"])) : h("", !0)
|
|
2254
|
+
])) : h("", !0),
|
|
2255
|
+
u.value?.mismatch ? (s(), x(e(X), {
|
|
2256
|
+
key: 3,
|
|
2042
2257
|
tone: "warning"
|
|
2043
2258
|
}, {
|
|
2044
|
-
default:
|
|
2045
|
-
g(
|
|
2259
|
+
default: l(() => [
|
|
2260
|
+
g(t(n.value.scopeMismatch) + " " + t(u.value.preselection) + " → " + t(u.value.selection?.root), 1)
|
|
2046
2261
|
]),
|
|
2047
2262
|
_: 1
|
|
2048
|
-
})) :
|
|
2049
|
-
|
|
2050
|
-
key:
|
|
2263
|
+
})) : h("", !0),
|
|
2264
|
+
xe.value ? (s(), x(e(X), {
|
|
2265
|
+
key: 4,
|
|
2051
2266
|
tone: "warning"
|
|
2052
2267
|
}, {
|
|
2053
|
-
default:
|
|
2054
|
-
g(
|
|
2268
|
+
default: l(() => [
|
|
2269
|
+
g(t(n.value.scopeNeeds), 1)
|
|
2055
2270
|
]),
|
|
2056
2271
|
_: 1
|
|
2057
|
-
})) :
|
|
2058
|
-
|
|
2059
|
-
key:
|
|
2272
|
+
})) : h("", !0),
|
|
2273
|
+
u.value?.disabled ? (s(), x(e(X), {
|
|
2274
|
+
key: 5,
|
|
2060
2275
|
tone: "warning",
|
|
2061
|
-
role: "status",
|
|
2062
2276
|
class: "save-message"
|
|
2063
2277
|
}, {
|
|
2064
|
-
default:
|
|
2065
|
-
g(
|
|
2278
|
+
default: l(() => [
|
|
2279
|
+
g(t(n.value.disabled), 1)
|
|
2066
2280
|
]),
|
|
2067
2281
|
_: 1
|
|
2068
|
-
})) :
|
|
2069
|
-
|
|
2070
|
-
|
|
2071
|
-
|
|
2072
|
-
disabled: v.value,
|
|
2073
|
-
onClick: O
|
|
2074
|
-
}, {
|
|
2075
|
-
default: n(() => [
|
|
2076
|
-
g(l(s.value.refresh), 1)
|
|
2077
|
-
]),
|
|
2078
|
-
_: 1
|
|
2079
|
-
}, 8, ["disabled"]),
|
|
2080
|
-
p.admin && o.value ? (t(), $(e(A), {
|
|
2081
|
-
key: 0,
|
|
2082
|
-
variant: o.value.disabled ? "secondary" : "danger",
|
|
2083
|
-
disabled: v.value,
|
|
2084
|
-
onClick: ee
|
|
2085
|
-
}, {
|
|
2086
|
-
default: n(() => [
|
|
2087
|
-
g(l(o.value.disabled ? s.value.enable : s.value.disable), 1)
|
|
2088
|
-
]),
|
|
2089
|
-
_: 1
|
|
2090
|
-
}, 8, ["variant", "disabled"])) : k("", !0)
|
|
2091
|
-
]),
|
|
2092
|
-
p.admin && o.value ? (t(), S("p", at, l(s.value.disableHelp), 1)) : k("", !0),
|
|
2093
|
-
C("h3", null, l(s.value.delegations), 1),
|
|
2094
|
-
x.value.some((w) => w.status === "reselection-required") ? (t(), $(e(Q), {
|
|
2095
|
-
key: 9,
|
|
2282
|
+
})) : h("", !0),
|
|
2283
|
+
$("h3", null, t(n.value.delegations), 1),
|
|
2284
|
+
w.value.some((A) => A.status === "reselection-required") ? (s(), x(e(X), {
|
|
2285
|
+
key: 6,
|
|
2096
2286
|
tone: "warning"
|
|
2097
2287
|
}, {
|
|
2098
|
-
default:
|
|
2099
|
-
g(
|
|
2288
|
+
default: l(() => [
|
|
2289
|
+
g(t(n.value.reselect), 1)
|
|
2100
2290
|
]),
|
|
2101
2291
|
_: 1
|
|
2102
|
-
})) :
|
|
2103
|
-
|
|
2104
|
-
|
|
2105
|
-
|
|
2106
|
-
|
|
2107
|
-
disabled: v.value || !o.value || o.value.disabled || !b.value,
|
|
2108
|
-
onClick: (U) => {
|
|
2109
|
-
d.value = w, i.value = !0;
|
|
2110
|
-
}
|
|
2111
|
-
}, {
|
|
2112
|
-
default: n(() => [
|
|
2113
|
-
g(l(s.value.choose) + " (" + l(w) + ")", 1)
|
|
2114
|
-
]),
|
|
2115
|
-
_: 2
|
|
2116
|
-
}, 1032, ["disabled", "onClick"]))), 128))
|
|
2117
|
-
])) : k("", !0),
|
|
2118
|
-
b.value ? (t(), $(_e, {
|
|
2119
|
-
key: o.value?.selection?.scope,
|
|
2120
|
-
open: i.value,
|
|
2121
|
-
"onUpdate:open": B[0] || (B[0] = (w) => i.value = w),
|
|
2122
|
-
provider: b.value,
|
|
2123
|
-
locale: p.locale,
|
|
2124
|
-
mode: "folder",
|
|
2125
|
-
destination: { key: d.value, selectDestination: p.sdk.selectDestination },
|
|
2126
|
-
onAuthorized: H
|
|
2127
|
-
}, null, 8, ["open", "provider", "locale", "destination"])) : k("", !0),
|
|
2128
|
-
o.value && !r.value.length ? (t(), S("p", tt, l(s.value.empty), 1)) : k("", !0),
|
|
2129
|
-
C("ul", nt, [
|
|
2130
|
-
(t(!0), S(Z, null, de(r.value, (w) => (t(), S("li", {
|
|
2131
|
-
key: w.id
|
|
2292
|
+
})) : h("", !0),
|
|
2293
|
+
u.value && !r.value.length ? (s(), V("p", pl, t(n.value.empty), 1)) : h("", !0),
|
|
2294
|
+
r.value.length ? (s(), V("ul", fl, [
|
|
2295
|
+
(s(!0), V(ne, null, ke(r.value, (A) => (s(), V("li", {
|
|
2296
|
+
key: A.id
|
|
2132
2297
|
}, [
|
|
2133
|
-
|
|
2134
|
-
|
|
2135
|
-
|
|
2298
|
+
$("div", yl, [
|
|
2299
|
+
d(e(pe), {
|
|
2300
|
+
path: A.path
|
|
2301
|
+
}, null, 8, ["path"]),
|
|
2302
|
+
$("span", ml, t(n.value.untilRevoked), 1)
|
|
2136
2303
|
]),
|
|
2137
|
-
|
|
2304
|
+
d(e(U), {
|
|
2138
2305
|
variant: "secondary",
|
|
2139
|
-
disabled:
|
|
2140
|
-
onClick: (
|
|
2306
|
+
disabled: k.value,
|
|
2307
|
+
onClick: (C) => Y(A.id)
|
|
2141
2308
|
}, {
|
|
2142
|
-
default:
|
|
2143
|
-
g(
|
|
2309
|
+
default: l(() => [
|
|
2310
|
+
g(t(n.value.revoke), 1)
|
|
2144
2311
|
]),
|
|
2145
2312
|
_: 1
|
|
2146
2313
|
}, 8, ["disabled", "onClick"])
|
|
2147
2314
|
]))), 128))
|
|
2148
|
-
]),
|
|
2149
|
-
|
|
2150
|
-
|
|
2151
|
-
|
|
2152
|
-
|
|
2153
|
-
|
|
2315
|
+
])) : h("", !0),
|
|
2316
|
+
y.picker ? (s(), V("div", bl, [
|
|
2317
|
+
(s(!0), V(ne, null, ke(y.picker.keys, (A) => (s(), x(e(U), {
|
|
2318
|
+
key: A,
|
|
2319
|
+
variant: "secondary",
|
|
2320
|
+
disabled: k.value || !u.value || u.value.disabled || !z.value,
|
|
2321
|
+
onClick: (C) => {
|
|
2322
|
+
i.value = A, m.value = !0;
|
|
2323
|
+
}
|
|
2324
|
+
}, {
|
|
2325
|
+
default: l(() => [
|
|
2326
|
+
g(t(ce(A)), 1)
|
|
2327
|
+
]),
|
|
2328
|
+
_: 2
|
|
2329
|
+
}, 1032, ["disabled", "onClick"]))), 128))
|
|
2330
|
+
])) : h("", !0),
|
|
2331
|
+
z.value ? (s(), x(Te, {
|
|
2332
|
+
key: u.value?.selection?.scope,
|
|
2333
|
+
open: m.value,
|
|
2334
|
+
"onUpdate:open": ee[0] || (ee[0] = (A) => m.value = A),
|
|
2335
|
+
provider: z.value,
|
|
2336
|
+
locale: y.locale,
|
|
2337
|
+
mode: "folder",
|
|
2338
|
+
destination: { key: i.value, selectDestination: y.sdk.selectDestination },
|
|
2339
|
+
onAuthorized: te,
|
|
2340
|
+
onRefused: se,
|
|
2341
|
+
"error-text": y.pickerErrorText
|
|
2342
|
+
}, null, 8, ["open", "provider", "locale", "destination", "error-text"])) : h("", !0),
|
|
2343
|
+
y.sampleSave && w.value.some((A) => A.status === "active") ? (s(), V("div", gl, [
|
|
2344
|
+
$("p", hl, t(n.value.exampleHelp), 1),
|
|
2345
|
+
$("div", kl, [
|
|
2346
|
+
(s(!0), V(ne, null, ke(w.value.filter((A) => A.status === "active"), (A) => (s(), x(e(U), {
|
|
2347
|
+
key: A.key,
|
|
2154
2348
|
variant: "secondary",
|
|
2155
|
-
disabled:
|
|
2156
|
-
onClick: (
|
|
2349
|
+
disabled: k.value || u.value?.disabled,
|
|
2350
|
+
onClick: (C) => R(A.key)
|
|
2157
2351
|
}, {
|
|
2158
|
-
default:
|
|
2159
|
-
g(
|
|
2352
|
+
default: l(() => [
|
|
2353
|
+
g(t(de(A.key)), 1)
|
|
2160
2354
|
]),
|
|
2161
2355
|
_: 2
|
|
2162
2356
|
}, 1032, ["disabled", "onClick"]))), 128))
|
|
2163
2357
|
])
|
|
2164
|
-
]
|
|
2165
|
-
|
|
2166
|
-
|
|
2167
|
-
|
|
2168
|
-
(
|
|
2169
|
-
|
|
2170
|
-
|
|
2171
|
-
"
|
|
2172
|
-
},
|
|
2173
|
-
|
|
2174
|
-
|
|
2175
|
-
|
|
2176
|
-
|
|
2177
|
-
|
|
2178
|
-
|
|
2179
|
-
|
|
2180
|
-
|
|
2358
|
+
])) : h("", !0),
|
|
2359
|
+
$("h3", null, t(n.value.operations), 1),
|
|
2360
|
+
u.value && !v.value.length ? (s(), V("p", _l, t(n.value.noOperations), 1)) : h("", !0),
|
|
2361
|
+
v.value.length ? (s(), V("div", wl, [
|
|
2362
|
+
d(e(Ca), {
|
|
2363
|
+
columns: J.value,
|
|
2364
|
+
rows: E.value,
|
|
2365
|
+
"row-key": "job_id"
|
|
2366
|
+
}, {
|
|
2367
|
+
"cell-name": l(({ row: A }) => [
|
|
2368
|
+
$("span", {
|
|
2369
|
+
class: "save-name",
|
|
2370
|
+
"data-save-job": A.job_id,
|
|
2371
|
+
title: A.name
|
|
2372
|
+
}, t(A.name), 9, xl),
|
|
2373
|
+
O(A) === "uncertain" ? (s(), V("p", Cl, t(n.value.uncertainHelp), 1)) : O(A) === "interrupted" ? (s(), V("p", $l, t(A.code ? e(Ie)({ code: A.code }, n.value) : n.value.interruptedHelp), 1)) : h("", !0)
|
|
2374
|
+
]),
|
|
2375
|
+
"cell-state": l(({ row: A }) => [
|
|
2376
|
+
$("span", {
|
|
2377
|
+
"data-save-state": O(A)
|
|
2378
|
+
}, [
|
|
2379
|
+
d(e($e), {
|
|
2380
|
+
tone: re(A)
|
|
2381
|
+
}, {
|
|
2382
|
+
default: l(() => [
|
|
2383
|
+
g(t(n.value[O(A)]), 1)
|
|
2384
|
+
]),
|
|
2385
|
+
_: 2
|
|
2386
|
+
}, 1032, ["tone"])
|
|
2387
|
+
], 8, Sl)
|
|
2388
|
+
]),
|
|
2389
|
+
"cell-size": l(({ row: A }) => [
|
|
2390
|
+
g(t(A.receipt?.size !== void 0 ? e($a)(A.receipt.size) : "—"), 1)
|
|
2391
|
+
]),
|
|
2392
|
+
"cell-location": l(({ row: A }) => [
|
|
2393
|
+
O(A) === "committed" ? (s(), x(e(pe), {
|
|
2394
|
+
key: 0,
|
|
2395
|
+
path: A.receipt.path
|
|
2396
|
+
}, null, 8, ["path"])) : (s(), V("span", zl, "—"))
|
|
2397
|
+
]),
|
|
2398
|
+
"cell-actions": l(({ row: A }) => [
|
|
2399
|
+
O(A) === "committed" ? (s(), x(e(U), {
|
|
2400
|
+
key: 0,
|
|
2401
|
+
variant: "ghost",
|
|
2402
|
+
size: "sm",
|
|
2403
|
+
"aria-label": n.value.openFolder,
|
|
2404
|
+
title: n.value.openFolder,
|
|
2405
|
+
onClick: (C) => e(ra)(we(A.receipt.path))
|
|
2181
2406
|
}, {
|
|
2182
|
-
default:
|
|
2183
|
-
|
|
2407
|
+
default: l(() => [
|
|
2408
|
+
d(e(Ua), {
|
|
2409
|
+
class: "save-icon",
|
|
2410
|
+
"aria-hidden": "true"
|
|
2411
|
+
})
|
|
2184
2412
|
]),
|
|
2185
2413
|
_: 1
|
|
2186
|
-
}
|
|
2187
|
-
|
|
2188
|
-
|
|
2189
|
-
|
|
2414
|
+
}, 8, ["aria-label", "title", "onClick"])) : h("", !0),
|
|
2415
|
+
Z(A) ? (s(), x(e(U), {
|
|
2416
|
+
key: 1,
|
|
2417
|
+
variant: "secondary",
|
|
2418
|
+
size: "sm",
|
|
2419
|
+
disabled: k.value,
|
|
2420
|
+
onClick: (C) => G(A)
|
|
2190
2421
|
}, {
|
|
2191
|
-
default:
|
|
2192
|
-
g(
|
|
2422
|
+
default: l(() => [
|
|
2423
|
+
g(t(n.value.cancel), 1)
|
|
2193
2424
|
]),
|
|
2194
2425
|
_: 1
|
|
2195
|
-
})) :
|
|
2196
|
-
E(w) === "interrupted" && w.code ? (t(), S("p", dt, l(e(Ve)({ code: w.code }, s.value)), 1)) : k("", !0)
|
|
2426
|
+
}, 8, ["disabled", "onClick"])) : h("", !0)
|
|
2197
2427
|
]),
|
|
2198
|
-
|
|
2199
|
-
|
|
2200
|
-
|
|
2201
|
-
|
|
2202
|
-
|
|
2428
|
+
_: 1
|
|
2429
|
+
}, 8, ["columns", "rows"]),
|
|
2430
|
+
v.value.length > Ve ? (s(), x(e(Sa), {
|
|
2431
|
+
key: 0,
|
|
2432
|
+
modelValue: T.value,
|
|
2433
|
+
"onUpdate:modelValue": ee[1] || (ee[1] = (A) => T.value = A),
|
|
2434
|
+
total: v.value.length,
|
|
2435
|
+
"page-size": Ve,
|
|
2436
|
+
class: "save-pages"
|
|
2437
|
+
}, null, 8, ["modelValue", "total"])) : h("", !0)
|
|
2438
|
+
])) : h("", !0)
|
|
2439
|
+
]),
|
|
2440
|
+
_: 2
|
|
2441
|
+
}, [
|
|
2442
|
+
y.admin && u.value ? {
|
|
2443
|
+
name: "footer",
|
|
2444
|
+
fn: l(() => [
|
|
2445
|
+
$("div", Pl, [
|
|
2446
|
+
$("p", null, t(n.value.disableHelp), 1),
|
|
2447
|
+
d(e(U), {
|
|
2448
|
+
variant: u.value.disabled ? "secondary" : "danger",
|
|
2449
|
+
disabled: k.value,
|
|
2450
|
+
onClick: le
|
|
2203
2451
|
}, {
|
|
2204
|
-
default:
|
|
2205
|
-
g(
|
|
2452
|
+
default: l(() => [
|
|
2453
|
+
g(t(u.value.disabled ? n.value.enable : n.value.disable), 1)
|
|
2206
2454
|
]),
|
|
2207
2455
|
_: 1
|
|
2208
|
-
}, 8, ["
|
|
2209
|
-
]
|
|
2210
|
-
])
|
|
2211
|
-
|
|
2212
|
-
|
|
2213
|
-
|
|
2456
|
+
}, 8, ["variant", "disabled"])
|
|
2457
|
+
])
|
|
2458
|
+
]),
|
|
2459
|
+
key: "0"
|
|
2460
|
+
} : void 0
|
|
2461
|
+
]), 1032, ["title", "description", "loading", "aria-busy"]));
|
|
2214
2462
|
}
|
|
2215
|
-
}),
|
|
2216
|
-
function
|
|
2217
|
-
const
|
|
2218
|
-
if (!
|
|
2219
|
-
return
|
|
2463
|
+
}), Zl = /* @__PURE__ */ ue(Vl, [["__scopeId", "data-v-5ef5e256"]]), ea = /* @__PURE__ */ Symbol("authorization");
|
|
2464
|
+
function Il() {
|
|
2465
|
+
const y = Ge(ea, void 0);
|
|
2466
|
+
if (!y) throw Error("authorization controls must be placed inside AuthorizationGate");
|
|
2467
|
+
return y;
|
|
2220
2468
|
}
|
|
2221
|
-
const
|
|
2469
|
+
const Tl = { class: "authorization-content" }, El = ["aria-busy", "data-authorization-state"], Ul = { class: "authorization-body" }, Al = /* @__PURE__ */ oe({
|
|
2222
2470
|
__name: "AuthorizationGate",
|
|
2223
2471
|
props: {
|
|
2224
2472
|
ctx: {},
|
|
2225
2473
|
name: {}
|
|
2226
2474
|
},
|
|
2227
2475
|
emits: ["ready"],
|
|
2228
|
-
setup(
|
|
2229
|
-
const
|
|
2230
|
-
let
|
|
2231
|
-
const
|
|
2232
|
-
function
|
|
2233
|
-
if (!
|
|
2234
|
-
return
|
|
2476
|
+
setup(y, { emit: q }) {
|
|
2477
|
+
const f = y, a = q, o = b(), m = b(), i = b(!1), n = b(!1), u = b(!1);
|
|
2478
|
+
let r = [], v = !1, k = 0, D = !1, S;
|
|
2479
|
+
const c = L(() => da(f.ctx.locale, f.name ?? f.ctx.displayName ?? "")), w = L(() => o.value || m.value), z = L(() => w.value?.state === "authorization_required"), M = L(() => ["helper_untrusted", "cli_untrusted"].includes(w.value?.reason || "")), N = L(() => z.value && !M.value), K = L(() => w.value?.reason === "credential_not_ready" ? "credential" : "unavailable"), O = L(() => w.value ? z.value ? c.value("title") : w.value.state === "ready" ? c.value("ready") : w.value.state === "not_admin" ? c.value("not_admin.title") : w.value.state === "session_expired" ? c.value("session_expired.title") : c.value(K.value + ".title") : c.value("checking")), Z = L(() => z.value ? c.value("purpose") : w.value?.state === "not_admin" ? c.value("not_admin.body") : w.value?.state === "session_expired" ? c.value("session_expired.body") : w.value?.state === "unavailable" ? c.value(K.value + ".body") : c.value("purpose")), ae = ["grant_missing", "upgrade_reapproval", "helper_untrusted", "cli_untrusted", "grant_incompatible", "package_identity_changed", "maintenance_task_missing", "maintenance_task_mismatch", "helper_health_rejected", "capability_missing"], W = L(() => ae.includes(w.value?.reason || "") ? w.value.reason : "unknown"), H = L(() => M.value ? "next.reinstall" : W.value === "grant_missing" ? "next.install" : W.value === "upgrade_reapproval" || W.value === "grant_incompatible" ? "next.update" : "next.repair");
|
|
2480
|
+
function j(R) {
|
|
2481
|
+
if (!R || R.command !== "authorization" || R.schema_version !== 1 || !["ready", "authorization_required", "not_admin", "session_expired", "unavailable"].includes(R.state) || R.reason === "upgrade_reapproval" && R.state !== "authorization_required") throw Error("invalid status");
|
|
2482
|
+
return R;
|
|
2235
2483
|
}
|
|
2236
|
-
const
|
|
2237
|
-
async function
|
|
2238
|
-
const
|
|
2239
|
-
for (let
|
|
2484
|
+
const te = [1e3, 3e3];
|
|
2485
|
+
async function se(R) {
|
|
2486
|
+
const T = R === "status" && !u.value ? te : [];
|
|
2487
|
+
for (let E = 0; ; E++) {
|
|
2240
2488
|
try {
|
|
2241
|
-
const
|
|
2242
|
-
if (
|
|
2243
|
-
} catch (
|
|
2244
|
-
if (
|
|
2489
|
+
const J = j(await f.ctx.authorization?.[R]());
|
|
2490
|
+
if (J.state !== "unavailable" || E >= T.length) return J;
|
|
2491
|
+
} catch (J) {
|
|
2492
|
+
if (J.code === "session_required" || E >= T.length) throw J;
|
|
2245
2493
|
}
|
|
2246
|
-
if (await new Promise((
|
|
2494
|
+
if (await new Promise((J) => setTimeout(J, T[E])), v) throw Error("disposed");
|
|
2247
2495
|
}
|
|
2248
2496
|
}
|
|
2249
|
-
async function
|
|
2250
|
-
if (
|
|
2251
|
-
const
|
|
2252
|
-
|
|
2497
|
+
async function Q(R) {
|
|
2498
|
+
if (i.value || v) return;
|
|
2499
|
+
const T = ++k;
|
|
2500
|
+
m.value = R === "request" && o.value?.state === "authorization_required" ? o.value : void 0, i.value = !0, n.value = !1, o.value = void 0;
|
|
2253
2501
|
try {
|
|
2254
|
-
const
|
|
2255
|
-
if (v ||
|
|
2256
|
-
|
|
2257
|
-
} catch (
|
|
2258
|
-
!v &&
|
|
2502
|
+
const E = await se(R);
|
|
2503
|
+
if (v || T !== k) return;
|
|
2504
|
+
o.value = E, u.value = E.state !== "ready", E.state === "ready" && Y(!0), E.state === "ready" && a("ready");
|
|
2505
|
+
} catch (E) {
|
|
2506
|
+
!v && T === k && (o.value = E.code === "session_required" ? { command: "authorization", schema_version: 1, state: "session_expired", reason: "session_expired" } : m.value || { command: "authorization", schema_version: 1, state: "unavailable", reason: "service_unavailable" }, n.value = !0, u.value = !0);
|
|
2259
2507
|
} finally {
|
|
2260
|
-
!v &&
|
|
2508
|
+
!v && T === k && (i.value = !1, m.value = void 0, D && (D = !1, Q("status")));
|
|
2261
2509
|
}
|
|
2262
2510
|
}
|
|
2263
|
-
function
|
|
2264
|
-
const
|
|
2265
|
-
|
|
2511
|
+
function Y(R) {
|
|
2512
|
+
const T = r;
|
|
2513
|
+
r = [], T.forEach((E) => E(R));
|
|
2266
2514
|
}
|
|
2267
|
-
function
|
|
2268
|
-
|
|
2515
|
+
function G(R) {
|
|
2516
|
+
u.value = R, R || Y(!1);
|
|
2269
2517
|
}
|
|
2270
|
-
function
|
|
2271
|
-
return
|
|
2518
|
+
function le() {
|
|
2519
|
+
return o.value?.state === "ready" ? Promise.resolve(!0) : (i.value || (u.value = !0), new Promise((R) => r.push(R)));
|
|
2272
2520
|
}
|
|
2273
|
-
return
|
|
2274
|
-
|
|
2275
|
-
|
|
2276
|
-
}),
|
|
2277
|
-
}),
|
|
2278
|
-
v = !0,
|
|
2279
|
-
}), (
|
|
2280
|
-
|
|
2281
|
-
|
|
2521
|
+
return fa(ea, { state: L(() => o.value?.state ?? "checking"), requireAuthorization: le, text: c, busy: i, canManage: () => !!f.ctx.authorization?.canManage?.(), revoke: () => Q("revoke") }), ge(() => {
|
|
2522
|
+
S = f.ctx.reopen(() => {
|
|
2523
|
+
i.value ? D = !0 : Q("status");
|
|
2524
|
+
}), Q("status");
|
|
2525
|
+
}), Qe(() => {
|
|
2526
|
+
v = !0, k++, Y(!1), typeof S == "function" && S();
|
|
2527
|
+
}), (R, T) => (s(), V(ne, null, [
|
|
2528
|
+
$("div", Tl, [
|
|
2529
|
+
De(R.$slots, "default", {}, void 0, !0)
|
|
2282
2530
|
]),
|
|
2283
|
-
|
|
2284
|
-
open:
|
|
2285
|
-
title:
|
|
2531
|
+
d(e(qe), {
|
|
2532
|
+
open: u.value,
|
|
2533
|
+
title: O.value,
|
|
2286
2534
|
width: "480px",
|
|
2287
|
-
"onUpdate:open":
|
|
2535
|
+
"onUpdate:open": G
|
|
2288
2536
|
}, {
|
|
2289
|
-
footer:
|
|
2290
|
-
|
|
2537
|
+
footer: l(() => [
|
|
2538
|
+
N.value ? (s(), x(e(U), {
|
|
2291
2539
|
key: 0,
|
|
2292
2540
|
variant: "primary",
|
|
2293
|
-
loading:
|
|
2294
|
-
disabled:
|
|
2295
|
-
onClick:
|
|
2541
|
+
loading: i.value,
|
|
2542
|
+
disabled: i.value,
|
|
2543
|
+
onClick: T[0] || (T[0] = (E) => Q("request"))
|
|
2296
2544
|
}, {
|
|
2297
|
-
default:
|
|
2298
|
-
g(
|
|
2545
|
+
default: l(() => [
|
|
2546
|
+
g(t(i.value ? c.value("authorizing") : c.value("authorize")), 1)
|
|
2299
2547
|
]),
|
|
2300
2548
|
_: 1
|
|
2301
|
-
}, 8, ["loading", "disabled"])) : (
|
|
2549
|
+
}, 8, ["loading", "disabled"])) : (s(), x(e(U), {
|
|
2302
2550
|
key: 1,
|
|
2303
2551
|
variant: "primary",
|
|
2304
|
-
loading:
|
|
2305
|
-
disabled:
|
|
2306
|
-
onClick:
|
|
2552
|
+
loading: i.value,
|
|
2553
|
+
disabled: i.value,
|
|
2554
|
+
onClick: T[1] || (T[1] = (E) => Q("status"))
|
|
2307
2555
|
}, {
|
|
2308
|
-
default:
|
|
2309
|
-
g(
|
|
2556
|
+
default: l(() => [
|
|
2557
|
+
g(t(i.value ? c.value("checking") : c.value("retry")), 1)
|
|
2310
2558
|
]),
|
|
2311
2559
|
_: 1
|
|
2312
2560
|
}, 8, ["loading", "disabled"]))
|
|
2313
2561
|
]),
|
|
2314
|
-
default:
|
|
2315
|
-
|
|
2562
|
+
default: l(() => [
|
|
2563
|
+
$("div", {
|
|
2316
2564
|
class: "authorization-view",
|
|
2317
|
-
"aria-busy":
|
|
2318
|
-
"data-authorization-state":
|
|
2565
|
+
"aria-busy": i.value,
|
|
2566
|
+
"data-authorization-state": o.value?.state || "checking"
|
|
2319
2567
|
}, [
|
|
2320
|
-
|
|
2321
|
-
|
|
2568
|
+
$("p", Ul, t(Z.value), 1),
|
|
2569
|
+
z.value ? (s(), x(e(X), {
|
|
2322
2570
|
key: 0,
|
|
2323
2571
|
class: "authorization-status",
|
|
2324
|
-
tone: ["grant_missing", "upgrade_reapproval"].includes(
|
|
2325
|
-
title:
|
|
2572
|
+
tone: ["grant_missing", "upgrade_reapproval"].includes(W.value) ? "info" : "warning",
|
|
2573
|
+
title: c.value("reason." + W.value)
|
|
2326
2574
|
}, {
|
|
2327
|
-
default:
|
|
2328
|
-
g(
|
|
2575
|
+
default: l(() => [
|
|
2576
|
+
g(t(c.value(H.value)), 1)
|
|
2329
2577
|
]),
|
|
2330
2578
|
_: 1
|
|
2331
|
-
}, 8, ["tone", "title"])) :
|
|
2332
|
-
|
|
2579
|
+
}, 8, ["tone", "title"])) : h("", !0),
|
|
2580
|
+
n.value ? (s(), x(e(X), {
|
|
2333
2581
|
key: 1,
|
|
2334
2582
|
class: "authorization-failed",
|
|
2335
2583
|
tone: "warning"
|
|
2336
2584
|
}, {
|
|
2337
|
-
default:
|
|
2338
|
-
g(
|
|
2585
|
+
default: l(() => [
|
|
2586
|
+
g(t(c.value("failed")), 1)
|
|
2339
2587
|
]),
|
|
2340
2588
|
_: 1
|
|
2341
|
-
})) :
|
|
2342
|
-
], 8,
|
|
2589
|
+
})) : h("", !0)
|
|
2590
|
+
], 8, El)
|
|
2343
2591
|
]),
|
|
2344
2592
|
_: 1
|
|
2345
2593
|
}, 8, ["open", "title"])
|
|
2346
2594
|
], 64));
|
|
2347
2595
|
}
|
|
2348
|
-
}),
|
|
2596
|
+
}), Wl = /* @__PURE__ */ ue(Al, [["__scopeId", "data-v-e16b5f7d"]]), Dl = { class: "authorization-setting" }, Rl = {
|
|
2349
2597
|
class: "authorization-state",
|
|
2350
2598
|
role: "status"
|
|
2351
|
-
},
|
|
2599
|
+
}, ql = { class: "authorization-revoke-body" }, Bl = /* @__PURE__ */ oe({
|
|
2352
2600
|
__name: "AuthorizationSettings",
|
|
2353
|
-
setup(
|
|
2354
|
-
const { state:
|
|
2355
|
-
return (
|
|
2356
|
-
|
|
2357
|
-
title: e(
|
|
2601
|
+
setup(y) {
|
|
2602
|
+
const { state: q, requireAuthorization: f, text: a, busy: o, canManage: m, revoke: i } = Il(), n = b(!1), u = { checking: "checking", ready: "ready", authorization_required: "state.required", not_admin: "not_admin.title", session_expired: "session_expired.title", unavailable: "state.unavailable" };
|
|
2603
|
+
return (r, v) => (s(), V(ne, null, [
|
|
2604
|
+
d(e(he), {
|
|
2605
|
+
title: e(a)("settings.title"),
|
|
2358
2606
|
collapsible: !1
|
|
2359
2607
|
}, {
|
|
2360
|
-
default:
|
|
2361
|
-
|
|
2362
|
-
label: e(
|
|
2363
|
-
description: e(
|
|
2608
|
+
default: l(() => [
|
|
2609
|
+
d(e(za), {
|
|
2610
|
+
label: e(a)("settings.status"),
|
|
2611
|
+
description: e(a)("purpose"),
|
|
2364
2612
|
align: "center"
|
|
2365
2613
|
}, {
|
|
2366
|
-
default:
|
|
2367
|
-
|
|
2368
|
-
|
|
2369
|
-
e(
|
|
2614
|
+
default: l(() => [
|
|
2615
|
+
$("div", Dl, [
|
|
2616
|
+
$("span", Rl, [
|
|
2617
|
+
e(q) === "ready" ? (s(), x(e(Aa), {
|
|
2370
2618
|
key: 0,
|
|
2371
2619
|
size: 16,
|
|
2372
2620
|
"aria-hidden": "true"
|
|
2373
|
-
})) :
|
|
2374
|
-
g(
|
|
2621
|
+
})) : h("", !0),
|
|
2622
|
+
g(t(e(a)(u[e(q)])), 1)
|
|
2375
2623
|
]),
|
|
2376
|
-
e(
|
|
2624
|
+
e(q) === "ready" && e(m)() ? (s(), x(e(U), {
|
|
2377
2625
|
key: 0,
|
|
2378
2626
|
variant: "secondary",
|
|
2379
|
-
disabled: e(
|
|
2380
|
-
onClick: v[0] || (v[0] = (
|
|
2627
|
+
disabled: e(o),
|
|
2628
|
+
onClick: v[0] || (v[0] = (k) => n.value = !0)
|
|
2381
2629
|
}, {
|
|
2382
|
-
default:
|
|
2383
|
-
g(
|
|
2630
|
+
default: l(() => [
|
|
2631
|
+
g(t(e(a)("revoke")), 1)
|
|
2384
2632
|
]),
|
|
2385
2633
|
_: 1
|
|
2386
|
-
}, 8, ["disabled"])) : e(
|
|
2634
|
+
}, 8, ["disabled"])) : e(q) !== "ready" && e(q) !== "checking" ? (s(), x(e(U), {
|
|
2387
2635
|
key: 1,
|
|
2388
2636
|
variant: "secondary",
|
|
2389
|
-
onClick: v[1] || (v[1] = (
|
|
2637
|
+
onClick: v[1] || (v[1] = (k) => e(f)())
|
|
2390
2638
|
}, {
|
|
2391
|
-
default:
|
|
2392
|
-
g(
|
|
2639
|
+
default: l(() => [
|
|
2640
|
+
g(t(e(a)("settings.details")), 1)
|
|
2393
2641
|
]),
|
|
2394
2642
|
_: 1
|
|
2395
|
-
})) :
|
|
2643
|
+
})) : h("", !0)
|
|
2396
2644
|
])
|
|
2397
2645
|
]),
|
|
2398
2646
|
_: 1
|
|
@@ -2400,99 +2648,105 @@ const ft = { class: "authorization-content" }, pt = ["aria-busy", "data-authoriz
|
|
|
2400
2648
|
]),
|
|
2401
2649
|
_: 1
|
|
2402
2650
|
}, 8, ["title"]),
|
|
2403
|
-
|
|
2404
|
-
open:
|
|
2405
|
-
"onUpdate:open": v[4] || (v[4] = (
|
|
2406
|
-
title: e(
|
|
2651
|
+
d(e(qe), {
|
|
2652
|
+
open: n.value,
|
|
2653
|
+
"onUpdate:open": v[4] || (v[4] = (k) => n.value = k),
|
|
2654
|
+
title: e(a)("revoke.title"),
|
|
2407
2655
|
width: "480px"
|
|
2408
2656
|
}, {
|
|
2409
|
-
footer:
|
|
2410
|
-
|
|
2657
|
+
footer: l(() => [
|
|
2658
|
+
d(e(U), {
|
|
2411
2659
|
variant: "secondary",
|
|
2412
|
-
onClick: v[2] || (v[2] = (
|
|
2660
|
+
onClick: v[2] || (v[2] = (k) => n.value = !1)
|
|
2413
2661
|
}, {
|
|
2414
|
-
default:
|
|
2415
|
-
g(
|
|
2662
|
+
default: l(() => [
|
|
2663
|
+
g(t(e(a)("cancel")), 1)
|
|
2416
2664
|
]),
|
|
2417
2665
|
_: 1
|
|
2418
2666
|
}),
|
|
2419
|
-
|
|
2667
|
+
d(e(U), {
|
|
2420
2668
|
variant: "danger",
|
|
2421
|
-
disabled: e(
|
|
2422
|
-
onClick: v[3] || (v[3] = (
|
|
2423
|
-
|
|
2669
|
+
disabled: e(o),
|
|
2670
|
+
onClick: v[3] || (v[3] = (k) => {
|
|
2671
|
+
n.value = !1, e(i)();
|
|
2424
2672
|
})
|
|
2425
2673
|
}, {
|
|
2426
|
-
default:
|
|
2427
|
-
g(
|
|
2674
|
+
default: l(() => [
|
|
2675
|
+
g(t(e(a)("revoke")), 1)
|
|
2428
2676
|
]),
|
|
2429
2677
|
_: 1
|
|
2430
2678
|
}, 8, ["disabled"])
|
|
2431
2679
|
]),
|
|
2432
|
-
default:
|
|
2433
|
-
|
|
2680
|
+
default: l(() => [
|
|
2681
|
+
$("p", ql, t(e(a)("revoke.body")), 1)
|
|
2434
2682
|
]),
|
|
2435
2683
|
_: 1
|
|
2436
2684
|
}, 8, ["open", "title"])
|
|
2437
2685
|
], 64));
|
|
2438
2686
|
}
|
|
2439
|
-
}),
|
|
2687
|
+
}), jl = /* @__PURE__ */ ue(Bl, [["__scopeId", "data-v-f031e7c7"]]);
|
|
2440
2688
|
export {
|
|
2441
|
-
|
|
2442
|
-
|
|
2443
|
-
|
|
2444
|
-
|
|
2445
|
-
|
|
2446
|
-
|
|
2447
|
-
|
|
2448
|
-
|
|
2449
|
-
|
|
2450
|
-
|
|
2451
|
-
|
|
2452
|
-
|
|
2453
|
-
|
|
2454
|
-
|
|
2455
|
-
|
|
2456
|
-
|
|
2457
|
-
|
|
2458
|
-
|
|
2459
|
-
|
|
2460
|
-
|
|
2461
|
-
|
|
2462
|
-
|
|
2463
|
-
|
|
2464
|
-
|
|
2465
|
-
|
|
2466
|
-
|
|
2467
|
-
|
|
2468
|
-
|
|
2469
|
-
|
|
2470
|
-
|
|
2471
|
-
|
|
2472
|
-
|
|
2473
|
-
|
|
2474
|
-
|
|
2475
|
-
|
|
2476
|
-
|
|
2477
|
-
|
|
2478
|
-
|
|
2479
|
-
|
|
2480
|
-
|
|
2481
|
-
|
|
2482
|
-
|
|
2483
|
-
|
|
2484
|
-
|
|
2485
|
-
|
|
2486
|
-
|
|
2487
|
-
|
|
2488
|
-
|
|
2489
|
-
|
|
2490
|
-
|
|
2491
|
-
|
|
2492
|
-
|
|
2493
|
-
|
|
2494
|
-
|
|
2495
|
-
|
|
2496
|
-
|
|
2497
|
-
|
|
2689
|
+
Kl as AppShell,
|
|
2690
|
+
Wl as AuthorizationGate,
|
|
2691
|
+
jl as AuthorizationSettings,
|
|
2692
|
+
Xl as BackgroundPanel,
|
|
2693
|
+
Zl as BackgroundSavePanel,
|
|
2694
|
+
ts as DEFAULT_REQUEST_TIMEOUT,
|
|
2695
|
+
Yl as DelegatePanel,
|
|
2696
|
+
Ql as ExecutorSettings,
|
|
2697
|
+
Da as ExecutorSetupKey,
|
|
2698
|
+
ls as FILE_STATION_APP,
|
|
2699
|
+
je as FileBrowser,
|
|
2700
|
+
Hl as FilesPage,
|
|
2701
|
+
Jl as LoginPage,
|
|
2702
|
+
Te as NasPicker,
|
|
2703
|
+
Gl as PortalSettings,
|
|
2704
|
+
ss as activePage,
|
|
2705
|
+
ns as authorizationCatalogs,
|
|
2706
|
+
da as authorizationCopy,
|
|
2707
|
+
is as backgroundCatalogs,
|
|
2708
|
+
sa as backgroundCopy,
|
|
2709
|
+
ia as backgroundErrorCopy,
|
|
2710
|
+
os as catalogs,
|
|
2711
|
+
us as clientTimeout,
|
|
2712
|
+
na as createBackgroundPickerProvider,
|
|
2713
|
+
rs as createBackgroundSaveFacade,
|
|
2714
|
+
ds as createFileTransfers,
|
|
2715
|
+
Me as createNasProvider,
|
|
2716
|
+
vs as createPortalAccess,
|
|
2717
|
+
Ml as createSession,
|
|
2718
|
+
cs as decodeResponse,
|
|
2719
|
+
ps as delegateCatalogs,
|
|
2720
|
+
Ke as delegateCopy,
|
|
2721
|
+
fs as encodeRequest,
|
|
2722
|
+
oa as errorCopy,
|
|
2723
|
+
ys as fileStationPath,
|
|
2724
|
+
Ae as format,
|
|
2725
|
+
ms as identityCatalogs,
|
|
2726
|
+
la as identityCopy,
|
|
2727
|
+
He as labelSeparator,
|
|
2728
|
+
bs as mergeCatalogs,
|
|
2729
|
+
gs as nasCatalogs,
|
|
2730
|
+
be as nasCopy,
|
|
2731
|
+
Le as nasErrorCopy,
|
|
2732
|
+
hs as openFileInFileStation,
|
|
2733
|
+
ra as openFolderInFileStation,
|
|
2734
|
+
ks as portalCatalogs,
|
|
2735
|
+
_s as portalMessages,
|
|
2736
|
+
ws as protocolCodes,
|
|
2737
|
+
xs as protocolOps,
|
|
2738
|
+
Cs as protocolSchemas,
|
|
2739
|
+
Be as requestKey,
|
|
2740
|
+
$s as saveCatalogs,
|
|
2741
|
+
Ne as saveCopy,
|
|
2742
|
+
Ie as saveError,
|
|
2743
|
+
ua as scopedPicker,
|
|
2744
|
+
Ss as shellCatalogs,
|
|
2745
|
+
aa as shellCopy,
|
|
2746
|
+
zs as shellPages,
|
|
2747
|
+
ta as uiLocale,
|
|
2748
|
+
Ps as uiLocales,
|
|
2749
|
+
Il as useAuthorization,
|
|
2750
|
+
We as useExecutorSetup,
|
|
2751
|
+
Ra as useNasRequest
|
|
2498
2752
|
};
|