@regenbio/regenbio-components-react 1.3.25 → 1.3.27

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -0,0 +1,8 @@
1
+ <?xml version="1.0" encoding="UTF-8"?>
2
+ <project version="4">
3
+ <component name="ProjectModuleManager">
4
+ <modules>
5
+ <module fileurl="file://$PROJECT_DIR$/.idea/test-components.iml" filepath="$PROJECT_DIR$/.idea/test-components.iml" />
6
+ </modules>
7
+ </component>
8
+ </project>
@@ -0,0 +1,12 @@
1
+ <?xml version="1.0" encoding="UTF-8"?>
2
+ <module type="WEB_MODULE" version="4">
3
+ <component name="NewModuleRootManager">
4
+ <content url="file://$MODULE_DIR$">
5
+ <excludeFolder url="file://$MODULE_DIR$/.tmp" />
6
+ <excludeFolder url="file://$MODULE_DIR$/temp" />
7
+ <excludeFolder url="file://$MODULE_DIR$/tmp" />
8
+ </content>
9
+ <orderEntry type="inheritedJdk" />
10
+ <orderEntry type="sourceFolder" forTests="false" />
11
+ </component>
12
+ </module>
package/.idea/vcs.xml ADDED
@@ -0,0 +1,6 @@
1
+ <?xml version="1.0" encoding="UTF-8"?>
2
+ <project version="4">
3
+ <component name="VcsDirectoryMappings">
4
+ <mapping directory="$PROJECT_DIR$" vcs="Git" />
5
+ </component>
6
+ </project>
package/build/index.d.ts CHANGED
@@ -29,6 +29,7 @@ import RbSingleImageUploader from "./components/Uploader/SingleImageUploader";
29
29
  import { RbSingleImageUploaderProps } from "./components/Uploader/SingleImageUploader/type";
30
30
  import { getRbInitialState, getRbAppLayout } from "./components/AppLayout";
31
31
  import { RbInitialStateReqProps, RbInitialStateRespProps, RbAppLayoutProps } from "./components/AppLayout/type";
32
+ import { RbCurrentUser, RbCurrentTheme } from "./components/AppLayout/interface";
32
33
  import RbAuthFrame from "./components/LoginLoad/AuthFrame";
33
34
  import { RbAuthFrameProps } from "./components/LoginLoad/AuthFrame/type";
34
35
  import RbBindFrame from "./components/LoginLoad/BindFrame";
@@ -52,6 +53,8 @@ import CommonConstant from "./services/constants/commonConstant";
52
53
  import IconConstant from "./services/constants/iconConstant";
53
54
  import DbConstant from "./services/constants/dbConstant";
54
55
  import { RespDTO, ConstantListItem, DictListItem, PageParams } from "./services/types/commonType";
56
+ import { BaseDO, BaseRelativeDO } from "@/interfaces/commonInterface";
57
+ import { TokenDO } from "./services/interfaces/oauth2Interface";
55
58
  import zhCN from "./locales/zh-CN";
56
59
  import enUS from "./locales/en-US";
57
60
  export { RbDataTable };
@@ -85,12 +88,14 @@ export { RbSingleImageUploader };
85
88
  export type { RbSingleImageUploaderProps };
86
89
  export { getRbInitialState, getRbAppLayout };
87
90
  export type { RbInitialStateReqProps, RbInitialStateRespProps, RbAppLayoutProps };
91
+ export { RbCurrentUser, RbCurrentTheme };
88
92
  export { RbAuthFrame, RbBindFrame };
89
93
  export type { RbAuthFrameProps, RbBindFrameProps };
90
94
  export { DbUtil, ObjectUtil, EventUtil, StorageUtil, ResourceUtil, RenderUtil, StringUtil, NumberUtil, RandomUtil, UnicodeUtil, UploadUtil, RequestUtil, DictUtil };
91
95
  export { EventEnum, StorageEnum };
92
96
  export { CommonConstant, IconConstant, DbConstant };
93
97
  export { RespDTO, ConstantListItem, DictListItem, PageParams };
98
+ export { BaseDO, BaseRelativeDO, TokenDO };
94
99
  export { zhCN, enUS };
95
100
  declare const _default: {
96
101
  RbDataTable: <DataSource, U, ValueType = "text">(props: RbDataTableProps<DataSource, U, ValueType>) => any;
package/package.json CHANGED
@@ -1,15 +1,12 @@
1
1
  {
2
2
  "name": "@regenbio/regenbio-components-react",
3
- "version": "1.3.25",
3
+ "version": "1.3.27",
4
4
  "publishConfig": {
5
5
  "access": "public"
6
6
  },
7
7
  "description": "@regenbio/regenbio-components-react",
8
8
  "main": "build/index.js",
9
9
  "types": "build/index.d.ts",
10
- "files": [
11
- "build"
12
- ],
13
10
  "scripts": {
14
11
  "checkVersion": "node scripts/checkVersion.js",
15
12
  "reinstall": "rimraf node_modules && yarn install",
@@ -0,0 +1,19 @@
1
+ const { execSync } = require('child_process');
2
+ const packageJson = require('../package.json');
3
+
4
+ const packageName = packageJson.name;
5
+ const packageVersion = packageJson.version;
6
+
7
+ try {
8
+ const result = execSync(`npm view ${packageName}@${packageVersion}`, {
9
+ stdio: 'pipe'
10
+ }).toString();
11
+
12
+ if (result) {
13
+ console.error(`\x1b[31m当前版本号 ${packageName}:${packageVersion} 已存在,请更新版本号。\x1b[0m`);
14
+ process.exit(1); // 终止发布
15
+ }
16
+ } catch (error) {
17
+ // 如果版本不存在,npm view 会抛出错误,可以继续发布
18
+ console.log(`\x1b[32m当前版本号 ${packageVersion} 不存在冲突,可以发布。\x1b[0m`);
19
+ }
package/tsconfig.json ADDED
@@ -0,0 +1,19 @@
1
+ {
2
+ "compilerOptions": {
3
+ "target": "esnext",
4
+ "module": "esnext",
5
+ "declaration": true, // 生成 .d.ts 类型声明文件
6
+ "outDir": "./build",
7
+ "jsx": "react-jsx",
8
+ "esModuleInterop": true,
9
+ "skipLibCheck": true,
10
+ "forceConsistentCasingInFileNames": true,
11
+ "moduleResolution": "node",
12
+ "baseUrl": "./",
13
+ "paths": {
14
+ "@/*": ["src/services/*"],
15
+ }
16
+ },
17
+ "include": ["src"],
18
+ "exclude": ["node_modules", "build"]
19
+ }
@@ -0,0 +1,48 @@
1
+ const path = require('path');
2
+
3
+ module.exports = {
4
+ entry: './src/index.tsx',
5
+ output: {
6
+ filename: 'index.js',
7
+ path: path.resolve(__dirname, 'build'),
8
+ libraryTarget: 'commonjs2'
9
+ },
10
+ module: {
11
+ rules: [
12
+ {
13
+ test: /\.js|jsx$/,
14
+ exclude: /(node_modules|build)/,
15
+ use: {
16
+ loader: 'babel-loader',
17
+ options: {
18
+ presets: ['@babel/preset-env', '@babel/preset-react']
19
+ }
20
+ }
21
+ },
22
+ {
23
+ test: /\.ts|tsx$/,
24
+ exclude: /(node_modules|build)/,
25
+ use: "ts-loader"
26
+ },
27
+ {
28
+ test: /\.css$/,
29
+ use: ['style-loader', 'css-loader']
30
+ },
31
+ ]
32
+ },
33
+ externals: {
34
+ react: 'react',
35
+ 'react-dom': 'react-dom',
36
+ '@ant-design/pro-components': '@ant-design/pro-components',
37
+ '@ant-design/pro-form': '@ant-design/pro-form',
38
+ 'antd': 'antd',
39
+ 'antd-style': 'antd-style',
40
+ '@types/lodash': '@types/lodash',
41
+ },
42
+ resolve: {
43
+ alias: {
44
+ "@": path.resolve(__dirname, "src/services"),
45
+ },
46
+ extensions: [".tsx", ".ts", ".js", ".scss", ".css", ".less"],
47
+ },
48
+ };