New to Telerik UI for .NET MAUI? Start a free 30-day trial

AIPrompt Button

The AIPrompt component can also be displayed as a button that will show a popup with an AIPrompt when interacted with.

To display the component as a button, create a new RadAIPromptButton instance and add the AIPrompt component inside it.

The RadAIPromptButton inherits from RadTemplatedButton and provides the following additional properties:

  • AIPrompt(RadAIPrompt)—Defines the corresponding RadAIPrompt control.
  • Popup(RadPopup)—Defines the corresponding RadPopup control.

Here is an example on how you can define an AIPrompt Button:

<telerik:RadAIPromptButton FontFamily="TelerikFontExamples"
                           Content="&#xe85e;"
                           HorizontalOptions="End"
                           VerticalOptions="End">
    <telerik:RadAIPrompt InputText="{Binding InputText}"
                         PromptRequestCommand="{Binding PromptRequestCommand}"
                         OutputItems="{Binding OutputItems}" />
</telerik:RadAIPromptButton>

See Also

In this article