Skip to content

Commit bd44c51

Browse files
authored
Merge pull request #142 from Team-INSERT/refactor/toastify
refactor : Toastify 컴포넌트 리팩터링
2 parents 1b207ce + bb49d5b commit bd44c51

File tree

3 files changed

+8
-29
lines changed

3 files changed

+8
-29
lines changed

app/globals.css

Lines changed: 2 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -143,13 +143,11 @@ button {
143143

144144
/* toastify */
145145

146-
.toastify {
147-
margin-top: 30px;
148-
}
149-
150146
.toastify .Toastify__toast {
151147
background-color: white;
148+
top: 40px;
152149
right: 80px;
153150
width: 400px;
154151
color: #274168;
152+
border-radius: 0px;
155153
}

components/Toastify/index.tsx

Lines changed: 4 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -3,13 +3,10 @@ import * as styles from "./style.css";
33

44
const Toastify = ({ content }: { content: string }) => {
55
return (
6-
<div className={styles.container}>
7-
<div className={styles.contentBox}>
8-
<Image width={999} height={999} className={styles.icon} src="/assets/info.png" alt="INFO" />
9-
<div className={styles.content}>{content}</div>
10-
</div>
11-
<div className={styles.sideBar} />
12-
</div>
6+
<figure className={styles.container}>
7+
<Image width={24} height={24} src="/assets/info.png" alt="INFO" />
8+
<figcaption className={styles.content}>{content}</figcaption>
9+
</figure>
1310
);
1411
};
1512

components/Toastify/style.css.ts

Lines changed: 2 additions & 18 deletions
Original file line numberDiff line numberDiff line change
@@ -8,29 +8,13 @@ export const container = style({
88
position: "absolute",
99
top: "0",
1010
left: "0",
11-
...flex.FLEX,
12-
});
13-
14-
export const contentBox = style({
15-
width: "100%",
11+
borderRight: `8px solid ${theme.primary}`,
1612
gap: "5%",
1713
padding: "5%",
1814
...flex.VERTICAL,
1915
});
2016

2117
export const content = style({
22-
...font.p1,
23-
fontWeight: "700",
18+
...font.H5,
2419
...flex.BETWEEN,
2520
});
26-
27-
export const sideBar = style({
28-
width: "4%",
29-
height: "100%",
30-
backgroundColor: theme.primary,
31-
});
32-
33-
export const icon = style({
34-
width: "23px",
35-
height: "23px",
36-
});

0 commit comments

Comments
 (0)