conflict-nuxt-4/app/types/blocks.js
2026-02-12 11:24:27 +03:30

35 lines
533 B
JavaScript
Executable File

/**
* @typedef {Object} BaseBlock
* @property {string} id
* @property {string} type
*/
/**
* @typedef {BaseBlock & {
* type: 'paragraph',
* text: string
* }} ParagraphBlock
*/
/**
* @typedef {BaseBlock & {
* type: 'heading',
* level: 1|2|3,
* text: string
* }} HeadingBlock
*/
/**
* @typedef {BaseBlock & {
* type: 'todo',
* text: string,
* checked: boolean
* }} TodoBlock
*/
/**
* @typedef {ParagraphBlock | HeadingBlock | TodoBlock} Block
*/
export {};