dashboard-shell-shell 1.0.111 → 1.0.113
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/.DS_Store +0 -0
- package/assets/icons/demo.css +539 -0
- package/assets/icons/demo_index.html +1131 -0
- package/assets/icons/iconfont.css +200 -0
- package/assets/icons/iconfont.js +1 -0
- package/assets/icons/iconfont.json +296 -0
- package/assets/icons/iconfont.ttf +0 -0
- package/assets/icons/iconfont.woff +0 -0
- package/assets/icons/iconfont.woff2 +0 -0
- package/assets/images/API.svg +3 -0
- package/assets/images/login/password.svg +20 -0
- package/assets/images/login/user.svg +6 -0
- package/assets/images/login-bg.png +0 -0
- package/assets/images/login-left.png +0 -0
- package/assets/images/login-logo.svg +19 -0
- package/assets/images/logo.png +0 -0
- package/assets/images/pl/harvester.png +0 -0
- package/assets/images/promp-yellow.svg +5 -0
- package/assets/images/user.png +0 -0
- package/assets/styles/all.scss +63 -0
- package/assets/styles/app.scss +2 -0
- package/assets/styles/base/_basic.scss +8 -2
- package/assets/styles/base/_helpers.scss +4 -0
- package/assets/styles/base/_typography.scss +2 -1
- package/assets/styles/base/_variables.scss +10 -2
- package/assets/styles/global/_button.scss +37 -25
- package/assets/styles/global/_columns.scss +3 -1
- package/assets/styles/global/_form.scss +45 -13
- package/assets/styles/global/_labeled-input.scss +50 -25
- package/assets/styles/global/_layout.scss +9 -3
- package/assets/styles/global/_select.scss +20 -13
- package/assets/styles/global/_table.scss +1 -1
- package/assets/styles/global/_tooltip.scss +47 -6
- package/assets/styles/themes/_dark.scss +1 -0
- package/assets/styles/themes/_light.scss +59 -46
- package/assets/styles/themes/_suse.scss +1 -0
- package/assets/styles/vendor/vue-select.scss +18 -7
- package/assets/translations/en-us.yaml +93 -12
- package/assets/translations/zh-hans.yaml +278 -141
- package/components/ActionDropdown.vue +1 -1
- package/components/ActionDropdownShell.vue +71 -0
- package/components/ActionMenu.vue +2 -2
- package/components/ActionMenuShell.vue +1 -0
- package/components/AppModal.vue +78 -6
- package/components/AssignTo.vue +25 -11
- package/components/AsyncButton.vue +24 -7
- package/components/BannerGraphic.vue +1 -0
- package/components/ButtonDropdown.vue +26 -4
- package/components/ButtonGroup.vue +4 -0
- package/components/ButtonMultiAction.vue +1 -0
- package/components/CommunityLinks.vue +3 -3
- package/components/ConsumptionGauge.vue +24 -5
- package/components/CopyToClipboardText.vue +2 -1
- package/components/CruResource.vue +12 -7
- package/components/CruResourceFooter.vue +2 -2
- package/components/DashboardOptions.vue +21 -15
- package/components/DetailText.vue +5 -0
- package/components/DisableAuthProviderModal.vue +1 -0
- package/components/DotState.vue +84 -0
- package/components/ExplorerMembers.vue +1 -1
- package/components/ExplorerProjectsNamespaces.vue +56 -14
- package/components/FixedBanner.vue +19 -12
- package/components/GlobalRoleBindings.vue +5 -1
- package/components/GrafanaDashboard.vue +4 -4
- package/components/GrowlManager.vue +4 -1
- package/components/HardwareResourceGauge.vue +39 -3
- package/components/InfoBox.vue +3 -3
- package/components/InputOrDisplay.vue +28 -2
- package/components/LabelValue.vue +16 -1
- package/components/LandingPagePreference.vue +5 -3
- package/components/LocaleSelector.vue +39 -93
- package/components/ModalManager.vue +55 -0
- package/components/ModalWithCard.vue +2 -0
- package/components/MoveModal.vue +1 -0
- package/components/PromptChangePassword.vue +1 -1
- package/components/PromptModal.vue +15 -2
- package/components/PromptRemove.vue +28 -8
- package/components/PromptRestore.vue +1 -0
- package/components/ResourceCancelModal.vue +1 -0
- package/components/ResourceDetail/Masthead.vue +188 -43
- package/components/ResourceDetail/__tests__/Masthead.test.ts +5 -1
- package/components/ResourceDetail/index.vue +49 -14
- package/components/ResourceList/Masthead.vue +80 -18
- package/components/ResourceTable.vue +60 -19
- package/components/SideNav.vue +32 -12
- package/components/SlideInPanelManager.vue +126 -0
- package/components/SortableTable/THead.vue +34 -5
- package/components/SortableTable/actions.js +1 -1
- package/components/SortableTable/index.vue +649 -142
- package/components/SortableTable/paging.js +36 -28
- package/components/SortableTable/selection.js +0 -11
- package/components/StatusBadge.vue +77 -0
- package/components/Tabbed/Tab.vue +3 -3
- package/components/Tabbed/index.vue +44 -26
- package/components/Wizard.vue +2 -2
- package/components/__tests__/AsyncButton.test.ts +2 -2
- package/components/__tests__/FixedBanner.test.ts +3 -3
- package/components/__tests__/ModalManager.spec.ts +176 -0
- package/components/__tests__/SlideInPanelManager.spec.ts +166 -0
- package/components/auth/Principal.vue +10 -3
- package/components/auth/__tests__/RoleDetailEdit.test.ts +3 -2
- package/components/form/ArrayList.vue +123 -85
- package/components/form/ArrayListGrouped.vue +10 -2
- package/components/form/Command.vue +6 -15
- package/components/form/EnvVars.vue +16 -8
- package/components/form/Footer.vue +8 -5
- package/components/form/HealthCheck.vue +3 -3
- package/components/form/HookOption.vue +11 -16
- package/components/form/KeyValue.vue +16 -7
- package/components/form/LabeledSelect.vue +59 -76
- package/components/form/LifecycleHooks.vue +3 -3
- package/components/form/MatchExpressions.vue +35 -12
- package/components/form/NameNsDescription.vue +147 -115
- package/components/form/Networking.vue +20 -12
- package/components/form/NodeAffinity.vue +31 -23
- package/components/form/NodeScheduling.vue +13 -3
- package/components/form/Password.vue +11 -5
- package/components/form/PodAffinity.vue +43 -44
- package/components/form/Probe.vue +68 -66
- package/components/form/ResourceQuota/Project.vue +5 -1
- package/components/form/ResourceSelector.vue +7 -9
- package/components/form/SSHKnownHosts/KnownHostsEditDialog.vue +6 -3
- package/components/form/SSHKnownHosts/__tests__/KnownHostsEditDialog.test.ts +12 -1
- package/components/form/SSHKnownHosts/index.vue +16 -2
- package/components/form/Security.vue +54 -56
- package/components/form/Select.vue +41 -7
- package/components/form/ShellInput.vue +5 -1
- package/components/form/Tolerations.vue +5 -1
- package/components/form/UnitInput.vue +2 -2
- package/components/form/ValueFromResource.vue +134 -121
- package/components/form/WorkloadPorts.vue +18 -18
- package/components/form/__tests__/ArrayList.test.ts +5 -2
- package/components/form/__tests__/MatchExpressions.test.ts +12 -12
- package/components/form/__tests__/NameNsDescription.test.ts +115 -14
- package/components/form/__tests__/Probe.test.ts +12 -8
- package/components/form/__tests__/SSHKnownHosts.test.ts +11 -0
- package/components/form/__tests__/Select.test.ts +37 -0
- package/components/form/__tests__/UnitInput.test.ts +4 -5
- package/components/formatter/BadgeStateFormatter.vue +8 -5
- package/components/formatter/InternalExternalIP.vue +2 -0
- package/components/formatter/SecretData.vue +20 -7
- package/components/nav/Favorite.vue +5 -1
- package/components/nav/Group.vue +60 -27
- package/components/nav/Header.vue +39 -13
- package/components/nav/Jump.vue +7 -0
- package/components/nav/NamespaceFilter.vue +14 -8
- package/components/nav/Pinned.vue +1 -1
- package/components/nav/TopLevelMenu.vue +5 -17
- package/components/nav/Type.vue +32 -35
- package/components/nav/__tests__/TopLevelMenu.test.ts +0 -40
- package/components/templates/blank.vue +4 -1
- package/components/templates/default.vue +8 -0
- package/components/templates/home.vue +10 -1
- package/components/templates/plain.vue +10 -1
- package/package.json +1 -1
- package/rancher-components/Banner/Banner.vue +6 -4
- package/rancher-components/Card/Card.vue +6 -4
- package/rancher-components/Form/Checkbox/Checkbox.vue +20 -1
- package/rancher-components/Form/LabeledInput/LabeledInput.vue +46 -5
- package/rancher-components/Form/Radio/RadioButton.vue +32 -8
- package/rancher-components/Form/Radio/RadioGroup.vue +31 -24
- package/rancher-components/Form/ToggleSwitch/ToggleSwitch.test.ts +17 -0
- package/rancher-components/Form/ToggleSwitch/ToggleSwitch.vue +8 -3
- package/rancher-components/LabeledTooltip/LabeledTooltip.vue +15 -3
- package/rancher-components/RcButton/RcButton.vue +1 -0
- package/rancher-components/RcButton/types.ts +1 -0
- package/rancher-components/RcDropdown/RcDropdown.vue +54 -15
- package/rancher-components/RcDropdown/RcDropdownItem.vue +5 -4
- package/rancher-components/RcDropdown/RcDropdownMenu.vue +11 -7
- package/rancher-components/RcDropdown/RcDropdownTrigger.vue +12 -2
- package/rancher-components/RcDropdown/useDropdownCollection.ts +8 -0
- package/rancher-components/RcDropdown/useDropdownContext.ts +9 -3
- package/rancher-components/StringList/StringList.vue +1 -1
- package/store/type-map.js +29 -2
- package/utils/error.js +30 -8
- package/utils/errorTranslate.json +916 -0
- package/vue.config.js +1 -1
- package/components/formatter/ExtensionCache.vue +0 -74
- package/components/formatter/Port.vue +0 -24
- package/components/formatter/SecretType.vue +0 -41
|
@@ -103,9 +103,6 @@ export default {
|
|
|
103
103
|
|
|
104
104
|
<template>
|
|
105
105
|
<div>
|
|
106
|
-
<p class="set-landing-leadin">
|
|
107
|
-
{{ t('landing.landingPrefs.body') }}
|
|
108
|
-
</p>
|
|
109
106
|
<RadioGroup
|
|
110
107
|
id="login-route"
|
|
111
108
|
:value="afterLoginRoute"
|
|
@@ -113,6 +110,11 @@ export default {
|
|
|
113
110
|
:options="routeRadioOptions"
|
|
114
111
|
@update:value="updateLoginRoute"
|
|
115
112
|
>
|
|
113
|
+
<template #label>
|
|
114
|
+
<p class="set-landing-leadin">
|
|
115
|
+
{{ t('landing.landingPrefs.body') }}
|
|
116
|
+
</p>
|
|
117
|
+
</template>
|
|
116
118
|
<template #2="{option}">
|
|
117
119
|
<div class="custom-page">
|
|
118
120
|
<RadioButton
|
|
@@ -1,11 +1,17 @@
|
|
|
1
1
|
<script>
|
|
2
2
|
import { mapGetters } from 'vuex';
|
|
3
3
|
import Select from '@shell/components/form/Select.vue';
|
|
4
|
+
import { RcDropdown, RcDropdownTrigger, RcDropdownItem } from '@components/RcDropdown';
|
|
4
5
|
|
|
5
6
|
export default {
|
|
6
7
|
name: 'LocalSelector',
|
|
7
8
|
|
|
8
|
-
components: {
|
|
9
|
+
components: {
|
|
10
|
+
Select,
|
|
11
|
+
RcDropdown,
|
|
12
|
+
RcDropdownItem,
|
|
13
|
+
RcDropdownTrigger,
|
|
14
|
+
},
|
|
9
15
|
|
|
10
16
|
props: {
|
|
11
17
|
mode: {
|
|
@@ -65,111 +71,51 @@ export default {
|
|
|
65
71
|
<template>
|
|
66
72
|
<div>
|
|
67
73
|
<div v-if="mode === 'login'">
|
|
68
|
-
<
|
|
69
|
-
|
|
70
|
-
|
|
71
|
-
|
|
72
|
-
|
|
73
|
-
|
|
74
|
-
@click="openLocaleSelector"
|
|
75
|
-
@blur.capture="closeLocaleSelector"
|
|
76
|
-
@keyup.enter="openLocaleSelector"
|
|
77
|
-
@keyup.space="openLocaleSelector"
|
|
78
|
-
>
|
|
79
|
-
<v-dropdown
|
|
80
|
-
popperClass="localeSelector"
|
|
81
|
-
:shown="isLocaleSelectorOpen"
|
|
82
|
-
placement="top"
|
|
83
|
-
distance="8"
|
|
84
|
-
skidding="12"
|
|
85
|
-
:triggers="[]"
|
|
86
|
-
:autoHide="false"
|
|
87
|
-
:flip="false"
|
|
88
|
-
:container="false"
|
|
89
|
-
@focus.capture="openLocaleSelector"
|
|
74
|
+
<rc-dropdown v-if="showLocale">
|
|
75
|
+
<rc-dropdown-trigger
|
|
76
|
+
data-testid="locale-selector"
|
|
77
|
+
link
|
|
78
|
+
class="baseline"
|
|
79
|
+
:aria-label="t('locale.menu')"
|
|
90
80
|
>
|
|
91
|
-
|
|
92
|
-
|
|
93
|
-
|
|
81
|
+
{{ selectedLocaleLabel }}
|
|
82
|
+
<template
|
|
83
|
+
v-if="showIcon"
|
|
84
|
+
#after
|
|
94
85
|
>
|
|
95
|
-
|
|
96
|
-
<i
|
|
97
|
-
v-if="showIcon"
|
|
98
|
-
class="icon icon-fw icon-sort-down"
|
|
99
|
-
/>
|
|
100
|
-
</a>
|
|
101
|
-
<template #popper>
|
|
102
|
-
<ul
|
|
103
|
-
class="list-unstyled dropdown"
|
|
104
|
-
style="margin: -1px;"
|
|
105
|
-
>
|
|
106
|
-
<li
|
|
107
|
-
v-if="showNone"
|
|
108
|
-
v-t="'locale.none'"
|
|
109
|
-
class="hand"
|
|
110
|
-
tabindex="0"
|
|
111
|
-
role="menuitem"
|
|
112
|
-
@click.stop="switchLocale('none')"
|
|
113
|
-
@keyup.enter.stop="switchLocale('none')"
|
|
114
|
-
@keyup.space.stop="switchLocale('none')"
|
|
115
|
-
/>
|
|
116
|
-
<li
|
|
117
|
-
v-for="(label, name) in availableLocales"
|
|
118
|
-
:key="name"
|
|
119
|
-
tabindex="0"
|
|
120
|
-
role="menuitem"
|
|
121
|
-
class="hand"
|
|
122
|
-
@click.stop="switchLocale(name)"
|
|
123
|
-
@keyup.enter.stop="switchLocale(name)"
|
|
124
|
-
@keyup.space.stop="switchLocale(name)"
|
|
125
|
-
>
|
|
126
|
-
{{ label }}
|
|
127
|
-
</li>
|
|
128
|
-
</ul>
|
|
86
|
+
<i class="icon icon-fw icon-sort-down" />
|
|
129
87
|
</template>
|
|
130
|
-
</
|
|
131
|
-
|
|
88
|
+
</rc-dropdown-trigger>
|
|
89
|
+
<template #dropdownCollection>
|
|
90
|
+
<rc-dropdown-item
|
|
91
|
+
v-if="showNone"
|
|
92
|
+
v-t="'locale.none'"
|
|
93
|
+
@click="switchLocale('none')"
|
|
94
|
+
/>
|
|
95
|
+
<rc-dropdown-item
|
|
96
|
+
v-for="(label, name) in availableLocales"
|
|
97
|
+
:key="name"
|
|
98
|
+
:lang="name"
|
|
99
|
+
@click.stop="switchLocale(name)"
|
|
100
|
+
>
|
|
101
|
+
{{ label }}
|
|
102
|
+
</rc-dropdown-item>
|
|
103
|
+
</template>
|
|
104
|
+
</rc-dropdown>
|
|
132
105
|
</div>
|
|
133
106
|
<div v-else>
|
|
134
107
|
<Select
|
|
135
108
|
:value="selectedOption"
|
|
136
109
|
:options="localesOptions"
|
|
110
|
+
:is-lang-select="true"
|
|
137
111
|
@update:value="switchLocale($event)"
|
|
138
112
|
/>
|
|
139
113
|
</div>
|
|
140
114
|
</div>
|
|
141
115
|
</template>
|
|
142
116
|
|
|
143
|
-
<style lang="scss"
|
|
144
|
-
.
|
|
145
|
-
|
|
146
|
-
padding: 0 5px;
|
|
147
|
-
line-height: 40px;
|
|
148
|
-
font-size: 15px;
|
|
149
|
-
font-weight: 500;
|
|
150
|
-
}
|
|
151
|
-
.content {
|
|
152
|
-
background: var(--nav-active);
|
|
153
|
-
padding: 10px;
|
|
154
|
-
margin-top: 6px;
|
|
155
|
-
border-radius: 4px;
|
|
156
|
-
}
|
|
157
|
-
|
|
158
|
-
.hand:focus-visible {
|
|
159
|
-
@include focus-outline;
|
|
160
|
-
outline-offset: 4px;
|
|
161
|
-
}
|
|
162
|
-
|
|
163
|
-
.locale-chooser {
|
|
164
|
-
cursor: pointer;
|
|
165
|
-
|
|
166
|
-
&:hover {
|
|
167
|
-
text-decoration: none;
|
|
117
|
+
<style lang="scss">
|
|
118
|
+
.baseline {
|
|
119
|
+
align-items: baseline;
|
|
168
120
|
}
|
|
169
|
-
}
|
|
170
|
-
|
|
171
|
-
.locale-login-container:focus-visible {
|
|
172
|
-
@include focus-outline;
|
|
173
|
-
outline-offset: 2px;
|
|
174
|
-
}
|
|
175
121
|
</style>
|
|
@@ -0,0 +1,55 @@
|
|
|
1
|
+
<script lang="ts" setup>
|
|
2
|
+
import { computed, ref } from 'vue';
|
|
3
|
+
import { useStore } from 'vuex';
|
|
4
|
+
|
|
5
|
+
import AppModal from '@shell/components/AppModal.vue';
|
|
6
|
+
|
|
7
|
+
const store = useStore();
|
|
8
|
+
|
|
9
|
+
const isOpen = computed(() => store.getters['modal/isOpen']);
|
|
10
|
+
const component = computed(() => store.getters['modal/component']);
|
|
11
|
+
const componentProps = computed(() => store.getters['modal/componentProps']);
|
|
12
|
+
const resources = computed(() => store.getters['modal/resources']);
|
|
13
|
+
const closeOnClickOutside = computed(() => store.getters['modal/closeOnClickOutside']);
|
|
14
|
+
const modalWidth = computed(() => store.getters['modal/modalWidth']);
|
|
15
|
+
// const modalSticky = computed(() => store.getters['modal/modalSticky']); // TODO: Implement sticky modals
|
|
16
|
+
|
|
17
|
+
const backgroundClosing = ref<Function | null>(null);
|
|
18
|
+
|
|
19
|
+
function close() {
|
|
20
|
+
if (!isOpen.value) return;
|
|
21
|
+
|
|
22
|
+
if (backgroundClosing.value) {
|
|
23
|
+
backgroundClosing.value();
|
|
24
|
+
}
|
|
25
|
+
|
|
26
|
+
store.commit('modal/closeModal');
|
|
27
|
+
}
|
|
28
|
+
|
|
29
|
+
function registerBackgroundClosing(fn: Function) {
|
|
30
|
+
backgroundClosing.value = fn;
|
|
31
|
+
}
|
|
32
|
+
</script>
|
|
33
|
+
|
|
34
|
+
<template>
|
|
35
|
+
<Teleport to="#modals">
|
|
36
|
+
<app-modal
|
|
37
|
+
v-if="isOpen && component"
|
|
38
|
+
:click-to-close="closeOnClickOutside"
|
|
39
|
+
:width="modalWidth"
|
|
40
|
+
:style="{ '--prompt-modal-width': modalWidth }"
|
|
41
|
+
:trigger-focus-trap="true"
|
|
42
|
+
tabindex="0"
|
|
43
|
+
@close="close"
|
|
44
|
+
>
|
|
45
|
+
<component
|
|
46
|
+
:is="component"
|
|
47
|
+
v-bind="componentProps || {}"
|
|
48
|
+
data-testid="modal-manager-component"
|
|
49
|
+
:resources="resources"
|
|
50
|
+
:register-background-closing="registerBackgroundClosing"
|
|
51
|
+
@close="close"
|
|
52
|
+
/>
|
|
53
|
+
</app-modal>
|
|
54
|
+
</Teleport>
|
|
55
|
+
</template>
|
|
@@ -65,6 +65,7 @@ export default {
|
|
|
65
65
|
v-bind="$attrs"
|
|
66
66
|
class="modal"
|
|
67
67
|
data-testid="mvc__card"
|
|
68
|
+
:trigger-focus-trap="true"
|
|
68
69
|
@close="$emit('finish', $event)"
|
|
69
70
|
>
|
|
70
71
|
<Card
|
|
@@ -132,6 +133,7 @@ export default {
|
|
|
132
133
|
|
|
133
134
|
&.card-container {
|
|
134
135
|
box-shadow: none;
|
|
136
|
+
padding: 14px;
|
|
135
137
|
}
|
|
136
138
|
}
|
|
137
139
|
</style>
|
package/components/MoveModal.vue
CHANGED
|
@@ -13,7 +13,11 @@ export default {
|
|
|
13
13
|
components: { AppModal },
|
|
14
14
|
|
|
15
15
|
data() {
|
|
16
|
-
return {
|
|
16
|
+
return {
|
|
17
|
+
opened: false,
|
|
18
|
+
backgroundClosing: null,
|
|
19
|
+
componentRendered: false
|
|
20
|
+
};
|
|
17
21
|
},
|
|
18
22
|
|
|
19
23
|
computed: {
|
|
@@ -54,10 +58,15 @@ export default {
|
|
|
54
58
|
watch: {
|
|
55
59
|
showModal(show) {
|
|
56
60
|
this.opened = show;
|
|
57
|
-
}
|
|
61
|
+
}
|
|
58
62
|
},
|
|
59
63
|
|
|
60
64
|
methods: {
|
|
65
|
+
onSlotComponentMounted() {
|
|
66
|
+
// variable for the watcher based focus-trap
|
|
67
|
+
// so that we know when the component is rendered
|
|
68
|
+
this.componentRendered = true;
|
|
69
|
+
},
|
|
61
70
|
close() {
|
|
62
71
|
if (!this.opened) {
|
|
63
72
|
return;
|
|
@@ -69,6 +78,7 @@ export default {
|
|
|
69
78
|
this.backgroundClosing();
|
|
70
79
|
}
|
|
71
80
|
|
|
81
|
+
this.componentRendered = false;
|
|
72
82
|
this.opened = false;
|
|
73
83
|
},
|
|
74
84
|
|
|
@@ -85,6 +95,8 @@ export default {
|
|
|
85
95
|
v-if="opened && component"
|
|
86
96
|
:click-to-close="closeOnClickOutside"
|
|
87
97
|
:width="modalWidth"
|
|
98
|
+
:trigger-focus-trap-watcher-based="true"
|
|
99
|
+
:focus-trap-watcher-based-variable="componentRendered"
|
|
88
100
|
@close="close()"
|
|
89
101
|
>
|
|
90
102
|
<component
|
|
@@ -92,6 +104,7 @@ export default {
|
|
|
92
104
|
:is="component"
|
|
93
105
|
:resources="resources"
|
|
94
106
|
:register-background-closing="registerBackgroundClosing"
|
|
107
|
+
@vue:mounted="onSlotComponentMounted"
|
|
95
108
|
@close="close()"
|
|
96
109
|
/>
|
|
97
110
|
</app-modal>
|
|
@@ -12,6 +12,7 @@ import { CATALOG as CATALOG_ANNOTATIONS } from '@shell/config/labels-annotations
|
|
|
12
12
|
import { CATALOG } from '@shell/config/types';
|
|
13
13
|
import { LabeledInput } from '@components/Form/LabeledInput';
|
|
14
14
|
import AppModal from '@shell/components/AppModal.vue';
|
|
15
|
+
import { translateError } from '@shell/utils/error';
|
|
15
16
|
|
|
16
17
|
export default {
|
|
17
18
|
name: 'PromptRemove',
|
|
@@ -213,6 +214,7 @@ export default {
|
|
|
213
214
|
},
|
|
214
215
|
|
|
215
216
|
methods: {
|
|
217
|
+
translateError,
|
|
216
218
|
resourceNames,
|
|
217
219
|
escapeHtml,
|
|
218
220
|
close() {
|
|
@@ -336,9 +338,10 @@ export default {
|
|
|
336
338
|
v-if="showModal"
|
|
337
339
|
custom-class="remove-modal"
|
|
338
340
|
name="promptRemove"
|
|
339
|
-
:width="
|
|
341
|
+
:width="460"
|
|
340
342
|
height="auto"
|
|
341
343
|
styles="max-height: 100vh;"
|
|
344
|
+
:trigger-focus-trap="true"
|
|
342
345
|
@close="close"
|
|
343
346
|
>
|
|
344
347
|
<Card
|
|
@@ -347,6 +350,11 @@ export default {
|
|
|
347
350
|
>
|
|
348
351
|
<template #title>
|
|
349
352
|
<h4 class="text-default-text">
|
|
353
|
+
<img
|
|
354
|
+
src="@shell/assets/images/promp-yellow.svg"
|
|
355
|
+
class="img-span"
|
|
356
|
+
alt=""
|
|
357
|
+
>
|
|
350
358
|
{{ t('promptRemove.title') }}
|
|
351
359
|
</h4>
|
|
352
360
|
</template>
|
|
@@ -354,7 +362,7 @@ export default {
|
|
|
354
362
|
<div class="mb-10">
|
|
355
363
|
<template v-if="!hasCustomRemove">
|
|
356
364
|
{{ t('promptRemove.attemptingToRemove', { type }) }} <span
|
|
357
|
-
v-clean-html="resourceNames(names, t)"
|
|
365
|
+
v-clean-html="resourceNames(names, null, t)"
|
|
358
366
|
/>
|
|
359
367
|
</template>
|
|
360
368
|
|
|
@@ -395,14 +403,14 @@ export default {
|
|
|
395
403
|
{{ warning }}
|
|
396
404
|
</div>
|
|
397
405
|
<div class="text-error mb-10 mt-10">
|
|
398
|
-
{{ error }}
|
|
406
|
+
{{ translateError(error) }}
|
|
399
407
|
</div>
|
|
400
|
-
<div
|
|
408
|
+
<!-- <div
|
|
401
409
|
v-if="!needsConfirm"
|
|
402
410
|
class="text-info mt-20"
|
|
403
411
|
>
|
|
404
412
|
{{ protip }}
|
|
405
|
-
</div>
|
|
413
|
+
</div> -->
|
|
406
414
|
</LabeledInput>
|
|
407
415
|
<div v-else-if="!hasCustomRemove">
|
|
408
416
|
<div
|
|
@@ -436,7 +444,7 @@ export default {
|
|
|
436
444
|
<div class="spacer" />
|
|
437
445
|
<AsyncButton
|
|
438
446
|
mode="delete"
|
|
439
|
-
class="btn
|
|
447
|
+
class="btn ml-10"
|
|
440
448
|
:disabled="deleteDisabled"
|
|
441
449
|
:data-testid="componentTestid + '-confirm-button'"
|
|
442
450
|
@click="remove"
|
|
@@ -460,12 +468,24 @@ export default {
|
|
|
460
468
|
text-align: right;
|
|
461
469
|
}
|
|
462
470
|
|
|
463
|
-
.card-actions {
|
|
471
|
+
/* .card-actions {
|
|
464
472
|
display: flex;
|
|
465
473
|
|
|
466
474
|
.spacer {
|
|
467
475
|
flex: 1;
|
|
468
476
|
}
|
|
469
|
-
}
|
|
477
|
+
} */
|
|
470
478
|
}
|
|
471
479
|
</style>
|
|
480
|
+
|
|
481
|
+
<style scoped>
|
|
482
|
+
.text-default-text{
|
|
483
|
+
line-height: 20px;
|
|
484
|
+
margin: 0px;
|
|
485
|
+
display: flex;
|
|
486
|
+
align-items: center;
|
|
487
|
+
}
|
|
488
|
+
.img-span{
|
|
489
|
+
margin-right: 8px;
|
|
490
|
+
}
|
|
491
|
+
</style>
|