10import org.kde.kirigami as Kirigami
12import "private" as Private
40 property string description:
""
45 property alias descriptionItem: internalDescriptionItem
50 property alias textItem: internalTextItem
56 property var leading: null
61 property real leadingPadding:
Kirigami.Units.smallSpacing
67 property var trailing: null
72 property real trailingPadding:
Kirigami.Units.smallSpacing
74 signal linkActivated(
string link)
76 focusPolicy:
Qt.NoFocus
80 contentItem: RowLayout {
83 Private.ContentItemLoader {
84 Layout.rightMargin: visible ? root.leadingPadding : 0
86 implicitHeight: visible ? root.leading.implicitHeight : 0
87 implicitWidth: visible ? root.leading.implicitWidth : 0
88 contentItem: root.leading
92 visible: root.icon.name !==
""
93 source: root.icon.name
94 color: root.icon.color
95 Layout.rightMargin: (root.icon.name !==
"") ? Private.FormCardUnits.horizontalSpacing : 0
96 implicitWidth: (root.icon.name !==
"") ?
Kirigami.Units.iconSizes.smallMedium : 0
97 implicitHeight: (root.icon.name !==
"") ?
Kirigami.Units.iconSizes.smallMedium : 0
101 Layout.fillWidth:
true
102 spacing: Private.FormCardUnits.verticalSpacing
106 Layout.fillWidth:
true
108 elide: Text.ElideRight
109 onLinkActivated: root.linkActivated(link)
111 Accessible.ignored:
true
115 id: internalDescriptionItem
116 Layout.fillWidth:
true
117 text: root.description
118 color:
Kirigami.Theme.disabledTextColor
119 visible: root.description !==
""
120 onLinkActivated: root.linkActivated(link)
125 Private.ContentItemLoader {
126 Layout.leftMargin: visible ? root.trailingPadding : 0
127 visible: root.trailing
128 implicitHeight: visible ? root.trailing.implicitHeight : 0
129 implicitWidth: visible ? root.trailing.implicitWidth : 0
130 contentItem: root.trailing