@flamingo-stack/openframe-frontend-core 0.0.810 → 0.0.811
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/{case-study-card-MEWJNF4N.cjs → case-study-card-AMINZROX.cjs} +5 -5
- package/dist/{chunk-FRS2VO22.cjs → chunk-243TS7YL.cjs} +38 -38
- package/dist/{chunk-GAHXURKJ.cjs → chunk-5QLDHPPU.cjs} +2 -2
- package/dist/{chunk-MAQFG62O.cjs → chunk-66J7ZSI5.cjs} +34 -34
- package/dist/{chunk-RKNCNL6K.cjs → chunk-6GT3ZL27.cjs} +28 -28
- package/dist/{chunk-PRCGRDHV.cjs → chunk-7Y6M4FW4.cjs} +5 -5
- package/dist/{chunk-TOWVMBAP.cjs → chunk-ACCZCRXT.cjs} +14 -14
- package/dist/{chunk-VXAKQRV7.cjs → chunk-APOMNC7H.cjs} +5 -5
- package/dist/{chunk-3FBXQSSC.cjs → chunk-CB77J5L7.cjs} +858 -664
- package/dist/{chunk-VHX4A4SA.cjs → chunk-CC3Q3MQG.cjs} +2 -2
- package/dist/{chunk-TOTR2WMH.cjs → chunk-CJ7W2SY4.cjs} +8 -8
- package/dist/{chunk-CZWQCYKV.cjs → chunk-CLU2KJFB.cjs} +3 -3
- package/dist/{chunk-OJZBZH56.cjs → chunk-CNTBGJA7.cjs} +3 -3
- package/dist/{chunk-F26COFTW.cjs → chunk-CPP2APON.cjs} +89 -89
- package/dist/{chunk-TT64NRFU.cjs → chunk-ERLMCSGF.cjs} +3 -3
- package/dist/{chunk-RPBOWCME.cjs → chunk-FK2WFU7R.cjs} +17 -17
- package/dist/{chunk-7PNRXJX2.cjs → chunk-FX35L4Y6.cjs} +3 -3
- package/dist/{chunk-5GJM7VRR.cjs → chunk-GI3MMBP3.cjs} +91 -26
- package/dist/{chunk-EKDLVUEA.cjs → chunk-GU3GJ5DH.cjs} +48 -48
- package/dist/{chunk-X2JSCOOR.cjs → chunk-IQLXO6EI.cjs} +97 -97
- package/dist/{chunk-J4QORJMC.cjs → chunk-J6C7F63P.cjs} +113 -113
- package/dist/{chunk-PIKHEBG5.cjs → chunk-JNWJB4Z5.cjs} +52 -52
- package/dist/{chunk-5MTYKS2Q.cjs → chunk-KVDUWXVZ.cjs} +4 -4
- package/dist/{chunk-V4FXUIMH.cjs → chunk-LC65AC6M.cjs} +4 -4
- package/dist/{chunk-FCFYZIOY.cjs → chunk-MDBOYMCW.cjs} +22 -22
- package/dist/{chunk-AQXKXZWB.cjs → chunk-MG3HJIGG.cjs} +4 -4
- package/dist/{chunk-KVJKKVB3.cjs → chunk-NZSWROGM.cjs} +7 -7
- package/dist/{chunk-B6DIM5JG.cjs → chunk-O32RLIN4.cjs} +6 -6
- package/dist/{chunk-2C63MX75.cjs → chunk-O4MEG2ZS.cjs} +21 -21
- package/dist/{chunk-4W77VLQV.cjs → chunk-OQDPZOGC.cjs} +6 -6
- package/dist/{chunk-ZXBRPQND.cjs → chunk-PCVY63WQ.cjs} +17 -17
- package/dist/{chunk-ML3DG4SS.cjs → chunk-PMOMZSCX.cjs} +5 -5
- package/dist/{chunk-TUZV2ZQY.cjs → chunk-Q7QYAINS.cjs} +2 -2
- package/dist/{chunk-ETI7OMPU.cjs → chunk-R55KNVPR.cjs} +71 -71
- package/dist/{chunk-NG3RKTQU.cjs → chunk-SFUNXMY3.cjs} +8 -8
- package/dist/{chunk-GG36TCKP.cjs → chunk-TKK66KHU.cjs} +6 -6
- package/dist/{chunk-TGOJHOQR.cjs → chunk-U2MHQBL4.cjs} +3 -3
- package/dist/{chunk-I3RJLXEL.cjs → chunk-UP3TLY2V.cjs} +131 -131
- package/dist/{chunk-CLMUD56S.cjs → chunk-VXMPVDOS.cjs} +26 -26
- package/dist/{chunk-MSAXZRXZ.cjs → chunk-WX5WDSKV.cjs} +583 -582
- package/dist/{chunk-R2ABQG2T.cjs → chunk-XLEWM5X5.cjs} +53 -53
- package/dist/{chunk-SZHDXXMK.cjs → chunk-YSDB6HGQ.cjs} +3 -3
- package/dist/{chunk-JLKGLPDC.cjs → chunk-ZW25QUJK.cjs} +16 -16
- package/dist/{chunk-FLW2VL5W.cjs → chunk-ZZO3FGPM.cjs} +24 -24
- package/dist/{cloud-tenants-QTASS5KP.cjs → cloud-tenants-XGGQG7SO.cjs} +24 -24
- package/dist/components/case-studies/index.cjs +40 -40
- package/dist/components/chat/entity-cards/dispatch.d.ts.map +1 -1
- package/dist/components/chat/entity-cards/dispatch.js +4 -1
- package/dist/components/chat/index.cjs +18 -18
- package/dist/components/contact/index.cjs +25 -25
- package/dist/components/docs/index.cjs +28 -28
- package/dist/components/embeds/index.cjs +25 -25
- package/dist/components/faq/index.cjs +26 -26
- package/dist/components/features/index.cjs +24 -24
- package/dist/components/help-center-pages/index.cjs +129 -129
- package/dist/components/index.cjs +89 -89
- package/dist/components/meeting-scheduler/index.cjs +93 -93
- package/dist/components/navigation/index.cjs +27 -27
- package/dist/components/onboarding-guides/index.cjs +27 -27
- package/dist/components/product-demo/index.cjs +35 -35
- package/dist/components/related-content/index.cjs +14 -14
- package/dist/components/tickets/index.cjs +31 -31
- package/dist/components/ui/index.cjs +24 -24
- package/dist/components/ui/markdown/base-components.d.ts.map +1 -1
- package/dist/components/ui/markdown/base-components.js +6 -7
- package/dist/components/ui/markdown/engine.d.ts +7 -0
- package/dist/components/ui/markdown/engine.d.ts.map +1 -1
- package/dist/components/ui/markdown/engine.js +12 -3
- package/dist/components/ui/markdown/external-media-notice.d.ts +33 -0
- package/dist/components/ui/markdown/external-media-notice.d.ts.map +1 -0
- package/dist/components/ui/markdown/external-media-notice.js +56 -0
- package/dist/components/ui/markdown/mermaid-diagram.d.ts +24 -2
- package/dist/components/ui/markdown/mermaid-diagram.d.ts.map +1 -1
- package/dist/components/ui/markdown/mermaid-diagram.js +66 -6
- package/dist/components/ui/markdown/rich/rich-markdown-renderer.d.ts +4 -4
- package/dist/components/ui/markdown/rich/rich-markdown-renderer.d.ts.map +1 -1
- package/dist/components/ui/markdown/rich/rich-markdown-renderer.js +2 -1
- package/dist/components/ui/markdown/sanitize.d.ts +28 -3
- package/dist/components/ui/markdown/sanitize.d.ts.map +1 -1
- package/dist/components/ui/markdown/sanitize.js +84 -12
- package/dist/components/ui/markdown/simple-markdown-renderer.d.ts +3 -2
- package/dist/components/ui/markdown/simple-markdown-renderer.d.ts.map +1 -1
- package/dist/{devices-KPMQI57Y.cjs → devices-H5Y4DBVC.cjs} +25 -25
- package/dist/{embeddable-chat-LB7NDFVQ.cjs → embeddable-chat-77ZOLCCK.cjs} +88 -88
- package/dist/hooks/index.cjs +10 -10
- package/dist/index.cjs +29 -29
- package/dist/{knowledge-JWGBY3ZJ.cjs → knowledge-MGH65HXM.cjs} +25 -25
- package/dist/{logs-QENTXKWY.cjs → logs-OL7ETVK6.cjs} +32 -32
- package/dist/{policies-2HXFZ2EL.cjs → policies-BCECWQ3F.cjs} +28 -28
- package/dist/{remote-session-LMUFV2RZ.cjs → remote-session-HML4UF7W.cjs} +11 -11
- package/dist/{scripts-TMXULK6L.cjs → scripts-XCD6V2JB.cjs} +31 -31
- package/dist/{software-update-H2LAEWDN.cjs → software-update-U5ESXRG5.cjs} +28 -28
- package/dist/{tickets-board-QF5JNSH2.cjs → tickets-board-EICQ5VLE.cjs} +14 -14
- package/dist/utils/app-origins.d.ts +41 -0
- package/dist/utils/app-origins.d.ts.map +1 -0
- package/dist/utils/app-origins.js +51 -0
- package/dist/utils/embed-auth-adapter-registry.d.ts +7 -0
- package/dist/utils/embed-auth-adapter-registry.d.ts.map +1 -0
- package/dist/utils/embed-auth-adapter-registry.js +34 -0
- package/dist/utils/embed-authed-fetch.d.ts.map +1 -1
- package/dist/utils/embed-authed-fetch.js +6 -19
- package/dist/utils/index.cjs +28 -12
- package/dist/{video-file-player-2FMFCGXE.cjs → video-file-player-4QMVTOBE.cjs} +3 -3
- package/package.json +1 -1
- package/src/components/chat/entity-cards/dispatch.tsx +12 -1
- package/src/components/ui/markdown/base-components.tsx +6 -7
- package/src/components/ui/markdown/engine.tsx +29 -5
- package/src/components/ui/markdown/external-media-notice.tsx +84 -0
- package/src/components/ui/markdown/mermaid-diagram.tsx +107 -5
- package/src/components/ui/markdown/rich/rich-markdown-renderer.tsx +11 -5
- package/src/components/ui/markdown/sanitize.ts +162 -15
- package/src/components/ui/markdown/simple-markdown-renderer.tsx +6 -2
- package/src/utils/app-origins.ts +95 -0
- package/src/utils/embed-auth-adapter-registry.ts +49 -0
- package/src/utils/embed-authed-fetch.ts +7 -35
|
@@ -15,25 +15,25 @@ var _chunkFDZOE5TLcjs = require('./chunk-FDZOE5TL.cjs');
|
|
|
15
15
|
|
|
16
16
|
|
|
17
17
|
|
|
18
|
-
var
|
|
19
|
-
require('./chunk-
|
|
20
|
-
require('./chunk-
|
|
18
|
+
var _chunkWX5WDSKVcjs = require('./chunk-WX5WDSKV.cjs');
|
|
19
|
+
require('./chunk-ZZO3FGPM.cjs');
|
|
20
|
+
require('./chunk-SFUNXMY3.cjs');
|
|
21
21
|
|
|
22
22
|
|
|
23
|
-
var
|
|
23
|
+
var _chunk243TS7YLcjs = require('./chunk-243TS7YL.cjs');
|
|
24
24
|
require('./chunk-HQQE74RO.cjs');
|
|
25
25
|
require('./chunk-DEY6XXGO.cjs');
|
|
26
|
-
require('./chunk-
|
|
27
|
-
require('./chunk-
|
|
26
|
+
require('./chunk-GU3GJ5DH.cjs');
|
|
27
|
+
require('./chunk-APOMNC7H.cjs');
|
|
28
28
|
require('./chunk-24I6RFVU.cjs');
|
|
29
29
|
require('./chunk-7Z536SPR.cjs');
|
|
30
30
|
require('./chunk-MZ4KBSH7.cjs');
|
|
31
31
|
require('./chunk-YR74H7Z3.cjs');
|
|
32
|
-
require('./chunk-
|
|
33
|
-
require('./chunk-
|
|
34
|
-
require('./chunk-
|
|
32
|
+
require('./chunk-J6C7F63P.cjs');
|
|
33
|
+
require('./chunk-CB77J5L7.cjs');
|
|
34
|
+
require('./chunk-ZW25QUJK.cjs');
|
|
35
35
|
require('./chunk-ZD6SZLO2.cjs');
|
|
36
|
-
require('./chunk-
|
|
36
|
+
require('./chunk-NZSWROGM.cjs');
|
|
37
37
|
require('./chunk-JTIGKLKJ.cjs');
|
|
38
38
|
require('./chunk-ZOZR3QI2.cjs');
|
|
39
39
|
require('./chunk-OMV5S5PI.cjs');
|
|
@@ -1823,21 +1823,21 @@ require('./chunk-LMBYZITR.cjs');
|
|
|
1823
1823
|
require('./chunk-TMVC7S2R.cjs');
|
|
1824
1824
|
require('./chunk-IYHH5EIO.cjs');
|
|
1825
1825
|
require('./chunk-XIBCMGBW.cjs');
|
|
1826
|
-
require('./chunk-
|
|
1827
|
-
require('./chunk-
|
|
1826
|
+
require('./chunk-ERLMCSGF.cjs');
|
|
1827
|
+
require('./chunk-CNTBGJA7.cjs');
|
|
1828
1828
|
require('./chunk-XYZBN6D7.cjs');
|
|
1829
1829
|
require('./chunk-JKX2C3I2.cjs');
|
|
1830
1830
|
require('./chunk-7DNL734S.cjs');
|
|
1831
1831
|
require('./chunk-WWUSFOJ7.cjs');
|
|
1832
1832
|
require('./chunk-SKI6NKOE.cjs');
|
|
1833
1833
|
require('./chunk-EWPR7662.cjs');
|
|
1834
|
-
require('./chunk-
|
|
1835
|
-
require('./chunk-
|
|
1836
|
-
require('./chunk-
|
|
1837
|
-
require('./chunk-
|
|
1834
|
+
require('./chunk-ACCZCRXT.cjs');
|
|
1835
|
+
require('./chunk-UP3TLY2V.cjs');
|
|
1836
|
+
require('./chunk-7Y6M4FW4.cjs');
|
|
1837
|
+
require('./chunk-OQDPZOGC.cjs');
|
|
1838
1838
|
require('./chunk-P4B6PVSG.cjs');
|
|
1839
|
-
require('./chunk-
|
|
1840
|
-
require('./chunk-
|
|
1839
|
+
require('./chunk-5QLDHPPU.cjs');
|
|
1840
|
+
require('./chunk-U2MHQBL4.cjs');
|
|
1841
1841
|
require('./chunk-S5C3OZCO.cjs');
|
|
1842
1842
|
require('./chunk-32ASZMTV.cjs');
|
|
1843
1843
|
require('./chunk-OOYBIS7D.cjs');
|
|
@@ -1847,13 +1847,13 @@ require('./chunk-ORO54HDF.cjs');
|
|
|
1847
1847
|
require('./chunk-RUHKTWGB.cjs');
|
|
1848
1848
|
require('./chunk-BLH2SFOO.cjs');
|
|
1849
1849
|
require('./chunk-STLJCAIZ.cjs');
|
|
1850
|
-
require('./chunk-
|
|
1850
|
+
require('./chunk-FX35L4Y6.cjs');
|
|
1851
1851
|
require('./chunk-NTPX5GXI.cjs');
|
|
1852
|
-
require('./chunk-
|
|
1853
|
-
require('./chunk-
|
|
1854
|
-
require('./chunk-
|
|
1852
|
+
require('./chunk-MG3HJIGG.cjs');
|
|
1853
|
+
require('./chunk-LC65AC6M.cjs');
|
|
1854
|
+
require('./chunk-YSDB6HGQ.cjs');
|
|
1855
1855
|
require('./chunk-VXXOUM2K.cjs');
|
|
1856
|
-
require('./chunk-
|
|
1856
|
+
require('./chunk-GI3MMBP3.cjs');
|
|
1857
1857
|
require('./chunk-KUXHXLJQ.cjs');
|
|
1858
1858
|
require('./chunk-UJ7AXHRZ.cjs');
|
|
1859
1859
|
require('./chunk-7RM4NM2C.cjs');
|
|
@@ -1920,14 +1920,14 @@ var noop = () => {
|
|
|
1920
1920
|
var HIDDEN_WHEN_COMPACT = ["organization"];
|
|
1921
1921
|
function StaticPackageField({ value }) {
|
|
1922
1922
|
return /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
1923
|
-
|
|
1923
|
+
_chunk243TS7YLcjs.Autocomplete,
|
|
1924
1924
|
{
|
|
1925
|
-
label:
|
|
1925
|
+
label: _chunkWX5WDSKVcjs.PACKAGE_SEARCH_LABEL,
|
|
1926
1926
|
labelVariant: "large",
|
|
1927
1927
|
options: value ? [{ value: value.id, label: value.name, description: _nullishCoalesce(value.description, () => ( void 0)) }] : [],
|
|
1928
1928
|
value: _nullishCoalesce(_optionalChain([value, 'optionalAccess', _ => _.id]), () => ( null)),
|
|
1929
1929
|
onChange: noop,
|
|
1930
|
-
placeholder:
|
|
1930
|
+
placeholder: _chunkWX5WDSKVcjs.PACKAGE_SEARCH_PLACEHOLDER
|
|
1931
1931
|
}
|
|
1932
1932
|
);
|
|
1933
1933
|
}
|
|
@@ -1941,7 +1941,7 @@ function SoftwareUpdateScreen({ compact = false }) {
|
|
|
1941
1941
|
[fixture.devices, fixture.selectedIds]
|
|
1942
1942
|
);
|
|
1943
1943
|
return /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "div", { className: "h-full bg-ods-bg pt-[var(--spacing-system-l)]", children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "div", { className: "h-full", children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
1944
|
-
|
|
1944
|
+
_chunkWX5WDSKVcjs.SoftwareActionForm,
|
|
1945
1945
|
{
|
|
1946
1946
|
action: fixture.action,
|
|
1947
1947
|
showHeader: false,
|
|
@@ -1953,7 +1953,7 @@ function SoftwareUpdateScreen({ compact = false }) {
|
|
|
1953
1953
|
initialValues: fixture.initialValues,
|
|
1954
1954
|
renderPackageSearch,
|
|
1955
1955
|
renderDevicePicker: () => /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
1956
|
-
|
|
1956
|
+
_chunkWX5WDSKVcjs.DeviceSelector,
|
|
1957
1957
|
{
|
|
1958
1958
|
devices: selected,
|
|
1959
1959
|
loading: false,
|
|
@@ -10,9 +10,9 @@ var _chunkFDZOE5TLcjs = require('./chunk-FDZOE5TL.cjs');
|
|
|
10
10
|
|
|
11
11
|
|
|
12
12
|
|
|
13
|
-
var
|
|
14
|
-
require('./chunk-
|
|
15
|
-
require('./chunk-
|
|
13
|
+
var _chunkZZO3FGPMcjs = require('./chunk-ZZO3FGPM.cjs');
|
|
14
|
+
require('./chunk-APOMNC7H.cjs');
|
|
15
|
+
require('./chunk-ZW25QUJK.cjs');
|
|
16
16
|
require('./chunk-JTIGKLKJ.cjs');
|
|
17
17
|
require('./chunk-ZOZR3QI2.cjs');
|
|
18
18
|
require('./chunk-OMV5S5PI.cjs');
|
|
@@ -1805,8 +1805,8 @@ require('./chunk-XIBCMGBW.cjs');
|
|
|
1805
1805
|
require('./chunk-XYZBN6D7.cjs');
|
|
1806
1806
|
require('./chunk-WWUSFOJ7.cjs');
|
|
1807
1807
|
require('./chunk-SKI6NKOE.cjs');
|
|
1808
|
-
require('./chunk-
|
|
1809
|
-
require('./chunk-
|
|
1808
|
+
require('./chunk-OQDPZOGC.cjs');
|
|
1809
|
+
require('./chunk-U2MHQBL4.cjs');
|
|
1810
1810
|
require('./chunk-S5C3OZCO.cjs');
|
|
1811
1811
|
require('./chunk-32ASZMTV.cjs');
|
|
1812
1812
|
require('./chunk-OOYBIS7D.cjs');
|
|
@@ -1814,11 +1814,11 @@ require('./chunk-4IYNDV3G.cjs');
|
|
|
1814
1814
|
require('./chunk-6VOOPMP5.cjs');
|
|
1815
1815
|
require('./chunk-ORO54HDF.cjs');
|
|
1816
1816
|
require('./chunk-RUHKTWGB.cjs');
|
|
1817
|
-
require('./chunk-
|
|
1818
|
-
require('./chunk-
|
|
1819
|
-
require('./chunk-
|
|
1817
|
+
require('./chunk-FX35L4Y6.cjs');
|
|
1818
|
+
require('./chunk-LC65AC6M.cjs');
|
|
1819
|
+
require('./chunk-YSDB6HGQ.cjs');
|
|
1820
1820
|
require('./chunk-VXXOUM2K.cjs');
|
|
1821
|
-
require('./chunk-
|
|
1821
|
+
require('./chunk-GI3MMBP3.cjs');
|
|
1822
1822
|
require('./chunk-KUXHXLJQ.cjs');
|
|
1823
1823
|
require('./chunk-NL3G642U.cjs');
|
|
1824
1824
|
require('./chunk-Z74QE57T.cjs');
|
|
@@ -1840,7 +1840,7 @@ function buildTicketsBoardFixture(cast) {
|
|
|
1840
1840
|
const dana = assignee(cast.person("dana"));
|
|
1841
1841
|
const alex = assignee(cast.person("alex"));
|
|
1842
1842
|
return [
|
|
1843
|
-
|
|
1843
|
+
_chunkZZO3FGPMcjs.columnFromTicketStatus.call(void 0, "ACTIVE", [
|
|
1844
1844
|
ticket("tk-1051", "Printer offline at the front desk", "ACTIVE", {
|
|
1845
1845
|
ticketNumber: "1051",
|
|
1846
1846
|
agent: "fae",
|
|
@@ -1858,7 +1858,7 @@ function buildTicketsBoardFixture(cast) {
|
|
|
1858
1858
|
tags: ["onboarding"]
|
|
1859
1859
|
})
|
|
1860
1860
|
]),
|
|
1861
|
-
|
|
1861
|
+
_chunkZZO3FGPMcjs.columnFromTicketStatus.call(void 0, "TECH_REQUIRED", [
|
|
1862
1862
|
ticket("tk-1049", "Acrobat Pro for Maya", "TECH_REQUIRED", {
|
|
1863
1863
|
ticketNumber: "1049",
|
|
1864
1864
|
agent: "fae",
|
|
@@ -1882,7 +1882,7 @@ function buildTicketsBoardFixture(cast) {
|
|
|
1882
1882
|
escalatedByUser: true
|
|
1883
1883
|
})
|
|
1884
1884
|
]),
|
|
1885
|
-
|
|
1885
|
+
_chunkZZO3FGPMcjs.columnFromTicketStatus.call(void 0, "ON_HOLD", [
|
|
1886
1886
|
ticket("tk-1046", "Replace the conference room display", "ON_HOLD", {
|
|
1887
1887
|
ticketNumber: "1046",
|
|
1888
1888
|
organizationName: _chunkFDZOE5TLcjs.DEMO_ORGANIZATIONS.acme.name,
|
|
@@ -1891,7 +1891,7 @@ function buildTicketsBoardFixture(cast) {
|
|
|
1891
1891
|
activity: { kind: "waiting-external" }
|
|
1892
1892
|
})
|
|
1893
1893
|
]),
|
|
1894
|
-
|
|
1894
|
+
_chunkZZO3FGPMcjs.columnFromTicketStatus.call(void 0,
|
|
1895
1895
|
"RESOLVED",
|
|
1896
1896
|
[
|
|
1897
1897
|
ticket("tk-1048", "Slow laptop", "RESOLVED", {
|
|
@@ -1927,7 +1927,7 @@ function TicketsBoardScreen({ compact = false }) {
|
|
|
1927
1927
|
const cast = _chunkLHV2R6QUcjs.useProductDemoCast.call(void 0, );
|
|
1928
1928
|
const board = _react.useMemo.call(void 0, () => buildTicketsBoardFixture(cast), [cast]);
|
|
1929
1929
|
const columns = compact ? board.filter((column) => column.id !== "ON_HOLD") : board;
|
|
1930
|
-
return /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "div", { className: "h-full bg-ods-bg p-[var(--spacing-system-m)]", children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
1930
|
+
return /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "div", { className: "h-full bg-ods-bg p-[var(--spacing-system-m)]", children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkZZO3FGPMcjs.Board, { columns, onChange: noop, initialCollapsed: compact ? void 0 : FOLDED }) });
|
|
1931
1931
|
}
|
|
1932
1932
|
|
|
1933
1933
|
|
|
@@ -0,0 +1,41 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Where the app loads from: the page, and the origins the host sanctions in
|
|
3
|
+
* `EmbedAuthAdapter.allowedOrigins` (the gateway of a native shell, whose page
|
|
4
|
+
* origin is `capacitor://` / `tauri://`). Untrusted markdown may load media
|
|
5
|
+
* only from here; `embedAuthedFetch` sends the bearer only here.
|
|
6
|
+
*/
|
|
7
|
+
export interface AppOrigins {
|
|
8
|
+
/** The page's root URL (`https://host/`, `capacitor://localhost/`); `null` on the server, where there is no page. */
|
|
9
|
+
readonly pageUrl: string | null;
|
|
10
|
+
readonly allowedOrigins: readonly string[];
|
|
11
|
+
}
|
|
12
|
+
/** The server's answer, and the first one a hydrating client gives: only relative URLs belong to the app. */
|
|
13
|
+
export declare const SERVER_APP_ORIGINS: AppOrigins;
|
|
14
|
+
/**
|
|
15
|
+
* The app's origins now. Same object until they change, so it can be a
|
|
16
|
+
* `useSyncExternalStore` snapshot (`subscribeAppOrigins` reports the change).
|
|
17
|
+
*/
|
|
18
|
+
export declare function readAppOrigins(): AppOrigins;
|
|
19
|
+
/** Called when a host registers, replaces or clears its auth adapter, which can change `allowedOrigins`. */
|
|
20
|
+
export declare const subscribeAppOrigins: (listener: () => void) => () => void;
|
|
21
|
+
/**
|
|
22
|
+
* `url` resolved against the page when it belongs to the app, otherwise `null`.
|
|
23
|
+
*
|
|
24
|
+
* The page match compares scheme and host instead of `URL.origin`, which is
|
|
25
|
+
* `"null"` for a `capacitor://` page.
|
|
26
|
+
*/
|
|
27
|
+
export declare function resolveAppOriginUrl(url: string, origins?: AppOrigins): URL | null;
|
|
28
|
+
/**
|
|
29
|
+
* Whether `url` loads from the app itself rather than from a third party.
|
|
30
|
+
* Untrusted markdown may only load media from here: a third-party `<img src>`
|
|
31
|
+
* is a request the content's author receives, with whatever the URL carries.
|
|
32
|
+
* Pass `origins` to decide against a snapshot (a render that must give the
|
|
33
|
+
* server's answer while it hydrates); it defaults to the app's origins now.
|
|
34
|
+
*/
|
|
35
|
+
export declare function isAppOriginUrl(url: string, origins?: AppOrigins): boolean;
|
|
36
|
+
/**
|
|
37
|
+
* `url` as an absolute http(s) URL against `origins`' page, for a notice to
|
|
38
|
+
* name its host; `null` when it is not http(s).
|
|
39
|
+
*/
|
|
40
|
+
export declare function absoluteHttpUrl(url: string, origins?: AppOrigins): string | null;
|
|
41
|
+
//# sourceMappingURL=app-origins.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"app-origins.d.ts","sourceRoot":"","sources":["../../src/utils/app-origins.ts"],"names":[],"mappings":"AAEA;;;;;GAKG;AACH,MAAM,WAAW,UAAU;IACzB,qHAAqH;IACrH,QAAQ,CAAC,OAAO,EAAE,MAAM,GAAG,IAAI,CAAC;IAChC,QAAQ,CAAC,cAAc,EAAE,SAAS,MAAM,EAAE,CAAC;CAC5C;AAED,6GAA6G;AAC7G,eAAO,MAAM,kBAAkB,EAAE,UAAgF,CAAC;AAOlH;;;GAGG;AACH,wBAAgB,cAAc,IAAI,UAAU,CAqB3C;AAED,4GAA4G;AAC5G,eAAO,MAAM,mBAAmB,EAAE,CAAC,QAAQ,EAAE,MAAM,IAAI,KAAK,MAAM,IAAiC,CAAC;AAEpG;;;;;GAKG;AACH,wBAAgB,mBAAmB,CAAC,GAAG,EAAE,MAAM,EAAE,OAAO,GAAE,UAA6B,GAAG,GAAG,GAAG,IAAI,CAYnG;AAED;;;;;;GAMG;AACH,wBAAgB,cAAc,CAAC,GAAG,EAAE,MAAM,EAAE,OAAO,CAAC,EAAE,UAAU,GAAG,OAAO,CAEzE;AAED;;;GAGG;AACH,wBAAgB,eAAe,CAAC,GAAG,EAAE,MAAM,EAAE,OAAO,GAAE,UAA6B,GAAG,MAAM,GAAG,IAAI,CAOlG"}
|
|
@@ -0,0 +1,51 @@
|
|
|
1
|
+
import { readRegisteredAdapter, subscribeRegisteredAdapter } from "./embed-auth-adapter-registry.js";
|
|
2
|
+
const SERVER_APP_ORIGINS = Object.freeze({ pageUrl: null, allowedOrigins: Object.freeze([]) });
|
|
3
|
+
const SERVER_PAGE_URL = "http://app.invalid/";
|
|
4
|
+
let snapshot = SERVER_APP_ORIGINS;
|
|
5
|
+
function readAppOrigins() {
|
|
6
|
+
if (typeof window === "undefined") return SERVER_APP_ORIGINS;
|
|
7
|
+
let pageUrl;
|
|
8
|
+
try {
|
|
9
|
+
pageUrl = new URL("/", window.location.href).href;
|
|
10
|
+
} catch {
|
|
11
|
+
return SERVER_APP_ORIGINS;
|
|
12
|
+
}
|
|
13
|
+
const allowedOrigins = readRegisteredAdapter()?.allowedOrigins ?? [];
|
|
14
|
+
if (snapshot.pageUrl !== pageUrl || snapshot.allowedOrigins.length !== allowedOrigins.length || snapshot.allowedOrigins.some((origin, i) => origin !== allowedOrigins[i])) {
|
|
15
|
+
snapshot = { pageUrl, allowedOrigins: [...allowedOrigins] };
|
|
16
|
+
}
|
|
17
|
+
return snapshot;
|
|
18
|
+
}
|
|
19
|
+
const subscribeAppOrigins = subscribeRegisteredAdapter;
|
|
20
|
+
function resolveAppOriginUrl(url, origins = readAppOrigins()) {
|
|
21
|
+
let page;
|
|
22
|
+
let target;
|
|
23
|
+
try {
|
|
24
|
+
page = new URL(origins.pageUrl ?? SERVER_PAGE_URL);
|
|
25
|
+
target = new URL(url, page);
|
|
26
|
+
} catch {
|
|
27
|
+
return null;
|
|
28
|
+
}
|
|
29
|
+
if (target.protocol === page.protocol && target.host === page.host) return target;
|
|
30
|
+
if (target.protocol !== "http:" && target.protocol !== "https:") return null;
|
|
31
|
+
return origins.allowedOrigins.includes(target.origin) ? target : null;
|
|
32
|
+
}
|
|
33
|
+
function isAppOriginUrl(url, origins) {
|
|
34
|
+
return resolveAppOriginUrl(url, origins) !== null;
|
|
35
|
+
}
|
|
36
|
+
function absoluteHttpUrl(url, origins = readAppOrigins()) {
|
|
37
|
+
try {
|
|
38
|
+
const resolved = new URL(url.trim(), origins.pageUrl ?? SERVER_PAGE_URL);
|
|
39
|
+
return resolved.protocol === "http:" || resolved.protocol === "https:" ? resolved.href : null;
|
|
40
|
+
} catch {
|
|
41
|
+
return null;
|
|
42
|
+
}
|
|
43
|
+
}
|
|
44
|
+
export {
|
|
45
|
+
SERVER_APP_ORIGINS,
|
|
46
|
+
absoluteHttpUrl,
|
|
47
|
+
isAppOriginUrl,
|
|
48
|
+
readAppOrigins,
|
|
49
|
+
resolveAppOriginUrl,
|
|
50
|
+
subscribeAppOrigins
|
|
51
|
+
};
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
/** The registered adapter, typed by the caller (the slot itself does not know the adapter's shape). */
|
|
2
|
+
export declare function readRegisteredAdapter<T>(): T | null;
|
|
3
|
+
/** Store the adapter (or `null`) and tell every listener, in every copy of this module. */
|
|
4
|
+
export declare function writeRegisteredAdapter(adapter: unknown): void;
|
|
5
|
+
/** Called after every registration, replacement or clear. */
|
|
6
|
+
export declare function subscribeRegisteredAdapter(listener: () => void): () => void;
|
|
7
|
+
//# sourceMappingURL=embed-auth-adapter-registry.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"embed-auth-adapter-registry.d.ts","sourceRoot":"","sources":["../../src/utils/embed-auth-adapter-registry.ts"],"names":[],"mappings":"AA2BA,uGAAuG;AACvG,wBAAgB,qBAAqB,CAAC,CAAC,KAAK,CAAC,GAAG,IAAI,CAGnD;AAED,2FAA2F;AAC3F,wBAAgB,sBAAsB,CAAC,OAAO,EAAE,OAAO,GAAG,IAAI,CAI7D;AAED,6DAA6D;AAC7D,wBAAgB,0BAA0B,CAAC,QAAQ,EAAE,MAAM,IAAI,GAAG,MAAM,IAAI,CAO3E"}
|
|
@@ -0,0 +1,34 @@
|
|
|
1
|
+
const ADAPTER_GLOBAL_KEY = "__embedAuthedFetchAdapter__";
|
|
2
|
+
const LISTENERS_GLOBAL_KEY = "__embedAuthedFetchAdapterListeners__";
|
|
3
|
+
function listeners() {
|
|
4
|
+
const slots = globalThis;
|
|
5
|
+
let set = slots[LISTENERS_GLOBAL_KEY];
|
|
6
|
+
if (!set) {
|
|
7
|
+
set = /* @__PURE__ */ new Set();
|
|
8
|
+
slots[LISTENERS_GLOBAL_KEY] = set;
|
|
9
|
+
}
|
|
10
|
+
return set;
|
|
11
|
+
}
|
|
12
|
+
function readRegisteredAdapter() {
|
|
13
|
+
if (typeof globalThis === "undefined") return null;
|
|
14
|
+
return globalThis[ADAPTER_GLOBAL_KEY] ?? null;
|
|
15
|
+
}
|
|
16
|
+
function writeRegisteredAdapter(adapter) {
|
|
17
|
+
if (typeof globalThis === "undefined") return;
|
|
18
|
+
globalThis[ADAPTER_GLOBAL_KEY] = adapter;
|
|
19
|
+
for (const listener of [...listeners()]) listener();
|
|
20
|
+
}
|
|
21
|
+
function subscribeRegisteredAdapter(listener) {
|
|
22
|
+
if (typeof globalThis === "undefined") return () => {
|
|
23
|
+
};
|
|
24
|
+
const set = listeners();
|
|
25
|
+
set.add(listener);
|
|
26
|
+
return () => {
|
|
27
|
+
set.delete(listener);
|
|
28
|
+
};
|
|
29
|
+
}
|
|
30
|
+
export {
|
|
31
|
+
readRegisteredAdapter,
|
|
32
|
+
subscribeRegisteredAdapter,
|
|
33
|
+
writeRegisteredAdapter
|
|
34
|
+
};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"embed-authed-fetch.d.ts","sourceRoot":"","sources":["../../src/utils/embed-authed-fetch.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"embed-authed-fetch.d.ts","sourceRoot":"","sources":["../../src/utils/embed-authed-fetch.ts"],"names":[],"mappings":"AA8BA;;;;;;;;;;;;;;;;;;;;;;;;;GAyBG;AACH,MAAM,WAAW,gBAAgB;IAC/B;;;;;;4EAMwE;IACxE,UAAU,CAAC,EAAE,MAAM,MAAM,CAAC,MAAM,EAAE,MAAM,GAAG,SAAS,CAAC,CAAC;IACtD;;6EAEyE;IACzE,WAAW,CAAC,EAAE,kBAAkB,CAAC;IACjC;;;;;;;;;;;;;;;;;;;OAmBG;IACH,OAAO,CAAC,EAAE,MAAM,OAAO,CAAC,OAAO,CAAC,CAAC;IACjC;;;;;;;;;;;;OAYG;IACH,aAAa,CAAC,EAAE,MAAM,IAAI,GAAG,OAAO,CAAC,IAAI,CAAC,CAAC;IAC3C;;;;;;;;;;;;OAYG;IACH,UAAU,CAAC,EAAE,CAAC,QAAQ,EAAE,QAAQ,KAAK,IAAI,GAAG,OAAO,CAAC,IAAI,CAAC,CAAC;IAC1D;;;;;;;;;;;OAWG;IACH,cAAc,CAAC,EAAE,MAAM,EAAE,CAAC;IAC1B;;;;;;;;OAQG;IACH,SAAS,CAAC,EAAE,CAAC,QAAQ,EAAE,MAAM,IAAI,KAAK,MAAM,IAAI,CAAC;CAClD;AAOD;;;;;;;;;GASG;AACH,wBAAgB,mBAAmB,CAAC,OAAO,EAAE,gBAAgB,GAAG,IAAI,GAAG,IAAI,CAS1E;AAED;;;;;GAKG;AACH,wBAAgB,mBAAmB,IAAI,OAAO,CAE7C;AAED;;;;;;GAMG;AACH,wBAAgB,8BAA8B,CAAC,QAAQ,EAAE,MAAM,IAAI,GAAG,MAAM,IAAI,CAE/E;AAED;;;;;;;;;;;;;;;;;;;;;;;;;;;GA2BG;AACH,wBAAgB,qBAAqB,CAAC,GAAG,EAAE,MAAM,GAAG,OAAO,CAM1D;AAED;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GAkCG;AACH,wBAAgB,gBAAgB,CAAC,GAAG,EAAE,MAAM,EAAE,IAAI,GAAE,WAAgB,GAAG,OAAO,CAAC,QAAQ,CAAC,CAkCvF"}
|
|
@@ -1,13 +1,9 @@
|
|
|
1
1
|
"use client";
|
|
2
|
+
import { resolveAppOriginUrl } from "./app-origins.js";
|
|
3
|
+
import { readRegisteredAdapter, writeRegisteredAdapter } from "./embed-auth-adapter-registry.js";
|
|
2
4
|
import { applyProxyAuth } from "./embed-proxy-auth-storage.js";
|
|
3
|
-
const ADAPTER_GLOBAL_KEY = "__embedAuthedFetchAdapter__";
|
|
4
5
|
function getRegisteredAuthAdapter() {
|
|
5
|
-
|
|
6
|
-
return globalThis[ADAPTER_GLOBAL_KEY] ?? null;
|
|
7
|
-
}
|
|
8
|
-
function storeRegisteredAuthAdapter(adapter) {
|
|
9
|
-
if (typeof globalThis === "undefined") return;
|
|
10
|
-
globalThis[ADAPTER_GLOBAL_KEY] = adapter;
|
|
6
|
+
return readRegisteredAdapter();
|
|
11
7
|
}
|
|
12
8
|
function setEmbedAuthAdapter(adapter) {
|
|
13
9
|
if (adapter && getRegisteredAuthAdapter() && process.env.NODE_ENV !== "production") {
|
|
@@ -15,7 +11,7 @@ function setEmbedAuthAdapter(adapter) {
|
|
|
15
11
|
"[setEmbedAuthAdapter] overwriting a previously-registered auth adapter. Two chat-runtime providers should not coexist \u2014 verify mount order and pass `null` from the unmounting provider."
|
|
16
12
|
);
|
|
17
13
|
}
|
|
18
|
-
|
|
14
|
+
writeRegisteredAdapter(adapter);
|
|
19
15
|
}
|
|
20
16
|
function hasEmbedAuthAdapter() {
|
|
21
17
|
return getRegisteredAuthAdapter() !== null;
|
|
@@ -28,17 +24,8 @@ function needsBearerAssetFetch(url) {
|
|
|
28
24
|
if (typeof window === "undefined") return false;
|
|
29
25
|
const adapter = getRegisteredAuthAdapter();
|
|
30
26
|
if (!adapter || adapter.getHeaders?.().Authorization === void 0) return false;
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
try {
|
|
34
|
-
target = new URL(url, window.location.href);
|
|
35
|
-
pageOrigin = new URL(window.location.href).origin;
|
|
36
|
-
} catch {
|
|
37
|
-
return false;
|
|
38
|
-
}
|
|
39
|
-
if (target.protocol !== "http:" && target.protocol !== "https:") return false;
|
|
40
|
-
if (target.origin === pageOrigin) return true;
|
|
41
|
-
return adapter.allowedOrigins?.includes(target.origin) ?? false;
|
|
27
|
+
const target = resolveAppOriginUrl(url);
|
|
28
|
+
return target !== null && (target.protocol === "http:" || target.protocol === "https:");
|
|
42
29
|
}
|
|
43
30
|
function embedAuthedFetch(url, init = {}) {
|
|
44
31
|
assertSameOrigin(url);
|
package/dist/utils/index.cjs
CHANGED
|
@@ -81388,11 +81388,11 @@ function loadIcon(key, loader) {
|
|
|
81388
81388
|
}
|
|
81389
81389
|
function subscribeToIcon(key) {
|
|
81390
81390
|
return (listener) => {
|
|
81391
|
-
const
|
|
81392
|
-
|
|
81393
|
-
iconListeners.set(key,
|
|
81391
|
+
const listeners2 = iconListeners.get(key) ?? /* @__PURE__ */ new Set();
|
|
81392
|
+
listeners2.add(listener);
|
|
81393
|
+
iconListeners.set(key, listeners2);
|
|
81394
81394
|
return () => {
|
|
81395
|
-
|
|
81395
|
+
listeners2.delete(listener);
|
|
81396
81396
|
};
|
|
81397
81397
|
};
|
|
81398
81398
|
}
|
|
@@ -83324,6 +83324,28 @@ function formatCitationIndices(indices) {
|
|
|
83324
83324
|
return runs.join(", ");
|
|
83325
83325
|
}
|
|
83326
83326
|
|
|
83327
|
+
// src/utils/embed-auth-adapter-registry.ts
|
|
83328
|
+
var ADAPTER_GLOBAL_KEY = "__embedAuthedFetchAdapter__";
|
|
83329
|
+
var LISTENERS_GLOBAL_KEY = "__embedAuthedFetchAdapterListeners__";
|
|
83330
|
+
function listeners() {
|
|
83331
|
+
const slots = globalThis;
|
|
83332
|
+
let set = slots[LISTENERS_GLOBAL_KEY];
|
|
83333
|
+
if (!set) {
|
|
83334
|
+
set = /* @__PURE__ */ new Set();
|
|
83335
|
+
slots[LISTENERS_GLOBAL_KEY] = set;
|
|
83336
|
+
}
|
|
83337
|
+
return set;
|
|
83338
|
+
}
|
|
83339
|
+
function readRegisteredAdapter() {
|
|
83340
|
+
if (typeof globalThis === "undefined") return null;
|
|
83341
|
+
return globalThis[ADAPTER_GLOBAL_KEY] ?? null;
|
|
83342
|
+
}
|
|
83343
|
+
function writeRegisteredAdapter(adapter2) {
|
|
83344
|
+
if (typeof globalThis === "undefined") return;
|
|
83345
|
+
globalThis[ADAPTER_GLOBAL_KEY] = adapter2;
|
|
83346
|
+
for (const listener of [...listeners()]) listener();
|
|
83347
|
+
}
|
|
83348
|
+
|
|
83327
83349
|
// src/utils/app-config.ts
|
|
83328
83350
|
function getAppType() {
|
|
83329
83351
|
try {
|
|
@@ -83417,14 +83439,8 @@ function applyProxyAuth(url, baseHeaders = { "Content-Type": "application/json"
|
|
|
83417
83439
|
}
|
|
83418
83440
|
|
|
83419
83441
|
// src/utils/embed-authed-fetch.ts
|
|
83420
|
-
var ADAPTER_GLOBAL_KEY = "__embedAuthedFetchAdapter__";
|
|
83421
83442
|
function getRegisteredAuthAdapter() {
|
|
83422
|
-
|
|
83423
|
-
return globalThis[ADAPTER_GLOBAL_KEY] ?? null;
|
|
83424
|
-
}
|
|
83425
|
-
function storeRegisteredAuthAdapter(adapter2) {
|
|
83426
|
-
if (typeof globalThis === "undefined") return;
|
|
83427
|
-
globalThis[ADAPTER_GLOBAL_KEY] = adapter2;
|
|
83443
|
+
return readRegisteredAdapter();
|
|
83428
83444
|
}
|
|
83429
83445
|
function setEmbedAuthAdapter(adapter2) {
|
|
83430
83446
|
if (adapter2 && getRegisteredAuthAdapter() && process.env.NODE_ENV !== "production") {
|
|
@@ -83432,7 +83448,7 @@ function setEmbedAuthAdapter(adapter2) {
|
|
|
83432
83448
|
"[setEmbedAuthAdapter] overwriting a previously-registered auth adapter. Two chat-runtime providers should not coexist \u2014 verify mount order and pass `null` from the unmounting provider."
|
|
83433
83449
|
);
|
|
83434
83450
|
}
|
|
83435
|
-
|
|
83451
|
+
writeRegisteredAdapter(adapter2);
|
|
83436
83452
|
}
|
|
83437
83453
|
function subscribeEmbedCredentialChange(listener) {
|
|
83438
83454
|
return getRegisteredAuthAdapter()?.subscribe?.(listener) ?? (() => {
|
|
@@ -19,8 +19,8 @@ require('./chunk-4IYNDV3G.cjs');
|
|
|
19
19
|
require('./chunk-NTPX5GXI.cjs');
|
|
20
20
|
|
|
21
21
|
|
|
22
|
-
var
|
|
23
|
-
require('./chunk-
|
|
22
|
+
var _chunkYSDB6HGQcjs = require('./chunk-YSDB6HGQ.cjs');
|
|
23
|
+
require('./chunk-GI3MMBP3.cjs');
|
|
24
24
|
require('./chunk-UJ7AXHRZ.cjs');
|
|
25
25
|
|
|
26
26
|
|
|
@@ -416,7 +416,7 @@ function FilePlayer({
|
|
|
416
416
|
const hover = useHoverPlayback(mediaRef, sound, { playOnHover, playWhenHovered, mutedIntent });
|
|
417
417
|
const health = usePlaybackHealth(mediaRef, url, !chromeless);
|
|
418
418
|
useIosNativeVideoFullscreen(mediaRef);
|
|
419
|
-
const captions =
|
|
419
|
+
const captions = _chunkYSDB6HGQcjs.useAuthedAssetSrc.call(void 0, captionsUrl, "text/vtt, */*");
|
|
420
420
|
const player = /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
421
421
|
_muxplayerreact2.default,
|
|
422
422
|
{
|
package/package.json
CHANGED
|
@@ -47,6 +47,7 @@ import {
|
|
|
47
47
|
type TrustCenterPublic,
|
|
48
48
|
type TrustFrameworkMonitoringEntry,
|
|
49
49
|
} from '../../../types/trust-center';
|
|
50
|
+
import { isAppOriginUrl } from '../../../utils/app-origins';
|
|
50
51
|
import { formatDateShort } from '../../../utils/date-formatters';
|
|
51
52
|
import {
|
|
52
53
|
DESIGN_DOC_READINESS_DISPLAY,
|
|
@@ -87,6 +88,7 @@ import { TruckFastIcon } from '../../icons-v2-generated/vehicles-and-delivery/tr
|
|
|
87
88
|
import type { LoadedProductReleaseCardProps } from '../../shared/product-release/product-release-card';
|
|
88
89
|
import { ProductReleaseCard } from '../../shared/product-release/product-release-card';
|
|
89
90
|
import type { ActionsMenuGroup } from '../../ui/actions-menu';
|
|
91
|
+
import { ExternalMediaNotice } from '../../ui/markdown/external-media-notice';
|
|
90
92
|
import { VendorIcon } from '../../vendor-icon';
|
|
91
93
|
import { useChatPanel } from '../chat-panel-context';
|
|
92
94
|
import type { ChatRef } from '../chat-ref.types';
|
|
@@ -2249,9 +2251,18 @@ export function renderChatInlineEntityCard(
|
|
|
2249
2251
|
(decoded.youtubeUrl ? `https://www.youtube.com/watch?v=${decoded.youtubeUrl}` : null),
|
|
2250
2252
|
metadata: { ...(chatRef.metadata ?? {}), ...decoded },
|
|
2251
2253
|
};
|
|
2254
|
+
// An `mp4-` id carries any https URL the reply put in it, and the
|
|
2255
|
+
// player fetches it on mount: from outside the app it is not played,
|
|
2256
|
+
// like a markdown image (`ExternalMediaNotice`). `mux-` and YouTube ids
|
|
2257
|
+
// only ever reach their own fixed hosts.
|
|
2258
|
+
const externalUrl = chatRef.id.startsWith('mp4-') && decoded.videoUrl;
|
|
2252
2259
|
return (
|
|
2253
2260
|
<BlockCard inline={<ChatInlineVideoPill chatRef={displayRef} />}>
|
|
2254
|
-
|
|
2261
|
+
{externalUrl && !isAppOriginUrl(externalUrl) ? (
|
|
2262
|
+
<ExternalMediaNotice url={externalUrl} kind="video" label={displayRef.title} />
|
|
2263
|
+
) : (
|
|
2264
|
+
<ChatVideoEntityCard chatRef={displayRef} />
|
|
2265
|
+
)}
|
|
2255
2266
|
</BlockCard>
|
|
2256
2267
|
);
|
|
2257
2268
|
}
|
|
@@ -18,6 +18,7 @@ import { slugifyHeadingText } from '../../../utils/markdown-heading-id';
|
|
|
18
18
|
import { renderedLinkRel } from '../../../utils/markdown-link';
|
|
19
19
|
import { getHashTargetElement, navigateSamePageHash, HUB_HEADER_OFFSET_PX } from '../../../utils/same-page-hash-nav';
|
|
20
20
|
import { useLoadingScope } from '../loading-scope';
|
|
21
|
+
import { ExternalMediaNotice } from './external-media-notice';
|
|
21
22
|
import { extractText, resolveFallbackHeadingId, useAssignedHeadingIds, useHeadingId } from './heading-ids';
|
|
22
23
|
import { MermaidDiagram } from './mermaid-diagram';
|
|
23
24
|
import type { TextSizeElement } from './text-size';
|
|
@@ -366,13 +367,11 @@ export function buildBaseComponents({
|
|
|
366
367
|
// authed loading for native shells and the 400x400 cap with click-to-
|
|
367
368
|
// expand for full resolution.
|
|
368
369
|
//
|
|
369
|
-
//
|
|
370
|
-
//
|
|
371
|
-
//
|
|
372
|
-
|
|
373
|
-
|
|
374
|
-
// rather than shipped unwired.
|
|
375
|
-
img: ({ src, alt }: MdRenderProps<'img'>) => {
|
|
370
|
+
// A third-party `src` never reaches here unless the composition set
|
|
371
|
+
// `allowRemoteMedia`: `rehypeStripUnsafe` moves it to `data-blocked-src`,
|
|
372
|
+
// and a notice stands where the image would have been. It is not loaded.
|
|
373
|
+
img: ({ src, alt, 'data-blocked-src': blockedSrc }: MdRenderProps<'img'> & { 'data-blocked-src'?: string }) => {
|
|
374
|
+
if (hasRenderableSrc(blockedSrc)) return <ExternalMediaNotice url={blockedSrc} kind="image" label={alt} />;
|
|
376
375
|
if (!hasRenderableSrc(src)) return null;
|
|
377
376
|
return <MarkdownContentImage src={src} alt={alt} />;
|
|
378
377
|
},
|