Changeset 1996350
- Timestamp:
- 12/17/2018 12:00:32 PM (7 years ago)
- Location:
- qibla-events/tags/1.0.2
- Files:
-
- 4 edited
- 5 copied
-
. (copied) (copied from qibla-events/trunk)
-
assets/js/map/map-listings.js (modified) (4 diffs)
-
assets/js/map/map-listings.min.js (modified) (1 diff)
-
changelog.txt (copied) (copied from qibla-events/trunk/changelog.txt) (1 diff)
-
index.php (copied) (copied from qibla-events/trunk/index.php)
-
readme.md (copied) (copied from qibla-events/trunk/readme.md)
-
readme.txt (copied) (copied from qibla-events/trunk/readme.txt)
-
src/Functions/Kses.php (modified) (1 diff)
-
src/Plugin.php (modified) (1 diff)
Legend:
- Unmodified
- Added
- Removed
-
qibla-events/tags/1.0.2/assets/js/map/map-listings.js
r1923077 r1996350 514 514 515 515 /** 516 * toggleLoaderTimeOut in complete filter 517 * 518 * @since 1.0.1 519 * 520 * @param {object} element The element in which append the loader 521 * @param {Function} inCallback The callback to call after the loader become visible. 522 * @param {Function} outCallback The callback to call after the loader become hidden. 523 */ 524 toggleLoaderTimeOut: function (element, inCallback, outCallback) { 525 if (element.lastElementChild.classList.contains('ajax-loader')) { 526 DL.Utils.UI.toggleLoader(element.firstElementChild, inCallback, outCallback); 527 } 528 }, 529 530 /** 516 531 * Filter the listings 517 532 * … … 560 575 var elementToScrollTo = document.body.classList.contains('is-safari') || 561 576 document.body.classList.contains('is-edge') || 562 document.body.classList.contains('is-mobile') ? ' body' : 'html';577 document.body.classList.contains('is-mobile') ? 'html,body' : 'html'; 563 578 564 579 $(elementToScrollTo).animate({ … … 618 633 }); 619 634 620 if (this.listingsListEl().lastElementChild.classList.contains('ajax-loader')) { 635 // After testing on fast servers, it seems that the listings are recovered 636 // and changed before the code checks the status of the upload. 637 // This causes the loader to stop, and does not show 638 // the listings because they are set to display none. 639 setTimeout(this.toggleLoaderTimeOut, 500, this.listingsListEl(), 640 function () { 641 this.updateListingsContainerBoxModel(); 642 this.toggleElementsWhenFetching(); 643 }.bind(this) 644 ); 645 646 /*if (this.listingsListEl().lastElementChild.classList.contains('ajax-loader')) { 621 647 DL.Utils.UI.toggleLoader( 622 648 this.listingsListEl().firstElementChild, … … 628 654 }.bind(this) 629 655 ); 630 } 656 }*/ 631 657 }.bind(this), 632 658 -
qibla-events/tags/1.0.2/assets/js/map/map-listings.min.js
r1923077 r1996350 1 window.DL=window.DL||{},window.DlMap=window.DlMap||{},window.DlListings=window.DlListings||{},function(o,l,t,e,i,r,a,s,n,c,d,u){"use strict";u.Listings=u.Listings||{},u.Listings.Filter={listingsListEl:function(){return document.querySelector(".dllistings-list")},useMap:function(){return Boolean(u.Utils.Functions.classList(document.body).contains("dl-is-listings--with-map"))},useScMap:function(){var t=document.getElementById("dlgoogle-map");return!!t&&Boolean(u.Utils.Functions.classList(t).contains("dlsc-map"))},visibleMap:function(){return window.dllistings.mapVisible||this.useScMap()},getFormTriggers:function(){return this.form.querySelectorAll(".dllistings-ajax-filter-trigger")},updateMap:function(){a.map.reCenter(),a.map.setEvents()},buildAutoupdateList:function(){if(l.isEmpty(this.autoUpdate)){var t=this.form.querySelectorAll(".is-autoupdate");t&&l.forEach(t,function(t){var e=u.Utils.String.toSlug(t.getAttribute("data-autoupdate"));e&&(this.autoUpdate[e]={instance:t,filter:t.getAttribute("data-autoupdate")})}.bind(this))}},updateAutoupdateFiltersMarkup:function(t){l.isEmpty(t)||(l.forEach(t,function(t,e){l.isUndefined(this.autoUpdate[e])||(this.autoUpdate[e].instance.innerHTML=t)}.bind(this)),u.Listings.FilterToggler.counterChecked(),u.Listings.FilterToggler.updateCheckboxCounter())},postData:function(t){var i="dlajax_action=listings_filter&"+o(this.form).serialize();l.isEmpty(this.autoUpdate)&&this.buildAutoupdateList(),l.forEach(this.autoUpdate,function(t,e){i+="&auto_update_filters["+t.filter+"]=1"}),l.isFunction(t)&&t(i)},init:function(){this.visibleMap()&&(a.map=new a.Map(document.querySelector("#dlgoogle-map"),window.dlgooglemap),a.markerCollection=new a.Backbone.Collections.Marker(null,{model:a.Backbone.Models.Marker})),this.archiveDescriptionModel=new s.Backbone.Models.ArchiveDescription,this.archiveDescriptionView=new s.Backbone.Views.ArchiveDescription({model:this.archiveDescriptionModel}),this.foundPostsModel=new s.Backbone.Models.FoundPosts,this.foundPostsView=new s.Backbone.Views.FoundPosts({model:this.foundPostsModel}),this.paginationModel=new s.Backbone.Models.Pagination,this.paginationView=new s.Backbone.Views.Pagination({model:this.paginationModel}),this.listingsCollection=new s.Backbone.Collections.Listings(null,{model:s.Backbone.Models.Listings}),l.isEmpty(d)||l.isEmpty(d.posts)||(this.listingsCollection.add(d.posts),this.visibleMap()&&(a.markerCollection.add(d.posts),a.map.markerCluster=new r(a.map,a.markerCollection.getMarkerRefs(),{gridSize:50,maxZoom:15,minimumClusterSize:2,ignoreHidden:!0},l.template(document.querySelector("#dltmpl_map_markerclusterer").innerHTML)),this.updateMap()),this.setPagionationAjaxTrigger(),window.jsonListings=void 0),this.setTriggers()},setPagionationAjaxTrigger:function(){var t,i=this,e=document.querySelector(".dlpagination");e&&(t=e.querySelectorAll("a.page-numbers")).length&&l.forEach(t,function(t){t.addEventListener("click",function(t){t.preventDefault(),clearTimeout(e);var e=setTimeout(function(){i.filter(t)},0)})})},setTriggers:function(){if(this.useMap()||!this.useScMap()){if(void 0===this.form||null===this.form)throw"Invalid form element when set triggers.";this.form.addEventListener("submit",this.filter.bind(this)),this.form.addEventListener("reset",this.filter.bind(this)),l.forEach(this.getFormTriggers(),function(t){var e;switch(t.nodeName){case"SELECT":e="select2change","qibla_"+t.getAttribute("data-taxonomy")+"_filter"===t.getAttribute("id")&&function(t,e){t.addEventListener(e,function(){var t=this.form.querySelectorAll(".geocode-input");t.length&&l.forEach(t,function(t){t.remove()});var e=this.form.querySelector("#geocode_nonce");e&&e.remove()}.bind(this))}.call(this,t,"select2change");break;case"INPUT":e="change";break;default:e="click"}t.addEventListener(e,this.filter.bind(this))}.bind(this))}},noPostsFound:function(t){var e=this.listingsListEl().firstElementChild;e&&(e.innerHTML=t)},toggleElementsWhenFetching:function(){var t=document.querySelector(".dlarchive-description"),e=document.querySelector(".dlarchive-listings-footer");e&&u.Utils.Functions.classList(e).toggle("is-hidden"),t&&u.Utils.Functions.classList(t).toggle("is-hidden")},updateListingsContainerBoxModel:function(t){var e=function(t){this.listingsListEl().style.height=t}.bind(this),i=function(){0===--n&&e("auto")};if(!this.visibleMap())if(t)e(this.listingsListEl().firstElementChild.clientHeight+"px");else{var s=this.listingsListEl().querySelectorAll("img"),n=s.length;l.forEach(s,function(t){t.complete?i():o(t).load(i)}.bind(this))}}, filter:function(n){var t=this.ajaxUrl;if(!(n instanceof Event&&("reset"!==n.type&&(n.preventDefault(),n.stopPropagation()),n.target.classList.contains("page-numbers")?t=n.target.getAttribute("href"):"I"===n.target.tagName&&n.target.parentNode.classList.contains("page-numbers")&&(t=n.target.parentNode.getAttribute("href")),"select2change"===n.type&&this.form.classList.contains("dlform-filter--open")))){this.listingsCollection.url=t;var e=document.body.classList.contains("is-safari")||document.body.classList.contains("is-edge")||document.body.classList.contains("is-mobile")?"body":"html";o(e).animate({scrollTop:0},function(){this.listingsListEl()&&u.Utils.UI.toggleLoader(this.listingsListEl().firstElementChild),this.postData(function(t){this.listingsCollection.fetch({type:"post",reset:!0,silent:!1,data:t,beforeSend:function(){u.Utils.Events.dispatchEvent("listings-collection-fetching",this.form,null,{obj:this,eventParent:n}),this.toggleElementsWhenFetching(),this.updateListingsContainerBoxModel(!0)}.bind(this),complete:function(){u.Utils.Events.dispatchEvent("listings-collection-fetched",this.form,null,{obj:this,eventParent:n}),this.listingsListEl().lastElementChild.classList.contains("ajax-loader")&&u.Utils.UI.toggleLoader(this.listingsListEl().firstElementChild,function(){this.updateListingsContainerBoxModel(),this.toggleElementsWhenFetching()}.bind(this))}.bind(this),success:function(t,e,i){if(t.models&&(u.Listings.Filter.visibleMap()&&a.markerCollection.reset(),l.forEach(t.models,function(t){t.trigger("update"),u.Listings.Filter.visibleMap()&&a.markerCollection.add(t.attributes)})),u.Utils.Events.dispatchEvent("listings-collection-success-fetched",this.form,null,{obj:this,eventParent:n}),e.foundPosts.number){var s=document.querySelector(".dlnocontent-found-listings");s&&s.remove(),u.Listings.Filter.visibleMap()&&(a.map.markerCluster=new r(a.map,a.markerCollection.getMarkerRefs(),{gridSize:50,maxZoom:15,minimumClusterSize:2,ignoreHidden:!0},l.template(document.querySelector("#dltmpl_map_markerclusterer").innerHTML)),this.updateMap())}else this.noPostsFound(e.noContentFoundTemplate);this.foundPostsModel.set(e.foundPosts),this.archiveDescriptionModel.set(e.archiveDescription),this.paginationModel.set(e.pagination),this.setPagionationAjaxTrigger(),"autoUpdateFilters"in e&&this.updateAutoupdateFiltersMarkup(e.autoUpdateFilters)}.bind(this)})}.bind(this))}.bind(this))}},construct:function(t,e,i){if(l.bindAll(this,"getFormTriggers","updateMap","postData","init","setPagionationAjaxTrigger","setTriggers","noPostsFound","toggleElementsWhenFetching","filter","updateListingsContainerBoxModel","updateAutoupdateFiltersMarkup","buildAutoupdateList"),i||this.useMap()||this.useScMap())return i&&(this.ajaxUrl=t,this.form=i,this.userPosition=e,this.data=null,this.autoUpdate={}),this}},u.Listings.FilterFactory=function(t,e,i){return Object.create(u.Listings.Filter).construct(t,e,i)},u.Listings.FilterToggler={useMap:function(){return Boolean(u.Utils.Functions.classList(document.body).contains("dl-is-listings--with-map"))},useScMap:function(){var t=document.getElementById("dlgoogle-map");return!!t&&Boolean(u.Utils.Functions.classList(t).contains("dlsc-map"))},visibleMap:function(){return window.dllistings.mapVisible||this.useScMap()},toggle:function(t){var e=this;"A"===t.target.tagName&&(t.preventDefault(),t.stopImmediatePropagation()),this.actions.style.display="none",o(this.filters).slideToggle(375,function(){if(e.isOpen=!e.isOpen,e.isOpen?(e.form.classList.add("dlform-filter--open"),e.actions.style.display="block"):e.form.classList.remove("dlform-filter--open"),this.style.overflowY="scroll",e.useMap()&&(e.form.parentElement.style.overflowY="hidden"),e.isOpen){var t=e.container.querySelector("#dltogglers");t&&(t=e.container.querySelector("#dltogglers").clientHeight)}else this.style.overflowY="auto",e.useMap()&&(e.form.parentElement.style.overflowY="auto")})},updateCheckboxCounter:function(){var t=document.querySelectorAll("[type=checkbox]:checked"),e=document.querySelector("#dltoggler_filters > span");0<t.length?e.innerText=t.length:e.innerText=""},counterChecked:function(){l.forEach(document.querySelectorAll("[type=checkbox]"),function(t){t.addEventListener("change",function(){u.Listings.FilterToggler.updateCheckboxCounter()})})},clearFilters:function(t){t&&(t.preventDefault(),t.stopPropagation()),this.form.reset();var e=this.form.querySelectorAll("select");e.length&&l.forEach(e,function(t){t.setAttribute("selected",t.firstElementChild.getAttribute("value")),u.Utils.Events.dispatchEvent("change",t)})},init:function(){var t=this.form.querySelector("#dltoggler_filters");return t&&t.addEventListener("click",this.toggle),this.updateBtn.addEventListener("click",this.toggle),this.clearBtn.addEventListener("click",this.toggle),this.counterChecked(),this.updateCheckboxCounter(),this},construct:function(){if(l.bindAll(this,"init","useMap","useScMap","visibleMap","toggle","clearFilters","updateCheckboxCounter","counterChecked"),this.isOpen=!1,!this.useScMap()&&(this.form=document.querySelector(".dlform-filter"),this.form&&(this.filters=this.form.querySelector(".dlform-filter__hidden-fields"),this.filters)))return this.container=document.querySelector("#dllistings_toolbar"),this.actions=this.filters.querySelector(".dlform-filter__actions"),this.updateBtn=this.form.querySelector(".dlform-filter__action--update"),this.clearBtn=this.form.querySelector(".dlform-filter__action--clear"),this}},u.Listings.FilterTogglerFactory=function(){return Object.create(u.Listings.FilterToggler).construct()},window.addEventListener("load",function(){var t=u.Listings.FilterFactory(window.dllistings.listingsAjaxUrl,u.Geo.UserPositionFactory(),document.getElementById("dlform_filter"));t&&t.init();var e=u.Listings.FilterTogglerFactory();e&&e.init()})}(jQuery,_,window.dllocalized,Backbone,window.google,window.CustomMarkerClusterer,window.DlMap,window.DlListings,window.dllistings,window.dlgooglemap,window.jsonListings,window.DL);1 window.DL=window.DL||{},window.DlMap=window.DlMap||{},window.DlListings=window.DlListings||{},function(o,l,t,e,i,r,a,s,n,c,d,u){"use strict";u.Listings=u.Listings||{},u.Listings.Filter={listingsListEl:function(){return document.querySelector(".dllistings-list")},useMap:function(){return Boolean(u.Utils.Functions.classList(document.body).contains("dl-is-listings--with-map"))},useScMap:function(){var t=document.getElementById("dlgoogle-map");return!!t&&Boolean(u.Utils.Functions.classList(t).contains("dlsc-map"))},visibleMap:function(){return window.dllistings.mapVisible||this.useScMap()},getFormTriggers:function(){return this.form.querySelectorAll(".dllistings-ajax-filter-trigger")},updateMap:function(){a.map.reCenter(),a.map.setEvents()},buildAutoupdateList:function(){if(l.isEmpty(this.autoUpdate)){var t=this.form.querySelectorAll(".is-autoupdate");t&&l.forEach(t,function(t){var e=u.Utils.String.toSlug(t.getAttribute("data-autoupdate"));e&&(this.autoUpdate[e]={instance:t,filter:t.getAttribute("data-autoupdate")})}.bind(this))}},updateAutoupdateFiltersMarkup:function(t){l.isEmpty(t)||(l.forEach(t,function(t,e){l.isUndefined(this.autoUpdate[e])||(this.autoUpdate[e].instance.innerHTML=t)}.bind(this)),u.Listings.FilterToggler.counterChecked(),u.Listings.FilterToggler.updateCheckboxCounter())},postData:function(t){var i="dlajax_action=listings_filter&"+o(this.form).serialize();l.isEmpty(this.autoUpdate)&&this.buildAutoupdateList(),l.forEach(this.autoUpdate,function(t,e){i+="&auto_update_filters["+t.filter+"]=1"}),l.isFunction(t)&&t(i)},init:function(){this.visibleMap()&&(a.map=new a.Map(document.querySelector("#dlgoogle-map"),window.dlgooglemap),a.markerCollection=new a.Backbone.Collections.Marker(null,{model:a.Backbone.Models.Marker})),this.archiveDescriptionModel=new s.Backbone.Models.ArchiveDescription,this.archiveDescriptionView=new s.Backbone.Views.ArchiveDescription({model:this.archiveDescriptionModel}),this.foundPostsModel=new s.Backbone.Models.FoundPosts,this.foundPostsView=new s.Backbone.Views.FoundPosts({model:this.foundPostsModel}),this.paginationModel=new s.Backbone.Models.Pagination,this.paginationView=new s.Backbone.Views.Pagination({model:this.paginationModel}),this.listingsCollection=new s.Backbone.Collections.Listings(null,{model:s.Backbone.Models.Listings}),l.isEmpty(d)||l.isEmpty(d.posts)||(this.listingsCollection.add(d.posts),this.visibleMap()&&(a.markerCollection.add(d.posts),a.map.markerCluster=new r(a.map,a.markerCollection.getMarkerRefs(),{gridSize:50,maxZoom:15,minimumClusterSize:2,ignoreHidden:!0},l.template(document.querySelector("#dltmpl_map_markerclusterer").innerHTML)),this.updateMap()),this.setPagionationAjaxTrigger(),window.jsonListings=void 0),this.setTriggers()},setPagionationAjaxTrigger:function(){var t,i=this,e=document.querySelector(".dlpagination");e&&(t=e.querySelectorAll("a.page-numbers")).length&&l.forEach(t,function(t){t.addEventListener("click",function(t){t.preventDefault(),clearTimeout(e);var e=setTimeout(function(){i.filter(t)},0)})})},setTriggers:function(){if(this.useMap()||!this.useScMap()){if(void 0===this.form||null===this.form)throw"Invalid form element when set triggers.";this.form.addEventListener("submit",this.filter.bind(this)),this.form.addEventListener("reset",this.filter.bind(this)),l.forEach(this.getFormTriggers(),function(t){var e;switch(t.nodeName){case"SELECT":e="select2change","qibla_"+t.getAttribute("data-taxonomy")+"_filter"===t.getAttribute("id")&&function(t,e){t.addEventListener(e,function(){var t=this.form.querySelectorAll(".geocode-input");t.length&&l.forEach(t,function(t){t.remove()});var e=this.form.querySelector("#geocode_nonce");e&&e.remove()}.bind(this))}.call(this,t,"select2change");break;case"INPUT":e="change";break;default:e="click"}t.addEventListener(e,this.filter.bind(this))}.bind(this))}},noPostsFound:function(t){var e=this.listingsListEl().firstElementChild;e&&(e.innerHTML=t)},toggleElementsWhenFetching:function(){var t=document.querySelector(".dlarchive-description"),e=document.querySelector(".dlarchive-listings-footer");e&&u.Utils.Functions.classList(e).toggle("is-hidden"),t&&u.Utils.Functions.classList(t).toggle("is-hidden")},updateListingsContainerBoxModel:function(t){var e=function(t){this.listingsListEl().style.height=t}.bind(this),i=function(){0===--n&&e("auto")};if(!this.visibleMap())if(t)e(this.listingsListEl().firstElementChild.clientHeight+"px");else{var s=this.listingsListEl().querySelectorAll("img"),n=s.length;l.forEach(s,function(t){t.complete?i():o(t).load(i)}.bind(this))}},toggleLoaderTimeOut:function(t,e,i){t.lastElementChild.classList.contains("ajax-loader")&&u.Utils.UI.toggleLoader(t.firstElementChild,e,i)},filter:function(n){var t=this.ajaxUrl;if(!(n instanceof Event&&("reset"!==n.type&&(n.preventDefault(),n.stopPropagation()),n.target.classList.contains("page-numbers")?t=n.target.getAttribute("href"):"I"===n.target.tagName&&n.target.parentNode.classList.contains("page-numbers")&&(t=n.target.parentNode.getAttribute("href")),"select2change"===n.type&&this.form.classList.contains("dlform-filter--open")))){this.listingsCollection.url=t;var e=document.body.classList.contains("is-safari")||document.body.classList.contains("is-edge")||document.body.classList.contains("is-mobile")?"html,body":"html";o(e).animate({scrollTop:0},function(){this.listingsListEl()&&u.Utils.UI.toggleLoader(this.listingsListEl().firstElementChild),this.postData(function(t){this.listingsCollection.fetch({type:"post",reset:!0,silent:!1,data:t,beforeSend:function(){u.Utils.Events.dispatchEvent("listings-collection-fetching",this.form,null,{obj:this,eventParent:n}),this.toggleElementsWhenFetching(),this.updateListingsContainerBoxModel(!0)}.bind(this),complete:function(){u.Utils.Events.dispatchEvent("listings-collection-fetched",this.form,null,{obj:this,eventParent:n}),setTimeout(this.toggleLoaderTimeOut,500,this.listingsListEl(),function(){this.updateListingsContainerBoxModel(),this.toggleElementsWhenFetching()}.bind(this))}.bind(this),success:function(t,e,i){if(t.models&&(u.Listings.Filter.visibleMap()&&a.markerCollection.reset(),l.forEach(t.models,function(t){t.trigger("update"),u.Listings.Filter.visibleMap()&&a.markerCollection.add(t.attributes)})),u.Utils.Events.dispatchEvent("listings-collection-success-fetched",this.form,null,{obj:this,eventParent:n}),e.foundPosts.number){var s=document.querySelector(".dlnocontent-found-listings");s&&s.remove(),u.Listings.Filter.visibleMap()&&(a.map.markerCluster=new r(a.map,a.markerCollection.getMarkerRefs(),{gridSize:50,maxZoom:15,minimumClusterSize:2,ignoreHidden:!0},l.template(document.querySelector("#dltmpl_map_markerclusterer").innerHTML)),this.updateMap())}else this.noPostsFound(e.noContentFoundTemplate);this.foundPostsModel.set(e.foundPosts),this.archiveDescriptionModel.set(e.archiveDescription),this.paginationModel.set(e.pagination),this.setPagionationAjaxTrigger(),"autoUpdateFilters"in e&&this.updateAutoupdateFiltersMarkup(e.autoUpdateFilters)}.bind(this)})}.bind(this))}.bind(this))}},construct:function(t,e,i){if(l.bindAll(this,"getFormTriggers","updateMap","postData","init","setPagionationAjaxTrigger","setTriggers","noPostsFound","toggleElementsWhenFetching","filter","updateListingsContainerBoxModel","updateAutoupdateFiltersMarkup","buildAutoupdateList"),i||this.useMap()||this.useScMap())return i&&(this.ajaxUrl=t,this.form=i,this.userPosition=e,this.data=null,this.autoUpdate={}),this}},u.Listings.FilterFactory=function(t,e,i){return Object.create(u.Listings.Filter).construct(t,e,i)},u.Listings.FilterToggler={useMap:function(){return Boolean(u.Utils.Functions.classList(document.body).contains("dl-is-listings--with-map"))},useScMap:function(){var t=document.getElementById("dlgoogle-map");return!!t&&Boolean(u.Utils.Functions.classList(t).contains("dlsc-map"))},visibleMap:function(){return window.dllistings.mapVisible||this.useScMap()},toggle:function(t){var e=this;"A"===t.target.tagName&&(t.preventDefault(),t.stopImmediatePropagation()),this.actions.style.display="none",o(this.filters).slideToggle(375,function(){if(e.isOpen=!e.isOpen,e.isOpen?(e.form.classList.add("dlform-filter--open"),e.actions.style.display="block"):e.form.classList.remove("dlform-filter--open"),this.style.overflowY="scroll",e.useMap()&&(e.form.parentElement.style.overflowY="hidden"),e.isOpen){var t=e.container.querySelector("#dltogglers");t&&(t=e.container.querySelector("#dltogglers").clientHeight)}else this.style.overflowY="auto",e.useMap()&&(e.form.parentElement.style.overflowY="auto")})},updateCheckboxCounter:function(){var t=document.querySelectorAll("[type=checkbox]:checked"),e=document.querySelector("#dltoggler_filters > span");0<t.length?e.innerText=t.length:e.innerText=""},counterChecked:function(){l.forEach(document.querySelectorAll("[type=checkbox]"),function(t){t.addEventListener("change",function(){u.Listings.FilterToggler.updateCheckboxCounter()})})},clearFilters:function(t){t&&(t.preventDefault(),t.stopPropagation()),this.form.reset();var e=this.form.querySelectorAll("select");e.length&&l.forEach(e,function(t){t.setAttribute("selected",t.firstElementChild.getAttribute("value")),u.Utils.Events.dispatchEvent("change",t)})},init:function(){var t=this.form.querySelector("#dltoggler_filters");return t&&t.addEventListener("click",this.toggle),this.updateBtn.addEventListener("click",this.toggle),this.clearBtn.addEventListener("click",this.toggle),this.counterChecked(),this.updateCheckboxCounter(),this},construct:function(){if(l.bindAll(this,"init","useMap","useScMap","visibleMap","toggle","clearFilters","updateCheckboxCounter","counterChecked"),this.isOpen=!1,!this.useScMap()&&(this.form=document.querySelector(".dlform-filter"),this.form&&(this.filters=this.form.querySelector(".dlform-filter__hidden-fields"),this.filters)))return this.container=document.querySelector("#dllistings_toolbar"),this.actions=this.filters.querySelector(".dlform-filter__actions"),this.updateBtn=this.form.querySelector(".dlform-filter__action--update"),this.clearBtn=this.form.querySelector(".dlform-filter__action--clear"),this}},u.Listings.FilterTogglerFactory=function(){return Object.create(u.Listings.FilterToggler).construct()},window.addEventListener("load",function(){var t=u.Listings.FilterFactory(window.dllistings.listingsAjaxUrl,u.Geo.UserPositionFactory(),document.getElementById("dlform_filter"));t&&t.init();var e=u.Listings.FilterTogglerFactory();e&&e.init()})}(jQuery,_,window.dllocalized,Backbone,window.google,window.CustomMarkerClusterer,window.DlMap,window.DlListings,window.dllistings,window.dlgooglemap,window.jsonListings,window.DL); -
qibla-events/tags/1.0.2/changelog.txt
r1951928 r1996350 1 = 1.0.2 = 2 3 Release Date – 17 Dicember 2018 4 5 Fix: toggle loader locked in archive listings 6 1 7 = 1.0.1 = 2 8 -
qibla-events/tags/1.0.2/src/Functions/Kses.php
r1923077 r1996350 221 221 } 222 222 223 /** 224 * WordPress 5.0.1 Form element no longer passes KSES 225 * 226 * @see https://make.wordpress.org/core/2018/12/13/backwards-compatibility-breaks-in-5-0-1/ 227 * 228 * @since 2.6.2 229 */ 223 230 // Form attributes. 224 $tagsInputIncluded['form'] = array_merge($tagsInputIncluded['form'], array('novalidate' => true)); 231 $tagsInputIncluded['form'] = array( 232 'id' => true, 233 'class' => true, 234 'action' => true, 235 'accept' => true, 236 'accept-charset' => true, 237 'enctype' => true, 238 'method' => true, 239 'name' => true, 240 'target' => true, 241 'novalidate' => true, 242 ); 243 225 244 // Fieldset attributes. 226 245 // WordPress have an empty array. -
qibla-events/tags/1.0.2/src/Plugin.php
r1923077 r1996350 43 43 * @var string The plugin current version 44 44 */ 45 const PLUGIN_VERSION = '1.0. 0';45 const PLUGIN_VERSION = '1.0.1'; 46 46 47 47 /**
Note: See TracChangeset
for help on using the changeset viewer.