{"name":"Popup Recorder","key":"popuprecorder","version":"1.0.5","instructions":"Embeds a Popup recorder that you can download recording from on the page.","showatto":"1","showplayers":"0","requirecss":"","requirejs":"https://cdn.jsdelivr.net/gh/justinhunt/cloudpoodll@latest/amd/build/cloudpoodll.min.js","shim":"","defaults":"","amd":"1","body":"<!-- Button trigger modal -->\n<button type=\"button\" class=\"btn btn-primary\" data-toggle=\"modal\" data-target=\"#@@AUTOID@@_trigger\">\n  Audio Recorder\n</button>\n\n<!-- Modal -->\n<div class=\"modal fade\" id=\"@@AUTOID@@_trigger\" tabindex=\"-1\" role=\"dialog\" aria-labelledby=\"exampleModalCenterTitle\" aria-hidden=\"true\">\n  <div class=\"modal-dialog modal-dialog-centered\" role=\"document\">\n    <div class=\"modal-content\">\n      <div class=\"modal-header\">\n        <h5 class=\"modal-title\" id=\"exampleModalLongTitle\">Record Audio</h5>\n        <button type=\"button\" class=\"close\" data-dismiss=\"modal\" aria-label=\"Close\">\n          <span aria-hidden=\"true\">&times;</span>\n        </button>\n      </div>\n      <div class=\"modal-body\">\n        <div id=\"@@AUTOID@@\" class=\"poodllrecorder\" data-parent=\"@@WWWROOT@@\" data-type=\"fresh\" data-width=\"380\" data-height=\"280\" data-id=\"@@AUTOID@@_widget\" data-media=\"audio\" data-token=\"@@CLOUDPOODLLTOKEN@@\" />\n      </div>\n     <div id=\"@@AUTOID@@_download\" style=\"display: none;\">\n           <a id=\"@@AUTOID@@_download_button\" class=\"btn btn-success pf-popuprecorder-downloadbutton\" download>Download</a>\n           <a id=\"@@AUTOID@@_reset_button\" href=\"#\" class=\"pf-popuprecorder-resetbutton\">New recording</a>\n    </div> \n    </div>\n  </div>\n</div>\n</div>","bodyend":"","script":"CloudPoodll = requiredjs_popuprecorder;\n\n//CloudPoodll.autoCreateRecorders();\nCloudPoodll.createRecorder(@@AUTOID@@);\n\nCloudPoodll.theCallback = function(message){\n   console.log(message);\n   switch(message.type){\n     case 'filesubmitted':\n       var dlink =\"https://cloud.poodll.com/local/cpapi/downloader.php?p=\"+message.mediaurl+\"&n=\"+message.mediafilename;\n       $('#' + @@AUTOID@@ + '_download_button').attr('href',dlink);\n       $('#' + @@AUTOID@@).hide();\n       $('#' + @@AUTOID@@ + '_download').show(); \n  }\n};\nCloudPoodll.initEvents();\n\n $('#' + @@AUTOID@@ + '_reset_button').click(function(){\n$('#' + @@AUTOID@@).empty();   \nCloudPoodll.createRecorder(@@AUTOID@@);\n$('#' + @@AUTOID@@).show();\n$('#' + @@AUTOID@@ + '_download').hide(); \n}\n);\n","style":".pf-popuprecorder-downloadbutton{\n    margin: auto;\n    text-align: center;\n    display: block;\n}\n.poodllrecorder{\nmargin: auto;\n}\n.pf-popuprecorder-resetbutton{\n    text-align: right;\n}","dataset":"","datasetvars":"","alternate":"","alternateend":""}