Showcase
A collection of finished examples. Rather than walking through individual component properties, this page presents complete DSL snippets that mirror real business scenarios — showing how TokUI components compose into production-ready interfaces: registration forms, CRUD consoles, data dashboards, sales and customer analysis reports, and AI conversation fragments. Each example shows the formatted, syntax-highlighted DSL on the left and a live render on the right; click "Edit" to modify it in real time.
Registration Form
A card wrapping a form, covering the most typical registration scenario: username, password, and email inputs, a select for country, a checkbox to accept terms, and an ft footer holding the submit and reset buttons.
The form's
sub:handler must be pre-registered viaTokUI.registerHandler('onRegister', fn)and is invoked when the submit button is pressed;act/mtdprovide a native-form fallback when JavaScript is unavailable.
Form + Table Linkage
An entry form on top and a table below showing the records that have been entered. Common in back-office sub-pages like "quickly add a member".
CRUD Console
The most classic back-office page: a card containing a search box and bulk action buttons at the top, a striped table with a checkbox column in the middle, and a pagination at the bottom.
Cells containing spaces or Chinese characters must be wrapped in double quotes as a whole, since the parser splits tokens by space and would otherwise truncate them. To add a checkbox column, change the first entry of the
thead'scolstochk.
Action Card with Footer
A card v:highlight highlighted card whose body holds explanatory text, with an ft footer using a btngroup to organize three actions — Save, Cancel, and Export. Common in settings panels or detail editors.
Data Dashboard
A row / col grid layout: a top row of four stat summary cards, with a chart line trend on the lower left and a real-time orders table on the right — a typical operations dashboard.
Report: Sales Analysis
A dashboard-style sales analysis report: title card → key-metric stat row → bar-comparison chart → detail table. The whole thing reads like a single BI report page.
Report: Customer Analysis
A desc description list summarizes the customer profile, paired with a detail table and a callout conclusion note — a fully structured customer-analysis conclusion page.
AI Conversation Fragment
The closing example, showcasing the overall expressiveness of AI scenarios: a bubble role:ai containing a think reasoning block, a tool-call tool invocation, an md Markdown body, and a msg-actions action bar — a real, streamable conversation reply.
bubble/think/tool-call/md/msg-actionsare all containers and must be closed. During streaming,thinkis shown first as it arrives, then thetool-callstatus andmdbody are progressively flushed out, simulating a real typewriter effect.
For properties and variants of more components, see the category docs in the left navigation: Basic Components, Form Controls, Tables, Layout Containers, Charts, AI Chat.