treehousedev / treehouse

https://treehouse.sh
MIT License
154 stars 12 forks source link

Remove cut nodes from view #287

Closed ArcaTech closed 1 year ago

ArcaTech commented 1 year ago

This adds a new cut attr to nodes when they're cut, and adds a cut-node class that sets display to none.

@taramk let me know how you feel about it.

Closes #274

progrium commented 1 year ago

Since attributes are persisted but clipboard state isn't, this could lead to inconsistent state across a page reload. Instead of storing it in an attribute, maybe you could just check the clipboard state if the node is in there?

ArcaTech commented 1 year ago

Oh yeah actually that makes more sense. I'll do that.

ArcaTech commented 1 year ago

Ok @progrium I made the change. Much cleaner.