mirror of
https://github.com/zenorocha/clipboard.js.git
synced 2023-08-10 21:12:48 +03:00
Modified comments and changed element type for "ClipboardAction" class;
This commit is contained in:
parent
c041e2a8f0
commit
e4f3fb226c
2
dist/clipboard.js
vendored
2
dist/clipboard.js
vendored
|
@ -265,7 +265,7 @@ var ClipboardAction = (function () {
|
||||||
};
|
};
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Creates a fake input element, sets its value from `text` property,
|
* Creates a fake textarea element, sets its value from `text` property,
|
||||||
* and makes a selection on it.
|
* and makes a selection on it.
|
||||||
*/
|
*/
|
||||||
|
|
||||||
|
|
|
@ -45,7 +45,7 @@ class ClipboardAction {
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Creates a fake input element, sets its value from `text` property,
|
* Creates a fake textarea element, sets its value from `text` property,
|
||||||
* and makes a selection on it.
|
* and makes a selection on it.
|
||||||
*/
|
*/
|
||||||
selectFake() {
|
selectFake() {
|
||||||
|
@ -53,7 +53,7 @@ class ClipboardAction {
|
||||||
|
|
||||||
this.fakeHandler = document.body.addEventListener('click', () => this.removeFake());
|
this.fakeHandler = document.body.addEventListener('click', () => this.removeFake());
|
||||||
|
|
||||||
this.fakeElem = document.createElement('input');
|
this.fakeElem = document.createElement('textarea');
|
||||||
this.fakeElem.style.position = 'absolute';
|
this.fakeElem.style.position = 'absolute';
|
||||||
this.fakeElem.style.left = '-9999px';
|
this.fakeElem.style.left = '-9999px';
|
||||||
this.fakeElem.setAttribute('readonly', '');
|
this.fakeElem.setAttribute('readonly', '');
|
||||||
|
|
Loading…
Reference in New Issue
Block a user