classcard-ui 0.2.753 → 0.2.755
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/classcard-ui.common.js +70 -59
- package/dist/classcard-ui.common.js.map +1 -1
- package/dist/classcard-ui.umd.js +70 -59
- package/dist/classcard-ui.umd.js.map +1 -1
- package/dist/classcard-ui.umd.min.js +1 -1
- package/dist/classcard-ui.umd.min.js.map +1 -1
- package/package.json +1 -1
- package/src/components/CMultiselect/CMultiselect.vue +2 -2
- package/src/components/CSelect/CSelect.vue +17 -7
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
<template>
|
|
2
2
|
<div>
|
|
3
|
-
<div class="flex w-full items-center justify-between" v-if="label">
|
|
3
|
+
<div class="mb-1 flex w-full items-center justify-between" v-if="label">
|
|
4
4
|
<div class="flex items-center">
|
|
5
5
|
<!-- label of multiselect field -->
|
|
6
6
|
<label v-if="label" class="text-sm font-medium text-gray-900">{{
|
|
@@ -12,7 +12,7 @@
|
|
|
12
12
|
<span v-if="hint" class="text-sm text-gray-500">{{ hint }}</span>
|
|
13
13
|
</div>
|
|
14
14
|
<v-select
|
|
15
|
-
class="disabled-opacity-50 disabled-pointer-events-none disabled-cursor-default
|
|
15
|
+
class="disabled-opacity-50 disabled-pointer-events-none disabled-cursor-default text-sm"
|
|
16
16
|
:placeholder="placeholder"
|
|
17
17
|
:multiple="isMultiple"
|
|
18
18
|
:taggable="isTaggable"
|
|
@@ -20,12 +20,12 @@
|
|
|
20
20
|
@click="toggleDropdown = !toggleDropdown"
|
|
21
21
|
@focus="type == 'tertiary' ? (showFocus = true) : ''"
|
|
22
22
|
@blur="close()"
|
|
23
|
-
@
|
|
23
|
+
@input="search()"
|
|
24
24
|
aria-haspopup="listbox"
|
|
25
25
|
aria-expanded="true"
|
|
26
26
|
aria-labelledby="listbox-label"
|
|
27
27
|
:class="{ ...classes, [inputClasses]: true }"
|
|
28
|
-
class="
|
|
28
|
+
class="relative w-full cursor-pointer rounded-md py-2 pl-3 pr-10 text-left text-sm focus:outline-none disabled:opacity-50 sm:text-sm"
|
|
29
29
|
:disabled="isDisabled"
|
|
30
30
|
autocomplete="off"
|
|
31
31
|
/>
|
|
@@ -72,7 +72,11 @@
|
|
|
72
72
|
v-if="type == 'tertiary' ? showFocus : true"
|
|
73
73
|
class="pointer-events-none right-0 flex items-center"
|
|
74
74
|
>
|
|
75
|
-
<c-icon
|
|
75
|
+
<c-icon
|
|
76
|
+
name="selector"
|
|
77
|
+
type="solid"
|
|
78
|
+
class="h-5 w-5 text-gray-400"
|
|
79
|
+
></c-icon>
|
|
76
80
|
</div>
|
|
77
81
|
</div>
|
|
78
82
|
</div>
|
|
@@ -92,7 +96,7 @@
|
|
|
92
96
|
tabindex="-1"
|
|
93
97
|
role="listbox"
|
|
94
98
|
aria-labelledby="listbox-label"
|
|
95
|
-
class="
|
|
99
|
+
class="max-h-60 overflow-auto rounded-md py-1 text-base ring-1 ring-gray-900 ring-opacity-5 focus:outline-none sm:text-sm"
|
|
96
100
|
>
|
|
97
101
|
<li
|
|
98
102
|
v-if="addAction"
|
|
@@ -114,7 +118,10 @@
|
|
|
114
118
|
:ref="`option-${String(index)}`"
|
|
115
119
|
@mousedown="handleSelect($event, option)"
|
|
116
120
|
class="relative cursor-pointer select-none py-2 pl-3 pr-9 text-gray-900 hover:bg-indigo-700 hover:text-white"
|
|
117
|
-
:class="[
|
|
121
|
+
:class="[
|
|
122
|
+
option.isDisabled ? 'pointer-events-none opacity-50' : '',
|
|
123
|
+
optionClasses,
|
|
124
|
+
]"
|
|
118
125
|
>
|
|
119
126
|
<span class="flex items-center">
|
|
120
127
|
<div v-if="option.showImage">
|
|
@@ -147,7 +154,9 @@
|
|
|
147
154
|
</span>
|
|
148
155
|
</span>
|
|
149
156
|
|
|
150
|
-
<span
|
|
157
|
+
<span
|
|
158
|
+
class="absolute inset-y-0 right-0 flex items-center pr-4 text-indigo-600"
|
|
159
|
+
>
|
|
151
160
|
<c-icon
|
|
152
161
|
id="list-icon"
|
|
153
162
|
v-show="showSelectedValue"
|
|
@@ -293,7 +302,8 @@ export default {
|
|
|
293
302
|
let options = [...this.options];
|
|
294
303
|
this.renderOptions = options.filter((option) => {
|
|
295
304
|
isNumber(option[this.renderOptionName])
|
|
296
|
-
? (option[this.renderOptionName] =
|
|
305
|
+
? (option[this.renderOptionName] =
|
|
306
|
+
option[this.renderOptionName].toString())
|
|
297
307
|
: "";
|
|
298
308
|
return option[this.renderOptionName]
|
|
299
309
|
.toLowerCase()
|