Add all view
This commit is contained in:
1 parent
186cff1d73
commit
49d8524597
18 files changed
+1007
-98
No files matched your search
@@ -0,0 +1,60 @@
|
||||
import QtQuick 2.5
|
||||
import "."
|
||||
|
||||
// Base de chaque écran : en-tête (titre + sous-titre) et zone de contenu.
|
||||
// `navigator` et `session` sont injectés par le Navigator au chargement.
|
||||
FocusScope {
|
||||
id: page
|
||||
|
||||
property var navigator: null
|
||||
property var session: null
|
||||
// Élément qui reçoit le focus quand l'écran s'affiche.
|
||||
property Item initialFocus: null
|
||||
|
||||
property alias title: titleText.text
|
||||
property alias subtitle: subtitleText.text
|
||||
default property alias content: body.data
|
||||
|
||||
Column {
|
||||
id: header
|
||||
anchors {
|
||||
top: parent.top
|
||||
left: parent.left
|
||||
right: parent.right
|
||||
margins: Theme.pageMargin
|
||||
}
|
||||
spacing: Theme.spacingS
|
||||
|
||||
Text {
|
||||
id: titleText
|
||||
width: parent.width
|
||||
color: Theme.text
|
||||
font.pixelSize: Theme.fontTitle
|
||||
font.bold: true
|
||||
elide: Text.ElideRight
|
||||
}
|
||||
|
||||
Text {
|
||||
id: subtitleText
|
||||
width: parent.width
|
||||
visible: text !== ""
|
||||
color: Theme.textMuted
|
||||
font.pixelSize: Theme.fontBody
|
||||
wrapMode: Text.WordWrap
|
||||
}
|
||||
}
|
||||
|
||||
Item {
|
||||
id: body
|
||||
anchors {
|
||||
top: header.bottom
|
||||
topMargin: Theme.spacingXL
|
||||
left: parent.left
|
||||
right: parent.right
|
||||
bottom: parent.bottom
|
||||
leftMargin: Theme.pageMargin
|
||||
rightMargin: Theme.pageMargin
|
||||
bottomMargin: Theme.pageMargin
|
||||
}
|
||||
}
|
||||
}
|
||||
Reference in new issue
Block a user