Skip to content

Commit

Sign-up buttons say Sign up everywhere; only the sign-up page says registration takes an invite

The landing page, the header, login, a missed page, the invite page, the docs header, settings and support no longer talk about requesting access or being invite-only. The sign-up page (and the GitHub sign-up step that is part of it) still explains invites and the request form. The deploy smoke test checks the landing page by its headline instead.

syntaqxcommitted Parent4bc4681Browse files
11 files+27−440/11 viewed
+1−5
11 ---
22 // The header's right side: where people go from the docs, then the source.
33 import { GitBranch } from '@lucide/astro';
4−
5−// g1t.sh is invite-only for now. A build with PUBLIC_G1T_REGISTRATION=open
6−// (an installation that lets anyone register) says Sign up again.
7−const inviteOnly = (import.meta.env.PUBLIC_G1T_REGISTRATION ?? 'invite') !== 'open';
84 ---
95
106 <nav class="g1t-nav" aria-label="g1t">
117 <a href="https://g1t.sh/">g1t.sh</a>
12− <a href="https://g1t.sh/register" class="g1t-nav-cta">{inviteOnly ? 'Request access' : 'Sign up'}</a>
8+ <a href="https://g1t.sh/register" class="g1t-nav-cta">Sign up</a>
139 <a href="https://g1t.sh/flagon-io/g1t" aria-label="Source on g1t" title="Source on g1t" class="g1t-nav-icon">
1410 <GitBranch />
1511 </a>
+1−1
7171 <section id="invites" className="scroll-mt-20">
7272 <p className="text-sm text-muted">
7373 {overview.mode === "invite"
74− ? "g1t is invite-only for now. Each invite lets one person make an account. "
74+ ? "Each invite lets one person make an account. "
7575 : "Anyone can make an account, but an invite still says who sent it. "}
7676 A revoked or expired invite that was never used comes back to you.
7777 </p>
+7−22
88 import { DeployArt, HeroArt, Live, PlanArt, QueueArt, TeamArt, WhyArt } from "./art";
99 import { ProviderMark } from "./model-providers";
1010 import { ButtonLink, CopyLine } from "./ui";
11−import { HAVE_AN_INVITE } from "../lib/invites";
12−import { useInviteOnly } from "../lib/registration";
1311
1412 const DOCS = "https://docs.g1t.sh";
1513
213211 * It lists no one's repositories; those are a click away under Explore.
214212 */
215213 export function Landing() {
216− const inviteOnly = useInviteOnly();
217214 return (
218215 <main className="overflow-x-clip">
219216 {/* The opening. */}
244241 </p>
245242 <div className="mt-9 flex animate-fade-up flex-wrap items-center justify-center gap-3">
246243 <ButtonLink to="/register" variant="primary" large>
247− {inviteOnly ? "Request access" : "Start for free"}
244+ Start for free
248245 <ArrowRight size={15} />
249246 </ButtonLink>
250− {inviteOnly ? (
251− <ButtonLink to={HAVE_AN_INVITE} variant="quiet" large>
252− Have an invite?
253− </ButtonLink>
254− ) : (
255− <ButtonLink to="#how" variant="quiet" large>
256− See how it works
257− </ButtonLink>
258− )}
247+ <ButtonLink to="#how" variant="quiet" large>
248+ See how it works
249+ </ButtonLink>
259250 </div>
260251 <p className="mx-auto mt-5 max-w-xl animate-fade-up text-sm text-fg-soft/60 text-balance">
261− {inviteOnly
262− ? "g1t is invite-only while we open it up. The forge is free, with no card; agents and checks start with a trial after a card check, and deployments come with the g1t plan."
263− : "The forge is free, with no card. Agents and checks start with a trial after a card check; deployments come with the g1t plan."}
252+ The forge is free, with no card. Agents and checks start with a trial after a card check;
253+ deployments come with the g1t plan.
264254 </p>
265255 </div>
266256 <Live className="relative mx-auto max-w-6xl px-2 pt-6 pb-2 sm:px-4">
626616 </p>
627617 <div className="mt-8 flex flex-wrap justify-center gap-3">
628618 <ButtonLink to="/register" variant="primary" large>
629− {inviteOnly ? "Request access" : "Create your workspace"}
619+ Create your workspace
630620 <ArrowRight size={15} />
631621 </ButtonLink>
632− {inviteOnly && (
633− <ButtonLink to={HAVE_AN_INVITE} variant="quiet" large>
634− Have an invite?
635− </ButtonLink>
636− )}
637622 <ButtonLink to={`${DOCS}/quickstart/`} variant="quiet" large>
638623 Read the quickstart
639624 </ButtonLink>
+2−2
2626 const CODE = "g1t-k7m2-q9xd-4hpw-abcd-0123-4567-89ef-ghjk";
2727
2828 test("while invite-only, nobody is offered a plain sign-up", () => {
29− assert.deepEqual(signUpCopy(true), { primary: "Request access", secondary: "Have an invite?" });
30− assert.deepEqual(signUpCopy(false), { primary: "Sign up", secondary: null });
29+ // Sign up everywhere; only the sign-up page says registration takes an invite.
30+ assert.deepEqual(signUpCopy(), { primary: "Sign up", secondary: null });
3131 assert.equal(HAVE_AN_INVITE, "/register#invite");
3232 });
3333
+7−3
1616 return `mailto:${INVITES_CONTACT}?subject=${encodeURIComponent(subject)}`;
1717 }
1818
19−/** What the sign-up buttons say. While invite-only, nobody can just sign up. */
20−export function signUpCopy(inviteOnly: boolean): { primary: string; secondary: string | null } {
21− return inviteOnly ? { primary: "Request access", secondary: "Have an invite?" } : { primary: "Sign up", secondary: null };
19+/**
20+ * What the sign-up buttons say: Sign up, whether or not registration is
21+ * invite-only. Only the sign-up page itself says how to get in (an invite,
22+ * or a request for one), so nothing else reads as a waiting room.
23+ */
24+export function signUpCopy(): { primary: string; secondary: string | null } {
25+ return { primary: "Sign up", secondary: null };
2226 }
2327
2428 /** The /register address that opens on the invite-code field. */
+2−2
1212 return root?.inviteOnly ?? true;
1313 }
1414
15−/** What the sign-up buttons say on this page. */
15+/** What the sign-up buttons say on this page: Sign up, in every registration mode. */
1616 export function useSignUpCopy() {
17− return signUpCopy(useInviteOnly());
17+ return signUpCopy();
1818 }
+2−2
8585 export async function loader({ context, params, request }: Route.LoaderArgs) {
8686 const user = getViewer(context);
8787 const chosen = readCookie(request.headers.get("cookie"), WORKSPACE_COOKIE);
88− // What sign-up buttons say: Request access while g1t is invite-only.
88+ // Whether sign-up takes an invite: only the sign-up page says so.
8989 const [shell, mode] = await Promise.all([
9090 // An account still confirming its address sees only the pages that
9191 // allows (lib/confirm-gate.ts), in the visitor's frame.
271271 { label: "Sign up", to: "/register", icon: <Plus size={15} /> },
272272 ];
273273
274−/** Sign up, or Request access while g1t is invite-only. */
274+/** Sign up: the sign-up page says whether it takes an invite. */
275275 function SignUpButton() {
276276 const copy = useSignUpCopy();
277277 return <ButtonLink to="/register">{copy.primary}</ButtonLink>;
+2−2
182182 signingUp ? "Make your account below and you get" : "Accepting gives you"
183183 } the ${invite.repository.role} role on ${invite.repository.name}.`;
184184 }
185− return "g1t is where people and agents ship software together: plan in issues, assign work to agents like teammates, and land it through checks that hold. It is invite-only for now; this invite gets you in.";
185+ return "g1t is where people and agents ship software together: plan in issues, assign work to agents like teammates, and land it through checks that hold. This invite gets you in.";
186186 }
187187
188188 /** What accepting is called on its button. */
424424 </div>
425425 )}
426426 <div className="mt-8 flex flex-wrap gap-3">
427− <ButtonLink to="/register#request">Request access</ButtonLink>
427+ <ButtonLink to="/register#request">Sign up</ButtonLink>
428428 <ButtonLink to={loaded.viewer ? "/" : "/login"} variant="quiet">
429429 {loaded.viewer ? "Go to g1t" : "Sign in"}
430430 </ButtonLink>
+1−3
22
33 import type { Route } from "./+types/login";
44 import { page } from "../lib/meta";
5−import { useInviteOnly } from "../lib/registration";
65 import { AuthCard } from "../components/auth-card";
76 import { ContinueWithGithub, GithubMark, OrDivider } from "../components/github";
87 import { PENDING_COOKIE, TWO_FACTOR_COOKIE, TWO_FACTOR_SECONDS, cookie, readCookie } from "../lib/github";
6059 }
6160
6261 export default function Login({ loaderData, actionData }: Route.ComponentProps) {
63− const inviteOnly = useInviteOnly();
6462 const registerUrl =
6563 loaderData.next === "/"
6664 ? "/register"
7371 <>
7472 New to g1t?{" "}
7573 <Link to={registerUrl} className="text-fg underline underline-offset-4">
76− {inviteOnly ? "Request access or use an invite" : "Create an account"}
74+ Create an account
7775 </Link>
7876 </>
7977 }
+1−1
3838 icon: <Ticket size={16} />,
3939 title: "Invites",
4040 address: CONTACT.support,
41− about: "More invites for you or your workspace while g1t is invite-only. Say who you would like to bring.",
41+ about: "More invites for you or your workspace. Say who you would like to bring.",
4242 },
4343 {
4444 icon: <CreditCard size={16} />,
+1−1
1515
1616 /** The checks, in order. `body` is the page's text with tags removed. */
1717 export const CHECKS = [
18− { name: "Landing page", path: "/", expect: ["Request access"] },
18+ { name: "Landing page", path: "/", expect: ["Plan in issues"] },
1919 { name: "Sign in", path: "/login", expect: ["Sign in"] },
2020 {
2121 name: "Sign up: invite and waitlist",