Skip to content

Commit

Permalink
- FIX: Disable mouse wheel on input boxes to prevent accidental value…
Browse files Browse the repository at this point in the history
… changes.

- FIX: Fixed navigation to next plot on blur event of last input.
- FIX: Fixed line wrapping issue on export page due to newline characters in comment.
  • Loading branch information
sebastian-raubach committed Jul 12, 2022
1 parent 32bf6ab commit 058be1a
Show file tree
Hide file tree
Showing 3 changed files with 9 additions and 7 deletions.
2 changes: 2 additions & 0 deletions src/components/DataEntryInput.vue
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,7 @@
@keyup.enter="$emit('enter')"
:value="values[index]"
@change="(event) => $emit('onValueChanged', +event)"
@wheel.prevent
type="number"
:min="(trait.restrictions && trait.restrictions.min !== null && trait.restrictions.min !== undefined) ? trait.restrictions.min : null"
:max="(trait.restrictions && trait.restrictions.max !== null && trait.restrictions.max !== undefined) ? trait.restrictions.max : null" />
Expand All @@ -32,6 +33,7 @@
:value="values[index]"
@change="(event) => $emit('onValueChanged', +event)"
type="number"
@wheel.prevent
:min="(trait.restrictions && trait.restrictions.min !== null && trait.restrictions.min !== undefined) ? trait.restrictions.min : null"
:max="(trait.restrictions && trait.restrictions.max !== null && trait.restrictions.max !== undefined) ? trait.restrictions.max : null"
:step="0.02" />
Expand Down
10 changes: 5 additions & 5 deletions src/components/DataPointEntry.vue
Original file line number Diff line number Diff line change
Expand Up @@ -489,11 +489,11 @@ export default {
this.speak(this.visibleTraitMapping[newIndex].trait.name)
}
} else {
if (this.isGuidedWalk) {
// Automatically call submit
this.$emit('submit')
}
// } else {
// if (this.isGuidedWalk) {
// // Automatically call submit
// this.$emit('submit')
// }
}
},
onValueChanged: function (event, index) {
Expand Down
4 changes: 2 additions & 2 deletions src/views/Export.vue
Original file line number Diff line number Diff line change
Expand Up @@ -316,7 +316,7 @@ export default {
}
// Comments
result += '\t' + (cell.comment ? cell.comment : '')
result += '\t' + (cell.comment ? cell.comment.replace(/\r?\n/, ' ') : '')
}
}
}
Expand Down Expand Up @@ -362,7 +362,7 @@ export default {
}
// Comments
result += '\t' + (cell.comment ? cell.comment : '')
result += '\t' + (cell.comment ? cell.comment.replace(/\r?\n/, ' ') : '')
}
}
}
Expand Down

0 comments on commit 058be1a

Please sign in to comment.