Skip to content

Commit 694871f

Browse files
authored
Merge pull request #330 from NHSDigital/fix/CCM-8865_remove_inline_css
Fix/ccm 8865 remove inline css
2 parents 2925540 + bc29f60 commit 694871f

File tree

10 files changed

+82
-39
lines changed

10 files changed

+82
-39
lines changed

frontend/src/__tests__/components/forms/DeleteTemplate/__snapshots__/DeleteTemplate.test.tsx.snap

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -23,8 +23,7 @@ exports[`renders component correctly 1`] = `
2323
</p>
2424
<form
2525
action="/no-action"
26-
class="nhsuk-u-margin-right-3"
27-
style="display: inline;"
26+
class="nhsuk-u-margin-right-3 inline-form"
2827
>
2928
<input
3029
name="form-id"
@@ -48,7 +47,7 @@ exports[`renders component correctly 1`] = `
4847
</form>
4948
<form
5049
action="/yes-action"
51-
style="display: inline;"
50+
class="inline-form"
5251
>
5352
<input
5453
name="form-id"

frontend/src/__tests__/components/forms/EmailTemplateForm/__snapshots__/EmailTemplateForm.test.tsx.snap

Lines changed: 20 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -164,6 +164,7 @@ exports[`renders page one error 1`] = `
164164
</span>
165165
<input
166166
aria-describedby="emailTemplateName--error-message"
167+
autocomplete="off"
167168
class="nhsuk-input nhsuk-input--error"
168169
data-testid="emailTemplateName-input"
169170
id="emailTemplateName"
@@ -184,6 +185,7 @@ exports[`renders page one error 1`] = `
184185
class="nhsuk-form-group"
185186
>
186187
<input
188+
autocomplete="off"
187189
class="nhsuk-input"
188190
data-testid="emailTemplateSubjectLine-input"
189191
id="emailTemplateSubjectLine"
@@ -204,6 +206,7 @@ exports[`renders page one error 1`] = `
204206
Message
205207
</label>
206208
<textarea
209+
autocomplete="off"
207210
class="nhsuk-textarea"
208211
data-testid="emailTemplateMessage-input"
209212
id="emailTemplateMessage"
@@ -221,7 +224,7 @@ exports[`renders page one error 1`] = `
221224
</button>
222225
</form>
223226
</div>
224-
<div
227+
<aside
225228
class="nhsuk-grid-column-one-third"
226229
>
227230
<h2
@@ -602,7 +605,7 @@ exports[`renders page one error 1`] = `
602605
</a>
603606
</li>
604607
</ul>
605-
</div>
608+
</aside>
606609
</div>
607610
</main>
608611
</DocumentFragment>
@@ -776,6 +779,7 @@ exports[`renders page with multiple errors 1`] = `
776779
</span>
777780
<input
778781
aria-describedby="emailTemplateName--error-message"
782+
autocomplete="off"
779783
class="nhsuk-input nhsuk-input--error"
780784
data-testid="emailTemplateName-input"
781785
id="emailTemplateName"
@@ -810,6 +814,7 @@ exports[`renders page with multiple errors 1`] = `
810814
</span>
811815
<input
812816
aria-describedby="emailTemplateSubjectLine--error-message"
817+
autocomplete="off"
813818
class="nhsuk-input nhsuk-input--error"
814819
data-testid="emailTemplateSubjectLine-input"
815820
id="emailTemplateSubjectLine"
@@ -842,6 +847,7 @@ exports[`renders page with multiple errors 1`] = `
842847
</span>
843848
<textarea
844849
aria-describedby="emailTemplateMessage--error-message"
850+
autocomplete="off"
845851
class="nhsuk-textarea nhsuk-textarea--error"
846852
data-testid="emailTemplateMessage-input"
847853
id="emailTemplateMessage"
@@ -859,7 +865,7 @@ exports[`renders page with multiple errors 1`] = `
859865
</button>
860866
</form>
861867
</div>
862-
<div
868+
<aside
863869
class="nhsuk-grid-column-one-third"
864870
>
865871
<h2
@@ -1240,7 +1246,7 @@ exports[`renders page with multiple errors 1`] = `
12401246
</a>
12411247
</li>
12421248
</ul>
1243-
</div>
1249+
</aside>
12441250
</div>
12451251
</main>
12461252
</DocumentFragment>
@@ -1361,6 +1367,7 @@ exports[`renders page with preloaded field values 1`] = `
13611367
class="nhsuk-form-group"
13621368
>
13631369
<input
1370+
autocomplete="off"
13641371
class="nhsuk-input"
13651372
data-testid="emailTemplateName-input"
13661373
id="emailTemplateName"
@@ -1381,6 +1388,7 @@ exports[`renders page with preloaded field values 1`] = `
13811388
class="nhsuk-form-group"
13821389
>
13831390
<input
1391+
autocomplete="off"
13841392
class="nhsuk-input"
13851393
data-testid="emailTemplateSubjectLine-input"
13861394
id="emailTemplateSubjectLine"
@@ -1401,6 +1409,7 @@ exports[`renders page with preloaded field values 1`] = `
14011409
Message
14021410
</label>
14031411
<textarea
1412+
autocomplete="off"
14041413
class="nhsuk-textarea"
14051414
data-testid="emailTemplateMessage-input"
14061415
id="emailTemplateMessage"
@@ -1420,7 +1429,7 @@ exports[`renders page with preloaded field values 1`] = `
14201429
</button>
14211430
</form>
14221431
</div>
1423-
<div
1432+
<aside
14241433
class="nhsuk-grid-column-one-third"
14251434
>
14261435
<h2
@@ -1801,7 +1810,7 @@ exports[`renders page with preloaded field values 1`] = `
18011810
</a>
18021811
</li>
18031812
</ul>
1804-
</div>
1813+
</aside>
18051814
</div>
18061815
</main>
18071816
</DocumentFragment>
@@ -1900,6 +1909,7 @@ exports[`renders page without back link for initial state with id - edit mode 1`
19001909
class="nhsuk-form-group"
19011910
>
19021911
<input
1912+
autocomplete="off"
19031913
class="nhsuk-input"
19041914
data-testid="emailTemplateName-input"
19051915
id="emailTemplateName"
@@ -1920,6 +1930,7 @@ exports[`renders page without back link for initial state with id - edit mode 1`
19201930
class="nhsuk-form-group"
19211931
>
19221932
<input
1933+
autocomplete="off"
19231934
class="nhsuk-input"
19241935
data-testid="emailTemplateSubjectLine-input"
19251936
id="emailTemplateSubjectLine"
@@ -1940,6 +1951,7 @@ exports[`renders page without back link for initial state with id - edit mode 1`
19401951
Message
19411952
</label>
19421953
<textarea
1954+
autocomplete="off"
19431955
class="nhsuk-textarea"
19441956
data-testid="emailTemplateMessage-input"
19451957
id="emailTemplateMessage"
@@ -1959,7 +1971,7 @@ exports[`renders page without back link for initial state with id - edit mode 1`
19591971
</button>
19601972
</form>
19611973
</div>
1962-
<div
1974+
<aside
19631975
class="nhsuk-grid-column-one-third"
19641976
>
19651977
<h2
@@ -2340,7 +2352,7 @@ exports[`renders page without back link for initial state with id - edit mode 1`
23402352
</a>
23412353
</li>
23422354
</ul>
2343-
</div>
2355+
</aside>
23442356
</div>
23452357
</main>
23462358
</DocumentFragment>

frontend/src/__tests__/components/forms/NhsAppTemplateForm/__snapshots__/NhsAppTemplateForm.test.tsx.snap

Lines changed: 20 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -115,6 +115,7 @@ exports[`renders page 1`] = `
115115
class="nhsuk-form-group"
116116
>
117117
<input
118+
autocomplete="off"
118119
class="nhsuk-input"
119120
id="nhsAppTemplateName"
120121
name="nhsAppTemplateName"
@@ -134,6 +135,7 @@ exports[`renders page 1`] = `
134135
Message
135136
</label>
136137
<textarea
138+
autocomplete="off"
137139
class="nhsuk-textarea"
138140
id="nhsAppTemplateMessage"
139141
maxlength="5000"
@@ -162,7 +164,7 @@ exports[`renders page 1`] = `
162164
</button>
163165
</form>
164166
</div>
165-
<div
167+
<aside
166168
class="nhsuk-grid-column-one-third"
167169
>
168170
<h2
@@ -453,7 +455,7 @@ exports[`renders page 1`] = `
453455
</a>
454456
</li>
455457
</ul>
456-
</div>
458+
</aside>
457459
</div>
458460
</main>
459461
</DocumentFragment>
@@ -618,6 +620,7 @@ exports[`renders page one error 1`] = `
618620
</span>
619621
<input
620622
aria-describedby="nhsAppTemplateName--error-message"
623+
autocomplete="off"
621624
class="nhsuk-input nhsuk-input--error"
622625
id="nhsAppTemplateName"
623626
name="nhsAppTemplateName"
@@ -637,6 +640,7 @@ exports[`renders page one error 1`] = `
637640
Message
638641
</label>
639642
<textarea
643+
autocomplete="off"
640644
class="nhsuk-textarea"
641645
id="nhsAppTemplateMessage"
642646
maxlength="5000"
@@ -663,7 +667,7 @@ exports[`renders page one error 1`] = `
663667
</button>
664668
</form>
665669
</div>
666-
<div
670+
<aside
667671
class="nhsuk-grid-column-one-third"
668672
>
669673
<h2
@@ -954,7 +958,7 @@ exports[`renders page one error 1`] = `
954958
</a>
955959
</li>
956960
</ul>
957-
</div>
961+
</aside>
958962
</div>
959963
</main>
960964
</DocumentFragment>
@@ -1121,6 +1125,7 @@ exports[`renders page with multiple errors 1`] = `
11211125
</span>
11221126
<input
11231127
aria-describedby="nhsAppTemplateName--error-message"
1128+
autocomplete="off"
11241129
class="nhsuk-input nhsuk-input--error"
11251130
id="nhsAppTemplateName"
11261131
name="nhsAppTemplateName"
@@ -1152,6 +1157,7 @@ exports[`renders page with multiple errors 1`] = `
11521157
</span>
11531158
<textarea
11541159
aria-describedby="nhsAppTemplateMessage--error-message"
1160+
autocomplete="off"
11551161
class="nhsuk-textarea nhsuk-textarea--error"
11561162
id="nhsAppTemplateMessage"
11571163
maxlength="5000"
@@ -1178,7 +1184,7 @@ exports[`renders page with multiple errors 1`] = `
11781184
</button>
11791185
</form>
11801186
</div>
1181-
<div
1187+
<aside
11821188
class="nhsuk-grid-column-one-third"
11831189
>
11841190
<h2
@@ -1469,7 +1475,7 @@ exports[`renders page with multiple errors 1`] = `
14691475
</a>
14701476
</li>
14711477
</ul>
1472-
</div>
1478+
</aside>
14731479
</div>
14741480
</main>
14751481
</DocumentFragment>
@@ -1590,6 +1596,7 @@ exports[`renders page with preloaded field values 1`] = `
15901596
class="nhsuk-form-group"
15911597
>
15921598
<input
1599+
autocomplete="off"
15931600
class="nhsuk-input"
15941601
id="nhsAppTemplateName"
15951602
name="nhsAppTemplateName"
@@ -1609,6 +1616,7 @@ exports[`renders page with preloaded field values 1`] = `
16091616
Message
16101617
</label>
16111618
<textarea
1619+
autocomplete="off"
16121620
class="nhsuk-textarea"
16131621
id="nhsAppTemplateMessage"
16141622
maxlength="5000"
@@ -1637,7 +1645,7 @@ exports[`renders page with preloaded field values 1`] = `
16371645
</button>
16381646
</form>
16391647
</div>
1640-
<div
1648+
<aside
16411649
class="nhsuk-grid-column-one-third"
16421650
>
16431651
<h2
@@ -1928,7 +1936,7 @@ exports[`renders page with preloaded field values 1`] = `
19281936
</a>
19291937
</li>
19301938
</ul>
1931-
</div>
1939+
</aside>
19321940
</div>
19331941
</main>
19341942
</DocumentFragment>
@@ -2027,6 +2035,7 @@ exports[`renders page without back link for initial state with id - edit mode 1`
20272035
class="nhsuk-form-group"
20282036
>
20292037
<input
2038+
autocomplete="off"
20302039
class="nhsuk-input"
20312040
id="nhsAppTemplateName"
20322041
name="nhsAppTemplateName"
@@ -2046,6 +2055,7 @@ exports[`renders page without back link for initial state with id - edit mode 1`
20462055
Message
20472056
</label>
20482057
<textarea
2058+
autocomplete="off"
20492059
class="nhsuk-textarea"
20502060
id="nhsAppTemplateMessage"
20512061
maxlength="5000"
@@ -2074,7 +2084,7 @@ exports[`renders page without back link for initial state with id - edit mode 1`
20742084
</button>
20752085
</form>
20762086
</div>
2077-
<div
2087+
<aside
20782088
class="nhsuk-grid-column-one-third"
20792089
>
20802090
<h2
@@ -2365,7 +2375,7 @@ exports[`renders page without back link for initial state with id - edit mode 1`
23652375
</a>
23662376
</li>
23672377
</ul>
2368-
</div>
2378+
</aside>
23692379
</div>
23702380
</main>
23712381
</DocumentFragment>

0 commit comments

Comments
 (0)