setting to disable role colors
This commit is contained in:
@@ -1630,6 +1630,18 @@ class Localuser {
|
||||
};
|
||||
genSecurity();
|
||||
}
|
||||
{
|
||||
const accessibility = settings.addButton(I18n.accessibility.name());
|
||||
accessibility.addCheckboxInput(
|
||||
I18n.accessibility.roleColors(),
|
||||
(t) => {
|
||||
this.perminfo.user.disableColors = !t;
|
||||
},
|
||||
{
|
||||
initState: !this.perminfo.user.disableColors,
|
||||
},
|
||||
);
|
||||
}
|
||||
{
|
||||
const connections = settings.addButton(I18n.getTranslation("localuser.connections"));
|
||||
const connectionContainer = document.createElement("div");
|
||||
|
@@ -442,6 +442,9 @@ class Member extends SnowFlake {
|
||||
return false;
|
||||
}
|
||||
getColor() {
|
||||
if (!this.localuser.perminfo.user.disableColors) {
|
||||
return "";
|
||||
}
|
||||
for (const thing of this.roles) {
|
||||
const color = thing.getColor();
|
||||
if (color) {
|
||||
|
@@ -145,6 +145,10 @@
|
||||
"noMessages": "No messages appear to be here, be the first to say something!",
|
||||
"blankMessage": "Blank Message",
|
||||
"spoiler": "Spoiler",
|
||||
"accessibility": {
|
||||
"name": "Accessibility",
|
||||
"roleColors": "Disable role colors"
|
||||
},
|
||||
"channel": {
|
||||
"name": "Channel",
|
||||
"copyId": "Copy channel id",
|
||||
|
Reference in New Issue
Block a user