fix(StatusBaseInput): fix default padding when leftComponent is loaded

This commit is contained in:
Patryk Osmaczko 2022-03-28 14:21:57 +02:00 committed by Khushboo Mehta
parent cf0ba3f7a1
commit ac3abff16f
1 changed files with 2 additions and 1 deletions

View File

@ -37,7 +37,7 @@ Item {
property alias placeholderTextColor: placeholder.color property alias placeholderTextColor: placeholder.color
property alias placeholderFont: placeholder.font property alias placeholderFont: placeholder.font
property real leftPadding: 16 property real leftPadding: leftComponentLoader.item ? 8 : 16
property real rightPadding: 16 property real rightPadding: 16
property real topPadding: 12 property real topPadding: 12
property real bottomPadding: 12 property real bottomPadding: 12
@ -130,6 +130,7 @@ Item {
clip: true clip: true
Loader { Loader {
id: leftComponentLoader
sourceComponent: { sourceComponent: {
if (root.leftComponent) return root.leftComponent if (root.leftComponent) return root.leftComponent
if (!root.leftIcon) return undefined if (!root.leftIcon) return undefined