move context defs to contexts dir
This commit is contained in:
parent
b6e37c4d47
commit
f9ce18ce17
@ -2,7 +2,7 @@ import { Node } from "@xyflow/react";
|
||||
import Bus from "./Bus";
|
||||
import { Emitter } from "mitt";
|
||||
|
||||
import * as nodes from "./nodes/";
|
||||
import * as nodes from "../nodes/";
|
||||
|
||||
export interface Iface {
|
||||
};
|
||||
@ -39,7 +39,7 @@ async function run(bus: Bus, node: Node) {
|
||||
async function execTask(bus: Bus, node: Node, aborted: Promise<void>) {
|
||||
switch (node.type) {
|
||||
case "fetch_ToshoListed":
|
||||
const data: nodes.fetch.ToshoListedData = node.data;
|
||||
const data: nodes.fetch.ToshoListed = node.data;
|
||||
data;
|
||||
const sleep = new Promise(resolve => setTimeout(resolve, 1));
|
||||
// TODO
|
@ -16,7 +16,7 @@ import * as nodes from "./nodes/";
|
||||
|
||||
import "@xyflow/react/dist/style.css";
|
||||
|
||||
import Bus, { createBus, BusContext, Events } from "./Bus";
|
||||
import Bus, { createBus, BusContext, Events } from "./contexts/Bus";
|
||||
|
||||
const nodeTypes = {
|
||||
fetch_ToshoListed: nodes.fetch.ToshoListed,
|
||||
|
@ -2,7 +2,7 @@ import { useTranslation } from "react-i18next";
|
||||
import { ReactNode, useContext, useCallback } from "react";
|
||||
import { NodeProps } from "@xyflow/react";
|
||||
|
||||
import { BusContext } from "../Bus";
|
||||
import { BusContext } from "../contexts/Bus";
|
||||
|
||||
import style from "./style.module.scss";
|
||||
|
||||
|
@ -3,7 +3,7 @@ import { useTranslation } from "react-i18next";
|
||||
import { Handle, Node, NodeProps, Position } from "@xyflow/react";
|
||||
import Base from "./Base";
|
||||
|
||||
import { BusContext } from "../Bus";
|
||||
import { BusContext } from "../contexts/Bus";
|
||||
|
||||
export type ToshoListed = Node<{
|
||||
prime: boolean,
|
||||
|
Loading…
x
Reference in New Issue
Block a user