mirror of
https://github.com/Comfy-Org/ComfyUI_frontend.git
synced 2026-04-29 18:52:19 +00:00
Fix cloning pinned nodes (#364)
This commit is contained in:
@@ -2698,10 +2698,10 @@ export class LGraphNode implements Positionable, IPinnable {
|
|||||||
* Toggles pinned state if no value is provided.
|
* Toggles pinned state if no value is provided.
|
||||||
*/
|
*/
|
||||||
pin(v?: boolean): void {
|
pin(v?: boolean): void {
|
||||||
this.graph._version++
|
if (this.graph) {
|
||||||
this.flags.pinned = v === undefined
|
this.graph._version++
|
||||||
? !this.flags.pinned
|
}
|
||||||
: v
|
this.flags.pinned = v ?? !this.flags.pinned
|
||||||
this.resizable = !this.pinned
|
this.resizable = !this.pinned
|
||||||
// Delete the flag if unpinned, so that we don't get unnecessary
|
// Delete the flag if unpinned, so that we don't get unnecessary
|
||||||
// flags.pinned = false in serialized object.
|
// flags.pinned = false in serialized object.
|
||||||
|
|||||||
Reference in New Issue
Block a user