Making infobox clickable (#18676)

* Making infobox clickable

* Making it accessible

* Moving API to proposed

* Matching styling from portal

* Fixing some styling

* Moving to proposed

* Removing extra spacing

* Registering and Unregistering listeners

* Fixing listeners

* Registering emitter only once.

* Changing emitter type from undefined to void

* Adding arialabel to clickable link

* Changing property name to suit its purpose
This commit is contained in:
Aasim Khan
2022-03-09 18:43:39 -08:00
committed by GitHub
parent 0c54c12772
commit b299f7ed3f
5 changed files with 147 additions and 5 deletions

View File

@@ -1661,4 +1661,27 @@ declare module 'azdata' {
*/
graphFileType: string;
}
/**
* Component to display text with an icon representing the severity
*/
export interface InfoBoxComponent extends Component, InfoBoxComponentProperties {
/**
* An event called when the InfoBox is clicked
*/
onDidClick: vscode.Event<void>;
}
export interface InfoBoxComponentProperties {
/**
* Sets whether the infobox is clickable or not. This will display a right arrow at the end of infobox text.
* Default value is false.
*/
isClickable?: boolean | undefined;
/**
* Sets the ariaLabel for the right arrow button that shows up in clickable infoboxes
*/
clickableButtonAriaLabel?: string;
}
}