diff light9/web/live/Effect.ts @ 2160:611c3e97de2f

factor out the show-specific strs
author drewp@bigasterisk.com
date Thu, 18 May 2023 10:49:16 -0700
parents 9c2e1b5c16e9
children
line wrap: on
line diff
--- a/light9/web/live/Effect.ts	Thu May 18 10:25:46 2023 -0700
+++ b/light9/web/live/Effect.ts	Thu May 18 10:49:16 2023 -0700
@@ -3,6 +3,7 @@
 import { some } from "underscore";
 import { Patch, patchContainsPreds, patchUpdate } from "../patch";
 import { SyncedGraph } from "../SyncedGraph";
+import { shortShow } from "../show_specific";
 
 type Color = string;
 export type ControlValue = number | Color | NamedNode;
@@ -33,7 +34,7 @@
     // called if the graph changes our values and not when the caller uses edit()
     private onValuesChanged: (values: void) => void
   ) {
-    this.ctxForEffect = this.graph.Uri(this.uri.value.replace("light9.bigasterisk.com/effect", "light9.bigasterisk.com/show/dance2019/effect"));
+    this.ctxForEffect = this.graph.Uri(this.uri.value.replace("light9.bigasterisk.com/effect", `light9.bigasterisk.com/show/${shortShow}/effect`));
     graph.runHandler(this.rebuildSettingsFromGraph.bind(this), `effect sync ${uri.value}`);
   }