Compare commits

...

3 commits

Author SHA1 Message Date
Benjamin Palko
c03d24de15 create ThemeComboBox 2025-09-16 10:33:55 -04:00
Benjamin Palko
7a04cccf0c should use Styling 2025-09-16 10:33:42 -04:00
Benjamin Palko
fdf61a0e90 remove font family from theme 2025-09-16 10:32:19 -04:00
4 changed files with 23 additions and 10 deletions

View file

@ -0,0 +1,20 @@
import qs.components
import qs.config
import QtQuick
StyledComboBox {
id: control
currentIndex: Theme.themes.indexOf(Theme.currentTheme)
model: Theme.themes
onActivated: index => {
Theme.currentTheme = Theme.themes[index];
}
Component.onCompleted: {
control.currentIndex = Theme.themes.indexOf(Theme.currentTheme);
Theme.onCurrentThemeChanged = () => {
Theme.themes.indexOf(Theme.currentTheme);
};
}
}

View file

@ -8,7 +8,6 @@ import Quickshell.Io
Singleton {
id: root
property string fontFamily: "JetBrainsMono Nerd Font"
property var palette: theme.palette
property alias themes: cache.themes

View file

@ -1,4 +1,5 @@
import qs.components
import qs.components.composite
import qs.config
import QtQuick
import QtQuick.Layouts
@ -10,16 +11,9 @@ StyledPane {
StyledText {
text: "Theme"
// font.bold: true
font.pixelSize: Styling.typography.textSize.lg
}
StyledComboBox {
currentIndex: Theme.themes.indexOf(Theme.currentTheme)
model: Theme.themes
onActivated: index => {
Theme.currentTheme = Theme.themes[index];
}
}
ThemeComboBox {}
}
}

View file

@ -55,7 +55,7 @@ StyledPanelWindow {
id: circle
radius: 150
borderColor: Styling.theme.base100
strokeColor: PomodoroService.state == "timer" ? Theme.palette.primary : Theme.palette.warning
strokeColor: PomodoroService.state == "timer" ? Styling.theme.primary : Styling.theme.warning
strokeWidth: 12
fillColor: button.hovered ? Styling.theme.primary : "transparent"
percentage: (PomodoroService.state == "timer" ? (PomodoroService.initialTime - PomodoroService.remainingTime) : PomodoroService.remainingTime) / PomodoroService.initialTime % 1