diff --git a/components/navbar.tsx b/components/navbar.tsx new file mode 100644 index 0000000..dfee8e8 --- /dev/null +++ b/components/navbar.tsx @@ -0,0 +1,49 @@ +import { h, tw } from "../deps.ts"; + +const NavBar = ( + props: { + size?: "small" | "large"; + theme?: "light" | "dark"; + }, +) => { + const { size = "large", theme = "light" } = props; + let bgColor, textColor, padding, imageSize, textSize; + if (theme === "light") { + bgColor = "bg-white"; + textColor = "text-black"; + } else { + bgColor = "bg-black"; + textColor = "text-white"; + } + if (size === "small") { + padding = "p-5"; + imageSize = "h-16"; + textSize = "text-4xl"; + } else { + padding = "p-6"; + imageSize = "h-20"; + textSize = "text-5xl"; + } + + return ( +
+ Harmony{" "} +
++ by Example +
+