},
};
+const Log = {
+ addTask: function (description: string) {
+ Model.addTask(description);
+ },
+};
+
function handleKey(event: any) {
if (event.target.tagName !== "INPUT") {
if (event.key == "j") Model.moveCursor(1);
function browserCreateTask(form: any) {
if (form.taskName.value) {
- Model.addTask(form.taskName.value);
+ Log.addTask(form.taskName.value);
}
form.taskName.value = "";
return false;