mypgs 1.0.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +33 -0
- package/assets/javascript/_pgs.js +214 -0
- package/assets/javascript/base/_darkmode.js +121 -0
- package/assets/javascript/base/_object.js +42 -0
- package/assets/javascript/components/_accordion.js +77 -0
- package/assets/javascript/components/_dropdown.js +107 -0
- package/assets/javascript/components/_exeNotifications.js +85 -0
- package/assets/javascript/components/_menu.js +92 -0
- package/assets/javascript/components/_modals.js +123 -0
- package/assets/javascript/components/_slides.js +183 -0
- package/assets/javascript/components/_steps.js +27 -0
- package/assets/javascript/components/_tabs.js +134 -0
- package/assets/javascript/functions/_formValidate.js +217 -0
- package/assets/javascript/functions/_notifications.js +74 -0
- package/assets/javascript/functions/_scrollY.js +77 -0
- package/assets/javascript/functions/_sendForm.js +100 -0
- package/assets/javascript/index.js +20 -0
- package/assets/javascript/patterns/_cookieConsent.js +209 -0
- package/assets/javascript/patterns/_header.js +134 -0
- package/assets/javascript/pgs.d.ts +23 -0
- package/assets/scss/base/_body.scss +151 -0
- package/assets/scss/base/_color.scss +56 -0
- package/assets/scss/base/_general.scss +58 -0
- package/assets/scss/base/_heading.scss +20 -0
- package/assets/scss/base/_html.scss +4 -0
- package/assets/scss/base/_reset.scss +15 -0
- package/assets/scss/base/_variables.scss +39 -0
- package/assets/scss/components/_accordion.scss +91 -0
- package/assets/scss/components/_breadcumbs.scss +40 -0
- package/assets/scss/components/_button.scss +28 -0
- package/assets/scss/components/_dropdown.scss +106 -0
- package/assets/scss/components/_form.scss +53 -0
- package/assets/scss/components/_logo.scss +51 -0
- package/assets/scss/components/_menu.scss +23 -0
- package/assets/scss/components/_modals.scss +120 -0
- package/assets/scss/components/_notification.scss +193 -0
- package/assets/scss/components/_searchbar.scss +68 -0
- package/assets/scss/components/_slides.scss +198 -0
- package/assets/scss/components/_steps.scss +111 -0
- package/assets/scss/components/_table.scss +59 -0
- package/assets/scss/components/_tabs.scss +69 -0
- package/assets/scss/components/_tooltip.scss +16 -0
- package/assets/scss/index.scss +64 -0
- package/assets/scss/layout/_flex.scss +47 -0
- package/assets/scss/layout/_gap.scss +12 -0
- package/assets/scss/layout/_grid.scss +11 -0
- package/assets/scss/layout/_layout.scss +41 -0
- package/assets/scss/layout/_pageShell.scss +171 -0
- package/assets/scss/mixin/_mx-base.scss +126 -0
- package/assets/scss/mixin/_mx-button.scss +186 -0
- package/assets/scss/mixin/_mx-card.scss +77 -0
- package/assets/scss/mixin/_mx-color.scss +34 -0
- package/assets/scss/mixin/_mx-form-addon.scss +180 -0
- package/assets/scss/mixin/_mx-form.scss +512 -0
- package/assets/scss/mixin/_mx-menu.scss +154 -0
- package/assets/scss/mixin/_mx-responsive.scss +353 -0
- package/assets/scss/mixin/_mx-semantic.scss +147 -0
- package/assets/scss/mixin/mixin.scss +36 -0
- package/assets/scss/patterns/_cookieConsent.scss +101 -0
- package/assets/scss/patterns/_footer.scss +180 -0
- package/assets/scss/patterns/_header.scss +143 -0
- package/dist/css/index.css +7026 -0
- package/dist/css/index.css.map +1 -0
- package/dist/css/index.min.css +1 -0
- package/dist/index.d.ts +24 -0
- package/dist/javascript/index.js +2034 -0
- package/dist/javascript/index.js.map +1 -0
- package/dist/javascript/index.min.js +1 -0
- package/package.json +40 -0
- package/templates/components/md-breadcumbs.html +23 -0
- package/templates/components/md-menu.html +6 -0
- package/templates/components/md-notification.html +10 -0
- package/templates/components/md-searchbar.html +24 -0
- package/templates/components/md-tooltip.html +5 -0
- package/templates/layout/md-body.html +20 -0
- package/templates/layout/md-cookieConsent.html +51 -0
- package/templates/layout/md-footer.html +16 -0
- package/templates/layout/md-header.html +43 -0
- package/webpack.config.js +131 -0
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.js","mappings":";;;;;;;;;;;;;;AAAA;AACA,WAAW,oBAAoB;AAC/B;AACO;AACP;AACA;;AAEA;AACA;;AAEA;AACA;AACA;;AAEA;AACA;AACA,mCAAmC,wBAAwB,IAAI,WAAW;AAC1E;;AAEA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,0BAA0B,KAAK,KAAK,EAAE;AACtC;AACA;;AAEA;AACA;AACA;AACA;AACA;AACA;;AAEA;AACA;AACA;AACA;;AAEA;AACA;AACA;AACA;AACA;;AAEA;AACA;AACA;;AAEA;AACA;AACA;;AAEA;AACA;AACA;AACA;AACA;AACA;AACA;;AAEA;AACA;AACA;AACA;AACA;;AAEA;AACA;;AAEA;;AAEA;AACA;AACA;AACA;AACA;;AAEA;AACA;AACA;AACA;;AAEA;AACA;AACA;;AAEA;AACA;AACA;AACA;;AAEA;AACA;AACA;AACA;AACA,aAAa;AACb;AACA;AACA;AACA;AACA,SAAS;;AAET;AACA;;AAEA;AACA;AACA;;AAEA;AACA;;AAEA;AACA;;AAEA;AACA;AACA;AACA;AACA;;AAEA;AACA;AACA;AACA;AACA;AACA;AACA;;AAEA;AACA;AACA;AACA;AACA;AACA;;AAEA;AACA;AACA;;AAEA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;;AAEA;AACA;AACA;AACA;AACA;;AAEA;AACA,oBAAoB,sCAAsC;AAC1D,qBAAqB;AACrB,SAAS;;AAET;AACA;;AAEA;AACA;AACA;;AAEA;AACA;AACA;;AAEA;AACA;AACA,0DAA0D;;AAE1D,0CAA0C,QAAQ;AAClD;AACA;;AAEA;AACA;AACA,0DAA0D;;AAE1D;AACA,uCAAuC,QAAQ;AAC/C;;AAEA;AACA;;AAEA;AACA,oBAAoB,sCAAsC;AAC1D,qBAAqB;AACrB,SAAS;;AAET;AACA;;AAEA;AACA;AACA;AACA;AACA;AACA;AACA;;AAEA;;;;;;;;;;;;;ACnNA;;;AAGA;AACA;AACA;AACA;AACA;AACA,oBAAoB,QAAQ;AAC5B;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;;;AAGA;AACA;AACA;AACA;;AAEA;;AAEA;AACA;AACA;AACA;;AAEA;AACA;;AAEA;;AAEA;AACA;AACA,0BAA0B;AAC1B;AACA;AACA,qBAAqB;AACrB;AACA;AACA,SAAS;AACT;;AAEA;AACA;AACA;;AAEA;AACA;AACA;AACA;AACA,SAAS;;AAET;AACA;AACA;AACA;AACA;AACA,KAAK;;AAEL;AACA;AACA;;AAEA;AACA;AACA;AACA;AACA,SAAS;;AAET;AACA;AACA;AACA;AACA;AACA,KAAK;AACL;;;;AAIA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;;AAEA;AACA;AACA;AACA;AACA;AACA;AACA,KAAK;AACL;AACA;;AAEA;;AAEA;AACA;AACA;;AAEA;AACA;AACA;AACA;;AAEA;AACA;AACA;AACA;AACA,KAAK;AACL,CAAC;;;;;;;;;;;ACxHD;AACA;;AAEA;AACA;AACA;AACA;AACA;;AAEA;AACA;AACA;;AAEA;AACA;AACA;;AAEA;AACA;;AAEA;AACA;;AAEA;AACA;AACA;AACA;AACA;AACA;AACA,iBAAiB;AACjB,aAAa;;AAEb;AACA;AACA;;AAEA;AACA,kDAAkD,YAAY;AAC9D,KAAK;;AAEL;AACA,CAAC;;;;;;;;;;;ACzCD;AACA;;AAEA;;AAEA;AACA;;AAEA;AACA;AACA,6BAA6B,GAAG;AAChC,iCAAiC,GAAG;;AAEpC;AACA;;AAEA;AACA;AACA;AACA;AACA;;AAEA;AACA;AACA;;AAEA;AACA;AACA;AACA,6CAA6C,4BAA4B,EAAE,kBAAkB;AAC7F;AACA;AACA;;AAEA;AACA;AACA;AACA;;AAEA;AACA;AACA;;AAEA;AACA;AACA;AACA;;AAEA;AACA;AACA;AACA;;AAEA;AACA;;AAEA;;AAEA;AACA,iEAAiE,qCAAqC;AACtG;;AAEA;AACA;;AAEA;AACA;;AAEA;AACA;AACA;AACA;AACA;AACA;AACA,KAAK;;AAEL,CAAC;;;;;;;;;;;;;;;;AC5ED;AACO;AACP;AACA;AACA;;AAEA;;AAEA;AACA;AACA;;AAEA;AACA,iDAAiD,MAAM;AACvD;;AAEA;AACA,oDAAoD,MAAM;AAC1D,wDAAwD,MAAM;AAC9D;AACA;AACA;AACA;AACA;;AAEA;AACA;AACA;AACA;;AAEA;AACA;AACA;AACA;AACA;AACA;;AAEA;AACA;;AAEA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;;AAEA,qEAAqE,IAAI;AACzE,sEAAsE,KAAK;AAC3E,mEAAmE,UAAU;AAC7E;;AAEA;AACA;;AAEA;AACA;AACA;AACA;AACA;;AAEA;AACA;AACA,SAAS;;AAET;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,SAAS;;AAET;AACA;AACA,SAAS;AACT;AACA;AACA,SAAS;AACT,KAAK;AACL;;AAEA;AACA;;;;;;;;;;;;;;;;;AC1G6E;;AAE7E;AACA;AACA;;AAEA;AACA;AACA;;AAEA;AACA;;AAEA;AACA;;AAEA,iCAAiC,kEAAS,GAAG,yEAAgB;AAC7D;;AAEA;AACA;;AAEA;AACA;;AAEA;AACA;AACA,0DAA0D;AAC1D,MAAM;AACN;AACA;AACA;AACA;;AAEA;AACA;AACA;;AAEA;AACA,uEAAuE,UAAU;;AAEjF;AACA,iDAAiD,UAAU;AAC3D;AACA,mDAAmD,YAAY;AAC/D;AACA;;AAEO;AACP;AACA;;AAEA;AACA;AACA;AACA;AACA;AACA;AACA;;AAEA;AACA;AACA;AACA;AACA;AACA;;AAEA,gBAAgB,kEAAS;AACzB;AACA,MAAM;AACN;AACA;;AAEA;AACA;;AAEA;AACA;AACA;;AAEA;AACA;AACA,EAAE;AACF;AACA;;;;;;;;;;;;;;;;;ACpF2C;;AAE3C;AACO;;AAEP;;AAEA;AACA;AACA;;AAEA;AACA;AACA;AACA,iDAAiD;AACjD;;AAEA;AACA;AACA;AACA;AACA;AACA;AACA,SAAS;AACT,KAAK;;AAEL;;AAEA;AACA;;AAEA;;AAEA;AACA;AACA;;AAEA;AACA,kDAAkD,MAAM;AACxD;;AAEA;AACA;AACA;AACA;AACA;AACA,gEAAgE;AAChE;;AAEA;AACA;AACA;AACA;AACA;AACA;;AAEA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,aAAa;AACb,SAAS;;AAET;;AAEA;AACA;AACA;;AAEA;AACA;AACA;AACA,wDAAwD;AACxD;;;AAGA;AACA;AACA;AACA,wBAAwB;AACxB;AACA,gBAAgB;AAChB,YAAY;AACZ,KAAK;AACL,IAAI,uDAAY;AAChB;;AAEA;AACA,U;;;;;;;;;;;;;;;AC3FA;AACA;AACO;AACP;;AAEA;AACA;AACA;;AAEA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;;AAEA;AACA;AACA;AACA;AACA;AACA;;;AAGA;AACA;;AAEA;AACA;AACA;;;AAGA;AACA;AACA;AACA;AACA;AACA;;;AAGA;AACA;AACA;AACA;AACA;;AAEA;AACA;AACA;AACA;AACA;AACA;AACA,iDAAiD,UAAU;AAC3D;AACA;AACA;;AAEA;AACA;AACA;AACA;AACA;AACA,kDAAkD,UAAU;AAC5D;AACA;AACA;;AAEA;AACA;AACA;AACA;AACA,sEAAsE,oBAAoB;AAC1F;AACA;;;AAGA;AACA;AACA;AACA;AACA;AACA;AACA,gDAAgD,gEAAgE;AAChH;AACA;AACA;AACA;AACA;;AAEA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,yDAAyD,kBAAkB;AAC3E,+CAA+C,qCAAqC;AACpF,kBAAkB;AAClB,aAAa;AACb,kCAAkC,6CAA6C;;AAE/E;AACA;AACA;AACA;AACA;AACA;AACA;AACA,kBAAkB;AAClB,aAAa;AACb;AACA,KAAK;AACL;;AAEA;;;;;;;;;;;;;;;;;;AC1H4D;AAC5D;;AAEA;AACA;AACA,kBAAkB,2DAA2D,uBAAuB,IAAI;AACxG;AACA;;AAEA;AACA,oCAAoC,aAAa;AACjD;AACA;AACA;;AAEA;AACA;AACA;AACA;AACA;AACA;AACA;;AAEA;AACA;AACA;AACA;AACA;AACA;;AAEA;AACA;AACA;AACA;AACA;;AAEA;AACA;AACA;;AAEA;AACA;AACA;AACA,aAAa;AACb;AACA;;AAEA;AACA;AACA;AACA;AACA;;AAEA;AACA;;AAEA;;AAEA;AACA,sBAAsB,qBAAqB;AAC3C;;AAEA;AACA;AACA;AACA;;AAEA;AACA;AACA;AACA;AACA;AACA;AACA;;AAEA;AACA,sBAAsB,qBAAqB;AAC3C;;AAEA;AACA;AACA;AACA;;AAEA;AACA;AACA;AACA;AACA;;AAEA;AACA;AACA,sFAAsF,eAAe;AACrG;;AAEA;AACA;AACA;;AAEA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;;AAEA;AACA;AACA;AACA;AACA;AACA;AACA,aAAa;AACb,SAAS;AACT;;AAEA;AACA;AACA;AACA;;AAEA;AACA;AACA;AACA;AACA;;AAEA;AACA;;AAEA;AACA,iCAAiC,wEAAoB;;AAErD;AACA;AACA,2EAA2E,eAAe;AAC1F,uEAAuE,eAAe;;AAEtF;AACA;AACA;AACA,cAAc;AACd;AACA;;;AAGA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,aAAa;AACb,SAAS;AACT;AACA;AACA;;AAEA;AACO;AACP;AACA;;AAEA,0CAA0C,cAAc;AACxD;AACA,KAAK;AACL;;AAEA;AACO;AACP;AACA;;;;;;;;;;;;;;;;;ACrLO;AACP;;AAEA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,cAAc;AACd;AACA;AACA;AACA;AACA;AACA;AACA;AACA,SAAS;AACT,KAAK;AACL;;AAEA;AACA,Q;;;;;;;;;;;;;;;;AC1BA;AACA;;AAEO;AACP;;AAEA;AACA;AACA;;AAEA;AACA;AACA;AACA;AACA;AACA;AACA;;AAEA;AACA;AACA;AACA;AACA;;AAEA;AACA;AACA;AACA;;AAEA;;AAEA;;AAEA;AACA;AACA;AACA;AACA,sDAAsD,UAAU;;AAEhE;AACA;AACA;AACA;AACA,iBAAiB;;AAEjB;AACA;AACA,aAAa;AACb;;AAEA;AACA;AACA;AACA;AACA;AACA,aAAa;AACb;;AAEA;AACA;AACA;AACA;;AAEA;AACA;;AAEA;AACA;AACA,yCAAyC,oCAAoC;AAC7E;AACA,sEAAsE,UAAU,kBAAkB;AAClG;;AAEA;AACA;AACA;AACA;AACA;;AAEA;AACA;;AAEA;AACA;AACA,2DAA2D,yDAAyD;;;AAGpH;AACA;AACA;AACA,gEAAgE,eAAe;;AAE/E;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,+BAA+B,gBAAgB;AAC/C,SAAS;AACT,KAAK;AACL;;AAEO;AACP;AACA;;;AAGA;AACA;AACA;AACA,iDAAiD,UAAU,WAAW;AACtE;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,0DAA0D,UAAU,uBAAuB;AAC3F;AACA;AACA,0DAA0D,UAAU,wBAAwB;AAC5F;AACA;AACA,kDAAkD,UAAU,wCAAwC;AACpG;;;;;;;;;;;;;;;;;ACrIA;AACA;AACA;;AAEA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;;AAEA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,gCAAgC,MAAM,KAAK,KAAK;AAChD;;;AAGA;AACA;AACA;AACA;AACA;;AAEA;AACA,wCAAwC,sBAAsB;;AAE9D;AACA;AACA;AACA;AACA;AACA;AACA;;AAEA;AACA;AACA;AACA;AACA;AACA,+BAA+B;AAC/B,KAAK;AACL;;AAEA;AACA;AACA;AACA;;;;AAIO;AACP;AACA;AACA;AACA;AACA;AACA;;AAEO;AACP;AACA;AACA;AACA;AACA;AACA,C;;;;;;;;;;;;;;;ACzEO;AACP;AACA;AACA;AACA;AACA;AACA;AACA;;AAEA;AACA;AACA;;AAEA;AACA;AACA;AACA;;AAEA;AACA,4CAA4C;AAC5C,2CAA2C;AAC3C;;AAEA;AACA,4CAA4C;AAC5C;AACA;AACA;AACA;;AAEA;AACA;AACA;;AAEA;AACA;AACA,0BAA0B;AAC1B;AACA,KAAK;;AAEL;AACA;AACA;AACA;AACA;;AAEA;AACA;;AAEA;AACA;AACA;;AAEA;AACA;AACA;AACA;;AAEA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;;AAEA;AACA;;AAEA;AACA;;AAEA;AACA;AACA,KAAK,IAAI,gBAAgB;AACzB;;;;;;;;;;;AC5EA;AACA;;AAEA;AACA;AACA;AACA;AACA,MAAM;AACN;AACA;AACA;AACA;;AAEA;AACA;AACA;AACA;AACA,MAAM;AACN;AACA;AACA;;AAEA;AACA;AACA;AACA;AACA;AACA,6BAA6B,+CAA+C;AAC5E;AACA,MAAM;AACN;AACA;AACA;;AAEA;AACA;AACA;AACA;AACA;AACA;AACA;;AAEA;AACA;AACA;AACA;;AAEA;AACA;AACA,gEAAgE,cAAc;AAC9E;;AAEA;AACA;AACA;AACA;AACA,KAAK;AACL;;AAEA;AACA,iCAAiC,+BAA+B;AAChE;AACA;AACA,2CAA2C,8BAA8B;AACzE;AACA,MAAM;AACN,2CAA2C,6BAA6B;AACxE;AACA;;AAEA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,MAAM;AACN;AACA;AACA;;AAEA;AACA,yCAAyC,mEAAmE;AAC5G;AACA;AACA;AACA;;AAEA;AACA;;AAEA;AACA;AACA,KAAK;AACL;;AAEA;AACA;AACA;AACA;;AAEA;AACA;AACA;AACA;AACA;AACA;AACA;;AAEA,oCAAoC,mEAAmE;;AAEvG;AACA;AACA;AACA;AACA;AACA,UAAU;AACV;AACA;AACA;;AAEA;AACA,wCAAwC,6BAA6B;;AAErE;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,aAAa;AACb,UAAU;AACV,uCAAuC,qBAAqB;AAC5D;AACA;;AAEA;AACA;AACA;;AAEA;AACA;AACA;;AAEA;AACA,0BAA0B,2BAA2B;AACrD;AACA;AACA,gCAAgC,iDAAiD;AACjF;;AAEA;AACA;AACA;AACA;AACA,KAAK;;AAEL;AACA;AACA;AACA;AACA;AACA,KAAK;;AAEL;AACA;AACA;AACA;AACA,KAAK;;AAEL;AACA;AACA;AACA;AACA,UAAU;AACV;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,KAAK;;AAEL;AACA;AACA;AACA;AACA,SAAS;AACT,KAAK;;AAEL;AACA;AACA;AACA;AACA;AACA,MAAM;AACN;AACA;AACA,CAAC;;;;;;;;;;;;;;;;AChND;AACA;AACA;AACA;;AAEA;AACO;;AAEP;AACA;AACA;;AAEA;AACA;AACA;;AAEA;;AAEA;AACA;AACA;AACA;AACA;AACA;;AAEA;AACA;AACA,UAAU;AACV;;AAEA;AACA;AACA;AACA;AACA;AACA;AACA,iBAAiB;;AAEjB;AACA;;AAEA;AACA;;AAEA;AACA;AACA;AACA;AACA,UAAU;AACV;AACA;AACA;AACA;AACA,UAAU;AACV;AACA;AACA;AACA;;AAEA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,SAAS;AACT;;AAEA;AACA;AACA;;AAEA;;;;;AAKA;AACA;AACA;AACA;AACA;;AAEA;AACA;AACA;;AAEA;;AAEA,kDAAkD,OAAO;AACzD;AACA,wDAAwD,aAAa;;AAErE;AACA;AACA;AACA;;;AAGA;AACA;AACA;AACA;AACA;;AAEA;AACA;AACA;AACA;AACA;AACA,cAAc;AACd;AACA;AACA;AACA,UAAU;AACV,sDAAsD;AACtD;AACA;AACA;AACA;;AAEA,CAAC;;AAED;AACA;AACA;AACA,CAAC;;AAED;AACA;AACA;AACA;AACA,C;;;;;;UCrIA;UACA;;UAEA;UACA;UACA;UACA;UACA;UACA;UACA;UACA;UACA;UACA;UACA;UACA;UACA;;UAEA;UACA;UACA;UACA;UACA;UACA;UACA;UACA;;UAEA;UACA;UACA;;;;;WC5BA;WACA;WACA;WACA;WACA;WACA,iCAAiC,WAAW;WAC5C;WACA,E;;;;;WCPA;WACA;WACA;WACA;WACA,yCAAyC,wCAAwC;WACjF;WACA;WACA,E;;;;;WCPA,wF;;;;;WCAA;WACA;WACA;WACA,uDAAuD,iBAAiB;WACxE;WACA,gDAAgD,aAAa;WAC7D,E;;;;;;;;;;;;;;;;;;;;;;;;;;;;;ACNA;AACmB;;AAEnB;AAC6B;AACF;;AAE3B;AACoC;AACD;AACQ;AACb;AACG;AACD;AACA;AACD;;AAE/B;AAC+B;AACO","sources":["webpack://mypgs/./assets/javascript/_pgs.js","webpack://mypgs/./assets/javascript/base/_darkmode.js","webpack://mypgs/./assets/javascript/base/_object.js","webpack://mypgs/./assets/javascript/components/_accordion.js","webpack://mypgs/./assets/javascript/components/_dropdown.js","webpack://mypgs/./assets/javascript/components/_exeNotifications.js","webpack://mypgs/./assets/javascript/components/_menu.js","webpack://mypgs/./assets/javascript/components/_modals.js","webpack://mypgs/./assets/javascript/components/_slides.js","webpack://mypgs/./assets/javascript/components/_steps.js","webpack://mypgs/./assets/javascript/components/_tabs.js","webpack://mypgs/./assets/javascript/functions/_notifications.js","webpack://mypgs/./assets/javascript/functions/_scrollY.js","webpack://mypgs/./assets/javascript/patterns/_cookieConsent.js","webpack://mypgs/./assets/javascript/patterns/_header.js","webpack://mypgs/webpack/bootstrap","webpack://mypgs/webpack/runtime/compat get default export","webpack://mypgs/webpack/runtime/define property getters","webpack://mypgs/webpack/runtime/hasOwnProperty shorthand","webpack://mypgs/webpack/runtime/make namespace object","webpack://mypgs/./assets/javascript/index.js"],"sourcesContent":["/**\n * @param {Element | Document} root\n*/\nexport function pgs(root) {\n const ATTR = \"pgs\";\n if (!root) throw new TypeError(\"pgs(root): root richiesto\");\n\n const canAttr = typeof root.getAttribute === \"function\" && typeof root.setAttribute === \"function\";\n const canQuery = typeof root.querySelector === \"function\" && typeof root.querySelectorAll === \"function\";\n\n if (!canQuery) {\n throw new TypeError(\"pgs(root): root deve supportare querySelector/querySelectorAll\");\n }\n\n //+\n function attrOnlyForElements(methodName) {\n throw new TypeError(`pgs(${root.nodeName || \"root\"}).${methodName}(): disponibile solo su Element (non su Document)`);\n };\n\n //+\n function concactSelector(value) {\n if (Array.isArray(value)) value = value.join(\",\");\n return String(value)\n .split(\",\")\n .map(v => v.trim())\n .filter(Boolean)\n .map(v => `[${ATTR}~=\"${v}\"]`)\n .join(\",\");\n }\n\n //+\n function getValues(el, separator = \" \") {\n return (el.getAttribute(ATTR) || \"\")\n .split(separator)\n .filter(Boolean);\n }\n\n //+\n function setValues(el, values, separator = \" \") {\n el.setAttribute(ATTR, values.join(separator));\n }\n\n //= BASE PGS \n function createBasePgs() {\n function api() {\n return api;\n }\n\n api.querySelector = function (value) {\n return root.querySelector(concactSelector(value));\n };\n\n api.querySelectorAll = function (value) {\n return root.querySelectorAll(concactSelector(value));\n };\n\n api.add = function (...values) {\n if (!canAttr) return attrOnlyForElements(\"add\");\n const current = getValues(root);\n for (const v of values) if (!current.includes(v)) current.push(v);\n setValues(root, current);\n return api;\n };\n\n api.remove = function (...values) {\n if (!canAttr) return attrOnlyForElements(\"remove\");\n setValues(root, getValues(root).filter(v => !values.includes(v)));\n return api;\n };\n\n api.toggle = function (value, force) {\n if (!canAttr) return attrOnlyForElements(\"toggle\");\n\n const exists = getValues(root).includes(value);\n\n if (force !== undefined) {\n if (force && !exists) api.add(value);\n if (!force && exists) api.remove(value);\n return !!force;\n }\n\n if (exists) {\n api.remove(value);\n return false;\n }\n\n api.add(value);\n return true;\n };\n\n api.contains = function (value) {\n if (!canAttr) return attrOnlyForElements(\"contains\");\n return getValues(root).includes(value);\n };\n\n Object.defineProperty(api, \"value\", {\n get() {\n if (!canAttr) return undefined;\n return root.getAttribute(ATTR);\n },\n set(v) {\n if (!canAttr) return attrOnlyForElements(\"value\");\n root.setAttribute(ATTR, v);\n }\n });\n\n return api;\n }\n\n //= STATE\n function createState(attribute) {\n if (!canAttr) return undefined;\n\n const read = (sep = \" \") =>\n (root.getAttribute(attribute) || \"\").split(sep).filter(Boolean);\n\n const write = (vals, sep = \" \") =>\n root.setAttribute(attribute, vals.join(sep));\n\n // funzione chiamabile: state(\"active\") == add(\"active\")\n function api(...values) {\n api.add(...values);\n return api;\n }\n\n api.add = function (...values) {\n const toAdd = values.flat().map(v => String(v).trim()).filter(Boolean);\n const current = read();\n for (const v of toAdd) if (!current.includes(v)) current.push(v);\n write(current);\n return api;\n };\n\n api.remove = function (...values) {\n const toRemove = values.flat().map(v => String(v).trim()).filter(Boolean);\n const current = read().filter(v => !toRemove.includes(v));\n write(current);\n return api;\n };\n\n api.toggle = function (value) {\n const v = String(value).trim();\n if (!v) return false;\n\n const current = read();\n if (current.includes(v)) {\n write(current.filter(x => x !== v));\n return false;\n }\n current.push(v);\n write(current);\n return true;\n };\n\n api.contains = function (value) {\n const v = String(value).trim();\n if (!v) return false;\n return read().includes(v);\n };\n\n Object.defineProperty(api, \"value\", {\n get() { return root.getAttribute(attribute); },\n set(v) { root.setAttribute(attribute, v); }\n });\n\n return api;\n }\n\n //= OPTION\n function createOption(attribute) {\n if (!canAttr) return undefined;\n\n function api() {\n return api;\n }\n\n api.contains = function (key) {\n const source = root.getAttribute(attribute) || \"\";\n const safeKey = String(key).replace(/[.*+?^${}()|[\\]\\\\]/g, \"\\\\$&\");\n\n return new RegExp(`(?:^|\\\\s)${safeKey}(?:\\\\[[^\\\\]]*\\\\])?(?=\\\\s|$)`)\n .test(source);\n };\n\n api.getValueBrackets = function (key) {\n const source = root.getAttribute(attribute) || \"\";\n const safeKey = String(key).replace(/[.*+?^${}()|[\\]\\\\]/g, \"\\\\$&\");\n\n const match = source.match(\n new RegExp(`(?:^|\\\\s)${safeKey}\\\\[([^\\\\]]*)\\\\]`)\n );\n\n return match ? match[1] : undefined;\n };\n\n Object.defineProperty(api, \"value\", {\n get() { return root.getAttribute(attribute); },\n set(v) { root.setAttribute(attribute, v); }\n });\n\n return api;\n }\n\n //# RETURN \n const api = createBasePgs();\n api.state = createState(\"pgs-state\");\n api.option = createOption(\"pgs-option\");\n api.modules = createOption(\"pgs-modules\");\n return api;\n}\n\nglobalThis.pgs ??= pgs;\n\n\n","//# DARKMODE\n\n\n//= CHANGE COLOR SVG & LOTTIE\n//+ SEARCH COLOR \nfunction searchColor(type = \"svg\") {\n const ROOT = getComputedStyle(document.documentElement);\n const colors = []\n for (let I = 0; I < 20; I++) {\n const color = ROOT.getPropertyValue('--' + type + '-color-' + I).toLocaleLowerCase().split(\"&\");\n if (!color[0] == \"\" && !color[1] == \"\") {\n let lightDark = [color[0], color[1]]\n colors.push(lightDark)\n }\n }\n return colors;\n}\nconst colors_svg_lottie = [searchColor(\"svg\"), searchColor(\"lottie\")];\n\n\n//+ change COLORS\nfunction darkmodeColorSVG() {\n function changecolor(svgDoc, type = \"svg\") {\n let isDarkMode = (document.documentElement.getAttribute(\"data-darkmode\") === \"true\") ? false : true;\n\n svgDoc.querySelectorAll('[fill], [stroke]').forEach(fillStroke => {\n\n for (const colors of colors_svg_lottie) {\n for (const color of colors) {\n let OLD = (color[0] || '').replace(/\\s/g, '');\n let NEW = (color[1] || '').replace(/\\s/g, '');\n\n [\"fill\", \"stroke\"].forEach(attr => {\n const current = fillStroke.getAttribute(attr);\n\n fillStroke.style.transition = \"fill 0.5s ease, stroke 0.5s ease\";\n\n if (!isDarkMode) {\n if (current == OLD) fillStroke.setAttribute(attr, NEW)\n } else {\n if (current == NEW) fillStroke.setAttribute(attr, OLD)\n }\n });\n }\n }\n });\n }\n\n //== OBJECTS\n const objects = document.querySelectorAll('object[type=\"image/svg+xml\"]');\n objects.forEach(obj => {\n\n //=== ALL FILL / STROKE\n obj.addEventListener(\"load\", () => {\n const svgDoc = obj.contentDocument;\n if (svgDoc) changecolor(svgDoc, \"svg\")\n });\n\n //=== In caso l'object sia già caricato\n if (obj.contentDocument) {\n const event = new Event(\"load\");\n obj.dispatchEvent(event);\n }\n });\n\n //== LOTTIE\n const lottiePlayers = document.querySelectorAll('lottie-player');\n lottiePlayers.forEach(lottiePlayer => {\n\n //=== ALL FILL / STROKE\n lottiePlayer.addEventListener(\"load\", () => {\n const svg = lottiePlayer.shadowRoot.querySelector('svg');\n if (svg) changecolor(svg, \"lottie\")\n });\n\n //=== In caso lottie sia già caricato\n if (lottiePlayer.shadowRoot) {\n const event = new Event(\"load\");\n lottiePlayer.dispatchEvent(event);\n }\n });\n}\n\n\n\n//= BUTTON DARKMODE \n//+ CHANGE ICON AND SVG \nlet toggleDarkmode = pgs(document).querySelectorAll(\"toggleDarkmode\");\nif (localStorage.getItem(\"screenIsDarkMode\") === \"true\") {\n document.body.classList.add(\"darkmode\");\n document.querySelector(\":root\").setAttribute(\"data-darkmode\", \"true\");\n document.body.setAttribute(\"data-darkmode\", \"true\");\n}\n\nfunction change(selector, isDarkMode) {\n selector.forEach(button => {\n const ICON = button.querySelector(\"i\");\n if (!ICON) return;\n ICON.classList.toggle(\"fa-moon\", !isDarkMode);\n ICON.classList.toggle(\"fa-sun\", isDarkMode);\n });\n darkmodeColorSVG();\n}\n\ntoggleDarkmode.forEach(button => {\n\n //== EXECUTE IMMEDIATELY\n let isDarkMode = document.documentElement.getAttribute(\"data-darkmode\") === \"true\";\n change(toggleDarkmode, isDarkMode);\n\n //== CLICK BUTTON \n button.addEventListener(\"click\", () => {\n let isDarkMode = (document.documentElement.getAttribute(\"data-darkmode\") === \"true\") ? false : true;\n localStorage.setItem(\"screenIsDarkMode\", isDarkMode);\n\n document.body.classList.toggle(\"darkmode\", isDarkMode);\n document.body.setAttribute(\"data-darkmode\", isDarkMode);\n document.querySelector(\":root\").setAttribute(\"data-darkmode\", isDarkMode);\n change(toggleDarkmode, isDarkMode);\n });\n});\n","document.addEventListener('DOMContentLoaded', () => {\n const objects = document.querySelectorAll('object[type=\"image/svg+xml\"]');\n\n objects.forEach(obj => {\n function applyAspectRatio(svgDoc) {\n if (!svgDoc) return;\n const svg = svgDoc.querySelector(\"svg\");\n if (!svg) return;\n\n const computedStyle = window.getComputedStyle(obj);\n svg.setAttribute(\"preserveAspectRatio\", computedStyle.objectFit === 'cover' ? \"xMidYMid slice\" : \"xMidYMid meet\");\n }\n\n function init() {\n const svgDoc = obj.contentDocument;\n if (!svgDoc) return;\n\n const svg = svgDoc.querySelector('svg');\n if (!svg) return;\n\n applyAspectRatio(svgDoc);\n if (obj.__objectResizeObserver) return;\n\n let rafId = 0;\n const resizeObserver = new ResizeObserver(() => {\n if (rafId) return;\n rafId = requestAnimationFrame(() => {\n rafId = 0;\n applyAspectRatio(svgDoc);\n });\n });\n\n resizeObserver.observe(obj);\n obj.__objectResizeObserver = resizeObserver;\n }\n\n if (obj.contentDocument && obj.contentDocument.querySelector('svg')) init();\n else obj.addEventListener('load', init, { once: true });\n });\n\n document.body.classList.add(\"object-loaded\");\n});\n","//= ACCORDION \nconst allAccordion = pgs(document).querySelectorAll(\"accordion\")\n\nallAccordion.forEach((accordion, index) => {\n\n const BUTTON = pgs(accordion).querySelector(\"accordion-button\");\n const CONTENT = pgs(accordion).querySelector(\"accordion-content\");\n\n //== ID univoci per aria-controls / aria-labelledby\n const ID = index + 1;\n const btnId = `acc-btn-${ID}`;\n const panelId = `acc-panel-${ID}`;\n\n //== Stato iniziale\n const isOpenInit = pgs(accordion).state.contains(\"open\");\n\n //== Accessibilità (setup una volta)\n BUTTON.setAttribute(\"role\", \"button\");\n BUTTON.setAttribute(\"tabindex\", \"0\");\n BUTTON.setAttribute(\"id\", btnId);\n BUTTON.setAttribute(\"aria-controls\", panelId);\n\n CONTENT.setAttribute(\"id\", panelId);\n CONTENT.setAttribute(\"role\", \"region\");\n CONTENT.setAttribute(\"aria-labelledby\", btnId);\n\n //+ Accessibility (applica stato aperto/chiuso)\n function accordionAccessibility(isOpen, button, content) {\n const text = (button?.textContent || \"\").trim().replace(/\\s+/g, \" \");\n button.setAttribute(\"aria-label\", `${isOpen ? \"Chiudi\" : \"Apri\"} ${text || \"sezione\"}`);\n button.setAttribute(\"aria-expanded\", String(isOpen));\n content.hidden = !isOpen;\n }\n\n //+ Chiudi tutti gli altri\n function closeOltherAccordion() {\n for (const otherLi of allAccordion) {\n if (otherLi === accordion) continue;\n\n const otherBtn = pgs(otherLi).querySelector(\"accordion-button\");\n const otherContent = pgs(otherLi).querySelector(\"accordion-content\");\n if (!otherBtn || !otherContent) continue;\n\n pgs(otherLi).state().remove(\"open\");\n accordionAccessibility(false, otherBtn, otherContent);\n }\n }\n\n //+ FN ACCORDION\n function accordionFunction() {\n const isOpen = pgs(accordion).state.contains(\"open\");\n const nowOpen = !isOpen;\n\n pgs(accordion).state.toggle(\"open\", nowOpen);\n accordionAccessibility(nowOpen, BUTTON, CONTENT);\n\n closeOltherAccordion();\n\n //== scroll to view\n if (nowOpen) setTimeout(() => accordion.scrollIntoView({ block: \"nearest\", inline: \"nearest\" }), 100);\n }\n\n // applica stato iniziale\n accordionAccessibility(isOpenInit, BUTTON, CONTENT);\n\n //- Eventi\n BUTTON.addEventListener(\"click\", accordionFunction);\n\n //- Tastiera: Enter / Space\n BUTTON.addEventListener(\"keydown\", (e) => {\n if (e.key === \"Enter\" || e.key === \" \") {\n e.preventDefault();\n accordionFunction();\n }\n });\n\n});\n","// + dropdown (Popover API)\nexport function pgs_dropdown() {\n pgs(document).querySelectorAll(\"dropdown\").forEach((DROPDOWN, index) => {\n const BUTTON = pgs(DROPDOWN).querySelector(\"dropdown-button\");\n const CONTENT = pgs(DROPDOWN).querySelector(\"dropdown-content\");\n\n if (!BUTTON || !CONTENT) return;\n\n // = INIT\n if (DROPDOWN.getAttribute(\"data-initialize\") === \"true\") return;\n DROPDOWN.setAttribute(\"data-initialize\", \"true\");\n\n // == CSS dropdown-anchor\n const ANCHOR_NAME = `--dropdown-anchor-${index}`;\n DROPDOWN.style.setProperty(\"--dropdown-anchor\", ANCHOR_NAME);\n\n // == IDs + ACCESSIBILITY\n if (!BUTTON.id) BUTTON.id = `dropdown-btn-${index}`;\n if (!CONTENT.id) CONTENT.id = `dropdown-panel-${index}`;\n BUTTON.setAttribute(\"type\", \"button\");\n BUTTON.setAttribute(\"aria-haspopup\", \"true\");\n BUTTON.setAttribute(\"aria-controls\", CONTENT.id);\n BUTTON.setAttribute(\"aria-expanded\", \"false\");\n CONTENT.setAttribute(\"aria-labelledby\", BUTTON.id);\n\n // == POPVER SETUP \n if (!CONTENT.hasAttribute(\"popover\")) CONTENT.setAttribute(\"popover\", \"auto\");\n BUTTON.setAttribute(\"popovertarget\", CONTENT.id);\n BUTTON.setAttribute(\"popovertargetaction\", \"toggle\");\n\n //-( Safari / legacy fallback: popover is in the top layer, so fixed coords are viewport-based.\n const HAS_ANCHOR_POSITIONING =\n CSS.supports(\"anchor-name: --dropdown-anchor\") &&\n CSS.supports(\"position-anchor: --dropdown-anchor\") &&\n CSS.supports(\"position-area: bottom\") &&\n CSS.supports(\"top: anchor(bottom)\");\n\n const updatePopoverPosition = () => {\n if (HAS_ANCHOR_POSITIONING) return;\n\n const buttonRect = BUTTON.getBoundingClientRect();\n const style = getComputedStyle(DROPDOWN);\n const offset = parseFloat(style.getPropertyValue(\"--dropdown-offset\")) || 10;\n const padding = parseFloat(style.getPropertyValue(\"--dropdown-padding\")) || 0;\n const arrowSize = parseFloat(style.getPropertyValue(\"--dropdown-arrow-size\")) || 12;\n const viewportGap = 8;\n const viewportWidth = window.innerWidth;\n const maxWidth = viewportWidth - viewportGap * 2;\n const contentStyle = getComputedStyle(CONTENT);\n const cssMaxWidth = parseFloat(contentStyle.maxWidth);\n const dropdownMaxWidth = Number.isFinite(cssMaxWidth) ? Math.min(cssMaxWidth, maxWidth) : maxWidth;\n const contentWidth = Math.min(\n Math.max(CONTENT.scrollWidth + padding * 2, buttonRect.width),\n dropdownMaxWidth\n );\n const top = buttonRect.bottom + offset;\n const centeredLeft = buttonRect.left + buttonRect.width / 2 - contentWidth / 2;\n const left = Math.min(\n Math.max(centeredLeft, viewportGap),\n viewportWidth - contentWidth - viewportGap\n );\n const buttonCenter = buttonRect.left + buttonRect.width / 2;\n const arrowLeft = Math.min(\n Math.max(buttonCenter - left, padding + arrowSize),\n contentWidth - padding - arrowSize\n );\n\n DROPDOWN.style.setProperty(\"--dropdown-fallback-top\", `${top}px`);\n DROPDOWN.style.setProperty(\"--dropdown-fallback-left\", `${left}px`);\n DROPDOWN.style.setProperty(\"--dropdown-arrow-left\", `${arrowLeft}px`);\n };\n\n BUTTON.addEventListener(\"click\", e => {\n if (HAS_ANCHOR_POSITIONING) return;\n\n e.preventDefault();\n if (CONTENT.matches(\":popover-open\")) {\n CONTENT.hidePopover();\n return;\n }\n\n updatePopoverPosition();\n CONTENT.showPopover();\n });\n\n // == sync ARIA + data-open quando apre/chiude\n CONTENT.addEventListener(\"toggle\", e => {\n const open = CONTENT.matches(\":popover-open\");\n BUTTON.setAttribute(\"aria-expanded\", open ? \"true\" : \"false\");\n pgs(DROPDOWN).state.toggle(\"open\", open);\n if (open) {\n updatePopoverPosition();\n CONTENT.querySelector('a, button, input, select, textarea, [tabindex]:not([tabindex=\"-1\"])')?.focus();\n }\n });\n\n window.addEventListener(\"resize\", () => {\n if (CONTENT.matches(\":popover-open\")) updatePopoverPosition();\n });\n window.addEventListener(\"scroll\", () => {\n if (CONTENT.matches(\":popover-open\")) updatePopoverPosition();\n }, true);\n });\n}\n\n// # INIT\npgs_dropdown();\n","import { PGS_notification, PGS_toast } from \"../functions/_notifications.js\";\n\nfunction escapeHtml(value) {\n return String(value ?? \"\");\n}\n\nfunction getDuration(notification) {\n const rawDuration = notification.duration;\n const duration = Number.parseInt(rawDuration, 10);\n\n return Number.isNaN(duration) ? 5000 : duration;\n}\n\nfunction getNotificationApi(notification) {\n const element = String(notification.element || \"notification\").trim();\n\n return element === \"toast\" ? PGS_toast : PGS_notification;\n}\n\nfunction getNotificationType(notification, api) {\n const type = String(notification.type || \"info\").trim();\n\n return typeof api[type] === \"function\" ? type : \"info\";\n}\n\nfunction getNotificationData(root) {\n try {\n return JSON.parse(root.dataset.notification || \"{}\");\n } catch (error) {\n console.warn(\"PGS notification: dati non validi\", error);\n return {};\n }\n}\n\nfunction getNotificationContent(title, content) {\n const safeContent = escapeHtml(content);\n const safeTitle = escapeHtml(title);\n\n if (!safeTitle) return safeContent;\n if (!safeContent) return `<span pgs=\"notification-element-title\">${safeTitle}</span>`;\n\n return `\n <span pgs=\"notification-element-title\">${safeTitle}</span>\n <br>\n <span pgs=\"notification-element-content\">${safeContent}</span>\n `;\n}\n\nexport function PGS_md_notification(root) {\n if (!root || root.dataset.initialize === \"true\") return;\n root.dataset.initialize = \"true\";\n\n const notification = getNotificationData(root);\n const title = String(notification.title || \"\").trim();\n const content = String(notification.message || \"\").trim();\n if (!title && !content) {\n root.remove();\n return;\n }\n\n const link = notification.link || null;\n const icon = notification.icon || undefined;\n const duration = getDuration(notification);\n const api = getNotificationApi(notification);\n const type = getNotificationType(notification, api);\n const formattedContent = getNotificationContent(title, content);\n\n if (api === PGS_toast) {\n api[type](formattedContent, duration, icon);\n } else {\n api[type](formattedContent, link, duration, icon);\n }\n\n root.remove();\n}\n\nfunction initMdNotifications() {\n pgs(document).querySelectorAll(\"notificationTrigger\").forEach(PGS_md_notification);\n}\n\nif (document.readyState === \"loading\") {\n document.addEventListener(\"DOMContentLoaded\", initMdNotifications);\n} else {\n initMdNotifications();\n}\n","import { pgs_dropdown } from \"./_dropdown\";\n\n//= DROP DOWN MENU\nexport function PGS_menu() {\n\n pgs(document).querySelectorAll('menu-horizontal').forEach(MENU => {\n\n MENU.querySelectorAll('nav > ul > li.menu-item-has-children').forEach(li => {\n if (li.querySelector(\"ul\")) {\n const ul = li.querySelector(\"ul\");\n\n const button = document.createElement(\"button\");\n button.className = \"icon-down\";\n button.type = \"button\";\n button.innerHTML = \"<span>⏷</span>\";\n li.querySelector(\"a\").insertAdjacentElement(\"afterend\", button);\n\n pgs(li).add(\"dropdown\")\n pgs(button).add(\"dropdown-button\")\n pgs(button).add(\"buttonNohover\")\n pgs(ul).add(\"dropdown-content\")\n pgs(ul).add(\"menu-vertical\")\n }\n });\n });\n\n pgs(document).querySelectorAll('menu-vertical').forEach(MENU => {\n\n MENU.querySelectorAll('.menu-item-has-children').forEach((li, index) => {\n const ul = li.querySelector(\"ul\");\n\n if (!ul) return\n\n const button = document.createElement(\"button\");\n button.className = \"icon-down buttonIcon\";\n button.type = \"button\";\n\n // ID unico per aria-controls\n const submenuId = `vertical-submenu-${index}`;\n ul.id = submenuId;\n\n // Stato iniziale\n pgs(button).add(\"buttonIcon\")\n button.setAttribute(\"aria-expanded\", \"false\");\n button.setAttribute(\"aria-controls\", submenuId);\n button.setAttribute(\"aria-label\", \"Apri sottomenu\");\n button.innerHTML = \"<span aria-hidden='true'>⏷</span>\";\n li.querySelector(\"a\").insertAdjacentElement(\"afterend\", button);\n\n function toggleMenu() {\n // const isOpena = ul.classList.toggle(\"open\");\n const isOpen = pgs(ul).state.toggle(\"open\");\n button.setAttribute(\"aria-expanded\", isOpen);\n button.setAttribute(\"aria-label\", isOpen ? \"Chiudi sottomenu\" : \"Apri sottomenu\");\n };\n\n // Click\n button.addEventListener(\"click\", toggleMenu);\n button.addEventListener(\"keydown\", (e) => {\n if (e.key === \"Enter\" || e.key === \" \") {\n e.preventDefault();\n toggleMenu();\n }\n });\n });\n\n // pgs(document).querySelectorAll('menu-vertical').forEach(MENU => {\n\n // MENU.querySelectorAll('.menu-item-has-children').forEach(li => {\n // if (li.querySelector(\"ul\")) {\n // const ul = li.querySelector(\"ul\");\n\n // const button = document.createElement(\"button\");\n // button.className = \"icon-down\";\n // button.type = \"button\";\n // button.innerHTML = \"<span>⏷</span>\";\n // li.querySelector(\"a\").insertAdjacentElement(\"afterend\", button);\n\n\n // pgs(button).add(\"buttonIcon\")\n // button.addEventListener(\"click\", () => {\n // ul.classList.toggle(\"open\")\n // })\n // }\n // });\n // });\n });\n pgs_dropdown()\n}\n\n//# INIT PGS_menu\nPGS_menu()","//# MODAL\nPGS_modal()\nexport function PGS_modal(selector = \"modal\") {\n pgs(document).querySelectorAll(selector).forEach(MODAL => {\n\n const BUTTON_OPEN = pgs(MODAL).querySelector(\"modal-button\"); \n const DIALOG = MODAL.querySelector(\"dialog\");\n if (!BUTTON_OPEN || !DIALOG) return;\n\n //== SELECTOR\n const DOMButtonClose = '<button pgs=\"buttonClose modal-close\" type=\"button\" tabindex=\"0\" aria-label=\"Chiudi\"><i class=\"fa-solid fa-close\"></i></button>';\n const modalContentHeader = pgs(MODAL)?.querySelector(\"modal-dialog-content-header\")\n \n \n //== OPTION ATTRIBUTES MODAL\n const disableBackdropClose = pgs(MODAL).option.contains(\"disableBackdropClose\")\n const data_history = pgs(MODAL).option.contains(\"history\");\n const data_container = pgs(MODAL).option.getValueBrackets(\"containerID\");\n const data_containerPGS = pgs(MODAL).option.getValueBrackets(\"containerPGS\");\n \n //== OPTION ATTRIBUTES DIALOG\n const topLevel = pgs(DIALOG).option.contains(\"topLevel\")\n\n \n //== BUTTON CLOSE\n if (pgs(MODAL).querySelector(\"modal-close\")) null\n else if (modalContentHeader) modalContentHeader.insertAdjacentHTML(\"beforeend\", DOMButtonClose)\n else DIALOG.insertAdjacentHTML(\"beforeend\", DOMButtonClose)\n const BUTTON_CLOSE = pgs(MODAL).querySelector(\"modal-close\")\n\n\n //== SET\n pgs(DIALOG).add(\"dialog modal-dialog\");\n\n //== BUTTON OPEN\n BUTTON_OPEN.setAttribute(\"role\", \"button\");\n BUTTON_OPEN.setAttribute(\"aria-label\", \"apri modale\");\n\n\n //== POSITION\n if(!topLevel){ \n if (data_container) document.querySelector(\"#\" + data_container)?.append(DIALOG);\n else if (data_containerPGS) pgs(document).querySelector(data_containerPGS)?.append(DIALOG);\n else document.body.append(DIALOG);\n }\n\n\n //+ FN STATUS \n function statusModal(status = true) {\n BUTTON_OPEN?.setAttribute(\"aria-expanded\", status);\n DIALOG?.setAttribute(\"aria-expanded\", status);\n }\n\n //+ FN OPEN \n function openModal(e) {\n e?.stopImmediatePropagation();\n if (!DIALOG.open) document.querySelectorAll(\"dialog[open]\").forEach((dlg) => dlg.close());\n statusModal(true);\n DIALOG.open ? closeModal(e) : topLevel ? DIALOG.showModal() : DIALOG.show();\n // modalCustomEvents('modal:open', { event: e });\n MODAL.dispatchEvent(new CustomEvent('modal:open'));\n DIALOG.dispatchEvent(new CustomEvent('modal:open'));\n }\n\n //+ FN CLOSE \n function closeModal(e) {\n e?.stopImmediatePropagation()\n statusModal(false);\n DIALOG.close();\n // modalCustomEvents('modal:close', { event: e });\n MODAL.dispatchEvent(new CustomEvent('modal:close'));\n DIALOG.dispatchEvent(new CustomEvent('modal:close'));\n }\n\n //+ fn OPEN ON HISTORY\n function openModalOnHistory() {\n const params = new URLSearchParams(window.location.search);\n if (params.get('modal') !== BUTTON_OPEN.id) return;\n document.getElementById(BUTTON_OPEN.id)?.scrollIntoView({ behavior: 'smooth' });\n openModal();\n }\n\n\n //= OPEN \n BUTTON_OPEN.addEventListener(\"click\", (e) => openModal(e));\n BUTTON_OPEN.addEventListener(\"keypress\", (e) => !DIALOG.open && (e.key === \"Enter\" || e.key === \" \") && openModal(e));\n \n //= CLOSE \n DIALOG.addEventListener(\"close\", () => statusModal(false));\n DIALOG.addEventListener(\"click\", e => { if (e.target == DIALOG && !disableBackdropClose) closeModal(e) });\n BUTTON_CLOSE?.addEventListener(\"click\", e => closeModal(e));\n \n //= UPDATE HISTORY\n if (data_history && BUTTON_OPEN.id) {\n setTimeout(openModalOnHistory, 1);\n\n //== Aggiorna URL quando cambia l'attributo \"open\" del dialog\n const obs = new MutationObserver(() => {\n let isOpen = DIALOG.hasAttribute(\"open\");\n try {\n const url = new URL(window.location.href);\n const params = new URLSearchParams(url.search);\n isOpen ? params.set('modal', BUTTON_OPEN.id) : params.delete('modal');\n url.search = params.toString() ? `?${params.toString()}` : \"\";\n window.history.pushState({ modal: BUTTON_OPEN.id, open: isOpen }, \"\", url);\n } catch (_) { }\n });\n obs.observe(DIALOG, { attributes: true, attributeFilter: [\"open\"] });\n\n //== Gestisce back/forward del browser per aprire/chiudere il dialog coerentemente\n window.addEventListener(\"popstate\", () => {\n try {\n const params = new URLSearchParams(window.location.search);\n const shouldOpen = params.get('modal') === BUTTON_OPEN.id;\n if (shouldOpen && !DIALOG.open) DIALOG.showModal();\n if (!shouldOpen && DIALOG.open) closeModal()\n } catch (_) { }\n });\n }\n });\n}\n\n//# INIT PGS_modal\n","import { PGS_scrollHorizontal } from \"../functions/_scrollY\"\nconst API = new WeakMap();\n\nclass PGS_Slides {\n //- CONSTRUCTOR\n constructor({ selector, viewRatio = 0.97, optionIntersectionObserver = {}, scrollOptions = {} } = {}) {\n this.selector = selector;\n this.viewRatio = viewRatio;\n\n this.optionIntersectionObserver = {\n threshold: Array.from({ length: 101 }, (_, i) => i / 100), // 0%,1%,2%...100%\n rootMargin: \"0px\",\n ...optionIntersectionObserver,\n };\n\n this.scrollOptions = {\n behavior: \"smooth\",\n inline: \"center\",\n block: \"nearest\",\n container: \"nearest\",\n ...scrollOptions,\n };\n\n this.container = this.selector ? pgs(this.selector).querySelector(\"slides-container\") : null;\n }\n \n //+ CREATE BUTTON \n #createButtonsAndDots() {\n const EL = this.selector\n\n //== PULSANTI\n if (!pgs(EL).querySelector('slides-prec') && !pgs(EL).querySelector('slides-next')) {\n EL.insertAdjacentHTML(\"afterbegin\", `<button pgs=\"slides-prec button\" type=\"button\" class=\"precButton\" aria-label=\"slide precedente\"> <span> <i class=\"fa-solid fa-arrow-left\"></i></span></button>`);\n EL.insertAdjacentHTML(\"beforeend\", `<button pgs=\"slides-next button\" type=\"button\" class=\"nextButton\" aria-label=\"prossima slide\"> <span> <i class=\"fa-solid fa-arrow-right\"></i></span></button>`);\n }\n\n //== DOTS\n if (!pgs(EL).querySelector('slides-dots')) {\n EL.insertAdjacentHTML(\"beforeend\", `<div pgs=\"slides-dots\" class=\"slides-dots\"></div>`);\n\n Array.from(this.container.children).forEach(() => {\n pgs(EL).querySelector('slides-dots')\n .insertAdjacentHTML(\"beforeend\", `<button type=\"button\" class=\"slide-dot\" aria-label=\"vai alla prossima slide\"></button>`);\n });\n }\n }\n\n //+ PREV \n #previousSlide() {\n const currents = this.container.querySelectorAll('.view');\n let current;\n \n\n if (pgs(this.selector).option.contains('singleScroll')) current = currents[currents.length - 1];\n else current = currents[0];\n\n const prev = current?.previousElementSibling;\n\n prev?.scrollIntoView(this.scrollOptions);\n prev?.focus({ preventScroll: true });\n }\n\n //+ NEXT \n #nextSlide() {\n const currents = this.container.querySelectorAll('.view');\n let current;\n\n \n \n if (pgs(this.selector).option.contains('singleScroll')) current = currents[0];\n else current = currents[currents.length - 1];\n \n const next = current?.nextElementSibling;\n console.log(current, next);\n\n next?.scrollIntoView(this.scrollOptions);\n next?.focus({ preventScroll: true });\n }\n\n //+ GO TO NUMBER SLIDE \n #goToNumberSlide(index) {\n this.container.children[index].scrollIntoView(this.scrollOptions)\n }\n\n //+ CALLBACK\n #callback(allLi, container, precButton, nextButton, dots) {\n allLi.forEach(LI => {\n const visiblePercent = 0.9 + LI.intersectionRatio * 0.1;\n const isView = visiblePercent >= 0.98;\n\n //== SCROLL ANIMATION\n if (!pgs(LI.target).option.contains('notScrollAnimation')) {\n LI.target.firstElementChild.style.setProperty('--visible-percent', `${visiblePercent}`);\n };\n\n //== VIEW & NOT-VIEW \n LI.target.classList.toggle(\"view\", isView);\n LI.target.classList.toggle(\"notView\", !isView);\n\n //== VIEW PREC e NEXT\n const all = LI.target.parentNode.children;\n const atStart = all[0].classList.contains(\"view\");\n const atEnd = all[all.length - 1].classList.contains(\"view\");\n nextButton.disabled = atEnd;\n precButton.disabled = atStart;\n nextButton.setAttribute('aria-disabled', String(atEnd));\n precButton.setAttribute('aria-disabled', String(atStart));\n\n //== ACTIVE DOT\n const viewElements = Array.from(container.children).filter(el => el.classList.contains('view'));\n dots.forEach((btn, i) => {\n const isActive = viewElements.some(el => Array.from(container.children).indexOf(el) === i);\n btn.classList.toggle('active', isActive);\n btn.setAttribute('aria-current', isActive ? 'true' : 'false');\n });\n })\n }\n\n //= EXECUTE\n execute() {\n const slides = this.selector;\n if (!this.container) return\n\n //== elements\n this.#createButtonsAndDots();\n const precButton = pgs(slides).querySelector('slides-prec');\n const nextButton = pgs(slides).querySelector('slides-next');\n const dots = Array.from(pgs(slides).querySelector('slides-dots').children);\n\n //== option\n const notScrollWithMouse = pgs(slides).option.contains('notScrollWithMouse');\n\n //== scroll\n if (!notScrollWithMouse) PGS_scrollHorizontal(this.container, 5);\n\n //==Listener: DOT, PREC, NEXT\n dots.forEach((dot, index) => dot.addEventListener(\"click\", e => this.#goToNumberSlide(index)));\n precButton.addEventListener(\"click\", e => this.#previousSlide(), { passive: true });\n nextButton.addEventListener(\"click\", e => this.#nextSlide(), { passive: true });\n\n //== observer\n const observer = new IntersectionObserver(\n (allLi) => this.#callback(allLi, this.container, precButton, nextButton, dots),\n { root: this.container, ...this.optionIntersectionObserver }\n );\n Array.from(this.container.children).forEach(allLi => observer.observe(allLi));\n\n\n //- API\n API.set(this.selector, {\n element: this.selector,\n container: this.container,\n previous: () => this.#previousSlide(),\n next: () => this.#nextSlide(),\n goTo: (index) => this.#goToNumberSlide(index),\n getCurrentIndexes: () => Array.from(this.container.children).map((el, i) => el.classList.contains(\"view\") ? i : -1).filter(i => i !== -1),\n getCurrentElements: () => Array.from(this.container.children).filter(el => el.classList.contains(\"view\")),\n getTotal: () => this.container.children.length,\n isAtStart: () => this.container.children[0]?.classList.contains(\"view\") || false,\n isAtEnd: () => {\n const children = this.container.children;\n const last = children[children.length - 1];\n return last?.classList.contains(\"view\") || false;\n },\n });\n }\n}\nPGS_slides_init();\n\n//# INIT \nexport function PGS_slides_init(root = document) {\n pgs(root).querySelectorAll(\"slides\").forEach(el => {\n if (API.has(el)) return;\n\n const instance = new PGS_Slides({ selector: el });\n instance.execute();\n });\n}\n\n//# API \nexport function PGS_slides_api(selector) {\n return API.get(selector);\n}\n","\nexport function PGS_ol() {\n pgs(document).querySelectorAll(\"steps\").forEach(steps => {\n\n pgs(steps).querySelectorAll(\"steps-step\").forEach((li, index) => {\n \n //= CIRCLE\n let circleLi;\n if (!pgs(li).querySelector(\"steps-step-circle\")) {\n circleLi = document.createElement(\"span\");\n pgs(circleLi).add(\"steps-step-circle\")\n circleLi.textContent = index + 1;\n li.insertAdjacentElement(\"afterbegin\", circleLi);\n } else{\n circleLi = pgs(li).querySelector(\"steps-step-circle\");\n }\n \n //= line\n const line = document.createElement(\"span\");\n pgs(line).add(\"steps-step-line\")\n li.insertAdjacentElement(\"afterbegin\", line);\n });\n });\n}\n\n//# INIT PGS_ol\nPGS_ol()","const API = new WeakMap();\nPGS_tabs()\n\nexport function PGS_tabs() {\n pgs(document).querySelectorAll(\"tabs\").forEach(tabsWizard => {\n\n //= INIT\n // if (tabsWizard.getAttribute(\"data-initialize\") == \"true\") return;\n // tabsWizard.setAttribute(\"data-initialize\", \"true\");\n\n //= SELECTOR\n const prev = pgs(tabsWizard).querySelector(\"tabs-prev\")\n const next = pgs(tabsWizard).querySelector(\"tabs-next\")\n const restart = pgs(tabsWizard).querySelector(\"tabs-restart\")\n const dots = pgs(tabsWizard).querySelector(\"tabs-dots\")\n const tabsContainer = pgs(tabsWizard).querySelector(\"tabs-container\");\n const allTab = pgs(tabsContainer).querySelectorAll(\"tab\");\n\n //= SETTING\n const total = allTab.length;\n const defaultTabLocked = Array.from(allTab).filter(tab => tab.getAttribute(\"data-tab-locked\") === \"true\")\n let current = 0;\n prev.disabled = true;\n\n //- CREAZIONE DOTS\n const tabDots = [];\n if (dots) {\n dots.innerHTML = \"\";\n\n allTab.forEach((tab, index) => {\n\n const iconClass = tab.getAttribute(\"data-tab-icon\") || \"fa-circle\";\n\n const dot = document.createElement(\"button\");\n dot.type = \"button\";\n dot.className = \"tab-dot\";\n dot.setAttribute(\"data-step\", index);\n dot.innerHTML = `<i class=\"fa-solid ${iconClass}\"></i>`;\n\n dot.addEventListener(\"click\", () => {\n if (dot.classList.contains(\"is-completed\")) {\n goTo(index, true);\n }\n });\n\n dots.appendChild(dot);\n tabDots.push(dot);\n });\n }\n\n //+ DOTS\n function updateDots() {\n tabDots.forEach((dot, i) => {\n dot.classList.toggle(\"is-active\", i === current);\n dot.classList.toggle(\"is-completed\", i < current);\n });\n }\n\n //+ Step\n function goTo(index) {\n current = Math.min(Math.max(index, 0), total - 1);\n const tab = allTab[current]\n\n prev.disabled = (current === 0);\n next.disabled = (current === total - 1 || tab.getAttribute(\"data-tab-locked\") === \"true\");\n\n allTab.forEach((tab, i) => tab.classList.toggle(\"is-active\", i === current));\n tab?.focus();\n tabsWizard?.scrollIntoView({ behavior: \"smooth\", block: \"start\" });\n updateDots();\n tabsWizard.dispatchEvent(new CustomEvent('tabs:change', { detail: { current, total } }));\n }\n\n //+ restart\n function restartTab() {\n goTo(0);\n defaultTabLocked.forEach(tab => tab.setAttribute(\"data-tab-locked\", \"true\"));\n }\n\n //= INIT\n goTo(0);\n\n //= data-tab-locked\n const observer = new MutationObserver(() => goTo(current));\n allTab?.forEach(tabEl => observer.observe(tabEl, { attributes: true, attributeFilter: [\"data-tab-locked\"], }));\n\n\n //= Click su Avanti/Indietro\n prev?.addEventListener(\"click\", e => goTo(current - 1));\n next?.addEventListener(\"click\", e => goTo(current + 1));\n restart?.addEventListener(\"click\", e => restartTab(), { capture: true });\n\n //-(API) \n // tabsWizard.addEventListener(\"tabs:reset\", () => restartTab());\n API.set(tabsWizard, {\n restart: restartTab,\n goTo,\n next: () => goTo(current + 1),\n prev: () => goTo(current - 1),\n toggleLock: (step, lock = true) => typeof step === \"number\" && allTab[step] && (allTab[step].setAttribute(\"data-tab-locked\", lock.toString()), goTo(current)),\n getCurrent: () => current,\n getState: () => ({ current, total }),\n });\n });\n}\n\nexport function PGS_tabs_api(selector) {\n return API.get(selector);\n}\n\n\n/* \n / EXAMPLE\n // vai allo step 2\n w.dispatchEvent(new CustomEvent(\"tabs:go\", { detail: { step: 2 } }));\n \n // next\n w.dispatchEvent(new CustomEvent(\"tabs:next\"));\n \n // prev\n w.dispatchEvent(new CustomEvent(\"tabs:prev\"));\n \n // reset a 0 senza relock\n w.dispatchEvent(new CustomEvent(\"tabs:reset\"));\n \n // lock step 3\n w.dispatchEvent(new CustomEvent(\"tabs:toggle-lock\", { detail: { step: 3, lock: true } }));\n \n // unlock step 3\n w.dispatchEvent(new CustomEvent(\"tabs:toggle-lock\", { detail: { step: 3, lock: false } }));\n \n // leggi stato\n w.dispatchEvent(new CustomEvent(\"tabs:get\", { detail: { reply: (state) => console.log(state) } }));\n*/\n","//# PGS_notification\nfunction initNotification(type, containerToken, icon, text, timeout, methodDelete = \"replace\", link = null) {\n let containerNotification = pgs(document).querySelector(containerToken);\n\n //== Create Container\n if (!containerNotification) {\n const newContainer = document.createElement(\"div\");\n pgs(newContainer).add(containerToken);\n newContainer.setAttribute(\"aria-live\", \"polite\");\n newContainer.setAttribute(\"aria-relevant\", \"additions\");\n document.body.appendChild(newContainer);\n containerNotification = newContainer;\n }\n\n //== Create Notification\n const notification = document.createElement(link ? \"a\" : \"div\");\n if (methodDelete == \"replace\") containerNotification.innerHTML = \"\";\n if (link) notification.href = link;\n if (timeout > 0) notification.style.setProperty(\"--notification-timeout\", timeout + \"ms\");\n pgs(notification).state.add(type);\n pgs(notification).add(\"notification-element\");\n notification.setAttribute(\"role\", type == \"error\" ? \"alert\" : \"status\")\n notification.innerHTML = `${icon} <p>${text}</p>`;\n containerNotification.appendChild(notification);\n\n\n //+ Animation delete \n function deleteNotification() {\n methodDelete == \"stack\" ? notification.style.translate = \"120%\" : notification.style.opacity = \"0\";\n setTimeout(() => notification.remove(), 300);\n }\n\n //== Timeout delete\n if (timeout > 0) setTimeout(() => { deleteNotification() }, timeout);\n\n //== button delete\n const btnDelete = document.createElement(\"button\");\n btnDelete.type = \"button\";\n btnDelete.ariaLabel = \"Rimuovi notifica\";\n btnDelete.innerHTML = '<i class=\"fa-solid fa-xmark\"></i>';\n btnDelete.setAttribute(\"pgs\", \"buttonClose\");\n notification.insertAdjacentElement(\"afterbegin\", btnDelete);\n\n //== event\n btnDelete.addEventListener(\"click\", function (e) {\n e.preventDefault();\n e.stopPropagation();\n e.stopImmediatePropagation()\n deleteNotification(e); // Esegue la tua funzione\n });\n}\n\nfunction deleteALl(containerToken) {\n let containerNotification = pgs(document).querySelector(containerToken);\n if (containerNotification) containerNotification.innerHTML = \"\";\n}\n\n\n\nexport let PGS_notification = {\n error: (text = \"Errore\", link = null, timeout = 0, icon = '<i class=\"fa-solid fa-octagon-xmark\"></i>') => initNotification(\"error\", \"notification\", icon, text, timeout, \"stack\", link),\n success: (text = \"Aggiornato\", link = null, timeout = 0, icon = '<i class=\"fa-solid fa-check\"></i>') => initNotification(\"success\", \"notification\", icon, text, timeout, \"stack\", link),\n info: (text = \"Aggiornamento\", link = null, timeout = 0, icon = '<i class=\"fa-solid fa-circle-info\"></i>',) => initNotification(\"info\", \"notification\", icon, text, timeout, \"stack\", link),\n warning: (text = \"Attenzione\", link = null, timeout = 0, icon = '<i class=\"fa-solid fa-triangle-exclamation\"></i>') => initNotification(\"warning\", \"notification\", icon, text, timeout, \"stack\", link),\n deleteAllNotification: () => deleteALl(\"notification\")\n}\n\nexport let PGS_toast = {\n error: (text = \"Errore\", timeout = 4000, icon = '<i class=\"fa-solid fa-octagon-xmark\"></i>',) => initNotification(\"error\", \"toast\", icon, text, timeout),\n success: (text = \"Aggiornato\", timeout = 4000, icon = '<i class=\"fa-solid fa-check\"></i>',) => initNotification(\"success\", \"toast\", icon, text, timeout),\n info: (text = \"Aggiornamento\", timeout = 0, icon = '<i class=\"fa-solid fa-circle-info\"></i>',) => initNotification(\"info\", \"toast\", icon, text, timeout),\n warning: (text = \"Attenzione\", timeout = 4000, icon = '<i class=\"fa-solid fa-triangle-exclamation\"></i>',) => initNotification(\"warning\", \"toast\", icon, text, timeout),\n deleteTost: () => deleteALl(\"toast\")\n}","export function PGS_scrollHorizontal(querySelector, dataSpeed) {\n // Se hai più contenitori, selezionali tutti:\n // Semplice \"singleton\" per stimare se la sorgente è trackpad\n const TrackpadDetector = (() => {\n let lastTs = 0;\n let smallAndFast = 0;\n let samples = 0;\n let isTrackpad = false;\n\n function update(e) {\n const now = performance.now();\n const dt = now - lastTs;\n\n // Porta delta in px (0: px, 1: linee, 2: pagine)\n let dy = Math.abs(e.deltaY);\n if (e.deltaMode === 1) dy *= 16;\n else if (e.deltaMode === 2) dy *= e.currentTarget?.clientHeight || 800;\n\n // Heuristica: eventi piccoli e ravvicinati → prob. trackpad\n const small = dy < 30; // soglia prudente\n const fast = dt < 35; // alta frequenza\n if (small && fast) smallAndFast++;\n\n samples++;\n if (samples >= 6) { // aggiorna il giudizio ogni N eventi\n isTrackpad = smallAndFast >= 3;\n smallAndFast = 0;\n samples = 0;\n }\n\n lastTs = now;\n return isTrackpad;\n }\n\n return {\n update,\n get value() { return isTrackpad; }\n };\n })();\n\n //= Scorrimento orizzontale con rotella (evita il trackpad)\n \n let el = querySelector\n el.addEventListener('wheel', (e) => {\n const speed = dataSpeed;\n\n //== lascia lo scroll naturale del trackpad\n if (TrackpadDetector.update(e)) return;\n\n //== Evita interferenze con zoom o scroll orizzontale nativo\n if (e.ctrlKey) return;\n if (Math.abs(e.deltaX) > Math.abs(e.deltaY)) return;\n\n //== Converti delta in px per lo shift orizzontale\n let delta = e.deltaY;\n if (e.deltaMode === 1) delta *= 16;\n else if (e.deltaMode === 2) delta *= el.clientHeight;\n\n //== Verifica se il contenitore può ancora scrollare orizzontalmente\n const atStart = el.scrollLeft <= 0;\n const atEnd = el.scrollLeft + el.clientWidth >= el.scrollWidth - 1;\n const scrollingRight = delta > 0;\n const scrollingLeft = delta < 0;\n const canScrollHoriz =\n (scrollingRight && !atEnd) ||\n (scrollingLeft && !atStart);\n\n // Se non può più scrollare in quella direzione, lascia che la pagina gestisca lo scroll verticale\n if (!canScrollHoriz) return;\n\n //== Previeni il default solo quando facciamo noi lo scroll orizzontale\n e.preventDefault();\n\n //== rotella giù => destra\n el.scrollLeft += delta * speed;\n }, { passive: false });\n}\n","const STORAGE_KEY = 'pgs_cookie_preferences_v1';\nconst focusableSelectors = 'a[href], button:not([disabled]), input:not([disabled]), [tabindex]:not([tabindex=\"-1\"])';\n\n//+ \nfunction safeJsonParse(value) {\n try {\n return value ? JSON.parse(value) : null;\n } catch (error) {\n console.warn('PGS cookie consent: impossibile leggere le preferenze', error);\n return null;\n }\n}\n\n//+ \nfunction readPreferences() {\n try {\n return safeJsonParse(localStorage.getItem(STORAGE_KEY));\n } catch (error) {\n return null;\n }\n}\n\n//+ \nfunction savePreferences(prefs) {\n try {\n localStorage.setItem(\n STORAGE_KEY,\n JSON.stringify({ ...prefs, updatedAt: new Date().toISOString() })\n );\n } catch (error) {\n console.warn('PGS cookie consent: impossibile salvare le preferenze', error);\n }\n}\n\n//+ \nfunction bootstrapGtag() {\n window.dataLayer = window.dataLayer || [];\n window.gtag = window.gtag || function gtag() {\n window.dataLayer.push(arguments);\n };\n}\n\n//+ \nfunction loadGoogleAnalytics(measurementId) {\n if (!measurementId || window.__PGS_gaLoaded) return;\n window.__PGS_gaLoaded = true;\n\n const script = document.createElement('script');\n script.async = true;\n script.src = `https://www.googletagmanager.com/gtag/js?id=${measurementId}`;\n document.head.appendChild(script);\n\n window.gtag('js', new Date());\n window.gtag('config', measurementId, {\n anonymize_ip: true,\n allow_google_signals: false,\n });\n}\n\n//+ \nfunction applyAnalyticsConsent({ allowAnalytics, measurementId }) {\n bootstrapGtag();\n if (allowAnalytics) {\n window.gtag('consent', 'update', { analytics_storage: 'granted' });\n loadGoogleAnalytics(measurementId);\n } else {\n window.gtag('consent', 'update', { analytics_storage: 'denied' });\n }\n}\n\n//+\nfunction setPgsFlag(element, token, enabled) {\n if (!(element instanceof HTMLElement) || !token) return;\n const current = (element.getAttribute('pgs') || '').split(/\\s+/).filter(Boolean);\n const next = enabled ? [...new Set([...current, token])] : current.filter((item) => item !== token);\n if (next.length > 0) {\n element.setAttribute('pgs', next.join(' '));\n } else {\n element.removeAttribute('pgs');\n }\n}\n\n//+\nfunction assignCookieRuntimeAttributes({ root, analyticsToggle, acceptAllButton, rejectButton, openButtons }) {\n root.dataset.cookieComponent = 'consent';\n analyticsToggle?.setAttribute('data-cookie-toggle', 'analytics');\n acceptAllButton?.setAttribute('data-cookie-action', 'accept');\n rejectButton?.setAttribute('data-cookie-action', 'reject');\n\n root.querySelector('[pgs~=\"cookieConsent-featureEssential\"]')?.setAttribute('data-cookie-feature', 'essential');\n root.querySelector('[pgs~=\"cookieConsent-featureAnalytics\"]')?.setAttribute('data-cookie-feature', 'analytics');\n\n openButtons.forEach((button) => {\n button.setAttribute('data-cookie-action', 'open');\n });\n}\n\n//= CookieConsent\ndocument.addEventListener('DOMContentLoaded', function () {\n const root = pgs(document).querySelector('cookieConsent');\n if (!root) return;\n\n const analyticsToggle = root.querySelector('[pgs~=\"cookieConsent-toggleAnalytics\"]');\n const acceptAllButton = root.querySelector('[pgs~=\"cookieConsent-actionAccept\"]');\n const rejectButton = root.querySelector('[pgs~=\"cookieConsent-actionReject\"]');\n const openButtons = document.querySelectorAll('[pgs~=\"cookieConsent-actionOpen\"]');\n const measurementId = (root.dataset.gaId || '').trim();\n const prefersGa = measurementId.length > 0;\n let lastFocusedElement = null;\n\n assignCookieRuntimeAttributes({ root, analyticsToggle, acceptAllButton, rejectButton, openButtons });\n\n if (analyticsToggle) {\n analyticsToggle.disabled = !prefersGa;\n if (!prefersGa) {\n analyticsToggle.checked = false;\n setPgsFlag(root, 'cookieConsent-gaUnavailable', true);\n } else {\n setPgsFlag(root, 'cookieConsent-gaUnavailable', false);\n }\n }\n\n bootstrapGtag();\n window.gtag('consent', 'default', { analytics_storage: 'denied' });\n\n function setBannerVisibility(show) {\n root.hidden = !show;\n root.setAttribute('aria-hidden', String(!show));\n document.body.classList.toggle('cookieConsent-open', show);\n if (show) {\n lastFocusedElement = document.activeElement;\n setTimeout(() => {\n root.focus();\n }, 0);\n } else if (lastFocusedElement instanceof HTMLElement) {\n lastFocusedElement.focus({ preventScroll: true });\n }\n }\n\n function closeBanner() {\n setBannerVisibility(false);\n }\n\n function openBanner() {\n setBannerVisibility(true);\n }\n\n function persistAndApply(allowAnalytics) {\n savePreferences({ analytics: allowAnalytics });\n setPgsFlag(root, 'cookieConsent-accepted', !!allowAnalytics);\n setPgsFlag(root, 'cookieConsent-declined', !allowAnalytics);\n applyAnalyticsConsent({ allowAnalytics: !!allowAnalytics, measurementId });\n }\n\n acceptAllButton?.addEventListener('click', () => {\n if (analyticsToggle && prefersGa) analyticsToggle.checked = true;\n persistAndApply(!!prefersGa);\n closeBanner();\n });\n\n rejectButton?.addEventListener('click', () => {\n const allowAnalytics = analyticsToggle ? analyticsToggle.checked && prefersGa : false;\n if (!allowAnalytics && analyticsToggle) analyticsToggle.checked = false;\n persistAndApply(allowAnalytics);\n closeBanner();\n });\n\n analyticsToggle?.addEventListener('change', (event) => {\n if (!prefersGa && event.target instanceof HTMLInputElement) {\n event.target.checked = false;\n }\n });\n\n root.addEventListener('keydown', (event) => {\n if (event.key === 'Escape') {\n event.preventDefault();\n closeBanner();\n } else if (event.key === 'Tab') {\n const focusables = root.querySelectorAll(focusableSelectors);\n if (focusables.length === 0) return;\n const first = focusables[0];\n const last = focusables[focusables.length - 1];\n if (!event.shiftKey && document.activeElement === last) {\n event.preventDefault();\n first.focus();\n }\n if (event.shiftKey && document.activeElement === first) {\n event.preventDefault();\n last.focus();\n }\n }\n });\n\n openButtons.forEach((button) => {\n button.addEventListener('click', (event) => {\n event.preventDefault();\n openBanner();\n });\n });\n\n const savedPrefs = readPreferences();\n if (savedPrefs && typeof savedPrefs.analytics === 'boolean') {\n if (analyticsToggle) analyticsToggle.checked = !!savedPrefs.analytics && prefersGa;\n persistAndApply(savedPrefs.analytics && prefersGa);\n closeBanner();\n } else {\n setBannerVisibility(true);\n }\n});\n","//# HEADER\nconst header = pgs(document).querySelector(\"header\");\nconst headerElements = pgs(header).querySelectorAll(\"header-element\");\nheaderElements.forEach(element => PGS_header(element));\n\n//= HEADER\nexport function PGS_header(selectHeader) {\n\n //= INIT\n if (selectHeader.getAttribute(\"data-initialize\") == \"true\") return;\n selectHeader.setAttribute(\"data-initialize\", \"true\");\n\n //= ACTIVE MOBILE \n let menuAttivate = false;\n let childsWidthSAVE;\n\n function mobileActive(headerElement) {\n\n //=== header\n let style = window.getComputedStyle(headerElement);\n let padding = parseFloat(style.paddingLeft) + parseFloat(style.paddingRight);\n let gap = parseFloat(style.gap);\n let headerElementWidth = parseInt(headerElement.offsetWidth - padding);\n let childsWidth;\n\n if (menuAttivate) {\n childsWidth = childsWidthSAVE;\n } else {\n let childs = [];\n\n // Esclude l'area mobile dedicata e l'hamburger, poi misura i figli sempre visibili su desktop.\n Array.from(headerElement.children)\n .filter(el => !pgs(el).contains(\"header-element-onlyMobile\"))\n .forEach(child => {\n if (pgs(child).contains(\"header-element-hamburger\")) return;\n childs.push(...child.children);\n });\n\n gap = Math.round(gap * (childs.length - 1));\n let childsReduce = childs.reduce((totalWidth, child) => totalWidth + child.offsetWidth, 0) - 2;\n\n childsWidth = childsReduce + gap;\n }\n\n //===set data\n if (window.innerWidth < 600) {\n header.setAttribute(\"data-header-mobileActive\", \"true\");\n selectHeader.setAttribute(\"data-header-mobileActive\", \"true\");\n } else if (headerElementWidth < childsWidth) {\n header.setAttribute(\"data-header-mobileActive\", \"true\");\n headerElement.setAttribute(\"data-header-mobileActive\", \"true\");\n menuAttivate = true;\n childsWidthSAVE = childsWidth;\n } else {\n header.setAttribute(\"data-header-mobileActive\", \"false\");\n headerElement.setAttribute(\"data-header-mobileActive\", \"false\");\n }\n }\n\n //== observer (throttled to avoid ResizeObserver loop warnings)\n let resizeRafId = 0;\n const scheduleMobileActive = () => {\n if (resizeRafId) return;\n resizeRafId = requestAnimationFrame(() => {\n resizeRafId = 0;\n mobileActive(selectHeader);\n });\n };\n\n let observer = new ResizeObserver(scheduleMobileActive);\n observer.observe(selectHeader);\n scheduleMobileActive();\n\n}\n\n\n\n\n//= HEADER HEIGHT\nconst body = document.querySelector(\"body\");\nfunction headerHeight() {\n const headerElements = document.querySelectorAll(\"header > [data-initialize=true]\");\n const wordPressBar = window.getComputedStyle(document.documentElement).marginTop ?? 0;\n\n const totalHeight = Array.from(headerElements)\n .map(el => el.offsetHeight)\n .reduce((sum, h) => sum + h);\n\n const height = totalHeight + parseInt(wordPressBar);\n\n body.style.setProperty('--heightOfHeader', `${height}px`);\n const scrollHeight = document.querySelector(\"header\").getAttribute(\"data-header-scroll\") === \"true\" ? 0 : height;\n body.style.setProperty('--heightOfHeaderScroll', `${scrollHeight}px`);\n\n}\nheaderHeight()\nwindow.addEventListener(\"resize\", headerHeight);\nwindow.addEventListener(\"scroll\", headerHeight);\n\n\n//= SCROLL\n// Nasconde l'header quando si scorre verso il basso e lo mostra quando si scorre verso l'alto su dispositivi con larghezza fino a 900px.\nlet lastScrollY = window.scrollY;\nwindow.addEventListener(\"scroll\", () => {\n let currentScrollY = window.scrollY;\n\n if (window.innerHeight <= 900) {\n if (currentScrollY >= 80) {\n if (currentScrollY > lastScrollY) {\n header.style.transform = \"translateY(-100%)\";\n header.setAttribute(\"data-header-scroll\", true)\n } else {\n header.style.transform = \"translateY(0px)\";\n header.setAttribute(\"data-header-scroll\", false)\n }\n } else {\n header.style.transform = \"translateY(0)\"; // Mostra sempre l'header se il scroll è inferiore a 80px\n header.setAttribute(\"data-header-scroll\", false)\n }\n }\n lastScrollY = currentScrollY;\n\n});\n\n// Ripristina la posizione dell'header quando si esce dalla modalità mobile\nwindow.addEventListener(\"resize\", () => {\n if (window.innerWidth > 768) header.style.transform = \"translateY(0)\";\n});\n\n// MOBILE ACTIVE\nif (window.innerWidth < 600) {\n document.querySelector(\"header\").setAttribute(\"data-header-mobileActive\", \"true\");\n document.querySelector(\"[pgs~=header-element]\").setAttribute(\"data-header-mobileActive\", \"true\");\n}","// The module cache\nvar __webpack_module_cache__ = {};\n\n// The require function\nfunction __webpack_require__(moduleId) {\n\t// Check if module is in cache\n\tvar cachedModule = __webpack_module_cache__[moduleId];\n\tif (cachedModule !== undefined) {\n\t\treturn cachedModule.exports;\n\t}\n\t// Create a new module (and put it into the cache)\n\tvar module = __webpack_module_cache__[moduleId] = {\n\t\t// no module.id needed\n\t\t// no module.loaded needed\n\t\texports: {}\n\t};\n\n\t// Execute the module function\n\tif (!(moduleId in __webpack_modules__)) {\n\t\tdelete __webpack_module_cache__[moduleId];\n\t\tvar e = new Error(\"Cannot find module '\" + moduleId + \"'\");\n\t\te.code = 'MODULE_NOT_FOUND';\n\t\tthrow e;\n\t}\n\t__webpack_modules__[moduleId](module, module.exports, __webpack_require__);\n\n\t// Return the exports of the module\n\treturn module.exports;\n}\n\n","// getDefaultExport function for compatibility with non-harmony modules\n__webpack_require__.n = (module) => {\n\tvar getter = module && module.__esModule ?\n\t\t() => (module['default']) :\n\t\t() => (module);\n\t__webpack_require__.d(getter, { a: getter });\n\treturn getter;\n};","// define getter functions for harmony exports\n__webpack_require__.d = (exports, definition) => {\n\tfor(var key in definition) {\n\t\tif(__webpack_require__.o(definition, key) && !__webpack_require__.o(exports, key)) {\n\t\t\tObject.defineProperty(exports, key, { enumerable: true, get: definition[key] });\n\t\t}\n\t}\n};","__webpack_require__.o = (obj, prop) => (Object.prototype.hasOwnProperty.call(obj, prop))","// define __esModule on exports\n__webpack_require__.r = (exports) => {\n\tif(typeof Symbol !== 'undefined' && Symbol.toStringTag) {\n\t\tObject.defineProperty(exports, Symbol.toStringTag, { value: 'Module' });\n\t}\n\tObject.defineProperty(exports, '__esModule', { value: true });\n};","//= PGS\nimport \"./_pgs.js\";\n\n//= BASE\nimport \"./base/_darkmode.js\";\nimport \"./base/_object.js\";\n\n//= CN \nimport \"./components/_accordion.js\";\nimport \"./components/_dropdown.js\";\nimport \"./components/_exeNotifications.js\";\nimport \"./components/_menu.js\"\nimport \"./components/_modals.js\";\nimport \"./components/_slides.js\"\nimport \"./components/_steps.js\";\nimport \"./components/_tabs.js\";\n\n//= patterns \nimport \"./patterns/_header.js\";\nimport \"./patterns/_cookieConsent.js\";\n"],"names":[],"sourceRoot":""}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
(()=>{var e={795(){function e(e="svg"){const t=getComputedStyle(document.documentElement),n=[];for(let o=0;o<20;o++){const r=t.getPropertyValue("--"+e+"-color-"+o).toLocaleLowerCase().split("&");if(""==!r[0]&&""==!r[1]){let e=[r[0],r[1]];n.push(e)}}return n}const t=[e("svg"),e("lottie")];let n=pgs(document).querySelectorAll("toggleDarkmode");function o(e,n){e.forEach(e=>{const t=e.querySelector("i");t&&(t.classList.toggle("fa-moon",!n),t.classList.toggle("fa-sun",n))}),function(){function e(e,n="svg"){let o="true"!==document.documentElement.getAttribute("data-darkmode");e.querySelectorAll("[fill], [stroke]").forEach(e=>{for(const n of t)for(const t of n){let n=(t[0]||"").replace(/\s/g,""),r=(t[1]||"").replace(/\s/g,"");["fill","stroke"].forEach(t=>{const i=e.getAttribute(t);e.style.transition="fill 0.5s ease, stroke 0.5s ease",o?i==r&&e.setAttribute(t,n):i==n&&e.setAttribute(t,r)})}})}document.querySelectorAll('object[type="image/svg+xml"]').forEach(t=>{if(t.addEventListener("load",()=>{const n=t.contentDocument;n&&e(n,"svg")}),t.contentDocument){const e=new Event("load");t.dispatchEvent(e)}}),document.querySelectorAll("lottie-player").forEach(t=>{if(t.addEventListener("load",()=>{const n=t.shadowRoot.querySelector("svg");n&&e(n,"lottie")}),t.shadowRoot){const e=new Event("load");t.dispatchEvent(e)}})}()}"true"===localStorage.getItem("screenIsDarkMode")&&(document.body.classList.add("darkmode"),document.querySelector(":root").setAttribute("data-darkmode","true"),document.body.setAttribute("data-darkmode","true")),n.forEach(e=>{let t="true"===document.documentElement.getAttribute("data-darkmode");o(n,t),e.addEventListener("click",()=>{let e="true"!==document.documentElement.getAttribute("data-darkmode");localStorage.setItem("screenIsDarkMode",e),document.body.classList.toggle("darkmode",e),document.body.setAttribute("data-darkmode",e),document.querySelector(":root").setAttribute("data-darkmode",e),o(n,e)})})},359(){document.addEventListener("DOMContentLoaded",()=>{document.querySelectorAll('object[type="image/svg+xml"]').forEach(e=>{function t(t){if(!t)return;const n=t.querySelector("svg");if(!n)return;const o=window.getComputedStyle(e);n.setAttribute("preserveAspectRatio","cover"===o.objectFit?"xMidYMid slice":"xMidYMid meet")}function n(){const n=e.contentDocument;if(!n)return;if(!n.querySelector("svg"))return;if(t(n),e.__objectResizeObserver)return;let o=0;const r=new ResizeObserver(()=>{o||(o=requestAnimationFrame(()=>{o=0,t(n)}))});r.observe(e),e.__objectResizeObserver=r}e.contentDocument&&e.contentDocument.querySelector("svg")?n():e.addEventListener("load",n,{once:!0})}),document.body.classList.add("object-loaded")})},527(){const e=pgs(document).querySelectorAll("accordion");e.forEach((t,n)=>{const o=pgs(t).querySelector("accordion-button"),r=pgs(t).querySelector("accordion-content"),i=n+1,s=`acc-btn-${i}`,a=`acc-panel-${i}`,c=pgs(t).state.contains("open");function l(e,t,n){const o=(t?.textContent||"").trim().replace(/\s+/g," ");t.setAttribute("aria-label",`${e?"Chiudi":"Apri"} ${o||"sezione"}`),t.setAttribute("aria-expanded",String(e)),n.hidden=!e}function d(){const n=!pgs(t).state.contains("open");pgs(t).state.toggle("open",n),l(n,o,r),function(){for(const n of e){if(n===t)continue;const e=pgs(n).querySelector("accordion-button"),o=pgs(n).querySelector("accordion-content");e&&o&&(pgs(n).state().remove("open"),l(!1,e,o))}}(),n&&setTimeout(()=>t.scrollIntoView({block:"nearest",inline:"nearest"}),100)}o.setAttribute("role","button"),o.setAttribute("tabindex","0"),o.setAttribute("id",s),o.setAttribute("aria-controls",a),r.setAttribute("id",a),r.setAttribute("role","region"),r.setAttribute("aria-labelledby",s),l(c,o,r),o.addEventListener("click",d),o.addEventListener("keydown",e=>{"Enter"!==e.key&&" "!==e.key||(e.preventDefault(),d())})})},48(){const e="pgs_cookie_preferences_v1";function t(){window.dataLayer=window.dataLayer||[],window.gtag=window.gtag||function(){window.dataLayer.push(arguments)}}function n(e,t,n){if(!(e instanceof HTMLElement&&t))return;const o=(e.getAttribute("pgs")||"").split(/\s+/).filter(Boolean),r=n?[...new Set([...o,t])]:o.filter(e=>e!==t);r.length>0?e.setAttribute("pgs",r.join(" ")):e.removeAttribute("pgs")}document.addEventListener("DOMContentLoaded",function(){const o=pgs(document).querySelector("cookieConsent");if(!o)return;const r=o.querySelector('[pgs~="cookieConsent-toggleAnalytics"]'),i=o.querySelector('[pgs~="cookieConsent-actionAccept"]'),s=o.querySelector('[pgs~="cookieConsent-actionReject"]'),a=document.querySelectorAll('[pgs~="cookieConsent-actionOpen"]'),c=(o.dataset.gaId||"").trim(),l=c.length>0;let d=null;function u(e){o.hidden=!e,o.setAttribute("aria-hidden",String(!e)),document.body.classList.toggle("cookieConsent-open",e),e?(d=document.activeElement,setTimeout(()=>{o.focus()},0)):d instanceof HTMLElement&&d.focus({preventScroll:!0})}function p(){u(!1)}function g(r){!function(t){try{localStorage.setItem(e,JSON.stringify({...t,updatedAt:(new Date).toISOString()}))}catch(e){console.warn("PGS cookie consent: impossibile salvare le preferenze",e)}}({analytics:r}),n(o,"cookieConsent-accepted",!!r),n(o,"cookieConsent-declined",!r),function({allowAnalytics:e,measurementId:n}){t(),e?(window.gtag("consent","update",{analytics_storage:"granted"}),function(e){if(!e||window.__PGS_gaLoaded)return;window.__PGS_gaLoaded=!0;const t=document.createElement("script");t.async=!0,t.src=`https://www.googletagmanager.com/gtag/js?id=${e}`,document.head.appendChild(t),window.gtag("js",new Date),window.gtag("config",e,{anonymize_ip:!0,allow_google_signals:!1})}(n)):window.gtag("consent","update",{analytics_storage:"denied"})}({allowAnalytics:!!r,measurementId:c})}!function({root:e,analyticsToggle:t,acceptAllButton:n,rejectButton:o,openButtons:r}){e.dataset.cookieComponent="consent",t?.setAttribute("data-cookie-toggle","analytics"),n?.setAttribute("data-cookie-action","accept"),o?.setAttribute("data-cookie-action","reject"),e.querySelector('[pgs~="cookieConsent-featureEssential"]')?.setAttribute("data-cookie-feature","essential"),e.querySelector('[pgs~="cookieConsent-featureAnalytics"]')?.setAttribute("data-cookie-feature","analytics"),r.forEach(e=>{e.setAttribute("data-cookie-action","open")})}({root:o,analyticsToggle:r,acceptAllButton:i,rejectButton:s,openButtons:a}),r&&(r.disabled=!l,l?n(o,"cookieConsent-gaUnavailable",!1):(r.checked=!1,n(o,"cookieConsent-gaUnavailable",!0))),t(),window.gtag("consent","default",{analytics_storage:"denied"}),i?.addEventListener("click",()=>{r&&l&&(r.checked=!0),g(!!l),p()}),s?.addEventListener("click",()=>{const e=!!r&&r.checked&&l;!e&&r&&(r.checked=!1),g(e),p()}),r?.addEventListener("change",e=>{!l&&e.target instanceof HTMLInputElement&&(e.target.checked=!1)}),o.addEventListener("keydown",e=>{if("Escape"===e.key)e.preventDefault(),p();else if("Tab"===e.key){const t=o.querySelectorAll('a[href], button:not([disabled]), input:not([disabled]), [tabindex]:not([tabindex="-1"])');if(0===t.length)return;const n=t[0],r=t[t.length-1];e.shiftKey||document.activeElement!==r||(e.preventDefault(),n.focus()),e.shiftKey&&document.activeElement===n&&(e.preventDefault(),r.focus())}}),a.forEach(e=>{e.addEventListener("click",e=>{e.preventDefault(),u(!0)})});const f=function(){try{return function(e){try{return e?JSON.parse(e):null}catch(e){return console.warn("PGS cookie consent: impossibile leggere le preferenze",e),null}}(localStorage.getItem(e))}catch(e){return null}}();f&&"boolean"==typeof f.analytics?(r&&(r.checked=!!f.analytics&&l),g(f.analytics&&l),p()):u(!0)})}},t={};function n(o){var r=t[o];if(void 0!==r)return r.exports;var i=t[o]={exports:{}};return e[o](i,i.exports,n),i.exports}(()=>{"use strict";function e(){pgs(document).querySelectorAll("dropdown").forEach((e,t)=>{const n=pgs(e).querySelector("dropdown-button"),o=pgs(e).querySelector("dropdown-content");if(!n||!o)return;if("true"===e.getAttribute("data-initialize"))return;e.setAttribute("data-initialize","true");const r=`--dropdown-anchor-${t}`;e.style.setProperty("--dropdown-anchor",r),n.id||(n.id=`dropdown-btn-${t}`),o.id||(o.id=`dropdown-panel-${t}`),n.setAttribute("type","button"),n.setAttribute("aria-haspopup","true"),n.setAttribute("aria-controls",o.id),n.setAttribute("aria-expanded","false"),o.setAttribute("aria-labelledby",n.id),o.hasAttribute("popover")||o.setAttribute("popover","auto"),n.setAttribute("popovertarget",o.id),n.setAttribute("popovertargetaction","toggle");const i=CSS.supports("anchor-name: --dropdown-anchor")&&CSS.supports("position-anchor: --dropdown-anchor")&&CSS.supports("position-area: bottom")&&CSS.supports("top: anchor(bottom)"),s=()=>{if(i)return;const t=n.getBoundingClientRect(),r=getComputedStyle(e),s=parseFloat(r.getPropertyValue("--dropdown-offset"))||10,a=parseFloat(r.getPropertyValue("--dropdown-padding"))||0,c=parseFloat(r.getPropertyValue("--dropdown-arrow-size"))||12,l=window.innerWidth,d=l-16,u=getComputedStyle(o),p=parseFloat(u.maxWidth),g=Number.isFinite(p)?Math.min(p,d):d,f=Math.min(Math.max(o.scrollWidth+2*a,t.width),g),m=t.bottom+s,b=t.left+t.width/2-f/2,h=Math.min(Math.max(b,8),l-f-8),y=t.left+t.width/2,v=Math.min(Math.max(y-h,a+c),f-a-c);e.style.setProperty("--dropdown-fallback-top",`${m}px`),e.style.setProperty("--dropdown-fallback-left",`${h}px`),e.style.setProperty("--dropdown-arrow-left",`${v}px`)};n.addEventListener("click",e=>{i||(e.preventDefault(),o.matches(":popover-open")?o.hidePopover():(s(),o.showPopover()))}),o.addEventListener("toggle",t=>{const r=o.matches(":popover-open");n.setAttribute("aria-expanded",r?"true":"false"),pgs(e).state.toggle("open",r),r&&(s(),o.querySelector('a, button, input, select, textarea, [tabindex]:not([tabindex="-1"])')?.focus())}),window.addEventListener("resize",()=>{o.matches(":popover-open")&&s()}),window.addEventListener("scroll",()=>{o.matches(":popover-open")&&s()},!0)})}function t(e,t,n,o,r,i="replace",s=null){let a=pgs(document).querySelector(t);if(!a){const e=document.createElement("div");pgs(e).add(t),e.setAttribute("aria-live","polite"),e.setAttribute("aria-relevant","additions"),document.body.appendChild(e),a=e}const c=document.createElement(s?"a":"div");function l(){"stack"==i?c.style.translate="120%":c.style.opacity="0",setTimeout(()=>c.remove(),300)}"replace"==i&&(a.innerHTML=""),s&&(c.href=s),r>0&&c.style.setProperty("--notification-timeout",r+"ms"),pgs(c).state.add(e),pgs(c).add("notification-element"),c.setAttribute("role","error"==e?"alert":"status"),c.innerHTML=`${n} <p>${o}</p>`,a.appendChild(c),r>0&&setTimeout(()=>{l()},r);const d=document.createElement("button");d.type="button",d.ariaLabel="Rimuovi notifica",d.innerHTML='<i class="fa-solid fa-xmark"></i>',d.setAttribute("pgs","buttonClose"),c.insertAdjacentElement("afterbegin",d),d.addEventListener("click",function(e){e.preventDefault(),e.stopPropagation(),e.stopImmediatePropagation(),l()})}function o(e){let t=pgs(document).querySelector(e);t&&(t.innerHTML="")}globalThis.pgs??=function(e){const t="pgs";if(!e)throw new TypeError("pgs(root): root richiesto");const n="function"==typeof e.getAttribute&&"function"==typeof e.setAttribute;if("function"!=typeof e.querySelector||"function"!=typeof e.querySelectorAll)throw new TypeError("pgs(root): root deve supportare querySelector/querySelectorAll");function o(t){throw new TypeError(`pgs(${e.nodeName||"root"}).${t}(): disponibile solo su Element (non su Document)`)}function r(e){return Array.isArray(e)&&(e=e.join(",")),String(e).split(",").map(e=>e.trim()).filter(Boolean).map(e=>`[${t}~="${e}"]`).join(",")}function i(e,n=" "){return(e.getAttribute(t)||"").split(n).filter(Boolean)}function s(e,n,o=" "){e.setAttribute(t,n.join(o))}function a(t){if(n)return o.contains=function(n){const o=e.getAttribute(t)||"",r=String(n).replace(/[.*+?^${}()|[\]\\]/g,"\\$&");return new RegExp(`(?:^|\\s)${r}(?:\\[[^\\]]*\\])?(?=\\s|$)`).test(o)},o.getValueBrackets=function(n){const o=e.getAttribute(t)||"",r=String(n).replace(/[.*+?^${}()|[\]\\]/g,"\\$&"),i=o.match(new RegExp(`(?:^|\\s)${r}\\[([^\\]]*)\\]`));return i?i[1]:void 0},Object.defineProperty(o,"value",{get:()=>e.getAttribute(t),set(n){e.setAttribute(t,n)}}),o;function o(){return o}}const c=function(){function a(){return a}return a.querySelector=function(t){return e.querySelector(r(t))},a.querySelectorAll=function(t){return e.querySelectorAll(r(t))},a.add=function(...t){if(!n)return o("add");const r=i(e);for(const e of t)r.includes(e)||r.push(e);return s(e,r),a},a.remove=function(...t){return n?(s(e,i(e).filter(e=>!t.includes(e))),a):o("remove")},a.toggle=function(t,r){if(!n)return o("toggle");const s=i(e).includes(t);return void 0!==r?(r&&!s&&a.add(t),!r&&s&&a.remove(t),!!r):s?(a.remove(t),!1):(a.add(t),!0)},a.contains=function(t){return n?i(e).includes(t):o("contains")},Object.defineProperty(a,"value",{get(){if(n)return e.getAttribute(t)},set(r){if(!n)return o("value");e.setAttribute(t,r)}}),a}();return c.state=function(t){if(!n)return;const o=(n=" ")=>(e.getAttribute(t)||"").split(n).filter(Boolean),r=(n,o=" ")=>e.setAttribute(t,n.join(o));function i(...e){return i.add(...e),i}return i.add=function(...e){const t=e.flat().map(e=>String(e).trim()).filter(Boolean),n=o();for(const e of t)n.includes(e)||n.push(e);return r(n),i},i.remove=function(...e){const t=e.flat().map(e=>String(e).trim()).filter(Boolean),n=o().filter(e=>!t.includes(e));return r(n),i},i.toggle=function(e){const t=String(e).trim();if(!t)return!1;const n=o();return n.includes(t)?(r(n.filter(e=>e!==t)),!1):(n.push(t),r(n),!0)},i.contains=function(e){const t=String(e).trim();return!!t&&o().includes(t)},Object.defineProperty(i,"value",{get:()=>e.getAttribute(t),set(n){e.setAttribute(t,n)}}),i}("pgs-state"),c.option=a("pgs-option"),c.modules=a("pgs-modules"),c},n(795),n(359),n(527),e();let r={error:(e="Errore",n=null,o=0,r='<i class="fa-solid fa-octagon-xmark"></i>')=>t("error","notification",r,e,o,"stack",n),success:(e="Aggiornato",n=null,o=0,r='<i class="fa-solid fa-check"></i>')=>t("success","notification",r,e,o,"stack",n),info:(e="Aggiornamento",n=null,o=0,r='<i class="fa-solid fa-circle-info"></i>')=>t("info","notification",r,e,o,"stack",n),warning:(e="Attenzione",n=null,o=0,r='<i class="fa-solid fa-triangle-exclamation"></i>')=>t("warning","notification",r,e,o,"stack",n),deleteAllNotification:()=>o("notification")},i={error:(e="Errore",n=4e3,o='<i class="fa-solid fa-octagon-xmark"></i>')=>t("error","toast",o,e,n),success:(e="Aggiornato",n=4e3,o='<i class="fa-solid fa-check"></i>')=>t("success","toast",o,e,n),info:(e="Aggiornamento",n=0,o='<i class="fa-solid fa-circle-info"></i>')=>t("info","toast",o,e,n),warning:(e="Attenzione",n=4e3,o='<i class="fa-solid fa-triangle-exclamation"></i>')=>t("warning","toast",o,e,n),deleteTost:()=>o("toast")};function s(e){return String(e??"")}function a(e){if(!e||"true"===e.dataset.initialize)return;e.dataset.initialize="true";const t=function(e){try{return JSON.parse(e.dataset.notification||"{}")}catch(e){return console.warn("PGS notification: dati non validi",e),{}}}(e),n=String(t.title||"").trim(),o=String(t.message||"").trim();if(!n&&!o)return void e.remove();const a=t.link||null,c=t.icon||void 0,l=function(e){const t=e.duration,n=Number.parseInt(t,10);return Number.isNaN(n)?5e3:n}(t),d=function(e){return"toast"===String(e.element||"notification").trim()?i:r}(t),u=function(e,t){const n=String(e.type||"info").trim();return"function"==typeof t[n]?n:"info"}(t,d),p=function(e,t){const n=s(t),o=s(e);return o?n?`\n <span pgs="notification-element-title">${o}</span>\n <br>\n <span pgs="notification-element-content">${n}</span>\n `:`<span pgs="notification-element-title">${o}</span>`:n}(n,o);d===i?d[u](p,l,c):d[u](p,a,l,c),e.remove()}function c(){pgs(document).querySelectorAll("notificationTrigger").forEach(a)}"loading"===document.readyState?document.addEventListener("DOMContentLoaded",c):c(),pgs(document).querySelectorAll("menu-horizontal").forEach(e=>{e.querySelectorAll("nav > ul > li.menu-item-has-children").forEach(e=>{if(e.querySelector("ul")){const t=e.querySelector("ul"),n=document.createElement("button");n.className="icon-down",n.type="button",n.innerHTML="<span>⏷</span>",e.querySelector("a").insertAdjacentElement("afterend",n),pgs(e).add("dropdown"),pgs(n).add("dropdown-button"),pgs(n).add("buttonNohover"),pgs(t).add("dropdown-content"),pgs(t).add("menu-vertical")}})}),pgs(document).querySelectorAll("menu-vertical").forEach(e=>{e.querySelectorAll(".menu-item-has-children").forEach((e,t)=>{const n=e.querySelector("ul");if(!n)return;const o=document.createElement("button");o.className="icon-down buttonIcon",o.type="button";const r=`vertical-submenu-${t}`;function i(){const e=pgs(n).state.toggle("open");o.setAttribute("aria-expanded",e),o.setAttribute("aria-label",e?"Chiudi sottomenu":"Apri sottomenu")}n.id=r,pgs(o).add("buttonIcon"),o.setAttribute("aria-expanded","false"),o.setAttribute("aria-controls",r),o.setAttribute("aria-label","Apri sottomenu"),o.innerHTML="<span aria-hidden='true'>⏷</span>",e.querySelector("a").insertAdjacentElement("afterend",o),o.addEventListener("click",i),o.addEventListener("keydown",e=>{"Enter"!==e.key&&" "!==e.key||(e.preventDefault(),i())})})}),e(),function(e="modal"){pgs(document).querySelectorAll(e).forEach(e=>{const t=pgs(e).querySelector("modal-button"),n=e.querySelector("dialog");if(!t||!n)return;const o='<button pgs="buttonClose modal-close" type="button" tabindex="0" aria-label="Chiudi"><i class="fa-solid fa-close"></i></button>',r=pgs(e)?.querySelector("modal-dialog-content-header"),i=pgs(e).option.contains("disableBackdropClose"),s=pgs(e).option.contains("history"),a=pgs(e).option.getValueBrackets("containerID"),c=pgs(e).option.getValueBrackets("containerPGS"),l=pgs(n).option.contains("topLevel");pgs(e).querySelector("modal-close")||(r?r.insertAdjacentHTML("beforeend",o):n.insertAdjacentHTML("beforeend",o));const d=pgs(e).querySelector("modal-close");function u(e=!0){t?.setAttribute("aria-expanded",e),n?.setAttribute("aria-expanded",e)}function p(t){t?.stopImmediatePropagation(),n.open||document.querySelectorAll("dialog[open]").forEach(e=>e.close()),u(!0),n.open?g(t):l?n.showModal():n.show(),e.dispatchEvent(new CustomEvent("modal:open")),n.dispatchEvent(new CustomEvent("modal:open"))}function g(t){t?.stopImmediatePropagation(),u(!1),n.close(),e.dispatchEvent(new CustomEvent("modal:close")),n.dispatchEvent(new CustomEvent("modal:close"))}pgs(n).add("dialog modal-dialog"),t.setAttribute("role","button"),t.setAttribute("aria-label","apri modale"),l||(a?document.querySelector("#"+a)?.append(n):c?pgs(document).querySelector(c)?.append(n):document.body.append(n)),t.addEventListener("click",e=>p(e)),t.addEventListener("keypress",e=>!n.open&&("Enter"===e.key||" "===e.key)&&p(e)),n.addEventListener("close",()=>u(!1)),n.addEventListener("click",e=>{e.target!=n||i||g(e)}),d?.addEventListener("click",e=>g(e)),s&&t.id&&(setTimeout(function(){new URLSearchParams(window.location.search).get("modal")===t.id&&(document.getElementById(t.id)?.scrollIntoView({behavior:"smooth"}),p())},1),new MutationObserver(()=>{let e=n.hasAttribute("open");try{const n=new URL(window.location.href),o=new URLSearchParams(n.search);e?o.set("modal",t.id):o.delete("modal"),n.search=o.toString()?`?${o.toString()}`:"",window.history.pushState({modal:t.id,open:e},"",n)}catch(e){}}).observe(n,{attributes:!0,attributeFilter:["open"]}),window.addEventListener("popstate",()=>{try{const e=new URLSearchParams(window.location.search).get("modal")===t.id;e&&!n.open&&n.showModal(),!e&&n.open&&g()}catch(e){}}))})}();const l=new WeakMap;class d{constructor({selector:e,viewRatio:t=.97,optionIntersectionObserver:n={},scrollOptions:o={}}={}){this.selector=e,this.viewRatio=t,this.optionIntersectionObserver={threshold:Array.from({length:101},(e,t)=>t/100),rootMargin:"0px",...n},this.scrollOptions={behavior:"smooth",inline:"center",block:"nearest",container:"nearest",...o},this.container=this.selector?pgs(this.selector).querySelector("slides-container"):null}#e(){const e=this.selector;pgs(e).querySelector("slides-prec")||pgs(e).querySelector("slides-next")||(e.insertAdjacentHTML("afterbegin",'<button pgs="slides-prec button" type="button" class="precButton" aria-label="slide precedente"> <span> <i class="fa-solid fa-arrow-left"></i></span></button>'),e.insertAdjacentHTML("beforeend",'<button pgs="slides-next button" type="button" class="nextButton" aria-label="prossima slide"> <span> <i class="fa-solid fa-arrow-right"></i></span></button>')),pgs(e).querySelector("slides-dots")||(e.insertAdjacentHTML("beforeend",'<div pgs="slides-dots" class="slides-dots"></div>'),Array.from(this.container.children).forEach(()=>{pgs(e).querySelector("slides-dots").insertAdjacentHTML("beforeend",'<button type="button" class="slide-dot" aria-label="vai alla prossima slide"></button>')}))}#t(){const e=this.container.querySelectorAll(".view");let t;t=pgs(this.selector).option.contains("singleScroll")?e[e.length-1]:e[0];const n=t?.previousElementSibling;n?.scrollIntoView(this.scrollOptions),n?.focus({preventScroll:!0})}#n(){const e=this.container.querySelectorAll(".view");let t;t=pgs(this.selector).option.contains("singleScroll")?e[0]:e[e.length-1];const n=t?.nextElementSibling;console.log(t,n),n?.scrollIntoView(this.scrollOptions),n?.focus({preventScroll:!0})}#o(e){this.container.children[e].scrollIntoView(this.scrollOptions)}#r(e,t,n,o,r){e.forEach(e=>{const i=.9+.1*e.intersectionRatio,s=i>=.98;pgs(e.target).option.contains("notScrollAnimation")||e.target.firstElementChild.style.setProperty("--visible-percent",`${i}`),e.target.classList.toggle("view",s),e.target.classList.toggle("notView",!s);const a=e.target.parentNode.children,c=a[0].classList.contains("view"),l=a[a.length-1].classList.contains("view");o.disabled=l,n.disabled=c,o.setAttribute("aria-disabled",String(l)),n.setAttribute("aria-disabled",String(c));const d=Array.from(t.children).filter(e=>e.classList.contains("view"));r.forEach((e,n)=>{const o=d.some(e=>Array.from(t.children).indexOf(e)===n);e.classList.toggle("active",o),e.setAttribute("aria-current",o?"true":"false")})})}execute(){const e=this.selector;if(!this.container)return;this.#e();const t=pgs(e).querySelector("slides-prec"),n=pgs(e).querySelector("slides-next"),o=Array.from(pgs(e).querySelector("slides-dots").children);pgs(e).option.contains("notScrollWithMouse")||function(e){const t=(()=>{let e=0,t=0,n=0,o=!1;return{update:function(r){const i=performance.now(),s=i-e;let a=Math.abs(r.deltaY);return 1===r.deltaMode?a*=16:2===r.deltaMode&&(a*=r.currentTarget?.clientHeight||800),a<30&&s<35&&t++,n++,n>=6&&(o=t>=3,t=0,n=0),e=i,o},get value(){return o}}})();let n=e;n.addEventListener("wheel",e=>{if(t.update(e))return;if(e.ctrlKey)return;if(Math.abs(e.deltaX)>Math.abs(e.deltaY))return;let o=e.deltaY;1===e.deltaMode?o*=16:2===e.deltaMode&&(o*=n.clientHeight);const r=n.scrollLeft<=0,i=n.scrollLeft+n.clientWidth>=n.scrollWidth-1;(o>0&&!i||o<0&&!r)&&(e.preventDefault(),n.scrollLeft+=5*o)},{passive:!1})}(this.container),o.forEach((e,t)=>e.addEventListener("click",e=>this.#o(t))),t.addEventListener("click",e=>this.#t(),{passive:!0}),n.addEventListener("click",e=>this.#n(),{passive:!0});const r=new IntersectionObserver(e=>this.#r(e,this.container,t,n,o),{root:this.container,...this.optionIntersectionObserver});Array.from(this.container.children).forEach(e=>r.observe(e)),l.set(this.selector,{element:this.selector,container:this.container,previous:()=>this.#t(),next:()=>this.#n(),goTo:e=>this.#o(e),getCurrentIndexes:()=>Array.from(this.container.children).map((e,t)=>e.classList.contains("view")?t:-1).filter(e=>-1!==e),getCurrentElements:()=>Array.from(this.container.children).filter(e=>e.classList.contains("view")),getTotal:()=>this.container.children.length,isAtStart:()=>this.container.children[0]?.classList.contains("view")||!1,isAtEnd:()=>{const e=this.container.children,t=e[e.length-1];return t?.classList.contains("view")||!1}})}}!function(e=document){pgs(e).querySelectorAll("slides").forEach(e=>{l.has(e)||new d({selector:e}).execute()})}(),pgs(document).querySelectorAll("steps").forEach(e=>{pgs(e).querySelectorAll("steps-step").forEach((e,t)=>{let n;pgs(e).querySelector("steps-step-circle")?n=pgs(e).querySelector("steps-step-circle"):(n=document.createElement("span"),pgs(n).add("steps-step-circle"),n.textContent=t+1,e.insertAdjacentElement("afterbegin",n));const o=document.createElement("span");pgs(o).add("steps-step-line"),e.insertAdjacentElement("afterbegin",o)})});const u=new WeakMap;pgs(document).querySelectorAll("tabs").forEach(e=>{const t=pgs(e).querySelector("tabs-prev"),n=pgs(e).querySelector("tabs-next"),o=pgs(e).querySelector("tabs-restart"),r=pgs(e).querySelector("tabs-dots"),i=pgs(e).querySelector("tabs-container"),s=pgs(i).querySelectorAll("tab"),a=s.length,c=Array.from(s).filter(e=>"true"===e.getAttribute("data-tab-locked"));let l=0;t.disabled=!0;const d=[];function p(o){l=Math.min(Math.max(o,0),a-1);const r=s[l];t.disabled=0===l,n.disabled=l===a-1||"true"===r.getAttribute("data-tab-locked"),s.forEach((e,t)=>e.classList.toggle("is-active",t===l)),r?.focus(),e?.scrollIntoView({behavior:"smooth",block:"start"}),d.forEach((e,t)=>{e.classList.toggle("is-active",t===l),e.classList.toggle("is-completed",t<l)}),e.dispatchEvent(new CustomEvent("tabs:change",{detail:{current:l,total:a}}))}function g(){p(0),c.forEach(e=>e.setAttribute("data-tab-locked","true"))}r&&(r.innerHTML="",s.forEach((e,t)=>{const n=e.getAttribute("data-tab-icon")||"fa-circle",o=document.createElement("button");o.type="button",o.className="tab-dot",o.setAttribute("data-step",t),o.innerHTML=`<i class="fa-solid ${n}"></i>`,o.addEventListener("click",()=>{o.classList.contains("is-completed")&&p(t)}),r.appendChild(o),d.push(o)})),p(0);const f=new MutationObserver(()=>p(l));s?.forEach(e=>f.observe(e,{attributes:!0,attributeFilter:["data-tab-locked"]})),t?.addEventListener("click",e=>p(l-1)),n?.addEventListener("click",e=>p(l+1)),o?.addEventListener("click",e=>g(),{capture:!0}),u.set(e,{restart:g,goTo:p,next:()=>p(l+1),prev:()=>p(l-1),toggleLock:(e,t=!0)=>"number"==typeof e&&s[e]&&(s[e].setAttribute("data-tab-locked",t.toString()),p(l)),getCurrent:()=>l,getState:()=>({current:l,total:a})})});const p=pgs(document).querySelector("header");pgs(p).querySelectorAll("header-element").forEach(e=>function(e){if("true"==e.getAttribute("data-initialize"))return;e.setAttribute("data-initialize","true");let t,n=!1;let o=0;const r=()=>{o||(o=requestAnimationFrame(()=>{o=0,function(o){let r,i=window.getComputedStyle(o),s=parseFloat(i.paddingLeft)+parseFloat(i.paddingRight),a=parseFloat(i.gap),c=parseInt(o.offsetWidth-s);if(n)r=t;else{let e=[];Array.from(o.children).filter(e=>!pgs(e).contains("header-element-onlyMobile")).forEach(t=>{pgs(t).contains("header-element-hamburger")||e.push(...t.children)}),a=Math.round(a*(e.length-1)),r=e.reduce((e,t)=>e+t.offsetWidth,0)-2+a}window.innerWidth<600?(p.setAttribute("data-header-mobileActive","true"),e.setAttribute("data-header-mobileActive","true")):c<r?(p.setAttribute("data-header-mobileActive","true"),o.setAttribute("data-header-mobileActive","true"),n=!0,t=r):(p.setAttribute("data-header-mobileActive","false"),o.setAttribute("data-header-mobileActive","false"))}(e)}))};new ResizeObserver(r).observe(e),r()}(e));const g=document.querySelector("body");function f(){const e=document.querySelectorAll("header > [data-initialize=true]"),t=window.getComputedStyle(document.documentElement).marginTop??0,n=Array.from(e).map(e=>e.offsetHeight).reduce((e,t)=>e+t)+parseInt(t);g.style.setProperty("--heightOfHeader",`${n}px`);const o="true"===document.querySelector("header").getAttribute("data-header-scroll")?0:n;g.style.setProperty("--heightOfHeaderScroll",`${o}px`)}f(),window.addEventListener("resize",f),window.addEventListener("scroll",f);let m=window.scrollY;window.addEventListener("scroll",()=>{let e=window.scrollY;window.innerHeight<=900&&(e>=80?e>m?(p.style.transform="translateY(-100%)",p.setAttribute("data-header-scroll",!0)):(p.style.transform="translateY(0px)",p.setAttribute("data-header-scroll",!1)):(p.style.transform="translateY(0)",p.setAttribute("data-header-scroll",!1))),m=e}),window.addEventListener("resize",()=>{window.innerWidth>768&&(p.style.transform="translateY(0)")}),window.innerWidth<600&&(document.querySelector("header").setAttribute("data-header-mobileActive","true"),document.querySelector("[pgs~=header-element]").setAttribute("data-header-mobileActive","true")),n(48)})()})();
|
package/package.json
ADDED
|
@@ -0,0 +1,40 @@
|
|
|
1
|
+
{
|
|
2
|
+
"name": "mypgs",
|
|
3
|
+
"version": "1.0.0",
|
|
4
|
+
"description": "MyPGS frontend theme and UI behaviors, with bundled JavaScript and CSS assets.",
|
|
5
|
+
"main": "./dist/javascript/index.js",
|
|
6
|
+
"types": "./dist/index.d.ts",
|
|
7
|
+
"exports": {
|
|
8
|
+
".": "./dist/javascript/index.js",
|
|
9
|
+
"./style.css": "./dist/css/index.css",
|
|
10
|
+
"./style.min.css": "./dist/css/index.min.css"
|
|
11
|
+
},
|
|
12
|
+
"style": "./dist/css/index.css",
|
|
13
|
+
"scripts": {
|
|
14
|
+
"start": "webpack",
|
|
15
|
+
"start watch": "webpack --watch",
|
|
16
|
+
"syncmaster-forzato": "git fetch origin && git checkout dev && git pull --rebase origin dev && git rebase origin/master && git push --force-with-lease origin dev && git checkout master && git pull --ff-only origin master && git merge --ff-only dev && git push origin master && git checkout dev",
|
|
17
|
+
"syncmaster": "git fetch origin && git checkout master && git pull --ff-only origin master && git merge --ff-only origin/dev && git push origin master && git checkout dev"
|
|
18
|
+
},
|
|
19
|
+
"keywords": [
|
|
20
|
+
"theme",
|
|
21
|
+
"css",
|
|
22
|
+
"ui",
|
|
23
|
+
"frontend",
|
|
24
|
+
"components"
|
|
25
|
+
],
|
|
26
|
+
"license": "ISC",
|
|
27
|
+
"devDependencies": {
|
|
28
|
+
"css-loader": "^7.1.2",
|
|
29
|
+
"mini-css-extract-plugin": "^2.9.2",
|
|
30
|
+
"postcss-loader": "^8.2.0",
|
|
31
|
+
"sass": "^1.86.3",
|
|
32
|
+
"sass-loader": "^16.0.5",
|
|
33
|
+
"sass-migrator": "^2.3.1",
|
|
34
|
+
"style-loader": "^4.0.0",
|
|
35
|
+
"webpack": "^5.98.0",
|
|
36
|
+
"webpack-cli": "^6.0.1",
|
|
37
|
+
"webpack-dev-server": "^5.2.0",
|
|
38
|
+
"webpack-remove-empty-scripts": "^1.0.4"
|
|
39
|
+
}
|
|
40
|
+
}
|
|
@@ -0,0 +1,23 @@
|
|
|
1
|
+
<nav aria-label="Breadcrumb">
|
|
2
|
+
<ul pgs="breadcrumbs">
|
|
3
|
+
<li pgs="breadcrumbs-item">
|
|
4
|
+
<a href="/">Home</a>
|
|
5
|
+
<span pgs="breadcrumbs-item-separator" aria-hidden="true">
|
|
6
|
+
>
|
|
7
|
+
</span>
|
|
8
|
+
</li>
|
|
9
|
+
|
|
10
|
+
<li pgs="breadcrumbs-item">
|
|
11
|
+
<a href="/blog">Blog</a>
|
|
12
|
+
<span pgs="breadcrumbs-item-separator" aria-hidden="true">
|
|
13
|
+
>
|
|
14
|
+
</span>
|
|
15
|
+
</li>
|
|
16
|
+
|
|
17
|
+
<li pgs="breadcrumbs-item">
|
|
18
|
+
<span pgs="breadcrumbs-item-current" aria-current="page">
|
|
19
|
+
Articolo di prova
|
|
20
|
+
</span>
|
|
21
|
+
</li>
|
|
22
|
+
</ul>
|
|
23
|
+
</nav>
|
|
@@ -0,0 +1,6 @@
|
|
|
1
|
+
<nav pgs="menuHorizontal">
|
|
2
|
+
<ul id="menu-principale" class="primary-menu">
|
|
3
|
+
<li id="menu-item-1752" class="menu-item"><a href="http://" aria-current="page"><i class="fa-duotone fa-icons"></i> <span>Menu1</span></a></li>
|
|
4
|
+
<li id="menu-item-2420" class="menu-item"><a href="http://"><i class="fa-duotone fa-shop"></i> <span>Menu2</span></a></li>
|
|
5
|
+
</ul>
|
|
6
|
+
</nav>
|
|
@@ -0,0 +1,24 @@
|
|
|
1
|
+
<div pgs="modal searchbar-modal" pgs-option="containerPgs[header]">
|
|
2
|
+
|
|
3
|
+
<button type="button" pgs="modal-button buttonIcon" title="Cerca">
|
|
4
|
+
<i class="fa-solid fa-search"></i>
|
|
5
|
+
</button>
|
|
6
|
+
|
|
7
|
+
<dialog>
|
|
8
|
+
<div pgs="flexRow searchbar-mobile">
|
|
9
|
+
|
|
10
|
+
<form pgs="buttonNohover searchbar" autocomplete="off" action="/" method="get">
|
|
11
|
+
<button type="submit" title="Cerca">
|
|
12
|
+
<i class="fa-solid fa-search"></i>
|
|
13
|
+
</button>
|
|
14
|
+
|
|
15
|
+
<input type="search" name="s" placeholder="Cerca" value="">
|
|
16
|
+
</form>
|
|
17
|
+
|
|
18
|
+
<button type="button" pgs="modal-close buttonIcon">
|
|
19
|
+
<i class="fa-solid fa-close"></i>
|
|
20
|
+
</button>
|
|
21
|
+
|
|
22
|
+
</div>
|
|
23
|
+
</dialog>
|
|
24
|
+
</div>
|
|
@@ -0,0 +1,20 @@
|
|
|
1
|
+
<!DOCTYPE html>
|
|
2
|
+
<html lang="it-IT" pgs="htmlBase">
|
|
3
|
+
|
|
4
|
+
<head>
|
|
5
|
+
<meta charset="UTF-8">
|
|
6
|
+
<meta name="viewport" content="width=device-width, initial-scale=1.0">
|
|
7
|
+
|
|
8
|
+
<!-- Colori Browsers -->
|
|
9
|
+
<meta name="theme-color" content="">
|
|
10
|
+
<meta name="apple-mobile-web-app-status-bar-color" content="">
|
|
11
|
+
|
|
12
|
+
<!-- Fonts -->
|
|
13
|
+
<link rel="preconnect" href="https://fonts.googleapis.com">
|
|
14
|
+
<link rel="preconnect" href="https://fonts.gstatic.com" crossorigin>
|
|
15
|
+
<link href="https://fonts.googleapis.com/css2?family=Urbanist:ital,wght@0,100..900;1,100..900&display=swap" rel="stylesheet">
|
|
16
|
+
|
|
17
|
+
</head>
|
|
18
|
+
|
|
19
|
+
<body pgs="bodyBase bodyImg bodyText bodyHeading" >
|
|
20
|
+
|
|
@@ -0,0 +1,51 @@
|
|
|
1
|
+
<section id="pgs-cookieConsent" pgs="cookieConsent" role="dialog" aria-modal="true" data-ga-id="<?= esc_attr($ga_measurement_id); ?>" hidden tabindex="-1">
|
|
2
|
+
<p><i class="fa-duotone fa-solid fa-cookie-bite"></i> Cookie e privacy <br></p>
|
|
3
|
+
<h2>La tua privacy prima di tutto</h2>
|
|
4
|
+
|
|
5
|
+
<p>
|
|
6
|
+
Utilizziamo cookie tecnici per offrire il servizio e, previo consenso, cookie analitici di
|
|
7
|
+
<strong>Google Analytics</strong> per misurare in modo anonimo il traffico e migliorare i contenuti.
|
|
8
|
+
Puoi modificare la scelta in qualsiasi momento.
|
|
9
|
+
</p>
|
|
10
|
+
|
|
11
|
+
<p>
|
|
12
|
+
<a href="/privacy-policy/" target="_blank" rel="noopener">Privacy Policy</a> -
|
|
13
|
+
<a href="/cookie-policy/" target="_blank" rel="noopener">Cookie Policy</a>
|
|
14
|
+
</p>
|
|
15
|
+
|
|
16
|
+
<div pgs="cookieConsent-panel flexColumn" role="group" aria-label="Preferenze cookie">
|
|
17
|
+
<div pgs="flexRow nowrap cookieConsent-featureEssential">
|
|
18
|
+
<div>
|
|
19
|
+
<p>
|
|
20
|
+
<strong>Cookie tecnici</strong>
|
|
21
|
+
<br>
|
|
22
|
+
<small>Sempre attivi per garantire il corretto funzionamento del sito.</small>
|
|
23
|
+
</p>
|
|
24
|
+
</div>
|
|
25
|
+
|
|
26
|
+
<span pgs="cookieConsent-panel-badge">Attivi</span>
|
|
27
|
+
</div>
|
|
28
|
+
|
|
29
|
+
<div pgs="flexRow cookieConsent-featureAnalytics">
|
|
30
|
+
<label pgs="toggle">
|
|
31
|
+
<p>
|
|
32
|
+
<strong>Analytics</strong>
|
|
33
|
+
<br>
|
|
34
|
+
<small>Dati di navigazione raccolti in forma aggregata per statistiche anonime.</small>
|
|
35
|
+
</p>
|
|
36
|
+
|
|
37
|
+
<input type="checkbox" pgs="cookieConsent-toggleAnalytics" aria-label="Abilita Google Analytics">
|
|
38
|
+
</label>
|
|
39
|
+
</div>
|
|
40
|
+
</div>
|
|
41
|
+
|
|
42
|
+
<div pgs="flexRow">
|
|
43
|
+
<button type="button" pgs="button cookieConsent-actionReject">
|
|
44
|
+
<i class="fa-solid fa-duotone fa-sliders"></i>Solo selezionati
|
|
45
|
+
</button>
|
|
46
|
+
|
|
47
|
+
<button type="button" pgs="buttonStrong cookieConsent-actionAccept">
|
|
48
|
+
<i class="fa-solid fa-check"></i> Accetta tutto
|
|
49
|
+
</button>
|
|
50
|
+
</div>
|
|
51
|
+
</section>
|
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
<footer pgs="footer">
|
|
2
|
+
<section pgs="footer-top section">
|
|
3
|
+
<div pgs="footer-top-content flex-3">
|
|
4
|
+
<div><h2>Menu1</h2></div>
|
|
5
|
+
<div><h2>Menu2</h2></div>
|
|
6
|
+
</div>
|
|
7
|
+
</section>
|
|
8
|
+
<section pgs="footer-legal section">
|
|
9
|
+
<div pgs="footer-legal-content">
|
|
10
|
+
<p><a href="">Privacy Policy</a></p>
|
|
11
|
+
<p><a href="">Cookie Policy</a></p>
|
|
12
|
+
<p><a href="">Termini e Condizioni</a></p>
|
|
13
|
+
<p>© 2026 MyPgs. Nessun diritto riservato.</p>
|
|
14
|
+
</div>
|
|
15
|
+
</section>
|
|
16
|
+
</footer>
|
|
@@ -0,0 +1,43 @@
|
|
|
1
|
+
<header pgs="header">
|
|
2
|
+
<div pgs="header-element">
|
|
3
|
+
<div pgs="header-element-alwaysOn">
|
|
4
|
+
</div>
|
|
5
|
+
|
|
6
|
+
<div pgs="header-element-onlyDesktop">
|
|
7
|
+
</div>
|
|
8
|
+
|
|
9
|
+
<div pgs="header-element-onlyMobile">
|
|
10
|
+
</div>
|
|
11
|
+
|
|
12
|
+
<div pgs="header-element-alwaysOnLast">
|
|
13
|
+
</div>
|
|
14
|
+
|
|
15
|
+
<div pgs="header-element-hamburger modal" pgs-option="containerPGS[header] ">
|
|
16
|
+
|
|
17
|
+
<button pgs="buttonIcon modal-button modal-close header-element-hamburger-button" type="button" title="menu">
|
|
18
|
+
<span pgs="header-element-hamburger-row"></span>
|
|
19
|
+
<span pgs="header-element-hamburger-row"></span>
|
|
20
|
+
</button>
|
|
21
|
+
|
|
22
|
+
<dialog pgs="header-mobile-dialog" pgs-option="right ">
|
|
23
|
+
<div pgs="modal-dialog-content header-mobile-content">
|
|
24
|
+
</div>
|
|
25
|
+
</dialog>
|
|
26
|
+
</div>
|
|
27
|
+
</div>
|
|
28
|
+
|
|
29
|
+
<!-- //# HEADER BOTTOM -->
|
|
30
|
+
|
|
31
|
+
<script>
|
|
32
|
+
if (localStorage.getItem("screenIsDarkMode") === "true") {
|
|
33
|
+
document.body.classList.add("darkmode");
|
|
34
|
+
document.querySelector(":root").setAttribute("data-darkmode", "true");
|
|
35
|
+
document.body.setAttribute("data-darkmode", "true");
|
|
36
|
+
}
|
|
37
|
+
|
|
38
|
+
if (window.innerWidth < 600) {
|
|
39
|
+
document.querySelector("header").setAttribute("data-header-mobileActive", "true");
|
|
40
|
+
document.querySelector("[pgs~=header-element]").setAttribute("data-header-mobileActive", "true");
|
|
41
|
+
}
|
|
42
|
+
</script>
|
|
43
|
+
</header>
|