WIP
This commit is contained in:
@@ -1,7 +1,11 @@
|
||||
import { Component } from "solid-js";
|
||||
import { Component, createSignal } from "solid-js";
|
||||
import { Handlers } from "../../types";
|
||||
import "./Load.css";
|
||||
|
||||
const Load: Component = () => {
|
||||
const Load: Component<{ handlers: Handlers }> = (props) => {
|
||||
const [fen, setFEN] = createSignal("");
|
||||
const [pgn, setPGN] = createSignal("");
|
||||
|
||||
return (
|
||||
<div class="load">
|
||||
<input
|
||||
@@ -10,8 +14,15 @@ const Load: Component = () => {
|
||||
name="load-fen"
|
||||
placeholder="PASTE FEN..."
|
||||
spellcheck={false}
|
||||
value={fen()}
|
||||
onInput={(e) => setFEN(e.currentTarget.value)}
|
||||
/>
|
||||
<button class="load__fen-btn">LOAD FEN</button>
|
||||
<button
|
||||
class="load__fen-btn"
|
||||
onClick={() => props.handlers.loadFEN(fen())}
|
||||
>
|
||||
LOAD FEN
|
||||
</button>
|
||||
<textarea
|
||||
class="load__pgn-input"
|
||||
name="load-pgn"
|
||||
|
||||
Reference in New Issue
Block a user