Release Healer Man 0.1.32
This commit is contained in:
1 parent
d3d6aaebdb
commit
6dcb1034e5
102 files changed
+10772
-788
No files matched your search
@@ -1,4 +1,4 @@
|
||||
import { lazy, Suspense, useState, type CSSProperties } from "react";
|
||||
import { useState, type CSSProperties } from "react";
|
||||
import { classById, FACTIONS, raceById } from "../app/characterCatalog";
|
||||
import type { CharacterProfile } from "../app/types";
|
||||
import { useShellStore } from "../app/shellStore";
|
||||
@@ -28,14 +28,8 @@ import { ActionBar, type ActionBarItem, type ActionBarItems } from "./ActionBar"
|
||||
import { DungeonMapGraphic } from "./DungeonMapGraphic";
|
||||
import { ExperienceBar } from "./ExperienceBar";
|
||||
import { BrandMark, FrontSurface } from "./FrontSurface";
|
||||
import {
|
||||
getLoadedCompanionManastormPanel,
|
||||
loadCompanionManastormPanel,
|
||||
} from "./gameplayResources";
|
||||
|
||||
const CompanionManastormPanel = lazy(() => loadCompanionManastormPanel().then((module) => ({
|
||||
default: module.CompanionManastormPanel,
|
||||
})));
|
||||
import { ShelvedCompanionPanel } from "@shelvedCompanionPanel";
|
||||
import { SHELVED_MODES_ENABLED } from "../app/releaseFeatures";
|
||||
|
||||
function safePercent(current: number, maximum: number): number {
|
||||
if (!Number.isFinite(current) || !Number.isFinite(maximum) || maximum <= 0) return 0;
|
||||
@@ -158,7 +152,6 @@ export function CompanionPanel({ snapshot, send, preferControllerBinds = false }
|
||||
}) {
|
||||
const selected = snapshot.characters.find((character) => character.id === snapshot.selectedCharacterId) ?? null;
|
||||
const active = snapshot.activeCharacter ?? selected;
|
||||
const PreloadedCompanionManastormPanel = getLoadedCompanionManastormPanel();
|
||||
|
||||
if (snapshot.phase === "login") {
|
||||
return (
|
||||
@@ -289,7 +282,7 @@ export function CompanionPanel({ snapshot, send, preferControllerBinds = false }
|
||||
<footer className="companion-actions">
|
||||
<button type="button" onClick={() => send({ name: "returnToCharacters" })}>Change character</button>
|
||||
<button type="button" disabled={!selected} onClick={() => send({ name: "openDungeons" })}>Dungeons</button>
|
||||
<button type="button" disabled={!selected} onClick={() => send({ name: "openManastorms" })}>Manastorms</button>
|
||||
{SHELVED_MODES_ENABLED ? <button type="button" disabled={!selected} onClick={() => send({ name: "openManastorms" })}>Manastorms</button> : null}
|
||||
</footer>
|
||||
</FrontSurface>
|
||||
);
|
||||
@@ -300,13 +293,7 @@ export function CompanionPanel({ snapshot, send, preferControllerBinds = false }
|
||||
}
|
||||
|
||||
if (snapshot.phase === "manastorms") {
|
||||
return PreloadedCompanionManastormPanel ? (
|
||||
<PreloadedCompanionManastormPanel selected={selected} send={send} />
|
||||
) : (
|
||||
<Suspense fallback={<FrontSurface bottom className="companion-panel" ariaLabel="Loading Manastorm companion screen"><span>Loading Manastorm data…</span></FrontSurface>}>
|
||||
<CompanionManastormPanel selected={selected} send={send} />
|
||||
</Suspense>
|
||||
);
|
||||
return <ShelvedCompanionPanel selected={selected} send={send} />;
|
||||
}
|
||||
|
||||
const race = active ? raceById(active.raceId) : null;
|
||||
|
||||
Reference in new issue
Block a user