nostalgic-css / NES.css

NES-style CSS Framework | ファミコン風CSSフレームワーク
https://nostalgic-css.github.io/NES.css/
MIT License
20.76k stars 1.66k forks source link

Icons render wrong when you zoom in and out on Chrome #427

Open jordanellis opened 4 years ago

jordanellis commented 4 years ago

Describe the bug When you zoom in on a page that has icons from nes.css on it, the icons begin to show with white grid lines in between them as if the squares used to make them aren't touching anymore.

To Reproduce

  1. Go to https://nostalgic-css.github.io/NES.css/ and view the icons.
  2. Zoom in (and out at different percentages) on the browser.
  3. View icons rendered with gaps.

Expected behavior Icons should be rendered similar to how they get rendered at 100% zoom. Screen Shot 2020-06-02 at 5 15 19 PM

Environment:

Suggestion(s) for fixing this issue Unfortunately I don't know much about rendering graphic

Additional context Love NES.css!

SecretBase commented 4 years ago

I think that kind of rendering bug on the browser when using box shadow as a pixel art

https://codepen.io/louflan/pen/mdJKRWN

I tried others people pixel art using same box shadow trick. also having the same problems.

I guess that just some weird browsers render bug. IMHO there nothing a framework can do about it. unless change those pixel art not using the box shadow trick.

Mac chrome at 110% zoom level image

Mac chrome at 67% zoom level image

Mac Safari zoom out 1 level image

Windows 10 Chrome 90% zoom level

image

guastallaigor commented 4 years ago

I guess that just some weird browsers render bug. IMHO there nothing a framework can do about it. unless change those pixel art not using the box shadow trick.

Yes, that's exactly what I thought. I saw this bug before, but I couldn't do anything about it. That's why I put the "help wanted" label :smile:

HiKaylum commented 4 years ago

May be possible converting these to SVGs rather than using box-shadow but will have to look into it and would be a breaking change.

hoangph271 commented 3 years ago

Not only icons but buttons are broken on Chrome as well...!

Screen Shot 2021-10-06 at 18 43 58

Works well on Firefox...!

Screen Shot 2021-10-06 at 18 44 08