[UPDATED] A UI redesign for perchance.org/generators โ€” devs, please use this code to update it

I redesigned the UI of the Recently Updated Generators, please use this code to update generators.

Redesign: https://perchance.org/nexora-better-generators What changed, version by version: https://perchance.org/nexora-better-generators#/changelog

To be clear about what this is: it's not a new hub or a new feed. It's the same generator list, the same comment threads โ€” I only changed the interface on top of it. Anyone can copy the code and drop it into the official page.

What the UI change does

  • Cards that tell you what a generator is.
    • Each card leads with the generator's human-readable title ($meta.title) and shows the slug underneath, plus views, "updated x ago" and the generator's tags. Two media icons under the timestamp preview its artwork (๐Ÿ–ผ๏ธ) and its live screenshot (๐Ÿ“ท) โ€” so you can see what a text-to-image generator actually produces before clicking it. Hovering swaps in the live screenshot too, and on a phone a tap opens and closes the same preview.
  • Discovery instead of a wall of cards.
    • On desktop there are two sticky side panels: ๐Ÿ”ฅ Most viewed on the left, ๐Ÿ“ˆ Trending on the right. Both collapse to a slim rail if you'd rather have the grid space.
  • A Trending feed that rotates.
    • Generators fall into three buckets โ€” proven (real engagement), fresh (new in the last 7 days), wildcards (older, low-activity) โ€” and the panel is filled one slot at a time with a weighted random draw (~30% / 40% / 30%), ordered by a 7-term score. It's redrawn on every page load, or on demand from the โŸณ button beside the heading, so the same handful of generators can't permanently freeze everyone else out. The trending algorithm is adapted from https://perchance.org/nexora-hub and the whole thing is tuneable via TRENDING_CONFIG.
  • The whole catalogue, without the wait.
    • The newest listings paint first, the rest of the ~1700 soon after, and the remainder pages in as you scroll โ€” so the feed is the full set without a long blank load.
  • Search that filters the list as you type
    • (names, titles, descriptions, tags). The search button still opens the Google site-search.
  • A "N new generators โ€” click to refresh" pill
    • when listings appear while you're reading, instead of the feed jumping under you.
  • Comments stay where they belong.
    • All four channels (General, Feedback, Sharing, Off topic) are hosted by the generators generator's own comment folders, so a comment posted on the redesign lands in the same thread as one posted on the official hub. Theme-aware, with a custom emoji pack.
  • Live "N online ยท peak N"
    • counter, with the peak stored durably on the server so it survives restarts.
  • A changelog page at #/changelog (deep-linkable), so users can see what changed and when โ€” plus a ๐Ÿ”€ Diff page at #/diff that shows a live, word-level diff of the official generators source against this one, for both panels, so any dev can see exactly what's different.
  • Independent mobile/desktop layouts, full dark-mode support, pinned and ultra-pinned entries (red ring, ๐Ÿ“Œ / ๐Ÿ“Œ๐Ÿ“Œ), a green ring marking the listings a refresh just brought in, the feed's spam/banned-name filtering, scroll-position restore, quick links and search โ€” all kept working.
0 points · 0 comments · view on lemmy.world

0 Comments

No comments yet.