Drop the dashboard's now-unused Open from clock toggle. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
31 lines
960 B
QML
31 lines
960 B
QML
import QtQuick
|
|
import Quickshell
|
|
import "../../components"
|
|
import "../../theme"
|
|
import "../../services"
|
|
import "../../core"
|
|
|
|
GlassPill {
|
|
id: root
|
|
readonly property var options: ConfigService.data.bar.clock
|
|
width: label.implicitWidth + 30
|
|
height: ModuleRegistry.pillHeight
|
|
SystemClock {
|
|
id: clock
|
|
precision: root.options.showSeconds ? SystemClock.Seconds : SystemClock.Minutes
|
|
}
|
|
Text {
|
|
id: label
|
|
anchors.centerIn: parent
|
|
text: Qt.formatDateTime(clock.date, (root.options.showDate ? "ddd, d MMM " : "") + (root.options.use24Hour ? "HH:mm" : "h:mm") + (root.options.showSeconds ? ":ss" : "") + (root.options.use24Hour ? "" : " AP"))
|
|
color: Theme.text
|
|
font.pixelSize: 13
|
|
}
|
|
// Clicking the clock toggles the Control Center.
|
|
MouseArea {
|
|
anchors.fill: parent
|
|
cursorShape: Qt.PointingHandCursor
|
|
onClicked: ShellState.toggleControlCenter()
|
|
}
|
|
}
|