@fluid-app/portal-sdk 0.1.273 → 0.1.274

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.
@@ -41,7 +41,7 @@ require("./TableWidget-BXtQHi6t.cjs");
41
41
  require("./ToDoWidget-BsiHDJPl.cjs");
42
42
  require("./VideoWidget-zdT_mVo9.cjs");
43
43
  require("./ScreenHeaderContext-JDIUM84f.cjs");
44
- const require_MessagingScreen = require("./MessagingScreen-DQ7h_qEA.cjs");
44
+ const require_MessagingScreen = require("./MessagingScreen-DbPqXpOt.cjs");
45
45
  require("./translation-api-context-factory-Bzw9AErt.cjs");
46
46
  require("./dist-D_3_ZuC5.cjs");
47
47
  require("./es-B5heQ57j.cjs");
@@ -54578,66 +54578,6 @@ z.object({
54578
54578
  url: z.string().min(1, "Link is required").url("Please enter a valid URL")
54579
54579
  });
54580
54580
  //#endregion
54581
- //#region src/messaging/MessagingHeaderBridge.tsx
54582
- /**
54583
- * Bridges messaging header content from inside <MessagingApp> into the
54584
- * portal shell's <ScreenHeader>. Render this as a child of <MessagingApp>
54585
- * with `hideTopBar` set, and the messaging UI's own <MessagesTopBar /> is
54586
- * suppressed in favour of populating the existing portal header.
54587
- *
54588
- * Right-hand actions are delegated to <MessagesHeaderActions /> from
54589
- * messaging-ui so this stays in sync with <MessagesTopBar />. The breadcrumbs
54590
- * are owned here because the portal shell shows them differently from the
54591
- * messaging-ui's inline page-title fallback.
54592
- */
54593
- const ROUTE_TITLES = {
54594
- pins: "Pinned Messages",
54595
- new: "New Message",
54596
- scheduled: "Scheduled Messages"
54597
- };
54598
- function fallbackRenderImage(props) {
54599
- return /* @__PURE__ */ jsx("img", {
54600
- src: props.src,
54601
- alt: props.alt,
54602
- width: props.width,
54603
- height: props.height,
54604
- className: props.className
54605
- });
54606
- }
54607
- function MessagingHeaderBridge() {
54608
- const { auth, renderImage: contextRenderImage } = useMessagingApp();
54609
- const navigation = useMessagingNavigation();
54610
- const { currentRoute } = navigation;
54611
- const { data: conversation } = useConversation("conversationId" in currentRoute ? currentRoute.conversationId : 0);
54612
- const renderImage = contextRenderImage ?? fallbackRenderImage;
54613
- const currentUser = auth.currentUser;
54614
- const conversationName = conversation?.name;
54615
- const routeTitle = ROUTE_TITLES[currentRoute.view];
54616
- useScreenHeaderBreadcrumbs(useMemo(() => {
54617
- if (routeTitle) return /* @__PURE__ */ jsx("h1", {
54618
- className: "text-foreground text-lg font-semibold",
54619
- children: routeTitle
54620
- });
54621
- if (conversationName) return /* @__PURE__ */ jsx("h1", {
54622
- className: "text-foreground truncate text-lg font-semibold",
54623
- children: conversationName
54624
- });
54625
- return null;
54626
- }, [routeTitle, conversationName]));
54627
- useScreenHeaderActions(useMemo(() => /* @__PURE__ */ jsx(MessagesHeaderActions, {
54628
- conversation,
54629
- currentUser,
54630
- navigation,
54631
- renderImage
54632
- }), [
54633
- conversation,
54634
- currentUser,
54635
- navigation,
54636
- renderImage
54637
- ]));
54638
- return null;
54639
- }
54640
- //#endregion
54641
54581
  //#region src/providers/MessagingTranslationBridge.tsx
54642
54582
  const messagingTranslationApi = createStaticDictAdapter("en", {
54643
54583
  loading_messaging: "Loading messaging...",
@@ -54877,6 +54817,66 @@ function MessagingTranslationBridge({ children }) {
54877
54817
  });
54878
54818
  }
54879
54819
  //#endregion
54820
+ //#region src/messaging/MessagingHeaderBridge.tsx
54821
+ /**
54822
+ * Bridges messaging header content from inside <MessagingApp> into the
54823
+ * portal shell's <ScreenHeader>. Render this as a child of <MessagingApp>
54824
+ * with `hideTopBar` set, and the messaging UI's own <MessagesTopBar /> is
54825
+ * suppressed in favour of populating the existing portal header.
54826
+ *
54827
+ * Right-hand actions are delegated to <MessagesHeaderActions /> from
54828
+ * messaging-ui so this stays in sync with <MessagesTopBar />. The breadcrumbs
54829
+ * are owned here because the portal shell shows them differently from the
54830
+ * messaging-ui's inline page-title fallback.
54831
+ */
54832
+ const ROUTE_TITLES = {
54833
+ pins: "Pinned Messages",
54834
+ new: "New Message",
54835
+ scheduled: "Scheduled Messages"
54836
+ };
54837
+ function fallbackRenderImage(props) {
54838
+ return /* @__PURE__ */ jsx("img", {
54839
+ src: props.src,
54840
+ alt: props.alt,
54841
+ width: props.width,
54842
+ height: props.height,
54843
+ className: props.className
54844
+ });
54845
+ }
54846
+ function MessagingHeaderBridge() {
54847
+ const { auth, renderImage: contextRenderImage } = useMessagingApp();
54848
+ const navigation = useMessagingNavigation();
54849
+ const { currentRoute } = navigation;
54850
+ const { data: conversation } = useConversation("conversationId" in currentRoute ? currentRoute.conversationId : 0);
54851
+ const renderImage = contextRenderImage ?? fallbackRenderImage;
54852
+ const currentUser = auth.currentUser;
54853
+ const conversationName = conversation?.name;
54854
+ const routeTitle = ROUTE_TITLES[currentRoute.view];
54855
+ useScreenHeaderBreadcrumbs(useMemo(() => {
54856
+ if (routeTitle) return /* @__PURE__ */ jsx("h1", {
54857
+ className: "text-foreground text-lg font-semibold",
54858
+ children: routeTitle
54859
+ });
54860
+ if (conversationName) return /* @__PURE__ */ jsx("h1", {
54861
+ className: "text-foreground truncate text-lg font-semibold",
54862
+ children: conversationName
54863
+ });
54864
+ return null;
54865
+ }, [routeTitle, conversationName]));
54866
+ useScreenHeaderActions(useMemo(() => /* @__PURE__ */ jsx(MessagingTranslationBridge, { children: /* @__PURE__ */ jsx(MessagesHeaderActions, {
54867
+ conversation,
54868
+ currentUser,
54869
+ navigation,
54870
+ renderImage
54871
+ }) }), [
54872
+ conversation,
54873
+ currentUser,
54874
+ navigation,
54875
+ renderImage
54876
+ ]));
54877
+ return null;
54878
+ }
54879
+ //#endregion
54880
54880
  //#region src/screens/MessagingScreen.tsx
54881
54881
  function renderImage(props) {
54882
54882
  return /* @__PURE__ */ jsx("img", {
@@ -55021,4 +55021,4 @@ const messagingScreenPropertySchema = {
55021
55021
  //#endregion
55022
55022
  export { useMessagingAuth as a, useMessagingConfig as i, messagingScreenPropertySchema as n, createFluidFileUploader as r, MessagingScreen as t };
55023
55023
 
55024
- //# sourceMappingURL=MessagingScreen-Dks3Jd3O.mjs.map
55024
+ //# sourceMappingURL=MessagingScreen-VBxlbe-V.mjs.map