feat: enhance RichTextInput configuration to prevent duplicate extensions when rich text is enabled (#24009)
This commit is contained in:
@@ -737,6 +737,17 @@
|
|||||||
StarterKit.configure({
|
StarterKit.configure({
|
||||||
link: link,
|
link: link,
|
||||||
code: false, // Disabled in favor of FixedCode (see workaround above)
|
code: false, // Disabled in favor of FixedCode (see workaround above)
|
||||||
|
// When rich text is on, ListKit + CodeBlockLowlight provide these.
|
||||||
|
// Disable StarterKit's equivalents to avoid duplicate extension names.
|
||||||
|
...(richText
|
||||||
|
? {
|
||||||
|
codeBlock: false,
|
||||||
|
bulletList: false,
|
||||||
|
orderedList: false,
|
||||||
|
listItem: false,
|
||||||
|
listKeymap: false
|
||||||
|
}
|
||||||
|
: {}),
|
||||||
// When rich text is off, disable Strike from StarterKit so we can
|
// When rich text is off, disable Strike from StarterKit so we can
|
||||||
// re-add it below without its Mod-Shift-s shortcut (which conflicts
|
// re-add it below without its Mod-Shift-s shortcut (which conflicts
|
||||||
// with the Toggle Sidebar shortcut). When rich text is on, the user
|
// with the Toggle Sidebar shortcut). When rich text is on, the user
|
||||||
|
|||||||
Reference in New Issue
Block a user