@dataloop-ai/components 0.20.184 → 0.20.186-ds-v3.0
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/DlDateTime/DlDateTimeRange/DateTimeRangeContent.vue +177 -0
- package/src/components/compound/DlDateTime/DlDateTimeRange/DlDateTimeRange.vue +101 -106
- package/src/components/compound/DlDateTime/DlDateTimeRange/types.ts +5 -0
- package/src/components/compound/DlDialogBox/DlDialogBox.vue +12 -2
- package/src/components/compound/DlDropdownButton/DlDropdownButton.vue +24 -27
- package/src/components/compound/DlInput/DlInput.vue +4 -0
- package/src/components/compound/DlSearches/DlSearch/DlSearch.vue +12 -0
- package/src/components/compound/DlSearches/DlSmartSearch/DlSmartSearch.vue +3 -8
- package/src/components/compound/DlSearches/DlSmartSearch/components/DlSmartSearchInput.vue +58 -18
- package/src/components/compound/DlSearches/DlSmartSearch/components/DlSmartSearchJsonEditorDialog.vue +187 -45
- package/src/components/compound/DlSelect/DlSelect.vue +15 -3
- package/src/components/compound/DlSelect/components/DlSelectOption.vue +7 -6
- package/src/components/compound/DlTable/DlTable.vue +13 -12
- package/src/components/compound/DlTable/hooks/use-sortable.ts +1 -2
- package/src/components/compound/DlTreeTable/DlTreeTable.vue +4 -2
- package/src/components/compound/DlTreeTable/views/DlTrTreeView.vue +1 -1
- package/src/components/essential/DlSwitch/DlSwitch.vue +14 -4
- package/src/components/shared/DlVirtualScroll/DlVirtualScroll.vue +3 -1
- package/src/demos/DlDateTimeRangeDemo.vue +20 -0
- package/src/demos/SmartSearchDemo/DlSmartSearchDemo.vue +1 -0
|
@@ -161,7 +161,7 @@
|
|
|
161
161
|
<div
|
|
162
162
|
v-if="
|
|
163
163
|
visibleColumns &&
|
|
164
|
-
|
|
164
|
+
visibleColumns.length
|
|
165
165
|
"
|
|
166
166
|
class="visible-columns-justify-end"
|
|
167
167
|
style="width: 100%; display: flex"
|
|
@@ -274,8 +274,8 @@
|
|
|
274
274
|
isRowSelected(getRowKey(props.item))
|
|
275
275
|
? 'selected'
|
|
276
276
|
: hasAnyAction
|
|
277
|
-
|
|
278
|
-
|
|
277
|
+
? ' cursor-pointer'
|
|
278
|
+
: ''
|
|
279
279
|
"
|
|
280
280
|
:no-hover="noHover"
|
|
281
281
|
@click="
|
|
@@ -565,7 +565,7 @@
|
|
|
565
565
|
<div
|
|
566
566
|
v-if="
|
|
567
567
|
visibleColumns &&
|
|
568
|
-
|
|
568
|
+
visibleColumns.length
|
|
569
569
|
"
|
|
570
570
|
class="visible-columns-justify-end"
|
|
571
571
|
style="width: 100%; display: flex"
|
|
@@ -674,8 +674,8 @@
|
|
|
674
674
|
<dl-top-scroll
|
|
675
675
|
v-if="
|
|
676
676
|
tableScroll &&
|
|
677
|
-
|
|
678
|
-
|
|
677
|
+
infiniteScroll &&
|
|
678
|
+
!isDataEmpty
|
|
679
679
|
"
|
|
680
680
|
:container-ref="tableScroll"
|
|
681
681
|
@scroll-to-top="
|
|
@@ -709,8 +709,8 @@
|
|
|
709
709
|
isRowSelected(getRowKey(row))
|
|
710
710
|
? 'selected'
|
|
711
711
|
: hasAnyAction
|
|
712
|
-
|
|
713
|
-
|
|
712
|
+
? ' cursor-pointer'
|
|
713
|
+
: ''
|
|
714
714
|
"
|
|
715
715
|
:no-hover="noHover"
|
|
716
716
|
@click="onTrClick($event, row, pageIndex)"
|
|
@@ -845,8 +845,8 @@
|
|
|
845
845
|
<dl-bottom-scroll
|
|
846
846
|
v-if="
|
|
847
847
|
tableScroll &&
|
|
848
|
-
|
|
849
|
-
|
|
848
|
+
infiniteScroll &&
|
|
849
|
+
!isDataEmpty
|
|
850
850
|
"
|
|
851
851
|
:container-ref="tableScroll"
|
|
852
852
|
@scroll-to-bottom="
|
|
@@ -903,7 +903,7 @@
|
|
|
903
903
|
<div
|
|
904
904
|
v-if="
|
|
905
905
|
hasBottomSelectionBanner &&
|
|
906
|
-
|
|
906
|
+
selectedRowsLabel(rowsSelectedNumber)
|
|
907
907
|
"
|
|
908
908
|
class="dl-table__control"
|
|
909
909
|
>
|
|
@@ -1762,7 +1762,8 @@ export default defineComponent({
|
|
|
1762
1762
|
|
|
1763
1763
|
const colspanForProgressBar = computed(() => {
|
|
1764
1764
|
return (
|
|
1765
|
-
colspanWithExpandableRow.value -
|
|
1765
|
+
colspanWithExpandableRow.value -
|
|
1766
|
+
(hasDraggableRows.value ? 0 : 1)
|
|
1766
1767
|
)
|
|
1767
1768
|
})
|
|
1768
1769
|
|
|
@@ -100,12 +100,11 @@ export function useSortable(vm: Record<string, any>) {
|
|
|
100
100
|
})
|
|
101
101
|
|
|
102
102
|
watch(rootRef, (newRootRef) => {
|
|
103
|
-
|
|
104
103
|
if (sortable.value) {
|
|
105
104
|
sortable.value.destroy()
|
|
106
105
|
sortable.value = null
|
|
107
106
|
}
|
|
108
|
-
|
|
107
|
+
|
|
109
108
|
if (newRootRef) {
|
|
110
109
|
sortable.value = new Sortable(newRootRef, {
|
|
111
110
|
...props.options,
|
|
@@ -804,7 +804,9 @@ export default defineComponent({
|
|
|
804
804
|
targetRow: finalTarget
|
|
805
805
|
})
|
|
806
806
|
|
|
807
|
-
const isDragValid =
|
|
807
|
+
const isDragValid =
|
|
808
|
+
shouldSkipValidation ||
|
|
809
|
+
checkParentCondition(draggedRow.value, finalTarget)
|
|
808
810
|
if (isDragValid) {
|
|
809
811
|
const smartSortingMovement = {
|
|
810
812
|
...sortingMovement.value,
|
|
@@ -929,7 +931,7 @@ export default defineComponent({
|
|
|
929
931
|
}
|
|
930
932
|
|
|
931
933
|
const isValid = checkParentCondition(draggedRow.value, targetRow)
|
|
932
|
-
|
|
934
|
+
|
|
933
935
|
if (isValid) {
|
|
934
936
|
storedValidTarget.value = targetRow
|
|
935
937
|
}
|
|
@@ -7,12 +7,14 @@
|
|
|
7
7
|
}`"
|
|
8
8
|
>
|
|
9
9
|
<label
|
|
10
|
-
v-if="
|
|
10
|
+
v-if="hasLeftLabel"
|
|
11
11
|
class="left dl-switch-label"
|
|
12
12
|
:for="computedId"
|
|
13
13
|
:style="cssLabelVars"
|
|
14
14
|
>
|
|
15
|
-
|
|
15
|
+
<slot name="left-label">
|
|
16
|
+
{{ leftLabel }}
|
|
17
|
+
</slot>
|
|
16
18
|
</label>
|
|
17
19
|
<span
|
|
18
20
|
class="dl-switch-container"
|
|
@@ -35,12 +37,14 @@
|
|
|
35
37
|
/>
|
|
36
38
|
</span>
|
|
37
39
|
<label
|
|
38
|
-
v-if="
|
|
40
|
+
v-if="hasRightLabel"
|
|
39
41
|
class="right dl-switch-label"
|
|
40
42
|
:for="computedId"
|
|
41
43
|
:style="cssLabelVars"
|
|
42
44
|
>
|
|
43
|
-
|
|
45
|
+
<slot name="right-label">
|
|
46
|
+
{{ rightLabel }}
|
|
47
|
+
</slot>
|
|
44
48
|
</label>
|
|
45
49
|
</div>
|
|
46
50
|
</template>
|
|
@@ -143,6 +147,12 @@ export default defineComponent({
|
|
|
143
147
|
? this.index === -1
|
|
144
148
|
: toRaw(this.modelValue) === toRaw(this.falseValue)
|
|
145
149
|
},
|
|
150
|
+
hasLeftLabel(): boolean {
|
|
151
|
+
return !!this.leftLabel || !!this.$slots['left-label']
|
|
152
|
+
},
|
|
153
|
+
hasRightLabel(): boolean {
|
|
154
|
+
return !!this.rightLabel || !!this.$slots['right-label']
|
|
155
|
+
},
|
|
146
156
|
cssVars(): Record<string, string> {
|
|
147
157
|
return {
|
|
148
158
|
'--dl-checkbox-height': `${this.size}px`,
|
|
@@ -124,7 +124,9 @@ export default defineComponent({
|
|
|
124
124
|
|
|
125
125
|
let localScrollTarget: HTMLElement | undefined
|
|
126
126
|
const rootRef: Ref<HTMLElement | null> = ref(null)
|
|
127
|
-
const scrollSizeItem: Ref<number> = ref(
|
|
127
|
+
const scrollSizeItem: Ref<number> = ref(
|
|
128
|
+
virtualScrollItemSize.value || 40
|
|
129
|
+
)
|
|
128
130
|
|
|
129
131
|
const isDefined = (v: any) => v !== undefined && v !== null
|
|
130
132
|
|
|
@@ -176,6 +176,26 @@
|
|
|
176
176
|
@change="handleModelValueUpdate"
|
|
177
177
|
/>
|
|
178
178
|
</div>
|
|
179
|
+
<div style="width: 500px; margin-top: 30px">
|
|
180
|
+
<div style="margin-bottom: 10px; font-weight: bold">
|
|
181
|
+
Inline Mode
|
|
182
|
+
</div>
|
|
183
|
+
<dl-date-time-range
|
|
184
|
+
v-model="date"
|
|
185
|
+
:type="type"
|
|
186
|
+
width="100%"
|
|
187
|
+
:available-range="range ? availableRange : null"
|
|
188
|
+
:mode="mode"
|
|
189
|
+
:show-time="showTime"
|
|
190
|
+
:auto-close="autoClose"
|
|
191
|
+
:including-current-month="includesCurrentMonthEnd"
|
|
192
|
+
:should-clear-select-first-option="shouldClearSelectFirstOption"
|
|
193
|
+
:disabled-type="type === 'day' ? 'month' : 'day'"
|
|
194
|
+
view-mode="inline"
|
|
195
|
+
@set-type="handleSetType"
|
|
196
|
+
@change="handleModelValueUpdate"
|
|
197
|
+
/>
|
|
198
|
+
</div>
|
|
179
199
|
</div>
|
|
180
200
|
</template>
|
|
181
201
|
<script lang="ts">
|