From 14649ac1fd82f5c16d895ff465ad9409faea06f7 Mon Sep 17 00:00:00 2001 From: Ari Date: Fri, 5 Aug 2022 22:54:17 -0400 Subject: [PATCH] added dial --- .../src/components/AutomationEditor/index.tsx | 47 ++++++++++++++----- .../AutomationManager/Loaded/automationDB.ts | 14 ++---- .../AutomationManager/Loaded/index.tsx | 36 ++++++++++++-- .../AutomationManager/Loaded/state.ts | 15 ++++-- 4 files changed, 80 insertions(+), 32 deletions(-) diff --git a/webapp/src/components/AutomationEditor/index.tsx b/webapp/src/components/AutomationEditor/index.tsx index 26f2ede..3421f6e 100644 --- a/webapp/src/components/AutomationEditor/index.tsx +++ b/webapp/src/components/AutomationEditor/index.tsx @@ -3,15 +3,19 @@ import "./index.mobile.css"; import { FC, useState } from "react"; import { useCookies } from "react-cookie"; -import { ControlButton } from "react-flow-renderer"; import Skeleton from "@mui/material/Skeleton"; import LinearProgress from "@mui/material/LinearProgress"; +import SpeedDial from "@mui/material/SpeedDial"; +import SpeedDialAction from "@mui/material/SpeedDialAction"; +import SpeedDialIcon from "@mui/icons-material/SettingsRounded"; import Edit from "@mui/icons-material/Edit"; import Icon from "@mui/material/Icon"; -import ModeEditOutlineTwoToneIcon from "@mui/icons-material/ModeEditOutlineTwoTone"; +import EditIcon from "@mui/icons-material/ModeEditOutlineTwoTone"; +import DeleteIcon from "@mui/icons-material/DeleteForever"; import { CheckMarkIcon } from "components/Icons"; +import RunIcon from "@mui/icons-material/RunCircleOutlined"; import { Modal } from "components/Modal"; import { Button } from "components/Inputs/Buttons/Button"; @@ -32,6 +36,8 @@ interface Props { automation?: AutomationData; dims: DAGDims; onUpdate: (auto: AutomationData) => void; + onTrigger: () => void; + onDelete: () => void; tagDB: TagDB; isNew?: boolean; } @@ -39,6 +45,8 @@ export const AutomationEditor: FC = ({ dims, automation: propsAutos, onUpdate: propsOnUpdate, + onDelete, + onTrigger, tagDB, isNew, }) => { @@ -198,12 +206,6 @@ export const AutomationEditor: FC = ({ Flip )} -