Try to login with a wrong password.
You will get a warning.
Check the site with AXE of WAVE or your favourite a11y check tool.
No contrast error
The warning / text combination has a contrast ratio of about 1.7.
It is for both. Defined in the webcomponent for alerts.
#29174 should be resolved now. If I understand right, it addresses the alerts in bootstrap and meanwhile they have good contrast ratio. #27369
My issue is caused by messages of type warning from the system, this is undpendent from client.
AFAIK it is defined in atum and cassiopea since #30294 by
Atum /administrator/templates/atum/scss/vendor/joomla-custom-elements/joomla-alert.scss
and similar for Cassiopea
&[type="warning"] {
--alert-accent-color: var(--warning);
}
in Atum
var(--warning)
equals $yellow
in variables.
and $yellow: #ffb514; //used in bootstrap
and in Cassiopea by
var(--warning) equals $yellow in variables.
and $yellow: #f0ad4e;
Therefore a small difference for the $yellow
which could be normalised and modified if needed.
It is an issue in frontend and backend. Your proposal looks good.
Now remains to decide if we use a new color directly for $warning
or modify the $yellow
in variables for each template.
I am not a specialist of a11y and css. I leave this to whoever is.
Hmm
It looks like Wave does not agree with https://webaim.org/resources/contrastchecker/ and firefox own contrast check
I modified here the text color for the Warning title to get black on the existing yellow instead of modifying the $yellow
I get
and contrastchecker agrees
Who should we believe?
Modifcations in the scss to get black text for warning are easy. Just create a new variable var(--alert-heading-text)
and adapt to warning type
.alert-heading {
display: flex;
flex-direction: column;
justify-content: center;
align-content: center;
padding: .8rem;
color: var(--alert-heading-text);
//color: rgba(255, 255, 255, .95);
background: var(--alert-accent-color, transparent);
}
.alert-link {
color: var(--success, inherit);
}
&[type="success"] {
--alert-accent-color: var(--success);
--alert-heading-text: rgba(255, 255, 255, .95);
}
&[type="info"] {
--alert-accent-color: var(--info);
--alert-heading-text: rgba(255, 255, 255, .95);
}
&[type="warning"] {
--alert-accent-color: var(--warning);
--alert-heading-text: #000;
}
&[type="danger"] {
--alert-accent-color: var(--danger);
--alert-heading-text: rgba(255, 255, 255, .95);
}
Thanks for reverting to my original code
Odd that Wave does not agree with https://webaim.org/resources/contrastchecker/ because they are both made by webaim
It is one of these things which drive me crazy
Odd that Wave does not agree with https://webaim.org/resources/contrastchecker/ because they are both made by webaim
Thanks for reverting to my original code
It is not really a revert as the code to get the present results is quite different.
Just something forgotten for the warning case.
Status | New | ⇒ | Closed |
Closed_Date | 0000-00-00 00:00:00 | ⇒ | 2020-08-16 05:19:47 |
Closed_By | ⇒ | infograf768 |
Are you referring to logging in to the admin or to the site?