diff --git a/src/editor/js/components/editor.tsx b/src/editor/js/components/editor.tsx index 1501825d7c0d68813bf9fcba90c74bb530a7848b..912c06dd654f799ce5abad409eb37790455958b6 100644 --- a/src/editor/js/components/editor.tsx +++ b/src/editor/js/components/editor.tsx @@ -1,9 +1,8 @@ import React from "react"; import { State } from "../state"; import * as Interactions from "../interactions"; -import { Graph, GraphData } from "../structures/graph/graph"; +import { Graph } from "../structures/graph/graph"; import { loadGraphJson } from "../../../datasets"; -import { ToolPool } from "./toolpool"; import { ToolDetails } from "./tooldetails"; import { SpaceSelect } from "./spaceselect"; import "./editor.css"; @@ -187,9 +186,6 @@ export class Editor extends React.PureComponent<propTypes, stateTypes> { historyObject={this.state.graph} onChange={this.onHistoryChange} /> - - <hr /> - <ToolPool state={this.state.state} /> <hr /> <ToolDetails /> </div> diff --git a/src/editor/js/components/toolbutton.css b/src/editor/js/components/toolbutton.css deleted file mode 100644 index 7151b39dd072242072a3e6d76e72b254b7bfdb46..0000000000000000000000000000000000000000 --- a/src/editor/js/components/toolbutton.css +++ /dev/null @@ -1,9 +0,0 @@ -div#ks-editor #toolpool > button { - margin: 0.25rem; -} - -div#ks-editor #toolpool > button > img { - max-height: 20px; - height: 20px; - width: auto; -} \ No newline at end of file diff --git a/src/editor/js/components/toolbutton.tsx b/src/editor/js/components/toolbutton.tsx deleted file mode 100644 index d344b487c046cfdde5b8675caeb50a17b99185de..0000000000000000000000000000000000000000 --- a/src/editor/js/components/toolbutton.tsx +++ /dev/null @@ -1,26 +0,0 @@ -import { InferType } from "prop-types"; -import React from "react"; -import "./toolbutton.css"; - -type propTypes = { - title: string; - icon: string; -}; - -export class ToolButton extends React.PureComponent< - propTypes, - InferType<typeof ToolButton.stateTypes> -> { - static stateTypes = {}; - - render(): React.ReactNode { - return ( - <button - title={this.props.title} - // onClick={() => this.props.state.setTool(this.props.tool)} - > - <img src={this.props.icon} /> - </button> - ); - } -} diff --git a/src/editor/js/components/toolpool.css b/src/editor/js/components/toolpool.css deleted file mode 100644 index 77dd26aa2827e5a471abb03ba41d2aabcb476110..0000000000000000000000000000000000000000 --- a/src/editor/js/components/toolpool.css +++ /dev/null @@ -1,5 +0,0 @@ -div#ks-editor #toolpool { - display: flex; - flex-wrap: wrap; - justify-content: space-evenly; -} \ No newline at end of file diff --git a/src/editor/js/components/toolpool.tsx b/src/editor/js/components/toolpool.tsx deleted file mode 100644 index 545f05333712c64e60c6e47e74517af4d5bc36d3..0000000000000000000000000000000000000000 --- a/src/editor/js/components/toolpool.tsx +++ /dev/null @@ -1,87 +0,0 @@ -import { InferType } from "prop-types"; -import React from "react"; -import { State } from "../state"; -import { ToolButton } from "./toolbutton"; -import wand from "../../images/tools/wand.png"; -import "./toolpool.css"; - -type propTypes = { - state: State; -}; - -export class ToolPool extends React.PureComponent< - propTypes, - InferType<typeof ToolPool.stateTypes> -> { - static stateTypes = {}; - - constructor(props: propTypes) { - super(props); - } - - render(): React.ReactNode { - // Don't render anything if state is not defined - // TODO: Reactivate code later. Was commented to work on the proper toolpool render - // if (!this.state) { - // return <div id="toolpool"></div>; - // } - - return ( - <div id="toolpool"> - <ToolButton - icon={wand} - title="Example Tools" - key="1" - ></ToolButton> - <ToolButton - icon={wand} - title="Example Tool" - key="2" - ></ToolButton> - <ToolButton - icon={wand} - title="Example Tool" - key="3" - ></ToolButton> - <ToolButton - icon={wand} - title="Example Tool" - key="4" - ></ToolButton> - <ToolButton - icon={wand} - title="Example Tool" - key="5" - ></ToolButton> - <ToolButton - icon={wand} - title="Example Tool" - key="6" - ></ToolButton> - <ToolButton - icon={wand} - title="Example Tool" - key="7" - ></ToolButton> - <ToolButton - icon={wand} - title="Example Tool" - key="8" - ></ToolButton> - <ToolButton - icon={wand} - title="Example Tool" - key="9" - ></ToolButton> - - {/* {this.props.state.display.tools.map((t) => ( - <ToolButton - tool={t} - state={this.props.state} - key={t.getKey()} - /> - ))} */} - </div> - ); - } -}