diff --git a/packages/grafana-ui/src/components/Segment/SegmentAsync.tsx b/packages/grafana-ui/src/components/Segment/SegmentAsync.tsx index 67093f43ce4..b952c38367e 100644 --- a/packages/grafana-ui/src/components/Segment/SegmentAsync.tsx +++ b/packages/grafana-ui/src/components/Segment/SegmentAsync.tsx @@ -13,8 +13,10 @@ import { useStyles } from '../../themes'; export interface SegmentAsyncProps extends SegmentProps, Omit, 'value' | 'onChange'> { value?: T | SelectableValue; loadOptions: (query?: string) => Promise>>; - // if true, options will be reloaded when user changes the value in the input, - // otherwise, options will be loaded when the segment is clicked + /** + * If true options will be reloaded when user changes the value in the input, + * otherwise, options will be loaded when the segment is clicked + */ reloadOptionsOnChange?: boolean; onChange: (item: SelectableValue) => void; noOptionMessageHandler?: (state: AsyncState>>) => string; diff --git a/packages/grafana-ui/src/components/Segment/SegmentSelect.tsx b/packages/grafana-ui/src/components/Segment/SegmentSelect.tsx index fe84a6c62a1..a50d59b4285 100644 --- a/packages/grafana-ui/src/components/Segment/SegmentSelect.tsx +++ b/packages/grafana-ui/src/components/Segment/SegmentSelect.tsx @@ -11,7 +11,9 @@ export interface Props extends Omit, 'value' | 'onC value?: SelectableValue; options: Array>; onChange: (item: SelectableValue) => void; - // if provided - AsyncSelect will be used allowing to reload options when the value in the input changes + /** + * If provided - AsyncSelect will be used allowing to reload options when the value in the input changes + */ loadOptions?: (inputValue: string) => Promise>>; onClickOutside: () => void; width: number;