From 56b7ecb008dfb737a735bd257ececc77bd94d76c Mon Sep 17 00:00:00 2001 From: bbedward Date: Fri, 10 Jul 2026 10:49:50 -0400 Subject: [PATCH] qs/common: fix path decoding fixes #2802 port 1.5 --- quickshell/Common/Paths.qml | 10 +++++++++- 1 file changed, 9 insertions(+), 1 deletion(-) diff --git a/quickshell/Common/Paths.qml b/quickshell/Common/Paths.qml index 1e9784761..a0d690b68 100644 --- a/quickshell/Common/Paths.qml +++ b/quickshell/Common/Paths.qml @@ -9,6 +9,8 @@ import qs.Services Singleton { id: root + readonly property var log: Log.scoped("Paths") + readonly property url home: StandardPaths.standardLocations(StandardPaths.HomeLocation)[0] readonly property url pictures: StandardPaths.standardLocations(StandardPaths.PicturesLocation)[0] readonly property url xdgCache: StandardPaths.standardLocations(StandardPaths.GenericCacheLocation)[0] @@ -23,7 +25,13 @@ Singleton { Component.onCompleted: mkdir(imagecache) function stringify(path: url): string { - return path.toString().replace(/%20/g, " "); + const raw = path.toString(); + try { + return decodeURIComponent(raw); + } catch (e) { + log.warn("failed to decode path:", raw, e); + return raw; + } } function expandTilde(path: string): string {