Hide YAML frontmatter from editor view
- Add frontmatterHide extension that hides --- ... --- block at top of files - Shows collapsed --- indicator, reveals on cursor focus - Place initial cursor after frontmatter so content is visible on load - Remove frontmatter detection from livePreview (handled by dedicated extension) - Add Playwright test for frontmatter hiding Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
This commit is contained in:
@@ -30,6 +30,7 @@ class HrWidget extends WidgetType {
|
||||
|
||||
function buildDecorations(view: EditorView): DecorationSet {
|
||||
const decs: Range<Decoration>[] = []
|
||||
|
||||
const tree = syntaxTree(view.state)
|
||||
|
||||
tree.iterate({
|
||||
|
||||
Reference in New Issue
Block a user