@flamingo-stack/openframe-frontend-core 0.0.253 → 0.0.254
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-E7LM7TPK.cjs → chunk-65JN25VM.cjs} +25 -25
- package/dist/{chunk-E7LM7TPK.cjs.map → chunk-65JN25VM.cjs.map} +1 -1
- package/dist/{chunk-N37WSTB7.js → chunk-BE472J6X.js} +2 -2
- package/dist/{chunk-4WFV4OTE.js → chunk-CAPVFI5A.js} +2 -2
- package/dist/{chunk-TNC2OENX.cjs → chunk-HYJ5IV4Z.cjs} +11 -11
- package/dist/{chunk-TNC2OENX.cjs.map → chunk-HYJ5IV4Z.cjs.map} +1 -1
- package/dist/{chunk-IA6B3HHQ.js → chunk-NP5U35FA.js} +53 -29
- package/dist/chunk-NP5U35FA.js.map +1 -0
- package/dist/{chunk-AXCLUHMQ.js → chunk-QCRQNKRO.js} +2 -2
- package/dist/{chunk-YEWZVXKX.cjs → chunk-TSY72CQ6.cjs} +28 -28
- package/dist/{chunk-YEWZVXKX.cjs.map → chunk-TSY72CQ6.cjs.map} +1 -1
- package/dist/{chunk-44UP5DJB.cjs → chunk-ZITMX2IQ.cjs} +53 -29
- package/dist/chunk-ZITMX2IQ.cjs.map +1 -0
- package/dist/components/chat/index.cjs +2 -2
- package/dist/components/chat/index.js +1 -1
- package/dist/components/contact/index.cjs +3 -3
- package/dist/components/contact/index.js +2 -2
- package/dist/components/features/index.cjs +2 -2
- package/dist/components/features/index.js +1 -1
- package/dist/components/index.cjs +49 -49
- package/dist/components/index.js +3 -3
- package/dist/components/navigation/index.cjs +2 -2
- package/dist/components/navigation/index.js +1 -1
- package/dist/components/related-content/index.cjs +3 -3
- package/dist/components/related-content/index.js +2 -2
- package/dist/components/tickets/index.cjs +55 -55
- package/dist/components/tickets/index.js +3 -3
- package/dist/components/ui/index.cjs +2 -2
- package/dist/components/ui/index.js +1 -1
- package/dist/components/ui/info-card.d.ts +16 -1
- package/dist/components/ui/info-card.d.ts.map +1 -1
- package/dist/index.cjs +2 -2
- package/dist/index.js +1 -1
- package/package.json +1 -1
- package/src/components/ui/info-card.tsx +87 -42
- package/src/stories/InfoCard.stories.tsx +60 -5
- package/dist/chunk-44UP5DJB.cjs.map +0 -1
- package/dist/chunk-IA6B3HHQ.js.map +0 -1
- /package/dist/{chunk-N37WSTB7.js.map → chunk-BE472J6X.js.map} +0 -0
- /package/dist/{chunk-4WFV4OTE.js.map → chunk-CAPVFI5A.js.map} +0 -0
- /package/dist/{chunk-AXCLUHMQ.js.map → chunk-QCRQNKRO.js.map} +0 -0
package/dist/components/index.js
CHANGED
|
@@ -6,7 +6,7 @@ import {
|
|
|
6
6
|
} from "../chunk-MKVKVJQQ.js";
|
|
7
7
|
import {
|
|
8
8
|
RelatedContentSection
|
|
9
|
-
} from "../chunk-
|
|
9
|
+
} from "../chunk-BE472J6X.js";
|
|
10
10
|
import {
|
|
11
11
|
DeliveryRow,
|
|
12
12
|
DevCardRowContent,
|
|
@@ -18,7 +18,7 @@ import {
|
|
|
18
18
|
UnifiedPagination,
|
|
19
19
|
init_unified_pagination,
|
|
20
20
|
unified_pagination_exports
|
|
21
|
-
} from "../chunk-
|
|
21
|
+
} from "../chunk-CAPVFI5A.js";
|
|
22
22
|
import {
|
|
23
23
|
DetailPageSkeleton,
|
|
24
24
|
DocSearchBar,
|
|
@@ -604,7 +604,7 @@ import {
|
|
|
604
604
|
useThemeToggle,
|
|
605
605
|
useUnifiedChat,
|
|
606
606
|
usesCanonicalStatusStyle
|
|
607
|
-
} from "../chunk-
|
|
607
|
+
} from "../chunk-NP5U35FA.js";
|
|
608
608
|
import {
|
|
609
609
|
CommandApprovalToast,
|
|
610
610
|
ToastCard,
|
|
@@ -26,7 +26,7 @@
|
|
|
26
26
|
|
|
27
27
|
|
|
28
28
|
|
|
29
|
-
var
|
|
29
|
+
var _chunkZITMX2IQcjs = require('../../chunk-ZITMX2IQ.cjs');
|
|
30
30
|
require('../../chunk-ELF4OOHC.cjs');
|
|
31
31
|
require('../../chunk-27APPAJN.cjs');
|
|
32
32
|
require('../../chunk-SGJBUL2Y.cjs');
|
|
@@ -72,5 +72,5 @@ require('../../chunk-VRHGVLSL.cjs');
|
|
|
72
72
|
|
|
73
73
|
|
|
74
74
|
|
|
75
|
-
exports.AppHeader =
|
|
75
|
+
exports.AppHeader = _chunkZITMX2IQcjs.AppHeader; exports.AppLayout = _chunkZITMX2IQcjs.AppLayout; exports.AppLayoutDrawer = _chunkZITMX2IQcjs.AppLayoutDrawerRoot; exports.AppLayoutDrawerBody = _chunkZITMX2IQcjs.AppLayoutDrawerBody; exports.AppLayoutDrawerClose = _chunkZITMX2IQcjs.AppLayoutDrawerClose; exports.AppLayoutDrawerContent = _chunkZITMX2IQcjs.AppLayoutDrawerContent; exports.AppLayoutDrawerDescription = _chunkZITMX2IQcjs.AppLayoutDrawerDescription; exports.AppLayoutDrawerFooter = _chunkZITMX2IQcjs.AppLayoutDrawerFooter; exports.AppLayoutDrawerHeader = _chunkZITMX2IQcjs.AppLayoutDrawerHeader; exports.AppLayoutDrawerTitle = _chunkZITMX2IQcjs.AppLayoutDrawerTitle; exports.AppLayoutDrawerTrigger = _chunkZITMX2IQcjs.AppLayoutDrawerTrigger; exports.ClientOnlyHeader = _chunkZITMX2IQcjs.ClientOnlyHeader; exports.Header = _chunkZITMX2IQcjs.Header; exports.HeaderButton = _chunkZITMX2IQcjs.HeaderButton; exports.HeaderGlobalSearch = _chunkZITMX2IQcjs.HeaderGlobalSearch; exports.HeaderMingoButton = _chunkZITMX2IQcjs.HeaderMingoButton; exports.HeaderOrganizationFilter = _chunkZITMX2IQcjs.HeaderOrganizationFilter; exports.HeaderSkeleton = _chunkZITMX2IQcjs.HeaderSkeleton; exports.MobileBurgerMenu = _chunkZITMX2IQcjs.MobileBurgerMenu; exports.MobileNavPanel = _chunkZITMX2IQcjs.MobileNavPanel; exports.NavigationSidebar = _chunkZITMX2IQcjs.NavigationSidebar; exports.SlidingSidebar = _chunkZITMX2IQcjs.SlidingSidebar; exports.StickySectionNav = _chunkZITMX2IQcjs.StickySectionNav; exports.useAppLayoutDrawerContainer = _chunkZITMX2IQcjs.useAppLayoutDrawerContainer; exports.useSectionNavigation = _chunkZITMX2IQcjs.useSectionNavigation;
|
|
76
76
|
//# sourceMappingURL=index.cjs.map
|
|
@@ -26,7 +26,7 @@ import {
|
|
|
26
26
|
StickySectionNav,
|
|
27
27
|
useAppLayoutDrawerContainer,
|
|
28
28
|
useSectionNavigation
|
|
29
|
-
} from "../../chunk-
|
|
29
|
+
} from "../../chunk-NP5U35FA.js";
|
|
30
30
|
import "../../chunk-4RDJZIHW.js";
|
|
31
31
|
import "../../chunk-MJNXIEV2.js";
|
|
32
32
|
import "../../chunk-VAUI3CND.js";
|
|
@@ -1,9 +1,9 @@
|
|
|
1
1
|
"use strict";Object.defineProperty(exports, "__esModule", {value: true});"use client";
|
|
2
2
|
|
|
3
3
|
|
|
4
|
-
var
|
|
4
|
+
var _chunkTSY72CQ6cjs = require('../../chunk-TSY72CQ6.cjs');
|
|
5
5
|
require('../../chunk-T7AJBKZP.cjs');
|
|
6
|
-
require('../../chunk-
|
|
6
|
+
require('../../chunk-ZITMX2IQ.cjs');
|
|
7
7
|
require('../../chunk-ELF4OOHC.cjs');
|
|
8
8
|
require('../../chunk-27APPAJN.cjs');
|
|
9
9
|
require('../../chunk-SGJBUL2Y.cjs');
|
|
@@ -25,5 +25,5 @@ require('../../chunk-XQFFGR6U.cjs');
|
|
|
25
25
|
require('../../chunk-VRHGVLSL.cjs');
|
|
26
26
|
|
|
27
27
|
|
|
28
|
-
exports.RelatedContentSection =
|
|
28
|
+
exports.RelatedContentSection = _chunkTSY72CQ6cjs.RelatedContentSection;
|
|
29
29
|
//# sourceMappingURL=index.cjs.map
|
|
@@ -1,9 +1,9 @@
|
|
|
1
1
|
"use client";
|
|
2
2
|
import {
|
|
3
3
|
RelatedContentSection
|
|
4
|
-
} from "../../chunk-
|
|
4
|
+
} from "../../chunk-BE472J6X.js";
|
|
5
5
|
import "../../chunk-L4LAAA5Q.js";
|
|
6
|
-
import "../../chunk-
|
|
6
|
+
import "../../chunk-NP5U35FA.js";
|
|
7
7
|
import "../../chunk-4RDJZIHW.js";
|
|
8
8
|
import "../../chunk-MJNXIEV2.js";
|
|
9
9
|
import "../../chunk-VAUI3CND.js";
|
|
@@ -7,11 +7,11 @@
|
|
|
7
7
|
|
|
8
8
|
|
|
9
9
|
|
|
10
|
-
var
|
|
10
|
+
var _chunkHYJ5IV4Zcjs = require('../../chunk-HYJ5IV4Z.cjs');
|
|
11
11
|
require('../../chunk-VFKQMAUF.cjs');
|
|
12
12
|
|
|
13
13
|
|
|
14
|
-
var
|
|
14
|
+
var _chunk65JN25VMcjs = require('../../chunk-65JN25VM.cjs');
|
|
15
15
|
|
|
16
16
|
|
|
17
17
|
|
|
@@ -36,7 +36,7 @@ var _chunkE7LM7TPKcjs = require('../../chunk-E7LM7TPK.cjs');
|
|
|
36
36
|
|
|
37
37
|
|
|
38
38
|
|
|
39
|
-
var
|
|
39
|
+
var _chunkZITMX2IQcjs = require('../../chunk-ZITMX2IQ.cjs');
|
|
40
40
|
|
|
41
41
|
|
|
42
42
|
var _chunkELF4OOHCcjs = require('../../chunk-ELF4OOHC.cjs');
|
|
@@ -109,7 +109,7 @@ function TicketOpenForm({
|
|
|
109
109
|
}) {
|
|
110
110
|
const [subject, setSubject] = _react.useState.call(void 0, "");
|
|
111
111
|
const [content, setContent] = _react.useState.call(void 0, "");
|
|
112
|
-
const { attachments, readyAttachments, hasInflightUploads, addFiles, removeAttachment, clear } =
|
|
112
|
+
const { attachments, readyAttachments, hasInflightUploads, addFiles, removeAttachment, clear } = _chunkZITMX2IQcjs.useChatAttachments.call(void 0, );
|
|
113
113
|
const trimmedSubject = subject.trim();
|
|
114
114
|
const trimmedContent = content.trim();
|
|
115
115
|
const overCap = content.length > TICKET_TEXT_MAX_CHARS;
|
|
@@ -168,7 +168,7 @@ function TicketOpenForm({
|
|
|
168
168
|
}
|
|
169
169
|
),
|
|
170
170
|
/* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
171
|
-
|
|
171
|
+
_chunkZITMX2IQcjs.Textarea,
|
|
172
172
|
{
|
|
173
173
|
id: "ticket-content",
|
|
174
174
|
placeholder: "Describe your issue or question in detail...",
|
|
@@ -192,7 +192,7 @@ function TicketOpenForm({
|
|
|
192
192
|
)
|
|
193
193
|
] }),
|
|
194
194
|
/* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
195
|
-
|
|
195
|
+
_chunkZITMX2IQcjs.ChatAttachmentChipStrip,
|
|
196
196
|
{
|
|
197
197
|
attachments,
|
|
198
198
|
onRemove: removeAttachment,
|
|
@@ -201,7 +201,7 @@ function TicketOpenForm({
|
|
|
201
201
|
),
|
|
202
202
|
/* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { className: "flex items-center justify-between gap-3", children: [
|
|
203
203
|
/* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
204
|
-
|
|
204
|
+
_chunkZITMX2IQcjs.ChatAttachmentAddButton,
|
|
205
205
|
{
|
|
206
206
|
attachmentsEnabled: !supportSystemDown,
|
|
207
207
|
attachmentsCount: attachments.length,
|
|
@@ -239,7 +239,7 @@ var _usesticktobottom = require('use-stick-to-bottom');
|
|
|
239
239
|
|
|
240
240
|
var LIST_ENGAGEMENTS_ENDPOINT = "/api/chat/agent/list-engagements";
|
|
241
241
|
function useTicketEngagements(externalTicketId, enabled = true, refetchInterval = false) {
|
|
242
|
-
const identity =
|
|
242
|
+
const identity = _chunkZITMX2IQcjs.useChatIdentity.call(void 0, );
|
|
243
243
|
const identityKey = _nullishCoalesce(_optionalChain([identity, 'access', _2 => _2.user, 'optionalAccess', _3 => _3.email]), () => ( "anon"));
|
|
244
244
|
const fetchable = enabled && !!externalTicketId && !externalTicketId.startsWith("temp-");
|
|
245
245
|
const queryEnabled = fetchable && identity.authTier !== "anon" && !!_optionalChain([identity, 'access', _4 => _4.user, 'optionalAccess', _5 => _5.email]);
|
|
@@ -259,7 +259,7 @@ function useTicketEngagements(externalTicketId, enabled = true, refetchInterval
|
|
|
259
259
|
// so polling pauses on a hidden tab.
|
|
260
260
|
refetchInterval,
|
|
261
261
|
queryFn: async () => {
|
|
262
|
-
const response = await
|
|
262
|
+
const response = await _chunkZITMX2IQcjs.embedAuthedFetch.call(void 0, LIST_ENGAGEMENTS_ENDPOINT, {
|
|
263
263
|
method: "POST",
|
|
264
264
|
body: JSON.stringify({ ticket_id: externalTicketId })
|
|
265
265
|
});
|
|
@@ -320,7 +320,7 @@ function TicketLinkedDeliveryCard({
|
|
|
320
320
|
{
|
|
321
321
|
className: `rounded-md border border-ods-border bg-ods-bg overflow-hidden ${_nullishCoalesce(className, () => ( ""))}`,
|
|
322
322
|
children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
323
|
-
|
|
323
|
+
_chunkHYJ5IV4Zcjs.DeliveryRow,
|
|
324
324
|
{
|
|
325
325
|
item,
|
|
326
326
|
href: clickup.delivery_href,
|
|
@@ -344,7 +344,7 @@ function TicketReplyComposer({
|
|
|
344
344
|
}) {
|
|
345
345
|
const [resolution, setResolution] = _react.useState.call(void 0, "");
|
|
346
346
|
const [closeDialogOpen, setCloseDialogOpen] = _react.useState.call(void 0, false);
|
|
347
|
-
const attachments =
|
|
347
|
+
const attachments = _chunkZITMX2IQcjs.useChatAttachments.call(void 0, );
|
|
348
348
|
const ticketRef = { id: ticket.id, external_id: ticket.external_id };
|
|
349
349
|
const hasReadyFiles = attachments.readyAttachments.length > 0;
|
|
350
350
|
const handleSend = _react.useCallback.call(void 0,
|
|
@@ -372,7 +372,7 @@ function TicketReplyComposer({
|
|
|
372
372
|
const disabled = busy || supportSystemDown;
|
|
373
373
|
return /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { className: "flex flex-col gap-2", children: [
|
|
374
374
|
/* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
375
|
-
|
|
375
|
+
_chunkZITMX2IQcjs.ChatAttachmentChipStrip,
|
|
376
376
|
{
|
|
377
377
|
attachments: attachments.attachments,
|
|
378
378
|
onRemove: attachments.removeAttachment,
|
|
@@ -381,7 +381,7 @@ function TicketReplyComposer({
|
|
|
381
381
|
}
|
|
382
382
|
),
|
|
383
383
|
/* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
384
|
-
|
|
384
|
+
_chunkZITMX2IQcjs.ChatInput,
|
|
385
385
|
{
|
|
386
386
|
fullWidth: true,
|
|
387
387
|
autoFocus: true,
|
|
@@ -395,7 +395,7 @@ function TicketReplyComposer({
|
|
|
395
395
|
),
|
|
396
396
|
/* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { className: "flex items-center gap-2 w-full", children: [
|
|
397
397
|
!supportSystemDown && /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
398
|
-
|
|
398
|
+
_chunkZITMX2IQcjs.ChatAttachmentAddButton,
|
|
399
399
|
{
|
|
400
400
|
attachmentsEnabled: true,
|
|
401
401
|
attachmentsCount: attachments.attachments.length,
|
|
@@ -418,13 +418,13 @@ function TicketReplyComposer({
|
|
|
418
418
|
}
|
|
419
419
|
)
|
|
420
420
|
] }),
|
|
421
|
-
/* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
422
|
-
/* @__PURE__ */ _jsxruntime.jsxs.call(void 0,
|
|
423
|
-
/* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
424
|
-
/* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
421
|
+
/* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkZITMX2IQcjs.AlertDialog, { open: closeDialogOpen, onOpenChange: setCloseDialogOpen, children: /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _chunkZITMX2IQcjs.AlertDialogContent, { className: "bg-ods-card border-ods-border", children: [
|
|
422
|
+
/* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _chunkZITMX2IQcjs.AlertDialogHeader, { children: [
|
|
423
|
+
/* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkZITMX2IQcjs.AlertDialogTitle, { className: "text-ods-text-primary", children: "Close this ticket?" }),
|
|
424
|
+
/* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkZITMX2IQcjs.AlertDialogDescription, { className: "text-ods-text-secondary", children: "Add an optional resolution note below. You can reopen the ticket later if needed." })
|
|
425
425
|
] }),
|
|
426
426
|
/* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
427
|
-
|
|
427
|
+
_chunkZITMX2IQcjs.Textarea,
|
|
428
428
|
{
|
|
429
429
|
value: resolution,
|
|
430
430
|
onChange: (e) => setResolution(e.target.value),
|
|
@@ -434,9 +434,9 @@ function TicketReplyComposer({
|
|
|
434
434
|
className: "mt-2"
|
|
435
435
|
}
|
|
436
436
|
),
|
|
437
|
-
/* @__PURE__ */ _jsxruntime.jsxs.call(void 0,
|
|
437
|
+
/* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _chunkZITMX2IQcjs.AlertDialogFooter, { children: [
|
|
438
438
|
/* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
439
|
-
|
|
439
|
+
_chunkZITMX2IQcjs.AlertDialogCancel,
|
|
440
440
|
{
|
|
441
441
|
disabled: busy,
|
|
442
442
|
className: "bg-transparent border-ods-border text-ods-text-primary hover:bg-ods-border",
|
|
@@ -444,7 +444,7 @@ function TicketReplyComposer({
|
|
|
444
444
|
}
|
|
445
445
|
),
|
|
446
446
|
/* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
447
|
-
|
|
447
|
+
_chunkZITMX2IQcjs.AlertDialogAction,
|
|
448
448
|
{
|
|
449
449
|
onClick: () => void confirmClose(),
|
|
450
450
|
disabled: busy,
|
|
@@ -514,7 +514,7 @@ var TICKET_FEED_HEIGHT = "h-[60vh] md:h-[420px]";
|
|
|
514
514
|
var TICKET_FEED_INNER = "flex flex-col gap-4 md:gap-6 px-4 md:px-6 py-4 md:py-6";
|
|
515
515
|
var TICKET_FEED_SKELETON_ROWS = 6;
|
|
516
516
|
function TicketTimelinePanel({ ticket }) {
|
|
517
|
-
const identity =
|
|
517
|
+
const identity = _chunkZITMX2IQcjs.useChatIdentity.call(void 0, );
|
|
518
518
|
const externalId = isOptimistic(ticket) ? null : ticket.external_id;
|
|
519
519
|
const { engagements, isLoading } = useTicketEngagements(
|
|
520
520
|
externalId,
|
|
@@ -534,11 +534,11 @@ function TicketTimelinePanel({ ticket }) {
|
|
|
534
534
|
const customerName = (isViewerTheCustomer ? viewerName : null) || ticketCustomerName || viewerName || _optionalChain([identity, 'access', _19 => _19.user, 'optionalAccess', _20 => _20.email]) || "You";
|
|
535
535
|
const customerAvatar = isViewerTheCustomer ? _nullishCoalesce(_optionalChain([identity, 'access', _21 => _21.user, 'optionalAccess', _22 => _22.avatarUrl]), () => ( void 0)) : void 0;
|
|
536
536
|
if (isLoading) {
|
|
537
|
-
return /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "div", { className: `${TICKET_FEED_FRAME} ${TICKET_FEED_HEIGHT}`, children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "div", { className: TICKET_FEED_INNER, children: Array.from({ length: TICKET_FEED_SKELETON_ROWS }, (_, i) => /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
537
|
+
return /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "div", { className: `${TICKET_FEED_FRAME} ${TICKET_FEED_HEIGHT}`, children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "div", { className: TICKET_FEED_INNER, children: Array.from({ length: TICKET_FEED_SKELETON_ROWS }, (_, i) => /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkZITMX2IQcjs.ChatMessageRowSkeleton, {}, i)) }) });
|
|
538
538
|
}
|
|
539
539
|
if (bodyTurns.length === 0 && engagements.length === 0) {
|
|
540
540
|
return /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
541
|
-
|
|
541
|
+
_chunkHYJ5IV4Zcjs.EmptyState,
|
|
542
542
|
{
|
|
543
543
|
type: "generic",
|
|
544
544
|
title: "No conversation yet",
|
|
@@ -553,7 +553,7 @@ function TicketTimelinePanel({ ticket }) {
|
|
|
553
553
|
const isResolution = turn.startsWith("[Resolution]");
|
|
554
554
|
const text = isResolution ? turn.replace(/^\[Resolution\]\s*/, "") : turn;
|
|
555
555
|
return /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
556
|
-
|
|
556
|
+
_chunkZITMX2IQcjs.ChatMessageRow,
|
|
557
557
|
{
|
|
558
558
|
displayName: customerName,
|
|
559
559
|
avatarUrl: customerAvatar,
|
|
@@ -582,13 +582,13 @@ function TicketTimelinePanel({ ticket }) {
|
|
|
582
582
|
}
|
|
583
583
|
const engAttachments = mapEngagementAttachments(eng.attachments);
|
|
584
584
|
return /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
585
|
-
|
|
585
|
+
_chunkZITMX2IQcjs.ChatMessageRow,
|
|
586
586
|
{
|
|
587
587
|
displayName: author,
|
|
588
588
|
avatarUrl: avatarSrc,
|
|
589
|
-
timeLabel: eng.createdAt ?
|
|
589
|
+
timeLabel: eng.createdAt ? _chunkZITMX2IQcjs.formatRelativeTime.call(void 0, eng.createdAt) : null,
|
|
590
590
|
body: stripAttachmentsPreamble(_nullishCoalesce(eng.body, () => ( ""))),
|
|
591
|
-
footer: engAttachments.length > 0 ? /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "div", { className: "mt-2", children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
591
|
+
footer: engAttachments.length > 0 ? /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "div", { className: "mt-2", children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkZITMX2IQcjs.TicketAttachmentsList, { attachments: engAttachments, size: "compact" }) }) : null
|
|
592
592
|
},
|
|
593
593
|
eng.id
|
|
594
594
|
);
|
|
@@ -707,7 +707,7 @@ function TicketRow({
|
|
|
707
707
|
const rowRef = _react.useRef.call(void 0, null);
|
|
708
708
|
const handleClick = _react.useCallback.call(void 0, () => {
|
|
709
709
|
onToggle(ticket.id);
|
|
710
|
-
|
|
710
|
+
_chunkZITMX2IQcjs.scrollElementIntoView.call(void 0, rowRef.current, {
|
|
711
711
|
adjustTargetY: (raw) => {
|
|
712
712
|
if (!rowRef.current) return raw;
|
|
713
713
|
const expandedDrawer = document.querySelector(
|
|
@@ -733,7 +733,7 @@ function TicketRow({
|
|
|
733
733
|
// so the badge accurately reflects "Closed" with a checkmark.
|
|
734
734
|
statusLabel: _nullishCoalesce(ticket.pipeline_stage_label, () => ( void 0)),
|
|
735
735
|
category: _nullishCoalesce(ticket.customer_company, () => ( void 0)),
|
|
736
|
-
timeAgo: ticket.hubspot_updated_at ?
|
|
736
|
+
timeAgo: ticket.hubspot_updated_at ? _chunkZITMX2IQcjs.formatRelativeTime.call(void 0, ticket.hubspot_updated_at) : void 0,
|
|
737
737
|
// Linked-work chip: surfaced whenever the ticket has a linked
|
|
738
738
|
// ClickUp task. Uses the linked task's own status so the chip text
|
|
739
739
|
// reads "Working" / "Waiting on version release" / etc. — useful
|
|
@@ -748,7 +748,7 @@ function TicketRow({
|
|
|
748
748
|
className: "border-b border-ods-border last:border-b-0",
|
|
749
749
|
children: [
|
|
750
750
|
/* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
751
|
-
|
|
751
|
+
_chunkZITMX2IQcjs.ChatTicketItem,
|
|
752
752
|
{
|
|
753
753
|
ticket: tileData,
|
|
754
754
|
onClick: optimistic ? void 0 : handleClick,
|
|
@@ -817,7 +817,7 @@ function useTicketsList(filters) {
|
|
|
817
817
|
pageSize
|
|
818
818
|
};
|
|
819
819
|
if (statusFilter) body.status = statusFilter;
|
|
820
|
-
const response = await
|
|
820
|
+
const response = await _chunkZITMX2IQcjs.embedAuthedFetch.call(void 0, FIND_TICKET_ENDPOINT, {
|
|
821
821
|
method: "POST",
|
|
822
822
|
body: JSON.stringify(body)
|
|
823
823
|
});
|
|
@@ -931,7 +931,7 @@ function useTicketActions(options) {
|
|
|
931
931
|
}, []);
|
|
932
932
|
const executeTicketAction = _react.useCallback.call(void 0,
|
|
933
933
|
async (toolName, args) => {
|
|
934
|
-
const res = await
|
|
934
|
+
const res = await _chunkZITMX2IQcjs.embedAuthedFetch.call(void 0, TICKET_ACTION_ENDPOINT, {
|
|
935
935
|
method: "POST",
|
|
936
936
|
body: JSON.stringify({ tool_name: toolName, args })
|
|
937
937
|
});
|
|
@@ -1316,13 +1316,13 @@ function resolveErrorCode(bodyCode, status) {
|
|
|
1316
1316
|
// src/components/tickets/ticket-center.tsx
|
|
1317
1317
|
|
|
1318
1318
|
function TicketCenter({ toast: toast2 = _chunkELF4OOHCcjs.toast } = {}) {
|
|
1319
|
-
const identity =
|
|
1319
|
+
const identity = _chunkZITMX2IQcjs.useChatIdentity.call(void 0, );
|
|
1320
1320
|
if (identity.isLoading) {
|
|
1321
1321
|
return /* @__PURE__ */ _jsxruntime.jsx.call(void 0, TicketCenterSkeleton, {});
|
|
1322
1322
|
}
|
|
1323
1323
|
if (identity.authTier === "anon" || !_optionalChain([identity, 'access', _58 => _58.user, 'optionalAccess', _59 => _59.email])) {
|
|
1324
1324
|
return /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
1325
|
-
|
|
1325
|
+
_chunkHYJ5IV4Zcjs.EmptyState,
|
|
1326
1326
|
{
|
|
1327
1327
|
type: "generic",
|
|
1328
1328
|
title: "Sign in to manage tickets",
|
|
@@ -1393,7 +1393,7 @@ function TicketCenterAuthed({
|
|
|
1393
1393
|
/* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { className: "flex items-center gap-3 text-xs text-ods-text-secondary", children: [
|
|
1394
1394
|
lastUpdatedAt && /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "span", { children: [
|
|
1395
1395
|
"Updated ",
|
|
1396
|
-
|
|
1396
|
+
_chunkZITMX2IQcjs.formatRelativeTime.call(void 0, new Date(lastUpdatedAt))
|
|
1397
1397
|
] }),
|
|
1398
1398
|
/* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
1399
1399
|
_chunkTU26IZPOcjs.Button,
|
|
@@ -1410,7 +1410,7 @@ function TicketCenterAuthed({
|
|
|
1410
1410
|
] })
|
|
1411
1411
|
] }),
|
|
1412
1412
|
isLoading ? /* @__PURE__ */ _jsxruntime.jsx.call(void 0, TicketListSkeleton, {}) : merged.length === 0 ? /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk6LK4VEXEcjs.Card, { className: "p-6", children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
1413
|
-
|
|
1413
|
+
_chunkHYJ5IV4Zcjs.EmptyState,
|
|
1414
1414
|
{
|
|
1415
1415
|
type: "generic",
|
|
1416
1416
|
title: "No tickets yet",
|
|
@@ -1459,7 +1459,7 @@ function TicketListSkeleton() {
|
|
|
1459
1459
|
// src/components/tickets/help-center-list.tsx
|
|
1460
1460
|
|
|
1461
1461
|
|
|
1462
|
-
|
|
1462
|
+
_chunkHYJ5IV4Zcjs.init_unified_pagination.call(void 0, );
|
|
1463
1463
|
|
|
1464
1464
|
// src/components/tickets/help-center-card.tsx
|
|
1465
1465
|
|
|
@@ -1481,7 +1481,7 @@ function HelpCenterCard({
|
|
|
1481
1481
|
const optimistic = isOptimistic(ticket);
|
|
1482
1482
|
const rawStatus = (_nullishCoalesce(ticket.status, () => ( "OPEN"))).toUpperCase();
|
|
1483
1483
|
const priority = (_nullishCoalesce(ticket.priority, () => ( ""))).toUpperCase();
|
|
1484
|
-
const relativeUpdated = ticket.hubspot_updated_at ?
|
|
1484
|
+
const relativeUpdated = ticket.hubspot_updated_at ? _chunkZITMX2IQcjs.formatRelativeTime.call(void 0, ticket.hubspot_updated_at) : "recently";
|
|
1485
1485
|
const title = (ticket.subject || "").trim() || "(untitled)";
|
|
1486
1486
|
const subtitle = `UPDATED ${relativeUpdated}, #${ticket.external_id || "\u2014"}${ticket.pipeline_stage_label ? `, ${ticket.pipeline_stage_label}` : ""}`;
|
|
1487
1487
|
const description = _nullishCoalesce(_nullishCoalesce(ticket.preview, () => ( ticket.body)), () => ( ""));
|
|
@@ -1494,7 +1494,7 @@ function HelpCenterCard({
|
|
|
1494
1494
|
_react.useEffect.call(void 0, () => {
|
|
1495
1495
|
if (!isExpanded) return;
|
|
1496
1496
|
const raf = requestAnimationFrame(() => {
|
|
1497
|
-
|
|
1497
|
+
_chunkZITMX2IQcjs.scrollElementIntoView.call(void 0, rowRef.current, {
|
|
1498
1498
|
headerOffset: STICKY_HEADER_OFFSET_PX
|
|
1499
1499
|
});
|
|
1500
1500
|
});
|
|
@@ -1505,7 +1505,7 @@ function HelpCenterCard({
|
|
|
1505
1505
|
_chunk6LK4VEXEcjs.StatusBadge,
|
|
1506
1506
|
{
|
|
1507
1507
|
text: rawStatus,
|
|
1508
|
-
colorScheme:
|
|
1508
|
+
colorScheme: _chunkZITMX2IQcjs.getStatusColorScheme.call(void 0, rawStatus),
|
|
1509
1509
|
variant: "card",
|
|
1510
1510
|
className: "border border-ods-border"
|
|
1511
1511
|
}
|
|
@@ -1538,7 +1538,7 @@ function HelpCenterCard({
|
|
|
1538
1538
|
"aria-controls": isExpanded ? `help-center-drawer-${ticket.id}` : void 0,
|
|
1539
1539
|
className: "w-full text-left p-[12px] md:p-[16px] focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ods-accent focus-visible:ring-inset disabled:cursor-default",
|
|
1540
1540
|
children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
1541
|
-
|
|
1541
|
+
_chunkHYJ5IV4Zcjs.DevCardRowContent,
|
|
1542
1542
|
{
|
|
1543
1543
|
title,
|
|
1544
1544
|
subtitle,
|
|
@@ -1613,7 +1613,7 @@ function HelpCenterCreateForm({
|
|
|
1613
1613
|
const [subject, setSubject] = _react.useState.call(void 0, "");
|
|
1614
1614
|
const [subjectError, setSubjectError] = _react.useState.call(void 0, null);
|
|
1615
1615
|
const subjectField = /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", { className: "flex flex-col", children: [
|
|
1616
|
-
/* @__PURE__ */ _jsxruntime.jsxs.call(void 0,
|
|
1616
|
+
/* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _chunkZITMX2IQcjs.Label, { htmlFor: "help-center-subject", children: [
|
|
1617
1617
|
"Subject",
|
|
1618
1618
|
/* @__PURE__ */ _jsxruntime.jsx.call(void 0, "span", { className: "text-ods-accent", children: "*" })
|
|
1619
1619
|
] }),
|
|
@@ -1645,7 +1645,7 @@ function HelpCenterCreateForm({
|
|
|
1645
1645
|
)
|
|
1646
1646
|
] });
|
|
1647
1647
|
return /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
1648
|
-
|
|
1648
|
+
_chunk65JN25VMcjs.ContactForm,
|
|
1649
1649
|
{
|
|
1650
1650
|
title: "Open a new ticket",
|
|
1651
1651
|
footerText: "The support team typically responds within one business day.",
|
|
@@ -1683,7 +1683,7 @@ function HelpCenterCreateForm({
|
|
|
1683
1683
|
// src/components/tickets/help-center-list.tsx
|
|
1684
1684
|
|
|
1685
1685
|
function HelpCenterList({ toast: toast2 = _chunkELF4OOHCcjs.toast } = {}) {
|
|
1686
|
-
const identity =
|
|
1686
|
+
const identity = _chunkZITMX2IQcjs.useChatIdentity.call(void 0, );
|
|
1687
1687
|
const searchParams = _chunkG7UE6RKVcjs.useSearchParams.call(void 0, );
|
|
1688
1688
|
const router = _chunkG7UE6RKVcjs.useRouter.call(void 0, );
|
|
1689
1689
|
const pathname = _chunkG7UE6RKVcjs.usePathname.call(void 0, );
|
|
@@ -1693,11 +1693,11 @@ function HelpCenterList({ toast: toast2 = _chunkELF4OOHCcjs.toast } = {}) {
|
|
|
1693
1693
|
const rawPage = Number(searchParams.get("page"));
|
|
1694
1694
|
const page = Number.isFinite(rawPage) && rawPage > 0 ? Math.floor(rawPage) : 1;
|
|
1695
1695
|
if (identity.isLoading) {
|
|
1696
|
-
return /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
1696
|
+
return /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkHYJ5IV4Zcjs.DevSectionPage, { sectionKey: "tickets", preControls: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, HelpCenterCreateFormSkeleton, {}), children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkHYJ5IV4Zcjs.DevCardRowSkeletonList, {}) });
|
|
1697
1697
|
}
|
|
1698
1698
|
if (identity.authTier === "anon" || !_optionalChain([identity, 'access', _60 => _60.user, 'optionalAccess', _61 => _61.email])) {
|
|
1699
|
-
return /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
1700
|
-
|
|
1699
|
+
return /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkHYJ5IV4Zcjs.DevSectionPage, { sectionKey: "tickets", children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
1700
|
+
_chunkHYJ5IV4Zcjs.EmptyState,
|
|
1701
1701
|
{
|
|
1702
1702
|
type: "generic",
|
|
1703
1703
|
title: "Sign in to manage tickets",
|
|
@@ -1822,15 +1822,15 @@ function HelpCenterListAuthed({
|
|
|
1822
1822
|
] }),
|
|
1823
1823
|
/* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkTU26IZPOcjs.Button, { type: "button", variant: "accent", onClick: () => refetch(), children: "Retry" })
|
|
1824
1824
|
] }),
|
|
1825
|
-
!error && /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "div", { className: "w-full", children: isLoading ? /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
1825
|
+
!error && /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "div", { className: "w-full", children: isLoading ? /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkHYJ5IV4Zcjs.DevCardRowSkeletonList, {}) : !hasResults && isFetching ? (
|
|
1826
1826
|
// Bridge state — background refetch in flight and the
|
|
1827
1827
|
// optimistic placeholder was just removed by the mutation
|
|
1828
1828
|
// callback. Without this branch "No tickets yet" would flash
|
|
1829
1829
|
// for ~50ms between `removeOptimistic` and the server
|
|
1830
1830
|
// response landing.
|
|
1831
|
-
/* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
1831
|
+
/* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkHYJ5IV4Zcjs.DevCardRowSkeletonList, { rows: 1 })
|
|
1832
1832
|
) : !hasResults ? hasActiveFilters ? /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
1833
|
-
|
|
1833
|
+
_chunkHYJ5IV4Zcjs.EmptyState,
|
|
1834
1834
|
{
|
|
1835
1835
|
type: "search",
|
|
1836
1836
|
title: "No tickets found",
|
|
@@ -1845,7 +1845,7 @@ function HelpCenterListAuthed({
|
|
|
1845
1845
|
}
|
|
1846
1846
|
}
|
|
1847
1847
|
) : /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
1848
|
-
|
|
1848
|
+
_chunkHYJ5IV4Zcjs.EmptyState,
|
|
1849
1849
|
{
|
|
1850
1850
|
type: "generic",
|
|
1851
1851
|
title: "No tickets yet",
|
|
@@ -1879,9 +1879,9 @@ function HelpCenterListAuthed({
|
|
|
1879
1879
|
ticket.id
|
|
1880
1880
|
)) })
|
|
1881
1881
|
) }),
|
|
1882
|
-
!error && totalPages > 1 && /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
1882
|
+
!error && totalPages > 1 && /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkHYJ5IV4Zcjs.UnifiedPagination, { currentPage: page, totalPages })
|
|
1883
1883
|
] });
|
|
1884
|
-
return /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
1884
|
+
return /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkHYJ5IV4Zcjs.DevSectionPage, { sectionKey: "tickets", preControls: form, children: body });
|
|
1885
1885
|
}
|
|
1886
1886
|
|
|
1887
1887
|
|
|
@@ -7,11 +7,11 @@ import {
|
|
|
7
7
|
EmptyState,
|
|
8
8
|
UnifiedPagination,
|
|
9
9
|
init_unified_pagination
|
|
10
|
-
} from "../../chunk-
|
|
10
|
+
} from "../../chunk-CAPVFI5A.js";
|
|
11
11
|
import "../../chunk-4XLJWX2N.js";
|
|
12
12
|
import {
|
|
13
13
|
ContactForm
|
|
14
|
-
} from "../../chunk-
|
|
14
|
+
} from "../../chunk-QCRQNKRO.js";
|
|
15
15
|
import {
|
|
16
16
|
AlertDialog,
|
|
17
17
|
AlertDialogAction,
|
|
@@ -36,7 +36,7 @@ import {
|
|
|
36
36
|
scrollElementIntoView,
|
|
37
37
|
useChatAttachments,
|
|
38
38
|
useChatIdentity
|
|
39
|
-
} from "../../chunk-
|
|
39
|
+
} from "../../chunk-NP5U35FA.js";
|
|
40
40
|
import {
|
|
41
41
|
toast
|
|
42
42
|
} from "../../chunk-4RDJZIHW.js";
|