diff options
Diffstat (limited to '.local/share/mode/plug.d/50_accent')
-rw-r--r-- | .local/share/mode/plug.d/50_accent | 16 |
1 files changed, 16 insertions, 0 deletions
diff --git a/.local/share/mode/plug.d/50_accent b/.local/share/mode/plug.d/50_accent new file mode 100644 index 0000000..6e0aa73 --- /dev/null +++ b/.local/share/mode/plug.d/50_accent @@ -0,0 +1,16 @@ +#!/bin/sh +# create accent color differently for dark/light mode + +# do not generate accent color if already explicitly defined by theme +[ -n "$accent" ] && return + +[ "$mode" == "light" ] && { + accent="$color15" + accent_text="$color0" +} +[ "$mode" == "dark" ] && { + accent="$(mix_rgb $bg $color0 0.5)" + accent_text="$fg" +} + +export accent accent_text |