filedialog: styling tweaks
This commit is contained in:
parent
377a452fc1
commit
6ce68d5f5c
2 changed files with 126 additions and 104 deletions
|
|
@ -1,6 +1,7 @@
|
|||
import qs.services
|
||||
import qs.config
|
||||
import Quickshell
|
||||
import QtQuick
|
||||
import QtQuick.Layouts
|
||||
|
||||
FloatingWindow {
|
||||
|
|
@ -16,7 +17,6 @@ FloatingWindow {
|
|||
|
||||
RowLayout {
|
||||
anchors.fill: parent
|
||||
anchors.margins: Appearance.padding.normal
|
||||
|
||||
spacing: Appearance.spacing.normal
|
||||
|
||||
|
|
@ -38,4 +38,12 @@ FloatingWindow {
|
|||
}
|
||||
}
|
||||
}
|
||||
|
||||
Behavior on color {
|
||||
ColorAnimation {
|
||||
duration: Appearance.anim.durations.normal
|
||||
easing.type: Easing.BezierSpline
|
||||
easing.bezierCurve: Appearance.anim.curves.standard
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -6,11 +6,21 @@ import qs.config
|
|||
import QtQuick
|
||||
import QtQuick.Layouts
|
||||
|
||||
RowLayout {
|
||||
StyledRect {
|
||||
id: root
|
||||
|
||||
required property var dialog
|
||||
|
||||
implicitWidth: inner.implicitWidth + Appearance.padding.normal * 2
|
||||
implicitHeight: inner.implicitHeight + Appearance.padding.normal * 2
|
||||
|
||||
color: Colours.palette.m3surfaceContainer
|
||||
|
||||
RowLayout {
|
||||
id: inner
|
||||
|
||||
anchors.fill: parent
|
||||
anchors.margins: Appearance.padding.normal
|
||||
spacing: Appearance.spacing.small
|
||||
|
||||
Item {
|
||||
|
|
@ -19,6 +29,7 @@ RowLayout {
|
|||
|
||||
StateLayer {
|
||||
radius: Appearance.rounding.small
|
||||
disabled: root.dialog.cwd.length === 1
|
||||
|
||||
function onClicked(): void {
|
||||
root.dialog.cwd.pop();
|
||||
|
|
@ -30,6 +41,8 @@ RowLayout {
|
|||
|
||||
anchors.centerIn: parent
|
||||
text: "drive_folder_upload"
|
||||
color: root.dialog.cwd.length === 1 ? Colours.palette.m3outline : Colours.palette.m3onSurface
|
||||
grade: 200
|
||||
}
|
||||
}
|
||||
|
||||
|
|
@ -37,7 +50,7 @@ RowLayout {
|
|||
Layout.fillWidth: true
|
||||
|
||||
radius: Appearance.rounding.small
|
||||
color: Colours.palette.m3surfaceContainer
|
||||
color: Colours.palette.m3surfaceContainerHigh
|
||||
|
||||
implicitHeight: pathComponents.implicitHeight + pathComponents.anchors.margins * 2
|
||||
|
||||
|
|
@ -45,7 +58,7 @@ RowLayout {
|
|||
id: pathComponents
|
||||
|
||||
anchors.fill: parent
|
||||
anchors.margins: Appearance.padding.small
|
||||
anchors.margins: Appearance.padding.small / 2
|
||||
anchors.leftMargin: 0
|
||||
|
||||
spacing: Appearance.spacing.small
|
||||
|
|
@ -74,7 +87,7 @@ RowLayout {
|
|||
|
||||
Item {
|
||||
implicitWidth: homeIcon.implicitWidth + (homeIcon.active ? Appearance.padding.small : 0) + folderName.implicitWidth + Appearance.padding.normal * 2
|
||||
implicitHeight: Math.max(homeIcon.implicitHeight, folderName.implicitHeight) + Appearance.padding.small * 2
|
||||
implicitHeight: folderName.implicitHeight + Appearance.padding.small * 2
|
||||
|
||||
Loader {
|
||||
anchors.fill: parent
|
||||
|
|
@ -125,4 +138,5 @@ RowLayout {
|
|||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue