Skip to content
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(ui): different landing page visual #5273

Merged
merged 4 commits into from
Mar 17, 2023

Conversation

floyd-li
Copy link
Member

Thank you for your contribution to the KodaDot NFT gallery.

i found this issue, it's caused by the svg filter feGaussianBlur. it has different behavior in different browsers, here's the chrome/firefox/safari's screenshot and you can easily find the difference.
also provide a codepen for this, you can use different browser to check behavior: https://codepen.io/floyd-li/pen/abaYXGg

image


so the solution is, replace thesesvg imgs with png.

👇 _ Let's make a quick check before the contribution.

PR Type

  • Bugfix
  • Feature
  • Refactoring

Context

Before submitting pull request, please make sure:

  • My contribution builds clean without any errors or warnings
  • I've merged recent default branch -- main and I've no conflicts
  • I've tried to respect high code quality standards
  • I've didn't break any original functionality
  • I've posted a screenshot of demonstrated change in this PR

Optional

  • I've tested it at </bsx/collection>
  • I've tested PR on mobile
  • I've written unit tests 🧪
  • I've found edge cases

Had issue bounty label?

  • Fill up your KSM address: Payout

Community participation

Screenshot 📸

  • My fix has changed something on UI; a screenshot is best to understand changes for others.

image

image

@floyd-li floyd-li requested a review from a team as a code owner March 14, 2023 19:26
@floyd-li floyd-li requested review from daiagi and Jarsen136 and removed request for a team March 14, 2023 19:26
@kodabot
Copy link
Collaborator

kodabot commented Mar 14, 2023

SUCCESS @floyd-li PR for issue #4757 which is assigned to you. Please wait for review and don't hesitate to grab another issue in the meantime!

@netlify
Copy link

netlify bot commented Mar 14, 2023

Deploy Preview for koda-nuxt ready!

Name Link
🔨 Latest commit ce7ae1b
🔍 Latest deploy log https://app.netlify.com/sites/koda-nuxt/deploys/64145736b9ae2c0008fc33d4
😎 Deploy Preview https://deploy-preview-5273--koda-nuxt.netlify.app
📱 Preview on mobile
Toggle QR Code...

QR Code

Use your smartphone camera to open QR code link.

To edit notification comments on pull requests, go to your Netlify site settings.

@floyd-li floyd-li changed the title fix(ui): bg image replace svg with png fix(ui): different landing page visual Mar 14, 2023
@exezbcz
Copy link
Member

exezbcz commented Mar 14, 2023

its looks much more transparent then before, not sure whether we want this tho. Is there any way to fix that?
after:
image
before:
image

tested in chrome

@floyd-li
Copy link
Member Author

thanks for your feedback, seems the svg to png convert goes wrong. i'll update it soon.

its looks much more transparent then before, not sure whether we want this tho. Is there any way to fix that? after: image before: image

tested in chrome

@floyd-li
Copy link
Member Author

@exezbcz just updat bg imgs, pls check it again :)

Copy link
Contributor

@roiLeo roiLeo left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

What if we keep svg and try to use css filter instead?

@exezbcz
Copy link
Member

exezbcz commented Mar 15, 2023

@roiLeo yeah, I was thinking the same but cannot find the issue - so basically use the raw shapes and then apply layer blur?

for example the right shape is this
image

  • with layer blur 400px

its in the figma landing page handoff
https://www.figma.com/file/3iOjW12ERFRDSVnpLuhQmf/landing-page-handoff?node-id=3725%3A3848&t=Do6VL6QnCQMUVc15-1

@exezbcz
Copy link
Member

exezbcz commented Mar 15, 2023

@floyd-li yup, looks good now!

@roiLeo
Copy link
Contributor

roiLeo commented Mar 15, 2023

@roiLeo yeah, I was thinking the same but cannot find the issue - so basically use the raw shapes and then apply layer blur?

I think we already mention this in older issue.

IMO we need to rework exported svg from figma.
For example on Nuxt website, there is more or less the same thing in header.
They manage to export 3 different gradient size depending on screen size:

@floyd-li
Copy link
Member Author

@exezbcz @roiLeo I tried this before and seems not working well.
here's the codepen based on the svg, i just commented the feGaussianBlur and use css filter: blur(185px) instead, also displayed differently in firefox as the svg does.
seemsblur effect has different behaviors in different broswers? 🤔️
https://codepen.io/floyd-li/pen/abaYXGg
image

@exezbcz
Copy link
Member

exezbcz commented Mar 15, 2023

@floyd-li hmm, weird, so the blur filter rendering is based on browser as well

  • so then is the png the only viable option?

@floyd-li
Copy link
Member Author

@floyd-li hmm, weird, so the blur filter rendering is based on browser as well

  • so then is the png the only viable option?

not sure but i think png or webp img is the low-coast solution currently

@floyd-li
Copy link
Member Author

floyd-li commented Mar 15, 2023

@floyd-li hmm, weird, so the blur filter rendering is based on browser as well

  • so then is the png the only viable option?

not sure but i think png or webp img is the low-coast solution currently

as i tested, if the css blur or the svg stdDeviation value > 100, firefox will render significantly different with chrome

edit: it's a bug reported 4 years ago and seems not been resolved, here's the bugzillia link: id=1530810

@exezbcz
Copy link
Member

exezbcz commented Mar 15, 2023

@floyd-li so i think we can go with the png approach then

Thanks for trying tho!
I will let other devs decide. It works for me 👍

Copy link
Contributor

@daiagi daiagi left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

wfm

@floyd-li floyd-li requested review from roiLeo and removed request for Jarsen136 March 16, 2023 09:02
Copy link
Contributor

@roiLeo roiLeo left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Hmm.. not really convinced with this solution but let it roll 🎢

Next we might need to resize (& minimify) the png for better aspec ratio
(and use b-image or nuxt-image lazy loading)

@floyd-li
Copy link
Member Author

Hmm.. not really convinced with this solution but let it roll 🎢

Next we might need to resize (& minimify) the png for better aspec ratio

(and use b-image or nuxt-image lazy loading)

yep i'll follow up this and try to find a better solution

@floyd-li
Copy link
Member Author

@vikiival @exezbcz is this PR okay to merge?

@vikiival
Copy link
Member

@vikiival @exezbcz is this PR okay to merge?

let's see what will mr. design will say

@codeclimate
Copy link

codeclimate bot commented Mar 17, 2023

Code Climate has analyzed commit ce7ae1b and detected 0 issues on this pull request.

View more on Code Climate.

@exezbcz
Copy link
Member

exezbcz commented Mar 17, 2023

@vikiival yes, its oki mr. painter :D

@vikiival
Copy link
Member

pay 20 usd

@vikiival vikiival merged commit a59d727 into kodadot:main Mar 17, 2023
@yangwao
Copy link
Member

yangwao commented Mar 17, 2023

😍 Perfect, I’ve sent the payout
💵 $20 @ 35.79 USD/KSM ~ 0.559 $KSM
🧗 EZiu1PjV2j2JHKxY6mHnFwwCRCoV27uHKQSkKXATSh1srJT
🔗 0x8c91fa48c68650115cf8e3573003b98d98876249e7e24e6e534aedd5bd6e8687

🪅 Let’s grab another issue and get rewarded!
🪄 github.com/kodadot/nft-gallery/issues

@yangwao yangwao added the paid pull-request has been paid label Mar 17, 2023
@floyd-li floyd-li deleted the fix/blurred-bg-issue branch October 8, 2023 03:18
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
paid pull-request has been paid S-visual-ok-✅
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Different landing page visual on firefox
7 participants