fix: issue with CSS styles when in-between whole pixel values for viewport width (#3139)

* fix: issue with CSS styles when in-between whole pixel values for viewport width

Fixes #2915

* chore: add explanatory comment

* fix: add missing slash
This commit is contained in:
David Wheatley 2021-10-29 19:57:53 +02:00 committed by GitHub
parent a6d4759ece
commit a4499678d9

View File

@ -119,13 +119,17 @@
// ---------------------------------
// BREAKPOINTS
@screen-phone-max: (@screen-tablet - 1);
// We use `-0.02` here to fix an odd rendering glitch with specific operating system UI scaling, and combined
// with specific viewport sizes. This can result in the browser actually being 'between' media queries, which
// breaks our UI. See: https://github.com/flarum/core/issues/2915
@screen-phone-max: (@screen-tablet - 0.02);
@screen-tablet: 768px;
@screen-tablet-max: (@screen-desktop - 1);
@screen-tablet-max: (@screen-desktop - 0.02);
@screen-desktop: 992px;
@screen-desktop-max: (@screen-desktop-hd - 1);
@screen-desktop-max: (@screen-desktop-hd - 0.02);
@screen-desktop-hd: 1100px;