{"version":3,"file":"geofencing-alert.js","sources":["../../../src/assets/scripts/geofencing-alert.entry.ts"],"sourcesContent":["import { SelectModalModel } from '@_types/_custom-event';\n\nconst geofencingAlert = {\n element: document.querySelector('.saig-o-geofencing-bar'),\n init: function () {\n var popupelement = document.querySelector('.saig-o-geofencing-popupAlert')\n if (popupelement) {\n setTimeout(this.showLocationPopup, 1000);\n }\n if (!this.element) {\n return;\n }\n this.closeAlert();\n\n },\n closeAlert: function () {\n const closeButton = this.element?.querySelector('.saig-o-geofencing-bar__close');\n\n const clickHandler = (event: any) => {\n this.element?.classList.add('d-none');\n };\n\n closeButton?.addEventListener('click', clickHandler);\n },\n showLocationPopup: function () {\n window.dispatchEvent<'selectModal'>(\n new CustomEvent('selectModal', {\n detail: {\n popUpId: 'geofencing-popup',\n selfControl: true,\n },\n })\n );\n },\n};\n\ngeofencingAlert.init();\n"],"names":["geofencingAlert","popupelement","_a","closeButton","clickHandler","event"],"mappings":"AAEA,MAAMA,EAAkB,CACtB,QAAS,SAAS,cAA2B,wBAAwB,EACrE,KAAM,UAAY,CACZ,IAAAC,EAAe,SAAS,cAA2B,+BAA+B,EAClFA,GACS,WAAA,KAAK,kBAAmB,GAAI,EAEpC,KAAK,SAGV,KAAK,WAAW,CAElB,EACA,WAAY,UAAY,CAb1B,IAAAC,EAcI,MAAMC,GAAcD,EAAA,KAAK,UAAL,YAAAA,EAAc,cAAc,iCAE1CE,EAAgBC,GAAe,CAhBzC,IAAAH,GAiBWA,EAAA,KAAA,UAAA,MAAAA,EAAS,UAAU,IAAI,SAAQ,EAGzBC,GAAA,MAAAA,EAAA,iBAAiB,QAASC,EACzC,EACA,kBAAmB,UAAY,CACtB,OAAA,cACL,IAAI,YAA8B,cAAe,CAC/C,OAAQ,CACN,QAAS,mBACT,YAAa,EACf,CAAA,CACD,CAAA,CAEL,CACF,EAEAJ,EAAgB,KAAK"}