PageSourceSearch

https://mairie-rocbaron.fr/typo3conf/ext/powermail_cond/Resources/…/PowermailCondition.min.js?1790261671

js mairie-rocbaron.fr collected 2026-09-24 23:15:26 UTC 6,397 bytes, 1 lines download raw bytes

1!function(){"use strict";function t(t,e,i){if("function"==typeof t?t===e:t.has(e))return arguments.length<3?e:i;throw new TypeError("Private element is not present on this object")}function e(t,e){if(e.has(t))throw new TypeError("Cannot initialize the same private elements twice on an object")}function i(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}function n(e,i){return e.get(t(e,i))}function o(t,i,n){e(t,i),i.set(t,n)}function r(e,i,n){return e.set(t(e,i),n),n}function a(t,e){for(var i=0;i<e.length;i++){var n=e[i];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(t,u(n.key),n)}}function l(t,e,i){return e&&a(t.prototype,e),i&&a(t,i),Object.defineProperty(t,"prototype",{writable:!1}),t}function s(t,e,i){return(e=u(e))in t?Object.defineProperty(t,e,{value:i,enumerable:!0,configurable:!0,writable:!0}):t[e]=i,t}function u(t){var e=function(t,e){if("object"!=typeof t||!t)return t;var i=t[Symbol.toPrimitive];if(void 0!==i){var n=i.call(t,e||"default");if("object"!=typeof n)return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return("string"===e?String:Number)(t)}(t,"string");return"symbol"==typeof e?e:e+""}var c=function(){return l(function t(){i(this,t)},null,[{key:"hideElement",value:function(t){null!==t&&(t.classList.add("powermail-cond-hidden"),t.style.display="none")}},{key:"showElement",value:function(t){null!==t&&(t.classList.remove("powermail-cond-hidden"),t.style.display="")}}])}(),d=new WeakMap,h=new WeakMap,f=new WeakMap,m=new WeakSet,p=l(function a(l){var u,c;i(this,a),e(u=this,c=m),c.add(u),s(this,"use strict",void 0),o(this,d,void 0),o(this,h,void 0),o(this,f,"data-powermail-cond-excluded-fields"),s(this,"initialize",function(){var e=this,i="#form-"+n(d,this).querySelector("input.powermail_form_uid").value+"-actions";if(null===document.querySelector(i))t(m,e,w).call(e);else{var o=JSON.parse(document.querySelector(i).textContent);t(m,e,y).call(e,o)}t(m,e,b).call(e),t(m,e,v).call(e)}),r(d,this,l),n(d,this).powermailConditions=this,r(h,this,n(d,this).classList.contains("powermail_morestep"))});function v(){var t=this;"true"!==n(d,this).getAttribute("data-powermail-ajax")&&n(d,this).addEventListener("submit",function(e){if(e.preventDefault(),document.activeElement&&document.activeElement.tagName){var i=document.activeElement,o=i.tagName.toLowerCase();if(("input"===o||"textarea"===o||"select"===o)&&n(d,t).contains(i))return i.blur(),void setTimeout(function(){n(d,t).reportValidity()&&n(d,t).submit()},50)}n(d,t).submit()})}function b(){var e=this;t(m,this,q).call(this).forEach(function(i){i.addEventListener("change",function(i){t(m,e,w).call(e)})})}function w(){var e=this;t(m,e,g).call(e);var i=new FormData(n(d,this));n(d,this).hasAttribute(n(f,this))&&n(d,this).querySelectorAll(n(d,this).getAttribute(n(f,this))).forEach(function(t){t.hasAttribute("name")&&i.delete(t.getAttribute("name"))});fetch(t(m,this,A).call(this),{body:i,method:"post"}).then(function(t){return t.json()}).then(function(i){i.loops>i.loopLimit?console.log("Too much loops reached by parsing conditions and rules. Check for conflicting conditions."):t(m,e,y).call(e,i)}).catch(function(t){console.log(t)})}function y(e){if(void 0!==e.todo)for(var i in e.todo)for(var o in e.todo[i])for(var r in"hide"===e.todo[i][o]["#action"]&&(n(h,this)&&c.hideElement(t(m,this,N).call(this,o)),t(m,this,L).call(this,t(m,this,M).call(this,o))),"un_hide"===e.todo[i][o]["#action"]&&(n(h,this)&&c.showElement(t(m,this,N).call(this,o)),t(m,this,_).call(this,t(m,this,M).call(this,o))),e.todo[i][o])"hide"===e.todo[i][o][r]["#action"]&&t(m,this,S).call(this,r),"un_hide"===e.todo[i][o][r]["#action"]&&t(m,this,E).call(this,r);
1n(d,this).querySelectorAll(".powermail_fieldset").forEach(function(t){"hidden"===window.getComputedStyle(t).visibility&&(t.style.visibility="visible",t.style.opacity=1)})}function g(){n(d,this).querySelectorAll('[disabled="disabled"]').forEach(function(t){t.removeAttribute("disabled")})}function q(){return n(d,this).querySelectorAll('input:not([data-powermail-validation="disabled"]):not([type="hidden"]):not([type="submit"]), textarea:not([data-powermail-validation="disabled"]), select:not([data-powermail-validation="disabled"])')}function A(){var t=document.querySelector("[data-condition-uri]");return null===t&&console.log("Tag with data-condition-uri not found. Maybe TypoScript was not included."),t.getAttribute("data-condition-uri")}function E(e){var i=t(m,this,x).call(this,e);null!==i&&c.showElement(i);var n=t(m,this,P).call(this,e);null!==n&&(n.removeAttribute("disabled"),t(m,this,k).call(this,n))}function S(e){var i=t(m,this,x).call(this,e);null!==i&&c.hideElement(i);var n=t(m,this,P).call(this,e);null!==n&&(n.setAttribute("disabled","disabled"),t(m,this,j).call(this,n))}function _(t){t.classList.remove("powermail-cond-hidden"),n(h,this)||c.showElement(t)}function L(t){n(h,this)?t.classList.add("powermail-cond-hidden"):c.hideElement(t)}function j(t){(t.hasAttribute("required")||t.hasAttribute("data-powermail-required"))&&(t.removeAttribute("required"),t.removeAttribute("data-powermail-required"),t.setAttribute("data-powermailcond-required","required"))}function k(e){"required"===e.getAttribute("data-powermailcond-required")&&(t(m,this,T).call(this)||t(m,this,C).call(this))&&e.setAttribute("required","required"),e.removeAttribute("data-powermailcond-required")}function C(){return"data-powermail-validate"===n(d,this).getAttribute("data-powermail-validate")}function T(){return"html5"===n(d,this).getAttribute("data-validate")}function x(e){var i=t(m,this,O).call(this,e);if(null!==i)return i;var n=t(m,this,P).call(this,e);if(null!==n){var o=n.closest(".powermail_fieldwrap");if(null!==o)return o}return console.log('Error: Could not find field by fieldMarker "'+e+'"'),null}function P(t){var e="tx_powermail_pi1[field]["+t+"]";return n(d,this).querySelector('[name="'+e+'"]:not([type="hidden"])')||n(d,this).querySelector('[name="'+e+'[]"]')}function M(t){return n(d,this).querySelector(".powermail_fieldset_"+t)}function N(t){return n(d,this).querySelector('.btn[data-powermail-fieldset="'.concat(t,'"]'))}function O(t){return n(d,this).querySelector(".powermail_fieldwrap_"+t)}window.addEventListener("pageshow",function(){document.querySelectorAll(".powermail_form").forEach(function(t){new p(t).initialize()})})}();

Line numbers count LF bytes from the start of the resource, as the search results do. Vendor segments are library code the classifier recognised; they are stored but not indexed. Bytes are shown as Latin1 characters, one per byte.