@tiptap/extension-bullet-list
Advanced tools
Comparing version 2.9.0 to 2.9.1
import { Node, mergeAttributes, wrappingInputRule } from '@tiptap/core'; | ||
import { ListItem } from '@tiptap/extension-list-item'; | ||
import { TextStyle } from '@tiptap/extension-text-style'; | ||
const ListItemName = 'listItem'; | ||
const TextStyleName = 'textStyle'; | ||
/** | ||
@@ -41,3 +41,3 @@ * Matches a bullet list to a dash or asterisk. | ||
if (this.options.keepAttributes) { | ||
return chain().toggleList(this.name, this.options.itemTypeName, this.options.keepMarks).updateAttributes(ListItem.name, this.editor.getAttributes(TextStyle.name)).run(); | ||
return chain().toggleList(this.name, this.options.itemTypeName, this.options.keepMarks).updateAttributes(ListItemName, this.editor.getAttributes(TextStyleName)).run(); | ||
} | ||
@@ -64,3 +64,3 @@ return commands.toggleList(this.name, this.options.itemTypeName, this.options.keepMarks); | ||
keepAttributes: this.options.keepAttributes, | ||
getAttributes: () => { return this.editor.getAttributes(TextStyle.name); }, | ||
getAttributes: () => { return this.editor.getAttributes(TextStyleName); }, | ||
editor: this.editor, | ||
@@ -67,0 +67,0 @@ }); |
(function (global, factory) { | ||
typeof exports === 'object' && typeof module !== 'undefined' ? factory(exports, require('@tiptap/core'), require('@tiptap/extension-list-item'), require('@tiptap/extension-text-style')) : | ||
typeof define === 'function' && define.amd ? define(['exports', '@tiptap/core', '@tiptap/extension-list-item', '@tiptap/extension-text-style'], factory) : | ||
(global = typeof globalThis !== 'undefined' ? globalThis : global || self, factory(global["@tiptap/extension-bullet-list"] = {}, global.core, global.extensionListItem, global.extensionTextStyle)); | ||
})(this, (function (exports, core, extensionListItem, extensionTextStyle) { 'use strict'; | ||
typeof exports === 'object' && typeof module !== 'undefined' ? factory(exports, require('@tiptap/core')) : | ||
typeof define === 'function' && define.amd ? define(['exports', '@tiptap/core'], factory) : | ||
(global = typeof globalThis !== 'undefined' ? globalThis : global || self, factory(global["@tiptap/extension-bullet-list"] = {}, global.core)); | ||
})(this, (function (exports, core) { 'use strict'; | ||
const ListItemName = 'listItem'; | ||
const TextStyleName = 'textStyle'; | ||
/** | ||
@@ -43,3 +45,3 @@ * Matches a bullet list to a dash or asterisk. | ||
if (this.options.keepAttributes) { | ||
return chain().toggleList(this.name, this.options.itemTypeName, this.options.keepMarks).updateAttributes(extensionListItem.ListItem.name, this.editor.getAttributes(extensionTextStyle.TextStyle.name)).run(); | ||
return chain().toggleList(this.name, this.options.itemTypeName, this.options.keepMarks).updateAttributes(ListItemName, this.editor.getAttributes(TextStyleName)).run(); | ||
} | ||
@@ -66,3 +68,3 @@ return commands.toggleList(this.name, this.options.itemTypeName, this.options.keepMarks); | ||
keepAttributes: this.options.keepAttributes, | ||
getAttributes: () => { return this.editor.getAttributes(extensionTextStyle.TextStyle.name); }, | ||
getAttributes: () => { return this.editor.getAttributes(TextStyleName); }, | ||
editor: this.editor, | ||
@@ -69,0 +71,0 @@ }); |
{ | ||
"name": "@tiptap/extension-bullet-list", | ||
"description": "bullet list extension for tiptap", | ||
"version": "2.9.0", | ||
"version": "2.9.1", | ||
"homepage": "https://tiptap.dev", | ||
@@ -32,10 +32,6 @@ "keywords": [ | ||
"devDependencies": { | ||
"@tiptap/core": "^2.9.0", | ||
"@tiptap/extension-list-item": "^2.9.0", | ||
"@tiptap/extension-text-style": "^2.9.0" | ||
"@tiptap/core": "^2.9.1" | ||
}, | ||
"peerDependencies": { | ||
"@tiptap/core": "^2.7.0", | ||
"@tiptap/extension-list-item": "^2.7.0", | ||
"@tiptap/extension-text-style": "^2.7.0" | ||
"@tiptap/core": "^2.7.0" | ||
}, | ||
@@ -42,0 +38,0 @@ "repository": { |
import { mergeAttributes, Node, wrappingInputRule } from '@tiptap/core' | ||
import { ListItem } from '@tiptap/extension-list-item' | ||
import { TextStyle } from '@tiptap/extension-text-style' | ||
const ListItemName = 'listItem' | ||
const TextStyleName = 'textStyle' | ||
export interface BulletListOptions { | ||
@@ -89,3 +90,3 @@ /** | ||
if (this.options.keepAttributes) { | ||
return chain().toggleList(this.name, this.options.itemTypeName, this.options.keepMarks).updateAttributes(ListItem.name, this.editor.getAttributes(TextStyle.name)).run() | ||
return chain().toggleList(this.name, this.options.itemTypeName, this.options.keepMarks).updateAttributes(ListItemName, this.editor.getAttributes(TextStyleName)).run() | ||
} | ||
@@ -115,3 +116,3 @@ return commands.toggleList(this.name, this.options.itemTypeName, this.options.keepMarks) | ||
keepAttributes: this.options.keepAttributes, | ||
getAttributes: () => { return this.editor.getAttributes(TextStyle.name) }, | ||
getAttributes: () => { return this.editor.getAttributes(TextStyleName) }, | ||
editor: this.editor, | ||
@@ -118,0 +119,0 @@ }) |
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
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
1
1
388
29626