From 7bb296b3a54925042208287c90b2e1369395efbf Mon Sep 17 00:00:00 2001
From: tangjinzhou <415800467@qq.com>
Date: Wed, 15 Sep 2021 16:06:38 +0800
Subject: [PATCH] test: update table snap
---
.../table/__tests__/__snapshots__/demo.test.js.snap | 12 ++++++------
components/vc-table/Cell/index.tsx | 2 +-
2 files changed, 7 insertions(+), 7 deletions(-)
diff --git a/components/table/__tests__/__snapshots__/demo.test.js.snap b/components/table/__tests__/__snapshots__/demo.test.js.snap
index cb3147c4f..1a5a8eade 100644
--- a/components/table/__tests__/__snapshots__/demo.test.js.snap
+++ b/components/table/__tests__/__snapshots__/demo.test.js.snap
@@ -37,10 +37,10 @@ exports[`renders ./components/table/demo/basic.vue correctly 1`] = `
John Brown
- John Brown
+ 32
|
- John Brown
+ New York No. 1 Lake Park
|
NICEDEVELOPER
@@ -55,10 +55,10 @@ exports[`renders ./components/table/demo/basic.vue correctly 1`] = `
Jim Green
|
- Jim Green
+ 42
|
- Jim Green
+ London No. 1 Lake Park
|
LOSER
@@ -73,10 +73,10 @@ exports[`renders ./components/table/demo/basic.vue correctly 1`] = `
Joe Black
|
- Joe Black
+ 32
|
- Joe Black
+ Sidney No. 1 Lake Park
|
COOLTEACHER
diff --git a/components/vc-table/Cell/index.tsx b/components/vc-table/Cell/index.tsx
index 8682f4ff7..65f981834 100644
--- a/components/vc-table/Cell/index.tsx
+++ b/components/vc-table/Cell/index.tsx
@@ -162,7 +162,7 @@ export default defineComponent({
index,
column: column.__originColumn__,
},
- () => [childNode],
+ () => [childNode === undefined ? value : childNode],
);
childNode = flattenChildren(child as any);
}
|