diff --git a/src/components/ListItems/ListElement.css b/src/components/ListItems/ListElement.css index 9501f35..e843b34 100644 --- a/src/components/ListItems/ListElement.css +++ b/src/components/ListItems/ListElement.css @@ -10,7 +10,7 @@ } .dropdown { - position: relative; + position: relative; display: inline-block; width: 100%; } @@ -97,8 +97,7 @@ .ListContainer { display: flex; flex-direction: column; - min-height: 60%; - max-height: 64%; + max-height:80%; max-width: 100%; overflow-y:auto; flex:1; diff --git a/src/components/ListItems/ListElement.vue b/src/components/ListItems/ListElement.vue index 7f7af95..6c8f406 100644 --- a/src/components/ListItems/ListElement.vue +++ b/src/components/ListItems/ListElement.vue @@ -131,7 +131,7 @@ export default { }, methods: { saveEditableText(index, event) { - let newText = event.target.innerText; + /*let newText = event.target.innerText; //Limit text length to 500 chars as validation @@ -149,10 +149,10 @@ export default { sel.removeAllRanges(); sel.addRange(range); - this.saveList(); + this.saveList();*/ }, completeItem(index) { - if (this.itemsArray[index].textString != '') { + if (this.itemsArray[index].textString != null && this.itemsArray[index].textString != '') { this.completedItemsArray.push(this.itemsArray[index]); } this.removeItemByIndex(index); @@ -196,7 +196,7 @@ export default { }, loadDefaultItemValues() { //future makes api call to get this user's default values - + }, createNewItem(text) { return { @@ -214,7 +214,6 @@ export default { }, createItemWithExistingValues(text) { return { - //Will be replaced eventually textString: text, scheduledCheckbox: this.scheduledCheckbox, @@ -378,12 +377,12 @@ export default { this.$nextTick(() => { this.focusEditable(newIndex); + this.itemsArray.splice(index, 1); + if (this.itemsArray.length === 0) { + this.itemsArray.push(this.createNewItem('')); // Add an empty item as a base case + this.saveList(); + } }); - this.itemsArray.splice(index, 1); - if (this.itemsArray.length === 0) { - this.itemsArray.push(this.createNewItem('')); // Add an empty item as a base case - } - this.saveList(); } }, setCaretPosition(element, position) { diff --git a/src/views/Dashboard.vue b/src/views/Dashboard.vue index 778e86d..8e990a3 100644 --- a/src/views/Dashboard.vue +++ b/src/views/Dashboard.vue @@ -15,6 +15,7 @@ + @@ -46,6 +47,7 @@ export default { }, methods: { handleTaskUpdates(updatedTasks, listName) { + }, handleTaskClicked(taskData) {