Public: anyone can read this; the crew can change it.

A template's page shows what it will create before the person starts it: its files, its first issue and its crew #15882

Merged opened this

Check · Review · Land · Live done — Landed and live in production.

Merged

scout/forge:scout/15855-a-template-s-page-shows-what-it-will-cre → main 0 commits fork 3 threads · 3 unresolved

  • Merged. scout/15855-a-template-s-page-shows-what-it-will-cre was merged into main as 7dd6091.

Review

Sign in to review this change.
10 files changed +212 −38
docs/features/template-page.md +4 −2
@@ -4,6 +4,8 @@ row: Template page
44 ---
55 # Template page
66
7 `/templates/owner/name` shows what a forge started from that template gets, read-only from its repository: the top-level file names (folders end in `/`) and the README's first paragraph, escaped. `/templates/blank` and `/templates/starter` show the built-in templates' own words. A repository that does not exist, is not marked a template, or that the viewer cannot read answers the same 404. Settings → App templates links each row to its page.
7 `/templates/owner/name` shows what a forge started from that template gets, read-only from its repository: the README's first paragraph (escaped), then **Files it will create** (every path, sorted, the first 30 with "and N more"), **First issue** (the `firstAsk` its forge.json declares, or "None: you tell the crew what to build") and **Crew seats** (the starter seats a new forge fills, from `src/spawn/starter_crew.ts`). `/templates/starter` lists the files it bakes. `/templates/blank` and `/templates/starter` show the built-in templates' own words. A repository that does not exist, is not marked a template, or that the viewer cannot read answers the same 404. Settings → App templates links each row to its page.
88
9 Code: `src/web/pages/template.ts`, `src/core/template_view.ts`, `src/core/readme_paragraph.ts`. Test: `test/template-page.test.ts`.
9 In the terminal, `p` on a row of Templates (`/templates` screen) opens the same three parts: files, first issue, crew seats, `j`/`k` scroll. Blank has no page, so `p` does nothing on it.
10
11 Code: `src/web/pages/template.ts`, `src/tui/screens/template_preview.ts`, `src/core/template_view.ts`, `src/core/readme_paragraph.ts`. Tests: `test/template-page.test.ts`, `test/template-preview.test.ts`, `test/template-preview-tui.test.ts`.
scripts/feature-doors-allow.json −1
@@ -11,7 +11,6 @@
1111 "docs/features/speak.md",
1212 "docs/features/stranger-pulls.md",
1313 "docs/features/talk-resume-writes.md",
14 "docs/features/template-page.md",
1514 "docs/features/template-timing.md",
1615 "docs/features/thread-fold.md",
1716 "docs/features/wave-standing.md",
src/core/template_view.ts +25 −10
@@ -1,48 +1,63 @@
11 /**
22 * What a template starts a forge with (#13407), read-only from its repository: the one reading the
3 * page shows, behind one gate. A repository that is missing,
3 * page and the terminal screen show, behind one gate. A repository that is missing,
44 * not marked a template or not readable by the viewer is `undefined` (the same not-found for all).
55 */
66
77 import type { App } from "../app.ts";
88 import { readFileAt } from "../apps/checkout.ts";
99 import { firstAskOf } from "../apps/first_ask.ts";
10 import { blobForRender, listTree, refTip } from "../git/read.ts";
10 import { bakedFiles } from "../apps/template.ts";
11 import { blobForRender, listPaths, refTip } from "../git/read.ts";
1112 import { repoDir } from "../git/repos.ts";
13 import { STARTER_SEATS } from "../spawn/starter_crew.ts";
1214 import { repoTemplateRef, TEMPLATES } from "../spawn/templates.ts";
1315 import type { User } from "./users.ts";
1416 import { readmeParagraph } from "./readme_paragraph.ts";
1517 import { canRead, getRepo } from "./repos.ts";
1618
1719 const README_BYTES = 16 * 1024;
18 const FILES_MAX = 200;
1920
2021 export type TemplateView = {
2122 readonly title: string;
2223 readonly about: string;
23 /** Top-level names; a folder ends in `/`. Empty for a built-in template. */
24 readonly files: readonly string[];
2524 /** The valid `firstAsk` its forge.json declares, if any. */
2625 readonly firstAsk?: string;
26 /** The first {@link PATHS_MAX} file paths it will create, in order. */
27 readonly paths: readonly string[];
28 /** How many more paths there are beyond `paths`. */
29 readonly morePaths: number;
30 /** The seats a new forge fills: `name: role`, one per starter seat. */
31 readonly seats: readonly string[];
2732 };
2833
outdated

The comment says builder (builder) style but SEATS builds name: role. Fix the comment. Also files above is no longer read by the page; remove it and its top-level listTree read.

34 export const PATHS_MAX = 30;
35 const SEATS: readonly string[] = STARTER_SEATS.map((s) => `${s.name}: ${s.role}`);
36
37 function capped(all: readonly string[]): { paths: string[]; morePaths: number } {
38 return { paths: all.slice(0, PATHS_MAX), morePaths: Math.max(0, all.length - PATHS_MAX) };
39 }
40
2941 /** A built-in template by id, or a marked repository by `owner/name`. */
3042 export async function templateView(app: App, viewer: User | undefined, ref: string): Promise<TemplateView | undefined> {
3143 const built = TEMPLATES.find((t) => t.id === ref);
32 if (built) return { title: built.title, about: built.says, files: [] };
44 if (built) {
45 const all = built.id === "starter" ? bakedFiles({ name: "app", description: "" }).map((f) => f.path).sort() : [];
46 return { title: built.title, about: built.says, ...capped(all), seats: SEATS };
47 }
3348 if (repoTemplateRef(ref) === undefined) return undefined;
3449 const [owner = "", name = ""] = ref.split("/");
3550 const repo = getRepo(app.db, owner, name);
3651 if (!repo || !repo.template || !canRead(app.db, repo, viewer)) return undefined;
3752 const dir = repoDir(app.reposRoot, repo.ownerName, repo.name);
38 let files: string[] = [];
3953 let about = "";
4054 let firstAsk: string | undefined;
55 let all: string[] = [];
4156 try {
4257 const tip = await refTip(dir, `refs/heads/${repo.defaultBranch}`);
4358 if (tip !== undefined) {
44 const tree = await listTree(dir, tip, "");
45 if (tree.ok) files = tree.value.slice(0, FILES_MAX).map((e) => (e.type === "tree" ? `${e.name}/` : e.name));
59 const listed = await listPaths(dir, tip);
60 if (listed.ok) all = listed.value.paths.slice().sort();
4661 const blob = await blobForRender(dir, tip, "README.md", README_BYTES);
4762 if (blob.kind === "text") about = readmeParagraph(new TextDecoder().decode(blob.body));
4863 firstAsk = firstAskOf(await readFileAt(dir, tip, "forge.json"));
@@ -50,5 +65,5 @@ export async function templateView(app: App, viewer: User | undefined, ref: stri
5065 } catch {
5166 // an unreadable repository shows what it can: the name and nothing else
5267 }
53 return { title: `${repo.ownerName}/${repo.name}`, about, files, ...(firstAsk === undefined ? {} : { firstAsk }) };
68 return { title: `${repo.ownerName}/${repo.name}`, about, ...capped(all), seats: SEATS, ...(firstAsk === undefined ? {} : { firstAsk }) };
5469 }
src/tui/screens/template_preview.ts added +60
@@ -0,0 +1,60 @@
1 /**
2 * A template's page in the terminal (#15855): the files a forge started from it will create, its
3 * first issue and the crew seats it fills, from the page's own reading (`templateView`). Read-only;
4 * opened with `p` on a row of /templates.
5 */
6
7 import { templateView, type TemplateView } from "../../core/template_view.ts";
8 import type { Ctx, Screen } from "../app/app.ts";
9 import { binding } from "../app/keys.ts";
10 import type { Session } from "../session.ts";
11 import { style } from "../term/style.ts";
12 import { truncate } from "../term/width.ts";
13
14 /** The lines the screen shows, from the page's reading: one list for every width. */
15 export function previewLines(v: TemplateView): string[] {
16 return [
17 ...(v.about === "" ? [] : [v.about, ""]),
18 ...(v.paths.length === 0 ? [] : ["Files it will create", ...v.paths.map((p) => ` ${p}`), ...(v.morePaths > 0 ? [` and ${v.morePaths} more`] : []), ""]),
19 "First issue",
20 ` ${v.firstAsk === undefined ? "None: you tell the crew what to build." : v.firstAsk.replace(/\s+/g, " ")}`,
21 "",
22 "Crew seats",
23 ...v.seats.map((s) => ` ${s}`),
24 ];
25 }
26
27 export function templatePreviewScreen(f: Session, ctx: Ctx, ref: string): Screen {
28 let view: TemplateView | undefined;
29 let gone = false;
30 let at = 0;
31 return {
32 title: `Template ${ref}`,
33 keys: [binding(["j", "k"], "scroll"), binding(["esc"], "back")],
34 async load(signal) {
35 const v = await templateView(f.app, f.user, ref);
36 if (signal.aborted) return;
37 view = v;
38 gone = v === undefined;
39 ctx.invalidate();
40 },
41 render(area, s) {
42 const c = ctx.theme.c;
43 const lines = view === undefined ? [gone ? "No such template." : "Reading…"] : previewLines(view);
44 at = Math.min(at, Math.max(0, lines.length - area.h));
45 lines.slice(at, at + area.h).forEach((l, i) => {
46 const head = !l.startsWith(" ") && l !== "" && view !== undefined && (l === "First issue" || l === "Crew seats" || l === "Files it will create");
47 s.text(area.x + 1, area.y + i, truncate(l, area.w - 2), style(head ? c.fg : c.mutedFg, c.bg), area.x + area.w);
48 });
49 },
50 key(e) {
51 if (e.ctrl || e.alt) return false;
52 if (e.key === "esc" || e.key === "q") ctx.pop();
53 else if (e.key === "j" || e.key === "down") at += 1;
54 else if (e.key === "k" || e.key === "up") at = Math.max(0, at - 1);
55 else return false;
56 ctx.invalidate();
57 return true;
58 },
59 };
60 }
src/tui/screens/templates.ts +6 −2
@@ -17,6 +17,7 @@ import { templateUse, useWords } from "../../spawn/template_use.ts";
1717 import { NO_CHANGES_YET, templateRecency } from "../../spawn/template_recent.ts";
1818 import { timeAgo } from "../../web/time_element.ts";
1919 import { newForgeScreen } from "./newforge.ts";
20 import { templatePreviewScreen } from "./template_preview.ts";
2021
2122 /** `updated 3d ago`, in the shared clock's words, or that nothing has landed. */
2223 const recencyLine = (at: string | undefined): string => (at === undefined ? NO_CHANGES_YET : `updated ${timeAgo(at)}`);
@@ -37,7 +38,7 @@ export function templatesScreen(session: Session, ctx: Ctx): Screen {
3738 const rows = () => filterTemplates(listed, q);
3839 return {
3940 title: "Templates",
40 keys: [binding(["j", "k"], "move"), ...(session.user === undefined ? [] : [binding(["enter"], "start a forge from it")]), binding(["/"], "filter by name or description"), binding(["esc"], "back")],
41 keys: [binding(["j", "k"], "move"), ...(session.user === undefined ? [] : [binding(["enter"], "start a forge from it")]), binding(["p"], "what it will create"), binding(["/"], "filter by name or description"), binding(["esc"], "back")],
4142 render(area, s) {
4243 const c = ctx.theme.c;
4344 const list = rows();
@@ -77,7 +78,10 @@ export function templatesScreen(session: Session, ctx: Ctx): Screen {
7778 if (e.key === "esc" || e.key === "q") ctx.pop();
7879 else if (e.key === "j" || e.key === "down") at = Math.min(Math.max(0, rows().length - 1), at + 1);
7980 else if (e.key === "k" || e.key === "up") at = Math.max(0, at - 1);
80 else if (e.key === "enter" && session.user !== undefined) {
81 else if (e.key === "p") {
82 const row = rows()[at];
83 if (row !== undefined && row.id !== DEFAULT_TEMPLATE) ctx.push(templatePreviewScreen(session, ctx, row.id));
84 } else if (e.key === "enter" && session.user !== undefined) {
8185 const row = rows()[at];
8286 if (row !== undefined) ctx.push(newForgeScreen(session, ctx, { template: row.id }));
8387 } else return false;
src/web/pages/template.ts +13 −13
@@ -1,10 +1,10 @@
11 /**
22 * A template's page (#13407): what a forge started from it begins with, read-only from its
3 * repository: the top-level file names and the README's first paragraph. A built-in template shows
4 * its own words. A repository that is missing, not marked a template or not readable by the viewer
5 * is the same 404 (`core/template_view.ts`). When a forge has been made from it, one line says how
6 * long the last took to its first live answer, read from stored events
7 * (`actions/template_timing.ts`).
3 * repository: the README's first paragraph, the files it will create, its first issue and the crew
4 * seats. A built-in template shows its own words. A repository that is missing, not marked a
5 * template or not readable by the viewer is the same 404 (`core/template_view.ts`). When a forge
6 * has been made from it, one line says how long the last took to its first live answer, read from
7 * stored events (`actions/template_timing.ts`).
88 */
99
1010 import { templateTimingLine } from "../../actions/template_timing.ts";
@@ -42,16 +42,16 @@ export async function templatePage(ctx: Ctx): Promise<Response> {
4242 ...(shared !== undefined ? { ogImage: `/og/template/${templateCardRef(ref)}.png` } : {}),
4343 body: html`${pageHead(view.title, { sub: view.about !== "" ? view.about : "The files a forge starts with." })}
4444 <section>
45 ${view.firstAsk === undefined ? null : html`<p id="template-first-ask"><span class="muted">A new forge opens with this ask:</span> <q>${view.firstAsk}</q></p>`}
4645 ${row ? html`<p>${btn("Start a forge", { variant: "primary", href: `/forges/new?template=${encodeURIComponent(ref)}` })}</p>` : null}
outdated

Principle 1: this line and the First issue section below say the same ask twice. Keep one: drop this paragraph and let the section carry it.

47 ${built ? null : html`<p>A forge started from this template begins with these files.</p>`}
48 ${built
46 ${view.paths.length === 0
4947 ? null
50 : view.files.length === 0
51 ? html`<p class="muted">No files yet.</p>`
52 : html`<dl class="status-rows">${view.files.map((f) =>
53 statusRow(f, html`${f.endsWith("/") ? "folder" : "file"}`),
54 )}</dl>`}
48 : html`<h2>Files it will create</h2>
49 <dl class="status-rows" id="template-paths">${view.paths.map((f) => statusRow(f, html`file`))}</dl>
50 ${view.morePaths > 0 ? html`<p class="small muted">and ${view.morePaths} more</p>` : null}`}
51 <h2>First issue</h2>
52 <p id="template-first-issue">${view.firstAsk === undefined ? html`<span class="muted">None: you tell the crew what to build.</span>` : html`<q>${view.firstAsk}</q>`}</p>
53 <h2>Crew seats</h2>
54 <dl class="status-rows" id="template-seats">${view.seats.map((s) => statusRow(s, html`seat`))}</dl>
5555 ${line === null ? null : html`<p class="small muted" id="template-timing">${line}</p>`}
5656 ${built ? null : html`<p class="muted"><a href="/${view.title}">Open the repository</a></p>`}
5757 </section>`,
test/feature-doors.test.ts +1 −1
@@ -29,7 +29,7 @@ test("a listed how-to that gained its terminal file fails: prune the list", () =
2929 /**
3030 * Lower this when the list shrinks; raising it is adding a page-only how-to, which review refuses.
3131 */
32 const CEILING = 19;
32 const CEILING = 18;
3333
3434 test("the allow list cannot gain a how-to", () => {
3535 expect(allowed.length, "the list only shrinks: name the terminal door in the how-to instead of listing it").toBeLessThanOrEqual(CEILING);
test/template-page.test.ts +27 −9
@@ -1,6 +1,6 @@
11 /**
2 * A template's page lists its top-level files and the README's first paragraph, escaped; unreadable
3 * is 404.
2 * A template's page lists its files, first issue, seats and the README's first paragraph, escaped;
3 * unreadable is 404.
44 */
55 import { afterAll, beforeAll, expect, setDefaultTimeout, test } from "bun:test";
66 import { mkdtemp, rm } from "node:fs/promises";
@@ -42,6 +42,9 @@ beforeAll(async () => {
4242 const forgeJsons: Record<string, string> = {
4343 asky: JSON.stringify({ app: { run: "bun main.ts" }, firstAsk: "Add a <b>weekly</b> menu page" }),
4444 };
45 const extra: Record<string, { path: string; content: string }[]> = {
46 big: Array.from({ length: 35 }, (_, i) => ({ path: `docs/n${String(i).padStart(2, "0")}.md`, content: "x" })),
47 };
4548 const make = async (name: string, visibility: "public" | "private", template: boolean) => {
4649 const repo = await createRepo(app, owner, { name, visibility, description: "" });
4750 if (!repo.ok) throw new Error(repo.error);
@@ -52,6 +55,7 @@ beforeAll(async () => {
5255 { path: "forge.json", content: forgeJsons[name] ?? '{"app":{"run":"bun main.ts"}}' },
5356 { path: "server.ts", content: "x" },
5457 { path: "src/a.ts", content: "x" },
58 ...(extra[name] ?? []),
5559 ],
5660 });
5761 if (!done.ok) throw new Error(String(done.error));
@@ -62,6 +66,7 @@ beforeAll(async () => {
6266 };
6367 await make("kit", "public", true);
6468 await make("asky", "public", true);
69 await make("big", "public", true);
6570 await make("badask", "public", true);
6671 // marked while valid, then changed to a value the check would refuse: the page ignores it
6772 const bad = await commitToBranch(app, owner, getRepo(app.db, "giver", "badask")!, {
@@ -88,14 +93,14 @@ afterAll(async () => {
8893
8994 const get = (path: string, cookie = "") => fetch(`${base}${path}`, { headers: { cookie } });
9095
91 test("a public template lists its top-level files and the README's first paragraph, escaped", async () => {
96 test("a public template lists its files and the README's first paragraph, escaped", async () => {
9297 const res = await get("/templates/giver/kit");
9398 expect(res.status).toBe(200);
9499 const body = await res.text();
95100 expect(body).toContain("server.ts");
96101 expect(body).toContain("src/");
97102 expect(body).toContain("README.md");
98 expect(body).not.toContain("a.ts");
103 expect(body).toContain("src/a.ts"); // the tree is listed in full since #15855
99104 expect(body).toContain("&lt;script&gt;alert(1)&lt;/script&gt; starter. Second line.");
100105 expect(body).not.toContain("<script>alert(1)");
101106 expect(body).not.toContain("Not this.");
@@ -130,11 +135,24 @@ test("readmeParagraph skips the heading and fences and stops at the blank line",
130135 expect(readmeParagraph("")).toBe("");
131136 });
132137
133 test("a template that declares a first ask shows it, escaped; none declared or invalid shows nothing", async () => {
138 test("a template that declares a first ask shows it once, under First issue, escaped; none declared says so", async () => {
134139 const shown = await (await get("/templates/giver/asky")).text();
135 expect(shown).toContain('id="template-first-ask"');
136 expect(shown).toContain("Add a &lt;b&gt;weekly&lt;/b&gt; menu page");
140 const issue = shown.split('id="template-first-issue"')[1]!.split("</p>")[0]!;
141 expect(issue).toContain("Add a &lt;b&gt;weekly&lt;/b&gt; menu page");
137142 expect(shown).not.toContain("<b>weekly");
138 expect(await (await get("/templates/giver/kit")).text()).not.toContain("template-first-ask");
139 expect(await (await get("/templates/giver/badask")).text()).not.toContain("template-first-ask");
143 expect(shown.split("menu page").length - 1).toBe(1);
144 expect(shown).not.toContain("template-first-ask");
145 for (const none of ["kit", "badask"]) {
146 const text = await (await get(`/templates/giver/${none}`)).text();
147 expect(text.split('id="template-first-issue"')[1]!.split("</p>")[0]!).toContain("None: you tell the crew what to build.");
148 }
149 });
150
151 test("past 30 paths the page lists 30 and says how many more", async () => {
152 const text = await (await get("/templates/giver/big")).text();
153 const paths = text.split('id="template-paths"')[1]!.split("</dl>")[0]!;
154 expect((paths.match(/status-row"/g) ?? []).length).toBe(30);
155 // 35 docs + README.md, forge.json, server.ts, src/a.ts
156 expect(text).toContain("and 9 more");
157 expect((await (await get("/templates/giver/kit")).text())).not.toContain(" more</p>");
140158 });
test/template-preview-tui.test.ts added +63
@@ -0,0 +1,63 @@
1 /**
2 * A template's page in the terminal: `p` on a /templates row shows the files it will create, its
3 * first issue and the crew seats, the lines the page shows.
4 */
5 import { afterAll, beforeAll, expect, test } from "bun:test";
6 import { mkdtemp, rm } from "node:fs/promises";
7 import { tmpdir } from "node:os";
8 import { join } from "node:path";
9 import { createApp, type App } from "../src/app.ts";
10 import { PATHS_MAX, templateView } from "../src/core/template_view.ts";
11 import { createForgeApp } from "../src/tui/forge.ts";
12 import { previewLines } from "../src/tui/screens/template_preview.ts";
13 import { templatesScreen } from "../src/tui/screens/templates.ts";
14 import { headlessTerminal } from "../src/tui/term/terminal.ts";
15 import { settleApp } from "./helpers/tui.ts";
16
17 let dir: string;
18 let app: App;
19 beforeAll(async () => {
20 dir = await mkdtemp(join(tmpdir(), "forge-template-preview-tui-"));
21 app = createApp({ dataDir: dir, port: 0 });
22 });
23 afterAll(async () => {
24 app.close();
25 await rm(dir, { recursive: true, force: true });
26 });
27
28 const key = (k: string) => ({ type: "key" as const, key: k, ctrl: false, alt: false, shift: false });
29
30 test("p on Starter shows its files, first issue and crew seats; the blank row has no page", async () => {
31 const { app: tui, session } = createForgeApp(
32 app,
33 { sshUsername: "guest", remoteAddress: "127.0.0.1", fingerprint: "SHA256:test" },
34 { terminal: headlessTerminal(120, 60), exitHooks: false },
35 );
36 tui.start();
37 const list = templatesScreen(session, tui.ctx);
38 tui.ctx.push(list);
39 await settleApp(tui);
40 list.key?.(key("p")); // blank is first: nothing to open
41 await settleApp(tui);
42 expect(tui.screen.toText()).not.toContain("First issue");
43 list.key?.(key("j"));
44 list.key?.(key("p"));
45 await settleApp(tui);
46 const text = tui.screen.toText();
47 expect(text).toContain("Files it will create");
48 expect(text).toContain("forge.json");
49 expect(text).toContain("First issue");
50 expect(text).toContain("None: you tell the crew what to build.");
51 expect(text).toContain("Crew seats");
52 expect(text).toContain("builder");
53 expect(text).toContain("reviewer");
54 });
55
56 test("the lines carry the ask once and say how many paths are not shown", async () => {
57 const v = await templateView(app, undefined, "starter");
58 if (v === undefined) throw new Error("no view");
59 const lines = previewLines({ ...v, firstAsk: "Add a menu", morePaths: 9 });
60 expect(lines.filter((l) => l.includes("Add a menu"))).toHaveLength(1);
61 expect(lines).toContain(" and 9 more");
62 expect(v.paths.length).toBeLessThanOrEqual(PATHS_MAX);
63 });
test/template-preview.test.ts +13
@@ -53,3 +53,16 @@ test("a repository template with nothing to read has no preview", () => {
5353 expect(String(previewLink("alice/full", "Full", { files: ["a"], more: 0, run: undefined, check: undefined }))).toContain('href="/templates/alice/full"');
5454 expect(String(previewLink("alice/full", "Full", { files: ["a"], more: 0, run: undefined, check: undefined }))).toContain('aria-label="Preview Full"');
5555 });
56
57 test("a template's page lists its files, first issue and seats", async () => {
58 const text = await (await fetch(`${servers.url}/templates/starter`)).text();
59 const paths = text.split('id="template-paths"')[1]!.split("</dl>")[0]!;
60 expect(paths).toContain("<dt>forge.json</dt>");
61 expect((paths.match(/status-row"/g) ?? []).length).toBeLessThanOrEqual(30);
62 expect(text).toContain('id="template-first-issue"');

This passes for any page since the id is always rendered. Add a repository template with a firstAsk and assert the ask sits inside template-first-issue, plus a tree over 30 paths asserting 'and N more'. Also add the terminal screen and a test for it.

63 const seats = text.split('id="template-seats"')[1]!.split("</dl>")[0]!;
64 expect(seats).toContain("builder");
65 expect(seats).toContain("reviewer");
66 expect((await fetch(`${servers.url}/templates/nope`)).status).toBe(404);
67 expect(text).toContain("/forges/new?template=starter");
68 });

↑↓ navigate ↵ open ⌘↵ its app esc close

Keyboard shortcuts

Docs