silverstripe-webpack/app/client/dist/js/app_Site.Controllers.MapElementController.js

1 line
16 KiB
JavaScript
Raw Normal View History

!function(e){var t={};function o(n){if(t[n])return t[n].exports;var a=t[n]={i:n,l:!1,exports:{}};return e[n].call(a.exports,a,a.exports,o),a.l=!0,a.exports}o.m=e,o.c=t,o.d=function(e,t,n){o.o(e,t)||Object.defineProperty(e,t,{enumerable:!0,get:n})},o.r=function(e){"undefined"!==typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})},o.t=function(e,t){if(1&t&&(e=o(e)),8&t)return e;if(4&t&&"object"===typeof e&&e&&e.__esModule)return e;var n=Object.create(null);if(o.r(n),Object.defineProperty(n,"default",{enumerable:!0,value:e}),2&t&&"string"!=typeof e)for(var a in e)o.d(n,a,function(t){return e[t]}.bind(null,a));return n},o.n=function(e){var t=e&&e.__esModule?function(){return e.default}:function(){return e};return o.d(t,"a",t),t},o.o=function(e,t){return Object.prototype.hasOwnProperty.call(e,t)},o.p="app/client/dist",o(o.s="./app/client/src/js/types/Site.Controllers.MapElementController.js")}({"./app/client/src/js/_consts.js":function(e,t,o){"use strict";var n={ENVS:["xs","sm","md","lg","xl","xxl","xxxl"],MAP_DRIVER:o("./node_modules/.pnpm/@a2nt/ss-bootstrap-ui-webpack-boilerplate@2.4.2/node_modules/@a2nt/ss-bootstrap-ui-webpack-boilerplate/src/js/_components/drivers/_map.google.js").a};t.a=n},"./app/client/src/js/types/Site.Controllers.MapElementController.js":function(e,t,o){"use strict";o.r(t);var n=o("jquery"),a=o.n(n),r=o("./node_modules/.pnpm/@a2nt/ss-bootstrap-ui-webpack-boilerplate@2.4.2/node_modules/@a2nt/ss-bootstrap-ui-webpack-boilerplate/src/js/_events.js"),i=o.n(r);o("./node_modules/.pnpm/@a2nt/ss-bootstrap-ui-webpack-boilerplate@2.4.2/node_modules/@a2nt/ss-bootstrap-ui-webpack-boilerplate/src/js/_components/_ui.map.api.js");function s(e,t){for(var o=0;o<t.length;o++){var n=t[o];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(e,n.key,n)}}var c=function(e){var t=window,o=(document,e("body")),n=function(){function t(){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,t)}var n,a,r;return n=t,r=[{key:"init",value:function(){this.dispose(),console.log("Initializing: ".concat("LocationUI"))}},{key:"initMap",value:function(){e(".mapAPI-map-container").find(".marker").on("".concat(i.a.MAPMARKERCLICK),(function(t){var n=e(t.currentTarget).data("id");o.find(".locations .location").removeClass("active"),o.find('.locations .location[data-id="'.concat(n,'"]')).addClass("active")})),o.find(".locations .location").on("click",(function(t){var n=e(t.currentTarget).data("id");o.find("#Marker".concat(n)).click()})),e(".mapAPI-map-container").on(i.a.MAPPOPUPCLOSE,(function(e){o.find(".locations .location").removeClass("active")}))}},{key:"dispose",value:function(){console.log("Destroying: ".concat("LocationUI"))}}],(a=null)&&s(n.prototype,a),r&&s(n,r),t}();return e(t).on("".concat(i.a.AJAX," ").concat(i.a.LOADED),(function(){n.init()})),e(t).on(i.a.MAPLOADED,(function(){n.initMap()})),n}(a.a);t.default=c},"./node_modules/.pnpm/@a2nt/ss-bootstrap-ui-webpack-boilerplate@2.4.2/node_modules/@a2nt/ss-bootstrap-ui-webpack-boilerplate/src/js/_components/_ui.map.api.js":function(e,t,o){"use strict";(function(e){var t=o("jquery"),n=o.n(t),a=o("./node_modules/.pnpm/@a2nt/ss-bootstrap-ui-webpack-boilerplate@2.4.2/node_modules/@a2nt/ss-bootstrap-ui-webpack-boilerplate/src/js/_events.js"),r=o.n(a),i=(o("./node_modules/.pnpm/@a2nt/ss-bootstrap-ui-webpack-boilerplate@2.4.2/node_modules/@a2nt/ss-bootstrap-ui-webpack-boilerplate/src/scss/_components/_ui.map.scss"),o("./app/client/src/js/_consts.js"));function s(e,t){for(var o=0;o<t.length;o++){var n=t[o];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(e,n.key,n)}}!function(t){var o="jsMapAPI",n=t("body"),a=i.a.MAP_DRIVER,c=window,l=function(){function i(s){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,i);var c=this,l=new a;c.$el=t(s);var p=c.$el,u=p.data();u.center=[u.lng?u.lng:n.data("default-lng"),u.lat?