Add Void difficulty and publish changelogs
Some checks failed
Deploy MineGeo to Dokploy / deploy (push) Failing after 3m40s

This commit is contained in:
2026-10-20 14:05:01 +05:00
parent 3ba398a838
commit de0e891b62
37 changed files with 995 additions and 65 deletions

View File

@@ -34,6 +34,8 @@ export function StartGame({
compass: boolean;
coordinates: boolean;
mapZoom: boolean;
mapPan: boolean;
timerVisible: boolean;
scoring: ScoringMode;
}>(difficultyRuleDefaults),
[savingDifficulty, setSavingDifficulty] = useState(false),
@@ -63,6 +65,8 @@ export function StartGame({
}, []);
const options: DifficultyPreset[] = [
...Object.entries(difficulties).map(([id, preset]) => ({
...difficultyRuleDefaults,
...preset,
id,
name: preset.label,
seconds: preset.seconds,
@@ -169,7 +173,10 @@ export function StartGame({
<button
key={option.id}
aria-pressed={difficulty === option.id}
className={difficulty === option.id ? "selected" : ""}
className={[
difficulty === option.id ? "selected" : "",
option.id === "void" ? "difficulty-void" : "",
].join(" ")}
disabled={loading}
onClick={() => setDifficulty(option.id)}
>
@@ -185,7 +192,7 @@ export function StartGame({
<ZoomIn size={13} />
{option.zoom ? t("Zoom allowed") : t("No zoom")}
</span>
{!(option.id in difficulties) && (
{(!(option.id in difficulties) || option.id === "void") && (
<span>
{t(
option.scoring === "strict"
@@ -197,6 +204,9 @@ export function StartGame({
· {t(option.pan === false ? "Fixed view" : "Panning allowed")}
</span>
)}
{option.id === "void" && (
<span>{t("Hardest · No compass · Fixed map")}</span>
)}
</button>
))}
</div>
@@ -238,9 +248,9 @@ export function StartGame({
<input
id="custom-difficulty-seconds"
type="number"
min={15}
min={5}
max={600}
step={15}
step={5}
value={difficultySeconds}
onChange={(event) =>
setDifficultySeconds(Number(event.target.value))
@@ -265,6 +275,8 @@ export function StartGame({
["compass", "Show north indicator"],
["coordinates", "Show guess coordinates"],
["mapZoom", "Allow guess-map zoom"],
["mapPan", "Allow guess-map panning"],
["timerVisible", "Show round countdown"],
] as const
).map(([key, label]) => (
<label className="difficulty-builder-zoom" key={key}>