mirror of
https://github.com/ckaczor/azuredatastudio.git
synced 2026-02-17 02:51:36 -05:00
port vscode changes (#19754)
* add aria-description support for selectbox * type check
This commit is contained in:
@@ -40,7 +40,7 @@ export interface ISelectBoxDelegate extends IDisposable {
|
|||||||
export interface ISelectBoxOptions {
|
export interface ISelectBoxOptions {
|
||||||
useCustomDrawn?: boolean;
|
useCustomDrawn?: boolean;
|
||||||
ariaLabel?: string;
|
ariaLabel?: string;
|
||||||
ariaDescription?: string; // {{SQL CARBON EDIT}} - Add aria description
|
ariaDescription?: string;
|
||||||
minBottomMargin?: number;
|
minBottomMargin?: number;
|
||||||
optionsAsChildren?: boolean;
|
optionsAsChildren?: boolean;
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -127,7 +127,6 @@ export class SelectBoxList extends Disposable implements ISelectBoxDelegate, ILi
|
|||||||
this.selectElement.setAttribute('aria-label', this.selectBoxOptions.ariaLabel);
|
this.selectElement.setAttribute('aria-label', this.selectBoxOptions.ariaLabel);
|
||||||
}
|
}
|
||||||
|
|
||||||
// {{SQL CARBON EDIT}}
|
|
||||||
if (typeof this.selectBoxOptions.ariaDescription === 'string') {
|
if (typeof this.selectBoxOptions.ariaDescription === 'string') {
|
||||||
this.selectElement.setAttribute('aria-description', this.selectBoxOptions.ariaDescription);
|
this.selectElement.setAttribute('aria-description', this.selectBoxOptions.ariaDescription);
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -36,7 +36,6 @@ export class SelectBoxNative extends Disposable implements ISelectBoxDelegate {
|
|||||||
this.selectElement.setAttribute('aria-label', this.selectBoxOptions.ariaLabel);
|
this.selectElement.setAttribute('aria-label', this.selectBoxOptions.ariaLabel);
|
||||||
}
|
}
|
||||||
|
|
||||||
// {{SQL CARBON EDIT}}
|
|
||||||
if (typeof this.selectBoxOptions.ariaDescription === 'string') {
|
if (typeof this.selectBoxOptions.ariaDescription === 'string') {
|
||||||
this.selectElement.setAttribute('aria-description', this.selectBoxOptions.ariaDescription);
|
this.selectElement.setAttribute('aria-description', this.selectBoxOptions.ariaDescription);
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user