MCPcopy Index your code
hub / github.com/Maps4HTML/MapML.js / min

Method min

src/map-feature.js:51–74  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

49 }
50
51 get min() {
52 // for templated or queried features ** native zoom is only used for zoomTo() **
53 let meta = {},
54 metaEl = this.getMeta('zoom');
55 if (metaEl)
56 meta = Util._metaContentToObject(metaEl.getAttribute('content'));
57 let projectionMinZoom = 0;
58 if (this._parentEl.nodeName === 'MAP-LINK') {
59 // minZoom = min attribute || sd.map-meta min zoom || map-link minZoom
60 return +(this.hasAttribute('min')
61 ? this.getAttribute('min')
62 : meta.min
63 ? meta.min
64 : this._parentEl.getZoomBounds().minZoom);
65 } else {
66 // for "static" features
67 // minZoom = min attribute || map-meta zoom || projection minZoom
68 return +(this.hasAttribute('min')
69 ? this.getAttribute('min')
70 : meta.min
71 ? meta.min
72 : projectionMinZoom);
73 }
74 }
75
76 set min(val) {
77 var parsedVal = parseInt(val, 10);

Callers

nothing calls this directly

Calls 5

getMetaMethod · 0.95
getLayerElMethod · 0.95
getAttributeMethod · 0.80
getZoomBoundsMethod · 0.80
setAttributeMethod · 0.80

Tested by

no test coverage detected