mirror of
https://github.com/GSA/notifications-admin.git
synced 2026-09-05 02:28:25 -04:00
Merge branch 'main' into notify-admin-211
This commit is contained in:
@@ -256,7 +256,7 @@ def govuk_text_input_field_widget(self, field, type=None, param_extensions=None,
|
||||
merge_jsonlike(params, param_extensions)
|
||||
|
||||
return Markup(
|
||||
render_template('components/uk_components/input/template.njk', params=params))
|
||||
render_template('components/components/input/template.njk', params=params))
|
||||
|
||||
|
||||
class GovukTextInputField(StringField):
|
||||
@@ -313,7 +313,7 @@ class GovukSearchField(SearchField):
|
||||
# this bypasses that by making self.widget a method with the same interface as widget.__call__
|
||||
def widget(self, field, param_extensions=None, **kwargs):
|
||||
|
||||
params = {"classes": "govuk-!-width-full"} # email addresses don't need to be spellchecked
|
||||
params = {"classes": ""} # email addresses don't need to be spellchecked
|
||||
merge_jsonlike(params, param_extensions)
|
||||
|
||||
return govuk_text_input_field_widget(self, field, type="search", param_extensions=params, **kwargs)
|
||||
@@ -511,7 +511,7 @@ class NestedFieldMixin:
|
||||
}
|
||||
},
|
||||
"formGroup": {
|
||||
"classes": "govuk-form-group--nested"
|
||||
"classes": "usa-form-group--nested"
|
||||
},
|
||||
"asList": True,
|
||||
"items": []
|
||||
@@ -720,7 +720,6 @@ def govuk_checkboxes_field_widget(self, field, wrap_in_collapsible=False, param_
|
||||
"attributes": {"id": field.name},
|
||||
"legend": {
|
||||
"text": field.label.text,
|
||||
"classes": "govuk-fieldset__legend--s"
|
||||
}
|
||||
},
|
||||
"asList": self.render_as_list,
|
||||
@@ -791,7 +790,7 @@ def govuk_radios_field_widget(self, field, param_extensions=None, **kwargs):
|
||||
merge_jsonlike(params, param_extensions)
|
||||
|
||||
return Markup(
|
||||
render_template('components/uk_components/radios/template.njk', params=params))
|
||||
render_template('components/components/radios/template.njk', params=params))
|
||||
|
||||
|
||||
class GovukCheckboxField(BooleanField):
|
||||
@@ -848,7 +847,7 @@ class GovukTextareaField(TextAreaField):
|
||||
merge_jsonlike(params, param_extensions)
|
||||
|
||||
return Markup(
|
||||
render_template('components/uk_components/textarea/template.njk', params=params))
|
||||
render_template('components/components/textarea/template.njk', params=params))
|
||||
|
||||
|
||||
# based on work done by @richardjpope: https://github.com/richardjpope/recourse/blob/master/recourse/forms.py#L6
|
||||
|
||||
@@ -46,7 +46,7 @@ class ValidGovEmail:
|
||||
from flask import url_for
|
||||
message = '''
|
||||
Enter a public sector email address or
|
||||
<a class="govuk-link govuk-link--no-visited-state" href="{}">find out who can use Notify</a>
|
||||
<a class="usa-link" href="{}">find out who can use Notify</a>
|
||||
'''.format(url_for('main.features'))
|
||||
if not is_gov_user(field.data.lower()):
|
||||
raise ValidationError(message)
|
||||
|
||||
@@ -93,7 +93,7 @@ def create_api_key(service_id):
|
||||
'hint': {
|
||||
'html': Markup(
|
||||
'Not available because your service is in '
|
||||
'<a class="govuk-link govuk-link--no-visited-state" href="/features/trial-mode">trial mode</a>')
|
||||
'<a class="usa-link" href="/features/trial-mode">trial mode</a>')
|
||||
}
|
||||
}
|
||||
if form.validate_on_submit():
|
||||
|
||||
@@ -22,7 +22,7 @@ def accept_invite(token):
|
||||
message = Markup("""
|
||||
You’re signed in as {}.
|
||||
This invite is for another email address.
|
||||
<a href={} class="govuk-link govuk-link--no-visited-state">Sign out</a>
|
||||
<a href={} class="usa-link">Sign out</a>
|
||||
and click the link again to accept this invite.
|
||||
""".format(
|
||||
current_user.email_address,
|
||||
@@ -82,7 +82,7 @@ def accept_org_invite(token):
|
||||
message = Markup("""
|
||||
You’re signed in as {}.
|
||||
This invite is for another email address.
|
||||
<a class="govuk-link govuk-link--no-visited-state" href={}>Sign out</a>
|
||||
<a class="usa-link" href={}>Sign out</a>
|
||||
and click the link again to accept this invite.
|
||||
""".format(
|
||||
current_user.email_address,
|
||||
|
||||
@@ -64,7 +64,7 @@ def sign_in():
|
||||
flash(Markup(
|
||||
(
|
||||
f"The email address or password you entered is incorrect."
|
||||
f" <a href={password_reset_url} class='govuk-link'>Forgot your password?</a>"
|
||||
f" <a href={password_reset_url} class='usa-link'>Forgot your password?</a>"
|
||||
)
|
||||
))
|
||||
|
||||
|
||||
Reference in New Issue
Block a user