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

Transparent background? #63

Closed
timmyomahony opened this Issue Oct 30, 2016 · 3 comments

Comments

2 participants
@timmyomahony
Copy link

timmyomahony commented Oct 30, 2016

Is it possible to have a transparent background? I tried

const qr = new QRious({
  element: ...,
  foreground: '#1a1a1a',
  background: 'transparent',  // also tried null and undefined
  value: 'https://github.com/neocotic/qrious',
  size: 500
});

but it doesn't work.

@neocotic neocotic added this to the 2.2.0 milestone Oct 30, 2016

@neocotic neocotic self-assigned this Oct 30, 2016

@neocotic

This comment has been minimized.

Copy link
Owner

neocotic commented Oct 30, 2016

Not currently supported but let's change that :)

I'm going to add 2 new options; backgroundAlpha and foregroundAlpha, both of which will default to 1.0. The values can range between 0 and 1. So, for your example;

const qr = new QRious({
  element: ...,
  foreground: '#1a1a1a',
  backgroundAlpha: 0,
  value: 'https://github.com/neocotic/qrious',
  size: 500
});

@neocotic neocotic referenced this issue Oct 30, 2016

Merged

2.2.0 WIP #64

1 of 1 task complete

@neocotic neocotic closed this in #64 Oct 30, 2016

@neocotic

This comment has been minimized.

Copy link
Owner

neocotic commented Oct 30, 2016

@timmyomahony Please upgrade to v2.2.0 and let me know how you get on with these new options.

@timmyomahony

This comment has been minimized.

Copy link

timmyomahony commented Oct 30, 2016

Amazing. Thanks for the quick reply. Just updated and it works perfectly.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment