@oceanbase/codemod 0.4.8 → 0.4.10

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.
package/README.md CHANGED
@@ -166,10 +166,10 @@ transform fixed style to antd v5 design token.
166
166
  - <Alert style={{ color: 'rgba(0, 0, 0, 0.85)', background: 'rgba(0, 0, 0,0.65)', backgroundColor: 'rgba(0,0,0,0.45)', border: '1px solid #d9d9d9' }} />
167
167
  - <Button style={{ color: '#1890ff', background: '#52c41a', backgroundColor: '#faad14', borderColor: '#ff4d4f' }}></Button>
168
168
  - </div>
169
- + (<div>
169
+ + <div>
170
170
  + <Alert style={{ color: token.colorText, background: token.colorTextSecondary, backgroundColor: token.colorTextTertiary, border: `1px solid ${token.colorBorder}` }} />
171
171
  + <Button style={{ color: token.colorInfo, background: token.colorSuccess, backgroundColor: token.colorWarning, borderColor: token.colorError }}></Button>
172
- + </div>)
172
+ + </div>
173
173
  );
174
174
  };
175
175
 
@@ -196,11 +196,11 @@ export default Demo;
196
196
  - <Button style={{ color: '#1890ff', background: '#52c41a', backgroundColor: '#faad14', borderColor: '#ff4d4f' }}></Button>
197
197
  - <div color="#fafafa" border="1px solid #fafafa" />
198
198
  - </div>
199
- + (<div>
199
+ + <div>
200
200
  + <Alert style={{ color: token.colorText, background: token.colorTextSecondary, backgroundColor: token.colorTextTertiary, border: `1px solid ${token.colorBgLayout}` }} />
201
201
  + <Button style={{ color: token.colorInfo, background: token.colorSuccess, backgroundColor: token.colorWarning, borderColor: token.colorError }}></Button>
202
202
  + <div color={token.colorBgLayout} border={`1px solid ${token.colorBgLayout}`} />
203
- + </div>)
203
+ + </div>
204
204
  );
205
205
  }
206
206
  }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@oceanbase/codemod",
3
- "version": "0.4.8",
3
+ "version": "0.4.10",
4
4
  "description": "Codemod for OceanBase Design upgrade",
5
5
  "keywords": [
6
6
  "oceanbase",
@@ -23,21 +23,21 @@
23
23
  "build": "father build"
24
24
  },
25
25
  "dependencies": {
26
- "@oceanbase/design": "^0.4.8",
26
+ "@oceanbase/design": "^0.4.10",
27
27
  "chalk": "^3.0.0",
28
28
  "command-exists": "^1.2.9",
29
29
  "execa": "^5.1.1",
30
30
  "find-up": "^7.0.0",
31
- "glob": "^11.0.0",
31
+ "glob": "^11.0.1",
32
32
  "is-directory": "^0.3.1",
33
33
  "is-git-clean": "^1.1.0",
34
34
  "jscodeshift": "^0.16.1",
35
35
  "lodash": "^4.17.21",
36
- "postcss": "^8.4.49",
36
+ "postcss": "^8.5.3",
37
37
  "postcss-less": "^6.0.0",
38
- "prettier": "^3.3.3",
38
+ "prettier": "^3.5.3",
39
39
  "read-pkg-up": "^10.1.0",
40
- "semver": "^7.6.3",
40
+ "semver": "^7.7.1",
41
41
  "update-check": "^1.5.4",
42
42
  "yargs-parser": "^21.1.1"
43
43
  },
@@ -47,5 +47,5 @@
47
47
  "enzyme": "^3.11.0",
48
48
  "enzyme-to-json": "^3.6.2"
49
49
  },
50
- "gitHead": "617efa9eb09833f74f0ab0065467b556b5b6843e"
50
+ "gitHead": "db83d4b1d50b50813d9751f4e8c1189badf67820"
51
51
  }
@@ -9,10 +9,10 @@ class Demo extends React.PureComponent {
9
9
 
10
10
  render() {
11
11
  return (
12
- (<div>
12
+ <div>
13
13
  <Alert style={{ color: token.colorText, background: token.colorTextSecondary, backgroundColor: token.colorTextTertiary, border: `1px solid ${token.colorBorder}` }} />
14
14
  <Button style={{ color: token.colorInfo, background: token.colorSuccess, backgroundColor: token.colorWarning, borderColor: token.colorError }}></Button>
15
- </div>)
15
+ </div>
16
16
  );
17
17
  }
18
18
  }
@@ -4,11 +4,11 @@ import { Alert, Button, theme, Tooltip } from '@oceanbase/design';
4
4
  const Demo = () => {
5
5
  const { token } = theme.useToken();
6
6
  return (
7
- (<div>
7
+ <div>
8
8
  <Alert style={{ color: token.colorText, background: token.colorTextSecondary, backgroundColor: token.colorTextTertiary, border: `1px solid ${token.colorBorder}` }} />
9
9
  <Button style={{ color: token.colorInfo, background: token.colorSuccess, backgroundColor: token.colorWarning, borderColor: token.colorError }}></Button>
10
10
  <Tooltip color={token.colorBgContainer} backgroundColor={token.colorErrorBg} borderColor={token.colorBgLayout} border={`1px solid ${token.colorBgLayout}`} />
11
- </div>)
11
+ </div>
12
12
  );
13
13
  };
14
14
 
@@ -5,11 +5,11 @@ function Demo1() {
5
5
  const { token } = theme.useToken();
6
6
  const tokenList = [token.colorTextTertiary, token.colorInfo, token.colorBgLayout];
7
7
  return (
8
- (<div>
8
+ <div>
9
9
  <Alert style={{ color: token.colorText, background: token.colorTextSecondary, backgroundColor: token.colorTextTertiary, border: `1px solid ${token.colorBorder}` }} />
10
10
  <Button style={{ color: token.colorInfo, background: token.colorSuccess, backgroundColor: token.colorWarning, borderColor: token.colorError }}></Button>
11
11
  <Tooltip color={token.colorBgContainer} backgroundColor={token.colorErrorBg} borderColor={token.colorBgLayout} border={`1px solid ${token.colorBgLayout}`} />
12
- </div>)
12
+ </div>
13
13
  );
14
14
  };
15
15
 
@@ -17,11 +17,11 @@ const Demo2 = () => {
17
17
  const { token } = theme.useToken();
18
18
  const tokenList = [token.colorTextTertiary, token.colorInfo, token.colorBgLayout];
19
19
  return (
20
- (<div>
20
+ <div>
21
21
  <Alert style={{ color: token.colorText, background: token.colorTextSecondary, backgroundColor: token.colorTextTertiary, border: `1px solid ${token.colorBorder}` }} />
22
22
  <Button style={{ color: token.colorInfo, background: token.colorSuccess, backgroundColor: token.colorWarning, borderColor: token.colorError }}></Button>
23
23
  <Tooltip color={token.colorBgContainer} backgroundColor={token.colorErrorBg} borderColor={token.colorBgLayout} border={`1px solid ${token.colorBgLayout}`} />
24
- </div>)
24
+ </div>
25
25
  );
26
26
  };
27
27
 
@@ -4,33 +4,33 @@ import { Alert, Button, token, Tooltip } from '@oceanbase/design';
4
4
  function getComponent1() {
5
5
  const tokenList = [token.colorTextTertiary, token.colorInfo, token.colorBgLayout];
6
6
  return (
7
- (<div>
7
+ <div>
8
8
  <Alert style={{ color: token.colorText, background: token.colorTextSecondary, backgroundColor: token.colorTextTertiary, border: `1px solid ${token.colorBorder}` }} />
9
9
  <Button style={{ color: token.colorInfo, background: token.colorSuccess, backgroundColor: token.colorWarning, borderColor: token.colorError }}></Button>
10
10
  <Tooltip color={token.colorBgContainer} backgroundColor={token.colorErrorBg} borderColor={token.colorBgLayout} border={`1px solid ${token.colorBgLayout}`} />
11
- </div>)
11
+ </div>
12
12
  );
13
13
  };
14
14
 
15
15
  const getComponent2 = () => {
16
16
  const tokenList = [token.colorTextTertiary, token.colorInfo, token.colorBgLayout];
17
17
  return (
18
- (<div>
18
+ <div>
19
19
  <Alert style={{ color: token.colorText, background: token.colorTextSecondary, backgroundColor: token.colorTextTertiary, border: `1px solid ${token.colorBorder}` }} />
20
20
  <Button style={{ color: token.colorInfo, background: token.colorSuccess, backgroundColor: token.colorWarning, borderColor: token.colorError }}></Button>
21
21
  <Tooltip color={token.colorBgContainer} backgroundColor={token.colorErrorBg} borderColor={token.colorBgLayout} border={`1px solid ${token.colorBgLayout}`} />
22
- </div>)
22
+ </div>
23
23
  );
24
24
  };
25
25
 
26
26
  export default () => {
27
27
  const tokenList = [token.colorTextTertiary, token.colorInfo, token.colorBgLayout];
28
28
  return (
29
- (<div>
29
+ <div>
30
30
  <Alert style={{ color: token.colorText, background: token.colorTextSecondary, backgroundColor: token.colorTextTertiary, border: `1px solid ${token.colorBorder}` }} />
31
31
  <Button style={{ color: token.colorInfo, background: token.colorSuccess, backgroundColor: token.colorWarning, borderColor: token.colorError }}></Button>
32
32
  <Tooltip color={token.colorBgContainer} backgroundColor={token.colorErrorBg} borderColor={token.colorBgLayout} border={`1px solid ${token.colorBgLayout}`} />
33
- </div>)
33
+ </div>
34
34
  );
35
35
  };
36
36
 
@@ -5,11 +5,11 @@ function useComponent1 () {
5
5
  const { token } = theme.useToken();
6
6
  const tokenList = [token.colorTextTertiary, token.colorInfo, token.colorBgLayout];
7
7
  return (
8
- (<div>
8
+ <div>
9
9
  <Alert style={{ color: token.colorText, background: token.colorTextSecondary, backgroundColor: token.colorTextTertiary, border: `1px solid ${token.colorBorder}` }} />
10
10
  <Button style={{ color: token.colorInfo, background: token.colorSuccess, backgroundColor: token.colorWarning, borderColor: token.colorError }}></Button>
11
11
  <Tooltip color={token.colorBgContainer} backgroundColor={token.colorErrorBg} borderColor={token.colorBgLayout} border={`1px solid ${token.colorBgLayout}`} />
12
- </div>)
12
+ </div>
13
13
  );
14
14
  };
15
15
 
@@ -17,11 +17,11 @@ const useComponent2 = () => {
17
17
  const { token } = theme.useToken();
18
18
  const tokenList = [token.colorTextTertiary, token.colorInfo, token.colorBgLayout];
19
19
  return (
20
- (<div>
20
+ <div>
21
21
  <Alert style={{ color: token.colorText, background: token.colorTextSecondary, backgroundColor: token.colorTextTertiary, border: `1px solid ${token.colorBorder}` }} />
22
22
  <Button style={{ color: token.colorInfo, background: token.colorSuccess, backgroundColor: token.colorWarning, borderColor: token.colorError }}></Button>
23
23
  <Tooltip color={token.colorBgContainer} backgroundColor={token.colorErrorBg} borderColor={token.colorBgLayout} border={`1px solid ${token.colorBgLayout}`} />
24
- </div>)
24
+ </div>
25
25
  );
26
26
  };
27
27
 
@@ -9,10 +9,10 @@ const Demo = () => {
9
9
  },
10
10
  }];
11
11
  return (
12
- (<div>
12
+ <div>
13
13
  <Alert style={{ color: token.colorText, background: token.colorTextSecondary, backgroundColor: token.colorTextTertiary, border: `1px solid ${token.colorBorder}` }} />
14
14
  <Button style={{ color: token.colorInfo, background: token.colorSuccess, backgroundColor: token.colorWarning, borderColor: token.colorError }}></Button>
15
- </div>)
15
+ </div>
16
16
  );
17
17
  };
18
18