Skip to content

Commit

Permalink
Prevent page from reloading when adding a new task in Chrome
Browse files Browse the repository at this point in the history
  • Loading branch information
raimund-schluessler committed Jan 25, 2019
1 parent 8918f90 commit 4d4b8e2
Show file tree
Hide file tree
Showing 3 changed files with 3 additions and 3 deletions.
2 changes: 1 addition & 1 deletion src/components/Task.vue
Expand Up @@ -103,7 +103,7 @@ License along with this library. If not, see <http://www.gnu.org/licenses/>.
v-click-outside="($event) => cancelCreation($event)"
class="task-item add-subtask"
>
<form name="addTaskForm" @submit="addTask">
<form name="addTaskForm" @submit.prevent="addTask">
<input v-model="newTaskName"
v-focus
:placeholder="subtasksCreationPlaceholder"
Expand Down
2 changes: 1 addition & 1 deletion src/components/TheCollections/Calendar.vue
Expand Up @@ -26,7 +26,7 @@ License along with this library. If not, see <http://www.gnu.org/licenses/>.
id="add-task"
class="add-task"
>
<form name="addTaskForm" @submit="addTask">
<form name="addTaskForm" @submit.prevent="addTask">
<input id="target"
v-model="newTaskName"
:placeholder="inputString"
Expand Down
2 changes: 1 addition & 1 deletion src/components/TheCollections/General.vue
Expand Up @@ -26,7 +26,7 @@ License along with this library. If not, see <http://www.gnu.org/licenses/>.
id="add-task"
class="add-task"
>
<form name="addTaskForm" @submit="addTask">
<form name="addTaskForm" @submit.prevent="addTask">
<input v-model="newTaskName"
:placeholder="inputString"
:disabled="isAddingTask"
Expand Down

0 comments on commit 4d4b8e2

Please sign in to comment.