├── .npmignore ├── public ├── CNAME ├── client │ ├── assets │ │ ├── index-29fa31c2.css │ │ ├── markers-036513c0.css │ │ ├── Leaflet-24eada1d.css │ │ ├── dynamicmarker-5f19e055.css │ │ ├── multiplemaps-62468025.css │ │ └── client-37b56038.css │ ├── legacy │ │ ├── assets │ │ │ ├── index-29fa31c2.css │ │ │ ├── markers-036513c0.css │ │ │ ├── Leaflet-24eada1d.css │ │ │ ├── dynamicmarker-5f19e055.css │ │ │ ├── multiplemaps-62468025.css │ │ │ └── client-37b56038.css │ │ ├── _layout.6823517f.js │ │ ├── _layout.df0f82dc.js │ │ ├── index.62188751.js │ │ ├── index.049368df.js │ │ ├── index.41ed73bf.js │ │ ├── index.500e2040.js │ │ ├── index.ad6813dd.js │ │ ├── Leaflet.5c215536.js │ │ ├── Leaflet.b4123ade.js │ │ ├── Leaflet.fd83408e.js │ │ ├── Leaflet.6f0b781f.js │ │ └── Leaflet.de470149.js │ ├── _layout.5f3b4fab.js │ ├── _layout.e1c0fd6a.js │ ├── index.0f953e3b.js │ ├── index.2f46261f.js │ ├── index.9beb2412.js │ ├── index.87135b46.js │ ├── index.c8aa42e9.js │ ├── Leaflet.1fd8bc0e.js │ ├── Leaflet.6481def0.js │ ├── Leaflet.764aae6b.js │ ├── Leaflet.1975f146.js │ ├── Leaflet.399e6cc7.js │ ├── index.024ef953.js │ ├── index.0fedf38a.js │ ├── index.683fc466.js │ ├── index.ac71540c.js │ ├── index.deb1472f.js │ ├── shimport@1.0.1.js │ ├── autocenter.003c8795.js │ ├── autocenter.1dd29cbf.js │ ├── autocenter.4d4d70e7.js │ ├── autocenter.72f27238.js │ ├── autocenter.f9d22676.js │ ├── disablescrollwheelzoom.165d01fa.js │ ├── disablescrollwheelzoom.770e47da.js │ └── disablescrollwheelzoom.8872cf05.js ├── favicon.png ├── logo-192.png ├── logo-512.png ├── svelte-logo.png ├── manifest.json ├── global.css ├── service-worker.js ├── service-worker-index.html ├── examples │ ├── index.html │ ├── autocenter │ │ └── index.html │ ├── themes │ │ └── index.html │ └── disablescrollwheelzoom │ │ └── index.html ├── prism.css ├── misc │ └── index.html └── index.html ├── src ├── index.js ├── stores.js ├── LoadSdk.svelte └── Leaflet.svelte ├── .gitattributes ├── rollup.config.js ├── README.md ├── LICENSE ├── package.json └── .gitignore /.npmignore: -------------------------------------------------------------------------------- 1 | public -------------------------------------------------------------------------------- /public/CNAME: -------------------------------------------------------------------------------- 1 | leaflet.anoram.com -------------------------------------------------------------------------------- /src/index.js: -------------------------------------------------------------------------------- 1 | export { default as default } from './Leaflet.svelte'; 2 | -------------------------------------------------------------------------------- /public/client/assets/index-29fa31c2.css: -------------------------------------------------------------------------------- 1 | .map.svelte-dt8ylx{height:600px;width:auto} -------------------------------------------------------------------------------- /.gitattributes: -------------------------------------------------------------------------------- 1 | # Auto detect text files and perform LF normalization 2 | * text=auto 3 | -------------------------------------------------------------------------------- /public/client/assets/markers-036513c0.css: -------------------------------------------------------------------------------- 1 | .map.svelte-1clh5nd{height:600px;width:auto} -------------------------------------------------------------------------------- /public/client/assets/Leaflet-24eada1d.css: -------------------------------------------------------------------------------- 1 | .map.svelte-1xdqv5q{height:inherit;width:inherit} -------------------------------------------------------------------------------- /public/client/assets/dynamicmarker-5f19e055.css: -------------------------------------------------------------------------------- 1 | .map.svelte-yphpdh{height:600px;width:auto} -------------------------------------------------------------------------------- /public/client/legacy/assets/index-29fa31c2.css: -------------------------------------------------------------------------------- 1 | .map.svelte-dt8ylx{height:600px;width:auto} -------------------------------------------------------------------------------- /public/client/legacy/assets/markers-036513c0.css: -------------------------------------------------------------------------------- 1 | .map.svelte-1clh5nd{height:600px;width:auto} -------------------------------------------------------------------------------- /public/favicon.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/anoram/leaflet-svelte/HEAD/public/favicon.png -------------------------------------------------------------------------------- /public/client/legacy/assets/Leaflet-24eada1d.css: -------------------------------------------------------------------------------- 1 | .map.svelte-1xdqv5q{height:inherit;width:inherit} -------------------------------------------------------------------------------- /public/client/legacy/assets/dynamicmarker-5f19e055.css: -------------------------------------------------------------------------------- 1 | .map.svelte-yphpdh{height:600px;width:auto} -------------------------------------------------------------------------------- /public/logo-192.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/anoram/leaflet-svelte/HEAD/public/logo-192.png -------------------------------------------------------------------------------- /public/logo-512.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/anoram/leaflet-svelte/HEAD/public/logo-512.png -------------------------------------------------------------------------------- /public/client/assets/multiplemaps-62468025.css: -------------------------------------------------------------------------------- 1 | .map.svelte-szbau7{height:300px;width:auto;margin:2em 0} -------------------------------------------------------------------------------- /public/svelte-logo.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/anoram/leaflet-svelte/HEAD/public/svelte-logo.png -------------------------------------------------------------------------------- /public/client/legacy/assets/multiplemaps-62468025.css: -------------------------------------------------------------------------------- 1 | .map.svelte-szbau7{height:300px;width:auto;margin:2em 0} -------------------------------------------------------------------------------- /src/stores.js: -------------------------------------------------------------------------------- 1 | import { writable } from 'svelte/store'; 2 | 3 | 4 | export const mapsLoaded = writable(false) 5 | export const mapsLoading = writable(false) 6 | -------------------------------------------------------------------------------- /public/manifest.json: -------------------------------------------------------------------------------- 1 | { 2 | "background_color": "#ffffff", 3 | "theme_color": "#333333", 4 | "name": "leaflet-svelte-demo", 5 | "short_name": "leaflet-svelte-demo", 6 | "display": "minimal-ui", 7 | "start_url": "/", 8 | "icons": [ 9 | { 10 | "src": "logo-192.png", 11 | "sizes": "192x192", 12 | "type": "image/png" 13 | }, 14 | { 15 | "src": "logo-512.png", 16 | "sizes": "512x512", 17 | "type": "image/png" 18 | } 19 | ] 20 | } 21 | -------------------------------------------------------------------------------- /rollup.config.js: -------------------------------------------------------------------------------- 1 | import svelte from 'rollup-plugin-svelte'; 2 | import resolve from '@rollup/plugin-node-resolve'; 3 | import pkg from './package.json'; 4 | 5 | const name = pkg.name 6 | .replace(/^(@\S+\/)?(svelte-)?(\S+)/, '$3') 7 | .replace(/^\w/, m => m.toUpperCase()) 8 | .replace(/-\w/g, m => m[1].toUpperCase()); 9 | 10 | export default { 11 | input: 'src/index.js', 12 | output: [ 13 | { file: pkg.module, 'format': 'es' }, 14 | { file: pkg.main, 'format': 'umd', name } 15 | ], 16 | plugins: [ 17 | svelte(), 18 | resolve() 19 | ] 20 | }; 21 | -------------------------------------------------------------------------------- /README.md: -------------------------------------------------------------------------------- 1 | ## Quick Start 2 | 3 | Install `npm i @anoram/leaflet-svelte` 4 | 5 | ```html 6 | 19 | 25 |
26 | 27 |
28 | 29 | ``` 30 | 31 | ## Demo and other instructions 32 | 33 | [https://leaflet.anoram.com](https://leaflet.anoram.com) 34 | 35 | 36 | 37 | -------------------------------------------------------------------------------- /public/global.css: -------------------------------------------------------------------------------- 1 | 2 | pre{ 3 | height: auto; 4 | max-height: 450px; 5 | font-size: 12px !important; 6 | 7 | } 8 | 9 | .tag { 10 | display: inherit !important; 11 | border: inherit !important; 12 | text-transform:inherit !important; 13 | color: inherit !important; 14 | padding: inherit !important; 15 | line-height: inherit !important; 16 | letter-spacing: inherit !important; 17 | } 18 | 19 | code, kbd, pre { 20 | background-color: #2d2d2d !important; 21 | color: #ccc !important; 22 | } 23 | .chip { 24 | padding: 4px; 25 | background-color: #d6d6d6; 26 | color: var(--color-error); 27 | font-size: 12px !important; 28 | } -------------------------------------------------------------------------------- /public/client/_layout.5f3b4fab.js: -------------------------------------------------------------------------------- 1 | import{S as s,i as a,s as c,C as l,e as t,c as o,a as r,d as e,b as n,f as i,m as u,D as f,p as $,r as d}from"./client.27f5503e.js";function h(s){let a,c,h,p;const v=s[1].default,m=l(v,s,s[0],null);return{c(){a=t("div"),c=t("div"),h=t("div"),m&&m.c(),this.h()},l(s){a=o(s,"DIV",{class:!0});var l=r(a);c=o(l,"DIV",{class:!0});var t=r(c);h=o(t,"DIV",{class:!0});var n=r(h);m&&m.l(n),n.forEach(e),t.forEach(e),l.forEach(e),this.h()},h(){n(h,"class","col"),n(c,"class","row"),n(a,"class","container")},m(s,l){i(s,a,l),u(a,c),u(c,h),m&&m.m(h,null),p=!0},p(s,[a]){m&&m.p&&1&a&&f(m,v,s,s[0],a,null,null)},i(s){p||($(m,s),p=!0)},o(s){d(m,s),p=!1},d(s){s&&e(a),m&&m.d(s)}}}function p(s,a,c){let{$$slots:l={},$$scope:t}=a;return s.$$set=s=>{"$$scope"in s&&c(0,t=s.$$scope)},[t,l]}export default class extends s{constructor(s){super(),a(this,s,p,h,c,{})}} 2 | -------------------------------------------------------------------------------- /public/client/_layout.e1c0fd6a.js: -------------------------------------------------------------------------------- 1 | import{S as s,i as a,s as c,C as l,e as t,c as o,a as r,d as e,b as n,f as i,m as u,D as d,p as f,r as $}from"./client.47f8a5db.js";function h(s){let a,c,h,p;const v=s[1].default,m=l(v,s,s[0],null);return{c(){a=t("div"),c=t("div"),h=t("div"),m&&m.c(),this.h()},l(s){a=o(s,"DIV",{class:!0});var l=r(a);c=o(l,"DIV",{class:!0});var t=r(c);h=o(t,"DIV",{class:!0});var n=r(h);m&&m.l(n),n.forEach(e),t.forEach(e),l.forEach(e),this.h()},h(){n(h,"class","col"),n(c,"class","row"),n(a,"class","container")},m(s,l){i(s,a,l),u(a,c),u(c,h),m&&m.m(h,null),p=!0},p(s,[a]){m&&m.p&&1&a&&d(m,v,s,s[0],a,null,null)},i(s){p||(f(m,s),p=!0)},o(s){$(m,s),p=!1},d(s){s&&e(a),m&&m.d(s)}}}function p(s,a,c){let{$$slots:l={},$$scope:t}=a;return s.$$set=s=>{"$$scope"in s&&c(0,t=s.$$scope)},[t,l]}export default class extends s{constructor(s){super(),a(this,s,p,h,c,{})}} 2 | -------------------------------------------------------------------------------- /public/client/assets/client-37b56038.css: -------------------------------------------------------------------------------- 1 | nav.svelte-1dbd5up{border-bottom:1px solid rgba(255,62,0,0.1);font-weight:300;padding:0 1em}ul.svelte-1dbd5up{margin:0;padding:0}ul.svelte-1dbd5up::after{content:'';display:block;clear:both}li.svelte-1dbd5up{display:block;float:left}[aria-current].svelte-1dbd5up{position:relative;display:inline-block}[aria-current].svelte-1dbd5up::after{position:absolute;content:'';width:calc(100% - 1em);height:2px;background-color:rgb(255,62,0);display:block;bottom:-1px}a.svelte-1dbd5up{text-decoration:none;padding:1em 0.5em;display:block} 2 | main.svelte-1fhquo8{position:relative;background-color:white;padding:2em;margin:0 auto;box-sizing:border-box} 3 | h1.svelte-8od9u6,p.svelte-8od9u6{margin:0 auto}h1.svelte-8od9u6{font-size:2.8em;font-weight:700;margin:0 0 0.5em 0}p.svelte-8od9u6{margin:1em auto}@media(min-width: 480px){h1.svelte-8od9u6{font-size:4em}} -------------------------------------------------------------------------------- /public/client/legacy/assets/client-37b56038.css: -------------------------------------------------------------------------------- 1 | nav.svelte-1dbd5up{border-bottom:1px solid rgba(255,62,0,0.1);font-weight:300;padding:0 1em}ul.svelte-1dbd5up{margin:0;padding:0}ul.svelte-1dbd5up::after{content:'';display:block;clear:both}li.svelte-1dbd5up{display:block;float:left}[aria-current].svelte-1dbd5up{position:relative;display:inline-block}[aria-current].svelte-1dbd5up::after{position:absolute;content:'';width:calc(100% - 1em);height:2px;background-color:rgb(255,62,0);display:block;bottom:-1px}a.svelte-1dbd5up{text-decoration:none;padding:1em 0.5em;display:block} 2 | main.svelte-1fhquo8{position:relative;background-color:white;padding:2em;margin:0 auto;box-sizing:border-box} 3 | h1.svelte-8od9u6,p.svelte-8od9u6{margin:0 auto}h1.svelte-8od9u6{font-size:2.8em;font-weight:700;margin:0 0 0.5em 0}p.svelte-8od9u6{margin:1em auto}@media(min-width: 480px){h1.svelte-8od9u6{font-size:4em}} -------------------------------------------------------------------------------- /src/LoadSdk.svelte: -------------------------------------------------------------------------------- 1 | 44 | 45 | -------------------------------------------------------------------------------- /LICENSE: -------------------------------------------------------------------------------- 1 | MIT License 2 | 3 | Copyright (c) 2020 Shriji 4 | 5 | Permission is hereby granted, free of charge, to any person obtaining a copy 6 | of this software and associated documentation files (the "Software"), to deal 7 | in the Software without restriction, including without limitation the rights 8 | to use, copy, modify, merge, publish, distribute, sublicense, and/or sell 9 | copies of the Software, and to permit persons to whom the Software is 10 | furnished to do so, subject to the following conditions: 11 | 12 | The above copyright notice and this permission notice shall be included in all 13 | copies or substantial portions of the Software. 14 | 15 | THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 16 | IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 17 | FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE 18 | AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER 19 | LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, 20 | OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE 21 | SOFTWARE. 22 | -------------------------------------------------------------------------------- /package.json: -------------------------------------------------------------------------------- 1 | { 2 | "name": "@anoram/leaflet-svelte", 3 | "svelte": "src/index.js", 4 | "module": "dist/index.mjs", 5 | "main": "dist/index.js", 6 | "scripts": { 7 | "build": "rollup -c", 8 | "prepublishOnly": "npm run build" 9 | }, 10 | "devDependencies": { 11 | "@rollup/plugin-node-resolve": "^6.0.0", 12 | "rollup": "^1.20.0", 13 | "rollup-plugin-svelte": "^5.0.0", 14 | "svelte": "^3.0.0" 15 | }, 16 | "keywords": [ 17 | "svelte", 18 | "leaflet", 19 | "sapper", 20 | "maps" 21 | ], 22 | "files": [ 23 | "src", 24 | "dist" 25 | ], 26 | "dependencies": { 27 | "@beyonk/async-script-loader": "^2.0.0" 28 | }, 29 | "publishConfig": { 30 | "access": "public" 31 | }, 32 | "description": "Svelte wrapper for Leaflet", 33 | "version": "0.0.7-1", 34 | "author": "Shriji Kondan (shriji@anoram.com)", 35 | "license": "MIT", 36 | "repository": { 37 | "type": "git", 38 | "url": "git+https://github.com/anoram/leaflet-svelte.git" 39 | }, 40 | "bugs": { 41 | "url": "https://github.com/anoram/leaflet-svelte/issues" 42 | }, 43 | "homepage": "https://github.com/anoram/leaflet-svelte#readme" 44 | } 45 | -------------------------------------------------------------------------------- /public/client/legacy/_layout.6823517f.js: -------------------------------------------------------------------------------- 1 | import{_ as t,g as n,h as c,j as s,i as a,k as r,S as o,s as u,G as i,e,c as f,a as l,d as h,b as v,f as p,u as d,H as $,I as y,w as m,x as D}from"./client.9c8a37b7.js";function R(t){var s=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(t){return!1}}();return function(){var a,r=n(t);if(s){var o=n(this).constructor;a=Reflect.construct(r,arguments,o)}else a=r.apply(this,arguments);return c(this,a)}}function I(t){var n,c,s,a,r=t[1].default,o=i(r,t,t[0],null);return{c:function(){n=e("div"),c=e("div"),s=e("div"),o&&o.c(),this.h()},l:function(t){n=f(t,"DIV",{class:!0});var a=l(n);c=f(a,"DIV",{class:!0});var r=l(c);s=f(r,"DIV",{class:!0});var u=l(s);o&&o.l(u),u.forEach(h),r.forEach(h),a.forEach(h),this.h()},h:function(){v(s,"class","col"),v(c,"class","row"),v(n,"class","container")},m:function(t,r){p(t,n,r),d(n,c),d(c,s),o&&o.m(s,null),a=!0},p:function(t,n){var c=$(n,1)[0];o&&o.p&&1&c&&y(o,r,t,t[0],c,null,null)},i:function(t){a||(m(o,t),a=!0)},o:function(t){D(o,t),a=!1},d:function(t){t&&h(n),o&&o.d(t)}}}function x(t,n,c){var s=n.$$slots,a=void 0===s?{}:s,r=n.$$scope;return t.$$set=function(t){"$$scope"in t&&c(0,r=t.$$scope)},[r,a]}var E=function(n){t(i,o);var c=R(i);function i(t){var n;return s(this,i),n=c.call(this),a(r(n),t,x,I,u,{}),n}return i}();export default E; 2 | -------------------------------------------------------------------------------- /public/client/legacy/_layout.df0f82dc.js: -------------------------------------------------------------------------------- 1 | import{_ as t,g as n,h as c,j as s,i as a,k as r,S as o,s as e,G as u,e as i,c as f,a as l,d as h,b as v,f as p,u as d,H as $,I as y,w as m,x as D}from"./client.48d5e9eb.js";function R(t){var s=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(t){return!1}}();return function(){var a,r=n(t);if(s){var o=n(this).constructor;a=Reflect.construct(r,arguments,o)}else a=r.apply(this,arguments);return c(this,a)}}function I(t){var n,c,s,a,r=t[1].default,o=u(r,t,t[0],null);return{c:function(){n=i("div"),c=i("div"),s=i("div"),o&&o.c(),this.h()},l:function(t){n=f(t,"DIV",{class:!0});var a=l(n);c=f(a,"DIV",{class:!0});var r=l(c);s=f(r,"DIV",{class:!0});var e=l(s);o&&o.l(e),e.forEach(h),r.forEach(h),a.forEach(h),this.h()},h:function(){v(s,"class","col"),v(c,"class","row"),v(n,"class","container")},m:function(t,r){p(t,n,r),d(n,c),d(c,s),o&&o.m(s,null),a=!0},p:function(t,n){var c=$(n,1)[0];o&&o.p&&1&c&&y(o,r,t,t[0],c,null,null)},i:function(t){a||(m(o,t),a=!0)},o:function(t){D(o,t),a=!1},d:function(t){t&&h(n),o&&o.d(t)}}}function x(t,n,c){var s=n.$$slots,a=void 0===s?{}:s,r=n.$$scope;return t.$$set=function(t){"$$scope"in t&&c(0,r=t.$$scope)},[r,a]}var E=function(n){t(u,o);var c=R(u);function u(t){var n;return s(this,u),n=c.call(this),a(r(n),t,x,I,e,{}),n}return u}();export default E; 2 | -------------------------------------------------------------------------------- /public/service-worker.js: -------------------------------------------------------------------------------- 1 | !function(){"use strict";const e=1602001049784,t="cache"+e,s=["/client/index.0fedf38a.js","/client/Leaflet.1975f146.js","/client/index.87135b46.js","/client/disablescrollwheelzoom.165d01fa.js","/client/dynamicmarker.910263a7.js","/client/multiplemaps.63d30901.js","/client/autocenter.003c8795.js","/client/tilelayer.118871a9.js","/client/circle.d288ffd7.js","/client/tooltip.5c798283.js","/client/markers.ce0b5181.js","/client/themes.75debb01.js","/client/misc.00560820.js","/client/client.a52649eb.js"].concat(["/service-worker-index.html","/CNAME","/favicon.png","/global.css","/logo-192.png","/logo-512.png","/manifest.json","/prism.css","/prism.js","/svelte-logo.png"]),n=new Set(s);self.addEventListener("install",e=>{e.waitUntil(caches.open(t).then(e=>e.addAll(s)).then(()=>{self.skipWaiting()}))}),self.addEventListener("activate",e=>{e.waitUntil(caches.keys().then(async e=>{for(const s of e)s!==t&&await caches.delete(s);self.clients.claim()}))}),self.addEventListener("fetch",t=>{if("GET"!==t.request.method||t.request.headers.has("range"))return;const s=new URL(t.request.url);s.protocol.startsWith("http")&&(s.hostname===self.location.hostname&&s.port!==self.location.port||(s.host===self.location.host&&n.has(s.pathname)?t.respondWith(caches.match(t.request)):"only-if-cached"!==t.request.cache&&t.respondWith(caches.open("offline"+e).then(async e=>{try{const s=await fetch(t.request);return e.put(t.request,s.clone()),s}catch(s){const n=await e.match(t.request);if(n)return n;throw s}}))))})}(); 2 | -------------------------------------------------------------------------------- /public/service-worker-index.html: -------------------------------------------------------------------------------- 1 |
-------------------------------------------------------------------------------- /public/client/index.0f953e3b.js: -------------------------------------------------------------------------------- 1 | import{S as t,i as e,s as a,e as l,t as s,c as r,a as o,k as h,d as i,b as n,f as c,m as p,n as f,g as m,j as u,E as v}from"./client.27f5503e.js";function d(t,e,a){const l=t.slice();return l[1]=e[a],l}function g(t){let e,a,m,u,v=t[1].title+"";return{c(){e=l("li"),a=l("a"),m=s(v),this.h()},l(t){e=r(t,"LI",{});var l=o(e);a=r(l,"A",{href:!0});var s=o(a);m=h(s,v),s.forEach(i),l.forEach(i),this.h()},h(){n(a,"href",u="examples/"+t[1].path)},m(t,l){c(t,e,l),p(e,a),p(a,m)},p:f,d(t){t&&i(e)}}}function E(t){let e,a,E,x,w,D,I,b=t[0].reverse(),L=[];for(let e=0;e Examples
-------------------------------------------------------------------------------- /public/client/legacy/index.62188751.js: -------------------------------------------------------------------------------- 1 | import{_ as t,g as a,h as r,j as e,i as n,k as o,S as c,s,e as i,t as l,c as f,a as u,p as h,d as p,b as v,f as m,u as d,n as g,l as E,o as y,H as x,J as D}from"./client.9c8a37b7.js";function w(t){var e=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(t){return!1}}();return function(){var n,o=a(t);if(e){var c=a(this).constructor;n=Reflect.construct(o,arguments,c)}else n=o.apply(this,arguments);return r(this,n)}}function R(t,a,r){var e=t.slice();return e[1]=a[r],e}function b(t){var a,r,e,n=t[1].title+"";return{c:function(){a=i("li"),r=i("a"),e=l(n),this.h()},l:function(t){a=f(t,"LI",{});var o=u(a);r=f(o,"A",{href:!0});var c=u(r);e=h(c,n),c.forEach(p),o.forEach(p),this.h()},h:function(){v(r,"href","examples/"+t[1].path)},m:function(t,n){m(t,a,n),d(a,r),d(r,e)},p:g,d:function(t){t&&p(a)}}}function I(t){for(var a,r,e,n,o,c,s,w=t[0].reverse(),I=[],L=0;L code[class*="language-"], 41 | pre[class*="language-"] { 42 | background: #2d2d2d; 43 | } 44 | 45 | /* Inline code */ 46 | :not(pre) > code[class*="language-"] { 47 | padding: .1em; 48 | border-radius: .3em; 49 | white-space: normal; 50 | } 51 | 52 | .token.comment, 53 | .token.block-comment, 54 | .token.prolog, 55 | .token.doctype, 56 | .token.cdata { 57 | color: #999; 58 | } 59 | 60 | .token.punctuation { 61 | color: #ccc; 62 | } 63 | 64 | .token.tag, 65 | .token.attr-name, 66 | .token.namespace, 67 | .token.deleted { 68 | color: #e2777a; 69 | } 70 | 71 | .token.function-name { 72 | color: #6196cc; 73 | } 74 | 75 | .token.boolean, 76 | .token.number, 77 | .token.function { 78 | color: #f08d49; 79 | } 80 | 81 | .token.property, 82 | .token.class-name, 83 | .token.constant, 84 | .token.symbol { 85 | color: #f8c555; 86 | } 87 | 88 | .token.selector, 89 | .token.important, 90 | .token.atrule, 91 | .token.keyword, 92 | .token.builtin { 93 | color: #cc99cd; 94 | } 95 | 96 | .token.string, 97 | .token.char, 98 | .token.attr-value, 99 | .token.regex, 100 | .token.variable { 101 | color: #7ec699; 102 | } 103 | 104 | .token.operator, 105 | .token.entity, 106 | .token.url { 107 | color: #67cdcc; 108 | } 109 | 110 | .token.important, 111 | .token.bold { 112 | font-weight: bold; 113 | } 114 | .token.italic { 115 | font-style: italic; 116 | } 117 | 118 | .token.entity { 119 | cursor: help; 120 | } 121 | 122 | .token.inserted { 123 | color: green; 124 | } 125 | 126 | -------------------------------------------------------------------------------- /public/client/legacy/index.500e2040.js: -------------------------------------------------------------------------------- 1 | import{_ as t,g as a,h as e,j as r,i as n,k as i,S as l,s as c,e as s,t as o,c as f,a as h,p as u,d as p,b as m,f as v,u as d,n as g,l as y,q as E,o as x,G as D,H as k}from"./client.e1fa59dc.js";function w(t){var r=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(t){return!1}}();return function(){var n,i=a(t);if(r){var l=a(this).constructor;n=Reflect.construct(i,arguments,l)}else n=i.apply(this,arguments);return e(this,n)}}function R(t,a,e){var r=t.slice();return r[1]=a[e],r}function b(t){var a,e,r,n=t[1].title+"";return{c:function(){a=s("li"),e=s("a"),r=o(n),this.h()},l:function(t){a=f(t,"LI",{});var i=h(a);e=f(i,"A",{href:!0});var l=h(e);r=u(l,n),l.forEach(p),i.forEach(p),this.h()},h:function(){m(e,"href","examples/"+t[1].path)},m:function(t,n){v(t,a,n),d(a,e),d(e,r)},p:g,d:function(t){t&&p(a)}}}function I(t){for(var a,e,r,n,i,l,c,w,I=t[0].reverse(),L=[],V=0;Ve(2,n=o)),s(o,T,o=>e(3,l=o));const r=i();let p={},c="";return a(()=>{n&&r("ready"),l||(T.set(!0),function(o,t,e){let n=o.length;function s(){n=--n,n<1&&e()}t()?e():o.forEach(({type:o,url:t,options:e={async:!0,defer:!0}})=>{const n="script"===o,i=document.createElement(n?"script":"link");n?(i.src=t,i.async=e.async,i.defer=e.defer):(i.rel="stylesheet",i.href=t),i.onload=s,document.body.appendChild(i)})}([{type:"style",url:"https://unpkg.com/leaflet@1.7.1/dist/leaflet.css"},{type:"script",url:"https://unpkg.com/leaflet@1.7.1/dist/leaflet.js"}],()=>!1,()=>(p=window.L,c=p.map,x.set(!0),!0)))}),o.$$.update=()=>{4&o.$$.dirty&&n&&r("ready")},[]}class v extends t{constructor(o){super(),e(this,o,L,null,n,{})}}const{window:Z}=k;function S(o){let t,e,n,s,i,a;return n=new v({}),n.$on("ready",o[1]),{c(){t=l("div"),e=r(),p(n.$$.fragment),this.h()},l(o){t=c(o,"DIV",{class:!0,id:!0}),d(t).forEach(u),e=m(o),h(n.$$.fragment,o),this.h()},h(){f(t,"class","map svelte-1xdqv5q"),f(t,"id",o[0])},m(l,r){g(l,t,r),o[4](t),g(l,e,r),y(n,l,r),s=!0,i||(a=w(Z,"resize",o[2]),i=!0)},p(o,[e]){(!s||1&e)&&f(t,"id",o[0])},i(o){s||($(n.$$.fragment,o),s=!0)},o(o){b(n.$$.fragment,o),s=!1},d(s){s&&u(t),o[4](null),s&&u(e),z(n,s),i=!1,a()}}}function A(o,t,e){let n={},s="";const a=i();let{options:l}=t,{zoom:r=13,maxZoom:p=19,minZoom:c=1,mapID:d="map",attributionControl:u=!0,center:m=[0,0],markers:h,circles:f,recenter:g=!1,scrollWheelZoom:y=!0,tileLayer:w={url:"https://{s}.tile.openstreetmap.org/{z}/{x}/{y}.png",attribution:'© OpenStreetMap contributors'},controls:$={zoomControl:!0,position:"topleft",scale:!1}}=l;return o.$$set=o=>{"options"in o&&e(3,l=o.options)},[d,function(){setTimeout(()=>{n=window.L,function(){s=n.map(d,{attributionControl:u,zoomControl:$.zoomControl,minZoom:c,maxZoom:p}).setView(m,r),n.tileLayer(w.url,{attribution:w.attribution}).addTo(s),y||s.scrollWheelZoom.disable();let o,t=n.control;$.zoomControl||t().remove();$.scale&&t.scale({position:$.position}).addTo(s);$.zoomControl&&$.position&&(s.removeControl(s.zoomControl),t.zoom({position:$.position}).addTo(s));let e,i=[],a=[],l={iconUrl:"https://unpkg.com/leaflet@1.7.1/dist/images/marker-icon.png",iconRetinaUrl:"https://unpkg.com/leaflet@1.7.1/dist/images/marker-icon-2x.png",shadowUrl:"https://unpkg.com/leaflet@1.7.1/dist/images/marker-shadow.png",iconSize:[25,41],iconAnchor:[12,41],popupAnchor:[1,-34],tooltipAnchor:[1,-34],shadowSize:[41,41]};h&&h.map(t=>{i.push([t.lat,t.lng]),o=t.icon?n.icon(t.icon):n.icon(l);let e=new n.marker([t.lat,t.lng],{icon:o});t.popup&&z(e,t.popup),t.tooltip&&b(e,t.tooltip),e.addTo(s)});f&&f.map(o=>{a.push([o.lat,o.lng]);let t=new n.circle([o.lat,o.lng],{...o});o.popup&&z(t,o.popup),o.tooltip&&b(t,o.tooltip),t.addTo(s)});function b(o,t){o.bindTooltip(t.text,{...t}).addTo(s),t.isOpen&&o.openTooltip()}function z(o,t){o.bindPopup(t.text,{closeOnClick:!1,autoClose:!1,...t}).addTo(s),t.isOpen&&o.openPopup()}g&&(1==i.length?(s.panTo(n.latLng(i[0][0],i[0][1])),s.setZoom(r)):(e=new n.LatLngBounds(i),s.fitBounds(e)))}(),a("ready")},1)},function(){s&&s.invalidateSize()},l,function(o){C[o?"unshift":"push"](()=>{d=o,e(0,d)})}]}class O extends t{constructor(o){super(),e(this,o,A,S,n,{options:3})}}export{O as L}; 2 | -------------------------------------------------------------------------------- /public/client/Leaflet.6481def0.js: -------------------------------------------------------------------------------- 1 | import{w as o,S as t,i as e,s as n,v as s,x as i,y as a,e as l,g as r,h as p,c,a as d,d as u,j as m,l as h,b as f,f as g,o as y,z as w,p as $,r as z,u as b,A as k,B as C}from"./client.47f8a5db.js";const x=o(!1),T=o(!1);function L(o,t,e){let n,l;s(o,x,o=>e(2,n=o)),s(o,T,o=>e(3,l=o));const r=i();let p={},c="";return a(()=>{n&&r("ready"),l||(T.set(!0),function(o,t,e){let n=o.length;function s(){n=--n,n<1&&e()}t()?e():o.forEach(({type:o,url:t,options:e={async:!0,defer:!0}})=>{const n="script"===o,i=document.createElement(n?"script":"link");n?(i.src=t,i.async=e.async,i.defer=e.defer):(i.rel="stylesheet",i.href=t),i.onload=s,document.body.appendChild(i)})}([{type:"style",url:"https://unpkg.com/leaflet@1.7.1/dist/leaflet.css"},{type:"script",url:"https://unpkg.com/leaflet@1.7.1/dist/leaflet.js"}],()=>!1,()=>(p=window.L,c=p.map,x.set(!0),!0)))}),o.$$.update=()=>{4&o.$$.dirty&&n&&r("ready")},[]}class v extends t{constructor(o){super(),e(this,o,L,null,n,{})}}const{window:Z}=k;function S(o){let t,e,n,s,i,a;return n=new v({}),n.$on("ready",o[1]),{c(){t=l("div"),e=r(),p(n.$$.fragment),this.h()},l(o){t=c(o,"DIV",{class:!0,id:!0}),d(t).forEach(u),e=m(o),h(n.$$.fragment,o),this.h()},h(){f(t,"class","map svelte-1xdqv5q"),f(t,"id",o[0])},m(l,r){g(l,t,r),o[4](t),g(l,e,r),y(n,l,r),s=!0,i||(a=w(Z,"resize",o[2]),i=!0)},p(o,[e]){(!s||1&e)&&f(t,"id",o[0])},i(o){s||($(n.$$.fragment,o),s=!0)},o(o){z(n.$$.fragment,o),s=!1},d(s){s&&u(t),o[4](null),s&&u(e),b(n,s),i=!1,a()}}}function A(o,t,e){let n={},s="";const a=i();let{options:l}=t,{zoom:r=13,maxZoom:p=19,minZoom:c=1,mapID:d="map",attributionControl:u=!0,center:m=[0,0],markers:h,circles:f,recenter:g=!1,scrollWheelZoom:y=!0,tileLayer:w={url:"https://{s}.tile.openstreetmap.org/{z}/{x}/{y}.png",attribution:'© OpenStreetMap contributors'},controls:$={zoomControl:!0,position:"topleft",scale:!1}}=l;return o.$$set=o=>{"options"in o&&e(3,l=o.options)},[d,function(){setTimeout(()=>{n=window.L,function(){s=n.map(d,{attributionControl:u,zoomControl:$.zoomControl,minZoom:c,maxZoom:p}).setView(m,r),n.tileLayer(w.url,{attribution:w.attribution}).addTo(s),y||s.scrollWheelZoom.disable();let o,t=n.control;$.zoomControl||t().remove();$.scale&&t.scale({position:$.position}).addTo(s);$.zoomControl&&$.position&&(s.removeControl(s.zoomControl),t.zoom({position:$.position}).addTo(s));let e,i=[],a=[],l={iconUrl:"https://unpkg.com/leaflet@1.7.1/dist/images/marker-icon.png",iconRetinaUrl:"https://unpkg.com/leaflet@1.7.1/dist/images/marker-icon-2x.png",shadowUrl:"https://unpkg.com/leaflet@1.7.1/dist/images/marker-shadow.png",iconSize:[25,41],iconAnchor:[12,41],popupAnchor:[1,-34],tooltipAnchor:[1,-34],shadowSize:[41,41]};h&&h.map(t=>{i.push([t.lat,t.lng]),o=t.icon?n.icon(t.icon):n.icon(l);let e=new n.marker([t.lat,t.lng],{icon:o});t.popup&&b(e,t.popup),t.tooltip&&z(e,t.tooltip),e.addTo(s)});f&&f.map(o=>{a.push([o.lat,o.lng]);let t=new n.circle([o.lat,o.lng],{...o});o.popup&&b(t,o.popup),o.tooltip&&z(t,o.tooltip),t.addTo(s)});function z(o,t){o.bindTooltip(t.text,{...t}).addTo(s),t.isOpen&&o.openTooltip()}function b(o,t){o.bindPopup(t.text,{closeOnClick:!1,autoClose:!1,...t}).addTo(s),t.isOpen&&o.openPopup()}g&&(1==i.length?(s.panTo(n.latLng(i[0][0],i[0][1])),s.setZoom(r)):(e=new n.LatLngBounds(i),s.fitBounds(e)))}(),a("ready")},1)},function(){s&&s.invalidateSize()},l,function(o){C[o?"unshift":"push"](()=>{d=o,e(0,d)})}]}class O extends t{constructor(o){super(),e(this,o,A,S,n,{options:3})}}export{O as L}; 2 | -------------------------------------------------------------------------------- /public/client/Leaflet.764aae6b.js: -------------------------------------------------------------------------------- 1 | import{w as o,S as t,i as e,s as n,v as s,x as i,y as a,e as l,g as r,h as p,c,a as d,d as u,j as m,l as h,b as f,f as g,o as y,z as w,p as $,r as z,u as k,A as C,B as b}from"./client.27f5503e.js";const x=o(!1),T=o(!1);function L(o,t,e){let n,l;s(o,x,o=>e(2,n=o)),s(o,T,o=>e(3,l=o));const r=i();let p={},c="";return a(()=>{n&&r("ready"),l||(T.set(!0),function(o,t,e){let n=o.length;function s(){n=--n,n<1&&e()}t()?e():o.forEach(({type:o,url:t,options:e={async:!0,defer:!0}})=>{const n="script"===o,i=document.createElement(n?"script":"link");n?(i.src=t,i.async=e.async,i.defer=e.defer):(i.rel="stylesheet",i.href=t),i.onload=s,document.body.appendChild(i)})}([{type:"style",url:"https://unpkg.com/leaflet@1.7.1/dist/leaflet.css"},{type:"script",url:"https://unpkg.com/leaflet@1.7.1/dist/leaflet.js"}],()=>!1,()=>(p=window.L,c=p.map,x.set(!0),!0)))}),o.$$.update=()=>{4&o.$$.dirty&&n&&r("ready")},[]}class v extends t{constructor(o){super(),e(this,o,L,null,n,{})}}const{window:Z}=C;function S(o){let t,e,n,s,i,a;return n=new v({}),n.$on("ready",o[1]),{c(){t=l("div"),e=r(),p(n.$$.fragment),this.h()},l(o){t=c(o,"DIV",{class:!0,id:!0}),d(t).forEach(u),e=m(o),h(n.$$.fragment,o),this.h()},h(){f(t,"class","map svelte-1xdqv5q"),f(t,"id",o[0])},m(l,r){g(l,t,r),o[4](t),g(l,e,r),y(n,l,r),s=!0,i||(a=w(Z,"resize",o[2]),i=!0)},p(o,[e]){(!s||1&e)&&f(t,"id",o[0])},i(o){s||($(n.$$.fragment,o),s=!0)},o(o){z(n.$$.fragment,o),s=!1},d(s){s&&u(t),o[4](null),s&&u(e),k(n,s),i=!1,a()}}}function A(o,t,e){let n={},s="";const a=i();let{options:l}=t,{zoom:r=13,maxZoom:p=19,minZoom:c=1,mapID:d="map",attributionControl:u=!0,center:m=[0,0],markers:h,circles:f,recenter:g=!1,scrollWheelZoom:y=!0,tileLayer:w={url:"https://{s}.tile.openstreetmap.org/{z}/{x}/{y}.png",attribution:'© OpenStreetMap contributors'},controls:$={zoomControl:!0,position:"topleft",scale:!1}}=l;return o.$$set=o=>{"options"in o&&e(3,l=o.options)},[d,function(){setTimeout(()=>{n=window.L,function(){s=n.map(d,{attributionControl:u,zoomControl:$.zoomControl,minZoom:c,maxZoom:p}).setView(m,r),n.tileLayer(w.url,{attribution:w.attribution}).addTo(s),y||s.scrollWheelZoom.disable();let o,t=n.control;$.zoomControl||t().remove();$.scale&&t.scale({position:$.position}).addTo(s);$.zoomControl&&$.position&&(s.removeControl(s.zoomControl),t.zoom({position:$.position}).addTo(s));let e,i=[],a=[],l={iconUrl:"https://unpkg.com/leaflet@1.7.1/dist/images/marker-icon.png",iconRetinaUrl:"https://unpkg.com/leaflet@1.7.1/dist/images/marker-icon-2x.png",shadowUrl:"https://unpkg.com/leaflet@1.7.1/dist/images/marker-shadow.png",iconSize:[25,41],iconAnchor:[12,41],popupAnchor:[1,-34],tooltipAnchor:[1,-34],shadowSize:[41,41]};h&&h.map(t=>{i.push([t.lat,t.lng]),o=t.icon?n.icon(t.icon):n.icon(l);let e=new n.marker([t.lat,t.lng],{icon:o});t.popup&&k(e,t.popup),t.tooltip&&z(e,t.tooltip),e.addTo(s)});f&&f.map(o=>{a.push([o.lat,o.lng]);let t=new n.circle([o.lat,o.lng],{...o});o.popup&&k(t,o.popup),o.tooltip&&z(t,o.tooltip),t.addTo(s)});function z(o,t){o.bindTooltip(t.text,{...t}).addTo(s),t.isOpen&&o.openTooltip()}function k(o,t){o.bindPopup(t.text,{closeOnClick:!1,autoClose:!1,...t}).addTo(s),t.isOpen&&o.openPopup()}g&&(1==i.length?(s.panTo(n.latLng(i[0][0],i[0][1])),s.setZoom(r)):(e=new n.LatLngBounds(i),s.fitBounds(e)))}(),a("ready")},1)},function(){s&&s.invalidateSize()},l,function(o){b[o?"unshift":"push"](()=>{d=o,e(0,d)})}]}class O extends t{constructor(o){super(),e(this,o,A,S,n,{options:3})}}export{O as L}; 2 | -------------------------------------------------------------------------------- /public/client/Leaflet.1975f146.js: -------------------------------------------------------------------------------- 1 | import{w as o,S as t,i as e,s as n,v as s,x as a,y as i,e as r,g as l,h as p,c,a as d,d as m,j as u,l as h,b as f,f as g,o as $,z as k,p as y,r as w,u as x,A as z,B as T}from"./client.a52649eb.js";const C=o(!1),b=o(!1);function Z(o,t,e){let n,r;s(o,C,o=>e(2,n=o)),s(o,b,o=>e(3,r=o));const l=a();let p={},c="";return i(()=>{n&&l("ready"),r||(b.set(!0),function(o,t,e){let n=o.length;function s(){n=--n,n<1&&e()}t()?e():o.forEach(({type:o,url:t,options:e={async:!0,defer:!0}})=>{const n="script"===o,a=document.createElement(n?"script":"link");n?(a.src=t,a.async=e.async,a.defer=e.defer):(a.rel="stylesheet",a.href=t),a.onload=s,document.body.appendChild(a)})}([{type:"style",url:"https://unpkg.com/leaflet@1.7.1/dist/leaflet.css"},{type:"script",url:"https://unpkg.com/leaflet@1.7.1/dist/leaflet.js"}],()=>!1,()=>(p=window.L,c=p.map,C.set(!0),!0)))}),o.$$.update=()=>{4&o.$$.dirty&&n&&l("ready")},[]}class L extends t{constructor(o){super(),e(this,o,Z,null,n,{})}}const{window:v}=z;function M(o){let t,e,n,s,a,i;return n=new L({}),n.$on("ready",o[1]),{c(){t=r("div"),e=l(),p(n.$$.fragment),this.h()},l(o){t=c(o,"DIV",{class:!0,id:!0}),d(t).forEach(m),e=u(o),h(n.$$.fragment,o),this.h()},h(){f(t,"class","map svelte-1xdqv5q"),f(t,"id",o[0])},m(r,l){g(r,t,l),o[7](t),g(r,e,l),$(n,r,l),s=!0,a||(i=k(v,"resize",o[2]),a=!0)},p(o,e){(!s||1&e[0])&&f(t,"id",o[0])},i(o){s||(y(n.$$.fragment,o),s=!0)},o(o){w(n.$$.fragment,o),s=!1},d(s){s&&m(t),o[7](null),s&&m(e),x(n,s),a=!1,i()}}}function S(o,t,e){let n={},s="";const i=a();let r,l,{options:p}=t,{zoom:c=13,maxZoom:d=19,minZoom:m=1,mapID:u="map",attributionControl:h=!0,center:f=[0,0],markers:g,circles:$,recenter:k=!1,scrollWheelZoom:y=!0,tilelayers:w=[{url:"https://{s}.tile.openstreetmap.org/{z}/{x}/{y}.png",attribution:'© OpenStreetMap contributors'}],controls:x={zoomControl:!0,position:"topleft",scale:!1}}=p,z=[],C=[],b={iconUrl:"https://unpkg.com/leaflet@1.7.1/dist/images/marker-icon.png",iconRetinaUrl:"https://unpkg.com/leaflet@1.7.1/dist/images/marker-icon-2x.png",shadowUrl:"https://unpkg.com/leaflet@1.7.1/dist/images/marker-shadow.png",iconSize:[25,41],iconAnchor:[12,41],popupAnchor:[1,-34],tooltipAnchor:[1,-34],shadowSize:[41,41]};function Z(o,t){o.bindPopup(t.text,{closeOnClick:!1,autoClose:!1,...t}).addTo(s),t.isOpen&&o.openPopup()}function L(o,t){o.bindTooltip(t.text,{...t}).addTo(s),t.isOpen&&o.openTooltip()}let v=[];const M=o=>{o.markers.map((o,t)=>{o.icon&&(r=n.icon(o.icon)),v[t]=new n.marker([o.lat,o.lng],{icon:r}).addTo(s),o.popup&&Z(v[t],o.popup),o.tooltip&&L(v[t],o.tooltip)})};let S=!1;return o.$$set=o=>{"options"in o&&e(3,p=o.options)},[u,function(){setTimeout(()=>{n=window.L,function(){s=n.map(u,{attributionControl:h,zoomControl:x.zoomControl,minZoom:m,maxZoom:d}).setView(f,c),v=n.marker([0,0]),w&&w.map(o=>{n.tileLayer(o.url,{...o}).addTo(s)});y||s.scrollWheelZoom.disable();let o=n.control;x.zoomControl||o().remove();x.scale&&o.scale({position:x.position}).addTo(s);x.zoomControl&&x.position&&(s.removeControl(s.zoomControl),o.zoom({position:x.position}).addTo(s));g&&g.map(o=>{z.push([o.lat,o.lng]),r=o.icon?n.icon(o.icon):n.icon(b);let t=new n.marker([o.lat,o.lng],{icon:r});o.popup&&Z(t,o.popup),o.tooltip&&L(t,o.tooltip),t.addTo(s)});$&&$.map(o=>{C.push([o.lat,o.lng]);let t=new n.circle([o.lat,o.lng],{...o});o.popup&&Z(t,o.popup),o.tooltip&&L(t,o.tooltip),t.addTo(s)});k&&(1==z.length?(s.panTo(n.latLng(z[0][0],z[0][1])),s.setZoom(c)):(l=new n.LatLngBounds(z),s.fitBounds(l)))}(),i("ready")},1)},function(){s&&s.invalidateSize()},p,M,o=>{S||(M(o),S=!0),o.markers.map((o,t)=>{v[t].setLatLng(o).update(),v[t].addTo(s)})},(o=5)=>{s.setZoom(o)},function(o){T[o?"unshift":"push"](()=>{u=o,e(0,u)})}]}class A extends t{constructor(o){super(),e(this,o,S,M,n,{options:3,addMarker:4,updateMarkers:5,setZoom:6},[-1,-1])}get addMarker(){return this.$$.ctx[4]}get updateMarkers(){return this.$$.ctx[5]}get setZoom(){return this.$$.ctx[6]}}export{A as L}; 2 | -------------------------------------------------------------------------------- /public/client/Leaflet.399e6cc7.js: -------------------------------------------------------------------------------- 1 | import{w as o,S as t,i as e,s as n,v as s,x as a,y as i,e as r,g as l,h as p,c,a as d,d as m,j as u,l as h,b as f,f as g,o as $,z as k,p as y,r as w,u as x,A as z,B as T}from"./client.cad504f2.js";const C=o(!1),Z=o(!1);function b(o,t,e){let n,r;s(o,C,o=>e(2,n=o)),s(o,Z,o=>e(3,r=o));const l=a();let p={},c="";return i(()=>{n&&l("ready"),r||(Z.set(!0),function(o,t,e){let n=o.length;function s(){n=--n,n<1&&e()}t()?e():o.forEach(({type:o,url:t,options:e={async:!0,defer:!0}})=>{const n="script"===o,a=document.createElement(n?"script":"link");n?(a.src=t,a.async=e.async,a.defer=e.defer):(a.rel="stylesheet",a.href=t),a.onload=s,document.body.appendChild(a)})}([{type:"style",url:"https://unpkg.com/leaflet@1.7.1/dist/leaflet.css"},{type:"script",url:"https://unpkg.com/leaflet@1.7.1/dist/leaflet.js"}],()=>!1,()=>(p=window.L,c=p.map,C.set(!0),!0)))}),o.$$.update=()=>{4&o.$$.dirty&&n&&l("ready")},[]}class L extends t{constructor(o){super(),e(this,o,b,null,n,{})}}const{window:v}=z;function M(o){let t,e,n,s,a,i;return n=new L({}),n.$on("ready",o[1]),{c(){t=r("div"),e=l(),p(n.$$.fragment),this.h()},l(o){t=c(o,"DIV",{class:!0,id:!0}),d(t).forEach(m),e=u(o),h(n.$$.fragment,o),this.h()},h(){f(t,"class","map svelte-1xdqv5q"),f(t,"id",o[0])},m(r,l){g(r,t,l),o[7](t),g(r,e,l),$(n,r,l),s=!0,a||(i=k(v,"resize",o[2]),a=!0)},p(o,e){(!s||1&e[0])&&f(t,"id",o[0])},i(o){s||(y(n.$$.fragment,o),s=!0)},o(o){w(n.$$.fragment,o),s=!1},d(s){s&&m(t),o[7](null),s&&m(e),x(n,s),a=!1,i()}}}function S(o,t,e){let n={},s="";const i=a();let r,l,{options:p}=t,{zoom:c=13,maxZoom:d=19,minZoom:m=1,mapID:u="map",attributionControl:h=!0,center:f=[0,0],markers:g,circles:$,recenter:k=!1,scrollWheelZoom:y=!0,tilelayers:w=[{url:"https://{s}.tile.openstreetmap.org/{z}/{x}/{y}.png",attribution:'© OpenStreetMap contributors'}],controls:x={zoomControl:!0,position:"topleft",scale:!1}}=p,z=[],C=[],Z={iconUrl:"https://unpkg.com/leaflet@1.7.1/dist/images/marker-icon.png",iconRetinaUrl:"https://unpkg.com/leaflet@1.7.1/dist/images/marker-icon-2x.png",shadowUrl:"https://unpkg.com/leaflet@1.7.1/dist/images/marker-shadow.png",iconSize:[25,41],iconAnchor:[12,41],popupAnchor:[1,-34],tooltipAnchor:[1,-34],shadowSize:[41,41]};function b(o,t){o.bindPopup(t.text,{closeOnClick:!1,autoClose:!1,...t}).addTo(s),t.isOpen&&o.openPopup()}function L(o,t){o.bindTooltip(t.text,{...t}).addTo(s),t.isOpen&&o.openTooltip()}let v=[];const M=o=>{o.markers.map((o,t)=>{o.icon&&(r=n.icon(o.icon)),v[t]=new n.marker([o.lat,o.lng],{icon:r}).addTo(s),o.popup&&b(v[t],o.popup),o.tooltip&&L(v[t],o.tooltip)})};let S=!1;return o.$$set=o=>{"options"in o&&e(3,p=o.options)},[u,function(){setTimeout(()=>{n=window.L,function(){s=n.map(u,{attributionControl:h,zoomControl:x.zoomControl,minZoom:m,maxZoom:d}).setView(f,c),v=n.marker([0,0]),w&&w.map(o=>{n.tileLayer(o.url,{...o}).addTo(s)});y||s.scrollWheelZoom.disable();let o=n.control;x.zoomControl||o().remove();x.scale&&o.scale({position:x.position}).addTo(s);x.zoomControl&&x.position&&(s.removeControl(s.zoomControl),o.zoom({position:x.position}).addTo(s));g&&g.map(o=>{z.push([o.lat,o.lng]),r=o.icon?n.icon(o.icon):n.icon(Z);let t=new n.marker([o.lat,o.lng],{icon:r});o.popup&&b(t,o.popup),o.tooltip&&L(t,o.tooltip),t.addTo(s)});$&&$.map(o=>{C.push([o.lat,o.lng]);let t=new n.circle([o.lat,o.lng],{...o});o.popup&&b(t,o.popup),o.tooltip&&L(t,o.tooltip),t.addTo(s)});k&&(1==z.length?(s.panTo(n.latLng(z[0][0],z[0][1])),s.setZoom(c)):(l=new n.LatLngBounds(z),s.fitBounds(l)))}(),i("ready")},1)},function(){s&&s.invalidateSize()},p,M,o=>{S||(M(o),S=!0),o.markers.map((o,t)=>{v[t].setLatLng(o).update(),v[t].addTo(s)})},(o=5)=>{s.setZoom(o)},function(o){T[o?"unshift":"push"](()=>{u=o,e(0,u)})}]}class A extends t{constructor(o){super(),e(this,o,S,M,n,{options:3,addMarker:4,updateMarkers:5,setZoom:6},[-1,-1])}get addMarker(){return this.$$.ctx[4]}get updateMarkers(){return this.$$.ctx[5]}get setZoom(){return this.$$.ctx[6]}}export{A as L}; 2 | -------------------------------------------------------------------------------- /public/misc/index.html: -------------------------------------------------------------------------------- 1 | Miscellaneous Settings

Miscellaneous Settings

Covers additional customization of the map view this example has no markers, markers options can be omitted if you just need the map. You could set the attributionControl false to remove Attribution

controls can be placed in the following locations the scale assumes the positions along with the zoom controls. Valid positions are topleft', 'topright', 'bottomleft' or 'bottomright'
the control position can only be set by setting zoomControl: false

Example

let options = {
 2 |     zoom: 13,
 3 |     maxZoom: 19,
 4 |     minZoom: 1,
 5 |     controls: {
 6 |       zoomControl: true,
 7 |       position: "bottomright",
 8 |       scale: true,
 9 |     },
10 |     center: [13, 80],
11 |     mapID: "map",
12 |     attributionControl: false,
13 |   };

Other existing libraries and Acreditation

-------------------------------------------------------------------------------- /public/index.html: -------------------------------------------------------------------------------- 1 | Home Quick Start with leaflet on Svelte

Quick Start

Svelte wrapper for leaflet. To use in svelte. For bugs and suggestions please file issue here

npm i @anoram/leaflet-svelte

Have <Map options={options}/> a child of a div and supply custom css for height/width.

Minimal Example

<script>
 2 | import Map from '@anoram/leaflet-svelte'
 3 | let options={
 4 |   center: [13,80],
 5 |   markers: [
 6 |     {
 7 |       lat: 13,
 8 |       lng: 80
 9 |     }
10 |   ],
11 |   mapID: "map"
12 | }
13 | </script>
14 | <style>
15 |   .map {
16 |     height: 600px;
17 |     width: auto;
18 |   }
19 | </style>
20 | <div class="map">
21 |   <Map {options} />
22 | </div>

mapID is unique like if you are planning to use multiple maps on the same page consider having different mapID

-------------------------------------------------------------------------------- /public/client/legacy/Leaflet.5c215536.js: -------------------------------------------------------------------------------- 1 | import{z as t,i as o,s as e,S as n,A as r,B as i,C as a,e as c,l as s,m as l,c as u,a as p,d as f,o as m,r as d,b as h,f as v,v as y,D as b,w as g,x as w,y as O,E as C,F as z}from"./client.9c8a37b7.js";import $ from"@babel/runtime/helpers/esm/classCallCheck";import k from"@babel/runtime/helpers/esm/assertThisInitialized";import P from"@babel/runtime/helpers/esm/inherits";import j from"@babel/runtime/helpers/esm/possibleConstructorReturn";import T from"@babel/runtime/helpers/esm/getPrototypeOf";import R from"@babel/runtime/helpers/esm/defineProperty";import x from"@babel/runtime/helpers/esm/slicedToArray";var D=t(!1),S=t(!1);function L(t){var o=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(t){return!1}}();return function(){var e,n=T(t);if(o){var r=T(this).constructor;e=Reflect.construct(n,arguments,r)}else e=n.apply(this,arguments);return j(this,e)}}function Z(t,o,e){var n,c;r(t,D,(function(t){return e(2,n=t)})),r(t,S,(function(t){return e(3,c=t)}));var s=i(),l={};return a((function(){n&&s("ready"),c||(S.set(!0),function(t,o,e){var n=t.length;function r(){(n=--n)<1&&e()}o()?e():t.forEach((function(t){var o=t.type,e=t.url,n=t.options,i=void 0===n?{async:!0,defer:!0}:n,a="script"===o,c=document.createElement(a?"script":"link");a?(c.src=e,c.async=i.async,c.defer=i.defer):(c.rel="stylesheet",c.href=e),c.onload=r,document.body.appendChild(c)}))}([{type:"style",url:"https://unpkg.com/leaflet@1.7.1/dist/leaflet.css"},{type:"script",url:"https://unpkg.com/leaflet@1.7.1/dist/leaflet.js"}],(function(){return!1}),(function(){return l=window.L,l.map,D.set(!0),!0})))})),t.$$.update=function(){4&t.$$.dirty&&n&&s("ready")},[]}var E=function(t){P(i,n);var r=L(i);function i(t){var n;return $(this,i),n=r.call(this),o(k(n),t,Z,null,e,{}),n}return i}();function A(t){var o=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(t){return!1}}();return function(){var e,n=T(t);if(o){var r=T(this).constructor;e=Reflect.construct(n,arguments,r)}else e=n.apply(this,arguments);return j(this,e)}}function B(t,o){var e=Object.keys(t);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(t);o&&(n=n.filter((function(o){return Object.getOwnPropertyDescriptor(t,o).enumerable}))),e.push.apply(e,n)}return e}function I(t){for(var o=1;oOpenStreetMap contributors'}:T,x=s.controls,D=void 0===x?{zoomControl:!0,position:"topleft",scale:!1}:x;return t.$$set=function(t){"options"in t&&e(3,c=t.options)},[v,function(){setTimeout((function(){n=window.L,function(){r=n.map(v,{attributionControl:b,zoomControl:D.zoomControl,minZoom:d,maxZoom:f}).setView(w,u),n.tileLayer(R.url,{attribution:R.attribution}).addTo(r),j||r.scrollWheelZoom.disable();var t,o=n.control;D.zoomControl||o().remove();D.scale&&o.scale({position:D.position}).addTo(r);D.zoomControl&&D.position&&(r.removeControl(r.zoomControl),o.zoom({position:D.position}).addTo(r));var e,i=[],a=[],c={iconUrl:"https://unpkg.com/leaflet@1.7.1/dist/images/marker-icon.png",iconRetinaUrl:"https://unpkg.com/leaflet@1.7.1/dist/images/marker-icon-2x.png",shadowUrl:"https://unpkg.com/leaflet@1.7.1/dist/images/marker-shadow.png",iconSize:[25,41],iconAnchor:[12,41],popupAnchor:[1,-34],tooltipAnchor:[1,-34],shadowSize:[41,41]};O&&O.map((function(o){i.push([o.lat,o.lng]),t=o.icon?n.icon(o.icon):n.icon(c);var e=new n.marker([o.lat,o.lng],{icon:t});o.popup&&l(e,o.popup),o.tooltip&&s(e,o.tooltip),e.addTo(r)}));C&&C.map((function(t){a.push([t.lat,t.lng]);var o=new n.circle([t.lat,t.lng],I({},t));t.popup&&l(o,t.popup),t.tooltip&&s(o,t.tooltip),o.addTo(r)}));function s(t,o){t.bindTooltip(o.text,I({},o)).addTo(r),o.isOpen&&t.openTooltip()}function l(t,o){t.bindPopup(o.text,I({closeOnClick:!1,autoClose:!1},o)).addTo(r),o.isOpen&&t.openPopup()}k&&(1==i.length?(r.panTo(n.latLng(i[0][0],i[0][1])),r.setZoom(u)):(e=new n.LatLngBounds(i),r.fitBounds(e)))}(),a("ready")}),1)},function(){r&&r.invalidateSize()},c,function(t){z[t?"unshift":"push"]((function(){e(0,v=t)}))}]}var W=function(t){P(i,n);var r=A(i);function i(t){var n;return $(this,i),n=r.call(this),o(k(n),t,V,q,e,{options:3}),n}return i}();export{W as L}; 2 | -------------------------------------------------------------------------------- /public/client/legacy/Leaflet.b4123ade.js: -------------------------------------------------------------------------------- 1 | import{z as t,i as o,s as e,S as n,A as r,B as i,C as a,e as s,l as c,m as l,c as u,a as p,d as f,o as m,r as d,b as h,f as v,v as y,D as b,w as g,x as w,y as O,E as C,F as z}from"./client.552f27ae.js";import $ from"@babel/runtime/helpers/esm/classCallCheck";import k from"@babel/runtime/helpers/esm/assertThisInitialized";import P from"@babel/runtime/helpers/esm/inherits";import j from"@babel/runtime/helpers/esm/possibleConstructorReturn";import T from"@babel/runtime/helpers/esm/getPrototypeOf";import R from"@babel/runtime/helpers/esm/defineProperty";import x from"@babel/runtime/helpers/esm/slicedToArray";var D=t(!1),S=t(!1);function L(t){var o=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(t){return!1}}();return function(){var e,n=T(t);if(o){var r=T(this).constructor;e=Reflect.construct(n,arguments,r)}else e=n.apply(this,arguments);return j(this,e)}}function Z(t,o,e){var n,s;r(t,D,(function(t){return e(2,n=t)})),r(t,S,(function(t){return e(3,s=t)}));var c=i(),l={};return a((function(){n&&c("ready"),s||(S.set(!0),function(t,o,e){var n=t.length;function r(){(n=--n)<1&&e()}o()?e():t.forEach((function(t){var o=t.type,e=t.url,n=t.options,i=void 0===n?{async:!0,defer:!0}:n,a="script"===o,s=document.createElement(a?"script":"link");a?(s.src=e,s.async=i.async,s.defer=i.defer):(s.rel="stylesheet",s.href=e),s.onload=r,document.body.appendChild(s)}))}([{type:"style",url:"https://unpkg.com/leaflet@1.7.1/dist/leaflet.css"},{type:"script",url:"https://unpkg.com/leaflet@1.7.1/dist/leaflet.js"}],(function(){return!1}),(function(){return l=window.L,l.map,D.set(!0),!0})))})),t.$$.update=function(){4&t.$$.dirty&&n&&c("ready")},[]}var E=function(t){P(i,n);var r=L(i);function i(t){var n;return $(this,i),n=r.call(this),o(k(n),t,Z,null,e,{}),n}return i}();function A(t){var o=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(t){return!1}}();return function(){var e,n=T(t);if(o){var r=T(this).constructor;e=Reflect.construct(n,arguments,r)}else e=n.apply(this,arguments);return j(this,e)}}function B(t,o){var e=Object.keys(t);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(t);o&&(n=n.filter((function(o){return Object.getOwnPropertyDescriptor(t,o).enumerable}))),e.push.apply(e,n)}return e}function I(t){for(var o=1;oOpenStreetMap contributors'}:T,x=c.controls,D=void 0===x?{zoomControl:!0,position:"topleft",scale:!1}:x;return t.$$set=function(t){"options"in t&&e(3,s=t.options)},[v,function(){setTimeout((function(){n=window.L,function(){r=n.map(v,{attributionControl:b,zoomControl:D.zoomControl,minZoom:d,maxZoom:f}).setView(w,u),n.tileLayer(R.url,{attribution:R.attribution}).addTo(r),j||r.scrollWheelZoom.disable();var t,o=n.control;D.zoomControl||o().remove();D.scale&&o.scale({position:D.position}).addTo(r);D.zoomControl&&D.position&&(r.removeControl(r.zoomControl),o.zoom({position:D.position}).addTo(r));var e,i=[],a=[],s={iconUrl:"https://unpkg.com/leaflet@1.7.1/dist/images/marker-icon.png",iconRetinaUrl:"https://unpkg.com/leaflet@1.7.1/dist/images/marker-icon-2x.png",shadowUrl:"https://unpkg.com/leaflet@1.7.1/dist/images/marker-shadow.png",iconSize:[25,41],iconAnchor:[12,41],popupAnchor:[1,-34],tooltipAnchor:[1,-34],shadowSize:[41,41]};O&&O.map((function(o){i.push([o.lat,o.lng]),t=o.icon?n.icon(o.icon):n.icon(s);var e=new n.marker([o.lat,o.lng],{icon:t});o.popup&&l(e,o.popup),o.tooltip&&c(e,o.tooltip),e.addTo(r)}));C&&C.map((function(t){a.push([t.lat,t.lng]);var o=new n.circle([t.lat,t.lng],I({},t));t.popup&&l(o,t.popup),t.tooltip&&c(o,t.tooltip),o.addTo(r)}));function c(t,o){t.bindTooltip(o.text,I({},o)).addTo(r),o.isOpen&&t.openTooltip()}function l(t,o){t.bindPopup(o.text,I({closeOnClick:!1,autoClose:!1},o)).addTo(r),o.isOpen&&t.openPopup()}k&&(1==i.length?(r.panTo(n.latLng(i[0][0],i[0][1])),r.setZoom(u)):(e=new n.LatLngBounds(i),r.fitBounds(e)))}(),a("ready")}),1)},function(){r&&r.invalidateSize()},s,function(t){z[t?"unshift":"push"]((function(){e(0,v=t)}))}]}var W=function(t){P(i,n);var r=A(i);function i(t){var n;return $(this,i),n=r.call(this),o(k(n),t,V,q,e,{options:3}),n}return i}();export{W as L}; 2 | -------------------------------------------------------------------------------- /public/client/legacy/Leaflet.fd83408e.js: -------------------------------------------------------------------------------- 1 | import{z as t,i as o,s as e,S as n,A as r,B as i,C as a,e as s,l as c,m as l,c as u,a as p,d as f,o as m,r as d,b as h,f as v,v as y,D as b,w as g,x as w,y as O,E as C,F as z}from"./client.48d5e9eb.js";import $ from"@babel/runtime/helpers/esm/classCallCheck";import k from"@babel/runtime/helpers/esm/assertThisInitialized";import P from"@babel/runtime/helpers/esm/inherits";import j from"@babel/runtime/helpers/esm/possibleConstructorReturn";import T from"@babel/runtime/helpers/esm/getPrototypeOf";import R from"@babel/runtime/helpers/esm/defineProperty";import x from"@babel/runtime/helpers/esm/slicedToArray";var D=t(!1),S=t(!1);function L(t){var o=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(t){return!1}}();return function(){var e,n=T(t);if(o){var r=T(this).constructor;e=Reflect.construct(n,arguments,r)}else e=n.apply(this,arguments);return j(this,e)}}function Z(t,o,e){var n,s;r(t,D,(function(t){return e(2,n=t)})),r(t,S,(function(t){return e(3,s=t)}));var c=i(),l={};return a((function(){n&&c("ready"),s||(S.set(!0),function(t,o,e){var n=t.length;function r(){(n=--n)<1&&e()}o()?e():t.forEach((function(t){var o=t.type,e=t.url,n=t.options,i=void 0===n?{async:!0,defer:!0}:n,a="script"===o,s=document.createElement(a?"script":"link");a?(s.src=e,s.async=i.async,s.defer=i.defer):(s.rel="stylesheet",s.href=e),s.onload=r,document.body.appendChild(s)}))}([{type:"style",url:"https://unpkg.com/leaflet@1.7.1/dist/leaflet.css"},{type:"script",url:"https://unpkg.com/leaflet@1.7.1/dist/leaflet.js"}],(function(){return!1}),(function(){return l=window.L,l.map,D.set(!0),!0})))})),t.$$.update=function(){4&t.$$.dirty&&n&&c("ready")},[]}var E=function(t){P(i,n);var r=L(i);function i(t){var n;return $(this,i),n=r.call(this),o(k(n),t,Z,null,e,{}),n}return i}();function A(t){var o=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(t){return!1}}();return function(){var e,n=T(t);if(o){var r=T(this).constructor;e=Reflect.construct(n,arguments,r)}else e=n.apply(this,arguments);return j(this,e)}}function B(t,o){var e=Object.keys(t);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(t);o&&(n=n.filter((function(o){return Object.getOwnPropertyDescriptor(t,o).enumerable}))),e.push.apply(e,n)}return e}function I(t){for(var o=1;oOpenStreetMap contributors'}:T,x=c.controls,D=void 0===x?{zoomControl:!0,position:"topleft",scale:!1}:x;return t.$$set=function(t){"options"in t&&e(3,s=t.options)},[v,function(){setTimeout((function(){n=window.L,function(){r=n.map(v,{attributionControl:b,zoomControl:D.zoomControl,minZoom:d,maxZoom:f}).setView(w,u),n.tileLayer(R.url,{attribution:R.attribution}).addTo(r),j||r.scrollWheelZoom.disable();var t,o=n.control;D.zoomControl||o().remove();D.scale&&o.scale({position:D.position}).addTo(r);D.zoomControl&&D.position&&(r.removeControl(r.zoomControl),o.zoom({position:D.position}).addTo(r));var e,i=[],a=[],s={iconUrl:"https://unpkg.com/leaflet@1.7.1/dist/images/marker-icon.png",iconRetinaUrl:"https://unpkg.com/leaflet@1.7.1/dist/images/marker-icon-2x.png",shadowUrl:"https://unpkg.com/leaflet@1.7.1/dist/images/marker-shadow.png",iconSize:[25,41],iconAnchor:[12,41],popupAnchor:[1,-34],tooltipAnchor:[1,-34],shadowSize:[41,41]};O&&O.map((function(o){i.push([o.lat,o.lng]),t=o.icon?n.icon(o.icon):n.icon(s);var e=new n.marker([o.lat,o.lng],{icon:t});o.popup&&l(e,o.popup),o.tooltip&&c(e,o.tooltip),e.addTo(r)}));C&&C.map((function(t){a.push([t.lat,t.lng]);var o=new n.circle([t.lat,t.lng],I({},t));t.popup&&l(o,t.popup),t.tooltip&&c(o,t.tooltip),o.addTo(r)}));function c(t,o){t.bindTooltip(o.text,I({},o)).addTo(r),o.isOpen&&t.openTooltip()}function l(t,o){t.bindPopup(o.text,I({closeOnClick:!1,autoClose:!1},o)).addTo(r),o.isOpen&&t.openPopup()}k&&(1==i.length?(r.panTo(n.latLng(i[0][0],i[0][1])),r.setZoom(u)):(e=new n.LatLngBounds(i),r.fitBounds(e)))}(),a("ready")}),1)},function(){r&&r.invalidateSize()},s,function(t){z[t?"unshift":"push"]((function(){e(0,v=t)}))}]}var W=function(t){P(i,n);var r=A(i);function i(t){var n;return $(this,i),n=r.call(this),o(k(n),t,V,q,e,{options:3}),n}return i}();export{W as L}; 2 | -------------------------------------------------------------------------------- /src/Leaflet.svelte: -------------------------------------------------------------------------------- 1 | 211 | 212 | 213 | 214 |
215 | 216 | 217 | 218 | 224 | -------------------------------------------------------------------------------- /public/examples/autocenter/index.html: -------------------------------------------------------------------------------- 1 | Multiple markers that are far apart
←Examples

Multiple markers that are far apart @0.0.4^

Recenter and set map view to center of both the locations or a set of markers.

<script>
 2 |   import Map from "@anoram/leaflet-svelte";
 3 |    let options = {
 4 |     recenter: true,
 5 |     markers: [
 6 |       {
 7 |         lat: 1,
 8 |         lng: 1,
 9 |       },
10 |       {
11 |         lat: 13,
12 |         lng: 80,
13 |       },
14 |     ],
15 |     mapID: "map",
16 | 
17 |   };
18 |   
19 | </script>
20 | 
21 | <style>
22 |   .map {
23 |     height: 600px;
24 |     width: auto;
25 |   }
26 | 
27 | </style>
28 | 
29 | 
30 | <div class="map">
31 |   <Map {options} />
32 | </div>

Note

recenter by default is false, setting it to true and maxZoom/minZoom values will not work, however if you give value for zoom it will reset and zoom the map as far as it can go and have all markers in the view.

-------------------------------------------------------------------------------- /public/client/legacy/Leaflet.6f0b781f.js: -------------------------------------------------------------------------------- 1 | import{z as t,i as o,s as e,S as n,A as r,B as i,C as a,e as c,l as s,m as u,c as p,a as l,d as f,o as m,r as d,b as h,f as v,v as y,D as g,w as b,x as k,y as w,E as O,F as $}from"./client.e1fa59dc.js";import C from"@babel/runtime/helpers/esm/classCallCheck";import z from"@babel/runtime/helpers/esm/createClass";import x from"@babel/runtime/helpers/esm/assertThisInitialized";import P from"@babel/runtime/helpers/esm/inherits";import T from"@babel/runtime/helpers/esm/possibleConstructorReturn";import j from"@babel/runtime/helpers/esm/getPrototypeOf";import R from"@babel/runtime/helpers/esm/defineProperty";var D=t(!1),Z=t(!1);function L(t){var o=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(t){return!1}}();return function(){var e,n=j(t);if(o){var r=j(this).constructor;e=Reflect.construct(n,arguments,r)}else e=n.apply(this,arguments);return T(this,e)}}function S(t,o,e){var n,c;r(t,D,(function(t){return e(2,n=t)})),r(t,Z,(function(t){return e(3,c=t)}));var s=i(),u={};return a((function(){n&&s("ready"),c||(Z.set(!0),function(t,o,e){var n=t.length;function r(){(n=--n)<1&&e()}o()?e():t.forEach((function(t){var o=t.type,e=t.url,n=t.options,i=void 0===n?{async:!0,defer:!0}:n,a="script"===o,c=document.createElement(a?"script":"link");a?(c.src=e,c.async=i.async,c.defer=i.defer):(c.rel="stylesheet",c.href=e),c.onload=r,document.body.appendChild(c)}))}([{type:"style",url:"https://unpkg.com/leaflet@1.7.1/dist/leaflet.css"},{type:"script",url:"https://unpkg.com/leaflet@1.7.1/dist/leaflet.js"}],(function(){return!1}),(function(){return u=window.L,u.map,D.set(!0),!0})))})),t.$$.update=function(){4&t.$$.dirty&&n&&s("ready")},[]}var E=function(t){P(i,n);var r=L(i);function i(t){var n;return C(this,i),n=r.call(this),o(x(n),t,S,null,e,{}),n}return i}();function M(t){var o=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(t){return!1}}();return function(){var e,n=j(t);if(o){var r=j(this).constructor;e=Reflect.construct(n,arguments,r)}else e=n.apply(this,arguments);return T(this,e)}}function A(t,o){var e=Object.keys(t);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(t);o&&(n=n.filter((function(o){return Object.getOwnPropertyDescriptor(t,o).enumerable}))),e.push.apply(e,n)}return e}function B(t){for(var o=1;oOpenStreetMap contributors'}]:R,Z=p.controls,L=void 0===Z?{zoomControl:!0,position:"topleft",scale:!1}:Z,S=[],E=[],M={iconUrl:"https://unpkg.com/leaflet@1.7.1/dist/images/marker-icon.png",iconRetinaUrl:"https://unpkg.com/leaflet@1.7.1/dist/images/marker-icon-2x.png",shadowUrl:"https://unpkg.com/leaflet@1.7.1/dist/images/marker-shadow.png",iconSize:[25,41],iconAnchor:[12,41],popupAnchor:[1,-34],tooltipAnchor:[1,-34],shadowSize:[41,41]};function A(t,o){t.bindPopup(o.text,B({closeOnClick:!1,autoClose:!1},o)).addTo(c),o.isOpen&&t.openPopup()}function I(t,o){t.bindTooltip(o.text,B({},o)).addTo(c),o.isOpen&&t.openTooltip()}var U=[],q=function(t){t.markers.map((function(t,o){t.icon&&(n=a.icon(t.icon)),U[o]=new a.marker([t.lat,t.lng],{icon:n}).addTo(c),t.popup&&A(U[o],t.popup),t.tooltip&&I(U[o],t.tooltip)}))},V=!1;return t.$$set=function(t){"options"in t&&e(3,u=t.options)},[g,function(){setTimeout((function(){a=window.L,function(){c=a.map(g,{attributionControl:k,zoomControl:L.zoomControl,minZoom:v,maxZoom:d}).setView(O,f),U=a.marker([0,0]),D&&D.map((function(t){a.tileLayer(t.url,B({},t)).addTo(c)}));j||c.scrollWheelZoom.disable();var t=a.control;L.zoomControl||t().remove();L.scale&&t.scale({position:L.position}).addTo(c);L.zoomControl&&L.position&&(c.removeControl(c.zoomControl),t.zoom({position:L.position}).addTo(c));C&&C.map((function(t){S.push([t.lat,t.lng]),n=t.icon?a.icon(t.icon):a.icon(M);var o=new a.marker([t.lat,t.lng],{icon:n});t.popup&&A(o,t.popup),t.tooltip&&I(o,t.tooltip),o.addTo(c)}));z&&z.map((function(t){E.push([t.lat,t.lng]);var o=new a.circle([t.lat,t.lng],B({},t));t.popup&&A(o,t.popup),t.tooltip&&I(o,t.tooltip),o.addTo(c)}));P&&(1==S.length?(c.panTo(a.latLng(S[0][0],S[0][1])),c.setZoom(f)):(r=new a.LatLngBounds(S),c.fitBounds(r)))}(),s("ready")}),1)},function(){c&&c.invalidateSize()},u,q,function(t){V||(q(t),V=!0),t.markers.map((function(t,o){U[o].setLatLng(t).update(),U[o].addTo(c)}))},function(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:5;c.setZoom(t)},function(t){$[t?"unshift":"push"]((function(){e(0,g=t)}))}]}var V=function(t){P(i,n);var r=M(i);function i(t){var n;return C(this,i),n=r.call(this),o(x(n),t,q,U,e,{options:3,addMarker:4,updateMarkers:5,setZoom:6},[-1,-1]),n}return z(i,[{key:"addMarker",get:function(){return this.$$.ctx[4]}},{key:"updateMarkers",get:function(){return this.$$.ctx[5]}},{key:"setZoom",get:function(){return this.$$.ctx[6]}}]),i}();export{V as L}; 2 | -------------------------------------------------------------------------------- /public/client/legacy/Leaflet.de470149.js: -------------------------------------------------------------------------------- 1 | import{z as t,i as o,s as e,S as n,A as r,B as i,C as a,e as c,l as s,m as u,c as p,a as l,d as f,o as m,r as d,b as h,f as v,v as y,D as g,w as b,x as k,y as w,E as O,F as $}from"./client.f81d29d5.js";import C from"@babel/runtime/helpers/esm/classCallCheck";import z from"@babel/runtime/helpers/esm/createClass";import x from"@babel/runtime/helpers/esm/assertThisInitialized";import P from"@babel/runtime/helpers/esm/inherits";import T from"@babel/runtime/helpers/esm/possibleConstructorReturn";import j from"@babel/runtime/helpers/esm/getPrototypeOf";import R from"@babel/runtime/helpers/esm/defineProperty";var D=t(!1),Z=t(!1);function L(t){var o=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(t){return!1}}();return function(){var e,n=j(t);if(o){var r=j(this).constructor;e=Reflect.construct(n,arguments,r)}else e=n.apply(this,arguments);return T(this,e)}}function S(t,o,e){var n,c;r(t,D,(function(t){return e(2,n=t)})),r(t,Z,(function(t){return e(3,c=t)}));var s=i(),u={};return a((function(){n&&s("ready"),c||(Z.set(!0),function(t,o,e){var n=t.length;function r(){(n=--n)<1&&e()}o()?e():t.forEach((function(t){var o=t.type,e=t.url,n=t.options,i=void 0===n?{async:!0,defer:!0}:n,a="script"===o,c=document.createElement(a?"script":"link");a?(c.src=e,c.async=i.async,c.defer=i.defer):(c.rel="stylesheet",c.href=e),c.onload=r,document.body.appendChild(c)}))}([{type:"style",url:"https://unpkg.com/leaflet@1.7.1/dist/leaflet.css"},{type:"script",url:"https://unpkg.com/leaflet@1.7.1/dist/leaflet.js"}],(function(){return!1}),(function(){return u=window.L,u.map,D.set(!0),!0})))})),t.$$.update=function(){4&t.$$.dirty&&n&&s("ready")},[]}var E=function(t){P(i,n);var r=L(i);function i(t){var n;return C(this,i),n=r.call(this),o(x(n),t,S,null,e,{}),n}return i}();function M(t){var o=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(t){return!1}}();return function(){var e,n=j(t);if(o){var r=j(this).constructor;e=Reflect.construct(n,arguments,r)}else e=n.apply(this,arguments);return T(this,e)}}function A(t,o){var e=Object.keys(t);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(t);o&&(n=n.filter((function(o){return Object.getOwnPropertyDescriptor(t,o).enumerable}))),e.push.apply(e,n)}return e}function B(t){for(var o=1;oOpenStreetMap contributors'}]:R,Z=p.controls,L=void 0===Z?{zoomControl:!0,position:"topleft",scale:!1}:Z,S=[],E=[],M={iconUrl:"https://unpkg.com/leaflet@1.7.1/dist/images/marker-icon.png",iconRetinaUrl:"https://unpkg.com/leaflet@1.7.1/dist/images/marker-icon-2x.png",shadowUrl:"https://unpkg.com/leaflet@1.7.1/dist/images/marker-shadow.png",iconSize:[25,41],iconAnchor:[12,41],popupAnchor:[1,-34],tooltipAnchor:[1,-34],shadowSize:[41,41]};function A(t,o){t.bindPopup(o.text,B({closeOnClick:!1,autoClose:!1},o)).addTo(c),o.isOpen&&t.openPopup()}function I(t,o){t.bindTooltip(o.text,B({},o)).addTo(c),o.isOpen&&t.openTooltip()}var U=[],q=function(t){t.markers.map((function(t,o){t.icon&&(n=a.icon(t.icon)),U[o]=new a.marker([t.lat,t.lng],{icon:n}).addTo(c),t.popup&&A(U[o],t.popup),t.tooltip&&I(U[o],t.tooltip)}))},V=!1;return t.$$set=function(t){"options"in t&&e(3,u=t.options)},[g,function(){setTimeout((function(){a=window.L,function(){c=a.map(g,{attributionControl:k,zoomControl:L.zoomControl,minZoom:v,maxZoom:d}).setView(O,f),U=a.marker([0,0]),D&&D.map((function(t){a.tileLayer(t.url,B({},t)).addTo(c)}));j||c.scrollWheelZoom.disable();var t=a.control;L.zoomControl||t().remove();L.scale&&t.scale({position:L.position}).addTo(c);L.zoomControl&&L.position&&(c.removeControl(c.zoomControl),t.zoom({position:L.position}).addTo(c));C&&C.map((function(t){S.push([t.lat,t.lng]),n=t.icon?a.icon(t.icon):a.icon(M);var o=new a.marker([t.lat,t.lng],{icon:n});t.popup&&A(o,t.popup),t.tooltip&&I(o,t.tooltip),o.addTo(c)}));z&&z.map((function(t){E.push([t.lat,t.lng]);var o=new a.circle([t.lat,t.lng],B({},t));t.popup&&A(o,t.popup),t.tooltip&&I(o,t.tooltip),o.addTo(c)}));P&&(1==S.length?(c.panTo(a.latLng(S[0][0],S[0][1])),c.setZoom(f)):(r=new a.LatLngBounds(S),c.fitBounds(r)))}(),s("ready")}),1)},function(){c&&c.invalidateSize()},u,q,function(t){V||(q(t),V=!0),t.markers.map((function(t,o){U[o].setLatLng(t).update(),U[o].addTo(c)}))},function(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:5;c.setZoom(t)},function(t){$[t?"unshift":"push"]((function(){e(0,g=t)}))}]}var V=function(t){P(i,n);var r=M(i);function i(t){var n;return C(this,i),n=r.call(this),o(x(n),t,q,U,e,{options:3,addMarker:4,updateMarkers:5,setZoom:6},[-1,-1]),n}return z(i,[{key:"addMarker",get:function(){return this.$$.ctx[4]}},{key:"updateMarkers",get:function(){return this.$$.ctx[5]}},{key:"setZoom",get:function(){return this.$$.ctx[6]}}]),i}();export{V as L}; 2 | -------------------------------------------------------------------------------- /public/client/index.024ef953.js: -------------------------------------------------------------------------------- 1 | import{S as a,i as s,s as n,e as t,c as p,a as e,d as o,b as c,f as l,n as r,g as u,t as i,h as k,q as h,j as m,k as f,l as g,m as v,o as d,p as E,r as $,u as y}from"./client.27f5503e.js";import{L as D}from"./Leaflet.764aae6b.js";function w(a){let s;return{c(){s=t("pre"),this.h()},l(a){s=p(a,"PRE",{class:!0}),e(s).forEach(o),this.h()},h(){c(s,"class","language-html")},m(a,n){l(a,s,n),s.innerHTML='<script>\nimport Map from \'@anoram/leaflet-svelte\'\nlet options={\n center: [13,80],\n markers: [\n {\n lat: 13,\n lng: 80\n }\n ],\n mapID: "map"\n}\n</script>\n<style>\n .map {\n height: 600px;\n width: auto;\n }\n</style>\n<div class="map">\n <Map {options} />\n</div>'},p:r,i:r,o:r,d(a){a&&o(s)}}}class I extends a{constructor(a){super(),s(this,a,null,w,n,{})}}function b(a){let s,n,w,b,x,M,S,H,P,V,j,q,L,Q,T,A,C,F,O,R,z,B,G,J,K,N,U,W,X,Y,Z,_,aa,sa,na,ta,pa,ea,oa,ca,la="{options}";return Y=new I({}),oa=new D({props:{options:a[0]}}),{c(){s=u(),n=t("div"),w=t("div"),b=t("div"),x=t("h4"),M=i("Quick Start"),S=u(),H=t("p"),P=i("Svelte wrapper for leaflet. To use in "),V=t("a"),j=i("svelte"),q=i(".\n For bugs and suggestions please file issue "),L=t("a"),Q=i("here"),T=u(),A=t("pre"),C=i("npm i @anoram/leaflet-svelte"),F=u(),O=t("p"),R=i("Have "),z=t("code"),B=i(""),K=i(" a child of a div and supply\n custom css for height/width."),N=u(),U=t("h4"),W=i("Minimal Example"),X=u(),k(Y.$$.fragment),Z=u(),_=t("p"),aa=t("code"),sa=i("mapID"),na=i(" is unique like if you are planning to use multiple maps on the same page consider having different mapID"),ta=u(),pa=t("div"),ea=t("div"),k(oa.$$.fragment),this.h()},l(a){h('[data-svelte="svelte-1zskho"]',document.head).forEach(o),s=m(a),n=p(a,"DIV",{class:!0});var t=e(n);w=p(t,"DIV",{class:!0});var c=e(w);b=p(c,"DIV",{class:!0});var l=e(b);x=p(l,"H4",{});var r=e(x);M=f(r,"Quick Start"),r.forEach(o),S=m(l),H=p(l,"P",{});var u=e(H);P=f(u,"Svelte wrapper for leaflet. To use in "),V=p(u,"A",{href:!0});var i=e(V);j=f(i,"svelte"),i.forEach(o),q=f(u,".\n For bugs and suggestions please file issue "),L=p(u,"A",{href:!0});var k=e(L);Q=f(k,"here"),k.forEach(o),u.forEach(o),T=m(l),A=p(l,"PRE",{});var v=e(A);C=f(v,"npm i @anoram/leaflet-svelte"),v.forEach(o),F=m(l),O=p(l,"P",{});var d=e(O);R=f(d,"Have "),z=p(d,"CODE",{});var E=e(z);B=f(E,""),E.forEach(o),K=f(d," a child of a div and supply\n custom css for height/width."),d.forEach(o),N=m(l),U=p(l,"H4",{});var $=e(U);W=f($,"Minimal Example"),$.forEach(o),X=m(l),g(Y.$$.fragment,l),Z=m(l),_=p(l,"P",{});var y=e(_);aa=p(y,"CODE",{});var D=e(aa);sa=f(D,"mapID"),D.forEach(o),na=f(y," is unique like if you are planning to use multiple maps on the same page consider having different mapID"),y.forEach(o),l.forEach(o),ta=m(c),pa=p(c,"DIV",{class:!0});var I=e(pa);ea=p(I,"DIV",{class:!0});var ca=e(ea);g(oa.$$.fragment,ca),ca.forEach(o),I.forEach(o),c.forEach(o),t.forEach(o),this.h()},h(){document.title="Home Quick Start with leaflet on Svelte",c(V,"href","https://github.com/anoram/leaflet-svelte"),c(L,"href","https://github.com/anoram/leaflet-svelte"),c(b,"class","col-6"),c(ea,"class","map svelte-dt8ylx"),c(pa,"class","col-6"),c(w,"class","row is-center"),c(n,"class","container")},m(a,t){l(a,s,t),l(a,n,t),v(n,w),v(w,b),v(b,x),v(x,M),v(b,S),v(b,H),v(H,P),v(H,V),v(V,j),v(H,q),v(H,L),v(L,Q),v(b,T),v(b,A),v(A,C),v(b,F),v(b,O),v(O,R),v(O,z),v(z,B),v(z,G),v(z,J),v(O,K),v(b,N),v(b,U),v(U,W),v(b,X),d(Y,b,null),v(b,Z),v(b,_),v(_,aa),v(aa,sa),v(_,na),v(w,ta),v(w,pa),v(pa,ea),d(oa,ea,null),ca=!0},p:r,i(a){ca||(E(Y.$$.fragment,a),E(oa.$$.fragment,a),ca=!0)},o(a){$(Y.$$.fragment,a),$(oa.$$.fragment,a),ca=!1},d(a){a&&o(s),a&&o(n),y(Y),y(oa)}}}function x(a){return[{center:[13,80],markers:[{lat:13,lng:80}],mapID:"map"}]}export default class extends a{constructor(a){super(),s(this,a,x,b,n,{})}} 2 | -------------------------------------------------------------------------------- /public/client/index.0fedf38a.js: -------------------------------------------------------------------------------- 1 | import{S as a,i as s,s as n,e as t,c as p,a as e,d as o,b as c,f as l,n as r,g as u,t as i,h as k,q as h,j as m,k as f,l as g,m as v,o as d,p as E,r as $,u as y}from"./client.a52649eb.js";import{L as D}from"./Leaflet.1975f146.js";function w(a){let s;return{c(){s=t("pre"),this.h()},l(a){s=p(a,"PRE",{class:!0}),e(s).forEach(o),this.h()},h(){c(s,"class","language-html")},m(a,n){l(a,s,n),s.innerHTML='<script>\nimport Map from \'@anoram/leaflet-svelte\'\nlet options={\n center: [13,80],\n markers: [\n {\n lat: 13,\n lng: 80\n }\n ],\n mapID: "map"\n}\n</script>\n<style>\n .map {\n height: 600px;\n width: auto;\n }\n</style>\n<div class="map">\n <Map {options} />\n</div>'},p:r,i:r,o:r,d(a){a&&o(s)}}}class I extends a{constructor(a){super(),s(this,a,null,w,n,{})}}function b(a){let s,n,w,b,x,M,S,H,P,V,j,q,L,Q,T,A,C,F,O,R,z,B,G,J,K,N,U,W,X,Y,Z,_,aa,sa,na,ta,pa,ea,oa,ca,la="{options}";return Y=new I({}),oa=new D({props:{options:a[0]}}),{c(){s=u(),n=t("div"),w=t("div"),b=t("div"),x=t("h4"),M=i("Quick Start"),S=u(),H=t("p"),P=i("Svelte wrapper for leaflet. To use in "),V=t("a"),j=i("svelte"),q=i(".\n For bugs and suggestions please file issue "),L=t("a"),Q=i("here"),T=u(),A=t("pre"),C=i("npm i @anoram/leaflet-svelte"),F=u(),O=t("p"),R=i("Have "),z=t("code"),B=i(""),K=i(" a child of a div and supply\n custom css for height/width."),N=u(),U=t("h4"),W=i("Minimal Example"),X=u(),k(Y.$$.fragment),Z=u(),_=t("p"),aa=t("code"),sa=i("mapID"),na=i(" is unique like if you are planning to use multiple maps on the same page consider having different mapID"),ta=u(),pa=t("div"),ea=t("div"),k(oa.$$.fragment),this.h()},l(a){h('[data-svelte="svelte-1zskho"]',document.head).forEach(o),s=m(a),n=p(a,"DIV",{class:!0});var t=e(n);w=p(t,"DIV",{class:!0});var c=e(w);b=p(c,"DIV",{class:!0});var l=e(b);x=p(l,"H4",{});var r=e(x);M=f(r,"Quick Start"),r.forEach(o),S=m(l),H=p(l,"P",{});var u=e(H);P=f(u,"Svelte wrapper for leaflet. To use in "),V=p(u,"A",{href:!0});var i=e(V);j=f(i,"svelte"),i.forEach(o),q=f(u,".\n For bugs and suggestions please file issue "),L=p(u,"A",{href:!0});var k=e(L);Q=f(k,"here"),k.forEach(o),u.forEach(o),T=m(l),A=p(l,"PRE",{});var v=e(A);C=f(v,"npm i @anoram/leaflet-svelte"),v.forEach(o),F=m(l),O=p(l,"P",{});var d=e(O);R=f(d,"Have "),z=p(d,"CODE",{});var E=e(z);B=f(E,""),E.forEach(o),K=f(d," a child of a div and supply\n custom css for height/width."),d.forEach(o),N=m(l),U=p(l,"H4",{});var $=e(U);W=f($,"Minimal Example"),$.forEach(o),X=m(l),g(Y.$$.fragment,l),Z=m(l),_=p(l,"P",{});var y=e(_);aa=p(y,"CODE",{});var D=e(aa);sa=f(D,"mapID"),D.forEach(o),na=f(y," is unique like if you are planning to use multiple maps on the same page consider having different mapID"),y.forEach(o),l.forEach(o),ta=m(c),pa=p(c,"DIV",{class:!0});var I=e(pa);ea=p(I,"DIV",{class:!0});var ca=e(ea);g(oa.$$.fragment,ca),ca.forEach(o),I.forEach(o),c.forEach(o),t.forEach(o),this.h()},h(){document.title="Home Quick Start with leaflet on Svelte",c(V,"href","https://github.com/anoram/leaflet-svelte"),c(L,"href","https://github.com/anoram/leaflet-svelte"),c(b,"class","col-6"),c(ea,"class","map svelte-dt8ylx"),c(pa,"class","col-6"),c(w,"class","row is-center"),c(n,"class","container")},m(a,t){l(a,s,t),l(a,n,t),v(n,w),v(w,b),v(b,x),v(x,M),v(b,S),v(b,H),v(H,P),v(H,V),v(V,j),v(H,q),v(H,L),v(L,Q),v(b,T),v(b,A),v(A,C),v(b,F),v(b,O),v(O,R),v(O,z),v(z,B),v(z,G),v(z,J),v(O,K),v(b,N),v(b,U),v(U,W),v(b,X),d(Y,b,null),v(b,Z),v(b,_),v(_,aa),v(aa,sa),v(_,na),v(w,ta),v(w,pa),v(pa,ea),d(oa,ea,null),ca=!0},p:r,i(a){ca||(E(Y.$$.fragment,a),E(oa.$$.fragment,a),ca=!0)},o(a){$(Y.$$.fragment,a),$(oa.$$.fragment,a),ca=!1},d(a){a&&o(s),a&&o(n),y(Y),y(oa)}}}function x(a){return[{center:[13,80],markers:[{lat:13,lng:80}],mapID:"map"}]}export default class extends a{constructor(a){super(),s(this,a,x,b,n,{})}} 2 | -------------------------------------------------------------------------------- /public/client/index.683fc466.js: -------------------------------------------------------------------------------- 1 | import{S as a,i as s,s as n,e as t,c as p,a as e,d as o,b as c,f as l,n as r,g as u,t as i,h as k,q as f,j as h,k as m,l as g,m as v,o as d,p as E,r as $,u as y}from"./client.47f8a5db.js";import{L as D}from"./Leaflet.6481def0.js";function w(a){let s;return{c(){s=t("pre"),this.h()},l(a){s=p(a,"PRE",{class:!0}),e(s).forEach(o),this.h()},h(){c(s,"class","language-html")},m(a,n){l(a,s,n),s.innerHTML='<script>\nimport Map from \'@anoram/leaflet-svelte\'\nlet options={\n center: [13,80],\n markers: [\n {\n lat: 13,\n lng: 80\n }\n ],\n mapID: "map"\n}\n</script>\n<style>\n .map {\n height: 600px;\n width: auto;\n }\n</style>\n<div class="map">\n <Map {options} />\n</div>'},p:r,i:r,o:r,d(a){a&&o(s)}}}class I extends a{constructor(a){super(),s(this,a,null,w,n,{})}}function b(a){let s,n,w,b,x,M,S,H,P,V,j,q,L,Q,T,A,C,F,O,R,z,B,G,J,K,N,U,W,X,Y,Z,_,aa,sa,na,ta,pa,ea,oa,ca,la="{options}";return Y=new I({}),oa=new D({props:{options:a[0]}}),{c(){s=u(),n=t("div"),w=t("div"),b=t("div"),x=t("h4"),M=i("Quick Start"),S=u(),H=t("p"),P=i("Svelte wrapper for leaflet. To use in "),V=t("a"),j=i("svelte"),q=i(".\n For bugs and suggestions please file issue "),L=t("a"),Q=i("here"),T=u(),A=t("pre"),C=i("npm i @anoram/leaflet-svelte"),F=u(),O=t("p"),R=i("Have "),z=t("code"),B=i(""),K=i(" a child of a div and supply\n custom css for height/width."),N=u(),U=t("h4"),W=i("Minimal Example"),X=u(),k(Y.$$.fragment),Z=u(),_=t("p"),aa=t("code"),sa=i("mapID"),na=i(" is unique like if you are planning to use multiple maps on the same page consider having different mapID"),ta=u(),pa=t("div"),ea=t("div"),k(oa.$$.fragment),this.h()},l(a){f('[data-svelte="svelte-1zskho"]',document.head).forEach(o),s=h(a),n=p(a,"DIV",{class:!0});var t=e(n);w=p(t,"DIV",{class:!0});var c=e(w);b=p(c,"DIV",{class:!0});var l=e(b);x=p(l,"H4",{});var r=e(x);M=m(r,"Quick Start"),r.forEach(o),S=h(l),H=p(l,"P",{});var u=e(H);P=m(u,"Svelte wrapper for leaflet. To use in "),V=p(u,"A",{href:!0});var i=e(V);j=m(i,"svelte"),i.forEach(o),q=m(u,".\n For bugs and suggestions please file issue "),L=p(u,"A",{href:!0});var k=e(L);Q=m(k,"here"),k.forEach(o),u.forEach(o),T=h(l),A=p(l,"PRE",{});var v=e(A);C=m(v,"npm i @anoram/leaflet-svelte"),v.forEach(o),F=h(l),O=p(l,"P",{});var d=e(O);R=m(d,"Have "),z=p(d,"CODE",{});var E=e(z);B=m(E,""),E.forEach(o),K=m(d," a child of a div and supply\n custom css for height/width."),d.forEach(o),N=h(l),U=p(l,"H4",{});var $=e(U);W=m($,"Minimal Example"),$.forEach(o),X=h(l),g(Y.$$.fragment,l),Z=h(l),_=p(l,"P",{});var y=e(_);aa=p(y,"CODE",{});var D=e(aa);sa=m(D,"mapID"),D.forEach(o),na=m(y," is unique like if you are planning to use multiple maps on the same page consider having different mapID"),y.forEach(o),l.forEach(o),ta=h(c),pa=p(c,"DIV",{class:!0});var I=e(pa);ea=p(I,"DIV",{class:!0});var ca=e(ea);g(oa.$$.fragment,ca),ca.forEach(o),I.forEach(o),c.forEach(o),t.forEach(o),this.h()},h(){document.title="Home Quick Start with leaflet on Svelte",c(V,"href","https://github.com/anoram/leaflet-svelte"),c(L,"href","https://github.com/anoram/leaflet-svelte"),c(b,"class","col-6"),c(ea,"class","map svelte-dt8ylx"),c(pa,"class","col-6"),c(w,"class","row is-center"),c(n,"class","container")},m(a,t){l(a,s,t),l(a,n,t),v(n,w),v(w,b),v(b,x),v(x,M),v(b,S),v(b,H),v(H,P),v(H,V),v(V,j),v(H,q),v(H,L),v(L,Q),v(b,T),v(b,A),v(A,C),v(b,F),v(b,O),v(O,R),v(O,z),v(z,B),v(z,G),v(z,J),v(O,K),v(b,N),v(b,U),v(U,W),v(b,X),d(Y,b,null),v(b,Z),v(b,_),v(_,aa),v(aa,sa),v(_,na),v(w,ta),v(w,pa),v(pa,ea),d(oa,ea,null),ca=!0},p:r,i(a){ca||(E(Y.$$.fragment,a),E(oa.$$.fragment,a),ca=!0)},o(a){$(Y.$$.fragment,a),$(oa.$$.fragment,a),ca=!1},d(a){a&&o(s),a&&o(n),y(Y),y(oa)}}}function x(a){return[{center:[13,80],markers:[{lat:13,lng:80}],mapID:"map"}]}export default class extends a{constructor(a){super(),s(this,a,x,b,n,{})}} 2 | -------------------------------------------------------------------------------- /public/client/index.ac71540c.js: -------------------------------------------------------------------------------- 1 | import{S as a,i as s,s as n,e as t,c as p,a as e,d as o,b as c,f as l,n as r,g as u,t as i,h as k,q as h,j as m,k as f,l as g,m as v,o as d,p as E,r as $,u as b}from"./client.bba8b1e3.js";import{L as y}from"./Leaflet.1fd8bc0e.js";function D(a){let s;return{c(){s=t("pre"),this.h()},l(a){s=p(a,"PRE",{class:!0}),e(s).forEach(o),this.h()},h(){c(s,"class","language-html")},m(a,n){l(a,s,n),s.innerHTML='<script>\nimport Map from \'@anoram/leaflet-svelte\'\nlet options={\n center: [13,80],\n markers: [\n {\n lat: 13,\n lng: 80\n }\n ],\n mapID: "map"\n}\n</script>\n<style>\n .map {\n height: 600px;\n width: auto;\n }\n</style>\n<div class="map">\n <Map {options} />\n</div>'},p:r,i:r,o:r,d(a){a&&o(s)}}}class w extends a{constructor(a){super(),s(this,a,null,D,n,{})}}function I(a){let s,n,D,I,x,M,S,H,P,V,j,q,L,Q,T,A,C,F,O,R,z,B,G,J,K,N,U,W,X,Y,Z,_,aa,sa,na,ta,pa,ea,oa,ca,la="{options}";return Y=new w({}),oa=new y({props:{options:a[0]}}),{c(){s=u(),n=t("div"),D=t("div"),I=t("div"),x=t("h4"),M=i("Quick Start"),S=u(),H=t("p"),P=i("Svelte wrapper for leaflet. To use in "),V=t("a"),j=i("svelte"),q=i(".\n For bugs and suggestions please file issue "),L=t("a"),Q=i("here"),T=u(),A=t("pre"),C=i("npm i @anoram/leaflet-svelte"),F=u(),O=t("p"),R=i("Have "),z=t("code"),B=i(""),K=i(" a child of a div and supply\n custom css for height/width."),N=u(),U=t("h4"),W=i("Minimal Example"),X=u(),k(Y.$$.fragment),Z=u(),_=t("p"),aa=t("code"),sa=i("mapID"),na=i(" is unique like if you are planning to use multiple maps on the same page consider having different mapID"),ta=u(),pa=t("div"),ea=t("div"),k(oa.$$.fragment),this.h()},l(a){h('[data-svelte="svelte-1zskho"]',document.head).forEach(o),s=m(a),n=p(a,"DIV",{class:!0});var t=e(n);D=p(t,"DIV",{class:!0});var c=e(D);I=p(c,"DIV",{class:!0});var l=e(I);x=p(l,"H4",{});var r=e(x);M=f(r,"Quick Start"),r.forEach(o),S=m(l),H=p(l,"P",{});var u=e(H);P=f(u,"Svelte wrapper for leaflet. To use in "),V=p(u,"A",{href:!0});var i=e(V);j=f(i,"svelte"),i.forEach(o),q=f(u,".\n For bugs and suggestions please file issue "),L=p(u,"A",{href:!0});var k=e(L);Q=f(k,"here"),k.forEach(o),u.forEach(o),T=m(l),A=p(l,"PRE",{});var v=e(A);C=f(v,"npm i @anoram/leaflet-svelte"),v.forEach(o),F=m(l),O=p(l,"P",{});var d=e(O);R=f(d,"Have "),z=p(d,"CODE",{});var E=e(z);B=f(E,""),E.forEach(o),K=f(d," a child of a div and supply\n custom css for height/width."),d.forEach(o),N=m(l),U=p(l,"H4",{});var $=e(U);W=f($,"Minimal Example"),$.forEach(o),X=m(l),g(Y.$$.fragment,l),Z=m(l),_=p(l,"P",{});var b=e(_);aa=p(b,"CODE",{});var y=e(aa);sa=f(y,"mapID"),y.forEach(o),na=f(b," is unique like if you are planning to use multiple maps on the same page consider having different mapID"),b.forEach(o),l.forEach(o),ta=m(c),pa=p(c,"DIV",{class:!0});var w=e(pa);ea=p(w,"DIV",{class:!0});var ca=e(ea);g(oa.$$.fragment,ca),ca.forEach(o),w.forEach(o),c.forEach(o),t.forEach(o),this.h()},h(){document.title="Home Quick Start with leaflet on Svelte",c(V,"href","https://github.com/anoram/leaflet-svelte"),c(L,"href","https://github.com/anoram/leaflet-svelte"),c(I,"class","col-6"),c(ea,"class","map svelte-dt8ylx"),c(pa,"class","col-6"),c(D,"class","row is-center"),c(n,"class","container")},m(a,t){l(a,s,t),l(a,n,t),v(n,D),v(D,I),v(I,x),v(x,M),v(I,S),v(I,H),v(H,P),v(H,V),v(V,j),v(H,q),v(H,L),v(L,Q),v(I,T),v(I,A),v(A,C),v(I,F),v(I,O),v(O,R),v(O,z),v(z,B),v(z,G),v(z,J),v(O,K),v(I,N),v(I,U),v(U,W),v(I,X),d(Y,I,null),v(I,Z),v(I,_),v(_,aa),v(aa,sa),v(_,na),v(D,ta),v(D,pa),v(pa,ea),d(oa,ea,null),ca=!0},p:r,i(a){ca||(E(Y.$$.fragment,a),E(oa.$$.fragment,a),ca=!0)},o(a){$(Y.$$.fragment,a),$(oa.$$.fragment,a),ca=!1},d(a){a&&o(s),a&&o(n),b(Y),b(oa)}}}function x(a){return[{center:[13,80],markers:[{lat:13,lng:80}],mapID:"map"}]}export default class extends a{constructor(a){super(),s(this,a,x,I,n,{})}} 2 | -------------------------------------------------------------------------------- /public/client/index.deb1472f.js: -------------------------------------------------------------------------------- 1 | import{S as a,i as s,s as n,e as t,c as p,a as e,d as o,b as c,f as l,n as r,g as u,t as i,h as k,q as h,j as m,k as f,l as g,m as v,o as d,p as E,r as $,u as y}from"./client.cad504f2.js";import{L as D}from"./Leaflet.399e6cc7.js";function w(a){let s;return{c(){s=t("pre"),this.h()},l(a){s=p(a,"PRE",{class:!0}),e(s).forEach(o),this.h()},h(){c(s,"class","language-html")},m(a,n){l(a,s,n),s.innerHTML='<script>\nimport Map from \'@anoram/leaflet-svelte\'\nlet options={\n center: [13,80],\n markers: [\n {\n lat: 13,\n lng: 80\n }\n ],\n mapID: "map"\n}\n</script>\n<style>\n .map {\n height: 600px;\n width: auto;\n }\n</style>\n<div class="map">\n <Map {options} />\n</div>'},p:r,i:r,o:r,d(a){a&&o(s)}}}class I extends a{constructor(a){super(),s(this,a,null,w,n,{})}}function b(a){let s,n,w,b,x,M,S,H,P,V,j,q,L,Q,T,A,C,F,O,R,z,B,G,J,K,N,U,W,X,Y,Z,_,aa,sa,na,ta,pa,ea,oa,ca,la="{options}";return Y=new I({}),oa=new D({props:{options:a[0]}}),{c(){s=u(),n=t("div"),w=t("div"),b=t("div"),x=t("h4"),M=i("Quick Start"),S=u(),H=t("p"),P=i("Svelte wrapper for leaflet. To use in "),V=t("a"),j=i("svelte"),q=i(".\n For bugs and suggestions please file issue "),L=t("a"),Q=i("here"),T=u(),A=t("pre"),C=i("npm i @anoram/leaflet-svelte"),F=u(),O=t("p"),R=i("Have "),z=t("code"),B=i(""),K=i(" a child of a div and supply\n custom css for height/width."),N=u(),U=t("h4"),W=i("Minimal Example"),X=u(),k(Y.$$.fragment),Z=u(),_=t("p"),aa=t("code"),sa=i("mapID"),na=i(" is unique like if you are planning to use multiple maps on the same page consider having different mapID"),ta=u(),pa=t("div"),ea=t("div"),k(oa.$$.fragment),this.h()},l(a){h('[data-svelte="svelte-1zskho"]',document.head).forEach(o),s=m(a),n=p(a,"DIV",{class:!0});var t=e(n);w=p(t,"DIV",{class:!0});var c=e(w);b=p(c,"DIV",{class:!0});var l=e(b);x=p(l,"H4",{});var r=e(x);M=f(r,"Quick Start"),r.forEach(o),S=m(l),H=p(l,"P",{});var u=e(H);P=f(u,"Svelte wrapper for leaflet. To use in "),V=p(u,"A",{href:!0});var i=e(V);j=f(i,"svelte"),i.forEach(o),q=f(u,".\n For bugs and suggestions please file issue "),L=p(u,"A",{href:!0});var k=e(L);Q=f(k,"here"),k.forEach(o),u.forEach(o),T=m(l),A=p(l,"PRE",{});var v=e(A);C=f(v,"npm i @anoram/leaflet-svelte"),v.forEach(o),F=m(l),O=p(l,"P",{});var d=e(O);R=f(d,"Have "),z=p(d,"CODE",{});var E=e(z);B=f(E,""),E.forEach(o),K=f(d," a child of a div and supply\n custom css for height/width."),d.forEach(o),N=m(l),U=p(l,"H4",{});var $=e(U);W=f($,"Minimal Example"),$.forEach(o),X=m(l),g(Y.$$.fragment,l),Z=m(l),_=p(l,"P",{});var y=e(_);aa=p(y,"CODE",{});var D=e(aa);sa=f(D,"mapID"),D.forEach(o),na=f(y," is unique like if you are planning to use multiple maps on the same page consider having different mapID"),y.forEach(o),l.forEach(o),ta=m(c),pa=p(c,"DIV",{class:!0});var I=e(pa);ea=p(I,"DIV",{class:!0});var ca=e(ea);g(oa.$$.fragment,ca),ca.forEach(o),I.forEach(o),c.forEach(o),t.forEach(o),this.h()},h(){document.title="Home Quick Start with leaflet on Svelte",c(V,"href","https://github.com/anoram/leaflet-svelte"),c(L,"href","https://github.com/anoram/leaflet-svelte"),c(b,"class","col-6"),c(ea,"class","map svelte-dt8ylx"),c(pa,"class","col-6"),c(w,"class","row is-center"),c(n,"class","container")},m(a,t){l(a,s,t),l(a,n,t),v(n,w),v(w,b),v(b,x),v(x,M),v(b,S),v(b,H),v(H,P),v(H,V),v(V,j),v(H,q),v(H,L),v(L,Q),v(b,T),v(b,A),v(A,C),v(b,F),v(b,O),v(O,R),v(O,z),v(z,B),v(z,G),v(z,J),v(O,K),v(b,N),v(b,U),v(U,W),v(b,X),d(Y,b,null),v(b,Z),v(b,_),v(_,aa),v(aa,sa),v(_,na),v(w,ta),v(w,pa),v(pa,ea),d(oa,ea,null),ca=!0},p:r,i(a){ca||(E(Y.$$.fragment,a),E(oa.$$.fragment,a),ca=!0)},o(a){$(Y.$$.fragment,a),$(oa.$$.fragment,a),ca=!1},d(a){a&&o(s),a&&o(n),y(Y),y(oa)}}}function x(a){return[{center:[13,80],markers:[{lat:13,lng:80}],mapID:"map"}]}export default class extends a{constructor(a){super(),s(this,a,x,b,n,{})}} 2 | -------------------------------------------------------------------------------- /public/client/shimport@1.0.1.js: -------------------------------------------------------------------------------- 1 | var __shimport__=function(n){"use strict";function t(n,t){for(var r=n.length;r--;)if(n[r].name===t)return n[r].as}var r=/\b(case|default|delete|do|else|in|instanceof|new|return|throw|typeof|void)\s*$/,e=/(^|\{|\(|\[\.|;|,|<|>|<=|>=|==|!=|===|!==|\+|-|\*\%|<<|>>|>>>|&|\||\^|!|~|&&|\|\||\?|:|=|\+=|-=|\*=|%=|<<=|>>=|>>>=|&=|\|=|\^=|\/=|\/)\s*$/,u=/(\}|\)|\+\+|--)\s*$/,o=/[{}()[.;,<>=+\-*%&|\^!~?:\/]/,a=/[a-zA-Z_$0-9]/,i={" ":1,"\t":1,"\n":1,"\r":1,"\f":1,"\v":1," ":1,"\u2028":1,"\u2029":1};function s(n){return n in i}function f(n){return"'"===n||'"'===n}var c=/^\*\s+as\s+(\w+)$/,l=/(\w+)\s*,\s*\*\s*as\s*(\w+)$/,d=/(\w+)\s*,\s*{(.+)}$/;function p(n){return n?n.split(",").map(function(n){var t=n.trim().split(/[^\S]+/),r=t[0];return{name:r,as:t[2]||r}}):[]}function m(n,r){for(var e=r,u=r+=6;n[r]&&s(n[r]);)r+=1;for(;n[r]&&!f(n[r]);)r+=1;for(var o=r,a=r+=1;n[r]&&!f(n[r]);)r+=1;var i=r++;return function(n,r,e,u,o){var a=t(u,"*")||t(u,"default");return{start:r,end:e,source:o,name:a,toString:function(t){var a=t.get(o);return(u.sort(function(n,t){return"default"===n.name?1:"default"===t.name?-1:void 0}).map(function(n){return"*"===n.name?null:"default"===n.name&&n.as===a?n.as+" = "+a+".default;":"var "+n.as+" = "+a+"."+n.name+";"}).join(" ")+" /*"+n.slice(r,e)+"*/").trim()}}}(n,e,r,function(n){var t=c.exec(n);return t?[{name:"*",as:t[1]}]:(t=l.exec(n))?[{name:"default",as:t[1]},{name:"*",as:t[2]}]:(t=d.exec(n))?[{name:"default",as:t[1]}].concat(p(t[2].trim())):"{"===n[0]?p(n.slice(1,-1).trim()):n?[{name:"default",as:n}]:[]}(n.slice(u,o).replace(/from\s*$/,"").trim()),n.slice(a,i))}function v(n,t){var r=t;for(t+=6;n[t]&&s(n[t]);)t+=1;var e=t;if("{"===n[t]){for(;"}"!==n[t];)t+=1;for(var u=t+=1,a=null;s(n[t]);)t+=1;if(/^from[\s\n'"]/.test(n.slice(t,t+5))){for(t+=4;s(n[t]);)t+=1;for(;n[t]&&!f(n[t]);)t+=1;for(var i=t+=1;n[t]&&!f(n[t]);)t+=1;a=n.slice(i,t),t+=1}return function(n,t,r,e,u,o){var a=p(n.slice(r+1,e-1).trim());return{start:t,end:u,source:o,toString:function(r){var e=r.get(o);return a.map(function(n){return"__exports."+n.as+" = "+(e?e+"."+n.name:n.name)+"; "}).join("")+"/*"+n.slice(t,u)+"*/"}}}(n,r,e,u,t,a)}if("*"===n[t]){for(t+=1;s(n[t]);)t+=1;for(t+=4;n[t]&&!f(n[t]);)t+=1;for(i=t+=1;n[t]&&!f(n[t]);)t+=1;var c=t++;return function(n,t,r,e){return{start:t,end:r,source:e,toString:function(u){return"Object.assign(__exports, "+u.get(e)+"); /*"+n.slice(t,r)+"*/"}}}(n,r,t,n.slice(i,c))}return/^default\b/.test(n.slice(t,t+8))?function(n,t,r){var e=/^\s*(?:(class)(\s+extends|\s*{)|(function)\s*\()/.exec(n.slice(r));if(e){r+=e[0].length;var u="__default_export";return{start:t,end:r,name:u,as:"default",toString:function(){return e[1]?"class "+u+e[2]:"function "+u+"("}}}return{start:t,end:r,toString:function(){return"__exports.default ="}}}(n,r,e+7):function(n,t,r){for(var e=r;n[r]&&/\S/.test(n[r]);)r+=1;for(;n[r]&&!/\S/.test(n[r]);)r+=1;for(var u=r;n[r]&&!o.test(n[r])&&!s(n[r]);)r+=1;var a=r;return{start:t,end:e,name:n.slice(u,a),toString:function(){return""}}}(n,r,e)}function h(n){var t,i=!0,f=!1,c=[],l=-1,d=function(){return n[l]},p={},h={},_=0,g=[],x=[],w=[];for(var S={pattern:/(?:(\()|(\))|({)|(})|(")|(')|(\/\/)|(\/\*)|(\/)|(`)|(import)|(export)|(\+\+|--))/g,handlers:[function(n){l=n,h[_++]=n},function(n){l=n,p[n]=h[--_]},function(n){l=n,c.push(S)},function(n){return l=n,c.pop()},function(n){return c.push(S),R},function(n){return c.push(S),U},function(n){return L},function(n){return A},function(t){for(var f=t;f>0&&s(n[f-1]);)f-=1;if(f>0){var c=f;if(o.test(n[c-1]))for(;c>0&&o.test(n[c-1]);)c-=1;else for(;c>0&&a.test(n[c-1]);)c-=1;var m=n.slice(c,f);i=!!m&&(r.test(m)||e.test(m)||u.test(m)&&!function(){if(")"===d()){for(var t=p[l];s(n[t-1]);)t-=1;return!/(if|while)$/.test(n.slice(t-5,t))}return!0}())}else i=!0;return $},function(n){return E},function(t){if(0===t||s(n[t-1])||o.test(n[t-1]))if(/import[\s\n{"']/.test(n.slice(t,t+7))){var r=m(n,t);g.push(r),z=r.end}else if("import("===n.slice(t,t+7)){var e=function(n){return{start:n,end:n+6,toString:function(){return"__import"}}}(t);x.push(e),z=e.end}},function(t){if((0===t||s(n[t-1])||o.test(n[t-1]))&&/export[\s\n{]/.test(n.slice(t,t+7))){var r=v(n,t);w.push(r),z=r.end}},function(t){f=!f&&"+"===n[t-1]}]},$={pattern:/(?:(\[)|(\\)|(.))/g,handlers:[function(n){return i?y:S},function(n){return t=b,j},function(n){return i&&!f?b:S}]},b={pattern:/(?:(\[)|(\\)|(\/))/g,handlers:[function(){return y},function(){return t=b,j},function(){return S}]},y={pattern:/(?:(\])|(\\))/g,handlers:[function(){return b},function(){return t=y,j}]},R={pattern:/(?:(\\)|("))/g,handlers:[function(){return t=R,j},function(){return c.pop()}]},U={pattern:/(?:(\\)|('))/g,handlers:[function(){return t=U,j},function(){return c.pop()}]},j={pattern:/(.)/g,handlers:[function(){return t}]},E={pattern:/(?:(\${)|(\\)|(`))/g,handlers:[function(){return c.push(E),S},function(){return t=E,j},function(){return S}]},L={pattern:/((?:\n|$))/g,handlers:[function(){return S}]},A={pattern:/(\*\/)/g,handlers:[function(){return S}]},k=S,z=0;z0||k!==S)throw new Error("Unexpected end of file");break}z=I.index+I[0].length;for(var O=1;O Themes with custom tileLayer
←Examples

Themes with custom tileLayer @0.0.7^

Leaflet custom tileLayer for different themes check out this collection.

<script>
 2 |   import Map from "@anoram/leaflet-svelte";
 3 |   let options = {
 4 |     center: [13, 80],
 5 |     markers: [
 6 |       {
 7 |         lat: 13,
 8 |         lng: 80,
 9 |       },
10 |     ],
11 |     mapID: "map",
12 |     tilelayers: [
13 |       {
14 |         url: "https://{s}.tile.openstreetmap.fr/hot/{z}/{x}/{y}.png",
15 |         attribution: `&copy; <a href="https://www.openstreetmap.org/copyright">OpenStreetMap</a> contributors, Tiles style by <a href="https://www.hotosm.org/" target="_blank">Humanitarian OpenStreetMap Team</a> hosted by <a href="https://openstreetmap.fr/" target="_blank">OpenStreetMap France</a>`,
16 |       }
17 |     ],
18 |   };
19 |   
20 | </script>
21 | 
22 | <style>
23 |   .map {
24 |     height: 600px;
25 |     width: auto;
26 |   }
27 | 
28 | </style>
29 | 
30 | 
31 | <div class="map">
32 |   <Map {options} />
33 | </div>

Note

Some services require API keys.

-------------------------------------------------------------------------------- /public/examples/disablescrollwheelzoom/index.html: -------------------------------------------------------------------------------- 1 | Disable scroll wheel zoom
←Examples

Disable scroll wheel zoom @0.0.4^

Disables mouse wheel intereactions for zoom and allows only zoom via controls.

<script>
 2 |   import Map from "@anoram/leaflet-svelte";
 3 |    let options = {
 4 |     recenter: true,
 5 |     zoom: 5,
 6 |     markers: [
 7 |       {
 8 |         lat: 8,
 9 |         lng: 8,
10 |       },
11 |       {
12 |         lat: 13,
13 |         lng: 80,
14 |       },
15 |     ],
16 |     controls: {
17 |       zoomControl: true,
18 |     },
19 |     scrollWheelZoom: false,
20 |     mapID: "map",
21 |     attributionControl: true,
22 |   };
23 |   
24 | </script>
25 | 
26 | <style>
27 |   .map {
28 |     height: 600px;
29 |     width: auto;
30 |   }
31 | 
32 | </style>
33 | 
34 | 
35 | <div class="map">
36 |   <Map {options} />
37 | </div>

Note

scrollWheelZoom by default is true additionally you can remove the zoom control element by setting controls: {zoomControl: true } to false.

-------------------------------------------------------------------------------- /public/client/autocenter.003c8795.js: -------------------------------------------------------------------------------- 1 | import{S as a,i as s,s as n,e as t,c as p,a as e,d as o,b as c,f as l,n as r,g as u,t as i,h as k,q as m,j as h,k as f,l as g,m as v,o as d,p as E,r as w,u as $}from"./client.a52649eb.js";import{L as y}from"./Leaflet.1975f146.js";function b(a){let s;return{c(){s=t("pre"),this.h()},l(a){s=p(a,"PRE",{class:!0}),e(s).forEach(o),this.h()},h(){c(s,"class","language-html")},m(a,n){l(a,s,n),s.innerHTML='<script>\n import Map from "@anoram/leaflet-svelte";\n let options = {\n recenter: true,\n markers: [\n {\n lat: 1,\n lng: 1,\n },\n {\n lat: 13,\n lng: 80,\n },\n ],\n mapID: "map",\n\n };\n \n</script>\n\n<style>\n .map {\n height: 600px;\n width: auto;\n }\n\n</style>\n\n\n<div class="map">\n <Map {options} />\n</div>'},p:r,i:r,o:r,d(a){a&&o(s)}}}class x extends a{constructor(a){super(),s(this,a,null,b,n,{})}}function D(a){let s,n,b,D,I,M,z,V,j,P,Z,q,C,H,L,N,O,R,A,S,T,B,F,G,J,K,Q,U,W,X,Y,_,aa,sa,na;return N=new x({}),sa=new y({props:{options:a[0]}}),{c(){s=u(),n=t("div"),b=t("div"),D=t("div"),I=t("a"),M=i("←Examples"),z=u(),V=t("h4"),j=i("Multiple markers that are far apart "),P=t("span"),Z=i("@0.0.4^"),q=u(),C=t("p"),H=i("Recenter and set map view to center of both the locations or a set of\r\n markers."),L=u(),k(N.$$.fragment),O=u(),R=t("h4"),A=i("Note"),S=u(),T=t("p"),B=t("code"),F=i("recenter"),G=i(" by default is false, setting it to true and "),J=t("code"),K=i("maxZoom/minZoom"),Q=i("\r\n values will not work, however if you give value for "),U=t("code"),W=i("zoom"),X=i(" it\r\n will reset and zoom the map as far as it can go and have all markers in the view."),Y=u(),_=t("div"),aa=t("div"),k(sa.$$.fragment),this.h()},l(a){m('[data-svelte="svelte-uezrq0"]',document.head).forEach(o),s=h(a),n=p(a,"DIV",{class:!0});var t=e(n);b=p(t,"DIV",{class:!0});var c=e(b);D=p(c,"DIV",{class:!0});var l=e(D);I=p(l,"A",{href:!0});var r=e(I);M=f(r,"←Examples"),r.forEach(o),z=h(l),V=p(l,"H4",{});var u=e(V);j=f(u,"Multiple markers that are far apart "),P=p(u,"SPAN",{class:!0});var i=e(P);Z=f(i,"@0.0.4^"),i.forEach(o),u.forEach(o),q=h(l),C=p(l,"P",{});var k=e(C);H=f(k,"Recenter and set map view to center of both the locations or a set of\r\n markers."),k.forEach(o),L=h(l),g(N.$$.fragment,l),O=h(l),R=p(l,"H4",{});var v=e(R);A=f(v,"Note"),v.forEach(o),S=h(l),T=p(l,"P",{});var d=e(T);B=p(d,"CODE",{});var E=e(B);F=f(E,"recenter"),E.forEach(o),G=f(d," by default is false, setting it to true and "),J=p(d,"CODE",{});var w=e(J);K=f(w,"maxZoom/minZoom"),w.forEach(o),Q=f(d,"\r\n values will not work, however if you give value for "),U=p(d,"CODE",{});var $=e(U);W=f($,"zoom"),$.forEach(o),X=f(d," it\r\n will reset and zoom the map as far as it can go and have all markers in the view."),d.forEach(o),l.forEach(o),Y=h(c),_=p(c,"DIV",{class:!0});var y=e(_);aa=p(y,"DIV",{class:!0});var x=e(aa);g(sa.$$.fragment,x),x.forEach(o),y.forEach(o),c.forEach(o),t.forEach(o),this.h()},h(){document.title="Multiple markers that are far apart",c(I,"href","examples"),c(P,"class","chip"),c(D,"class","col-6"),c(aa,"class","map svelte-dt8ylx"),c(_,"class","col-6"),c(b,"class","row is-center"),c(n,"class","container")},m(a,t){l(a,s,t),l(a,n,t),v(n,b),v(b,D),v(D,I),v(I,M),v(D,z),v(D,V),v(V,j),v(V,P),v(P,Z),v(D,q),v(D,C),v(C,H),v(D,L),d(N,D,null),v(D,O),v(D,R),v(R,A),v(D,S),v(D,T),v(T,B),v(B,F),v(T,G),v(T,J),v(J,K),v(T,Q),v(T,U),v(U,W),v(T,X),v(b,Y),v(b,_),v(_,aa),d(sa,aa,null),na=!0},p:r,i(a){na||(E(N.$$.fragment,a),E(sa.$$.fragment,a),na=!0)},o(a){w(N.$$.fragment,a),w(sa.$$.fragment,a),na=!1},d(a){a&&o(s),a&&o(n),$(N),$(sa)}}}function I(a){return[{recenter:!0,markers:[{lat:1,lng:1},{lat:13,lng:80}],mapID:"map"}]}export default class extends a{constructor(a){super(),s(this,a,I,D,n,{})}} 2 | -------------------------------------------------------------------------------- /public/client/autocenter.1dd29cbf.js: -------------------------------------------------------------------------------- 1 | import{S as a,i as s,s as n,e as t,c as p,a as e,d as o,b as c,f as l,n as r,g as u,t as i,h as k,q as m,j as h,k as f,l as g,m as v,o as d,p as E,r as w,u as $}from"./client.27f5503e.js";import{L as y}from"./Leaflet.764aae6b.js";function b(a){let s;return{c(){s=t("pre"),this.h()},l(a){s=p(a,"PRE",{class:!0}),e(s).forEach(o),this.h()},h(){c(s,"class","language-html")},m(a,n){l(a,s,n),s.innerHTML='<script>\n import Map from "@anoram/leaflet-svelte";\n let options = {\n recenter: true,\n markers: [\n {\n lat: 1,\n lng: 1,\n },\n {\n lat: 13,\n lng: 80,\n },\n ],\n mapID: "map",\n\n };\n \n</script>\n\n<style>\n .map {\n height: 600px;\n width: auto;\n }\n\n</style>\n\n\n<div class="map">\n <Map {options} />\n</div>'},p:r,i:r,o:r,d(a){a&&o(s)}}}class x extends a{constructor(a){super(),s(this,a,null,b,n,{})}}function D(a){let s,n,b,D,I,M,z,V,j,P,Z,q,C,H,L,N,O,R,A,S,T,B,F,G,J,K,Q,U,W,X,Y,_,aa,sa,na;return N=new x({}),sa=new y({props:{options:a[0]}}),{c(){s=u(),n=t("div"),b=t("div"),D=t("div"),I=t("a"),M=i("←Examples"),z=u(),V=t("h4"),j=i("Multiple markers that are far apart "),P=t("span"),Z=i("@0.0.4^"),q=u(),C=t("p"),H=i("Recenter and set map view to center of both the locations or a set of\r\n markers."),L=u(),k(N.$$.fragment),O=u(),R=t("h4"),A=i("Note"),S=u(),T=t("p"),B=t("code"),F=i("recenter"),G=i(" by default is false, setting it to true and "),J=t("code"),K=i("maxZoom/minZoom"),Q=i("\r\n values will not work, however if you give value for "),U=t("code"),W=i("zoom"),X=i(" it\r\n will reset and zoom the map as far as it can go and have all markers in the view."),Y=u(),_=t("div"),aa=t("div"),k(sa.$$.fragment),this.h()},l(a){m('[data-svelte="svelte-uezrq0"]',document.head).forEach(o),s=h(a),n=p(a,"DIV",{class:!0});var t=e(n);b=p(t,"DIV",{class:!0});var c=e(b);D=p(c,"DIV",{class:!0});var l=e(D);I=p(l,"A",{href:!0});var r=e(I);M=f(r,"←Examples"),r.forEach(o),z=h(l),V=p(l,"H4",{});var u=e(V);j=f(u,"Multiple markers that are far apart "),P=p(u,"SPAN",{class:!0});var i=e(P);Z=f(i,"@0.0.4^"),i.forEach(o),u.forEach(o),q=h(l),C=p(l,"P",{});var k=e(C);H=f(k,"Recenter and set map view to center of both the locations or a set of\r\n markers."),k.forEach(o),L=h(l),g(N.$$.fragment,l),O=h(l),R=p(l,"H4",{});var v=e(R);A=f(v,"Note"),v.forEach(o),S=h(l),T=p(l,"P",{});var d=e(T);B=p(d,"CODE",{});var E=e(B);F=f(E,"recenter"),E.forEach(o),G=f(d," by default is false, setting it to true and "),J=p(d,"CODE",{});var w=e(J);K=f(w,"maxZoom/minZoom"),w.forEach(o),Q=f(d,"\r\n values will not work, however if you give value for "),U=p(d,"CODE",{});var $=e(U);W=f($,"zoom"),$.forEach(o),X=f(d," it\r\n will reset and zoom the map as far as it can go and have all markers in the view."),d.forEach(o),l.forEach(o),Y=h(c),_=p(c,"DIV",{class:!0});var y=e(_);aa=p(y,"DIV",{class:!0});var x=e(aa);g(sa.$$.fragment,x),x.forEach(o),y.forEach(o),c.forEach(o),t.forEach(o),this.h()},h(){document.title="Multiple markers that are far apart",c(I,"href","examples"),c(P,"class","chip"),c(D,"class","col-6"),c(aa,"class","map svelte-dt8ylx"),c(_,"class","col-6"),c(b,"class","row is-center"),c(n,"class","container")},m(a,t){l(a,s,t),l(a,n,t),v(n,b),v(b,D),v(D,I),v(I,M),v(D,z),v(D,V),v(V,j),v(V,P),v(P,Z),v(D,q),v(D,C),v(C,H),v(D,L),d(N,D,null),v(D,O),v(D,R),v(R,A),v(D,S),v(D,T),v(T,B),v(B,F),v(T,G),v(T,J),v(J,K),v(T,Q),v(T,U),v(U,W),v(T,X),v(b,Y),v(b,_),v(_,aa),d(sa,aa,null),na=!0},p:r,i(a){na||(E(N.$$.fragment,a),E(sa.$$.fragment,a),na=!0)},o(a){w(N.$$.fragment,a),w(sa.$$.fragment,a),na=!1},d(a){a&&o(s),a&&o(n),$(N),$(sa)}}}function I(a){return[{recenter:!0,markers:[{lat:1,lng:1},{lat:13,lng:80}],mapID:"map"}]}export default class extends a{constructor(a){super(),s(this,a,I,D,n,{})}} 2 | -------------------------------------------------------------------------------- /public/client/autocenter.4d4d70e7.js: -------------------------------------------------------------------------------- 1 | import{S as a,i as s,s as n,e as t,c as p,a as e,d as o,b as c,f as l,n as r,g as u,t as i,h as k,q as m,j as h,k as f,l as g,m as v,o as d,p as E,r as w,u as $}from"./client.cad504f2.js";import{L as y}from"./Leaflet.399e6cc7.js";function b(a){let s;return{c(){s=t("pre"),this.h()},l(a){s=p(a,"PRE",{class:!0}),e(s).forEach(o),this.h()},h(){c(s,"class","language-html")},m(a,n){l(a,s,n),s.innerHTML='<script>\n import Map from "@anoram/leaflet-svelte";\n let options = {\n recenter: true,\n markers: [\n {\n lat: 1,\n lng: 1,\n },\n {\n lat: 13,\n lng: 80,\n },\n ],\n mapID: "map",\n\n };\n \n</script>\n\n<style>\n .map {\n height: 600px;\n width: auto;\n }\n\n</style>\n\n\n<div class="map">\n <Map {options} />\n</div>'},p:r,i:r,o:r,d(a){a&&o(s)}}}class x extends a{constructor(a){super(),s(this,a,null,b,n,{})}}function D(a){let s,n,b,D,I,M,z,V,j,P,Z,q,C,H,L,N,O,R,A,S,T,B,F,G,J,K,Q,U,W,X,Y,_,aa,sa,na;return N=new x({}),sa=new y({props:{options:a[0]}}),{c(){s=u(),n=t("div"),b=t("div"),D=t("div"),I=t("a"),M=i("←Examples"),z=u(),V=t("h4"),j=i("Multiple markers that are far apart "),P=t("span"),Z=i("@0.0.4^"),q=u(),C=t("p"),H=i("Recenter and set map view to center of both the locations or a set of\r\n markers."),L=u(),k(N.$$.fragment),O=u(),R=t("h4"),A=i("Note"),S=u(),T=t("p"),B=t("code"),F=i("recenter"),G=i(" by default is false, setting it to true and "),J=t("code"),K=i("maxZoom/minZoom"),Q=i("\r\n values will not work, however if you give value for "),U=t("code"),W=i("zoom"),X=i(" it\r\n will reset and zoom the map as far as it can go and have all markers in the view."),Y=u(),_=t("div"),aa=t("div"),k(sa.$$.fragment),this.h()},l(a){m('[data-svelte="svelte-uezrq0"]',document.head).forEach(o),s=h(a),n=p(a,"DIV",{class:!0});var t=e(n);b=p(t,"DIV",{class:!0});var c=e(b);D=p(c,"DIV",{class:!0});var l=e(D);I=p(l,"A",{href:!0});var r=e(I);M=f(r,"←Examples"),r.forEach(o),z=h(l),V=p(l,"H4",{});var u=e(V);j=f(u,"Multiple markers that are far apart "),P=p(u,"SPAN",{class:!0});var i=e(P);Z=f(i,"@0.0.4^"),i.forEach(o),u.forEach(o),q=h(l),C=p(l,"P",{});var k=e(C);H=f(k,"Recenter and set map view to center of both the locations or a set of\r\n markers."),k.forEach(o),L=h(l),g(N.$$.fragment,l),O=h(l),R=p(l,"H4",{});var v=e(R);A=f(v,"Note"),v.forEach(o),S=h(l),T=p(l,"P",{});var d=e(T);B=p(d,"CODE",{});var E=e(B);F=f(E,"recenter"),E.forEach(o),G=f(d," by default is false, setting it to true and "),J=p(d,"CODE",{});var w=e(J);K=f(w,"maxZoom/minZoom"),w.forEach(o),Q=f(d,"\r\n values will not work, however if you give value for "),U=p(d,"CODE",{});var $=e(U);W=f($,"zoom"),$.forEach(o),X=f(d," it\r\n will reset and zoom the map as far as it can go and have all markers in the view."),d.forEach(o),l.forEach(o),Y=h(c),_=p(c,"DIV",{class:!0});var y=e(_);aa=p(y,"DIV",{class:!0});var x=e(aa);g(sa.$$.fragment,x),x.forEach(o),y.forEach(o),c.forEach(o),t.forEach(o),this.h()},h(){document.title="Multiple markers that are far apart",c(I,"href","examples"),c(P,"class","chip"),c(D,"class","col-6"),c(aa,"class","map svelte-dt8ylx"),c(_,"class","col-6"),c(b,"class","row is-center"),c(n,"class","container")},m(a,t){l(a,s,t),l(a,n,t),v(n,b),v(b,D),v(D,I),v(I,M),v(D,z),v(D,V),v(V,j),v(V,P),v(P,Z),v(D,q),v(D,C),v(C,H),v(D,L),d(N,D,null),v(D,O),v(D,R),v(R,A),v(D,S),v(D,T),v(T,B),v(B,F),v(T,G),v(T,J),v(J,K),v(T,Q),v(T,U),v(U,W),v(T,X),v(b,Y),v(b,_),v(_,aa),d(sa,aa,null),na=!0},p:r,i(a){na||(E(N.$$.fragment,a),E(sa.$$.fragment,a),na=!0)},o(a){w(N.$$.fragment,a),w(sa.$$.fragment,a),na=!1},d(a){a&&o(s),a&&o(n),$(N),$(sa)}}}function I(a){return[{recenter:!0,markers:[{lat:1,lng:1},{lat:13,lng:80}],mapID:"map"}]}export default class extends a{constructor(a){super(),s(this,a,I,D,n,{})}} 2 | -------------------------------------------------------------------------------- /public/client/autocenter.72f27238.js: -------------------------------------------------------------------------------- 1 | import{S as a,i as s,s as n,e as t,c as p,a as e,d as o,b as c,f as l,n as r,g as u,t as i,h as k,q as m,j as h,k as f,l as g,m as v,o as d,p as E,r as w,u as $}from"./client.bba8b1e3.js";import{L as b}from"./Leaflet.1fd8bc0e.js";function y(a){let s;return{c(){s=t("pre"),this.h()},l(a){s=p(a,"PRE",{class:!0}),e(s).forEach(o),this.h()},h(){c(s,"class","language-html")},m(a,n){l(a,s,n),s.innerHTML='<script>\n import Map from "@anoram/leaflet-svelte";\n let options = {\n recenter: true,\n markers: [\n {\n lat: 1,\n lng: 1,\n },\n {\n lat: 13,\n lng: 80,\n },\n ],\n mapID: "map",\n\n };\n \n</script>\n\n<style>\n .map {\n height: 600px;\n width: auto;\n }\n\n</style>\n\n\n<div class="map">\n <Map {options} />\n</div>'},p:r,i:r,o:r,d(a){a&&o(s)}}}class x extends a{constructor(a){super(),s(this,a,null,y,n,{})}}function D(a){let s,n,y,D,I,M,z,V,j,P,Z,q,C,H,L,N,O,R,A,S,T,B,F,G,J,K,Q,U,W,X,Y,_,aa,sa,na;return N=new x({}),sa=new b({props:{options:a[0]}}),{c(){s=u(),n=t("div"),y=t("div"),D=t("div"),I=t("a"),M=i("←Examples"),z=u(),V=t("h4"),j=i("Multiple markers that are far apart "),P=t("span"),Z=i("@0.0.4^"),q=u(),C=t("p"),H=i("Recenter and set map view to center of both the locations or a set of\r\n markers."),L=u(),k(N.$$.fragment),O=u(),R=t("h4"),A=i("Note"),S=u(),T=t("p"),B=t("code"),F=i("recenter"),G=i(" by default is false, setting it to true and "),J=t("code"),K=i("maxZoom/minZoom"),Q=i("\r\n values will not work, however if you give value for "),U=t("code"),W=i("zoom"),X=i(" it\r\n will reset and zoom the map as far as it can go and have all markers in the view."),Y=u(),_=t("div"),aa=t("div"),k(sa.$$.fragment),this.h()},l(a){m('[data-svelte="svelte-uezrq0"]',document.head).forEach(o),s=h(a),n=p(a,"DIV",{class:!0});var t=e(n);y=p(t,"DIV",{class:!0});var c=e(y);D=p(c,"DIV",{class:!0});var l=e(D);I=p(l,"A",{href:!0});var r=e(I);M=f(r,"←Examples"),r.forEach(o),z=h(l),V=p(l,"H4",{});var u=e(V);j=f(u,"Multiple markers that are far apart "),P=p(u,"SPAN",{class:!0});var i=e(P);Z=f(i,"@0.0.4^"),i.forEach(o),u.forEach(o),q=h(l),C=p(l,"P",{});var k=e(C);H=f(k,"Recenter and set map view to center of both the locations or a set of\r\n markers."),k.forEach(o),L=h(l),g(N.$$.fragment,l),O=h(l),R=p(l,"H4",{});var v=e(R);A=f(v,"Note"),v.forEach(o),S=h(l),T=p(l,"P",{});var d=e(T);B=p(d,"CODE",{});var E=e(B);F=f(E,"recenter"),E.forEach(o),G=f(d," by default is false, setting it to true and "),J=p(d,"CODE",{});var w=e(J);K=f(w,"maxZoom/minZoom"),w.forEach(o),Q=f(d,"\r\n values will not work, however if you give value for "),U=p(d,"CODE",{});var $=e(U);W=f($,"zoom"),$.forEach(o),X=f(d," it\r\n will reset and zoom the map as far as it can go and have all markers in the view."),d.forEach(o),l.forEach(o),Y=h(c),_=p(c,"DIV",{class:!0});var b=e(_);aa=p(b,"DIV",{class:!0});var x=e(aa);g(sa.$$.fragment,x),x.forEach(o),b.forEach(o),c.forEach(o),t.forEach(o),this.h()},h(){document.title="Multiple markers that are far apart",c(I,"href","examples"),c(P,"class","chip"),c(D,"class","col-6"),c(aa,"class","map svelte-dt8ylx"),c(_,"class","col-6"),c(y,"class","row is-center"),c(n,"class","container")},m(a,t){l(a,s,t),l(a,n,t),v(n,y),v(y,D),v(D,I),v(I,M),v(D,z),v(D,V),v(V,j),v(V,P),v(P,Z),v(D,q),v(D,C),v(C,H),v(D,L),d(N,D,null),v(D,O),v(D,R),v(R,A),v(D,S),v(D,T),v(T,B),v(B,F),v(T,G),v(T,J),v(J,K),v(T,Q),v(T,U),v(U,W),v(T,X),v(y,Y),v(y,_),v(_,aa),d(sa,aa,null),na=!0},p:r,i(a){na||(E(N.$$.fragment,a),E(sa.$$.fragment,a),na=!0)},o(a){w(N.$$.fragment,a),w(sa.$$.fragment,a),na=!1},d(a){a&&o(s),a&&o(n),$(N),$(sa)}}}function I(a){return[{recenter:!0,markers:[{lat:1,lng:1},{lat:13,lng:80}],mapID:"map"}]}export default class extends a{constructor(a){super(),s(this,a,I,D,n,{})}} 2 | -------------------------------------------------------------------------------- /public/client/autocenter.f9d22676.js: -------------------------------------------------------------------------------- 1 | import{S as a,i as s,s as n,e as t,c as p,a as e,d as o,b as c,f as l,n as r,g as u,t as i,h as k,q as m,j as f,k as h,l as g,m as v,o as d,p as E,r as w,u as $}from"./client.47f8a5db.js";import{L as y}from"./Leaflet.6481def0.js";function b(a){let s;return{c(){s=t("pre"),this.h()},l(a){s=p(a,"PRE",{class:!0}),e(s).forEach(o),this.h()},h(){c(s,"class","language-html")},m(a,n){l(a,s,n),s.innerHTML='<script>\n import Map from "@anoram/leaflet-svelte";\n let options = {\n recenter: true,\n markers: [\n {\n lat: 1,\n lng: 1,\n },\n {\n lat: 13,\n lng: 80,\n },\n ],\n mapID: "map",\n\n };\n \n</script>\n\n<style>\n .map {\n height: 600px;\n width: auto;\n }\n\n</style>\n\n\n<div class="map">\n <Map {options} />\n</div>'},p:r,i:r,o:r,d(a){a&&o(s)}}}class x extends a{constructor(a){super(),s(this,a,null,b,n,{})}}function D(a){let s,n,b,D,I,M,z,V,j,P,Z,q,C,H,L,N,O,R,A,S,T,B,F,G,J,K,Q,U,W,X,Y,_,aa,sa,na;return N=new x({}),sa=new y({props:{options:a[0]}}),{c(){s=u(),n=t("div"),b=t("div"),D=t("div"),I=t("a"),M=i("←Examples"),z=u(),V=t("h4"),j=i("Multiple markers that are far apart "),P=t("span"),Z=i("@0.0.4^"),q=u(),C=t("p"),H=i("Recenter and set map view to center of both the locations or a set of\r\n markers."),L=u(),k(N.$$.fragment),O=u(),R=t("h4"),A=i("Note"),S=u(),T=t("p"),B=t("code"),F=i("recenter"),G=i(" by default is false, setting it to true and "),J=t("code"),K=i("maxZoom/minZoom"),Q=i("\r\n values will not work, however if you give value for "),U=t("code"),W=i("zoom"),X=i(" it\r\n will reset and zoom the map as far as it can go and have all markers in the view."),Y=u(),_=t("div"),aa=t("div"),k(sa.$$.fragment),this.h()},l(a){m('[data-svelte="svelte-uezrq0"]',document.head).forEach(o),s=f(a),n=p(a,"DIV",{class:!0});var t=e(n);b=p(t,"DIV",{class:!0});var c=e(b);D=p(c,"DIV",{class:!0});var l=e(D);I=p(l,"A",{href:!0});var r=e(I);M=h(r,"←Examples"),r.forEach(o),z=f(l),V=p(l,"H4",{});var u=e(V);j=h(u,"Multiple markers that are far apart "),P=p(u,"SPAN",{class:!0});var i=e(P);Z=h(i,"@0.0.4^"),i.forEach(o),u.forEach(o),q=f(l),C=p(l,"P",{});var k=e(C);H=h(k,"Recenter and set map view to center of both the locations or a set of\r\n markers."),k.forEach(o),L=f(l),g(N.$$.fragment,l),O=f(l),R=p(l,"H4",{});var v=e(R);A=h(v,"Note"),v.forEach(o),S=f(l),T=p(l,"P",{});var d=e(T);B=p(d,"CODE",{});var E=e(B);F=h(E,"recenter"),E.forEach(o),G=h(d," by default is false, setting it to true and "),J=p(d,"CODE",{});var w=e(J);K=h(w,"maxZoom/minZoom"),w.forEach(o),Q=h(d,"\r\n values will not work, however if you give value for "),U=p(d,"CODE",{});var $=e(U);W=h($,"zoom"),$.forEach(o),X=h(d," it\r\n will reset and zoom the map as far as it can go and have all markers in the view."),d.forEach(o),l.forEach(o),Y=f(c),_=p(c,"DIV",{class:!0});var y=e(_);aa=p(y,"DIV",{class:!0});var x=e(aa);g(sa.$$.fragment,x),x.forEach(o),y.forEach(o),c.forEach(o),t.forEach(o),this.h()},h(){document.title="Multiple markers that are far apart",c(I,"href","examples"),c(P,"class","chip"),c(D,"class","col-6"),c(aa,"class","map svelte-dt8ylx"),c(_,"class","col-6"),c(b,"class","row is-center"),c(n,"class","container")},m(a,t){l(a,s,t),l(a,n,t),v(n,b),v(b,D),v(D,I),v(I,M),v(D,z),v(D,V),v(V,j),v(V,P),v(P,Z),v(D,q),v(D,C),v(C,H),v(D,L),d(N,D,null),v(D,O),v(D,R),v(R,A),v(D,S),v(D,T),v(T,B),v(B,F),v(T,G),v(T,J),v(J,K),v(T,Q),v(T,U),v(U,W),v(T,X),v(b,Y),v(b,_),v(_,aa),d(sa,aa,null),na=!0},p:r,i(a){na||(E(N.$$.fragment,a),E(sa.$$.fragment,a),na=!0)},o(a){w(N.$$.fragment,a),w(sa.$$.fragment,a),na=!1},d(a){a&&o(s),a&&o(n),$(N),$(sa)}}}function I(a){return[{recenter:!0,markers:[{lat:1,lng:1},{lat:13,lng:80}],mapID:"map"}]}export default class extends a{constructor(a){super(),s(this,a,I,D,n,{})}} 2 | -------------------------------------------------------------------------------- /public/client/disablescrollwheelzoom.165d01fa.js: -------------------------------------------------------------------------------- 1 | import{S as s,i as a,s as n,e as t,c as o,a as p,d as e,b as l,f as c,n as r,g as u,t as i,h as k,q as m,j as h,k as f,l as g,m as d,o as v,p as b,r as E,u as y}from"./client.a52649eb.js";import{L as $}from"./Leaflet.1975f146.js";function z(s){let a;return{c(){a=t("pre"),this.h()},l(s){a=o(s,"PRE",{class:!0}),p(a).forEach(e),this.h()},h(){l(a,"class","language-html")},m(s,n){c(s,a,n),a.innerHTML='<script>\n import Map from "@anoram/leaflet-svelte";\n let options = {\n recenter: true,\n zoom: 5,\n markers: [\n {\n lat: 8,\n lng: 8,\n },\n {\n lat: 13,\n lng: 80,\n },\n ],\n controls: {\n zoomControl: true,\n },\n scrollWheelZoom: false,\n mapID: "map",\n attributionControl: true,\n };\n \n</script>\n\n<style>\n .map {\n height: 600px;\n width: auto;\n }\n\n</style>\n\n\n<div class="map">\n <Map {options} />\n</div>'},p:r,i:r,o:r,d(s){s&&e(a)}}}class w extends s{constructor(s){super(),a(this,s,null,z,n,{})}}function D(s){let a,n,z,D,x,C,I,V,j,P,W,Z,H,L,M,N,q,A,O,S,R,T,B,F,G,J,K,Q,U,X,Y,_,ss="controls: {zoomControl: true }";return N=new w({}),Y=new $({props:{options:s[0]}}),{c(){a=u(),n=t("div"),z=t("div"),D=t("div"),x=t("a"),C=i("←Examples"),I=u(),V=t("h4"),j=i("Disable scroll wheel zoom "),P=t("span"),W=i("@0.0.4^"),Z=u(),H=t("p"),L=i("Disables mouse wheel intereactions for zoom and allows only zoom via\r\n controls."),M=u(),k(N.$$.fragment),q=u(),A=t("h4"),O=i("Note"),S=u(),R=t("p"),T=t("code"),B=i("scrollWheelZoom"),F=i(" by default is true additionally you can remove the zoom control element by setting "),G=t("code"),J=i(ss),K=i(" to false."),Q=u(),U=t("div"),X=t("div"),k(Y.$$.fragment),this.h()},l(s){m('[data-svelte="svelte-50lzuc"]',document.head).forEach(e),a=h(s),n=o(s,"DIV",{class:!0});var t=p(n);z=o(t,"DIV",{class:!0});var l=p(z);D=o(l,"DIV",{class:!0});var c=p(D);x=o(c,"A",{href:!0});var r=p(x);C=f(r,"←Examples"),r.forEach(e),I=h(c),V=o(c,"H4",{});var u=p(V);j=f(u,"Disable scroll wheel zoom "),P=o(u,"SPAN",{class:!0});var i=p(P);W=f(i,"@0.0.4^"),i.forEach(e),u.forEach(e),Z=h(c),H=o(c,"P",{});var k=p(H);L=f(k,"Disables mouse wheel intereactions for zoom and allows only zoom via\r\n controls."),k.forEach(e),M=h(c),g(N.$$.fragment,c),q=h(c),A=o(c,"H4",{});var d=p(A);O=f(d,"Note"),d.forEach(e),S=h(c),R=o(c,"P",{});var v=p(R);T=o(v,"CODE",{});var b=p(T);B=f(b,"scrollWheelZoom"),b.forEach(e),F=f(v," by default is true additionally you can remove the zoom control element by setting "),G=o(v,"CODE",{});var E=p(G);J=f(E,ss),E.forEach(e),K=f(v," to false."),v.forEach(e),c.forEach(e),Q=h(l),U=o(l,"DIV",{class:!0});var y=p(U);X=o(y,"DIV",{class:!0});var $=p(X);g(Y.$$.fragment,$),$.forEach(e),y.forEach(e),l.forEach(e),t.forEach(e),this.h()},h(){document.title="Disable scroll wheel zoom",l(x,"href","examples"),l(P,"class","chip"),l(D,"class","col-6"),l(X,"class","map svelte-dt8ylx"),l(U,"class","col-6"),l(z,"class","row is-center"),l(n,"class","container")},m(s,t){c(s,a,t),c(s,n,t),d(n,z),d(z,D),d(D,x),d(x,C),d(D,I),d(D,V),d(V,j),d(V,P),d(P,W),d(D,Z),d(D,H),d(H,L),d(D,M),v(N,D,null),d(D,q),d(D,A),d(A,O),d(D,S),d(D,R),d(R,T),d(T,B),d(R,F),d(R,G),d(G,J),d(R,K),d(z,Q),d(z,U),d(U,X),v(Y,X,null),_=!0},p:r,i(s){_||(b(N.$$.fragment,s),b(Y.$$.fragment,s),_=!0)},o(s){E(N.$$.fragment,s),E(Y.$$.fragment,s),_=!1},d(s){s&&e(a),s&&e(n),y(N),y(Y)}}}function x(s){return[{recenter:!0,zoom:5,markers:[{lat:8,lng:8},{lat:13,lng:80}],controls:{zoomControl:!0},scrollWheelZoom:!1,mapID:"map",attributionControl:!0}]}export default class extends s{constructor(s){super(),a(this,s,x,D,n,{})}} 2 | -------------------------------------------------------------------------------- /public/client/disablescrollwheelzoom.770e47da.js: -------------------------------------------------------------------------------- 1 | import{S as a,i as s,s as n,e as t,c as o,a as p,d as e,b as l,f as c,n as r,g as u,t as i,h as k,q as m,j as h,k as f,l as g,m as d,o as v,p as b,r as E,u as y}from"./client.27f5503e.js";import{L as $}from"./Leaflet.764aae6b.js";function z(a){let s;return{c(){s=t("pre"),this.h()},l(a){s=o(a,"PRE",{class:!0}),p(s).forEach(e),this.h()},h(){l(s,"class","language-html")},m(a,n){c(a,s,n),s.innerHTML='<script>\n import Map from "@anoram/leaflet-svelte";\n let options = {\n recenter: true,\n zoom: 5,\n markers: [\n {\n lat: 8,\n lng: 8,\n },\n {\n lat: 13,\n lng: 80,\n },\n ],\n controls: {\n zoomControl: true,\n },\n scrollWheelZoom: false,\n mapID: "map",\n attributionControl: true,\n };\n \n</script>\n\n<style>\n .map {\n height: 600px;\n width: auto;\n }\n\n</style>\n\n\n<div class="map">\n <Map {options} />\n</div>'},p:r,i:r,o:r,d(a){a&&e(s)}}}class w extends a{constructor(a){super(),s(this,a,null,z,n,{})}}function D(a){let s,n,z,D,x,C,I,V,j,P,W,Z,H,L,M,N,q,A,O,S,R,T,B,F,G,J,K,Q,U,X,Y,_,aa="controls: {zoomControl: true }";return N=new w({}),Y=new $({props:{options:a[0]}}),{c(){s=u(),n=t("div"),z=t("div"),D=t("div"),x=t("a"),C=i("←Examples"),I=u(),V=t("h4"),j=i("Disable scroll wheel zoom "),P=t("span"),W=i("@0.0.4^"),Z=u(),H=t("p"),L=i("Disables mouse wheel intereactions for zoom and allows only zoom via\r\n controls."),M=u(),k(N.$$.fragment),q=u(),A=t("h4"),O=i("Note"),S=u(),R=t("p"),T=t("code"),B=i("scrollWheelZoom"),F=i(" by default is true additionally you can remove the zoom control element by setting "),G=t("code"),J=i(aa),K=i(" to false."),Q=u(),U=t("div"),X=t("div"),k(Y.$$.fragment),this.h()},l(a){m('[data-svelte="svelte-50lzuc"]',document.head).forEach(e),s=h(a),n=o(a,"DIV",{class:!0});var t=p(n);z=o(t,"DIV",{class:!0});var l=p(z);D=o(l,"DIV",{class:!0});var c=p(D);x=o(c,"A",{href:!0});var r=p(x);C=f(r,"←Examples"),r.forEach(e),I=h(c),V=o(c,"H4",{});var u=p(V);j=f(u,"Disable scroll wheel zoom "),P=o(u,"SPAN",{class:!0});var i=p(P);W=f(i,"@0.0.4^"),i.forEach(e),u.forEach(e),Z=h(c),H=o(c,"P",{});var k=p(H);L=f(k,"Disables mouse wheel intereactions for zoom and allows only zoom via\r\n controls."),k.forEach(e),M=h(c),g(N.$$.fragment,c),q=h(c),A=o(c,"H4",{});var d=p(A);O=f(d,"Note"),d.forEach(e),S=h(c),R=o(c,"P",{});var v=p(R);T=o(v,"CODE",{});var b=p(T);B=f(b,"scrollWheelZoom"),b.forEach(e),F=f(v," by default is true additionally you can remove the zoom control element by setting "),G=o(v,"CODE",{});var E=p(G);J=f(E,aa),E.forEach(e),K=f(v," to false."),v.forEach(e),c.forEach(e),Q=h(l),U=o(l,"DIV",{class:!0});var y=p(U);X=o(y,"DIV",{class:!0});var $=p(X);g(Y.$$.fragment,$),$.forEach(e),y.forEach(e),l.forEach(e),t.forEach(e),this.h()},h(){document.title="Disable scroll wheel zoom",l(x,"href","examples"),l(P,"class","chip"),l(D,"class","col-6"),l(X,"class","map svelte-dt8ylx"),l(U,"class","col-6"),l(z,"class","row is-center"),l(n,"class","container")},m(a,t){c(a,s,t),c(a,n,t),d(n,z),d(z,D),d(D,x),d(x,C),d(D,I),d(D,V),d(V,j),d(V,P),d(P,W),d(D,Z),d(D,H),d(H,L),d(D,M),v(N,D,null),d(D,q),d(D,A),d(A,O),d(D,S),d(D,R),d(R,T),d(T,B),d(R,F),d(R,G),d(G,J),d(R,K),d(z,Q),d(z,U),d(U,X),v(Y,X,null),_=!0},p:r,i(a){_||(b(N.$$.fragment,a),b(Y.$$.fragment,a),_=!0)},o(a){E(N.$$.fragment,a),E(Y.$$.fragment,a),_=!1},d(a){a&&e(s),a&&e(n),y(N),y(Y)}}}function x(a){return[{recenter:!0,zoom:5,markers:[{lat:8,lng:8},{lat:13,lng:80}],controls:{zoomControl:!0},scrollWheelZoom:!1,mapID:"map",attributionControl:!0}]}export default class extends a{constructor(a){super(),s(this,a,x,D,n,{})}} 2 | -------------------------------------------------------------------------------- /public/client/disablescrollwheelzoom.8872cf05.js: -------------------------------------------------------------------------------- 1 | import{S as s,i as a,s as n,e as t,c as o,a as p,d as e,b as l,f as c,n as r,g as u,t as i,h as k,q as m,j as h,k as f,l as g,m as d,o as v,p as b,r as E,u as y}from"./client.47f8a5db.js";import{L as $}from"./Leaflet.6481def0.js";function z(s){let a;return{c(){a=t("pre"),this.h()},l(s){a=o(s,"PRE",{class:!0}),p(a).forEach(e),this.h()},h(){l(a,"class","language-html")},m(s,n){c(s,a,n),a.innerHTML='<script>\n import Map from "@anoram/leaflet-svelte";\n let options = {\n recenter: true,\n zoom: 5,\n markers: [\n {\n lat: 8,\n lng: 8,\n },\n {\n lat: 13,\n lng: 80,\n },\n ],\n controls: {\n zoomControl: true,\n },\n scrollWheelZoom: false,\n mapID: "map",\n attributionControl: true,\n };\n \n</script>\n\n<style>\n .map {\n height: 600px;\n width: auto;\n }\n\n</style>\n\n\n<div class="map">\n <Map {options} />\n</div>'},p:r,i:r,o:r,d(s){s&&e(a)}}}class w extends s{constructor(s){super(),a(this,s,null,z,n,{})}}function D(s){let a,n,z,D,x,C,I,V,j,P,W,Z,H,L,M,N,q,A,O,S,R,T,B,F,G,J,K,Q,U,X,Y,_,ss="controls: {zoomControl: true }";return N=new w({}),Y=new $({props:{options:s[0]}}),{c(){a=u(),n=t("div"),z=t("div"),D=t("div"),x=t("a"),C=i("←Examples"),I=u(),V=t("h4"),j=i("Disable scroll wheel zoom "),P=t("span"),W=i("@0.0.4^"),Z=u(),H=t("p"),L=i("Disables mouse wheel intereactions for zoom and allows only zoom via\r\n controls."),M=u(),k(N.$$.fragment),q=u(),A=t("h4"),O=i("Note"),S=u(),R=t("p"),T=t("code"),B=i("scrollWheelZoom"),F=i(" by default is true additionally you can remove the zoom control element by setting "),G=t("code"),J=i(ss),K=i(" to false."),Q=u(),U=t("div"),X=t("div"),k(Y.$$.fragment),this.h()},l(s){m('[data-svelte="svelte-50lzuc"]',document.head).forEach(e),a=h(s),n=o(s,"DIV",{class:!0});var t=p(n);z=o(t,"DIV",{class:!0});var l=p(z);D=o(l,"DIV",{class:!0});var c=p(D);x=o(c,"A",{href:!0});var r=p(x);C=f(r,"←Examples"),r.forEach(e),I=h(c),V=o(c,"H4",{});var u=p(V);j=f(u,"Disable scroll wheel zoom "),P=o(u,"SPAN",{class:!0});var i=p(P);W=f(i,"@0.0.4^"),i.forEach(e),u.forEach(e),Z=h(c),H=o(c,"P",{});var k=p(H);L=f(k,"Disables mouse wheel intereactions for zoom and allows only zoom via\r\n controls."),k.forEach(e),M=h(c),g(N.$$.fragment,c),q=h(c),A=o(c,"H4",{});var d=p(A);O=f(d,"Note"),d.forEach(e),S=h(c),R=o(c,"P",{});var v=p(R);T=o(v,"CODE",{});var b=p(T);B=f(b,"scrollWheelZoom"),b.forEach(e),F=f(v," by default is true additionally you can remove the zoom control element by setting "),G=o(v,"CODE",{});var E=p(G);J=f(E,ss),E.forEach(e),K=f(v," to false."),v.forEach(e),c.forEach(e),Q=h(l),U=o(l,"DIV",{class:!0});var y=p(U);X=o(y,"DIV",{class:!0});var $=p(X);g(Y.$$.fragment,$),$.forEach(e),y.forEach(e),l.forEach(e),t.forEach(e),this.h()},h(){document.title="Disable scroll wheel zoom",l(x,"href","examples"),l(P,"class","chip"),l(D,"class","col-6"),l(X,"class","map svelte-dt8ylx"),l(U,"class","col-6"),l(z,"class","row is-center"),l(n,"class","container")},m(s,t){c(s,a,t),c(s,n,t),d(n,z),d(z,D),d(D,x),d(x,C),d(D,I),d(D,V),d(V,j),d(V,P),d(P,W),d(D,Z),d(D,H),d(H,L),d(D,M),v(N,D,null),d(D,q),d(D,A),d(A,O),d(D,S),d(D,R),d(R,T),d(T,B),d(R,F),d(R,G),d(G,J),d(R,K),d(z,Q),d(z,U),d(U,X),v(Y,X,null),_=!0},p:r,i(s){_||(b(N.$$.fragment,s),b(Y.$$.fragment,s),_=!0)},o(s){E(N.$$.fragment,s),E(Y.$$.fragment,s),_=!1},d(s){s&&e(a),s&&e(n),y(N),y(Y)}}}function x(s){return[{recenter:!0,zoom:5,markers:[{lat:8,lng:8},{lat:13,lng:80}],controls:{zoomControl:!0},scrollWheelZoom:!1,mapID:"map",attributionControl:!0}]}export default class extends s{constructor(s){super(),a(this,s,x,D,n,{})}} 2 | --------------------------------------------------------------------------------