feat: structure for eww dots

This commit is contained in:
hesam-init 2024-06-28 13:16:38 +03:30
parent b1175b0018
commit d8f781cb27
58 changed files with 445 additions and 445 deletions

View file

Before

Width:  |  Height:  |  Size: 85 KiB

After

Width:  |  Height:  |  Size: 85 KiB

View file

Before

Width:  |  Height:  |  Size: 18 KiB

After

Width:  |  Height:  |  Size: 18 KiB

View file

Before

Width:  |  Height:  |  Size: 256 KiB

After

Width:  |  Height:  |  Size: 256 KiB

View file

Before

Width:  |  Height:  |  Size: 251 KiB

After

Width:  |  Height:  |  Size: 251 KiB

View file

Before

Width:  |  Height:  |  Size: 147 KiB

After

Width:  |  Height:  |  Size: 147 KiB

View file

Before

Width:  |  Height:  |  Size: 9.4 KiB

After

Width:  |  Height:  |  Size: 9.4 KiB

View file

Before

Width:  |  Height:  |  Size: 7.1 KiB

After

Width:  |  Height:  |  Size: 7.1 KiB

View file

Before

Width:  |  Height:  |  Size: 9.6 KiB

After

Width:  |  Height:  |  Size: 9.6 KiB

View file

Before

Width:  |  Height:  |  Size: 1.4 KiB

After

Width:  |  Height:  |  Size: 1.4 KiB

View file

Before

Width:  |  Height:  |  Size: 32 KiB

After

Width:  |  Height:  |  Size: 32 KiB

View file

Before

Width:  |  Height:  |  Size: 26 KiB

After

Width:  |  Height:  |  Size: 26 KiB

View file

Before

Width:  |  Height:  |  Size: 5.3 KiB

After

Width:  |  Height:  |  Size: 5.3 KiB

View file

Before

Width:  |  Height:  |  Size: 276 B

After

Width:  |  Height:  |  Size: 276 B

View file

Before

Width:  |  Height:  |  Size: 464 B

After

Width:  |  Height:  |  Size: 464 B

View file

Before

Width:  |  Height:  |  Size: 325 B

After

Width:  |  Height:  |  Size: 325 B

View file

Before

Width:  |  Height:  |  Size: 470 B

After

Width:  |  Height:  |  Size: 470 B

View file

Before

Width:  |  Height:  |  Size: 523 B

After

Width:  |  Height:  |  Size: 523 B

View file

Before

Width:  |  Height:  |  Size: 1.5 KiB

After

Width:  |  Height:  |  Size: 1.5 KiB

View file

Before

Width:  |  Height:  |  Size: 1.4 KiB

After

Width:  |  Height:  |  Size: 1.4 KiB

View file

Before

Width:  |  Height:  |  Size: 949 B

After

Width:  |  Height:  |  Size: 949 B

View file

Before

Width:  |  Height:  |  Size: 561 B

After

Width:  |  Height:  |  Size: 561 B

View file

Before

Width:  |  Height:  |  Size: 1.2 KiB

After

Width:  |  Height:  |  Size: 1.2 KiB

View file

Before

Width:  |  Height:  |  Size: 378 B

After

Width:  |  Height:  |  Size: 378 B

View file

@ -1 +1 @@
@import "./themes/everblush.scss"; @import "./assets/themes/everblush.scss";

View file

@ -1,20 +0,0 @@
.heading {
font-size: 25px;
color: $accent;
margin: 5px;
}
.dmpdcontrol {
margin: 10px;
}
.dmpdcontrol label {
font-size: 20px;
margin: 0px 8px;
}
.dicons label {
font-size: 25px;
margin-right: 6px;
}

View file

@ -1,11 +1,11 @@
@import "./colors.scss"; @import "./colors.scss";
@import "./src/bar/styles.scss"; @import "./src/sidebar/styles.scss";
// @import "./bottom_bar/bar.scss"; @import "./src/control-panel/styles.scss";
@import "./control_panel/control_panel.scss"; @import "./src/dashboard/styles.scss";
@import "./dashboard/dashboard.scss"; @import "./src/dock/styles.scss";
@import "./dock/dock.scss"; @import "./src/desktop/styles.scss";
@import "./desktop/desktop.scss";
@import "./notification/notification.scss"; @import "./notification/notification.scss";
// @import "./src/bottom-bar/styles.scss";
* { * {
all: unset; all: unset;
@ -110,7 +110,7 @@ checkbutton:checked {
} }
entry { entry {
// image: url('./image/screenshot.png'); // image: url('./assets/image/screenshot.png');
padding: 5px; padding: 5px;
margin: 5px; margin: 5px;
border-radius: 5px; border-radius: 5px;

View file

@ -1,48 +1,5 @@
(include "./src/utils/_revealer.yuck") (include "./src/utils/_revealer.yuck")
(include "./src/_pollers.yuck") (include "./src/_definitions.yuck")
(include "./src/_variables.yuck")
(deflisten workspacejson
:initial '[{"focused": true, "empty": false, "name": 1}, {"focused": false, "empty": true, "name": 2}, {"focused": false, "empty": true, "name": 3}, {"focused": false, "empty": true, "name": 4}, {"focused": false, "empty": true, "name": 5}]'
"./scripts/workspace.py")
;; used mainly in control panel and dashboard
(defpoll hostname :initial "idk" :interval "24h" 'echo "$(whoami)"')
(defpoll uptime :initial "idk" :interval "1m" "uptime -p")
(defpoll weatherjson
:initial '{
"FeelsLikeC": "0",
"FeelsLikeF": "0",
"cloudcover": "0",
"humidity": "0",
"localObsDateTime": "2000-00-00 07:27 AM",
"observation_time": "07:27 AM",
"precipInches": "0.0",
"precipMM": "0.0",
"pressure": "0",
"pressureInches": "0",
"temp_C": "0",
"temp_F": "0",
"uvIndex": "0",
"visibility": "0",
"visibilityMiles": "0",
"weatherCode": "727",
"weatherDesc": [{"value": "Idk"}],
"weatherIconUrl": [{"value": ""}],
"winddir16Point": "",
"winddirDegree": "0",
"windspeedKmph": "0",
"windspeedMiles": "0",
"icon": "idk",
"hourly": []
}'
:interval "1h"
:run-while revealcontrolpanel
"./scripts/weather.py")
(defpoll datehour :initial "12" :interval "30m" "date +'%H'")
(defpoll notesc :interval "2s" :run-while reveal4 "cat -s ~/Documents/fuck.txt")
(defpoll quotejson :interval "1h" `./scripts/quote.py`)
(deflisten timerdis `./scripts/timer.py subscribe`)
;; dock ;; dock
(deflisten tasksjson :initial "[]" "./scripts/tasklist.py") (deflisten tasksjson :initial "[]" "./scripts/tasklist.py")
@ -59,33 +16,9 @@
(defvar borderpixel 2) (defvar borderpixel 2)
(defvar caffeine false) (defvar caffeine false)
; Notifications
(deflisten notifications :initial '{
"count": 0,
"dnd": false,
"notifications": [],
"popups": []
}'
"./scripts/notifCatch"
)
;; cava pipe ("borrowed from tail-r") ;; cava pipe ("borrowed from tail-r")
;; (deflisten cavajson :initial "[]" "./scripts/cava_pipe.sh") ;; (deflisten cavajson :initial "[]" "./scripts/cava_pipe.sh")
;; playerctl
(deflisten psong "playerctl metadata --format '{{ title }}' -F")
(deflisten partist "playerctl metadata --format '{{ artist }}' -F")
(deflisten pcover "./scripts/pollcover.sh")
(deflisten pstatus "playerctl status -F")
(deflisten ptime
:initial '{
"position": 0,
"duration": 0,
"readable": "0:00"
}'
"playerctl -F metadata -f '{ \"position\": {{position/1000000}}, \"duration\": {{mpris:length/1000000}}, \"readable\": \"{{duration(position)}}/{{duration(mpris:length)}}\" }'")
;; (deflisten pside "playerctl -F metadata -f '{ \"volume\": {{volume*100}}, \"shuffle\": \"{{shuffle}}\", \"loop\": \"{{loop}}\" }'")
;; wallpaper thing ;; wallpaper thing
(defvar wallpapers "[]") (defvar wallpapers "[]")
@ -94,11 +27,18 @@
(defpoll theme :interval "24h" "./scripts/toggletheme") (defpoll theme :interval "24h" "./scripts/toggletheme")
(include "./src/bar/main.yuck") ;; (include "./src/bottom_bar/bar.yuck")
;; (include "./bottom_bar/bar.yuck") (include "./src/sidebar/main.yuck")
(include "./control_panel/control_panel.yuck")
(include "./dashboard/dashboard.yuck") (include "./src/control-panel/main.yuck")
(include "./dock/dock.yuck") (include "./src/control-panel/windowswitcher.yuck")
(include "./desktop/desktop.yuck")
(include "./src/wallpapers/main.yuck")
(include "./src/dashboard/main.yuck")
(include "./src/dock/main.yuck")
(include "./src/desktop/main.yuck")
(include "./notification/notification.yuck") (include "./notification/notification.yuck")
(include "./wallpapers/wallpapers.yuck")

View file

@ -1,11 +1,11 @@
(defwindow notifypopup (defwindow notifypopup
:geometry (geometry :geometry (geometry
:x 0 :x 0
:y 0 :y 0
:width 480 :width 480
:height 0 :height 0
:anchor "top right") :anchor "top right")
:stacking "overlay" :stacking "overlay"
:monitor 0 :monitor 0
(revealer (revealer
@ -13,78 +13,78 @@
:transition "slidedown" :transition "slidedown"
(box (box
:orientation "v" :orientation "v"
:space-evenly false :space-evenly false
:spacing 5 :spacing 5
(for noti in {notifications.popups} (for noti in {notifications.popups}
(singlenotif :noti noti :initial true))))) (singlenotif :noti noti :initial true)))))
(defwidget singlenotif [noti initial] (defwidget singlenotif [noti initial]
(box (box
:orientation "v" :orientation "v"
:class "${initial ? 'popup' : 'notifbox'}" :class "${initial ? 'popup' : 'notifbox'}"
:space-evenly false :space-evenly false
(centerbox (centerbox
:orientation "h" :orientation "h"
:class "notifbar" :class "notifbar"
(image :halign "start" :image-width 30 :image-height 30 :path {noti.icon != "null" ? noti.icon : "./image/idk.svg"}) (image :halign "start" :image-width 30 :image-height 30 :path {noti.icon != "null" ? noti.icon : "./assets/image/idk.svg"})
(scroll (scroll
:halign "center" :halign "center"
:valign "center" :valign "center"
:hexpand true :hexpand true
:hscroll true :hscroll true
:vscroll false :vscroll false
:width 200 :width 200
(label (label
:class "notiflabel" :class "notiflabel"
:text {noti.app})) :text {noti.app}))
(button (button
:halign "end" :halign "end"
:onclick "./scripts/notifManage --close ${noti.id}" :onclick "./scripts/notifManage --close ${noti.id}"
(label (label
:class "notifclose" :class "notifclose"
:text ""))) :text "")))
(box (box
:orientation "h" :orientation "h"
:halign "fill" :halign "fill"
:height 80 :height 80
:space-evenly false :space-evenly false
:spacing 10 :spacing 10
(image :image-width 80 :image-height 80 :visible {noti.image != "null"} :path {noti.image != "null" ? noti.image : "./image/idk.svg"}) (image :image-width 80 :image-height 80 :visible {noti.image != "null"} :path {noti.image != "null" ? noti.image : "./assets/image/idk.svg"})
(button (button
:onclick "./scripts/notifManage --dismiss ${noti.id}" :onclick "./scripts/notifManage --dismiss ${noti.id}"
:onrightclick "./scripts/notifManage --close ${noti.id}" :onrightclick "./scripts/notifManage --close ${noti.id}"
:tooltip "${noti.time}" :tooltip "${noti.time}"
:hexpand true :hexpand true
:vexpand true :vexpand true
(box (box
:orientation "v" :orientation "v"
:space-evenly false :space-evenly false
:valign "center" :valign "center"
(scroll (scroll
:hscroll true :hscroll true
:vscroll false :vscroll false
:hexpand true :hexpand true
(label (label
:class "notiftitle" :class "notiftitle"
:text {noti.summary})) :text {noti.summary}))
(scroll (scroll
:hscroll true :hscroll true
:vscroll false :vscroll false
:hexpand true :hexpand true
(label (label
:class "notifbody" :class "notifbody"
:visible {noti.body != "null"} :visible {noti.body != "null"}
:text {noti.body}))))) :text {noti.body})))))
(box (box
:orientation "h" :orientation "h"
(for action in {noti.actions} (for action in {noti.actions}
(button (button
:onclick "./scripts/notifManage --action ${noti.id} ${action[0]} && ./scripts/notifManage --close ${noti.id}" :onclick "./scripts/notifManage --action ${noti.id} ${action[0]} && ./scripts/notifManage --close ${noti.id}"
(label (label
:class "notifactions" :class "notifactions"
:text {action[1]})) :text {action[1]}))
)))) ))))

View file

@ -0,0 +1,97 @@
(defvar revealVolume false)
(defvar revealMicrophone false)
(defvar revealBrightness false)
(defvar revealControlpanel false)
(defvar reveal1 false)
(defvar reveal2 false)
(defvar reveal3 false)
(defvar reveal4 false)
(defvar reveal5 false)
(defvar reveal6 false)
(defvar revealweather false)
(defvar revealsystray false)
; Workspaces
(defvar show_no_of_windows false)
(deflisten workspacesjson :initial "[]" "./scripts/workspaces get-all-workspaces")
(defpoll current_workspace :initial "0" :interval "50ms" "./scripts/workspaces get-active-workspace")
; Notifications
(deflisten notifications :initial '{
"count": 0,
"dnd": false,
"notifications": [],
"popups": []
}'
"./scripts/notifCatch"
)
; Playerctl
(deflisten psong "playerctl metadata --format '{{ title }}' -F")
(deflisten partist "playerctl metadata --format '{{ artist }}' -F")
(deflisten pcover "./scripts/pollcover.sh")
(deflisten pstatus "playerctl status -F")
(deflisten ptime
:initial '{
"position": 0,
"duration": 0,
"readable": "0:00"
}'
"playerctl -F metadata -f '{ \"position\": {{position/1000000}}, \"duration\": {{mpris:length/1000000}}, \"readable\": \"{{duration(position)}}/{{duration(mpris:length)}}\" }'")
;; (deflisten pside "playerctl -F metadata -f '{ \"volume\": {{volume*100}}, \"shuffle\": \"{{shuffle}}\", \"loop\": \"{{loop}}\" }'")
(defpoll thour :initial "0" :interval "60s" "date +'%I'")
(defpoll tmin :initial "0" :interval "60s" "date +'%M'")
(defpoll tpm :initial "0" :interval "60s" "date +'%p'")
(defpoll volumemute :initial "false" :interval "1s" "pamixer --get-mute")
(defpoll volume :initial "0" :interval "1s" "pactl get-sink-volume @DEFAULT_SINK@ | awk '{print $5}' | tr -d '%'")
(defpoll mic_volume :initial "0" :interval "1s" "pactl get-source-volume @DEFAULT_SOURCE@ | awk '{print $5}' | tr -d '%'")
(defpoll brightness :initial "0" :interval "2s" "brightnessctl -m | awk -F, '{print substr($4, 0, length($4)-1)}' | tr -d '%'")
(defpoll wifi_icon :initial "" :interval "30s" "./scripts/wifi --ICON")
(defpoll wifi_essid :initial "" :interval "30s" "./scripts/wifi --ESSID")
(defpoll wifi_radio :initial "off" :interval "2s" "nmcli radio wifi")
(defpoll calendar_day :initial "1" :interval "20h" "date '+%d'")
(defpoll calendar_year :initial "2000" :interval "20h" "date '+%Y'")
(defpoll bat0 :initial "0" :interval "30s" "bash ./scripts/sys_info --bat")
(defpoll baticon :initial "" :interval "30s" "bash ./scripts/sys_info --baticon")
(defpoll batstat :interval "30s" "cat /sys/class/power_supply/BAT0/status")
(defpoll homedir :initial "" :interval "24h" "echo ~")
; Controlpanel
(defpoll hostname :initial "idk" :interval "24h" 'echo "$(whoami)"')
(defpoll uptime :initial "idk" :interval "1m" "uptime -p")
(deflisten timerdis "./scripts/timer.py subscribe")
(defpoll weatherjson
:initial '{
"FeelsLikeC": "0",
"FeelsLikeF": "0",
"cloudcover": "0",
"humidity": "0",
"localObsDateTime": "2000-00-00 07:27 AM",
"observation_time": "07:27 AM",
"precipInches": "0.0",
"precipMM": "0.0",
"pressure": "0",
"pressureInches": "0",
"temp_C": "0",
"temp_F": "0",
"uvIndex": "0",
"visibility": "0",
"visibilityMiles": "0",
"weatherCode": "727",
"weatherDesc": [{"value": "Idk"}],
"weatherIconUrl": [{"value": ""}],
"winddir16Point": "",
"winddirDegree": "0",
"windspeedKmph": "0",
"windspeedMiles": "0",
"icon": "idk",
"hourly": []
}'
:interval "1h"
:run-while revealcontrolpanel
"./scripts/weather.py")
(defpoll datehour :initial "12" :interval "30m" "date +'%H'")
(defpoll notesc :interval "2s" :run-while reveal4 "cat -s ~/Documents/fuck.txt")
(defpoll quotejson :interval "1h" `./scripts/quote.py`)

View file

@ -1,16 +0,0 @@
(defpoll thour :initial "0" :interval "60s" "date +'%I'")
(defpoll tmin :initial "0" :interval "60s" "date +'%M'")
(defpoll tpm :initial "0" :interval "60s" "date +'%p'")
(defpoll volumemute :initial "false" :interval "1s" "pamixer --get-mute")
(defpoll volume :initial "0" :interval "1s" "pactl get-sink-volume @DEFAULT_SINK@ | awk '{print $5}' | tr -d '%'")
(defpoll mic_volume :initial "0" :interval "1s" "pactl get-source-volume @DEFAULT_SOURCE@ | awk '{print $5}' | tr -d '%'")
(defpoll brightness :initial "0" :interval "2s" "brightnessctl -m | awk -F, '{print substr($4, 0, length($4)-1)}' | tr -d '%'")
(defpoll wifi_icon :initial "" :interval "30s" "./scripts/wifi --ICON")
(defpoll wifi_essid :initial "" :interval "30s" "./scripts/wifi --ESSID")
(defpoll wifi_radio :initial "off" :interval "2s" "nmcli radio wifi")
(defpoll calendar_day :initial "1" :interval "20h" "date '+%d'")
(defpoll calendar_year :initial "2000" :interval "20h" "date '+%Y'")
(defpoll bat0 :initial "0" :interval "30s" "bash ./scripts/sys_info --bat")
;; (defpoll baticon :initial "" :interval "30s" "bash ./scripts/sys_info --baticon")
;; (defpoll batstat :interval "30s" "cat /sys/class/power_supply/BAT0/status")
(defpoll homedir :initial "" :interval "24h" "echo ~")

View file

@ -1,13 +0,0 @@
(defvar revealVolume false)
(defvar revealMicrophone false)
(defvar revealBrightness false)
(defvar reveal1 false)
(defvar reveal2 false)
(defvar reveal3 false)
(defvar reveal4 false)
(defvar reveal5 false)
(defvar reveal6 false)
(defvar revealweather false)
(defvar revealsystray false)
(defvar revealcontrolpanel false)

View file

@ -1,45 +1,47 @@
(include "./src/bottom-bar/sidectl.yuck")
(defwindow bar (defwindow bar
:geometry (geometry :geometry (geometry
:x "0%" :x "0%"
:y "0%" :y "0%"
:width "100%" :width "100%"
:height 40 :height 40
:anchor "bottom center") :anchor "bottom center")
:exclusive true :exclusive true
:monitor 0 :monitor 0
:wm-ignore false :wm-ignore false
(barstruct)) (barstruct))
(defwidget barstruct [] (defwidget barstruct []
;; (box ;; (box
;; :orientation "v" ;; :orientation "v"
;; :space-evenly false ;; :space-evenly false
(centerbox (centerbox
:class "barwidget" :class "barwidget"
:orientation "h" :orientation "h"
:height 60 :height 60
(left) (left)
(middle) (middle)
(right)) (right))
;; (revealer ;; (revealer
;; :transition "slideup" ;; :transition "slideup"
;; :reveal revealcontrolpanel ;; :reveal revealcontrolpanel
;; (box ;; (box
;; :class "barwidget" ;; :class "barwidget"
;; :orientation "h" ;; :orientation "h"
;; :space-evenly false ;; :space-evenly false
;; (box ;; (box
;; :orientation "v" ;; :orientation "v"
;; :space-evenly false ;; :space-evenly false
;; (user) ;; (user)
;; (chooser)) ;; (chooser))
;; (overview) ;; (overview)
;; (timer) ;; (timer)
;; (touchpad) ;; (touchpad)
;; ))) ;; )))
) )
(defwidget left [] (defwidget left []
(box (box
:orientation "h" :orientation "h"
:space-evenly false :space-evenly false
@ -48,30 +50,30 @@
(home) (home)
(workspaces) (workspaces)
;; (cavapipe) ;; (cavapipe)
)) ))
(defwidget middle [] (defwidget middle []
(box (box
:orientation "h" :orientation "h"
:space-evenly false :space-evenly false
:halign "center" :halign "center"
:valign "fill" :valign "fill"
(tasklist :iconsize 42) (tasklist :iconsize 42)
)) ))
(defwidget right [] (defwidget right []
(box (box
:orientation "h" :orientation "h"
:space-evenly false :space-evenly false
:halign "end" :halign "end"
:valign "fill" :valign "fill"
(button :class "widget" :onclick "./scripts/touchkey.sh && ${EWW_CMD} update revealcontrolpanel=false" (button :class "widget" :onclick "./scripts/touchkey.sh && ${EWW_CMD} update revealcontrolpanel=false"
(label :class "icon" :style "padding-left: 3px;" :text "󰌌")) (label :class "icon" :style "padding-left: 3px;" :text "󰌌"))
(playerctl) (playerctl)
(sysicons) (sysicons)
;; (battery) ;; (battery)
(clock) (clock)
)) ))
(defwidget workspaces [] (defwidget workspaces []
(eventbox (eventbox
@ -90,126 +92,125 @@
:class { workspacejson[i].focused ? "workspacethingactive" : "workspacething"} :class { workspacejson[i].focused ? "workspacethingactive" : "workspacething"}
:orientation "h" :orientation "h"
:space-evenly false :space-evenly false
(box (box
:width 50) :width 50)
(revealer (revealer
:reveal { !workspacejson[i].empty || workspacejson[i].focused } :reveal { !workspacejson[i].empty || workspacejson[i].focused }
:transition "slideright" :transition "slideright"
(box (box
:width 30)) :width 30))
(revealer (revealer
:reveal { workspacejson[i].focused } :reveal { workspacejson[i].focused }
:transition "slideright" :transition "slideright"
(box (box
:width 20)) :width 20))
)))))) ))))))
(defwidget clock [] (defwidget clock []
(box (box
:orientation "h" :orientation "h"
:class "clock widget" :class "clock widget"
:space-evenly false :space-evenly false
(button (button
:onclick "${EWW_CMD} update reveal1=${!reveal1} reveal2=false reveal3=false" :onclick "${EWW_CMD} update reveal1=${!reveal1} reveal2=false reveal3=false"
(label :text "${thour}:${tmin} ${tpm}")))) (label :text "${thour}:${tmin} ${tpm}"))))
(defwidget sysicons [] (defwidget sysicons []
(box (box
:class "widget" :class "widget"
:valign "fill" :valign "fill"
(button (button
:onclick "${EWW_CMD} update reveal1=false reveal2=${!reveal2} reveal3=false" :onclick "${EWW_CMD} update reveal1=false reveal2=${!reveal2} reveal3=false"
:class "icon" :class "icon"
(box (box
:orientation "h" :orientation "h"
:space-evenly false :space-evenly false
:spacing 5 :spacing 5
(label :tooltip wifi_essid :class "icon" :text wifi_icon) (label :tooltip wifi_essid :class "icon" :text wifi_icon)
(label :tooltip "${volume}%" :class "icon" :text {volumemute == 'false' ? "󰕾" : "󰖁"}) (label :tooltip "${volume}%" :class "icon" :text {volumemute == 'false' ? "󰕾" : "󰖁"})
(overlay (overlay
:tooltip "${bat0}%" :tooltip "${bat0}%"
(label :class "icon" :text "") (label :class "icon" :text "")
(scale (scale
:hexpand false :hexpand false
:orientation "h" :orientation "h"
:active false :active false
:min 0 :min 0
:max 100 :max 100
:value bat0 :value bat0
:class "overbat ${EWW_BATTERY.BAT0.status == 'Charging' ? 'charging' : ''}")) :class "overbat ${EWW_BATTERY.BAT0.status == 'Charging' ? 'charging' : ''}"))
)))) ))))
(defwidget battery [] (defwidget battery []
(box (box
:orientation "h" :orientation "h"
:space-evenly false :space-evenly false
:class "widget" :class "widget"
(overlay (overlay
(scale (scale
:class "${EWW_BATTERY.BAT0.status == 'Charging' ? 'charging': bat0 < 16 ? 'dying': 'normal'} bat_scale" :class "${EWW_BATTERY.BAT0.status == 'Charging' ? 'charging': bat0 < 16 ? 'dying': 'normal'} bat_scale"
:value "${bat0}" :value "${bat0}"
:orientation "h" :orientation "h"
:max 100 :max 100
:min 0 :min 0
:flipped true :flipped true
:active false) :active false)
(label (label
:class "lightning" :class "lightning"
:visible {EWW_BATTERY.BAT0.status == "Charging"} :visible {EWW_BATTERY.BAT0.status == "Charging"}
:text "󱐋")) :text "󱐋"))
(label :text "${bat0}%"))) (label :text "${bat0}%")))
(defwidget playerctl [] (defwidget playerctl []
(overlay (overlay
(box (box
:halign "fill" :halign "fill"
:width 150 :width 150
:class { pcover != "" ? "mpdcover" : "widget"} :class { pcover != "" ? "mpdcover" : "widget"}
:style "background-image: url('${pcover}')") :style "background-image: url('${pcover}')")
(box (box
;; :class "widget" ;; :class "widget"
:orientation "h" :orientation "h"
:space-evenly false :space-evenly false
:spacing 5 :spacing 5
:halign "center" :halign "center"
:valign "center" :valign "center"
(eventbox (eventbox
:onclick "${EWW_CMD} update reveal1=false reveal2=false reveal3=${!reveal3}" :onclick "${EWW_CMD} update reveal1=false reveal2=false reveal3=${!reveal3}"
(image :path { pcover == "" ? "./image/emptympd.png" : pcover } :image-width 30 :image-height 30 :style "padding: 0px 5px;")) (image :path { pcover == "" ? "./assets/image/emptympd.png" : pcover } :image-width 30 :image-height 30 :style "padding: 0px 5px;"))
(button :onclick "playerctl previous" (button :onclick "playerctl previous"
(label :class "icon" :text "󰒮")) (label :class "icon" :text "󰒮"))
(button :onclick "playerctl play-pause" (button :onclick "playerctl play-pause"
(label :class "icon" :text { pstatus == "Playing" ? "" : "" })) (label :class "icon" :text { pstatus == "Playing" ? "" : "" }))
(button :onclick "playerctl next" (button :onclick "playerctl next"
(label :class "icon" :text "󰒭")) (label :class "icon" :text "󰒭"))
))) )))
(defwidget home [] (defwidget home []
(box (box
:class "widget" :class "widget"
:hexpand false :hexpand false
:vexpand false :vexpand false
(eventbox (eventbox
;; :onclick "~/.config/eww/meowidgets/scripts/launch" ;; :onclick "~/.config/eww/meowidgets/scripts/launch"
;; :onclick "~/.config/eww/meowayland/scripts/launch" ;; :onclick "~/.config/eww/meowayland/scripts/launch"
;; :onclick "./scripts/pop control" ;; :onclick "./scripts/pop control"
:onclick "${EWW_CMD} update revealcontrolpanel=${ !revealcontrolpanel }" :onclick "${EWW_CMD} update revealcontrolpanel=${ !revealcontrolpanel }"
:onrightclick "${EWW_CMD} open wallpaperselect --toggle" :onrightclick "${EWW_CMD} open wallpaperselect --toggle"
:cursor "pointer" :cursor "pointer"
(label :text "" :halign "center" :class "launchicon" :style "padding: 0px 4px;")))) (label :text "" :halign "center" :class "launchicon" :style "padding: 0px 4px;"))))
;; (defwidget cavapipe [] ;; (defwidget cavapipe []
;; (box ;; (box
;; :class "widget" ;; :class "widget"
;; :orientation "h" ;; :orientation "h"
;; :space-evenly true ;; :space-evenly true
;; (for bar in {cavajson} ;; (for bar in {cavajson}
;; (scale ;; (scale
;; :class "cavascale" ;; :class "cavascale"
;; :orientation "v" ;; :orientation "v"
;; :value bar ;; :value bar
;; :min 0 ;; :min 0
;; :max 100 ;; :max 100
;; :flipped true)))) ;; :flipped true))))
(include "./bottom_bar/sidectl.yuck")

View file

@ -1,15 +1,15 @@
(defwindow sidectl1 (defwindow sidectl1
:geometry (geometry :geometry (geometry
:x "0%" :x "0%"
:y "0%" :y "0%"
:width 320 :width 320
:height 0 :height 0
:anchor "bottom right") :anchor "bottom right")
:monitor 0 :monitor 0
:stacking "overlay" :stacking "overlay"
(revealer (revealer
:reveal reveal1 :reveal reveal1
:transition "slideup" :transition "slideup"
(box (box
:orientation "v" :orientation "v"
@ -18,31 +18,31 @@
(box (box
:height 700 :height 700
:class "popup" :class "popup"
(notiweathertoggle)) (notiweathertoggle))
(box (box
:class "popup" :class "popup"
(box (box
:class "unbarwidget" :class "unbarwidget"
(calendar (calendar
:day calendar_day :day calendar_day
:year calendar_year :year calendar_year
:class ""))) :class "")))
))) )))
(defwindow sidectl2 (defwindow sidectl2
:geometry (geometry :geometry (geometry
:x 50 :x 50
:y 0 :y 0
:width 200 :width 200
:height 0 :height 0
:anchor "bottom right") :anchor "bottom right")
:monitor 0 :monitor 0
:stacking "overlay" :stacking "overlay"
(revealer (revealer
:reveal reveal2 :reveal reveal2
:transition "slideup" :transition "slideup"
(box (box
:class "popup" :class "popup"
:orientation "v" :orientation "v"
:space-evenly false :space-evenly false
@ -50,131 +50,131 @@
:orientation "v" :orientation "v"
:class "widget" :class "widget"
:spacing 20 :spacing 20
:space-evenly false :space-evenly false
(box (box
:orientation "v" :orientation "v"
:height 150 :height 150
(box (box
:orientation "h" :orientation "h"
(togglebuttons (togglebuttons
:icon wifi_icon :icon wifi_icon
:class {wifi_radio == "enabled" ? "icontitlesel" : "icontitle"} :class {wifi_radio == "enabled" ? "icontitlesel" : "icontitle"}
:text {wifi_radio == "enabled" ? wifi_essid == "" ? "Disconnected" : "Connected" : "Off"} :text {wifi_radio == "enabled" ? wifi_essid == "" ? "Disconnected" : "Connected" : "Off"}
:subtext { wifi_essid == "" ? "..." : wifi_essid} :subtext { wifi_essid == "" ? "..." : wifi_essid}
:toggle {wifi_radio == "enabled" ? "nmcli radio wifi off" : "nmcli radio wifi on"}) :toggle {wifi_radio == "enabled" ? "nmcli radio wifi off" : "nmcli radio wifi on"})
(togglebuttons (togglebuttons
:icon "" :icon ""
:class {caffeine ? "icontitlesel" : "icontitle"} :class {caffeine ? "icontitlesel" : "icontitle"}
:text "Caffeine" :text "Caffeine"
:subtext {caffeine ? "on" : "off"} :subtext {caffeine ? "on" : "off"}
:toggle {caffeine ? "swaymsg [app_id='.*'] inhibit_idle none && ${EWW_CMD} update caffeine=false" : "swaymsg [app_id='.*'] inhibit_idle open && ${EWW_CMD} update caffeine=true"})) :toggle {caffeine ? "swaymsg [app_id='.*'] inhibit_idle none && ${EWW_CMD} update caffeine=false" : "swaymsg [app_id='.*'] inhibit_idle open && ${EWW_CMD} update caffeine=true"}))
(box (box
:orientation "h" :orientation "h"
(togglebuttons (togglebuttons
:icon "" :icon ""
:class "icontitle" :class "icontitle"
:text "Theme" :text "Theme"
:subtext theme :subtext theme
:toggle "${EWW_CMD} update reveal2=false && ~/.config/eww/themeswitch/scripts/pop") :toggle "${EWW_CMD} update reveal2=false && ~/.config/eww/themeswitch/scripts/pop")
(togglebuttons (togglebuttons
:icon "" :icon ""
:class {notifications.dnd ? "icontitlesel" : "icontitle"} :class {notifications.dnd ? "icontitlesel" : "icontitle"}
:text "Do not disturb" :text "Do not disturb"
:subtext {notifications.dnd ? "on" : "off"} :subtext {notifications.dnd ? "on" : "off"}
:toggle "./scripts/notifManage --toggle") :toggle "./scripts/notifManage --toggle")
)) ))
(sliderctl :icon {volumemute == 'false' ? "󰕾" : "󰖁"} :value volume :onchange "pamixer --set-volume {}") (sliderctl :icon {volumemute == 'false' ? "󰕾" : "󰖁"} :value volume :onchange "pamixer --set-volume {}")
(sliderctl :icon "󰃞" :value brightness :onchange "brightnessctl set {}%") (sliderctl :icon "󰃞" :value brightness :onchange "brightnessctl set {}%")
(box (box
:orientation "h" :orientation "h"
:space-evenly false :space-evenly false
:halign "end" :halign "end"
(overlay (overlay
(scale (scale
:class "${EWW_BATTERY.BAT0.status == 'Charging' ? 'charging': bat0 < 16 ? 'dying': 'normal'} bat_scale" :class "${EWW_BATTERY.BAT0.status == 'Charging' ? 'charging': bat0 < 16 ? 'dying': 'normal'} bat_scale"
:value "${bat0}" :value "${bat0}"
:orientation "h" :orientation "h"
:max 100 :max 100
:min 0 :min 0
:active false) :active false)
(label (label
:class "lightning" :class "lightning"
:visible {EWW_BATTERY.BAT0.status == "Charging"} :visible {EWW_BATTERY.BAT0.status == "Charging"}
:text "󱐋")) :text "󱐋"))
(label :text "${bat0}%")) (label :text "${bat0}%"))
)))) ))))
(defwidget togglebuttons [icon class text ?subtext toggle] (defwidget togglebuttons [icon class text ?subtext toggle]
(button (button
:onclick toggle :onclick toggle
(box (box
:orientation "h" :orientation "h"
:class class :class class
:space-evenly false :space-evenly false
(label (label
:class "icon" :class "icon"
:halign "start" :halign "start"
:text icon) :text icon)
(box (box
:orientation "v" :orientation "v"
:hexpand true :hexpand true
:halign "center" :halign "center"
(label (label
:text text) :text text)
(label (label
:limit-width 17 :limit-width 17
:text subtext))))) :text subtext)))))
(defwidget sliderctl [icon value onchange] (defwidget sliderctl [icon value onchange]
(box (box
:orientation "h" :orientation "h"
:space-evenly false :space-evenly false
:hexpand true :hexpand true
:spacing 5 :spacing 5
(label (label
:class "icon" :class "icon"
:text icon :text icon
:style "margin-left: 5px;") :style "margin-left: 5px;")
(scale (scale
:class "sliderctl" :class "sliderctl"
:orientation "h" :orientation "h"
:value value :value value
:tooltip "${value}%" :tooltip "${value}%"
:min 0 :min 0
:max 100 :max 100
:onchange onchange))) :onchange onchange)))
(defwindow sidectl3 (defwindow sidectl3
:geometry (geometry :geometry (geometry
:x 150 :x 150
:y 0 :y 0
:width 440 :width 440
:height 0 :height 0
:anchor "bottom right") :anchor "bottom right")
:monitor 0 :monitor 0
:stacking "overlay" :stacking "overlay"
(revealer (revealer
:reveal reveal3 :reveal reveal3
:transition "slideup" :transition "slideup"
(box (box
:class "popup" :class "popup"
(box (box
:orientation "h" :orientation "h"
:class "unbarwidget" :class "unbarwidget"
:space-evenly false :space-evenly false
:spacing 20 :spacing 20
(image :style "margin: 5px;" :image-height 190 :image-width 190 :path { pcover == "" ? "./image/emptympd.png" : pcover }) (image :style "margin: 5px;" :image-height 190 :image-width 190 :path { pcover == "" ? "./assets/image/emptympd.png" : pcover })
(box (box
:orientation "v" :orientation "v"
:space-evenly false :space-evenly false
:width 210 :width 210
:height 200 :height 200
(scroll (scroll
@ -185,88 +185,88 @@
:hscroll true :hscroll true
:vscroll false :vscroll false
(label :class "mauthor" :text partist)) (label :class "mauthor" :text partist))
(box (box
:orientation "h" :orientation "h"
:class "mpd_controls" :class "mpd_controls"
:style "margin-top: 10px;" :style "margin-top: 10px;"
(button :onclick "playerctl previous" (label :text "󰒮")) (button :onclick "playerctl previous" (label :text "󰒮"))
(button :onclick "playerctl play-pause" (button :onclick "playerctl play-pause"
(label :text { pstatus == "Playing" ? "" : ""} )) (label :text { pstatus == "Playing" ? "" : ""} ))
(button :onclick "playerctl next" (button :onclick "playerctl next"
(label :text "󰒭"))) (label :text "󰒭")))
(scale (scale
:class "seektime" :class "seektime"
:value { ptime.position } :value { ptime.position }
:orientation "h" :orientation "h"
:onchange "playerctl position {}" :onchange "playerctl position {}"
:min 0 :min 0
:max { ptime.duration } :max { ptime.duration }
:tooltip { ptime.readable })) :tooltip { ptime.readable }))
;; (box ;; (box
;; :orientation "v" ;; :orientation "v"
;; :space-evenly false ;; :space-evenly false
;; :valign "center" ;; :valign "center"
;; :halign "end" ;; :halign "end"
;; :class "sidempdctl" ;; :class "sidempdctl"
;; (scale ;; (scale
;; :value { pside.volume } ;; :value { pside.volume }
;; :orientation "v" ;; :orientation "v"
;; :class "mpdvolumeseek" ;; :class "mpdvolumeseek"
;; :onchange "playerctl volume {}" ;; :onchange "playerctl volume {}"
;; :min 0 ;; :min 0
;; :max 100 ;; :max 100
;; :flipped true ;; :flipped true
;; :tooltip "volume: ${pside.volume}") ;; :tooltip "volume: ${pside.volume}")
;; (button ;; (button
;; :onclick "playerctl shuffle toggle" ;; :onclick "playerctl shuffle toggle"
;; (label ;; (label
;; :text {pside.shuffle == "true" ? "󰒝" : "󰒞"})) ;; :text {pside.shuffle == "true" ? "󰒝" : "󰒞"}))
;; (button ;; (button
;; :onclick "playerctl loop ${pside.loop == 'Track' ? 'Playlist' : 'Track'}" ;; :onclick "playerctl loop ${pside.loop == 'Track' ? 'Playlist' : 'Track'}"
;; (label ;; (label
;; :text {pside.loop == "Track" ? "󰑘" : "󰑖"})) ;; :text {pside.loop == "Track" ? "󰑘" : "󰑖"}))
;; ) ;; )
)))) ))))
(defwindow sidectl4 (defwindow sidectl4
:geometry (geometry :geometry (geometry
:x 0 :x 0
:y 0 :y 0
:width 340 :width 340
:height 0 :height 0
:anchor "bottom left" :anchor "bottom left"
) )
:stacking "overlay" :stacking "overlay"
:monitor 0 :monitor 0
(revealer (revealer
:reveal revealcontrolpanel :reveal revealcontrolpanel
:transition "slideup" :transition "slideup"
(box (box
:class "popup" :class "popup"
(control_widget :short true)))) (control_widget :short true))))
(defwidget touchpad [] (defwidget touchpad []
(box (box
:class "unbarwidget" :class "unbarwidget"
:orientation "h" :orientation "h"
:width 180 :width 180
(box (box
:orientation "h" :orientation "h"
(box (box
:orientation "v" :orientation "v"
(button :onclick "swaymsg floating toggle" (button :onclick "swaymsg floating toggle"
(label :class "largetouchicon" :text "󱟱")) (label :class "largetouchicon" :text "󱟱"))
(button :onclick "foot -D ~" (button :onclick "foot -D ~"
(label :class "largetouchicon" :text "")) (label :class "largetouchicon" :text ""))
(button :onclick "./scripts/pop scrop" (button :onclick "./scripts/pop scrop"
(label :class "largetouchicon" :text "󰆞")) (label :class "largetouchicon" :text "󰆞"))
) )
(box (box
:orientation "v" :orientation "v"
(button :onclick "swaymsg kill" (button :onclick "swaymsg kill"
(label :class "largetouchicon" :text "󰅙")) (label :class "largetouchicon" :text "󰅙"))
(button :onclick "${EWW_CMD} update revealcontrolpanel=false && (cd && wofi --show=drun -i -I)" (button :onclick "${EWW_CMD} update revealcontrolpanel=false && (cd && wofi --show=drun -i -I)"
(label :class "largetouchicon" :text "󰀻")) (label :class "largetouchicon" :text "󰀻"))
(button :onclick "./scripts/touchkey.sh && ${EWW_CMD} update revealcontrolpanel=false" (button :onclick "./scripts/touchkey.sh && ${EWW_CMD} update revealcontrolpanel=false"
(label :class "largetouchicon" :text "󰌌")) (label :class "largetouchicon" :text "󰌌"))
)))) ))))

View file

@ -1,3 +1,5 @@
(include "./src/control-panel/windowswitcher.yuck")
(defwindow control_panel (defwindow control_panel
:geometry (geometry :geometry (geometry
:x 10 :x 10
@ -217,7 +219,7 @@
:valign "start" :valign "start"
:halign "fill" :halign "fill"
:hexpand true :hexpand true
(image :style "margin: 10px;" :image-width 80 :image-height 80 :path "./image/fieshidle.gif") (image :style "margin: 10px;" :image-width 80 :image-height 80 :path "./assets/image/fieshidle.gif")
(scroll (scroll
:hscroll true :hscroll true
:vscroll false :vscroll false
@ -304,7 +306,7 @@
(image (image
:image-width 50 :image-width 50
:image-height 50 :image-height 50
:path "./image/weather/${hour.icon}.svg") :path "./assets/image/weather/${hour.icon}.svg")
(box (box
:orientation "v" :orientation "v"
:space-evenly false :space-evenly false
@ -325,7 +327,7 @@
:image-width 100 :image-width 100
:image-height 100 :image-height 100
:style "margin: 10px;" :style "margin: 10px;"
:path "./image/weather/${weatherjson.icon}.svg") :path "./assets/image/weather/${weatherjson.icon}.svg")
(scroll (scroll
:hscroll true :hscroll true
:vscroll false :vscroll false
@ -474,7 +476,7 @@
:halign "center" :halign "center"
:valign "center" :valign "center"
:spacing 10 :spacing 10
(image :image-width 100 :image-height 100 :path { pcover == "" ? "./image/emptympd.png" : pcover }) (image :image-width 100 :image-height 100 :path { pcover == "" ? "./assets/image/emptympd.png" : pcover })
(box (box
:orientation "v" :orientation "v"
:space-evenly false :space-evenly false
@ -498,6 +500,4 @@
(button :style "padding-right: 3px;" :onclick "playerctl play-pause" (button :style "padding-right: 3px;" :onclick "playerctl play-pause"
(label :text { pstatus == "Playing" ? "" : ""} )) (label :text { pstatus == "Playing" ? "" : ""} ))
(button :onclick "playerctl next" (button :onclick "playerctl next"
(label :text "󰒭"))))))) (label :text "󰒭")))))))
(include "./control_panel/windowswitcher.yuck")

View file

@ -1,9 +1,9 @@
;; Credits to T0kyob0y ;; Credits to T0kyob0y
(defwidget overview[] (defwidget overview []
(box (box
:space-evenly false :space-evenly false
:class "unbarwidget" :class "unbarwidget"
:orientation "h" :orientation "h"
:hexpand true :hexpand true
@ -11,7 +11,7 @@
:hscroll true :hscroll true
:vscroll false :vscroll false
:hexpand true :hexpand true
(box (box
:orientation "h" :orientation "h"
:space-evenly true :space-evenly true
:spacing 10 :spacing 10
@ -20,26 +20,26 @@
;; :ondropped "notify-send 'real'" ;; :ondropped "notify-send 'real'"
:onclick "${EWW_CMD} update revealcontrolpanel=false && swaymsg -t command workspace number ${i+1}" :onclick "${EWW_CMD} update revealcontrolpanel=false && swaymsg -t command workspace number ${i+1}"
;; :onclick "swaymsg -t command workspace number ${i+1}" ;; :onclick "swaymsg -t command workspace number ${i+1}"
(box (box
:class "overviewworkspace" :class "overviewworkspace"
:space-evenly false :space-evenly false
;; :height {round(1080/5.8, 0)} ;; :height {round(1080/5.8, 0)}
:vexpand true :vexpand true
:width {round(1920/5.8, 0)} :width {round(1920/5.8, 0)}
(for j in {windows[i]} (for j in {windows[i]}
(windowapp :w j) (windowapp :w j)
)) ))
)))))) ))))))
(defwidget windowapp [w] (defwidget windowapp [w]
(box (box
:style " :style "
margin-left: ${round(((w.rect.x)/5.8), 0)}px; margin-left: ${round(((w.rect.x)/5.8), 0)}px;
margin-top: ${round(w.rect.y/5.8, 0)}px; margin-top: ${round(w.rect.y/5.8, 0)}px;
margin-right: -${round((w.rect.x + w.rect.width)/5.8, 0)}px; margin-right: -${round((w.rect.x + w.rect.width)/5.8, 0)}px;
margin-bottom: -${round(((w.rect.y + w.rect.height)/5.8), 0)}px; margin-bottom: -${round(((w.rect.y + w.rect.height)/5.8), 0)}px;
" "
:hexpand false :hexpand false
:vexpand false :vexpand false
:halign "start" :halign "start"
:valign "start" :valign "start"
@ -49,10 +49,10 @@
:halign "center" :halign "center"
:dragvalue "${w.pid}" :dragvalue "${w.pid}"
:dragtype "text" :dragtype "text"
(image (image
:valign "center" :valign "center"
:halign "center" :halign "center"
:image-height {round(w.rect.width/5.8 * 45/100, 0)} :image-height {round(w.rect.width/5.8 * 45/100, 0)}
:image-width {round(w.rect.height/5.8 * 45/100, 0)} :image-width {round(w.rect.height/5.8 * 45/100, 0)}
:path {w.path} :path {w.path}
)))) ))))

View file

@ -1,5 +1,4 @@
;; Dashboard design is made by tsukki9696
(defwindow dashboard (defwindow dashboard
:geometry (geometry :geometry (geometry
:x 0 :x 0
@ -16,7 +15,7 @@
:class "popup" :class "popup"
:space-evenly false :space-evenly false
:orientation "v" :orientation "v"
(duser :name "Failed" :tag "failed.sh" :pfp "./image/roundpfp.png") (duser :name "Failed" :tag "failed.sh" :pfp "./assets/image/roundpfp.png")
(box (box
:space-evenly true :space-evenly true
:orientation "h" :orientation "h"

View file

@ -0,0 +1,19 @@
.heading {
font-size: 25px;
color: $accent;
margin: 5px;
}
.dmpdcontrol {
margin: 10px;
}
.dmpdcontrol label {
font-size: 20px;
margin: 0px 8px;
}
.dicons label {
font-size: 25px;
margin-right: 6px;
}

View file

@ -30,12 +30,12 @@
(defwidget imagesicon [name] (defwidget imagesicon [name]
(eventbox (eventbox
:onclick "feh ./image/desktop/${name}.png" :onclick "feh ./assets/image/desktop/${name}.png"
:class "desktopbox" :class "desktopbox"
(box (box
:orientation "v" :orientation "v"
:space-evenly false :space-evenly false
:height 100 :height 100
:valign "end" :valign "end"
(image :width 100 :height 100 :image-width 80 :image-height 80 :path "./image/desktop/${name}.png") (image :width 100 :height 100 :image-width 80 :image-height 80 :path "./assets/image/desktop/${name}.png")
(label :class "desktoptext" :text "${name}.png")))) (label :class "desktoptext" :text "${name}.png"))))

View file

@ -19,7 +19,7 @@
:space-evenly false :space-evenly false
(revealer (revealer
:transition "slideright" :transition "slideright"
:reveal revealcontrolpanel :reveal revealControlpanel
(control_widget)) (control_widget))
(centerbox (centerbox
:class "barwidget" :class "barwidget"
@ -69,23 +69,17 @@
; (battery) ; (battery)
)) ))
(defvar show_no_of_windows false)
(deflisten workspacesdata :initial "[]" "./scripts/workspaces get-all-workspaces")
(defpoll current_workspace :initial "0" :interval "50ms" "./scripts/workspaces get-active-workspace")
(defwidget workspaces [] (defwidget workspaces []
(eventbox (eventbox
:cursor "pointer" :cursor "pointer"
:onscroll "./scripts/workspaces change {} ${current_workspace}" :onscroll "./scripts/workspaces change {} ${current_workspace}"
:onhover "eww update show_no_of_windows=true" :onhover "${EWW_CMD} update show_no_of_windows=true"
:onhoverlost "eww update show_no_of_windows=false" :onhoverlost "${EWW_CMD} update show_no_of_windows=false"
(box (box
:class "workspaces" :class "workspaces"
:space-evenly false :space-evenly false
:orientation "v" :orientation "v"
(for workspace in {workspacesdata} (for workspace in {workspacesjson}
(button (button
:onclick "hyprctl dispatch workspace ${workspace.id}" :onclick "hyprctl dispatch workspace ${workspace.id}"
(box (box
@ -109,7 +103,7 @@
;; :onclick "~/.config/eww/meowidgets/scripts/launch" ;; :onclick "~/.config/eww/meowidgets/scripts/launch"
;; :onclick "~/.config/eww/meowayland/scripts/launch" ;; :onclick "~/.config/eww/meowayland/scripts/launch"
;; :onclick "./scripts/pop control" ;; :onclick "./scripts/pop control"
:onclick "${EWW_CMD} update revealcontrolpanel=${ !revealcontrolpanel }" :onclick "${EWW_CMD} update revealControlpanel=${ !revealControlpanel }"
:onrightclick "${EWW_CMD} open wallpaperselect --toggle" :onrightclick "${EWW_CMD} open wallpaperselect --toggle"
:cursor "pointer" :cursor "pointer"
(label :text "" :halign "center" :class "launchicon" :style "padding: 2px 0px;")))) (label :text "" :halign "center" :class "launchicon" :style "padding: 2px 0px;"))))
@ -205,7 +199,7 @@
:spacing 5 :spacing 5
(eventbox (eventbox
:onclick "${EWW_CMD} open music --toggle" :onclick "${EWW_CMD} open music --toggle"
(image :path { pcover == "" ? "./image/emptympd.png" : pcover } :image-width 20 :image-height 20)) (image :path { pcover == "" ? "./assets/image/emptympd.png" : pcover } :image-width 20 :image-height 20))
(button :onclick "playerctl previous" (button :onclick "playerctl previous"
(label :class "picon" :text "󰒮")) (label :class "picon" :text "󰒮"))
(button :onclick "playerctl play-pause" (button :onclick "playerctl play-pause"
@ -313,7 +307,7 @@
:class "unbarwidget" :class "unbarwidget"
:space-evenly false :space-evenly false
:spacing 20 :spacing 20
(image :style "margin: 5px;" :image-height 190 :image-width 190 :path { pcover == "" ? "./image/emptympd.png" : pcover }) (image :style "margin: 5px;" :image-height 190 :image-width 190 :path { pcover == "" ? "./assets/image/emptympd.png" : pcover })
(box (box
:orientation "v" :orientation "v"
:space-evenly false :space-evenly false

View file

@ -8,7 +8,6 @@
:anchor "center") :anchor "center")
:stacking "overlay" :stacking "overlay"
:monitor 0 :monitor 0
:focusable true
(box (box
:class "popup" :class "popup"
(wallpaperselectwidget))) (wallpaperselectwidget)))
@ -46,7 +45,7 @@
:style "margin: 50px 0px 5px 0px;" :style "margin: 50px 0px 5px 0px;"
:hexpand false :hexpand false
:vexpand false :vexpand false
:path "./image/fieshidle.gif" :path "./assets/image/fieshidle.gif"
:visible {arraylength(wallpapers) == 0}) :visible {arraylength(wallpapers) == 0})
(label (label