urbanarchive / qpl-name-explorer

White label site for QPL Name Explorer
2 stars 2 forks source link

Add a featured content to the top of the homepage feed. #84

Open benpsmyth opened 1 year ago

benpsmyth commented 1 year ago

Homepage Feed ONLY:

  1. Display "featured" items first (airtable checkbox) Could be submissions or tours

  2. Display a randomized list of submissions that contain photos

  3. Randomize remaining submissions. (continuous scroll-based pagination)

Image

isaacbw commented 1 year ago

Make sure tours are sorted organically!

allthesignals commented 1 year ago

Logic so far...

      ...data.filter(record => record[LOCATIONS.FEATURED] || record[TOURS.FEATURED]),
      ...shuffleArray(data.filter(record => record[LOCATIONS.IMAGES]?.length)),
      ...data.filter(record => !record[LOCATIONS.IMAGES]?.length),

surface featured tours and locations at the top. then, surface locations with images. shuffle those. then, anything else goes go to the bottom...