mirror of
https://github.com/remvze/moodist.git
synced 2025-09-29 15:30:49 -04:00
refactor: add variant to container
This commit is contained in:
parent
f66a6ffde7
commit
831a9c8ea0
@ -35,9 +35,6 @@
|
||||
}
|
||||
|
||||
& .desc {
|
||||
width: 100%;
|
||||
max-width: 450px;
|
||||
margin: 0 auto;
|
||||
line-height: 1.6;
|
||||
color: var(--color-foreground-subtle);
|
||||
text-align: center;
|
||||
|
@ -18,7 +18,7 @@ export function About() {
|
||||
|
||||
return (
|
||||
<section className={styles.about}>
|
||||
<Container>
|
||||
<Container tight>
|
||||
<div className={styles.iconContainer}>
|
||||
<div className={styles.tail} />
|
||||
<div className={styles.icon}>
|
||||
|
@ -2,4 +2,8 @@
|
||||
width: 90%;
|
||||
max-width: 600px;
|
||||
margin: 0 auto;
|
||||
|
||||
&.tight {
|
||||
max-width: 450px;
|
||||
}
|
||||
}
|
||||
|
@ -5,8 +5,13 @@ import styles from './container.module.css';
|
||||
interface ContainerProps {
|
||||
children: React.ReactNode;
|
||||
className?: string;
|
||||
tight?: boolean;
|
||||
}
|
||||
|
||||
export function Container({ children, className }: ContainerProps) {
|
||||
return <div className={cn(styles.container, className)}>{children}</div>;
|
||||
export function Container({ children, className, tight }: ContainerProps) {
|
||||
return (
|
||||
<div className={cn(styles.container, className, tight && styles.tight)}>
|
||||
{children}
|
||||
</div>
|
||||
);
|
||||
}
|
||||
|
Loading…
x
Reference in New Issue
Block a user