2021-10-21 08:22:05 +00:00
|
|
|
import QtQuick 2.13
|
|
|
|
import QtQuick.Layouts 1.13
|
|
|
|
|
|
|
|
import StatusQ.Components 0.1
|
|
|
|
import StatusQ.Core.Theme 0.1
|
|
|
|
import StatusQ.Core 0.1
|
|
|
|
import StatusQ.Controls 0.1
|
|
|
|
|
2022-07-28 20:56:44 +00:00
|
|
|
import utils 1.0
|
|
|
|
import shared.controls 1.0
|
|
|
|
|
2021-12-06 21:10:54 +00:00
|
|
|
import "../../stores"
|
2021-10-21 08:22:05 +00:00
|
|
|
import "../../controls"
|
|
|
|
|
2022-07-28 20:56:44 +00:00
|
|
|
Item {
|
2021-10-21 08:22:05 +00:00
|
|
|
id: root
|
|
|
|
|
|
|
|
CollectibleDetailsHeader {
|
|
|
|
id: collectibleHeader
|
2022-07-28 20:56:44 +00:00
|
|
|
anchors.top: parent.top
|
2021-10-21 08:22:05 +00:00
|
|
|
anchors.left: parent.left
|
|
|
|
anchors.right: parent.right
|
2022-08-11 11:55:08 +00:00
|
|
|
asset.name: RootStore.collectiblesStore.collectibleImageUrl
|
|
|
|
asset.isImage: true
|
2021-10-21 08:22:05 +00:00
|
|
|
primaryText: RootStore.collectiblesStore.name
|
|
|
|
secondaryText: RootStore.collectiblesStore.collectibleId
|
|
|
|
}
|
|
|
|
|
2022-07-28 20:56:44 +00:00
|
|
|
ColumnLayout {
|
2021-10-21 08:22:05 +00:00
|
|
|
anchors.top: collectibleHeader.bottom
|
|
|
|
anchors.topMargin: 46
|
2022-07-28 20:56:44 +00:00
|
|
|
anchors.left: parent.left
|
|
|
|
anchors.right: parent.right
|
|
|
|
anchors.bottom: parent.bottom
|
|
|
|
|
|
|
|
spacing: Style.current.padding
|
2021-10-21 08:22:05 +00:00
|
|
|
|
|
|
|
Row {
|
|
|
|
id: collectibleImageDetails
|
2022-07-28 20:56:44 +00:00
|
|
|
Layout.preferredWidth: parent.width
|
2021-10-21 08:22:05 +00:00
|
|
|
spacing: 24
|
|
|
|
|
|
|
|
StatusRoundedImage {
|
|
|
|
id: collectibleimage
|
|
|
|
width: 253
|
|
|
|
height: 253
|
|
|
|
radius: 2
|
|
|
|
color: RootStore.collectiblesStore.backgroundColor
|
|
|
|
border.color: Theme.palette.directColor8
|
|
|
|
border.width: 1
|
|
|
|
image.source: RootStore.collectiblesStore.imageUrl
|
|
|
|
}
|
|
|
|
StatusBaseText {
|
|
|
|
id: collectibleText
|
2022-07-28 20:56:44 +00:00
|
|
|
width: parent.width - collectibleimage.width - Style.current.bigPadding
|
2021-10-21 08:22:05 +00:00
|
|
|
height: collectibleimage.height
|
|
|
|
|
|
|
|
text: RootStore.collectiblesStore.description
|
|
|
|
color: Theme.palette.directColor1
|
|
|
|
font.pixelSize: 15
|
|
|
|
lineHeight: 22
|
|
|
|
lineHeightMode: Text.FixedHeight
|
|
|
|
elide: Text.ElideRight
|
|
|
|
wrapMode: Text.Wrap
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
2022-07-28 20:56:44 +00:00
|
|
|
StatusTabBar {
|
|
|
|
id: collectiblesDetailsTab
|
|
|
|
Layout.fillWidth: true
|
|
|
|
Layout.topMargin: Style.current.xlPadding
|
|
|
|
visible: RootStore.collectiblesStore.properties.count > 0
|
2021-10-21 08:22:05 +00:00
|
|
|
|
2022-07-28 20:56:44 +00:00
|
|
|
StatusTabButton {
|
|
|
|
leftPadding: 0
|
|
|
|
width: implicitWidth
|
|
|
|
text: qsTr("Properties")
|
2021-10-21 08:22:05 +00:00
|
|
|
}
|
|
|
|
}
|
|
|
|
|
2022-07-28 20:56:44 +00:00
|
|
|
StackLayout {
|
|
|
|
Flow {
|
|
|
|
width: parent.width
|
|
|
|
spacing: 10
|
|
|
|
Repeater {
|
|
|
|
model: RootStore.collectiblesStore.properties
|
|
|
|
InformationTile {
|
|
|
|
maxWidth: parent.width
|
|
|
|
primaryText: model.traitType
|
|
|
|
secondaryText: model.value
|
2021-10-21 08:22:05 +00:00
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|