0
0
Fork 0

fix: reset VnTable scroll properties

This commit is contained in:
Javier Segarra 2024-09-18 12:27:48 +00:00
parent 29bd3f0516
commit d76250f56f
1 changed files with 3 additions and 8 deletions

View File

@ -69,10 +69,7 @@ const $props = defineProps({
type: Boolean, type: Boolean,
default: false, default: false,
}, },
disableInfiniteScroll: {
type: Boolean,
default: false,
},
hasSubToolbar: { hasSubToolbar: {
type: Boolean, type: Boolean,
default: null, default: null,
@ -368,9 +365,7 @@ function handleOnDataSaved(_) {
ref="CrudModelRef" ref="CrudModelRef"
@on-fetch="(...args) => emit('onFetch', ...args)" @on-fetch="(...args) => emit('onFetch', ...args)"
:search-url="searchUrl" :search-url="searchUrl"
:disable-infinite-scroll=" :disable-infinite-scroll="isTableMode"
$attrs['disableInfiniteScroll'] ? isTableMode : !disableInfiniteScroll
"
@save-changes="reload" @save-changes="reload"
:has-sub-toolbar="$props.hasSubToolbar ?? isEditable" :has-sub-toolbar="$props.hasSubToolbar ?? isEditable"
:auto-load="hasParams || $attrs['auto-load']" :auto-load="hasParams || $attrs['auto-load']"
@ -390,7 +385,7 @@ function handleOnDataSaved(_) {
card-container-class="grid-three" card-container-class="grid-three"
flat flat
:style="isTableMode && `max-height: ${tableHeight}`" :style="isTableMode && `max-height: ${tableHeight}`"
virtual-scroll :virtual-scroll="isTableMode"
@virtual-scroll=" @virtual-scroll="
(event) => (event) =>
event.index > rows.length - 2 && event.index > rows.length - 2 &&