aboutsummaryrefslogtreecommitdiff
path: root/src/components/Frame.tsx
diff options
context:
space:
mode:
authorNikita Tchayka <nikitatchayka@gmail.com>2023-09-14 23:01:22 +0100
committerNikita Tchayka <nikitatchayka@gmail.com>2023-09-14 23:01:22 +0100
commit71dfeb721d271dd58c5e2f4f26cff1fe407eef80 (patch)
tree2065223910ccd8a49b4d05a6ce2d3425715835ec /src/components/Frame.tsx
parentb32489e304cc34ce965ae4f5027a7ba374cea173 (diff)
downloadneohaskell.github.io-71dfeb721d271dd58c5e2f4f26cff1fe407eef80.tar.gz
neohaskell.github.io-71dfeb721d271dd58c5e2f4f26cff1fe407eef80.tar.bz2
neohaskell.github.io-71dfeb721d271dd58c5e2f4f26cff1fe407eef80.zip
Start roadmap
Diffstat (limited to 'src/components/Frame.tsx')
-rw-r--r--src/components/Frame.tsx6
1 files changed, 5 insertions, 1 deletions
diff --git a/src/components/Frame.tsx b/src/components/Frame.tsx
index 62467b6..6f858ba 100644
--- a/src/components/Frame.tsx
+++ b/src/components/Frame.tsx
@@ -6,6 +6,7 @@ type FrameType = {
children?: ReactElement | ReactElement[];
rainbow?: boolean;
shadowClass?: string;
+ background?: string;
width?: "fit" | "full" | "1/2" | "1/3";
};
@@ -34,11 +35,14 @@ const Frame = ({
children,
width,
shadowClass = "shadow-neoblack",
+ background = "bg-white",
}: FrameType) => {
const s = rainbow
? classes.filter((c) => !c.includes("shadow")).concat("shadow-rainbow")
: classes;
- const cls = [...s, `${widthClasses[width]}`, shadowClass].join(" ");
+ const cls = [...s, `${widthClasses[width]}`, shadowClass, background].join(
+ " "
+ );
return <div className={cls}>{children}</div>;
};