@the-portland-company/shell 0.36.0 → 0.36.2

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.
@@ -2058,116 +2058,118 @@ function NavTopBar({
2058
2058
  }
2059
2059
  ) })
2060
2060
  ] }),
2061
- /* @__PURE__ */ jsxs("div", { className: "absolute right-0 z-30 mt-2 w-72 rounded-xl border border-[color:var(--line)] bg-[color:var(--panel-elevated)] py-1 shadow-[var(--shadow-soft)]", children: [
2061
+ /* @__PURE__ */ jsxs("div", { className: "absolute right-0 z-30 mt-2 flex max-h-[calc(100vh-5rem)] w-72 flex-col overflow-hidden rounded-xl border border-[color:var(--line)] bg-[color:var(--panel-elevated)] py-1 shadow-[var(--shadow-soft)]", children: [
2062
2062
  /* @__PURE__ */ jsx(TopBarPanelArrow, {}),
2063
- userMenu?.myProfileHref ? /* @__PURE__ */ jsxs(
2064
- "a",
2065
- {
2066
- href: safeHref(userMenu.myProfileHref),
2067
- className: "flex w-full items-center gap-2.5 px-4 py-2.5 text-left text-sm font-medium text-[color:var(--foreground)] hover:bg-[color:var(--panel)]",
2068
- children: [
2069
- /* @__PURE__ */ jsx(ProfileIcon, {}),
2070
- "My Profile"
2071
- ]
2072
- }
2073
- ) : null,
2074
- userMenu?.organizationSettingsHref ? /* @__PURE__ */ jsxs(
2075
- "a",
2076
- {
2077
- href: safeHref(userMenu.organizationSettingsHref),
2078
- className: "flex w-full items-center gap-2.5 border-t border-[color:var(--line)] px-4 py-2.5 text-left text-sm font-medium text-[color:var(--foreground)] hover:bg-[color:var(--panel)]",
2079
- children: [
2080
- /* @__PURE__ */ jsx(BriefcaseIcon, {}),
2081
- "Organization Settings"
2082
- ]
2083
- }
2084
- ) : null,
2085
- userMenu?.roles && userMenu.roles.length > 0 ? /* @__PURE__ */ jsxs("div", { className: "border-t border-[color:var(--line)] px-4 py-3", children: [
2086
- /* @__PURE__ */ jsx("p", { className: "mb-2 text-[11px] font-semibold uppercase tracking-[0.08em] text-[color:var(--muted)]", children: "Roles & Organizations" }),
2087
- /* @__PURE__ */ jsx("ul", { className: "flex flex-col gap-1.5", children: userMenu.roles.map((r, i) => /* @__PURE__ */ jsxs("li", { className: "flex flex-wrap items-center gap-1.5 text-sm", children: [
2088
- /* @__PURE__ */ jsx("span", { className: "rounded-md bg-[color:var(--panel)] px-2 py-0.5 text-xs font-bold uppercase tracking-wide text-[color:var(--foreground)]", children: r.role }),
2089
- r.orgName ? /* @__PURE__ */ jsxs("span", { className: "text-[color:var(--muted)]", children: [
2090
- "in ",
2091
- r.orgName
2092
- ] }) : null
2093
- ] }, `${r.role}-${i}`)) })
2094
- ] }) : null,
2095
- userMenu?.accounts && userMenu.accounts.length > 0 ? /* @__PURE__ */ jsxs("div", { className: "border-t border-[color:var(--line)] px-4 py-3", children: [
2096
- /* @__PURE__ */ jsx("p", { className: "mb-2 text-[11px] font-semibold uppercase tracking-[0.08em] text-[color:var(--muted)]", children: "Accounts" }),
2097
- /* @__PURE__ */ jsx("ul", { className: "flex flex-col gap-1", children: userMenu.accounts.map((a) => /* @__PURE__ */ jsxs("li", { className: "flex items-center gap-2.5", children: [
2098
- /* @__PURE__ */ jsxs(
2099
- "button",
2063
+ /* @__PURE__ */ jsxs("div", { className: "min-h-0 flex-1 overflow-y-auto overscroll-contain", children: [
2064
+ userMenu?.myProfileHref ? /* @__PURE__ */ jsxs(
2065
+ "a",
2066
+ {
2067
+ href: safeHref(userMenu.myProfileHref),
2068
+ className: "flex w-full items-center gap-2.5 px-4 py-2.5 text-left text-sm font-medium text-[color:var(--foreground)] hover:bg-[color:var(--panel)]",
2069
+ children: [
2070
+ /* @__PURE__ */ jsx(ProfileIcon, {}),
2071
+ "My Profile"
2072
+ ]
2073
+ }
2074
+ ) : null,
2075
+ userMenu?.organizationSettingsHref ? /* @__PURE__ */ jsxs(
2076
+ "a",
2077
+ {
2078
+ href: safeHref(userMenu.organizationSettingsHref),
2079
+ className: "flex w-full items-center gap-2.5 border-t border-[color:var(--line)] px-4 py-2.5 text-left text-sm font-medium text-[color:var(--foreground)] hover:bg-[color:var(--panel)]",
2080
+ children: [
2081
+ /* @__PURE__ */ jsx(BriefcaseIcon, {}),
2082
+ "Organization Settings"
2083
+ ]
2084
+ }
2085
+ ) : null,
2086
+ userMenu?.roles && userMenu.roles.length > 0 ? /* @__PURE__ */ jsxs("div", { className: "border-t border-[color:var(--line)] px-4 py-3", children: [
2087
+ /* @__PURE__ */ jsx("p", { className: "mb-2 text-[11px] font-semibold uppercase tracking-[0.08em] text-[color:var(--muted)]", children: "Roles & Organizations" }),
2088
+ /* @__PURE__ */ jsx("ul", { className: "flex flex-col gap-1.5", children: userMenu.roles.map((r, i) => /* @__PURE__ */ jsxs("li", { className: "flex flex-wrap items-center gap-1.5 text-sm", children: [
2089
+ /* @__PURE__ */ jsx("span", { className: "rounded-md bg-[color:var(--panel)] px-2 py-0.5 text-xs font-bold uppercase tracking-wide text-[color:var(--foreground)]", children: r.role }),
2090
+ r.orgName ? /* @__PURE__ */ jsxs("span", { className: "text-[color:var(--muted)]", children: [
2091
+ "in ",
2092
+ r.orgName
2093
+ ] }) : null
2094
+ ] }, `${r.role}-${i}`)) })
2095
+ ] }) : null,
2096
+ userMenu?.accounts && userMenu.accounts.length > 0 ? /* @__PURE__ */ jsxs("div", { className: "border-t border-[color:var(--line)] px-4 py-3", children: [
2097
+ /* @__PURE__ */ jsx("p", { className: "mb-2 text-[11px] font-semibold uppercase tracking-[0.08em] text-[color:var(--muted)]", children: "Accounts" }),
2098
+ /* @__PURE__ */ jsx("ul", { className: "flex flex-col gap-1", children: userMenu.accounts.map((a) => /* @__PURE__ */ jsxs("li", { className: "flex items-center gap-2.5", children: [
2099
+ /* @__PURE__ */ jsxs(
2100
+ "button",
2101
+ {
2102
+ type: "button",
2103
+ onClick: () => {
2104
+ if (!a.active) userMenu.onSwitchAccount?.(a.id);
2105
+ },
2106
+ className: "flex min-w-0 flex-1 items-center gap-2.5 rounded-lg px-1 py-1 text-left hover:bg-[color:var(--panel)]",
2107
+ children: [
2108
+ /* @__PURE__ */ jsx("span", { className: "flex h-8 w-8 shrink-0 items-center justify-center overflow-hidden rounded-full bg-[color:var(--color-race-red)] text-[11px] font-bold text-white", children: a.avatarUrl ? /* @__PURE__ */ jsx("img", { src: a.avatarUrl, alt: "", className: "h-full w-full object-cover" }) : (a.name ?? a.email ?? "?").slice(0, 2).toUpperCase() }),
2109
+ /* @__PURE__ */ jsxs("span", { className: "flex min-w-0 flex-col leading-tight", children: [
2110
+ /* @__PURE__ */ jsx(
2111
+ "span",
2112
+ {
2113
+ className: [
2114
+ "truncate text-sm font-semibold",
2115
+ a.active ? "text-[color:var(--color-race-red)]" : "text-[color:var(--foreground)]"
2116
+ ].join(" "),
2117
+ children: a.name ?? a.email ?? a.id.slice(0, 8)
2118
+ }
2119
+ ),
2120
+ /* @__PURE__ */ jsx("span", { className: "truncate text-xs text-[color:var(--muted)]", children: a.active ? "Active" : a.email ?? "" })
2121
+ ] })
2122
+ ]
2123
+ }
2124
+ ),
2125
+ !a.active && userMenu.onRemoveAccount ? /* @__PURE__ */ jsx(
2126
+ "button",
2127
+ {
2128
+ type: "button",
2129
+ "aria-label": `Remove ${a.name ?? a.email ?? "account"}`,
2130
+ onClick: () => userMenu.onRemoveAccount?.(a.id),
2131
+ className: "shrink-0 rounded p-1 text-[color:var(--color-race-red)] hover:bg-[color:var(--panel)]",
2132
+ children: /* @__PURE__ */ jsx(TrashIcon, {})
2133
+ }
2134
+ ) : null
2135
+ ] }, a.id)) }),
2136
+ userMenu.addAccountHref || userMenu.onAddAccount ? userMenu.addAccountHref ? /* @__PURE__ */ jsxs(
2137
+ "a",
2100
2138
  {
2101
- type: "button",
2102
- onClick: () => {
2103
- if (!a.active) userMenu.onSwitchAccount?.(a.id);
2104
- },
2105
- className: "flex min-w-0 flex-1 items-center gap-2.5 rounded-lg px-1 py-1 text-left hover:bg-[color:var(--panel)]",
2139
+ href: safeHref(userMenu.addAccountHref),
2140
+ className: "mt-1.5 flex items-center gap-2.5 rounded-lg px-1 py-1.5 text-sm font-semibold text-[color:var(--color-race-red)] hover:bg-[color:var(--panel)]",
2106
2141
  children: [
2107
- /* @__PURE__ */ jsx("span", { className: "flex h-8 w-8 shrink-0 items-center justify-center overflow-hidden rounded-full bg-[color:var(--color-race-red)] text-[11px] font-bold text-white", children: a.avatarUrl ? /* @__PURE__ */ jsx("img", { src: a.avatarUrl, alt: "", className: "h-full w-full object-cover" }) : (a.name ?? a.email ?? "?").slice(0, 2).toUpperCase() }),
2108
- /* @__PURE__ */ jsxs("span", { className: "flex min-w-0 flex-col leading-tight", children: [
2109
- /* @__PURE__ */ jsx(
2110
- "span",
2111
- {
2112
- className: [
2113
- "truncate text-sm font-semibold",
2114
- a.active ? "text-[color:var(--color-race-red)]" : "text-[color:var(--foreground)]"
2115
- ].join(" "),
2116
- children: a.name ?? a.email ?? a.id.slice(0, 8)
2117
- }
2118
- ),
2119
- /* @__PURE__ */ jsx("span", { className: "truncate text-xs text-[color:var(--muted)]", children: a.active ? "Active" : a.email ?? "" })
2120
- ] })
2142
+ /* @__PURE__ */ jsx(AddUserIcon, {}),
2143
+ "Add Account"
2121
2144
  ]
2122
2145
  }
2123
- ),
2124
- !a.active && userMenu.onRemoveAccount ? /* @__PURE__ */ jsx(
2146
+ ) : /* @__PURE__ */ jsxs(
2125
2147
  "button",
2126
2148
  {
2127
2149
  type: "button",
2128
- "aria-label": `Remove ${a.name ?? a.email ?? "account"}`,
2129
- onClick: () => userMenu.onRemoveAccount?.(a.id),
2130
- className: "shrink-0 rounded p-1 text-[color:var(--color-race-red)] hover:bg-[color:var(--panel)]",
2131
- children: /* @__PURE__ */ jsx(TrashIcon, {})
2150
+ onClick: userMenu.onAddAccount,
2151
+ className: "mt-1.5 flex w-full items-center gap-2.5 rounded-lg px-1 py-1.5 text-left text-sm font-semibold text-[color:var(--color-race-red)] hover:bg-[color:var(--panel)]",
2152
+ children: [
2153
+ /* @__PURE__ */ jsx(AddUserIcon, {}),
2154
+ "Add Account"
2155
+ ]
2132
2156
  }
2133
2157
  ) : null
2134
- ] }, a.id)) }),
2135
- userMenu.addAccountHref || userMenu.onAddAccount ? userMenu.addAccountHref ? /* @__PURE__ */ jsxs(
2136
- "a",
2158
+ ] }) : null,
2159
+ userMenu?.theme ? /* @__PURE__ */ jsx("div", { className: "border-t border-[color:var(--line)]", children: /* @__PURE__ */ jsx(
2160
+ NavThemeControl,
2137
2161
  {
2138
- href: safeHref(userMenu.addAccountHref),
2139
- className: "mt-1.5 flex items-center gap-2.5 rounded-lg px-1 py-1.5 text-sm font-semibold text-[color:var(--color-race-red)] hover:bg-[color:var(--panel)]",
2140
- children: [
2141
- /* @__PURE__ */ jsx(AddUserIcon, {}),
2142
- "Add Account"
2143
- ]
2144
- }
2145
- ) : /* @__PURE__ */ jsxs(
2146
- "button",
2147
- {
2148
- type: "button",
2149
- onClick: userMenu.onAddAccount,
2150
- className: "mt-1.5 flex w-full items-center gap-2.5 rounded-lg px-1 py-1.5 text-left text-sm font-semibold text-[color:var(--color-race-red)] hover:bg-[color:var(--panel)]",
2151
- children: [
2152
- /* @__PURE__ */ jsx(AddUserIcon, {}),
2153
- "Add Account"
2154
- ]
2162
+ value: userMenu.theme.value,
2163
+ onChange: userMenu.theme.onChange
2155
2164
  }
2156
- ) : null
2157
- ] }) : null,
2158
- userMenu?.theme ? /* @__PURE__ */ jsx("div", { className: "border-t border-[color:var(--line)]", children: /* @__PURE__ */ jsx(
2159
- NavThemeControl,
2160
- {
2161
- value: userMenu.theme.value,
2162
- onChange: userMenu.theme.onChange
2163
- }
2164
- ) }) : null,
2165
+ ) }) : null
2166
+ ] }),
2165
2167
  onSignOut ? /* @__PURE__ */ jsxs(
2166
2168
  "button",
2167
2169
  {
2168
2170
  type: "button",
2169
2171
  onClick: onSignOut,
2170
- className: "flex w-full items-center gap-2.5 border-t border-[color:var(--line)] px-4 py-2.5 text-left text-sm font-medium text-[color:var(--foreground)] hover:bg-[color:var(--panel)] hover:text-[color:var(--color-race-red)]",
2172
+ className: "flex w-full shrink-0 items-center gap-2.5 border-t border-[color:var(--line)] px-4 py-2.5 text-left text-sm font-medium text-[color:var(--foreground)] hover:bg-[color:var(--panel)] hover:text-[color:var(--color-race-red)]",
2171
2173
  children: [
2172
2174
  /* @__PURE__ */ jsx(SignOutIcon, {}),
2173
2175
  "Sign out"
@@ -2489,5 +2491,5 @@ function NavAppShell({
2489
2491
  }
2490
2492
 
2491
2493
  export { CAMPAIGN_FEATURE_AVAILABILITY, CORE_APP_ORIGIN, CORE_BILLING_PATH, FuelAction, NavAppShell, NavBetaBanner, NavChromeProvider, NavDisplayAction, NavSidebar, NavTabStrip, NavThemeControl, NavTopBar, NotificationsAction, SupportAction, TopBarCountBadge, TopBarPanelArrow, TopBarPopover, TopBarTooltip, TopBarWidgetSlot, envChipClasses, isNavItemActive, standardPolitogyNav, topBarIconButtonClass, useChromeMe, useChromeOrgs, useNavChromeFetcher, useThemePreference };
2492
- //# sourceMappingURL=chunk-QX2UNWSE.js.map
2493
- //# sourceMappingURL=chunk-QX2UNWSE.js.map
2494
+ //# sourceMappingURL=chunk-LIGKGXFT.js.map
2495
+ //# sourceMappingURL=chunk-LIGKGXFT.js.map