feat(eww): add WIP lockscreen widget

This commit is contained in:
Mohammad Rafiq 2025-03-19 18:29:23 +08:00
parent 04dbe997a8
commit 076f81007c
No known key found for this signature in database

View file

@ -1,22 +1,30 @@
(defwindow example (defwindow lockscreen_background :monitor 0
:monitor 0 :geometry (geometry :width "100%"
:geometry (geometry :x "0%" :height "100%"
:t "20px" :anchor "center")
:width "90%"
:height "30px"
:anchor "top center")
:stacking "fg" :stacking "fg"
(labeled-container :name "foo" (box))
(greeter :name "rafiq")))
(defwidget greeter [?text name] (defwindow lockscreen_title :monitor 0
(box :orientation "horizontal" :geometry (geometry :anchor "center")
:halign "center" :stacking "fg"
text (greeting))
(button :onclick "hyprctl notify 0 1000 0 'Hello, ${name}.'"
"Greet")))
(defwidget labeled-container [name] (defwidget greeting[]
(box :class "container" (box (label :markup '<span size="32pt">Hi, rafiq.</span>')))
name
(children))) (defwindow lockscreen_input :monitor 0
:geometry (geometry :y "55%"
:width "5%"
:height "2.5%"
:anchor "center top")
:stacking "fg"
:focusable "ondemand"
(password_input))
(defwidget password_input[]
(box
(input :onaccept "${EWW_CMD} close-all"
:password true
:class "password_input"
:css ".password_input {border-radius:50px;}")))