Files
MYSOPHAL/js/clipboard.min.js
BACHIR SOULDI f33121a308 Add GenericObject plugin files and assets
- Introduced default icon images in PNG and SVG formats.
- Added example icons for car and cube in SVG format.
- Created setup file for the GenericObject plugin with versioning and directory definitions.
- Included a header file with licensing information for the plugin.
- Added a remove.txt file with instructions for safe deletion.
2025-11-11 13:52:20 +01:00

1 line
696 B
JavaScript

$((function(){$(document).on("click",".copy_to_clipboard_wrapper",(function(e){var o=$(e.target);if(o.attr("class")=="copy_to_clipboard_wrapper"){o=o.find("*")}o.select();var t;try{t=document.execCommand("copy")}catch(e){t=false}o.blur();if(t){$(".copy_to_clipboard_wrapper.copied").removeClass("copied");o.parent(".copy_to_clipboard_wrapper").addClass("copied")}else{o.parent(".copy_to_clipboard_wrapper").addClass("copyfail")}}))}));function copyTextToClipboard(e){var o=document.createElement("textarea");o.value=e;o.setAttribute("readonly","");o.style={position:"absolute",visibility:"hidden"};document.body.appendChild(o);o.select();document.execCommand("copy");document.body.removeChild(o)}