-
Notifications
You must be signed in to change notification settings - Fork 14
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
test(Image): test for Image added #361
Conversation
Preview is ready. |
src/components/BackgroundImage/__tests__/BackgroundImage.test.tsx
Outdated
Show resolved
Hide resolved
src/components/Image/Image.tsx
Outdated
)} | ||
<source srcSet={mobile} media={`(max-width: ${BREAKPOINTS.sm}px)`} /> | ||
</Fragment> | ||
<DeviceSpecificFragment src={mobile} disableWebp={disableWebp} breakpoint="sm" /> |
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.
<DeviceSpecificFragment src={mobile} disableWebp={disableWebp} breakpoint="sm" /> | |
<DeviceSpecificFragment src={mobile} disableWebp={disableWebp} breakpoint="BREAKPOINTS.sm" /> |
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.
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.
Why are we using it inside when we can pass it from here once?
#401 separeted |
a2656f5
to
32491b8
Compare
32491b8
to
d520fba
Compare
d520fba
to
591aeed
Compare
src/components/Image/Image.tsx
Outdated
data-qa={`${qa}-compressed`} | ||
/> | ||
)} | ||
<source srcSet={src} media={`(max-width: ${BREAKPOINTS[breakpoint]}px)`} data-qa={qa} /> |
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.
<source srcSet={src} media={`(max-width: ${BREAKPOINTS[breakpoint]}px)`} data-qa={qa} /> | |
<source srcSet={src} media={`(max-width: breakpoint)`} data-qa={qa} /> |
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 hope I understand you
src/components/Image/Image.tsx
Outdated
@@ -37,11 +37,11 @@ const DeviceSpecificFragment = ({ | |||
<source | |||
srcSet={checkWebP(src)} | |||
type="image/webp" | |||
media={`(max-width: ${BREAKPOINTS[breakpoint]}px)`} | |||
media={`(max-width: ${breakpoint})`} |
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.
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.
Sure
No description provided.