A text readout, optionally rendered as Markdown.
Import¶
from manywidgets import TextExample¶
Read-only — drive it from another widget (see the linking guide). Echo a dropdown selection, rendered as Markdown:
from ipywidgets import jsdlink
from manywidgets import Dropdown, Text
pick = Dropdown(options=["**bold**", "_italic_", "`code`"], value="**bold**")
echo = Text(markdown=True)
jsdlink((pick, "value"), (echo, "value"))
display(pick, echo)API¶
| Trait | Type | Default | Description |
|---|---|---|---|
value | Unicode | '' | |
markdown | Bool | False | |
widget_id | Unicode | '' | Stable unique id used for cross-widget linking (auto-assigned). |
With markdown=True, value is parsed to HTML and set as innerHTML — treat it
as any notebook-authored content.