mirror of
https://github.com/GSA/notifications-admin.git
synced 2026-08-18 21:49:37 -04:00
Removing or changing more govuk styles
This commit is contained in:
@@ -84,7 +84,7 @@ def test_view_organization_shows_the_correct_organization(
|
||||
)
|
||||
|
||||
assert normalize_spaces(page.select_one('h1').text) == 'Usage'
|
||||
assert normalize_spaces(page.select_one('.govuk-hint').text) == (
|
||||
assert normalize_spaces(page.select_one('.usa-hint').text) == (
|
||||
'Test 1 has no live services on Notify.gov'
|
||||
)
|
||||
assert not page.select('a[download]')
|
||||
@@ -383,7 +383,7 @@ def test_organization_services_shows_live_services_and_usage(
|
||||
assert normalize_spaces(usage_rows[5].text) == "$42.00 spent on text messages"
|
||||
|
||||
# Ensure there’s no ‘this org has no services message’
|
||||
assert not page.select('.govuk-hint')
|
||||
assert not page.select('.usa-hint')
|
||||
|
||||
|
||||
@freeze_time("2020-02-20 20:20")
|
||||
@@ -912,7 +912,7 @@ def test_view_organization_settings(
|
||||
}
|
||||
if 'hint' in option:
|
||||
option_values['hint'] = normalize_spaces(
|
||||
page.select_one('label[for={}] + .govuk-hint'.format(radios[index]['id'])).text)
|
||||
page.select_one('label[for={}] + .usa-hint'.format(radios[index]['id'])).text)
|
||||
assert option_values == option
|
||||
|
||||
if expected_selected:
|
||||
|
||||
@@ -502,7 +502,7 @@ def test_template_id_is_searchable_for_services_with_api_keys(
|
||||
normalize_spaces(item.text)
|
||||
for item in page.select(
|
||||
# Text which should be hidden from all users
|
||||
r'.template-list-item .govuk-\!-display-none'
|
||||
r'.template-list-item .display-none'
|
||||
)
|
||||
] == [
|
||||
template_2["id"],
|
||||
|
||||
@@ -45,7 +45,7 @@ describe('Collapsible fieldset', () => {
|
||||
<fieldset class="govuk-fieldset" id="folder_permissions" aria-describedby="users_with_permission-hint">
|
||||
<legend class="govuk-fieldset__legend govuk-fieldset__legend--s">
|
||||
Folders this team member can see
|
||||
<span class="govuk-hint" id="users_with_permission-hint">
|
||||
<span class="usa-hint" id="users_with_permission-hint">
|
||||
<div class="selection-summary" role="region" aria-live="polite"></div>
|
||||
</span>
|
||||
</legend>
|
||||
@@ -146,7 +146,7 @@ describe('Collapsible fieldset', () => {
|
||||
|
||||
test("the hint is removed", () => {
|
||||
|
||||
expect(document.querySelector('.govuk-hint')).toBeNull();
|
||||
expect(document.querySelector('.usa-hint')).toBeNull();
|
||||
|
||||
});
|
||||
|
||||
|
||||
@@ -17,21 +17,21 @@ describe("Error Banner", () => {
|
||||
<span class="usa-error-message banner-dangerous js-error-visible">
|
||||
</span>`;
|
||||
window.GOVUK.ErrorBanner.hideBanner();
|
||||
expect(document.querySelector('.banner-dangerous').classList).toContain('govuk-!-display-none')
|
||||
expect(document.querySelector('.banner-dangerous').classList).toContain('display-none')
|
||||
});
|
||||
});
|
||||
|
||||
describe("The `showBanner` method", () => {
|
||||
beforeEach(() => {
|
||||
document.body.innerHTML = `
|
||||
<span class="usa-error-message banner-dangerous js-error-visible govuk-!-display-none">
|
||||
<span class="usa-error-message banner-dangerous js-error-visible display-none">
|
||||
</span>`;
|
||||
|
||||
window.GOVUK.ErrorBanner.showBanner('Some Err');
|
||||
});
|
||||
|
||||
test("Will show the element", () => {
|
||||
expect(document.querySelector('.banner-dangerous').classList).not.toContain('govuk-!-display-none')
|
||||
expect(document.querySelector('.banner-dangerous').classList).not.toContain('display-none')
|
||||
});
|
||||
});
|
||||
});
|
||||
|
||||
@@ -67,7 +67,7 @@ describe("List entry", () => {
|
||||
Domain names
|
||||
</span>
|
||||
</legend>
|
||||
<span id="domains-hint" class="govuk-hint">
|
||||
<span id="domains-hint" class="usa-hint">
|
||||
For example cabinet-office.gov.uk
|
||||
</span>
|
||||
<div class="input-list" data-module="list-entry" data-list-item-name="domain" id="list-entry-domains">
|
||||
|
||||
@@ -302,7 +302,7 @@ describe('Update content', () => {
|
||||
</span>
|
||||
</div>
|
||||
<div class="govuk-grid-column-one-half file-list-status">
|
||||
<p class="govuk-body govuk-!-margin-bottom-0 govuk-hint">
|
||||
<p class="govuk-body govuk-!-margin-bottom-0 usa-hint">
|
||||
${content.status}
|
||||
</p>
|
||||
</div>
|
||||
|
||||
Reference in New Issue
Block a user