bar: component loader

This commit is contained in:
end-4
2026-02-03 18:17:02 +01:00
parent 680d8e85c8
commit 0e049db304
9 changed files with 228 additions and 39 deletions
@@ -0,0 +1,17 @@
import QtQuick
import qs.modules.common as C
FallbackLoader {
id: root
required property string componentName
property string context // Path for the builtin component
readonly property string componentNameWithExt: componentName.endsWith(".qml") ? componentName : `${componentName}.qml`
source: `${C.Directories.userComponents}/${componentNameWithExt}`
fallbacks: [
...(context ? [ `${context}/${componentNameWithExt}` ] : []),
componentNameWithExt
]
}