Skip to content
This repository was archived by the owner on Oct 25, 2021. It is now read-only.

Commit 98117ed

Browse files
committed
Minor adjustments to GDS 3 styling
1 parent 49a440f commit 98117ed

File tree

4 files changed

+46
-9
lines changed

4 files changed

+46
-9
lines changed

assets/css/hmcts-webchat-gds-v3.css

Lines changed: 24 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1128,7 +1128,7 @@ input[type="number"] {
11281128

11291129
button,
11301130
input[type="submit"] {
1131-
background-color: #00823b !important;
1131+
background-color: #00703c !important;
11321132
background-image: none !important;
11331133
border-color: transparent !important;
11341134
color: #ffffff !important;
@@ -1137,10 +1137,30 @@ input[type="submit"] {
11371137
width: calc(100% - 40px) !important;
11381138
}
11391139

1140-
button:hover, button:focus,
1141-
input[type="submit"]:hover,
1140+
button:hover,
1141+
input[type="submit"]:hover {
1142+
background-color: #005a30 !important;
1143+
}
1144+
1145+
button:focus,
11421146
input[type="submit"]:focus {
1143-
background-color: #00682f !important;
1147+
border-color: #ffdd00 !important;
1148+
box-shadow: inset 0 0 0 1px #ffdd00 !important;
1149+
outline: 3px solid transparent;
1150+
}
1151+
1152+
button:focus:not(:active):not(:hover),
1153+
input[type="submit"]:focus:not(:active):not(:hover) {
1154+
background-color: #ffdd00 !important;
1155+
border-color: #ffdd00 !important;
1156+
box-shadow: 0 2px 0 #0b0c0c !important;
1157+
color: #0b0c0c !important;
1158+
}
1159+
1160+
button:active,
1161+
input[type="submit"]:active {
1162+
box-shadow: 0 2px 0 #002d18;
1163+
outline: 0;
11441164
}
11451165

11461166
input[type="text"],

assets/javascript/hmcts-webchat.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -44,7 +44,7 @@ function parseText(text) {
4444
}
4545

4646
function webchat_init(customParams) {
47-
const version = '0.3.4';
47+
const version = '0.3.5';
4848
const requiredParams = [
4949
'uuid',
5050
'tenant',

assets/sass/hmcts-webchat-gds-v3.scss

Lines changed: 20 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@
77
@import "node_modules/govuk-frontend-3/govuk/components/label/label";
88
@import "node_modules/govuk-frontend-3/govuk/components/textarea/textarea";
99

10-
$govuk-button-colour: #00823b; // sass-lint:disable no-color-literals
10+
$govuk-button-colour: govuk-colour("green");; // sass-lint:disable no-color-literals
1111
$govuk-button-hover-colour: govuk-shade($govuk-button-colour, 20%);
1212
$govuk-button-shadow-colour: govuk-shade($govuk-button-colour, 60%);
1313
$govuk-button-text-colour: govuk-colour("white");
@@ -24,10 +24,27 @@ input[type="submit"] {
2424
margin-top: 10px !important;
2525
width: calc(100% - 40px) !important;
2626

27-
&:hover,
28-
&:focus {
27+
&:hover {
2928
background-color: $govuk-button-hover-colour !important;
3029
}
30+
31+
&:focus {
32+
border-color: govuk-colour("yellow") !important;
33+
box-shadow: inset 0 0 0 1px govuk-colour("yellow") !important;
34+
outline: 3px solid transparent;
35+
36+
&:not(:active):not(:hover) {
37+
background-color: govuk-colour("yellow") !important;
38+
border-color: govuk-colour("yellow") !important;
39+
box-shadow: 0 2px 0 govuk-colour("black") !important;
40+
color: govuk-colour("black") !important;
41+
}
42+
}
43+
44+
&:active {
45+
box-shadow: 0 2px 0 $govuk-button-shadow-colour;
46+
outline: 0;
47+
}
3148
}
3249

3350
input[type="text"],

package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "@hmcts/ctsc-web-chat",
3-
"version": "0.3.4",
3+
"version": "0.3.5",
44
"description": "HMCTS CTSC Web Chat",
55
"repository": {
66
"type": "git",

0 commit comments

Comments
 (0)