Skip to content

Commit 9c5b664

Browse files
committed
Refactor
& fix syntax highlighter
1 parent 455ba52 commit 9c5b664

File tree

23 files changed

+163
-135
lines changed

23 files changed

+163
-135
lines changed

README.md

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -82,7 +82,7 @@ Devup UI is a CSS in JS preprocessor that does not require runtime.
8282
Devup UI eliminates the performance degradation of the browser through the CSS in JS preprocessor.
8383
We develop a preprocessor that considers all grammatical cases.
8484

85-
```jsx
85+
```typescript
8686
// Before
8787
<Box bg={"red"}/>
8888
// After
@@ -91,7 +91,7 @@ We develop a preprocessor that considers all grammatical cases.
9191

9292
Variables are fully supported.
9393

94-
```jsx
94+
```typescript
9595
// Before
9696
<Box bg={colorVariable}/>
9797
// After
@@ -102,7 +102,7 @@ Variables are fully supported.
102102

103103
Various expressions and responsiveness are also fully supported.
104104

105-
```jsx
105+
```typescript
106106
// Before
107107
<Box bg={["red", "blue", a > b ? "yellow" : variable]}/>
108108
// After
@@ -130,7 +130,7 @@ Support Theme with Typing
130130
}
131131
```
132132

133-
```jsx
133+
```typescript
134134
// Type Safe
135135
<Text color="$text"/>
136136
```
@@ -139,7 +139,7 @@ Support Responsive And Pseudo Selector
139139

140140
You can use responsive and pseudo selector.
141141

142-
```jsx
142+
```typescript
143143
// Responsive with Selector
144144
<Box _hover={{bg: ["red", "blue"]}}/>
145145

README_ko.md

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -82,7 +82,7 @@ Devup UI는 런타임이 필요 없는 CSS in JS 전처리기입니다.
8282
Devup UI는 CSS in JS 전처리기를 통하여 브라우저의 성능 저하를 원천적으로 제거합니다.
8383
모든 문법적 경우의 수를 고려하여 전처리기를 개발합니다.
8484

85-
```jsx
85+
```typescript
8686
// Before
8787
<Box bg={"red"}/>
8888
// After
@@ -91,7 +91,7 @@ Devup UI는 CSS in JS 전처리기를 통하여 브라우저의 성능 저하를
9191

9292
변수 사용도 완전히 지원합니다.
9393

94-
```jsx
94+
```typescript
9595
// Before
9696
<Box bg={colorVariable}/>
9797
// After
@@ -102,7 +102,7 @@ Devup UI는 CSS in JS 전처리기를 통하여 브라우저의 성능 저하를
102102

103103
다양한 표현식과 반응형도 모두 지원합니다.
104104

105-
```jsx
105+
```typescript
106106
// Before
107107
<Box bg={["red", "blue", a > b ? "yellow" : variable]}/>
108108
// After
@@ -130,7 +130,7 @@ Devup UI는 CSS in JS 전처리기를 통하여 브라우저의 성능 저하를
130130
}
131131
```
132132

133-
```jsx
133+
```typescript
134134
// Type Safe
135135
<Text color="$text"/>
136136
```
@@ -139,7 +139,7 @@ Devup UI는 CSS in JS 전처리기를 통하여 브라우저의 성능 저하를
139139

140140
물론 동시 사용도 가능합니다.
141141

142-
```jsx
142+
```typescript
143143
// Responsive with Selector
144144
<Box _hover={{bg: ["red", "blue"]}}/>
145145

apps/landing/src/app/(detail)/components/MdxCard.tsx

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -46,12 +46,12 @@ export default async function MdxCard({
4646
borderRadius: '10px',
4747
border: '1px solid $border',
4848
bg: '$containerBackground',
49-
maxWidth: '100%',
49+
maxW: '100%',
5050
flexShrink: 0,
5151
cursor: 'default',
52-
marginBottom: '20px',
52+
mb: '20px',
5353
_lastChild: {
54-
marginBottom: '0',
54+
mb: '0',
5555
},
5656
typography: 'bodyReg',
5757
color: '$text',
@@ -65,7 +65,7 @@ export default async function MdxCard({
6565
</ReactMarkdown>
6666
</VStack>
6767
<MdxCardFooter>
68-
<Code language="tsx" value={code} />
68+
<Code language="typescript" value={code} />
6969
</MdxCardFooter>
7070
</Card>
7171
)

apps/landing/src/app/(detail)/docs/api/box/page.mdx

Lines changed: 6 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -14,20 +14,16 @@ It is just a `div` with some styles.
1414

1515
## How to use
1616

17-
```jsx
18-
// Before
19-
<Box bg={"red"} />
17+
```typescript
18+
const before = <Box bg={"red"} />
2019

21-
// After
22-
<div className="d0" />
20+
const after = <div className="d0" />
2321
```
2422

2523
You can use the `as` prop to change the element type.
2624

27-
```jsx
28-
// Before
29-
<Box as={"span"} />
25+
```typescript
26+
const before = <Box as={"span"} />
3027

31-
// After
32-
<span className="d0" />
28+
const after = <span className="d0" />
3329
```

apps/landing/src/app/(detail)/docs/api/button/page.mdx

Lines changed: 3 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -12,10 +12,8 @@ The `Button` component is a simple button component that can be used to trigger
1212

1313
## How to use
1414

15-
```jsx
16-
// Before
17-
<Button bg={"red"} />
15+
```typescript
16+
const before = <Button bg={"red"} />
1817

19-
// After
20-
<button className="d0" />
18+
const after = <button className="d0" />
2119
```

apps/landing/src/app/(detail)/docs/api/center/page.mdx

Lines changed: 9 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -13,18 +13,20 @@ It has a `display: flex` style with `justify-content: center` and `align-items:
1313

1414
## How to use
1515

16-
````jsx
17-
// Before
18-
<Center>
16+
````typescript
17+
const before = (
18+
<Center>
1919
<Box bg="blue" w={25} h={25} />
2020
<Box bg="blue" w={25} h={25} />
2121
<Box bg="blue" w={25} h={25} />
22-
</Center>
22+
</Center>
23+
)
2324

24-
// After, It has 3 classes on default
25-
<div className="d3 d4 d5">
25+
const after = (
26+
<div className="d3 d4 d5">
2627
<div className="d0 d1 d2"></div>
2728
<div className="d0 d1 d2"></div>
2829
<div className="d0 d1 d2"></div>
29-
</div>```
30+
</div>
31+
)
3032
````

apps/landing/src/app/(detail)/docs/api/css/page.mdx

Lines changed: 20 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -17,26 +17,31 @@ export const metadata = {
1717
You can use `css` as a tag function to create a css string. Pass in a string of css properties as an argument, ans it will be converted
1818
into a class list.
1919

20-
```jsx
21-
// Before
22-
<any className={css`
23-
color: red;
24-
`}/>
25-
26-
// After
27-
<any className="d0"/>
20+
```typescript
21+
const before = (
22+
<div
23+
className={css`
24+
color: red;
25+
`}
26+
/>
27+
)
28+
29+
const after = <any className="d0"/>
30+
2831
```
2932

3033
### CSS Object
3134

3235
You can also use the css function by passing in a css object as an argument.
3336

34-
```jsx
35-
// Before
36-
<any className={css({
37-
color: "red"
38-
})}/>
37+
```typescript
38+
const before = (
39+
<any
40+
className={css({
41+
color: 'red',
42+
})}
43+
/>
44+
)
3945

40-
// After
41-
<any className="d0" />
46+
const after = <any className="d0" />
4247
```

apps/landing/src/app/(detail)/docs/api/flex/page.mdx

Lines changed: 3 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -14,10 +14,8 @@ It has a `display: flex` style by default.
1414

1515
## How to use
1616

17-
```jsx
18-
// Before
19-
<Flex />
17+
```typescript
18+
const before = <Flex />
2019

21-
// After, it has a class on default
22-
<div className="d0" />
20+
const after = <div className="d0" />
2321
```

apps/landing/src/app/(detail)/docs/api/grid/page.mdx

Lines changed: 9 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -14,19 +14,21 @@ It has a `display: grid` style by default.
1414

1515
## How to use
1616

17-
````jsx
18-
// Before
19-
<Grid>
17+
````typescript
18+
const before = (
19+
<Grid>
2020
<Box bg="blue" w={25} h={25} />
2121
<Box bg="blue" w={25} h={25} />
2222
<Box bg="blue" w={25} h={25} />
23-
</Grid>
23+
</Grid>
24+
)
2425

25-
// After, It has a class on default
26-
<div className="d3">
26+
const after = (
27+
<div className="d3">
2728
<div className="d0 d1 d2"></div>
2829
<div className="d0 d1 d2"></div>
2930
<div className="d0 d1 d2"></div>
30-
</div>
31+
</div>
32+
)
3133
```
3234
````

apps/landing/src/app/(detail)/docs/api/group-selector/page.mdx

Lines changed: 8 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -12,10 +12,12 @@ The `group` selector is used to apply styles to a group of elements. It is used
1212

1313
## How to use
1414

15-
```jsx
16-
<div role="group">
17-
<Box _groupHover={{ bg: 'red' }} />
18-
<Box _groupHover={{ bg: 'red' }} />
19-
<Box _groupHover={{ bg: 'red' }} />
20-
</div>
15+
```typescript
16+
const group = (
17+
<div role="group">
18+
<Box _groupHover={{ bg: 'red' }} />
19+
<Box _groupHover={{ bg: 'red' }} />
20+
<Box _groupHover={{ bg: 'red' }} />
21+
</div>
22+
)
2123
```

0 commit comments

Comments
 (0)