/**
 * @bobfrankston/mailx-store
 * Two-layer storage: SQLite metadata index + pluggable body backend.
 */

export { MailxDB } from "./db.js";
export { FileMessageStore } from "./file-store.js";
export { parseSerial, prewarmParseWorker } from "./parse-serial.js";
export { sniffAndFixCharset, fixCharsetDeclString } from "./charset.js";

// Store — the nexus. Owns DB + .eml files + operations + bus.
export { Store } from "./store.js";
export type { StoreMessage } from "./store.js";

// Store-event bus lives in `@bobfrankston/mailx-bus` so the browser-side
// store (mailx-store-web) and the desktop-side store (this package) share
// the same bus. Re-exported here so existing callers don't have to learn
// the new import path.
export { StoreBus, storeBus } from "@bobfrankston/mailx-bus";
export type { StoreEvent, StoreEventKind, StoreEventHandler } from "@bobfrankston/mailx-bus";
