german translation
This commit is contained in:
107
ayto/index.html
107
ayto/index.html
@@ -1,9 +1,9 @@
|
|||||||
<!DOCTYPE html>
|
<!DOCTYPE html>
|
||||||
<html lang="en" class="h-full" data-theme="mocha">
|
<html lang="de" class="h-full" data-theme="mocha">
|
||||||
<head>
|
<head>
|
||||||
<meta charset="UTF-8">
|
<meta charset="UTF-8">
|
||||||
<meta name="viewport" content="width=device-width, initial-scale=1.0">
|
<meta name="viewport" content="width=device-width, initial-scale=1.0">
|
||||||
<title>AYTO Matcher | Probability Engine</title>
|
<title>AYTO? Match-Rechner | Wer passt zu wem?</title>
|
||||||
<link rel="icon" href="/ayto/favicon.ico" type="image/x-icon">
|
<link rel="icon" href="/ayto/favicon.ico" type="image/x-icon">
|
||||||
<script src="https://cdn.tailwindcss.com"></script>
|
<script src="https://cdn.tailwindcss.com"></script>
|
||||||
<link rel="preconnect" href="https://fonts.googleapis.com">
|
<link rel="preconnect" href="https://fonts.googleapis.com">
|
||||||
@@ -77,16 +77,6 @@
|
|||||||
border: 1px solid rgba(0, 0, 0, 0.05);
|
border: 1px solid rgba(0, 0, 0, 0.05);
|
||||||
}
|
}
|
||||||
|
|
||||||
.step-pill {
|
|
||||||
transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
|
|
||||||
}
|
|
||||||
|
|
||||||
.step-pill.active {
|
|
||||||
background: var(--blue);
|
|
||||||
color: var(--base);
|
|
||||||
box-shadow: 0 0 15px rgba(137, 180, 250, 0.4);
|
|
||||||
}
|
|
||||||
|
|
||||||
.gradient-heading {
|
.gradient-heading {
|
||||||
background: linear-gradient(to right, var(--text), var(--lavender));
|
background: linear-gradient(to right, var(--text), var(--lavender));
|
||||||
-webkit-background-clip: text;
|
-webkit-background-clip: text;
|
||||||
@@ -117,9 +107,6 @@
|
|||||||
transform: translateY(-1px);
|
transform: translateY(-1px);
|
||||||
filter: brightness(1.05);
|
filter: brightness(1.05);
|
||||||
}
|
}
|
||||||
.btn-elegant:active:not(:disabled) {
|
|
||||||
transform: translateY(0);
|
|
||||||
}
|
|
||||||
|
|
||||||
.table-container::-webkit-scrollbar { width: 4px; height: 4px; }
|
.table-container::-webkit-scrollbar { width: 4px; height: 4px; }
|
||||||
.table-container::-webkit-scrollbar-thumb { background: var(--surface2); border-radius: 10px; }
|
.table-container::-webkit-scrollbar-thumb { background: var(--surface2); border-radius: 10px; }
|
||||||
@@ -137,10 +124,6 @@
|
|||||||
}
|
}
|
||||||
.animate-slide-in { animation: slideIn 0.5s ease-out forwards; }
|
.animate-slide-in { animation: slideIn 0.5s ease-out forwards; }
|
||||||
|
|
||||||
.card-glow:hover {
|
|
||||||
box-shadow: 0 0 25px rgba(203, 166, 247, 0.1);
|
|
||||||
}
|
|
||||||
|
|
||||||
/* Custom Dropdown Styling */
|
/* Custom Dropdown Styling */
|
||||||
select.input-elegant {
|
select.input-elegant {
|
||||||
appearance: none;
|
appearance: none;
|
||||||
@@ -178,18 +161,18 @@
|
|||||||
<header class="sticky top-0 z-50 glass-panel border-b border-white/5 py-4 px-6 mb-8 flex items-center justify-between">
|
<header class="sticky top-0 z-50 glass-panel border-b border-white/5 py-4 px-6 mb-8 flex items-center justify-between">
|
||||||
<div class="flex items-center gap-3">
|
<div class="flex items-center gap-3">
|
||||||
<div class="p-2 bg-gradient-to-br from-mauve to-blue rounded-xl shadow-lg">
|
<div class="p-2 bg-gradient-to-br from-mauve to-blue rounded-xl shadow-lg">
|
||||||
<i data-lucide="calculator" class="w-6 h-6 text-base"></i>
|
<i data-lucide="heart" class="w-6 h-6 text-base"></i>
|
||||||
</div>
|
</div>
|
||||||
<div>
|
<div>
|
||||||
<h1 class="text-lg font-extrabold tracking-tight">AYTO Matcher</h1>
|
<h1 class="text-lg font-extrabold tracking-tight">AYTO? Match-Rechner</h1>
|
||||||
<p class="text-[10px] font-bold text-overlay2 uppercase tracking-widest">Surjective probability engine</p>
|
<p class="text-[10px] font-bold text-overlay2 uppercase tracking-widest">Findet eure Perfect Matches</p>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<div class="flex items-center gap-4">
|
<div class="flex items-center gap-4">
|
||||||
<div class="hidden sm:flex items-center gap-2 px-3 py-1.5 glass-panel rounded-xl">
|
<div class="hidden sm:flex items-center gap-2 px-3 py-1.5 glass-panel rounded-xl">
|
||||||
<i data-lucide="cpu" class="w-4 h-4 text-blue"></i>
|
<i data-lucide="cpu" class="w-4 h-4 text-blue"></i>
|
||||||
<span class="text-xs font-bold text-subtext1">Rust API 1.85</span>
|
<span class="text-xs font-bold text-subtext1">Rust Engine 1.85</span>
|
||||||
</div>
|
</div>
|
||||||
<select id="theme-select" class="input-elegant py-1.5 px-3 text-xs font-bold border-none outline-none">
|
<select id="theme-select" class="input-elegant py-1.5 px-3 text-xs font-bold border-none outline-none">
|
||||||
<option value="mocha">Mocha</option>
|
<option value="mocha">Mocha</option>
|
||||||
@@ -211,30 +194,30 @@
|
|||||||
<div class="w-8 h-8 rounded-full bg-blue/20 text-blue flex items-center justify-center">
|
<div class="w-8 h-8 rounded-full bg-blue/20 text-blue flex items-center justify-center">
|
||||||
<i data-lucide="users" class="w-4 h-4"></i>
|
<i data-lucide="users" class="w-4 h-4"></i>
|
||||||
</div>
|
</div>
|
||||||
<h2 class="text-sm font-black uppercase tracking-[0.1em]">1. Season Setup</h2>
|
<h2 class="text-sm font-black uppercase tracking-[0.1em]">1. Wer ist in der Villa?</h2>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<div class="space-y-4 mb-6">
|
<div class="space-y-4 mb-6">
|
||||||
<div>
|
<div>
|
||||||
<label class="text-[10px] font-black text-overlay2 uppercase tracking-widest mb-2 block">Matcher Group (G1)</label>
|
<label class="text-[10px] font-black text-overlay2 uppercase tracking-widest mb-2 block">Gruppe A (Wählen zuerst)</label>
|
||||||
<textarea id="group1-names" rows="4" class="w-full input-elegant p-4 text-sm placeholder:text-surface2 scrollbar-hide" placeholder="E.g. Chris, Justin, Remy..."></textarea>
|
<textarea id="group1-names" rows="4" class="w-full input-elegant p-4 text-sm placeholder:text-surface2 scrollbar-hide" placeholder="Namen untereinander, z.B. Sophie, Lara..."></textarea>
|
||||||
</div>
|
</div>
|
||||||
<div>
|
<div>
|
||||||
<label class="text-[10px] font-black text-overlay2 uppercase tracking-widest mb-2 block">The Pool (G2)</label>
|
<label class="text-[10px] font-black text-overlay2 uppercase tracking-widest mb-2 block">Gruppe B (Die Auswahl)</label>
|
||||||
<textarea id="group2-names" rows="4" class="w-full input-elegant p-4 text-sm placeholder:text-surface2" placeholder="E.g. Kai, Jenna, Max..."></textarea>
|
<textarea id="group2-names" rows="4" class="w-full input-elegant p-4 text-sm placeholder:text-surface2" placeholder="Namen untereinander, z.B. Max, Leon..."></textarea>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<button id="setup-button" class="w-full btn-elegant py-4 bg-blue text-base hover:shadow-[0_0_20px_rgba(137,180,250,0.3)]">
|
<button id="setup-button" class="w-full btn-elegant py-4 bg-blue text-base hover:shadow-[0_0_20px_rgba(137,180,250,0.3)]">
|
||||||
INITIALIZE CALCULATOR
|
VILLA INITIALISIEREN
|
||||||
</button>
|
</button>
|
||||||
|
|
||||||
<div class="flex gap-2 mt-4">
|
<div class="flex gap-2 mt-4">
|
||||||
<button id="save-button" class="flex-1 btn-elegant py-2.5 bg-surface1 text-xs hover:bg-surface2 disabled:opacity-30 disabled:pointer-events-none" disabled>
|
<button id="save-button" class="flex-1 btn-elegant py-2.5 bg-surface1 text-xs hover:bg-surface2 disabled:opacity-30 disabled:pointer-events-none" disabled>
|
||||||
<span class="flex items-center justify-center gap-2"><i data-lucide="save" class="w-3 h-3"></i>SAVE</span>
|
<span class="flex items-center justify-center gap-2"><i data-lucide="save" class="w-3 h-3"></i>SICHERN</span>
|
||||||
</button>
|
</button>
|
||||||
<button id="load-button" class="flex-1 btn-elegant py-2.5 bg-surface1 text-xs hover:bg-surface2">
|
<button id="load-button" class="flex-1 btn-elegant py-2.5 bg-surface1 text-xs hover:bg-surface2">
|
||||||
<span class="flex items-center justify-center gap-2"><i data-lucide="upload-cloud" class="w-3 h-3"></i>LOAD</span>
|
<span class="flex items-center justify-center gap-2"><i data-lucide="upload-cloud" class="w-3 h-3"></i>LADEN</span>
|
||||||
</button>
|
</button>
|
||||||
<input type="file" id="file-loader" class="hidden" accept=".json">
|
<input type="file" id="file-loader" class="hidden" accept=".json">
|
||||||
</div>
|
</div>
|
||||||
@@ -249,7 +232,7 @@
|
|||||||
<div class="w-8 h-8 rounded-full bg-green/20 text-green flex items-center justify-center">
|
<div class="w-8 h-8 rounded-full bg-green/20 text-green flex items-center justify-center">
|
||||||
<i data-lucide="search" class="w-4 h-4"></i>
|
<i data-lucide="search" class="w-4 h-4"></i>
|
||||||
</div>
|
</div>
|
||||||
<h2 class="text-sm font-black uppercase tracking-[0.1em]">2. Truth Booth</h2>
|
<h2 class="text-sm font-black uppercase tracking-[0.1em]">2. Truth Booth Ergebnis</h2>
|
||||||
</div>
|
</div>
|
||||||
<form id="truth-booth-form" class="space-y-4">
|
<form id="truth-booth-form" class="space-y-4">
|
||||||
<div class="grid grid-cols-2 gap-3">
|
<div class="grid grid-cols-2 gap-3">
|
||||||
@@ -257,11 +240,11 @@
|
|||||||
<select id="tb-group2" class="input-elegant p-3 text-sm"></select>
|
<select id="tb-group2" class="input-elegant p-3 text-sm"></select>
|
||||||
</div>
|
</div>
|
||||||
<select id="tb-result" class="w-full input-elegant p-3 text-sm">
|
<select id="tb-result" class="w-full input-elegant p-3 text-sm">
|
||||||
<option value="no-match">❌ NO MATCH</option>
|
<option value="no-match">❌ KEIN MATCH</option>
|
||||||
<option value="match">💖 PERFECT MATCH</option>
|
<option value="match">💖 PERFECT MATCH</option>
|
||||||
</select>
|
</select>
|
||||||
<button type="submit" class="w-full btn-elegant py-3 bg-green/10 text-green border border-green/20 hover:bg-green/20">
|
<button type="submit" class="w-full btn-elegant py-3 bg-green/10 text-green border border-green/20 hover:bg-green/20">
|
||||||
ADD TB RESULT
|
TRUTH BOOTH HINZUFÜGEN
|
||||||
</button>
|
</button>
|
||||||
</form>
|
</form>
|
||||||
<div id="truth-booth-list" class="mt-6 space-y-2"></div>
|
<div id="truth-booth-list" class="mt-6 space-y-2"></div>
|
||||||
@@ -273,12 +256,12 @@
|
|||||||
<div class="w-8 h-8 rounded-full bg-mauve/20 text-mauve flex items-center justify-center">
|
<div class="w-8 h-8 rounded-full bg-mauve/20 text-mauve flex items-center justify-center">
|
||||||
<i data-lucide="flame" class="w-4 h-4"></i>
|
<i data-lucide="flame" class="w-4 h-4"></i>
|
||||||
</div>
|
</div>
|
||||||
<h2 class="text-sm font-black uppercase tracking-[0.1em]">3. Matchup Ceremony</h2>
|
<h2 class="text-sm font-black uppercase tracking-[0.1em]">3. Matching Night</h2>
|
||||||
</div>
|
</div>
|
||||||
<form id="ceremony-form">
|
<form id="ceremony-form">
|
||||||
<div id="ceremony-pairs-container" class="space-y-2 mb-6 max-h-[300px] overflow-y-auto pr-2 table-container"></div>
|
<div id="ceremony-pairs-container" class="space-y-2 mb-6 max-h-[300px] overflow-y-auto pr-2 table-container"></div>
|
||||||
<div class="bg-base/40 rounded-2xl p-4 mb-4 flex items-center justify-between border border-white/5">
|
<div class="bg-base/40 rounded-2xl p-4 mb-4 flex items-center justify-between border border-white/5">
|
||||||
<span class="text-[10px] font-black text-overlay2 uppercase tracking-[0.15em]">Correct Beams</span>
|
<span class="text-[10px] font-black text-overlay2 uppercase tracking-[0.15em]">Anzahl Lichter (Beams)</span>
|
||||||
<div class="flex items-center gap-4">
|
<div class="flex items-center gap-4">
|
||||||
<button type="button" onclick="ceremony_beams.stepDown()" class="w-8 h-8 flex items-center justify-center hover:bg-white/5 rounded-lg">
|
<button type="button" onclick="ceremony_beams.stepDown()" class="w-8 h-8 flex items-center justify-center hover:bg-white/5 rounded-lg">
|
||||||
<i data-lucide="minus" class="w-3 h-3 text-overlay1"></i>
|
<i data-lucide="minus" class="w-3 h-3 text-overlay1"></i>
|
||||||
@@ -290,7 +273,7 @@
|
|||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
<button type="submit" class="w-full btn-elegant py-4 bg-mauve/10 text-mauve border border-mauve/20 hover:bg-mauve/20">
|
<button type="submit" class="w-full btn-elegant py-4 bg-mauve/10 text-mauve border border-mauve/20 hover:bg-mauve/20">
|
||||||
RECORD CEREMONY
|
NACHT SPEICHERN
|
||||||
</button>
|
</button>
|
||||||
</form>
|
</form>
|
||||||
<div id="ceremony-list" class="mt-6 space-y-4"></div>
|
<div id="ceremony-list" class="mt-6 space-y-4"></div>
|
||||||
@@ -304,21 +287,21 @@
|
|||||||
<!-- Dashboard / Status -->
|
<!-- Dashboard / Status -->
|
||||||
<section id="status-dashboard" class="hidden animate-slide-in">
|
<section id="status-dashboard" class="hidden animate-slide-in">
|
||||||
<div class="grid grid-cols-1 md:grid-cols-2 gap-6">
|
<div class="grid grid-cols-1 md:grid-cols-2 gap-6">
|
||||||
<div class="glass-panel rounded-[32px] p-8 relative overflow-hidden card-glow transition-all duration-300">
|
<div class="glass-panel rounded-[32px] p-8 relative overflow-hidden shadow-xl">
|
||||||
<div class="absolute -right-8 -top-8 w-32 h-32 bg-blue/10 rounded-full blur-3xl"></div>
|
<div class="absolute -right-8 -top-8 w-32 h-32 bg-blue/10 rounded-full blur-3xl"></div>
|
||||||
<h3 class="text-[11px] font-black text-overlay2 uppercase tracking-[0.25em] mb-4">Valid Scenarios</h3>
|
<h3 class="text-[11px] font-black text-overlay2 uppercase tracking-[0.25em] mb-4">Verbleibende Möglichkeiten</h3>
|
||||||
<p id="total-possibilities" class="text-7xl font-black gradient-heading tracking-tighter">--</p>
|
<p id="total-possibilities" class="text-7xl font-black gradient-heading tracking-tighter">--</p>
|
||||||
<div class="mt-6 flex items-center gap-2">
|
<div class="mt-6 flex items-center gap-2">
|
||||||
<span class="w-2 h-2 rounded-full bg-blue animate-pulse"></span>
|
<span class="w-2 h-2 rounded-full bg-blue animate-pulse"></span>
|
||||||
<span class="text-[10px] font-bold text-blue uppercase tracking-widest">Live Engine Active</span>
|
<span class="text-[10px] font-bold text-blue uppercase tracking-widest">Rust-Engine berechnet live</span>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<div class="flex flex-col gap-6">
|
<div class="flex flex-col gap-6">
|
||||||
<button id="calculate-button" class="flex-1 btn-elegant bg-gradient-to-br from-blue to-sapphire text-base p-8 shadow-2xl hover:scale-[1.02] active:scale-[0.98] group">
|
<button id="calculate-button" class="flex-1 btn-elegant bg-gradient-to-br from-blue to-sapphire text-base p-8 shadow-2xl hover:scale-[1.02] active:scale-[0.98] group">
|
||||||
<div class="flex flex-col items-center gap-2">
|
<div class="flex flex-col items-center gap-2">
|
||||||
<i data-lucide="play" class="w-6 h-6 fill-base"></i>
|
<i data-lucide="refresh-cw" class="w-6 h-6 text-base group-hover:rotate-180 transition-transform duration-500"></i>
|
||||||
<span class="text-sm tracking-[0.2em]">RECALCULATE PROBABILITIES</span>
|
<span class="text-sm tracking-[0.2em]">WAHRSCHEINLICHKEITEN AKTUALISIEREN</span>
|
||||||
</div>
|
</div>
|
||||||
</button>
|
</button>
|
||||||
</div>
|
</div>
|
||||||
@@ -329,12 +312,12 @@
|
|||||||
<section id="grid-section" class="hidden glass-panel rounded-[40px] p-8 border border-white/5 animate-slide-in shadow-2xl relative">
|
<section id="grid-section" class="hidden glass-panel rounded-[40px] p-8 border border-white/5 animate-slide-in shadow-2xl relative">
|
||||||
<div class="flex items-center justify-between mb-8">
|
<div class="flex items-center justify-between mb-8">
|
||||||
<div>
|
<div>
|
||||||
<h2 class="text-2xl font-black tracking-tight mb-1">Probability Matrix</h2>
|
<h2 class="text-2xl font-black tracking-tight mb-1">Wahrscheinlichkeits-Matrix</h2>
|
||||||
<p class="text-[10px] font-bold text-overlay2 uppercase tracking-[0.2em]">Percentage chance per perfect match</p>
|
<p class="text-[10px] font-bold text-overlay2 uppercase tracking-[0.2em]">Chance auf Perfect Match pro Paarung</p>
|
||||||
</div>
|
</div>
|
||||||
<div class="flex gap-2">
|
<div class="flex gap-2">
|
||||||
<div class="px-3 py-1 bg-green/10 text-green rounded-full text-[10px] font-bold border border-green/20">CONFIRMED</div>
|
<div class="px-3 py-1 bg-green/10 text-green rounded-full text-[10px] font-bold border border-green/20">BESTÄTIGT</div>
|
||||||
<div class="px-3 py-1 bg-red/10 text-red rounded-full text-[10px] font-bold border border-red/20">IMPOSSIBLE</div>
|
<div class="px-3 py-1 bg-red/10 text-red rounded-full text-[10px] font-bold border border-red/20">UNMÖGLICH</div>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
@@ -353,11 +336,11 @@
|
|||||||
</div>
|
</div>
|
||||||
<div class="flex items-center gap-2">
|
<div class="flex items-center gap-2">
|
||||||
<div class="w-3 h-3 rounded bg-red opacity-50"></div>
|
<div class="w-3 h-3 rounded bg-red opacity-50"></div>
|
||||||
<span class="text-[10px] font-bold text-overlay1 uppercase tracking-widest">0% Impossible</span>
|
<span class="text-[10px] font-bold text-overlay1 uppercase tracking-widest">Ausgeschlossen</span>
|
||||||
</div>
|
</div>
|
||||||
<div class="flex items-center gap-2">
|
<div class="flex items-center gap-2">
|
||||||
<div class="w-3 h-3 rounded bg-peach"></div>
|
<div class="w-3 h-3 rounded bg-peach"></div>
|
||||||
<span class="text-[10px] font-bold text-overlay1 uppercase tracking-widest">Calculated Prob</span>
|
<span class="text-[10px] font-bold text-overlay1 uppercase tracking-widest">Wahrscheinlichkeit</span>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</section>
|
</section>
|
||||||
@@ -370,7 +353,7 @@
|
|||||||
<i data-lucide="alert-circle" class="w-4 h-4"></i>
|
<i data-lucide="alert-circle" class="w-4 h-4"></i>
|
||||||
</div>
|
</div>
|
||||||
<div>
|
<div>
|
||||||
<p class="text-xs font-black uppercase tracking-widest mb-1">Algorithm Warning</p>
|
<p class="text-xs font-black uppercase tracking-widest mb-1">Algorithmus Warnung</p>
|
||||||
<p id="error-text" class="text-[11px] font-medium opacity-90 leading-relaxed"></p>
|
<p id="error-text" class="text-[11px] font-medium opacity-90 leading-relaxed"></p>
|
||||||
</div>
|
</div>
|
||||||
<button onclick="errorMessage.classList.add('hidden')" class="opacity-40 hover:opacity-100 transition-opacity">
|
<button onclick="errorMessage.classList.add('hidden')" class="opacity-40 hover:opacity-100 transition-opacity">
|
||||||
@@ -385,8 +368,8 @@
|
|||||||
<div class="absolute inset-0 border-4 border-blue border-t-transparent rounded-full animate-spin"></div>
|
<div class="absolute inset-0 border-4 border-blue border-t-transparent rounded-full animate-spin"></div>
|
||||||
</div>
|
</div>
|
||||||
<div class="text-center">
|
<div class="text-center">
|
||||||
<p class="text-xs font-black text-blue tracking-[0.4em] uppercase mb-2">Analyzing Patterns</p>
|
<p class="text-xs font-black text-blue tracking-[0.4em] uppercase mb-2">Analysiere Muster</p>
|
||||||
<p class="text-[10px] text-overlay1 font-medium italic">Simulating surjective mappings in Rust...</p>
|
<p class="text-[10px] text-overlay1 font-medium italic">Berechne surjective Mappings in Rust...</p>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
@@ -465,8 +448,8 @@
|
|||||||
const g1 = g1NamesText.value.split('\n').map(s => s.trim()).filter(s => s.length > 0);
|
const g1 = g1NamesText.value.split('\n').map(s => s.trim()).filter(s => s.length > 0);
|
||||||
const g2 = g2NamesText.value.split('\n').map(s => s.trim()).filter(s => s.length > 0);
|
const g2 = g2NamesText.value.split('\n').map(s => s.trim()).filter(s => s.length > 0);
|
||||||
|
|
||||||
if (g1.length === 0 || g2.length === 0) return showError("Enter contestant names to begin.");
|
if (g1.length === 0 || g2.length === 0) return showError("Bitte gib die Namen der Teilnehmer ein.");
|
||||||
if (g1.length > g2.length) return showError("The matcher group must be smaller than or equal to the pool.");
|
if (g1.length > g2.length) return showError("Gruppe A darf nicht größer sein als Gruppe B.");
|
||||||
|
|
||||||
group1Names = g1;
|
group1Names = g1;
|
||||||
group2Names = g2;
|
group2Names = g2;
|
||||||
@@ -478,7 +461,7 @@
|
|||||||
populateSelectors();
|
populateSelectors();
|
||||||
populateCeremonyPairBuilder();
|
populateCeremonyPairBuilder();
|
||||||
|
|
||||||
initialPossibilitiesText.textContent = `${group1Names.length} Matches • ${group2Names.length} Potential Pools`;
|
initialPossibilitiesText.textContent = `${group1Names.length} in Gruppe A • ${group2Names.length} in Gruppe B`;
|
||||||
|
|
||||||
inputSections.classList.remove("hidden");
|
inputSections.classList.remove("hidden");
|
||||||
statusDashboard.classList.remove("hidden");
|
statusDashboard.classList.remove("hidden");
|
||||||
@@ -500,7 +483,7 @@
|
|||||||
<div class="flex items-center gap-3 p-2 group transition-all">
|
<div class="flex items-center gap-3 p-2 group transition-all">
|
||||||
<span class="text-[10px] font-black text-overlay2 w-16 truncate uppercase">${name}</span>
|
<span class="text-[10px] font-black text-overlay2 w-16 truncate uppercase">${name}</span>
|
||||||
<select data-g1-name="${name}" class="ceremony-pair-select flex-1 input-elegant p-2 text-xs">
|
<select data-g1-name="${name}" class="ceremony-pair-select flex-1 input-elegant p-2 text-xs">
|
||||||
<option value="">Choose match...</option>
|
<option value="">Paarung wählen...</option>
|
||||||
${group2Names.map(g2name => `<option value="${g2name}">${g2name}</option>`).join('')}
|
${group2Names.map(g2name => `<option value="${g2name}">${g2name}</option>`).join('')}
|
||||||
</select>
|
</select>
|
||||||
</div>
|
</div>
|
||||||
@@ -545,7 +528,7 @@
|
|||||||
<div class="flex justify-between items-center mb-4">
|
<div class="flex justify-between items-center mb-4">
|
||||||
<div class="flex items-center gap-2">
|
<div class="flex items-center gap-2">
|
||||||
<span class="w-6 h-6 rounded-lg bg-mauve/10 text-mauve flex items-center justify-center text-[10px] font-black">${index}</span>
|
<span class="w-6 h-6 rounded-lg bg-mauve/10 text-mauve flex items-center justify-center text-[10px] font-black">${index}</span>
|
||||||
<span class="text-[10px] font-black uppercase tracking-widest text-mauve">${ceremony.beams} Beams</span>
|
<span class="text-[10px] font-black uppercase tracking-widest text-mauve">${ceremony.beams} Lichter</span>
|
||||||
</div>
|
</div>
|
||||||
<button data-id="${ceremony.id}" class="remove-ceremony-btn opacity-0 group-hover:opacity-100 transition-all text-red"><i data-lucide="trash-2" class="w-3 h-3"></i></button>
|
<button data-id="${ceremony.id}" class="remove-ceremony-btn opacity-0 group-hover:opacity-100 transition-all text-red"><i data-lucide="trash-2" class="w-3 h-3"></i></button>
|
||||||
</div>
|
</div>
|
||||||
@@ -570,12 +553,12 @@
|
|||||||
|
|
||||||
for (const select of pairSelectors) {
|
for (const select of pairSelectors) {
|
||||||
const g2Name = select.value;
|
const g2Name = select.value;
|
||||||
if (!g2Name) return showError("Match everyone before recording the ceremony.");
|
if (!g2Name) return showError("Bitte wähle alle Paarungen für diese Nacht aus.");
|
||||||
selectedG2Names.push(g2Name);
|
selectedG2Names.push(g2Name);
|
||||||
pairs[select.dataset.g1Name] = g2Name;
|
pairs[select.dataset.g1Name] = g2Name;
|
||||||
}
|
}
|
||||||
|
|
||||||
if (new Set(selectedG2Names).size !== selectedG2Names.length) return showError("Each pool member can only be selected once.");
|
if (new Set(selectedG2Names).size !== selectedG2Names.length) return showError("Jede Person aus Gruppe B darf nur einmal gewählt werden.");
|
||||||
|
|
||||||
const beams = parseInt(ceremonyBeams.value, 10);
|
const beams = parseInt(ceremonyBeams.value, 10);
|
||||||
const ceremony = { id: Date.now(), pairs, beams };
|
const ceremony = { id: Date.now(), pairs, beams };
|
||||||
@@ -608,20 +591,20 @@
|
|||||||
body: JSON.stringify(payload)
|
body: JSON.stringify(payload)
|
||||||
});
|
});
|
||||||
|
|
||||||
if (!res.ok) throw new Error("Calculation engine error.");
|
if (!res.ok) throw new Error("Rechenfehler im Backend.");
|
||||||
const results = await res.json();
|
const results = await res.json();
|
||||||
|
|
||||||
totalPossibilitiesText.textContent = results.possibilities.toLocaleString();
|
totalPossibilitiesText.textContent = results.possibilities.toLocaleString();
|
||||||
|
|
||||||
if (results.possibilities === 0) {
|
if (results.possibilities === 0) {
|
||||||
showError("IMPOSSIBLE SCENARIO: The data entered is contradictory.");
|
showError("WIDERSPRUCH: Die eingegebenen Daten sind mathematisch unmöglich.");
|
||||||
probTableBody.innerHTML = '';
|
probTableBody.innerHTML = '';
|
||||||
probTableHead.innerHTML = '';
|
probTableHead.innerHTML = '';
|
||||||
} else {
|
} else {
|
||||||
displayProbabilityGrid(results.grid_data);
|
displayProbabilityGrid(results.grid_data);
|
||||||
}
|
}
|
||||||
} catch (e) {
|
} catch (e) {
|
||||||
showError("Could not reach the analysis server.");
|
showError("Verbindung zum Server fehlgeschlagen.");
|
||||||
} finally {
|
} finally {
|
||||||
hideLoading();
|
hideLoading();
|
||||||
}
|
}
|
||||||
@@ -661,7 +644,7 @@
|
|||||||
const blob = new Blob([JSON.stringify(state, null, 2)], { type: 'application/json' });
|
const blob = new Blob([JSON.stringify(state, null, 2)], { type: 'application/json' });
|
||||||
const url = URL.createObjectURL(blob);
|
const url = URL.createObjectURL(blob);
|
||||||
const a = document.createElement('a');
|
const a = document.createElement('a');
|
||||||
a.href = url; a.download = 'ayto-save.json';
|
a.href = url; a.download = 'ayto-daten.json';
|
||||||
a.click();
|
a.click();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user