Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat: [LINKER-23] vanilla extract global style 설정 #8

Merged
merged 9 commits into from
Dec 14, 2023
2 changes: 1 addition & 1 deletion .yarn/sdks/typescript/package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "typescript",
"version": "5.2.2-sdk",
"version": "5.3.2-sdk",
"main": "./lib/typescript.js",
"type": "commonjs",
"bin": {
Expand Down
2 changes: 1 addition & 1 deletion services/web/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -51,4 +51,4 @@
"msw": {
"workerDirectory": "public"
}
}
}
1 change: 1 addition & 0 deletions services/web/src/app/layout.tsx
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
import type { Metadata } from 'next';
import { Inter } from 'next/font/google';
import '../../src/styles/global.css';

const inter = Inter({ subsets: ['latin'] });

Expand Down
7 changes: 6 additions & 1 deletion services/web/src/app/page.tsx
Original file line number Diff line number Diff line change
@@ -1,3 +1,8 @@
export default function Home() {
return <main>Linker🚀</main>;
return (
<div>
<main>Linker🚀</main>
<button>Linker</button>
</div>
);
}
38 changes: 38 additions & 0 deletions services/web/src/styles/global.css.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1,38 @@
import { globalStyle } from '@vanilla-extract/css';

export const GlobalStyle = [
globalStyle('html', {
fontSize: '62.5%',
margin: 0,
padding: 0,
overflowX: 'hidden',
height: '100%',
}),
globalStyle('body', {
margin: 0,
padding: 0,
overflowX: 'hidden',
fontSize: '1.6rem',
}),
globalStyle('*, *:before, *:after', {
boxSizing: 'border-box',
}),
globalStyle('focus', {
outline: 'none',
border: 'none',
}),
globalStyle('button', {
background: 'none',
padding: 0,
border: 'none',
cursor: 'pointer',
}),
globalStyle('a', {
color: 'inherit',
textDecoration: 'none',
cursor: 'pointer',
}),
globalStyle('table', { borderCollapse: 'collapse', borderSpacing: 0 }),

globalStyle('img, picture, video, canvas, svg ', { display: 'block', maxWidth: '100%' }),
];
Loading