diff --git a/html/chessboard.tsx b/html/chessboard.tsx index 3418785..c1ffc08 100644 --- a/html/chessboard.tsx +++ b/html/chessboard.tsx @@ -95,6 +95,7 @@ const Pieces = () => { render_and_copy(
+ @@ -103,7 +104,6 @@ render_and_copy( -
, true ); diff --git a/html/pixels.tsx b/html/pixels.tsx new file mode 100644 index 0000000..b4de922 --- /dev/null +++ b/html/pixels.tsx @@ -0,0 +1,63 @@ +import { ComponentChildren, JSX } from "preact"; +import { Main, render_and_copy } from "./common.tsx"; + +// kind of made this not generic :( +const Toggle = ({ a, b }: { a: JSX.Element; b: JSX.Element }) => ( +
+ +
+ {a} +
+
+
+ {b} +
+
+); + +const Pixel = ({ color_a, color_b }: { color_a: string; color_b: string }) => ( + + } + b={ +
+ } + /> +); + +render_and_copy( +
+ + + + + + + + + + + + + + + + +
+);