PageSourceSearch

https://www.uclgmeets.org/decidim-packs/js/decidim_direct_verifications_participants-ace211f8a9df09b382e5.js

js uclgmeets.org collected 2026-10-01 12:03:15 UTC 4,173 bytes, 17 lines download raw bytes

1(function(){var r={82556:function(){class e{constructor(t,i){this.table=t,this.svgPath=t.querySelector("use[href]").getAttribute("href").split("#")[0],this.config=i,this.table.addEventListener("click",o=>{o.target.closest(".show-verifications-modal")&&this.toggleModal(o)}),this.addModal()}addModal(){const t=`
2<div id="show-verifications-modal" data-dialog="show-verifications-modal" role="dialog" tabindex="-1"
3     aria-hidden="true" aria-modal="true" aria-labelledby="dialog-title-show-verifications-modal" aria-describedby="dialog-desc-show-verifications-modal">
4  <div id="show-verifications-modal-content">
5    <button class="close-button" type="button" data-dialog-close="show-verifications-modal" data-dialog-closable aria-label="${this.config.closeModalLabel}">\xD7</button>
6    <div data-dialog-container>
7      <svg width="1em" height="1em" role="img" aria-hidden="true"><use href="${this.svgPath}#ri-information-line"></use></svg>
8      <h3 class="h3" id="dialog-title-show-verifications-modal" tabindex="-1" data-dialog-title="">${this.config.modalTitle}</h3>
9      <div id="dialog-desc-show-verifications-modal" class="my-8">
10        <div class="modal-body"></div>
11      </div>
12    </div>
13    <div data-dialog-actions></div>
14  </div>
15</div>`,i=document.createElement("div");i.innerHTML=t.trim(),this.modal=i.firstChild,this.table.parentNode.insertBefore(this.modal,this.table.nextSibling),this.modalBody=this.modal.querySelector(".modal-body"),this.closeButton=this.modal.querySelector(".close-button"),this.closeButton.addEventListener("click",()=>this.hideModal()),this.modal.addEventListener("click",o=>{o.target===this.modal&&this.hideModal()})}drawButtons(){this.table.querySelectorAll("tbody tr").forEach(i=>{const o=i.querySelector("td:last-child");if(o){const n=`<span><a class="action-icon show-verifications-modal" title="${this.config.buttonTitle}" href="#open-show-verifications-modal"><span class="has-tip ${this.getTrStatus(i)}"><svg aria-label="${this.config.buttonTitle}" role="img" class="icon--ban icon"><title>${this.config.buttonTitle}</title><use href="${this.svgPath}#ri-key-2-line"></use></svg></span></a></span>`;o.innerHTML=n+o.innerHTML}})}addStatsTitle(){const t=document.querySelector(".item_show__header-title"),i=`<a class="button button__sm button__secondary" href="/admin/direct_verifications/stats">${this.config.statsLabel}</a>`;t.innerHTML+=i}getTrStatus(t){const i=t.dataset.userId;return this.getUserVerifications(i).length?"alert":""}getVerification(t){return this.config.verifications.find(i=>i.id===t)}getUserVerifications(t){return this.config.verifications.filter(i=>i.userId===t)}showModal(){this.modal.setAttribute("aria-hidden","false"),this.modal.style.display="block",document.body.classList.add("modal-open")}hideModal(){this.modal.setAttribute("aria-hidden","true"),this.modal.style.display="none",document.body.classList.remove("modal-open")}toggleModal(t){const i=t.target.closest("tr");if(i){const o=i.dataset.userId,n=this.config.userVerificationsPath.replace("-ID-",o);this.loadUrl(n)}}loadUrl(t,i=!1){i?this.modal.classList.add("large"):this.modal.classList.remove("large"),this.modalBody.innerHTML='<span class="loading-spinner"></span>',fetch(t).then(o=>o.text()).then(o=>{this.modalBody.innerHTML=o,this.showModal()}).catch(o=>{this.modalBody.innerHTML=`<p>Error loading content: ${o.message}</p>`,this.showModal()})}}document.addEventListener("DOMContentLoaded",()=>{const a=new e(document.querySelector("#user-groups table.table-list"),DirectVerificationsConfig);a.drawButtons(),a.addStatsTitle()})}},d={};function s(e){var a=d[e];if(a!==void 0)return a.exports;var t=d[e]={exports:{}};return r[e](t,t.exports,s),t.exports}(function(){s.n=function(e){var a=e&&e.__esModule?function(){return e.default}:function(){return e};return s.d(a,{a}),a}})(),function(){s.d=function(e,a){for(var t in a)s.o(a,t)&&!s.o(e,t)&&Object.defineProperty(e,t,{enumerable:!0,get:a[t]})}}(),function(){s.o=function(e,a){return Object.prototype.hasOwnProperty.call(e,a)}}(),function(){"use strict";var e=s(82556),a=s.n(e)}()})();
16
17//# sourceMappingURL=decidim_direct_verifications_participants-ace211f8a9df09b382e5.js.map

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.