Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions src/commands/olist.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -15,8 +15,8 @@ export const olist: ICommand = {
execute: ({ state, view }) => {
if (!state || !view) return;
const lineInfo = view.state.doc.lineAt(view.state.selection.main.from);
let mark = '- ';
const matchMark = lineInfo.text.match(/^-/);
let mark = '1. ';
const matchMark = lineInfo.text.match(/^\1\./);
if (matchMark && matchMark[0]) {
mark = '';
}
Expand Down
4 changes: 2 additions & 2 deletions src/commands/ulist.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -16,8 +16,8 @@ export const ulist: ICommand = {
execute: ({ state, view }) => {
if (!state || !view) return;
const lineInfo = view.state.doc.lineAt(view.state.selection.main.from);
let mark = '1. ';
const matchMark = lineInfo.text.match(/^\1\./);
let mark = '- ';
const matchMark = lineInfo.text.match(/^-/);
if (matchMark && matchMark[0]) {
mark = '';
}
Expand Down