ObservableMedia does not emit when largest viewport is active
This seems to be happening with custom breakpoints and I'm using 2.0.0-beta6, but it may still be happening with other instances as well.
Here's a plunker that shows the custom breakpoints. Scaling the app up and down shows that events are emitted to console for small and medium, but not the largest size.
https://plnkr.co/edit/WvZtQ024vu2R816EMPQD?p=preview
@TylerDev6 - Your non-overlapping breakpoint ranges appear to be wrong
[{
alias: 'xs',
mediaQuery: 'screen and (max-width: 767px)'
}, {
alias: 'sm',
mediaQuery: 'screen and (max-width: 767px)'
}, {
alias: 'md',
mediaQuery: 'screen and (min-width: 768px) and (max-width: 1023px)'
}, {
alias: 'lg',
mediaQuery: 'screen and (min-width: 1024px)'
}, {
alias: 'xl',
mediaQuery: 'screen and (min-width: 1024px)'
}]
^ they are overlapping and often the same. Non-overlapping ranges must have distinct, unique, non-overlapping range values.
right, that was a problem I had encountered. As you can see, I only really need 3 breakpoints but the API indicates that I must provide all 5. Since I didn't want layout changes triggered by the default xs and xl breakpoints I overrode them.
However, why would that actually cause the behaviour I'm seeing? xs / sm overlap but I still get emits for xs.... lg and xl overlap but I don't get emits for either.
Related to #245
Will be fixed with PR #313.
See working plunker: https://plnkr.co/edit/yylQr2IdbGy2Yr00srrN?p=preview
Fixed with SHA 00ac57a
This issue has been automatically locked due to inactivity. Please file a new issue if you are encountering a similar or related problem.
Read more about our automatic conversation locking policy.
This action has been performed automatically by a bot.