const input = <HTMLInputElement>document.getElementById("taskName");
if (input.value.match(/^ *$/)) return;
const task = ui.addTask(input.value);
const input = <HTMLInputElement>document.getElementById("taskName");
if (input.value.match(/^ *$/)) return;
const task = ui.addTask(input.value);
while (true) {
cursor = increment > 0 ? cursor.nextElementSibling : cursor.previousElementSibling;
if (!cursor || !(cursor instanceof HTMLElement)) break;
while (true) {
cursor = increment > 0 ? cursor.nextElementSibling : cursor.previousElementSibling;
if (!cursor || !(cursor instanceof HTMLElement)) break;
const oldState = task.getAttribute("data-state")!;
if (newState === oldState) return;
const createTimestamp = task.getAttribute("data-created")!;
const oldState = task.getAttribute("data-state")!;
if (newState === oldState) return;
const createTimestamp = task.getAttribute("data-created")!;
return ui.setState(createTimestamp, newState, oldState);
},
setView: function (state: string, color: string) {
const sheet = (document.getElementById("viewStyle") as HTMLStyleElement).sheet!;
return ui.setState(createTimestamp, newState, oldState);
},
setView: function (state: string, color: string) {
const sheet = (document.getElementById("viewStyle") as HTMLStyleElement).sheet!;
if (event.key == "m") return browserUI.setState("someday-maybe");
} else if (inputState === InputState.V) {
inputState = InputState.Root;
if (event.key == "m") return browserUI.setState("someday-maybe");
} else if (inputState === InputState.V) {
inputState = InputState.Root;
if (event.key == "c") return browserUI.setView("cancelled", "Red");
if (event.key == "d") return browserUI.setView("done", "LawnGreen");
if (event.key == "q") return browserUI.setView("todo", "White");
if (event.key == "c") return browserUI.setView("cancelled", "Red");
if (event.key == "d") return browserUI.setView("done", "LawnGreen");
if (event.key == "q") return browserUI.setView("todo", "White");