-
Notifications
You must be signed in to change notification settings - Fork 33
/
plugin.min.js
1 lines (1 loc) · 955 Bytes
/
plugin.min.js
1
(function(){var youtube=function(){"use strict";tinymce.PluginManager.requireLangPack("youtube");tinymce.PluginManager.add("youtube",function(editor,url){editor.ui.registry.addIcon("youtube-brands",'<svg width="24" height="24"><use xlink:href="'+url+'/img/youtube.svg#youtube-brands"></use></svg>');var _dialog=false;var _typeOptions=[];var _api=false;var _urlDialogConfig={title:"YouTube Title",url:url+"/youtube.html",width:800,height:620};editor.ui.registry.addButton("youtube",{icon:"youtube-brands",tooltip:"YouTube Tooltip",title:"YouTube Tooltip",onAction:()=>{_api=editor.windowManager.openUrl(_urlDialogConfig)}});editor.ui.registry.addMenuItem("youtube",{icon:"youtube-brands",text:"YouTube Tooltip",tooltip:"YouTube Tooltip",title:"YouTube Tooltip",onAction:()=>{_api=editor.windowManager.openUrl(_urlDialogConfig)}});return{getMetadata:function(){return{name:"YouTube Plugin",url:"https://github.com/gtraxx/tinymce-plugin-youtube"}}}})}()})();