Skip to content

Add a closure/context parameter to transform_fn #47

@dacec354

Description

@dacec354

I want to render mixed styled text in TextArea while still using its soft wrap.

Embedding raw ANSI sequences in the text buffer is fragile. When wrapped or clipped, ANSI state can leak if reset sequences are cut, causing later output to inherit the wrong style.

A closure/context parameter on transform_fn would let users apply styling in the final transform phase with access to local state, instead of requiring TextArea itself to handle all ANSI edge cases.

This shifts the complexity to the caller, but keeps the core component simpler and avoids many hard-to-fix rendering traps.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions