initial commit for media widget update + anim tokens restructure
C++ / fmt (pull_request) Successful in 4s
JS/TS / fmt (pull_request) Successful in 20s
JS/TS / lint (pull_request) Successful in 22s
Python / static (pull_request) Successful in 57s
Rust / fmt (pull_request) Successful in 1m2s
C++ / build (pull_request) Successful in 2m10s
Rust / build (pull_request) Successful in 1m50s
Rust / clippy (pull_request) Successful in 1m25s
Python / verify (pull_request) Successful in 2m58s
C++ / clang-tidy (pull_request) Successful in 7m8s
C++ / fmt (pull_request) Successful in 4s
JS/TS / fmt (pull_request) Successful in 20s
JS/TS / lint (pull_request) Successful in 22s
Python / static (pull_request) Successful in 57s
Rust / fmt (pull_request) Successful in 1m2s
C++ / build (pull_request) Successful in 2m10s
Rust / build (pull_request) Successful in 1m50s
Rust / clippy (pull_request) Successful in 1m25s
Python / verify (pull_request) Successful in 2m58s
C++ / clang-tidy (pull_request) Successful in 7m8s
This commit is contained in:
@@ -27,25 +27,25 @@ AnchorAnimation {
|
|||||||
if (type == AnchorAnim.DefaultSpatial)
|
if (type == AnchorAnim.DefaultSpatial)
|
||||||
return Tokens.anim.durations.expressiveDefaultSpatial;
|
return Tokens.anim.durations.expressiveDefaultSpatial;
|
||||||
if (type == AnchorAnim.SlowSpatial)
|
if (type == AnchorAnim.SlowSpatial)
|
||||||
return Tokens.anim.durations.large;
|
return Tokens.anim.durations.expressiveSlowSpatial;
|
||||||
|
|
||||||
const types = ["small", "normal", "large", "extraLarge"];
|
const types = ["small", "normal", "large", "extraLarge"];
|
||||||
const idx = type % 4;
|
const idx = type % 4; // 0-7 are the 4 standard types
|
||||||
return Tokens.anim.durations[types[idx]];
|
return Tokens.anim.durations[types[idx]];
|
||||||
}
|
}
|
||||||
easing.bezierCurve: {
|
easing: {
|
||||||
if (type == AnchorAnim.FastSpatial)
|
if (type == AnchorAnim.FastSpatial)
|
||||||
return Tokens.anim.curves.expressiveFastSpatial;
|
return Tokens.anim.expressiveFastSpatial;
|
||||||
if (type == AnchorAnim.DefaultSpatial)
|
if (type == AnchorAnim.DefaultSpatial)
|
||||||
return Tokens.anim.curves.expressiveDefaultSpatial;
|
return Tokens.anim.expressiveDefaultSpatial;
|
||||||
if (type == AnchorAnim.SlowSpatial)
|
if (type == AnchorAnim.SlowSpatial)
|
||||||
return Tokens.anim.curves.expressiveSlowSpatial;
|
return Tokens.anim.expressiveSlowSpatial;
|
||||||
|
|
||||||
if (type >= AnchorAnim.StandardSmall && type <= AnchorAnim.StandardExtraLarge)
|
if (type >= AnchorAnim.StandardSmall && type <= AnchorAnim.StandardExtraLarge)
|
||||||
return Tokens.anim.curves.standard;
|
return Tokens.anim.standard;
|
||||||
if (type >= AnchorAnim.EmphasizedSmall && type <= AnchorAnim.EmphasizedExtraLarge)
|
if (type >= AnchorAnim.EmphasizedSmall && type <= AnchorAnim.EmphasizedExtraLarge)
|
||||||
return Tokens.anim.curves.emphasized;
|
return Tokens.anim.emphasized;
|
||||||
|
|
||||||
return Tokens.anim.curves.expressiveDefaultSpatial;
|
return Tokens.anim.expressiveDefaultSpatial;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
+12
-12
@@ -30,34 +30,34 @@ NumberAnimation {
|
|||||||
if (type === Anim.DefaultSpatial)
|
if (type === Anim.DefaultSpatial)
|
||||||
return Tokens.anim.durations.expressiveDefaultSpatial;
|
return Tokens.anim.durations.expressiveDefaultSpatial;
|
||||||
if (type === Anim.SlowSpatial)
|
if (type === Anim.SlowSpatial)
|
||||||
return Tokens.anim.durations.large;
|
return Tokens.anim.durations.expressiveSlowSpatial;
|
||||||
if (type === Anim.FastEffects)
|
if (type === Anim.FastEffects)
|
||||||
return Tokens.anim.durations.expressiveFastEffects;
|
return Tokens.anim.durations.expressiveFastEffects;
|
||||||
if (type === Anim.DefaultEffects)
|
if (type === Anim.DefaultEffects)
|
||||||
return Tokens.anim.durations.expressiveEffects;
|
return Tokens.anim.durations.expressiveDefaultEffects;
|
||||||
if (type === Anim.SlowEffects)
|
if (type === Anim.SlowEffects)
|
||||||
return Tokens.anim.durations.expressiveSlowEffects;
|
return Tokens.anim.durations.expressiveSlowEffects;
|
||||||
|
|
||||||
const types = ["small", "normal", "large", "extraLarge"];
|
const types = ["small", "normal", "large", "extraLarge"];
|
||||||
const idx = type % 4;
|
const idx = type % 4; // 0-7 are the 4 standard types
|
||||||
return Tokens.anim.durations[types[idx]];
|
return Tokens.anim.durations[types[idx]];
|
||||||
}
|
}
|
||||||
easing.bezierCurve: {
|
easing: {
|
||||||
if (type === Anim.FastSpatial)
|
if (type === Anim.FastSpatial)
|
||||||
return Tokens.anim.curves.expressiveFastSpatial;
|
return Tokens.anim.expressiveFastSpatial;
|
||||||
if (type === Anim.DefaultSpatial)
|
if (type === Anim.DefaultSpatial)
|
||||||
return Tokens.anim.curves.expressiveDefaultSpatial;
|
return Tokens.anim.expressiveDefaultSpatial;
|
||||||
if (type === Anim.SlowSpatial)
|
if (type === Anim.SlowSpatial)
|
||||||
return Tokens.anim.curves.expressiveSlowSpatial;
|
return Tokens.anim.expressiveSlowSpatial;
|
||||||
if (type === Anim.FastEffects)
|
if (type === Anim.FastEffects)
|
||||||
return Tokens.anim.curves.expressiveFastEffects;
|
return Tokens.anim.expressiveFastEffects;
|
||||||
if (type === Anim.DefaultEffects)
|
if (type === Anim.DefaultEffects)
|
||||||
return Tokens.anim.curves.expressiveDefaultEffects;
|
return Tokens.anim.expressiveDefaultEffects;
|
||||||
if (type === Anim.SlowEffects)
|
if (type === Anim.SlowEffects)
|
||||||
return Tokens.anim.curves.expressiveSlowEffects;
|
return Tokens.anim.expressiveSlowEffects;
|
||||||
|
|
||||||
if (type >= Anim.EmphasizedSmall && type <= Anim.EmphasizedExtraLarge)
|
if (type >= Anim.EmphasizedSmall && type <= Anim.EmphasizedExtraLarge)
|
||||||
return Tokens.anim.curves.emphasized;
|
return Tokens.anim.emphasized;
|
||||||
return Tokens.anim.curves.standard;
|
return Tokens.anim.standard;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -107,7 +107,7 @@ Slider {
|
|||||||
|
|
||||||
Anim {
|
Anim {
|
||||||
duration: Tokens.anim.durations.normal / 2
|
duration: Tokens.anim.durations.normal / 2
|
||||||
easing.bezierCurve: Tokens.anim.curves.standardAccel
|
easing: Tokens.anim.standardAccel
|
||||||
property: "scale"
|
property: "scale"
|
||||||
target: icon
|
target: icon
|
||||||
to: 0
|
to: 0
|
||||||
@@ -119,7 +119,7 @@ Slider {
|
|||||||
|
|
||||||
Anim {
|
Anim {
|
||||||
duration: Tokens.anim.durations.normal / 2
|
duration: Tokens.anim.durations.normal / 2
|
||||||
easing.bezierCurve: Tokens.anim.curves.standardDecel
|
easing: Tokens.anim.standardDecel
|
||||||
property: "scale"
|
property: "scale"
|
||||||
target: icon
|
target: icon
|
||||||
to: 1
|
to: 1
|
||||||
|
|||||||
@@ -1,5 +1,6 @@
|
|||||||
import QtQuick
|
import QtQuick
|
||||||
import ZShell.Config
|
import ZShell.Config
|
||||||
|
import qs.Components
|
||||||
import qs.Services
|
import qs.Services
|
||||||
|
|
||||||
CustomRect {
|
CustomRect {
|
||||||
@@ -36,7 +37,7 @@ CustomRect {
|
|||||||
readonly property color onColor: !enabled ? disabledOnColor : internalChecked ? activeOnColor : inactiveOnColor
|
readonly property color onColor: !enabled ? disabledOnColor : internalChecked ? activeOnColor : inactiveOnColor
|
||||||
property real padding
|
property real padding
|
||||||
readonly property alias pressed: stateLayer.pressed
|
readonly property alias pressed: stateLayer.pressed
|
||||||
property real pressedRadius: Tokens.rounding.smallest
|
property real pressedRadius: Tokens.rounding.small
|
||||||
readonly property alias radiusAnim: radiusAnim
|
readonly property alias radiusAnim: radiusAnim
|
||||||
property bool radiusMorph: true
|
property bool radiusMorph: true
|
||||||
property alias shapeMorph: stateLayer.shapeMorph
|
property alias shapeMorph: stateLayer.shapeMorph
|
||||||
|
|||||||
+2
-58
@@ -2,62 +2,6 @@ import QtQuick
|
|||||||
import ZShell.Config
|
import ZShell.Config
|
||||||
|
|
||||||
ColorAnimation {
|
ColorAnimation {
|
||||||
enum Type {
|
duration: Tokens.anim.durations.expressiveSlowEffects
|
||||||
StandardSmall = 0,
|
easing: Tokens.anim.expressiveSlowEffects
|
||||||
Standard,
|
|
||||||
StandardLarge,
|
|
||||||
StandardExtraLarge,
|
|
||||||
EmphasizedSmall,
|
|
||||||
Emphasized,
|
|
||||||
EmphasizedLarge,
|
|
||||||
EmphasizedExtraLarge,
|
|
||||||
FastSpatial,
|
|
||||||
DefaultSpatial,
|
|
||||||
SlowSpatial,
|
|
||||||
FastEffects,
|
|
||||||
DefaultEffects,
|
|
||||||
SlowEffects
|
|
||||||
}
|
|
||||||
|
|
||||||
property int type: CAnim.DefaultSpatial
|
|
||||||
|
|
||||||
duration: {
|
|
||||||
if (type < CAnim.StandardSmall || type > Anim.SlowEffects)
|
|
||||||
return Tokens.anim.durations.normal;
|
|
||||||
|
|
||||||
if (type === CAnim.FastSpatial)
|
|
||||||
return Tokens.anim.durations.expressiveFastSpatial;
|
|
||||||
if (type === CAnim.DefaultSpatial)
|
|
||||||
return Tokens.anim.durations.expressiveDefaultSpatial;
|
|
||||||
if (type === CAnim.SlowSpatial)
|
|
||||||
return Tokens.anim.durations.large;
|
|
||||||
if (type === CAnim.FastEffects)
|
|
||||||
return Tokens.anim.durations.expressiveFastEffects;
|
|
||||||
if (type === CAnim.DefaultEffects)
|
|
||||||
return Tokens.anim.durations.expressiveEffects;
|
|
||||||
if (type === CAnim.SlowEffects)
|
|
||||||
return Tokens.anim.durations.expressiveSlowEffects;
|
|
||||||
|
|
||||||
const types = ["small", "normal", "large", "extraLarge"];
|
|
||||||
const idx = type % 4;
|
|
||||||
return Tokens.anim.durations[types[idx]];
|
|
||||||
}
|
|
||||||
easing.bezierCurve: {
|
|
||||||
if (type === CAnim.FastSpatial)
|
|
||||||
return Tokens.anim.curves.expressiveFastSpatial;
|
|
||||||
if (type === CAnim.DefaultSpatial)
|
|
||||||
return Tokens.anim.curves.expressiveDefaultSpatial;
|
|
||||||
if (type === CAnim.SlowSpatial)
|
|
||||||
return Tokens.anim.curves.expressiveSlowSpatial;
|
|
||||||
if (type === CAnim.FastEffects)
|
|
||||||
return Tokens.anim.curves.expressiveFastEffects;
|
|
||||||
if (type === CAnim.DefaultEffects)
|
|
||||||
return Tokens.anim.curves.expressiveDefaultEffects;
|
|
||||||
if (type === CAnim.SlowEffects)
|
|
||||||
return Tokens.anim.curves.expressiveSlowEffects;
|
|
||||||
|
|
||||||
if (type >= CAnim.EmphasizedSmall && type <= Anim.EmphasizedExtraLarge)
|
|
||||||
return Tokens.anim.curves.emphasized;
|
|
||||||
return Tokens.anim.curves.standard;
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -23,7 +23,7 @@ BusyIndicator {
|
|||||||
property real implicitSize: Tokens.font.size.normal * 3
|
property real implicitSize: Tokens.font.size.normal * 3
|
||||||
property real internalStrokeWidth: strokeWidth
|
property real internalStrokeWidth: strokeWidth
|
||||||
readonly property alias progress: manager.progress
|
readonly property alias progress: manager.progress
|
||||||
property real strokeWidth: Tokens.padding.small * 0.8
|
property real strokeWidth: Tokens.padding.extraSmall * 0.8
|
||||||
property alias type: manager.indeterminateAnimationType
|
property alias type: manager.indeterminateAnimationType
|
||||||
|
|
||||||
implicitHeight: implicitSize
|
implicitHeight: implicitSize
|
||||||
|
|||||||
@@ -21,7 +21,7 @@ Item {
|
|||||||
readonly property real size: Math.min(width, height)
|
readonly property real size: Math.min(width, height)
|
||||||
property int spacing: Tokens.spacing.small
|
property int spacing: Tokens.spacing.small
|
||||||
property int startAngle: -90
|
property int startAngle: -90
|
||||||
property int strokeWidth: Tokens.padding.small
|
property int strokeWidth: Tokens.padding.extraSmall
|
||||||
property int sweepAngle: 360
|
property int sweepAngle: 360
|
||||||
readonly property real thickness: strokeWidth * (1 + waveAmplitude) * 2
|
readonly property real thickness: strokeWidth * (1 + waveAmplitude) * 2
|
||||||
property real value
|
property real value
|
||||||
|
|||||||
@@ -23,7 +23,7 @@ CheckBox {
|
|||||||
color: Colors.palette.m3surfaceVariant
|
color: Colors.palette.m3surfaceVariant
|
||||||
implicitHeight: control.checkHeight
|
implicitHeight: control.checkHeight
|
||||||
implicitWidth: control.checkWidth
|
implicitWidth: control.checkWidth
|
||||||
radius: Tokens.rounding.smallest / 2
|
radius: Tokens.rounding.small / 2
|
||||||
|
|
||||||
CustomRect {
|
CustomRect {
|
||||||
color: Colors.palette.m3primary
|
color: Colors.palette.m3primary
|
||||||
|
|||||||
@@ -141,7 +141,7 @@ Slider {
|
|||||||
CAnim {
|
CAnim {
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
NumberAnimation on waveProgress {
|
Anim on waveProgress {
|
||||||
duration: root.waveDuration
|
duration: root.waveDuration
|
||||||
easing.type: Easing.Linear
|
easing.type: Easing.Linear
|
||||||
from: 0
|
from: 0
|
||||||
|
|||||||
@@ -38,9 +38,9 @@ DoubleSpinBox {
|
|||||||
horizontalAlignment: TextField.AlignHCenter
|
horizontalAlignment: TextField.AlignHCenter
|
||||||
implicitWidth: 65
|
implicitWidth: 65
|
||||||
inputMethodHints: Qt.ImhFormattedNumbersOnly
|
inputMethodHints: Qt.ImhFormattedNumbersOnly
|
||||||
leftPadding: Tokens.padding.larger
|
leftPadding: Tokens.padding.small
|
||||||
readOnly: !root.editable
|
readOnly: !root.editable
|
||||||
rightPadding: Tokens.padding.larger
|
rightPadding: Tokens.padding.small
|
||||||
text: root.textFromValue(root.value, root.locale)
|
text: root.textFromValue(root.value, root.locale)
|
||||||
validator: root.validator
|
validator: root.validator
|
||||||
|
|
||||||
|
|||||||
@@ -1,70 +0,0 @@
|
|||||||
pragma ComponentBehavior: Bound
|
|
||||||
|
|
||||||
import QtQuick
|
|
||||||
import QtQuick.Layouts
|
|
||||||
import ZShell.Config
|
|
||||||
import qs.Services
|
|
||||||
|
|
||||||
Item {
|
|
||||||
id: root
|
|
||||||
|
|
||||||
property alias active: splitButton.active
|
|
||||||
property alias buttonAlias: splitButton
|
|
||||||
property alias expanded: splitButton.expanded
|
|
||||||
property int expandedZ: 100
|
|
||||||
required property string label
|
|
||||||
property alias menuItems: splitButton.menuItems
|
|
||||||
property bool shouldBeActive: true
|
|
||||||
property alias type: splitButton.type
|
|
||||||
|
|
||||||
signal selected(item: MenuItem)
|
|
||||||
|
|
||||||
anchors.left: parent.left
|
|
||||||
anchors.right: parent.right
|
|
||||||
clip: false
|
|
||||||
implicitHeight: row.implicitHeight + Tokens.padding.smaller * 2
|
|
||||||
opacity: shouldBeActive ? 1 : 0
|
|
||||||
scale: shouldBeActive ? 1 : 0.8
|
|
||||||
z: splitButton.menu.implicitHeight > 0 ? expandedZ : 1
|
|
||||||
|
|
||||||
Behavior on opacity {
|
|
||||||
Anim {
|
|
||||||
}
|
|
||||||
}
|
|
||||||
Behavior on scale {
|
|
||||||
Anim {
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
RowLayout {
|
|
||||||
id: row
|
|
||||||
|
|
||||||
anchors.left: parent.left
|
|
||||||
anchors.margins: Tokens.padding.small
|
|
||||||
anchors.right: parent.right
|
|
||||||
anchors.verticalCenter: parent.verticalCenter
|
|
||||||
spacing: Tokens.spacing.normal
|
|
||||||
|
|
||||||
CustomText {
|
|
||||||
Layout.fillWidth: true
|
|
||||||
color: root.enabled ? Colors.palette.m3onSurface : Colors.palette.m3onSurfaceVariant
|
|
||||||
font.pointSize: Tokens.font.size.larger
|
|
||||||
text: root.label
|
|
||||||
}
|
|
||||||
|
|
||||||
CustomSplitButton {
|
|
||||||
id: splitButton
|
|
||||||
|
|
||||||
enabled: root.enabled
|
|
||||||
type: CustomSplitButton.Filled
|
|
||||||
z: 2
|
|
||||||
|
|
||||||
menu.onItemSelected: item => {
|
|
||||||
root.selected(item);
|
|
||||||
}
|
|
||||||
stateLayer.onClicked: {
|
|
||||||
splitButton.expanded = !splitButton.expanded;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
@@ -14,7 +14,7 @@ Switch {
|
|||||||
|
|
||||||
indicator: CustomRect {
|
indicator: CustomRect {
|
||||||
color: root.checked && root.enabled ? Colors.palette.m3primary : Colors.layer(Colors.palette.m3surfaceContainerHighest, root.cLayer)
|
color: root.checked && root.enabled ? Colors.palette.m3primary : Colors.layer(Colors.palette.m3surfaceContainerHighest, root.cLayer)
|
||||||
implicitHeight: Tokens.font.size.medium + Tokens.padding.normal * 2
|
implicitHeight: Tokens.font.size.larger + Tokens.padding.small * 2
|
||||||
implicitWidth: implicitHeight * 1.7
|
implicitWidth: implicitHeight * 1.7
|
||||||
radius: Tokens.rounding.full
|
radius: Tokens.rounding.full
|
||||||
|
|
||||||
@@ -92,7 +92,7 @@ Switch {
|
|||||||
|
|
||||||
anchors.centerIn: parent
|
anchors.centerIn: parent
|
||||||
asynchronous: true
|
asynchronous: true
|
||||||
height: parent.implicitHeight - Tokens.padding.larger
|
height: parent.implicitHeight - Tokens.padding.small
|
||||||
preferredRendererType: Shape.CurveRenderer
|
preferredRendererType: Shape.CurveRenderer
|
||||||
width: height
|
width: height
|
||||||
|
|
||||||
@@ -153,6 +153,6 @@ Switch {
|
|||||||
|
|
||||||
component PropAnim: PropertyAnimation {
|
component PropAnim: PropertyAnimation {
|
||||||
duration: Tokens.anim.durations.expressiveFastSpatial
|
duration: Tokens.anim.durations.expressiveFastSpatial
|
||||||
easing.bezierCurve: Tokens.anim.curves.expressiveFastSpatial
|
easing: Tokens.anim.expressiveFastSpatial
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -129,8 +129,8 @@ TextFieldBase {
|
|||||||
}
|
}
|
||||||
|
|
||||||
AnchorAnim {
|
AnchorAnim {
|
||||||
duration: Tokens.anim.durations.expressiveEffects
|
duration: Tokens.anim.durations.expressiveDefaultEffects
|
||||||
easing.bezierCurve: Tokens.anim.curves.expressiveEffects
|
easing: Tokens.anim.expressiveDefaultEffects
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@@ -140,7 +140,7 @@ TextFieldBase {
|
|||||||
|
|
||||||
active: root.leadingIcon
|
active: root.leadingIcon
|
||||||
anchors.left: parent.left
|
anchors.left: parent.left
|
||||||
anchors.leftMargin: Tokens.padding.normal
|
anchors.leftMargin: Tokens.padding.small
|
||||||
anchors.verticalCenter: parent.verticalCenter
|
anchors.verticalCenter: parent.verticalCenter
|
||||||
|
|
||||||
sourceComponent: MaterialIcon {
|
sourceComponent: MaterialIcon {
|
||||||
@@ -154,7 +154,7 @@ TextFieldBase {
|
|||||||
|
|
||||||
active: root.trailingIcon
|
active: root.trailingIcon
|
||||||
anchors.right: parent.right
|
anchors.right: parent.right
|
||||||
anchors.rightMargin: Tokens.padding.normal
|
anchors.rightMargin: Tokens.padding.small
|
||||||
anchors.verticalCenter: parent.verticalCenter
|
anchors.verticalCenter: parent.verticalCenter
|
||||||
|
|
||||||
sourceComponent: MaterialIcon {
|
sourceComponent: MaterialIcon {
|
||||||
|
|||||||
@@ -27,7 +27,7 @@ ButtonBase {
|
|||||||
return Colors.palette.m3onPrimary;
|
return Colors.palette.m3onPrimary;
|
||||||
return type === IconButton.Tonal ? Colors.palette.m3onSecondaryContainer : Colors.palette.m3onSurfaceVariant;
|
return type === IconButton.Tonal ? Colors.palette.m3onSecondaryContainer : Colors.palette.m3onSurfaceVariant;
|
||||||
}
|
}
|
||||||
padding: type === IconButton.Text ? Tokens.padding.extraSmall / 2 : Tokens.padding.small
|
padding: type === IconButton.Text ? Tokens.padding.extraSmall / 2 : Tokens.padding.extraSmall
|
||||||
|
|
||||||
MaterialIcon {
|
MaterialIcon {
|
||||||
id: label
|
id: label
|
||||||
|
|||||||
@@ -17,7 +17,7 @@ ButtonBase {
|
|||||||
return Colors.palette.m3primary;
|
return Colors.palette.m3primary;
|
||||||
return type === TextButton.Filled ? Colors.palette.m3onPrimary : Colors.palette.m3onSecondary;
|
return type === TextButton.Filled ? Colors.palette.m3onPrimary : Colors.palette.m3onSecondary;
|
||||||
}
|
}
|
||||||
horizontalPadding: Tokens.padding.larger
|
horizontalPadding: Tokens.padding.small
|
||||||
implicitHeight: row.implicitHeight + verticalPadding * 2
|
implicitHeight: row.implicitHeight + verticalPadding * 2
|
||||||
implicitWidth: row.implicitWidth + horizontalPadding * 2
|
implicitWidth: row.implicitWidth + horizontalPadding * 2
|
||||||
inactiveColor: {
|
inactiveColor: {
|
||||||
@@ -32,7 +32,7 @@ ButtonBase {
|
|||||||
return Colors.palette.m3primary;
|
return Colors.palette.m3primary;
|
||||||
return type === TextButton.Filled ? Colors.palette.m3onSurface : Colors.palette.m3onSecondaryContainer;
|
return type === TextButton.Filled ? Colors.palette.m3onSurface : Colors.palette.m3onSecondaryContainer;
|
||||||
}
|
}
|
||||||
verticalPadding: Tokens.padding.small
|
verticalPadding: Tokens.padding.extraSmall
|
||||||
|
|
||||||
RowLayout {
|
RowLayout {
|
||||||
id: row
|
id: row
|
||||||
|
|||||||
+5
-5
@@ -78,7 +78,7 @@ MouseArea {
|
|||||||
implicitHeight: column.implicitHeight + column.anchors.margins * 2
|
implicitHeight: column.implicitHeight + column.anchors.margins * 2
|
||||||
implicitWidth: Math.max(200, column.implicitWidth + column.anchors.margins * 2)
|
implicitWidth: Math.max(200, column.implicitWidth + column.anchors.margins * 2)
|
||||||
level: 2
|
level: 2
|
||||||
radius: Tokens.rounding.medium
|
radius: Tokens.rounding.large
|
||||||
x: {
|
x: {
|
||||||
watcher.transform;
|
watcher.transform;
|
||||||
const item = root.attachTo;
|
const item = root.attachTo;
|
||||||
@@ -132,9 +132,9 @@ MouseArea {
|
|||||||
|
|
||||||
Layout.fillWidth: true
|
Layout.fillWidth: true
|
||||||
color: Qt.alpha(Colors.palette.m3tertiaryContainer, active ? 1 : 0)
|
color: Qt.alpha(Colors.palette.m3tertiaryContainer, active ? 1 : 0)
|
||||||
implicitHeight: menuOptionRow.implicitHeight + Tokens.padding.larger * 2
|
implicitHeight: menuOptionRow.implicitHeight + Tokens.padding.medium * 2
|
||||||
implicitWidth: menuOptionRow.implicitWidth + Tokens.padding.larger * 2
|
implicitWidth: menuOptionRow.implicitWidth + Tokens.padding.medium * 2
|
||||||
radius: Tokens.rounding.small
|
radius: menu.radius - column.anchors.margins
|
||||||
|
|
||||||
Behavior on radius {
|
Behavior on radius {
|
||||||
Anim {
|
Anim {
|
||||||
@@ -157,7 +157,7 @@ MouseArea {
|
|||||||
id: menuOptionRow
|
id: menuOptionRow
|
||||||
|
|
||||||
anchors.fill: parent
|
anchors.fill: parent
|
||||||
anchors.margins: Tokens.padding.larger
|
anchors.margins: Tokens.padding.medium
|
||||||
spacing: Tokens.spacing.small
|
spacing: Tokens.spacing.small
|
||||||
|
|
||||||
MaterialIcon {
|
MaterialIcon {
|
||||||
|
|||||||
@@ -70,7 +70,7 @@ TextFieldBase {
|
|||||||
id: clearIcon
|
id: clearIcon
|
||||||
|
|
||||||
anchors.right: parent.right
|
anchors.right: parent.right
|
||||||
anchors.rightMargin: Tokens.padding.larger
|
anchors.rightMargin: Tokens.padding.small
|
||||||
anchors.verticalCenter: parent.verticalCenter
|
anchors.verticalCenter: parent.verticalCenter
|
||||||
enabled: root.text
|
enabled: root.text
|
||||||
icon: "clear"
|
icon: "clear"
|
||||||
|
|||||||
@@ -12,14 +12,14 @@ Row {
|
|||||||
}
|
}
|
||||||
|
|
||||||
property alias active: menu.active
|
property alias active: menu.active
|
||||||
property color color: type == CustomSplitButton.Filled ? Colors.palette.m3primary : Colors.palette.m3secondaryContainer
|
property color colour: type == SplitButton.Filled ? Colors.palette.m3primary : Colors.palette.m3secondaryContainer
|
||||||
property color disabledColor: Qt.alpha(Colors.palette.m3onSurface, 0.1)
|
property color disabledColor: Qt.alpha(Colors.palette.m3onSurface, 0.1)
|
||||||
property color disabledTextColor: Qt.alpha(Colors.palette.m3onSurface, 0.38)
|
property color disabledTextColor: Qt.alpha(Colors.palette.m3onSurface, 0.38)
|
||||||
readonly property alias expandBtn: expandBtn
|
readonly property alias expandBtn: expandBtn
|
||||||
property alias expanded: menu.expanded
|
property alias expanded: menu.expanded
|
||||||
property string fallbackIcon
|
property string fallbackIcon
|
||||||
property string fallbackText
|
property string fallbackText
|
||||||
property real horizontalPadding: Tokens.padding.larger
|
property real horizontalPadding: Tokens.padding.medium
|
||||||
readonly property alias iconLabel: iconLabel
|
readonly property alias iconLabel: iconLabel
|
||||||
readonly property alias label: label
|
readonly property alias label: label
|
||||||
readonly property alias menu: menu
|
readonly property alias menu: menu
|
||||||
@@ -27,20 +27,20 @@ Row {
|
|||||||
property bool menuOnTop
|
property bool menuOnTop
|
||||||
property real minLeftWidth
|
property real minLeftWidth
|
||||||
readonly property alias stateLayer: stateLayer
|
readonly property alias stateLayer: stateLayer
|
||||||
property color textColor: type == CustomSplitButton.Filled ? Colors.palette.m3onPrimary : Colors.palette.m3onSecondaryContainer
|
property color textColor: type == SplitButton.Filled ? Colors.palette.m3onPrimary : Colors.palette.m3onSecondaryContainer
|
||||||
readonly property alias textRow: textRow
|
readonly property alias textRow: textRow
|
||||||
property int type: CustomSplitButton.Filled
|
property int type: SplitButton.Filled
|
||||||
property real verticalPadding: Tokens.padding.small
|
property real verticalPadding: Tokens.padding.small
|
||||||
|
|
||||||
spacing: Math.floor(Tokens.spacing.extraSmall)
|
spacing: Math.floor(Tokens.spacing.extraSmall / 2)
|
||||||
|
|
||||||
CustomRect {
|
CustomRect {
|
||||||
bottomRightRadius: Tokens.rounding.small / 2
|
bottomRightRadius: Tokens.rounding.medium / 2
|
||||||
color: !root.enabled ? root.disabledColor : root.color
|
color: root.disabled ? root.disabledColor : root.colour
|
||||||
implicitHeight: expandBtn.implicitHeight
|
implicitHeight: expandBtn.implicitHeight
|
||||||
implicitWidth: Math.max(root.minLeftWidth, textRow.implicitWidth + root.horizontalPadding * 2)
|
implicitWidth: Math.max(root.minLeftWidth, textRow.implicitWidth + root.horizontalPadding * 2)
|
||||||
radius: implicitHeight / 2 * Math.min(1, Tokens.rounding.scale)
|
radius: implicitHeight / 2 * Math.min(1, Tokens.rounding.scale)
|
||||||
topRightRadius: Tokens.rounding.small / 2
|
topRightRadius: Tokens.rounding.medium / 2
|
||||||
|
|
||||||
StateLayer {
|
StateLayer {
|
||||||
id: stateLayer
|
id: stateLayer
|
||||||
@@ -92,10 +92,10 @@ Row {
|
|||||||
CustomRect {
|
CustomRect {
|
||||||
id: expandBtn
|
id: expandBtn
|
||||||
|
|
||||||
property real rad: root.expanded ? implicitHeight / 2 * Math.min(1, Tokens.rounding.scale) : Tokens.rounding.small / 2
|
property real rad: root.expanded ? implicitHeight / 2 * Math.min(1, Tokens.rounding.scale) : Tokens.rounding.medium / 2
|
||||||
|
|
||||||
bottomLeftRadius: rad
|
bottomLeftRadius: rad
|
||||||
color: !root.enabled ? root.disabledColor : root.color
|
color: !root.enabled ? root.disabledColor : root.colour
|
||||||
implicitHeight: expandIcon.implicitHeight + root.verticalPadding * 2
|
implicitHeight: expandIcon.implicitHeight + root.verticalPadding * 2
|
||||||
implicitWidth: implicitHeight
|
implicitWidth: implicitHeight
|
||||||
radius: implicitHeight / 2 * Math.min(1, Tokens.rounding.scale)
|
radius: implicitHeight / 2 * Math.min(1, Tokens.rounding.scale)
|
||||||
@@ -1,9 +1,8 @@
|
|||||||
import QtQuick
|
import QtQuick
|
||||||
import QtQuick.Shapes
|
import QtQuick.Shapes
|
||||||
import ZShell
|
import ZShell
|
||||||
import ZShell.Components
|
|
||||||
import qs.Helpers
|
|
||||||
import ZShell.Config
|
import ZShell.Config
|
||||||
|
import qs.Helpers
|
||||||
import qs.Services
|
import qs.Services
|
||||||
|
|
||||||
MouseArea {
|
MouseArea {
|
||||||
@@ -81,7 +80,7 @@ MouseArea {
|
|||||||
|
|
||||||
alwaysRunToEnd: true
|
alwaysRunToEnd: true
|
||||||
duration: Tokens.anim.durations.expressiveSlowEffects * 2
|
duration: Tokens.anim.durations.expressiveSlowEffects * 2
|
||||||
easing.bezierCurve: Tokens.anim.curves.standard
|
easing: Tokens.anim.standard
|
||||||
property: "circleRadius"
|
property: "circleRadius"
|
||||||
target: root
|
target: root
|
||||||
to: root.endRadius
|
to: root.endRadius
|
||||||
|
|||||||
@@ -14,7 +14,7 @@ ButtonBase {
|
|||||||
return Colors.palette.m3primary;
|
return Colors.palette.m3primary;
|
||||||
return type === TextButton.Filled ? Colors.palette.m3onPrimary : Colors.palette.m3onSecondary;
|
return type === TextButton.Filled ? Colors.palette.m3onPrimary : Colors.palette.m3onSecondary;
|
||||||
}
|
}
|
||||||
horizontalPadding: Tokens.padding.normal
|
horizontalPadding: Tokens.padding.small
|
||||||
implicitHeight: label.implicitHeight + verticalPadding * 2
|
implicitHeight: label.implicitHeight + verticalPadding * 2
|
||||||
implicitWidth: label.implicitWidth + horizontalPadding * 2
|
implicitWidth: label.implicitWidth + horizontalPadding * 2
|
||||||
inactiveColor: {
|
inactiveColor: {
|
||||||
@@ -29,7 +29,7 @@ ButtonBase {
|
|||||||
return Colors.palette.m3primary;
|
return Colors.palette.m3primary;
|
||||||
return type === TextButton.Filled ? Colors.palette.m3onSurface : Colors.palette.m3onSecondaryContainer;
|
return type === TextButton.Filled ? Colors.palette.m3onSurface : Colors.palette.m3onSecondaryContainer;
|
||||||
}
|
}
|
||||||
verticalPadding: Tokens.padding.small
|
verticalPadding: Tokens.padding.extraSmall
|
||||||
|
|
||||||
CustomText {
|
CustomText {
|
||||||
id: label
|
id: label
|
||||||
|
|||||||
@@ -36,7 +36,7 @@ TextField {
|
|||||||
color: Colors.palette.m3primary
|
color: Colors.palette.m3primary
|
||||||
implicitHeight: root.cursorRectangle.height
|
implicitHeight: root.cursorRectangle.height
|
||||||
implicitWidth: 1.5
|
implicitWidth: 1.5
|
||||||
radius: Tokens.rounding.large
|
radius: Tokens.rounding.largeIncreased
|
||||||
x: root.cursorRectangle.x
|
x: root.cursorRectangle.x
|
||||||
y: root.cursorRectangle.y
|
y: root.cursorRectangle.y
|
||||||
|
|
||||||
|
|||||||
@@ -32,8 +32,8 @@ CustomRect {
|
|||||||
return Colors.palette.m3errorContainer;
|
return Colors.palette.m3errorContainer;
|
||||||
return Colors.palette.m3surface;
|
return Colors.palette.m3surface;
|
||||||
}
|
}
|
||||||
implicitHeight: layout.implicitHeight + Tokens.padding.smaller * 2
|
implicitHeight: layout.implicitHeight + Tokens.padding.small * 2
|
||||||
radius: Tokens.rounding.normal
|
radius: Tokens.rounding.medium
|
||||||
|
|
||||||
Behavior on border.color {
|
Behavior on border.color {
|
||||||
CAnim {
|
CAnim {
|
||||||
@@ -52,10 +52,10 @@ CustomRect {
|
|||||||
id: layout
|
id: layout
|
||||||
|
|
||||||
anchors.fill: parent
|
anchors.fill: parent
|
||||||
anchors.leftMargin: Tokens.padding.normal
|
anchors.leftMargin: Tokens.padding.small
|
||||||
anchors.margins: Tokens.padding.smaller
|
anchors.margins: Tokens.padding.small
|
||||||
anchors.rightMargin: Tokens.padding.normal
|
anchors.rightMargin: Tokens.padding.small
|
||||||
spacing: Tokens.spacing.normal
|
spacing: Tokens.spacing.medium
|
||||||
|
|
||||||
CustomRect {
|
CustomRect {
|
||||||
color: {
|
color: {
|
||||||
@@ -67,9 +67,9 @@ CustomRect {
|
|||||||
return Colors.palette.m3error;
|
return Colors.palette.m3error;
|
||||||
return Colors.palette.m3surfaceContainerHigh;
|
return Colors.palette.m3surfaceContainerHigh;
|
||||||
}
|
}
|
||||||
implicitHeight: icon.implicitHeight + Tokens.padding.smaller * 2
|
implicitHeight: icon.implicitHeight + Tokens.padding.small * 2
|
||||||
implicitWidth: implicitHeight
|
implicitWidth: implicitHeight
|
||||||
radius: Tokens.rounding.normal
|
radius: Tokens.rounding.medium
|
||||||
|
|
||||||
MaterialIcon {
|
MaterialIcon {
|
||||||
id: icon
|
id: icon
|
||||||
|
|||||||
@@ -21,7 +21,7 @@ Item {
|
|||||||
}
|
}
|
||||||
return h;
|
return h;
|
||||||
}
|
}
|
||||||
implicitWidth: Config.utilities.sizes.toastWidth - Tokens.padding.normal * 2
|
implicitWidth: Config.utilities.sizes.toastWidth - Tokens.padding.small * 2
|
||||||
|
|
||||||
Repeater {
|
Repeater {
|
||||||
id: repeater
|
id: repeater
|
||||||
@@ -82,7 +82,7 @@ Item {
|
|||||||
Behavior on anchors.bottomMargin {
|
Behavior on anchors.bottomMargin {
|
||||||
Anim {
|
Anim {
|
||||||
duration: Tokens.anim.durations.expressiveDefaultSpatial
|
duration: Tokens.anim.durations.expressiveDefaultSpatial
|
||||||
easing.bezierCurve: Tokens.anim.curves.expressiveDefaultSpatial
|
easing: Tokens.anim.expressiveDefaultSpatial
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
Behavior on opacity {
|
Behavior on opacity {
|
||||||
@@ -105,7 +105,7 @@ Item {
|
|||||||
id: initAnim
|
id: initAnim
|
||||||
|
|
||||||
duration: Tokens.anim.durations.expressiveDefaultSpatial
|
duration: Tokens.anim.durations.expressiveDefaultSpatial
|
||||||
easing.bezierCurve: Tokens.anim.curves.expressiveDefaultSpatial
|
easing: Tokens.anim.expressiveDefaultSpatial
|
||||||
from: 0
|
from: 0
|
||||||
properties: "opacity,scale"
|
properties: "opacity,scale"
|
||||||
target: toast
|
target: toast
|
||||||
|
|||||||
+2
-2
@@ -111,7 +111,7 @@ Item {
|
|||||||
id: toasts
|
id: toasts
|
||||||
|
|
||||||
anchors.bottom: sidebar.visible ? parent.bottom : utilities.top
|
anchors.bottom: sidebar.visible ? parent.bottom : utilities.top
|
||||||
anchors.margins: Tokens.padding.normal
|
anchors.margins: Tokens.padding.small
|
||||||
anchors.right: sidebar.left
|
anchors.right: sidebar.left
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -161,7 +161,7 @@ Item {
|
|||||||
Behavior on offsetScale {
|
Behavior on offsetScale {
|
||||||
Anim {
|
Anim {
|
||||||
duration: Tokens.anim.durations.expressiveDefaultSpatial
|
duration: Tokens.anim.durations.expressiveDefaultSpatial
|
||||||
easing.bezierCurve: Tokens.anim.curves.expressiveDefaultSpatial
|
easing: Tokens.anim.expressiveDefaultSpatial
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
+9
-9
@@ -225,7 +225,7 @@ CustomWindow {
|
|||||||
implicitHeight: panels.dashboard.height * (geometry.horizontal ? 1 + extraExtent : 1)
|
implicitHeight: panels.dashboard.height * (geometry.horizontal ? 1 + extraExtent : 1)
|
||||||
implicitWidth: panels.dashboard.width * (geometry.horizontal ? 1 : 1 + extraExtent)
|
implicitWidth: panels.dashboard.width * (geometry.horizontal ? 1 : 1 + extraExtent)
|
||||||
panel: panels.dashboardWrapper
|
panel: panels.dashboardWrapper
|
||||||
radius: Tokens.rounding.normal
|
radius: Tokens.rounding.extraLarge
|
||||||
x: panels.dashboardWrapper.x + panels.dashboard.x + geometry.insetLeft(root.borderThickness) - (geometry.horizontal ? 0 : panels.dashboard.width * extraExtent)
|
x: panels.dashboardWrapper.x + panels.dashboard.x + geometry.insetLeft(root.borderThickness) - (geometry.horizontal ? 0 : panels.dashboard.width * extraExtent)
|
||||||
y: panels.dashboardWrapper.y + panels.dashboard.y + geometry.insetTop(root.borderThickness) - (geometry.horizontal && geometry.position !== "bottom" ? panels.dashboard.height * extraExtent : 0)
|
y: panels.dashboardWrapper.y + panels.dashboard.y + geometry.insetTop(root.borderThickness) - (geometry.horizontal && geometry.position !== "bottom" ? panels.dashboard.height * extraExtent : 0)
|
||||||
}
|
}
|
||||||
@@ -238,7 +238,7 @@ CustomWindow {
|
|||||||
deformAmount: 0.06
|
deformAmount: 0.06
|
||||||
implicitHeight: panels.launcher.height * (1 + extraHeight)
|
implicitHeight: panels.launcher.height * (1 + extraHeight)
|
||||||
panel: panels.launcher
|
panel: panels.launcher
|
||||||
radius: Tokens.rounding.smallest + 5
|
radius: Tokens.rounding.medium + (Tokens.padding.largeIncreased / 4)
|
||||||
y: panels.launcher.y + geometry.insetTop(root.borderThickness)
|
y: panels.launcher.y + geometry.insetTop(root.borderThickness)
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -267,7 +267,7 @@ CustomWindow {
|
|||||||
id: notifsBg
|
id: notifsBg
|
||||||
|
|
||||||
panel: panels.notifications
|
panel: panels.notifications
|
||||||
radius: Tokens.rounding.normal
|
radius: Tokens.rounding.medium
|
||||||
}
|
}
|
||||||
|
|
||||||
PanelBg {
|
PanelBg {
|
||||||
@@ -288,7 +288,7 @@ CustomWindow {
|
|||||||
implicitHeight: panels.popouts.height * (geometry.horizontal ? 1 + extraExtent : 1)
|
implicitHeight: panels.popouts.height * (geometry.horizontal ? 1 + extraExtent : 1)
|
||||||
implicitWidth: panels.popouts.width * (geometry.horizontal ? 1 : 1 + extraExtent)
|
implicitWidth: panels.popouts.width * (geometry.horizontal ? 1 : 1 + extraExtent)
|
||||||
panel: panels.popoutsWrapper
|
panel: panels.popoutsWrapper
|
||||||
radius: panels.popouts.current?.panelRadius ?? Tokens.rounding.normal
|
radius: panels.popouts.current?.panelRadius ?? Tokens.rounding.large
|
||||||
x: panels.popoutsWrapper.x + panels.popouts.x + geometry.insetLeft(root.borderThickness) - (geometry.horizontal ? 0 : panels.popouts.width * extraExtent)
|
x: panels.popoutsWrapper.x + panels.popouts.x + geometry.insetLeft(root.borderThickness) - (geometry.horizontal ? 0 : panels.popouts.width * extraExtent)
|
||||||
y: panels.popoutsWrapper.y + panels.popouts.y + geometry.insetTop(root.borderThickness) - (geometry.barOnTop ? panels.popouts.height * extraExtent : 0)
|
y: panels.popoutsWrapper.y + panels.popouts.y + geometry.insetTop(root.borderThickness) - (geometry.barOnTop ? panels.popouts.height * extraExtent : 0)
|
||||||
|
|
||||||
@@ -305,7 +305,7 @@ CustomWindow {
|
|||||||
implicitHeight: panels.resources.height
|
implicitHeight: panels.resources.height
|
||||||
implicitWidth: panels.resources.width
|
implicitWidth: panels.resources.width
|
||||||
panel: panels.resourcesWrapper
|
panel: panels.resourcesWrapper
|
||||||
radius: Tokens.rounding.large
|
radius: Tokens.rounding.largeIncreased + Tokens.padding.small
|
||||||
x: panels.resourcesWrapper.x + panels.resources.x + geometry.insetLeft(root.borderThickness)
|
x: panels.resourcesWrapper.x + panels.resources.x + geometry.insetLeft(root.borderThickness)
|
||||||
y: panels.resourcesWrapper.y + panels.resources.y + geometry.insetTop(root.borderThickness)
|
y: panels.resourcesWrapper.y + panels.resources.y + geometry.insetTop(root.borderThickness)
|
||||||
}
|
}
|
||||||
@@ -315,7 +315,7 @@ CustomWindow {
|
|||||||
|
|
||||||
deformAmount: 0.03
|
deformAmount: 0.03
|
||||||
panel: panels.settings
|
panel: panels.settings
|
||||||
radius: Tokens.rounding.large + Tokens.padding.normal
|
radius: Tokens.rounding.largeIncreased + Tokens.padding.small
|
||||||
}
|
}
|
||||||
|
|
||||||
PanelBg {
|
PanelBg {
|
||||||
@@ -323,7 +323,7 @@ CustomWindow {
|
|||||||
|
|
||||||
deformAmount: 0.08
|
deformAmount: 0.08
|
||||||
panel: panels.dock
|
panel: panels.dock
|
||||||
radius: Tokens.rounding.normal
|
radius: Tokens.rounding.medium
|
||||||
}
|
}
|
||||||
|
|
||||||
PanelBg {
|
PanelBg {
|
||||||
@@ -331,7 +331,7 @@ CustomWindow {
|
|||||||
|
|
||||||
deformAmount: 0.08
|
deformAmount: 0.08
|
||||||
panel: panels.drawing
|
panel: panels.drawing
|
||||||
radius: Tokens.rounding.normal
|
radius: Tokens.rounding.medium
|
||||||
}
|
}
|
||||||
|
|
||||||
PanelBg {
|
PanelBg {
|
||||||
@@ -462,7 +462,7 @@ CustomWindow {
|
|||||||
group: blobGroup
|
group: blobGroup
|
||||||
implicitHeight: panel.height
|
implicitHeight: panel.height
|
||||||
implicitWidth: panel.width
|
implicitWidth: panel.width
|
||||||
radius: Tokens.rounding.smallest
|
radius: Tokens.rounding.small
|
||||||
x: panel.x + geometry.insetLeft(root.borderThickness)
|
x: panel.x + geometry.insetLeft(root.borderThickness)
|
||||||
y: panel.y + geometry.insetTop(root.borderThickness)
|
y: panel.y + geometry.insetTop(root.borderThickness)
|
||||||
}
|
}
|
||||||
|
|||||||
+8
-8
@@ -18,7 +18,7 @@ ColumnLayout {
|
|||||||
Layout.fillHeight: true
|
Layout.fillHeight: true
|
||||||
Layout.fillWidth: false
|
Layout.fillWidth: false
|
||||||
Layout.preferredWidth: centerWidth
|
Layout.preferredWidth: centerWidth
|
||||||
spacing: Tokens.spacing.large * 2
|
spacing: Tokens.spacing.largeIncreased * 2
|
||||||
|
|
||||||
RowLayout {
|
RowLayout {
|
||||||
Layout.alignment: Qt.AlignHCenter
|
Layout.alignment: Qt.AlignHCenter
|
||||||
@@ -64,7 +64,7 @@ ColumnLayout {
|
|||||||
|
|
||||||
CustomClippingRect {
|
CustomClippingRect {
|
||||||
Layout.alignment: Qt.AlignHCenter
|
Layout.alignment: Qt.AlignHCenter
|
||||||
Layout.topMargin: Tokens.spacing.large * 2
|
Layout.topMargin: Tokens.spacing.largeIncreased * 2
|
||||||
color: Colors.tPalette.m3surfaceContainer
|
color: Colors.tPalette.m3surfaceContainer
|
||||||
implicitHeight: root.centerWidth / 2
|
implicitHeight: root.centerWidth / 2
|
||||||
implicitWidth: root.centerWidth / 2
|
implicitWidth: root.centerWidth / 2
|
||||||
@@ -99,7 +99,7 @@ ColumnLayout {
|
|||||||
Layout.alignment: Qt.AlignHCenter
|
Layout.alignment: Qt.AlignHCenter
|
||||||
color: Colors.tPalette.m3surfaceContainer
|
color: Colors.tPalette.m3surfaceContainer
|
||||||
focus: true
|
focus: true
|
||||||
implicitHeight: input.implicitHeight + Tokens.padding.small * 2
|
implicitHeight: input.implicitHeight + Tokens.padding.extraSmall * 2
|
||||||
implicitWidth: root.centerWidth * 0.8
|
implicitWidth: root.centerWidth * 0.8
|
||||||
radius: Tokens.rounding.full
|
radius: Tokens.rounding.full
|
||||||
|
|
||||||
@@ -130,11 +130,11 @@ ColumnLayout {
|
|||||||
id: input
|
id: input
|
||||||
|
|
||||||
anchors.fill: parent
|
anchors.fill: parent
|
||||||
anchors.margins: Tokens.padding.small
|
anchors.margins: Tokens.padding.extraSmall
|
||||||
spacing: Tokens.spacing.normal
|
spacing: Tokens.spacing.medium
|
||||||
|
|
||||||
Item {
|
Item {
|
||||||
implicitHeight: statusIcon.implicitHeight + Tokens.padding.small * 2
|
implicitHeight: statusIcon.implicitHeight + Tokens.padding.extraSmall * 2
|
||||||
implicitWidth: implicitHeight
|
implicitWidth: implicitHeight
|
||||||
|
|
||||||
MaterialIcon {
|
MaterialIcon {
|
||||||
@@ -174,7 +174,7 @@ ColumnLayout {
|
|||||||
|
|
||||||
CustomRect {
|
CustomRect {
|
||||||
color: root.greeter.buffer && !root.greeter.launching ? Colors.palette.m3primary : Colors.layer(Colors.palette.m3surfaceContainerHigh, 2)
|
color: root.greeter.buffer && !root.greeter.launching ? Colors.palette.m3primary : Colors.layer(Colors.palette.m3surfaceContainerHigh, 2)
|
||||||
implicitHeight: enterIcon.implicitHeight + Tokens.padding.small * 2
|
implicitHeight: enterIcon.implicitHeight + Tokens.padding.extraSmall * 2
|
||||||
implicitWidth: implicitHeight
|
implicitWidth: implicitHeight
|
||||||
radius: Tokens.rounding.full
|
radius: Tokens.rounding.full
|
||||||
|
|
||||||
@@ -200,7 +200,7 @@ ColumnLayout {
|
|||||||
|
|
||||||
Item {
|
Item {
|
||||||
Layout.fillWidth: true
|
Layout.fillWidth: true
|
||||||
Layout.topMargin: -Tokens.spacing.large
|
Layout.topMargin: -Tokens.spacing.largeIncreased
|
||||||
implicitHeight: Math.max(message.implicitHeight, stateMessage.implicitHeight)
|
implicitHeight: Math.max(message.implicitHeight, stateMessage.implicitHeight)
|
||||||
|
|
||||||
Behavior on implicitHeight {
|
Behavior on implicitHeight {
|
||||||
|
|||||||
+11
-11
@@ -30,11 +30,11 @@ NumberAnimation {
|
|||||||
if (type === Anim.DefaultSpatial)
|
if (type === Anim.DefaultSpatial)
|
||||||
return Tokens.anim.durations.expressiveDefaultSpatial;
|
return Tokens.anim.durations.expressiveDefaultSpatial;
|
||||||
if (type === Anim.SlowSpatial)
|
if (type === Anim.SlowSpatial)
|
||||||
return Tokens.anim.durations.large;
|
return Tokens.anim.durations.expressiveSlowSpatial;
|
||||||
if (type === Anim.FastEffects)
|
if (type === Anim.FastEffects)
|
||||||
return Tokens.anim.durations.expressiveFastEffects;
|
return Tokens.anim.durations.expressiveFastEffects;
|
||||||
if (type === Anim.DefaultEffects)
|
if (type === Anim.DefaultEffects)
|
||||||
return Tokens.anim.durations.expressiveEffects;
|
return Tokens.anim.durations.expressiveDefaultEffects;
|
||||||
if (type === Anim.SlowEffects)
|
if (type === Anim.SlowEffects)
|
||||||
return Tokens.anim.durations.expressiveSlowEffects;
|
return Tokens.anim.durations.expressiveSlowEffects;
|
||||||
|
|
||||||
@@ -42,22 +42,22 @@ NumberAnimation {
|
|||||||
const idx = type % 4; // 0-7 are the 4 standard types
|
const idx = type % 4; // 0-7 are the 4 standard types
|
||||||
return Tokens.anim.durations[types[idx]];
|
return Tokens.anim.durations[types[idx]];
|
||||||
}
|
}
|
||||||
easing.bezierCurve: {
|
easing: {
|
||||||
if (type === Anim.FastSpatial)
|
if (type === Anim.FastSpatial)
|
||||||
return Tokens.anim.curves.expressiveFastSpatial;
|
return Tokens.anim.expressiveFastSpatial;
|
||||||
if (type === Anim.DefaultSpatial)
|
if (type === Anim.DefaultSpatial)
|
||||||
return Tokens.anim.curves.expressiveDefaultSpatial;
|
return Tokens.anim.expressiveDefaultSpatial;
|
||||||
if (type === Anim.SlowSpatial)
|
if (type === Anim.SlowSpatial)
|
||||||
return Tokens.anim.curves.expressiveSlowSpatial;
|
return Tokens.anim.expressiveSlowSpatial;
|
||||||
if (type === Anim.FastEffects)
|
if (type === Anim.FastEffects)
|
||||||
return Tokens.anim.curves.expressiveFastEffects;
|
return Tokens.anim.expressiveFastEffects;
|
||||||
if (type === Anim.DefaultEffects)
|
if (type === Anim.DefaultEffects)
|
||||||
return Tokens.anim.curves.expressiveDefaultEffects;
|
return Tokens.anim.expressiveDefaultEffects;
|
||||||
if (type === Anim.SlowEffects)
|
if (type === Anim.SlowEffects)
|
||||||
return Tokens.anim.curves.expressiveSlowEffects;
|
return Tokens.anim.expressiveSlowEffects;
|
||||||
|
|
||||||
if (type >= Anim.EmphasizedSmall && type <= Anim.EmphasizedExtraLarge)
|
if (type >= Anim.EmphasizedSmall && type <= Anim.EmphasizedExtraLarge)
|
||||||
return Tokens.anim.curves.emphasized;
|
return Tokens.anim.emphasized;
|
||||||
return Tokens.anim.curves.standard;
|
return Tokens.anim.standard;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -2,62 +2,6 @@ import QtQuick
|
|||||||
import ZShell.Config
|
import ZShell.Config
|
||||||
|
|
||||||
ColorAnimation {
|
ColorAnimation {
|
||||||
enum Type {
|
duration: Tokens.anim.durations.expressiveSlowEffects
|
||||||
StandardSmall = 0,
|
easing: Tokens.anim.expressiveSlowEffects
|
||||||
Standard,
|
|
||||||
StandardLarge,
|
|
||||||
StandardExtraLarge,
|
|
||||||
EmphasizedSmall,
|
|
||||||
Emphasized,
|
|
||||||
EmphasizedLarge,
|
|
||||||
EmphasizedExtraLarge,
|
|
||||||
FastSpatial,
|
|
||||||
DefaultSpatial,
|
|
||||||
SlowSpatial,
|
|
||||||
FastEffects,
|
|
||||||
DefaultEffects,
|
|
||||||
SlowEffects
|
|
||||||
}
|
|
||||||
|
|
||||||
property int type: CAnim.DefaultSpatial
|
|
||||||
|
|
||||||
duration: {
|
|
||||||
if (type < CAnim.StandardSmall || type > Anim.SlowEffects)
|
|
||||||
return Tokens.anim.durations.normal;
|
|
||||||
|
|
||||||
if (type === CAnim.FastSpatial)
|
|
||||||
return Tokens.anim.durations.expressiveFastSpatial;
|
|
||||||
if (type === CAnim.DefaultSpatial)
|
|
||||||
return Tokens.anim.durations.expressiveDefaultSpatial;
|
|
||||||
if (type === CAnim.SlowSpatial)
|
|
||||||
return Tokens.anim.durations.large;
|
|
||||||
if (type === CAnim.FastEffects)
|
|
||||||
return Tokens.anim.durations.expressiveFastEffects;
|
|
||||||
if (type === CAnim.DefaultEffects)
|
|
||||||
return Tokens.anim.durations.expressiveEffects;
|
|
||||||
if (type === CAnim.SlowEffects)
|
|
||||||
return Tokens.anim.durations.expressiveSlowEffects;
|
|
||||||
|
|
||||||
const types = ["small", "normal", "large", "extraLarge"];
|
|
||||||
const idx = type % 4;
|
|
||||||
return Tokens.anim.durations[types[idx]];
|
|
||||||
}
|
|
||||||
easing.bezierCurve: {
|
|
||||||
if (type === CAnim.FastSpatial)
|
|
||||||
return Tokens.anim.curves.expressiveFastSpatial;
|
|
||||||
if (type === CAnim.DefaultSpatial)
|
|
||||||
return Tokens.anim.curves.expressiveDefaultSpatial;
|
|
||||||
if (type === CAnim.SlowSpatial)
|
|
||||||
return Tokens.anim.curves.expressiveSlowSpatial;
|
|
||||||
if (type === CAnim.FastEffects)
|
|
||||||
return Tokens.anim.curves.expressiveFastEffects;
|
|
||||||
if (type === CAnim.DefaultEffects)
|
|
||||||
return Tokens.anim.curves.expressiveDefaultEffects;
|
|
||||||
if (type === CAnim.SlowEffects)
|
|
||||||
return Tokens.anim.curves.expressiveSlowEffects;
|
|
||||||
|
|
||||||
if (type >= CAnim.EmphasizedSmall && type <= Anim.EmphasizedExtraLarge)
|
|
||||||
return Tokens.anim.curves.emphasized;
|
|
||||||
return Tokens.anim.curves.standard;
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -23,7 +23,7 @@ BusyIndicator {
|
|||||||
property real implicitSize: Tokens.font.size.normal * 3
|
property real implicitSize: Tokens.font.size.normal * 3
|
||||||
property real internalStrokeWidth: strokeWidth
|
property real internalStrokeWidth: strokeWidth
|
||||||
readonly property alias progress: manager.progress
|
readonly property alias progress: manager.progress
|
||||||
property real strokeWidth: Tokens.padding.small * 0.8
|
property real strokeWidth: Tokens.padding.extraSmall * 0.8
|
||||||
property alias type: manager.indeterminateAnimationType
|
property alias type: manager.indeterminateAnimationType
|
||||||
|
|
||||||
implicitHeight: implicitSize
|
implicitHeight: implicitSize
|
||||||
|
|||||||
@@ -21,7 +21,7 @@ Item {
|
|||||||
readonly property real size: Math.min(width, height)
|
readonly property real size: Math.min(width, height)
|
||||||
property int spacing: Tokens.spacing.small
|
property int spacing: Tokens.spacing.small
|
||||||
property int startAngle: -90
|
property int startAngle: -90
|
||||||
property int strokeWidth: Tokens.padding.small
|
property int strokeWidth: Tokens.padding.extraSmall
|
||||||
property int sweepAngle: 360
|
property int sweepAngle: 360
|
||||||
readonly property real thickness: strokeWidth * (1 + waveAmplitude) * 2
|
readonly property real thickness: strokeWidth * (1 + waveAmplitude) * 2
|
||||||
property real value
|
property real value
|
||||||
|
|||||||
@@ -27,7 +27,7 @@ TextField {
|
|||||||
|
|
||||||
color: Colors.palette.m3primary
|
color: Colors.palette.m3primary
|
||||||
implicitWidth: 2
|
implicitWidth: 2
|
||||||
radius: Tokens.rounding.normal
|
radius: Tokens.rounding.medium
|
||||||
|
|
||||||
Behavior on opacity {
|
Behavior on opacity {
|
||||||
Anim {
|
Anim {
|
||||||
|
|||||||
@@ -81,7 +81,7 @@ MouseArea {
|
|||||||
|
|
||||||
alwaysRunToEnd: true
|
alwaysRunToEnd: true
|
||||||
duration: Tokens.anim.durations.expressiveSlowEffects * 2
|
duration: Tokens.anim.durations.expressiveSlowEffects * 2
|
||||||
easing.bezierCurve: Tokens.anim.curves.standard
|
easing: Tokens.anim.standard
|
||||||
property: "circleRadius"
|
property: "circleRadius"
|
||||||
target: root
|
target: root
|
||||||
to: root.endRadius
|
to: root.endRadius
|
||||||
|
|||||||
+7
-7
@@ -11,18 +11,18 @@ RowLayout {
|
|||||||
required property var greeter
|
required property var greeter
|
||||||
required property real screenHeight
|
required property real screenHeight
|
||||||
|
|
||||||
spacing: Tokens.spacing.large * 2
|
spacing: Tokens.spacing.largeIncreased * 2
|
||||||
|
|
||||||
ColumnLayout {
|
ColumnLayout {
|
||||||
Layout.fillWidth: true
|
Layout.fillWidth: true
|
||||||
spacing: Tokens.spacing.normal
|
spacing: Tokens.spacing.medium
|
||||||
|
|
||||||
CustomRect {
|
CustomRect {
|
||||||
Layout.fillWidth: true
|
Layout.fillWidth: true
|
||||||
color: Colors.tPalette.m3surfaceContainer
|
color: Colors.tPalette.m3surfaceContainer
|
||||||
implicitHeight: weather.implicitHeight
|
implicitHeight: weather.implicitHeight
|
||||||
radius: Tokens.rounding.small
|
radius: Tokens.rounding.small
|
||||||
topLeftRadius: Tokens.rounding.large
|
topLeftRadius: Tokens.rounding.largeIncreased
|
||||||
|
|
||||||
WeatherInfo {
|
WeatherInfo {
|
||||||
id: weather
|
id: weather
|
||||||
@@ -34,7 +34,7 @@ RowLayout {
|
|||||||
CustomClippingRect {
|
CustomClippingRect {
|
||||||
Layout.fillHeight: true
|
Layout.fillHeight: true
|
||||||
Layout.fillWidth: true
|
Layout.fillWidth: true
|
||||||
bottomLeftRadius: Tokens.rounding.large
|
bottomLeftRadius: Tokens.rounding.largeIncreased
|
||||||
color: Colors.tPalette.m3surfaceContainer
|
color: Colors.tPalette.m3surfaceContainer
|
||||||
radius: Tokens.rounding.small
|
radius: Tokens.rounding.small
|
||||||
|
|
||||||
@@ -51,15 +51,15 @@ RowLayout {
|
|||||||
|
|
||||||
ColumnLayout {
|
ColumnLayout {
|
||||||
Layout.fillWidth: true
|
Layout.fillWidth: true
|
||||||
spacing: Tokens.spacing.normal
|
spacing: Tokens.spacing.medium
|
||||||
|
|
||||||
CustomRect {
|
CustomRect {
|
||||||
Layout.fillHeight: true
|
Layout.fillHeight: true
|
||||||
Layout.fillWidth: true
|
Layout.fillWidth: true
|
||||||
bottomRightRadius: Tokens.rounding.large
|
bottomRightRadius: Tokens.rounding.largeIncreased
|
||||||
color: Colors.tPalette.m3surfaceContainer
|
color: Colors.tPalette.m3surfaceContainer
|
||||||
radius: Tokens.rounding.small
|
radius: Tokens.rounding.small
|
||||||
topRightRadius: Tokens.rounding.large
|
topRightRadius: Tokens.rounding.largeIncreased
|
||||||
|
|
||||||
SessionDock {
|
SessionDock {
|
||||||
greeter: root.greeter
|
greeter: root.greeter
|
||||||
|
|||||||
@@ -43,7 +43,7 @@ Scope {
|
|||||||
ParallelAnimation {
|
ParallelAnimation {
|
||||||
Anim {
|
Anim {
|
||||||
duration: Tokens.anim.durations.expressiveFastSpatial
|
duration: Tokens.anim.durations.expressiveFastSpatial
|
||||||
easing.bezierCurve: Tokens.anim.curves.expressiveFastSpatial
|
easing: Tokens.anim.expressiveFastSpatial
|
||||||
property: "scale"
|
property: "scale"
|
||||||
target: lockContent
|
target: lockContent
|
||||||
to: 1
|
to: 1
|
||||||
@@ -65,7 +65,7 @@ Scope {
|
|||||||
|
|
||||||
Anim {
|
Anim {
|
||||||
duration: Tokens.anim.durations.expressiveDefaultSpatial
|
duration: Tokens.anim.durations.expressiveDefaultSpatial
|
||||||
easing.bezierCurve: Tokens.anim.curves.expressiveDefaultSpatial
|
easing: Tokens.anim.expressiveDefaultSpatial
|
||||||
property: "scale"
|
property: "scale"
|
||||||
target: content
|
target: content
|
||||||
to: 1
|
to: 1
|
||||||
@@ -74,12 +74,12 @@ Scope {
|
|||||||
Anim {
|
Anim {
|
||||||
property: "radius"
|
property: "radius"
|
||||||
target: lockBg
|
target: lockBg
|
||||||
to: Tokens.rounding.large * 1.5
|
to: Tokens.rounding.largeIncreased * 1.5
|
||||||
}
|
}
|
||||||
|
|
||||||
Anim {
|
Anim {
|
||||||
duration: Tokens.anim.durations.expressiveDefaultSpatial
|
duration: Tokens.anim.durations.expressiveDefaultSpatial
|
||||||
easing.bezierCurve: Tokens.anim.curves.expressiveDefaultSpatial
|
easing: Tokens.anim.expressiveDefaultSpatial
|
||||||
property: "implicitWidth"
|
property: "implicitWidth"
|
||||||
target: lockContent
|
target: lockContent
|
||||||
to: (win.screen?.height ?? 0) * Config.lock.sizes.heightMult * Config.lock.sizes.ratio
|
to: (win.screen?.height ?? 0) * Config.lock.sizes.heightMult * Config.lock.sizes.ratio
|
||||||
@@ -87,7 +87,7 @@ Scope {
|
|||||||
|
|
||||||
Anim {
|
Anim {
|
||||||
duration: Tokens.anim.durations.expressiveDefaultSpatial
|
duration: Tokens.anim.durations.expressiveDefaultSpatial
|
||||||
easing.bezierCurve: Tokens.anim.curves.expressiveDefaultSpatial
|
easing: Tokens.anim.expressiveDefaultSpatial
|
||||||
property: "implicitHeight"
|
property: "implicitHeight"
|
||||||
target: lockContent
|
target: lockContent
|
||||||
to: (win.screen?.height ?? 0) * Config.lock.sizes.heightMult
|
to: (win.screen?.height ?? 0) * Config.lock.sizes.heightMult
|
||||||
|
|||||||
@@ -113,7 +113,7 @@ Item {
|
|||||||
Behavior on scale {
|
Behavior on scale {
|
||||||
Anim {
|
Anim {
|
||||||
duration: Tokens.anim.durations.expressiveFastSpatial
|
duration: Tokens.anim.durations.expressiveFastSpatial
|
||||||
easing.bezierCurve: Tokens.anim.curves.expressiveFastSpatial
|
easing: Tokens.anim.expressiveFastSpatial
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -13,7 +13,7 @@ ColumnLayout {
|
|||||||
|
|
||||||
anchors.fill: parent
|
anchors.fill: parent
|
||||||
anchors.margins: Tokens.padding.large
|
anchors.margins: Tokens.padding.large
|
||||||
spacing: Tokens.spacing.smaller
|
spacing: Tokens.spacing.small
|
||||||
|
|
||||||
CustomText {
|
CustomText {
|
||||||
Layout.fillWidth: true
|
Layout.fillWidth: true
|
||||||
@@ -41,7 +41,7 @@ ColumnLayout {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
sourceComponent: ColumnLayout {
|
sourceComponent: ColumnLayout {
|
||||||
spacing: Tokens.spacing.large
|
spacing: Tokens.spacing.largeIncreased
|
||||||
|
|
||||||
MaterialIcon {
|
MaterialIcon {
|
||||||
Layout.alignment: Qt.AlignHCenter
|
Layout.alignment: Qt.AlignHCenter
|
||||||
@@ -79,8 +79,8 @@ ColumnLayout {
|
|||||||
|
|
||||||
anchors.left: parent?.left
|
anchors.left: parent?.left
|
||||||
anchors.right: parent?.right
|
anchors.right: parent?.right
|
||||||
implicitHeight: row.implicitHeight + Tokens.padding.normal * 2
|
implicitHeight: row.implicitHeight + Tokens.padding.small * 2
|
||||||
radius: Tokens.rounding.normal - Tokens.padding.smaller
|
radius: Tokens.rounding.medium - Tokens.padding.small
|
||||||
|
|
||||||
StateLayer {
|
StateLayer {
|
||||||
onClicked: {
|
onClicked: {
|
||||||
@@ -92,8 +92,8 @@ ColumnLayout {
|
|||||||
id: row
|
id: row
|
||||||
|
|
||||||
anchors.fill: parent
|
anchors.fill: parent
|
||||||
anchors.margins: Tokens.padding.normal
|
anchors.margins: Tokens.padding.small
|
||||||
spacing: Tokens.spacing.normal
|
spacing: Tokens.spacing.medium
|
||||||
|
|
||||||
MaterialIcon {
|
MaterialIcon {
|
||||||
color: session.index === sessions.currentIndex ? Colors.palette.m3onPrimary : Colors.palette.m3onSurfaceVariant
|
color: session.index === sessions.currentIndex ? Colors.palette.m3onPrimary : Colors.palette.m3onSurfaceVariant
|
||||||
@@ -129,13 +129,13 @@ ColumnLayout {
|
|||||||
color: Colors.palette.m3primary
|
color: Colors.palette.m3primary
|
||||||
implicitHeight: sessions.currentItem?.implicitHeight ?? 0
|
implicitHeight: sessions.currentItem?.implicitHeight ?? 0
|
||||||
implicitWidth: sessions.width
|
implicitWidth: sessions.width
|
||||||
radius: Tokens.rounding.normal - Tokens.padding.smaller
|
radius: Tokens.rounding.medium - Tokens.padding.small
|
||||||
y: sessions.currentItem?.y ?? 0
|
y: sessions.currentItem?.y ?? 0
|
||||||
|
|
||||||
Behavior on y {
|
Behavior on y {
|
||||||
Anim {
|
Anim {
|
||||||
duration: Tokens.anim.durations.small
|
duration: Tokens.anim.durations.small
|
||||||
easing.bezierCurve: Tokens.anim.curves.expressiveEffects
|
easing: Tokens.anim.expressiveDefaultEffects
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -14,7 +14,7 @@ ColumnLayout {
|
|||||||
|
|
||||||
anchors.fill: parent
|
anchors.fill: parent
|
||||||
anchors.margins: Tokens.padding.large
|
anchors.margins: Tokens.padding.large
|
||||||
spacing: Tokens.spacing.smaller
|
spacing: Tokens.spacing.small
|
||||||
|
|
||||||
CustomText {
|
CustomText {
|
||||||
Layout.fillWidth: true
|
Layout.fillWidth: true
|
||||||
@@ -42,7 +42,7 @@ ColumnLayout {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
sourceComponent: ColumnLayout {
|
sourceComponent: ColumnLayout {
|
||||||
spacing: Tokens.spacing.large
|
spacing: Tokens.spacing.largeIncreased
|
||||||
|
|
||||||
MaterialIcon {
|
MaterialIcon {
|
||||||
Layout.alignment: Qt.AlignHCenter
|
Layout.alignment: Qt.AlignHCenter
|
||||||
@@ -81,8 +81,8 @@ ColumnLayout {
|
|||||||
|
|
||||||
anchors.left: parent?.left
|
anchors.left: parent?.left
|
||||||
anchors.right: parent?.right
|
anchors.right: parent?.right
|
||||||
implicitHeight: row.implicitHeight + Tokens.padding.normal * 2
|
implicitHeight: row.implicitHeight + Tokens.padding.small * 2
|
||||||
radius: Tokens.rounding.normal - Tokens.padding.smaller
|
radius: Tokens.rounding.medium - Tokens.padding.small
|
||||||
|
|
||||||
StateLayer {
|
StateLayer {
|
||||||
onClicked: {
|
onClicked: {
|
||||||
@@ -94,8 +94,8 @@ ColumnLayout {
|
|||||||
id: row
|
id: row
|
||||||
|
|
||||||
anchors.fill: parent
|
anchors.fill: parent
|
||||||
anchors.margins: Tokens.padding.normal
|
anchors.margins: Tokens.padding.small
|
||||||
spacing: Tokens.spacing.normal
|
spacing: Tokens.spacing.medium
|
||||||
|
|
||||||
CustomClippingRect {
|
CustomClippingRect {
|
||||||
Layout.preferredHeight: 50
|
Layout.preferredHeight: 50
|
||||||
@@ -135,13 +135,13 @@ ColumnLayout {
|
|||||||
color: Colors.palette.m3primary
|
color: Colors.palette.m3primary
|
||||||
implicitHeight: users.currentItem?.implicitHeight ?? 0
|
implicitHeight: users.currentItem?.implicitHeight ?? 0
|
||||||
implicitWidth: users.width
|
implicitWidth: users.width
|
||||||
radius: Tokens.rounding.normal - Tokens.padding.smaller
|
radius: Tokens.rounding.medium - Tokens.padding.small
|
||||||
y: users.currentItem?.y ?? 0
|
y: users.currentItem?.y ?? 0
|
||||||
|
|
||||||
Behavior on y {
|
Behavior on y {
|
||||||
Anim {
|
Anim {
|
||||||
duration: Tokens.anim.durations.small
|
duration: Tokens.anim.durations.expressiveDefaultEffects
|
||||||
easing.bezierCurve: Tokens.anim.curves.expressiveEffects
|
easing: Tokens.anim.expressiveDefaultEffects
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -34,7 +34,7 @@ ColumnLayout {
|
|||||||
|
|
||||||
RowLayout {
|
RowLayout {
|
||||||
Layout.fillWidth: true
|
Layout.fillWidth: true
|
||||||
spacing: Tokens.spacing.large
|
spacing: Tokens.spacing.largeIncreased
|
||||||
|
|
||||||
MaterialIcon {
|
MaterialIcon {
|
||||||
animate: true
|
animate: true
|
||||||
@@ -67,7 +67,7 @@ ColumnLayout {
|
|||||||
}
|
}
|
||||||
|
|
||||||
Loader {
|
Loader {
|
||||||
Layout.rightMargin: Tokens.padding.smaller
|
Layout.rightMargin: Tokens.padding.small
|
||||||
active: root.width > 400
|
active: root.width > 400
|
||||||
visible: active
|
visible: active
|
||||||
|
|
||||||
@@ -103,12 +103,12 @@ ColumnLayout {
|
|||||||
|
|
||||||
Layout.bottomMargin: Tokens.padding.large * 2
|
Layout.bottomMargin: Tokens.padding.large * 2
|
||||||
Layout.fillWidth: true
|
Layout.fillWidth: true
|
||||||
Layout.topMargin: Tokens.spacing.smaller
|
Layout.topMargin: Tokens.spacing.small
|
||||||
active: root.rootHeight > 820
|
active: root.rootHeight > 820
|
||||||
visible: active
|
visible: active
|
||||||
|
|
||||||
sourceComponent: RowLayout {
|
sourceComponent: RowLayout {
|
||||||
spacing: Tokens.spacing.large
|
spacing: Tokens.spacing.largeIncreased
|
||||||
|
|
||||||
Repeater {
|
Repeater {
|
||||||
model: {
|
model: {
|
||||||
|
|||||||
+1
-1
@@ -391,7 +391,7 @@ Item {
|
|||||||
tool: root.tool
|
tool: root.tool
|
||||||
visible: root.mode === "edit"
|
visible: root.mode === "edit"
|
||||||
x: Math.max(8, Math.min(root.rsx + root.sw / 2 - width / 2, root.screen.width - width - 8))
|
x: Math.max(8, Math.min(root.rsx + root.sw / 2 - width / 2, root.screen.width - width - 8))
|
||||||
y: (root.rsy + root.sh + height + Tokens.padding.normal <= root.screen.height) ? root.rsy + root.sh + Tokens.padding.normal : (root.rsy - height - Tokens.padding.normal <= 0) ? root.rsy + root.sh - height - Tokens.padding.normal : root.rsy - height - Tokens.padding.normal
|
y: (root.rsy + root.sh + height + Tokens.padding.small <= root.screen.height) ? root.rsy + root.sh + Tokens.padding.small : (root.rsy - height - Tokens.padding.small <= 0) ? root.rsy + root.sh - height - Tokens.padding.small : root.rsy - height - Tokens.padding.small
|
||||||
|
|
||||||
onCancelRequested: root.cancel()
|
onCancelRequested: root.cancel()
|
||||||
onClearRequested: annotations.clearAll()
|
onClearRequested: annotations.clearAll()
|
||||||
|
|||||||
@@ -49,9 +49,9 @@ CustomRect {
|
|||||||
signal undoRequested
|
signal undoRequested
|
||||||
|
|
||||||
color: Colors.palette.m3surface
|
color: Colors.palette.m3surface
|
||||||
height: row.implicitHeight + Tokens.padding.normal * 2
|
height: row.implicitHeight + Tokens.padding.small * 2
|
||||||
radius: Tokens.rounding.full
|
radius: Tokens.rounding.full
|
||||||
width: row.implicitWidth + Tokens.padding.normal * 2
|
width: row.implicitWidth + Tokens.padding.small * 2
|
||||||
|
|
||||||
RowLayout {
|
RowLayout {
|
||||||
id: row
|
id: row
|
||||||
@@ -73,6 +73,7 @@ CustomRect {
|
|||||||
required property var modelData
|
required property var modelData
|
||||||
|
|
||||||
color: root.tool === modelData.id ? "#3584e4" : "transparent"
|
color: root.tool === modelData.id ? "#3584e4" : "transparent"
|
||||||
|
font.pointSize: Tokens.font.size.large
|
||||||
icon: tool.modelData.glyph
|
icon: tool.modelData.glyph
|
||||||
inactiveColor: root.tool === modelData.id ? Colors.palette.m3primary : "transparent"
|
inactiveColor: root.tool === modelData.id ? Colors.palette.m3primary : "transparent"
|
||||||
inactiveOnColor: root.tool === modelData.id ? Colors.palette.m3onPrimary : Colors.palette.m3onSurface
|
inactiveOnColor: root.tool === modelData.id ? Colors.palette.m3onPrimary : Colors.palette.m3onSurface
|
||||||
@@ -98,11 +99,11 @@ CustomRect {
|
|||||||
model: root.colorPalette
|
model: root.colorPalette
|
||||||
|
|
||||||
delegate: IconButton {
|
delegate: IconButton {
|
||||||
readonly property real buttonSize: toolRow.implicitHeight - Tokens.padding.normal
|
readonly property real buttonSize: toolRow.implicitHeight - Tokens.padding.small
|
||||||
required property color modelData
|
required property color modelData
|
||||||
|
|
||||||
fillWidth: false
|
fillWidth: false
|
||||||
font.pointSize: 0
|
font.pointSize: Tokens.font.size.large
|
||||||
icon: ""
|
icon: ""
|
||||||
implicitHeight: buttonSize
|
implicitHeight: buttonSize
|
||||||
implicitWidth: buttonSize
|
implicitWidth: buttonSize
|
||||||
@@ -127,6 +128,7 @@ CustomRect {
|
|||||||
spacing: Tokens.spacing.extraSmall
|
spacing: Tokens.spacing.extraSmall
|
||||||
|
|
||||||
IconButton {
|
IconButton {
|
||||||
|
font.pointSize: Tokens.font.size.large
|
||||||
icon: "undo"
|
icon: "undo"
|
||||||
inactiveColor: "transparent"
|
inactiveColor: "transparent"
|
||||||
inactiveOnColor: Colors.palette.m3onSurface
|
inactiveOnColor: Colors.palette.m3onSurface
|
||||||
@@ -138,6 +140,7 @@ CustomRect {
|
|||||||
}
|
}
|
||||||
|
|
||||||
IconButton {
|
IconButton {
|
||||||
|
font.pointSize: Tokens.font.size.large
|
||||||
icon: "delete_history"
|
icon: "delete_history"
|
||||||
inactiveColor: "transparent"
|
inactiveColor: "transparent"
|
||||||
inactiveOnColor: Colors.palette.m3onSurface
|
inactiveOnColor: Colors.palette.m3onSurface
|
||||||
@@ -149,6 +152,7 @@ CustomRect {
|
|||||||
}
|
}
|
||||||
|
|
||||||
IconButton {
|
IconButton {
|
||||||
|
font.pointSize: Tokens.font.size.large
|
||||||
icon: "content_copy"
|
icon: "content_copy"
|
||||||
inactiveColor: "transparent"
|
inactiveColor: "transparent"
|
||||||
inactiveOnColor: Colors.palette.m3onSurface
|
inactiveOnColor: Colors.palette.m3onSurface
|
||||||
@@ -160,6 +164,7 @@ CustomRect {
|
|||||||
}
|
}
|
||||||
|
|
||||||
IconButton {
|
IconButton {
|
||||||
|
font.pointSize: Tokens.font.size.large
|
||||||
icon: "delete_forever"
|
icon: "delete_forever"
|
||||||
inactiveColor: "transparent"
|
inactiveColor: "transparent"
|
||||||
inactiveOnColor: Colors.palette.m3onSurface
|
inactiveOnColor: Colors.palette.m3onSurface
|
||||||
@@ -171,6 +176,7 @@ CustomRect {
|
|||||||
}
|
}
|
||||||
|
|
||||||
IconButton {
|
IconButton {
|
||||||
|
font.pointSize: Tokens.font.size.large
|
||||||
icon: "check"
|
icon: "check"
|
||||||
inactiveColor: "transparent"
|
inactiveColor: "transparent"
|
||||||
inactiveOnColor: Colors.palette.m3onSurface
|
inactiveOnColor: Colors.palette.m3onSurface
|
||||||
|
|||||||
@@ -16,7 +16,7 @@ Item {
|
|||||||
required property bool fullscreen
|
required property bool fullscreen
|
||||||
readonly property bool horizontal: position !== "left"
|
readonly property bool horizontal: position !== "left"
|
||||||
property bool isHovered
|
property bool isHovered
|
||||||
readonly property int padding: Math.max(Tokens.padding.smaller, Config.bar.border)
|
readonly property int padding: Math.max(Tokens.padding.small, Config.bar.border)
|
||||||
required property Wrapper popouts
|
required property Wrapper popouts
|
||||||
required property ClipWrapper popoutsWrapper
|
required property ClipWrapper popoutsWrapper
|
||||||
required property string position
|
required property string position
|
||||||
|
|||||||
@@ -44,7 +44,7 @@ WidgetBase {
|
|||||||
}
|
}
|
||||||
required property GridLayout loader
|
required property GridLayout loader
|
||||||
required property Wrapper popouts
|
required property Wrapper popouts
|
||||||
readonly property real size: horizontal ? timeText.contentWidth + Tokens.padding.normal * 2 : verticalColumn.implicitHeight + Tokens.padding.larger * 2
|
readonly property real size: horizontal ? timeText.contentWidth + Tokens.padding.small * 2 : verticalColumn.implicitHeight + Tokens.padding.small * 2
|
||||||
required property PersistentProperties visibilities
|
required property PersistentProperties visibilities
|
||||||
|
|
||||||
color: visibilities.dashboard ? Colors.palette.m3primary : Colors.tPalette.m3surfaceContainer
|
color: visibilities.dashboard ? Colors.palette.m3primary : Colors.tPalette.m3surfaceContainer
|
||||||
@@ -72,7 +72,7 @@ WidgetBase {
|
|||||||
id: verticalColumn
|
id: verticalColumn
|
||||||
|
|
||||||
anchors.centerIn: parent
|
anchors.centerIn: parent
|
||||||
spacing: Tokens.padding.small ?? 2
|
spacing: Tokens.padding.extraSmall ?? 2
|
||||||
visible: !root.horizontal
|
visible: !root.horizontal
|
||||||
width: root.baseSize
|
width: root.baseSize
|
||||||
|
|
||||||
@@ -96,8 +96,8 @@ WidgetBase {
|
|||||||
|
|
||||||
Rectangle {
|
Rectangle {
|
||||||
Layout.alignment: Qt.AlignHCenter
|
Layout.alignment: Qt.AlignHCenter
|
||||||
Layout.bottomMargin: Tokens.padding.small ?? 2
|
Layout.bottomMargin: Tokens.padding.extraSmall ?? 2
|
||||||
Layout.topMargin: Tokens.padding.small ?? 2
|
Layout.topMargin: Tokens.padding.extraSmall ?? 2
|
||||||
color: root.contentColor
|
color: root.contentColor
|
||||||
height: 1
|
height: 1
|
||||||
implicitWidth: root.baseSize * 0.5
|
implicitWidth: root.baseSize * 0.5
|
||||||
|
|||||||
@@ -7,13 +7,13 @@ import qs.Helpers
|
|||||||
Row {
|
Row {
|
||||||
id: root
|
id: root
|
||||||
|
|
||||||
property real batHeight: Tokens.padding.smaller * 2
|
property real batHeight: Tokens.padding.small * 2
|
||||||
property real batWidth: Tokens.padding.larger * 2
|
property real batWidth: Tokens.padding.medium * 2
|
||||||
required property string devState
|
required property string devState
|
||||||
property real nubHeight: Tokens.padding.small
|
property real nubHeight: Tokens.padding.extraSmall
|
||||||
property real nubWidth: 2
|
property real nubWidth: 2
|
||||||
required property real percentage
|
required property real percentage
|
||||||
property real radius: Tokens.rounding.smallest / 2
|
property real radius: Tokens.rounding.small / 2
|
||||||
|
|
||||||
spacing: 1
|
spacing: 1
|
||||||
|
|
||||||
|
|||||||
@@ -12,8 +12,8 @@ WidgetBase {
|
|||||||
readonly property string currentMedia: (Players.active?.trackTitle ?? qsTr("No media")) || qsTr("Unknown title")
|
readonly property string currentMedia: (Players.active?.trackTitle ?? qsTr("No media")) || qsTr("Unknown title")
|
||||||
readonly property int textWidth: Math.min(metrics.width, 200)
|
readonly property int textWidth: Math.min(metrics.width, 200)
|
||||||
|
|
||||||
implicitHeight: horizontal ? baseSize : layout.implicitHeight + Tokens.padding.normal * 2
|
implicitHeight: horizontal ? baseSize : layout.implicitHeight + Tokens.padding.small * 2
|
||||||
implicitWidth: horizontal ? layout.implicitWidth + Tokens.padding.normal * 2 : baseSize
|
implicitWidth: horizontal ? layout.implicitWidth + Tokens.padding.small * 2 : baseSize
|
||||||
radius: Tokens.rounding.full
|
radius: Tokens.rounding.full
|
||||||
|
|
||||||
Behavior on implicitHeight {
|
Behavior on implicitHeight {
|
||||||
@@ -39,11 +39,11 @@ WidgetBase {
|
|||||||
GridLayout {
|
GridLayout {
|
||||||
id: layout
|
id: layout
|
||||||
|
|
||||||
anchors.bottomMargin: root.horizontal ? 0 : Tokens.padding.normal
|
anchors.bottomMargin: root.horizontal ? 0 : Tokens.padding.small
|
||||||
anchors.fill: parent
|
anchors.fill: parent
|
||||||
anchors.leftMargin: root.horizontal ? Tokens.padding.normal : 0
|
anchors.leftMargin: root.horizontal ? Tokens.padding.small : 0
|
||||||
anchors.rightMargin: root.horizontal ? Tokens.padding.normal : 0
|
anchors.rightMargin: root.horizontal ? Tokens.padding.small : 0
|
||||||
anchors.topMargin: root.horizontal ? 0 : Tokens.padding.normal
|
anchors.topMargin: root.horizontal ? 0 : Tokens.padding.small
|
||||||
columns: root.horizontal ? -1 : 1
|
columns: root.horizontal ? -1 : 1
|
||||||
|
|
||||||
Behavior on implicitWidth {
|
Behavior on implicitWidth {
|
||||||
|
|||||||
@@ -22,7 +22,7 @@ GridLayout {
|
|||||||
property bool warning: percentage * 100 >= warningThreshold
|
property bool warning: percentage * 100 >= warningThreshold
|
||||||
property int warningThreshold: 80
|
property int warningThreshold: 80
|
||||||
|
|
||||||
columnSpacing: Tokens.spacing.smaller
|
columnSpacing: Tokens.spacing.medium
|
||||||
columns: horizontal ? -1 : 1
|
columns: horizontal ? -1 : 1
|
||||||
percentage: 0
|
percentage: 0
|
||||||
|
|
||||||
@@ -49,7 +49,7 @@ GridLayout {
|
|||||||
}
|
}
|
||||||
|
|
||||||
CustomClippingRect {
|
CustomClippingRect {
|
||||||
Layout.preferredHeight: root.horizontal ? icon.implicitHeight - Tokens.padding.small : 4
|
Layout.preferredHeight: root.horizontal ? icon.implicitHeight - Tokens.padding.extraSmall : 4
|
||||||
Layout.preferredWidth: root.horizontal ? 4 : icon.implicitWidth
|
Layout.preferredWidth: root.horizontal ? 4 : icon.implicitWidth
|
||||||
color: Colors.layer(Colors.palette.m3surfaceContainerHigh, 2)
|
color: Colors.layer(Colors.palette.m3surfaceContainerHigh, 2)
|
||||||
radius: Tokens.rounding.full
|
radius: Tokens.rounding.full
|
||||||
|
|||||||
@@ -16,8 +16,8 @@ WidgetBase {
|
|||||||
|
|
||||||
clip: true
|
clip: true
|
||||||
color: visibilities.resources ? Colors.palette.m3primary : Colors.tPalette.m3surfaceContainer
|
color: visibilities.resources ? Colors.palette.m3primary : Colors.tPalette.m3surfaceContainer
|
||||||
implicitHeight: horizontal ? baseSize : gridLayout.implicitHeight + Tokens.padding.normal * 2
|
implicitHeight: horizontal ? baseSize : gridLayout.implicitHeight + Tokens.padding.medium * 2
|
||||||
implicitWidth: horizontal ? gridLayout.implicitWidth + Tokens.padding.larger * 2 : baseSize
|
implicitWidth: horizontal ? gridLayout.implicitWidth + Tokens.padding.medium * 2 : baseSize
|
||||||
radius: Tokens.rounding.full
|
radius: Tokens.rounding.full
|
||||||
|
|
||||||
StateLayer {
|
StateLayer {
|
||||||
@@ -32,7 +32,7 @@ WidgetBase {
|
|||||||
anchors.centerIn: parent
|
anchors.centerIn: parent
|
||||||
anchors.horizontalCenterOffset: root.horizontal ? 0 : 1
|
anchors.horizontalCenterOffset: root.horizontal ? 0 : 1
|
||||||
anchors.verticalCenterOffset: root.horizontal ? 0 : -3
|
anchors.verticalCenterOffset: root.horizontal ? 0 : -3
|
||||||
columnSpacing: Tokens.spacing.smaller
|
columnSpacing: Tokens.spacing.small
|
||||||
columns: root.horizontal ? -1 : 1
|
columns: root.horizontal ? -1 : 1
|
||||||
|
|
||||||
ServiceRef {
|
ServiceRef {
|
||||||
|
|||||||
@@ -30,8 +30,8 @@ WidgetBase {
|
|||||||
return i;
|
return i;
|
||||||
return -1;
|
return -1;
|
||||||
}
|
}
|
||||||
readonly property real size: horizontal ? grid.implicitWidth + Tokens.padding.small * 2 : grid.implicitHeight + Tokens.padding.small * 2
|
readonly property real size: horizontal ? grid.implicitWidth + grid.anchors.leftMargin + grid.anchors.rightMargin : grid.implicitHeight + grid.anchors.bottomMargin + grid.anchors.topMargin
|
||||||
readonly property int spacing: Tokens.spacing.normal / 2
|
readonly property int spacing: Tokens.spacing.medium / 2
|
||||||
|
|
||||||
// Entries that can shrink to nothing, spacing included
|
// Entries that can shrink to nothing, spacing included
|
||||||
function collapsed(entry: var): bool {
|
function collapsed(entry: var): bool {
|
||||||
@@ -40,13 +40,13 @@ WidgetBase {
|
|||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
|
|
||||||
bottomLeftRadius: horizontal ? Tokens.rounding.smallest / 2 : Tokens.rounding.full
|
bottomLeftRadius: horizontal ? Tokens.rounding.small / 2 : Tokens.rounding.full
|
||||||
color: Colors.tPalette.m3surfaceContainer
|
color: Colors.tPalette.m3surfaceContainer
|
||||||
implicitHeight: horizontal ? baseSize : size
|
implicitHeight: horizontal ? baseSize : size
|
||||||
implicitWidth: horizontal ? size : baseSize
|
implicitWidth: horizontal ? size : baseSize
|
||||||
radius: Tokens.rounding.full
|
radius: Tokens.rounding.full
|
||||||
topLeftRadius: Tokens.rounding.smallest / 2
|
topLeftRadius: Tokens.rounding.small / 2
|
||||||
topRightRadius: horizontal ? Tokens.rounding.full : Tokens.rounding.smallest / 2
|
topRightRadius: horizontal ? Tokens.rounding.full : Tokens.rounding.small / 2
|
||||||
|
|
||||||
Behavior on implicitHeight {
|
Behavior on implicitHeight {
|
||||||
enabled: !root.horizontal
|
enabled: !root.horizontal
|
||||||
@@ -64,11 +64,11 @@ WidgetBase {
|
|||||||
GridLayout {
|
GridLayout {
|
||||||
id: grid
|
id: grid
|
||||||
|
|
||||||
anchors.bottomMargin: root.horizontal ? 0 : Tokens.padding.small
|
anchors.bottomMargin: root.horizontal ? 0 : Tokens.padding.medium
|
||||||
anchors.fill: parent
|
anchors.fill: parent
|
||||||
anchors.leftMargin: root.horizontal ? Tokens.padding.small : 0
|
anchors.leftMargin: root.horizontal ? Tokens.padding.extraSmall : 0
|
||||||
anchors.rightMargin: root.horizontal ? Tokens.padding.small : 0
|
anchors.rightMargin: root.horizontal ? Tokens.padding.extraSmall : 0
|
||||||
anchors.topMargin: root.horizontal ? 0 : Tokens.padding.small
|
anchors.topMargin: root.horizontal ? 0 : Tokens.padding.extraSmall
|
||||||
columns: root.horizontal ? -1 : 1
|
columns: root.horizontal ? -1 : 1
|
||||||
|
|
||||||
Repeater {
|
Repeater {
|
||||||
|
|||||||
@@ -16,22 +16,26 @@ WidgetBase {
|
|||||||
readonly property alias items: repeater
|
readonly property alias items: repeater
|
||||||
readonly property alias layout: sysGrid
|
readonly property alias layout: sysGrid
|
||||||
required property GridLayout loader
|
required property GridLayout loader
|
||||||
readonly property int padding: Tokens.padding.small
|
readonly property int padding: Tokens.padding.extraSmall
|
||||||
required property Wrapper popouts
|
required property Wrapper popouts
|
||||||
readonly property real size: horizontal ? sysGrid.implicitWidth + Tokens.padding.small : sysGrid.implicitHeight + Tokens.padding.small
|
readonly property real size: horizontal ? sysGrid.implicitWidth + sysGrid.anchors.leftMargin + sysGrid.anchors.rightMargin : sysGrid.implicitHeight + sysGrid.anchors.topMargin + sysGrid.anchors.bottomMargin
|
||||||
|
|
||||||
bottomLeftRadius: horizontal ? Tokens.rounding.full : Tokens.rounding.smallest / 2
|
bottomLeftRadius: horizontal ? Tokens.rounding.full : Tokens.rounding.small / 2
|
||||||
bottomRightRadius: Tokens.rounding.smallest / 2
|
bottomRightRadius: Tokens.rounding.small / 2
|
||||||
color: Colors.tPalette.m3surfaceContainer
|
color: Colors.tPalette.m3surfaceContainer
|
||||||
implicitHeight: horizontal ? baseSize : size
|
implicitHeight: horizontal ? baseSize : size
|
||||||
implicitWidth: horizontal ? size : baseSize
|
implicitWidth: horizontal ? size : baseSize
|
||||||
radius: Tokens.rounding.full
|
radius: Tokens.rounding.full
|
||||||
topRightRadius: horizontal ? Tokens.rounding.smallest / 2 : Tokens.rounding.full
|
topRightRadius: horizontal ? Tokens.rounding.small / 2 : Tokens.rounding.full
|
||||||
|
|
||||||
GridLayout {
|
GridLayout {
|
||||||
id: sysGrid
|
id: sysGrid
|
||||||
|
|
||||||
|
anchors.bottomMargin: root.horizontal ? 0 : Tokens.padding.extraSmall
|
||||||
anchors.centerIn: parent
|
anchors.centerIn: parent
|
||||||
|
anchors.leftMargin: root.horizontal ? Tokens.padding.extraSmall : 0
|
||||||
|
anchors.rightMargin: root.horizontal ? Tokens.padding.extraSmall : 0
|
||||||
|
anchors.topMargin: root.horizontal ? 0 : Tokens.padding.extraSmall
|
||||||
columns: root.horizontal ? -1 : 1
|
columns: root.horizontal ? -1 : 1
|
||||||
rowSpacing: -2
|
rowSpacing: -2
|
||||||
|
|
||||||
@@ -46,6 +50,7 @@ WidgetBase {
|
|||||||
required property int index
|
required property int index
|
||||||
required property SystemTrayItem modelData
|
required property SystemTrayItem modelData
|
||||||
|
|
||||||
|
Layout.alignment: Qt.AlignHCenter | Qt.AlignVCenter
|
||||||
implicitHeight: 34
|
implicitHeight: 34
|
||||||
implicitWidth: 34
|
implicitWidth: 34
|
||||||
ind: index
|
ind: index
|
||||||
|
|||||||
@@ -12,7 +12,7 @@ import qs.Services
|
|||||||
Item {
|
Item {
|
||||||
id: root
|
id: root
|
||||||
|
|
||||||
property real activeWorkspaceMargin: Math.ceil(Tokens.padding.small / 2)
|
property real activeWorkspaceMargin: Math.ceil(Tokens.padding.medium / 4)
|
||||||
readonly property int effectiveActiveWorkspaceId: monitor?.activeWorkspace?.id ?? 1
|
readonly property int effectiveActiveWorkspaceId: monitor?.activeWorkspace?.id ?? 1
|
||||||
required property bool horizontal
|
required property bool horizontal
|
||||||
readonly property HyprlandMonitor monitor: Hyprland.monitorFor(root.screen)
|
readonly property HyprlandMonitor monitor: Hyprland.monitorFor(root.screen)
|
||||||
|
|||||||
@@ -15,12 +15,13 @@ import qs.Services
|
|||||||
Item {
|
Item {
|
||||||
id: root
|
id: root
|
||||||
|
|
||||||
readonly property int rounding: Tokens.rounding.small - Tokens.padding.small
|
readonly property int panelRadius: Tokens.rounding.largeIncreased + Tokens.padding.smaller
|
||||||
|
readonly property int rounding: panelRadius - Tokens.padding.smaller
|
||||||
readonly property int topMargin: 0
|
readonly property int topMargin: 0
|
||||||
required property var wrapper
|
required property var wrapper
|
||||||
|
|
||||||
implicitHeight: vol.implicitHeight + Tokens.padding.small * 2
|
implicitHeight: vol.implicitHeight + Tokens.padding.smaller * 2
|
||||||
implicitWidth: 500 + Tokens.padding.small * 2
|
implicitWidth: 500 + Tokens.padding.smaller * 2
|
||||||
|
|
||||||
CustomRect {
|
CustomRect {
|
||||||
anchors.left: parent.left
|
anchors.left: parent.left
|
||||||
@@ -28,7 +29,7 @@ Item {
|
|||||||
anchors.top: parent.top
|
anchors.top: parent.top
|
||||||
color: Colors.tPalette.m3surfaceContainer
|
color: Colors.tPalette.m3surfaceContainer
|
||||||
implicitHeight: parent.implicitHeight
|
implicitHeight: parent.implicitHeight
|
||||||
radius: Tokens.rounding.small
|
radius: root.rounding
|
||||||
y: parent.y
|
y: parent.y
|
||||||
|
|
||||||
Behavior on implicitHeight {
|
Behavior on implicitHeight {
|
||||||
@@ -41,7 +42,7 @@ Item {
|
|||||||
id: vol
|
id: vol
|
||||||
|
|
||||||
anchors.left: parent.left
|
anchors.left: parent.left
|
||||||
anchors.margins: Tokens.padding.small
|
anchors.margins: Tokens.padding.smaller
|
||||||
anchors.right: parent.right
|
anchors.right: parent.right
|
||||||
anchors.verticalCenter: parent.verticalCenter
|
anchors.verticalCenter: parent.verticalCenter
|
||||||
}
|
}
|
||||||
@@ -51,17 +52,17 @@ Item {
|
|||||||
|
|
||||||
CustomRect {
|
CustomRect {
|
||||||
Layout.fillWidth: true
|
Layout.fillWidth: true
|
||||||
Layout.preferredHeight: 65 + Tokens.spacing.smaller * 2
|
Layout.preferredHeight: 65 + Tokens.spacing.small * 2
|
||||||
Layout.topMargin: root.topMargin
|
Layout.topMargin: root.topMargin
|
||||||
color: Colors.tPalette.m3surfaceContainer
|
color: Colors.tPalette.m3surfaceContainer
|
||||||
radius: root.rounding
|
radius: root.rounding - vol.anchors.margins
|
||||||
|
|
||||||
ColumnLayout {
|
ColumnLayout {
|
||||||
anchors.bottomMargin: Tokens.padding.smaller
|
anchors.bottomMargin: Tokens.padding.small
|
||||||
anchors.fill: parent
|
anchors.fill: parent
|
||||||
anchors.leftMargin: Tokens.padding.larger
|
anchors.leftMargin: Tokens.padding.small
|
||||||
anchors.rightMargin: Tokens.padding.larger
|
anchors.rightMargin: Tokens.padding.small
|
||||||
anchors.topMargin: Tokens.padding.smaller
|
anchors.topMargin: Tokens.padding.small
|
||||||
|
|
||||||
RowLayout {
|
RowLayout {
|
||||||
Layout.fillHeight: true
|
Layout.fillHeight: true
|
||||||
@@ -82,12 +83,12 @@ Item {
|
|||||||
}
|
}
|
||||||
|
|
||||||
RowLayout {
|
RowLayout {
|
||||||
spacing: Tokens.spacing.large
|
spacing: Tokens.spacing.largeIncreased
|
||||||
|
|
||||||
CustomMouseArea {
|
CustomMouseArea {
|
||||||
Layout.bottomMargin: Tokens.padding.normal
|
Layout.bottomMargin: Tokens.padding.small
|
||||||
Layout.fillWidth: true
|
Layout.fillWidth: true
|
||||||
Layout.preferredHeight: Tokens.padding.larger * 3
|
Layout.preferredHeight: Tokens.padding.medium * 3
|
||||||
|
|
||||||
CustomSlider {
|
CustomSlider {
|
||||||
anchors.left: parent.left
|
anchors.left: parent.left
|
||||||
@@ -109,7 +110,7 @@ Item {
|
|||||||
}
|
}
|
||||||
|
|
||||||
CustomSwitch {
|
CustomSwitch {
|
||||||
Layout.bottomMargin: Tokens.padding.normal
|
Layout.bottomMargin: Tokens.padding.small
|
||||||
checked: !Audio.muted
|
checked: !Audio.muted
|
||||||
|
|
||||||
onToggled: {
|
onToggled: {
|
||||||
@@ -124,10 +125,10 @@ Item {
|
|||||||
|
|
||||||
CustomClippingRect {
|
CustomClippingRect {
|
||||||
Layout.fillWidth: true
|
Layout.fillWidth: true
|
||||||
Layout.preferredHeight: 65 + Tokens.spacing.smaller * 2
|
Layout.preferredHeight: 65 + Tokens.spacing.small * 2
|
||||||
Layout.topMargin: root.topMargin
|
Layout.topMargin: root.topMargin
|
||||||
color: Colors.tPalette.m3surfaceContainer
|
color: Colors.tPalette.m3surfaceContainer
|
||||||
radius: root.rounding
|
radius: root.rounding - vol.anchors.margins
|
||||||
|
|
||||||
PwNodePeakMonitor {
|
PwNodePeakMonitor {
|
||||||
id: sourcePeak
|
id: sourcePeak
|
||||||
@@ -151,11 +152,11 @@ Item {
|
|||||||
}
|
}
|
||||||
|
|
||||||
ColumnLayout {
|
ColumnLayout {
|
||||||
anchors.bottomMargin: Tokens.padding.smaller
|
anchors.bottomMargin: Tokens.padding.small
|
||||||
anchors.fill: parent
|
anchors.fill: parent
|
||||||
anchors.leftMargin: Tokens.padding.larger
|
anchors.leftMargin: Tokens.padding.small
|
||||||
anchors.rightMargin: Tokens.padding.larger
|
anchors.rightMargin: Tokens.padding.small
|
||||||
anchors.topMargin: Tokens.padding.smaller
|
anchors.topMargin: Tokens.padding.small
|
||||||
|
|
||||||
RowLayout {
|
RowLayout {
|
||||||
Layout.fillHeight: true
|
Layout.fillHeight: true
|
||||||
@@ -176,12 +177,12 @@ Item {
|
|||||||
}
|
}
|
||||||
|
|
||||||
RowLayout {
|
RowLayout {
|
||||||
spacing: Tokens.spacing.large
|
spacing: Tokens.spacing.largeIncreased
|
||||||
|
|
||||||
CustomMouseArea {
|
CustomMouseArea {
|
||||||
Layout.bottomMargin: Tokens.padding.normal
|
Layout.bottomMargin: Tokens.padding.small
|
||||||
Layout.fillWidth: true
|
Layout.fillWidth: true
|
||||||
Layout.preferredHeight: Tokens.padding.larger * 3
|
Layout.preferredHeight: Tokens.padding.medium * 3
|
||||||
|
|
||||||
CustomSlider {
|
CustomSlider {
|
||||||
anchors.left: parent.left
|
anchors.left: parent.left
|
||||||
@@ -203,7 +204,7 @@ Item {
|
|||||||
}
|
}
|
||||||
|
|
||||||
CustomSwitch {
|
CustomSwitch {
|
||||||
Layout.bottomMargin: Tokens.padding.normal
|
Layout.bottomMargin: Tokens.padding.small
|
||||||
checked: !Audio.sourceMuted
|
checked: !Audio.sourceMuted
|
||||||
|
|
||||||
onToggled: {
|
onToggled: {
|
||||||
@@ -236,10 +237,10 @@ Item {
|
|||||||
required property var modelData
|
required property var modelData
|
||||||
|
|
||||||
Layout.fillWidth: true
|
Layout.fillWidth: true
|
||||||
Layout.preferredHeight: 65 + Tokens.spacing.smaller * 2
|
Layout.preferredHeight: 65 + Tokens.spacing.small * 2
|
||||||
Layout.topMargin: root.topMargin
|
Layout.topMargin: root.topMargin
|
||||||
color: Colors.tPalette.m3surfaceContainer
|
color: Colors.tPalette.m3surfaceContainer
|
||||||
radius: root.rounding
|
radius: root.rounding - vol.anchors.margins
|
||||||
|
|
||||||
PwNodePeakMonitor {
|
PwNodePeakMonitor {
|
||||||
id: peak
|
id: peak
|
||||||
@@ -271,11 +272,11 @@ Item {
|
|||||||
}
|
}
|
||||||
|
|
||||||
ColumnLayout {
|
ColumnLayout {
|
||||||
anchors.bottomMargin: Tokens.padding.smaller
|
anchors.bottomMargin: Tokens.padding.small
|
||||||
anchors.fill: parent
|
anchors.fill: parent
|
||||||
anchors.leftMargin: Tokens.padding.larger
|
anchors.leftMargin: Tokens.padding.small
|
||||||
anchors.rightMargin: Tokens.padding.larger
|
anchors.rightMargin: Tokens.padding.small
|
||||||
anchors.topMargin: Tokens.padding.smaller
|
anchors.topMargin: Tokens.padding.small
|
||||||
|
|
||||||
RowLayout {
|
RowLayout {
|
||||||
Layout.fillHeight: true
|
Layout.fillHeight: true
|
||||||
@@ -297,12 +298,12 @@ Item {
|
|||||||
}
|
}
|
||||||
|
|
||||||
RowLayout {
|
RowLayout {
|
||||||
spacing: Tokens.spacing.large
|
spacing: Tokens.spacing.largeIncreased
|
||||||
|
|
||||||
CustomMouseArea {
|
CustomMouseArea {
|
||||||
Layout.bottomMargin: Tokens.padding.normal
|
Layout.bottomMargin: Tokens.padding.small
|
||||||
Layout.fillWidth: true
|
Layout.fillWidth: true
|
||||||
Layout.preferredHeight: Tokens.padding.larger * 3
|
Layout.preferredHeight: Tokens.padding.medium * 3
|
||||||
|
|
||||||
CustomSlider {
|
CustomSlider {
|
||||||
anchors.left: parent.left
|
anchors.left: parent.left
|
||||||
@@ -324,7 +325,7 @@ Item {
|
|||||||
}
|
}
|
||||||
|
|
||||||
CustomSwitch {
|
CustomSwitch {
|
||||||
Layout.bottomMargin: Tokens.padding.normal
|
Layout.bottomMargin: Tokens.padding.small
|
||||||
checked: !appBox.modelData.audio.muted
|
checked: !appBox.modelData.audio.muted
|
||||||
|
|
||||||
onToggled: {
|
onToggled: {
|
||||||
|
|||||||
@@ -58,7 +58,7 @@ Item {
|
|||||||
|
|
||||||
Anim {
|
Anim {
|
||||||
duration: content.animLength
|
duration: content.animLength
|
||||||
easing.bezierCurve: content.animCurve
|
easing: content.animCurve
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
Behavior on y {
|
Behavior on y {
|
||||||
@@ -66,7 +66,7 @@ Item {
|
|||||||
|
|
||||||
Anim {
|
Anim {
|
||||||
duration: content.animLength
|
duration: content.animLength
|
||||||
easing.bezierCurve: content.animCurve
|
easing: content.animCurve
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -81,6 +81,7 @@ Item {
|
|||||||
anchors.top: root.position === "top" ? parent.top : undefined
|
anchors.top: root.position === "top" ? parent.top : undefined
|
||||||
anchors.topMargin: (-implicitHeight - 5) * root.offsetScale
|
anchors.topMargin: (-implicitHeight - 5) * root.offsetScale
|
||||||
anchors.verticalCenter: root.horizontal ? undefined : parent.verticalCenter
|
anchors.verticalCenter: root.horizontal ? undefined : parent.verticalCenter
|
||||||
|
horizontal: root.horizontal
|
||||||
offsetScale: root.offsetScale
|
offsetScale: root.offsetScale
|
||||||
screen: root.screen
|
screen: root.screen
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -11,10 +11,11 @@ Item {
|
|||||||
|
|
||||||
readonly property Item current: currentPopout?.item ?? null
|
readonly property Item current: currentPopout?.item ?? null
|
||||||
readonly property Popout currentPopout: content.children.find(c => c.shouldBeActive) ?? null
|
readonly property Popout currentPopout: content.children.find(c => c.shouldBeActive) ?? null
|
||||||
|
required property bool horizontal
|
||||||
required property PopoutState popouts
|
required property PopoutState popouts
|
||||||
|
|
||||||
implicitHeight: (currentPopout?.implicitHeight ?? 0) + Tokens.padding.small * 2
|
implicitHeight: (currentPopout?.implicitHeight ?? 0) + Tokens.padding.smaller * 2
|
||||||
implicitWidth: (currentPopout?.implicitWidth ?? 0) + Tokens.padding.small * 2
|
implicitWidth: (currentPopout?.implicitWidth ?? 0) + Tokens.padding.smaller * 2
|
||||||
|
|
||||||
Item {
|
Item {
|
||||||
id: content
|
id: content
|
||||||
@@ -69,6 +70,7 @@ Item {
|
|||||||
name: "upower"
|
name: "upower"
|
||||||
|
|
||||||
sourceComponent: UPowerPopout {
|
sourceComponent: UPowerPopout {
|
||||||
|
horizontal: root.horizontal
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -99,7 +101,7 @@ Item {
|
|||||||
anchors.centerIn: opacity === 1 ? undefined : parent
|
anchors.centerIn: opacity === 1 ? undefined : parent
|
||||||
anchors.horizontalCenter: parent.horizontalCenter
|
anchors.horizontalCenter: parent.horizontalCenter
|
||||||
anchors.top: opacity === 1 ? parent.top : undefined
|
anchors.top: opacity === 1 ? parent.top : undefined
|
||||||
anchors.topMargin: 5
|
anchors.topMargin: Tokens.padding.smaller
|
||||||
opacity: 0
|
opacity: 0
|
||||||
scale: 0.8
|
scale: 0.8
|
||||||
|
|
||||||
|
|||||||
@@ -15,7 +15,7 @@ StackView {
|
|||||||
id: root
|
id: root
|
||||||
|
|
||||||
readonly property int itemHeight: 30
|
readonly property int itemHeight: 30
|
||||||
readonly property int panelRadius: ((itemHeight / 2) + Tokens.padding.small) * Tokens.rounding.scale
|
readonly property int panelRadius: ((itemHeight / 2) + Tokens.padding.extraSmall) * Tokens.rounding.scale
|
||||||
required property PopoutState popouts
|
required property PopoutState popouts
|
||||||
property int rootWidth: 0
|
property int rootWidth: 0
|
||||||
required property QsMenuHandle trayItem
|
required property QsMenuHandle trayItem
|
||||||
@@ -88,10 +88,10 @@ StackView {
|
|||||||
required property QsMenuEntry modelData
|
required property QsMenuEntry modelData
|
||||||
|
|
||||||
Layout.fillWidth: true
|
Layout.fillWidth: true
|
||||||
Layout.leftMargin: modelData.isSeparator ? Tokens.padding.normal : 0
|
Layout.leftMargin: modelData?.isSeparator ?? false ? Tokens.padding.small : 0
|
||||||
Layout.rightMargin: modelData.isSeparator ? Tokens.padding.normal : 0
|
Layout.rightMargin: modelData?.isSeparator ?? false ? Tokens.padding.small : 0
|
||||||
color: modelData.isSeparator ? Colors.palette.m3outlineVariant : "transparent"
|
color: modelData?.isSeparator ?? false ? Colors.palette.m3outlineVariant : "transparent"
|
||||||
implicitHeight: modelData.isSeparator ? (visible ? 1 : 0) : childrenLoader.item.implicitHeight
|
implicitHeight: modelData?.isSeparator ?? false ? (visible ? 1 : 0) : childrenLoader.item?.implicitHeight ?? 0
|
||||||
implicitWidth: childrenLoader.item?.implicitWidth ?? 0
|
implicitWidth: childrenLoader.item?.implicitWidth ?? 0
|
||||||
radius: Tokens.rounding.full
|
radius: Tokens.rounding.full
|
||||||
visible: index !== (menuOpener.children.values.length - 1) ? true : (modelData.isSeparator ? false : true)
|
visible: index !== (menuOpener.children.values.length - 1) ? true : (modelData.isSeparator ? false : true)
|
||||||
@@ -99,18 +99,18 @@ StackView {
|
|||||||
Loader {
|
Loader {
|
||||||
id: childrenLoader
|
id: childrenLoader
|
||||||
|
|
||||||
active: !item.modelData.isSeparator
|
active: !item.modelData?.isSeparator ?? false
|
||||||
anchors.fill: parent
|
anchors.fill: parent
|
||||||
asynchronous: true
|
asynchronous: true
|
||||||
|
|
||||||
sourceComponent: Item {
|
sourceComponent: Item {
|
||||||
property int iconWidth: icon.active ? icon.width + Tokens.spacing.normal + icon.anchors.rightMargin : 0
|
property int iconWidth: icon.active ? icon.width + Tokens.spacing.medium + icon.anchors.rightMargin : 0
|
||||||
|
|
||||||
implicitHeight: root.itemHeight
|
implicitHeight: root.itemHeight
|
||||||
implicitWidth: label.width + label.anchors.leftMargin * 2 + iconWidth + (expand.item?.width ?? 0)
|
implicitWidth: label.width + label.anchors.leftMargin * 2 + iconWidth + (expand.item?.width ?? 0)
|
||||||
|
|
||||||
StateLayer {
|
StateLayer {
|
||||||
enabled: item.modelData.enabled
|
enabled: item.modelData?.enabled ?? false
|
||||||
radius: item.radius
|
radius: item.radius
|
||||||
|
|
||||||
onClicked: {
|
onClicked: {
|
||||||
@@ -130,7 +130,7 @@ StackView {
|
|||||||
Loader {
|
Loader {
|
||||||
id: icon
|
id: icon
|
||||||
|
|
||||||
active: item.modelData.icon !== ""
|
active: item.modelData?.icon ?? "" !== ""
|
||||||
anchors.right: parent.right
|
anchors.right: parent.right
|
||||||
anchors.rightMargin: 10
|
anchors.rightMargin: 10
|
||||||
anchors.verticalCenter: parent.verticalCenter
|
anchors.verticalCenter: parent.verticalCenter
|
||||||
@@ -144,7 +144,7 @@ StackView {
|
|||||||
id: iconImage
|
id: iconImage
|
||||||
|
|
||||||
implicitSize: parent.implicitHeight
|
implicitSize: parent.implicitHeight
|
||||||
source: item.modelData.icon
|
source: item.modelData?.icon ?? Qt.url("")
|
||||||
visible: false
|
visible: false
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -163,20 +163,20 @@ StackView {
|
|||||||
anchors.left: parent.left
|
anchors.left: parent.left
|
||||||
anchors.leftMargin: 10
|
anchors.leftMargin: 10
|
||||||
anchors.verticalCenter: parent.verticalCenter
|
anchors.verticalCenter: parent.verticalCenter
|
||||||
color: item.modelData.enabled ? Colors.palette.m3onSurface : Colors.palette.m3outline
|
color: item.modelData?.enabled ?? false ? Colors.palette.m3onSurface : Colors.palette.m3outline
|
||||||
text: item.modelData.text
|
text: item.modelData?.text ?? ""
|
||||||
}
|
}
|
||||||
|
|
||||||
Loader {
|
Loader {
|
||||||
id: expand
|
id: expand
|
||||||
|
|
||||||
active: item.modelData.hasChildren
|
active: item.modelData?.hasChildren ?? false
|
||||||
anchors.right: parent.right
|
anchors.right: parent.right
|
||||||
anchors.verticalCenter: parent.verticalCenter
|
anchors.verticalCenter: parent.verticalCenter
|
||||||
asynchronous: true
|
asynchronous: true
|
||||||
|
|
||||||
sourceComponent: MaterialIcon {
|
sourceComponent: MaterialIcon {
|
||||||
color: item.modelData.enabled ? Colors.palette.m3onSurface : Colors.palette.m3outline
|
color: item.modelData?.enabled ?? false ? Colors.palette.m3onSurface : Colors.palette.m3outline
|
||||||
text: "chevron_right"
|
text: "chevron_right"
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -12,9 +12,10 @@ import qs.Services
|
|||||||
Column {
|
Column {
|
||||||
id: root
|
id: root
|
||||||
|
|
||||||
readonly property int panelRadius: ((profiles.height / 2) + Tokens.padding.small) * Tokens.rounding.scale
|
required property bool horizontal
|
||||||
|
readonly property int panelRadius: ((profiles.height / 2) + Tokens.padding.extraSmall) * Tokens.rounding.scale
|
||||||
|
|
||||||
spacing: Tokens.spacing.normal
|
spacing: Tokens.spacing.medium
|
||||||
|
|
||||||
Loader {
|
Loader {
|
||||||
active: Battery.isLaptop
|
active: Battery.isLaptop
|
||||||
@@ -24,6 +25,13 @@ Column {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Item {
|
||||||
|
id: padding
|
||||||
|
|
||||||
|
implicitHeight: root.horizontal ? 0 : Tokens.padding.small
|
||||||
|
implicitWidth: 1
|
||||||
|
}
|
||||||
|
|
||||||
Repeater {
|
Repeater {
|
||||||
model: Battery.allPeripherals
|
model: Battery.allPeripherals
|
||||||
|
|
||||||
@@ -33,9 +41,9 @@ Column {
|
|||||||
required property var modelData
|
required property var modelData
|
||||||
|
|
||||||
anchors.left: parent.left
|
anchors.left: parent.left
|
||||||
anchors.leftMargin: Tokens.padding.normal
|
anchors.leftMargin: Tokens.padding.small
|
||||||
anchors.right: parent.right
|
anchors.right: parent.right
|
||||||
anchors.rightMargin: Tokens.padding.normal
|
anchors.rightMargin: Tokens.padding.small
|
||||||
|
|
||||||
CustomText {
|
CustomText {
|
||||||
Layout.fillWidth: true
|
Layout.fillWidth: true
|
||||||
@@ -67,7 +75,7 @@ Column {
|
|||||||
}
|
}
|
||||||
|
|
||||||
anchors.left: parent.left
|
anchors.left: parent.left
|
||||||
anchors.leftMargin: Tokens.padding.normal
|
anchors.leftMargin: Tokens.padding.small
|
||||||
text: Battery.isLaptop ? qsTr("Time %1: %2").arg(Battery.onBattery ? "remaining" : "until charged").arg(Battery.onBattery ? formatSeconds(Battery.timeToEmpty, "Calculating...") : formatSeconds(Battery.timeToFull, "Fully charged!")) : qsTr("Power profile: %1").arg(PowerProfile.toString(PowerProfiles.profile))
|
text: Battery.isLaptop ? qsTr("Time %1: %2").arg(Battery.onBattery ? "remaining" : "until charged").arg(Battery.onBattery ? formatSeconds(Battery.timeToEmpty, "Calculating...") : formatSeconds(Battery.timeToFull, "Fully charged!")) : qsTr("Power profile: %1").arg(PowerProfile.toString(PowerProfiles.profile))
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -80,8 +88,8 @@ Column {
|
|||||||
sourceComponent: CustomRect {
|
sourceComponent: CustomRect {
|
||||||
color: Colors.palette.m3error
|
color: Colors.palette.m3error
|
||||||
implicitHeight: child.implicitHeight + Tokens.padding.large
|
implicitHeight: child.implicitHeight + Tokens.padding.large
|
||||||
implicitWidth: child.implicitWidth + Tokens.padding.larger * 2
|
implicitWidth: child.implicitWidth + Tokens.padding.small * 2
|
||||||
radius: Tokens.rounding.large
|
radius: Tokens.rounding.largeIncreased
|
||||||
|
|
||||||
Column {
|
Column {
|
||||||
id: child
|
id: child
|
||||||
@@ -138,7 +146,7 @@ Column {
|
|||||||
anchors.horizontalCenter: parent.horizontalCenter
|
anchors.horizontalCenter: parent.horizontalCenter
|
||||||
color: Colors.tPalette.m3surfaceContainer
|
color: Colors.tPalette.m3surfaceContainer
|
||||||
implicitHeight: indicator.height + Tokens.padding.extraSmall * 2
|
implicitHeight: indicator.height + Tokens.padding.extraSmall * 2
|
||||||
implicitWidth: saver.implicitHeight + balance.implicitHeight + perf.implicitHeight + Tokens.padding.larger * 2 + Tokens.spacing.small * 8
|
implicitWidth: saver.implicitHeight + balance.implicitHeight + perf.implicitHeight + Tokens.padding.small * 2 + Tokens.spacing.small * 8
|
||||||
radius: Tokens.rounding.full
|
radius: Tokens.rounding.full
|
||||||
|
|
||||||
CustomRect {
|
CustomRect {
|
||||||
@@ -219,8 +227,8 @@ Column {
|
|||||||
required property string icon
|
required property string icon
|
||||||
required property int profile
|
required property int profile
|
||||||
|
|
||||||
implicitHeight: icon.implicitHeight + Tokens.padding.small
|
implicitHeight: icon.implicitHeight + Tokens.padding.extraSmall
|
||||||
implicitWidth: icon.implicitHeight + Tokens.padding.small
|
implicitWidth: icon.implicitHeight + Tokens.padding.extraSmall
|
||||||
|
|
||||||
StateLayer {
|
StateLayer {
|
||||||
color: profiles.current === parent.icon ? Colors.palette.m3onPrimary : Colors.palette.m3onSurface
|
color: profiles.current === parent.icon ? Colors.palette.m3onPrimary : Colors.palette.m3onSurface
|
||||||
|
|||||||
@@ -13,13 +13,13 @@ CustomClippingRect {
|
|||||||
id: root
|
id: root
|
||||||
|
|
||||||
readonly property bool hasUpdates: Object.keys(Updates.updates)?.length > 0
|
readonly property bool hasUpdates: Object.keys(Updates.updates)?.length > 0
|
||||||
readonly property int itemHeight: 50 + Tokens.padding.smaller * 2
|
readonly property int itemHeight: 50 + Tokens.padding.small * 2
|
||||||
required property var wrapper
|
required property var wrapper
|
||||||
|
|
||||||
color: Colors.tPalette.m3surfaceContainer
|
color: Colors.tPalette.m3surfaceContainer
|
||||||
implicitHeight: hasUpdates ? updatesListLoader.item?.implicitHeight + Tokens.padding.small * 2 : noUpdatesLoader.item.height
|
implicitHeight: hasUpdates ? updatesListLoader.item?.implicitHeight + Tokens.padding.extraSmall * 2 : noUpdatesLoader.item.height
|
||||||
implicitWidth: hasUpdates ? updatesListLoader.item?.contentWidth + Tokens.padding.small * 2 : noUpdatesLoader.item.width
|
implicitWidth: hasUpdates ? updatesListLoader.item?.contentWidth + Tokens.padding.extraSmall * 2 : noUpdatesLoader.item.width
|
||||||
radius: Tokens.rounding.small
|
radius: Tokens.rounding.large - Tokens.padding.smaller
|
||||||
|
|
||||||
Loader {
|
Loader {
|
||||||
id: noUpdatesLoader
|
id: noUpdatesLoader
|
||||||
@@ -70,7 +70,7 @@ CustomClippingRect {
|
|||||||
displayMarginEnd: root.itemHeight
|
displayMarginEnd: root.itemHeight
|
||||||
implicitHeight: Math.min(contentHeight, (root.itemHeight + spacing) * 5 - spacing)
|
implicitHeight: Math.min(contentHeight, (root.itemHeight + spacing) * 5 - spacing)
|
||||||
implicitWidth: contentWidth
|
implicitWidth: contentWidth
|
||||||
spacing: Tokens.spacing.normal
|
spacing: Tokens.spacing.medium
|
||||||
|
|
||||||
delegate: CustomRect {
|
delegate: CustomRect {
|
||||||
id: update
|
id: update
|
||||||
@@ -81,12 +81,12 @@ CustomClippingRect {
|
|||||||
color: Colors.tPalette.m3surfaceContainer
|
color: Colors.tPalette.m3surfaceContainer
|
||||||
implicitHeight: root.itemHeight
|
implicitHeight: root.itemHeight
|
||||||
implicitWidth: 600
|
implicitWidth: 600
|
||||||
radius: Tokens.rounding.small - Tokens.padding.small
|
radius: root.radius - Tokens.padding.extraSmall
|
||||||
|
|
||||||
RowLayout {
|
RowLayout {
|
||||||
anchors.fill: parent
|
anchors.fill: parent
|
||||||
anchors.leftMargin: Tokens.padding.smaller
|
anchors.leftMargin: Tokens.padding.small
|
||||||
anchors.rightMargin: Tokens.padding.smaller
|
anchors.rightMargin: Tokens.padding.small
|
||||||
|
|
||||||
MaterialIcon {
|
MaterialIcon {
|
||||||
font.pointSize: Tokens.font.size.large * 2
|
font.pointSize: Tokens.font.size.large * 2
|
||||||
|
|||||||
@@ -8,7 +8,7 @@ import ZShell.Config
|
|||||||
Item {
|
Item {
|
||||||
id: root
|
id: root
|
||||||
|
|
||||||
property list<real> animCurve: Tokens.anim.curves.expressiveDefaultSpatial
|
property var animCurve: Tokens.anim.expressiveDefaultSpatial
|
||||||
property int animLength: Tokens.anim.durations.expressiveDefaultSpatial
|
property int animLength: Tokens.anim.durations.expressiveDefaultSpatial
|
||||||
readonly property alias content: content
|
readonly property alias content: content
|
||||||
readonly property Item current: (content.item as Content)?.current ?? null
|
readonly property Item current: (content.item as Content)?.current ?? null
|
||||||
@@ -16,6 +16,7 @@ Item {
|
|||||||
property alias currentName: popoutState.currentName
|
property alias currentName: popoutState.currentName
|
||||||
property string detachedMode
|
property string detachedMode
|
||||||
property alias hasCurrent: popoutState.hasCurrent
|
property alias hasCurrent: popoutState.hasCurrent
|
||||||
|
required property bool horizontal
|
||||||
readonly property real nonAnimHeight: content.implicitHeight || 150
|
readonly property real nonAnimHeight: content.implicitHeight || 150
|
||||||
readonly property real nonAnimWidth: children.find(c => c.shouldBeActive)?.implicitWidth ?? content.implicitWidth
|
readonly property real nonAnimWidth: children.find(c => c.shouldBeActive)?.implicitWidth ?? content.implicitWidth
|
||||||
required property real offsetScale
|
required property real offsetScale
|
||||||
@@ -35,7 +36,7 @@ Item {
|
|||||||
|
|
||||||
Anim {
|
Anim {
|
||||||
duration: root.animLength
|
duration: root.animLength
|
||||||
easing.bezierCurve: root.animCurve
|
easing: root.animCurve
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
Behavior on implicitWidth {
|
Behavior on implicitWidth {
|
||||||
@@ -43,7 +44,7 @@ Item {
|
|||||||
|
|
||||||
Anim {
|
Anim {
|
||||||
duration: root.animLength
|
duration: root.animLength
|
||||||
easing.bezierCurve: root.animCurve
|
easing: root.animCurve
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -58,6 +59,7 @@ Item {
|
|||||||
shouldBeActive: root.hasCurrent
|
shouldBeActive: root.hasCurrent
|
||||||
|
|
||||||
sourceComponent: Content {
|
sourceComponent: Content {
|
||||||
|
horizontal: root.horizontal
|
||||||
popouts: popoutState
|
popouts: popoutState
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -59,7 +59,7 @@ Item {
|
|||||||
|
|
||||||
anchors.bottom: parent.bottom
|
anchors.bottom: parent.bottom
|
||||||
anchors.left: entries.right
|
anchors.left: entries.right
|
||||||
anchors.leftMargin: Tokens.spacing.normal
|
anchors.leftMargin: Tokens.spacing.medium
|
||||||
anchors.top: parent.top
|
anchors.top: parent.top
|
||||||
color: Colors.tPalette.m3surfaceContainer
|
color: Colors.tPalette.m3surfaceContainer
|
||||||
implicitWidth: ClipHistory.previewIsImage ? Math.max(Math.min(imagePreview.sourceSize.width + Tokens.padding.large * 2, Config.clipboard.sizes.previewWidth), Config.clipboard.sizes.minPreviewWidth) : Math.max(Math.min(textPreviewColumn.width + textPreviewColumn.anchors.margins * 2, Config.clipboard.sizes.previewWidth), Config.clipboard.sizes.minPreviewWidth)
|
implicitWidth: ClipHistory.previewIsImage ? Math.max(Math.min(imagePreview.sourceSize.width + Tokens.padding.large * 2, Config.clipboard.sizes.previewWidth), Config.clipboard.sizes.minPreviewWidth) : Math.max(Math.min(textPreviewColumn.width + textPreviewColumn.anchors.margins * 2, Config.clipboard.sizes.previewWidth), Config.clipboard.sizes.minPreviewWidth)
|
||||||
@@ -75,7 +75,7 @@ Item {
|
|||||||
|
|
||||||
anchors.left: parent.left
|
anchors.left: parent.left
|
||||||
anchors.leftMargin: 0
|
anchors.leftMargin: 0
|
||||||
anchors.margins: Tokens.padding.normal
|
anchors.margins: Tokens.padding.small
|
||||||
anchors.top: parent.top
|
anchors.top: parent.top
|
||||||
visible: !ClipHistory.previewIsImage
|
visible: !ClipHistory.previewIsImage
|
||||||
|
|
||||||
@@ -90,7 +90,7 @@ Item {
|
|||||||
required property int index
|
required property int index
|
||||||
required property var modelData
|
required property var modelData
|
||||||
|
|
||||||
spacing: Tokens.spacing.normal
|
spacing: Tokens.spacing.medium
|
||||||
|
|
||||||
CustomRect {
|
CustomRect {
|
||||||
color: lineRow.index % 2 ? Colors.tPalette.m3surfaceContainer : "transparent"
|
color: lineRow.index % 2 ? Colors.tPalette.m3surfaceContainer : "transparent"
|
||||||
@@ -192,7 +192,7 @@ Item {
|
|||||||
anchors.bottom: parent.bottom
|
anchors.bottom: parent.bottom
|
||||||
anchors.left: parent.left
|
anchors.left: parent.left
|
||||||
anchors.top: search.bottom
|
anchors.top: search.bottom
|
||||||
anchors.topMargin: Tokens.spacing.normal
|
anchors.topMargin: Tokens.spacing.medium
|
||||||
implicitWidth: Config.clipboard.sizes.width
|
implicitWidth: Config.clipboard.sizes.width
|
||||||
|
|
||||||
CustomListView {
|
CustomListView {
|
||||||
@@ -204,7 +204,7 @@ Item {
|
|||||||
highlightRangeMode: ListView.ApplyRange
|
highlightRangeMode: ListView.ApplyRange
|
||||||
preferredHighlightBegin: 0
|
preferredHighlightBegin: 0
|
||||||
preferredHighlightEnd: height
|
preferredHighlightEnd: height
|
||||||
spacing: Tokens.spacing.normal
|
spacing: Tokens.spacing.medium
|
||||||
|
|
||||||
CustomScrollBar.vertical: CustomScrollBar {
|
CustomScrollBar.vertical: CustomScrollBar {
|
||||||
flickable: view
|
flickable: view
|
||||||
@@ -250,7 +250,7 @@ Item {
|
|||||||
id: icon
|
id: icon
|
||||||
|
|
||||||
anchors.left: parent.left
|
anchors.left: parent.left
|
||||||
anchors.margins: Tokens.padding.normal
|
anchors.margins: Tokens.padding.small
|
||||||
anchors.verticalCenter: parent.verticalCenter
|
anchors.verticalCenter: parent.verticalCenter
|
||||||
font.pointSize: Tokens.font.size.large
|
font.pointSize: Tokens.font.size.large
|
||||||
text: clipItem.isImage ? "image" : "text_fields"
|
text: clipItem.isImage ? "image" : "text_fields"
|
||||||
@@ -260,7 +260,7 @@ Item {
|
|||||||
id: text
|
id: text
|
||||||
|
|
||||||
anchors.left: icon.right
|
anchors.left: icon.right
|
||||||
anchors.margins: Tokens.spacing.normal
|
anchors.margins: Tokens.spacing.medium
|
||||||
anchors.verticalCenter: parent.verticalCenter
|
anchors.verticalCenter: parent.verticalCenter
|
||||||
elide: Text.ElideRight
|
elide: Text.ElideRight
|
||||||
text: clipItem.isImage ? qsTr("Image") : ClipHistory.displayText(clipItem.modelData)
|
text: clipItem.isImage ? qsTr("Image") : ClipHistory.displayText(clipItem.modelData)
|
||||||
@@ -292,7 +292,7 @@ Item {
|
|||||||
|
|
||||||
IconButton {
|
IconButton {
|
||||||
Layout.fillHeight: true
|
Layout.fillHeight: true
|
||||||
Layout.margins: Tokens.padding.normal
|
Layout.margins: Tokens.padding.small
|
||||||
Layout.preferredWidth: height
|
Layout.preferredWidth: height
|
||||||
icon: "delete"
|
icon: "delete"
|
||||||
inactiveColor: Qt.alpha(Colors.palette.m3error, 0.8)
|
inactiveColor: Qt.alpha(Colors.palette.m3error, 0.8)
|
||||||
@@ -320,7 +320,7 @@ Item {
|
|||||||
Behavior on y {
|
Behavior on y {
|
||||||
Anim {
|
Anim {
|
||||||
duration: Tokens.anim.durations.small
|
duration: Tokens.anim.durations.small
|
||||||
easing.bezierCurve: Tokens.anim.curves.expressiveEffects
|
easing: Tokens.anim.expressiveDefaultEffects
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -15,15 +15,15 @@ Item {
|
|||||||
required property PersistentProperties visibilities
|
required property PersistentProperties visibilities
|
||||||
|
|
||||||
anchors.bottomMargin: (-implicitHeight - 5) * offsetScale
|
anchors.bottomMargin: (-implicitHeight - 5) * offsetScale
|
||||||
implicitHeight: content.implicitHeight + Tokens.padding.normal * 2
|
implicitHeight: content.implicitHeight + Tokens.padding.small * 2
|
||||||
implicitWidth: content.implicitWidth + Tokens.padding.normal * 2 || 400
|
implicitWidth: content.implicitWidth + Tokens.padding.small * 2 || 400
|
||||||
opacity: 1 - offsetScale
|
opacity: 1 - offsetScale
|
||||||
visible: offsetScale < 1
|
visible: offsetScale < 1
|
||||||
|
|
||||||
Behavior on offsetScale {
|
Behavior on offsetScale {
|
||||||
Anim {
|
Anim {
|
||||||
duration: Tokens.anim.durations.expressiveDefaultSpatial
|
duration: Tokens.anim.durations.expressiveDefaultSpatial
|
||||||
easing.bezierCurve: Tokens.anim.curves.expressiveDefaultSpatial
|
easing: Tokens.anim.expressiveDefaultSpatial
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -32,11 +32,11 @@ Item {
|
|||||||
|
|
||||||
anchors.bottom: parent.bottom
|
anchors.bottom: parent.bottom
|
||||||
anchors.left: parent.left
|
anchors.left: parent.left
|
||||||
anchors.margins: Tokens.padding.smaller
|
anchors.margins: Tokens.padding.small
|
||||||
anchors.right: parent.right
|
anchors.right: parent.right
|
||||||
anchors.top: parent.top
|
anchors.top: parent.top
|
||||||
color: "transparent"
|
color: "transparent"
|
||||||
radius: Tokens.rounding.normal - anchors.margins
|
radius: Tokens.rounding.extraLarge - anchors.margins
|
||||||
|
|
||||||
Item {
|
Item {
|
||||||
id: view
|
id: view
|
||||||
|
|||||||
@@ -13,11 +13,11 @@ GridLayout {
|
|||||||
|
|
||||||
required property PersistentProperties dashState
|
required property PersistentProperties dashState
|
||||||
readonly property bool dashboardVisible: visibilities.dashboard
|
readonly property bool dashboardVisible: visibilities.dashboard
|
||||||
property int radius: Tokens.rounding.smallest
|
property int radius: Tokens.rounding.medium
|
||||||
required property PersistentProperties visibilities
|
required property PersistentProperties visibilities
|
||||||
|
|
||||||
columnSpacing: Tokens.spacing.smaller
|
columnSpacing: Tokens.spacing.small
|
||||||
rowSpacing: Tokens.spacing.smaller
|
rowSpacing: Tokens.spacing.small
|
||||||
|
|
||||||
ParallelAnimation {
|
ParallelAnimation {
|
||||||
id: openAnim
|
id: openAnim
|
||||||
@@ -104,12 +104,13 @@ GridLayout {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
Rect {
|
CustomClippingRect {
|
||||||
Layout.column: 0
|
Layout.column: 0
|
||||||
Layout.columnSpan: 5
|
Layout.columnSpan: 5
|
||||||
Layout.fillWidth: true
|
Layout.fillWidth: true
|
||||||
Layout.preferredHeight: media.implicitHeight
|
Layout.preferredHeight: media.implicitHeight
|
||||||
Layout.row: 2
|
Layout.row: 2
|
||||||
|
color: Colors.tPalette.m3surfaceContainer
|
||||||
radius: root.radius
|
radius: root.radius
|
||||||
|
|
||||||
Media {
|
Media {
|
||||||
|
|||||||
@@ -132,7 +132,7 @@ CustomMouseArea {
|
|||||||
|
|
||||||
IconButton {
|
IconButton {
|
||||||
icon: "chevron_left"
|
icon: "chevron_left"
|
||||||
padding: Tokens.padding.small
|
padding: Tokens.padding.extraSmall
|
||||||
type: IconButton.Text
|
type: IconButton.Text
|
||||||
|
|
||||||
onClicked: root.dashState.currentDate = new Date(root.realCurrYear, root.realCurrMonth - 1, 1)
|
onClicked: root.dashState.currentDate = new Date(root.realCurrYear, root.realCurrMonth - 1, 1)
|
||||||
@@ -150,7 +150,7 @@ CustomMouseArea {
|
|||||||
const now = new Date();
|
const now = new Date();
|
||||||
return root.realCurrMonth !== now.getMonth() || root.realCurrYear !== now.getFullYear();
|
return root.realCurrMonth !== now.getMonth() || root.realCurrYear !== now.getFullYear();
|
||||||
}
|
}
|
||||||
radius: pressed ? Tokens.rounding.small : Tokens.rounding.large
|
radius: pressed ? Tokens.rounding.small : Tokens.rounding.largeIncreased
|
||||||
|
|
||||||
Behavior on radius {
|
Behavior on radius {
|
||||||
Anim {
|
Anim {
|
||||||
@@ -203,7 +203,7 @@ CustomMouseArea {
|
|||||||
|
|
||||||
IconButton {
|
IconButton {
|
||||||
icon: "chevron_right"
|
icon: "chevron_right"
|
||||||
padding: Tokens.padding.small
|
padding: Tokens.padding.extraSmall
|
||||||
type: IconButton.Text
|
type: IconButton.Text
|
||||||
|
|
||||||
onClicked: root.dashState.currentDate = new Date(root.realCurrYear, root.realCurrMonth + 1, 1)
|
onClicked: root.dashState.currentDate = new Date(root.realCurrYear, root.realCurrMonth + 1, 1)
|
||||||
@@ -259,7 +259,7 @@ CustomMouseArea {
|
|||||||
|
|
||||||
required property var model
|
required property var model
|
||||||
|
|
||||||
implicitHeight: text.implicitHeight + Tokens.padding.normal * 2
|
implicitHeight: text.implicitHeight + Tokens.padding.small * 2
|
||||||
implicitWidth: implicitHeight
|
implicitWidth: implicitHeight
|
||||||
|
|
||||||
CustomText {
|
CustomText {
|
||||||
|
|||||||
@@ -9,6 +9,7 @@ import QtQuick.Effects
|
|||||||
import ZShell.Components
|
import ZShell.Components
|
||||||
import ZShell.Services
|
import ZShell.Services
|
||||||
import ZShell.Config
|
import ZShell.Config
|
||||||
|
import qs.Modules.Dashboard.Dash.Media
|
||||||
import qs.Daemons
|
import qs.Daemons
|
||||||
import qs.Components
|
import qs.Components
|
||||||
import qs.Helpers
|
import qs.Helpers
|
||||||
@@ -25,7 +26,7 @@ Item {
|
|||||||
|
|
||||||
anchors.left: parent.left
|
anchors.left: parent.left
|
||||||
anchors.right: parent.right
|
anchors.right: parent.right
|
||||||
implicitHeight: layout.implicitHeight
|
implicitHeight: layout.implicitHeight + layout.anchors.margins * 2
|
||||||
function lengthStr(length: int): string {
|
function lengthStr(length: int): string {
|
||||||
if (length < 0)
|
if (length < 0)
|
||||||
return "-1:-1";
|
return "-1:-1";
|
||||||
@@ -57,14 +58,18 @@ Item {
|
|||||||
service: Audio.cava
|
service: Audio.cava
|
||||||
}
|
}
|
||||||
|
|
||||||
|
BackgroundShapes {
|
||||||
|
anchors.fill: parent
|
||||||
|
}
|
||||||
|
|
||||||
Shape {
|
Shape {
|
||||||
id: visualizer
|
id: visualizer
|
||||||
|
|
||||||
readonly property int bars: Config.services.visualizerBars
|
readonly property int bars: Config.services.visualizerBars
|
||||||
property color color: Colors.palette.m3tertiary
|
property color color: Qt.alpha(Colors.palette.m3primary, 0.5)
|
||||||
property color fillColor: Qt.alpha(color, 0.25)
|
property color fillColor: Qt.alpha(color, 0.1)
|
||||||
|
|
||||||
anchors.fill: layout
|
anchors.fill: parent
|
||||||
anchors.leftMargin: -(shape.strokeWidth / 2)
|
anchors.leftMargin: -(shape.strokeWidth / 2)
|
||||||
layer.enabled: true
|
layer.enabled: true
|
||||||
asynchronous: true
|
asynchronous: true
|
||||||
@@ -87,15 +92,15 @@ Item {
|
|||||||
if (n < 2)
|
if (n < 2)
|
||||||
return "";
|
return "";
|
||||||
|
|
||||||
const h = layout.height + shape.strokeWidth / 2;
|
const h = root.height + shape.strokeWidth / 2;
|
||||||
const w = layout.width + shape.strokeWidth;
|
const w = root.width + shape.strokeWidth;
|
||||||
|
|
||||||
function x(i) {
|
function x(i) {
|
||||||
return i * w / (n - 1);
|
return i * w / (n - 1);
|
||||||
}
|
}
|
||||||
|
|
||||||
function y(i) {
|
function y(i) {
|
||||||
return h - values[i] * Config.dashboard.sizes.mediaVisualizerSize;
|
return h - (values[i] * Config.dashboard.sizes.mediaVisualizerSize) / 2;
|
||||||
}
|
}
|
||||||
|
|
||||||
let d = `M 0 ${h} `;
|
let d = `M 0 ${h} `;
|
||||||
@@ -142,48 +147,21 @@ Item {
|
|||||||
RowLayout {
|
RowLayout {
|
||||||
id: layout
|
id: layout
|
||||||
|
|
||||||
anchors.left: parent.left
|
|
||||||
anchors.right: parent.right
|
|
||||||
|
|
||||||
CustomClippingRect {
|
|
||||||
id: cover
|
|
||||||
|
|
||||||
Layout.alignment: Qt.AlignLeft
|
|
||||||
Layout.bottomMargin: Tokens.padding.large + Config.dashboard.sizes.mediaProgressThickness + Tokens.spacing.small
|
|
||||||
Layout.leftMargin: Tokens.padding.large + Config.dashboard.sizes.mediaProgressThickness + Tokens.spacing.small
|
|
||||||
Layout.preferredHeight: Config.dashboard.sizes.mediaCoverArtSize
|
|
||||||
Layout.preferredWidth: Config.dashboard.sizes.mediaCoverArtSize
|
|
||||||
Layout.topMargin: Tokens.padding.large + Config.dashboard.sizes.mediaProgressThickness + Tokens.spacing.small
|
|
||||||
color: Colors.tPalette.m3surfaceContainerHigh
|
|
||||||
radius: Infinity
|
|
||||||
|
|
||||||
MaterialIcon {
|
|
||||||
anchors.centerIn: parent
|
|
||||||
color: Colors.palette.m3onSurfaceVariant
|
|
||||||
font.pointSize: (parent.width * 0.4) || 1
|
|
||||||
grade: 200
|
|
||||||
text: "art_track"
|
|
||||||
}
|
|
||||||
|
|
||||||
Image {
|
|
||||||
id: image
|
|
||||||
|
|
||||||
anchors.fill: parent
|
anchors.fill: parent
|
||||||
asynchronous: true
|
anchors.margins: Tokens.padding.large
|
||||||
fillMode: Image.PreserveAspectCrop
|
anchors.leftMargin: Tokens.padding.extraLarge
|
||||||
source: Players.active?.trackArtUrl ?? ""
|
|
||||||
sourceSize.height: Math.floor(height)
|
CoverVisualizer {
|
||||||
sourceSize.width: Math.floor(width)
|
Layout.fillHeight: true
|
||||||
}
|
implicitWidth: Config.dashboard.sizes.mediaCoverArtSize
|
||||||
}
|
}
|
||||||
|
|
||||||
ColumnLayout {
|
ColumnLayout {
|
||||||
Layout.fillWidth: true
|
Layout.fillWidth: true
|
||||||
Layout.leftMargin: Tokens.spacing.large
|
Layout.leftMargin: Tokens.spacing.largeIncreased
|
||||||
Layout.rightMargin: Tokens.spacing.large
|
Layout.rightMargin: Tokens.spacing.largeIncreased
|
||||||
Layout.preferredHeight: childrenRect.height
|
|
||||||
|
|
||||||
spacing: Tokens.spacing.normal
|
spacing: Tokens.spacing.small
|
||||||
|
|
||||||
MarqueeText {
|
MarqueeText {
|
||||||
id: title
|
id: title
|
||||||
@@ -222,7 +200,7 @@ Item {
|
|||||||
|
|
||||||
RowLayout {
|
RowLayout {
|
||||||
id: positionSliderLayout
|
id: positionSliderLayout
|
||||||
Layout.topMargin: Tokens.spacing.extraLargeIncreased
|
Layout.topMargin: Tokens.spacing.large
|
||||||
Layout.fillWidth: true
|
Layout.fillWidth: true
|
||||||
spacing: Tokens.spacing.small
|
spacing: Tokens.spacing.small
|
||||||
|
|
||||||
@@ -289,7 +267,6 @@ Item {
|
|||||||
checked: Players.active?.shuffle ?? false
|
checked: Players.active?.shuffle ?? false
|
||||||
enabled: Players.active?.shuffleSupported
|
enabled: Players.active?.shuffleSupported
|
||||||
onClicked: Players.active.shuffle = !Players.active?.shuffle
|
onClicked: Players.active.shuffle = !Players.active?.shuffle
|
||||||
implicitWidth: Math.round(implicitHeight * 0.9)
|
|
||||||
}
|
}
|
||||||
|
|
||||||
IconButton {
|
IconButton {
|
||||||
@@ -301,6 +278,7 @@ Item {
|
|||||||
shapeMorph: true
|
shapeMorph: true
|
||||||
enabled: Players.active?.canGoPrevious
|
enabled: Players.active?.canGoPrevious
|
||||||
onClicked: Players.active?.previous()
|
onClicked: Players.active?.previous()
|
||||||
|
font.pointSize: Tokens.font.size.large
|
||||||
}
|
}
|
||||||
|
|
||||||
IconButton {
|
IconButton {
|
||||||
@@ -313,6 +291,7 @@ Item {
|
|||||||
checked: Players.active?.isPlaying ?? false
|
checked: Players.active?.isPlaying ?? false
|
||||||
enabled: Players.active?.canTogglePlaying
|
enabled: Players.active?.canTogglePlaying
|
||||||
onClicked: Players.active?.togglePlaying()
|
onClicked: Players.active?.togglePlaying()
|
||||||
|
font.pointSize: Tokens.font.size.large
|
||||||
}
|
}
|
||||||
|
|
||||||
IconButton {
|
IconButton {
|
||||||
@@ -324,6 +303,7 @@ Item {
|
|||||||
shapeMorph: true
|
shapeMorph: true
|
||||||
enabled: Players.active?.canGoNext
|
enabled: Players.active?.canGoNext
|
||||||
onClicked: Players.active?.next()
|
onClicked: Players.active?.next()
|
||||||
|
font.pointSize: Tokens.font.size.large
|
||||||
}
|
}
|
||||||
|
|
||||||
IconButton {
|
IconButton {
|
||||||
@@ -342,7 +322,6 @@ Item {
|
|||||||
else
|
else
|
||||||
Players.active.loopState = MprisLoopState.None;
|
Players.active.loopState = MprisLoopState.None;
|
||||||
}
|
}
|
||||||
implicitWidth: Math.round(implicitHeight * 0.9)
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -0,0 +1,97 @@
|
|||||||
|
pragma ComponentBehavior: Bound
|
||||||
|
|
||||||
|
import QtQuick
|
||||||
|
import M3Shapes
|
||||||
|
import qs.Components
|
||||||
|
import qs.Services
|
||||||
|
import qs.Helpers
|
||||||
|
|
||||||
|
Item {
|
||||||
|
id: root
|
||||||
|
|
||||||
|
property int count: 14
|
||||||
|
property list<real> darkOpacities: [0.10, 0.20, 0.10, 0.20]
|
||||||
|
property list<real> lightOpacities: [0.34, 0.34, 0.08, 0.2]
|
||||||
|
property real maxRotSpeed: 12
|
||||||
|
property real maxSize: 124
|
||||||
|
property real maxSpeed: 18
|
||||||
|
property real minRotSpeed: -12
|
||||||
|
property real minSize: 36
|
||||||
|
property real minSpeed: 4
|
||||||
|
readonly property list<int> shapePool: [MaterialShape.Circle, MaterialShape.Cookie4Sided, MaterialShape.Cookie6Sided, MaterialShape.Cookie7Sided, MaterialShape.Cookie9Sided, MaterialShape.Cookie12Sided, MaterialShape.Sunny, MaterialShape.VerySunny, MaterialShape.SoftBurst, MaterialShape.Pentagon, MaterialShape.Gem, MaterialShape.Arch, MaterialShape.Arrow, MaterialShape.Pill, MaterialShape.Triangle, MaterialShape.Fan, MaterialShape.Oval]
|
||||||
|
|
||||||
|
function rand(min: real, max: real): real {
|
||||||
|
return min + Math.random() * (max - min);
|
||||||
|
}
|
||||||
|
|
||||||
|
function signedRand(min: real, max: real): real {
|
||||||
|
return rand(min, max) * (Math.random() < 0.5 ? -1 : 1);
|
||||||
|
}
|
||||||
|
|
||||||
|
Component.onCompleted: shapes.model = count
|
||||||
|
|
||||||
|
Repeater {
|
||||||
|
id: shapes
|
||||||
|
|
||||||
|
DriftingShape {
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
FrameAnimation {
|
||||||
|
running: root.visible && root.width > 0 && root.height > 0 && (Players.active?.isPlaying ?? false)
|
||||||
|
|
||||||
|
onTriggered: {
|
||||||
|
const dt = frameTime;
|
||||||
|
for (let i = 0; i < shapes.count; i++) {
|
||||||
|
const s = shapes.itemAt(i) as DriftingShape;
|
||||||
|
if (!s)
|
||||||
|
continue;
|
||||||
|
|
||||||
|
s.x += s.vx * dt;
|
||||||
|
s.y += s.vy * dt;
|
||||||
|
s.rotation += s.vr * dt;
|
||||||
|
|
||||||
|
if (s.x + s.width < 0)
|
||||||
|
s.x = root.width;
|
||||||
|
else if (s.x > root.width)
|
||||||
|
s.x = -s.width;
|
||||||
|
|
||||||
|
if (s.y + s.height < 0)
|
||||||
|
s.y = root.height;
|
||||||
|
else if (s.y > root.height)
|
||||||
|
s.y = -s.height;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
component DriftingShape: MaterialShape {
|
||||||
|
id: shapeItem
|
||||||
|
|
||||||
|
readonly property int colorIdx: Math.floor(Math.random() * 4)
|
||||||
|
required property int index
|
||||||
|
property real vr: root.rand(root.minRotSpeed, root.maxRotSpeed)
|
||||||
|
property real vx: root.signedRand(root.minSpeed, root.maxSpeed)
|
||||||
|
property real vy: root.signedRand(root.minSpeed, root.maxSpeed)
|
||||||
|
|
||||||
|
color: [Colors.palette.m3primaryContainer, Colors.palette.m3secondaryContainer, Colors.palette.m3tertiaryContainer, Colors.palette.m3outlineVariant][colorIdx]
|
||||||
|
implicitSize: root.minSize + (index / root.count) * (root.maxSize - root.minSize)
|
||||||
|
opacity: Colors.light ? root.lightOpacities[colorIdx] : root.darkOpacities[colorIdx]
|
||||||
|
rotation: root.rand(0, 360)
|
||||||
|
shape: root.shapePool[Math.floor(Math.random() * root.shapePool.length)]
|
||||||
|
|
||||||
|
Behavior on color {
|
||||||
|
CAnim {
|
||||||
|
}
|
||||||
|
}
|
||||||
|
Behavior on opacity {
|
||||||
|
Anim {
|
||||||
|
type: Anim.SlowEffects
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
Component.onCompleted: {
|
||||||
|
x = root.rand(0, root.width - implicitSize);
|
||||||
|
y = root.rand(0, root.height - implicitSize);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
@@ -0,0 +1,100 @@
|
|||||||
|
pragma ComponentBehavior: Bound
|
||||||
|
|
||||||
|
import QtQuick
|
||||||
|
import QtQuick.Effects
|
||||||
|
import M3Shapes
|
||||||
|
import qs.Helpers
|
||||||
|
import qs.Effects
|
||||||
|
import qs.Components
|
||||||
|
import qs.Services
|
||||||
|
|
||||||
|
Item {
|
||||||
|
id: root
|
||||||
|
|
||||||
|
property color fallbackColor: Colors.layer(Colors.palette.m3surfaceContainerHighest, 2)
|
||||||
|
property bool hadPrevious
|
||||||
|
readonly property alias shape: shape
|
||||||
|
|
||||||
|
layer.enabled: true
|
||||||
|
|
||||||
|
Behavior on fallbackColor {
|
||||||
|
CAnim {
|
||||||
|
}
|
||||||
|
}
|
||||||
|
layer.effect: MultiEffect {
|
||||||
|
blurMax: 1
|
||||||
|
shadowColor: Colors.palette.m3outline
|
||||||
|
shadowEnabled: true
|
||||||
|
shadowOpacity: 0.3
|
||||||
|
}
|
||||||
|
|
||||||
|
Item {
|
||||||
|
id: shapeWrapper
|
||||||
|
|
||||||
|
anchors.fill: parent
|
||||||
|
layer.enabled: true
|
||||||
|
opacity: root.fallbackColor.a
|
||||||
|
|
||||||
|
MaterialShape {
|
||||||
|
id: shape
|
||||||
|
|
||||||
|
color: Qt.alpha(root.fallbackColor, 1)
|
||||||
|
implicitSize: root.width
|
||||||
|
shape: MaterialShape.Cookie12Sided
|
||||||
|
|
||||||
|
Anim on rotation {
|
||||||
|
duration: 23500
|
||||||
|
easing.type: Easing.Linear
|
||||||
|
from: 360
|
||||||
|
loops: Animation.Infinite
|
||||||
|
paused: !Players.active?.isPlaying
|
||||||
|
running: true
|
||||||
|
to: 0
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
MaterialIcon {
|
||||||
|
anchors.centerIn: parent
|
||||||
|
animate: true
|
||||||
|
color: Colors.palette.m3onSurfaceVariant
|
||||||
|
grade: 200
|
||||||
|
opacity: image.status === Image.Null || image.status === Image.Error ? 1 : 0
|
||||||
|
text: image.status === Image.Error ? "broken_image" : "art_track"
|
||||||
|
|
||||||
|
Behavior on opacity {
|
||||||
|
Anim {
|
||||||
|
type: Anim.DefaultEffects
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
Loader {
|
||||||
|
active: opacity > 0
|
||||||
|
anchors.centerIn: parent
|
||||||
|
asynchronous: true
|
||||||
|
opacity: image.status === Image.Loading ? 1 : 0
|
||||||
|
|
||||||
|
Behavior on opacity {
|
||||||
|
Anim {
|
||||||
|
type: Anim.DefaultEffects
|
||||||
|
}
|
||||||
|
}
|
||||||
|
sourceComponent: LoadingIndicator {
|
||||||
|
color: Colors.palette.m3primaryContainer
|
||||||
|
implicitSize: root.width * 0.3
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
FadeImage {
|
||||||
|
id: image
|
||||||
|
|
||||||
|
anchors.fill: parent
|
||||||
|
layer.enabled: true
|
||||||
|
source: Players.getArtUrl(Players.active)
|
||||||
|
|
||||||
|
layer.effect: Mask {
|
||||||
|
maskSource: shapeWrapper
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
@@ -0,0 +1,18 @@
|
|||||||
|
pragma ComponentBehavior: Bound
|
||||||
|
|
||||||
|
import QtQuick
|
||||||
|
import M3Shapes
|
||||||
|
import ZShell.Config
|
||||||
|
|
||||||
|
Item {
|
||||||
|
id: root
|
||||||
|
|
||||||
|
CoverArt {
|
||||||
|
id: cover
|
||||||
|
|
||||||
|
anchors.centerIn: parent
|
||||||
|
implicitHeight: Config.dashboard.sizes.mediaCoverArtSize
|
||||||
|
implicitWidth: Config.dashboard.sizes.mediaCoverArtSize
|
||||||
|
shape.shape: MaterialShape.Cookie9Sided
|
||||||
|
}
|
||||||
|
}
|
||||||
@@ -35,7 +35,7 @@ Item {
|
|||||||
anchors.horizontalCenter: parent.horizontalCenter
|
anchors.horizontalCenter: parent.horizontalCenter
|
||||||
anchors.margins: Tokens.padding.large
|
anchors.margins: Tokens.padding.large
|
||||||
anchors.top: parent.top
|
anchors.top: parent.top
|
||||||
spacing: Tokens.spacing.normal
|
spacing: Tokens.spacing.medium
|
||||||
|
|
||||||
Resource {
|
Resource {
|
||||||
fgColor: Colors.palette.m3primary
|
fgColor: Colors.palette.m3primary
|
||||||
|
|||||||
@@ -18,7 +18,7 @@ Row {
|
|||||||
color: Colors.layer(Colors.palette.m3surfaceContainerHigh, 2)
|
color: Colors.layer(Colors.palette.m3surfaceContainerHigh, 2)
|
||||||
implicitHeight: info.implicitHeight
|
implicitHeight: info.implicitHeight
|
||||||
implicitWidth: info.implicitHeight
|
implicitWidth: info.implicitHeight
|
||||||
radius: Tokens.rounding.smallest
|
radius: Tokens.rounding.small
|
||||||
|
|
||||||
MaterialIcon {
|
MaterialIcon {
|
||||||
anchors.centerIn: parent
|
anchors.centerIn: parent
|
||||||
|
|||||||
@@ -27,7 +27,7 @@ Item {
|
|||||||
id: info
|
id: info
|
||||||
|
|
||||||
anchors.left: icon.right
|
anchors.left: icon.right
|
||||||
anchors.leftMargin: Tokens.spacing.large
|
anchors.leftMargin: Tokens.spacing.largeIncreased
|
||||||
anchors.verticalCenter: parent.verticalCenter
|
anchors.verticalCenter: parent.verticalCenter
|
||||||
spacing: 8
|
spacing: 8
|
||||||
|
|
||||||
|
|||||||
@@ -181,7 +181,7 @@ Item {
|
|||||||
anchors.verticalCenter: parent.verticalCenter
|
anchors.verticalCenter: parent.verticalCenter
|
||||||
color: "transparent"
|
color: "transparent"
|
||||||
implicitHeight: parent.height + 8 * 2
|
implicitHeight: parent.height + 8 * 2
|
||||||
radius: Tokens.rounding.smallest
|
radius: Tokens.rounding.small
|
||||||
|
|
||||||
CustomRect {
|
CustomRect {
|
||||||
id: stateLayer
|
id: stateLayer
|
||||||
|
|||||||
@@ -32,7 +32,7 @@ Item {
|
|||||||
y: root.menuY
|
y: root.menuY
|
||||||
|
|
||||||
color: Colors.tPalette.m3surface
|
color: Colors.tPalette.m3surface
|
||||||
radius: Tokens.rounding.normal
|
radius: Tokens.rounding.medium
|
||||||
|
|
||||||
implicitWidth: menuLayout.implicitWidth + padding * 2
|
implicitWidth: menuLayout.implicitWidth + padding * 2
|
||||||
implicitHeight: menuLayout.implicitHeight + padding * 2
|
implicitHeight: menuLayout.implicitHeight + padding * 2
|
||||||
@@ -48,13 +48,13 @@ Item {
|
|||||||
CustomRect {
|
CustomRect {
|
||||||
Layout.preferredWidth: 200
|
Layout.preferredWidth: 200
|
||||||
radius: popupBackground.radius - popupBackground.padding
|
radius: popupBackground.radius - popupBackground.padding
|
||||||
implicitHeight: openTerminalRow.implicitHeight + Tokens.padding.small * 2
|
implicitHeight: openTerminalRow.implicitHeight + Tokens.padding.extraSmall * 2
|
||||||
|
|
||||||
RowLayout {
|
RowLayout {
|
||||||
id: openTerminalRow
|
id: openTerminalRow
|
||||||
spacing: 8
|
spacing: 8
|
||||||
anchors.fill: parent
|
anchors.fill: parent
|
||||||
anchors.leftMargin: Tokens.padding.smaller
|
anchors.leftMargin: Tokens.padding.small
|
||||||
|
|
||||||
MaterialIcon { text: "terminal"; font.pointSize: 20 }
|
MaterialIcon { text: "terminal"; font.pointSize: 20 }
|
||||||
CustomText { text: "Open terminal"; Layout.fillWidth: true }
|
CustomText { text: "Open terminal"; Layout.fillWidth: true }
|
||||||
@@ -81,13 +81,13 @@ Item {
|
|||||||
CustomRect {
|
CustomRect {
|
||||||
Layout.fillWidth: true
|
Layout.fillWidth: true
|
||||||
radius: popupBackground.radius - popupBackground.padding
|
radius: popupBackground.radius - popupBackground.padding
|
||||||
implicitHeight: settingsRow.implicitHeight + Tokens.padding.small * 2
|
implicitHeight: settingsRow.implicitHeight + Tokens.padding.extraSmall * 2
|
||||||
|
|
||||||
RowLayout {
|
RowLayout {
|
||||||
id: settingsRow
|
id: settingsRow
|
||||||
spacing: 8
|
spacing: 8
|
||||||
anchors.fill: parent
|
anchors.fill: parent
|
||||||
anchors.leftMargin: Tokens.padding.smaller
|
anchors.leftMargin: Tokens.padding.small
|
||||||
|
|
||||||
MaterialIcon { text: "settings"; font.pointSize: 20 }
|
MaterialIcon { text: "settings"; font.pointSize: 20 }
|
||||||
CustomText { text: "ZShell settings"; Layout.fillWidth: true }
|
CustomText { text: "ZShell settings"; Layout.fillWidth: true }
|
||||||
@@ -115,13 +115,13 @@ Item {
|
|||||||
CustomRect {
|
CustomRect {
|
||||||
Layout.fillWidth: true
|
Layout.fillWidth: true
|
||||||
radius: popupBackground.radius - popupBackground.padding
|
radius: popupBackground.radius - popupBackground.padding
|
||||||
implicitHeight: logoutRow.implicitHeight + Tokens.padding.small * 2
|
implicitHeight: logoutRow.implicitHeight + Tokens.padding.extraSmall * 2
|
||||||
|
|
||||||
RowLayout {
|
RowLayout {
|
||||||
id: logoutRow
|
id: logoutRow
|
||||||
spacing: 8
|
spacing: 8
|
||||||
anchors.fill: parent
|
anchors.fill: parent
|
||||||
anchors.leftMargin: Tokens.padding.smaller
|
anchors.leftMargin: Tokens.padding.small
|
||||||
|
|
||||||
MaterialIcon { text: "logout"; font.pointSize: 20 }
|
MaterialIcon { text: "logout"; font.pointSize: 20 }
|
||||||
CustomText { text: "Logout"; Layout.fillWidth: true }
|
CustomText { text: "Logout"; Layout.fillWidth: true }
|
||||||
@@ -148,13 +148,13 @@ Item {
|
|||||||
// CustomRect {
|
// CustomRect {
|
||||||
// Layout.fillWidth: true
|
// Layout.fillWidth: true
|
||||||
// radius: popupBackground.radius - popupBackground.padding
|
// radius: popupBackground.radius - popupBackground.padding
|
||||||
// implicitHeight: desktopIconsRow.implicitHeight + Tokens.padding.small * 2
|
// implicitHeight: desktopIconsRow.implicitHeight + Tokens.padding.extraSmall * 2
|
||||||
//
|
//
|
||||||
// RowLayout {
|
// RowLayout {
|
||||||
// id: desktopIconsRow
|
// id: desktopIconsRow
|
||||||
// spacing: 8
|
// spacing: 8
|
||||||
// anchors.fill: parent
|
// anchors.fill: parent
|
||||||
// anchors.leftMargin: Tokens.padding.smaller
|
// anchors.leftMargin: Tokens.padding.small
|
||||||
//
|
//
|
||||||
// MaterialIcon { text: Config.options.background.showDesktopIcons ? "visibility_off" : "visibility"; font.pointSize: 20 }
|
// MaterialIcon { text: Config.options.background.showDesktopIcons ? "visibility_off" : "visibility"; font.pointSize: 20 }
|
||||||
// CustomText { text: Config.options.background.showDesktopIcons ? "Hide icons" : "Show icons"; Layout.fillWidth: true }
|
// CustomText { text: Config.options.background.showDesktopIcons ? "Hide icons" : "Show icons"; Layout.fillWidth: true }
|
||||||
|
|||||||
@@ -43,13 +43,13 @@ Item {
|
|||||||
CustomClippingRect {
|
CustomClippingRect {
|
||||||
id: popupBackground
|
id: popupBackground
|
||||||
|
|
||||||
readonly property real padding: Tokens.padding.small
|
readonly property real padding: Tokens.padding.extraSmall
|
||||||
|
|
||||||
color: Colors.tPalette.m3surface
|
color: Colors.tPalette.m3surface
|
||||||
implicitHeight: menuLayout.implicitHeight + padding * 2
|
implicitHeight: menuLayout.implicitHeight + padding * 2
|
||||||
implicitWidth: menuLayout.implicitWidth + padding * 2
|
implicitWidth: menuLayout.implicitWidth + padding * 2
|
||||||
opacity: contextMenu.visible ? 1 : 0
|
opacity: contextMenu.visible ? 1 : 0
|
||||||
radius: Tokens.rounding.normal
|
radius: Tokens.rounding.medium
|
||||||
x: contextMenu.menuX
|
x: contextMenu.menuX
|
||||||
y: contextMenu.menuY
|
y: contextMenu.menuY
|
||||||
|
|
||||||
@@ -66,14 +66,14 @@ Item {
|
|||||||
|
|
||||||
CustomRect {
|
CustomRect {
|
||||||
Layout.preferredWidth: 160
|
Layout.preferredWidth: 160
|
||||||
implicitHeight: openRow.implicitHeight + Tokens.padding.small * 2
|
implicitHeight: openRow.implicitHeight + Tokens.padding.extraSmall * 2
|
||||||
radius: popupBackground.radius - popupBackground.padding
|
radius: popupBackground.radius - popupBackground.padding
|
||||||
|
|
||||||
RowLayout {
|
RowLayout {
|
||||||
id: openRow
|
id: openRow
|
||||||
|
|
||||||
anchors.fill: parent
|
anchors.fill: parent
|
||||||
anchors.leftMargin: Tokens.padding.smaller
|
anchors.leftMargin: Tokens.padding.small
|
||||||
spacing: 8
|
spacing: 8
|
||||||
|
|
||||||
MaterialIcon {
|
MaterialIcon {
|
||||||
@@ -109,14 +109,14 @@ Item {
|
|||||||
|
|
||||||
CustomRect {
|
CustomRect {
|
||||||
Layout.fillWidth: true
|
Layout.fillWidth: true
|
||||||
implicitHeight: openWithRow.implicitHeight + Tokens.padding.small * 2
|
implicitHeight: openWithRow.implicitHeight + Tokens.padding.extraSmall * 2
|
||||||
radius: popupBackground.radius - popupBackground.padding
|
radius: popupBackground.radius - popupBackground.padding
|
||||||
|
|
||||||
RowLayout {
|
RowLayout {
|
||||||
id: openWithRow
|
id: openWithRow
|
||||||
|
|
||||||
anchors.fill: parent
|
anchors.fill: parent
|
||||||
anchors.leftMargin: Tokens.padding.smaller
|
anchors.leftMargin: Tokens.padding.small
|
||||||
spacing: 8
|
spacing: 8
|
||||||
|
|
||||||
MaterialIcon {
|
MaterialIcon {
|
||||||
@@ -154,14 +154,14 @@ Item {
|
|||||||
|
|
||||||
CustomRect {
|
CustomRect {
|
||||||
Layout.fillWidth: true
|
Layout.fillWidth: true
|
||||||
implicitHeight: copyPathRow.implicitHeight + Tokens.padding.small * 2
|
implicitHeight: copyPathRow.implicitHeight + Tokens.padding.extraSmall * 2
|
||||||
radius: popupBackground.radius - popupBackground.padding
|
radius: popupBackground.radius - popupBackground.padding
|
||||||
|
|
||||||
RowLayout {
|
RowLayout {
|
||||||
id: copyPathRow
|
id: copyPathRow
|
||||||
|
|
||||||
anchors.fill: parent
|
anchors.fill: parent
|
||||||
anchors.leftMargin: Tokens.padding.smaller
|
anchors.leftMargin: Tokens.padding.small
|
||||||
spacing: 8
|
spacing: 8
|
||||||
|
|
||||||
MaterialIcon {
|
MaterialIcon {
|
||||||
@@ -187,7 +187,7 @@ Item {
|
|||||||
|
|
||||||
CustomRect {
|
CustomRect {
|
||||||
Layout.fillWidth: true
|
Layout.fillWidth: true
|
||||||
implicitHeight: renameRow.implicitHeight + Tokens.padding.small * 2
|
implicitHeight: renameRow.implicitHeight + Tokens.padding.extraSmall * 2
|
||||||
radius: popupBackground.radius - popupBackground.padding
|
radius: popupBackground.radius - popupBackground.padding
|
||||||
visible: contextMenu.targetPaths.length === 1
|
visible: contextMenu.targetPaths.length === 1
|
||||||
|
|
||||||
@@ -195,7 +195,7 @@ Item {
|
|||||||
id: renameRow
|
id: renameRow
|
||||||
|
|
||||||
anchors.fill: parent
|
anchors.fill: parent
|
||||||
anchors.leftMargin: Tokens.padding.smaller
|
anchors.leftMargin: Tokens.padding.small
|
||||||
spacing: 8
|
spacing: 8
|
||||||
|
|
||||||
MaterialIcon {
|
MaterialIcon {
|
||||||
@@ -229,14 +229,14 @@ Item {
|
|||||||
|
|
||||||
CustomRect {
|
CustomRect {
|
||||||
Layout.fillWidth: true
|
Layout.fillWidth: true
|
||||||
implicitHeight: deleteRow.implicitHeight + Tokens.padding.small * 2
|
implicitHeight: deleteRow.implicitHeight + Tokens.padding.extraSmall * 2
|
||||||
radius: popupBackground.radius - popupBackground.padding
|
radius: popupBackground.radius - popupBackground.padding
|
||||||
|
|
||||||
RowLayout {
|
RowLayout {
|
||||||
id: deleteRow
|
id: deleteRow
|
||||||
|
|
||||||
anchors.fill: parent
|
anchors.fill: parent
|
||||||
anchors.leftMargin: Tokens.padding.smaller
|
anchors.leftMargin: Tokens.padding.small
|
||||||
spacing: 8
|
spacing: 8
|
||||||
|
|
||||||
MaterialIcon {
|
MaterialIcon {
|
||||||
|
|||||||
@@ -205,7 +205,7 @@ Item {
|
|||||||
anchors.margins: 4
|
anchors.margins: 4
|
||||||
color: "white"
|
color: "white"
|
||||||
opacity: root.iconsRoot.selectedIcons.includes(root.filePath) ? 0.2 : 0.0
|
opacity: root.iconsRoot.selectedIcons.includes(root.filePath) ? 0.2 : 0.0
|
||||||
radius: Tokens.rounding.smallest
|
radius: Tokens.rounding.small
|
||||||
|
|
||||||
Behavior on opacity {
|
Behavior on opacity {
|
||||||
Anim {
|
Anim {
|
||||||
@@ -265,7 +265,7 @@ Item {
|
|||||||
anchors.margins: 4
|
anchors.margins: 4
|
||||||
color: "white"
|
color: "white"
|
||||||
opacity: parent.containsMouse ? 0.1 : 0.0
|
opacity: parent.containsMouse ? 0.1 : 0.0
|
||||||
radius: Tokens.rounding.smallest
|
radius: Tokens.rounding.small
|
||||||
|
|
||||||
Behavior on opacity {
|
Behavior on opacity {
|
||||||
Anim {
|
Anim {
|
||||||
|
|||||||
@@ -22,10 +22,10 @@ Item {
|
|||||||
property string draggedAppId: ""
|
property string draggedAppId: ""
|
||||||
property var draggedModelData: null
|
property var draggedModelData: null
|
||||||
property bool dropAnimating: false
|
property bool dropAnimating: false
|
||||||
readonly property int padding: Tokens.padding.small
|
readonly property int padding: Tokens.padding.extraSmall
|
||||||
required property var panels
|
required property var panels
|
||||||
property var pendingCommitIds: []
|
property var pendingCommitIds: []
|
||||||
readonly property int rounding: Tokens.rounding.large
|
readonly property int rounding: Tokens.rounding.largeIncreased
|
||||||
required property ShellScreen screen
|
required property ShellScreen screen
|
||||||
required property PersistentProperties visibilities
|
required property PersistentProperties visibilities
|
||||||
property var visualIds: []
|
property var visualIds: []
|
||||||
@@ -247,7 +247,7 @@ Item {
|
|||||||
property bool enableAddAnimation: false
|
property bool enableAddAnimation: false
|
||||||
|
|
||||||
anchors.left: parent.left
|
anchors.left: parent.left
|
||||||
anchors.margins: Tokens.padding.small
|
anchors.margins: Tokens.padding.extraSmall
|
||||||
anchors.top: parent.top
|
anchors.top: parent.top
|
||||||
boundsBehavior: Flickable.StopAtBounds
|
boundsBehavior: Flickable.StopAtBounds
|
||||||
height: Config.dock.height
|
height: Config.dock.height
|
||||||
@@ -255,7 +255,7 @@ Item {
|
|||||||
interactive: !(root.dragActive || root.dropAnimating)
|
interactive: !(root.dragActive || root.dropAnimating)
|
||||||
model: visualModel
|
model: visualModel
|
||||||
orientation: ListView.Horizontal
|
orientation: ListView.Horizontal
|
||||||
spacing: Tokens.padding.smaller
|
spacing: Tokens.padding.small
|
||||||
|
|
||||||
add: Transition {
|
add: Transition {
|
||||||
ParallelAnimation {
|
ParallelAnimation {
|
||||||
|
|||||||
@@ -23,7 +23,7 @@ CustomRect {
|
|||||||
|
|
||||||
implicitHeight: Config.dock.height
|
implicitHeight: Config.dock.height
|
||||||
implicitWidth: isSeparator ? 1 : implicitHeight
|
implicitWidth: isSeparator ? 1 : implicitHeight
|
||||||
radius: Tokens.rounding.normal - Tokens.padding.small
|
radius: Tokens.rounding.medium - Tokens.padding.extraSmall
|
||||||
|
|
||||||
Loader {
|
Loader {
|
||||||
active: !isSeparator
|
active: !isSeparator
|
||||||
|
|||||||
@@ -5,9 +5,9 @@ import ZShell.Config
|
|||||||
import qs.Services
|
import qs.Services
|
||||||
|
|
||||||
CustomRect {
|
CustomRect {
|
||||||
Layout.bottomMargin: dockRow.padding + Tokens.rounding.normal
|
Layout.bottomMargin: dockRow.padding + Tokens.rounding.medium
|
||||||
Layout.fillHeight: true
|
Layout.fillHeight: true
|
||||||
Layout.topMargin: dockRow.padding + Tokens.rounding.normal
|
Layout.topMargin: dockRow.padding + Tokens.rounding.medium
|
||||||
color: Colors.palette.m3outlineVariant
|
color: Colors.palette.m3outlineVariant
|
||||||
implicitWidth: 1
|
implicitWidth: 1
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -24,7 +24,7 @@ Item {
|
|||||||
Behavior on offsetScale {
|
Behavior on offsetScale {
|
||||||
Anim {
|
Anim {
|
||||||
duration: Tokens.anim.durations.expressiveDefaultSpatial
|
duration: Tokens.anim.durations.expressiveDefaultSpatial
|
||||||
easing.bezierCurve: Tokens.anim.curves.expressiveDefaultSpatial
|
easing: Tokens.anim.expressiveDefaultSpatial
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -33,8 +33,8 @@ Item {
|
|||||||
drawing.drawingState.penColor = Qt.hsva(huePicker.currentHue, saturationSlider.value, brightnessSlider.value, drawing.drawingState.penColor.a);
|
drawing.drawingState.penColor = Qt.hsva(huePicker.currentHue, saturationSlider.value, brightnessSlider.value, drawing.drawingState.penColor.a);
|
||||||
}
|
}
|
||||||
|
|
||||||
implicitHeight: column.height + Tokens.padding.larger * 2
|
implicitHeight: column.height + Tokens.padding.small * 2
|
||||||
implicitWidth: huePicker.implicitWidth + Tokens.padding.normal * 2
|
implicitWidth: huePicker.implicitWidth + Tokens.padding.small * 2
|
||||||
|
|
||||||
Component.onCompleted: syncFromPenColor()
|
Component.onCompleted: syncFromPenColor()
|
||||||
|
|
||||||
@@ -97,7 +97,7 @@ Item {
|
|||||||
|
|
||||||
anchors.left: parent.left
|
anchors.left: parent.left
|
||||||
anchors.right: parent.right
|
anchors.right: parent.right
|
||||||
spacing: Tokens.spacing.normal
|
spacing: Tokens.spacing.medium
|
||||||
|
|
||||||
Repeater {
|
Repeater {
|
||||||
model: root.colors1
|
model: root.colors1
|
||||||
@@ -113,7 +113,7 @@ Item {
|
|||||||
|
|
||||||
anchors.left: parent.left
|
anchors.left: parent.left
|
||||||
anchors.right: parent.right
|
anchors.right: parent.right
|
||||||
spacing: Tokens.spacing.normal
|
spacing: Tokens.spacing.medium
|
||||||
|
|
||||||
Repeater {
|
Repeater {
|
||||||
model: root.colors2
|
model: root.colors2
|
||||||
@@ -172,7 +172,7 @@ Item {
|
|||||||
}
|
}
|
||||||
|
|
||||||
IconButton {
|
IconButton {
|
||||||
anchors.margins: Tokens.padding.normal
|
anchors.margins: Tokens.padding.small
|
||||||
anchors.right: parent.right
|
anchors.right: parent.right
|
||||||
anchors.top: parent.top
|
anchors.top: parent.top
|
||||||
checked: root.wrapper.pinned
|
checked: root.wrapper.pinned
|
||||||
|
|||||||
@@ -49,13 +49,13 @@ Item {
|
|||||||
Behavior on implicitWidth {
|
Behavior on implicitWidth {
|
||||||
Anim {
|
Anim {
|
||||||
duration: Tokens.anim.durations.expressiveDefaultSpatial
|
duration: Tokens.anim.durations.expressiveDefaultSpatial
|
||||||
easing.bezierCurve: Tokens.anim.curves.expressiveDefaultSpatial
|
easing: Tokens.anim.expressiveDefaultSpatial
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
Behavior on offsetScale {
|
Behavior on offsetScale {
|
||||||
Anim {
|
Anim {
|
||||||
duration: Tokens.anim.durations.expressiveDefaultSpatial
|
duration: Tokens.anim.durations.expressiveDefaultSpatial
|
||||||
easing.bezierCurve: Tokens.anim.curves.expressiveDefaultSpatial
|
easing: Tokens.anim.expressiveDefaultSpatial
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -99,13 +99,13 @@ CustomListView {
|
|||||||
implicitHeight: root.currentItem?.implicitHeight ?? 0
|
implicitHeight: root.currentItem?.implicitHeight ?? 0
|
||||||
implicitWidth: root.width
|
implicitWidth: root.width
|
||||||
opacity: 0.08
|
opacity: 0.08
|
||||||
radius: Tokens.rounding.smallest
|
radius: Tokens.rounding.medium
|
||||||
y: root.currentItem?.y ?? 0
|
y: root.currentItem?.y ?? 0
|
||||||
|
|
||||||
Behavior on y {
|
Behavior on y {
|
||||||
Anim {
|
Anim {
|
||||||
duration: Tokens.anim.durations.small
|
duration: Tokens.anim.durations.small
|
||||||
easing.bezierCurve: Tokens.anim.curves.expressiveEffects
|
easing: Tokens.anim.expressiveDefaultEffects
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@@ -170,7 +170,7 @@ CustomListView {
|
|||||||
ParallelAnimation {
|
ParallelAnimation {
|
||||||
Anim {
|
Anim {
|
||||||
duration: Tokens.anim.durations.small
|
duration: Tokens.anim.durations.small
|
||||||
easing.bezierCurve: Tokens.anim.curves.standardAccel
|
easing: Tokens.anim.standardAccel
|
||||||
from: 1
|
from: 1
|
||||||
property: "opacity"
|
property: "opacity"
|
||||||
target: root
|
target: root
|
||||||
@@ -179,7 +179,7 @@ CustomListView {
|
|||||||
|
|
||||||
Anim {
|
Anim {
|
||||||
duration: Tokens.anim.durations.small
|
duration: Tokens.anim.durations.small
|
||||||
easing.bezierCurve: Tokens.anim.curves.standardAccel
|
easing: Tokens.anim.standardAccel
|
||||||
from: 1
|
from: 1
|
||||||
property: "scale"
|
property: "scale"
|
||||||
target: root
|
target: root
|
||||||
@@ -205,7 +205,7 @@ CustomListView {
|
|||||||
ParallelAnimation {
|
ParallelAnimation {
|
||||||
Anim {
|
Anim {
|
||||||
duration: Tokens.anim.durations.small
|
duration: Tokens.anim.durations.small
|
||||||
easing.bezierCurve: Tokens.anim.curves.standardDecel
|
easing: Tokens.anim.standardDecel
|
||||||
from: 0
|
from: 0
|
||||||
property: "opacity"
|
property: "opacity"
|
||||||
target: root
|
target: root
|
||||||
@@ -214,7 +214,7 @@ CustomListView {
|
|||||||
|
|
||||||
Anim {
|
Anim {
|
||||||
duration: Tokens.anim.durations.small
|
duration: Tokens.anim.durations.small
|
||||||
easing.bezierCurve: Tokens.anim.curves.standardDecel
|
easing: Tokens.anim.standardDecel
|
||||||
from: 0.9
|
from: 0.9
|
||||||
property: "scale"
|
property: "scale"
|
||||||
target: root
|
target: root
|
||||||
|
|||||||
@@ -21,7 +21,7 @@ CarouselView {
|
|||||||
focalWidth: Config.launcher.sizes.wallpaperWidth
|
focalWidth: Config.launcher.sizes.wallpaperWidth
|
||||||
glideDuration: 250
|
glideDuration: 250
|
||||||
glideEasingType: Easing.OutCubic
|
glideEasingType: Easing.OutCubic
|
||||||
implicitHeight: tileHeight + Tokens.spacing.small / 2 + Tokens.padding.large + Tokens.padding.normal
|
implicitHeight: tileHeight + Tokens.spacing.small / 2 + Tokens.padding.large + Tokens.padding.small
|
||||||
itemSpacing: Tokens.spacing.small
|
itemSpacing: Tokens.spacing.small
|
||||||
maxWidth: {
|
maxWidth: {
|
||||||
if (!screen)
|
if (!screen)
|
||||||
|
|||||||
@@ -12,9 +12,9 @@ Item {
|
|||||||
id: root
|
id: root
|
||||||
|
|
||||||
required property real maxHeight
|
required property real maxHeight
|
||||||
readonly property int padding: Tokens.padding.small
|
readonly property int padding: Tokens.padding.largeIncreased / 4
|
||||||
required property var panels
|
required property var panels
|
||||||
readonly property int rounding: Tokens.rounding.large
|
readonly property int rounding: Tokens.rounding.largeIncreased
|
||||||
required property PersistentProperties visibilities
|
required property PersistentProperties visibilities
|
||||||
|
|
||||||
implicitHeight: search.height + listWrapper.height + padding * 2
|
implicitHeight: search.height + listWrapper.height + padding * 2
|
||||||
@@ -49,9 +49,9 @@ Item {
|
|||||||
anchors.left: parent.left
|
anchors.left: parent.left
|
||||||
anchors.margins: root.padding
|
anchors.margins: root.padding
|
||||||
anchors.right: parent.right
|
anchors.right: parent.right
|
||||||
bottomPadding: Tokens.padding.larger
|
bottomPadding: Tokens.padding.medium
|
||||||
placeholderText: qsTr("Type \"%1\" for commands").arg(Config.launcher.actionPrefix)
|
placeholderText: qsTr("Type \"%1\" for commands").arg(Config.launcher.actionPrefix)
|
||||||
topPadding: Tokens.padding.larger
|
topPadding: Tokens.padding.medium
|
||||||
|
|
||||||
Component.onCompleted: forceActiveFocus()
|
Component.onCompleted: forceActiveFocus()
|
||||||
Keys.onDownPressed: list.currentList?.decrementCurrentIndex()
|
Keys.onDownPressed: list.currentList?.decrementCurrentIndex()
|
||||||
|
|||||||
@@ -32,7 +32,7 @@ Item {
|
|||||||
|
|
||||||
Anim {
|
Anim {
|
||||||
duration: Tokens.anim.durations.small
|
duration: Tokens.anim.durations.small
|
||||||
easing.bezierCurve: Tokens.anim.curves.expressiveEffects
|
easing: Tokens.anim.expressiveDefaultEffects
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
Behavior on implicitWidth {
|
Behavior on implicitWidth {
|
||||||
@@ -40,7 +40,7 @@ Item {
|
|||||||
|
|
||||||
Anim {
|
Anim {
|
||||||
duration: Tokens.anim.durations.small
|
duration: Tokens.anim.durations.small
|
||||||
easing.bezierCurve: Tokens.anim.curves.expressiveEffects
|
easing: Tokens.anim.expressiveDefaultEffects
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
Behavior on state {
|
Behavior on state {
|
||||||
@@ -127,7 +127,7 @@ Item {
|
|||||||
opacity: root.currentList?.count === 0 ? 1 : 0
|
opacity: root.currentList?.count === 0 ? 1 : 0
|
||||||
padding: Tokens.padding.large
|
padding: Tokens.padding.large
|
||||||
scale: root.currentList?.count === 0 ? 1 : 0.5
|
scale: root.currentList?.count === 0 ? 1 : 0.5
|
||||||
spacing: Tokens.spacing.normal
|
spacing: Tokens.spacing.medium
|
||||||
|
|
||||||
Behavior on opacity {
|
Behavior on opacity {
|
||||||
Anim {
|
Anim {
|
||||||
|
|||||||
@@ -16,7 +16,7 @@ Item {
|
|||||||
implicitHeight: Config.launcher.sizes.itemHeight
|
implicitHeight: Config.launcher.sizes.itemHeight
|
||||||
|
|
||||||
StateLayer {
|
StateLayer {
|
||||||
radius: Tokens.rounding.smallest
|
radius: Tokens.rounding.small
|
||||||
|
|
||||||
onClicked: {
|
onClicked: {
|
||||||
root.modelData?.onClicked(root.list);
|
root.modelData?.onClicked(root.list);
|
||||||
@@ -25,9 +25,9 @@ Item {
|
|||||||
|
|
||||||
Item {
|
Item {
|
||||||
anchors.fill: parent
|
anchors.fill: parent
|
||||||
anchors.leftMargin: Tokens.padding.larger
|
anchors.leftMargin: Tokens.padding.small
|
||||||
anchors.margins: Tokens.padding.smaller
|
anchors.margins: Tokens.padding.small
|
||||||
anchors.rightMargin: Tokens.padding.larger
|
anchors.rightMargin: Tokens.padding.small
|
||||||
|
|
||||||
MaterialIcon {
|
MaterialIcon {
|
||||||
id: icon
|
id: icon
|
||||||
@@ -39,7 +39,7 @@ Item {
|
|||||||
|
|
||||||
Item {
|
Item {
|
||||||
anchors.left: icon.right
|
anchors.left: icon.right
|
||||||
anchors.leftMargin: Tokens.spacing.normal
|
anchors.leftMargin: Tokens.spacing.medium
|
||||||
anchors.verticalCenter: icon.verticalCenter
|
anchors.verticalCenter: icon.verticalCenter
|
||||||
implicitHeight: name.implicitHeight + desc.implicitHeight
|
implicitHeight: name.implicitHeight + desc.implicitHeight
|
||||||
implicitWidth: parent.width - icon.width
|
implicitWidth: parent.width - icon.width
|
||||||
@@ -59,7 +59,7 @@ Item {
|
|||||||
elide: Text.ElideRight
|
elide: Text.ElideRight
|
||||||
font.pointSize: Tokens.font.size.small
|
font.pointSize: Tokens.font.size.small
|
||||||
text: root.modelData?.desc ?? ""
|
text: root.modelData?.desc ?? ""
|
||||||
width: root.width - icon.width - Tokens.rounding.normal * 2
|
width: root.width - icon.width - Tokens.rounding.medium * 2
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -19,7 +19,7 @@ Item {
|
|||||||
implicitHeight: Config.launcher.sizes.itemHeight
|
implicitHeight: Config.launcher.sizes.itemHeight
|
||||||
|
|
||||||
StateLayer {
|
StateLayer {
|
||||||
radius: Tokens.rounding.smallest
|
radius: Tokens.rounding.small
|
||||||
|
|
||||||
onClicked: {
|
onClicked: {
|
||||||
Apps.launch(root.modelData);
|
Apps.launch(root.modelData);
|
||||||
@@ -29,9 +29,9 @@ Item {
|
|||||||
|
|
||||||
Item {
|
Item {
|
||||||
anchors.fill: parent
|
anchors.fill: parent
|
||||||
anchors.leftMargin: Tokens.padding.larger
|
anchors.leftMargin: Tokens.padding.medium
|
||||||
anchors.margins: Tokens.padding.smaller
|
anchors.margins: Tokens.padding.small
|
||||||
anchors.rightMargin: Tokens.padding.larger
|
anchors.rightMargin: Tokens.padding.medium
|
||||||
|
|
||||||
IconImage {
|
IconImage {
|
||||||
id: icon
|
id: icon
|
||||||
@@ -43,7 +43,7 @@ Item {
|
|||||||
|
|
||||||
Item {
|
Item {
|
||||||
anchors.left: icon.right
|
anchors.left: icon.right
|
||||||
anchors.leftMargin: Tokens.spacing.normal
|
anchors.leftMargin: Tokens.spacing.medium
|
||||||
anchors.verticalCenter: icon.verticalCenter
|
anchors.verticalCenter: icon.verticalCenter
|
||||||
implicitHeight: name.implicitHeight + comment.implicitHeight
|
implicitHeight: name.implicitHeight + comment.implicitHeight
|
||||||
implicitWidth: parent.width - icon.width
|
implicitWidth: parent.width - icon.width
|
||||||
@@ -63,7 +63,7 @@ Item {
|
|||||||
elide: Text.ElideRight
|
elide: Text.ElideRight
|
||||||
font.pointSize: Tokens.font.size.small
|
font.pointSize: Tokens.font.size.small
|
||||||
text: (root.modelData?.comment || root.modelData?.genericName || root.modelData?.name) ?? ""
|
text: (root.modelData?.comment || root.modelData?.genericName || root.modelData?.name) ?? ""
|
||||||
width: root.width - icon.width - Tokens.rounding.normal * 2
|
width: root.width - icon.width - Tokens.rounding.medium - Tokens.padding.medium * 2
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -24,7 +24,7 @@ Item {
|
|||||||
implicitHeight: Config.launcher.sizes.itemHeight
|
implicitHeight: Config.launcher.sizes.itemHeight
|
||||||
|
|
||||||
StateLayer {
|
StateLayer {
|
||||||
radius: Tokens.rounding.smallest
|
radius: Tokens.rounding.small
|
||||||
|
|
||||||
onClicked: {
|
onClicked: {
|
||||||
root.onClicked();
|
root.onClicked();
|
||||||
@@ -33,10 +33,10 @@ Item {
|
|||||||
|
|
||||||
RowLayout {
|
RowLayout {
|
||||||
anchors.left: parent.left
|
anchors.left: parent.left
|
||||||
anchors.margins: Tokens.padding.larger
|
anchors.margins: Tokens.padding.small
|
||||||
anchors.right: parent.right
|
anchors.right: parent.right
|
||||||
anchors.verticalCenter: parent.verticalCenter
|
anchors.verticalCenter: parent.verticalCenter
|
||||||
spacing: Tokens.spacing.normal
|
spacing: Tokens.spacing.medium
|
||||||
|
|
||||||
MaterialIcon {
|
MaterialIcon {
|
||||||
Layout.alignment: Qt.AlignVCenter
|
Layout.alignment: Qt.AlignVCenter
|
||||||
@@ -64,13 +64,13 @@ Item {
|
|||||||
Layout.alignment: Qt.AlignVCenter
|
Layout.alignment: Qt.AlignVCenter
|
||||||
clip: true
|
clip: true
|
||||||
color: Colors.palette.m3tertiary
|
color: Colors.palette.m3tertiary
|
||||||
implicitHeight: Math.max(label.implicitHeight, icon.implicitHeight) + Tokens.padding.small * 2
|
implicitHeight: Math.max(label.implicitHeight, icon.implicitHeight) + Tokens.padding.extraSmall * 2
|
||||||
implicitWidth: (stateLayer.containsMouse ? label.implicitWidth + label.anchors.rightMargin : 0) + icon.implicitWidth + Tokens.padding.normal * 2
|
implicitWidth: (stateLayer.containsMouse ? label.implicitWidth + label.anchors.rightMargin : 0) + icon.implicitWidth + Tokens.padding.small * 2
|
||||||
radius: Tokens.rounding.normal
|
radius: Tokens.rounding.medium
|
||||||
|
|
||||||
Behavior on implicitWidth {
|
Behavior on implicitWidth {
|
||||||
Anim {
|
Anim {
|
||||||
easing.bezierCurve: Tokens.anim.curves.expressiveEffects
|
easing: Tokens.anim.expressiveDefaultEffects
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -106,7 +106,7 @@ Item {
|
|||||||
id: icon
|
id: icon
|
||||||
|
|
||||||
anchors.right: parent.right
|
anchors.right: parent.right
|
||||||
anchors.rightMargin: Tokens.padding.normal
|
anchors.rightMargin: Tokens.padding.small
|
||||||
anchors.verticalCenter: parent.verticalCenter
|
anchors.verticalCenter: parent.verticalCenter
|
||||||
color: Colors.palette.m3onTertiary
|
color: Colors.palette.m3onTertiary
|
||||||
font.pointSize: Tokens.font.size.large
|
font.pointSize: Tokens.font.size.large
|
||||||
|
|||||||
@@ -15,7 +15,7 @@ Item {
|
|||||||
implicitHeight: Config.launcher.sizes.itemHeight
|
implicitHeight: Config.launcher.sizes.itemHeight
|
||||||
|
|
||||||
StateLayer {
|
StateLayer {
|
||||||
radius: Tokens.rounding.smallest
|
radius: Tokens.rounding.small
|
||||||
|
|
||||||
onClicked: {
|
onClicked: {
|
||||||
root.modelData?.onClicked(root.list);
|
root.modelData?.onClicked(root.list);
|
||||||
@@ -24,9 +24,9 @@ Item {
|
|||||||
|
|
||||||
Item {
|
Item {
|
||||||
anchors.fill: parent
|
anchors.fill: parent
|
||||||
anchors.leftMargin: Tokens.padding.larger
|
anchors.leftMargin: Tokens.padding.small
|
||||||
anchors.margins: Tokens.padding.smaller
|
anchors.margins: Tokens.padding.small
|
||||||
anchors.rightMargin: Tokens.padding.larger
|
anchors.rightMargin: Tokens.padding.small
|
||||||
|
|
||||||
MaterialIcon {
|
MaterialIcon {
|
||||||
id: icon
|
id: icon
|
||||||
@@ -38,10 +38,10 @@ Item {
|
|||||||
|
|
||||||
Column {
|
Column {
|
||||||
anchors.left: icon.right
|
anchors.left: icon.right
|
||||||
anchors.leftMargin: Tokens.spacing.larger
|
anchors.leftMargin: Tokens.spacing.large
|
||||||
anchors.verticalCenter: icon.verticalCenter
|
anchors.verticalCenter: icon.verticalCenter
|
||||||
spacing: 0
|
spacing: 0
|
||||||
width: parent.width - icon.width - anchors.leftMargin - (current.active ? current.width + Tokens.spacing.normal : 0)
|
width: parent.width - icon.width - anchors.leftMargin - (current.active ? current.width + Tokens.spacing.medium : 0)
|
||||||
|
|
||||||
CustomText {
|
CustomText {
|
||||||
font.pointSize: Tokens.font.size.normal
|
font.pointSize: Tokens.font.size.normal
|
||||||
|
|||||||
@@ -11,7 +11,7 @@ Item {
|
|||||||
|
|
||||||
property int contentHeight
|
property int contentHeight
|
||||||
readonly property real maxHeight: {
|
readonly property real maxHeight: {
|
||||||
let max = screen.height - Tokens.spacing.large * 2;
|
let max = screen.height - Tokens.spacing.largeIncreased * 2;
|
||||||
if (visibilities.resources && panels.resourcesWrapper.x + panels.resourcesWrapper.width > root.x)
|
if (visibilities.resources && panels.resourcesWrapper.x + panels.resourcesWrapper.width > root.x)
|
||||||
max -= panels.resources.nonAnimHeight;
|
max -= panels.resources.nonAnimHeight;
|
||||||
if (panels.popouts.hasCurrent)
|
if (panels.popouts.hasCurrent)
|
||||||
@@ -34,7 +34,7 @@ Item {
|
|||||||
Behavior on offsetScale {
|
Behavior on offsetScale {
|
||||||
Anim {
|
Anim {
|
||||||
duration: Tokens.anim.durations.expressiveDefaultSpatial
|
duration: Tokens.anim.durations.expressiveDefaultSpatial
|
||||||
easing.bezierCurve: Tokens.anim.curves.expressiveDefaultSpatial
|
easing: Tokens.anim.expressiveDefaultSpatial
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -19,7 +19,7 @@ ColumnLayout {
|
|||||||
Layout.fillHeight: true
|
Layout.fillHeight: true
|
||||||
Layout.fillWidth: false
|
Layout.fillWidth: false
|
||||||
Layout.preferredWidth: centerWidth
|
Layout.preferredWidth: centerWidth
|
||||||
spacing: Tokens.spacing.large * 2
|
spacing: Tokens.spacing.largeIncreased * 2
|
||||||
|
|
||||||
RowLayout {
|
RowLayout {
|
||||||
Layout.alignment: Qt.AlignHCenter
|
Layout.alignment: Qt.AlignHCenter
|
||||||
@@ -65,7 +65,7 @@ ColumnLayout {
|
|||||||
|
|
||||||
CustomClippingRect {
|
CustomClippingRect {
|
||||||
Layout.alignment: Qt.AlignHCenter
|
Layout.alignment: Qt.AlignHCenter
|
||||||
Layout.topMargin: Tokens.spacing.large * 2
|
Layout.topMargin: Tokens.spacing.largeIncreased * 2
|
||||||
color: Colors.tPalette.m3surfaceContainer
|
color: Colors.tPalette.m3surfaceContainer
|
||||||
implicitHeight: root.centerWidth / 2
|
implicitHeight: root.centerWidth / 2
|
||||||
implicitWidth: root.centerWidth / 2
|
implicitWidth: root.centerWidth / 2
|
||||||
@@ -90,7 +90,7 @@ ColumnLayout {
|
|||||||
Layout.alignment: Qt.AlignHCenter
|
Layout.alignment: Qt.AlignHCenter
|
||||||
color: Colors.tPalette.m3surfaceContainer
|
color: Colors.tPalette.m3surfaceContainer
|
||||||
focus: true
|
focus: true
|
||||||
implicitHeight: input.implicitHeight + Tokens.padding.small * 2
|
implicitHeight: input.implicitHeight + Tokens.padding.extraSmall * 2
|
||||||
implicitWidth: root.centerWidth * 0.8
|
implicitWidth: root.centerWidth * 0.8
|
||||||
radius: Tokens.rounding.full
|
radius: Tokens.rounding.full
|
||||||
|
|
||||||
@@ -121,11 +121,11 @@ ColumnLayout {
|
|||||||
id: input
|
id: input
|
||||||
|
|
||||||
anchors.fill: parent
|
anchors.fill: parent
|
||||||
anchors.margins: Tokens.padding.small
|
anchors.margins: Tokens.padding.extraSmall
|
||||||
spacing: Tokens.spacing.normal
|
spacing: Tokens.spacing.medium
|
||||||
|
|
||||||
Item {
|
Item {
|
||||||
implicitHeight: fprintIcon.implicitHeight + Tokens.padding.small * 2
|
implicitHeight: fprintIcon.implicitHeight + Tokens.padding.extraSmall * 2
|
||||||
implicitWidth: implicitHeight
|
implicitWidth: implicitHeight
|
||||||
|
|
||||||
MaterialIcon {
|
MaterialIcon {
|
||||||
@@ -163,7 +163,7 @@ ColumnLayout {
|
|||||||
|
|
||||||
CustomRect {
|
CustomRect {
|
||||||
color: root.lock.pam.buffer ? Colors.palette.m3primary : Colors.layer(Colors.palette.m3surfaceContainerHigh, 2)
|
color: root.lock.pam.buffer ? Colors.palette.m3primary : Colors.layer(Colors.palette.m3surfaceContainerHigh, 2)
|
||||||
implicitHeight: enterIcon.implicitHeight + Tokens.padding.small * 2
|
implicitHeight: enterIcon.implicitHeight + Tokens.padding.extraSmall * 2
|
||||||
implicitWidth: implicitHeight
|
implicitWidth: implicitHeight
|
||||||
radius: Tokens.rounding.full
|
radius: Tokens.rounding.full
|
||||||
|
|
||||||
@@ -189,7 +189,7 @@ ColumnLayout {
|
|||||||
|
|
||||||
Item {
|
Item {
|
||||||
Layout.fillWidth: true
|
Layout.fillWidth: true
|
||||||
Layout.topMargin: -Tokens.spacing.large
|
Layout.topMargin: -Tokens.spacing.largeIncreased
|
||||||
implicitHeight: Math.max(message.implicitHeight, stateMessage.implicitHeight)
|
implicitHeight: Math.max(message.implicitHeight, stateMessage.implicitHeight)
|
||||||
|
|
||||||
Behavior on implicitHeight {
|
Behavior on implicitHeight {
|
||||||
|
|||||||
@@ -12,17 +12,17 @@ CustomClippingRect {
|
|||||||
|
|
||||||
implicitHeight: layout.implicitHeight
|
implicitHeight: layout.implicitHeight
|
||||||
implicitWidth: layout.implicitWidth
|
implicitWidth: layout.implicitWidth
|
||||||
radius: Tokens.rounding.large
|
radius: Tokens.rounding.largeIncreased
|
||||||
|
|
||||||
RowLayout {
|
RowLayout {
|
||||||
id: layout
|
id: layout
|
||||||
|
|
||||||
anchors.fill: parent
|
anchors.fill: parent
|
||||||
spacing: Tokens.spacing.large * 2
|
spacing: Tokens.spacing.largeIncreased * 2
|
||||||
|
|
||||||
ColumnLayout {
|
ColumnLayout {
|
||||||
Layout.fillWidth: true
|
Layout.fillWidth: true
|
||||||
spacing: Tokens.spacing.normal
|
spacing: Tokens.spacing.medium
|
||||||
|
|
||||||
WeatherInfo {
|
WeatherInfo {
|
||||||
id: weather
|
id: weather
|
||||||
@@ -52,15 +52,15 @@ CustomClippingRect {
|
|||||||
|
|
||||||
ColumnLayout {
|
ColumnLayout {
|
||||||
Layout.fillWidth: true
|
Layout.fillWidth: true
|
||||||
spacing: Tokens.spacing.normal
|
spacing: Tokens.spacing.medium
|
||||||
|
|
||||||
CustomRect {
|
CustomRect {
|
||||||
Layout.fillHeight: true
|
Layout.fillHeight: true
|
||||||
Layout.fillWidth: true
|
Layout.fillWidth: true
|
||||||
bottomRightRadius: Tokens.rounding.large
|
bottomRightRadius: Tokens.rounding.largeIncreased
|
||||||
color: Colors.tPalette.m3surfaceContainer
|
color: Colors.tPalette.m3surfaceContainer
|
||||||
radius: Tokens.rounding.small
|
radius: Tokens.rounding.small
|
||||||
topRightRadius: Tokens.rounding.large
|
topRightRadius: Tokens.rounding.largeIncreased
|
||||||
|
|
||||||
NotifDock {
|
NotifDock {
|
||||||
lock: root.lock
|
lock: root.lock
|
||||||
|
|||||||
@@ -94,7 +94,7 @@ Item {
|
|||||||
Behavior on scale {
|
Behavior on scale {
|
||||||
Anim {
|
Anim {
|
||||||
duration: Tokens.anim.durations.expressiveFastSpatial
|
duration: Tokens.anim.durations.expressiveFastSpatial
|
||||||
easing.bezierCurve: Tokens.anim.curves.expressiveFastSpatial
|
easing: Tokens.anim.expressiveFastSpatial
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -31,7 +31,7 @@ WlSessionLockSurface {
|
|||||||
ParallelAnimation {
|
ParallelAnimation {
|
||||||
Anim {
|
Anim {
|
||||||
duration: Tokens.anim.durations.expressiveDefaultSpatial
|
duration: Tokens.anim.durations.expressiveDefaultSpatial
|
||||||
easing.bezierCurve: Tokens.anim.curves.expressiveDefaultSpatial
|
easing: Tokens.anim.expressiveDefaultSpatial
|
||||||
properties: "implicitWidth,implicitHeight"
|
properties: "implicitWidth,implicitHeight"
|
||||||
target: lockContent
|
target: lockContent
|
||||||
to: lockContent.size
|
to: lockContent.size
|
||||||
@@ -45,7 +45,7 @@ WlSessionLockSurface {
|
|||||||
|
|
||||||
Anim {
|
Anim {
|
||||||
duration: Tokens.anim.durations.expressiveDefaultSpatial
|
duration: Tokens.anim.durations.expressiveDefaultSpatial
|
||||||
easing.bezierCurve: Tokens.anim.curves.expressiveDefaultSpatial
|
easing: Tokens.anim.expressiveDefaultSpatial
|
||||||
property: "scale"
|
property: "scale"
|
||||||
target: content
|
target: content
|
||||||
to: 0
|
to: 0
|
||||||
@@ -94,7 +94,7 @@ WlSessionLockSurface {
|
|||||||
ParallelAnimation {
|
ParallelAnimation {
|
||||||
Anim {
|
Anim {
|
||||||
duration: Tokens.anim.durations.expressiveFastSpatial
|
duration: Tokens.anim.durations.expressiveFastSpatial
|
||||||
easing.bezierCurve: Tokens.anim.curves.expressiveFastSpatial
|
easing: Tokens.anim.expressiveFastSpatial
|
||||||
property: "scale"
|
property: "scale"
|
||||||
target: lockContent
|
target: lockContent
|
||||||
to: 1
|
to: 1
|
||||||
@@ -116,7 +116,7 @@ WlSessionLockSurface {
|
|||||||
|
|
||||||
Anim {
|
Anim {
|
||||||
duration: Tokens.anim.durations.expressiveDefaultSpatial
|
duration: Tokens.anim.durations.expressiveDefaultSpatial
|
||||||
easing.bezierCurve: Tokens.anim.curves.expressiveDefaultSpatial
|
easing: Tokens.anim.expressiveDefaultSpatial
|
||||||
property: "scale"
|
property: "scale"
|
||||||
target: content
|
target: content
|
||||||
to: 1
|
to: 1
|
||||||
@@ -125,12 +125,12 @@ WlSessionLockSurface {
|
|||||||
Anim {
|
Anim {
|
||||||
property: "radius"
|
property: "radius"
|
||||||
target: lockBg
|
target: lockBg
|
||||||
to: Tokens.rounding.large * 1.5
|
to: Tokens.rounding.largeIncreased * 1.5
|
||||||
}
|
}
|
||||||
|
|
||||||
Anim {
|
Anim {
|
||||||
duration: Tokens.anim.durations.expressiveDefaultSpatial
|
duration: Tokens.anim.durations.expressiveDefaultSpatial
|
||||||
easing.bezierCurve: Tokens.anim.curves.expressiveDefaultSpatial
|
easing: Tokens.anim.expressiveDefaultSpatial
|
||||||
property: "implicitWidth"
|
property: "implicitWidth"
|
||||||
target: lockContent
|
target: lockContent
|
||||||
to: (root.screen?.height ?? 0) * Config.lock.sizes.heightMult * Config.lock.sizes.ratio
|
to: (root.screen?.height ?? 0) * Config.lock.sizes.heightMult * Config.lock.sizes.ratio
|
||||||
@@ -138,7 +138,7 @@ WlSessionLockSurface {
|
|||||||
|
|
||||||
Anim {
|
Anim {
|
||||||
duration: Tokens.anim.durations.expressiveDefaultSpatial
|
duration: Tokens.anim.durations.expressiveDefaultSpatial
|
||||||
easing.bezierCurve: Tokens.anim.curves.expressiveDefaultSpatial
|
easing: Tokens.anim.expressiveDefaultSpatial
|
||||||
property: "implicitHeight"
|
property: "implicitHeight"
|
||||||
target: lockContent
|
target: lockContent
|
||||||
to: (root.screen?.height ?? 0) * Config.lock.sizes.heightMult
|
to: (root.screen?.height ?? 0) * Config.lock.sizes.heightMult
|
||||||
|
|||||||
@@ -57,7 +57,7 @@ CustomClippingRect {
|
|||||||
animate: true
|
animate: true
|
||||||
color: Colors.palette.m3primary
|
color: Colors.palette.m3primary
|
||||||
elide: Text.ElideRight
|
elide: Text.ElideRight
|
||||||
font.pointSize: Tokens.font.size.medium
|
font.pointSize: Tokens.font.size.normal
|
||||||
horizontalAlignment: Text.AlignHCenter
|
horizontalAlignment: Text.AlignHCenter
|
||||||
text: (Players.active?.trackTitle ?? qsTr("Nothing playing")) || qsTr("Unknown track")
|
text: (Players.active?.trackTitle ?? qsTr("Nothing playing")) || qsTr("Unknown track")
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -18,7 +18,7 @@ ColumnLayout {
|
|||||||
|
|
||||||
anchors.fill: parent
|
anchors.fill: parent
|
||||||
anchors.margins: Tokens.padding.large
|
anchors.margins: Tokens.padding.large
|
||||||
spacing: Tokens.spacing.smaller
|
spacing: Tokens.spacing.small
|
||||||
|
|
||||||
CustomText {
|
CustomText {
|
||||||
Layout.fillWidth: true
|
Layout.fillWidth: true
|
||||||
@@ -48,7 +48,7 @@ ColumnLayout {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
sourceComponent: ColumnLayout {
|
sourceComponent: ColumnLayout {
|
||||||
spacing: Tokens.spacing.large
|
spacing: Tokens.spacing.largeIncreased
|
||||||
|
|
||||||
Image {
|
Image {
|
||||||
asynchronous: true
|
asynchronous: true
|
||||||
@@ -88,7 +88,7 @@ ColumnLayout {
|
|||||||
|
|
||||||
Anim {
|
Anim {
|
||||||
duration: Tokens.anim.durations.expressiveDefaultSpatial
|
duration: Tokens.anim.durations.expressiveDefaultSpatial
|
||||||
easing.bezierCurve: Tokens.anim.curves.expressiveDefaultSpatial
|
easing: Tokens.anim.expressiveDefaultSpatial
|
||||||
from: 0
|
from: 0
|
||||||
property: "scale"
|
property: "scale"
|
||||||
to: 1
|
to: 1
|
||||||
@@ -104,7 +104,7 @@ ColumnLayout {
|
|||||||
|
|
||||||
Anim {
|
Anim {
|
||||||
duration: Tokens.anim.durations.expressiveDefaultSpatial
|
duration: Tokens.anim.durations.expressiveDefaultSpatial
|
||||||
easing.bezierCurve: Tokens.anim.curves.expressiveDefaultSpatial
|
easing: Tokens.anim.expressiveDefaultSpatial
|
||||||
property: "y"
|
property: "y"
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@@ -122,7 +122,7 @@ ColumnLayout {
|
|||||||
|
|
||||||
Anim {
|
Anim {
|
||||||
duration: Tokens.anim.durations.expressiveDefaultSpatial
|
duration: Tokens.anim.durations.expressiveDefaultSpatial
|
||||||
easing.bezierCurve: Tokens.anim.curves.expressiveDefaultSpatial
|
easing: Tokens.anim.expressiveDefaultSpatial
|
||||||
property: "y"
|
property: "y"
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
+12
-12
@@ -26,13 +26,13 @@ CustomRect {
|
|||||||
anchors.right: parent?.right
|
anchors.right: parent?.right
|
||||||
clip: true
|
clip: true
|
||||||
color: root.urgency === "critical" ? Colors.palette.m3secondaryContainer : Colors.layer(Colors.palette.m3surfaceContainerHigh, 2)
|
color: root.urgency === "critical" ? Colors.palette.m3secondaryContainer : Colors.layer(Colors.palette.m3surfaceContainerHigh, 2)
|
||||||
implicitHeight: content.implicitHeight + Tokens.padding.normal * 2
|
implicitHeight: content.implicitHeight + Tokens.padding.small * 2
|
||||||
radius: Tokens.rounding.normal
|
radius: Tokens.rounding.medium
|
||||||
|
|
||||||
Behavior on implicitHeight {
|
Behavior on implicitHeight {
|
||||||
Anim {
|
Anim {
|
||||||
duration: Tokens.anim.durations.expressiveDefaultSpatial
|
duration: Tokens.anim.durations.expressiveDefaultSpatial
|
||||||
easing.bezierCurve: Tokens.anim.curves.expressiveDefaultSpatial
|
easing: Tokens.anim.expressiveDefaultSpatial
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -40,10 +40,10 @@ CustomRect {
|
|||||||
id: content
|
id: content
|
||||||
|
|
||||||
anchors.left: parent.left
|
anchors.left: parent.left
|
||||||
anchors.margins: Tokens.padding.normal
|
anchors.margins: Tokens.padding.small
|
||||||
anchors.right: parent.right
|
anchors.right: parent.right
|
||||||
anchors.top: parent.top
|
anchors.top: parent.top
|
||||||
spacing: Tokens.spacing.normal
|
spacing: Tokens.spacing.medium
|
||||||
|
|
||||||
Item {
|
Item {
|
||||||
Layout.alignment: Qt.AlignLeft | Qt.AlignTop
|
Layout.alignment: Qt.AlignLeft | Qt.AlignTop
|
||||||
@@ -119,15 +119,15 @@ CustomRect {
|
|||||||
}
|
}
|
||||||
|
|
||||||
ColumnLayout {
|
ColumnLayout {
|
||||||
Layout.bottomMargin: -Tokens.padding.small / 2 - (root.expanded ? 0 : spacing)
|
Layout.bottomMargin: -Tokens.padding.extraSmall / 2 - (root.expanded ? 0 : spacing)
|
||||||
Layout.fillWidth: true
|
Layout.fillWidth: true
|
||||||
Layout.topMargin: -Tokens.padding.small
|
Layout.topMargin: -Tokens.padding.extraSmall
|
||||||
spacing: Math.round(Tokens.spacing.small / 2)
|
spacing: Math.round(Tokens.spacing.small / 2)
|
||||||
|
|
||||||
RowLayout {
|
RowLayout {
|
||||||
Layout.bottomMargin: -parent.spacing
|
Layout.bottomMargin: -parent.spacing
|
||||||
Layout.fillWidth: true
|
Layout.fillWidth: true
|
||||||
spacing: Tokens.spacing.smaller
|
spacing: Tokens.spacing.small
|
||||||
|
|
||||||
CustomText {
|
CustomText {
|
||||||
Layout.fillWidth: true
|
Layout.fillWidth: true
|
||||||
@@ -147,8 +147,8 @@ CustomRect {
|
|||||||
CustomRect {
|
CustomRect {
|
||||||
Layout.preferredWidth: root.notifs.length > Config.notifs.groupPreviewNum ? implicitWidth : 0
|
Layout.preferredWidth: root.notifs.length > Config.notifs.groupPreviewNum ? implicitWidth : 0
|
||||||
color: root.urgency === "critical" ? Colors.palette.m3error : Colors.layer(Colors.palette.m3surfaceContainerHighest, 2)
|
color: root.urgency === "critical" ? Colors.palette.m3error : Colors.layer(Colors.palette.m3surfaceContainerHighest, 2)
|
||||||
implicitHeight: groupCount.implicitHeight + Tokens.padding.small
|
implicitHeight: groupCount.implicitHeight + Tokens.padding.extraSmall
|
||||||
implicitWidth: expandBtn.implicitWidth + Tokens.padding.smaller * 2
|
implicitWidth: expandBtn.implicitWidth + Tokens.padding.small * 2
|
||||||
opacity: root.notifs.length > Config.notifs.groupPreviewNum ? 1 : 0
|
opacity: root.notifs.length > Config.notifs.groupPreviewNum ? 1 : 0
|
||||||
radius: Tokens.rounding.full
|
radius: Tokens.rounding.full
|
||||||
|
|
||||||
@@ -178,7 +178,7 @@ CustomRect {
|
|||||||
CustomText {
|
CustomText {
|
||||||
id: groupCount
|
id: groupCount
|
||||||
|
|
||||||
Layout.leftMargin: Tokens.padding.small / 2
|
Layout.leftMargin: Tokens.padding.extraSmall / 2
|
||||||
animate: true
|
animate: true
|
||||||
color: root.urgency === "critical" ? Colors.palette.m3onError : Colors.palette.m3onSurface
|
color: root.urgency === "critical" ? Colors.palette.m3onError : Colors.palette.m3onSurface
|
||||||
font.pointSize: Tokens.font.size.small
|
font.pointSize: Tokens.font.size.small
|
||||||
@@ -186,7 +186,7 @@ CustomRect {
|
|||||||
}
|
}
|
||||||
|
|
||||||
MaterialIcon {
|
MaterialIcon {
|
||||||
Layout.rightMargin: -Tokens.padding.small / 2
|
Layout.rightMargin: -Tokens.padding.extraSmall / 2
|
||||||
animate: true
|
animate: true
|
||||||
color: root.urgency === "critical" ? Colors.palette.m3onError : Colors.palette.m3onSurface
|
color: root.urgency === "critical" ? Colors.palette.m3onError : Colors.palette.m3onSurface
|
||||||
text: root.expanded ? "expand_less" : "expand_more"
|
text: root.expanded ? "expand_less" : "expand_more"
|
||||||
|
|||||||
@@ -38,7 +38,7 @@ CustomRect {
|
|||||||
|
|
||||||
anchors.fill: parent
|
anchors.fill: parent
|
||||||
anchors.margins: Tokens.padding.large
|
anchors.margins: Tokens.padding.large
|
||||||
spacing: Tokens.spacing.large
|
spacing: Tokens.spacing.largeIncreased
|
||||||
|
|
||||||
Resource {
|
Resource {
|
||||||
id: cpu
|
id: cpu
|
||||||
|
|||||||
@@ -53,7 +53,7 @@ ColumnLayout {
|
|||||||
Layout.alignment: Qt.AlignHCenter
|
Layout.alignment: Qt.AlignHCenter
|
||||||
animate: true
|
animate: true
|
||||||
color: Colors.palette.m3onSurfaceVariant
|
color: Colors.palette.m3onSurfaceVariant
|
||||||
font.pointSize: Tokens.font.size.medium
|
font.pointSize: Tokens.font.size.normal
|
||||||
text: {
|
text: {
|
||||||
const today = Weather.forecast[0];
|
const today = Weather.forecast[0];
|
||||||
return qsTr("High %1 • Low %2").arg(Weather.formatTemp(today?.maxTempC)).arg(Weather.formatTemp(today?.minTempC));
|
return qsTr("High %1 • Low %2").arg(Weather.formatTemp(today?.maxTempC)).arg(Weather.formatTemp(today?.minTempC));
|
||||||
|
|||||||
@@ -24,14 +24,14 @@ CustomRect {
|
|||||||
|
|
||||||
MaterialIcon {
|
MaterialIcon {
|
||||||
Layout.topMargin: Math.round(fontInfo.pointSize * 0.12)
|
Layout.topMargin: Math.round(fontInfo.pointSize * 0.12)
|
||||||
font.pointSize: Tokens.font.size.medium
|
font.pointSize: Tokens.font.size.normal
|
||||||
text: "schedule"
|
text: "schedule"
|
||||||
}
|
}
|
||||||
|
|
||||||
CustomText {
|
CustomText {
|
||||||
id: title
|
id: title
|
||||||
|
|
||||||
font.pointSize: Tokens.font.size.medium
|
font.pointSize: Tokens.font.size.normal
|
||||||
text: qsTr("Hourly forecast")
|
text: qsTr("Hourly forecast")
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@@ -47,7 +47,7 @@ CustomRect {
|
|||||||
implicitHeight: contentItem.childrenRect.height
|
implicitHeight: contentItem.childrenRect.height
|
||||||
model: Weather.hourlyForecast
|
model: Weather.hourlyForecast
|
||||||
orientation: VerticalFadeListView.Horizontal
|
orientation: VerticalFadeListView.Horizontal
|
||||||
spacing: Tokens.spacing.normal
|
spacing: Tokens.spacing.medium
|
||||||
|
|
||||||
delegate: ColumnLayout {
|
delegate: ColumnLayout {
|
||||||
id: hour
|
id: hour
|
||||||
@@ -61,7 +61,7 @@ CustomRect {
|
|||||||
MaterialShape {
|
MaterialShape {
|
||||||
Layout.alignment: Qt.AlignHCenter
|
Layout.alignment: Qt.AlignHCenter
|
||||||
color: Qt.alpha(Colors.palette.m3primary, hour.index === 0 ? 1 : 0)
|
color: Qt.alpha(Colors.palette.m3primary, hour.index === 0 ? 1 : 0)
|
||||||
implicitSize: temp.implicitHeight + Tokens.padding.normal * 2
|
implicitSize: temp.implicitHeight + Tokens.padding.small * 2
|
||||||
shape: MaterialShape.Cookie4Sided
|
shape: MaterialShape.Cookie4Sided
|
||||||
|
|
||||||
Behavior on color {
|
Behavior on color {
|
||||||
@@ -74,7 +74,7 @@ CustomRect {
|
|||||||
|
|
||||||
anchors.centerIn: parent
|
anchors.centerIn: parent
|
||||||
color: hour.index === 0 ? Colors.palette.m3onPrimary : Colors.palette.m3onSurface
|
color: hour.index === 0 ? Colors.palette.m3onPrimary : Colors.palette.m3onSurface
|
||||||
font.pointSize: Tokens.font.size.medium
|
font.pointSize: Tokens.font.size.normal
|
||||||
text: Weather.formatTemp(hour.cond.tempC).slice(0, -1) // Remove C/F
|
text: Weather.formatTemp(hour.cond.tempC).slice(0, -1) // Remove C/F
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -15,7 +15,7 @@ CustomRect {
|
|||||||
implicitHeight: {
|
implicitHeight: {
|
||||||
const base = brief.implicitHeight + brief.anchors.topMargin;
|
const base = brief.implicitHeight + brief.anchors.topMargin;
|
||||||
if (showForecast)
|
if (showForecast)
|
||||||
return base + Tokens.spacing.large + forecast.implicitHeight + forecast.anchors.margins;
|
return base + Tokens.spacing.largeIncreased + forecast.implicitHeight + forecast.anchors.margins;
|
||||||
return base + brief.anchors.topMargin;
|
return base + brief.anchors.topMargin;
|
||||||
}
|
}
|
||||||
radius: Tokens.rounding.small
|
radius: Tokens.rounding.small
|
||||||
|
|||||||
@@ -11,7 +11,7 @@ import qs.Helpers
|
|||||||
Item {
|
Item {
|
||||||
id: root
|
id: root
|
||||||
|
|
||||||
readonly property int padding: Tokens.padding.smaller
|
readonly property int padding: Tokens.padding.small
|
||||||
required property Item panels
|
required property Item panels
|
||||||
required property PersistentProperties visibilities
|
required property PersistentProperties visibilities
|
||||||
|
|
||||||
@@ -55,7 +55,7 @@ Item {
|
|||||||
anchors.fill: parent
|
anchors.fill: parent
|
||||||
anchors.margins: root.padding
|
anchors.margins: root.padding
|
||||||
color: "transparent"
|
color: "transparent"
|
||||||
radius: Tokens.rounding.normal - root.padding
|
radius: Tokens.rounding.medium - root.padding
|
||||||
|
|
||||||
CustomListView {
|
CustomListView {
|
||||||
id: list
|
id: list
|
||||||
@@ -93,7 +93,7 @@ Item {
|
|||||||
|
|
||||||
component Anim: NumberAnimation {
|
component Anim: NumberAnimation {
|
||||||
duration: Tokens.anim.durations.expressiveDefaultSpatial
|
duration: Tokens.anim.durations.expressiveDefaultSpatial
|
||||||
easing.bezierCurve: Tokens.anim.curves.expressiveDefaultSpatial
|
easing: Tokens.anim.expressiveDefaultSpatial
|
||||||
}
|
}
|
||||||
component NotifWrapper: Item {
|
component NotifWrapper: Item {
|
||||||
id: wrapper
|
id: wrapper
|
||||||
|
|||||||
@@ -27,7 +27,7 @@ CustomRect {
|
|||||||
|
|
||||||
Behavior on x {
|
Behavior on x {
|
||||||
Anim {
|
Anim {
|
||||||
easing.bezierCurve: Tokens.anim.curves.emphasizedDecel
|
easing: Tokens.anim.emphasizedDecel
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -88,7 +88,7 @@ CustomRect {
|
|||||||
id: inner
|
id: inner
|
||||||
|
|
||||||
anchors.left: parent.left
|
anchors.left: parent.left
|
||||||
anchors.margins: Tokens.padding.normal
|
anchors.margins: Tokens.padding.small
|
||||||
anchors.right: parent.right
|
anchors.right: parent.right
|
||||||
anchors.top: parent.top
|
anchors.top: parent.top
|
||||||
implicitHeight: root.nonAnimHeight
|
implicitHeight: root.nonAnimHeight
|
||||||
@@ -204,7 +204,7 @@ CustomRect {
|
|||||||
|
|
||||||
Behavior on sweepAngle {
|
Behavior on sweepAngle {
|
||||||
Anim {
|
Anim {
|
||||||
easing.bezierCurve: Tokens.anim.curves.emphasizedDecel
|
easing: Tokens.anim.emphasizedDecel
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@@ -471,7 +471,7 @@ CustomRect {
|
|||||||
isRound: true
|
isRound: true
|
||||||
label.anchors.centerIn: undefined
|
label.anchors.centerIn: undefined
|
||||||
label.anchors.left: left
|
label.anchors.left: left
|
||||||
label.anchors.margins: Tokens.padding.normal
|
label.anchors.margins: Tokens.padding.small
|
||||||
label.anchors.right: right
|
label.anchors.right: right
|
||||||
label.anchors.verticalCenter: verticalCenter
|
label.anchors.verticalCenter: verticalCenter
|
||||||
label.elide: Text.ElideRight
|
label.elide: Text.ElideRight
|
||||||
|
|||||||
Some files were not shown because too many files have changed in this diff Show More
Reference in New Issue
Block a user