@@ -61,7 +61,9 @@ var kBackgroundLoaderCode = 'Loader {\n\
6161// %1 is used as anchors of artShapeHolder
6262// %2 is used as image width
6363// %3 is used as image height
64−// %4 is injected as code to artImage
64+// %4 is used as aspect ratio fallback
65+// %5 is used for artShapeSource.hideSource and inner Loader visible
66+// %6 is injected as code to artImage
6567var kArtShapeHolderCode = 'Item { \n\
6668 id: artShapeHolder; \n\
6769 height: root.fixedArtShapeSize.height > 0 ? root.fixedArtShapeSize.height : artShapeLoader.height; \n\
@@ -76,7 +78,6 @@ var kArtShapeHolderCode = 'Item { \n\
7678 sourceComponent: Item { \n\
7779 id: artShape; \n\
7880 objectName: "artShape"; \n\
79− readonly property bool doShapeItem: components["art"]["conciergeMode"] !== true; \n\
8081 visible: image.status == Image.Ready; \n\
8182 readonly property alias image: artImage; \n\
8283 ShaderEffectSource { \n\
@@ -85,11 +86,11 @@ var kArtShapeHolderCode = 'Item { \n\
8586 anchors.centerIn: parent; \n\
8687 width: 1; \n\
8788 height: 1; \n\
88− hideSource: doShapeItem; \n\
89+ hideSource: %5; \n\
8990 } \n\
9091 Loader { \n\
9192 anchors.fill: parent; \n\
92− visible: artShape.doShapeItem; \n\
93+ visible: %5; \n\
9394 sourceComponent: root.artShapeStyle === "icon" ? artShapeIconComponent : artShapeShapeComponent; \n\
9495 Component { \n\
9596 id: artShapeShapeComponent; \n\
@@ -113,7 +114,7 @@ var kArtShapeHolderCode = 'Item { \n\
113114 } \n\
114115 } \n\
115116 readonly property real fixedArtShapeSizeAspect: (root.fixedArtShapeSize.height > 0 && root.fixedArtShapeSize.width > 0) ? root.fixedArtShapeSize.width / root.fixedArtShapeSize.height : -1; \n\
116− readonly property real aspect: fixedArtShapeSizeAspect > 0 ? fixedArtShapeSizeAspect : components !== undefined ? components["art"]["aspect-ratio"] : 1; \n\
117+ readonly property real aspect: fixedArtShapeSizeAspect > 0 ? fixedArtShapeSizeAspect : %4; \n\
117118 Component.onCompleted: { updateWidthHeightBindings(); } \n\
118119 Connections { target: root; onFixedArtShapeSizeChanged: updateWidthHeightBindings(); } \n\
119120 function updateWidthHeightBindings() { \n\
@@ -132,7 +133,7 @@ var kArtShapeHolderCode = 'Item { \n\
132133 asynchronous: root.asynchronous; \n\
133134 width: %2; \n\
134135 height: %3; \n\
135− %4 \n\
136+ %6 \n\
136137 } \n\
137138 } \n\
138139 } \n\
@@ -398,7 +399,6 @@ function cardString(template, components) {
398399
399400 code = 'AbstractButton { \n\
400401 id: root; \n\
401− property var components; \n\
402402 property var cardData; \n\
403403 property string artShapeStyle: "inset"; \n\
404404 property string backgroundShapeStyle: "inset"; \n\
@@ -416,7 +416,8 @@ function cardString(template, components) {
416416
417417 var hasArt = components["art"] && components["art"]["field"] || false;
418418 var hasSummary = components["summary"] || false;
419− var artAndSummary = hasArt && hasSummary && components["art"]["conciergeMode"] !== true;
419+ var isConciergeMode = components["art"] && components["art"]["conciergeMode"] || false;
420+ var artAndSummary = hasArt && hasSummary && !isConciergeMode;
420421 var isHorizontal = template["card-layout"] === "horizontal";
421422 var hasBackground = (!isHorizontal && (template["card-background"] || components["background"] || artAndSummary)) ||
422423 (hasSummary && (template["card-background"] || components["background"]));
@@ -478,12 +479,16 @@ function cardString(template, components) {
478479 heightCode = 'width / artShape.aspect';
479480 }
480481
482+ var aspectRatio = components["art"] && components["art"]["aspect-ratio"] || 1;
483+ if (typeof aspectRatio !== "number") {
484+ aspectRatio = 1;
485+ }
481486 var fallback = components["art"] && components["art"]["fallback"] || "";
482487 var fallbackCode = "";
483488 if (fallback !== "") {
484489 fallbackCode += 'onStatusChanged: if (status === Image.Error) source = "%1";'.arg(fallback);
485490 }
486− code += kArtShapeHolderCode.arg(artAnchors).arg(widthCode).arg(heightCode).arg(fallbackCode);
491+ code += kArtShapeHolderCode.arg(artAnchors).arg(widthCode).arg(heightCode).arg(aspectRatio).arg(isConciergeMode ? "false" : "true").arg(fallbackCode);
487492 } else {
488493 code += 'readonly property size artShapeSize: Qt.size(-1, -1);\n'
489494 }