2023-06-14 15:25:48 +00:00
|
|
|
import QtQuick 2.15
|
|
|
|
import QtQuick.Controls 2.15
|
|
|
|
import QtQuick.Layouts 1.15
|
|
|
|
|
2023-07-20 10:38:49 +00:00
|
|
|
import AppLayouts.Communities.panels 1.0
|
|
|
|
|
2023-06-14 15:25:48 +00:00
|
|
|
import Storybook 1.0
|
2023-07-20 10:38:49 +00:00
|
|
|
import Models 1.0
|
2023-06-14 15:25:48 +00:00
|
|
|
|
|
|
|
|
|
|
|
SplitView {
|
2023-07-20 10:38:49 +00:00
|
|
|
FeesModel {
|
|
|
|
id: feesModel
|
|
|
|
}
|
2023-06-14 15:25:48 +00:00
|
|
|
|
2023-07-20 10:38:49 +00:00
|
|
|
Pane {
|
2023-06-14 15:25:48 +00:00
|
|
|
SplitView.fillWidth: true
|
2023-07-20 10:38:49 +00:00
|
|
|
SplitView.fillHeight: true
|
2023-06-14 15:25:48 +00:00
|
|
|
|
2023-07-20 10:38:49 +00:00
|
|
|
Rectangle {
|
|
|
|
anchors.fill: feesPanel
|
|
|
|
anchors.margins: -15
|
|
|
|
border.color: "lightgray"
|
|
|
|
color: "transparent"
|
|
|
|
}
|
2023-06-14 15:25:48 +00:00
|
|
|
|
2023-07-20 10:38:49 +00:00
|
|
|
FeesPanel {
|
|
|
|
id: feesPanel
|
2023-06-14 15:25:48 +00:00
|
|
|
|
2023-07-20 10:38:49 +00:00
|
|
|
anchors.centerIn: parent
|
2023-06-14 15:25:48 +00:00
|
|
|
|
2023-07-20 10:38:49 +00:00
|
|
|
width: 500
|
2023-06-14 15:25:48 +00:00
|
|
|
|
2023-07-20 10:38:49 +00:00
|
|
|
model: LimitProxyModel {
|
|
|
|
sourceModel: feesModel
|
|
|
|
limit: countSlider.value
|
2023-06-14 15:25:48 +00:00
|
|
|
}
|
|
|
|
|
2023-07-20 10:38:49 +00:00
|
|
|
placeholderText: placeholderTextField.text
|
|
|
|
|
|
|
|
footer: Rectangle {
|
|
|
|
id: footer
|
2023-06-14 15:25:48 +00:00
|
|
|
|
2023-07-20 10:38:49 +00:00
|
|
|
visible: showFooterSwitch.checked
|
|
|
|
|
|
|
|
height: 100
|
|
|
|
|
|
|
|
border.color: "lightgray"
|
|
|
|
color: "transparent"
|
2023-06-14 15:25:48 +00:00
|
|
|
|
2023-07-20 10:38:49 +00:00
|
|
|
Label {
|
|
|
|
anchors.centerIn: parent
|
|
|
|
text: "footer"
|
|
|
|
}
|
|
|
|
}
|
2023-06-14 15:25:48 +00:00
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
Pane {
|
|
|
|
SplitView.minimumWidth: 300
|
|
|
|
SplitView.preferredWidth: 300
|
|
|
|
|
|
|
|
ColumnLayout {
|
|
|
|
anchors.fill: parent
|
|
|
|
|
|
|
|
Label {
|
|
|
|
Layout.fillWidth: true
|
|
|
|
|
2023-07-20 10:38:49 +00:00
|
|
|
text: "Placeholder text"
|
2023-06-14 15:25:48 +00:00
|
|
|
}
|
|
|
|
|
|
|
|
TextField {
|
2023-07-20 10:38:49 +00:00
|
|
|
id: placeholderTextField
|
2023-06-14 15:25:48 +00:00
|
|
|
|
|
|
|
Layout.fillWidth: true
|
2023-07-20 10:38:49 +00:00
|
|
|
text: "Add valid “What” and “To” values to see fees"
|
2023-06-14 15:25:48 +00:00
|
|
|
}
|
|
|
|
|
|
|
|
Switch {
|
2023-07-20 10:38:49 +00:00
|
|
|
id: showFooterSwitch
|
2023-06-14 15:25:48 +00:00
|
|
|
|
2023-07-20 10:38:49 +00:00
|
|
|
text: "Show footer"
|
|
|
|
checked: true
|
2023-06-14 15:25:48 +00:00
|
|
|
}
|
|
|
|
|
2023-07-20 10:38:49 +00:00
|
|
|
Label {
|
|
|
|
Layout.fillWidth: true
|
2023-06-14 15:25:48 +00:00
|
|
|
|
2023-07-20 10:38:49 +00:00
|
|
|
text: "Number of items in the model"
|
2023-06-14 15:25:48 +00:00
|
|
|
}
|
|
|
|
|
2023-07-20 10:38:49 +00:00
|
|
|
RowLayout {
|
|
|
|
Slider {
|
|
|
|
id: countSlider
|
2023-06-14 15:25:48 +00:00
|
|
|
|
2023-07-20 10:38:49 +00:00
|
|
|
from: 0
|
|
|
|
to: feesModel.count
|
|
|
|
value: to
|
|
|
|
|
|
|
|
stepSize: 1
|
|
|
|
snapMode: Slider.SnapAlways
|
|
|
|
}
|
|
|
|
|
|
|
|
Label {
|
|
|
|
text: countSlider.value
|
|
|
|
}
|
2023-06-14 15:25:48 +00:00
|
|
|
}
|
|
|
|
|
|
|
|
Item {
|
|
|
|
Layout.fillHeight: true
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
2023-07-31 12:21:14 +00:00
|
|
|
|
|
|
|
// category: Panels
|