@appscode/design-system 1.0.43-alpha.13 → 1.0.43-alpha.132
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/base/utilities/_default.scss +283 -21
- package/base/utilities/_derived-variables.scss +0 -13
- package/base/utilities/_initial-variables.scss +78 -56
- package/base/utilities/_mixin.scss +10 -17
- package/base/utilities/_typography.scss +23 -7
- package/base/utilities/dark-theme.scss +25 -0
- package/components/_ac-accordion.scss +1 -0
- package/components/_ac-alert-box.scss +18 -10
- package/components/_ac-card.scss +55 -20
- package/components/_ac-code-highlight.scss +7 -1
- package/components/_ac-content-layout.scss +4 -4
- package/components/_ac-drag.scss +6 -6
- package/components/_ac-input.scss +74 -40
- package/components/_ac-modal.scss +5 -4
- package/components/_ac-multi-select.scss +195 -13
- package/components/_ac-options.scss +31 -16
- package/components/_ac-select-box.scss +15 -5
- package/components/_ac-table.scss +42 -36
- package/components/_ac-tabs.scss +72 -23
- package/components/_ac-tags.scss +2 -2
- package/components/_ac-terminal.scss +272 -0
- package/components/_app-drawer.scss +6 -6
- package/components/_breadcumb.scss +7 -2
- package/components/_buttons.scss +60 -27
- package/components/_card-body-wrapper.scss +3 -3
- package/components/_dashboard-header.scss +33 -1
- package/components/_direct-deploy.scss +69 -0
- package/components/_go-to-top.scss +1 -1
- package/components/_graph.scss +45 -0
- package/components/_image-upload.scss +6 -4
- package/components/_left-sidebar-menu.scss +200 -46
- package/components/_monaco-editor.scss +1 -1
- package/components/_navbar.scss +129 -26
- package/components/_overview-info.scss +4 -4
- package/components/_overview-page.scss +1 -2
- package/components/_pagination.scss +10 -2
- package/components/_payment-card.scss +28 -12
- package/components/_preview-modal.scss +19 -8
- package/components/_pricing-table.scss +1 -1
- package/components/_progress-bar.scss +5 -5
- package/components/_subscription-card.scss +15 -8
- package/components/_table-of-content.scss +1 -1
- package/components/_tfa.scss +69 -0
- package/components/_transitions.scss +261 -0
- package/components/_widget-menu.scss +9 -9
- package/components/_wizard.scss +31 -19
- package/components/ac-toaster/_ac-toasted.scss +5 -5
- package/components/bbum/_card-team.scss +18 -10
- package/components/bbum/_information-center.scss +17 -3
- package/components/bbum/_mobile-desktop.scss +6 -6
- package/components/bbum/_post.scss +5 -4
- package/components/bbum/_sign-up-notification.scss +6 -6
- package/components/bbum/_single-post-preview.scss +9 -9
- package/components/bbum/_user-profile.scss +97 -90
- package/components/ui-builder/_ui-builder.scss +29 -10
- package/components/ui-builder/_vue-open-api.scss +98 -0
- package/layouts/_404.scss +2 -1
- package/layouts/_code-preview.scss +14 -7
- package/main.scss +4 -0
- package/package.json +2 -7
- package/plugins/theme.js +130 -128
- package/vue-components/v2/banner/Banner.vue +2 -2
- package/vue-components/v2/breadcrumbs/Breadcrumb.vue +97 -0
- package/vue-components/v2/button/Button.vue +5 -0
- package/vue-components/v2/button/DownloadBtn.vue +45 -0
- package/vue-components/v2/card/PaymentCards.vue +11 -2
- package/vue-components/v2/content/ContentTable.vue +12 -7
- package/vue-components/v2/editor/Editor.vue +29 -1
- package/vue-components/v2/editor/FilteredFileEditor.vue +153 -0
- package/vue-components/v2/editor/ResourceKeyValueEditor.vue +196 -0
- package/vue-components/v2/loaders/ResourceLoader.vue +90 -0
- package/vue-components/v2/loaders/SidebarLoader.vue +32 -0
- package/vue-components/v2/modal/Modal.vue +33 -12
- package/vue-components/v2/modals/DeleteConfirmationModal.vue +77 -0
- package/vue-components/v2/modals/JsonShowModal.vue +12 -2
- package/vue-components/v2/navbar/Appdrawer.vue +10 -9
- package/vue-components/v2/navbar/ThemeMode.vue +120 -0
- package/vue-components/v2/navbar/User.vue +154 -12
- package/vue-components/v2/preloader/Preloader.vue +5 -5
- package/vue-components/v2/sidebar/ClusterSwitcher.vue +126 -0
- package/vue-components/v2/sidebar/SidebarItem.vue +23 -1
- package/vue-components/v2/sidebar/SidebarItemWithDropDown.vue +19 -20
- package/vue-components/v2/table/Table.vue +43 -8
- package/vue-components/v2/table/TableRow.vue +17 -8
- package/vue-components/v2/table/table-cell/CellValue.vue +31 -4
- package/vue-components/v2/table/table-cell/GenericCell.vue +56 -0
- package/vue-components/v2/table/table-cell/ObjectCell.vue +4 -1
- package/vue-components/v2/tabs/EditorTabs.vue +1 -1
- package/vue-components/v3/button/Button.vue +5 -0
- package/vue-components/v3/dropdown/DropdownMenu.vue +1 -1
- package/vue-components/v3/editor/Editor.vue +32 -11
- package/vue-components/v3/modal/Modal.vue +10 -1
- package/vue-components/v3/modals/JsonShowModal.vue +13 -4
- package/vue-components/v3/navbar/Appdrawer.vue +12 -7
- package/vue-components/v3/navbar/ThemeMode.vue +128 -0
- package/vue-components/v3/navbar/User.vue +154 -12
- package/vue-components/v3/sidebar/ClusterSwitcher.vue +133 -0
- package/vue-components/v3/sidebar/SidebarItemWithDropDown.vue +120 -0
- package/vue-components/v3/table/Table.vue +27 -5
- package/vue-components/v3/table/TableRow.vue +1 -1
- package/vue-components/v3/table/table-cell/CellValue.vue +26 -3
- package/vue-components/v3/table/table-cell/GenericCell.vue +62 -0
- package/vue-components/v3/table/table-cell/ObjectCell.vue +5 -1
- package/vue-components/v3/tabs/EditorTabs.vue +1 -1
|
@@ -0,0 +1,153 @@
|
|
|
1
|
+
<template>
|
|
2
|
+
<div class="ac-preview is-active is-not-fixed">
|
|
3
|
+
<div class="ac-preview-inner">
|
|
4
|
+
<!-- preview body start -->
|
|
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
|
+
>
|
|
10
|
+
<div class="ac-files">
|
|
11
|
+
<ul v-if="!isPreviewLoading">
|
|
12
|
+
<li
|
|
13
|
+
v-for="(previewYaml, idx) in filteredYamls"
|
|
14
|
+
:key="previewYaml.name + idx"
|
|
15
|
+
:class="{ 'is-active': activeKey === previewYaml.uid }"
|
|
16
|
+
>
|
|
17
|
+
<a @click.prevent="setActivePreview(previewYaml.uid)">
|
|
18
|
+
<span>
|
|
19
|
+
<img
|
|
20
|
+
src="~@appscode/design-system-images/icons/file-icon.svg"
|
|
21
|
+
alt=""
|
|
22
|
+
/>
|
|
23
|
+
</span>
|
|
24
|
+
<span>{{ previewYaml.name }}</span>
|
|
25
|
+
</a>
|
|
26
|
+
</li>
|
|
27
|
+
</ul>
|
|
28
|
+
<sidebar-loader v-else />
|
|
29
|
+
</div>
|
|
30
|
+
</div>
|
|
31
|
+
<div class="right-content">
|
|
32
|
+
<div class="right-content">
|
|
33
|
+
<resource-loader v-if="isPreviewLoading" />
|
|
34
|
+
<editor
|
|
35
|
+
v-else-if="!isPreviewLoading && !hideValue"
|
|
36
|
+
v-model="activeFile.content"
|
|
37
|
+
:original-value="activeFile.content"
|
|
38
|
+
:language="activeFile.format"
|
|
39
|
+
:read-only="isEditorReadOnly"
|
|
40
|
+
:editor-height="editorHeight"
|
|
41
|
+
:show-minimap="showMinimap"
|
|
42
|
+
/>
|
|
43
|
+
<span v-else> *************** </span>
|
|
44
|
+
</div>
|
|
45
|
+
</div>
|
|
46
|
+
</div>
|
|
47
|
+
</div>
|
|
48
|
+
</div>
|
|
49
|
+
</template>
|
|
50
|
+
<script>
|
|
51
|
+
import Preloader from "../preloader/Preloader.vue";
|
|
52
|
+
import Banner from "../banner/Banner.vue";
|
|
53
|
+
export default {
|
|
54
|
+
components: {
|
|
55
|
+
Editor: () => ({
|
|
56
|
+
component: import("./Editor.vue"),
|
|
57
|
+
loading: Preloader,
|
|
58
|
+
delay: 200,
|
|
59
|
+
error: Banner,
|
|
60
|
+
timeout: 20000
|
|
61
|
+
}),
|
|
62
|
+
ResourceLoader: () => import("./../loaders/ResourceLoader.vue"),
|
|
63
|
+
SidebarLoader: () => import("./../loaders/SidebarLoader.vue")
|
|
64
|
+
},
|
|
65
|
+
props: {
|
|
66
|
+
searchText: {
|
|
67
|
+
type: String,
|
|
68
|
+
default: ""
|
|
69
|
+
},
|
|
70
|
+
toggleHideValue: {
|
|
71
|
+
type: Boolean,
|
|
72
|
+
default: true
|
|
73
|
+
},
|
|
74
|
+
isPreviewLoading: {
|
|
75
|
+
type: Boolean,
|
|
76
|
+
default: false
|
|
77
|
+
},
|
|
78
|
+
isEditorReadOnly: {
|
|
79
|
+
type: Boolean,
|
|
80
|
+
default: false
|
|
81
|
+
},
|
|
82
|
+
previewYamls: {
|
|
83
|
+
type: Array,
|
|
84
|
+
default: () => {
|
|
85
|
+
[];
|
|
86
|
+
}
|
|
87
|
+
},
|
|
88
|
+
showMinimap: {
|
|
89
|
+
type: Boolean,
|
|
90
|
+
default: false
|
|
91
|
+
},
|
|
92
|
+
editorHeight: {
|
|
93
|
+
type: Number,
|
|
94
|
+
default: 60
|
|
95
|
+
}
|
|
96
|
+
},
|
|
97
|
+
data() {
|
|
98
|
+
return {
|
|
99
|
+
activeKey: "",
|
|
100
|
+
hideValue: ""
|
|
101
|
+
};
|
|
102
|
+
},
|
|
103
|
+
computed: {
|
|
104
|
+
activeFile() {
|
|
105
|
+
const activeFile = this.filteredYamls.find(
|
|
106
|
+
element => element.uid === this.activeKey
|
|
107
|
+
);
|
|
108
|
+
return activeFile || { content: "", format: "yaml" };
|
|
109
|
+
},
|
|
110
|
+
filteredYamls() {
|
|
111
|
+
if (this.searchText) {
|
|
112
|
+
return this.previewYamls.filter(
|
|
113
|
+
element => JSON.stringify(element).search(this.searchText) > -1
|
|
114
|
+
);
|
|
115
|
+
} else return this.previewYamls;
|
|
116
|
+
},
|
|
117
|
+
isKeyAvailable() {
|
|
118
|
+
const val = this.previewYamls.find(element => {
|
|
119
|
+
return element.uid === this.activeKey;
|
|
120
|
+
});
|
|
121
|
+
return val === undefined ? false : true;
|
|
122
|
+
}
|
|
123
|
+
},
|
|
124
|
+
methods: {
|
|
125
|
+
initActivePreview() {
|
|
126
|
+
if (!this.isKeyAvailable) {
|
|
127
|
+
this.activeKey = this.previewYamls[0].uid;
|
|
128
|
+
this.hideValue = this.activeFile.isSecret;
|
|
129
|
+
this.$emit("setActiveKey", this.activeKey);
|
|
130
|
+
}
|
|
131
|
+
},
|
|
132
|
+
setActivePreview(uid) {
|
|
133
|
+
this.activeKey = uid;
|
|
134
|
+
this.hideValue = this.activeFile.isSecret;
|
|
135
|
+
this.$emit("setActiveKey", this.activeKey);
|
|
136
|
+
}
|
|
137
|
+
},
|
|
138
|
+
watch: {
|
|
139
|
+
previewYamls: {
|
|
140
|
+
deep: true,
|
|
141
|
+
immediate: true,
|
|
142
|
+
handler(n) {
|
|
143
|
+
if (n.length) {
|
|
144
|
+
this.initActivePreview();
|
|
145
|
+
}
|
|
146
|
+
}
|
|
147
|
+
},
|
|
148
|
+
toggleHideValue(n) {
|
|
149
|
+
this.hideValue = n;
|
|
150
|
+
}
|
|
151
|
+
}
|
|
152
|
+
};
|
|
153
|
+
</script>
|
|
@@ -0,0 +1,196 @@
|
|
|
1
|
+
<template>
|
|
2
|
+
<content-table
|
|
3
|
+
:table-title="title"
|
|
4
|
+
:searchable="isSearchable"
|
|
5
|
+
:hide-header="hideHeader"
|
|
6
|
+
>
|
|
7
|
+
<template #content-controls>
|
|
8
|
+
<header-item v-if="showHideBtn">
|
|
9
|
+
<ac-button
|
|
10
|
+
modifier-classes="is-square is-primary"
|
|
11
|
+
:icon-class="toggleHideValue ? 'eye-slash' : 'eye'"
|
|
12
|
+
@click.prevent="toggleHideValue = !toggleHideValue"
|
|
13
|
+
/>
|
|
14
|
+
</header-item>
|
|
15
|
+
<header-item v-if="showCopyBtn">
|
|
16
|
+
<ac-button
|
|
17
|
+
modifier-classes="is-square is-primary"
|
|
18
|
+
icon-class="copy"
|
|
19
|
+
v-clipboard:copy="decode(activeFile)"
|
|
20
|
+
v-clipboard:success="onCopy"
|
|
21
|
+
v-clipboard:error="onError"
|
|
22
|
+
/>
|
|
23
|
+
</header-item>
|
|
24
|
+
<header-item v-if="showDownloadBtn">
|
|
25
|
+
<download-btn
|
|
26
|
+
:file-data="decode(activeFile)"
|
|
27
|
+
:file-name="activeFile.name"
|
|
28
|
+
/>
|
|
29
|
+
</header-item>
|
|
30
|
+
<header-item v-if="showUpdateBtn && !isEditorReadOnly">
|
|
31
|
+
<ac-button
|
|
32
|
+
modifier-classes="is-square is-primary"
|
|
33
|
+
icon-class="pencil-square-o"
|
|
34
|
+
:class="{ 'is-loading': isUpdateActive }"
|
|
35
|
+
@click.prevent="$emit('updateData', activeKey, activeFile)"
|
|
36
|
+
/>
|
|
37
|
+
</header-item>
|
|
38
|
+
<header-item v-if="showDeleteBtn">
|
|
39
|
+
<ac-button
|
|
40
|
+
modifier-classes="is-square is-danger"
|
|
41
|
+
icon-class="trash"
|
|
42
|
+
@click.prevent="showDeleteDataModal = true"
|
|
43
|
+
/>
|
|
44
|
+
<delete-confirmation-modal
|
|
45
|
+
title="Delete Resource"
|
|
46
|
+
message="Do you want to delete "
|
|
47
|
+
:item-name="activeFile.name"
|
|
48
|
+
:open="showDeleteDataModal"
|
|
49
|
+
:is-delete-active="deleteModalStatus === 'loading'"
|
|
50
|
+
@delete-confirmation-modal$confirm="confirmDelete"
|
|
51
|
+
@closemodal="showDeleteDataModal = false"
|
|
52
|
+
/>
|
|
53
|
+
</header-item>
|
|
54
|
+
<slot name="content-action" />
|
|
55
|
+
</template>
|
|
56
|
+
<template #content="{ searchText }">
|
|
57
|
+
<filtered-file-editor
|
|
58
|
+
:search-text="searchText"
|
|
59
|
+
:toggle-hide-value="toggleHideValue"
|
|
60
|
+
:is-preview-loading="isPreviewLoading"
|
|
61
|
+
:is-editor-read-only="isEditorReadOnly"
|
|
62
|
+
:preview-yamls="previewYamls"
|
|
63
|
+
:show-minimap="showMinimap"
|
|
64
|
+
:editor-height="editorHeight"
|
|
65
|
+
@setActiveKey="setActiveKey"
|
|
66
|
+
/>
|
|
67
|
+
</template>
|
|
68
|
+
</content-table>
|
|
69
|
+
</template>
|
|
70
|
+
<script>
|
|
71
|
+
export default {
|
|
72
|
+
components: {
|
|
73
|
+
AcButton: () => import("./../button/Button.vue"),
|
|
74
|
+
Editor: () => import("./../editor/Editor.vue"),
|
|
75
|
+
ContentTable: () => import("./../content/ContentTable.vue"),
|
|
76
|
+
HeaderItem: () => import("./../header/HeaderItem.vue"),
|
|
77
|
+
DownloadBtn: () => import("./../button/DownloadBtn.vue"),
|
|
78
|
+
DeleteConfirmationModal: () =>
|
|
79
|
+
import("./../modals/DeleteConfirmationModal.vue"),
|
|
80
|
+
FilteredFileEditor: () => import("./FilteredFileEditor.vue")
|
|
81
|
+
},
|
|
82
|
+
props: {
|
|
83
|
+
title: {
|
|
84
|
+
type: String,
|
|
85
|
+
default: "Title"
|
|
86
|
+
},
|
|
87
|
+
isSearchable: {
|
|
88
|
+
type: Boolean,
|
|
89
|
+
default: false
|
|
90
|
+
},
|
|
91
|
+
isPreviewLoading: {
|
|
92
|
+
type: Boolean,
|
|
93
|
+
default: false
|
|
94
|
+
},
|
|
95
|
+
isEditorReadOnly: {
|
|
96
|
+
type: Boolean,
|
|
97
|
+
default: false
|
|
98
|
+
},
|
|
99
|
+
previewYamls: {
|
|
100
|
+
type: Array,
|
|
101
|
+
default: () => {
|
|
102
|
+
[];
|
|
103
|
+
}
|
|
104
|
+
},
|
|
105
|
+
visibleBtn: {
|
|
106
|
+
type: Object,
|
|
107
|
+
default: () => {
|
|
108
|
+
return {};
|
|
109
|
+
}
|
|
110
|
+
},
|
|
111
|
+
showMinimap: {
|
|
112
|
+
type: Boolean,
|
|
113
|
+
default: false
|
|
114
|
+
},
|
|
115
|
+
isUpdateActive: {
|
|
116
|
+
type: Boolean,
|
|
117
|
+
default: false
|
|
118
|
+
},
|
|
119
|
+
deleteModalStatus: {
|
|
120
|
+
type: String,
|
|
121
|
+
default: "closed"
|
|
122
|
+
},
|
|
123
|
+
editorHeight: {
|
|
124
|
+
type: Number,
|
|
125
|
+
default: 60
|
|
126
|
+
},
|
|
127
|
+
hideHeader: {
|
|
128
|
+
type: Boolean,
|
|
129
|
+
default: false
|
|
130
|
+
}
|
|
131
|
+
},
|
|
132
|
+
data() {
|
|
133
|
+
return {
|
|
134
|
+
activeKey: 0,
|
|
135
|
+
toggleHideValue: "",
|
|
136
|
+
showDeleteDataModal: false
|
|
137
|
+
};
|
|
138
|
+
},
|
|
139
|
+
computed: {
|
|
140
|
+
activeFile() {
|
|
141
|
+
const activeFile = this.previewYamls.find(
|
|
142
|
+
element => element.uid === this.activeKey
|
|
143
|
+
);
|
|
144
|
+
return activeFile || { content: "", format: "yaml" };
|
|
145
|
+
},
|
|
146
|
+
showCopyBtn() {
|
|
147
|
+
if (this.visibleBtn.showCopyBtn) return true;
|
|
148
|
+
else return false;
|
|
149
|
+
},
|
|
150
|
+
showHideBtn() {
|
|
151
|
+
if (this.visibleBtn.showHideBtn) return true;
|
|
152
|
+
else return false;
|
|
153
|
+
},
|
|
154
|
+
showUpdateBtn() {
|
|
155
|
+
if (this.visibleBtn.showUpdateBtn) return true;
|
|
156
|
+
else return false;
|
|
157
|
+
},
|
|
158
|
+
showDownloadBtn() {
|
|
159
|
+
if (this.visibleBtn.showDownloadBtn) return true;
|
|
160
|
+
else return false;
|
|
161
|
+
},
|
|
162
|
+
showDeleteBtn() {
|
|
163
|
+
if (this.visibleBtn.showDeleteBtn) return true;
|
|
164
|
+
else return false;
|
|
165
|
+
}
|
|
166
|
+
},
|
|
167
|
+
methods: {
|
|
168
|
+
onCopy() {
|
|
169
|
+
this.$toasted.global.success("Value copied successfully").goAway(1000);
|
|
170
|
+
},
|
|
171
|
+
onError() {
|
|
172
|
+
this.$toasted.global.error("Copying failed").goAway(1000);
|
|
173
|
+
},
|
|
174
|
+
decode(str) {
|
|
175
|
+
if (str && this.toggleHideValue === false) return str.content;
|
|
176
|
+
else return "";
|
|
177
|
+
},
|
|
178
|
+
encode(str) {
|
|
179
|
+
if (str && this.toggleHideValue === false) return str.content;
|
|
180
|
+
else return "";
|
|
181
|
+
},
|
|
182
|
+
confirmDelete(flag) {
|
|
183
|
+
if (flag) this.$emit("deleteResource", this.activeKey);
|
|
184
|
+
},
|
|
185
|
+
setActiveKey(key) {
|
|
186
|
+
this.activeKey = key;
|
|
187
|
+
this.toggleHideValue = this.activeFile.isSecret;
|
|
188
|
+
}
|
|
189
|
+
},
|
|
190
|
+
watch: {
|
|
191
|
+
deleteModalStatus(n) {
|
|
192
|
+
if (n === "closed") this.showDeleteDataModal = false;
|
|
193
|
+
}
|
|
194
|
+
}
|
|
195
|
+
};
|
|
196
|
+
</script>
|
|
@@ -0,0 +1,90 @@
|
|
|
1
|
+
<template>
|
|
2
|
+
<div>
|
|
3
|
+
<content-loader
|
|
4
|
+
:width="100"
|
|
5
|
+
:height="40"
|
|
6
|
+
:speed="2"
|
|
7
|
+
:primaryColor="'#f5f7f9'"
|
|
8
|
+
>
|
|
9
|
+
<rect x="1" y="1" rx="1" ry="1" width="14" height="1" />
|
|
10
|
+
<rect x="17" y="1" rx="1" ry="1" width="13" height="1" />
|
|
11
|
+
<rect x="32" y="1" rx="1" ry="1" width="8" height="1" />
|
|
12
|
+
|
|
13
|
+
<rect x="7" y="3" rx="1" ry="1" width="14" height="1" />
|
|
14
|
+
<rect x="23" y="3" rx="1" ry="1" width="13" height="1" />
|
|
15
|
+
<rect x="38" y="3" rx="1" ry="1" width="8" height="1" />
|
|
16
|
+
|
|
17
|
+
<rect x="13" y="5" rx="1" ry="1" width="8" height="1" />
|
|
18
|
+
<rect x="23" y="5" rx="1" ry="1" width="15" height="1" />
|
|
19
|
+
<rect x="40" y="5" rx="1" ry="1" width="4" height="1" />
|
|
20
|
+
|
|
21
|
+
<rect x="13" y="7" rx="1" ry="1" width="10" height="1" />
|
|
22
|
+
<rect x="25" y="7" rx="1" ry="1" width="20" height="1" />
|
|
23
|
+
|
|
24
|
+
<rect x="7" y="10" rx="1" ry="1" width="14" height="1" />
|
|
25
|
+
<rect x="23" y="10" rx="1" ry="1" width="13" height="1" />
|
|
26
|
+
<rect x="38" y="10" rx="1" ry="1" width="8" height="1" />
|
|
27
|
+
|
|
28
|
+
<rect x="13" y="12" rx="1" ry="1" width="8" height="1" />
|
|
29
|
+
<rect x="23" y="12" rx="1" ry="1" width="15" height="1" />
|
|
30
|
+
<rect x="40" y="12" rx="1" ry="1" width="4" height="1" />
|
|
31
|
+
|
|
32
|
+
<rect x="13" y="14" rx="1" ry="1" width="10" height="1" />
|
|
33
|
+
<rect x="25" y="14" rx="1" ry="1" width="20" height="1" />
|
|
34
|
+
|
|
35
|
+
<rect x="7" y="17" rx="1" ry="1" width="14" height="1" />
|
|
36
|
+
<rect x="23" y="17" rx="1" ry="1" width="13" height="1" />
|
|
37
|
+
<rect x="38" y="17" rx="1" ry="1" width="8" height="1" />
|
|
38
|
+
|
|
39
|
+
<rect x="13" y="19" rx="1" ry="1" width="8" height="1" />
|
|
40
|
+
<rect x="23" y="19" rx="1" ry="1" width="15" height="1" />
|
|
41
|
+
<rect x="40" y="19" rx="1" ry="1" width="4" height="1" />
|
|
42
|
+
|
|
43
|
+
<rect x="7" y="22" rx="1" ry="1" width="14" height="1" />
|
|
44
|
+
<rect x="23" y="22" rx="1" ry="1" width="13" height="1" />
|
|
45
|
+
<rect x="38" y="22" rx="1" ry="1" width="8" height="1" />
|
|
46
|
+
|
|
47
|
+
<rect x="13" y="24" rx="1" ry="1" width="8" height="1" />
|
|
48
|
+
<rect x="23" y="24" rx="1" ry="1" width="15" height="1" />
|
|
49
|
+
<rect x="40" y="24" rx="1" ry="1" width="4" height="1" />
|
|
50
|
+
|
|
51
|
+
<rect x="1" y="26" rx="1" ry="1" width="14" height="1" />
|
|
52
|
+
<rect x="17" y="26" rx="1" ry="1" width="13" height="1" />
|
|
53
|
+
<rect x="32" y="26" rx="1" ry="1" width="8" height="1" />
|
|
54
|
+
|
|
55
|
+
<rect x="7" y="29" rx="1" ry="1" width="14" height="1" />
|
|
56
|
+
<rect x="23" y="29" rx="1" ry="1" width="13" height="1" />
|
|
57
|
+
<rect x="38" y="29" rx="1" ry="1" width="8" height="1" />
|
|
58
|
+
|
|
59
|
+
<rect x="13" y="31" rx="1" ry="1" width="8" height="1" />
|
|
60
|
+
<rect x="23" y="31" rx="1" ry="1" width="15" height="1" />
|
|
61
|
+
<rect x="40" y="31" rx="1" ry="1" width="4" height="1" />
|
|
62
|
+
|
|
63
|
+
<rect x="7" y="33" rx="1" ry="1" width="14" height="1" />
|
|
64
|
+
<rect x="23" y="33" rx="1" ry="1" width="13" height="1" />
|
|
65
|
+
<rect x="38" y="33" rx="1" ry="1" width="8" height="1" />
|
|
66
|
+
|
|
67
|
+
<rect x="13" y="35" rx="1" ry="1" width="8" height="1" />
|
|
68
|
+
<rect x="23" y="35" rx="1" ry="1" width="15" height="1" />
|
|
69
|
+
<rect x="40" y="35" rx="1" ry="1" width="4" height="1" />
|
|
70
|
+
|
|
71
|
+
<rect x="13" y="37" rx="1" ry="1" width="8" height="1" />
|
|
72
|
+
<rect x="23" y="37" rx="1" ry="1" width="15" height="1" />
|
|
73
|
+
<rect x="40" y="37" rx="1" ry="1" width="4" height="1" />
|
|
74
|
+
|
|
75
|
+
<rect x="1" y="39" rx="1" ry="1" width="14" height="1" />
|
|
76
|
+
<rect x="17" y="39" rx="1" ry="1" width="13" height="1" />
|
|
77
|
+
<rect x="32" y="39" rx="1" ry="1" width="8" height="1" />
|
|
78
|
+
</content-loader>
|
|
79
|
+
</div>
|
|
80
|
+
</template>
|
|
81
|
+
|
|
82
|
+
<script>
|
|
83
|
+
import { ContentLoader } from "vue-content-loader";
|
|
84
|
+
|
|
85
|
+
export default {
|
|
86
|
+
components: {
|
|
87
|
+
ContentLoader,
|
|
88
|
+
},
|
|
89
|
+
};
|
|
90
|
+
</script>
|
|
@@ -0,0 +1,32 @@
|
|
|
1
|
+
<template>
|
|
2
|
+
<div>
|
|
3
|
+
<content-loader
|
|
4
|
+
:width="100"
|
|
5
|
+
:height="175"
|
|
6
|
+
:speed="2"
|
|
7
|
+
:primaryColor="'#dcdee6'"
|
|
8
|
+
>
|
|
9
|
+
<rect x="2" y="1" rx="3" ry="3" width="96" height="20" />
|
|
10
|
+
<rect x="15" y="23" rx="3" ry="3" width="83" height="15" />
|
|
11
|
+
<rect x="15" y="40" rx="3" ry="3" width="83" height="15" />
|
|
12
|
+
<rect x="15" y="57" rx="3" ry="3" width="83" height="15" />
|
|
13
|
+
|
|
14
|
+
<rect x="2" y="78" rx="3" ry="3" width="96" height="20" />
|
|
15
|
+
<rect x="15" y="100" rx="3" ry="3" width="83" height="15" />
|
|
16
|
+
<rect x="15" y="117" rx="3" ry="3" width="83" height="15" />
|
|
17
|
+
<rect x="15" y="134" rx="3" ry="3" width="83" height="15" />
|
|
18
|
+
|
|
19
|
+
<rect x="2" y="155" rx="3" ry="3" width="96" height="20" />
|
|
20
|
+
</content-loader>
|
|
21
|
+
</div>
|
|
22
|
+
</template>
|
|
23
|
+
|
|
24
|
+
<script>
|
|
25
|
+
import { ContentLoader } from "vue-content-loader";
|
|
26
|
+
|
|
27
|
+
export default {
|
|
28
|
+
components: {
|
|
29
|
+
ContentLoader,
|
|
30
|
+
},
|
|
31
|
+
};
|
|
32
|
+
</script>
|
|
@@ -6,7 +6,7 @@
|
|
|
6
6
|
v-if="showModal"
|
|
7
7
|
class="ac-modal is-middle-alignment"
|
|
8
8
|
:class="modifierClasses"
|
|
9
|
-
@click.self="
|
|
9
|
+
@click.self="onModalOutsideClick"
|
|
10
10
|
>
|
|
11
11
|
<div class="ac-modal-inner">
|
|
12
12
|
<!-- modal header start -->
|
|
@@ -17,7 +17,10 @@
|
|
|
17
17
|
<header-item>
|
|
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
24
|
@click.stop="destroyModal"
|
|
22
25
|
/>
|
|
23
26
|
</header-item>
|
|
@@ -36,7 +39,12 @@
|
|
|
36
39
|
<!-- modal body end -->
|
|
37
40
|
|
|
38
41
|
<!-- modal footer start -->
|
|
39
|
-
<div
|
|
42
|
+
<div
|
|
43
|
+
class="ac-modal-footer action-footer is-flex is-align-items-center is-justify-content-space-between"
|
|
44
|
+
>
|
|
45
|
+
<div>
|
|
46
|
+
<slot name="modal-footer-left" />
|
|
47
|
+
</div>
|
|
40
48
|
<buttons class="has-text-right is-block">
|
|
41
49
|
<slot name="modal-footer-controls" />
|
|
42
50
|
</buttons>
|
|
@@ -52,28 +60,36 @@ export default {
|
|
|
52
60
|
props: {
|
|
53
61
|
open: {
|
|
54
62
|
type: Boolean,
|
|
55
|
-
default: false
|
|
63
|
+
default: false
|
|
56
64
|
},
|
|
57
65
|
title: {
|
|
58
66
|
type: String,
|
|
59
|
-
default: "Modal"
|
|
67
|
+
default: "Modal"
|
|
60
68
|
},
|
|
61
69
|
modifierClasses: {
|
|
62
70
|
type: String,
|
|
63
|
-
default: ""
|
|
71
|
+
default: ""
|
|
72
|
+
},
|
|
73
|
+
isCloseOptionDisabled: {
|
|
74
|
+
type: Boolean,
|
|
75
|
+
default: false
|
|
64
76
|
},
|
|
77
|
+
ignoreOutsideClick: {
|
|
78
|
+
type: Boolean,
|
|
79
|
+
default: false
|
|
80
|
+
}
|
|
65
81
|
},
|
|
66
82
|
|
|
67
83
|
components: {
|
|
68
84
|
HeaderItems: () => import("../header/HeaderItems.vue"),
|
|
69
85
|
HeaderItem: () => import("../header/HeaderItem.vue"),
|
|
70
86
|
Buttons: () => import("../button/Buttons.vue"),
|
|
71
|
-
AcButton: () => import("../button/Button.vue")
|
|
87
|
+
AcButton: () => import("../button/Button.vue")
|
|
72
88
|
},
|
|
73
89
|
|
|
74
90
|
data() {
|
|
75
91
|
return {
|
|
76
|
-
showModal: false
|
|
92
|
+
showModal: false
|
|
77
93
|
};
|
|
78
94
|
},
|
|
79
95
|
|
|
@@ -86,8 +102,8 @@ export default {
|
|
|
86
102
|
} else {
|
|
87
103
|
this.destroyModal();
|
|
88
104
|
}
|
|
89
|
-
}
|
|
90
|
-
}
|
|
105
|
+
}
|
|
106
|
+
}
|
|
91
107
|
},
|
|
92
108
|
|
|
93
109
|
methods: {
|
|
@@ -97,16 +113,21 @@ export default {
|
|
|
97
113
|
this.destroyModal();
|
|
98
114
|
}
|
|
99
115
|
},
|
|
116
|
+
onModalOutsideClick() {
|
|
117
|
+
if (this.ignoreOutsideClick) return;
|
|
118
|
+
this.destroyModal();
|
|
119
|
+
},
|
|
100
120
|
initializeModal() {
|
|
101
121
|
this.showModal = true;
|
|
102
122
|
document.addEventListener("keydown", this.onKeyDown);
|
|
103
123
|
},
|
|
104
124
|
destroyModal() {
|
|
125
|
+
if (this.isCloseOptionDisabled) return;
|
|
105
126
|
this.showModal = false;
|
|
106
127
|
document.removeEventListener("keydown", this.onKeyDown);
|
|
107
128
|
|
|
108
129
|
this.$emit("closemodal", true);
|
|
109
|
-
}
|
|
110
|
-
}
|
|
130
|
+
}
|
|
131
|
+
}
|
|
111
132
|
};
|
|
112
133
|
</script>
|
|
@@ -0,0 +1,77 @@
|
|
|
1
|
+
<template>
|
|
2
|
+
<!-- modal start -->
|
|
3
|
+
<modal
|
|
4
|
+
:title="title"
|
|
5
|
+
modifier-classes="is-normal"
|
|
6
|
+
:open="open"
|
|
7
|
+
@closemodal="closeModal"
|
|
8
|
+
>
|
|
9
|
+
<!-- freedom content start -->
|
|
10
|
+
<div class="action-message pt-35 pb-35 has-text-centered">
|
|
11
|
+
<h5 class="is-message">{{ message }} {{ itemName ? "" : "?" }}</h5>
|
|
12
|
+
<p class="is-description">{{ itemName }} {{ itemName ? "?" : "" }}</p>
|
|
13
|
+
</div>
|
|
14
|
+
|
|
15
|
+
<!-- freedom content end -->
|
|
16
|
+
|
|
17
|
+
<!-- modal footer start -->
|
|
18
|
+
<template #modal-footer-controls>
|
|
19
|
+
<ac-button
|
|
20
|
+
@click.stop="closeModal"
|
|
21
|
+
title="Cancel"
|
|
22
|
+
modifier-classes="is-outlined"
|
|
23
|
+
/>
|
|
24
|
+
<ac-button
|
|
25
|
+
modifier-classes="is-danger"
|
|
26
|
+
:is-loader-active="isDeleteActive"
|
|
27
|
+
title="Yes"
|
|
28
|
+
@click.stop="confirm(true)"
|
|
29
|
+
/>
|
|
30
|
+
</template>
|
|
31
|
+
</modal>
|
|
32
|
+
<!-- modal end -->
|
|
33
|
+
</template>
|
|
34
|
+
|
|
35
|
+
<script>
|
|
36
|
+
export default {
|
|
37
|
+
components: {
|
|
38
|
+
Modal: () => import("./../modal/Modal.vue"),
|
|
39
|
+
AcButton: () => import("./../button/Button.vue")
|
|
40
|
+
},
|
|
41
|
+
props: {
|
|
42
|
+
open: {
|
|
43
|
+
type: Boolean,
|
|
44
|
+
default: false
|
|
45
|
+
},
|
|
46
|
+
title: {
|
|
47
|
+
type: String,
|
|
48
|
+
default: ""
|
|
49
|
+
},
|
|
50
|
+
message: {
|
|
51
|
+
type: String,
|
|
52
|
+
default: ""
|
|
53
|
+
},
|
|
54
|
+
itemName: {
|
|
55
|
+
type: String,
|
|
56
|
+
default: ""
|
|
57
|
+
},
|
|
58
|
+
isLoading: {
|
|
59
|
+
type: Boolean,
|
|
60
|
+
default: false
|
|
61
|
+
},
|
|
62
|
+
isDeleteActive: {
|
|
63
|
+
type: Boolean,
|
|
64
|
+
default: false
|
|
65
|
+
}
|
|
66
|
+
},
|
|
67
|
+
methods: {
|
|
68
|
+
confirm(response) {
|
|
69
|
+
this.$emit("delete-confirmation-modal$confirm", response);
|
|
70
|
+
},
|
|
71
|
+
closeModal() {
|
|
72
|
+
this.confirm(false);
|
|
73
|
+
this.$emit("closemodal", true);
|
|
74
|
+
}
|
|
75
|
+
}
|
|
76
|
+
};
|
|
77
|
+
</script>
|
|
@@ -10,7 +10,9 @@
|
|
|
10
10
|
<ac-button
|
|
11
11
|
modifier-classes="is-square is-primary"
|
|
12
12
|
icon-class="copy"
|
|
13
|
-
v-clipboard:copy="
|
|
13
|
+
v-clipboard:copy="
|
|
14
|
+
`${editorTitle}: ${JSON.stringify(parsedContent, null, 4)}`
|
|
15
|
+
"
|
|
14
16
|
v-clipboard:success="onCopy"
|
|
15
17
|
v-clipboard:error="onError"
|
|
16
18
|
/>
|
|
@@ -26,6 +28,8 @@
|
|
|
26
28
|
</template>
|
|
27
29
|
|
|
28
30
|
<script>
|
|
31
|
+
import Preloader from "../preloader/Preloader.vue";
|
|
32
|
+
import Banner from "../banner/Banner.vue";
|
|
29
33
|
export default {
|
|
30
34
|
props: {
|
|
31
35
|
open: {
|
|
@@ -43,7 +47,13 @@ export default {
|
|
|
43
47
|
},
|
|
44
48
|
components: {
|
|
45
49
|
Modal: () => import("../modal/Modal.vue"),
|
|
46
|
-
Editor: () =>
|
|
50
|
+
Editor: () => ({
|
|
51
|
+
component: import("../editor/Editor.vue"),
|
|
52
|
+
loading: Preloader,
|
|
53
|
+
delay: 200,
|
|
54
|
+
error: Banner,
|
|
55
|
+
timeout: 20000,
|
|
56
|
+
}),
|
|
47
57
|
AcButton: () => import("../button/Button.vue"),
|
|
48
58
|
HeaderItem: () => import("../header/HeaderItem.vue"),
|
|
49
59
|
},
|