emojis: honestly not bad

This commit is contained in:
mehbark 2023-11-28 01:12:14 -05:00
parent 9360a02965
commit 81b2299a02

41
html/emoji-land.tsx Normal file
View file

@ -0,0 +1,41 @@
import { Cycle, render_and_copy } from "./common.tsx";
const emojis = [
"🏡",
"🌳",
"🌲",
"🎄",
"🐦",
"🦊",
"🐻",
"🐶",
"🐕",
"🐩",
"🦈",
];
const Emoji = ({ children }: { children: string }) => <div>{children}</div>;
const Cell = () => (
<Cycle width_px={60} height_px={60} style={{}}>
<Emoji> </Emoji>
{...emojis.map(e => <Emoji>{e}</Emoji>)}
</Cycle>
);
render_and_copy(
<div
style={{
width: "calc(60px * 7)",
aspectRatio: "1",
margin: "0 auto",
display: "grid",
gridTemplateColumns: "repeat(7, 1fr)",
fontSize: "40px",
outline: "1px solid black",
backgroundColor: "#296639",
}}
>
{...Array.from({ length: 49 }, () => <Cell />)}
</div>
);