Skip to content

Commit 13d08e1

Browse files
committed
fix lint errors, build errors
1 parent b49a09c commit 13d08e1

File tree

8 files changed

+581
-796
lines changed

8 files changed

+581
-796
lines changed

packages/chakra-ui/package.json

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -29,7 +29,8 @@
2929
},
3030
"scripts": {
3131
"build": "../dev/bin.mjs build",
32-
"lint": "../dev/bin.mjs lint"
32+
"lint": "../dev/bin.mjs lint",
33+
"fix": "../dev/bin.mjs fix"
3334
},
3435
"dependencies": {
3536
"@moblin/core": "workspace:*"

packages/chakra-ui/src/Flex.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,8 @@
11
import {
22
chakra,
33
forwardRef,
4-
SystemProps,
54
type MergeWithAs,
5+
SystemProps,
66
} from "@chakra-v2/react";
77
import {
88
__DEV__,

packages/dev/bin.mjs

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -55,6 +55,10 @@ try {
5555
if (command === "lint") {
5656
await $`eslint -c eslint.config.ts src/**/*`;
5757
}
58+
59+
if (command === "fix") {
60+
await $`eslint -c eslint.config.ts src/**/* --fix`;
61+
}
5862
} catch (error) {
5963
if (error instanceof ProcessOutput) {
6064
// console.error(error.stderr);

packages/dev/package.json

Lines changed: 13 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -7,21 +7,21 @@
77
"dev": "./bin.mjs"
88
},
99
"dependencies": {
10-
"@eslint/js": "^9.18.0",
11-
"concurrently": "^9.1.0",
10+
"@eslint/js": "^9.37.0",
11+
"concurrently": "^9.2.1",
1212
"cross-env": "^7.0.3",
13-
"eslint": "^9.18.0",
14-
"eslint-config-prettier": "^10.0.1",
15-
"eslint-plugin-prettier": "^5.2.3",
16-
"eslint-plugin-react": "^7.37.4",
17-
"eslint-plugin-react-hooks": "^5.1.0",
13+
"eslint": "^9.37.0",
14+
"eslint-config-prettier": "^10.1.8",
15+
"eslint-plugin-prettier": "^5.5.4",
16+
"eslint-plugin-react": "^7.37.5",
17+
"eslint-plugin-react-hooks": "^5.2.0",
1818
"eslint-plugin-simple-import-sort": "^12.1.1",
19-
"globals": "^15.14.0",
20-
"jiti": "^2.4.2",
21-
"lint-staged": "^15.2.10",
22-
"prettier": "^3.3.3",
19+
"globals": "^15.15.0",
20+
"jiti": "^2.6.1",
21+
"lint-staged": "^15.5.2",
22+
"prettier": "^3.6.2",
2323
"rimraf": "^6.0.1",
24-
"typescript-eslint": "^8.21.0",
25-
"zx": "^8.3.0"
24+
"typescript-eslint": "^8.46.1",
25+
"zx": "^8.8.4"
2626
}
2727
}

packages/storybook-chakra-ui/src/Box.gen.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
import { Meta } from "@storybook/react";
22
import { Box } from "@moblin/chakra-ui";
33
import { demo } from "./animatable-demo";
4-
import { chakra, HTMLChakraProps } from "@chakra-ui/system";
4+
import { chakra, HTMLChakraProps } from "@chakra-v2/react";
55

66
const meta: Meta = {
77
component: Box,

packages/storybook-chakra-ui/src/Scrollable.gen.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@ import { Meta } from "@storybook/react";
22

33
import { Scrollable, ScrollableProps } from "@moblin/chakra-ui";
44
import { demo } from "./animatable-demo";
5-
import { chakra } from "@chakra-ui/system";
5+
import { chakra } from "@chakra-v2/react";
66
import { FlexDirection } from "@moblin/core";
77

88
const meta: Meta<ScrollableProps & { overflow: boolean }> = {
Lines changed: 30 additions & 30 deletions
Original file line numberDiff line numberDiff line change
@@ -1,63 +1,63 @@
1-
import { chakra, HTMLChakraProps, keyframes } from '@chakra-ui/system';
2-
import isChromatic from 'chromatic/isChromatic';
1+
import { chakra, HTMLChakraProps } from "@chakra-v2/react";
2+
import isChromatic from "chromatic/isChromatic";
3+
import { keyframes } from "@emotion/react";
34

4-
import * as S from './storybook.js';
5+
import * as S from "./storybook.js";
56

67
interface DemoOptions {
78
title?: string;
89
animate?: boolean;
910
}
1011

1112
const resize = keyframes({
12-
'0%': {
13-
width: '12rem',
14-
height: '12rem',
13+
"0%": {
14+
width: "12rem",
15+
height: "12rem",
1516
},
16-
'50%': {
17-
width: '24rem',
18-
height: '24rem',
17+
"50%": {
18+
width: "24rem",
19+
height: "24rem",
1920
},
20-
'100%': {
21-
width: '12rem',
22-
height: '12rem',
21+
"100%": {
22+
width: "12rem",
23+
height: "12rem",
2324
},
2425
});
2526

2627
const DemoContainer = ({
2728
title,
2829
animate,
2930
...props
30-
}: DemoOptions & HTMLChakraProps<'div'>) => (
31+
}: DemoOptions & HTMLChakraProps<"div">) => (
3132
<chakra.div
3233
{...props}
3334
position="relative"
3435
padding={8}
3536
bg="green.300"
3637
color="black"
3738
__css={{
38-
'& > div:first-of-type': {
39-
width: '12rem',
40-
height: '12rem',
41-
willChange: 'width, height',
42-
animationName: animate ? resize.toString() : 'none',
43-
animationDuration: '2s',
44-
animationIterationCount: 'infinite',
39+
"& > div:first-of-type": {
40+
width: "12rem",
41+
height: "12rem",
42+
willChange: "width, height",
43+
animationName: animate ? resize.toString() : "none",
44+
animationDuration: "2s",
45+
animationIterationCount: "infinite",
4546
},
4647
}}
4748
/>
4849
);
4950

5051
export const demo =
5152
({
52-
title = 'Container',
53+
title = "Container",
5354
animate = !isChromatic(),
5455
}: DemoOptions = {}): S.Decorator =>
55-
(Story) =>
56-
(
57-
<DemoContainer animate={animate}>
58-
<Story />
59-
<chakra.div position="absolute" top="0.5rem" left="0.5rem">
60-
{title}
61-
</chakra.div>
62-
</DemoContainer>
63-
);
56+
(Story) => (
57+
<DemoContainer animate={animate}>
58+
<Story />
59+
<chakra.div position="absolute" top="0.5rem" left="0.5rem">
60+
{title}
61+
</chakra.div>
62+
</DemoContainer>
63+
);

0 commit comments

Comments
 (0)