fix: KöPi - Bilder maxHeight 220px, nie abgeschnitten

This commit is contained in:
2026-07-09 15:03:42 +02:00
parent 0ba26c36ca
commit b53f58956a

View File

@@ -36,9 +36,9 @@ function OfferCard({ offer }) {
}}> }}>
{/* Bild oben, volle Breite */} {/* Bild oben, volle Breite */}
{offer.image && ( {offer.image && (
<div style={{ margin:'-12px -14px 8px -14px', borderRadius:'8px 8px 0 0', overflow:'hidden', background:'#1a1a1a', display:'flex', alignItems:'center', justifyContent:'center' }}> <div style={{ margin:'-12px -14px 8px -14px', borderRadius:'8px 8px 0 0', overflow:'hidden', background:'#1a1a1a', display:'flex', alignItems:'center', justifyContent:'center', maxHeight:220 }}>
<img src={offer.image} alt="König Pilsener" <img src={offer.image} alt="König Pilsener"
style={{ width:'100%', height:'auto', display:'block' }} style={{ maxWidth:'100%', maxHeight:220, width:'auto', height:'auto', display:'block', objectFit:'contain' }}
onError={e => { e.target.parentElement.style.display='none'; }} onError={e => { e.target.parentElement.style.display='none'; }}
/> />
</div> </div>