Browse Source

style: reformat code

pull/7898/head
layhuts 2 weeks ago
parent
commit
08e4bb40b4
  1. 7
      packages/effects/plugins/src/vxe-table/use-vxe-grid.vue
  2. 5
      playground/src/views/examples/vxe-table/viewed.vue

7
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},

5
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';
},
},
});

Loading…
Cancel
Save