From 88935caeb05b70a6c9cd16855e9c753784cd0447 Mon Sep 17 00:00:00 2001 From: sunshinesmilelk <1176136681@qq.com> Date: Mon, 16 Dec 2024 23:48:18 +0800 Subject: [PATCH] chore(configuration-panel): add babel config --- apps/docs/package.json | 2 +- .../babel.config.json | 20 +++++++++++++++++++ .../mana-configuration-panel/package.json | 2 +- .../src/index.spec.ts | 2 +- 4 files changed, 23 insertions(+), 3 deletions(-) create mode 100644 packages/mana-configuration-panel/babel.config.json diff --git a/apps/docs/package.json b/apps/docs/package.json index 835face..558f0e7 100644 --- a/apps/docs/package.json +++ b/apps/docs/package.json @@ -25,7 +25,7 @@ "dependencies": { "@ant-design/icons": "^5.1.0", "@difizen/mana-app": "^0.1.31", - "@difizen/mana-configuration-panel": "0.0.1", + "@difizen/mana-configuration-panel": "0.1.31", "@difizen/mana-l10n": "^0.1.31", "@difizen/mana-react": "^0.1.31", "@difizen/umi-plugin-mana": "^0.1.31", diff --git a/packages/mana-configuration-panel/babel.config.json b/packages/mana-configuration-panel/babel.config.json new file mode 100644 index 0000000..efd1224 --- /dev/null +++ b/packages/mana-configuration-panel/babel.config.json @@ -0,0 +1,20 @@ +{ + "presets": [ + "@babel/preset-env", + [ + "@babel/preset-react", + { + "runtime": "automatic" + } + ], + "@babel/preset-typescript" + ], + "plugins": [ + ["@babel/plugin-proposal-decorators", { "legacy": true }], + ["@babel/plugin-transform-flow-strip-types", { "allowDeclareFields": true }], + ["@babel/plugin-transform-private-methods", { "loose": true }], + ["@babel/plugin-transform-private-property-in-object", { "loose": true }], + ["@babel/plugin-transform-class-properties", { "loose": true }], + "babel-plugin-parameter-decorator" + ] +} diff --git a/packages/mana-configuration-panel/package.json b/packages/mana-configuration-panel/package.json index 706e1bc..a9e6aff 100644 --- a/packages/mana-configuration-panel/package.json +++ b/packages/mana-configuration-panel/package.json @@ -1,6 +1,6 @@ { "name": "@difizen/mana-configuration-panel", - "version": "0.0.1", + "version": "0.1.31", "keywords": [ "mana", "difizen", diff --git a/packages/mana-configuration-panel/src/index.spec.ts b/packages/mana-configuration-panel/src/index.spec.ts index c6a7073..13e2594 100644 --- a/packages/mana-configuration-panel/src/index.spec.ts +++ b/packages/mana-configuration-panel/src/index.spec.ts @@ -1,7 +1,7 @@ import assert from 'assert'; describe('mana-configuration-panel', () => { - it('import', () => { + it('#import', () => { assert(true); }); });