Closed SimplGy closed 2 years ago
Possibly answering my own question here; would you say this is the right pattern to follow when adjusting the symbols added to decorate things in the editor panel?
https://github.com/aidenlx/table-extended/blob/master/src/tx-main.ts#L99
I don't think it would be easy to extend the parser at the moment. You might have to write an overlay mode and have it injected to the codemirror instances.
The link you provided hooks to the preview rendering rather than editor.
Maybe looking at https://github.com/SimplGy/obsidian-codemirror-options is the closest analogue. Noting that there's probably a pretty up-and-coming change the codemirror api level going to be used...
I'd like to extend the HyperMD / markdown parser, by matching patterns and adding css classnames if certain lines match a regex.
Is there an example that does this?
I can see how to style existing css classnames, but not how to add new classnames to the generated editor markup.
Thanks!