diff --git a/web/src/app.css b/web/src/app.css index 898558b6e..306d16cd9 100644 --- a/web/src/app.css +++ b/web/src/app.css @@ -3,8 +3,6 @@ @import "./pierre.css"; @import "./logs.css"; -/* dark follows the system unless an ancestor pins the theme, so Storybook (and - later the theme setting) can force either mode with data-theme on */ @custom-variant dark { @media (prefers-color-scheme: dark) { &:where(:not([data-theme="light"], [data-theme="light"] *)) { @@ -24,13 +22,6 @@ --font-sans--font-feature-settings: "kern" 1, "liga" 1, "cv05" 1, "tnum" 1; - /* ========================================================================= - Semantic color tokens — synced from Figma "Design System" › semantic colors - Names mirror the Figma variables verbatim (`/` → `-`). Light-mode values - here; dark-mode overrides live in the dark variant block below. - ========================================================================= */ - - /* --- background --- */ --color-background-default: #ffffff; --color-background-subtle: #f9fafb; --color-background-inset: #f3f4f6; @@ -61,7 +52,6 @@ --color-background-navigation-frame: #f9fafb; --color-background-navigation-item: #ffffff; - /* --- foreground --- */ --color-foreground-default: #111827; --color-foreground-muted: #4b5563; --color-foreground-subtle: #6b7280; @@ -94,7 +84,6 @@ --color-foreground-link-info: #4f46e5; --color-foreground-link-info-hover: #6366f1; - /* --- border --- */ --color-border-default: #e5e7eb; --color-border-subtle: #f3f4f6; --color-border-strong: #d1d5db; @@ -107,21 +96,18 @@ --color-border-danger-subtle: #fecaca; --color-border-navigation-item-active: #e5e7eb; - /* --- shadow (inner depth, eg.: for the button component) --- */ --color-shadow-inner-strong: #d1d5db; --color-shadow-inner-strong-hover: #d1d5db; --color-shadow-inner-subtle: #e5e7eb; --color-shadow-ambient-strong: var(--color-alpha-dark-10); --color-shadow-ambient-subtle: var(--color-alpha-dark-5); - /* --- shadow --- */ --shadow-small: 0 2px 4px var(--color-shadow-ambient-strong); --shadow-regular: 0 4px 12px var(--color-shadow-ambient-subtle), 0 2px 4px var(--color-shadow-ambient-subtle); --shadow-large: 0 6px 16px var(--color-shadow-ambient-subtle), 0 4px 6px var(--color-shadow-ambient-subtle); - /* --- alpha --- */ --color-alpha-light-5: color-mix(in srgb, var(--color-background-default) 5%, transparent); --color-alpha-light-10: color-mix(in srgb, var(--color-background-default) 10%, transparent); --color-alpha-light-15: color-mix(in srgb, var(--color-background-default) 15%, transparent); @@ -181,7 +167,6 @@ --color-ansi-bright-cyan: #04a5e5; --color-ansi-bright-white: #bcc0cc; - /* --- animations --- */ --animate-spin-step: spin-step 2.5s infinite; @keyframes spin-step { @@ -445,7 +430,6 @@ :root { @variant dark { - /* --- background (Dark) --- */ --color-background-default: #1f2937; --color-background-subtle: #374151; --color-background-inset: #374151; @@ -473,7 +457,6 @@ --color-background-navigation-frame: #1f2937; --color-background-navigation-item: #374151; - /* --- foreground (Dark) --- */ --color-foreground-default: #f3f4f6; --color-foreground-muted: #9ca3af; --color-foreground-subtle: #6b7280; @@ -505,7 +488,6 @@ --color-foreground-link-info: #6366f1; --color-foreground-link-info-hover: #818cf8; - /* --- border (Dark) --- */ --color-border-default: #374151; --color-border-subtle: #2d3643; --color-border-strong: #6b7280; @@ -517,7 +499,6 @@ --color-border-danger: #991b1b; --color-border-navigation-item-active: #4b5563; - /* --- shadow (Dark) --- */ --color-shadow-inner-strong: #030712; --color-shadow-inner-strong-hover: #1f2937; --color-shadow-inner-subtle: #111827; diff --git a/web/src/lib/api/collaborator.ts b/web/src/lib/api/collaborator.ts index 0b30bb04e..c3fb713dd 100644 --- a/web/src/lib/api/collaborator.ts +++ b/web/src/lib/api/collaborator.ts @@ -2,8 +2,6 @@ import type { Did } from "@atcute/lexicons/syntax"; import type { BobbinContext } from "./client"; import { items } from "./pagination"; -// the appview guards every write on a repo with `repo:push`, which the owner always -// holds and everyone else earns through a collaborator record export const resolvePushAccess = async ( ctx: BobbinContext, repo: { ownerDid: string; repoDid?: string }, diff --git a/web/src/lib/api/fileHistory.ts b/web/src/lib/api/fileHistory.ts index dc312a939..7f64df1aa 100644 --- a/web/src/lib/api/fileHistory.ts +++ b/web/src/lib/api/fileHistory.ts @@ -67,7 +67,6 @@ const seedOf = (key: string): number => { return hash >>> 0; }; -// mulberry32, so one path always invents the same history const random = (seed: number) => { let state = seed; return () => { @@ -80,10 +79,6 @@ const random = (seed: number) => { const DAY_MS = 86_400_000; -/** - * an invented history for one path: deterministic in `${repo}:${path}`, newest - * first, spread over enough months to group and often long enough to paginate - */ export const mockFileHistory = ( repo: string, path: string, diff --git a/web/src/lib/api/repo.ts b/web/src/lib/api/repo.ts index 8f882be07..3e4520156 100644 --- a/web/src/lib/api/repo.ts +++ b/web/src/lib/api/repo.ts @@ -151,10 +151,7 @@ export interface CommitSummary { body: string; authorName: string; authorEmail: string; - // a commit made through tangled signs with the author's did instead of an - // email, so unlike a git name that author is an account we can link to authorDid?: string; - // filled in by the loader, since resolving the did takes a round trip authorHandle?: string; when: string; changeId?: string; diff --git a/web/src/lib/api/repoIndex.ts b/web/src/lib/api/repoIndex.ts index 3fd79073f..646d3822c 100644 --- a/web/src/lib/api/repoIndex.ts +++ b/web/src/lib/api/repoIndex.ts @@ -123,7 +123,6 @@ export interface RepoIndexOptions { requireRef?: boolean; } -// a did-signed commit points at a real account, so trade the git author name // for the handle and the row reads like the rest of the site. a plain git // email that belongs to a verified signup resolves to that same did first, so // those rows get the identical treatment. diff --git a/web/src/lib/auth.svelte.ts b/web/src/lib/auth.svelte.ts index 2b6cda536..8a7e520e9 100644 --- a/web/src/lib/auth.svelte.ts +++ b/web/src/lib/auth.svelte.ts @@ -173,6 +173,7 @@ const resolveProfile = async ( } catch { // try local resolver next. } + } catch {} try { const identity = await identityResolver.resolve(identifier as ActorIdentifier); @@ -326,6 +327,7 @@ export const createAuth = ( } catch { // fall through to the inline error } + } catch {} } throw new Error(`${handle}'s session expired. Sign in again to act as them.`, { cause diff --git a/web/src/lib/components/comment/CommentCard.stories.svelte b/web/src/lib/components/comment/CommentCard.stories.svelte index 3fadebeae..376d9d818 100644 --- a/web/src/lib/components/comment/CommentCard.stories.svelte +++ b/web/src/lib/components/comment/CommentCard.stories.svelte @@ -61,7 +61,6 @@ }} /> - - - - // lucide carries no Bluesky mark, so this is the vector the appview already - // ships at appview/pages/static/icons/bluesky.svg — kept identical so both - // front ends draw the same butterfly. import type { SVGAttributes } from "svelte/elements"; let { class: className = "size-4", ...rest }: SVGAttributes = $props(); diff --git a/web/src/lib/components/icons/UserRoundArrowForward.svelte b/web/src/lib/components/icons/UserRoundArrowForward.svelte index 8ba3d47b7..77462c12d 100644 --- a/web/src/lib/components/icons/UserRoundArrowForward.svelte +++ b/web/src/lib/components/icons/UserRoundArrowForward.svelte @@ -1,7 +1,5 @@ - { void subject; clear(); }); - // clearing on close would swap the form back in behind the panel while it is - // still fading out, so a sent report keeps its confirmation and resets on the - // way back in let showing = false; $effect(() => { if (open && !showing && sent) clear(); diff --git a/web/src/lib/components/moderation/ReportItems.stories.svelte b/web/src/lib/components/moderation/ReportItems.stories.svelte index 4c9b1014f..2804ff650 100644 --- a/web/src/lib/components/moderation/ReportItems.stories.svelte +++ b/web/src/lib/components/moderation/ReportItems.stories.svelte @@ -20,7 +20,6 @@ }); - {#snippet template(args: ComponentProps)} @@ -29,7 +28,6 @@ - , out of the story canvas const dialog = await waitFor(() => { const el = screen.getByRole("dialog", { hidden: true }); expect(el).toBeVisible(); @@ -48,7 +45,6 @@ }} /> - - - diff --git a/web/src/lib/components/moderation/reporting.svelte.ts b/web/src/lib/components/moderation/reporting.svelte.ts index 6cb2479e3..f961baa51 100644 --- a/web/src/lib/components/moderation/reporting.svelte.ts +++ b/web/src/lib/components/moderation/reporting.svelte.ts @@ -6,7 +6,6 @@ export interface Reporting { canReport(authorDid: string): boolean; } -/** Call at component init: reads the auth context. */ export const createReporting = (labelerDid?: () => string | undefined): Reporting => { const auth = getAuth(); const labeler = $derived( diff --git a/web/src/lib/components/notifications/NotificationBell.svelte b/web/src/lib/components/notifications/NotificationBell.svelte index de85e787c..10a65f140 100644 --- a/web/src/lib/components/notifications/NotificationBell.svelte +++ b/web/src/lib/components/notifications/NotificationBell.svelte @@ -30,7 +30,6 @@ const auth = getAuth(); - // the appview preview serves five rows and sends the rest to the full page const PREVIEW_LIMIT = 5; let readFilter = $state("unread"); @@ -66,13 +65,9 @@ notifications.map((n) => (n.uri in overrides ? { ...n, read: overrides[n.uri] } : n)) ); - // the badge counts everything unread, not the rows this filter shows const unreadCount = $derived(totalUnread); const badge = $derived(unreadCount > 99 ? "99+" : String(unreadCount)); - // the unread tab filters on the data as it loaded, never on the local read - // state, so toggling a row restyles it in place instead of dropping it out of - // the list under the cursor. const unreadOnLoad = $derived(new Set(notifications.filter((n) => !n.read).map((n) => n.uri))); const filtered = $derived( @@ -107,7 +102,6 @@ await markAllNotificationsRead(deliberi).catch(() => {}); }; - // the popover survives a client-side navigation unless something closes it const dismiss = (event: MouseEvent & { currentTarget: HTMLAnchorElement }) => { const popover = event.currentTarget.closest("[popover]"); if (popover instanceof HTMLElement) popover.hidePopover(); @@ -133,7 +127,6 @@ {/if} {/snippet} -