From a08f4ff69e5b3844cd51d5acffc0df3811d3da4e Mon Sep 17 00:00:00 2001 From: inottn Date: Sun, 22 Sep 2024 21:59:29 +0800 Subject: [PATCH] fix: use data-allow-mismatch to suppress hydration mismatch warnings (#13122) --- .../test/__snapshots__/demo-ssr.spec.ts.snap | 8 ++ .../test/__snapshots__/demo.spec.ts.snap | 8 ++ .../test/__snapshots__/index.spec.ts.snap | 24 ++++ .../test/__snapshots__/demo-ssr.spec.ts.snap | 5 + .../test/__snapshots__/demo.spec.ts.snap | 10 ++ .../test/__snapshots__/demo-ssr.spec.ts.snap | 10 ++ .../test/__snapshots__/demo.spec.ts.snap | 10 ++ .../test/__snapshots__/index.spec.ts.snap | 4 + .../test/__snapshots__/demo-ssr.spec.ts.snap | 4 + .../test/__snapshots__/demo.spec.ts.snap | 20 ++- .../test/__snapshots__/demo-ssr.spec.ts.snap | 4 + .../test/__snapshots__/demo.spec.ts.snap | 4 + .../test/__snapshots__/index.spec.ts.snap | 88 ++++++++++++-- .../vant/src/dropdown-item/DropdownItem.tsx | 1 + .../vant/src/dropdown-menu/DropdownMenu.tsx | 1 + .../test/__snapshots__/demo.spec.ts.snap | 15 +++ .../test/__snapshots__/index.spec.tsx.snap | 33 +++++ packages/vant/src/empty/Empty.tsx | 81 ++++++++++--- .../test/__snapshots__/demo-ssr.spec.ts.snap | 54 +++++++-- .../test/__snapshots__/demo.spec.ts.snap | 73 +++++++++-- .../test/__snapshots__/index.spec.ts.snap | 45 +++++-- packages/vant/src/field/Field.tsx | 2 + .../test/__snapshots__/demo-ssr.spec.ts.snap | 51 ++++++++ .../test/__snapshots__/demo.spec.ts.snap | 51 ++++++++ .../test/__snapshots__/index.spec.js.snap | 8 ++ .../test/__snapshots__/demo.spec.ts.snap | 6 + .../test/__snapshots__/demo-ssr.spec.ts.snap | 3 + .../test/__snapshots__/demo.spec.ts.snap | 6 + .../test/__snapshots__/demo-ssr.spec.ts.snap | 28 +++++ .../form/test/__snapshots__/demo.spec.ts.snap | 60 +++++++-- .../test/__snapshots__/events.spec.tsx.snap | 2 + .../test/__snapshots__/props.spec.tsx.snap | 17 +++ .../test/__snapshots__/demo-ssr.spec.ts.snap | 4 + .../icon/test/__snapshots__/demo.spec.ts.snap | 8 ++ .../test/__snapshots__/demo-ssr.spec.ts.snap | 2 + .../test/__snapshots__/demo.spec.ts.snap | 4 + .../test/__snapshots__/demo-ssr.spec.ts.snap | 3 + .../list/test/__snapshots__/demo.spec.ts.snap | 6 + .../test/__snapshots__/demo-ssr.spec.ts.snap | 2 + .../test/__snapshots__/demo.spec.ts.snap | 2 + .../test/__snapshots__/demo-ssr.spec.ts.snap | 10 ++ .../test/__snapshots__/demo.spec.ts.snap | 20 +++ .../test/__snapshots__/demo-ssr.spec.ts.snap | 2 + .../test/__snapshots__/demo.spec.ts.snap | 2 + .../test/__snapshots__/demo-ssr.spec.ts.snap | 2 + .../test/__snapshots__/demo.spec.ts.snap | 2 + .../test/__snapshots__/demo-ssr.spec.ts.snap | 3 + .../test/__snapshots__/demo.spec.ts.snap | 6 + packages/vant/src/search/Search.tsx | 6 +- .../test/__snapshots__/demo-ssr.spec.ts.snap | 7 ++ .../test/__snapshots__/demo.spec.ts.snap | 7 ++ .../test/__snapshots__/index.spec.ts.snap | 3 +- packages/vant/src/tab/Tab.tsx | 2 + packages/vant/src/tab/TabTitle.tsx | 1 + .../test/__snapshots__/demo-ssr.spec.ts.snap | 57 +++++++++ .../tab/test/__snapshots__/demo.spec.ts.snap | 114 ++++++++++++++++++ .../test/__snapshots__/index.spec.tsx.snap | 43 +++++++ .../test/__snapshots__/insert.spec.tsx.snap | 19 +++ 58 files changed, 1005 insertions(+), 68 deletions(-) diff --git a/packages/vant/src/address-edit/test/__snapshots__/demo-ssr.spec.ts.snap b/packages/vant/src/address-edit/test/__snapshots__/demo-ssr.spec.ts.snap index 009a19629..25e50d5da 100644 --- a/packages/vant/src/address-edit/test/__snapshots__/demo-ssr.spec.ts.snap +++ b/packages/vant/src/address-edit/test/__snapshots__/demo-ssr.spec.ts.snap @@ -15,6 +15,7 @@ exports[`should render demo and match snapshot 1`] = `