--- import { formatLastSeenTime, PRESENCE_BANDS, PRESENCE_PARTS, type ActivityFeed } from "@/lib/activity"; import MediaViewer from "./MediaViewer.astro"; import ActivityRows from "./ActivityRows.astro"; import StoryAvatar from "@/components/StoryAvatar.astro"; import StoryViewer from "@/components/StoryViewer.astro"; import type { BlueskyActivity } from "@/lib/activity/types"; import identity from "../../../atproto.config.json"; interface Props { feed?: ActivityFeed; } const { feed } = Astro.props; const lastSeenText = feed?.lastSeenAt ? formatLastSeenTime(feed.lastSeenAt) : null; const presence = PRESENCE_PARTS[feed?.presence ?? "unknown"]; const currentBand = PRESENCE_BANDS.find(({ state }) => state === feed?.presence); const presenceDetail = currentBand ? `${currentBand.within} ago` : "not checked for a day"; // The picture from one of kualta's own posts in the feed; without one, the story ring's script reads it from Bluesky. const ownPost = feed?.events.find( (event): event is BlueskyActivity => event.source === "bluesky" && event.post.author.did === identity.did, ); const author = { name: "kualta", avatar: ownPost?.post.author.avatar }; --- Loading recent activity {[1, 2, 3].map(() => ( ))} {presence.lead}{" "} {presence.status} When was kualta last seen {presenceDetail} {lastSeenText} signals delayed