IMPR: Minor updates

This commit is contained in:
Tony Air 2022-03-15 20:48:57 +02:00
parent 9684f37a98
commit 6db6cf0583
21 changed files with 306 additions and 219 deletions

View File

@ -1,6 +1,12 @@
---
Name: app-api-captcha
After:
- a2nt-cms-niceties-base-config
---
A2nt\CMSNiceties\Extensions\SiteMemberLoginForm:
enable_captcha: false
SilverStripe\SpamProtection\Extension\FormSpamProtectionExtension:
default_spam_protector: UndefinedOffset\NoCaptcha\Forms\NocaptchaProtector

17
app/_config/app.yml Normal file
View File

@ -0,0 +1,17 @@
---
Name: app-basics
After:
- elemental
- elemental-list
- elementalvirtual
- elemental-basics
- a2nt-cms-niceties-options-elements
- webapp-base-extensions
- webapp-locale-fluent
---
SilverStripe\CMS\Model\SiteTree:
allowed_elements: null
DNADesign\ElementalList\Model\ElementList:
allowed_elements: null

View File

@ -1,6 +1,7 @@
---
Name: webapp-locale-fluent
After:
- '#versionedfiles'
- webapp-extensions
- webapp-elemental
- webapp-locale
@ -35,9 +36,14 @@ Page:
DNADesign\Elemental\Models\ElementalArea:
extensions:
- DNADesign\Elemental\TopPage\FluentExtension
- A2nt\CMSNiceties\Extensions\ElementalArea
- A2nt\ElementalBasics\Extensions\ElementalArea
DNADesign\Elemental\Models\BaseElement:
extensions:
- DNADesign\Elemental\TopPage\FluentExtension
- A2nt\CMSNiceties\Extensions\ElementRows
- A2nt\ElementalBasics\Extensions\ElementRows
SilverStripe\SiteConfig\SiteConfig:
extensions:
- TractorCow\Fluent\Extension\FluentExtension

View File

@ -1,12 +1,7 @@
---
Name: webapp-options-elements
After:
- elemental
- elemental-list
- elementalvirtual
- elemental-basics
- a2nt-cms-niceties-options-elements
- webapp-base-extensions
- app-basics
---
Page:
searchable_elements:
@ -52,3 +47,20 @@ DNADesign\ElementalList\Model\ElementList:
styles:
whiteframe: 'White Frame'
noframe: 'No Frame'
A2nt\ElementalBasics\Extensions\ElementImageWidget:
available_heights:
'300': 'Small (300px)'
'400': 'Medium (400px)'
'600': 'Big (600px)'
available_widths:
'300': 'Small (300px)'
'400': 'Medium (400px)'
'600': 'Big (600px)'
available_ratios:
'1:1': '1:1'
'3:2': '3:2'
'2:3': '2:3'
'16:9': '16:9'

File diff suppressed because one or more lines are too long

View File

@ -1 +1 @@
#Menu-Dynamic-Elements-Admin-TestimonialsAdmin,#Menu-Dynamic-Elements-Promos-Admin-PromosAdmin,#Menu-Dynamic-Elements-Sponsors-Admin-SponsorsAdmin,#Menu-SilverStripe-CampaignAdmin-CampaignAdmin{display:none}#Form_ItemEditForm_MajorActions_Holder{border:0;margin-bottom:0;min-width:30%;padding-bottom:0}#Form_EditForm_MajorActions_Holder{border:0;margin-bottom:0;min-width:70%;padding-bottom:0}#Form_ItemEditForm_RightGroup_Holder{border:0;margin-bottom:0;min-width:20%;padding-bottom:0}.grid-field__icon-action.edit-link{opacity:1}.toolbar--south .btn-primary{color:#fff}.toolbar--south .btn-outline-primary{color:#999}#ActionMenus_MoreOptions .btn-primary{color:#5589a7}body.cms{flex-direction:column;overflow-x:hidden}.fields-compact .form-group{margin-bottom:.25rem;padding-bottom:.5rem}.fields-compact .form-group .form__field-label{font-weight:700}.fields-compact .form-group:after{margin-bottom:.25rem}.fields-compact .form-group:after,.fields-compact .form__divider:after{display:none}.fields-row{margin:0!important;padding:0 0 2em!important;width:100%}.fields-row .form__fieldgroup{display:flex;flex:0 0 100%!important;flex-wrap:wrap;margin:0!important;max-width:100%!important;padding:0!important;width:100%!important}.fields-row .form__fieldgroup>.form-group{flex:1 1 50%;margin:0!important;max-width:50%;padding:0 1rem}.notifications-list .alert .btn-close{display:none}
#Menu-Dynamic-Elements-Admin-TestimonialsAdmin,#Menu-Dynamic-Elements-Promos-Admin-PromosAdmin,#Menu-Dynamic-Elements-Sponsors-Admin-SponsorsAdmin,#Menu-SilverStripe-CampaignAdmin-CampaignAdmin{display:none}#Form_EditForm_MajorActions_Holder,#Form_ItemEditForm_MajorActions_Holder{border:0;flex:1 1;margin-bottom:0;padding-bottom:0}#Form_EditForm_MajorActions_Holder .btn,#Form_ItemEditForm_MajorActions_Holder .btn{white-space:nowrap}#Form_ItemEditForm_RightGroup,#Form_ItemEditForm_RightGroup_Holder{margin-bottom:0;padding-bottom:0}#Form_ItemEditForm_RightGroup{align-items:center;border:0;display:flex;justify-content:center}.grid-field__icon-action.edit-link{opacity:1}.grid-field__table .form-check-input.editable-column-field{margin:0!important}.toolbar--south .btn-primary{color:#fff}.toolbar--south .btn-outline-primary{color:#999}#ActionMenus_MoreOptions .btn-primary{color:#5589a7}body.cms{flex-direction:column;overflow-x:hidden}.fields-compact .form-group{margin-bottom:.25rem;padding-bottom:.5rem}.fields-compact .form-group .form__field-label{font-weight:700}.fields-compact .form-group:after{margin-bottom:.25rem}.fields-compact .form-group:after,.fields-compact .form__divider:after{display:none}.fields-row{margin:0!important;padding:0 0 2em!important;width:100%}.fields-row .form__fieldgroup{display:flex;flex:0 0 100%!important;flex-wrap:wrap;margin:0!important;max-width:100%!important;padding:0!important;width:100%!important}.fields-row .form__fieldgroup>.form-group{flex:1 1 50%;margin:0!important;max-width:50%;padding:0 1rem}.notifications-list .alert .btn-close{display:none}

View File

@ -1 +1 @@
h1.title{border-bottom:1px solid #dee2e6;display:block;line-height:1.5em;text-align:right;text-transform:uppercase}.warningMessage{background-color:#fff3cd;border:1px solid #ffeeba;border-radius:.25rem;color:#856404;margin-bottom:1rem;padding:1rem;position:relative}#Content{margin:auto;padding-left:20px;text-align:left}#Content .emailTitle{font-size:2.5rem;font-weight:400}#Content .emailTitle,#Content .PageTitle{font-family:Roboto,system-ui,-apple-system,Segoe UI,Helvetica Neue,Arial,Noto Sans,Liberation Sans,sans-serif,Apple Color Emoji,Segoe UI Emoji,Segoe UI Symbol,Noto Color Emoji}#Content .PageTitle{color:#212529;font-size:14px;padding:5px}#Content .footer td{padding:10px}#Content .footer td.right{text-align:right}#Content .typography{padding:0 10px}#Content .typography a{font-size:1em;text-decoration:underline}#Content .typography a:hover{text-decoration:none}#Content .typography ul{padding:2px 15px}#Content .typography ul li{padding:2px 5px}#Content .typography p{color:#212529;margin:.75em 0}table#SenderTable .meta,table#SenderTable .sender{width:50%}table#MetaTable{margin-left:auto}table#MetaTable .label{font-weight:700}#ShippingTable td,#ShippingTable th{width:50%}table.infotable{background:#fff;border:1px solid #dee2e6;border-collapse:collapse;margin-top:10px;width:100%}table.infotable td.product.title{color:#0d6efd;font-family:Roboto,system-ui,-apple-system,Segoe UI,Helvetica Neue,Arial,Noto Sans,Liberation Sans,sans-serif,Apple Color Emoji,Segoe UI Emoji,Segoe UI Symbol,Noto Color Emoji;font-size:1.75rem;font-weight:400}table.infotable tr td,table.infotable tr th{border:1px solid #dee2e6;color:#212529;padding:5px}table.infotable td{vertical-align:middle}table.infotable tr.summary{font-weight:700}table.infotable td.ordersummary{border-bottom:1px solid #dee2e6;font-size:1em}table.infotable tr th{font-weight:700}table.infotable tr td a{color:#0d6efd;text-decoration:underline}table.infotable tr td a:hover{text-decoration:none}table.infotable .modifierRow,table.infotable .right,table.infotable .threeColHeader{text-align:right}table.infotable .center{text-align:center}table.infotable .left,table.infotable th{text-align:left}
h1.title{border-bottom:1px solid #dee2e6;display:block;line-height:1.5em;text-align:right;text-transform:uppercase}.warningMessage{background-color:#fff3cd;border:1px solid #ffeeba;border-radius:.25rem;color:#856404;margin-bottom:1rem;padding:1rem;position:relative}#Content{margin:auto;padding-left:20px;text-align:left}#Content .emailTitle{font-size:2.5rem;font-weight:400}#Content .PageTitle,#Content .emailTitle{font-family:Roboto,system-ui,-apple-system,Segoe UI,Helvetica Neue,Arial,Noto Sans,Liberation Sans,sans-serif,Apple Color Emoji,Segoe UI Emoji,Segoe UI Symbol,Noto Color Emoji}#Content .PageTitle{color:#212529;font-size:14px;padding:5px}#Content .footer td{padding:10px}#Content .footer td.right{text-align:right}#Content .typography{padding:0 10px}#Content .typography a{font-size:1em;text-decoration:underline}#Content .typography a:hover{text-decoration:none}#Content .typography ul{padding:2px 15px}#Content .typography ul li{padding:2px 5px}#Content .typography p{color:#212529;margin:.75em 0}table#SenderTable .meta,table#SenderTable .sender{width:50%}table#MetaTable{margin-left:auto}table#MetaTable .label{font-weight:700}#ShippingTable td,#ShippingTable th{width:50%}table.infotable{background:#fff;border:1px solid #dee2e6;border-collapse:collapse;margin-top:10px;width:100%}table.infotable td.product.title{color:#0d6efd;font-family:Roboto,system-ui,-apple-system,Segoe UI,Helvetica Neue,Arial,Noto Sans,Liberation Sans,sans-serif,Apple Color Emoji,Segoe UI Emoji,Segoe UI Symbol,Noto Color Emoji;font-size:1.75rem;font-weight:400}table.infotable tr td,table.infotable tr th{border:1px solid #dee2e6;color:#212529;padding:5px}table.infotable td{vertical-align:middle}table.infotable tr.summary{font-weight:700}table.infotable td.ordersummary{border-bottom:1px solid #dee2e6;font-size:1em}table.infotable tr th{font-weight:700}table.infotable tr td a{color:#0d6efd;text-decoration:underline}table.infotable tr td a:hover{text-decoration:none}table.infotable .modifierRow,table.infotable .right,table.infotable .threeColHeader{text-align:right}table.infotable .center{text-align:center}table.infotable .left,table.infotable th{text-align:left}

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

View File

@ -1 +1,2 @@
!function(){var t={8545:function(t){function _typeof(t){return _typeof="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},_typeof(t)}function DBSCAN(t,r,o,i){this.dataset=[],this.epsilon=1,this.minPts=2,this.distance=this._euclideanDistance,this.clusters=[],this.noise=[],this._visited=[],this._assigned=[],this._datasetLength=0,this._init(t,r,o,i)}DBSCAN.prototype.run=function(t,r,o,i){this._init(t,r,o,i);for(var a=0;a<this._datasetLength;a++)if(1!==this._visited[a]){this._visited[a]=1;var u=this._regionQuery(a);if(u.length<this.minPts)this.noise.push(a);else{var c=this.clusters.length;this.clusters.push([]),this._addToCluster(a,c),this._expandCluster(c,u)}}return this.clusters},DBSCAN.prototype._init=function(t,r,o,i){if(t){if(!(t instanceof Array))throw Error("Dataset must be of type array, "+_typeof(t)+" given");this.dataset=t,this.clusters=[],this.noise=[],this._datasetLength=t.length,this._visited=new Array(this._datasetLength),this._assigned=new Array(this._datasetLength)}r&&(this.epsilon=r),o&&(this.minPts=o),i&&(this.distance=i)},DBSCAN.prototype._expandCluster=function(t,r){for(var o=0;o<r.length;o++){var i=r[o];if(1!==this._visited[i]){this._visited[i]=1;var a=this._regionQuery(i);a.length>=this.minPts&&(r=this._mergeArrays(r,a))}1!==this._assigned[i]&&this._addToCluster(i,t)}},DBSCAN.prototype._addToCluster=function(t,r){this.clusters[r].push(t),this._assigned[t]=1},DBSCAN.prototype._regionQuery=function(t){for(var r=[],o=0;o<this._datasetLength;o++){this.distance(this.dataset[t],this.dataset[o])<this.epsilon&&r.push(o)}return r},DBSCAN.prototype._mergeArrays=function(t,r){for(var o=r.length,i=0;i<o;i++){var a=r[i];t.indexOf(a)<0&&t.push(a)}return t},DBSCAN.prototype._euclideanDistance=function(t,r){for(var o=0,i=Math.min(t.length,r.length);i--;)o+=(t[i]-r[i])*(t[i]-r[i]);return Math.sqrt(o)},t.exports&&(t.exports=DBSCAN)},1361:function(t){function KMEANS(t,r,o){this.k=3,this.dataset=[],this.assignments=[],this.centroids=[],this.init(t,r,o)}KMEANS.prototype.init=function(t,r,o){this.assignments=[],this.centroids=[],"undefined"!==typeof t&&(this.dataset=t),"undefined"!==typeof r&&(this.k=r),"undefined"!==typeof o&&(this.distance=o)},KMEANS.prototype.run=function(t,r){this.init(t,r);for(var o=this.dataset.length,i=0;i<this.k;i++)this.centroids[i]=this.randomCentroid();for(var a=!0;a;){a=this.assign();for(var u=0;u<this.k;u++){for(var c=new Array(h),l=0,p=0;p<h;p++)c[p]=0;for(var d=0;d<o;d++){var h=this.dataset[d].length;if(u===this.assignments[d]){for(p=0;p<h;p++)c[p]+=this.dataset[d][p];l++}}if(l>0){for(p=0;p<h;p++)c[p]/=l;this.centroids[u]=c}else this.centroids[u]=this.randomCentroid(),a=!0}}return this.getClusters()},KMEANS.prototype.randomCentroid=function(){var t,r,o=this.dataset.length-1;do{r=Math.round(Math.random()*o),t=this.dataset[r]}while(this.centroids.indexOf(t)>=0);return t},KMEANS.prototype.assign=function(){for(var t,r=!1,o=this.dataset.length,i=0;i<o;i++)(t=this.argmin(this.dataset[i],this.centroids,this.distance))!=this.assignments[i]&&(this.assignments[i]=t,r=!0);return r},KMEANS.prototype.getClusters=function(){for(var t,r=new Array(this.k),o=0;o<this.assignments.length;o++)"undefined"===typeof r[t=this.assignments[o]]&&(r[t]=[]),r[t].push(o);return r},KMEANS.prototype.argmin=function(t,r,o){for(var i,a=Number.MAX_VALUE,u=0,c=r.length,l=0;l<c;l++)(i=o(t,r[l]))<a&&(a=i,u=l);return u},KMEANS.prototype.distance=function(t,r){for(var o=0,i=Math.min(t.length,r.length);i--;){var a=t[i]-r[i];o+=a*a}return Math.sqrt(o)},t.exports&&(t.exports=KMEANS)},1402:function(t,r,o){function _typeof(t){return _typeof="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},_typeof(t)}if(t.exports)var i=o(3162);function OPTICS(t,r,o,i){this.epsilon=1,this.minPts=1,this.distance=this._euclideanDistance,this._reachability=[],this._processed=[],this._coreDistance=0,this._orderedList=[],this._init(t,r,o,i)}OPTICS.prototype.run=function(t,r,o,a){this._init(t,r,o,a);for(var u=0,c=this.dataset.length;u<c;u++)if(1!==this._processed[u]){this._processed[u]=1,this.clusters.push([u]);var l=this.clusters.length-1;this._orderedList.push(u);var p=new i(null,null,"asc"),d=this._regionQuery(u);void 0!==this._distanceToCore(u)&&(this._updateQueue(u,d,p),this._expandCluster(l,p))}return this.clusters},OPTICS.prototype.getReachabilityPlot=function(){for(var t=[],r=0,o=this._orderedList.length;r<o;r++){var i=this._orderedList[r],a=this._reachability[i];t.push([i,a])}return t},OPTICS.prototype._init=function(t,r,o,i){if(t){if(!(t instanceof Array))throw Error("Dataset must be of type array, "+_typeof(t)+" given");this.dataset=t,this.clusters=[],this._reachability=new Array(this.dataset.length),this._processed=new Array(this.dataset.length),this._coreDistance=0,this._orderedList=[]}r&&(this.epsilon=r),o&&(this.minPts=o),i&&(this.distance=i)},OPTICS.prototype._updateQueue=function(t,r,o){var i=this;this._coreDistance=this._distanceToCore(t),r.forEach((function(r){if(void 0===i._processed[r]){var a=i.distance(i.dataset[t],i.dataset[r]),u=Math.max(i._coreDistance,a);void 0===i._reachability[r]?(i._reachability[r]=u,o.insert(r,u)):u<i._reachability[r]&&(i._reachability[r]=u,o.remove(r),o.insert(r,u))}}))},OPTICS.prototype._expandCluster=function(t,r){for(var o=r.getElements(),i=0,a=o.length;i<a;i++){var u=o[i];if(void 0===this._processed[u]){var c=this._regionQuery(u);this._processed[u]=1,this.clusters[t].push(u),this._orderedList.push(u),void 0!==this._distanceToCore(u)&&(this._updateQueue(u,c,r),this._expandCluster(t,r))}}},OPTICS.prototype._distanceToCore=function(t){for(var r=this.epsilon,o=0;o<r;o++){if(this._regionQuery(t,o).length>=this.minPts)return o}},OPTICS.prototype._regionQuery=function(t,r){r=r||this.epsilon;for(var o=[],i=0,a=this.dataset.length;i<a;i++)this.distance(this.dataset[t],this.dataset[i])<r&&o.push(i);return o},OPTICS.prototype._euclideanDistance=function(t,r){for(var o=0,i=Math.min(t.length,r.length);i--;)o+=(t[i]-r[i])*(t[i]-r[i]);return Math.sqrt(o)},t.exports&&(t.exports=OPTICS)},3162:function(t){function PriorityQueue(t,r,o){this._queue=[],this._priorities=[],this._sorting="desc",this._init(t,r,o)}PriorityQueue.prototype.insert=function(t,r){for(var o=this._queue.length,i=o;i--;){var a=this._priorities[i];"desc"===this._sorting?r>a&&(o=i):r<a&&(o=i)}this._insertAt(t,r,o)},PriorityQueue.prototype.remove=function(t){for(var r=this._queue.length;r--;){if(t===this._queue[r]){this._queue.splice(r,1),this._priorities.splice(r,1);break}}},PriorityQueue.prototype.forEach=function(t){this._queue.forEach(t)},PriorityQueue.prototype.getElements=function(){return this._queue},PriorityQueue.prototype.getElementPriority=function(t){return this._priorities[t]},PriorityQueue.prototype.getPriorities=function(){return this._priorities},PriorityQueue.prototype.getElementsWithPriorities=function(){for(var t=[],r=0,o=this._queue.length;r<o;r++)t.push([this._queue[r],this._priorities[r]]);return t},PriorityQueue.prototype._init=function(t,r,o){if(t&&r){if(this._queue=[],this._priorities=[],t.length!==r.length)throw new Error("Arrays must have the same length");for(var i=0;i<t.length;i++)this.insert(t[i],r[i])}o&&(this._sorting=o)},PriorityQueue.prototype._insertAt=function(t,r,o){this._queue.length===o?(this._queue.push(t),this._priorities.push(r)):(this._queue.splice(o,0,t),this._priorities.splice(o,0,r))},t.exports&&(t.exports=PriorityQueue)},7776:function(t,r,o){t.exports&&(t.exports={DBSCAN:o(8545),KMEANS:o(1361),OPTICS:o(1402),PriorityQueue:o(3162)})},9978:function(t){"use strict";function _createForOfIteratorHelper(t,r){var o="undefined"!==typeof Symbol&&t[Symbol.iterator]||t["@@iterator"];if(!o){if(Array.isArray(t)||(o=function _unsupportedIterableToArray(t,r){if(!t)return;if("string"===typeof t)return _arrayLikeToArray(t,r);var o=Object.prototype.toString.call(t).slice(8,-1);"Object"===o&&t.constructor&&(o=t.constructor.name);if("Map"===o||"Set"===o)return Array.from(t);if("Arguments"===o||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(o))return _arrayLikeToArray(t,r)}(t))||r&&t&&"number"===typeof t.length){o&&(t=o);var i=0,a=function F(){};return{s:a,n:function n(){return i>=t.length?{done:!0}:{done:!1,value:t[i++]}},e:function e(t){throw t},f:a}}throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}var u,c=!0,l=!1;return{s:function s(){o=o.call(t)},n:function n(){var t=o.next();return c=t.done,t},e:function e(t){l=!0,u=t},f:function f(){try{c||null==o.return||o.return()}finally{if(l)throw u}}}}function _arrayLikeToArray(t,r){(null==r||r>t.length)&&(r=t.length);for(var o=0,i=new Array(r);o<r;o++)i[o]=t[o];return i}function _typeof(t){return _typeof="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},_typeof(t)}t.exports=function equal(t,r){if(t===r)return!0;if(t&&r&&"object"==_typeof(t)&&"object"==_typeof(r)){if(t.constructor!==r.constructor)return!1;var o,i,a;if(Array.isArray(t)){if((o=t.length)!=r.length)return!1;for(i=o;0!==i--;)if(!equal(t[i],r[i]))return!1;return!0}if(t instanceof Map&&r instanceof Map){if(t.size!==r.size)return!1;var u,c=_createForOfIteratorHelper(t.entries());try{for(c.s();!(u=c.n()).done;)if(i=u.value,!r.has(i[0]))return!1}catch(y){c.e(y)}finally{c.f()}var l,p=_createForOfIteratorHelper(t.entries());try{for(p.s();!(l=p.n()).done;)if(!equal((i=l.value)[1],r.get(i[0])))return!1}catch(y){p.e(y)}finally{p.f()}return!0}if(t instanceof Set&&r instanceof Set){if(t.size!==r.size)return!1;var d,h=_createForOfIteratorHelper(t.entries());try{for(h.s();!(d=h.n()).done;)if(i=d.value,!r.has(i[0]))return!1}catch(y){h.e(y)}finally{h.f()}return!0}if(ArrayBuffer.isView(t)&&ArrayBuffer.isView(r)){if((o=t.length)!=r.length)return!1;for(i=o;0!==i--;)if(t[i]!==r[i])return!1;return!0}if(t.constructor===RegExp)return t.source===r.source&&t.flags===r.flags;if(t.valueOf!==Object.prototype.valueOf)return t.valueOf()===r.valueOf();if(t.toString!==Object.prototype.toString)return t.toString()===r.toString();if((o=(a=Object.keys(t)).length)!==Object.keys(r).length)return!1;for(i=o;0!==i--;)if(!Object.prototype.hasOwnProperty.call(r,a[i]))return!1;for(i=o;0!==i--;){var g=a[i];if(!equal(t[g],r[g]))return!1}return!0}return t!==t&&r!==r}},1639:function(t){"use strict";t.exports={eudist:function eudist(t,r){for(var o=t.length,i=0,a=0;a<o;a++){var u=(t[a]||0)-(r[a]||0);i+=u*u}return i},mandist:function mandist(t,r){for(var o=t.length,i=0,a=0,u=0;u<o;u++)i+=(a=(t[u]||0)-(r[u]||0))>=0?a:-a;return i},dist:function dist(t,r,o){var i=Math.abs(t-r);return o?i:i*i}}},8662:function(t,r,o){"use strict";var i=o(1639),a=i.eudist,u=i.dist;t.exports={kmrand:function kmrand(t,r){for(var o={},i=[],a=r<<2,u=t.length,c=t[0].length>0;i.length<r&&a-- >0;){var l=t[Math.floor(Math.random()*u)],p=c?l.join("_"):"".concat(l);o[p]||(o[p]=!0,i.push(l))}if(i.length<r)throw new Error("Error initializating clusters");return i},kmpp:function kmpp(t,r,o){var i=o||(t[0].length?a:u),c=[],l=t.length,p=t[0].length>0,d=t[Math.floor(Math.random()*l)];p?d.join("_"):"".concat(d);for(c.push(d);c.length<r;){for(var h=[],g=c.length,y=0,m=[],v=0;v<l;v++){for(var _=1/0,b=0;b<g;b++){var k=i(t[v],c[b]);k<=_&&(_=k)}h[v]=_}for(var P=0;P<l;P++)y+=h[P];for(var M=0;M<l;M++)m[M]={i:M,v:t[M],pr:h[M]/y,cs:0};m.sort((function(t,r){return t.pr-r.pr})),m[0].cs=m[0].pr;for(var w=1;w<l;w++)m[w].cs=m[w-1].cs+m[w].pr;for(var S=Math.random(),C=0;C<l-1&&m[C++].cs<S;);c.push(m[C-1].v)}return c}}},3106:function(t,r,o){"use strict";var i=o(1639),a=o(8662),u=i.eudist,c=(i.mandist,i.dist,a.kmrand),l=a.kmpp;function init(t,r,o){o=o||[];for(var i=0;i<t;i++)o[i]=r;return o}function test(t,r){for(var o=Array.isArray(t),i=this.centroids,a=i.length,c=1/0,l=0,p=0;p<a;p++){var d=r?r(t,i[p]):o?u(t,i[p]):Math.abs(t-i[p]);d<=c&&(c=d,l=p)}return{idx:l,centroid:i[l]}}t.exports=function skmeans(t,r,o,i,a){var p=[],d=[],h=[],g=[],y=!1,m=i||1e4,v=t.length,_=t[0].length,b=_>0,k=[];if(o)p="kmrand"==o?c(t,r):"kmpp"==o?l(t,r,a):o;else for(var P={},M=0;p.length<r;){var w=Math.floor(Math.random()*v);P[w]||(P[w]=!0,p[M++]=t[w])}do{init(r,0,k);for(var S=0;S<v;S++){for(var C=1/0,x=0,O=0;O<r;O++){(g=a?a(t[S],p[O]):b?u(t[S],p[O]):Math.abs(t[S]-p[O]))<=C&&(C=g,x=O)}h[S]=x,k[x]++}var A=[];d=[];if(b)for(var E=0;E<r;E++)A[E]=init(_,0,A[E]),d[E]=p[E];else for(var T=0;T<r;T++)A[T]=0,d[T]=p[T];if(b){for(var D=0;D<r;D++)p[D]=[];for(var L=0;L<v;L++)for(var N=A[h[L]],I=t[L],j=0;j<_;j++)N[j]+=I[j];y=!0;for(var q=0;q<r;q++){for(var B=p[q],G=A[q],Q=d[q],R=k[q],H=0;H<_;H++)B[H]=G[H]/R||0;if(y)for(var z=0;z<_;z++)if(Q[z]!=B[z]){y=!1;break}}}else{for(var K=0;K<v;K++){A[h[K]]+=t[K]}for(var U=0;U<r;U++)p[U]=A[U]/k[U]||0;y=!0;for(var Z=0;Z<r;Z++)if(d[Z]!=p[Z]){y=!1;break}}y=y||--m<=0}while(!y);return{it:(i||1e4)-m,k:r,idxs:h,centroids:p,test:test}}}},r={};function __webpack_require__(o){var i=r[o];if(void 0!==i)return i.exports;var a=r[o]={exports:{}};return t[o](a,a.exports,__webpack_require__),a.exports}__webpack_require__.r=function(t){"undefined"!==typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(t,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(t,"__esModule",{value:!0})},function(){"use strict";var t={};__webpack_require__.r(t);var r="ajax-load",o="load-ready",i="map-loaded",a="map-api-loaded",u="map-marker-click",c="map-popup-close";__webpack_require__(3106);__webpack_require__(7776);var l;Math.fround||(l=new Float32Array(1));__webpack_require__(9978);var p;!function(t){t.CLUSTERING_BEGIN="clusteringbegin",t.CLUSTERING_END="clusteringend",t.CLUSTER_CLICK="click"}(p||(p={}));function map_google_marker_typeof(t){return map_google_marker_typeof="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},map_google_marker_typeof(t)}function map_google_marker_defineProperties(t,r){for(var o=0;o<r.length;o++){var i=r[o];i.enumerable=i.enumerable||!1,i.configurable=!0,"value"in i&&(i.writable=!0),Object.defineProperty(t,i.key,i)}}function map_google_marker_setPrototypeOf(t,r){return map_google_marker_setPrototypeOf=Object.setPrototypeOf||function _setPrototypeOf(t,r){return t.__proto__=r,t},map_google_marker_setPrototypeOf(t,r)}function map_google_marker_createSuper(t){var r=function map_google_marker_isNativeReflectConstruct(){if("undefined"===typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"===typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(t){return!1}}();return function _createSuperInternal(){var o,i=map_google_marker_getPrototypeOf(t);if(r){var a=map_google_marker_getPrototypeOf(this).constructor;o=Reflect.construct(i,arguments,a)}else o=i.apply(this,arguments);return map_google_marker_possibleConstructorReturn(this,o)}}function map_google_marker_possibleConstructorReturn(t,r){if(r&&("object"===map_google_marker_typeof(r)||"function"===typeof r))return r;if(void 0!==r)throw new TypeError("Derived constructors may only return object or undefined");return map_google_marker_assertThisInitialized(t)}function map_google_marker_assertThisInitialized(t){if(void 0===t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return t}function map_google_marker_getPrototypeOf(t){return map_google_marker_getPrototypeOf=Object.setPrototypeOf?Object.getPrototypeOf:function _getPrototypeOf(t){return t.__proto__||Object.getPrototypeOf(t)},map_google_marker_getPrototypeOf(t)}var d={init:function init(){return function(t){!function map_google_marker_inherits(t,r){if("function"!==typeof r&&null!==r)throw new TypeError("Super expression must either be null or a function");t.prototype=Object.create(r&&r.prototype,{constructor:{value:t,writable:!0,configurable:!0}}),Object.defineProperty(t,"prototype",{writable:!1}),r&&map_google_marker_setPrototypeOf(t,r)}(GoogleMapsHtmlOverlay,google.maps.OverlayView);var r=map_google_marker_createSuper(GoogleMapsHtmlOverlay);function GoogleMapsHtmlOverlay(t){var o;!function map_google_marker_classCallCheck(t,r){if(!(t instanceof r))throw new TypeError("Cannot call a class as a function")}(this,GoogleMapsHtmlOverlay);var i=map_google_marker_assertThisInitialized(o=r.call(this));return i.ownerMap=t.map,i.position=t.position,i.html=t.html?t.html:'<div class="mapboxgl-marker"><i class="marker-icon fas fa-map-marker-alt"></i></div>',i.divClass=t.divClass,i.align=t.align,i.isDebugMode=t.debug,i.onClick=t.onClick,i.onMouseOver=t.onMouseOver,i.isBoolean=function(t){return"boolean"===typeof t},i.isNotUndefined=function(t){return"undefined"!==typeof t},i.hasContent=function(t){return t.length>0},i.isString=function(t){return"string"===typeof t},i.isFunction=function(t){return"function"===typeof t},o}return function map_google_marker_createClass(t,r,o){return r&&map_google_marker_defineProperties(t.prototype,r),o&&map_google_marker_defineProperties(t,o),Object.defineProperty(t,"prototype",{writable:!1}),t}(GoogleMapsHtmlOverlay,[{key:"onAdd",value:function onAdd(){var t=this;t.div=document.createElement("div"),t.div.style.position="absolute",t.isNotUndefined(t.divClass)&&t.hasContent(t.divClass)&&(t.div.className=t.divClass),t.isNotUndefined(t.html)&&t.hasContent(t.html)&&t.isString(t.html)&&(t.div.innerHTML=t.html),t.isBoolean(t.isDebugMode)&&t.isDebugMode&&(t.div.className="debug-mode",t.div.innerHTML='<div style="height: 10px; width: 10px; background: red; border-radius: 100%;"></div><div style="position: absolute; top: 5px; padding: 5px; width: 130px; text-align: center; font-size: 18px; text-transform: uppercase; font-weight: bolder; background: red; color: white; font-family: Arial;">Debug mode</div>',t.div.setAttribute("style","position: absolute;border: 5px dashed red;height: 150px;width: 150px;display: flex;justify-content: center;align-items: center;")),t.getPanes().overlayMouseTarget.appendChild(t.div),google.maps.event.addDomListener(t.div,"click",(function(r){google.maps.event.trigger(t,"click"),t.isFunction(t.onClick)&&t.onClick(),r.stopPropagation()})),google.maps.event.addDomListener(t.div,"mouseover",(function(r){google.maps.event.trigger(t,"mouseover"),t.isFunction(t.onMouseOver)&&t.onMouseOver(),r.stopPropagation()}))}},{key:"draw",value:function draw(){var t=this,r=document.querySelector(".popup");r.length||(r=t.div);var o=t.getProjection();if(!o)return console.log("GoogleMapsHtmlOverlay: current map is missing"),null;var i=o.fromLatLngToDivPixel(t.getPosition()),a={y:void 0,x:void 0},u=r.offsetWidth,c=r.offsetHeight;switch(Array.isArray(t.align)?t.align.join(" "):""){case"left top":a.y=c,a.x=u;break;case"left center":a.y=c/2,a.x=u;break;case"left bottom":a.y=0,a.x=u;break;case"center top":a.y=c,a.x=u/2;break;case"center center":default:a.y=c/2,a.x=u/2;break;case"center bottom":a.y=0,a.x=u/2;break;case"right top":a.y=c,a.x=0;break;case"right center":a.y=c/2,a.x=0;break;case"right bottom":a.y=0,a.x=0}t.div.style.top="".concat(i.y-a.y,"px"),t.div.style.left="".concat(i.x-a.x,"px")}},{key:"getPosition",value:function getPosition(){return new google.maps.LatLng(this.position)}},{key:"getDiv",value:function getDiv(){return this.div}},{key:"setPosition",value:function setPosition(t,r){var o=this;o.position=t,o.align=r,o.draw()}},{key:"remove",value:function remove(){this.setMap(null),this.div.remove()}},{key:"getDraggable",value:function getDraggable(){return!1}}]),GoogleMapsHtmlOverlay}()}};function map_google_defineProperties(t,r){for(var o=0;o<r.length;o++){var i=r[o];i.enumerable=i.enumerable||!1,i.configurable=!0,"value"in i&&(i.writable=!0),Object.defineProperty(t,i.key,i)}}var h=function(r){var o=function(){function GoogleMapsDriver(){!function map_google_classCallCheck(t,r){if(!(t instanceof r))throw new TypeError("Cannot call a class as a function")}(this,GoogleMapsDriver)}return function map_google_createClass(t,r,o){return r&&map_google_defineProperties(t.prototype,r),o&&map_google_defineProperties(t,o),Object.defineProperty(t,"prototype",{writable:!1}),t}(GoogleMapsDriver,[{key:"getName",value:function getName(){return"GoogleMapsDriver"}},{key:"init",value:function init(t){var o=arguments.length>1&&void 0!==arguments[1]?arguments[1]:[],i=this;i.el=t,i.config=o,i.markers=[],r["init".concat(i.getName())]=function(){i.googleApiLoaded()};var a=document.createElement("script");a.src="https://maps.googleapis.com/maps/api/js?key=".concat(o.key,"&callback=init").concat(i.getName()),a.async=!0,a.defer=!0,document.head.appendChild(a)}},{key:"googleApiLoaded",value:function googleApiLoaded(){var r=this,o=r.el,i=r.config,u=o.querySelector(".mapAPI-map"),c=i.mapZoom&&"0"!==i.mapZoom?parseInt(i.mapZoom):10,l=i.center&&","!==i.center?{lat:i.center[1],lng:i.center[0]}:{lat:0,lng:0},p=i.style?i.style:null;console.log("".concat(r.getName(),": API is loaded")),r.MarkerUI=d.init(),r.map=new google.maps.Map(u,{zoom:c,center:l,fullscreenControl:!0,styles:p}),r.default_zoom=c,u.classList.add("mapboxgl-map"),r.popup=new r.MarkerUI({map:r.map,align:["center","top"],divClass:"mapboxgl-popup popup mapboxgl-popup-anchor-bottom d-none",html:'<div class="mapboxgl-popup-tip"></div><div class="mapboxgl-popup-content"><div class="mapboxgl-popup-close-button" type="button" aria-label="Close popup">\xd7</div><div class="html"></div></div>'}),r.popup.setMap(r.map),r.geocoder=new google.maps.Geocoder,r.cluster=new t.default(r.map,null,{styles:[{width:30,height:30,className:"mapboxgl-cluster"}]}),o.dispatchEvent(new Event(a))}},{key:"addMarker",value:function addMarker(t,r){var o=this,i={lat:t[1],lng:t[0]},a=new o.MarkerUI({position:i,map:o.map,align:["center","top"],html:'<div class="mapboxgl-marker"><div id="Marker'.concat(r.id,'" data-id="').concat(r.id,'" class="marker">').concat(r.icon,"</div></div>"),onClick:function onClick(){var t=document.querySelector("#Marker".concat(r.id));o.showPopup(i,r.content),t.dispatchEvent(new Event(u))}});return o.markers.push(a),o.cluster.addMarker(a),a}},{key:"showPopup",value:function showPopup(t,r){var o=this,i=o.popup.getDiv();o.config.flyToMarker&&(o.map.setCenter(t),o.config.noZoom||o.map.setZoom(18)),i.style.opacity="0",i.classList.remove("d-none"),i.querySelector(".mapboxgl-popup-content .html").innerHTML=r,i.querySelector(".mapboxgl-popup-close-button").addEventListener("click",(function(t){t.preventDefault(),o.hidePopup()})),o.popup.setPosition(t,["center","top"]),i.style.opacity="1",i.style["margin-top"]="-1rem"}},{key:"hidePopup",value:function hidePopup(){var t=this;t.popup.getDiv().classList.add("d-none"),t.config.noRestoreBounds&&!t.config.flyToBounds||t.restoreBounds(),t.el.dispatchEvent(new Event(c))}},{key:"geocode",value:function geocode(t,r){var o=this;o.geocoder.geocode({address:t},(function(t,i){if("OK"===i)return"function"===typeof r&&r(t),t;console.error("".concat(o.getName(),": Geocode was not successful for the following reason: ").concat(i))}))}},{key:"reverseGeocode",value:function reverseGeocode(t,r){var o=this;o.geocoder.geocode({location:latlng},(function(t,i){if("OK"===i)return"function"===typeof r&&r(t),t;console.error("".concat(o.getName(),": Reverse Geocoding was not successful for the following reason: ").concat(i))}))}},{key:"addGeoJson",value:function addGeoJson(t){var r=this,o=JSON.parse(t.geojson),i=(o.features[0].geometry.coordinates,new google.maps.LatLngBounds);o.features.forEach((function(o){var a=o.id,u=o.geometry.coordinates,c=o.properties.content;r.addMarker(u,{id:a,content:c,icon:o.icon,flyToMarker:t.flyToMarker}),i.extend({lat:u[1],lng:u[0]})})),r.markers.length>1?r.map.fitBounds(i,{padding:30}):r.markers[0]&&r.map.setCenter(r.markers[0].getPosition()),r.default_bounds=i,r.default_zoom=r.map.getZoom()}},{key:"getMap",value:function getMap(){return this.map}},{key:"getPopup",value:function getPopup(){return this.popup}},{key:"restoreBounds",value:function restoreBounds(){var t=this;t.default_bounds&&t.markers.length>1?t.map.fitBounds(t.default_bounds,{padding:30}):(t.markers[0]&&t.map.setCenter(t.markers[0].getPosition()),t.restoreZoom())}},{key:"restoreZoom",value:function restoreZoom(){this.map.setZoom(this.default_zoom)}}]),GoogleMapsDriver}();return o}(window),g={ENVS:["xs","sm","md","lg","xl","xxl","xxxl"],MAP_DRIVER:h};function map_api_defineProperties(t,r){for(var o=0;o<r.length;o++){var i=r[o];i.enumerable=i.enumerable||!1,i.configurable=!0,"value"in i&&(i.writable=!0),Object.defineProperty(t,i.key,i)}}!function(t){var u="js-mapapi",c=g.MAP_DRIVER,l=function(){function MapAPI(t){!function map_api_classCallCheck(t,r){if(!(t instanceof r))throw new TypeError("Cannot call a class as a function")}(this,MapAPI);var r=this,o=new c,i=document.querySelector("body"),l=t.dataset;l.center=[l.lng?l.lng:i.dataset["default-lng"],l.lat?l.lat:i.dataset["default-lat"]],l.icon||(l.icon='<i class="fas fa-map-marker-alt"></i>'),console.log("".concat(u,": init ").concat(o.getName(),"...")),r.drv=o,r.el=t,r.config=l,o.init(t,l),t.addEventListener(a,(function(){r.addMarkers()}))}return function map_api_createClass(t,r,o){return r&&map_api_defineProperties(t.prototype,r),o&&map_api_defineProperties(t,o),Object.defineProperty(t,"prototype",{writable:!1}),t}(MapAPI,[{key:"getMap",value:function getMap(){return ui.map}},{key:"dispose",value:function dispose(){this.el=null,this.el.classList.remove("".concat(u,"-active"))}},{key:"addMarkers",value:function addMarkers(){console.log("".concat(u,": addMarkers"));var t=this,r=t.el,o=t.drv,a=t.config;if(t.map=o.getMap(),a.geojson)console.log("".concat(u,": setting up geocode data")),o.addGeoJson(a);else if(a.address)console.log(a.address),console.log("".concat(u,": setting up address marker")),o.geocode(a.address,(function(r){console.log(r);var i=r[0].geometry.location.lat(),c=r[0].geometry.location.lng();console.log("".concat(u,": setting up single lat/lng marker lat: ").concat(i," lng: ").concat(c)),o.addMarker([c,i],a),t.map.setCenter({lat:i,lng:c})}));else if(a.lat&&a.lng){var c=a.lat,l=a.lng;console.log("".concat(u,": setting up single lat/lng marker lat: ").concat(c," lng: ").concat(l)),o.addMarker([l,c],a)}r.classList.add("".concat(u,"-active")),r.dispatchEvent(new Event(i)),console.log("".concat(u,": Map is loaded"))}}]),MapAPI}(),p=function init(){console.log("".concat(u,": init")),document.querySelectorAll(".".concat(u)).forEach((function(t,r){new l(t)}))};t.addEventListener("".concat(o),p),t.addEventListener("".concat(r),p)}(window)}()}();
/*! For license information please see app_Site.Controllers.MapElementController.js.LICENSE.txt */
!function(){var t={4283:function(t){function _typeof(t){return _typeof="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},_typeof(t)}function DBSCAN(t,r,o,i){this.dataset=[],this.epsilon=1,this.minPts=2,this.distance=this._euclideanDistance,this.clusters=[],this.noise=[],this._visited=[],this._assigned=[],this._datasetLength=0,this._init(t,r,o,i)}DBSCAN.prototype.run=function(t,r,o,i){this._init(t,r,o,i);for(var a=0;a<this._datasetLength;a++)if(1!==this._visited[a]){this._visited[a]=1;var u=this._regionQuery(a);if(u.length<this.minPts)this.noise.push(a);else{var l=this.clusters.length;this.clusters.push([]),this._addToCluster(a,l),this._expandCluster(l,u)}}return this.clusters},DBSCAN.prototype._init=function(t,r,o,i){if(t){if(!(t instanceof Array))throw Error("Dataset must be of type array, "+_typeof(t)+" given");this.dataset=t,this.clusters=[],this.noise=[],this._datasetLength=t.length,this._visited=new Array(this._datasetLength),this._assigned=new Array(this._datasetLength)}r&&(this.epsilon=r),o&&(this.minPts=o),i&&(this.distance=i)},DBSCAN.prototype._expandCluster=function(t,r){for(var o=0;o<r.length;o++){var i=r[o];if(1!==this._visited[i]){this._visited[i]=1;var a=this._regionQuery(i);a.length>=this.minPts&&(r=this._mergeArrays(r,a))}1!==this._assigned[i]&&this._addToCluster(i,t)}},DBSCAN.prototype._addToCluster=function(t,r){this.clusters[r].push(t),this._assigned[t]=1},DBSCAN.prototype._regionQuery=function(t){for(var r=[],o=0;o<this._datasetLength;o++){this.distance(this.dataset[t],this.dataset[o])<this.epsilon&&r.push(o)}return r},DBSCAN.prototype._mergeArrays=function(t,r){for(var o=r.length,i=0;i<o;i++){var a=r[i];t.indexOf(a)<0&&t.push(a)}return t},DBSCAN.prototype._euclideanDistance=function(t,r){for(var o=0,i=Math.min(t.length,r.length);i--;)o+=(t[i]-r[i])*(t[i]-r[i]);return Math.sqrt(o)},t.exports&&(t.exports=DBSCAN)},5021:function(t){function KMEANS(t,r,o){this.k=3,this.dataset=[],this.assignments=[],this.centroids=[],this.init(t,r,o)}KMEANS.prototype.init=function(t,r,o){this.assignments=[],this.centroids=[],"undefined"!==typeof t&&(this.dataset=t),"undefined"!==typeof r&&(this.k=r),"undefined"!==typeof o&&(this.distance=o)},KMEANS.prototype.run=function(t,r){this.init(t,r);for(var o=this.dataset.length,i=0;i<this.k;i++)this.centroids[i]=this.randomCentroid();for(var a=!0;a;){a=this.assign();for(var u=0;u<this.k;u++){for(var l=new Array(d),c=0,p=0;p<d;p++)l[p]=0;for(var h=0;h<o;h++){var d=this.dataset[h].length;if(u===this.assignments[h]){for(p=0;p<d;p++)l[p]+=this.dataset[h][p];c++}}if(c>0){for(p=0;p<d;p++)l[p]/=c;this.centroids[u]=l}else this.centroids[u]=this.randomCentroid(),a=!0}}return this.getClusters()},KMEANS.prototype.randomCentroid=function(){var t,r,o=this.dataset.length-1;do{r=Math.round(Math.random()*o),t=this.dataset[r]}while(this.centroids.indexOf(t)>=0);return t},KMEANS.prototype.assign=function(){for(var t,r=!1,o=this.dataset.length,i=0;i<o;i++)(t=this.argmin(this.dataset[i],this.centroids,this.distance))!=this.assignments[i]&&(this.assignments[i]=t,r=!0);return r},KMEANS.prototype.getClusters=function(){for(var t,r=new Array(this.k),o=0;o<this.assignments.length;o++)"undefined"===typeof r[t=this.assignments[o]]&&(r[t]=[]),r[t].push(o);return r},KMEANS.prototype.argmin=function(t,r,o){for(var i,a=Number.MAX_VALUE,u=0,l=r.length,c=0;c<l;c++)(i=o(t,r[c]))<a&&(a=i,u=c);return u},KMEANS.prototype.distance=function(t,r){for(var o=0,i=Math.min(t.length,r.length);i--;){var a=t[i]-r[i];o+=a*a}return Math.sqrt(o)},t.exports&&(t.exports=KMEANS)},9134:function(t,r,o){function _typeof(t){return _typeof="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},_typeof(t)}if(t.exports)var i=o(9250);function OPTICS(t,r,o,i){this.epsilon=1,this.minPts=1,this.distance=this._euclideanDistance,this._reachability=[],this._processed=[],this._coreDistance=0,this._orderedList=[],this._init(t,r,o,i)}OPTICS.prototype.run=function(t,r,o,a){this._init(t,r,o,a);for(var u=0,l=this.dataset.length;u<l;u++)if(1!==this._processed[u]){this._processed[u]=1,this.clusters.push([u]);var c=this.clusters.length-1;this._orderedList.push(u);var p=new i(null,null,"asc"),h=this._regionQuery(u);void 0!==this._distanceToCore(u)&&(this._updateQueue(u,h,p),this._expandCluster(c,p))}return this.clusters},OPTICS.prototype.getReachabilityPlot=function(){for(var t=[],r=0,o=this._orderedList.length;r<o;r++){var i=this._orderedList[r],a=this._reachability[i];t.push([i,a])}return t},OPTICS.prototype._init=function(t,r,o,i){if(t){if(!(t instanceof Array))throw Error("Dataset must be of type array, "+_typeof(t)+" given");this.dataset=t,this.clusters=[],this._reachability=new Array(this.dataset.length),this._processed=new Array(this.dataset.length),this._coreDistance=0,this._orderedList=[]}r&&(this.epsilon=r),o&&(this.minPts=o),i&&(this.distance=i)},OPTICS.prototype._updateQueue=function(t,r,o){var i=this;this._coreDistance=this._distanceToCore(t),r.forEach((function(r){if(void 0===i._processed[r]){var a=i.distance(i.dataset[t],i.dataset[r]),u=Math.max(i._coreDistance,a);void 0===i._reachability[r]?(i._reachability[r]=u,o.insert(r,u)):u<i._reachability[r]&&(i._reachability[r]=u,o.remove(r),o.insert(r,u))}}))},OPTICS.prototype._expandCluster=function(t,r){for(var o=r.getElements(),i=0,a=o.length;i<a;i++){var u=o[i];if(void 0===this._processed[u]){var l=this._regionQuery(u);this._processed[u]=1,this.clusters[t].push(u),this._orderedList.push(u),void 0!==this._distanceToCore(u)&&(this._updateQueue(u,l,r),this._expandCluster(t,r))}}},OPTICS.prototype._distanceToCore=function(t){for(var r=this.epsilon,o=0;o<r;o++){if(this._regionQuery(t,o).length>=this.minPts)return o}},OPTICS.prototype._regionQuery=function(t,r){r=r||this.epsilon;for(var o=[],i=0,a=this.dataset.length;i<a;i++)this.distance(this.dataset[t],this.dataset[i])<r&&o.push(i);return o},OPTICS.prototype._euclideanDistance=function(t,r){for(var o=0,i=Math.min(t.length,r.length);i--;)o+=(t[i]-r[i])*(t[i]-r[i]);return Math.sqrt(o)},t.exports&&(t.exports=OPTICS)},9250:function(t){function PriorityQueue(t,r,o){this._queue=[],this._priorities=[],this._sorting="desc",this._init(t,r,o)}PriorityQueue.prototype.insert=function(t,r){for(var o=this._queue.length,i=o;i--;){var a=this._priorities[i];"desc"===this._sorting?r>a&&(o=i):r<a&&(o=i)}this._insertAt(t,r,o)},PriorityQueue.prototype.remove=function(t){for(var r=this._queue.length;r--;){if(t===this._queue[r]){this._queue.splice(r,1),this._priorities.splice(r,1);break}}},PriorityQueue.prototype.forEach=function(t){this._queue.forEach(t)},PriorityQueue.prototype.getElements=function(){return this._queue},PriorityQueue.prototype.getElementPriority=function(t){return this._priorities[t]},PriorityQueue.prototype.getPriorities=function(){return this._priorities},PriorityQueue.prototype.getElementsWithPriorities=function(){for(var t=[],r=0,o=this._queue.length;r<o;r++)t.push([this._queue[r],this._priorities[r]]);return t},PriorityQueue.prototype._init=function(t,r,o){if(t&&r){if(this._queue=[],this._priorities=[],t.length!==r.length)throw new Error("Arrays must have the same length");for(var i=0;i<t.length;i++)this.insert(t[i],r[i])}o&&(this._sorting=o)},PriorityQueue.prototype._insertAt=function(t,r,o){this._queue.length===o?(this._queue.push(t),this._priorities.push(r)):(this._queue.splice(o,0,t),this._priorities.splice(o,0,r))},t.exports&&(t.exports=PriorityQueue)},7485:function(t,r,o){t.exports&&(t.exports={DBSCAN:o(4283),KMEANS:o(5021),OPTICS:o(9134),PriorityQueue:o(9250)})},3564:function(t){"use strict";function _createForOfIteratorHelper(t,r){var o="undefined"!==typeof Symbol&&t[Symbol.iterator]||t["@@iterator"];if(!o){if(Array.isArray(t)||(o=function _unsupportedIterableToArray(t,r){if(!t)return;if("string"===typeof t)return _arrayLikeToArray(t,r);var o=Object.prototype.toString.call(t).slice(8,-1);"Object"===o&&t.constructor&&(o=t.constructor.name);if("Map"===o||"Set"===o)return Array.from(t);if("Arguments"===o||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(o))return _arrayLikeToArray(t,r)}(t))||r&&t&&"number"===typeof t.length){o&&(t=o);var i=0,a=function F(){};return{s:a,n:function n(){return i>=t.length?{done:!0}:{done:!1,value:t[i++]}},e:function e(t){throw t},f:a}}throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}var u,l=!0,c=!1;return{s:function s(){o=o.call(t)},n:function n(){var t=o.next();return l=t.done,t},e:function e(t){c=!0,u=t},f:function f(){try{l||null==o.return||o.return()}finally{if(c)throw u}}}}function _arrayLikeToArray(t,r){(null==r||r>t.length)&&(r=t.length);for(var o=0,i=new Array(r);o<r;o++)i[o]=t[o];return i}function _typeof(t){return _typeof="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},_typeof(t)}t.exports=function equal(t,r){if(t===r)return!0;if(t&&r&&"object"==_typeof(t)&&"object"==_typeof(r)){if(t.constructor!==r.constructor)return!1;var o,i,a;if(Array.isArray(t)){if((o=t.length)!=r.length)return!1;for(i=o;0!==i--;)if(!equal(t[i],r[i]))return!1;return!0}if(t instanceof Map&&r instanceof Map){if(t.size!==r.size)return!1;var u,l=_createForOfIteratorHelper(t.entries());try{for(l.s();!(u=l.n()).done;)if(i=u.value,!r.has(i[0]))return!1}catch(g){l.e(g)}finally{l.f()}var c,p=_createForOfIteratorHelper(t.entries());try{for(p.s();!(c=p.n()).done;)if(!equal((i=c.value)[1],r.get(i[0])))return!1}catch(g){p.e(g)}finally{p.f()}return!0}if(t instanceof Set&&r instanceof Set){if(t.size!==r.size)return!1;var h,d=_createForOfIteratorHelper(t.entries());try{for(d.s();!(h=d.n()).done;)if(i=h.value,!r.has(i[0]))return!1}catch(g){d.e(g)}finally{d.f()}return!0}if(ArrayBuffer.isView(t)&&ArrayBuffer.isView(r)){if((o=t.length)!=r.length)return!1;for(i=o;0!==i--;)if(t[i]!==r[i])return!1;return!0}if(t.constructor===RegExp)return t.source===r.source&&t.flags===r.flags;if(t.valueOf!==Object.prototype.valueOf)return t.valueOf()===r.valueOf();if(t.toString!==Object.prototype.toString)return t.toString()===r.toString();if((o=(a=Object.keys(t)).length)!==Object.keys(r).length)return!1;for(i=o;0!==i--;)if(!Object.prototype.hasOwnProperty.call(r,a[i]))return!1;for(i=o;0!==i--;){var m=a[i];if(!equal(t[m],r[m]))return!1}return!0}return t!==t&&r!==r}},5361:function(t){"use strict";t.exports={eudist:function eudist(t,r){for(var o=t.length,i=0,a=0;a<o;a++){var u=(t[a]||0)-(r[a]||0);i+=u*u}return i},mandist:function mandist(t,r){for(var o=t.length,i=0,a=0,u=0;u<o;u++)i+=(a=(t[u]||0)-(r[u]||0))>=0?a:-a;return i},dist:function dist(t,r,o){var i=Math.abs(t-r);return o?i:i*i}}},9:function(t,r,o){"use strict";var i=o(5361),a=i.eudist,u=i.dist;t.exports={kmrand:function kmrand(t,r){for(var o={},i=[],a=r<<2,u=t.length,l=t[0].length>0;i.length<r&&a-- >0;){var c=t[Math.floor(Math.random()*u)],p=l?c.join("_"):"".concat(c);o[p]||(o[p]=!0,i.push(c))}if(i.length<r)throw new Error("Error initializating clusters");return i},kmpp:function kmpp(t,r,o){var i=o||(t[0].length?a:u),l=[],c=t.length,p=t[0].length>0,h=t[Math.floor(Math.random()*c)];p?h.join("_"):"".concat(h);for(l.push(h);l.length<r;){for(var d=[],m=l.length,g=0,y=[],_=0;_<c;_++){for(var v=1/0,b=0;b<m;b++){var k=i(t[_],l[b]);k<=v&&(v=k)}d[_]=v}for(var C=0;C<c;C++)g+=d[C];for(var x=0;x<c;x++)y[x]={i:x,v:t[x],pr:d[x]/g,cs:0};y.sort((function(t,r){return t.pr-r.pr})),y[0].cs=y[0].pr;for(var w=1;w<c;w++)y[w].cs=y[w-1].cs+y[w].pr;for(var P=Math.random(),M=0;M<c-1&&y[M++].cs<P;);l.push(y[M-1].v)}return l}}},4250:function(t,r,o){"use strict";var i=o(5361),a=o(9),u=i.eudist,l=(i.mandist,i.dist,a.kmrand),c=a.kmpp;function init(t,r,o){o=o||[];for(var i=0;i<t;i++)o[i]=r;return o}function test(t,r){for(var o=Array.isArray(t),i=this.centroids,a=i.length,l=1/0,c=0,p=0;p<a;p++){var h=r?r(t,i[p]):o?u(t,i[p]):Math.abs(t-i[p]);h<=l&&(l=h,c=p)}return{idx:c,centroid:i[c]}}t.exports=function skmeans(t,r,o,i,a){var p=[],h=[],d=[],m=[],g=!1,y=i||1e4,_=t.length,v=t[0].length,b=v>0,k=[];if(o)p="kmrand"==o?l(t,r):"kmpp"==o?c(t,r,a):o;else for(var C={},x=0;p.length<r;){var w=Math.floor(Math.random()*_);C[w]||(C[w]=!0,p[x++]=t[w])}do{init(r,0,k);for(var P=0;P<_;P++){for(var M=1/0,O=0,S=0;S<r;S++){(m=a?a(t[P],p[S]):b?u(t[P],p[S]):Math.abs(t[P]-p[S]))<=M&&(M=m,O=S)}d[P]=O,k[O]++}var A=[];h=[];if(b)for(var I=0;I<r;I++)A[I]=init(v,0,A[I]),h[I]=p[I];else for(var E=0;E<r;E++)A[E]=0,h[E]=p[E];if(b){for(var T=0;T<r;T++)p[T]=[];for(var L=0;L<_;L++)for(var j=A[d[L]],D=t[L],N=0;N<v;N++)j[N]+=D[N];g=!0;for(var q=0;q<r;q++){for(var R=p[q],Z=A[q],z=h[q],B=k[q],G=0;G<v;G++)R[G]=Z[G]/B||0;if(g)for(var H=0;H<v;H++)if(z[H]!=R[H]){g=!1;break}}}else{for(var K=0;K<_;K++){A[d[K]]+=t[K]}for(var Q=0;Q<r;Q++)p[Q]=A[Q]/k[Q]||0;g=!0;for(var U=0;U<r;U++)if(h[U]!=p[U]){g=!1;break}}g=g||--y<=0}while(!g);return{it:(i||1e4)-y,k:r,idxs:d,centroids:p,test:test}}}},r={};function __webpack_require__(o){var i=r[o];if(void 0!==i)return i.exports;var a=r[o]={exports:{}};return t[o](a,a.exports,__webpack_require__),a.exports}__webpack_require__.n=function(t){var r=t&&t.__esModule?function(){return t.default}:function(){return t};return __webpack_require__.d(r,{a:r}),r},__webpack_require__.d=function(t,r){for(var o in r)__webpack_require__.o(r,o)&&!__webpack_require__.o(t,o)&&Object.defineProperty(t,o,{enumerable:!0,get:r[o]})},__webpack_require__.o=function(t,r){return Object.prototype.hasOwnProperty.call(t,r)},function(){"use strict";var t="ajax-load",r="load-ready",o="map-loaded",i="map-api-loaded",a="map-marker-click",u="map-popup-close";__webpack_require__(4250);__webpack_require__(7485);function sortKD(t,r,o,i,a,u){if(!(a-i<=o)){var l=i+a>>1;sort_select(t,r,l,i,a,u%2),sortKD(t,r,o,i,l-1,u+1),sortKD(t,r,o,l+1,a,u+1)}}function sort_select(t,r,o,i,a,u){for(;a>i;){if(a-i>600){var l=a-i+1,c=o-i+1,p=Math.log(l),h=.5*Math.exp(2*p/3),d=.5*Math.sqrt(p*h*(l-h)/l)*(c-l/2<0?-1:1);sort_select(t,r,o,Math.max(i,Math.floor(o-c*h/l+d)),Math.min(a,Math.floor(o+(l-c)*h/l+d)),u)}var m=r[2*o+u],g=i,y=a;for(swapItem(t,r,i,o),r[2*a+u]>m&&swapItem(t,r,i,a);g<y;){for(swapItem(t,r,g,y),g++,y--;r[2*g+u]<m;)g++;for(;r[2*y+u]>m;)y--}r[2*i+u]===m?swapItem(t,r,i,y):swapItem(t,r,++y,a),y<=o&&(i=y+1),o<=y&&(a=y-1)}}function swapItem(t,r,o,i){swap(t,o,i),swap(r,2*o,2*i),swap(r,2*o+1,2*i+1)}function swap(t,r,o){var i=t[r];t[r]=t[o],t[o]=i}function sqDist(t,r,o,i){var a=t-o,u=r-i;return a*a+u*u}function _classCallCheck(t,r){if(!(t instanceof r))throw new TypeError("Cannot call a class as a function")}function _defineProperties(t,r){for(var o=0;o<r.length;o++){var i=r[o];i.enumerable=i.enumerable||!1,i.configurable=!0,"value"in i&&(i.writable=!0),Object.defineProperty(t,i.key,i)}}var l=function defaultGetX(t){return t[0]},c=function defaultGetY(t){return t[1]},p=function(){function KDBush(t){var r=arguments.length>1&&void 0!==arguments[1]?arguments[1]:l,o=arguments.length>2&&void 0!==arguments[2]?arguments[2]:c,i=arguments.length>3&&void 0!==arguments[3]?arguments[3]:64,a=arguments.length>4&&void 0!==arguments[4]?arguments[4]:Float64Array;_classCallCheck(this,KDBush),this.nodeSize=i,this.points=t;for(var u=t.length<65536?Uint16Array:Uint32Array,p=this.ids=new u(t.length),h=this.coords=new a(2*t.length),d=0;d<t.length;d++)p[d]=d,h[2*d]=r(t[d]),h[2*d+1]=o(t[d]);sortKD(p,h,i,0,p.length-1,0)}return function _createClass(t,r,o){return r&&_defineProperties(t.prototype,r),o&&_defineProperties(t,o),Object.defineProperty(t,"prototype",{writable:!1}),t}(KDBush,[{key:"range",value:function range(t,r,o,i){return function range_range(t,r,o,i,a,u,l){for(var c,p,h=[0,t.length-1,0],d=[];h.length;){var m=h.pop(),g=h.pop(),y=h.pop();if(g-y<=l)for(var _=y;_<=g;_++)c=r[2*_],p=r[2*_+1],c>=o&&c<=a&&p>=i&&p<=u&&d.push(t[_]);else{var v=Math.floor((y+g)/2);c=r[2*v],p=r[2*v+1],c>=o&&c<=a&&p>=i&&p<=u&&d.push(t[v]);var b=(m+1)%2;(0===m?o<=c:i<=p)&&(h.push(y),h.push(v-1),h.push(b)),(0===m?a>=c:u>=p)&&(h.push(v+1),h.push(g),h.push(b))}}return d}(this.ids,this.coords,t,r,o,i,this.nodeSize)}},{key:"within",value:function within(t,r,o){return function within_within(t,r,o,i,a,u){for(var l=[0,t.length-1,0],c=[],p=a*a;l.length;){var h=l.pop(),d=l.pop(),m=l.pop();if(d-m<=u)for(var g=m;g<=d;g++)sqDist(r[2*g],r[2*g+1],o,i)<=p&&c.push(t[g]);else{var y=Math.floor((m+d)/2),_=r[2*y],v=r[2*y+1];sqDist(_,v,o,i)<=p&&c.push(t[y]);var b=(h+1)%2;(0===h?o-a<=_:i-a<=v)&&(l.push(m),l.push(y-1),l.push(b)),(0===h?o+a>=_:i+a>=v)&&(l.push(y+1),l.push(d),l.push(b))}}return c}(this.ids,this.coords,t,r,o,this.nodeSize)}}]),KDBush}();function _slicedToArray(t,r){return function _arrayWithHoles(t){if(Array.isArray(t))return t}(t)||function _iterableToArrayLimit(t,r){var o=null==t?null:"undefined"!==typeof Symbol&&t[Symbol.iterator]||t["@@iterator"];if(null==o)return;var i,a,u=[],l=!0,c=!1;try{for(o=o.call(t);!(l=(i=o.next()).done)&&(u.push(i.value),!r||u.length!==r);l=!0);}catch(p){c=!0,a=p}finally{try{l||null==o.return||o.return()}finally{if(c)throw a}}return u}(t,r)||_unsupportedIterableToArray(t,r)||function _nonIterableRest(){throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function _createForOfIteratorHelper(t,r){var o="undefined"!==typeof Symbol&&t[Symbol.iterator]||t["@@iterator"];if(!o){if(Array.isArray(t)||(o=_unsupportedIterableToArray(t))||r&&t&&"number"===typeof t.length){o&&(t=o);var i=0,a=function F(){};return{s:a,n:function n(){return i>=t.length?{done:!0}:{done:!1,value:t[i++]}},e:function e(t){throw t},f:a}}throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}var u,l=!0,c=!1;return{s:function s(){o=o.call(t)},n:function n(){var t=o.next();return l=t.done,t},e:function e(t){c=!0,u=t},f:function f(){try{l||null==o.return||o.return()}finally{if(c)throw u}}}}function _unsupportedIterableToArray(t,r){if(t){if("string"===typeof t)return _arrayLikeToArray(t,r);var o=Object.prototype.toString.call(t).slice(8,-1);return"Object"===o&&t.constructor&&(o=t.constructor.name),"Map"===o||"Set"===o?Array.from(t):"Arguments"===o||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(o)?_arrayLikeToArray(t,r):void 0}}function _arrayLikeToArray(t,r){(null==r||r>t.length)&&(r=t.length);for(var o=0,i=new Array(r);o<r;o++)i[o]=t[o];return i}function supercluster_defineProperties(t,r){for(var o=0;o<r.length;o++){var i=r[o];i.enumerable=i.enumerable||!1,i.configurable=!0,"value"in i&&(i.writable=!0),Object.defineProperty(t,i.key,i)}}var h,d={minZoom:0,maxZoom:16,minPoints:2,radius:40,extent:512,nodeSize:64,log:!1,generateId:!1,reduce:null,map:function map(t){return t}},m=Math.fround||(h=new Float32Array(1),function(t){return h[0]=+t,h[0]}),g=function(){function Supercluster(t){!function supercluster_classCallCheck(t,r){if(!(t instanceof r))throw new TypeError("Cannot call a class as a function")}(this,Supercluster),this.options=extend(Object.create(d),t),this.trees=new Array(this.options.maxZoom+1)}return function supercluster_createClass(t,r,o){return r&&supercluster_defineProperties(t.prototype,r),o&&supercluster_defineProperties(t,o),Object.defineProperty(t,"prototype",{writable:!1}),t}(Supercluster,[{key:"load",value:function load(t){var r=this.options,o=r.log,i=r.minZoom,a=r.maxZoom,u=r.nodeSize;o&&console.time("total time");var l="prepare ".concat(t.length," points");o&&console.time(l),this.points=t;for(var c,h,d,g,y,_=[],v=0;v<t.length;v++)t[v].geometry&&_.push((c=t[v],h=v,d=void 0,g=void 0,y=void 0,d=_slicedToArray(c.geometry.coordinates,2),g=d[0],y=d[1],{x:m(lngX(g)),y:m(latY(y)),zoom:1/0,index:h,parentId:-1}));this.trees[a+1]=new p(_,getX,getY,u,Float32Array),o&&console.timeEnd(l);for(var b=a;b>=i;b--){var k=+Date.now();_=this._cluster(_,b),this.trees[b]=new p(_,getX,getY,u,Float32Array),o&&console.log("z%d: %d clusters in %dms",b,_.length,+Date.now()-k)}return o&&console.timeEnd("total time"),this}},{key:"getClusters",value:function getClusters(t,r){var o=((t[0]+180)%360+360)%360-180,i=Math.max(-90,Math.min(90,t[1])),a=180===t[2]?180:((t[2]+180)%360+360)%360-180,u=Math.max(-90,Math.min(90,t[3]));if(t[2]-t[0]>=360)o=-180,a=180;else if(o>a){var l=this.getClusters([o,i,180,u],r),c=this.getClusters([-180,i,a,u],r);return l.concat(c)}var p,h=this.trees[this._limitZoom(r)],d=[],m=_createForOfIteratorHelper(h.range(lngX(o),latY(u),lngX(a),latY(i)));try{for(m.s();!(p=m.n()).done;){var g=p.value,y=h.points[g];d.push(y.numPoints?getClusterJSON(y):this.points[y.index])}}catch(_){m.e(_)}finally{m.f()}return d}},{key:"getChildren",value:function getChildren(t){var r=this._getOriginId(t),o=this._getOriginZoom(t),i="No cluster with the specified id.",a=this.trees[o];if(!a)throw new Error(i);var u=a.points[r];if(!u)throw new Error(i);var l,c=this.options.radius/(this.options.extent*Math.pow(2,o-1)),p=[],h=_createForOfIteratorHelper(a.within(u.x,u.y,c));try{for(h.s();!(l=h.n()).done;){var d=l.value,m=a.points[d];m.parentId===t&&p.push(m.numPoints?getClusterJSON(m):this.points[m.index])}}catch(g){h.e(g)}finally{h.f()}if(0===p.length)throw new Error(i);return p}},{key:"getLeaves",value:function getLeaves(t,r,o){r=r||10,o=o||0;var i=[];return this._appendLeaves(i,t,r,o,0),i}},{key:"getTile",value:function getTile(t,r,o){var i=this.trees[this._limitZoom(t)],a=Math.pow(2,t),u=this.options,l=u.extent,c=u.radius/l,p=(o-c)/a,h=(o+1+c)/a,d={features:[]};return this._addTileFeatures(i.range((r-c)/a,p,(r+1+c)/a,h),i.points,r,o,a,d),0===r&&this._addTileFeatures(i.range(1-c/a,p,1,h),i.points,a,o,a,d),r===a-1&&this._addTileFeatures(i.range(0,p,c/a,h),i.points,-1,o,a,d),d.features.length?d:null}},{key:"getClusterExpansionZoom",value:function getClusterExpansionZoom(t){for(var r=this._getOriginZoom(t)-1;r<=this.options.maxZoom;){var o=this.getChildren(t);if(r++,1!==o.length)break;t=o[0].properties.cluster_id}return r}},{key:"_appendLeaves",value:function _appendLeaves(t,r,o,i,a){var u,l=_createForOfIteratorHelper(this.getChildren(r));try{for(l.s();!(u=l.n()).done;){var c=u.value,p=c.properties;if(p&&p.cluster?a+p.point_count<=i?a+=p.point_count:a=this._appendLeaves(t,p.cluster_id,o,i,a):a<i?a++:t.push(c),t.length===o)break}}catch(h){l.e(h)}finally{l.f()}return a}},{key:"_addTileFeatures",value:function _addTileFeatures(t,r,o,i,a,u){var l,c=_createForOfIteratorHelper(t);try{for(c.s();!(l=c.n()).done;){var p=r[l.value],h=p.numPoints,d=void 0,m=void 0,g=void 0;if(h)d=getClusterProperties(p),m=p.x,g=p.y;else{var y=this.points[p.index];d=y.properties,m=lngX(y.geometry.coordinates[0]),g=latY(y.geometry.coordinates[1])}var _={type:1,geometry:[[Math.round(this.options.extent*(m*a-o)),Math.round(this.options.extent*(g*a-i))]],tags:d},v=void 0;h?v=p.id:this.options.generateId?v=p.index:this.points[p.index].id&&(v=this.points[p.index].id),void 0!==v&&(_.id=v),u.features.push(_)}}catch(b){c.e(b)}finally{c.f()}}},{key:"_limitZoom",value:function _limitZoom(t){return Math.max(this.options.minZoom,Math.min(+t,this.options.maxZoom+1))}},{key:"_cluster",value:function _cluster(t,r){for(var o=[],i=this.options,a=i.radius,u=i.extent,l=i.reduce,c=i.minPoints,p=a/(u*Math.pow(2,r)),h=0;h<t.length;h++){var d=t[h];if(!(d.zoom<=r)){d.zoom=r;var m,g=this.trees[r+1],y=g.within(d.x,d.y,p),_=d.numPoints||1,v=_,b=_createForOfIteratorHelper(y);try{for(b.s();!(m=b.n()).done;){var k=m.value,C=g.points[k];C.zoom>r&&(v+=C.numPoints||1)}}catch(N){b.e(N)}finally{b.f()}if(v>_&&v>=c){var x,w=d.x*_,P=d.y*_,M=l&&_>1?this._map(d,!0):null,O=(h<<5)+(r+1)+this.points.length,S=_createForOfIteratorHelper(y);try{for(S.s();!(x=S.n()).done;){var A=x.value,I=g.points[A];if(!(I.zoom<=r)){I.zoom=r;var E=I.numPoints||1;w+=I.x*E,P+=I.y*E,I.parentId=O,l&&(M||(M=this._map(d,!0)),l(M,this._map(I)))}}}catch(N){S.e(N)}finally{S.f()}d.parentId=O,o.push(createCluster(w/v,P/v,O,v,M))}else if(o.push(d),v>1){var T,L=_createForOfIteratorHelper(y);try{for(L.s();!(T=L.n()).done;){var j=T.value,D=g.points[j];D.zoom<=r||(D.zoom=r,o.push(D))}}catch(N){L.e(N)}finally{L.f()}}}}return o}},{key:"_getOriginId",value:function _getOriginId(t){return t-this.points.length>>5}},{key:"_getOriginZoom",value:function _getOriginZoom(t){return(t-this.points.length)%32}},{key:"_map",value:function _map(t,r){if(t.numPoints)return r?extend({},t.properties):t.properties;var o=this.points[t.index].properties,i=this.options.map(o);return r&&i===o?extend({},i):i}}]),Supercluster}();function createCluster(t,r,o,i,a){return{x:m(t),y:m(r),zoom:1/0,id:o,parentId:-1,numPoints:i,properties:a}}function getClusterJSON(t){return{type:"Feature",id:t.id,properties:getClusterProperties(t),geometry:{type:"Point",coordinates:[(i=t.x,360*(i-.5)),(r=t.y,o=(180-360*r)*Math.PI/180,360*Math.atan(Math.exp(o))/Math.PI-90)]}};var r,o,i}function getClusterProperties(t){var r=t.numPoints,o=r>=1e4?"".concat(Math.round(r/1e3),"k"):r>=1e3?"".concat(Math.round(r/100)/10,"k"):r;return extend(extend({},t.properties),{cluster:!0,cluster_id:t.id,point_count:r,point_count_abbreviated:o})}function lngX(t){return t/360+.5}function latY(t){var r=Math.sin(t*Math.PI/180),o=.5-.25*Math.log((1+r)/(1-r))/Math.PI;return o<0?0:o>1?1:o}function extend(t,r){for(var o in r)t[o]=r[o];return t}function getX(t){return t.x}function getY(t){return t.y}var y=__webpack_require__(3564),_=__webpack_require__.n(y);function index_esm_typeof(t){return index_esm_typeof="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},index_esm_typeof(t)}function index_esm_slicedToArray(t,r){return function index_esm_arrayWithHoles(t){if(Array.isArray(t))return t}(t)||function index_esm_iterableToArrayLimit(t,r){var o=null==t?null:"undefined"!==typeof Symbol&&t[Symbol.iterator]||t["@@iterator"];if(null==o)return;var i,a,u=[],l=!0,c=!1;try{for(o=o.call(t);!(l=(i=o.next()).done)&&(u.push(i.value),!r||u.length!==r);l=!0);}catch(p){c=!0,a=p}finally{try{l||null==o.return||o.return()}finally{if(c)throw a}}return u}(t,r)||index_esm_unsupportedIterableToArray(t,r)||function index_esm_nonIterableRest(){throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function _toConsumableArray(t){return function _arrayWithoutHoles(t){if(Array.isArray(t))return index_esm_arrayLikeToArray(t)}(t)||function _iterableToArray(t){if("undefined"!==typeof Symbol&&null!=t[Symbol.iterator]||null!=t["@@iterator"])return Array.from(t)}(t)||index_esm_unsupportedIterableToArray(t)||function _nonIterableSpread(){throw new TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function index_esm_unsupportedIterableToArray(t,r){if(t){if("string"===typeof t)return index_esm_arrayLikeToArray(t,r);var o=Object.prototype.toString.call(t).slice(8,-1);return"Object"===o&&t.constructor&&(o=t.constructor.name),"Map"===o||"Set"===o?Array.from(t):"Arguments"===o||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(o)?index_esm_arrayLikeToArray(t,r):void 0}}function index_esm_arrayLikeToArray(t,r){(null==r||r>t.length)&&(r=t.length);for(var o=0,i=new Array(r);o<r;o++)i[o]=t[o];return i}function _inherits(t,r){if("function"!==typeof r&&null!==r)throw new TypeError("Super expression must either be null or a function");t.prototype=Object.create(r&&r.prototype,{constructor:{value:t,writable:!0,configurable:!0}}),Object.defineProperty(t,"prototype",{writable:!1}),r&&_setPrototypeOf(t,r)}function _setPrototypeOf(t,r){return _setPrototypeOf=Object.setPrototypeOf||function _setPrototypeOf(t,r){return t.__proto__=r,t},_setPrototypeOf(t,r)}function _createSuper(t){var r=function _isNativeReflectConstruct(){if("undefined"===typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"===typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(t){return!1}}();return function _createSuperInternal(){var o,i=_getPrototypeOf(t);if(r){var a=_getPrototypeOf(this).constructor;o=Reflect.construct(i,arguments,a)}else o=i.apply(this,arguments);return _possibleConstructorReturn(this,o)}}function _possibleConstructorReturn(t,r){if(r&&("object"===index_esm_typeof(r)||"function"===typeof r))return r;if(void 0!==r)throw new TypeError("Derived constructors may only return object or undefined");return function _assertThisInitialized(t){if(void 0===t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return t}(t)}function _getPrototypeOf(t){return _getPrototypeOf=Object.setPrototypeOf?Object.getPrototypeOf:function _getPrototypeOf(t){return t.__proto__||Object.getPrototypeOf(t)},_getPrototypeOf(t)}function index_esm_classCallCheck(t,r){if(!(t instanceof r))throw new TypeError("Cannot call a class as a function")}function index_esm_defineProperties(t,r){for(var o=0;o<r.length;o++){var i=r[o];i.enumerable=i.enumerable||!1,i.configurable=!0,"value"in i&&(i.writable=!0),Object.defineProperty(t,i.key,i)}}function index_esm_createClass(t,r,o){return r&&index_esm_defineProperties(t.prototype,r),o&&index_esm_defineProperties(t,o),Object.defineProperty(t,"prototype",{writable:!1}),t}function __rest(t,r){var o={};for(var i in t)Object.prototype.hasOwnProperty.call(t,i)&&r.indexOf(i)<0&&(o[i]=t[i]);if(null!=t&&"function"===typeof Object.getOwnPropertySymbols){var a=0;for(i=Object.getOwnPropertySymbols(t);a<i.length;a++)r.indexOf(i[a])<0&&Object.prototype.propertyIsEnumerable.call(t,i[a])&&(o[i[a]]=t[i[a]])}return o}var v=function(){function Cluster(t){var r=t.markers,o=t.position;index_esm_classCallCheck(this,Cluster),this.markers=r,o&&(o instanceof google.maps.LatLng?this._position=o:this._position=new google.maps.LatLng(o))}return index_esm_createClass(Cluster,[{key:"bounds",get:function get(){if(0!==this.markers.length||this._position)return this.markers.reduce((function(t,r){return t.extend(r.getPosition())}),new google.maps.LatLngBounds(this._position,this._position))}},{key:"position",get:function get(){return this._position||this.bounds.getCenter()}},{key:"count",get:function get(){return this.markers.filter((function(t){return t.getVisible()})).length}},{key:"push",value:function push(t){this.markers.push(t)}},{key:"delete",value:function _delete(){this.marker&&(this.marker.setMap(null),delete this.marker),this.markers.length=0}}]),Cluster}(),b=function(){function AbstractAlgorithm(t){var r=t.maxZoom,o=void 0===r?16:r;index_esm_classCallCheck(this,AbstractAlgorithm),this.maxZoom=o}return index_esm_createClass(AbstractAlgorithm,[{key:"noop",value:function noop(t){var r=t.markers;return k(r)}}]),AbstractAlgorithm}(),k=function _noop(t){return t.map((function(t){return new v({position:t.getPosition(),markers:[t]})}))},C=function(t){_inherits(SuperClusterAlgorithm,t);var r=_createSuper(SuperClusterAlgorithm);function SuperClusterAlgorithm(t){var o;index_esm_classCallCheck(this,SuperClusterAlgorithm);var i=t.maxZoom,a=t.radius,u=void 0===a?60:a,l=__rest(t,["maxZoom","radius"]);return(o=r.call(this,{maxZoom:i})).superCluster=new g(Object.assign({maxZoom:o.maxZoom,radius:u},l)),o.state={zoom:null},o}return index_esm_createClass(SuperClusterAlgorithm,[{key:"calculate",value:function calculate(t){var r=!1;if(!_()(t.markers,this.markers)){r=!0,this.markers=_toConsumableArray(t.markers);var o=this.markers.map((function(t){return{type:"Feature",geometry:{type:"Point",coordinates:[t.getPosition().lng(),t.getPosition().lat()]},properties:{marker:t}}}));this.superCluster.load(o)}var i={zoom:t.map.getZoom()};return r||this.state.zoom>this.maxZoom&&i.zoom>this.maxZoom||(r=r||!_()(this.state,i)),this.state=i,r&&(this.clusters=this.cluster(t)),{clusters:this.clusters,changed:r}}},{key:"cluster",value:function cluster(t){var r=t.map;return this.superCluster.getClusters([-180,-90,180,90],Math.round(r.getZoom())).map(this.transformCluster.bind(this))}},{key:"transformCluster",value:function transformCluster(t){var r=index_esm_slicedToArray(t.geometry.coordinates,2),o=r[0],i=r[1],a=t.properties;if(a.cluster)return new v({markers:this.superCluster.getLeaves(a.cluster_id,1/0).map((function(t){return t.properties.marker})),position:new google.maps.LatLng({lat:i,lng:o})});var u=a.marker;return new v({markers:[u],position:u.getPosition()})}}]),SuperClusterAlgorithm}(b),x=index_esm_createClass((function ClusterStats(t,r){index_esm_classCallCheck(this,ClusterStats),this.markers={sum:t.length};var o=r.map((function(t){return t.count})),i=o.reduce((function(t,r){return t+r}),0);this.clusters={count:r.length,markers:{mean:i/r.length,sum:i,min:Math.min.apply(Math,_toConsumableArray(o)),max:Math.max.apply(Math,_toConsumableArray(o))}}})),w=function(){function DefaultRenderer(){index_esm_classCallCheck(this,DefaultRenderer)}return index_esm_createClass(DefaultRenderer,[{key:"render",value:function render(t,r){var o=t.count,i=t.position,a=o>Math.max(10,r.clusters.markers.mean)?"#ff0000":"#0000ff",u=window.btoa('\n <svg fill="'.concat(a,'" xmlns="http://www.w3.org/2000/svg" viewBox="0 0 240 240">\n <circle cx="120" cy="120" opacity=".6" r="70" />\n <circle cx="120" cy="120" opacity=".3" r="90" />\n <circle cx="120" cy="120" opacity=".2" r="110" />\n </svg>'));return new google.maps.Marker({position:i,icon:{url:"data:image/svg+xml;base64,".concat(u),scaledSize:new google.maps.Size(45,45)},label:{text:String(o),color:"rgba(255,255,255,0.9)",fontSize:"12px"},title:"Cluster of ".concat(o," markers"),zIndex:Number(google.maps.Marker.MAX_ZINDEX)+o})}}]),DefaultRenderer}();var P,M=index_esm_createClass((function OverlayViewSafe(){index_esm_classCallCheck(this,OverlayViewSafe),function index_esm_extend(t,r){for(var o in r.prototype)t.prototype[o]=r.prototype[o]}(OverlayViewSafe,google.maps.OverlayView)}));!function(t){t.CLUSTERING_BEGIN="clusteringbegin",t.CLUSTERING_END="clusteringend",t.CLUSTER_CLICK="click"}(P||(P={}));var O=function defaultOnClusterClickHandler(t,r,o){o.fitBounds(r.bounds)},S=function(t){_inherits(MarkerClusterer,t);var r=_createSuper(MarkerClusterer);function MarkerClusterer(t){var o,i=t.map,a=t.markers,u=void 0===a?[]:a,l=t.algorithm,c=void 0===l?new C({}):l,p=t.renderer,h=void 0===p?new w:p,d=t.onClusterClick,m=void 0===d?O:d;return index_esm_classCallCheck(this,MarkerClusterer),(o=r.call(this)).markers=_toConsumableArray(u),o.clusters=[],o.algorithm=c,o.renderer=h,o.onClusterClick=m,i&&o.setMap(i),o}return index_esm_createClass(MarkerClusterer,[{key:"addMarker",value:function addMarker(t,r){this.markers.includes(t)||(this.markers.push(t),r||this.render())}},{key:"addMarkers",value:function addMarkers(t,r){var o=this;t.forEach((function(t){o.addMarker(t,!0)})),r||this.render()}},{key:"removeMarker",value:function removeMarker(t,r){var o=this.markers.indexOf(t);return-1!==o&&(t.setMap(null),this.markers.splice(o,1),r||this.render(),!0)}},{key:"removeMarkers",value:function removeMarkers(t,r){var o=this,i=!1;return t.forEach((function(t){i=o.removeMarker(t,!0)||i})),i&&!r&&this.render(),i}},{key:"clearMarkers",value:function clearMarkers(t){this.markers.length=0,t||this.render()}},{key:"render",value:function render(){var t=this.getMap();if(t instanceof google.maps.Map&&this.getProjection()){google.maps.event.trigger(this,P.CLUSTERING_BEGIN,this);var r=this.algorithm.calculate({markers:this.markers,map:t,mapCanvasProjection:this.getProjection()}),o=r.clusters,i=r.changed;(i||void 0==i)&&(this.reset(),this.clusters=o,this.renderClusters()),google.maps.event.trigger(this,P.CLUSTERING_END,this)}}},{key:"onAdd",value:function onAdd(){this.idleListener=this.getMap().addListener("idle",this.render.bind(this)),this.render()}},{key:"onRemove",value:function onRemove(){google.maps.event.removeListener(this.idleListener),this.reset()}},{key:"reset",value:function reset(){this.markers.forEach((function(t){return t.setMap(null)})),this.clusters.forEach((function(t){return t.delete()})),this.clusters=[]}},{key:"renderClusters",value:function renderClusters(){var t=this,r=new x(this.markers,this.clusters),o=this.getMap();this.clusters.forEach((function(i){1===i.markers.length?i.marker=i.markers[0]:(i.marker=t.renderer.render(i,r),t.onClusterClick&&i.marker.addListener("click",(function(r){google.maps.event.trigger(t,P.CLUSTER_CLICK,i),t.onClusterClick(r,i,o)}))),i.marker.setMap(o)}))}}]),MarkerClusterer}(M);function map_google_marker_typeof(t){return map_google_marker_typeof="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},map_google_marker_typeof(t)}function map_google_marker_defineProperties(t,r){for(var o=0;o<r.length;o++){var i=r[o];i.enumerable=i.enumerable||!1,i.configurable=!0,"value"in i&&(i.writable=!0),Object.defineProperty(t,i.key,i)}}function map_google_marker_setPrototypeOf(t,r){return map_google_marker_setPrototypeOf=Object.setPrototypeOf||function _setPrototypeOf(t,r){return t.__proto__=r,t},map_google_marker_setPrototypeOf(t,r)}function map_google_marker_createSuper(t){var r=function map_google_marker_isNativeReflectConstruct(){if("undefined"===typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"===typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(t){return!1}}();return function _createSuperInternal(){var o,i=map_google_marker_getPrototypeOf(t);if(r){var a=map_google_marker_getPrototypeOf(this).constructor;o=Reflect.construct(i,arguments,a)}else o=i.apply(this,arguments);return map_google_marker_possibleConstructorReturn(this,o)}}function map_google_marker_possibleConstructorReturn(t,r){if(r&&("object"===map_google_marker_typeof(r)||"function"===typeof r))return r;if(void 0!==r)throw new TypeError("Derived constructors may only return object or undefined");return map_google_marker_assertThisInitialized(t)}function map_google_marker_assertThisInitialized(t){if(void 0===t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return t}function map_google_marker_getPrototypeOf(t){return map_google_marker_getPrototypeOf=Object.setPrototypeOf?Object.getPrototypeOf:function _getPrototypeOf(t){return t.__proto__||Object.getPrototypeOf(t)},map_google_marker_getPrototypeOf(t)}var A={init:function init(){return function(t){!function map_google_marker_inherits(t,r){if("function"!==typeof r&&null!==r)throw new TypeError("Super expression must either be null or a function");t.prototype=Object.create(r&&r.prototype,{constructor:{value:t,writable:!0,configurable:!0}}),Object.defineProperty(t,"prototype",{writable:!1}),r&&map_google_marker_setPrototypeOf(t,r)}(GoogleMapsHtmlOverlay,google.maps.OverlayView);var r=map_google_marker_createSuper(GoogleMapsHtmlOverlay);function GoogleMapsHtmlOverlay(t){var o;!function map_google_marker_classCallCheck(t,r){if(!(t instanceof r))throw new TypeError("Cannot call a class as a function")}(this,GoogleMapsHtmlOverlay);var i=map_google_marker_assertThisInitialized(o=r.call(this));return i.ownerMap=t.map,i.position=t.position,i.html=t.html?t.html:'<div class="mapboxgl-marker"><i class="marker-icon fas fa-map-marker-alt"></i></div>',i.divClass=t.divClass,i.align=t.align,i.isDebugMode=t.debug,i.onClick=t.onClick,i.onMouseOver=t.onMouseOver,i.isBoolean=function(t){return"boolean"===typeof t},i.isNotUndefined=function(t){return"undefined"!==typeof t},i.hasContent=function(t){return t.length>0},i.isString=function(t){return"string"===typeof t},i.isFunction=function(t){return"function"===typeof t},o}return function map_google_marker_createClass(t,r,o){return r&&map_google_marker_defineProperties(t.prototype,r),o&&map_google_marker_defineProperties(t,o),Object.defineProperty(t,"prototype",{writable:!1}),t}(GoogleMapsHtmlOverlay,[{key:"onAdd",value:function onAdd(){var t=this;t.div=document.createElement("div"),t.div.style.position="absolute",t.isNotUndefined(t.divClass)&&t.hasContent(t.divClass)&&(t.div.className=t.divClass),t.isNotUndefined(t.html)&&t.hasContent(t.html)&&t.isString(t.html)&&(t.div.innerHTML=t.html),t.isBoolean(t.isDebugMode)&&t.isDebugMode&&(t.div.className="debug-mode",t.div.innerHTML='<div style="height: 10px; width: 10px; background: red; border-radius: 100%;"></div><div style="position: absolute; top: 5px; padding: 5px; width: 130px; text-align: center; font-size: 18px; text-transform: uppercase; font-weight: bolder; background: red; color: white; font-family: Arial;">Debug mode</div>',t.div.setAttribute("style","position: absolute;border: 5px dashed red;height: 150px;width: 150px;display: flex;justify-content: center;align-items: center;")),t.getPanes().overlayMouseTarget.appendChild(t.div),google.maps.event.addDomListener(t.div,"click",(function(r){google.maps.event.trigger(t,"click"),t.isFunction(t.onClick)&&t.onClick(),r.stopPropagation()})),google.maps.event.addDomListener(t.div,"mouseover",(function(r){google.maps.event.trigger(t,"mouseover"),t.isFunction(t.onMouseOver)&&t.onMouseOver(),r.stopPropagation()}))}},{key:"draw",value:function draw(){var t=this,r=document.querySelector(".popup");r.length||(r=t.div);var o=t.getProjection();if(!o)return console.log("GoogleMapsHtmlOverlay: current map is missing"),null;var i=o.fromLatLngToDivPixel(t.getPosition()),a={y:void 0,x:void 0},u=r.offsetWidth,l=r.offsetHeight;switch(Array.isArray(t.align)?t.align.join(" "):""){case"left top":a.y=l,a.x=u;break;case"left center":a.y=l/2,a.x=u;break;case"left bottom":a.y=0,a.x=u;break;case"center top":a.y=l,a.x=u/2;break;case"center center":default:a.y=l/2,a.x=u/2;break;case"center bottom":a.y=0,a.x=u/2;break;case"right top":a.y=l,a.x=0;break;case"right center":a.y=l/2,a.x=0;break;case"right bottom":a.y=0,a.x=0}t.div.style.top="".concat(i.y-a.y,"px"),t.div.style.left="".concat(i.x-a.x,"px")}},{key:"getPosition",value:function getPosition(){return new google.maps.LatLng(this.position)}},{key:"getDiv",value:function getDiv(){return this.div}},{key:"setPosition",value:function setPosition(t,r){var o=this;o.position=t,o.align=r,o.draw()}},{key:"remove",value:function remove(){this.setMap(null),this.div.remove()}},{key:"getDraggable",value:function getDraggable(){return!1}}]),GoogleMapsHtmlOverlay}()}};function map_google_defineProperties(t,r){for(var o=0;o<r.length;o++){var i=r[o];i.enumerable=i.enumerable||!1,i.configurable=!0,"value"in i&&(i.writable=!0),Object.defineProperty(t,i.key,i)}}var I=function(t){var r=function(){function GoogleMapsDriver(){!function map_google_classCallCheck(t,r){if(!(t instanceof r))throw new TypeError("Cannot call a class as a function")}(this,GoogleMapsDriver)}return function map_google_createClass(t,r,o){return r&&map_google_defineProperties(t.prototype,r),o&&map_google_defineProperties(t,o),Object.defineProperty(t,"prototype",{writable:!1}),t}(GoogleMapsDriver,[{key:"getName",value:function getName(){return"GoogleMapsDriver"}},{key:"init",value:function init(r){var o=arguments.length>1&&void 0!==arguments[1]?arguments[1]:[],i=this;i.el=r,i.config=o,i.markers=[],t["init".concat(i.getName())]=function(){i.googleApiLoaded()};var a=document.createElement("script");a.src="https://maps.googleapis.com/maps/api/js?key=".concat(o.key,"&callback=init").concat(i.getName()),a.async=!0,a.defer=!0,document.head.appendChild(a)}},{key:"googleApiLoaded",value:function googleApiLoaded(){var t=this,r=t.el,o=t.config,a=r.querySelector(".mapAPI-map"),u=o.mapZoom&&"0"!==o.mapZoom?parseInt(o.mapZoom):10,l=o.center&&","!==o.center?{lat:o.center[1],lng:o.center[0]}:{lat:0,lng:0},c=o.style?o.style:null;console.log("".concat(t.getName(),": API is loaded")),t.MarkerUI=A.init(),t.map=new google.maps.Map(a,{zoom:u,center:l,fullscreenControl:!0,styles:c}),t.default_zoom=u,a.classList.add("mapboxgl-map"),t.popup=new t.MarkerUI({map:t.map,align:["center","top"],divClass:"mapboxgl-popup popup mapboxgl-popup-anchor-bottom d-none",html:'<div class="mapboxgl-popup-tip"></div><div class="mapboxgl-popup-content"><div class="mapboxgl-popup-close-button" type="button" aria-label="Close popup">\xd7</div><div class="html"></div></div>'}),t.popup.setMap(t.map),t.geocoder=new google.maps.Geocoder,t.cluster=new S(t.map,null,{styles:[{width:30,height:30,className:"mapboxgl-cluster"}]}),r.dispatchEvent(new Event(i))}},{key:"addMarker",value:function addMarker(t,r){var o=this,i={lat:t[1],lng:t[0]},u=new o.MarkerUI({position:i,map:o.map,align:["center","top"],html:'<div class="mapboxgl-marker"><div id="Marker'.concat(r.id,'" data-id="').concat(r.id,'" class="marker">').concat(r.icon,"</div></div>"),onClick:function onClick(){var t=document.querySelector("#Marker".concat(r.id));o.showPopup(i,r.content),t.dispatchEvent(new Event(a))}});return o.markers.push(u),o.cluster.addMarker(u),u}},{key:"showPopup",value:function showPopup(t,r){var o=this,i=o.popup.getDiv();o.config.flyToMarker&&(o.map.setCenter(t),o.config.noZoom||o.map.setZoom(18)),i.style.opacity="0",i.classList.remove("d-none"),i.querySelector(".mapboxgl-popup-content .html").innerHTML=r,i.querySelector(".mapboxgl-popup-close-button").addEventListener("click",(function(t){t.preventDefault(),o.hidePopup()})),o.popup.setPosition(t,["center","top"]),i.style.opacity="1",i.style["margin-top"]="-1rem"}},{key:"hidePopup",value:function hidePopup(){var t=this;t.popup.getDiv().classList.add("d-none"),t.config.noRestoreBounds&&!t.config.flyToBounds||t.restoreBounds(),t.el.dispatchEvent(new Event(u))}},{key:"geocode",value:function geocode(t,r){var o=this;o.geocoder.geocode({address:t},(function(t,i){if("OK"===i)return"function"===typeof r&&r(t),t;console.error("".concat(o.getName(),": Geocode was not successful for the following reason: ").concat(i))}))}},{key:"reverseGeocode",value:function reverseGeocode(t,r){var o=this;o.geocoder.geocode({location:latlng},(function(t,i){if("OK"===i)return"function"===typeof r&&r(t),t;console.error("".concat(o.getName(),": Reverse Geocoding was not successful for the following reason: ").concat(i))}))}},{key:"addGeoJson",value:function addGeoJson(t){var r=this,o=JSON.parse(t.geojson),i=(o.features[0].geometry.coordinates,new google.maps.LatLngBounds);o.features.forEach((function(o){var a=o.id,u=o.geometry.coordinates,l=o.properties.content;r.addMarker(u,{id:a,content:l,icon:o.icon,flyToMarker:t.flyToMarker}),i.extend({lat:u[1],lng:u[0]})})),r.markers.length>1?r.map.fitBounds(i,{padding:30}):r.markers[0]&&r.map.setCenter(r.markers[0].getPosition()),r.default_bounds=i,r.default_zoom=r.map.getZoom()}},{key:"getMap",value:function getMap(){return this.map}},{key:"getPopup",value:function getPopup(){return this.popup}},{key:"restoreBounds",value:function restoreBounds(){var t=this;t.default_bounds&&t.markers.length>1?t.map.fitBounds(t.default_bounds,{padding:30}):(t.markers[0]&&t.map.setCenter(t.markers[0].getPosition()),t.restoreZoom())}},{key:"restoreZoom",value:function restoreZoom(){this.map.setZoom(this.default_zoom)}}]),GoogleMapsDriver}();return r}(window),E={ENVS:["xs","sm","md","lg","xl","xxl","xxxl"],MAP_DRIVER:I};function map_api_defineProperties(t,r){for(var o=0;o<r.length;o++){var i=r[o];i.enumerable=i.enumerable||!1,i.configurable=!0,"value"in i&&(i.writable=!0),Object.defineProperty(t,i.key,i)}}!function(a){var u="js-mapapi",l=E.MAP_DRIVER,c=function(){function MapAPI(t){!function map_api_classCallCheck(t,r){if(!(t instanceof r))throw new TypeError("Cannot call a class as a function")}(this,MapAPI);var r=this,o=new l,a=document.querySelector("body"),c=t.dataset;c.center=[c.lng?c.lng:a.dataset["default-lng"],c.lat?c.lat:a.dataset["default-lat"]],c.icon||(c.icon='<i class="fas fa-map-marker-alt"></i>'),console.log("".concat(u,": init ").concat(o.getName(),"...")),r.drv=o,r.el=t,r.config=c,o.init(t,c),t.addEventListener(i,(function(){r.addMarkers()}))}return function map_api_createClass(t,r,o){return r&&map_api_defineProperties(t.prototype,r),o&&map_api_defineProperties(t,o),Object.defineProperty(t,"prototype",{writable:!1}),t}(MapAPI,[{key:"getMap",value:function getMap(){return ui.map}},{key:"dispose",value:function dispose(){this.el=null,this.el.classList.remove("".concat(u,"-active"))}},{key:"addMarkers",value:function addMarkers(){console.log("".concat(u,": addMarkers"));var t=this,r=t.el,i=t.drv,a=t.config;if(t.map=i.getMap(),a.geojson)console.log("".concat(u,": setting up geocode data")),i.addGeoJson(a);else if(a.address)console.log(a.address),console.log("".concat(u,": setting up address marker")),i.geocode(a.address,(function(r){console.log(r);var o=r[0].geometry.location.lat(),l=r[0].geometry.location.lng();console.log("".concat(u,": setting up single lat/lng marker lat: ").concat(o," lng: ").concat(l)),i.addMarker([l,o],a),t.map.setCenter({lat:o,lng:l})}));else if(a.lat&&a.lng){var l=a.lat,c=a.lng;console.log("".concat(u,": setting up single lat/lng marker lat: ").concat(l," lng: ").concat(c)),i.addMarker([c,l],a)}r.classList.add("".concat(u,"-active")),r.dispatchEvent(new Event(o)),console.log("".concat(u,": Map is loaded"))}}]),MapAPI}(),p=function init(){console.log("".concat(u,": init")),document.querySelectorAll(".".concat(u)).forEach((function(t,r){new c(t)}))};a.addEventListener("".concat(r),p),a.addEventListener("".concat(t),p)}(window)}()}();

View File

@ -0,0 +1,14 @@
/*! *****************************************************************************
Copyright (c) Microsoft Corporation.
Permission to use, copy, modify, and/or distribute this software for any
purpose with or without fee is hereby granted.
THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES WITH
REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY
AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, DIRECT,
INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM
LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR
OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR
PERFORMANCE OF THIS SOFTWARE.
***************************************************************************** */

File diff suppressed because one or more lines are too long

View File

@ -31,7 +31,7 @@
831
]
},
"mini-css-extract-plugin /mnt/data/srv/dist/repositories/silverstripe-webpack/node_modules/.pnpm/css-loader@6.5.1_webpack@5.66.0/node_modules/css-loader/dist/cjs.js??ruleSet[1].rules[1].use[1]!./node_modules/.pnpm/sass-loader@12.4.0_sass@1.48.0+webpack@5.66.0/node_modules/sass-loader/dist/cjs.js??ruleSet[1].rules[1].use[2]!./app/client/src/scss/app.scss": [
"mini-css-extract-plugin /mnt/data/srv/dist/repositories/silverstripe-webpack/node_modules/.pnpm/css-loader@6.7.1_webpack@5.70.0/node_modules/css-loader/dist/cjs.js??ruleSet[1].rules[1].use[1]!./node_modules/.pnpm/sass-loader@12.6.0_sass@1.49.9+webpack@5.70.0/node_modules/sass-loader/dist/cjs.js??ruleSet[1].rules[1].use[2]!./app/client/src/scss/app.scss": [
{
"chunks": {
"byName": {
@ -46,10 +46,10 @@
},
"modules": {
"byIdentifier": {
"./node_modules/.pnpm/babel-loader@8.2.3_70acdf73bf8b5ce90b5f0f8b0b09e0d8/node_modules/babel-loader/lib/index.js??ruleSet[1].rules[0].use!./node_modules/.pnpm/css-loader@6.5.1_webpack@5.66.0/node_modules/css-loader/dist/runtime/api.js": 814,
"./node_modules/.pnpm/babel-loader@8.2.3_70acdf73bf8b5ce90b5f0f8b0b09e0d8/node_modules/babel-loader/lib/index.js??ruleSet[1].rules[0].use!./node_modules/.pnpm/css-loader@6.5.1_webpack@5.66.0/node_modules/css-loader/dist/runtime/getUrl.js": 531,
"./node_modules/.pnpm/babel-loader@8.2.3_70acdf73bf8b5ce90b5f0f8b0b09e0d8/node_modules/babel-loader/lib/index.js??ruleSet[1].rules[0].use!./node_modules/.pnpm/css-loader@6.5.1_webpack@5.66.0/node_modules/css-loader/dist/runtime/sourceMaps.js": 344,
"./node_modules/.pnpm/css-loader@6.5.1_webpack@5.66.0/node_modules/css-loader/dist/cjs.js??ruleSet[1].rules[1].use[1]!./node_modules/.pnpm/sass-loader@12.4.0_sass@1.48.0+webpack@5.66.0/node_modules/sass-loader/dist/cjs.js??ruleSet[1].rules[1].use[2]!./app/client/src/scss/app.scss": 472,
"./node_modules/.pnpm/babel-loader@8.2.3_c57fa08b67e0055c44c6192257d88d4e/node_modules/babel-loader/lib/index.js??ruleSet[1].rules[0].use!./node_modules/.pnpm/css-loader@6.7.1_webpack@5.70.0/node_modules/css-loader/dist/runtime/api.js": 67,
"./node_modules/.pnpm/babel-loader@8.2.3_c57fa08b67e0055c44c6192257d88d4e/node_modules/babel-loader/lib/index.js??ruleSet[1].rules[0].use!./node_modules/.pnpm/css-loader@6.7.1_webpack@5.70.0/node_modules/css-loader/dist/runtime/getUrl.js": 293,
"./node_modules/.pnpm/babel-loader@8.2.3_c57fa08b67e0055c44c6192257d88d4e/node_modules/babel-loader/lib/index.js??ruleSet[1].rules[0].use!./node_modules/.pnpm/css-loader@6.7.1_webpack@5.70.0/node_modules/css-loader/dist/runtime/sourceMaps.js": 117,
"./node_modules/.pnpm/css-loader@6.7.1_webpack@5.70.0/node_modules/css-loader/dist/cjs.js??ruleSet[1].rules[1].use[1]!./node_modules/.pnpm/sass-loader@12.6.0_sass@1.49.9+webpack@5.70.0/node_modules/sass-loader/dist/cjs.js??ruleSet[1].rules[1].use[2]!./app/client/src/scss/app.scss": 514,
"asset/inline|data:image/svg+xml,%3csvg xmlns=%27http://www.w3.org/2000/svg%27 viewBox=%27-4 -4 8 8%27%3e%3ccircle r=%272%27 fill=%27%23fff%27/%3e%3c/svg%3e": 204,
"asset/inline|data:image/svg+xml,%3csvg xmlns=%27http://www.w3.org/2000/svg%27 viewBox=%27-4 -4 8 8%27%3e%3ccircle r=%273%27 fill=%27%2386b7fe%27/%3e%3c/svg%3e": 609,
"asset/inline|data:image/svg+xml,%3csvg xmlns=%27http://www.w3.org/2000/svg%27 viewBox=%27-4 -4 8 8%27%3e%3ccircle r=%273%27 fill=%27%23fff%27/%3e%3c/svg%3e": 469,
@ -68,23 +68,23 @@
"asset/inline|data:image/svg+xml,%3csvg xmlns=%27http://www.w3.org/2000/svg%27 viewBox=%270 0 8 8%27%3e%3cpath fill=%27%23198754%27 d=%27M2.3 6.73L.6 4.53c-.4-1.04.46-1.4 1.1-.8l1.1 1.4 3.4-3.8c.6-.63 1.6-.27 1.2.7l-4 4.6c-.43.5-.8.4-1.1.1z%27/%3e%3c/svg%3e": 819
},
"usedIds": [
67,
117,
144,
175,
204,
214,
217,
344,
293,
349,
460,
469,
472,
486,
531,
514,
609,
647,
692,
740,
814,
819,
931,
956
@ -92,7 +92,7 @@
}
}
],
"mini-css-extract-plugin /mnt/data/srv/dist/repositories/silverstripe-webpack/node_modules/.pnpm/css-loader@6.5.1_webpack@5.66.0/node_modules/css-loader/dist/cjs.js??ruleSet[1].rules[1].use[1]!./node_modules/.pnpm/sass-loader@12.4.0_sass@1.48.0+webpack@5.66.0/node_modules/sass-loader/dist/cjs.js??ruleSet[1].rules[1].use[2]!./app/client/src/scss/types/cms.scss": [
"mini-css-extract-plugin /mnt/data/srv/dist/repositories/silverstripe-webpack/node_modules/.pnpm/css-loader@6.7.1_webpack@5.70.0/node_modules/css-loader/dist/cjs.js??ruleSet[1].rules[1].use[1]!./node_modules/.pnpm/sass-loader@12.6.0_sass@1.49.9+webpack@5.70.0/node_modules/sass-loader/dist/cjs.js??ruleSet[1].rules[1].use[2]!./app/client/src/scss/types/cms.scss": [
{
"chunks": {
"byName": {
@ -107,19 +107,19 @@
},
"modules": {
"byIdentifier": {
"./node_modules/.pnpm/babel-loader@8.2.3_70acdf73bf8b5ce90b5f0f8b0b09e0d8/node_modules/babel-loader/lib/index.js??ruleSet[1].rules[0].use!./node_modules/.pnpm/css-loader@6.5.1_webpack@5.66.0/node_modules/css-loader/dist/runtime/api.js": 814,
"./node_modules/.pnpm/babel-loader@8.2.3_70acdf73bf8b5ce90b5f0f8b0b09e0d8/node_modules/babel-loader/lib/index.js??ruleSet[1].rules[0].use!./node_modules/.pnpm/css-loader@6.5.1_webpack@5.66.0/node_modules/css-loader/dist/runtime/sourceMaps.js": 344,
"./node_modules/.pnpm/css-loader@6.5.1_webpack@5.66.0/node_modules/css-loader/dist/cjs.js??ruleSet[1].rules[1].use[1]!./node_modules/.pnpm/sass-loader@12.4.0_sass@1.48.0+webpack@5.66.0/node_modules/sass-loader/dist/cjs.js??ruleSet[1].rules[1].use[2]!./app/client/src/scss/types/cms.scss": 525
"./node_modules/.pnpm/babel-loader@8.2.3_c57fa08b67e0055c44c6192257d88d4e/node_modules/babel-loader/lib/index.js??ruleSet[1].rules[0].use!./node_modules/.pnpm/css-loader@6.7.1_webpack@5.70.0/node_modules/css-loader/dist/runtime/api.js": 67,
"./node_modules/.pnpm/babel-loader@8.2.3_c57fa08b67e0055c44c6192257d88d4e/node_modules/babel-loader/lib/index.js??ruleSet[1].rules[0].use!./node_modules/.pnpm/css-loader@6.7.1_webpack@5.70.0/node_modules/css-loader/dist/runtime/sourceMaps.js": 117,
"./node_modules/.pnpm/css-loader@6.7.1_webpack@5.70.0/node_modules/css-loader/dist/cjs.js??ruleSet[1].rules[1].use[1]!./node_modules/.pnpm/sass-loader@12.6.0_sass@1.49.9+webpack@5.70.0/node_modules/sass-loader/dist/cjs.js??ruleSet[1].rules[1].use[2]!./app/client/src/scss/types/cms.scss": 541
},
"usedIds": [
344,
525,
814
67,
117,
541
]
}
}
],
"mini-css-extract-plugin /mnt/data/srv/dist/repositories/silverstripe-webpack/node_modules/.pnpm/css-loader@6.5.1_webpack@5.66.0/node_modules/css-loader/dist/cjs.js??ruleSet[1].rules[1].use[1]!./node_modules/.pnpm/sass-loader@12.4.0_sass@1.48.0+webpack@5.66.0/node_modules/sass-loader/dist/cjs.js??ruleSet[1].rules[1].use[2]!./app/client/src/scss/types/dev.scss": [
"mini-css-extract-plugin /mnt/data/srv/dist/repositories/silverstripe-webpack/node_modules/.pnpm/css-loader@6.7.1_webpack@5.70.0/node_modules/css-loader/dist/cjs.js??ruleSet[1].rules[1].use[1]!./node_modules/.pnpm/sass-loader@12.6.0_sass@1.49.9+webpack@5.70.0/node_modules/sass-loader/dist/cjs.js??ruleSet[1].rules[1].use[2]!./app/client/src/scss/types/dev.scss": [
{
"chunks": {
"byName": {
<