@tiptap/extension-list-keymap
Advanced tools
Comparing version 2.3.2 to 2.4.0
@@ -203,2 +203,9 @@ import { getNodeType, getNodeAtPosition, isNodeActive, isAtStartOfNode, isAtEndOfNode, Extension } from '@tiptap/core'; | ||
/** | ||
* This extension registers custom keymaps to change the behaviour of the backspace and delete keys. | ||
* By default Prosemirror keyhandling will always lift or sink items so paragraphs are joined into | ||
* the adjacent or previous list item. This extension will prevent this behaviour and instead will | ||
* try to join paragraphs from two list items into a single list item. | ||
* @see https://www.tiptap.dev/api/extensions/list-keymap | ||
*/ | ||
const ListKeymap = Extension.create({ | ||
@@ -205,0 +212,0 @@ name: 'listKeymap', |
@@ -207,2 +207,9 @@ (function (global, factory) { | ||
/** | ||
* This extension registers custom keymaps to change the behaviour of the backspace and delete keys. | ||
* By default Prosemirror keyhandling will always lift or sink items so paragraphs are joined into | ||
* the adjacent or previous list item. This extension will prevent this behaviour and instead will | ||
* try to join paragraphs from two list items into a single list item. | ||
* @see https://www.tiptap.dev/api/extensions/list-keymap | ||
*/ | ||
const ListKeymap = core.Extension.create({ | ||
@@ -209,0 +216,0 @@ name: 'listKeymap', |
import { Extension } from '@tiptap/core'; | ||
export declare type ListKeymapOptions = { | ||
/** | ||
* An array of list types. This is used for item and wrapper list matching. | ||
* @default [] | ||
* @example [{ itemName: 'listItem', wrapperNames: ['bulletList', 'orderedList'] }] | ||
*/ | ||
listTypes: Array<{ | ||
@@ -8,2 +13,9 @@ itemName: string; | ||
}; | ||
/** | ||
* This extension registers custom keymaps to change the behaviour of the backspace and delete keys. | ||
* By default Prosemirror keyhandling will always lift or sink items so paragraphs are joined into | ||
* the adjacent or previous list item. This extension will prevent this behaviour and instead will | ||
* try to join paragraphs from two list items into a single list item. | ||
* @see https://www.tiptap.dev/api/extensions/list-keymap | ||
*/ | ||
export declare const ListKeymap: Extension<ListKeymapOptions, any>; |
{ | ||
"name": "@tiptap/extension-list-keymap", | ||
"description": "list keymap extension for tiptap", | ||
"version": "2.3.2", | ||
"version": "2.4.0", | ||
"homepage": "https://tiptap.dev", | ||
@@ -32,3 +32,3 @@ "keywords": [ | ||
"devDependencies": { | ||
"@tiptap/core": "^2.3.2" | ||
"@tiptap/core": "^2.4.0" | ||
}, | ||
@@ -35,0 +35,0 @@ "peerDependencies": { |
@@ -6,2 +6,7 @@ import { Extension } from '@tiptap/core' | ||
export type ListKeymapOptions = { | ||
/** | ||
* An array of list types. This is used for item and wrapper list matching. | ||
* @default [] | ||
* @example [{ itemName: 'listItem', wrapperNames: ['bulletList', 'orderedList'] }] | ||
*/ | ||
listTypes: Array<{ | ||
@@ -13,2 +18,9 @@ itemName: string, | ||
/** | ||
* This extension registers custom keymaps to change the behaviour of the backspace and delete keys. | ||
* By default Prosemirror keyhandling will always lift or sink items so paragraphs are joined into | ||
* the adjacent or previous list item. This extension will prevent this behaviour and instead will | ||
* try to join paragraphs from two list items into a single list item. | ||
* @see https://www.tiptap.dev/api/extensions/list-keymap | ||
*/ | ||
export const ListKeymap = Extension.create<ListKeymapOptions>({ | ||
@@ -15,0 +27,0 @@ name: 'listKeymap', |
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
105215
1178