@vc-shell/framework 1.0.142 → 1.0.143
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 +10 -0
- package/core/composables/useSettings/index.ts +5 -3
- package/dist/core/composables/useSettings/index.d.ts.map +1 -1
- package/dist/framework.js +7675 -7795
- package/dist/index.d.ts.map +1 -1
- package/dist/shared/components/user-dropdown-button/user-dropdown-button.vue.d.ts.map +1 -1
- package/dist/shared/index.d.ts.map +1 -1
- package/dist/shared/modules/dynamic/pages/dynamic-blade-list.vue.d.ts.map +1 -1
- package/dist/tsconfig.tsbuildinfo +1 -1
- package/dist/ui/components/organisms/vc-table/vc-table.vue.d.ts +2 -2
- package/dist/ui/components/organisms/vc-table/vc-table.vue.d.ts.map +1 -1
- package/package.json +4 -4
- package/shared/components/user-dropdown-button/user-dropdown-button.vue +5 -3
- package/shared/index.ts +0 -9
- package/shared/modules/dynamic/pages/dynamic-blade-list.vue +4 -1
- package/ui/components/organisms/vc-table/vc-table.vue +7 -13
- package/dist/shared/locales/index.d.ts +0 -3
- package/dist/shared/locales/index.d.ts.map +0 -1
- package/dist/ui/locales/index.d.ts +0 -3
- package/dist/ui/locales/index.d.ts.map +0 -1
- package/shared/locales/en.json +0 -42
- package/shared/locales/index.ts +0 -2
- package/ui/locales/en.json +0 -59
- package/ui/locales/index.ts +0 -2
|
@@ -1,8 +1,8 @@
|
|
|
1
|
-
import { MaybeRef } from "vue";
|
|
1
|
+
import { Ref, MaybeRef } from "vue";
|
|
2
2
|
import { IActionBuilderResult, ITableColumns } from "./../../../../core/types";
|
|
3
3
|
export interface StatusImage {
|
|
4
4
|
image?: string;
|
|
5
|
-
text: string
|
|
5
|
+
text: string | Ref<string>;
|
|
6
6
|
action?: string;
|
|
7
7
|
clickHandler?: () => void;
|
|
8
8
|
}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"vc-table.vue.d.ts","sourceRoot":"","sources":["../../../../../ui/components/organisms/vc-table/vc-table.vue.ts"],"names":[],"mappings":"AAEA,OAAO,
|
|
1
|
+
{"version":3,"file":"vc-table.vue.d.ts","sourceRoot":"","sources":["../../../../../ui/components/organisms/vc-table/vc-table.vue.ts"],"names":[],"mappings":"AAEA,OAAO,EAOL,GAAG,EAIH,QAAQ,EAET,MAAM,KAAK,CAAC;AAOb,OAAO,EAAE,oBAAoB,EAAE,aAAa,EAAE,MAAM,0BAA0B,CAAC;AAK/E,MAAM,WAAW,WAAW;IAC1B,KAAK,CAAC,EAAE,MAAM,CAAC;IACf,IAAI,EAAE,MAAM,GAAG,GAAG,CAAC,MAAM,CAAC,CAAC;IAC3B,MAAM,CAAC,EAAE,MAAM,CAAC;IAChB,YAAY,CAAC,EAAE,MAAM,IAAI,CAAC;CAC3B;AAED,MAAM,WAAW,SAAS;IACxB,CAAC,CAAC,EAAE,MAAM,GAAG,GAAG,CAAC;IACjB,OAAO,CAAC,EAAE,oBAAoB,EAAE,CAAC;CAClC;;;;;;;;;;;;;;aAg8DY,aAAa,EAAE;;;;;;mBAp3DS,MAAM;mBAAa,MAAM;;;;sCAs3DzB,oBAAoB,EAAE;;;;;;;;;;;;;cAqB7C,MAAM;;;WASb,GAAG;;2CAn9D2B,GAAG,KAAK,GAAG;;;kBACG,aAAa;cAAO,GAAG;wBAJxD,GAAG,KAAK,GAAG;wBACX;YAAE,UAAU,EAAE,MAAM,IAAI,CAAA;SAAE,KAAK,GAAG;;;cACZ,GAAG;0BAGvB,GAAG,KAAK,GAAG;uBACd,GAAG,KAAK,GAAG;wBACV,GAAG,KAAK,GAAG;;2CAJQ,GAAG,KAAK,GAAG;;;kBACG,aAAa;cAAO,GAAG;wBAJxD,GAAG,KAAK,GAAG;wBACX;YAAE,UAAU,EAAE,MAAM,IAAI,CAAA;SAAE,KAAK,GAAG;;;cACZ,GAAG;0BAGvB,GAAG,KAAK,GAAG;uBACd,GAAG,KAAK,GAAG;wBACV,GAAG,KAAK,GAAG;;;mBA2D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,GAAG,KAAK,GAAG;;+CAJQ,GAAG,KAAK,GAAG;;;sBACG,aAAa;kBAAO,GAAG;4BAJxD,GAAG,KAAK,GAAG;4BACX;gBAAE,UAAU,EAAE,MAAM,IAAI,CAAA;aAAE,KAAK,GAAG;;;kBACZ,GAAG;8BAGvB,GAAG,KAAK,GAAG;2BACd,GAAG,KAAK,GAAG;4BACV,GAAG,KAAK,GAAG;;;uBA2DQ,MAAM;uBAAa,MAAM;;;;;AAzE9D,wBAk+D2E;AAQ3E,KAAK,cAAc,CAAC,CAAC,IAAI;KAAG,CAAC,IAAI,MAAM,CAAC,GAAG,CAAC,CAAC,CAAC,CAAC;CAAG,GAAG,EAAE,CAAC"}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@vc-shell/framework",
|
|
3
|
-
"version": "1.0.
|
|
3
|
+
"version": "1.0.143",
|
|
4
4
|
"type": "module",
|
|
5
5
|
"main": "./dist/framework.js",
|
|
6
6
|
"types": "./dist/index.d.ts",
|
|
@@ -52,9 +52,9 @@
|
|
|
52
52
|
"whatwg-fetch": "^3.6.19"
|
|
53
53
|
},
|
|
54
54
|
"devDependencies": {
|
|
55
|
-
"@vc-shell/api-client-generator": "^1.0.
|
|
56
|
-
"@vc-shell/config-generator": "^1.0.
|
|
57
|
-
"@vc-shell/ts-config": "^1.0.
|
|
55
|
+
"@vc-shell/api-client-generator": "^1.0.143",
|
|
56
|
+
"@vc-shell/config-generator": "^1.0.143",
|
|
57
|
+
"@vc-shell/ts-config": "^1.0.143",
|
|
58
58
|
"@vitejs/plugin-vue": "^5.0.3",
|
|
59
59
|
"sass": "^1.69.6",
|
|
60
60
|
"typescript": "^5.3.3",
|
|
@@ -24,7 +24,9 @@
|
|
|
24
24
|
{{ name || user?.userName }}
|
|
25
25
|
</div>
|
|
26
26
|
<div class="user-dropdown-button__role">
|
|
27
|
-
{{
|
|
27
|
+
{{
|
|
28
|
+
(role && $t(`SHELL.USER.ROLE.${role}`)) || (user?.isAdministrator ? $t("SHELL.USER.ROLE.ADMINISTRATOR") : "")
|
|
29
|
+
}}
|
|
28
30
|
</div>
|
|
29
31
|
</div>
|
|
30
32
|
<div
|
|
@@ -88,13 +90,13 @@ const accountMenuVisible = ref(false);
|
|
|
88
90
|
const menu = computed(() => [
|
|
89
91
|
...props.menuItems,
|
|
90
92
|
{
|
|
91
|
-
title: t("
|
|
93
|
+
title: t("SHELL.ACCOUNT.CHANGE_PASSWORD"),
|
|
92
94
|
clickHandler() {
|
|
93
95
|
open();
|
|
94
96
|
},
|
|
95
97
|
},
|
|
96
98
|
{
|
|
97
|
-
title: t("
|
|
99
|
+
title: t("SHELL.ACCOUNT.LOGOUT"),
|
|
98
100
|
async clickHandler() {
|
|
99
101
|
await signOut();
|
|
100
102
|
router.push({ name: "Login" });
|
package/shared/index.ts
CHANGED
|
@@ -5,18 +5,9 @@ import { VcAppSwitcherComponent } from "./components/app-switcher";
|
|
|
5
5
|
import { VcBladeNavigationComponent } from "./components/blade-navigation";
|
|
6
6
|
import { AssetsManagerModule } from "./modules/assets-manager";
|
|
7
7
|
import { VcPopupHandler } from "./components/popup-handler";
|
|
8
|
-
import * as locales from "./locales";
|
|
9
|
-
import { i18n } from "./../core/plugins";
|
|
10
8
|
|
|
11
9
|
export const SharedModule = {
|
|
12
10
|
install(app: App, args: { router: Router }): void {
|
|
13
|
-
// Load locales
|
|
14
|
-
if (locales) {
|
|
15
|
-
Object.entries(locales).forEach(([key, message]) => {
|
|
16
|
-
i18n.global.mergeLocaleMessage(key, message);
|
|
17
|
-
});
|
|
18
|
-
}
|
|
19
|
-
|
|
20
11
|
app
|
|
21
12
|
.use(AssetsDetailsModule)
|
|
22
13
|
.use(AssetsManagerModule)
|
|
@@ -28,7 +28,7 @@
|
|
|
28
28
|
class="tw-grow tw-basis-0"
|
|
29
29
|
:loading="loading"
|
|
30
30
|
:expanded="expanded"
|
|
31
|
-
:columns="(
|
|
31
|
+
:columns="(tableColsWithLocales as ITableColumns[]) ?? []"
|
|
32
32
|
:state-key="stateKey ?? ''"
|
|
33
33
|
:items="itemsProxy as Record<string, any>[]"
|
|
34
34
|
:multiselect="isWidgetView ? false : tableData?.multiselect"
|
|
@@ -224,6 +224,9 @@ watch(
|
|
|
224
224
|
const tableData =
|
|
225
225
|
props.composables &&
|
|
226
226
|
computed(() => props.model?.content.find((type: ListContentSchema) => type.component === "vc-table"));
|
|
227
|
+
|
|
228
|
+
const tableColsWithLocales = tableData?.value?.columns?.map((col) => ({ ...col, title: computed(() => t(col.title)) }));
|
|
229
|
+
|
|
227
230
|
const stateKey =
|
|
228
231
|
props.composables &&
|
|
229
232
|
computed(() => {
|
|
@@ -27,7 +27,7 @@
|
|
|
27
27
|
<!-- Table search input -->
|
|
28
28
|
<VcInput
|
|
29
29
|
class="tw-grow tw-basis-0"
|
|
30
|
-
:placeholder="searchPlaceholder"
|
|
30
|
+
:placeholder="searchPlaceholder || $t('COMPONENTS.ORGANISMS.VC_TABLE.SEARCH')"
|
|
31
31
|
clearable
|
|
32
32
|
name="table_search"
|
|
33
33
|
:model-value="searchValue"
|
|
@@ -362,7 +362,7 @@
|
|
|
362
362
|
:src="notfound.image"
|
|
363
363
|
/>
|
|
364
364
|
<div class="tw-m-4 vc-table__empty-text">
|
|
365
|
-
{{ notfound.text }}
|
|
365
|
+
{{ notfound.text || t("COMPONENTS.ORGANISMS.VC_TABLE.NOT_FOUND") }}
|
|
366
366
|
</div>
|
|
367
367
|
<VcButton
|
|
368
368
|
v-if="notfound.action"
|
|
@@ -384,7 +384,9 @@
|
|
|
384
384
|
v-if="empty.image"
|
|
385
385
|
:src="empty.image"
|
|
386
386
|
/>
|
|
387
|
-
<div class="tw-m-4 tw-text-xl tw-font-medium">
|
|
387
|
+
<div class="tw-m-4 tw-text-xl tw-font-medium">
|
|
388
|
+
{{ empty.text || t("COMPONENTS.ORGANISMS.VC_TABLE.EMPTY") }}
|
|
389
|
+
</div>
|
|
388
390
|
<VcButton
|
|
389
391
|
v-if="empty.action"
|
|
390
392
|
@click="empty.clickHandler"
|
|
@@ -414,7 +416,7 @@
|
|
|
414
416
|
|
|
415
417
|
<!-- Table counter -->
|
|
416
418
|
<VcTableCounter
|
|
417
|
-
:label="totalLabel"
|
|
419
|
+
:label="totalLabel || $t('COMPONENTS.ORGANISMS.VC_TABLE.TOTALS')"
|
|
418
420
|
:value="totalCount"
|
|
419
421
|
></VcTableCounter>
|
|
420
422
|
</div>
|
|
@@ -450,7 +452,7 @@ import { useI18n } from "vue-i18n";
|
|
|
450
452
|
|
|
451
453
|
export interface StatusImage {
|
|
452
454
|
image?: string;
|
|
453
|
-
text: string
|
|
455
|
+
text: string | Ref<string>;
|
|
454
456
|
action?: string;
|
|
455
457
|
clickHandler?: () => void;
|
|
456
458
|
}
|
|
@@ -501,19 +503,11 @@ const props = withDefaults(
|
|
|
501
503
|
}>(),
|
|
502
504
|
{
|
|
503
505
|
items: () => [],
|
|
504
|
-
totalLabel: "Totals:",
|
|
505
506
|
totalCount: 0,
|
|
506
507
|
pages: 0,
|
|
507
508
|
expanded: true,
|
|
508
509
|
currentPage: 0,
|
|
509
510
|
selectedItemId: undefined,
|
|
510
|
-
searchPlaceholder: "Search...",
|
|
511
|
-
empty: () => ({
|
|
512
|
-
text: "List is empty.",
|
|
513
|
-
}),
|
|
514
|
-
notfound: () => ({
|
|
515
|
-
text: "Nothing found.",
|
|
516
|
-
}),
|
|
517
511
|
header: true,
|
|
518
512
|
footer: true,
|
|
519
513
|
activeFilterCount: 0,
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../shared/locales/index.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,MAAM,WAAW,CAAC;AAChC,OAAO,EAAE,EAAE,EAAE,CAAC"}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../ui/locales/index.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,MAAM,WAAW,CAAC;AAChC,OAAO,EAAE,EAAE,EAAE,CAAC"}
|
package/shared/locales/en.json
DELETED
|
@@ -1,42 +0,0 @@
|
|
|
1
|
-
{
|
|
2
|
-
"COMPONENTS": {
|
|
3
|
-
"CHANGE_PASSWORD": {
|
|
4
|
-
"TITLE": "Change password",
|
|
5
|
-
"CURRENT_PASSWORD": {
|
|
6
|
-
"LABEL": "Current password",
|
|
7
|
-
"PLACEHOLDER": "Enter password"
|
|
8
|
-
},
|
|
9
|
-
"NEW_PASSWORD": {
|
|
10
|
-
"LABEL": "New password",
|
|
11
|
-
"PLACEHOLDER": "Enter password"
|
|
12
|
-
},
|
|
13
|
-
"CONFIRM_PASSWORD": {
|
|
14
|
-
"LABEL": "Confirm password",
|
|
15
|
-
"PLACEHOLDER": "Confirm password"
|
|
16
|
-
},
|
|
17
|
-
"CANCEL": "Cancel",
|
|
18
|
-
"SAVE": "Update",
|
|
19
|
-
"ERRORS": {
|
|
20
|
-
"Repeat-password": "Passwords are not same",
|
|
21
|
-
"Equal-passwords": "The new password must not match the old one",
|
|
22
|
-
"Invalid-token": "Token is invalid or expired",
|
|
23
|
-
"Password-too-weak": "New password does not comply one or more password security policies:",
|
|
24
|
-
"PasswordTooShort": "Passwords too short",
|
|
25
|
-
"PasswordRequiresUniqueChars": "Passwords must use different characters",
|
|
26
|
-
"PasswordRequiresLower": "Passwords must have at least one lowercase ('a'-'z')",
|
|
27
|
-
"PasswordRequiresUpper": "Passwords must have at least one uppercase ('A'-'Z')",
|
|
28
|
-
"PasswordRequiresDigit": "Passwords must have at least one digit ('0'-'9')",
|
|
29
|
-
"PasswordRequiresNonAlphanumeric": "Passwords must have at least one non alphanumeric character",
|
|
30
|
-
"Incorrect password.": "You entered an incorrect password",
|
|
31
|
-
"You have used this password in the past. Choose another one.": "You have used this password in the past. Choose another one."
|
|
32
|
-
}
|
|
33
|
-
},
|
|
34
|
-
"NOTIFICATION_DROPDOWN": {
|
|
35
|
-
"TITLE": "Notifications",
|
|
36
|
-
"EMPTY": "No notifications yet"
|
|
37
|
-
},
|
|
38
|
-
"LANGUAGE_SELECTOR": {
|
|
39
|
-
"TITLE": "Language selector"
|
|
40
|
-
}
|
|
41
|
-
}
|
|
42
|
-
}
|
package/shared/locales/index.ts
DELETED
package/ui/locales/en.json
DELETED
|
@@ -1,59 +0,0 @@
|
|
|
1
|
-
{
|
|
2
|
-
"COMPONENTS": {
|
|
3
|
-
"MOLECULES": {
|
|
4
|
-
"VC_SELECT": {
|
|
5
|
-
"CLICK_TO_SELECT": "Click to select..."
|
|
6
|
-
},
|
|
7
|
-
"VC_FILE_UPLOAD":{
|
|
8
|
-
"DRAG_HERE": "Drag and drop file here or",
|
|
9
|
-
"BROWSE":"browse your files"
|
|
10
|
-
}
|
|
11
|
-
},
|
|
12
|
-
"ORGANISMS": {
|
|
13
|
-
"VC_GALLERY":{
|
|
14
|
-
"INTERNAL": {
|
|
15
|
-
"VC_GALLERY_ITEM":{
|
|
16
|
-
"FULLSCREEN": "Fullscreen",
|
|
17
|
-
"EDIT":"Edit",
|
|
18
|
-
"DELETE":"Delete"
|
|
19
|
-
},
|
|
20
|
-
"VC_GALLERY_PREVIEW":{
|
|
21
|
-
"COPY_IMAGE_LINK": "copy image link"
|
|
22
|
-
}
|
|
23
|
-
},
|
|
24
|
-
"GALLERY_IS_EMPTY": "Gallery is empty"
|
|
25
|
-
},
|
|
26
|
-
"VC_APP": {
|
|
27
|
-
"INTERNAL":{
|
|
28
|
-
"VC_APP_BAR": {
|
|
29
|
-
"BACK":"Back"
|
|
30
|
-
}
|
|
31
|
-
}
|
|
32
|
-
},
|
|
33
|
-
"VC_BLADE": {
|
|
34
|
-
"SEE_DETAILS": "See details",
|
|
35
|
-
"ERROR_POPUP": {
|
|
36
|
-
"TITLE": "Error details"
|
|
37
|
-
}
|
|
38
|
-
},
|
|
39
|
-
"VC_TABLE": {
|
|
40
|
-
"CURRENT_PAGE_SELECTED": "All items in this page are selected.",
|
|
41
|
-
"SELECT_ALL": "Select all items",
|
|
42
|
-
"ALL_SELECTED": "All items are selected.",
|
|
43
|
-
"CANCEL": "Cancel selection",
|
|
44
|
-
"ALL_ACTIONS": "All actions",
|
|
45
|
-
"ALL_FILTERS": "Filters"
|
|
46
|
-
},
|
|
47
|
-
|
|
48
|
-
"VC_POPUP": {
|
|
49
|
-
"OK":"OK",
|
|
50
|
-
"CONFIRM":"Confirm",
|
|
51
|
-
"CANCEL":"Cancel",
|
|
52
|
-
"TITLE": {
|
|
53
|
-
"CONFIRMATION": "Confirmation",
|
|
54
|
-
"ERROR": "Error"
|
|
55
|
-
}
|
|
56
|
-
}
|
|
57
|
-
}
|
|
58
|
-
}
|
|
59
|
-
}
|
package/ui/locales/index.ts
DELETED