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

Firefox copy/paste not working #507

Open
argyleink opened this issue May 12, 2021 · 0 comments
Open

Firefox copy/paste not working #507

argyleink opened this issue May 12, 2021 · 0 comments

Comments

@argyleink
Copy link
Collaborator

Uncaught (in promise) TypeError: 'clipboard-write' (value of 'name' member of PermissionDescriptor) is not a valid value for enumeration PermissionName.

A try/catch could pivot the logic, so on error it just tries to write. BUT, the manifest.json would need modified for copy/paste ability as well clipboardWrite, which is probably not an issue.

todo:

  • find tradeoffs between the 2 techniques
  • determine if unifying them to the old way or supplying a fallback are better
argyleink added a commit that referenced this issue May 14, 2021
* added color swatches with contrast-safe text

* color swatch click event setup

* clipboard event (still a WIP)

* copy to clipboard actually works now

* tell user: copy/copied

* Apply some suggestions from code review

Co-authored-by: Adam Argyle <[email protected]>

* colormode and modemap setup

* more responsive. cleaner contrasting text with TinyColor.

* account for long aria attribute text affecting responsiveness

* further tweaks to responsively style A, AA, AAA, aria-label, etc

* one more flexbox tweak

* see if this fixes the test (updated HTML)

* revert contrastValueSelector. comment out first failing test.

let's see how it goes!

* clipboard.writeText works in firefox without this permission

navigator.permissions.query({name:'clipboard-write'}) currently won't work in firefox

* copyToClipboard: 'clipboard-write' method for now

fully address firefox 'clipboard-write' in #507

Co-authored-by: Adam Argyle <[email protected]>

* more stable getContrastingColor

Co-authored-by: Adam Argyle <[email protected]>

* ugly fix but gets rid of the empty div

* tabindex="0" -> focusable -> holds focus

* rid gap

* metatip.element.css color-swatch padding: 10px <- 0.5em

Co-authored-by: Adam Argyle <[email protected]>

* tweak the sizing and order

* alignment tweaks

* white-space:nowrap; removes need for 0.7em font-size i think

Co-authored-by: Adam Argyle <[email protected]>
argyleink added a commit that referenced this issue May 18, 2021
* A11y metatip color swatches (+ click to copy to clipboard) (#505)

* added color swatches with contrast-safe text

* color swatch click event setup

* clipboard event (still a WIP)

* copy to clipboard actually works now

* tell user: copy/copied

* Apply some suggestions from code review

Co-authored-by: Adam Argyle <[email protected]>

* colormode and modemap setup

* more responsive. cleaner contrasting text with TinyColor.

* account for long aria attribute text affecting responsiveness

* further tweaks to responsively style A, AA, AAA, aria-label, etc

* one more flexbox tweak

* see if this fixes the test (updated HTML)

* revert contrastValueSelector. comment out first failing test.

let's see how it goes!

* clipboard.writeText works in firefox without this permission

navigator.permissions.query({name:'clipboard-write'}) currently won't work in firefox

* copyToClipboard: 'clipboard-write' method for now

fully address firefox 'clipboard-write' in #507

Co-authored-by: Adam Argyle <[email protected]>

* more stable getContrastingColor

Co-authored-by: Adam Argyle <[email protected]>

* ugly fix but gets rid of the empty div

* tabindex="0" -> focusable -> holds focus

* rid gap

* metatip.element.css color-swatch padding: 10px <- 0.5em

Co-authored-by: Adam Argyle <[email protected]>

* tweak the sizing and order

* alignment tweaks

* white-space:nowrap; removes need for 0.7em font-size i think

Co-authored-by: Adam Argyle <[email protected]>

* closer to matching target design

* fixes regression

* minor color updates

* remove commas from presentation teir

* fixes regression in no match state

* fixes spacing issue and remove emoji

* add space into copy prompt

* adds tag presentation style

* adds space into copied message too

* matches spacing of other elements

* spacing nit

Co-authored-by: Howard Chiam <[email protected]>
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

1 participant