Behaviour SwRS-MDOKFSTUDIO-FMSCHEMA-004
The propertiesTable setting hides the table while the body renders
When `markdownOkfSchemaStudio.frontmatter.propertiesTable` is false, the extension SHALL show neither the properties table nor the raw frontmatter text and still render the body of the document.
Another outcome at step 1 of path 1 in StRS-MDOKFSTUDIO-FMSCHEMA-001, in the state “A document starts with a `---` line and a YAML mapping”.
Scenarios 5
The situations the tests check; open one to read it.
nominalSetting off
Givena document with frontmatter and the heading `# Title`, with `frontmatter.propertiesTable` set to false
Whenthe preview is rendered
Thenno properties table and no frontmatter text appear and the heading Title is rendered at the top of the preview
nominalSetting at its default
Giventhe same document with `frontmatter.propertiesTable` unset (default true, boolean, no other accepted value)
Whenthe preview is rendered
Thenthe properties table is shown above the heading
boundaryDocument without frontmatter
Givena document without frontmatter and the setting false
Whenthe preview is rendered
Thenthe body is rendered as with the setting on
nominalA frontmatter setting change re-analyses the open previews
Givenan open preview of the active document with an undeclared field
When`frontmatter.strictAdditionalProperties` is changed to true
Thenthe open table shows the unknown-field warning without reopening the preview
boundaryWhich setting changes re-analyse
| Input | Outcome |
|---|---|
| Any `markdownOkfSchemaStudio.frontmatter.*` setting changes | The frontmatter settings of every open preview are read again and the table of each preview whose document is the active editor's document is re-analysed |
| A change to a setting outside the preview, plantuml and frontmatter sections | The open previews are not re-analysed |
| A change in the preview or plantuml section | The same refresh runs; other previews are re-rendered from their last good render with the new settings, not re-analysed |
Implemented in 4
Tested by 3
Known limits (2)
- the frontmatter is still parsed and validated while the table is off; nothing is shown, so a schema problem cannot be seen.
- a preview whose document is not the active editor's document is not re-analysed by this path; it only re-renders from its last good render.
Replaces
SwRS-MDOKFSTUDIO-FMSCHEMA-045A frontmatter setting change re-analyses the open previews superseded superseded by SwRS-MDOKFSTUDIO-FMSCHEMA-004 Markdown file
SwRS-MDOKFSTUDIO-FMSCHEMA-075The body still renders when the table is off superseded superseded by SwRS-MDOKFSTUDIO-FMSCHEMA-004 Markdown file