@the-portland-company/shell 0.2.0 → 0.2.1
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 +6 -0
- package/dist/index.cjs +22 -0
- package/dist/index.cjs.map +1 -1
- package/dist/index.d.cts +37 -1
- package/dist/index.d.ts +37 -1
- package/dist/index.js +18 -1
- package/dist/index.js.map +1 -1
- package/package.json +1 -1
package/CHANGELOG.md
CHANGED
|
@@ -1,5 +1,11 @@
|
|
|
1
1
|
# Changelog
|
|
2
2
|
|
|
3
|
+
## 0.2.1 — 2026-05-13
|
|
4
|
+
|
|
5
|
+
### Added
|
|
6
|
+
- `<ShellChrome>` component — drops chrome data (organization, linkedAccounts, support, devNotesMenu, myProfileHref) into the shell from a position deep in the tree. Use this when the data lives in app contexts nested BELOW `<ShellProvider>`. Apps that have the data at the top can keep using `<ShellProvider>` props directly.
|
|
7
|
+
- Re-exported chrome context objects (`ShellOrgContext`, `ShellLinkedAccountsContext`, `ShellSupportProviderContext`, `ShellChromeContext`) so power users can write their own bindings.
|
|
8
|
+
|
|
3
9
|
## 0.2.0 — 2026-05-13
|
|
4
10
|
|
|
5
11
|
### Added
|
package/dist/index.cjs
CHANGED
|
@@ -1782,6 +1782,23 @@ function AppLayout({
|
|
|
1782
1782
|
overlaySlot
|
|
1783
1783
|
] });
|
|
1784
1784
|
}
|
|
1785
|
+
function ShellChrome({
|
|
1786
|
+
children,
|
|
1787
|
+
organization,
|
|
1788
|
+
linkedAccounts,
|
|
1789
|
+
support,
|
|
1790
|
+
devNotesMenu,
|
|
1791
|
+
myProfileHref
|
|
1792
|
+
}) {
|
|
1793
|
+
const chrome = react$1.useMemo(
|
|
1794
|
+
() => ({
|
|
1795
|
+
devNotesMenu: devNotesMenu ?? null,
|
|
1796
|
+
myProfileHref: myProfileHref ?? "/my-profile"
|
|
1797
|
+
}),
|
|
1798
|
+
[devNotesMenu, myProfileHref]
|
|
1799
|
+
);
|
|
1800
|
+
return /* @__PURE__ */ jsxRuntime.jsx(ShellOrgContext.Provider, { value: organization ?? null, children: /* @__PURE__ */ jsxRuntime.jsx(ShellLinkedAccountsContext.Provider, { value: linkedAccounts ?? null, children: /* @__PURE__ */ jsxRuntime.jsx(ShellSupportProviderContext.Provider, { value: support ?? null, children: /* @__PURE__ */ jsxRuntime.jsx(ShellChromeContext.Provider, { value: chrome, children }) }) }) });
|
|
1801
|
+
}
|
|
1785
1802
|
|
|
1786
1803
|
// src/sw/registerShellPrecache.ts
|
|
1787
1804
|
async function registerShellPrecache(opts = {}) {
|
|
@@ -1823,7 +1840,12 @@ exports.HeaderTabBar = HeaderTabBar;
|
|
|
1823
1840
|
exports.OrgSelector = OrgSelector;
|
|
1824
1841
|
exports.PageContainer = PageContainer;
|
|
1825
1842
|
exports.PageHeader = PageHeader;
|
|
1843
|
+
exports.ShellChrome = ShellChrome;
|
|
1844
|
+
exports.ShellChromeContext = ShellChromeContext;
|
|
1845
|
+
exports.ShellLinkedAccountsContext = ShellLinkedAccountsContext;
|
|
1846
|
+
exports.ShellOrgContext = ShellOrgContext;
|
|
1826
1847
|
exports.ShellProvider = ShellProvider;
|
|
1848
|
+
exports.ShellSupportProviderContext = ShellSupportProviderContext;
|
|
1827
1849
|
exports.Sidebar = Sidebar;
|
|
1828
1850
|
exports.SupportRequestButton = SupportRequestButton;
|
|
1829
1851
|
exports.UserMenu = UserMenu;
|