/**
 * Browser-safe exports for @open-matrix/federation
 */

// Core utilities
export * from './topics';
export * from './uri';
export * from './mxesc1';
export * from './wire_codec';
export * from './ulid';

// Envelope handling
export * from './envelope';
export type {
  CrossRealmEnvelopeLegacy as CrossRealmEnvelope,
  ReplyEnvelopeLegacy as ReplyEnvelope,
} from './envelope';
export * from './envelope_codec';
export * from './wire_profile';

// Transport (browser-safe only)
export * from './transport/base';
export * from './transport/inmem';
// Explicit re-exports for bundler compatibility (Vite/Rollup CJS interop)
export { InMemoryExactBroker, InMemoryFilterBroker, topicMatchesFilter } from './transport/inmem';

// Runtime
export * from './federation_peer';
export * from './runtime/internal_messages';
export * from './runtime/subscription_forwarder';
export * from './runtime/browser_router_factory';

// Identity (isValidRoot, RootId, etc.)
export * from './identity';

// Cross-realm client
export * from './cross_realm_client';

// Security
export * from './security/replay';
export * from './security/ratelimit';
export * from './security/policy';
export * from './security/principal';

// Tab root generation (browser-specific)
export * from './tab_realm';

// Root identity (new canonical names + backward compat)
export * from './root_identity';
export * from './realm_identity';
