Markdown OKF-Schema Studio

Behaviour SwRS-MDOKFSTUDIO-LIFE-024

The panel title names the document and whether it follows

When a preview panel is created, restored, switched to another document or finishes a render, the extension SHALL title the side preview Studio · {file name}, a fixed preview with the bare file name, and a panel with no known document Studio, using the title of the document the panel shows.

Part of StRS-MDOKFSTUDIO-LIFE-003, outside the paths drawn on its map.

Scenarios 4

The situations the tests check; open one to read it.

nominalSide preview
Giventhe side preview following the editor on notes.md
Whenthe panel is created
Thenits title is Studio · notes.md (integration test test/integration/lifecycle.test.ts)
boundaryFixed preview and panel without a document
InputOutcome
an Open With tab on notes.md, createdtitle notes.md, without the Studio prefix
an older restored panel on notes.mdtitle notes.md, without the Studio prefix (integration test test/integration/serializer.test.ts, older panel does not match /^Studio/)
a panel with no documenttitle Studio
nominalSwitch
Givena side preview titled Studio · preview.md
Whenthe reader makes preview-other.md the active editor
Thenthe title becomes Studio · preview-other.md
nominalRender finished
Givena preview whose title was set before its first render
Whena render of the shown document finishes
Thenthe title is set again from the rendered file's path, with the same role prefix

Implemented in 2

Tested by 3