RegistryFrame

tcmts.registry.pages.RegistryFrame · #t4htt3js · term · runs anywhere

The registry's frame: its mark and name, a narrow search, who's signed in, and its two tabs (Libraries is the tab of every page about libraries: one, its code, its changes, a search).

import { RegistryAccount, RegistrySearch, RegistryTabs } from "#codebase/tcmts/registry/pages";
import { at } from "#codebase/tcmts/share";
import type { ReactNode } from "react";

export function RegistryFrame({
  tab,
  title,
  children,
}: {
  tab: string;
  title: string;
  children: ReactNode;
}) {
  return (
    <>
      <title>{`${title} · tcm registry`}</title>
      <header className="app">
        <div className="wrap">
          <div className="bar1">
            <a className="logo" href={at("/")}>
              <span className="mark" aria-hidden="true" />
              tcm registry
            </a>
            <RegistrySearch />
            <RegistryAccount />
          </div>
          <RegistryTabs tab={tab === "code" ? "libraries" : tab} />
        </div>
      </header>
      {children}
    </>
  );
}

uses

used by