Audio Player 12 block design & features
AudioPlayer12 is a weekly top songs chart built with shadcn/ui and Tailwind CSS, styled like the charts page of a music streaming app. A heading and short line sit beside a this week and last week toggle, above a preview bar and a twelve row list with rank, movement, cover, title and artist, weeks on the chart, peak position and track length.
Movement shows as small coloured text, with a green up arrow and number for climbers, a red down arrow for fallers, New for fresh entries and a dash for songs that held their place. The top three rows are larger with bigger covers and ranks. Clicking a row plays a 30 second preview, swapping its rank for an animated equaliser and drawing a thin progress line along the bottom of the row, and when a preview ends the next row starts. Switching weeks slides every song to its new position, fading out songs that dropped off and bringing in new ones.
Previews start on row one shortly after load, and the chart flips to last week once after a few seconds so the rows animate in previews, unless someone has already interacted. Every song can take an audioSrc for real preview clips. Reduced motion visitors see a paused chart with still bars and instant reordering. On phones the weeks and peak columns hide and the seek bar collapses so the list stays readable, which suits music magazines, radio stations and label sites.
