summaryrefslogtreecommitdiff
path: root/modules/launcher/ActionItem.qml
diff options
context:
space:
mode:
author2 * r + 2 * t <61896496+soramanew@users.noreply.github.com>2025-05-24 13:47:45 +0800
committer2 * r + 2 * t <61896496+soramanew@users.noreply.github.com>2025-05-24 13:47:45 +0800
commit4ca23da8e139deaf4615a39e7e7ffbd7fbd3ab61 (patch)
treef88ed87462a79518157cd829ade13eff24699b91 /modules/launcher/ActionItem.qml
parentinternal: remove padded rect (diff)
downloadcaelestia-shell-4ca23da8e139deaf4615a39e7e7ffbd7fbd3ab61.tar.gz
caelestia-shell-4ca23da8e139deaf4615a39e7e7ffbd7fbd3ab61.tar.bz2
caelestia-shell-4ca23da8e139deaf4615a39e7e7ffbd7fbd3ab61.zip
internal: fix null errors
Diffstat (limited to 'modules/launcher/ActionItem.qml')
-rw-r--r--modules/launcher/ActionItem.qml12
1 files changed, 6 insertions, 6 deletions
diff --git a/modules/launcher/ActionItem.qml b/modules/launcher/ActionItem.qml
index 800c937..f4f90a2 100644
--- a/modules/launcher/ActionItem.qml
+++ b/modules/launcher/ActionItem.qml
@@ -11,14 +11,14 @@ Item {
implicitHeight: LauncherConfig.sizes.itemHeight
- anchors.left: parent.left
- anchors.right: parent.right
+ anchors.left: parent?.left
+ anchors.right: parent?.right
StateLayer {
radius: Appearance.rounding.full
function onClicked(): void {
- root.modelData.onClicked(root.list);
+ root.modelData?.onClicked(root.list);
}
}
@@ -31,7 +31,7 @@ Item {
MaterialIcon {
id: icon
- text: root.modelData.icon
+ text: root.modelData?.icon ?? ""
font.pointSize: Appearance.font.size.extraLarge
anchors.verticalCenter: parent.verticalCenter
@@ -48,12 +48,12 @@ Item {
StyledText {
id: name
- text: root.modelData.name
+ text: root.modelData?.name ?? ""
font.pointSize: Appearance.font.size.normal
}
StyledText {
- text: root.modelData.desc
+ text: root.modelData?.desc ?? ""
font.pointSize: Appearance.font.size.small
color: Colours.alpha(Colours.palette.m3outline, true)