@dataloop-ai/components 0.19.88 → 0.19.89
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
|
@@ -14,7 +14,7 @@
|
|
|
14
14
|
</dl-virtual-scroll>
|
|
15
15
|
</div>
|
|
16
16
|
<div
|
|
17
|
-
v-else-if="!
|
|
17
|
+
v-else-if="!hasItems"
|
|
18
18
|
ref="grid"
|
|
19
19
|
:style="gridStyles"
|
|
20
20
|
:class="gridClass"
|
|
@@ -109,8 +109,14 @@ export default defineComponent({
|
|
|
109
109
|
setup(props, { emit }) {
|
|
110
110
|
const vm = getCurrentInstance()
|
|
111
111
|
const grid = ref<HTMLElement | null>(null)
|
|
112
|
-
const {
|
|
113
|
-
|
|
112
|
+
const {
|
|
113
|
+
modelValue,
|
|
114
|
+
mode,
|
|
115
|
+
rowGap,
|
|
116
|
+
columnGap,
|
|
117
|
+
maxElementsPerRow,
|
|
118
|
+
items
|
|
119
|
+
} = toRefs(props)
|
|
114
120
|
|
|
115
121
|
const isLayoutMode = computed(() => mode.value == DlGridMode.LAYOUT)
|
|
116
122
|
const isGridMode = computed(() => mode.value == DlGridMode.GRID)
|
|
@@ -242,6 +248,8 @@ export default defineComponent({
|
|
|
242
248
|
applyGridElementStyles()
|
|
243
249
|
})
|
|
244
250
|
|
|
251
|
+
const hasItems = computed(() => !!items.value?.length)
|
|
252
|
+
|
|
245
253
|
return {
|
|
246
254
|
isLayoutMode,
|
|
247
255
|
isGridMode,
|
|
@@ -249,7 +257,8 @@ export default defineComponent({
|
|
|
249
257
|
gridClass,
|
|
250
258
|
gridStyles,
|
|
251
259
|
grid,
|
|
252
|
-
hasVirtualScroll
|
|
260
|
+
hasVirtualScroll,
|
|
261
|
+
hasItems
|
|
253
262
|
}
|
|
254
263
|
}
|
|
255
264
|
})
|