Writing AssistantPro
AI chat card with a soft gradient glow, suggestions, streaming replies and live voice dictation.
oxyn add writing-assistantWren
Your writing companion.What should we write?
The preview stays free for everyone. Pro opens the code of every Pro component, screen, agent-app template, block and kit, plus the Pro CLI.
Rendered from Rust at build time · goes live when visible
When to use
- A small AI writing chat: suggestions to start from, streaming replies and voice dictation, in a card with a soft gradient glow.
When not to use
- Prompt composer with model picker, voice input, app connections and approval request: use Chat Composer instead.
- The model menu of an AI chat: use Model Picker instead.
- The prompt box for an agent, in six layouts: use Composer instead.
Installation
Writing Assistant is part of Oxyn Pro; the preview is free. Pro items install with the oxyn CLI once your licence is signed in; until then Pro members copy the code from this page.
oxyn add writing-assistantUsage
The preview is free. Pro opens the code of every Pro component, screen and template.
Examples
Default
The glow drifts behind the welcome line; a chip sends itself and the reply streams.
Wren
Your writing companion.What should we write?
Code Pro
The preview is free. Pro opens the code of every Pro component, screen and template.
Chat
After a message: the bubble, the reply, the glow quieter and New chat in the header.
Wren
Your writing companion.I fixed two typos, split the long second paragraph and moved your main ask to the first line, so it's the first thing they read.
Code Pro
The preview is free. Pro opens the code of every Pro component, screen and template.
Dictating
Dictating: the mic is a pale-blue tile with level bars and the words land in the field, then send.
Wren
Your writing companion.What should we write?
Code Pro
The preview is free. Pro opens the code of every Pro component, screen and template.
Classic
Classic style: a stronger glow on an inset panel, capsule chips, a white pill field and a round mic.
Wren
Your writing companion.What should we write?
Code Pro
The preview is free. Pro opens the code of every Pro component, screen and template.
API reference
WritingAssistant
| Prop | Type | Default | Description |
|---|---|---|---|
name | String | "Wren" | Assistant name on top. |
tagline | String | "Your writing companion." | Line under the name. |
greeting | String | "What should we write?" | Big line on the welcome screen. |
suggestions | Vec<String> | Default::default() | Chips that send themselves. |
placeholder | String | "Ask anything…" | Placeholder of the prompt field. |
asked | String | Default::default() | Start with this message already answered. |
dictating | bool | Default::default() | Start dictating. |
nowrequired | ClockMs | — | The clock. |
style | String | Default::default() | `clean`, `classic`, or empty to follow `data-cstyle`. |
on_action | EventHandler<(String, String)> | — | (`send` | `dictate` | `new-chat`, text). |
Read from the Rust signature and doc comments.
Keyboard interactions
| Key | Action |
|---|---|
| Tab | Suggestions, the field, the mic, Send and New chat |
| Enter | Send the field |
Accessibility
- New messages are announced politely; "Writing…" carries a label.
- The mic is a toggle named Dictate / Stop dictation (aria-pressed).
Responsive behaviour
- Fills its container up to 380 px.
Edge cases (spec)
Up to 380 px.
Notes for AI
- Import
WritingAssistantfromoxyn_dioxusand includeSTATUS_INDICATOR_CSSplus the token stylesheet once. - A GPUI version exists:
WritingAssistantElinoxyn_gpui. - Props to set first:
now. - It reads a clock (
now) for live timers; pass one clock for the whole page rather than one per component. - Keep its states and timings as they ship; restyle it through the CSS variables rather than by hand.