import type { Action, Config, Stat } from "../types.ts"; const element = document.getElementById("pet-config"); if (!element?.textContent) throw new Error("Missing #pet-config JSON configuration"); export const CFG: Config = JSON.parse(element.textContent); export const DEBUG = new URLSearchParams(location.search).get("debug") === "1" || location.hash.slice(1) === "debug"; export { DAY, HOUR, MIN } from "./utils.ts"; export const WANT_ICON: Record = { snack: "cookie", play: "ball", bath: "bubbles", sleep: "moon", pats: "heart", medicine: "pill", }; export const OFFER_ICON: Record = { bath: "bubbles", medicine: "pill", play: "ball", }; export const NAME_IDEAS = [ "Mochi", "Pip", "Bean", "Tofu", "Nori", "Puddle", "Sprout", "Pebble", "Momo", "Kiwi", "Dumpling", "Boba", "Miso", "Clover", "Noodle", "Gumdrop", "Yuzu", "Biscuit", "Fig", "Bun", ]; // Display order of the meters. Saves can arrive with keys in another order // (the host serializes them alphabetically), so never render by key order. export const STATS: readonly Stat[] = ["tummy", "fun", "energy", "clean"]; export const FEATURE_TEXT: Record = {}; export const ACT_NEEDS: Partial> = {};