Hi, I'm working on a new mastodon theme and suffering from a problem of visual accessibility.
The problem is that user re-definable color variables defined in variables.scss
are too few so we can only create very simple colored themes. e.g. I think that It would be very difficult if we try to make "white(=opposing to default)" color theme.
Does anybody have a good idea?
I think that this problem can be solved by adding variables to some extent with mastodon. For example, it is strange that text color has $ui-base-color
, is not it?
I think this is a structural defect.
Text as text color, button as button color, background as independent color, I think that each should be separated.
May be you should have a look to this (light) theme developed by Mathieu Dubois.
I used it as a base to do my own (Cafe) theme for my own instance. Some screenshots here
But I agree that the color variables are not enough detailed to do it properly.
This is a huge accessibility issue. As of today, there is a too few variables to make a truly accessible theme.
For example, $ui-primary-color
, which is used both as a background and a text color, needs to be:
$ui-base-color
background;When you put all of this constraints together, for each variables, you can't have a theme that respect the contrast recommendations every time.
I don't know what the proper fix would be, but I guess we need to add more variables.
This issue should be tagged with "accessibility" and should probably be at least of medium priority.
Have the recent merged PRs resolved this sufficiently?
Most helpful comment
I think that this problem can be solved by adding variables to some extent with mastodon. For example, it is strange that text color has
$ui-base-color
, is not it?I think this is a structural defect.
Text as text color, button as button color, background as independent color, I think that each should be separated.