OpenTUI 0.5.15
Breaking changes
- core:
DiffRenderable.destroyRecursively()is removed. Calldestroy()instead.DiffRenderablenow frees its internal views in the protecteddestroySelf()method. See Lifecycle and cleanup. (8ec0082)
Added
- core:
CreateRuntimePluginOptions.preservetakes a list or set of specifiers, or a predicate. The runtime plugin leaves matching bare specifiers unchanged, so a module that the host registers withbuild.module()is not replaced by a copy fromnode_modules.coreandadditionalmodules still take precedence. See Load plugins and modules at runtime. (#1569) - react:
ReactRuntimePluginSupportOptions.preserveaccepts the same values. See Load plugins and modules at runtime. (#1569) - solid:
SolidRuntimePluginSupportOptions.preserveaccepts the same values. See Load plugins and modules at runtime. (#1569)
Fixed
- core:
drawBoxanddrawPackedBufferdraw nothing when the width or height is zero or negative. Before, a negative extent reached native code as a very large value and could crash it, and a zero packed-buffer width divided by zero.pushScissorRectclips to an empty rectangle for such extents, so the matching pop stays balanced. See Buffer API. (#1559) - native: Blended cell writes reject negative coordinates. Before, an off-screen write could overflow or address an invalid cell. See Buffer API. (#1556)
- core:
DiffRenderableandLineNumberRenderablefree their cached internal views when you destroy them.LineNumberRenderablenow has its owndestroy()method. See Lifecycle and cleanup. (8ec0082) - solid: Slot placeholders are freed when their slot child is destroyed. See Solid plugin slots. (8ec0082)
API changes#
@opentui/core#
Added
protected method DiffRenderable.destroySelf(): voidmethod LineNumberRenderable.destroy(): void
Removed
method DiffRenderable.destroyRecursively(): void
@opentui/core/runtime-plugin#
Added
property CreateRuntimePluginOptions.preserve?: RuntimeSpecifierPreservetype RuntimeSpecifierPreserve = readonly string[] | ReadonlySet<string> | ((specifier: string) => boolean)
@opentui/core/runtime-plugin-support#
Added
property CreateRuntimePluginOptions.preserve?: RuntimeSpecifierPreservetype RuntimeSpecifierPreserve = readonly string[] | ReadonlySet<string> | ((specifier: string) => boolean)
@opentui/core/runtime-plugin-support/configure#
Added
property CreateRuntimePluginOptions.preserve?: RuntimeSpecifierPreservetype RuntimeSpecifierPreserve = readonly string[] | ReadonlySet<string> | ((specifier: string) => boolean)
@opentui/react/runtime-plugin-support#
Added
property ReactRuntimePluginSupportOptions.preserve?: RuntimeSpecifierPreserve
@opentui/react/runtime-plugin-support/configure#
Added
property ReactRuntimePluginSupportOptions.preserve?: RuntimeSpecifierPreserve
@opentui/solid#
Added
method LayoutSlotRenderable.destroyRecursively(): voidmethod SlotRenderable.didDestroySlotChild(child: LayoutSlotRenderable | TextSlotRenderable): void
Changed
method SlotRenderable.getSlotChild(parent: BaseRenderable): TextSlotRenderable | LayoutSlotRenderablemethod SlotRenderable.getSlotChild(parent: BaseRenderable): LayoutSlotRenderable | TextSlotRenderable
@opentui/solid/runtime-plugin-support#
Added
property SolidRuntimePluginSupportOptions.preserve?: RuntimeSpecifierPreserve
@opentui/solid/runtime-plugin-support/configure#
Added
property SolidRuntimePluginSupportOptions.preserve?: RuntimeSpecifierPreserve