@tiptap/extension-blockquote
Advanced tools
Comparing version 2.3.2 to 2.4.0
import { Node, mergeAttributes, wrappingInputRule } from '@tiptap/core'; | ||
/** | ||
* Matches a blockquote to a `>` as input. | ||
*/ | ||
const inputRegex = /^\s*>\s$/; | ||
/** | ||
* This extension allows you to create blockquotes. | ||
* @see https://tiptap.dev/api/nodes/blockquote | ||
*/ | ||
const Blockquote = Node.create({ | ||
@@ -5,0 +12,0 @@ name: 'blockquote', |
@@ -7,3 +7,10 @@ (function (global, factory) { | ||
/** | ||
* Matches a blockquote to a `>` as input. | ||
*/ | ||
const inputRegex = /^\s*>\s$/; | ||
/** | ||
* This extension allows you to create blockquotes. | ||
* @see https://tiptap.dev/api/nodes/blockquote | ||
*/ | ||
const Blockquote = core.Node.create({ | ||
@@ -10,0 +17,0 @@ name: 'blockquote', |
import { Node } from '@tiptap/core'; | ||
export interface BlockquoteOptions { | ||
/** | ||
* HTML attributes to add to the blockquote element | ||
* @default {} | ||
* @example { class: 'foo' } | ||
*/ | ||
HTMLAttributes: Record<string, any>; | ||
@@ -23,3 +28,10 @@ } | ||
} | ||
/** | ||
* Matches a blockquote to a `>` as input. | ||
*/ | ||
export declare const inputRegex: RegExp; | ||
/** | ||
* This extension allows you to create blockquotes. | ||
* @see https://tiptap.dev/api/nodes/blockquote | ||
*/ | ||
export declare const Blockquote: Node<BlockquoteOptions, any>; |
{ | ||
"name": "@tiptap/extension-blockquote", | ||
"description": "blockquote 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": { |
import { mergeAttributes, Node, wrappingInputRule } from '@tiptap/core' | ||
export interface BlockquoteOptions { | ||
/** | ||
* HTML attributes to add to the blockquote element | ||
* @default {} | ||
* @example { class: 'foo' } | ||
*/ | ||
HTMLAttributes: Record<string, any>, | ||
@@ -26,4 +31,11 @@ } | ||
/** | ||
* Matches a blockquote to a `>` as input. | ||
*/ | ||
export const inputRegex = /^\s*>\s$/ | ||
/** | ||
* This extension allows you to create blockquotes. | ||
* @see https://tiptap.dev/api/nodes/blockquote | ||
*/ | ||
export const Blockquote = Node.create<BlockquoteOptions>({ | ||
@@ -30,0 +42,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
20206
302