@metoceanapi/wxtiles-common 0.0.10 → 0.0.11-1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/.github/workflows/lint.yml +1 -1
- package/.github/workflows/validate-pull-request-title.yml +17 -0
- package/LICENSE.txt +1 -1
- package/biome.json +16 -3
- package/controls/WxAPIControl/WxAPIControl-busy.ts +16 -0
- package/controls/WxAPIControl/WxAPIControl-datasets.ts +102 -0
- package/controls/WxAPIControl/WxAPIControl-filter.ts +66 -0
- package/controls/WxAPIControl/WxAPIControl-variables.ts +73 -0
- package/controls/WxAPIControl.ts +87 -120
- package/controls/WxInfoControl.ts +87 -2
- package/controls/WxLegendControl.ts +28 -2
- package/controls/WxStyleEditorControl.ts +129 -7
- package/controls/WxTimeControl.ts +133 -5
- package/docs/docs/.nojekyll +1 -0
- package/docs/docs/assets/highlight.css +92 -0
- package/docs/docs/assets/icons.svg +1 -0
- package/docs/docs/assets/style.css +1610 -0
- package/docs/docs/classes/controls_WxAPIControl.WxAPIControl.html +28 -0
- package/docs/docs/classes/controls_WxInfoControl.WxInfoControl.html +20 -0
- package/docs/docs/classes/controls_WxLegendControl.WxLegendControl.html +19 -0
- package/docs/docs/classes/controls_WxStyleEditorControl.WxStyleEditorControl.html +111 -0
- package/docs/docs/classes/controls_WxTimeControl.WxTimeControl.html +28 -0
- package/docs/docs/classes/managers_BaseDatasetManager.BaseDatasetManager.html +104 -0
- package/docs/docs/classes/managers_WxAllDatasetsManager.WxAllDatasetsManager.html +24 -0
- package/docs/docs/classes/types.WxRasterDataCache.html +27 -0
- package/docs/docs/classes/utils_RawCLUT.RawCLUT.html +18 -0
- package/docs/docs/classes/utils_qtree.QTree.html +22 -0
- package/docs/docs/classes/utils_wxtools.DataIntegral.html +10 -0
- package/docs/docs/classes/wxapi.WxAPI.html +45 -0
- package/docs/docs/classes/wxlayer_loader.Loader.html +31 -0
- package/docs/docs/classes/wxlayer_painter.Painter.html +20 -0
- package/docs/docs/classes/wxlayer_wxlayer.WxLayer.html +57 -0
- package/docs/docs/enums/utils_qtree.TileType.html +5 -0
- package/docs/docs/functions/utils_RawCLUT.WxCreateLegend.html +5 -0
- package/docs/docs/functions/utils_mercator.LatLonToPixels.html +6 -0
- package/docs/docs/functions/utils_mercator.PixelsToLatLon.html +6 -0
- package/docs/docs/functions/utils_mercator.PixelsToLonLat.html +6 -0
- package/docs/docs/functions/utils_mercator.coordToPixel.html +5 -0
- package/docs/docs/functions/utils_tests_wxtools.tests.html +1 -0
- package/docs/docs/functions/utils_wxtools.HEXtoRGBA.html +3 -0
- package/docs/docs/functions/utils_wxtools.HashXYZ.html +4 -0
- package/docs/docs/functions/utils_wxtools.RGBAtoHEX.html +3 -0
- package/docs/docs/functions/utils_wxtools.RGBtoHEX.html +3 -0
- package/docs/docs/functions/utils_wxtools.WXLOG.html +2 -0
- package/docs/docs/functions/utils_wxtools.WxGetColorSchemes.html +2 -0
- package/docs/docs/functions/utils_wxtools.WxGetColorStyles.html +2 -0
- package/docs/docs/functions/utils_wxtools.WxTilesLibSetup.html +3 -0
- package/docs/docs/functions/utils_wxtools.WxTilesLogging.html +5 -0
- package/docs/docs/functions/utils_wxtools.blurData.html +7 -0
- package/docs/docs/functions/utils_wxtools.buildIntegralPare.html +6 -0
- package/docs/docs/functions/utils_wxtools.cacheUriPromise.html +2 -0
- package/docs/docs/functions/utils_wxtools.create2DContext.html +6 -0
- package/docs/docs/functions/utils_wxtools.createEl.html +5 -0
- package/docs/docs/functions/utils_wxtools.createLevels.html +6 -0
- package/docs/docs/functions/utils_wxtools.fetchJson.html +6 -0
- package/docs/docs/functions/utils_wxtools.getClosestTimeString.html +5 -0
- package/docs/docs/functions/utils_wxtools.loadDataIntegral.html +5 -0
- package/docs/docs/functions/utils_wxtools.loadImage.html +4 -0
- package/docs/docs/functions/utils_wxtools.loadImageData.html +5 -0
- package/docs/docs/functions/utils_wxtools.makeConverter.html +9 -0
- package/docs/docs/functions/utils_wxtools.mixColor.html +3 -0
- package/docs/docs/functions/utils_wxtools.refineColor.html +3 -0
- package/docs/docs/functions/utils_wxtools.uriXYZ.html +5 -0
- package/docs/docs/functions/wxlayer_WxImplementation.WxLayerBaseImplementationMixin.html +4 -0
- package/docs/docs/functions/wxlayer_loadertools.applyMask.html +10 -0
- package/docs/docs/functions/wxlayer_loadertools.makeBox.html +4 -0
- package/docs/docs/functions/wxlayer_loadertools.splitCoords.html +6 -0
- package/docs/docs/functions/wxlayer_loadertools.subData.html +5 -0
- package/docs/docs/functions/wxlayer_loadertools.subDataDegree.html +5 -0
- package/docs/docs/functions/wxlayer_loadertools.subMask.html +5 -0
- package/docs/docs/hierarchy.html +1 -0
- package/docs/docs/index.html +7 -0
- package/docs/docs/interfaces/types.IsoInfo.html +8 -0
- package/docs/docs/interfaces/types.SLinePoint.html +4 -0
- package/docs/docs/interfaces/types.WxAPIOptions.html +37 -0
- package/docs/docs/interfaces/types.WxAllBoundariesMeta.html +8 -0
- package/docs/docs/interfaces/types.WxAllDatasetsShortMetas.html +4 -0
- package/docs/docs/interfaces/types.WxBoundaryMeta.html +10 -0
- package/docs/docs/interfaces/types.WxData.html +10 -0
- package/docs/docs/interfaces/types.WxDataSetManagerOptions.html +14 -0
- package/docs/docs/interfaces/types.WxDatasetMeta.html +20 -0
- package/docs/docs/interfaces/types.WxDatasetShortMeta.html +9 -0
- package/docs/docs/interfaces/types.WxLayerAPI.html +24 -0
- package/docs/docs/interfaces/types.WxLayerBaseAPI.html +16 -0
- package/docs/docs/interfaces/types.WxLayerOptions.html +12 -0
- package/docs/docs/interfaces/types.WxLngLat.html +6 -0
- package/docs/docs/interfaces/types.WxRasterData.html +13 -0
- package/docs/docs/interfaces/types.WxRequestInit.html +3 -0
- package/docs/docs/interfaces/types.WxTileInfo.html +18 -0
- package/docs/docs/interfaces/types.WxVariableMeta.html +13 -0
- package/docs/docs/interfaces/types.WxVariablesMetas.html +4 -0
- package/docs/docs/interfaces/utils_RawCLUT.WxLegend.html +14 -0
- package/docs/docs/interfaces/utils_RawCLUT.WxTick.html +10 -0
- package/docs/docs/interfaces/utils_qtree.Tree.html +7 -0
- package/docs/docs/interfaces/utils_wxtools.CachedUriLoaderPromiseFunc.html +2 -0
- package/docs/docs/interfaces/utils_wxtools.ColorStylesIncomplete.html +2 -0
- package/docs/docs/interfaces/utils_wxtools.Converter.html +5 -0
- package/docs/docs/interfaces/utils_wxtools.DataPicture.html +6 -0
- package/docs/docs/interfaces/utils_wxtools.IntegralPare.html +6 -0
- package/docs/docs/interfaces/utils_wxtools.WxColorSchemes.html +3 -0
- package/docs/docs/interfaces/utils_wxtools.WxColorStyleStrict.html +95 -0
- package/docs/docs/interfaces/utils_wxtools.WxColorStyleWeak.html +95 -0
- package/docs/docs/interfaces/utils_wxtools.WxColorStylesStrict.html +2 -0
- package/docs/docs/interfaces/utils_wxtools.WxColorStylesWeakMixed.html +2 -0
- package/docs/docs/interfaces/utils_wxtools.WxTilesLibOptions.html +8 -0
- package/docs/docs/interfaces/utils_wxtools.WxUnits.html +2 -0
- package/docs/docs/interfaces/utils_wxtools.XYZ.html +5 -0
- package/docs/docs/modules/controls_WxAPIControl.html +1 -0
- package/docs/docs/modules/controls_WxInfoControl.html +1 -0
- package/docs/docs/modules/controls_WxLegendControl.html +1 -0
- package/docs/docs/modules/controls_WxStyleEditorControl.html +1 -0
- package/docs/docs/modules/controls_WxTimeControl.html +1 -0
- package/docs/docs/modules/defaults_colorschemes.html +1 -0
- package/docs/docs/modules/defaults_styles.html +1 -0
- package/docs/docs/modules/defaults_uconv.html +1 -0
- package/docs/docs/modules/managers_BaseDatasetManager.html +1 -0
- package/docs/docs/modules/managers_WxAllDatasetsManager.html +1 -0
- package/docs/docs/modules/types.html +1 -0
- package/docs/docs/modules/utils_RawCLUT.html +1 -0
- package/docs/docs/modules/utils_mercator.html +1 -0
- package/docs/docs/modules/utils_qtree.html +1 -0
- package/docs/docs/modules/utils_tests_wxtools.html +1 -0
- package/docs/docs/modules/utils_wxtools.html +1 -0
- package/docs/docs/modules/wxapi.html +1 -0
- package/docs/docs/modules/wxlayer_WxImplementation.html +1 -0
- package/docs/docs/modules/wxlayer_loader.html +1 -0
- package/docs/docs/modules/wxlayer_loadertools.html +1 -0
- package/docs/docs/modules/wxlayer_painter.html +1 -0
- package/docs/docs/modules/wxlayer_wxlayer.html +1 -0
- package/docs/docs/modules.html +1 -0
- package/docs/docs/types/types.ListenerMethod.html +1 -0
- package/docs/docs/types/types.SLine.html +2 -0
- package/docs/docs/types/types.WxDate.html +9 -0
- package/docs/docs/types/types.WxEventType.html +1 -0
- package/docs/docs/types/types.WxInstances.html +2 -0
- package/docs/docs/types/types.WxLayerVarsNames.html +2 -0
- package/docs/docs/types/types.WxURIs.html +2 -0
- package/docs/docs/types/utils_qtree.SubTrees.html +2 -0
- package/docs/docs/types/utils_qtree.SubTreesN.html +2 -0
- package/docs/docs/types/utils_qtree.TreeN.html +2 -0
- package/docs/docs/types/utils_wxtools.DataIntegrals.html +2 -0
- package/docs/docs/types/utils_wxtools.DataPictures.html +2 -0
- package/docs/docs/types/utils_wxtools.WxUnitTuple.html +2 -0
- package/docs/docs/types/utils_wxtools.colorMapTuple.html +2 -0
- package/docs/docs/variables/defaults_colorschemes.__colorSchemes_default_preset.html +1 -0
- package/docs/docs/variables/defaults_styles.__colorStyles_default_preset.html +1 -0
- package/docs/docs/variables/defaults_uconv.__units_default_preset.html +1 -0
- package/managers/BaseDatasetManager.ts +2 -4
- package/managers/WxAllDatasetsManager.ts +1 -1
- package/package.json +5 -3
- package/tsconfig.json +31 -0
- package/typedoc.json +4 -0
- package/types.ts +1 -1
- package/utils/qtree.ts +2 -1
- package/utils/tests_wxtools.ts +10 -10
- package/utils/wxtools.ts +1 -0
- package/wxapi.ts +3 -4
- package/wxlayer/WxImplementation.ts +8 -6
- package/wxlayer/loadertools.ts +14 -10
- package/wxlayer/painter.ts +4 -4
|
@@ -0,0 +1,2 @@
|
|
|
1
|
+
<!DOCTYPE html><html class="default" lang="en" data-base=".."><head><meta charset="utf-8"/><meta http-equiv="x-ua-compatible" content="IE=edge"/><title>WxUnitTuple | @metoceanapi/wxtiles-common</title><meta name="description" content="Documentation for @metoceanapi/wxtiles-common"/><meta name="viewport" content="width=device-width, initial-scale=1"/><link rel="stylesheet" href="../assets/style.css"/><link rel="stylesheet" href="../assets/highlight.css"/><script defer src="../assets/main.js"></script><script async src="../assets/icons.js" id="tsd-icons-script"></script><script async src="../assets/search.js" id="tsd-search-script"></script><script async src="../assets/navigation.js" id="tsd-nav-script"></script><script async src="../assets/hierarchy.js" id="tsd-hierarchy-script"></script></head><body><script>document.documentElement.dataset.theme = localStorage.getItem("tsd-theme") || "os";document.body.style.display="none";setTimeout(() => app?app.showPage():document.body.style.removeProperty("display"),500)</script><header class="tsd-page-toolbar"><div class="tsd-toolbar-contents container"><div class="table-cell" id="tsd-search"><div class="field"><label for="tsd-search-field" class="tsd-widget tsd-toolbar-icon search no-caption"><svg width="16" height="16" viewBox="0 0 16 16" fill="none"><use href="../assets/icons.svg#icon-search"></use></svg></label><input type="text" id="tsd-search-field" aria-label="Search"/></div><div class="field"><div id="tsd-toolbar-links"></div></div><ul class="results"><li class="state loading">Preparing search index...</li><li class="state failure">The search index is not available</li></ul><a href="../index.html" class="title">@metoceanapi/wxtiles-common</a></div><div class="table-cell" id="tsd-widgets"><a href="#" class="tsd-widget tsd-toolbar-icon menu no-caption" data-toggle="menu" aria-label="Menu"><svg width="16" height="16" viewBox="0 0 16 16" fill="none"><use href="../assets/icons.svg#icon-menu"></use></svg></a></div></div></header><div class="container container-main"><div class="col-content"><div class="tsd-page-title"><ul class="tsd-breadcrumb"><li><a href="../modules.html">@metoceanapi/wxtiles-common</a></li><li><a href="../modules/utils_wxtools.html">utils/wxtools</a></li><li><a href="utils_wxtools.WxUnitTuple.html">WxUnitTuple</a></li></ul><h1>Type Alias WxUnitTuple</h1></div><div class="tsd-signature"><span class="tsd-kind-type-alias">WxUnitTuple</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-symbol">[</span><span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">,</span> <span class="tsd-signature-type">number</span><span class="tsd-signature-symbol">,</span> <span class="tsd-signature-type">number</span><span class="tsd-signature-symbol">?</span><span class="tsd-signature-symbol">]</span></div><div class="tsd-comment tsd-typography"><p>type for unit converter</p>
|
|
2
|
+
</div><div class="tsd-comment tsd-typography"></div><aside class="tsd-sources"><ul><li>Defined in <a href="https://github.com/metoceanapi/wxtiles-common/blob/b815568b9334ab8c2405ae085c09aad12678ca1b/utils/wxtools.ts#L13">utils/wxtools.ts:13</a></li></ul></aside></div><div class="col-sidebar"><div class="page-menu"><div class="tsd-navigation settings"><details class="tsd-accordion"><summary class="tsd-accordion-summary"><h3><svg width="20" height="20" viewBox="0 0 24 24" fill="none"><use href="../assets/icons.svg#icon-chevronDown"></use></svg>Settings</h3></summary><div class="tsd-accordion-details"><div class="tsd-filter-visibility"><span class="settings-label">Member Visibility</span><ul id="tsd-filter-options"><li class="tsd-filter-item"><label class="tsd-filter-input"><input type="checkbox" id="tsd-filter-protected" name="protected"/><svg width="32" height="32" viewBox="0 0 32 32" aria-hidden="true"><rect class="tsd-checkbox-background" width="30" height="30" x="1" y="1" rx="6" fill="none"></rect><path class="tsd-checkbox-checkmark" d="M8.35422 16.8214L13.2143 21.75L24.6458 10.25" stroke="none" stroke-width="3.5" stroke-linejoin="round" fill="none"></path></svg><span>Protected</span></label></li><li class="tsd-filter-item"><label class="tsd-filter-input"><input type="checkbox" id="tsd-filter-inherited" name="inherited" checked/><svg width="32" height="32" viewBox="0 0 32 32" aria-hidden="true"><rect class="tsd-checkbox-background" width="30" height="30" x="1" y="1" rx="6" fill="none"></rect><path class="tsd-checkbox-checkmark" d="M8.35422 16.8214L13.2143 21.75L24.6458 10.25" stroke="none" stroke-width="3.5" stroke-linejoin="round" fill="none"></path></svg><span>Inherited</span></label></li><li class="tsd-filter-item"><label class="tsd-filter-input"><input type="checkbox" id="tsd-filter-external" name="external"/><svg width="32" height="32" viewBox="0 0 32 32" aria-hidden="true"><rect class="tsd-checkbox-background" width="30" height="30" x="1" y="1" rx="6" fill="none"></rect><path class="tsd-checkbox-checkmark" d="M8.35422 16.8214L13.2143 21.75L24.6458 10.25" stroke="none" stroke-width="3.5" stroke-linejoin="round" fill="none"></path></svg><span>External</span></label></li></ul></div><div class="tsd-theme-toggle"><label class="settings-label" for="tsd-theme">Theme</label><select id="tsd-theme"><option value="os">OS</option><option value="light">Light</option><option value="dark">Dark</option></select></div></div></details></div></div><div class="site-menu"><nav class="tsd-navigation"><a href="../modules.html">@metoceanapi/wxtiles-common</a><ul class="tsd-small-nested-navigation" id="tsd-nav-container"><li>Loading...</li></ul></nav></div></div></div><footer><p class="tsd-generator">Generated using <a href="https://typedoc.org/" target="_blank">TypeDoc</a></p></footer><div class="overlay"></div></body></html>
|
|
@@ -0,0 +1,2 @@
|
|
|
1
|
+
<!DOCTYPE html><html class="default" lang="en" data-base=".."><head><meta charset="utf-8"/><meta http-equiv="x-ua-compatible" content="IE=edge"/><title>colorMapTuple | @metoceanapi/wxtiles-common</title><meta name="description" content="Documentation for @metoceanapi/wxtiles-common"/><meta name="viewport" content="width=device-width, initial-scale=1"/><link rel="stylesheet" href="../assets/style.css"/><link rel="stylesheet" href="../assets/highlight.css"/><script defer src="../assets/main.js"></script><script async src="../assets/icons.js" id="tsd-icons-script"></script><script async src="../assets/search.js" id="tsd-search-script"></script><script async src="../assets/navigation.js" id="tsd-nav-script"></script><script async src="../assets/hierarchy.js" id="tsd-hierarchy-script"></script></head><body><script>document.documentElement.dataset.theme = localStorage.getItem("tsd-theme") || "os";document.body.style.display="none";setTimeout(() => app?app.showPage():document.body.style.removeProperty("display"),500)</script><header class="tsd-page-toolbar"><div class="tsd-toolbar-contents container"><div class="table-cell" id="tsd-search"><div class="field"><label for="tsd-search-field" class="tsd-widget tsd-toolbar-icon search no-caption"><svg width="16" height="16" viewBox="0 0 16 16" fill="none"><use href="../assets/icons.svg#icon-search"></use></svg></label><input type="text" id="tsd-search-field" aria-label="Search"/></div><div class="field"><div id="tsd-toolbar-links"></div></div><ul class="results"><li class="state loading">Preparing search index...</li><li class="state failure">The search index is not available</li></ul><a href="../index.html" class="title">@metoceanapi/wxtiles-common</a></div><div class="table-cell" id="tsd-widgets"><a href="#" class="tsd-widget tsd-toolbar-icon menu no-caption" data-toggle="menu" aria-label="Menu"><svg width="16" height="16" viewBox="0 0 16 16" fill="none"><use href="../assets/icons.svg#icon-menu"></use></svg></a></div></div></header><div class="container container-main"><div class="col-content"><div class="tsd-page-title"><ul class="tsd-breadcrumb"><li><a href="../modules.html">@metoceanapi/wxtiles-common</a></li><li><a href="../modules/utils_wxtools.html">utils/wxtools</a></li><li><a href="utils_wxtools.colorMapTuple.html">colorMapTuple</a></li></ul><h1>Type Alias colorMapTuple</h1></div><div class="tsd-signature"><span class="tsd-kind-type-alias">colorMapTuple</span><span class="tsd-signature-symbol">:</span> <span class="tsd-signature-symbol">[</span><span class="tsd-signature-type">number</span><span class="tsd-signature-symbol">,</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">]</span></div><div class="tsd-comment tsd-typography"><p>A [level,color] tuple</p>
|
|
2
|
+
</div><div class="tsd-comment tsd-typography"></div><aside class="tsd-sources"><ul><li>Defined in <a href="https://github.com/metoceanapi/wxtiles-common/blob/b815568b9334ab8c2405ae085c09aad12678ca1b/utils/wxtools.ts#L28">utils/wxtools.ts:28</a></li></ul></aside></div><div class="col-sidebar"><div class="page-menu"><div class="tsd-navigation settings"><details class="tsd-accordion"><summary class="tsd-accordion-summary"><h3><svg width="20" height="20" viewBox="0 0 24 24" fill="none"><use href="../assets/icons.svg#icon-chevronDown"></use></svg>Settings</h3></summary><div class="tsd-accordion-details"><div class="tsd-filter-visibility"><span class="settings-label">Member Visibility</span><ul id="tsd-filter-options"><li class="tsd-filter-item"><label class="tsd-filter-input"><input type="checkbox" id="tsd-filter-protected" name="protected"/><svg width="32" height="32" viewBox="0 0 32 32" aria-hidden="true"><rect class="tsd-checkbox-background" width="30" height="30" x="1" y="1" rx="6" fill="none"></rect><path class="tsd-checkbox-checkmark" d="M8.35422 16.8214L13.2143 21.75L24.6458 10.25" stroke="none" stroke-width="3.5" stroke-linejoin="round" fill="none"></path></svg><span>Protected</span></label></li><li class="tsd-filter-item"><label class="tsd-filter-input"><input type="checkbox" id="tsd-filter-inherited" name="inherited" checked/><svg width="32" height="32" viewBox="0 0 32 32" aria-hidden="true"><rect class="tsd-checkbox-background" width="30" height="30" x="1" y="1" rx="6" fill="none"></rect><path class="tsd-checkbox-checkmark" d="M8.35422 16.8214L13.2143 21.75L24.6458 10.25" stroke="none" stroke-width="3.5" stroke-linejoin="round" fill="none"></path></svg><span>Inherited</span></label></li><li class="tsd-filter-item"><label class="tsd-filter-input"><input type="checkbox" id="tsd-filter-external" name="external"/><svg width="32" height="32" viewBox="0 0 32 32" aria-hidden="true"><rect class="tsd-checkbox-background" width="30" height="30" x="1" y="1" rx="6" fill="none"></rect><path class="tsd-checkbox-checkmark" d="M8.35422 16.8214L13.2143 21.75L24.6458 10.25" stroke="none" stroke-width="3.5" stroke-linejoin="round" fill="none"></path></svg><span>External</span></label></li></ul></div><div class="tsd-theme-toggle"><label class="settings-label" for="tsd-theme">Theme</label><select id="tsd-theme"><option value="os">OS</option><option value="light">Light</option><option value="dark">Dark</option></select></div></div></details></div></div><div class="site-menu"><nav class="tsd-navigation"><a href="../modules.html">@metoceanapi/wxtiles-common</a><ul class="tsd-small-nested-navigation" id="tsd-nav-container"><li>Loading...</li></ul></nav></div></div></div><footer><p class="tsd-generator">Generated using <a href="https://typedoc.org/" target="_blank">TypeDoc</a></p></footer><div class="overlay"></div></body></html>
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
<!DOCTYPE html><html class="default" lang="en" data-base=".."><head><meta charset="utf-8"/><meta http-equiv="x-ua-compatible" content="IE=edge"/><title>__colorSchemes_default_preset | @metoceanapi/wxtiles-common</title><meta name="description" content="Documentation for @metoceanapi/wxtiles-common"/><meta name="viewport" content="width=device-width, initial-scale=1"/><link rel="stylesheet" href="../assets/style.css"/><link rel="stylesheet" href="../assets/highlight.css"/><script defer src="../assets/main.js"></script><script async src="../assets/icons.js" id="tsd-icons-script"></script><script async src="../assets/search.js" id="tsd-search-script"></script><script async src="../assets/navigation.js" id="tsd-nav-script"></script><script async src="../assets/hierarchy.js" id="tsd-hierarchy-script"></script></head><body><script>document.documentElement.dataset.theme = localStorage.getItem("tsd-theme") || "os";document.body.style.display="none";setTimeout(() => app?app.showPage():document.body.style.removeProperty("display"),500)</script><header class="tsd-page-toolbar"><div class="tsd-toolbar-contents container"><div class="table-cell" id="tsd-search"><div class="field"><label for="tsd-search-field" class="tsd-widget tsd-toolbar-icon search no-caption"><svg width="16" height="16" viewBox="0 0 16 16" fill="none"><use href="../assets/icons.svg#icon-search"></use></svg></label><input type="text" id="tsd-search-field" aria-label="Search"/></div><div class="field"><div id="tsd-toolbar-links"></div></div><ul class="results"><li class="state loading">Preparing search index...</li><li class="state failure">The search index is not available</li></ul><a href="../index.html" class="title">@metoceanapi/wxtiles-common</a></div><div class="table-cell" id="tsd-widgets"><a href="#" class="tsd-widget tsd-toolbar-icon menu no-caption" data-toggle="menu" aria-label="Menu"><svg width="16" height="16" viewBox="0 0 16 16" fill="none"><use href="../assets/icons.svg#icon-menu"></use></svg></a></div></div></header><div class="container container-main"><div class="col-content"><div class="tsd-page-title"><ul class="tsd-breadcrumb"><li><a href="../modules.html">@metoceanapi/wxtiles-common</a></li><li><a href="../modules/defaults_colorschemes.html">defaults/colorschemes</a></li><li><a href="defaults_colorschemes.__colorSchemes_default_preset.html">__colorSchemes_default_preset</a></li></ul><h1>Variable __colorSchemes_default_preset<code class="tsd-tag">Const</code></h1></div><div class="tsd-signature"><span class="tsd-kind-variable">__colorSchemes_default_preset</span><span class="tsd-signature-symbol">:</span> <a href="../interfaces/utils_wxtools.WxColorSchemes.html" class="tsd-signature-type tsd-kind-interface">WxColorSchemes</a><span class="tsd-signature-symbol"> = ...</span></div><aside class="tsd-sources"><ul><li>Defined in <a href="https://github.com/metoceanapi/wxtiles-common/blob/b815568b9334ab8c2405ae085c09aad12678ca1b/defaults/colorschemes.ts#L2">defaults/colorschemes.ts:2</a></li></ul></aside></div><div class="col-sidebar"><div class="page-menu"><div class="tsd-navigation settings"><details class="tsd-accordion"><summary class="tsd-accordion-summary"><h3><svg width="20" height="20" viewBox="0 0 24 24" fill="none"><use href="../assets/icons.svg#icon-chevronDown"></use></svg>Settings</h3></summary><div class="tsd-accordion-details"><div class="tsd-filter-visibility"><span class="settings-label">Member Visibility</span><ul id="tsd-filter-options"><li class="tsd-filter-item"><label class="tsd-filter-input"><input type="checkbox" id="tsd-filter-protected" name="protected"/><svg width="32" height="32" viewBox="0 0 32 32" aria-hidden="true"><rect class="tsd-checkbox-background" width="30" height="30" x="1" y="1" rx="6" fill="none"></rect><path class="tsd-checkbox-checkmark" d="M8.35422 16.8214L13.2143 21.75L24.6458 10.25" stroke="none" stroke-width="3.5" stroke-linejoin="round" fill="none"></path></svg><span>Protected</span></label></li><li class="tsd-filter-item"><label class="tsd-filter-input"><input type="checkbox" id="tsd-filter-inherited" name="inherited" checked/><svg width="32" height="32" viewBox="0 0 32 32" aria-hidden="true"><rect class="tsd-checkbox-background" width="30" height="30" x="1" y="1" rx="6" fill="none"></rect><path class="tsd-checkbox-checkmark" d="M8.35422 16.8214L13.2143 21.75L24.6458 10.25" stroke="none" stroke-width="3.5" stroke-linejoin="round" fill="none"></path></svg><span>Inherited</span></label></li><li class="tsd-filter-item"><label class="tsd-filter-input"><input type="checkbox" id="tsd-filter-external" name="external"/><svg width="32" height="32" viewBox="0 0 32 32" aria-hidden="true"><rect class="tsd-checkbox-background" width="30" height="30" x="1" y="1" rx="6" fill="none"></rect><path class="tsd-checkbox-checkmark" d="M8.35422 16.8214L13.2143 21.75L24.6458 10.25" stroke="none" stroke-width="3.5" stroke-linejoin="round" fill="none"></path></svg><span>External</span></label></li></ul></div><div class="tsd-theme-toggle"><label class="settings-label" for="tsd-theme">Theme</label><select id="tsd-theme"><option value="os">OS</option><option value="light">Light</option><option value="dark">Dark</option></select></div></div></details></div></div><div class="site-menu"><nav class="tsd-navigation"><a href="../modules.html">@metoceanapi/wxtiles-common</a><ul class="tsd-small-nested-navigation" id="tsd-nav-container"><li>Loading...</li></ul></nav></div></div></div><footer><p class="tsd-generator">Generated using <a href="https://typedoc.org/" target="_blank">TypeDoc</a></p></footer><div class="overlay"></div></body></html>
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
<!DOCTYPE html><html class="default" lang="en" data-base=".."><head><meta charset="utf-8"/><meta http-equiv="x-ua-compatible" content="IE=edge"/><title>__colorStyles_default_preset | @metoceanapi/wxtiles-common</title><meta name="description" content="Documentation for @metoceanapi/wxtiles-common"/><meta name="viewport" content="width=device-width, initial-scale=1"/><link rel="stylesheet" href="../assets/style.css"/><link rel="stylesheet" href="../assets/highlight.css"/><script defer src="../assets/main.js"></script><script async src="../assets/icons.js" id="tsd-icons-script"></script><script async src="../assets/search.js" id="tsd-search-script"></script><script async src="../assets/navigation.js" id="tsd-nav-script"></script><script async src="../assets/hierarchy.js" id="tsd-hierarchy-script"></script></head><body><script>document.documentElement.dataset.theme = localStorage.getItem("tsd-theme") || "os";document.body.style.display="none";setTimeout(() => app?app.showPage():document.body.style.removeProperty("display"),500)</script><header class="tsd-page-toolbar"><div class="tsd-toolbar-contents container"><div class="table-cell" id="tsd-search"><div class="field"><label for="tsd-search-field" class="tsd-widget tsd-toolbar-icon search no-caption"><svg width="16" height="16" viewBox="0 0 16 16" fill="none"><use href="../assets/icons.svg#icon-search"></use></svg></label><input type="text" id="tsd-search-field" aria-label="Search"/></div><div class="field"><div id="tsd-toolbar-links"></div></div><ul class="results"><li class="state loading">Preparing search index...</li><li class="state failure">The search index is not available</li></ul><a href="../index.html" class="title">@metoceanapi/wxtiles-common</a></div><div class="table-cell" id="tsd-widgets"><a href="#" class="tsd-widget tsd-toolbar-icon menu no-caption" data-toggle="menu" aria-label="Menu"><svg width="16" height="16" viewBox="0 0 16 16" fill="none"><use href="../assets/icons.svg#icon-menu"></use></svg></a></div></div></header><div class="container container-main"><div class="col-content"><div class="tsd-page-title"><ul class="tsd-breadcrumb"><li><a href="../modules.html">@metoceanapi/wxtiles-common</a></li><li><a href="../modules/defaults_styles.html">defaults/styles</a></li><li><a href="defaults_styles.__colorStyles_default_preset.html">__colorStyles_default_preset</a></li></ul><h1>Variable __colorStyles_default_preset<code class="tsd-tag">Const</code></h1></div><div class="tsd-signature"><span class="tsd-kind-variable">__colorStyles_default_preset</span><span class="tsd-signature-symbol">:</span> <a href="../interfaces/utils_wxtools.WxColorStylesStrict.html" class="tsd-signature-type tsd-kind-interface">WxColorStylesStrict</a><span class="tsd-signature-symbol"> = ...</span></div><aside class="tsd-sources"><ul><li>Defined in <a href="https://github.com/metoceanapi/wxtiles-common/blob/b815568b9334ab8c2405ae085c09aad12678ca1b/defaults/styles.ts#L3">defaults/styles.ts:3</a></li></ul></aside></div><div class="col-sidebar"><div class="page-menu"><div class="tsd-navigation settings"><details class="tsd-accordion"><summary class="tsd-accordion-summary"><h3><svg width="20" height="20" viewBox="0 0 24 24" fill="none"><use href="../assets/icons.svg#icon-chevronDown"></use></svg>Settings</h3></summary><div class="tsd-accordion-details"><div class="tsd-filter-visibility"><span class="settings-label">Member Visibility</span><ul id="tsd-filter-options"><li class="tsd-filter-item"><label class="tsd-filter-input"><input type="checkbox" id="tsd-filter-protected" name="protected"/><svg width="32" height="32" viewBox="0 0 32 32" aria-hidden="true"><rect class="tsd-checkbox-background" width="30" height="30" x="1" y="1" rx="6" fill="none"></rect><path class="tsd-checkbox-checkmark" d="M8.35422 16.8214L13.2143 21.75L24.6458 10.25" stroke="none" stroke-width="3.5" stroke-linejoin="round" fill="none"></path></svg><span>Protected</span></label></li><li class="tsd-filter-item"><label class="tsd-filter-input"><input type="checkbox" id="tsd-filter-inherited" name="inherited" checked/><svg width="32" height="32" viewBox="0 0 32 32" aria-hidden="true"><rect class="tsd-checkbox-background" width="30" height="30" x="1" y="1" rx="6" fill="none"></rect><path class="tsd-checkbox-checkmark" d="M8.35422 16.8214L13.2143 21.75L24.6458 10.25" stroke="none" stroke-width="3.5" stroke-linejoin="round" fill="none"></path></svg><span>Inherited</span></label></li><li class="tsd-filter-item"><label class="tsd-filter-input"><input type="checkbox" id="tsd-filter-external" name="external"/><svg width="32" height="32" viewBox="0 0 32 32" aria-hidden="true"><rect class="tsd-checkbox-background" width="30" height="30" x="1" y="1" rx="6" fill="none"></rect><path class="tsd-checkbox-checkmark" d="M8.35422 16.8214L13.2143 21.75L24.6458 10.25" stroke="none" stroke-width="3.5" stroke-linejoin="round" fill="none"></path></svg><span>External</span></label></li></ul></div><div class="tsd-theme-toggle"><label class="settings-label" for="tsd-theme">Theme</label><select id="tsd-theme"><option value="os">OS</option><option value="light">Light</option><option value="dark">Dark</option></select></div></div></details></div></div><div class="site-menu"><nav class="tsd-navigation"><a href="../modules.html">@metoceanapi/wxtiles-common</a><ul class="tsd-small-nested-navigation" id="tsd-nav-container"><li>Loading...</li></ul></nav></div></div></div><footer><p class="tsd-generator">Generated using <a href="https://typedoc.org/" target="_blank">TypeDoc</a></p></footer><div class="overlay"></div></body></html>
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
<!DOCTYPE html><html class="default" lang="en" data-base=".."><head><meta charset="utf-8"/><meta http-equiv="x-ua-compatible" content="IE=edge"/><title>__units_default_preset | @metoceanapi/wxtiles-common</title><meta name="description" content="Documentation for @metoceanapi/wxtiles-common"/><meta name="viewport" content="width=device-width, initial-scale=1"/><link rel="stylesheet" href="../assets/style.css"/><link rel="stylesheet" href="../assets/highlight.css"/><script defer src="../assets/main.js"></script><script async src="../assets/icons.js" id="tsd-icons-script"></script><script async src="../assets/search.js" id="tsd-search-script"></script><script async src="../assets/navigation.js" id="tsd-nav-script"></script><script async src="../assets/hierarchy.js" id="tsd-hierarchy-script"></script></head><body><script>document.documentElement.dataset.theme = localStorage.getItem("tsd-theme") || "os";document.body.style.display="none";setTimeout(() => app?app.showPage():document.body.style.removeProperty("display"),500)</script><header class="tsd-page-toolbar"><div class="tsd-toolbar-contents container"><div class="table-cell" id="tsd-search"><div class="field"><label for="tsd-search-field" class="tsd-widget tsd-toolbar-icon search no-caption"><svg width="16" height="16" viewBox="0 0 16 16" fill="none"><use href="../assets/icons.svg#icon-search"></use></svg></label><input type="text" id="tsd-search-field" aria-label="Search"/></div><div class="field"><div id="tsd-toolbar-links"></div></div><ul class="results"><li class="state loading">Preparing search index...</li><li class="state failure">The search index is not available</li></ul><a href="../index.html" class="title">@metoceanapi/wxtiles-common</a></div><div class="table-cell" id="tsd-widgets"><a href="#" class="tsd-widget tsd-toolbar-icon menu no-caption" data-toggle="menu" aria-label="Menu"><svg width="16" height="16" viewBox="0 0 16 16" fill="none"><use href="../assets/icons.svg#icon-menu"></use></svg></a></div></div></header><div class="container container-main"><div class="col-content"><div class="tsd-page-title"><ul class="tsd-breadcrumb"><li><a href="../modules.html">@metoceanapi/wxtiles-common</a></li><li><a href="../modules/defaults_uconv.html">defaults/uconv</a></li><li><a href="defaults_uconv.__units_default_preset.html">__units_default_preset</a></li></ul><h1>Variable __units_default_preset<code class="tsd-tag">Const</code></h1></div><div class="tsd-signature"><span class="tsd-kind-variable">__units_default_preset</span><span class="tsd-signature-symbol">:</span> <a href="../interfaces/utils_wxtools.WxUnits.html" class="tsd-signature-type tsd-kind-interface">WxUnits</a><span class="tsd-signature-symbol"> = ...</span></div><aside class="tsd-sources"><ul><li>Defined in <a href="https://github.com/metoceanapi/wxtiles-common/blob/b815568b9334ab8c2405ae085c09aad12678ca1b/defaults/uconv.ts#L3">defaults/uconv.ts:3</a></li></ul></aside></div><div class="col-sidebar"><div class="page-menu"><div class="tsd-navigation settings"><details class="tsd-accordion"><summary class="tsd-accordion-summary"><h3><svg width="20" height="20" viewBox="0 0 24 24" fill="none"><use href="../assets/icons.svg#icon-chevronDown"></use></svg>Settings</h3></summary><div class="tsd-accordion-details"><div class="tsd-filter-visibility"><span class="settings-label">Member Visibility</span><ul id="tsd-filter-options"><li class="tsd-filter-item"><label class="tsd-filter-input"><input type="checkbox" id="tsd-filter-protected" name="protected"/><svg width="32" height="32" viewBox="0 0 32 32" aria-hidden="true"><rect class="tsd-checkbox-background" width="30" height="30" x="1" y="1" rx="6" fill="none"></rect><path class="tsd-checkbox-checkmark" d="M8.35422 16.8214L13.2143 21.75L24.6458 10.25" stroke="none" stroke-width="3.5" stroke-linejoin="round" fill="none"></path></svg><span>Protected</span></label></li><li class="tsd-filter-item"><label class="tsd-filter-input"><input type="checkbox" id="tsd-filter-inherited" name="inherited" checked/><svg width="32" height="32" viewBox="0 0 32 32" aria-hidden="true"><rect class="tsd-checkbox-background" width="30" height="30" x="1" y="1" rx="6" fill="none"></rect><path class="tsd-checkbox-checkmark" d="M8.35422 16.8214L13.2143 21.75L24.6458 10.25" stroke="none" stroke-width="3.5" stroke-linejoin="round" fill="none"></path></svg><span>Inherited</span></label></li><li class="tsd-filter-item"><label class="tsd-filter-input"><input type="checkbox" id="tsd-filter-external" name="external"/><svg width="32" height="32" viewBox="0 0 32 32" aria-hidden="true"><rect class="tsd-checkbox-background" width="30" height="30" x="1" y="1" rx="6" fill="none"></rect><path class="tsd-checkbox-checkmark" d="M8.35422 16.8214L13.2143 21.75L24.6458 10.25" stroke="none" stroke-width="3.5" stroke-linejoin="round" fill="none"></path></svg><span>External</span></label></li></ul></div><div class="tsd-theme-toggle"><label class="settings-label" for="tsd-theme">Theme</label><select id="tsd-theme"><option value="os">OS</option><option value="light">Light</option><option value="dark">Dark</option></select></div></div></details></div></div><div class="site-menu"><nav class="tsd-navigation"><a href="../modules.html">@metoceanapi/wxtiles-common</a><ul class="tsd-small-nested-navigation" id="tsd-nav-container"><li>Loading...</li></ul></nav></div></div></div><footer><p class="tsd-generator">Generated using <a href="https://typedoc.org/" target="_blank">TypeDoc</a></p></footer><div class="overlay"></div></body></html>
|
|
@@ -1,12 +1,10 @@
|
|
|
1
|
-
import { WXLOG
|
|
1
|
+
import { WXLOG } from "../utils/wxtools";
|
|
2
2
|
import type {
|
|
3
3
|
WxAllBoundariesMeta,
|
|
4
|
-
WxAllDatasetsShortMetas,
|
|
5
4
|
WxDatasetMeta,
|
|
6
5
|
WxVariableMeta,
|
|
7
6
|
WxDate,
|
|
8
7
|
WxLayerVarsNames,
|
|
9
|
-
WxLayerOptions,
|
|
10
8
|
WxDataSetManagerOptions,
|
|
11
9
|
} from "../types";
|
|
12
10
|
import type { WxAPI } from "../wxapi";
|
|
@@ -254,7 +252,7 @@ export abstract class BaseDatasetManager {
|
|
|
254
252
|
* */
|
|
255
253
|
protected _checkCombineVariableIfVector(variable: string): WxLayerVarsNames {
|
|
256
254
|
WXLOG(
|
|
257
|
-
`WxDataSetManager.
|
|
255
|
+
`WxDataSetManager._checkCombineVariableIfVector: ${this.datasetName}, ${variable}`,
|
|
258
256
|
);
|
|
259
257
|
const variableMeta = this._datasetCurrentMeta.variablesMeta[variable];
|
|
260
258
|
if (!variableMeta)
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@metoceanapi/wxtiles-common",
|
|
3
|
-
"version": "0.0.
|
|
3
|
+
"version": "0.0.11-1",
|
|
4
4
|
"description": "Common resources shared by wxtiles mapbox and leaflet packages.",
|
|
5
5
|
"exports": {
|
|
6
6
|
"./*": "./*.ts",
|
|
@@ -10,14 +10,16 @@
|
|
|
10
10
|
"private": false,
|
|
11
11
|
"scripts": {
|
|
12
12
|
"test": "echo \"Error: no test specified\" && exit 1",
|
|
13
|
-
"prepare": "husky"
|
|
13
|
+
"prepare": "husky",
|
|
14
|
+
"gen-docs": "npx typedoc"
|
|
14
15
|
},
|
|
15
16
|
"author": "MetOcean",
|
|
16
17
|
"license": "ISC",
|
|
17
18
|
"devDependencies": {
|
|
18
19
|
"@biomejs/biome": "1.9.4",
|
|
19
20
|
"git-format-staged": "^3.1.1",
|
|
20
|
-
"husky": "^9.1.7"
|
|
21
|
+
"husky": "^9.1.7",
|
|
22
|
+
"typedoc": "^0.27.6"
|
|
21
23
|
},
|
|
22
24
|
"repository": {
|
|
23
25
|
"type": "git",
|
package/tsconfig.json
ADDED
|
@@ -0,0 +1,31 @@
|
|
|
1
|
+
{
|
|
2
|
+
"compilerOptions": {
|
|
3
|
+
// Output configuration
|
|
4
|
+
"outDir": "dist/es",
|
|
5
|
+
"declaration": true,
|
|
6
|
+
"emitDeclarationOnly": true,
|
|
7
|
+
"sourceMap": true,
|
|
8
|
+
|
|
9
|
+
// Module resolution
|
|
10
|
+
"moduleResolution": "node",
|
|
11
|
+
"allowSyntheticDefaultImports": true,
|
|
12
|
+
"esModuleInterop": true,
|
|
13
|
+
"resolveJsonModule": true,
|
|
14
|
+
|
|
15
|
+
// Target and library
|
|
16
|
+
"target": "ES2020",
|
|
17
|
+
"lib": ["ES2020", "DOM"],
|
|
18
|
+
|
|
19
|
+
// Strict type checking (all enabled by "strict")
|
|
20
|
+
"strict": true,
|
|
21
|
+
|
|
22
|
+
// Additional checks
|
|
23
|
+
"noImplicitOverride": true,
|
|
24
|
+
"noImplicitReturns": true,
|
|
25
|
+
"noUnusedLocals": true,
|
|
26
|
+
"noUnusedParameters": true,
|
|
27
|
+
"noFallthroughCasesInSwitch": true,
|
|
28
|
+
"noUncheckedSideEffectImports": true
|
|
29
|
+
},
|
|
30
|
+
"exclude": ["node_modules", "dist"]
|
|
31
|
+
}
|
package/typedoc.json
ADDED
package/types.ts
CHANGED
|
@@ -326,7 +326,7 @@ export interface WxLngLat {
|
|
|
326
326
|
* Used in {@link WxLayerBaseImplementation} cache of the renderes tiles
|
|
327
327
|
* */
|
|
328
328
|
export class WxRasterDataCache extends Map<string, WxRasterData> {
|
|
329
|
-
clear(): void {
|
|
329
|
+
override clear(): void {
|
|
330
330
|
WXLOG("TilesCache.clear()");
|
|
331
331
|
|
|
332
332
|
for (const v of this.values()) {
|
package/utils/qtree.ts
CHANGED
|
@@ -90,7 +90,8 @@ export class QTree {
|
|
|
90
90
|
const _seamask = await fetchJson<string>(input, requestInit);
|
|
91
91
|
this._qtree = qtreeFromString(_seamask, { pos: 0 });
|
|
92
92
|
} catch (e) {
|
|
93
|
-
|
|
93
|
+
const message = e instanceof Error ? e.message : String(e);
|
|
94
|
+
throw new Error(`Failed to load QTree: ${message}`);
|
|
94
95
|
}
|
|
95
96
|
|
|
96
97
|
this._qtreedepth = getTreeDepth(this._qtree);
|
package/utils/tests_wxtools.ts
CHANGED
|
@@ -49,21 +49,21 @@ function ft_printIm(raw: ArrayLike<number>, n: number, comment: string) {
|
|
|
49
49
|
}
|
|
50
50
|
|
|
51
51
|
function ft_Uint16ArrayRandom() {
|
|
52
|
-
const seed = 1;
|
|
52
|
+
// const seed = 1;
|
|
53
53
|
// const rnd = () => Math.floor(Math.abs(Math.sin(seed++)) * 32000 + 32000);
|
|
54
54
|
const rnd = () => Math.floor(Math.random() * 32000);
|
|
55
55
|
return new Uint16Array(258 * 258).map(rnd);
|
|
56
56
|
}
|
|
57
57
|
|
|
58
58
|
function ft_Uint16ArrayAscent() {
|
|
59
|
-
return new Uint16Array(258 * 258).map((
|
|
59
|
+
return new Uint16Array(258 * 258).map((_v, i) => (i % 258) + ~~(i / 258));
|
|
60
60
|
}
|
|
61
61
|
|
|
62
|
-
function ft_Uint16ArrayDescent() {
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
}
|
|
62
|
+
// function ft_Uint16ArrayDescent() {
|
|
63
|
+
// return new Uint16Array(258 * 258).map(
|
|
64
|
+
// (_v, i) => 514 - ((i % 258) + ~~(i / 258)),
|
|
65
|
+
// );
|
|
66
|
+
// }
|
|
67
67
|
|
|
68
68
|
function ft_Uint32ArrayCompare(a: ArrayLike<number>, b: ArrayLike<number>) {
|
|
69
69
|
if (a.length !== b.length) return false;
|
|
@@ -102,9 +102,9 @@ function ft_buildDataIntegralAscent(): DataIntegral {
|
|
|
102
102
|
return new DataIntegral(ft_Uint16ArrayAscent(), 0, 1, 1);
|
|
103
103
|
}
|
|
104
104
|
|
|
105
|
-
function ft_buildDataIntegralDescend(): DataIntegral {
|
|
106
|
-
|
|
107
|
-
}
|
|
105
|
+
// function ft_buildDataIntegralDescend(): DataIntegral {
|
|
106
|
+
// return new DataIntegral(ft_Uint16ArrayDescent(), 0, 1, 1);
|
|
107
|
+
// }
|
|
108
108
|
|
|
109
109
|
function ft_buildDataIntegralRandom(): DataIntegral {
|
|
110
110
|
return new DataIntegral(ft_Uint16ArrayRandom(), 0, 1, 1);
|
package/utils/wxtools.ts
CHANGED
package/wxapi.ts
CHANGED
|
@@ -1,5 +1,6 @@
|
|
|
1
|
+
// @ts-ignore
|
|
1
2
|
import "@metoceanapi/wxtiles-common/wxtiles.css";
|
|
2
|
-
|
|
3
|
+
import { WxAllDatasetsManager } from "./managers/WxAllDatasetsManager";
|
|
3
4
|
import { QTree } from "./utils/qtree";
|
|
4
5
|
import {
|
|
5
6
|
WXLOG,
|
|
@@ -10,9 +11,7 @@ import {
|
|
|
10
11
|
loadImageData,
|
|
11
12
|
uriXYZ,
|
|
12
13
|
} from "./utils/wxtools";
|
|
13
|
-
import type { WxAPIOptions,
|
|
14
|
-
import { BaseDatasetManager } from "./managers/BaseDatasetManager";
|
|
15
|
-
import { WxAllDatasetsManager } from "./managers/WxAllDatasetsManager";
|
|
14
|
+
import type { WxAPIOptions, WxDataSetManagerOptions, WxDatasetMeta } from "./types";
|
|
16
15
|
|
|
17
16
|
/**
|
|
18
17
|
* WxAPI is an initialisation object for the library. See {@link WxAPIOptions} for options.
|
|
@@ -1,3 +1,5 @@
|
|
|
1
|
+
import type { BaseDatasetManager } from "../managers/BaseDatasetManager";
|
|
2
|
+
import type { WxDatasetMeta, WxDate, WxEventType, WxLayerVarsNames, WxRasterData, WxRasterDataCache, WxRequestInit, WxVariableMeta } from "../types";
|
|
1
3
|
import {
|
|
2
4
|
WXLOG,
|
|
3
5
|
type WxColorStyleStrict,
|
|
@@ -6,11 +8,9 @@ import {
|
|
|
6
8
|
type XYZ,
|
|
7
9
|
} from "../utils/wxtools";
|
|
8
10
|
import type { WxLayer } from "./wxlayer";
|
|
9
|
-
import type { WxRequestInit, WxDatasetMeta, WxVariableMeta, WxDate, WxLayerVarsNames, WxLngLat, WxRasterDataCache, WxTileInfo, WxLayerBaseAPI, WxRasterData, WxLayerOptions, WxEventType } from "../types";
|
|
10
|
-
import { BaseDatasetManager } from "../managers/BaseDatasetManager";
|
|
11
11
|
|
|
12
|
-
|
|
13
|
-
type GenericConstraintConstructor<T
|
|
12
|
+
// biome-ignore lint/suspicious/noExplicitAny: necessary for mixins
|
|
13
|
+
type GenericConstraintConstructor<T> = new (...args: any[]) => T;
|
|
14
14
|
|
|
15
15
|
interface MixableI<WxDatasetManagerT extends BaseDatasetManager> {
|
|
16
16
|
id: string
|
|
@@ -288,8 +288,8 @@ export function WxLayerBaseImplementationMixin<WxDatasetManagerT extends BaseDat
|
|
|
288
288
|
* A dummy function to be replaced by ancestor classes.
|
|
289
289
|
*/
|
|
290
290
|
async _reloadVisible(
|
|
291
|
-
|
|
292
|
-
|
|
291
|
+
_requestInit?: WxRequestInit,
|
|
292
|
+
_redraw?: boolean,
|
|
293
293
|
): Promise<void> {}
|
|
294
294
|
|
|
295
295
|
/**
|
|
@@ -336,12 +336,14 @@ export function WxLayerBaseImplementationMixin<WxDatasetManagerT extends BaseDat
|
|
|
336
336
|
// it's ok if the tile is not found. Just return empty tile, or...
|
|
337
337
|
|
|
338
338
|
// ...or, rethrow 'AbortError' to the framework to handle
|
|
339
|
+
// @ts-ignore
|
|
339
340
|
if (e.name === "AbortError") {
|
|
340
341
|
throw e;
|
|
341
342
|
}
|
|
342
343
|
|
|
343
344
|
// ...or, if the loadTile->loadImage->throw 'reason' is 'instance-not-found', try to update wxdatasetManager, then update the layer
|
|
344
345
|
// if we aren't in the middle of updating wxdatasetManager (others may initiate update as well)
|
|
346
|
+
// @ts-ignore
|
|
345
347
|
if (e.reason === "instance-not-found" && !this._needUpdateDSManager) {
|
|
346
348
|
this._needUpdateDSManager = true;
|
|
347
349
|
WXLOG(
|
package/wxlayer/loadertools.ts
CHANGED
|
@@ -34,10 +34,10 @@ type InterpolatorSquare = (
|
|
|
34
34
|
* This function calculates the interpolated value based on the corners of the square.
|
|
35
35
|
* The interpolation is applied within a 2D grid of values.
|
|
36
36
|
*
|
|
37
|
-
* @param
|
|
38
|
-
* @param
|
|
39
|
-
* @param
|
|
40
|
-
* @param
|
|
37
|
+
* @param a_ - Value at the top-left corner of the square.
|
|
38
|
+
* @param b_ - Value at the top-right corner of the square.
|
|
39
|
+
* @param c_ - Value at the bottom-left corner of the square.
|
|
40
|
+
* @param d_ - Value at the bottom-right corner of the square.
|
|
41
41
|
* @param dxt - Interpolation coefficient in the x-direction.
|
|
42
42
|
* @param dyt - Interpolation coefficient in the y-direction.
|
|
43
43
|
* @param dmin - Minimum data value.
|
|
@@ -45,10 +45,10 @@ type InterpolatorSquare = (
|
|
|
45
45
|
* @returns The interpolated value within the square.
|
|
46
46
|
*/
|
|
47
47
|
function interpolatorSquareDegree(
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
48
|
+
a_: number,
|
|
49
|
+
b_: number,
|
|
50
|
+
c_: number,
|
|
51
|
+
d_: number,
|
|
52
52
|
dxt: number,
|
|
53
53
|
dyt: number,
|
|
54
54
|
dmin: number,
|
|
@@ -58,6 +58,10 @@ function interpolatorSquareDegree(
|
|
|
58
58
|
// | |
|
|
59
59
|
// | |
|
|
60
60
|
// c----d
|
|
61
|
+
let a = a_;
|
|
62
|
+
let b = b_;
|
|
63
|
+
let c = c_;
|
|
64
|
+
let d = d_;
|
|
61
65
|
|
|
62
66
|
// 16 possible variants for a,b,c,d != 0 ( != NaN)
|
|
63
67
|
const sq = (a ? 1 : 0) | (b ? 2 : 0) | (c ? 4 : 0) | (d ? 8 : 0);
|
|
@@ -146,8 +150,8 @@ function interpolatorSquare(
|
|
|
146
150
|
d: number,
|
|
147
151
|
dxt: number,
|
|
148
152
|
dyt: number,
|
|
149
|
-
|
|
150
|
-
|
|
153
|
+
_dmin: number,
|
|
154
|
+
_dmul: number,
|
|
151
155
|
): number {
|
|
152
156
|
// 0 1
|
|
153
157
|
// a --- b default version a --- b flipped version
|
package/wxlayer/painter.ts
CHANGED
|
@@ -221,7 +221,7 @@ function _printIsolineTextWithStroke(
|
|
|
221
221
|
val: string,
|
|
222
222
|
ctx: CanvasRenderingContext2D,
|
|
223
223
|
// biome-ignore lint/suspicious/noExplicitAny: Suppressing for specific use case
|
|
224
|
-
|
|
224
|
+
_z: any,
|
|
225
225
|
): void {
|
|
226
226
|
ctx.strokeText(val, 0, 0);
|
|
227
227
|
} // _printIsolineTextWithStroke
|
|
@@ -403,9 +403,9 @@ function _drawVectorAnimationLinesStep<WxDatasetManagerT extends BaseDatasetMana
|
|
|
403
403
|
wxdata: WxData,
|
|
404
404
|
ctx: CanvasRenderingContext2D,
|
|
405
405
|
{ CLUT, style }: WxLayer<WxDatasetManagerT>,
|
|
406
|
-
|
|
406
|
+
seed_: number,
|
|
407
407
|
): void {
|
|
408
|
-
// '
|
|
408
|
+
// 'seed_' is a time tick given by the browser's scheduller
|
|
409
409
|
const { data, slines } = wxdata;
|
|
410
410
|
// if (!slines.length || !style.streamLineStatic || style.streamLineColor === 'none') return; // done by the caller!!!
|
|
411
411
|
const l = data[0];
|
|
@@ -415,7 +415,7 @@ function _drawVectorAnimationLinesStep<WxDatasetManagerT extends BaseDatasetMana
|
|
|
415
415
|
? refineColor(style.streamLineColor).substring(0, 7)
|
|
416
416
|
: "#000000";
|
|
417
417
|
|
|
418
|
-
seed =
|
|
418
|
+
const seed = seed_ >> 5;
|
|
419
419
|
for (let i = 0; i < slines.length; ++i) {
|
|
420
420
|
const sLine = slines[i];
|
|
421
421
|
const sSize = sLine.length - 1;
|