@burdenoff/website-sdk 2026.1031.3 → 2026.1101.2
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 +42 -8
- package/dist/analytics/index.js +19 -69
- package/dist/analytics/index.js.map +1 -1
- package/dist/analytics/index.mjs +3 -69
- package/dist/analytics/index.mjs.map +1 -1
- package/dist/avatar-live/index.js +1 -0
- package/dist/avatar-live/index.js.map +1 -1
- package/dist/avatar-live/index.mjs +1 -0
- package/dist/avatar-live/index.mjs.map +1 -1
- package/dist/avatar-live-view/index.js +10 -30
- package/dist/avatar-live-view/index.js.map +1 -1
- package/dist/avatar-live-view/index.mjs +4 -24
- package/dist/avatar-live-view/index.mjs.map +1 -1
- package/dist/chunk-23H4JUL4.js +41 -0
- package/dist/chunk-23H4JUL4.js.map +1 -0
- package/dist/chunk-34RX5P75.mjs +25 -0
- package/dist/chunk-34RX5P75.mjs.map +1 -0
- package/dist/chunk-3LFFY7AZ.js +184 -0
- package/dist/chunk-3LFFY7AZ.js.map +1 -0
- package/dist/chunk-3X26GE4S.js +2794 -0
- package/dist/chunk-3X26GE4S.js.map +1 -0
- package/dist/chunk-45GCA4GG.js +85 -0
- package/dist/chunk-45GCA4GG.js.map +1 -0
- package/dist/chunk-4SAGVLHN.js +876 -0
- package/dist/chunk-4SAGVLHN.js.map +1 -0
- package/dist/chunk-4U6YAII5.js +218 -0
- package/dist/chunk-4U6YAII5.js.map +1 -0
- package/dist/chunk-5GMTBOO6.js +21 -0
- package/dist/chunk-5GMTBOO6.js.map +1 -0
- package/dist/chunk-5JRJ57CL.mjs +329 -0
- package/dist/chunk-5JRJ57CL.mjs.map +1 -0
- package/dist/chunk-6C2DKIC7.js +4 -0
- package/dist/chunk-6C2DKIC7.js.map +1 -0
- package/dist/chunk-6IBFBWC5.mjs +17 -0
- package/dist/chunk-6IBFBWC5.mjs.map +1 -0
- package/dist/chunk-6KY2ZRVI.js +116 -0
- package/dist/chunk-6KY2ZRVI.js.map +1 -0
- package/dist/chunk-6VJT3SM4.mjs +182 -0
- package/dist/chunk-6VJT3SM4.mjs.map +1 -0
- package/dist/chunk-6YZUFMK2.mjs +40 -0
- package/dist/chunk-6YZUFMK2.mjs.map +1 -0
- package/dist/chunk-7A6R7CGG.js +47 -0
- package/dist/chunk-7A6R7CGG.js.map +1 -0
- package/dist/chunk-7PWL4V2R.js +4 -0
- package/dist/chunk-7PWL4V2R.js.map +1 -0
- package/dist/chunk-AA33WDYS.js +161 -0
- package/dist/chunk-AA33WDYS.js.map +1 -0
- package/dist/chunk-AHRGFXV2.js +525 -0
- package/dist/chunk-AHRGFXV2.js.map +1 -0
- package/dist/chunk-B63XLDZH.mjs +109 -0
- package/dist/chunk-B63XLDZH.mjs.map +1 -0
- package/dist/chunk-BX2USEWF.mjs +35 -0
- package/dist/chunk-BX2USEWF.mjs.map +1 -0
- package/dist/chunk-BYSZT35R.js +150 -0
- package/dist/chunk-BYSZT35R.js.map +1 -0
- package/dist/chunk-C6OJIHNO.js +12 -0
- package/dist/chunk-C6OJIHNO.js.map +1 -0
- package/dist/chunk-COOELBX7.mjs +63 -0
- package/dist/chunk-COOELBX7.mjs.map +1 -0
- package/dist/chunk-D2TW7MNC.mjs +2771 -0
- package/dist/chunk-D2TW7MNC.mjs.map +1 -0
- package/dist/chunk-D5KEZ6V6.mjs +3 -0
- package/dist/chunk-D5KEZ6V6.mjs.map +1 -0
- package/dist/chunk-E3GUGJMY.js +46 -0
- package/dist/chunk-E3GUGJMY.js.map +1 -0
- package/dist/chunk-EBZ2HGJ2.mjs +52 -0
- package/dist/chunk-EBZ2HGJ2.mjs.map +1 -0
- package/dist/chunk-EDLTUOIA.mjs +210 -0
- package/dist/chunk-EDLTUOIA.mjs.map +1 -0
- package/dist/chunk-EJQSOT4X.js +4 -0
- package/dist/chunk-EJQSOT4X.js.map +1 -0
- package/dist/chunk-EUPFS6MZ.mjs +2019 -0
- package/dist/chunk-EUPFS6MZ.mjs.map +1 -0
- package/dist/chunk-F3XWDC3B.js +77 -0
- package/dist/chunk-F3XWDC3B.js.map +1 -0
- package/dist/chunk-FFADMVIK.mjs +5127 -0
- package/dist/chunk-FFADMVIK.mjs.map +1 -0
- package/dist/chunk-FJWS7BKT.mjs +3 -0
- package/dist/chunk-FJWS7BKT.mjs.map +1 -0
- package/dist/chunk-FJZJDUOR.mjs +3 -0
- package/dist/chunk-FJZJDUOR.mjs.map +1 -0
- package/dist/chunk-GCFLCO2Z.mjs +145 -0
- package/dist/chunk-GCFLCO2Z.mjs.map +1 -0
- package/dist/chunk-GEXC4LRP.js +61 -0
- package/dist/chunk-GEXC4LRP.js.map +1 -0
- package/dist/chunk-GTRAXQGC.mjs +3 -0
- package/dist/chunk-GTRAXQGC.mjs.map +1 -0
- package/dist/chunk-IKOIRUKW.js +270 -0
- package/dist/chunk-IKOIRUKW.js.map +1 -0
- package/dist/chunk-IXTWOPRN.js +45 -0
- package/dist/chunk-IXTWOPRN.js.map +1 -0
- package/dist/chunk-JDXOXGOK.js +547 -0
- package/dist/chunk-JDXOXGOK.js.map +1 -0
- package/dist/chunk-JSLDWYV7.mjs +558 -0
- package/dist/chunk-JSLDWYV7.mjs.map +1 -0
- package/dist/chunk-JXLSTVBK.js +336 -0
- package/dist/chunk-JXLSTVBK.js.map +1 -0
- package/dist/chunk-KHYXK7FG.mjs +49 -0
- package/dist/chunk-KHYXK7FG.mjs.map +1 -0
- package/dist/chunk-KSMBOWQQ.js +2034 -0
- package/dist/chunk-KSMBOWQQ.js.map +1 -0
- package/dist/chunk-KU2PXHGB.mjs +83 -0
- package/dist/chunk-KU2PXHGB.mjs.map +1 -0
- package/dist/chunk-KZANIV3S.mjs +37 -0
- package/dist/chunk-KZANIV3S.mjs.map +1 -0
- package/dist/chunk-L4BP6YOB.js +20 -0
- package/dist/chunk-L4BP6YOB.js.map +1 -0
- package/dist/chunk-MRKA2OAF.mjs +75 -0
- package/dist/chunk-MRKA2OAF.mjs.map +1 -0
- package/dist/chunk-N5EC53MH.mjs +80 -0
- package/dist/chunk-N5EC53MH.mjs.map +1 -0
- package/dist/chunk-NZANQGDM.mjs +34 -0
- package/dist/chunk-NZANQGDM.mjs.map +1 -0
- package/dist/chunk-O4GS3XPZ.js +10 -0
- package/dist/chunk-O4GS3XPZ.js.map +1 -0
- package/dist/chunk-O76QDGRM.js +5154 -0
- package/dist/chunk-O76QDGRM.js.map +1 -0
- package/dist/chunk-OYEUNZJY.js +114 -0
- package/dist/chunk-OYEUNZJY.js.map +1 -0
- package/dist/chunk-PHXAGQNB.js +74 -0
- package/dist/chunk-PHXAGQNB.js.map +1 -0
- package/dist/chunk-PIHHPP7J.mjs +16 -0
- package/dist/chunk-PIHHPP7J.mjs.map +1 -0
- package/dist/chunk-PXRHVVOU.mjs +499 -0
- package/dist/chunk-PXRHVVOU.mjs.map +1 -0
- package/dist/chunk-QMA6U6AU.js +36 -0
- package/dist/chunk-QMA6U6AU.js.map +1 -0
- package/dist/chunk-R6J7IULF.js +44 -0
- package/dist/chunk-R6J7IULF.js.map +1 -0
- package/dist/chunk-R7G6TWIS.mjs +10 -0
- package/dist/chunk-R7G6TWIS.mjs.map +1 -0
- package/dist/chunk-RUMGFI6L.mjs +544 -0
- package/dist/chunk-RUMGFI6L.mjs.map +1 -0
- package/dist/chunk-S54JWSJF.js +565 -0
- package/dist/chunk-S54JWSJF.js.map +1 -0
- package/dist/chunk-SK5UGG6A.js +2041 -0
- package/dist/chunk-SK5UGG6A.js.map +1 -0
- package/dist/chunk-SKIYDKIS.mjs +70 -0
- package/dist/chunk-SKIYDKIS.mjs.map +1 -0
- package/dist/chunk-SZNS5IK6.mjs +322 -0
- package/dist/chunk-SZNS5IK6.mjs.map +1 -0
- package/dist/chunk-T7JIPZAC.js +66 -0
- package/dist/chunk-T7JIPZAC.js.map +1 -0
- package/dist/chunk-TGYQHO2E.mjs +864 -0
- package/dist/chunk-TGYQHO2E.mjs.map +1 -0
- package/dist/chunk-TT3MHN42.mjs +8 -0
- package/dist/chunk-TT3MHN42.mjs.map +1 -0
- package/dist/chunk-UM55U65W.mjs +268 -0
- package/dist/chunk-UM55U65W.mjs.map +1 -0
- package/dist/chunk-UQ2HALUD.js +72 -0
- package/dist/chunk-UQ2HALUD.js.map +1 -0
- package/dist/chunk-UXWT7G77.js +82 -0
- package/dist/chunk-UXWT7G77.js.map +1 -0
- package/dist/chunk-VNS5WDWO.mjs +7 -0
- package/dist/chunk-VNS5WDWO.mjs.map +1 -0
- package/dist/chunk-VRWZLGR7.js +4 -0
- package/dist/chunk-VRWZLGR7.js.map +1 -0
- package/dist/chunk-VZLDSNH4.mjs +22 -0
- package/dist/chunk-VZLDSNH4.mjs.map +1 -0
- package/dist/chunk-W6P3YETJ.js +92 -0
- package/dist/chunk-W6P3YETJ.js.map +1 -0
- package/dist/chunk-WPKFFQCR.mjs +90 -0
- package/dist/chunk-WPKFFQCR.mjs.map +1 -0
- package/dist/chunk-WTVTI5TO.mjs +22 -0
- package/dist/chunk-WTVTI5TO.mjs.map +1 -0
- package/dist/chunk-XJOBZ4RJ.js +44 -0
- package/dist/chunk-XJOBZ4RJ.js.map +1 -0
- package/dist/chunk-XP2JDNDU.js +325 -0
- package/dist/chunk-XP2JDNDU.js.map +1 -0
- package/dist/chunk-Y4V5CEWD.mjs +112 -0
- package/dist/chunk-Y4V5CEWD.mjs.map +1 -0
- package/dist/chunk-YERN2UWM.js +116 -0
- package/dist/chunk-YERN2UWM.js.map +1 -0
- package/dist/chunk-ZKJQWFAA.mjs +114 -0
- package/dist/chunk-ZKJQWFAA.mjs.map +1 -0
- package/dist/chunk-ZOON3S3Y.mjs +138 -0
- package/dist/chunk-ZOON3S3Y.mjs.map +1 -0
- package/dist/chunk-ZP6QRAYC.mjs +2024 -0
- package/dist/chunk-ZP6QRAYC.mjs.map +1 -0
- package/dist/chunk-ZSTFX7FV.js +9 -0
- package/dist/chunk-ZSTFX7FV.js.map +1 -0
- package/dist/client/index.js +23 -331
- package/dist/client/index.js.map +1 -1
- package/dist/client/index.mjs +3 -330
- package/dist/client/index.mjs.map +1 -1
- package/dist/comparison/index.js +28 -111
- package/dist/comparison/index.js.map +1 -1
- package/dist/comparison/index.mjs +2 -107
- package/dist/comparison/index.mjs.map +1 -1
- package/dist/components/contact.js +21 -931
- package/dist/components/contact.js.map +1 -1
- package/dist/components/contact.mjs +12 -909
- package/dist/components/contact.mjs.map +1 -1
- package/dist/components/electron-download.js +12 -124
- package/dist/components/electron-download.js.map +1 -1
- package/dist/components/electron-download.mjs +4 -106
- package/dist/components/electron-download.mjs.map +1 -1
- package/dist/components/explore-cta.js +8 -112
- package/dist/components/explore-cta.js.map +1 -1
- package/dist/components/explore-cta.mjs +3 -114
- package/dist/components/explore-cta.mjs.map +1 -1
- package/dist/components/explore.js +62 -7833
- package/dist/components/explore.js.map +1 -1
- package/dist/components/explore.mjs +13 -7800
- package/dist/components/explore.mjs.map +1 -1
- package/dist/components/launch-countdown.js +8 -83
- package/dist/components/launch-countdown.js.map +1 -1
- package/dist/components/launch-countdown.mjs +3 -85
- package/dist/components/launch-countdown.mjs.map +1 -1
- package/dist/components/newsletter.js +20 -993
- package/dist/components/newsletter.js.map +1 -1
- package/dist/components/newsletter.mjs +11 -971
- package/dist/components/newsletter.mjs.map +1 -1
- package/dist/components/partners.js +24 -1302
- package/dist/components/partners.js.map +1 -1
- package/dist/components/partners.mjs +15 -1276
- package/dist/components/partners.mjs.map +1 -1
- package/dist/components/pricing.js +49 -1249
- package/dist/components/pricing.js.map +1 -1
- package/dist/components/pricing.mjs +8 -1226
- package/dist/components/pricing.mjs.map +1 -1
- package/dist/components/problems-solved.js +8 -150
- package/dist/components/problems-solved.js.map +1 -1
- package/dist/components/problems-solved.mjs +4 -133
- package/dist/components/problems-solved.mjs.map +1 -1
- package/dist/components/resource-links.js +8 -304
- package/dist/components/resource-links.js.map +1 -1
- package/dist/components/resource-links.mjs +5 -308
- package/dist/components/resource-links.mjs.map +1 -1
- package/dist/components/social-links.js +8 -343
- package/dist/components/social-links.js.map +1 -1
- package/dist/components/social-links.mjs +5 -347
- package/dist/components/social-links.mjs.map +1 -1
- package/dist/components/unsubscribe.js +10 -627
- package/dist/components/unsubscribe.js.map +1 -1
- package/dist/components/unsubscribe.mjs +6 -611
- package/dist/components/unsubscribe.mjs.map +1 -1
- package/dist/components/waitlist.js +21 -1001
- package/dist/components/waitlist.js.map +1 -1
- package/dist/components/waitlist.mjs +12 -982
- package/dist/components/waitlist.mjs.map +1 -1
- package/dist/components/website-switcher.js +12 -175
- package/dist/components/website-switcher.js.map +1 -1
- package/dist/components/website-switcher.mjs +4 -157
- package/dist/components/website-switcher.mjs.map +1 -1
- package/dist/content/index.js +118 -3616
- package/dist/content/index.js.map +1 -1
- package/dist/content/index.mjs +12 -3567
- package/dist/content/index.mjs.map +1 -1
- package/dist/hooks/index.js +37 -2321
- package/dist/hooks/index.js.map +1 -1
- package/dist/hooks/index.mjs +6 -2318
- package/dist/hooks/index.mjs.map +1 -1
- package/dist/index.js +4145 -20599
- package/dist/index.js.map +1 -1
- package/dist/index.mjs +3766 -20567
- package/dist/index.mjs.map +1 -1
- package/dist/product/index.js +20 -393
- package/dist/product/index.js.map +1 -1
- package/dist/product/index.mjs +5 -394
- package/dist/product/index.mjs.map +1 -1
- package/dist/seo/index.js +8 -76
- package/dist/seo/index.js.map +1 -1
- package/dist/seo/index.mjs +3 -78
- package/dist/seo/index.mjs.map +1 -1
- package/dist/store/index.js +51 -2650
- package/dist/store/index.js.map +1 -1
- package/dist/store/index.mjs +13 -2619
- package/dist/store/index.mjs.map +1 -1
- package/dist/utils/index.js +69 -134
- package/dist/utils/index.js.map +1 -1
- package/dist/utils/index.mjs +5 -122
- package/dist/utils/index.mjs.map +1 -1
- package/package.json +2 -1
|
@@ -0,0 +1,41 @@
|
|
|
1
|
+
'use strict';
|
|
2
|
+
|
|
3
|
+
// src/components/explore-avatar-live-config.ts
|
|
4
|
+
var AVATAR_WEB_API_PATH = "/api/web-avatar/v1";
|
|
5
|
+
var SITE = /^[a-z][a-z0-9-]{1,31}$/;
|
|
6
|
+
var VERSION = /^[A-Za-z0-9._-]{1,32}$/;
|
|
7
|
+
var SITE_KEY = /^[A-Za-z0-9_-]{1,128}$/;
|
|
8
|
+
var LOOPBACK_HOSTS = /* @__PURE__ */ new Set(["localhost", "127.0.0.1", "[::1]"]);
|
|
9
|
+
function isAvatarSite(value) {
|
|
10
|
+
return SITE.test(value);
|
|
11
|
+
}
|
|
12
|
+
function isAvatarVersion(value) {
|
|
13
|
+
return VERSION.test(value);
|
|
14
|
+
}
|
|
15
|
+
function avatarApiBase(gatewayUrl) {
|
|
16
|
+
if (!gatewayUrl) return null;
|
|
17
|
+
let url;
|
|
18
|
+
try {
|
|
19
|
+
url = new URL(gatewayUrl);
|
|
20
|
+
} catch {
|
|
21
|
+
return null;
|
|
22
|
+
}
|
|
23
|
+
const local = url.protocol === "http:" && LOOPBACK_HOSTS.has(url.hostname.toLowerCase());
|
|
24
|
+
if (url.protocol !== "https:" && !local) return null;
|
|
25
|
+
return `${url.origin}${AVATAR_WEB_API_PATH}`;
|
|
26
|
+
}
|
|
27
|
+
function liveConfigComplete(live) {
|
|
28
|
+
return typeof live.load === "function" && typeof live.site === "string" && isAvatarSite(live.site) && typeof live.manifestVersion === "string" && isAvatarVersion(live.manifestVersion) && typeof live.turnstileSiteKey === "string" && SITE_KEY.test(live.turnstileSiteKey);
|
|
29
|
+
}
|
|
30
|
+
var REVIEWED = /* @__PURE__ */ new Set(["en"]);
|
|
31
|
+
function isAvatarLiveLocaleReviewed(locale) {
|
|
32
|
+
return REVIEWED.has(locale);
|
|
33
|
+
}
|
|
34
|
+
|
|
35
|
+
exports.avatarApiBase = avatarApiBase;
|
|
36
|
+
exports.isAvatarLiveLocaleReviewed = isAvatarLiveLocaleReviewed;
|
|
37
|
+
exports.isAvatarSite = isAvatarSite;
|
|
38
|
+
exports.isAvatarVersion = isAvatarVersion;
|
|
39
|
+
exports.liveConfigComplete = liveConfigComplete;
|
|
40
|
+
//# sourceMappingURL=chunk-23H4JUL4.js.map
|
|
41
|
+
//# sourceMappingURL=chunk-23H4JUL4.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"sources":["../src/components/explore-avatar-live-config.ts"],"names":[],"mappings":";;;AAwCO,IAAM,mBAAA,GAAsB,oBAAA;AAEnC,IAAM,IAAA,GAAO,wBAAA;AACb,IAAM,OAAA,GAAU,wBAAA;AAChB,IAAM,QAAA,GAAW,wBAAA;AACjB,IAAM,iCAAiB,IAAI,GAAA,CAAI,CAAC,WAAA,EAAa,WAAA,EAAa,OAAO,CAAC,CAAA;AAG3D,SAAS,aAAa,KAAA,EAAwB;AACnD,EAAA,OAAO,IAAA,CAAK,KAAK,KAAK,CAAA;AACxB;AAGO,SAAS,gBAAgB,KAAA,EAAwB;AACtD,EAAA,OAAO,OAAA,CAAQ,KAAK,KAAK,CAAA;AAC3B;AAOO,SAAS,cAAc,UAAA,EAA+C;AAC3E,EAAA,IAAI,CAAC,YAAY,OAAO,IAAA;AACxB,EAAA,IAAI,GAAA;AACJ,EAAA,IAAI;AACF,IAAA,GAAA,GAAM,IAAI,IAAI,UAAU,CAAA;AAAA,EAC1B,CAAA,CAAA,MAAQ;AACN,IAAA,OAAO,IAAA;AAAA,EACT;AACA,EAAA,MAAM,KAAA,GACJ,IAAI,QAAA,KAAa,OAAA,IAAW,eAAe,GAAA,CAAI,GAAA,CAAI,QAAA,CAAS,WAAA,EAAa,CAAA;AAC3E,EAAA,IAAI,GAAA,CAAI,QAAA,KAAa,QAAA,IAAY,CAAC,OAAO,OAAO,IAAA;AAChD,EAAA,OAAO,CAAA,EAAG,GAAA,CAAI,MAAM,CAAA,EAAG,mBAAmB,CAAA,CAAA;AAC5C;AAGO,SAAS,mBAAmB,IAAA,EAAuC;AACxE,EAAA,OACE,OAAO,IAAA,CAAK,IAAA,KAAS,UAAA,IACrB,OAAO,IAAA,CAAK,IAAA,KAAS,QAAA,IACrB,YAAA,CAAa,IAAA,CAAK,IAAI,CAAA,IACtB,OAAO,IAAA,CAAK,eAAA,KAAoB,QAAA,IAChC,eAAA,CAAgB,IAAA,CAAK,eAAe,CAAA,IACpC,OAAO,IAAA,CAAK,gBAAA,KAAqB,QAAA,IACjC,QAAA,CAAS,IAAA,CAAK,IAAA,CAAK,gBAAgB,CAAA;AAEvC;AAMA,IAAM,QAAA,mBAAuC,IAAI,GAAA,CAAmB,CAAC,IAAI,CAAC,CAAA;AAGnE,SAAS,2BAA2B,MAAA,EAAgC;AACzE,EAAA,OAAO,QAAA,CAAS,IAAI,MAAM,CAAA;AAC5B","file":"chunk-23H4JUL4.js","sourcesContent":["/**\n * BOFF-9797. The small part of the live avatar that the panel itself needs, whether or not it is ever opened: what a\n * host's `avatar.live` is, whether the live avatar can run on this page at all, and where its requests go.\n *\n * Everything else (the view, its state machine, the requests, the words, the bot check) is a separate chunk that a\n * site only downloads when its visitor first opens the Avatar view (see `explore-avatar-live.tsx`). That is why this\n * file is separate and kept to a few lines: it is the only part of the live avatar in the package root for a site that\n * does not pass `avatar.live`, and the part of it that decides, without loading anything, whether the chunk is wanted.\n * Types only, plus plain functions: nothing here imports a component, a context or a string table.\n */\nimport type { ExploreLocale } from \"./explore-i18n\";\nimport type { AvatarLiveModule } from \"../avatar-live/types\";\nimport type { UseExploreChatResult } from \"../hooks/use-explore-chat\";\n\n/**\n * BOFF-9797. A host's opt-in to the live avatar on its panel's Avatar tab. Every field is required; a config that is\n * incomplete leaves the tab as it was (and a warning in the console).\n */\nexport interface ExplorePanelAvatarLive {\n /** The site, as the live avatar service knows it: `healthybowl`. */\n site: string;\n /**\n * Loads the live avatar's room module: `() => import('@burdenoff/website-sdk/avatar-live')`. Called only after the\n * visitor presses Start on the consent card, never on page load or on opening the tab. That entry needs the\n * package's optional peer dependency for media rooms (see the README).\n */\n load: () => Promise<AvatarLiveModule>;\n /** The site's Cloudflare Turnstile site key, for the bot check that runs when the visitor presses Start. */\n turnstileSiteKey: string;\n /** The version of the suggested-question list the panel shows (its `examplePrompts`), such as `hb-en-1`. */\n manifestVersion: string;\n}\n\n/** What the live avatar reads of the panel's conversation: the transcript, whether it is read-only, and the token. */\nexport type AvatarConversation = Pick<\n UseExploreChatResult,\n \"messages\" | \"isSharedView\" | \"getConversationToken\"\n>;\n\n/** The web branch's routes, under the gateway's origin. */\nexport const AVATAR_WEB_API_PATH = \"/api/web-avatar/v1\";\n\nconst SITE = /^[a-z][a-z0-9-]{1,31}$/;\nconst VERSION = /^[A-Za-z0-9._-]{1,32}$/;\nconst SITE_KEY = /^[A-Za-z0-9_-]{1,128}$/;\nconst LOOPBACK_HOSTS = new Set([\"localhost\", \"127.0.0.1\", \"[::1]\"]);\n\n/** A site slug the contract accepts (`healthybowl`). */\nexport function isAvatarSite(value: string): boolean {\n return SITE.test(value);\n}\n\n/** A consent or manifest version the contract accepts (`hb-en-1`). */\nexport function isAvatarVersion(value: string): boolean {\n return VERSION.test(value);\n}\n\n/**\n * The web branch's base URL on the SDK's configured gateway: the gateway URL's origin, plus\n * {@link AVATAR_WEB_API_PATH}. Null for anything that is not an `https:` URL (or `http:` on this machine, for local\n * development).\n */\nexport function avatarApiBase(gatewayUrl: string | undefined): string | null {\n if (!gatewayUrl) return null;\n let url: URL;\n try {\n url = new URL(gatewayUrl);\n } catch {\n return null;\n }\n const local =\n url.protocol === \"http:\" && LOOPBACK_HOSTS.has(url.hostname.toLowerCase());\n if (url.protocol !== \"https:\" && !local) return null;\n return `${url.origin}${AVATAR_WEB_API_PATH}`;\n}\n\n/** Whether a host's `avatar.live` has everything the live avatar needs, in the shapes the contract accepts. */\nexport function liveConfigComplete(live: ExplorePanelAvatarLive): boolean {\n return (\n typeof live.load === \"function\" &&\n typeof live.site === \"string\" &&\n isAvatarSite(live.site) &&\n typeof live.manifestVersion === \"string\" &&\n isAvatarVersion(live.manifestVersion) &&\n typeof live.turnstileSiteKey === \"string\" &&\n SITE_KEY.test(live.turnstileSiteKey)\n );\n}\n\n/**\n * The locales whose live-avatar strings have been reviewed. The live avatar runs only in these; see\n * `explore-avatar-i18n.ts`. English only, until a named reviewer signs off on another.\n */\nconst REVIEWED: ReadonlySet<ExploreLocale> = new Set<ExploreLocale>([\"en\"]);\n\n/** Whether the live avatar may run in `locale`: its strings have been reviewed. */\nexport function isAvatarLiveLocaleReviewed(locale: ExploreLocale): boolean {\n return REVIEWED.has(locale);\n}\n"]}
|
|
@@ -0,0 +1,25 @@
|
|
|
1
|
+
import { cn } from './chunk-R7G6TWIS.mjs';
|
|
2
|
+
import * as React from 'react';
|
|
3
|
+
import { jsx } from 'react/jsx-runtime';
|
|
4
|
+
|
|
5
|
+
var Input = React.forwardRef(
|
|
6
|
+
({ className, type, ...props }, ref) => {
|
|
7
|
+
return /* @__PURE__ */ jsx(
|
|
8
|
+
"input",
|
|
9
|
+
{
|
|
10
|
+
type,
|
|
11
|
+
className: cn(
|
|
12
|
+
"flex h-9 w-full rounded-md border border-input bg-transparent px-3 py-1 text-base shadow-sm transition-colors file:border-0 file:bg-transparent file:text-sm file:font-medium file:text-foreground placeholder:text-muted-foreground focus-visible:outline-none focus-visible:ring-1 focus-visible:ring-ring disabled:cursor-not-allowed disabled:opacity-50 md:text-sm",
|
|
13
|
+
className
|
|
14
|
+
),
|
|
15
|
+
ref,
|
|
16
|
+
...props
|
|
17
|
+
}
|
|
18
|
+
);
|
|
19
|
+
}
|
|
20
|
+
);
|
|
21
|
+
Input.displayName = "Input";
|
|
22
|
+
|
|
23
|
+
export { Input };
|
|
24
|
+
//# sourceMappingURL=chunk-34RX5P75.mjs.map
|
|
25
|
+
//# sourceMappingURL=chunk-34RX5P75.mjs.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"sources":["../src/ui/input.tsx"],"names":[],"mappings":";;;;AAIA,IAAM,KAAA,GAAc,KAAA,CAAA,UAAA;AAAA,EAClB,CAAC,EAAE,SAAA,EAAW,MAAM,GAAG,KAAA,IAAS,GAAA,KAAQ;AACtC,IAAA,uBACE,GAAA;AAAA,MAAC,OAAA;AAAA,MAAA;AAAA,QACC,IAAA;AAAA,QACA,SAAA,EAAW,EAAA;AAAA,UACT,yWAAA;AAAA,UACA;AAAA,SACF;AAAA,QACA,GAAA;AAAA,QACC,GAAG;AAAA;AAAA,KACN;AAAA,EAEJ;AACF;AACA,KAAA,CAAM,WAAA,GAAc,OAAA","file":"chunk-34RX5P75.mjs","sourcesContent":["import * as React from \"react\";\n\nimport { cn } from \"../utils/cn\";\n\nconst Input = React.forwardRef<HTMLInputElement, React.ComponentProps<\"input\">>(\n ({ className, type, ...props }, ref) => {\n return (\n <input\n type={type}\n className={cn(\n \"flex h-9 w-full rounded-md border border-input bg-transparent px-3 py-1 text-base shadow-sm transition-colors file:border-0 file:bg-transparent file:text-sm file:font-medium file:text-foreground placeholder:text-muted-foreground focus-visible:outline-none focus-visible:ring-1 focus-visible:ring-ring disabled:cursor-not-allowed disabled:opacity-50 md:text-sm\",\n className,\n )}\n ref={ref}\n {...props}\n />\n );\n },\n);\nInput.displayName = \"Input\";\n\nexport { Input };\n"]}
|
|
@@ -0,0 +1,184 @@
|
|
|
1
|
+
'use strict';
|
|
2
|
+
|
|
3
|
+
var jsxRuntime = require('react/jsx-runtime');
|
|
4
|
+
|
|
5
|
+
var PROSE_CSS = `
|
|
6
|
+
.boff-prose {
|
|
7
|
+
max-width: none;
|
|
8
|
+
}
|
|
9
|
+
|
|
10
|
+
.boff-prose h1 {
|
|
11
|
+
font-size: 2.25rem;
|
|
12
|
+
font-weight: 800;
|
|
13
|
+
line-height: 1.2;
|
|
14
|
+
margin-top: 0;
|
|
15
|
+
margin-bottom: 1rem;
|
|
16
|
+
color: hsl(var(--foreground));
|
|
17
|
+
}
|
|
18
|
+
|
|
19
|
+
.boff-prose h2 {
|
|
20
|
+
font-size: 1.75rem;
|
|
21
|
+
font-weight: 700;
|
|
22
|
+
line-height: 1.3;
|
|
23
|
+
margin-top: 2rem;
|
|
24
|
+
margin-bottom: 1rem;
|
|
25
|
+
color: hsl(var(--foreground));
|
|
26
|
+
}
|
|
27
|
+
|
|
28
|
+
.boff-prose h3 {
|
|
29
|
+
font-size: 1.5rem;
|
|
30
|
+
font-weight: 600;
|
|
31
|
+
line-height: 1.4;
|
|
32
|
+
margin-top: 1.5rem;
|
|
33
|
+
margin-bottom: 0.75rem;
|
|
34
|
+
color: hsl(var(--foreground));
|
|
35
|
+
}
|
|
36
|
+
|
|
37
|
+
.boff-prose h4 {
|
|
38
|
+
font-size: 1.25rem;
|
|
39
|
+
font-weight: 600;
|
|
40
|
+
line-height: 1.5;
|
|
41
|
+
margin-top: 1.25rem;
|
|
42
|
+
margin-bottom: 0.5rem;
|
|
43
|
+
color: hsl(var(--foreground));
|
|
44
|
+
}
|
|
45
|
+
|
|
46
|
+
.boff-prose p {
|
|
47
|
+
margin-bottom: 1rem;
|
|
48
|
+
line-height: 1.75;
|
|
49
|
+
color: hsl(var(--foreground));
|
|
50
|
+
}
|
|
51
|
+
|
|
52
|
+
.boff-prose ul,
|
|
53
|
+
.boff-prose ol {
|
|
54
|
+
margin-bottom: 1rem;
|
|
55
|
+
padding-left: 1.5rem;
|
|
56
|
+
}
|
|
57
|
+
|
|
58
|
+
.boff-prose ul {
|
|
59
|
+
list-style-type: disc;
|
|
60
|
+
}
|
|
61
|
+
|
|
62
|
+
.boff-prose ol {
|
|
63
|
+
list-style-type: decimal;
|
|
64
|
+
}
|
|
65
|
+
|
|
66
|
+
.boff-prose li {
|
|
67
|
+
margin-bottom: 0.25rem;
|
|
68
|
+
line-height: 1.75;
|
|
69
|
+
color: hsl(var(--foreground));
|
|
70
|
+
}
|
|
71
|
+
|
|
72
|
+
.boff-prose li > ul,
|
|
73
|
+
.boff-prose li > ol {
|
|
74
|
+
margin-top: 0.25rem;
|
|
75
|
+
margin-bottom: 0.25rem;
|
|
76
|
+
}
|
|
77
|
+
|
|
78
|
+
.boff-prose a {
|
|
79
|
+
color: hsl(var(--primary));
|
|
80
|
+
text-decoration: underline;
|
|
81
|
+
text-underline-offset: 2px;
|
|
82
|
+
}
|
|
83
|
+
|
|
84
|
+
.boff-prose a:hover {
|
|
85
|
+
opacity: 0.8;
|
|
86
|
+
}
|
|
87
|
+
|
|
88
|
+
.boff-prose hr {
|
|
89
|
+
border: none;
|
|
90
|
+
height: 1px;
|
|
91
|
+
background-color: hsl(var(--border));
|
|
92
|
+
margin: 2rem 0;
|
|
93
|
+
}
|
|
94
|
+
|
|
95
|
+
.boff-prose blockquote {
|
|
96
|
+
border-left: 4px solid hsl(var(--border));
|
|
97
|
+
padding-left: 1rem;
|
|
98
|
+
margin: 1.5rem 0;
|
|
99
|
+
font-style: italic;
|
|
100
|
+
color: hsl(var(--muted-foreground));
|
|
101
|
+
}
|
|
102
|
+
|
|
103
|
+
.boff-prose strong {
|
|
104
|
+
font-weight: 700;
|
|
105
|
+
color: hsl(var(--foreground));
|
|
106
|
+
}
|
|
107
|
+
|
|
108
|
+
.boff-prose code {
|
|
109
|
+
background-color: hsl(var(--muted));
|
|
110
|
+
padding: 0.125rem 0.25rem;
|
|
111
|
+
border-radius: 0.25rem;
|
|
112
|
+
font-size: 0.875em;
|
|
113
|
+
font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, "Liberation Mono", "Courier New", monospace;
|
|
114
|
+
}
|
|
115
|
+
|
|
116
|
+
.boff-prose pre {
|
|
117
|
+
background-color: hsl(var(--muted));
|
|
118
|
+
padding: 1rem;
|
|
119
|
+
border-radius: 0.5rem;
|
|
120
|
+
overflow-x: auto;
|
|
121
|
+
margin-bottom: 1rem;
|
|
122
|
+
}
|
|
123
|
+
|
|
124
|
+
.boff-prose pre code {
|
|
125
|
+
background-color: transparent;
|
|
126
|
+
padding: 0;
|
|
127
|
+
}
|
|
128
|
+
|
|
129
|
+
.boff-prose img {
|
|
130
|
+
max-width: 100%;
|
|
131
|
+
height: auto;
|
|
132
|
+
}
|
|
133
|
+
|
|
134
|
+
.boff-prose table {
|
|
135
|
+
width: 100%;
|
|
136
|
+
border-collapse: collapse;
|
|
137
|
+
margin-bottom: 1rem;
|
|
138
|
+
}
|
|
139
|
+
|
|
140
|
+
.boff-prose th,
|
|
141
|
+
.boff-prose td {
|
|
142
|
+
border: 1px solid hsl(var(--border));
|
|
143
|
+
padding: 0.5rem;
|
|
144
|
+
text-align: left;
|
|
145
|
+
}
|
|
146
|
+
|
|
147
|
+
.boff-prose th {
|
|
148
|
+
font-weight: 600;
|
|
149
|
+
background-color: hsl(var(--muted));
|
|
150
|
+
}
|
|
151
|
+
|
|
152
|
+
/* Smaller variant used inside cards and compact panels */
|
|
153
|
+
.boff-prose-sm {
|
|
154
|
+
font-size: 0.875rem;
|
|
155
|
+
}
|
|
156
|
+
|
|
157
|
+
.boff-prose-sm h1 {
|
|
158
|
+
font-size: 1.75rem;
|
|
159
|
+
}
|
|
160
|
+
|
|
161
|
+
.boff-prose-sm h2 {
|
|
162
|
+
font-size: 1.5rem;
|
|
163
|
+
}
|
|
164
|
+
|
|
165
|
+
.boff-prose-sm h3 {
|
|
166
|
+
font-size: 1.25rem;
|
|
167
|
+
}
|
|
168
|
+
|
|
169
|
+
.boff-prose-sm h4 {
|
|
170
|
+
font-size: 1.125rem;
|
|
171
|
+
}
|
|
172
|
+
|
|
173
|
+
.boff-prose-sm p,
|
|
174
|
+
.boff-prose-sm li {
|
|
175
|
+
line-height: 1.625;
|
|
176
|
+
}
|
|
177
|
+
`;
|
|
178
|
+
function ProseStyles() {
|
|
179
|
+
return /* @__PURE__ */ jsxRuntime.jsx("style", { dangerouslySetInnerHTML: { __html: PROSE_CSS } });
|
|
180
|
+
}
|
|
181
|
+
|
|
182
|
+
exports.ProseStyles = ProseStyles;
|
|
183
|
+
//# sourceMappingURL=chunk-3LFFY7AZ.js.map
|
|
184
|
+
//# sourceMappingURL=chunk-3LFFY7AZ.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"sources":["../src/content/prose-styles.tsx"],"names":[],"mappings":";;;;AAUO,IAAM,SAAA,GAAY;AAAA;AAAA;AAAA;;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;;AAAA;AAAA;AAAA;AAAA;AAAA;;AAAA;AAAA;AAAA;AAAA;AAAA;;AAAA;AAAA;AAAA;;AAAA;AAAA;AAAA;;AAAA;AAAA;AAAA;AAAA;AAAA;;AAAA;AAAA;AAAA;AAAA;AAAA;;AAAA;AAAA;AAAA;AAAA;AAAA;;AAAA;AAAA;AAAA;;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;;AAAA;AAAA;AAAA;AAAA;;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;;AAAA;AAAA;AAAA;AAAA;;AAAA;AAAA;AAAA;AAAA;;AAAA;AAAA;AAAA;AAAA;AAAA;;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;;AAAA;AAAA;AAAA;AAAA;;AAAA;AAAA;AAAA;AAAA;;AAAA;AAAA;AAAA;;AAAA;AAAA;AAAA;;AAAA;AAAA;AAAA;;AAAA;AAAA;AAAA;;AAAA;AAAA;AAAA;AAAA;AAAA,CAAA;AA8KlB,SAAS,WAAA,GAAc;AAC5B,EAAA,sCAAQ,OAAA,EAAA,EAAM,uBAAA,EAAyB,EAAE,MAAA,EAAQ,WAAU,EAAG,CAAA;AAChE","file":"chunk-3LFFY7AZ.js","sourcesContent":["\"use client\";\n\n/**\n * Self-contained prose styles for SDK content renderers.\n *\n * These components inject a scoped `.boff-prose` stylesheet so markdown content\n * renders correctly even when the host website does not install\n * `@tailwindcss/typography` or define `.prose` CSS.\n */\n\nexport const PROSE_CSS = `\n.boff-prose {\n max-width: none;\n}\n\n.boff-prose h1 {\n font-size: 2.25rem;\n font-weight: 800;\n line-height: 1.2;\n margin-top: 0;\n margin-bottom: 1rem;\n color: hsl(var(--foreground));\n}\n\n.boff-prose h2 {\n font-size: 1.75rem;\n font-weight: 700;\n line-height: 1.3;\n margin-top: 2rem;\n margin-bottom: 1rem;\n color: hsl(var(--foreground));\n}\n\n.boff-prose h3 {\n font-size: 1.5rem;\n font-weight: 600;\n line-height: 1.4;\n margin-top: 1.5rem;\n margin-bottom: 0.75rem;\n color: hsl(var(--foreground));\n}\n\n.boff-prose h4 {\n font-size: 1.25rem;\n font-weight: 600;\n line-height: 1.5;\n margin-top: 1.25rem;\n margin-bottom: 0.5rem;\n color: hsl(var(--foreground));\n}\n\n.boff-prose p {\n margin-bottom: 1rem;\n line-height: 1.75;\n color: hsl(var(--foreground));\n}\n\n.boff-prose ul,\n.boff-prose ol {\n margin-bottom: 1rem;\n padding-left: 1.5rem;\n}\n\n.boff-prose ul {\n list-style-type: disc;\n}\n\n.boff-prose ol {\n list-style-type: decimal;\n}\n\n.boff-prose li {\n margin-bottom: 0.25rem;\n line-height: 1.75;\n color: hsl(var(--foreground));\n}\n\n.boff-prose li > ul,\n.boff-prose li > ol {\n margin-top: 0.25rem;\n margin-bottom: 0.25rem;\n}\n\n.boff-prose a {\n color: hsl(var(--primary));\n text-decoration: underline;\n text-underline-offset: 2px;\n}\n\n.boff-prose a:hover {\n opacity: 0.8;\n}\n\n.boff-prose hr {\n border: none;\n height: 1px;\n background-color: hsl(var(--border));\n margin: 2rem 0;\n}\n\n.boff-prose blockquote {\n border-left: 4px solid hsl(var(--border));\n padding-left: 1rem;\n margin: 1.5rem 0;\n font-style: italic;\n color: hsl(var(--muted-foreground));\n}\n\n.boff-prose strong {\n font-weight: 700;\n color: hsl(var(--foreground));\n}\n\n.boff-prose code {\n background-color: hsl(var(--muted));\n padding: 0.125rem 0.25rem;\n border-radius: 0.25rem;\n font-size: 0.875em;\n font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, \"Liberation Mono\", \"Courier New\", monospace;\n}\n\n.boff-prose pre {\n background-color: hsl(var(--muted));\n padding: 1rem;\n border-radius: 0.5rem;\n overflow-x: auto;\n margin-bottom: 1rem;\n}\n\n.boff-prose pre code {\n background-color: transparent;\n padding: 0;\n}\n\n.boff-prose img {\n max-width: 100%;\n height: auto;\n}\n\n.boff-prose table {\n width: 100%;\n border-collapse: collapse;\n margin-bottom: 1rem;\n}\n\n.boff-prose th,\n.boff-prose td {\n border: 1px solid hsl(var(--border));\n padding: 0.5rem;\n text-align: left;\n}\n\n.boff-prose th {\n font-weight: 600;\n background-color: hsl(var(--muted));\n}\n\n/* Smaller variant used inside cards and compact panels */\n.boff-prose-sm {\n font-size: 0.875rem;\n}\n\n.boff-prose-sm h1 {\n font-size: 1.75rem;\n}\n\n.boff-prose-sm h2 {\n font-size: 1.5rem;\n}\n\n.boff-prose-sm h3 {\n font-size: 1.25rem;\n}\n\n.boff-prose-sm h4 {\n font-size: 1.125rem;\n}\n\n.boff-prose-sm p,\n.boff-prose-sm li {\n line-height: 1.625;\n}\n`;\n\nexport function ProseStyles() {\n return <style dangerouslySetInnerHTML={{ __html: PROSE_CSS }} />;\n}\n"]}
|