Export and import encounter, undo/redo history, and player characters as a downloadable .json file. Export/import actions are in the action bar overflow menu. Import validates using existing rehydration functions and shows a confirmation dialog when replacing a non-empty encounter. Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
133 lines
3.0 KiB
TypeScript
133 lines
3.0 KiB
TypeScript
export {
|
|
type AddCombatantSuccess,
|
|
addCombatant,
|
|
type CombatantInit,
|
|
} from "./add-combatant.js";
|
|
export { type AdjustHpSuccess, adjustHp } from "./adjust-hp.js";
|
|
export { advanceTurn } from "./advance-turn.js";
|
|
export { resolveCreatureName } from "./auto-number.js";
|
|
export {
|
|
type ClearEncounterSuccess,
|
|
clearEncounter,
|
|
} from "./clear-encounter.js";
|
|
export {
|
|
CONDITION_DEFINITIONS,
|
|
type ConditionDefinition,
|
|
type ConditionId,
|
|
getConditionDescription,
|
|
getConditionsForEdition,
|
|
type RulesEdition,
|
|
VALID_CONDITION_IDS,
|
|
} from "./conditions.js";
|
|
export {
|
|
type CreatePlayerCharacterSuccess,
|
|
createPlayerCharacter,
|
|
} from "./create-player-character.js";
|
|
export {
|
|
type BestiaryIndex,
|
|
type BestiaryIndexEntry,
|
|
type BestiarySource,
|
|
type Creature,
|
|
type CreatureId,
|
|
creatureId,
|
|
type DailySpells,
|
|
type LegendaryBlock,
|
|
proficiencyBonus,
|
|
type SpellcastingBlock,
|
|
type TraitBlock,
|
|
} from "./creature-types.js";
|
|
export {
|
|
type DeletePlayerCharacterSuccess,
|
|
deletePlayerCharacter,
|
|
} from "./delete-player-character.js";
|
|
export {
|
|
type EditCombatantSuccess,
|
|
editCombatant,
|
|
} from "./edit-combatant.js";
|
|
export {
|
|
type EditPlayerCharacterSuccess,
|
|
editPlayerCharacter,
|
|
} from "./edit-player-character.js";
|
|
export type {
|
|
AcSet,
|
|
CombatantAdded,
|
|
CombatantRemoved,
|
|
CombatantUpdated,
|
|
ConcentrationEnded,
|
|
ConcentrationStarted,
|
|
ConditionAdded,
|
|
ConditionRemoved,
|
|
CurrentHpAdjusted,
|
|
DomainEvent,
|
|
EncounterCleared,
|
|
InitiativeSet,
|
|
MaxHpSet,
|
|
PlayerCharacterCreated,
|
|
PlayerCharacterDeleted,
|
|
PlayerCharacterUpdated,
|
|
RoundAdvanced,
|
|
RoundRetreated,
|
|
TempHpSet,
|
|
TurnAdvanced,
|
|
TurnRetreated,
|
|
} from "./events.js";
|
|
export type { ExportBundle } from "./export-bundle.js";
|
|
export { deriveHpStatus, type HpStatus } from "./hp-status.js";
|
|
export {
|
|
calculateInitiative,
|
|
formatInitiativeModifier,
|
|
type InitiativeResult,
|
|
} from "./initiative.js";
|
|
export {
|
|
type PlayerCharacter,
|
|
type PlayerCharacterId,
|
|
type PlayerCharacterList,
|
|
type PlayerColor,
|
|
type PlayerIcon,
|
|
playerCharacterId,
|
|
VALID_PLAYER_COLORS,
|
|
VALID_PLAYER_ICONS,
|
|
} from "./player-character-types.js";
|
|
export {
|
|
type RemoveCombatantSuccess,
|
|
removeCombatant,
|
|
} from "./remove-combatant.js";
|
|
export { retreatTurn } from "./retreat-turn.js";
|
|
export {
|
|
type RollMode,
|
|
rollInitiative,
|
|
selectRoll,
|
|
} from "./roll-initiative.js";
|
|
export { type SetAcSuccess, setAc } from "./set-ac.js";
|
|
export { type SetHpSuccess, setHp } from "./set-hp.js";
|
|
export {
|
|
type SetInitiativeSuccess,
|
|
setInitiative,
|
|
} from "./set-initiative.js";
|
|
export { type SetTempHpSuccess, setTempHp } from "./set-temp-hp.js";
|
|
export {
|
|
type ToggleConcentrationSuccess,
|
|
toggleConcentration,
|
|
} from "./toggle-concentration.js";
|
|
export {
|
|
type ToggleConditionSuccess,
|
|
toggleCondition,
|
|
} from "./toggle-condition.js";
|
|
export {
|
|
type Combatant,
|
|
type CombatantId,
|
|
combatantId,
|
|
createEncounter,
|
|
type DomainError,
|
|
type Encounter,
|
|
isDomainError,
|
|
} from "./types.js";
|
|
export {
|
|
clearHistory,
|
|
EMPTY_UNDO_REDO_STATE,
|
|
pushUndo,
|
|
redo,
|
|
type UndoRedoState,
|
|
undo,
|
|
} from "./undo-redo.js";
|