@flamingo-stack/openframe-frontend-core 0.0.818 → 0.0.820
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/dist/{chunk-VGZXB3SY.cjs → chunk-2TEUAOUZ.cjs} +3 -3
- package/dist/{chunk-NWIEZUM7.cjs → chunk-42K7MLVS.cjs} +19 -19
- package/dist/{chunk-5AIOYEXW.cjs → chunk-5GUQBNQF.cjs} +47 -47
- package/dist/{chunk-JTBJB4JF.cjs → chunk-7X7PHALX.cjs} +9 -9
- package/dist/{chunk-YHPUD4PM.cjs → chunk-ADBZCDFX.cjs} +11 -11
- package/dist/{chunk-YMPPE322.cjs → chunk-BHJDQYUN.cjs} +107 -107
- package/dist/{chunk-DGAX5WG2.cjs → chunk-CJ7VHMPD.cjs} +2 -2
- package/dist/{chunk-DL4HWYIB.cjs → chunk-DLQCSJTY.cjs} +3 -3
- package/dist/{chunk-AE22KOW3.cjs → chunk-IJ3C4WL5.cjs} +53 -53
- package/dist/{chunk-BD42NMCT.cjs → chunk-JQ3JZLYS.cjs} +4 -4
- package/dist/{chunk-6QT5K5I5.cjs → chunk-L55EVW33.cjs} +6 -6
- package/dist/{chunk-5VRSUEC5.cjs → chunk-MOPDE3OA.cjs} +10 -10
- package/dist/{chunk-U2THWP25.cjs → chunk-NSN3O47K.cjs} +32 -32
- package/dist/{chunk-IQCHV7Z2.cjs → chunk-OTGYA5F7.cjs} +21 -3
- package/dist/{chunk-ZWAVMZIF.cjs → chunk-STFOH6QU.cjs} +7 -7
- package/dist/{chunk-VRXDTRIY.cjs → chunk-TVOAFYT7.cjs} +39 -39
- package/dist/{chunk-NEXMK6OP.cjs → chunk-TYDSD3FV.cjs} +4 -4
- package/dist/{chunk-4XASD2TL.cjs → chunk-YAY7Z42C.cjs} +16 -16
- package/dist/{cloud-tenants-V6EV4OGK.cjs → cloud-tenants-ENCHNOF2.cjs} +4 -4
- package/dist/components/case-studies/index.cjs +16 -16
- package/dist/components/chat/embeddable-chat.d.ts.map +1 -1
- package/dist/components/chat/embeddable-chat.js +5 -6
- package/dist/components/chat/index.cjs +3 -3
- package/dist/components/chat/remark-strip-citations.d.ts +1 -1
- package/dist/components/chat/remark-strip-citations.d.ts.map +1 -1
- package/dist/components/chat/remark-strip-citations.js +8 -2
- package/dist/components/chat/utils/cited-sources.d.ts +9 -0
- package/dist/components/chat/utils/cited-sources.d.ts.map +1 -1
- package/dist/components/chat/utils/cited-sources.js +41 -0
- package/dist/components/contact/index.cjs +5 -5
- package/dist/components/docs/index.cjs +8 -8
- package/dist/components/embeds/index.cjs +5 -5
- package/dist/components/faq/index.cjs +6 -6
- package/dist/components/features/index.cjs +4 -4
- package/dist/components/help-center-pages/index.cjs +61 -61
- package/dist/components/index.cjs +37 -37
- package/dist/components/meeting-scheduler/index.cjs +29 -29
- package/dist/components/navigation/index.cjs +7 -7
- package/dist/components/onboarding-guides/index.cjs +6 -6
- package/dist/components/product-demo/index.cjs +13 -13
- package/dist/components/tickets/index.cjs +9 -9
- package/dist/components/ui/index.cjs +4 -4
- package/dist/{devices-6KZAJAAS.cjs → devices-HRLHG4TR.cjs} +5 -5
- package/dist/{embeddable-chat-5IHA5SUZ.cjs → embeddable-chat-ARMXVLUP.cjs} +107 -67
- package/dist/index.cjs +8 -8
- package/dist/{knowledge-I7FDQQYJ.cjs → knowledge-S2L5ZCAU.cjs} +5 -5
- package/dist/{logs-Q7PAVJUG.cjs → logs-UYQZSFS4.cjs} +12 -12
- package/dist/{policies-C3DW5CHS.cjs → policies-SMA4MW6L.cjs} +8 -8
- package/dist/{scripts-BET663HD.cjs → scripts-TZNXTFRR.cjs} +9 -9
- package/dist/{software-update-W7ZQXEPK.cjs → software-update-YHDVBC7V.cjs} +7 -7
- package/package.json +1 -1
- package/src/components/chat/embeddable-chat.tsx +7 -8
- package/src/components/chat/remark-strip-citations.ts +14 -3
- package/src/components/chat/utils/cited-sources.ts +61 -0
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
"use strict";Object.defineProperty(exports, "__esModule", {value: true}); function _nullishCoalesce(lhs, rhsFn) { if (lhs != null) { return lhs; } else { return rhsFn(); } } function _optionalChain(ops) { let lastAccessLHS = undefined; let value = ops[0]; let i = 1; while (i < ops.length) { const op = ops[i]; const fn = ops[i + 1]; i += 2; if ((op === 'optionalAccess' || op === 'optionalCall') && value == null) { return undefined; } if (op === 'access' || op === 'optionalAccess') { lastAccessLHS = value; value = fn(value); } else if (op === 'call' || op === 'optionalCall') { value = fn((...args) => value.call(lastAccessLHS, ...args)); lastAccessLHS = undefined; } } return value; }"use client";
|
|
2
2
|
|
|
3
3
|
|
|
4
|
-
var
|
|
4
|
+
var _chunkYAY7Z42Ccjs = require('./chunk-YAY7Z42C.cjs');
|
|
5
5
|
|
|
6
6
|
|
|
7
7
|
var _chunkZRDVFADQcjs = require('./chunk-ZRDVFADQ.cjs');
|
|
@@ -396,7 +396,7 @@ function useScrollSpy(sections, options = {}) {
|
|
|
396
396
|
// src/components/navigation/multi-level-navigation.tsx
|
|
397
397
|
var _lucidereact = require('lucide-react');
|
|
398
398
|
|
|
399
|
-
var DEFAULT_FOLDER_INDEX_FILE2 =
|
|
399
|
+
var DEFAULT_FOLDER_INDEX_FILE2 = _chunkYAY7Z42Ccjs.DEFAULT_FOLDER_INDEX_FILE;
|
|
400
400
|
var NAV_LIST_CLASS = "space-y-2";
|
|
401
401
|
var NAV_ITEM_CLASS = "space-y-1";
|
|
402
402
|
var NAV_ROW_FRAME_CLASS = "relative w-full rounded-lg border transition-all duration-150";
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
"use strict";Object.defineProperty(exports, "__esModule", {value: true});"use client";
|
|
2
2
|
|
|
3
3
|
|
|
4
|
-
var
|
|
4
|
+
var _chunkBHJDQYUNcjs = require('./chunk-BHJDQYUN.cjs');
|
|
5
5
|
|
|
6
6
|
|
|
7
7
|
var _chunkCKR42OBKcjs = require('./chunk-CKR42OBK.cjs');
|
|
@@ -48,7 +48,7 @@ function GoogleSheetsViewer({ externalUrl, fileName, height }) {
|
|
|
48
48
|
] });
|
|
49
49
|
}
|
|
50
50
|
return /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
51
|
-
|
|
51
|
+
_chunkBHJDQYUNcjs.EmbedViewerFrame,
|
|
52
52
|
{
|
|
53
53
|
icon: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkCKR42OBKcjs.GoogleSheetsIcon, { className: "h-5 w-5 shrink-0" }),
|
|
54
54
|
title: displayName,
|
|
@@ -83,7 +83,7 @@ function PdfViewer({ src, fileName, onPreview, onDownload, height }) {
|
|
|
83
83
|
] });
|
|
84
84
|
}
|
|
85
85
|
return /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
86
|
-
|
|
86
|
+
_chunkBHJDQYUNcjs.EmbedViewerFrame,
|
|
87
87
|
{
|
|
88
88
|
icon: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkM7ZSKWT3cjs.AdobePdfIcon, { className: "h-5 w-5 shrink-0" }),
|
|
89
89
|
title: displayName,
|
|
@@ -1,21 +1,21 @@
|
|
|
1
1
|
"use strict";Object.defineProperty(exports, "__esModule", {value: true}); function _interopRequireWildcard(obj) { if (obj && obj.__esModule) { return obj; } else { var newObj = {}; if (obj != null) { for (var key in obj) { if (Object.prototype.hasOwnProperty.call(obj, key)) { newObj[key] = obj[key]; } } } newObj.default = obj; return newObj; } } function _nullishCoalesce(lhs, rhsFn) { if (lhs != null) { return lhs; } else { return rhsFn(); } } function _optionalChain(ops) { let lastAccessLHS = undefined; let value = ops[0]; let i = 1; while (i < ops.length) { const op = ops[i]; const fn = ops[i + 1]; i += 2; if ((op === 'optionalAccess' || op === 'optionalCall') && value == null) { return undefined; } if (op === 'access' || op === 'optionalAccess') { lastAccessLHS = value; value = fn(value); } else if (op === 'call' || op === 'optionalCall') { value = fn((...args) => value.call(lastAccessLHS, ...args)); lastAccessLHS = undefined; } } return value; }"use client";
|
|
2
2
|
|
|
3
3
|
|
|
4
|
-
var
|
|
4
|
+
var _chunk7X7PHALXcjs = require('./chunk-7X7PHALX.cjs');
|
|
5
5
|
|
|
6
6
|
|
|
7
7
|
|
|
8
8
|
|
|
9
9
|
|
|
10
10
|
|
|
11
|
-
var
|
|
11
|
+
var _chunkMOPDE3OAcjs = require('./chunk-MOPDE3OA.cjs');
|
|
12
12
|
|
|
13
13
|
|
|
14
14
|
|
|
15
15
|
var _chunkSBFBNOKUcjs = require('./chunk-SBFBNOKU.cjs');
|
|
16
16
|
|
|
17
17
|
|
|
18
|
-
var
|
|
18
|
+
var _chunkJQ3JZLYScjs = require('./chunk-JQ3JZLYS.cjs');
|
|
19
19
|
|
|
20
20
|
|
|
21
21
|
|
|
@@ -28,7 +28,7 @@ var _chunkBD42NMCTcjs = require('./chunk-BD42NMCT.cjs');
|
|
|
28
28
|
|
|
29
29
|
|
|
30
30
|
|
|
31
|
-
var
|
|
31
|
+
var _chunkBHJDQYUNcjs = require('./chunk-BHJDQYUN.cjs');
|
|
32
32
|
|
|
33
33
|
|
|
34
34
|
|
|
@@ -45,14 +45,14 @@ var _chunk7DNL734Scjs = require('./chunk-7DNL734S.cjs');
|
|
|
45
45
|
|
|
46
46
|
|
|
47
47
|
|
|
48
|
-
var
|
|
48
|
+
var _chunkYAY7Z42Ccjs = require('./chunk-YAY7Z42C.cjs');
|
|
49
49
|
|
|
50
50
|
|
|
51
51
|
|
|
52
52
|
|
|
53
53
|
|
|
54
54
|
|
|
55
|
-
var
|
|
55
|
+
var _chunkOTGYA5F7cjs = require('./chunk-OTGYA5F7.cjs');
|
|
56
56
|
|
|
57
57
|
|
|
58
58
|
var _chunkOBQ5WUNGcjs = require('./chunk-OBQ5WUNG.cjs');
|
|
@@ -155,7 +155,7 @@ var TicketActionFailure = class extends Error {
|
|
|
155
155
|
function useTicketActions(options) {
|
|
156
156
|
const queryClient = _reactquery.useQueryClient.call(void 0, );
|
|
157
157
|
const ticketActionEndpoint = _nullishCoalesce(_chunkUJ7AXHRZcjs.useRequiredChatRuntime.call(void 0, ).endpoints.ticketActionUrl, () => ( TICKET_ACTION_ENDPOINT));
|
|
158
|
-
const ticketLive =
|
|
158
|
+
const ticketLive = _chunkJQ3JZLYScjs.useOptionalTicketLive.call(void 0, );
|
|
159
159
|
const notifyTicketCreated = _optionalChain([ticketLive, 'optionalAccess', _ => _.notifyTicketCreated]);
|
|
160
160
|
const { prependOptimistic, removeOptimistic, removeTicketFromCache, toast: toast2, onSupportSystemDown } = options;
|
|
161
161
|
const formInFlightRef = _react.useRef.call(void 0, null);
|
|
@@ -648,7 +648,7 @@ var COUNTER_VISIBLE_AT = Math.floor(TICKET_TEXT_MAX_CHARS * 0.8);
|
|
|
648
648
|
function TicketOpenForm({ onSubmit, isSubmitting, supportSystemDown }) {
|
|
649
649
|
const [subject, setSubject] = _react.useState.call(void 0, "");
|
|
650
650
|
const [content, setContent] = _react.useState.call(void 0, "");
|
|
651
|
-
const { attachments, readyAttachments, hasInflightUploads, addFiles, removeAttachment, clear } =
|
|
651
|
+
const { attachments, readyAttachments, hasInflightUploads, addFiles, removeAttachment, clear } = _chunkOTGYA5F7cjs.useChatAttachments.call(void 0, );
|
|
652
652
|
const trimmedSubject = subject.trim();
|
|
653
653
|
const trimmedContent = content.trim();
|
|
654
654
|
const overCap = content.length > TICKET_TEXT_MAX_CHARS;
|
|
@@ -668,7 +668,7 @@ function TicketOpenForm({ onSubmit, isSubmitting, supportSystemDown }) {
|
|
|
668
668
|
clear();
|
|
669
669
|
}
|
|
670
670
|
};
|
|
671
|
-
return /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkUEULXVW2cjs.Card, { className: "p-6", children: /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "form", { onSubmit: handleSubmit, className: "flex flex-col gap-6 md:flex-row", ...
|
|
671
|
+
return /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkUEULXVW2cjs.Card, { className: "p-6", children: /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "form", { onSubmit: handleSubmit, className: "flex flex-col gap-6 md:flex-row", ..._chunkYAY7Z42Ccjs.HUBSPOT_DO_NOT_COLLECT_FORM_PROPS, children: [
|
|
672
672
|
/* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { className: "min-w-0 flex-1 md:max-w-md", children: [
|
|
673
673
|
/* @__PURE__ */ _jsxruntime.jsx.call(void 0, "h2", { className: "mb-2 text-ods-text-primary text-h2", children: "Need Support?" }),
|
|
674
674
|
/* @__PURE__ */ _jsxruntime.jsx.call(void 0, "p", { className: "text-ods-text-secondary text-h6", children: "Can't find what you're looking for? Submit a support ticket below \u2014 we'll follow up shortly." }),
|
|
@@ -693,7 +693,7 @@ function TicketOpenForm({ onSubmit, isSubmitting, supportSystemDown }) {
|
|
|
693
693
|
/* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { children: [
|
|
694
694
|
/* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkN3MBQRCQcjs.Label, { htmlFor: "ticket-content", className: "mb-1", children: "Your Message" }),
|
|
695
695
|
/* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
696
|
-
|
|
696
|
+
_chunkBHJDQYUNcjs.Textarea,
|
|
697
697
|
{
|
|
698
698
|
id: "ticket-content",
|
|
699
699
|
placeholder: "Describe your issue or question in detail...",
|
|
@@ -711,7 +711,7 @@ function TicketOpenForm({ onSubmit, isSubmitting, supportSystemDown }) {
|
|
|
711
711
|
] })
|
|
712
712
|
] }),
|
|
713
713
|
/* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
714
|
-
|
|
714
|
+
_chunkOTGYA5F7cjs.ChatAttachmentChipStrip,
|
|
715
715
|
{
|
|
716
716
|
attachments,
|
|
717
717
|
onRemove: removeAttachment,
|
|
@@ -720,7 +720,7 @@ function TicketOpenForm({ onSubmit, isSubmitting, supportSystemDown }) {
|
|
|
720
720
|
),
|
|
721
721
|
/* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { className: "flex items-center justify-between gap-3", children: [
|
|
722
722
|
/* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
723
|
-
|
|
723
|
+
_chunkOTGYA5F7cjs.ChatAttachmentAddButton,
|
|
724
724
|
{
|
|
725
725
|
attachmentsEnabled: !supportSystemDown,
|
|
726
726
|
attachmentsCount: attachments.length,
|
|
@@ -750,7 +750,7 @@ var _usesticktobottom = require('use-stick-to-bottom');
|
|
|
750
750
|
|
|
751
751
|
var LIST_ENGAGEMENTS_ENDPOINT = "/api/chat/agent/list-engagements";
|
|
752
752
|
function useTicketEngagements(externalTicketId, enabled = true) {
|
|
753
|
-
const identity =
|
|
753
|
+
const identity = _chunkOTGYA5F7cjs.useChatIdentity.call(void 0, );
|
|
754
754
|
const identityKey = _nullishCoalesce(_optionalChain([identity, 'access', _21 => _21.user, 'optionalAccess', _22 => _22.email]), () => ( "anon"));
|
|
755
755
|
const listEngagementsEndpoint = _nullishCoalesce(_chunkUJ7AXHRZcjs.useRequiredChatRuntime.call(void 0, ).endpoints.listEngagementsUrl, () => ( LIST_ENGAGEMENTS_ENDPOINT));
|
|
756
756
|
const fetchable = enabled && !!externalTicketId && !externalTicketId.startsWith("temp-");
|
|
@@ -823,7 +823,7 @@ function TicketLinkedDeliveryCard({ clickup, className }) {
|
|
|
823
823
|
dateClosed: clickup.date_closed,
|
|
824
824
|
clickupUrl: _nullishCoalesce(clickup.clickup_url, () => ( ""))
|
|
825
825
|
};
|
|
826
|
-
return /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "div", { className: `${_chunkUEULXVW2cjs.CONTENT_CARD_SKELETON_FRAME_CLASS} ${_nullishCoalesce(className, () => ( ""))}`, children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
826
|
+
return /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "div", { className: `${_chunkUEULXVW2cjs.CONTENT_CARD_SKELETON_FRAME_CLASS} ${_nullishCoalesce(className, () => ( ""))}`, children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkMOPDE3OAcjs.DeliveryRow, { item, href: clickup.delivery_href, caption: "Linked delivery" }) });
|
|
827
827
|
}
|
|
828
828
|
|
|
829
829
|
// src/components/tickets/ticket-reply-composer.tsx
|
|
@@ -838,7 +838,7 @@ function TicketReplyComposer({
|
|
|
838
838
|
}) {
|
|
839
839
|
const [resolution, setResolution] = _react.useState.call(void 0, "");
|
|
840
840
|
const [closeDialogOpen, setCloseDialogOpen] = _react.useState.call(void 0, false);
|
|
841
|
-
const attachments =
|
|
841
|
+
const attachments = _chunkOTGYA5F7cjs.useChatAttachments.call(void 0, );
|
|
842
842
|
const { readyAttachments, clear: clearAttachments } = attachments;
|
|
843
843
|
const ticketRef = { id: ticket.id, external_id: ticket.external_id };
|
|
844
844
|
const hasReadyFiles = readyAttachments.length > 0;
|
|
@@ -859,7 +859,7 @@ function TicketReplyComposer({
|
|
|
859
859
|
const disabled = busy || supportSystemDown;
|
|
860
860
|
return /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { className: "flex flex-col gap-2", children: [
|
|
861
861
|
/* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
862
|
-
|
|
862
|
+
_chunkOTGYA5F7cjs.ChatAttachmentChipStrip,
|
|
863
863
|
{
|
|
864
864
|
attachments: attachments.attachments,
|
|
865
865
|
onRemove: attachments.removeAttachment,
|
|
@@ -882,7 +882,7 @@ function TicketReplyComposer({
|
|
|
882
882
|
),
|
|
883
883
|
/* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { className: "flex w-full items-center gap-2", children: [
|
|
884
884
|
!supportSystemDown && /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
885
|
-
|
|
885
|
+
_chunkOTGYA5F7cjs.ChatAttachmentAddButton,
|
|
886
886
|
{
|
|
887
887
|
attachmentsEnabled: true,
|
|
888
888
|
attachmentsCount: attachments.attachments.length,
|
|
@@ -905,13 +905,13 @@ function TicketReplyComposer({
|
|
|
905
905
|
}
|
|
906
906
|
)
|
|
907
907
|
] }),
|
|
908
|
-
/* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
909
|
-
/* @__PURE__ */ _jsxruntime.jsxs.call(void 0,
|
|
910
|
-
/* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
911
|
-
/* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
908
|
+
/* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkBHJDQYUNcjs.AlertDialog, { open: closeDialogOpen, onOpenChange: setCloseDialogOpen, children: /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _chunkBHJDQYUNcjs.AlertDialogContent, { className: "border-ods-border bg-ods-card", children: [
|
|
909
|
+
/* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _chunkBHJDQYUNcjs.AlertDialogHeader, { children: [
|
|
910
|
+
/* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkBHJDQYUNcjs.AlertDialogTitle, { className: "text-ods-text-primary", children: "Close this ticket?" }),
|
|
911
|
+
/* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkBHJDQYUNcjs.AlertDialogDescription, { className: "text-ods-text-secondary", children: "Add an optional resolution note below. You can reopen the ticket later if needed." })
|
|
912
912
|
] }),
|
|
913
913
|
/* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
914
|
-
|
|
914
|
+
_chunkBHJDQYUNcjs.Textarea,
|
|
915
915
|
{
|
|
916
916
|
value: resolution,
|
|
917
917
|
onChange: (e) => setResolution(e.target.value),
|
|
@@ -921,9 +921,9 @@ function TicketReplyComposer({
|
|
|
921
921
|
className: "mt-2"
|
|
922
922
|
}
|
|
923
923
|
),
|
|
924
|
-
/* @__PURE__ */ _jsxruntime.jsxs.call(void 0,
|
|
924
|
+
/* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _chunkBHJDQYUNcjs.AlertDialogFooter, { children: [
|
|
925
925
|
/* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
926
|
-
|
|
926
|
+
_chunkBHJDQYUNcjs.AlertDialogCancel,
|
|
927
927
|
{
|
|
928
928
|
disabled: busy,
|
|
929
929
|
className: "border-ods-border bg-transparent text-ods-text-primary hover:bg-ods-border",
|
|
@@ -931,7 +931,7 @@ function TicketReplyComposer({
|
|
|
931
931
|
}
|
|
932
932
|
),
|
|
933
933
|
/* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
934
|
-
|
|
934
|
+
_chunkBHJDQYUNcjs.AlertDialogAction,
|
|
935
935
|
{
|
|
936
936
|
onClick: () => void confirmClose(),
|
|
937
937
|
disabled: busy,
|
|
@@ -993,11 +993,11 @@ var TICKET_FEED_HEIGHT = "h-[60vh] md:h-[420px]";
|
|
|
993
993
|
var TICKET_FEED_INNER = "flex flex-col gap-4 md:gap-6 px-4 md:px-6 py-4 md:py-6";
|
|
994
994
|
var TICKET_FEED_SKELETON_ROWS = 6;
|
|
995
995
|
function TicketTimelinePanel({ ticket }) {
|
|
996
|
-
const identity =
|
|
996
|
+
const identity = _chunkOTGYA5F7cjs.useChatIdentity.call(void 0, );
|
|
997
997
|
const runtime = _chunkUJ7AXHRZcjs.useChatRuntime.call(void 0, );
|
|
998
998
|
const externalId = isOptimistic(ticket) ? null : ticket.external_id;
|
|
999
999
|
const { engagements, isLoading } = useTicketEngagements(externalId, !!externalId);
|
|
1000
|
-
const live =
|
|
1000
|
+
const live = _chunkJQ3JZLYScjs.useOptionalTicketLive.call(void 0, );
|
|
1001
1001
|
const setOpenTicketId = _optionalChain([live, 'optionalAccess', _25 => _25.setOpenTicketId]);
|
|
1002
1002
|
const markRead = _optionalChain([live, 'optionalAccess', _26 => _26.markRead]);
|
|
1003
1003
|
const markReadDebounceRef = _react.useRef.call(void 0, null);
|
|
@@ -1036,7 +1036,7 @@ function TicketTimelinePanel({ ticket }) {
|
|
|
1036
1036
|
const customerName = (isViewerTheCustomer ? viewerName : null) || ticketCustomerName || viewerName || _optionalChain([identity, 'access', _40 => _40.user, 'optionalAccess', _41 => _41.email]) || "You";
|
|
1037
1037
|
const customerAvatar = isViewerTheCustomer ? _nullishCoalesce(_optionalChain([identity, 'access', _42 => _42.user, 'optionalAccess', _43 => _43.avatarUrl]), () => ( void 0)) : void 0;
|
|
1038
1038
|
if (isLoading) {
|
|
1039
|
-
return /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "div", { className: `${TICKET_FEED_FRAME} ${TICKET_FEED_HEIGHT}`, children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk2XCORRJVcjs.LoadingRegion, { label: "Loading messages", className: TICKET_FEED_INNER, children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk63A4GZMBcjs.LoadingItems, { count: TICKET_FEED_SKELETON_ROWS, children: () => /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
1039
|
+
return /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "div", { className: `${TICKET_FEED_FRAME} ${TICKET_FEED_HEIGHT}`, children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk2XCORRJVcjs.LoadingRegion, { label: "Loading messages", className: TICKET_FEED_INNER, children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk63A4GZMBcjs.LoadingItems, { count: TICKET_FEED_SKELETON_ROWS, children: () => /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkYAY7Z42Ccjs.ChatMessageRow, { loading: true, displayName: "", body: "", "data-loading-item": true }) }) }) });
|
|
1040
1040
|
}
|
|
1041
1041
|
if (bodyTurns.length === 0 && engagements.length === 0) {
|
|
1042
1042
|
return /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
@@ -1055,7 +1055,7 @@ function TicketTimelinePanel({ ticket }) {
|
|
|
1055
1055
|
const isResolution = turn.startsWith("[Resolution]");
|
|
1056
1056
|
const text = isResolution ? turn.replace(/^\[Resolution\]\s*/, "") : turn;
|
|
1057
1057
|
return /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
1058
|
-
|
|
1058
|
+
_chunkYAY7Z42Ccjs.ChatMessageRow,
|
|
1059
1059
|
{
|
|
1060
1060
|
"data-loading-item": true,
|
|
1061
1061
|
displayName: customerName,
|
|
@@ -1085,14 +1085,14 @@ function TicketTimelinePanel({ ticket }) {
|
|
|
1085
1085
|
}
|
|
1086
1086
|
const engAttachments = mapEngagementAttachments(eng.attachments, runtime);
|
|
1087
1087
|
return /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
1088
|
-
|
|
1088
|
+
_chunkYAY7Z42Ccjs.ChatMessageRow,
|
|
1089
1089
|
{
|
|
1090
1090
|
"data-loading-item": true,
|
|
1091
1091
|
displayName: author,
|
|
1092
1092
|
avatarUrl: avatarSrc,
|
|
1093
1093
|
timeLabel: eng.createdAt ? _chunkOBQ5WUNGcjs.formatRelativeTime.call(void 0, eng.createdAt) : null,
|
|
1094
1094
|
body: stripAttachmentsPreamble(_nullishCoalesce(eng.body, () => ( ""))),
|
|
1095
|
-
footer: engAttachments.length > 0 ? /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "div", { className: "mt-2", children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
1095
|
+
footer: engAttachments.length > 0 ? /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "div", { className: "mt-2", children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkBHJDQYUNcjs.TicketAttachmentsList, { attachments: engAttachments, size: "compact" }) }) : null
|
|
1096
1096
|
},
|
|
1097
1097
|
eng.id
|
|
1098
1098
|
);
|
|
@@ -1197,7 +1197,7 @@ var TICKET_ROW_FRAME_CLASS = "border-b border-ods-border last:border-b-0";
|
|
|
1197
1197
|
var TICKET_ROW_OUTER_CLASS = "scroll-mt-24";
|
|
1198
1198
|
function TicketRow(props) {
|
|
1199
1199
|
if (_chunk63A4GZMBcjs.useLoadingScope.call(void 0, ) || props.loading) {
|
|
1200
|
-
return /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "div", { id: props.id, className: TICKET_ROW_OUTER_CLASS, ..._chunk63A4GZMBcjs.loadingItemProps.call(void 0, props), children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "div", { className: TICKET_ROW_FRAME_CLASS, children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
1200
|
+
return /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "div", { id: props.id, className: TICKET_ROW_OUTER_CLASS, ..._chunk63A4GZMBcjs.loadingItemProps.call(void 0, props), children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "div", { className: TICKET_ROW_FRAME_CLASS, children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkYAY7Z42Ccjs.ChatTicketItem, { loading: true }) }) });
|
|
1201
1201
|
}
|
|
1202
1202
|
return /* @__PURE__ */ _jsxruntime.jsx.call(void 0, TicketRowLoaded, { ...props });
|
|
1203
1203
|
}
|
|
@@ -1252,7 +1252,7 @@ function TicketRowLoaded({
|
|
|
1252
1252
|
};
|
|
1253
1253
|
return /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "div", { ref: rowRef, id, className: TICKET_ROW_OUTER_CLASS, ..._chunk63A4GZMBcjs.loadingItemProps.call(void 0, markers), children: /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, Collapsible, { open: expanded && !optimistic, className: TICKET_ROW_FRAME_CLASS, children: [
|
|
1254
1254
|
/* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
1255
|
-
|
|
1255
|
+
_chunkYAY7Z42Ccjs.ChatTicketItem,
|
|
1256
1256
|
{
|
|
1257
1257
|
ticket: tileData,
|
|
1258
1258
|
onClick: optimistic ? void 0 : handleClick,
|
|
@@ -1291,7 +1291,7 @@ function TicketCenter({ toast: toast2 = _chunkT266OITJcjs.toast } = {}) {
|
|
|
1291
1291
|
return /* @__PURE__ */ _jsxruntime.jsx.call(void 0, TicketCenterGate, { toast: toast2 });
|
|
1292
1292
|
}
|
|
1293
1293
|
function TicketCenterGate({ toast: toast2 }) {
|
|
1294
|
-
const identity =
|
|
1294
|
+
const identity = _chunkOTGYA5F7cjs.useChatIdentity.call(void 0, );
|
|
1295
1295
|
if (identity.isLoading) {
|
|
1296
1296
|
return /* @__PURE__ */ _jsxruntime.jsx.call(void 0, TicketCenterPending, {});
|
|
1297
1297
|
}
|
|
@@ -1346,7 +1346,7 @@ function TicketCenterAuthed({
|
|
|
1346
1346
|
const toggleRow = _react.useCallback.call(void 0, (id) => {
|
|
1347
1347
|
setExpandedTicketId((prev) => prev === id ? null : id);
|
|
1348
1348
|
}, []);
|
|
1349
|
-
const syncInPage =
|
|
1349
|
+
const syncInPage = _chunkMOPDE3OAcjs.usePageDataSync.call(void 0, sync, isLoading);
|
|
1350
1350
|
const merged = [...optimisticTickets, ...tickets];
|
|
1351
1351
|
return /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
1352
1352
|
TicketCenterView,
|
|
@@ -1363,7 +1363,7 @@ function TicketCenterAuthed({
|
|
|
1363
1363
|
TicketRow,
|
|
1364
1364
|
{
|
|
1365
1365
|
"data-loading-item": true,
|
|
1366
|
-
id:
|
|
1366
|
+
id: _chunkYAY7Z42Ccjs.devSectionAnchorId.call(void 0, "ticket", ticket.external_id),
|
|
1367
1367
|
ticket,
|
|
1368
1368
|
expanded: expandedTicketId === ticket.id,
|
|
1369
1369
|
onToggle: toggleRow,
|
|
@@ -1382,8 +1382,8 @@ function TicketCenterAuthed({
|
|
|
1382
1382
|
function TicketCenterPending({
|
|
1383
1383
|
region = true
|
|
1384
1384
|
} = {}) {
|
|
1385
|
-
const syncInPage =
|
|
1386
|
-
return /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
1385
|
+
const syncInPage = _chunkMOPDE3OAcjs.usePageDataSync.call(void 0, null, true);
|
|
1386
|
+
return /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkOTGYA5F7cjs.LoadingFallback, { label: "Loading tickets", status: region, children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
1387
1387
|
TicketCenterView,
|
|
1388
1388
|
{
|
|
1389
1389
|
tickets: [],
|
|
@@ -1445,7 +1445,7 @@ function TicketListHeader({
|
|
|
1445
1445
|
return /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { className: "flex items-center justify-between gap-3", children: [
|
|
1446
1446
|
/* @__PURE__ */ _jsxruntime.jsx.call(void 0, "p", { className: "text-ods-text-secondary text-h5", children: "Your Current Tickets" }),
|
|
1447
1447
|
/* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { className: "flex items-center gap-3 text-ods-text-secondary text-h6", children: [
|
|
1448
|
-
sync !== void 0 && /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
1448
|
+
sync !== void 0 && /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkBHJDQYUNcjs.DataSyncLine, { sync, loading: syncLoading, inline: true }),
|
|
1449
1449
|
/* @__PURE__ */ _jsxruntime.jsx.call(void 0, "span", { inert: !onRefresh || void 0, "aria-hidden": !onRefresh || void 0, children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
1450
1450
|
_chunkFCZAUK4Dcjs.Button,
|
|
1451
1451
|
{
|
|
@@ -1480,7 +1480,7 @@ function HelpCenterCard(props) {
|
|
|
1480
1480
|
return /* @__PURE__ */ _jsxruntime.jsx.call(void 0, HelpCenterCardLoaded, { ...props });
|
|
1481
1481
|
}
|
|
1482
1482
|
function HelpCenterCardSkeleton({ id, ...props }) {
|
|
1483
|
-
return /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "div", { id, className: HELP_CENTER_ROW_CLASS, "aria-hidden": true, ..._chunk63A4GZMBcjs.loadingItemProps.call(void 0, props), children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "div", { className: HELP_CENTER_SUMMARY_PAD_CLASS, children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
1483
|
+
return /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "div", { id, className: HELP_CENTER_ROW_CLASS, "aria-hidden": true, ..._chunk63A4GZMBcjs.loadingItemProps.call(void 0, props), children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "div", { className: HELP_CENTER_SUMMARY_PAD_CLASS, children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkMOPDE3OAcjs.DevCardRowContent, { loading: true, title: "", subtitle: "", description: "", rightBadges: null }) }) });
|
|
1484
1484
|
}
|
|
1485
1485
|
function HelpCenterCardLoaded({
|
|
1486
1486
|
ticket,
|
|
@@ -1519,7 +1519,7 @@ function HelpCenterCardLoaded({
|
|
|
1519
1519
|
});
|
|
1520
1520
|
return () => cancelAnimationFrame(raf);
|
|
1521
1521
|
}, [isExpanded]);
|
|
1522
|
-
const live =
|
|
1522
|
+
const live = _chunkJQ3JZLYScjs.useOptionalTicketLive.call(void 0, );
|
|
1523
1523
|
const unreadCount = !optimistic && ticket.external_id && _optionalChain([live, 'optionalAccess', _64 => _64.unreadByTicket, 'access', _65 => _65[ticket.external_id]]) || 0;
|
|
1524
1524
|
const rightBadges = /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _jsxruntime.Fragment, { children: [
|
|
1525
1525
|
unreadCount > 0 && // Only rows with unread replies carry it; the row's loading form draws the status badge alone.
|
|
@@ -1574,7 +1574,7 @@ function HelpCenterCardLoaded({
|
|
|
1574
1574
|
"aria-expanded": isExpandable ? isExpanded : void 0,
|
|
1575
1575
|
"aria-controls": isExpanded ? `help-center-drawer-${ticket.id}` : void 0,
|
|
1576
1576
|
children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "span", { className: _chunk63A4GZMBcjs.cn.call(void 0, "block", HELP_CENTER_SUMMARY_PAD_CLASS), children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
1577
|
-
|
|
1577
|
+
_chunkMOPDE3OAcjs.DevCardRowContent,
|
|
1578
1578
|
{
|
|
1579
1579
|
title,
|
|
1580
1580
|
subtitle,
|
|
@@ -1655,7 +1655,7 @@ function HelpCenterCreateFormBody({
|
|
|
1655
1655
|
subjectError && /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "span", { id: "help-center-subject-error", className: "mt-1 text-ods-error text-h6", children: subjectError })
|
|
1656
1656
|
] });
|
|
1657
1657
|
return /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
1658
|
-
|
|
1658
|
+
_chunk7X7PHALXcjs.ContactForm,
|
|
1659
1659
|
{
|
|
1660
1660
|
rescue: null,
|
|
1661
1661
|
title: "Open a new ticket",
|
|
@@ -1695,17 +1695,17 @@ function HelpCenterCreateFormBody({
|
|
|
1695
1695
|
// src/components/tickets/help-center-list.tsx
|
|
1696
1696
|
|
|
1697
1697
|
function HelpCenterList({ toast: toast2 = _chunkT266OITJcjs.toast, backButton, title, shell } = {}) {
|
|
1698
|
-
const identity =
|
|
1698
|
+
const identity = _chunkOTGYA5F7cjs.useChatIdentity.call(void 0, );
|
|
1699
1699
|
const searchParams = _chunk7DNL734Scjs.useSearchParams.call(void 0, );
|
|
1700
1700
|
const router = _chunk7DNL734Scjs.useRouter.call(void 0, );
|
|
1701
1701
|
const pathname = _chunk7DNL734Scjs.usePathname.call(void 0, );
|
|
1702
|
-
const search = searchParams.get(
|
|
1702
|
+
const search = searchParams.get(_chunkYAY7Z42Ccjs.DEV_SECTION_PARAM_KEYS.search) || "";
|
|
1703
1703
|
const status = searchParams.get("status") || "all";
|
|
1704
|
-
const ticketParam = searchParams.get(
|
|
1704
|
+
const ticketParam = searchParams.get(_chunkYAY7Z42Ccjs.TICKET_OPEN_PARAM) || "";
|
|
1705
1705
|
const page = _chunkBLH2SFOOcjs.positiveInt.call(void 0, searchParams.get("page"), 1);
|
|
1706
1706
|
if (identity.isLoading) {
|
|
1707
1707
|
return /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
1708
|
-
|
|
1708
|
+
_chunkMOPDE3OAcjs.DevSectionPage,
|
|
1709
1709
|
{
|
|
1710
1710
|
sectionKey: "tickets",
|
|
1711
1711
|
backButton,
|
|
@@ -1717,7 +1717,7 @@ function HelpCenterList({ toast: toast2 = _chunkT266OITJcjs.toast, backButton, t
|
|
|
1717
1717
|
);
|
|
1718
1718
|
}
|
|
1719
1719
|
if (identity.authTier === "anon" || !_optionalChain([identity, 'access', _66 => _66.user, 'optionalAccess', _67 => _67.email])) {
|
|
1720
|
-
return /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
1720
|
+
return /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkMOPDE3OAcjs.DevSectionPage, { sectionKey: "tickets", backButton, title, shell, children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
1721
1721
|
_chunkSBFBNOKUcjs.EmptyState,
|
|
1722
1722
|
{
|
|
1723
1723
|
type: "generic",
|
|
@@ -1769,8 +1769,8 @@ function HelpCenterListAuthed({
|
|
|
1769
1769
|
const setOpenTicket = _react.useCallback.call(void 0,
|
|
1770
1770
|
(externalId) => {
|
|
1771
1771
|
const params = new URLSearchParams(searchParams.toString());
|
|
1772
|
-
if (externalId) params.set(
|
|
1773
|
-
else params.delete(
|
|
1772
|
+
if (externalId) params.set(_chunkYAY7Z42Ccjs.TICKET_OPEN_PARAM, externalId);
|
|
1773
|
+
else params.delete(_chunkYAY7Z42Ccjs.TICKET_OPEN_PARAM);
|
|
1774
1774
|
const qs = params.toString();
|
|
1775
1775
|
router.replace(qs ? `${pathname}?${qs}` : pathname, { scroll: false });
|
|
1776
1776
|
},
|
|
@@ -1848,7 +1848,7 @@ function HelpCenterListAuthed({
|
|
|
1848
1848
|
/* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkFCZAUK4Dcjs.Button, { type: "button", variant: "accent", onClick: () => refetch(), children: "Retry" })
|
|
1849
1849
|
] }),
|
|
1850
1850
|
!error && /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "div", { className: "w-full", children: isLoading || !hasResults && isFetching ? /* @__PURE__ */ _jsxruntime.jsx.call(void 0, HelpCenterRowsFrame, { children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk63A4GZMBcjs.LoadingItems, { count: pageSize, children: () => /* @__PURE__ */ _jsxruntime.jsx.call(void 0, HelpCenterCard, { ticket: null, "data-loading-item": true }) }) }) : !hasResults ? /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
1851
|
-
|
|
1851
|
+
_chunkMOPDE3OAcjs.ListEmptyState,
|
|
1852
1852
|
{
|
|
1853
1853
|
isFiltered: hasActiveFilters,
|
|
1854
1854
|
filtered: {
|
|
@@ -1871,7 +1871,7 @@ function HelpCenterListAuthed({
|
|
|
1871
1871
|
HelpCenterCard,
|
|
1872
1872
|
{
|
|
1873
1873
|
"data-loading-item": true,
|
|
1874
|
-
id:
|
|
1874
|
+
id: _chunkYAY7Z42Ccjs.devSectionAnchorId.call(void 0, "ticket", ticket.external_id),
|
|
1875
1875
|
ticket,
|
|
1876
1876
|
expanded: expandedTicketId === ticket.id,
|
|
1877
1877
|
onToggle: toggleRow,
|
|
@@ -1888,7 +1888,7 @@ function HelpCenterListAuthed({
|
|
|
1888
1888
|
)) }) }),
|
|
1889
1889
|
!error && totalPages > 1 && /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkSBFBNOKUcjs.UnifiedPagination, { currentPage: page, totalPages })
|
|
1890
1890
|
] });
|
|
1891
|
-
return /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
1891
|
+
return /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkMOPDE3OAcjs.DevSectionPage, { sectionKey: "tickets", backButton, title, shell, preControls: form, children: body });
|
|
1892
1892
|
}
|
|
1893
1893
|
function HelpCenterRowsFrame({ children }) {
|
|
1894
1894
|
return /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "div", { className: "w-full overflow-clip rounded-[6px] border border-ods-border bg-ods-card", children });
|
|
@@ -1,10 +1,10 @@
|
|
|
1
1
|
"use strict";Object.defineProperty(exports, "__esModule", {value: true}); function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; } function _nullishCoalesce(lhs, rhsFn) { if (lhs != null) { return lhs; } else { return rhsFn(); } } function _optionalChain(ops) { let lastAccessLHS = undefined; let value = ops[0]; let i = 1; while (i < ops.length) { const op = ops[i]; const fn = ops[i + 1]; i += 2; if ((op === 'optionalAccess' || op === 'optionalCall') && value == null) { return undefined; } if (op === 'access' || op === 'optionalAccess') { lastAccessLHS = value; value = fn(value); } else if (op === 'call' || op === 'optionalCall') { value = fn((...args) => value.call(lastAccessLHS, ...args)); lastAccessLHS = undefined; } } return value; }"use client";
|
|
2
2
|
|
|
3
3
|
|
|
4
|
-
var
|
|
4
|
+
var _chunkYAY7Z42Ccjs = require('./chunk-YAY7Z42C.cjs');
|
|
5
5
|
|
|
6
6
|
|
|
7
|
-
var
|
|
7
|
+
var _chunkOTGYA5F7cjs = require('./chunk-OTGYA5F7.cjs');
|
|
8
8
|
|
|
9
9
|
|
|
10
10
|
var _chunkGI3MMBP3cjs = require('./chunk-GI3MMBP3.cjs');
|
|
@@ -44,7 +44,7 @@ function isSummaryData(value) {
|
|
|
44
44
|
}
|
|
45
45
|
function TicketLiveProvider({ children, enabled = true }) {
|
|
46
46
|
const runtime = _chunkUJ7AXHRZcjs.useChatRuntime.call(void 0, );
|
|
47
|
-
const identity =
|
|
47
|
+
const identity = _chunkOTGYA5F7cjs.useChatIdentity.call(void 0, enabled);
|
|
48
48
|
const queryClient = _reactquery.useQueryClient.call(void 0, );
|
|
49
49
|
const streamUrl = _nullishCoalesce(_optionalChain([runtime, 'optionalAccess', _ => _.endpoints, 'access', _2 => _2.ticketStreamUrl]), () => ( TICKET_STREAM_ENDPOINT));
|
|
50
50
|
const readUrl = _nullishCoalesce(_optionalChain([runtime, 'optionalAccess', _3 => _3.endpoints, 'access', _4 => _4.ticketReadUrl]), () => ( TICKET_READ_ENDPOINT));
|
|
@@ -160,7 +160,7 @@ function TicketLiveProvider({ children, enabled = true }) {
|
|
|
160
160
|
_react2.default.useEffect(() => {
|
|
161
161
|
if (!streamEnabled) return void 0;
|
|
162
162
|
if (typeof window === "undefined") return void 0;
|
|
163
|
-
subscriptionRef.current =
|
|
163
|
+
subscriptionRef.current = _chunkYAY7Z42Ccjs.createSseSubscription.call(void 0, {
|
|
164
164
|
url: streamUrl,
|
|
165
165
|
onEvent: (name, data) => handlersRef.current.onEvent(name, data),
|
|
166
166
|
onStatusChange: (status) => handlersRef.current.onStatus(status),
|
|
@@ -1,13 +1,13 @@
|
|
|
1
1
|
"use strict";Object.defineProperty(exports, "__esModule", {value: true}); function _nullishCoalesce(lhs, rhsFn) { if (lhs != null) { return lhs; } else { return rhsFn(); } } function _optionalChain(ops) { let lastAccessLHS = undefined; let value = ops[0]; let i = 1; while (i < ops.length) { const op = ops[i]; const fn = ops[i + 1]; i += 2; if ((op === 'optionalAccess' || op === 'optionalCall') && value == null) { return undefined; } if (op === 'access' || op === 'optionalAccess') { lastAccessLHS = value; value = fn(value); } else if (op === 'call' || op === 'optionalCall') { value = fn((...args) => value.call(lastAccessLHS, ...args)); lastAccessLHS = undefined; } } return value; }"use client";
|
|
2
2
|
|
|
3
3
|
|
|
4
|
-
var
|
|
4
|
+
var _chunkBHJDQYUNcjs = require('./chunk-BHJDQYUN.cjs');
|
|
5
5
|
|
|
6
6
|
|
|
7
7
|
|
|
8
8
|
|
|
9
9
|
|
|
10
|
-
var
|
|
10
|
+
var _chunkOTGYA5F7cjs = require('./chunk-OTGYA5F7.cjs');
|
|
11
11
|
|
|
12
12
|
|
|
13
13
|
|
|
@@ -37,7 +37,7 @@ var _jsxruntime = require('react/jsx-runtime');
|
|
|
37
37
|
function DocSearchResultRow({ result, isHighlighted }) {
|
|
38
38
|
const docType = _optionalChain([result, 'access', _ => _.metadata, 'optionalAccess', _2 => _2.documentType]) || void 0;
|
|
39
39
|
const sourceRepo = _optionalChain([result, 'access', _3 => _3.metadata, 'optionalAccess', _4 => _4.sourceRepo]) || void 0;
|
|
40
|
-
const { Icon: SourceIcon, label: iconLabel } =
|
|
40
|
+
const { Icon: SourceIcon, label: iconLabel } = _chunkOTGYA5F7cjs.resolveSourceIcon.call(void 0, {
|
|
41
41
|
sourceRepo,
|
|
42
42
|
documentType: docType
|
|
43
43
|
});
|
|
@@ -67,7 +67,7 @@ function DocSearchBar({
|
|
|
67
67
|
renderResult
|
|
68
68
|
}) {
|
|
69
69
|
return /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
70
|
-
|
|
70
|
+
_chunkBHJDQYUNcjs.SearchInput,
|
|
71
71
|
{
|
|
72
72
|
placeholder,
|
|
73
73
|
value: query,
|
|
@@ -117,7 +117,7 @@ function mapDocSearchResults(docs) {
|
|
|
117
117
|
results.push({
|
|
118
118
|
id: `group-${entry.repo}`,
|
|
119
119
|
// Same table label and count as the chat's grouped chip: one owner each.
|
|
120
|
-
title: `${
|
|
120
|
+
title: `${_chunkOTGYA5F7cjs.getSourceLabel.call(void 0, entry.repo)} ${_chunkOTGYA5F7cjs.recordCountLabel.call(void 0, rows.length)}`,
|
|
121
121
|
path: rows[0].path,
|
|
122
122
|
type: "file",
|
|
123
123
|
metadata: {
|
|
@@ -316,7 +316,7 @@ function useDocSearch(config) {
|
|
|
316
316
|
}
|
|
317
317
|
case "ask-ai":
|
|
318
318
|
setKeepOpen(false);
|
|
319
|
-
window.dispatchEvent(new CustomEvent(
|
|
319
|
+
window.dispatchEvent(new CustomEvent(_chunkOTGYA5F7cjs.ASK_AI_OPEN_WITH_REF_EVENT, { detail: action.detail }));
|
|
320
320
|
return;
|
|
321
321
|
case "route":
|
|
322
322
|
setKeepOpen(false);
|
|
@@ -5,7 +5,7 @@ var _chunkSBFBNOKUcjs = require('./chunk-SBFBNOKU.cjs');
|
|
|
5
5
|
|
|
6
6
|
|
|
7
7
|
|
|
8
|
-
var
|
|
8
|
+
var _chunkSTFOH6QUcjs = require('./chunk-STFOH6QU.cjs');
|
|
9
9
|
|
|
10
10
|
|
|
11
11
|
|
|
@@ -15,7 +15,7 @@ var _chunkHEVW75L3cjs = require('./chunk-HEVW75L3.cjs');
|
|
|
15
15
|
|
|
16
16
|
|
|
17
17
|
|
|
18
|
-
var
|
|
18
|
+
var _chunkBHJDQYUNcjs = require('./chunk-BHJDQYUN.cjs');
|
|
19
19
|
|
|
20
20
|
|
|
21
21
|
var _chunkIJCSQFLDcjs = require('./chunk-IJCSQFLD.cjs');
|
|
@@ -26,7 +26,7 @@ var _chunkIJCSQFLDcjs = require('./chunk-IJCSQFLD.cjs');
|
|
|
26
26
|
var _chunk7DNL734Scjs = require('./chunk-7DNL734S.cjs');
|
|
27
27
|
|
|
28
28
|
|
|
29
|
-
var
|
|
29
|
+
var _chunkYAY7Z42Ccjs = require('./chunk-YAY7Z42C.cjs');
|
|
30
30
|
|
|
31
31
|
|
|
32
32
|
|
|
@@ -105,7 +105,7 @@ function PageDataSyncProvider({
|
|
|
105
105
|
function PageDataSyncRow({ inline = false }) {
|
|
106
106
|
const context = _react.useContext.call(void 0, PageDataSyncContext);
|
|
107
107
|
if (!context) return null;
|
|
108
|
-
const line = /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
108
|
+
const line = /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkBHJDQYUNcjs.DataSyncLine, { sync: context.state.sync, loading: context.state.loading, stated: context.stated, inline });
|
|
109
109
|
return context.stated ? line : /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "div", { className: "contents", "data-loading-optional": "", children: line });
|
|
110
110
|
}
|
|
111
111
|
function usePageDataSync(sync, loading) {
|
|
@@ -124,7 +124,7 @@ function usePageDataSync(sync, loading) {
|
|
|
124
124
|
// src/components/shared/dev-section/dev-section-view.tsx
|
|
125
125
|
|
|
126
126
|
function DevSectionView({ sectionKey, preControls, children, showHeading = true }) {
|
|
127
|
-
const section =
|
|
127
|
+
const section = _chunkYAY7Z42Ccjs.OPENFRAME_DEV_SECTIONS[sectionKey];
|
|
128
128
|
const router = _chunk7DNL734Scjs.useRouter.call(void 0, );
|
|
129
129
|
const pathname = _chunk7DNL734Scjs.usePathname.call(void 0, );
|
|
130
130
|
const searchParams = _chunk7DNL734Scjs.useSearchParams.call(void 0, );
|
|
@@ -166,7 +166,7 @@ function DevSectionView({ sectionKey, preControls, children, showHeading = true
|
|
|
166
166
|
preControls,
|
|
167
167
|
(search || filter) && /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { className: "space-y-4", children: [
|
|
168
168
|
search && /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
169
|
-
|
|
169
|
+
_chunkBHJDQYUNcjs.SearchInput,
|
|
170
170
|
{
|
|
171
171
|
showDropdown: false,
|
|
172
172
|
placeholder: search.placeholder,
|
|
@@ -176,7 +176,7 @@ function DevSectionView({ sectionKey, preControls, children, showHeading = true
|
|
|
176
176
|
}
|
|
177
177
|
),
|
|
178
178
|
filter && /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
179
|
-
|
|
179
|
+
_chunkBHJDQYUNcjs.StatusFilterComponent,
|
|
180
180
|
{
|
|
181
181
|
selectedStatus: currentFilterValue,
|
|
182
182
|
onStatusChange: handleFilterChange,
|
|
@@ -201,7 +201,7 @@ function DevSectionPage({
|
|
|
201
201
|
shell = true
|
|
202
202
|
}) {
|
|
203
203
|
const router = _chunk7DNL734Scjs.useRouter.call(void 0, );
|
|
204
|
-
const section =
|
|
204
|
+
const section = _chunkYAY7Z42Ccjs.OPENFRAME_DEV_SECTIONS[sectionKey];
|
|
205
205
|
const backCfg = backButton === false ? void 0 : {
|
|
206
206
|
label: _nullishCoalesce((backButton ? backButton.label : void 0), () => ( "Back to home")),
|
|
207
207
|
onClick: () => router.push(_nullishCoalesce((backButton ? backButton.href : void 0), () => ( "/")))
|
|
@@ -223,12 +223,12 @@ function DevSectionPage({
|
|
|
223
223
|
backButton: backCfg,
|
|
224
224
|
children: [
|
|
225
225
|
/* @__PURE__ */ _jsxruntime.jsx.call(void 0, DevSectionView, { sectionKey, showHeading: false, preControls, children }),
|
|
226
|
-
faq && /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
226
|
+
faq && /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkSTFOH6QUcjs.FaqSection, { ..._chunkSTFOH6QUcjs.pageFaqProps.call(void 0, faq) })
|
|
227
227
|
]
|
|
228
228
|
}
|
|
229
229
|
)
|
|
230
230
|
);
|
|
231
|
-
return shell ? /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
231
|
+
return shell ? /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkBHJDQYUNcjs.PageShell, { children: inner }) : /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "div", { className: "page-shell-content", children: inner });
|
|
232
232
|
}
|
|
233
233
|
|
|
234
234
|
// src/components/shared/dev-section/dev-card-row.tsx
|