forked from cronvel/terminal-kit
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Form minor refacto, preparing multi-line TextInput
- Loading branch information
Cédric Ronvel
committed
Aug 17, 2018
1 parent
1d6d25c
commit 1f59bca
Showing
2 changed files
with
55 additions
and
44 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -49,11 +49,13 @@ var form = new termkit.Form( { | |
x: 10 , | ||
y: 10 , | ||
width: 40 , | ||
textInputs: [ | ||
inputs: [ | ||
{ | ||
key: 'login' , | ||
label: 'Login: ' , | ||
content: '[email protected]' , | ||
|
||
// Validators are not yet implemented | ||
validator: { type: 'string' } | ||
} , | ||
{ | ||
|
@@ -78,6 +80,12 @@ var form = new termkit.Form( { | |
label: 'age: ' , | ||
validator: { type: 'string' } | ||
} , | ||
{ | ||
key: 'comment' , | ||
label: 'comment: ' , | ||
height: 3 , | ||
validator: { type: 'string' } | ||
} , | ||
] , | ||
buttons: [ | ||
{ | ||
|