optimize(components): accuracy draggable area for TableColumnSetting with animation

This commit is contained in:
orangelckc 2024-06-01 16:07:34 +02:00
parent 086bad474e
commit 2ed7699372
No known key found for this signature in database
GPG Key ID: ABA70086FAC6334C

View File

@ -21,10 +21,10 @@ const columns = defineModel<NaiveUI.TableColumnCheck[]>('columns', {
{{ $t('common.columnSetting') }} {{ $t('common.columnSetting') }}
</NButton> </NButton>
</template> </template>
<VueDraggable v-model="columns"> <VueDraggable v-model="columns" :animation="150" filter=".none_draggable">
<div v-for="item in columns" :key="item.key" class="h-36px flex-y-center rd-4px hover:(bg-primary bg-opacity-20)"> <div v-for="item in columns" :key="item.key" class="h-36px flex-y-center rd-4px hover:(bg-primary bg-opacity-20)">
<icon-mdi-drag class="mr-8px cursor-move text-icon" /> <icon-mdi-drag class="mr-8px h-full cursor-move text-icon" />
<NCheckbox v-model:checked="item.checked"> <NCheckbox v-model:checked="item.checked" class="none_draggable flex-1">
{{ item.title }} {{ item.title }}
</NCheckbox> </NCheckbox>
</div> </div>