Change variable names to be clearer
This commit is contained in:
parent
3f2beb44b2
commit
850153a517
@ -9,7 +9,7 @@ export default {
|
||||
if (typeof this[name] !== undefined) {
|
||||
this[name] = value
|
||||
if (event['parent_uid'] === this._uid) {
|
||||
this.disabled = false
|
||||
this.changed = true
|
||||
}
|
||||
}
|
||||
},
|
||||
@ -17,14 +17,14 @@ export default {
|
||||
|
||||
data: function() {
|
||||
return {
|
||||
disabled: this.disableSave,
|
||||
changed: this.hasChanges,
|
||||
}
|
||||
},
|
||||
|
||||
props: {
|
||||
disableSave: {
|
||||
hasChanges: {
|
||||
type: Boolean,
|
||||
default: true,
|
||||
default: false,
|
||||
},
|
||||
},
|
||||
}
|
||||
|
@ -1,6 +1,6 @@
|
||||
{% macro SaveButton(text, additional_classes="") -%}
|
||||
{% set class = "usa-button usa-button-primary" + additional_classes %}
|
||||
<button type="submit" class="{{ class }}" tabindex="0" v-bind:disabled="disabled">
|
||||
<button type="submit" class="{{ class }}" tabindex="0" v-bind:disabled="!changed">
|
||||
{{ text }}
|
||||
</button>
|
||||
{%- endmacro %}
|
||||
|
Loading…
x
Reference in New Issue
Block a user