on 956acfc help sign in
urbit.org/components/Section.js
21 lines 473 B history raw
1import classnames from "classnames";
3// Provides a flexible layout building block
4export default function Section({
5 children,
6 className = "",
7 short = false,
8 narrow = false,
9}) {
10 const spacing = classnames({
11 "py-6 md:py-8 lg:py-10": short,
12 "py-10 md:py-12 lg:py-24": !short,
13 "md:w-8/12": narrow,
14 "md:w-10/12": !narrow,
15 });
16 return (
17 <section className={`w-full px-4 md:px-8 ${spacing} ${className}`}>
18 {children}
19 </section>
20 );