fixed notifications font rendering

This commit is contained in:
SomeElse
2026-05-16 21:17:45 +00:00
parent 526607ee8d
commit 0c7b5188a8
15 changed files with 292 additions and 590 deletions

View File

@@ -6,19 +6,9 @@ import Quickshell.Wayland
import "../../config" as Cfg
import "../../components"
Rectangle {
ModuleChip {
id: root
property real panelRadius: Cfg.Config.radius / 2
property int borderWidth: Cfg.Config.panelBorderWidth
property bool isTop: true
property var targetScreen: null
property int barHeight: Cfg.Config.barHeight
property int barMargin: Cfg.Config.margin
readonly property var t: Cfg.Config.theme
TimezoneProvider { id: timezone }
width: clockLayout.implicitWidth + 24
@@ -92,52 +82,11 @@ Rectangle {
}
}
PanelWindow {
PopupPanel {
id: calendarPopup
screen: root.targetScreen
visible: false
color: "transparent"
property bool popupOpen: false
function open() { hideTimer.stop(); visible = true; popupOpen = true }
function close() { popupOpen = false; hideTimer.restart() }
function toggle() { popupOpen ? close() : open() }
Timer {
id: hideTimer
interval: Cfg.Config.popupAnimDuration + 70
onTriggered: calendarPopup.visible = false
}
anchors { top: true; bottom: true; left: true; right: true }
WlrLayershell.layer: WlrLayer.Top
WlrLayershell.namespace: "main-shell-calendar"
WlrLayershell.exclusiveZone: -1
mask: popupOpen ? null : _noInput
Region { id: _noInput }
TapHandler { onTapped: calendarPopup.close() }
Item {
id: calClipContainer
readonly property int cardW: 284
readonly property int screenPad: root.barMargin + 10
x: {
let centerX = root.mapToItem(null, 0, 0).x + root.width / 2
let desiredX = centerX - cardW / 2
return Math.max(screenPad, Math.min(desiredX, parent.width - cardW - screenPad))
}
width: cardW
anchors.top: root.isTop ? parent.top : undefined
anchors.bottom: root.isTop ? undefined : parent.bottom
anchors.topMargin: root.isTop ? (root.barHeight + 10) : 0
anchors.bottomMargin: root.isTop ? 0 : (root.barHeight + 10)
height: parent.height - root.barHeight - 10
clip: true
ns: "calendar"
chipRoot: root
cardWidth: 284
Rectangle {
id: card
@@ -407,6 +356,5 @@ Rectangle {
Item { height: 4 }
}
}
}
}
}