import { Node } from '../../core/Node.js'; /** * Size configuration for content blocks * @typedef {Object} ContentBlockSize * @property {number} [top] - Top position in pixels * @property {number} [left] - Left position in pixels * @property {number|string} [width] - Width in pixels or percentage (e.g., "50%") * @property {number|string} [height] - Height in pixels or percentage */ /** * Content block configuration * @typedef {Object} ContentBlockConfig * @property {boolean} [horizontalRule] - Whether this is a horizontal rule * @property {ContentBlockSize} [size] - Size and position configuration * @property {string} [background] - Background color (hex, rgb, or named color) */ /** * Configuration options for ContentBlock * @typedef {Object} ContentBlockOptions * @category Options * @property {Object} [htmlAttributes] HTML attributes for the block element */ /** * Attributes for content blocks * @typedef {Object} ContentBlockAttributes * @category Attributes * @property {boolean} [horizontalRule=false] Whether this block is a horizontal rule * @property {ContentBlockSize} [size] Size and position of the content block * @property {string} [background] Background color for the block * @property {Object} [drawingContent] @internal Internal drawing data * @property {Object} [attributes] @internal Additional internal attributes * @example * // Insert a custom content block * editor.commands.insertContentBlock({ * size: { width: '100%', height: 2 }, * background: '#e5e7eb' * }) */ /** * Default attributes for a horizontal rule content block. * Single source of truth shared by both `parseDOM` (for `
` tags) * and the `insertHorizontalRule` command. * @returns {ContentBlockAttributes} */ export function createDefaultHorizontalRuleAttrs(): ContentBlockAttributes; /** * @module ContentBlock * @sidebarTitle Content Block * @snippetPath /snippets/extensions/content-block.mdx */ export const ContentBlock: Node, Record, Record>; /** * Size configuration for content blocks */ export type ContentBlockSize = { /** * - Top position in pixels */ top?: number | undefined; /** * - Left position in pixels */ left?: number | undefined; /** * - Width in pixels or percentage (e.g., "50%") */ width?: string | number | undefined; /** * - Height in pixels or percentage */ height?: string | number | undefined; }; /** * Content block configuration */ export type ContentBlockConfig = { /** * - Whether this is a horizontal rule */ horizontalRule?: boolean | undefined; /** * - Size and position configuration */ size?: ContentBlockSize | undefined; /** * - Background color (hex, rgb, or named color) */ background?: string | undefined; }; /** * Configuration options for ContentBlock */ export type ContentBlockOptions = Object; /** * Attributes for content blocks */ export type ContentBlockAttributes = Object; //# sourceMappingURL=content-block.d.ts.map