ref0-git 0.0.0 → 0.3.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/app/apps/github/.dev.vars.example +6 -0
- package/app/apps/github/README.md +70 -0
- package/app/apps/github/THIRD_PARTY_NOTICES.md +214 -0
- package/app/apps/github/components.json +25 -0
- package/app/apps/github/generated/git-rest.ts +10444 -0
- package/app/apps/github/generated/routeTree.gen.ts +1242 -0
- package/app/apps/github/migrations/postgres/0001_auth.sql +46 -0
- package/app/apps/github/migrations/sql/0001_auth.sql +19 -0
- package/app/apps/github/migrations/sql/0002_passkeys.sql +9 -0
- package/app/apps/github/migrations/sql/0003_orgs.sql +22 -0
- package/app/apps/github/migrations/sql/0004_avatars.sql +6 -0
- package/app/apps/github/package.json +80 -0
- package/app/apps/github/src/branches/branch-list.tsx +385 -0
- package/app/apps/github/src/branches/branches.ts +55 -0
- package/app/apps/github/src/clients/allowed.ts +213 -0
- package/app/apps/github/src/clients/at-most.ts +17 -0
- package/app/apps/github/src/clients/avatars.ts +410 -0
- package/app/apps/github/src/clients/cached.ts +65 -0
- package/app/apps/github/src/clients/calls.ts +160 -0
- package/app/apps/github/src/clients/clients.ts +82 -0
- package/app/apps/github/src/clients/graphql.ts +50 -0
- package/app/apps/github/src/clients/host-answer.ts +28 -0
- package/app/apps/github/src/clients/host-calls.ts +382 -0
- package/app/apps/github/src/clients/icon-bytes.ts +203 -0
- package/app/apps/github/src/clients/proxy.ts +59 -0
- package/app/apps/github/src/clients/session-ended.ts +18 -0
- package/app/apps/github/src/clients/transfers.ts +212 -0
- package/app/apps/github/src/code/breadcrumbs.tsx +50 -0
- package/app/apps/github/src/code/code-page.tsx +147 -0
- package/app/apps/github/src/code/code-tree.tsx +338 -0
- package/app/apps/github/src/code/controls.tsx +230 -0
- package/app/apps/github/src/code/file-view.tsx +450 -0
- package/app/apps/github/src/code/files.ts +332 -0
- package/app/apps/github/src/code/folder-list.tsx +122 -0
- package/app/apps/github/src/code/go-to-file.tsx +131 -0
- package/app/apps/github/src/code/highlighted.tsx +58 -0
- package/app/apps/github/src/code/lines.ts +46 -0
- package/app/apps/github/src/code/load.ts +147 -0
- package/app/apps/github/src/code/markdown-files.ts +58 -0
- package/app/apps/github/src/code/places.ts +88 -0
- package/app/apps/github/src/code/ref-pages.ts +179 -0
- package/app/apps/github/src/code/ref-switcher.tsx +203 -0
- package/app/apps/github/src/code/refs.ts +142 -0
- package/app/apps/github/src/code/repo-home.tsx +240 -0
- package/app/apps/github/src/code/repo.ts +105 -0
- package/app/apps/github/src/code/saved-reads.ts +199 -0
- package/app/apps/github/src/code/saved.ts +110 -0
- package/app/apps/github/src/code/tree-fold.ts +186 -0
- package/app/apps/github/src/code/trees.ts +136 -0
- package/app/apps/github/src/components/avatar-picture.ts +53 -0
- package/app/apps/github/src/components/avatar-url.ts +16 -0
- package/app/apps/github/src/components/confirm-action.tsx +100 -0
- package/app/apps/github/src/components/count.tsx +24 -0
- package/app/apps/github/src/components/create-button.tsx +38 -0
- package/app/apps/github/src/components/file-icons/file-icons.css +225 -0
- package/app/apps/github/src/components/file-icons/file-icons.tsx +138 -0
- package/app/apps/github/src/components/filter.tsx +35 -0
- package/app/apps/github/src/components/hotkeys/hotkeys.tsx +255 -0
- package/app/apps/github/src/components/item-list.tsx +65 -0
- package/app/apps/github/src/components/language-dot.tsx +29 -0
- package/app/apps/github/src/components/list-toolbar.tsx +82 -0
- package/app/apps/github/src/components/markdown/editor.tsx +57 -0
- package/app/apps/github/src/components/markdown/markdown.css +177 -0
- package/app/apps/github/src/components/markdown/markdown.tsx +82 -0
- package/app/apps/github/src/components/owner-card.tsx +196 -0
- package/app/apps/github/src/components/pull-status.tsx +34 -0
- package/app/apps/github/src/components/recent.ts +41 -0
- package/app/apps/github/src/components/relative-time.tsx +78 -0
- package/app/apps/github/src/components/repos/icon-hashes.ts +91 -0
- package/app/apps/github/src/components/repos/new-repo-form.tsx +196 -0
- package/app/apps/github/src/components/repos/repo-icon.tsx +47 -0
- package/app/apps/github/src/components/repos/repo-list.tsx +528 -0
- package/app/apps/github/src/components/repos/your-repos.tsx +124 -0
- package/app/apps/github/src/components/review-state.tsx +75 -0
- package/app/apps/github/src/components/route-dialog.tsx +137 -0
- package/app/apps/github/src/components/save-button.tsx +58 -0
- package/app/apps/github/src/components/shell/app-shell.tsx +164 -0
- package/app/apps/github/src/components/shell/create-org-dialog.tsx +118 -0
- package/app/apps/github/src/components/shell/create-row.tsx +49 -0
- package/app/apps/github/src/components/shell/link-menu.tsx +94 -0
- package/app/apps/github/src/components/shell/nav-user.tsx +97 -0
- package/app/apps/github/src/components/shell/owner-repos.tsx +247 -0
- package/app/apps/github/src/components/shell/owner-switcher.tsx +104 -0
- package/app/apps/github/src/components/shell/repo-switcher.tsx +179 -0
- package/app/apps/github/src/components/shell/sections.ts +31 -0
- package/app/apps/github/src/components/shell/submenu-chevron.ts +147 -0
- package/app/apps/github/src/components/signin/device-card.tsx +139 -0
- package/app/apps/github/src/components/signin/login-form.tsx +88 -0
- package/app/apps/github/src/components/signin/signin-page.tsx +33 -0
- package/app/apps/github/src/components/signin/signup-form.tsx +106 -0
- package/app/apps/github/src/components/states/live-status.tsx +42 -0
- package/app/apps/github/src/components/states/states.tsx +126 -0
- package/app/apps/github/src/components/tab-indicator.tsx +143 -0
- package/app/apps/github/src/components/theme-choice.tsx +108 -0
- package/app/apps/github/src/components/theme-provider.tsx +126 -0
- package/app/apps/github/src/components/tones.ts +23 -0
- package/app/apps/github/src/components/ui/alert-dialog.tsx +187 -0
- package/app/apps/github/src/components/ui/alert.tsx +78 -0
- package/app/apps/github/src/components/ui/avatar.tsx +106 -0
- package/app/apps/github/src/components/ui/badge.tsx +51 -0
- package/app/apps/github/src/components/ui/breadcrumb.tsx +124 -0
- package/app/apps/github/src/components/ui/button-group.tsx +87 -0
- package/app/apps/github/src/components/ui/button.tsx +61 -0
- package/app/apps/github/src/components/ui/calendar.tsx +221 -0
- package/app/apps/github/src/components/ui/card.tsx +102 -0
- package/app/apps/github/src/components/ui/checkbox.tsx +26 -0
- package/app/apps/github/src/components/ui/collapsible.tsx +19 -0
- package/app/apps/github/src/components/ui/combobox.tsx +304 -0
- package/app/apps/github/src/components/ui/command.tsx +208 -0
- package/app/apps/github/src/components/ui/dialog.tsx +156 -0
- package/app/apps/github/src/components/ui/dropdown-menu.tsx +290 -0
- package/app/apps/github/src/components/ui/empty.tsx +100 -0
- package/app/apps/github/src/components/ui/field.tsx +236 -0
- package/app/apps/github/src/components/ui/hover-card.tsx +48 -0
- package/app/apps/github/src/components/ui/input-group.tsx +163 -0
- package/app/apps/github/src/components/ui/input.tsx +19 -0
- package/app/apps/github/src/components/ui/item.tsx +201 -0
- package/app/apps/github/src/components/ui/kbd.tsx +27 -0
- package/app/apps/github/src/components/ui/label.tsx +33 -0
- package/app/apps/github/src/components/ui/popover.tsx +87 -0
- package/app/apps/github/src/components/ui/radio-group.tsx +35 -0
- package/app/apps/github/src/components/ui/select.tsx +198 -0
- package/app/apps/github/src/components/ui/separator.tsx +22 -0
- package/app/apps/github/src/components/ui/sheet.tsx +138 -0
- package/app/apps/github/src/components/ui/sidebar.tsx +724 -0
- package/app/apps/github/src/components/ui/skeleton.tsx +13 -0
- package/app/apps/github/src/components/ui/sonner.tsx +47 -0
- package/app/apps/github/src/components/ui/styles.css +242 -0
- package/app/apps/github/src/components/ui/table.tsx +113 -0
- package/app/apps/github/src/components/ui/tabs.tsx +79 -0
- package/app/apps/github/src/components/ui/textarea.tsx +17 -0
- package/app/apps/github/src/components/ui/title.ts +6 -0
- package/app/apps/github/src/components/ui/toggle-group.tsx +89 -0
- package/app/apps/github/src/components/ui/toggle.tsx +42 -0
- package/app/apps/github/src/components/ui/tooltip.tsx +63 -0
- package/app/apps/github/src/components/user-avatar.tsx +145 -0
- package/app/apps/github/src/components/view-tabs.tsx +42 -0
- package/app/apps/github/src/context/context.ts +133 -0
- package/app/apps/github/src/diffs/blobs.ts +94 -0
- package/app/apps/github/src/diffs/diff-view.tsx +155 -0
- package/app/apps/github/src/diffs/files.ts +121 -0
- package/app/apps/github/src/diffs/hunks.tsx +454 -0
- package/app/apps/github/src/diffs/patch.ts +131 -0
- package/app/apps/github/src/diffs/rows.ts +137 -0
- package/app/apps/github/src/history/commit-diff.ts +54 -0
- package/app/apps/github/src/history/commit-list.tsx +207 -0
- package/app/apps/github/src/history/commit-page.tsx +147 -0
- package/app/apps/github/src/history/history.ts +129 -0
- package/app/apps/github/src/hooks/allowed.ts +31 -0
- package/app/apps/github/src/hooks/answers.ts +65 -0
- package/app/apps/github/src/hooks/avatars.ts +54 -0
- package/app/apps/github/src/hooks/draft.ts +38 -0
- package/app/apps/github/src/hooks/open-counts.ts +127 -0
- package/app/apps/github/src/hooks/profiles.ts +120 -0
- package/app/apps/github/src/hooks/repos.ts +440 -0
- package/app/apps/github/src/hooks/use-mobile.ts +19 -0
- package/app/apps/github/src/hooks/viewer.ts +39 -0
- package/app/apps/github/src/inbox/count.ts +70 -0
- package/app/apps/github/src/inbox/inbox-item.tsx +66 -0
- package/app/apps/github/src/inbox/inbox-page.tsx +572 -0
- package/app/apps/github/src/inbox/marks.ts +130 -0
- package/app/apps/github/src/inbox/release-tags.ts +65 -0
- package/app/apps/github/src/inbox/search.ts +97 -0
- package/app/apps/github/src/inbox/subjects.ts +184 -0
- package/app/apps/github/src/inbox/subscription-controls.tsx +184 -0
- package/app/apps/github/src/inbox/subscriptions.ts +189 -0
- package/app/apps/github/src/inbox/threads.ts +198 -0
- package/app/apps/github/src/issues/changes.ts +332 -0
- package/app/apps/github/src/issues/counts.ts +62 -0
- package/app/apps/github/src/issues/issue-list.tsx +682 -0
- package/app/apps/github/src/issues/issue-page.tsx +533 -0
- package/app/apps/github/src/issues/issues.ts +566 -0
- package/app/apps/github/src/issues/label-dialog.tsx +310 -0
- package/app/apps/github/src/issues/labels-page.tsx +119 -0
- package/app/apps/github/src/issues/new-issue.tsx +79 -0
- package/app/apps/github/src/issues/parts.tsx +71 -0
- package/app/apps/github/src/issues/picker.tsx +298 -0
- package/app/apps/github/src/issues/search.ts +238 -0
- package/app/apps/github/src/issues/sidebar.tsx +236 -0
- package/app/apps/github/src/lib/cn.ts +8 -0
- package/app/apps/github/src/lib/highlighting.ts +13 -0
- package/app/apps/github/src/live/follow.ts +129 -0
- package/app/apps/github/src/live/sse.ts +74 -0
- package/app/apps/github/src/live/use-follow.ts +37 -0
- package/app/apps/github/src/markdown/README.md +53 -0
- package/app/apps/github/src/markdown/allowed-html.ts +69 -0
- package/app/apps/github/src/markdown/context.ts +206 -0
- package/app/apps/github/src/markdown/images.ts +81 -0
- package/app/apps/github/src/markdown/lookup.ts +127 -0
- package/app/apps/github/src/markdown/patches.ts +299 -0
- package/app/apps/github/src/markdown/query.ts +25 -0
- package/app/apps/github/src/markdown/references.ts +158 -0
- package/app/apps/github/src/markdown/render.ts +103 -0
- package/app/apps/github/src/names/owners.ts +51 -0
- package/app/apps/github/src/names/repos.ts +24 -0
- package/app/apps/github/src/palette/palette.tsx +562 -0
- package/app/apps/github/src/palette/recent.ts +116 -0
- package/app/apps/github/src/palette/rows.tsx +487 -0
- package/app/apps/github/src/palette/server.ts +107 -0
- package/app/apps/github/src/palette/targets.ts +306 -0
- package/app/apps/github/src/policy.ts +606 -0
- package/app/apps/github/src/private-repos.ts +47 -0
- package/app/apps/github/src/pulls/compare-page.tsx +342 -0
- package/app/apps/github/src/pulls/files-tab.tsx +776 -0
- package/app/apps/github/src/pulls/live.ts +124 -0
- package/app/apps/github/src/pulls/merge-box.tsx +367 -0
- package/app/apps/github/src/pulls/merge-button.ts +86 -0
- package/app/apps/github/src/pulls/pull-list.tsx +235 -0
- package/app/apps/github/src/pulls/pull-page.tsx +474 -0
- package/app/apps/github/src/pulls/pull.ts +468 -0
- package/app/apps/github/src/pulls/pulls.ts +318 -0
- package/app/apps/github/src/pulls/review.ts +350 -0
- package/app/apps/github/src/pulls/search.ts +130 -0
- package/app/apps/github/src/queue/queue-page.tsx +405 -0
- package/app/apps/github/src/queue/queue.ts +231 -0
- package/app/apps/github/src/releases/latest-release.tsx +55 -0
- package/app/apps/github/src/releases/overview.tsx +30 -0
- package/app/apps/github/src/releases/release-form.tsx +353 -0
- package/app/apps/github/src/releases/release-list.tsx +173 -0
- package/app/apps/github/src/releases/release-view.tsx +183 -0
- package/app/apps/github/src/releases/releases.ts +308 -0
- package/app/apps/github/src/releases/tag-list.tsx +134 -0
- package/app/apps/github/src/router.tsx +46 -0
- package/app/apps/github/src/routes/$owner/$repo/_code/blob/$.tsx +33 -0
- package/app/apps/github/src/routes/$owner/$repo/_code/tree/$.tsx +28 -0
- package/app/apps/github/src/routes/$owner/$repo/_code.tsx +11 -0
- package/app/apps/github/src/routes/$owner/$repo/_releases/releases/index.tsx +19 -0
- package/app/apps/github/src/routes/$owner/$repo/_releases/tags.tsx +19 -0
- package/app/apps/github/src/routes/$owner/$repo/_releases.tsx +23 -0
- package/app/apps/github/src/routes/$owner/$repo/branches.tsx +39 -0
- package/app/apps/github/src/routes/$owner/$repo/commit/$sha.tsx +34 -0
- package/app/apps/github/src/routes/$owner/$repo/commits/$.tsx +42 -0
- package/app/apps/github/src/routes/$owner/$repo/compare/$.tsx +19 -0
- package/app/apps/github/src/routes/$owner/$repo/index.tsx +24 -0
- package/app/apps/github/src/routes/$owner/$repo/issues/$number.tsx +50 -0
- package/app/apps/github/src/routes/$owner/$repo/issues/index.tsx +53 -0
- package/app/apps/github/src/routes/$owner/$repo/issues/new.tsx +43 -0
- package/app/apps/github/src/routes/$owner/$repo/labels.tsx +22 -0
- package/app/apps/github/src/routes/$owner/$repo/pull/$number/checks.tsx +15 -0
- package/app/apps/github/src/routes/$owner/$repo/pull/$number/commits.tsx +15 -0
- package/app/apps/github/src/routes/$owner/$repo/pull/$number/files.tsx +15 -0
- package/app/apps/github/src/routes/$owner/$repo/pull/$number/index.tsx +19 -0
- package/app/apps/github/src/routes/$owner/$repo/pull/$number/route.tsx +52 -0
- package/app/apps/github/src/routes/$owner/$repo/pulls/index.tsx +48 -0
- package/app/apps/github/src/routes/$owner/$repo/queue.tsx +22 -0
- package/app/apps/github/src/routes/$owner/$repo/releases/edit/$.tsx +58 -0
- package/app/apps/github/src/routes/$owner/$repo/releases/new.tsx +40 -0
- package/app/apps/github/src/routes/$owner/$repo/releases/tag/$.tsx +35 -0
- package/app/apps/github/src/routes/$owner/$repo/route.tsx +102 -0
- package/app/apps/github/src/routes/$owner/$repo/settings/access.tsx +9 -0
- package/app/apps/github/src/routes/$owner/$repo/settings/hooks/index.tsx +16 -0
- package/app/apps/github/src/routes/$owner/$repo/settings/hooks/new.tsx +25 -0
- package/app/apps/github/src/routes/$owner/$repo/settings/index.tsx +17 -0
- package/app/apps/github/src/routes/$owner/$repo/settings/route.tsx +28 -0
- package/app/apps/github/src/routes/$owner/$repo/settings/rules.tsx +12 -0
- package/app/apps/github/src/routes/$owner/$repo/tokens.tsx +16 -0
- package/app/apps/github/src/routes/$owner/index.tsx +45 -0
- package/app/apps/github/src/routes/-nav.tsx +293 -0
- package/app/apps/github/src/routes/-root-testing.ts +107 -0
- package/app/apps/github/src/routes/__root.tsx +225 -0
- package/app/apps/github/src/routes/api.auth.$.ts +18 -0
- package/app/apps/github/src/routes/downloads/$owner/$repo/$asset.tsx +10 -0
- package/app/apps/github/src/routes/file-icons[.]svg.ts +21 -0
- package/app/apps/github/src/routes/icons/$owner/$repo.tsx +14 -0
- package/app/apps/github/src/routes/icons/$owner/index.tsx +14 -0
- package/app/apps/github/src/routes/icons/index.tsx +12 -0
- package/app/apps/github/src/routes/index.tsx +48 -0
- package/app/apps/github/src/routes/login.tsx +24 -0
- package/app/apps/github/src/routes/login_.code.tsx +31 -0
- package/app/apps/github/src/routes/new.tsx +91 -0
- package/app/apps/github/src/routes/notifications.tsx +20 -0
- package/app/apps/github/src/routes/orgs/$owner/issues.tsx +8 -0
- package/app/apps/github/src/routes/orgs/$owner/pulls.tsx +8 -0
- package/app/apps/github/src/routes/orgs/$owner/releases.tsx +8 -0
- package/app/apps/github/src/routes/orgs/$owner/route.tsx +25 -0
- package/app/apps/github/src/routes/orgs/$owner/settings.tsx +30 -0
- package/app/apps/github/src/routes/orgs/$owner/tokens.tsx +15 -0
- package/app/apps/github/src/routes/settings.tsx +54 -0
- package/app/apps/github/src/routes/signup.tsx +24 -0
- package/app/apps/github/src/routes/uploads/$owner/$repo/$release.tsx +10 -0
- package/app/apps/github/src/seed/acme.ts +498 -0
- package/app/apps/github/src/seed/licenses.ts +114 -0
- package/app/apps/github/src/seed/seed.ts +528 -0
- package/app/apps/github/src/server.ts +97 -0
- package/app/apps/github/src/settings/account-avatar.tsx +43 -0
- package/app/apps/github/src/settings/avatar-section.tsx +140 -0
- package/app/apps/github/src/settings/avatar.ts +58 -0
- package/app/apps/github/src/settings/general-settings.tsx +439 -0
- package/app/apps/github/src/settings/general.ts +73 -0
- package/app/apps/github/src/settings/hook-form.tsx +195 -0
- package/app/apps/github/src/settings/hook-list.tsx +166 -0
- package/app/apps/github/src/settings/hooks.ts +87 -0
- package/app/apps/github/src/settings/org-settings.tsx +228 -0
- package/app/apps/github/src/settings/orgs.ts +116 -0
- package/app/apps/github/src/settings/rule-list.tsx +72 -0
- package/app/apps/github/src/settings/rules.ts +27 -0
- package/app/apps/github/src/settings/settings-layout.tsx +114 -0
- package/app/apps/github/src/signin/approval.ts +186 -0
- package/app/apps/github/src/signin/auth-client.ts +127 -0
- package/app/apps/github/src/signin/auth.ts +753 -0
- package/app/apps/github/src/signin/avatars.ts +126 -0
- package/app/apps/github/src/signin/client-ip.ts +39 -0
- package/app/apps/github/src/signin/credentials.ts +26 -0
- package/app/apps/github/src/signin/device-code.ts +95 -0
- package/app/apps/github/src/signin/device-prompt.ts +125 -0
- package/app/apps/github/src/signin/errors.ts +135 -0
- package/app/apps/github/src/signin/host-session.ts +68 -0
- package/app/apps/github/src/signin/orgs.ts +283 -0
- package/app/apps/github/src/signin/owner-names.ts +183 -0
- package/app/apps/github/src/signin/person-lock.ts +104 -0
- package/app/apps/github/src/signin/seal.ts +88 -0
- package/app/apps/github/src/signin/seed-people.ts +92 -0
- package/app/apps/github/src/signin/session.ts +48 -0
- package/app/apps/github/src/signin/unborn.ts +110 -0
- package/app/apps/github/src/signin/viewer-orgs.ts +47 -0
- package/app/apps/github/src/signin/viewer.ts +74 -0
- package/app/apps/github/src/signin/with-headers.ts +14 -0
- package/app/apps/github/src/tokens/tokens-page.tsx +529 -0
- package/app/apps/github/src/tokens/tokens.ts +54 -0
- package/app/apps/github/tsconfig.json +25 -0
- package/app/apps/github/tsconfig.worker.json +24 -0
- package/app/apps/github/vite.config.ts +21 -0
- package/app/pnpm-workspace.yaml +216 -0
- package/app/tsconfig.base.json +127 -0
- package/dist/LICENSE +202 -0
- package/dist/cli/child.mjs +42 -0
- package/dist/cli/commands.mjs +23 -0
- package/dist/cli/credentials.mjs +84 -0
- package/dist/cli/documents.mjs +214 -0
- package/dist/cli/events.mjs +55 -0
- package/dist/cli/failure.mjs +105 -0
- package/dist/cli/folders.mjs +32 -0
- package/dist/cli/git-remote-ref0.d.mts +1 -0
- package/dist/cli/git-remote-ref0.mjs +29 -0
- package/dist/cli/git.mjs +69 -0
- package/dist/cli/helpers.mjs +184 -0
- package/dist/cli/hosts.mjs +127 -0
- package/dist/cli/node.mjs +15 -0
- package/dist/cli/output.mjs +135 -0
- package/dist/cli/prompt.mjs +35 -0
- package/dist/cli/queue.mjs +215 -0
- package/dist/cli/ref0-git.d.mts +1 -0
- package/dist/cli/ref0-git.mjs +144 -0
- package/dist/cli/repos.mjs +162 -0
- package/dist/cli/resources.mjs +131 -0
- package/dist/cli/run-end.mjs +57 -0
- package/dist/cli/runtime.mjs +50 -0
- package/dist/cli/setup.mjs +1410 -0
- package/dist/cli/sign-in.mjs +162 -0
- package/dist/cli/sign-ins.mjs +136 -0
- package/dist/cli/sqlite.mjs +28 -0
- package/dist/cli/tokens.mjs +141 -0
- package/dist/cli/vendor.mjs +123 -0
- package/dist/init/app.mjs +231 -0
- package/dist/init/astro.mjs +49 -0
- package/dist/init/choices.mjs +497 -0
- package/dist/init/cloudflare.mjs +324 -0
- package/dist/init/create.mjs +151 -0
- package/dist/init/detect.mjs +297 -0
- package/dist/init/files.mjs +80 -0
- package/dist/init/frameworks.mjs +248 -0
- package/dist/init/git-module.mjs +49 -0
- package/dist/init/github-routes.mjs +66 -0
- package/dist/init/jsonc.mjs +143 -0
- package/dist/init/metadata.mjs +48 -0
- package/dist/init/mounts.mjs +109 -0
- package/dist/init/next.mjs +203 -0
- package/dist/init/node-app.mjs +189 -0
- package/dist/init/node.mjs +460 -0
- package/dist/init/nuxt.mjs +115 -0
- package/dist/init/output.mjs +21 -0
- package/dist/init/plan.mjs +82 -0
- package/dist/init/range-major.mjs +257 -0
- package/dist/init/react-router.mjs +59 -0
- package/dist/init/routes.mjs +148 -0
- package/dist/init/shell.mjs +4 -0
- package/dist/init/stores.mjs +51 -0
- package/dist/init/sveltekit.mjs +139 -0
- package/dist/init/template.mjs +142 -0
- package/dist/init/templates.mjs +343 -0
- package/dist/init/vercel.mjs +384 -0
- package/dist/init/versions.mjs +32 -0
- package/dist/init/workspace.mjs +20 -0
- package/package.json +48 -6
- package/README.md +0 -5
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
import { createFileRoute } from '@tanstack/react-router';
|
|
2
|
+
|
|
3
|
+
import { removeAvatar, serveAvatar, uploadAvatar } from '../../../clients/avatars.ts';
|
|
4
|
+
|
|
5
|
+
/** A repo's icon: served to its readers, and set or removed from its settings by its admins. */
|
|
6
|
+
export const Route = createFileRoute('/icons/$owner/$repo')({
|
|
7
|
+
server: {
|
|
8
|
+
handlers: {
|
|
9
|
+
GET: ({ request, context, params }) => serveAvatar(context, request, params),
|
|
10
|
+
PUT: ({ request, context, params }) => uploadAvatar(context, request, params),
|
|
11
|
+
DELETE: ({ request, context, params }) => removeAvatar(context, request, params),
|
|
12
|
+
},
|
|
13
|
+
},
|
|
14
|
+
});
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
import { createFileRoute } from '@tanstack/react-router';
|
|
2
|
+
|
|
3
|
+
import { removeAvatar, serveAvatar, uploadAvatar } from '../../../clients/avatars.ts';
|
|
4
|
+
|
|
5
|
+
/** A person's or an org's picture: served to anyone, and set or removed from their settings. */
|
|
6
|
+
export const Route = createFileRoute('/icons/$owner/')({
|
|
7
|
+
server: {
|
|
8
|
+
handlers: {
|
|
9
|
+
GET: ({ request, context, params }) => serveAvatar(context, request, params),
|
|
10
|
+
PUT: ({ request, context, params }) => uploadAvatar(context, request, params),
|
|
11
|
+
DELETE: ({ request, context, params }) => removeAvatar(context, request, params),
|
|
12
|
+
},
|
|
13
|
+
},
|
|
14
|
+
});
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
import { createFileRoute } from '@tanstack/react-router';
|
|
2
|
+
|
|
3
|
+
import { serveIconHashes } from '../../clients/avatars.ts';
|
|
4
|
+
|
|
5
|
+
/** The icon hashes of the repos a page shows, by their names, each as its caller reads it. */
|
|
6
|
+
export const Route = createFileRoute('/icons/')({
|
|
7
|
+
server: {
|
|
8
|
+
handlers: {
|
|
9
|
+
GET: ({ request, context }) => serveIconHashes(context, request),
|
|
10
|
+
},
|
|
11
|
+
},
|
|
12
|
+
});
|
|
@@ -0,0 +1,48 @@
|
|
|
1
|
+
import { createFileRoute, redirect } from '@tanstack/react-router';
|
|
2
|
+
|
|
3
|
+
import { readPagesAhead } from '../clients/cached.ts';
|
|
4
|
+
import { YourRepos } from '../components/repos/your-repos.tsx';
|
|
5
|
+
import { signInHref } from '../components/states/states.tsx';
|
|
6
|
+
import { filterOf, readSearch, repoList, searchOf } from '../hooks/repos.ts';
|
|
7
|
+
|
|
8
|
+
export const Route = createFileRoute('/')({
|
|
9
|
+
validateSearch: (query) => searchOf(filterOf(readSearch(query))),
|
|
10
|
+
// A visitor signs in first, before the page draws on the server or in the browser, and comes back.
|
|
11
|
+
beforeLoad: ({ context, location }) => {
|
|
12
|
+
if (context.viewer === null) throw redirect({ href: signInHref(location.href) });
|
|
13
|
+
|
|
14
|
+
return { viewer: context.viewer };
|
|
15
|
+
},
|
|
16
|
+
loaderDeps: ({ search }) => search,
|
|
17
|
+
// Each list's first page, read before the page draws, so the server draws the rows and not a
|
|
18
|
+
// skeleton the browser swaps out.
|
|
19
|
+
loader: async ({ context, deps }) => {
|
|
20
|
+
const filter = filterOf(deps);
|
|
21
|
+
const { login, orgs } = context.viewer;
|
|
22
|
+
const owners = [
|
|
23
|
+
{ kind: 'viewer' as const, login },
|
|
24
|
+
...orgs.map((org) => ({ kind: 'org' as const, login: org })),
|
|
25
|
+
];
|
|
26
|
+
|
|
27
|
+
await Promise.all(
|
|
28
|
+
owners.map((owner) => readPagesAhead(context.queryClient, repoList(owner, filter))),
|
|
29
|
+
);
|
|
30
|
+
},
|
|
31
|
+
component: Home,
|
|
32
|
+
});
|
|
33
|
+
|
|
34
|
+
/** The viewer's repositories and their orgs'. */
|
|
35
|
+
function Home() {
|
|
36
|
+
const { viewer } = Route.useRouteContext();
|
|
37
|
+
const navigate = Route.useNavigate();
|
|
38
|
+
const filter = filterOf(Route.useSearch());
|
|
39
|
+
|
|
40
|
+
return (
|
|
41
|
+
<YourRepos
|
|
42
|
+
viewer={viewer.login}
|
|
43
|
+
orgs={viewer.orgs}
|
|
44
|
+
filter={filter}
|
|
45
|
+
onFilter={(next) => void navigate({ search: searchOf(next), replace: true })}
|
|
46
|
+
/>
|
|
47
|
+
);
|
|
48
|
+
}
|
|
@@ -0,0 +1,24 @@
|
|
|
1
|
+
import { createFileRoute, redirect } from '@tanstack/react-router';
|
|
2
|
+
|
|
3
|
+
import { SigninPage } from '../components/signin/signin-page.tsx';
|
|
4
|
+
import { LoginForm } from '../components/signin/login-form.tsx';
|
|
5
|
+
import { backTo, returnSearch } from '../signin/session.ts';
|
|
6
|
+
|
|
7
|
+
/** Sign-in with a login and a password; `?return_to=` names the app's page to go back to. */
|
|
8
|
+
export const Route = createFileRoute('/login')({
|
|
9
|
+
validateSearch: returnSearch,
|
|
10
|
+
beforeLoad: ({ context, search }) => {
|
|
11
|
+
if (context.viewer !== null) throw redirect({ href: backTo(search.return_to) });
|
|
12
|
+
},
|
|
13
|
+
component: Login,
|
|
14
|
+
});
|
|
15
|
+
|
|
16
|
+
function Login() {
|
|
17
|
+
const search = Route.useSearch();
|
|
18
|
+
|
|
19
|
+
return (
|
|
20
|
+
<SigninPage>
|
|
21
|
+
<LoginForm returnTo={backTo(search.return_to)} />
|
|
22
|
+
</SigninPage>
|
|
23
|
+
);
|
|
24
|
+
}
|
|
@@ -0,0 +1,31 @@
|
|
|
1
|
+
import { createFileRoute, redirect } from '@tanstack/react-router';
|
|
2
|
+
|
|
3
|
+
import { SigninPage } from '../components/signin/signin-page.tsx';
|
|
4
|
+
import { DeviceCard } from '../components/signin/device-card.tsx';
|
|
5
|
+
import { codeSearch, deviceCard } from '../signin/device-code.ts';
|
|
6
|
+
|
|
7
|
+
/**
|
|
8
|
+
* The device flow's page, which Git's `/login/device` redirects to: a code to enter, a device's
|
|
9
|
+
* prompt to approve or deny, or what was decided. A person signs in first, and comes back here.
|
|
10
|
+
*/
|
|
11
|
+
export const Route = createFileRoute('/login_/code')({
|
|
12
|
+
validateSearch: codeSearch,
|
|
13
|
+
beforeLoad: ({ context, location }) => {
|
|
14
|
+
if (context.viewer === null) {
|
|
15
|
+
throw redirect({ href: `/login?${new URLSearchParams({ return_to: location.href })}` });
|
|
16
|
+
}
|
|
17
|
+
},
|
|
18
|
+
loaderDeps: ({ search }) => search,
|
|
19
|
+
loader: ({ deps }) => deviceCard({ data: deps }),
|
|
20
|
+
component: Code,
|
|
21
|
+
});
|
|
22
|
+
|
|
23
|
+
function Code() {
|
|
24
|
+
const state = Route.useLoaderData();
|
|
25
|
+
|
|
26
|
+
return (
|
|
27
|
+
<SigninPage>
|
|
28
|
+
<DeviceCard state={state} />
|
|
29
|
+
</SigninPage>
|
|
30
|
+
);
|
|
31
|
+
}
|
|
@@ -0,0 +1,91 @@
|
|
|
1
|
+
import { createFileRoute } from '@tanstack/react-router';
|
|
2
|
+
import { flow } from 'effect/Function';
|
|
3
|
+
import * as Option from 'effect/Option';
|
|
4
|
+
import * as Schema from 'effect/Schema';
|
|
5
|
+
|
|
6
|
+
import { NewRepoForm } from '../components/repos/new-repo-form.tsx';
|
|
7
|
+
import { RepoList } from '../components/repos/repo-list.tsx';
|
|
8
|
+
import { RouteDialog } from '../components/route-dialog.tsx';
|
|
9
|
+
import { SignedOut } from '../components/states/states.tsx';
|
|
10
|
+
import {
|
|
11
|
+
filterOf,
|
|
12
|
+
newLoader,
|
|
13
|
+
newLoaderDeps,
|
|
14
|
+
type Owner,
|
|
15
|
+
readSearch,
|
|
16
|
+
searchOf,
|
|
17
|
+
} from '../hooks/repos.ts';
|
|
18
|
+
import { backTo } from '../signin/session.ts';
|
|
19
|
+
|
|
20
|
+
/**
|
|
21
|
+
* `/new`'s URL query: the owner the form starts under, as an org's New names it, and `return_to`,
|
|
22
|
+
* the page New was pressed on, which closing goes back to, as sign-in's does.
|
|
23
|
+
*/
|
|
24
|
+
const NewSearch = Schema.Struct({
|
|
25
|
+
owner: Schema.optional(Schema.String),
|
|
26
|
+
return_to: Schema.optional(Schema.String),
|
|
27
|
+
});
|
|
28
|
+
|
|
29
|
+
/** `/new`'s query, read: one it can't read starts under the viewer. */
|
|
30
|
+
const readNewSearch = flow(
|
|
31
|
+
Schema.decodeUnknownOption(NewSearch),
|
|
32
|
+
Option.getOrElse((): typeof NewSearch.Type => ({})),
|
|
33
|
+
);
|
|
34
|
+
|
|
35
|
+
export const Route = createFileRoute('/new')({
|
|
36
|
+
validateSearch: readNewSearch,
|
|
37
|
+
loaderDeps: newLoaderDeps,
|
|
38
|
+
loader: newLoader,
|
|
39
|
+
component: NewRepo,
|
|
40
|
+
});
|
|
41
|
+
|
|
42
|
+
/**
|
|
43
|
+
* A new repository, under the viewer's login or one of their orgs', in a dialog over the list New
|
|
44
|
+
* was pressed on: the org's that `?owner=` names, when they belong to it, or else their own. The form
|
|
45
|
+
* starts under that owner. Closing it goes back to `?return_to=`, kept on the app's own pages, or to
|
|
46
|
+
* that list.
|
|
47
|
+
*/
|
|
48
|
+
function NewRepo() {
|
|
49
|
+
const { viewer } = Route.useRouteContext();
|
|
50
|
+
const { org } = Route.useLoaderData();
|
|
51
|
+
const { owner, return_to } = Route.useSearch();
|
|
52
|
+
const navigate = Route.useNavigate();
|
|
53
|
+
if (viewer === null) return <SignedOut returnTo="/new" what="the new repository form" />;
|
|
54
|
+
|
|
55
|
+
// An org past the 1,000 the viewer's orgs hold joins the picker, once its check says so.
|
|
56
|
+
const owners =
|
|
57
|
+
org === undefined || viewer.orgs.includes(org)
|
|
58
|
+
? [viewer.login, ...viewer.orgs]
|
|
59
|
+
: [viewer.login, ...viewer.orgs, org];
|
|
60
|
+
const listed: Owner =
|
|
61
|
+
org === undefined ? { kind: 'viewer', login: viewer.login } : { kind: 'org', login: org };
|
|
62
|
+
const list = org === undefined ? '/' : `/${org}`;
|
|
63
|
+
const back = return_to === undefined ? list : backTo(return_to);
|
|
64
|
+
// The list draws as the page it closes to does: with that page's filter, when it's the list's.
|
|
65
|
+
const backUrl = new URL(back, 'https://app.invalid');
|
|
66
|
+
const filter = filterOf(
|
|
67
|
+
readSearch(backUrl.pathname === list ? Object.fromEntries(backUrl.searchParams) : {}),
|
|
68
|
+
);
|
|
69
|
+
|
|
70
|
+
return (
|
|
71
|
+
<>
|
|
72
|
+
<RepoList
|
|
73
|
+
owner={listed}
|
|
74
|
+
owns
|
|
75
|
+
filter={filter}
|
|
76
|
+
onFilter={(next) =>
|
|
77
|
+
void (org === undefined
|
|
78
|
+
? navigate({ to: '/', search: searchOf(next) })
|
|
79
|
+
: navigate({ to: '/$owner', params: { owner: org }, search: searchOf(next) }))
|
|
80
|
+
}
|
|
81
|
+
/>
|
|
82
|
+
<RouteDialog
|
|
83
|
+
title="New repository"
|
|
84
|
+
description="A Git repository under your login, or one of your organizations'."
|
|
85
|
+
closeTo={back}
|
|
86
|
+
>
|
|
87
|
+
<NewRepoForm viewer={viewer.login} owners={owners} start={owner} />
|
|
88
|
+
</RouteDialog>
|
|
89
|
+
</>
|
|
90
|
+
);
|
|
91
|
+
}
|
|
@@ -0,0 +1,20 @@
|
|
|
1
|
+
import { createFileRoute } from '@tanstack/react-router';
|
|
2
|
+
|
|
3
|
+
import { SignedOut } from '../components/states/states.tsx';
|
|
4
|
+
import { InboxPage } from '../inbox/inbox-page.tsx';
|
|
5
|
+
import { filterOf, inboxHref, readInboxSearch } from '../inbox/search.ts';
|
|
6
|
+
|
|
7
|
+
export const Route = createFileRoute('/notifications')({
|
|
8
|
+
validateSearch: readInboxSearch,
|
|
9
|
+
staticData: { ownHeading: true },
|
|
10
|
+
component: Notifications,
|
|
11
|
+
});
|
|
12
|
+
|
|
13
|
+
/** The signed-in viewer's Inbox, under the filter its URL names; a visitor's is a sign-in. */
|
|
14
|
+
function Notifications() {
|
|
15
|
+
const { viewer } = Route.useRouteContext();
|
|
16
|
+
const filter = filterOf(Route.useSearch());
|
|
17
|
+
if (viewer === null) return <SignedOut returnTo={inboxHref(filter)} what="your inbox" />;
|
|
18
|
+
|
|
19
|
+
return <InboxPage filter={filter} />;
|
|
20
|
+
}
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
import { createFileRoute } from '@tanstack/react-router';
|
|
2
|
+
|
|
3
|
+
import { AcrossRepos } from '../../../components/states/states.tsx';
|
|
4
|
+
|
|
5
|
+
/** An owner's issues across its repos, which waits on one read across them. */
|
|
6
|
+
export const Route = createFileRoute('/orgs/$owner/issues')({
|
|
7
|
+
component: () => <AcrossRepos what="issues" />,
|
|
8
|
+
});
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
import { createFileRoute } from '@tanstack/react-router';
|
|
2
|
+
|
|
3
|
+
import { AcrossRepos } from '../../../components/states/states.tsx';
|
|
4
|
+
|
|
5
|
+
/** An owner's pull requests across its repos, which waits on one read across them. */
|
|
6
|
+
export const Route = createFileRoute('/orgs/$owner/pulls')({
|
|
7
|
+
component: () => <AcrossRepos what="pull requests" />,
|
|
8
|
+
});
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
import { createFileRoute } from '@tanstack/react-router';
|
|
2
|
+
|
|
3
|
+
import { AcrossRepos } from '../../../components/states/states.tsx';
|
|
4
|
+
|
|
5
|
+
/** An owner's releases across its repos, which waits on one read across them. */
|
|
6
|
+
export const Route = createFileRoute('/orgs/$owner/releases')({
|
|
7
|
+
component: () => <AcrossRepos what="releases" />,
|
|
8
|
+
});
|
|
@@ -0,0 +1,25 @@
|
|
|
1
|
+
import { createFileRoute, notFound, Outlet } from '@tanstack/react-router';
|
|
2
|
+
|
|
3
|
+
import { cached } from '../../../clients/cached.ts';
|
|
4
|
+
import { LoadFailed } from '../../../components/states/states.tsx';
|
|
5
|
+
import { ownerAt } from '../../../hooks/repos.ts';
|
|
6
|
+
import { ownerProblem } from '../../../names/owners.ts';
|
|
7
|
+
|
|
8
|
+
/**
|
|
9
|
+
* An owner's level, under `/orgs/$owner/`: the owner read once, before its page draws, so each
|
|
10
|
+
* page and the shell know it for an org or a person, and a login no one has is not found.
|
|
11
|
+
*/
|
|
12
|
+
export const Route = createFileRoute('/orgs/$owner')({
|
|
13
|
+
loader: async ({ params, context }) => {
|
|
14
|
+
if (ownerProblem(params.owner) !== undefined) throw notFound();
|
|
15
|
+
|
|
16
|
+
const owner = await cached(context.queryClient, ownerAt(params.owner, context.viewer?.login));
|
|
17
|
+
if (owner === null) throw notFound();
|
|
18
|
+
|
|
19
|
+
return { owner };
|
|
20
|
+
},
|
|
21
|
+
component: Outlet,
|
|
22
|
+
errorComponent: ({ error }) => (
|
|
23
|
+
<LoadFailed message={error instanceof Error ? error.message : "The owner didn't load"} />
|
|
24
|
+
),
|
|
25
|
+
});
|
|
@@ -0,0 +1,30 @@
|
|
|
1
|
+
import { createFileRoute, notFound, useLoaderData, useRouteContext } from '@tanstack/react-router';
|
|
2
|
+
|
|
3
|
+
import { cached } from '../../../clients/cached.ts';
|
|
4
|
+
import { SignedOut } from '../../../components/states/states.tsx';
|
|
5
|
+
import { ownerAt } from '../../../hooks/repos.ts';
|
|
6
|
+
import { OrgSettings } from '../../../settings/org-settings.tsx';
|
|
7
|
+
|
|
8
|
+
/** An org's settings: a person's own are at `/settings`, and no one's are under `/orgs/`. */
|
|
9
|
+
export const Route = createFileRoute('/orgs/$owner/settings')({
|
|
10
|
+
loader: async ({ params, context }) => {
|
|
11
|
+
// The owner's level reads the same owner, at the same time, so the two share the one read.
|
|
12
|
+
const owner = await cached(context.queryClient, ownerAt(params.owner, context.viewer?.login));
|
|
13
|
+
if (owner?.kind !== 'org') throw notFound();
|
|
14
|
+
},
|
|
15
|
+
component: OrgSettingsPage,
|
|
16
|
+
});
|
|
17
|
+
|
|
18
|
+
/** An org's picture and people, for someone signed in. */
|
|
19
|
+
function OrgSettingsPage() {
|
|
20
|
+
const { owner } = useLoaderData({ from: '/orgs/$owner' });
|
|
21
|
+
const { viewer } = useRouteContext({ from: '__root__' });
|
|
22
|
+
|
|
23
|
+
if (viewer === null) {
|
|
24
|
+
return (
|
|
25
|
+
<SignedOut returnTo={`/orgs/${owner.login}/settings`} what={`${owner.login}'s settings`} />
|
|
26
|
+
);
|
|
27
|
+
}
|
|
28
|
+
|
|
29
|
+
return <OrgSettings org={owner.login} viewer={viewer.login} />;
|
|
30
|
+
}
|
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
import { createFileRoute, useRouteContext } from '@tanstack/react-router';
|
|
2
|
+
|
|
3
|
+
import { SignedOut } from '../../../components/states/states.tsx';
|
|
4
|
+
import { TokensPage } from '../../../tokens/tokens-page.tsx';
|
|
5
|
+
|
|
6
|
+
export const Route = createFileRoute('/orgs/$owner/tokens')({ component: Tokens });
|
|
7
|
+
|
|
8
|
+
/** The signed-in person's tokens that reach the owner's repos. */
|
|
9
|
+
function Tokens() {
|
|
10
|
+
const { owner } = Route.useParams();
|
|
11
|
+
const { viewer } = useRouteContext({ from: '__root__' });
|
|
12
|
+
if (viewer === null) return <SignedOut returnTo={`/orgs/${owner}/tokens`} what="your tokens" />;
|
|
13
|
+
|
|
14
|
+
return <TokensPage login={viewer.login} within={{ owner }} />;
|
|
15
|
+
}
|
|
@@ -0,0 +1,54 @@
|
|
|
1
|
+
import { createFileRoute, useRouteContext } from '@tanstack/react-router';
|
|
2
|
+
|
|
3
|
+
import { SignedOut } from '../components/states/states.tsx';
|
|
4
|
+
import { ThemeToggles } from '../components/theme-choice.tsx';
|
|
5
|
+
import {
|
|
6
|
+
Card,
|
|
7
|
+
CardContent,
|
|
8
|
+
CardDescription,
|
|
9
|
+
CardHeader,
|
|
10
|
+
CardTitle,
|
|
11
|
+
} from '../components/ui/card.tsx';
|
|
12
|
+
import { AccountAvatar } from '../settings/account-avatar.tsx';
|
|
13
|
+
|
|
14
|
+
export const Route = createFileRoute('/settings')({ component: AccountSettingsPage });
|
|
15
|
+
|
|
16
|
+
/**
|
|
17
|
+
* The signed-in person's own settings, at `/settings` as GitHub's are: their picture, and how this
|
|
18
|
+
* browser shows the app, the account menu's Theme from the same piece. Their tokens
|
|
19
|
+
* have their own page in the side nav, so these don't repeat them. An org's are at
|
|
20
|
+
* `/orgs/$owner/settings`.
|
|
21
|
+
*/
|
|
22
|
+
function AccountSettingsPage() {
|
|
23
|
+
const { viewer } = useRouteContext({ from: '__root__' });
|
|
24
|
+
if (viewer === null) return <SignedOut returnTo="/settings" what="your settings" />;
|
|
25
|
+
|
|
26
|
+
return (
|
|
27
|
+
// A form-like page, as an org's settings: held to a readable width, in the middle of the page.
|
|
28
|
+
<div className="mx-auto flex w-full max-w-3xl flex-col gap-6">
|
|
29
|
+
<AccountAvatar login={viewer.login} account="user" />
|
|
30
|
+
<Appearance />
|
|
31
|
+
</div>
|
|
32
|
+
);
|
|
33
|
+
}
|
|
34
|
+
|
|
35
|
+
/** The theme, kept in this browser: kept on the account waits for the accounts design's pages. */
|
|
36
|
+
function Appearance() {
|
|
37
|
+
return (
|
|
38
|
+
<section aria-label="Appearance">
|
|
39
|
+
<Card>
|
|
40
|
+
<CardHeader>
|
|
41
|
+
<CardTitle>
|
|
42
|
+
<h2>Appearance</h2>
|
|
43
|
+
</CardTitle>
|
|
44
|
+
<CardDescription>
|
|
45
|
+
Light, dark, or as your system is set. This browser keeps it, so another keeps its own.
|
|
46
|
+
</CardDescription>
|
|
47
|
+
</CardHeader>
|
|
48
|
+
<CardContent>
|
|
49
|
+
<ThemeToggles named />
|
|
50
|
+
</CardContent>
|
|
51
|
+
</Card>
|
|
52
|
+
</section>
|
|
53
|
+
);
|
|
54
|
+
}
|
|
@@ -0,0 +1,24 @@
|
|
|
1
|
+
import { createFileRoute, redirect } from '@tanstack/react-router';
|
|
2
|
+
|
|
3
|
+
import { SigninPage } from '../components/signin/signin-page.tsx';
|
|
4
|
+
import { SignupForm } from '../components/signin/signup-form.tsx';
|
|
5
|
+
import { backTo, returnSearch } from '../signin/session.ts';
|
|
6
|
+
|
|
7
|
+
/** Sign-up with a login and a password, signed in after; `?return_to=` as `/login` takes it. */
|
|
8
|
+
export const Route = createFileRoute('/signup')({
|
|
9
|
+
validateSearch: returnSearch,
|
|
10
|
+
beforeLoad: ({ context, search }) => {
|
|
11
|
+
if (context.viewer !== null) throw redirect({ href: backTo(search.return_to) });
|
|
12
|
+
},
|
|
13
|
+
component: Signup,
|
|
14
|
+
});
|
|
15
|
+
|
|
16
|
+
function Signup() {
|
|
17
|
+
const search = Route.useSearch();
|
|
18
|
+
|
|
19
|
+
return (
|
|
20
|
+
<SigninPage>
|
|
21
|
+
<SignupForm returnTo={backTo(search.return_to)} />
|
|
22
|
+
</SigninPage>
|
|
23
|
+
);
|
|
24
|
+
}
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
import { createFileRoute } from '@tanstack/react-router';
|
|
2
|
+
|
|
3
|
+
import { forwardUpload } from '../../../../clients/transfers.ts';
|
|
4
|
+
|
|
5
|
+
/** An asset's upload from the app's release form, streamed to the drop-in as the session's holder. */
|
|
6
|
+
export const Route = createFileRoute('/uploads/$owner/$repo/$release')({
|
|
7
|
+
server: {
|
|
8
|
+
handlers: { POST: ({ request, context, params }) => forwardUpload(context, request, params) },
|
|
9
|
+
},
|
|
10
|
+
});
|