@appscode/design-system 1.0.3-alpha.9 → 1.0.43-alpha.14
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 +11 -4
- package/base/utilities/_derived-variables.scss +2 -2
- package/base/utilities/_initial-variables.scss +35 -22
- package/base/utilities/_mixin.scss +96 -9
- package/components/_ac-alert-box.scss +30 -2
- package/components/_ac-input.scss +70 -3
- package/components/_ac-multi-select.scss +25 -5
- package/components/_ac-table.scss +52 -17
- package/components/_ac-tags.scss +1 -1
- package/components/_breadcumb.scss +2 -2
- package/components/_buttons.scss +26 -6
- package/components/_left-sidebar-menu.scss +8 -2
- package/components/_navbar.scss +1 -1
- package/components/_pagination.scss +36 -6
- package/components/_preloader.scss +1 -1
- package/components/_wizard.scss +1 -1
- package/components/ac-toaster/_ac-toasted.scss +36 -4
- package/components/bbum/_information-center.scss +2 -2
- package/components/bbum/_user-profile.scss +1 -1
- package/components/ui-builder/_ui-builder.scss +2 -2
- package/layouts/_code-preview.scss +1 -0
- package/package.json +1 -1
- package/plugins/theme.js +138 -0
- package/plugins/vue-toaster.js +7 -6
- package/vue-components/v2/card/CardContent.vue +5 -0
- package/vue-components/v2/card/CardHeader.vue +12 -0
- package/vue-components/v2/card/OverviewCard.vue +10 -0
- package/vue-components/v2/card/OverviewCards.vue +5 -0
- package/vue-components/v2/card/PaymentCards.vue +6 -9
- package/vue-components/v2/content/ContentHeader.vue +1 -1
- package/vue-components/v2/header/Header.vue +0 -1
- package/vue-components/v2/modal/Modal.vue +2 -3
- package/vue-components/v2/modals/JsonShowModal.vue +0 -1
- package/vue-components/v2/navbar/Appdrawer.vue +8 -6
- package/vue-components/v2/pagination/Pagination.vue +8 -1
- package/vue-components/v2/sidebar/SidebarItem.vue +1 -1
- package/vue-components/v2/table/InfoTable.vue +13 -3
- package/vue-components/v2/table/Table.vue +75 -5
- package/vue-components/v3/button/Button.vue +73 -0
- package/vue-components/v3/content/ContentHeader.vue +54 -0
- package/vue-components/v3/content/ContentTable.vue +65 -0
- package/vue-components/v3/dropdown/DropdownDivider.vue +3 -0
- package/vue-components/v3/dropdown/DropdownItem.vue +5 -0
- package/vue-components/v3/dropdown/DropdownMenu.vue +111 -0
- package/vue-components/v3/editor/Editor.vue +137 -0
- package/vue-components/v3/form-fields/Input.vue +21 -0
- package/vue-components/v3/header/Header.vue +45 -0
- package/vue-components/v3/modal/Modal.vue +126 -0
- package/vue-components/v3/modals/JsonShowModal.vue +87 -0
- package/vue-components/v3/navbar/Appdrawer.vue +58 -0
- package/vue-components/v3/navbar/User.vue +64 -0
- package/vue-components/v3/pagination/Pagination.vue +159 -0
- package/vue-components/v3/searchbars/SearchBar.vue +47 -0
- package/vue-components/v3/tab/TabItem.vue +17 -0
- package/vue-components/v3/table/FakeTableCell.vue +39 -0
- package/vue-components/v3/table/InfoTable.vue +105 -0
- package/vue-components/v3/table/Table.vue +238 -0
- package/vue-components/v3/table/TableCell.vue +28 -0
- package/vue-components/v3/table/TableRow.vue +60 -0
- package/vue-components/v3/table/table-cell/ArrayCell.vue +111 -0
- package/vue-components/v3/table/table-cell/CellValue.vue +108 -0
- package/vue-components/v3/table/table-cell/ObjectCell.vue +105 -0
- package/vue-components/v3/table/table-cell/ValueWithModal.vue +43 -0
- package/vue-components/v3/tabs/EditorTabs.vue +36 -0
- package/vue-components/v3/tag/Tag.vue +17 -0
|
@@ -0,0 +1,105 @@
|
|
|
1
|
+
<template>
|
|
2
|
+
<tags v-if="printableStringObjs.length">
|
|
3
|
+
<tag
|
|
4
|
+
v-for="printableStringOb in printableStringObjs.slice(
|
|
5
|
+
0,
|
|
6
|
+
indexOfCharacterLengthExceed
|
|
7
|
+
)"
|
|
8
|
+
:key="printableStringOb.key"
|
|
9
|
+
>
|
|
10
|
+
<value-with-modal
|
|
11
|
+
v-if="printableStringOb.exceededLength"
|
|
12
|
+
:title="printableStringOb.key"
|
|
13
|
+
:value="printableStringOb.value"
|
|
14
|
+
:print="printableStringOb.print"
|
|
15
|
+
/>
|
|
16
|
+
<template v-else> {{ printableStringOb.print }} </template>
|
|
17
|
+
</tag>
|
|
18
|
+
|
|
19
|
+
<tag v-if="indexOfCharacterLengthExceed !== printableStringObjs.length">
|
|
20
|
+
<a @click.prevent.stop="showFullData = true">
|
|
21
|
+
<ellipsis-icon />
|
|
22
|
+
<json-show-modal
|
|
23
|
+
:open="showFullData"
|
|
24
|
+
@closemodal="showFullData = false"
|
|
25
|
+
:editor-title="cellTitle"
|
|
26
|
+
:editor-content="obj"
|
|
27
|
+
/>
|
|
28
|
+
</a>
|
|
29
|
+
</tag>
|
|
30
|
+
</tags>
|
|
31
|
+
<p v-else>-</p>
|
|
32
|
+
</template>
|
|
33
|
+
|
|
34
|
+
<script>
|
|
35
|
+
import { defineComponent, defineAsyncComponent } from "vue";
|
|
36
|
+
|
|
37
|
+
export default defineComponent({
|
|
38
|
+
props: {
|
|
39
|
+
cellTitle: {
|
|
40
|
+
type: String,
|
|
41
|
+
default: "Object",
|
|
42
|
+
},
|
|
43
|
+
obj: {
|
|
44
|
+
type: Object,
|
|
45
|
+
default: () => ({}),
|
|
46
|
+
},
|
|
47
|
+
maxCharacterLength: {
|
|
48
|
+
type: Number,
|
|
49
|
+
default: undefined,
|
|
50
|
+
},
|
|
51
|
+
},
|
|
52
|
+
components: {
|
|
53
|
+
Tags: defineAsyncComponent(() =>
|
|
54
|
+
import("../../../v2/tag/Tags.vue").then((module) => module.default)
|
|
55
|
+
),
|
|
56
|
+
Tag: defineAsyncComponent(() =>
|
|
57
|
+
import("../../tag/Tag.vue").then((module) => module.default)
|
|
58
|
+
),
|
|
59
|
+
EllipsisIcon: defineAsyncComponent(() =>
|
|
60
|
+
import("../../../v2/icons/Ellipsis.vue").then((module) => module.default)
|
|
61
|
+
),
|
|
62
|
+
JsonShowModal: defineAsyncComponent(() =>
|
|
63
|
+
import("../../modals/JsonShowModal.vue").then((module) => module.default)
|
|
64
|
+
),
|
|
65
|
+
ValueWithModal: defineAsyncComponent(() =>
|
|
66
|
+
import("./ValueWithModal.vue").then((module) => module.default)
|
|
67
|
+
),
|
|
68
|
+
},
|
|
69
|
+
|
|
70
|
+
data() {
|
|
71
|
+
return {
|
|
72
|
+
showFullData: false,
|
|
73
|
+
};
|
|
74
|
+
},
|
|
75
|
+
|
|
76
|
+
computed: {
|
|
77
|
+
objKeys() {
|
|
78
|
+
return Object.keys(this.obj) || [];
|
|
79
|
+
},
|
|
80
|
+
printableStringObjs() {
|
|
81
|
+
return this.objKeys.map((key) => {
|
|
82
|
+
const value = this.obj[key];
|
|
83
|
+
const keyValue = `${key}: ${value}`;
|
|
84
|
+
const exceededLength = keyValue.length > 30;
|
|
85
|
+
const print = exceededLength ? key : keyValue;
|
|
86
|
+
return { key, value, keyValue, exceededLength, print };
|
|
87
|
+
});
|
|
88
|
+
},
|
|
89
|
+
indexOfCharacterLengthExceed() {
|
|
90
|
+
let idx = -1;
|
|
91
|
+
let cumulativeLen = 0;
|
|
92
|
+
for (const [index, po] of this.printableStringObjs.entries()) {
|
|
93
|
+
const newLen = cumulativeLen + po.print.length;
|
|
94
|
+
if (newLen > this.maxCharacterLength) {
|
|
95
|
+
idx = index;
|
|
96
|
+
break;
|
|
97
|
+
}
|
|
98
|
+
cumulativeLen = newLen;
|
|
99
|
+
}
|
|
100
|
+
|
|
101
|
+
return idx === -1 ? this.printableStringObjs.length : idx;
|
|
102
|
+
},
|
|
103
|
+
},
|
|
104
|
+
});
|
|
105
|
+
</script>
|
|
@@ -0,0 +1,43 @@
|
|
|
1
|
+
<template>
|
|
2
|
+
<a @click.prevent.stop="showModal = true">
|
|
3
|
+
{{ print }}
|
|
4
|
+
|
|
5
|
+
<json-show-modal
|
|
6
|
+
:open="showModal"
|
|
7
|
+
@closemodal="showModal = false"
|
|
8
|
+
:editor-title="title"
|
|
9
|
+
:editor-content="value"
|
|
10
|
+
/>
|
|
11
|
+
</a>
|
|
12
|
+
</template>
|
|
13
|
+
|
|
14
|
+
<script>
|
|
15
|
+
import { defineComponent, defineAsyncComponent } from "vue";
|
|
16
|
+
|
|
17
|
+
export default defineComponent({
|
|
18
|
+
props: {
|
|
19
|
+
title: {
|
|
20
|
+
type: String,
|
|
21
|
+
default: "",
|
|
22
|
+
},
|
|
23
|
+
value: {
|
|
24
|
+
type: null,
|
|
25
|
+
default: "",
|
|
26
|
+
},
|
|
27
|
+
print: {
|
|
28
|
+
type: String,
|
|
29
|
+
default: "",
|
|
30
|
+
},
|
|
31
|
+
},
|
|
32
|
+
components: {
|
|
33
|
+
JsonShowModal: defineAsyncComponent(() =>
|
|
34
|
+
import("../../modals/JsonShowModal.vue").then((module) => module.default)
|
|
35
|
+
),
|
|
36
|
+
},
|
|
37
|
+
data() {
|
|
38
|
+
return {
|
|
39
|
+
showModal: false,
|
|
40
|
+
};
|
|
41
|
+
},
|
|
42
|
+
});
|
|
43
|
+
</script>
|
|
@@ -0,0 +1,36 @@
|
|
|
1
|
+
<template>
|
|
2
|
+
<tabs-body class="mt-20">
|
|
3
|
+
<tabs class="is-line">
|
|
4
|
+
<tab-item :is-active="activeTab === 'edit'">
|
|
5
|
+
<a @click.prevent="$emit('tabchange', 'edit')">Edit</a>
|
|
6
|
+
</tab-item>
|
|
7
|
+
<tab-item :is-active="activeTab === 'preview'">
|
|
8
|
+
<a @click.prevent="$emit('tabchange', 'preview')">Preview Changes</a>
|
|
9
|
+
</tab-item>
|
|
10
|
+
</tabs>
|
|
11
|
+
</tabs-body>
|
|
12
|
+
</template>
|
|
13
|
+
|
|
14
|
+
<script>
|
|
15
|
+
import { defineComponent, defineAsyncComponent } from "vue";
|
|
16
|
+
export default defineComponent({
|
|
17
|
+
props: {
|
|
18
|
+
activeTab: {
|
|
19
|
+
type: String,
|
|
20
|
+
default: "",
|
|
21
|
+
},
|
|
22
|
+
},
|
|
23
|
+
emits: ["tabchange"],
|
|
24
|
+
components: {
|
|
25
|
+
TabsBody: defineAsyncComponent(() =>
|
|
26
|
+
import("../../v2/tab/TabsBody.vue").then((module) => module.default)
|
|
27
|
+
),
|
|
28
|
+
Tabs: defineAsyncComponent(() =>
|
|
29
|
+
import("../../v2/tab/Tabs.vue").then((module) => module.default)
|
|
30
|
+
),
|
|
31
|
+
TabItem: defineAsyncComponent(() =>
|
|
32
|
+
import("../tab/TabItem.vue").then((module) => module.default)
|
|
33
|
+
),
|
|
34
|
+
},
|
|
35
|
+
});
|
|
36
|
+
</script>
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
<template>
|
|
2
|
+
<div class="tag" :class="modifierClasses">
|
|
3
|
+
<slot />
|
|
4
|
+
</div>
|
|
5
|
+
</template>
|
|
6
|
+
|
|
7
|
+
<script>
|
|
8
|
+
import { defineComponent } from "vue";
|
|
9
|
+
export default defineComponent({
|
|
10
|
+
props: {
|
|
11
|
+
modifierClasses: {
|
|
12
|
+
type: String,
|
|
13
|
+
default: "",
|
|
14
|
+
},
|
|
15
|
+
},
|
|
16
|
+
});
|
|
17
|
+
</script>
|