mirror of
https://github.com/fastmail/Squire.git
synced 2024-12-22 07:13:08 -05:00
Handle pasting text/uri-list
This commit is contained in:
parent
43b2c6b0e1
commit
6b85bda364
3 changed files with 9 additions and 3 deletions
|
@ -2363,7 +2363,10 @@ var onPaste = function ( event ) {
|
||||||
type = item.type;
|
type = item.type;
|
||||||
if ( type === 'text/html' ) {
|
if ( type === 'text/html' ) {
|
||||||
htmlItem = item;
|
htmlItem = item;
|
||||||
} else if ( type === 'text/plain' ) {
|
// iOS copy URL gives you type text/uri-list which is just a list
|
||||||
|
// of 1 or more URLs separated by new lines. Can just treat as
|
||||||
|
// plain text.
|
||||||
|
} else if ( type === 'text/plain' || type === 'text/uri-list' ) {
|
||||||
plainItem = item;
|
plainItem = item;
|
||||||
} else if ( type === 'text/rtf' ) {
|
} else if ( type === 'text/rtf' ) {
|
||||||
hasRTF = true;
|
hasRTF = true;
|
||||||
|
|
File diff suppressed because one or more lines are too long
|
@ -162,7 +162,10 @@ var onPaste = function ( event ) {
|
||||||
type = item.type;
|
type = item.type;
|
||||||
if ( type === 'text/html' ) {
|
if ( type === 'text/html' ) {
|
||||||
htmlItem = item;
|
htmlItem = item;
|
||||||
} else if ( type === 'text/plain' ) {
|
// iOS copy URL gives you type text/uri-list which is just a list
|
||||||
|
// of 1 or more URLs separated by new lines. Can just treat as
|
||||||
|
// plain text.
|
||||||
|
} else if ( type === 'text/plain' || type === 'text/uri-list' ) {
|
||||||
plainItem = item;
|
plainItem = item;
|
||||||
} else if ( type === 'text/rtf' ) {
|
} else if ( type === 'text/rtf' ) {
|
||||||
hasRTF = true;
|
hasRTF = true;
|
||||||
|
|
Loading…
Reference in a new issue