openpencil/packages/docs/user-guide
Danila Poyarkov 6c6f24409e
feat: let a collection name the attribute its modes switch by (#913)
* feat: let a collection name the attribute its modes switch by

Manually switched modes were always selected by data-<collection name>, so a collection called New wrote data-new and a codebase already using data-color-scheme could not be matched. A collection can now name its attribute in the inspector, validated so a stylesheet can select it as is. The stylesheet and exported code use it, setting it is undoable, and .fig files keep it in the collection's plugin data.

* fix: show the switch attribute only where there are modes to switch

* fix: return to the list after committing the switch attribute

* fix: keep a collection's switch attribute when a new one is refused

setModeAttribute cleared the attribute when given a name a stylesheet cannot select on; it now leaves the current one, and only an empty name restores the default. In the inspector, Enter on a refused name keeps the focus so it can be corrected.

* docs: describe the switch attribute in the mode conditions

The Switched manually row still said the attribute is named after the collection. The changelog had collected four copies of the variables dialog entry through rebases; one remains, with the switch attribute in it.
2026-10-06 12:35:41 +00:00
..
auto-layout.md fix: match Figma when dragging, drawing, duplicating, and pasting (#894) 2026-10-05 12:39:03 +00:00
canvas-navigation.md feat(app): show who works on each page (#815) 2026-10-04 01:18:16 +04:00
checking-designs.md feat(lint): suggest group-to-frame and hidden-layer fixes; keep canvas edits in code previews (#870) 2026-10-04 12:46:06 +00:00
components.md fix: share Figma's creation and grouping between editor and plugin API (#919) 2026-10-06 12:28:52 +00:00
context-menu.md fix: share Figma's creation and grouping between editor and plugin API (#919) 2026-10-06 12:28:52 +00:00
drawing-shapes.md fix: share Figma's creation and grouping between editor and plugin API (#919) 2026-10-06 12:28:52 +00:00
exporting.md feat: open documents dropped onto the window (#906) 2026-10-05 14:24:43 +00:00
index.md feat: check designs live with a Lint panel, canvas markers, and fixes (#804) 2026-10-04 10:08:39 +00:00
layers-and-pages.md docs: clarify recovery cleanup and browser font scope 2026-09-15 23:19:29 +03:00
pen-tool.md update pen tool space drag spec 2026-03-27 21:27:45 +05:00
selection-and-manipulation.md feat: select layers at Figma's click depth (#900) 2026-10-05 12:39:04 +00:00
text-editing.md docs: clarify recovery cleanup and browser font scope 2026-09-15 23:19:29 +03:00
variables.md feat: let a collection name the attribute its modes switch by (#913) 2026-10-06 12:35:41 +00:00
vector-edit.md Quote vector edit docs descriptions 2026-03-27 21:54:54 +03:00