fix(playground): tmagic-form样式丢失

fix #610
This commit is contained in:
roymondchen 2024-05-29 20:10:32 +08:00
parent d98029d5e7
commit 49e9d5b985
2 changed files with 12 additions and 2 deletions

View File

@ -33,7 +33,9 @@ import App from './App.vue';
import router from './route'; import router from './route';
import 'element-plus/dist/index.css'; import 'element-plus/dist/index.css';
import '@tmagic/editor/src/theme/index.scss'; import '@tmagic/editor/dist/style.css';
import '@tmagic/form/dist/style.css';
import '@tmagic/table/dist/style.css';
// @ts-ignore // @ts-ignore
globalThis.MonacoEnvironment = { globalThis.MonacoEnvironment = {

View File

@ -46,9 +46,17 @@ export default defineConfig({
resolve: { resolve: {
alias: [ alias: [
{ {
find: /^@tmagic\/editor\/src\/theme\/index.scss/, find: /^@tmagic\/editor\/dist\/style.css/,
replacement: path.join(__dirname, '../packages/editor/src/theme/index.scss'), replacement: path.join(__dirname, '../packages/editor/src/theme/index.scss'),
}, },
{
find: /^@tmagic\/form\/dist\/style.css/,
replacement: path.join(__dirname, '../packages/form/src/theme/index.scss'),
},
{
find: /^@tmagic\/table\/dist\/style.css/,
replacement: path.join(__dirname, '../packages/table/dist/style.css'),
},
{ find: /^@tmagic\/core/, replacement: path.join(__dirname, '../packages/core/src/index.ts') }, { find: /^@tmagic\/core/, replacement: path.join(__dirname, '../packages/core/src/index.ts') },
{ find: /^@editor/, replacement: path.join(__dirname, '../packages/editor/src/') }, { find: /^@editor/, replacement: path.join(__dirname, '../packages/editor/src/') },
{ find: /^@tmagic\/editor/, replacement: path.join(__dirname, '../packages/editor/src/index.ts') }, { find: /^@tmagic\/editor/, replacement: path.join(__dirname, '../packages/editor/src/index.ts') },