Skip to content

Commit

Permalink
When a line begins with a tag, insert a space so that Foundry does no…
Browse files Browse the repository at this point in the history
…t think it's a header.
  • Loading branch information
chase-burke committed Feb 14, 2024
1 parent bd98eb9 commit 82ab855
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 1 deletion.
1 change: 1 addition & 0 deletions src/lava-flow.ts
Original file line number Diff line number Diff line change
Expand Up @@ -267,6 +267,7 @@ export default class LavaFlow {
let originalText = await file.originalFile.text();
if (originalText !== null && originalText.length > 6)
originalText = originalText.replace(/^---\r?\n([^-].*\r?\n)+---(\r?\n)+/, '');
originalText = originalText.replace(/^#[0-9A-Za-z]+\b/gm, ' $&');
return originalText;
}

Expand Down
4 changes: 3 additions & 1 deletion test/Test Vault/Formats.md
Original file line number Diff line number Diff line change
Expand Up @@ -167,4 +167,6 @@ First Header | Second Header
- [x] this is a complete item
- [?] this is also a complete item (works with every character)
- [ ] this is an incomplete item
- [ ] tasks can be clicked in Preview to be checked off
- [ ] tasks can be clicked in Preview to be checked off
# Tags
#thisIsNotAHeader

0 comments on commit 82ab855

Please sign in to comment.