You cannot select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
31 lines
653 B
TypeScript
31 lines
653 B
TypeScript
import { swel } from "../../deps/swel.ts";
|
|
import { Dispatch } from "../../state/lib/store.ts";
|
|
import { CmpPaintComponent, Paint } from "../component.ts";
|
|
import { Action, newSchema } from "./actions.ts";
|
|
|
|
export type State = undefined;
|
|
|
|
export class Home extends CmpPaintComponent<State> {
|
|
private newSchemaButton = swel(
|
|
"button",
|
|
{
|
|
on: { click: () => this.dispatch(newSchema()) },
|
|
},
|
|
"New schema",
|
|
);
|
|
|
|
private container = swel("div", { className: "home" }, [
|
|
this.newSchemaButton,
|
|
]);
|
|
|
|
constructor(private dispatch: Dispatch<Action>) {
|
|
super();
|
|
}
|
|
|
|
get el() {
|
|
return this.container;
|
|
}
|
|
|
|
paint_: Paint<State> = (cur) => {};
|
|
}
|