@appscode/design-system 2.0.61 → 2.0.63

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 CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@appscode/design-system",
3
- "version": "2.0.61",
3
+ "version": "2.0.63",
4
4
  "description": "A design system for Appscode websites and dashboards made using Bulma",
5
5
  "main": "main.scss",
6
6
  "scripts": {
@@ -1,27 +1,4 @@
1
1
  .ac-accordion-wrapper {
2
- &.is-marginless {
3
- .single-accordion-item {
4
- margin: 0;
5
- padding: 0;
6
-
7
- .accordion-heading {
8
- padding: 10px 20px;
9
- position: relative;
10
- z-index: 1;
11
-
12
- &::after {
13
- position: absolute;
14
- content: "";
15
- left: 0;
16
- top: 0;
17
- width: 4px;
18
- height: 100%;
19
- background-color: $ac-primary;
20
- }
21
- }
22
- }
23
- }
24
-
25
2
  .single-accordion-item {
26
3
  background-color: $white-100;
27
4
  padding: 15px 20px;
@@ -69,7 +46,6 @@
69
46
 
70
47
  .accordion-body {
71
48
  max-height: 0;
72
- // transition: max-height 0.2s ease-out;
73
49
  overflow: hidden;
74
50
 
75
51
  p {
@@ -92,26 +68,3 @@
92
68
  }
93
69
  }
94
70
  }
95
-
96
- /****************************************
97
- Responsive Classes
98
- *****************************************/
99
- // Extra small devices (portrait phones, less than 576px)
100
- @media (max-width: 575.98px) {
101
- }
102
-
103
- // Small devices (landscape phones, 576px and up)
104
- @media (min-width: 576px) and (max-width: 767.98px) {
105
- }
106
-
107
- // Medium devices (tablets, 768px and up)
108
- @media (min-width: 768px) and (max-width: 991.98px) {
109
- }
110
-
111
- // Large devices (desktops, 992px and up)
112
- @media (min-width: 992px) and (max-width: 1199.98px) {
113
- }
114
-
115
- // Extra large devices (large desktops, 1200px and up)
116
- @media (min-width: 1200px) {
117
- }
@@ -0,0 +1,37 @@
1
+ .avatar {
2
+ position: relative;
3
+ z-index: 1;
4
+
5
+ .dots {
6
+ position: absolute;
7
+ right: calc(5% - 6px);
8
+ top: calc(30% - 6px);
9
+ width: 12px;
10
+ height: 12px;
11
+ background-color: $info;
12
+ border-radius: 50%;
13
+ border: 2px solid $white-100;
14
+ box-shadow: 2px 2px 2px rgba(5, 5, 5, 0.16);
15
+ z-index: 2;
16
+ &.is-not-active {
17
+ background-color: $gray-60;
18
+ }
19
+ }
20
+ .is-initial {
21
+ position: relative;
22
+ z-index: 1;
23
+ background-color: $gray-90;
24
+ height: 100%;
25
+ width: 100%;
26
+ display: flex;
27
+ align-items: center;
28
+ justify-content: center;
29
+ font-size: 16px;
30
+ font-weight: 500;
31
+ color: $color-heading;
32
+ border: 1px solid $color-border;
33
+ &.is-rounded {
34
+ border-radius: 50%;
35
+ }
36
+ }
37
+ }
@@ -1,6 +1,31 @@
1
1
  // INFO TABLE END
2
-
3
2
  // GENERAL TABLE START
3
+
4
+ .table-container {
5
+ &.ac-table-container {
6
+ &::-webkit-scrollbar {
7
+ height: 7px;
8
+ }
9
+
10
+ /* Track */
11
+ &::-webkit-scrollbar-track {
12
+ background-color: #d1d4de;
13
+ border-radius: 10px;
14
+ }
15
+
16
+ /* Handle */
17
+ &::-webkit-scrollbar-thumb {
18
+ background-color: $gray-70;
19
+ border-radius: 10px;
20
+ }
21
+
22
+ /* Handle on hover */
23
+ &::-webkit-scrollbar-thumb:hover {
24
+ background-color: $gray-60;
25
+ }
26
+ }
27
+ }
28
+
4
29
  .table.ac-table {
5
30
  background-color: transparent;
6
31
  margin-bottom: 0;
@@ -0,0 +1,23 @@
1
+ .is-checkradio.is-primary[type="checkbox"].is-primary:checked.has-background-color + label::before,
2
+ .is-checkradio.is-primary[type="checkbox"].is-primary:checked.has-background-color + label:before,
3
+ .is-checkradio.is-primary[type="checkbox"].is-primary:checked.has-background-color + label::after,
4
+ .is-checkradio.is-primary[type="checkbox"].is-primary:checked.has-background-color + label:after {
5
+ background-color: $ac-primary !important;
6
+ }
7
+
8
+ .is-checkradio.is-primary[type="radio"] + label::after,
9
+ .is-checkradio.is-primary[type="radio"] + label:after {
10
+ background: $ac-primary !important;
11
+ }
12
+ .is-checkradio.is-primary[type="checkbox"]:checked + label::before,
13
+ .is-checkradio.is-primary[type="checkbox"]:checked + label:before,
14
+ .is-checkradio.is-primary[type="radio"]:checked + label::before,
15
+ .is-checkradio.is-primary[type="radio"]:checked + label:before {
16
+ border-color: $ac-primary;
17
+ }
18
+
19
+ .is-checkradio[type="radio"].is-primary:checked + label::after,
20
+ .is-checkradio[type="radio"].is-primary:checked + label:after {
21
+ background-color: $ac-primary !important;
22
+ border-color: $ac-primary;
23
+ }
@@ -3,6 +3,19 @@
3
3
  z-index: 1;
4
4
  margin-bottom: 16px;
5
5
 
6
+ .prepend {
7
+ position: absolute;
8
+ left: 1px;
9
+ top: 1px;
10
+ width: 32px;
11
+ height: 34px;
12
+ display: flex;
13
+ align-items: center;
14
+ border-radius: 4px 0 0 4px;
15
+ justify-content: center;
16
+ border-right: 1px solid $color-border-dark;
17
+ background-color: $white-100;
18
+ }
6
19
  &.is-disable {
7
20
  opacity: 0.5;
8
21
 
@@ -497,35 +510,35 @@
497
510
  }
498
511
  }
499
512
 
500
- .is-checkradio[type="radio"] + label::after,
501
- .is-checkradio[type="radio"] + label:after {
502
- background: $ac-primary;
503
- }
504
-
505
- .is-checkradio[type="checkbox"]:checked + label::before,
506
- .is-checkradio[type="checkbox"]:checked + label:before,
507
- .is-checkradio[type="radio"]:checked + label::before,
508
- .is-checkradio[type="radio"]:checked + label:before {
509
- border: 0.2rem solid $ac-primary;
510
- }
511
-
512
- .is-checkradio[type="checkbox"]:hover:not([disabled]) + label::before,
513
- .is-checkradio[type="checkbox"]:hover:not([disabled]) + label:before,
514
- .is-checkradio[type="radio"]:hover:not([disabled]) + label::before,
515
- .is-checkradio[type="radio"]:hover:not([disabled]) + label:before {
516
- border-color: $primary-30 !important;
517
- }
518
-
519
- .switch[type="checkbox"].is-primary:checked + label::before,
520
- .switch[type="checkbox"].is-primary:checked + label:before {
521
- background-color: $ac-primary;
522
- }
523
-
524
- .is-checkradio[type="checkbox"] + label::after,
525
- .is-checkradio[type="checkbox"] + label:after {
526
- border-width: 0.2rem;
527
- border-color: $ac-primary;
528
- }
513
+ // .is-checkradio[type="radio"] + label::after,
514
+ // .is-checkradio[type="radio"] + label:after {
515
+ // background: $ac-primary;
516
+ // }
517
+
518
+ // .is-checkradio[type="checkbox"]:checked + label::before,
519
+ // .is-checkradio[type="checkbox"]:checked + label:before,
520
+ // .is-checkradio[type="radio"]:checked + label::before,
521
+ // .is-checkradio[type="radio"]:checked + label:before {
522
+ // border: 0.2rem solid $ac-primary;
523
+ // }
524
+
525
+ // .is-checkradio[type="checkbox"]:hover:not([disabled]) + label::before,
526
+ // .is-checkradio[type="checkbox"]:hover:not([disabled]) + label:before,
527
+ // .is-checkradio[type="radio"]:hover:not([disabled]) + label::before,
528
+ // .is-checkradio[type="radio"]:hover:not([disabled]) + label:before {
529
+ // border-color: $primary-30 !important;
530
+ // }
531
+
532
+ // .switch[type="checkbox"].is-primary:checked + label::before,
533
+ // .switch[type="checkbox"].is-primary:checked + label:before {
534
+ // background-color: $ac-primary;
535
+ // }
536
+
537
+ // .is-checkradio[type="checkbox"] + label::after,
538
+ // .is-checkradio[type="checkbox"] + label:after {
539
+ // border-width: 0.2rem;
540
+ // border-color: $ac-primary;
541
+ // }
529
542
 
530
543
  // file upload
531
544
  .file.ac-file {
@@ -13,8 +13,19 @@ withDefaults(defineProps<Props>(), {
13
13
  <div class="toast-header is-flex is-align-items-center">
14
14
  <h6 class="mr-auto">Toast Header</h6>
15
15
  <small>2 hours ago</small>
16
- <button type="button" class="button ac-button is-danger is-outlined w-18 h-18 flex ml-8">
17
- <span class="material-icons close-icon">close</span>
16
+ <button type="button" class="button ac-button is-white ml-8">
17
+ <span class="icon">
18
+ <svg
19
+ xmlns="http://www.w3.org/2000/svg"
20
+ fill="none"
21
+ viewBox="0 0 24 24"
22
+ stroke-width="1.5"
23
+ stroke="currentColor"
24
+ class="w-6 h-6"
25
+ >
26
+ <path stroke-linecap="round" stroke-linejoin="round" d="M6 18 18 6M6 6l12 12" />
27
+ </svg>
28
+ </span>
18
29
  </button>
19
30
  </div>
20
31
  <div class="toast-body">
@@ -0,0 +1,32 @@
1
+ <script setup lang="ts">
2
+ interface Props {
3
+ size?: string;
4
+ imgUrl?: string;
5
+ rounded?: boolean;
6
+ roundedClass?: string;
7
+ dots?: boolean;
8
+ isInitial?: boolean;
9
+ dotBgColor?: string;
10
+ }
11
+
12
+ withDefaults(defineProps<Props>(), {
13
+ size: "32x32",
14
+ imgUrl: "https://bulma.io/images/placeholders/32x32.png",
15
+ rounded: false,
16
+ roundedClass: "",
17
+ dots: false,
18
+ isInitial: false,
19
+ dotBgColor: "",
20
+ });
21
+ </script>
22
+
23
+ <template>
24
+ <figure class="avatar image" :class="`is-${size}`">
25
+ <span v-if="dots" class="dots" :class="dotBgColor"></span>
26
+ <div v-if="isInitial" class="is-initial" :class="[rounded ? 'is-rounded' : '', roundedClass]">jd</div>
27
+ <img v-else :class="[rounded ? 'is-rounded' : '', roundedClass]" :src="imgUrl" alt="avatar-image" />
28
+ </figure>
29
+ </template>
30
+ <style lang="scss">
31
+ @import "../../../vue-components/styles/components/_avatar.scss";
32
+ </style>
@@ -14,8 +14,8 @@ interface Props {
14
14
 
15
15
  withDefaults(defineProps<Props>(), {
16
16
  clusterData: () => ({
17
- name: "",
18
- providerIcon: "",
17
+ name: "Cluster Name",
18
+ providerIcon: "https://via.placeholder.com/100/dddddd/808080",
19
19
  tags: [],
20
20
  details: [],
21
21
  }),
@@ -34,7 +34,7 @@ const OptionDots = defineAsyncComponent(() => import("../option-dots/Options.vue
34
34
  <div class="card-details-inner" :class="modifierClasses">
35
35
  <div class="c-header">
36
36
  <div class="c-logo">
37
- <img :src="clusterData.providerIcon" alt="" />
37
+ <img :src="clusterData.providerIcon" :alt="clusterData.name" />
38
38
  </div>
39
39
  <div class="c-content">
40
40
  <div class="is-flex is-justify-content-space-between pr-32">
@@ -1,6 +1,22 @@
1
- <script setup lang="ts"></script>
1
+ <script setup lang="ts">
2
+ interface Props {
3
+ modifierClasses?: string;
4
+ cardNumber?: number;
5
+ expire?: string;
6
+ name?: string;
7
+ cardType?: string;
8
+ }
9
+
10
+ withDefaults(defineProps<Props>(), {
11
+ modifierClasses: "",
12
+ cardNumber: 2296,
13
+ expire: "12/23",
14
+ name: "John Smith",
15
+ cardType: "VISA",
16
+ });
17
+ </script>
2
18
  <template>
3
- <div class="ac-payment-card-wrapper">
19
+ <div class="ac-payment-card-wrapper" :class="modifierClasses">
4
20
  <!-- single card start -->
5
21
  <div class="ac-payment-card payment-bg-2">
6
22
  <div class="payment-card-inner">
@@ -36,7 +52,7 @@
36
52
  <p class="p-card-number is-star">****</p>
37
53
  <p class="p-card-number is-star">****</p>
38
54
  <p class="p-card-number is-star">****</p>
39
- <p class="p-card-number">2296</p>
55
+ <p class="p-card-number">{{ cardNumber }}</p>
40
56
  </div>
41
57
  <!-- card body end -->
42
58
  <!-- card footer start -->
@@ -45,10 +61,14 @@
45
61
  <div class="p-card-expiry">
46
62
  <p>Expiry Date <span>12/20</span></p>
47
63
  </div>
48
- <p class="user-name">John Smith</p>
64
+ <p class="user-name">{{ name }}</p>
49
65
  </div>
50
66
  <div class="p-card-logo">
51
- <img src="https://bb-developer-v1.web.app/_nuxt/img/visa-card-logo.6a56d8c.svg" alt="visa-card" />
67
+ <img
68
+ v-if="cardType === 'VISA'"
69
+ src="https://bb-developer-v1.web.app/_nuxt/img/visa-card-logo.6a56d8c.svg"
70
+ alt="visa-card"
71
+ />
52
72
  </div>
53
73
  </div>
54
74
  <!-- card footer end -->
@@ -0,0 +1,45 @@
1
+ <script setup lang="ts">
2
+ interface Props {
3
+ modifierClasses?: string;
4
+ label?: boolean;
5
+ horizontal?: boolean;
6
+ }
7
+
8
+ withDefaults(defineProps<Props>(), {
9
+ modifierClasses: "",
10
+ label: false,
11
+ horizontal: false,
12
+ });
13
+ </script>
14
+
15
+ <template>
16
+ <div class="divider" :class="[horizontal ? 'is-horizontal' : '', modifierClasses]">
17
+ <span v-if="label">OR</span>
18
+ </div>
19
+ </template>
20
+ <style lang="scss">
21
+ .divider {
22
+ height: 1px;
23
+ width: 100%;
24
+ background-color: $color-border;
25
+ margin: 16px 0;
26
+ position: relative;
27
+ &.is-horizontal {
28
+ width: 1px;
29
+ min-height: 32px;
30
+ margin: 0 16px;
31
+ span {
32
+ top: 50%;
33
+ margin-top: -8px;
34
+ }
35
+ }
36
+ span {
37
+ position: absolute;
38
+ right: 50%;
39
+ margin-right: -16px;
40
+ background: $white-100;
41
+ top: -10px;
42
+ padding-inline: 8px;
43
+ }
44
+ }
45
+ </style>
@@ -0,0 +1,35 @@
1
+ <script setup lang="ts">
2
+ interface Props {
3
+ modifierClasses?: string;
4
+ name: string;
5
+ label?: string;
6
+ type?: string;
7
+ check?: boolean;
8
+ }
9
+
10
+ withDefaults(defineProps<Props>(), {
11
+ modifierClasses: "",
12
+ name: "checkbox",
13
+ label: "Check Radio",
14
+ type: "checkbox",
15
+ check: false,
16
+ });
17
+ </script>
18
+
19
+ <template>
20
+ <div class="field">
21
+ <input
22
+ class="is-checkradio"
23
+ :class="[type === 'checkbox' ? 'has-background-color' : '', modifierClasses]"
24
+ :id="name"
25
+ :type="type"
26
+ :name="name"
27
+ :checked="check"
28
+ />
29
+ <label :for="name">{{ label }}</label>
30
+ </div>
31
+ </template>
32
+
33
+ <style lang="scss">
34
+ @import "../../../vue-components/styles/components/form-fields/_check-radio.scss";
35
+ </style>
@@ -0,0 +1,75 @@
1
+ <script setup lang="ts">
2
+ interface Props {
3
+ modifierClasses?: string;
4
+ name: string;
5
+ label?: string;
6
+ type?: string;
7
+ check?: boolean;
8
+ }
9
+
10
+ withDefaults(defineProps<Props>(), {
11
+ modifierClasses: "",
12
+ name: "switch",
13
+ label: "Switch Label",
14
+ type: "checkbox",
15
+ check: false,
16
+ });
17
+ </script>
18
+
19
+ <template>
20
+ <div class="field">
21
+ <input
22
+ :id="name"
23
+ type="checkbox"
24
+ :name="name"
25
+ class="switch is-rounded"
26
+ :class="modifierClasses"
27
+ :checked="check"
28
+ />
29
+ <label :for="name">{{ label }}</label>
30
+ </div>
31
+ <!--
32
+ <div class="field">
33
+ <input
34
+ id="switchRoundedSuccess"
35
+ type="checkbox"
36
+ name="switchRoundedSuccess"
37
+ class="switch is-rounded is-success"
38
+ checked="checked"
39
+ />
40
+ <label for="switchRoundedSuccess">Switch rounded success</label>
41
+ </div>
42
+
43
+ <div class="field">
44
+ <input
45
+ id="switchRoundedWarning"
46
+ type="checkbox"
47
+ name="switchRoundedWarning"
48
+ class="switch is-rounded is-warning"
49
+ checked="checked"
50
+ />
51
+ <label for="switchRoundedWarning">Switch rounded warning</label>
52
+ </div>
53
+
54
+ <div class="field">
55
+ <input
56
+ id="switchRoundedDanger"
57
+ type="checkbox"
58
+ name="switchRoundedDanger"
59
+ class="switch is-rounded is-danger"
60
+ checked="checked"
61
+ />
62
+ <label for="switchRoundedDanger">Switch rounded danger</label>
63
+ </div>
64
+
65
+ <div class="field">
66
+ <input
67
+ id="switchRoundedInfo"
68
+ type="checkbox"
69
+ name="switchRoundedInfo"
70
+ class="switch is-rounded is-info"
71
+ checked="checked"
72
+ />
73
+ <label for="switchRoundedInfo">Switch rounded info</label>
74
+ </div> -->
75
+ </template>
@@ -0,0 +1,47 @@
1
+ <script setup lang="ts">
2
+ interface Props {
3
+ modifierClasses?: string;
4
+ height?: string;
5
+ width?: string;
6
+ rounded?: boolean;
7
+ }
8
+
9
+ withDefaults(defineProps<Props>(), {
10
+ modifierClasses: "",
11
+ height: "16px",
12
+ width: "100%",
13
+ rounded: false,
14
+ });
15
+ </script>
16
+
17
+ <template>
18
+ <div class="skeleton" :class="[rounded ? 'is-rounded' : '', modifierClasses]"></div>
19
+ </template>
20
+
21
+ <style lang="scss">
22
+ .skeletons {
23
+ display: flex;
24
+ flex-direction: column;
25
+ gap: 8px;
26
+ }
27
+ .skeleton {
28
+ background: linear-gradient(90deg, $secondary-95 25%, $secondary-90 50%, $secondary-95 75%);
29
+ background-size: 200% 100%;
30
+ animation: loading 2s infinite ease-in-out;
31
+ border-radius: 4px;
32
+ display: flex;
33
+ height: v-bind(height);
34
+ width: v-bind(width);
35
+ &.is-rounded {
36
+ border-radius: 50%;
37
+ }
38
+ }
39
+ @keyframes loading {
40
+ 0% {
41
+ background-position: 200% 0;
42
+ }
43
+ 100% {
44
+ background-position: -200% 0;
45
+ }
46
+ }
47
+ </style>
@@ -0,0 +1,15 @@
1
+ <script setup lang="ts">
2
+ interface Props {
3
+ modifierClasses?: string;
4
+ }
5
+
6
+ withDefaults(defineProps<Props>(), {
7
+ modifierClasses: "",
8
+ });
9
+ </script>
10
+
11
+ <template>
12
+ <div class="skeletons" :class="modifierClasses">
13
+ <slot></slot>
14
+ </div>
15
+ </template>
@@ -1,5 +1,15 @@
1
+ <script setup lang="ts">
2
+ interface Props {
3
+ modifierClasses?: string;
4
+ }
5
+
6
+ withDefaults(defineProps<Props>(), {
7
+ modifierClasses: "",
8
+ });
9
+ </script>
10
+
1
11
  <template>
2
- <div class="colored-steps">
12
+ <div class="colored-steps" :class="modifierClasses">
3
13
  <ol class="steps">
4
14
  <li class="step">
5
15
  <div class="step-header bg-primary"></div>
@@ -24,30 +24,3 @@ onMounted(() => {
24
24
  <slot />
25
25
  </div>
26
26
  </template>
27
-
28
- <style lang="scss">
29
- .table-container {
30
- &.ac-table-container {
31
- &::-webkit-scrollbar {
32
- height: 7px;
33
- }
34
-
35
- /* Track */
36
- &::-webkit-scrollbar-track {
37
- background-color: #d1d4de;
38
- border-radius: 10px;
39
- }
40
-
41
- /* Handle */
42
- &::-webkit-scrollbar-thumb {
43
- background-color: $primary-95;
44
- border-radius: 10px;
45
- }
46
-
47
- /* Handle on hover */
48
- &::-webkit-scrollbar-thumb:hover {
49
- background-color: $primary-95;
50
- }
51
- }
52
- }
53
- </style>