@appscode/design-system 2.0.59 → 2.0.60
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/package.json +1 -1
- package/plugins/theme.js +2 -5
- package/plugins/time-convert.js +5 -9
- package/plugins/vue-toaster.js +2 -1
- package/vue-components/plugins/time-convert.js +2 -6
- package/vue-components/styles/base/utilities/_colors.scss +20 -26
- package/vue-components/styles/base/utilities/_generate-color-classes.scss +41 -233
- package/vue-components/styles/base/utilities/_global.scss +13 -14
- package/vue-components/styles/base/utilities/_layouts.scss +1 -2
- package/vue-components/styles/base/utilities/_mixin.scss +8 -46
- package/vue-components/styles/base/utilities/_root-variables.scss +1 -1
- package/vue-components/styles/base/utilities/_spacing.scss +1 -1
- package/vue-components/styles/base/utilities/_typography.scss +1 -1
- package/vue-components/styles/components/_ac-drag.scss +1 -1
- package/vue-components/styles/components/_badge-tags.scss +75 -0
- package/vue-components/styles/components/_card-body-wrapper.scss +1 -1
- package/vue-components/styles/components/_pagination.scss +2 -2
- package/vue-components/styles/components/_preview-modal.scss +3 -3
- package/vue-components/styles/components/_progress-bar.scss +3 -3
- package/vue-components/styles/components/_table.scss +3 -3
- package/vue-components/styles/components/_tabs.scss +2 -2
- package/vue-components/styles/components/_terminal.scss +4 -4
- package/vue-components/styles/components/_wizard.scss +3 -3
- package/vue-components/styles/components/ac-toaster/_ac-toasted.scss +10 -5
- package/vue-components/styles/components/alert/_alert.scss +2 -12
- package/vue-components/styles/components/alert/_toast.scss +1 -1
- package/vue-components/styles/components/bbum/_all.scss +1 -1
- package/vue-components/styles/components/bbum/_card-team.scss +1 -6
- package/vue-components/styles/components/bbum/_information-center.scss +4 -4
- package/vue-components/styles/components/bbum/_mobile-desktop.scss +10 -5
- package/vue-components/styles/components/bbum/_user-profile.scss +1 -1
- package/vue-components/styles/components/cards/_info.scss +1 -7
- package/vue-components/styles/components/editor/_filtered-file-editor.scss +3 -3
- package/vue-components/styles/components/editor/_monaco-editor.scss +1 -1
- package/vue-components/styles/components/form-fields/_input-card.scss +2 -2
- package/vue-components/styles/components/form-fields/_input.scss +3 -3
- package/vue-components/styles/components/navbar/_menu-content.scss +1 -2
- package/vue-components/styles/components/select-box/_ac-select-box.scss +2 -2
- package/vue-components/styles/components/select-box/_multi-select.scss +4 -9
- package/vue-components/styles/components/sidebar/_left-sidebar.scss +2 -2
- package/vue-components/styles/components/ui-builder/_ui-builder.scss +1 -1
- package/vue-components/styles/components/ui-builder/_vue-open-api.scss +5 -10
- package/vue-components/styles/layouts/_code-preview.scss +2 -2
- package/vue-components/styles/theme/_dark.scss +1 -1
- package/vue-components/v2/breadcrumbs/Breadcrumb.vue +14 -27
- package/vue-components/v2/button/Button.vue +2 -7
- package/vue-components/v2/button/DownloadBtn.vue +9 -9
- package/vue-components/v2/card/CardContent.vue +1 -1
- package/vue-components/v2/card/CardHeader.vue +2 -4
- package/vue-components/v2/card/PaymentCard.vue +1 -1
- package/vue-components/v2/card/PaymentCardOptionButtons.vue +1 -1
- package/vue-components/v2/card/PaymentCards.vue +15 -11
- package/vue-components/v2/content/ContentHeader.vue +6 -6
- package/vue-components/v2/editor/Editor.vue +2 -11
- package/vue-components/v2/editor/FilteredFileEditor.vue +5 -17
- package/vue-components/v2/editor/MonacoEditor.vue +5 -12
- package/vue-components/v2/editor/ResourceKeyValueEditor.vue +4 -14
- package/vue-components/v2/form/Form.vue +9 -12
- package/vue-components/v2/header/Header.vue +1 -4
- package/vue-components/v2/loaders/ResourceLoader.vue +5 -5
- package/vue-components/v2/loaders/SidebarLoader.vue +5 -5
- package/vue-components/v2/modal/Modal.vue +2 -7
- package/vue-components/v2/modals/DeleteConfirmationModal.vue +1 -6
- package/vue-components/v2/modals/JsonShowModal.vue +3 -15
- package/vue-components/v2/navbar/Appdrawer.vue +2 -10
- package/vue-components/v2/navbar/ThemeMode.vue +12 -18
- package/vue-components/v2/navbar/User.vue +19 -82
- package/vue-components/v2/notification/Notification.vue +3 -12
- package/vue-components/v2/notification/NotificationItem.vue +1 -3
- package/vue-components/v2/pagination/Pagination.vue +5 -26
- package/vue-components/v2/preloader/Preloader.vue +5 -5
- package/vue-components/v2/searchbars/SearchBar.vue +1 -7
- package/vue-components/v2/sidebar/ClusterSwitcher.vue +2 -2
- package/vue-components/v2/sidebar/SidebarItem.vue +2 -10
- package/vue-components/v2/sidebar/SidebarItemWithDropDown.vue +1 -2
- package/vue-components/v2/table/FakeTableCell.vue +1 -2
- package/vue-components/v2/table/InfoTable.vue +4 -10
- package/vue-components/v2/table/Table.vue +16 -64
- package/vue-components/v2/table/TableRow.vue +3 -15
- package/vue-components/v2/table/table-cell/ArrayCell.vue +3 -9
- package/vue-components/v2/table/table-cell/CellValue.vue +1 -2
- package/vue-components/v2/table/table-cell/GenericCell.vue +8 -8
- package/vue-components/v2/table/table-cell/ObjectCell.vue +2 -6
- package/vue-components/v2/table/table-cell/ValueWithModal.vue +1 -6
- package/vue-components/v3/alert/AlertMessage.vue +1 -5
- package/vue-components/v3/alert/Toast.vue +1 -4
- package/vue-components/v3/badge-tags/Badge.vue +24 -0
- package/vue-components/v3/badge-tags/Tag.vue +26 -0
- package/vue-components/v3/breadcrumbs/Breadcrumb.vue +6 -24
- package/vue-components/v3/button/Button.vue +2 -11
- package/vue-components/v3/cards/CardHeader.vue +1 -3
- package/vue-components/v3/cards/Cluster.vue +3 -9
- package/vue-components/v3/cards/Counter.vue +1 -4
- package/vue-components/v3/cards/FeatureCard.vue +1 -6
- package/vue-components/v3/cards/FeatureCards.vue +1 -5
- package/vue-components/v3/cards/InfoCard.vue +10 -30
- package/vue-components/v3/cards/Monitoring.vue +3 -15
- package/vue-components/v3/cards/OrgCard.vue +7 -26
- package/vue-components/v3/cards/OverviewCards.vue +1 -3
- package/vue-components/v3/cards/Payment.vue +1 -4
- package/vue-components/v3/content/ContentHeader.vue +1 -3
- package/vue-components/v3/content/ContentTable.vue +4 -16
- package/vue-components/v3/dropdown/DropdownAction.vue +1 -5
- package/vue-components/v3/editor/Editor.vue +33 -19
- package/vue-components/v3/editor/FilteredFileEditor.vue +29 -27
- package/vue-components/v3/editor/MonacoEditor.vue +7 -17
- package/vue-components/v3/editor/ResourceKeyValueEditor.vue +5 -17
- package/vue-components/v3/footer/Status.vue +5 -18
- package/vue-components/v3/footer/Usage.vue +1 -5
- package/vue-components/v3/form/Form.vue +1 -3
- package/vue-components/v3/form-fields/FileUpload.vue +3 -11
- package/vue-components/v3/form-fields/FileUploadSmall.vue +1 -3
- package/vue-components/v3/form-fields/Searchbar.vue +5 -21
- package/vue-components/v3/header/Header.vue +1 -4
- package/vue-components/v3/loaders/ClusterSwitcherLoader.vue +1 -6
- package/vue-components/v3/loaders/InfoCardLoader.vue +1 -6
- package/vue-components/v3/loaders/SingleInfoCardLoader.vue +1 -6
- package/vue-components/v3/modal/Modal.vue +5 -19
- package/vue-components/v3/modals/DeleteConfirmationModal.vue +1 -6
- package/vue-components/v3/modals/JsonShowModal.vue +5 -17
- package/vue-components/v3/navbar/Appdrawer.vue +2 -10
- package/vue-components/v3/navbar/Navbar.vue +2 -10
- package/vue-components/v3/navbar/NavbarItem.vue +1 -5
- package/vue-components/v3/navbar/Notification.vue +7 -31
- package/vue-components/v3/navbar/ThemeMode.vue +5 -17
- package/vue-components/v3/navbar/User.vue +64 -67
- package/vue-components/v3/notification/AlertBox.vue +6 -20
- package/vue-components/v3/notification/Notification.vue +6 -25
- package/vue-components/v3/notification/NotificationItem.vue +3 -9
- package/vue-components/v3/pagination/Pagination.vue +7 -25
- package/vue-components/v3/searchbars/SearchBar.vue +3 -17
- package/vue-components/v3/sidebar/AccentColorPicker.vue +3 -12
- package/vue-components/v3/sidebar/SidebarFooter.vue +3 -17
- package/vue-components/v3/sidebar/SidebarHeader.vue +4 -28
- package/vue-components/v3/sidebar/SidebarItem.vue +3 -11
- package/vue-components/v3/sidebar/SidebarItemWithDropDown.vue +3 -7
- package/vue-components/v3/sidebar/Steps.vue +1 -2
- package/vue-components/v3/sidebar/sidebar-tabs/SidebarTabsLayout.vue +1 -4
- package/vue-components/v3/sidebar/sidebar-tabs/TabsContent.vue +34 -52
- package/vue-components/v3/steps/ColoredSteps.vue +75 -0
- package/vue-components/v3/table/InfoTable.vue +5 -17
- package/vue-components/v3/table/MultiInfoTable.vue +6 -20
- package/vue-components/v3/table/Table.vue +15 -63
- package/vue-components/v3/table/TableContainer.vue +1 -4
- package/vue-components/v3/table/TableRow.vue +5 -24
- package/vue-components/v3/table/table-cell/ArrayCell.vue +6 -20
- package/vue-components/v3/table/table-cell/CellValue.vue +3 -9
- package/vue-components/v3/table/table-cell/GenericCell.vue +2 -5
- package/vue-components/v3/table/table-cell/ObjectCell.vue +5 -17
- package/vue-components/v3/table/table-cell/ValueWithModal.vue +2 -9
- package/vue-components/styles/components/_ac-tags.scss +0 -116
- package/vue-components/v3/badge/Badge.vue +0 -3
|
@@ -58,13 +58,13 @@
|
|
|
58
58
|
|
|
59
59
|
/* Handle */
|
|
60
60
|
&::-webkit-scrollbar-thumb {
|
|
61
|
-
background-color: $
|
|
61
|
+
background-color: $gray-50;
|
|
62
62
|
border-radius: 10px;
|
|
63
63
|
}
|
|
64
64
|
|
|
65
65
|
/* Handle on hover */
|
|
66
66
|
&::-webkit-scrollbar-thumb:hover {
|
|
67
|
-
background-color: $
|
|
67
|
+
background-color: $gray-50;
|
|
68
68
|
}
|
|
69
69
|
|
|
70
70
|
.number {
|
|
@@ -2,15 +2,8 @@
|
|
|
2
2
|
<div class="ac-breadcrumb">
|
|
3
3
|
<nav aria-label="breadcrumbs" class="breadcrumb">
|
|
4
4
|
<ul>
|
|
5
|
-
<li
|
|
6
|
-
|
|
7
|
-
:key="idx"
|
|
8
|
-
:class="{ 'is-active': idx === list.length - 1 }"
|
|
9
|
-
>
|
|
10
|
-
<router-link
|
|
11
|
-
class="router-link-active"
|
|
12
|
-
:class="{ 'is-active': idx === list.length - 1 }"
|
|
13
|
-
:to="item.path"
|
|
5
|
+
<li v-for="(item, idx) in list" :key="idx" :class="{ 'is-active': idx === list.length - 1 }">
|
|
6
|
+
<router-link class="router-link-active" :class="{ 'is-active': idx === list.length - 1 }" :to="item.path"
|
|
14
7
|
>{{ item.name }}
|
|
15
8
|
</router-link>
|
|
16
9
|
</li>
|
|
@@ -22,15 +15,13 @@
|
|
|
22
15
|
export default {
|
|
23
16
|
data() {
|
|
24
17
|
return {
|
|
25
|
-
list: []
|
|
18
|
+
list: [],
|
|
26
19
|
};
|
|
27
20
|
},
|
|
28
21
|
methods: {
|
|
29
22
|
createBreadcrumbs(n) {
|
|
30
23
|
//Adding dynamic path to the route
|
|
31
|
-
const listPaths = this.$route.matched.map(element =>
|
|
32
|
-
this.pathReplaceWithParam(element.path)
|
|
33
|
-
);
|
|
24
|
+
const listPaths = this.$route.matched.map((element) => this.pathReplaceWithParam(element.path));
|
|
34
25
|
|
|
35
26
|
//Removing the last duplicate value from the listpaths array
|
|
36
27
|
listPaths.pop();
|
|
@@ -42,37 +33,33 @@ export default {
|
|
|
42
33
|
this.list = listName.map((element, index) => {
|
|
43
34
|
return {
|
|
44
35
|
name: element,
|
|
45
|
-
path: listPaths[index]
|
|
36
|
+
path: listPaths[index],
|
|
46
37
|
};
|
|
47
38
|
});
|
|
48
39
|
},
|
|
49
40
|
pathReplaceWithParam(path) {
|
|
50
41
|
//Split the path and remove the first and last empty block
|
|
51
|
-
let splitPath = path.split("/").filter(element => element !== "");
|
|
42
|
+
let splitPath = path.split("/").filter((element) => element !== "");
|
|
52
43
|
|
|
53
44
|
//Replace all element with query params where the element start with ":"
|
|
54
45
|
// Then again add them wthi "/" and return the path value
|
|
55
46
|
return splitPath.reduce((pval, cval) => {
|
|
56
47
|
if (cval[0] === ":") {
|
|
57
|
-
const cutIndex =
|
|
58
|
-
cval.indexOf("?") !== -1 ? cval.indexOf("?") : cval.length;
|
|
48
|
+
const cutIndex = cval.indexOf("?") !== -1 ? cval.indexOf("?") : cval.length;
|
|
59
49
|
return (pval += this.$route.params[cval.slice(1, cutIndex)] + "/");
|
|
60
50
|
} else return (pval += cval + "/");
|
|
61
51
|
}, "/");
|
|
62
52
|
},
|
|
63
53
|
createList(paths) {
|
|
64
54
|
//Split all the path and remove all empty block
|
|
65
|
-
let spath = paths.map(element => {
|
|
66
|
-
return element.split("/").filter(word => word !== "");
|
|
55
|
+
let spath = paths.map((element) => {
|
|
56
|
+
return element.split("/").filter((word) => word !== "");
|
|
67
57
|
});
|
|
68
58
|
|
|
69
59
|
// Convert all the path arry in one arry where each element is the different fo previous element
|
|
70
60
|
return spath.reduce((prev, curr, currentIdx) => {
|
|
71
61
|
if (currentIdx === 0) return prev.concat([this.createVal(0, curr)]);
|
|
72
|
-
else
|
|
73
|
-
return prev.concat([
|
|
74
|
-
this.createVal(spath[currentIdx - 1].length, curr)
|
|
75
|
-
]);
|
|
62
|
+
else return prev.concat([this.createVal(spath[currentIdx - 1].length, curr)]);
|
|
76
63
|
}, []);
|
|
77
64
|
},
|
|
78
65
|
createVal(startIdx, paths) {
|
|
@@ -82,7 +69,7 @@ export default {
|
|
|
82
69
|
else return (prev += curr + " / ");
|
|
83
70
|
} else return prev + "";
|
|
84
71
|
}, "");
|
|
85
|
-
}
|
|
72
|
+
},
|
|
86
73
|
},
|
|
87
74
|
watch: {
|
|
88
75
|
"$route.path": {
|
|
@@ -90,8 +77,8 @@ export default {
|
|
|
90
77
|
immediate: true,
|
|
91
78
|
handler(n) {
|
|
92
79
|
this.createBreadcrumbs(n);
|
|
93
|
-
}
|
|
94
|
-
}
|
|
95
|
-
}
|
|
80
|
+
},
|
|
81
|
+
},
|
|
82
|
+
},
|
|
96
83
|
};
|
|
97
84
|
</script>
|
|
@@ -7,12 +7,7 @@
|
|
|
7
7
|
:title="tooltip"
|
|
8
8
|
>
|
|
9
9
|
<span v-if="iconClass || iconImage" class="icon is-small">
|
|
10
|
-
<img
|
|
11
|
-
v-if="iconImage"
|
|
12
|
-
:src="iconImage"
|
|
13
|
-
alt="close-icon"
|
|
14
|
-
:width="iconImageWidth"
|
|
15
|
-
/>
|
|
10
|
+
<img v-if="iconImage" :src="iconImage" alt="close-icon" :width="iconImageWidth" />
|
|
16
11
|
<i v-else :class="`fa fa-${iconClass}`" aria-hidden="true" />
|
|
17
12
|
</span>
|
|
18
13
|
<span v-if="title" :class="titleModifierClass">{{ title }}</span>
|
|
@@ -30,7 +25,7 @@ export default {
|
|
|
30
25
|
},
|
|
31
26
|
tooltip: {
|
|
32
27
|
type: String,
|
|
33
|
-
defualt: undefined
|
|
28
|
+
defualt: undefined,
|
|
34
29
|
},
|
|
35
30
|
// for loader
|
|
36
31
|
isLoaderActive: {
|
|
@@ -12,34 +12,34 @@ import downloadFunc from "downloadjs";
|
|
|
12
12
|
|
|
13
13
|
export default {
|
|
14
14
|
components: {
|
|
15
|
-
AcButton: () => import("./../button/Button.vue")
|
|
15
|
+
AcButton: () => import("./../button/Button.vue"),
|
|
16
16
|
},
|
|
17
17
|
props: {
|
|
18
18
|
fileData: {
|
|
19
19
|
type: String,
|
|
20
|
-
default: ""
|
|
20
|
+
default: "",
|
|
21
21
|
},
|
|
22
22
|
fileName: {
|
|
23
23
|
type: String,
|
|
24
|
-
default: ""
|
|
24
|
+
default: "",
|
|
25
25
|
},
|
|
26
26
|
isFetching: {
|
|
27
27
|
type: Boolean,
|
|
28
|
-
default: false
|
|
29
|
-
}
|
|
28
|
+
default: false,
|
|
29
|
+
},
|
|
30
30
|
},
|
|
31
31
|
data() {
|
|
32
32
|
return {
|
|
33
|
-
downloadIcon: "fa fa-cloud-download"
|
|
33
|
+
downloadIcon: "fa fa-cloud-download",
|
|
34
34
|
};
|
|
35
35
|
},
|
|
36
36
|
component: {
|
|
37
|
-
downloadFunc
|
|
37
|
+
downloadFunc,
|
|
38
38
|
},
|
|
39
39
|
methods: {
|
|
40
40
|
download() {
|
|
41
41
|
downloadFunc(this.fileData, this.fileName);
|
|
42
|
-
}
|
|
43
|
-
}
|
|
42
|
+
},
|
|
43
|
+
},
|
|
44
44
|
};
|
|
45
45
|
</script>
|
|
@@ -1,7 +1,5 @@
|
|
|
1
1
|
<template>
|
|
2
|
-
<div
|
|
3
|
-
class="is-flex is-justify-content-space-between pt-8 pb-8 pl-20 pr-20 b-1"
|
|
4
|
-
>
|
|
2
|
+
<div class="is-flex is-justify-content-space-between pt-8 pb-8 pl-20 pr-20 b-1">
|
|
5
3
|
<div class="header-left-content">
|
|
6
4
|
<slot name="card-header-left" />
|
|
7
5
|
</div>
|
|
@@ -9,4 +7,4 @@
|
|
|
9
7
|
<slot name="card-header-right" />
|
|
10
8
|
</div>
|
|
11
9
|
</div>
|
|
12
|
-
</template>
|
|
10
|
+
</template>
|
|
@@ -2,12 +2,7 @@
|
|
|
2
2
|
<div class="ac-payment-card-wrapper">
|
|
3
3
|
<!-- loader start -->
|
|
4
4
|
<div v-if="isLoaderActive" class="ac-payment-card is-transparent-bg p-0">
|
|
5
|
-
<content-loader
|
|
6
|
-
:height="235"
|
|
7
|
-
:speed="2"
|
|
8
|
-
:primaryColor="primaryColor"
|
|
9
|
-
:secondaryColor="secondaryColor"
|
|
10
|
-
/>
|
|
5
|
+
<content-loader :height="235" :speed="2" :primaryColor="primaryColor" :secondaryColor="secondaryColor" />
|
|
11
6
|
</div>
|
|
12
7
|
<!-- loader end -->
|
|
13
8
|
<template v-else>
|
|
@@ -20,7 +15,12 @@
|
|
|
20
15
|
</template>
|
|
21
16
|
<script>
|
|
22
17
|
import { ContentLoader } from "vue-content-loader";
|
|
23
|
-
import {
|
|
18
|
+
import {
|
|
19
|
+
loaderLightThemePrimaryColor,
|
|
20
|
+
loaderDarkThemePrimaryColor,
|
|
21
|
+
loaderLightThemeSecondaryColor,
|
|
22
|
+
loaderDarkThemeSecondaryColor,
|
|
23
|
+
} from "@appscode/design-system/plugins/theme";
|
|
24
24
|
|
|
25
25
|
export default {
|
|
26
26
|
components: {
|
|
@@ -34,11 +34,15 @@ export default {
|
|
|
34
34
|
},
|
|
35
35
|
computed: {
|
|
36
36
|
primaryColor() {
|
|
37
|
-
return document.documentElement.classList.contains("is-dark-theme")
|
|
37
|
+
return document.documentElement.classList.contains("is-dark-theme")
|
|
38
|
+
? loaderDarkThemePrimaryColor
|
|
39
|
+
: loaderLightThemePrimaryColor;
|
|
38
40
|
},
|
|
39
41
|
secondaryColor() {
|
|
40
|
-
return document.documentElement.classList.contains("is-dark-theme")
|
|
41
|
-
|
|
42
|
-
|
|
42
|
+
return document.documentElement.classList.contains("is-dark-theme")
|
|
43
|
+
? loaderDarkThemeSecondaryColor
|
|
44
|
+
: loaderLightThemeSecondaryColor;
|
|
45
|
+
},
|
|
46
|
+
},
|
|
43
47
|
};
|
|
44
48
|
</script>
|
|
@@ -31,20 +31,20 @@ export default {
|
|
|
31
31
|
props: {
|
|
32
32
|
headerTitle: {
|
|
33
33
|
type: String,
|
|
34
|
-
default: "Content Header"
|
|
34
|
+
default: "Content Header",
|
|
35
35
|
},
|
|
36
36
|
headerSubTitle: {
|
|
37
37
|
type: String,
|
|
38
|
-
default: ""
|
|
38
|
+
default: "",
|
|
39
39
|
},
|
|
40
40
|
removeBorderBottom: {
|
|
41
41
|
type: Boolean,
|
|
42
|
-
default: false
|
|
43
|
-
}
|
|
42
|
+
default: false,
|
|
43
|
+
},
|
|
44
44
|
},
|
|
45
45
|
|
|
46
46
|
components: {
|
|
47
|
-
HeaderItems: () => import("../header/HeaderItems.vue")
|
|
48
|
-
}
|
|
47
|
+
HeaderItems: () => import("../header/HeaderItems.vue"),
|
|
48
|
+
},
|
|
49
49
|
};
|
|
50
50
|
</script>
|
|
@@ -1,10 +1,6 @@
|
|
|
1
1
|
<template>
|
|
2
2
|
<div>
|
|
3
|
-
<editor-tabs
|
|
4
|
-
v-if="!readOnly"
|
|
5
|
-
@tabchange="activeTab = $event"
|
|
6
|
-
:active-tab="activeTab"
|
|
7
|
-
/>
|
|
3
|
+
<editor-tabs v-if="!readOnly" @tabchange="activeTab = $event" :active-tab="activeTab" />
|
|
8
4
|
<monaco-editor
|
|
9
5
|
v-if="activeTab === 'edit'"
|
|
10
6
|
@editorDidMount="onEditorMount"
|
|
@@ -110,12 +106,7 @@ export default {
|
|
|
110
106
|
return this.showMinimap && noOfLines * 2 > this.editorHeight;
|
|
111
107
|
},
|
|
112
108
|
theme() {
|
|
113
|
-
return (
|
|
114
|
-
this.editorTheme ||
|
|
115
|
-
(document.documentElement.classList.contains("is-dark-theme")
|
|
116
|
-
? "vs-dark"
|
|
117
|
-
: "vs")
|
|
118
|
-
);
|
|
109
|
+
return this.editorTheme || (document.documentElement.classList.contains("is-dark-theme") ? "vs-dark" : "vs");
|
|
119
110
|
},
|
|
120
111
|
},
|
|
121
112
|
|
|
@@ -3,10 +3,7 @@
|
|
|
3
3
|
<div class="ac-preview-inner">
|
|
4
4
|
<!-- preview body start -->
|
|
5
5
|
<div class="ac-preview-body mt-0 pt-15 pl-20">
|
|
6
|
-
<div
|
|
7
|
-
v-if="isPreviewLoading || (!isPreviewLoading && previewYamls)"
|
|
8
|
-
class="left-content"
|
|
9
|
-
>
|
|
6
|
+
<div v-if="isPreviewLoading || (!isPreviewLoading && previewYamls)" class="left-content">
|
|
10
7
|
<div class="ac-files ac-hscrollbar ac-vscrollbar pt-0">
|
|
11
8
|
<ul v-if="!isPreviewLoading">
|
|
12
9
|
<li
|
|
@@ -17,10 +14,7 @@
|
|
|
17
14
|
>
|
|
18
15
|
<a @click.prevent="setActivePreview(previewYaml.uid)">
|
|
19
16
|
<span>
|
|
20
|
-
<img
|
|
21
|
-
src="~@appscode/design-system-images/icons/file-icon.svg"
|
|
22
|
-
alt=""
|
|
23
|
-
/>
|
|
17
|
+
<img src="~@appscode/design-system-images/icons/file-icon.svg" alt="" />
|
|
24
18
|
</span>
|
|
25
19
|
<span>{{ previewYaml.name }}</span>
|
|
26
20
|
</a>
|
|
@@ -123,15 +117,11 @@ export default {
|
|
|
123
117
|
},
|
|
124
118
|
computed: {
|
|
125
119
|
activeFile() {
|
|
126
|
-
const activeFile = this.filteredYamls.find(
|
|
127
|
-
(element) => element.uid === this.activeKey
|
|
128
|
-
);
|
|
120
|
+
const activeFile = this.filteredYamls.find((element) => element.uid === this.activeKey);
|
|
129
121
|
return activeFile || { content: "", format: "yaml" };
|
|
130
122
|
},
|
|
131
123
|
originalValue() {
|
|
132
|
-
const activeFile = this.filteredYamls.find(
|
|
133
|
-
(element) => element.uid === this.activeKey
|
|
134
|
-
);
|
|
124
|
+
const activeFile = this.filteredYamls.find((element) => element.uid === this.activeKey);
|
|
135
125
|
return (activeFile && activeFile.initContent) || "";
|
|
136
126
|
},
|
|
137
127
|
editorTheme() {
|
|
@@ -145,9 +135,7 @@ export default {
|
|
|
145
135
|
},
|
|
146
136
|
filteredYamls() {
|
|
147
137
|
if (this.searchText) {
|
|
148
|
-
return this.previewYamls.filter(
|
|
149
|
-
(element) => JSON.stringify(element).search(this.searchText) > -1
|
|
150
|
-
);
|
|
138
|
+
return this.previewYamls.filter((element) => JSON.stringify(element).search(this.searchText) > -1);
|
|
151
139
|
} else return this.previewYamls;
|
|
152
140
|
},
|
|
153
141
|
isKeyAvailable() {
|
|
@@ -24,12 +24,8 @@ export default {
|
|
|
24
24
|
},
|
|
25
25
|
computed: {
|
|
26
26
|
style() {
|
|
27
|
-
const fixedWidth = this.width.toString().includes("%")
|
|
28
|
-
|
|
29
|
-
: `${this.width}px`;
|
|
30
|
-
const fixedHeight = this.height.toString().includes("%")
|
|
31
|
-
? this.height
|
|
32
|
-
: `${this.height}px`;
|
|
27
|
+
const fixedWidth = this.width.toString().includes("%") ? this.width : `${this.width}px`;
|
|
28
|
+
const fixedHeight = this.height.toString().includes("%") ? this.height : `${this.height}px`;
|
|
33
29
|
return {
|
|
34
30
|
width: fixedWidth,
|
|
35
31
|
height: fixedHeight,
|
|
@@ -47,9 +43,7 @@ export default {
|
|
|
47
43
|
initMonaco() {
|
|
48
44
|
this.$emit("editorWillMount", this.monaco);
|
|
49
45
|
const { value, language, theme, options } = this;
|
|
50
|
-
this.editor = monaco.editor[
|
|
51
|
-
this.diffEditor ? "createDiffEditor" : "create"
|
|
52
|
-
](this.$el, {
|
|
46
|
+
this.editor = monaco.editor[this.diffEditor ? "createDiffEditor" : "create"](this.$el, {
|
|
53
47
|
value: value,
|
|
54
48
|
language: language,
|
|
55
49
|
theme: theme,
|
|
@@ -114,12 +108,11 @@ export default {
|
|
|
114
108
|
const { original, modified } = this.editor.getModel();
|
|
115
109
|
monaco.editor.setModelLanguage(original, this.language);
|
|
116
110
|
monaco.editor.setModelLanguage(modified, this.language);
|
|
117
|
-
} else
|
|
118
|
-
monaco.editor.setModelLanguage(this.editor.getModel(), this.language);
|
|
111
|
+
} else monaco.editor.setModelLanguage(this.editor.getModel(), this.language);
|
|
119
112
|
},
|
|
120
113
|
theme() {
|
|
121
114
|
monaco.editor.setTheme(this.theme);
|
|
122
115
|
},
|
|
123
116
|
},
|
|
124
117
|
};
|
|
125
|
-
</script>
|
|
118
|
+
</script>
|
|
@@ -1,9 +1,5 @@
|
|
|
1
1
|
<template>
|
|
2
|
-
<content-table
|
|
3
|
-
:table-title="title"
|
|
4
|
-
:searchable="isSearchable"
|
|
5
|
-
:hide-header="hideHeader"
|
|
6
|
-
>
|
|
2
|
+
<content-table :table-title="title" :searchable="isSearchable" :hide-header="hideHeader">
|
|
7
3
|
<template #content-controls>
|
|
8
4
|
<header-item v-if="showHideBtn">
|
|
9
5
|
<ac-button
|
|
@@ -22,10 +18,7 @@
|
|
|
22
18
|
/>
|
|
23
19
|
</header-item>
|
|
24
20
|
<header-item v-if="showDownloadBtn">
|
|
25
|
-
<download-btn
|
|
26
|
-
:file-data="decode(activeFile)"
|
|
27
|
-
:file-name="activeFile.name"
|
|
28
|
-
/>
|
|
21
|
+
<download-btn :file-data="decode(activeFile)" :file-name="activeFile.name" />
|
|
29
22
|
</header-item>
|
|
30
23
|
<header-item v-if="showUpdateBtn && !isEditorReadOnly">
|
|
31
24
|
<ac-button
|
|
@@ -78,8 +71,7 @@ export default {
|
|
|
78
71
|
ContentTable: () => import("./../content/ContentTable.vue"),
|
|
79
72
|
HeaderItem: () => import("./../header/HeaderItem.vue"),
|
|
80
73
|
DownloadBtn: () => import("./../button/DownloadBtn.vue"),
|
|
81
|
-
DeleteConfirmationModal: () =>
|
|
82
|
-
import("./../modals/DeleteConfirmationModal.vue"),
|
|
74
|
+
DeleteConfirmationModal: () => import("./../modals/DeleteConfirmationModal.vue"),
|
|
83
75
|
FilteredFileEditor: () => import("./FilteredFileEditor.vue"),
|
|
84
76
|
},
|
|
85
77
|
props: {
|
|
@@ -151,9 +143,7 @@ export default {
|
|
|
151
143
|
},
|
|
152
144
|
computed: {
|
|
153
145
|
activeFile() {
|
|
154
|
-
const activeFile = this.previewYamls.find(
|
|
155
|
-
(element) => element.uid === this.activeKey
|
|
156
|
-
);
|
|
146
|
+
const activeFile = this.previewYamls.find((element) => element.uid === this.activeKey);
|
|
157
147
|
return activeFile || { content: "", format: "yaml" };
|
|
158
148
|
},
|
|
159
149
|
showCopyBtn() {
|
|
@@ -6,20 +6,17 @@
|
|
|
6
6
|
'pt-10': reducePaddingTop,
|
|
7
7
|
'pl-20': !isContainer,
|
|
8
8
|
'form-content': !isContainer,
|
|
9
|
-
container: isContainer
|
|
9
|
+
container: isContainer,
|
|
10
10
|
}"
|
|
11
11
|
>
|
|
12
12
|
<slot />
|
|
13
13
|
</div>
|
|
14
|
-
<div
|
|
15
|
-
class="form-footer b-t-1 pt-10 pb-10 pl-20 pr-20 mt-15"
|
|
16
|
-
v-if="hasFooter"
|
|
17
|
-
>
|
|
14
|
+
<div class="form-footer b-t-1 pt-10 pb-10 pl-20 pr-20 mt-15" v-if="hasFooter">
|
|
18
15
|
<div
|
|
19
16
|
class="ac-vcentered"
|
|
20
17
|
:class="{
|
|
21
18
|
'form-content': !isContainer,
|
|
22
|
-
container: isContainer
|
|
19
|
+
container: isContainer,
|
|
23
20
|
}"
|
|
24
21
|
>
|
|
25
22
|
<form-footer-controls>
|
|
@@ -38,20 +35,20 @@ export default {
|
|
|
38
35
|
props: {
|
|
39
36
|
isContainer: {
|
|
40
37
|
type: Boolean,
|
|
41
|
-
default: false
|
|
38
|
+
default: false,
|
|
42
39
|
},
|
|
43
40
|
hasFooter: {
|
|
44
41
|
type: Boolean,
|
|
45
|
-
default: true
|
|
42
|
+
default: true,
|
|
46
43
|
},
|
|
47
44
|
reducePaddingTop: {
|
|
48
45
|
type: Boolean,
|
|
49
|
-
default: false
|
|
50
|
-
}
|
|
46
|
+
default: false,
|
|
47
|
+
},
|
|
51
48
|
},
|
|
52
49
|
|
|
53
50
|
components: {
|
|
54
|
-
FormFooterControls: () => import("./FormFooterControls.vue")
|
|
55
|
-
}
|
|
51
|
+
FormFooterControls: () => import("./FormFooterControls.vue"),
|
|
52
|
+
},
|
|
56
53
|
};
|
|
57
54
|
</script>
|
|
@@ -1,9 +1,6 @@
|
|
|
1
1
|
<template>
|
|
2
2
|
<div class="inner-header">
|
|
3
|
-
<div
|
|
4
|
-
class="is-flex is-justify-content-space-between"
|
|
5
|
-
:class="{ container: isContainer }"
|
|
6
|
-
>
|
|
3
|
+
<div class="is-flex is-justify-content-space-between" :class="{ container: isContainer }">
|
|
7
4
|
<header-items>
|
|
8
5
|
<header-item>
|
|
9
6
|
<h5>{{ title }}</h5>
|
|
@@ -85,17 +85,17 @@ import { ContentLoader } from "vue-content-loader";
|
|
|
85
85
|
|
|
86
86
|
export default {
|
|
87
87
|
components: {
|
|
88
|
-
ContentLoader
|
|
88
|
+
ContentLoader,
|
|
89
89
|
},
|
|
90
90
|
props: {
|
|
91
91
|
primaryLoaderColor: {
|
|
92
92
|
type: String,
|
|
93
|
-
default: "#f5f7f9"
|
|
93
|
+
default: "#f5f7f9",
|
|
94
94
|
},
|
|
95
95
|
secondaryLoaderColor: {
|
|
96
96
|
type: String,
|
|
97
|
-
default: "#ecebeb"
|
|
98
|
-
}
|
|
99
|
-
}
|
|
97
|
+
default: "#ecebeb",
|
|
98
|
+
},
|
|
99
|
+
},
|
|
100
100
|
};
|
|
101
101
|
</script>
|
|
@@ -27,17 +27,17 @@ import { ContentLoader } from "vue-content-loader";
|
|
|
27
27
|
|
|
28
28
|
export default {
|
|
29
29
|
components: {
|
|
30
|
-
ContentLoader
|
|
30
|
+
ContentLoader,
|
|
31
31
|
},
|
|
32
32
|
props: {
|
|
33
33
|
primaryLoaderColor: {
|
|
34
34
|
type: String,
|
|
35
|
-
default: "#f5f7f9"
|
|
35
|
+
default: "#f5f7f9",
|
|
36
36
|
},
|
|
37
37
|
secondaryLoaderColor: {
|
|
38
38
|
type: String,
|
|
39
|
-
default: "#ecebeb"
|
|
40
|
-
}
|
|
41
|
-
}
|
|
39
|
+
default: "#ecebeb",
|
|
40
|
+
},
|
|
41
|
+
},
|
|
42
42
|
};
|
|
43
43
|
</script>
|
|
@@ -18,9 +18,7 @@
|
|
|
18
18
|
<ac-button
|
|
19
19
|
modifier-classes="is-square is-transparent"
|
|
20
20
|
:disabled="isCloseOptionDisabled"
|
|
21
|
-
:icon-image="
|
|
22
|
-
require('@appscode/design-system-images/icons/close-icon.svg')
|
|
23
|
-
"
|
|
21
|
+
:icon-image="require('@appscode/design-system-images/icons/close-icon.svg')"
|
|
24
22
|
data-testid="delete-confirmation-modal-close-icon"
|
|
25
23
|
@click.stop="destroyModal"
|
|
26
24
|
/>
|
|
@@ -30,10 +28,7 @@
|
|
|
30
28
|
<!-- modal header end -->
|
|
31
29
|
|
|
32
30
|
<!-- modal body start -->
|
|
33
|
-
<div
|
|
34
|
-
class="ac-modal-body ac-vscrollbar"
|
|
35
|
-
data-testid="ac-modal-content-with-scroll"
|
|
36
|
-
>
|
|
31
|
+
<div class="ac-modal-body ac-vscrollbar" data-testid="ac-modal-content-with-scroll">
|
|
37
32
|
<div class="ac-modal-content">
|
|
38
33
|
<!-- freedom content start -->
|
|
39
34
|
<slot />
|
|
@@ -1,11 +1,6 @@
|
|
|
1
1
|
<template>
|
|
2
2
|
<!-- modal start -->
|
|
3
|
-
<modal
|
|
4
|
-
:title="title"
|
|
5
|
-
modifier-classes="is-normal"
|
|
6
|
-
:open="open"
|
|
7
|
-
@closemodal="closeModal"
|
|
8
|
-
>
|
|
3
|
+
<modal :title="title" modifier-classes="is-normal" :open="open" @closemodal="closeModal">
|
|
9
4
|
<!-- freedom content start -->
|
|
10
5
|
<div class="action-message pt-35 pb-35 has-text-centered">
|
|
11
6
|
<h5 class="is-message">{{ message }} {{ itemName ? "" : "?" }}</h5>
|
|
@@ -1,29 +1,17 @@
|
|
|
1
1
|
<template>
|
|
2
|
-
<modal
|
|
3
|
-
:title="editorTitle"
|
|
4
|
-
:open="open"
|
|
5
|
-
@closemodal="closeModal"
|
|
6
|
-
modifier-classes="is-medium"
|
|
7
|
-
>
|
|
2
|
+
<modal :title="editorTitle" :open="open" @closemodal="closeModal" modifier-classes="is-medium">
|
|
8
3
|
<template #modal-header-controls>
|
|
9
4
|
<header-item>
|
|
10
5
|
<ac-button
|
|
11
6
|
modifier-classes="is-square is-primary"
|
|
12
7
|
icon-class="copy"
|
|
13
|
-
v-clipboard:copy="
|
|
14
|
-
`${editorTitle}: ${JSON.stringify(parsedContent, null, 4)}`
|
|
15
|
-
"
|
|
8
|
+
v-clipboard:copy="`${editorTitle}: ${JSON.stringify(parsedContent, null, 4)}`"
|
|
16
9
|
v-clipboard:success="onCopy"
|
|
17
10
|
v-clipboard:error="onError"
|
|
18
11
|
/>
|
|
19
12
|
</header-item>
|
|
20
13
|
</template>
|
|
21
|
-
<editor
|
|
22
|
-
:value="JSON.stringify(parsedContent, null, 4)"
|
|
23
|
-
:read-only="true"
|
|
24
|
-
language="json"
|
|
25
|
-
:show-minimap="false"
|
|
26
|
-
/>
|
|
14
|
+
<editor :value="JSON.stringify(parsedContent, null, 4)" :read-only="true" language="json" :show-minimap="false" />
|
|
27
15
|
</modal>
|
|
28
16
|
</template>
|
|
29
17
|
|