@dataloop-ai/components 0.19.284 → 0.19.285
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 +1 -1
- package/src/components/compound/DlSelect/DlSelect.vue +7 -3
- package/src/components/compound/DlSelect/components/DlSelectOption.vue +13 -20
- package/src/components/compound/DlSelect/types.ts +2 -0
- package/src/components/compound/DlSelect/utils.ts +1 -3
- package/src/demos/DlSelectDemo.vue +1 -1
package/package.json
CHANGED
|
@@ -341,11 +341,13 @@ import {
|
|
|
341
341
|
getLabel,
|
|
342
342
|
getIconSize,
|
|
343
343
|
optionsValidator,
|
|
344
|
-
DlSelectOptionType,
|
|
345
344
|
getLabelOfSelectedOption,
|
|
346
345
|
getCaseInsensitiveInput
|
|
347
346
|
} from './utils'
|
|
348
|
-
import {
|
|
347
|
+
import {
|
|
348
|
+
DlSelectOption as DlSelectOptionEntry,
|
|
349
|
+
DlSelectOptionType
|
|
350
|
+
} from '../types'
|
|
349
351
|
import DlSelectOption from './components/DlSelectOption.vue'
|
|
350
352
|
import { cloneDeep, isEqual } from 'lodash'
|
|
351
353
|
import { getColor } from '../../../utils'
|
|
@@ -1219,7 +1221,9 @@ export default defineComponent({
|
|
|
1219
1221
|
justify-content: center !important;
|
|
1220
1222
|
align-items: center;
|
|
1221
1223
|
color: var(--dl-color-medium);
|
|
1222
|
-
transition-property:
|
|
1224
|
+
transition-property:
|
|
1225
|
+
transform,
|
|
1226
|
+
-webkit-transform;
|
|
1223
1227
|
transition-duration: 0.28s, 0.28s;
|
|
1224
1228
|
transition-timing-function: ease, ease;
|
|
1225
1229
|
transition-delay: 0s, 0s;
|
|
@@ -1,9 +1,5 @@
|
|
|
1
1
|
<template>
|
|
2
|
-
<div
|
|
3
|
-
:id="uuid"
|
|
4
|
-
:class="identifierClass"
|
|
5
|
-
style="width: 100%"
|
|
6
|
-
>
|
|
2
|
+
<div :id="uuid" :class="identifierClass" style="width: 100%">
|
|
7
3
|
<div
|
|
8
4
|
v-if="readonly"
|
|
9
5
|
:class="[{ 'readonly-option': true }, { capitalized }]"
|
|
@@ -22,10 +18,7 @@
|
|
|
22
18
|
style="width: 100%"
|
|
23
19
|
@click="handleClick"
|
|
24
20
|
>
|
|
25
|
-
<dl-item-section
|
|
26
|
-
:color="color"
|
|
27
|
-
style="width: 100%"
|
|
28
|
-
>
|
|
21
|
+
<dl-item-section :color="color" style="width: 100%">
|
|
29
22
|
<span
|
|
30
23
|
v-if="multiselect"
|
|
31
24
|
class="multiselect-option"
|
|
@@ -58,15 +51,9 @@
|
|
|
58
51
|
}}
|
|
59
52
|
</slot>
|
|
60
53
|
</dl-checkbox>
|
|
61
|
-
<span
|
|
62
|
-
v-if="count"
|
|
63
|
-
class="counter"
|
|
64
|
-
> ({{ count }}) </span>
|
|
54
|
+
<span v-if="count" class="counter"> ({{ count }}) </span>
|
|
65
55
|
</span>
|
|
66
|
-
<div
|
|
67
|
-
v-else
|
|
68
|
-
:class="{ capitalized }"
|
|
69
|
-
>
|
|
56
|
+
<div v-else :class="{ capitalized }">
|
|
70
57
|
<slot>
|
|
71
58
|
{{
|
|
72
59
|
capitalized
|
|
@@ -130,8 +117,12 @@ import { DlItemSection } from '../../../shared'
|
|
|
130
117
|
import { v4 } from 'uuid'
|
|
131
118
|
import { debounce } from 'lodash'
|
|
132
119
|
import { stateManager } from '../../../../StateManager'
|
|
133
|
-
import {
|
|
134
|
-
import {
|
|
120
|
+
import { getCaseInsensitiveInput, getLabel } from '../utils'
|
|
121
|
+
import {
|
|
122
|
+
DlSelectedValueType,
|
|
123
|
+
DlSelectOption,
|
|
124
|
+
DlSelectOptionType
|
|
125
|
+
} from '../../types'
|
|
135
126
|
|
|
136
127
|
const ValueTypes = [Array, Boolean, String, Number, Object, Function]
|
|
137
128
|
|
|
@@ -412,7 +403,9 @@ export default defineComponent({
|
|
|
412
403
|
display: flex !important;
|
|
413
404
|
justify-content: center !important;
|
|
414
405
|
color: var(--dl-color-medium);
|
|
415
|
-
transition-property:
|
|
406
|
+
transition-property:
|
|
407
|
+
transform,
|
|
408
|
+
-webkit-transform;
|
|
416
409
|
transition-duration: 0.28s, 0.28s;
|
|
417
410
|
transition-timing-function: ease, ease;
|
|
418
411
|
transition-delay: 0s, 0s;
|
|
@@ -1,7 +1,5 @@
|
|
|
1
1
|
import { TInputSizes } from '../../../utils/input-sizes'
|
|
2
|
-
import {
|
|
3
|
-
|
|
4
|
-
export type DlSelectOptionType = string | number | DlSelectOption
|
|
2
|
+
import { DlSelectOptionType } from './types'
|
|
5
3
|
|
|
6
4
|
export const getLabel = (option: any) => {
|
|
7
5
|
if (typeof option === 'object' && 'label' in option) {
|
|
@@ -632,7 +632,7 @@
|
|
|
632
632
|
import { cloneDeep } from 'lodash'
|
|
633
633
|
import { defineComponent } from 'vue-demi'
|
|
634
634
|
import { DlChip, DlSelect, DlIcon, DlBadge, DlButton } from '../components'
|
|
635
|
-
import { DlSelectOptionType } from '../components/
|
|
635
|
+
import { DlSelectOptionType } from '../components/types'
|
|
636
636
|
|
|
637
637
|
const defaultOptions = [
|
|
638
638
|
{ label: 'Contributor 1', value: 'c1' },
|