fix weird gaps and indents in InterfaceConfig

This commit is contained in:
darksignal7
2025-10-05 21:39:51 +03:00
parent d95147712b
commit 94fb563a15
@@ -43,10 +43,6 @@ ContentPage {
} }
} }
ContentSubsection { ContentSubsection {
title: Translation.tr("Clock style") title: Translation.tr("Clock style")
ConfigSelectionArray { ConfigSelectionArray {
@@ -69,7 +65,6 @@ ContentPage {
} }
} }
ConfigRow{ ConfigRow{
visible: Config.options.background.clock.style === "cookie" visible: Config.options.background.clock.style === "cookie"
ContentSubsection { ContentSubsection {
@@ -120,162 +115,157 @@ ContentPage {
} }
ContentSubsection {
ContentSubsection { enabled: Config.options.background.clock.style === "cookie"
enabled: Config.options.background.clock.style === "cookie" visible: enabled
visible: enabled title: Translation.tr("Hour hand style")
title: Translation.tr("Hour hand style") ConfigSelectionArray {
ConfigSelectionArray { currentValue: Config.options.background.clock.cookie.hourHandStyle
currentValue: Config.options.background.clock.cookie.hourHandStyle onSelected: newValue => {
onSelected: newValue => { Config.options.background.clock.cookie.hourHandStyle = newValue;
Config.options.background.clock.cookie.hourHandStyle = newValue;
}
options: [
{
displayName: Translation.tr("Classic"),
icon: "radio",
value: "classic"
},
{
displayName: Translation.tr("Stroke"),
icon: "stroke_partial",
value: "stroke"
},
{
displayName: Translation.tr("Fill"),
icon: "stroke_full",
value: "fill"
},
{
displayName: Translation.tr("Hide"),
icon: "deselect",
value: "hide"
}
]
} }
options: [
{
displayName: Translation.tr("Classic"),
icon: "radio",
value: "classic"
},
{
displayName: Translation.tr("Stroke"),
icon: "stroke_partial",
value: "stroke"
},
{
displayName: Translation.tr("Fill"),
icon: "stroke_full",
value: "fill"
},
{
displayName: Translation.tr("Hide"),
icon: "deselect",
value: "hide"
}
]
} }
}
ContentSubsection { ContentSubsection {
enabled: Config.options.background.clock.style === "cookie" enabled: Config.options.background.clock.style === "cookie"
visible: enabled visible: enabled
title: Translation.tr("Minute hand style") title: Translation.tr("Minute hand style")
ConfigSelectionArray { ConfigSelectionArray {
currentValue: Config.options.background.clock.cookie.minuteHandStyle currentValue: Config.options.background.clock.cookie.minuteHandStyle
onSelected: newValue => { onSelected: newValue => {
Config.options.background.clock.cookie.minuteHandStyle = newValue; Config.options.background.clock.cookie.minuteHandStyle = newValue;
}
options: [
{
displayName: Translation.tr("Classic"),
icon: "radio",
value: "classic"
},
{
displayName: Translation.tr("Thin"),
icon: "pen_size_1",
value: "thin"
},
{
displayName: Translation.tr("Medium"),
icon: "pen_size_3",
value: "medium"
},
{
displayName: Translation.tr("Bold"),
icon: "pen_size_5",
value: "bold"
},
{
displayName: Translation.tr("Hide"),
icon: "deselect",
value: "hide"
}
]
} }
} options: [
ContentSubsection { {
enabled: Config.options.background.clock.style === "cookie" displayName: Translation.tr("Classic"),
visible: enabled icon: "radio",
title: Translation.tr("Seconds hand style") value: "classic"
ConfigSelectionArray { },
currentValue: Config.options.background.clock.cookie.secondHandStyle {
onSelected: newValue => { displayName: Translation.tr("Thin"),
Config.options.background.clock.cookie.secondHandStyle = newValue; icon: "pen_size_1",
value: "thin"
},
{
displayName: Translation.tr("Medium"),
icon: "pen_size_3",
value: "medium"
},
{
displayName: Translation.tr("Bold"),
icon: "pen_size_5",
value: "bold"
},
{
displayName: Translation.tr("Hide"),
icon: "deselect",
value: "hide"
} }
options: [ ]
{
displayName: Translation.tr("Classic"),
icon: "radio",
value: "classic"
},
{
displayName: Translation.tr("Line"),
icon: "line_end",
value: "line"
},
{
displayName: Translation.tr("Dot"),
icon: "adjust",
value: "dot"
},
{
displayName: Translation.tr("Hide"),
icon: "deselect",
value: "hide"
}
]
}
} }
}
ContentSubsection {
enabled: Config.options.background.clock.style === "cookie"
visible: enabled
title: Translation.tr("Seconds hand style")
ConfigSelectionArray {
currentValue: Config.options.background.clock.cookie.secondHandStyle
onSelected: newValue => {
Config.options.background.clock.cookie.secondHandStyle = newValue;
}
options: [
{
displayName: Translation.tr("Classic"),
icon: "radio",
value: "classic"
},
{
displayName: Translation.tr("Line"),
icon: "line_end",
value: "line"
},
{
displayName: Translation.tr("Dot"),
icon: "adjust",
value: "dot"
},
{
displayName: Translation.tr("Hide"),
icon: "deselect",
value: "hide"
}
]
}
}
ContentSubsection {
enabled: Config.options.background.clock.style === "cookie"
visible: enabled
ContentSubsection { title: Translation.tr("Date style")
enabled: Config.options.background.clock.style === "cookie" ConfigSelectionArray {
visible: enabled currentValue: Config.options.background.clock.cookie.dateStyle
title: Translation.tr("Date style") onSelected: newValue => {
ConfigSelectionArray { if (newValue !== "bubble" && Config.options.background.clock.cookie.dialNumberStyle === "none"){
currentValue: Config.options.background.clock.cookie.dateStyle Config.options.background.clock.cookie.dateStyle = newValue;
onSelected: newValue => { }
if (newValue !== "bubble" && Config.options.background.clock.cookie.dialNumberStyle === "none"){ if (newValue === "bubble" || newValue === "none"){
Config.options.background.clock.cookie.dateStyle = newValue; Config.options.background.clock.cookie.dateStyle = newValue;
}
if (newValue === "bubble" || newValue === "none"){
Config.options.background.clock.cookie.dateStyle = newValue;
}
} }
options: [
{
displayName: Translation.tr("None"),
icon: "deselect",
value: "none"
},
{
displayName: Translation.tr("Bubble"),
icon: "bubble_chart",
value: "bubble"
},
{
displayName: Translation.tr("Rotating"),
icon: "rotate_right",
value: "rotating"
},
{
displayName: Translation.tr("Square"),
icon: "square",
value: "square"
}
]
} }
options: [
{
displayName: Translation.tr("None"),
icon: "deselect",
value: "none"
},
{
displayName: Translation.tr("Bubble"),
icon: "bubble_chart",
value: "bubble"
},
{
displayName: Translation.tr("Rotating"),
icon: "rotate_right",
value: "rotating"
},
{
displayName: Translation.tr("Square"),
icon: "square",
value: "square"
}
]
} }
StyledText { }
visible: Config.options.background.clock.style === "cookie" StyledText {
Layout.leftMargin: 10 visible: Config.options.background.clock.style === "cookie"
color: Appearance.colors.colSubtext Layout.leftMargin: 10
font.pixelSize: Appearance.font.pixelSize.smallie color: Appearance.colors.colSubtext
text: Translation.tr("'Rotating' and 'Square' styles are not compatible with dial styles for aesthetic reasons") font.pixelSize: Appearance.font.pixelSize.smallie
} text: Translation.tr("'Rotating' and 'Square' styles are not compatible with dial styles for aesthetic reasons")
}
ConfigSpinBox { ConfigSpinBox {