diff --git a/src/App.tsx b/src/App.tsx index ea78823..e695775 100644 --- a/src/App.tsx +++ b/src/App.tsx @@ -30,7 +30,7 @@ function App() { key={i} srcObject={blob} picked={picked.includes(blob)} - onPick={() => setPicked((prev) => toggle(prev, blob))} + onPick={() => setPicked((prev) => [blob, ...prev])} /> ))} @@ -39,10 +39,4 @@ function App() { ); } -function toggle(list: T[], item: T): T[] { - return list.includes(item) - ? list.filter((each) => each !== item) - : [...list, item]; -} - export default App; diff --git a/src/index.css b/src/index.css index 6119ad9..9a5f0a6 100644 --- a/src/index.css +++ b/src/index.css @@ -25,7 +25,6 @@ a:hover { body { margin: 0; display: flex; - place-items: center; min-width: 320px; min-height: 100vh; } @@ -33,6 +32,12 @@ body { h1 { font-size: 3.2em; line-height: 1.1; + font-weight: 100; +} +h2, +h3, +h4 { + font-weight: 100; } button {