@portabletext/editor 1.12.1 → 1.12.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/lib/index.esm.js +2 -2
- package/lib/index.esm.js.map +1 -1
- package/lib/index.js +2 -2
- package/lib/index.js.map +1 -1
- package/lib/index.mjs +2 -2
- package/lib/index.mjs.map +1 -1
- package/package.json +1 -1
- package/src/editor/behavior/behavior.markdown.ts +2 -2
package/lib/index.js
CHANGED
|
@@ -748,9 +748,9 @@ function createMarkdownBehaviors(config) {
|
|
|
748
748
|
listItemLength: 1,
|
|
749
749
|
style: defaultStyle
|
|
750
750
|
};
|
|
751
|
-
const looksLikeOrderedList = /^1
|
|
751
|
+
const looksLikeOrderedList = /^1\./.test(blockText), orderedListStyle = config.orderedListStyle?.({
|
|
752
752
|
schema: context.schema
|
|
753
|
-
}), caretAtTheEndOfOrderedList =
|
|
753
|
+
}), caretAtTheEndOfOrderedList = blockOffset.offset === 2;
|
|
754
754
|
return defaultStyle && caretAtTheEndOfOrderedList && looksLikeOrderedList && orderedListStyle !== void 0 ? {
|
|
755
755
|
focusTextBlock,
|
|
756
756
|
listItem: orderedListStyle,
|