diff --git a/less/checkbox.less b/less/checkbox.less index 7487b5ad79..887a65da8e 100644 --- a/less/checkbox.less +++ b/less/checkbox.less @@ -17,7 +17,7 @@ margin-right: 20px; } - &:before { + &::before { border: solid 2px @ffe-grey; border-radius: 2px; content: ''; @@ -32,7 +32,7 @@ background-color: @ffe-white; } - &:after { + &::after { transform: scaleX(-1) rotate(180deg + -45deg); transform-origin: left top; border-right: 3px solid transparent; @@ -52,32 +52,32 @@ opacity: 0; cursor: pointer; - &:checked + .ffe-checkbox:before, - &:hover + .ffe-checkbox:before, - &:focus + .ffe-checkbox:before, - &:active + .ffe-checkbox:before { + &:checked + .ffe-checkbox::before, + &:hover + .ffe-checkbox::before, + &:focus + .ffe-checkbox::before, + &:active + .ffe-checkbox::before { outline: none; } - &:hover + .ffe-checkbox:before { + &:hover + .ffe-checkbox::before { border-color: @ffe-blue-royal-light-wcag; } - &:active + .ffe-checkbox:before, - &:focus + .ffe-checkbox:before { + &:active + .ffe-checkbox::before, + &:focus + .ffe-checkbox::before { box-shadow: 0 0 0 2px @ffe-blue-focus; } - &:checked + .ffe-checkbox:before { + &:checked + .ffe-checkbox::before { border-color: @ffe-blue-royal-light-wcag; background-color: @ffe-white; } - &:focus + .ffe-checkbox:before { + &:focus + .ffe-checkbox::before { box-shadow: 0 0 0 2px @ffe-blue-focus; } - &:checked + .ffe-checkbox:after { + &:checked + .ffe-checkbox::after { animation: checkmark 0.4s; border-color: @ffe-blue-royal-light-wcag; } @@ -85,12 +85,12 @@ @keyframes checkmark { 0% { - height: 0; - width: 6px; + height: 0; + width: 6px; } 50% { - height: 11px; - width: 6px; + height: 11px; + width: 6px; } } diff --git a/less/field-error-message.less b/less/field-error-message.less index 42f1f73944..a3d9f8c152 100644 --- a/less/field-error-message.less +++ b/less/field-error-message.less @@ -5,7 +5,7 @@ display: none; } - &:before:extend(.ffe-field-info-message:before) { + &::before:extend(.ffe-field-info-message::before) { content: '!'; background-color: @ffe-orange-wcag; } diff --git a/less/field-info-message.less b/less/field-info-message.less index 6d63762959..5a60b44a6f 100644 --- a/less/field-info-message.less +++ b/less/field-info-message.less @@ -8,7 +8,7 @@ display: none; } - &:before { + &::before { content: 'i'; color: @ffe-white; background-color: @ffe-blue-royal; diff --git a/less/field-success-message.less b/less/field-success-message.less index 67d2e78926..387ac03cd8 100644 --- a/less/field-success-message.less +++ b/less/field-success-message.less @@ -5,7 +5,7 @@ display: none; } - &:before:extend(.ffe-field-info-message:before) { + &::before:extend(.ffe-field-info-message::before) { content: '\2713'; background-color: @ffe-green-wcag; } diff --git a/less/form.less b/less/form.less index 14c52008f3..abc78a2af4 100644 --- a/less/form.less +++ b/less/form.less @@ -26,5 +26,5 @@ select, textarea, input:not([type="radio"]):not([type="checkbox"]) { - appearance: none; + appearance: none; } diff --git a/less/input-field.less b/less/input-field.less index 9b4011e1ad..7459cbfb7f 100644 --- a/less/input-field.less +++ b/less/input-field.less @@ -14,7 +14,8 @@ border-color: @ffe-blue-royal-light-wcag; } - &:focus, &:active { + &:focus, + &:active { border-color: @ffe-blue-royal-light-wcag; box-shadow: 0 0 0 2px @ffe-blue-focus; outline: none; diff --git a/less/radio-block.less b/less/radio-block.less index e2b953be52..a5b8cae1cf 100644 --- a/less/radio-block.less +++ b/less/radio-block.less @@ -14,7 +14,7 @@ background-color: @ffe-white; cursor: pointer; - &:before { + &::before { .ffe-sb1-radioblob(); left: 20px; @@ -30,8 +30,8 @@ } &__wrapper { - padding: 20px 20px 30px; - cursor: auto; + padding: 20px 20px 30px; + cursor: auto; &--empty { padding: 0; @@ -63,7 +63,7 @@ } } - &:checked + .ffe-radio-block__content:before { + &:checked + .ffe-radio-block__content::before { .ffe-sb1-radioblob-active(); } diff --git a/less/radio-button.less b/less/radio-button.less index dfe121b11d..750d9043ec 100644 --- a/less/radio-button.less +++ b/less/radio-button.less @@ -14,7 +14,7 @@ margin-right: 20px; } - &:before { + &::before { content: ''; background-color: @ffe-white; border: 2px solid @ffe-grey; @@ -27,7 +27,7 @@ top: 3px; } - &:after { + &::after { content: ''; border: 2px solid transparent; width: 20px; @@ -41,32 +41,32 @@ } .ffe-radio-input { - &:checked + .ffe-radio-button:before, - &:hover + .ffe-radio-button:before, - &:focus + .ffe-radio-button:before, - &:active + .ffe-radio-button:before { + &:checked + .ffe-radio-button::before, + &:hover + .ffe-radio-button::before, + &:focus + .ffe-radio-button::before, + &:active + .ffe-radio-button::before { outline: none; } - &:hover + .ffe-radio-button:before { + &:hover + .ffe-radio-button::before { border-color: @ffe-blue-royal-light-wcag; } - &:active + .ffe-radio-button:before, - &:focus + .ffe-radio-button:before { + &:active + .ffe-radio-button::before, + &:focus + .ffe-radio-button::before { border-color: @ffe-blue-focus; } - &:checked + .ffe-radio-button:before { + &:checked + .ffe-radio-button::before { background-color: @ffe-blue-royal-light-wcag; border: 5px solid @ffe-white; } - &:checked + .ffe-radio-button:after { + &:checked + .ffe-radio-button::after { border-color: @ffe-blue-royal-light-wcag; } - &:focus + .ffe-radio-button:before { + &:focus + .ffe-radio-button::before { box-shadow: 0 0 0 2px @ffe-blue-focus; } } diff --git a/less/radio-input.less b/less/radio-input.less index ba384a597e..cb85d89719 100644 --- a/less/radio-input.less +++ b/less/radio-input.less @@ -1,4 +1,4 @@ .ffe-radio-input { - position: absolute; - opacity: 0; + position: absolute; + opacity: 0; } diff --git a/less/radio-switch.less b/less/radio-switch.less index c79a06a4ba..416319b848 100644 --- a/less/radio-switch.less +++ b/less/radio-switch.less @@ -14,11 +14,11 @@ box-shadow: 0 1px 2px 1px rgba(0, 0, 0, 0.05); margin-bottom: 5px; - &:before { - .ffe-sb1-radioblob(); + &::before { + .ffe-sb1-radioblob(); - left: 12px; - top: 8px; + left: 12px; + top: 8px; } @media screen and (min-width: @breakpoint-sm) { @@ -41,7 +41,7 @@ border-color: @ffe-blue-focus; } - &:checked + .ffe-radio-switch:before { + &:checked + .ffe-radio-switch::before { .ffe-sb1-radioblob-active(); } } diff --git a/less/textarea.less b/less/textarea.less index 1f93b44754..a3b73b370d 100644 --- a/less/textarea.less +++ b/less/textarea.less @@ -13,7 +13,8 @@ border-color: @ffe-blue-royal-light-wcag; } - &:focus, &:active { + &:focus, + &:active { border-color: @ffe-blue-royal-light-wcag; box-shadow: 0 0 0 2px @ffe-blue-focus; outline: none; diff --git a/less/tooltip.less b/less/tooltip.less index 58bb0d5cc6..31302d64f5 100644 --- a/less/tooltip.less +++ b/less/tooltip.less @@ -18,7 +18,8 @@ vertical-align: middle; width: @ffe-tooltip-size; - &:hover, &:focus { + &:hover, + &:focus { border-color: @ffe-blue-royal-light-wcag; } @@ -27,7 +28,8 @@ outline: none; } - &:active, &--active { + &:active, + &--active { border-color: @ffe-blue-royal; color: @ffe-blue-royal; }