-
Notifications
You must be signed in to change notification settings - Fork 9
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
Add HTML support for showing images #50
Conversation
Codecov Report
@@ Coverage Diff @@
## master #50 +/- ##
==========================================
+ Coverage 87.89% 87.98% +0.09%
==========================================
Files 6 6
Lines 223 233 +10
==========================================
+ Hits 196 205 +9
- Misses 27 28 +1
Continue to review full report at Codecov.
|
Looks good to me 👍 |
This might break some people's workflow, I'm not sure. But let's check it out in the wild JuliaRegistries/General#59456 |
This does not work well in Pluto notebooks, where suddenly our specialized PNG display (with native performance and nice scaling and reduced layout shifts) is replaced by a blurry small inline image 😭 We use Images.jl extensively in https://computationalthinking.mit.edu/ , where the automatic scaling causes confusingly small and blurry images. I now have to add an override to disable this PR: Base.showable(::MIME"text/html", ::AbstractMatrix{<:Colorant}) = false @lorenzoh can I work with you to add the PNG->HTML to Pollen.jl directly, instead of to this package? Or maybe we can hide this change behind a flag? |
Another example from the 3b1b lecture: BeforeSchermopname.2022-05-11.om.20.36.35.movAfter this PRThe image is too small, and you often get vertical layout shifts when the Schermopname.2022-05-11.om.20.35.14.movSchermopname.2022-05-11.om.20.34.27.mov |
Oh, this is so unfortunate! I knew there will be some conflict if the same HTML output feature is defined in downstream packages but didn't expect it to be undesired as this (especially the vertical layout shifts). |
Can't push to #49 so I open a new PR here. Changes on top of #49:
show_element
codescloses #48
closes #49
cc: @lorenzoh