-
Notifications
You must be signed in to change notification settings - Fork 339
MAINT: Drop jQuery and use Bootstrap 5 #1029
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
I know this is WIP, just a reminder that we will need to get these pydata-sphinx-theme/src/pydata_sphinx_theme/assets/scripts/pydata-sphinx-theme.js Line 101 in 5133e4a
pydata-sphinx-theme/src/pydata_sphinx_theme/assets/scripts/pydata-sphinx-theme.js Line 330 in 5133e4a
pydata-sphinx-theme/src/pydata_sphinx_theme/assets/scripts/pydata-sphinx-theme.js Lines 383 to 387 in 5133e4a
pydata-sphinx-theme/src/pydata_sphinx_theme/theme/pydata_sphinx_theme/sections/announcement.html Lines 6 to 7 in 5133e4a
|
Yep I'm working on it, I just want to check first if the bootstrap breaking changes are all tackled. @drammock do you know a way to edit |
I think with #868 it worked that way because FontAwesome doesn't have any dependencies. AFAIK |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I love that package-lock.json
has gone from 21k lines to 9k lines. I noticed a few problems, see below.
src/pydata_sphinx_theme/theme/pydata_sphinx_theme/components/version-switcher.html
Show resolved
Hide resolved
I took a pass through the preview docs, and they seem to look good to me. Scrolling behavior works and things seem to be formatted properly. Anything else that @12rambau wants to do here or are you ready for final review + merge? My feel is we should:
|
SGTM! |
what type of banner are you thinking about? Using the header banner or adding a warning admonition on the landing page ? |
I was thinking header banner - what do you think? I'm happy with whatever path you think is best |
I was thinking, maybe that's a good reason to finish the PR on loud banners #759 ? |
I agree that loud banners would be quite useful! Though I won't have any time to finish it any time soon. I am happy to review PRs if you or others want to take it over and get it over the finish line. |
Now that 0.12 is out should we commit this one to master ? |
If you think that this is ready to go, then I suggest we merge it quickly and iterate from there. One suggestion: could you provide a short summary of the changes that you needed to make in this PR, as a "mini guide" to downstream authors who might need to make the same changes in their themes? |
@choldgraf done (I'll may need some proofreading though). |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
OK looks good to me - I've cleaned up the language a little bit, so I think we should merge this and then see if any bugs or questions pop up!
This can be removed when pydata/pydata-sphinx-theme#1029 is released.
This can be removed when pydata/pydata-sphinx-theme#1029 is released.
Fix #953, Fix #764
for bootstrap I've followed the instructions from: https://getbootstrap.com/docs/5.0/migration/
which lead to the following changes:
left
(resl
) bystart
(res.s
) andright
(res.r
) byend
(res.e
)data-*
bydata-bs-*
and for jquery: https://tobiasahlin.com/blog/move-from-jquery-to-vanilla-javascript/#network-requests-with-get-or-ajax
which lead to the following changes:
.ready()
$.ajax
,$.getJSON
and$.get
by the genericfetch
$().each
etc...)jquery
everywhereIt's a sensitive change as I'm modifying pretty much every js of theme so I tagged most of the regular maintainers. Let me know what you think and your suggestions. Also note that the
package-lock.json
ended up being a lot modified, if you know a way to cherry-pick the changes I'm happy to change it.