I'm using Form control and hide a control base on condition. It is working if I use tab to navigate or move focus between child control on a page but it redraw if I'm using down or up arrow for navigation. does any body use form control to handle visibility?
Controller :
export class LoginController {
view: LoginView
I'm using Form control and hide a control base on condition. It is working if I use tab to navigate or move focus between child control on a page but it redraw if I'm using down or up arrow for navigation. does any body use form control to handle visibility?
Controller : export class LoginController { view: LoginView
};
View: import Screen from '../screen' const tkit = require("terminal-kit"); import { BaseView } from '../shared/base.view'; export class LoginView { form: any constructor() { this.form = new tkit.Form({ parent: Screen.document.elements.core, x: 1, y: 1, width: 40,',
value: 'ok'
},
{
content: '',
value: 'cancel'
}
]
});
inputs: [ { key: 'UserName', label: 'Login: ', content: '', validator: { type: 'string' }, maxLength: 20, }, { key: 'Password', echoChar: '*', label: 'Password: ', validator: { type: 'number' }, disabled: true } , { key: 'bdate', label: 'Birth Date: ', content: '', validator: { type: 'string' }, maxLength: 20, } ], buttons: [ { content: '
};
Step to reproduce :
step 1:
Step 2: Press enter. It will hide Birth date input control![image](https://user-images.githubusercontent.com/32077544/233646806-b9099635-6a5b-43c4-bf34-f3a5fc9ae08e.png)
Step 3: press tab It will work without any issue
Issue Step 4: instead of using tab, use down or up arrow.![image](https://user-images.githubusercontent.com/32077544/233647045-12492e84-526e-454d-9e9c-5a896ec7c562.png)
it will display again.
anybody use form control in your application and noticed such issue?