Add ability to handle enter key propagation for input model components (#7524)

* Add ability to stop enter key propagation for input model components

* Fix spacing

* onInputEntered -> onEnterKeyPressed
This commit is contained in:
Charles Gagnon
2019-10-07 12:05:43 -07:00
committed by GitHub
parent effa50a9bd
commit 5454917569
7 changed files with 73 additions and 1 deletions

9
src/sql/azdata.d.ts vendored
View File

@@ -2991,6 +2991,11 @@ declare module 'azdata' {
columns?: number;
min?: number;
max?: number;
/**
* Whether to stop key event propagation when enter is pressed in the input box. Leaving this as false
* means the event will propagate up to any parents that have handlers (such as validate on Dialogs)
*/
stopEnterPropagation?: boolean;
}
export interface TableColumn {
@@ -3235,6 +3240,10 @@ declare module 'azdata' {
export interface InputBoxComponent extends Component, InputBoxProperties {
onTextChanged: vscode.Event<any>;
/**
* Event that's fired whenever enter is pressed within the input box
*/
onEnterKeyPressed: vscode.Event<string>;
}
export interface RadioButtonComponent extends Component, RadioButtonProperties {