From afcfa44ec69a2d1e0c4e95094fecb9afa8b24b22 Mon Sep 17 00:00:00 2001 From: candifloss Date: Thu, 8 Aug 2024 21:13:44 +0530 Subject: [PATCH] Fixed scripts, Added panel icon widgets, placeholder icons, placeholder css --- eww/eww.css | 26 +++++++++++++- eww/eww.css.map | 2 +- eww/scss/colors/_glassy.scss | 25 +++++++++++-- eww/scss/panel/_panel_widgets.scss | 36 ++++++++++++++++++- eww/sh/actions/brightness/brit_dec.sh | 0 eww/sh/actions/brightness/brit_inc.sh | 0 eww/sh/actions/vol/vol_inc.sh | 0 eww/sh/actions/vol/vol_mute.sh | 0 eww/sh/osd/osd.sh | 0 eww/sh/unrelated/csswatch.sh | 0 eww/sh/values/battery.sh | 0 eww/sh/values/brightness.sh | 0 eww/sh/values/ip.sh | 0 eww/sh/values/volume.sh | 0 eww/sh/values/wifi.sh | 0 eww/yuck/panel/panel_widg_right.yuck | 12 ++++++- eww/yuck/panel/panel_widgs/panel_bat_ico.yuck | 11 ++++++ .../panel/panel_widgs/panel_brit_ico.yuck | 11 ++++++ .../panel/panel_widgs/panel_notif_ico.yuck | 12 +++++++ eww/yuck/panel/panel_widgs/panel_vol_ico.yuck | 11 ++++++ .../panel/panel_widgs/panel_wifi_ico.yuck | 12 +++++++ eww/yuck/vars/vars.yuck | 12 ++++--- 22 files changed, 159 insertions(+), 11 deletions(-) mode change 100644 => 100755 eww/sh/actions/brightness/brit_dec.sh mode change 100644 => 100755 eww/sh/actions/brightness/brit_inc.sh mode change 100644 => 100755 eww/sh/actions/vol/vol_inc.sh mode change 100644 => 100755 eww/sh/actions/vol/vol_mute.sh mode change 100644 => 100755 eww/sh/osd/osd.sh mode change 100644 => 100755 eww/sh/unrelated/csswatch.sh mode change 100644 => 100755 eww/sh/values/battery.sh mode change 100644 => 100755 eww/sh/values/brightness.sh mode change 100644 => 100755 eww/sh/values/ip.sh mode change 100644 => 100755 eww/sh/values/volume.sh mode change 100644 => 100755 eww/sh/values/wifi.sh create mode 100644 eww/yuck/panel/panel_widgs/panel_bat_ico.yuck create mode 100644 eww/yuck/panel/panel_widgs/panel_brit_ico.yuck create mode 100644 eww/yuck/panel/panel_widgs/panel_notif_ico.yuck create mode 100644 eww/yuck/panel/panel_widgs/panel_vol_ico.yuck create mode 100644 eww/yuck/panel/panel_widgs/panel_wifi_ico.yuck diff --git a/eww/eww.css b/eww/eww.css index 65a6ed4..a814e64 100644 --- a/eww/eww.css +++ b/eww/eww.css @@ -113,10 +113,34 @@ tooltip { /* Panel widgets */ .panel_mini_widg { - padding: 0 2px; border-radius: 2px; background-color: rgba(108, 110, 114, 0.74); } +.panel_mini_widg.panel_time { + padding: 0 2px; + background-color: rgba(29, 80, 69, 0.74); +} +.panel_mini_widg.panel_date { + padding: 0 2px; + background-color: rgba(109, 75, 173, 0.74); +} +.panel_mini_widg.panel_ico { + font-family: "icon-font"; + border-radius: 4px; + background-color: rgba(109, 75, 173, 0.74); +} +.panel_mini_widg.panel_bat_ico { + background-color: rgba(235, 92, 223, 0.74); +} +.panel_mini_widg.panel_vol_ico { + background-color: rgba(201, 243, 84, 0.74); +} +.panel_mini_widg.panel_brit_ico { + background-color: rgba(211, 80, 76, 0.74); +} +.panel_mini_widg.panel_wifi_ico { + background-color: rgba(76, 231, 154, 0.74); +} /* Panel */ .panel_widg { diff --git a/eww/eww.css.map b/eww/eww.css.map index 5f7c559..edda543 100644 --- a/eww/eww.css.map +++ b/eww/eww.css.map @@ -1 +1 @@ -{"version":3,"sourceRoot":"","sources":["scss/common/_common.scss","scss/tooltip/_tooltip.scss","scss/colors/_glassy.scss","scss/osd/_osd.scss","scss/osd/_bat.scss","scss/osd/_bri.scss","scss/osd/_vol.scss","scss/dock/_dock.scss","scss/panel/_panel_widgets.scss","scss/panel/_panel.scss"],"names":[],"mappings":"AAAA;AACA;EACI;;;ACFJ;AAGA;EACI;EACA,kBCDS;EDET,OCDY;;;ACDhB;AAKI;EACH,eAJI;EAKJ,kBDHY;;ACMT;EAEH;EACA,kBDNc;;ACOd;EAEI,eAdA;;AAgBJ;EAEI;;AClBA;EACH,kBFMyB;;AEJtB;EACH,kBFI6B;;AEF1B;EACH,kBFE0B;;AEAvB;EACH;;AAEG;EACH,kBFF0B;;AEIvB;EACH,kBFJsB;;AEMnB;EACH,kBFNwB;;AEQrB;EACH,kBFRuB;;AEUpB;EACH,kBFVuB;;AGfpB;EACH,kBHyBsB;;AGvBnB;EACH,kBHuBsB;;AGrBnB;EACH,kBHqBuB;;AGnBpB;EACH,kBHmBuB;;AGjBpB;EACH,kBHiBuB;;AI9BpB;EACH,kBJgBsB;;AIdnB;EACH,kBJesB;;AIbnB;EACH,kBJasB;;AIXnB;EACH,kBJWuB;;AITpB;EACH,kBJSuB;;AIPpB;EACH,kBJOuB;;ACErB;EAEH,cA3BI;EA4BJ;EACA;;AAGG;EAEH;EACA;EACA;;;AIzCD;AAEA;EACI;EACA,kBLoCU;;AKnCV;EACI;EACA;EACA;EACA,OLiCc;;AK/Bd;EACI,kBL6BM;;;AMzClB;AAEA;EACI;EACA;EACA,kBN4CqB;;;AOhDzB;AAEA;EACI,kBPyCW;;AOvCX;EACI,kBPuCa;;AOrCjB;EACI,kBPqCW;;AOnCf;EACI,kBPmCY","file":"eww.css"} \ No newline at end of file +{"version":3,"sourceRoot":"","sources":["scss/common/_common.scss","scss/tooltip/_tooltip.scss","scss/colors/_glassy.scss","scss/osd/_osd.scss","scss/osd/_bat.scss","scss/osd/_bri.scss","scss/osd/_vol.scss","scss/dock/_dock.scss","scss/panel/_panel_widgets.scss","scss/panel/_panel.scss"],"names":[],"mappings":"AAAA;AACA;EACI;;;ACFJ;AAGA;EACI;EACA,kBCDS;EDET,OCDY;;;ACDhB;AAKI;EACH,eAJI;EAKJ,kBDHY;;ACMT;EAEH;EACA,kBDNc;;ACOd;EAEI,eAdA;;AAgBJ;EAEI;;AClBA;EACH,kBFMyB;;AEJtB;EACH,kBFI6B;;AEF1B;EACH,kBFE0B;;AEAvB;EACH;;AAEG;EACH,kBFF0B;;AEIvB;EACH,kBFJsB;;AEMnB;EACH,kBFNwB;;AEQrB;EACH,kBFRuB;;AEUpB;EACH,kBFVuB;;AGfpB;EACH,kBHyBsB;;AGvBnB;EACH,kBHuBsB;;AGrBnB;EACH,kBHqBuB;;AGnBpB;EACH,kBHmBuB;;AGjBpB;EACH,kBHiBuB;;AI9BpB;EACH,kBJgBsB;;AIdnB;EACH,kBJesB;;AIbnB;EACH,kBJasB;;AIXnB;EACH,kBJWuB;;AITpB;EACH,kBJSuB;;AIPpB;EACH,kBJOuB;;ACErB;EAEH,cA3BI;EA4BJ;EACA;;AAGG;EAEH;EACA;EACA;;;AIzCD;AAEA;EACI;EACA,kBLoCU;;AKnCV;EACI;EACA;EACA;EACA,OLiCc;;AK/Bd;EACI,kBL6BM;;;AMzClB;AAEA;EACI;EACA,kBNgDqB;;AM9CrB;EACI;EACA,kBN+CY;;AM5ChB;EACI;EACA,kBN4CY;;AMxChB;EACI;EACA;EACA,kBNqCY;;AMjChB;EACI,kBNsCe;;AMnCnB;EACI,kBNoCe;;AMjCnB;EACI,kBNkCgB;;AM/BpB;EACI,kBNgCgB;;;AOpExB;AAEA;EACI,kBPyCW;;AOvCX;EACI,kBPwCa;;AOtCjB;EACI,kBPsCW;;AOpCf;EACI,kBPoCY","file":"eww.css"} \ No newline at end of file diff --git a/eww/scss/colors/_glassy.scss b/eww/scss/colors/_glassy.scss index 3c863d7..9e408b2 100644 --- a/eww/scss/colors/_glassy.scss +++ b/eww/scss/colors/_glassy.scss @@ -8,7 +8,7 @@ $tooltip_color: rgba(255, 255, 255, 1); //OSD $osd_bg_col: rgba(128, 128, 128, 0.5); $osd_ico_col: rgba(255, 255, 255, 1); -$osd_val_col: rgba(255, 255, 255, 1); +$osd_val_col: $osd_ico_col; $osd_fill_col: rgba( 18, 122, 155, 1); $osd_fill_col_bat_unknown: rgba(218, 255, 69, 1); @@ -45,7 +45,28 @@ $dock_ico_fg_def_col: rgba(255, 255, 255, 1); //Panel $panel_bg_col: rgba(128, 128, 128, 0.5); +$panel_fg_col: rgb(255, 255, 255); $panel_right_bg_col: rgba(221, 128, 128, 0.856); $panel_cen_bg_col: rgba(209, 188, 95, 0.849); $panel_left_bg_col: rgba(96, 211, 196, 0.863); -$panel_mini_widg_bg_col: rgba(108, 110, 114, 0.74); + +//Panel mini widgets +$panel_mini_widg_bg_col: rgba(108, 110, 114, 0.74); //Default +$panel_mini_widg_fg_col: $panel_fg_col; + +$panel_time_bg_col: rgba(29, 80, 69, 0.74); //Time +$panel_time_text_col: $panel_mini_widg_fg_col; +$panel_date_bg_col: rgba(109, 75, 173, 0.74); //Date +$panel_date_text_col: $panel_mini_widg_fg_col; + +$panel_ico_bg_col: $panel_mini_widg_bg_col; //Panel icons, default +$panel_ico_fg_col: $panel_mini_widg_fg_col; + +$panel_ico_bat_bg_col: rgba(235, 92, 223, 0.74); //Battery +$panel_ico_bat_text_col: $panel_ico_fg_col; +$panel_ico_vol_bg_col: rgba(201, 243, 84, 0.74); //Volume +$panel_ico_vol_text_col: $panel_ico_fg_col; +$panel_ico_brit_bg_col: rgba(211, 80, 76, 0.74); //Brightness +$panel_ico_brit_text_col: $panel_ico_fg_col; +$panel_ico_wifi_bg_col: rgba(76, 231, 154, 0.74); //Wifi +$panel_ico_wifi_text_col: $panel_ico_fg_col; diff --git a/eww/scss/panel/_panel_widgets.scss b/eww/scss/panel/_panel_widgets.scss index 8d9e77d..59a4339 100644 --- a/eww/scss/panel/_panel_widgets.scss +++ b/eww/scss/panel/_panel_widgets.scss @@ -2,7 +2,41 @@ /* Panel widgets */ .panel_mini_widg { - padding: 0 2px; border-radius: 2px; background-color: $panel_mini_widg_bg_col; + + &.panel_time { + padding: 0 2px; + background-color: $panel_time_bg_col; + //color: $panel_time_text_col; + } + &.panel_date { + padding: 0 2px; + background-color: $panel_date_bg_col; + //color: $panel_date_text_col; + } + + &.panel_ico { + font-family: "icon-font"; + border-radius: 4px; + background-color: $panel_date_bg_col; + //color: $panel_date_text_col; + } + + &.panel_bat_ico { + background-color: $panel_ico_bat_bg_col; + //color: $panel_ico_bat_text_col; + } + &.panel_vol_ico { + background-color: $panel_ico_vol_bg_col; + //color: $panel_ico_vol_text_col; + } + &.panel_brit_ico { + background-color: $panel_ico_brit_bg_col; + //color: $panel_ico_brit_text_col; + } + &.panel_wifi_ico { + background-color: $panel_ico_wifi_bg_col; + //color: $panel_ico_wifi_text_col; + } } \ No newline at end of file diff --git a/eww/sh/actions/brightness/brit_dec.sh b/eww/sh/actions/brightness/brit_dec.sh old mode 100644 new mode 100755 diff --git a/eww/sh/actions/brightness/brit_inc.sh b/eww/sh/actions/brightness/brit_inc.sh old mode 100644 new mode 100755 diff --git a/eww/sh/actions/vol/vol_inc.sh b/eww/sh/actions/vol/vol_inc.sh old mode 100644 new mode 100755 diff --git a/eww/sh/actions/vol/vol_mute.sh b/eww/sh/actions/vol/vol_mute.sh old mode 100644 new mode 100755 diff --git a/eww/sh/osd/osd.sh b/eww/sh/osd/osd.sh old mode 100644 new mode 100755 diff --git a/eww/sh/unrelated/csswatch.sh b/eww/sh/unrelated/csswatch.sh old mode 100644 new mode 100755 diff --git a/eww/sh/values/battery.sh b/eww/sh/values/battery.sh old mode 100644 new mode 100755 diff --git a/eww/sh/values/brightness.sh b/eww/sh/values/brightness.sh old mode 100644 new mode 100755 diff --git a/eww/sh/values/ip.sh b/eww/sh/values/ip.sh old mode 100644 new mode 100755 diff --git a/eww/sh/values/volume.sh b/eww/sh/values/volume.sh old mode 100644 new mode 100755 diff --git a/eww/sh/values/wifi.sh b/eww/sh/values/wifi.sh old mode 100644 new mode 100755 diff --git a/eww/yuck/panel/panel_widg_right.yuck b/eww/yuck/panel/panel_widg_right.yuck index 8b89c7b..d11d72b 100644 --- a/eww/yuck/panel/panel_widg_right.yuck +++ b/eww/yuck/panel/panel_widg_right.yuck @@ -1,5 +1,10 @@ (include "yuck/panel/panel_widgs/panel_clock.yuck") (include "yuck/panel/panel_widgs/panel_date.yuck") +(include "yuck/panel/panel_widgs/panel_vol_ico.yuck") +(include "yuck/panel/panel_widgs/panel_bat_ico.yuck") +(include "yuck/panel/panel_widgs/panel_brit_ico.yuck") +(include "yuck/panel/panel_widgs/panel_wifi_ico.yuck") +(include "yuck/panel/panel_widgs/panel_notif_ico.yuck") (defwidget panel_right [h] (box @@ -9,10 +14,15 @@ :halign "end" :valign "end" :height "${h}" - ;:width 300 + ;:width 400 ;:active false ;Widgets: + (panel_notif_ico :h "${h}") + (panel_wifi_ico :h "${h}") + (panel_brit_ico :h "${h}") + (panel_vol_ico :h "${h}") + (panel_bat_ico :h "${h}") (panel_date :h "${h}") (panel_time :h "${h}") ) diff --git a/eww/yuck/panel/panel_widgs/panel_bat_ico.yuck b/eww/yuck/panel/panel_widgs/panel_bat_ico.yuck new file mode 100644 index 0000000..dadcc7b --- /dev/null +++ b/eww/yuck/panel/panel_widgs/panel_bat_ico.yuck @@ -0,0 +1,11 @@ +(defwidget panel_bat_ico [h] + (label + :class "panel_mini_widg panel_ico panel_bat_ico" + :halign "end" + :valign "end" + :height "${h}" + :width "${h}" + ;:active true + :text "${battery.icon}" + ) +) \ No newline at end of file diff --git a/eww/yuck/panel/panel_widgs/panel_brit_ico.yuck b/eww/yuck/panel/panel_widgs/panel_brit_ico.yuck new file mode 100644 index 0000000..30cddfe --- /dev/null +++ b/eww/yuck/panel/panel_widgs/panel_brit_ico.yuck @@ -0,0 +1,11 @@ +(defwidget panel_brit_ico [h] + (label + :class "panel_mini_widg panel_ico panel_brit_ico" + :halign "end" + :valign "end" + :height "${h}" + :width "${h}" + ;:active true + :text "${brit.icon}" + ) +) \ No newline at end of file diff --git a/eww/yuck/panel/panel_widgs/panel_notif_ico.yuck b/eww/yuck/panel/panel_widgs/panel_notif_ico.yuck new file mode 100644 index 0000000..1a3cc55 --- /dev/null +++ b/eww/yuck/panel/panel_widgs/panel_notif_ico.yuck @@ -0,0 +1,12 @@ +(defwidget panel_notif_ico [h] + (label + :class "panel_mini_widg panel_ico panel_notif_ico" + :halign "end" + :valign "end" + :height "${h}" + :width "${h}" + ;:active true + :text "" + :tooltip "No notifications" + ) +) \ No newline at end of file diff --git a/eww/yuck/panel/panel_widgs/panel_vol_ico.yuck b/eww/yuck/panel/panel_widgs/panel_vol_ico.yuck new file mode 100644 index 0000000..2792f46 --- /dev/null +++ b/eww/yuck/panel/panel_widgs/panel_vol_ico.yuck @@ -0,0 +1,11 @@ +(defwidget panel_vol_ico [h] + (label + :class "panel_mini_widg panel_ico panel_vol_ico" + :halign "end" + :valign "end" + :height "${h}" + :width "${h}" + ;:active true + :text "${vol.icon}" + ) +) \ No newline at end of file diff --git a/eww/yuck/panel/panel_widgs/panel_wifi_ico.yuck b/eww/yuck/panel/panel_widgs/panel_wifi_ico.yuck new file mode 100644 index 0000000..aaa62d0 --- /dev/null +++ b/eww/yuck/panel/panel_widgs/panel_wifi_ico.yuck @@ -0,0 +1,12 @@ +(defwidget panel_wifi_ico [h] + (label + :class "panel_mini_widg panel_ico panel_wifi_ico" + :halign "end" + :valign "end" + :height "${h}" + :width "${h}" + ;:active true + :text "${wifi.icon}" + :tooltip "${wifi.name}\n${wifi.speed}" + ) +) \ No newline at end of file diff --git a/eww/yuck/vars/vars.yuck b/eww/yuck/vars/vars.yuck index b2079e0..fc0d17e 100644 --- a/eww/yuck/vars/vars.yuck +++ b/eww/yuck/vars/vars.yuck @@ -3,30 +3,32 @@ ;Network (defpoll wlan_ip :interval "1m" - `/home/lcm/.config/eww/sh/values/ip.sh` + :initial "{\"name\":\"Not connected\",\"speed\":\"0 Mbit/s\",\"bars\":\"0\",\"icon\":\"\"}" + `sh/values/ip.sh` ) (defpoll wifi :interval "1m" - `/home/lcm/.config/eww/sh/values/wifi.sh` + :initial "{\"name\":\"Not connected\",\"speed\":\"0 Mbit/s\",\"bars\":\"0\",\"icon\":\"\"}" + `sh/values/wifi.sh` ) ;Volume (defpoll vol :interval "300ms" :initial "{\"level\":\"0\",\"status\":\"empty\",\"icon\":\"\"}" - `/home/lcm/.config/eww/sh/values/volume.sh` + `sh/values/volume.sh` ) ;Brightness (defpoll brit :interval "300ms" :initial "{\"level\":\"0\",\"status\":\"empty\",\"icon\":\"\"}" - `/home/lcm/.config/eww/sh/values/brightness.sh` + `sh/values/brightness.sh` ) ;Battery (defpoll battery :interval "300ms" :initial "{\"level\":\"0\",\"status\":\"empty\",\"icon\":\"\"}" - `/home/lcm/.config/eww/sh/values/battery.sh` + `sh/values/battery.sh` ) \ No newline at end of file