Linger is An Open-Source Personal Agent That Runs Fully on Your PC. We aim to break Big Tech’s grip on AI by bringing powerful local AI to everyday computers through efficient model–harness co-design, so everyone can run their own.
/** Paths sharing a secondary navigation keep their layout mounted. */
export function routeLayoutKey(pathname: string): string {
// An opened Document sits inside the Workspace layout beside Library pages.
const workspace = pathname.match(
/^(\/t\/[^/]+)\/(?:library|documents)(?=\/|$)/,
);
if (workspace) return `${workspace[1]}/library`;
return (
pathname.match(/^\/t\/[^/]+\/settings(?=\/|$)/)?.[0] ??
pathname.match(/^\/t\/[^/]+\/rooms\/[^/]+(?=\/|$)/)?.[0] ??
pathname
);
}