Compare commits

...

2 Commits

Author SHA1 Message Date
STEINNI 38ed29327e subflow can take js objects or url 2026-04-10 14:35:01 +00:00
STEINNI a921a3cc71 Merge branch 'main' of https://gitea.internike.com/nike/buildoz 2026-04-10 13:32:00 +00:00
+7 -3
View File
@@ -230,14 +230,18 @@ class BZgraflow extends Buildoz{
// scaled down so it fits exactly inside the clicked node, then animate it to full size.
const nodeBB = nodeEl.getBoundingClientRect()
const parentBB = this.getBoundingClientRect()
const flowNode = this.flow?.nodes?.find(n => n.id === id)
const flowUrl = flowNode.subflow.url
const childEl = document.createElement('bz-graflow')
childEl.isSubflow = true
childEl.currentOrientation = this.currentOrientation
childEl.setAttribute('flow', flowUrl)
if(flowNode.subflow.url) childEl.setAttribute('flow', flowNode.subflow.url)
else {
childEl.addEventListener('bz:graflow:domConnected', (e) => {
e.detail.graflow.loadFlow(flowNode.subflow.flow)
})
}
childEl.setAttribute('tension', this.getBZAttribute('tension') || '60')
// Remember which node we "came from" so exitSubflow() can animate back to it.
childEl.dataset.enterNodeId = id