Skip to main content

CnTextWidget

Multi-line rich-text / markdown widget with optional table mode (sanitised HTML).

Part of the dashboard widget library (v2). Registered with the dashboard widget registry and consumed by LaunchPad's widget grid. See the widget library overview and docs/architecture/cards-and-widgets.md.

content.text goes through the app's translate function, so manifest source text reads in the user's language like the other widgets. content.link draws a link under the text: { "label": "Bekijk de afspraken", "route": "SlaAttainment" } (a page id, or a router path starting with /) or { "label": "Docs", "href": "https://example.org" } (opens in a new tab). The label is translated too.

{ "type": "text", "title": "Afspraken", "content": { "text": "3 afspraken vandaag", "link": { "label": "Alle afspraken", "route": "Appointments" } } }

Reference​

Props​

NameTypeRequiredDefaultDescription
content{text: string, fontSize: string, color: string, backgroundColor: string, textAlign: string, contentMode: string, tableMode: boolean, tableData: object}\{\}Persisted widget content blob: {text, fontSize, color, backgroundColor, textAlign, contentMode, tableMode, tableData}. All keys are optional; missing keys collapse to documented defaults.