Skip to content

Commit 2118eb5

Browse files
committed
qml: follow-up de83a10
1 parent de83a10 commit 2118eb5

File tree

1 file changed

+64
-0
lines changed

1 file changed

+64
-0
lines changed
Lines changed: 64 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,64 @@
1+
import QtQuick 2.6
2+
import QtQuick.Layouts 1.0
3+
import QtQuick.Controls 2.3
4+
import QtQuick.Controls.Material 2.0
5+
import QtQml.Models 2.1
6+
import QtQml 2.6
7+
8+
import "controls"
9+
10+
Pane {
11+
id: root
12+
13+
ColumnLayout {
14+
anchors.fill: parent
15+
16+
Label {
17+
text: qsTr('Invoices')
18+
font.pixelSize: constants.fontSizeLarge
19+
color: Material.accentColor
20+
}
21+
22+
Rectangle {
23+
height: 1
24+
Layout.fillWidth: true
25+
color: Material.accentColor
26+
}
27+
28+
Frame {
29+
background: PaneInsetBackground {}
30+
31+
verticalPadding: 0
32+
horizontalPadding: 0
33+
Layout.fillHeight: true
34+
Layout.fillWidth: true
35+
36+
ListView {
37+
id: listview
38+
anchors.fill: parent
39+
clip: true
40+
41+
model: DelegateModel {
42+
id: delegateModel
43+
model: Daemon.currentWallet.invoiceModel
44+
delegate: InvoiceDelegate {
45+
onClicked: app.stack.getRoot().openInvoice(model.key)
46+
}
47+
}
48+
49+
remove: Transition {
50+
NumberAnimation { properties: 'scale'; to: 0.75; duration: 300 }
51+
NumberAnimation { properties: 'opacity'; to: 0; duration: 300 }
52+
}
53+
removeDisplaced: Transition {
54+
SequentialAnimation {
55+
PauseAnimation { duration: 200 }
56+
SpringAnimation { properties: 'y'; duration: 100; spring: 5; damping: 0.5; mass: 2 }
57+
}
58+
}
59+
60+
ScrollIndicator.vertical: ScrollIndicator { }
61+
}
62+
}
63+
}
64+
}

0 commit comments

Comments
 (0)