Greums commited on
Commit
6673d34
·
1 Parent(s): 0e08884

disable minify

Browse files
dist/assets/index-C9o3CIT4.js ADDED
@@ -0,0 +1,1414 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
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 rangeSlider = "_rangeSlider_1trvf_1";
624
+ const rangeSlider__values = "_rangeSlider__values_1trvf_99";
625
+ const progress = "_progress_1trvf_116";
626
+ const style$4 = {
627
+ rangeSlider,
628
+ rangeSlider__values,
629
+ progress
630
+ };
631
+ function Slider(props) {
632
+ return /* @__PURE__ */ u$1("div", { className: style$4.rangeSlider, style: `--min:${props.min}; --max:${props.max}; --step:${props.step}; --value:${props.value}; --text-value:"${props.value}";`, children: [
633
+ /* @__PURE__ */ u$1(
634
+ "input",
635
+ {
636
+ name: props.name,
637
+ type: "range",
638
+ min: props.min,
639
+ max: props.max,
640
+ step: props.step,
641
+ value: props.value,
642
+ onInput: (e2) => props.onChange(Number(e2.target.value))
643
+ }
644
+ ),
645
+ /* @__PURE__ */ u$1("output", {}),
646
+ /* @__PURE__ */ u$1("div", { className: style$4.progress })
647
+ ] });
648
+ }
649
+ function Topics(props) {
650
+ const sortedTopics = T(() => {
651
+ if (props.topics === null || props.topics.length < 1) {
652
+ return props.topics;
653
+ }
654
+ return props.topics.sort((topicA, topicB) => {
655
+ if (topicA.posts.length < 1 || topicB.posts.length < 1) {
656
+ return 0;
657
+ }
658
+ return topicB.posts[topicB.posts.length - 1].date.localeCompare(topicA.posts[topicA.posts.length - 1].date);
659
+ });
660
+ }, [props.topics]);
661
+ return /* @__PURE__ */ u$1("div", { children: [
662
+ sortedTopics === null ? /* @__PURE__ */ u$1(Spinner, { className: style$7.spinner }) : /* @__PURE__ */ u$1(
663
+ List,
664
+ {
665
+ topics: sortedTopics,
666
+ setRoute: props.setRoute,
667
+ latestGeneratedTopicId: props.latestGeneratedTopicId
668
+ }
669
+ ),
670
+ /* @__PURE__ */ u$1("div", { children: [
671
+ /* @__PURE__ */ u$1("h2", { children: "Nouveau sujet" }),
672
+ /* @__PURE__ */ u$1("div", { className: style$7.generationSettings, children: /* @__PURE__ */ u$1(FormGroup, { children: [
673
+ /* @__PURE__ */ u$1("label", { for: "postCount", children: "Nombre de posts" }),
674
+ /* @__PURE__ */ u$1(
675
+ Slider,
676
+ {
677
+ name: "postCount",
678
+ value: props.settings.postCount,
679
+ onChange: (v2) => props.setSettings({ ...props.settings, postCount: v2 }),
680
+ min: 1,
681
+ max: 10,
682
+ step: 1
683
+ }
684
+ )
685
+ ] }) }),
686
+ /* @__PURE__ */ u$1(
687
+ Button,
688
+ {
689
+ onClick: () => props.generateTopic(props.settings.postCount),
690
+ secondary: true,
691
+ loading: props.pendingGeneration,
692
+ children: "Générer"
693
+ }
694
+ )
695
+ ] }),
696
+ /* @__PURE__ */ u$1("hr", {})
697
+ ] });
698
+ }
699
+ function List(props) {
700
+ return /* @__PURE__ */ u$1("ul", { className: style$7.list, children: [
701
+ /* @__PURE__ */ u$1("li", { className: style$7.head, children: [
702
+ /* @__PURE__ */ u$1("span", { children: "Sujet" }),
703
+ /* @__PURE__ */ u$1("span", { children: "Auteur" }),
704
+ /* @__PURE__ */ u$1("span", { children: "NB" }),
705
+ /* @__PURE__ */ u$1("span", { children: "Dernier msg" })
706
+ ] }),
707
+ props.topics.length < 1 && /* @__PURE__ */ u$1("li", { children: [
708
+ /* @__PURE__ */ u$1("span", { children: "Aucun sujet" }),
709
+ /* @__PURE__ */ u$1("span", {}),
710
+ /* @__PURE__ */ u$1("span", {}),
711
+ /* @__PURE__ */ u$1("span", {})
712
+ ] }),
713
+ props.topics.map((topic) => /* @__PURE__ */ u$1("li", { className: cn({ [style$7.highlight]: topic.id === props.latestGeneratedTopicId }), children: [
714
+ /* @__PURE__ */ u$1("span", { children: /* @__PURE__ */ u$1("a", { href: "#", onClick: (e2) => {
715
+ e2.preventDefault();
716
+ props.setRoute(routes.topic, 0, topic.id);
717
+ }, children: topic.title }) }),
718
+ /* @__PURE__ */ u$1("span", { children: topic.posts[0].user }),
719
+ /* @__PURE__ */ u$1("span", { children: topic.posts.length }),
720
+ /* @__PURE__ */ u$1("span", { children: iso8601ToFrench(topic.posts[topic.posts.length - 1].date) })
721
+ ] }))
722
+ ] });
723
+ }
724
+ const post = "_post_uuidr_1";
725
+ const postHeader = "_postHeader_uuidr_12";
726
+ const avatar = "_avatar_uuidr_23";
727
+ const user = "_user_uuidr_31";
728
+ const date = "_date_uuidr_39";
729
+ const generationSettings = "_generationSettings_uuidr_46";
730
+ const style$3 = {
731
+ post,
732
+ postHeader,
733
+ avatar,
734
+ user,
735
+ date,
736
+ generationSettings
737
+ };
738
+ const wrapper$1 = "_wrapper_cfqzy_1";
739
+ const style$2 = {
740
+ wrapper: wrapper$1
741
+ };
742
+ const smileysMap = [
743
+ [":)", "1"],
744
+ // https://image.jeuxvideo.com/smileys_img/1.gif
745
+ [":snif:", "20"],
746
+ [":gba:", "17"],
747
+ [":g)", "3"],
748
+ [":-)", "46"],
749
+ [":snif2:", "13"],
750
+ [":bravo:", "69"],
751
+ [":d)", "4"],
752
+ [":hap:", "18"],
753
+ [":ouch:", "22"],
754
+ [":pacg:", "9"],
755
+ [":cd:", "5"],
756
+ [":-)))", "23"],
757
+ [":ouch2:", "57"],
758
+ [":pacd:", "10"],
759
+ [":cute:", "nyu"],
760
+ [":content:", "24"],
761
+ [":p)", "7"],
762
+ [":-p", "31"],
763
+ [":noel:", "11"],
764
+ [":oui:", "37"],
765
+ [":(", "45"],
766
+ [":peur:", "47"],
767
+ [":question:", "2"],
768
+ [":cool:", "26"],
769
+ [":-(", "14"],
770
+ [":coeur:", "54"],
771
+ [":mort:", "21"],
772
+ [":rire:", "39"],
773
+ [":-((", "15"],
774
+ [":fou:", "50"],
775
+ [":sleep:", "27"],
776
+ [":-D", "40"],
777
+ [":nonnon:", "25"],
778
+ [":fier:", "53"],
779
+ [":honte:", "30"],
780
+ [":rire2:", "41"],
781
+ [":non2:", "33"],
782
+ [":sarcastic:", "43"],
783
+ [":monoeil:", "34"],
784
+ [":o))", "12"],
785
+ [":nah:", "19"],
786
+ [":doute:", "28"],
787
+ [":rouge:", "55"],
788
+ [":ok:", "36"],
789
+ [":non:", "35"],
790
+ [":malade:", "8"],
791
+ [":fete:", "66"],
792
+ [":sournois:", "67"],
793
+ [":hum:", "68"],
794
+ [":ange:", "60"],
795
+ [":diable:", "61"],
796
+ [":gni:", "62"],
797
+ [":play:", "play"],
798
+ [":desole:", "65"],
799
+ [":spoiler:", "63"],
800
+ [":merci:", "58"],
801
+ [":svp:", "59"],
802
+ [":sors:", "56"],
803
+ [":salut:", "42"],
804
+ [":rechercher:", "38"],
805
+ [":hello:", "29"],
806
+ [":up:", "44"],
807
+ [":bye:", "48"],
808
+ [":gne:", "51"],
809
+ [":lol:", "32"],
810
+ [":dpdr:", "49"],
811
+ [":dehors:", "52"],
812
+ [":hs:", "64"],
813
+ [":banzai:", "70"],
814
+ [":bave:", "71"],
815
+ [":pf:", "pf"],
816
+ [":cimer:", "cimer"],
817
+ [":ddb:", "ddb"],
818
+ [":pave:", "pave"],
819
+ [":objection:", "objection"],
820
+ [":siffle:", "siffle"]
821
+ ];
822
+ function Preview(props) {
823
+ const html = T(() => {
824
+ const escaped = escapeHtml(props.raw);
825
+ return injectHTML(escaped).replace(/\n/g, "<br/>");
826
+ }, [props.raw]);
827
+ return /* @__PURE__ */ u$1("div", { className: style$2.wrapper, dangerouslySetInnerHTML: { __html: html } });
828
+ }
829
+ const jvcodeMap = [
830
+ // [/(https?:\/\/image\.noelshack\.com\/\S+)/g]: "<img width=\"68\" height=\"51\" alt=\"noelshak\" src=\"$1\"/>"
831
+ [
832
+ // Stickers
833
+ /(^| )https?:\/\/image\.noelshack\.com\/(?:fichiers|minis)(\S+)/gm,
834
+ '$1<img width="68" height="51" alt="noelshak" src="https://image.noelshack.com/minis/$2"/>'
835
+ ],
836
+ [
837
+ // Vocaroo
838
+ /(^| )https:\/\/vocaroo.com\/(.+)/gm,
839
+ '$1<div><iframe width="300" height="60" src="https://vocaroo.com/embed/$2?autoplay=0" frameborder="0" allow="autoplay"></iframe></div>'
840
+ ],
841
+ [
842
+ // Citations
843
+ /^(?:&gt;.*(?:\n&gt;.*)*)/g,
844
+ (reg, raw) => {
845
+ const match = reg.exec(raw);
846
+ if (!match) return raw;
847
+ console.log(match);
848
+ const index = match.index;
849
+ const length = match[0].length;
850
+ return raw.substring(0, index) + `<blockquote>${match[0].replace(/^&gt;/gm, "")}</blockquote>` + raw.substring(index + length);
851
+ }
852
+ ],
853
+ [
854
+ // Spoil
855
+ /&lt;spoil&gt;(.*?)&lt;\/spoil&gt;/gm,
856
+ (reg, raw) => {
857
+ return raw.replace(reg, (_2, matched) => {
858
+ const randomId = (Math.random() + 1).toString(36).substring(2);
859
+ 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>`;
860
+ });
861
+ }
862
+ ],
863
+ [
864
+ // Regular links
865
+ /(^| )(https?:\/\/\S+)/gm,
866
+ '$1<a href="$2" target="_blank">$2</a>'
867
+ ],
868
+ // Generate regexes for smileys
869
+ // ...smileysMap.map((maping) => {
870
+ // return [new RegExp(
871
+ // Object.keys(smileysMap).map(s => (
872
+ // "(?:(?:^| )" + s.replace(/[.*+?^${}()|[\]\\]/g, '\\$&') + ")"
873
+ // )).join("|"), "gm"
874
+ // ), `<img src="${maping[1]}" width="16" height="16" alt=""/>`]
875
+ // })
876
+ // (() => {
877
+ // new RegExp(
878
+ // smileysMap.map((mapping) => (
879
+ // "(?:(?:^| )" + s.replace(/[.*+?^${}()|[\]\\]/g, '\\$&') + ")"
880
+ // )).join("|"), "gm"
881
+ // )
882
+ // return [/(https?:\/\/image\.noelshack\.com\/\S+)/g, "<img width=\"68\" height=\"51\" alt=\"noelshak\" src=\"$1\"/>"]
883
+ // })()
884
+ ...smileysMap.map((mapping) => {
885
+ return [
886
+ new RegExp("(?:(^| )" + mapping[0].replace(/[.*+?^${}()|[\]\\]/g, "\\$&") + ")", "gm"),
887
+ `$1<img src="https://image.jeuxvideo.com/smileys_img/${mapping[1]}.gif" alt="${mapping[0]}"/>`
888
+ ];
889
+ })
890
+ ];
891
+ function injectHTML(input2) {
892
+ do {
893
+ for (const [regex, htmlOrFunc] of jvcodeMap) {
894
+ if (htmlOrFunc instanceof Function) {
895
+ input2 = htmlOrFunc(regex, input2);
896
+ } else {
897
+ input2 = input2.replace(regex, htmlOrFunc);
898
+ }
899
+ }
900
+ } while (false);
901
+ return input2;
902
+ }
903
+ function escapeHtml(unsafe) {
904
+ return unsafe.replace(/&/g, "&amp;").replace(/</g, "&lt;").replace(/>/g, "&gt;").replace(/"/g, "&quot;").replace(/'/g, "&#039;");
905
+ }
906
+ function Topic(props) {
907
+ console.log(props.topic);
908
+ return /* @__PURE__ */ u$1("div", { children: [
909
+ props.topic.posts.map((post2) => /* @__PURE__ */ u$1(Post, { post: post2 })),
910
+ /* @__PURE__ */ u$1("div", { children: [
911
+ /* @__PURE__ */ u$1("h2", { children: "Ajout de posts" }),
912
+ /* @__PURE__ */ u$1("div", { className: style$3.generationSettings, children: /* @__PURE__ */ u$1(FormGroup, { children: [
913
+ /* @__PURE__ */ u$1("label", { htmlFor: "postCount", children: "Nombre de posts" }),
914
+ /* @__PURE__ */ u$1(
915
+ Slider,
916
+ {
917
+ name: "postCount",
918
+ value: props.settings.postCount,
919
+ onChange: (v2) => props.setSettings({ ...props.settings, postCount: v2 }),
920
+ min: 1,
921
+ max: 10,
922
+ step: 1
923
+ }
924
+ )
925
+ ] }) }),
926
+ /* @__PURE__ */ u$1(
927
+ Button,
928
+ {
929
+ onClick: () => props.addPosts(props.topic.id, props.settings.postCount),
930
+ secondary: true,
931
+ loading: props.pendingGeneration,
932
+ children: "Générer"
933
+ }
934
+ )
935
+ ] }),
936
+ /* @__PURE__ */ u$1("hr", {})
937
+ ] });
938
+ }
939
+ function Post(props) {
940
+ return /* @__PURE__ */ u$1("div", { className: style$3.post, children: [
941
+ /* @__PURE__ */ u$1("div", { className: style$3.postHeader, children: [
942
+ /* @__PURE__ */ u$1("img", { src: "https://image.jeuxvideo.com/avatar-sm/default.jpg", className: style$3.avatar, alt: "ahi" }),
943
+ /* @__PURE__ */ u$1("div", { className: style$3.user, children: props.post.user }),
944
+ /* @__PURE__ */ u$1("div", { className: style$3.date, children: iso8601ToFrench(props.post.date) })
945
+ ] }),
946
+ /* @__PURE__ */ u$1(Preview, { raw: props.post.content })
947
+ ] });
948
+ }
949
+ const wrapper = "_wrapper_1dmrl_1";
950
+ const icon = "_icon_1dmrl_6";
951
+ const input = "_input_1dmrl_14";
952
+ const style$1 = {
953
+ wrapper,
954
+ icon,
955
+ input
956
+ };
957
+ const Input = ({
958
+ type,
959
+ icon: icon2,
960
+ value,
961
+ placeholder,
962
+ onChange,
963
+ className,
964
+ disabled: disabled2,
965
+ id,
966
+ name
967
+ }) => {
968
+ const [focused, setFocused] = h(false);
969
+ const inputClass = cn(style$1.input, "generic-input", className, {
970
+ focused,
971
+ disabled: disabled2
972
+ });
973
+ const handleInputChange = (event) => {
974
+ console.log("handleInputChange");
975
+ const target = event.target;
976
+ onChange(type === "number" ? parseFloat(target.value) || 0 : target.value);
977
+ };
978
+ const Icon = icon2;
979
+ return /* @__PURE__ */ u$1("div", { className: style$1.wrapper, children: [
980
+ /* @__PURE__ */ u$1(Icon, { className: style$1.icon, size: 18 }),
981
+ /* @__PURE__ */ u$1(
982
+ "input",
983
+ {
984
+ title: "Le pseudo doit avoir une longueur comprise entre 3 et 15 caractères.",
985
+ type,
986
+ id,
987
+ name,
988
+ value,
989
+ placeholder,
990
+ onInput: handleInputChange,
991
+ className: inputClass,
992
+ disabled: disabled2,
993
+ onFocus: () => setFocused(true),
994
+ onBlur: () => setFocused(false)
995
+ }
996
+ )
997
+ ] });
998
+ };
999
+ const Link = (props) => {
1000
+ const color = props.color || "currentColor";
1001
+ const size = props.size || 24;
1002
+ delete props.color;
1003
+ delete props.size;
1004
+ return g(
1005
+ "svg",
1006
+ 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),
1007
+ 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" }),
1008
+ 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" })
1009
+ );
1010
+ };
1011
+ const Settings$1 = (props) => {
1012
+ const color = props.color || "currentColor";
1013
+ const size = props.size || 24;
1014
+ delete props.color;
1015
+ delete props.size;
1016
+ return g(
1017
+ "svg",
1018
+ 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),
1019
+ g("circle", { cx: "12", cy: "12", r: "3" }),
1020
+ 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" })
1021
+ );
1022
+ };
1023
+ function Settings(props) {
1024
+ return /* @__PURE__ */ u$1("div", { children: /* @__PURE__ */ u$1("form", { children: [
1025
+ /* @__PURE__ */ u$1(FormGroup, { children: [
1026
+ /* @__PURE__ */ u$1("label", { htmlFor: "api", children: "API" }),
1027
+ /* @__PURE__ */ u$1(
1028
+ Input,
1029
+ {
1030
+ type: "text",
1031
+ placeholder: "URl d'API ex: https://ouruq7zepnehg2-5000.proxy.runpod.net/",
1032
+ icon: Link,
1033
+ value: props.settings.apiURL,
1034
+ onChange: (v2) => props.setSettings({ ...props.settings, apiURL: v2 })
1035
+ }
1036
+ )
1037
+ ] }),
1038
+ /* @__PURE__ */ u$1(FormGroup, { children: [
1039
+ /* @__PURE__ */ u$1("label", { for: "temperature", children: "Temperature" }),
1040
+ /* @__PURE__ */ u$1(
1041
+ Slider,
1042
+ {
1043
+ name: "temperature",
1044
+ value: props.settings.temperature,
1045
+ onChange: (v2) => props.setSettings({ ...props.settings, temperature: v2 }),
1046
+ min: 0.1,
1047
+ max: 2,
1048
+ step: 0.1
1049
+ }
1050
+ )
1051
+ ] }),
1052
+ /* @__PURE__ */ u$1("div", { children: /* @__PURE__ */ u$1(
1053
+ Button,
1054
+ {
1055
+ onClick: () => {
1056
+ props.resetApp();
1057
+ },
1058
+ secondary: true,
1059
+ title: "Tout réinitialiser",
1060
+ children: "Réinitialiser"
1061
+ }
1062
+ ) }),
1063
+ /* @__PURE__ */ u$1("br", {}),
1064
+ /* @__PURE__ */ u$1("div", { children: /* @__PURE__ */ u$1(
1065
+ Button,
1066
+ {
1067
+ onClick: () => {
1068
+ history.go(-1);
1069
+ },
1070
+ children: "Retour"
1071
+ }
1072
+ ) })
1073
+ ] }) });
1074
+ }
1075
+ const breadcrumbs = "_breadcrumbs_145yl_1";
1076
+ const actions = "_actions_145yl_10";
1077
+ const style = {
1078
+ breadcrumbs,
1079
+ actions
1080
+ };
1081
+ function Layout(props) {
1082
+ return /* @__PURE__ */ u$1("div", { children: [
1083
+ /* @__PURE__ */ u$1("nav", { className: style.breadcrumbs, children: [
1084
+ props.breadcrumbs,
1085
+ /* @__PURE__ */ u$1("div", { className: style.actions, children: /* @__PURE__ */ u$1("a", { href: "#", title: "Paramètres", onClick: (e2) => {
1086
+ e2.preventDefault();
1087
+ props.setRoute(routes.settings);
1088
+ }, children: /* @__PURE__ */ u$1(Settings$1, { size: 18 }) }) })
1089
+ ] }),
1090
+ /* @__PURE__ */ u$1("h2", { children: props.title }),
1091
+ props.children
1092
+ ] });
1093
+ }
1094
+ const itemKey = "settings";
1095
+ const defaultSettings = {
1096
+ apiURL: "http://localhost:5000",
1097
+ temperature: 0.9,
1098
+ postCount: 3
1099
+ };
1100
+ function fetchSettings() {
1101
+ const storedSettings = localStorage.getItem(itemKey);
1102
+ if (storedSettings) {
1103
+ return { ...defaultSettings, ...JSON.parse(storedSettings) };
1104
+ } else {
1105
+ return defaultSettings;
1106
+ }
1107
+ }
1108
+ function saveSettings(settings) {
1109
+ localStorage.setItem(itemKey, JSON.stringify(settings));
1110
+ }
1111
+ function resetSettings() {
1112
+ localStorage.removeItem(itemKey);
1113
+ }
1114
+ function generateUUID() {
1115
+ return "10000000-1000-4000-8000-100000000000".replace(
1116
+ /[018]/g,
1117
+ (c2) => (+c2 ^ crypto.getRandomValues(new Uint8Array(1))[0] & 15 >> +c2 / 4).toString(16)
1118
+ );
1119
+ }
1120
+ const titleRegex = /Sujet\s+:\s+"(.+?)"?<\|eot_id\|>/;
1121
+ const userRegex = /<\|im_pseudo\|>([^<]+)<\|end_pseudo\|>/;
1122
+ const dateRegex = /<\|im_date\|>([^<]+)<\|end_date\|>/;
1123
+ const contentRegex = /<\|begin_of_post\|>([\s\S]+)(?:<\|end_of_post\|>)?$/;
1124
+ function tokensToTopic(tokens) {
1125
+ const topic = {
1126
+ id: generateUUID(),
1127
+ title: "",
1128
+ posts: []
1129
+ };
1130
+ for (const postTokens of tokens.split("<|end_of_post|>").slice(0, -1)) {
1131
+ console.log("Post tokens:");
1132
+ console.log(postTokens);
1133
+ if (topic.posts.length < 1) {
1134
+ const titleMatch = postTokens.match(titleRegex);
1135
+ console.log(`title: ${titleMatch[1]}`);
1136
+ topic.title = titleMatch[1];
1137
+ }
1138
+ topic.posts = topic.posts.concat(tokensToPosts(postTokens));
1139
+ }
1140
+ return topic;
1141
+ }
1142
+ function tokensToPosts(tokens) {
1143
+ const posts = [];
1144
+ for (const postTokens of tokens.split("<|end_of_post|>")) {
1145
+ if (postTokens.length < 1) {
1146
+ continue;
1147
+ }
1148
+ console.log("Post tokens:");
1149
+ console.log(postTokens);
1150
+ const userMatch = postTokens.match(userRegex);
1151
+ console.log(`user: ${userMatch[1]}`);
1152
+ const dateMatch = postTokens.match(dateRegex);
1153
+ console.log(`date: ${dateMatch[1]}`);
1154
+ const contentMatch = postTokens.match(contentRegex);
1155
+ console.log(`content: ${contentMatch[1]}`);
1156
+ posts.push({
1157
+ user: userMatch[1],
1158
+ date: frenchToIso8601(dateMatch[1]),
1159
+ content: contentMatch[1]
1160
+ });
1161
+ }
1162
+ return posts;
1163
+ }
1164
+ function tokenizeTopic(topic) {
1165
+ if (topic.posts.length === 0) {
1166
+ throw new Error("Topic must have at least one post");
1167
+ }
1168
+ const tokenizedPosts = topic.posts.map((post2) => tokenizePost(post2, topic.posts[0].user)).flat().join("");
1169
+ let lines = [
1170
+ "<|start_header_id|><|sujet|><|end_header_id|>",
1171
+ "",
1172
+ `Sujet : "${topic.title}"`
1173
+ ];
1174
+ return lines.join("\n") + tokenizedPosts;
1175
+ }
1176
+ function tokenizePost(post2, poster) {
1177
+ let lines = [
1178
+ `<|eot_id|><|start_header_id|><|${post2.user === poster ? "autheur" : "khey"}|>`,
1179
+ "<|end_header_id|>",
1180
+ "",
1181
+ `<|im_pseudo|>${post2.user}<|end_pseudo|>`,
1182
+ `<|im_date|>Le ${iso8601ToFrench(post2.date)}<|end_date|>`,
1183
+ "",
1184
+ `<|begin_of_post|>${post2.content}<|end_of_post|>`
1185
+ ];
1186
+ return lines.join("\n");
1187
+ }
1188
+ async function generateTopic(settings, nPosts) {
1189
+ console.log(settings);
1190
+ const rawOutput = await fetApiWithStream(settings, "<|start_header_id|>", nPosts);
1191
+ return tokensToTopic(rawOutput);
1192
+ }
1193
+ async function generatePosts(settings, nPosts, topic) {
1194
+ const rawOutput = await fetApiWithStream(settings, tokenizeTopic(topic), nPosts);
1195
+ console.log("rawOutput");
1196
+ console.log(rawOutput);
1197
+ return tokensToPosts(rawOutput);
1198
+ }
1199
+ const postEndToken = "<|end_of_post|>";
1200
+ async function fetApiWithStream(settings, prompt, nPosts) {
1201
+ const controller = new AbortController();
1202
+ const response = await fetch(new URL("/v1/completions", settings.apiURL), {
1203
+ method: "POST",
1204
+ headers: {
1205
+ "Content-Type": "application/json"
1206
+ },
1207
+ body: JSON.stringify({
1208
+ prompt,
1209
+ temperature: settings.temperature,
1210
+ max_tokens: 2e3,
1211
+ stream: true,
1212
+ skip_special_tokens: false
1213
+ // stop: "<|end_of_post|>"
1214
+ // top_p: 1,
1215
+ // frequency_penalty: 0,
1216
+ // presence_penalty: 0,
1217
+ }),
1218
+ signal: controller.signal
1219
+ });
1220
+ if (!response.ok) {
1221
+ throw new Error(`Failed to fetch API (${response.status} ${response.statusText}): ${await response.text()}`);
1222
+ }
1223
+ console.log(`Fetching topic with ${nPosts} posts...`);
1224
+ let endTokenCount = 0;
1225
+ let tokens = "";
1226
+ let finishReason = null;
1227
+ try {
1228
+ await response.body.pipeThrough(new TextDecoderStream("utf-8")).pipeTo(new WritableStream({
1229
+ write(rawChunk) {
1230
+ for (const rawChunkLine of rawChunk.split("\n")) {
1231
+ if (!rawChunkLine.startsWith("data:")) continue;
1232
+ const chunk = JSON.parse(rawChunkLine.slice(6));
1233
+ const text = chunk.choices[0].text;
1234
+ console.log(text);
1235
+ tokens += chunk.choices[0].text;
1236
+ if (text.includes(postEndToken)) {
1237
+ endTokenCount++;
1238
+ if (endTokenCount >= nPosts) {
1239
+ finishReason = "custom_stop";
1240
+ controller.abort();
1241
+ break;
1242
+ }
1243
+ } else {
1244
+ finishReason = chunk.choices[0].finish_reason;
1245
+ }
1246
+ }
1247
+ }
1248
+ }));
1249
+ } catch (e2) {
1250
+ if (e2.name !== "AbortError") {
1251
+ throw e2;
1252
+ }
1253
+ }
1254
+ console.log("Done fetching data");
1255
+ console.log(`Finish reason: ${finishReason}`);
1256
+ console.log(`Tokens: ${tokens}`);
1257
+ return tokens;
1258
+ }
1259
+ function App() {
1260
+ const [route, _setRoute] = h(routes.home);
1261
+ const [page, setPage] = h(0);
1262
+ const [topicId, setTopicId] = h(null);
1263
+ const [topics, setTopics] = h(loadTopics);
1264
+ const [latestGeneratedTopicId, setLatestGeneratedTopicId] = h(null);
1265
+ const [pendingGeneration, setPendingGeneration] = h(false);
1266
+ y(() => {
1267
+ console.log("save !");
1268
+ saveTopics(topics);
1269
+ }, [topics]);
1270
+ const _generateTopic = async (postsCount) => {
1271
+ setPendingGeneration(true);
1272
+ const topic = await generateTopic(settings, postsCount);
1273
+ setLatestGeneratedTopicId(topic.id);
1274
+ setTopics((topics2) => [...topics2, topic]);
1275
+ setPendingGeneration(false);
1276
+ };
1277
+ const addPosts = async (topicId2, postsCount) => {
1278
+ setPendingGeneration(true);
1279
+ const posts = await generatePosts(settings, postsCount, topics.find((t2) => t2.id === topicId2));
1280
+ const newTopics = [...topics];
1281
+ const foundIndex = newTopics.findIndex((t2) => t2.id === topicId2);
1282
+ newTopics[foundIndex].posts = newTopics[foundIndex].posts.concat(posts);
1283
+ setTopics(newTopics);
1284
+ setPendingGeneration(false);
1285
+ };
1286
+ const [settings, setSettings] = h(fetchSettings);
1287
+ y(() => {
1288
+ saveSettings(settings);
1289
+ }, [settings]);
1290
+ const resetApp = () => {
1291
+ resetSettings();
1292
+ setSettings(fetchSettings);
1293
+ setTopics([]);
1294
+ };
1295
+ const updateRoute = q(() => {
1296
+ const url = new URL(window.location.href);
1297
+ const route2 = url.searchParams.get("route");
1298
+ if (route2 && route2 in routes) {
1299
+ _setRoute(route2);
1300
+ }
1301
+ const page2 = url.searchParams.get("page");
1302
+ if (page2) {
1303
+ setPage(parseInt(page2));
1304
+ }
1305
+ const id = url.searchParams.get("id");
1306
+ if (id) {
1307
+ setTopicId(id);
1308
+ }
1309
+ }, []);
1310
+ y(() => {
1311
+ updateRoute();
1312
+ }, []);
1313
+ y(() => {
1314
+ function listener() {
1315
+ updateRoute();
1316
+ }
1317
+ window.addEventListener("popstate", listener);
1318
+ return () => {
1319
+ window.removeEventListener("popstate", listener);
1320
+ };
1321
+ }, []);
1322
+ const setRoute = q((route2, page2, id) => {
1323
+ const url = new URL(window.location.href);
1324
+ url.searchParams.set("route", route2);
1325
+ _setRoute(route2);
1326
+ if (page2 !== void 0) {
1327
+ url.searchParams.set("page", String(page2));
1328
+ setPage(page2);
1329
+ } else {
1330
+ url.searchParams.delete("page");
1331
+ setPage(0);
1332
+ }
1333
+ if (id !== void 0) {
1334
+ url.searchParams.set("id", id);
1335
+ setTopicId(id);
1336
+ } else {
1337
+ url.searchParams.delete("id");
1338
+ setTopicId(null);
1339
+ }
1340
+ const newUrl = url.toString();
1341
+ if (newUrl !== window.location.href) {
1342
+ window.history.pushState({}, "", newUrl);
1343
+ }
1344
+ }, []);
1345
+ let routeComponent = void 0;
1346
+ let breadcrumbs2 = void 0;
1347
+ let title = void 0;
1348
+ switch (route) {
1349
+ case routes.home:
1350
+ routeComponent = /* @__PURE__ */ u$1(
1351
+ Topics,
1352
+ {
1353
+ topics,
1354
+ setRoute,
1355
+ settings,
1356
+ setSettings,
1357
+ generateTopic: _generateTopic,
1358
+ pendingGeneration,
1359
+ latestGeneratedTopicId
1360
+ }
1361
+ );
1362
+ breadcrumbs2 = "accueil";
1363
+ title = "Liste des sujets";
1364
+ break;
1365
+ case routes.topic:
1366
+ if (topicId === null) {
1367
+ routeComponent = /* @__PURE__ */ u$1("div", { children: "Impossible d'afficher le sujet" });
1368
+ breadcrumbs2 = "accueil";
1369
+ title = "Sujet";
1370
+ } else {
1371
+ if (topics === null) {
1372
+ routeComponent = /* @__PURE__ */ u$1("div", { children: "Chargement..." });
1373
+ breadcrumbs2 = `accueil / sujet`;
1374
+ title = `Chargement...`;
1375
+ } else {
1376
+ const topic = topics.find((t2) => t2.id === topicId);
1377
+ routeComponent = /* @__PURE__ */ u$1(
1378
+ Topic,
1379
+ {
1380
+ topic,
1381
+ settings,
1382
+ setSettings,
1383
+ addPosts,
1384
+ pendingGeneration
1385
+ }
1386
+ );
1387
+ breadcrumbs2 = `accueil / ${topic.title}`;
1388
+ title = `Sujet : ${topic.title}`;
1389
+ }
1390
+ }
1391
+ break;
1392
+ case routes.settings:
1393
+ routeComponent = /* @__PURE__ */ u$1(Settings, { settings, setSettings, resetApp });
1394
+ breadcrumbs2 = "accueil / paramètres";
1395
+ title = "Paramètres";
1396
+ break;
1397
+ }
1398
+ return /* @__PURE__ */ u$1(k$1, { children: [
1399
+ /* @__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) => {
1400
+ e2.preventDefault();
1401
+ setRoute(routes.home);
1402
+ }, children: "JVCGPT" }) }) }) }),
1403
+ /* @__PURE__ */ u$1("main", { children: /* @__PURE__ */ u$1(Container, { children: /* @__PURE__ */ u$1(
1404
+ Layout,
1405
+ {
1406
+ breadcrumbs: breadcrumbs2,
1407
+ title,
1408
+ setRoute,
1409
+ children: routeComponent
1410
+ }
1411
+ ) }) })
1412
+ ] });
1413
+ }
1414
+ D$1(g(App, null), document.getElementById("app"));
dist/assets/index-Cjniv5yr.js DELETED
@@ -1,8 +0,0 @@
1
- (function(){const t=document.createElement("link").relList;if(t&&t.supports&&t.supports("modulepreload"))return;for(const s of document.querySelectorAll('link[rel="modulepreload"]'))o(s);new MutationObserver(s=>{for(const r of s)if(r.type==="childList")for(const a of r.addedNodes)a.tagName==="LINK"&&a.rel==="modulepreload"&&o(a)}).observe(document,{childList:!0,subtree:!0});function n(s){const r={};return s.integrity&&(r.integrity=s.integrity),s.referrerPolicy&&(r.referrerPolicy=s.referrerPolicy),s.crossOrigin==="use-credentials"?r.credentials="include":s.crossOrigin==="anonymous"?r.credentials="omit":r.credentials="same-origin",r}function o(s){if(s.ep)return;s.ep=!0;const r=n(s);fetch(s.href,r)}})();var te,v,Ue,A,be,Me,ie,De,le,ae,_e,M={},ze=[],nt=/acit|ex(?:s|g|n|p|$)|rph|grid|ows|mnc|ntw|ine[ch]|zoo|^ord|itera/i,ue=Array.isArray;function L(e,t){for(var n in t)e[n]=t[n];return e}function de(e){e&&e.parentNode&&e.parentNode.removeChild(e)}function R(e,t,n){var o,s,r,a={};for(r in t)r=="key"?o=t[r]:r=="ref"?s=t[r]:a[r]=t[r];if(arguments.length>2&&(a.children=arguments.length>3?te.call(arguments,2):n),typeof e=="function"&&e.defaultProps!=null)for(r in e.defaultProps)a[r]===void 0&&(a[r]=e.defaultProps[r]);return J(e,a,o,s,null)}function J(e,t,n,o,s){var r={type:e,props:t,key:n,ref:o,__k:null,__:null,__b:0,__e:null,__c:null,constructor:void 0,__v:s??++Ue,__i:-1,__u:0};return s==null&&v.vnode!=null&&v.vnode(r),r}function z(e){return e.children}function K(e,t){this.props=e,this.context=t}function F(e,t){if(t==null)return e.__?F(e.__,e.__i+1):null;for(var n;t<e.__k.length;t++)if((n=e.__k[t])!=null&&n.__e!=null)return n.__e;return typeof e.type=="function"?F(e):null}function Ge(e){var t,n;if((e=e.__)!=null&&e.__c!=null){for(e.__e=e.__c.base=null,t=0;t<e.__k.length;t++)if((n=e.__k[t])!=null&&n.__e!=null){e.__e=e.__c.base=n.__e;break}return Ge(e)}}function we(e){(!e.__d&&(e.__d=!0)&&A.push(e)&&!Q.__r++||be!==v.debounceRendering)&&((be=v.debounceRendering)||Me)(Q)}function Q(){var e,t,n,o,s,r,a,c;for(A.sort(ie);e=A.shift();)e.__d&&(t=A.length,o=void 0,r=(s=(n=e).__v).__e,a=[],c=[],n.__P&&((o=L({},s)).__v=s.__v+1,v.vnode&&v.vnode(o),fe(n.__P,o,s,n.__n,n.__P.namespaceURI,32&s.__u?[r]:null,a,r??F(s),!!(32&s.__u),c),o.__v=s.__v,o.__.__k[o.__i]=o,Ve(a,o,c),o.__e!=r&&Ge(o)),A.length>t&&A.sort(ie));Q.__r=0}function We(e,t,n,o,s,r,a,c,u,l,f){var i,h,d,g,k,w,m=o&&o.__k||ze,p=t.length;for(u=ot(n,t,m,u,p),i=0;i<p;i++)(d=n.__k[i])!=null&&(h=d.__i===-1?M:m[d.__i]||M,d.__i=i,w=fe(e,d,h,s,r,a,c,u,l,f),g=d.__e,d.ref&&h.ref!=d.ref&&(h.ref&&he(h.ref,null,d),f.push(d.ref,d.__c||g,d)),k==null&&g!=null&&(k=g),4&d.__u||h.__k===d.__k?u=Be(d,u,e):typeof d.type=="function"&&w!==void 0?u=w:g&&(u=g.nextSibling),d.__u&=-7);return n.__e=k,u}function ot(e,t,n,o,s){var r,a,c,u,l,f=n.length,i=f,h=0;for(e.__k=new Array(s),r=0;r<s;r++)(a=t[r])!=null&&typeof a!="boolean"&&typeof a!="function"?(u=r+h,(a=e.__k[r]=typeof a=="string"||typeof a=="number"||typeof a=="bigint"||a.constructor==String?J(null,a,null,null,null):ue(a)?J(z,{children:a},null,null,null):a.constructor===void 0&&a.__b>0?J(a.type,a.props,a.key,a.ref?a.ref:null,a.__v):a).__=e,a.__b=e.__b+1,c=null,(l=a.__i=rt(a,n,u,i))!==-1&&(i--,(c=n[l])&&(c.__u|=2)),c==null||c.__v===null?(l==-1&&h--,typeof a.type!="function"&&(a.__u|=4)):l!=u&&(l==u-1?h--:l==u+1?h++:(l>u?h--:h++,a.__u|=4))):e.__k[r]=null;if(i)for(r=0;r<f;r++)(c=n[r])!=null&&!(2&c.__u)&&(c.__e==o&&(o=F(c)),Je(c,c));return o}function Be(e,t,n){var o,s;if(typeof e.type=="function"){for(o=e.__k,s=0;o&&s<o.length;s++)o[s]&&(o[s].__=e,t=Be(o[s],t,n));return t}e.__e!=t&&(t&&e.type&&!n.contains(t)&&(t=F(e)),n.insertBefore(e.__e,t||null),t=e.__e);do t=t&&t.nextSibling;while(t!=null&&t.nodeType==8);return t}function rt(e,t,n,o){var s,r,a=e.key,c=e.type,u=t[n];if(u===null||u&&a==u.key&&c===u.type&&!(2&u.__u))return n;if(o>(u!=null&&!(2&u.__u)?1:0))for(s=n-1,r=n+1;s>=0||r<t.length;){if(s>=0){if((u=t[s])&&!(2&u.__u)&&a==u.key&&c===u.type)return s;s--}if(r<t.length){if((u=t[r])&&!(2&u.__u)&&a==u.key&&c===u.type)return r;r++}}return-1}function $e(e,t,n){t[0]=="-"?e.setProperty(t,n??""):e[t]=n==null?"":typeof n!="number"||nt.test(t)?n:n+"px"}function G(e,t,n,o,s){var r;e:if(t=="style")if(typeof n=="string")e.style.cssText=n;else{if(typeof o=="string"&&(e.style.cssText=o=""),o)for(t in o)n&&t in n||$e(e.style,t,"");if(n)for(t in n)o&&n[t]===o[t]||$e(e.style,t,n[t])}else if(t[0]=="o"&&t[1]=="n")r=t!=(t=t.replace(De,"$1")),t=t.toLowerCase()in e||t=="onFocusOut"||t=="onFocusIn"?t.toLowerCase().slice(2):t.slice(2),e.l||(e.l={}),e.l[t+r]=n,n?o?n.u=o.u:(n.u=le,e.addEventListener(t,r?_e:ae,r)):e.removeEventListener(t,r?_e:ae,r);else{if(s=="http://www.w3.org/2000/svg")t=t.replace(/xlink(H|:h)/,"h").replace(/sName$/,"s");else if(t!="width"&&t!="height"&&t!="href"&&t!="list"&&t!="form"&&t!="tabIndex"&&t!="download"&&t!="rowSpan"&&t!="colSpan"&&t!="role"&&t!="popover"&&t in e)try{e[t]=n??"";break e}catch{}typeof n=="function"||(n==null||n===!1&&t[4]!="-"?e.removeAttribute(t):e.setAttribute(t,t=="popover"&&n==1?"":n))}}function ke(e){return function(t){if(this.l){var n=this.l[t.type+e];if(t.t==null)t.t=le++;else if(t.t<n.u)return;return n(v.event?v.event(t):t)}}}function fe(e,t,n,o,s,r,a,c,u,l){var f,i,h,d,g,k,w,m,p,P,N,I,y,x,T,S,j,C=t.type;if(t.constructor!==void 0)return null;128&n.__u&&(u=!!(32&n.__u),r=[c=t.__e=n.__e]),(f=v.__b)&&f(t);e:if(typeof C=="function")try{if(m=t.props,p="prototype"in C&&C.prototype.render,P=(f=C.contextType)&&o[f.__c],N=f?P?P.props.value:f.__:o,n.__c?w=(i=t.__c=n.__c).__=i.__E:(p?t.__c=i=new C(m,N):(t.__c=i=new K(m,N),i.constructor=C,i.render=it),P&&P.sub(i),i.props=m,i.state||(i.state={}),i.context=N,i.__n=o,h=i.__d=!0,i.__h=[],i._sb=[]),p&&i.__s==null&&(i.__s=i.state),p&&C.getDerivedStateFromProps!=null&&(i.__s==i.state&&(i.__s=L({},i.__s)),L(i.__s,C.getDerivedStateFromProps(m,i.__s))),d=i.props,g=i.state,i.__v=t,h)p&&C.getDerivedStateFromProps==null&&i.componentWillMount!=null&&i.componentWillMount(),p&&i.componentDidMount!=null&&i.__h.push(i.componentDidMount);else{if(p&&C.getDerivedStateFromProps==null&&m!==d&&i.componentWillReceiveProps!=null&&i.componentWillReceiveProps(m,N),!i.__e&&(i.shouldComponentUpdate!=null&&i.shouldComponentUpdate(m,i.__s,N)===!1||t.__v==n.__v)){for(t.__v!=n.__v&&(i.props=m,i.state=i.__s,i.__d=!1),t.__e=n.__e,t.__k=n.__k,t.__k.some(function(O){O&&(O.__=t)}),I=0;I<i._sb.length;I++)i.__h.push(i._sb[I]);i._sb=[],i.__h.length&&a.push(i);break e}i.componentWillUpdate!=null&&i.componentWillUpdate(m,i.__s,N),p&&i.componentDidUpdate!=null&&i.__h.push(function(){i.componentDidUpdate(d,g,k)})}if(i.context=N,i.props=m,i.__P=e,i.__e=!1,y=v.__r,x=0,p){for(i.state=i.__s,i.__d=!1,y&&y(t),f=i.render(i.props,i.state,i.context),T=0;T<i._sb.length;T++)i.__h.push(i._sb[T]);i._sb=[]}else do i.__d=!1,y&&y(t),f=i.render(i.props,i.state,i.context),i.state=i.__s;while(i.__d&&++x<25);i.state=i.__s,i.getChildContext!=null&&(o=L(L({},o),i.getChildContext())),p&&!h&&i.getSnapshotBeforeUpdate!=null&&(k=i.getSnapshotBeforeUpdate(d,g)),c=We(e,ue(S=f!=null&&f.type===z&&f.key==null?f.props.children:f)?S:[S],t,n,o,s,r,a,c,u,l),i.base=t.__e,t.__u&=-161,i.__h.length&&a.push(i),w&&(i.__E=i.__=null)}catch(O){if(t.__v=null,u||r!=null)if(O.then){for(t.__u|=u?160:128;c&&c.nodeType==8&&c.nextSibling;)c=c.nextSibling;r[r.indexOf(c)]=null,t.__e=c}else for(j=r.length;j--;)de(r[j]);else t.__e=n.__e,t.__k=n.__k;v.__e(O,t,n)}else r==null&&t.__v==n.__v?(t.__k=n.__k,t.__e=n.__e):c=t.__e=st(n.__e,t,n,o,s,r,a,u,l);return(f=v.diffed)&&f(t),128&t.__u?void 0:c}function Ve(e,t,n){for(var o=0;o<n.length;o++)he(n[o],n[++o],n[++o]);v.__c&&v.__c(t,e),e.some(function(s){try{e=s.__h,s.__h=[],e.some(function(r){r.call(s)})}catch(r){v.__e(r,s.__v)}})}function st(e,t,n,o,s,r,a,c,u){var l,f,i,h,d,g,k,w=n.props,m=t.props,p=t.type;if(p=="svg"?s="http://www.w3.org/2000/svg":p=="math"?s="http://www.w3.org/1998/Math/MathML":s||(s="http://www.w3.org/1999/xhtml"),r!=null){for(l=0;l<r.length;l++)if((d=r[l])&&"setAttribute"in d==!!p&&(p?d.localName==p:d.nodeType==3)){e=d,r[l]=null;break}}if(e==null){if(p==null)return document.createTextNode(m);e=document.createElementNS(s,p,m.is&&m),c&&(v.__m&&v.__m(t,r),c=!1),r=null}if(p===null)w===m||c&&e.data===m||(e.data=m);else{if(r=r&&te.call(e.childNodes),w=n.props||M,!c&&r!=null)for(w={},l=0;l<e.attributes.length;l++)w[(d=e.attributes[l]).name]=d.value;for(l in w)if(d=w[l],l!="children"){if(l=="dangerouslySetInnerHTML")i=d;else if(!(l in m)){if(l=="value"&&"defaultValue"in m||l=="checked"&&"defaultChecked"in m)continue;G(e,l,null,d,s)}}for(l in m)d=m[l],l=="children"?h=d:l=="dangerouslySetInnerHTML"?f=d:l=="value"?g=d:l=="checked"?k=d:c&&typeof d!="function"||w[l]===d||G(e,l,d,w[l],s);if(f)c||i&&(f.__html===i.__html||f.__html===e.innerHTML)||(e.innerHTML=f.__html),t.__k=[];else if(i&&(e.innerHTML=""),We(e,ue(h)?h:[h],t,n,o,p=="foreignObject"?"http://www.w3.org/1999/xhtml":s,r,a,r?r[0]:n.__k&&F(n,0),c,u),r!=null)for(l=r.length;l--;)de(r[l]);c||(l="value",p=="progress"&&g==null?e.removeAttribute("value"):g!==void 0&&(g!==e[l]||p=="progress"&&!g||p=="option"&&g!==w[l])&&G(e,l,g,w[l],s),l="checked",k!==void 0&&k!==e[l]&&G(e,l,k,w[l],s))}return e}function he(e,t,n){try{if(typeof e=="function"){var o=typeof e.__u=="function";o&&e.__u(),o&&t==null||(e.__u=e(t))}else e.current=t}catch(s){v.__e(s,n)}}function Je(e,t,n){var o,s;if(v.unmount&&v.unmount(e),(o=e.ref)&&(o.current&&o.current!==e.__e||he(o,null,t)),(o=e.__c)!=null){if(o.componentWillUnmount)try{o.componentWillUnmount()}catch(r){v.__e(r,t)}o.base=o.__P=null}if(o=e.__k)for(s=0;s<o.length;s++)o[s]&&Je(o[s],t,n||typeof e.type!="function");n||de(e.__e),e.__c=e.__=e.__e=void 0}function it(e,t,n){return this.constructor(e,n)}function at(e,t,n){var o,s,r,a;t==document&&(t=document.documentElement),v.__&&v.__(e,t),s=(o=!1)?null:t.__k,r=[],a=[],fe(t,e=t.__k=R(z,null,[e]),s||M,M,t.namespaceURI,s?null:t.firstChild?te.call(t.childNodes):null,r,s?s.__e:t.firstChild,o,a),Ve(r,e,a)}te=ze.slice,v={__e:function(e,t,n,o){for(var s,r,a;t=t.__;)if((s=t.__c)&&!s.__)try{if((r=s.constructor)&&r.getDerivedStateFromError!=null&&(s.setState(r.getDerivedStateFromError(e)),a=s.__d),s.componentDidCatch!=null&&(s.componentDidCatch(e,o||{}),a=s.__d),a)return s.__E=s}catch(c){e=c}throw e}},Ue=0,K.prototype.setState=function(e,t){var n;n=this.__s!=null&&this.__s!==this.state?this.__s:this.__s=L({},this.state),typeof e=="function"&&(e=e(L({},n),this.props)),e&&L(n,e),e!=null&&this.__v&&(t&&this._sb.push(t),we(this))},K.prototype.forceUpdate=function(e){this.__v&&(this.__e=!0,e&&this.__h.push(e),we(this))},K.prototype.render=z,A=[],Me=typeof Promise=="function"?Promise.prototype.then.bind(Promise.resolve()):setTimeout,ie=function(e,t){return e.__v.__b-t.__v.__b},Q.__r=0,De=/(PointerCapture)$|Capture$/i,le=0,ae=ke(!1),_e=ke(!0);var _t=0;function _(e,t,n,o,s,r){t||(t={});var a,c,u=t;if("ref"in u)for(c in u={},t)c=="ref"?a=t[c]:u[c]=t[c];var l={type:e,props:u,key:n,ref:a,__k:null,__:null,__b:0,__e:null,__c:null,constructor:void 0,__v:--_t,__i:-1,__u:0,__source:s,__self:r};if(typeof e=="function"&&(a=e.defaultProps))for(c in a)u[c]===void 0&&(u[c]=a[c]);return v.vnode&&v.vnode(l),l}var D,b,oe,Se,X=0,Ke=[],$=v,xe=$.__b,Ne=$.__r,Te=$.diffed,Ce=$.__c,Pe=$.unmount,Ie=$.__;function pe(e,t){$.__h&&$.__h(b,e,X||t),X=0;var n=b.__H||(b.__H={__:[],__h:[]});return e>=n.__.length&&n.__.push({}),n.__[e]}function q(e){return X=1,ct(Qe,e)}function ct(e,t,n){var o=pe(D++,2);if(o.t=e,!o.__c&&(o.__=[Qe(void 0,t),function(c){var u=o.__N?o.__N[0]:o.__[0],l=o.t(u,c);u!==l&&(o.__N=[l,o.__[1]],o.__c.setState({}))}],o.__c=b,!b.u)){var s=function(c,u,l){if(!o.__c.__H)return!0;var f=o.__c.__H.__.filter(function(h){return!!h.__c});if(f.every(function(h){return!h.__N}))return!r||r.call(this,c,u,l);var i=o.__c.props!==c;return f.forEach(function(h){if(h.__N){var d=h.__[0];h.__=h.__N,h.__N=void 0,d!==h.__[0]&&(i=!0)}}),r&&r.call(this,c,u,l)||i};b.u=!0;var r=b.shouldComponentUpdate,a=b.componentWillUpdate;b.componentWillUpdate=function(c,u,l){if(this.__e){var f=r;r=void 0,s(c,u,l),r=f}a&&a.call(this,c,u,l)},b.shouldComponentUpdate=s}return o.__N||o.__}function W(e,t){var n=pe(D++,3);!$.__s&&Ze(n.__H,t)&&(n.__=e,n.i=t,b.__H.__h.push(n))}function me(e,t){var n=pe(D++,7);return Ze(n.__H,t)&&(n.__=e(),n.__H=t,n.__h=e),n.__}function je(e,t){return X=8,me(function(){return e},t)}function lt(){for(var e;e=Ke.shift();)if(e.__P&&e.__H)try{e.__H.__h.forEach(Z),e.__H.__h.forEach(ce),e.__H.__h=[]}catch(t){e.__H.__h=[],$.__e(t,e.__v)}}$.__b=function(e){b=null,xe&&xe(e)},$.__=function(e,t){e&&t.__k&&t.__k.__m&&(e.__m=t.__k.__m),Ie&&Ie(e,t)},$.__r=function(e){Ne&&Ne(e),D=0;var t=(b=e.__c).__H;t&&(oe===b?(t.__h=[],b.__h=[],t.__.forEach(function(n){n.__N&&(n.__=n.__N),n.i=n.__N=void 0})):(t.__h.forEach(Z),t.__h.forEach(ce),t.__h=[],D=0)),oe=b},$.diffed=function(e){Te&&Te(e);var t=e.__c;t&&t.__H&&(t.__H.__h.length&&(Ke.push(t)!==1&&Se===$.requestAnimationFrame||((Se=$.requestAnimationFrame)||ut)(lt)),t.__H.__.forEach(function(n){n.i&&(n.__H=n.i),n.i=void 0})),oe=b=null},$.__c=function(e,t){t.some(function(n){try{n.__h.forEach(Z),n.__h=n.__h.filter(function(o){return!o.__||ce(o)})}catch(o){t.some(function(s){s.__h&&(s.__h=[])}),t=[],$.__e(o,n.__v)}}),Ce&&Ce(e,t)},$.unmount=function(e){Pe&&Pe(e);var t,n=e.__c;n&&n.__H&&(n.__H.__.forEach(function(o){try{Z(o)}catch(s){t=s}}),n.__H=void 0,t&&$.__e(t,n.__v))};var qe=typeof requestAnimationFrame=="function";function ut(e){var t,n=function(){clearTimeout(o),qe&&cancelAnimationFrame(t),setTimeout(e)},o=setTimeout(n,100);qe&&(t=requestAnimationFrame(n))}function Z(e){var t=b,n=e.__c;typeof n=="function"&&(e.__c=void 0,n()),b=t}function ce(e){var t=b;e.__c=e.__(),b=t}function Ze(e,t){return!e||e.length!==t.length||t.some(function(n,o){return n!==e[o]})}function Qe(e,t){return typeof t=="function"?t(e):t}const dt="_header_1hnaa_1",ft="_logo_1hnaa_6",He={header:dt,logo:ft},ht="_container_1putz_1",pt={container:ht};function Le(e){return _("div",{class:pt.container,children:e.children})}const Xe="topics";function mt(){const e=localStorage.getItem(Xe);return e?JSON.parse(e):[]}function gt(e){localStorage.setItem(Xe,JSON.stringify(e))}function vt(e){return e&&e.__esModule&&Object.prototype.hasOwnProperty.call(e,"default")?e.default:e}var re={exports:{}};/*!
2
- Copyright (c) 2018 Jed Watson.
3
- Licensed under the MIT License (MIT), see
4
- http://jedwatson.github.io/classnames
5
- */var Re;function yt(){return Re||(Re=1,function(e){(function(){var t={}.hasOwnProperty;function n(){for(var r="",a=0;a<arguments.length;a++){var c=arguments[a];c&&(r=s(r,o(c)))}return r}function o(r){if(typeof r=="string"||typeof r=="number")return r;if(typeof r!="object")return"";if(Array.isArray(r))return n.apply(null,r);if(r.toString!==Object.prototype.toString&&!r.toString.toString().includes("[native code]"))return r.toString();var a="";for(var c in r)t.call(r,c)&&r[c]&&(a=s(a,c));return a}function s(r,a){return a?r?r+" "+a:r+a:r}e.exports?(n.default=n,e.exports=n):window.classNames=n})()}(re)),re.exports}var bt=yt();const ne=vt(bt),wt="_spinnerSquare_4vgl0_1",$t="_square1_4vgl0_14",kt="_square2_4vgl0_18",St="_square3_4vgl0_22",B={spinnerSquare:wt,square1:$t,"square-anim":"_square-anim_4vgl0_1",square2:kt,square3:St};function xt(e){return _("div",{className:ne(B.spinnerSquare,e.className),children:[_("div",{className:B.square1}),_("div",{className:B.square2}),_("div",{className:B.square3})]})}const Nt="_spinner_1pqws_1",Tt="_list_1pqws_5",Ct="_highlight_1pqws_44",Pt="_head_1pqws_48",It="_generationSettings_1pqws_52",U={spinner:Nt,list:Tt,highlight:Ct,head:Pt,generationSettings:It},H={home:"home",topic:"topic",settings:"settings"},jt="_btn_1ts7o_1",qt="_disabled_1ts7o_18",Ht="_secondary_1ts7o_22",Lt="_spinner_1ts7o_32",Rt="_load3_1ts7o_1",V={btn:jt,disabled:qt,secondary:Ht,spinner:Lt,load3:Rt};function Y(e){const t=e.disabled||e.loading,n=ne(V.btn,{[V.secondary]:e.secondary},"button",e.className,{[V.disabled]:t});let o;return e.loading&&(o=_("span",{className:V.spinner})),_("button",{type:"button",onClick:()=>{t||e.onClick()},className:n,disabled:t,title:e.title,children:[o,e.children]})}const At=/(\d{4})-(\d{2})-(\d{2})T(\d{2}):(\d{2}):(\d{2})/;function ge(e){console.log("iso8601ToTokens",e);const t=e.match(At),n=t[1],o=Ye[parseInt(t[2],10)-1],s=t[3],r=t[4],a=t[5],c=t[6];return`${s} ${o} ${n} à ${r}:${a}:${c}`}const Et=/(\d{1,2}) ([a-zA-Z\u00C0-\u024F]+) (\d{4}) à (\d{2}):(\d{2}):(\d{2})/;function Ft(e){console.log("tokensToIso8601",e);const t=e.match(Et);if(!t)throw new Error("Invalid date format");const[,n,o,s,r,a,c]=t,u=(Ye.indexOf(o)+1).toString();if(!u)throw new Error("Invalid month name");return`${s}-${u.padStart(2,"0")}-${n.padStart(2,"0")}T${r}:${a}:${c}`}const Ye=["janvier","février","mars","avril","mai","juin","juillet","août","septembre","octobre","novembre","décembre"],Ot="_formGroup_b3g81_1",Ut={formGroup:Ot};function ee(e){return _("div",{className:Ut.formGroup,children:e.children})}const Mt="_rangeSlider_1trvf_1",Dt="_rangeSlider__values_1trvf_99",zt="_progress_1trvf_116",Ae={rangeSlider:Mt,rangeSlider__values:Dt,progress:zt};function ve(e){return _("div",{className:Ae.rangeSlider,style:`--min:${e.min}; --max:${e.max}; --step:${e.step}; --value:${e.value}; --text-value:"${e.value}";`,children:[_("input",{name:e.name,type:"range",min:e.min,max:e.max,step:e.step,value:e.value,onInput:t=>e.onChange(Number(t.target.value))}),_("output",{}),_("div",{className:Ae.progress})]})}function Gt(e){const t=me(()=>e.topics===null||e.topics.length<1?e.topics:e.topics.sort((n,o)=>n.posts.length<1||o.posts.length<1?0:o.posts[o.posts.length-1].date.localeCompare(n.posts[n.posts.length-1].date)),[e.topics]);return _("div",{children:[t===null?_(xt,{className:U.spinner}):_(Wt,{topics:t,setRoute:e.setRoute,latestGeneratedTopicId:e.latestGeneratedTopicId}),_("div",{children:[_("h2",{children:"Nouveau sujet"}),_("div",{className:U.generationSettings,children:_(ee,{children:[_("label",{for:"postCount",children:"Nombre de posts"}),_(ve,{name:"postCount",value:e.settings.postCount,onChange:n=>e.setSettings({...e.settings,postCount:n}),min:1,max:10,step:1})]})}),_(Y,{onClick:()=>e.generateTopic(e.settings.postCount),secondary:!0,loading:e.pendingGeneration,children:"Générer"})]}),_("hr",{})]})}function Wt(e){return _("ul",{className:U.list,children:[_("li",{className:U.head,children:[_("span",{children:"Sujet"}),_("span",{children:"Auteur"}),_("span",{children:"NB"}),_("span",{children:"Dernier msg"})]}),e.topics.length<1&&_("li",{children:[_("span",{children:"Aucun sujet"}),_("span",{}),_("span",{}),_("span",{})]}),e.topics.map(t=>_("li",{className:ne({[U.highlight]:t.id===e.latestGeneratedTopicId}),children:[_("span",{children:_("a",{href:"#",onClick:n=>{n.preventDefault(),e.setRoute(H.topic,0,t.id)},children:t.title})}),_("span",{children:t.posts[0].user}),_("span",{children:t.posts.length}),_("span",{children:ge(t.posts[t.posts.length-1].date)})]}))]})}const Bt="_post_uuidr_1",Vt="_postHeader_uuidr_12",Jt="_avatar_uuidr_23",Kt="_user_uuidr_31",Zt="_date_uuidr_39",Qt="_generationSettings_uuidr_46",E={post:Bt,postHeader:Vt,avatar:Jt,user:Kt,date:Zt,generationSettings:Qt},Xt="_wrapper_cfqzy_1",Yt={wrapper:Xt},en=[[":)","1"],[":snif:","20"],[":gba:","17"],[":g)","3"],[":-)","46"],[":snif2:","13"],[":bravo:","69"],[":d)","4"],[":hap:","18"],[":ouch:","22"],[":pacg:","9"],[":cd:","5"],[":-)))","23"],[":ouch2:","57"],[":pacd:","10"],[":cute:","nyu"],[":content:","24"],[":p)","7"],[":-p","31"],[":noel:","11"],[":oui:","37"],[":(","45"],[":peur:","47"],[":question:","2"],[":cool:","26"],[":-(","14"],[":coeur:","54"],[":mort:","21"],[":rire:","39"],[":-((","15"],[":fou:","50"],[":sleep:","27"],[":-D","40"],[":nonnon:","25"],[":fier:","53"],[":honte:","30"],[":rire2:","41"],[":non2:","33"],[":sarcastic:","43"],[":monoeil:","34"],[":o))","12"],[":nah:","19"],[":doute:","28"],[":rouge:","55"],[":ok:","36"],[":non:","35"],[":malade:","8"],[":fete:","66"],[":sournois:","67"],[":hum:","68"],[":ange:","60"],[":diable:","61"],[":gni:","62"],[":play:","play"],[":desole:","65"],[":spoiler:","63"],[":merci:","58"],[":svp:","59"],[":sors:","56"],[":salut:","42"],[":rechercher:","38"],[":hello:","29"],[":up:","44"],[":bye:","48"],[":gne:","51"],[":lol:","32"],[":dpdr:","49"],[":dehors:","52"],[":hs:","64"],[":banzai:","70"],[":bave:","71"],[":pf:","pf"],[":cimer:","cimer"],[":ddb:","ddb"],[":pave:","pave"],[":objection:","objection"],[":siffle:","siffle"]];function tn(e){const t=me(()=>{const n=rn(e.raw);return on(n).replace(/\n/g,"<br/>")},[e.raw]);return _("div",{className:Yt.wrapper,dangerouslySetInnerHTML:{__html:t}})}const nn=[[/(^| )https?:\/\/image\.noelshack\.com\/(?:fichiers|minis)(\S+)/gm,'$1<img width="68" height="51" alt="noelshak" src="https://image.noelshack.com/minis/$2"/>'],[/(^| )https:\/\/vocaroo.com\/(.+)/gm,'$1<div><iframe width="300" height="60" src="https://vocaroo.com/embed/$2?autoplay=0" frameborder="0" allow="autoplay"></iframe></div>'],[/^(?:&gt;.*(?:\n&gt;.*)*)/g,(e,t)=>{const n=e.exec(t);if(!n)return t;console.log(n);const o=n.index,s=n[0].length;return t.substring(0,o)+`<blockquote>${n[0].replace(/^&gt;/gm,"")}</blockquote>`+t.substring(o+s)}],[/&lt;spoil&gt;(.*?)&lt;\/spoil&gt;/gm,(e,t)=>t.replace(e,(n,o)=>{const s=(Math.random()+1).toString(36).substring(2);return`<span class="bloc-spoil-jv"><input type="checkbox" id="${s}" class="open-spoil"><label class="barre-head" for="${s}"><span class="txt-spoil">Spoil</span></label><span class="contenu-spoil">${o}</span></span>`})],[/(^| )(https?:\/\/\S+)/gm,'$1<a href="$2" target="_blank">$2</a>'],...en.map(e=>[new RegExp("(?:(^| )"+e[0].replace(/[.*+?^${}()|[\]\\]/g,"\\$&")+")","gm"),`$1<img src="https://image.jeuxvideo.com/smileys_img/${e[1]}.gif" alt="${e[0]}"/>`])];function on(e){do for(const[t,n]of nn)n instanceof Function?e=n(t,e):e=e.replace(t,n);while(!1);return e}function rn(e){return e.replace(/&/g,"&amp;").replace(/</g,"&lt;").replace(/>/g,"&gt;").replace(/"/g,"&quot;").replace(/'/g,"&#039;")}function sn(e){return console.log(e.topic),_("div",{children:[e.topic.posts.map(t=>_(an,{post:t})),_("div",{children:[_("h2",{children:"Ajout de posts"}),_("div",{className:E.generationSettings,children:_(ee,{children:[_("label",{htmlFor:"postCount",children:"Nombre de posts"}),_(ve,{name:"postCount",value:e.settings.postCount,onChange:t=>e.setSettings({...e.settings,postCount:t}),min:1,max:10,step:1})]})}),_(Y,{onClick:()=>e.addPosts(e.topic.id,e.settings.postCount),secondary:!0,loading:e.pendingGeneration,children:"Générer"})]}),_("hr",{})]})}function an(e){return _("div",{className:E.post,children:[_("div",{className:E.postHeader,children:[_("img",{src:"https://image.jeuxvideo.com/avatar-sm/default.jpg",className:E.avatar,alt:"ahi"}),_("div",{className:E.user,children:e.post.user}),_("div",{className:E.date,children:ge(e.post.date)})]}),_(tn,{raw:e.post.content})]})}const _n="_wrapper_1dmrl_1",cn="_icon_1dmrl_6",ln="_input_1dmrl_14",se={wrapper:_n,icon:cn,input:ln},un=({type:e,icon:t,value:n,placeholder:o,onChange:s,className:r,disabled:a,id:c,name:u})=>{const[l,f]=q(!1),i=ne(se.input,"generic-input",r,{focused:l,disabled:a}),h=g=>{console.log("handleInputChange");const k=g.target;s(e==="number"?parseFloat(k.value)||0:k.value)},d=t;return _("div",{className:se.wrapper,children:[_(d,{className:se.icon,size:18}),_("input",{title:"Le pseudo doit avoir une longueur comprise entre 3 et 15 caractères.",type:e,id:c,name:u,value:n,placeholder:o,onInput:h,className:i,disabled:a,onFocus:()=>f(!0),onBlur:()=>f(!1)})]})},dn=e=>{const t=e.color||"currentColor",n=e.size||24;return delete e.color,delete e.size,R("svg",Object.assign({xmlns:"http://www.w3.org/2000/svg",width:n,height:n,viewBox:"0 0 24 24",fill:"none",stroke:t,"stroke-width":"2","stroke-linecap":"round","stroke-linejoin":"round"},e),R("path",{d:"M10 13a5 5 0 0 0 7.54.54l3-3a5 5 0 0 0-7.07-7.07l-1.72 1.71"}),R("path",{d:"M14 11a5 5 0 0 0-7.54-.54l-3 3a5 5 0 0 0 7.07 7.07l1.71-1.71"}))},fn=e=>{const t=e.color||"currentColor",n=e.size||24;return delete e.color,delete e.size,R("svg",Object.assign({xmlns:"http://www.w3.org/2000/svg",width:n,height:n,viewBox:"0 0 24 24",fill:"none",stroke:t,"stroke-width":"2","stroke-linecap":"round","stroke-linejoin":"round"},e),R("circle",{cx:"12",cy:"12",r:"3"}),R("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"}))};function hn(e){return _("div",{children:_("form",{children:[_(ee,{children:[_("label",{htmlFor:"api",children:"API"}),_(un,{type:"text",placeholder:"URl d'API ex: https://ouruq7zepnehg2-5000.proxy.runpod.net/",icon:dn,value:e.settings.apiURL,onChange:t=>e.setSettings({...e.settings,apiURL:t})})]}),_(ee,{children:[_("label",{for:"temperature",children:"Temperature"}),_(ve,{name:"temperature",value:e.settings.temperature,onChange:t=>e.setSettings({...e.settings,temperature:t}),min:.1,max:2,step:.1})]}),_("div",{children:_(Y,{onClick:()=>{e.resetApp()},secondary:!0,title:"Tout réinitialiser",children:"Réinitialiser"})}),_("br",{}),_("div",{children:_(Y,{onClick:()=>{history.go(-1)},children:"Retour"})})]})})}const pn="_breadcrumbs_145yl_1",mn="_actions_145yl_10",Ee={breadcrumbs:pn,actions:mn};function gn(e){return _("div",{children:[_("nav",{className:Ee.breadcrumbs,children:[e.breadcrumbs,_("div",{className:Ee.actions,children:_("a",{href:"#",title:"Paramètres",onClick:t=>{t.preventDefault(),e.setRoute(H.settings)},children:_(fn,{size:18})})})]}),_("h2",{children:e.title}),e.children]})}const ye="settings",Fe={apiURL:"http://localhost:5000",temperature:.9,postCount:3};function Oe(){const e=localStorage.getItem(ye);return e?{...Fe,...JSON.parse(e)}:Fe}function vn(e){localStorage.setItem(ye,JSON.stringify(e))}function yn(){localStorage.removeItem(ye)}function bn(){return"10000000-1000-4000-8000-100000000000".replace(/[018]/g,e=>(+e^crypto.getRandomValues(new Uint8Array(1))[0]&15>>+e/4).toString(16))}const wn=/Sujet\s+:\s+"(.+?)"?<\|eot_id\|>/,$n=/<\|im_pseudo\|>([^<]+)<\|end_pseudo\|>/,kn=/<\|im_date\|>([^<]+)<\|end_date\|>/,Sn=/<\|begin_of_post\|>([\s\S]+)(?:<\|end_of_post\|>)?$/;function xn(e){const t={id:bn(),title:"",posts:[]};for(const n of e.split("<|end_of_post|>").slice(0,-1)){if(console.log("Post tokens:"),console.log(n),t.posts.length<1){const o=n.match(wn);console.log(`title: ${o[1]}`),t.title=o[1]}t.posts=t.posts.concat(et(n))}return t}function et(e){const t=[];for(const n of e.split("<|end_of_post|>")){if(n.length<1)continue;console.log("Post tokens:"),console.log(n);const o=n.match($n);console.log(`user: ${o[1]}`);const s=n.match(kn);console.log(`date: ${s[1]}`);const r=n.match(Sn);console.log(`content: ${r[1]}`),t.push({user:o[1],date:Ft(s[1]),content:r[1]})}return t}function Nn(e){if(e.posts.length===0)throw new Error("Topic must have at least one post");const t=e.posts.map(o=>Tn(o,e.posts[0].user)).flat().join("");return["<|start_header_id|><|sujet|><|end_header_id|>","",`Sujet : "${e.title}"`].join(`
6
- `)+t}function Tn(e,t){return[`<|eot_id|><|start_header_id|><|${e.user===t?"autheur":"khey"}|>`,"<|end_header_id|>","",`<|im_pseudo|>${e.user}<|end_pseudo|>`,`<|im_date|>Le ${ge(e.date)}<|end_date|>`,"",`<|begin_of_post|>${e.content}<|end_of_post|>`].join(`
7
- `)}async function Cn(e,t){console.log(e);const n=await tt(e,"<|start_header_id|>",t);return xn(n)}async function Pn(e,t,n){const o=await tt(e,Nn(n),t);return console.log("rawOutput"),console.log(o),et(o)}const In="<|end_of_post|>";async function tt(e,t,n){const o=new AbortController,s=await fetch(new URL("/v1/completions",e.apiURL),{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify({prompt:t,temperature:e.temperature,max_tokens:2e3,stream:!0,skip_special_tokens:!1}),signal:o.signal});if(!s.ok)throw new Error(`Failed to fetch API (${s.status} ${s.statusText}): ${await s.text()}`);console.log(`Fetching topic with ${n} posts...`);let r=0,a="",c=null;try{await s.body.pipeThrough(new TextDecoderStream("utf-8")).pipeTo(new WritableStream({write(u){for(const l of u.split(`
8
- `)){if(!l.startsWith("data:"))continue;const f=JSON.parse(l.slice(6)),i=f.choices[0].text;if(console.log(i),a+=f.choices[0].text,i.includes(In)){if(r++,r>=n){c="custom_stop",o.abort();break}}else c=f.choices[0].finish_reason}}}))}catch(u){if(u.name!=="AbortError")throw u}return console.log("Done fetching data"),console.log(`Finish reason: ${c}`),console.log(`Tokens: ${a}`),a}function jn(){const[e,t]=q(H.home),[n,o]=q(0),[s,r]=q(null),[a,c]=q(mt),[u,l]=q(null),[f,i]=q(!1);W(()=>{console.log("save !"),gt(a)},[a]);const h=async y=>{i(!0);const x=await Cn(g,y);l(x.id),c(T=>[...T,x]),i(!1)},d=async(y,x)=>{i(!0);const T=await Pn(g,x,a.find(C=>C.id===y)),S=[...a],j=S.findIndex(C=>C.id===y);S[j].posts=S[j].posts.concat(T),c(S),i(!1)},[g,k]=q(Oe);W(()=>{vn(g)},[g]);const w=()=>{yn(),k(Oe),c([])},m=je(()=>{const y=new URL(window.location.href),x=y.searchParams.get("route");x&&x in H&&t(x);const T=y.searchParams.get("page");T&&o(parseInt(T));const S=y.searchParams.get("id");S&&r(S)},[]);W(()=>{m()},[]),W(()=>{function y(){m()}return window.addEventListener("popstate",y),()=>{window.removeEventListener("popstate",y)}},[]);const p=je((y,x,T)=>{const S=new URL(window.location.href);S.searchParams.set("route",y),t(y),x!==void 0?(S.searchParams.set("page",String(x)),o(x)):(S.searchParams.delete("page"),o(0)),T!==void 0?(S.searchParams.set("id",T),r(T)):(S.searchParams.delete("id"),r(null));const j=S.toString();j!==window.location.href&&window.history.pushState({},"",j)},[]);let P,N,I;switch(e){case H.home:P=_(Gt,{topics:a,setRoute:p,settings:g,setSettings:k,generateTopic:h,pendingGeneration:f,latestGeneratedTopicId:u}),N="accueil",I="Liste des sujets";break;case H.topic:if(s===null)P=_("div",{children:"Impossible d'afficher le sujet"}),N="accueil",I="Sujet";else if(a===null)P=_("div",{children:"Chargement..."}),N="accueil / sujet",I="Chargement...";else{const y=a.find(x=>x.id===s);P=_(sn,{topic:y,settings:g,setSettings:k,addPosts:d,pendingGeneration:f}),N=`accueil / ${y.title}`,I=`Sujet : ${y.title}`}break;case H.settings:P=_(hn,{settings:g,setSettings:k,resetApp:w}),N="accueil / paramètres",I="Paramètres";break}return _(z,{children:[_("header",{className:He.header,children:_(Le,{children:_("h1",{className:He.logo,children:_("a",{href:"#",onClick:y=>{y.preventDefault(),p(H.home)},children:"JVCGPT"})})})}),_("main",{children:_(Le,{children:_(gn,{breadcrumbs:N,title:I,setRoute:p,children:P})})})]})}at(R(jn,null),document.getElementById("app"));
 
 
 
 
 
 
 
 
 
dist/assets/index-CvL5ef4j.css ADDED
@@ -0,0 +1,856 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
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
+ }._rangeSlider_1trvf_1 {
439
+ --primary-color: var(--text-secondary);
440
+ --value-offset-y: var(--ticks-gap);
441
+ --value-active-color: white;
442
+ --value-background: transparent;
443
+ --value-background-hover: var(--primary-color);
444
+ --value-font: 700 12px/1 Arial;
445
+ --fill-color: var(--primary-color);
446
+ --progress-background: #eee;
447
+ --progress-radius: 20px;
448
+ --track-height: calc(var(--thumb-size) / 2);
449
+ --min-max-font: 12px Arial;
450
+ --min-max-opacity: 0.5;
451
+ --min-max-x-offset: 50%;
452
+ --thumb-size: 20px;
453
+ --thumb-color: white;
454
+ --thumb-shadow: 0 0 3px rgba(0, 0, 0, 0.4), 0 0 1px rgba(0, 0, 0, 0.5) inset,
455
+ 0 0 0 99px var(--thumb-color) inset;
456
+ --thumb-shadow-active: 0 0 0 calc(var(--thumb-size) / 4) inset var(--thumb-color),
457
+ 0 0 0 99px var(--primary-color) inset, 0 0 3px rgba(0, 0, 0, 0.4);
458
+ --thumb-shadow-hover: var(--thumb-shadow);
459
+ --ticks-thickness: 1px;
460
+ --ticks-height: 5px;
461
+ --ticks-gap: var(
462
+ --ticks-height,
463
+ 0
464
+ );
465
+ --ticks-color: silver;
466
+ --step: 1;
467
+ --ticks-count: Calc(var(--max) - var(--min)) / var(--step);
468
+ --maxTicksAllowed: 30;
469
+ --too-many-ticks: Min(1, Max(var(--ticks-count) - var(--maxTicksAllowed), 0));
470
+ --x-step: Max(
471
+ var(--step),
472
+ var(--too-many-ticks) * (var(--max) - var(--min))
473
+ );
474
+ --tickInterval: 100/ ((var(--max) - var(--min)) / var(--step)) * var(--tickEvery, 1);
475
+ --tickIntervalPerc: calc(
476
+ (100% - var(--thumb-size)) / ((var(--max) - var(--min)) / var(--x-step)) *
477
+ var(--tickEvery, 1)
478
+ );
479
+ --value-a: Clamp(
480
+ var(--min),
481
+ var(--value, 0),
482
+ var(--max)
483
+ );
484
+ --value-b: var(--value, 0);
485
+ --text-value-a: var(--text-value, "");
486
+ --completed-a: calc(
487
+ (var(--value-a) - var(--min)) / (var(--max) - var(--min)) * 100
488
+ );
489
+ --completed-b: calc(
490
+ (var(--value-b) - var(--min)) / (var(--max) - var(--min)) * 100
491
+ );
492
+ --ca: Min(var(--completed-a), var(--completed-b));
493
+ --cb: Max(var(--completed-a), var(--completed-b));
494
+ --thumbs-too-close: Clamp(
495
+ -1,
496
+ 1000 * (Min(1, Max(var(--cb) - var(--ca) - 5, -1)) + 0.001),
497
+ 1
498
+ );
499
+ display: inline-block;
500
+ height: max(var(--track-height), var(--thumb-size));
501
+ background: linear-gradient(to right, var(--ticks-color) var(--ticks-thickness), transparent 1px) repeat-x;
502
+ background-size: var(--tickIntervalPerc) var(--ticks-height);
503
+ background-position-x: calc(var(--thumb-size) / 2 - var(--ticks-thickness) / 2);
504
+ background-position-y: var(--flip-y, bottom);
505
+ padding-bottom: var(--flip-y, var(--ticks-gap));
506
+ padding-top: calc(var(--flip-y) * var(--ticks-gap));
507
+ margin-top: 1rem;
508
+ margin-bottom: 2rem;
509
+ position: relative;
510
+ z-index: 1;
511
+ }
512
+ ._rangeSlider_1trvf_1[data-ticks-position=top] {
513
+ --flip-y: 1;
514
+ }
515
+ ._rangeSlider_1trvf_1::before, ._rangeSlider_1trvf_1::after {
516
+ --offset: calc(var(--thumb-size) / 2);
517
+ content: counter(x);
518
+ display: var(--show-min-max, block);
519
+ font: var(--min-max-font);
520
+ position: absolute;
521
+ bottom: var(--flip-y, -2.5ch);
522
+ top: calc(-2.5ch * var(--flip-y));
523
+ opacity: var(--min-max-opacity);
524
+ transform: translateX(calc(var(--min-max-x-offset) * var(--before, -1) * -1));
525
+ pointer-events: none;
526
+ }
527
+ ._rangeSlider_1trvf_1::before {
528
+ --before: 1;
529
+ counter-reset: x var(--min);
530
+ left: var(--offset);
531
+ }
532
+ ._rangeSlider_1trvf_1::after {
533
+ counter-reset: x var(--max);
534
+ right: var(--offset);
535
+ }
536
+ ._rangeSlider__values_1trvf_99 {
537
+ position: relative;
538
+ top: 50%;
539
+ line-height: 0;
540
+ text-align: justify;
541
+ width: 100%;
542
+ pointer-events: none;
543
+ margin: 0 auto;
544
+ z-index: 5;
545
+ }
546
+ ._rangeSlider__values_1trvf_99::after {
547
+ content: "";
548
+ width: 100%;
549
+ display: inline-block;
550
+ height: 0;
551
+ background: red;
552
+ }
553
+ ._rangeSlider_1trvf_1 ._progress_1trvf_116 {
554
+ --start-end: calc(var(--thumb-size) / 2);
555
+ --clip-end: calc(100% - (var(--cb)) * 1%);
556
+ --clip-start: calc(var(--ca) * 1%);
557
+ --clip: inset(-20px var(--clip-end) -20px var(--clip-start));
558
+ position: absolute;
559
+ left: calc(var(--start-end) - 10px);
560
+ right: calc(var(--start-end) - 10px);
561
+ top: calc(var(--ticks-gap) * var(--flip-y, 0) + var(--thumb-size) / 2 - var(--track-height));
562
+ height: calc(var(--track-height));
563
+ background: var(--progress-background, #eee);
564
+ pointer-events: none;
565
+ z-index: -1;
566
+ border-radius: var(--progress-radius);
567
+ }
568
+ ._rangeSlider_1trvf_1 ._progress_1trvf_116::before {
569
+ content: "";
570
+ position: absolute;
571
+ left: 0;
572
+ right: 0;
573
+ clip-path: var(--clip);
574
+ top: 0;
575
+ bottom: 0;
576
+ background: var(--fill-color, black);
577
+ box-shadow: var(--progress-flll-shadow);
578
+ z-index: 1;
579
+ border-radius: inherit;
580
+ }
581
+ ._rangeSlider_1trvf_1 ._progress_1trvf_116::after {
582
+ content: "";
583
+ position: absolute;
584
+ top: 0;
585
+ right: 0;
586
+ bottom: 0;
587
+ left: 0;
588
+ box-shadow: var(--progress-shadow);
589
+ pointer-events: none;
590
+ border-radius: inherit;
591
+ }
592
+ ._rangeSlider_1trvf_1 > input {
593
+ -webkit-appearance: none;
594
+ width: 100%;
595
+ height: var(--thumb-size);
596
+ margin: 0;
597
+ position: absolute;
598
+ left: 0;
599
+ top: calc(50% - max(var(--track-height), var(--thumb-size)) / 2 + var(--ticks-gap) / 2 * var(--flip-y, -1));
600
+ cursor: -webkit-grab;
601
+ cursor: grab;
602
+ outline: none;
603
+ background: none;
604
+ }
605
+ ._rangeSlider_1trvf_1 > input:not(:only-of-type) {
606
+ pointer-events: none;
607
+ }
608
+ ._rangeSlider_1trvf_1 > input::-webkit-slider-thumb {
609
+ appearance: none;
610
+ height: var(--thumb-size);
611
+ width: var(--thumb-size);
612
+ transform: translateY(-4px);
613
+ border-radius: var(--thumb-radius, 50%);
614
+ background: var(--thumb-color);
615
+ box-shadow: var(--thumb-shadow);
616
+ border: none;
617
+ pointer-events: auto;
618
+ transition: 0.1s;
619
+ }
620
+ ._rangeSlider_1trvf_1 > input::-moz-range-thumb {
621
+ appearance: none;
622
+ height: var(--thumb-size);
623
+ width: var(--thumb-size);
624
+ transform: translateY(-4px);
625
+ border-radius: var(--thumb-radius, 50%);
626
+ background: var(--thumb-color);
627
+ box-shadow: var(--thumb-shadow);
628
+ border: none;
629
+ pointer-events: auto;
630
+ transition: 0.1s;
631
+ }
632
+ ._rangeSlider_1trvf_1 > input::-ms-thumb {
633
+ appearance: none;
634
+ height: var(--thumb-size);
635
+ width: var(--thumb-size);
636
+ transform: translateY(-4px);
637
+ border-radius: var(--thumb-radius, 50%);
638
+ background: var(--thumb-color);
639
+ box-shadow: var(--thumb-shadow);
640
+ border: none;
641
+ pointer-events: auto;
642
+ transition: 0.1s;
643
+ }
644
+ ._rangeSlider_1trvf_1 > input:hover {
645
+ --thumb-shadow: var(--thumb-shadow-hover);
646
+ }
647
+ ._rangeSlider_1trvf_1 > input:active {
648
+ --thumb-shadow: var(--thumb-shadow-active);
649
+ cursor: grabbing;
650
+ z-index: 2;
651
+ }
652
+ ._rangeSlider_1trvf_1 > input:active + output {
653
+ transition: 0s;
654
+ }
655
+ ._rangeSlider_1trvf_1 > input:nth-of-type(1) {
656
+ --is-left-most: Clamp(0, (var(--value-a) - var(--value-b)) * 99999, 1);
657
+ }
658
+ ._rangeSlider_1trvf_1 > input:nth-of-type(1) + output {
659
+ --value: var(--value-a);
660
+ --x-offset: calc(var(--completed-a) * -1%);
661
+ }
662
+ ._rangeSlider_1trvf_1 > input:nth-of-type(1) + output:not(:only-of-type) {
663
+ --flip: calc(var(--thumbs-too-close) * -1);
664
+ }
665
+ ._rangeSlider_1trvf_1 > input:nth-of-type(1) + output::after {
666
+ content: var(--prefix, "") var(--text-value-a) var(--suffix, "");
667
+ }
668
+ ._rangeSlider_1trvf_1 > input:nth-of-type(2) {
669
+ --is-left-most: Clamp(0, (var(--value-b) - var(--value-a)) * 99999, 1);
670
+ }
671
+ ._rangeSlider_1trvf_1 > input:nth-of-type(2) + output {
672
+ --value: var(--value-b);
673
+ }
674
+ ._rangeSlider_1trvf_1 > input:only-of-type ~ ._progress_1trvf_116 {
675
+ --clip-start: 0;
676
+ }
677
+ ._rangeSlider_1trvf_1 > input + output {
678
+ --flip: -1;
679
+ --x-offset: calc(var(--completed-b) * -1%);
680
+ --pos: calc(
681
+ ((var(--value) - var(--min)) / (var(--max) - var(--min))) * 100%
682
+ );
683
+ pointer-events: none;
684
+ position: absolute;
685
+ z-index: 5;
686
+ background: var(--value-background);
687
+ border-radius: 10px;
688
+ padding: 0 4px;
689
+ left: var(--pos);
690
+ transform: translate(var(--x-offset), calc(150% * var(--flip) - (var(--y-offset, 0px) + var(--value-offset-y)) * var(--flip)));
691
+ transition: all 0.12s ease-out, left 0s;
692
+ }
693
+ ._rangeSlider_1trvf_1 > input + output::after {
694
+ content: var(--prefix, "") var(--text-value-b) var(--suffix, "");
695
+ font: var(--value-font);
696
+ }._post_uuidr_1 {
697
+ margin-bottom: 0.9375rem;
698
+ font-size: 0.9375rem;
699
+ line-height: 1.5;
700
+ background: var(--block-bg-color);
701
+ border: 0.0625rem solid var(--border-color);
702
+ border-radius: 0.5rem;
703
+ overflow: hidden;
704
+ padding: 0.75rem;
705
+ }
706
+
707
+ ._postHeader_uuidr_12 {
708
+ border-bottom: 0.0625rem dotted var(--border-color);
709
+ height: 3.625rem;
710
+ margin-bottom: 0.75rem;
711
+ display: grid;
712
+ grid-template-areas: "avatar user" "avatar date";
713
+ grid-template-rows: 1.5rem 1.5rem;
714
+ grid-template-columns: auto 1fr;
715
+ column-gap: 0.625rem;
716
+ }
717
+
718
+ ._avatar_uuidr_23 {
719
+ grid-area: avatar;
720
+ height: 3rem;
721
+ width: 3rem;
722
+ object-fit: cover;
723
+ border-radius: 50%;
724
+ }
725
+
726
+ ._user_uuidr_31 {
727
+ grid-area: user;
728
+ font-size: 1.0625rem;
729
+ font-weight: 500;
730
+ font-family: "Roboto", Arial, Helvetica, sans-serif;
731
+ line-height: 1.25;
732
+ }
733
+
734
+ ._date_uuidr_39 {
735
+ grid-area: date;
736
+ color: var(--link-color);
737
+ text-decoration: none;
738
+ font-size: 0.8125rem;
739
+ }
740
+
741
+ ._generationSettings_uuidr_46 {
742
+ display: grid;
743
+ grid-template-columns: 1fr 1fr;
744
+ }._wrapper_cfqzy_1 .bloc-spoil-jv {
745
+ margin-bottom: 0;
746
+ display: inline;
747
+ }
748
+ ._wrapper_cfqzy_1 .bloc-spoil-jv .open-spoil {
749
+ position: absolute;
750
+ left: -999rem;
751
+ }
752
+ ._wrapper_cfqzy_1 .bloc-spoil-jv .barre-head {
753
+ height: auto;
754
+ line-height: inherit;
755
+ text-align: center;
756
+ cursor: pointer;
757
+ position: relative;
758
+ display: inline;
759
+ }
760
+ ._wrapper_cfqzy_1 .bloc-spoil-jv .barre-head .txt-spoil {
761
+ position: static;
762
+ display: inline;
763
+ padding: 0.125rem 1.25rem;
764
+ line-height: inherit;
765
+ top: 0;
766
+ left: 0;
767
+ width: 4.6875rem;
768
+ font-size: 0.9285em;
769
+ text-align: center;
770
+ color: #fff;
771
+ text-transform: uppercase;
772
+ background: #fd374e;
773
+ font-weight: 700;
774
+ border-radius: 0.25rem;
775
+ }
776
+ ._wrapper_cfqzy_1 .bloc-spoil-jv .contenu-spoil {
777
+ background: #f4d6da;
778
+ color: #212121;
779
+ padding: 0.625rem;
780
+ display: none;
781
+ text-align: left;
782
+ overflow: hidden;
783
+ }
784
+ ._wrapper_cfqzy_1 .bloc-spoil-jv .open-spoil:checked ~ .contenu-spoil {
785
+ display: inline;
786
+ }
787
+ ._wrapper_cfqzy_1 blockquote {
788
+ text-align: left;
789
+ border-left: 0.3125rem solid rgba(0, 0, 0, 0.2);
790
+ color: var(--text-blockquote-color);
791
+ padding: 0.625rem;
792
+ background: none;
793
+ font-style: normal;
794
+ font-size: inherit;
795
+ margin: 0 0 0.9375rem 1rem;
796
+ }
797
+ ._wrapper_cfqzy_1 a {
798
+ color: var(--link-color);
799
+ text-decoration: none;
800
+ }
801
+ ._wrapper_cfqzy_1 a:hover {
802
+ color: var(--text-hover-secondary);
803
+ text-decoration: none;
804
+ }._wrapper_1dmrl_1 {
805
+ position: relative;
806
+ margin-bottom: 0.9375rem;
807
+ }
808
+
809
+ ._icon_1dmrl_6 {
810
+ position: absolute;
811
+ top: 0.625rem;
812
+ left: 0.625rem;
813
+ font-size: 1.125rem;
814
+ line-height: 1em;
815
+ }
816
+
817
+ ._input_1dmrl_14 {
818
+ display: block;
819
+ width: 100%;
820
+ font-weight: 400;
821
+ line-height: 1.5;
822
+ color: var(--input-text-color);
823
+ background-color: var(--input-bg-color);
824
+ background-clip: padding-box;
825
+ border: 0.0625rem solid var(--input-border-color);
826
+ -webkit-appearance: none;
827
+ appearance: none;
828
+ border-radius: 0.75rem;
829
+ box-shadow: inset 0 0.0625rem 0.125rem rgba(0, 0, 0, 0.075);
830
+ transition: border-color 0.15s ease-in-out, box-shadow 0.15s ease-in-out;
831
+ padding-top: 0;
832
+ padding-right: 0.3125rem;
833
+ padding-left: 2.5rem;
834
+ padding-bottom: 0;
835
+ font-weight: 700;
836
+ height: 2.5rem;
837
+ font-size: 1rem;
838
+ }
839
+ ._input_1dmrl_14::placeholder {
840
+ color: var(--input-placeholder-color);
841
+ font-weight: 400;
842
+ }._breadcrumbs_145yl_1 {
843
+ font-weight: 700;
844
+ color: var(--text-muted-color);
845
+ font-size: 0.8125rem;
846
+ margin-top: 1.25rem;
847
+ margin-bottom: 0.9375rem;
848
+ display: flex;
849
+ }
850
+
851
+ ._actions_145yl_10 {
852
+ margin-left: auto;
853
+ }
854
+ ._actions_145yl_10 a:hover {
855
+ color: var(--text-muted-hover-color);
856
+ }
dist/assets/index-bikKewjx.css DELETED
@@ -1 +0,0 @@
1
- @import"https://fonts.googleapis.com/css2?family=Roboto:ital,wght@0,100..900;1,100..900&display=swap";*:where(:not(html,iframe,canvas,img,svg,video,audio):not(svg *,symbol *)){all:unset;display:revert}*,*:before,*:after{box-sizing:border-box}html{-moz-text-size-adjust:none;-webkit-text-size-adjust:none;text-size-adjust:none}a,button{cursor:revert}ol,ul,menu,summary{list-style:none}ol{counter-reset:revert}img{max-inline-size:100%;max-block-size:100%}table{border-collapse:collapse}input,textarea{-webkit-user-select:auto}textarea{white-space:revert}meter{-webkit-appearance:revert;appearance:revert}:where(pre){all:revert;box-sizing:border-box}::placeholder{color:unset}:where([hidden]){display:none}:where([contenteditable]:not([contenteditable=false])){-moz-user-modify:read-write;-webkit-user-modify:read-write;overflow-wrap:break-word;-webkit-line-break:after-white-space;-webkit-user-select:auto}:where([draggable=true]){-webkit-user-drag:element}:where(dialog:modal){all:revert;box-sizing:border-box}::-webkit-details-marker{display:none}:root{color-scheme:dark;--body-bg: #22252a;--text-primary: #3d87f5;--text-hover-primary: #5596f6;--text-secondary: #f66031;--text-hover-secondary: #f7734a;--text-danger: #e4606d;--text-hover-danger: #dc3545;--text-dark: #e0e0e0;--text-hover-dark: #fff;--text-light: #000;--bg-color-light: #272a30;--bg-color-light-transparent: rgba(39, 42, 48, 0);--bg-color: #22252a;--text-color: #f2f2f2;--border-color: #4a4c4f;--border-even-color: #454f5e;--border-highlighted-color: #765d3f;--block-bg-color: #2e3238;--block-even-bg-color: #363e49;--block-highlighted-bg-color: #594126;--block-bg-color-hover: #353941;--block-bg-color-hover-dark: #454b54;--text-muted-color: #9e9e9e;--text-muted-hover-color: #bababa;--text-blockquote-color: #c7c7d1;--link-color: #7dc3f7;--link-hover-bg-color: #4c5767;--header-bg-color: #18191b;--header-bottom-bg-color: #000;--header-bottom-bg-color-hover: #303236;--video-footer-bg-color: #1d1e20;--layout-bg-color: #292d32;--disabled-bg-color: #1d1e20;--disabled-text-color: #787e87;--disabled-border-color: #787e87;--ad-bg-color: #18191b;--ad-border-color: #000;--game-header-bg-color: #2c2f35;--bg-light: #2c2f35;--game-tab-hover-bg-color: #17191c;--price-color: #9fafc6;--blue-light: #414a58;--live-color: #ff4d4d;--live-hover-color: #ff1a1a;--gauge-bg-color: #616161;--blue-gray-color: #9fafc6;--message-delete: #104e60;--message-delete-border: #092a34;--message-delete-gta: #46435b;--message-delete-gta-border: #191820;--input-bg-color: #303236;--input-border-color: #636569;--input-text-color: #f2f2f2;--input-placeholder-color: #616161;--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");--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>");--admin-color: #f24444;--modo-color: #42b228;--ad-placeholder-opacity: .4;--alert-brightness: .85;--filters-bg-color: #16191d;--gray-100: #f8f9fa;--gray-200: #e9ecef;--gray-300: #dee2e6;--gray-400: #ced4da;--gray-500: #adb5bd;--gray-600: #6c757d;--gray-700: #495057;--gray-800: #343a40;--gray-900: #212529;--white-rgb: #fff;--black-rgb: #000;--body-color-rgb: var(--text-color);--body-bg-rgb: var(--body-bg);--font-sans-serif: "Roboto", Arial, Helvetica, sans-serif;--font-monospace: SFMono-Regular, Menlo, Monaco, Consolas, "Liberation Mono", "Courier New", monospace;--gradient: linear-gradient(180deg, rgba(255, 255, 255, .15), rgba(255, 255, 255, 0));--root-font-size: 1rem;--body-font-family: "Roboto", Arial, Helvetica, sans-serif;--body-font-size: .9375rem;--body-font-weight: 400;--body-line-height: 1.5;--body-color: var(--text-color);--border-width: .0625rem;--border-style: solid;--border-color-translucent: rgba(0, 0, 0, .175);--border-radius: .75rem;--border-radius-sm: .5rem;--border-radius-lg: .75rem;--border-radius-xl: 1rem;--border-radius-2xl: 2rem;--border-radius-pill: 50rem;--link-hover-color: var(--text-hover-secondary);--code-color: #d63384;--highlight-bg: #fff3cd;--topic-font-size: .8125rem;--topic-font-weight: 700;--topic-line-height: 1.25;--topic-gap: .625rem;--topic-title-font-size: .9375rem;--topic-title-font-weight: 500}body{margin:0;font-family:var(--body-font-family),sans-serif;font-size:var(--body-font-size);font-weight:var(--body-font-weight);line-height:var(--body-line-height);color:var(--body-color);text-align:var(--body-text-align);background-color:var(--body-bg);-webkit-text-size-adjust:100%;-webkit-tap-highlight-color:rgba(0,0,0,0)}hr{height:1px;width:100%;background-color:var(--border-color);display:block;margin:1.5rem 0}h2{font-size:1.59375rem;line-height:1.25;font-weight:500;color:var(--text-color);padding-bottom:1.5rem}._header_1hnaa_1{background-color:var(--header-bg-color);color:var(--text-color)}._logo_1hnaa_6{font-size:2rem;font-weight:700}._container_1putz_1{margin:0 auto;min-width:20rem;max-width:73.5rem;padding:0 .5rem}._spinnerSquare_4vgl0_1{display:flex;flex-direction:row;width:90px;height:120px}._spinnerSquare_4vgl0_1>div{width:17px;height:80px;margin:auto;border-radius:4px}._square1_4vgl0_14{animation:_square-anim_4vgl0_1 1.2s cubic-bezier(.445,.05,.55,.95) 0s infinite}._square2_4vgl0_18{animation:_square-anim_4vgl0_1 1.2s cubic-bezier(.445,.05,.55,.95) .2s infinite}._square3_4vgl0_22{animation:_square-anim_4vgl0_1 1.2s cubic-bezier(.445,.05,.55,.95) .4s infinite}@keyframes _square-anim_4vgl0_1{0%{height:80px;background-color:var(--text-secondary)}20%{height:80px}40%{height:120px;background-color:var(--text-hover-secondary)}80%{height:80px}to{height:80px;background-color:var(--text-secondary)}}._spinner_1pqws_1{margin:5rem auto}._list_1pqws_5{display:grid;grid-template-columns:10fr 3fr 1fr 3fr;list-style-type:none;background:var(--block-bg-color);border:.0625rem solid var(--border-color);border-radius:.75rem;width:100%;padding:0;overflow:hidden;margin-bottom:1.5rem}._list_1pqws_5>li{display:contents;list-style:none;padding:0;margin:0}._list_1pqws_5>li>span{font-weight:var(--topic-font-weight);font-size:var(--topic-font-size);padding:var(--topic-gap)}._list_1pqws_5>li>span a{overflow:hidden;display:-webkit-box;-webkit-line-clamp:var(--topic-title-lines);-webkit-box-orient:vertical;color:var(--link-color);text-decoration:none;font-size:var(--topic-title-font-size);font-weight:var(--topic-title-font-weight)}._list_1pqws_5>li>span a:hover{color:var(--text-hover-secondary)}._list_1pqws_5>li:nth-child(2n)>span{background:var(--block-even-bg-color)}._list_1pqws_5>li._highlight_1pqws_44>span{background:var(--block-highlighted-bg-color)}._head_1pqws_48>span{text-transform:uppercase}._generationSettings_1pqws_52{display:grid;grid-template-columns:1fr 1fr}._btn_1ts7o_1{position:relative;display:inline-flex;justify-content:center;align-items:center;padding:0 1.25rem;margin:0;border:.0625rem solid var(--text-secondary);height:2.25rem;line-height:2.25rem;font-size:.9375rem;text-decoration:none;color:var(--text-secondary);border-radius:1.125rem;white-space:nowrap;cursor:pointer}._btn_1ts7o_1:not(._disabled_1ts7o_18):hover{border-color:var(--text-hover-secondary);color:var(--text-hover-secondary)}._btn_1ts7o_1._secondary_1ts7o_22{color:#fff;background-color:var(--text-secondary)}._btn_1ts7o_1._secondary_1ts7o_22:not(._disabled_1ts7o_18):hover{border-color:var(--text-hover-secondary);background:var(--text-hover-secondary);color:#fff}._spinner_1ts7o_32{font-size:10px;margin-right:1em;width:1.5em;height:1.5em;border-radius:50%;background:#fff;background:linear-gradient(to right,#fff 10%,#fff0 42%);position:relative;animation:_load3_1ts7o_1 1.4s infinite linear;transform:translateZ(0)}._spinner_1ts7o_32:before{width:50%;height:50%;background:#fff;border-radius:100% 0 0;position:absolute;top:0;left:0;content:""}._spinner_1ts7o_32:after{background:var(--text-secondary);width:75%;height:75%;border-radius:50%;content:"";margin:auto;position:absolute;inset:0}@keyframes _load3_1ts7o_1{0%{transform:rotate(0)}to{transform:rotate(360deg)}}._disabled_1ts7o_18{cursor:not-allowed}._disabled_1ts7o_18:after{content:"";position:absolute;width:100%;height:100%;background:#4f4f4f;border:.0625rem solid #4f4f4f;border-radius:1.125rem;opacity:.5;box-sizing:content-box}._formGroup_b3g81_1{display:flex;flex-direction:column;margin-bottom:1rem;justify-content:space-between}._formGroup_b3g81_1>*{flex-grow:0}._formGroup_b3g81_1 label{font-size:1rem;margin-bottom:1rem}._rangeSlider_1trvf_1{--primary-color: var(--text-secondary);--value-offset-y: var(--ticks-gap);--value-active-color: white;--value-background: transparent;--value-background-hover: var(--primary-color);--value-font: 700 12px/1 Arial;--fill-color: var(--primary-color);--progress-background: #eee;--progress-radius: 20px;--track-height: calc(var(--thumb-size) / 2);--min-max-font: 12px Arial;--min-max-opacity: .5;--min-max-x-offset: 50%;--thumb-size: 20px;--thumb-color: white;--thumb-shadow: 0 0 3px rgba(0, 0, 0, .4), 0 0 1px rgba(0, 0, 0, .5) inset, 0 0 0 99px var(--thumb-color) inset;--thumb-shadow-active: 0 0 0 calc(var(--thumb-size) / 4) inset var(--thumb-color), 0 0 0 99px var(--primary-color) inset, 0 0 3px rgba(0, 0, 0, .4);--thumb-shadow-hover: var(--thumb-shadow);--ticks-thickness: 1px;--ticks-height: 5px;--ticks-gap: var( --ticks-height, 0 );--ticks-color: silver;--step: 1;--ticks-count: Calc(var(--max) - var(--min)) / var(--step);--maxTicksAllowed: 30;--too-many-ticks: Min(1, Max(var(--ticks-count) - var(--maxTicksAllowed), 0));--x-step: Max( var(--step), var(--too-many-ticks) * (var(--max) - var(--min)) );--tickInterval: 100/ ((var(--max) - var(--min)) / var(--step)) * var(--tickEvery, 1);--tickIntervalPerc: calc( (100% - var(--thumb-size)) / ((var(--max) - var(--min)) / var(--x-step)) * var(--tickEvery, 1) );--value-a: Clamp( var(--min), var(--value, 0), var(--max) );--value-b: var(--value, 0);--text-value-a: var(--text-value, "");--completed-a: calc( (var(--value-a) - var(--min)) / (var(--max) - var(--min)) * 100 );--completed-b: calc( (var(--value-b) - var(--min)) / (var(--max) - var(--min)) * 100 );--ca: Min(var(--completed-a), var(--completed-b));--cb: Max(var(--completed-a), var(--completed-b));--thumbs-too-close: Clamp( -1, 1000 * (Min(1, Max(var(--cb) - var(--ca) - 5, -1)) + .001), 1 );display:inline-block;height:max(var(--track-height),var(--thumb-size));background:linear-gradient(to right,var(--ticks-color) var(--ticks-thickness),transparent 1px) repeat-x;background-size:var(--tickIntervalPerc) var(--ticks-height);background-position-x:calc(var(--thumb-size) / 2 - var(--ticks-thickness) / 2);background-position-y:var(--flip-y, bottom);padding-bottom:var(--flip-y, var(--ticks-gap));padding-top:calc(var(--flip-y) * var(--ticks-gap));margin-top:1rem;margin-bottom:2rem;position:relative;z-index:1}._rangeSlider_1trvf_1[data-ticks-position=top]{--flip-y: 1}._rangeSlider_1trvf_1:before,._rangeSlider_1trvf_1:after{--offset: calc(var(--thumb-size) / 2);content:counter(x);display:var(--show-min-max, block);font:var(--min-max-font);position:absolute;bottom:var(--flip-y, -2.5ch);top:calc(-2.5ch * var(--flip-y));opacity:var(--min-max-opacity);transform:translate(calc(var(--min-max-x-offset) * var(--before, -1) * -1));pointer-events:none}._rangeSlider_1trvf_1:before{--before: 1;counter-reset:x var(--min);left:var(--offset)}._rangeSlider_1trvf_1:after{counter-reset:x var(--max);right:var(--offset)}._rangeSlider__values_1trvf_99{position:relative;top:50%;line-height:0;text-align:justify;width:100%;pointer-events:none;margin:0 auto;z-index:5}._rangeSlider__values_1trvf_99:after{content:"";width:100%;display:inline-block;height:0;background:red}._rangeSlider_1trvf_1 ._progress_1trvf_116{--start-end: calc(var(--thumb-size) / 2);--clip-end: calc(100% - (var(--cb)) * 1%);--clip-start: calc(var(--ca) * 1%);--clip: inset(-20px var(--clip-end) -20px var(--clip-start));position:absolute;left:calc(var(--start-end) - 10px);right:calc(var(--start-end) - 10px);top:calc(var(--ticks-gap) * var(--flip-y, 0) + var(--thumb-size) / 2 - var(--track-height));height:calc(var(--track-height));background:var(--progress-background, #eee);pointer-events:none;z-index:-1;border-radius:var(--progress-radius)}._rangeSlider_1trvf_1 ._progress_1trvf_116:before{content:"";position:absolute;inset:0;clip-path:var(--clip);background:var(--fill-color, black);box-shadow:var(--progress-flll-shadow);z-index:1;border-radius:inherit}._rangeSlider_1trvf_1 ._progress_1trvf_116:after{content:"";position:absolute;inset:0;box-shadow:var(--progress-shadow);pointer-events:none;border-radius:inherit}._rangeSlider_1trvf_1>input{-webkit-appearance:none;width:100%;height:var(--thumb-size);margin:0;position:absolute;left:0;top:calc(50% - max(var(--track-height),var(--thumb-size)) / 2 + var(--ticks-gap) / 2 * var(--flip-y, -1));cursor:-webkit-grab;cursor:grab;outline:none;background:none}._rangeSlider_1trvf_1>input:not(:only-of-type){pointer-events:none}._rangeSlider_1trvf_1>input::-webkit-slider-thumb{appearance:none;height:var(--thumb-size);width:var(--thumb-size);transform:translateY(-4px);border-radius:var(--thumb-radius, 50%);background:var(--thumb-color);box-shadow:var(--thumb-shadow);border:none;pointer-events:auto;transition:.1s}._rangeSlider_1trvf_1>input::-moz-range-thumb{appearance:none;height:var(--thumb-size);width:var(--thumb-size);transform:translateY(-4px);border-radius:var(--thumb-radius, 50%);background:var(--thumb-color);box-shadow:var(--thumb-shadow);border:none;pointer-events:auto;transition:.1s}._rangeSlider_1trvf_1>input::-ms-thumb{appearance:none;height:var(--thumb-size);width:var(--thumb-size);transform:translateY(-4px);border-radius:var(--thumb-radius, 50%);background:var(--thumb-color);box-shadow:var(--thumb-shadow);border:none;pointer-events:auto;transition:.1s}._rangeSlider_1trvf_1>input:hover{--thumb-shadow: var(--thumb-shadow-hover)}._rangeSlider_1trvf_1>input:active{--thumb-shadow: var(--thumb-shadow-active);cursor:grabbing;z-index:2}._rangeSlider_1trvf_1>input:active+output{transition:0s}._rangeSlider_1trvf_1>input:nth-of-type(1){--is-left-most: Clamp(0, (var(--value-a) - var(--value-b)) * 99999, 1)}._rangeSlider_1trvf_1>input:nth-of-type(1)+output{--value: var(--value-a);--x-offset: calc(var(--completed-a) * -1%)}._rangeSlider_1trvf_1>input:nth-of-type(1)+output:not(:only-of-type){--flip: calc(var(--thumbs-too-close) * -1)}._rangeSlider_1trvf_1>input:nth-of-type(1)+output:after{content:var(--prefix, "") var(--text-value-a) var(--suffix, "")}._rangeSlider_1trvf_1>input:nth-of-type(2){--is-left-most: Clamp(0, (var(--value-b) - var(--value-a)) * 99999, 1)}._rangeSlider_1trvf_1>input:nth-of-type(2)+output{--value: var(--value-b)}._rangeSlider_1trvf_1>input:only-of-type~._progress_1trvf_116{--clip-start: 0}._rangeSlider_1trvf_1>input+output{--flip: -1;--x-offset: calc(var(--completed-b) * -1%);--pos: calc( ((var(--value) - var(--min)) / (var(--max) - var(--min))) * 100% );pointer-events:none;position:absolute;z-index:5;background:var(--value-background);border-radius:10px;padding:0 4px;left:var(--pos);transform:translate(var(--x-offset),calc(150% * var(--flip) - (var(--y-offset, 0px) + var(--value-offset-y)) * var(--flip)));transition:all .12s ease-out,left 0s}._rangeSlider_1trvf_1>input+output:after{content:var(--prefix, "") var(--text-value-b) var(--suffix, "");font:var(--value-font)}._post_uuidr_1{margin-bottom:.9375rem;font-size:.9375rem;line-height:1.5;background:var(--block-bg-color);border:.0625rem solid var(--border-color);border-radius:.5rem;overflow:hidden;padding:.75rem}._postHeader_uuidr_12{border-bottom:.0625rem dotted var(--border-color);height:3.625rem;margin-bottom:.75rem;display:grid;grid-template-areas:"avatar user" "avatar date";grid-template-rows:1.5rem 1.5rem;grid-template-columns:auto 1fr;column-gap:.625rem}._avatar_uuidr_23{grid-area:avatar;height:3rem;width:3rem;object-fit:cover;border-radius:50%}._user_uuidr_31{grid-area:user;font-size:1.0625rem;font-weight:500;font-family:Roboto,Arial,Helvetica,sans-serif;line-height:1.25}._date_uuidr_39{grid-area:date;color:var(--link-color);text-decoration:none;font-size:.8125rem}._generationSettings_uuidr_46{display:grid;grid-template-columns:1fr 1fr}._wrapper_cfqzy_1 .bloc-spoil-jv{margin-bottom:0;display:inline}._wrapper_cfqzy_1 .bloc-spoil-jv .open-spoil{position:absolute;left:-999rem}._wrapper_cfqzy_1 .bloc-spoil-jv .barre-head{height:auto;line-height:inherit;text-align:center;cursor:pointer;position:relative;display:inline}._wrapper_cfqzy_1 .bloc-spoil-jv .barre-head .txt-spoil{position:static;display:inline;padding:.125rem 1.25rem;line-height:inherit;top:0;left:0;width:4.6875rem;font-size:.9285em;text-align:center;color:#fff;text-transform:uppercase;background:#fd374e;font-weight:700;border-radius:.25rem}._wrapper_cfqzy_1 .bloc-spoil-jv .contenu-spoil{background:#f4d6da;color:#212121;padding:.625rem;display:none;text-align:left;overflow:hidden}._wrapper_cfqzy_1 .bloc-spoil-jv .open-spoil:checked~.contenu-spoil{display:inline}._wrapper_cfqzy_1 blockquote{text-align:left;border-left:.3125rem solid rgba(0,0,0,.2);color:var(--text-blockquote-color);padding:.625rem;background:none;font-style:normal;font-size:inherit;margin:0 0 .9375rem 1rem}._wrapper_cfqzy_1 a{color:var(--link-color);text-decoration:none}._wrapper_cfqzy_1 a:hover{color:var(--text-hover-secondary);text-decoration:none}._wrapper_1dmrl_1{position:relative;margin-bottom:.9375rem}._icon_1dmrl_6{position:absolute;top:.625rem;left:.625rem;font-size:1.125rem;line-height:1em}._input_1dmrl_14{display:block;width:100%;font-weight:400;line-height:1.5;color:var(--input-text-color);background-color:var(--input-bg-color);background-clip:padding-box;border:.0625rem solid var(--input-border-color);-webkit-appearance:none;appearance:none;border-radius:.75rem;box-shadow:inset 0 .0625rem .125rem #00000013;transition:border-color .15s ease-in-out,box-shadow .15s ease-in-out;padding-top:0;padding-right:.3125rem;padding-left:2.5rem;padding-bottom:0;font-weight:700;height:2.5rem;font-size:1rem}._input_1dmrl_14::placeholder{color:var(--input-placeholder-color);font-weight:400}._breadcrumbs_145yl_1{font-weight:700;color:var(--text-muted-color);font-size:.8125rem;margin-top:1.25rem;margin-bottom:.9375rem;display:flex}._actions_145yl_10{margin-left:auto}._actions_145yl_10 a:hover{color:var(--text-muted-hover-color)}
 
 
dist/index.html CHANGED
@@ -6,8 +6,8 @@
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-Cjniv5yr.js"></script>
10
- <link rel="stylesheet" crossorigin href="./assets/index-bikKewjx.css">
11
  </head>
12
  <body>
13
  <div id="app"></div>
 
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-C9o3CIT4.js"></script>
10
+ <link rel="stylesheet" crossorigin href="./assets/index-CvL5ef4j.css">
11
  </head>
12
  <body>
13
  <div id="app"></div>
vite.config.ts CHANGED
@@ -14,6 +14,7 @@ export default defineConfig({
14
  })
15
  ],
16
  build: {
17
- target: "es2022"
 
18
  },
19
  });
 
14
  })
15
  ],
16
  build: {
17
+ target: "es2022",
18
+ minify: false,
19
  },
20
  });