The chat components are the building blocks of a conversation with an assistant or an agent. There are four of them, and they work together:
| Component | Role |
|---|---|
dap-ds-chat-composer | The message entry box: a text field that grows with its content, a send button and slots for extra controls. |
dap-ds-chat-message-list | The scrolling container of the conversation. It stays at the latest message while the user is at the bottom. |
dap-ds-chat-message | One message of the conversation, styled by who sent it. |
dap-ds-chat-step | One compact line that shows an action the assistant took, with its status. |
The components only display the conversation and collect the next message. They do not store messages and do not talk to a server: your page listens to the events, sends the text, and adds the message elements.
✅ Use the chat components when:
- Users talk to an assistant or an agent in a conversation that grows while they watch
- A reply can take time, is written piece by piece, and the user must be able to stop it
- The assistant does work between its replies that the user should see
❌ Don't use the chat components for:
- A field of a form that is submitted with other fields (use a textarea instead)
- Search (use a search field instead)
- Feedback about the page or a form (use a callout or feedback message instead)
- The steps of a process the user completes (use a stepper instead)
- A history of dated events (use a timeline instead)
A message list above a composer makes a chat. Give the list the remaining height of a column layout, so the conversation scrolls and the composer stays in place:
The composer fires dds-submit with the text in event.detail.value. Add the message of the user to the list, show a step while the assistant works, then stream the reply into a new message. Handle both ways a reply can end early: the user stops it, or it fails:
<div style="display: flex; flex-direction: column; gap: var(--dds-spacing-300); height: 32rem">
<dap-ds-chat-message-list id="list" style="flex: 1; min-height: 0">
<dap-ds-chat-message name="Assistant" timestamp="10:40">Hello! How can I help you today?</dap-ds-chat-message>
</dap-ds-chat-message-list>
<dap-ds-chat-composer id="composer" placeholder="Ask a question"></dap-ds-chat-composer>
</div>
<script>
const list = document.querySelector('#list')
const composer = document.querySelector('#composer')
let controller
const create = (tag, props) =>
Object.assign(document.createElement(tag), props)
composer.addEventListener('dds-submit', async event => {
const step = create('dap-ds-chat-step', {
label: 'Searching the knowledge base',
})
const reply = create('dap-ds-chat-message', { streaming: true })
list.append(
create('dap-ds-chat-message', {
sender: 'user',
textContent: event.detail.value,
}),
step,
)
// The user sent a message, so show it even if they had scrolled up
list.scrollToBottom()
composer.busy = true
composer.status = undefined
controller = new AbortController()
try {
const stream = await askAssistant(event.detail.value, controller.signal)
Object.assign(step, {
status: 'success',
label: 'Searched the knowledge base',
})
list.append(reply)
for await (const chunk of stream) {
reply.textContent += chunk
}
} catch (error) {
const stopped = error.name === 'AbortError'
// The reply ended before the search did, so the step must not keep spinning
if (step.status === 'running') {
if (stopped) {
step.remove()
} else {
Object.assign(step, {
status: 'error',
label: 'Search the knowledge base',
})
}
}
if (!stopped) {
composer.status = 'error'
composer.statusText = 'The reply could not be loaded. Try again.'
}
} finally {
reply.streaming = false
composer.busy = false
}
})
composer.addEventListener('dds-stop', () => controller?.abort())
</script>
Each component has its own import subpath, so a page that uses all four imports all four:
import 'dap-design-system/components/chat-composer'
import 'dap-design-system/components/chat-message-list'
import 'dap-design-system/components/chat-message'
import 'dap-design-system/components/chat-step'
The Enter key and the send button send the message. Shift+Enter inserts a line break. The send button is disabled while the field is empty or holds only whitespace:
The field is cleared after dds-submit, unless you call preventDefault(), for example to keep the text when it cannot be sent:
composer.addEventListener('dds-submit', event => {
if (!navigator.onLine) {
// Keep the text in the field
event.preventDefault()
composer.status = 'error'
composer.statusText = 'You are offline. Try again later.'
return
}
sendMessage(event.detail.value)
})
Set submitOnEnter="false" when the Enter key should insert a line break. The message is then sent only with the send button.
The composer has two methods: focus() moves the focus to the text field, and clear() empties it without firing dds-input.
Set busy while a reply is being generated. The send button becomes a stop button that fires dds-stop, and sending is blocked. The user can still type the next message:
disabled turns off the text field and the send or stop button:
The field starts at minRows (1 by default) and grows with the text up to maxRows (8 by default). After that it scrolls. maxlength limits the number of characters:
Set status to error or warning and give the message in statusText. The message is shown only when both are set. Use the status slot when the message needs markup, such as a link:
The message sits under the box by default. Set statusPosition="top" to show it above:
The box is lifted with a shadow by default (elevation="low"), which suits a composer that floats over the conversation. elevation="none" draws it like an input, with a border and hover and focus states:
The header slot is a row above the text field, for example for attachments. The footer slot holds actions at the start of the bottom row, and the send-actions slot holds controls just before the send button. Slots you leave empty take no space:
The list fills the height of its container, so give the container a height, or set --dds-chat-message-list-height or --dds-chat-message-list-max-height. Scroll up in the example to see the "jump to the latest message" button:
While the user is at the bottom, the list stays at the bottom when a message is added or a streaming message grows. After the user scrolls up, the list does not move, so reading is never interrupted.
Call scrollToBottom() to return to the latest message and follow new content again, for example right after the user sends a message. The scroll is smooth by default and instant for users who prefer reduced motion; pass an options object with behavior: 'auto' for an instant scroll.
dds-scroll-end-change fires when the list reaches or leaves the latest message, with the new state in event.detail.atEnd.
Set autoScroll="false" to turn following off. The list then moves only when the user scrolls or presses the button.
Content in the empty slot is shown while the list has no messages:
sender is assistant by default. Set it to user for the messages of the user and to system for notes about the conversation. User messages sit at the end of the row, assistant messages at the start, and system messages are small centered notes without a bubble:
name and timestamp are shown above the bubble. The timestamp is plain text: format it on your page, in the language of the user:
Set streaming while the message is being written. A typing indicator follows the content, also while the message is still empty. Add the text as it arrives and remove streaming when the reply is complete:
Put an avatar in the avatar slot, extra information such as sources or a delivery state in the meta slot, and controls such as a copy button in the actions slot. Slots you leave empty take no space:
When the content is only text, its line breaks are kept, so a message typed with Shift+Enter looks the way it was written. When the content has elements, normal HTML whitespace rules apply:
You need the following documents:
- your current passport,
- a valid identity card.
The message renders what you put in it. If a reply contains Markdown or HTML from a model or from another user, convert and sanitize it on your page before you insert it.
status is running by default and shows a spinner. Set it to success or error when the action ends. Change the label with it, so the text matches the state:
detail is a secondary text after the label, for example a size, a count or an identifier. Content in the default slot is shown under the line; use it to explain a failure or to give a short result:
Keep the element and change its properties when the action ends:
const step = document.createElement('dap-ds-chat-step')
step.label = 'Searching the knowledge base'
list.append(step)
const results = await search(query)
step.status = 'success'
step.label = 'Searched the knowledge base'
step.detail = `${results.length} results`
Every chat component has its own CSS custom properties and parts; the tables at the end of this page list them. Set the properties on the component they belong to:
- Name of the field: the text field has no visible label. Its accessible name is a localized "Message"; set
labelwhen the page needs a more specific name. The placeholder is not a label. - Keyboard: Enter sends the message and Shift+Enter inserts a line break. Enter is ignored while an IME composition is in progress, so confirming a candidate does not send the message.
- Send and stop button: the button has a localized accessible name that changes with
busy. Override the names withsendButtonLabelandstopButtonLabel. After a click on the send button the focus returns to the text field. - Status: the status message is linked to the text field with
aria-describedby. An error is announced at once (role="alert") and marks the field invalid; a warning is announced politely (role="status").
- Live region: the scrolling region has the
logrole and is a polite live region, so screen readers announce new messages without interrupting the user. - Name: the region is named with a localized "Conversation". Set
labelwhen the page has several conversations or needs a more specific name. - Keyboard: the scrolling region is focusable, so keyboard users can scroll it with the keyboard.
- Scroll button: the "jump to the latest message" button has a localized accessible name; override it with
scrollButtonLabel. After it is pressed it disappears, and the focus moves to the scrolling region instead of being lost. - Focus: the list never moves the focus when a message arrives. Keep the focus in the composer so the user can go on typing.
- Structure: each message is an
article. - Who is speaking: the sides and colors are not available to screen reader users. A message with a
nameis introduced by that name; without one, a visually hidden, localized sender ("You", "Assistant" or "System") is read before the content. - Streaming: a streaming message has
aria-busy="true", and the typing indicator is hidden from assistive technology. - Avatar: when the name is shown next to it, the avatar is decorative; give it an empty
alt.
- Status as text: the spinner and the icons are hidden from assistive technology. The status is read as visually hidden, localized text before the label, so it does not depend on color or shape.
- Label: write the label so that it makes sense on its own, and update it when the status changes ("Creating page" becomes "Created page").
- Extra content: explain a failure in words in the default slot; do not rely on the error icon.
The controls you put in the slots of the composer and the messages keep their own names, roles and keyboard behavior. Give icon buttons an aria-label that says what they act on.
Import the component by its own subpath. This registers <dap-ds-chat-composer> (and the
components it renders internally) and lets your bundler include only what you use:
import 'dap-design-system/components/chat-composer'
Need a reference to the class (e.g. to register it manually or extend it)? The same subpath default-exports it:
import DapDSChatComposer from 'dap-design-system/components/chat-composer'
Register the whole library at once — convenient, but pulls every component into your bundle:
import 'dap-design-system'
import { DapDSChatComposerReact } from 'dap-design-system/react'
| Property | Type | Default | Description |
|---|---|---|---|
value | string | '' | The text of the message. |
placeholder | string | The placeholder of the text field. | |
label | string | The accessible name of the text field. Defaults to a localized "Message". | |
disabled | boolean | false | Whether the composer is disabled. Disables the text field and the send or stop button. |
busy | boolean | false | Whether a reply is being generated. The send button becomes a stop button and submitting is blocked; the user can still type. |
minRows | number | 1 | The number of text rows shown when the field is empty. |
maxRows | number | 8 | The number of text rows the field grows to before it scrolls. |
maxlength | number, undefined | The maximum number of characters of the message. | |
submitOnEnter | boolean | true | Whether the Enter key sends the message. Shift+Enter always inserts a line break. Set submitOnEnter="false" to turn it off. |
status | 'error', 'warning' , undefined | The status of the composer. | |
statusText | string | The status message. Shown when status is set; the status slot overrides it. | |
statusPosition | 'top', 'bottom' | 'bottom' | Where the status message is shown, relative to the box. |
elevation | 'low', 'none' | 'low' | The elevation of the box. low lifts it with a shadow; none draws an input style border with hover and focus states. |
sendButtonLabel | string | The accessible name of the send button. Defaults to a localized "Send". | |
stopButtonLabel | string | The accessible name of the stop button. Defaults to a localized "Stop". | |
autofocus | boolean | false | Whether the text field takes the focus when the page loads. |
ariaLabel | string, null | null | Accessible label for the element. Use this to provide a text alternative |
| for elements that don't have visible text content. | |||
ariaExpanded | 'true', 'false' | null | Indicates whether the element is expanded or collapsed. |
ariaControls | string, null | null | Identifies the element that is controlled by this element. |
ariaHasPopup | string, null | null | Indicates the availability and type of interactive popup element. |
ariaDescribedBy | string, null | null | Identifies the element that describes the current element. |
ariaPressed | 'true', 'false' , 'mixed' | null | Indicates the current "pressed" state of toggle buttons. |
ariaHidden | 'true', 'false' | null | Indicates whether the element is hidden from accessibility APIs. |
customStyles | string, undefined | Custom CSS text to be merged with the component's styles. | |
| This CSS will be injected into the shadow DOM and merged with the component's static styles. |
| Name | Description |
|---|---|
header | A row above the text field, for example attachments or context. |
footer | Actions at the start of the bottom row, for example an attach button. |
send-actions | Controls just before the send button, for example a microphone button. |
status | The status message. Overrides `statusText`. |
| Event Name | Description | Type |
|---|---|---|
dds-input | Fired when the text changes. | {value: string } |
dds-submit | Fired when the message is sent with the send button or the Enter key. Cancelable: unless it is prevented, the field is cleared. | {value: string } |
dds-stop | Fired when the stop button is pressed while `busy`. | {void } |
| Part Name | Description |
|---|---|
base | The main chat composer container. |
body | The box around the header, the text field and the bottom row. |
header | The wrapper of the header slot. |
textarea | The native textarea. |
footer | The wrapper of the footer slot. |
send-actions | The wrapper of the send-actions slot. |
send-button | The send button, which is the stop button while `busy`. |
status | The status message. |
You can style CSS parts using the ::part() pseudo-element selector:
/* Target a specific part */
.my-custom-dap-ds-chat-composer::part(base) {
/* Your custom styles */
}
/* Target multiple parts */
.my-custom-dap-ds-chat-composer::part(base),
.my-custom-dap-ds-chat-composer::part(body) {
/* Shared styles */
}
Example usage:
<dap-ds-chat-composer class="my-custom-dap-ds-chat-composer">
Chat
</dap-ds-chat-composer>
.my-custom-dap-ds-chat-composer::part(base) {
border-radius: 12px;
box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
}
CSS parts allow you to style internal elements of the component while maintaining encapsulation. Learn more in our styling guide.
| Property Name | Description |
|---|---|
--dds-chat-composer-gap | Gap between the box and the status message. (default: var(--dds-spacing-200)) |
--dds-chat-composer-body-gap | Gap between the header, the text field and the bottom row. (default: var(--dds-spacing-200)) |
--dds-chat-composer-padding | Padding of the box. (default: var(--dds-spacing-300)) |
--dds-chat-composer-background | Background of the box. (default: var(--dds-fields-background-default)) |
--dds-chat-composer-color | Text color of the text field. (default: var(--dds-text-neutral-base)) |
--dds-chat-composer-placeholder-color | Color of the placeholder. (default: var(--dds-text-neutral-placeholder)) |
--dds-chat-composer-font-size | Font size of the text field. (default: var(--dds-font-base)) |
--dds-chat-composer-line-height | Line height of the text field. (default: var(--dds-font-line-height-xlarge)) |
--dds-chat-composer-border-radius | Border radius of the box. (default: var(--dds-radius-large)) |
--dds-chat-composer-border-width | Border width of the box. (default: var(--dds-border-width-base)) |
--dds-chat-composer-border-color | Border color of the box with `elevation="none"`. (default: var(--dds-border-neutral-base)) |
--dds-chat-composer-hover-border-color | Border color of the box on hover with `elevation="none"`. (default: var(--dds-border-neutral-strong)) |
--dds-chat-composer-elevated-border-color | Border color of the box with `elevation="low"`. (default: var(--dds-border-neutral-divider)) |
--dds-chat-composer-shadow | Shadow of the box with `elevation="low"`. (default: 0 var(--dds-spacing-50) var(--dds-spacing-300) var(--dds-black-10)) |
--dds-chat-composer-error-border-color | Border color of the box with the error status. (default: var(--dds-border-negative-base)) |
--dds-chat-composer-warning-border-color | Border color of the box with the warning status. (default: var(--dds-border-warning-base)) |
--dds-chat-composer-disabled-background | Background of the disabled box. (default: var(--dds-fields-background-disabled)) |
--dds-chat-composer-disabled-color | Text color of the disabled text field. (default: var(--dds-text-neutral-disabled)) |
--dds-chat-composer-actions-gap | Gap between the controls of the bottom row. (default: var(--dds-spacing-200)) |
--dds-chat-composer-status-font-size | Font size of the status message. (default: var(--dds-font-sm)) |
--dds-chat-composer-status-error-color | Text color of the error status message. (default: var(--dds-text-negative-subtle)) |
--dds-chat-composer-status-error-icon-color | Icon color of the error status message. (default: var(--dds-icon-negative-subtle)) |
--dds-chat-composer-status-warning-color | Text color of the warning status message. (default: var(--dds-text-neutral-base)) |
--dds-chat-composer-status-warning-icon-color | Icon color of the warning status message. (default: var(--dds-icon-warning-subtle)) |
CSS custom properties (CSS variables) can be set directly on the component or in your stylesheet:
Method 1: Inline styles (Quick customization)
<dap-ds-chat-composer
style="--dds-chat-composer-gap: value; --dds-chat-composer-body-gap: value;">
Chat
</dap-ds-chat-composer>
Method 2: CSS classes (Reusable styles)
.my-custom-dap-ds-chat-composer {
--dds-chat-composer-gap: value;
--dds-chat-composer-body-gap: value;
--dds-chat-composer-padding: value;
}
<dap-ds-chat-composer class="my-custom-dap-ds-chat-composer">
Chat
</dap-ds-chat-composer>
Method 3: Global theme customization
/* Apply to all instances */
dap-ds-chat-composer {
--dds-chat-composer-gap: value;
--dds-chat-composer-body-gap: value;
}
CSS custom properties inherit through the Shadow DOM, making them perfect for theming. Changes apply immediately without rebuilding.
| Property | Type | Default | Description |
|---|---|---|---|
sender | 'user', 'assistant' , 'system' | 'assistant' | Who sent the message. It sets the alignment and the colors, and the visually hidden sender prefix when there is no name. |
name | string | The name of the author, shown above the content. | |
timestamp | string | The time of the message as preformatted text, shown next to the name. | |
streaming | boolean | false | Whether the message is still being written. Sets aria-busy and shows a typing indicator after the content. |
ariaLabel | string, null | null | Accessible label for the element. Use this to provide a text alternative |
| for elements that don't have visible text content. | |||
ariaExpanded | 'true', 'false' | null | Indicates whether the element is expanded or collapsed. |
ariaControls | string, null | null | Identifies the element that is controlled by this element. |
ariaHasPopup | string, null | null | Indicates the availability and type of interactive popup element. |
ariaDescribedBy | string, null | null | Identifies the element that describes the current element. |
ariaPressed | 'true', 'false' , 'mixed' | null | Indicates the current "pressed" state of toggle buttons. |
ariaHidden | 'true', 'false' | null | Indicates whether the element is hidden from accessibility APIs. |
customStyles | string, undefined | Custom CSS text to be merged with the component's styles. | |
| This CSS will be injected into the shadow DOM and merged with the component's static styles. |
| Name | Description |
|---|---|
(default) | The content of the message. Line breaks of plain text are kept. |
avatar | The avatar of the sender. |
actions | Actions for the message, such as a copy button. |
meta | Extra information under the message, such as a delivery state or sources. |
No custom events available.
| Part Name | Description |
|---|---|
base | The main chat message container. |
avatar | The wrapper of the avatar slot. |
main | The column with the header, the bubble, the meta and the actions. |
header | The row with the author name and the timestamp. |
name | The author name. |
timestamp | The timestamp. |
bubble | The bubble around the content. |
content | The wrapper of the message content. |
typing-indicator | The indicator shown while the message is streaming. |
meta | The wrapper of the meta slot. |
actions | The wrapper of the actions slot. |
| Property Name | Description |
|---|---|
--dds-chat-message-gap | Gap between the avatar and the message. (default: var(--dds-spacing-200)) |
--dds-chat-message-content-gap | Gap between the header, the bubble, the meta and the actions. (default: var(--dds-spacing-100)) |
--dds-chat-message-max-width | Maximum width of the message without the avatar. (default: 80%) |
--dds-chat-message-padding | Padding of the bubble. (default: var(--dds-spacing-200) var(--dds-spacing-300)) |
--dds-chat-message-border-radius | Border radius of the bubble. (default: var(--dds-radius-large)) |
--dds-chat-message-border-width | Border width of the bubble. (default: var(--dds-border-width-base)) |
--dds-chat-message-font-size | Font size of the content. (default: var(--dds-font-base)) |
--dds-chat-message-header-font-size | Font size of the author name and the timestamp. (default: var(--dds-font-sm)) |
--dds-chat-message-name-color | Color of the author name. (default: var(--dds-text-neutral-strong)) |
--dds-chat-message-timestamp-color | Color of the timestamp and the meta content. (default: var(--dds-text-neutral-subtle)) |
--dds-chat-message-user-background | Background color of a user message. (default: var(--dds-background-brand-base)) |
--dds-chat-message-user-color | Text color of a user message. (default: var(--dds-text-neutral-base)) |
--dds-chat-message-user-border-color | Border color of a user message. (default: var(--dds-border-brand-subtle)) |
--dds-chat-message-assistant-background | Background color of an assistant message. (default: var(--dds-background-neutral-base)) |
--dds-chat-message-assistant-color | Text color of an assistant message. (default: var(--dds-text-neutral-base)) |
--dds-chat-message-assistant-border-color | Border color of an assistant message. (default: var(--dds-border-neutral-divider)) |
--dds-chat-message-system-color | Text color of a system message. (default: var(--dds-text-neutral-subtle)) |
--dds-chat-message-system-font-size | Font size of a system message. (default: var(--dds-font-sm)) |
--dds-chat-message-typing-color | Color of the typing indicator. (default: var(--dds-icon-neutral-subtle)) |
| Property | Type | Default | Description |
|---|---|---|---|
label | string | The accessible name of the list. Defaults to a localized "Conversation". | |
autoScroll | boolean | true | Whether the list follows new content. While the user is at the bottom, the list stays at the bottom when content is added or grows. |
After the user scrolls up, the list does not move and a "scroll to latest" button is shown. Set autoScroll="false" to turn it off. | |||
scrollButtonLabel | string | The accessible name of the "scroll to latest" button. Defaults to a localized text. | |
ariaLabel | string, null | null | Accessible label for the element. Use this to provide a text alternative |
| for elements that don't have visible text content. | |||
ariaExpanded | 'true', 'false' | null | Indicates whether the element is expanded or collapsed. |
ariaControls | string, null | null | Identifies the element that is controlled by this element. |
ariaHasPopup | string, null | null | Indicates the availability and type of interactive popup element. |
ariaDescribedBy | string, null | null | Identifies the element that describes the current element. |
ariaPressed | 'true', 'false' , 'mixed' | null | Indicates the current "pressed" state of toggle buttons. |
ariaHidden | 'true', 'false' | null | Indicates whether the element is hidden from accessibility APIs. |
customStyles | string, undefined | Custom CSS text to be merged with the component's styles. | |
| This CSS will be injected into the shadow DOM and merged with the component's static styles. |
| Name | Description |
|---|---|
(default) | The messages and steps of the conversation. |
empty | Content shown while there are no messages. |
| Event Name | Description | Type |
|---|---|---|
dds-scroll-end-change | Fired when the list reaches or leaves the latest message. | {atEnd: boolean } |
| Part Name | Description |
|---|---|
base | The main chat message list container. |
viewport | The scrolling region with the `log` role. |
content | The wrapper of the messages. |
empty | The wrapper of the empty slot. |
scroll-button | The button that scrolls to the latest message. |
| Property Name | Description |
|---|---|
--dds-chat-message-list-gap | Gap between the messages. (default: var(--dds-spacing-400)) |
--dds-chat-message-list-padding | Padding of the scrolling region. (default: var(--dds-spacing-400)) |
--dds-chat-message-list-height | Height of the list. (default: 100%) |
--dds-chat-message-list-max-height | Maximum height of the list. (default: none) |
--dds-chat-message-list-background | Background of the list. (default: transparent) |
--dds-chat-message-list-scroll-button-offset | Distance of the scroll button from the bottom of the list. (default: var(--dds-spacing-300)) |
--dds-chat-message-list-scroll-button-background | Background of the scroll button. (default: var(--dds-background-neutral-subtle)) |
--dds-chat-message-list-scroll-button-border-color | Border color of the scroll button. (default: var(--dds-border-neutral-base)) |
| Property | Type | Default | Description |
|---|---|---|---|
status | 'running', 'success' , 'error' | 'running' | The status of the step. It is shown by the indicator and also given as visually hidden text. |
label | string | The main text of the step, for example the action the assistant took. | |
detail | string | The secondary text of the step, for example a size or an identifier. | |
ariaLabel | string, null | null | Accessible label for the element. Use this to provide a text alternative |
| for elements that don't have visible text content. | |||
ariaExpanded | 'true', 'false' | null | Indicates whether the element is expanded or collapsed. |
ariaControls | string, null | null | Identifies the element that is controlled by this element. |
ariaHasPopup | string, null | null | Indicates the availability and type of interactive popup element. |
ariaDescribedBy | string, null | null | Identifies the element that describes the current element. |
ariaPressed | 'true', 'false' , 'mixed' | null | Indicates the current "pressed" state of toggle buttons. |
ariaHidden | 'true', 'false' | null | Indicates whether the element is hidden from accessibility APIs. |
customStyles | string, undefined | Custom CSS text to be merged with the component's styles. | |
| This CSS will be injected into the shadow DOM and merged with the component's static styles. |
| Name | Description |
|---|---|
(default) | Optional extra content shown under the line, such as an error explanation. |
No custom events available.
| Part Name | Description |
|---|---|
base | The main chat step container. |
line | The line with the status indicator, the label and the detail. |
indicator | The status indicator (spinner or icon). It is hidden from assistive technology; the status is given as hidden text. |
label | The main text of the step. |
detail | The secondary text of the step. |
content | The wrapper of the extra content. |
| Property Name | Description |
|---|---|
--dds-chat-step-gap | Gap between the indicator, the label and the detail. (default: var(--dds-spacing-200)) |
--dds-chat-step-content-gap | Gap between the line and the extra content. (default: var(--dds-spacing-100)) |
--dds-chat-step-font-size | Font size of the step. (default: var(--dds-font-sm)) |
--dds-chat-step-color | Color of the label. (default: var(--dds-text-neutral-base)) |
--dds-chat-step-detail-color | Color of the detail and the extra content. (default: var(--dds-text-neutral-subtle)) |
--dds-chat-step-indicator-size | Width and height reserved for the status indicator. (default: var(--dds-spacing-400)) |
--dds-chat-step-success-color | Color of the success icon. (default: var(--dds-icon-positive-subtle)) |
--dds-chat-step-error-color | Color of the error icon. (default: var(--dds-icon-negative-subtle)) |