X7ROOT File Manager
Current Path:
/home/okeydcqc/okeyanueyiagu.com/wp-content/plugins/wp-optimize/js
home
/
okeydcqc
/
okeyanueyiagu.com
/
wp-content
/
plugins
/
wp-optimize
/
js
/
ðŸ“
..
📄
blockUI-4-2-4.min.js
(627 B)
📄
blockUI.js
(1.22 KB)
📄
cache-4-2-4.min.js
(8.04 KB)
📄
cache.js
(15.25 KB)
📄
delay-js-4-2-4.min.js
(1.16 KB)
📄
delay-js.js
(5.39 KB)
ðŸ“
handlebars
📄
heartbeat-4-2-4.min.js
(2.78 KB)
📄
heartbeat.js
(7.52 KB)
ðŸ“
jszip
📄
loadAsync-4-2-4.min.js
(304 B)
📄
loadAsync.js
(670 B)
📄
loadCSS-4-2-4.min.js
(818 B)
📄
loadCSS.js
(3.05 KB)
📄
minify-4-2-4.min.js
(11.89 KB)
📄
minify.js
(20.75 KB)
📄
modal-4-2-4.min.js
(922 B)
📄
modal.js
(1.79 KB)
📄
queue-4-2-4.min.js
(698 B)
📄
queue.js
(3.57 KB)
📄
send-command-4-2-4.min.js
(2.58 KB)
📄
send-command.js
(5.88 KB)
ðŸ“
serialize-json
ðŸ“
sortable
📄
status-4-2-4.min.js
(3.52 KB)
📄
status.js
(6.81 KB)
📄
wpo-images-view-4-2-4.min.js
(7.33 KB)
📄
wpo-images-view.js
(15.58 KB)
📄
wpoadmin-4-2-4.min.js
(37.22 KB)
📄
wpoadmin.js
(75.47 KB)
📄
wposmush-4-2-4.min.js
(22.94 KB)
📄
wposmush.js
(45.5 KB)
Editing: wposmush-4-2-4.min.js
jQuery(function(s){WP_Optimize_Smush=WP_Optimize_Smush()});var WP_Optimize_Smush=function(){function s(s){E(wposmush.server_check),data={server:wposmush.smush_settings.compression_server,skip_notice:!0},S("check_server_status",data,function(e){if(e.online){if(s.each(function(s,e){smush_image_list.push({attachment_id:parseInt(e.value),blog_id:wposmush.blog_id})}),data={optimization_id:"smush",selected_images:smush_image_list,smush_options:{compression_server:wposmush.smush_settings.compression_server,image_quality:wposmush.smush_settings.image_quality,lossy_compression:wposmush.smush_settings.lossy_compression,back_up_original:wposmush.smush_settings.back_up_original,preserve_exif:wposmush.smush_settings.preserve_exif}},smush_from_media_library=!0,smush_completed=!1,smush_timer_locked)return;E("",W.extend(V,{message:W("#wpo_smush_images_information_container")}),!1,!0),f(),smush_timer_handle=window.setInterval(r,1e3),S("process_bulk_smush",data)}else error_message=e.error?e.error+"<br>"+wposmush.server_error:wposmush.server_error,E(error_message)})}function e(s){smush_from_media_library=!0;var e=[],o=function(o){return function(a){e.push(o),1<e.length&&e.length===s.length?a(wposmush.images_restored_successfully):a()}};s.each(function(s,e){I(wposmush.blog_id,parseInt(e.value),o(parseInt(e.value)))})}function o(){var s=0==W('input[type="checkbox"]:checked',H).length;G.prop("disabled",s),L.prop("disabled",s)}function a(s,e){if(smush_mark_all_as_uncompressed){s=s?1:0,e=e?1:0;var o=W("#smush-information-modal-cancel-btn .smush-information");S("mark_all_as_uncompressed",{restore_backup:s,delete_only_backups_meta:e,skip_notice:!0},function(t){if(smush_mark_all_as_uncompressed)return t.hasOwnProperty("error")?(E(t.error),void _()):void(t.completed?(E("",W.extend(V,{message:W("#smush-information-modal")})),W("#smush-information-modal .smush-information").text(t.message),_()):(o.text(t.message),a(s,e)))})}}function t(s,e,o){var a=s.data("blog"),t=s.data("id"),i={attachment_id:t,blog_id:a},n=s.closest("#smush-metabox-inside-wrapper");data={selected_images:[i]},o===!1&&(data.unmark=!0),e.preventDefault(),E(wposmush.please_updating_images_info),S("mark_as_compressed",data,function(s){W("#smush-information-modal .smush-information").text(s.summary),E("",W.extend(V,{message:W("#smush-information-modal")})),s.status&&(n.length&&(o?(W(".wpo_smush_single_image",n).hide(),W(".wpo-toggle-advanced-options",n).removeClass("opened"),W(".wpo_smush_mark_single_image",n).hide(),W(".wpo_smush_unmark_single_image",n).show(),W(".wpo_restore_single_image",n).show(),W("#smush_info",n).text(s.info)):(W(".wpo_smush_single_image",n).show(),W(".wpo_smush_mark_single_image",n).show(),W(".wpo_smush_unmark_single_image",n).hide(),W(".wpo_restore_single_image",n).hide(),W("#smush_info",n).text(s.info))),s.hasOwnProperty("media_column_html")&&q(a,t,s.media_column_html))})}function n(){W(this).toggleClass("opened"),W(this).hasClass("opened")?W(this).text(wposmush.less):W(this).text(wposmush.more)}function _(s){var s="undefined"==typeof s||s,e={use_cache:s};J.html("..."),z(!0),Q.push(F.add_agent({_wait:!1,_keep:!1,command:"updraft_smush_ajax",command_data:{data:e,subaction:"get_ui_update"},callback:function(s){C(s,l),O(),z(!1),o()}})),Y=!0}function m(){W("#wpo_smush_images_grid input:checked").each(function(){image={attachment_id:W(this).val(),blog_id:W(this).data("blog")},smush_image_list.push(image)}),data={optimization_id:"smush",selected_images:smush_image_list,smush_options:{compression_server:W("input[name='compression_server']:checked").val(),image_quality:W("#image_quality").val(),lossy_compression:W("#smush-lossy-compression").is(":checked"),back_up_original:W("#smush-backup-original").is(":checked"),preserve_exif:W("#smush-preserve-exif").is(":checked")}},g(),Q.push(F.add_agent({_wait:!1,_keep:!1,command:"updraft_smush_ajax",command_data:{data:data,subaction:"process_bulk_smush"}}))}function u(){if(W("#wp-optimize-wrap").length){W("#wpo_smush_images_save_options_spinner").show().delay(3e3).fadeOut();var s=ss();S("update_smush_options",s,function(s){W("#wpo_smush_images_save_options_spinner").hide(),s.hasOwnProperty("saved")&&s.saved?W("#wpo_smush_images_save_options_done").show().delay(3e3).fadeOut():W("#wpo_smush_images_save_options_fail").show().delay(3e3).fadeOut()})}}function r(){smush_timer_locked=!0,smush_total_seconds++,seconds=smush_total_seconds%60+""<10?"0"+smush_total_seconds%60:smush_total_seconds%60,minutes=parseInt(smush_total_seconds/60)+""<10?"0"+parseInt(smush_total_seconds/60):parseInt(smush_total_seconds/60),W("#smush_stats_timer").text(minutes+":"+seconds),c(smush_total_seconds)}function c(s){0==s%3&&p(s),0==s%60&&(null!=T&&(F.cancel_agent(T),T=null),Q.push(F.add_agent({_wait:!1,command:"updraft_smush_ajax",command_data:{data:{},subaction:"process_pending_images"},callback:function(s){C(s,b)}})))}function p(s){data={update_ui:!0,use_cache:!1};var e=s<5,o=F.add_agent({_wait:!e,_keep:!1,command:"updraft_smush_ajax",command_data:{data:data,subaction:"get_ui_update"},callback:function(s){C(s,b)}});null!==o&&(T=o,Q.push(o))}function l(s){if(H.html(""),s&&s.hasOwnProperty("unsmushed_images")){var e=s.unsmushed_images,o=s.pending_tasks,a=0;if(0==e.length&&0==o&&H.text(wposmush.all_images_compressed).wrapInner("<div class='wpo-fieldgroup'> </div>"),1===s.is_multisite)a=uncompressed_images_sites_select.find(":selected").val(),d(a,s);else for(a in s.unsmushed_images)d(a,s)}}function h(s,e){return s.id-e.id}function d(s,e){var o="post.php?post=",a="&action=edit",t=e.admin_urls[s],n=e.unsmushed_images[s];"undefined"!=typeof n&&n.sort(h);for(i in n)if(n.hasOwnProperty(i)){var _=n[i];x(_,s,t+o+_.id+a)}}function g(){smush_timer_locked||(E("",W.extend(V,{message:W("#wpo_smush_images_information_container")}),!1,!0),f(),smush_timer_handle=window.setInterval(r,1e3),z(!0))}function f(){W("#smush_stats_pending_images").html("..."),W("#smush_stats_completed_images").html("..."),W("#smush_stats_bytes_saved").html("..."),W("#smush_stats_percent_saved").html("..."),W("#smush_stats_timer").html("...")}function w(s){for(var e in s)s.hasOwnProperty(e)&&W("#post-"+e+" .column-wpo_smush").html(s[e]);M()}function b(s){W("#smush_stats_pending_images").html(s.pending_tasks),W("#smush_stats_completed_images").html(s.completed_task_count),W("#smush_stats_bytes_saved").html(s.bytes_saved),W("#smush_stats_percent_saved").html(s.percent_saved),1==s.smush_complete&&setTimeout(function(){v(function(){_(!1)})},1500)}function v(s){data={update_ui:!0,use_cache:!1,image_list:smush_image_list},function(s){Q.push(F.add_agent({_unique:!1,_wait:!1,_keep:!1,command:"updraft_smush_ajax",command_data:{data:data,subaction:"get_ui_update"},callback:function(e){summary=e.session_stats,e.session_stats&&(0!=e.completed_task_count&&(summary+="<hr>"+e.summary),k(summary),s instanceof Function&&s())}}))}(s)}function k(s){smush_completed||(W("#summary-message").html(s),y(),E("",W.extend(V,{message:W("#smush-complete-summary")})),smush_completed=!0,F.cancel_agents(Q))}function y(){smush_total_seconds=0,smush_timer_locked=!1,smush_completed=!1,smush_image_list=[],F.cancel_agents(Q),clearInterval(smush_timer_handle),z(!1)}function x(s,e,o){var a=["wpo_smush_",e,"_",s.id].join("");image_html='<div class="wpo_smush_image" data-filesize="'+s.filesize+'">',image_html+='<a class="button" href="'+o+'" target="_blank"> '+wposmush.view_image+" </a>",image_html+='<input id="'+a+'" type="checkbox" data-blog="'+e+'" class="wpo_smush_image__input" value="'+s.id+'">',image_html+='<label for="'+a+'"></a>',image_html+='<div class="thumbnail">',image_html+='<img class="lazyload" src="'+s.thumb_url+'">',image_html+="</div></label></div>",H.append(image_html)}function O(){features=wposmush.features,service=W("input[name^='compression_server']:checked").val();for(feature in features[service])W("."+feature).prop("disabled",!features[service][feature]);W(".wpo_smush_image").each(function(){W(this).data("filesize")>wposmush.features[service].max_filesize?W(this).hide():W(this).show()})}function z(s){W.each([G,Z,A,N,L],function(e,o){o.prop("disabled",s)}),s?(W("#wpo_smush_images_refresh").hide(),W(".wpo_smush_images_loader").show()):(W("#wpo_smush_images_refresh").show(),W(".wpo_smush_images_loader").hide())}function P(s,e){0!=s.length&&(data={selected_image:s,smush_options:e},E(wposmush.compress_single_image_dialog,{},!1,!0),S("compress_single_image",data,function(s){C(s,j)}))}function I(s,e,o){if(0!=e.length){E(wposmush.please_wait);var a={blog_id:s,selected_image:e};S.apply({unique:!1},["restore_single_image",a,function(s){var e=function(e){"undefined"!=typeof e&&(s.summary=e),C(s,j)};o instanceof Function?o(e):e()}])}}function j(s){if(s.hasOwnProperty("success")&&s.success){W(".smush-information").text(s.summary),E("",W.extend(V,{message:W("#smush-information-modal")})),W(".wpo-toggle-advanced-options.wpo_smush_single_image").removeClass("opened"),D(s.operation,s.summary,s.restore_possible,s);var e=s.blog_id||s.options.blog_id,o=s.image||s.options.attachment_id;smush_affected_images.hasOwnProperty(e)||(smush_affected_images[e]={}),smush_affected_images[e].hasOwnProperty(o)||(smush_affected_images[e][o]={}),s.hasOwnProperty("media_column_html")&&q(e,o,s.media_column_html),"compress"==s.operation?smush_affected_images[e][o]={operation:s.operation,summary:s.summary,restore_possible:s.restore_possible}:(o&&M(),smush_affected_images[e][o]={operation:s.operation})}else E(s.error_message)}function q(s,e,o){W(['.wpo-smush-media-library-column[data-blog="',s,'"][data-id="',e,'"]'].join("")).parent().html(o)}function D(s,e,o,a){var t=W("#smush_info").closest("#smush-metabox-inside-wrapper");0!==t.length&&("compress"==s?(W(".wpo_smush_single_image").hide(),W(".wpo_restore_single_image").show(),a&&a.hasOwnProperty("sizes-info")?(W("#smush_info").text(e),W("#wpo_smush_details").html(a["sizes-info"])):(W("#smush_info").text(e),W("#wpo_smush_details").text("").hide()),W(".wpo_smush_mark_single_image").hide(),o?W(".restore_possible").show():W(".restore_possible").hide()):(W(".wpo_smush_single_image").show(),W(".wpo_restore_single_image").hide(),W(".wpo_smush_mark_single_image").show(),W(".wpo_smush_unmark_single_image",t).hide()))}function C(s,e){s&&s.hasOwnProperty("status")&&s.status?e&&e(s):(alert(wposmush.error_unexpected_response),console.log(s))}function U(){return W('input[name="media[]"]:checked')}function K(){var s=[],e=U();return e.each(function(e,o){s.push(parseInt(o.value))}),s}function M(){W("#bulk-action-selector-top, #bulk-action-selector-bottom").val("-1"),W('input[name="media[]"]:checked, #cb-select-all-1, #cb-select-all-2').prop("checked",!1)}function S(s,e,o,a){a="undefined"==typeof a||a,e=e.hasOwnProperty("skip_notice")&&1===Object.keys(e).length||W.isEmptyObject(e)?{use_cache:!1}:e,function(o,t,i){Q.push(F.add_agent({_wait:!1,_keep:t,_unique:i,command:"updraft_smush_ajax",command_data:{data:e,subaction:s},callback:function(s){if(a){try{var e=wpo_parse_json(s)}catch(t){console.log("smush_manager_send_command JSON parse error"),console.log(t),console.log(s),alert(wposmush.error_unexpected_response)}"undefined"!=typeof o&&o(e)}else"undefined"!=typeof o&&o(s)}}))}(o,this.keep,this.unique)}var W=jQuery,F=WP_Optimize_Heartbeat(),Q=[],T=null,E=wp_optimize.block_ui,H=W("#wpo_smush_images_grid"),J=W("#smush_info_images"),N=W("#wpo_smush_images_refresh"),Z=W("#wpo_smush_images_select_all"),A=W("#wpo_smush_images_select_none"),B=W("#wpo_smush_clear_stats_btn"),G=W("#wpo_smush_images_btn"),L=W("#wpo_smush_mark_as_compressed"),R=W(".wpo_smush.column-wpo_smush .convert-to-webp");smush_mark_all_as_uncompressed_btn=W("#wpo_smush_mark_all_as_uncompressed_btn"),restore_all_compressed_images_btn=W("#wpo_smush_restore_all_compressed_images_btn"),smush_view_logs_btn=W(".wpo_smush_get_logs"),smush_delete_backup_images_btn=W("#wpo_smush_delete_backup_btn"),compression_server_select=W(".compression_server"),reset_webp_serving_method_btn=W("#wpo_reset_webp_serving_method"),smush_images_tab_loaded=!1,smush_service_features=[],smush_total_seconds=0,smush_timer_locked=!1,smush_timer_handle=0,smush_image_list=[],smush_completed=!1,smush_from_media_library=!1,smush_mark_all_as_uncompressed=!1,smush_affected_images={},pending_tasks_cancel_btn=W("#wpo_smush_images_pending_tasks_cancel_button"),uncompressed_images_sites_select=W("#wpo_uncompressed_images_sites_select");var V={baseZ:160001,css:{top:"50%",transform:"translate(0, -50%)",width:"400px",padding:"20px",cursor:"pointer"}};W("#doaction, #doaction2").on("click",function(o){o.stopImmediatePropagation();var a=W(this).prev("select").val();if("wp_optimize_bulk_compression"===a||"wp_optimize_bulk_restore"===a){var t=U();0!==t.length&&(o.preventDefault(),"wp_optimize_bulk_compression"===a&&s(t),"wp_optimize_bulk_restore"===a&&e(t))}}),H.on("click",".thumbnail",function(s){W(this).closest('input[type="checkbox"]').prop("checked",!0)});var X=!1;H.on("mousedown",".thumbnail",function(s){X=s.shiftKey||s.ctrlKey}),H.on("mouseup",".thumbnail",function(s){X=s.shiftKey||s.ctrlKey}),reset_webp_serving_method_btn.on("click",function(s){s.preventDefault(),S("reset_webp_serving_method",{skip_notice:!0},function(s){s.success?W("#wpo_reset_webp_serving_method_done").show().delay(3e3).fadeOut():(W("#enable_webp_conversion").prop("checked",!1),W("#smush-information-modal .smush-information").text(s.error_message),E("",W.extend(V,{message:W("#smush-information-modal")}),!1,!0))})});var Y=!1;W("#wp-optimize-nav-tab-wrapper__wpo_images .nav-tab").on("click",function(){Y||W(this).is("#wp-optimize-nav-tab-wpo_images-smush")&&_(!1)}),W("#wp-optimize-wrap").on("page-change",function(s,e){Y||"wpo_images"==e.page&&W("#wp-optimize-nav-tab-wrapper__wpo_images .nav-tab-active").is("#wp-optimize-nav-tab-wpo_images-smush")&&_(!1)}),W("#smush-metabox").length>0&&O();var $=null;H.on("click",".wpo_smush_image",function(s){var e=W('#wpo_smush_images_grid input[type="checkbox"]'),a=W(this).find(".wpo_smush_image__input"),t=!a.prop("checked");if($||(W(this).find(".wpo_smush_image__input").prop("checked",t),$=a),!0===X){var i=e.index(a),n=e.index($);i===n?e.slice(Math.min(i,n),Math.max(i,n)+1).prop("checked",t):!0===$.prop("checked")&&e.slice(Math.min(i,n),Math.max(i,n)+1).prop("checked",t)}$=a,o()}),o(),compression_server_select.on("change",function(s){O(),u()}),G.off().on("click",function(){return 0==W('#wpo_smush_images_grid input[type="checkbox"]:checked').length?void E(wposmush.please_select_images):(E(wposmush.server_check),data={server:W("input[name='compression_server']:checked").val(),skip_notice:!0},void S("check_server_status",data,function(s){s.online?m():(error_message=s.error?s.error+"<br>"+wposmush.server_error:wposmush.server_error,E(error_message))}))}),L.off().on("click",function(){var s,e=[];W("#wpo_smush_images_grid input:checked").each(function(){s={attachment_id:W(this).val(),blog_id:W(this).data("blog")},e.push(s)}),E(wposmush.please_updating_images_info),S("mark_as_compressed",{selected_images:e},function(s){W("#smush-information-modal .smush-information").text(s.summary),E("",W.extend(V,{message:W("#smush-information-modal")})),_(!1)})}),smush_mark_all_as_uncompressed_btn.on("click",function(){if(confirm(wposmush.mark_all_images_uncompressed)){var s=confirm(wposmush.restore_images_from_backup);E(wposmush.please_wait),smush_mark_all_as_uncompressed=!0,a(s)}}),restore_all_compressed_images_btn.on("click",function(){confirm(wposmush.restore_all_compressed_images)&&(E(wposmush.please_wait),smush_mark_all_as_uncompressed=!0,a(!0,!0))}),W('#smush-information-modal-cancel-btn input[type="button"]').on("click",function(){smush_mark_all_as_uncompressed=!1,_(),W.unblockUI()}),N.off().on("click",function(){_(!1)}),Z.off().on("click",function(){W('#wpo_smush_images_grid input[type="checkbox"]').prop("checked",!0),$=null,o()}),A.off().on("click",function(){W('#wpo_smush_images_grid input[type="checkbox"]').prop("checked",!1),$=null,o()}),smush_view_logs_btn.off().on("click",function(){W("#log-panel").text("Please wait, fetching logs."),S("get_smush_logs",{},function(s){W.blockUI({message:W("#smush-log-modal"),onOverlayClick:W.unblockUI(),css:{width:"80%",height:"80%",top:"15%",left:"15%"}}),W("#log-panel").html("<pre>"+s+"</pre>"),download_link=ajaxurl+"?action=updraft_smush_ajax&subaction=get_smush_logs&nonce="+wposmush.smush_ajax_nonce,W("#smush-log-modal a").attr("href",download_link)},!1)}),smush_delete_backup_images_btn.on("click",function(){if(confirm(wposmush.delete_image_backup_confirm)){smush_delete_backup_images_btn.prop("disabled",!0);var s=W("#wpo_smush_delete_backup_spinner"),e=W("#wpo_smush_delete_backup_done");s.show(),S("clean_all_backup_images",{},function(){s.hide(),smush_delete_backup_images_btn.prop("disabled",!1),e.css("display","inline-block").delay(3e3).fadeOut()})}}),B.off().on("click",function(s){W("#wpo_smush_images_clear_stats_spinner").show().delay(3e3).fadeOut(),S("clear_smush_stats",{},function(s){W("#wpo_smush_images_clear_stats_spinner").hide(),W("#wpo_smush_images_clear_stats_done").show().delay(3e3).fadeOut()})}),W("body").on("click","#wpo_smush_images_pending_tasks_cancel_button",function(s){wposmush.cancel===pending_tasks_cancel_btn.val()&&(pending_tasks_cancel_btn.val(wposmush.cancelling),pending_tasks_cancel_btn.prop("disabled",!0)),S("clear_pending_images",{restore_images:smush_image_list},function(s){W.unblockUI(),s.status?(_(),y()):console.log("Cancelling pending images apparently failed.",s),pending_tasks_cancel_btn.val(wposmush.cancel),pending_tasks_cancel_btn.prop("disabled",!1)})}),W(".column-wpo_smush").on("click",".wpo-smush-compress-popup-btn",function(s){var e=W(this).data("id"),o=W(this).data("blog");s.preventDefault(),S("get_smush_settings_form",{attachment_id:e,blog_id:o},function(s){if(s.success){var a=['<div class="wpo-smush-compress-popup-content">',"<h3>",wposmush.compress_image,"</h3>",s.html,"</div>",'<div class="wpo_smush_single_image action_button" style="display:inline-block;">','<input type="button" data-blog="',o,'" data-id="',e,'" id="smush_compress_',e,'" class="button-primary button" value="',wposmush.compress,'">',"</div>"," ",'<a href="#" class="button wpo-smush-popup-cancel-btn">',wposmush.close,"</a>"].join("");E("",W.extend(V,{message:a}))}})}),W("body").on("click",".wpo-smush-popup-cancel-btn",function(s){s.preventDefault(),W.unblockUI()}),W("body").on("click",".wpo_smush_single_image .button",function(){image={attachment_id:W(this).data("id"),blog_id:W(this).data("blog")},W("#enable_custom_compression").is(":checked")?image_quality=W("#custom_compression_slider").val():image_quality=W("#enable_lossy_compression").is(":checked")?60:92,lossy_compression=image_quality<92,smush_options={compression_server:W("input[name='compression_server_"+image.attachment_id+"']:checked").val(),image_quality:image_quality,lossy_compression:lossy_compression,back_up_original:W("#smush_backup_"+image.attachment_id).is(":checked"),preserve_exif:W("#smush_exif_"+image.attachment_id).is(":checked")},data={server:W("input[name='compression_server_"+W(this).attr("id").substring(15)+"']:checked").val()},E(wposmush.server_check),S("check_server_status",data,function(s){s.online?P(image,smush_options):(error_message=s.error?s.error+"<br>"+wposmush.server_error:wposmush.server_error,E(error_message))})}),W("body").on("click",".wpo_restore_single_image .button, .wpo_restore_single_image a",function(s){var e=W(this);blog_id=e.data("blog"),image_id=e.data("id"),s.preventDefault(),image_id&&blog_id&&I(blog_id,image_id)}),W("body").on("click",".wpo_smush_mark_single_image .button, .wpo_smush_mark_single_image a",function(s){t(W(this),s,!0)}),W("body").on("click",".wpo_smush_unmark_single_image .button, .wpo_smush_unmark_single_image a",function(s){t(W(this),s,!1)}),W("body").on("click","#wpo_smush_details .wpo-collapsible",n),W("body").on("click",".column-wpo_smush .wpo-collapsible",n),W("body").on("click","#smush-log-modal .close, #smush-information-modal .information-modal-close",function(){W.unblockUI(),smush_from_media_library&&M()}),W("body").on("click",".wpo_smush_stats_cta_btn, .wpo_smush_get_logs, #smush-complete-summary .close",function(){if(W.unblockUI(),smush_from_media_library){var s=K();S("get_smush_details",{selected_images:s},function(s){s.success?(window.clearInterval(smush_timer_handle),w(s.smush_details)):console.log(s)})}else _(),setTimeout(y,500)}),W("body").on("click",".wpo-toggle-advanced-options",function(s){s.preventDefault(),W(this).toggleClass("opened")}),W(".wpo-fieldgroup .autosmush input, .wpo-fieldgroup .compression_level, .wpo-fieldgroup .image_options, #smush-show-metabox").on("change",function(s){u()}),W("body").on("change",".smush-options.compression_level",function(){W("#enable_custom_compression").is(":checked")?W(".smush-options.custom_compression").show():W(".smush-options.custom_compression").hide()}),W("body").on("change",'.smush-advanced input[type="radio"]',function(){O()}),W("#enable_webp_conversion").on("change",function(s){if(W("#wp-optimize-wrap").length){W("#wpo_smush_images_save_options_spinner").show().delay(3e3).fadeOut(),W("#enable_webp_conversion").prop("disabled",!0);var e=ss();e.skip_notice=!0,S("update_webp_options",e,function(s){if(W("#wpo_smush_images_save_options_spinner").hide(),s.hasOwnProperty("saved")&&s.saved)W("#wpo_smush_images_save_options_done").show().delay(3e3).fadeOut();else{if(W("#enable_webp_conversion").prop("checked",!1),"update_failed_no_working_webp_converter"===s.error_code){var e="<p>"+wposmush.webp_conversion_tool_error+' <a href="https://teamupdraft.com/documentation/wp-optimize/topics/image-compression/troubleshooting/the-webp-conversion-tool-is-not-working/" target="_blank">'+wposmush.webp_conversion_tool_how_to+"</a></p>";W("#smush-information-modal .smush-information").html(e)}else W("#smush-information-modal .smush-information").text(s.error_message);E("",W.extend(V,{message:W("#smush-information-modal")}),!1,!0)}W("#enable_webp_conversion").prop("disabled",!1)})}}),R.on("click",function(s){s.preventDefault();var e=W(this);data={attachment_id:W(this).data("attachment-id"),skip_notice:!0},E(wposmush.converting_to_webp,{},0,!0),S("convert_to_webp_format",data,function(s){s.error?E(s.error,{},2e3):(E(s.success,{},2e3),e.next().remove(),e.remove())})}),uncompressed_images_sites_select.on("change",function(){_()}),W(document).on("admin-metabox-smush-loaded",function(){var s=W('.wpo_restore_single_image input[type="button"]').first().data();if(s&&smush_affected_images.hasOwnProperty(s.blog)&&smush_affected_images[s.blog].hasOwnProperty(s.id)){var e=smush_affected_images[s.blog][s.id];"compress"==e.operation?D(e.operation,e.summary,e.restore_possible,e):D(e.operation)}}),F.setup();var ss=function(){var s="";s=W("#enable_custom_compression").is(":checked")?W("#custom_compression_slider").val():W("#enable_lossy_compression").is(":checked")?60:92;var e=s<92;return{compression_server:W("input[name='compression_server']:checked").val(),image_quality:s,lossy_compression:e,back_up_original:W("#smush-backup-original").is(":checked"),back_up_delete_after:W("#smush-backup-delete").is(":checked"),back_up_delete_after_days:W("#smush-backup-delete-days").val(),preserve_exif:W("#smush-preserve-exif").is(":checked"),autosmush:W("#smush-automatically").is(":checked"),show_smush_metabox:W("#smush-show-metabox").is(":checked"),webp_conversion:W("#enable_webp_conversion").is(":checked")}};wp_optimize.smush_settings=ss};
Upload File
Create Folder