Greums commited on
Commit
0f33248
·
1 Parent(s): a22b864

removed dist

Browse files
dist/assets/index-BhbZavTP.css DELETED
@@ -1,728 +0,0 @@
1
- @import url("https://fonts.googleapis.com/css2?family=Roboto:ital,wght@0,100..900;1,100..900&display=swap");
2
- /***
3
- The new CSS reset - version 1.11.3 (last updated 25.08.2024)
4
- GitHub page: https://github.com/elad2412/the-new-css-reset
5
- ***/
6
- /*
7
- Remove all the styles of the "User-Agent-Stylesheet", except for the 'display' property
8
- - The "symbol *" part is to solve Firefox SVG sprite bug
9
- - The "html" element is excluded, otherwise a bug in Chrome breaks the CSS hyphens property (https://github.com/elad2412/the-new-css-reset/issues/36)
10
- */
11
- *:where(:not(html, iframe, canvas, img, svg, video, audio):not(svg *, symbol *)) {
12
- all: unset;
13
- display: revert;
14
- }
15
- /* Preferred box-sizing value */
16
- *,
17
- *::before,
18
- *::after {
19
- box-sizing: border-box;
20
- }
21
- /* Fix mobile Safari increase font-size on landscape mode */
22
- html {
23
- -moz-text-size-adjust: none;
24
- -webkit-text-size-adjust: none;
25
- text-size-adjust: none;
26
- }
27
- /* Reapply the pointer cursor for anchor tags */
28
- a, button {
29
- cursor: revert;
30
- }
31
- /* Remove list styles (bullets/numbers) */
32
- ol, ul, menu, summary {
33
- list-style: none;
34
- }
35
- /* Firefox: solve issue where nested ordered lists continue numbering from parent (https://bugzilla.mozilla.org/show_bug.cgi?id=1881517) */
36
- ol {
37
- counter-reset: revert;
38
- }
39
- /* For images to not be able to exceed their container */
40
- img {
41
- max-inline-size: 100%;
42
- max-block-size: 100%;
43
- }
44
- /* removes spacing between cells in tables */
45
- table {
46
- border-collapse: collapse;
47
- }
48
- /* Safari - solving issue when using user-select:none on the <body> text input doesn't working */
49
- input, textarea {
50
- -webkit-user-select: auto;
51
- }
52
- /* revert the 'white-space' property for textarea elements on Safari */
53
- textarea {
54
- white-space: revert;
55
- }
56
- /* minimum style to allow to style meter element */
57
- meter {
58
- -webkit-appearance: revert;
59
- appearance: revert;
60
- }
61
- /* preformatted text - use only for this feature */
62
- :where(pre) {
63
- all: revert;
64
- box-sizing: border-box;
65
- }
66
- /* reset default text opacity of input placeholder */
67
- ::placeholder {
68
- color: unset;
69
- }
70
- /* fix the feature of 'hidden' attribute.
71
- display:revert; revert to element instead of attribute */
72
- :where([hidden]) {
73
- display: none;
74
- }
75
- /* revert for bug in Chromium browsers
76
- - fix for the content editable attribute will work properly.
77
- - webkit-user-select: auto; added for Safari in case of using user-select:none on wrapper element*/
78
- :where([contenteditable]:not([contenteditable=false])) {
79
- -moz-user-modify: read-write;
80
- -webkit-user-modify: read-write;
81
- overflow-wrap: break-word;
82
- -webkit-line-break: after-white-space;
83
- -webkit-user-select: auto;
84
- }
85
- /* apply back the draggable feature - exist only in Chromium and Safari */
86
- :where([draggable=true]) {
87
- -webkit-user-drag: element;
88
- }
89
- /* Revert Modal native behavior */
90
- :where(dialog:modal) {
91
- all: revert;
92
- box-sizing: border-box;
93
- }
94
- /* Remove details summary webkit styles */
95
- ::-webkit-details-marker {
96
- display: none;
97
- }
98
- :root {
99
- color-scheme: dark;
100
- --body-bg: #22252a;
101
- --text-primary: #3d87f5;
102
- --text-hover-primary: #5596f6;
103
- --text-secondary: #f66031;
104
- --text-hover-secondary: #f7734a;
105
- --text-danger: #e4606d;
106
- --text-hover-danger: #dc3545;
107
- --text-dark: #e0e0e0;
108
- --text-hover-dark: #fff;
109
- --text-light: #000;
110
- --bg-color-light: #272a30;
111
- --bg-color-light-transparent: rgba(39, 42, 48, 0);
112
- --bg-color: #22252a;
113
- --text-color: #f2f2f2;
114
- --border-color: #4a4c4f;
115
- --border-even-color: #454f5e;
116
- --border-highlighted-color: #765d3f;
117
- --block-bg-color: #2e3238;
118
- --block-even-bg-color: #363e49;
119
- --block-highlighted-bg-color: #594126;
120
- --block-bg-color-hover: #353941;
121
- --block-bg-color-hover-dark: #454b54;
122
- --text-muted-color: #9e9e9e;
123
- --text-muted-hover-color: #bababa;
124
- --text-blockquote-color: #c7c7d1;
125
- --link-color: #7dc3f7;
126
- --link-hover-bg-color: #4c5767;
127
- --header-bg-color: #18191b;
128
- --header-bottom-bg-color: #000;
129
- --header-bottom-bg-color-hover: #303236;
130
- --video-footer-bg-color: #1d1e20;
131
- --layout-bg-color: #292d32;
132
- --disabled-bg-color: #1d1e20;
133
- --disabled-text-color: #787e87;
134
- --disabled-border-color: #787e87;
135
- --ad-bg-color: #18191b;
136
- --ad-border-color: #000;
137
- --game-header-bg-color: #2c2f35;
138
- --bg-light: #2c2f35;
139
- --game-tab-hover-bg-color: #17191c;
140
- --price-color: #9fafc6;
141
- --blue-light: #414a58;
142
- --live-color: #ff4d4d;
143
- --live-hover-color: #ff1a1a;
144
- --gauge-bg-color: #616161;
145
- --blue-gray-color: #9fafc6;
146
- --message-delete: #104e60;
147
- --message-delete-border: #092a34;
148
- --message-delete-gta: #46435b;
149
- --message-delete-gta-border: #191820;
150
- --input-bg-color: #303236;
151
- --input-border-color: #636569;
152
- --input-text-color: #f2f2f2;
153
- --input-placeholder-color: #616161;
154
- --form-select-indicator: url("data:image/svg+xml,%3csvg xmlns=%27http://www.w3.org/2000/svg%27 viewBox=%270 0 16 16%27%3e%3cpath stroke=%27%23e0e0e0%27 stroke-width=%272px%27 d=%27M2 5l6 6 6-6%27 fill=%27none%27 stroke-linecap=%27round%27 stroke-linejoin=%27round%27/%3e%3c/svg%3e");
155
- --form-switch-bg-image: url("data:image/svg+xml,<svg xmlns=%27http://www.w3.org/2000/svg%27 viewBox=%27-4 -4 8 8%27><circle r=%273%27 fill=%27%23636569%27/></svg>");
156
- --admin-color: #f24444;
157
- --modo-color: #42b228;
158
- --ad-placeholder-opacity: 0.4;
159
- --alert-brightness: 0.85;
160
- --filters-bg-color: #16191d;
161
- --gray-100: #f8f9fa;
162
- --gray-200: #e9ecef;
163
- --gray-300: #dee2e6;
164
- --gray-400: #ced4da;
165
- --gray-500: #adb5bd;
166
- --gray-600: #6c757d;
167
- --gray-700: #495057;
168
- --gray-800: #343a40;
169
- --gray-900: #212529;
170
- --white-rgb: #fff;
171
- --black-rgb: #000;
172
- --body-color-rgb: var(--text-color);
173
- --body-bg-rgb: var(--body-bg);
174
- --font-sans-serif: "Roboto", Arial, Helvetica, sans-serif;
175
- --font-monospace: SFMono-Regular, Menlo, Monaco, Consolas, "Liberation Mono", "Courier New", monospace;
176
- --gradient: linear-gradient(180deg, rgba(255, 255, 255, 0.15), rgba(255, 255, 255, 0));
177
- --root-font-size: 1rem;
178
- --body-font-family: "Roboto", Arial, Helvetica, sans-serif;
179
- --body-font-size: 0.9375rem;
180
- --body-font-weight: 400;
181
- --body-line-height: 1.5;
182
- --body-color: var(--text-color);
183
- --border-width: 0.0625rem;
184
- --border-style: solid;
185
- --border-color-translucent: rgba(0, 0, 0, 0.175);
186
- --border-radius: 0.75rem;
187
- --border-radius-sm: 0.5rem;
188
- --border-radius-lg: 0.75rem;
189
- --border-radius-xl: 1rem;
190
- --border-radius-2xl: 2rem;
191
- --border-radius-pill: 50rem;
192
- --link-hover-color: var(--text-hover-secondary);
193
- --code-color: #d63384;
194
- --highlight-bg: #fff3cd;
195
- --topic-font-size: 0.8125rem;
196
- --topic-font-weight: 700;
197
- --topic-line-height: 1.25;
198
- --topic-gap: 0.625rem;
199
- --topic-title-font-size: 0.9375rem;
200
- --topic-title-font-weight: 500;
201
- }
202
- body {
203
- margin: 0;
204
- font-family: var(--body-font-family), sans-serif;
205
- font-size: var(--body-font-size);
206
- font-weight: var(--body-font-weight);
207
- line-height: var(--body-line-height);
208
- color: var(--body-color);
209
- text-align: var(--body-text-align);
210
- background-color: var(--body-bg);
211
- -webkit-text-size-adjust: 100%;
212
- -webkit-tap-highlight-color: rgba(0, 0, 0, 0);
213
- }
214
- hr {
215
- height: 1px;
216
- width: 100%;
217
- background-color: var(--border-color);
218
- display: block;
219
- margin: 1.5rem 0;
220
- }
221
- h2 {
222
- font-size: 1.59375rem;
223
- line-height: 1.25;
224
- font-weight: 500;
225
- color: var(--text-color);
226
- padding-bottom: 1.5rem;
227
- }._header_1hnaa_1 {
228
- background-color: var(--header-bg-color);
229
- color: var(--text-color);
230
- }
231
-
232
- ._logo_1hnaa_6 {
233
- font-size: 2rem;
234
- font-weight: 700;
235
- }._container_1putz_1 {
236
- margin: 0 auto;
237
- min-width: 20rem;
238
- max-width: 73.5rem;
239
- padding: 0 0.5rem;
240
- }._spinnerSquare_4vgl0_1 {
241
- display: flex;
242
- flex-direction: row;
243
- width: 90px;
244
- height: 120px;
245
- }
246
- ._spinnerSquare_4vgl0_1 > div {
247
- width: 17px;
248
- height: 80px;
249
- margin: auto auto;
250
- border-radius: 4px;
251
- }
252
-
253
- ._square1_4vgl0_14 {
254
- animation: _square-anim_4vgl0_1 1200ms cubic-bezier(0.445, 0.05, 0.55, 0.95) 0s infinite;
255
- }
256
-
257
- ._square2_4vgl0_18 {
258
- animation: _square-anim_4vgl0_1 1200ms cubic-bezier(0.445, 0.05, 0.55, 0.95) 200ms infinite;
259
- }
260
-
261
- ._square3_4vgl0_22 {
262
- animation: _square-anim_4vgl0_1 1200ms cubic-bezier(0.445, 0.05, 0.55, 0.95) 400ms infinite;
263
- }
264
-
265
- @keyframes _square-anim_4vgl0_1 {
266
- 0% {
267
- height: 80px;
268
- background-color: var(--text-secondary);
269
- }
270
- 20% {
271
- height: 80px;
272
- }
273
- 40% {
274
- height: 120px;
275
- background-color: var(--text-hover-secondary);
276
- }
277
- 80% {
278
- height: 80px;
279
- }
280
- 100% {
281
- height: 80px;
282
- background-color: var(--text-secondary);
283
- }
284
- }._spinner_1pqws_1 {
285
- margin: 5rem auto;
286
- }
287
-
288
- ._list_1pqws_5 {
289
- display: grid;
290
- grid-template-columns: 10fr 3fr 1fr 3fr;
291
- list-style-type: none;
292
- background: var(--block-bg-color);
293
- border: 0.0625rem solid var(--border-color);
294
- border-radius: 0.75rem;
295
- width: 100%;
296
- padding: 0;
297
- overflow: hidden;
298
- margin-bottom: 1.5rem;
299
- }
300
- ._list_1pqws_5 > li {
301
- display: contents;
302
- list-style: none;
303
- padding: 0;
304
- margin: 0;
305
- }
306
- ._list_1pqws_5 > li > span {
307
- font-weight: var(--topic-font-weight);
308
- font-size: var(--topic-font-size);
309
- padding: var(--topic-gap);
310
- }
311
- ._list_1pqws_5 > li > span a {
312
- overflow: hidden;
313
- display: -webkit-box;
314
- -webkit-line-clamp: var(--topic-title-lines);
315
- -webkit-box-orient: vertical;
316
- color: var(--link-color);
317
- text-decoration: none;
318
- font-size: var(--topic-title-font-size);
319
- font-weight: var(--topic-title-font-weight);
320
- }
321
- ._list_1pqws_5 > li > span a:hover {
322
- color: var(--text-hover-secondary);
323
- }
324
- ._list_1pqws_5 > li:nth-child(even) > span {
325
- background: var(--block-even-bg-color);
326
- }
327
- ._list_1pqws_5 > li._highlight_1pqws_44 > span {
328
- background: var(--block-highlighted-bg-color);
329
- }
330
-
331
- ._head_1pqws_48 > span {
332
- text-transform: uppercase;
333
- }
334
-
335
- ._generationSettings_1pqws_52 {
336
- display: grid;
337
- grid-template-columns: 1fr 1fr;
338
- }._btn_1ts7o_1 {
339
- position: relative;
340
- display: inline-flex;
341
- justify-content: center;
342
- align-items: center;
343
- padding: 0 1.25rem;
344
- margin: 0;
345
- border: 0.0625rem solid var(--text-secondary);
346
- height: 2.25rem;
347
- line-height: 2.25rem;
348
- font-size: 0.9375rem;
349
- text-decoration: none;
350
- color: var(--text-secondary);
351
- border-radius: 1.125rem;
352
- white-space: nowrap;
353
- cursor: pointer;
354
- }
355
- ._btn_1ts7o_1:not(._disabled_1ts7o_18):hover {
356
- border-color: var(--text-hover-secondary);
357
- color: var(--text-hover-secondary);
358
- }
359
- ._btn_1ts7o_1._secondary_1ts7o_22 {
360
- color: #fff;
361
- background-color: var(--text-secondary);
362
- }
363
- ._btn_1ts7o_1._secondary_1ts7o_22:not(._disabled_1ts7o_18):hover {
364
- border-color: var(--text-hover-secondary);
365
- background: var(--text-hover-secondary);
366
- color: #fff;
367
- }
368
-
369
- ._spinner_1ts7o_32 {
370
- font-size: 10px;
371
- margin-right: 1em;
372
- width: 1.5em;
373
- height: 1.5em;
374
- border-radius: 50%;
375
- background: #ffffff;
376
- background: linear-gradient(to right, #ffffff 10%, rgba(255, 255, 255, 0) 42%);
377
- position: relative;
378
- animation: _load3_1ts7o_1 1.4s infinite linear;
379
- transform: translateZ(0);
380
- }
381
- ._spinner_1ts7o_32:before {
382
- width: 50%;
383
- height: 50%;
384
- background: #ffffff;
385
- border-radius: 100% 0 0 0;
386
- position: absolute;
387
- top: 0;
388
- left: 0;
389
- content: "";
390
- }
391
- ._spinner_1ts7o_32:after {
392
- background: var(--text-secondary);
393
- width: 75%;
394
- height: 75%;
395
- border-radius: 50%;
396
- content: "";
397
- margin: auto;
398
- position: absolute;
399
- top: 0;
400
- left: 0;
401
- bottom: 0;
402
- right: 0;
403
- }
404
-
405
- @keyframes _load3_1ts7o_1 {
406
- 0% {
407
- transform: rotate(0deg);
408
- }
409
- 100% {
410
- transform: rotate(360deg);
411
- }
412
- }
413
- ._disabled_1ts7o_18 {
414
- cursor: not-allowed;
415
- }
416
- ._disabled_1ts7o_18:after {
417
- content: "";
418
- position: absolute;
419
- width: 100%;
420
- height: 100%;
421
- background: #4f4f4f;
422
- border: 0.0625rem solid #4f4f4f;
423
- border-radius: 1.125rem;
424
- opacity: 0.5;
425
- box-sizing: content-box;
426
- }._formGroup_b3g81_1 {
427
- display: flex;
428
- flex-direction: column;
429
- margin-bottom: 1rem;
430
- justify-content: space-between;
431
- }
432
- ._formGroup_b3g81_1 > * {
433
- flex-grow: 0;
434
- }
435
- ._formGroup_b3g81_1 label {
436
- font-size: 1rem;
437
- margin-bottom: 1rem;
438
- }._slider_1hlzr_1 {
439
- --ticks-count: calc(var(--max) - var(--min)) / var(--step);
440
- --too-many-ticks: min(1, Max(var(--ticks-count) - 30, 0));
441
- --x-step: max(var(--step), var(--too-many-ticks) * (var(--max) - var(--min)));
442
- position: relative;
443
- background: linear-gradient(to right, var(--text-muted-color) 1px, transparent 1px) repeat-x;
444
- background-size: calc((100% - 20px) / ((var(--max) - var(--min)) / var(--x-step))) 5px;
445
- background-position-x: calc(10px - 0.5px);
446
- background-position-y: bottom;
447
- font-weight: 700;
448
- color: var(--text-muted-color);
449
- font-size: 0.8125rem;
450
- height: 22px;
451
- margin-top: 2.5ch;
452
- margin-bottom: 2.5ch;
453
- }
454
- ._slider_1hlzr_1::before, ._slider_1hlzr_1::after {
455
- content: counter(x);
456
- position: absolute;
457
- bottom: calc(-2.5ch - 2px);
458
- top: calc(2.5ch + 2px);
459
- opacity: 0.5;
460
- transform: translateX(calc(50% * var(--before, -1) * -1));
461
- pointer-events: none;
462
- }
463
- ._slider_1hlzr_1::before {
464
- --before: 1;
465
- counter-reset: x var(--min);
466
- left: 10px;
467
- }
468
- ._slider_1hlzr_1::after {
469
- counter-reset: x var(--max);
470
- right: 10px;
471
- }
472
-
473
- ._outputContainer_1hlzr_36 {
474
- position: absolute;
475
- top: 0;
476
- left: 10px;
477
- right: 10px;
478
- height: 10px;
479
- pointer-events: none;
480
- }
481
-
482
- ._output_1hlzr_36 {
483
- pointer-events: none;
484
- position: absolute;
485
- z-index: 5;
486
- width: 20px;
487
- height: 20px;
488
- left: calc((var(--value) - var(--min)) / (var(--max) - var(--min)) * 100% - 10px);
489
- bottom: 16px;
490
- text-align: center;
491
- }
492
-
493
- ._progress_1hlzr_56 {
494
- --completed-a: calc((clamp(var(--min), var(--value, 0), var(--max)) - var(--min)) / (var(--max) - var(--min)) * 100);
495
- --completed-b: calc((var(--value) - var(--min)) / (var(--max) - var(--min)) * 100);
496
- --cb: max(var(--completed-a), var(--completed-b));
497
- --start-end: 10px;
498
- --clip-end: calc(100% - (var(--cb)) * 1%);
499
- --clip: inset(-20px var(--clip-end) -20px 0);
500
- position: absolute;
501
- width: 100%;
502
- height: 10px;
503
- background: var(--text-color);
504
- border-radius: 10px;
505
- z-index: -1;
506
- }
507
- ._progress_1hlzr_56::before {
508
- content: "";
509
- position: absolute;
510
- left: 0;
511
- right: 0;
512
- clip-path: var(--clip);
513
- top: 0;
514
- bottom: 0;
515
- background: var(--text-secondary);
516
- z-index: 1;
517
- border-radius: inherit;
518
- }
519
-
520
- ._input_1hlzr_83 {
521
- --thumb-shadow: 0 0 3px rgba(0, 0, 0, 0.4), 0 0 1px rgba(0, 0, 0, 0.5) inset, 0 0 0 99px var(--text-color) inset;
522
- -webkit-appearance: none;
523
- width: 100%;
524
- height: 20px;
525
- margin: 0;
526
- position: absolute;
527
- left: 0;
528
- cursor: grab;
529
- outline: none;
530
- background: none;
531
- }
532
- ._input_1hlzr_83::-webkit-slider-thumb {
533
- appearance: none;
534
- height: 20px;
535
- width: 20px;
536
- transform: translateY(-5px);
537
- border-radius: 50%;
538
- background: var(--text-color);
539
- box-shadow: var(--thumb-shadow);
540
- border: none;
541
- pointer-events: auto;
542
- }
543
- ._input_1hlzr_83::-moz-range-thumb {
544
- appearance: none;
545
- height: 20px;
546
- width: 20px;
547
- transform: translateY(-5px);
548
- border-radius: 50%;
549
- background: var(--text-color);
550
- box-shadow: var(--thumb-shadow);
551
- border: none;
552
- pointer-events: auto;
553
- }
554
- ._input_1hlzr_83::-ms-thumb {
555
- appearance: none;
556
- height: 20px;
557
- width: 20px;
558
- transform: translateY(-5px);
559
- border-radius: 50%;
560
- background: var(--text-color);
561
- box-shadow: var(--thumb-shadow);
562
- border: none;
563
- pointer-events: auto;
564
- }
565
- ._input_1hlzr_83:active {
566
- --thumb-shadow: 0 0 0 5px inset var(--text-color), 0 0 0 99px var(--text-secondary) inset, 0 0 3px rgba(0, 0, 0, 0.4);
567
- cursor: grabbing;
568
- }._post_uuidr_1 {
569
- margin-bottom: 0.9375rem;
570
- font-size: 0.9375rem;
571
- line-height: 1.5;
572
- background: var(--block-bg-color);
573
- border: 0.0625rem solid var(--border-color);
574
- border-radius: 0.5rem;
575
- overflow: hidden;
576
- padding: 0.75rem;
577
- }
578
-
579
- ._postHeader_uuidr_12 {
580
- border-bottom: 0.0625rem dotted var(--border-color);
581
- height: 3.625rem;
582
- margin-bottom: 0.75rem;
583
- display: grid;
584
- grid-template-areas: "avatar user" "avatar date";
585
- grid-template-rows: 1.5rem 1.5rem;
586
- grid-template-columns: auto 1fr;
587
- column-gap: 0.625rem;
588
- }
589
-
590
- ._avatar_uuidr_23 {
591
- grid-area: avatar;
592
- height: 3rem;
593
- width: 3rem;
594
- object-fit: cover;
595
- border-radius: 50%;
596
- }
597
-
598
- ._user_uuidr_31 {
599
- grid-area: user;
600
- font-size: 1.0625rem;
601
- font-weight: 500;
602
- font-family: "Roboto", Arial, Helvetica, sans-serif;
603
- line-height: 1.25;
604
- }
605
-
606
- ._date_uuidr_39 {
607
- grid-area: date;
608
- color: var(--link-color);
609
- text-decoration: none;
610
- font-size: 0.8125rem;
611
- }
612
-
613
- ._generationSettings_uuidr_46 {
614
- display: grid;
615
- grid-template-columns: 1fr 1fr;
616
- }._wrapper_cfqzy_1 .bloc-spoil-jv {
617
- margin-bottom: 0;
618
- display: inline;
619
- }
620
- ._wrapper_cfqzy_1 .bloc-spoil-jv .open-spoil {
621
- position: absolute;
622
- left: -999rem;
623
- }
624
- ._wrapper_cfqzy_1 .bloc-spoil-jv .barre-head {
625
- height: auto;
626
- line-height: inherit;
627
- text-align: center;
628
- cursor: pointer;
629
- position: relative;
630
- display: inline;
631
- }
632
- ._wrapper_cfqzy_1 .bloc-spoil-jv .barre-head .txt-spoil {
633
- position: static;
634
- display: inline;
635
- padding: 0.125rem 1.25rem;
636
- line-height: inherit;
637
- top: 0;
638
- left: 0;
639
- width: 4.6875rem;
640
- font-size: 0.9285em;
641
- text-align: center;
642
- color: #fff;
643
- text-transform: uppercase;
644
- background: #fd374e;
645
- font-weight: 700;
646
- border-radius: 0.25rem;
647
- }
648
- ._wrapper_cfqzy_1 .bloc-spoil-jv .contenu-spoil {
649
- background: #f4d6da;
650
- color: #212121;
651
- padding: 0.625rem;
652
- display: none;
653
- text-align: left;
654
- overflow: hidden;
655
- }
656
- ._wrapper_cfqzy_1 .bloc-spoil-jv .open-spoil:checked ~ .contenu-spoil {
657
- display: inline;
658
- }
659
- ._wrapper_cfqzy_1 blockquote {
660
- text-align: left;
661
- border-left: 0.3125rem solid rgba(0, 0, 0, 0.2);
662
- color: var(--text-blockquote-color);
663
- padding: 0.625rem;
664
- background: none;
665
- font-style: normal;
666
- font-size: inherit;
667
- margin: 0 0 0.9375rem 1rem;
668
- }
669
- ._wrapper_cfqzy_1 a {
670
- color: var(--link-color);
671
- text-decoration: none;
672
- }
673
- ._wrapper_cfqzy_1 a:hover {
674
- color: var(--text-hover-secondary);
675
- text-decoration: none;
676
- }._wrapper_1dmrl_1 {
677
- position: relative;
678
- margin-bottom: 0.9375rem;
679
- }
680
-
681
- ._icon_1dmrl_6 {
682
- position: absolute;
683
- top: 0.625rem;
684
- left: 0.625rem;
685
- font-size: 1.125rem;
686
- line-height: 1em;
687
- }
688
-
689
- ._input_1dmrl_14 {
690
- display: block;
691
- width: 100%;
692
- font-weight: 400;
693
- line-height: 1.5;
694
- color: var(--input-text-color);
695
- background-color: var(--input-bg-color);
696
- background-clip: padding-box;
697
- border: 0.0625rem solid var(--input-border-color);
698
- -webkit-appearance: none;
699
- appearance: none;
700
- border-radius: 0.75rem;
701
- box-shadow: inset 0 0.0625rem 0.125rem rgba(0, 0, 0, 0.075);
702
- transition: border-color 0.15s ease-in-out, box-shadow 0.15s ease-in-out;
703
- padding-top: 0;
704
- padding-right: 0.3125rem;
705
- padding-left: 2.5rem;
706
- padding-bottom: 0;
707
- font-weight: 700;
708
- height: 2.5rem;
709
- font-size: 1rem;
710
- }
711
- ._input_1dmrl_14::placeholder {
712
- color: var(--input-placeholder-color);
713
- font-weight: 400;
714
- }._breadcrumbs_145yl_1 {
715
- font-weight: 700;
716
- color: var(--text-muted-color);
717
- font-size: 0.8125rem;
718
- margin-top: 1.25rem;
719
- margin-bottom: 0.9375rem;
720
- display: flex;
721
- }
722
-
723
- ._actions_145yl_10 {
724
- margin-left: auto;
725
- }
726
- ._actions_145yl_10 a:hover {
727
- color: var(--text-muted-hover-color);
728
- }
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
dist/assets/index-NR4DZ1UN.js DELETED
@@ -1,1431 +0,0 @@
1
- (function polyfill() {
2
- const relList = document.createElement("link").relList;
3
- if (relList && relList.supports && relList.supports("modulepreload")) {
4
- return;
5
- }
6
- for (const link of document.querySelectorAll('link[rel="modulepreload"]')) {
7
- processPreload(link);
8
- }
9
- new MutationObserver((mutations) => {
10
- for (const mutation of mutations) {
11
- if (mutation.type !== "childList") {
12
- continue;
13
- }
14
- for (const node of mutation.addedNodes) {
15
- if (node.tagName === "LINK" && node.rel === "modulepreload")
16
- processPreload(node);
17
- }
18
- }
19
- }).observe(document, { childList: true, subtree: true });
20
- function getFetchOpts(link) {
21
- const fetchOpts = {};
22
- if (link.integrity) fetchOpts.integrity = link.integrity;
23
- if (link.referrerPolicy) fetchOpts.referrerPolicy = link.referrerPolicy;
24
- if (link.crossOrigin === "use-credentials")
25
- fetchOpts.credentials = "include";
26
- else if (link.crossOrigin === "anonymous") fetchOpts.credentials = "omit";
27
- else fetchOpts.credentials = "same-origin";
28
- return fetchOpts;
29
- }
30
- function processPreload(link) {
31
- if (link.ep)
32
- return;
33
- link.ep = true;
34
- const fetchOpts = getFetchOpts(link);
35
- fetch(link.href, fetchOpts);
36
- }
37
- })();
38
- var n, l$1, u$2, i$1, r$1, o$1, e$1, f$2, c$1, s$1, a$1, p$1 = {}, v$1 = [], y$1 = /acit|ex(?:s|g|n|p|$)|rph|grid|ows|mnc|ntw|ine[ch]|zoo|^ord|itera/i, d$1 = Array.isArray;
39
- function w$1(n2, l2) {
40
- for (var u2 in l2) n2[u2] = l2[u2];
41
- return n2;
42
- }
43
- function _(n2) {
44
- n2 && n2.parentNode && n2.parentNode.removeChild(n2);
45
- }
46
- function g(l2, u2, t2) {
47
- var i2, r2, o2, e2 = {};
48
- for (o2 in u2) "key" == o2 ? i2 = u2[o2] : "ref" == o2 ? r2 = u2[o2] : e2[o2] = u2[o2];
49
- if (arguments.length > 2 && (e2.children = arguments.length > 3 ? n.call(arguments, 2) : t2), "function" == typeof l2 && null != l2.defaultProps) for (o2 in l2.defaultProps) void 0 === e2[o2] && (e2[o2] = l2.defaultProps[o2]);
50
- return m$1(l2, e2, i2, r2, null);
51
- }
52
- function m$1(n2, t2, i2, r2, o2) {
53
- var e2 = { type: n2, props: t2, key: i2, ref: r2, __k: null, __: null, __b: 0, __e: null, __c: null, constructor: void 0, __v: null == o2 ? ++u$2 : o2, __i: -1, __u: 0 };
54
- return null == o2 && null != l$1.vnode && l$1.vnode(e2), e2;
55
- }
56
- function k$1(n2) {
57
- return n2.children;
58
- }
59
- function x(n2, l2) {
60
- this.props = n2, this.context = l2;
61
- }
62
- function C$1(n2, l2) {
63
- if (null == l2) return n2.__ ? C$1(n2.__, n2.__i + 1) : null;
64
- for (var u2; l2 < n2.__k.length; l2++) if (null != (u2 = n2.__k[l2]) && null != u2.__e) return u2.__e;
65
- return "function" == typeof n2.type ? C$1(n2) : null;
66
- }
67
- function S(n2) {
68
- var l2, u2;
69
- if (null != (n2 = n2.__) && null != n2.__c) {
70
- for (n2.__e = n2.__c.base = null, l2 = 0; l2 < n2.__k.length; l2++) if (null != (u2 = n2.__k[l2]) && null != u2.__e) {
71
- n2.__e = n2.__c.base = u2.__e;
72
- break;
73
- }
74
- return S(n2);
75
- }
76
- }
77
- function M(n2) {
78
- (!n2.__d && (n2.__d = true) && i$1.push(n2) && !P.__r++ || r$1 !== l$1.debounceRendering) && ((r$1 = l$1.debounceRendering) || o$1)(P);
79
- }
80
- function P() {
81
- var n2, u2, t2, r2, o2, f2, c2, s2;
82
- for (i$1.sort(e$1); n2 = i$1.shift(); ) n2.__d && (u2 = i$1.length, r2 = void 0, f2 = (o2 = (t2 = n2).__v).__e, c2 = [], s2 = [], t2.__P && ((r2 = w$1({}, o2)).__v = o2.__v + 1, l$1.vnode && l$1.vnode(r2), j$1(t2.__P, r2, o2, t2.__n, t2.__P.namespaceURI, 32 & o2.__u ? [f2] : null, c2, null == f2 ? C$1(o2) : f2, !!(32 & o2.__u), s2), r2.__v = o2.__v, r2.__.__k[r2.__i] = r2, z$1(c2, r2, s2), r2.__e != f2 && S(r2)), i$1.length > u2 && i$1.sort(e$1));
83
- P.__r = 0;
84
- }
85
- function $(n2, l2, u2, t2, i2, r2, o2, e2, f2, c2, s2) {
86
- var a2, h2, y2, d2, w2, _2, g2 = t2 && t2.__k || v$1, m2 = l2.length;
87
- for (f2 = I(u2, l2, g2, f2, m2), a2 = 0; a2 < m2; a2++) null != (y2 = u2.__k[a2]) && (h2 = -1 === y2.__i ? p$1 : g2[y2.__i] || p$1, y2.__i = a2, _2 = j$1(n2, y2, h2, i2, r2, o2, e2, f2, c2, s2), d2 = y2.__e, y2.ref && h2.ref != y2.ref && (h2.ref && V(h2.ref, null, y2), s2.push(y2.ref, y2.__c || d2, y2)), null == w2 && null != d2 && (w2 = d2), 4 & y2.__u || h2.__k === y2.__k ? f2 = A(y2, f2, n2) : "function" == typeof y2.type && void 0 !== _2 ? f2 = _2 : d2 && (f2 = d2.nextSibling), y2.__u &= -7);
88
- return u2.__e = w2, f2;
89
- }
90
- function I(n2, l2, u2, t2, i2) {
91
- var r2, o2, e2, f2, c2, s2 = u2.length, a2 = s2, h2 = 0;
92
- for (n2.__k = new Array(i2), r2 = 0; r2 < i2; r2++) null != (o2 = l2[r2]) && "boolean" != typeof o2 && "function" != typeof o2 ? (f2 = r2 + h2, (o2 = n2.__k[r2] = "string" == typeof o2 || "number" == typeof o2 || "bigint" == typeof o2 || o2.constructor == String ? m$1(null, o2, null, null, null) : d$1(o2) ? m$1(k$1, { children: o2 }, null, null, null) : void 0 === o2.constructor && o2.__b > 0 ? m$1(o2.type, o2.props, o2.key, o2.ref ? o2.ref : null, o2.__v) : o2).__ = n2, o2.__b = n2.__b + 1, e2 = null, -1 !== (c2 = o2.__i = L(o2, u2, f2, a2)) && (a2--, (e2 = u2[c2]) && (e2.__u |= 2)), null == e2 || null === e2.__v ? (-1 == c2 && h2--, "function" != typeof o2.type && (o2.__u |= 4)) : c2 != f2 && (c2 == f2 - 1 ? h2-- : c2 == f2 + 1 ? h2++ : (c2 > f2 ? h2-- : h2++, o2.__u |= 4))) : n2.__k[r2] = null;
93
- if (a2) for (r2 = 0; r2 < s2; r2++) null != (e2 = u2[r2]) && 0 == (2 & e2.__u) && (e2.__e == t2 && (t2 = C$1(e2)), q$1(e2, e2));
94
- return t2;
95
- }
96
- function A(n2, l2, u2) {
97
- var t2, i2;
98
- if ("function" == typeof n2.type) {
99
- for (t2 = n2.__k, i2 = 0; t2 && i2 < t2.length; i2++) t2[i2] && (t2[i2].__ = n2, l2 = A(t2[i2], l2, u2));
100
- return l2;
101
- }
102
- n2.__e != l2 && (l2 && n2.type && !u2.contains(l2) && (l2 = C$1(n2)), u2.insertBefore(n2.__e, l2 || null), l2 = n2.__e);
103
- do {
104
- l2 = l2 && l2.nextSibling;
105
- } while (null != l2 && 8 == l2.nodeType);
106
- return l2;
107
- }
108
- function L(n2, l2, u2, t2) {
109
- var i2, r2, o2 = n2.key, e2 = n2.type, f2 = l2[u2];
110
- if (null === f2 || f2 && o2 == f2.key && e2 === f2.type && 0 == (2 & f2.__u)) return u2;
111
- if (t2 > (null != f2 && 0 == (2 & f2.__u) ? 1 : 0)) for (i2 = u2 - 1, r2 = u2 + 1; i2 >= 0 || r2 < l2.length; ) {
112
- if (i2 >= 0) {
113
- if ((f2 = l2[i2]) && 0 == (2 & f2.__u) && o2 == f2.key && e2 === f2.type) return i2;
114
- i2--;
115
- }
116
- if (r2 < l2.length) {
117
- if ((f2 = l2[r2]) && 0 == (2 & f2.__u) && o2 == f2.key && e2 === f2.type) return r2;
118
- r2++;
119
- }
120
- }
121
- return -1;
122
- }
123
- function T$1(n2, l2, u2) {
124
- "-" == l2[0] ? n2.setProperty(l2, null == u2 ? "" : u2) : n2[l2] = null == u2 ? "" : "number" != typeof u2 || y$1.test(l2) ? u2 : u2 + "px";
125
- }
126
- function F(n2, l2, u2, t2, i2) {
127
- var r2;
128
- n: if ("style" == l2) if ("string" == typeof u2) n2.style.cssText = u2;
129
- else {
130
- if ("string" == typeof t2 && (n2.style.cssText = t2 = ""), t2) for (l2 in t2) u2 && l2 in u2 || T$1(n2.style, l2, "");
131
- if (u2) for (l2 in u2) t2 && u2[l2] === t2[l2] || T$1(n2.style, l2, u2[l2]);
132
- }
133
- else if ("o" == l2[0] && "n" == l2[1]) r2 = l2 != (l2 = l2.replace(f$2, "$1")), l2 = l2.toLowerCase() in n2 || "onFocusOut" == l2 || "onFocusIn" == l2 ? l2.toLowerCase().slice(2) : l2.slice(2), n2.l || (n2.l = {}), n2.l[l2 + r2] = u2, u2 ? t2 ? u2.u = t2.u : (u2.u = c$1, n2.addEventListener(l2, r2 ? a$1 : s$1, r2)) : n2.removeEventListener(l2, r2 ? a$1 : s$1, r2);
134
- else {
135
- if ("http://www.w3.org/2000/svg" == i2) l2 = l2.replace(/xlink(H|:h)/, "h").replace(/sName$/, "s");
136
- else if ("width" != l2 && "height" != l2 && "href" != l2 && "list" != l2 && "form" != l2 && "tabIndex" != l2 && "download" != l2 && "rowSpan" != l2 && "colSpan" != l2 && "role" != l2 && "popover" != l2 && l2 in n2) try {
137
- n2[l2] = null == u2 ? "" : u2;
138
- break n;
139
- } catch (n3) {
140
- }
141
- "function" == typeof u2 || (null == u2 || false === u2 && "-" != l2[4] ? n2.removeAttribute(l2) : n2.setAttribute(l2, "popover" == l2 && 1 == u2 ? "" : u2));
142
- }
143
- }
144
- function O(n2) {
145
- return function(u2) {
146
- if (this.l) {
147
- var t2 = this.l[u2.type + n2];
148
- if (null == u2.t) u2.t = c$1++;
149
- else if (u2.t < t2.u) return;
150
- return t2(l$1.event ? l$1.event(u2) : u2);
151
- }
152
- };
153
- }
154
- function j$1(n2, u2, t2, i2, r2, o2, e2, f2, c2, s2) {
155
- var a2, h2, p2, v2, y2, g2, m2, b, C2, S2, M2, P2, I2, A2, H, L2, T2, F2 = u2.type;
156
- if (void 0 !== u2.constructor) return null;
157
- 128 & t2.__u && (c2 = !!(32 & t2.__u), o2 = [f2 = u2.__e = t2.__e]), (a2 = l$1.__b) && a2(u2);
158
- n: if ("function" == typeof F2) try {
159
- if (b = u2.props, C2 = "prototype" in F2 && F2.prototype.render, S2 = (a2 = F2.contextType) && i2[a2.__c], M2 = a2 ? S2 ? S2.props.value : a2.__ : i2, t2.__c ? m2 = (h2 = u2.__c = t2.__c).__ = h2.__E : (C2 ? u2.__c = h2 = new F2(b, M2) : (u2.__c = h2 = new x(b, M2), h2.constructor = F2, h2.render = B$1), S2 && S2.sub(h2), h2.props = b, h2.state || (h2.state = {}), h2.context = M2, h2.__n = i2, p2 = h2.__d = true, h2.__h = [], h2._sb = []), C2 && null == h2.__s && (h2.__s = h2.state), C2 && null != F2.getDerivedStateFromProps && (h2.__s == h2.state && (h2.__s = w$1({}, h2.__s)), w$1(h2.__s, F2.getDerivedStateFromProps(b, h2.__s))), v2 = h2.props, y2 = h2.state, h2.__v = u2, p2) C2 && null == F2.getDerivedStateFromProps && null != h2.componentWillMount && h2.componentWillMount(), C2 && null != h2.componentDidMount && h2.__h.push(h2.componentDidMount);
160
- else {
161
- if (C2 && null == F2.getDerivedStateFromProps && b !== v2 && null != h2.componentWillReceiveProps && h2.componentWillReceiveProps(b, M2), !h2.__e && (null != h2.shouldComponentUpdate && false === h2.shouldComponentUpdate(b, h2.__s, M2) || u2.__v == t2.__v)) {
162
- for (u2.__v != t2.__v && (h2.props = b, h2.state = h2.__s, h2.__d = false), u2.__e = t2.__e, u2.__k = t2.__k, u2.__k.some(function(n3) {
163
- n3 && (n3.__ = u2);
164
- }), P2 = 0; P2 < h2._sb.length; P2++) h2.__h.push(h2._sb[P2]);
165
- h2._sb = [], h2.__h.length && e2.push(h2);
166
- break n;
167
- }
168
- null != h2.componentWillUpdate && h2.componentWillUpdate(b, h2.__s, M2), C2 && null != h2.componentDidUpdate && h2.__h.push(function() {
169
- h2.componentDidUpdate(v2, y2, g2);
170
- });
171
- }
172
- if (h2.context = M2, h2.props = b, h2.__P = n2, h2.__e = false, I2 = l$1.__r, A2 = 0, C2) {
173
- for (h2.state = h2.__s, h2.__d = false, I2 && I2(u2), a2 = h2.render(h2.props, h2.state, h2.context), H = 0; H < h2._sb.length; H++) h2.__h.push(h2._sb[H]);
174
- h2._sb = [];
175
- } else do {
176
- h2.__d = false, I2 && I2(u2), a2 = h2.render(h2.props, h2.state, h2.context), h2.state = h2.__s;
177
- } while (h2.__d && ++A2 < 25);
178
- h2.state = h2.__s, null != h2.getChildContext && (i2 = w$1(w$1({}, i2), h2.getChildContext())), C2 && !p2 && null != h2.getSnapshotBeforeUpdate && (g2 = h2.getSnapshotBeforeUpdate(v2, y2)), f2 = $(n2, d$1(L2 = null != a2 && a2.type === k$1 && null == a2.key ? a2.props.children : a2) ? L2 : [L2], u2, t2, i2, r2, o2, e2, f2, c2, s2), h2.base = u2.__e, u2.__u &= -161, h2.__h.length && e2.push(h2), m2 && (h2.__E = h2.__ = null);
179
- } catch (n3) {
180
- if (u2.__v = null, c2 || null != o2) if (n3.then) {
181
- for (u2.__u |= c2 ? 160 : 128; f2 && 8 == f2.nodeType && f2.nextSibling; ) f2 = f2.nextSibling;
182
- o2[o2.indexOf(f2)] = null, u2.__e = f2;
183
- } else for (T2 = o2.length; T2--; ) _(o2[T2]);
184
- else u2.__e = t2.__e, u2.__k = t2.__k;
185
- l$1.__e(n3, u2, t2);
186
- }
187
- else null == o2 && u2.__v == t2.__v ? (u2.__k = t2.__k, u2.__e = t2.__e) : f2 = u2.__e = N(t2.__e, u2, t2, i2, r2, o2, e2, c2, s2);
188
- return (a2 = l$1.diffed) && a2(u2), 128 & u2.__u ? void 0 : f2;
189
- }
190
- function z$1(n2, u2, t2) {
191
- for (var i2 = 0; i2 < t2.length; i2++) V(t2[i2], t2[++i2], t2[++i2]);
192
- l$1.__c && l$1.__c(u2, n2), n2.some(function(u3) {
193
- try {
194
- n2 = u3.__h, u3.__h = [], n2.some(function(n3) {
195
- n3.call(u3);
196
- });
197
- } catch (n3) {
198
- l$1.__e(n3, u3.__v);
199
- }
200
- });
201
- }
202
- function N(u2, t2, i2, r2, o2, e2, f2, c2, s2) {
203
- var a2, h2, v2, y2, w2, g2, m2, b = i2.props, k2 = t2.props, x2 = t2.type;
204
- if ("svg" == x2 ? o2 = "http://www.w3.org/2000/svg" : "math" == x2 ? o2 = "http://www.w3.org/1998/Math/MathML" : o2 || (o2 = "http://www.w3.org/1999/xhtml"), null != e2) {
205
- for (a2 = 0; a2 < e2.length; a2++) if ((w2 = e2[a2]) && "setAttribute" in w2 == !!x2 && (x2 ? w2.localName == x2 : 3 == w2.nodeType)) {
206
- u2 = w2, e2[a2] = null;
207
- break;
208
- }
209
- }
210
- if (null == u2) {
211
- if (null == x2) return document.createTextNode(k2);
212
- u2 = document.createElementNS(o2, x2, k2.is && k2), c2 && (l$1.__m && l$1.__m(t2, e2), c2 = false), e2 = null;
213
- }
214
- if (null === x2) b === k2 || c2 && u2.data === k2 || (u2.data = k2);
215
- else {
216
- if (e2 = e2 && n.call(u2.childNodes), b = i2.props || p$1, !c2 && null != e2) for (b = {}, a2 = 0; a2 < u2.attributes.length; a2++) b[(w2 = u2.attributes[a2]).name] = w2.value;
217
- for (a2 in b) if (w2 = b[a2], "children" == a2) ;
218
- else if ("dangerouslySetInnerHTML" == a2) v2 = w2;
219
- else if (!(a2 in k2)) {
220
- if ("value" == a2 && "defaultValue" in k2 || "checked" == a2 && "defaultChecked" in k2) continue;
221
- F(u2, a2, null, w2, o2);
222
- }
223
- for (a2 in k2) w2 = k2[a2], "children" == a2 ? y2 = w2 : "dangerouslySetInnerHTML" == a2 ? h2 = w2 : "value" == a2 ? g2 = w2 : "checked" == a2 ? m2 = w2 : c2 && "function" != typeof w2 || b[a2] === w2 || F(u2, a2, w2, b[a2], o2);
224
- if (h2) c2 || v2 && (h2.__html === v2.__html || h2.__html === u2.innerHTML) || (u2.innerHTML = h2.__html), t2.__k = [];
225
- else if (v2 && (u2.innerHTML = ""), $(u2, d$1(y2) ? y2 : [y2], t2, i2, r2, "foreignObject" == x2 ? "http://www.w3.org/1999/xhtml" : o2, e2, f2, e2 ? e2[0] : i2.__k && C$1(i2, 0), c2, s2), null != e2) for (a2 = e2.length; a2--; ) _(e2[a2]);
226
- c2 || (a2 = "value", "progress" == x2 && null == g2 ? u2.removeAttribute("value") : void 0 !== g2 && (g2 !== u2[a2] || "progress" == x2 && !g2 || "option" == x2 && g2 !== b[a2]) && F(u2, a2, g2, b[a2], o2), a2 = "checked", void 0 !== m2 && m2 !== u2[a2] && F(u2, a2, m2, b[a2], o2));
227
- }
228
- return u2;
229
- }
230
- function V(n2, u2, t2) {
231
- try {
232
- if ("function" == typeof n2) {
233
- var i2 = "function" == typeof n2.__u;
234
- i2 && n2.__u(), i2 && null == u2 || (n2.__u = n2(u2));
235
- } else n2.current = u2;
236
- } catch (n3) {
237
- l$1.__e(n3, t2);
238
- }
239
- }
240
- function q$1(n2, u2, t2) {
241
- var i2, r2;
242
- if (l$1.unmount && l$1.unmount(n2), (i2 = n2.ref) && (i2.current && i2.current !== n2.__e || V(i2, null, u2)), null != (i2 = n2.__c)) {
243
- if (i2.componentWillUnmount) try {
244
- i2.componentWillUnmount();
245
- } catch (n3) {
246
- l$1.__e(n3, u2);
247
- }
248
- i2.base = i2.__P = null;
249
- }
250
- if (i2 = n2.__k) for (r2 = 0; r2 < i2.length; r2++) i2[r2] && q$1(i2[r2], u2, t2 || "function" != typeof n2.type);
251
- t2 || _(n2.__e), n2.__c = n2.__ = n2.__e = void 0;
252
- }
253
- function B$1(n2, l2, u2) {
254
- return this.constructor(n2, u2);
255
- }
256
- function D$1(u2, t2, i2) {
257
- var r2, o2, e2, f2;
258
- t2 == document && (t2 = document.documentElement), l$1.__ && l$1.__(u2, t2), o2 = (r2 = false) ? null : t2.__k, e2 = [], f2 = [], j$1(t2, u2 = t2.__k = g(k$1, null, [u2]), o2 || p$1, p$1, t2.namespaceURI, o2 ? null : t2.firstChild ? n.call(t2.childNodes) : null, e2, o2 ? o2.__e : t2.firstChild, r2, f2), z$1(e2, u2, f2);
259
- }
260
- n = v$1.slice, l$1 = { __e: function(n2, l2, u2, t2) {
261
- for (var i2, r2, o2; l2 = l2.__; ) if ((i2 = l2.__c) && !i2.__) try {
262
- if ((r2 = i2.constructor) && null != r2.getDerivedStateFromError && (i2.setState(r2.getDerivedStateFromError(n2)), o2 = i2.__d), null != i2.componentDidCatch && (i2.componentDidCatch(n2, t2 || {}), o2 = i2.__d), o2) return i2.__E = i2;
263
- } catch (l3) {
264
- n2 = l3;
265
- }
266
- throw n2;
267
- } }, u$2 = 0, x.prototype.setState = function(n2, l2) {
268
- var u2;
269
- u2 = null != this.__s && this.__s !== this.state ? this.__s : this.__s = w$1({}, this.state), "function" == typeof n2 && (n2 = n2(w$1({}, u2), this.props)), n2 && w$1(u2, n2), null != n2 && this.__v && (l2 && this._sb.push(l2), M(this));
270
- }, x.prototype.forceUpdate = function(n2) {
271
- this.__v && (this.__e = true, n2 && this.__h.push(n2), M(this));
272
- }, x.prototype.render = k$1, i$1 = [], o$1 = "function" == typeof Promise ? Promise.prototype.then.bind(Promise.resolve()) : setTimeout, e$1 = function(n2, l2) {
273
- return n2.__v.__b - l2.__v.__b;
274
- }, P.__r = 0, f$2 = /(PointerCapture)$|Capture$/i, c$1 = 0, s$1 = O(false), a$1 = O(true);
275
- var f$1 = 0;
276
- function u$1(e2, t2, n2, o2, i2, u2) {
277
- t2 || (t2 = {});
278
- var a2, c2, p2 = t2;
279
- if ("ref" in p2) for (c2 in p2 = {}, t2) "ref" == c2 ? a2 = t2[c2] : p2[c2] = t2[c2];
280
- var l2 = { type: e2, props: p2, key: n2, ref: a2, __k: null, __: null, __b: 0, __e: null, __c: null, constructor: void 0, __v: --f$1, __i: -1, __u: 0, __source: i2, __self: u2 };
281
- if ("function" == typeof e2 && (a2 = e2.defaultProps)) for (c2 in a2) void 0 === p2[c2] && (p2[c2] = a2[c2]);
282
- return l$1.vnode && l$1.vnode(l2), l2;
283
- }
284
- var t, r, u, i, o = 0, f = [], c = l$1, e = c.__b, a = c.__r, v = c.diffed, l = c.__c, m = c.unmount, s = c.__;
285
- function d(n2, t2) {
286
- c.__h && c.__h(r, n2, o || t2), o = 0;
287
- var u2 = r.__H || (r.__H = { __: [], __h: [] });
288
- return n2 >= u2.__.length && u2.__.push({}), u2.__[n2];
289
- }
290
- function h(n2) {
291
- return o = 1, p(D, n2);
292
- }
293
- function p(n2, u2, i2) {
294
- var o2 = d(t++, 2);
295
- if (o2.t = n2, !o2.__c && (o2.__ = [D(void 0, u2), function(n3) {
296
- var t2 = o2.__N ? o2.__N[0] : o2.__[0], r2 = o2.t(t2, n3);
297
- t2 !== r2 && (o2.__N = [r2, o2.__[1]], o2.__c.setState({}));
298
- }], o2.__c = r, !r.u)) {
299
- var f2 = function(n3, t2, r2) {
300
- if (!o2.__c.__H) return true;
301
- var u3 = o2.__c.__H.__.filter(function(n4) {
302
- return !!n4.__c;
303
- });
304
- if (u3.every(function(n4) {
305
- return !n4.__N;
306
- })) return !c2 || c2.call(this, n3, t2, r2);
307
- var i3 = o2.__c.props !== n3;
308
- return u3.forEach(function(n4) {
309
- if (n4.__N) {
310
- var t3 = n4.__[0];
311
- n4.__ = n4.__N, n4.__N = void 0, t3 !== n4.__[0] && (i3 = true);
312
- }
313
- }), c2 && c2.call(this, n3, t2, r2) || i3;
314
- };
315
- r.u = true;
316
- var c2 = r.shouldComponentUpdate, e2 = r.componentWillUpdate;
317
- r.componentWillUpdate = function(n3, t2, r2) {
318
- if (this.__e) {
319
- var u3 = c2;
320
- c2 = void 0, f2(n3, t2, r2), c2 = u3;
321
- }
322
- e2 && e2.call(this, n3, t2, r2);
323
- }, r.shouldComponentUpdate = f2;
324
- }
325
- return o2.__N || o2.__;
326
- }
327
- function y(n2, u2) {
328
- var i2 = d(t++, 3);
329
- !c.__s && C(i2.__H, u2) && (i2.__ = n2, i2.i = u2, r.__H.__h.push(i2));
330
- }
331
- function T(n2, r2) {
332
- var u2 = d(t++, 7);
333
- return C(u2.__H, r2) && (u2.__ = n2(), u2.__H = r2, u2.__h = n2), u2.__;
334
- }
335
- function q(n2, t2) {
336
- return o = 8, T(function() {
337
- return n2;
338
- }, t2);
339
- }
340
- function j() {
341
- for (var n2; n2 = f.shift(); ) if (n2.__P && n2.__H) try {
342
- n2.__H.__h.forEach(z), n2.__H.__h.forEach(B), n2.__H.__h = [];
343
- } catch (t2) {
344
- n2.__H.__h = [], c.__e(t2, n2.__v);
345
- }
346
- }
347
- c.__b = function(n2) {
348
- r = null, e && e(n2);
349
- }, c.__ = function(n2, t2) {
350
- n2 && t2.__k && t2.__k.__m && (n2.__m = t2.__k.__m), s && s(n2, t2);
351
- }, c.__r = function(n2) {
352
- a && a(n2), t = 0;
353
- var i2 = (r = n2.__c).__H;
354
- i2 && (u === r ? (i2.__h = [], r.__h = [], i2.__.forEach(function(n3) {
355
- n3.__N && (n3.__ = n3.__N), n3.i = n3.__N = void 0;
356
- })) : (i2.__h.forEach(z), i2.__h.forEach(B), i2.__h = [], t = 0)), u = r;
357
- }, c.diffed = function(n2) {
358
- v && v(n2);
359
- var t2 = n2.__c;
360
- t2 && t2.__H && (t2.__H.__h.length && (1 !== f.push(t2) && i === c.requestAnimationFrame || ((i = c.requestAnimationFrame) || w)(j)), t2.__H.__.forEach(function(n3) {
361
- n3.i && (n3.__H = n3.i), n3.i = void 0;
362
- })), u = r = null;
363
- }, c.__c = function(n2, t2) {
364
- t2.some(function(n3) {
365
- try {
366
- n3.__h.forEach(z), n3.__h = n3.__h.filter(function(n4) {
367
- return !n4.__ || B(n4);
368
- });
369
- } catch (r2) {
370
- t2.some(function(n4) {
371
- n4.__h && (n4.__h = []);
372
- }), t2 = [], c.__e(r2, n3.__v);
373
- }
374
- }), l && l(n2, t2);
375
- }, c.unmount = function(n2) {
376
- m && m(n2);
377
- var t2, r2 = n2.__c;
378
- r2 && r2.__H && (r2.__H.__.forEach(function(n3) {
379
- try {
380
- z(n3);
381
- } catch (n4) {
382
- t2 = n4;
383
- }
384
- }), r2.__H = void 0, t2 && c.__e(t2, r2.__v));
385
- };
386
- var k = "function" == typeof requestAnimationFrame;
387
- function w(n2) {
388
- var t2, r2 = function() {
389
- clearTimeout(u2), k && cancelAnimationFrame(t2), setTimeout(n2);
390
- }, u2 = setTimeout(r2, 100);
391
- k && (t2 = requestAnimationFrame(r2));
392
- }
393
- function z(n2) {
394
- var t2 = r, u2 = n2.__c;
395
- "function" == typeof u2 && (n2.__c = void 0, u2()), r = t2;
396
- }
397
- function B(n2) {
398
- var t2 = r;
399
- n2.__c = n2.__(), r = t2;
400
- }
401
- function C(n2, t2) {
402
- return !n2 || n2.length !== t2.length || t2.some(function(t3, r2) {
403
- return t3 !== n2[r2];
404
- });
405
- }
406
- function D(n2, t2) {
407
- return "function" == typeof t2 ? t2(n2) : t2;
408
- }
409
- const header = "_header_1hnaa_1";
410
- const logo = "_logo_1hnaa_6";
411
- const style$a = {
412
- header,
413
- logo
414
- };
415
- const container = "_container_1putz_1";
416
- const style$9 = {
417
- container
418
- };
419
- function Container(props) {
420
- return /* @__PURE__ */ u$1("div", { class: style$9.container, children: props.children });
421
- }
422
- const itemKey$1 = "topics";
423
- function loadTopics() {
424
- const storedTopics = localStorage.getItem(itemKey$1);
425
- if (storedTopics) {
426
- return JSON.parse(storedTopics);
427
- } else {
428
- return [];
429
- }
430
- }
431
- function saveTopics(topics) {
432
- localStorage.setItem(itemKey$1, JSON.stringify(topics));
433
- }
434
- function getDefaultExportFromCjs(x2) {
435
- return x2 && x2.__esModule && Object.prototype.hasOwnProperty.call(x2, "default") ? x2["default"] : x2;
436
- }
437
- var classnames = { exports: {} };
438
- /*!
439
- Copyright (c) 2018 Jed Watson.
440
- Licensed under the MIT License (MIT), see
441
- http://jedwatson.github.io/classnames
442
- */
443
- var hasRequiredClassnames;
444
- function requireClassnames() {
445
- if (hasRequiredClassnames) return classnames.exports;
446
- hasRequiredClassnames = 1;
447
- (function(module) {
448
- (function() {
449
- var hasOwn = {}.hasOwnProperty;
450
- function classNames() {
451
- var classes = "";
452
- for (var i2 = 0; i2 < arguments.length; i2++) {
453
- var arg = arguments[i2];
454
- if (arg) {
455
- classes = appendClass(classes, parseValue(arg));
456
- }
457
- }
458
- return classes;
459
- }
460
- function parseValue(arg) {
461
- if (typeof arg === "string" || typeof arg === "number") {
462
- return arg;
463
- }
464
- if (typeof arg !== "object") {
465
- return "";
466
- }
467
- if (Array.isArray(arg)) {
468
- return classNames.apply(null, arg);
469
- }
470
- if (arg.toString !== Object.prototype.toString && !arg.toString.toString().includes("[native code]")) {
471
- return arg.toString();
472
- }
473
- var classes = "";
474
- for (var key in arg) {
475
- if (hasOwn.call(arg, key) && arg[key]) {
476
- classes = appendClass(classes, key);
477
- }
478
- }
479
- return classes;
480
- }
481
- function appendClass(value, newClass) {
482
- if (!newClass) {
483
- return value;
484
- }
485
- if (value) {
486
- return value + " " + newClass;
487
- }
488
- return value + newClass;
489
- }
490
- if (module.exports) {
491
- classNames.default = classNames;
492
- module.exports = classNames;
493
- } else {
494
- window.classNames = classNames;
495
- }
496
- })();
497
- })(classnames);
498
- return classnames.exports;
499
- }
500
- var classnamesExports = requireClassnames();
501
- const cn = /* @__PURE__ */ getDefaultExportFromCjs(classnamesExports);
502
- const spinnerSquare = "_spinnerSquare_4vgl0_1";
503
- const square1 = "_square1_4vgl0_14";
504
- const square2 = "_square2_4vgl0_18";
505
- const square3 = "_square3_4vgl0_22";
506
- const style$8 = {
507
- spinnerSquare,
508
- square1,
509
- "square-anim": "_square-anim_4vgl0_1",
510
- square2,
511
- square3
512
- };
513
- function Spinner(props) {
514
- return /* @__PURE__ */ u$1("div", { className: cn(style$8.spinnerSquare, props.className), children: [
515
- /* @__PURE__ */ u$1("div", { className: style$8.square1 }),
516
- /* @__PURE__ */ u$1("div", { className: style$8.square2 }),
517
- /* @__PURE__ */ u$1("div", { className: style$8.square3 })
518
- ] });
519
- }
520
- const spinner$1 = "_spinner_1pqws_1";
521
- const list = "_list_1pqws_5";
522
- const highlight = "_highlight_1pqws_44";
523
- const head = "_head_1pqws_48";
524
- const generationSettings$1 = "_generationSettings_1pqws_52";
525
- const style$7 = {
526
- spinner: spinner$1,
527
- list,
528
- highlight,
529
- head,
530
- generationSettings: generationSettings$1
531
- };
532
- const routes = {
533
- home: "home",
534
- topic: "topic",
535
- settings: "settings"
536
- };
537
- const btn = "_btn_1ts7o_1";
538
- const disabled = "_disabled_1ts7o_18";
539
- const secondary = "_secondary_1ts7o_22";
540
- const spinner = "_spinner_1ts7o_32";
541
- const load3 = "_load3_1ts7o_1";
542
- const style$6 = {
543
- btn,
544
- disabled,
545
- secondary,
546
- spinner,
547
- load3
548
- };
549
- function Button(props) {
550
- const disabled2 = props.disabled || props.loading;
551
- const buttonClass = cn(style$6.btn, { [style$6.secondary]: props.secondary }, "button", props.className, { [style$6.disabled]: disabled2 });
552
- let spinner2 = void 0;
553
- if (props.loading) {
554
- spinner2 = /* @__PURE__ */ u$1("span", { className: style$6.spinner });
555
- }
556
- return /* @__PURE__ */ u$1(
557
- "button",
558
- {
559
- type: "button",
560
- onClick: () => {
561
- if (!disabled2) {
562
- props.onClick();
563
- }
564
- },
565
- className: buttonClass,
566
- disabled: disabled2,
567
- title: props.title,
568
- children: [
569
- spinner2,
570
- props.children
571
- ]
572
- }
573
- );
574
- }
575
- const iso8601ToFrenchRegex = /(\d{4})-(\d{2})-(\d{2})T(\d{2}):(\d{2}):(\d{2})/;
576
- function iso8601ToFrench(iso8601) {
577
- console.log("iso8601ToTokens", iso8601);
578
- const matches = iso8601.match(iso8601ToFrenchRegex);
579
- const year = matches[1];
580
- const month = months[parseInt(matches[2], 10) - 1];
581
- const day = matches[3];
582
- const hours = matches[4];
583
- const minutes = matches[5];
584
- const seconds = matches[6];
585
- return `${day} ${month} ${year} à ${hours}:${minutes}:${seconds}`;
586
- }
587
- const frenchToIso8601Regex = /(\d{1,2}) ([a-zA-Z\u00C0-\u024F]+) (\d{4}) à (\d{2}):(\d{2}):(\d{2})/;
588
- function frenchToIso8601(french) {
589
- console.log("tokensToIso8601", french);
590
- const match = french.match(frenchToIso8601Regex);
591
- if (!match) {
592
- throw new Error("Invalid date format");
593
- }
594
- const [, day, month, year, hours, minutes, seconds] = match;
595
- const monthNumber = (months.indexOf(month) + 1).toString();
596
- if (!monthNumber) {
597
- throw new Error("Invalid month name");
598
- }
599
- const isoDate = `${year}-${monthNumber.padStart(2, "0")}-${day.padStart(2, "0")}T${hours}:${minutes}:${seconds}`;
600
- return isoDate;
601
- }
602
- const months = [
603
- "janvier",
604
- "février",
605
- "mars",
606
- "avril",
607
- "mai",
608
- "juin",
609
- "juillet",
610
- "août",
611
- "septembre",
612
- "octobre",
613
- "novembre",
614
- "décembre"
615
- ];
616
- const formGroup = "_formGroup_b3g81_1";
617
- const style$5 = {
618
- formGroup
619
- };
620
- function FormGroup(props) {
621
- return /* @__PURE__ */ u$1("div", { className: style$5.formGroup, children: props.children });
622
- }
623
- const slider = "_slider_1hlzr_1";
624
- const outputContainer = "_outputContainer_1hlzr_36";
625
- const output = "_output_1hlzr_36";
626
- const progress = "_progress_1hlzr_56";
627
- const input$1 = "_input_1hlzr_83";
628
- const style$4 = {
629
- slider,
630
- outputContainer,
631
- output,
632
- progress,
633
- input: input$1
634
- };
635
- function Slider(props) {
636
- return /* @__PURE__ */ u$1(
637
- "div",
638
- {
639
- className: cn(style$4.slider, props.className),
640
- style: {
641
- "--value": props.value,
642
- "--min": props.min,
643
- "--max": props.max,
644
- "--step": props.step
645
- },
646
- children: [
647
- /* @__PURE__ */ u$1(
648
- "input",
649
- {
650
- type: "range",
651
- className: style$4.input,
652
- name: props.name,
653
- min: props.min,
654
- max: props.max,
655
- step: props.step,
656
- value: props.value,
657
- onInput: (e2) => props.onChange(Number(e2.target.value))
658
- }
659
- ),
660
- /* @__PURE__ */ u$1("div", { className: style$4.progress }),
661
- /* @__PURE__ */ u$1("div", { className: style$4.outputContainer, children: /* @__PURE__ */ u$1("output", { className: style$4.output, children: props.value }) })
662
- ]
663
- }
664
- );
665
- }
666
- function Topics(props) {
667
- const sortedTopics = T(() => {
668
- if (props.topics === null || props.topics.length < 1) {
669
- return props.topics;
670
- }
671
- return props.topics.sort((topicA, topicB) => {
672
- if (topicA.posts.length < 1 || topicB.posts.length < 1) {
673
- return 0;
674
- }
675
- return topicB.posts[topicB.posts.length - 1].date.localeCompare(topicA.posts[topicA.posts.length - 1].date);
676
- });
677
- }, [props.topics]);
678
- return /* @__PURE__ */ u$1("div", { children: [
679
- sortedTopics === null ? /* @__PURE__ */ u$1(Spinner, { className: style$7.spinner }) : /* @__PURE__ */ u$1(
680
- List,
681
- {
682
- topics: sortedTopics,
683
- setRoute: props.setRoute,
684
- latestGeneratedTopicId: props.latestGeneratedTopicId
685
- }
686
- ),
687
- /* @__PURE__ */ u$1("div", { children: [
688
- /* @__PURE__ */ u$1("h2", { children: "Nouveau sujet" }),
689
- /* @__PURE__ */ u$1("div", { className: style$7.generationSettings, children: /* @__PURE__ */ u$1(FormGroup, { children: [
690
- /* @__PURE__ */ u$1("label", { for: "postCount", children: "Nombre de posts" }),
691
- /* @__PURE__ */ u$1(
692
- Slider,
693
- {
694
- name: "postCount",
695
- value: props.settings.postCount,
696
- onChange: (v2) => props.setSettings({ ...props.settings, postCount: v2 }),
697
- min: 1,
698
- max: 10,
699
- step: 1
700
- }
701
- )
702
- ] }) }),
703
- /* @__PURE__ */ u$1(
704
- Button,
705
- {
706
- onClick: () => props.generateTopic(props.settings.postCount),
707
- secondary: true,
708
- loading: props.pendingGeneration,
709
- children: "Générer"
710
- }
711
- )
712
- ] }),
713
- /* @__PURE__ */ u$1("hr", {})
714
- ] });
715
- }
716
- function List(props) {
717
- return /* @__PURE__ */ u$1("ul", { className: style$7.list, children: [
718
- /* @__PURE__ */ u$1("li", { className: style$7.head, children: [
719
- /* @__PURE__ */ u$1("span", { children: "Sujet" }),
720
- /* @__PURE__ */ u$1("span", { children: "Auteur" }),
721
- /* @__PURE__ */ u$1("span", { children: "NB" }),
722
- /* @__PURE__ */ u$1("span", { children: "Dernier msg" })
723
- ] }),
724
- props.topics.length < 1 && /* @__PURE__ */ u$1("li", { children: [
725
- /* @__PURE__ */ u$1("span", { children: "Aucun sujet" }),
726
- /* @__PURE__ */ u$1("span", {}),
727
- /* @__PURE__ */ u$1("span", {}),
728
- /* @__PURE__ */ u$1("span", {})
729
- ] }),
730
- props.topics.map((topic) => /* @__PURE__ */ u$1("li", { className: cn({ [style$7.highlight]: topic.id === props.latestGeneratedTopicId }), children: [
731
- /* @__PURE__ */ u$1("span", { children: /* @__PURE__ */ u$1("a", { href: "#", onClick: (e2) => {
732
- e2.preventDefault();
733
- props.setRoute(routes.topic, 0, topic.id);
734
- }, children: topic.title }) }),
735
- /* @__PURE__ */ u$1("span", { children: topic.posts[0].user }),
736
- /* @__PURE__ */ u$1("span", { children: topic.posts.length }),
737
- /* @__PURE__ */ u$1("span", { children: iso8601ToFrench(topic.posts[topic.posts.length - 1].date) })
738
- ] }))
739
- ] });
740
- }
741
- const post = "_post_uuidr_1";
742
- const postHeader = "_postHeader_uuidr_12";
743
- const avatar = "_avatar_uuidr_23";
744
- const user = "_user_uuidr_31";
745
- const date = "_date_uuidr_39";
746
- const generationSettings = "_generationSettings_uuidr_46";
747
- const style$3 = {
748
- post,
749
- postHeader,
750
- avatar,
751
- user,
752
- date,
753
- generationSettings
754
- };
755
- const wrapper$1 = "_wrapper_cfqzy_1";
756
- const style$2 = {
757
- wrapper: wrapper$1
758
- };
759
- const smileysMap = [
760
- [":)", "1"],
761
- // https://image.jeuxvideo.com/smileys_img/1.gif
762
- [":snif:", "20"],
763
- [":gba:", "17"],
764
- [":g)", "3"],
765
- [":-)", "46"],
766
- [":snif2:", "13"],
767
- [":bravo:", "69"],
768
- [":d)", "4"],
769
- [":hap:", "18"],
770
- [":ouch:", "22"],
771
- [":pacg:", "9"],
772
- [":cd:", "5"],
773
- [":-)))", "23"],
774
- [":ouch2:", "57"],
775
- [":pacd:", "10"],
776
- [":cute:", "nyu"],
777
- [":content:", "24"],
778
- [":p)", "7"],
779
- [":-p", "31"],
780
- [":noel:", "11"],
781
- [":oui:", "37"],
782
- [":(", "45"],
783
- [":peur:", "47"],
784
- [":question:", "2"],
785
- [":cool:", "26"],
786
- [":-(", "14"],
787
- [":coeur:", "54"],
788
- [":mort:", "21"],
789
- [":rire:", "39"],
790
- [":-((", "15"],
791
- [":fou:", "50"],
792
- [":sleep:", "27"],
793
- [":-D", "40"],
794
- [":nonnon:", "25"],
795
- [":fier:", "53"],
796
- [":honte:", "30"],
797
- [":rire2:", "41"],
798
- [":non2:", "33"],
799
- [":sarcastic:", "43"],
800
- [":monoeil:", "34"],
801
- [":o))", "12"],
802
- [":nah:", "19"],
803
- [":doute:", "28"],
804
- [":rouge:", "55"],
805
- [":ok:", "36"],
806
- [":non:", "35"],
807
- [":malade:", "8"],
808
- [":fete:", "66"],
809
- [":sournois:", "67"],
810
- [":hum:", "68"],
811
- [":ange:", "60"],
812
- [":diable:", "61"],
813
- [":gni:", "62"],
814
- [":play:", "play"],
815
- [":desole:", "65"],
816
- [":spoiler:", "63"],
817
- [":merci:", "58"],
818
- [":svp:", "59"],
819
- [":sors:", "56"],
820
- [":salut:", "42"],
821
- [":rechercher:", "38"],
822
- [":hello:", "29"],
823
- [":up:", "44"],
824
- [":bye:", "48"],
825
- [":gne:", "51"],
826
- [":lol:", "32"],
827
- [":dpdr:", "49"],
828
- [":dehors:", "52"],
829
- [":hs:", "64"],
830
- [":banzai:", "70"],
831
- [":bave:", "71"],
832
- [":pf:", "pf"],
833
- [":cimer:", "cimer"],
834
- [":ddb:", "ddb"],
835
- [":pave:", "pave"],
836
- [":objection:", "objection"],
837
- [":siffle:", "siffle"]
838
- ];
839
- function Preview(props) {
840
- const html = T(() => {
841
- const escaped = escapeHtml(props.raw);
842
- return injectHTML(escaped).replace(/\n/g, "<br/>");
843
- }, [props.raw]);
844
- return /* @__PURE__ */ u$1("div", { className: style$2.wrapper, dangerouslySetInnerHTML: { __html: html } });
845
- }
846
- const jvcodeMap = [
847
- // [/(https?:\/\/image\.noelshack\.com\/\S+)/g]: "<img width=\"68\" height=\"51\" alt=\"noelshak\" src=\"$1\"/>"
848
- [
849
- // Stickers
850
- /(^| )https?:\/\/image\.noelshack\.com\/(?:fichiers|minis)(\S+)/gm,
851
- '$1<img width="68" height="51" alt="noelshak" src="https://image.noelshack.com/minis/$2"/>'
852
- ],
853
- [
854
- // Vocaroo
855
- /(^| )https:\/\/vocaroo.com\/(.+)/gm,
856
- '$1<div><iframe width="300" height="60" src="https://vocaroo.com/embed/$2?autoplay=0" frameborder="0" allow="autoplay"></iframe></div>'
857
- ],
858
- [
859
- // Citations
860
- /^(?:&gt;.*(?:\n&gt;.*)*)/g,
861
- (reg, raw) => {
862
- const match = reg.exec(raw);
863
- if (!match) return raw;
864
- console.log(match);
865
- const index = match.index;
866
- const length = match[0].length;
867
- return raw.substring(0, index) + `<blockquote>${match[0].replace(/^&gt;/gm, "")}</blockquote>` + raw.substring(index + length);
868
- }
869
- ],
870
- [
871
- // Spoil
872
- /&lt;spoil&gt;(.*?)&lt;\/spoil&gt;/gm,
873
- (reg, raw) => {
874
- return raw.replace(reg, (_2, matched) => {
875
- const randomId = (Math.random() + 1).toString(36).substring(2);
876
- return `<span class="bloc-spoil-jv"><input type="checkbox" id="${randomId}" class="open-spoil"><label class="barre-head" for="${randomId}"><span class="txt-spoil">Spoil</span></label><span class="contenu-spoil">${matched}</span></span>`;
877
- });
878
- }
879
- ],
880
- [
881
- // Regular links
882
- /(^| )(https?:\/\/\S+)/gm,
883
- '$1<a href="$2" target="_blank">$2</a>'
884
- ],
885
- // Generate regexes for smileys
886
- // ...smileysMap.map((maping) => {
887
- // return [new RegExp(
888
- // Object.keys(smileysMap).map(s => (
889
- // "(?:(?:^| )" + s.replace(/[.*+?^${}()|[\]\\]/g, '\\$&') + ")"
890
- // )).join("|"), "gm"
891
- // ), `<img src="${maping[1]}" width="16" height="16" alt=""/>`]
892
- // })
893
- // (() => {
894
- // new RegExp(
895
- // smileysMap.map((mapping) => (
896
- // "(?:(?:^| )" + s.replace(/[.*+?^${}()|[\]\\]/g, '\\$&') + ")"
897
- // )).join("|"), "gm"
898
- // )
899
- // return [/(https?:\/\/image\.noelshack\.com\/\S+)/g, "<img width=\"68\" height=\"51\" alt=\"noelshak\" src=\"$1\"/>"]
900
- // })()
901
- ...smileysMap.map((mapping) => {
902
- return [
903
- new RegExp("(?:(^| )" + mapping[0].replace(/[.*+?^${}()|[\]\\]/g, "\\$&") + ")", "gm"),
904
- `$1<img src="https://image.jeuxvideo.com/smileys_img/${mapping[1]}.gif" alt="${mapping[0]}"/>`
905
- ];
906
- })
907
- ];
908
- function injectHTML(input2) {
909
- do {
910
- for (const [regex, htmlOrFunc] of jvcodeMap) {
911
- if (htmlOrFunc instanceof Function) {
912
- input2 = htmlOrFunc(regex, input2);
913
- } else {
914
- input2 = input2.replace(regex, htmlOrFunc);
915
- }
916
- }
917
- } while (false);
918
- return input2;
919
- }
920
- function escapeHtml(unsafe) {
921
- return unsafe.replace(/&/g, "&amp;").replace(/</g, "&lt;").replace(/>/g, "&gt;").replace(/"/g, "&quot;").replace(/'/g, "&#039;");
922
- }
923
- function Topic(props) {
924
- console.log(props.topic);
925
- return /* @__PURE__ */ u$1("div", { children: [
926
- props.topic.posts.map((post2) => /* @__PURE__ */ u$1(Post, { post: post2 })),
927
- /* @__PURE__ */ u$1("div", { children: [
928
- /* @__PURE__ */ u$1("h2", { children: "Ajout de posts" }),
929
- /* @__PURE__ */ u$1("div", { className: style$3.generationSettings, children: /* @__PURE__ */ u$1(FormGroup, { children: [
930
- /* @__PURE__ */ u$1("label", { htmlFor: "postCount", children: "Nombre de posts" }),
931
- /* @__PURE__ */ u$1(
932
- Slider,
933
- {
934
- name: "postCount",
935
- value: props.settings.postCount,
936
- onChange: (v2) => props.setSettings({ ...props.settings, postCount: v2 }),
937
- min: 1,
938
- max: 10,
939
- step: 1
940
- }
941
- )
942
- ] }) }),
943
- /* @__PURE__ */ u$1(
944
- Button,
945
- {
946
- onClick: () => props.addPosts(props.topic.id, props.settings.postCount),
947
- secondary: true,
948
- loading: props.pendingGeneration,
949
- children: "Générer"
950
- }
951
- )
952
- ] }),
953
- /* @__PURE__ */ u$1("hr", {})
954
- ] });
955
- }
956
- function Post(props) {
957
- return /* @__PURE__ */ u$1("div", { className: style$3.post, children: [
958
- /* @__PURE__ */ u$1("div", { className: style$3.postHeader, children: [
959
- /* @__PURE__ */ u$1("img", { src: "https://image.jeuxvideo.com/avatar-sm/default.jpg", className: style$3.avatar, alt: "ahi" }),
960
- /* @__PURE__ */ u$1("div", { className: style$3.user, children: props.post.user }),
961
- /* @__PURE__ */ u$1("div", { className: style$3.date, children: iso8601ToFrench(props.post.date) })
962
- ] }),
963
- /* @__PURE__ */ u$1(Preview, { raw: props.post.content })
964
- ] });
965
- }
966
- const wrapper = "_wrapper_1dmrl_1";
967
- const icon = "_icon_1dmrl_6";
968
- const input = "_input_1dmrl_14";
969
- const style$1 = {
970
- wrapper,
971
- icon,
972
- input
973
- };
974
- const Input = ({
975
- type,
976
- icon: icon2,
977
- value,
978
- placeholder,
979
- onChange,
980
- className,
981
- disabled: disabled2,
982
- id,
983
- name
984
- }) => {
985
- const [focused, setFocused] = h(false);
986
- const inputClass = cn(style$1.input, "generic-input", className, {
987
- focused,
988
- disabled: disabled2
989
- });
990
- const handleInputChange = (event) => {
991
- console.log("handleInputChange");
992
- const target = event.target;
993
- onChange(type === "number" ? parseFloat(target.value) || 0 : target.value);
994
- };
995
- const Icon = icon2;
996
- return /* @__PURE__ */ u$1("div", { className: style$1.wrapper, children: [
997
- /* @__PURE__ */ u$1(Icon, { className: style$1.icon, size: 18 }),
998
- /* @__PURE__ */ u$1(
999
- "input",
1000
- {
1001
- title: "Le pseudo doit avoir une longueur comprise entre 3 et 15 caractères.",
1002
- type,
1003
- id,
1004
- name,
1005
- value,
1006
- placeholder,
1007
- onInput: handleInputChange,
1008
- className: inputClass,
1009
- disabled: disabled2,
1010
- onFocus: () => setFocused(true),
1011
- onBlur: () => setFocused(false)
1012
- }
1013
- )
1014
- ] });
1015
- };
1016
- const Link = (props) => {
1017
- const color = props.color || "currentColor";
1018
- const size = props.size || 24;
1019
- delete props.color;
1020
- delete props.size;
1021
- return g(
1022
- "svg",
1023
- Object.assign({ xmlns: "http://www.w3.org/2000/svg", width: size, height: size, viewBox: "0 0 24 24", fill: "none", stroke: color, "stroke-width": "2", "stroke-linecap": "round", "stroke-linejoin": "round" }, props),
1024
- g("path", { d: "M10 13a5 5 0 0 0 7.54.54l3-3a5 5 0 0 0-7.07-7.07l-1.72 1.71" }),
1025
- g("path", { d: "M14 11a5 5 0 0 0-7.54-.54l-3 3a5 5 0 0 0 7.07 7.07l1.71-1.71" })
1026
- );
1027
- };
1028
- const Settings$1 = (props) => {
1029
- const color = props.color || "currentColor";
1030
- const size = props.size || 24;
1031
- delete props.color;
1032
- delete props.size;
1033
- return g(
1034
- "svg",
1035
- Object.assign({ xmlns: "http://www.w3.org/2000/svg", width: size, height: size, viewBox: "0 0 24 24", fill: "none", stroke: color, "stroke-width": "2", "stroke-linecap": "round", "stroke-linejoin": "round" }, props),
1036
- g("circle", { cx: "12", cy: "12", r: "3" }),
1037
- g("path", { d: "M19.4 15a1.65 1.65 0 0 0 .33 1.82l.06.06a2 2 0 0 1 0 2.83 2 2 0 0 1-2.83 0l-.06-.06a1.65 1.65 0 0 0-1.82-.33 1.65 1.65 0 0 0-1 1.51V21a2 2 0 0 1-2 2 2 2 0 0 1-2-2v-.09A1.65 1.65 0 0 0 9 19.4a1.65 1.65 0 0 0-1.82.33l-.06.06a2 2 0 0 1-2.83 0 2 2 0 0 1 0-2.83l.06-.06a1.65 1.65 0 0 0 .33-1.82 1.65 1.65 0 0 0-1.51-1H3a2 2 0 0 1-2-2 2 2 0 0 1 2-2h.09A1.65 1.65 0 0 0 4.6 9a1.65 1.65 0 0 0-.33-1.82l-.06-.06a2 2 0 0 1 0-2.83 2 2 0 0 1 2.83 0l.06.06a1.65 1.65 0 0 0 1.82.33H9a1.65 1.65 0 0 0 1-1.51V3a2 2 0 0 1 2-2 2 2 0 0 1 2 2v.09a1.65 1.65 0 0 0 1 1.51 1.65 1.65 0 0 0 1.82-.33l.06-.06a2 2 0 0 1 2.83 0 2 2 0 0 1 0 2.83l-.06.06a1.65 1.65 0 0 0-.33 1.82V9a1.65 1.65 0 0 0 1.51 1H21a2 2 0 0 1 2 2 2 2 0 0 1-2 2h-.09a1.65 1.65 0 0 0-1.51 1z" })
1038
- );
1039
- };
1040
- function Settings(props) {
1041
- return /* @__PURE__ */ u$1("div", { children: /* @__PURE__ */ u$1("form", { children: [
1042
- /* @__PURE__ */ u$1(FormGroup, { children: [
1043
- /* @__PURE__ */ u$1("label", { htmlFor: "api", children: "API" }),
1044
- /* @__PURE__ */ u$1(
1045
- Input,
1046
- {
1047
- type: "text",
1048
- placeholder: "URl d'API ex: https://ouruq7zepnehg2-5000.proxy.runpod.net/",
1049
- icon: Link,
1050
- value: props.settings.apiURL,
1051
- onChange: (v2) => props.setSettings({ ...props.settings, apiURL: v2 })
1052
- }
1053
- )
1054
- ] }),
1055
- /* @__PURE__ */ u$1(FormGroup, { children: [
1056
- /* @__PURE__ */ u$1("label", { for: "temperature", children: "Temperature" }),
1057
- /* @__PURE__ */ u$1(
1058
- Slider,
1059
- {
1060
- name: "temperature",
1061
- value: props.settings.temperature,
1062
- onChange: (v2) => props.setSettings({ ...props.settings, temperature: v2 }),
1063
- min: 0.1,
1064
- max: 2,
1065
- step: 0.1
1066
- }
1067
- )
1068
- ] }),
1069
- /* @__PURE__ */ u$1("div", { children: /* @__PURE__ */ u$1(
1070
- Button,
1071
- {
1072
- onClick: () => {
1073
- props.resetApp();
1074
- },
1075
- secondary: true,
1076
- title: "Tout réinitialiser",
1077
- children: "Réinitialiser"
1078
- }
1079
- ) }),
1080
- /* @__PURE__ */ u$1("br", {}),
1081
- /* @__PURE__ */ u$1("div", { children: /* @__PURE__ */ u$1(
1082
- Button,
1083
- {
1084
- onClick: () => {
1085
- history.go(-1);
1086
- },
1087
- children: "Retour"
1088
- }
1089
- ) })
1090
- ] }) });
1091
- }
1092
- const breadcrumbs = "_breadcrumbs_145yl_1";
1093
- const actions = "_actions_145yl_10";
1094
- const style = {
1095
- breadcrumbs,
1096
- actions
1097
- };
1098
- function Layout(props) {
1099
- return /* @__PURE__ */ u$1("div", { children: [
1100
- /* @__PURE__ */ u$1("nav", { className: style.breadcrumbs, children: [
1101
- props.breadcrumbs,
1102
- /* @__PURE__ */ u$1("div", { className: style.actions, children: /* @__PURE__ */ u$1("a", { href: "#", title: "Paramètres", onClick: (e2) => {
1103
- e2.preventDefault();
1104
- props.setRoute(routes.settings);
1105
- }, children: /* @__PURE__ */ u$1(Settings$1, { size: 18 }) }) })
1106
- ] }),
1107
- /* @__PURE__ */ u$1("h2", { children: props.title }),
1108
- props.children
1109
- ] });
1110
- }
1111
- const itemKey = "settings";
1112
- const defaultSettings = {
1113
- apiURL: "http://localhost:5000",
1114
- temperature: 0.9,
1115
- postCount: 3
1116
- };
1117
- function fetchSettings() {
1118
- const storedSettings = localStorage.getItem(itemKey);
1119
- if (storedSettings) {
1120
- return { ...defaultSettings, ...JSON.parse(storedSettings) };
1121
- } else {
1122
- return defaultSettings;
1123
- }
1124
- }
1125
- function saveSettings(settings) {
1126
- localStorage.setItem(itemKey, JSON.stringify(settings));
1127
- }
1128
- function resetSettings() {
1129
- localStorage.removeItem(itemKey);
1130
- }
1131
- function generateUUID() {
1132
- return "10000000-1000-4000-8000-100000000000".replace(
1133
- /[018]/g,
1134
- (c2) => (+c2 ^ crypto.getRandomValues(new Uint8Array(1))[0] & 15 >> +c2 / 4).toString(16)
1135
- );
1136
- }
1137
- const titleRegex = /Sujet\s+:\s+"(.+?)"?<\|eot_id\|>/;
1138
- const userRegex = /<\|im_pseudo\|>([^<]+)<\|end_pseudo\|>/;
1139
- const dateRegex = /<\|im_date\|>([^<]+)<\|end_date\|>/;
1140
- const contentRegex = /<\|begin_of_post\|>([\s\S]+)(?:<\|end_of_post\|>)?$/;
1141
- function tokensToTopic(tokens) {
1142
- const topic = {
1143
- id: generateUUID(),
1144
- title: "",
1145
- posts: []
1146
- };
1147
- for (const postTokens of tokens.split("<|end_of_post|>").slice(0, -1)) {
1148
- console.log("Post tokens:");
1149
- console.log(postTokens);
1150
- if (topic.posts.length < 1) {
1151
- const titleMatch = postTokens.match(titleRegex);
1152
- console.log(`title: ${titleMatch[1]}`);
1153
- topic.title = titleMatch[1];
1154
- }
1155
- topic.posts = topic.posts.concat(tokensToPosts(postTokens));
1156
- }
1157
- return topic;
1158
- }
1159
- function tokensToPosts(tokens) {
1160
- const posts = [];
1161
- for (const postTokens of tokens.split("<|end_of_post|>")) {
1162
- if (postTokens.length < 1) {
1163
- continue;
1164
- }
1165
- console.log("Post tokens:");
1166
- console.log(postTokens);
1167
- const userMatch = postTokens.match(userRegex);
1168
- console.log(`user: ${userMatch[1]}`);
1169
- const dateMatch = postTokens.match(dateRegex);
1170
- console.log(`date: ${dateMatch[1]}`);
1171
- const contentMatch = postTokens.match(contentRegex);
1172
- console.log(`content: ${contentMatch[1]}`);
1173
- posts.push({
1174
- user: userMatch[1],
1175
- date: frenchToIso8601(dateMatch[1]),
1176
- content: contentMatch[1]
1177
- });
1178
- }
1179
- return posts;
1180
- }
1181
- function tokenizeTopic(topic) {
1182
- if (topic.posts.length === 0) {
1183
- throw new Error("Topic must have at least one post");
1184
- }
1185
- const tokenizedPosts = topic.posts.map((post2) => tokenizePost(post2, topic.posts[0].user)).flat().join("");
1186
- let lines = [
1187
- "<|start_header_id|><|sujet|><|end_header_id|>",
1188
- "",
1189
- `Sujet : "${topic.title}"`
1190
- ];
1191
- return lines.join("\n") + tokenizedPosts;
1192
- }
1193
- function tokenizePost(post2, poster) {
1194
- let lines = [
1195
- `<|eot_id|><|start_header_id|><|${post2.user === poster ? "autheur" : "khey"}|>`,
1196
- "<|end_header_id|>",
1197
- "",
1198
- `<|im_pseudo|>${post2.user}<|end_pseudo|>`,
1199
- `<|im_date|>Le ${iso8601ToFrench(post2.date)}<|end_date|>`,
1200
- "",
1201
- `<|begin_of_post|>${post2.content}<|end_of_post|>`
1202
- ];
1203
- return lines.join("\n");
1204
- }
1205
- async function generateTopic(settings, nPosts) {
1206
- console.log(settings);
1207
- const rawOutput = await fetApiWithStream(settings, "<|start_header_id|>", nPosts);
1208
- return tokensToTopic(rawOutput);
1209
- }
1210
- async function generatePosts(settings, nPosts, topic) {
1211
- const rawOutput = await fetApiWithStream(settings, tokenizeTopic(topic), nPosts);
1212
- console.log("rawOutput");
1213
- console.log(rawOutput);
1214
- return tokensToPosts(rawOutput);
1215
- }
1216
- const postEndToken = "<|end_of_post|>";
1217
- async function fetApiWithStream(settings, prompt, nPosts) {
1218
- const controller = new AbortController();
1219
- const response = await fetch(new URL("/v1/completions", settings.apiURL), {
1220
- method: "POST",
1221
- headers: {
1222
- "Content-Type": "application/json"
1223
- },
1224
- body: JSON.stringify({
1225
- prompt,
1226
- temperature: settings.temperature,
1227
- max_tokens: 2e3,
1228
- stream: true,
1229
- skip_special_tokens: false
1230
- // stop: "<|end_of_post|>"
1231
- // top_p: 1,
1232
- // frequency_penalty: 0,
1233
- // presence_penalty: 0,
1234
- }),
1235
- signal: controller.signal
1236
- });
1237
- if (!response.ok) {
1238
- throw new Error(`Failed to fetch API (${response.status} ${response.statusText}): ${await response.text()}`);
1239
- }
1240
- console.log(`Fetching topic with ${nPosts} posts...`);
1241
- let endTokenCount = 0;
1242
- let tokens = "";
1243
- let finishReason = null;
1244
- try {
1245
- await response.body.pipeThrough(new TextDecoderStream("utf-8")).pipeTo(new WritableStream({
1246
- write(rawChunk) {
1247
- for (const rawChunkLine of rawChunk.split("\n")) {
1248
- if (!rawChunkLine.startsWith("data:")) continue;
1249
- const chunk = JSON.parse(rawChunkLine.slice(6));
1250
- const text = chunk.choices[0].text;
1251
- console.log(text);
1252
- tokens += chunk.choices[0].text;
1253
- if (text.includes(postEndToken)) {
1254
- endTokenCount++;
1255
- if (endTokenCount >= nPosts) {
1256
- finishReason = "custom_stop";
1257
- controller.abort();
1258
- break;
1259
- }
1260
- } else {
1261
- finishReason = chunk.choices[0].finish_reason;
1262
- }
1263
- }
1264
- }
1265
- }));
1266
- } catch (e2) {
1267
- if (e2.name !== "AbortError") {
1268
- throw e2;
1269
- }
1270
- }
1271
- console.log("Done fetching data");
1272
- console.log(`Finish reason: ${finishReason}`);
1273
- console.log(`Tokens: ${tokens}`);
1274
- return tokens;
1275
- }
1276
- function App() {
1277
- const [route, _setRoute] = h(routes.home);
1278
- const [page, setPage] = h(0);
1279
- const [topicId, setTopicId] = h(null);
1280
- const [topics, setTopics] = h(loadTopics);
1281
- const [latestGeneratedTopicId, setLatestGeneratedTopicId] = h(null);
1282
- const [pendingGeneration, setPendingGeneration] = h(false);
1283
- y(() => {
1284
- console.log("save !");
1285
- saveTopics(topics);
1286
- }, [topics]);
1287
- const _generateTopic = async (postsCount) => {
1288
- setPendingGeneration(true);
1289
- const topic = await generateTopic(settings, postsCount);
1290
- setLatestGeneratedTopicId(topic.id);
1291
- setTopics((topics2) => [...topics2, topic]);
1292
- setPendingGeneration(false);
1293
- };
1294
- const addPosts = async (topicId2, postsCount) => {
1295
- setPendingGeneration(true);
1296
- const posts = await generatePosts(settings, postsCount, topics.find((t2) => t2.id === topicId2));
1297
- const newTopics = [...topics];
1298
- const foundIndex = newTopics.findIndex((t2) => t2.id === topicId2);
1299
- newTopics[foundIndex].posts = newTopics[foundIndex].posts.concat(posts);
1300
- setTopics(newTopics);
1301
- setPendingGeneration(false);
1302
- };
1303
- const [settings, setSettings] = h(fetchSettings);
1304
- y(() => {
1305
- saveSettings(settings);
1306
- }, [settings]);
1307
- const resetApp = () => {
1308
- resetSettings();
1309
- setSettings(fetchSettings);
1310
- setTopics([]);
1311
- };
1312
- const updateRoute = q(() => {
1313
- const url = new URL(window.location.href);
1314
- const route2 = url.searchParams.get("route");
1315
- if (route2 && route2 in routes) {
1316
- _setRoute(route2);
1317
- }
1318
- const page2 = url.searchParams.get("page");
1319
- if (page2) {
1320
- setPage(parseInt(page2));
1321
- }
1322
- const id = url.searchParams.get("id");
1323
- if (id) {
1324
- setTopicId(id);
1325
- }
1326
- }, []);
1327
- y(() => {
1328
- updateRoute();
1329
- }, []);
1330
- y(() => {
1331
- function listener() {
1332
- updateRoute();
1333
- }
1334
- window.addEventListener("popstate", listener);
1335
- return () => {
1336
- window.removeEventListener("popstate", listener);
1337
- };
1338
- }, []);
1339
- const setRoute = q((route2, page2, id) => {
1340
- const url = new URL(window.location.href);
1341
- url.searchParams.set("route", route2);
1342
- _setRoute(route2);
1343
- if (page2 !== void 0) {
1344
- url.searchParams.set("page", String(page2));
1345
- setPage(page2);
1346
- } else {
1347
- url.searchParams.delete("page");
1348
- setPage(0);
1349
- }
1350
- if (id !== void 0) {
1351
- url.searchParams.set("id", id);
1352
- setTopicId(id);
1353
- } else {
1354
- url.searchParams.delete("id");
1355
- setTopicId(null);
1356
- }
1357
- const newUrl = url.toString();
1358
- if (newUrl !== window.location.href) {
1359
- window.history.pushState({}, "", newUrl);
1360
- }
1361
- }, []);
1362
- let routeComponent = void 0;
1363
- let breadcrumbs2 = void 0;
1364
- let title = void 0;
1365
- switch (route) {
1366
- case routes.home:
1367
- routeComponent = /* @__PURE__ */ u$1(
1368
- Topics,
1369
- {
1370
- topics,
1371
- setRoute,
1372
- settings,
1373
- setSettings,
1374
- generateTopic: _generateTopic,
1375
- pendingGeneration,
1376
- latestGeneratedTopicId
1377
- }
1378
- );
1379
- breadcrumbs2 = "accueil";
1380
- title = "Liste des sujets";
1381
- break;
1382
- case routes.topic:
1383
- if (topicId === null) {
1384
- routeComponent = /* @__PURE__ */ u$1("div", { children: "Impossible d'afficher le sujet" });
1385
- breadcrumbs2 = "accueil";
1386
- title = "Sujet";
1387
- } else {
1388
- if (topics === null) {
1389
- routeComponent = /* @__PURE__ */ u$1("div", { children: "Chargement..." });
1390
- breadcrumbs2 = `accueil / sujet`;
1391
- title = `Chargement...`;
1392
- } else {
1393
- const topic = topics.find((t2) => t2.id === topicId);
1394
- routeComponent = /* @__PURE__ */ u$1(
1395
- Topic,
1396
- {
1397
- topic,
1398
- settings,
1399
- setSettings,
1400
- addPosts,
1401
- pendingGeneration
1402
- }
1403
- );
1404
- breadcrumbs2 = `accueil / ${topic.title}`;
1405
- title = `Sujet : ${topic.title}`;
1406
- }
1407
- }
1408
- break;
1409
- case routes.settings:
1410
- routeComponent = /* @__PURE__ */ u$1(Settings, { settings, setSettings, resetApp });
1411
- breadcrumbs2 = "accueil / paramètres";
1412
- title = "Paramètres";
1413
- break;
1414
- }
1415
- return /* @__PURE__ */ u$1(k$1, { children: [
1416
- /* @__PURE__ */ u$1("header", { className: style$a.header, children: /* @__PURE__ */ u$1(Container, { children: /* @__PURE__ */ u$1("h1", { className: style$a.logo, children: /* @__PURE__ */ u$1("a", { href: "#", onClick: (e2) => {
1417
- e2.preventDefault();
1418
- setRoute(routes.home);
1419
- }, children: "JVCGPT" }) }) }) }),
1420
- /* @__PURE__ */ u$1("main", { children: /* @__PURE__ */ u$1(Container, { children: /* @__PURE__ */ u$1(
1421
- Layout,
1422
- {
1423
- breadcrumbs: breadcrumbs2,
1424
- title,
1425
- setRoute,
1426
- children: routeComponent
1427
- }
1428
- ) }) })
1429
- ] });
1430
- }
1431
- D$1(g(App, null), document.getElementById("app"));
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
dist/favicon.svg DELETED
dist/index.html DELETED
@@ -1,15 +0,0 @@
1
- <!DOCTYPE html>
2
- <html lang="fr">
3
- <head>
4
- <meta charset="UTF-8"/>
5
- <link rel="icon" type="image/svg+xml" href="./favicon.svg"/>
6
- <meta name="viewport" content="width=device-width, initial-scale=1.0"/>
7
- <meta name="color-scheme" content="dark"/>
8
- <title>JVCGPT</title>
9
- <script type="module" crossorigin src="./assets/index-NR4DZ1UN.js"></script>
10
- <link rel="stylesheet" crossorigin href="./assets/index-BhbZavTP.css">
11
- </head>
12
- <body>
13
- <div id="app"></div>
14
- </body>
15
- </html>