@appscode/design-system 2.17.22 → 2.17.23

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.17.22",
3
+ "version": "2.17.23",
4
4
  "description": "A design system for Appscode websites and dashboards made using Bulma",
5
5
  "main": "main.scss",
6
6
  "scripts": {
@@ -16,6 +16,7 @@ interface prop {
16
16
  isLoading?: boolean;
17
17
  optionType?: "simple" | "custom";
18
18
  placeholderText?: string;
19
+ isrequired?: boolean;
19
20
  }
20
21
 
21
22
  const props = withDefaults(defineProps<prop>(), {
@@ -24,6 +25,7 @@ const props = withDefaults(defineProps<prop>(), {
24
25
  isLoading: false,
25
26
  optionType: "simple",
26
27
  placeholderText: "Select Option",
28
+ isrequired: false,
27
29
  });
28
30
 
29
31
  const emit = defineEmits(["select", "remove", "onRefreshClick"]);
@@ -87,10 +89,17 @@ watch(isOpen, (n) => {
87
89
  ref="selectBox"
88
90
  class="ac-single-input is-small is-selectbox"
89
91
  :class="{ 'is-open': isOpen, 'is-disabled': isLoading }"
92
+ data-testid="simple-select-box"
90
93
  :style="[isOpen ? { 'z-index': 2 } : '']"
91
94
  >
92
- <label for="custom-select" class="ac-label" :class="{ 'show-label': labelHoisted || isOpen }" @click="selectClick">
95
+ <label
96
+ for="custom-select"
97
+ class="ac-label"
98
+ :class="{ 'is-required': isrequired, 'show-label': labelHoisted || isOpen }"
99
+ @click="selectClick"
100
+ >
93
101
  {{ placeholderText }}
102
+ <span v-if="isrequired" class="is-required"> * </span>
94
103
  </label>
95
104
 
96
105
  <input
@@ -41,7 +41,13 @@ function handleBack() {
41
41
  :class="{ 'mb-8': resetStyle }"
42
42
  >
43
43
  <header-items>
44
- <button v-if="hasBackButton" title="Back" class="ac-back-button" @click="handleBack">
44
+ <button
45
+ v-if="hasBackButton"
46
+ title="Back"
47
+ class="ac-back-button"
48
+ data-testid="back-button"
49
+ @click="handleBack"
50
+ >
45
51
  <ArrowUturnLeft />
46
52
  </button>
47
53
  <header-item>