feat: declarative vesktop theming

This commit is contained in:
Artur Manuel 2024-12-16 21:10:12 +00:00
commit 50ab2b94b2
6 changed files with 10 additions and 137 deletions

View file

@ -1,22 +0,0 @@
@theme "~/.config/rofi/gruvbox-material.rasi"
configuration {
font: "Monospace 10";
drun {
display-name: "";
}
run {
display-name: "";
}
window {
display-name: "";
}
timeout {
delay: 10;
action: "kb-cancel";
}
}

View file

@ -1,108 +0,0 @@
/**
* Gruvbox Material Rofi theme
* Color palette copied from https://github.com/sainnhe/gruvbox-material
* https://github.com/hiimsergey/rofi-gruvbox-material
*/
* {
// Taken from "Hard" variant
background: #282828; // bg_statusline1
element: #32302f; // bg_statusline2
selection: #a89984; // grey2
text: #eee0b7; // bg4 (light mode)
red: #ea6962; // red
yellow: #d8a657; // yellow
reddark: #c14a4a; // red (light mode)
yellowdark: #b47109; // yellow (light mode)
background-color: transparent;
}
window {
height: 600;
width: 600;
border-radius: 10;
}
mainbox {
spacing: 0;
children: [inputbar, message, listview];
}
inputbar {
color: @text;
padding: 14;
background-color: @background;
}
message {
padding: 10;
background-color: @selection;
}
listview {
padding: 8;
border-radius: 0 0 10 10;
border: 2 2 2 2;
border-color: @background;
background-color: @background;
dynamic: false;
}
textbox {
text-color: @text;
}
error-message {
border: 20 20 20 20;
}
entry, prompt, case-indicator {
text-color: inherit;
}
prompt {
margin: 0 10 0 0;
}
element {
padding: 5;
vertical-align: 0.5;
border-radius: 10;
text-color: @text;
background-color: @element;
}
element.selected.normal {
background-color: @selection;
}
element.alternate.normal {
background-color: inherit;
}
element.normal.active, element.alternate.active {
background-color: @yellow;
}
element.selected.active {
background-color: @yellowdark;
}
element.normal.urgent, element.alternate.urgent {
background-color: @red;
}
element.selected.urgent {
background-color: @reddark;
}
element-text, element-icon {
size: 40;
margin: 0 10 0 0;
vertical-align: 0.5;
background-color: inherit;
text-color: @text;
}

View file

@ -0,0 +1,3 @@
:root {
--font: "Monospace";
}

View file

@ -9,7 +9,7 @@
"format": "{player_icon} {dynamic}",
"format-paused": "{status_icon} <i>{dynamic}</i>",
"interval": 1,
"dynamic-length": 52,
"dynamic-len": 52,
"player-icons": {
"default": "▶",
"mpv": "🎵",