feat(admonitions): allow changing admonition type

This commit is contained in:
Elian Doran
2025-03-13 22:20:12 +02:00
parent fb7e310224
commit 504879b11c
2 changed files with 22 additions and 10 deletions

View File

@@ -162,6 +162,10 @@ export default class AdmonitionCommand extends Command {
quote = writer.createElement( 'aside', { type });
writer.wrap( groupRange, quote );
} else if (quote.is("element")) {
this.editor.model.change((writer) => {
writer.setAttribute("type", type, quote as Element);
});
}
quotesToMerge.push( quote );