glitchgrab 1.47.0 → 1.48.1
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.
- package/README.md +102 -13
- package/dist/index.js +1054 -425
- package/dist/index.js.map +1 -1
- package/dist/index.mjs +1054 -425
- package/dist/index.mjs.map +1 -1
- package/dist/server.d.mts +102 -1
- package/dist/server.d.ts +102 -1
- package/dist/server.js +85 -0
- package/dist/server.js.map +1 -1
- package/dist/server.mjs +82 -0
- package/dist/server.mjs.map +1 -1
- package/package.json +1 -1
package/dist/index.mjs
CHANGED
|
@@ -14,6 +14,37 @@ import {
|
|
|
14
14
|
// src/error-boundary.tsx
|
|
15
15
|
import * as React from "react";
|
|
16
16
|
|
|
17
|
+
// ../report-ui/dist/assist-response.mjs
|
|
18
|
+
var ASSIST_OFFLINE_MESSAGE = "The assistant is unavailable \u2014 write your report below and send it as normal.";
|
|
19
|
+
function assistOffline() {
|
|
20
|
+
return { conversationId: null, question: null, report: null, degraded: ASSIST_OFFLINE_MESSAGE };
|
|
21
|
+
}
|
|
22
|
+
function toAssistTurnResult(ok, body) {
|
|
23
|
+
var _a, _b, _c, _d, _e, _f, _g, _h;
|
|
24
|
+
const envelope = body != null ? body : null;
|
|
25
|
+
if (!ok || !(envelope == null ? void 0 : envelope.success)) {
|
|
26
|
+
return {
|
|
27
|
+
...assistOffline(),
|
|
28
|
+
// The server words why (cap, rate limit, switched off). An hourly limit
|
|
29
|
+
// keeps the assistant button for this report.
|
|
30
|
+
degraded: (_a = envelope == null ? void 0 : envelope.error) != null ? _a : ASSIST_OFFLINE_MESSAGE,
|
|
31
|
+
retryable: (envelope == null ? void 0 : envelope.retryable) === true
|
|
32
|
+
};
|
|
33
|
+
}
|
|
34
|
+
const d = (_b = envelope.data) != null ? _b : {};
|
|
35
|
+
return {
|
|
36
|
+
conversationId: (_c = d.conversationId) != null ? _c : null,
|
|
37
|
+
question: (_d = d.question) != null ? _d : null,
|
|
38
|
+
options: Array.isArray(d.options) ? d.options.filter((o) => typeof o === "string") : [],
|
|
39
|
+
report: (_e = d.report) != null ? _e : null,
|
|
40
|
+
duplicate: (_f = d.duplicate) != null ? _f : null,
|
|
41
|
+
related: (_g = d.related) != null ? _g : null,
|
|
42
|
+
solved: (_h = d.solved) != null ? _h : null,
|
|
43
|
+
aboutGlitchgrab: d.aboutGlitchgrab === true,
|
|
44
|
+
degraded: null
|
|
45
|
+
};
|
|
46
|
+
}
|
|
47
|
+
|
|
17
48
|
// src/redact.ts
|
|
18
49
|
var SENSITIVE_KEY_RE = /(pass|pwd|secret|token|auth|session|cookie|credential|apikey|api_key|access_key|private|signature|otp|pin|cvv|card|ssn|aadhaar|pan)/i;
|
|
19
50
|
var EMAIL_RE = /[\w.+-]+@[\w-]+\.[\w.-]+/g;
|
|
@@ -688,13 +719,7 @@ async function findSimilarIssues(description, token, baseUrl, identity) {
|
|
|
688
719
|
}
|
|
689
720
|
}
|
|
690
721
|
async function assistTurn(params, token, baseUrl) {
|
|
691
|
-
|
|
692
|
-
const offline = {
|
|
693
|
-
conversationId: null,
|
|
694
|
-
question: null,
|
|
695
|
-
report: null,
|
|
696
|
-
degraded: "The assistant is unavailable \u2014 write your report below and send it as normal."
|
|
697
|
-
};
|
|
722
|
+
const offline = assistOffline();
|
|
698
723
|
try {
|
|
699
724
|
const url = `${baseUrl != null ? baseUrl : DEFAULT_BASE_URL}/api/v1/ai/report-chat`;
|
|
700
725
|
const response = await fetch(url, {
|
|
@@ -705,28 +730,7 @@ async function assistTurn(params, token, baseUrl) {
|
|
|
705
730
|
},
|
|
706
731
|
body: JSON.stringify(params)
|
|
707
732
|
});
|
|
708
|
-
|
|
709
|
-
if (!response.ok || !(envelope == null ? void 0 : envelope.success)) {
|
|
710
|
-
return {
|
|
711
|
-
conversationId: null,
|
|
712
|
-
question: null,
|
|
713
|
-
report: null,
|
|
714
|
-
degraded: (_a = envelope == null ? void 0 : envelope.error) != null ? _a : offline.degraded,
|
|
715
|
-
// An hourly limit, not a cap: the dialog keeps the assistant button.
|
|
716
|
-
retryable: (envelope == null ? void 0 : envelope.retryable) === true
|
|
717
|
-
};
|
|
718
|
-
}
|
|
719
|
-
return {
|
|
720
|
-
conversationId: (_c = (_b = envelope.data) == null ? void 0 : _b.conversationId) != null ? _c : null,
|
|
721
|
-
question: (_e = (_d = envelope.data) == null ? void 0 : _d.question) != null ? _e : null,
|
|
722
|
-
options: (_g = (_f = envelope.data) == null ? void 0 : _f.options) != null ? _g : [],
|
|
723
|
-
report: (_i = (_h = envelope.data) == null ? void 0 : _h.report) != null ? _i : null,
|
|
724
|
-
duplicate: (_k = (_j = envelope.data) == null ? void 0 : _j.duplicate) != null ? _k : null,
|
|
725
|
-
related: (_m = (_l = envelope.data) == null ? void 0 : _l.related) != null ? _m : null,
|
|
726
|
-
solved: (_o = (_n = envelope.data) == null ? void 0 : _n.solved) != null ? _o : null,
|
|
727
|
-
aboutGlitchgrab: ((_p = envelope.data) == null ? void 0 : _p.aboutGlitchgrab) === true,
|
|
728
|
-
degraded: null
|
|
729
|
-
};
|
|
733
|
+
return toAssistTurnResult(response.ok, await response.json().catch(() => null));
|
|
730
734
|
} catch (e) {
|
|
731
735
|
return offline;
|
|
732
736
|
}
|
|
@@ -955,10 +959,11 @@ import { jsx, jsxs } from "react/jsx-runtime";
|
|
|
955
959
|
import { useEffect as useEffect2, useMemo, useRef as useRef2, useState as useState2 } from "react";
|
|
956
960
|
import { createPortal } from "react-dom";
|
|
957
961
|
import { Fragment, jsx as jsx2, jsxs as jsxs2 } from "react/jsx-runtime";
|
|
962
|
+
import { Fragment as Fragment2, jsx as jsx3, jsxs as jsxs3 } from "react/jsx-runtime";
|
|
958
963
|
import { useCallback, useEffect as useEffect3, useRef as useRef3, useState as useState3 } from "react";
|
|
959
964
|
import { createPortal as createPortal2 } from "react-dom";
|
|
960
|
-
import { Fragment as Fragment2, jsx as jsx3, jsxs as jsxs3 } from "react/jsx-runtime";
|
|
961
965
|
import { Fragment as Fragment3, jsx as jsx4, jsxs as jsxs4 } from "react/jsx-runtime";
|
|
966
|
+
import { Fragment as Fragment4, jsx as jsx5, jsxs as jsxs5 } from "react/jsx-runtime";
|
|
962
967
|
var MAX_SCREENSHOT_DATA_URL_LENGTH = 18e5;
|
|
963
968
|
var QUALITY_LADDER = [0.92, 0.85, 0.75];
|
|
964
969
|
var DOWNSCALE_FACTOR = 0.7;
|
|
@@ -1389,6 +1394,412 @@ function getTypeLabel(type) {
|
|
|
1389
1394
|
return "Other";
|
|
1390
1395
|
}
|
|
1391
1396
|
}
|
|
1397
|
+
var CODE = /`([^`\n]+)`/y;
|
|
1398
|
+
var MD_LINK = /\[([^\]\n]*)\]\((https?:\/\/[^\s)]+)\)/y;
|
|
1399
|
+
var BOLD_STAR = /\*\*(\S(?:[^\n]*?\S)?)\*\*/y;
|
|
1400
|
+
var BOLD_UNDER = /__(\S(?:[^\n]*?\S)?)__/y;
|
|
1401
|
+
var ITALIC_STAR = /\*(\S(?:[^*\n]*?\S)?)\*/y;
|
|
1402
|
+
var ITALIC_UNDER = /_(\S(?:[^_\n]*?\S)?)_/y;
|
|
1403
|
+
var STRIKE = /~~(\S(?:[^\n]*?\S)?)~~/y;
|
|
1404
|
+
var FULL_URL = /https?:\/\/[^\s<>]+/y;
|
|
1405
|
+
var BARE_URL = /(?:[a-z0-9-]+\.)+[a-z]{2,24}\/[^\s<>]*/y;
|
|
1406
|
+
var WORD = /[A-Za-z0-9]/;
|
|
1407
|
+
var URL_EDGE = /[A-Za-z0-9@./-]/;
|
|
1408
|
+
var TRAILING_PUNCT = /[.,;:!?'")\]*_~]+$/;
|
|
1409
|
+
var ESCAPABLE = "\\`*_{}[]()#+-.!|~>";
|
|
1410
|
+
var MONO = "ui-monospace, SFMono-Regular, Menlo, Consolas, monospace";
|
|
1411
|
+
function at(re, text, i) {
|
|
1412
|
+
re.lastIndex = i;
|
|
1413
|
+
return re.exec(text);
|
|
1414
|
+
}
|
|
1415
|
+
function isSafeHref(href) {
|
|
1416
|
+
try {
|
|
1417
|
+
const { protocol } = new URL(href);
|
|
1418
|
+
return protocol === "http:" || protocol === "https:";
|
|
1419
|
+
} catch (e) {
|
|
1420
|
+
return false;
|
|
1421
|
+
}
|
|
1422
|
+
}
|
|
1423
|
+
function renderInline(text, theme, key) {
|
|
1424
|
+
var _a, _b;
|
|
1425
|
+
const out = [];
|
|
1426
|
+
let plain = "";
|
|
1427
|
+
let i = 0;
|
|
1428
|
+
const flush = () => {
|
|
1429
|
+
if (plain) out.push(plain);
|
|
1430
|
+
plain = "";
|
|
1431
|
+
};
|
|
1432
|
+
const link = (href, label, k) => /* @__PURE__ */ jsx2(
|
|
1433
|
+
"a",
|
|
1434
|
+
{
|
|
1435
|
+
href,
|
|
1436
|
+
target: "_blank",
|
|
1437
|
+
rel: "noopener noreferrer nofollow",
|
|
1438
|
+
title: href,
|
|
1439
|
+
style: {
|
|
1440
|
+
color: "inherit",
|
|
1441
|
+
textDecoration: "underline",
|
|
1442
|
+
textDecorationColor: theme.accent,
|
|
1443
|
+
textUnderlineOffset: "2px",
|
|
1444
|
+
wordBreak: "break-word"
|
|
1445
|
+
},
|
|
1446
|
+
children: label
|
|
1447
|
+
},
|
|
1448
|
+
k
|
|
1449
|
+
);
|
|
1450
|
+
while (i < text.length) {
|
|
1451
|
+
const ch = text[i];
|
|
1452
|
+
const prev = i > 0 ? text[i - 1] : "";
|
|
1453
|
+
const k = `${key}.${i}`;
|
|
1454
|
+
let m;
|
|
1455
|
+
if (ch === "\\" && i + 1 < text.length && ESCAPABLE.includes(text[i + 1])) {
|
|
1456
|
+
plain += text[i + 1];
|
|
1457
|
+
i += 2;
|
|
1458
|
+
continue;
|
|
1459
|
+
}
|
|
1460
|
+
if (ch === "`" && (m = at(CODE, text, i))) {
|
|
1461
|
+
flush();
|
|
1462
|
+
out.push(
|
|
1463
|
+
/* @__PURE__ */ jsx2(
|
|
1464
|
+
"code",
|
|
1465
|
+
{
|
|
1466
|
+
style: {
|
|
1467
|
+
fontFamily: MONO,
|
|
1468
|
+
fontSize: "0.92em",
|
|
1469
|
+
padding: "1px 4px",
|
|
1470
|
+
borderRadius: "4px",
|
|
1471
|
+
backgroundColor: theme.bg,
|
|
1472
|
+
border: `1px solid ${theme.border}`,
|
|
1473
|
+
wordBreak: "break-word"
|
|
1474
|
+
},
|
|
1475
|
+
children: m[1]
|
|
1476
|
+
},
|
|
1477
|
+
k
|
|
1478
|
+
)
|
|
1479
|
+
);
|
|
1480
|
+
i += m[0].length;
|
|
1481
|
+
continue;
|
|
1482
|
+
}
|
|
1483
|
+
const image = ch === "!" && text[i + 1] === "[";
|
|
1484
|
+
if ((ch === "[" || image) && (m = at(MD_LINK, text, image ? i + 1 : i)) && isSafeHref(m[2])) {
|
|
1485
|
+
flush();
|
|
1486
|
+
const label = m[1] ? renderInline(m[1], theme, k) : m[2];
|
|
1487
|
+
out.push(link(m[2], label, k));
|
|
1488
|
+
i += m[0].length + (image ? 1 : 0);
|
|
1489
|
+
continue;
|
|
1490
|
+
}
|
|
1491
|
+
if (ch === "~" && text[i + 1] === "~" && (m = at(STRIKE, text, i))) {
|
|
1492
|
+
flush();
|
|
1493
|
+
out.push(/* @__PURE__ */ jsx2("del", { children: renderInline(m[1], theme, k) }, k));
|
|
1494
|
+
i += m[0].length;
|
|
1495
|
+
continue;
|
|
1496
|
+
}
|
|
1497
|
+
if ((ch === "*" || ch === "_") && !WORD.test(prev)) {
|
|
1498
|
+
const double = text[i + 1] === ch;
|
|
1499
|
+
const bold = double ? at(ch === "*" ? BOLD_STAR : BOLD_UNDER, text, i) : null;
|
|
1500
|
+
const italic = bold ? null : at(ch === "*" ? ITALIC_STAR : ITALIC_UNDER, text, i);
|
|
1501
|
+
m = bold != null ? bold : italic;
|
|
1502
|
+
if (m && !WORD.test((_a = text[i + m[0].length]) != null ? _a : "")) {
|
|
1503
|
+
flush();
|
|
1504
|
+
const inner = renderInline(m[1], theme, k);
|
|
1505
|
+
out.push(
|
|
1506
|
+
bold ? /* @__PURE__ */ jsx2("strong", { style: { fontWeight: 700 }, children: inner }, k) : /* @__PURE__ */ jsx2("em", { style: { fontStyle: "italic" }, children: inner }, k)
|
|
1507
|
+
);
|
|
1508
|
+
i += m[0].length;
|
|
1509
|
+
continue;
|
|
1510
|
+
}
|
|
1511
|
+
}
|
|
1512
|
+
if (!URL_EDGE.test(prev)) {
|
|
1513
|
+
m = ch === "h" ? at(FULL_URL, text, i) : null;
|
|
1514
|
+
const bare = m ? null : /[a-z0-9]/.test(ch) ? at(BARE_URL, text, i) : null;
|
|
1515
|
+
const raw = (_b = m == null ? void 0 : m[0]) != null ? _b : bare == null ? void 0 : bare[0];
|
|
1516
|
+
if (raw) {
|
|
1517
|
+
const shown = raw.replace(TRAILING_PUNCT, "");
|
|
1518
|
+
const href = m ? shown : `https://${shown}`;
|
|
1519
|
+
if (shown.includes("/") && isSafeHref(href)) {
|
|
1520
|
+
flush();
|
|
1521
|
+
out.push(link(href, shown, k));
|
|
1522
|
+
i += shown.length;
|
|
1523
|
+
continue;
|
|
1524
|
+
}
|
|
1525
|
+
}
|
|
1526
|
+
}
|
|
1527
|
+
plain += ch;
|
|
1528
|
+
i += 1;
|
|
1529
|
+
}
|
|
1530
|
+
flush();
|
|
1531
|
+
return out;
|
|
1532
|
+
}
|
|
1533
|
+
var FENCE = /^\s{0,3}(`{3,}|~{3,})/;
|
|
1534
|
+
var HEADING = /^\s{0,3}(#{1,6})\s+(.+?)(?:\s+#+)?\s*$/;
|
|
1535
|
+
var RULE = /^\s{0,3}([-*_])(?:\s*\1){2,}\s*$/;
|
|
1536
|
+
var QUOTE = /^\s{0,3}>\s?(.*)$/;
|
|
1537
|
+
var LIST_ITEM = /^(\s*)([-*+]|\d{1,9}[.)])\s+(.*)$/;
|
|
1538
|
+
var TABLE_SEP = /^\s*\|?\s*:?-+:?\s*(?:\|\s*:?-+:?\s*)*\|?\s*$/;
|
|
1539
|
+
var TASK = /^\[([ xX])\]\s+(.*)$/;
|
|
1540
|
+
var STACK = {
|
|
1541
|
+
display: "flex",
|
|
1542
|
+
flexDirection: "column",
|
|
1543
|
+
gap: "6px",
|
|
1544
|
+
minWidth: 0
|
|
1545
|
+
};
|
|
1546
|
+
function splitRow(line) {
|
|
1547
|
+
let s = line.trim();
|
|
1548
|
+
if (s.startsWith("|")) s = s.slice(1);
|
|
1549
|
+
if (s.endsWith("|") && !s.endsWith("\\|")) s = s.slice(0, -1);
|
|
1550
|
+
const cells = [];
|
|
1551
|
+
let cell = "";
|
|
1552
|
+
for (let i = 0; i < s.length; i++) {
|
|
1553
|
+
if (s[i] === "\\" && s[i + 1] === "|") {
|
|
1554
|
+
cell += "|";
|
|
1555
|
+
i++;
|
|
1556
|
+
} else if (s[i] === "|") {
|
|
1557
|
+
cells.push(cell.trim());
|
|
1558
|
+
cell = "";
|
|
1559
|
+
} else {
|
|
1560
|
+
cell += s[i];
|
|
1561
|
+
}
|
|
1562
|
+
}
|
|
1563
|
+
cells.push(cell.trim());
|
|
1564
|
+
return cells;
|
|
1565
|
+
}
|
|
1566
|
+
function tableAt(lines, i) {
|
|
1567
|
+
const head = lines[i];
|
|
1568
|
+
const sep = lines[i + 1];
|
|
1569
|
+
if (!(head == null ? void 0 : head.includes("|")) || !(sep == null ? void 0 : sep.includes("|")) || !TABLE_SEP.test(sep)) return null;
|
|
1570
|
+
const aligns = splitRow(sep);
|
|
1571
|
+
return aligns.length === splitRow(head).length ? aligns : null;
|
|
1572
|
+
}
|
|
1573
|
+
function startsBlock(lines, i) {
|
|
1574
|
+
const line = lines[i];
|
|
1575
|
+
return FENCE.test(line) || HEADING.test(line) || RULE.test(line) || QUOTE.test(line) || LIST_ITEM.test(line) || tableAt(lines, i) !== null;
|
|
1576
|
+
}
|
|
1577
|
+
function renderBlocks(lines, theme, key) {
|
|
1578
|
+
const out = [];
|
|
1579
|
+
let i = 0;
|
|
1580
|
+
while (i < lines.length) {
|
|
1581
|
+
const line = lines[i];
|
|
1582
|
+
const k = `${key}-${i}`;
|
|
1583
|
+
let m;
|
|
1584
|
+
if (!line.trim()) {
|
|
1585
|
+
i++;
|
|
1586
|
+
continue;
|
|
1587
|
+
}
|
|
1588
|
+
if (m = FENCE.exec(line)) {
|
|
1589
|
+
const fence = m[1];
|
|
1590
|
+
const body = [];
|
|
1591
|
+
i++;
|
|
1592
|
+
while (i < lines.length) {
|
|
1593
|
+
const t2 = lines[i].trim();
|
|
1594
|
+
if (t2.length >= fence.length && [...t2].every((c) => c === fence[0])) break;
|
|
1595
|
+
body.push(lines[i]);
|
|
1596
|
+
i++;
|
|
1597
|
+
}
|
|
1598
|
+
i++;
|
|
1599
|
+
out.push(
|
|
1600
|
+
/* @__PURE__ */ jsx2(
|
|
1601
|
+
"pre",
|
|
1602
|
+
{
|
|
1603
|
+
style: {
|
|
1604
|
+
margin: 0,
|
|
1605
|
+
padding: "8px 10px",
|
|
1606
|
+
borderRadius: "6px",
|
|
1607
|
+
backgroundColor: theme.bg,
|
|
1608
|
+
border: `1px solid ${theme.border}`,
|
|
1609
|
+
overflowX: "auto",
|
|
1610
|
+
maxWidth: "100%",
|
|
1611
|
+
fontFamily: MONO,
|
|
1612
|
+
fontSize: "12px",
|
|
1613
|
+
lineHeight: 1.5,
|
|
1614
|
+
whiteSpace: "pre"
|
|
1615
|
+
},
|
|
1616
|
+
children: /* @__PURE__ */ jsx2("code", { style: { fontFamily: "inherit" }, children: body.join("\n") })
|
|
1617
|
+
},
|
|
1618
|
+
k
|
|
1619
|
+
)
|
|
1620
|
+
);
|
|
1621
|
+
continue;
|
|
1622
|
+
}
|
|
1623
|
+
if (m = HEADING.exec(line)) {
|
|
1624
|
+
const level = m[1].length;
|
|
1625
|
+
out.push(
|
|
1626
|
+
/* @__PURE__ */ jsx2(
|
|
1627
|
+
"div",
|
|
1628
|
+
{
|
|
1629
|
+
role: "heading",
|
|
1630
|
+
"aria-level": level,
|
|
1631
|
+
style: {
|
|
1632
|
+
fontWeight: 700,
|
|
1633
|
+
fontSize: level === 1 ? "1.15em" : level === 2 ? "1.08em" : "1em",
|
|
1634
|
+
lineHeight: 1.35
|
|
1635
|
+
},
|
|
1636
|
+
children: renderInline(m[2], theme, k)
|
|
1637
|
+
},
|
|
1638
|
+
k
|
|
1639
|
+
)
|
|
1640
|
+
);
|
|
1641
|
+
i++;
|
|
1642
|
+
continue;
|
|
1643
|
+
}
|
|
1644
|
+
if (RULE.test(line)) {
|
|
1645
|
+
out.push(/* @__PURE__ */ jsx2("div", { role: "separator", style: { borderTop: `1px solid ${theme.border}` } }, k));
|
|
1646
|
+
i++;
|
|
1647
|
+
continue;
|
|
1648
|
+
}
|
|
1649
|
+
if (QUOTE.test(line)) {
|
|
1650
|
+
const inner = [];
|
|
1651
|
+
while (i < lines.length && (m = QUOTE.exec(lines[i]))) {
|
|
1652
|
+
inner.push(m[1]);
|
|
1653
|
+
i++;
|
|
1654
|
+
}
|
|
1655
|
+
out.push(
|
|
1656
|
+
/* @__PURE__ */ jsx2(
|
|
1657
|
+
"blockquote",
|
|
1658
|
+
{
|
|
1659
|
+
style: {
|
|
1660
|
+
...STACK,
|
|
1661
|
+
margin: 0,
|
|
1662
|
+
paddingLeft: "10px",
|
|
1663
|
+
// `border` is near the bubble's own colour; the bar vanished.
|
|
1664
|
+
borderLeft: `3px solid ${theme.accent}66`,
|
|
1665
|
+
color: theme.textMuted
|
|
1666
|
+
},
|
|
1667
|
+
children: renderBlocks(inner, theme, k)
|
|
1668
|
+
},
|
|
1669
|
+
k
|
|
1670
|
+
)
|
|
1671
|
+
);
|
|
1672
|
+
continue;
|
|
1673
|
+
}
|
|
1674
|
+
const aligns = tableAt(lines, i);
|
|
1675
|
+
if (aligns) {
|
|
1676
|
+
const head = splitRow(line);
|
|
1677
|
+
const rows = [];
|
|
1678
|
+
i += 2;
|
|
1679
|
+
while (i < lines.length && lines[i].trim() && lines[i].includes("|")) {
|
|
1680
|
+
rows.push(splitRow(lines[i]));
|
|
1681
|
+
i++;
|
|
1682
|
+
}
|
|
1683
|
+
const align = (c) => {
|
|
1684
|
+
var _a;
|
|
1685
|
+
const a = (_a = aligns[c]) != null ? _a : "";
|
|
1686
|
+
if (a.startsWith(":") && a.endsWith(":")) return "center";
|
|
1687
|
+
return a.endsWith(":") ? "right" : "left";
|
|
1688
|
+
};
|
|
1689
|
+
const cell = (c) => ({
|
|
1690
|
+
border: `1px solid ${theme.border}`,
|
|
1691
|
+
padding: "4px 8px",
|
|
1692
|
+
textAlign: align(c),
|
|
1693
|
+
verticalAlign: "top"
|
|
1694
|
+
});
|
|
1695
|
+
out.push(
|
|
1696
|
+
/* @__PURE__ */ jsx2("div", { style: { overflowX: "auto", maxWidth: "100%" }, children: /* @__PURE__ */ jsxs2("table", { style: { borderCollapse: "collapse", fontSize: "12px", margin: 0 }, children: [
|
|
1697
|
+
/* @__PURE__ */ jsx2("thead", { children: /* @__PURE__ */ jsx2("tr", { children: head.map((h, c) => /* @__PURE__ */ jsx2("th", { style: { ...cell(c), fontWeight: 600, backgroundColor: theme.bg }, children: renderInline(h, theme, `${k}h${c}`) }, c)) }) }),
|
|
1698
|
+
/* @__PURE__ */ jsx2("tbody", { children: rows.map((row, r) => /* @__PURE__ */ jsx2("tr", { children: head.map((_, c) => {
|
|
1699
|
+
var _a;
|
|
1700
|
+
return /* @__PURE__ */ jsx2("td", { style: cell(c), children: renderInline((_a = row[c]) != null ? _a : "", theme, `${k}r${r}c${c}`) }, c);
|
|
1701
|
+
}) }, r)) })
|
|
1702
|
+
] }) }, k)
|
|
1703
|
+
);
|
|
1704
|
+
continue;
|
|
1705
|
+
}
|
|
1706
|
+
if (m = LIST_ITEM.exec(line)) {
|
|
1707
|
+
const baseIndent = m[1].length;
|
|
1708
|
+
const ordered = /\d/.test(m[2]);
|
|
1709
|
+
const start = ordered ? parseInt(m[2], 10) : 1;
|
|
1710
|
+
const items = [];
|
|
1711
|
+
while (i < lines.length) {
|
|
1712
|
+
const l = lines[i];
|
|
1713
|
+
const lm = LIST_ITEM.exec(l);
|
|
1714
|
+
const indent = l.length - l.trimStart().length;
|
|
1715
|
+
if (lm && indent <= baseIndent + 1) {
|
|
1716
|
+
if (/\d/.test(lm[2]) !== ordered) break;
|
|
1717
|
+
items.push([lm[3]]);
|
|
1718
|
+
i++;
|
|
1719
|
+
continue;
|
|
1720
|
+
}
|
|
1721
|
+
const current = items[items.length - 1];
|
|
1722
|
+
if (!l.trim()) {
|
|
1723
|
+
const next = lines[i + 1];
|
|
1724
|
+
const nextIndent = next ? next.length - next.trimStart().length : 0;
|
|
1725
|
+
if ((next == null ? void 0 : next.trim()) && (nextIndent > baseIndent + 1 || LIST_ITEM.test(next))) {
|
|
1726
|
+
current.push("");
|
|
1727
|
+
i++;
|
|
1728
|
+
continue;
|
|
1729
|
+
}
|
|
1730
|
+
break;
|
|
1731
|
+
}
|
|
1732
|
+
if (indent > baseIndent + 1) {
|
|
1733
|
+
current.push(l.slice(Math.min(indent, baseIndent + 2)));
|
|
1734
|
+
i++;
|
|
1735
|
+
continue;
|
|
1736
|
+
}
|
|
1737
|
+
break;
|
|
1738
|
+
}
|
|
1739
|
+
const ListTag = ordered ? "ol" : "ul";
|
|
1740
|
+
out.push(
|
|
1741
|
+
/* @__PURE__ */ jsx2(
|
|
1742
|
+
ListTag,
|
|
1743
|
+
{
|
|
1744
|
+
start: ordered && start !== 1 ? start : void 0,
|
|
1745
|
+
style: {
|
|
1746
|
+
margin: 0,
|
|
1747
|
+
paddingLeft: "20px",
|
|
1748
|
+
listStyleType: ordered ? "decimal" : "disc",
|
|
1749
|
+
listStylePosition: "outside"
|
|
1750
|
+
},
|
|
1751
|
+
children: items.map((itemLines, n) => {
|
|
1752
|
+
const ik = `${k}i${n}`;
|
|
1753
|
+
const task = TASK.exec(itemLines[0]);
|
|
1754
|
+
const body = task ? [task[2], ...itemLines.slice(1)] : itemLines;
|
|
1755
|
+
const box = task ? /* @__PURE__ */ jsx2("span", { "aria-hidden": "true", style: { marginRight: "6px" }, children: task[1] === " " ? "\u2610" : "\u2611" }) : null;
|
|
1756
|
+
const simple = body.filter((x) => x.trim()).length === 1;
|
|
1757
|
+
return /* @__PURE__ */ jsx2(
|
|
1758
|
+
"li",
|
|
1759
|
+
{
|
|
1760
|
+
style: {
|
|
1761
|
+
display: "list-item",
|
|
1762
|
+
marginTop: n ? "3px" : 0,
|
|
1763
|
+
paddingLeft: "2px",
|
|
1764
|
+
listStyleType: task ? "none" : void 0
|
|
1765
|
+
},
|
|
1766
|
+
children: simple ? /* @__PURE__ */ jsxs2(Fragment, { children: [
|
|
1767
|
+
box,
|
|
1768
|
+
renderInline(body[0], theme, ik)
|
|
1769
|
+
] }) : /* @__PURE__ */ jsxs2("div", { style: STACK, children: [
|
|
1770
|
+
box ? /* @__PURE__ */ jsxs2("div", { children: [
|
|
1771
|
+
box,
|
|
1772
|
+
renderInline(body[0], theme, ik)
|
|
1773
|
+
] }) : null,
|
|
1774
|
+
renderBlocks(box ? body.slice(1) : body, theme, ik)
|
|
1775
|
+
] })
|
|
1776
|
+
},
|
|
1777
|
+
ik
|
|
1778
|
+
);
|
|
1779
|
+
})
|
|
1780
|
+
},
|
|
1781
|
+
k
|
|
1782
|
+
)
|
|
1783
|
+
);
|
|
1784
|
+
continue;
|
|
1785
|
+
}
|
|
1786
|
+
const para = [];
|
|
1787
|
+
while (i < lines.length && lines[i].trim() && !(para.length && startsBlock(lines, i))) {
|
|
1788
|
+
para.push(lines[i].trim());
|
|
1789
|
+
i++;
|
|
1790
|
+
}
|
|
1791
|
+
out.push(
|
|
1792
|
+
/* @__PURE__ */ jsx2("div", { children: para.flatMap((p, n) => {
|
|
1793
|
+
const inline = renderInline(p, theme, `${k}p${n}`);
|
|
1794
|
+
return n ? [/* @__PURE__ */ jsx2("br", {}, `${k}br${n}`), ...inline] : inline;
|
|
1795
|
+
}) }, k)
|
|
1796
|
+
);
|
|
1797
|
+
}
|
|
1798
|
+
return out;
|
|
1799
|
+
}
|
|
1800
|
+
function ChatMarkdown({ text, theme }) {
|
|
1801
|
+
return /* @__PURE__ */ jsx2("div", { style: STACK, children: renderBlocks(text.replace(/\r\n?/g, "\n").split("\n"), theme, "md") });
|
|
1802
|
+
}
|
|
1392
1803
|
function pickAssistImages(all) {
|
|
1393
1804
|
const picked = [];
|
|
1394
1805
|
let total = 0;
|
|
@@ -1421,6 +1832,17 @@ var STARTERS = [
|
|
|
1421
1832
|
"It did the wrong thing",
|
|
1422
1833
|
"I wish it could\u2026"
|
|
1423
1834
|
];
|
|
1835
|
+
var CONFIRM_OPTION = "Yes, that's it";
|
|
1836
|
+
function isCheckBackQuestion(text) {
|
|
1837
|
+
const t2 = text.trim();
|
|
1838
|
+
return /^so,? you['’]?re saying\b/i.test(t2) || /\b(is that right|is that correct|did i get (that|it) right|have i got (that|it) right)\s*\??\s*$/i.test(t2);
|
|
1839
|
+
}
|
|
1840
|
+
function isAffirmativeReply(text) {
|
|
1841
|
+
return /^(y|ya|yah|yes|yess|yeah|yep|yup|ok|okay|sure|correct|right|exactly|confirm(ed)?|that['’]?s (it|right|correct)|yes,? that['’]?s (it|right)|haan|han|ha|ho|hmm yes|👍)[\s.!👍]*$/i.test(
|
|
1842
|
+
text.trim()
|
|
1843
|
+
);
|
|
1844
|
+
}
|
|
1845
|
+
var AUTO_FILE_SECONDS = 3;
|
|
1424
1846
|
var NARROW_QUERY = "(max-width: 640px)";
|
|
1425
1847
|
function useIsNarrow() {
|
|
1426
1848
|
const [narrow, setNarrow] = useState2(false);
|
|
@@ -1437,7 +1859,7 @@ function useIsNarrow() {
|
|
|
1437
1859
|
return narrow;
|
|
1438
1860
|
}
|
|
1439
1861
|
function Sparkle({ color, size = 14 }) {
|
|
1440
|
-
return /* @__PURE__ */
|
|
1862
|
+
return /* @__PURE__ */ jsx3("svg", { width: size, height: size, viewBox: "0 0 24 24", fill: "none", "aria-hidden": "true", children: /* @__PURE__ */ jsx3(
|
|
1441
1863
|
"path",
|
|
1442
1864
|
{
|
|
1443
1865
|
d: "M12 3l1.5 4.5L18 9l-4.5 1.5L12 15l-1.5-4.5L6 9l4.5-1.5L12 3zM19 15l.75 2.25L22 18l-2.25.75L19 21l-.75-2.25L16 18l2.25-.75L19 15z",
|
|
@@ -1453,7 +1875,7 @@ function Avatar({
|
|
|
1453
1875
|
initials
|
|
1454
1876
|
}) {
|
|
1455
1877
|
const isAi = who === "assistant";
|
|
1456
|
-
return /* @__PURE__ */
|
|
1878
|
+
return /* @__PURE__ */ jsx3(
|
|
1457
1879
|
"span",
|
|
1458
1880
|
{
|
|
1459
1881
|
"aria-hidden": "true",
|
|
@@ -1472,9 +1894,9 @@ function Avatar({
|
|
|
1472
1894
|
fontSize: "10px",
|
|
1473
1895
|
fontWeight: 700
|
|
1474
1896
|
},
|
|
1475
|
-
children: isAi ? /* @__PURE__ */
|
|
1476
|
-
/* @__PURE__ */
|
|
1477
|
-
/* @__PURE__ */
|
|
1897
|
+
children: isAi ? /* @__PURE__ */ jsx3(Sparkle, { color: t2.accent, size: 12 }) : initials ? initials : /* @__PURE__ */ jsxs3("svg", { width: "12", height: "12", viewBox: "0 0 24 24", fill: "none", "aria-hidden": "true", children: [
|
|
1898
|
+
/* @__PURE__ */ jsx3("circle", { cx: "12", cy: "8", r: "3.4", stroke: "currentColor", strokeWidth: "1.8" }),
|
|
1899
|
+
/* @__PURE__ */ jsx3(
|
|
1478
1900
|
"path",
|
|
1479
1901
|
{
|
|
1480
1902
|
d: "M5 20c0-3.6 3.1-5.6 7-5.6s7 2 7 5.6",
|
|
@@ -1535,12 +1957,15 @@ function AssistSheet({
|
|
|
1535
1957
|
const [duplicate, setDuplicate] = useState2(null);
|
|
1536
1958
|
const [glitchgrabOffer, setGlitchgrabOffer] = useState2(false);
|
|
1537
1959
|
const [solved, setSolved] = useState2(null);
|
|
1960
|
+
const needsSeverity = (tile) => showSeverity && tile === "BUG" && !severity;
|
|
1538
1961
|
const [phase, setPhase] = useState2(
|
|
1539
|
-
!typePicked ? "type" : currentTile === "RATING" ? "rating" : "chat"
|
|
1962
|
+
() => !typePicked ? "type" : currentTile === "RATING" ? "rating" : needsSeverity(currentTile) ? "severity" : "chat"
|
|
1540
1963
|
);
|
|
1964
|
+
const [autoFileLeft, setAutoFileLeft] = useState2(null);
|
|
1541
1965
|
const scrollRef = useRef2(null);
|
|
1542
1966
|
const draftRef = useRef2(null);
|
|
1543
1967
|
const seededRef = useRef2(false);
|
|
1968
|
+
const seedPendingRef = useRef2(false);
|
|
1544
1969
|
const eventsRef = useRef2([]);
|
|
1545
1970
|
const aiDraftRef = useRef2(null);
|
|
1546
1971
|
function logEvent(type, detail) {
|
|
@@ -1580,14 +2005,33 @@ function AssistSheet({
|
|
|
1580
2005
|
var _a;
|
|
1581
2006
|
if (phase === "draft") (_a = draftRef.current) == null ? void 0 : _a.focus();
|
|
1582
2007
|
}, [phase]);
|
|
2008
|
+
useEffect2(() => {
|
|
2009
|
+
if (autoFileLeft === null) return;
|
|
2010
|
+
if (isSubmitting || submitted || phase !== "draft") {
|
|
2011
|
+
setAutoFileLeft(null);
|
|
2012
|
+
return;
|
|
2013
|
+
}
|
|
2014
|
+
if (autoFileLeft <= 0) {
|
|
2015
|
+
sendDraft(true);
|
|
2016
|
+
return;
|
|
2017
|
+
}
|
|
2018
|
+
const id = setTimeout(() => setAutoFileLeft((n) => n === null ? null : n - 1), 1e3);
|
|
2019
|
+
return () => clearTimeout(id);
|
|
2020
|
+
}, [autoFileLeft, isSubmitting, submitted, phase]);
|
|
2021
|
+
function stopAutoFile(reason) {
|
|
2022
|
+
if (autoFileLeft === null) return;
|
|
2023
|
+
setAutoFileLeft(null);
|
|
2024
|
+
logEvent("auto_file_stopped", reason);
|
|
2025
|
+
}
|
|
1583
2026
|
function degradeKeepingEvents(events, message, retryable) {
|
|
1584
2027
|
if (events) eventsRef.current = [...events, ...eventsRef.current];
|
|
1585
2028
|
flushEvents();
|
|
1586
2029
|
onDegrade(message, retryable);
|
|
1587
2030
|
}
|
|
1588
|
-
async function runTurn(history2) {
|
|
2031
|
+
async function runTurn(history2, autoFile = false) {
|
|
1589
2032
|
var _a, _b;
|
|
1590
2033
|
setBusy(true);
|
|
2034
|
+
setAutoFileLeft(null);
|
|
1591
2035
|
let result;
|
|
1592
2036
|
const events = takeEvents();
|
|
1593
2037
|
try {
|
|
@@ -1647,6 +2091,9 @@ function AssistSheet({
|
|
|
1647
2091
|
setMessages([...history2, { role: "assistant", content: result.report, kind: "report" }]);
|
|
1648
2092
|
setOptions([]);
|
|
1649
2093
|
setPhase("draft");
|
|
2094
|
+
if (autoFile && !attach && !(severityAsked && !severity)) {
|
|
2095
|
+
setAutoFileLeft(AUTO_FILE_SECONDS);
|
|
2096
|
+
}
|
|
1650
2097
|
return;
|
|
1651
2098
|
}
|
|
1652
2099
|
if (result.question) {
|
|
@@ -1660,13 +2107,34 @@ function AssistSheet({
|
|
|
1660
2107
|
if (seededRef.current) return;
|
|
1661
2108
|
seededRef.current = true;
|
|
1662
2109
|
if (!typePicked || currentTile === "RATING") return;
|
|
2110
|
+
if (phase === "severity") {
|
|
2111
|
+
seedPendingRef.current = true;
|
|
2112
|
+
return;
|
|
2113
|
+
}
|
|
2114
|
+
seedFromDescription();
|
|
2115
|
+
}, []);
|
|
2116
|
+
function seedFromDescription() {
|
|
1663
2117
|
const seed = description.trim();
|
|
1664
2118
|
if (!seed) return;
|
|
1665
2119
|
const history2 = [{ role: "user", content: seed }];
|
|
1666
2120
|
setMessages(history2);
|
|
1667
2121
|
void runTurn(history2);
|
|
1668
|
-
}
|
|
1669
|
-
function
|
|
2122
|
+
}
|
|
2123
|
+
function answerSeverity(value) {
|
|
2124
|
+
onSeverityChange(value);
|
|
2125
|
+
setPhase("chat");
|
|
2126
|
+
if (seedPendingRef.current) {
|
|
2127
|
+
seedPendingRef.current = false;
|
|
2128
|
+
seedFromDescription();
|
|
2129
|
+
}
|
|
2130
|
+
}
|
|
2131
|
+
function sendTyped(text) {
|
|
2132
|
+
var _a;
|
|
2133
|
+
const lastAssistant = [...messages].reverse().find((m) => m.role === "assistant");
|
|
2134
|
+
const checkingBack = options.includes(CONFIRM_OPTION) || (lastAssistant == null ? void 0 : lastAssistant.kind) !== "report" && isCheckBackQuestion((_a = lastAssistant == null ? void 0 : lastAssistant.content) != null ? _a : "");
|
|
2135
|
+
send(text, checkingBack && isAffirmativeReply(text));
|
|
2136
|
+
}
|
|
2137
|
+
function send(text, autoFile = false) {
|
|
1670
2138
|
const value = text.trim();
|
|
1671
2139
|
if (!value || busy) return;
|
|
1672
2140
|
setOptions([]);
|
|
@@ -1681,11 +2149,11 @@ function AssistSheet({
|
|
|
1681
2149
|
const history2 = [...base, { role: "user", content: value }];
|
|
1682
2150
|
setMessages(history2);
|
|
1683
2151
|
setInput("");
|
|
1684
|
-
void runTurn(history2);
|
|
2152
|
+
void runTurn(history2, autoFile);
|
|
1685
2153
|
}
|
|
1686
2154
|
function pickType(tile) {
|
|
1687
2155
|
onPickType(tile);
|
|
1688
|
-
setPhase(tile === "RATING" ? "rating" : "chat");
|
|
2156
|
+
setPhase(tile === "RATING" ? "rating" : needsSeverity(tile) ? "severity" : "chat");
|
|
1689
2157
|
}
|
|
1690
2158
|
function withCurrentDraft(history2) {
|
|
1691
2159
|
const current = description.trim();
|
|
@@ -1698,16 +2166,17 @@ function AssistSheet({
|
|
|
1698
2166
|
}
|
|
1699
2167
|
return next;
|
|
1700
2168
|
}
|
|
1701
|
-
function sendDraft() {
|
|
2169
|
+
function sendDraft(auto = false) {
|
|
2170
|
+
setAutoFileLeft(null);
|
|
1702
2171
|
const edited = aiDraftRef.current !== null && description.trim() !== aiDraftRef.current.trim();
|
|
1703
|
-
logEvent("draft_sent", edited ? "edited" : "as drafted");
|
|
2172
|
+
logEvent("draft_sent", auto ? "auto-filed" : edited ? "edited" : "as drafted");
|
|
1704
2173
|
flushEvents();
|
|
1705
2174
|
onSend();
|
|
1706
2175
|
}
|
|
1707
2176
|
const empty = phase === "chat" && messages.length === 0 && !busy;
|
|
1708
2177
|
function renderKnownIssue({ title, footer }) {
|
|
1709
2178
|
if (!duplicate) return null;
|
|
1710
|
-
return /* @__PURE__ */
|
|
2179
|
+
return /* @__PURE__ */ jsxs3(
|
|
1711
2180
|
"div",
|
|
1712
2181
|
{
|
|
1713
2182
|
"data-gg-known-issue": "",
|
|
@@ -1724,15 +2193,15 @@ function AssistSheet({
|
|
|
1724
2193
|
minWidth: 0
|
|
1725
2194
|
},
|
|
1726
2195
|
children: [
|
|
1727
|
-
/* @__PURE__ */
|
|
1728
|
-
title && /* @__PURE__ */
|
|
2196
|
+
/* @__PURE__ */ jsx3("span", { style: { color: t2.text, fontWeight: 600 }, children: duplicate.kind === "related" ? title ? "Your request goes onto this issue" : `Connected to #${duplicate.number}` : title ? "Our team is already on this" : `Our team is already on #${duplicate.number}` }),
|
|
2197
|
+
title && /* @__PURE__ */ jsxs3("span", { style: { color: t2.textMuted, wordBreak: "break-word" }, children: [
|
|
1729
2198
|
"#",
|
|
1730
2199
|
duplicate.number,
|
|
1731
2200
|
" ",
|
|
1732
2201
|
duplicate.title
|
|
1733
2202
|
] }),
|
|
1734
|
-
duplicate.status && duplicate.kind !== "related" && /* @__PURE__ */
|
|
1735
|
-
footer && /* @__PURE__ */
|
|
2203
|
+
duplicate.status && duplicate.kind !== "related" && /* @__PURE__ */ jsx3("span", { style: { color: t2.text, fontWeight: 600 }, children: duplicate.status }),
|
|
2204
|
+
footer && /* @__PURE__ */ jsx3("span", { style: { color: t2.textMuted }, children: duplicate.kind === "related" ? "Added as a separate request on it, not a repeat \u2014 the team sees both." : footer })
|
|
1736
2205
|
]
|
|
1737
2206
|
}
|
|
1738
2207
|
);
|
|
@@ -1755,15 +2224,16 @@ function AssistSheet({
|
|
|
1755
2224
|
animation: "gg-sheet-in .22s cubic-bezier(.2,.8,.2,1)"
|
|
1756
2225
|
};
|
|
1757
2226
|
return createPortal(
|
|
1758
|
-
/* @__PURE__ */
|
|
1759
|
-
/* @__PURE__ */
|
|
2227
|
+
/* @__PURE__ */ jsxs3(Fragment2, { children: [
|
|
2228
|
+
/* @__PURE__ */ jsx3("style", { children: `
|
|
1760
2229
|
@keyframes gg-sheet-in{from{transform:translateX(24px);opacity:0}to{transform:translateX(0);opacity:1}}
|
|
1761
2230
|
@keyframes gg-sheet-up{from{transform:translateY(24px);opacity:0}to{transform:translateY(0);opacity:1}}
|
|
1762
2231
|
@keyframes gg-sheet-fade{from{opacity:0}to{opacity:1}}
|
|
2232
|
+
@keyframes gg-autofile{from{transform:scaleX(0)}to{transform:scaleX(1)}}
|
|
1763
2233
|
@keyframes gg-dot{0%,80%,100%{transform:translateY(0);opacity:.4}40%{transform:translateY(-3px);opacity:1}}
|
|
1764
|
-
[data-gg-sheet-send]:focus-visible,[data-gg-chip]:focus-visible,[data-gg-assist-remove]:focus-visible{outline:2px solid currentColor;outline-offset:2px}
|
|
2234
|
+
[data-gg-sheet-send]:focus-visible,[data-gg-chip]:focus-visible,[data-gg-assist-remove]:focus-visible,[data-gg-stop-auto-file]:focus-visible{outline:2px solid currentColor;outline-offset:2px}
|
|
1765
2235
|
` }),
|
|
1766
|
-
/* @__PURE__ */
|
|
2236
|
+
/* @__PURE__ */ jsx3(
|
|
1767
2237
|
"div",
|
|
1768
2238
|
{
|
|
1769
2239
|
"data-glitchgrab-layer": "",
|
|
@@ -1783,7 +2253,7 @@ function AssistSheet({
|
|
|
1783
2253
|
},
|
|
1784
2254
|
onClick: () => leave("closed"),
|
|
1785
2255
|
onPointerDown: (e) => e.stopPropagation(),
|
|
1786
|
-
children: /* @__PURE__ */
|
|
2256
|
+
children: /* @__PURE__ */ jsxs3(
|
|
1787
2257
|
"div",
|
|
1788
2258
|
{
|
|
1789
2259
|
onClick: (e) => e.stopPropagation(),
|
|
@@ -1804,7 +2274,7 @@ function AssistSheet({
|
|
|
1804
2274
|
isolation: "isolate"
|
|
1805
2275
|
},
|
|
1806
2276
|
children: [
|
|
1807
|
-
/* @__PURE__ */
|
|
2277
|
+
/* @__PURE__ */ jsxs3(
|
|
1808
2278
|
"div",
|
|
1809
2279
|
{
|
|
1810
2280
|
"data-gg-sheet-header": "",
|
|
@@ -1819,8 +2289,8 @@ function AssistSheet({
|
|
|
1819
2289
|
minWidth: 0
|
|
1820
2290
|
},
|
|
1821
2291
|
children: [
|
|
1822
|
-
/* @__PURE__ */
|
|
1823
|
-
/* @__PURE__ */
|
|
2292
|
+
/* @__PURE__ */ jsxs3("div", { style: { minWidth: 0 }, children: [
|
|
2293
|
+
/* @__PURE__ */ jsxs3(
|
|
1824
2294
|
"div",
|
|
1825
2295
|
{
|
|
1826
2296
|
style: {
|
|
@@ -1831,9 +2301,9 @@ function AssistSheet({
|
|
|
1831
2301
|
fontWeight: 600
|
|
1832
2302
|
},
|
|
1833
2303
|
children: [
|
|
1834
|
-
/* @__PURE__ */
|
|
2304
|
+
/* @__PURE__ */ jsx3(Sparkle, { color: t2.accent }),
|
|
1835
2305
|
"Describe it with AI",
|
|
1836
|
-
/* @__PURE__ */
|
|
2306
|
+
/* @__PURE__ */ jsx3(
|
|
1837
2307
|
"span",
|
|
1838
2308
|
{
|
|
1839
2309
|
style: {
|
|
@@ -1852,12 +2322,13 @@ function AssistSheet({
|
|
|
1852
2322
|
]
|
|
1853
2323
|
}
|
|
1854
2324
|
),
|
|
1855
|
-
/* @__PURE__ */
|
|
2325
|
+
/* @__PURE__ */ jsxs3("div", { style: { fontSize: "11.5px", color: t2.textMuted, marginTop: "3px" }, children: [
|
|
1856
2326
|
phase === "type" ? null : reportTypeLabel,
|
|
1857
|
-
|
|
2327
|
+
phase !== "type" && severityAsked && severity ? ` \xB7 ${SEVERITY_LABELS[severity]}` : null,
|
|
2328
|
+
projectSlot ? /* @__PURE__ */ jsx3("span", { style: { marginLeft: "6px" }, children: projectSlot }) : null
|
|
1858
2329
|
] })
|
|
1859
2330
|
] }),
|
|
1860
|
-
/* @__PURE__ */
|
|
2331
|
+
/* @__PURE__ */ jsx3(
|
|
1861
2332
|
"button",
|
|
1862
2333
|
{
|
|
1863
2334
|
type: "button",
|
|
@@ -1884,7 +2355,7 @@ function AssistSheet({
|
|
|
1884
2355
|
]
|
|
1885
2356
|
}
|
|
1886
2357
|
),
|
|
1887
|
-
/* @__PURE__ */
|
|
2358
|
+
/* @__PURE__ */ jsx3(
|
|
1888
2359
|
"div",
|
|
1889
2360
|
{
|
|
1890
2361
|
ref: scrollRef,
|
|
@@ -1896,7 +2367,7 @@ function AssistSheet({
|
|
|
1896
2367
|
display: "flex",
|
|
1897
2368
|
flexDirection: "column"
|
|
1898
2369
|
},
|
|
1899
|
-
children: /* @__PURE__ */
|
|
2370
|
+
children: /* @__PURE__ */ jsxs3(
|
|
1900
2371
|
"div",
|
|
1901
2372
|
{
|
|
1902
2373
|
style: {
|
|
@@ -1907,10 +2378,10 @@ function AssistSheet({
|
|
|
1907
2378
|
minWidth: 0
|
|
1908
2379
|
},
|
|
1909
2380
|
children: [
|
|
1910
|
-
phase === "type" && /* @__PURE__ */
|
|
1911
|
-
/* @__PURE__ */
|
|
1912
|
-
/* @__PURE__ */
|
|
1913
|
-
/* @__PURE__ */
|
|
2381
|
+
phase === "type" && /* @__PURE__ */ jsxs3("div", { style: { display: "flex", flexDirection: "column", gap: "12px" }, children: [
|
|
2382
|
+
/* @__PURE__ */ jsxs3("div", { style: { display: "flex", gap: "8px" }, children: [
|
|
2383
|
+
/* @__PURE__ */ jsx3(Avatar, { who: "assistant", theme: t2 }),
|
|
2384
|
+
/* @__PURE__ */ jsxs3(
|
|
1914
2385
|
"div",
|
|
1915
2386
|
{
|
|
1916
2387
|
style: {
|
|
@@ -1928,7 +2399,7 @@ function AssistSheet({
|
|
|
1928
2399
|
}
|
|
1929
2400
|
)
|
|
1930
2401
|
] }),
|
|
1931
|
-
/* @__PURE__ */
|
|
2402
|
+
/* @__PURE__ */ jsx3(
|
|
1932
2403
|
"div",
|
|
1933
2404
|
{
|
|
1934
2405
|
style: {
|
|
@@ -1939,7 +2410,7 @@ function AssistSheet({
|
|
|
1939
2410
|
},
|
|
1940
2411
|
children: tiles.map((tile) => {
|
|
1941
2412
|
const rate = tile === "RATING";
|
|
1942
|
-
return /* @__PURE__ */
|
|
2413
|
+
return /* @__PURE__ */ jsx3(
|
|
1943
2414
|
"button",
|
|
1944
2415
|
{
|
|
1945
2416
|
type: "button",
|
|
@@ -1972,10 +2443,66 @@ function AssistSheet({
|
|
|
1972
2443
|
}
|
|
1973
2444
|
)
|
|
1974
2445
|
] }),
|
|
1975
|
-
phase === "
|
|
1976
|
-
/* @__PURE__ */
|
|
1977
|
-
/* @__PURE__ */
|
|
1978
|
-
/* @__PURE__ */
|
|
2446
|
+
phase === "severity" && /* @__PURE__ */ jsxs3("div", { style: { display: "flex", flexDirection: "column", gap: "12px" }, children: [
|
|
2447
|
+
/* @__PURE__ */ jsxs3("div", { style: { display: "flex", gap: "8px" }, children: [
|
|
2448
|
+
/* @__PURE__ */ jsx3(Avatar, { who: "assistant", theme: t2 }),
|
|
2449
|
+
/* @__PURE__ */ jsx3(
|
|
2450
|
+
"div",
|
|
2451
|
+
{
|
|
2452
|
+
style: {
|
|
2453
|
+
padding: "9px 12px",
|
|
2454
|
+
borderRadius: "12px 12px 12px 4px",
|
|
2455
|
+
backgroundColor: t2.bgSecondary,
|
|
2456
|
+
fontSize: "13px",
|
|
2457
|
+
lineHeight: 1.55,
|
|
2458
|
+
maxWidth: "88%"
|
|
2459
|
+
},
|
|
2460
|
+
children: "How bad is it?"
|
|
2461
|
+
}
|
|
2462
|
+
)
|
|
2463
|
+
] }),
|
|
2464
|
+
/* @__PURE__ */ jsx3(
|
|
2465
|
+
"div",
|
|
2466
|
+
{
|
|
2467
|
+
role: "radiogroup",
|
|
2468
|
+
"aria-label": "Severity",
|
|
2469
|
+
style: {
|
|
2470
|
+
display: "flex",
|
|
2471
|
+
flexWrap: "wrap",
|
|
2472
|
+
gap: "6px",
|
|
2473
|
+
paddingLeft: "32px"
|
|
2474
|
+
},
|
|
2475
|
+
children: SEVERITY_LEVELS.map((s) => /* @__PURE__ */ jsx3(
|
|
2476
|
+
"button",
|
|
2477
|
+
{
|
|
2478
|
+
type: "button",
|
|
2479
|
+
role: "radio",
|
|
2480
|
+
"aria-checked": severity === s,
|
|
2481
|
+
"data-gg-chip": "",
|
|
2482
|
+
"data-gg-severity": s,
|
|
2483
|
+
onClick: () => answerSeverity(s),
|
|
2484
|
+
style: {
|
|
2485
|
+
border: `1px solid ${t2.inputBorder}`,
|
|
2486
|
+
background: "transparent",
|
|
2487
|
+
color: t2.textMuted,
|
|
2488
|
+
borderRadius: "999px",
|
|
2489
|
+
// Same as the picker and option chips — one chip size.
|
|
2490
|
+
padding: "8px 12px",
|
|
2491
|
+
fontSize: "12px",
|
|
2492
|
+
fontFamily: "inherit",
|
|
2493
|
+
cursor: "pointer"
|
|
2494
|
+
},
|
|
2495
|
+
children: SEVERITY_LABELS[s]
|
|
2496
|
+
},
|
|
2497
|
+
s
|
|
2498
|
+
))
|
|
2499
|
+
}
|
|
2500
|
+
)
|
|
2501
|
+
] }),
|
|
2502
|
+
phase === "rating" && !submitted && /* @__PURE__ */ jsxs3("div", { style: { display: "flex", flexDirection: "column", gap: "12px" }, children: [
|
|
2503
|
+
/* @__PURE__ */ jsxs3("div", { style: { display: "flex", gap: "8px" }, children: [
|
|
2504
|
+
/* @__PURE__ */ jsx3(Avatar, { who: "assistant", theme: t2 }),
|
|
2505
|
+
/* @__PURE__ */ jsx3(
|
|
1979
2506
|
"div",
|
|
1980
2507
|
{
|
|
1981
2508
|
style: {
|
|
@@ -1990,7 +2517,7 @@ function AssistSheet({
|
|
|
1990
2517
|
}
|
|
1991
2518
|
)
|
|
1992
2519
|
] }),
|
|
1993
|
-
/* @__PURE__ */
|
|
2520
|
+
/* @__PURE__ */ jsxs3(
|
|
1994
2521
|
"div",
|
|
1995
2522
|
{
|
|
1996
2523
|
style: {
|
|
@@ -2004,9 +2531,9 @@ function AssistSheet({
|
|
|
2004
2531
|
backgroundColor: "rgba(245,158,11,0.06)"
|
|
2005
2532
|
},
|
|
2006
2533
|
children: [
|
|
2007
|
-
/* @__PURE__ */
|
|
2534
|
+
/* @__PURE__ */ jsx3("div", { style: { display: "flex", gap: "4px" }, role: "group", "aria-label": "Rating", children: [1, 2, 3, 4, 5].map((star) => {
|
|
2008
2535
|
const filled = star <= (hoveredStar || rating);
|
|
2009
|
-
return /* @__PURE__ */
|
|
2536
|
+
return /* @__PURE__ */ jsx3(
|
|
2010
2537
|
"button",
|
|
2011
2538
|
{
|
|
2012
2539
|
type: "button",
|
|
@@ -2022,7 +2549,7 @@ function AssistSheet({
|
|
|
2022
2549
|
cursor: "pointer",
|
|
2023
2550
|
lineHeight: 0
|
|
2024
2551
|
},
|
|
2025
|
-
children: /* @__PURE__ */
|
|
2552
|
+
children: /* @__PURE__ */ jsx3("svg", { width: "30", height: "30", viewBox: "0 0 24 24", "aria-hidden": "true", children: /* @__PURE__ */ jsx3(
|
|
2026
2553
|
"path",
|
|
2027
2554
|
{
|
|
2028
2555
|
d: "M12 3l2.6 5.3 5.9.9-4.3 4.1 1 5.8L12 16.4 6.8 19.1l1-5.8L3.5 9.2l5.9-.9L12 3z",
|
|
@@ -2036,7 +2563,7 @@ function AssistSheet({
|
|
|
2036
2563
|
star
|
|
2037
2564
|
);
|
|
2038
2565
|
}) }),
|
|
2039
|
-
/* @__PURE__ */
|
|
2566
|
+
/* @__PURE__ */ jsx3(
|
|
2040
2567
|
"textarea",
|
|
2041
2568
|
{
|
|
2042
2569
|
value: description,
|
|
@@ -2059,7 +2586,7 @@ function AssistSheet({
|
|
|
2059
2586
|
}
|
|
2060
2587
|
}
|
|
2061
2588
|
),
|
|
2062
|
-
/* @__PURE__ */
|
|
2589
|
+
/* @__PURE__ */ jsx3(
|
|
2063
2590
|
"button",
|
|
2064
2591
|
{
|
|
2065
2592
|
type: "button",
|
|
@@ -2083,10 +2610,10 @@ function AssistSheet({
|
|
|
2083
2610
|
}
|
|
2084
2611
|
)
|
|
2085
2612
|
] }),
|
|
2086
|
-
empty && /* @__PURE__ */
|
|
2087
|
-
/* @__PURE__ */
|
|
2088
|
-
/* @__PURE__ */
|
|
2089
|
-
/* @__PURE__ */
|
|
2613
|
+
empty && /* @__PURE__ */ jsxs3("div", { style: { display: "flex", flexDirection: "column", gap: "12px" }, children: [
|
|
2614
|
+
/* @__PURE__ */ jsxs3("div", { style: { display: "flex", gap: "8px" }, children: [
|
|
2615
|
+
/* @__PURE__ */ jsx3(Avatar, { who: "assistant", theme: t2 }),
|
|
2616
|
+
/* @__PURE__ */ jsxs3(
|
|
2090
2617
|
"div",
|
|
2091
2618
|
{
|
|
2092
2619
|
style: {
|
|
@@ -2104,7 +2631,7 @@ function AssistSheet({
|
|
|
2104
2631
|
}
|
|
2105
2632
|
)
|
|
2106
2633
|
] }),
|
|
2107
|
-
/* @__PURE__ */
|
|
2634
|
+
/* @__PURE__ */ jsx3(
|
|
2108
2635
|
"div",
|
|
2109
2636
|
{
|
|
2110
2637
|
style: {
|
|
@@ -2113,7 +2640,7 @@ function AssistSheet({
|
|
|
2113
2640
|
gap: "6px",
|
|
2114
2641
|
paddingLeft: "32px"
|
|
2115
2642
|
},
|
|
2116
|
-
children: STARTERS.map((s) => /* @__PURE__ */
|
|
2643
|
+
children: STARTERS.map((s) => /* @__PURE__ */ jsx3(
|
|
2117
2644
|
"button",
|
|
2118
2645
|
{
|
|
2119
2646
|
type: "button",
|
|
@@ -2143,9 +2670,9 @@ function AssistSheet({
|
|
|
2143
2670
|
const mine = m.role === "user";
|
|
2144
2671
|
if (m.kind === "report") {
|
|
2145
2672
|
const live = phase === "draft" && i === messages.length - 1;
|
|
2146
|
-
return /* @__PURE__ */
|
|
2147
|
-
/* @__PURE__ */
|
|
2148
|
-
/* @__PURE__ */
|
|
2673
|
+
return /* @__PURE__ */ jsxs3("div", { style: { display: "flex", gap: "8px", minWidth: 0 }, children: [
|
|
2674
|
+
/* @__PURE__ */ jsx3(Avatar, { who: "assistant", theme: t2 }),
|
|
2675
|
+
/* @__PURE__ */ jsx3(
|
|
2149
2676
|
"div",
|
|
2150
2677
|
{
|
|
2151
2678
|
"data-gg-draft-bubble": "",
|
|
@@ -2160,8 +2687,12 @@ function AssistSheet({
|
|
|
2160
2687
|
color: t2.text,
|
|
2161
2688
|
border: live ? "none" : `1px solid ${t2.accent}66`
|
|
2162
2689
|
},
|
|
2163
|
-
children: live ?
|
|
2164
|
-
|
|
2690
|
+
children: live ? (
|
|
2691
|
+
// #402: "have a read" beside a countdown reads as a
|
|
2692
|
+
// contradiction. Say what is about to happen instead.
|
|
2693
|
+
autoFileLeft !== null ? "Here's your report \u2014 I'll file it unless you want to change something." : "Here's your report \u2014 have a read."
|
|
2694
|
+
) : /* @__PURE__ */ jsxs3(Fragment2, { children: [
|
|
2695
|
+
/* @__PURE__ */ jsx3(
|
|
2165
2696
|
"span",
|
|
2166
2697
|
{
|
|
2167
2698
|
style: {
|
|
@@ -2176,7 +2707,7 @@ function AssistSheet({
|
|
|
2176
2707
|
children: "Draft so far"
|
|
2177
2708
|
}
|
|
2178
2709
|
),
|
|
2179
|
-
/* @__PURE__ */
|
|
2710
|
+
/* @__PURE__ */ jsx3(
|
|
2180
2711
|
"span",
|
|
2181
2712
|
{
|
|
2182
2713
|
style: {
|
|
@@ -2195,7 +2726,7 @@ function AssistSheet({
|
|
|
2195
2726
|
)
|
|
2196
2727
|
] }, i);
|
|
2197
2728
|
}
|
|
2198
|
-
return /* @__PURE__ */
|
|
2729
|
+
return /* @__PURE__ */ jsxs3(
|
|
2199
2730
|
"div",
|
|
2200
2731
|
{
|
|
2201
2732
|
style: {
|
|
@@ -2205,22 +2736,24 @@ function AssistSheet({
|
|
|
2205
2736
|
flexDirection: mine ? "row-reverse" : "row"
|
|
2206
2737
|
},
|
|
2207
2738
|
children: [
|
|
2208
|
-
/* @__PURE__ */
|
|
2209
|
-
/* @__PURE__ */
|
|
2739
|
+
/* @__PURE__ */ jsx3(Avatar, { who: m.role, theme: t2, initials }),
|
|
2740
|
+
/* @__PURE__ */ jsx3(
|
|
2210
2741
|
"div",
|
|
2211
2742
|
{
|
|
2212
2743
|
style: {
|
|
2213
2744
|
maxWidth: "82%",
|
|
2745
|
+
minWidth: 0,
|
|
2214
2746
|
padding: "9px 12px",
|
|
2215
2747
|
borderRadius: mine ? "12px 12px 4px 12px" : "12px 12px 12px 4px",
|
|
2216
2748
|
fontSize: "13px",
|
|
2217
2749
|
lineHeight: 1.55,
|
|
2218
|
-
|
|
2750
|
+
// Markdown owns the assistant's line breaks and lists.
|
|
2751
|
+
whiteSpace: mine ? "pre-wrap" : "normal",
|
|
2219
2752
|
wordBreak: "break-word",
|
|
2220
2753
|
backgroundColor: mine ? t2.accent : t2.bgSecondary,
|
|
2221
2754
|
color: mine ? t2.accentText : t2.text
|
|
2222
2755
|
},
|
|
2223
|
-
children: m.content
|
|
2756
|
+
children: mine ? m.content : /* @__PURE__ */ jsx3(ChatMarkdown, { text: m.content, theme: t2 })
|
|
2224
2757
|
}
|
|
2225
2758
|
)
|
|
2226
2759
|
]
|
|
@@ -2228,8 +2761,8 @@ function AssistSheet({
|
|
|
2228
2761
|
i
|
|
2229
2762
|
);
|
|
2230
2763
|
}),
|
|
2231
|
-
duplicate && !busy && phase === "chat" && /* @__PURE__ */
|
|
2232
|
-
glitchgrabOffer && onReportGlitchgrabProblem && !busy && phase === "chat" && /* @__PURE__ */
|
|
2764
|
+
duplicate && !busy && phase === "chat" && /* @__PURE__ */ jsx3("div", { style: { paddingLeft: "32px", minWidth: 0 }, children: renderKnownIssue({ title: false }) }),
|
|
2765
|
+
glitchgrabOffer && onReportGlitchgrabProblem && !busy && phase === "chat" && /* @__PURE__ */ jsx3("div", { style: { paddingLeft: "32px", minWidth: 0 }, children: /* @__PURE__ */ jsxs3(
|
|
2233
2766
|
"div",
|
|
2234
2767
|
{
|
|
2235
2768
|
"data-gg-glitchgrab-offer": "",
|
|
@@ -2245,10 +2778,10 @@ function AssistSheet({
|
|
|
2245
2778
|
lineHeight: 1.5
|
|
2246
2779
|
},
|
|
2247
2780
|
children: [
|
|
2248
|
-
/* @__PURE__ */
|
|
2249
|
-
/* @__PURE__ */
|
|
2250
|
-
/* @__PURE__ */
|
|
2251
|
-
/* @__PURE__ */
|
|
2781
|
+
/* @__PURE__ */ jsx3("span", { style: { color: t2.text, fontWeight: 600 }, children: "This is about Glitchgrab, not this app" }),
|
|
2782
|
+
/* @__PURE__ */ jsx3("span", { style: { color: t2.textMuted }, children: "It goes to the team that builds this reporter, with your chat attached." }),
|
|
2783
|
+
/* @__PURE__ */ jsxs3("div", { style: { display: "flex", flexWrap: "wrap", gap: "6px" }, children: [
|
|
2784
|
+
/* @__PURE__ */ jsx3(
|
|
2252
2785
|
"button",
|
|
2253
2786
|
{
|
|
2254
2787
|
type: "button",
|
|
@@ -2277,7 +2810,7 @@ function AssistSheet({
|
|
|
2277
2810
|
children: "Send to the Glitchgrab team"
|
|
2278
2811
|
}
|
|
2279
2812
|
),
|
|
2280
|
-
/* @__PURE__ */
|
|
2813
|
+
/* @__PURE__ */ jsx3(
|
|
2281
2814
|
"button",
|
|
2282
2815
|
{
|
|
2283
2816
|
type: "button",
|
|
@@ -2304,7 +2837,7 @@ function AssistSheet({
|
|
|
2304
2837
|
]
|
|
2305
2838
|
}
|
|
2306
2839
|
) }),
|
|
2307
|
-
options.length > 0 && !busy && phase === "chat" && !glitchgrabOffer && /* @__PURE__ */
|
|
2840
|
+
options.length > 0 && !busy && phase === "chat" && !glitchgrabOffer && /* @__PURE__ */ jsx3(
|
|
2308
2841
|
"div",
|
|
2309
2842
|
{
|
|
2310
2843
|
style: {
|
|
@@ -2319,7 +2852,7 @@ function AssistSheet({
|
|
|
2319
2852
|
gap: "6px",
|
|
2320
2853
|
paddingLeft: "32px"
|
|
2321
2854
|
},
|
|
2322
|
-
children: options.map((option) => /* @__PURE__ */
|
|
2855
|
+
children: options.map((option) => /* @__PURE__ */ jsx3(
|
|
2323
2856
|
"button",
|
|
2324
2857
|
{
|
|
2325
2858
|
type: "button",
|
|
@@ -2327,7 +2860,7 @@ function AssistSheet({
|
|
|
2327
2860
|
"data-gg-option": "",
|
|
2328
2861
|
onClick: () => {
|
|
2329
2862
|
logEvent("option_tap", option);
|
|
2330
|
-
send(option);
|
|
2863
|
+
send(option, option === CONFIRM_OPTION);
|
|
2331
2864
|
},
|
|
2332
2865
|
style: {
|
|
2333
2866
|
border: `1px solid ${t2.inputBorder}`,
|
|
@@ -2348,9 +2881,9 @@ function AssistSheet({
|
|
|
2348
2881
|
))
|
|
2349
2882
|
}
|
|
2350
2883
|
),
|
|
2351
|
-
busy && /* @__PURE__ */
|
|
2352
|
-
/* @__PURE__ */
|
|
2353
|
-
/* @__PURE__ */
|
|
2884
|
+
busy && /* @__PURE__ */ jsxs3("div", { style: { display: "flex", gap: "8px" }, role: "status", "aria-label": "Thinking", children: [
|
|
2885
|
+
/* @__PURE__ */ jsx3(Avatar, { who: "assistant", theme: t2 }),
|
|
2886
|
+
/* @__PURE__ */ jsx3(
|
|
2354
2887
|
"span",
|
|
2355
2888
|
{
|
|
2356
2889
|
style: {
|
|
@@ -2361,7 +2894,7 @@ function AssistSheet({
|
|
|
2361
2894
|
borderRadius: "12px 12px 12px 4px",
|
|
2362
2895
|
backgroundColor: t2.bgSecondary
|
|
2363
2896
|
},
|
|
2364
|
-
children: [0, 1, 2].map((i) => /* @__PURE__ */
|
|
2897
|
+
children: [0, 1, 2].map((i) => /* @__PURE__ */ jsx3(
|
|
2365
2898
|
"span",
|
|
2366
2899
|
{
|
|
2367
2900
|
style: {
|
|
@@ -2377,7 +2910,7 @@ function AssistSheet({
|
|
|
2377
2910
|
}
|
|
2378
2911
|
)
|
|
2379
2912
|
] }),
|
|
2380
|
-
phase === "draft" && !submitted && /* @__PURE__ */
|
|
2913
|
+
phase === "draft" && !submitted && /* @__PURE__ */ jsxs3(
|
|
2381
2914
|
"div",
|
|
2382
2915
|
{
|
|
2383
2916
|
style: {
|
|
@@ -2392,7 +2925,7 @@ function AssistSheet({
|
|
|
2392
2925
|
boxSizing: "border-box"
|
|
2393
2926
|
},
|
|
2394
2927
|
children: [
|
|
2395
|
-
/* @__PURE__ */
|
|
2928
|
+
/* @__PURE__ */ jsx3(
|
|
2396
2929
|
"span",
|
|
2397
2930
|
{
|
|
2398
2931
|
style: {
|
|
@@ -2409,12 +2942,15 @@ function AssistSheet({
|
|
|
2409
2942
|
title: true,
|
|
2410
2943
|
footer: "Your details will be added to it instead of opening a new issue."
|
|
2411
2944
|
}),
|
|
2412
|
-
/* @__PURE__ */
|
|
2945
|
+
/* @__PURE__ */ jsx3(
|
|
2413
2946
|
"textarea",
|
|
2414
2947
|
{
|
|
2415
2948
|
ref: draftRef,
|
|
2416
2949
|
value: description,
|
|
2417
|
-
onChange: (e) =>
|
|
2950
|
+
onChange: (e) => {
|
|
2951
|
+
stopAutoFile("edited the draft");
|
|
2952
|
+
onDescriptionChange(e.target.value);
|
|
2953
|
+
},
|
|
2418
2954
|
rows: 6,
|
|
2419
2955
|
style: {
|
|
2420
2956
|
width: "100%",
|
|
@@ -2433,8 +2969,8 @@ function AssistSheet({
|
|
|
2433
2969
|
}
|
|
2434
2970
|
}
|
|
2435
2971
|
),
|
|
2436
|
-
severityAsked && /* @__PURE__ */
|
|
2437
|
-
/* @__PURE__ */
|
|
2972
|
+
severityAsked && autoFileLeft === null && /* @__PURE__ */ jsxs3("div", { children: [
|
|
2973
|
+
/* @__PURE__ */ jsxs3(
|
|
2438
2974
|
"span",
|
|
2439
2975
|
{
|
|
2440
2976
|
style: {
|
|
@@ -2445,7 +2981,7 @@ function AssistSheet({
|
|
|
2445
2981
|
},
|
|
2446
2982
|
children: [
|
|
2447
2983
|
"How bad is it?",
|
|
2448
|
-
!severity && /* @__PURE__ */
|
|
2984
|
+
!severity && /* @__PURE__ */ jsx3(
|
|
2449
2985
|
"span",
|
|
2450
2986
|
{
|
|
2451
2987
|
style: {
|
|
@@ -2459,7 +2995,7 @@ function AssistSheet({
|
|
|
2459
2995
|
]
|
|
2460
2996
|
}
|
|
2461
2997
|
),
|
|
2462
|
-
/* @__PURE__ */
|
|
2998
|
+
/* @__PURE__ */ jsx3(
|
|
2463
2999
|
"div",
|
|
2464
3000
|
{
|
|
2465
3001
|
role: "radiogroup",
|
|
@@ -2467,7 +3003,7 @@ function AssistSheet({
|
|
|
2467
3003
|
style: { display: "flex", gap: "6px" },
|
|
2468
3004
|
children: SEVERITY_LEVELS.map((s) => {
|
|
2469
3005
|
const on = severity === s;
|
|
2470
|
-
return /* @__PURE__ */
|
|
3006
|
+
return /* @__PURE__ */ jsx3(
|
|
2471
3007
|
"button",
|
|
2472
3008
|
{
|
|
2473
3009
|
type: "button",
|
|
@@ -2498,7 +3034,7 @@ function AssistSheet({
|
|
|
2498
3034
|
}
|
|
2499
3035
|
)
|
|
2500
3036
|
] }),
|
|
2501
|
-
attachmentCount > 0 && /* @__PURE__ */
|
|
3037
|
+
attachmentCount > 0 && /* @__PURE__ */ jsxs3("span", { style: { fontSize: "11.5px", color: t2.textMuted }, children: [
|
|
2502
3038
|
attachmentCount,
|
|
2503
3039
|
" ",
|
|
2504
3040
|
attachmentCount === 1 ? "attachment" : "attachments",
|
|
@@ -2507,10 +3043,10 @@ function AssistSheet({
|
|
|
2507
3043
|
]
|
|
2508
3044
|
}
|
|
2509
3045
|
),
|
|
2510
|
-
phase === "solved" && solved && /* @__PURE__ */
|
|
2511
|
-
/* @__PURE__ */
|
|
2512
|
-
/* @__PURE__ */
|
|
2513
|
-
/* @__PURE__ */
|
|
3046
|
+
phase === "solved" && solved && /* @__PURE__ */ jsxs3("div", { style: { display: "flex", flexDirection: "column", gap: "12px" }, children: [
|
|
3047
|
+
/* @__PURE__ */ jsxs3("div", { style: { display: "flex", gap: "8px" }, children: [
|
|
3048
|
+
/* @__PURE__ */ jsx3(Avatar, { who: "assistant", theme: t2 }),
|
|
3049
|
+
/* @__PURE__ */ jsx3(
|
|
2514
3050
|
"div",
|
|
2515
3051
|
{
|
|
2516
3052
|
style: {
|
|
@@ -2526,7 +3062,7 @@ function AssistSheet({
|
|
|
2526
3062
|
}
|
|
2527
3063
|
)
|
|
2528
3064
|
] }),
|
|
2529
|
-
/* @__PURE__ */
|
|
3065
|
+
/* @__PURE__ */ jsx3(
|
|
2530
3066
|
"span",
|
|
2531
3067
|
{
|
|
2532
3068
|
style: { fontSize: "11.5px", color: t2.textMuted, paddingLeft: "32px" },
|
|
@@ -2534,7 +3070,7 @@ function AssistSheet({
|
|
|
2534
3070
|
}
|
|
2535
3071
|
)
|
|
2536
3072
|
] }),
|
|
2537
|
-
submitted && /* @__PURE__ */
|
|
3073
|
+
submitted && /* @__PURE__ */ jsxs3(
|
|
2538
3074
|
"div",
|
|
2539
3075
|
{
|
|
2540
3076
|
style: {
|
|
@@ -2555,7 +3091,7 @@ function AssistSheet({
|
|
|
2555
3091
|
)
|
|
2556
3092
|
}
|
|
2557
3093
|
),
|
|
2558
|
-
!submitted && phase !== "type" && /* @__PURE__ */
|
|
3094
|
+
!submitted && phase !== "type" && phase !== "severity" && /* @__PURE__ */ jsxs3(
|
|
2559
3095
|
"div",
|
|
2560
3096
|
{
|
|
2561
3097
|
style: {
|
|
@@ -2566,7 +3102,7 @@ function AssistSheet({
|
|
|
2566
3102
|
backgroundColor: t2.bg
|
|
2567
3103
|
},
|
|
2568
3104
|
children: [
|
|
2569
|
-
phase === "solved" ? /* @__PURE__ */
|
|
3105
|
+
phase === "solved" ? /* @__PURE__ */ jsx3(
|
|
2570
3106
|
"button",
|
|
2571
3107
|
{
|
|
2572
3108
|
type: "button",
|
|
@@ -2586,7 +3122,7 @@ function AssistSheet({
|
|
|
2586
3122
|
},
|
|
2587
3123
|
children: "Done"
|
|
2588
3124
|
}
|
|
2589
|
-
) : phase === "rating" ? /* @__PURE__ */
|
|
3125
|
+
) : phase === "rating" ? /* @__PURE__ */ jsx3(
|
|
2590
3126
|
"button",
|
|
2591
3127
|
{
|
|
2592
3128
|
type: "button",
|
|
@@ -2612,8 +3148,8 @@ function AssistSheet({
|
|
|
2612
3148
|
// element on both sides of a draft landing — it stays put
|
|
2613
3149
|
// instead of remounting, and a draft is something you can
|
|
2614
3150
|
// still reply to (#360), not a form that replaced the chat.
|
|
2615
|
-
/* @__PURE__ */
|
|
2616
|
-
(screenshots.length > 0 || files.length > 0 || onAddFiles) && /* @__PURE__ */
|
|
3151
|
+
/* @__PURE__ */ jsxs3(Fragment2, { children: [
|
|
3152
|
+
(screenshots.length > 0 || files.length > 0 || onAddFiles) && /* @__PURE__ */ jsxs3(
|
|
2617
3153
|
"div",
|
|
2618
3154
|
{
|
|
2619
3155
|
style: {
|
|
@@ -2626,7 +3162,7 @@ function AssistSheet({
|
|
|
2626
3162
|
children: [
|
|
2627
3163
|
screenshots.map((shot, i) => {
|
|
2628
3164
|
const read = readShots.has(shot);
|
|
2629
|
-
return /* @__PURE__ */
|
|
3165
|
+
return /* @__PURE__ */ jsxs3(
|
|
2630
3166
|
"div",
|
|
2631
3167
|
{
|
|
2632
3168
|
style: {
|
|
@@ -2636,7 +3172,7 @@ function AssistSheet({
|
|
|
2636
3172
|
flexShrink: 0
|
|
2637
3173
|
},
|
|
2638
3174
|
children: [
|
|
2639
|
-
/* @__PURE__ */
|
|
3175
|
+
/* @__PURE__ */ jsx3(
|
|
2640
3176
|
"img",
|
|
2641
3177
|
{
|
|
2642
3178
|
src: shot,
|
|
@@ -2654,7 +3190,7 @@ function AssistSheet({
|
|
|
2654
3190
|
}
|
|
2655
3191
|
}
|
|
2656
3192
|
),
|
|
2657
|
-
onRemoveImage && /* @__PURE__ */
|
|
3193
|
+
onRemoveImage && /* @__PURE__ */ jsx3(
|
|
2658
3194
|
"button",
|
|
2659
3195
|
{
|
|
2660
3196
|
type: "button",
|
|
@@ -2662,6 +3198,7 @@ function AssistSheet({
|
|
|
2662
3198
|
"aria-label": `Remove image ${i + 1}`,
|
|
2663
3199
|
title: "Remove this image",
|
|
2664
3200
|
onClick: () => {
|
|
3201
|
+
stopAutoFile("changed attachments");
|
|
2665
3202
|
logEvent(
|
|
2666
3203
|
"image_removed",
|
|
2667
3204
|
pageShot && shot === pageShot ? "page capture" : "attached"
|
|
@@ -2683,7 +3220,7 @@ function AssistSheet({
|
|
|
2683
3220
|
justifyContent: "center",
|
|
2684
3221
|
borderRadius: "50%"
|
|
2685
3222
|
},
|
|
2686
|
-
children: /* @__PURE__ */
|
|
3223
|
+
children: /* @__PURE__ */ jsx3(
|
|
2687
3224
|
"span",
|
|
2688
3225
|
{
|
|
2689
3226
|
"aria-hidden": "true",
|
|
@@ -2699,7 +3236,7 @@ function AssistSheet({
|
|
|
2699
3236
|
alignItems: "center",
|
|
2700
3237
|
justifyContent: "center"
|
|
2701
3238
|
},
|
|
2702
|
-
children: /* @__PURE__ */
|
|
3239
|
+
children: /* @__PURE__ */ jsx3("svg", { width: "8", height: "8", viewBox: "0 0 10 10", fill: "none", children: /* @__PURE__ */ jsx3(
|
|
2703
3240
|
"path",
|
|
2704
3241
|
{
|
|
2705
3242
|
d: "M1 1L9 9M9 1L1 9",
|
|
@@ -2720,7 +3257,7 @@ function AssistSheet({
|
|
|
2720
3257
|
files.map((file, i) => {
|
|
2721
3258
|
const read = readFiles.has(i);
|
|
2722
3259
|
const why = read ? "the assistant reads this file" : isAssistReadableFile(file.name) ? "attached, but more than one message can carry, so the assistant is not reading it" : "attached to the report \u2014 the assistant can't read this kind of file";
|
|
2723
|
-
return /* @__PURE__ */
|
|
3260
|
+
return /* @__PURE__ */ jsxs3(
|
|
2724
3261
|
"div",
|
|
2725
3262
|
{
|
|
2726
3263
|
"data-gg-assist-file": "",
|
|
@@ -2741,7 +3278,7 @@ function AssistSheet({
|
|
|
2741
3278
|
flexShrink: 0
|
|
2742
3279
|
},
|
|
2743
3280
|
children: [
|
|
2744
|
-
/* @__PURE__ */
|
|
3281
|
+
/* @__PURE__ */ jsx3("svg", { width: "14", height: "14", viewBox: "0 0 24 24", fill: "none", "aria-hidden": "true", style: { flexShrink: 0 }, children: /* @__PURE__ */ jsx3(
|
|
2745
3282
|
"path",
|
|
2746
3283
|
{
|
|
2747
3284
|
d: "M14 2H6a2 2 0 00-2 2v16a2 2 0 002 2h12a2 2 0 002-2V8z M14 2v6h6",
|
|
@@ -2751,7 +3288,7 @@ function AssistSheet({
|
|
|
2751
3288
|
strokeLinejoin: "round"
|
|
2752
3289
|
}
|
|
2753
3290
|
) }),
|
|
2754
|
-
/* @__PURE__ */
|
|
3291
|
+
/* @__PURE__ */ jsx3(
|
|
2755
3292
|
"span",
|
|
2756
3293
|
{
|
|
2757
3294
|
style: {
|
|
@@ -2764,7 +3301,7 @@ function AssistSheet({
|
|
|
2764
3301
|
children: file.name
|
|
2765
3302
|
}
|
|
2766
3303
|
),
|
|
2767
|
-
onRemoveFile && /* @__PURE__ */
|
|
3304
|
+
onRemoveFile && /* @__PURE__ */ jsx3(
|
|
2768
3305
|
"button",
|
|
2769
3306
|
{
|
|
2770
3307
|
type: "button",
|
|
@@ -2772,6 +3309,7 @@ function AssistSheet({
|
|
|
2772
3309
|
"aria-label": `Remove file ${file.name}`,
|
|
2773
3310
|
title: "Remove this file",
|
|
2774
3311
|
onClick: () => {
|
|
3312
|
+
stopAutoFile("changed attachments");
|
|
2775
3313
|
logEvent("file_removed", read ? "read" : "not read");
|
|
2776
3314
|
onRemoveFile(i);
|
|
2777
3315
|
},
|
|
@@ -2790,7 +3328,7 @@ function AssistSheet({
|
|
|
2790
3328
|
justifyContent: "center",
|
|
2791
3329
|
borderRadius: "50%"
|
|
2792
3330
|
},
|
|
2793
|
-
children: /* @__PURE__ */
|
|
3331
|
+
children: /* @__PURE__ */ jsx3(
|
|
2794
3332
|
"span",
|
|
2795
3333
|
{
|
|
2796
3334
|
"aria-hidden": "true",
|
|
@@ -2806,7 +3344,7 @@ function AssistSheet({
|
|
|
2806
3344
|
alignItems: "center",
|
|
2807
3345
|
justifyContent: "center"
|
|
2808
3346
|
},
|
|
2809
|
-
children: /* @__PURE__ */
|
|
3347
|
+
children: /* @__PURE__ */ jsx3("svg", { width: "8", height: "8", viewBox: "0 0 10 10", fill: "none", children: /* @__PURE__ */ jsx3(
|
|
2810
3348
|
"path",
|
|
2811
3349
|
{
|
|
2812
3350
|
d: "M1 1L9 9M9 1L1 9",
|
|
@@ -2824,7 +3362,7 @@ function AssistSheet({
|
|
|
2824
3362
|
`file-${i}-${file.name}`
|
|
2825
3363
|
);
|
|
2826
3364
|
}),
|
|
2827
|
-
onAddFiles && /* @__PURE__ */
|
|
3365
|
+
onAddFiles && /* @__PURE__ */ jsxs3(
|
|
2828
3366
|
"label",
|
|
2829
3367
|
{
|
|
2830
3368
|
"data-gg-assist-attach": "",
|
|
@@ -2844,7 +3382,7 @@ function AssistSheet({
|
|
|
2844
3382
|
},
|
|
2845
3383
|
children: [
|
|
2846
3384
|
"+",
|
|
2847
|
-
/* @__PURE__ */
|
|
3385
|
+
/* @__PURE__ */ jsx3(
|
|
2848
3386
|
"input",
|
|
2849
3387
|
{
|
|
2850
3388
|
type: "file",
|
|
@@ -2854,6 +3392,7 @@ function AssistSheet({
|
|
|
2854
3392
|
var _a;
|
|
2855
3393
|
const picked = Array.from((_a = e.target.files) != null ? _a : []);
|
|
2856
3394
|
if (picked.length) {
|
|
3395
|
+
stopAutoFile("changed attachments");
|
|
2857
3396
|
const images = picked.filter((f) => f.type.startsWith("image/")).length;
|
|
2858
3397
|
if (images) logEvent("image_added", String(images));
|
|
2859
3398
|
if (picked.length > images) {
|
|
@@ -2869,7 +3408,7 @@ function AssistSheet({
|
|
|
2869
3408
|
]
|
|
2870
3409
|
}
|
|
2871
3410
|
),
|
|
2872
|
-
readShots.size < screenshots.length && /* @__PURE__ */
|
|
3411
|
+
readShots.size < screenshots.length && /* @__PURE__ */ jsxs3("span", { style: { color: t2.textMuted, fontSize: "11px" }, children: [
|
|
2873
3412
|
readShots.size,
|
|
2874
3413
|
" of ",
|
|
2875
3414
|
screenshots.length,
|
|
@@ -2878,16 +3417,19 @@ function AssistSheet({
|
|
|
2878
3417
|
]
|
|
2879
3418
|
}
|
|
2880
3419
|
),
|
|
2881
|
-
/* @__PURE__ */
|
|
2882
|
-
/* @__PURE__ */
|
|
3420
|
+
/* @__PURE__ */ jsxs3("div", { style: { display: "flex", gap: "8px", alignItems: "flex-end" }, children: [
|
|
3421
|
+
/* @__PURE__ */ jsx3(
|
|
2883
3422
|
"textarea",
|
|
2884
3423
|
{
|
|
2885
3424
|
value: input,
|
|
2886
|
-
onChange: (e) =>
|
|
3425
|
+
onChange: (e) => {
|
|
3426
|
+
stopAutoFile("typing a change");
|
|
3427
|
+
setInput(e.target.value);
|
|
3428
|
+
},
|
|
2887
3429
|
onKeyDown: (e) => {
|
|
2888
3430
|
if (e.key === "Enter" && !e.shiftKey) {
|
|
2889
3431
|
e.preventDefault();
|
|
2890
|
-
|
|
3432
|
+
sendTyped(input);
|
|
2891
3433
|
}
|
|
2892
3434
|
},
|
|
2893
3435
|
placeholder: phase === "draft" ? "Anything to change? Tell me here\u2026" : "Type your answer\u2026",
|
|
@@ -2912,12 +3454,12 @@ function AssistSheet({
|
|
|
2912
3454
|
}
|
|
2913
3455
|
}
|
|
2914
3456
|
),
|
|
2915
|
-
/* @__PURE__ */
|
|
3457
|
+
/* @__PURE__ */ jsx3(
|
|
2916
3458
|
"button",
|
|
2917
3459
|
{
|
|
2918
3460
|
type: "button",
|
|
2919
3461
|
"data-gg-sheet-send": "",
|
|
2920
|
-
onClick: () =>
|
|
3462
|
+
onClick: () => sendTyped(input),
|
|
2921
3463
|
disabled: busy || !input.trim(),
|
|
2922
3464
|
"aria-label": "Send message",
|
|
2923
3465
|
"data-gg-send-message": "",
|
|
@@ -2934,7 +3476,7 @@ function AssistSheet({
|
|
|
2934
3476
|
color: busy || !input.trim() ? t2.textMuted : t2.accentText,
|
|
2935
3477
|
cursor: busy || !input.trim() ? "default" : "pointer"
|
|
2936
3478
|
},
|
|
2937
|
-
children: /* @__PURE__ */
|
|
3479
|
+
children: /* @__PURE__ */ jsx3("svg", { width: "17", height: "17", viewBox: "0 0 24 24", fill: "none", "aria-hidden": "true", children: /* @__PURE__ */ jsx3(
|
|
2938
3480
|
"path",
|
|
2939
3481
|
{
|
|
2940
3482
|
d: "M3 20.5L21.5 12 3 3.5V10l12 2-12 2v6.5z",
|
|
@@ -2944,8 +3486,8 @@ function AssistSheet({
|
|
|
2944
3486
|
}
|
|
2945
3487
|
)
|
|
2946
3488
|
] }),
|
|
2947
|
-
phase === "draft" && /* @__PURE__ */
|
|
2948
|
-
validationError && /* @__PURE__ */
|
|
3489
|
+
phase === "draft" && /* @__PURE__ */ jsxs3(Fragment2, { children: [
|
|
3490
|
+
validationError && /* @__PURE__ */ jsx3(
|
|
2949
3491
|
"p",
|
|
2950
3492
|
{
|
|
2951
3493
|
style: {
|
|
@@ -2956,12 +3498,95 @@ function AssistSheet({
|
|
|
2956
3498
|
children: validationError
|
|
2957
3499
|
}
|
|
2958
3500
|
),
|
|
2959
|
-
|
|
3501
|
+
autoFileLeft !== null ? (
|
|
3502
|
+
// #402: "Yes, that's it" was the confirmation. The draft
|
|
3503
|
+
// files itself unless they stop it — the bar shows how
|
|
3504
|
+
// long is left, the button sends now, the × on its right
|
|
3505
|
+
// stops it (#406). Stopping keeps the draft: Send Report
|
|
3506
|
+
// comes back, and closing the sheet drops it.
|
|
3507
|
+
/* @__PURE__ */ jsxs3("div", { style: { display: "flex", gap: "8px", marginTop: "8px" }, children: [
|
|
3508
|
+
/* @__PURE__ */ jsxs3(
|
|
3509
|
+
"button",
|
|
3510
|
+
{
|
|
3511
|
+
type: "button",
|
|
3512
|
+
"data-gg-sheet-send": "",
|
|
3513
|
+
"data-gg-auto-file": "",
|
|
3514
|
+
onClick: () => sendDraft(),
|
|
3515
|
+
style: {
|
|
3516
|
+
flex: 1,
|
|
3517
|
+
minWidth: 0,
|
|
3518
|
+
position: "relative",
|
|
3519
|
+
overflow: "hidden",
|
|
3520
|
+
padding: "12px",
|
|
3521
|
+
borderRadius: "10px",
|
|
3522
|
+
border: "none",
|
|
3523
|
+
backgroundColor: t2.accent,
|
|
3524
|
+
color: t2.accentText,
|
|
3525
|
+
fontSize: "14px",
|
|
3526
|
+
fontWeight: 700,
|
|
3527
|
+
fontFamily: "inherit",
|
|
3528
|
+
cursor: "pointer"
|
|
3529
|
+
},
|
|
3530
|
+
children: [
|
|
3531
|
+
/* @__PURE__ */ jsx3(
|
|
3532
|
+
"span",
|
|
3533
|
+
{
|
|
3534
|
+
"aria-hidden": "true",
|
|
3535
|
+
style: {
|
|
3536
|
+
position: "absolute",
|
|
3537
|
+
inset: 0,
|
|
3538
|
+
backgroundColor: "rgba(255,255,255,0.22)",
|
|
3539
|
+
transformOrigin: "left",
|
|
3540
|
+
animation: `gg-autofile ${AUTO_FILE_SECONDS}s linear forwards`
|
|
3541
|
+
}
|
|
3542
|
+
}
|
|
3543
|
+
),
|
|
3544
|
+
/* @__PURE__ */ jsxs3("span", { style: { position: "relative" }, children: [
|
|
3545
|
+
"Filing in ",
|
|
3546
|
+
autoFileLeft,
|
|
3547
|
+
"s\u2026"
|
|
3548
|
+
] })
|
|
3549
|
+
]
|
|
3550
|
+
}
|
|
3551
|
+
),
|
|
3552
|
+
/* @__PURE__ */ jsx3(
|
|
3553
|
+
"button",
|
|
3554
|
+
{
|
|
3555
|
+
type: "button",
|
|
3556
|
+
"data-gg-stop-auto-file": "",
|
|
3557
|
+
onClick: () => stopAutoFile("pressed stop"),
|
|
3558
|
+
"aria-label": "Stop \u2014 don't send",
|
|
3559
|
+
title: "Stop \u2014 don't send",
|
|
3560
|
+
style: {
|
|
3561
|
+
flexShrink: 0,
|
|
3562
|
+
width: "44px",
|
|
3563
|
+
borderRadius: "10px",
|
|
3564
|
+
border: `1px solid ${t2.inputBorder}`,
|
|
3565
|
+
background: "transparent",
|
|
3566
|
+
color: t2.text,
|
|
3567
|
+
display: "inline-flex",
|
|
3568
|
+
alignItems: "center",
|
|
3569
|
+
justifyContent: "center",
|
|
3570
|
+
cursor: "pointer"
|
|
3571
|
+
},
|
|
3572
|
+
children: /* @__PURE__ */ jsx3("svg", { width: "16", height: "16", viewBox: "0 0 24 24", fill: "none", "aria-hidden": "true", children: /* @__PURE__ */ jsx3(
|
|
3573
|
+
"path",
|
|
3574
|
+
{
|
|
3575
|
+
d: "M6 6l12 12M18 6L6 18",
|
|
3576
|
+
stroke: "currentColor",
|
|
3577
|
+
strokeWidth: "2.25",
|
|
3578
|
+
strokeLinecap: "round"
|
|
3579
|
+
}
|
|
3580
|
+
) })
|
|
3581
|
+
}
|
|
3582
|
+
)
|
|
3583
|
+
] })
|
|
3584
|
+
) : /* @__PURE__ */ jsx3(
|
|
2960
3585
|
"button",
|
|
2961
3586
|
{
|
|
2962
3587
|
type: "button",
|
|
2963
3588
|
"data-gg-sheet-send": "",
|
|
2964
|
-
onClick: sendDraft,
|
|
3589
|
+
onClick: () => sendDraft(),
|
|
2965
3590
|
disabled: isSubmitting || !description.trim(),
|
|
2966
3591
|
style: {
|
|
2967
3592
|
width: "100%",
|
|
@@ -2982,7 +3607,7 @@ function AssistSheet({
|
|
|
2982
3607
|
] })
|
|
2983
3608
|
] })
|
|
2984
3609
|
),
|
|
2985
|
-
phase === "chat" && messages.length > 0 && /* @__PURE__ */
|
|
3610
|
+
phase === "chat" && messages.length > 0 && /* @__PURE__ */ jsx3(
|
|
2986
3611
|
"button",
|
|
2987
3612
|
{
|
|
2988
3613
|
type: "button",
|
|
@@ -3002,7 +3627,7 @@ function AssistSheet({
|
|
|
3002
3627
|
children: "Not getting it? Fill the form yourself \u2192"
|
|
3003
3628
|
}
|
|
3004
3629
|
),
|
|
3005
|
-
onReportGlitchgrabProblem && phase !== "solved" && !glitchgrabOffer && /* @__PURE__ */
|
|
3630
|
+
onReportGlitchgrabProblem && phase !== "solved" && !glitchgrabOffer && /* @__PURE__ */ jsx3(
|
|
3006
3631
|
"button",
|
|
3007
3632
|
{
|
|
3008
3633
|
type: "button",
|
|
@@ -3165,7 +3790,7 @@ function GlitchgrabProblemPanel({
|
|
|
3165
3790
|
// `data-glitchgrab-layer` exempts this from the dialog's anti-focus-trap
|
|
3166
3791
|
// sweep, which sets `inert` on every other role="dialog" on the page —
|
|
3167
3792
|
// without it the panel renders but cannot be typed into.
|
|
3168
|
-
/* @__PURE__ */
|
|
3793
|
+
/* @__PURE__ */ jsx4(
|
|
3169
3794
|
"div",
|
|
3170
3795
|
{
|
|
3171
3796
|
"data-glitchgrab-layer": "",
|
|
@@ -3185,7 +3810,7 @@ function GlitchgrabProblemPanel({
|
|
|
3185
3810
|
boxSizing: "border-box",
|
|
3186
3811
|
fontFamily: FONT
|
|
3187
3812
|
},
|
|
3188
|
-
children: /* @__PURE__ */
|
|
3813
|
+
children: /* @__PURE__ */ jsx4(
|
|
3189
3814
|
"div",
|
|
3190
3815
|
{
|
|
3191
3816
|
style: {
|
|
@@ -3199,10 +3824,10 @@ function GlitchgrabProblemPanel({
|
|
|
3199
3824
|
boxShadow: "0 20px 50px rgba(0,0,0,0.5)",
|
|
3200
3825
|
padding: "18px"
|
|
3201
3826
|
},
|
|
3202
|
-
children: sent ? /* @__PURE__ */
|
|
3203
|
-
/* @__PURE__ */
|
|
3204
|
-
/* @__PURE__ */
|
|
3205
|
-
/* @__PURE__ */
|
|
3827
|
+
children: sent ? /* @__PURE__ */ jsxs4(Fragment3, { children: [
|
|
3828
|
+
/* @__PURE__ */ jsx4("div", { id: "gg-self-report-title", style: { fontSize: "15px", fontWeight: 600 }, children: "Sent to the Glitchgrab team" }),
|
|
3829
|
+
/* @__PURE__ */ jsx4("p", { style: { margin: "6px 0 16px", fontSize: "13px", lineHeight: 1.5, color: t2.textMuted }, children: "Thanks \u2014 we'll look into it. Your report is still open behind this, exactly as you left it." }),
|
|
3830
|
+
/* @__PURE__ */ jsx4(
|
|
3206
3831
|
"button",
|
|
3207
3832
|
{
|
|
3208
3833
|
type: "button",
|
|
@@ -3212,8 +3837,8 @@ function GlitchgrabProblemPanel({
|
|
|
3212
3837
|
children: "Back to your report"
|
|
3213
3838
|
}
|
|
3214
3839
|
)
|
|
3215
|
-
] }) : /* @__PURE__ */
|
|
3216
|
-
/* @__PURE__ */
|
|
3840
|
+
] }) : /* @__PURE__ */ jsxs4(Fragment3, { children: [
|
|
3841
|
+
/* @__PURE__ */ jsxs4(
|
|
3217
3842
|
"div",
|
|
3218
3843
|
{
|
|
3219
3844
|
style: {
|
|
@@ -3223,8 +3848,8 @@ function GlitchgrabProblemPanel({
|
|
|
3223
3848
|
gap: "12px"
|
|
3224
3849
|
},
|
|
3225
3850
|
children: [
|
|
3226
|
-
/* @__PURE__ */
|
|
3227
|
-
/* @__PURE__ */
|
|
3851
|
+
/* @__PURE__ */ jsx4("div", { id: "gg-self-report-title", style: { fontSize: "15px", fontWeight: 600 }, children: "Problem with Glitchgrab?" }),
|
|
3852
|
+
/* @__PURE__ */ jsx4(
|
|
3228
3853
|
"button",
|
|
3229
3854
|
{
|
|
3230
3855
|
type: "button",
|
|
@@ -3246,8 +3871,8 @@ function GlitchgrabProblemPanel({
|
|
|
3246
3871
|
]
|
|
3247
3872
|
}
|
|
3248
3873
|
),
|
|
3249
|
-
/* @__PURE__ */
|
|
3250
|
-
/* @__PURE__ */
|
|
3874
|
+
/* @__PURE__ */ jsx4("p", { style: { margin: "6px 0 12px", fontSize: "13px", lineHeight: 1.5, color: t2.textMuted }, children: "This goes to the people who build this reporter \u2014 not to this project's team. Tell us what went wrong: the AI chat, a button, anything." }),
|
|
3875
|
+
/* @__PURE__ */ jsx4(
|
|
3251
3876
|
"textarea",
|
|
3252
3877
|
{
|
|
3253
3878
|
ref: inputRef,
|
|
@@ -3281,7 +3906,7 @@ function GlitchgrabProblemPanel({
|
|
|
3281
3906
|
}
|
|
3282
3907
|
}
|
|
3283
3908
|
),
|
|
3284
|
-
/* @__PURE__ */
|
|
3909
|
+
/* @__PURE__ */ jsxs4(
|
|
3285
3910
|
"div",
|
|
3286
3911
|
{
|
|
3287
3912
|
"data-gg-self-report-images": "",
|
|
@@ -3293,8 +3918,8 @@ function GlitchgrabProblemPanel({
|
|
|
3293
3918
|
marginTop: "10px"
|
|
3294
3919
|
},
|
|
3295
3920
|
children: [
|
|
3296
|
-
images.map((src, i) => /* @__PURE__ */
|
|
3297
|
-
/* @__PURE__ */
|
|
3921
|
+
images.map((src, i) => /* @__PURE__ */ jsxs4("div", { style: { position: "relative", width: "48px", height: "48px" }, children: [
|
|
3922
|
+
/* @__PURE__ */ jsx4(
|
|
3298
3923
|
"img",
|
|
3299
3924
|
{
|
|
3300
3925
|
src,
|
|
@@ -3310,7 +3935,7 @@ function GlitchgrabProblemPanel({
|
|
|
3310
3935
|
}
|
|
3311
3936
|
}
|
|
3312
3937
|
),
|
|
3313
|
-
/* @__PURE__ */
|
|
3938
|
+
/* @__PURE__ */ jsx4(
|
|
3314
3939
|
"button",
|
|
3315
3940
|
{
|
|
3316
3941
|
type: "button",
|
|
@@ -3333,7 +3958,7 @@ function GlitchgrabProblemPanel({
|
|
|
3333
3958
|
justifyContent: "center",
|
|
3334
3959
|
borderRadius: "50%"
|
|
3335
3960
|
},
|
|
3336
|
-
children: /* @__PURE__ */
|
|
3961
|
+
children: /* @__PURE__ */ jsx4(
|
|
3337
3962
|
"span",
|
|
3338
3963
|
{
|
|
3339
3964
|
"aria-hidden": "true",
|
|
@@ -3349,7 +3974,7 @@ function GlitchgrabProblemPanel({
|
|
|
3349
3974
|
alignItems: "center",
|
|
3350
3975
|
justifyContent: "center"
|
|
3351
3976
|
},
|
|
3352
|
-
children: /* @__PURE__ */
|
|
3977
|
+
children: /* @__PURE__ */ jsx4("svg", { width: "8", height: "8", viewBox: "0 0 10 10", fill: "none", children: /* @__PURE__ */ jsx4(
|
|
3353
3978
|
"path",
|
|
3354
3979
|
{
|
|
3355
3980
|
d: "M1 1L9 9M9 1L1 9",
|
|
@@ -3363,7 +3988,7 @@ function GlitchgrabProblemPanel({
|
|
|
3363
3988
|
}
|
|
3364
3989
|
)
|
|
3365
3990
|
] }, i)),
|
|
3366
|
-
images.length < MAX_SELF_REPORT_IMAGES && /* @__PURE__ */
|
|
3991
|
+
images.length < MAX_SELF_REPORT_IMAGES && /* @__PURE__ */ jsx4(
|
|
3367
3992
|
"button",
|
|
3368
3993
|
{
|
|
3369
3994
|
type: "button",
|
|
@@ -3390,7 +4015,7 @@ function GlitchgrabProblemPanel({
|
|
|
3390
4015
|
children: images.length >= 3 ? "+ Add" : "+ Add screenshot"
|
|
3391
4016
|
}
|
|
3392
4017
|
),
|
|
3393
|
-
/* @__PURE__ */
|
|
4018
|
+
/* @__PURE__ */ jsx4(
|
|
3394
4019
|
"input",
|
|
3395
4020
|
{
|
|
3396
4021
|
ref: fileRef,
|
|
@@ -3409,7 +4034,7 @@ function GlitchgrabProblemPanel({
|
|
|
3409
4034
|
]
|
|
3410
4035
|
}
|
|
3411
4036
|
),
|
|
3412
|
-
/* @__PURE__ */
|
|
4037
|
+
/* @__PURE__ */ jsxs4(
|
|
3413
4038
|
"p",
|
|
3414
4039
|
{
|
|
3415
4040
|
"data-gg-self-report-includes": "",
|
|
@@ -3422,10 +4047,10 @@ function GlitchgrabProblemPanel({
|
|
|
3422
4047
|
]
|
|
3423
4048
|
}
|
|
3424
4049
|
),
|
|
3425
|
-
error && /* @__PURE__ */
|
|
3426
|
-
/* @__PURE__ */
|
|
3427
|
-
/* @__PURE__ */
|
|
3428
|
-
/* @__PURE__ */
|
|
4050
|
+
error && /* @__PURE__ */ jsx4("p", { role: "alert", style: { margin: "8px 0 0", fontSize: "12px", color: "#ef4444" }, children: error }),
|
|
4051
|
+
/* @__PURE__ */ jsxs4("div", { style: { display: "flex", justifyContent: "flex-end", gap: "8px", marginTop: "14px" }, children: [
|
|
4052
|
+
/* @__PURE__ */ jsx4("button", { type: "button", onClick: onClose, style: secondaryButton, children: "Cancel" }),
|
|
4053
|
+
/* @__PURE__ */ jsx4(
|
|
3429
4054
|
"button",
|
|
3430
4055
|
{
|
|
3431
4056
|
type: "button",
|
|
@@ -3604,7 +4229,7 @@ var SHOT_WAIT_MS = 3e3;
|
|
|
3604
4229
|
var SIMILAR_WAIT_MS = 2500;
|
|
3605
4230
|
var MAX_SIMILAR_SHOWN = 3;
|
|
3606
4231
|
function ButtonSpinner() {
|
|
3607
|
-
return /* @__PURE__ */
|
|
4232
|
+
return /* @__PURE__ */ jsx5(
|
|
3608
4233
|
"span",
|
|
3609
4234
|
{
|
|
3610
4235
|
"aria-hidden": "true",
|
|
@@ -3756,13 +4381,13 @@ function ReporterChip({
|
|
|
3756
4381
|
const label = isAnonymous ? "Anonymous" : name;
|
|
3757
4382
|
const title = isAnonymous ? "No reporter identity was passed to Glitchgrab \u2014 this report won't be attributed to anyone" : [name, reporter == null ? void 0 : reporter.email, reporter == null ? void 0 : reporter.role].filter(Boolean).join(" \xB7 ");
|
|
3758
4383
|
const showAvatarImage = !!avatarUrl && !avatarFailed;
|
|
3759
|
-
return /* @__PURE__ */
|
|
4384
|
+
return /* @__PURE__ */ jsxs5(
|
|
3760
4385
|
"span",
|
|
3761
4386
|
{
|
|
3762
4387
|
title,
|
|
3763
4388
|
style: { display: "flex", alignItems: "center", gap: "6px", minWidth: 0 },
|
|
3764
4389
|
children: [
|
|
3765
|
-
/* @__PURE__ */
|
|
4390
|
+
/* @__PURE__ */ jsx5(
|
|
3766
4391
|
"span",
|
|
3767
4392
|
{
|
|
3768
4393
|
"aria-hidden": "true",
|
|
@@ -3782,7 +4407,7 @@ function ReporterChip({
|
|
|
3782
4407
|
color: isAnonymous ? t2.textMuted : t2.accentText,
|
|
3783
4408
|
border: `1px solid ${isAnonymous ? t2.inputBorder : "transparent"}`
|
|
3784
4409
|
},
|
|
3785
|
-
children: showAvatarImage ? /* @__PURE__ */
|
|
4410
|
+
children: showAvatarImage ? /* @__PURE__ */ jsx5(
|
|
3786
4411
|
"img",
|
|
3787
4412
|
{
|
|
3788
4413
|
src: avatarUrl,
|
|
@@ -3792,9 +4417,9 @@ function ReporterChip({
|
|
|
3792
4417
|
onError: () => setAvatarFailed(true),
|
|
3793
4418
|
style: { width: "100%", height: "100%", objectFit: "cover" }
|
|
3794
4419
|
}
|
|
3795
|
-
) : initials ? initials : /* @__PURE__ */
|
|
3796
|
-
/* @__PURE__ */
|
|
3797
|
-
/* @__PURE__ */
|
|
4420
|
+
) : initials ? initials : /* @__PURE__ */ jsxs5("svg", { width: "10", height: "10", viewBox: "0 0 16 16", fill: "none", children: [
|
|
4421
|
+
/* @__PURE__ */ jsx5("circle", { cx: "8", cy: "5.5", r: "2.75", stroke: "currentColor", strokeWidth: "1.4" }),
|
|
4422
|
+
/* @__PURE__ */ jsx5(
|
|
3798
4423
|
"path",
|
|
3799
4424
|
{
|
|
3800
4425
|
d: "M2.75 13.5c0-2.35 2.35-3.75 5.25-3.75s5.25 1.4 5.25 3.75",
|
|
@@ -3806,7 +4431,7 @@ function ReporterChip({
|
|
|
3806
4431
|
] })
|
|
3807
4432
|
}
|
|
3808
4433
|
),
|
|
3809
|
-
/* @__PURE__ */
|
|
4434
|
+
/* @__PURE__ */ jsxs5(
|
|
3810
4435
|
"span",
|
|
3811
4436
|
{
|
|
3812
4437
|
style: {
|
|
@@ -3937,9 +4562,11 @@ function ReportDialog({
|
|
|
3937
4562
|
reporter,
|
|
3938
4563
|
onClose,
|
|
3939
4564
|
headerSlot,
|
|
3940
|
-
reportGlitchgrabProblem
|
|
4565
|
+
reportGlitchgrabProblem,
|
|
4566
|
+
layout = "modal"
|
|
3941
4567
|
}) {
|
|
3942
4568
|
var _a;
|
|
4569
|
+
const sheet = layout === "sheet";
|
|
3943
4570
|
const [isEnhancing, setIsEnhancing] = useState4(false);
|
|
3944
4571
|
const [assistOpen, setAssistOpen] = useState4(false);
|
|
3945
4572
|
const [assistNotice, setAssistNotice] = useState4(null);
|
|
@@ -4694,9 +5321,9 @@ function ReportDialog({
|
|
|
4694
5321
|
}
|
|
4695
5322
|
};
|
|
4696
5323
|
if (!mounted) return null;
|
|
4697
|
-
return /* @__PURE__ */
|
|
5324
|
+
return /* @__PURE__ */ jsxs5(Fragment4, { children: [
|
|
4698
5325
|
isOpen && createPortal3(
|
|
4699
|
-
/* @__PURE__ */
|
|
5326
|
+
/* @__PURE__ */ jsx5("style", { children: `
|
|
4700
5327
|
@keyframes gg-pulse{0%,100%{opacity:1}50%{opacity:0.35}}
|
|
4701
5328
|
@keyframes gg-spin{to{transform:rotate(360deg)}}
|
|
4702
5329
|
@keyframes gg-b1{0%,100%{height:3px}40%{height:13px}}
|
|
@@ -4734,7 +5361,7 @@ function ReportDialog({
|
|
|
4734
5361
|
document.body
|
|
4735
5362
|
),
|
|
4736
5363
|
isOpen && createPortal3(
|
|
4737
|
-
/* @__PURE__ */
|
|
5364
|
+
/* @__PURE__ */ jsx5(
|
|
4738
5365
|
"div",
|
|
4739
5366
|
{
|
|
4740
5367
|
"data-glitchgrab-layer": "",
|
|
@@ -4747,8 +5374,8 @@ function ReportDialog({
|
|
|
4747
5374
|
// dialog's state IS the report, and unmounting would drop the
|
|
4748
5375
|
// screenshots, attachments and step the reporter is on.
|
|
4749
5376
|
display: sheetUp ? "none" : "flex",
|
|
4750
|
-
alignItems: "center",
|
|
4751
|
-
justifyContent: "center",
|
|
5377
|
+
alignItems: sheet ? "stretch" : "center",
|
|
5378
|
+
justifyContent: sheet ? "flex-end" : "center",
|
|
4752
5379
|
backgroundColor: "rgba(0,0,0,0.5)",
|
|
4753
5380
|
fontFamily: '-apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif'
|
|
4754
5381
|
},
|
|
@@ -4757,7 +5384,7 @@ function ReportDialog({
|
|
|
4757
5384
|
},
|
|
4758
5385
|
onPointerDown: (e) => e.stopPropagation(),
|
|
4759
5386
|
onFocus: (e) => e.stopPropagation(),
|
|
4760
|
-
children: /* @__PURE__ */
|
|
5387
|
+
children: /* @__PURE__ */ jsxs5(
|
|
4761
5388
|
"div",
|
|
4762
5389
|
{
|
|
4763
5390
|
ref: modalRef,
|
|
@@ -4768,21 +5395,22 @@ function ReportDialog({
|
|
|
4768
5395
|
style: {
|
|
4769
5396
|
position: "relative",
|
|
4770
5397
|
zIndex: 2147483647,
|
|
4771
|
-
width: "420px",
|
|
4772
|
-
maxWidth: "calc(100% - 32px)",
|
|
4773
|
-
maxHeight: "calc(100dvh - 32px)",
|
|
5398
|
+
width: sheet ? "440px" : "420px",
|
|
5399
|
+
maxWidth: sheet ? "100%" : "calc(100% - 32px)",
|
|
5400
|
+
maxHeight: sheet ? "100dvh" : "calc(100dvh - 32px)",
|
|
5401
|
+
...sheet ? { height: "100dvh", borderLeft: `1px solid ${t2.inputBorder}` } : {},
|
|
4774
5402
|
display: "flex",
|
|
4775
5403
|
flexDirection: "column",
|
|
4776
5404
|
backgroundColor: t2.bg,
|
|
4777
|
-
borderRadius: "12px",
|
|
4778
|
-
boxShadow: "0 20px 60px rgba(0, 0, 0, 0.2), 0 4px 16px rgba(0, 0, 0, 0.1)",
|
|
5405
|
+
borderRadius: sheet ? 0 : "12px",
|
|
5406
|
+
boxShadow: sheet ? "0 20px 60px rgba(0, 0, 0, 0.35)" : "0 20px 60px rgba(0, 0, 0, 0.2), 0 4px 16px rgba(0, 0, 0, 0.1)",
|
|
4779
5407
|
fontFamily: '-apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif',
|
|
4780
5408
|
overflow: "hidden",
|
|
4781
5409
|
color: t2.text,
|
|
4782
5410
|
isolation: "isolate"
|
|
4783
5411
|
},
|
|
4784
5412
|
children: [
|
|
4785
|
-
/* @__PURE__ */
|
|
5413
|
+
/* @__PURE__ */ jsxs5(
|
|
4786
5414
|
"div",
|
|
4787
5415
|
{
|
|
4788
5416
|
style: {
|
|
@@ -4791,7 +5419,7 @@ function ReportDialog({
|
|
|
4791
5419
|
borderBottom: `1px solid ${t2.border}`
|
|
4792
5420
|
},
|
|
4793
5421
|
children: [
|
|
4794
|
-
/* @__PURE__ */
|
|
5422
|
+
/* @__PURE__ */ jsxs5(
|
|
4795
5423
|
"div",
|
|
4796
5424
|
{
|
|
4797
5425
|
style: {
|
|
@@ -4800,7 +5428,7 @@ function ReportDialog({
|
|
|
4800
5428
|
alignItems: "center"
|
|
4801
5429
|
},
|
|
4802
5430
|
children: [
|
|
4803
|
-
/* @__PURE__ */
|
|
5431
|
+
/* @__PURE__ */ jsxs5(
|
|
4804
5432
|
"div",
|
|
4805
5433
|
{
|
|
4806
5434
|
style: {
|
|
@@ -4809,7 +5437,7 @@ function ReportDialog({
|
|
|
4809
5437
|
gap: "8px"
|
|
4810
5438
|
},
|
|
4811
5439
|
children: [
|
|
4812
|
-
step > 1 && /* @__PURE__ */
|
|
5440
|
+
step > 1 && availableTypes.length > 1 && /* @__PURE__ */ jsx5(
|
|
4813
5441
|
"button",
|
|
4814
5442
|
{
|
|
4815
5443
|
type: "button",
|
|
@@ -4823,14 +5451,14 @@ function ReportDialog({
|
|
|
4823
5451
|
alignItems: "center"
|
|
4824
5452
|
},
|
|
4825
5453
|
"aria-label": "Back",
|
|
4826
|
-
children: /* @__PURE__ */
|
|
5454
|
+
children: /* @__PURE__ */ jsx5(
|
|
4827
5455
|
"svg",
|
|
4828
5456
|
{
|
|
4829
5457
|
width: "16",
|
|
4830
5458
|
height: "16",
|
|
4831
5459
|
viewBox: "0 0 16 16",
|
|
4832
5460
|
fill: "none",
|
|
4833
|
-
children: /* @__PURE__ */
|
|
5461
|
+
children: /* @__PURE__ */ jsx5(
|
|
4834
5462
|
"path",
|
|
4835
5463
|
{
|
|
4836
5464
|
d: "M10 3L5 8L10 13",
|
|
@@ -4844,7 +5472,7 @@ function ReportDialog({
|
|
|
4844
5472
|
)
|
|
4845
5473
|
}
|
|
4846
5474
|
),
|
|
4847
|
-
/* @__PURE__ */
|
|
5475
|
+
/* @__PURE__ */ jsx5(
|
|
4848
5476
|
"span",
|
|
4849
5477
|
{
|
|
4850
5478
|
style: {
|
|
@@ -4858,7 +5486,7 @@ function ReportDialog({
|
|
|
4858
5486
|
]
|
|
4859
5487
|
}
|
|
4860
5488
|
),
|
|
4861
|
-
/* @__PURE__ */
|
|
5489
|
+
/* @__PURE__ */ jsxs5(
|
|
4862
5490
|
"div",
|
|
4863
5491
|
{
|
|
4864
5492
|
style: {
|
|
@@ -4867,7 +5495,7 @@ function ReportDialog({
|
|
|
4867
5495
|
gap: "8px"
|
|
4868
5496
|
},
|
|
4869
5497
|
children: [
|
|
4870
|
-
step === 1 && /* @__PURE__ */
|
|
5498
|
+
step === 1 && /* @__PURE__ */ jsx5(
|
|
4871
5499
|
"span",
|
|
4872
5500
|
{
|
|
4873
5501
|
title: "Press this anywhere to open Glitchgrab",
|
|
@@ -4885,7 +5513,7 @@ function ReportDialog({
|
|
|
4885
5513
|
children: getShortcutLabel()
|
|
4886
5514
|
}
|
|
4887
5515
|
),
|
|
4888
|
-
/* @__PURE__ */
|
|
5516
|
+
/* @__PURE__ */ jsx5(
|
|
4889
5517
|
"button",
|
|
4890
5518
|
{
|
|
4891
5519
|
type: "button",
|
|
@@ -4900,7 +5528,7 @@ function ReportDialog({
|
|
|
4900
5528
|
justifyContent: "center"
|
|
4901
5529
|
},
|
|
4902
5530
|
"aria-label": "Close",
|
|
4903
|
-
children: /* @__PURE__ */
|
|
5531
|
+
children: /* @__PURE__ */ jsx5(
|
|
4904
5532
|
"svg",
|
|
4905
5533
|
{
|
|
4906
5534
|
width: "16",
|
|
@@ -4908,7 +5536,7 @@ function ReportDialog({
|
|
|
4908
5536
|
viewBox: "0 0 16 16",
|
|
4909
5537
|
fill: "none",
|
|
4910
5538
|
style: { display: "block" },
|
|
4911
|
-
children: /* @__PURE__ */
|
|
5539
|
+
children: /* @__PURE__ */ jsx5(
|
|
4912
5540
|
"path",
|
|
4913
5541
|
{
|
|
4914
5542
|
d: "M4 4L12 12M12 4L4 12",
|
|
@@ -4927,7 +5555,7 @@ function ReportDialog({
|
|
|
4927
5555
|
]
|
|
4928
5556
|
}
|
|
4929
5557
|
),
|
|
4930
|
-
/* @__PURE__ */
|
|
5558
|
+
availableTypes.length > 1 && /* @__PURE__ */ jsx5(
|
|
4931
5559
|
"div",
|
|
4932
5560
|
{
|
|
4933
5561
|
style: {
|
|
@@ -4937,12 +5565,12 @@ function ReportDialog({
|
|
|
4937
5565
|
gap: "0",
|
|
4938
5566
|
marginTop: "12px"
|
|
4939
5567
|
},
|
|
4940
|
-
children: [1, 2].map((s, i) => /* @__PURE__ */
|
|
5568
|
+
children: [1, 2].map((s, i) => /* @__PURE__ */ jsxs5(
|
|
4941
5569
|
"div",
|
|
4942
5570
|
{
|
|
4943
5571
|
style: { display: "flex", alignItems: "center" },
|
|
4944
5572
|
children: [
|
|
4945
|
-
/* @__PURE__ */
|
|
5573
|
+
/* @__PURE__ */ jsx5(
|
|
4946
5574
|
"div",
|
|
4947
5575
|
{
|
|
4948
5576
|
style: {
|
|
@@ -4954,7 +5582,7 @@ function ReportDialog({
|
|
|
4954
5582
|
}
|
|
4955
5583
|
}
|
|
4956
5584
|
),
|
|
4957
|
-
i < 1 && /* @__PURE__ */
|
|
5585
|
+
i < 1 && /* @__PURE__ */ jsx5(
|
|
4958
5586
|
"div",
|
|
4959
5587
|
{
|
|
4960
5588
|
style: {
|
|
@@ -4974,7 +5602,7 @@ function ReportDialog({
|
|
|
4974
5602
|
]
|
|
4975
5603
|
}
|
|
4976
5604
|
),
|
|
4977
|
-
/* @__PURE__ */
|
|
5605
|
+
/* @__PURE__ */ jsx5(
|
|
4978
5606
|
"div",
|
|
4979
5607
|
{
|
|
4980
5608
|
style: {
|
|
@@ -4983,7 +5611,7 @@ function ReportDialog({
|
|
|
4983
5611
|
flex: "1 1 auto",
|
|
4984
5612
|
minHeight: 0
|
|
4985
5613
|
},
|
|
4986
|
-
children: submitted ? /* @__PURE__ */
|
|
5614
|
+
children: submitted ? /* @__PURE__ */ jsx5(
|
|
4987
5615
|
"div",
|
|
4988
5616
|
{
|
|
4989
5617
|
style: {
|
|
@@ -4993,7 +5621,7 @@ function ReportDialog({
|
|
|
4993
5621
|
fontSize: "14px",
|
|
4994
5622
|
fontWeight: 500
|
|
4995
5623
|
},
|
|
4996
|
-
children: queuedMessage ? /* @__PURE__ */
|
|
5624
|
+
children: queuedMessage ? /* @__PURE__ */ jsx5(
|
|
4997
5625
|
"span",
|
|
4998
5626
|
{
|
|
4999
5627
|
style: {
|
|
@@ -5006,9 +5634,9 @@ function ReportDialog({
|
|
|
5006
5634
|
}
|
|
5007
5635
|
) : addedToIssue ? `Added to #${addedToIssue}${addedAsRelated ? " as a related request" : ""}. Thank you!` : `${getTypeLabel(reportType)} sent. Thank you!`
|
|
5008
5636
|
}
|
|
5009
|
-
) : /* @__PURE__ */
|
|
5010
|
-
step === 1 && headerSlot ? /* @__PURE__ */
|
|
5011
|
-
step === 1 && sendFeedback2 && /* @__PURE__ */
|
|
5637
|
+
) : /* @__PURE__ */ jsxs5(Fragment4, { children: [
|
|
5638
|
+
step === 1 && headerSlot ? /* @__PURE__ */ jsx5("div", { style: { marginBottom: "14px" }, children: headerSlot }) : null,
|
|
5639
|
+
step === 1 && sendFeedback2 && /* @__PURE__ */ jsxs5(
|
|
5012
5640
|
"div",
|
|
5013
5641
|
{
|
|
5014
5642
|
style: {
|
|
@@ -5025,16 +5653,16 @@ function ReportDialog({
|
|
|
5025
5653
|
},
|
|
5026
5654
|
onMouseLeave: () => setHoveredStar(0),
|
|
5027
5655
|
children: [
|
|
5028
|
-
/* @__PURE__ */
|
|
5656
|
+
/* @__PURE__ */ jsx5(
|
|
5029
5657
|
"span",
|
|
5030
5658
|
{
|
|
5031
5659
|
style: { fontSize: "13px", fontWeight: 600, color: t2.text },
|
|
5032
5660
|
children: "How are we doing?"
|
|
5033
5661
|
}
|
|
5034
5662
|
),
|
|
5035
|
-
/* @__PURE__ */
|
|
5663
|
+
/* @__PURE__ */ jsx5("span", { style: { display: "flex", gap: "4px" }, children: [1, 2, 3, 4, 5].map((star) => {
|
|
5036
5664
|
const filled = star <= (hoveredStar || rating);
|
|
5037
|
-
return /* @__PURE__ */
|
|
5665
|
+
return /* @__PURE__ */ jsx5(
|
|
5038
5666
|
"button",
|
|
5039
5667
|
{
|
|
5040
5668
|
type: "button",
|
|
@@ -5055,7 +5683,7 @@ function ReportDialog({
|
|
|
5055
5683
|
cursor: "pointer",
|
|
5056
5684
|
lineHeight: 0
|
|
5057
5685
|
},
|
|
5058
|
-
children: /* @__PURE__ */
|
|
5686
|
+
children: /* @__PURE__ */ jsx5("svg", { width: "26", height: "26", viewBox: "0 0 24 24", "aria-hidden": "true", children: /* @__PURE__ */ jsx5(
|
|
5059
5687
|
"path",
|
|
5060
5688
|
{
|
|
5061
5689
|
d: "M12 3l2.6 5.3 5.9.9-4.3 4.1 1 5.8L12 16.4 6.8 19.1l1-5.8L3.5 9.2l5.9-.9L12 3z",
|
|
@@ -5072,7 +5700,7 @@ function ReportDialog({
|
|
|
5072
5700
|
]
|
|
5073
5701
|
}
|
|
5074
5702
|
),
|
|
5075
|
-
step === 1 && sendFeedback2 && /* @__PURE__ */
|
|
5703
|
+
step === 1 && sendFeedback2 && /* @__PURE__ */ jsxs5(
|
|
5076
5704
|
"div",
|
|
5077
5705
|
{
|
|
5078
5706
|
style: {
|
|
@@ -5082,13 +5710,13 @@ function ReportDialog({
|
|
|
5082
5710
|
marginBottom: "16px"
|
|
5083
5711
|
},
|
|
5084
5712
|
children: [
|
|
5085
|
-
/* @__PURE__ */
|
|
5086
|
-
/* @__PURE__ */
|
|
5087
|
-
/* @__PURE__ */
|
|
5713
|
+
/* @__PURE__ */ jsx5("span", { style: { flex: 1, height: "1px", background: t2.border } }),
|
|
5714
|
+
/* @__PURE__ */ jsx5("span", { style: { fontSize: "11px", color: t2.textMuted }, children: "or report something" }),
|
|
5715
|
+
/* @__PURE__ */ jsx5("span", { style: { flex: 1, height: "1px", background: t2.border } })
|
|
5088
5716
|
]
|
|
5089
5717
|
}
|
|
5090
5718
|
),
|
|
5091
|
-
step === 1 && screenshots.length > 0 && /* @__PURE__ */
|
|
5719
|
+
step === 1 && screenshots.length > 0 && /* @__PURE__ */ jsxs5(
|
|
5092
5720
|
"div",
|
|
5093
5721
|
{
|
|
5094
5722
|
style: {
|
|
@@ -5102,7 +5730,7 @@ function ReportDialog({
|
|
|
5102
5730
|
background: t2.inputBg
|
|
5103
5731
|
},
|
|
5104
5732
|
children: [
|
|
5105
|
-
/* @__PURE__ */
|
|
5733
|
+
/* @__PURE__ */ jsx5(
|
|
5106
5734
|
"img",
|
|
5107
5735
|
{
|
|
5108
5736
|
src: screenshots[0],
|
|
@@ -5117,8 +5745,8 @@ function ReportDialog({
|
|
|
5117
5745
|
}
|
|
5118
5746
|
}
|
|
5119
5747
|
),
|
|
5120
|
-
/* @__PURE__ */
|
|
5121
|
-
/* @__PURE__ */
|
|
5748
|
+
/* @__PURE__ */ jsx5("span", { style: { fontSize: "11px", color: t2.textMuted, flex: 1 }, children: "Screenshot attached" }),
|
|
5749
|
+
/* @__PURE__ */ jsx5(
|
|
5122
5750
|
"button",
|
|
5123
5751
|
{
|
|
5124
5752
|
type: "button",
|
|
@@ -5139,7 +5767,7 @@ function ReportDialog({
|
|
|
5139
5767
|
]
|
|
5140
5768
|
}
|
|
5141
5769
|
),
|
|
5142
|
-
step === 1 && /* @__PURE__ */
|
|
5770
|
+
step === 1 && /* @__PURE__ */ jsx5(
|
|
5143
5771
|
"div",
|
|
5144
5772
|
{
|
|
5145
5773
|
ref: tileGridRef,
|
|
@@ -5149,7 +5777,7 @@ function ReportDialog({
|
|
|
5149
5777
|
gridTemplateColumns: "1fr 1fr 1fr",
|
|
5150
5778
|
gap: "10px"
|
|
5151
5779
|
},
|
|
5152
|
-
children: availableTypes.map((type) => /* @__PURE__ */
|
|
5780
|
+
children: availableTypes.map((type) => /* @__PURE__ */ jsxs5(
|
|
5153
5781
|
"button",
|
|
5154
5782
|
{
|
|
5155
5783
|
type: "button",
|
|
@@ -5180,7 +5808,7 @@ function ReportDialog({
|
|
|
5180
5808
|
},
|
|
5181
5809
|
children: [
|
|
5182
5810
|
getTypeIcon(type, t2.accent, 22),
|
|
5183
|
-
/* @__PURE__ */
|
|
5811
|
+
/* @__PURE__ */ jsx5(
|
|
5184
5812
|
"span",
|
|
5185
5813
|
{
|
|
5186
5814
|
style: {
|
|
@@ -5198,11 +5826,12 @@ function ReportDialog({
|
|
|
5198
5826
|
))
|
|
5199
5827
|
}
|
|
5200
5828
|
),
|
|
5201
|
-
step === 2 && /* @__PURE__ */
|
|
5202
|
-
/* @__PURE__ */
|
|
5829
|
+
step === 2 && /* @__PURE__ */ jsxs5(Fragment4, { children: [
|
|
5830
|
+
/* @__PURE__ */ jsxs5(
|
|
5203
5831
|
"button",
|
|
5204
5832
|
{
|
|
5205
5833
|
type: "button",
|
|
5834
|
+
disabled: availableTypes.length === 1,
|
|
5206
5835
|
onClick: () => setStep(1),
|
|
5207
5836
|
style: {
|
|
5208
5837
|
display: "inline-flex",
|
|
@@ -5217,16 +5846,16 @@ function ReportDialog({
|
|
|
5217
5846
|
fontSize: "11px",
|
|
5218
5847
|
fontWeight: 600,
|
|
5219
5848
|
fontFamily: "inherit",
|
|
5220
|
-
cursor: "pointer"
|
|
5849
|
+
cursor: availableTypes.length === 1 ? "default" : "pointer"
|
|
5221
5850
|
},
|
|
5222
5851
|
children: [
|
|
5223
5852
|
getTypeIcon(reportType, isRating ? "#f59e0b" : t2.accent, 13),
|
|
5224
5853
|
getTypeLabel(reportType),
|
|
5225
|
-
/* @__PURE__ */
|
|
5854
|
+
availableTypes.length > 1 && /* @__PURE__ */ jsx5("span", { style: { color: t2.textMuted, fontWeight: 400 }, children: "\xB7 change" })
|
|
5226
5855
|
]
|
|
5227
5856
|
}
|
|
5228
5857
|
),
|
|
5229
|
-
isRating && /* @__PURE__ */
|
|
5858
|
+
isRating && /* @__PURE__ */ jsx5(
|
|
5230
5859
|
"div",
|
|
5231
5860
|
{
|
|
5232
5861
|
style: {
|
|
@@ -5237,7 +5866,7 @@ function ReportDialog({
|
|
|
5237
5866
|
onMouseLeave: () => setHoveredStar(0),
|
|
5238
5867
|
children: [1, 2, 3, 4, 5].map((star) => {
|
|
5239
5868
|
const filled = star <= (hoveredStar || rating);
|
|
5240
|
-
return /* @__PURE__ */
|
|
5869
|
+
return /* @__PURE__ */ jsx5(
|
|
5241
5870
|
"button",
|
|
5242
5871
|
{
|
|
5243
5872
|
type: "button",
|
|
@@ -5254,7 +5883,7 @@ function ReportDialog({
|
|
|
5254
5883
|
cursor: "pointer",
|
|
5255
5884
|
lineHeight: 0
|
|
5256
5885
|
},
|
|
5257
|
-
children: /* @__PURE__ */
|
|
5886
|
+
children: /* @__PURE__ */ jsx5("svg", { width: "30", height: "30", viewBox: "0 0 24 24", "aria-hidden": "true", children: /* @__PURE__ */ jsx5(
|
|
5258
5887
|
"path",
|
|
5259
5888
|
{
|
|
5260
5889
|
d: "M12 3l2.6 5.3 5.9.9-4.3 4.1 1 5.8L12 16.4 6.8 19.1l1-5.8L3.5 9.2l5.9-.9L12 3z",
|
|
@@ -5270,7 +5899,7 @@ function ReportDialog({
|
|
|
5270
5899
|
})
|
|
5271
5900
|
}
|
|
5272
5901
|
),
|
|
5273
|
-
assist && !isRating && !assistUsed && /* @__PURE__ */
|
|
5902
|
+
assist && !isRating && !assistUsed && /* @__PURE__ */ jsxs5(
|
|
5274
5903
|
"button",
|
|
5275
5904
|
{
|
|
5276
5905
|
type: "button",
|
|
@@ -5297,7 +5926,7 @@ function ReportDialog({
|
|
|
5297
5926
|
},
|
|
5298
5927
|
title: "Answer a question or two and the assistant writes the report for you",
|
|
5299
5928
|
children: [
|
|
5300
|
-
/* @__PURE__ */
|
|
5929
|
+
/* @__PURE__ */ jsx5("svg", { width: "12", height: "12", viewBox: "0 0 24 24", fill: "none", "aria-hidden": "true", children: /* @__PURE__ */ jsx5(
|
|
5301
5930
|
"path",
|
|
5302
5931
|
{
|
|
5303
5932
|
d: "M12 3l1.5 4.5L18 9l-4.5 1.5L12 15l-1.5-4.5L6 9l4.5-1.5L12 3zM19 15l.75 2.25L22 18l-2.25.75L19 21l-.75-2.25L16 18l2.25-.75L19 15z",
|
|
@@ -5310,8 +5939,8 @@ function ReportDialog({
|
|
|
5310
5939
|
]
|
|
5311
5940
|
}
|
|
5312
5941
|
),
|
|
5313
|
-
/* @__PURE__ */
|
|
5314
|
-
/* @__PURE__ */
|
|
5942
|
+
/* @__PURE__ */ jsxs5("div", { style: { position: "relative" }, children: [
|
|
5943
|
+
/* @__PURE__ */ jsx5(
|
|
5315
5944
|
"textarea",
|
|
5316
5945
|
{
|
|
5317
5946
|
ref: textareaRef,
|
|
@@ -5353,7 +5982,7 @@ function ReportDialog({
|
|
|
5353
5982
|
autoFocus: true
|
|
5354
5983
|
}
|
|
5355
5984
|
),
|
|
5356
|
-
(isListening || isTranscribing) && /* @__PURE__ */
|
|
5985
|
+
(isListening || isTranscribing) && /* @__PURE__ */ jsxs5(
|
|
5357
5986
|
"span",
|
|
5358
5987
|
{
|
|
5359
5988
|
style: {
|
|
@@ -5371,7 +6000,7 @@ function ReportDialog({
|
|
|
5371
6000
|
zIndex: 1
|
|
5372
6001
|
},
|
|
5373
6002
|
children: [
|
|
5374
|
-
/* @__PURE__ */
|
|
6003
|
+
/* @__PURE__ */ jsx5(
|
|
5375
6004
|
"span",
|
|
5376
6005
|
{
|
|
5377
6006
|
style: {
|
|
@@ -5386,7 +6015,7 @@ function ReportDialog({
|
|
|
5386
6015
|
}
|
|
5387
6016
|
),
|
|
5388
6017
|
isTranscribing ? "Transcribing\u2026" : "REC",
|
|
5389
|
-
isListening && !isTranscribing && /* @__PURE__ */
|
|
6018
|
+
isListening && !isTranscribing && /* @__PURE__ */ jsx5(
|
|
5390
6019
|
"span",
|
|
5391
6020
|
{
|
|
5392
6021
|
style: {
|
|
@@ -5413,7 +6042,7 @@ function ReportDialog({
|
|
|
5413
6042
|
dur: "0.55s",
|
|
5414
6043
|
delay: "0.15s"
|
|
5415
6044
|
}
|
|
5416
|
-
].map((b, i) => /* @__PURE__ */
|
|
6045
|
+
].map((b, i) => /* @__PURE__ */ jsx5(
|
|
5417
6046
|
"span",
|
|
5418
6047
|
{
|
|
5419
6048
|
style: {
|
|
@@ -5433,7 +6062,7 @@ function ReportDialog({
|
|
|
5433
6062
|
]
|
|
5434
6063
|
}
|
|
5435
6064
|
),
|
|
5436
|
-
enhanceText2 && /* @__PURE__ */
|
|
6065
|
+
enhanceText2 && /* @__PURE__ */ jsxs5(
|
|
5437
6066
|
"button",
|
|
5438
6067
|
{
|
|
5439
6068
|
type: "button",
|
|
@@ -5478,7 +6107,7 @@ function ReportDialog({
|
|
|
5478
6107
|
},
|
|
5479
6108
|
title: "Polish grammar \u2014 preserves your meaning",
|
|
5480
6109
|
children: [
|
|
5481
|
-
/* @__PURE__ */
|
|
6110
|
+
/* @__PURE__ */ jsx5(
|
|
5482
6111
|
"svg",
|
|
5483
6112
|
{
|
|
5484
6113
|
width: "11",
|
|
@@ -5486,7 +6115,7 @@ function ReportDialog({
|
|
|
5486
6115
|
viewBox: "0 0 24 24",
|
|
5487
6116
|
fill: "none",
|
|
5488
6117
|
"aria-hidden": "true",
|
|
5489
|
-
children: /* @__PURE__ */
|
|
6118
|
+
children: /* @__PURE__ */ jsx5(
|
|
5490
6119
|
"path",
|
|
5491
6120
|
{
|
|
5492
6121
|
d: "M12 3l1.5 4.5L18 9l-4.5 1.5L12 15l-1.5-4.5L6 9l4.5-1.5L12 3zM19 15l.75 2.25L22 18l-2.25.75L19 21l-.75-2.25L16 18l2.25-.75L19 15z",
|
|
@@ -5501,7 +6130,7 @@ function ReportDialog({
|
|
|
5501
6130
|
]
|
|
5502
6131
|
}
|
|
5503
6132
|
),
|
|
5504
|
-
transcribeAudio2 && /* @__PURE__ */
|
|
6133
|
+
transcribeAudio2 && /* @__PURE__ */ jsx5(
|
|
5505
6134
|
"button",
|
|
5506
6135
|
{
|
|
5507
6136
|
type: "button",
|
|
@@ -5527,7 +6156,7 @@ function ReportDialog({
|
|
|
5527
6156
|
padding: 0,
|
|
5528
6157
|
transition: "border-color 0.2s ease, color 0.2s ease"
|
|
5529
6158
|
},
|
|
5530
|
-
children: isListening ? /* @__PURE__ */
|
|
6159
|
+
children: isListening ? /* @__PURE__ */ jsx5(
|
|
5531
6160
|
"svg",
|
|
5532
6161
|
{
|
|
5533
6162
|
width: "12",
|
|
@@ -5535,7 +6164,7 @@ function ReportDialog({
|
|
|
5535
6164
|
viewBox: "0 0 24 24",
|
|
5536
6165
|
fill: "currentColor",
|
|
5537
6166
|
"aria-hidden": "true",
|
|
5538
|
-
children: /* @__PURE__ */
|
|
6167
|
+
children: /* @__PURE__ */ jsx5(
|
|
5539
6168
|
"rect",
|
|
5540
6169
|
{
|
|
5541
6170
|
x: "6",
|
|
@@ -5546,7 +6175,7 @@ function ReportDialog({
|
|
|
5546
6175
|
}
|
|
5547
6176
|
)
|
|
5548
6177
|
}
|
|
5549
|
-
) : /* @__PURE__ */
|
|
6178
|
+
) : /* @__PURE__ */ jsxs5(
|
|
5550
6179
|
"svg",
|
|
5551
6180
|
{
|
|
5552
6181
|
width: "13",
|
|
@@ -5555,7 +6184,7 @@ function ReportDialog({
|
|
|
5555
6184
|
fill: "none",
|
|
5556
6185
|
"aria-hidden": "true",
|
|
5557
6186
|
children: [
|
|
5558
|
-
/* @__PURE__ */
|
|
6187
|
+
/* @__PURE__ */ jsx5(
|
|
5559
6188
|
"rect",
|
|
5560
6189
|
{
|
|
5561
6190
|
x: "9",
|
|
@@ -5567,7 +6196,7 @@ function ReportDialog({
|
|
|
5567
6196
|
strokeWidth: "1.8"
|
|
5568
6197
|
}
|
|
5569
6198
|
),
|
|
5570
|
-
/* @__PURE__ */
|
|
6199
|
+
/* @__PURE__ */ jsx5(
|
|
5571
6200
|
"path",
|
|
5572
6201
|
{
|
|
5573
6202
|
d: "M5 10a7 7 0 0014 0M12 19v3M9 22h6",
|
|
@@ -5582,7 +6211,7 @@ function ReportDialog({
|
|
|
5582
6211
|
}
|
|
5583
6212
|
)
|
|
5584
6213
|
] }),
|
|
5585
|
-
transcribeAudio2 && !isListening && !isTranscribing && !voiceError && /* @__PURE__ */
|
|
6214
|
+
transcribeAudio2 && !isListening && !isTranscribing && !voiceError && /* @__PURE__ */ jsxs5(
|
|
5586
6215
|
"div",
|
|
5587
6216
|
{
|
|
5588
6217
|
style: {
|
|
@@ -5596,16 +6225,16 @@ function ReportDialog({
|
|
|
5596
6225
|
userSelect: "none"
|
|
5597
6226
|
},
|
|
5598
6227
|
children: [
|
|
5599
|
-
/* @__PURE__ */
|
|
5600
|
-
/* @__PURE__ */
|
|
5601
|
-
/* @__PURE__ */
|
|
5602
|
-
/* @__PURE__ */
|
|
6228
|
+
/* @__PURE__ */ jsxs5("svg", { width: "11", height: "11", viewBox: "0 0 24 24", fill: "none", stroke: "currentColor", strokeWidth: "2", strokeLinecap: "round", strokeLinejoin: "round", children: [
|
|
6229
|
+
/* @__PURE__ */ jsx5("path", { d: "M12 2a3 3 0 0 0-3 3v7a3 3 0 0 0 6 0V5a3 3 0 0 0-3-3Z" }),
|
|
6230
|
+
/* @__PURE__ */ jsx5("path", { d: "M19 10v2a7 7 0 0 1-14 0v-2" }),
|
|
6231
|
+
/* @__PURE__ */ jsx5("line", { x1: "12", x2: "12", y1: "19", y2: "22" })
|
|
5603
6232
|
] }),
|
|
5604
6233
|
"Hold Space to speak \u2014 we'll transcribe it"
|
|
5605
6234
|
]
|
|
5606
6235
|
}
|
|
5607
6236
|
),
|
|
5608
|
-
isEnhanced && originalDescription !== null && /* @__PURE__ */
|
|
6237
|
+
isEnhanced && originalDescription !== null && /* @__PURE__ */ jsxs5(
|
|
5609
6238
|
"div",
|
|
5610
6239
|
{
|
|
5611
6240
|
style: {
|
|
@@ -5619,7 +6248,7 @@ function ReportDialog({
|
|
|
5619
6248
|
border: `1px solid ${t2.accent}40`
|
|
5620
6249
|
},
|
|
5621
6250
|
children: [
|
|
5622
|
-
/* @__PURE__ */
|
|
6251
|
+
/* @__PURE__ */ jsx5(
|
|
5623
6252
|
"svg",
|
|
5624
6253
|
{
|
|
5625
6254
|
width: "12",
|
|
@@ -5627,7 +6256,7 @@ function ReportDialog({
|
|
|
5627
6256
|
viewBox: "0 0 24 24",
|
|
5628
6257
|
fill: "none",
|
|
5629
6258
|
style: { flexShrink: 0 },
|
|
5630
|
-
children: /* @__PURE__ */
|
|
6259
|
+
children: /* @__PURE__ */ jsx5(
|
|
5631
6260
|
"path",
|
|
5632
6261
|
{
|
|
5633
6262
|
d: "M12 3l1.5 4.5L18 9l-4.5 1.5L12 15l-1.5-4.5L6 9l4.5-1.5L12 3z",
|
|
@@ -5638,7 +6267,7 @@ function ReportDialog({
|
|
|
5638
6267
|
)
|
|
5639
6268
|
}
|
|
5640
6269
|
),
|
|
5641
|
-
/* @__PURE__ */
|
|
6270
|
+
/* @__PURE__ */ jsx5(
|
|
5642
6271
|
"span",
|
|
5643
6272
|
{
|
|
5644
6273
|
style: {
|
|
@@ -5649,7 +6278,7 @@ function ReportDialog({
|
|
|
5649
6278
|
children: "AI enhanced"
|
|
5650
6279
|
}
|
|
5651
6280
|
),
|
|
5652
|
-
/* @__PURE__ */
|
|
6281
|
+
/* @__PURE__ */ jsx5(
|
|
5653
6282
|
"button",
|
|
5654
6283
|
{
|
|
5655
6284
|
type: "button",
|
|
@@ -5671,7 +6300,7 @@ function ReportDialog({
|
|
|
5671
6300
|
children: "Keep"
|
|
5672
6301
|
}
|
|
5673
6302
|
),
|
|
5674
|
-
/* @__PURE__ */
|
|
6303
|
+
/* @__PURE__ */ jsx5(
|
|
5675
6304
|
"button",
|
|
5676
6305
|
{
|
|
5677
6306
|
type: "button",
|
|
@@ -5697,7 +6326,7 @@ function ReportDialog({
|
|
|
5697
6326
|
]
|
|
5698
6327
|
}
|
|
5699
6328
|
),
|
|
5700
|
-
voiceError && /* @__PURE__ */
|
|
6329
|
+
voiceError && /* @__PURE__ */ jsx5(
|
|
5701
6330
|
"p",
|
|
5702
6331
|
{
|
|
5703
6332
|
role: "alert",
|
|
@@ -5711,7 +6340,7 @@ function ReportDialog({
|
|
|
5711
6340
|
children: voiceError
|
|
5712
6341
|
}
|
|
5713
6342
|
),
|
|
5714
|
-
assistNotice && /* @__PURE__ */
|
|
6343
|
+
assistNotice && /* @__PURE__ */ jsx5(
|
|
5715
6344
|
"p",
|
|
5716
6345
|
{
|
|
5717
6346
|
style: {
|
|
@@ -5724,8 +6353,8 @@ function ReportDialog({
|
|
|
5724
6353
|
children: assistNotice
|
|
5725
6354
|
}
|
|
5726
6355
|
),
|
|
5727
|
-
!isRating && /* @__PURE__ */
|
|
5728
|
-
/* @__PURE__ */
|
|
6356
|
+
!isRating && /* @__PURE__ */ jsxs5("div", { style: { marginTop: "10px" }, children: [
|
|
6357
|
+
/* @__PURE__ */ jsxs5(
|
|
5729
6358
|
"span",
|
|
5730
6359
|
{
|
|
5731
6360
|
style: {
|
|
@@ -5741,7 +6370,7 @@ function ReportDialog({
|
|
|
5741
6370
|
]
|
|
5742
6371
|
}
|
|
5743
6372
|
),
|
|
5744
|
-
(screenshots.length > 0 || shotPending) && /* @__PURE__ */
|
|
6373
|
+
(screenshots.length > 0 || shotPending) && /* @__PURE__ */ jsxs5(
|
|
5745
6374
|
"div",
|
|
5746
6375
|
{
|
|
5747
6376
|
style: {
|
|
@@ -5751,7 +6380,7 @@ function ReportDialog({
|
|
|
5751
6380
|
marginBottom: "8px"
|
|
5752
6381
|
},
|
|
5753
6382
|
children: [
|
|
5754
|
-
shotPending && /* @__PURE__ */
|
|
6383
|
+
shotPending && /* @__PURE__ */ jsx5(
|
|
5755
6384
|
"div",
|
|
5756
6385
|
{
|
|
5757
6386
|
role: "status",
|
|
@@ -5776,7 +6405,7 @@ function ReportDialog({
|
|
|
5776
6405
|
children: "Capturing\u2026"
|
|
5777
6406
|
}
|
|
5778
6407
|
),
|
|
5779
|
-
screenshots.map((src, i) => /* @__PURE__ */
|
|
6408
|
+
screenshots.map((src, i) => /* @__PURE__ */ jsxs5(
|
|
5780
6409
|
"div",
|
|
5781
6410
|
{
|
|
5782
6411
|
style: {
|
|
@@ -5785,7 +6414,7 @@ function ReportDialog({
|
|
|
5785
6414
|
height: "56px"
|
|
5786
6415
|
},
|
|
5787
6416
|
children: [
|
|
5788
|
-
/* @__PURE__ */
|
|
6417
|
+
/* @__PURE__ */ jsx5(
|
|
5789
6418
|
"img",
|
|
5790
6419
|
{
|
|
5791
6420
|
src,
|
|
@@ -5803,7 +6432,7 @@ function ReportDialog({
|
|
|
5803
6432
|
}
|
|
5804
6433
|
}
|
|
5805
6434
|
),
|
|
5806
|
-
/* @__PURE__ */
|
|
6435
|
+
/* @__PURE__ */ jsx5(
|
|
5807
6436
|
"button",
|
|
5808
6437
|
{
|
|
5809
6438
|
type: "button",
|
|
@@ -5829,14 +6458,14 @@ function ReportDialog({
|
|
|
5829
6458
|
alignItems: "center",
|
|
5830
6459
|
justifyContent: "center"
|
|
5831
6460
|
},
|
|
5832
|
-
children: /* @__PURE__ */
|
|
6461
|
+
children: /* @__PURE__ */ jsx5(
|
|
5833
6462
|
"svg",
|
|
5834
6463
|
{
|
|
5835
6464
|
width: "8",
|
|
5836
6465
|
height: "8",
|
|
5837
6466
|
viewBox: "0 0 10 10",
|
|
5838
6467
|
fill: "none",
|
|
5839
|
-
children: /* @__PURE__ */
|
|
6468
|
+
children: /* @__PURE__ */ jsx5(
|
|
5840
6469
|
"path",
|
|
5841
6470
|
{
|
|
5842
6471
|
d: "M1 1L9 9M9 1L1 9",
|
|
@@ -5849,7 +6478,7 @@ function ReportDialog({
|
|
|
5849
6478
|
)
|
|
5850
6479
|
}
|
|
5851
6480
|
),
|
|
5852
|
-
/* @__PURE__ */
|
|
6481
|
+
/* @__PURE__ */ jsx5(
|
|
5853
6482
|
"button",
|
|
5854
6483
|
{
|
|
5855
6484
|
type: "button",
|
|
@@ -5874,14 +6503,14 @@ function ReportDialog({
|
|
|
5874
6503
|
justifyContent: "center",
|
|
5875
6504
|
boxShadow: "0 2px 8px rgba(0,0,0,0.45)"
|
|
5876
6505
|
},
|
|
5877
|
-
children: /* @__PURE__ */
|
|
6506
|
+
children: /* @__PURE__ */ jsx5(
|
|
5878
6507
|
"svg",
|
|
5879
6508
|
{
|
|
5880
6509
|
width: "12",
|
|
5881
6510
|
height: "12",
|
|
5882
6511
|
viewBox: "0 0 24 24",
|
|
5883
6512
|
fill: "none",
|
|
5884
|
-
children: /* @__PURE__ */
|
|
6513
|
+
children: /* @__PURE__ */ jsx5(
|
|
5885
6514
|
"path",
|
|
5886
6515
|
{
|
|
5887
6516
|
d: "M12 20h9M16.5 3.5a2.12 2.12 0 013 3L7 19l-4 1 1-4L16.5 3.5z",
|
|
@@ -5902,7 +6531,7 @@ function ReportDialog({
|
|
|
5902
6531
|
]
|
|
5903
6532
|
}
|
|
5904
6533
|
),
|
|
5905
|
-
attachments.length > 0 && /* @__PURE__ */
|
|
6534
|
+
attachments.length > 0 && /* @__PURE__ */ jsx5(
|
|
5906
6535
|
"div",
|
|
5907
6536
|
{
|
|
5908
6537
|
style: {
|
|
@@ -5911,7 +6540,7 @@ function ReportDialog({
|
|
|
5911
6540
|
gap: "6px",
|
|
5912
6541
|
marginBottom: "8px"
|
|
5913
6542
|
},
|
|
5914
|
-
children: attachments.map((a, i) => /* @__PURE__ */
|
|
6543
|
+
children: attachments.map((a, i) => /* @__PURE__ */ jsxs5(
|
|
5915
6544
|
"div",
|
|
5916
6545
|
{
|
|
5917
6546
|
style: {
|
|
@@ -5923,7 +6552,7 @@ function ReportDialog({
|
|
|
5923
6552
|
border: `1px solid ${t2.border}`
|
|
5924
6553
|
},
|
|
5925
6554
|
children: [
|
|
5926
|
-
/* @__PURE__ */
|
|
6555
|
+
/* @__PURE__ */ jsxs5(
|
|
5927
6556
|
"svg",
|
|
5928
6557
|
{
|
|
5929
6558
|
width: "14",
|
|
@@ -5932,7 +6561,7 @@ function ReportDialog({
|
|
|
5932
6561
|
fill: "none",
|
|
5933
6562
|
style: { flexShrink: 0, opacity: 0.6 },
|
|
5934
6563
|
children: [
|
|
5935
|
-
/* @__PURE__ */
|
|
6564
|
+
/* @__PURE__ */ jsx5(
|
|
5936
6565
|
"path",
|
|
5937
6566
|
{
|
|
5938
6567
|
d: "M14 2H6a2 2 0 00-2 2v16a2 2 0 002 2h12a2 2 0 002-2V8z",
|
|
@@ -5942,7 +6571,7 @@ function ReportDialog({
|
|
|
5942
6571
|
strokeLinejoin: "round"
|
|
5943
6572
|
}
|
|
5944
6573
|
),
|
|
5945
|
-
/* @__PURE__ */
|
|
6574
|
+
/* @__PURE__ */ jsx5(
|
|
5946
6575
|
"path",
|
|
5947
6576
|
{
|
|
5948
6577
|
d: "M14 2v6h6",
|
|
@@ -5955,7 +6584,7 @@ function ReportDialog({
|
|
|
5955
6584
|
]
|
|
5956
6585
|
}
|
|
5957
6586
|
),
|
|
5958
|
-
/* @__PURE__ */
|
|
6587
|
+
/* @__PURE__ */ jsx5(
|
|
5959
6588
|
"span",
|
|
5960
6589
|
{
|
|
5961
6590
|
style: {
|
|
@@ -5969,7 +6598,7 @@ function ReportDialog({
|
|
|
5969
6598
|
children: a.name
|
|
5970
6599
|
}
|
|
5971
6600
|
),
|
|
5972
|
-
/* @__PURE__ */
|
|
6601
|
+
/* @__PURE__ */ jsxs5(
|
|
5973
6602
|
"span",
|
|
5974
6603
|
{
|
|
5975
6604
|
style: { fontSize: "10px", color: t2.textMuted },
|
|
@@ -5979,7 +6608,7 @@ function ReportDialog({
|
|
|
5979
6608
|
]
|
|
5980
6609
|
}
|
|
5981
6610
|
),
|
|
5982
|
-
/* @__PURE__ */
|
|
6611
|
+
/* @__PURE__ */ jsx5(
|
|
5983
6612
|
"button",
|
|
5984
6613
|
{
|
|
5985
6614
|
type: "button",
|
|
@@ -6003,14 +6632,14 @@ function ReportDialog({
|
|
|
6003
6632
|
justifyContent: "center",
|
|
6004
6633
|
flexShrink: 0
|
|
6005
6634
|
},
|
|
6006
|
-
children: /* @__PURE__ */
|
|
6635
|
+
children: /* @__PURE__ */ jsx5(
|
|
6007
6636
|
"svg",
|
|
6008
6637
|
{
|
|
6009
6638
|
width: "8",
|
|
6010
6639
|
height: "8",
|
|
6011
6640
|
viewBox: "0 0 10 10",
|
|
6012
6641
|
fill: "none",
|
|
6013
|
-
children: /* @__PURE__ */
|
|
6642
|
+
children: /* @__PURE__ */ jsx5(
|
|
6014
6643
|
"path",
|
|
6015
6644
|
{
|
|
6016
6645
|
d: "M1 1L9 9M9 1L1 9",
|
|
@@ -6029,7 +6658,7 @@ function ReportDialog({
|
|
|
6029
6658
|
))
|
|
6030
6659
|
}
|
|
6031
6660
|
),
|
|
6032
|
-
/* @__PURE__ */
|
|
6661
|
+
/* @__PURE__ */ jsx5(
|
|
6033
6662
|
"div",
|
|
6034
6663
|
{
|
|
6035
6664
|
onClick: () => {
|
|
@@ -6055,7 +6684,7 @@ function ReportDialog({
|
|
|
6055
6684
|
background: screenshotDragOver ? isDark ? "rgba(34,211,238,0.06)" : "rgba(8,145,178,0.04)" : "transparent",
|
|
6056
6685
|
transition: "border-color 0.15s ease, background 0.15s ease"
|
|
6057
6686
|
},
|
|
6058
|
-
children: screenshots.length + attachments.length > 0 ? /* @__PURE__ */
|
|
6687
|
+
children: screenshots.length + attachments.length > 0 ? /* @__PURE__ */ jsx5(
|
|
6059
6688
|
"p",
|
|
6060
6689
|
{
|
|
6061
6690
|
style: {
|
|
@@ -6066,8 +6695,8 @@ function ReportDialog({
|
|
|
6066
6695
|
},
|
|
6067
6696
|
children: screenshotDragOver ? "Drop to attach" : "+ Add more \xB7 Drag & drop \xB7 Paste"
|
|
6068
6697
|
}
|
|
6069
|
-
) : /* @__PURE__ */
|
|
6070
|
-
/* @__PURE__ */
|
|
6698
|
+
) : /* @__PURE__ */ jsxs5(Fragment4, { children: [
|
|
6699
|
+
/* @__PURE__ */ jsxs5(
|
|
6071
6700
|
"svg",
|
|
6072
6701
|
{
|
|
6073
6702
|
width: "22",
|
|
@@ -6080,7 +6709,7 @@ function ReportDialog({
|
|
|
6080
6709
|
opacity: 0.45
|
|
6081
6710
|
},
|
|
6082
6711
|
children: [
|
|
6083
|
-
/* @__PURE__ */
|
|
6712
|
+
/* @__PURE__ */ jsx5(
|
|
6084
6713
|
"rect",
|
|
6085
6714
|
{
|
|
6086
6715
|
x: "3",
|
|
@@ -6092,7 +6721,7 @@ function ReportDialog({
|
|
|
6092
6721
|
strokeWidth: "1.5"
|
|
6093
6722
|
}
|
|
6094
6723
|
),
|
|
6095
|
-
/* @__PURE__ */
|
|
6724
|
+
/* @__PURE__ */ jsx5(
|
|
6096
6725
|
"circle",
|
|
6097
6726
|
{
|
|
6098
6727
|
cx: "8.5",
|
|
@@ -6102,7 +6731,7 @@ function ReportDialog({
|
|
|
6102
6731
|
strokeWidth: "1.5"
|
|
6103
6732
|
}
|
|
6104
6733
|
),
|
|
6105
|
-
/* @__PURE__ */
|
|
6734
|
+
/* @__PURE__ */ jsx5(
|
|
6106
6735
|
"path",
|
|
6107
6736
|
{
|
|
6108
6737
|
d: "M21 15l-5-5L5 21",
|
|
@@ -6115,7 +6744,7 @@ function ReportDialog({
|
|
|
6115
6744
|
]
|
|
6116
6745
|
}
|
|
6117
6746
|
),
|
|
6118
|
-
/* @__PURE__ */
|
|
6747
|
+
/* @__PURE__ */ jsx5(
|
|
6119
6748
|
"p",
|
|
6120
6749
|
{
|
|
6121
6750
|
style: {
|
|
@@ -6127,7 +6756,7 @@ function ReportDialog({
|
|
|
6127
6756
|
children: screenshotDragOver ? "Drop to attach" : "Add screenshots or files"
|
|
6128
6757
|
}
|
|
6129
6758
|
),
|
|
6130
|
-
/* @__PURE__ */
|
|
6759
|
+
/* @__PURE__ */ jsx5(
|
|
6131
6760
|
"p",
|
|
6132
6761
|
{
|
|
6133
6762
|
style: {
|
|
@@ -6142,8 +6771,8 @@ function ReportDialog({
|
|
|
6142
6771
|
}
|
|
6143
6772
|
)
|
|
6144
6773
|
] }),
|
|
6145
|
-
showSeverity && reportType === "BUG" && /* @__PURE__ */
|
|
6146
|
-
/* @__PURE__ */
|
|
6774
|
+
showSeverity && reportType === "BUG" && /* @__PURE__ */ jsxs5("div", { style: { marginTop: "10px" }, children: [
|
|
6775
|
+
/* @__PURE__ */ jsxs5(
|
|
6147
6776
|
"span",
|
|
6148
6777
|
{
|
|
6149
6778
|
style: {
|
|
@@ -6156,7 +6785,7 @@ function ReportDialog({
|
|
|
6156
6785
|
},
|
|
6157
6786
|
children: [
|
|
6158
6787
|
"How bad is it?",
|
|
6159
|
-
/* @__PURE__ */
|
|
6788
|
+
/* @__PURE__ */ jsx5(
|
|
6160
6789
|
"span",
|
|
6161
6790
|
{
|
|
6162
6791
|
style: {
|
|
@@ -6169,7 +6798,7 @@ function ReportDialog({
|
|
|
6169
6798
|
]
|
|
6170
6799
|
}
|
|
6171
6800
|
),
|
|
6172
|
-
/* @__PURE__ */
|
|
6801
|
+
/* @__PURE__ */ jsx5(
|
|
6173
6802
|
"div",
|
|
6174
6803
|
{
|
|
6175
6804
|
role: "radiogroup",
|
|
@@ -6177,7 +6806,7 @@ function ReportDialog({
|
|
|
6177
6806
|
style: { display: "flex", gap: "6px" },
|
|
6178
6807
|
children: SEVERITY_LEVELS.map((s) => {
|
|
6179
6808
|
const on = severity === s;
|
|
6180
|
-
return /* @__PURE__ */
|
|
6809
|
+
return /* @__PURE__ */ jsx5(
|
|
6181
6810
|
"button",
|
|
6182
6811
|
{
|
|
6183
6812
|
type: "button",
|
|
@@ -6218,7 +6847,7 @@ function ReportDialog({
|
|
|
6218
6847
|
}
|
|
6219
6848
|
)
|
|
6220
6849
|
] }),
|
|
6221
|
-
validationError && /* @__PURE__ */
|
|
6850
|
+
validationError && /* @__PURE__ */ jsx5(
|
|
6222
6851
|
"p",
|
|
6223
6852
|
{
|
|
6224
6853
|
style: {
|
|
@@ -6233,7 +6862,7 @@ function ReportDialog({
|
|
|
6233
6862
|
// Same visual language as the assistant's "Our team is
|
|
6234
6863
|
// already on this" card, so both routes to a duplicate
|
|
6235
6864
|
// read as one feature.
|
|
6236
|
-
/* @__PURE__ */
|
|
6865
|
+
/* @__PURE__ */ jsxs5(
|
|
6237
6866
|
"div",
|
|
6238
6867
|
{
|
|
6239
6868
|
"data-gg-similar": "",
|
|
@@ -6248,11 +6877,11 @@ function ReportDialog({
|
|
|
6248
6877
|
backgroundColor: "rgba(245,158,11,0.08)"
|
|
6249
6878
|
},
|
|
6250
6879
|
children: [
|
|
6251
|
-
/* @__PURE__ */
|
|
6252
|
-
/* @__PURE__ */
|
|
6253
|
-
/* @__PURE__ */
|
|
6880
|
+
/* @__PURE__ */ jsxs5("div", { style: { display: "flex", flexDirection: "column", gap: "2px" }, children: [
|
|
6881
|
+
/* @__PURE__ */ jsx5("span", { style: { color: t2.text, fontWeight: 600, fontSize: "13px" }, children: "Our team may already have this, or something close" }),
|
|
6882
|
+
/* @__PURE__ */ jsx5("span", { style: { color: t2.textMuted, fontSize: "12px", lineHeight: 1.5 }, children: similarIssues.length > 1 ? "Pick the one that matches. Same problem, or a different request for the same feature \u2014 it's added to that issue, so the team has it in one place." : "Same problem, or a different request for the same feature? Pick it \u2014 it's added to that issue, so the team has it in one place." })
|
|
6254
6883
|
] }),
|
|
6255
|
-
/* @__PURE__ */
|
|
6884
|
+
/* @__PURE__ */ jsx5(
|
|
6256
6885
|
"div",
|
|
6257
6886
|
{
|
|
6258
6887
|
role: "radiogroup",
|
|
@@ -6260,7 +6889,7 @@ function ReportDialog({
|
|
|
6260
6889
|
style: { display: "flex", flexDirection: "column", gap: "6px" },
|
|
6261
6890
|
children: similarIssues.map((issue) => {
|
|
6262
6891
|
const picked = pickedSimilar === issue.number;
|
|
6263
|
-
return /* @__PURE__ */
|
|
6892
|
+
return /* @__PURE__ */ jsxs5(
|
|
6264
6893
|
"button",
|
|
6265
6894
|
{
|
|
6266
6895
|
type: "button",
|
|
@@ -6285,7 +6914,7 @@ function ReportDialog({
|
|
|
6285
6914
|
fontFamily: "inherit"
|
|
6286
6915
|
},
|
|
6287
6916
|
children: [
|
|
6288
|
-
/* @__PURE__ */
|
|
6917
|
+
/* @__PURE__ */ jsx5(
|
|
6289
6918
|
"span",
|
|
6290
6919
|
{
|
|
6291
6920
|
"aria-hidden": "true",
|
|
@@ -6302,7 +6931,7 @@ function ReportDialog({
|
|
|
6302
6931
|
}
|
|
6303
6932
|
}
|
|
6304
6933
|
),
|
|
6305
|
-
/* @__PURE__ */
|
|
6934
|
+
/* @__PURE__ */ jsxs5(
|
|
6306
6935
|
"span",
|
|
6307
6936
|
{
|
|
6308
6937
|
style: {
|
|
@@ -6312,7 +6941,7 @@ function ReportDialog({
|
|
|
6312
6941
|
minWidth: 0
|
|
6313
6942
|
},
|
|
6314
6943
|
children: [
|
|
6315
|
-
/* @__PURE__ */
|
|
6944
|
+
/* @__PURE__ */ jsxs5(
|
|
6316
6945
|
"span",
|
|
6317
6946
|
{
|
|
6318
6947
|
title: issue.title,
|
|
@@ -6326,7 +6955,7 @@ function ReportDialog({
|
|
|
6326
6955
|
WebkitBoxOrient: "vertical"
|
|
6327
6956
|
},
|
|
6328
6957
|
children: [
|
|
6329
|
-
/* @__PURE__ */
|
|
6958
|
+
/* @__PURE__ */ jsxs5("span", { style: { color: t2.textMuted, fontWeight: 600 }, children: [
|
|
6330
6959
|
"#",
|
|
6331
6960
|
issue.number
|
|
6332
6961
|
] }),
|
|
@@ -6335,7 +6964,7 @@ function ReportDialog({
|
|
|
6335
6964
|
]
|
|
6336
6965
|
}
|
|
6337
6966
|
),
|
|
6338
|
-
issue.status && /* @__PURE__ */
|
|
6967
|
+
issue.status && /* @__PURE__ */ jsx5("span", { style: { fontSize: "11.5px", color: t2.textMuted }, children: issue.status })
|
|
6339
6968
|
]
|
|
6340
6969
|
}
|
|
6341
6970
|
)
|
|
@@ -6346,7 +6975,7 @@ function ReportDialog({
|
|
|
6346
6975
|
})
|
|
6347
6976
|
}
|
|
6348
6977
|
),
|
|
6349
|
-
/* @__PURE__ */
|
|
6978
|
+
/* @__PURE__ */ jsx5(
|
|
6350
6979
|
"button",
|
|
6351
6980
|
{
|
|
6352
6981
|
type: "button",
|
|
@@ -6371,15 +7000,15 @@ function ReportDialog({
|
|
|
6371
7000
|
cursor: isSubmitting || !pickedSimilar ? "not-allowed" : "pointer",
|
|
6372
7001
|
fontFamily: "inherit"
|
|
6373
7002
|
},
|
|
6374
|
-
children: typeof attachingTo === "number" && duplicateKind !== "related" ? /* @__PURE__ */
|
|
6375
|
-
/* @__PURE__ */
|
|
7003
|
+
children: typeof attachingTo === "number" && duplicateKind !== "related" ? /* @__PURE__ */ jsxs5(Fragment4, { children: [
|
|
7004
|
+
/* @__PURE__ */ jsx5(ButtonSpinner, {}),
|
|
6376
7005
|
"Adding to #",
|
|
6377
7006
|
attachingTo,
|
|
6378
7007
|
"\u2026"
|
|
6379
7008
|
] }) : pickedSimilar ? `Add to #${pickedSimilar}` : "Pick the matching issue"
|
|
6380
7009
|
}
|
|
6381
7010
|
),
|
|
6382
|
-
pickedSimilar && /* @__PURE__ */
|
|
7011
|
+
pickedSimilar && /* @__PURE__ */ jsx5(
|
|
6383
7012
|
"button",
|
|
6384
7013
|
{
|
|
6385
7014
|
type: "button",
|
|
@@ -6404,15 +7033,15 @@ function ReportDialog({
|
|
|
6404
7033
|
cursor: isSubmitting ? "not-allowed" : "pointer",
|
|
6405
7034
|
fontFamily: "inherit"
|
|
6406
7035
|
},
|
|
6407
|
-
children: typeof attachingTo === "number" && duplicateKind === "related" ? /* @__PURE__ */
|
|
6408
|
-
/* @__PURE__ */
|
|
7036
|
+
children: typeof attachingTo === "number" && duplicateKind === "related" ? /* @__PURE__ */ jsxs5(Fragment4, { children: [
|
|
7037
|
+
/* @__PURE__ */ jsx5(ButtonSpinner, {}),
|
|
6409
7038
|
"Adding to #",
|
|
6410
7039
|
attachingTo,
|
|
6411
7040
|
"\u2026"
|
|
6412
7041
|
] }) : `Related request \u2014 add to #${pickedSimilar}`
|
|
6413
7042
|
}
|
|
6414
7043
|
),
|
|
6415
|
-
/* @__PURE__ */
|
|
7044
|
+
/* @__PURE__ */ jsx5(
|
|
6416
7045
|
"button",
|
|
6417
7046
|
{
|
|
6418
7047
|
type: "button",
|
|
@@ -6437,8 +7066,8 @@ function ReportDialog({
|
|
|
6437
7066
|
cursor: isSubmitting ? "not-allowed" : "pointer",
|
|
6438
7067
|
fontFamily: "inherit"
|
|
6439
7068
|
},
|
|
6440
|
-
children: attachingTo === "new" ? /* @__PURE__ */
|
|
6441
|
-
/* @__PURE__ */
|
|
7069
|
+
children: attachingTo === "new" ? /* @__PURE__ */ jsxs5(Fragment4, { children: [
|
|
7070
|
+
/* @__PURE__ */ jsx5(ButtonSpinner, {}),
|
|
6442
7071
|
"Sending as new\u2026"
|
|
6443
7072
|
] }) : "No, mine is different \u2014 send as new"
|
|
6444
7073
|
}
|
|
@@ -6446,7 +7075,7 @@ function ReportDialog({
|
|
|
6446
7075
|
]
|
|
6447
7076
|
}
|
|
6448
7077
|
)
|
|
6449
|
-
) : /* @__PURE__ */
|
|
7078
|
+
) : /* @__PURE__ */ jsx5(
|
|
6450
7079
|
"button",
|
|
6451
7080
|
{
|
|
6452
7081
|
type: "button",
|
|
@@ -6466,8 +7095,8 @@ function ReportDialog({
|
|
|
6466
7095
|
fontFamily: "inherit",
|
|
6467
7096
|
transition: "background-color 0.15s ease"
|
|
6468
7097
|
},
|
|
6469
|
-
children: checkingSimilar ? /* @__PURE__ */
|
|
6470
|
-
/* @__PURE__ */
|
|
7098
|
+
children: checkingSimilar ? /* @__PURE__ */ jsxs5(Fragment4, { children: [
|
|
7099
|
+
/* @__PURE__ */ jsx5(ButtonSpinner, {}),
|
|
6471
7100
|
"Checking for existing reports\u2026"
|
|
6472
7101
|
] }) : isSubmitting ? shotPending && !isRating ? "Attaching screenshot\u2026" : "Sending..." : isRating ? "Send Rating" : "Send Report"
|
|
6473
7102
|
}
|
|
@@ -6476,7 +7105,7 @@ function ReportDialog({
|
|
|
6476
7105
|
] })
|
|
6477
7106
|
}
|
|
6478
7107
|
),
|
|
6479
|
-
/* @__PURE__ */
|
|
7108
|
+
/* @__PURE__ */ jsxs5(
|
|
6480
7109
|
"div",
|
|
6481
7110
|
{
|
|
6482
7111
|
style: {
|
|
@@ -6488,8 +7117,8 @@ function ReportDialog({
|
|
|
6488
7117
|
gap: "12px"
|
|
6489
7118
|
},
|
|
6490
7119
|
children: [
|
|
6491
|
-
/* @__PURE__ */
|
|
6492
|
-
reportGlitchgrabProblem ? /* @__PURE__ */
|
|
7120
|
+
/* @__PURE__ */ jsx5(ReporterChip, { reporter, t: t2 }),
|
|
7121
|
+
reportGlitchgrabProblem ? /* @__PURE__ */ jsx5(
|
|
6493
7122
|
"button",
|
|
6494
7123
|
{
|
|
6495
7124
|
type: "button",
|
|
@@ -6516,7 +7145,7 @@ function ReportDialog({
|
|
|
6516
7145
|
},
|
|
6517
7146
|
children: "Problem with Glitchgrab?"
|
|
6518
7147
|
}
|
|
6519
|
-
) : /* @__PURE__ */
|
|
7148
|
+
) : /* @__PURE__ */ jsx5(
|
|
6520
7149
|
"span",
|
|
6521
7150
|
{
|
|
6522
7151
|
style: {
|
|
@@ -6538,7 +7167,7 @@ function ReportDialog({
|
|
|
6538
7167
|
),
|
|
6539
7168
|
document.body
|
|
6540
7169
|
),
|
|
6541
|
-
/* @__PURE__ */
|
|
7170
|
+
/* @__PURE__ */ jsx5(
|
|
6542
7171
|
"input",
|
|
6543
7172
|
{
|
|
6544
7173
|
ref: fileInputRef,
|
|
@@ -6550,7 +7179,7 @@ function ReportDialog({
|
|
|
6550
7179
|
}
|
|
6551
7180
|
),
|
|
6552
7181
|
isOpen && previewIndex !== null && screenshots[previewIndex] && createPortal3(
|
|
6553
|
-
/* @__PURE__ */
|
|
7182
|
+
/* @__PURE__ */ jsxs5(
|
|
6554
7183
|
"div",
|
|
6555
7184
|
{
|
|
6556
7185
|
"data-glitchgrab-layer": "",
|
|
@@ -6572,7 +7201,7 @@ function ReportDialog({
|
|
|
6572
7201
|
},
|
|
6573
7202
|
onMouseDown: (e) => e.stopPropagation(),
|
|
6574
7203
|
children: [
|
|
6575
|
-
/* @__PURE__ */
|
|
7204
|
+
/* @__PURE__ */ jsxs5(
|
|
6576
7205
|
"div",
|
|
6577
7206
|
{
|
|
6578
7207
|
ref: previewImgRef,
|
|
@@ -6584,7 +7213,7 @@ function ReportDialog({
|
|
|
6584
7213
|
},
|
|
6585
7214
|
onClick: (e) => e.stopPropagation(),
|
|
6586
7215
|
children: [
|
|
6587
|
-
/* @__PURE__ */
|
|
7216
|
+
/* @__PURE__ */ jsx5(
|
|
6588
7217
|
"div",
|
|
6589
7218
|
{
|
|
6590
7219
|
ref: previewScrollRef,
|
|
@@ -6603,7 +7232,7 @@ function ReportDialog({
|
|
|
6603
7232
|
touchAction: "none",
|
|
6604
7233
|
cursor: "grab"
|
|
6605
7234
|
} : { maxWidth: "100%", lineHeight: 0 },
|
|
6606
|
-
children: /* @__PURE__ */
|
|
7235
|
+
children: /* @__PURE__ */ jsx5(
|
|
6607
7236
|
"img",
|
|
6608
7237
|
{
|
|
6609
7238
|
ref: previewImgElRef,
|
|
@@ -6631,7 +7260,7 @@ function ReportDialog({
|
|
|
6631
7260
|
)
|
|
6632
7261
|
}
|
|
6633
7262
|
),
|
|
6634
|
-
/* @__PURE__ */
|
|
7263
|
+
/* @__PURE__ */ jsxs5(
|
|
6635
7264
|
"button",
|
|
6636
7265
|
{
|
|
6637
7266
|
type: "button",
|
|
@@ -6659,7 +7288,7 @@ function ReportDialog({
|
|
|
6659
7288
|
animation: "gg-pulse 2s ease-in-out infinite"
|
|
6660
7289
|
},
|
|
6661
7290
|
children: [
|
|
6662
|
-
/* @__PURE__ */
|
|
7291
|
+
/* @__PURE__ */ jsx5("svg", { width: "13", height: "13", viewBox: "0 0 24 24", fill: "none", children: /* @__PURE__ */ jsx5(
|
|
6663
7292
|
"path",
|
|
6664
7293
|
{
|
|
6665
7294
|
d: "M12 20h9M16.5 3.5a2.12 2.12 0 013 3L7 19l-4 1 1-4L16.5 3.5z",
|
|
@@ -6676,7 +7305,7 @@ function ReportDialog({
|
|
|
6676
7305
|
]
|
|
6677
7306
|
}
|
|
6678
7307
|
),
|
|
6679
|
-
/* @__PURE__ */
|
|
7308
|
+
/* @__PURE__ */ jsx5(
|
|
6680
7309
|
"div",
|
|
6681
7310
|
{
|
|
6682
7311
|
style: {
|
|
@@ -6685,7 +7314,7 @@ function ReportDialog({
|
|
|
6685
7314
|
alignItems: "center",
|
|
6686
7315
|
gap: "12px"
|
|
6687
7316
|
},
|
|
6688
|
-
children: /* @__PURE__ */
|
|
7317
|
+
children: /* @__PURE__ */ jsx5(
|
|
6689
7318
|
"span",
|
|
6690
7319
|
{
|
|
6691
7320
|
style: {
|
|
@@ -6707,7 +7336,7 @@ function ReportDialog({
|
|
|
6707
7336
|
document.body
|
|
6708
7337
|
),
|
|
6709
7338
|
isOpen && annotatingIndex !== null && screenshots[annotatingIndex] && createPortal3(
|
|
6710
|
-
/* @__PURE__ */
|
|
7339
|
+
/* @__PURE__ */ jsx5(
|
|
6711
7340
|
AnnotationCanvas,
|
|
6712
7341
|
{
|
|
6713
7342
|
imageSrc: screenshots[annotatingIndex],
|
|
@@ -6723,7 +7352,7 @@ function ReportDialog({
|
|
|
6723
7352
|
),
|
|
6724
7353
|
document.body
|
|
6725
7354
|
),
|
|
6726
|
-
isOpen && selfReportFrom && reportGlitchgrabProblem && /* @__PURE__ */
|
|
7355
|
+
isOpen && selfReportFrom && reportGlitchgrabProblem && /* @__PURE__ */ jsx5(
|
|
6727
7356
|
GlitchgrabProblemPanel,
|
|
6728
7357
|
{
|
|
6729
7358
|
send: reportGlitchgrabProblem,
|
|
@@ -6736,7 +7365,7 @@ function ReportDialog({
|
|
|
6736
7365
|
onClose: () => setSelfReportFrom(null)
|
|
6737
7366
|
}
|
|
6738
7367
|
),
|
|
6739
|
-
isOpen && sheetUp && /* @__PURE__ */
|
|
7368
|
+
isOpen && sheetUp && /* @__PURE__ */ jsx5(
|
|
6740
7369
|
AssistSheet,
|
|
6741
7370
|
{
|
|
6742
7371
|
assist,
|
|
@@ -6837,7 +7466,7 @@ function getTypeIcon(type, color, size = 24) {
|
|
|
6837
7466
|
};
|
|
6838
7467
|
switch (type) {
|
|
6839
7468
|
case "RATING":
|
|
6840
|
-
return /* @__PURE__ */
|
|
7469
|
+
return /* @__PURE__ */ jsx5("svg", { ...props, children: /* @__PURE__ */ jsx5(
|
|
6841
7470
|
"path",
|
|
6842
7471
|
{
|
|
6843
7472
|
d: "M12 3l2.6 5.3 5.9.9-4.3 4.1 1 5.8L12 16.4 6.8 19.1l1-5.8L3.5 9.2l5.9-.9L12 3z",
|
|
@@ -6847,7 +7476,7 @@ function getTypeIcon(type, color, size = 24) {
|
|
|
6847
7476
|
}
|
|
6848
7477
|
) });
|
|
6849
7478
|
case "BUG":
|
|
6850
|
-
return /* @__PURE__ */
|
|
7479
|
+
return /* @__PURE__ */ jsx5("svg", { ...props, children: /* @__PURE__ */ jsx5(
|
|
6851
7480
|
"path",
|
|
6852
7481
|
{
|
|
6853
7482
|
d: "M8 2L6.5 3.5M16 2L17.5 3.5M3 9H7M17 9H21M12 2a5 5 0 015 5v4a5 5 0 01-10 0V7a5 5 0 015-5zM7 16l-2 3M17 16l2 3",
|
|
@@ -6857,7 +7486,7 @@ function getTypeIcon(type, color, size = 24) {
|
|
|
6857
7486
|
}
|
|
6858
7487
|
) });
|
|
6859
7488
|
case "FEATURE_REQUEST":
|
|
6860
|
-
return /* @__PURE__ */
|
|
7489
|
+
return /* @__PURE__ */ jsx5("svg", { ...props, children: /* @__PURE__ */ jsx5(
|
|
6861
7490
|
"path",
|
|
6862
7491
|
{
|
|
6863
7492
|
d: "M12 2L15.09 8.26L22 9.27L17 14.14L18.18 21.02L12 17.77L5.82 21.02L7 14.14L2 9.27L8.91 8.26L12 2z",
|
|
@@ -6867,8 +7496,8 @@ function getTypeIcon(type, color, size = 24) {
|
|
|
6867
7496
|
}
|
|
6868
7497
|
) });
|
|
6869
7498
|
case "UI_IMPROVEMENT":
|
|
6870
|
-
return /* @__PURE__ */
|
|
6871
|
-
/* @__PURE__ */
|
|
7499
|
+
return /* @__PURE__ */ jsxs5("svg", { ...props, children: [
|
|
7500
|
+
/* @__PURE__ */ jsx5(
|
|
6872
7501
|
"rect",
|
|
6873
7502
|
{
|
|
6874
7503
|
x: "3",
|
|
@@ -6880,7 +7509,7 @@ function getTypeIcon(type, color, size = 24) {
|
|
|
6880
7509
|
strokeWidth: "1.5"
|
|
6881
7510
|
}
|
|
6882
7511
|
),
|
|
6883
|
-
/* @__PURE__ */
|
|
7512
|
+
/* @__PURE__ */ jsx5(
|
|
6884
7513
|
"path",
|
|
6885
7514
|
{
|
|
6886
7515
|
d: "M3 9h18M9 21V9",
|
|
@@ -6891,7 +7520,7 @@ function getTypeIcon(type, color, size = 24) {
|
|
|
6891
7520
|
)
|
|
6892
7521
|
] });
|
|
6893
7522
|
case "PERFORMANCE":
|
|
6894
|
-
return /* @__PURE__ */
|
|
7523
|
+
return /* @__PURE__ */ jsx5("svg", { ...props, children: /* @__PURE__ */ jsx5(
|
|
6895
7524
|
"path",
|
|
6896
7525
|
{
|
|
6897
7526
|
d: "M12 21a9 9 0 100-18 9 9 0 000 18zM12 12l4-4M12 7v.01",
|
|
@@ -6902,7 +7531,7 @@ function getTypeIcon(type, color, size = 24) {
|
|
|
6902
7531
|
}
|
|
6903
7532
|
) });
|
|
6904
7533
|
case "SECURITY":
|
|
6905
|
-
return /* @__PURE__ */
|
|
7534
|
+
return /* @__PURE__ */ jsx5("svg", { ...props, children: /* @__PURE__ */ jsx5(
|
|
6906
7535
|
"path",
|
|
6907
7536
|
{
|
|
6908
7537
|
d: "M12 3l7 3v5c0 4.5-3 8.5-7 10-4-1.5-7-5.5-7-10V6l7-3z",
|
|
@@ -6912,9 +7541,9 @@ function getTypeIcon(type, color, size = 24) {
|
|
|
6912
7541
|
}
|
|
6913
7542
|
) });
|
|
6914
7543
|
case "QUESTION":
|
|
6915
|
-
return /* @__PURE__ */
|
|
6916
|
-
/* @__PURE__ */
|
|
6917
|
-
/* @__PURE__ */
|
|
7544
|
+
return /* @__PURE__ */ jsxs5("svg", { ...props, children: [
|
|
7545
|
+
/* @__PURE__ */ jsx5("circle", { cx: "12", cy: "12", r: "10", stroke: color, strokeWidth: "1.5" }),
|
|
7546
|
+
/* @__PURE__ */ jsx5(
|
|
6918
7547
|
"path",
|
|
6919
7548
|
{
|
|
6920
7549
|
d: "M9.09 9a3 3 0 015.83 1c0 2-3 3-3 3M12 17h.01",
|
|
@@ -6926,7 +7555,7 @@ function getTypeIcon(type, color, size = 24) {
|
|
|
6926
7555
|
)
|
|
6927
7556
|
] });
|
|
6928
7557
|
case "OTHER":
|
|
6929
|
-
return /* @__PURE__ */
|
|
7558
|
+
return /* @__PURE__ */ jsx5("svg", { ...props, children: /* @__PURE__ */ jsx5(
|
|
6930
7559
|
"path",
|
|
6931
7560
|
{
|
|
6932
7561
|
d: "M21 15a2 2 0 01-2 2H7l-4 4V5a2 2 0 012-2h14a2 2 0 012 2v10z",
|
|
@@ -6940,7 +7569,7 @@ function getTypeIcon(type, color, size = 24) {
|
|
|
6940
7569
|
|
|
6941
7570
|
// src/booking-dialog.tsx
|
|
6942
7571
|
import { useCallback as useCallback2, useEffect as useEffect5, useMemo as useMemo3, useState as useState5 } from "react";
|
|
6943
|
-
import { Fragment as
|
|
7572
|
+
import { Fragment as Fragment5, jsx as jsx6, jsxs as jsxs6 } from "react/jsx-runtime";
|
|
6944
7573
|
var t = {
|
|
6945
7574
|
bg: "#141414",
|
|
6946
7575
|
surface: "#1c1c1c",
|
|
@@ -7102,7 +7731,7 @@ function BookingDialog({
|
|
|
7102
7731
|
}
|
|
7103
7732
|
}
|
|
7104
7733
|
const canSubmitDetails = name.trim() && email.includes("@") && phone.replace(/\D/g, "").length >= 8;
|
|
7105
|
-
return /* @__PURE__ */
|
|
7734
|
+
return /* @__PURE__ */ jsx6(
|
|
7106
7735
|
"div",
|
|
7107
7736
|
{
|
|
7108
7737
|
onClick: (e) => {
|
|
@@ -7119,7 +7748,7 @@ function BookingDialog({
|
|
|
7119
7748
|
padding: 16,
|
|
7120
7749
|
fontFamily: "-apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif"
|
|
7121
7750
|
},
|
|
7122
|
-
children: /* @__PURE__ */
|
|
7751
|
+
children: /* @__PURE__ */ jsxs6(
|
|
7123
7752
|
"div",
|
|
7124
7753
|
{
|
|
7125
7754
|
role: "dialog",
|
|
@@ -7137,7 +7766,7 @@ function BookingDialog({
|
|
|
7137
7766
|
overflow: "hidden"
|
|
7138
7767
|
},
|
|
7139
7768
|
children: [
|
|
7140
|
-
/* @__PURE__ */
|
|
7769
|
+
/* @__PURE__ */ jsxs6(
|
|
7141
7770
|
"div",
|
|
7142
7771
|
{
|
|
7143
7772
|
style: {
|
|
@@ -7149,11 +7778,11 @@ function BookingDialog({
|
|
|
7149
7778
|
gap: 12
|
|
7150
7779
|
},
|
|
7151
7780
|
children: [
|
|
7152
|
-
/* @__PURE__ */
|
|
7153
|
-
/* @__PURE__ */
|
|
7154
|
-
heading.description && /* @__PURE__ */
|
|
7781
|
+
/* @__PURE__ */ jsxs6("div", { children: [
|
|
7782
|
+
/* @__PURE__ */ jsx6("div", { style: { fontSize: 15, fontWeight: 600 }, children: heading.title }),
|
|
7783
|
+
heading.description && /* @__PURE__ */ jsx6("div", { style: { fontSize: 12, color: t.muted, marginTop: 2 }, children: heading.description })
|
|
7155
7784
|
] }),
|
|
7156
|
-
/* @__PURE__ */
|
|
7785
|
+
/* @__PURE__ */ jsx6(
|
|
7157
7786
|
"button",
|
|
7158
7787
|
{
|
|
7159
7788
|
onClick: onClose,
|
|
@@ -7165,10 +7794,10 @@ function BookingDialog({
|
|
|
7165
7794
|
]
|
|
7166
7795
|
}
|
|
7167
7796
|
),
|
|
7168
|
-
/* @__PURE__ */
|
|
7169
|
-
error && /* @__PURE__ */
|
|
7170
|
-
step === "slots" && /* @__PURE__ */
|
|
7171
|
-
whatsappUrl && /* @__PURE__ */
|
|
7797
|
+
/* @__PURE__ */ jsxs6("div", { style: { padding: 18, overflowY: "auto", flex: "1 1 auto" }, children: [
|
|
7798
|
+
error && /* @__PURE__ */ jsx6("div", { style: { color: t.danger, fontSize: 12, marginBottom: 12, lineHeight: 1.5 }, children: error }),
|
|
7799
|
+
step === "slots" && /* @__PURE__ */ jsxs6(Fragment5, { children: [
|
|
7800
|
+
whatsappUrl && /* @__PURE__ */ jsxs6(
|
|
7172
7801
|
"a",
|
|
7173
7802
|
{
|
|
7174
7803
|
href: whatsappUrl,
|
|
@@ -7187,15 +7816,15 @@ function BookingDialog({
|
|
|
7187
7816
|
},
|
|
7188
7817
|
children: [
|
|
7189
7818
|
"\u{1F4AC} Rather book on WhatsApp?",
|
|
7190
|
-
/* @__PURE__ */
|
|
7819
|
+
/* @__PURE__ */ jsx6("span", { style: { display: "block", fontSize: 11, color: t.muted, marginTop: 2 }, children: "We'll ask the same questions in chat." })
|
|
7191
7820
|
]
|
|
7192
7821
|
}
|
|
7193
7822
|
),
|
|
7194
|
-
slots === null && /* @__PURE__ */
|
|
7195
|
-
(slots == null ? void 0 : slots.length) === 0 && !error && /* @__PURE__ */
|
|
7196
|
-
[...byDay.entries()].map(([day, daySlots]) => /* @__PURE__ */
|
|
7197
|
-
/* @__PURE__ */
|
|
7198
|
-
/* @__PURE__ */
|
|
7823
|
+
slots === null && /* @__PURE__ */ jsx6("div", { style: { color: t.muted, fontSize: 13 }, children: "Finding times\u2026" }),
|
|
7824
|
+
(slots == null ? void 0 : slots.length) === 0 && !error && /* @__PURE__ */ jsx6("div", { style: { color: t.muted, fontSize: 13 }, children: "No times available right now." }),
|
|
7825
|
+
[...byDay.entries()].map(([day, daySlots]) => /* @__PURE__ */ jsxs6("div", { style: { marginBottom: 18 }, children: [
|
|
7826
|
+
/* @__PURE__ */ jsx6("div", { style: { fontSize: 11, color: t.muted, marginBottom: 8, textTransform: "uppercase", letterSpacing: ".6px" }, children: formatDay(daySlots[0].startsAt) }),
|
|
7827
|
+
/* @__PURE__ */ jsx6("div", { style: { display: "flex", flexWrap: "wrap", gap: 8 }, children: daySlots.map((slot) => /* @__PURE__ */ jsx6(
|
|
7199
7828
|
"button",
|
|
7200
7829
|
{
|
|
7201
7830
|
onClick: () => {
|
|
@@ -7217,13 +7846,13 @@ function BookingDialog({
|
|
|
7217
7846
|
)) })
|
|
7218
7847
|
] }, day))
|
|
7219
7848
|
] }),
|
|
7220
|
-
step === "details" && selected && /* @__PURE__ */
|
|
7221
|
-
/* @__PURE__ */
|
|
7849
|
+
step === "details" && selected && /* @__PURE__ */ jsxs6("div", { style: { display: "flex", flexDirection: "column", gap: 10 }, children: [
|
|
7850
|
+
/* @__PURE__ */ jsxs6("div", { style: { fontSize: 13, color: t.muted }, children: [
|
|
7222
7851
|
formatDay(selected.startsAt),
|
|
7223
7852
|
" \xB7 ",
|
|
7224
7853
|
formatTime(selected.startsAt),
|
|
7225
7854
|
" \xB7 ",
|
|
7226
|
-
/* @__PURE__ */
|
|
7855
|
+
/* @__PURE__ */ jsx6(
|
|
7227
7856
|
"button",
|
|
7228
7857
|
{
|
|
7229
7858
|
onClick: () => setStep("slots"),
|
|
@@ -7232,9 +7861,9 @@ function BookingDialog({
|
|
|
7232
7861
|
}
|
|
7233
7862
|
)
|
|
7234
7863
|
] }),
|
|
7235
|
-
/* @__PURE__ */
|
|
7236
|
-
/* @__PURE__ */
|
|
7237
|
-
/* @__PURE__ */
|
|
7864
|
+
/* @__PURE__ */ jsx6(Field, { label: "Your name", value: name, onChange: setName }),
|
|
7865
|
+
/* @__PURE__ */ jsx6(Field, { label: "Email", value: email, onChange: setEmail, type: "email" }),
|
|
7866
|
+
/* @__PURE__ */ jsx6(
|
|
7238
7867
|
Field,
|
|
7239
7868
|
{
|
|
7240
7869
|
label: "Mobile number",
|
|
@@ -7244,8 +7873,8 @@ function BookingDialog({
|
|
|
7244
7873
|
hint: "We send a code here to confirm, then a reminder before the call."
|
|
7245
7874
|
}
|
|
7246
7875
|
),
|
|
7247
|
-
/* @__PURE__ */
|
|
7248
|
-
/* @__PURE__ */
|
|
7876
|
+
/* @__PURE__ */ jsx6(Field, { label: "Anything we should know? (optional)", value: note, onChange: setNote }),
|
|
7877
|
+
/* @__PURE__ */ jsx6(
|
|
7249
7878
|
"button",
|
|
7250
7879
|
{
|
|
7251
7880
|
onClick: startBooking,
|
|
@@ -7255,10 +7884,10 @@ function BookingDialog({
|
|
|
7255
7884
|
}
|
|
7256
7885
|
)
|
|
7257
7886
|
] }),
|
|
7258
|
-
step === "code" && /* @__PURE__ */
|
|
7259
|
-
/* @__PURE__ */
|
|
7260
|
-
/* @__PURE__ */
|
|
7261
|
-
/* @__PURE__ */
|
|
7887
|
+
step === "code" && /* @__PURE__ */ jsxs6("div", { style: { display: "flex", flexDirection: "column", gap: 10 }, children: [
|
|
7888
|
+
/* @__PURE__ */ jsx6("div", { style: { fontSize: 13, color: t.muted, lineHeight: 1.5 }, children: "We sent a 4-digit code to your phone. Your slot is held for 10 minutes." }),
|
|
7889
|
+
/* @__PURE__ */ jsx6(Field, { label: "Code", value: code, onChange: setCode }),
|
|
7890
|
+
/* @__PURE__ */ jsx6(
|
|
7262
7891
|
"button",
|
|
7263
7892
|
{
|
|
7264
7893
|
onClick: confirmBooking,
|
|
@@ -7268,15 +7897,15 @@ function BookingDialog({
|
|
|
7268
7897
|
}
|
|
7269
7898
|
)
|
|
7270
7899
|
] }),
|
|
7271
|
-
step === "done" && /* @__PURE__ */
|
|
7272
|
-
/* @__PURE__ */
|
|
7273
|
-
/* @__PURE__ */
|
|
7900
|
+
step === "done" && /* @__PURE__ */ jsxs6("div", { style: { display: "flex", flexDirection: "column", gap: 10 }, children: [
|
|
7901
|
+
/* @__PURE__ */ jsx6("div", { style: { fontSize: 15, fontWeight: 600 }, children: "You're booked." }),
|
|
7902
|
+
/* @__PURE__ */ jsxs6("div", { style: { fontSize: 13, color: t.muted, lineHeight: 1.6 }, children: [
|
|
7274
7903
|
selected && `${formatDay(selected.startsAt)} at ${formatTime(selected.startsAt)}. `,
|
|
7275
7904
|
"A calendar invite is on its way to ",
|
|
7276
7905
|
email,
|
|
7277
7906
|
", and we'll send a WhatsApp reminder before the call."
|
|
7278
7907
|
] }),
|
|
7279
|
-
meetUrl && /* @__PURE__ */
|
|
7908
|
+
meetUrl && /* @__PURE__ */ jsx6("a", { href: meetUrl, target: "_blank", rel: "noreferrer", style: { ...primaryStyle(false), textAlign: "center", textDecoration: "none" }, children: "Open the meeting link" })
|
|
7280
7909
|
] })
|
|
7281
7910
|
] })
|
|
7282
7911
|
]
|
|
@@ -7305,9 +7934,9 @@ function Field({
|
|
|
7305
7934
|
type = "text",
|
|
7306
7935
|
hint
|
|
7307
7936
|
}) {
|
|
7308
|
-
return /* @__PURE__ */
|
|
7937
|
+
return /* @__PURE__ */ jsxs6("label", { style: { display: "block", fontSize: 11, color: t.muted }, children: [
|
|
7309
7938
|
label,
|
|
7310
|
-
/* @__PURE__ */
|
|
7939
|
+
/* @__PURE__ */ jsx6(
|
|
7311
7940
|
"input",
|
|
7312
7941
|
{
|
|
7313
7942
|
type,
|
|
@@ -7328,7 +7957,7 @@ function Field({
|
|
|
7328
7957
|
}
|
|
7329
7958
|
}
|
|
7330
7959
|
),
|
|
7331
|
-
hint && /* @__PURE__ */
|
|
7960
|
+
hint && /* @__PURE__ */ jsx6("div", { style: { marginTop: 4, fontSize: 10, color: t.muted }, children: hint })
|
|
7332
7961
|
] });
|
|
7333
7962
|
}
|
|
7334
7963
|
|
|
@@ -7469,7 +8098,7 @@ function matchesShortcut(e) {
|
|
|
7469
8098
|
}
|
|
7470
8099
|
|
|
7471
8100
|
// src/provider.tsx
|
|
7472
|
-
import { Fragment as
|
|
8101
|
+
import { Fragment as Fragment6, jsx as jsx7, jsxs as jsxs7 } from "react/jsx-runtime";
|
|
7473
8102
|
var DEFAULT_BASE_URL2 = "https://glitchgrab.dev";
|
|
7474
8103
|
var GlitchgrabContext = createContext(null);
|
|
7475
8104
|
function useGlitchgrab() {
|
|
@@ -7951,7 +8580,7 @@ function GlitchgrabProviderInner({
|
|
|
7951
8580
|
useEffect6(() => {
|
|
7952
8581
|
setShortcutLabel(getShortcutLabel2());
|
|
7953
8582
|
}, []);
|
|
7954
|
-
return /* @__PURE__ */
|
|
8583
|
+
return /* @__PURE__ */ jsxs7(
|
|
7955
8584
|
GlitchgrabContext.Provider,
|
|
7956
8585
|
{
|
|
7957
8586
|
value: {
|
|
@@ -7971,7 +8600,7 @@ function GlitchgrabProviderInner({
|
|
|
7971
8600
|
shortcutLabel
|
|
7972
8601
|
},
|
|
7973
8602
|
children: [
|
|
7974
|
-
/* @__PURE__ */
|
|
8603
|
+
/* @__PURE__ */ jsx7(
|
|
7975
8604
|
GlitchgrabErrorBoundary,
|
|
7976
8605
|
{
|
|
7977
8606
|
token,
|
|
@@ -7983,7 +8612,7 @@ function GlitchgrabProviderInner({
|
|
|
7983
8612
|
children
|
|
7984
8613
|
}
|
|
7985
8614
|
),
|
|
7986
|
-
/* @__PURE__ */
|
|
8615
|
+
/* @__PURE__ */ jsx7(
|
|
7987
8616
|
BookingDialog,
|
|
7988
8617
|
{
|
|
7989
8618
|
token,
|
|
@@ -7992,7 +8621,7 @@ function GlitchgrabProviderInner({
|
|
|
7992
8621
|
onClose: () => setBookingOpen(false)
|
|
7993
8622
|
}
|
|
7994
8623
|
),
|
|
7995
|
-
/* @__PURE__ */
|
|
8624
|
+
/* @__PURE__ */ jsx7(
|
|
7996
8625
|
ReportDialog,
|
|
7997
8626
|
{
|
|
7998
8627
|
report,
|
|
@@ -8005,9 +8634,9 @@ function GlitchgrabProviderInner({
|
|
|
8005
8634
|
types,
|
|
8006
8635
|
showSeverity,
|
|
8007
8636
|
reporter,
|
|
8008
|
-
headerSlot: projectName ? /* @__PURE__ */
|
|
8637
|
+
headerSlot: projectName ? /* @__PURE__ */ jsxs7("div", { style: { fontSize: 11, color: "#9aa0a6" }, children: [
|
|
8009
8638
|
"Reporting to ",
|
|
8010
|
-
/* @__PURE__ */
|
|
8639
|
+
/* @__PURE__ */ jsx7("strong", { style: { color: "#e5e5e5" }, children: projectName })
|
|
8011
8640
|
] }) : null
|
|
8012
8641
|
}
|
|
8013
8642
|
)
|
|
@@ -8016,21 +8645,21 @@ function GlitchgrabProviderInner({
|
|
|
8016
8645
|
);
|
|
8017
8646
|
}
|
|
8018
8647
|
function GlitchgrabProvider(props) {
|
|
8019
|
-
if (!props.token) return /* @__PURE__ */
|
|
8648
|
+
if (!props.token) return /* @__PURE__ */ jsx7(Fragment6, { children: props.children });
|
|
8020
8649
|
const resolvedProps = {
|
|
8021
8650
|
...props,
|
|
8022
8651
|
baseUrl: props.baseUrl || DEFAULT_BASE_URL2
|
|
8023
8652
|
};
|
|
8024
8653
|
try {
|
|
8025
|
-
return /* @__PURE__ */
|
|
8654
|
+
return /* @__PURE__ */ jsx7(GlitchgrabProviderInner, { ...resolvedProps });
|
|
8026
8655
|
} catch (e) {
|
|
8027
|
-
return /* @__PURE__ */
|
|
8656
|
+
return /* @__PURE__ */ jsx7(Fragment6, { children: props.children });
|
|
8028
8657
|
}
|
|
8029
8658
|
}
|
|
8030
8659
|
|
|
8031
8660
|
// src/report-button.tsx
|
|
8032
8661
|
import { useState as useState7 } from "react";
|
|
8033
|
-
import { Fragment as
|
|
8662
|
+
import { Fragment as Fragment7, jsx as jsx8, jsxs as jsxs8 } from "react/jsx-runtime";
|
|
8034
8663
|
function useGlitchgrabSafe() {
|
|
8035
8664
|
try {
|
|
8036
8665
|
return useGlitchgrab();
|
|
@@ -8054,7 +8683,7 @@ function ReportButton({
|
|
|
8054
8683
|
setCapturing(false);
|
|
8055
8684
|
};
|
|
8056
8685
|
if (children) {
|
|
8057
|
-
return /* @__PURE__ */
|
|
8686
|
+
return /* @__PURE__ */ jsx8(Fragment7, { children: children({ onClick: handleClick, capturing }) });
|
|
8058
8687
|
}
|
|
8059
8688
|
const isTop = (_a = position == null ? void 0 : position.startsWith("top")) != null ? _a : false;
|
|
8060
8689
|
const isLeft = (_b = position == null ? void 0 : position.endsWith("left")) != null ? _b : false;
|
|
@@ -8062,7 +8691,7 @@ function ReportButton({
|
|
|
8062
8691
|
...isLeft ? { left: "16px" } : { right: "16px" },
|
|
8063
8692
|
...isTop ? { top: "16px" } : { bottom: "16px" }
|
|
8064
8693
|
};
|
|
8065
|
-
return /* @__PURE__ */
|
|
8694
|
+
return /* @__PURE__ */ jsxs8(
|
|
8066
8695
|
"button",
|
|
8067
8696
|
{
|
|
8068
8697
|
type: "button",
|
|
@@ -8097,7 +8726,7 @@ function ReportButton({
|
|
|
8097
8726
|
},
|
|
8098
8727
|
"aria-label": label,
|
|
8099
8728
|
children: [
|
|
8100
|
-
/* @__PURE__ */
|
|
8729
|
+
/* @__PURE__ */ jsx8(
|
|
8101
8730
|
"svg",
|
|
8102
8731
|
{
|
|
8103
8732
|
width: "16",
|
|
@@ -8105,7 +8734,7 @@ function ReportButton({
|
|
|
8105
8734
|
viewBox: "0 0 16 16",
|
|
8106
8735
|
fill: "none",
|
|
8107
8736
|
style: { flexShrink: 0 },
|
|
8108
|
-
children: /* @__PURE__ */
|
|
8737
|
+
children: /* @__PURE__ */ jsx8(
|
|
8109
8738
|
"path",
|
|
8110
8739
|
{
|
|
8111
8740
|
d: "M8 1C4.134 1 1 4.134 1 8s3.134 7 7 7 7-3.134 7-7-3.134-7-7-7zm0 12.5a.75.75 0 110-1.5.75.75 0 010 1.5zm.75-3.5a.75.75 0 01-1.5 0V5a.75.75 0 011.5 0v5z",
|
|
@@ -8121,15 +8750,15 @@ function ReportButton({
|
|
|
8121
8750
|
}
|
|
8122
8751
|
|
|
8123
8752
|
// src/book-demo-button.tsx
|
|
8124
|
-
import { Fragment as
|
|
8753
|
+
import { Fragment as Fragment8, jsx as jsx9 } from "react/jsx-runtime";
|
|
8125
8754
|
function BookDemoButton({
|
|
8126
8755
|
label = "Book a demo",
|
|
8127
8756
|
className,
|
|
8128
8757
|
children
|
|
8129
8758
|
}) {
|
|
8130
8759
|
const { openBookingDialog } = useGlitchgrab();
|
|
8131
|
-
if (children) return /* @__PURE__ */
|
|
8132
|
-
return /* @__PURE__ */
|
|
8760
|
+
if (children) return /* @__PURE__ */ jsx9(Fragment8, { children: children({ onClick: openBookingDialog }) });
|
|
8761
|
+
return /* @__PURE__ */ jsx9(
|
|
8133
8762
|
"button",
|
|
8134
8763
|
{
|
|
8135
8764
|
type: "button",
|
|
@@ -8151,7 +8780,7 @@ function BookDemoButton({
|
|
|
8151
8780
|
}
|
|
8152
8781
|
|
|
8153
8782
|
// src/feedback-button.tsx
|
|
8154
|
-
import { Fragment as
|
|
8783
|
+
import { Fragment as Fragment9, jsx as jsx10, jsxs as jsxs9 } from "react/jsx-runtime";
|
|
8155
8784
|
function useGlitchgrabSafe2() {
|
|
8156
8785
|
try {
|
|
8157
8786
|
return useGlitchgrab();
|
|
@@ -8170,7 +8799,7 @@ function FeedbackButton({
|
|
|
8170
8799
|
if (!glitchgrab) return null;
|
|
8171
8800
|
const handleClick = () => glitchgrab.openFeedbackDialog();
|
|
8172
8801
|
if (children) {
|
|
8173
|
-
return /* @__PURE__ */
|
|
8802
|
+
return /* @__PURE__ */ jsx10(Fragment9, { children: children({ onClick: handleClick }) });
|
|
8174
8803
|
}
|
|
8175
8804
|
const isTop = (_a = position == null ? void 0 : position.startsWith("top")) != null ? _a : false;
|
|
8176
8805
|
const isLeft = (_b = position == null ? void 0 : position.endsWith("left")) != null ? _b : false;
|
|
@@ -8178,7 +8807,7 @@ function FeedbackButton({
|
|
|
8178
8807
|
...isLeft ? { left: "16px" } : { right: "16px" },
|
|
8179
8808
|
...isTop ? { top: "16px" } : { bottom: "16px" }
|
|
8180
8809
|
};
|
|
8181
|
-
return /* @__PURE__ */
|
|
8810
|
+
return /* @__PURE__ */ jsxs9(
|
|
8182
8811
|
"button",
|
|
8183
8812
|
{
|
|
8184
8813
|
type: "button",
|
|
@@ -8211,7 +8840,7 @@ function FeedbackButton({
|
|
|
8211
8840
|
},
|
|
8212
8841
|
"aria-label": label,
|
|
8213
8842
|
children: [
|
|
8214
|
-
/* @__PURE__ */
|
|
8843
|
+
/* @__PURE__ */ jsx10(
|
|
8215
8844
|
"svg",
|
|
8216
8845
|
{
|
|
8217
8846
|
width: "16",
|
|
@@ -8220,7 +8849,7 @@ function FeedbackButton({
|
|
|
8220
8849
|
fill: "none",
|
|
8221
8850
|
style: { flexShrink: 0 },
|
|
8222
8851
|
"aria-hidden": "true",
|
|
8223
|
-
children: /* @__PURE__ */
|
|
8852
|
+
children: /* @__PURE__ */ jsx10(
|
|
8224
8853
|
"path",
|
|
8225
8854
|
{
|
|
8226
8855
|
d: "M12 2.5l2.9 5.9 6.5.9-4.7 4.6 1.1 6.5L12 17.4l-5.8 3 1.1-6.5L2.6 9.3l6.5-.9L12 2.5z",
|