UNPKG

@antv/t8

Version:

T8 is a text visualization solution for unstructured data within the AntV technology stack, and it is a declarative T8 markdown syntax that can be used to describe the content of data interpretation reports.

23 lines (19 loc) 863 B
'use strict'; var tslib = require('tslib'); /** * Creates a factory function for custom block descriptors. * * This function takes a descriptor object and returns a new descriptor with the * `isBlock` property set to `true`. The descriptor is expected to be of type * `BlockDescriptor<CustomBlockSpec>`, where `CustomBlockSpec` is the type of * the block specification. * * @param descriptor - The descriptor object to be converted into a block descriptor. * @returns A new block descriptor with the `isBlock` property set to `true`. */ // eslint-disable-next-line @typescript-eslint/no-explicit-any var createCustomBlockFactory = function (descriptor) { return tslib.__assign(tslib.__assign({}, descriptor), { isBlock: true }); }; exports.createCustomBlockFactory = createCustomBlockFactory; //# sourceMappingURL=createCustomBlockFactory.js.map