(id, push = true)
| 4667 | } |
| 4668 | |
| 4669 | function toggleSelectElement(id, push = true) { |
| 4670 | if (!selectedIds || !(selectedIds instanceof Set)) selectedIds = new Set(); |
| 4671 | if (selectedIds.has(id)) { |
| 4672 | selectedIds.delete(id); |
| 4673 | } else { |
| 4674 | selectedIds.add(id); |
| 4675 | selectedId = id; |
| 4676 | } |
| 4677 | if (!selectedIds.size) selectedId = null; |
| 4678 | updatePropsInputs(); |
| 4679 | renderElements(); |
| 4680 | renderLayers(); |
| 4681 | if (push) pushHistory(); |
| 4682 | } |
| 4683 | |
| 4684 | function getLayerLabel(el) { |
| 4685 | const t = String(el.type || "element"); |
no test coverage detected