Closes backlog item 4: Rithub (apps/gitea, live at git.ereboslab.com) had
zero discovery or signup surface. A signed-in Console session now
provisions a dedicated Gitea user, private org and first repo in one call
(lib/gitea.ts, admin API with sudo= impersonation), via a new public
/rithub landing page and POST /api/v1/rithub/provision route. Signed out,
the CTA goes through the same cross-sell sign-in bridge as items 1/2;
signed in, it closes the loop item 5's OIDC provider opened ("one sign-in,
not a second account").
Verified against a real gitea/gitea:1.23 container: user/org/repo creation,
sudo impersonation, slug-collision retries and the route's idempotency
check all confirmed live. tsc clean, npm test 167/167, npm run test:bundle
3/3 (including a full client build).
46 lines
1.7 KiB
TypeScript
46 lines
1.7 KiB
TypeScript
// Inline icons (no emoji, no icon-font download).
|
|
export function CopyIcon() {
|
|
return (
|
|
<svg width="16" height="16" viewBox="0 0 24 24" fill="none" stroke="currentColor" strokeWidth="2" aria-hidden="true">
|
|
<rect x="9" y="9" width="12" height="12" rx="2" />
|
|
<path d="M5 15V5a2 2 0 0 1 2-2h10" />
|
|
</svg>
|
|
);
|
|
}
|
|
export function SignOutIcon() {
|
|
return (
|
|
<svg width="16" height="16" viewBox="0 0 24 24" fill="none" stroke="currentColor" strokeWidth="2" aria-hidden="true">
|
|
<path d="M9 21H5a2 2 0 0 1-2-2V5a2 2 0 0 1 2-2h4" />
|
|
<path d="M16 17l5-5-5-5M21 12H9" />
|
|
</svg>
|
|
);
|
|
}
|
|
export function CloseIcon() {
|
|
return (
|
|
<svg width="16" height="16" viewBox="0 0 24 24" fill="none" stroke="currentColor" strokeWidth="2" aria-hidden="true">
|
|
<path d="M18 6L6 18M6 6l12 12" />
|
|
</svg>
|
|
);
|
|
}
|
|
/** A ledger/billing account glyph (Mint self-serve provisioning, item 11). */
|
|
export function WalletIcon() {
|
|
return (
|
|
<svg width="16" height="16" viewBox="0 0 24 24" fill="none" stroke="currentColor" strokeWidth="2" aria-hidden="true">
|
|
<rect x="3" y="6" width="18" height="13" rx="2" />
|
|
<path d="M3 10h18" />
|
|
<circle cx="16" cy="14.5" r="1.3" fill="currentColor" stroke="none" />
|
|
</svg>
|
|
);
|
|
}
|
|
/** A git-repo glyph (Rithub self-serve provisioning, item 4). */
|
|
export function GitRepoIcon() {
|
|
return (
|
|
<svg width="16" height="16" viewBox="0 0 24 24" fill="none" stroke="currentColor" strokeWidth="2" aria-hidden="true">
|
|
<circle cx="6" cy="6" r="2.4" />
|
|
<circle cx="6" cy="18" r="2.4" />
|
|
<circle cx="18" cy="9" r="2.4" />
|
|
<path d="M6 8.4V15.6M6 15.6c0-4 3-5.8 6.3-6.5M18 11.4V13" />
|
|
</svg>
|
|
);
|
|
}
|