Skip to content

Commit 6c97eac

Browse files
committed
[-]: docs lint 파이프라인 복구
1 parent fa14c71 commit 6c97eac

7 files changed

Lines changed: 127 additions & 109 deletions

File tree

packages/document/.eslintrc.json

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,7 @@
11
{
22
"extends": [
3-
"next/babel",
43
"next/core-web-vitals",
54
"plugin:prettier/recommended",
65
"plugin:tailwindcss/recommended"
76
]
8-
}
7+
}

packages/document/package.json

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,7 @@
44
"private": true,
55
"scripts": {
66
"dev": "next dev",
7+
"prebuild": "pnpm -C ../main build",
78
"build": "next build",
89
"start": "next start",
910
"lint": "next lint"
@@ -30,7 +31,7 @@
3031
"@types/prismjs": "^1.26.3",
3132
"@types/react": "^18.0.15",
3233
"@types/react-dom": "^18.0.6",
33-
"eslint": "^9.1.0",
34+
"eslint": "^8.57.0",
3435
"eslint-config-next": "14.2.2",
3536
"eslint-config-prettier": "^9.1.0",
3637
"eslint-plugin-prettier": "^5.1.3",
@@ -41,4 +42,4 @@
4142
"tailwindcss": "^3.4.1",
4243
"typescript": "^5.4.5"
4344
}
44-
}
45+
}

packages/document/src/components/code.tsx

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -111,7 +111,7 @@ export const Code: React.FC<{
111111
className={clsx(
112112
props.className,
113113
className,
114-
'items flex h-full w-full flex-col justify-center overflow-x-auto rounded-lg p-4',
114+
'flex size-full flex-col justify-center overflow-x-auto rounded-lg p-4',
115115
)}
116116
style={style}
117117
>
@@ -121,9 +121,9 @@ export const Code: React.FC<{
121121
}
122122

123123
return (
124-
<div {...getLineProps({ line, key: i })}>
124+
<div key={i} {...getLineProps({ line, key: i })}>
125125
{line.map((token, key) => (
126-
<span {...getTokenProps({ token, key })} />
126+
<span key={key} {...getTokenProps({ token, key })} />
127127
))}
128128
</div>
129129
);

packages/document/src/components/docs-layout.tsx

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -21,7 +21,7 @@ const TableHeader: React.FC<{
2121

2222
export default function DocsLayout({ children }: { children?: React.ReactNode }) {
2323
return (
24-
<div className="flex min-h-screen flex-col bg-white bg-opacity-50">
24+
<div className="flex min-h-screen flex-col bg-white/50">
2525
<div className="mx-auto w-full max-w-4xl flex-1 px-2">
2626
<header className=" col-start-1 col-end-6 mb-16 mt-12 flex items-center justify-between px-2">
2727
<Link href="/">React Tutorial Overlay</Link>
@@ -49,7 +49,7 @@ export default function DocsLayout({ children }: { children?: React.ReactNode })
4949
</div>
5050
</nav>
5151

52-
<main className="prose-tutorial prose col-span-4 w-full flex-1 text-tutorial-900">{children}</main>
52+
<main className="prose col-span-4 w-full flex-1 text-tutorial-900">{children}</main>
5353
</div>
5454
</div>
5555
<Footer />

packages/document/src/pages/_app.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,7 @@ const components: MDXComponents = {
1818
props.className ? (
1919
<Code className={props.className} snippet={props.children as string} />
2020
) : (
21-
<code className="my-0.5 rounded bg-tutorial-300 bg-opacity-40 px-1 py-1" {...props} />
21+
<code className="my-0.5 rounded bg-tutorial-300/40 p-1" {...props} />
2222
),
2323
};
2424

packages/document/src/pages/index.tsx

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -29,18 +29,18 @@ export default function Home() {
2929
description="A headless library that makes it easy to put tutorials on top of the screen."
3030
/>
3131
<div className="container prose mx-auto flex flex-col items-center justify-center">
32-
<h1 className="my-[5rem]">React Tutorial Overlay</h1>
32+
<h1 className="my-20">React Tutorial Overlay</h1>
3333
<div className="flex gap-4">
3434
<button
3535
id="button-open"
3636
onClick={handleClick}
37-
className="rounded-md bg-tutorial-600 px-[1rem] py-[0.5rem] text-tutorial-50"
37+
className="rounded-md bg-tutorial-600 px-4 py-2 text-tutorial-50"
3838
>
3939
Start tutorial
4040
</button>
4141
<button
4242
id="button-docs"
43-
className="rounded-md bg-tutorial-600 px-[1rem] py-[0.5rem] text-tutorial-50"
43+
className="rounded-md bg-tutorial-600 px-4 py-2 text-tutorial-50"
4444
onClick={() => router.push('/docs')}
4545
>
4646
Documentation

0 commit comments

Comments
 (0)