From 7c087deded561c74b632c1eb3feba86657253fac Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E4=BA=8C=E8=B4=A7=E7=88=B1=E5=90=83=E7=99=BD=E8=90=9D?= =?UTF-8?q?=E5=8D=9C?= Date: Thu, 8 Sep 2022 15:21:42 +0800 Subject: [PATCH] chore: Add theme=null export for vite build error (#37462) * fix: Vite build error * test: Update snapshot * chore: Update snapshot --- components/__tests__/__snapshots__/index.test.ts.snap | 1 + components/index.tsx | 3 +++ tests/__snapshots__/index.test.js.snap | 1 + 3 files changed, 5 insertions(+) diff --git a/components/__tests__/__snapshots__/index.test.ts.snap b/components/__tests__/__snapshots__/index.test.ts.snap index 3e17f31437..ea9484e31b 100644 --- a/components/__tests__/__snapshots__/index.test.ts.snap +++ b/components/__tests__/__snapshots__/index.test.ts.snap @@ -67,6 +67,7 @@ Array [ "Upload", "message", "notification", + "theme", "version", ] `; diff --git a/components/index.tsx b/components/index.tsx index 2e0f4364b9..3e8d411a5a 100644 --- a/components/index.tsx +++ b/components/index.tsx @@ -16,6 +16,9 @@ if ( } /* @remove-on-es-build-end */ +// Fix vite build error +export const theme = null; + export { default as Affix } from './affix'; export type { AffixProps } from './affix'; export { default as Alert } from './alert'; diff --git a/tests/__snapshots__/index.test.js.snap b/tests/__snapshots__/index.test.js.snap index a1e9ba738e..aa0121bab7 100644 --- a/tests/__snapshots__/index.test.js.snap +++ b/tests/__snapshots__/index.test.js.snap @@ -67,6 +67,7 @@ Array [ "Upload", "message", "notification", + "theme", "version", ] `;