feat(Storybook): RadioButtonFlowSelector utility added
This commit is contained in:
parent
670aa4627e
commit
1d728a5241
|
@ -58,7 +58,7 @@ ListView {
|
|||
}
|
||||
|
||||
Connections {
|
||||
target: root.model
|
||||
target: root.model || null
|
||||
|
||||
function onRowsInserted() {
|
||||
if (rowModel.count === 0)
|
||||
|
|
|
@ -0,0 +1,26 @@
|
|||
import QtQuick 2.15
|
||||
import QtQuick.Controls 2.15
|
||||
import QtQuick.Layouts 1.15
|
||||
|
||||
import StatusQ.Core.Utils 0.1
|
||||
|
||||
import utils 1.0
|
||||
|
||||
Flow {
|
||||
id: root
|
||||
|
||||
property alias model: repeater.model
|
||||
|
||||
property string selection: model ? model[initialSelection] : ""
|
||||
property int initialSelection: 0
|
||||
|
||||
Repeater {
|
||||
id: repeater
|
||||
|
||||
RadioButton {
|
||||
text: modelData
|
||||
checked: root.initialSelection === index
|
||||
onToggled: selection = modelData
|
||||
}
|
||||
}
|
||||
}
|
|
@ -24,6 +24,7 @@ LogsView 1.0 LogsView.qml
|
|||
PageToolBar 1.0 PageToolBar.qml
|
||||
PagesList 1.0 PagesList.qml
|
||||
PopupBackground 1.0 PopupBackground.qml
|
||||
RadioButtonFlowSelector 1.0 RadioButtonFlowSelector.qml
|
||||
SettingsLayout 1.0 SettingsLayout.qml
|
||||
SingleItemProxyModel 1.0 SingleItemProxyModel.qml
|
||||
SourceCodeBox 1.0 SourceCodeBox.qml
|
||||
|
|
Loading…
Reference in New Issue