feat(city-map): Add 2D City Map with coordinates and agent presence

- Add migration 013_city_map_coordinates.sql with map coordinates, zones, and agents table
- Add /city/map API endpoint in city-service
- Add /city/agents and /city/agents/online endpoints
- Extend presence aggregator to include agents[] in snapshot
- Add AgentsSource for fetching agent data from DB
- Create CityMap component with interactive room tiles
- Add useCityMap hook for fetching map data
- Update useGlobalPresence to include agents
- Add map/list view toggle on /city page
- Add agent badges to room cards and map tiles
This commit is contained in:
Apple
2025-11-27 07:00:47 -08:00
parent 3de3c8cb36
commit 6bd769ef40
258 changed files with 1747 additions and 79 deletions

View File

@@ -90,3 +90,4 @@ export function usePasskeyLogin(): UsePasskeyLoginResult {

View File

@@ -83,3 +83,4 @@ export function usePasskeyRegister(): UsePasskeyRegisterResult {

View File

@@ -176,3 +176,4 @@ function Metric({ label, value }: { label: string; value: string }) {

View File

@@ -93,3 +93,4 @@ export function useMicroDAOs(): UseMicroDAOsResult {

View File

@@ -17,3 +17,4 @@ export async function getCitySnapshot(): Promise<CitySnapshot> {

View File

@@ -67,3 +67,4 @@ export function CityAgentPanel({ agent }: CityAgentPanelProps) {

View File

@@ -72,3 +72,4 @@ export function CityEventsFeed({ events }: CityEventsFeedProps) {

View File

@@ -60,3 +60,4 @@ export function CityLayout({ snapshot }: CityLayoutProps) {

View File

@@ -109,3 +109,4 @@ export function CityMetricsGrid({ metrics }: CityMetricsGridProps) {

View File

@@ -83,3 +83,4 @@ export function CityMicroDAOPanel({ microdao }: CityMicroDAOPanelProps) {

View File

@@ -74,3 +74,4 @@ export function CityNodesSummary({ nodes }: CityNodesSummaryProps) {

View File

@@ -53,3 +53,4 @@ export function CityQuestPanel({ quests }: CityQuestPanelProps) {

View File

@@ -102,3 +102,4 @@ export function CitySectorMap({ snapshot }: CitySectorMapProps) {

View File

@@ -51,3 +51,4 @@ export function useCityData() {

View File

@@ -131,3 +131,4 @@ export function useCityWebSocket(options: UseCityWebSocketOptions) {

View File

@@ -81,3 +81,4 @@ export interface CityQuestSummary {

View File

@@ -124,3 +124,4 @@ export function MessengerPage() {

View File

@@ -21,3 +21,4 @@ export async function createChannel(data: ChannelCreateInput): Promise<Channel>

View File

@@ -28,3 +28,4 @@ export async function getChannelMessages(

View File

@@ -23,3 +23,4 @@ export async function getChannels(microdaoId?: string): Promise<Channel[]> {

View File

@@ -24,3 +24,4 @@ export async function sendMessage(

View File

@@ -41,3 +41,4 @@ export function ChannelHeader({ channel, isConnected }: Props) {

View File

@@ -45,3 +45,4 @@ export function ChannelList({ channels, selectedChannelId, onSelectChannel }: Pr

View File

@@ -77,3 +77,4 @@ export function MessageComposer({ onSend, disabled }: Props) {

View File

@@ -63,3 +63,4 @@ export function MessageList({ messages, loading }: Props) {

View File

@@ -41,3 +41,4 @@ export function useChannels(microdaoId?: string) {

View File

@@ -60,3 +60,4 @@ export function useMessages(channelId: string) {

View File

@@ -110,3 +110,4 @@ export function useMessagingWebSocket(channelId: string): UseMessagingWebSocketR

View File

@@ -98,3 +98,4 @@ export interface WebSocketMessage {

View File

@@ -232,3 +232,4 @@ export const CosmosView = memo(Component);

View File

@@ -186,3 +186,4 @@ export function GalaxyView({ scene, onSelect }: GalaxyViewProps) {

View File

@@ -217,3 +217,4 @@ export function StarSystemView({ scene, onSelect }: StarSystemViewProps) {