mirror of
https://github.com/pipipi-pikachu/PPTist.git
synced 2025-04-15 02:20:00 +08:00
perf: 文本框优化
This commit is contained in:
parent
62289a87db
commit
7bcbae1782
@ -8,6 +8,8 @@ import {
|
||||
selectParentNode,
|
||||
joinUp,
|
||||
joinDown,
|
||||
chainCommands,
|
||||
splitBlockKeepMarks,
|
||||
} from 'prosemirror-commands'
|
||||
|
||||
export const buildKeymap = (schema: Schema) => {
|
||||
@ -24,8 +26,7 @@ export const buildKeymap = (schema: Schema) => {
|
||||
bind('Ctrl-i', toggleMark(schema.marks.em))
|
||||
bind('Ctrl-u', toggleMark(schema.marks.underline))
|
||||
bind('Ctrl-d', toggleMark(schema.marks.strikethrough))
|
||||
|
||||
bind('Enter', splitListItem(schema.nodes.list_item))
|
||||
bind('Enter', chainCommands(splitListItem(schema.nodes.list_item), splitBlockKeepMarks))
|
||||
bind('Mod-[', liftListItem(schema.nodes.list_item))
|
||||
bind('Mod-]', sinkListItem(schema.nodes.list_item))
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user