fixed up styling for autos

This commit is contained in:
ari committed 2022-05-05 15:03:33 -04:00
1 parent 634f3e9219
commit c256400518
9 files changed
+104 -107

No files matched your search

@@ -12,7 +12,7 @@ export type EditorState = {
export type EditorStatus = EditorState['status'];
export const useAutomatioEditorState = (
automation: AutomationData,
automation: AutomationData | undefined,
onSave: (a: AutomationData) => void,
) => {
const [state, update] = useState<EditorState>({
@@ -30,10 +30,12 @@ export const useAutomatioEditorState = (
})
useEffect(() => {
update({
status: 'unchanged',
data: genEditorData(automation),
})
if (automation) {
update({
status: 'unchanged',
data: genEditorData(automation),
})
}
}, [automation]);
return {