namespace Collaboration.Hubs; /// Route synchronization payload — sent when host navigates. public record RouteSyncPayload( Guid SessionId, Guid TriggeredByUserId, string Route, // Angular router URL string? ModuleCode, string? RecordId, string? RecordLabel, long Timestamp ); /// Cursor position — sent frequently, kept minimal. public record CursorPayload( Guid SessionId, Guid UserId, string CursorColor, double XPercent, // % of viewport width double YPercent, // % of viewport height string? ElementPath, // CSS selector hint for sticky cursor long Timestamp ); /// Form field state sync. public record FormSyncPayload( Guid SessionId, Guid TriggeredByUserId, string FormId, // Unique form identifier within the route string FieldPath, // Dot-notation: "invoice.lineItems[0].amount" object? Value, long Timestamp ); /// Chat message within a session. public record ChatMessage( Guid SessionId, Guid FromUserId, string FromDisplayName, string CursorColor, string Text, DateTime SentAt ); /// Annotation drawn on screen — coordinates relative to viewport. public record AnnotationPayload( Guid SessionId, Guid FromUserId, string CursorColor, string Type, // "draw" | "highlight" | "arrow" | "clear" string? Data, // SVG path data or JSON geometry long Timestamp ); /// Heartbeat to keep session alive and confirm connection. public record HeartbeatPayload( Guid SessionId, long ClientTimestamp );