bfg-common 1.4.513 → 1.4.515
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/components/common/pages/shortcuts/Shortcuts.vue +1 -1
- package/components/common/pages/shortcuts/block/Block.vue +25 -0
- package/components/common/pages/shortcuts/block/BlockNew.vue +100 -0
- package/components/common/pages/shortcuts/category/CategoryNew.vue +7 -7
- package/package.json +1 -1
- package/components/common/pages/shortcuts/Category.vue +0 -41
- /package/components/common/pages/shortcuts/{Block.vue → block/BlockOld.vue} +0 -0
|
@@ -0,0 +1,25 @@
|
|
|
1
|
+
<template>
|
|
2
|
+
<common-pages-shortcuts-block-new
|
|
3
|
+
v-if="isNewView"
|
|
4
|
+
:item="props.item"
|
|
5
|
+
:test-id="props.testId"
|
|
6
|
+
/>
|
|
7
|
+
<common-pages-shortcuts-block-old
|
|
8
|
+
v-else
|
|
9
|
+
:item="props.item"
|
|
10
|
+
:test-id="props.testId"
|
|
11
|
+
/>
|
|
12
|
+
</template>
|
|
13
|
+
<script setup lang="ts">
|
|
14
|
+
import type { UI_I_BlockItem } from '~/components/common/pages/shortcuts/lib/models/interfaces'
|
|
15
|
+
|
|
16
|
+
const props = defineProps<{
|
|
17
|
+
item: UI_I_BlockItem
|
|
18
|
+
testId?: string
|
|
19
|
+
}>()
|
|
20
|
+
|
|
21
|
+
const { $store }: any = useNuxtApp()
|
|
22
|
+
|
|
23
|
+
const isNewView = computed<boolean>(() => $store.getters['main/getIsNewView'])
|
|
24
|
+
</script>
|
|
25
|
+
<style lang="scss" scoped></style>
|
|
@@ -0,0 +1,100 @@
|
|
|
1
|
+
<template>
|
|
2
|
+
<ui-widget class="category-block-item">
|
|
3
|
+
<nuxt-link
|
|
4
|
+
class="unit"
|
|
5
|
+
:to="navigate"
|
|
6
|
+
:title="props.item.navigateTo"
|
|
7
|
+
:data-id="props.testId"
|
|
8
|
+
@click="changeLastNavigation"
|
|
9
|
+
@contextmenu="changeLastNavigation"
|
|
10
|
+
>
|
|
11
|
+
<span
|
|
12
|
+
v-if="props.item.iconClassName"
|
|
13
|
+
:class="['unit-icon', props.item.iconClassName]"
|
|
14
|
+
/>
|
|
15
|
+
<span v-else-if="props.item.iconName" class="icon-2">
|
|
16
|
+
<atoms-the-icon2 :name="props.item.iconName" width="34" height="34" />
|
|
17
|
+
</span>
|
|
18
|
+
<div class="unit-text" :title="props.item.text">
|
|
19
|
+
{{ props.item.text }}
|
|
20
|
+
</div>
|
|
21
|
+
</nuxt-link>
|
|
22
|
+
</ui-widget>
|
|
23
|
+
</template>
|
|
24
|
+
<script setup lang="ts">
|
|
25
|
+
import type { UI_I_BlockItem } from '~/components/common/pages/shortcuts/lib/models/interfaces'
|
|
26
|
+
|
|
27
|
+
const props = defineProps<{
|
|
28
|
+
item: UI_I_BlockItem
|
|
29
|
+
testId?: string
|
|
30
|
+
}>()
|
|
31
|
+
|
|
32
|
+
const navigate = computed<string>(() => '/' + props.item.navigateTo)
|
|
33
|
+
|
|
34
|
+
const changeLastNavigation = (): void => {
|
|
35
|
+
if (!props.item.nav) return
|
|
36
|
+
|
|
37
|
+
const lastSelectedInventory = 'lastSelectedInventoryTreeIdStorageKey'
|
|
38
|
+
useLocalStorage(lastSelectedInventory, props.item.nav)
|
|
39
|
+
}
|
|
40
|
+
</script>
|
|
41
|
+
<style lang="scss" scoped>
|
|
42
|
+
.category-block-item {
|
|
43
|
+
max-width: 176px;
|
|
44
|
+
}
|
|
45
|
+
|
|
46
|
+
.unit {
|
|
47
|
+
display: flex;
|
|
48
|
+
flex-direction: column;
|
|
49
|
+
justify-content: center;
|
|
50
|
+
align-items: center;
|
|
51
|
+
width: 95px;
|
|
52
|
+
margin: 21px 10px;
|
|
53
|
+
text-decoration-line: none;
|
|
54
|
+
&-icon {
|
|
55
|
+
margin: 0px 10px 15px 10px;
|
|
56
|
+
min-width: 34px;
|
|
57
|
+
min-height: 34px;
|
|
58
|
+
display: inline-block;
|
|
59
|
+
color: var(--global-font-color3);
|
|
60
|
+
|
|
61
|
+
&.icon-lifecycle-manager,
|
|
62
|
+
&.icon-cloud-provider-services {
|
|
63
|
+
background-size: contain;
|
|
64
|
+
background-repeat: no-repeat;
|
|
65
|
+
}
|
|
66
|
+
&.icon-lifecycle-manager {
|
|
67
|
+
background-image: url('assets/img/icons/icon-life-m-light.svg');
|
|
68
|
+
html.dark-theme & {
|
|
69
|
+
background-image: url('assets/img/icons/icon-life-m-dark.svg');
|
|
70
|
+
color: var(--global-font-color3);
|
|
71
|
+
}
|
|
72
|
+
}
|
|
73
|
+
&.icon-cloud-provider-services {
|
|
74
|
+
background-image: url('assets/img/icons/icon-cps.png');
|
|
75
|
+
html.dark-theme & {
|
|
76
|
+
background-image: url('assets/img/icons/icon-cps-dark-mode.png');
|
|
77
|
+
}
|
|
78
|
+
}
|
|
79
|
+
&.icon-vm-customizationManager-32x,
|
|
80
|
+
&.icon-storage-profile-32x,
|
|
81
|
+
&.icon-Host_Policy-32x,
|
|
82
|
+
&.icon-certificate-32x {
|
|
83
|
+
width: 34px;
|
|
84
|
+
height: 34px;
|
|
85
|
+
}
|
|
86
|
+
}
|
|
87
|
+
.icon-2 {
|
|
88
|
+
margin: 0 10px 15px 10px;
|
|
89
|
+
color: var(--global-font-color3);
|
|
90
|
+
}
|
|
91
|
+
&-text {
|
|
92
|
+
color: var(--global-font-color3);
|
|
93
|
+
font-size: 13px;
|
|
94
|
+
line-height: 13px;
|
|
95
|
+
font-weight: 400;
|
|
96
|
+
padding-bottom: 2px;
|
|
97
|
+
text-align: center;
|
|
98
|
+
}
|
|
99
|
+
}
|
|
100
|
+
</style>
|
|
@@ -3,7 +3,7 @@
|
|
|
3
3
|
<span class="category__headline">
|
|
4
4
|
{{ props.title }}
|
|
5
5
|
</span>
|
|
6
|
-
<div class="
|
|
6
|
+
<div class="category__block">
|
|
7
7
|
<common-pages-shortcuts-block
|
|
8
8
|
v-for="(item, key) in props.blockItems"
|
|
9
9
|
:key="key"
|
|
@@ -23,6 +23,7 @@ const props = defineProps<{
|
|
|
23
23
|
}>()
|
|
24
24
|
</script>
|
|
25
25
|
<style lang="scss" scoped>
|
|
26
|
+
@import 'assets/scss/common/mixins';
|
|
26
27
|
.category {
|
|
27
28
|
&__headline {
|
|
28
29
|
color: #9da6ad;
|
|
@@ -30,12 +31,11 @@ const props = defineProps<{
|
|
|
30
31
|
font-weight: 400;
|
|
31
32
|
line-height: 19.36px;
|
|
32
33
|
}
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
margin-top: -4px;
|
|
34
|
+
&__block {
|
|
35
|
+
@include flex($dir: row, $just: flex-start, $w: wrap);
|
|
36
|
+
gap: 12px;
|
|
37
|
+
border-bottom: 1px solid var(--horizontal-line);
|
|
38
|
+
padding: 16px 0 24px;
|
|
39
39
|
}
|
|
40
40
|
}
|
|
41
41
|
</style>
|
package/package.json
CHANGED
|
@@ -1,41 +0,0 @@
|
|
|
1
|
-
<template>
|
|
2
|
-
<div class="category">
|
|
3
|
-
<span class="category-text" :title="props.title">
|
|
4
|
-
{{ props.title }}
|
|
5
|
-
</span>
|
|
6
|
-
<div class="category-block">
|
|
7
|
-
<common-shortcuts-block
|
|
8
|
-
v-for="(item, key) in props.blockItems"
|
|
9
|
-
:key="key"
|
|
10
|
-
:item="item"
|
|
11
|
-
:test-id="item.testId"
|
|
12
|
-
/>
|
|
13
|
-
</div>
|
|
14
|
-
</div>
|
|
15
|
-
</template>
|
|
16
|
-
|
|
17
|
-
<script setup lang="ts">
|
|
18
|
-
import type { UI_I_BlockItem } from '~/components/common/pages/shortcuts/lib/models/interfaces'
|
|
19
|
-
|
|
20
|
-
const props = defineProps<{
|
|
21
|
-
title: string
|
|
22
|
-
blockItems: UI_I_BlockItem[]
|
|
23
|
-
}>()
|
|
24
|
-
</script>
|
|
25
|
-
<style lang="scss" scoped>
|
|
26
|
-
.category {
|
|
27
|
-
&-text {
|
|
28
|
-
color: var(--light-white-100);
|
|
29
|
-
font-size: 18px;
|
|
30
|
-
line-height: 21px;
|
|
31
|
-
font-weight: 400;
|
|
32
|
-
}
|
|
33
|
-
&-block {
|
|
34
|
-
display: flex;
|
|
35
|
-
flex-direction: row;
|
|
36
|
-
justify-content: flex-start;
|
|
37
|
-
border-top: 1px solid var(--global-border-color);
|
|
38
|
-
margin-top: -4px;
|
|
39
|
-
}
|
|
40
|
-
}
|
|
41
|
-
</style>
|
|
File without changes
|