Skip to content

Restructure homepage and add rotating featured examples#953

Open
TimMonko wants to merge 15 commits intonapari:mainfrom
TimMonko:enh/homepage
Open

Restructure homepage and add rotating featured examples#953
TimMonko wants to merge 15 commits intonapari:mainfrom
TimMonko:enh/homepage

Conversation

@TimMonko
Copy link
Contributor

@TimMonko TimMonko commented Mar 13, 2026

References and relevant issues

Address #793, I think?
Also, I think it will need to wait until 0.7.0 releases because it will look for the example images in stable static ... right? They won't be there until after 0.7.0 releases.

Description

Revamp of homepage, will detail out later. Having a bit of trouble full building locally so I'm pushing to make the bot build for me lol. This makes the homepage MUCH easier and quicker to parse and I think actually provides more information. I prompted copilot with Claude Opus to set this up and it did a REALLY bad job aesthetically (I still have css cleanup to do), BUT it use this whole .js stuff that I'm clueless about and that actual works (and is what matplotlib uses). So it was sort of a win and sort of a fighting a toddler moment. In the end, I combed over most of the code myself lol.

  1. Gets ride of sidebar on homepage only
  2. Adds a search button in the navbar persistent on all pages, to continue to allow searching from home page
  3. Gets rid of many cards, especially those that are redundant with navbar links (like community and contributing)... TODO: realizing I should probably drop the plugins card too...? But this one is more of a "heres how napari works" compared to community and contributing
  4. Takes the quicklinks from the sidebar and makes them prevalant, but still less downplayed parts of the homepage
  5. Adds a rotating example from the gallery -- featured_examples.json allows us to control which examples. We could probably do this as a gallery tag, but I thought it was nice to control here (rather than in napari/napari) how examples are rendered and we can be more precise about home page wording for the individual example . Also notice the dropshadow around the media, so we won't have the really sad white border around it like with the above viewer example.
image

Some more ideas

  1. have a copy-pastable uvx "napari[all]" remote_path_to_example.py to show it running python files?
  2. Instead of the "really nice" examples, we could do more basic ones to demonstrate API like viewer.add_image() leading to the add image example? I don't really like this though
  3. We could also just ref any page we want and any image, the featured_examples.json just takes keys that are title, description, doc path, and image path. So if we have in dpeth tutorials or other things to highlight (or we can make another dynamic section with the same model that highlights other parts of the docs)
  4. Ignore the example part, but do keep the sidebar removal + moving those key links over + the install + download cards.

@github-actions github-actions bot added the documentation Improvements or additions to documentation label Mar 13, 2026
@TimMonko
Copy link
Contributor Author

@napari-bot make html

@TimMonko TimMonko marked this pull request as ready for review March 13, 2026 19:01
@TimMonko TimMonko changed the title Enh/homepage Restructure homepage and add rotating featured examples Mar 13, 2026
@TimMonko
Copy link
Contributor Author

@napari-bot make html

@TimMonko
Copy link
Contributor Author

@napari-bot make html

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

documentation Improvements or additions to documentation

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant