(props: {
pathname: string;
onNavigate?: () => void;
showBrand?: boolean;
onOpenCommands: () => void;
})
| 167 | // ── SidebarContent ─────────────────────────────────────────────────────── |
| 168 | |
| 169 | function SidebarContent(props: { |
| 170 | pathname: string; |
| 171 | onNavigate?: () => void; |
| 172 | showBrand?: boolean; |
| 173 | onOpenCommands: () => void; |
| 174 | }) { |
| 175 | const isHome = props.pathname === "/"; |
| 176 | const isSecrets = props.pathname === "/secrets"; |
| 177 | const isPolicies = props.pathname === "/policies"; |
| 178 | const isToolkits = props.pathname === "/toolkits" || props.pathname.startsWith("/toolkits/"); |
| 179 | const isArtifacts = props.pathname === "/artifacts" || props.pathname.startsWith("/artifacts/"); |
| 180 | |
| 181 | return ( |
| 182 | <> |
| 183 | {props.showBrand !== false && ( |
| 184 | <div className="desktop-macos-titlebar flex h-12 shrink-0 items-center gap-2 border-b border-sidebar-border px-4"> |
| 185 | <Link to="/{-$orgSlug}" className="desktop-macos-no-drag flex shrink-0 items-center"> |
| 186 | <Wordmark /> |
| 187 | </Link> |
| 188 | <div className="desktop-macos-no-drag ml-auto flex min-w-0 flex-1 justify-end pl-3"> |
| 189 | <ServerConnectionMenu variant="header" /> |
| 190 | </div> |
| 191 | </div> |
| 192 | )} |
| 193 | |
| 194 | <nav className="flex flex-1 flex-col overflow-y-auto p-2"> |
| 195 | <NavItem |
| 196 | to="/{-$orgSlug}" |
| 197 | label="Integrations" |
| 198 | active={isHome} |
| 199 | onNavigate={props.onNavigate} |
| 200 | /> |
| 201 | <NavItem |
| 202 | to="/{-$orgSlug}/secrets" |
| 203 | label="Secrets" |
| 204 | active={isSecrets} |
| 205 | onNavigate={props.onNavigate} |
| 206 | /> |
| 207 | <NavItem |
| 208 | to="/{-$orgSlug}/policies" |
| 209 | label="Policies" |
| 210 | active={isPolicies} |
| 211 | onNavigate={props.onNavigate} |
| 212 | /> |
| 213 | <NavItem |
| 214 | to="/{-$orgSlug}/toolkits" |
| 215 | label="Toolkits" |
| 216 | active={isToolkits} |
| 217 | onNavigate={props.onNavigate} |
| 218 | /> |
| 219 | <NavItem |
| 220 | to="/{-$orgSlug}/artifacts" |
| 221 | label="Artifacts" |
| 222 | active={isArtifacts} |
| 223 | onNavigate={props.onNavigate} |
| 224 | /> |
| 225 | |
| 226 | <PluginNav pathname={props.pathname} onNavigate={props.onNavigate} /> |
nothing calls this directly
no outgoing calls
no test coverage detected