napari / napari-sphinx-theme

https://napari.org/napari-sphinx-theme
BSD 3-Clause "New" or "Revised" License
4 stars 11 forks source link

Full refactor of napari-sphinx-theme to depend on pydata-sphinx-theme #134

Closed melissawm closed 10 months ago

melissawm commented 1 year ago

Refactors colors, styling and fonts from napari-sphinx-theme. Also removes extra react components that are not needed for the napari theme.

Includes the community calendar feature, but calendar is now managed on the docs side.

To see how this would look like, you can fetch this PR and build the docs locally (after fetching napari/docs#267), or you can see the deployed site here: https://melissawm.github.io/napari-theme-var

Important

After merging, this will also require a new release of the napari-sphinx-theme.

Addresses napari/napari-sphinx-theme#113

See also napari/docs#267

melissawm commented 1 year ago

I think I addressed all comments except for the calendar - let me know if there's anything else to do here. Cheers!

jni commented 11 months ago

Hi folks,

After some discussion with @Czaki, I don't think we need to wait until 0.4.19 to merge and release this, since our docs builds pin the napari-sphinx-theme version. I would like to merge this and release the theme, which will unlock the PRs on the docs side. But @melissawm I'm unclear about where the calendar pop-up needs to be fixed — is it here in the theme, or is it in the docs repo?

jni commented 11 months ago

(But I'm more than happy to clean up the events to be plaintext, too.)

psobolewskiPhD commented 11 months ago

My understanding is it's the actual events in google? that need fixing.

melissawm commented 11 months ago

If the events are fixed on the calendar side, it will both make them more readable right now and more easily formatted into a nice pop-up later, so that's helpful. I can also prioritize this today to bring the napari-docs PR up to date. I'll let you know. Thanks! :rocket:

melissawm commented 11 months ago

Ok! Just rebuilt everything and rebased the napari-docs PR. This should be good to go except for the calendar as mentioned before. Also - for this to be active on the website, we need to cut a new release of this theme.

psobolewskiPhD commented 10 months ago

This PR can be seen live on napari CI: https://output.circle-artifacts.com/output/job/c9c574d3-71c6-434f-b5ab-85bdb7ff68c3/artifacts/0/docs/docs/_build/index.html?pr=267

psobolewskiPhD commented 10 months ago

I checked the calendar: https://melissawm.github.io/napari-theme-var/community/meeting_schedule.html This should be using the latest of everything right? Things look a bit better?

image

I think it will either look bad in the new theme or look bad on google calendar?

jni commented 10 months ago

I think it will either look bad in the new theme or look bad on google calendar?

I think Google Calendar is literally adding that html. I edited every event and pasted in plaintext versions of the descriptions, and this is what it looks like? I'm more than a little bit miffed at Google, yet again. I wonder if there are other calendar providers we can use here. (Once again, I wonder if @melissawm has suggestions based on other projects she's seen at Quansight.)

I also noticed when clicking a few events that this is using a javascript prompt, which means FF thinks it's spammy if you click on two events quickly:

Screenshot 2024-01-16 at 7 06 24 pm

So I wonder whether there's another alternative here... Either way, I'm happy to take guidance from @melissawm on whether that should come in a later PR. For now, I think the theme provides enough value that we should merge it and deal with the issues later. But I don't have a great idea what "deal with the issues" actually entails... 😅

melissawm commented 10 months ago

@jni I went with a different modal (not an alert) and I think that does it. Also it looks much better now, since I can really format things properly! Here it is: https://melissawm.github.io/napari-theme-var/community/meeting_schedule.html

Screenshot just in case: Screenshot_20240116_193136

What do you think?

psobolewskiPhD commented 10 months ago

@jni I went with a different modal (not an alert) and I think that does it. Also it looks much better now, since I can really format things properly! Here it is: https://melissawm.github.io/napari-theme-var/community/meeting_schedule.html

OMG it's perfect! I have to be honest, the clickable links are 💯 because this is how I access these things!

melissawm commented 10 months ago

Yes - this should be a temporary thing. Version 1.15.1 introduces a bug where the left side bars don't show up. This is fixed in main but not yet released. Here are the details: https://github.com/pydata/pydata-sphinx-theme/issues/1625

jni commented 10 months ago

🚀🚀🚀🚀 I am elated over here!!!! 😭 🙏🙏🙏🙏

@melissawm could you confirm for me the next steps needed? By my understanding:

jni commented 10 months ago

btw, this thing:

image

😍😍😍😍

melissawm commented 10 months ago

🚀🚀🚀🚀 I am elated over here!!!! 😭 🙏🙏🙏🙏

@melissawm could you confirm for me the next steps needed? By my understanding:

  • release napari-sphinx-theme
  • update requirements on napari/docs#267
  • merge napari/docs#267
  • ... profit?

That is also my understanding! I'll be around looking to see if we have any unexpected failures but I think we should be good! 😍 Woohoo!!

jni commented 10 months ago

Ok, there will be a constraints-update required and I think that has to happen on the napari/napari repo. But the build can't work until napari/docs#267 is merged. HMMM. I guess there is a minimum of one broken build in our future, but I think that's ok... Anyway, since the constraints are used when building docs, it is risk-free to release this so imma do it!!!

melissawm commented 10 months ago

I'll update the requirements files on the PR at the docs repo but I'm not really sure how to update the constraints files, so I'll leave those up to you folks 🙏

jni commented 10 months ago

Ok, lots to fix in our release action :joy: hold please :joy: