Skip to content
Merged
Show file tree
Hide file tree
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -59,7 +59,7 @@ import {
$selectedPage,
} from "~/shared/awareness";
import { updateWebstudioData } from "~/shared/instance-utils";
import { restoreTreeVariablesMutable } from "~/shared/data-variables";
import { rebindTreeVariablesMutable } from "~/shared/data-variables";

const validateUrl = (value: string, scope: Record<string, unknown>) => {
const evaluatedValue = evaluateExpressionWithinScope(value, scope);
Expand Down Expand Up @@ -608,7 +608,7 @@ export const ResourceForm = forwardRef<
updateWebstudioData((data) => {
data.dataSources.set(newVariable.id, newVariable);
data.resources.set(newResource.id, newResource);
restoreTreeVariablesMutable({ instancePath, ...data });
rebindTreeVariablesMutable({ instancePath, ...data });
});
},
}));
Expand Down Expand Up @@ -740,7 +740,7 @@ export const SystemResourceForm = forwardRef<
updateWebstudioData((data) => {
data.dataSources.set(newVariable.id, newVariable);
data.resources.set(newResource.id, newResource);
restoreTreeVariablesMutable({ instancePath, ...data });
rebindTreeVariablesMutable({ instancePath, ...data });
});
},
}));
Expand Down Expand Up @@ -856,7 +856,7 @@ export const GraphqlResourceForm = forwardRef<
updateWebstudioData((data) => {
data.dataSources.set(newVariable.id, newVariable);
data.resources.set(newResource.id, newResource);
restoreTreeVariablesMutable({ instancePath, ...data });
rebindTreeVariablesMutable({ instancePath, ...data });
});
},
}));
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -75,7 +75,7 @@ import { generateCurl } from "./curl";
import { updateWebstudioData } from "~/shared/instance-utils";
import {
findUnsetVariableNames,
restoreTreeVariablesMutable,
rebindTreeVariablesMutable,
} from "~/shared/data-variables";

const $variablesByName = computed(
Expand Down Expand Up @@ -299,7 +299,7 @@ const ParameterForm = forwardRef<
const name = z.string().parse(formData.get("name"));
updateWebstudioData((data) => {
data.dataSources.set(variable.id, { ...variable, name });
restoreTreeVariablesMutable({ instancePath, ...data });
rebindTreeVariablesMutable({ instancePath, ...data });
});
},
}));
Expand Down Expand Up @@ -339,7 +339,7 @@ const useValuePanelRef = ({
type: "variable",
value: variableValue,
});
restoreTreeVariablesMutable({ instancePath, ...data });
rebindTreeVariablesMutable({ instancePath, ...data });
});
},
}));
Expand Down
Loading