dashboard-shell-shell 3.0.5-test.6 → 3.0.5-test.9
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/harvester/favicon.png +0 -0
- package/assets/brand/suse/favicon.png +0 -0
- package/assets/icons/demo.css +539 -0
- package/assets/icons/demo.css:Zone.Identifier +0 -0
- package/assets/icons/demo_index.html +1131 -0
- package/assets/icons/demo_index.html:Zone.Identifier +0 -0
- package/assets/icons/iconfont.css +216 -0
- package/assets/icons/iconfont.css:Zone.Identifier +0 -0
- package/assets/icons/iconfont.js +1 -0
- package/assets/icons/iconfont.js:Zone.Identifier +0 -0
- package/assets/icons/iconfont.json +324 -0
- package/assets/icons/iconfont.json:Zone.Identifier +0 -0
- package/assets/icons/iconfont.ttf +0 -0
- package/assets/icons/iconfont.ttf:Zone.Identifier +0 -0
- package/assets/icons/iconfont.woff +0 -0
- package/assets/icons/iconfont.woff2 +0 -0
- package/assets/icons/iconfont.woff2:Zone.Identifier +0 -0
- package/assets/icons/iconfont.woff:Zone.Identifier +0 -0
- package/assets/images/API.svg +3 -0
- package/assets/images/action.svg +6 -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/half-logo.svg +2 -23
- package/assets/images/pl/harvester.png +0 -0
- package/assets/images/pl/logo.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 +4 -0
- package/assets/styles/base/_basic.scss +2 -2
- package/assets/styles/base/_mixins.scss +1 -1
- package/assets/styles/base/_typography.scss +2 -1
- package/assets/styles/base/_variables.scss +14 -7
- package/assets/styles/global/_button.scss +43 -25
- package/assets/styles/global/_columns.scss +3 -1
- package/assets/styles/global/_form.scss +45 -13
- package/assets/styles/global/_labeled-input.scss +54 -26
- package/assets/styles/global/_layout.scss +8 -3
- package/assets/styles/global/_select.scss +25 -17
- package/assets/styles/global/_table.scss +7 -1
- package/assets/styles/global/_tooltip.scss +56 -8
- package/assets/styles/themes/_dark.scss +3 -0
- package/assets/styles/themes/_light.scss +66 -43
- package/assets/styles/vendor/vue-select.scss +22 -9
- package/assets/translations/en-us.yaml +28 -4
- package/assets/translations/zh-hans.yaml +452 -189
- package/components/ActionDropdown.vue +2 -1
- package/components/ActionMenu.vue +2 -2
- package/components/ActionMenuShell.vue +2 -0
- package/components/AppModal.vue +46 -5
- package/components/BrandImage.vue +1 -0
- package/components/ButtonDropdown.vue +26 -4
- package/components/ButtonMultiAction.vue +1 -0
- package/components/ClusterIconMenu.vue +1 -1
- package/components/CodeMirror.vue +20 -6
- package/components/ConsumptionGauge.vue +24 -5
- package/components/CopyToClipboard.vue +15 -0
- package/components/CruResource.vue +9 -8
- package/components/CruResourceFooter.vue +2 -2
- package/components/DashboardOptions.vue +29 -17
- package/components/DotState.vue +84 -0
- package/components/Drawer/Chrome.vue +2 -2
- package/components/Drawer/ResourceDetailDrawer/ConfigTab.vue +22 -22
- package/components/Drawer/ResourceDetailDrawer/YamlTab.vue +1 -1
- package/components/Drawer/ResourceDetailDrawer/index.vue +2 -1
- package/components/ExplorerMembers.vue +18 -3
- package/components/ExplorerProjectsNamespaces.vue +19 -5
- package/components/GlobalRoleBindings.vue +112 -48
- package/components/GrafanaDashboard.vue +4 -4
- package/components/GrowlManager.vue +3 -1
- package/components/HardwareResourceGauge.vue +39 -3
- package/components/IndentedPanel.vue +4 -10
- package/components/InfoBox.vue +3 -3
- package/components/InputOrDisplay.vue +28 -2
- package/components/LabelValue.vue +20 -1
- package/components/ModalWithCard.vue +12 -3
- package/components/PodSecurityAdmission.vue +1 -1
- package/components/PromptModal.vue +1 -1
- package/components/PromptRemove.vue +30 -11
- package/components/Resource/Detail/Metadata/IdentifyingInformation/index.vue +1 -3
- package/components/Resource/Detail/Metadata/KeyValue.vue +8 -4
- package/components/Resource/Detail/Metadata/index.vue +3 -1
- package/components/Resource/Detail/TitleBar/Title.vue +4 -3
- package/components/Resource/Detail/TitleBar/Top.vue +2 -0
- package/components/Resource/Detail/TitleBar/index.vue +109 -24
- package/components/ResourceDetail/Masthead/legacy.vue +181 -38
- package/components/ResourceDetail/legacy.vue +32 -14
- package/components/ResourceList/Masthead.vue +226 -54
- package/components/ResourceList/ResourceLoadingIndicator.vue +5 -2
- package/components/ResourceTable.vue +24 -2
- package/components/SideNav.vue +74 -20
- package/components/SortableTable/THead.vue +33 -3
- package/components/SortableTable/index.vue +1016 -463
- package/components/SortableTable/paging.js +26 -16
- package/components/SortableTable/selection.js +2 -2
- package/components/Tabbed/Tab.vue +3 -3
- package/components/Tabbed/index.vue +47 -29
- package/components/YamlEditor.vue +0 -1
- package/components/auth/Principal.vue +37 -13
- package/components/auth/RoleDetailEdit.vue +58 -7
- package/components/auth/SelectPrincipal.vue +1 -0
- package/components/breadcrumb/index.vue +316 -0
- package/components/form/ArrayList.vue +41 -33
- package/components/form/ArrayListGrouped.vue +10 -2
- package/components/form/ArrayListSelect.vue +1 -1
- package/components/form/BannerSettings.vue +64 -59
- package/components/form/ChangePassword.vue +4 -4
- package/components/form/ColorInput.vue +32 -8
- package/components/form/Footer.vue +11 -8
- package/components/form/InputWithSelect.vue +8 -5
- package/components/form/KeyValue.vue +47 -7
- package/components/form/LabeledSelect.vue +214 -242
- package/components/form/Labels.vue +3 -3
- package/components/form/MatchExpressions.vue +24 -7
- package/components/form/Members/ClusterPermissionsEditor.vue +1 -2
- package/components/form/Members/MembershipEditor.vue +1 -1
- package/components/form/NameNsDescription.vue +59 -20
- package/components/form/Password.vue +16 -7
- package/components/form/PodAffinity.vue +4 -5
- package/components/form/ResourceQuota/Namespace.vue +4 -4
- package/components/form/ResourceQuota/NamespaceRow.vue +18 -17
- package/components/form/ResourceQuota/Project.vue +4 -4
- package/components/form/ResourceQuota/ProjectRow.vue +3 -6
- package/components/form/Select.vue +5 -2
- package/components/form/SimpleSecretSelector.vue +29 -9
- package/components/form/Taints.vue +2 -1
- package/components/form/UnitInput.vue +8 -3
- package/components/form/WorkloadPorts.vue +143 -123
- package/components/formatter/BadgeStateFormatter.vue +8 -5
- package/components/formatter/LiveDate.vue +3 -3
- package/components/nav/Favorite.vue +5 -1
- package/components/nav/Group.vue +132 -99
- package/components/nav/Header.vue +124 -27
- package/components/nav/HeaderPageActionMenu.vue +1 -0
- package/components/nav/NamespaceFilter.vue +20 -17
- package/components/nav/TopLevelMenu.vue +182 -119
- package/components/nav/Type.vue +63 -41
- package/composables/useClickOutside.ts +1 -1
- package/config/private-label.js +15 -11
- package/config/product/auth.js +17 -7
- package/config/product/settings.js +19 -9
- package/config/settings.ts +28 -0
- package/config/table-headers.js +3 -2
- package/dialog/ForceMachineRemoveDialog.vue +2 -2
- package/dialog/ScalePoolDownDialog.vue +2 -2
- package/edit/management.cattle.io.user.vue +17 -4
- package/edit/monitoring.coreos.com.alertmanagerconfig/auth.vue +19 -19
- package/edit/monitoring.coreos.com.alertmanagerconfig/receiverConfig.vue +31 -31
- package/edit/monitoring.coreos.com.alertmanagerconfig/routeConfig.vue +36 -12
- package/edit/monitoring.coreos.com.alertmanagerconfig/types/email.vue +6 -6
- package/edit/monitoring.coreos.com.alertmanagerconfig/types/opsgenie.vue +10 -10
- package/edit/monitoring.coreos.com.alertmanagerconfig/types/pagerduty.vue +4 -4
- package/edit/monitoring.coreos.com.alertmanagerconfig/types/slack.vue +4 -4
- package/edit/monitoring.coreos.com.alertmanagerconfig/types/webhook.vue +1 -1
- package/edit/monitoring.coreos.com.receiver/types/email.vue +6 -6
- package/edit/monitoring.coreos.com.receiver/types/opsgenie.vue +10 -10
- package/edit/monitoring.coreos.com.receiver/types/pagerduty.vue +5 -5
- package/edit/monitoring.coreos.com.receiver/types/slack.vue +4 -4
- package/edit/namespace.vue +1 -2
- package/edit/token.vue +31 -12
- package/edit/workload/index.vue +4 -4
- package/list/management.cattle.io.setting.vue +22 -13
- package/list/management.cattle.io.user.vue +7 -3
- package/list/namespace.vue +3 -0
- package/list/provisioning.cattle.io.cluster.vue +6 -7
- package/mixins/brand.js +17 -0
- package/package.json +1 -1
- package/pages/account/pri.vue +229 -0
- package/pages/auth/login.vue +220 -52
- package/pages/auth/setup.vue +142 -19
- package/pages/c/_cluster/_product/namespaces.vue +5 -5
- package/pages/c/_cluster/auth/roles/index.vue +56 -5
- package/pages/c/_cluster/monitoring/monitor/index.vue +2 -2
- package/pages/c/_cluster/settings/banners.vue +174 -102
- package/pages/c/_cluster/settings/brand.vue +350 -302
- package/pages/c/_cluster/settings/performance.vue +61 -38
- package/pages/home.vue +70 -30
- package/pages/prefs.vue +27 -25
- package/pkg/tsconfig.json +9 -9
- package/pkg/vue.config.js +1 -1
- package/plugins/dashboard-store/resource-class.js +28 -27
- package/promptRemove/mixin/roleDeletionCheck.js +2 -2
- package/public/index.html +4 -4
- package/rancher-components/BadgeState/BadgeState.vue +38 -55
- package/rancher-components/Banner/Banner.vue +12 -8
- package/rancher-components/Card/Card.vue +7 -8
- package/rancher-components/Form/Checkbox/Checkbox.vue +4 -0
- package/rancher-components/Form/LabeledInput/LabeledInput.vue +42 -3
- package/rancher-components/Form/Radio/RadioButton.vue +35 -11
- package/rancher-components/Form/Radio/RadioGroup.vue +13 -5
- package/rancher-components/Form/TextArea/TextAreaAutoGrow.vue +3 -3
- package/rancher-components/Form/ToggleSwitch/ToggleSwitch.vue +1 -0
- package/rancher-components/LabeledTooltip/LabeledTooltip.vue +12 -4
- package/rancher-components/RcDropdown/RcDropdown.vue +35 -7
- package/rancher-components/RcDropdown/RcDropdownItem.vue +2 -2
- package/rancher-components/RcDropdown/RcDropdownMenu.vue +12 -6
- package/rancher-components/RcDropdown/types.ts +1 -0
- package/rancher-components/StringList/StringList.vue +1 -1
- package/scripts/publish-shell.sh +1 -1
- package/static/favicon.ico +0 -0
- package/static/favicon.png +0 -0
- package/static/loading-indicator.html +3 -3
- package/store/i18n.js +5 -2
- package/store/modal.ts +3 -3
- package/store/prefs.js +11 -4
- package/store/type-map.js +32 -2
- package/types/shell/index.d.ts +78 -97
- package/utils/error.js +89 -8
- package/utils/errorTranslate.json +1351 -0
- package/utils/router.js +21 -0
- package/utils/select.js +26 -3
- package/utils/string.js +8 -5
- package/utils/title.ts +1 -1
- package/vue.config.js +1 -1
|
@@ -52,7 +52,10 @@ export default {
|
|
|
52
52
|
helper.update(args);
|
|
53
53
|
}
|
|
54
54
|
|
|
55
|
+
const topLevelPermissions = sessionStorage.getItem('TOPLEVELPERMISSIONS') || ''
|
|
56
|
+
|
|
55
57
|
return {
|
|
58
|
+
topLevelPermissions,
|
|
56
59
|
shown: false,
|
|
57
60
|
displayVersion,
|
|
58
61
|
fullVersion,
|
|
@@ -471,12 +474,14 @@ export default {
|
|
|
471
474
|
|
|
472
475
|
<template>
|
|
473
476
|
<div>
|
|
474
|
-
<!--
|
|
477
|
+
<!-- ====================== 遮罩层(点击可关闭菜单) ====================== -->
|
|
475
478
|
<div
|
|
476
479
|
v-if="shown"
|
|
477
480
|
class="side-menu-glass"
|
|
478
481
|
@click="hide()"
|
|
479
482
|
/>
|
|
483
|
+
|
|
484
|
+
<!-- ====================== 菜单主容器(带淡入淡出过渡) ====================== -->
|
|
480
485
|
<transition name="fade">
|
|
481
486
|
<!-- Side menu -->
|
|
482
487
|
<div
|
|
@@ -487,8 +492,11 @@ export default {
|
|
|
487
492
|
role="navigation"
|
|
488
493
|
:aria-label="t('nav.ariaLabel.topLevelMenu')"
|
|
489
494
|
>
|
|
490
|
-
|
|
495
|
+
|
|
496
|
+
<!-- ====================== 菜单头部(Logo + 菜单按钮) ====================== -->
|
|
491
497
|
<div class="title">
|
|
498
|
+
|
|
499
|
+
<!-- 菜单按钮(汉堡图标) -->
|
|
492
500
|
<div
|
|
493
501
|
data-testid="top-level-menu"
|
|
494
502
|
:aria-label="t('nav.expandCollapseAppBar')"
|
|
@@ -499,6 +507,8 @@ export default {
|
|
|
499
507
|
@keyup.space="toggle()"
|
|
500
508
|
@click="toggle()"
|
|
501
509
|
>
|
|
510
|
+
|
|
511
|
+
<!-- 汉堡菜单SVG图标 -->
|
|
502
512
|
<svg
|
|
503
513
|
class="menu-icon"
|
|
504
514
|
xmlns="http://www.w3.org/2000/svg"
|
|
@@ -511,19 +521,22 @@ export default {
|
|
|
511
521
|
fill="none"
|
|
512
522
|
/><path d="M3 18h18v-2H3v2zm0-5h18v-2H3v2zm0-7v2h18V6H3z" /></svg>
|
|
513
523
|
</div>
|
|
514
|
-
|
|
524
|
+
|
|
525
|
+
<!-- 品牌Logo -->
|
|
526
|
+
<div v-if="topLevelPermissions && topLevelPermissions === 'superadmin'" class="side-menu-logo">
|
|
515
527
|
<BrandImage
|
|
516
528
|
data-testid="side-menu__brand-img"
|
|
517
529
|
:alt="t('nav.alt.mainMenuRancherLogo')"
|
|
518
|
-
file-name="
|
|
530
|
+
file-name="logo.png"
|
|
519
531
|
/>
|
|
520
532
|
</div>
|
|
521
533
|
</div>
|
|
522
534
|
|
|
523
|
-
<!--
|
|
535
|
+
<!-- ====================== 菜单内容区 ====================== -->
|
|
524
536
|
<div class="body">
|
|
525
|
-
<div>
|
|
526
|
-
|
|
537
|
+
<div v-if="topLevelPermissions && topLevelPermissions === 'superadmin'">
|
|
538
|
+
|
|
539
|
+
<!-- 首页按钮 -->
|
|
527
540
|
<div @click="hide()">
|
|
528
541
|
<router-link
|
|
529
542
|
class="option cluster selector home"
|
|
@@ -531,6 +544,8 @@ export default {
|
|
|
531
544
|
role="link"
|
|
532
545
|
:aria-label="t('nav.ariaLabel.homePage')"
|
|
533
546
|
>
|
|
547
|
+
|
|
548
|
+
<!-- 首页图标 -->
|
|
534
549
|
<svg
|
|
535
550
|
v-clean-tooltip="getTooltipConfig(t('nav.home'))"
|
|
536
551
|
class="top-menu-icon"
|
|
@@ -547,12 +562,14 @@ export default {
|
|
|
547
562
|
</div>
|
|
548
563
|
</router-link>
|
|
549
564
|
</div>
|
|
550
|
-
|
|
565
|
+
|
|
566
|
+
<!-- 集群搜索框 -->
|
|
551
567
|
<div
|
|
552
568
|
v-if="showClusterSearch"
|
|
553
569
|
class="clusters-search"
|
|
554
570
|
>
|
|
555
571
|
<div class="clusters-search-count">
|
|
572
|
+
<!-- 当前搜索到的集群数量 -->
|
|
556
573
|
<span>{{ clusterFilterCount }}</span>
|
|
557
574
|
{{ t('nav.search.clusters') }}
|
|
558
575
|
<i
|
|
@@ -571,10 +588,14 @@ export default {
|
|
|
571
588
|
:tabindex="!shown ? -1 : 0"
|
|
572
589
|
:aria-label="t('nav.search.ariaLabel')"
|
|
573
590
|
>
|
|
591
|
+
|
|
592
|
+
<!-- 搜索图标 -->
|
|
574
593
|
<i
|
|
575
594
|
class="magnifier icon icon-search"
|
|
576
595
|
:class="{ active: clusterFilter }"
|
|
577
596
|
/>
|
|
597
|
+
|
|
598
|
+
<!-- 清空按钮 -->
|
|
578
599
|
<i
|
|
579
600
|
v-if="clusterFilter"
|
|
580
601
|
class="icon icon-close"
|
|
@@ -584,9 +605,11 @@ export default {
|
|
|
584
605
|
</div>
|
|
585
606
|
</div>
|
|
586
607
|
|
|
587
|
-
<!-- Harvester
|
|
608
|
+
<!-- ====================== Harvester 相关功能区 ====================== -->
|
|
588
609
|
<template v-if="hciApps.length">
|
|
589
610
|
<div class="category" />
|
|
611
|
+
|
|
612
|
+
<!-- 跳转 Harvester Dashboard -->
|
|
590
613
|
<div>
|
|
591
614
|
<a
|
|
592
615
|
v-if="isRancherInHarvester"
|
|
@@ -602,6 +625,8 @@ export default {
|
|
|
602
625
|
</div>
|
|
603
626
|
</a>
|
|
604
627
|
</div>
|
|
628
|
+
|
|
629
|
+
<!-- Harvester 应用列表 -->
|
|
605
630
|
<div
|
|
606
631
|
v-for="(a, i) in appBar.hciApps"
|
|
607
632
|
:key="i"
|
|
@@ -624,14 +649,14 @@ export default {
|
|
|
624
649
|
</div>
|
|
625
650
|
</template>
|
|
626
651
|
|
|
627
|
-
<!--
|
|
628
|
-
<template v-if="!!allClustersCount">
|
|
652
|
+
<!-- ====================== 集群列表 ====================== -->
|
|
653
|
+
<template v-if="topLevelPermissions && topLevelPermissions === 'superadmin' && !!allClustersCount">
|
|
629
654
|
<div
|
|
630
655
|
ref="clusterList"
|
|
631
656
|
class="clusters"
|
|
632
657
|
:style="pinnedClustersHeight"
|
|
633
658
|
>
|
|
634
|
-
<!--
|
|
659
|
+
<!-- 已固定集群 -->
|
|
635
660
|
<div
|
|
636
661
|
v-if="showPinClusters && pinFiltered.length"
|
|
637
662
|
class="clustersPinned"
|
|
@@ -642,11 +667,13 @@ export default {
|
|
|
642
667
|
:data-testid="`pinned-ready-cluster-${index}`"
|
|
643
668
|
@click="hide()"
|
|
644
669
|
>
|
|
645
|
-
|
|
670
|
+
|
|
671
|
+
<!-- 可用集群按钮 -->
|
|
672
|
+
<span
|
|
646
673
|
v-if="c.ready"
|
|
647
674
|
v-shortkey.push="{windows: ['alt'], mac: ['option']}"
|
|
648
675
|
:data-testid="`pinned-menu-cluster-${ c.id }`"
|
|
649
|
-
class="cluster selector option"
|
|
676
|
+
class="clusterBtn cluster selector option"
|
|
650
677
|
:class="{'active-menu-link': c.isMenuActive }"
|
|
651
678
|
:to="c.clusterRoute"
|
|
652
679
|
role="button"
|
|
@@ -676,7 +703,9 @@ export default {
|
|
|
676
703
|
:cluster="c"
|
|
677
704
|
:tab-order="shown ? 0 : -1"
|
|
678
705
|
/>
|
|
679
|
-
</
|
|
706
|
+
</span>
|
|
707
|
+
|
|
708
|
+
<!-- 不可用集群 -->
|
|
680
709
|
<span
|
|
681
710
|
v-else
|
|
682
711
|
class="option cluster selector disabled"
|
|
@@ -705,6 +734,8 @@ export default {
|
|
|
705
734
|
/>
|
|
706
735
|
</span>
|
|
707
736
|
</div>
|
|
737
|
+
|
|
738
|
+
<!-- 分割线 -->
|
|
708
739
|
<div
|
|
709
740
|
v-if="clustersFiltered.length > 0"
|
|
710
741
|
class="category-title"
|
|
@@ -713,7 +744,7 @@ export default {
|
|
|
713
744
|
</div>
|
|
714
745
|
</div>
|
|
715
746
|
|
|
716
|
-
<!--
|
|
747
|
+
<!-- 搜索结果集群列表 -->
|
|
717
748
|
<div class="clustersList">
|
|
718
749
|
<div
|
|
719
750
|
v-for="(c, index) in appBar.clustersFiltered"
|
|
@@ -721,11 +752,13 @@ export default {
|
|
|
721
752
|
:data-testid="`top-level-menu-cluster-${index}`"
|
|
722
753
|
@click="hide()"
|
|
723
754
|
>
|
|
724
|
-
|
|
755
|
+
|
|
756
|
+
<!-- 可用集群 -->
|
|
757
|
+
<span
|
|
725
758
|
v-if="c.ready"
|
|
726
759
|
v-shortkey.push="{windows: ['alt'], mac: ['option']}"
|
|
727
760
|
:data-testid="`menu-cluster-${ c.id }`"
|
|
728
|
-
class="cluster selector option"
|
|
761
|
+
class="cluster selector option clusterBtn"
|
|
729
762
|
:class="{'active-menu-link': c.isMenuActive }"
|
|
730
763
|
:to="c.clusterRoute"
|
|
731
764
|
role="button"
|
|
@@ -756,7 +789,9 @@ export default {
|
|
|
756
789
|
:tab-order="shown ? 0 : -1"
|
|
757
790
|
:cluster="c"
|
|
758
791
|
/>
|
|
759
|
-
</
|
|
792
|
+
</span>
|
|
793
|
+
|
|
794
|
+
<!-- 不可用集群 -->
|
|
760
795
|
<span
|
|
761
796
|
v-else
|
|
762
797
|
class="option cluster selector disabled"
|
|
@@ -788,7 +823,7 @@ export default {
|
|
|
788
823
|
</div>
|
|
789
824
|
</div>
|
|
790
825
|
|
|
791
|
-
<!--
|
|
826
|
+
<!-- 无匹配集群提示 -->
|
|
792
827
|
<div
|
|
793
828
|
v-if="clustersFiltered.length === 0 && searchActive"
|
|
794
829
|
data-testid="top-level-menu-no-results"
|
|
@@ -798,7 +833,7 @@ export default {
|
|
|
798
833
|
</div>
|
|
799
834
|
</div>
|
|
800
835
|
|
|
801
|
-
<!--
|
|
836
|
+
<!-- 查看所有集群按钮 -->
|
|
802
837
|
<router-link
|
|
803
838
|
v-if="allClustersCount > maxClustersToShow"
|
|
804
839
|
class="clusters-all"
|
|
@@ -817,104 +852,129 @@ export default {
|
|
|
817
852
|
</router-link>
|
|
818
853
|
</template>
|
|
819
854
|
|
|
820
|
-
<!--
|
|
821
|
-
<div class="category">
|
|
855
|
+
<!-- ====================== 多集群应用区 ====================== -->
|
|
856
|
+
<div :style="!(topLevelPermissions && topLevelPermissions === 'superadmin') ? { placeContent: 'flex-start', display: 'flex', flexDirection: 'column' } : {}" class="category">
|
|
857
|
+
<!-- 多集群应用 -->
|
|
822
858
|
<template v-if="multiClusterApps.length">
|
|
823
|
-
<
|
|
824
|
-
|
|
825
|
-
|
|
826
|
-
<hr role="none">
|
|
827
|
-
<span>
|
|
828
|
-
{{ t('nav.categories.multiCluster') }}
|
|
829
|
-
</span>
|
|
830
|
-
</div>
|
|
831
|
-
<div
|
|
832
|
-
v-for="(a, i) in appBar.multiClusterApps"
|
|
833
|
-
:key="i"
|
|
834
|
-
@click="hide()"
|
|
835
|
-
>
|
|
836
|
-
<router-link
|
|
837
|
-
class="option"
|
|
838
|
-
:class="{'active-menu-link': a.isMenuActive }"
|
|
839
|
-
:to="a.to"
|
|
840
|
-
role="link"
|
|
841
|
-
:aria-label="`${t('nav.ariaLabel.multiClusterApps')} ${ a.label }`"
|
|
842
|
-
>
|
|
843
|
-
<IconOrSvg
|
|
844
|
-
v-clean-tooltip="getTooltipConfig(a.label)"
|
|
845
|
-
class="app-icon"
|
|
846
|
-
:icon="a.icon"
|
|
847
|
-
:src="a.svg"
|
|
848
|
-
/>
|
|
849
|
-
<span class="option-link">{{ a.label }}</span>
|
|
850
|
-
</router-link>
|
|
851
|
-
</div>
|
|
852
|
-
</template>
|
|
853
|
-
|
|
854
|
-
<!-- Configuration apps menu -->
|
|
855
|
-
<template v-if="configurationApps.length">
|
|
856
|
-
<div
|
|
857
|
-
class="category-title"
|
|
858
|
-
>
|
|
859
|
-
<hr role="none">
|
|
860
|
-
<span>
|
|
861
|
-
{{ t('nav.categories.configuration') }}
|
|
862
|
-
</span>
|
|
863
|
-
</div>
|
|
864
|
-
<div
|
|
865
|
-
v-for="(a, i) in appBar.configurationApps"
|
|
866
|
-
:key="i"
|
|
867
|
-
@click="hide()"
|
|
868
|
-
>
|
|
869
|
-
<router-link
|
|
870
|
-
class="option"
|
|
871
|
-
:class="{'active-menu-link': a.isMenuActive }"
|
|
872
|
-
:to="a.to"
|
|
873
|
-
role="link"
|
|
874
|
-
:aria-label="`${t('nav.ariaLabel.configurationApps')} ${ a.label }`"
|
|
859
|
+
<template v-if="topLevelPermissions && topLevelPermissions === 'superadmin'">
|
|
860
|
+
<div
|
|
861
|
+
class="category-title"
|
|
875
862
|
>
|
|
876
|
-
<
|
|
877
|
-
|
|
878
|
-
|
|
879
|
-
|
|
880
|
-
|
|
881
|
-
|
|
882
|
-
<div
|
|
883
|
-
|
|
884
|
-
|
|
863
|
+
<hr role="none">
|
|
864
|
+
<span>
|
|
865
|
+
{{ t('nav.categories.multiCluster') }}
|
|
866
|
+
</span>
|
|
867
|
+
</div>
|
|
868
|
+
<template v-for="(a, i) in appBar.multiClusterApps" :key="i">
|
|
869
|
+
<div
|
|
870
|
+
v-if="a.value === 'harvesterManager'"
|
|
871
|
+
@click="hide()"
|
|
872
|
+
>
|
|
873
|
+
<router-link
|
|
874
|
+
class="option"
|
|
875
|
+
:class="{'active-menu-link': a.isMenuActive }"
|
|
876
|
+
:to="a.to"
|
|
877
|
+
role="link"
|
|
878
|
+
:aria-label="`${t('nav.ariaLabel.multiClusterApps')} ${ a.label }`"
|
|
879
|
+
>
|
|
880
|
+
<IconOrSvg
|
|
881
|
+
v-clean-tooltip="getTooltipConfig(a.label)"
|
|
882
|
+
class="app-icon"
|
|
883
|
+
:icon="a.icon"
|
|
884
|
+
:src="a.svg"
|
|
885
|
+
/>
|
|
886
|
+
<span class="option-link">{{ a.label }}</span>
|
|
887
|
+
</router-link>
|
|
888
|
+
</div>
|
|
889
|
+
</template>
|
|
890
|
+
</template>
|
|
891
|
+
<template v-else>
|
|
892
|
+
<template v-for="(a, i) in appBar.multiClusterApps" :key="i">
|
|
893
|
+
<div
|
|
894
|
+
v-if="a.value === 'harvesterManager'"
|
|
895
|
+
@click="hide()"
|
|
896
|
+
>
|
|
897
|
+
<router-link
|
|
898
|
+
class="option"
|
|
899
|
+
:class="{'active-menu-link': a.isMenuActive }"
|
|
900
|
+
:to="a.to"
|
|
901
|
+
role="link"
|
|
902
|
+
:aria-label="`${t('nav.ariaLabel.multiClusterApps')} ${ a.label }`"
|
|
903
|
+
>
|
|
904
|
+
<IconOrSvg
|
|
905
|
+
v-clean-tooltip="getTooltipConfig(a.label)"
|
|
906
|
+
class="app-icon"
|
|
907
|
+
:icon="a.icon"
|
|
908
|
+
:src="a.svg"
|
|
909
|
+
/>
|
|
910
|
+
<span class="option-link">{{ a.label }}</span>
|
|
911
|
+
</router-link>
|
|
912
|
+
</div>
|
|
913
|
+
</template>
|
|
914
|
+
</template>
|
|
885
915
|
</template>
|
|
886
|
-
</div>
|
|
887
|
-
</div>
|
|
888
916
|
|
|
889
|
-
|
|
890
|
-
|
|
891
|
-
|
|
892
|
-
|
|
893
|
-
|
|
894
|
-
|
|
895
|
-
|
|
896
|
-
|
|
897
|
-
|
|
898
|
-
|
|
899
|
-
|
|
900
|
-
|
|
901
|
-
|
|
902
|
-
|
|
903
|
-
|
|
904
|
-
|
|
905
|
-
|
|
906
|
-
|
|
907
|
-
|
|
908
|
-
|
|
909
|
-
|
|
910
|
-
|
|
911
|
-
|
|
912
|
-
|
|
913
|
-
|
|
914
|
-
|
|
915
|
-
|
|
916
|
-
|
|
917
|
-
|
|
917
|
+
<!-- 配置类应用 -->
|
|
918
|
+
<div>
|
|
919
|
+
<template v-if="configurationApps.length">
|
|
920
|
+
<template v-if="topLevelPermissions && topLevelPermissions === 'superadmin'">
|
|
921
|
+
<div
|
|
922
|
+
class="category-title"
|
|
923
|
+
>
|
|
924
|
+
<hr role="none">
|
|
925
|
+
<span>
|
|
926
|
+
{{ t('nav.categories.configuration') }}
|
|
927
|
+
</span>
|
|
928
|
+
</div>
|
|
929
|
+
<div
|
|
930
|
+
v-for="(a, i) in appBar.configurationApps"
|
|
931
|
+
:key="i"
|
|
932
|
+
@click="hide()"
|
|
933
|
+
>
|
|
934
|
+
<router-link
|
|
935
|
+
class="option"
|
|
936
|
+
:class="{'active-menu-link': a.isMenuActive }"
|
|
937
|
+
:to="a.to"
|
|
938
|
+
role="link"
|
|
939
|
+
:aria-label="`${t('nav.ariaLabel.configurationApps')} ${ a.label }`"
|
|
940
|
+
>
|
|
941
|
+
<IconOrSvg
|
|
942
|
+
v-clean-tooltip="getTooltipConfig(a.label)"
|
|
943
|
+
class="app-icon"
|
|
944
|
+
:icon="a.icon"
|
|
945
|
+
:src="a.svg"
|
|
946
|
+
/>
|
|
947
|
+
<div>{{ a.label }}</div>
|
|
948
|
+
</router-link>
|
|
949
|
+
</div>
|
|
950
|
+
</template>
|
|
951
|
+
<template v-else>
|
|
952
|
+
<template v-for="(a, i) in appBar.configurationApps" :key="i">
|
|
953
|
+
<div
|
|
954
|
+
v-if="a.value === 'settings' || a.value === 'auth'"
|
|
955
|
+
@click="hide()"
|
|
956
|
+
>
|
|
957
|
+
<router-link
|
|
958
|
+
class="option"
|
|
959
|
+
:class="{'active-menu-link': a.isMenuActive }"
|
|
960
|
+
:to="a.to"
|
|
961
|
+
role="link"
|
|
962
|
+
:aria-label="`${t('nav.ariaLabel.configurationApps')} ${ a.label }`"
|
|
963
|
+
>
|
|
964
|
+
<IconOrSvg
|
|
965
|
+
v-clean-tooltip="getTooltipConfig(a.label)"
|
|
966
|
+
class="app-icon"
|
|
967
|
+
:icon="a.icon"
|
|
968
|
+
:src="a.svg"
|
|
969
|
+
/>
|
|
970
|
+
<div>{{ a.label }}</div>
|
|
971
|
+
</router-link>
|
|
972
|
+
</div>
|
|
973
|
+
</template>
|
|
974
|
+
</template>
|
|
975
|
+
<div style="height: 40px;"></div>
|
|
976
|
+
</template>
|
|
977
|
+
</div>
|
|
918
978
|
</div>
|
|
919
979
|
</div>
|
|
920
980
|
</div>
|
|
@@ -973,6 +1033,10 @@ export default {
|
|
|
973
1033
|
$option-padding-left: 14px;
|
|
974
1034
|
$option-height: $icon-size + $option-padding + $option-padding;
|
|
975
1035
|
|
|
1036
|
+
.clusterBtn {
|
|
1037
|
+
background-color: var(--nav-icon-badge-bg);
|
|
1038
|
+
}
|
|
1039
|
+
|
|
976
1040
|
.side-menu {
|
|
977
1041
|
.menu {
|
|
978
1042
|
position: absolute;
|
|
@@ -1069,7 +1133,6 @@ export default {
|
|
|
1069
1133
|
flex: 1;
|
|
1070
1134
|
display: flex;
|
|
1071
1135
|
flex-direction: column;
|
|
1072
|
-
margin: 10px 0;
|
|
1073
1136
|
width: 300px;
|
|
1074
1137
|
overflow: auto;
|
|
1075
1138
|
|
|
@@ -1077,7 +1140,7 @@ export default {
|
|
|
1077
1140
|
align-items: center;
|
|
1078
1141
|
cursor: pointer;
|
|
1079
1142
|
display: flex;
|
|
1080
|
-
color: var(--
|
|
1143
|
+
color: var(--primary);
|
|
1081
1144
|
font-size: 14px;
|
|
1082
1145
|
height: $option-height;
|
|
1083
1146
|
white-space: nowrap;
|
|
@@ -1087,7 +1150,7 @@ export default {
|
|
|
1087
1150
|
border: none;
|
|
1088
1151
|
|
|
1089
1152
|
.cluster-badge-logo-text {
|
|
1090
|
-
color: var(--
|
|
1153
|
+
color: var(--primary);
|
|
1091
1154
|
font-weight: 500;
|
|
1092
1155
|
}
|
|
1093
1156
|
|
|
@@ -1159,7 +1222,7 @@ export default {
|
|
|
1159
1222
|
.rancher-provider-icon,
|
|
1160
1223
|
svg {
|
|
1161
1224
|
margin-right: 16px;
|
|
1162
|
-
fill: var(--
|
|
1225
|
+
fill: var(--primary);
|
|
1163
1226
|
}
|
|
1164
1227
|
|
|
1165
1228
|
.top-menu-icon {
|