Tore out the old engine, left some wounds
This commit is contained in:
@@ -0,0 +1,13 @@
|
||||
export default function evaluateToggles(computation, node){
|
||||
let prop = node.data;
|
||||
if (!prop) return;
|
||||
let toggles = prop._computationDetails?.toggleAncestors;
|
||||
if (!toggles) return;
|
||||
toggles.forEach(toggle => {
|
||||
if (prop.inactive || !toggle.condition) return;
|
||||
if (!toggle.condition.value){
|
||||
prop.inactive = true;
|
||||
prop.deactivatedByToggle = true;
|
||||
}
|
||||
});
|
||||
}
|
||||
Reference in New Issue
Block a user