nuxt-glorious 1.2.9-6 → 1.2.9-8

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/dist/module.json CHANGED
@@ -1,5 +1,5 @@
1
1
  {
2
2
  "name": "nuxt-glorious",
3
3
  "configKey": "glorious",
4
- "version": "1.2.9-6"
4
+ "version": "1.2.9-8"
5
5
  }
@@ -29,7 +29,7 @@ const props: any = defineProps(_props)
29
29
  :to="props.to"
30
30
  :class="[
31
31
  `glorious-button`,
32
- `color-${props.color}`,
32
+ `button-color-${props.color}`,
33
33
  `size-${props.size}`,
34
34
  props.outline ? 'outline' : '',
35
35
  ]"
@@ -23,6 +23,7 @@ watch(
23
23
 
24
24
  modelValue.value = null
25
25
  selectValue.value = null
26
+ const firstVal = selectValue.value
26
27
  </script>
27
28
 
28
29
  <template>
@@ -31,6 +32,7 @@ selectValue.value = null
31
32
  {{ props.title }}
32
33
  </span>
33
34
  <div class="grow flex relative">
35
+ {{ selectValue }}
34
36
  <select
35
37
  v-model="selectValue"
36
38
  aria-label="glorious select"
@@ -38,6 +40,16 @@ selectValue.value = null
38
40
  class="grow glorious-select"
39
41
  :class="[`color-${props.color}`, props.size]"
40
42
  >
43
+ <option
44
+ :selected="
45
+ selectValue === null ||
46
+ selectValue === '' ||
47
+ typeof selectValue === 'undefined'
48
+ "
49
+ :value="firstVal"
50
+ >
51
+ {{ props.placeholder }}
52
+ </option>
41
53
  <option
42
54
  v-for="(item, index) in props.options"
43
55
  :key="index"
@@ -46,16 +58,6 @@ selectValue.value = null
46
58
  {{ item[props.displayTextKey] }}
47
59
  </option>
48
60
  </select>
49
- <span
50
- v-if="
51
- selectValue === null ||
52
- selectValue === '' ||
53
- typeof selectValue === 'undefined'
54
- "
55
- class="absolute top-0 bottom-0 my-auto px-3 h-max text-gray-500"
56
- >
57
- {{ props.placeholder }}
58
- </span>
59
61
  </div>
60
62
  <GErrorText :error="props.error" />
61
63
  </div>
@@ -27,87 +27,87 @@ button:focus-visible {
27
27
  @apply py-0.5;
28
28
  }
29
29
 
30
- .color-orange {
30
+ .button-color-orange {
31
31
  @apply bg-orange-600 border-orange-700 hover:bg-orange-700;
32
32
  }
33
- .color-orange.outline {
33
+ .button-color-orange.outline {
34
34
  @apply bg-transparent border outline-none;
35
35
  @apply text-orange-500 hover:bg-orange-100;
36
36
  }
37
- .color-orange.outline div.loading > div > div {
37
+ .button-color-orange.outline div.loading > div > div {
38
38
  border-color: theme("colors.orange.700") !important;
39
39
  }
40
- .color-orange:disabled {
40
+ .button-color-orange:disabled {
41
41
  @apply cursor-not-allowed;
42
42
  }
43
- .color-orange:disabled:not(:disabled) {
43
+ .button-color-orange:disabled:not(:disabled) {
44
44
  @apply bg-orange-300;
45
45
  }
46
46
 
47
- .color-blue {
47
+ .button-color-blue {
48
48
  @apply bg-blue-600 border-blue-700 hover:bg-blue-700;
49
49
  }
50
- .color-blue.outline {
50
+ .button-color-blue.outline {
51
51
  @apply bg-transparent border outline-none;
52
52
  @apply text-blue-500 hover:bg-blue-100;
53
53
  }
54
- .color-blue.outline div.loading > div > div {
54
+ .button-color-blue.outline div.loading > div > div {
55
55
  border-color: theme("colors.blue.700") !important;
56
56
  }
57
- .color-blue:disabled {
57
+ .button-color-blue:disabled {
58
58
  @apply cursor-not-allowed;
59
59
  }
60
- .color-blue:disabled:not(:disabled) {
60
+ .button-color-blue:disabled:not(:disabled) {
61
61
  @apply bg-blue-300;
62
62
  }
63
63
 
64
- .color-gray {
64
+ .button-color-gray {
65
65
  @apply bg-gray-600 border-gray-700 hover:bg-gray-700;
66
66
  }
67
- .color-gray.outline {
67
+ .button-color-gray.outline {
68
68
  @apply bg-transparent border outline-none;
69
69
  @apply text-gray-500 hover:bg-gray-100;
70
70
  }
71
- .color-gray.outline div.loading > div > div {
71
+ .button-color-gray.outline div.loading > div > div {
72
72
  border-color: theme("colors.gray.700") !important;
73
73
  }
74
- .color-gray:disabled {
74
+ .button-color-gray:disabled {
75
75
  @apply cursor-not-allowed;
76
76
  }
77
- .color-gray:disabled:not(:disabled) {
77
+ .button-color-gray:disabled:not(:disabled) {
78
78
  @apply bg-gray-300;
79
79
  }
80
80
 
81
- .color-red {
81
+ .button-color-red {
82
82
  @apply bg-red-600 border-red-700 hover:bg-red-700;
83
83
  }
84
- .color-red.outline {
84
+ .button-color-red.outline {
85
85
  @apply bg-transparent border outline-none;
86
86
  @apply text-red-500 hover:bg-red-100;
87
87
  }
88
- .color-red.outline div.loading > div > div {
88
+ .button-color-red.outline div.loading > div > div {
89
89
  border-color: theme("colors.red.700") !important;
90
90
  }
91
- .color-red:disabled {
91
+ .button-color-red:disabled {
92
92
  @apply cursor-not-allowed;
93
93
  }
94
- .color-red:disabled:not(:disabled) {
94
+ .button-color-red:disabled:not(:disabled) {
95
95
  @apply bg-red-300;
96
96
  }
97
97
 
98
- .color-green {
98
+ .button-color-green {
99
99
  @apply bg-green-600 border-green-700 hover:bg-green-700;
100
100
  }
101
- .color-green.outline {
101
+ .button-color-green.outline {
102
102
  @apply bg-transparent border outline-none;
103
103
  @apply text-green-500 hover:bg-green-100;
104
104
  }
105
- .color-green.outline div.loading > div > div {
105
+ .button-color-green.outline div.loading > div > div {
106
106
  border-color: theme("colors.green.700") !important;
107
107
  }
108
- .color-green:disabled {
108
+ .button-color-green:disabled {
109
109
  @apply cursor-not-allowed;
110
110
  }
111
- .color-green:disabled:not(:disabled) {
111
+ .button-color-green:disabled:not(:disabled) {
112
112
  @apply bg-green-300;
113
113
  }
@@ -11,7 +11,7 @@ button:focus-visible {
11
11
  @include mixin.load-size();
12
12
  }
13
13
  @each $color in var.$colors {
14
- .#{'color-' + $color} {
14
+ .#{'button-color-' + $color} {
15
15
  @apply #{"bg-" + ($color) + "-600 border-" + $color + "-700 hover:bg-" + $color + "-700"};
16
16
 
17
17
  &.outline {
package/package.json CHANGED
@@ -1,5 +1,5 @@
1
1
  {
2
- "version": "1.2.9-6",
2
+ "version": "1.2.9-8",
3
3
  "name": "nuxt-glorious",
4
4
  "description": "This package provides many things needed by a project, including server requests and authentication, SEO and other requirements of a project.",
5
5
  "repository": "sajadhzj/nuxt-glorious",