style: make transparency same for light/dark
This commit is contained in:
parent
e53c517829
commit
d77c324fd5
1 changed files with 1 additions and 2 deletions
3
app.tsx
3
app.tsx
|
|
@ -23,8 +23,7 @@ const isLayer = (name: string) =>
|
||||||
|
|
||||||
const applyTransparency = (name: string, hex: string) => {
|
const applyTransparency = (name: string, hex: string) => {
|
||||||
if (style.transparency.get() === "off" || !isLayer(name)) return hex;
|
if (style.transparency.get() === "off" || !isLayer(name)) return hex;
|
||||||
let amount = style.transparency.get() === "high" ? 0.58 : 0.78;
|
const amount = style.transparency.get() === "high" ? 0.58 : 0.78;
|
||||||
if (Palette.get_default().mode === "light") amount = style.transparency.get() === "high" ? 0.53 : 0.63;
|
|
||||||
return `color.change(${hex}, $alpha: ${amount})`;
|
return `color.change(${hex}, $alpha: ${amount})`;
|
||||||
};
|
};
|
||||||
|
|
||||||
|
|
|
||||||
Loading…
Add table
Reference in a new issue