dashboard-shell-shell 3.0.5-test.9 → 3.0.5-tsh.1
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/assets/brand/csp/favicon.png +0 -0
- package/assets/icons/iconfont.css +4 -1
- package/assets/images/pl/dark/logo.png +0 -0
- package/assets/styles/all.scss +23 -3
- package/assets/styles/base/_variables.scss +2 -2
- package/assets/styles/fonts/_icons.scss +3 -2
- package/assets/styles/global/_button.scss +1 -1
- package/assets/styles/global/_form.scss +1 -0
- package/assets/styles/global/_select.scss +1 -1
- package/assets/styles/global/_tooltip.scss +5 -1
- package/assets/styles/themes/_light.scss +3 -3
- package/assets/styles/vendor/vue-select.scss +2 -1
- package/assets/translations/en-us.yaml +60 -0
- package/assets/translations/zh-hans.yaml +164 -21
- package/components/ButtonDropdown.vue +3 -1
- package/components/ClusterIconMenu.vue +1 -1
- package/components/CodeMirror.vue +6 -4
- package/components/ConsumptionGauge.vue +1 -1
- package/components/ContainerResourceLimit.vue +2 -2
- package/components/CruResource.vue +3 -2
- package/components/Drawer/ResourceDetailDrawer/ConfigTab.vue +22 -19
- package/components/Drawer/ResourceDetailDrawer/index.vue +3 -3
- package/components/ExplorerMembers.vue +10 -1
- package/components/GlobalRoleBindings.vue +52 -112
- package/components/PodSecurityAdmission.vue +1 -1
- package/components/PromptRemove.vue +23 -1
- package/components/RelatedResources.vue +3 -0
- package/components/Resource/Detail/TitleBar/composables.ts +16 -1
- package/components/Resource/Detail/TitleBar/index.vue +37 -24
- package/components/ResourceDetail/Masthead/index.vue +1 -1
- package/components/ResourceDetail/Masthead/latest.vue +1 -1
- package/components/ResourceDetail/Masthead/legacy.vue +8 -7
- package/components/ResourceDetail/legacy.vue +15 -15
- package/components/ResourceList/Masthead.vue +11 -15
- package/components/ResourceTable.vue +16 -0
- package/components/SideNav.vue +21 -21
- package/components/SingleClusterInfo.vue +2 -1
- package/components/SortableTable/THead.vue +46 -1
- package/components/SortableTable/index.vue +54 -18
- package/components/Tabbed/index.vue +6 -1
- package/components/auth/Principal.vue +16 -8
- package/components/auth/RoleDetailEdit.vue +11 -7
- package/components/breadcrumb/index.vue +13 -210
- package/components/form/ArrayList.vue +164 -147
- package/components/form/ArrayListGrouped.vue +5 -3
- package/components/form/ChangePassword.vue +1 -1
- package/components/form/ClusterAppearance.vue +4 -3
- package/components/form/Command.vue +4 -5
- package/components/form/Conditions.vue +15 -1
- package/components/form/Footer.vue +1 -0
- package/components/form/HealthCheck.vue +0 -2
- package/components/form/HookOption.vue +87 -58
- package/components/form/InputWithSelect.vue +8 -7
- package/components/form/KeyValue.vue +20 -2
- package/components/form/LabeledSelect.vue +3 -1
- package/components/form/Labels.vue +2 -2
- package/components/form/MatchExpressions.vue +4 -4
- package/components/form/Members/ClusterMembershipEditor.vue +1 -1
- package/components/form/Members/ClusterPermissionsEditor.vue +31 -28
- package/components/form/Members/MembershipEditor.vue +3 -3
- package/components/form/Members/ProjectMembershipEditor.vue +1 -1
- package/components/form/NameNsDescription.vue +4 -2
- package/components/form/Networking.vue +6 -9
- package/components/form/NodeAffinity.vue +29 -28
- package/components/form/PodAffinity.vue +23 -23
- package/components/form/Probe.vue +15 -11
- package/components/form/ProjectMemberEditor.vue +28 -25
- package/components/form/ResourceQuota/Namespace.vue +4 -4
- package/components/form/ResourceQuota/NamespaceRow.vue +11 -9
- package/components/form/ResourceQuota/Project.vue +4 -4
- package/components/form/ResourceQuota/ProjectRow.vue +36 -30
- package/components/form/ResourceSelector.vue +1 -1
- package/components/form/Security.vue +1 -3
- package/components/form/Select.vue +7 -1
- package/components/form/ServiceNameSelect.vue +2 -5
- package/components/form/ServicePorts.vue +149 -75
- package/components/form/Tolerations.vue +13 -9
- package/components/form/ValueFromResource.vue +110 -96
- package/components/formatter/WorkloadHealthScale.vue +4 -3
- package/components/nav/Group.vue +6 -0
- package/components/nav/Header.vue +17 -137
- package/components/nav/NamespaceFilter.vue +14 -19
- package/components/nav/TopLevelMenu.vue +99 -125
- package/components/nav/Type.vue +11 -3
- package/config/menuRouteMap.js +10 -0
- package/config/product/explorer.js +32 -10
- package/config/product/manager.js +28 -17
- package/config/router/navigation-guards/index.js +61 -3
- package/detail/node.vue +28 -23
- package/dialog/AddCustomBadgeDialog.vue +17 -9
- package/dialog/RollbackWorkloadDialog.vue +1 -1
- package/edit/autoscaling.horizontalpodautoscaler/external-metric.vue +1 -1
- package/edit/autoscaling.horizontalpodautoscaler/hpa-scaling-rule.vue +9 -6
- package/edit/autoscaling.horizontalpodautoscaler/index.vue +3 -1
- package/edit/autoscaling.horizontalpodautoscaler/metric-identifier.vue +2 -2
- package/edit/autoscaling.horizontalpodautoscaler/metric-object-reference.vue +7 -5
- package/edit/autoscaling.horizontalpodautoscaler/metric-target.vue +5 -3
- package/edit/autoscaling.horizontalpodautoscaler/metrics-row.vue +2 -2
- package/edit/autoscaling.horizontalpodautoscaler/object-metric.vue +2 -2
- package/edit/autoscaling.horizontalpodautoscaler/pod-metric.vue +1 -1
- package/edit/autoscaling.horizontalpodautoscaler/resource-metric.vue +2 -2
- package/edit/configmap.vue +4 -0
- package/edit/monitoring.coreos.com.alertmanagerconfig/receiverConfig.vue +32 -8
- package/edit/monitoring.coreos.com.alertmanagerconfig/types/dingding.vue +24 -0
- package/edit/monitoring.coreos.com.alertmanagerconfig/types/message.vue +39 -0
- package/edit/monitoring.coreos.com.alertmanagerconfig/types/snmp.vue +32 -0
- package/edit/monitoring.coreos.com.alertmanagerconfig/types/work.vue +16 -0
- package/edit/networking.k8s.io.ingress/Certificate.vue +14 -5
- package/edit/networking.k8s.io.ingress/DefaultBackend.vue +2 -2
- package/edit/networking.k8s.io.ingress/Rule.vue +5 -11
- package/edit/networking.k8s.io.ingress/RulePath.vue +105 -96
- package/edit/networking.k8s.io.networkpolicy/PolicyRule.vue +3 -3
- package/edit/networking.k8s.io.networkpolicy/PolicyRulePort.vue +4 -2
- package/edit/networking.k8s.io.networkpolicy/PolicyRuleTarget.vue +12 -11
- package/edit/networking.k8s.io.networkpolicy/index.vue +1 -1
- package/edit/persistentvolume/index.vue +3 -1
- package/edit/persistentvolumeclaim.vue +2 -0
- package/edit/provisioning.cattle.io.cluster/tabs/Basics.vue +1 -1
- package/edit/secret/index.vue +2 -2
- package/edit/service.vue +4 -1
- package/edit/storage.k8s.io.storageclass/index.vue +10 -8
- package/edit/storage.k8s.io.storageclass/provisioners/kubernetes.io/aws-ebs.vue +34 -27
- package/edit/storage.k8s.io.storageclass/provisioners/kubernetes.io/gce-pd.vue +15 -13
- package/edit/storage.k8s.io.storageclass/provisioners/kubernetes.io/vsphere-volume.vue +41 -39
- package/edit/workload/Job.vue +31 -34
- package/edit/workload/Upgrading.vue +5 -5
- package/edit/workload/index.vue +19 -15
- package/edit/workload/storage/Mount.vue +1 -0
- package/edit/workload/storage/awsElasticBlockStore.vue +9 -7
- package/edit/workload/storage/azureDisk.vue +14 -10
- package/edit/workload/storage/azureFile.vue +9 -7
- package/edit/workload/storage/csi/index.vue +6 -9
- package/edit/workload/storage/emptyDir.vue +7 -5
- package/edit/workload/storage/gcePersistentDisk.vue +9 -7
- package/edit/workload/storage/hostPath.vue +7 -5
- package/edit/workload/storage/nfs.vue +8 -6
- package/edit/workload/storage/persistentVolumeClaim/index.vue +12 -10
- package/edit/workload/storage/persistentVolumeClaim/persistentvolumeclaim.vue +20 -15
- package/edit/workload/storage/secret.vue +9 -6
- package/edit/workload/storage/vsphereVolume.vue +11 -7
- package/initialize/app-extended.js +7 -1
- package/list/management.cattle.io.podsecurityadmissionconfigurationtemplate.vue +8 -6
- package/mixins/create-edit-view/impl.js +10 -0
- package/models/provisioning.cattle.io.cluster.js +19 -18
- package/models/workload.js +2 -2
- package/package.json +1 -1
- package/pages/account/index.vue +93 -58
- package/pages/auth/login.vue +1 -1
- package/pages/auth/setup.vue +36 -17
- package/pages/c/_cluster/explorer/ConfigBadge.vue +1 -1
- package/pages/c/_cluster/explorer/index.vue +2 -1
- package/pages/c/_cluster/explorer/tools/index.vue +6 -6
- package/pages/home.vue +55 -13
- package/plugins/dashboard-store/actions.js +1 -1
- package/rancher-components/Banner/Banner.vue +14 -2
- package/rancher-components/Form/Radio/RadioGroup.vue +9 -1
- package/rancher-components/LabeledTooltip/LabeledTooltip.vue +31 -2
- package/scripts/build-pkg.sh +18 -23
- package/scripts/publish-shell.sh +1 -1
- package/store/i18n.js +1 -0
- package/store/type-map.js +0 -2
- package/utils/error.js +23 -3
- package/utils/errorTranslate.json +377 -8
- package/utils/errorTranslateNew.json +39 -0
package/pages/account/index.vue
CHANGED
|
@@ -151,48 +151,40 @@ export default {
|
|
|
151
151
|
<template>
|
|
152
152
|
<Loading v-if="$fetchState.pending" />
|
|
153
153
|
<div v-else>
|
|
154
|
-
<
|
|
155
|
-
|
|
156
|
-
<
|
|
157
|
-
|
|
158
|
-
|
|
159
|
-
|
|
160
|
-
|
|
161
|
-
<h2 v-t="'accountAndKeys.account.title'" />
|
|
162
|
-
<div class="account">
|
|
163
|
-
<Principal
|
|
164
|
-
:value="principal.id"
|
|
165
|
-
:use-muted="false"
|
|
166
|
-
:show-labels="true"
|
|
167
|
-
/>
|
|
168
|
-
<div>
|
|
169
|
-
<button
|
|
170
|
-
v-if="canChangePassword"
|
|
171
|
-
role="button"
|
|
172
|
-
:aria-label="t('accountAndKeys.account.change')"
|
|
173
|
-
type="button"
|
|
174
|
-
class="btn role-primary"
|
|
175
|
-
data-testid="account_change_password"
|
|
176
|
-
@click="showChangePasswordDialog"
|
|
177
|
-
>
|
|
178
|
-
{{ t("accountAndKeys.account.change") }}
|
|
179
|
-
</button>
|
|
154
|
+
<div style="display: flex;align-items: center;margin-bottom: 20px;">
|
|
155
|
+
<!-- <BackLink class="backLinkCls" :link="backLink" /> -->
|
|
156
|
+
<div style="font-size: 26px;">
|
|
157
|
+
<TabTitle breadcrumb="vendor-only">
|
|
158
|
+
{{ t('accountAndKeys.title') }}
|
|
159
|
+
</TabTitle>
|
|
180
160
|
</div>
|
|
181
161
|
</div>
|
|
182
162
|
|
|
183
|
-
<
|
|
184
|
-
|
|
185
|
-
<div>
|
|
186
|
-
<
|
|
187
|
-
|
|
188
|
-
|
|
189
|
-
|
|
190
|
-
|
|
191
|
-
|
|
192
|
-
|
|
163
|
+
<div class="account_card mb-20">
|
|
164
|
+
<h5 v-t="'accountAndKeys.account.title'" />
|
|
165
|
+
<div class="account">
|
|
166
|
+
<Principal
|
|
167
|
+
:userLogo="true"
|
|
168
|
+
:userLogoSize="79"
|
|
169
|
+
:value="principal.id"
|
|
170
|
+
:use-muted="false"
|
|
171
|
+
:show-labels="true"
|
|
172
|
+
/>
|
|
173
|
+
<div>
|
|
174
|
+
<button
|
|
175
|
+
v-if="canChangePassword"
|
|
176
|
+
role="button"
|
|
177
|
+
:aria-label="t('accountAndKeys.account.change')"
|
|
178
|
+
type="button"
|
|
179
|
+
class="btn role-primary"
|
|
180
|
+
data-testid="account_change_password"
|
|
181
|
+
@click="showChangePasswordDialog"
|
|
182
|
+
>
|
|
183
|
+
{{ t("accountAndKeys.account.change") }}
|
|
184
|
+
</button>
|
|
193
185
|
</div>
|
|
194
186
|
</div>
|
|
195
|
-
<button
|
|
187
|
+
<!-- <button
|
|
196
188
|
v-if="apiKeySchema"
|
|
197
189
|
role="button"
|
|
198
190
|
:aria-label="t('accountAndKeys.apiKeys.add.label')"
|
|
@@ -201,33 +193,71 @@ export default {
|
|
|
201
193
|
@click="addKey"
|
|
202
194
|
>
|
|
203
195
|
{{ t('accountAndKeys.apiKeys.add.label') }}
|
|
204
|
-
</button>
|
|
205
|
-
</div>
|
|
206
|
-
<div
|
|
207
|
-
v-if="apiKeySchema"
|
|
208
|
-
class="keys"
|
|
209
|
-
>
|
|
210
|
-
<ResourceTable
|
|
211
|
-
:schema="apiKeySchema"
|
|
212
|
-
:rows="apiKeys"
|
|
213
|
-
:headers="apiKeyheaders"
|
|
214
|
-
key-field="id"
|
|
215
|
-
data-testid="api_keys_list"
|
|
216
|
-
:search="true"
|
|
217
|
-
:row-actions="true"
|
|
218
|
-
:table-actions="true"
|
|
219
|
-
/>
|
|
196
|
+
</button> -->
|
|
220
197
|
</div>
|
|
221
|
-
|
|
222
|
-
|
|
223
|
-
|
|
224
|
-
|
|
225
|
-
|
|
198
|
+
|
|
199
|
+
<div class="account_card mb-20">
|
|
200
|
+
<div class="keys-header">
|
|
201
|
+
<div>
|
|
202
|
+
<h5 v-t="'accountAndKeys.apiKeys.title'" />
|
|
203
|
+
<div class="api-url">
|
|
204
|
+
<span>{{ t("accountAndKeys.apiKeys.apiEndpoint") }}</span>
|
|
205
|
+
<CopyToClipboardText
|
|
206
|
+
:aria-label="t('accountAndKeys.apiKeys.copyApiEnpoint')"
|
|
207
|
+
:text="apiUrl"
|
|
208
|
+
/>
|
|
209
|
+
</div>
|
|
210
|
+
</div>
|
|
211
|
+
</div>
|
|
212
|
+
<div
|
|
213
|
+
v-if="apiKeySchema"
|
|
214
|
+
class="keys"
|
|
215
|
+
>
|
|
216
|
+
<ResourceTable
|
|
217
|
+
:schema="apiKeySchema"
|
|
218
|
+
:rows="apiKeys"
|
|
219
|
+
:headers="apiKeyheaders"
|
|
220
|
+
key-field="id"
|
|
221
|
+
data-testid="api_keys_list"
|
|
222
|
+
:search="true"
|
|
223
|
+
:row-actions="true"
|
|
224
|
+
:table-actions="true"
|
|
225
|
+
>
|
|
226
|
+
<template #header-right>
|
|
227
|
+
<button
|
|
228
|
+
style="margin-right: 10px;"
|
|
229
|
+
v-if="apiKeySchema"
|
|
230
|
+
role="button"
|
|
231
|
+
:aria-label="t('accountAndKeys.apiKeys.add.label')"
|
|
232
|
+
class="btn role-primary add"
|
|
233
|
+
data-testid="account_create_api_keys"
|
|
234
|
+
@click="addKey"
|
|
235
|
+
>
|
|
236
|
+
{{ t('accountAndKeys.apiKeys.add.label') }}
|
|
237
|
+
</button>
|
|
238
|
+
</template>
|
|
239
|
+
</ResourceTable>
|
|
240
|
+
</div>
|
|
241
|
+
<div v-else>
|
|
242
|
+
<Banner
|
|
243
|
+
color="warning"
|
|
244
|
+
:label="t('accountAndKeys.apiKeys.notAllowed')"
|
|
245
|
+
/>
|
|
246
|
+
</div>
|
|
226
247
|
</div>
|
|
227
248
|
</div>
|
|
228
249
|
</template>
|
|
229
250
|
|
|
230
251
|
<style lang='scss' scoped>
|
|
252
|
+
.account_card {
|
|
253
|
+
border: 1px solid #d7d7d7;
|
|
254
|
+
padding: 20px;
|
|
255
|
+
box-sizing: border-box;
|
|
256
|
+
}
|
|
257
|
+
:deep() .back-link {
|
|
258
|
+
font-size: 26px;
|
|
259
|
+
margin: 0 20px 0 0 !important;
|
|
260
|
+
}
|
|
231
261
|
hr {
|
|
232
262
|
margin: 20px 0;
|
|
233
263
|
}
|
|
@@ -237,6 +267,10 @@ export default {
|
|
|
237
267
|
justify-content: space-between
|
|
238
268
|
}
|
|
239
269
|
|
|
270
|
+
.principal .avatar {
|
|
271
|
+
width: 287px !important;
|
|
272
|
+
}
|
|
273
|
+
|
|
240
274
|
.keys-header {
|
|
241
275
|
display: flex;
|
|
242
276
|
div {
|
|
@@ -254,6 +288,7 @@ export default {
|
|
|
254
288
|
|
|
255
289
|
.api-url {
|
|
256
290
|
display: flex;
|
|
291
|
+
margin: 20px 0;
|
|
257
292
|
|
|
258
293
|
> span {
|
|
259
294
|
margin-right: 6px;
|
package/pages/auth/login.vue
CHANGED
|
@@ -312,7 +312,7 @@ export default {
|
|
|
312
312
|
this.$store.dispatch('auth/setInitialPass', this.password);
|
|
313
313
|
this.$router.push({ name: 'auth-setup' });
|
|
314
314
|
} else {
|
|
315
|
-
this.$router.push({ name: '
|
|
315
|
+
this.$router.push({ name: 'home' });
|
|
316
316
|
}
|
|
317
317
|
|
|
318
318
|
} catch (err) {
|
package/pages/auth/setup.vue
CHANGED
|
@@ -21,6 +21,7 @@ import FormValidation from '@shell/mixins/form-validation';
|
|
|
21
21
|
import isUrl from 'is-url';
|
|
22
22
|
import { isLocalhost } from '@shell/utils/validators/setting';
|
|
23
23
|
import Loading from '@shell/components/Loading';
|
|
24
|
+
import { copyTextToClipboard } from '@shell/utils/clipboard';
|
|
24
25
|
|
|
25
26
|
const calcIsFirstLogin = (store) => {
|
|
26
27
|
const firstLoginSetting = store.getters['management/byId'](MANAGEMENT.SETTING, SETTING.FIRST_LOGIN);
|
|
@@ -149,7 +150,7 @@ export default {
|
|
|
149
150
|
this['isFirstLogin'] = isFirstLogin;
|
|
150
151
|
this['mustChangePassword'] = mustChangePassword;
|
|
151
152
|
// this['current'] = current;
|
|
152
|
-
this['current'] = 'admin';
|
|
153
|
+
this['current'] = current || 'admin';
|
|
153
154
|
this['v3User'] = v3User;
|
|
154
155
|
this['serverUrl'] = serverUrl;
|
|
155
156
|
this['mcmEnabled'] = mcmEnabled;
|
|
@@ -259,6 +260,14 @@ export default {
|
|
|
259
260
|
this.$router.replace('/');
|
|
260
261
|
},
|
|
261
262
|
|
|
263
|
+
copyPassword(val) {
|
|
264
|
+
copyTextToClipboard(val).then(() => {
|
|
265
|
+
console.log('复制成功')
|
|
266
|
+
}).catch(() => {
|
|
267
|
+
console.log('复制失败')
|
|
268
|
+
});
|
|
269
|
+
},
|
|
270
|
+
|
|
262
271
|
onServerUrlChange(value) {
|
|
263
272
|
this.serverUrl = value.trim();
|
|
264
273
|
},
|
|
@@ -324,13 +333,14 @@ export default {
|
|
|
324
333
|
>
|
|
325
334
|
<div class="mb-20">
|
|
326
335
|
<RadioGroup
|
|
336
|
+
class="setupRadioGroupCls"
|
|
327
337
|
v-model:value="useRandom"
|
|
328
338
|
data-testid="setup-password-mode"
|
|
329
339
|
name="password-mode"
|
|
330
340
|
:options="passwordOptions"
|
|
331
341
|
/>
|
|
332
342
|
</div>
|
|
333
|
-
<div class="mb-20">
|
|
343
|
+
<div class="setup_radom-password mb-20">
|
|
334
344
|
<LabeledInput
|
|
335
345
|
v-if="useRandom"
|
|
336
346
|
ref="password"
|
|
@@ -347,13 +357,9 @@ export default {
|
|
|
347
357
|
>
|
|
348
358
|
<div
|
|
349
359
|
class="addon"
|
|
350
|
-
style="padding:
|
|
360
|
+
style="padding: 4px 0px 0px;"
|
|
351
361
|
>
|
|
352
|
-
<
|
|
353
|
-
:aria-label="t('setup.copyRandom')"
|
|
354
|
-
:text="password"
|
|
355
|
-
class="btn-sm"
|
|
356
|
-
/>
|
|
362
|
+
<a @click="copyPassword(password)" href="javascript:;">复制</a>
|
|
357
363
|
</div>
|
|
358
364
|
</template>
|
|
359
365
|
</LabeledInput>
|
|
@@ -367,15 +373,17 @@ export default {
|
|
|
367
373
|
:required="true"
|
|
368
374
|
/>
|
|
369
375
|
</div>
|
|
370
|
-
<
|
|
371
|
-
|
|
372
|
-
|
|
373
|
-
|
|
374
|
-
|
|
375
|
-
|
|
376
|
-
|
|
377
|
-
|
|
378
|
-
|
|
376
|
+
<div class="setup_radom-password">
|
|
377
|
+
<Password
|
|
378
|
+
v-show="!useRandom"
|
|
379
|
+
v-model:value.trim="confirm"
|
|
380
|
+
autocomplete="new-password"
|
|
381
|
+
data-testid="setup-password-confirm"
|
|
382
|
+
class="setup-password"
|
|
383
|
+
:label="t('setup.confirmPassword')"
|
|
384
|
+
:required="true"
|
|
385
|
+
/>
|
|
386
|
+
</div>
|
|
379
387
|
</template>
|
|
380
388
|
|
|
381
389
|
<template v-if="isFirstLogin">
|
|
@@ -467,6 +475,16 @@ export default {
|
|
|
467
475
|
</template>
|
|
468
476
|
|
|
469
477
|
<style lang="scss" scoped>
|
|
478
|
+
.setup_radom-password {
|
|
479
|
+
:deep(.label-input-all) LABEL {
|
|
480
|
+
color: #fff;
|
|
481
|
+
}
|
|
482
|
+
}
|
|
483
|
+
.setupRadioGroupCls {
|
|
484
|
+
:deep(.radio-label) {
|
|
485
|
+
color: #fff;
|
|
486
|
+
}
|
|
487
|
+
}
|
|
470
488
|
.principal {
|
|
471
489
|
display: block;
|
|
472
490
|
background: var(--box-bg);
|
|
@@ -538,6 +556,7 @@ export default {
|
|
|
538
556
|
}
|
|
539
557
|
|
|
540
558
|
.setup-title {
|
|
559
|
+
color: #fff;
|
|
541
560
|
:deep() code {
|
|
542
561
|
font-size: 12px;
|
|
543
562
|
padding: 0;
|
|
@@ -694,7 +694,8 @@ export default {
|
|
|
694
694
|
role="link"
|
|
695
695
|
:aria-label="t('nav.clusterTools')"
|
|
696
696
|
>
|
|
697
|
-
|
|
697
|
+
<!-- 禅道 3539 隐藏集群工具 -->
|
|
698
|
+
<!-- <span>{{ t('nav.clusterTools') }}</span> -->
|
|
698
699
|
</router-link>
|
|
699
700
|
</div>
|
|
700
701
|
<ConfigBadge
|
|
@@ -230,7 +230,7 @@ export default {
|
|
|
230
230
|
|
|
231
231
|
.name {
|
|
232
232
|
white-space: nowrap;
|
|
233
|
-
overflow: hidden;
|
|
233
|
+
// overflow: hidden;
|
|
234
234
|
text-overflow: ellipsis;
|
|
235
235
|
margin: 0;
|
|
236
236
|
}
|
|
@@ -249,7 +249,7 @@ export default {
|
|
|
249
249
|
.version {
|
|
250
250
|
color: var(--muted);
|
|
251
251
|
white-space: nowrap;
|
|
252
|
-
overflow: hidden;
|
|
252
|
+
// overflow: hidden;
|
|
253
253
|
text-overflow: ellipsis;
|
|
254
254
|
font-size: 0.9em;
|
|
255
255
|
margin-top: 4px;
|
|
@@ -262,10 +262,10 @@ export default {
|
|
|
262
262
|
.description-content {
|
|
263
263
|
display: -webkit-box;
|
|
264
264
|
-webkit-box-orient: vertical;
|
|
265
|
-
-webkit-line-clamp: 3;
|
|
266
|
-
line-clamp: 3;
|
|
267
|
-
overflow: hidden;
|
|
268
|
-
text-overflow: ellipsis;
|
|
265
|
+
// -webkit-line-clamp: 3;
|
|
266
|
+
// line-clamp: 3;
|
|
267
|
+
// overflow: hidden;
|
|
268
|
+
// text-overflow: ellipsis;
|
|
269
269
|
color: var(--text-muted);
|
|
270
270
|
}
|
|
271
271
|
|
package/pages/home.vue
CHANGED
|
@@ -485,32 +485,24 @@ export default defineComponent({
|
|
|
485
485
|
>
|
|
486
486
|
|
|
487
487
|
<!-- 页签标题组件,不显示子页面标题和面包屑 -->
|
|
488
|
-
<TabTitle
|
|
489
|
-
v-if="topLevelPermissionsVis"
|
|
490
|
-
:show-child="false"
|
|
491
|
-
:breadcrumb="false"
|
|
492
|
-
>
|
|
493
|
-
|
|
494
|
-
<!-- 页面标题:{vendor} - 首页 -->
|
|
495
|
-
{{ `${vendor} - ${t('landing.homepage')}` }}
|
|
496
|
-
</TabTitle>
|
|
497
488
|
|
|
498
489
|
<!-- 首页欢迎横幅 -->
|
|
499
|
-
<BannerGraphic
|
|
490
|
+
<!-- <BannerGraphic
|
|
500
491
|
v-if="topLevelPermissionsVis"
|
|
501
492
|
:small="true"
|
|
502
493
|
:title="t('landing.welcomeToRancher', {vendor})"
|
|
503
494
|
:pref="HIDE_HOME_PAGE_CARDS"
|
|
504
495
|
pref-key="welcomeBanner"
|
|
505
496
|
data-testid="home-banner-graphic"
|
|
506
|
-
/>
|
|
497
|
+
/> -->
|
|
507
498
|
<IndentedPanel class="mt-20 mb-20">
|
|
508
499
|
|
|
509
500
|
<!-- 主面板布局 -->
|
|
510
501
|
<div class="row home-panels">
|
|
511
502
|
<div class="col main-panel">
|
|
512
503
|
<h2 class="mb-20">
|
|
513
|
-
{{ t('landing.clusters.title') }}
|
|
504
|
+
<!-- {{ t('landing.clusters.title') }} -->
|
|
505
|
+
首页
|
|
514
506
|
</h2>
|
|
515
507
|
|
|
516
508
|
<!-- 集群列表面板 -->
|
|
@@ -548,7 +540,7 @@ export default defineComponent({
|
|
|
548
540
|
v-if="canCreateCluster || !!provClusterSchema"
|
|
549
541
|
#header-right
|
|
550
542
|
>
|
|
551
|
-
<div
|
|
543
|
+
<div class="table-heading">
|
|
552
544
|
<router-link
|
|
553
545
|
v-if="!!provClusterSchema"
|
|
554
546
|
:to="manageLocation"
|
|
@@ -669,6 +661,14 @@ export default defineComponent({
|
|
|
669
661
|
</button>
|
|
670
662
|
</template>
|
|
671
663
|
</PaginatedResourceTable>
|
|
664
|
+
<div v-else class="home-prompt">
|
|
665
|
+
<div style="text-align: center;position: relative;">
|
|
666
|
+
<div class="left-border"></div>
|
|
667
|
+
<!-- <div class="right-border"></div> -->
|
|
668
|
+
<div class="home-prompt-title">欢 迎 登 录</div>
|
|
669
|
+
<div class="home-prompt-subtitle">企业级容器编排与管理解决方案,提供强大的Kubernetes集群管理、应用部署和服务治理能力。</div>
|
|
670
|
+
</div>
|
|
671
|
+
</div>
|
|
672
672
|
</div>
|
|
673
673
|
|
|
674
674
|
<!-- 单集群模式 -->
|
|
@@ -688,6 +688,48 @@ export default defineComponent({
|
|
|
688
688
|
</template>
|
|
689
689
|
|
|
690
690
|
<style lang='scss' scoped>
|
|
691
|
+
.home-prompt {
|
|
692
|
+
width: 100%;
|
|
693
|
+
height: 500px;
|
|
694
|
+
display: flex;
|
|
695
|
+
align-items: center;
|
|
696
|
+
justify-content: center;
|
|
697
|
+
.left-border,
|
|
698
|
+
.right-border {
|
|
699
|
+
position: absolute;
|
|
700
|
+
height: 1px;
|
|
701
|
+
width: 120px;
|
|
702
|
+
background: linear-gradient(90deg, transparent, #00a8ff, transparent);
|
|
703
|
+
bottom: 0px;
|
|
704
|
+
}
|
|
705
|
+
.left-border {
|
|
706
|
+
left: calc(50% - 60px);
|
|
707
|
+
}
|
|
708
|
+
.right-border {
|
|
709
|
+
right: 0;
|
|
710
|
+
}
|
|
711
|
+
.home-prompt-title {
|
|
712
|
+
font-size: 32px;
|
|
713
|
+
color: #1a1a1a;
|
|
714
|
+
font-weight: 700;
|
|
715
|
+
letter-spacing: -0.5px;
|
|
716
|
+
margin-bottom: 15px;
|
|
717
|
+
background: linear-gradient(135deg, #00a8ff, #0050b3);
|
|
718
|
+
-webkit-background-clip: text;
|
|
719
|
+
-webkit-text-fill-color: transparent;
|
|
720
|
+
background-clip: text;
|
|
721
|
+
display: inline-block;
|
|
722
|
+
}
|
|
723
|
+
|
|
724
|
+
.home-prompt-subtitle {
|
|
725
|
+
font-size: 18px;
|
|
726
|
+
color: #666666;
|
|
727
|
+
margin-bottom: 20px;
|
|
728
|
+
max-width: 800px;
|
|
729
|
+
margin-left: auto;
|
|
730
|
+
margin-right: auto;
|
|
731
|
+
}
|
|
732
|
+
}
|
|
691
733
|
.banner-link:focus-visible {
|
|
692
734
|
@include focus-outline;
|
|
693
735
|
}
|
|
@@ -78,7 +78,16 @@ export default defineComponent({
|
|
|
78
78
|
* Return message text as label.
|
|
79
79
|
*/
|
|
80
80
|
messageLabel(): string | void {
|
|
81
|
-
|
|
81
|
+
|
|
82
|
+
let labelStr = this.label
|
|
83
|
+
|
|
84
|
+
if (labelStr === 'waiting for api to be available') {
|
|
85
|
+
labelStr = '等待api可用'
|
|
86
|
+
} else if (labelStr === 'Cluster agent is not connected') {
|
|
87
|
+
labelStr = '集群agent未连接'
|
|
88
|
+
}
|
|
89
|
+
|
|
90
|
+
return !(typeof labelStr === 'string') ? stringify(labelStr) : undefined;
|
|
82
91
|
},
|
|
83
92
|
},
|
|
84
93
|
methods: { nlToBr }
|
|
@@ -164,6 +173,7 @@ $icon-size: 24px;
|
|
|
164
173
|
margin: 0px 0px 20px 0px;
|
|
165
174
|
position: relative;
|
|
166
175
|
width: 100%;
|
|
176
|
+
min-height: 32px;
|
|
167
177
|
color: var(--body-text);
|
|
168
178
|
|
|
169
179
|
&__icon {
|
|
@@ -201,13 +211,15 @@ $icon-size: 24px;
|
|
|
201
211
|
}
|
|
202
212
|
|
|
203
213
|
&__content {
|
|
204
|
-
padding:
|
|
214
|
+
padding: 2px 10px;
|
|
205
215
|
transition: all 0.2s ease;
|
|
206
216
|
line-height: 12px;
|
|
207
217
|
width: 100%;
|
|
208
218
|
border-left: solid $left-border-size transparent;
|
|
209
219
|
display: flex;
|
|
210
220
|
gap: 3px;
|
|
221
|
+
min-height: 32px;
|
|
222
|
+
align-items: center;
|
|
211
223
|
word-wrap:break-word;
|
|
212
224
|
word-break:break-all;
|
|
213
225
|
|
|
@@ -102,6 +102,11 @@ export default defineComponent({
|
|
|
102
102
|
row: {
|
|
103
103
|
type: Boolean,
|
|
104
104
|
default: false
|
|
105
|
+
},
|
|
106
|
+
|
|
107
|
+
flexDirection: {
|
|
108
|
+
type: String,
|
|
109
|
+
default: 'row'
|
|
105
110
|
}
|
|
106
111
|
},
|
|
107
112
|
|
|
@@ -274,7 +279,7 @@ export default defineComponent({
|
|
|
274
279
|
:aria-describedby="radioGroupAriaDescribedBy"
|
|
275
280
|
:aria-activedescendant="ariaActiveDescendant"
|
|
276
281
|
class="radio-group"
|
|
277
|
-
:class="{'row':row}"
|
|
282
|
+
:class="{'row':row, 'flexDirection': flexDirection === 'column'}"
|
|
278
283
|
:tabindex="isDisabled ? -1 : 0"
|
|
279
284
|
:aria-disabled="isDisabled"
|
|
280
285
|
@keydown.down.prevent.stop="clickNext(1)"
|
|
@@ -312,6 +317,9 @@ export default defineComponent({
|
|
|
312
317
|
</template>
|
|
313
318
|
|
|
314
319
|
<style lang='scss'>
|
|
320
|
+
.flexDirection {
|
|
321
|
+
flex-direction: column;
|
|
322
|
+
}
|
|
315
323
|
.radio-group {
|
|
316
324
|
&:focus, &:focus-visible {
|
|
317
325
|
border: none;
|
|
@@ -123,8 +123,8 @@ export default defineComponent({
|
|
|
123
123
|
&.null {
|
|
124
124
|
|
|
125
125
|
.status-icon {
|
|
126
|
-
top:
|
|
127
|
-
right:
|
|
126
|
+
top: 8px !important;
|
|
127
|
+
right: 25px !important;
|
|
128
128
|
}
|
|
129
129
|
}
|
|
130
130
|
|
|
@@ -146,6 +146,35 @@ export default defineComponent({
|
|
|
146
146
|
}
|
|
147
147
|
}
|
|
148
148
|
|
|
149
|
+
.labeled-select{
|
|
150
|
+
.labeled-tooltip{
|
|
151
|
+
&.null {
|
|
152
|
+
.status-icon {
|
|
153
|
+
top: 10px !important;
|
|
154
|
+
right: 25px !important;
|
|
155
|
+
}
|
|
156
|
+
}
|
|
157
|
+
|
|
158
|
+
&.error {
|
|
159
|
+
|
|
160
|
+
.status-icon {
|
|
161
|
+
top: 9px !important;
|
|
162
|
+
right: 20px;
|
|
163
|
+
}
|
|
164
|
+
}
|
|
165
|
+
}
|
|
166
|
+
}
|
|
167
|
+
.labeled-input{
|
|
168
|
+
.labeled-tooltip{
|
|
169
|
+
&.null {
|
|
170
|
+
.status-icon {
|
|
171
|
+
top: 10px !important;
|
|
172
|
+
right: 10px !important;
|
|
173
|
+
}
|
|
174
|
+
}
|
|
175
|
+
}
|
|
176
|
+
}
|
|
177
|
+
|
|
149
178
|
// Ensure code blocks inside tootips don't look awful
|
|
150
179
|
.v-popper__popper.v-popper--theme-tooltip {
|
|
151
180
|
.v-popper__inner {
|