0
Fork 0
mirror of https://github.com/fastmail/Squire.git synced 2024-12-22 23:40:35 -05:00
Commit graph

9 commits

Author SHA1 Message Date
Neil Jenkins
6413034884 Improve copy/paste
* In browsers that support it, we now tell it to copy exactly what was selected
  in the DOM, and not to add extra gunk which browsers do to preserve exact
  styling if pasted into another document.
* Don't use the clipboard APIs with MS Edge, since it only supports plain text.
  If we let it fallback to the browser implementation it will insert HTML.
2016-03-11 15:22:49 +11:00
Neil Jenkins
6ed3b93900 Workaround Firefox clipboard ignores RTF data 2016-03-07 18:38:07 +11:00
Neil Jenkins
715166b95d Let browser handle paste of images in FF/Safari. 2015-07-16 10:47:56 -07:00
Neil Jenkins
fdcef5fc8e Workaround clipboard having blank text/html version. 2015-07-14 12:59:27 -07:00
Neil Jenkins
579cad7ff9 Fix pasting plain text in Safari. 2015-07-11 19:22:46 +07:00
Neil Jenkins
def56193d4 Fix dummy paste area should be removed after paste completes 2015-06-22 09:32:47 +07:00
Neil Jenkins
680c0fbbb7 Don't use old clipboard API.
Safari very rarely has a text/html version (even if you copy from within
Safari!) so you end up always pasting plain text. Better to use the fallback
method to grab the data.
2015-06-19 14:19:37 +07:00
Neil Jenkins
bc523f83e8 Better paste handling
Get paste data directly from browser when supported. Funnel all pastes through
the insertHTML method for consistent results.
2015-06-19 14:19:21 +07:00
Neil Jenkins
395a5825e9 Split cleaning fns and clipboard handlers into separate file. 2015-06-19 14:18:32 +07:00