mirror of
https://github.com/rommapp/romm.git
synced 2026-11-30 18:42:34 +01:00
Stop forcing a fixed box ratio on gallery covers. Cards now share one height and vary in width to match each cover image's natural aspect, with no cropping. - GameCover measures the rendered image's natural ratio on load and drives its own aspect-ratio from it (style ratio kept only as a pre-load seed); emits the measured ratio. - GameCard default (gallery) card: fixed art height, natural width; size tiers and hero keep their fixed footprints. Forwards the ratio event. - Gallery grid becomes flow-packed wrapping rows: useGalleryVirtualItems greedily packs same-height / natural-width cards per row (ragged right), measuring ratios client-side (cached by rom id, debounced re-pack). Row height stays uniform so RVirtualScroller, AlphaStrip, scroll restoration and grid-nav are unchanged. - useResponsiveColumns additionally exposes usableWidth for width packing. - Unit tests for packFlowRows. Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>