Port to BasicListItem with subtitle

This commit is contained in:
Tobias Fella 2020-04-30 17:51:55 +02:00
parent f069871eb1
commit 98ac6278da
1 changed files with 3 additions and 17 deletions

View File

@ -85,23 +85,9 @@ Kirigami.ScrollablePage {
}
}
delegate: Kirigami.SwipeListItem {
Controls.Label {
text: model.title + " - " + model.updated.toLocaleString(Qt.locale(), Locale.ShortFormat)
textFormat: Text.RichText
color: model.read ? Kirigami.Theme.disabledTextColor : Kirigami.Theme.textColor
wrapMode: Text.Wrap
}
actions: [
Kirigami.Action {
icon.name: model.bookmark ? "bookmark-remove" : "bookmark-new"
text: i18n("Bookmark")
onTriggered: {
model.bookmark = !model.bookmark
}
}
]
delegate: Kirigami.BasicListItem {
text: model.title
subtitle: model.updated.toLocaleString(Qt.locale(), Locale.ShortFormat)
onClicked: {
model.read = true;