Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

@tiptap/extension-bullet-list

Package Overview
Dependencies
Maintainers
4
Versions
168
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@tiptap/extension-bullet-list - npm Package Compare versions

Comparing version 2.3.2 to 2.4.0

18

dist/index.js
import { Node, mergeAttributes, Mark, getMarkAttributes, wrappingInputRule } from '@tiptap/core';
/**
* This extension allows you to create list items.
* @see https://www.tiptap.dev/api/nodes/list-item
*/
const ListItem = Node.create({

@@ -33,2 +37,7 @@ name: 'listItem',

/**
* This extension allows you to create text styles. It is required by default
* for the `textColor` and `backgroundColor` extensions.
* @see https://www.tiptap.dev/api/marks/text-style
*/
const TextStyle = Mark.create({

@@ -72,3 +81,12 @@ name: 'textStyle',

/**
* Matches a bullet list to a dash or asterisk.
*/
const inputRegex = /^\s*([-+*])\s$/;
/**
* This extension allows you to create bullet lists.
* This requires the ListItem extension
* @see https://tiptap.dev/api/nodes/bullet-list
* @see https://tiptap.dev/api/nodes/list-item.
*/
const BulletList = Node.create({

@@ -75,0 +93,0 @@ name: 'bulletList',

@@ -7,2 +7,6 @@ (function (global, factory) {

/**
* This extension allows you to create list items.
* @see https://www.tiptap.dev/api/nodes/list-item
*/
const ListItem = core.Node.create({

@@ -38,2 +42,7 @@ name: 'listItem',

/**
* This extension allows you to create text styles. It is required by default
* for the `textColor` and `backgroundColor` extensions.
* @see https://www.tiptap.dev/api/marks/text-style
*/
const TextStyle = core.Mark.create({

@@ -77,3 +86,12 @@ name: 'textStyle',

/**
* Matches a bullet list to a dash or asterisk.
*/
const inputRegex = /^\s*([-+*])\s$/;
/**
* This extension allows you to create bullet lists.
* This requires the ListItem extension
* @see https://tiptap.dev/api/nodes/bullet-list
* @see https://tiptap.dev/api/nodes/list-item.
*/
const BulletList = core.Node.create({

@@ -80,0 +98,0 @@ name: 'bulletList',

import { Node } from '@tiptap/core';
export interface BulletListOptions {
/**
* The node name for the list items
* @default 'listItem'
* @example 'paragraph'
*/
itemTypeName: string;
/**
* HTML attributes to add to the bullet list element
* @default {}
* @example { class: 'foo' }
*/
HTMLAttributes: Record<string, any>;
/**
* Keep the marks when splitting the list
* @default false
* @example true
*/
keepMarks: boolean;
/**
* Keep the attributes when splitting the list
* @default false
* @example true
*/
keepAttributes: boolean;

@@ -18,3 +38,12 @@ }

}
/**
* Matches a bullet list to a dash or asterisk.
*/
export declare const inputRegex: RegExp;
/**
* This extension allows you to create bullet lists.
* This requires the ListItem extension
* @see https://tiptap.dev/api/nodes/bullet-list
* @see https://tiptap.dev/api/nodes/list-item.
*/
export declare const BulletList: Node<BulletListOptions, any>;
import { Node } from '@tiptap/core';
export interface ListItemOptions {
/**
* The HTML attributes for a list item node.
* @default {}
* @example { class: 'foo' }
*/
HTMLAttributes: Record<string, any>;
/**
* The node type for bulletList nodes
* @default 'bulletList'
* @example 'myCustomBulletList'
*/
bulletListTypeName: string;
/**
* The node type for orderedList nodes
* @default 'orderedList'
* @example 'myCustomOrderedList'
*/
orderedListTypeName: string;
}
/**
* This extension allows you to create list items.
* @see https://www.tiptap.dev/api/nodes/list-item
*/
export declare const ListItem: Node<ListItemOptions, any>;
import { Mark } from '@tiptap/core';
export interface TextStyleOptions {
/**
* HTML attributes to add to the span element.
* @default {}
* @example { class: 'foo' }
*/
HTMLAttributes: Record<string, any>;

@@ -10,2 +15,3 @@ }

* Remove spans without inline style attributes.
* @example editor.commands.removeEmptyTextStyle()
*/

@@ -16,2 +22,7 @@ removeEmptyTextStyle: () => ReturnType;

}
/**
* This extension allows you to create text styles. It is required by default
* for the `textColor` and `backgroundColor` extensions.
* @see https://www.tiptap.dev/api/marks/text-style
*/
export declare const TextStyle: Mark<TextStyleOptions, any>;

4

package.json
{
"name": "@tiptap/extension-bullet-list",
"description": "bullet list 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": {

@@ -7,5 +7,28 @@ import { mergeAttributes, Node, wrappingInputRule } from '@tiptap/core'

export interface BulletListOptions {
/**
* The node name for the list items
* @default 'listItem'
* @example 'paragraph'
*/
itemTypeName: string,
/**
* HTML attributes to add to the bullet list element
* @default {}
* @example { class: 'foo' }
*/
HTMLAttributes: Record<string, any>,
/**
* Keep the marks when splitting the list
* @default false
* @example true
*/
keepMarks: boolean,
/**
* Keep the attributes when splitting the list
* @default false
* @example true
*/
keepAttributes: boolean,

@@ -25,4 +48,13 @@ }

/**
* Matches a bullet list to a dash or asterisk.
*/
export const inputRegex = /^\s*([-+*])\s$/
/**
* This extension allows you to create bullet lists.
* This requires the ListItem extension
* @see https://tiptap.dev/api/nodes/bullet-list
* @see https://tiptap.dev/api/nodes/list-item.
*/
export const BulletList = Node.create<BulletListOptions>({

@@ -29,0 +61,0 @@ name: 'bulletList',

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

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc