@vc-shell/framework 1.0.43 → 1.0.44
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/framework.js +6 -6
- package/dist/framework.js.map +1 -1
- package/dist/style.css +1 -1
- package/package.json +4 -4
- package/shared/app-switcher/components/vc-app-switcher/vc-app-switcher.vue +1 -1
- package/ui/components/organisms/vc-app/_internal/vc-app-bar/vc-app-bar.vue +16 -35
- package/ui/components/organisms/vc-app/_internal/vc-app-menu/vc-app-menu.vue +12 -2
- package/ui/components/organisms/vc-app/vc-app.vue +1 -1
|
@@ -3,56 +3,41 @@
|
|
|
3
3
|
class="tw-relative tw-flex tw-items-center tw-content-between tw-h-[var(--app-bar-height)] tw-bg-[color:var(--app-bar-background-color)] tw-pl-4"
|
|
4
4
|
>
|
|
5
5
|
<slot name="appSwitcher"></slot>
|
|
6
|
-
|
|
7
|
-
<template v-if="
|
|
8
|
-
<!--
|
|
6
|
+
|
|
7
|
+
<template v-if="!$isMobile.value || blades.length === 0">
|
|
8
|
+
<!-- Logo -->
|
|
9
9
|
<img
|
|
10
|
-
|
|
11
|
-
class="h-3/6 tw-cursor-pointer"
|
|
10
|
+
class="tw-h-1/2 tw-cursor-pointer tw-mx-3"
|
|
12
11
|
alt="logo"
|
|
13
12
|
:src="logo"
|
|
14
13
|
@click="$emit('logo:click')"
|
|
15
14
|
/>
|
|
16
15
|
|
|
16
|
+
<!-- Title -->
|
|
17
|
+
<div
|
|
18
|
+
class="tw-text-[color:var(--app-bar-product-name-color)] tw-text-[length:var(--app-bar-product-name-size)] tw-font-medium"
|
|
19
|
+
v-if="title"
|
|
20
|
+
>
|
|
21
|
+
{{ title }}
|
|
22
|
+
</div>
|
|
23
|
+
</template>
|
|
24
|
+
|
|
25
|
+
<template v-if="$isMobile.value">
|
|
17
26
|
<!-- Show blades name when at least one blade is opened -->
|
|
18
27
|
<div
|
|
19
|
-
v-
|
|
28
|
+
v-if="blades.length === 1"
|
|
20
29
|
class="tw-overflow-ellipsis tw-overflow-hidden tw-whitespace-nowrap tw-text-2xl tw-leading-header"
|
|
21
30
|
>
|
|
22
31
|
{{ blades[0].title }}
|
|
23
32
|
</div>
|
|
24
33
|
|
|
25
34
|
<!-- Show back link when more than one blade is opened -->
|
|
26
|
-
<VcLink v-else @click="$emit('backlink:click')">
|
|
35
|
+
<VcLink v-else-if="blades.length > 1" @click="$emit('backlink:click')">
|
|
27
36
|
<VcIcon icon="fas fa-chevron-left" size="s"></VcIcon>
|
|
28
37
|
<span class="tw-ml-2 tw-text-lg">{{ $t("Back") }}</span>
|
|
29
38
|
</VcLink>
|
|
30
39
|
</template>
|
|
31
40
|
|
|
32
|
-
<!-- Logo container for desktop devices -->
|
|
33
|
-
<template v-else>
|
|
34
|
-
<img
|
|
35
|
-
class="tw-h-3/6 tw-cursor-pointer"
|
|
36
|
-
:src="logo"
|
|
37
|
-
alt="logo"
|
|
38
|
-
@click="$emit('logo:click')"
|
|
39
|
-
/>
|
|
40
|
-
<div
|
|
41
|
-
class="tw-text-[color:var(--app-bar-version-color)] tw-text-xs tw-ml-[30px]"
|
|
42
|
-
@click="$emit('version:click')"
|
|
43
|
-
>
|
|
44
|
-
{{ version }}
|
|
45
|
-
</div>
|
|
46
|
-
</template>
|
|
47
|
-
|
|
48
|
-
<!-- Product name slot -->
|
|
49
|
-
<div
|
|
50
|
-
class="tw-text-[color:var(--app-bar-product-name-color)] tw-text-[length:var(--app-bar-product-name-size)] tw-font-medium tw-ml-[30px]"
|
|
51
|
-
v-if="title"
|
|
52
|
-
>
|
|
53
|
-
{{ title }}
|
|
54
|
-
</div>
|
|
55
|
-
|
|
56
41
|
<!-- Additional spacer -->
|
|
57
42
|
<div class="tw-grow tw-basis-0 tw-basis-0"></div>
|
|
58
43
|
|
|
@@ -103,7 +88,6 @@ import { IBladeElement } from "@/shared";
|
|
|
103
88
|
|
|
104
89
|
export interface Props {
|
|
105
90
|
logo: string;
|
|
106
|
-
version: string;
|
|
107
91
|
blades: IBladeElement[];
|
|
108
92
|
buttons: IBladeToolbar[];
|
|
109
93
|
title?: string;
|
|
@@ -111,7 +95,6 @@ export interface Props {
|
|
|
111
95
|
|
|
112
96
|
withDefaults(defineProps<Props>(), {
|
|
113
97
|
logo: "",
|
|
114
|
-
version: "",
|
|
115
98
|
blades: () => [],
|
|
116
99
|
buttons: () => [],
|
|
117
100
|
});
|
|
@@ -119,7 +102,6 @@ withDefaults(defineProps<Props>(), {
|
|
|
119
102
|
defineEmits([
|
|
120
103
|
"logo:click",
|
|
121
104
|
"backlink:click",
|
|
122
|
-
"version:click",
|
|
123
105
|
"toolbarbutton:click",
|
|
124
106
|
"menubutton:click",
|
|
125
107
|
]);
|
|
@@ -135,7 +117,6 @@ defineEmits([
|
|
|
135
117
|
--app-bar-button-background-color: var(--app-bar-background-color);
|
|
136
118
|
--app-bar-button-color-hover: #34414f;
|
|
137
119
|
--app-bar-button-background-color-hover: var(--app-bar-background-color);
|
|
138
|
-
--app-bar-version-color: #838d9a;
|
|
139
120
|
--app-bar-product-name-color: #34414f;
|
|
140
121
|
--app-bar-product-name-size: 20px;
|
|
141
122
|
}
|
|
@@ -28,7 +28,7 @@
|
|
|
28
28
|
|
|
29
29
|
<!-- Show scrollable area with menu items -->
|
|
30
30
|
<VcContainer :noPadding="true" class="tw-grow tw-basis-0">
|
|
31
|
-
<div class="tw-gap-[5px] tw-flex tw-flex-col tw-px-4">
|
|
31
|
+
<div class="tw-gap-[5px] tw-flex tw-flex-col tw-px-4 tw-h-full">
|
|
32
32
|
<template
|
|
33
33
|
v-for="(item, index) in mobileMenuItems"
|
|
34
34
|
:key="`info_item_${index}`"
|
|
@@ -38,7 +38,7 @@
|
|
|
38
38
|
v-if="item.component"
|
|
39
39
|
:is="item.component"
|
|
40
40
|
v-bind="item.bladeOptions"
|
|
41
|
-
class="tw-p-0 tw-mb-2 tw-w-full"
|
|
41
|
+
class="tw-p-0 tw-mb-2 tw-w-full tw-h-auto"
|
|
42
42
|
></component>
|
|
43
43
|
</template>
|
|
44
44
|
</template>
|
|
@@ -60,6 +60,12 @@
|
|
|
60
60
|
"
|
|
61
61
|
/>
|
|
62
62
|
</template>
|
|
63
|
+
<div
|
|
64
|
+
class="tw-text-[color:var(--app-menu-version-color)] tw-text-xs tw-mt-auto tw-self-center tw-p-1"
|
|
65
|
+
@click="$emit('version:click')"
|
|
66
|
+
>
|
|
67
|
+
{{ version }}
|
|
68
|
+
</div>
|
|
63
69
|
</div>
|
|
64
70
|
</VcContainer>
|
|
65
71
|
</div>
|
|
@@ -76,15 +82,18 @@ import { IMenuClickEvent } from "@/shared";
|
|
|
76
82
|
export interface Props {
|
|
77
83
|
items?: IMenuItems[];
|
|
78
84
|
mobileMenuItems?: IMenuItems[];
|
|
85
|
+
version: string;
|
|
79
86
|
}
|
|
80
87
|
|
|
81
88
|
export interface Emits {
|
|
82
89
|
(event: "item:click", { item, navigationCb }: IMenuClickEvent): void;
|
|
90
|
+
(event: "version:click"): void;
|
|
83
91
|
}
|
|
84
92
|
|
|
85
93
|
withDefaults(defineProps<Props>(), {
|
|
86
94
|
items: () => [],
|
|
87
95
|
mobileMenuItems: () => [],
|
|
96
|
+
version: "",
|
|
88
97
|
});
|
|
89
98
|
|
|
90
99
|
defineEmits<Emits>();
|
|
@@ -100,6 +109,7 @@ defineExpose({
|
|
|
100
109
|
:root {
|
|
101
110
|
--app-menu-width: 230px;
|
|
102
111
|
--app-menu-background-color: #ffffff;
|
|
112
|
+
--app-menu-version-color: #838d9a;
|
|
103
113
|
}
|
|
104
114
|
|
|
105
115
|
.vc-app-menu {
|
|
@@ -15,7 +15,6 @@
|
|
|
15
15
|
class="tw-shrink-0"
|
|
16
16
|
:logo="logo"
|
|
17
17
|
:blades="bladesRefs"
|
|
18
|
-
:version="version"
|
|
19
18
|
:buttons="toolbarItems"
|
|
20
19
|
@toolbarbutton:click="onToolbarButtonClick"
|
|
21
20
|
@menubutton:click="$refs.menu.isMobileVisible = true"
|
|
@@ -34,6 +33,7 @@
|
|
|
34
33
|
ref="menu"
|
|
35
34
|
class="tw-shrink-0"
|
|
36
35
|
:items="menuItems"
|
|
36
|
+
:version="version"
|
|
37
37
|
:mobileMenuItems="mobileMenuItems"
|
|
38
38
|
@item:click="onMenuItemClick"
|
|
39
39
|
></VcAppMenu>
|