diff options
Diffstat (limited to 'components/package')
-rw-r--r-- | components/package/contents/ui/People.qml | 133 |
1 files changed, 133 insertions, 0 deletions
diff --git a/components/package/contents/ui/People.qml b/components/package/contents/ui/People.qml new file mode 100644 index 00000000..47dd82ec --- /dev/null +++ b/components/package/contents/ui/People.qml | |||
@@ -0,0 +1,133 @@ | |||
1 | /* | ||
2 | Copyright (C) 2017 Michael Bohlender, <michael.bohlender@kdemail.net> | ||
3 | |||
4 | This program is free software; you can redistribute it and/or modify | ||
5 | it under the terms of the GNU General Public License as published by | ||
6 | the Free Software Foundation; either version 2 of the License, or | ||
7 | (at your option) any later version. | ||
8 | |||
9 | This program is distributed in the hope that it will be useful, | ||
10 | but WITHOUT ANY WARRANTY; without even the implied warranty of | ||
11 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | ||
12 | GNU General Public License for more details. | ||
13 | |||
14 | You should have received a copy of the GNU General Public License along | ||
15 | with this program; if not, write to the Free Software Foundation, Inc., | ||
16 | 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. | ||
17 | */ | ||
18 | |||
19 | import QtQuick 2.7 | ||
20 | import QtQuick.Controls 2.0 | ||
21 | import QtQuick.Controls 1.4 as Controls | ||
22 | import QtQuick.Layouts 1.1 | ||
23 | |||
24 | import org.kde.kirigami 1.0 as Kirigami | ||
25 | |||
26 | Popup { | ||
27 | |||
28 | modal: true | ||
29 | |||
30 | Controls.SplitView { | ||
31 | anchors.fill: parent | ||
32 | |||
33 | Item { | ||
34 | height: parent.height | ||
35 | width: Kirigami.Units.gridUnit * 14 | ||
36 | |||
37 | Item { | ||
38 | id: toolBar | ||
39 | |||
40 | width: parent.width - scroll.width | ||
41 | height: Kirigami.Units.gridUnit * 2 | ||
42 | |||
43 | Rectangle { | ||
44 | |||
45 | anchors.centerIn: parent | ||
46 | |||
47 | height: Kirigami.Units.gridUnit * 1.5 | ||
48 | width: parent.width* 0.8 | ||
49 | |||
50 | color: "#27ae60" | ||
51 | |||
52 | clip: true | ||
53 | |||
54 | Text { | ||
55 | |||
56 | anchors.centerIn: parent | ||
57 | |||
58 | clip: true | ||
59 | |||
60 | text: "New Contact" | ||
61 | |||
62 | color: "white" | ||
63 | } | ||
64 | } | ||
65 | } | ||
66 | |||
67 | ListView { | ||
68 | id: listView | ||
69 | |||
70 | anchors { | ||
71 | top: toolBar.bottom | ||
72 | left: parent.left | ||
73 | right: parent.right | ||
74 | bottom: parent.bottom | ||
75 | topMargin: Kirigami.Units.smallSpacing | ||
76 | } | ||
77 | |||
78 | model: 15 | ||
79 | clip: true | ||
80 | |||
81 | ScrollBar.vertical: ScrollBar { | ||
82 | id: scroll | ||
83 | } | ||
84 | |||
85 | delegate: Kirigami.AbstractListItem { | ||
86 | height: Kirigami.Units.gridUnit * 2.5 | ||
87 | width: listView.width - scroll.width | ||
88 | |||
89 | clip: true | ||
90 | |||
91 | Avatar { | ||
92 | id: avatar | ||
93 | |||
94 | anchors { | ||
95 | verticalCenter: parent.verticalCenter | ||
96 | left: parent.left | ||
97 | leftMargin: Kirigami.Units.smallSpacing | ||
98 | } | ||
99 | |||
100 | height: parent.height * 0.9 | ||
101 | width: height | ||
102 | |||
103 | name: "Wolfgang Rosenzweig" | ||
104 | } | ||
105 | |||
106 | Text { | ||
107 | id: name | ||
108 | |||
109 | anchors { | ||
110 | left: avatar.right | ||
111 | leftMargin: Kirigami.Units.smallSpacing | ||
112 | verticalCenter: avatar.verticalCenter | ||
113 | } | ||
114 | |||
115 | text: "Wolfgang Rosenzweig" | ||
116 | color: Kirigami.Theme.textColor | ||
117 | } | ||
118 | } | ||
119 | } | ||
120 | } | ||
121 | |||
122 | Item { | ||
123 | height: parent.height | ||
124 | Layout.fillWidth: true | ||
125 | |||
126 | ToolBar { | ||
127 | |||
128 | width: parent.width | ||
129 | height: Kirigami.Units.gridUnit * 2 | ||
130 | } | ||
131 | } | ||
132 | } | ||
133 | } | ||