Manual:CopyTextLayout

CopyTextLayout is a MediaWiki widget that features a button to copy the text provided. It is a OOUI based widget. It is a combination of OOUI's TextInputWidget and ButtonWidget.

Javascript Examples
Using the widget in MediaWiki Extension will be done through the 3 steps. First create the resource javascript file, Second register the js file in extension.json file. So that the module can load by ResourceLoader. And finally, load it by Output Context.
 * In MediaWiki Extension
 * Create the resource.js file in extension directory with following code.
 * Register the js file as module in extension.json
 * Finally load it by Output Context in your SpecialPage/ParserHook.