@fluid-app/portal-sdk 0.1.325 → 0.1.327
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/index.cjs +5 -9
- package/dist/index.cjs.map +1 -1
- package/dist/index.d.cts +4 -4
- package/dist/index.d.mts +4 -4
- package/dist/index.mjs +5 -9
- package/dist/index.mjs.map +1 -1
- package/package.json +9 -9
package/dist/index.d.cts
CHANGED
|
@@ -4718,10 +4718,10 @@ interface PageRouterProps {
|
|
|
4718
4718
|
baseSlug: string;
|
|
4719
4719
|
restParams: string;
|
|
4720
4720
|
/**
|
|
4721
|
-
* Slugs from the active navigation. When provided,
|
|
4722
|
-
* render if they're
|
|
4723
|
-
*
|
|
4724
|
-
*
|
|
4721
|
+
* Slugs from the active navigation. When provided, screens listed in
|
|
4722
|
+
* `OPT_IN_SYSTEM_SCREENS` (messages, contacts) only render if they're
|
|
4723
|
+
* reachable via the nav — matching the implicit gating builder screens
|
|
4724
|
+
* get from being sourced via `appData.screens`. All other system screens
|
|
4725
4725
|
* bypass this check. Omit to render system screens unconditionally.
|
|
4726
4726
|
*/
|
|
4727
4727
|
navSlugs?: readonly string[] | undefined;
|
package/dist/index.d.mts
CHANGED
|
@@ -4719,10 +4719,10 @@ interface PageRouterProps {
|
|
|
4719
4719
|
baseSlug: string;
|
|
4720
4720
|
restParams: string;
|
|
4721
4721
|
/**
|
|
4722
|
-
* Slugs from the active navigation. When provided,
|
|
4723
|
-
* render if they're
|
|
4724
|
-
*
|
|
4725
|
-
*
|
|
4722
|
+
* Slugs from the active navigation. When provided, screens listed in
|
|
4723
|
+
* `OPT_IN_SYSTEM_SCREENS` (messages, contacts) only render if they're
|
|
4724
|
+
* reachable via the nav — matching the implicit gating builder screens
|
|
4725
|
+
* get from being sourced via `appData.screens`. All other system screens
|
|
4726
4726
|
* bypass this check. Omit to render system screens unconditionally.
|
|
4727
4727
|
*/
|
|
4728
4728
|
navSlugs?: readonly string[] | undefined;
|
package/dist/index.mjs
CHANGED
|
@@ -2162,15 +2162,11 @@ const SYSTEM_SLUG_SCREEN_MAP = {
|
|
|
2162
2162
|
"app-download": AppDownloadScreen
|
|
2163
2163
|
};
|
|
2164
2164
|
/**
|
|
2165
|
-
* System screens that
|
|
2166
|
-
*
|
|
2167
|
-
*
|
|
2165
|
+
* System screens that a portal must opt into by adding them to its active
|
|
2166
|
+
* navigation. Every other system screen is reachable by default; these two
|
|
2167
|
+
* only render when their nav slug is present.
|
|
2168
2168
|
*/
|
|
2169
|
-
const
|
|
2170
|
-
ProfileScreen$1,
|
|
2171
|
-
OrdersScreen$1,
|
|
2172
|
-
SubscriptionsScreen$1
|
|
2173
|
-
]);
|
|
2169
|
+
const OPT_IN_SYSTEM_SCREENS = new Set([MessagingScreen$1, ContactsScreen$1]);
|
|
2174
2170
|
/** Pre-sorted keys for greedy prefix matching (longest first). */
|
|
2175
2171
|
const SORTED_SCREEN_KEYS = Object.keys(SYSTEM_SLUG_SCREEN_MAP).sort((a, b) => b.length - a.length);
|
|
2176
2172
|
/** Prefix-match a slug against screen map keys, longest match first. */
|
|
@@ -2233,7 +2229,7 @@ function PageRouter({ currentSlug, currentNavItem, customPages, screens, baseSlu
|
|
|
2233
2229
|
});
|
|
2234
2230
|
}
|
|
2235
2231
|
const SystemScreen = SYSTEM_SLUG_SCREEN_MAP[baseSlug] ?? findScreenByPrefix(currentSlug);
|
|
2236
|
-
const systemScreenInNav = navSlugs === void 0 || SystemScreen !== void 0 && (
|
|
2232
|
+
const systemScreenInNav = navSlugs === void 0 || SystemScreen !== void 0 && (!OPT_IN_SYSTEM_SCREENS.has(SystemScreen) || isSystemScreenCoveredByNav(SystemScreen, navSlugs));
|
|
2237
2233
|
if (SystemScreen && systemScreenInNav) return /* @__PURE__ */ jsx(Suspense, {
|
|
2238
2234
|
fallback: /* @__PURE__ */ jsx("div", {
|
|
2239
2235
|
className: "flex h-full items-center justify-center",
|