import type { Map, MapObject, Tile } from '@/application/types' import { BaseStorage } from '@/storage/baseStorage' export class MapStorage extends BaseStorage { constructor() { super('maps', 'id, name, createdAt, updatedAt') } } export class TileStorage extends BaseStorage { constructor() { super('tiles', 'id, name, createdAt, updatedAt') } } export class MapObjectStorage extends BaseStorage { constructor() { super('mapObjects', 'id, name, createdAt, updatedAt') } } export class SpriteStorage extends BaseStorage { constructor() { super('sprites', 'id, name, createdAt, updatedAt') } } export class CharacterTypeStorage extends BaseStorage { constructor() { super('characterTypes', 'id, name, createdAt, updatedAt') } async getSpriteId(characterTypeId: string) { const characterType = await this.getById(characterTypeId) return characterType?.sprite } } export class CharacterHairStorage extends BaseStorage { constructor() { super('characterHairs', 'id, name, createdAt, updatedAt') } async getSpriteId(characterTypeId: string) { const characterType = await this.getById(characterTypeId) return characterType?.sprite } } export class SoundStorage extends BaseStorage<{ id: string; name: string; base64: string }> { constructor() { super('sounds', 'id, name, createdAt, updatedAt') } }