Prompt serializer and test fixes

This commit is contained in:
space-nuko
2023-05-20 21:42:38 -05:00
parent 8d031120f7
commit 09e806bd3e
17 changed files with 196 additions and 106 deletions

View File

@@ -10,6 +10,7 @@ import { get } from "svelte/store";
import configState from "$lib/stores/configState";
import type { WritableLayoutStateStore } from "$lib/stores/layoutStates";
import layoutStates from "$lib/stores/layoutStates";
import workflowStateStore, { ComfyWorkflow } from "$lib/stores/workflowState";
export type DefaultWidgetSpec = {
defaultWidgetNode: new (name?: string) => ComfyWidgetNode,
@@ -106,6 +107,10 @@ export default class ComfyGraphNode extends LGraphNode {
return layoutStates.getLayoutByNode(this);
}
get workflow(): ComfyWorkflow | null {
return workflowStateStore.getWorkflowByNode(this);
}
constructor(title?: string) {
super(title)
this.addProperty("tags", [], "array")