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

rendering with enable-force-dark and svg tag #40

Open
st4nny opened this issue Oct 17, 2021 · 4 comments
Open

rendering with enable-force-dark and svg tag #40

st4nny opened this issue Oct 17, 2021 · 4 comments

Comments

@st4nny
Copy link

st4nny commented Oct 17, 2021

Hi,
i have this:
<VueQrcode class="mx-auto z-30 relative" style="width:230px; height:230px;" :value=qrcode tag="svg" :options="{ width: 230, color: {dark: '#000',light: '#fff'} }"></VueQrcode>
with flag enable-force-dark enabled i obtain a white square.
Possible solution?

@fengyuanchen
Copy link
Owner

What's the enable-force-dark meaning? Any online demo for check?

@st4nny
Copy link
Author

st4nny commented Oct 22, 2021

Hi,
Go to chrome://flags/#enable-force-dark
on chrome or chromium and enabled dark mode.
Go to https://fengyuanchen.github.io/vue-qrcode demo page, the qr generated with svg tag are white.

@fengyuanchen
Copy link
Owner

  1. It may be a problem with the enable-force-dark mode of the browser.
  2. It may be a problem with the node-qrcode project.
  3. I will suggest you use the img or canvas tag instead currently in enable-force-dark mode.

@st4nny
Copy link
Author

st4nny commented Oct 22, 2021

Hi, thank you for reply.
Some old mobile devices have problem with chrome and rendering with canvas
while with svg i don't have problem. I haven't investigate instead with this bug with canvas

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants