@the-portland-company/shell 0.102.3 → 0.104.0
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/CHANGELOG.md +7 -0
- package/dist/app-chrome.cjs +65 -9
- package/dist/app-chrome.cjs.map +1 -1
- package/dist/app-chrome.d.cts +1 -1
- package/dist/app-chrome.d.ts +1 -1
- package/dist/app-chrome.js +21 -6
- package/dist/app-chrome.js.map +1 -1
- package/dist/{chunk-PR5QBA7S.js → chunk-7XWRF7Y2.js} +49 -8
- package/dist/chunk-7XWRF7Y2.js.map +1 -0
- package/dist/{index-DTFEH6Tk.d.cts → index-BKVWMe9_.d.cts} +18 -2
- package/dist/{index-BTYiaHqq.d.ts → index-DnrsvxhZ.d.ts} +18 -2
- package/dist/index.d.cts +2 -2
- package/dist/index.d.ts +2 -2
- package/dist/native.cjs +47 -5
- package/dist/native.cjs.map +1 -1
- package/dist/native.d.cts +1 -1
- package/dist/native.d.ts +1 -1
- package/dist/native.js +1 -1
- package/package.json +3 -3
- package/dist/chunk-PR5QBA7S.js.map +0 -1
package/dist/app-chrome.d.cts
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import * as react_jsx_runtime from 'react/jsx-runtime';
|
|
2
2
|
import { ReactNode } from 'react';
|
|
3
|
-
import { S as StandardNavIconKey, z as NavIcon, N as NavItem, D as NavBreadcrumb, E as StandardNavMode, G as NavLinkComponent, I as NavChromeFetcher, J as NavMode, L as NavUserMenu, M as NavOrgOption, i as NotificationsAdapter, O as ChromeOrgSummary, Q as NavFooterLink, U as NavFooter, W as NavDisplayMode } from './index-
|
|
3
|
+
import { S as StandardNavIconKey, z as NavIcon, N as NavItem, D as NavBreadcrumb, E as StandardNavMode, G as NavLinkComponent, I as NavChromeFetcher, J as NavMode, L as NavUserMenu, M as NavOrgOption, i as NotificationsAdapter, O as ChromeOrgSummary, Q as NavFooterLink, U as NavFooter, W as NavDisplayMode } from './index-BKVWMe9_.cjs';
|
|
4
4
|
import './theme-preference.cjs';
|
|
5
5
|
import './brand-favicon.cjs';
|
|
6
6
|
|
package/dist/app-chrome.d.ts
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import * as react_jsx_runtime from 'react/jsx-runtime';
|
|
2
2
|
import { ReactNode } from 'react';
|
|
3
|
-
import { S as StandardNavIconKey, z as NavIcon, N as NavItem, D as NavBreadcrumb, E as StandardNavMode, G as NavLinkComponent, I as NavChromeFetcher, J as NavMode, L as NavUserMenu, M as NavOrgOption, i as NotificationsAdapter, O as ChromeOrgSummary, Q as NavFooterLink, U as NavFooter, W as NavDisplayMode } from './index-
|
|
3
|
+
import { S as StandardNavIconKey, z as NavIcon, N as NavItem, D as NavBreadcrumb, E as StandardNavMode, G as NavLinkComponent, I as NavChromeFetcher, J as NavMode, L as NavUserMenu, M as NavOrgOption, i as NotificationsAdapter, O as ChromeOrgSummary, Q as NavFooterLink, U as NavFooter, W as NavDisplayMode } from './index-DnrsvxhZ.js';
|
|
4
4
|
import './theme-preference.js';
|
|
5
5
|
import './brand-favicon.js';
|
|
6
6
|
|
package/dist/app-chrome.js
CHANGED
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
"use client";
|
|
2
2
|
import { broadcastLogout, watchLogout } from './chunk-LL6LSJAH.js';
|
|
3
3
|
import { writeUrlState } from './chunk-GVQKZI5X.js';
|
|
4
|
-
import { clearBetaBannerDismissal, standardPolitogyNav, standardNavIcons, isNavItemActive, NavAppShell } from './chunk-
|
|
5
|
-
export { standardNavIcons } from './chunk-
|
|
4
|
+
import { clearBetaBannerDismissal, standardPolitogyNav, standardNavIcons, isNavItemActive, isUnderNavPattern, NavAppShell } from './chunk-7XWRF7Y2.js';
|
|
5
|
+
export { standardNavIcons } from './chunk-7XWRF7Y2.js';
|
|
6
6
|
import { orgIdTail, ORG_ID_QUERY_PARAM, settingsBaseUrl, authBaseUrl, readOrgSelectorFromUrl, matchOrgSelector, syncOrgIdInUrl, isOrgId, switchActiveOrg, ACTIVE_ORG_QUERY_PARAM, writeActiveOrgCookie, resolveActiveOrg, readActiveOrgCookie } from './chunk-5LO5W7W5.js';
|
|
7
7
|
import { warnDeprecated, NavChromeProvider, FuelAction, NotificationsAction, OrganizationSettingsAction, MyProfileAction, useChromeMe, useNavChromeDedupedFetch, useChromeOrgs, useNavChromeFetcher } from './chunk-HR2TBHHH.js';
|
|
8
8
|
import './chunk-BHRVZPZ7.js';
|
|
@@ -801,18 +801,33 @@ function FrameBody({
|
|
|
801
801
|
const navItems = core?.nav ?? derivedNavItems;
|
|
802
802
|
const navIsActive = useMemo(() => {
|
|
803
803
|
const childHrefs = /* @__PURE__ */ new Map();
|
|
804
|
+
const extra = /* @__PURE__ */ new Map();
|
|
805
|
+
const addExtra = (href, pats) => {
|
|
806
|
+
if (!pats?.length) return;
|
|
807
|
+
extra.set(href, [...extra.get(href) ?? [], ...pats]);
|
|
808
|
+
};
|
|
804
809
|
for (const item of navItems) {
|
|
805
|
-
if (!item.href
|
|
810
|
+
if (!item.href) continue;
|
|
811
|
+
addExtra(item.href, item.activeOn);
|
|
812
|
+
if (!item.children?.length) continue;
|
|
806
813
|
const hrefs = [];
|
|
807
814
|
for (const child of item.children) {
|
|
808
|
-
if (child.href)
|
|
815
|
+
if (child.href) {
|
|
816
|
+
hrefs.push(child.href);
|
|
817
|
+
addExtra(child.href, child.activeOn);
|
|
818
|
+
}
|
|
819
|
+
addExtra(item.href, child.activeOn);
|
|
809
820
|
for (const leaf of child.children ?? []) {
|
|
810
|
-
if (leaf.href)
|
|
821
|
+
if (leaf.href) {
|
|
822
|
+
hrefs.push(leaf.href);
|
|
823
|
+
addExtra(leaf.href, leaf.activeOn);
|
|
824
|
+
}
|
|
825
|
+
addExtra(item.href, leaf.activeOn);
|
|
811
826
|
}
|
|
812
827
|
}
|
|
813
828
|
childHrefs.set(item.href, hrefs);
|
|
814
829
|
}
|
|
815
|
-
return (pathname2, href) => isNavItemActive(pathname2, href) || (childHrefs.get(href) ?? []).some((h) => isNavItemActive(pathname2, h));
|
|
830
|
+
return (pathname2, href) => isNavItemActive(pathname2, href) || (childHrefs.get(href) ?? []).some((h) => isNavItemActive(pathname2, h)) || (extra.get(href) ?? []).some((p) => isUnderNavPattern(pathname2, p));
|
|
816
831
|
}, [navItems]);
|
|
817
832
|
const derivedBreadcrumbs = useMemo(
|
|
818
833
|
() => deriveBreadcrumbs(navItems, pathname, { search, origin: meta.origin }),
|