Frontend: Aus main übernommen assets/ und includes/frontend-* synchronisiert in develop (CSS/Ergebnis/Formular).
All checks were successful
Deploy Workshop-Wahlen (DEV / PROD) / deploy (push) Successful in 13s
All checks were successful
Deploy Workshop-Wahlen (DEV / PROD) / deploy (push) Successful in 13s
This commit is contained in:
@@ -106,7 +106,28 @@ add_shortcode('konficastle_workshop_ergebnis', function($atts) {
|
||||
|
||||
ob_start();
|
||||
// Inline styles, angepasst an konfi-castle.com Look (dezent, grün/türkis Akzent)
|
||||
|
||||
echo '<style>
|
||||
.kc-result{font-family: -apple-system,BlinkMacSystemFont,"Segoe UI",Roboto,Helvetica,Arial,sans-serif;color:#222;}
|
||||
.kc-result h3{margin-top:0;text-align:center;color:#154a3b;}
|
||||
.kc-phase{margin:18px 0;padding:12px;border-radius:12px;background:#fbfffe;border:1px solid #e6f3ee;}
|
||||
/* Responsive Kachel-Layout: auto-fit with minmax so cards wrap based on viewport */
|
||||
.kc-result .kc-inner { max-width:1100px; margin:0 auto; padding:0 14px; box-sizing:border-box; }
|
||||
.kc-workshops-grid{display:grid;grid-template-columns:repeat(auto-fit, minmax(260px, 1fr));gap:14px;margin-top:12px;align-items:start;}
|
||||
.kc-workshop-card{background:#ffffff;border-radius:12px;overflow:hidden;border:1px solid #e9f4f0;box-shadow:0 2px 6px rgba(8,38,28,0.04);width:100%;}
|
||||
/* Zentrierter, prominenter Titelbereich in der Mitte oben der Kachel */
|
||||
.kc-workshop-card .title{background:linear-gradient(90deg, rgba(45,166,106,0.04), rgba(13,89,71,0.02));display:flex;flex-wrap:wrap;align-items:center;justify-content:center;padding:18px 12px;font-weight:800;color:#0d5947;font-size:1.06rem;letter-spacing:0.2px;border-bottom:1px solid rgba(229,244,240,0.8);gap:12px;}
|
||||
.kc-workshop-card .title .count{color:#6b6b6b;font-weight:600;font-size:0.9rem;margin-left:6px;}
|
||||
.kc-workshop-card .title .teamers{font-weight:600;color:#145a47;font-size:0.9rem;opacity:0.92;}
|
||||
.kc-workshop-card .title .teamers small{font-weight:500;color:#4c7a6a;opacity:0.9;font-size:0.85rem;margin-left:6px;}
|
||||
/* Content-Bereich unter dem Titel mit etwas mehr Luft */
|
||||
.kc-workshop-card .content{padding:12px 18px 18px 18px;}
|
||||
.kc-participants{display:grid;grid-template-columns:1fr 1fr;gap:6px 12px;font-size:0.95rem;color:#2b2b2b;}
|
||||
.kc-participant{padding:6px 8px;border-radius:6px;background:transparent;}
|
||||
.kc-participant.me{background:#fffbe6;border:1px solid #ffeab2;}
|
||||
.kc-notassigned{background:#fff6f6;border:1px solid #ffd2d2;padding:12px;border-radius:10px;margin-top:12px;}
|
||||
/* Auf sehr kleinen Bildschirmen die Teilnehmer ebenfalls einspaltig */
|
||||
@media(max-width:700px){ .kc-participants{grid-template-columns:1fr;} }
|
||||
</style>';
|
||||
|
||||
echo '<div class="kc-result">';
|
||||
echo '<h3>Ergebnis für diese Wahl</h3>';
|
||||
@@ -176,19 +197,23 @@ add_shortcode('konficastle_workshop_ergebnis', function($atts) {
|
||||
}
|
||||
|
||||
echo '<div class="kc-workshop-card">';
|
||||
// Teamernamen (falls vorhanden) anzeigen - mit Phase-Key
|
||||
$teamer_html = '';
|
||||
$teamer_key = intval($d['id']) . '_' . intval($phase);
|
||||
if (!empty($ws_teamers[$teamer_key])) {
|
||||
$teamer_html = '<span class="teamers">'.esc_html(implode(', ', $ws_teamers[$teamer_key])).'</span>';
|
||||
}
|
||||
echo '<div class="title">'.esc_html($ws_name).($teamer_html ? ' '.$teamer_html : '').'<span class="count">('.$count.' TN)</span></div>';
|
||||
echo '<div class="title">'.esc_html($ws_name).' '. $teamer_html .'<span class="count">('.$count.' TN)</span></div>';
|
||||
echo '<div class="content">';
|
||||
echo '<div class="kc-participants">';
|
||||
foreach($teilnehmer as $t) {
|
||||
$is_me = in_array(intval($t->id), $my_ids);
|
||||
$name = esc_html($t->vorname.' '.$t->nachname);
|
||||
echo '<span class="kc-participant'.($is_me ? ' me' : '').'">'. $name .'</span>';
|
||||
$label = $name . ' <span style="color:#6b6b6b;font-size:85%;">('.intval($t->phase).')</span>';
|
||||
echo '<div class="kc-participant'.($is_me ? ' me' : '').'">'. $label .'</div>';
|
||||
}
|
||||
echo '</div>';
|
||||
echo '</div>'; // kc-participants
|
||||
echo '</div>'; // content
|
||||
echo '</div>';
|
||||
}
|
||||
|
||||
@@ -200,11 +225,11 @@ add_shortcode('konficastle_workshop_ergebnis', function($atts) {
|
||||
if (!empty($nicht_zugeteilt)) {
|
||||
echo '<div class="kc-notassigned">';
|
||||
echo '<b>Nicht zugeteilt:</b><br>';
|
||||
echo '<div style="margin:6px 0 0 18px;">';
|
||||
echo '<ul style="margin:6px 0 0 18px;">';
|
||||
foreach($nicht_zugeteilt as $t) {
|
||||
echo '<span style="display:inline-block;white-space:nowrap;margin-right:12px;">'.esc_html($t->vorname.' '.$t->nachname).'</span>';
|
||||
echo '<li>'.esc_html($t->vorname.' '.$t->nachname).' (Phase '.intval($t->phase).')</li>';
|
||||
}
|
||||
echo '</div></div>';
|
||||
echo '</ul></div>';
|
||||
}
|
||||
|
||||
echo '</div>'; // kc-result
|
||||
|
||||
Reference in New Issue
Block a user