Skip to content

Commit

Permalink
Merge pull request #436 from ProcessMaker/bugfix/FOUR-17713
Browse files Browse the repository at this point in the history
Bugfix/FOUR-17713: 39852 Immatics Corrupted Process
  • Loading branch information
ryancooley authored Aug 13, 2024
2 parents 2729f22 + 43492a7 commit a7926cb
Showing 1 changed file with 21 additions and 7 deletions.
28 changes: 21 additions & 7 deletions src/components/FormInput.vue
Original file line number Diff line number Diff line change
Expand Up @@ -5,12 +5,12 @@
v-bind="$attrs"
v-uni-id="name"
:value="value"
@input="$emit('input', $event.target.value)"
@input="handleInput"
:name="name"
class="form-control"
:class="classList"
v-on:blur="formatFloatValue()"
>
/>
<display-errors v-if="error || (validator && validator.errorCount)" :name="name" :error="error" :validator="validator"/>
<small v-if="helper" class="form-text text-muted" v-html="helper"/>
</div>
Expand Down Expand Up @@ -39,7 +39,13 @@ export default {
'helper',
'name',
'controlClass',
'validateKeyStrokes',
],
data() {
return {
validator: null,
}
},
computed:{
classList() {
return {
Expand All @@ -48,10 +54,18 @@ export default {
}
}
},
data() {
return {
validator: null
methods: {
handleInput(event) {
if (this.validateKeyStrokes) {
const allowedVariableRegex = new RegExp(this.validateKeyStrokes);
if (!allowedVariableRegex.test(event.target.value)) {
this.$emit("input", this.value);
event.target.value = this.value;
return;
}
}
this.$emit("input", event.target.value);
}
},
}
}
};
</script>

0 comments on commit a7926cb

Please sign in to comment.