nixos-dotfiles

nixos-dotfiles

https://git.tonybtw.com/nixos-dotfiles.git git://git.tonybtw.com/nixos-dotfiles.git
13,405 bytes raw
1
import Quickshell
2
import Quickshell.Wayland
3
import QtQuick
4
import QtQuick.Layouts
5
6
Variants {
7
    model: Quickshell.screens
8
    FloatingWindow {
9
        property var modelData
10
        screen: modelData
11
        visible: true
12
        width: 400
13
        height: 800
14
        
15
        color: "transparent"
16
        
17
        Rectangle {
18
            anchors.fill: parent
19
            color: "#80000000"
20
            
21
            MouseArea {
22
                anchors.fill: parent
23
                onClicked: visible = false
24
            }
25
        }
26
        
27
        Rectangle {
28
            anchors.fill: parent
29
            color: "#1a1b26"
30
            
31
            ColumnLayout {
32
                anchors.fill: parent
33
                anchors.margins: 20
34
                spacing: 15
35
                
36
                RowLayout {
37
                    Layout.fillWidth: true
38
                    
39
                    Text {
40
                        text: "Dashboard"
41
                        color: "#a9b1d6"
42
                        font.pixelSize: 24
43
                        font.family: "JetBrainsMono Nerd Font"
44
                        font.bold: true
45
                    }
46
                    
47
                    Item { Layout.fillWidth: true }
48
                    
49
                    Rectangle {
50
                        width: 30
51
                        height: 30
52
                        color: "#32344a"
53
                        radius: 5
54
                        
55
                        Text {
56
                            anchors.centerIn: parent
57
                            text: "✕"
58
                            color: "#a9b1d6"
59
                            font.pixelSize: 18
60
                        }
61
                        
62
                        MouseArea {
63
                            anchors.fill: parent
64
                            onClicked: visible = false
65
                        }
66
                    }
67
                }
68
                
69
                Rectangle {
70
                    Layout.fillWidth: true
71
                    Layout.preferredHeight: 200
72
                    color: "#16161e"
73
                    radius: 8
74
                    
75
                    ColumnLayout {
76
                        anchors.fill: parent
77
                        anchors.margins: 15
78
                        spacing: 10
79
                        
80
                        Text {
81
                            text: "System Stats"
82
                            color: "#7aa2f7"
83
                            font.pixelSize: 16
84
                            font.family: "JetBrainsMono Nerd Font"
85
                            font.bold: true
86
                        }
87
                        
88
                        RowLayout {
89
                            Layout.fillWidth: true
90
                            
91
                            Text {
92
                                text: "CPU"
93
                                color: "#a9b1d6"
94
                                font.pixelSize: 14
95
                                font.family: "JetBrainsMono Nerd Font"
96
                                Layout.preferredWidth: 80
97
                            }
98
                            
99
                            Rectangle {
100
                                Layout.fillWidth: true
101
                                height: 20
102
                                color: "#32344a"
103
                                radius: 4
104
                                
105
                                Rectangle {
106
                                    width: parent.width * 0.45
107
                                    height: parent.height
108
                                    color: "#e0af68"
109
                                    radius: 4
110
                                }
111
                            }
112
                            
113
                            Text {
114
                                text: "45%"
115
                                color: "#a9b1d6"
116
                                font.pixelSize: 14
117
                                font.family: "JetBrainsMono Nerd Font"
118
                                Layout.preferredWidth: 50
119
                            }
120
                        }
121
                        
122
                        RowLayout {
123
                            Layout.fillWidth: true
124
                            
125
                            Text {
126
                                text: "Memory"
127
                                color: "#a9b1d6"
128
                                font.pixelSize: 14
129
                                font.family: "JetBrainsMono Nerd Font"
130
                                Layout.preferredWidth: 80
131
                            }
132
                            
133
                            Rectangle {
134
                                Layout.fillWidth: true
135
                                height: 20
136
                                color: "#32344a"
137
                                radius: 4
138
                                
139
                                Rectangle {
140
                                    width: parent.width * 0.62
141
                                    height: parent.height
142
                                    color: "#9ece6a"
143
                                    radius: 4
144
                                }
145
                            }
146
                            
147
                            Text {
148
                                text: "62%"
149
                                color: "#a9b1d6"
150
                                font.pixelSize: 14
151
                                font.family: "JetBrainsMono Nerd Font"
152
                                Layout.preferredWidth: 50
153
                            }
154
                        }
155
                        
156
                        RowLayout {
157
                            Layout.fillWidth: true
158
                            
159
                            Text {
160
                                text: "Disk"
161
                                color: "#a9b1d6"
162
                                font.pixelSize: 14
163
                                font.family: "JetBrainsMono Nerd Font"
164
                                Layout.preferredWidth: 80
165
                            }
166
                            
167
                            Rectangle {
168
                                Layout.fillWidth: true
169
                                height: 20
170
                                color: "#32344a"
171
                                radius: 4
172
                                
173
                                Rectangle {
174
                                    width: parent.width * 0.73
175
                                    height: parent.height
176
                                    color: "#7aa2f7"
177
                                    radius: 4
178
                                }
179
                            }
180
                            
181
                            Text {
182
                                text: "73%"
183
                                color: "#a9b1d6"
184
                                font.pixelSize: 14
185
                                font.family: "JetBrainsMono Nerd Font"
186
                                Layout.preferredWidth: 50
187
                            }
188
                        }
189
                    }
190
                }
191
                
192
                Rectangle {
193
                    Layout.fillWidth: true
194
                    Layout.preferredHeight: 120
195
                    color: "#16161e"
196
                    radius: 8
197
                    
198
                    ColumnLayout {
199
                        anchors.fill: parent
200
                        anchors.margins: 15
201
                        spacing: 10
202
                        
203
                        Text {
204
                            text: "Quick Controls"
205
                            color: "#7aa2f7"
206
                            font.pixelSize: 16
207
                            font.family: "JetBrainsMono Nerd Font"
208
                            font.bold: true
209
                        }
210
                        
211
                        RowLayout {
212
                            Layout.fillWidth: true
213
                            
214
                            Text {
215
                                text: "🔊"
216
                                font.pixelSize: 20
217
                            }
218
                            
219
                            Rectangle {
220
                                Layout.fillWidth: true
221
                                height: 8
222
                                color: "#32344a"
223
                                radius: 4
224
                                
225
                                Rectangle {
226
                                    width: parent.width * 0.7
227
                                    height: parent.height
228
                                    color: "#ad8ee6"
229
                                    radius: 4
230
                                }
231
                            }
232
                            
233
                            Text {
234
                                text: "70%"
235
                                color: "#a9b1d6"
236
                                font.pixelSize: 14
237
                                font.family: "JetBrainsMono Nerd Font"
238
                            }
239
                        }
240
                        
241
                        RowLayout {
242
                            Layout.fillWidth: true
243
                            
244
                            Text {
245
                                text: "☀️"
246
                                font.pixelSize: 20
247
                            }
248
                            
249
                            Rectangle {
250
                                Layout.fillWidth: true
251
                                height: 8
252
                                color: "#32344a"
253
                                radius: 4
254
                                
255
                                Rectangle {
256
                                    width: parent.width * 0.85
257
                                    height: parent.height
258
                                    color: "#e0af68"
259
                                    radius: 4
260
                                }
261
                            }
262
                            
263
                            Text {
264
                                text: "85%"
265
                                color: "#a9b1d6"
266
                                font.pixelSize: 14
267
                                font.family: "JetBrainsMono Nerd Font"
268
                            }
269
                        }
270
                    }
271
                }
272
                
273
                Rectangle {
274
                    Layout.fillWidth: true
275
                    Layout.preferredHeight: 100
276
                    color: "#16161e"
277
                    radius: 8
278
                    
279
                    ColumnLayout {
280
                        anchors.fill: parent
281
                        anchors.margins: 15
282
                        spacing: 5
283
                        
284
                        Text {
285
                            text: Qt.formatDateTime(new Date(), "dddd, MMMM d")
286
                            color: "#0db9d7"
287
                            font.pixelSize: 18
288
                            font.family: "JetBrainsMono Nerd Font"
289
                            font.bold: true
290
                        }
291
                        
292
                        Text {
293
                            text: Qt.formatDateTime(new Date(), "h:mm AP")
294
                            color: "#a9b1d6"
295
                            font.pixelSize: 28
296
                            font.family: "JetBrainsMono Nerd Font"
297
                            font.bold: true
298
                        }
299
                    }
300
                }
301
                
302
                Item { Layout.fillHeight: true }
303
                
304
                RowLayout {
305
                    Layout.fillWidth: true
306
                    spacing: 10
307
                    
308
                    Rectangle {
309
                        Layout.fillWidth: true
310
                        height: 40
311
                        color: "#32344a"
312
                        radius: 8
313
                        
314
                        Text {
315
                            anchors.centerIn: parent
316
                            text: "Lock"
317
                            color: "#a9b1d6"
318
                            font.pixelSize: 14
319
                            font.family: "JetBrainsMono Nerd Font"
320
                        }
321
                        
322
                        MouseArea {
323
                            anchors.fill: parent
324
                            onClicked: {
325
                            }
326
                        }
327
                    }
328
                    
329
                    Rectangle {
330
                        Layout.fillWidth: true
331
                        height: 40
332
                        color: "#f7768e"
333
                        radius: 8
334
                        
335
                        Text {
336
                            anchors.centerIn: parent
337
                            text: "Power"
338
                            color: "#1a1b26"
339
                            font.pixelSize: 14
340
                            font.family: "JetBrainsMono Nerd Font"
341
                            font.bold: true
342
                        }
343
                        
344
                        MouseArea {
345
                            anchors.fill: parent
346
                            onClicked: {
347
                            }
348
                        }
349
                    }
350
                }
351
            }
352
        }
353
    }
354
}