-
-
Notifications
You must be signed in to change notification settings - Fork 81
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
fix image constraints #341
Conversation
@pichfl do you think this would have any negative effects? 🤔 the idea is to have a global rule because we can't add a specific class to images that are added to Markdown |
By setting only the |
Thanks @pichfl! I'm sorry I need one point of clarification in follow up. Are you saying we should include |
So @pichfl, I probably didn't explain the need for this change explicitly enough. When you say "We should rather fix anything that breaks though" what precisely do you mean? 🤔 The issue that we have is that we can't actually manually fix all images in some of the sites that use the For example, if you look at the example markdown page on master you will see that there is currently an image that is exploding off the side of the page: https://ember-styleguide.netlify.app/concepts/markdown/ (also you can see that the corresponding page is fixed in this PR: https://deploy-preview-341--ember-styleguide.netlify.app/concepts/markdown/ ) I'm happy for us to put in the |
- images in markdown breakout of their container as described in #335 - this sets a max width to constrain them Co-Authored-By: Chris Manson <mansona@users.noreply.github.com>
4cd7d2b
to
caa1178
Compare
Also I created two branches ember-learn/ember-website#666 and ember-learn/ember-website#665 that test with Percy sees no difference between them but I guess that this could be because Percy uses Chrome? 🤔 Is there something that I should be looking for? |
In case this CSS approach may help: https://github.com/ijlee2/ember-container-query/blob/main/tests/dummy/app/components/widgets/widget-3/tour-schedule/responsive-image/index.css I don't think IE 11 supports |
@ijlee2 so this sort of solution isn't really available to us, we need to make sure that the default implementation (without using classes) works because of the nature of the way Markdown is being rendered in our infrastructure 👍 nice pointer 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.
I'm going to go ahead with this change as is for now 👍 Because we ran the experiment with and without height: auto;
and couldn't find any difference we think it's safe to leave it like this for the time being. If we find any evidence of distortions going forward we will look at what caused them and consider adding height: auto;
as a bugfix at that stage 🎉
Co-Authored-By: Chris Manson mansona@users.noreply.github.com