import type { Adapters } from "../contexts/adapter-context.js"; import { loadEncounter, saveEncounter, } from "../persistence/encounter-storage.js"; import { loadPlayerCharacters, savePlayerCharacters, } from "../persistence/player-character-storage.js"; import { loadUndoRedoStacks, saveUndoRedoStacks, } from "../persistence/undo-redo-storage.js"; import * as bestiaryCache from "./bestiary-cache.js"; import * as bestiaryIndex from "./bestiary-index-adapter.js"; import * as pf2eBestiaryIndex from "./pf2e-bestiary-index-adapter.js"; export const productionAdapters: Adapters = { encounterPersistence: { load: loadEncounter, save: saveEncounter, }, undoRedoPersistence: { load: loadUndoRedoStacks, save: saveUndoRedoStacks, }, playerCharacterPersistence: { load: loadPlayerCharacters, save: savePlayerCharacters, }, bestiaryCache: { cacheSource: bestiaryCache.cacheSource, isSourceCached: bestiaryCache.isSourceCached, getCachedSources: bestiaryCache.getCachedSources, clearSource: bestiaryCache.clearSource, clearAll: bestiaryCache.clearAll, loadAllCachedCreatures: bestiaryCache.loadAllCachedCreatures, }, bestiaryIndex: { loadIndex: bestiaryIndex.loadBestiaryIndex, getAllSourceCodes: bestiaryIndex.getAllSourceCodes, getDefaultFetchUrl: bestiaryIndex.getDefaultFetchUrl, getSourceDisplayName: bestiaryIndex.getSourceDisplayName, }, pf2eBestiaryIndex: { loadIndex: pf2eBestiaryIndex.loadPf2eBestiaryIndex, getAllSourceCodes: pf2eBestiaryIndex.getAllPf2eSourceCodes, getDefaultFetchUrl: pf2eBestiaryIndex.getDefaultPf2eFetchUrl, getSourceDisplayName: pf2eBestiaryIndex.getPf2eSourceDisplayName, }, };