Docs Components Assistant

ThreadFollowupSuggestions

React example follows below.
ts
import { ThreadFollowupSuggestions } from "@grassroot/ui-react/assistant";
import { assistantDemoSuggestions } from "@grassroot/demo-fixtures";
export default function ThreadFollowupSuggestionsDemo() {
return <ThreadFollowupSuggestions suggestions={assistantDemoSuggestions} />;
}
ts
<script setup lang="ts">
import { ThreadFollowupSuggestions } from "@grassroot/ui-vue/assistant";
import { assistantDemoSuggestions } from "@grassroot/demo-fixtures";
</script>
<template>
<ThreadFollowupSuggestions :suggestions="assistantDemoSuggestions" />
</template>
ts
import "./ensure-compiler";
import { ChangeDetectionStrategy, Component } from "@angular/core";
import { GrassrootThreadFollowupSuggestions } from "@grassroot/ui-angular/assistant";
import { assistantDemoSuggestions } from "@grassroot/demo-fixtures";
@Component({
selector: "app-thread-followup-suggestions-demo",
standalone: true,
imports: [GrassrootThreadFollowupSuggestions],
changeDetection: ChangeDetectionStrategy.OnPush,
template: `<grassroot-thread-followup-suggestions [suggestions]="suggestions" />`,
})
export class ThreadFollowupSuggestionsDemoComponent {
protected readonly suggestions = assistantDemoSuggestions;
}
export default ThreadFollowupSuggestionsDemoComponent;
ts
<script lang="ts">
import { ThreadFollowupSuggestions } from "@grassroot/ui-svelte/assistant";
import { assistantDemoSuggestions } from "@grassroot/demo-fixtures";
</script>
<ThreadFollowupSuggestions suggestions={assistantDemoSuggestions} />
ts
/** @jsxImportSource solid-js */
import { ThreadFollowupSuggestions } from "@grassroot/ui-solid/assistant";
import { assistantDemoSuggestions } from "@grassroot/demo-fixtures";
export default function ThreadFollowupSuggestionsDemo() {
return <ThreadFollowupSuggestions suggestions={assistantDemoSuggestions} />;
}

Installation

API Reference

Import

import { ThreadFollowupSuggestions } from "@grassroot/ui-react/assistant";
import { assistantDemoSuggestions } from "@grassroot/demo-fixtures";

Props

Prop
Type
Default
Requirement
suggestions
readonly string[] | undefined
optional
onSelect
((suggestion: string) => void) | undefined
optional
Prop
suggestions
Type
readonly string[] | undefined
Default
Requirement
optional
Prop
onSelect
Type
((suggestion: string) => void) | undefined
Default
Requirement
optional

Events

EventPayload
onSelect((suggestion: string) => void) | undefined

Native attributes

Standard DOM and ARIA attributes not listed above spread onto the root element.

Import

import { ThreadFollowupSuggestions } from "@grassroot/ui-vue/assistant";
import { assistantDemoSuggestions } from "@grassroot/demo-fixtures";

Props

Prop
Type
Default
Requirement
suggestions
string[]
() => []
optional
Prop
suggestions
Type
string[]
Default
() => []
Requirement
optional

Events

EventPayload
select(string) => void

Import

import "./ensure-compiler";
import { ChangeDetectionStrategy, Component } from "@angular/core";
import { GrassrootThreadFollowupSuggestions } from "@grassroot/ui-angular/assistant";
import { assistantDemoSuggestions } from "@grassroot/demo-fixtures";

Props

Prop
Type
Default
Requirement
suggestions
readonly string[]
[]
optional
Prop
suggestions
Type
readonly string[]
Default
[]
Requirement
optional

Events

EventPayload
selectstring

Import

import { ThreadFollowupSuggestions } from "@grassroot/ui-svelte/assistant";
import { assistantDemoSuggestions } from "@grassroot/demo-fixtures";

Props

Prop
Type
Default
Requirement
suggestions
readonly string[]
optional
onSelect
(suggestion: string) => void
optional
class
string
optional
style
string
optional
Prop
suggestions
Type
readonly string[]
Default
Requirement
optional
Prop
onSelect
Type
(suggestion: string) => void
Default
Requirement
optional
Prop
class
Type
string
Default
Requirement
optional
Prop
style
Type
string
Default
Requirement
optional

Events

EventPayload
onSelect(suggestion: string) => void

Content regions

  • children

Import

import { ThreadFollowupSuggestions } from "@grassroot/ui-solid/assistant";
import { assistantDemoSuggestions } from "@grassroot/demo-fixtures";

Props

Prop
Type
Default
Requirement
suggestions
readonly string[]
optional
onSelect
(suggestion: string) => void
optional
Prop
suggestions
Type
readonly string[]
Default
Requirement
optional
Prop
onSelect
Type
(suggestion: string) => void
Default
Requirement
optional

Events

EventPayload
onSelect(suggestion: string) => void

Content regions

  • children

Native attributes

Standard DOM and ARIA attributes not listed above spread onto the root element.