@wssto2/vue-core 0.9.4 → 0.11.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +39 -0
- package/dist/ActionRow.vue_vue_type_script_setup_true_lang-DybAIOHS.js +64 -0
- package/dist/Activity-CdkJW68R.js +169 -0
- package/dist/{AdaptivePageShell.vue_vue_type_script_setup_true_lang-DdJOodn8.js → AdaptivePageShell.vue_vue_type_script_setup_true_lang-D5i77H6S.js} +147 -159
- package/dist/{AsyncSection.vue_vue_type_script_setup_true_lang-BdeOKqz_.js → AsyncSection.vue_vue_type_script_setup_true_lang-DGzQ-Snp.js} +1 -1
- package/dist/BottomDockPortal.vue_vue_type_script_setup_true_lang-DmwR-2SP.js +17 -0
- package/dist/Button.vue_vue_type_script_setup_true_lang-C74hcb0N.js +123 -0
- package/dist/Changes-DxK_QfiB.js +69 -0
- package/dist/{CollectionPage.vue_vue_type_script_setup_true_lang-DHcekGNn.js → CollectionPage.vue_vue_type_script_setup_true_lang-x0jyJ01f.js} +19 -18
- package/dist/{DataTable.vue_vue_type_script_setup_true_lang-8kBsNRuq.js → DataTable.vue_vue_type_script_setup_true_lang-C_ZytnW-.js} +1 -1
- package/dist/{DateField.vue_vue_type_script_setup_true_lang-BhKdCVFn.js → DateField.vue_vue_type_script_setup_true_lang-CeNwBbJT.js} +1 -1
- package/dist/{DeadLetters-Bb5pPlOY.js → DeadLetters-DnA7LP1w.js} +5 -6
- package/dist/DrawnCheck.vue_vue_type_script_setup_true_lang-9DzDJlIA.js +38 -0
- package/dist/FormGroup.vue_vue_type_script_setup_true_lang-D6jYfNjW.js +427 -0
- package/dist/{FormView.vue_vue_type_script_setup_true_lang-aaNnMIOi.js → FormView.vue_vue_type_script_setup_true_lang-DvbPEiNQ.js} +2 -2
- package/dist/{General-BAG7S6wV.js → General-2matxl2Y.js} +23 -24
- package/dist/Highlight.vue_vue_type_script_setup_true_lang-DZGBmwcX.js +29 -0
- package/dist/{IncidentRecord-D8aOpNHo.js → IncidentRecord-Bt3G4HlX.js} +14 -15
- package/dist/{IncidentsList-C0cFl0Db.js → IncidentsList-2iwgqp9J.js} +3 -3
- package/dist/{Modal.vue_vue_type_script_setup_true_lang-BlHhdmMy.js → Modal.vue_vue_type_script_setup_true_lang-DDS0iEnn.js} +9 -8
- package/dist/{NewRolePage-C6Iu-EQJ.js → NewRolePage-DhGFwvk3.js} +4 -4
- package/dist/{NumberField.vue_vue_type_script_setup_true_lang-TGGAq8J-.js → NumberField.vue_vue_type_script_setup_true_lang-B3UrXNqH.js} +1 -1
- package/dist/{PersonAccess.vue_vue_type_script_setup_true_lang-qz1tmYpF.js → PersonAccess.vue_vue_type_script_setup_true_lang-DbGZSNQc.js} +56 -56
- package/dist/ProfilePage-CpuyDBAv.js +685 -0
- package/dist/ProgressTrack.vue_vue_type_script_setup_true_lang-DrOm8k--.js +30 -0
- package/dist/{RecordHeader.vue_vue_type_script_setup_true_lang-B9mN7UxZ.js → RecordHeader.vue_vue_type_script_setup_true_lang-DqGc3Jyo.js} +1 -1
- package/dist/{ResourcePage.vue_vue_type_script_setup_true_lang-Cw8mGf_B.js → ResourcePage.vue_vue_type_script_setup_true_lang-DljhsTU4.js} +3 -3
- package/dist/{RoleEditor.vue_vue_type_script_setup_true_lang-CJPvOVDV.js → RoleEditor.vue_vue_type_script_setup_true_lang-C0FIotFA.js} +11 -12
- package/dist/{RolePage-Dj_ocMnM.js → RolePage-DaNv049g.js} +10 -10
- package/dist/{RolesPage-PXrs4O-1.js → RolesPage-6hlzJes_.js} +6 -6
- package/dist/SearchInput.vue_vue_type_script_setup_true_lang-w4eAqyZ9.js +32 -0
- package/dist/{SectionList.vue_vue_type_script_setup_true_lang-CtdF1zuv.js → SectionList.vue_vue_type_script_setup_true_lang-DR0_NsqC.js} +1 -1
- package/dist/{SectionNavigator.vue_vue_type_script_setup_true_lang-B5ove3rM.js → SectionNavigator.vue_vue_type_script_setup_true_lang-Dh3sXUt_.js} +2 -2
- package/dist/{SegmentedField.vue_vue_type_script_setup_true_lang-ChfDFAA2.js → SegmentedField.vue_vue_type_script_setup_true_lang-zv_AxpBn.js} +1 -1
- package/dist/{SelectField.vue_vue_type_script_setup_true_lang-BP8nAQwo.js → SelectField.vue_vue_type_script_setup_true_lang-BZwdANL3.js} +3 -3
- package/dist/{ServiceAccountDialog.vue_vue_type_script_setup_true_lang-aWkKwxNe.js → ServiceAccountDialog.vue_vue_type_script_setup_true_lang-FJbWxME_.js} +20 -20
- package/dist/{ServiceAccountRecord-bxX9yQkC.js → ServiceAccountRecord-0-JF5lRx.js} +24 -24
- package/dist/{ServiceAccountsList-BXE6htxk.js → ServiceAccountsList-DcsnOcf-.js} +32 -32
- package/dist/{Sessions--Gvc0kxw.js → Sessions-DgWhpk-i.js} +23 -24
- package/dist/{SettingsPage-DzDC7gD-.js → SettingsPage-BXPWATYU.js} +28 -30
- package/dist/{SignIn-CTI_699e.js → SignIn-DPoUwHZd.js} +9 -10
- package/dist/{SignInPage-HKC1bm2E.js → SignInPage-OyrVemro.js} +4 -4
- package/dist/SignIns-BMDrZVVp.js +64 -0
- package/dist/StatusLine.vue_vue_type_script_setup_true_lang-DsdQmLq6.js +56 -0
- package/dist/{SwitchField.vue_vue_type_script_setup_true_lang-BMA2YXTZ.js → SwitchField.vue_vue_type_script_setup_true_lang-Ds4q0bbl.js} +1 -1
- package/dist/{TextField.vue_vue_type_script_setup_true_lang-BFVsqcBX.js → TextField.vue_vue_type_script_setup_true_lang-CWIeeZRE.js} +2 -2
- package/dist/{TextareaField.vue_vue_type_script_setup_true_lang-Dyh4Hhyl.js → TextareaField.vue_vue_type_script_setup_true_lang-D2j4s96s.js} +1 -1
- package/dist/{TimeField.vue_vue_type_script_setup_true_lang-gGFfQLuK.js → TimeField.vue_vue_type_script_setup_true_lang-D-Em4glH.js} +1 -1
- package/dist/UserRecord-BW-gdCqi.js +202 -0
- package/dist/UsersList-B3ZF_1Dj.js +74 -0
- package/dist/access/index.js +4 -4
- package/dist/app/index.d.ts +1 -0
- package/dist/app/index.js +11 -10
- package/dist/app/languages.d.ts +8 -0
- package/dist/{application-BmXW6iW_.js → application-CuzT-0vW.js} +1 -1
- package/dist/button/index.js +6 -5
- package/dist/collection/Highlight.vue.d.ts +12 -0
- package/dist/collection/PickerModal.vue.d.ts +26 -0
- package/dist/collection/definition.d.ts +6 -6
- package/dist/collection/http.d.ts +6 -6
- package/dist/collection/index.d.ts +6 -1
- package/dist/collection/index.js +145 -85
- package/dist/collection/picker.d.ts +39 -0
- package/dist/collection/types.d.ts +9 -4
- package/dist/collection/useCollection.d.ts +5 -5
- package/dist/content/ActivityStream.vue.d.ts +62 -0
- package/dist/content/CommentThread.vue.d.ts +52 -0
- package/dist/content/Composer.vue.d.ts +36 -0
- package/dist/content/index.d.ts +3 -0
- package/dist/content/index.js +321 -56
- package/dist/controls/index.js +28 -54
- package/dist/form/index.js +132 -134
- package/dist/format/index.d.ts +1 -0
- package/dist/format/index.js +10 -6
- package/dist/format/slug.d.ts +8 -0
- package/dist/http-Dm0uXY9O.js +95 -0
- package/dist/i18n/index.d.ts +15 -0
- package/dist/i18n/index.js +89 -63
- package/dist/i18n/plural.d.ts +23 -0
- package/dist/i18n/serverMessages.d.ts +16 -0
- package/dist/identity/embed.d.ts +39 -0
- package/dist/identity/index.d.ts +22 -1
- package/dist/identity/index.js +40 -21
- package/dist/identity/session.d.ts +9 -1
- package/dist/identity/shared/ChangeFeed.vue.d.ts +6 -3
- package/dist/identity/users/context.d.ts +11 -0
- package/dist/identity/users/dialogs.d.ts +10 -0
- package/dist/identity/users/ext.d.ts +8 -0
- package/dist/identity/users/feature.d.ts +22 -1
- package/dist/identity/users/list.d.ts +12 -1
- package/dist/identity/users/personSections.d.ts +15 -6
- package/dist/identity/users/replace.d.ts +45 -0
- package/dist/identity/users/words.d.ts +28 -0
- package/dist/incidents/api.d.ts +1 -1
- package/dist/incidents/index.js +1 -1
- package/dist/{index-Dz0LkLM8.js → index-ClJeyW3F.js} +4 -4
- package/dist/index-Cq9TuOqH.js +1264 -0
- package/dist/{index-Dm-sdJJr.js → index-kEHY7hcG.js} +31 -32
- package/dist/index.d.ts +1 -1
- package/dist/index.js +1 -1
- package/dist/keepAlive-ClGnsIzT.js +55 -0
- package/dist/modal/index.js +3 -3
- package/dist/modules/identity/entities.d.ts +7 -0
- package/dist/modules/identity/routes.d.ts +8 -4
- package/dist/modules/identity/schemas.d.ts +16 -0
- package/dist/{neighbors-DVfU9T0o.js → neighbors-OyvGi233.js} +2 -2
- package/dist/notifications/deadletters/list.d.ts +1 -1
- package/dist/notifications/index.js +1 -1
- package/dist/{options-QuOkMKVZ.js → options-B48UiYsG.js} +2 -2
- package/dist/page/index.js +11 -11
- package/dist/phone/index.js +1 -1
- package/dist/pwa/AndroidInstallBanner.vue.d.ts +18 -0
- package/dist/pwa/InstallQrSheet.vue.d.ts +21 -0
- package/dist/pwa/IosInstallGuide.vue.d.ts +19 -0
- package/dist/pwa/QrCode.vue.d.ts +16 -0
- package/dist/pwa/index.d.ts +4 -0
- package/dist/pwa/index.js +244 -24
- package/dist/resource/index.js +1 -1
- package/dist/rowLayout-BsKEzEME.js +650 -0
- package/dist/shell/DarkModeRow.vue.d.ts +15 -0
- package/dist/shell/OfflineNotice.vue.d.ts +2 -0
- package/dist/shell/QuickSearchButton.vue.d.ts +2 -0
- package/dist/shell/QuickSearchPalette.vue.d.ts +12 -0
- package/dist/shell/darkMode.d.ts +26 -0
- package/dist/shell/index.d.ts +10 -0
- package/dist/shell/index.js +954 -579
- package/dist/shell/offlineNotice.d.ts +3 -0
- package/dist/shell/quickSearch.d.ts +14 -0
- package/dist/shell/quickSearchControl.d.ts +69 -0
- package/dist/shortcut-DUR6yPWA.js +93 -0
- package/dist/state/BackgroundTaskCapsule.vue.d.ts +18 -0
- package/dist/state/backgroundTasks.d.ts +58 -0
- package/dist/state/index.d.ts +4 -0
- package/dist/state/index.js +194 -80
- package/dist/state/useCountUp.d.ts +9 -0
- package/dist/styles.css +1 -1
- package/dist/{suggestions-BVQhoXzS.js → suggestions-q_v3M7G6.js} +1 -1
- package/dist/testing/collection.d.ts +1 -1
- package/dist/{useCommand-Dc8Lgs9h.js → useCommand-Ch_nx1AQ.js} +4 -4
- package/dist/{useGroupSheet-DQ6cVG-z.js → useGroupSheet-CPjHydQV.js} +14 -15
- package/dist/{useRecordDialog-BTsbHY38.js → useRecordDialog-DdkauXnU.js} +1 -1
- package/dist/{useResourceForm-DJ4Q75pq.js → useResourceForm-Dl6YFYyz.js} +1 -1
- package/package.json +3 -2
- package/dist/ActionRow.vue_vue_type_script_setup_true_lang-Cg1lhpcA.js +0 -45
- package/dist/Activity-29hsZ28j.js +0 -156
- package/dist/Button.vue_vue_type_script_setup_true_lang-Dp7OB-eF.js +0 -192
- package/dist/Changes-Dxjdkd_5.js +0 -129
- package/dist/FormErrors.vue_vue_type_script_setup_true_lang-CIggKPtq.js +0 -295
- package/dist/FormGroup.vue_vue_type_script_setup_true_lang-B37dixvJ.js +0 -137
- package/dist/PageBar.vue_vue_type_script_setup_true_lang-qI94fjJv.js +0 -47
- package/dist/ProfilePage-BnohZIEg.js +0 -764
- package/dist/ProgressTrack.vue_vue_type_script_setup_true_lang-B6Prw9hi.js +0 -64
- package/dist/SectionIntro.vue_vue_type_script_setup_true_lang-CZtPrmXD.js +0 -23
- package/dist/SessionList.vue_vue_type_script_setup_true_lang-Cnyt5V8T.js +0 -133
- package/dist/SignIns-BcqBgWgN.js +0 -121
- package/dist/UserRecord-CtUPpbCt.js +0 -267
- package/dist/UsersList-BMkIgIg8.js +0 -155
- package/dist/definition-C7QuyV3i.js +0 -54
- package/dist/http-nz92KjdS.js +0 -42
- package/dist/identity/fieldMessages.d.ts +0 -15
- package/dist/identity/users/languages.d.ts +0 -4
- package/dist/index-CdtofdcJ.js +0 -501
- package/dist/keepAlive-z3IRFkQq.js +0 -46
- package/dist/languages-BShG9LpE.js +0 -10
- package/dist/rowLayout-CT8vWYgI.js +0 -663
- package/dist/signInEvents-DWShrJox.js +0 -30
- package/dist/status-BRA14qwX.js +0 -34
- package/dist/useWaitStatus-fsacMl4W.js +0 -24
- /package/dist/{fieldMessages-B6GHgi40.js → serverMessages-B6GHgi40.js} +0 -0
|
@@ -1,17 +1,16 @@
|
|
|
1
1
|
import { defineComponent as L, useModel as X, useId as Y, useTemplateRef as O, ref as h, computed as w, watch as N, nextTick as z, onMounted as H, openBlock as b, createElementBlock as _, normalizeClass as T, createElementVNode as $, unref as x, Fragment as I, renderList as Z, createTextVNode as ee, toDisplayString as j, createCommentVNode as C, mergeModels as A, onBeforeUnmount as te, createBlock as F, withCtx as E, createVNode as ae, renderSlot as J, provide as K, toRef as se, shallowRef as le, toValue as P } from "vue";
|
|
2
2
|
import { useI18n as Q } from "vue-i18n";
|
|
3
|
-
import { _ as oe } from "./Modal.vue_vue_type_script_setup_true_lang-
|
|
3
|
+
import { _ as oe } from "./Modal.vue_vue_type_script_setup_true_lang-DDS0iEnn.js";
|
|
4
4
|
import { _ as q } from "./Banner.vue_vue_type_script_setup_true_lang-sv0phngk.js";
|
|
5
|
-
import { D as ne } from "./
|
|
6
|
-
import { _ as re, s as U, c as B, f as
|
|
7
|
-
import { d as
|
|
8
|
-
import { r as ce } from "./FormGroup.vue_vue_type_script_setup_true_lang-B37dixvJ.js";
|
|
5
|
+
import { D as ne } from "./shortcut-DUR6yPWA.js";
|
|
6
|
+
import { _ as re, r as ie, s as U, c as B, f as ue } from "./FormGroup.vue_vue_type_script_setup_true_lang-D6jYfNjW.js";
|
|
7
|
+
import { d as ce } from "./options-B48UiYsG.js";
|
|
9
8
|
import { t as de } from "./toast-CqSDTWRX.js";
|
|
10
9
|
import { a as fe } from "./leaveGuard-Cc8yeLxM.js";
|
|
11
10
|
const ve = ["id", "value", "name", "disabled", "aria-label", "aria-invalid", "aria-describedby"], me = {
|
|
12
11
|
key: 1,
|
|
13
12
|
class: "h-5 w-px animate-caret-blink bg-content-strong"
|
|
14
|
-
},
|
|
13
|
+
}, De = /* @__PURE__ */ L({
|
|
15
14
|
__name: "OtpInput",
|
|
16
15
|
props: /* @__PURE__ */ A({
|
|
17
16
|
length: { default: 6 },
|
|
@@ -97,7 +96,7 @@ const ve = ["id", "value", "name", "disabled", "aria-label", "aria-invalid", "ar
|
|
|
97
96
|
], 2))), 128))
|
|
98
97
|
], 34));
|
|
99
98
|
}
|
|
100
|
-
}), pe = { class: "text-footnote" }, be = { class: "text-footnote" },
|
|
99
|
+
}), pe = { class: "text-footnote" }, be = { class: "text-footnote" }, Ge = /* @__PURE__ */ L({
|
|
101
100
|
__name: "GroupSheet",
|
|
102
101
|
props: {
|
|
103
102
|
sheet: {},
|
|
@@ -175,7 +174,7 @@ const ve = ["id", "value", "name", "disabled", "aria-label", "aria-invalid", "ar
|
|
|
175
174
|
_: 3
|
|
176
175
|
}, 8, ["size", "title", "subtitle", "before-dismiss", "primary-label", "status", "processing-label", "done-label"]));
|
|
177
176
|
}
|
|
178
|
-
}), ge = ["data-group"],
|
|
177
|
+
}), ge = ["data-group"], Ve = /* @__PURE__ */ L({
|
|
179
178
|
__name: "RecordGroupScope",
|
|
180
179
|
props: {
|
|
181
180
|
only: {},
|
|
@@ -183,7 +182,7 @@ const ve = ["id", "value", "name", "disabled", "aria-label", "aria-invalid", "ar
|
|
|
183
182
|
},
|
|
184
183
|
setup(l) {
|
|
185
184
|
const a = l;
|
|
186
|
-
return K(
|
|
185
|
+
return K(ie, { only: se(a, "only") }), K(ce, w(() => a.editable)), (t, o) => (b(), _("div", {
|
|
187
186
|
class: "flex min-w-0 flex-col gap-group-gap",
|
|
188
187
|
"data-test": "record-group-scope",
|
|
189
188
|
"data-group": a.only
|
|
@@ -192,7 +191,7 @@ const ve = ["id", "value", "name", "disabled", "aria-label", "aria-invalid", "ar
|
|
|
192
191
|
], 8, ge));
|
|
193
192
|
}
|
|
194
193
|
});
|
|
195
|
-
function
|
|
194
|
+
function ze(l) {
|
|
196
195
|
const { form: a } = l;
|
|
197
196
|
if (l.rebase && !a.rebase) throw new Error("useGroupSheet: `rebase` needs a record form (useResourceForm), which can take the freshly read record as its base.");
|
|
198
197
|
const t = () => typeof l.fields == "function" ? l.fields() : l.fields, o = () => P(l.restore) ?? t(), i = h(!1), d = h(!1), m = h([]), f = h(null), r = le({});
|
|
@@ -214,7 +213,7 @@ function Fe(l) {
|
|
|
214
213
|
function p(s) {
|
|
215
214
|
const e = new Set(t()), n = P(l.group), M = /* @__PURE__ */ new Set();
|
|
216
215
|
for (const W of Object.keys(s.all())) {
|
|
217
|
-
const R =
|
|
216
|
+
const R = ue(W);
|
|
218
217
|
if (e.has(R)) continue;
|
|
219
218
|
const V = l.groupOf?.(R) ?? l.fallbackGroup;
|
|
220
219
|
V && V !== n && M.add(V);
|
|
@@ -271,8 +270,8 @@ function Fe(l) {
|
|
|
271
270
|
};
|
|
272
271
|
}
|
|
273
272
|
export {
|
|
274
|
-
|
|
275
|
-
|
|
276
|
-
|
|
277
|
-
|
|
273
|
+
Ge as _,
|
|
274
|
+
Ve as a,
|
|
275
|
+
De as b,
|
|
276
|
+
ze as u
|
|
278
277
|
};
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { shallowRef as v, watch as m, computed as f } from "vue";
|
|
2
|
-
import { u as i, c as h } from "./
|
|
2
|
+
import { u as i, c as h } from "./FormGroup.vue_vue_type_script_setup_true_lang-D6jYfNjW.js";
|
|
3
3
|
function b(u) {
|
|
4
4
|
const t = i(u), r = v(null), s = v(!1);
|
|
5
5
|
let n = null;
|
package/package.json
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@wssto2/vue-core",
|
|
3
|
-
"version": "0.
|
|
4
|
-
"goCore": "v1.
|
|
3
|
+
"version": "0.11.0",
|
|
4
|
+
"goCore": "v1.15.0",
|
|
5
5
|
"description": "Shared Vue 3 library for go-core applications: app shell, list / record / form pages and their controls.",
|
|
6
6
|
"keywords": [
|
|
7
7
|
"vue",
|
|
@@ -194,6 +194,7 @@
|
|
|
194
194
|
"@floating-ui/dom": "^1.8.0",
|
|
195
195
|
"country-flag-icons": "^1.6.20",
|
|
196
196
|
"libphonenumber-js": "^1.13.14",
|
|
197
|
+
"uqr": "^0.1.3",
|
|
197
198
|
"vue-sonner": "^1.3.2"
|
|
198
199
|
},
|
|
199
200
|
"peerDependenciesMeta": {
|
|
@@ -1,45 +0,0 @@
|
|
|
1
|
-
import { defineComponent as r, openBlock as s, createBlock as d, unref as n, withCtx as f, createElementVNode as t, normalizeClass as m, toDisplayString as l, createElementBlock as u, createCommentVNode as p, createVNode as b } from "vue";
|
|
2
|
-
import { g as _ } from "./options-QuOkMKVZ.js";
|
|
3
|
-
import { _ as x } from "./Icon.vue_vue_type_script_lang-BhhsFYwp.js";
|
|
4
|
-
const k = ["disabled"], y = { class: "flex min-w-0 flex-1 flex-col" }, h = {
|
|
5
|
-
key: 0,
|
|
6
|
-
class: "text-footnote text-content-muted"
|
|
7
|
-
}, N = /* @__PURE__ */ r({
|
|
8
|
-
__name: "ActionRow",
|
|
9
|
-
props: {
|
|
10
|
-
label: {},
|
|
11
|
-
sub: { default: void 0 },
|
|
12
|
-
tone: { default: "link" },
|
|
13
|
-
disabled: { type: Boolean, default: !1 }
|
|
14
|
-
},
|
|
15
|
-
emits: ["click"],
|
|
16
|
-
setup(i, { emit: a }) {
|
|
17
|
-
const e = i, c = a;
|
|
18
|
-
return (v, o) => (s(), d(n(_), { layout: "stacked" }, {
|
|
19
|
-
default: f(() => [
|
|
20
|
-
t("button", {
|
|
21
|
-
type: "button",
|
|
22
|
-
disabled: e.disabled,
|
|
23
|
-
class: "flex w-full items-center gap-3 py-0.5 text-left focus-visible:outline-2 focus-visible:outline-border-focus disabled:opacity-50",
|
|
24
|
-
onClick: o[0] || (o[0] = (w) => c("click"))
|
|
25
|
-
}, [
|
|
26
|
-
t("span", y, [
|
|
27
|
-
t("span", {
|
|
28
|
-
class: m(["text-body", e.tone === "critical" ? "text-content-destructive" : "text-content-link"])
|
|
29
|
-
}, l(e.label), 3),
|
|
30
|
-
e.sub ? (s(), u("span", h, l(e.sub), 1)) : p("", !0)
|
|
31
|
-
]),
|
|
32
|
-
b(n(x), {
|
|
33
|
-
name: "arrowRightSLine",
|
|
34
|
-
size: 18,
|
|
35
|
-
class: "shrink-0 text-content-disabled"
|
|
36
|
-
})
|
|
37
|
-
], 8, k)
|
|
38
|
-
]),
|
|
39
|
-
_: 1
|
|
40
|
-
}));
|
|
41
|
-
}
|
|
42
|
-
});
|
|
43
|
-
export {
|
|
44
|
-
N as _
|
|
45
|
-
};
|
|
@@ -1,156 +0,0 @@
|
|
|
1
|
-
import { defineComponent as S, ref as g, watch as w, computed as k, openBlock as i, createElementBlock as y, createVNode as _, unref as t, createElementVNode as r, withCtx as f, toDisplayString as u, Fragment as C, renderList as N, createBlock as x, createTextVNode as j, createCommentVNode as R } from "vue";
|
|
2
|
-
import { useI18n as q } from "vue-i18n";
|
|
3
|
-
import { _ as D } from "./IconTile.vue_vue_type_script_setup_true_lang-BmxCuUZ9.js";
|
|
4
|
-
import { _ as I } from "./Tabs.vue_vue_type_script_setup_true_lang-tpkGp98F.js";
|
|
5
|
-
import { u as O } from "./format-D8KUBmbS.js";
|
|
6
|
-
import { _ as U } from "./DateField.vue_vue_type_script_setup_true_lang-BhKdCVFn.js";
|
|
7
|
-
import { _ as T } from "./FormGroup.vue_vue_type_script_setup_true_lang-B37dixvJ.js";
|
|
8
|
-
import { g as z } from "./options-QuOkMKVZ.js";
|
|
9
|
-
import { P as G, c as H, i as J } from "./index-CdtofdcJ.js";
|
|
10
|
-
import { u as K } from "./platform-BQOX_Ntw.js";
|
|
11
|
-
import { b as M } from "./routeResource-DlTsGTg_.js";
|
|
12
|
-
import { _ as Q } from "./AsyncSection.vue_vue_type_script_setup_true_lang-BdeOKqz_.js";
|
|
13
|
-
import { _ as W } from "./Badge.vue_vue_type_script_setup_true_lang-DJyZc0C7.js";
|
|
14
|
-
import { u as X } from "./useLoad-M7V-AVwR.js";
|
|
15
|
-
import { _ as Y } from "./PageBar.vue_vue_type_script_setup_true_lang-qI94fjJv.js";
|
|
16
|
-
import { _ as Z } from "./SectionIntro.vue_vue_type_script_setup_true_lang-CZtPrmXD.js";
|
|
17
|
-
const ee = {
|
|
18
|
-
class: "flex min-w-0 flex-col gap-group-gap",
|
|
19
|
-
"data-person-activity": ""
|
|
20
|
-
}, te = { class: "flex flex-wrap items-end justify-between gap-3" }, ae = {
|
|
21
|
-
class: "flex items-end gap-2",
|
|
22
|
-
"data-activity-range": ""
|
|
23
|
-
}, se = {
|
|
24
|
-
key: 0,
|
|
25
|
-
class: "px-row-inset py-4 text-body text-content-muted",
|
|
26
|
-
"data-activity-empty": ""
|
|
27
|
-
}, oe = {
|
|
28
|
-
key: 1,
|
|
29
|
-
class: "flex min-w-0 flex-col gap-group-gap",
|
|
30
|
-
"data-activity-feed": ""
|
|
31
|
-
}, le = { class: "flex flex-wrap items-center gap-x-1.5" }, ne = { class: "text-body tabular-nums text-content-muted" }, ie = { class: "px-row-inset text-footnote text-content-muted" }, we = /* @__PURE__ */ S({
|
|
32
|
-
__name: "Activity",
|
|
33
|
-
setup(re) {
|
|
34
|
-
const { t: o, te: $ } = q(), { http: A } = K(), V = O(), b = M(G), { activityAreas: B } = H(), c = g("all"), d = g(null), m = g(null), v = g(1), p = X(
|
|
35
|
-
async ({ signal: a }) => {
|
|
36
|
-
const e = b.id.value;
|
|
37
|
-
if (e === null) return null;
|
|
38
|
-
const s = { id: e, page: v.value, per_page: 20, ...c.value === "all" ? {} : { area: c.value }, ...d.value ? { from: d.value } : {}, ...m.value ? { to: m.value } : {} };
|
|
39
|
-
return (await A.request(J.usersActivity, s, { signal: a })).data;
|
|
40
|
-
},
|
|
41
|
-
{ watch: () => b.id.value }
|
|
42
|
-
);
|
|
43
|
-
w([c, d, m], () => {
|
|
44
|
-
v.value = 1, p.reload();
|
|
45
|
-
}), w(v, () => void p.reload());
|
|
46
|
-
const h = (a) => {
|
|
47
|
-
if (a === "all" || a === "identity" || a === "other") return o(`core.users.activity.areas.${a}`);
|
|
48
|
-
const e = B[a];
|
|
49
|
-
return e && $(e) ? o(e) : o("core.users.activity.areas.other");
|
|
50
|
-
}, E = k(() => p.data.value?.meta?.views ?? []), P = k(() => {
|
|
51
|
-
const a = E.value.filter((e) => e.key === "all" || e.key === c.value || e.count > 0).map((e) => ({ value: e.key, label: h(e.key), badge: e.count }));
|
|
52
|
-
return a.length > 0 ? a : [{ value: "all", label: h("all") }];
|
|
53
|
-
}), F = (a) => $(`core.users.activity.actions.${a}`) ? o(`core.users.activity.actions.${a}`) : o("core.users.activity.actions.other"), L = k(() => {
|
|
54
|
-
const a = [];
|
|
55
|
-
for (const e of p.data.value?.data ?? []) {
|
|
56
|
-
const s = e.created_at.slice(0, 10), l = a[a.length - 1];
|
|
57
|
-
l && l.key === s ? l.rows.push(e) : a.push({ key: s, header: V.date(e.created_at), rows: [e] });
|
|
58
|
-
}
|
|
59
|
-
return a;
|
|
60
|
-
});
|
|
61
|
-
return (a, e) => (i(), y("div", ee, [
|
|
62
|
-
_(Z, {
|
|
63
|
-
title: t(o)("core.users.sections.activity"),
|
|
64
|
-
description: t(o)("core.users.intro.activity", { name: t(b).data.value?.name ?? "" })
|
|
65
|
-
}, null, 8, ["title", "description"]),
|
|
66
|
-
r("div", te, [
|
|
67
|
-
_(t(I), {
|
|
68
|
-
modelValue: c.value,
|
|
69
|
-
"onUpdate:modelValue": e[0] || (e[0] = (s) => c.value = s),
|
|
70
|
-
tabs: P.value,
|
|
71
|
-
presentation: "scope",
|
|
72
|
-
label: t(o)("core.users.activity.areas_label")
|
|
73
|
-
}, null, 8, ["modelValue", "tabs", "label"]),
|
|
74
|
-
r("div", ae, [
|
|
75
|
-
_(t(U), {
|
|
76
|
-
modelValue: d.value,
|
|
77
|
-
"onUpdate:modelValue": e[1] || (e[1] = (s) => d.value = s),
|
|
78
|
-
label: t(o)("core.users.activity.since"),
|
|
79
|
-
max: m.value ?? void 0
|
|
80
|
-
}, null, 8, ["modelValue", "label", "max"]),
|
|
81
|
-
_(t(U), {
|
|
82
|
-
modelValue: m.value,
|
|
83
|
-
"onUpdate:modelValue": e[2] || (e[2] = (s) => m.value = s),
|
|
84
|
-
label: t(o)("core.users.activity.until"),
|
|
85
|
-
min: d.value ?? void 0
|
|
86
|
-
}, null, 8, ["modelValue", "label", "min"])
|
|
87
|
-
])
|
|
88
|
-
]),
|
|
89
|
-
_(t(Q), {
|
|
90
|
-
state: t(p).state.value,
|
|
91
|
-
"skeleton-rows": 5,
|
|
92
|
-
"is-empty": () => !1,
|
|
93
|
-
onRetry: e[4] || (e[4] = (s) => t(p).reload())
|
|
94
|
-
}, {
|
|
95
|
-
default: f(({ value: s }) => [
|
|
96
|
-
!s || s.data.length === 0 ? (i(), y("p", se, u(t(o)("core.users.activity.empty")), 1)) : (i(), y("div", oe, [
|
|
97
|
-
(i(!0), y(C, null, N(L.value, (l) => (i(), x(t(T), {
|
|
98
|
-
key: l.key,
|
|
99
|
-
header: l.header
|
|
100
|
-
}, {
|
|
101
|
-
default: f(() => [
|
|
102
|
-
(i(!0), y(C, null, N(l.rows, (n) => (i(), x(t(z), {
|
|
103
|
-
key: n.id,
|
|
104
|
-
layout: "setting",
|
|
105
|
-
label: `${F(n.action)}`,
|
|
106
|
-
"data-activity-row": ""
|
|
107
|
-
}, {
|
|
108
|
-
leading: f(() => [
|
|
109
|
-
_(t(D), {
|
|
110
|
-
tone: "anchor",
|
|
111
|
-
icon: "listCheck"
|
|
112
|
-
})
|
|
113
|
-
]),
|
|
114
|
-
sub: f(() => [
|
|
115
|
-
r("span", le, [
|
|
116
|
-
r("span", null, u(h(n.area)), 1),
|
|
117
|
-
e[5] || (e[5] = r("span", { "aria-hidden": "true" }, "·", -1)),
|
|
118
|
-
r("span", null, u(n.record_type) + " #" + u(n.record_id), 1)
|
|
119
|
-
])
|
|
120
|
-
]),
|
|
121
|
-
default: f(() => [
|
|
122
|
-
n.signed_in_as ? (i(), x(t(W), {
|
|
123
|
-
key: 0,
|
|
124
|
-
tone: "warning",
|
|
125
|
-
"data-activity-signed-in-as": ""
|
|
126
|
-
}, {
|
|
127
|
-
default: f(() => [
|
|
128
|
-
j(u(n.signed_in_as.name ? t(o)("core.users.activity.signed_in_as", { name: n.signed_in_as.name }) : t(o)("core.users.activity.signed_in_as_other")), 1)
|
|
129
|
-
]),
|
|
130
|
-
_: 2
|
|
131
|
-
}, 1024)) : R("", !0),
|
|
132
|
-
r("span", ne, u(t(V).time(n.created_at)), 1)
|
|
133
|
-
]),
|
|
134
|
-
_: 2
|
|
135
|
-
}, 1032, ["label"]))), 128))
|
|
136
|
-
]),
|
|
137
|
-
_: 2
|
|
138
|
-
}, 1032, ["header"]))), 128))
|
|
139
|
-
])),
|
|
140
|
-
s ? (i(), x(Y, {
|
|
141
|
-
key: 2,
|
|
142
|
-
page: v.value,
|
|
143
|
-
"onUpdate:page": e[3] || (e[3] = (l) => v.value = l),
|
|
144
|
-
"last-page": s.last_page,
|
|
145
|
-
total: s.total
|
|
146
|
-
}, null, 8, ["page", "last-page", "total"])) : R("", !0),
|
|
147
|
-
r("p", ie, u(t(o)("core.users.activity.footer")), 1)
|
|
148
|
-
]),
|
|
149
|
-
_: 1
|
|
150
|
-
}, 8, ["state"])
|
|
151
|
-
]));
|
|
152
|
-
}
|
|
153
|
-
});
|
|
154
|
-
export {
|
|
155
|
-
we as default
|
|
156
|
-
};
|
|
@@ -1,192 +0,0 @@
|
|
|
1
|
-
import { getCurrentInstance as L, watchEffect as R, toValue as z, computed as f, triggerRef as w, shallowRef as A, defineComponent as B, useSlots as I, useTemplateRef as M, openBlock as y, createBlock as N, unref as $, withCtx as D, createElementVNode as P, mergeProps as v, createVNode as h, createElementBlock as K, h as k } from "vue";
|
|
2
|
-
import { RouterLink as T } from "vue-router";
|
|
3
|
-
import { _ as x } from "./Icon.vue_vue_type_script_lang-BhhsFYwp.js";
|
|
4
|
-
import { u as j } from "./useWaitStatus-fsacMl4W.js";
|
|
5
|
-
import { p as V } from "./perDocument-DUuFrdGU.js";
|
|
6
|
-
import { t as Y } from "./dialogStack-B5G6xHq0.js";
|
|
7
|
-
const O = /^[^\p{L}\p{N}\s]$/u;
|
|
8
|
-
function U(t, n) {
|
|
9
|
-
const e = n.shiftKey === void 0 && O.test(n.key) || t.shiftKey === (n.shiftKey ?? !1), i = n.mod ? t.ctrlKey !== t.metaKey : t.ctrlKey === (n.ctrlKey ?? !1) && t.metaKey === (n.metaKey ?? !1);
|
|
10
|
-
return t.key.toLowerCase() === n.key.toLowerCase() && e && i && t.altKey === (n.altKey ?? !1);
|
|
11
|
-
}
|
|
12
|
-
function G(t) {
|
|
13
|
-
return t instanceof HTMLElement && (t.isContentEditable || /^(input|textarea|select)$/i.test(t.tagName));
|
|
14
|
-
}
|
|
15
|
-
function H(t, n) {
|
|
16
|
-
const e = L();
|
|
17
|
-
R((i) => {
|
|
18
|
-
const o = z(t);
|
|
19
|
-
if (!o) return;
|
|
20
|
-
if (o.label !== void 0) {
|
|
21
|
-
const a = q(o);
|
|
22
|
-
i(a.remove);
|
|
23
|
-
}
|
|
24
|
-
const s = (a) => {
|
|
25
|
-
a.repeat || !U(a, o) || !(o.mod || o.ctrlKey || o.altKey || o.metaKey) && G(a.target) || W(e) && n(a) !== !1 && a.preventDefault();
|
|
26
|
-
};
|
|
27
|
-
window.addEventListener("keydown", s), i(() => window.removeEventListener("keydown", s));
|
|
28
|
-
});
|
|
29
|
-
}
|
|
30
|
-
function W(t) {
|
|
31
|
-
const n = Y();
|
|
32
|
-
if (n === void 0) return !0;
|
|
33
|
-
const e = t?.subTree.el;
|
|
34
|
-
return !!n && !!e && n.contains(e);
|
|
35
|
-
}
|
|
36
|
-
const Z = Symbol("vue-core:shortcuts"), E = () => V(Z, () => ({ items: [], changed: A(0) }));
|
|
37
|
-
function q(t) {
|
|
38
|
-
const n = E();
|
|
39
|
-
return n.items = [...n.items, t], w(n.changed), {
|
|
40
|
-
remove() {
|
|
41
|
-
n.items = n.items.filter((e) => e !== t), w(n.changed);
|
|
42
|
-
}
|
|
43
|
-
};
|
|
44
|
-
}
|
|
45
|
-
function F(t) {
|
|
46
|
-
const n = typeof navigator < "u" && /Mac|iPhone|iPad|iPod/.test(navigator.platform || navigator.userAgent), e = n ? { ctrl: "⌃", alt: "⌥", shift: "⇧", meta: "⌘" } : { ctrl: "Ctrl", alt: "Alt", shift: "Shift", meta: "Meta" }, i = t.mod ? !n : t.ctrlKey, o = t.mod ? n : t.metaKey, s = J[t.key] ?? (t.key.length === 1 ? t.key.toUpperCase() : t.key);
|
|
47
|
-
return [
|
|
48
|
-
...i ? [e.ctrl] : [],
|
|
49
|
-
...t.altKey ? [e.alt] : [],
|
|
50
|
-
...t.shiftKey ? [e.shift] : [],
|
|
51
|
-
...o ? [e.meta] : [],
|
|
52
|
-
s
|
|
53
|
-
];
|
|
54
|
-
}
|
|
55
|
-
const J = { ArrowLeft: "←", ArrowRight: "→", ArrowUp: "↑", ArrowDown: "↓", Escape: "Esc", " ": "Space" };
|
|
56
|
-
function re() {
|
|
57
|
-
const t = E();
|
|
58
|
-
return f(() => {
|
|
59
|
-
t.changed.value;
|
|
60
|
-
const n = /* @__PURE__ */ new Map();
|
|
61
|
-
for (const e of t.items) {
|
|
62
|
-
const i = typeof e.label == "function" ? e.label() : e.label ?? "";
|
|
63
|
-
if (i === "") continue;
|
|
64
|
-
const o = e.group ?? null, s = n.get(`${o}\0${i}`) ?? { group: o, label: i, keys: [] }, a = F(e);
|
|
65
|
-
s.keys.some((r) => r.join("+") === a.join("+")) || s.keys.push(a), n.set(`${o}\0${i}`, s);
|
|
66
|
-
}
|
|
67
|
-
return [...n.values()];
|
|
68
|
-
});
|
|
69
|
-
}
|
|
70
|
-
const Q = ["href", "tabindex", "onClick"], X = ["href", "tabindex"], ee = ["type", "disabled"], le = /* @__PURE__ */ B({
|
|
71
|
-
__name: "Button",
|
|
72
|
-
props: {
|
|
73
|
-
prominence: { default: "standard" },
|
|
74
|
-
tone: { default: void 0 },
|
|
75
|
-
size: { default: "md" },
|
|
76
|
-
icon: { default: void 0 },
|
|
77
|
-
trailingIcon: { default: void 0 },
|
|
78
|
-
to: { default: void 0 },
|
|
79
|
-
href: { default: void 0 },
|
|
80
|
-
type: { default: "button" },
|
|
81
|
-
disabled: { type: Boolean, default: !1 },
|
|
82
|
-
processing: { type: Boolean, default: !1 },
|
|
83
|
-
keyboardShortcut: { default: void 0 }
|
|
84
|
-
},
|
|
85
|
-
emits: ["click"],
|
|
86
|
-
setup(t, { emit: n }) {
|
|
87
|
-
const e = t, i = n, o = I(), s = M("element"), a = j(() => e.processing), r = f(() => e.disabled || e.processing);
|
|
88
|
-
function m(l, c) {
|
|
89
|
-
if (r.value) {
|
|
90
|
-
l.preventDefault();
|
|
91
|
-
return;
|
|
92
|
-
}
|
|
93
|
-
i("click", l), c?.(l);
|
|
94
|
-
}
|
|
95
|
-
H(() => e.keyboardShortcut, (l) => {
|
|
96
|
-
if (r.value || s.value?.closest("[inert]")) return !1;
|
|
97
|
-
i("click", l);
|
|
98
|
-
});
|
|
99
|
-
const _ = {
|
|
100
|
-
primary: {
|
|
101
|
-
default: "bg-tint text-content-on-tint hover:bg-tint/90 active:bg-tint/80",
|
|
102
|
-
critical: "bg-status-danger-solid text-white hover:brightness-110"
|
|
103
|
-
},
|
|
104
|
-
secondary: {
|
|
105
|
-
default: "bg-tint-soft text-content-link hover:brightness-95 dark:hover:brightness-125",
|
|
106
|
-
critical: "bg-status-danger-surface text-content-destructive hover:brightness-95 dark:hover:brightness-125"
|
|
107
|
-
},
|
|
108
|
-
standard: {
|
|
109
|
-
default: "bg-fill text-content-strong hover:bg-fill-strong",
|
|
110
|
-
critical: "bg-fill text-content-destructive hover:bg-fill-strong"
|
|
111
|
-
},
|
|
112
|
-
plain: {
|
|
113
|
-
default: "bg-transparent text-content-link hover:bg-tint-soft",
|
|
114
|
-
critical: "bg-transparent text-content-destructive hover:bg-status-danger-surface"
|
|
115
|
-
},
|
|
116
|
-
link: {
|
|
117
|
-
default: "bg-transparent text-content-link hover:underline",
|
|
118
|
-
critical: "bg-transparent text-content-destructive hover:underline"
|
|
119
|
-
}
|
|
120
|
-
}, u = {
|
|
121
|
-
xs: { box: "min-h-6 px-2.5 py-0.5 text-xs gap-1", icon: 12 },
|
|
122
|
-
sm: { box: "min-h-8 px-3 py-1 text-xs gap-1.5", icon: 14 },
|
|
123
|
-
md: { box: "min-h-9 px-4 py-1.5 text-sm gap-2", icon: 16 },
|
|
124
|
-
lg: { box: "min-h-11 px-5 py-2 text-base gap-2", icon: 20 },
|
|
125
|
-
xl: { box: "min-h-12 px-6 py-2.5 text-base gap-2.5", icon: 22 }
|
|
126
|
-
}, p = f(() => [
|
|
127
|
-
"hit-target flex cursor-pointer select-none items-center justify-center rounded-button text-center font-semibold",
|
|
128
|
-
"transition duration-motion-fast ease-motion-standard",
|
|
129
|
-
"focus-visible:outline-2 focus-visible:outline-offset-2 focus-visible:outline-border-focus",
|
|
130
|
-
_[e.prominence][e.tone ?? "default"],
|
|
131
|
-
u[e.size].box,
|
|
132
|
-
// aria-disabled covers links, which have no `disabled` attribute.
|
|
133
|
-
e.processing && !e.disabled ? "cursor-progress" : "disabled:cursor-not-allowed disabled:opacity-45 aria-disabled:cursor-not-allowed aria-disabled:opacity-45"
|
|
134
|
-
]), b = f(() => ({
|
|
135
|
-
"aria-disabled": r.value || void 0,
|
|
136
|
-
"aria-busy": e.processing || void 0
|
|
137
|
-
})), g = () => [
|
|
138
|
-
e.processing && a.visible.value ? k(x, { name: "loader4Line", size: u[e.size].icon, class: "animate-spin", "data-test": "button-spinner" }) : e.icon ? k(x, { name: e.icon, size: u[e.size].icon }) : null,
|
|
139
|
-
o.default?.(),
|
|
140
|
-
e.trailingIcon ? k(x, { name: e.trailingIcon, size: u[e.size].icon }) : null
|
|
141
|
-
];
|
|
142
|
-
return (l, c) => e.to !== void 0 ? (y(), N($(T), {
|
|
143
|
-
key: 0,
|
|
144
|
-
to: e.to,
|
|
145
|
-
custom: ""
|
|
146
|
-
}, {
|
|
147
|
-
default: D(({ href: d, navigate: C }) => [
|
|
148
|
-
P("a", v({
|
|
149
|
-
ref_key: "element",
|
|
150
|
-
ref: s,
|
|
151
|
-
href: r.value ? void 0 : d,
|
|
152
|
-
class: p.value
|
|
153
|
-
}, b.value, {
|
|
154
|
-
tabindex: r.value ? -1 : void 0,
|
|
155
|
-
onClick: (S) => m(S, C)
|
|
156
|
-
}), [
|
|
157
|
-
h(g)
|
|
158
|
-
], 16, Q)
|
|
159
|
-
]),
|
|
160
|
-
_: 1
|
|
161
|
-
}, 8, ["to"])) : e.href !== void 0 ? (y(), K("a", v({
|
|
162
|
-
key: 1,
|
|
163
|
-
ref_key: "element",
|
|
164
|
-
ref: s,
|
|
165
|
-
href: r.value ? void 0 : e.href,
|
|
166
|
-
class: p.value
|
|
167
|
-
}, b.value, {
|
|
168
|
-
tabindex: r.value ? -1 : void 0,
|
|
169
|
-
onClick: c[0] || (c[0] = (d) => m(d))
|
|
170
|
-
}), [
|
|
171
|
-
h(g)
|
|
172
|
-
], 16, X)) : (y(), K("button", v({
|
|
173
|
-
key: 2,
|
|
174
|
-
ref_key: "element",
|
|
175
|
-
ref: s,
|
|
176
|
-
type: e.type,
|
|
177
|
-
class: p.value,
|
|
178
|
-
disabled: r.value
|
|
179
|
-
}, b.value, {
|
|
180
|
-
onClick: c[1] || (c[1] = (d) => m(d))
|
|
181
|
-
}), [
|
|
182
|
-
h(g)
|
|
183
|
-
], 16, ee));
|
|
184
|
-
}
|
|
185
|
-
});
|
|
186
|
-
export {
|
|
187
|
-
le as _,
|
|
188
|
-
re as a,
|
|
189
|
-
U as m,
|
|
190
|
-
F as s,
|
|
191
|
-
H as u
|
|
192
|
-
};
|
package/dist/Changes-Dxjdkd_5.js
DELETED
|
@@ -1,129 +0,0 @@
|
|
|
1
|
-
import { defineComponent as k, computed as N, openBlock as n, createBlock as u, unref as a, withCtx as g, createElementBlock as p, Fragment as _, renderList as $, createElementVNode as i, toDisplayString as h, createCommentVNode as C, ref as x, watch as b, createVNode as y } from "vue";
|
|
2
|
-
import { useI18n as E } from "vue-i18n";
|
|
3
|
-
import { P as V, i as R } from "./index-CdtofdcJ.js";
|
|
4
|
-
import { u as S } from "./platform-BQOX_Ntw.js";
|
|
5
|
-
import { b as B } from "./routeResource-DlTsGTg_.js";
|
|
6
|
-
import { _ as F } from "./AsyncSection.vue_vue_type_script_setup_true_lang-BdeOKqz_.js";
|
|
7
|
-
import { u as L } from "./useLoad-M7V-AVwR.js";
|
|
8
|
-
import { _ as P } from "./Avatar.vue_vue_type_script_setup_true_lang-BPj_fkJR.js";
|
|
9
|
-
import { _ as I } from "./IconTile.vue_vue_type_script_setup_true_lang-BmxCuUZ9.js";
|
|
10
|
-
import { u as O } from "./format-D8KUBmbS.js";
|
|
11
|
-
import { _ as T } from "./FormGroup.vue_vue_type_script_setup_true_lang-B37dixvJ.js";
|
|
12
|
-
import { g as U } from "./options-QuOkMKVZ.js";
|
|
13
|
-
import { _ as q } from "./PageBar.vue_vue_type_script_setup_true_lang-qI94fjJv.js";
|
|
14
|
-
import { _ as z } from "./SectionIntro.vue_vue_type_script_setup_true_lang-CZtPrmXD.js";
|
|
15
|
-
import { _ as A } from "./ViewTabs.vue_vue_type_script_setup_true_lang-BjdDXE3T.js";
|
|
16
|
-
const D = { class: "flex items-center pl-0.5" }, G = { class: "flex flex-wrap items-center gap-x-1.5" }, H = {
|
|
17
|
-
class: "font-medium text-content",
|
|
18
|
-
"data-change-actor": ""
|
|
19
|
-
}, W = /* @__PURE__ */ k({
|
|
20
|
-
__name: "ChangeFeed",
|
|
21
|
-
props: {
|
|
22
|
-
rows: {}
|
|
23
|
-
},
|
|
24
|
-
setup(v) {
|
|
25
|
-
const w = v, { t: r, te: f } = E(), d = O(), m = /* @__PURE__ */ new Set(["created", "activated", "deactivated", "password"]), c = (s) => r(`core.users.changes.fields.${s}`), l = N(
|
|
26
|
-
() => w.rows.map((s) => {
|
|
27
|
-
const t = f(`core.users.changes.actions.${s.action}`) ? r(`core.users.changes.actions.${s.action}`) : r("core.users.changes.actions.unknown"), e = m.has(s.action) ? [] : s.fields.filter((o) => o !== "password" && f(`core.users.changes.fields.${o}`)).map((o) => o in s.before || o in s.after ? r("core.users.changes.diff", { field: c(o), before: s.before[o] || "—", after: s.after[o] || "—" }) : c(o));
|
|
28
|
-
return { row: s, sentence: t, details: e };
|
|
29
|
-
})
|
|
30
|
-
);
|
|
31
|
-
return (s, t) => (n(), u(a(T), { "data-change-feed": "" }, {
|
|
32
|
-
default: g(() => [
|
|
33
|
-
(n(!0), p(_, null, $(l.value, (e) => (n(), u(a(U), {
|
|
34
|
-
key: e.row.id,
|
|
35
|
-
layout: "setting",
|
|
36
|
-
label: e.sentence,
|
|
37
|
-
"data-change-row": ""
|
|
38
|
-
}, {
|
|
39
|
-
leading: g(() => [
|
|
40
|
-
i("span", D, [
|
|
41
|
-
e.row.actor?.name ? (n(), u(a(P), {
|
|
42
|
-
key: 0,
|
|
43
|
-
name: e.row.actor.name,
|
|
44
|
-
size: "sm"
|
|
45
|
-
}, null, 8, ["name"])) : (n(), u(a(I), {
|
|
46
|
-
key: 1,
|
|
47
|
-
tone: "anchor",
|
|
48
|
-
icon: "edit"
|
|
49
|
-
}))
|
|
50
|
-
])
|
|
51
|
-
]),
|
|
52
|
-
sub: g(() => [
|
|
53
|
-
i("span", G, [
|
|
54
|
-
e.row.actor ? (n(), p(_, { key: 0 }, [
|
|
55
|
-
i("span", H, h(e.row.actor.name || a(r)("core.account.somebody_else")), 1),
|
|
56
|
-
t[0] || (t[0] = i("span", { "aria-hidden": "true" }, "·", -1))
|
|
57
|
-
], 64)) : C("", !0),
|
|
58
|
-
(n(!0), p(_, null, $(e.details, (o) => (n(), p(_, { key: o }, [
|
|
59
|
-
i("span", null, h(o), 1),
|
|
60
|
-
t[1] || (t[1] = i("span", { "aria-hidden": "true" }, "·", -1))
|
|
61
|
-
], 64))), 128)),
|
|
62
|
-
i("span", null, h(a(d).dateTime(e.row.created_at)), 1)
|
|
63
|
-
])
|
|
64
|
-
]),
|
|
65
|
-
_: 2
|
|
66
|
-
}, 1032, ["label"]))), 128))
|
|
67
|
-
]),
|
|
68
|
-
_: 1
|
|
69
|
-
}));
|
|
70
|
-
}
|
|
71
|
-
}), Y = {
|
|
72
|
-
class: "flex min-w-0 flex-col gap-group-gap",
|
|
73
|
-
"data-person-changes": ""
|
|
74
|
-
}, j = {
|
|
75
|
-
key: 0,
|
|
76
|
-
class: "px-row-inset py-4 text-body text-content-muted",
|
|
77
|
-
"data-changes-empty": ""
|
|
78
|
-
}, ie = /* @__PURE__ */ k({
|
|
79
|
-
__name: "Changes",
|
|
80
|
-
setup(v) {
|
|
81
|
-
const w = ["all", "access", "details"], { t: r } = E(), { http: f } = S(), d = B(V), m = x("all"), c = x(1), l = L(
|
|
82
|
-
async ({ signal: s }) => {
|
|
83
|
-
const t = d.id.value;
|
|
84
|
-
return t === null ? null : (await f.request(R.usersChanges, { id: t, view: m.value, page: c.value, per_page: 20 }, { signal: s })).data;
|
|
85
|
-
},
|
|
86
|
-
{ watch: () => d.id.value }
|
|
87
|
-
);
|
|
88
|
-
return b(m, () => {
|
|
89
|
-
c.value = 1, l.reload();
|
|
90
|
-
}), b(c, () => void l.reload()), (s, t) => (n(), p("div", Y, [
|
|
91
|
-
y(z, {
|
|
92
|
-
title: a(r)("core.users.sections.changes"),
|
|
93
|
-
description: a(r)("core.users.intro.changes", { name: a(d).data.value?.name ?? "" })
|
|
94
|
-
}, null, 8, ["title", "description"]),
|
|
95
|
-
y(A, {
|
|
96
|
-
modelValue: m.value,
|
|
97
|
-
"onUpdate:modelValue": t[0] || (t[0] = (e) => m.value = e),
|
|
98
|
-
views: w,
|
|
99
|
-
counts: a(l).data.value?.meta?.views,
|
|
100
|
-
"label-of": (e) => a(r)(`core.users.changes.views.${e}`),
|
|
101
|
-
label: a(r)("core.users.sections.changes")
|
|
102
|
-
}, null, 8, ["modelValue", "counts", "label-of", "label"]),
|
|
103
|
-
y(a(F), {
|
|
104
|
-
state: a(l).state.value,
|
|
105
|
-
"skeleton-rows": 5,
|
|
106
|
-
"is-empty": () => !1,
|
|
107
|
-
onRetry: t[2] || (t[2] = (e) => a(l).reload())
|
|
108
|
-
}, {
|
|
109
|
-
default: g(({ value: e }) => [
|
|
110
|
-
!e || e.data.length === 0 ? (n(), p("p", j, h(a(r)("core.users.changes.empty")), 1)) : (n(), u(W, {
|
|
111
|
-
key: 1,
|
|
112
|
-
rows: e.data
|
|
113
|
-
}, null, 8, ["rows"])),
|
|
114
|
-
e ? (n(), u(q, {
|
|
115
|
-
key: 2,
|
|
116
|
-
page: c.value,
|
|
117
|
-
"onUpdate:page": t[1] || (t[1] = (o) => c.value = o),
|
|
118
|
-
"last-page": e.last_page,
|
|
119
|
-
total: e.total
|
|
120
|
-
}, null, 8, ["page", "last-page", "total"])) : C("", !0)
|
|
121
|
-
]),
|
|
122
|
-
_: 1
|
|
123
|
-
}, 8, ["state"])
|
|
124
|
-
]));
|
|
125
|
-
}
|
|
126
|
-
});
|
|
127
|
-
export {
|
|
128
|
-
ie as default
|
|
129
|
-
};
|