chore(Storybook): StatusItemSelectorPage moved from Sandbox to Storybook
This commit is contained in:
parent
47cb1810b6
commit
0db5790f76
|
@ -149,6 +149,10 @@ ListModel {
|
||||||
title: "StatusDotsLoadingIndicator"
|
title: "StatusDotsLoadingIndicator"
|
||||||
section: "Components"
|
section: "Components"
|
||||||
}
|
}
|
||||||
|
ListElement {
|
||||||
|
title: "StatusItemSelector"
|
||||||
|
section: "Components"
|
||||||
|
}
|
||||||
ListElement {
|
ListElement {
|
||||||
title: "BrowserSettings"
|
title: "BrowserSettings"
|
||||||
section: "Settings"
|
section: "Settings"
|
||||||
|
|
|
@ -1,15 +1,19 @@
|
||||||
import QtQuick 2.14
|
import QtQuick 2.15
|
||||||
import QtQuick.Layouts 1.14
|
import QtQuick.Layouts 1.15
|
||||||
|
|
||||||
import StatusQ.Components 0.1
|
import StatusQ.Components 0.1
|
||||||
import StatusQ.Controls 0.1
|
import StatusQ.Controls 0.1
|
||||||
import StatusQ.Core.Utils 0.1
|
import StatusQ.Core.Utils 0.1
|
||||||
|
|
||||||
|
import utils 1.0
|
||||||
|
|
||||||
ColumnLayout {
|
ColumnLayout {
|
||||||
spacing: 20
|
spacing: 20
|
||||||
|
|
||||||
StatusItemSelector {
|
StatusItemSelector {
|
||||||
id: selector
|
id: selector
|
||||||
icon: "qrc:/images/SNT.png"
|
|
||||||
|
icon: Style.png("tokens/SNT")
|
||||||
iconSize: 24
|
iconSize: 24
|
||||||
title: "Item Selector Title"
|
title: "Item Selector Title"
|
||||||
defaultItemText: "Example: Empty items"
|
defaultItemText: "Example: Empty items"
|
||||||
|
@ -25,19 +29,23 @@ ColumnLayout {
|
||||||
width: 200
|
width: 200
|
||||||
contentItem: ColumnLayout {
|
contentItem: ColumnLayout {
|
||||||
spacing: 10
|
spacing: 10
|
||||||
|
|
||||||
StatusInput {
|
StatusInput {
|
||||||
id: input
|
id: input
|
||||||
text: "Sample"
|
text: "Sample"
|
||||||
Layout.fillWidth: true
|
Layout.fillWidth: true
|
||||||
}
|
}
|
||||||
|
|
||||||
StatusButton {
|
StatusButton {
|
||||||
Layout.alignment: Qt.AlignHCenter
|
Layout.alignment: Qt.AlignHCenter
|
||||||
|
|
||||||
text: "Add element"
|
text: "Add element"
|
||||||
onClicked: {
|
onClicked: {
|
||||||
model.append({
|
model.append({
|
||||||
text: input.text,
|
text: input.text,
|
||||||
imageSource: "qrc:/images/SNT.png",
|
imageSource: Style.png("tokens/SNT"),
|
||||||
operator: model.count > 0 ? OperatorsUtils.Operators.Or : OperatorsUtils.Operators.None
|
operator: model.count > 0 ? OperatorsUtils.Operators.Or
|
||||||
|
: OperatorsUtils.Operators.None
|
||||||
})
|
})
|
||||||
|
|
||||||
dropdown.close()
|
dropdown.close()
|
||||||
|
@ -55,6 +63,7 @@ ColumnLayout {
|
||||||
|
|
||||||
StatusButton {
|
StatusButton {
|
||||||
Layout.alignment: Qt.AlignHCenter
|
Layout.alignment: Qt.AlignHCenter
|
||||||
|
|
||||||
text: "Clear list"
|
text: "Clear list"
|
||||||
onClicked: { selector.itemsModel.clear() }
|
onClicked: { selector.itemsModel.clear() }
|
||||||
}
|
}
|
|
@ -306,11 +306,6 @@ StatusWindow {
|
||||||
selected: viewLoader.source.toString().includes(title)
|
selected: viewLoader.source.toString().includes(title)
|
||||||
onClicked: mainPageView.page(title);
|
onClicked: mainPageView.page(title);
|
||||||
}
|
}
|
||||||
StatusNavigationListItem {
|
|
||||||
title: "StatusItemSelector"
|
|
||||||
selected: viewLoader.source.toString().includes(title)
|
|
||||||
onClicked: mainPageView.page(title, true);
|
|
||||||
}
|
|
||||||
StatusNavigationListItem {
|
StatusNavigationListItem {
|
||||||
title: "StatusChartPanel"
|
title: "StatusChartPanel"
|
||||||
selected: viewLoader.source.toString().includes(title)
|
selected: viewLoader.source.toString().includes(title)
|
||||||
|
|
|
@ -56,7 +56,6 @@
|
||||||
<file>pages/StatusExpandableSettingsItemPage.qml</file>
|
<file>pages/StatusExpandableSettingsItemPage.qml</file>
|
||||||
<file>pages/StatusImageCropPanelPage.qml</file>
|
<file>pages/StatusImageCropPanelPage.qml</file>
|
||||||
<file>pages/StatusInputPage.qml</file>
|
<file>pages/StatusInputPage.qml</file>
|
||||||
<file>pages/StatusItemSelectorPage.qml</file>
|
|
||||||
<file>pages/StatusListPickerPage.qml</file>
|
<file>pages/StatusListPickerPage.qml</file>
|
||||||
<file>pages/StatusMacNotificationPage.qml</file>
|
<file>pages/StatusMacNotificationPage.qml</file>
|
||||||
<file>pages/StatusPasswordStrengthIndicatorPage.qml</file>
|
<file>pages/StatusPasswordStrengthIndicatorPage.qml</file>
|
||||||
|
|
Loading…
Reference in New Issue