Fix a couple a11y issues (#8334)

* Fix a couple a11y issues

* Add other dialog
This commit is contained in:
Charles Gagnon
2019-11-15 07:41:09 -08:00
committed by GitHub
parent 02b1673c71
commit 7563416754
5 changed files with 6 additions and 4 deletions

View File

@@ -105,7 +105,7 @@ export class SelectBox extends vsSelectBox {
// SelectBoxList uses its own custom drop down list so we need to also stop propagation from that or it'll
// also bubble up
this.onkeydown(this.selectBoxDelegate.selectDropDownContainer, (e: IKeyboardEvent) => {
if (e.keyCode === KeyCode.Enter) {
if (e.keyCode === KeyCode.Enter || e.keyCode === KeyCode.Escape) {
dom.EventHelper.stop(e, true);
}
});

View File

@@ -56,6 +56,8 @@
.modal .modal-title {
font-size: 15px;
font-weight: 600;
margin-block-start: 0px;
margin-block-end: 0px;
}
.modal .modal-title-icon {

View File

@@ -188,7 +188,7 @@ export abstract class Modal extends Disposable implements IThemable {
this._modalTitleIcon = DOM.append(this._modalHeaderSection, DOM.$('.modal-title-icon'));
}
this._modalTitle = DOM.append(this._modalHeaderSection, DOM.$('.modal-title'));
this._modalTitle = DOM.append(this._modalHeaderSection, DOM.$('h1.modal-title'));
this._modalTitle.innerText = this._title;
}