Initial UI

This commit is contained in:
Agel committed 2026-03-15 20:33:36 +01:00
1 parent 4d52c8cc60
commit 3c0037cfc9
29 files changed
+1367 -2

No files matched your search

Binary file not shown.
+246
View File
@@ -0,0 +1,246 @@
<?xml version="1.0" standalone="no"?>
<!DOCTYPE svg PUBLIC "-//W3C//DTD SVG 20010904//EN"
"http://www.w3.org/TR/2001/REC-SVG-20010904/DTD/svg10.dtd">
<svg version="1.0" xmlns="http://www.w3.org/2000/svg"
width="1280.000000pt" height="904.000000pt" viewBox="0 0 1280.000000 904.000000"
preserveAspectRatio="xMidYMid meet">
<metadata>
Created by potrace 1.15, written by Peter Selinger 2001-2017
</metadata>
<g transform="translate(0.000000,904.000000) scale(0.100000,-0.100000)"
fill="#000000" stroke="none">
<path d="M2715 8837 c-131 -21 -215 -42 -271 -68 -34 -16 -67 -29 -75 -29 -8
0 -19 -4 -25 -9 -22 -20 -141 -41 -294 -52 -156 -11 -289 -10 -721 7 -141 6
-188 3 -304 -20 -11 -2 -63 -9 -115 -15 -101 -12 -174 -29 -308 -68 -89 -26
-139 -34 -242 -37 -36 -1 -131 -6 -212 -11 l-148 -8 0 -1024 c0 -1021 0 -1024
20 -1013 11 6 20 7 20 2 0 -10 20 -14 78 -13 23 0 41 -3 38 -7 -2 -4 46 -7
107 -8 62 0 121 -2 132 -4 11 -2 66 0 123 4 91 7 102 10 102 27 0 10 6 19 13
19 8 0 7 4 -3 10 -13 8 -13 10 2 10 9 0 18 5 20 12 3 7 20 13 39 15 19 1 48 5
64 7 17 3 62 8 100 11 39 4 87 11 107 16 20 5 103 11 185 14 176 4 254 19 428
79 121 41 263 101 275 115 4 5 78 43 90 46 26 7 82 37 99 54 12 12 41 31 64
43 42 22 103 65 143 103 12 11 39 36 60 56 22 20 71 71 109 114 90 101 95 105
106 105 5 0 9 4 9 9 0 5 19 29 43 53 23 25 53 65 67 88 14 24 71 90 127 146
56 57 109 117 119 134 10 16 21 30 25 30 8 0 26 50 34 91 3 13 10 35 16 49 43
92 68 175 68 222 -1 21 4 59 9 85 35 157 51 317 36 351 -4 9 -8 22 -8 27 -2
20 -40 95 -48 95 -4 0 -8 6 -8 14 0 7 -10 20 -23 29 -12 8 -38 30 -57 49 -51
50 -108 63 -215 45z"/>
<path d="M9370 8049 c-19 -4 -114 -8 -210 -8 -317 1 -362 -16 -374 -140 -13
-148 -46 -175 -256 -212 -41 -7 -96 -28 -150 -57 -47 -24 -98 -51 -114 -60
-24 -12 -37 -13 -83 -2 -48 10 -67 23 -166 113 -151 138 -189 167 -282 223
l-80 47 -134 -1 c-105 -2 -152 2 -224 19 -52 13 -92 18 -94 12 -4 -10 -76 -3
-223 22 -68 12 -172 18 -365 21 -148 1 -345 6 -437 9 -135 5 -195 2 -320 -15
-84 -11 -227 -29 -318 -40 -91 -11 -183 -25 -205 -31 -22 -6 -87 -22 -145 -35
-188 -42 -468 -118 -482 -132 -14 -14 9 -27 117 -62 55 -18 114 -40 130 -50
32 -19 376 -130 403 -130 20 0 172 -71 172 -80 0 -14 -53 -51 -122 -86 -69
-34 -251 -140 -392 -229 -271 -171 -430 -311 -486 -430 -75 -160 -92 -191
-109 -200 -10 -6 -42 -23 -72 -39 -29 -15 -93 -37 -141 -46 -79 -17 -141 -35
-203 -60 -109 -45 -220 -73 -320 -81 -171 -14 -265 -50 -440 -169 -87 -58
-270 -160 -289 -160 -3 0 -47 -20 -98 -44 -51 -24 -111 -51 -133 -60 -22 -10
-49 -21 -60 -26 -82 -37 -202 -44 -420 -25 -99 8 -129 0 -171 -47 -25 -27 -74
-117 -74 -135 0 -7 -12 -38 -26 -70 -45 -103 -52 -118 -58 -140 -10 -30 -89
-161 -120 -197 -14 -16 -23 -33 -20 -37 9 -14 -6 -49 -21 -49 -7 0 -15 -10
-19 -23 -3 -13 -14 -34 -26 -46 -11 -13 -17 -28 -14 -33 3 -5 -4 -12 -16 -15
-18 -5 -21 -11 -18 -35 3 -19 -1 -33 -11 -41 -9 -7 -22 -24 -28 -39 -15 -34
-34 -37 -30 -6 2 19 -3 23 -25 22 -20 -1 -28 5 -33 23 -4 17 -11 23 -21 19 -8
-3 -13 -2 -10 3 13 20 -25 18 -73 -6 -44 -21 -55 -22 -68 -11 -14 11 -14 10 0
-13 15 -23 16 -28 3 -38 -11 -9 -20 -10 -35 -1 -16 8 -27 8 -43 -2 -13 -7 -27
-11 -31 -10 -4 1 -7 -5 -5 -15 2 -9 -6 -22 -17 -28 -25 -13 -33 -40 -9 -31 10
4 21 1 26 -6 5 -9 8 -10 8 -1 0 8 9 7 30 -5 22 -13 28 -22 23 -37 -3 -11 -11
-23 -17 -27 -6 -4 -7 -11 -2 -15 4 -4 14 0 21 10 8 12 15 14 20 8 3 -6 1 -11
-5 -11 -6 0 -10 -8 -8 -17 5 -26 33 -22 33 4 0 13 3 23 8 23 4 0 11 0 15 0 15
0 11 -148 -4 -161 -10 -8 -14 -8 -14 0 0 6 -4 11 -9 11 -8 0 -9 -37 -2 -59 0
-2 8 2 16 9 9 8 15 8 15 2 0 -17 61 -35 86 -25 23 9 -2 30 -43 38 l-37 7 23
17 c22 17 22 49 0 36 -5 -3 -6 1 -3 9 7 17 34 30 34 16 0 -14 37 -13 46 1 3 6
0 15 -7 20 -11 7 -10 9 4 9 11 0 17 -8 17 -24 0 -13 7 -26 15 -30 8 -3 15 -13
15 -21 0 -9 4 -14 9 -10 18 10 21 -13 5 -30 -9 -9 -14 -18 -11 -21 9 -9 27 6
27 22 0 8 6 14 14 14 10 0 16 -13 18 -37 3 -34 5 -36 43 -39 22 -1 57 4 79 11
22 8 43 12 47 10 4 -3 9 2 13 10 3 8 12 15 21 15 8 0 15 4 15 8 0 4 9 9 20 10
11 1 29 3 40 4 11 1 20 6 20 10 0 15 29 8 38 -9 9 -15 12 -14 43 4 28 16 41
18 69 11 19 -5 69 -11 110 -13 216 -10 493 -101 584 -191 14 -15 26 -23 26
-18 0 5 6 -2 13 -16 8 -14 19 -24 25 -22 7 1 12 -2 12 -8 0 -5 5 -10 12 -10 6
0 19 -6 27 -13 28 -22 237 -84 381 -113 247 -48 281 -57 515 -133 193 -64 264
-76 360 -61 188 29 375 138 420 246 25 61 14 181 -21 224 -6 8 -26 43 -43 77
-35 70 -68 105 -127 132 -45 22 -135 46 -203 56 -94 14 -241 82 -295 136 -15
16 -32 29 -36 29 -4 0 -13 14 -20 30 -17 41 1 226 26 268 22 39 127 107 211
138 63 23 77 24 193 19 159 -8 251 -20 370 -51 204 -52 388 -68 485 -44 76 20
145 44 145 52 0 4 6 8 13 8 20 0 56 42 66 77 19 66 -16 110 -100 128 -33 7
-150 51 -219 82 -62 28 -128 84 -145 124 -27 58 -15 104 54 223 34 58 61 108
61 113 0 11 31 71 51 100 29 42 107 93 166 108 32 8 128 20 213 25 85 6 200
14 254 20 55 5 102 7 105 4 3 -3 6 -80 6 -170 0 -90 3 -164 8 -164 4 0 8 48 9
108 0 59 2 112 3 117 2 6 3 33 4 61 l1 52 68 6 c37 4 144 20 239 36 199 34
468 70 521 70 49 0 68 -14 142 -106 102 -127 188 -320 218 -488 14 -76 27
-117 45 -144 14 -20 33 -63 41 -95 9 -33 27 -87 41 -122 29 -73 31 -103 9
-112 -9 -3 -58 2 -110 12 -89 17 -100 17 -176 1 -151 -30 -206 -68 -259 -180
-57 -122 -105 -173 -314 -338 -75 -60 -80 -66 -83 -106 -2 -25 1 -42 7 -42 6
0 11 -6 11 -12 0 -19 89 -111 140 -146 44 -29 90 -76 158 -160 17 -22 32 -43
32 -47 0 -3 18 -28 40 -56 l40 -51 -29 -39 c-24 -33 -28 -48 -27 -94 1 -44 8
-63 34 -100 l33 -47 -21 -42 c-27 -57 -26 -69 15 -112 19 -20 35 -43 35 -51 0
-34 -69 -144 -139 -222 -131 -146 -182 -192 -354 -320 -92 -68 -167 -127 -167
-132 0 -5 -4 -9 -10 -9 -16 0 -11 38 10 80 11 22 27 67 36 100 9 35 26 71 40
85 13 13 27 38 30 55 l7 30 24 -24 c41 -42 121 -38 108 5 -4 13 -2 19 9 19 23
0 20 31 -4 37 -11 3 -17 9 -14 14 3 5 10 7 15 4 5 -4 9 2 9 12 0 11 5 24 12
31 8 8 2 22 -27 54 -21 24 -45 49 -53 56 -9 6 -12 12 -7 12 5 0 0 7 -12 15
-22 15 -53 68 -53 90 0 8 -9 10 -24 8 -16 -3 -45 6 -80 25 -35 18 -59 26 -68
21 -7 -5 -30 -9 -50 -9 -27 0 -41 6 -53 23 l-16 22 -20 -27 c-12 -16 -25 -28
-31 -28 -23 0 -97 -57 -112 -85 -8 -16 -29 -48 -45 -70 -54 -71 -61 -208 -14
-238 27 -17 11 -27 -39 -27 -61 0 -183 -32 -251 -67 -65 -32 -120 -90 -158
-164 l-31 -62 -59 7 c-43 4 -70 1 -96 -9 -19 -8 -47 -15 -62 -15 -14 -1 -44
-9 -66 -20 -66 -32 -65 -32 -65 93 0 90 4 121 20 156 11 24 20 49 20 56 0 7
-24 37 -53 67 -44 46 -64 58 -125 78 -42 13 -77 19 -82 14 -5 -5 9 -46 32 -94
64 -133 63 -173 -15 -414 l-42 -131 -6 95 c-3 52 -11 123 -18 156 -10 52 -9
69 5 109 22 66 8 94 -72 144 -35 22 -72 53 -81 69 -39 62 -98 122 -119 122
-46 0 -42 -72 7 -139 16 -23 47 -76 69 -119 46 -89 50 -130 25 -284 -8 -51
-18 -120 -22 -154 l-8 -60 -143 23 c-100 16 -174 35 -250 64 -59 22 -138 52
-176 65 -38 14 -74 28 -80 33 -6 5 -43 22 -83 39 l-72 30 59 -77 c33 -42 94
-116 135 -166 41 -49 111 -133 155 -187 44 -53 92 -105 107 -116 62 -45 201
-169 219 -194 24 -36 97 -89 172 -127 33 -17 90 -55 126 -86 70 -59 155 -105
196 -105 14 0 50 -16 80 -35 30 -19 60 -35 67 -35 6 0 44 -16 84 -35 41 -19
80 -35 89 -35 8 0 69 -17 135 -39 174 -56 280 -85 460 -126 262 -60 275 -62
410 -69 72 -4 188 -14 259 -22 111 -14 171 -14 416 -5 248 9 346 17 553 46 38
5 38 5 36 -23 -3 -20 8 -49 32 -88 20 -33 39 -76 43 -97 4 -21 14 -41 22 -44
7 -3 14 -11 14 -19 0 -8 5 -15 10 -15 6 -1 15 -2 20 -3 6 0 14 -6 18 -11 4 -6
28 -22 55 -35 26 -14 47 -28 47 -32 0 -5 9 -17 20 -28 12 -12 18 -25 15 -31
-4 -5 7 -14 23 -20 28 -10 61 -60 54 -83 -2 -5 6 -15 18 -23 11 -8 20 -23 20
-33 0 -11 18 -36 39 -56 38 -34 39 -39 36 -85 -3 -27 -9 -58 -15 -68 -23 -44
41 -113 145 -156 97 -41 139 -39 177 5 16 19 38 52 49 72 10 20 27 43 37 50
11 7 26 27 35 44 13 25 34 39 99 67 85 36 215 71 303 82 64 8 104 23 133 49
13 12 24 19 25 16 1 -2 13 3 26 12 20 14 27 32 37 95 9 53 10 90 3 114 -11 46
-74 105 -120 113 -19 4 -78 19 -132 33 -79 22 -102 24 -115 15 -45 -32 -64
-37 -77 -19 -8 12 -14 14 -17 6 -2 -6 -18 -13 -35 -15 -17 -2 -35 -5 -40 -6
-13 -4 -143 64 -143 74 0 6 -7 7 -16 4 -19 -7 -63 40 -64 69 -1 25 -72 105
-94 105 -12 0 -16 7 -14 28 2 15 7 30 12 33 5 4 1 17 -8 30 -26 38 -19 55 36
95 45 32 546 288 617 315 33 13 132 -51 156 -100 58 -121 84 -166 113 -196 17
-19 32 -38 32 -43 0 -5 35 -39 77 -76 l77 -68 58 6 c61 6 107 30 166 85 19 17
49 38 67 46 41 17 233 57 243 51 4 -2 38 -6 74 -8 59 -2 70 0 92 21 21 20 26
34 26 73 0 108 100 266 179 281 51 11 191 8 234 -4 27 -7 60 -33 110 -84 89
-90 124 -103 234 -85 40 6 107 11 150 11 142 0 361 27 425 53 111 45 166 87
264 198 101 115 117 145 134 255 13 79 1 119 -43 147 -23 16 -100 10 -177 -13
-19 -6 -107 -11 -196 -11 -125 0 -177 -4 -235 -19 -177 -45 -317 -36 -449 27
-116 56 -227 73 -323 49 -80 -20 -407 -25 -407 -6 0 7 -7 8 -17 4 -23 -9 -257
-6 -261 3 -1 4 -21 6 -44 4 -41 -4 -42 -4 -28 16 114 158 191 295 229 410 12
35 46 116 76 180 116 251 185 545 185 786 0 52 7 130 15 173 8 43 18 146 20
228 11 288 14 330 26 375 10 39 9 55 -10 125 -12 44 -35 132 -51 195 -16 63
-36 135 -45 160 -9 25 -29 99 -46 165 -17 66 -47 154 -67 197 -33 68 -41 77
-75 88 -111 33 -197 209 -141 289 16 22 15 27 -4 75 -11 28 -22 58 -25 66 -4
13 13 20 79 34 46 10 84 23 84 27 0 5 5 9 12 9 6 0 48 37 92 83 67 68 97 90
171 126 50 24 113 55 140 69 59 30 172 125 180 153 10 30 -44 117 -120 195
-64 65 -77 74 -151 98 -127 42 -187 48 -274 31 -117 -24 -129 -31 -137 -79 -4
-25 -17 -52 -34 -68 -24 -25 -35 -28 -91 -28 -51 0 -65 4 -75 19 -7 10 -37 33
-67 51 -37 21 -56 38 -56 51 0 36 33 104 69 143 48 51 86 67 149 59 97 -11
120 9 132 118 9 78 39 144 87 191 34 33 35 33 142 36 128 4 143 -1 222 -83 65
-67 106 -82 193 -67 33 5 96 10 140 11 192 5 299 19 374 49 90 37 137 74 229
178 70 80 88 111 112 202 7 23 16 42 20 42 5 0 4 21 -3 47 -9 37 -19 50 -46
65 -47 25 -101 23 -158 -6 -45 -23 -57 -24 -202 -23 -138 1 -163 -1 -223 -22
-122 -41 -276 -31 -334 22 -13 11 -23 17 -23 14 0 -4 -19 1 -42 10 -34 14 -68
17 -168 15 -273 -6 -316 -6 -350 -1 -19 3 -51 2 -70 -2z m-42 -1146 c-10 -2
-26 -2 -35 0 -10 3 -2 5 17 5 19 0 27 -2 18 -5z m-7641 -1935 c-3 -8 -6 -5 -6
6 -1 11 2 17 5 13 3 -3 4 -12 1 -19z m-147 -148 c0 -5 -5 -10 -11 -10 -5 0 -7
5 -4 10 3 6 8 10 11 10 2 0 4 -4 4 -10z m80 0 c0 -5 -4 -10 -10 -10 -5 0 -10
5 -10 10 0 6 5 10 10 10 6 0 10 -4 10 -10z m-145 -20 c3 -6 -1 -7 -9 -4 -18 7
-21 14 -7 14 6 0 13 -4 16 -10z m47 -41 c6 -15 3 -15 -23 -5 -17 6 -25 12 -19
14 5 2 10 10 10 19 0 12 2 12 13 1 7 -7 16 -20 19 -29z m111 -145 c9 -9 -4
-34 -18 -34 -8 0 -11 8 -8 20 5 20 15 25 26 14z m4517 -1244 c0 -5 -7 -7 -15
-4 -8 4 -15 8 -15 10 0 2 7 4 15 4 8 0 15 -4 15 -10z m-486 -352 c-14 -47 -55
-119 -64 -113 -10 6 22 99 42 122 17 21 30 15 22 -9z"/>
<path d="M3339 7139 c-6 -12 -13 -31 -15 -43 -2 -11 -7 -36 -10 -53 -8 -42 11
-44 34 -3 11 20 24 29 36 28 26 -4 32 18 6 25 -13 3 -20 13 -20 30 0 34 -16
43 -31 16z"/>
<path d="M3300 6981 c-6 -12 -8 -21 -5 -21 3 0 -1 -13 -10 -30 -8 -16 -15 -39
-15 -52 1 -21 3 -20 35 14 25 27 40 35 57 32 l23 -5 -22 17 c-13 9 -23 22 -23
29 0 7 -6 18 -14 24 -12 10 -17 8 -26 -8z"/>
<path d="M3171 6971 c-6 -4 -11 -12 -10 -17 1 -5 -3 -22 -10 -38 -16 -40 -4
-47 24 -14 15 17 30 26 39 22 22 -9 20 1 -7 30 -14 15 -28 22 -36 17z"/>
<path d="M3660 6910 c-23 -23 -35 -63 -25 -87 6 -16 8 -15 16 6 6 14 15 21 24
17 19 -7 31 14 14 25 -11 7 -12 12 -1 29 6 11 12 22 12 25 0 12 -21 4 -40 -15z"/>
<path d="M3693 6637 c-11 -36 -6 -97 7 -97 5 0 12 9 15 21 4 12 12 18 21 15 7
-3 16 -1 20 5 3 6 -3 13 -15 16 -16 4 -21 13 -21 39 0 43 -14 44 -27 1z"/>
<path d="M4060 6595 c-12 -13 -27 -22 -31 -19 -5 3 -9 0 -9 -6 0 -7 -10 -20
-22 -30 -32 -26 -16 -36 33 -20 33 11 42 11 49 1 4 -8 13 -10 19 -7 13 9 15
36 2 36 -6 0 -7 16 -4 35 7 41 -5 44 -37 10z"/>
<path d="M3848 6478 c-17 -17 -22 -32 -20 -58 6 -55 42 -86 42 -35 0 22 3 25
25 19 21 -5 25 -3 25 15 0 15 -6 21 -21 21 -15 0 -19 4 -15 15 3 8 9 22 12 30
9 23 -22 18 -48 -7z"/>
<path d="M4980 5961 c0 -6 -10 -19 -22 -31 -12 -11 -18 -20 -13 -20 5 0 -2
-11 -15 -25 -30 -32 -18 -44 19 -22 16 9 36 15 44 11 8 -3 17 2 20 10 4 9 2
16 -4 16 -6 0 -9 14 -7 32 2 19 -2 33 -9 35 -7 3 -13 0 -13 -6z"/>
<path d="M5206 5922 c-16 -27 -10 -79 13 -108 l24 -29 -7 28 c-5 20 -3 27 9
27 8 0 15 5 15 10 0 6 -6 10 -14 10 -8 0 -18 16 -23 37 -6 26 -11 34 -17 25z"/>
<path d="M5479 5893 c0 -5 -2 -19 -4 -33 -1 -14 4 -33 13 -42 15 -18 33 -24
31 -10 -4 24 3 33 21 27 26 -8 26 7 -1 23 -12 8 -18 19 -15 28 4 10 -2 14 -19
14 -14 0 -25 -3 -26 -7z"/>
<path d="M5733 5825 c0 -27 2 -38 4 -22 2 15 2 37 0 50 -2 12 -4 0 -4 -28z"/>
<path d="M5720 5540 c0 -11 2 -20 4 -20 2 0 6 9 9 20 3 11 1 20 -4 20 -5 0 -9
-9 -9 -20z"/>
<path d="M5722 5480 c0 -14 2 -19 5 -12 2 6 2 18 0 25 -3 6 -5 1 -5 -13z"/>
<path d="M5722 5410 c0 -19 2 -27 5 -17 2 9 2 25 0 35 -3 9 -5 1 -5 -18z"/>
<path d="M5606 5228 c-20 -28 -20 -78 -3 -121 15 -35 13 -203 -3 -222 -4 -5
-25 -50 -45 -100 -52 -125 -99 -217 -156 -304 -27 -41 -49 -81 -49 -90 0 -22
19 -41 40 -41 14 0 15 -9 8 -72 -5 -40 -14 -75 -20 -79 -7 -5 -7 -8 1 -10 8
-3 8 -28 1 -89 -15 -128 -13 -166 8 -176 24 -10 313 -42 335 -36 22 5 26 23
46 186 l16 131 40 6 40 6 -37 2 -38 1 0 46 c0 44 1 46 24 40 29 -7 50 15 43
46 -3 13 -21 68 -41 122 -42 114 -100 380 -98 444 1 24 7 52 12 62 6 10 10 29
10 42 0 13 11 45 25 72 42 83 27 125 -49 145 -66 16 -93 14 -110 -11z m106
-23 c44 -8 53 -32 31 -87 -12 -30 -19 -37 -32 -32 -9 4 -28 7 -43 6 -23 -1
-29 4 -34 26 -3 15 -8 33 -10 40 -2 8 -1 25 2 39 5 19 11 23 28 19 11 -2 37
-8 58 -11z m-12 -192 c0 -19 -5 -23 -30 -23 -16 0 -30 4 -30 9 0 25 14 40 36
39 18 -2 24 -8 24 -25z m-190 -927 c0 -49 -4 -56 -30 -49 -16 4 -18 11 -13 32
19 82 43 91 43 17z m160 -16 c0 -44 -2 -50 -21 -50 -19 0 -20 4 -14 43 6 35
18 56 33 57 1 0 2 -22 2 -50z"/>
<path d="M1195 4900 c-3 -5 1 -10 9 -10 9 0 16 5 16 10 0 6 -4 10 -9 10 -6 0
-13 -4 -16 -10z"/>
<path d="M1185 4870 c3 -5 8 -10 11 -10 2 0 4 5 4 10 0 6 -5 10 -11 10 -5 0
-7 -4 -4 -10z"/>
<path d="M950 4796 c-10 -28 -28 -37 -52 -24 -10 5 -18 5 -18 0 0 -5 -8 -18
-17 -30 -10 -12 -26 -31 -35 -44 -10 -12 -33 -27 -50 -32 -32 -11 -33 -13 -32
-63 1 -44 -1 -53 -16 -53 -10 0 -21 -7 -24 -16 -5 -13 -9 -14 -21 -4 -13 10
-15 8 -15 -14 0 -19 -6 -27 -24 -32 -25 -6 -39 -26 -41 -54 0 -10 -8 -14 -24
-12 -13 2 -28 -2 -32 -10 -7 -10 -13 -9 -27 8 -9 12 -29 24 -44 28 -22 5 -25
3 -21 -14 4 -14 0 -20 -11 -20 -9 0 -13 -6 -10 -15 4 -8 10 -12 16 -9 5 3 8
-2 6 -11 -2 -10 3 -20 11 -23 10 -3 12 0 8 11 -3 9 -2 19 4 23 19 11 22 -5 5
-30 -9 -14 -16 -27 -16 -30 0 -2 20 -2 45 0 27 3 45 0 45 -6 0 -5 11 -10 24
-10 26 0 43 30 30 51 -5 8 -1 8 14 0 28 -15 32 -14 32 10 0 11 4 18 10 14 5
-3 8 -11 6 -18 -1 -7 -1 -9 1 -4 3 4 13 7 23 7 14 0 18 -7 16 -32 -1 -31 1
-33 29 -30 17 2 36 9 43 14 9 8 12 3 12 -21 0 -20 5 -31 14 -31 8 0 16 -7 20
-15 8 -23 28 -18 21 5 -5 14 -2 20 9 20 9 0 16 6 16 13 0 7 8 20 19 29 10 8
21 22 24 29 4 10 9 8 22 -9 16 -22 18 -22 31 -5 9 12 13 13 14 5 0 -7 4 -11 9
-8 5 3 11 -3 14 -15 5 -18 12 -20 65 -17 45 2 58 6 54 16 -3 9 2 13 14 11 32
-6 31 15 -1 22 -24 5 -26 7 -13 13 9 4 22 5 28 1 5 -3 10 -1 10 5 0 7 7 10 15
6 8 -3 15 -1 15 4 0 6 9 10 21 10 15 0 19 5 15 15 -4 11 0 15 12 13 11 -2 16
2 14 12 -2 8 0 11 5 7 4 -5 8 -14 8 -20 0 -6 16 -13 35 -14 19 -2 42 -5 50 -8
8 -3 4 3 -9 14 -16 12 -20 20 -11 23 7 2 14 18 14 34 1 26 -2 30 -18 26 -15
-4 -18 -1 -12 13 5 15 4 16 -9 5 -12 -10 -15 -9 -15 6 0 16 -2 17 -10 4 -8
-12 -10 -11 -10 7 0 12 -4 24 -10 28 -5 3 -6 13 -3 23 3 9 3 14 -2 10 -12 -11
-64 20 -61 37 1 8 5 17 8 21 4 3 2 19 -4 35 -12 34 -3 83 13 73 7 -4 9 1 7 12
-3 17 -13 19 -77 19 -45 0 -75 -4 -78 -11 -6 -16 -68 -2 -68 15 0 8 -10 18
-23 22 -19 7 -24 4 -32 -15z m210 -126 c0 -5 -4 -10 -10 -10 -5 0 -10 5 -10
10 0 6 5 10 10 10 6 0 10 -4 10 -10z m-390 -215 c9 -11 16 -12 31 -2 14 8 21
9 30 0 8 -8 2 -13 -22 -18 -22 -5 -34 -4 -37 4 -2 6 -10 11 -17 11 -8 0 -17 5
-20 10 -10 16 21 12 35 -5z m154 -21 c4 -9 4 -19 2 -21 -8 -8 -26 8 -26 23 0
19 16 18 24 -2z m-138 -50 c-4 -9 -2 -22 4 -29 8 -10 4 -14 -16 -19 -30 -8
-45 1 -25 14 11 6 10 9 -5 12 -16 3 -14 6 11 20 39 21 38 21 31 2z m-256 -19
c-7 -9 -15 -13 -17 -11 -7 7 7 26 19 26 6 0 6 -6 -2 -15z"/>
<path d="M10935 4587 c-16 -5 -37 -13 -45 -17 -9 -4 -30 -11 -48 -14 -17 -4
-59 -24 -92 -43 -61 -37 -77 -64 -68 -118 4 -25 38 -65 55 -65 7 0 13 -6 13
-12 1 -19 52 -75 84 -91 26 -14 33 -13 104 20 50 23 95 35 132 38 100 5 137
15 148 39 6 14 6 28 0 39 -6 11 -5 17 1 17 13 0 7 33 -7 38 -7 2 -12 11 -12
20 -1 18 -29 73 -30 57 0 -5 -23 14 -50 43 -47 47 -55 52 -103 55 -29 2 -65 0
-82 -6z"/>
<path d="M1283 4383 c-21 -8 -15 -22 7 -16 11 3 20 9 20 14 0 10 -8 10 -27 2z"/>
<path d="M437 4303 c-10 -18 -17 -62 -12 -76 8 -19 87 -17 93 2 3 9 0 12 -10
9 -8 -4 -20 2 -26 13 -9 13 -9 19 -1 19 6 0 9 6 6 13 -2 6 -10 11 -16 10 -6
-2 -11 2 -11 7 0 12 -17 13 -23 3z"/>
<path d="M556 4245 c-3 -8 -1 -15 4 -15 6 0 10 7 10 15 0 8 -2 15 -4 15 -2 0
-6 -7 -10 -15z"/>
<path d="M10729 3953 c-15 -18 -26 -39 -51 -100 -7 -18 -16 -33 -20 -33 -5 0
-8 -13 -8 -30 0 -30 0 -30 55 -27 34 1 55 6 55 14 0 6 6 13 13 16 10 4 10 7 0
18 -7 7 -12 33 -12 59 1 25 4 35 6 23 2 -13 9 -23 14 -23 12 0 1 42 -13 51 -6
4 -6 9 1 13 6 4 11 13 11 19 0 8 -3 7 -9 -2 -7 -11 -10 -10 -18 3 -8 15 -10
15 -24 -1z"/>
<path d="M9892 1625 c-38 -18 -53 -30 -57 -49 -3 -14 -7 -37 -10 -51 -3 -13
-13 -32 -23 -42 -30 -30 -98 -116 -111 -140 -6 -12 -11 -41 -11 -64 0 -23 -11
-81 -24 -128 -31 -110 -59 -260 -54 -291 2 -15 14 -30 31 -38 27 -13 32 -12
80 21 29 19 75 46 102 59 28 14 75 40 105 60 66 43 181 92 260 113 98 25 165
61 245 131 71 62 76 69 71 98 -13 63 -167 255 -224 278 -45 18 -214 57 -267
62 -50 4 -70 1 -113 -19z"/>
</g>
</svg>

After

Width:  |  Height:  |  Size: 17 KiB

+21
View File
@@ -0,0 +1,21 @@
#include "AppState.h"
AppState::AppState(QObject *parent)
: QObject(parent)
{
}
QString AppState::lastFilePath() const
{
return m_lastFilePath;
}
void AppState::save()
{
// Will use QSettings via TDD
}
void AppState::restore()
{
// Will use QSettings via TDD
}
+26
View File
@@ -0,0 +1,26 @@
#ifndef APPSTATE_H
#define APPSTATE_H
#include <QObject>
#include <QString>
class AppState : public QObject {
Q_OBJECT
Q_PROPERTY(QString lastFilePath READ lastFilePath NOTIFY lastFilePathChanged)
public:
explicit AppState(QObject *parent = nullptr);
QString lastFilePath() const;
Q_INVOKABLE void save();
Q_INVOKABLE void restore();
signals:
void lastFilePathChanged();
private:
QString m_lastFilePath;
};
#endif // APPSTATE_H
+108
View File
@@ -0,0 +1,108 @@
#include "BookController.h"
#include "ReaderFactory.h"
#include "ReadingModel.h"
#include "BookmarkModel.h"
BookController::BookController(QObject *parent)
: QObject(parent)
{
}
QString BookController::bookTitle() const
{
return m_bookTitle;
}
QString BookController::bookAuthor() const
{
return m_bookAuthor;
}
bool BookController::loading() const
{
return m_loading;
}
QString BookController::errorMessage() const
{
return m_errorMessage;
}
bool BookController::hasBook() const
{
return m_reader != nullptr;
}
QList<TocEntry> BookController::toc() const
{
if (m_reader)
return m_reader->tableOfContents();
return {};
}
void BookController::setReadingModel(ReadingModel *model)
{
m_readingModel = model;
}
void BookController::setBookmarkModel(BookmarkModel *model)
{
m_bookmarkModel = model;
}
void BookController::openBook(const QUrl &fileUrl)
{
QString filePath = fileUrl.toLocalFile();
m_loading = true;
emit loadingChanged();
m_errorMessage.clear();
emit errorMessageChanged();
auto reader = ReaderFactory::create(filePath);
if (!reader) {
m_loading = false;
emit loadingChanged();
m_errorMessage = QStringLiteral("No format readers available");
emit errorMessageChanged();
emit bookError(m_errorMessage);
return;
}
if (!reader->open(filePath)) {
m_loading = false;
emit loadingChanged();
m_errorMessage = reader->lastError();
emit errorMessageChanged();
emit bookError(m_errorMessage);
return;
}
m_reader = std::move(reader);
m_bookTitle = m_reader->title();
m_bookAuthor = m_reader->author();
if (m_readingModel)
m_readingModel->setReader(m_reader.get());
if (m_bookmarkModel)
m_bookmarkModel->setBookId(filePath);
m_loading = false;
emit loadingChanged();
emit bookChanged();
emit bookReady();
}
void BookController::closeBook()
{
m_reader.reset();
m_bookTitle.clear();
m_bookAuthor.clear();
if (m_readingModel)
m_readingModel->setReader(nullptr);
emit bookChanged();
}
+57
View File
@@ -0,0 +1,57 @@
#ifndef BOOKCONTROLLER_H
#define BOOKCONTROLLER_H
#include <QObject>
#include <QString>
#include <QUrl>
#include <QList>
#include <memory>
#include "FormatReader.h"
class ReadingModel;
class BookmarkModel;
class BookController : public QObject {
Q_OBJECT
Q_PROPERTY(QString bookTitle READ bookTitle NOTIFY bookChanged)
Q_PROPERTY(QString bookAuthor READ bookAuthor NOTIFY bookChanged)
Q_PROPERTY(bool loading READ loading NOTIFY loadingChanged)
Q_PROPERTY(QString errorMessage READ errorMessage NOTIFY errorMessageChanged)
Q_PROPERTY(bool hasBook READ hasBook NOTIFY bookChanged)
Q_PROPERTY(QList<TocEntry> toc READ toc NOTIFY bookChanged)
public:
explicit BookController(QObject *parent = nullptr);
QString bookTitle() const;
QString bookAuthor() const;
bool loading() const;
QString errorMessage() const;
bool hasBook() const;
QList<TocEntry> toc() const;
void setReadingModel(ReadingModel *model);
void setBookmarkModel(BookmarkModel *model);
Q_INVOKABLE void openBook(const QUrl &fileUrl);
Q_INVOKABLE void closeBook();
signals:
void bookReady();
void bookError(const QString &error);
void bookChanged();
void loadingChanged();
void errorMessageChanged();
private:
std::unique_ptr<FormatReader> m_reader;
ReadingModel *m_readingModel = nullptr;
BookmarkModel *m_bookmarkModel = nullptr;
QString m_bookTitle;
QString m_bookAuthor;
bool m_loading = false;
QString m_errorMessage;
};
#endif // BOOKCONTROLLER_H
+45
View File
@@ -0,0 +1,45 @@
#include "BookmarkModel.h"
#include "BookmarkStore.h"
BookmarkModel::BookmarkModel(QObject *parent)
: QObject(parent)
{
}
QStringList BookmarkModel::bookmarks() const
{
return m_bookmarks;
}
void BookmarkModel::setBookId(const QString &bookId)
{
m_bookId = bookId;
m_bookmarks.clear();
if (m_store) {
m_bookmarks = m_store->bookmarksForBook(m_bookId);
}
emit bookmarksChanged();
}
void BookmarkModel::setStore(BookmarkStore *store)
{
m_store = store;
}
void BookmarkModel::addBookmark(const QString &bookmark)
{
if (m_store) {
m_store->addBookmark(m_bookId, bookmark);
m_bookmarks = m_store->bookmarksForBook(m_bookId);
emit bookmarksChanged();
}
}
void BookmarkModel::removeBookmark(const QString &bookmark)
{
if (m_store) {
m_store->removeBookmark(m_bookId, bookmark);
m_bookmarks = m_store->bookmarksForBook(m_bookId);
emit bookmarksChanged();
}
}
+33
View File
@@ -0,0 +1,33 @@
#ifndef BOOKMARKMODEL_H
#define BOOKMARKMODEL_H
#include <QObject>
#include <QStringList>
class BookmarkStore;
class BookmarkModel : public QObject {
Q_OBJECT
Q_PROPERTY(QStringList bookmarks READ bookmarks NOTIFY bookmarksChanged)
public:
explicit BookmarkModel(QObject *parent = nullptr);
QStringList bookmarks() const;
void setBookId(const QString &bookId);
void setStore(BookmarkStore *store);
Q_INVOKABLE void addBookmark(const QString &bookmark);
Q_INVOKABLE void removeBookmark(const QString &bookmark);
signals:
void bookmarksChanged();
private:
BookmarkStore *m_store = nullptr;
QString m_bookId;
QStringList m_bookmarks;
};
#endif // BOOKMARKMODEL_H
+24
View File
@@ -0,0 +1,24 @@
#include "BookmarkStore.h"
BookmarkStore::BookmarkStore(QObject *parent)
: QObject(parent)
{
}
QStringList BookmarkStore::bookmarksForBook(const QString &bookId) const
{
Q_UNUSED(bookId)
return {};
}
void BookmarkStore::addBookmark(const QString &bookId, const QString &bookmark)
{
Q_UNUSED(bookId)
Q_UNUSED(bookmark)
}
void BookmarkStore::removeBookmark(const QString &bookId, const QString &bookmark)
{
Q_UNUSED(bookId)
Q_UNUSED(bookmark)
}
+18
View File
@@ -0,0 +1,18 @@
#ifndef BOOKMARKSTORE_H
#define BOOKMARKSTORE_H
#include <QObject>
#include <QStringList>
class BookmarkStore : public QObject {
Q_OBJECT
public:
explicit BookmarkStore(QObject *parent = nullptr);
QStringList bookmarksForBook(const QString &bookId) const;
void addBookmark(const QString &bookId, const QString &bookmark);
void removeBookmark(const QString &bookId, const QString &bookmark);
};
#endif // BOOKMARKSTORE_H
+32
View File
@@ -0,0 +1,32 @@
#ifndef FORMATREADER_H
#define FORMATREADER_H
#include <QString>
#include <QList>
struct TocEntry {
QString title;
int chapterIndex;
int depth; // 0 = top level
};
struct Chapter {
int index;
QString title;
QString contentHtml;
};
class FormatReader {
public:
virtual ~FormatReader() = default;
virtual bool open(const QString &filePath) = 0;
virtual QString lastError() = 0;
virtual int chapterCount() = 0;
virtual Chapter loadChapter(int index) = 0;
virtual QList<TocEntry> tableOfContents() = 0;
virtual QString title() = 0;
virtual QString author() = 0;
};
#endif // FORMATREADER_H
+8
View File
@@ -0,0 +1,8 @@
#include "ReaderFactory.h"
#include "FormatReader.h"
std::unique_ptr<FormatReader> ReaderFactory::create(const QString &filePath)
{
Q_UNUSED(filePath)
return nullptr;
}
+14
View File
@@ -0,0 +1,14 @@
#ifndef READERFACTORY_H
#define READERFACTORY_H
#include <memory>
#include <QString>
class FormatReader;
class ReaderFactory {
public:
static std::unique_ptr<FormatReader> create(const QString &filePath);
};
#endif // READERFACTORY_H
+88
View File
@@ -0,0 +1,88 @@
#include "ReadingModel.h"
#include "FormatReader.h"
ReadingModel::ReadingModel(QObject *parent)
: QObject(parent)
{
}
QString ReadingModel::chapterTitle() const
{
return m_chapterTitle;
}
QString ReadingModel::chapterContent() const
{
return m_chapterContent;
}
int ReadingModel::currentChapter() const
{
return m_currentChapter;
}
int ReadingModel::totalChapters() const
{
return m_totalChapters;
}
double ReadingModel::progress() const
{
if (m_totalChapters == 0)
return 0.0;
return static_cast<double>(m_currentChapter + 1) / m_totalChapters;
}
void ReadingModel::setReader(FormatReader *reader)
{
m_reader = reader;
m_currentChapter = 0;
m_totalChapters = reader ? reader->chapterCount() : 0;
m_chapterTitle.clear();
m_chapterContent.clear();
if (m_reader && m_totalChapters > 0) {
auto chapter = m_reader->loadChapter(0);
m_chapterTitle = chapter.title;
m_chapterContent = chapter.contentHtml;
}
emit totalChaptersChanged();
emit chapterChanged();
}
void ReadingModel::nextChapter()
{
if (!m_reader || m_currentChapter >= m_totalChapters - 1)
return;
m_currentChapter++;
auto chapter = m_reader->loadChapter(m_currentChapter);
m_chapterTitle = chapter.title;
m_chapterContent = chapter.contentHtml;
emit chapterChanged();
}
void ReadingModel::previousChapter()
{
if (!m_reader || m_currentChapter <= 0)
return;
m_currentChapter--;
auto chapter = m_reader->loadChapter(m_currentChapter);
m_chapterTitle = chapter.title;
m_chapterContent = chapter.contentHtml;
emit chapterChanged();
}
void ReadingModel::goToChapter(int index)
{
if (!m_reader || index < 0 || index >= m_totalChapters)
return;
m_currentChapter = index;
auto chapter = m_reader->loadChapter(m_currentChapter);
m_chapterTitle = chapter.title;
m_chapterContent = chapter.contentHtml;
emit chapterChanged();
}
+44
View File
@@ -0,0 +1,44 @@
#ifndef READINGMODEL_H
#define READINGMODEL_H
#include <QObject>
#include <QString>
class FormatReader;
class ReadingModel : public QObject {
Q_OBJECT
Q_PROPERTY(QString chapterTitle READ chapterTitle NOTIFY chapterChanged)
Q_PROPERTY(QString chapterContent READ chapterContent NOTIFY chapterChanged)
Q_PROPERTY(int currentChapter READ currentChapter NOTIFY chapterChanged)
Q_PROPERTY(int totalChapters READ totalChapters NOTIFY totalChaptersChanged)
Q_PROPERTY(double progress READ progress NOTIFY chapterChanged)
public:
explicit ReadingModel(QObject *parent = nullptr);
QString chapterTitle() const;
QString chapterContent() const;
int currentChapter() const;
int totalChapters() const;
double progress() const;
void setReader(FormatReader *reader);
Q_INVOKABLE void nextChapter();
Q_INVOKABLE void previousChapter();
Q_INVOKABLE void goToChapter(int index);
signals:
void chapterChanged();
void totalChaptersChanged();
private:
FormatReader *m_reader = nullptr;
int m_currentChapter = 0;
int m_totalChapters = 0;
QString m_chapterTitle;
QString m_chapterContent;
};
#endif // READINGMODEL_H
+42
View File
@@ -0,0 +1,42 @@
#include <QGuiApplication>
#include <QQmlApplicationEngine>
#include <QQmlContext>
#include "backend/BookController.h"
#include "backend/ReadingModel.h"
#include "backend/BookmarkModel.h"
#include "backend/BookmarkStore.h"
#include "backend/AppState.h"
int main(int argc, char *argv[])
{
QGuiApplication app(argc, argv);
app.setApplicationName(QStringLiteral("Asteria"));
app.setOrganizationName(QStringLiteral("Asteria"));
BookmarkStore bookmarkStore;
ReadingModel readingModel;
BookmarkModel bookmarkModel;
bookmarkModel.setStore(&bookmarkStore);
BookController bookController;
bookController.setReadingModel(&readingModel);
bookController.setBookmarkModel(&bookmarkModel);
AppState appState;
QQmlApplicationEngine engine;
engine.rootContext()->setContextProperty(QStringLiteral("bookController"), &bookController);
engine.rootContext()->setContextProperty(QStringLiteral("readingModel"), &readingModel);
engine.rootContext()->setContextProperty(QStringLiteral("bookmarkModel"), &bookmarkModel);
engine.rootContext()->setContextProperty(QStringLiteral("appState"), &appState);
const QUrl url(QStringLiteral("qrc:/Asteria/Main.qml"));
QObject::connect(&engine, &QQmlApplicationEngine::objectCreationFailed,
&app, []() { QCoreApplication::exit(-1); },
Qt::QueuedConnection);
engine.load(url);
return app.exec();
}
+107
View File
@@ -0,0 +1,107 @@
import QtQuick
import QtQuick.Controls
import QtQuick.Dialogs
import Asteria
ApplicationWindow {
id: window
width: 1024
height: 768
visible: true
title: "Asteria"
color: Theme.backgroundDeepest
FontLoader {
id: materialIcons
source: "qrc:/Asteria/src/assets/MaterialIconsOutlined-Regular.otf"
}
property bool sidebarOpen: false
property string currentPage: "starter"
Row {
anchors.fill: parent
SideBar {
id: sidebar
height: parent.height
sidebarOpen: window.sidebarOpen
onCloseDrawer: window.sidebarOpen = false
onNavigateTo: function(page) {
window.currentPage = page
window.sidebarOpen = false
}
onOpenFile: {
fileDialog.open()
window.sidebarOpen = false
}
}
Column {
width: parent.width - sidebar.width
height: parent.height
Header {
id: header
width: parent.width
sidebarOpen: window.sidebarOpen
currentPage: window.currentPage
onMenuClicked: window.sidebarOpen = true
}
Loader {
id: contentLoader
width: parent.width
height: parent.height - header.height - (footerLoader.active ? Theme.footerHeight : 0)
sourceComponent: {
switch (window.currentPage) {
case "reader": return readerComponent
case "settings": return settingsComponent
default: return starterComponent
}
}
}
Loader {
id: footerLoader
width: parent.width
active: window.currentPage === "reader"
sourceComponent: Footer {}
}
}
}
Component {
id: starterComponent
StarterPage {}
}
Component {
id: readerComponent
ReaderPage {}
}
Component {
id: settingsComponent
SettingsPage {}
}
ErrorPopup {
anchors.fill: parent
z: 3000
}
FileDialog {
id: fileDialog
title: "Open Book"
nameFilters: ["Book files (*.txt *.fb2 *.epub *.pdf *.doc *.rtf *.html *.htm *.docx *.djvu *.odt *.chm)", "All files (*)"]
onAccepted: bookController.openBook(selectedFile)
}
Connections {
target: bookController
function onBookReady() {
window.currentPage = "reader"
}
}
}
+33
View File
@@ -0,0 +1,33 @@
pragma Singleton
import QtQuick
QtObject {
readonly property color backgroundDeepest: "#010620"
readonly property color backgroundDefault: "#01082b"
readonly property color surface: "#191d35"
readonly property color headerBg: "#14172c"
readonly property color footerBg: "#1a1e36"
readonly property color scrollbarTrack: "#131628"
readonly property color scrollbarThumb: "#36486a"
readonly property color primaryAccent: "#3a5688"
readonly property color buttonAccent: "#5785c1"
readonly property color sidebarButtonText: "#98aaf4"
readonly property color readingText: "#c4c8d8"
readonly property color uiText: "#a2a5b4"
readonly property color headerText: "#8488aa"
readonly property color dimText: "#71738c"
readonly property color counterText: "#606175"
readonly property int sidebarWidth: 240
readonly property color gradientTop: "#0e1125"
readonly property color gradientBottom: "#191d35"
readonly property color divider: Qt.rgba(1, 1, 1, 0.12)
readonly property color overlayBg: Qt.rgba(0.055, 0.055, 0.067, 0.4)
readonly property color actionDisabled: "#141724"
readonly property int headerHeight: 64
readonly property int footerHeight: 28
readonly property int animDurationOpen: 225
readonly property int animDurationClose: 195
}
+47
View File
@@ -0,0 +1,47 @@
import QtQuick
import QtQuick.Controls
import Asteria
Rectangle {
id: overlay
color: Theme.overlayBg
visible: bookController.errorMessage !== ""
MouseArea {
anchors.fill: parent
onClicked: {} // Block clicks through overlay
}
Column {
anchors.centerIn: parent
spacing: 20
Text {
anchors.horizontalCenter: parent.horizontalCenter
text: bookController.errorMessage
font.pixelSize: 15
color: Theme.readingText
horizontalAlignment: Text.AlignHCenter
wrapMode: Text.Wrap
width: Math.min(overlay.width * 0.6, 400)
}
Button {
anchors.horizontalCenter: parent.horizontalCenter
text: "Ok"
contentItem: Text {
text: parent.text
font.pixelSize: 14
color: "#ffffff"
horizontalAlignment: Text.AlignHCenter
}
background: Rectangle {
implicitWidth: 80
implicitHeight: 36
radius: 4
color: parent.hovered ? Qt.lighter(Theme.primaryAccent, 1.15) : Theme.primaryAccent
}
onClicked: bookController.errorMessage = ""
}
}
}
+25
View File
@@ -0,0 +1,25 @@
import QtQuick
import Asteria
Rectangle {
height: Theme.footerHeight
color: Theme.footerBg
Rectangle {
width: parent.width
height: 1
color: Theme.divider
anchors.top: parent.top
}
Text {
anchors.verticalCenter: parent.verticalCenter
x: parent.width * 0.5
text: bookController.hasBook
? "Chapter " + (readingModel.currentChapter + 1) + " / " + readingModel.totalChapters
: ""
font.pixelSize: 11
font.bold: true
color: Theme.dimText
}
}
+85
View File
@@ -0,0 +1,85 @@
import QtQuick
import QtQuick.Controls
import Asteria
Rectangle {
id: header
height: Theme.headerHeight
color: Theme.surface
property bool sidebarOpen: false
property string currentPage: "starter"
signal menuClicked()
Button {
id: menuButton
anchors.left: parent.left
anchors.leftMargin: 12
anchors.verticalCenter: parent.verticalCenter
visible: !header.sidebarOpen
flat: true
contentItem: Text {
text: "\u2630"
font.pixelSize: 24
color: Theme.buttonAccent
}
background: Item {}
onClicked: header.menuClicked()
}
Text {
anchors.centerIn: parent
text: {
switch (header.currentPage) {
case "settings": return "Settings"
case "reader": return bookController.bookTitle || ""
default: return ""
}
}
font.pixelSize: 16
color: Theme.headerText
}
Row {
anchors.right: parent.right
anchors.rightMargin: parent.width * 0.02
anchors.verticalCenter: parent.verticalCenter
spacing: 8
Text {
id: clockText
anchors.verticalCenter: parent.verticalCenter
font.pixelSize: 16
font.bold: true
color: Theme.dimText
Timer {
running: true
repeat: true
interval: 1000
triggeredOnStart: true
onTriggered: {
var d = new Date()
var h = d.getHours() % 12
if (h === 0) h = 12
var m = d.getMinutes().toString().padStart(2, '0')
var s = d.getSeconds().toString().padStart(2, '0')
var ampm = d.getHours() >= 12 ? "PM" : "AM"
clockText.text = h + ":" + m + ":" + s + " " + ampm
}
}
}
Text {
anchors.verticalCenter: parent.verticalCenter
font.pixelSize: 12
font.bold: true
color: Theme.counterText
visible: header.currentPage === "reader" && bookController.hasBook
text: bookController.hasBook
? (readingModel.currentChapter + 1) + "/" + readingModel.totalChapters
: ""
}
}
}
+41
View File
@@ -0,0 +1,41 @@
import QtQuick
import QtQuick.Controls
import Asteria
Rectangle {
gradient: Gradient {
GradientStop { position: 0.0; color: Theme.gradientTop }
GradientStop { position: 1.0; color: Theme.gradientBottom }
}
Flickable {
anchors.fill: parent
anchors.margins: 12
contentHeight: contentText.implicitHeight
clip: true
ScrollBar.vertical: ScrollBar {
policy: ScrollBar.AsNeeded
contentItem: Rectangle {
implicitWidth: 18
radius: 3
color: Theme.scrollbarThumb
}
background: Rectangle {
implicitWidth: 18
color: Theme.scrollbarTrack
}
}
Text {
id: contentText
width: parent.width
wrapMode: Text.WrapAtWordBoundaryOrAnywhere
textFormat: Text.RichText
font.pixelSize: 16
lineHeight: 1.6
color: Theme.readingText
text: bookController.hasBook ? readingModel.chapterContent : "Open a book to start reading"
}
}
}
+99
View File
@@ -0,0 +1,99 @@
import QtQuick
import QtQuick.Controls
import Asteria
Rectangle {
id: sidebar
width: sidebarOpen ? Theme.sidebarWidth : 0
clip: true
color: Theme.surface
property bool sidebarOpen: false
signal closeDrawer()
signal navigateTo(string page)
signal openFile()
Behavior on width {
NumberAnimation {
duration: sidebarOpen ? Theme.animDurationOpen : Theme.animDurationClose
easing.type: Easing.OutQuad
}
}
Text {
anchors.left: parent.left
anchors.leftMargin: 16
y: Theme.headerHeight / 2 - height / 2
text: "Asteria"
font.pixelSize: 18
font.bold: true
color: Theme.uiText
}
// Close button aligned with main header row
Button {
anchors.right: parent.right
anchors.rightMargin: 12
y: Theme.headerHeight / 2 - height / 2
z: 1
flat: true
contentItem: Text {
text: "\ue5cb"
font.family: "Material Icons Outlined"
font.pixelSize: 24
color: Theme.sidebarButtonText
}
background: Item {}
onClicked: sidebar.closeDrawer()
}
Column {
y: Theme.headerHeight
width: Theme.sidebarWidth
SideBarButton {
iconText: "\ue86d"
title: "Book"
onClicked: sidebar.navigateTo("reader")
}
SideBarButton {
iconText: "\ue30a"
title: "Files"
onClicked: sidebar.openFile()
}
// Divider
Rectangle {
width: parent.width
height: 1
color: Theme.divider
}
SideBarButton {
iconText: "\ue3a9"
title: "Dark Theme"
onClicked: {} // Non-functional
}
SideBarButton {
iconText: "\ue3a6"
title: "Light Theme"
onClicked: {} // Non-functional
}
// Divider
Rectangle {
width: parent.width
height: 1
color: Theme.divider
}
SideBarButton {
iconText: "\ue8b8"
title: "Settings"
onClicked: sidebar.navigateTo("settings")
}
}
}
+43
View File
@@ -0,0 +1,43 @@
import QtQuick
import QtQuick.Controls
import Asteria
Rectangle {
id: root
height: 48
width: parent ? parent.width : 240
color: mouseArea.containsMouse ? Qt.lighter(Theme.headerBg, 1.3) : "transparent"
property string iconText: ""
property string title: ""
signal clicked()
Row {
anchors.fill: parent
anchors.leftMargin: 16
spacing: 16
Text {
anchors.verticalCenter: parent.verticalCenter
text: root.iconText
font.family: "Material Icons Outlined"
font.pixelSize: 24
color: Theme.sidebarButtonText
}
Text {
anchors.verticalCenter: parent.verticalCenter
text: root.title
font.pixelSize: 14
color: Theme.sidebarButtonText
}
}
MouseArea {
id: mouseArea
anchors.fill: parent
hoverEnabled: true
cursorShape: Qt.PointingHandCursor
onClicked: root.clicked()
}
}
+6
View File
@@ -0,0 +1,6 @@
import QtQuick
import Asteria
PageView {
anchors.fill: parent
}
+9
View File
@@ -0,0 +1,9 @@
import QtQuick
import Asteria
Rectangle {
gradient: Gradient {
GradientStop { position: 0.0; color: Theme.gradientTop }
GradientStop { position: 1.0; color: Theme.gradientBottom }
}
}
+16
View File
@@ -0,0 +1,16 @@
import QtQuick
import Asteria
Rectangle {
gradient: Gradient {
GradientStop { position: 0.0; color: Theme.gradientTop }
GradientStop { position: 1.0; color: Theme.gradientBottom }
}
Image {
anchors.fill: parent
source: "qrc:/Asteria/src/assets/moon1.svg"
fillMode: Image.PreserveAspectCrop
opacity: 0.15
}
}