2
0
forked from Wavyzz/dolibarr

Debug feature copy-paste on smarpthone

This commit is contained in:
Laurent Destailleur
2021-05-19 11:47:58 +02:00
parent 4d42235670
commit 78cf2b59c8
5 changed files with 26 additions and 6 deletions

View File

@@ -214,17 +214,17 @@ print '
print "\n/* JS CODE TO ENABLE ClipBoard copy paste*/\n";
print 'jQuery(\'.clipboardCPShowOnHover\').hover(
function() {
console.log("We hover a value with a copy paste feature");
console.log("We hover a value with a copy paste feature");
$(this).children(".clipboardCPButton, .clipboardCPText").show();
},
function() {
console.log("We hover out the value with a copy paste feature");
console.log("We hover out the value with a copy paste feature");
$(this).children(".clipboardCPButton, .clipboardCPText").hide();
}
);';
print 'jQuery(\'.clipboardCPButton\').click(function() {
print 'jQuery(\'.clipboardCPButton, .clipboardCPValueToPrint\').click(function() {
/* console.log(this.parentNode); */
console.log("We click on a clipboardCPButton tag");
console.log("We click on a clipboardCPButton or clipboardCPValueToPrint class");
if (window.getSelection) {
selection = window.getSelection();