classcard-ui 0.2.648 → 0.2.649

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": "classcard-ui",
3
- "version": "0.2.648",
3
+ "version": "0.2.649",
4
4
  "main": "dist/classcard-ui.umd.min.js",
5
5
  "scripts": {
6
6
  "serve": "vue-cli-service serve",
@@ -12,68 +12,72 @@
12
12
  <span v-if="hint" class="text-sm text-gray-500">{{ hint }}</span>
13
13
  </div>
14
14
 
15
- <div class="relative" :class="label ? 'mt-1' : ''">
16
- <input
17
- type="text"
18
- v-model="selectSearch"
19
- @click="toggleDropdown = !toggleDropdown"
20
- @focus="type == 'tertiary' ? (showFocus = true) : ''"
21
- @blur="close()"
22
- @keyup="search()"
23
- aria-haspopup="listbox"
24
- aria-expanded="true"
25
- aria-labelledby="listbox-label"
26
- :class="{ ...classes, [inputClasses]: true }"
27
- 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"
28
- :disabled="isDisabled"
29
- autocomplete="off"
30
- />
15
+ <div class="relative">
16
+ <div class="relative truncate" :class="label ? 'mt-1' : ''">
17
+ <input
18
+ type="text"
19
+ v-model="selectSearch"
20
+ @click="toggleDropdown = !toggleDropdown"
21
+ @focus="type == 'tertiary' ? (showFocus = true) : ''"
22
+ @blur="close()"
23
+ @keyup="search()"
24
+ aria-haspopup="listbox"
25
+ aria-expanded="true"
26
+ aria-labelledby="listbox-label"
27
+ :class="{ ...classes, [inputClasses]: true }"
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
+ :disabled="isDisabled"
30
+ autocomplete="off"
31
+ />
31
32
 
32
- <div class="pointer-events-none absolute top-[7px] left-3 flex">
33
- <span class="flex items-center" :style="selectedOptionStyles">
34
- <div v-if="showImage && !selectSearch && value">
35
- <c-avatar
36
- v-if="value.photo"
37
- size="extraextrasmall"
38
- :image="value.photo"
39
- :rounded="true"
40
- ></c-avatar>
41
- <c-avatar
42
- v-else
43
- size="extraextrasmall"
44
- :nameInitials="value.initials"
45
- :rounded="true"
46
- :isDynamicallyColored="coloredAvatars"
47
- ></c-avatar>
48
- </div>
49
- <c-icon
50
- v-if="icon && !showImage"
51
- :class="icon.class"
52
- :name="icon.name"
53
- :type="icon.type"
54
- >
55
- </c-icon>
56
- <span :class="showImage ? 'ml-3' : ''" class="block truncate text-sm">
57
- {{
58
- selectedValue
59
- ? selectedValue
60
- : !selectSearch || selectSearch == ""
61
- ? placeholder
62
- : null
63
- }}
64
- </span>
65
- </span>
66
- </div>
67
- <div class="pointer-events-none absolute top-2 right-3 flex">
68
33
  <div
69
- v-if="type == 'tertiary' ? showFocus : true"
70
- class="pointer-events-none right-0 flex items-center"
34
+ class="pointer-events-none absolute inset-0 left-3 flex h-[38px] items-center overflow-hidden pr-10"
71
35
  >
72
- <c-icon
73
- name="selector"
74
- type="solid"
75
- class="h-5 w-5 text-gray-400"
76
- ></c-icon>
36
+ <div class="flex items-center truncate" :style="selectedOptionStyles">
37
+ <div v-if="showImage && !selectSearch && value">
38
+ <c-avatar
39
+ v-if="value.photo"
40
+ size="extraextrasmall"
41
+ :image="value.photo"
42
+ :rounded="true"
43
+ ></c-avatar>
44
+ <c-avatar
45
+ v-else
46
+ size="extraextrasmall"
47
+ :nameInitials="value.initials"
48
+ :rounded="true"
49
+ :isDynamicallyColored="coloredAvatars"
50
+ ></c-avatar>
51
+ </div>
52
+ <c-icon
53
+ v-if="icon && !showImage"
54
+ :class="icon.class"
55
+ :name="icon.name"
56
+ :type="icon.type"
57
+ >
58
+ </c-icon>
59
+ <p :class="showImage ? 'ml-3' : ''" class="block truncate text-sm">
60
+ {{
61
+ selectedValue
62
+ ? selectedValue
63
+ : !selectSearch || selectSearch == ""
64
+ ? placeholder
65
+ : null
66
+ }}
67
+ </p>
68
+ </div>
69
+ </div>
70
+ <div class="pointer-events-none absolute top-2 right-3 flex">
71
+ <div
72
+ v-if="type == 'tertiary' ? showFocus : true"
73
+ class="pointer-events-none right-0 flex items-center"
74
+ >
75
+ <c-icon
76
+ name="selector"
77
+ type="solid"
78
+ class="h-5 w-5 text-gray-400"
79
+ ></c-icon>
80
+ </div>
77
81
  </div>
78
82
  </div>
79
83
  <transition