@bitux/review-layer-react 0.1.1 → 0.1.3

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -1,6 +1,6 @@
1
- import Qe, { useState as A, useEffect as $, useCallback as L, useRef as ge, useMemo as Ot, createContext as It, useContext as Lt } from "react";
2
- import { createPortal as Ke } from "react-dom";
3
- var Pe = { exports: {} }, ue = {};
1
+ import le, { memo as Rr, useState as A, useEffect as F, useCallback as j, useRef as mr, useMemo as $r, createContext as $e, useContext as Me } from "react";
2
+ import { createPortal as se } from "react-dom";
3
+ var Ar = { exports: {} }, lr = {};
4
4
  /**
5
5
  * @license React
6
6
  * react-jsx-runtime.production.min.js
@@ -10,21 +10,21 @@ var Pe = { exports: {} }, ue = {};
10
10
  * This source code is licensed under the MIT license found in the
11
11
  * LICENSE file in the root directory of this source tree.
12
12
  */
13
- var Xe;
14
- function At() {
15
- if (Xe) return ue;
16
- Xe = 1;
17
- var t = Qe, o = Symbol.for("react.element"), n = Symbol.for("react.fragment"), i = Object.prototype.hasOwnProperty, a = t.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED.ReactCurrentOwner, d = { key: !0, ref: !0, __self: !0, __source: !0 };
18
- function g(p, m, R) {
19
- var h, C = {}, w = null, O = null;
20
- R !== void 0 && (w = "" + R), m.key !== void 0 && (w = "" + m.key), m.ref !== void 0 && (O = m.ref);
21
- for (h in m) i.call(m, h) && !d.hasOwnProperty(h) && (C[h] = m[h]);
22
- if (p && p.defaultProps) for (h in m = p.defaultProps, m) C[h] === void 0 && (C[h] = m[h]);
23
- return { $$typeof: o, type: p, key: w, ref: O, props: C, _owner: a.current };
13
+ var oe;
14
+ function We() {
15
+ if (oe) return lr;
16
+ oe = 1;
17
+ var e = le, t = Symbol.for("react.element"), o = Symbol.for("react.fragment"), i = Object.prototype.hasOwnProperty, a = e.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED.ReactCurrentOwner, s = { key: !0, ref: !0, __self: !0, __source: !0 };
18
+ function v(g, d, w) {
19
+ var x, y = {}, P = null, S = null;
20
+ w !== void 0 && (P = "" + w), d.key !== void 0 && (P = "" + d.key), d.ref !== void 0 && (S = d.ref);
21
+ for (x in d) i.call(d, x) && !s.hasOwnProperty(x) && (y[x] = d[x]);
22
+ if (g && g.defaultProps) for (x in d = g.defaultProps, d) y[x] === void 0 && (y[x] = d[x]);
23
+ return { $$typeof: t, type: g, key: P, ref: S, props: y, _owner: a.current };
24
24
  }
25
- return ue.Fragment = n, ue.jsx = g, ue.jsxs = g, ue;
25
+ return lr.Fragment = o, lr.jsx = v, lr.jsxs = v, lr;
26
26
  }
27
- var ce = {};
27
+ var sr = {};
28
28
  /**
29
29
  * @license React
30
30
  * react-jsx-runtime.development.js
@@ -34,91 +34,91 @@ var ce = {};
34
34
  * This source code is licensed under the MIT license found in the
35
35
  * LICENSE file in the root directory of this source tree.
36
36
  */
37
- var Ge;
38
- function Ft() {
39
- return Ge || (Ge = 1, process.env.NODE_ENV !== "production" && function() {
40
- var t = Qe, o = Symbol.for("react.element"), n = Symbol.for("react.portal"), i = Symbol.for("react.fragment"), a = Symbol.for("react.strict_mode"), d = Symbol.for("react.profiler"), g = Symbol.for("react.provider"), p = Symbol.for("react.context"), m = Symbol.for("react.forward_ref"), R = Symbol.for("react.suspense"), h = Symbol.for("react.suspense_list"), C = Symbol.for("react.memo"), w = Symbol.for("react.lazy"), O = Symbol.for("react.offscreen"), _ = Symbol.iterator, I = "@@iterator";
41
- function z(e) {
42
- if (e === null || typeof e != "object")
37
+ var te;
38
+ function Be() {
39
+ return te || (te = 1, process.env.NODE_ENV !== "production" && function() {
40
+ var e = le, t = Symbol.for("react.element"), o = Symbol.for("react.portal"), i = Symbol.for("react.fragment"), a = Symbol.for("react.strict_mode"), s = Symbol.for("react.profiler"), v = Symbol.for("react.provider"), g = Symbol.for("react.context"), d = Symbol.for("react.forward_ref"), w = Symbol.for("react.suspense"), x = Symbol.for("react.suspense_list"), y = Symbol.for("react.memo"), P = Symbol.for("react.lazy"), S = Symbol.for("react.offscreen"), V = Symbol.iterator, $ = "@@iterator";
41
+ function L(r) {
42
+ if (r === null || typeof r != "object")
43
43
  return null;
44
- var r = _ && e[_] || e[I];
45
- return typeof r == "function" ? r : null;
44
+ var n = V && r[V] || r[$];
45
+ return typeof n == "function" ? n : null;
46
46
  }
47
- var u = t.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED;
48
- function f(e) {
47
+ var c = e.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED;
48
+ function p(r) {
49
49
  {
50
- for (var r = arguments.length, s = new Array(r > 1 ? r - 1 : 0), c = 1; c < r; c++)
51
- s[c - 1] = arguments[c];
52
- k("error", e, s);
50
+ for (var n = arguments.length, u = new Array(n > 1 ? n - 1 : 0), f = 1; f < n; f++)
51
+ u[f - 1] = arguments[f];
52
+ I("error", r, u);
53
53
  }
54
54
  }
55
- function k(e, r, s) {
55
+ function I(r, n, u) {
56
56
  {
57
- var c = u.ReactDebugCurrentFrame, E = c.getStackAddendum();
58
- E !== "" && (r += "%s", s = s.concat([E]));
59
- var b = s.map(function(y) {
60
- return String(y);
57
+ var f = c.ReactDebugCurrentFrame, E = f.getStackAddendum();
58
+ E !== "" && (n += "%s", u = u.concat([E]));
59
+ var R = u.map(function(h) {
60
+ return String(h);
61
61
  });
62
- b.unshift("Warning: " + r), Function.prototype.apply.call(console[e], console, b);
62
+ R.unshift("Warning: " + n), Function.prototype.apply.call(console[r], console, R);
63
63
  }
64
64
  }
65
- var U = !1, X = !1, K = !1, S = !1, j = !1, M;
66
- M = Symbol.for("react.module.reference");
67
- function W(e) {
68
- return !!(typeof e == "string" || typeof e == "function" || e === i || e === d || j || e === a || e === R || e === h || S || e === O || U || X || K || typeof e == "object" && e !== null && (e.$$typeof === w || e.$$typeof === C || e.$$typeof === g || e.$$typeof === p || e.$$typeof === m || // This needs to include all possible module reference object
65
+ var N = !1, H = !1, er = !1, or = !1, tr = !1, X;
66
+ X = Symbol.for("react.module.reference");
67
+ function m(r) {
68
+ return !!(typeof r == "string" || typeof r == "function" || r === i || r === s || tr || r === a || r === w || r === x || or || r === S || N || H || er || typeof r == "object" && r !== null && (r.$$typeof === P || r.$$typeof === y || r.$$typeof === v || r.$$typeof === g || r.$$typeof === d || // This needs to include all possible module reference object
69
69
  // types supported by any Flight configuration anywhere since
70
70
  // we don't know which Flight build this will end up being used
71
71
  // with.
72
- e.$$typeof === M || e.getModuleId !== void 0));
72
+ r.$$typeof === X || r.getModuleId !== void 0));
73
73
  }
74
- function re(e, r, s) {
75
- var c = e.displayName;
76
- if (c)
77
- return c;
78
- var E = r.displayName || r.name || "";
79
- return E !== "" ? s + "(" + E + ")" : s;
74
+ function C(r, n, u) {
75
+ var f = r.displayName;
76
+ if (f)
77
+ return f;
78
+ var E = n.displayName || n.name || "";
79
+ return E !== "" ? u + "(" + E + ")" : u;
80
80
  }
81
- function G(e) {
82
- return e.displayName || "Context";
81
+ function z(r) {
82
+ return r.displayName || "Context";
83
83
  }
84
- function V(e) {
85
- if (e == null)
84
+ function T(r) {
85
+ if (r == null)
86
86
  return null;
87
- if (typeof e.tag == "number" && f("Received an unexpected object in getComponentNameFromType(). This is likely a bug in React. Please file an issue."), typeof e == "function")
88
- return e.displayName || e.name || null;
89
- if (typeof e == "string")
90
- return e;
91
- switch (e) {
87
+ if (typeof r.tag == "number" && p("Received an unexpected object in getComponentNameFromType(). This is likely a bug in React. Please file an issue."), typeof r == "function")
88
+ return r.displayName || r.name || null;
89
+ if (typeof r == "string")
90
+ return r;
91
+ switch (r) {
92
92
  case i:
93
93
  return "Fragment";
94
- case n:
94
+ case o:
95
95
  return "Portal";
96
- case d:
96
+ case s:
97
97
  return "Profiler";
98
98
  case a:
99
99
  return "StrictMode";
100
- case R:
100
+ case w:
101
101
  return "Suspense";
102
- case h:
102
+ case x:
103
103
  return "SuspenseList";
104
104
  }
105
- if (typeof e == "object")
106
- switch (e.$$typeof) {
107
- case p:
108
- var r = e;
109
- return G(r) + ".Consumer";
105
+ if (typeof r == "object")
106
+ switch (r.$$typeof) {
110
107
  case g:
111
- var s = e;
112
- return G(s._context) + ".Provider";
113
- case m:
114
- return re(e, e.render, "ForwardRef");
115
- case C:
116
- var c = e.displayName || null;
117
- return c !== null ? c : V(e.type) || "Memo";
118
- case w: {
119
- var E = e, b = E._payload, y = E._init;
108
+ var n = r;
109
+ return z(n) + ".Consumer";
110
+ case v:
111
+ var u = r;
112
+ return z(u._context) + ".Provider";
113
+ case d:
114
+ return C(r, r.render, "ForwardRef");
115
+ case y:
116
+ var f = r.displayName || null;
117
+ return f !== null ? f : T(r.type) || "Memo";
118
+ case P: {
119
+ var E = r, R = E._payload, h = E._init;
120
120
  try {
121
- return V(y(b));
121
+ return T(h(R));
122
122
  } catch {
123
123
  return null;
124
124
  }
@@ -126,743 +126,764 @@ function Ft() {
126
126
  }
127
127
  return null;
128
128
  }
129
- var H = Object.assign, J = 0, ne, oe, x, q, ie, ae, se;
130
- function De() {
129
+ var G = Object.assign, Y = 0, J, dr, fr, nr, ir, _, q;
130
+ function ar() {
131
131
  }
132
- De.__reactDisabledLog = !0;
133
- function it() {
132
+ ar.__reactDisabledLog = !0;
133
+ function vr() {
134
134
  {
135
- if (J === 0) {
136
- ne = console.log, oe = console.info, x = console.warn, q = console.error, ie = console.group, ae = console.groupCollapsed, se = console.groupEnd;
137
- var e = {
135
+ if (Y === 0) {
136
+ J = console.log, dr = console.info, fr = console.warn, nr = console.error, ir = console.group, _ = console.groupCollapsed, q = console.groupEnd;
137
+ var r = {
138
138
  configurable: !0,
139
139
  enumerable: !0,
140
- value: De,
140
+ value: ar,
141
141
  writable: !0
142
142
  };
143
143
  Object.defineProperties(console, {
144
- info: e,
145
- log: e,
146
- warn: e,
147
- error: e,
148
- group: e,
149
- groupCollapsed: e,
150
- groupEnd: e
144
+ info: r,
145
+ log: r,
146
+ warn: r,
147
+ error: r,
148
+ group: r,
149
+ groupCollapsed: r,
150
+ groupEnd: r
151
151
  });
152
152
  }
153
- J++;
153
+ Y++;
154
154
  }
155
155
  }
156
- function at() {
156
+ function pr() {
157
157
  {
158
- if (J--, J === 0) {
159
- var e = {
158
+ if (Y--, Y === 0) {
159
+ var r = {
160
160
  configurable: !0,
161
161
  enumerable: !0,
162
162
  writable: !0
163
163
  };
164
164
  Object.defineProperties(console, {
165
- log: H({}, e, {
166
- value: ne
165
+ log: G({}, r, {
166
+ value: J
167
167
  }),
168
- info: H({}, e, {
169
- value: oe
168
+ info: G({}, r, {
169
+ value: dr
170
170
  }),
171
- warn: H({}, e, {
172
- value: x
171
+ warn: G({}, r, {
172
+ value: fr
173
173
  }),
174
- error: H({}, e, {
175
- value: q
174
+ error: G({}, r, {
175
+ value: nr
176
176
  }),
177
- group: H({}, e, {
178
- value: ie
177
+ group: G({}, r, {
178
+ value: ir
179
179
  }),
180
- groupCollapsed: H({}, e, {
181
- value: ae
180
+ groupCollapsed: G({}, r, {
181
+ value: _
182
182
  }),
183
- groupEnd: H({}, e, {
184
- value: se
183
+ groupEnd: G({}, r, {
184
+ value: q
185
185
  })
186
186
  });
187
187
  }
188
- J < 0 && f("disabledDepth fell below zero. This is a bug in React. Please file an issue.");
188
+ Y < 0 && p("disabledDepth fell below zero. This is a bug in React. Please file an issue.");
189
189
  }
190
190
  }
191
- var xe = u.ReactCurrentDispatcher, Ee;
192
- function fe(e, r, s) {
191
+ var Cr = c.ReactCurrentDispatcher, kr;
192
+ function gr(r, n, u) {
193
193
  {
194
- if (Ee === void 0)
194
+ if (kr === void 0)
195
195
  try {
196
196
  throw Error();
197
197
  } catch (E) {
198
- var c = E.stack.trim().match(/\n( *(at )?)/);
199
- Ee = c && c[1] || "";
198
+ var f = E.stack.trim().match(/\n( *(at )?)/);
199
+ kr = f && f[1] || "";
200
200
  }
201
201
  return `
202
- ` + Ee + e;
202
+ ` + kr + r;
203
203
  }
204
204
  }
205
- var we = !1, pe;
205
+ var Pr = !1, br;
206
206
  {
207
- var st = typeof WeakMap == "function" ? WeakMap : Map;
208
- pe = new st();
207
+ var ge = typeof WeakMap == "function" ? WeakMap : Map;
208
+ br = new ge();
209
209
  }
210
- function Oe(e, r) {
211
- if (!e || we)
210
+ function Mr(r, n) {
211
+ if (!r || Pr)
212
212
  return "";
213
213
  {
214
- var s = pe.get(e);
215
- if (s !== void 0)
216
- return s;
214
+ var u = br.get(r);
215
+ if (u !== void 0)
216
+ return u;
217
217
  }
218
- var c;
219
- we = !0;
218
+ var f;
219
+ Pr = !0;
220
220
  var E = Error.prepareStackTrace;
221
221
  Error.prepareStackTrace = void 0;
222
- var b;
223
- b = xe.current, xe.current = null, it();
222
+ var R;
223
+ R = Cr.current, Cr.current = null, vr();
224
224
  try {
225
- if (r) {
226
- var y = function() {
225
+ if (n) {
226
+ var h = function() {
227
227
  throw Error();
228
228
  };
229
- if (Object.defineProperty(y.prototype, "props", {
229
+ if (Object.defineProperty(h.prototype, "props", {
230
230
  set: function() {
231
231
  throw Error();
232
232
  }
233
233
  }), typeof Reflect == "object" && Reflect.construct) {
234
234
  try {
235
- Reflect.construct(y, []);
236
- } catch (N) {
237
- c = N;
235
+ Reflect.construct(h, []);
236
+ } catch (W) {
237
+ f = W;
238
238
  }
239
- Reflect.construct(e, [], y);
239
+ Reflect.construct(r, [], h);
240
240
  } else {
241
241
  try {
242
- y.call();
243
- } catch (N) {
244
- c = N;
242
+ h.call();
243
+ } catch (W) {
244
+ f = W;
245
245
  }
246
- e.call(y.prototype);
246
+ r.call(h.prototype);
247
247
  }
248
248
  } else {
249
249
  try {
250
250
  throw Error();
251
- } catch (N) {
252
- c = N;
251
+ } catch (W) {
252
+ f = W;
253
253
  }
254
- e();
254
+ r();
255
255
  }
256
- } catch (N) {
257
- if (N && c && typeof N.stack == "string") {
258
- for (var v = N.stack.split(`
259
- `), F = c.stack.split(`
260
- `), T = v.length - 1, P = F.length - 1; T >= 1 && P >= 0 && v[T] !== F[P]; )
261
- P--;
262
- for (; T >= 1 && P >= 0; T--, P--)
263
- if (v[T] !== F[P]) {
264
- if (T !== 1 || P !== 1)
256
+ } catch (W) {
257
+ if (W && f && typeof W.stack == "string") {
258
+ for (var b = W.stack.split(`
259
+ `), M = f.stack.split(`
260
+ `), D = b.length - 1, O = M.length - 1; D >= 1 && O >= 0 && b[D] !== M[O]; )
261
+ O--;
262
+ for (; D >= 1 && O >= 0; D--, O--)
263
+ if (b[D] !== M[O]) {
264
+ if (D !== 1 || O !== 1)
265
265
  do
266
- if (T--, P--, P < 0 || v[T] !== F[P]) {
267
- var Y = `
268
- ` + v[T].replace(" at new ", " at ");
269
- return e.displayName && Y.includes("<anonymous>") && (Y = Y.replace("<anonymous>", e.displayName)), typeof e == "function" && pe.set(e, Y), Y;
266
+ if (D--, O--, O < 0 || b[D] !== M[O]) {
267
+ var U = `
268
+ ` + b[D].replace(" at new ", " at ");
269
+ return r.displayName && U.includes("<anonymous>") && (U = U.replace("<anonymous>", r.displayName)), typeof r == "function" && br.set(r, U), U;
270
270
  }
271
- while (T >= 1 && P >= 0);
271
+ while (D >= 1 && O >= 0);
272
272
  break;
273
273
  }
274
274
  }
275
275
  } finally {
276
- we = !1, xe.current = b, at(), Error.prepareStackTrace = E;
276
+ Pr = !1, Cr.current = R, pr(), Error.prepareStackTrace = E;
277
277
  }
278
- var te = e ? e.displayName || e.name : "", Z = te ? fe(te) : "";
279
- return typeof e == "function" && pe.set(e, Z), Z;
278
+ var K = r ? r.displayName || r.name : "", Z = K ? gr(K) : "";
279
+ return typeof r == "function" && br.set(r, Z), Z;
280
280
  }
281
- function lt(e, r, s) {
282
- return Oe(e, !1);
281
+ function be(r, n, u) {
282
+ return Mr(r, !1);
283
283
  }
284
- function ut(e) {
285
- var r = e.prototype;
286
- return !!(r && r.isReactComponent);
284
+ function he(r) {
285
+ var n = r.prototype;
286
+ return !!(n && n.isReactComponent);
287
287
  }
288
- function he(e, r, s) {
289
- if (e == null)
288
+ function hr(r, n, u) {
289
+ if (r == null)
290
290
  return "";
291
- if (typeof e == "function")
292
- return Oe(e, ut(e));
293
- if (typeof e == "string")
294
- return fe(e);
295
- switch (e) {
296
- case R:
297
- return fe("Suspense");
298
- case h:
299
- return fe("SuspenseList");
291
+ if (typeof r == "function")
292
+ return Mr(r, he(r));
293
+ if (typeof r == "string")
294
+ return gr(r);
295
+ switch (r) {
296
+ case w:
297
+ return gr("Suspense");
298
+ case x:
299
+ return gr("SuspenseList");
300
300
  }
301
- if (typeof e == "object")
302
- switch (e.$$typeof) {
303
- case m:
304
- return lt(e.render);
305
- case C:
306
- return he(e.type, r, s);
307
- case w: {
308
- var c = e, E = c._payload, b = c._init;
301
+ if (typeof r == "object")
302
+ switch (r.$$typeof) {
303
+ case d:
304
+ return be(r.render);
305
+ case y:
306
+ return hr(r.type, n, u);
307
+ case P: {
308
+ var f = r, E = f._payload, R = f._init;
309
309
  try {
310
- return he(b(E), r, s);
310
+ return hr(R(E), n, u);
311
311
  } catch {
312
312
  }
313
313
  }
314
314
  }
315
315
  return "";
316
316
  }
317
- var le = Object.prototype.hasOwnProperty, Ie = {}, Le = u.ReactDebugCurrentFrame;
318
- function ve(e) {
319
- if (e) {
320
- var r = e._owner, s = he(e.type, e._source, r ? r.type : null);
321
- Le.setExtraStackFrame(s);
317
+ var ur = Object.prototype.hasOwnProperty, Wr = {}, Br = c.ReactDebugCurrentFrame;
318
+ function xr(r) {
319
+ if (r) {
320
+ var n = r._owner, u = hr(r.type, r._source, n ? n.type : null);
321
+ Br.setExtraStackFrame(u);
322
322
  } else
323
- Le.setExtraStackFrame(null);
323
+ Br.setExtraStackFrame(null);
324
324
  }
325
- function ct(e, r, s, c, E) {
325
+ function xe(r, n, u, f, E) {
326
326
  {
327
- var b = Function.call.bind(le);
328
- for (var y in e)
329
- if (b(e, y)) {
330
- var v = void 0;
327
+ var R = Function.call.bind(ur);
328
+ for (var h in r)
329
+ if (R(r, h)) {
330
+ var b = void 0;
331
331
  try {
332
- if (typeof e[y] != "function") {
333
- var F = Error((c || "React class") + ": " + s + " type `" + y + "` is invalid; it must be a function, usually from the `prop-types` package, but received `" + typeof e[y] + "`.This often happens because of typos such as `PropTypes.function` instead of `PropTypes.func`.");
334
- throw F.name = "Invariant Violation", F;
332
+ if (typeof r[h] != "function") {
333
+ var M = Error((f || "React class") + ": " + u + " type `" + h + "` is invalid; it must be a function, usually from the `prop-types` package, but received `" + typeof r[h] + "`.This often happens because of typos such as `PropTypes.function` instead of `PropTypes.func`.");
334
+ throw M.name = "Invariant Violation", M;
335
335
  }
336
- v = e[y](r, y, c, s, null, "SECRET_DO_NOT_PASS_THIS_OR_YOU_WILL_BE_FIRED");
337
- } catch (T) {
338
- v = T;
336
+ b = r[h](n, h, f, u, null, "SECRET_DO_NOT_PASS_THIS_OR_YOU_WILL_BE_FIRED");
337
+ } catch (D) {
338
+ b = D;
339
339
  }
340
- v && !(v instanceof Error) && (ve(E), f("%s: type specification of %s `%s` is invalid; the type checker function must return `null` or an `Error` but returned a %s. You may have forgotten to pass an argument to the type checker creator (arrayOf, instanceOf, objectOf, oneOf, oneOfType, and shape all require an argument).", c || "React class", s, y, typeof v), ve(null)), v instanceof Error && !(v.message in Ie) && (Ie[v.message] = !0, ve(E), f("Failed %s type: %s", s, v.message), ve(null));
340
+ b && !(b instanceof Error) && (xr(E), p("%s: type specification of %s `%s` is invalid; the type checker function must return `null` or an `Error` but returned a %s. You may have forgotten to pass an argument to the type checker creator (arrayOf, instanceOf, objectOf, oneOf, oneOfType, and shape all require an argument).", f || "React class", u, h, typeof b), xr(null)), b instanceof Error && !(b.message in Wr) && (Wr[b.message] = !0, xr(E), p("Failed %s type: %s", u, b.message), xr(null));
341
341
  }
342
342
  }
343
343
  }
344
- var dt = Array.isArray;
345
- function be(e) {
346
- return dt(e);
344
+ var ye = Array.isArray;
345
+ function jr(r) {
346
+ return ye(r);
347
347
  }
348
- function ft(e) {
348
+ function me(r) {
349
349
  {
350
- var r = typeof Symbol == "function" && Symbol.toStringTag, s = r && e[Symbol.toStringTag] || e.constructor.name || "Object";
351
- return s;
350
+ var n = typeof Symbol == "function" && Symbol.toStringTag, u = n && r[Symbol.toStringTag] || r.constructor.name || "Object";
351
+ return u;
352
352
  }
353
353
  }
354
- function pt(e) {
354
+ function we(r) {
355
355
  try {
356
- return Ae(e), !1;
356
+ return Yr(r), !1;
357
357
  } catch {
358
358
  return !0;
359
359
  }
360
360
  }
361
- function Ae(e) {
362
- return "" + e;
361
+ function Yr(r) {
362
+ return "" + r;
363
363
  }
364
- function Fe(e) {
365
- if (pt(e))
366
- return f("The provided key is an unsupported type %s. This value must be coerced to a string before before using it here.", ft(e)), Ae(e);
364
+ function Ur(r) {
365
+ if (we(r))
366
+ return p("The provided key is an unsupported type %s. This value must be coerced to a string before before using it here.", me(r)), Yr(r);
367
367
  }
368
- var $e = u.ReactCurrentOwner, ht = {
368
+ var Gr = c.ReactCurrentOwner, _e = {
369
369
  key: !0,
370
370
  ref: !0,
371
371
  __self: !0,
372
372
  __source: !0
373
- }, Ne, ze;
374
- function vt(e) {
375
- if (le.call(e, "ref")) {
376
- var r = Object.getOwnPropertyDescriptor(e, "ref").get;
377
- if (r && r.isReactWarning)
373
+ }, Hr, Xr;
374
+ function Ee(r) {
375
+ if (ur.call(r, "ref")) {
376
+ var n = Object.getOwnPropertyDescriptor(r, "ref").get;
377
+ if (n && n.isReactWarning)
378
378
  return !1;
379
379
  }
380
- return e.ref !== void 0;
380
+ return r.ref !== void 0;
381
381
  }
382
- function gt(e) {
383
- if (le.call(e, "key")) {
384
- var r = Object.getOwnPropertyDescriptor(e, "key").get;
385
- if (r && r.isReactWarning)
382
+ function Re(r) {
383
+ if (ur.call(r, "key")) {
384
+ var n = Object.getOwnPropertyDescriptor(r, "key").get;
385
+ if (n && n.isReactWarning)
386
386
  return !1;
387
387
  }
388
- return e.key !== void 0;
388
+ return r.key !== void 0;
389
389
  }
390
- function yt(e, r) {
391
- typeof e.ref == "string" && $e.current;
390
+ function Se(r, n) {
391
+ typeof r.ref == "string" && Gr.current;
392
392
  }
393
- function mt(e, r) {
393
+ function Ce(r, n) {
394
394
  {
395
- var s = function() {
396
- Ne || (Ne = !0, f("%s: `key` is not a prop. Trying to access it will result in `undefined` being returned. If you need to access the same value within the child component, you should pass it as a different prop. (https://reactjs.org/link/special-props)", r));
395
+ var u = function() {
396
+ Hr || (Hr = !0, p("%s: `key` is not a prop. Trying to access it will result in `undefined` being returned. If you need to access the same value within the child component, you should pass it as a different prop. (https://reactjs.org/link/special-props)", n));
397
397
  };
398
- s.isReactWarning = !0, Object.defineProperty(e, "key", {
399
- get: s,
398
+ u.isReactWarning = !0, Object.defineProperty(r, "key", {
399
+ get: u,
400
400
  configurable: !0
401
401
  });
402
402
  }
403
403
  }
404
- function xt(e, r) {
404
+ function ke(r, n) {
405
405
  {
406
- var s = function() {
407
- ze || (ze = !0, f("%s: `ref` is not a prop. Trying to access it will result in `undefined` being returned. If you need to access the same value within the child component, you should pass it as a different prop. (https://reactjs.org/link/special-props)", r));
406
+ var u = function() {
407
+ Xr || (Xr = !0, p("%s: `ref` is not a prop. Trying to access it will result in `undefined` being returned. If you need to access the same value within the child component, you should pass it as a different prop. (https://reactjs.org/link/special-props)", n));
408
408
  };
409
- s.isReactWarning = !0, Object.defineProperty(e, "ref", {
410
- get: s,
409
+ u.isReactWarning = !0, Object.defineProperty(r, "ref", {
410
+ get: u,
411
411
  configurable: !0
412
412
  });
413
413
  }
414
414
  }
415
- var Et = function(e, r, s, c, E, b, y) {
416
- var v = {
415
+ var Pe = function(r, n, u, f, E, R, h) {
416
+ var b = {
417
417
  // This tag allows us to uniquely identify this as a React Element
418
- $$typeof: o,
418
+ $$typeof: t,
419
419
  // Built-in properties that belong on the element
420
- type: e,
421
- key: r,
422
- ref: s,
423
- props: y,
420
+ type: r,
421
+ key: n,
422
+ ref: u,
423
+ props: h,
424
424
  // Record the component responsible for creating this element.
425
- _owner: b
425
+ _owner: R
426
426
  };
427
- return v._store = {}, Object.defineProperty(v._store, "validated", {
427
+ return b._store = {}, Object.defineProperty(b._store, "validated", {
428
428
  configurable: !1,
429
429
  enumerable: !1,
430
430
  writable: !0,
431
431
  value: !1
432
- }), Object.defineProperty(v, "_self", {
432
+ }), Object.defineProperty(b, "_self", {
433
433
  configurable: !1,
434
434
  enumerable: !1,
435
435
  writable: !1,
436
- value: c
437
- }), Object.defineProperty(v, "_source", {
436
+ value: f
437
+ }), Object.defineProperty(b, "_source", {
438
438
  configurable: !1,
439
439
  enumerable: !1,
440
440
  writable: !1,
441
441
  value: E
442
- }), Object.freeze && (Object.freeze(v.props), Object.freeze(v)), v;
442
+ }), Object.freeze && (Object.freeze(b.props), Object.freeze(b)), b;
443
443
  };
444
- function wt(e, r, s, c, E) {
444
+ function je(r, n, u, f, E) {
445
445
  {
446
- var b, y = {}, v = null, F = null;
447
- s !== void 0 && (Fe(s), v = "" + s), gt(r) && (Fe(r.key), v = "" + r.key), vt(r) && (F = r.ref, yt(r, E));
448
- for (b in r)
449
- le.call(r, b) && !ht.hasOwnProperty(b) && (y[b] = r[b]);
450
- if (e && e.defaultProps) {
451
- var T = e.defaultProps;
452
- for (b in T)
453
- y[b] === void 0 && (y[b] = T[b]);
446
+ var R, h = {}, b = null, M = null;
447
+ u !== void 0 && (Ur(u), b = "" + u), Re(n) && (Ur(n.key), b = "" + n.key), Ee(n) && (M = n.ref, Se(n, E));
448
+ for (R in n)
449
+ ur.call(n, R) && !_e.hasOwnProperty(R) && (h[R] = n[R]);
450
+ if (r && r.defaultProps) {
451
+ var D = r.defaultProps;
452
+ for (R in D)
453
+ h[R] === void 0 && (h[R] = D[R]);
454
454
  }
455
- if (v || F) {
456
- var P = typeof e == "function" ? e.displayName || e.name || "Unknown" : e;
457
- v && mt(y, P), F && xt(y, P);
455
+ if (b || M) {
456
+ var O = typeof r == "function" ? r.displayName || r.name || "Unknown" : r;
457
+ b && Ce(h, O), M && ke(h, O);
458
458
  }
459
- return Et(e, v, F, E, c, $e.current, y);
459
+ return Pe(r, b, M, E, f, Gr.current, h);
460
460
  }
461
461
  }
462
- var Re = u.ReactCurrentOwner, Me = u.ReactDebugCurrentFrame;
463
- function ee(e) {
464
- if (e) {
465
- var r = e._owner, s = he(e.type, e._source, r ? r.type : null);
466
- Me.setExtraStackFrame(s);
462
+ var Vr = c.ReactCurrentOwner, Jr = c.ReactDebugCurrentFrame;
463
+ function Q(r) {
464
+ if (r) {
465
+ var n = r._owner, u = hr(r.type, r._source, n ? n.type : null);
466
+ Jr.setExtraStackFrame(u);
467
467
  } else
468
- Me.setExtraStackFrame(null);
468
+ Jr.setExtraStackFrame(null);
469
469
  }
470
- var Se;
471
- Se = !1;
472
- function Ce(e) {
473
- return typeof e == "object" && e !== null && e.$$typeof === o;
470
+ var Tr;
471
+ Tr = !1;
472
+ function Dr(r) {
473
+ return typeof r == "object" && r !== null && r.$$typeof === t;
474
474
  }
475
- function We() {
475
+ function qr() {
476
476
  {
477
- if (Re.current) {
478
- var e = V(Re.current.type);
479
- if (e)
477
+ if (Vr.current) {
478
+ var r = T(Vr.current.type);
479
+ if (r)
480
480
  return `
481
481
 
482
- Check the render method of \`` + e + "`.";
482
+ Check the render method of \`` + r + "`.";
483
483
  }
484
484
  return "";
485
485
  }
486
486
  }
487
- function bt(e) {
487
+ function Ve(r) {
488
488
  return "";
489
489
  }
490
- var Ve = {};
491
- function Rt(e) {
490
+ var Zr = {};
491
+ function Te(r) {
492
492
  {
493
- var r = We();
494
- if (!r) {
495
- var s = typeof e == "string" ? e : e.displayName || e.name;
496
- s && (r = `
493
+ var n = qr();
494
+ if (!n) {
495
+ var u = typeof r == "string" ? r : r.displayName || r.name;
496
+ u && (n = `
497
497
 
498
- Check the top-level render call using <` + s + ">.");
498
+ Check the top-level render call using <` + u + ">.");
499
499
  }
500
- return r;
500
+ return n;
501
501
  }
502
502
  }
503
- function Be(e, r) {
503
+ function Qr(r, n) {
504
504
  {
505
- if (!e._store || e._store.validated || e.key != null)
505
+ if (!r._store || r._store.validated || r.key != null)
506
506
  return;
507
- e._store.validated = !0;
508
- var s = Rt(r);
509
- if (Ve[s])
507
+ r._store.validated = !0;
508
+ var u = Te(n);
509
+ if (Zr[u])
510
510
  return;
511
- Ve[s] = !0;
512
- var c = "";
513
- e && e._owner && e._owner !== Re.current && (c = " It was passed a child from " + V(e._owner.type) + "."), ee(e), f('Each child in a list should have a unique "key" prop.%s%s See https://reactjs.org/link/warning-keys for more information.', s, c), ee(null);
511
+ Zr[u] = !0;
512
+ var f = "";
513
+ r && r._owner && r._owner !== Vr.current && (f = " It was passed a child from " + T(r._owner.type) + "."), Q(r), p('Each child in a list should have a unique "key" prop.%s%s See https://reactjs.org/link/warning-keys for more information.', u, f), Q(null);
514
514
  }
515
515
  }
516
- function Ye(e, r) {
516
+ function Kr(r, n) {
517
517
  {
518
- if (typeof e != "object")
518
+ if (typeof r != "object")
519
519
  return;
520
- if (be(e))
521
- for (var s = 0; s < e.length; s++) {
522
- var c = e[s];
523
- Ce(c) && Be(c, r);
520
+ if (jr(r))
521
+ for (var u = 0; u < r.length; u++) {
522
+ var f = r[u];
523
+ Dr(f) && Qr(f, n);
524
524
  }
525
- else if (Ce(e))
526
- e._store && (e._store.validated = !0);
527
- else if (e) {
528
- var E = z(e);
529
- if (typeof E == "function" && E !== e.entries)
530
- for (var b = E.call(e), y; !(y = b.next()).done; )
531
- Ce(y.value) && Be(y.value, r);
525
+ else if (Dr(r))
526
+ r._store && (r._store.validated = !0);
527
+ else if (r) {
528
+ var E = L(r);
529
+ if (typeof E == "function" && E !== r.entries)
530
+ for (var R = E.call(r), h; !(h = R.next()).done; )
531
+ Dr(h.value) && Qr(h.value, n);
532
532
  }
533
533
  }
534
534
  }
535
- function St(e) {
535
+ function De(r) {
536
536
  {
537
- var r = e.type;
538
- if (r == null || typeof r == "string")
537
+ var n = r.type;
538
+ if (n == null || typeof n == "string")
539
539
  return;
540
- var s;
541
- if (typeof r == "function")
542
- s = r.propTypes;
543
- else if (typeof r == "object" && (r.$$typeof === m || // Note: Memo only checks outer props here.
540
+ var u;
541
+ if (typeof n == "function")
542
+ u = n.propTypes;
543
+ else if (typeof n == "object" && (n.$$typeof === d || // Note: Memo only checks outer props here.
544
544
  // Inner props are checked in the reconciler.
545
- r.$$typeof === C))
546
- s = r.propTypes;
545
+ n.$$typeof === y))
546
+ u = n.propTypes;
547
547
  else
548
548
  return;
549
- if (s) {
550
- var c = V(r);
551
- ct(s, e.props, "prop", c, e);
552
- } else if (r.PropTypes !== void 0 && !Se) {
553
- Se = !0;
554
- var E = V(r);
555
- f("Component %s declared `PropTypes` instead of `propTypes`. Did you misspell the property assignment?", E || "Unknown");
549
+ if (u) {
550
+ var f = T(n);
551
+ xe(u, r.props, "prop", f, r);
552
+ } else if (n.PropTypes !== void 0 && !Tr) {
553
+ Tr = !0;
554
+ var E = T(n);
555
+ p("Component %s declared `PropTypes` instead of `propTypes`. Did you misspell the property assignment?", E || "Unknown");
556
556
  }
557
- typeof r.getDefaultProps == "function" && !r.getDefaultProps.isReactClassApproved && f("getDefaultProps is only used on classic React.createClass definitions. Use a static property named `defaultProps` instead.");
557
+ typeof n.getDefaultProps == "function" && !n.getDefaultProps.isReactClassApproved && p("getDefaultProps is only used on classic React.createClass definitions. Use a static property named `defaultProps` instead.");
558
558
  }
559
559
  }
560
- function Ct(e) {
560
+ function Ie(r) {
561
561
  {
562
- for (var r = Object.keys(e.props), s = 0; s < r.length; s++) {
563
- var c = r[s];
564
- if (c !== "children" && c !== "key") {
565
- ee(e), f("Invalid prop `%s` supplied to `React.Fragment`. React.Fragment can only have `key` and `children` props.", c), ee(null);
562
+ for (var n = Object.keys(r.props), u = 0; u < n.length; u++) {
563
+ var f = n[u];
564
+ if (f !== "children" && f !== "key") {
565
+ Q(r), p("Invalid prop `%s` supplied to `React.Fragment`. React.Fragment can only have `key` and `children` props.", f), Q(null);
566
566
  break;
567
567
  }
568
568
  }
569
- e.ref !== null && (ee(e), f("Invalid attribute `ref` supplied to `React.Fragment`."), ee(null));
569
+ r.ref !== null && (Q(r), p("Invalid attribute `ref` supplied to `React.Fragment`."), Q(null));
570
570
  }
571
571
  }
572
- var Ue = {};
573
- function He(e, r, s, c, E, b) {
572
+ var re = {};
573
+ function ee(r, n, u, f, E, R) {
574
574
  {
575
- var y = W(e);
576
- if (!y) {
577
- var v = "";
578
- (e === void 0 || typeof e == "object" && e !== null && Object.keys(e).length === 0) && (v += " You likely forgot to export your component from the file it's defined in, or you might have mixed up default and named imports.");
579
- var F = bt();
580
- F ? v += F : v += We();
581
- var T;
582
- e === null ? T = "null" : be(e) ? T = "array" : e !== void 0 && e.$$typeof === o ? (T = "<" + (V(e.type) || "Unknown") + " />", v = " Did you accidentally export a JSX literal instead of a component?") : T = typeof e, f("React.jsx: type is invalid -- expected a string (for built-in components) or a class/function (for composite components) but got: %s.%s", T, v);
575
+ var h = m(r);
576
+ if (!h) {
577
+ var b = "";
578
+ (r === void 0 || typeof r == "object" && r !== null && Object.keys(r).length === 0) && (b += " You likely forgot to export your component from the file it's defined in, or you might have mixed up default and named imports.");
579
+ var M = Ve();
580
+ M ? b += M : b += qr();
581
+ var D;
582
+ r === null ? D = "null" : jr(r) ? D = "array" : r !== void 0 && r.$$typeof === t ? (D = "<" + (T(r.type) || "Unknown") + " />", b = " Did you accidentally export a JSX literal instead of a component?") : D = typeof r, p("React.jsx: type is invalid -- expected a string (for built-in components) or a class/function (for composite components) but got: %s.%s", D, b);
583
583
  }
584
- var P = wt(e, r, s, E, b);
585
- if (P == null)
586
- return P;
587
- if (y) {
588
- var Y = r.children;
589
- if (Y !== void 0)
590
- if (c)
591
- if (be(Y)) {
592
- for (var te = 0; te < Y.length; te++)
593
- Ye(Y[te], e);
594
- Object.freeze && Object.freeze(Y);
584
+ var O = je(r, n, u, E, R);
585
+ if (O == null)
586
+ return O;
587
+ if (h) {
588
+ var U = n.children;
589
+ if (U !== void 0)
590
+ if (f)
591
+ if (jr(U)) {
592
+ for (var K = 0; K < U.length; K++)
593
+ Kr(U[K], r);
594
+ Object.freeze && Object.freeze(U);
595
595
  } else
596
- f("React.jsx: Static children should always be an array. You are likely explicitly calling React.jsxs or React.jsxDEV. Use the Babel transform instead.");
596
+ p("React.jsx: Static children should always be an array. You are likely explicitly calling React.jsxs or React.jsxDEV. Use the Babel transform instead.");
597
597
  else
598
- Ye(Y, e);
598
+ Kr(U, r);
599
599
  }
600
- if (le.call(r, "key")) {
601
- var Z = V(e), N = Object.keys(r).filter(function(Dt) {
602
- return Dt !== "key";
603
- }), _e = N.length > 0 ? "{key: someKey, " + N.join(": ..., ") + ": ...}" : "{key: someKey}";
604
- if (!Ue[Z + _e]) {
605
- var kt = N.length > 0 ? "{" + N.join(": ..., ") + ": ...}" : "{}";
606
- f(`A props object containing a "key" prop is being spread into JSX:
600
+ if (ur.call(n, "key")) {
601
+ var Z = T(r), W = Object.keys(n).filter(function(Ne) {
602
+ return Ne !== "key";
603
+ }), Ir = W.length > 0 ? "{key: someKey, " + W.join(": ..., ") + ": ...}" : "{key: someKey}";
604
+ if (!re[Z + Ir]) {
605
+ var Fe = W.length > 0 ? "{" + W.join(": ..., ") + ": ...}" : "{}";
606
+ p(`A props object containing a "key" prop is being spread into JSX:
607
607
  let props = %s;
608
608
  <%s {...props} />
609
609
  React keys must be passed directly to JSX without using spread:
610
610
  let props = %s;
611
- <%s key={someKey} {...props} />`, _e, Z, kt, Z), Ue[Z + _e] = !0;
611
+ <%s key={someKey} {...props} />`, Ir, Z, Fe, Z), re[Z + Ir] = !0;
612
612
  }
613
613
  }
614
- return e === i ? Ct(P) : St(P), P;
614
+ return r === i ? Ie(O) : De(O), O;
615
615
  }
616
616
  }
617
- function _t(e, r, s) {
618
- return He(e, r, s, !0);
617
+ function Oe(r, n, u) {
618
+ return ee(r, n, u, !0);
619
619
  }
620
- function jt(e, r, s) {
621
- return He(e, r, s, !1);
620
+ function Le(r, n, u) {
621
+ return ee(r, n, u, !1);
622
622
  }
623
- var Tt = jt, Pt = _t;
624
- ce.Fragment = i, ce.jsx = Tt, ce.jsxs = Pt;
625
- }()), ce;
623
+ var ze = Le, Ae = Oe;
624
+ sr.Fragment = i, sr.jsx = ze, sr.jsxs = Ae;
625
+ }()), sr;
626
626
  }
627
- process.env.NODE_ENV === "production" ? Pe.exports = At() : Pe.exports = Ft();
628
- var l = Pe.exports;
629
- function $t(t) {
630
- if (t.id && /^[a-zA-Z][\w-]*$/.test(t.id))
631
- return `#${t.id}`;
632
- const o = [];
633
- let n = t;
634
- for (; n && n.nodeType === Node.ELEMENT_NODE; ) {
635
- let i = n.nodeName.toLowerCase();
636
- if (n.id && /^[a-zA-Z][\w-]*$/.test(n.id)) {
637
- o.unshift(`#${n.id}`);
627
+ process.env.NODE_ENV === "production" ? Ar.exports = We() : Ar.exports = Be();
628
+ var l = Ar.exports;
629
+ function Ye(e) {
630
+ if (e.id && /^[a-zA-Z][\w-]*$/.test(e.id))
631
+ return `#${e.id}`;
632
+ const t = [];
633
+ let o = e;
634
+ for (; o && o.nodeType === Node.ELEMENT_NODE; ) {
635
+ let i = o.nodeName.toLowerCase();
636
+ if (o.id && /^[a-zA-Z][\w-]*$/.test(o.id)) {
637
+ t.unshift(`#${o.id}`);
638
638
  break;
639
639
  }
640
- if (n.className && typeof n.className == "string") {
641
- const a = n.className.trim().split(/\s+/).filter(Boolean);
640
+ if (o.className && typeof o.className == "string") {
641
+ const a = o.className.trim().split(/\s+/).filter(Boolean);
642
642
  if (a.length > 0) {
643
- const d = a.filter((g) => /^[a-zA-Z][\w-]*$/.test(g)).slice(0, 2).map((g) => `.${g}`).join("");
644
- d && (i += d);
643
+ const s = a.filter((v) => /^[a-zA-Z][\w-]*$/.test(v)).slice(0, 2).map((v) => `.${v}`).join("");
644
+ s && (i += s);
645
645
  }
646
646
  }
647
- if (o.length > 0) {
648
- const a = n.parentElement;
647
+ if (t.length > 0) {
648
+ const a = o.parentElement;
649
649
  if (a) {
650
- const d = Array.from(a.children).filter(
651
- (g) => g.nodeName === n.nodeName
650
+ const s = Array.from(a.children).filter(
651
+ (v) => v.nodeName === o.nodeName
652
652
  );
653
- if (d.length > 1) {
654
- const g = d.indexOf(n) + 1;
655
- i += `:nth-child(${g})`;
653
+ if (s.length > 1) {
654
+ const v = s.indexOf(o) + 1;
655
+ i += `:nth-child(${v})`;
656
656
  }
657
657
  }
658
658
  }
659
- o.unshift(i), n = n.parentElement;
659
+ t.unshift(i), o = o.parentElement;
660
660
  }
661
- return o.join(" > ");
661
+ return t.join(" > ");
662
662
  }
663
- function et(t) {
664
- if (typeof document > "u" || !(t != null && t.trim())) return null;
663
+ const Ue = "[data-review-layer-root]", Ge = 16;
664
+ function Fr(e, t, o = Ge) {
665
+ if (typeof window > "u") return { x: e, y: t };
666
+ const i = o, a = o, s = window.innerWidth - o, v = window.innerHeight - o;
667
+ return {
668
+ x: Math.max(i, Math.min(s, e)),
669
+ y: Math.max(a, Math.min(v, t))
670
+ };
671
+ }
672
+ function ce(e) {
673
+ var t;
674
+ if (typeof document > "u" || !(e != null && e.trim())) return null;
665
675
  try {
666
- const o = document.querySelector(t);
667
- return o ? o.getBoundingClientRect() : null;
676
+ const o = document.querySelector(e);
677
+ return !o || (t = o.closest) != null && t.call(o, Ue) ? null : o.getBoundingClientRect();
668
678
  } catch {
669
679
  return null;
670
680
  }
671
681
  }
672
- function Nt(t) {
682
+ function He(e) {
673
683
  if (typeof window > "u")
674
684
  return { relativeX: 0, relativeY: 0 };
675
- const o = window.innerWidth, n = window.innerHeight;
685
+ const t = window.innerWidth, o = window.innerHeight;
676
686
  return {
677
- relativeX: o > 0 ? t.left / o : 0,
678
- relativeY: n > 0 ? t.top / n : 0
687
+ relativeX: t > 0 ? e.left / t : 0,
688
+ relativeY: o > 0 ? e.top / o : 0
679
689
  };
680
690
  }
681
- function zt(t) {
691
+ function Nr(e) {
682
692
  if (typeof window > "u")
683
693
  return {
684
- x: t.x ?? 0,
685
- y: t.y ?? 0
694
+ x: e.x ?? 0,
695
+ y: e.y ?? 0
686
696
  };
687
- const o = t.relativeX ?? null, n = t.relativeY ?? null;
688
- return o != null && n != null ? {
689
- x: o * window.innerWidth,
690
- y: n * window.innerHeight
697
+ const t = e.relativeX ?? e.relative_x ?? null, o = e.relativeY ?? e.relative_y ?? null;
698
+ return t != null && o != null ? {
699
+ x: t * window.innerWidth,
700
+ y: o * window.innerHeight
691
701
  } : {
692
- x: t.x ?? 0,
693
- y: t.y ?? 0
702
+ x: e.x ?? 0,
703
+ y: e.y ?? 0
694
704
  };
695
705
  }
696
- function ye(t) {
697
- if (t.selector) {
698
- const o = et(t.selector);
699
- if (o != null)
700
- return { x: o.left, y: o.top };
706
+ function Xe(e) {
707
+ const { x: t, y: o } = Nr(e), i = e.width ?? 100, a = e.height ?? 40;
708
+ return new DOMRect(t, o, i, a);
709
+ }
710
+ function wr(e) {
711
+ const t = (e.relativeX ?? e.relative_x) != null && (e.relativeY ?? e.relative_y) != null, o = e.x != null && e.y != null;
712
+ if (t || o)
713
+ return Nr(e);
714
+ if (e.selector) {
715
+ const i = ce(e.selector);
716
+ if (i != null)
717
+ return { x: i.left, y: i.top };
701
718
  }
702
- return zt(t);
719
+ return Nr(e);
703
720
  }
704
- const D = {
721
+ const k = {
705
722
  PENDING: "pending",
706
723
  DEV_FIXED: "dev_fixed",
707
724
  VALIDATED: "validated"
708
725
  };
709
- function de(t) {
726
+ function cr(e) {
710
727
  return {
711
728
  "Content-Type": "application/json",
712
- "x-review-key": t
729
+ "x-review-key": e
713
730
  };
714
731
  }
715
- async function Mt(t, o, n) {
716
- const i = await fetch(`${t}/reviewers`, {
717
- headers: de(o),
718
- signal: n == null ? void 0 : n.signal
732
+ async function Je(e, t, o) {
733
+ const i = await fetch(`${e}/reviewers`, {
734
+ headers: cr(t),
735
+ signal: o == null ? void 0 : o.signal
719
736
  });
720
737
  if (!i.ok) throw new Error("Failed to fetch reviewers");
721
738
  return (await i.json()).data ?? [];
722
739
  }
723
- async function Wt(t, o, n) {
724
- const i = await fetch(`${t}/comments`, {
740
+ async function qe(e, t, o) {
741
+ const i = await fetch(`${e}/comments`, {
725
742
  method: "POST",
726
- headers: de(o),
727
- body: JSON.stringify(n)
743
+ headers: cr(t),
744
+ body: JSON.stringify(o)
728
745
  });
729
746
  if (!i.ok) {
730
- const d = await i.json().catch(() => ({}));
731
- throw new Error(d.message || "Failed to create comment");
747
+ const s = await i.json().catch(() => ({}));
748
+ throw new Error(s.message || "Failed to create comment");
732
749
  }
733
750
  return (await i.json()).data;
734
751
  }
735
- async function Vt(t, o, n, i) {
736
- const a = new URLSearchParams({ url: n }), d = await fetch(`${t}/comments?${a}`, {
737
- headers: de(o),
752
+ async function Ze(e, t, o, i) {
753
+ const a = new URLSearchParams({ url: o }), s = await fetch(`${e}/comments?${a}`, {
754
+ headers: cr(t),
738
755
  signal: i == null ? void 0 : i.signal
739
756
  });
740
- if (!d.ok) throw new Error("Failed to fetch comments");
741
- return (await d.json()).data ?? [];
757
+ if (!s.ok) throw new Error("Failed to fetch comments");
758
+ return (await s.json()).data ?? [];
742
759
  }
743
- async function Bt(t, o, n, i) {
744
- const a = await fetch(`${t}/comments/${n}/status`, {
760
+ async function Qe(e, t, o, i) {
761
+ const a = await fetch(`${e}/comments/${o}/status`, {
745
762
  method: "PATCH",
746
- headers: de(o),
763
+ headers: cr(t),
747
764
  body: JSON.stringify({ status: i })
748
765
  });
749
766
  if (!a.ok) {
750
- const g = await a.json().catch(() => ({}));
751
- throw new Error(g.message || "Failed to update comment status");
767
+ const v = await a.json().catch(() => ({}));
768
+ throw new Error(v.message || "Failed to update comment status");
752
769
  }
753
770
  return (await a.json()).data;
754
771
  }
755
- async function Yt(t, o, n) {
756
- const i = await fetch(`${t}/comments/${n}`, {
772
+ async function Ke(e, t, o) {
773
+ const i = await fetch(`${e}/comments/${o}`, {
757
774
  method: "DELETE",
758
- headers: de(o)
775
+ headers: cr(t)
759
776
  });
760
777
  if (!i.ok) {
761
778
  const a = await i.json().catch(() => ({}));
762
779
  throw new Error(a.message || "Failed to delete comment");
763
780
  }
764
781
  }
765
- const Ut = {
782
+ const ro = {
766
783
  position: "fixed",
767
784
  inset: 0,
768
785
  zIndex: 999997,
769
786
  backgroundColor: "transparent"
770
- }, Ht = {
787
+ }, eo = {
771
788
  position: "fixed",
772
789
  minWidth: 320,
773
790
  maxWidth: 400,
774
- padding: 16,
775
- backgroundColor: "#fff",
776
- border: "1px solid #e8e8e8",
777
- borderRadius: 8,
778
- boxShadow: "0 8px 24px rgba(0,0,0,0.15)",
791
+ padding: "var(--ui-positive-Value_400, 16px)",
792
+ backgroundColor: "var(--ui-color-bg-surface-default, #fff)",
793
+ border: "1px solid var(--ui-color-border-subtle, #e8e8e8)",
794
+ borderRadius: "var(--ui-radius_8, 8px)",
795
+ boxShadow: "0 8px 24px var(--ui-color-black-alpha-20, rgba(0,0,0,0.15))",
779
796
  zIndex: 999998
780
- }, Xt = {
797
+ }, oo = {
781
798
  width: "100%",
782
799
  minHeight: 80,
783
- padding: "8px 12px",
784
- marginBottom: 12,
785
- border: "1px solid #d9d9d9",
786
- borderRadius: 6,
787
- fontSize: 14,
800
+ padding: "var(--ui-positive-Value_200, 8px) var(--ui-positive-Value_300, 12px)",
801
+ marginBottom: "var(--ui-positive-Value_200, 12px)",
802
+ border: "1px solid var(--ui-color-border-default, #d9d9d9)",
803
+ borderRadius: "var(--ui-radius_6, 6px)",
804
+ fontSize: "var(--ui-font-size-sm, 14px)",
805
+ fontFamily: "var(--ui-font-family-ui, 'Inter', sans-serif)",
788
806
  resize: "vertical",
789
807
  boxSizing: "border-box"
790
- }, Gt = {
808
+ }, to = {
791
809
  width: "100%",
792
- padding: "8px 12px",
793
- marginBottom: 12,
794
- border: "1px solid #d9d9d9",
795
- borderRadius: 6,
796
- fontSize: 14
797
- }, Jt = {
798
- padding: "8px 16px",
799
- backgroundColor: "#ff4d4f",
800
- color: "#fff",
810
+ padding: "var(--ui-positive-Value_200, 8px) var(--ui-positive-Value_300, 12px)",
811
+ marginBottom: "var(--ui-positive-Value_300, 12px)",
812
+ border: "1px solid var(--ui-color-border-default, #d9d9d9)",
813
+ borderRadius: "var(--ui-radius_6, 6px)",
814
+ fontSize: "var(--ui-font-size-sm, 14px)"
815
+ }, no = {
816
+ padding: "var(--ui-positive-Value_200, 8px) var(--ui-positive-Value_400, 16px)",
817
+ backgroundColor: "var(--ui-color-bg-fill-danger-default, #ff4d4f)",
818
+ color: "var(--ui-color-text-on-color, #fff)",
801
819
  border: "none",
802
- borderRadius: 6,
803
- fontSize: 14,
820
+ borderRadius: "var(--ui-radius_6, 6px)",
821
+ fontSize: "var(--ui-font-size-sm, 14px)",
804
822
  cursor: "pointer",
805
- fontWeight: 500
823
+ fontWeight: "var(--ui-font-weight-medium, 500)"
806
824
  };
807
- function qt({
808
- apiUrl: t,
809
- apiKey: o,
810
- reviewers: n,
825
+ function io({
826
+ apiUrl: e,
827
+ apiKey: t,
828
+ reviewers: o,
811
829
  position: i,
812
830
  payload: a,
813
- onClose: d,
814
- onSuccess: g
831
+ onClose: s,
832
+ onSuccess: v
815
833
  }) {
816
- var z;
817
- const [p, m] = A(""), [R, h] = A(
818
- ((z = n[0]) == null ? void 0 : z.id) ?? 0
819
- ), [C, w] = A(!1), [O, _] = A(null);
820
- $(() => {
821
- n.length > 0 && !R && h(n[0].id);
822
- }, [n, R]);
823
- const I = async (u) => {
824
- if (u.preventDefault(), !(!p.trim() || !R)) {
825
- w(!0), _(null);
826
- try {
827
- await Wt(t, o, {
828
- ...a,
829
- message: p.trim(),
830
- reviewerId: R
831
- }), g(), d();
832
- } catch (f) {
833
- _(f instanceof Error ? f.message : "Failed to send comment");
834
- } finally {
835
- w(!1);
834
+ var L;
835
+ const [g, d] = A(""), [w, x] = A(
836
+ ((L = o[0]) == null ? void 0 : L.id) ?? 0
837
+ ), [y, P] = A(!1), [S, V] = A(null);
838
+ F(() => {
839
+ o.length > 0 && !w && x(o[0].id);
840
+ }, [o, w]);
841
+ const $ = j(
842
+ async (c) => {
843
+ if (c.preventDefault(), !(!g.trim() || !w)) {
844
+ P(!0), V(null);
845
+ try {
846
+ await qe(e, t, {
847
+ ...a,
848
+ message: g.trim(),
849
+ reviewerId: w
850
+ }), v(), s();
851
+ } catch (p) {
852
+ V(p instanceof Error ? p.message : "Failed to send comment");
853
+ } finally {
854
+ P(!1);
855
+ }
836
856
  }
837
- }
838
- };
857
+ },
858
+ [e, t, a, g, w, v, s]
859
+ );
839
860
  return /* @__PURE__ */ l.jsxs(l.Fragment, { children: [
840
861
  /* @__PURE__ */ l.jsx(
841
862
  "div",
842
863
  {
843
864
  role: "presentation",
844
- style: Ut,
845
- onClick: d,
846
- onKeyDown: (u) => u.key === "Escape" && d()
865
+ style: ro,
866
+ onClick: s,
867
+ onKeyDown: (c) => c.key === "Escape" && s()
847
868
  }
848
869
  ),
849
870
  /* @__PURE__ */ l.jsx(
850
871
  "div",
851
872
  {
852
873
  style: {
853
- ...Ht,
874
+ ...eo,
854
875
  left: Math.min(i.x, typeof window < "u" ? window.innerWidth - 420 : i.x),
855
876
  top: i.y + 12
856
877
  },
857
- onClick: (u) => u.stopPropagation(),
858
- children: /* @__PURE__ */ l.jsxs("form", { onSubmit: I, children: [
878
+ onClick: (c) => c.stopPropagation(),
879
+ children: /* @__PURE__ */ l.jsxs("form", { onSubmit: $, children: [
859
880
  /* @__PURE__ */ l.jsx(
860
881
  "textarea",
861
882
  {
862
883
  placeholder: "Escribe tu comentario...",
863
- value: p,
864
- onChange: (u) => m(u.target.value),
865
- style: Xt,
884
+ value: g,
885
+ onChange: (c) => d(c.target.value),
886
+ style: oo,
866
887
  required: !0,
867
888
  autoFocus: !0
868
889
  }
@@ -870,109 +891,133 @@ function qt({
870
891
  /* @__PURE__ */ l.jsxs(
871
892
  "select",
872
893
  {
873
- value: R,
874
- onChange: (u) => h(Number(u.target.value)),
875
- style: Gt,
894
+ value: w,
895
+ onChange: (c) => x(Number(c.target.value)),
896
+ style: to,
876
897
  required: !0,
877
- disabled: n.length === 0,
898
+ disabled: o.length === 0,
878
899
  children: [
879
- /* @__PURE__ */ l.jsx("option", { value: "", children: n.length === 0 ? "No hay revisores (ejecuta php artisan db:seed en la API)" : "Selecciona revisor" }),
880
- n.map((u) => /* @__PURE__ */ l.jsx("option", { value: u.id, children: u.name }, u.id))
900
+ /* @__PURE__ */ l.jsx("option", { value: "", children: o.length === 0 ? "No hay revisores (ejecuta php artisan db:seed en la API)" : "Selecciona revisor" }),
901
+ o.map((c) => /* @__PURE__ */ l.jsx("option", { value: c.id, children: c.name }, c.id))
881
902
  ]
882
903
  }
883
904
  ),
884
- O && /* @__PURE__ */ l.jsx(
905
+ S && /* @__PURE__ */ l.jsx(
885
906
  "div",
886
907
  {
887
908
  style: {
888
- color: "#ff4d4f",
889
- fontSize: 12,
890
- marginBottom: 8
909
+ color: "var(--ui-color-text-danger-default, #ff4d4f)",
910
+ fontSize: "var(--ui-font-size-xs, 12px)",
911
+ marginBottom: "var(--ui-positive-Value_200, 8px)"
891
912
  },
892
- children: O
913
+ children: S
893
914
  }
894
915
  ),
895
- /* @__PURE__ */ l.jsx(
916
+ /* @__PURE__ */ l.jsx("div", { style: { display: "flex", justifyContent: "flex-end" }, children: /* @__PURE__ */ l.jsx(
896
917
  "button",
897
918
  {
898
919
  type: "submit",
899
- style: Jt,
900
- disabled: C || n.length === 0,
901
- children: C ? "Enviando..." : "Enviar comentario"
920
+ style: no,
921
+ disabled: y || o.length === 0,
922
+ children: y ? "Enviando..." : "Enviar comentario"
902
923
  }
903
- )
924
+ ) })
904
925
  ] })
905
926
  }
906
927
  )
907
928
  ] });
908
929
  }
909
- const Zt = {
910
- position: "fixed",
911
- outline: "2px solid #ff4d4f",
912
- outlineOffset: "2px",
913
- pointerEvents: "none",
914
- zIndex: 999997,
915
- boxSizing: "border-box"
916
- };
917
- function Qt({ selector: t, active: o }) {
918
- const [n, i] = A(null), a = L(() => {
919
- if (!o || !(t != null && t.trim())) {
920
- i(null);
930
+ const ao = Rr(io), uo = "var(--ui-color-red-500, #ef4444)";
931
+ function lo(e) {
932
+ return {
933
+ position: "fixed",
934
+ outline: `2px solid ${e}`,
935
+ outlineOffset: "var(--ui-positive-Value_200, 2px)",
936
+ pointerEvents: "none",
937
+ zIndex: 999997,
938
+ boxSizing: "border-box"
939
+ };
940
+ }
941
+ const so = Rr(function({
942
+ selector: t,
943
+ active: o,
944
+ fallbackComment: i,
945
+ outlineColor: a = uo
946
+ }) {
947
+ const [s, v] = A(null), g = j(() => {
948
+ if (!o) {
949
+ v(null);
921
950
  return;
922
951
  }
923
- const d = et(t);
924
- i(d);
925
- }, [t, o]);
926
- return $(() => {
927
- a();
928
- }, [a]), $(() => {
929
- if (!(!o || !(t != null && t.trim())))
930
- return window.addEventListener("scroll", a, !0), window.addEventListener("resize", a), () => {
931
- window.removeEventListener("scroll", a, !0), window.removeEventListener("resize", a);
952
+ const d = t != null && t.trim() ? ce(t) : null;
953
+ if (d) {
954
+ v(d);
955
+ return;
956
+ }
957
+ if (i) {
958
+ v(Xe(i));
959
+ return;
960
+ }
961
+ v(null);
962
+ }, [t, o, i]);
963
+ return F(() => {
964
+ g();
965
+ }, [g]), F(() => {
966
+ if (o)
967
+ return window.addEventListener("scroll", g, !0), window.addEventListener("resize", g), () => {
968
+ window.removeEventListener("scroll", g, !0), window.removeEventListener("resize", g);
932
969
  };
933
- }, [o, t, a]), !o || n == null ? null : /* @__PURE__ */ l.jsx(
970
+ }, [o, g]), !o || s == null ? null : /* @__PURE__ */ l.jsx(
934
971
  "div",
935
972
  {
936
973
  "aria-hidden": !0,
937
974
  style: {
938
- ...Zt,
939
- left: n.left,
940
- top: n.top,
941
- width: n.width,
942
- height: n.height
975
+ ...lo(a),
976
+ left: s.left,
977
+ top: s.top,
978
+ width: s.width,
979
+ height: s.height
943
980
  }
944
981
  }
945
982
  );
946
- }
947
- const ke = 32, Je = 5e6, B = {
948
- cardBg: "#ffffff",
949
- textDark: "#333333",
950
- textMuted: "#888888",
951
- border: "#cccccc",
952
- shadow: "0 4px 16px rgba(0, 0, 0, 0.12)"
953
- }, Kt = {
954
- [D.PENDING]: "Pendiente",
955
- [D.DEV_FIXED]: "Corregido Desarrollo",
956
- [D.VALIDATED]: "Validado"
957
- }, er = {
958
- [D.PENDING]: "PENDIENTE",
959
- [D.DEV_FIXED]: "CORREGIDO DESARROLLO",
960
- [D.VALIDATED]: "VALIDADO"
961
- }, Q = {
962
- [D.PENDING]: "rgb(240, 69, 69)",
963
- [D.DEV_FIXED]: "rgb(235, 179, 8)",
964
- [D.VALIDATED]: "rgb(33, 196, 94)"
983
+ }), _r = 32, ne = 15e5, Or = 250, B = {
984
+ cardBg: "var(--ui-color-bg-surface-default, #ffffff)",
985
+ cardFooterBg: "var(--ui-color-bg-surface-secondary-default, #f8fafc)",
986
+ textDark: "var(--ui-color-text-primary, #333333)",
987
+ textMuted: "var(--ui-color-text-secondary, #888888)",
988
+ border: "var(--ui-color-border-default, #cccccc)",
989
+ shadow: "var(--ui-shadow-card, 0 4px 16px rgba(0, 0, 0, 0.12))"
990
+ }, co = {
991
+ [k.PENDING]: "Pendiente",
992
+ [k.DEV_FIXED]: "Corregido",
993
+ [k.VALIDATED]: "Validado"
994
+ }, fo = {
995
+ [k.PENDING]: "PENDIENTE",
996
+ [k.DEV_FIXED]: "CORREGIDO",
997
+ [k.VALIDATED]: "VALIDADO"
998
+ }, rr = {
999
+ [k.PENDING]: "var(--ui-color-red-500, rgb(240, 69, 69))",
1000
+ [k.DEV_FIXED]: "var(--ui-color-yellow-500, rgb(235, 179, 8))",
1001
+ [k.VALIDATED]: "var(--ui-color-green-500, rgb(33, 196, 94))"
1002
+ }, ie = {
1003
+ [k.PENDING]: "var(--ui-color-bg-surface-danger-default, #fef2f2)",
1004
+ [k.DEV_FIXED]: "var(--ui-color-bg-surface-warning-default, #fffbeb)",
1005
+ [k.VALIDATED]: "var(--ui-color-bg-surface-success-default, #f0fdf4)"
1006
+ }, Er = {
1007
+ [k.PENDING]: "var(--ui-color-red-500, #ef4444)",
1008
+ [k.DEV_FIXED]: "var(--ui-color-orange-500, #f59e0b)",
1009
+ [k.VALIDATED]: "var(--ui-color-green-500, #22c55e)"
965
1010
  };
966
- function tr(t) {
967
- const o = t.trim().split(/\s+/);
968
- return o.length >= 2 ? (o[0][0] + o[o.length - 1][0]).toUpperCase() : t.slice(0, 2).toUpperCase() || "?";
1011
+ function vo(e) {
1012
+ const t = e.trim().split(/\s+/);
1013
+ return t.length >= 2 ? (t[0][0] + t[t.length - 1][0]).toUpperCase() : e.slice(0, 2).toUpperCase() || "?";
969
1014
  }
970
- const rr = () => /* @__PURE__ */ l.jsx("svg", { width: "12", height: "12", viewBox: "0 0 12 12", fill: "none", style: { marginRight: 4, flexShrink: 0 }, children: /* @__PURE__ */ l.jsx("path", { d: "M10 3L4.5 8.5L2 6", stroke: "currentColor", strokeWidth: "2", strokeLinecap: "round", strokeLinejoin: "round" }) }), nr = ({ color: t }) => /* @__PURE__ */ l.jsxs("svg", { width: "20", height: "20", viewBox: "0 0 24 24", fill: "none", style: { flexShrink: 0 }, children: [
1015
+ const po = () => /* @__PURE__ */ l.jsx("svg", { width: "12", height: "12", viewBox: "0 0 12 12", fill: "none", style: { marginRight: 4, flexShrink: 0 }, children: /* @__PURE__ */ l.jsx("path", { d: "M10 3L4.5 8.5L2 6", stroke: "currentColor", strokeWidth: "2", strokeLinecap: "round", strokeLinejoin: "round" }) }), go = ({ color: e }) => /* @__PURE__ */ l.jsxs("svg", { width: "20", height: "20", viewBox: "0 0 24 24", fill: "none", style: { flexShrink: 0 }, children: [
971
1016
  /* @__PURE__ */ l.jsx(
972
1017
  "path",
973
1018
  {
974
1019
  d: "M21 11.5a8.38 8.38 0 0 1-.9 3.8 8.5 8.5 0 0 1-7.6 4.7 8.38 8.38 0 0 1-3.8-.9L3 21l1.9-5.7a8.38 8.38 0 0 1-.9-3.8 8.5 8.5 0 0 1 4.7-7.6 8.38 8.38 0 0 1 3.8-.9h.5a8.48 8.48 0 0 1 8 8v.5z",
975
- stroke: t,
1020
+ stroke: e,
976
1021
  strokeWidth: "2",
977
1022
  strokeLinecap: "round",
978
1023
  strokeLinejoin: "round",
@@ -983,104 +1028,128 @@ const rr = () => /* @__PURE__ */ l.jsx("svg", { width: "12", height: "12", viewB
983
1028
  "path",
984
1029
  {
985
1030
  d: "M8 10h.01M12 10h.01M16 10h.01",
986
- stroke: "#fff",
1031
+ stroke: "var(--ui-color-white, #fff)",
987
1032
  strokeWidth: "1.5",
988
1033
  strokeLinecap: "round"
989
1034
  }
990
1035
  )
991
- ] }), or = (t) => ({
1036
+ ] }), bo = (e) => ({
992
1037
  position: "fixed",
993
- width: ke,
994
- height: ke,
1038
+ width: _r,
1039
+ height: _r,
995
1040
  borderRadius: "50%",
996
- backgroundColor: Q[t] ?? Q[D.PENDING],
997
- color: "#fff",
1041
+ backgroundColor: rr[e] ?? rr[k.PENDING],
1042
+ color: "var(--ui-color-text-on-color, #fff)",
998
1043
  display: "flex",
999
1044
  alignItems: "center",
1000
1045
  justifyContent: "center",
1001
1046
  cursor: "pointer",
1002
- fontFamily: "'Inter', sans-serif",
1003
- boxShadow: "0 2px 8px rgba(0,0,0,0.2)",
1047
+ fontFamily: "var(--ui-font-family-ui, 'Inter', sans-serif)",
1048
+ boxShadow: "0 2px 8px var(--ui-color-black-alpha-20, rgba(0,0,0,0.2))",
1004
1049
  zIndex: 999998,
1005
- border: "2px solid #fff"
1006
- }), ir = {
1050
+ border: "2px solid var(--ui-color-white, #fff)"
1051
+ }), ho = {
1007
1052
  position: "fixed",
1008
- maxWidth: 320,
1009
- padding: "16px 14px",
1053
+ width: Or,
1054
+ minWidth: Or,
1055
+ maxWidth: Or,
1056
+ boxSizing: "border-box",
1010
1057
  backgroundColor: B.cardBg,
1011
- borderRadius: 12,
1058
+ borderRadius: "var(--ui-radius_12, 12px)",
1012
1059
  boxShadow: B.shadow,
1013
- fontSize: 13,
1014
- fontFamily: "'Inter', sans-serif",
1060
+ fontSize: "var(--ui-font-size-sm, 14px)",
1061
+ fontFamily: "var(--ui-font-family-ui, 'Inter', sans-serif)",
1015
1062
  zIndex: 999999,
1016
1063
  pointerEvents: "auto"
1017
- }, ar = {
1064
+ }, xo = {
1018
1065
  display: "flex",
1019
1066
  alignItems: "center",
1020
1067
  justifyContent: "space-between",
1021
- gap: 10,
1022
- marginBottom: 12
1023
- }, sr = (t) => ({
1068
+ gap: "var(--ui-positive-Value_250, 10px)",
1069
+ borderBottom: `1px solid ${B.border}`,
1070
+ padding: "var(--ui-positive-Value_300, 12px)"
1071
+ }, yo = (e) => ({
1024
1072
  width: 40,
1025
1073
  height: 40,
1026
1074
  borderRadius: "50%",
1027
- backgroundColor: Q[t] ?? Q[D.PENDING],
1028
- color: "#fff",
1029
- border: "2px solid #fff",
1075
+ backgroundColor: rr[e] ?? rr[k.PENDING],
1076
+ color: "var(--ui-color-text-on-color, #fff)",
1077
+ border: "2px solid var(--ui-color-white, #fff)",
1030
1078
  display: "flex",
1031
1079
  alignItems: "center",
1032
1080
  justifyContent: "center",
1033
- fontSize: 14,
1034
- fontWeight: 700,
1035
- flexShrink: 0
1036
- }), lr = {
1081
+ fontSize: "var(--ui-font-size-sm, 14px)",
1082
+ fontWeight: "var(--ui-font-weight-bold, 700)",
1083
+ flexShrink: 0,
1084
+ overflow: "hidden"
1085
+ }), mo = Rr(function({
1086
+ reviewer: t,
1087
+ status: o
1088
+ }) {
1089
+ const i = t == null ? void 0 : t.image_url, a = (t == null ? void 0 : t.name) ?? "Revisor", s = yo(o);
1090
+ if (i && i.trim()) {
1091
+ const v = rr[o] ?? rr[k.PENDING];
1092
+ return /* @__PURE__ */ l.jsx("div", { style: { ...s, border: `2px solid ${v}` }, children: /* @__PURE__ */ l.jsx(
1093
+ "img",
1094
+ {
1095
+ src: i,
1096
+ alt: a,
1097
+ style: {
1098
+ width: "100%",
1099
+ height: "100%",
1100
+ objectFit: "cover"
1101
+ },
1102
+ loading: "lazy"
1103
+ }
1104
+ ) });
1105
+ }
1106
+ return /* @__PURE__ */ l.jsx("div", { style: s, children: vo(a) });
1107
+ }), wo = {
1037
1108
  flexShrink: 0,
1038
- width: 24,
1039
- height: 24,
1109
+ width: "var(--ui-positive-Value_600, 24px)",
1110
+ height: "var(--ui-positive-Value_600, 24px)",
1040
1111
  padding: 0,
1041
1112
  border: "none",
1042
- borderRadius: 6,
1113
+ borderRadius: "var(--ui-radius_6, 6px)",
1043
1114
  backgroundColor: "transparent",
1044
1115
  color: B.textDark,
1045
1116
  cursor: "pointer",
1046
- fontSize: 18,
1117
+ fontSize: "var(--ui-positive-Value_450, 18px)",
1047
1118
  lineHeight: 1,
1048
1119
  display: "flex",
1049
1120
  alignItems: "center",
1050
1121
  justifyContent: "center"
1051
- }, ur = (t) => {
1052
- const o = t === D.DEV_FIXED;
1122
+ }, _o = (e) => {
1123
+ const t = Er[e] ?? Er[k.PENDING];
1053
1124
  return {
1054
1125
  display: "inline-flex",
1055
1126
  alignItems: "center",
1056
- marginBottom: 10,
1057
- padding: "4px 10px",
1058
- borderRadius: 9999,
1059
- fontSize: 10,
1060
- fontWeight: 700,
1061
- fontFamily: "'Inter', sans-serif",
1127
+ padding: "var(--ui-positive-Value_50, 4px) var(--ui-positive-Value_100, 10px)",
1128
+ borderRadius: "var(--ui-radius_full, 9999px)",
1129
+ fontSize: "8px",
1130
+ fontWeight: "var(--ui-font-weight-bold, 700)",
1131
+ fontFamily: "var(--ui-font-family-ui, 'Inter', sans-serif)",
1062
1132
  textTransform: "uppercase",
1063
1133
  letterSpacing: "0.02em",
1064
- backgroundColor: Q[t] ?? Q[D.PENDING],
1065
- color: o ? B.textDark : "#fff"
1134
+ backgroundColor: ie[e] ?? ie[k.PENDING],
1135
+ color: t,
1136
+ border: `1px solid ${t}`
1066
1137
  };
1067
- }, cr = {
1138
+ }, Eo = {
1068
1139
  display: "block",
1069
- marginTop: 12,
1070
- marginBottom: 6,
1071
- fontSize: 10,
1072
- fontWeight: 600,
1073
- fontFamily: "'Inter', sans-serif",
1140
+ fontSize: "var(--ui-font-size-2xs, 10px)",
1141
+ fontWeight: "var(--ui-font-weight-semibold, 600)",
1142
+ fontFamily: "var(--ui-font-family-ui, 'Inter', sans-serif)",
1074
1143
  color: B.textMuted,
1075
1144
  textTransform: "uppercase",
1076
1145
  letterSpacing: "0.04em"
1077
- }, dr = {
1146
+ }, Ro = {
1078
1147
  width: "100%",
1079
- padding: "8px 12px",
1080
- paddingRight: 32,
1081
- fontSize: 13,
1082
- fontFamily: "'Inter', sans-serif",
1083
- borderRadius: 8,
1148
+ padding: "var(--ui-positive-Value_200, 8px) var(--ui-positive-Value_300, 12px)",
1149
+ paddingRight: "var(--ui-positive-Value_800, 32px)",
1150
+ fontSize: "var(--ui-font-size-xs, 13px)",
1151
+ fontFamily: "var(--ui-font-family-ui, 'Inter', sans-serif)",
1152
+ borderRadius: "var(--ui-radius_8, 8px)",
1084
1153
  border: `1px solid ${B.border}`,
1085
1154
  backgroundColor: B.cardBg,
1086
1155
  color: B.textDark,
@@ -1088,341 +1157,416 @@ const rr = () => /* @__PURE__ */ l.jsx("svg", { width: "12", height: "12", viewB
1088
1157
  appearance: "none",
1089
1158
  backgroundImage: `url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 12 12'%3E%3Cpath fill='%23333' d='M6 8L2 4h8z'/%3E%3C/svg%3E")`,
1090
1159
  backgroundRepeat: "no-repeat",
1091
- backgroundPosition: "right 10px center"
1092
- }, fr = {
1160
+ backgroundPosition: "right var(--ui-positive-Value_250, 10px) center"
1161
+ }, So = {
1093
1162
  display: "flex",
1094
1163
  alignItems: "center",
1095
1164
  justifyContent: "flex-end",
1096
- gap: 8,
1097
- marginTop: 14,
1098
- paddingTop: 12,
1099
- borderTop: `1px solid ${B.border}`
1100
- }, tt = {
1165
+ gap: "var(--ui-positive-Value_200, 8px)",
1166
+ padding: "var(--ui-positive-Value_300, 12px)",
1167
+ borderTop: `1px solid ${B.border}`,
1168
+ backgroundColor: B.cardFooterBg
1169
+ }, de = {
1101
1170
  minWidth: 100,
1102
- padding: "8px 14px",
1103
- fontSize: 13,
1104
- fontWeight: 600,
1105
- fontFamily: "'Inter', sans-serif",
1106
- borderRadius: 8,
1171
+ padding: "var(--ui-positive-Value_200, 8px) var(--ui-positive-Value_350, 14px)",
1172
+ fontSize: "var(--ui-font-size-xs, 13px)",
1173
+ fontWeight: "var(--ui-font-weight-semibold, 600)",
1174
+ fontFamily: "var(--ui-font-family-ui, 'Inter', sans-serif)",
1175
+ borderRadius: "var(--ui-radius_8, 8px)",
1107
1176
  cursor: "pointer",
1108
1177
  border: "none"
1109
- }, pr = {
1110
- ...tt,
1178
+ }, Co = {
1179
+ ...de,
1111
1180
  backgroundColor: "transparent",
1112
1181
  color: B.textDark
1113
- }, hr = {
1114
- ...tt,
1115
- backgroundColor: Q[D.VALIDATED],
1116
- color: "#fff"
1182
+ }, yr = "review-layer-resolve-btn", ko = [
1183
+ "pending",
1184
+ "dev_fixed",
1185
+ "validated"
1186
+ ], Po = {
1187
+ ...de,
1188
+ backgroundColor: "var(--ui-color-bg-fill-success-default, #22c55e)",
1189
+ color: "var(--ui-color-text-on-color, #fff)"
1117
1190
  };
1118
- function vr({
1119
- comment: t,
1120
- offset: o = { dx: 0, dy: 0 },
1121
- apiUrl: n,
1191
+ function jo({
1192
+ comment: e,
1193
+ offset: t = { dx: 0, dy: 0 },
1194
+ apiUrl: o,
1122
1195
  apiKey: i,
1123
- onStatusChange: a
1196
+ onStatusChange: a,
1197
+ reviewMode: s = !1
1124
1198
  }) {
1125
- var ne, oe;
1126
- const [d, g] = A(!1), [p, m] = A(!1), [R, h] = A(() => ye(t)), [C, w] = A(!1), [O, _] = A(null), I = ge(null), z = ge(null), u = ge(null), f = L(() => {
1127
- h(ye(t));
1128
- }, [t]);
1129
- $(() => {
1130
- f();
1131
- }, [f]), $(() => {
1199
+ var nr, ir;
1200
+ const [v, g] = A(!1), [d, w] = A(!1), [x, y] = A(() => wr(e)), [P, S] = A(!1), [V, $] = A(null), L = mr(null), c = mr(null), p = mr(null), I = j(() => {
1201
+ y(wr(e));
1202
+ }, [e]);
1203
+ F(() => {
1204
+ I();
1205
+ }, [I]), F(() => {
1132
1206
  if (!(typeof window > "u"))
1133
- return window.addEventListener("scroll", f, !0), window.addEventListener("resize", f), () => {
1134
- window.removeEventListener("scroll", f, !0), window.removeEventListener("resize", f);
1207
+ return window.addEventListener("scroll", I, !0), window.addEventListener("resize", I), () => {
1208
+ window.removeEventListener("scroll", I, !0), window.removeEventListener("resize", I);
1135
1209
  };
1136
- }, [f]);
1137
- const k = L(() => {
1138
- I.current !== null && (clearTimeout(I.current), I.current = null);
1139
- }, []), U = L(() => {
1140
- k(), g(!0);
1141
- }, [k]), X = L(() => {
1142
- p || (I.current = setTimeout(() => {
1143
- I.current = null, g(!1);
1144
- }, Je));
1145
- }, [p]), K = L(() => {
1146
- k(), g(!0);
1147
- }, [k]), S = L(() => {
1148
- p || (I.current = setTimeout(() => {
1149
- I.current = null, g(!1);
1150
- }, Je));
1151
- }, [p]), j = L(() => {
1152
- p ? (m(!1), g(!1)) : (m(!0), g(!0));
1153
- }, [p]);
1154
- $(() => {
1155
- if (!p) return;
1156
- const x = (q) => {
1157
- var ae, se;
1158
- const ie = q.target;
1159
- (ae = z.current) != null && ae.contains(ie) || (se = u.current) != null && se.contains(ie) || (m(!1), g(!1));
1210
+ }, [I]);
1211
+ const N = j(() => {
1212
+ L.current !== null && (clearTimeout(L.current), L.current = null);
1213
+ }, []), H = j(() => {
1214
+ s || (N(), g(!0));
1215
+ }, [s, N]), er = j(() => {
1216
+ d || (L.current = setTimeout(() => {
1217
+ L.current = null, g(!1);
1218
+ }, ne));
1219
+ }, [d]), or = j(() => {
1220
+ N(), g(!0);
1221
+ }, [N]), tr = j(() => {
1222
+ d || (L.current = setTimeout(() => {
1223
+ L.current = null, g(!1);
1224
+ }, ne));
1225
+ }, [d]), X = j(() => {
1226
+ if (s) {
1227
+ d && (w(!1), g(!1));
1228
+ return;
1229
+ }
1230
+ d ? (w(!1), g(!1)) : (w(!0), g(!0));
1231
+ }, [s, d]);
1232
+ F(() => {
1233
+ if (!d) return;
1234
+ const _ = (q) => {
1235
+ var vr, pr;
1236
+ const ar = q.target;
1237
+ (vr = c.current) != null && vr.contains(ar) || (pr = p.current) != null && pr.contains(ar) || (w(!1), g(!1));
1160
1238
  };
1161
- return document.addEventListener("mousedown", x, !0), () => document.removeEventListener("mousedown", x, !0);
1162
- }, [p]), $(() => () => k(), [k]);
1163
- const M = R.x + o.dx, W = R.y + o.dy, re = d, G = L(() => {
1164
- m(!1), g(!1);
1165
- }, []), V = async (x) => {
1166
- if (x !== t.status) {
1167
- _(null), w(!0);
1168
- try {
1169
- await Bt(n, i, t.id, x), a();
1170
- } catch (q) {
1171
- _(q instanceof Error ? q.message : "Error al actualizar");
1172
- } finally {
1173
- w(!1);
1239
+ return document.addEventListener("mousedown", _, !0), () => document.removeEventListener("mousedown", _, !0);
1240
+ }, [d]), F(() => () => N(), [N]), F(() => {
1241
+ s && (w(!1), g(!1));
1242
+ }, [s]);
1243
+ const m = x.x + t.dx, C = x.y + t.dy, { x: z, y: T } = Fr(m, C, _r / 2), G = v && !d, Y = j(() => {
1244
+ w(!1), g(!1);
1245
+ }, []), J = j(
1246
+ async (_) => {
1247
+ if (_ !== e.status) {
1248
+ $(null), S(!0);
1249
+ try {
1250
+ await Qe(o, i, e.id, _), a();
1251
+ } catch (q) {
1252
+ $(q instanceof Error ? q.message : "Error al actualizar");
1253
+ } finally {
1254
+ S(!1);
1255
+ }
1174
1256
  }
1175
- }
1176
- }, H = async () => {
1177
- _(null), w(!0);
1257
+ },
1258
+ [o, i, e.id, e.status, a]
1259
+ ), dr = j(async () => {
1260
+ $(null), S(!0);
1178
1261
  try {
1179
- await Yt(n, i, t.id), a(), G();
1180
- } catch (x) {
1181
- _(x instanceof Error ? x.message : "Error al eliminar");
1262
+ await Ke(o, i, e.id), a(), Y();
1263
+ } catch (_) {
1264
+ $(_ instanceof Error ? _.message : "Error al eliminar");
1182
1265
  } finally {
1183
- w(!1);
1266
+ S(!1);
1184
1267
  }
1185
- }, J = [
1186
- "pending",
1187
- "dev_fixed",
1188
- "validated"
1189
- ];
1268
+ }, [o, i, e.id, a, Y]), fr = $r(
1269
+ () => ({ ...bo(e.status), left: z, top: T, transform: "translate(-50%, -50%)" }),
1270
+ [e.status, z, T]
1271
+ );
1190
1272
  return /* @__PURE__ */ l.jsxs(l.Fragment, { children: [
1191
- /* @__PURE__ */ l.jsx(Qt, { selector: t.selector, active: re }),
1273
+ /* @__PURE__ */ l.jsx(
1274
+ so,
1275
+ {
1276
+ selector: e.selector,
1277
+ active: G,
1278
+ fallbackComment: e,
1279
+ outlineColor: Er[e.status] ?? Er[k.PENDING]
1280
+ }
1281
+ ),
1192
1282
  /* @__PURE__ */ l.jsx(
1193
1283
  "div",
1194
1284
  {
1195
- ref: z,
1285
+ ref: c,
1196
1286
  role: "button",
1197
1287
  tabIndex: 0,
1198
- "aria-label": `Comentario: ${t.message.slice(0, 30)}...`,
1199
- "aria-expanded": d,
1200
- style: {
1201
- ...or(t.status),
1202
- left: M,
1203
- top: W,
1204
- transform: "translate(-50%, -50%)"
1205
- },
1206
- onMouseEnter: U,
1207
- onMouseLeave: X,
1208
- onClick: j,
1209
- children: /* @__PURE__ */ l.jsx(nr, { color: "#fff" })
1288
+ "aria-label": `Comentario: ${e.message.slice(0, 30)}...`,
1289
+ "aria-expanded": v,
1290
+ style: fr,
1291
+ onMouseEnter: H,
1292
+ onMouseLeave: er,
1293
+ onClick: X,
1294
+ children: /* @__PURE__ */ l.jsx(go, { color: "var(--ui-color-white, #fff)" })
1210
1295
  }
1211
1296
  ),
1212
- d && /* @__PURE__ */ l.jsxs(
1297
+ v && /* @__PURE__ */ l.jsxs(
1213
1298
  "div",
1214
1299
  {
1215
- ref: u,
1300
+ ref: p,
1216
1301
  role: "dialog",
1217
1302
  "aria-label": "Detalle del comentario",
1218
1303
  style: {
1219
- ...ir,
1220
- left: M + ke / 2 + 6,
1221
- top: W
1304
+ ...ho,
1305
+ left: z + _r / 2 + 6,
1306
+ top: T
1222
1307
  },
1223
- onMouseEnter: K,
1224
- onMouseLeave: S,
1308
+ onMouseEnter: or,
1309
+ onMouseLeave: tr,
1225
1310
  children: [
1226
- /* @__PURE__ */ l.jsxs("div", { style: ar, children: [
1311
+ /* @__PURE__ */ l.jsxs("div", { style: xo, children: [
1227
1312
  /* @__PURE__ */ l.jsxs("div", { style: { display: "flex", alignItems: "center", gap: 10, flex: 1, minWidth: 0 }, children: [
1228
- /* @__PURE__ */ l.jsx("div", { style: sr(t.status), children: tr(((ne = t.reviewer) == null ? void 0 : ne.name) ?? "Revisor") }),
1313
+ /* @__PURE__ */ l.jsx(mo, { reviewer: e.reviewer, status: e.status }),
1229
1314
  /* @__PURE__ */ l.jsxs("div", { children: [
1230
- /* @__PURE__ */ l.jsx("div", { style: { fontWeight: 700, fontSize: 14, color: B.textDark }, children: ((oe = t.reviewer) == null ? void 0 : oe.name) ?? "Revisor" }),
1231
- /* @__PURE__ */ l.jsx("div", { style: { fontSize: 12, color: B.textMuted }, children: "Revisor" })
1315
+ /* @__PURE__ */ l.jsx("div", { style: { fontWeight: 700, fontSize: 14, color: B.textDark }, children: ((nr = e.reviewer) == null ? void 0 : nr.name) ?? "Revisor" }),
1316
+ /* @__PURE__ */ l.jsx("div", { style: { fontSize: 12, color: B.textMuted }, children: ((ir = e.reviewer) == null ? void 0 : ir.job_title) ?? "Revisor" })
1232
1317
  ] })
1233
1318
  ] }),
1234
1319
  /* @__PURE__ */ l.jsx(
1235
1320
  "button",
1236
1321
  {
1237
1322
  type: "button",
1238
- "aria-label": t.status === D.VALIDATED ? "Eliminar comentario" : "Cerrar",
1239
- style: lr,
1240
- disabled: C,
1241
- onClick: (x) => {
1242
- x.stopPropagation(), t.status === D.VALIDATED ? H() : G();
1323
+ "aria-label": e.status === k.VALIDATED ? "Eliminar comentario" : "Cerrar",
1324
+ style: wo,
1325
+ disabled: P,
1326
+ onClick: (_) => {
1327
+ _.stopPropagation(), e.status === k.VALIDATED ? dr() : Y();
1243
1328
  },
1244
- onMouseDown: (x) => x.stopPropagation(),
1329
+ onMouseDown: (_) => _.stopPropagation(),
1245
1330
  children: "✕"
1246
1331
  }
1247
1332
  )
1248
1333
  ] }),
1249
- /* @__PURE__ */ l.jsxs("div", { style: ur(t.status), children: [
1250
- t.status === D.VALIDATED && /* @__PURE__ */ l.jsx(rr, {}),
1251
- er[t.status] ?? t.status
1334
+ /* @__PURE__ */ l.jsxs("div", { style: { padding: 12, display: "flex", alignItems: "flex-start", flexDirection: "column", gap: 4 }, children: [
1335
+ /* @__PURE__ */ l.jsxs("div", { style: _o(e.status), children: [
1336
+ e.status === k.VALIDATED && /* @__PURE__ */ l.jsx(po, {}),
1337
+ fo[e.status] ?? e.status
1338
+ ] }),
1339
+ /* @__PURE__ */ l.jsx("div", { style: { color: B.textDark, lineHeight: 1.5, marginBottom: 12, marginTop: 12 }, children: e.message }),
1340
+ /* @__PURE__ */ l.jsxs("div", { style: { display: "flex", flexDirection: "column", gap: 4, width: "100%" }, children: [
1341
+ /* @__PURE__ */ l.jsx("label", { style: Eo, htmlFor: `comment-status-${e.id}`, children: "Cambiar estado" }),
1342
+ /* @__PURE__ */ l.jsx(
1343
+ "select",
1344
+ {
1345
+ id: `comment-status-${e.id}`,
1346
+ style: Ro,
1347
+ value: e.status,
1348
+ disabled: P,
1349
+ onChange: (_) => J(_.target.value),
1350
+ onMouseDown: (_) => _.stopPropagation(),
1351
+ "aria-label": "Cambiar estado del comentario",
1352
+ children: ko.map((_) => /* @__PURE__ */ l.jsx("option", { value: _, children: co[_] }, _))
1353
+ }
1354
+ ),
1355
+ V && /* @__PURE__ */ l.jsx("div", { style: { marginTop: 8, fontSize: 11, color: "var(--ui-color-text-danger-default, rgb(240, 69, 69))" }, children: V })
1356
+ ] })
1252
1357
  ] }),
1253
- /* @__PURE__ */ l.jsx("div", { style: { color: B.textDark, lineHeight: 1.5 }, children: t.message }),
1254
- /* @__PURE__ */ l.jsx("label", { style: cr, htmlFor: `comment-status-${t.id}`, children: "Cambiar estado" }),
1255
- /* @__PURE__ */ l.jsx(
1256
- "select",
1257
- {
1258
- id: `comment-status-${t.id}`,
1259
- style: dr,
1260
- value: t.status,
1261
- disabled: C,
1262
- onChange: (x) => V(x.target.value),
1263
- onMouseDown: (x) => x.stopPropagation(),
1264
- "aria-label": "Cambiar estado del comentario",
1265
- children: J.map((x) => /* @__PURE__ */ l.jsx("option", { value: x, children: Kt[x] }, x))
1266
- }
1267
- ),
1268
- O && /* @__PURE__ */ l.jsx("div", { style: { marginTop: 8, fontSize: 11, color: "rgb(240, 69, 69)" }, children: O }),
1269
- /* @__PURE__ */ l.jsxs("div", { style: fr, children: [
1358
+ /* @__PURE__ */ l.jsxs("div", { style: So, children: [
1270
1359
  /* @__PURE__ */ l.jsx(
1271
1360
  "button",
1272
1361
  {
1273
1362
  type: "button",
1274
- style: pr,
1275
- onMouseDown: (x) => x.stopPropagation(),
1276
- onClick: (x) => {
1277
- x.stopPropagation(), G();
1363
+ style: Co,
1364
+ onMouseDown: (_) => _.stopPropagation(),
1365
+ onClick: (_) => {
1366
+ _.stopPropagation(), Y();
1278
1367
  },
1279
1368
  children: "Cerrar"
1280
1369
  }
1281
1370
  ),
1282
- t.status !== D.VALIDATED && /* @__PURE__ */ l.jsx(
1283
- "button",
1284
- {
1285
- type: "button",
1286
- style: hr,
1287
- disabled: C,
1288
- onMouseDown: (x) => x.stopPropagation(),
1289
- onClick: (x) => {
1290
- x.stopPropagation(), V("validated");
1291
- },
1292
- children: "Resolver hilo"
1293
- }
1294
- )
1371
+ e.status !== k.VALIDATED && /* @__PURE__ */ l.jsxs(l.Fragment, { children: [
1372
+ /* @__PURE__ */ l.jsx("style", { children: `
1373
+ .${yr}:hover:not(:disabled) {
1374
+ background-color: var(--ui-color-bg-fill-success-hover, #16a34a) !important;
1375
+ }
1376
+ .${yr}:active:not(:disabled) {
1377
+ background-color: var(--ui-color-bg-fill-success-pressed, #15803d) !important;
1378
+ }
1379
+ .${yr}:disabled {
1380
+ background-color: var(--ui-color-bg-fill-success-default, #22c55e) !important;
1381
+ opacity: 0.7;
1382
+ cursor: not-allowed;
1383
+ }
1384
+ ` }),
1385
+ /* @__PURE__ */ l.jsx(
1386
+ "button",
1387
+ {
1388
+ type: "button",
1389
+ className: yr,
1390
+ style: Po,
1391
+ disabled: P,
1392
+ onMouseDown: (_) => _.stopPropagation(),
1393
+ onClick: (_) => {
1394
+ _.stopPropagation(), J("validated");
1395
+ },
1396
+ children: "Validar"
1397
+ }
1398
+ )
1399
+ ] })
1295
1400
  ] })
1296
1401
  ]
1297
1402
  }
1298
1403
  )
1299
1404
  ] });
1300
1405
  }
1301
- const gr = 25, yr = 36;
1302
- function mr(t) {
1303
- const o = /* @__PURE__ */ new Map();
1304
- for (let n = 0; n < t.length; n++) {
1305
- const i = t[n], { x: a, y: d } = ye(i);
1306
- let g = 0;
1307
- for (let p = 0; p < n; p++) {
1308
- const m = t[p], { x: R, y: h } = ye(m);
1309
- Math.hypot(a - R, d - h) < gr && g++;
1406
+ const Vo = Rr(jo), To = 25, Do = 36;
1407
+ function Io(e) {
1408
+ const t = /* @__PURE__ */ new Map();
1409
+ for (let o = 0; o < e.length; o++) {
1410
+ const i = e[o], { x: a, y: s } = wr(i), { x: v, y: g } = Fr(a, s);
1411
+ let d = 0;
1412
+ for (let w = 0; w < o; w++) {
1413
+ const { x, y } = wr(e[w]), { x: P, y: S } = Fr(x, y);
1414
+ Math.hypot(v - P, g - S) < To && d++;
1310
1415
  }
1311
- o.set(i.id, { dx: g * yr, dy: 0 });
1416
+ t.set(i.id, { dx: d * Do, dy: 0 });
1312
1417
  }
1313
- return o;
1418
+ return t;
1314
1419
  }
1315
- function xr() {
1420
+ function Oo() {
1316
1421
  return typeof window > "u" ? "" : `${window.innerWidth}x${window.innerHeight}`;
1317
1422
  }
1318
- function Er({
1319
- apiUrl: t,
1320
- apiKey: o,
1321
- reviewMode: n,
1322
- reviewers: i,
1323
- comments: a,
1324
- loadComments: d,
1423
+ function Lo({
1424
+ apiUrl: e,
1425
+ apiKey: t,
1426
+ reviewMode: o,
1427
+ setReviewMode: i,
1428
+ reviewers: a,
1429
+ comments: s,
1430
+ loadComments: v,
1325
1431
  commentsLoadFailed: g = !1
1326
1432
  }) {
1327
- const [p, m] = A(null), R = ge(null), [h, C] = A(null), w = L(() => {
1328
- p && (p.style.outline = "", p.style.outlineOffset = "", m(null));
1329
- }, [p]), O = L(() => {
1330
- R.current && (R.current.style.outline = "", R.current.style.outlineOffset = "", R.current = null);
1433
+ const [d, w] = A(null), x = mr(null), [y, P] = A(null), S = j(() => {
1434
+ d && (d.style.outline = "", d.style.outlineOffset = "", w(null));
1435
+ }, [d]), V = j(() => {
1436
+ x.current && (x.current.style.outline = "", x.current.style.outlineOffset = "", x.current = null);
1331
1437
  }, []);
1332
- $(() => {
1333
- n || (w(), O());
1334
- }, [n, w, O]), $(() => {
1438
+ F(() => {
1439
+ o || (S(), V());
1440
+ }, [o, S, V]), F(() => {
1335
1441
  if (typeof document > "u") return;
1336
- const S = document.body.style.cursor;
1337
- return h ? document.body.style.cursor = "default" : n && (document.body.style.cursor = "crosshair"), () => {
1338
- document.body.style.cursor = S;
1442
+ const m = document.body.style.cursor;
1443
+ return y ? document.body.style.cursor = "default" : o && (document.body.style.cursor = "crosshair"), () => {
1444
+ document.body.style.cursor = m;
1339
1445
  };
1340
- }, [n, h]);
1341
- const _ = L(
1342
- (S) => {
1343
- if (!n || h) return;
1344
- const j = S.target.nodeType === Node.ELEMENT_NODE ? S.target : S.target.parentElement;
1345
- j && (w(), m(j), j.style.outline = "2px solid #ff4d4f", j.style.outlineOffset = "2px");
1446
+ }, [o, y]);
1447
+ const $ = j((m) => {
1448
+ var z;
1449
+ if (!m || typeof document > "u" || m === document.body || m === document.documentElement) return !0;
1450
+ const C = (z = m.tagName) == null ? void 0 : z.toUpperCase();
1451
+ return C === "BODY" || C === "HTML" ? !0 : m.parentElement !== document.body ? !1 : m.id === "root" || m.getAttribute("data-review-layer-host") != null || document.body.children.length === 1;
1452
+ }, []), L = j(
1453
+ (m) => {
1454
+ if (!o || y) return;
1455
+ const C = m.target.nodeType === Node.ELEMENT_NODE ? m.target : m.target.parentElement;
1456
+ !C || $(C) || (S(), w(C), C.style.outline = "2px solid var(--ui-color-bg-fill-danger-default, #ff4d4f)", C.style.outlineOffset = "2px");
1346
1457
  },
1347
- [n, h, w]
1348
- ), I = L(
1349
- (S) => {
1350
- var M;
1351
- if (h) return;
1352
- const j = S.relatedTarget;
1353
- p && (!j || !p.contains(j)) && !(j && ((M = p.contains) != null && M.call(p, j))) && w();
1458
+ [o, y, S, $]
1459
+ ), c = j(
1460
+ (m) => {
1461
+ var z;
1462
+ if (y) return;
1463
+ const C = m.relatedTarget;
1464
+ d && (!C || !d.contains(C)) && !(C && ((z = d.contains) != null && z.call(d, C))) && S();
1354
1465
  },
1355
- [p, h, w]
1356
- ), z = L(
1357
- (S) => {
1358
- if (!n || h) return;
1359
- S.preventDefault(), S.stopPropagation();
1360
- const j = S.target;
1361
- if (!j || j.closest("[data-review-layer-pin]") || j.closest("[data-review-layer-modal]")) return;
1362
- w();
1363
- const M = j;
1364
- R.current = M, M.style.outline = "2px solid #ff4d4f", M.style.outlineOffset = "2px";
1365
- const W = M.getBoundingClientRect(), re = $t(j), { relativeX: G, relativeY: V } = Nt(W);
1366
- C({
1367
- position: { x: W.left + W.width / 2, y: W.bottom },
1466
+ [d, y, S]
1467
+ ), p = j(
1468
+ (m) => {
1469
+ if (!o || y) return;
1470
+ const C = m.target;
1471
+ if (!C || $(C) || C.closest("[data-review-layer-root]")) return;
1472
+ m.preventDefault(), m.stopPropagation(), S();
1473
+ const z = C;
1474
+ x.current = z, z.style.outline = "2px solid var(--ui-color-bg-fill-danger-default, #ff4d4f)", z.style.outlineOffset = "2px";
1475
+ const T = z.getBoundingClientRect(), G = Ye(C), { relativeX: Y, relativeY: J } = He(T);
1476
+ P({
1477
+ position: { x: T.left + T.width / 2, y: T.bottom },
1368
1478
  payload: {
1369
- selector: re,
1370
- x: Math.round(W.left),
1371
- y: Math.round(W.top),
1372
- relativeX: G,
1373
- relativeY: V,
1374
- width: Math.round(W.width),
1375
- height: Math.round(W.height),
1479
+ selector: G,
1480
+ x: Math.round(T.left),
1481
+ y: Math.round(T.top),
1482
+ relativeX: Y,
1483
+ relativeY: J,
1484
+ width: Math.round(T.width),
1485
+ height: Math.round(T.height),
1376
1486
  url: typeof window < "u" && window.location.pathname || "/",
1377
- viewport: xr(),
1487
+ viewport: Oo(),
1378
1488
  userAgent: typeof navigator < "u" ? navigator.userAgent : "",
1379
1489
  pageTitle: typeof document < "u" ? document.title : ""
1380
1490
  }
1381
1491
  });
1382
1492
  },
1383
- [n, h, w]
1493
+ [o, y, S, $]
1384
1494
  );
1385
- $(() => {
1386
- if (n)
1387
- return document.addEventListener("mouseover", _, !0), document.addEventListener("mouseout", I, !0), document.addEventListener("click", z, !0), () => {
1388
- document.removeEventListener("mouseover", _, !0), document.removeEventListener("mouseout", I, !0), document.removeEventListener("click", z, !0);
1495
+ F(() => {
1496
+ if (o)
1497
+ return document.addEventListener("mouseover", L, !0), document.addEventListener("mouseout", c, !0), document.addEventListener("click", p, !0), () => {
1498
+ document.removeEventListener("mouseover", L, !0), document.removeEventListener("mouseout", c, !0), document.removeEventListener("click", p, !0);
1389
1499
  };
1390
- }, [n, _, I, z]);
1391
- const [u, f] = A(0);
1392
- $(() => {
1500
+ }, [o, L, c, p]);
1501
+ const [I, N] = A(0);
1502
+ F(() => {
1393
1503
  if (typeof window > "u") return;
1394
- const S = () => f((j) => j + 1);
1395
- return window.addEventListener("resize", S), window.addEventListener("scroll", S, !0), () => {
1396
- window.removeEventListener("resize", S), window.removeEventListener("scroll", S, !0);
1504
+ const m = () => N((C) => C + 1);
1505
+ return window.addEventListener("resize", m), window.addEventListener("scroll", m, !0), () => {
1506
+ window.removeEventListener("resize", m), window.removeEventListener("scroll", m, !0);
1397
1507
  };
1398
1508
  }, []);
1399
- const k = Ot(
1400
- () => mr(a),
1401
- [a, u]
1402
- ), U = {
1509
+ const H = $r(
1510
+ () => Io(s),
1511
+ [s, I]
1512
+ ), er = j(() => {
1513
+ V(), P(null);
1514
+ }, [V]), or = {
1403
1515
  position: "fixed",
1404
1516
  inset: 0,
1405
1517
  zIndex: 999999,
1406
1518
  pointerEvents: "none",
1407
- cursor: n ? "crosshair" : void 0
1408
- }, X = /* @__PURE__ */ l.jsxs("div", { style: U, "aria-hidden": !0, children: [
1409
- n && /* @__PURE__ */ l.jsx(
1519
+ cursor: o ? "crosshair" : void 0
1520
+ }, tr = /* @__PURE__ */ l.jsxs(l.Fragment, { children: [
1521
+ /* @__PURE__ */ l.jsx("div", { style: or, "aria-hidden": !0, "data-review-layer-root": !0 }),
1522
+ o && /* @__PURE__ */ l.jsxs(
1410
1523
  "div",
1411
1524
  {
1525
+ "data-review-layer-root": !0,
1412
1526
  style: {
1413
1527
  position: "fixed",
1414
- top: 10,
1415
- left: 10,
1528
+ top: "var(--ui-positive-Value_250, 10px)",
1529
+ left: "var(--ui-positive-Value_250, 10px)",
1416
1530
  zIndex: 1e6,
1417
- padding: "6px 12px",
1418
- backgroundColor: "#ff4d4f",
1419
- color: "#fff",
1420
- borderRadius: 6,
1421
- fontSize: 12,
1422
- fontWeight: 500,
1531
+ display: "flex",
1532
+ alignItems: "center",
1533
+ gap: "var(--ui-positive-Value_250, 10px)",
1534
+ padding: "var(--ui-positive-Value_150, 6px) var(--ui-positive-Value_300, 12px)",
1535
+ backgroundColor: "var(--ui-color-bg-fill-danger-default, #ff4d4f)",
1536
+ color: "var(--ui-color-text-on-color, #fff)",
1537
+ borderRadius: "var(--ui-radius_6, 6px)",
1538
+ fontSize: "var(--ui-font-size-xs, 12px)",
1539
+ fontWeight: "var(--ui-font-weight-medium, 500)",
1423
1540
  pointerEvents: "auto"
1424
1541
  },
1425
- children: "Modo revisión (Shift+R para salir)"
1542
+ children: [
1543
+ /* @__PURE__ */ l.jsx("span", { children: "Modo revisión (Shift+R para salir)" }),
1544
+ /* @__PURE__ */ l.jsx(
1545
+ "button",
1546
+ {
1547
+ type: "button",
1548
+ onClick: () => i(!1),
1549
+ "aria-label": "Salir del modo revisión",
1550
+ style: {
1551
+ padding: 0,
1552
+ margin: 0,
1553
+ width: 20,
1554
+ height: 20,
1555
+ display: "flex",
1556
+ alignItems: "center",
1557
+ justifyContent: "center",
1558
+ border: "none",
1559
+ borderRadius: "var(--ui-radius_6, 6px)",
1560
+ backgroundColor: "rgba(255,255,255,0.2)",
1561
+ color: "inherit",
1562
+ fontSize: 14,
1563
+ lineHeight: 1,
1564
+ cursor: "pointer"
1565
+ },
1566
+ children: "×"
1567
+ }
1568
+ )
1569
+ ]
1426
1570
  }
1427
1571
  ),
1428
1572
  g && /* @__PURE__ */ l.jsxs(
@@ -1430,19 +1574,19 @@ function Er({
1430
1574
  {
1431
1575
  style: {
1432
1576
  position: "fixed",
1433
- bottom: 16,
1577
+ bottom: "var(--ui-positive-Value_400, 16px)",
1434
1578
  left: "50%",
1435
1579
  transform: "translateX(-50%)",
1436
1580
  display: "flex",
1437
1581
  alignItems: "center",
1438
- gap: 10,
1439
- padding: "8px 14px",
1440
- backgroundColor: "#fff",
1441
- border: "1px solid #e8e8e8",
1442
- borderRadius: 8,
1443
- boxShadow: "0 2px 12px rgba(0,0,0,0.1)",
1444
- fontSize: 12,
1445
- color: "#333",
1582
+ gap: "var(--ui-positive-Value_250, 10px)",
1583
+ padding: "var(--ui-positive-Value_200, 8px) var(--ui-positive-Value_350, 14px)",
1584
+ backgroundColor: "var(--ui-color-bg-surface-default, #fff)",
1585
+ border: "1px solid var(--ui-color-border-subtle, #e8e8e8)",
1586
+ borderRadius: "var(--ui-radius_8, 8px)",
1587
+ boxShadow: "0 2px 12px var(--ui-color-black-alpha-10, rgba(0,0,0,0.1))",
1588
+ fontSize: "var(--ui-font-size-xs, 12px)",
1589
+ color: "var(--ui-color-text-primary, #333)",
1446
1590
  zIndex: 999997,
1447
1591
  pointerEvents: "auto"
1448
1592
  },
@@ -1452,15 +1596,15 @@ function Er({
1452
1596
  "button",
1453
1597
  {
1454
1598
  type: "button",
1455
- onClick: () => d(),
1599
+ onClick: () => v(),
1456
1600
  style: {
1457
- padding: "4px 10px",
1458
- fontSize: 12,
1459
- fontWeight: 600,
1460
- backgroundColor: "rgb(33, 196, 94)",
1461
- color: "#fff",
1601
+ padding: "var(--ui-positive-Value_100, 4px) var(--ui-positive-Value_250, 10px)",
1602
+ fontSize: "var(--ui-font-size-xs, 12px)",
1603
+ fontWeight: "var(--ui-font-weight-semibold, 600)",
1604
+ backgroundColor: "var(--ui-color-bg-fill-success-default, rgb(33, 196, 94))",
1605
+ color: "var(--ui-color-text-on-color, #fff)",
1462
1606
  border: "none",
1463
- borderRadius: 6,
1607
+ borderRadius: "var(--ui-radius_6, 6px)",
1464
1608
  cursor: "pointer"
1465
1609
  },
1466
1610
  children: "Reintentar"
@@ -1469,192 +1613,528 @@ function Er({
1469
1613
  ]
1470
1614
  }
1471
1615
  ),
1472
- a.map((S) => /* @__PURE__ */ l.jsx("div", { "data-review-layer-pin": !0, style: { pointerEvents: "auto" }, children: /* @__PURE__ */ l.jsx(
1473
- vr,
1616
+ s.map((m) => /* @__PURE__ */ l.jsx("div", { "data-review-layer-pin": !0, style: { pointerEvents: "auto" }, children: /* @__PURE__ */ l.jsx(
1617
+ Vo,
1474
1618
  {
1475
- comment: S,
1476
- offset: k.get(S.id),
1477
- apiUrl: t,
1478
- apiKey: o,
1479
- onStatusChange: d
1619
+ comment: m,
1620
+ offset: H.get(m.id),
1621
+ apiUrl: e,
1622
+ apiKey: t,
1623
+ onStatusChange: v,
1624
+ reviewMode: o
1480
1625
  }
1481
- ) }, S.id)),
1482
- h && /* @__PURE__ */ l.jsx("div", { "data-review-layer-modal": !0, style: { pointerEvents: "auto" }, children: /* @__PURE__ */ l.jsx(
1483
- qt,
1626
+ ) }, m.id)),
1627
+ y && /* @__PURE__ */ l.jsx("div", { "data-review-layer-modal": !0, style: { pointerEvents: "auto" }, children: /* @__PURE__ */ l.jsx(
1628
+ ao,
1484
1629
  {
1485
- apiUrl: t,
1486
- apiKey: o,
1487
- reviewers: i,
1488
- position: h.position,
1489
- payload: h.payload,
1490
- onClose: () => {
1491
- O(), C(null);
1492
- },
1493
- onSuccess: d
1630
+ apiUrl: e,
1631
+ apiKey: t,
1632
+ reviewers: a,
1633
+ position: y.position,
1634
+ payload: y.payload,
1635
+ onClose: er,
1636
+ onSuccess: v
1494
1637
  }
1495
1638
  ) })
1496
- ] }), K = typeof document < "u" ? document.body : null;
1497
- return K ? Ke(X, K) : null;
1639
+ ] }), X = typeof document < "u" ? document.body : null;
1640
+ return X ? se(tr, X) : null;
1498
1641
  }
1499
- function wr(t, o, n) {
1500
- const i = L(() => {
1501
- t && n((a) => !a);
1502
- }, [t, n]);
1503
- $(() => {
1504
- if (!t) return;
1505
- const a = (d) => {
1506
- (d.key === "r" || d.key === "R" || d.code === "KeyR") && d.shiftKey && (d.preventDefault(), i());
1642
+ const zo = `/**\r
1643
+ * Tokens de diseño UI para review-layer-react.\r
1644
+ * Las variables se inyectan en :root al montar ReviewProvider.\r
1645
+ * Puedes sobrescribirlas en tu app para adaptar el tema.\r
1646
+ */\r
1647
+ :root {\r
1648
+ /* Colores base */\r
1649
+ --ui-color-white: rgb(255, 255, 255);\r
1650
+ --ui-color-black: rgb(0, 0, 0);\r
1651
+ --ui-color-red-50: rgb(255, 242, 242);\r
1652
+ --ui-color-red-100: rgb(252, 227, 227);\r
1653
+ --ui-color-red-200: rgb(250, 189, 189);\r
1654
+ --ui-color-red-300: rgb(245, 148, 148);\r
1655
+ --ui-color-red-400: rgb(242, 107, 107);\r
1656
+ --ui-color-red-500: rgb(240, 69, 69);\r
1657
+ --ui-color-red-600: rgb(212, 61, 61);\r
1658
+ --ui-color-red-700: rgb(184, 51, 51);\r
1659
+ --ui-color-red-800: rgb(156, 43, 43);\r
1660
+ --ui-color-red-900: rgb(128, 36, 36);\r
1661
+ --ui-color-orange-50: rgb(255, 247, 242);\r
1662
+ --ui-color-orange-100: rgb(252, 237, 227);\r
1663
+ --ui-color-orange-200: rgb(252, 209, 176);\r
1664
+ --ui-color-orange-300: rgb(250, 176, 125);\r
1665
+ --ui-color-orange-400: rgb(250, 145, 74);\r
1666
+ --ui-color-orange-500: rgb(250, 115, 23);\r
1667
+ --ui-color-orange-600: rgb(219, 102, 20);\r
1668
+ --ui-color-orange-700: rgb(189, 87, 18);\r
1669
+ --ui-color-orange-800: rgb(158, 74, 13);\r
1670
+ --ui-color-orange-900: rgb(128, 59, 10);\r
1671
+ --ui-color-yellow-50: rgb(255, 250, 242);\r
1672
+ --ui-color-yellow-100: rgb(252, 245, 227);\r
1673
+ --ui-color-yellow-200: rgb(247, 230, 173);\r
1674
+ --ui-color-yellow-300: rgb(242, 214, 117);\r
1675
+ --ui-color-yellow-400: rgb(240, 196, 64);\r
1676
+ --ui-color-yellow-500: rgb(235, 179, 8);\r
1677
+ --ui-color-yellow-600: rgb(209, 158, 8);\r
1678
+ --ui-color-yellow-700: rgb(181, 140, 5);\r
1679
+ --ui-color-yellow-800: rgb(156, 120, 5);\r
1680
+ --ui-color-yellow-900: rgb(128, 97, 5);\r
1681
+ --ui-color-lime-50: rgb(250, 255, 242);\r
1682
+ --ui-color-lime-100: rgb(242, 252, 227);\r
1683
+ --ui-color-lime-200: rgb(214, 240, 176);\r
1684
+ --ui-color-lime-300: rgb(186, 227, 125);\r
1685
+ --ui-color-lime-400: rgb(161, 217, 74);\r
1686
+ --ui-color-lime-500: rgb(133, 204, 23);\r
1687
+ --ui-color-lime-600: rgb(120, 186, 20);\r
1688
+ --ui-color-lime-700: rgb(107, 166, 18);\r
1689
+ --ui-color-lime-800: rgb(97, 148, 15);\r
1690
+ --ui-color-lime-900: rgb(84, 128, 13);\r
1691
+ --ui-color-green-50: rgb(242, 255, 245);\r
1692
+ --ui-color-green-100: rgb(227, 252, 237);\r
1693
+ --ui-color-green-200: rgb(179, 240, 201);\r
1694
+ --ui-color-green-300: rgb(130, 224, 166);\r
1695
+ --ui-color-green-400: rgb(84, 212, 130);\r
1696
+ --ui-color-green-500: rgb(33, 196, 94);\r
1697
+ --ui-color-green-600: rgb(31, 181, 87);\r
1698
+ --ui-color-green-700: rgb(28, 163, 79);\r
1699
+ --ui-color-green-800: rgb(26, 145, 69);\r
1700
+ --ui-color-green-900: rgb(23, 128, 61);\r
1701
+ --ui-color-cyan-50: rgb(242, 252, 255);\r
1702
+ --ui-color-cyan-100: rgb(227, 250, 252);\r
1703
+ --ui-color-cyan-200: rgb(171, 232, 242);\r
1704
+ --ui-color-cyan-300: rgb(117, 217, 232);\r
1705
+ --ui-color-cyan-400: rgb(61, 199, 222);\r
1706
+ --ui-color-cyan-500: rgb(5, 181, 212);\r
1707
+ --ui-color-cyan-600: rgb(5, 163, 191);\r
1708
+ --ui-color-cyan-700: rgb(5, 145, 171);\r
1709
+ --ui-color-cyan-800: rgb(5, 128, 148);\r
1710
+ --ui-color-cyan-900: rgb(5, 110, 128);\r
1711
+ --ui-color-azure-50: rgb(242, 250, 255);\r
1712
+ --ui-color-azure-100: rgb(227, 245, 252);\r
1713
+ --ui-color-azure-200: rgb(173, 224, 247);\r
1714
+ --ui-color-azure-300: rgb(120, 204, 242);\r
1715
+ --ui-color-azure-400: rgb(69, 186, 237);\r
1716
+ --ui-color-azure-500: rgb(13, 166, 232);\r
1717
+ --ui-color-azure-600: rgb(13, 148, 207);\r
1718
+ --ui-color-azure-700: rgb(10, 128, 181);\r
1719
+ --ui-color-azure-800: rgb(10, 110, 156);\r
1720
+ --ui-color-azure-900: rgb(8, 89, 128);\r
1721
+ --ui-color-blue-50: rgb(242, 245, 255);\r
1722
+ --ui-color-blue-100: rgb(227, 232, 252);\r
1723
+ --ui-color-blue-200: rgb(184, 196, 237);\r
1724
+ --ui-color-blue-300: rgb(140, 161, 222);\r
1725
+ --ui-color-blue-400: rgb(97, 125, 209);\r
1726
+ --ui-color-blue-500: rgb(54, 89, 194);\r
1727
+ --ui-color-blue-600: rgb(51, 82, 176);\r
1728
+ --ui-color-blue-700: rgb(46, 74, 161);\r
1729
+ --ui-color-blue-800: rgb(41, 66, 145);\r
1730
+ --ui-color-blue-900: rgb(36, 59, 128);\r
1731
+ --ui-color-violet-50: rgb(245, 242, 255);\r
1732
+ --ui-color-violet-100: rgb(237, 227, 252);\r
1733
+ --ui-color-violet-200: rgb(209, 186, 250);\r
1734
+ --ui-color-violet-300: rgb(181, 143, 245);\r
1735
+ --ui-color-violet-400: rgb(153, 102, 242);\r
1736
+ --ui-color-violet-500: rgb(125, 59, 237);\r
1737
+ --ui-color-violet-600: rgb(110, 51, 209);\r
1738
+ --ui-color-violet-700: rgb(97, 46, 184);\r
1739
+ --ui-color-violet-800: rgb(82, 38, 156);\r
1740
+ --ui-color-violet-900: rgb(66, 31, 128);\r
1741
+ --ui-color-magenta-50: rgb(255, 242, 247);\r
1742
+ --ui-color-magenta-100: rgb(252, 227, 240);\r
1743
+ --ui-color-magenta-200: rgb(247, 184, 214);\r
1744
+ --ui-color-magenta-300: rgb(245, 140, 186);\r
1745
+ --ui-color-magenta-400: rgb(240, 94, 161);\r
1746
+ --ui-color-magenta-500: rgb(235, 51, 135);\r
1747
+ --ui-color-magenta-600: rgb(209, 46, 120);\r
1748
+ --ui-color-magenta-700: rgb(181, 41, 105);\r
1749
+ --ui-color-magenta-800: rgb(156, 33, 89);\r
1750
+ --ui-color-magenta-900: rgb(128, 28, 74);\r
1751
+ --ui-color-rose-50: rgb(255, 242, 245);\r
1752
+ --ui-color-rose-100: rgb(252, 227, 232);\r
1753
+ --ui-color-rose-200: rgb(245, 179, 194);\r
1754
+ --ui-color-rose-300: rgb(240, 128, 153);\r
1755
+ --ui-color-rose-400: rgb(232, 79, 112);\r
1756
+ --ui-color-rose-500: rgb(224, 28, 71);\r
1757
+ --ui-color-rose-600: rgb(201, 26, 64);\r
1758
+ --ui-color-rose-700: rgb(176, 23, 56);\r
1759
+ --ui-color-rose-800: rgb(153, 20, 48);\r
1760
+ --ui-color-rose-900: rgb(128, 15, 41);\r
1761
+ --ui-color-light-gray-50: rgb(247, 247, 250);\r
1762
+ --ui-color-light-gray-100: rgb(240, 242, 242);\r
1763
+ --ui-color-light-gray-200: rgb(224, 227, 230);\r
1764
+ --ui-color-light-gray-300: rgb(212, 214, 217);\r
1765
+ --ui-color-light-gray-400: rgb(199, 199, 204);\r
1766
+ --ui-color-light-gray-500: rgb(186, 189, 191);\r
1767
+ --ui-color-light-gray-600: rgb(171, 173, 179);\r
1768
+ --ui-color-light-gray-700: rgb(158, 163, 166);\r
1769
+ --ui-color-light-gray-800: rgb(145, 148, 153);\r
1770
+ --ui-color-light-gray-900: rgb(133, 135, 140);\r
1771
+ --ui-color-dark-gray-50: rgb(120, 122, 128);\r
1772
+ --ui-color-dark-gray-100: rgb(107, 110, 115);\r
1773
+ --ui-color-dark-gray-200: rgb(97, 99, 105);\r
1774
+ --ui-color-dark-gray-300: rgb(89, 89, 94);\r
1775
+ --ui-color-dark-gray-400: rgb(77, 79, 84);\r
1776
+ --ui-color-dark-gray-500: rgb(69, 69, 74);\r
1777
+ --ui-color-dark-gray-600: rgb(59, 61, 64);\r
1778
+ --ui-color-dark-gray-700: rgb(48, 51, 54);\r
1779
+ --ui-color-dark-gray-800: rgb(38, 41, 43);\r
1780
+ --ui-color-dark-gray-900: rgb(31, 31, 33);\r
1781
+ --ui-color-black-alpha-transparent: rgba(0, 0, 0, 0);\r
1782
+ --ui-color-black-alpha-5: rgba(0, 0, 0, 0.05);\r
1783
+ --ui-color-black-alpha-10: rgba(0, 0, 0, 0.1);\r
1784
+ --ui-color-black-alpha-20: rgba(0, 0, 0, 0.2);\r
1785
+ --ui-color-black-alpha-30: rgba(0, 0, 0, 0.3);\r
1786
+ --ui-color-black-alpha-40: rgba(0, 0, 0, 0.4);\r
1787
+ --ui-color-black-alpha-50: rgba(0, 0, 0, 0.5);\r
1788
+ --ui-color-black-alpha-60: rgba(0, 0, 0, 0.6);\r
1789
+ --ui-color-black-alpha-70: rgba(0, 0, 0, 0.7);\r
1790
+ --ui-color-black-alpha-80: rgba(0, 0, 0, 0.8);\r
1791
+ --ui-color-black-alpha-90: rgba(0, 0, 0, 0.9);\r
1792
+ \r
1793
+ /* Espaciado positivo */\r
1794
+ --ui-positive-Value_0: 0;\r
1795
+ --ui-positive-Value_12: 0.66px;\r
1796
+ --ui-positive-Value_25: 1px;\r
1797
+ --ui-positive-Value_50: 2px;\r
1798
+ --ui-positive-Value_100: 4px;\r
1799
+ --ui-positive-Value_150: 6px;\r
1800
+ --ui-positive-Value_200: 8px;\r
1801
+ --ui-positive-Value_250: 10px;\r
1802
+ --ui-positive-Value_275: 11px;\r
1803
+ --ui-positive-Value_300: 12px;\r
1804
+ --ui-positive-Value_325: 13px;\r
1805
+ --ui-positive-Value_350: 14px;\r
1806
+ --ui-positive-Value_400: 16px;\r
1807
+ --ui-positive-Value_450: 18px;\r
1808
+ --ui-positive-Value_500: 20px;\r
1809
+ --ui-positive-Value_600: 24px;\r
1810
+ --ui-positive-Value_700: 28px;\r
1811
+ --ui-positive-Value_750: 30px;\r
1812
+ --ui-positive-Value_800: 32px;\r
1813
+ --ui-positive-Value_900: 36px;\r
1814
+ --ui-positive-Value_1000: 40px;\r
1815
+ --ui-positive-Value_1200: 48px;\r
1816
+ --ui-positive-Value_1400: 56px;\r
1817
+ --ui-positive-Value_1600: 64px;\r
1818
+ --ui-positive-Value_2000: 80px;\r
1819
+ --ui-positive-Value_2400: 96px;\r
1820
+ --ui-positive-Value_2800: 112px;\r
1821
+ --ui-positive-Value_3200: 128px;\r
1822
+ --ui-positive-Value_full: 9999px;\r
1823
+ \r
1824
+ /* Sombras */\r
1825
+ --ui-shadow-01-x: 0;\r
1826
+ --ui-shadow-01-y: 1px;\r
1827
+ --ui-shadow-01-blur: 2px;\r
1828
+ --ui-shadow-01-Spread: 0;\r
1829
+ --ui-shadow-02-x: 0;\r
1830
+ --ui-shadow-02-y: 2px;\r
1831
+ --ui-shadow-02-blur: 4px;\r
1832
+ --ui-shadow-02-Spread: -1px;\r
1833
+ --ui-shadow-03-x: 0;\r
1834
+ --ui-shadow-03-y: 4px;\r
1835
+ --ui-shadow-03-blur: 8px;\r
1836
+ --ui-shadow-03-Spread: -2px;\r
1837
+ --ui-shadow-04-x: 0;\r
1838
+ --ui-shadow-04-y: 8px;\r
1839
+ --ui-shadow-04-blur: 16px;\r
1840
+ --ui-shadow-04-Spread: -4px;\r
1841
+ --ui-shadow-05-x: 0;\r
1842
+ --ui-shadow-05-y: 16px;\r
1843
+ --ui-shadow-05-blur: 24px;\r
1844
+ --ui-shadow-05-Spread: -8px;\r
1845
+ --ui-shadow-01-Color: var(--ui-color-black-alpha-10);\r
1846
+ --ui-shadow-02-Color: var(--ui-color-black-alpha-20);\r
1847
+ --ui-shadow-03-Color: var(--ui-color-black-alpha-20);\r
1848
+ --ui-shadow-04-Color: var(--ui-color-black-alpha-30);\r
1849
+ --ui-shadow-05-Color: var(--ui-color-black-alpha-30);\r
1850
+ \r
1851
+ /* Z-index */\r
1852
+ --ui-z-hide: -1;\r
1853
+ --ui-z-base: 0;\r
1854
+ --ui-z-raised: 100;\r
1855
+ --ui-z-sticky: 200;\r
1856
+ --ui-z-shell: 300;\r
1857
+ --ui-z-dropdown: 400;\r
1858
+ --ui-z-popover: 500;\r
1859
+ --ui-z-tooltip: 600;\r
1860
+ --ui-z-modalBackdrop: 690;\r
1861
+ --ui-z-modal: 700;\r
1862
+ --ui-z-toast: 800;\r
1863
+ --ui-z-overlay: 900;\r
1864
+ --ui-z-max: 99999;\r
1865
+ \r
1866
+ /* Tipografía */\r
1867
+ --ui-font-family-ui: "Inter", -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;\r
1868
+ --ui-font-family-mono: "IBM Plex Mono";\r
1869
+ --ui-font-weight-regular: 400;\r
1870
+ --ui-font-weight-medium: 500;\r
1871
+ --ui-font-weight-semibold: 600;\r
1872
+ --ui-font-weight-bold: 700;\r
1873
+ \r
1874
+ /* Radios */\r
1875
+ --ui-radius_0: 0;\r
1876
+ --ui-radius_2: 2px;\r
1877
+ --ui-radius_4: 4px;\r
1878
+ --ui-radius_6: 6px;\r
1879
+ --ui-radius_8: 8px;\r
1880
+ --ui-radius_10: 10px;\r
1881
+ --ui-radius_12: 12px;\r
1882
+ --ui-radius_16: 16px;\r
1883
+ --ui-radius_24: 24px;\r
1884
+ --ui-radius_full: 9999px;\r
1885
+ \r
1886
+ /* Semánticos: texto */\r
1887
+ --ui-color-text-primary: var(--ui-color-dark-gray-700);\r
1888
+ --ui-color-text-secondary: var(--ui-color-dark-gray-300);\r
1889
+ --ui-color-text-tertiary: var(--ui-color-dark-gray-100);\r
1890
+ --ui-color-text-disabled: var(--ui-color-light-gray-500);\r
1891
+ --ui-color-text-on-color: var(--ui-color-white);\r
1892
+ --ui-color-text-danger-default: var(--ui-color-red-700);\r
1893
+ --ui-color-text-danger-hover: var(--ui-color-red-800);\r
1894
+ --ui-color-text-danger-pressed: var(--ui-color-red-900);\r
1895
+ \r
1896
+ /* Semánticos: bordes */\r
1897
+ --ui-color-border-default: var(--ui-color-light-gray-400);\r
1898
+ --ui-color-border-subtle: var(--ui-color-light-gray-300);\r
1899
+ --ui-color-border-strong: var(--ui-color-dark-gray-400);\r
1900
+ --ui-color-border-danger: var(--ui-color-red-500);\r
1901
+ \r
1902
+ /* Semánticos: superficies y fondos */\r
1903
+ --ui-color-bg-surface-default: var(--ui-color-white);\r
1904
+ --ui-color-bg-surface-secondary-default: var(--ui-color-light-gray-50);\r
1905
+ --ui-color-bg-surface-secondary-hover: var(--ui-color-light-gray-100);\r
1906
+ --ui-color-bg-fill-danger-default: var(--ui-color-red-500);\r
1907
+ --ui-color-bg-fill-danger-hover: var(--ui-color-red-600);\r
1908
+ --ui-color-bg-fill-danger-pressed: var(--ui-color-red-700);\r
1909
+ --ui-color-bg-fill-success-default: var(--ui-color-green-500);\r
1910
+ --ui-color-bg-fill-success-hover: var(--ui-color-green-600);\r
1911
+ --ui-color-bg-fill-success-pressed: var(--ui-color-green-700);\r
1912
+ --ui-color-bg-surface-success-default: var(--ui-color-green-50);\r
1913
+ --ui-color-bg-surface-success-hover: var(--ui-color-green-100);\r
1914
+ --ui-color-bg-surface-success-selected: var(--ui-color-green-200);\r
1915
+ --ui-color-bg-surface-danger-default: var(--ui-color-red-50);\r
1916
+ --ui-color-bg-surface-danger-hover: var(--ui-color-red-100);\r
1917
+ --ui-color-bg-surface-danger-selected: var(--ui-color-red-200);\r
1918
+ --ui-color-bg-surface-warning-default: var(--ui-color-yellow-50);\r
1919
+ --ui-color-bg-surface-warning-hover: var(--ui-color-yellow-100);\r
1920
+ --ui-color-bg-surface-warning-selected: var(--ui-color-yellow-200);\r
1921
+ \r
1922
+ /* Espaciado (space) */\r
1923
+ --ui-Positive-space_0: var(--ui-positive-Value_0);\r
1924
+ --ui-Positive-space_2: var(--ui-positive-Value_100);\r
1925
+ --ui-Positive-space_4: var(--ui-positive-Value_100);\r
1926
+ --ui-Positive-space_6: var(--ui-positive-Value_150);\r
1927
+ --ui-Positive-space_8: var(--ui-positive-Value_200);\r
1928
+ --ui-Positive-space_10: var(--ui-positive-Value_250);\r
1929
+ --ui-Positive-space_12: var(--ui-positive-Value_300);\r
1930
+ --ui-Positive-space_16: var(--ui-positive-Value_400);\r
1931
+ --ui-Positive-space_20: var(--ui-positive-Value_500);\r
1932
+ --ui-Positive-space_24: var(--ui-positive-Value_600);\r
1933
+ --ui-Positive-space_28: var(--ui-positive-Value_700);\r
1934
+ --ui-Positive-space_32: var(--ui-positive-Value_800);\r
1935
+ --ui-Positive-space_40: var(--ui-positive-Value_1000);\r
1936
+ --ui-Positive-space_48: var(--ui-positive-Value_1200);\r
1937
+ --ui-Positive-space_56: var(--ui-positive-Value_1400);\r
1938
+ --ui-Positive-space_64: var(--ui-positive-Value_1600);\r
1939
+ --ui-Positive-space_80: var(--ui-positive-Value_2000);\r
1940
+ --ui-Positive-space_96: var(--ui-positive-Value_2400);\r
1941
+ \r
1942
+ /* Tamaños de fuente */\r
1943
+ --ui-font-size-2xs: var(--ui-positive-Value_250);\r
1944
+ --ui-font-size-xs: var(--ui-positive-Value_300);\r
1945
+ --ui-font-size-sm: var(--ui-positive-Value_350);\r
1946
+ --ui-font-size-md: var(--ui-positive-Value_400);\r
1947
+ --ui-font-size-lg: var(--ui-positive-Value_450);\r
1948
+ --ui-font-size-xl: var(--ui-positive-Value_500);\r
1949
+ --ui-font-size-2xl: var(--ui-positive-Value_600);\r
1950
+ --ui-font-size-3xl: var(--ui-positive-Value_750);\r
1951
+ --ui-font-size-4xl: var(--ui-positive-Value_900);\r
1952
+ --ui-font-size-5xl: var(--ui-positive-Value_1200);\r
1953
+ \r
1954
+ /* Line height (muestra) */\r
1955
+ --ui-font-lh-10-normal: 14.5px;\r
1956
+ --ui-font-lh-12-normal: 17.5px;\r
1957
+ --ui-font-lh-14-normal: 20.5px;\r
1958
+ --ui-font-lh-16-normal: 23px;\r
1959
+ --ui-font-lh-18-normal: 26px;\r
1960
+ --ui-font-lh-20-snug: 25px;\r
1961
+ \r
1962
+ /* Sombras compuestas (para uso en box-shadow) */\r
1963
+ --ui-shadow-card: 0 4px 16px var(--ui-shadow-01-Color);\r
1964
+ --ui-shadow-popover: 0 var(--ui-shadow-02-y) var(--ui-shadow-02-blur) var(--ui-shadow-02-Color);\r
1965
+ --ui-shadow-modal: 0 var(--ui-shadow-04-y) var(--ui-shadow-04-blur) var(--ui-shadow-04-Color);\r
1966
+ }\r
1967
+ `;
1968
+ function Ao(e, t, o) {
1969
+ const i = j(() => {
1970
+ e && o((a) => !a);
1971
+ }, [e, o]);
1972
+ F(() => {
1973
+ if (!e) return;
1974
+ const a = (s) => {
1975
+ (s.key === "r" || s.key === "R" || s.code === "KeyR") && s.shiftKey && !s.ctrlKey && !s.metaKey && (s.preventDefault(), i());
1507
1976
  };
1508
1977
  return window.addEventListener("keydown", a), () => window.removeEventListener("keydown", a);
1509
- }, [t, i]);
1978
+ }, [e, i]);
1510
1979
  }
1511
- const br = "review_layer:v1:";
1512
- function Rr(t, o) {
1513
- if (t == null) return o;
1980
+ const Fo = "review_layer:v1:";
1981
+ function No(e, t) {
1982
+ if (e == null) return t;
1514
1983
  try {
1515
- return JSON.parse(t) ?? o;
1984
+ return JSON.parse(e) ?? t;
1516
1985
  } catch {
1517
- return o;
1986
+ return t;
1518
1987
  }
1519
1988
  }
1520
- function me(t, o, n, i) {
1521
- const a = `${br}${Sr(t)}:${n}`;
1989
+ function Sr(e, t, o, i) {
1990
+ const a = `${Fo}${$o(e)}:${o}`;
1522
1991
  return i != null ? `${a}:${i}` : a;
1523
1992
  }
1524
- function Sr(t) {
1525
- return t.replace(/\/+$/, "") || "/";
1993
+ function $o(e) {
1994
+ return e.replace(/\/+$/, "") || "/";
1526
1995
  }
1527
- function rt(t) {
1996
+ function fe(e) {
1528
1997
  if (typeof localStorage > "u") return null;
1529
- const o = localStorage.getItem(t);
1530
- return Rr(o, null);
1998
+ const t = localStorage.getItem(e);
1999
+ return No(t, null);
1531
2000
  }
1532
- function nt(t, o) {
2001
+ function ve(e, t) {
1533
2002
  if (!(typeof localStorage > "u"))
1534
2003
  try {
1535
- localStorage.setItem(t, JSON.stringify({ data: o, at: Date.now() }));
2004
+ localStorage.setItem(e, JSON.stringify({ data: t, at: Date.now() }));
1536
2005
  } catch {
1537
2006
  }
1538
2007
  }
1539
- function je(t, o, n) {
1540
- const i = rt(me(t, o, "comments", n));
2008
+ function Lr(e, t, o) {
2009
+ const i = fe(Sr(e, t, "comments", o));
1541
2010
  return (i == null ? void 0 : i.data) ?? null;
1542
2011
  }
1543
- function Cr(t, o, n, i) {
1544
- nt(me(t, o, "comments", n), i);
2012
+ function Mo(e, t, o, i) {
2013
+ ve(Sr(e, t, "comments", o), i);
1545
2014
  }
1546
- function qe(t, o) {
1547
- const n = rt(me(t, o, "reviewers"));
1548
- return (n == null ? void 0 : n.data) ?? null;
2015
+ function ae(e, t) {
2016
+ const o = fe(Sr(e, t, "reviewers"));
2017
+ return (o == null ? void 0 : o.data) ?? null;
1549
2018
  }
1550
- function _r(t, o, n) {
1551
- nt(me(t, o, "reviewers"), n);
2019
+ function Wo(e, t, o) {
2020
+ ve(Sr(e, t, "reviewers"), o);
1552
2021
  }
1553
- const jr = "https://review-layer-api.onrender.com/api";
1554
- function Ze() {
2022
+ const Bo = "https://review-layer-api.onrender.com/api";
2023
+ function ue() {
1555
2024
  return typeof window > "u" ? "/" : window.location.pathname || "/";
1556
2025
  }
1557
- const ot = It(null);
1558
- let Te = null;
1559
- function kr() {
1560
- const t = Lt(ot);
1561
- if (!t)
2026
+ const pe = $e(null);
2027
+ let zr = null;
2028
+ function Go() {
2029
+ const e = Me(pe);
2030
+ if (!e)
1562
2031
  throw new Error("useReview must be used within ReviewProvider");
1563
- return t;
2032
+ return e;
1564
2033
  }
1565
- function Dr({
1566
- children: t,
1567
- enabled: o = !0,
1568
- apiUrl: n,
2034
+ function Ho({
2035
+ children: e,
2036
+ enabled: t = !0,
2037
+ apiUrl: o,
1569
2038
  apiKey: i
1570
2039
  }) {
1571
- const a = (n == null ? void 0 : n.trim()) || jr, [d, g] = A(!1), [p, m] = A([]), [R, h] = A([]), [C, w] = A(!1);
1572
- wr(o, d, g);
1573
- const O = L(
1574
- async (u) => {
1575
- if (!(!o || !a || !i))
2040
+ const a = (o == null ? void 0 : o.trim()) || Bo, [s, v] = A(!1), [g, d] = A([]), [w, x] = A([]), [y, P] = A(!1);
2041
+ Ao(t, s, v);
2042
+ const S = j(
2043
+ async (c) => {
2044
+ if (!(!t || !a || !i))
1576
2045
  try {
1577
- const f = await Mt(a, i, { signal: u });
1578
- u != null && u.aborted || (m(f), _r(a, i, f));
1579
- } catch (f) {
1580
- if (f instanceof Error && f.name === "AbortError") return;
1581
- if (!(u != null && u.aborted)) {
1582
- const k = qe(a, i);
1583
- k != null && m(k);
2046
+ const p = await Je(a, i, { signal: c });
2047
+ c != null && c.aborted || (d(p), Wo(a, i, p));
2048
+ } catch (p) {
2049
+ if (p instanceof Error && p.name === "AbortError") return;
2050
+ if (!(c != null && c.aborted)) {
2051
+ const I = ae(a, i);
2052
+ I != null && d(I);
1584
2053
  }
1585
2054
  }
1586
2055
  },
1587
- [o, a, i]
1588
- ), _ = L(
1589
- async (u) => {
1590
- if (!o || !a || !i) return;
1591
- const f = Ze(), k = je(a, i, f);
1592
- k != null && h(k);
2056
+ [t, a, i]
2057
+ ), V = j(
2058
+ async (c) => {
2059
+ if (!t || !a || !i) return;
2060
+ const p = ue(), I = Lr(a, i, p);
2061
+ I != null && x(I);
1593
2062
  try {
1594
- w(!1);
1595
- const U = await Vt(a, i, f, { signal: u });
1596
- u != null && u.aborted || (h(U), Cr(a, i, f, U));
1597
- } catch (U) {
1598
- if (U instanceof Error && U.name === "AbortError") return;
1599
- if (!(u != null && u.aborted)) {
1600
- w(!0);
1601
- const X = je(a, i, f);
1602
- X != null && h(X);
2063
+ P(!1);
2064
+ const N = await Ze(a, i, p, { signal: c });
2065
+ c != null && c.aborted || (x(N), Mo(a, i, p, N));
2066
+ } catch (N) {
2067
+ if (N instanceof Error && N.name === "AbortError") return;
2068
+ if (!(c != null && c.aborted)) {
2069
+ P(!0);
2070
+ const H = Lr(a, i, p);
2071
+ H != null && x(H);
1603
2072
  }
1604
2073
  }
1605
2074
  },
1606
- [o, a, i]
2075
+ [t, a, i]
1607
2076
  );
1608
- $(() => {
1609
- if (!o || !a || !i) return;
1610
- const u = Ze(), f = qe(a, i), k = je(a, i, u);
1611
- f != null && m(f), k != null && h(k);
1612
- }, [o, a, i]), $(() => {
1613
- if (!o || !a || !i) return;
1614
- const u = `${a}:${i}`;
1615
- if (Te !== u)
1616
- return Te = u, O(), _(), () => {
2077
+ F(() => {
2078
+ if (!t || !a || !i) return;
2079
+ const c = ue(), p = ae(a, i), I = Lr(a, i, c);
2080
+ p != null && d(p), I != null && x(I);
2081
+ }, [t, a, i]), F(() => {
2082
+ if (typeof document > "u") return;
2083
+ const c = "review-layer-ui-variables";
2084
+ if (!document.getElementById(c)) {
2085
+ const p = document.createElement("style");
2086
+ p.id = c, p.textContent = zo, document.head.appendChild(p);
2087
+ }
2088
+ }, []), F(() => {
2089
+ if (!t || !a || !i) return;
2090
+ const c = `${a}:${i}`;
2091
+ if (zr !== c)
2092
+ return zr = c, S(), V(), () => {
1617
2093
  setTimeout(() => {
1618
- Te = null;
2094
+ zr = null;
1619
2095
  }, 0);
1620
2096
  };
1621
- }, [o, a, i, O, _]), $(() => {
1622
- if (!o) return;
1623
- const u = () => _();
1624
- return window.addEventListener("popstate", u), () => window.removeEventListener("popstate", u);
1625
- }, [o, _]);
1626
- const I = {
1627
- apiUrl: a,
1628
- apiKey: i,
1629
- reviewMode: d,
1630
- setReviewMode: g,
1631
- reviewers: p,
1632
- comments: R,
1633
- loadComments: _,
1634
- commentsLoadFailed: C
1635
- }, z = o && typeof document < "u" ? Ke(
2097
+ }, [t, a, i, S, V]), F(() => {
2098
+ if (!t) return;
2099
+ const c = () => V();
2100
+ return window.addEventListener("popstate", c), () => window.removeEventListener("popstate", c);
2101
+ }, [t, V]);
2102
+ const $ = $r(
2103
+ () => ({
2104
+ apiUrl: a,
2105
+ apiKey: i,
2106
+ reviewMode: s,
2107
+ setReviewMode: v,
2108
+ reviewers: g,
2109
+ comments: w,
2110
+ loadComments: V,
2111
+ commentsLoadFailed: y
2112
+ }),
2113
+ [a, i, s, v, g, w, V, y]
2114
+ ), L = t && typeof document < "u" ? se(
1636
2115
  /* @__PURE__ */ l.jsx(
1637
- Er,
2116
+ Lo,
1638
2117
  {
1639
2118
  apiUrl: a,
1640
2119
  apiKey: i,
1641
- reviewMode: d,
1642
- reviewers: p,
1643
- comments: R,
1644
- loadComments: _,
1645
- commentsLoadFailed: C
2120
+ reviewMode: s,
2121
+ setReviewMode: v,
2122
+ reviewers: g,
2123
+ comments: w,
2124
+ loadComments: V,
2125
+ commentsLoadFailed: y
1646
2126
  }
1647
2127
  ),
1648
2128
  document.body
1649
2129
  ) : null;
1650
- return /* @__PURE__ */ l.jsxs(ot.Provider, { value: I, children: [
1651
- t,
1652
- z
2130
+ return /* @__PURE__ */ l.jsxs(pe.Provider, { value: $, children: [
2131
+ e,
2132
+ L
1653
2133
  ] });
1654
2134
  }
1655
2135
  export {
1656
- jr as DEFAULT_API_URL,
1657
- Dr as ReviewProvider,
1658
- kr as useReview
2136
+ Bo as DEFAULT_API_URL,
2137
+ Ho as ReviewProvider,
2138
+ Go as useReview
1659
2139
  };
1660
2140
  //# sourceMappingURL=review-layer-react.js.map