32
32
<span class =" multiselect-name" >
33
33
{{ option.displayName }}
34
34
</span >
35
- <span :class =" { icon: true, ['icon-' + option.type]: true, 'multiselect-icon': true }" />
35
+ <span :class =" { icon: true, [typeIconClass[ option.type] ]: true, 'multiselect-icon': true }" />
36
36
</div >
37
37
</template >
38
38
<template #selected-option =" option " >
47
47
<span class =" multiselect-name" >
48
48
{{ option.displayName }}
49
49
</span >
50
- <span :class =" { icon: true, ['icon-' + option.type]: true, 'multiselect-icon': true }" />
50
+ <span :class =" { icon: true, [typeIconClass[ option.type] ]: true, 'multiselect-icon': true }" />
51
51
</template >
52
52
<template #noOptions >
53
53
{{ t('approval', 'No recommendations. Start typing.') }}
@@ -67,6 +67,12 @@ import axios from '@nextcloud/axios'
67
67
import NcAvatar from ' @nextcloud/vue/dist/Components/NcAvatar.js'
68
68
import NcSelect from ' @nextcloud/vue/dist/Components/NcSelect.js'
69
69
70
+ const typeIconClass = {
71
+ user: ' icon-user' ,
72
+ group: ' icon-group' ,
73
+ circle: ' icon-circles' ,
74
+ }
75
+
70
76
export default {
71
77
name: ' MultiselectWho' ,
72
78
@@ -86,8 +92,7 @@ export default {
86
92
default : () => [
87
93
0 ,
88
94
1 ,
89
- // wait until new circle stuff is more stable
90
- // 7,
95
+ 7 ,
91
96
],
92
97
},
93
98
placeholder: {
@@ -102,6 +107,7 @@ export default {
102
107
103
108
data () {
104
109
return {
110
+ typeIconClass,
105
111
loadingSuggestions: false ,
106
112
suggestions: [],
107
113
query: ' ' ,
@@ -266,12 +272,7 @@ export default {
266
272
}
267
273
.multiselect-icon {
268
274
opacity : 0.5 ;
269
- }
270
- .icon-circle {
271
- background-image : var (--icon-contacts-circles-000 );
272
- background-size : 100% 100% ;
273
- background-repeat : no-repeat ;
274
- background-position : center ;
275
+ margin-left : 4px ;
275
276
}
276
277
.select-suggestion {
277
278
display : flex ;
0 commit comments