InlineAutocomplete
Shows suggestions to complete the current word/phrase the user is actively typing.
Internal Component
This component is intended solely for use within GitHub and is not available for external use.Props
InlineAutocomplete
Name | Default | Description |
---|---|---|
triggers Required | Trigger[] Register the triggers that can cause suggestions to appear. | |
onShowSuggestions Required | (event: ShowSuggestionsEvent) => void Called when a valid suggestion query is updated. This should be handled by setting the
| |
onSelectSuggestion | (event: SelectSuggestionsEvent) => void Called when a suggestion is selected. | |
onHideSuggestions Required | () => void Called when suggestions should be hidden. Set | |
suggestions Required | Suggestions The currently visible list of suggestions. If Typically, this should not contain more than five or so suggestions. | |
tabInsertsSuggestions | false | boolean If |
style | Omit<React.CSSProperties, "position"> The | |
children Required | TextInputCompatibleChild An | |
suggestionsPlacement | "below" | SuggestionsPlacement Control which side of the insertion point the suggestions list appears on by default. This
should almost always be In either case, if there is not enough room to display the suggestions in the default direction, the suggestions will appear in the other direction. |
portalName | string The name of the portal to render the suggestions overlay into. This is useful if you have multiple inline autocomplete components on the same page and you want to ensure the suggestions overlay is rendered in the correct order. | |
fullWidth | boolean If | |
title | string Optional title/name for the suggestions menu. | |
asMenu | boolean For simple cases, the standard representation of this widget is as a |