mirror of
https://github.com/barsdeveloper/ueblueprint.git
synced 2026-02-03 23:55:04 +08:00
Fix comments dragging nodes
This commit is contained in:
10
dist/css/ueb-style.css
vendored
10
dist/css/ueb-style.css
vendored
@@ -182,7 +182,7 @@ ueb-blueprint[data-zoom="-12"] {
|
||||
height: 0;
|
||||
}
|
||||
|
||||
.ueb-positioned, ueb-link, ueb-blueprint[data-selecting=true] ueb-selector {
|
||||
.ueb-positioned, ueb-blueprint[data-selecting=true] ueb-selector {
|
||||
position: absolute;
|
||||
}
|
||||
|
||||
@@ -236,6 +236,7 @@ ueb-node[data-type="/Script/BlueprintGraph.K2Node_Knot"][data-selected=true] .ue
|
||||
}
|
||||
|
||||
ueb-link {
|
||||
position: absolute;
|
||||
--ueb-link-color: rgb(var(--ueb-link-color-rgb));
|
||||
--ueb-from-input-coefficient: calc(2 * var(--ueb-from-input) - 1);
|
||||
/* when from-y > to-y */
|
||||
@@ -248,6 +249,7 @@ ueb-link {
|
||||
* their hover behavior correctly firing.
|
||||
*/
|
||||
visibility: hidden;
|
||||
z-index: 2;
|
||||
}
|
||||
|
||||
ueb-link > svg {
|
||||
@@ -532,8 +534,8 @@ ueb-node.ueb-node-style-glass .ueb-node-outputs:first-child {
|
||||
padding-left: 8px;
|
||||
}
|
||||
|
||||
ueb-node.ueb-node-style-comment {
|
||||
z-index: -1;
|
||||
ueb-node:not(.ueb-node-style-comment) {
|
||||
z-index: 10;
|
||||
}
|
||||
|
||||
ueb-node.ueb-node-style-comment .ueb-node-border {
|
||||
@@ -560,6 +562,7 @@ ueb-node.ueb-node-style-comment .ueb-node-wrapper::after {
|
||||
}
|
||||
|
||||
ueb-node.ueb-node-style-comment .ueb-node-top {
|
||||
position: relative;
|
||||
margin: 3px;
|
||||
padding: 3px 10px;
|
||||
box-shadow: none;
|
||||
@@ -568,6 +571,7 @@ ueb-node.ueb-node-style-comment .ueb-node-top {
|
||||
color: white;
|
||||
font-size: 24px;
|
||||
text-shadow: 2px 1px 1px #444, 0 0 2px #bbb;
|
||||
z-index: 1;
|
||||
}
|
||||
|
||||
ueb-blueprint {
|
||||
|
||||
2
dist/css/ueb-style.css.map
vendored
2
dist/css/ueb-style.css.map
vendored
@@ -1 +1 @@
|
||||
{"version":3,"sourceRoot":"","sources":["../../scss/style.scss","../../scss/ueb-knot.scss","../../scss/ueb-link.scss","../../scss/ueb-node.scss","../../scss/ueb-pin.scss","../../scss/ueb-ui-controls.scss","../../scss/ueb-window.scss"],"names":[],"mappings":"AAAA;EACI;EACA;EACA,KACI;;AAIR;EACI;EACA;EACA,KACI;;AAIR;EACI;EACA;EACA,KACI;;AAIR;EACI;EACA;EACA;EACA;EACA;EACA;EACA;EACA;;;AAGJ;EACI;;;AAGJ;EACI;EACA;EACA;EACA;EACA;EACA;EACA;EACA;;;AAGJ;EACI;EACA;EACA;;;AAGJ;EACI;EACA;EACA;EACA;;;AAGJ;EACI;;;AAGJ;EACI;EACA;EACA;EACA;EACA;EACA;EACA;EACA,kBAEI;EA0BJ,iBAEI;EAQJ;EACA;EACA;EACA;EACA;;;AAGJ;EACI;;;AAGJ;EACI;;;AAGJ;EACI;;;AAGJ;EACI;;;AAGJ;EACI;;;AAGJ;EACI;;;AAGJ;EACI;;;AAGJ;EACI;;;AAGJ;EACI;;;AAGJ;EACI;;;AAGJ;EACI;;;AAGJ;EACI;;;AAGJ;EACI;EACA;;;AAGJ;EACI;;;AAGJ;EACI;EACA;;;AAGJ;EACI;EACA;;;AAGJ;EACI;EACA;;;AAGJ;EACI;EACA;;;AAGJ;EACI;EACA;;;AAGJ;EACI;EACA;;;AAGJ;EACI;EACA;;;AAGJ;EACI;EACA;;;AAGJ;EACI;EACA;EACA;EACA;;;AAGJ;EACI;EACA;;;AAGJ;EACI;;;AAGJ;EACI;EACA;EACA;EACA;EACA;EACA;EACA;EACA,kBAEI;EAmDJ,iBAEI;EAWJ,qBAEI;EAOJ;;;AAGJ;EACI;;;AAIJ;EACI;;;AAGJ;EACI;EACA;EACA;;;AC3UJ;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GJ;AAAA;EAEI;EACA;EACA;EACA;;;AAGJ;EACI;EACA;EACA;;;AAGJ;EACI;;;AAGJ;EACI;;;AAGJ;EACI;;;AAGJ;EACI;EACA;EACA;EACA;EACA;EACA;;AAEA;EACI;EACA;EACA;EACA;EACA;EACA;EACA;EACA;;;AAgBR;EACI;EACA;EACA;EACA;EACA;EACA;EACA;EACA;;;ACnSJ;EACI;;;AAGJ;EACI;AAAA;AAAA;AAAA;AAAA;AAAA;EAMA;;;AAGJ;EACI;EACA;;;AAGJ;EACI;;;AAGJ;EACI;;;AAGJ;EACI;EACA;EACA;;AAEA;EACI;EACA;;;AAIR;EACI;EACA;;;AAGJ;EACI;;;AAGJ;EACI;;;AAGJ;EACI;EACA;;;AAGJ;EACI;;;AAGJ;EACI;;;AAGJ;EACI;EACA;EACA;;;AAGJ;EACI;EACA;EACA;EACA;;;AAGJ;EACI;;;AAGJ;EACI;;;AAGJ;EACI;;;AAGJ;EACI;;;AAGJ;EACI;;;AAGJ;EACI;EACA;EACA;EACA;EACA;EACA;EACA;;AAEA;EAII;EACA;;;AAIR;EACI;;;AAGJ;EACI;EACA;EACA;EACA;EACA;EACA;;;AAGJ;EACI;;;AAGJ;EACI;EACA;EACA;EACA;EACA;EACA;;;AAGJ;EACI;;;AAGJ;EACI;EACA;EACA;;;AAGJ;EACI;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;;AAEA;EACI;EACA;;AAGJ;EACI;EACA;EACA;;;AAIR;EACI;;;ACjLJ;EACI;EACA;EACA;EACA;EACA;EACA;EACA;;AAEA;EACI;;;AAIR;EACI;EACA;EACA;EACA;;;AAGJ;EACI;EACA;;AAEA;EAEI;EACA;EACA;EACA;EACA;EACA;;AAGJ;EACI;EACA;;AAGJ;EACI;EACA;;;AAIR;AAAA;EAEI;EACA;EACA;EACA;;;AAGJ;EACI;EACA;;AAEA;EACI;;;AAIR;EACI;;;AAGJ;EACI;EACA;EACA;EACA;EACA;;;AAGJ;EACI;EACA;EACA;EACA;;;AAKA;EACI;EACA;EACA;EACA;EACA;EACA;;AAGJ;EACI;;;AAIR;AAAA;AAAA;EAGI;EACA;EACA;;;AAGJ;EACI;EACA;EACA;;;AAGJ;EACI;EACA;EACA;;;AAGJ;EACI;EACA;EACA;;;AAGJ;EACI;EACA;EACA;EACA;EACA;EACA;;;AAGJ;AAAA;AAAA;EAGI;EACA;EACA;EACA;;;AAGJ;EACI;EACA;;;AAGJ;EACI;EACA;EACA;;;AAGJ;EACI;EACA;EACA;;;AAGJ;EACI;EACA;EACA;EACA;EACA;EACA;;;ACnKJ;EACI;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;;;AAGJ;EACI;EACA;EACA;EACA;EACA;EACA;;;AAGJ;EACI;EACA;;;AAGJ;EACI;EACA;EACA;;;AAGJ;EACI;EACA;EACA;EACA;;;AAGJ;AAAA;EAEI;EACA;;;AAGJ;EACI;EACA;;;AAGJ;EACI;EACA;EACA;EACA;EACA,YACI;;;AAWR;EACI;EACA;EACA;EACA;EACA;EACA;EACA;EACA;;;AAGJ;EACI;EACA;;;AAGJ;AAAA;EAEI;EACA;EACA;;;AAGJ;EACI;EACA;;;AAGJ;EACI;EACA;;;AAGJ;EACI;;;AAGJ;EACI;;;AAGJ;EACI;;;AAGJ;EACI;EACA;;AAEA;EAEI;EACA;EACA;EACA;EACA;EACA;;AAGJ;EACI;;;AAIR;AAAA;EAEI;EACA;;;AAGJ;EACI;;;AAGJ;AAAA;EAEI;;;AAGJ;EACI;EACA;EACA;;;AAGJ;EACI;EACA;EACA;EACA;EACA;;;AAGJ;EACI;EACA;EACA;;AAEA;EACI;;;AAIR;EACI;;;AAGJ;EACI;;;AAGJ;EACI;;;AAGJ;EACI;;;AAGJ;EACI;;;AAGJ;EACI;;;AAGJ;EACI;;;AAGJ;EACI;;;AAGJ;EACI;;;AAGJ;EACI;;;AAGJ;EACI;EACA;;;AAGJ;EACI;EACA;EACA;EACA","file":"ueb-style.css"}
|
||||
{"version":3,"sourceRoot":"","sources":["../../scss/style.scss","../../scss/ueb-knot.scss","../../scss/ueb-link.scss","../../scss/ueb-node.scss","../../scss/ueb-pin.scss","../../scss/ueb-ui-controls.scss","../../scss/ueb-window.scss"],"names":[],"mappings":"AAAA;EACI;EACA;EACA,KACI;;AAIR;EACI;EACA;EACA,KACI;;AAIR;EACI;EACA;EACA,KACI;;AAIR;EACI;EACA;EACA;EACA;EACA;EACA;EACA;EACA;;;AAGJ;EACI;;;AAGJ;EACI;EACA;EACA;EACA;EACA;EACA;EACA;EACA;;;AAGJ;EACI;EACA;EACA;;;AAGJ;EACI;EACA;EACA;EACA;;;AAGJ;EACI;;;AAGJ;EACI;EACA;EACA;EACA;EACA;EACA;EACA;EACA,kBAEI;EA0BJ,iBAEI;EAQJ;EACA;EACA;EACA;EACA;;;AAGJ;EACI;;;AAGJ;EACI;;;AAGJ;EACI;;;AAGJ;EACI;;;AAGJ;EACI;;;AAGJ;EACI;;;AAGJ;EACI;;;AAGJ;EACI;;;AAGJ;EACI;;;AAGJ;EACI;;;AAGJ;EACI;;;AAGJ;EACI;;;AAGJ;EACI;EACA;;;AAGJ;EACI;;;AAGJ;EACI;EACA;;;AAGJ;EACI;EACA;;;AAGJ;EACI;EACA;;;AAGJ;EACI;EACA;;;AAGJ;EACI;EACA;;;AAGJ;EACI;EACA;;;AAGJ;EACI;EACA;;;AAGJ;EACI;EACA;;;AAGJ;EACI;EACA;EACA;EACA;;;AAGJ;EACI;EACA;;;AAGJ;EACI;;;AAGJ;EACI;EACA;EACA;EACA;EACA;EACA;EACA;EACA,kBAEI;EAmDJ,iBAEI;EAWJ,qBAEI;EAOJ;;;AAGJ;EACI;;;AAIJ;EACI;;;AAGJ;EACI;EACA;EACA;;;AC3UJ;EACI;;;AAGJ;EACI;;;AAGJ;EACI;;;AAGJ;EACI;EACA;;;AAGJ;EACI;;;AChBJ;EACI;EACA;EACA;AACA;EACA;EACA;EACA;EACA;AACA;AAAA;AAAA;AAAA;EAIA;EACA;;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A;EACI;EACA;EACA;EACA;EACA;EACA;EACA;EACA;;;AAgBR;EACI;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;;;ACrSJ;EACI;;;AAGJ;EACI;AAAA;AAAA;AAAA;AAAA;AAAA;EAMA;;;AAGJ;EACI;EACA;;;AAGJ;EACI;;;AAGJ;EACI;;;AAGJ;EACI;EACA;EACA;;AAEA;EACI;EACA;;;AAIR;EACI;EACA;;;AAGJ;EACI;;;AAGJ;EACI;;;AAGJ;EACI;EACA;;;AAGJ;EACI;;;AAGJ;EACI;;;AAGJ;EACI;EACA;EACA;;;AAGJ;EACI;EACA;EACA;EACA;;;AAGJ;EACI;;;AAGJ;EACI;;;AAGJ;EACI;;;AAGJ;EACI;;;AAGJ;EACI;;;AAGJ;EACI;EACA;EACA;EACA;EACA;EACA;EACA;;AAEA;EAII;EACA;;;AAIR;EACI;;;AAGJ;EACI;EACA;EACA;EACA;EACA;EACA;;;AAGJ;EACI;;;AAGJ;EACI;EACA;EACA;EACA;EACA;EACA;;;AAGJ;EACI;;;AAGJ;EACI;EACA;EACA;;;AAGJ;EACI;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;;AAEA;EACI;EACA;;AAGJ;EACI;EACA;EACA;;;AAIR;EACI;;;ACjLJ;EACI;EACA;EACA;EACA;EACA;EACA;EACA;;AAEA;EACI;;;AAIR;EACI;EACA;EACA;EACA;;;AAGJ;EACI;EACA;;AAEA;EAEI;EACA;EACA;EACA;EACA;EACA;;AAGJ;EACI;EACA;;AAGJ;EACI;EACA;;;AAIR;AAAA;EAEI;EACA;EACA;EACA;;;AAGJ;EACI;EACA;;AAEA;EACI;;;AAIR;EACI;;;AAGJ;EACI;EACA;EACA;EACA;EACA;;;AAGJ;EACI;EACA;EACA;EACA;;;AAKA;EACI;EACA;EACA;EACA;EACA;EACA;;AAGJ;EACI;;;AAIR;AAAA;AAAA;EAGI;EACA;EACA;;;AAGJ;EACI;EACA;EACA;;;AAGJ;EACI;EACA;EACA;;;AAGJ;EACI;EACA;EACA;;;AAGJ;EACI;EACA;EACA;EACA;EACA;EACA;;;AAGJ;AAAA;AAAA;EAGI;EACA;EACA;EACA;;;AAGJ;EACI;EACA;;;AAGJ;EACI;EACA;EACA;;;AAGJ;EACI;EACA;EACA;;;AAGJ;EACI;EACA;EACA;EACA;EACA;EACA;;;ACnKJ;EACI;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;;;AAGJ;EACI;EACA;EACA;EACA;EACA;EACA;;;AAGJ;EACI;EACA;;;AAGJ;EACI;EACA;EACA;;;AAGJ;EACI;EACA;EACA;EACA;;;AAGJ;AAAA;EAEI;EACA;;;AAGJ;EACI;EACA;;;AAGJ;EACI;EACA;EACA;EACA;EACA,YACI;;;AAWR;EACI;EACA;EACA;EACA;EACA;EACA;EACA;EACA;;;AAGJ;EACI;EACA;;;AAGJ;AAAA;EAEI;EACA;EACA;;;AAGJ;EACI;EACA;;;AAGJ;EACI;EACA;;;AAGJ;EACI;;;AAGJ;EACI;;;AAGJ;EACI;;;AAGJ;EACI;EACA;;AAEA;EAEI;EACA;EACA;EACA;EACA;EACA;;AAGJ;EACI;;;AAIR;AAAA;EAEI;EACA;;;AAGJ;EACI;;;AAGJ;AAAA;EAEI;;;AAGJ;EACI;EACA;EACA;;;AAGJ;EACI;EACA;EACA;EACA;EACA;;;AAGJ;EACI;EACA;EACA;;AAEA;EACI;;;AAIR;EACI;;;AAGJ;EACI;;;AAGJ;EACI;;;AAGJ;EACI;;;AAGJ;EACI;;;AAGJ;EACI;;;AAGJ;EACI;;;AAGJ;EACI;;;AAGJ;EACI;;;AAGJ;EACI;;;AAGJ;EACI;EACA;;;AAGJ;EACI;EACA;EACA;EACA","file":"ueb-style.css"}
|
||||
2
dist/css/ueb-style.min.css
vendored
2
dist/css/ueb-style.min.css
vendored
File diff suppressed because one or more lines are too long
2
dist/css/ueb-style.min.css.map
vendored
2
dist/css/ueb-style.min.css.map
vendored
@@ -1 +1 @@
|
||||
{"version":3,"sourceRoot":"","sources":["../../scss/style.scss","../../scss/ueb-knot.scss","../../scss/ueb-link.scss","../../scss/ueb-node.scss","../../scss/ueb-pin.scss","../../scss/ueb-ui-controls.scss","../../scss/ueb-window.scss"],"names":[],"mappings":"AAAA,WACI,qBACA,oBACA,IACI,kGAIR,WACI,qBACA,mBACA,IACI,sGAIR,WACI,qBACA,iBACA,IACI,gGAIR,cACI,eACA,6CACA,cACA,kBACA,8EACA,+BACA,WACA,iBAGJ,kBACI,iBAGJ,qBACI,aACA,kBACA,MACA,QACA,OACA,aACA,0BACA,UAGJ,mBACI,iBACA,iCACA,eAGJ,mBACI,kBACA,gCACA,gBACA,kBAGJ,oDACI,gBAGJ,UACI,kFACA,kBACA,eACA,gBACA,+DACA,gEACA,yBACA,iBAEI,s3BA0BJ,gBAEI,sZAQJ,sFACA,gEACA,oDACA,qBACA,gBAGJ,6CACI,gBAGJ,8CACI,eAGJ,6BACI,eAGJ,6BACI,mBAGJ,6BACI,kBAGJ,6BACI,mBAGJ,6BACI,iBAGJ,6BACI,mBAGJ,6BACI,kBAGJ,8BACI,mBAGJ,8BACI,kBAGJ,8BACI,mBAGJ,8BACI,iBACA,uDAGJ,0BACI,gCAGJ,8BACI,mBACA,uDAGJ,8BACI,sBACA,uDAGJ,8BACI,iBACA,uDAGJ,8BACI,sBACA,uDAGJ,8BACI,sBACA,uDAGJ,+BACI,iBACA,uDAGJ,+BACI,sBACA,uDAGJ,+BACI,sBACA,uDAGJ,kBACI,kBACA,QACA,SACA,wGAGJ,sBACI,QACA,SAGJ,yEACI,kBAGJ,aACI,cACA,kBACA,kBACA,MACA,OACA,QACA,SACA,iBAEI,wlDAmDJ,gBAEI,gQAWJ,oBAEI,wJAOJ,4BAGJ,gDACI,mBAIJ,eACI,mBAGJ,0BACI,mBACA,uBACA,gBC3UJ,yDACI,gBAGJ,iEACI,aAGJ,uFACI,aAGJ,0EACI,iBACA,2BAGJ,8FACI,qCChBJ,SACI,iDACA,kE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GJ,iDACI,YAGJ,kDACI,kBACA,UACA,YACA,gBACA,4CACA,gBAEA,yDACI,WACA,cACA,kBACA,UACA,WACA,WACA,YACA,6TAgBR,8CACI,WACA,iBACA,gBACA,gBACA,sCACA,WACA,eACA,0CCnSJ,cACI,6BAGJ,QACI,4NAMA,+CAGJ,QACI,cACA,gBAGJ,sBACI,kBAGJ,wEACI,aAGJ,iBACI,qBACA,iBACA,gBAEA,mBACI,qBACA,sBAIR,iFACI,qCACA,iBAGJ,oCACI,2BAGJ,0BACI,iBAGJ,cACI,eACA,gBAGJ,+BACI,iBAGJ,gCACI,gBAGJ,kBACI,WACA,YACA,2BAGJ,0CACI,uBACA,WACA,YACA,sBAGJ,0CACI,kBAGJ,cACI,qBAGJ,8BACI,kBAGJ,gHACI,aAGJ,uBACI,iBAGJ,eACI,qBACA,sBACA,gBACA,yBACA,kBACA,oBACA,cAEA,4FAII,yCACA,aAIR,yCACI,aAGJ,uCACI,gBACA,UACA,YACA,WACA,yBACA,2BAGJ,+CACI,6OAGJ,oEACI,UACA,WACA,YACA,qBACA,gBACA,yCAGJ,oCACI,cAGJ,qBACI,sBACA,gBACA,WAGJ,uBACI,cACA,aACA,YACA,UACA,eACA,gBACA,gBACA,4BACA,gBACA,cACA,cAEA,0CACI,WACA,YAGJ,gDACI,mBACA,mBACA,WAIR,4EACI,YCjLJ,YACI,eACA,yBACA,kBACA,iBACA,mBACA,kBACA,eAEA,kBACI,mBAIR,aACI,aACA,yBACA,SACA,gBAGJ,mCACI,kBACA,oBAEA,qFAEI,WACA,cACA,kBACA,QACA,SACA,+BAGJ,2CACI,UACA,0BAGJ,0CACI,WACA,2BAIR,uCAEI,kBACA,yBACA,kBACA,mBAGJ,uBACI,kBACA,YAEA,6BACI,iBAIR,kCACI,iBAGJ,qCACI,cACA,kBACA,YACA,kBACA,mBAGJ,4BACI,kBACA,cACA,iBACA,UAKA,4BACI,WACA,qBACA,6BACA,oCACA,qCACA,sBAGJ,0BACI,eAIR,uEAGI,kBACA,MACA,YAGJ,oBACI,QACA,OACA,iBAGJ,0BACI,QACA,WACA,mBAGJ,yBACI,OACA,WACA,mBAGJ,sBACI,kBACA,MACA,QACA,SACA,WACA,iBAGJ,gFAGI,kBACA,YACA,YACA,iBAGJ,uBACI,QACA,OAGJ,6BACI,QACA,WACA,mBAGJ,4BACI,OACA,WACA,mBAGJ,qBACI,kBACA,MACA,SACA,OACA,WACA,iBCnKJ,WACI,cACA,kBACA,yBACA,MACA,OACA,sGACA,mBACA,6CACA,aAGJ,gBACI,aACA,mBACA,mBACA,gBACA,YACA,mBAGJ,oBACI,aACA,yBAGJ,iBACI,YACA,kBACA,kBAGJ,kBACI,YACA,YACA,WACA,eAGJ,+CAEI,qBACA,sBAGJ,uBACI,aACA,2DAGJ,wBACI,kBACA,iBACA,gBACA,mBACA,WACI,mLAWR,kBACI,cACA,kBACA,gBACA,iBACA,UACA,WACA,sBACA,kBAGJ,0CACI,8BACA,6BAGJ,qDAEI,aACA,oBACA,WAGJ,6BACI,iBACA,4EAGJ,wBACI,kBACA,4EAGJ,cACI,cAGJ,2CACI,yCAGJ,sCACI,yCAGJ,0BACI,kBACA,sBAEA,mEAEI,WACA,cACA,kBACA,oBACA,UACA,0BAGJ,iCACI,QAIR,4DAEI,YACA,YAGJ,8BACI,aAGJ,wDAEI,UAGJ,2BACI,aACA,gBACA,gBAGJ,oDACI,aACA,sBACA,8BACA,YACA,UAGJ,wDACI,aACA,mBACA,kBAEA,4DACI,YAIR,kDACI,YAGJ,yDACI,oCAGJ,yDACI,oCAGJ,yDACI,oCAGJ,yDACI,oCAGJ,yDACI,oCAGJ,yDACI,oCAGJ,yDACI,oCAGJ,2BACI,WAGJ,mBACI,oBAGJ,yBACI,iBACA,aAGJ,0CACI,UACA,iBACA,sBACA","file":"ueb-style.min.css"}
|
||||
{"version":3,"sourceRoot":"","sources":["../../scss/style.scss","../../scss/ueb-knot.scss","../../scss/ueb-link.scss","../../scss/ueb-node.scss","../../scss/ueb-pin.scss","../../scss/ueb-ui-controls.scss","../../scss/ueb-window.scss"],"names":[],"mappings":"AAAA,WACI,qBACA,oBACA,IACI,kGAIR,WACI,qBACA,mBACA,IACI,sGAIR,WACI,qBACA,iBACA,IACI,gGAIR,cACI,eACA,6CACA,cACA,kBACA,8EACA,+BACA,WACA,iBAGJ,kBACI,iBAGJ,qBACI,aACA,kBACA,MACA,QACA,OACA,aACA,0BACA,UAGJ,mBACI,iBACA,iCACA,eAGJ,mBACI,kBACA,gCACA,gBACA,kBAGJ,oDACI,gBAGJ,UACI,kFACA,kBACA,eACA,gBACA,+DACA,gEACA,yBACA,iBAEI,s3BA0BJ,gBAEI,sZAQJ,sFACA,gEACA,oDACA,qBACA,gBAGJ,6CACI,gBAGJ,8CACI,eAGJ,6BACI,eAGJ,6BACI,mBAGJ,6BACI,kBAGJ,6BACI,mBAGJ,6BACI,iBAGJ,6BACI,mBAGJ,6BACI,kBAGJ,8BACI,mBAGJ,8BACI,kBAGJ,8BACI,mBAGJ,8BACI,iBACA,uDAGJ,0BACI,gCAGJ,8BACI,mBACA,uDAGJ,8BACI,sBACA,uDAGJ,8BACI,iBACA,uDAGJ,8BACI,sBACA,uDAGJ,8BACI,sBACA,uDAGJ,+BACI,iBACA,uDAGJ,+BACI,sBACA,uDAGJ,+BACI,sBACA,uDAGJ,kBACI,kBACA,QACA,SACA,wGAGJ,sBACI,QACA,SAGJ,gEACI,kBAGJ,aACI,cACA,kBACA,kBACA,MACA,OACA,QACA,SACA,iBAEI,wlDAmDJ,gBAEI,gQAWJ,oBAEI,wJAOJ,4BAGJ,gDACI,mBAIJ,eACI,mBAGJ,0BACI,mBACA,uBACA,gBC3UJ,yDACI,gBAGJ,iEACI,aAGJ,uFACI,aAGJ,0EACI,iBACA,2BAGJ,8FACI,qCChBJ,SACI,kBACA,iDACA,kEAEA,wEACA,cACA,6CACA,8CAKA,kBACA,UAGJ,aACI,oEACA,kBACA,WACA,YACA,eACA,+FAGJ,6BACI,mBACA,6BACA,wCA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6TAgBR,8CACI,kBACA,WACA,iBACA,gBACA,gBACA,sCACA,WACA,eACA,0CACA,UCrSJ,cACI,6BAGJ,QACI,4NAMA,+CAGJ,QACI,cACA,gBAGJ,sBACI,kBAGJ,wEACI,aAGJ,iBACI,qBACA,iBACA,gBAEA,mBACI,qBACA,sBAIR,iFACI,qCACA,iBAGJ,oCACI,2BAGJ,0BACI,iBAGJ,cACI,eACA,gBAGJ,+BACI,iBAGJ,gCACI,gBAGJ,kBACI,WACA,YACA,2BAGJ,0CACI,uBACA,WACA,YACA,sBAGJ,0CACI,kBAGJ,cACI,qBAGJ,8BACI,kBAGJ,gHACI,aAGJ,uBACI,iBAGJ,eACI,qBACA,sBACA,gBACA,yBACA,kBACA,oBACA,cAEA,4FAII,yCACA,aAIR,yCACI,aAGJ,uCACI,gBACA,UACA,YACA,WACA,yBACA,2BAGJ,+CACI,6OAGJ,oEACI,UACA,WACA,YACA,qBACA,gBACA,yCAGJ,oCACI,cAGJ,qBACI,sBACA,gBACA,WAGJ,uBACI,cACA,aACA,YACA,UACA,eACA,gBACA,gBACA,4BACA,gBACA,cACA,cAEA,0CACI,WACA,YAGJ,gDACI,mBACA,mBACA,WAIR,4EACI,YCjLJ,YACI,eACA,yBACA,kBACA,iBACA,mBACA,kBACA,eAEA,kBACI,mBAIR,aACI,aACA,yBACA,SACA,gBAGJ,mCACI,kBACA,oBAEA,qFAEI,WACA,cACA,kBACA,QACA,SACA,+BAGJ,2CACI,UACA,0BAGJ,0CACI,WACA,2BAIR,uCAEI,kBACA,yBACA,kBACA,mBAGJ,uBACI,kBACA,YAEA,6BACI,iBAIR,kCACI,iBAGJ,qCACI,cACA,kBACA,YACA,kBACA,mBAGJ,4BACI,kBACA,cACA,iBACA,UAKA,4BACI,WACA,qBACA,6BACA,oCACA,qCACA,sBAGJ,0BACI,eAIR,uEAGI,kBACA,MACA,YAGJ,oBACI,QACA,OACA,iBAGJ,0BACI,QACA,WACA,mBAGJ,yBACI,OACA,WACA,mBAGJ,sBACI,kBACA,MACA,QACA,SACA,WACA,iBAGJ,gFAGI,kBACA,YACA,YACA,iBAGJ,uBACI,QACA,OAGJ,6BACI,QACA,WACA,mBAGJ,4BACI,OACA,WACA,mBAGJ,qBACI,kBACA,MACA,SACA,OACA,WACA,iBCnKJ,WACI,cACA,kBACA,yBACA,MACA,OACA,sGACA,mBACA,6CACA,aAGJ,gBACI,aACA,mBACA,mBACA,gBACA,YACA,mBAGJ,oBACI,aACA,yBAGJ,iBACI,YACA,kBACA,kBAGJ,kBACI,YACA,YACA,WACA,eAGJ,+CAEI,qBACA,sBAGJ,uBACI,aACA,2DAGJ,wBACI,kBACA,iBACA,gBACA,mBACA,WACI,mLAWR,kBACI,cACA,kBACA,gBACA,iBACA,UACA,WACA,sBACA,kBAGJ,0CACI,8BACA,6BAGJ,qDAEI,aACA,oBACA,WAGJ,6BACI,iBACA,4EAGJ,wBACI,kBACA,4EAGJ,cACI,cAGJ,2CACI,yCAGJ,sCACI,yCAGJ,0BACI,kBACA,sBAEA,mEAEI,WACA,cACA,kBACA,oBACA,UACA,0BAGJ,iCACI,QAIR,4DAEI,YACA,YAGJ,8BACI,aAGJ,wDAEI,UAGJ,2BACI,aACA,gBACA,gBAGJ,oDACI,aACA,sBACA,8BACA,YACA,UAGJ,wDACI,aACA,mBACA,kBAEA,4DACI,YAIR,kDACI,YAGJ,yDACI,oCAGJ,yDACI,oCAGJ,yDACI,oCAGJ,yDACI,oCAGJ,yDACI,oCAGJ,yDACI,oCAGJ,yDACI,oCAGJ,2BACI,WAGJ,mBACI,oBAGJ,yBACI,iBACA,aAGJ,0CACI,UACA,iBACA,sBACA","file":"ueb-style.min.css"}
|
||||
117
dist/ueblueprint.js
vendored
117
dist/ueblueprint.js
vendored
@@ -1204,7 +1204,7 @@ class LinearColorEntity extends IEntity {
|
||||
R: RealUnitEntity,
|
||||
G: RealUnitEntity,
|
||||
B: RealUnitEntity,
|
||||
A: new TypeInitialization(RealUnitEntity, true, () => new RealUnitEntity(1), false, true),
|
||||
A: new TypeInitialization(RealUnitEntity, true, () => new RealUnitEntity(1), false, false),
|
||||
H: new TypeInitialization(RealUnitEntity, true, undefined, false, true),
|
||||
S: new TypeInitialization(RealUnitEntity, true, undefined, false, true),
|
||||
V: new TypeInitialization(RealUnitEntity, true, undefined, false, true),
|
||||
@@ -3155,26 +3155,26 @@ class IDraggableElement extends IElement {
|
||||
}
|
||||
|
||||
/** @param {Number[]} param0 */
|
||||
setLocation([x, y]) {
|
||||
setLocation([x, y], acknowledge = true) {
|
||||
const d = [x - this.locationX, y - this.locationY];
|
||||
this.locationX = x;
|
||||
this.locationY = y;
|
||||
if (this.blueprint) {
|
||||
if (this.blueprint && acknowledge) {
|
||||
// @ts-expect-error
|
||||
const dragLocalEvent = new CustomEvent(this.constructor.dragEventName, {
|
||||
detail: {
|
||||
value: d,
|
||||
},
|
||||
bubbles: false,
|
||||
cancelable: true
|
||||
cancelable: true,
|
||||
});
|
||||
this.dispatchEvent(dragLocalEvent);
|
||||
}
|
||||
}
|
||||
|
||||
/** @param {Number[]} param0 */
|
||||
addLocation([x, y]) {
|
||||
this.setLocation([this.locationX + x, this.locationY + y]);
|
||||
addLocation([x, y], acknowledge = true) {
|
||||
this.setLocation([this.locationX + x, this.locationY + y], acknowledge);
|
||||
}
|
||||
|
||||
/** @param {Number[]} value */
|
||||
@@ -3544,7 +3544,6 @@ class Paste extends IInput {
|
||||
if (nodes.length > 0) {
|
||||
this.blueprint.unselectAll();
|
||||
}
|
||||
this.blueprint.addGraphElement(...nodes);
|
||||
let mousePosition = this.blueprint.mousePosition;
|
||||
nodes.forEach(node => {
|
||||
const locationOffset = [
|
||||
@@ -3555,6 +3554,7 @@ class Paste extends IInput {
|
||||
node.snapToGrid();
|
||||
node.setSelected(true);
|
||||
});
|
||||
this.blueprint.addGraphElement(...nodes);
|
||||
return true
|
||||
}
|
||||
}
|
||||
@@ -4480,7 +4480,8 @@ class LinkElement extends IFromToPositionedElement {
|
||||
if (location == null) {
|
||||
const self = this;
|
||||
if (!this.hasUpdated || !this.destinationPin.hasUpdated) {
|
||||
Promise.all([this.updateComplete, this.destinationPin.updateComplete]).then(() => self.setDestinationLocation());
|
||||
Promise.all([this.updateComplete, this.destinationPin.updateComplete])
|
||||
.then(() => self.setDestinationLocation());
|
||||
return
|
||||
}
|
||||
location = this.destinationPin.template.getLinkLocation();
|
||||
@@ -4724,7 +4725,7 @@ class MouseMoveNodes extends MouseMoveDraggable {
|
||||
.filter(comment => !node.isInsideComment(comment))
|
||||
.forEach(comment => node.unbindFromComment(comment))
|
||||
);
|
||||
this.blueprint.getCommentNodes(true).forEach(comment =>
|
||||
this.blueprint.getCommentNodes().forEach(comment =>
|
||||
/** @type {CommentNodeTemplate} */(comment.template).manageNodesBind()
|
||||
);
|
||||
}
|
||||
@@ -4885,7 +4886,7 @@ class NodeTemplate extends ISelectableDraggableTemplate {
|
||||
firstUpdated(changedProperties) {
|
||||
super.firstUpdated(changedProperties);
|
||||
this.setupPins();
|
||||
Promise.all(this.element.getPinElements().map(n => n.updateComplete)).then(() => this.element.acknowledgeReflow());
|
||||
this.element.updateComplete.then(() => this.element.acknowledgeReflow());
|
||||
}
|
||||
|
||||
setupPins() {
|
||||
@@ -4985,29 +4986,33 @@ class IResizeableTemplate extends NodeTemplate {
|
||||
onDrag: (location, movement) => {
|
||||
movement[1] = location[1] - this.element.topBoundary();
|
||||
if (this.setSizeY(this.element.sizeY - movement[1])) {
|
||||
this.element.addLocation([0, movement[1]]);
|
||||
this.element.addLocation([0, movement[1]], false);
|
||||
}
|
||||
}
|
||||
},
|
||||
onEndDrag : () => this.endResize(),
|
||||
}),
|
||||
new MouseClickDrag(this.#RHandler, this.element.blueprint, {
|
||||
onDrag: (location, movement) => {
|
||||
movement[0] = location[0] - this.element.rightBoundary();
|
||||
this.setSizeX(this.element.sizeX + movement[0]);
|
||||
}
|
||||
},
|
||||
onEndDrag : () => this.endResize(),
|
||||
}),
|
||||
new MouseClickDrag(this.#BHandler, this.element.blueprint, {
|
||||
onDrag: (location, movement) => {
|
||||
movement[1] = location[1] - this.element.bottomBoundary();
|
||||
this.setSizeY(this.element.sizeY + movement[1]);
|
||||
}
|
||||
},
|
||||
onEndDrag : () => this.endResize(),
|
||||
}),
|
||||
new MouseClickDrag(this.#LHandler, this.element.blueprint, {
|
||||
onDrag: (location, movement) => {
|
||||
movement[0] = location[0] - this.element.leftBoundary();
|
||||
if (this.setSizeX(this.element.sizeX - movement[0])) {
|
||||
this.element.addLocation([movement[0], 0]);
|
||||
this.element.addLocation([movement[0], 0], false);
|
||||
}
|
||||
}
|
||||
},
|
||||
onEndDrag : () => this.endResize(),
|
||||
}),
|
||||
new MouseClickDrag(this.#TRHandler, this.element.blueprint, {
|
||||
onDrag: (location, movement) => {
|
||||
@@ -5015,9 +5020,10 @@ class IResizeableTemplate extends NodeTemplate {
|
||||
movement[1] = location[1] - this.element.topBoundary();
|
||||
this.setSizeX(this.element.sizeX + movement[0]);
|
||||
if (this.setSizeY(this.element.sizeY - movement[1])) {
|
||||
this.element.addLocation([0, movement[1]]);
|
||||
this.element.addLocation([0, movement[1]], false);
|
||||
}
|
||||
}
|
||||
},
|
||||
onEndDrag : () => this.endResize(),
|
||||
}),
|
||||
new MouseClickDrag(this.#BRHandler, this.element.blueprint, {
|
||||
onDrag: (location, movement) => {
|
||||
@@ -5025,29 +5031,32 @@ class IResizeableTemplate extends NodeTemplate {
|
||||
movement[1] = location[1] - this.element.bottomBoundary();
|
||||
this.setSizeX(this.element.sizeX + movement[0]);
|
||||
this.setSizeY(this.element.sizeY + movement[1]);
|
||||
}
|
||||
},
|
||||
onEndDrag : () => this.endResize(),
|
||||
}),
|
||||
new MouseClickDrag(this.#BLHandler, this.element.blueprint, {
|
||||
onDrag: (location, movement) => {
|
||||
movement[0] = location[0] - this.element.leftBoundary();
|
||||
movement[1] = location[1] - this.element.bottomBoundary();
|
||||
if (this.setSizeX(this.element.sizeX - movement[0])) {
|
||||
this.element.addLocation([movement[0], 0]);
|
||||
this.element.addLocation([movement[0], 0], false);
|
||||
}
|
||||
this.setSizeY(this.element.sizeY + movement[1]);
|
||||
}
|
||||
},
|
||||
onEndDrag : () => this.endResize(),
|
||||
}),
|
||||
new MouseClickDrag(this.#TLHandler, this.element.blueprint, {
|
||||
onDrag: (location, movement) => {
|
||||
movement[0] = location[0] - this.element.leftBoundary();
|
||||
movement[1] = location[1] - this.element.topBoundary();
|
||||
if (this.setSizeX(this.element.sizeX - movement[0])) {
|
||||
this.element.addLocation([movement[0], 0]);
|
||||
this.element.addLocation([movement[0], 0], false);
|
||||
}
|
||||
if (this.setSizeY(this.element.sizeY - movement[1])) {
|
||||
this.element.addLocation([0, movement[1]]);
|
||||
this.element.addLocation([0, movement[1]], false);
|
||||
}
|
||||
}
|
||||
},
|
||||
onEndDrag : () => this.endResize(),
|
||||
}),
|
||||
]
|
||||
}
|
||||
@@ -5063,6 +5072,8 @@ class IResizeableTemplate extends NodeTemplate {
|
||||
this.element.setNodeHeight(value);
|
||||
return true
|
||||
}
|
||||
|
||||
endResize() {}
|
||||
}
|
||||
|
||||
/**
|
||||
@@ -5094,14 +5105,6 @@ class CommentNodeTemplate extends IResizeableTemplate {
|
||||
return this.element.querySelector(".ueb-node-top")
|
||||
}
|
||||
|
||||
/** @param {Map} changedProperties */
|
||||
willUpdate(changedProperties) {
|
||||
super.willUpdate(changedProperties);
|
||||
if (changedProperties.has("sizeX") || changedProperties.has("sizeY")) {
|
||||
this.manageNodesBind();
|
||||
}
|
||||
}
|
||||
|
||||
render() {
|
||||
return y`
|
||||
<div class="ueb-node-border">
|
||||
@@ -5115,15 +5118,19 @@ class CommentNodeTemplate extends IResizeableTemplate {
|
||||
}
|
||||
|
||||
manageNodesBind() {
|
||||
this.element.blueprint
|
||||
.getNodes(false, [
|
||||
this.element.topBoundary(),
|
||||
this.element.rightBoundary(),
|
||||
this.element.bottomBoundary(),
|
||||
this.element.leftBoundary(),
|
||||
])
|
||||
.filter(node => !node.boundComments.includes(this.element))
|
||||
.forEach(node => node.bindToComment(this.element));
|
||||
let nodes = this.element.blueprint.getNodes();
|
||||
for (let node of nodes) {
|
||||
if (
|
||||
node.topBoundary() >= this.element.topBoundary()
|
||||
&& node.rightBoundary() <= this.element.rightBoundary()
|
||||
&& node.bottomBoundary() <= this.element.bottomBoundary()
|
||||
&& node.leftBoundary() >= this.element.leftBoundary()
|
||||
) {
|
||||
node.bindToComment(this.element);
|
||||
} else {
|
||||
node.unbindFromComment(this.element);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
/** @param {Number} value */
|
||||
@@ -5145,6 +5152,10 @@ class CommentNodeTemplate extends IResizeableTemplate {
|
||||
}
|
||||
return false
|
||||
}
|
||||
|
||||
endResize() {
|
||||
this.manageNodesBind();
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
@@ -5700,7 +5711,7 @@ class NodeElement extends ISelectableDraggableElement {
|
||||
this.sizeX = this.entity.NodeWidth.value;
|
||||
this.sizeY = this.entity.NodeHeight.value;
|
||||
} else {
|
||||
Promise.all([this.updateComplete, ...this.#pins.map(p => p.updateComplete)]).then(() => this.computeSizes());
|
||||
this.updateComplete.then(() => this.computeSizes());
|
||||
}
|
||||
}
|
||||
|
||||
@@ -5721,9 +5732,13 @@ class NodeElement extends ISelectableDraggableElement {
|
||||
return new NodeElement(entity)
|
||||
}
|
||||
|
||||
getUpdateComplete() {
|
||||
return Promise.all([super.getUpdateComplete(), ...this.#pins.map(pin => pin.updateComplete)]).then(() => true)
|
||||
}
|
||||
|
||||
/** @param {NodeElement} commentNode */
|
||||
bindToComment(commentNode) {
|
||||
if (!this.boundComments.includes(commentNode)) {
|
||||
if (commentNode != this && !this.boundComments.includes(commentNode)) {
|
||||
commentNode.addEventListener(Configuration.nodeDragEventName, this.#commentDragHandler);
|
||||
this.boundComments.push(commentNode);
|
||||
}
|
||||
@@ -5808,13 +5823,13 @@ class NodeElement extends ISelectableDraggableElement {
|
||||
return this.entity.CustomProperties.filter(v => v instanceof PinEntity)
|
||||
}
|
||||
|
||||
setLocation(value = [0, 0]) {
|
||||
setLocation(value = [0, 0], acknowledge = true) {
|
||||
let nodeConstructor = this.entity.NodePosX.constructor;
|
||||
// @ts-expect-error
|
||||
this.entity.NodePosX = new nodeConstructor(value[0]);
|
||||
// @ts-expect-error
|
||||
this.entity.NodePosY = new nodeConstructor(value[1]);
|
||||
super.setLocation(value);
|
||||
super.setLocation(value, acknowledge);
|
||||
}
|
||||
|
||||
acknowledgeDelete() {
|
||||
@@ -6442,7 +6457,7 @@ class Blueprint extends IElement {
|
||||
|| l > Number.MIN_SAFE_INTEGER
|
||||
) {
|
||||
result = result.filter(n => {
|
||||
return n.topBoundary() > t && n.rightBoundary() < r && n.bottomBoundary() < b && n.leftBoundary() > l
|
||||
return n.topBoundary() >= t && n.rightBoundary() <= r && n.bottomBoundary() <= b && n.leftBoundary() >= l
|
||||
});
|
||||
}
|
||||
return result
|
||||
@@ -6529,11 +6544,6 @@ class Blueprint extends IElement {
|
||||
}
|
||||
this.nodes.push(element);
|
||||
this.nodesContainerElement?.appendChild(element);
|
||||
if (element.getType() == Configuration.nodeType.comment) {
|
||||
element.addNextUpdatedCallbacks(() =>
|
||||
/** @type {CommentNodeTemplate} */(element.template).manageNodesBind()
|
||||
);
|
||||
}
|
||||
} else if (element instanceof LinkElement && !this.links.includes(element)) {
|
||||
this.links.push(element);
|
||||
if (this.linksContainerElement && !this.linksContainerElement.contains(element)) {
|
||||
@@ -6544,6 +6554,11 @@ class Blueprint extends IElement {
|
||||
graphElements.filter(element => element instanceof NodeElement).forEach(
|
||||
node => /** @type {NodeElement} */(node).sanitizeLinks(graphElements)
|
||||
);
|
||||
graphElements
|
||||
.filter(element => element instanceof NodeElement && element.getType() == Configuration.nodeType.comment)
|
||||
.forEach(element => element.updateComplete.then(() =>
|
||||
/** @type {CommentNodeTemplate} */(element.template).manageNodesBind()
|
||||
));
|
||||
}
|
||||
|
||||
/** @param {...IElement} graphElements */
|
||||
|
||||
6
dist/ueblueprint.min.js
vendored
6
dist/ueblueprint.min.js
vendored
File diff suppressed because one or more lines are too long
@@ -290,7 +290,7 @@ export default class Blueprint extends IElement {
|
||||
|| l > Number.MIN_SAFE_INTEGER
|
||||
) {
|
||||
result = result.filter(n => {
|
||||
return n.topBoundary() > t && n.rightBoundary() < r && n.bottomBoundary() < b && n.leftBoundary() > l
|
||||
return n.topBoundary() >= t && n.rightBoundary() <= r && n.bottomBoundary() <= b && n.leftBoundary() >= l
|
||||
})
|
||||
}
|
||||
return result
|
||||
@@ -379,11 +379,6 @@ export default class Blueprint extends IElement {
|
||||
this.nodes.push(element)
|
||||
nodeElements.push(element)
|
||||
this.nodesContainerElement?.appendChild(element)
|
||||
if (element.getType() == Configuration.nodeType.comment) {
|
||||
element.addNextUpdatedCallbacks(() =>
|
||||
/** @type {CommentNodeTemplate} */(element.template).manageNodesBind()
|
||||
)
|
||||
}
|
||||
} else if (element instanceof LinkElement && !this.links.includes(element)) {
|
||||
this.links.push(element)
|
||||
if (this.linksContainerElement && !this.linksContainerElement.contains(element)) {
|
||||
@@ -394,6 +389,11 @@ export default class Blueprint extends IElement {
|
||||
graphElements.filter(element => element instanceof NodeElement).forEach(
|
||||
node => /** @type {NodeElement} */(node).sanitizeLinks(graphElements)
|
||||
)
|
||||
graphElements
|
||||
.filter(element => element instanceof NodeElement && element.getType() == Configuration.nodeType.comment)
|
||||
.forEach(element => element.updateComplete.then(() =>
|
||||
/** @type {CommentNodeTemplate} */(element.template).manageNodesBind()
|
||||
))
|
||||
}
|
||||
|
||||
/** @param {...IElement} graphElements */
|
||||
|
||||
@@ -62,26 +62,26 @@ export default class IDraggableElement extends IElement {
|
||||
}
|
||||
|
||||
/** @param {Number[]} param0 */
|
||||
setLocation([x, y]) {
|
||||
setLocation([x, y], acknowledge = true) {
|
||||
const d = [x - this.locationX, y - this.locationY]
|
||||
this.locationX = x
|
||||
this.locationY = y
|
||||
if (this.blueprint) {
|
||||
if (this.blueprint && acknowledge) {
|
||||
// @ts-expect-error
|
||||
const dragLocalEvent = new CustomEvent(this.constructor.dragEventName, {
|
||||
detail: {
|
||||
value: d,
|
||||
},
|
||||
bubbles: false,
|
||||
cancelable: true
|
||||
cancelable: true,
|
||||
})
|
||||
this.dispatchEvent(dragLocalEvent)
|
||||
}
|
||||
}
|
||||
|
||||
/** @param {Number[]} param0 */
|
||||
addLocation([x, y]) {
|
||||
this.setLocation([this.locationX + x, this.locationY + y])
|
||||
addLocation([x, y], acknowledge = true) {
|
||||
this.setLocation([this.locationX + x, this.locationY + y], acknowledge)
|
||||
}
|
||||
|
||||
/** @param {Number[]} value */
|
||||
|
||||
@@ -199,7 +199,8 @@ export default class LinkElement extends IFromToPositionedElement {
|
||||
if (location == null) {
|
||||
const self = this
|
||||
if (!this.hasUpdated || !this.destinationPin.hasUpdated) {
|
||||
Promise.all([this.updateComplete, this.destinationPin.updateComplete]).then(() => self.setDestinationLocation())
|
||||
Promise.all([this.updateComplete, this.destinationPin.updateComplete])
|
||||
.then(() => self.setDestinationLocation())
|
||||
return
|
||||
}
|
||||
location = this.destinationPin.template.getLinkLocation()
|
||||
|
||||
@@ -111,7 +111,7 @@ export default class NodeElement extends ISelectableDraggableElement {
|
||||
this.sizeX = this.entity.NodeWidth.value
|
||||
this.sizeY = this.entity.NodeHeight.value
|
||||
} else {
|
||||
Promise.all([this.updateComplete, ...this.#pins.map(p => p.updateComplete)]).then(() => this.computeSizes())
|
||||
this.updateComplete.then(() => this.computeSizes())
|
||||
}
|
||||
}
|
||||
|
||||
@@ -132,9 +132,13 @@ export default class NodeElement extends ISelectableDraggableElement {
|
||||
return new NodeElement(entity)
|
||||
}
|
||||
|
||||
getUpdateComplete() {
|
||||
return Promise.all([super.getUpdateComplete(), ...this.#pins.map(pin => pin.updateComplete)]).then(() => true)
|
||||
}
|
||||
|
||||
/** @param {NodeElement} commentNode */
|
||||
bindToComment(commentNode) {
|
||||
if (!this.boundComments.includes(commentNode)) {
|
||||
if (commentNode != this && !this.boundComments.includes(commentNode)) {
|
||||
commentNode.addEventListener(Configuration.nodeDragEventName, this.#commentDragHandler)
|
||||
this.boundComments.push(commentNode)
|
||||
}
|
||||
@@ -219,13 +223,13 @@ export default class NodeElement extends ISelectableDraggableElement {
|
||||
return this.entity.CustomProperties.filter(v => v instanceof PinEntity)
|
||||
}
|
||||
|
||||
setLocation(value = [0, 0]) {
|
||||
setLocation(value = [0, 0], acknowledge = true) {
|
||||
let nodeConstructor = this.entity.NodePosX.constructor
|
||||
// @ts-expect-error
|
||||
this.entity.NodePosX = new nodeConstructor(value[0])
|
||||
// @ts-expect-error
|
||||
this.entity.NodePosY = new nodeConstructor(value[1])
|
||||
super.setLocation(value)
|
||||
super.setLocation(value, acknowledge)
|
||||
}
|
||||
|
||||
acknowledgeDelete() {
|
||||
|
||||
@@ -9,7 +9,7 @@ export default class LinearColorEntity extends IEntity {
|
||||
R: RealUnitEntity,
|
||||
G: RealUnitEntity,
|
||||
B: RealUnitEntity,
|
||||
A: new TypeInitialization(RealUnitEntity, true, () => new RealUnitEntity(1), false, true),
|
||||
A: new TypeInitialization(RealUnitEntity, true, () => new RealUnitEntity(1), false, false),
|
||||
H: new TypeInitialization(RealUnitEntity, true, undefined, false, true),
|
||||
S: new TypeInitialization(RealUnitEntity, true, undefined, false, true),
|
||||
V: new TypeInitialization(RealUnitEntity, true, undefined, false, true),
|
||||
|
||||
@@ -45,7 +45,6 @@ export default class Paste extends IInput {
|
||||
if (nodes.length > 0) {
|
||||
this.blueprint.unselectAll()
|
||||
}
|
||||
this.blueprint.addGraphElement(...nodes)
|
||||
let mousePosition = this.blueprint.mousePosition
|
||||
nodes.forEach(node => {
|
||||
const locationOffset = [
|
||||
@@ -56,6 +55,7 @@ export default class Paste extends IInput {
|
||||
node.snapToGrid()
|
||||
node.setSelected(true)
|
||||
})
|
||||
this.blueprint.addGraphElement(...nodes)
|
||||
return true
|
||||
}
|
||||
}
|
||||
|
||||
@@ -30,7 +30,7 @@ export default class MouseMoveNodes extends MouseMoveDraggable {
|
||||
.filter(comment => !node.isInsideComment(comment))
|
||||
.forEach(comment => node.unbindFromComment(comment))
|
||||
)
|
||||
this.blueprint.getCommentNodes(true).forEach(comment =>
|
||||
this.blueprint.getCommentNodes().forEach(comment =>
|
||||
/** @type {CommentNodeTemplate} */(comment.template).manageNodesBind()
|
||||
)
|
||||
}
|
||||
|
||||
@@ -32,14 +32,6 @@ export default class CommentNodeTemplate extends IResizeableTemplate {
|
||||
return this.element.querySelector(".ueb-node-top")
|
||||
}
|
||||
|
||||
/** @param {Map} changedProperties */
|
||||
willUpdate(changedProperties) {
|
||||
super.willUpdate(changedProperties)
|
||||
if (changedProperties.has("sizeX") || changedProperties.has("sizeY")) {
|
||||
this.manageNodesBind()
|
||||
}
|
||||
}
|
||||
|
||||
render() {
|
||||
return html`
|
||||
<div class="ueb-node-border">
|
||||
@@ -53,15 +45,19 @@ export default class CommentNodeTemplate extends IResizeableTemplate {
|
||||
}
|
||||
|
||||
manageNodesBind() {
|
||||
this.element.blueprint
|
||||
.getNodes(false, [
|
||||
this.element.topBoundary(),
|
||||
this.element.rightBoundary(),
|
||||
this.element.bottomBoundary(),
|
||||
this.element.leftBoundary(),
|
||||
])
|
||||
.filter(node => !node.boundComments.includes(this.element))
|
||||
.forEach(node => node.bindToComment(this.element))
|
||||
let nodes = this.element.blueprint.getNodes()
|
||||
for (let node of nodes) {
|
||||
if (
|
||||
node.topBoundary() >= this.element.topBoundary()
|
||||
&& node.rightBoundary() <= this.element.rightBoundary()
|
||||
&& node.bottomBoundary() <= this.element.bottomBoundary()
|
||||
&& node.leftBoundary() >= this.element.leftBoundary()
|
||||
) {
|
||||
node.bindToComment(this.element)
|
||||
} else {
|
||||
node.unbindFromComment(this.element)
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
/** @param {Number} value */
|
||||
@@ -83,4 +79,8 @@ export default class CommentNodeTemplate extends IResizeableTemplate {
|
||||
}
|
||||
return false
|
||||
}
|
||||
|
||||
endResize() {
|
||||
this.manageNodesBind()
|
||||
}
|
||||
}
|
||||
|
||||
@@ -61,29 +61,33 @@ export default class IResizeableTemplate extends NodeTemplate {
|
||||
onDrag: (location, movement) => {
|
||||
movement[1] = location[1] - this.element.topBoundary()
|
||||
if (this.setSizeY(this.element.sizeY - movement[1])) {
|
||||
this.element.addLocation([0, movement[1]])
|
||||
this.element.addLocation([0, movement[1]], false)
|
||||
}
|
||||
}
|
||||
},
|
||||
onEndDrag : () => this.endResize(),
|
||||
}),
|
||||
new MouseClickDrag(this.#RHandler, this.element.blueprint, {
|
||||
onDrag: (location, movement) => {
|
||||
movement[0] = location[0] - this.element.rightBoundary()
|
||||
this.setSizeX(this.element.sizeX + movement[0])
|
||||
}
|
||||
},
|
||||
onEndDrag : () => this.endResize(),
|
||||
}),
|
||||
new MouseClickDrag(this.#BHandler, this.element.blueprint, {
|
||||
onDrag: (location, movement) => {
|
||||
movement[1] = location[1] - this.element.bottomBoundary()
|
||||
this.setSizeY(this.element.sizeY + movement[1])
|
||||
}
|
||||
},
|
||||
onEndDrag : () => this.endResize(),
|
||||
}),
|
||||
new MouseClickDrag(this.#LHandler, this.element.blueprint, {
|
||||
onDrag: (location, movement) => {
|
||||
movement[0] = location[0] - this.element.leftBoundary()
|
||||
if (this.setSizeX(this.element.sizeX - movement[0])) {
|
||||
this.element.addLocation([movement[0], 0])
|
||||
this.element.addLocation([movement[0], 0], false)
|
||||
}
|
||||
}
|
||||
},
|
||||
onEndDrag : () => this.endResize(),
|
||||
}),
|
||||
new MouseClickDrag(this.#TRHandler, this.element.blueprint, {
|
||||
onDrag: (location, movement) => {
|
||||
@@ -91,9 +95,10 @@ export default class IResizeableTemplate extends NodeTemplate {
|
||||
movement[1] = location[1] - this.element.topBoundary()
|
||||
this.setSizeX(this.element.sizeX + movement[0])
|
||||
if (this.setSizeY(this.element.sizeY - movement[1])) {
|
||||
this.element.addLocation([0, movement[1]])
|
||||
this.element.addLocation([0, movement[1]], false)
|
||||
}
|
||||
}
|
||||
},
|
||||
onEndDrag : () => this.endResize(),
|
||||
}),
|
||||
new MouseClickDrag(this.#BRHandler, this.element.blueprint, {
|
||||
onDrag: (location, movement) => {
|
||||
@@ -101,29 +106,32 @@ export default class IResizeableTemplate extends NodeTemplate {
|
||||
movement[1] = location[1] - this.element.bottomBoundary()
|
||||
this.setSizeX(this.element.sizeX + movement[0])
|
||||
this.setSizeY(this.element.sizeY + movement[1])
|
||||
}
|
||||
},
|
||||
onEndDrag : () => this.endResize(),
|
||||
}),
|
||||
new MouseClickDrag(this.#BLHandler, this.element.blueprint, {
|
||||
onDrag: (location, movement) => {
|
||||
movement[0] = location[0] - this.element.leftBoundary()
|
||||
movement[1] = location[1] - this.element.bottomBoundary()
|
||||
if (this.setSizeX(this.element.sizeX - movement[0])) {
|
||||
this.element.addLocation([movement[0], 0])
|
||||
this.element.addLocation([movement[0], 0], false)
|
||||
}
|
||||
this.setSizeY(this.element.sizeY + movement[1])
|
||||
}
|
||||
},
|
||||
onEndDrag : () => this.endResize(),
|
||||
}),
|
||||
new MouseClickDrag(this.#TLHandler, this.element.blueprint, {
|
||||
onDrag: (location, movement) => {
|
||||
movement[0] = location[0] - this.element.leftBoundary()
|
||||
movement[1] = location[1] - this.element.topBoundary()
|
||||
if (this.setSizeX(this.element.sizeX - movement[0])) {
|
||||
this.element.addLocation([movement[0], 0])
|
||||
this.element.addLocation([movement[0], 0], false)
|
||||
}
|
||||
if (this.setSizeY(this.element.sizeY - movement[1])) {
|
||||
this.element.addLocation([0, movement[1]])
|
||||
this.element.addLocation([0, movement[1]], false)
|
||||
}
|
||||
}
|
||||
},
|
||||
onEndDrag : () => this.endResize(),
|
||||
}),
|
||||
]
|
||||
}
|
||||
@@ -139,4 +147,6 @@ export default class IResizeableTemplate extends NodeTemplate {
|
||||
this.element.setNodeHeight(value)
|
||||
return true
|
||||
}
|
||||
|
||||
endResize() {}
|
||||
}
|
||||
|
||||
@@ -129,7 +129,7 @@ export default class NodeTemplate extends ISelectableDraggableTemplate {
|
||||
firstUpdated(changedProperties) {
|
||||
super.firstUpdated(changedProperties)
|
||||
this.setupPins()
|
||||
Promise.all(this.element.getPinElements().map(n => n.updateComplete)).then(() => this.element.acknowledgeReflow())
|
||||
this.element.updateComplete.then(() => this.element.acknowledgeReflow())
|
||||
}
|
||||
|
||||
setupPins() {
|
||||
|
||||
@@ -1,6 +1,7 @@
|
||||
@use "style.scss";
|
||||
|
||||
ueb-link {
|
||||
position: absolute;
|
||||
--ueb-link-color: rgb(var(--ueb-link-color-rgb));
|
||||
--ueb-from-input-coefficient: calc(2 * var(--ueb-from-input) - 1);
|
||||
/* when from-y > to-y */
|
||||
@@ -13,7 +14,7 @@ ueb-link {
|
||||
* their hover behavior correctly firing.
|
||||
*/
|
||||
visibility: hidden;
|
||||
@extend .ueb-positioned;
|
||||
z-index: 2;
|
||||
}
|
||||
|
||||
ueb-link>svg {
|
||||
|
||||
@@ -241,8 +241,8 @@ ueb-node.ueb-node-style-glass .ueb-node-outputs:first-child {
|
||||
padding-left: 8px;
|
||||
}
|
||||
|
||||
ueb-node.ueb-node-style-comment {
|
||||
z-index: -1;
|
||||
ueb-node:not(.ueb-node-style-comment) {
|
||||
z-index: 10;
|
||||
}
|
||||
|
||||
ueb-node.ueb-node-style-comment .ueb-node-border {
|
||||
@@ -282,6 +282,7 @@ ueb-node.ueb-node-style-comment .ueb-node-wrapper {
|
||||
}
|
||||
|
||||
ueb-node.ueb-node-style-comment .ueb-node-top {
|
||||
position: relative;
|
||||
margin: 3px;
|
||||
padding: 3px 10px;
|
||||
box-shadow: none;
|
||||
@@ -290,4 +291,5 @@ ueb-node.ueb-node-style-comment .ueb-node-top {
|
||||
color: white;
|
||||
font-size: 24px;
|
||||
text-shadow: 2px 1px 1px #444, 0 0 2px #bbb;
|
||||
z-index: 1;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user