dashboard-shell-shell 1.0.113 → 1.0.114
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/ActionDropdown.vue +1 -1
- package/components/ActionMenu.vue +2 -2
- package/components/ActionMenuShell.vue +0 -1
- package/components/AppModal.vue +6 -78
- package/components/AssignTo.vue +11 -25
- package/components/AsyncButton.vue +7 -24
- package/components/BannerGraphic.vue +0 -1
- package/components/ButtonDropdown.vue +4 -26
- package/components/ButtonGroup.vue +0 -4
- package/components/ButtonMultiAction.vue +0 -1
- package/components/CommunityLinks.vue +3 -3
- package/components/ConsumptionGauge.vue +5 -24
- package/components/CopyToClipboardText.vue +1 -2
- package/components/CruResource.vue +7 -12
- package/components/CruResourceFooter.vue +2 -2
- package/components/DashboardOptions.vue +15 -21
- package/components/DetailText.vue +0 -5
- package/components/DisableAuthProviderModal.vue +0 -1
- package/components/ExplorerMembers.vue +1 -1
- package/components/ExplorerProjectsNamespaces.vue +14 -56
- package/components/FixedBanner.vue +12 -19
- package/components/GlobalRoleBindings.vue +1 -5
- package/components/GrafanaDashboard.vue +4 -4
- package/components/GrowlManager.vue +1 -4
- package/components/HardwareResourceGauge.vue +3 -39
- package/components/InfoBox.vue +3 -3
- package/components/InputOrDisplay.vue +2 -28
- package/components/LabelValue.vue +1 -16
- package/components/LandingPagePreference.vue +3 -5
- package/components/LocaleSelector.vue +93 -39
- package/components/ModalWithCard.vue +0 -2
- package/components/MoveModal.vue +0 -1
- package/components/PromptChangePassword.vue +1 -1
- package/components/PromptModal.vue +2 -15
- package/components/PromptRemove.vue +8 -28
- package/components/PromptRestore.vue +0 -1
- package/components/ResourceCancelModal.vue +0 -1
- package/components/ResourceDetail/Masthead.vue +43 -188
- package/components/ResourceDetail/__tests__/Masthead.test.ts +1 -5
- package/components/ResourceDetail/index.vue +14 -49
- package/components/ResourceList/Masthead.vue +18 -80
- package/components/ResourceTable.vue +19 -60
- package/components/SideNav.vue +12 -32
- package/components/SortableTable/THead.vue +5 -34
- package/components/SortableTable/actions.js +1 -1
- package/components/SortableTable/index.vue +142 -649
- package/components/SortableTable/paging.js +28 -36
- package/components/SortableTable/selection.js +11 -0
- package/components/Tabbed/Tab.vue +3 -3
- package/components/Tabbed/index.vue +26 -44
- package/components/Wizard.vue +2 -2
- package/components/__tests__/AsyncButton.test.ts +2 -2
- package/components/__tests__/FixedBanner.test.ts +3 -3
- package/components/auth/Principal.vue +3 -10
- package/components/auth/__tests__/RoleDetailEdit.test.ts +2 -3
- package/components/form/ArrayList.vue +85 -123
- package/components/form/ArrayListGrouped.vue +2 -10
- package/components/form/Command.vue +15 -6
- package/components/form/EnvVars.vue +8 -16
- package/components/form/Footer.vue +5 -8
- package/components/form/HealthCheck.vue +3 -3
- package/components/form/HookOption.vue +16 -11
- package/components/form/KeyValue.vue +7 -16
- package/components/form/LabeledSelect.vue +76 -59
- package/components/form/LifecycleHooks.vue +3 -3
- package/components/form/MatchExpressions.vue +12 -35
- package/components/form/NameNsDescription.vue +115 -147
- package/components/form/Networking.vue +12 -20
- package/components/form/NodeAffinity.vue +23 -31
- package/components/form/NodeScheduling.vue +3 -13
- package/components/form/Password.vue +5 -11
- package/components/form/PodAffinity.vue +44 -43
- package/components/form/Probe.vue +66 -68
- package/components/form/ResourceQuota/Project.vue +1 -5
- package/components/form/ResourceSelector.vue +9 -7
- package/components/form/SSHKnownHosts/KnownHostsEditDialog.vue +3 -6
- package/components/form/SSHKnownHosts/__tests__/KnownHostsEditDialog.test.ts +1 -12
- package/components/form/SSHKnownHosts/index.vue +2 -16
- package/components/form/Security.vue +56 -54
- package/components/form/Select.vue +7 -41
- package/components/form/ShellInput.vue +1 -5
- package/components/form/Tolerations.vue +1 -5
- package/components/form/UnitInput.vue +2 -2
- package/components/form/ValueFromResource.vue +121 -134
- package/components/form/WorkloadPorts.vue +18 -18
- package/components/form/__tests__/ArrayList.test.ts +2 -5
- package/components/form/__tests__/MatchExpressions.test.ts +12 -12
- package/components/form/__tests__/NameNsDescription.test.ts +14 -115
- package/components/form/__tests__/Probe.test.ts +8 -12
- package/components/form/__tests__/SSHKnownHosts.test.ts +0 -11
- package/components/form/__tests__/Select.test.ts +0 -37
- package/components/form/__tests__/UnitInput.test.ts +5 -4
- package/components/formatter/BadgeStateFormatter.vue +5 -8
- package/components/formatter/ExtensionCache.vue +74 -0
- package/components/formatter/InternalExternalIP.vue +0 -2
- package/components/formatter/Port.vue +24 -0
- package/components/formatter/SecretData.vue +7 -20
- package/components/formatter/SecretType.vue +41 -0
- package/components/nav/Favorite.vue +1 -5
- package/components/nav/Group.vue +27 -60
- package/components/nav/Header.vue +13 -39
- package/components/nav/Jump.vue +0 -7
- package/components/nav/NamespaceFilter.vue +8 -14
- package/components/nav/Pinned.vue +1 -1
- package/components/nav/TopLevelMenu.vue +17 -5
- package/components/nav/Type.vue +35 -32
- package/components/nav/__tests__/TopLevelMenu.test.ts +40 -0
- package/components/templates/blank.vue +1 -4
- package/components/templates/default.vue +0 -8
- package/components/templates/home.vue +1 -10
- package/components/templates/plain.vue +1 -10
- package/package.json +1 -1
- package/components/ActionDropdownShell.vue +0 -71
- package/components/DotState.vue +0 -84
- package/components/ModalManager.vue +0 -55
- package/components/SlideInPanelManager.vue +0 -126
- package/components/StatusBadge.vue +0 -77
- package/components/__tests__/ModalManager.spec.ts +0 -176
- package/components/__tests__/SlideInPanelManager.spec.ts +0 -166
|
@@ -15,8 +15,7 @@ export default {
|
|
|
15
15
|
},
|
|
16
16
|
|
|
17
17
|
indexTo() {
|
|
18
|
-
|
|
19
|
-
return Math.min(this.totalRows, this.indexFrom + Number(this.perPage) - 1);
|
|
18
|
+
return Math.min(this.totalRows, this.indexFrom + this.perPage - 1);
|
|
20
19
|
},
|
|
21
20
|
|
|
22
21
|
totalPages() {
|
|
@@ -24,18 +23,17 @@ export default {
|
|
|
24
23
|
},
|
|
25
24
|
|
|
26
25
|
showPaging() {
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
26
|
+
if (!this.paging) {
|
|
27
|
+
return false;
|
|
28
|
+
}
|
|
30
29
|
|
|
31
|
-
|
|
30
|
+
const havePages = this.totalPages > 1;
|
|
32
31
|
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
32
|
+
if (this.altLoading) {
|
|
33
|
+
return havePages;
|
|
34
|
+
}
|
|
36
35
|
|
|
37
|
-
|
|
38
|
-
return !this.loading && this.paging && this.totalPages >= 1;
|
|
36
|
+
return !this.loading && havePages;
|
|
39
37
|
},
|
|
40
38
|
|
|
41
39
|
pagingDisplay() {
|
|
@@ -63,9 +61,9 @@ export default {
|
|
|
63
61
|
},
|
|
64
62
|
|
|
65
63
|
data() {
|
|
66
|
-
|
|
64
|
+
const perPage = this.getPerPage();
|
|
67
65
|
|
|
68
|
-
return { page: 1, perPage
|
|
66
|
+
return { page: 1, perPage };
|
|
69
67
|
},
|
|
70
68
|
|
|
71
69
|
watch: {
|
|
@@ -80,37 +78,31 @@ export default {
|
|
|
80
78
|
}
|
|
81
79
|
},
|
|
82
80
|
|
|
83
|
-
|
|
84
|
-
|
|
85
|
-
|
|
81
|
+
page() {
|
|
82
|
+
this.debouncedPaginationChanged();
|
|
83
|
+
},
|
|
86
84
|
|
|
87
|
-
|
|
88
|
-
|
|
89
|
-
|
|
85
|
+
perPage() {
|
|
86
|
+
this.debouncedPaginationChanged();
|
|
87
|
+
},
|
|
90
88
|
|
|
91
89
|
},
|
|
92
90
|
|
|
93
91
|
methods: {
|
|
94
|
-
|
|
95
|
-
|
|
96
|
-
|
|
92
|
+
getPerPage() {
|
|
93
|
+
// perPage can not change while the list is displayed
|
|
94
|
+
let out = this.rowsPerPage || 0;
|
|
97
95
|
|
|
98
|
-
|
|
99
|
-
|
|
100
|
-
|
|
101
|
-
|
|
102
|
-
// // This should ideally never happen, but the preference value could be invalid, so return something...
|
|
103
|
-
// if ( out <= 0 ) {
|
|
104
|
-
// out = 10;
|
|
105
|
-
// }
|
|
106
|
-
|
|
107
|
-
// return out;
|
|
108
|
-
// },
|
|
96
|
+
if ( out <= 0 ) {
|
|
97
|
+
out = parseInt(this.$store.getters['prefs/get'](ROWS_PER_PAGE), 10) || 0;
|
|
98
|
+
}
|
|
109
99
|
|
|
100
|
+
// This should ideally never happen, but the preference value could be invalid, so return something...
|
|
101
|
+
if ( out <= 0 ) {
|
|
102
|
+
out = 10;
|
|
103
|
+
}
|
|
110
104
|
|
|
111
|
-
|
|
112
|
-
this.setPage(1);
|
|
113
|
-
this.perPage = num;
|
|
105
|
+
return out;
|
|
114
106
|
},
|
|
115
107
|
|
|
116
108
|
setPage(num) {
|
|
@@ -340,6 +340,17 @@ export default {
|
|
|
340
340
|
if ( !isSelected ) {
|
|
341
341
|
this.update([node], this.selectedRows.slice());
|
|
342
342
|
}
|
|
343
|
+
|
|
344
|
+
let resources = this.selectedRows;
|
|
345
|
+
|
|
346
|
+
if ( this.mangleActionResources ) {
|
|
347
|
+
resources = await this.mangleActionResources(resources);
|
|
348
|
+
}
|
|
349
|
+
|
|
350
|
+
this.$store.commit(`action-menu/show`, {
|
|
351
|
+
resources,
|
|
352
|
+
event: e,
|
|
353
|
+
});
|
|
343
354
|
},
|
|
344
355
|
|
|
345
356
|
keySelectRow(row, more = false) {
|
|
@@ -100,14 +100,14 @@ export default {
|
|
|
100
100
|
v-if="shouldShowHeader"
|
|
101
101
|
class="tab-header"
|
|
102
102
|
>
|
|
103
|
-
|
|
103
|
+
<h2>
|
|
104
104
|
{{ labelDisplay }}
|
|
105
105
|
<i
|
|
106
106
|
v-if="tooltip"
|
|
107
107
|
v-clean-tooltip="tooltip"
|
|
108
108
|
class="icon icon-info icon-lg"
|
|
109
109
|
/>
|
|
110
|
-
</h2>
|
|
110
|
+
</h2>
|
|
111
111
|
<slot name="tab-header-right" />
|
|
112
112
|
</div>
|
|
113
113
|
<slot v-bind="{active}" />
|
|
@@ -118,7 +118,7 @@ export default {
|
|
|
118
118
|
.tab-header {
|
|
119
119
|
display: flex;
|
|
120
120
|
justify-content: space-between;
|
|
121
|
-
|
|
121
|
+
margin-bottom: 15px;
|
|
122
122
|
align-items: center;
|
|
123
123
|
|
|
124
124
|
h2 {
|
|
@@ -367,6 +367,15 @@ export default {
|
|
|
367
367
|
margin: 0;
|
|
368
368
|
padding: 0;
|
|
369
369
|
|
|
370
|
+
&:focus-visible {
|
|
371
|
+
outline: none;
|
|
372
|
+
|
|
373
|
+
.tab.active {
|
|
374
|
+
@include focus-outline;
|
|
375
|
+
outline-offset: -2px;
|
|
376
|
+
}
|
|
377
|
+
}
|
|
378
|
+
|
|
370
379
|
&.horizontal {
|
|
371
380
|
border: solid thin var(--border);
|
|
372
381
|
border-bottom: 0;
|
|
@@ -382,12 +391,8 @@ export default {
|
|
|
382
391
|
}
|
|
383
392
|
}
|
|
384
393
|
|
|
385
|
-
&:focus {
|
|
386
|
-
|
|
387
|
-
|
|
388
|
-
& .tab.active a span {
|
|
389
|
-
text-decoration: none;
|
|
390
|
-
}
|
|
394
|
+
&:focus .tab.active a span {
|
|
395
|
+
text-decoration: underline;
|
|
391
396
|
}
|
|
392
397
|
|
|
393
398
|
.tab {
|
|
@@ -404,7 +409,7 @@ export default {
|
|
|
404
409
|
&:hover {
|
|
405
410
|
text-decoration: none;
|
|
406
411
|
span {
|
|
407
|
-
text-decoration:
|
|
412
|
+
text-decoration: underline;
|
|
408
413
|
}
|
|
409
414
|
}
|
|
410
415
|
}
|
|
@@ -474,68 +479,45 @@ export default {
|
|
|
474
479
|
|
|
475
480
|
.side-tabs {
|
|
476
481
|
display: flex;
|
|
477
|
-
|
|
478
|
-
/* box-shadow: 0 0 20px var(--shadow);
|
|
482
|
+
box-shadow: 0 0 20px var(--shadow);
|
|
479
483
|
border-radius: calc(var(--border-radius) * 2);
|
|
480
|
-
background-color: var(--tabbed-sidebar-bg);
|
|
481
|
-
|
|
484
|
+
background-color: var(--tabbed-sidebar-bg);
|
|
485
|
+
|
|
482
486
|
.tab-container {
|
|
483
487
|
padding: 20px;
|
|
484
488
|
}
|
|
485
489
|
|
|
486
490
|
& .tabs {
|
|
487
|
-
|
|
488
|
-
|
|
491
|
+
width: $sideways-tabs-width;
|
|
492
|
+
min-width: $sideways-tabs-width;
|
|
489
493
|
display: flex;
|
|
490
|
-
|
|
491
|
-
|
|
492
|
-
/* flex: 1 0; */
|
|
493
|
-
/* flex-direction: column; */
|
|
494
|
+
flex: 1 0;
|
|
495
|
+
flex-direction: column;
|
|
494
496
|
|
|
495
497
|
// &.vertical {
|
|
496
498
|
// .tab.active {
|
|
497
499
|
// background-color: var(--tabbed-container-bg);
|
|
498
500
|
// }
|
|
499
501
|
// }
|
|
502
|
+
|
|
500
503
|
& .tab {
|
|
501
|
-
|
|
502
|
-
|
|
503
|
-
height: 36px;
|
|
504
|
-
/* border-top: solid 5px transparent; */
|
|
505
|
-
display: flex;
|
|
506
|
-
justify-content: center;
|
|
507
|
-
padding: 8px 16px;
|
|
508
|
-
box-sizing: border-box;
|
|
509
|
-
border: 1px solid #d7d7d7;
|
|
510
|
-
border-bottom: 0px;
|
|
511
|
-
margin-right: 5px;
|
|
512
|
-
border-radius: 2px;
|
|
504
|
+
width: 100%;
|
|
505
|
+
border-left: solid 5px transparent;
|
|
513
506
|
|
|
514
507
|
&.toggle A {
|
|
515
508
|
color: var(--primary);
|
|
516
|
-
padding: 0px;
|
|
517
509
|
}
|
|
518
510
|
|
|
519
511
|
A {
|
|
520
|
-
color: var(--
|
|
521
|
-
padding: 0px;
|
|
512
|
+
color: var(--primary);
|
|
522
513
|
}
|
|
523
514
|
|
|
524
515
|
&.active {
|
|
525
516
|
background-color: var(--body-bg);
|
|
526
|
-
border-
|
|
527
|
-
position: relative;
|
|
528
|
-
&.active::before{
|
|
529
|
-
position: absolute;
|
|
530
|
-
right: 0;
|
|
531
|
-
left: 0;
|
|
532
|
-
top: 34px;
|
|
533
|
-
border-bottom: 1px solid #fff;
|
|
534
|
-
content: '';
|
|
517
|
+
border-left: solid 5px var(--primary);
|
|
535
518
|
|
|
536
|
-
}
|
|
537
519
|
& A {
|
|
538
|
-
color: var(--
|
|
520
|
+
color: var(--input-label);
|
|
539
521
|
}
|
|
540
522
|
}
|
|
541
523
|
|
|
@@ -579,7 +561,7 @@ margin: 0px -20px;
|
|
|
579
561
|
&
|
|
580
562
|
|
|
581
563
|
.tab-container {
|
|
582
|
-
|
|
564
|
+
width: calc(100% - #{$sideways-tabs-width});
|
|
583
565
|
flex-grow: 1;
|
|
584
566
|
background-color: var(--body-bg);
|
|
585
567
|
}
|
package/components/Wizard.vue
CHANGED
|
@@ -426,7 +426,7 @@ export default {
|
|
|
426
426
|
</div>
|
|
427
427
|
<div
|
|
428
428
|
id="wizard-footer-controls"
|
|
429
|
-
class="controls-row"
|
|
429
|
+
class="controls-row pt-20"
|
|
430
430
|
>
|
|
431
431
|
<slot
|
|
432
432
|
name="cancel"
|
|
@@ -674,7 +674,7 @@ $spacer: 10px;
|
|
|
674
674
|
// We have to account for the absolute position of the .controls-row
|
|
675
675
|
.footer-error {
|
|
676
676
|
margin-top: -40px;
|
|
677
|
-
margin-bottom:
|
|
677
|
+
margin-bottom: 70px;
|
|
678
678
|
}
|
|
679
679
|
|
|
680
680
|
.controls-row {
|
|
@@ -42,7 +42,7 @@ describe('component: AsyncButton', () => {
|
|
|
42
42
|
expect(span.text()).toBe('some-string');
|
|
43
43
|
});
|
|
44
44
|
|
|
45
|
-
it('click on async button should emit click with a proper state of waiting,
|
|
45
|
+
it('click on async button should emit click with a proper state of waiting, disabled and spinning ::: CB true', () => {
|
|
46
46
|
jest.useFakeTimers();
|
|
47
47
|
|
|
48
48
|
const wrapper: VueWrapper<InstanceType<typeof AsyncButton>> = mount(AsyncButton, {
|
|
@@ -65,7 +65,7 @@ describe('component: AsyncButton', () => {
|
|
|
65
65
|
expect(wrapper.emitted('click')).toHaveLength(1);
|
|
66
66
|
expect(wrapper.vm.phase).toBe(ASYNC_BUTTON_STATES.WAITING);
|
|
67
67
|
expect(wrapper.vm.isSpinning).toBe(true);
|
|
68
|
-
expect(wrapper.vm.
|
|
68
|
+
expect(wrapper.vm.isDisabled).toBe(true);
|
|
69
69
|
// testing cb function has been emitted
|
|
70
70
|
expect(typeof wrapper.emitted('click')![0][0]).toBe('function');
|
|
71
71
|
|
|
@@ -40,7 +40,7 @@ describe('component: FixedBanner', () => {
|
|
|
40
40
|
expect(wrapper.vm.showHeader).toStrictEqual(true);
|
|
41
41
|
|
|
42
42
|
const bannerElem = wrapper.find('.banner');
|
|
43
|
-
const noArrayTextElem = wrapper.find('.banner
|
|
43
|
+
const noArrayTextElem = wrapper.find('.banner > p');
|
|
44
44
|
|
|
45
45
|
expect(bannerElem.exists()).toBe(true);
|
|
46
46
|
expect(bannerElem.classes()).not.toContain('banner-consent');
|
|
@@ -60,7 +60,7 @@ describe('component: FixedBanner', () => {
|
|
|
60
60
|
expect(wrapper.vm.showFooter).toStrictEqual(true);
|
|
61
61
|
|
|
62
62
|
const bannerElem = wrapper.find('.banner');
|
|
63
|
-
const noArrayTextElem = wrapper.find('.banner
|
|
63
|
+
const noArrayTextElem = wrapper.find('.banner > p');
|
|
64
64
|
|
|
65
65
|
expect(bannerElem.exists()).toBe(true);
|
|
66
66
|
expect(bannerElem.classes()).not.toContain('banner-consent');
|
|
@@ -84,7 +84,7 @@ describe('component: FixedBanner', () => {
|
|
|
84
84
|
const bannerDialogElem = wrapper.find('.banner-dialog');
|
|
85
85
|
const bannerDialogFrameElem = wrapper.find('.banner-dialog-frame');
|
|
86
86
|
const buttonDialog = wrapper.find('.banner-dialog button');
|
|
87
|
-
const noArrayTextElem = wrapper.find('.banner
|
|
87
|
+
const noArrayTextElem = wrapper.find('.banner > p');
|
|
88
88
|
|
|
89
89
|
expect(bannerElem.exists()).toBe(true);
|
|
90
90
|
expect(bannerDialogGlassElem.exists()).toBe(true);
|
|
@@ -90,7 +90,6 @@ export default {
|
|
|
90
90
|
<img
|
|
91
91
|
:src="principal.avatarSrc"
|
|
92
92
|
:class="{'round': principal.roundAvatar}"
|
|
93
|
-
:alt="t('principal.alt.avatar')"
|
|
94
93
|
>
|
|
95
94
|
</div>
|
|
96
95
|
<div
|
|
@@ -99,9 +98,9 @@ export default {
|
|
|
99
98
|
>
|
|
100
99
|
<table>
|
|
101
100
|
<tbody>
|
|
102
|
-
<tr><
|
|
103
|
-
<tr><
|
|
104
|
-
<tr><
|
|
101
|
+
<tr><td>{{ t('principal.name') }}: </td><td>{{ principal.name || principal.loginName }}</td></tr>
|
|
102
|
+
<tr><td>{{ t('principal.loginName') }}: </td><td>{{ principal.loginName }}</td></tr>
|
|
103
|
+
<tr><td>{{ t('principal.type') }}: </td><td>{{ principal.displayType }}</td></tr>
|
|
105
104
|
</tbody>
|
|
106
105
|
</table>
|
|
107
106
|
</div>
|
|
@@ -165,12 +164,6 @@ export default {
|
|
|
165
164
|
grid-template-rows: auto math.div($size, 2);
|
|
166
165
|
column-gap: 10px;
|
|
167
166
|
|
|
168
|
-
th {
|
|
169
|
-
text-align: left;
|
|
170
|
-
font-weight: normal;
|
|
171
|
-
padding-right: 10px;
|
|
172
|
-
}
|
|
173
|
-
|
|
174
167
|
&.showLabels {
|
|
175
168
|
grid-template-areas:
|
|
176
169
|
"avatar name";
|
|
@@ -51,9 +51,8 @@ describe('component: RoleDetailEdit', () => {
|
|
|
51
51
|
const wrapper = mount(RoleDetailEdit, {
|
|
52
52
|
props: {
|
|
53
53
|
value: {
|
|
54
|
-
rules:
|
|
55
|
-
subtype:
|
|
56
|
-
metadata: { name: 'global-role-with-inherited' },
|
|
54
|
+
rules: [{ verbs }],
|
|
55
|
+
subtype: 'GLOBAL'
|
|
57
56
|
},
|
|
58
57
|
},
|
|
59
58
|
|