Strict null pass on some base ui files (#4832)

* more strict null checks in base browser code

* revert changes to radiobutton

* fix some more minor things, enable strict null check in pipelines

* formatting

* fix compile errors

* make null undefined

* more null to undefined
This commit is contained in:
Anthony Dresser
2019-04-03 16:18:33 -07:00
committed by GitHub
parent 80a8e1a4da
commit cef5bbb2be
25 changed files with 253 additions and 234 deletions

View File

@@ -74,9 +74,9 @@ export interface ISelectData {
export class SelectBox extends Widget implements ISelectBoxDelegate {
// {{SQL CARBON EDIT}}
protected selectElement: HTMLSelectElement;
protected selectBackground: Color;
protected selectForeground: Color;
protected selectBorder: Color;
protected selectBackground?: Color;
protected selectForeground?: Color;
protected selectBorder?: Color;
private styles: ISelectBoxStyles;
private selectBoxDelegate: ISelectBoxDelegate;
@@ -137,14 +137,15 @@ export class SelectBox extends Widget implements ISelectBoxDelegate {
public applyStyles(): void {
this.selectBoxDelegate.applyStyles();
}
// {{SQL CARBON EDIT}}
protected createOption(value: string, disabled?: boolean): HTMLOptionElement {
let option = document.createElement('option');
option.value = value;
option.text = value;
option.disabled = disabled;
option.disabled = disabled || false;
return option;
}
}
}