A stills wall with a full-screen viewer
The stills wall from the film pages: stills are laid out in six columns, and a click opens a full-screen viewer. It is a native dialog, the still is as large as the viewport allows, and the arrow keys, the buttons or a swipe change the still.
Source · GitHubPress any still to open the full-screen viewer. Use the arrow keys, the buttons on either side or a swipe to change the still; press Escape, the backdrop or the close button to leave.
Each still is a link to its image file, so without JavaScript a click opens that image directly. With JavaScript, the click opens the full-screen viewer instead: dialog.showModal() takes focus and makes the background unclickable, page scrolling uses the site's shared lock (Lenis stop + overflow hidden, then scrollTo → start → refresh on close), and after closing, focus returns to the still that opened it. Opening is a 0.35s fade with the picture scaling from 0.96 to 1; changing the still slides the next one in by 24px from the direction of travel; closing fades out on power2.in and then calls close(). State is cleaned up only in the native close event, so Escape, the backdrop and the button all run the same code. The stills and captions here are from the page for 大话西游, including the rights line.
Source
Source files on GitHub:











