Skip to content

feat(prompt-line): conversation starters example#1787

Open
warrenmblood wants to merge 6 commits into
carbon-design-system:feat/prompt-linefrom
warrenmblood:conversation-starters-example
Open

feat(prompt-line): conversation starters example#1787
warrenmblood wants to merge 6 commits into
carbon-design-system:feat/prompt-linefrom
warrenmblood:conversation-starters-example

Conversation

@warrenmblood

@warrenmblood warrenmblood commented Jul 15, 2026

Copy link
Copy Markdown
Contributor

Closes #1351

Adds new example to showcase the usage of Starter prompts via InputConfig.starters to show suggestions in the prompt line while the editor is empty, focused, and editable.

Changelog

New

  • Two new examples: the React and WC versions of prompt-line-conversation-starters
  • Adds StartersConfig interface (items: SuggestionItem[] + renderCustomList?) and replaced all usage of SuggestionItem[] for AutocompleteControllerOptions.starters with it. This allows users to pass renderCustomList to replace the built-in list UI, for example to add a header above the items.

Changed

  • Docs updates to reflect changes in this PR
  • Updates conversation starters tests in packages/ai-chat/tests/components/spec/promptLineMode_spec.ts & packages/ai-chat-components/src/components/prompt-line/src/__tests__/autocomplete-controller.test.ts to accept StartersConfig instead of SuggestionItem[]

Testing / Reviewing

Test the React & Web component example:

  • npm run start --workspace=@carbon/ai-chat-examples-react-prompt-line-conversation-starters
  • npm run start --workspace=@carbon/ai-chat-examples-web-components-prompt-line-conversation-starters

@warrenmblood
warrenmblood requested a review from a team as a code owner July 15, 2026 18:40
@warrenmblood
warrenmblood requested review from ethanwinters and removed request for a team July 15, 2026 18:40
@warrenmblood warrenmblood changed the title Conversation starters example feat(prompt-line): conversation starters example Jul 15, 2026
@netlify

netlify Bot commented Jul 15, 2026

Copy link
Copy Markdown

Deploy Preview for carbon-ai-chat-demo ready!

Name Link
🔨 Latest commit 1bd9471
🔍 Latest deploy log https://app.netlify.com/projects/carbon-ai-chat-demo/deploys/6a57d83b928ace0008afb1de
😎 Deploy Preview https://deploy-preview-1787--carbon-ai-chat-demo.netlify.app
📱 Preview on mobile
Toggle QR Code...

QR Code

Use your smartphone camera to open QR code link.
🤖 Make changes Run an agent on this branch

To edit notification comments on pull requests, go to your Netlify project configuration.

@netlify

netlify Bot commented Jul 15, 2026

Copy link
Copy Markdown

Deploy Preview for ai-chat-components-react ready!

Name Link
🔨 Latest commit 1bd9471
🔍 Latest deploy log https://app.netlify.com/projects/ai-chat-components-react/deploys/6a57d83b5ca605000889ef4f
😎 Deploy Preview https://deploy-preview-1787--ai-chat-components-react.netlify.app
📱 Preview on mobile
Toggle QR Code...

QR Code

Use your smartphone camera to open QR code link.
🤖 Make changes Run an agent on this branch

To edit notification comments on pull requests, go to your Netlify project configuration.

@netlify

netlify Bot commented Jul 15, 2026

Copy link
Copy Markdown

Deploy Preview for carbon-ai-chat-components ready!

Name Link
🔨 Latest commit 1bd9471
🔍 Latest deploy log https://app.netlify.com/projects/carbon-ai-chat-components/deploys/6a57d83b4cbf28000893954c
😎 Deploy Preview https://deploy-preview-1787--carbon-ai-chat-components.netlify.app
📱 Preview on mobile
Toggle QR Code...

QR Code

Use your smartphone camera to open QR code link.
🤖 Make changes Run an agent on this branch

To edit notification comments on pull requests, go to your Netlify project configuration.

// Each alerts on click — swap onClick for real handlers.
actions: [
{
text: "Add",

@ethanwinters ethanwinters Jul 20, 2026

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

We don't need all these random actions in this example, but I do believe the figma designs had a button to turn on/off the starters as an action.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants