@flamingo-stack/openframe-frontend-core 0.0.644 → 0.0.645-snapshot.20260917103313
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 +2 -2
- package/dist/{chunk-RFFF2EYD.cjs → chunk-2KE2M67P.cjs} +15 -15
- package/dist/{chunk-RFFF2EYD.cjs.map → chunk-2KE2M67P.cjs.map} +1 -1
- package/dist/{chunk-PFV4DAX5.js → chunk-2ZLCQSG4.js} +10 -10
- package/dist/{chunk-FOSIR4QF.js → chunk-3DWDJ54N.js} +5 -5
- package/dist/{chunk-YB6FI2G3.js → chunk-3SMLYVM2.js} +1 -1
- package/dist/{chunk-YB6FI2G3.js.map → chunk-3SMLYVM2.js.map} +1 -1
- package/dist/{chunk-4EEUB62O.js → chunk-4HVWGYHI.js} +2 -2
- package/dist/{chunk-27RD5XTP.js → chunk-4TLGU2FT.js} +5 -5
- package/dist/{chunk-G5U4JP45.js → chunk-5ONM3FHQ.js} +4 -4
- package/dist/{chunk-MRIOYSXH.js → chunk-63RIPFJ4.js} +5 -5
- package/dist/{chunk-GELNUDBT.cjs → chunk-77BLJHKI.cjs} +10 -10
- package/dist/{chunk-GELNUDBT.cjs.map → chunk-77BLJHKI.cjs.map} +1 -1
- package/dist/{chunk-KJWPAJRT.js → chunk-7EI3NES7.js} +3 -3
- package/dist/{chunk-DCCY54LU.cjs → chunk-7HHVE7DC.cjs} +14 -14
- package/dist/{chunk-DCCY54LU.cjs.map → chunk-7HHVE7DC.cjs.map} +1 -1
- package/dist/{chunk-CBXZSTAG.cjs → chunk-7UWJMWDH.cjs} +1004 -794
- package/dist/chunk-7UWJMWDH.cjs.map +1 -0
- package/dist/{chunk-3DGRXC74.js → chunk-CH5E4GXC.js} +5 -5
- package/dist/{chunk-VE52MSYC.js → chunk-CJMWRV65.js} +8 -8
- package/dist/{chunk-65EVGKFV.cjs → chunk-CSZBFSYT.cjs} +14 -14
- package/dist/{chunk-65EVGKFV.cjs.map → chunk-CSZBFSYT.cjs.map} +1 -1
- package/dist/{chunk-TTVOBWAH.js → chunk-D5PU7K2W.js} +5 -5
- package/dist/{chunk-3IXDZI3R.cjs → chunk-DOVVKQMZ.cjs} +3 -3
- package/dist/{chunk-3IXDZI3R.cjs.map → chunk-DOVVKQMZ.cjs.map} +1 -1
- package/dist/{chunk-I57XLISO.js → chunk-DULSS7R6.js} +226 -16
- package/dist/chunk-DULSS7R6.js.map +1 -0
- package/dist/{chunk-KOQCA5X5.cjs → chunk-DWJREJRA.cjs} +5 -5
- package/dist/{chunk-KOQCA5X5.cjs.map → chunk-DWJREJRA.cjs.map} +1 -1
- package/dist/{chunk-7R2DIGG4.cjs → chunk-EX5PJGVA.cjs} +76 -76
- package/dist/{chunk-7R2DIGG4.cjs.map → chunk-EX5PJGVA.cjs.map} +1 -1
- package/dist/{chunk-GBEUGDZG.cjs → chunk-F6U2H42L.cjs} +23 -23
- package/dist/{chunk-GBEUGDZG.cjs.map → chunk-F6U2H42L.cjs.map} +1 -1
- package/dist/{chunk-3UBT2OIX.cjs → chunk-FMG2YUBW.cjs} +74 -74
- package/dist/{chunk-3UBT2OIX.cjs.map → chunk-FMG2YUBW.cjs.map} +1 -1
- package/dist/{chunk-KEKN76JR.js → chunk-FRQ2DE5Z.js} +5 -5
- package/dist/{chunk-JOV64HW5.js → chunk-GRBZC5N3.js} +3 -3
- package/dist/{chunk-CHIHYC7Q.cjs → chunk-GSD62VAY.cjs} +21 -21
- package/dist/{chunk-CHIHYC7Q.cjs.map → chunk-GSD62VAY.cjs.map} +1 -1
- package/dist/{chunk-LPMDCQLL.js → chunk-H3EJDISW.js} +2 -2
- package/dist/{chunk-HPWLIYRL.js → chunk-HT4B4NGI.js} +14 -14
- package/dist/{chunk-KOLVBEW5.js → chunk-IWISVG4P.js} +3 -3
- package/dist/{chunk-MCQAOIUK.cjs → chunk-JEH4PXJG.cjs} +37 -37
- package/dist/{chunk-MCQAOIUK.cjs.map → chunk-JEH4PXJG.cjs.map} +1 -1
- package/dist/{chunk-GNKM6R55.cjs → chunk-JH5P72AF.cjs} +25 -25
- package/dist/{chunk-GNKM6R55.cjs.map → chunk-JH5P72AF.cjs.map} +1 -1
- package/dist/{chunk-HOGOQA2X.js → chunk-JNOPOJHH.js} +3 -3
- package/dist/{chunk-LCK7T2RM.cjs → chunk-JU6SBF3C.cjs} +13 -13
- package/dist/{chunk-LCK7T2RM.cjs.map → chunk-JU6SBF3C.cjs.map} +1 -1
- package/dist/{chunk-F2KBCLUG.js → chunk-KKSSA4CS.js} +2 -2
- package/dist/{chunk-IXD6SHQ6.js → chunk-KMI4VAS2.js} +6 -6
- package/dist/{chunk-IIXB5REN.cjs → chunk-KNMCYCY3.cjs} +16 -16
- package/dist/{chunk-IIXB5REN.cjs.map → chunk-KNMCYCY3.cjs.map} +1 -1
- package/dist/{chunk-RNMGKAS6.js → chunk-KPEBCJIH.js} +15 -15
- package/dist/{chunk-OMSUWB6A.cjs → chunk-LPMW5CNR.cjs} +118 -118
- package/dist/{chunk-OMSUWB6A.cjs.map → chunk-LPMW5CNR.cjs.map} +1 -1
- package/dist/{chunk-FKBM6U43.js → chunk-LZLT67PE.js} +2 -2
- package/dist/{chunk-B3Z3RJRW.js → chunk-M4AD2PHE.js} +5 -5
- package/dist/{chunk-BVQEU5JB.js → chunk-MT5A25AX.js} +2 -2
- package/dist/chunk-OXB6LRBK.js +20 -0
- package/dist/chunk-OXB6LRBK.js.map +1 -0
- package/dist/{chunk-OVXYX47B.cjs → chunk-PP6RACFB.cjs} +19 -19
- package/dist/{chunk-OVXYX47B.cjs.map → chunk-PP6RACFB.cjs.map} +1 -1
- package/dist/{chunk-S2KMNFFN.js → chunk-RJUXSUSM.js} +7 -7
- package/dist/{chunk-TGUA3C4U.cjs → chunk-RKN3TM24.cjs} +9 -9
- package/dist/{chunk-TGUA3C4U.cjs.map → chunk-RKN3TM24.cjs.map} +1 -1
- package/dist/{chunk-C5Y5T6GC.cjs → chunk-SBJ7BWYG.cjs} +20 -20
- package/dist/{chunk-C5Y5T6GC.cjs.map → chunk-SBJ7BWYG.cjs.map} +1 -1
- package/dist/{chunk-UKV52KAP.cjs → chunk-SIXBT6BA.cjs} +44 -44
- package/dist/{chunk-UKV52KAP.cjs.map → chunk-SIXBT6BA.cjs.map} +1 -1
- package/dist/{chunk-SKABQX44.js → chunk-SKA27VLR.js} +7 -7
- package/dist/{chunk-UPKZU6QU.cjs → chunk-U2YLMFJK.cjs} +1 -1
- package/dist/{chunk-UPKZU6QU.cjs.map → chunk-U2YLMFJK.cjs.map} +1 -1
- package/dist/{chunk-B5IFXCRF.cjs → chunk-VJOZGHTK.cjs} +41 -41
- package/dist/{chunk-B5IFXCRF.cjs.map → chunk-VJOZGHTK.cjs.map} +1 -1
- package/dist/{chunk-UEXIMEVU.js → chunk-VK7YKTAL.js} +10 -10
- package/dist/{chunk-CCWI3622.cjs → chunk-VTYP25OW.cjs} +4 -4
- package/dist/{chunk-CCWI3622.cjs.map → chunk-VTYP25OW.cjs.map} +1 -1
- package/dist/{chunk-4WVWRFGP.js → chunk-W2HZUFVB.js} +9 -9
- package/dist/{chunk-T3C3JLGV.cjs → chunk-WKX7DYFM.cjs} +8 -8
- package/dist/{chunk-T3C3JLGV.cjs.map → chunk-WKX7DYFM.cjs.map} +1 -1
- package/dist/{chunk-RB6L5EGM.cjs → chunk-X2YUAHNR.cjs} +1131 -1131
- package/dist/{chunk-RB6L5EGM.cjs.map → chunk-X2YUAHNR.cjs.map} +1 -1
- package/dist/{chunk-LZYPSDFE.cjs → chunk-X5OMIX5I.cjs} +90 -90
- package/dist/{chunk-LZYPSDFE.cjs.map → chunk-X5OMIX5I.cjs.map} +1 -1
- package/dist/chunk-X7CEWD6V.cjs +20 -0
- package/dist/chunk-X7CEWD6V.cjs.map +1 -0
- package/dist/{chunk-5JUTGEZE.js → chunk-XBTZOO74.js} +2 -2
- package/dist/{chunk-RWURXICE.cjs → chunk-XGD6SCHN.cjs} +44 -44
- package/dist/{chunk-RWURXICE.cjs.map → chunk-XGD6SCHN.cjs.map} +1 -1
- package/dist/{chunk-EHAYNUOL.cjs → chunk-XOGD2AME.cjs} +3 -3
- package/dist/{chunk-EHAYNUOL.cjs.map → chunk-XOGD2AME.cjs.map} +1 -1
- package/dist/{chunk-FAD5WURS.cjs → chunk-YR5S7VBA.cjs} +124 -124
- package/dist/{chunk-FAD5WURS.cjs.map → chunk-YR5S7VBA.cjs.map} +1 -1
- package/dist/{chunk-N6HNK25A.cjs → chunk-YWUZL3RT.cjs} +11 -11
- package/dist/{chunk-N6HNK25A.cjs.map → chunk-YWUZL3RT.cjs.map} +1 -1
- package/dist/{chunk-7Q5XXPCB.js → chunk-Z3HJFVYS.js} +14 -14
- package/dist/components/calendar.cjs +10 -10
- package/dist/components/calendar.js +2 -2
- package/dist/components/case-studies/index.cjs +30 -30
- package/dist/components/case-studies/index.js +14 -14
- package/dist/components/chat/embeddable-chat.d.ts +14 -1
- package/dist/components/chat/embeddable-chat.d.ts.map +1 -1
- package/dist/components/chat/index.cjs +9 -9
- package/dist/components/chat/index.d.ts +1 -1
- package/dist/components/chat/index.d.ts.map +1 -1
- package/dist/components/chat/index.js +8 -8
- package/dist/components/chat/utils/source-row-cta.d.ts +1 -1
- package/dist/components/command.d.ts +7 -7
- package/dist/components/contact/index.cjs +15 -15
- package/dist/components/contact/index.js +14 -14
- package/dist/components/docs/index.cjs +18 -18
- package/dist/components/docs/index.js +17 -17
- package/dist/components/embeds/index.cjs +15 -15
- package/dist/components/embeds/index.js +14 -14
- package/dist/components/faq/index.cjs +16 -16
- package/dist/components/faq/index.js +15 -15
- package/dist/components/features/index.cjs +14 -14
- package/dist/components/features/index.js +13 -13
- package/dist/components/help-center-pages/index.cjs +37 -37
- package/dist/components/help-center-pages/index.js +28 -28
- package/dist/components/icons/index.cjs +3 -3
- package/dist/components/icons/index.js +2 -2
- package/dist/components/index.cjs +115 -115
- package/dist/components/index.cjs.map +1 -1
- package/dist/components/index.js +31 -31
- package/dist/components/index.js.map +1 -1
- package/dist/components/meeting-scheduler/index.cjs +119 -119
- package/dist/components/meeting-scheduler/index.js +15 -15
- package/dist/components/navigation/index.cjs +17 -17
- package/dist/components/navigation/index.js +16 -16
- package/dist/components/onboarding-guides/index.cjs +18 -18
- package/dist/components/onboarding-guides/index.js +17 -17
- package/dist/components/related-content/index.cjs +10 -10
- package/dist/components/related-content/index.js +9 -9
- package/dist/components/resizable.d.ts +1 -1
- package/dist/components/tickets/index.cjs +19 -19
- package/dist/components/tickets/index.js +18 -18
- package/dist/components/ui/file-manager/index.cjs +57 -57
- package/dist/components/ui/file-manager/index.js +4 -4
- package/dist/components/ui/index.cjs +14 -14
- package/dist/components/ui/index.js +13 -13
- package/dist/contexts/chat-runtime-context.d.ts +1 -1
- package/dist/contexts/index.cjs +2 -2
- package/dist/contexts/index.js +1 -1
- package/dist/hooks/index.cjs +7 -7
- package/dist/hooks/index.js +6 -6
- package/dist/index.cjs +36 -28
- package/dist/index.cjs.map +1 -1
- package/dist/index.js +30 -22
- package/dist/index.js.map +1 -1
- package/dist/platform-domains.cjs +43 -0
- package/dist/platform-domains.cjs.map +1 -1
- package/dist/platform-domains.d.ts +62 -4
- package/dist/platform-domains.d.ts.map +1 -1
- package/dist/platform-domains.js +39 -1
- package/dist/platform-domains.js.map +1 -1
- package/dist/types/index.cjs +0 -104
- package/dist/types/index.cjs.map +1 -1
- package/dist/types/index.js +0 -104
- package/dist/types/index.js.map +1 -1
- package/dist/utils/cn.d.ts +0 -21
- package/dist/utils/cn.d.ts.map +1 -1
- package/dist/utils/index.cjs +53 -25
- package/dist/utils/index.cjs.map +1 -1
- package/dist/utils/index.d.ts +1 -2
- package/dist/utils/index.d.ts.map +1 -1
- package/dist/utils/index.js +49 -25
- package/dist/utils/index.js.map +1 -1
- package/package.json +1 -1
- package/src/__tests__/platform-domains.test.ts +124 -0
- package/src/components/chat/embeddable-chat.tsx +65 -3
- package/src/components/chat/index.ts +6 -1
- package/src/components/chat/utils/__tests__/source-row-cta.test.ts +2 -2
- package/src/components/chat/utils/source-row-cta.ts +4 -4
- package/src/components/made-with-love.tsx +2 -2
- package/src/contexts/chat-runtime-context.tsx +1 -1
- package/src/platform-domains.ts +99 -4
- package/src/utils/.cn.md +3 -23
- package/src/utils/cn.ts +0 -47
- package/src/utils/index.ts +9 -2
- package/dist/chunk-23V5BSHD.cjs +0 -169
- package/dist/chunk-23V5BSHD.cjs.map +0 -1
- package/dist/chunk-CBXZSTAG.cjs.map +0 -1
- package/dist/chunk-I57XLISO.js.map +0 -1
- package/dist/chunk-O4MCCKKN.js +0 -169
- package/dist/chunk-O4MCCKKN.js.map +0 -1
- /package/dist/{chunk-PFV4DAX5.js.map → chunk-2ZLCQSG4.js.map} +0 -0
- /package/dist/{chunk-FOSIR4QF.js.map → chunk-3DWDJ54N.js.map} +0 -0
- /package/dist/{chunk-4EEUB62O.js.map → chunk-4HVWGYHI.js.map} +0 -0
- /package/dist/{chunk-27RD5XTP.js.map → chunk-4TLGU2FT.js.map} +0 -0
- /package/dist/{chunk-G5U4JP45.js.map → chunk-5ONM3FHQ.js.map} +0 -0
- /package/dist/{chunk-MRIOYSXH.js.map → chunk-63RIPFJ4.js.map} +0 -0
- /package/dist/{chunk-KJWPAJRT.js.map → chunk-7EI3NES7.js.map} +0 -0
- /package/dist/{chunk-3DGRXC74.js.map → chunk-CH5E4GXC.js.map} +0 -0
- /package/dist/{chunk-VE52MSYC.js.map → chunk-CJMWRV65.js.map} +0 -0
- /package/dist/{chunk-TTVOBWAH.js.map → chunk-D5PU7K2W.js.map} +0 -0
- /package/dist/{chunk-KEKN76JR.js.map → chunk-FRQ2DE5Z.js.map} +0 -0
- /package/dist/{chunk-JOV64HW5.js.map → chunk-GRBZC5N3.js.map} +0 -0
- /package/dist/{chunk-LPMDCQLL.js.map → chunk-H3EJDISW.js.map} +0 -0
- /package/dist/{chunk-HPWLIYRL.js.map → chunk-HT4B4NGI.js.map} +0 -0
- /package/dist/{chunk-KOLVBEW5.js.map → chunk-IWISVG4P.js.map} +0 -0
- /package/dist/{chunk-HOGOQA2X.js.map → chunk-JNOPOJHH.js.map} +0 -0
- /package/dist/{chunk-F2KBCLUG.js.map → chunk-KKSSA4CS.js.map} +0 -0
- /package/dist/{chunk-IXD6SHQ6.js.map → chunk-KMI4VAS2.js.map} +0 -0
- /package/dist/{chunk-RNMGKAS6.js.map → chunk-KPEBCJIH.js.map} +0 -0
- /package/dist/{chunk-FKBM6U43.js.map → chunk-LZLT67PE.js.map} +0 -0
- /package/dist/{chunk-B3Z3RJRW.js.map → chunk-M4AD2PHE.js.map} +0 -0
- /package/dist/{chunk-BVQEU5JB.js.map → chunk-MT5A25AX.js.map} +0 -0
- /package/dist/{chunk-S2KMNFFN.js.map → chunk-RJUXSUSM.js.map} +0 -0
- /package/dist/{chunk-SKABQX44.js.map → chunk-SKA27VLR.js.map} +0 -0
- /package/dist/{chunk-UEXIMEVU.js.map → chunk-VK7YKTAL.js.map} +0 -0
- /package/dist/{chunk-4WVWRFGP.js.map → chunk-W2HZUFVB.js.map} +0 -0
- /package/dist/{chunk-5JUTGEZE.js.map → chunk-XBTZOO74.js.map} +0 -0
- /package/dist/{chunk-7Q5XXPCB.js.map → chunk-Z3HJFVYS.js.map} +0 -0
|
@@ -42,7 +42,7 @@ import {
|
|
|
42
42
|
WhatsAppIcon,
|
|
43
43
|
XLogo,
|
|
44
44
|
YouTubeIcon
|
|
45
|
-
} from "./chunk-
|
|
45
|
+
} from "./chunk-H3EJDISW.js";
|
|
46
46
|
import {
|
|
47
47
|
AlertCircleIcon,
|
|
48
48
|
AlertTriangleIcon,
|
|
@@ -174,7 +174,7 @@ import {
|
|
|
174
174
|
safeHref,
|
|
175
175
|
sortBitesByCreatedAtDesc,
|
|
176
176
|
useCoverImageFallback
|
|
177
|
-
} from "./chunk-
|
|
177
|
+
} from "./chunk-3DWDJ54N.js";
|
|
178
178
|
import {
|
|
179
179
|
next_image_default
|
|
180
180
|
} from "./chunk-MDKCTSDS.js";
|
|
@@ -187,14 +187,14 @@ import {
|
|
|
187
187
|
getPlatformDisplayName,
|
|
188
188
|
useAuthedAssetSrc,
|
|
189
189
|
useAuthedImageSrc
|
|
190
|
-
} from "./chunk-
|
|
190
|
+
} from "./chunk-LZLT67PE.js";
|
|
191
191
|
import {
|
|
192
192
|
OpenFrameLogo
|
|
193
193
|
} from "./chunk-OTX6XNSA.js";
|
|
194
194
|
import {
|
|
195
195
|
useChatRuntime,
|
|
196
196
|
useRequiredChatRuntime
|
|
197
|
-
} from "./chunk-
|
|
197
|
+
} from "./chunk-3SMLYVM2.js";
|
|
198
198
|
import {
|
|
199
199
|
COLLISION_PADDING_PX,
|
|
200
200
|
CollisionBoundaryContext,
|
|
@@ -206,20 +206,19 @@ import {
|
|
|
206
206
|
Skeleton,
|
|
207
207
|
useCollisionBoundary,
|
|
208
208
|
usePortalContainer
|
|
209
|
-
} from "./chunk-
|
|
209
|
+
} from "./chunk-XBTZOO74.js";
|
|
210
210
|
import {
|
|
211
211
|
SearchIcon
|
|
212
212
|
} from "./chunk-6U3IUD57.js";
|
|
213
213
|
import {
|
|
214
214
|
Button
|
|
215
|
-
} from "./chunk-
|
|
215
|
+
} from "./chunk-4HVWGYHI.js";
|
|
216
216
|
import {
|
|
217
217
|
next_link_default
|
|
218
218
|
} from "./chunk-BTROSBHF.js";
|
|
219
219
|
import {
|
|
220
|
-
cn
|
|
221
|
-
|
|
222
|
-
} from "./chunk-O4MCCKKN.js";
|
|
220
|
+
cn
|
|
221
|
+
} from "./chunk-OXB6LRBK.js";
|
|
223
222
|
import {
|
|
224
223
|
acquireClient,
|
|
225
224
|
releaseClient,
|
|
@@ -7106,9 +7105,9 @@ var ChatMessageEnhanced = forwardRef16(
|
|
|
7106
7105
|
/* @__PURE__ */ new Map()
|
|
7107
7106
|
);
|
|
7108
7107
|
const refByKey = useMemo8(() => {
|
|
7109
|
-
const
|
|
7110
|
-
for (const described of refs ?? [])
|
|
7111
|
-
return
|
|
7108
|
+
const byKey2 = /* @__PURE__ */ new Map();
|
|
7109
|
+
for (const described of refs ?? []) byKey2.set(`${described.type}:${described.id}`, described);
|
|
7110
|
+
return byKey2;
|
|
7112
7111
|
}, [refs]);
|
|
7113
7112
|
const renderingPlan = useMemo8(() => {
|
|
7114
7113
|
if (!hasMarkerSupport) return null;
|
|
@@ -14845,6 +14844,179 @@ function defaultTableIdForDocumentType(documentType) {
|
|
|
14845
14844
|
|
|
14846
14845
|
// src/components/chat/utils/source-row-cta.ts
|
|
14847
14846
|
import { FileText as FileText3 } from "lucide-react";
|
|
14847
|
+
|
|
14848
|
+
// src/platform-domains.ts
|
|
14849
|
+
var PLATFORM_DOMAINS = [
|
|
14850
|
+
{ key: "marketing-hub", defaultUrl: "https://marketing-hub.flamingo.so", envVar: "NEXT_PUBLIC_MARKETING_HUB_URL" },
|
|
14851
|
+
{ key: "company-hub", defaultUrl: "https://company-hub.flamingo.so", envVar: "NEXT_PUBLIC_COMPANY_HUB_URL" },
|
|
14852
|
+
{ key: "product-hub", defaultUrl: "https://product-hub.flamingo.so", envVar: "NEXT_PUBLIC_PRODUCT_HUB_URL" },
|
|
14853
|
+
{ key: "revenue-hub", defaultUrl: "https://revenue-hub.flamingo.so", envVar: "NEXT_PUBLIC_REVENUE_HUB_URL" },
|
|
14854
|
+
{ key: "people-hub", defaultUrl: "https://people-hub.flamingo.so", envVar: "NEXT_PUBLIC_PEOPLE_HUB_URL" },
|
|
14855
|
+
{ key: "openmsp", defaultUrl: "https://www.openmsp.ai", envVar: "NEXT_PUBLIC_OPENMSP_URL" },
|
|
14856
|
+
// ORDERING INVARIANT (first-wins, load-bearing): `flamingo` MUST precede `flamingo-teaser` + `universal`.
|
|
14857
|
+
// All three resolve to www.flamingo.run; the reverse index is first-wins → flamingo claims the shared host,
|
|
14858
|
+
// teaser keeps only its unique flamingo.cx aliases, universal contributes no unique host.
|
|
14859
|
+
// ⚠️ DO NOT REORDER — enforced by the module-load self-check at the bottom of this file.
|
|
14860
|
+
{ key: "flamingo", defaultUrl: "https://www.flamingo.run", envVar: "NEXT_PUBLIC_FLAMINGO_URL" },
|
|
14861
|
+
{ key: "tmcg", defaultUrl: "https://www.tmcg.miami", envVar: "NEXT_PUBLIC_TMCG_URL" },
|
|
14862
|
+
{ key: "mlg", defaultUrl: "https://www.mlg.soccer", envVar: "NEXT_PUBLIC_MLG_URL" },
|
|
14863
|
+
{
|
|
14864
|
+
key: "flamingo-teaser",
|
|
14865
|
+
defaultUrl: "https://www.flamingo.run",
|
|
14866
|
+
envVar: "NEXT_PUBLIC_FLAMINGO_URL",
|
|
14867
|
+
aliasHostnames: ["flamingo.cx", "www.flamingo.cx"]
|
|
14868
|
+
},
|
|
14869
|
+
{
|
|
14870
|
+
key: "openframe",
|
|
14871
|
+
defaultUrl: "https://openframe.ai",
|
|
14872
|
+
envVar: "NEXT_PUBLIC_OPENFRAME_URL",
|
|
14873
|
+
aliasHostnames: ["openframe.ai", "www.openframe.ai", "hub.openframe.ai"]
|
|
14874
|
+
},
|
|
14875
|
+
{
|
|
14876
|
+
key: "openframe-dashboard",
|
|
14877
|
+
defaultUrl: "https://openframe.ai",
|
|
14878
|
+
envVar: "NEXT_PUBLIC_OPENFRAME_DASHBOARD_URL",
|
|
14879
|
+
pseudo: true
|
|
14880
|
+
},
|
|
14881
|
+
{ key: "universal", defaultUrl: "https://www.flamingo.run", envVar: "NEXT_PUBLIC_FLAMINGO_URL" }
|
|
14882
|
+
];
|
|
14883
|
+
var ENV_OVERRIDES = {
|
|
14884
|
+
NEXT_PUBLIC_MARKETING_HUB_URL: process.env.NEXT_PUBLIC_MARKETING_HUB_URL,
|
|
14885
|
+
NEXT_PUBLIC_COMPANY_HUB_URL: process.env.NEXT_PUBLIC_COMPANY_HUB_URL,
|
|
14886
|
+
NEXT_PUBLIC_PRODUCT_HUB_URL: process.env.NEXT_PUBLIC_PRODUCT_HUB_URL,
|
|
14887
|
+
NEXT_PUBLIC_REVENUE_HUB_URL: process.env.NEXT_PUBLIC_REVENUE_HUB_URL,
|
|
14888
|
+
NEXT_PUBLIC_PEOPLE_HUB_URL: process.env.NEXT_PUBLIC_PEOPLE_HUB_URL,
|
|
14889
|
+
NEXT_PUBLIC_OPENMSP_URL: process.env.NEXT_PUBLIC_OPENMSP_URL,
|
|
14890
|
+
NEXT_PUBLIC_FLAMINGO_URL: process.env.NEXT_PUBLIC_FLAMINGO_URL,
|
|
14891
|
+
NEXT_PUBLIC_TMCG_URL: process.env.NEXT_PUBLIC_TMCG_URL,
|
|
14892
|
+
NEXT_PUBLIC_MLG_URL: process.env.NEXT_PUBLIC_MLG_URL,
|
|
14893
|
+
NEXT_PUBLIC_OPENFRAME_URL: process.env.NEXT_PUBLIC_OPENFRAME_URL,
|
|
14894
|
+
NEXT_PUBLIC_OPENFRAME_DASHBOARD_URL: process.env.NEXT_PUBLIC_OPENFRAME_DASHBOARD_URL
|
|
14895
|
+
};
|
|
14896
|
+
function byKey(key) {
|
|
14897
|
+
return PLATFORM_DOMAINS.find((e) => e.key === key);
|
|
14898
|
+
}
|
|
14899
|
+
function envOverrideFor(key) {
|
|
14900
|
+
const envVar = byKey(key)?.envVar;
|
|
14901
|
+
if (!envVar) return null;
|
|
14902
|
+
return ENV_OVERRIDES[envVar] || null;
|
|
14903
|
+
}
|
|
14904
|
+
function ensureScheme(url) {
|
|
14905
|
+
const trimmed = url.trim();
|
|
14906
|
+
if (/^[a-z][a-z0-9+.-]*:\/\//i.test(trimmed)) return trimmed;
|
|
14907
|
+
return `https://${trimmed.replace(/^\/+/, "")}`;
|
|
14908
|
+
}
|
|
14909
|
+
function getPlatformProductionUrl(platform) {
|
|
14910
|
+
const resolved = envOverrideFor(platform) ?? byKey(platform)?.defaultUrl ?? envOverrideFor("flamingo") ?? "https://www.flamingo.run";
|
|
14911
|
+
return ensureScheme(resolved);
|
|
14912
|
+
}
|
|
14913
|
+
function getPlatformUrl(platform, options = {}) {
|
|
14914
|
+
const url = options.environment !== "production" && process.env.NODE_ENV !== "production" ? process.env.NEXT_PUBLIC_DEV_URL || "http://localhost:3000" : getPlatformProductionUrl(platform);
|
|
14915
|
+
return url.replace(/\/+$/, "");
|
|
14916
|
+
}
|
|
14917
|
+
function getDeploymentUrl(options) {
|
|
14918
|
+
if (typeof window !== "undefined") return window.location.origin;
|
|
14919
|
+
const configured = options.configuredUrl?.trim();
|
|
14920
|
+
if (configured) return ensureScheme(configured).replace(/\/+$/, "");
|
|
14921
|
+
if (process.env.VERCEL_ENV === "preview" && process.env.VERCEL_URL) {
|
|
14922
|
+
return ensureScheme(process.env.VERCEL_URL).replace(/\/+$/, "");
|
|
14923
|
+
}
|
|
14924
|
+
if (process.env.VERCEL_ENV === "production" || process.env.NODE_ENV === "production") {
|
|
14925
|
+
return getPlatformUrl(options.platform, { environment: "production" });
|
|
14926
|
+
}
|
|
14927
|
+
return (process.env.NEXT_PUBLIC_DEV_URL || `http://localhost:${process.env.PORT ?? 3e3}`).replace(/\/+$/, "");
|
|
14928
|
+
}
|
|
14929
|
+
var LOCAL_HOSTNAME = /^(localhost|127(?:\.\d{1,3}){3}|0\.0\.0\.0|\[::1\])$/i;
|
|
14930
|
+
function isLocalUrl(url) {
|
|
14931
|
+
try {
|
|
14932
|
+
return LOCAL_HOSTNAME.test(new URL(url).hostname);
|
|
14933
|
+
} catch {
|
|
14934
|
+
return false;
|
|
14935
|
+
}
|
|
14936
|
+
}
|
|
14937
|
+
function getRequestOrigin(headers, options) {
|
|
14938
|
+
const host = headers.get("host");
|
|
14939
|
+
if (!host) return getDeploymentUrl(options);
|
|
14940
|
+
const local = LOCAL_HOSTNAME.test(host.replace(/:\d+$/, ""));
|
|
14941
|
+
const proto = headers.get("x-forwarded-proto")?.split(",")[0].trim() || (local ? "http" : "https");
|
|
14942
|
+
return `${proto}://${host}`;
|
|
14943
|
+
}
|
|
14944
|
+
function resolveRedirectTarget(origin, target) {
|
|
14945
|
+
const url = new URL(target, origin);
|
|
14946
|
+
if (!/^https?:\/\//i.test(target) && url.origin !== new URL(origin).origin) {
|
|
14947
|
+
throw new Error(`resolveRedirectTarget: "${target}" is not a same-origin path`);
|
|
14948
|
+
}
|
|
14949
|
+
return url;
|
|
14950
|
+
}
|
|
14951
|
+
function hostOf(value) {
|
|
14952
|
+
if (!value) return null;
|
|
14953
|
+
try {
|
|
14954
|
+
return new URL(value).hostname.toLowerCase();
|
|
14955
|
+
} catch {
|
|
14956
|
+
return null;
|
|
14957
|
+
}
|
|
14958
|
+
}
|
|
14959
|
+
function expandWwwApex(host) {
|
|
14960
|
+
if (host.startsWith("www.")) return [host, host.slice(4)];
|
|
14961
|
+
if (host.split(".").length === 2) return [host, `www.${host}`];
|
|
14962
|
+
return [host];
|
|
14963
|
+
}
|
|
14964
|
+
function toRegistrableBaseDomain(host) {
|
|
14965
|
+
const parts = host.split(".");
|
|
14966
|
+
if (parts.length >= 2) return parts.slice(-2).join(".");
|
|
14967
|
+
return void 0;
|
|
14968
|
+
}
|
|
14969
|
+
function aliasHostsOf(key) {
|
|
14970
|
+
return byKey(key)?.aliasHostnames ?? [];
|
|
14971
|
+
}
|
|
14972
|
+
function hostsForEntry(entry, opts) {
|
|
14973
|
+
const resolved = hostOf(getPlatformProductionUrl(entry.key));
|
|
14974
|
+
const hosts = resolved ? expandWwwApex(resolved) : [];
|
|
14975
|
+
if (opts.includeAliases) hosts.push(...aliasHostsOf(entry.key));
|
|
14976
|
+
return hosts;
|
|
14977
|
+
}
|
|
14978
|
+
function getPlatformByHostname(hostname) {
|
|
14979
|
+
const host = hostname.toLowerCase();
|
|
14980
|
+
for (const entry of PLATFORM_DOMAINS) {
|
|
14981
|
+
if (entry.pseudo) continue;
|
|
14982
|
+
if (hostsForEntry(entry, { includeAliases: true }).includes(host)) return entry.key;
|
|
14983
|
+
}
|
|
14984
|
+
return null;
|
|
14985
|
+
}
|
|
14986
|
+
function isPreviewHost(hostname) {
|
|
14987
|
+
return hostname.endsWith(".vercel.app");
|
|
14988
|
+
}
|
|
14989
|
+
function getAllPlatformBaseDomains() {
|
|
14990
|
+
if (typeof window === "undefined") return [];
|
|
14991
|
+
const hostname = window.location.hostname;
|
|
14992
|
+
if (hostname === "localhost" || hostname === "127.0.0.1" || hostname.startsWith("127.")) {
|
|
14993
|
+
return [];
|
|
14994
|
+
}
|
|
14995
|
+
const previewEnv = process.env.VERCEL_ENV === "preview" || process.env.NEXT_PUBLIC_VERCEL_ENV === "preview" || isPreviewHost(hostname);
|
|
14996
|
+
if (previewEnv) {
|
|
14997
|
+
return [".vercel.app", "vercel.app"];
|
|
14998
|
+
}
|
|
14999
|
+
const baseDomains = /* @__PURE__ */ new Set();
|
|
15000
|
+
for (const entry of PLATFORM_DOMAINS) {
|
|
15001
|
+
if (entry.pseudo) continue;
|
|
15002
|
+
const host = hostOf(getPlatformProductionUrl(entry.key));
|
|
15003
|
+
if (!host) continue;
|
|
15004
|
+
const base = toRegistrableBaseDomain(host);
|
|
15005
|
+
if (base) {
|
|
15006
|
+
baseDomains.add(`.${base}`);
|
|
15007
|
+
baseDomains.add(base);
|
|
15008
|
+
}
|
|
15009
|
+
}
|
|
15010
|
+
return Array.from(baseDomains);
|
|
15011
|
+
}
|
|
15012
|
+
var _orderIdx = (k) => PLATFORM_DOMAINS.findIndex((e) => e.key === k);
|
|
15013
|
+
if (_orderIdx("flamingo") > _orderIdx("flamingo-teaser") || _orderIdx("flamingo") > _orderIdx("universal") || getPlatformByHostname("flamingo.cx") !== "flamingo-teaser" || getPlatformByHostname("hub.openframe.ai") !== "openframe") {
|
|
15014
|
+
console.error(
|
|
15015
|
+
"[platform-domains] \u26A0\uFE0F PLATFORM_DOMAINS ordering invariant violated \u2014 `flamingo` must precede `flamingo-teaser`/`universal`, and the openframe/teaser aliases must be intact. Do not reorder the table."
|
|
15016
|
+
);
|
|
15017
|
+
}
|
|
15018
|
+
|
|
15019
|
+
// src/components/chat/utils/source-row-cta.ts
|
|
14848
15020
|
function sanitizePath(path) {
|
|
14849
15021
|
return (path || "").replace(/[^a-zA-Z0-9/_\-.]/g, "");
|
|
14850
15022
|
}
|
|
@@ -14879,11 +15051,11 @@ function resolveSourceRowCTA(row, ctx = {}) {
|
|
|
14879
15051
|
const docTarget = row.documentType ? ctx.docPlatformTargets?.[row.documentType] : void 0;
|
|
14880
15052
|
if (docTarget) {
|
|
14881
15053
|
const seg = docTarget.basePath.split("/").filter(Boolean).join("/");
|
|
14882
|
-
const base = `${
|
|
15054
|
+
const base = `${getPlatformUrl(docTarget.platform)}${seg ? `/${seg}` : ""}/`;
|
|
14883
15055
|
href = safeHref(new URL(safePath, base).toString()) ?? null;
|
|
14884
15056
|
targetPlatform = docTarget.platform;
|
|
14885
15057
|
} else if (ctx.chipBasePlatform) {
|
|
14886
|
-
const base = `${
|
|
15058
|
+
const base = `${getPlatformUrl(ctx.chipBasePlatform)}/knowledge-base/`;
|
|
14887
15059
|
href = safeHref(new URL(safePath, base).toString()) ?? null;
|
|
14888
15060
|
targetPlatform = ctx.chipBasePlatform;
|
|
14889
15061
|
} else if (ctx.baseRoute) {
|
|
@@ -25068,15 +25240,45 @@ function EmbeddableChatInner({
|
|
|
25068
25240
|
const handleNewChat = useCallback27(() => {
|
|
25069
25241
|
resetToNewChat();
|
|
25070
25242
|
}, [resetToNewChat]);
|
|
25243
|
+
const [pendingDraft, setPendingDraft] = useState48(null);
|
|
25244
|
+
const [seededDraft, setSeededDraft] = useState48(null);
|
|
25245
|
+
if (pendingDraft && seededDraft !== pendingDraft) {
|
|
25246
|
+
setSeededDraft(pendingDraft);
|
|
25247
|
+
setContextItems(pendingDraft.mentions);
|
|
25248
|
+
}
|
|
25249
|
+
const appliedDraftRef = useRef35(null);
|
|
25250
|
+
useEffect38(() => {
|
|
25251
|
+
const draft = pendingDraft;
|
|
25252
|
+
if (!draft || appliedDraftRef.current === draft) return;
|
|
25253
|
+
const input = chatInputRef.current;
|
|
25254
|
+
if (!input) return;
|
|
25255
|
+
appliedDraftRef.current = draft;
|
|
25256
|
+
input.clear();
|
|
25257
|
+
for (const item of draft.mentions) {
|
|
25258
|
+
const key = `${item.type}:${item.id}`;
|
|
25259
|
+
input.commitMention(mentionTokenOf(key, mentionMarkerByType), {
|
|
25260
|
+
label: item.label,
|
|
25261
|
+
icon: resolveContextIcon(item)
|
|
25262
|
+
});
|
|
25263
|
+
mentionKeysRef.current.add(key);
|
|
25264
|
+
}
|
|
25265
|
+
if (draft.text) input.setValue(`${input.getValue()}${draft.mentions.length > 0 ? "\n" : ""}${draft.text}`);
|
|
25266
|
+
}, [pendingDraft, composeOpen, activeDialogId, activeMode, archiveOpen, mentionMarkerByType, resolveContextIcon]);
|
|
25071
25267
|
useImperativeHandle4(
|
|
25072
25268
|
handleRef,
|
|
25073
25269
|
() => ({
|
|
25074
25270
|
startNewChat: () => {
|
|
25075
25271
|
resetToNewChat();
|
|
25076
25272
|
setComposeOpen(true);
|
|
25273
|
+
},
|
|
25274
|
+
prefillDraft: ({ text: text2, mentions = [] }) => {
|
|
25275
|
+
resetToNewChat();
|
|
25276
|
+
setComposeOpen(true);
|
|
25277
|
+
mentionKeysRef.current.clear();
|
|
25278
|
+
setPendingDraft({ text: text2, mentions: mentions.slice(0, contextMaxItems) });
|
|
25077
25279
|
}
|
|
25078
25280
|
}),
|
|
25079
|
-
[resetToNewChat]
|
|
25281
|
+
[resetToNewChat, contextMaxItems]
|
|
25080
25282
|
);
|
|
25081
25283
|
const splitHeaderMenuItems = [
|
|
25082
25284
|
headerOnCopyLink && { id: "copy-link", label: "Copy chat link", onClick: headerOnCopyLink },
|
|
@@ -25842,6 +26044,14 @@ export {
|
|
|
25842
26044
|
getSourceLabel,
|
|
25843
26045
|
DEFAULT_DOCUMENT_TYPE_TO_TABLE_ID,
|
|
25844
26046
|
defaultTableIdForDocumentType,
|
|
26047
|
+
byKey,
|
|
26048
|
+
getPlatformProductionUrl,
|
|
26049
|
+
getPlatformUrl,
|
|
26050
|
+
getDeploymentUrl,
|
|
26051
|
+
isLocalUrl,
|
|
26052
|
+
getRequestOrigin,
|
|
26053
|
+
resolveRedirectTarget,
|
|
26054
|
+
getAllPlatformBaseDomains,
|
|
25845
26055
|
resolveSourceRowCTA,
|
|
25846
26056
|
resolveSourceIcon,
|
|
25847
26057
|
chatCardLabel,
|
|
@@ -25928,4 +26138,4 @@ export {
|
|
|
25928
26138
|
buildStreamFrames,
|
|
25929
26139
|
EmbeddableChat
|
|
25930
26140
|
};
|
|
25931
|
-
//# sourceMappingURL=chunk-
|
|
26141
|
+
//# sourceMappingURL=chunk-DULSS7R6.js.map
|