From 08e4bb40b41b6bed73edfdd5eace80925b8534da Mon Sep 17 00:00:00 2001 From: layhuts Date: Sat, 9 May 2026 18:28:23 +0800 Subject: [PATCH] style: reformat code --- packages/effects/plugins/src/vxe-table/use-vxe-grid.vue | 7 ++----- playground/src/views/examples/vxe-table/viewed.vue | 5 +++-- 2 files changed, 5 insertions(+), 7 deletions(-) diff --git a/packages/effects/plugins/src/vxe-table/use-vxe-grid.vue b/packages/effects/plugins/src/vxe-table/use-vxe-grid.vue index 173c1bfab..665f18f62 100644 --- a/packages/effects/plugins/src/vxe-table/use-vxe-grid.vue +++ b/packages/effects/plugins/src/vxe-table/use-vxe-grid.vue @@ -92,11 +92,8 @@ watch( if (!cfg) return; - const keyField = - (gridOptions.value?.rowConfig as any)?.keyField || 'id'; - const resolved = isBoolean(cfg) - ? {keyField} - : {keyField, ...cfg}; + const keyField = (gridOptions.value?.rowConfig as any)?.keyField || 'id'; + const resolved = isBoolean(cfg) ? {keyField} : {keyField, ...cfg}; gridApi.viewedRowHelper = useViewedRow(resolved); }, {immediate: true}, diff --git a/playground/src/views/examples/vxe-table/viewed.vue b/playground/src/views/examples/vxe-table/viewed.vue index b849ab70e..3531ef89a 100644 --- a/playground/src/views/examples/vxe-table/viewed.vue +++ b/playground/src/views/examples/vxe-table/viewed.vue @@ -164,8 +164,9 @@ function onClassNameSet() { gridApi.setState({ viewedRowOptions: { rowClassName: () => { - - return isClassName.value ? 'bg-red-100 vxe-row--viewed' : 'vxe-row--viewed'; + return isClassName.value + ? 'bg-red-100 vxe-row--viewed' + : 'vxe-row--viewed'; }, }, });