File tree Expand file tree Collapse file tree 2 files changed +16
-7
lines changed Expand file tree Collapse file tree 2 files changed +16
-7
lines changed Original file line number Diff line number Diff line change @@ -34,7 +34,7 @@ def consent_status_tag(consent)
34
34
if consent . withdrawn? || consent . invalidated?
35
35
"grey"
36
36
elsif consent . response_given?
37
- "green"
37
+ "aqua- green"
38
38
elsif consent . response_refused?
39
39
"red"
40
40
else
@@ -50,24 +50,31 @@ def consent_status_tag(consent)
50
50
)
51
51
end
52
52
53
+ # We can’t use the colour param as NHS.UK frontend uses different colour
54
+ # names (aqua-green) than those supported by GOV.UK Frontend (turquoise)
53
55
if consent . invalidated?
54
56
safe_join (
55
57
[
56
- govuk_tag ( text : tag . s ( text ) , colour : ) ,
58
+ govuk_tag ( text : tag . s ( text ) , classes : "nhsuk-tag-- #{ colour } " ) ,
57
59
vaccine_method ,
58
60
tag . span ( "Invalid" , class : "nhsuk-u-secondary-text-color" )
59
61
] . compact
60
62
)
61
63
elsif consent . withdrawn?
62
64
safe_join (
63
65
[
64
- govuk_tag ( text : tag . s ( text ) , colour : ) ,
66
+ govuk_tag ( text : tag . s ( text ) , classes : "nhsuk-tag-- #{ colour } " ) ,
65
67
vaccine_method ,
66
68
tag . span ( "Withdrawn" , class : "nhsuk-u-secondary-text-color" )
67
69
] . compact
68
70
)
69
71
else
70
- safe_join ( [ govuk_tag ( text :, colour :) , vaccine_method ] . compact )
72
+ safe_join (
73
+ [
74
+ govuk_tag ( text :, classes : "nhsuk-tag--#{ colour } " ) ,
75
+ vaccine_method
76
+ ] . compact
77
+ )
71
78
end
72
79
end
73
80
end
Original file line number Diff line number Diff line change @@ -16,22 +16,24 @@ def triage_status_tag(triage)
16
16
if triage . invalidated?
17
17
"grey"
18
18
elsif triage . ready_to_vaccinate?
19
- "green"
19
+ "aqua- green"
20
20
elsif triage . do_not_vaccinate?
21
21
"red"
22
22
else
23
23
"blue"
24
24
end
25
25
26
+ # We can’t use the colour param as NHS.UK frontend uses different colour
27
+ # names (aqua-green) than those supported by GOV.UK Frontend (turquoise)
26
28
if triage . invalidated?
27
29
safe_join (
28
30
[
29
- govuk_tag ( text : tag . s ( text ) , colour : ) ,
31
+ govuk_tag ( text : tag . s ( text ) , classes : "nhsuk-tag-- #{ colour } " ) ,
30
32
tag . span ( "Invalid" , class : "nhsuk-u-secondary-text-color" )
31
33
]
32
34
)
33
35
else
34
- govuk_tag ( text :, colour : )
36
+ govuk_tag ( text :, classes : "nhsuk-tag-- #{ colour } " )
35
37
end
36
38
end
37
39
end
You can’t perform that action at this time.
0 commit comments