mirror of
https://github.com/zombieFox/nightTab.git
synced 2025-06-30 06:11:09 +02:00
[design] improve link item name colour
This commit is contained in:
@ -1363,17 +1363,25 @@ var link = (function() {
|
|||||||
|
|
||||||
var shades = theme.mod.color.shades({
|
var shades = theme.mod.color.shades({
|
||||||
rgb: stagedLink.link.color.rgb,
|
rgb: stagedLink.link.color.rgb,
|
||||||
contrastNegative: 8,
|
contrastNegative: 7,
|
||||||
contrastPositive: 8
|
contrastPositive: 7
|
||||||
});
|
});
|
||||||
|
|
||||||
var rgb;
|
var rgb;
|
||||||
|
|
||||||
if (hsl.l <= 50) {
|
if (hsl.l <= 50) {
|
||||||
rgb = shades.positive["9"];
|
if (hsl.l > 30 && hsl.l <= 50 && hsl.h > 40 && hsl.h < 200) {
|
||||||
linkItemStyle.push("--theme-style-text: var(--theme-white);");
|
rgb = shades.negative["9"];
|
||||||
|
} else {
|
||||||
|
rgb = shades.positive["9"];
|
||||||
|
};
|
||||||
} else {
|
} else {
|
||||||
rgb = shades.negative["9"];
|
rgb = shades.negative["9"];
|
||||||
|
};
|
||||||
|
|
||||||
|
if (hsl.l <= 50) {
|
||||||
|
linkItemStyle.push("--theme-style-text: var(--theme-white);");
|
||||||
|
} else {
|
||||||
linkItemStyle.push("--theme-style-text: var(--theme-black);");
|
linkItemStyle.push("--theme-style-text: var(--theme-black);");
|
||||||
};
|
};
|
||||||
|
|
||||||
|
Reference in New Issue
Block a user