diff --git a/app/javascript/src/validated_form.js b/app/javascript/src/validated_form.js index c7e0edf215..740b1929fc 100644 --- a/app/javascript/src/validated_form.js +++ b/app/javascript/src/validated_form.js @@ -265,15 +265,21 @@ class NonDrivingContactMediumWarning extends ValidatableFormSectionComponent { } showWarningConfirmation () { - this.checkboxContainer.append($( + if (!(this.warningConfirmationShown)) { + this.checkboxContainer.append($( `
` - )) + )) + } + + this.warningConfirmationShown = true } removeWarningConfirmation () { + delete this.warningConfirmationShown + this.checkboxContainer.find('.warning-required-checkbox').remove() } }