Skip to content

hyprsunset

Toggle for Hyprland's blue-light filter.

Add it to your layout with hyprsunset:

toml
[[bar.layout]]
monitor = "*"
right = ["hyprsunset"]

General

FieldTypeDefaultDescription
formatstring"{{ status }}"Format string for the label.
temperatureu325000Color temperature in Kelvin when filter is enabled. Range: 1000-20000.
gammau32100Display gamma percentage when filter is enabled. Range: 0-200.
icon-offstring"ld-sun-symbolic"Icon when filter is disabled (showing normal daylight colors).
icon-onstring"ld-moon-symbolic"Icon when filter is enabled (showing warm night colors).
border-showboolfalseDisplay border around button.
icon-showbooltrueDisplay module icon.
label-showbooltrueDisplay label.
label-max-lengthu320Max label characters before truncation with ellipsis. Set to 0 to disable.
More about format

Placeholders

  • {{ status }} - Filter status text (On, Off)
  • {{ temp }} - Current temperature in Kelvin (shows "--" when disabled)
  • {{ gamma }} - Current gamma percentage (shows "--" when disabled)
  • {{ config_temp }} - Configured temperature (always available)
  • {{ config_gamma }} - Configured gamma (always available)

Examples

  • "{{ status }}" - "On"
  • "{{ temp }}K {{ gamma }}%" - "4500K 80%"
  • "{{ status }} ({{ temp }}K)" - "On (4500K)"

Colors

FieldTypeDefaultDescription
border-colorColorValue"yellow"Border color token.
icon-colorColorValue"auto"Icon foreground color. Auto selects based on variant for contrast.
icon-bg-colorColorValue"yellow"Icon container background color token.
label-colorColorValue"yellow"Label text color token.
button-bg-colorColorValue"bg-surface-elevated"Button background color token.

Click actions

FieldTypeDefaultDescription
left-clickClickAction":toggle"Action on left click. Default toggles blue light filter.
right-clickClickAction""Action on right click.
middle-clickClickAction""Action on middle click.
scroll-upClickAction""Action on scroll up.
scroll-downClickAction""Action on scroll down.

Default configuration

toml
[modules.hyprsunset]
format = "{{ status }}"
temperature = 5000
gamma = 100
icon-off = "ld-sun-symbolic"
icon-on = "ld-moon-symbolic"
border-show = false
border-color = "yellow"
icon-show = true
icon-color = "auto"
icon-bg-color = "yellow"
label-show = true
label-color = "yellow"
label-max-length = 0
button-bg-color = "bg-surface-elevated"
left-click = ":toggle"
right-click = ""
middle-click = ""
scroll-up = ""
scroll-down = ""

Released under the MIT License.