vue-chrts 2.0.0 → 2.1.0-beta-3

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.
Files changed (165) hide show
  1. package/dist/components/AreaChart/AreaChart.js +141 -112
  2. package/dist/components/AreaChart/types.d.ts +33 -1
  3. package/dist/components/BarChart/BarChart.js +76 -65
  4. package/dist/components/BarChart/types.d.ts +9 -1
  5. package/dist/components/BubbleChart/BubbleChart.js +55 -45
  6. package/dist/components/BubbleChart/types.d.ts +9 -1
  7. package/dist/components/DagreGraph/DagreGraph.js +171 -0
  8. package/dist/components/DagreGraph/DagreGraph.vue.d.ts +33 -0
  9. package/dist/components/DagreGraph/DagreGraph2.js +4 -0
  10. package/dist/components/DagreGraph/types.d.ts +253 -0
  11. package/dist/components/DonutChart/DonutChart.js +69 -59
  12. package/dist/components/DonutChart/types.d.ts +14 -2
  13. package/dist/components/DualChart/DualChart.js +216 -0
  14. package/dist/components/DualChart/DualChart.vue.d.ts +21 -0
  15. package/dist/components/DualChart/DualChart2.js +4 -0
  16. package/dist/components/DualChart/types.d.ts +195 -0
  17. package/dist/components/GanttChart/GanttChart.js +58 -48
  18. package/dist/components/GanttChart/types.d.ts +9 -1
  19. package/dist/components/LineChart/LineChart.js +17 -9
  20. package/dist/components/Maps/DottedMap/DottedMap.js +170 -0
  21. package/dist/components/Maps/DottedMap/DottedMap.vue.d.ts +52 -0
  22. package/dist/components/Maps/DottedMap/DottedMap2.js +4 -0
  23. package/dist/components/Maps/DottedMap/MapLegend.vue.d.ts +6 -0
  24. package/dist/components/Maps/DottedMap/MapZoomControls.js +44 -0
  25. package/dist/components/Maps/DottedMap/MapZoomControls.vue.d.ts +13 -0
  26. package/dist/components/Maps/DottedMap/MapZoomControls2.js +4 -0
  27. package/dist/components/Maps/DottedMap/core.js +122 -0
  28. package/dist/components/Maps/DottedMap/core.vue.d.ts +36 -0
  29. package/dist/components/Maps/DottedMap/core2.js +4 -0
  30. package/dist/components/Maps/DottedMap/mapUtils.d.ts +49 -0
  31. package/dist/components/Maps/DottedMap/mapUtils.js +130 -0
  32. package/dist/components/Maps/DottedMap/pins.d.ts +9 -0
  33. package/dist/components/Maps/DottedMap/pins.js +58 -0
  34. package/dist/components/Maps/DottedMap/regions.d.ts +4 -0
  35. package/dist/components/Maps/DottedMap/regions.js +66 -0
  36. package/dist/components/Maps/DottedMap/types.d.ts +127 -0
  37. package/dist/components/Maps/DottedMap/useMapPanZoom.d.ts +22 -0
  38. package/dist/components/Maps/DottedMap/useMapPanZoom.js +41 -0
  39. package/dist/components/Maps/TopoJSONMap/TopoJSONMap.js +170 -0
  40. package/dist/components/Maps/TopoJSONMap/TopoJSONMap.vue.d.ts +30 -0
  41. package/dist/components/Maps/TopoJSONMap/TopoJSONMap2.js +4 -0
  42. package/dist/components/Maps/TopoJSONMap/data.d.ts +13 -0
  43. package/dist/components/Maps/TopoJSONMap/types.d.ts +40 -0
  44. package/dist/components/Maps/types.d.ts +48 -0
  45. package/dist/components/SankeyChart/SankeyChart.js +133 -0
  46. package/dist/components/SankeyChart/SankeyChart.vue.d.ts +22 -0
  47. package/dist/components/SankeyChart/SankeyChart2.js +4 -0
  48. package/dist/components/SankeyChart/types.d.ts +116 -0
  49. package/dist/components/Tooltip.js +32 -27
  50. package/dist/data/countries.geo.json.js +9 -0
  51. package/dist/index.d.ts +8 -2
  52. package/dist/index.js +25 -12
  53. package/dist/node_modules/.pnpm/@turf_boolean-point-in-polygon@7.3.1/node_modules/@turf/boolean-point-in-polygon/dist/esm/index.js +28 -0
  54. package/dist/node_modules/.pnpm/@turf_invariant@7.3.1/node_modules/@turf/invariant/dist/esm/index.js +20 -0
  55. package/dist/node_modules/.pnpm/mgrs@1.0.0/node_modules/mgrs/mgrs.js +222 -0
  56. package/dist/node_modules/.pnpm/point-in-polygon-hao@1.2.4/node_modules/point-in-polygon-hao/dist/esm/index.js +25 -0
  57. package/dist/node_modules/.pnpm/proj4@2.20.2/node_modules/proj4/lib/Point.js +24 -0
  58. package/dist/node_modules/.pnpm/proj4@2.20.2/node_modules/proj4/lib/Proj.js +46 -0
  59. package/dist/node_modules/.pnpm/proj4@2.20.2/node_modules/proj4/lib/adjust_axis.js +31 -0
  60. package/dist/node_modules/.pnpm/proj4@2.20.2/node_modules/proj4/lib/checkSanity.js +15 -0
  61. package/dist/node_modules/.pnpm/proj4@2.20.2/node_modules/proj4/lib/common/adjust_lat.js +8 -0
  62. package/dist/node_modules/.pnpm/proj4@2.20.2/node_modules/proj4/lib/common/adjust_lon.js +8 -0
  63. package/dist/node_modules/.pnpm/proj4@2.20.2/node_modules/proj4/lib/common/adjust_zone.js +13 -0
  64. package/dist/node_modules/.pnpm/proj4@2.20.2/node_modules/proj4/lib/common/asinhy.js +9 -0
  65. package/dist/node_modules/.pnpm/proj4@2.20.2/node_modules/proj4/lib/common/asinz.js +6 -0
  66. package/dist/node_modules/.pnpm/proj4@2.20.2/node_modules/proj4/lib/common/clens.js +8 -0
  67. package/dist/node_modules/.pnpm/proj4@2.20.2/node_modules/proj4/lib/common/clens_cmplx.js +10 -0
  68. package/dist/node_modules/.pnpm/proj4@2.20.2/node_modules/proj4/lib/common/cosh.js +7 -0
  69. package/dist/node_modules/.pnpm/proj4@2.20.2/node_modules/proj4/lib/common/e0fn.js +6 -0
  70. package/dist/node_modules/.pnpm/proj4@2.20.2/node_modules/proj4/lib/common/e1fn.js +6 -0
  71. package/dist/node_modules/.pnpm/proj4@2.20.2/node_modules/proj4/lib/common/e2fn.js +6 -0
  72. package/dist/node_modules/.pnpm/proj4@2.20.2/node_modules/proj4/lib/common/e3fn.js +6 -0
  73. package/dist/node_modules/.pnpm/proj4@2.20.2/node_modules/proj4/lib/common/gN.js +7 -0
  74. package/dist/node_modules/.pnpm/proj4@2.20.2/node_modules/proj4/lib/common/gatg.js +8 -0
  75. package/dist/node_modules/.pnpm/proj4@2.20.2/node_modules/proj4/lib/common/hypot.js +8 -0
  76. package/dist/node_modules/.pnpm/proj4@2.20.2/node_modules/proj4/lib/common/imlfn.js +11 -0
  77. package/dist/node_modules/.pnpm/proj4@2.20.2/node_modules/proj4/lib/common/iqsfnz.js +13 -0
  78. package/dist/node_modules/.pnpm/proj4@2.20.2/node_modules/proj4/lib/common/log1py.js +7 -0
  79. package/dist/node_modules/.pnpm/proj4@2.20.2/node_modules/proj4/lib/common/mlfn.js +6 -0
  80. package/dist/node_modules/.pnpm/proj4@2.20.2/node_modules/proj4/lib/common/msfnz.js +7 -0
  81. package/dist/node_modules/.pnpm/proj4@2.20.2/node_modules/proj4/lib/common/phi2z.js +10 -0
  82. package/dist/node_modules/.pnpm/proj4@2.20.2/node_modules/proj4/lib/common/pj_enfn.js +10 -0
  83. package/dist/node_modules/.pnpm/proj4@2.20.2/node_modules/proj4/lib/common/pj_inv_mlfn.js +14 -0
  84. package/dist/node_modules/.pnpm/proj4@2.20.2/node_modules/proj4/lib/common/pj_mlfn.js +6 -0
  85. package/dist/node_modules/.pnpm/proj4@2.20.2/node_modules/proj4/lib/common/qsfnz.js +7 -0
  86. package/dist/node_modules/.pnpm/proj4@2.20.2/node_modules/proj4/lib/common/sign.js +6 -0
  87. package/dist/node_modules/.pnpm/proj4@2.20.2/node_modules/proj4/lib/common/sinh.js +7 -0
  88. package/dist/node_modules/.pnpm/proj4@2.20.2/node_modules/proj4/lib/common/srat.js +6 -0
  89. package/dist/node_modules/.pnpm/proj4@2.20.2/node_modules/proj4/lib/common/toPoint.js +10 -0
  90. package/dist/node_modules/.pnpm/proj4@2.20.2/node_modules/proj4/lib/common/tsfnz.js +8 -0
  91. package/dist/node_modules/.pnpm/proj4@2.20.2/node_modules/proj4/lib/common/vincenty.js +33 -0
  92. package/dist/node_modules/.pnpm/proj4@2.20.2/node_modules/proj4/lib/constants/Datum.js +1278 -0
  93. package/dist/node_modules/.pnpm/proj4@2.20.2/node_modules/proj4/lib/constants/Ellipsoid.js +226 -0
  94. package/dist/node_modules/.pnpm/proj4@2.20.2/node_modules/proj4/lib/constants/PrimeMeridian.js +17 -0
  95. package/dist/node_modules/.pnpm/proj4@2.20.2/node_modules/proj4/lib/constants/units.js +25 -0
  96. package/dist/node_modules/.pnpm/proj4@2.20.2/node_modules/proj4/lib/constants/values.js +22 -0
  97. package/dist/node_modules/.pnpm/proj4@2.20.2/node_modules/proj4/lib/core.js +65 -0
  98. package/dist/node_modules/.pnpm/proj4@2.20.2/node_modules/proj4/lib/datum.js +8 -0
  99. package/dist/node_modules/.pnpm/proj4@2.20.2/node_modules/proj4/lib/datumUtils.js +82 -0
  100. package/dist/node_modules/.pnpm/proj4@2.20.2/node_modules/proj4/lib/datum_transform.js +94 -0
  101. package/dist/node_modules/.pnpm/proj4@2.20.2/node_modules/proj4/lib/defs.js +39 -0
  102. package/dist/node_modules/.pnpm/proj4@2.20.2/node_modules/proj4/lib/deriveConstants.js +30 -0
  103. package/dist/node_modules/.pnpm/proj4@2.20.2/node_modules/proj4/lib/extend.js +12 -0
  104. package/dist/node_modules/.pnpm/proj4@2.20.2/node_modules/proj4/lib/global.js +9 -0
  105. package/dist/node_modules/.pnpm/proj4@2.20.2/node_modules/proj4/lib/index.js +25 -0
  106. package/dist/node_modules/.pnpm/proj4@2.20.2/node_modules/proj4/lib/match.js +11 -0
  107. package/dist/node_modules/.pnpm/proj4@2.20.2/node_modules/proj4/lib/nadgrid.js +128 -0
  108. package/dist/node_modules/.pnpm/proj4@2.20.2/node_modules/proj4/lib/parseCode.js +47 -0
  109. package/dist/node_modules/.pnpm/proj4@2.20.2/node_modules/proj4/lib/projString.js +119 -0
  110. package/dist/node_modules/.pnpm/proj4@2.20.2/node_modules/proj4/lib/projections/aea.js +43 -0
  111. package/dist/node_modules/.pnpm/proj4@2.20.2/node_modules/proj4/lib/projections/aeqd.js +36 -0
  112. package/dist/node_modules/.pnpm/proj4@2.20.2/node_modules/proj4/lib/projections/bonne.js +55 -0
  113. package/dist/node_modules/.pnpm/proj4@2.20.2/node_modules/proj4/lib/projections/cass.js +52 -0
  114. package/dist/node_modules/.pnpm/proj4@2.20.2/node_modules/proj4/lib/projections/cea.js +36 -0
  115. package/dist/node_modules/.pnpm/proj4@2.20.2/node_modules/proj4/lib/projections/eqc.js +27 -0
  116. package/dist/node_modules/.pnpm/proj4@2.20.2/node_modules/proj4/lib/projections/eqdc.js +48 -0
  117. package/dist/node_modules/.pnpm/proj4@2.20.2/node_modules/proj4/lib/projections/eqearth.js +30 -0
  118. package/dist/node_modules/.pnpm/proj4@2.20.2/node_modules/proj4/lib/projections/etmerc.js +54 -0
  119. package/dist/node_modules/.pnpm/proj4@2.20.2/node_modules/proj4/lib/projections/gauss.js +27 -0
  120. package/dist/node_modules/.pnpm/proj4@2.20.2/node_modules/proj4/lib/projections/geocent.js +26 -0
  121. package/dist/node_modules/.pnpm/proj4@2.20.2/node_modules/proj4/lib/projections/geos.js +49 -0
  122. package/dist/node_modules/.pnpm/proj4@2.20.2/node_modules/proj4/lib/projections/gnom.js +28 -0
  123. package/dist/node_modules/.pnpm/proj4@2.20.2/node_modules/proj4/lib/projections/krovak.js +31 -0
  124. package/dist/node_modules/.pnpm/proj4@2.20.2/node_modules/proj4/lib/projections/laea.js +134 -0
  125. package/dist/node_modules/.pnpm/proj4@2.20.2/node_modules/proj4/lib/projections/lcc.js +61 -0
  126. package/dist/node_modules/.pnpm/proj4@2.20.2/node_modules/proj4/lib/projections/longlat.js +19 -0
  127. package/dist/node_modules/.pnpm/proj4@2.20.2/node_modules/proj4/lib/projections/merc.js +49 -0
  128. package/dist/node_modules/.pnpm/proj4@2.20.2/node_modules/proj4/lib/projections/mill.js +26 -0
  129. package/dist/node_modules/.pnpm/proj4@2.20.2/node_modules/proj4/lib/projections/moll.js +37 -0
  130. package/dist/node_modules/.pnpm/proj4@2.20.2/node_modules/proj4/lib/projections/nzmg.js +48 -0
  131. package/dist/node_modules/.pnpm/proj4@2.20.2/node_modules/proj4/lib/projections/ob_tran.js +173 -0
  132. package/dist/node_modules/.pnpm/proj4@2.20.2/node_modules/proj4/lib/projections/omerc.js +58 -0
  133. package/dist/node_modules/.pnpm/proj4@2.20.2/node_modules/proj4/lib/projections/ortho.js +28 -0
  134. package/dist/node_modules/.pnpm/proj4@2.20.2/node_modules/proj4/lib/projections/poly.js +68 -0
  135. package/dist/node_modules/.pnpm/proj4@2.20.2/node_modules/proj4/lib/projections/qsc.js +67 -0
  136. package/dist/node_modules/.pnpm/proj4@2.20.2/node_modules/proj4/lib/projections/robin.js +104 -0
  137. package/dist/node_modules/.pnpm/proj4@2.20.2/node_modules/proj4/lib/projections/sinu.js +47 -0
  138. package/dist/node_modules/.pnpm/proj4@2.20.2/node_modules/proj4/lib/projections/somerc.js +34 -0
  139. package/dist/node_modules/.pnpm/proj4@2.20.2/node_modules/proj4/lib/projections/stere.js +46 -0
  140. package/dist/node_modules/.pnpm/proj4@2.20.2/node_modules/proj4/lib/projections/sterea.js +33 -0
  141. package/dist/node_modules/.pnpm/proj4@2.20.2/node_modules/proj4/lib/projections/tmerc.js +60 -0
  142. package/dist/node_modules/.pnpm/proj4@2.20.2/node_modules/proj4/lib/projections/tpers.js +110 -0
  143. package/dist/node_modules/.pnpm/proj4@2.20.2/node_modules/proj4/lib/projections/utm.js +22 -0
  144. package/dist/node_modules/.pnpm/proj4@2.20.2/node_modules/proj4/lib/projections/vandg.js +34 -0
  145. package/dist/node_modules/.pnpm/proj4@2.20.2/node_modules/proj4/lib/projections.js +34 -0
  146. package/dist/node_modules/.pnpm/proj4@2.20.2/node_modules/proj4/lib/transform.js +49 -0
  147. package/dist/node_modules/.pnpm/proj4@2.20.2/node_modules/proj4/projs.js +38 -0
  148. package/dist/node_modules/.pnpm/robust-predicates@3.0.2/node_modules/robust-predicates/esm/orient2d.js +23 -0
  149. package/dist/node_modules/.pnpm/robust-predicates@3.0.2/node_modules/robust-predicates/esm/util.js +30 -0
  150. package/dist/node_modules/.pnpm/wkt-parser@1.5.2/node_modules/wkt-parser/PROJJSONBuilder2015.js +9 -0
  151. package/dist/node_modules/.pnpm/wkt-parser@1.5.2/node_modules/wkt-parser/PROJJSONBuilder2019.js +20 -0
  152. package/dist/node_modules/.pnpm/wkt-parser@1.5.2/node_modules/wkt-parser/PROJJSONBuilderBase.js +171 -0
  153. package/dist/node_modules/.pnpm/wkt-parser@1.5.2/node_modules/wkt-parser/buildPROJJSON.js +11 -0
  154. package/dist/node_modules/.pnpm/wkt-parser@1.5.2/node_modules/wkt-parser/detectWKTVersion.js +7 -0
  155. package/dist/node_modules/.pnpm/wkt-parser@1.5.2/node_modules/wkt-parser/index.js +104 -0
  156. package/dist/node_modules/.pnpm/wkt-parser@1.5.2/node_modules/wkt-parser/parser.js +117 -0
  157. package/dist/node_modules/.pnpm/wkt-parser@1.5.2/node_modules/wkt-parser/process.js +89 -0
  158. package/dist/node_modules/.pnpm/wkt-parser@1.5.2/node_modules/wkt-parser/transformPROJJSON.js +73 -0
  159. package/dist/node_modules/.pnpm/wkt-parser@1.5.2/node_modules/wkt-parser/util.js +12 -0
  160. package/dist/types.d.ts +21 -1
  161. package/dist/utils/geoJsonToGrid.d.ts +14 -0
  162. package/dist/utils/index.d.ts +1 -0
  163. package/dist/utils.d.ts +3 -0
  164. package/dist/utils.js +35 -31
  165. package/package.json +15 -9
@@ -0,0 +1,173 @@
1
+ import u from "../common/adjust_lon.js";
2
+ import { EPSLN as c, D2R as p, HALF_PI as d, R2D as _ } from "../constants/values.js";
3
+ import y from "../Proj.js";
4
+ import { names as E } from "./longlat.js";
5
+ const v = {
6
+ OBLIQUE: {
7
+ forward: T,
8
+ inverse: O
9
+ },
10
+ TRANSVERSE: {
11
+ forward: I,
12
+ inverse: A
13
+ }
14
+ }, M = {
15
+ ROTATE: {
16
+ o_alpha: "oAlpha",
17
+ o_lon_c: "oLongC",
18
+ o_lat_c: "oLatC"
19
+ },
20
+ NEW_POLE: {
21
+ o_lat_p: "oLatP",
22
+ o_lon_p: "oLongP"
23
+ },
24
+ NEW_EQUATOR: {
25
+ o_lon_1: "oLong1",
26
+ o_lat_1: "oLat1",
27
+ o_lon_2: "oLong2",
28
+ o_lat_2: "oLat2"
29
+ }
30
+ };
31
+ function L() {
32
+ if (this.x0 = this.x0 || 0, this.y0 = this.y0 || 0, this.long0 = this.long0 || 0, this.title = this.title || "General Oblique Transformation", this.isIdentity = E.includes(this.o_proj), !this.o_proj)
33
+ throw new Error("Missing parameter: o_proj");
34
+ if (this.o_proj === "ob_tran")
35
+ throw new Error("Invalid value for o_proj: " + this.o_proj);
36
+ const t = this.projStr.replace("+proj=ob_tran", "").replace("+o_proj=", "+proj=").trim(), o = y(t);
37
+ if (!o)
38
+ throw new Error("Invalid parameter: o_proj. Unknown projection " + this.o_proj);
39
+ o.long0 = 0, this.obliqueProjection = o;
40
+ let e;
41
+ const i = Object.keys(M), s = (a) => {
42
+ if (typeof this[a] > "u")
43
+ return;
44
+ const h = parseFloat(this[a]) * p;
45
+ if (isNaN(h))
46
+ throw new Error("Invalid value for " + a + ": " + this[a]);
47
+ return h;
48
+ };
49
+ for (let a = 0; a < i.length; a++) {
50
+ const h = i[a], m = M[h], f = Object.entries(m);
51
+ if (f.some(
52
+ ([l]) => typeof this[l] < "u"
53
+ )) {
54
+ e = m;
55
+ for (let l = 0; l < f.length; l++) {
56
+ const [b, j] = f[l], w = s(b);
57
+ if (typeof w > "u")
58
+ throw new Error("Missing parameter: " + b + ".");
59
+ this[j] = w;
60
+ }
61
+ break;
62
+ }
63
+ }
64
+ if (!e)
65
+ throw new Error("No valid parameters provided for ob_tran projection.");
66
+ const { lamp: n, phip: r } = x(this, e);
67
+ this.lamp = n, Math.abs(r) > c ? (this.cphip = Math.cos(r), this.sphip = Math.sin(r), this.projectionType = v.OBLIQUE) : this.projectionType = v.TRANSVERSE;
68
+ }
69
+ function P(t) {
70
+ return this.projectionType.forward(this, t);
71
+ }
72
+ function g(t) {
73
+ return this.projectionType.inverse(this, t);
74
+ }
75
+ function x(t, o) {
76
+ let e, i;
77
+ if (o === M.ROTATE) {
78
+ let s = t.oLongC, n = t.oLatC, r = t.oAlpha;
79
+ if (Math.abs(Math.abs(n) - d) <= c)
80
+ throw new Error("Invalid value for o_lat_c: " + t.o_lat_c + " should be < 90°");
81
+ i = s + Math.atan2(-1 * Math.cos(r), -1 * Math.sin(r) * Math.sin(n)), e = Math.asin(Math.cos(n) * Math.sin(r));
82
+ } else if (o === M.NEW_POLE)
83
+ i = t.oLongP, e = t.oLatP;
84
+ else {
85
+ let s = t.oLong1, n = t.oLat1, r = t.oLong2, a = t.oLat2, h = Math.abs(n);
86
+ if (Math.abs(n) > d - c)
87
+ throw new Error("Invalid value for o_lat_1: " + t.o_lat_1 + " should be < 90°");
88
+ if (Math.abs(a) > d - c)
89
+ throw new Error("Invalid value for o_lat_2: " + t.o_lat_2 + " should be < 90°");
90
+ if (Math.abs(n - a) < c)
91
+ throw new Error("Invalid value for o_lat_1 and o_lat_2: o_lat_1 should be different from o_lat_2");
92
+ if (h < c)
93
+ throw new Error("Invalid value for o_lat_1: o_lat_1 should be different from zero");
94
+ i = Math.atan2(
95
+ Math.cos(n) * Math.sin(a) * Math.cos(s) - Math.sin(n) * Math.cos(a) * Math.cos(r),
96
+ Math.sin(n) * Math.cos(a) * Math.sin(r) - Math.cos(n) * Math.sin(a) * Math.sin(s)
97
+ ), e = Math.atan(-1 * Math.cos(i - s) / Math.tan(n));
98
+ }
99
+ return { lamp: i, phip: e };
100
+ }
101
+ function T(t, o) {
102
+ let { x: e, y: i } = o;
103
+ e += t.long0;
104
+ const s = Math.cos(e), n = Math.sin(i), r = Math.cos(i);
105
+ o.x = u(
106
+ Math.atan2(
107
+ r * Math.sin(e),
108
+ t.sphip * r * s + t.cphip * n
109
+ ) + t.lamp
110
+ ), o.y = Math.asin(
111
+ t.sphip * n - t.cphip * r * s
112
+ );
113
+ const a = t.obliqueProjection.forward(o);
114
+ return t.isIdentity && (a.x *= _, a.y *= _), a;
115
+ }
116
+ function I(t, o) {
117
+ let { x: e, y: i } = o;
118
+ e += t.long0;
119
+ const s = Math.cos(i), n = Math.cos(e);
120
+ o.x = u(
121
+ Math.atan2(
122
+ s * Math.sin(e),
123
+ Math.sin(i)
124
+ ) + t.lamp
125
+ ), o.y = Math.asin(-1 * s * n);
126
+ const r = t.obliqueProjection.forward(o);
127
+ return t.isIdentity && (r.x *= _, r.y *= _), r;
128
+ }
129
+ function O(t, o) {
130
+ t.isIdentity && (o.x *= p, o.y *= p);
131
+ const e = t.obliqueProjection.inverse(o);
132
+ let { x: i, y: s } = e;
133
+ if (i < Number.MAX_VALUE) {
134
+ i -= t.lamp;
135
+ const n = Math.cos(i), r = Math.sin(s), a = Math.cos(s);
136
+ o.x = Math.atan2(
137
+ a * Math.sin(i),
138
+ t.sphip * a * n - t.cphip * r
139
+ ), o.y = Math.asin(
140
+ t.sphip * r + t.cphip * a * n
141
+ );
142
+ }
143
+ return o.x = u(o.x + t.long0), o;
144
+ }
145
+ function A(t, o) {
146
+ t.isIdentity && (o.x *= p, o.y *= p);
147
+ const e = t.obliqueProjection.inverse(o);
148
+ let { x: i, y: s } = e;
149
+ if (i < Number.MAX_VALUE) {
150
+ const n = Math.cos(s);
151
+ i -= t.lamp, o.x = Math.atan2(
152
+ n * Math.sin(i),
153
+ -1 * Math.sin(s)
154
+ ), o.y = Math.asin(
155
+ n * Math.cos(i)
156
+ );
157
+ }
158
+ return o.x = u(o.x + t.long0), o;
159
+ }
160
+ var N = ["General Oblique Transformation", "General_Oblique_Transformation", "ob_tran"];
161
+ const V = {
162
+ init: L,
163
+ forward: P,
164
+ inverse: g,
165
+ names: N
166
+ };
167
+ export {
168
+ V as default,
169
+ P as forward,
170
+ L as init,
171
+ g as inverse,
172
+ N as names
173
+ };
@@ -0,0 +1,58 @@
1
+ import A from "../common/tsfnz.js";
2
+ import q from "../common/adjust_lon.js";
3
+ import E from "../common/phi2z.js";
4
+ import { EPSLN as x, HALF_PI as u, TWO_PI as w, FORTPI as d } from "../constants/values.js";
5
+ import { getNormalizedProjName as H } from "../projections.js";
6
+ var m = 1e-7;
7
+ function N(t) {
8
+ var s = ["Hotine_Oblique_Mercator", "Hotine_Oblique_Mercator_variant_A", "Hotine_Oblique_Mercator_Azimuth_Natural_Origin"], o = typeof t.projName == "object" ? Object.keys(t.projName)[0] : t.projName;
9
+ return "no_uoff" in t || "no_off" in t || s.indexOf(o) !== -1 || s.indexOf(H(o)) !== -1;
10
+ }
11
+ function j() {
12
+ var t, s, o, a, i, n, e, r, h, M, l = 0, _, p = 0, B = 0, f = 0, b = 0, g = 0, c = 0;
13
+ this.no_off = N(this), this.no_rot = "no_rot" in this;
14
+ var y = !1;
15
+ "alpha" in this && (y = !0);
16
+ var v = !1;
17
+ if ("rectified_grid_angle" in this && (v = !0), y && (c = this.alpha), v && (l = this.rectified_grid_angle), y || v)
18
+ p = this.longc;
19
+ else if (B = this.long1, b = this.lat1, f = this.long2, g = this.lat2, Math.abs(b - g) <= m || (t = Math.abs(b)) <= m || Math.abs(t - u) <= m || Math.abs(Math.abs(this.lat0) - u) <= m || Math.abs(Math.abs(g) - u) <= m)
20
+ throw new Error();
21
+ var O = 1 - this.es;
22
+ s = Math.sqrt(O), Math.abs(this.lat0) > x ? (r = Math.sin(this.lat0), o = Math.cos(this.lat0), t = 1 - this.es * r * r, this.B = o * o, this.B = Math.sqrt(1 + this.es * this.B * this.B / O), this.A = this.B * this.k0 * s / t, a = this.B * s / (o * Math.sqrt(t)), i = a * a - 1, i <= 0 ? i = 0 : (i = Math.sqrt(i), this.lat0 < 0 && (i = -i)), this.E = i += a, this.E *= Math.pow(A(this.e, this.lat0, r), this.B)) : (this.B = 1 / s, this.A = this.k0, this.E = a = i = 1), y || v ? (y ? (_ = Math.asin(Math.sin(c) / a), v || (l = c)) : (_ = l, c = Math.asin(a * Math.sin(_))), this.lam0 = p - Math.asin(0.5 * (i - 1 / i) * Math.tan(_)) / this.B) : (n = Math.pow(A(this.e, b, Math.sin(b)), this.B), e = Math.pow(A(this.e, g, Math.sin(g)), this.B), i = this.E / n, h = (e - n) / (e + n), M = this.E * this.E, M = (M - e * n) / (M + e * n), t = B - f, t < -Math.PI ? f -= w : t > Math.PI && (f += w), this.lam0 = q(0.5 * (B + f) - Math.atan(M * Math.tan(0.5 * this.B * (B - f)) / h) / this.B, this.over), _ = Math.atan(2 * Math.sin(this.B * q(B - this.lam0, this.over)) / (i - 1 / i)), l = c = Math.asin(a * Math.sin(_))), this.singam = Math.sin(_), this.cosgam = Math.cos(_), this.sinrot = Math.sin(l), this.cosrot = Math.cos(l), this.rB = 1 / this.B, this.ArB = this.A * this.rB, this.BrA = 1 / this.ArB, this.no_off ? this.u_0 = 0 : (this.u_0 = Math.abs(this.ArB * Math.atan(Math.sqrt(a * a - 1) / Math.cos(c))), this.lat0 < 0 && (this.u_0 = -this.u_0)), i = 0.5 * _, this.v_pole_n = this.ArB * Math.log(Math.tan(d - i)), this.v_pole_s = this.ArB * Math.log(Math.tan(d + i));
23
+ }
24
+ function T(t) {
25
+ var s = {}, o, a, i, n, e, r, h, M;
26
+ if (t.x = t.x - this.lam0, Math.abs(Math.abs(t.y) - u) > x) {
27
+ if (e = this.E / Math.pow(A(this.e, t.y, Math.sin(t.y)), this.B), r = 1 / e, o = 0.5 * (e - r), a = 0.5 * (e + r), n = Math.sin(this.B * t.x), i = (o * this.singam - n * this.cosgam) / a, Math.abs(Math.abs(i) - 1) < x)
28
+ throw new Error();
29
+ M = 0.5 * this.ArB * Math.log((1 - i) / (1 + i)), r = Math.cos(this.B * t.x), Math.abs(r) < m ? h = this.A * t.x : h = this.ArB * Math.atan2(o * this.cosgam + n * this.singam, r);
30
+ } else
31
+ M = t.y > 0 ? this.v_pole_n : this.v_pole_s, h = this.ArB * t.y;
32
+ return this.no_rot ? (s.x = h, s.y = M) : (h -= this.u_0, s.x = M * this.cosrot + h * this.sinrot, s.y = h * this.cosrot - M * this.sinrot), s.x = this.a * s.x + this.x0, s.y = this.a * s.y + this.y0, s;
33
+ }
34
+ function z(t) {
35
+ var s, o, a, i, n, e, r, h = {};
36
+ if (t.x = (t.x - this.x0) * (1 / this.a), t.y = (t.y - this.y0) * (1 / this.a), this.no_rot ? (o = t.y, s = t.x) : (o = t.x * this.cosrot - t.y * this.sinrot, s = t.y * this.cosrot + t.x * this.sinrot + this.u_0), a = Math.exp(-this.BrA * o), i = 0.5 * (a - 1 / a), n = 0.5 * (a + 1 / a), e = Math.sin(this.BrA * s), r = (e * this.cosgam + i * this.singam) / n, Math.abs(Math.abs(r) - 1) < x)
37
+ h.x = 0, h.y = r < 0 ? -u : u;
38
+ else {
39
+ if (h.y = this.E / Math.sqrt((1 + r) / (1 - r)), h.y = E(this.e, Math.pow(h.y, 1 / this.B)), h.y === 1 / 0)
40
+ throw new Error();
41
+ h.x = -this.rB * Math.atan2(i * this.cosgam - e * this.singam, Math.cos(this.BrA * s));
42
+ }
43
+ return h.x += this.lam0, h;
44
+ }
45
+ var I = ["Hotine_Oblique_Mercator", "Hotine Oblique Mercator", "Hotine_Oblique_Mercator_variant_A", "Hotine_Oblique_Mercator_Variant_B", "Hotine_Oblique_Mercator_Azimuth_Natural_Origin", "Hotine_Oblique_Mercator_Two_Point_Natural_Origin", "Hotine_Oblique_Mercator_Azimuth_Center", "Oblique_Mercator", "omerc"];
46
+ const V = {
47
+ init: j,
48
+ forward: T,
49
+ inverse: z,
50
+ names: I
51
+ };
52
+ export {
53
+ V as default,
54
+ T as forward,
55
+ j as init,
56
+ z as inverse,
57
+ I as names
58
+ };
@@ -0,0 +1,28 @@
1
+ import l from "../common/adjust_lon.js";
2
+ import M from "../common/asinz.js";
3
+ import { EPSLN as v, HALF_PI as x } from "../constants/values.js";
4
+ function f() {
5
+ this.sin_p14 = Math.sin(this.lat0), this.cos_p14 = Math.cos(this.lat0);
6
+ }
7
+ function _(t) {
8
+ var i, a, h, n, r, s, o, e, y = t.x, c = t.y;
9
+ return h = l(y - this.long0, this.over), i = Math.sin(c), a = Math.cos(c), n = Math.cos(h), s = this.sin_p14 * i + this.cos_p14 * a * n, r = 1, (s > 0 || Math.abs(s) <= v) && (o = this.a * r * a * Math.sin(h), e = this.y0 + this.a * r * (this.cos_p14 * i - this.sin_p14 * a * n)), t.x = o, t.y = e, t;
10
+ }
11
+ function u(t) {
12
+ var i, a, h, n, r, s, o;
13
+ return t.x -= this.x0, t.y -= this.y0, i = Math.sqrt(t.x * t.x + t.y * t.y), a = M(i / this.a), h = Math.sin(a), n = Math.cos(a), s = this.long0, Math.abs(i) <= v ? (o = this.lat0, t.x = s, t.y = o, t) : (o = M(n * this.sin_p14 + t.y * h * this.cos_p14 / i), r = Math.abs(this.lat0) - x, Math.abs(r) <= v ? (this.lat0 >= 0 ? s = l(this.long0 + Math.atan2(t.x, -t.y), this.over) : s = l(this.long0 - Math.atan2(-t.x, t.y), this.over), t.x = s, t.y = o, t) : (s = l(this.long0 + Math.atan2(t.x * h, i * this.cos_p14 * n - t.y * this.sin_p14 * h), this.over), t.x = s, t.y = o, t));
14
+ }
15
+ var m = ["ortho"];
16
+ const z = {
17
+ init: f,
18
+ forward: _,
19
+ inverse: u,
20
+ names: m
21
+ };
22
+ export {
23
+ z as default,
24
+ _ as forward,
25
+ f as init,
26
+ u as inverse,
27
+ m as names
28
+ };
@@ -0,0 +1,68 @@
1
+ import c from "../common/e0fn.js";
2
+ import g from "../common/e1fn.js";
3
+ import w from "../common/e2fn.js";
4
+ import _ from "../common/e3fn.js";
5
+ import m from "../common/adjust_lon.js";
6
+ import q from "../common/adjust_lat.js";
7
+ import u from "../common/mlfn.js";
8
+ import { EPSLN as v } from "../constants/values.js";
9
+ import P from "../common/gN.js";
10
+ var p = 20;
11
+ function j() {
12
+ this.temp = this.b / this.a, this.es = 1 - Math.pow(this.temp, 2), this.e = Math.sqrt(this.es), this.e0 = c(this.es), this.e1 = g(this.es), this.e2 = w(this.es), this.e3 = _(this.es), this.ml0 = this.a * u(this.e0, this.e1, this.e2, this.e3, this.lat0);
13
+ }
14
+ function k(e) {
15
+ var M = e.x, s = e.y, h, r, a, i = m(M - this.long0, this.over);
16
+ if (a = i * Math.sin(s), this.sphere)
17
+ Math.abs(s) <= v ? (h = this.a * i, r = -1 * this.a * this.lat0) : (h = this.a * Math.sin(a) / Math.tan(s), r = this.a * (q(s - this.lat0) + (1 - Math.cos(a)) / Math.tan(s)));
18
+ else if (Math.abs(s) <= v)
19
+ h = this.a * i, r = -1 * this.ml0;
20
+ else {
21
+ var n = P(this.a, this.e, Math.sin(s)) / Math.tan(s);
22
+ h = n * Math.sin(a), r = this.a * u(this.e0, this.e1, this.e2, this.e3, s) - this.ml0 + n * (1 - Math.cos(a));
23
+ }
24
+ return e.x = h + this.x0, e.y = r + this.y0, e;
25
+ }
26
+ function A(e) {
27
+ var M, s, h, r, a, i, n, t, l;
28
+ if (h = e.x - this.x0, r = e.y - this.y0, this.sphere)
29
+ if (Math.abs(r + this.a * this.lat0) <= v)
30
+ M = m(h / this.a + this.long0, this.over), s = 0;
31
+ else {
32
+ i = this.lat0 + r / this.a, n = h * h / this.a / this.a + i * i, t = i;
33
+ var y;
34
+ for (a = p; a; --a)
35
+ if (y = Math.tan(t), l = -1 * (i * (t * y + 1) - t - 0.5 * (t * t + n) * y) / ((t - i) / y - 1), t += l, Math.abs(l) <= v) {
36
+ s = t;
37
+ break;
38
+ }
39
+ M = m(this.long0 + Math.asin(h * Math.tan(t) / this.a) / Math.sin(s), this.over);
40
+ }
41
+ else if (Math.abs(r + this.ml0) <= v)
42
+ s = 0, M = m(this.long0 + h / this.a, this.over);
43
+ else {
44
+ i = (this.ml0 + r) / this.a, n = h * h / this.a / this.a + i * i, t = i;
45
+ var f, d, b, o, x;
46
+ for (a = p; a; --a)
47
+ if (x = this.e * Math.sin(t), f = Math.sqrt(1 - x * x) * Math.tan(t), d = this.a * u(this.e0, this.e1, this.e2, this.e3, t), b = this.e0 - 2 * this.e1 * Math.cos(2 * t) + 4 * this.e2 * Math.cos(4 * t) - 6 * this.e3 * Math.cos(6 * t), o = d / this.a, l = (i * (f * o + 1) - o - 0.5 * f * (o * o + n)) / (this.es * Math.sin(2 * t) * (o * o + n - 2 * i * o) / (4 * f) + (i - o) * (f * b - 2 / Math.sin(2 * t)) - b), t -= l, Math.abs(l) <= v) {
48
+ s = t;
49
+ break;
50
+ }
51
+ f = Math.sqrt(1 - this.es * Math.pow(Math.sin(s), 2)) * Math.tan(s), M = m(this.long0 + Math.asin(h * f / this.a) / Math.sin(s), this.over);
52
+ }
53
+ return e.x = M, e.y = s, e;
54
+ }
55
+ var E = ["Polyconic", "American_Polyconic", "poly"];
56
+ const C = {
57
+ init: j,
58
+ forward: k,
59
+ inverse: A,
60
+ names: E
61
+ };
62
+ export {
63
+ C as default,
64
+ k as forward,
65
+ j as init,
66
+ A as inverse,
67
+ E as names
68
+ };
@@ -0,0 +1,67 @@
1
+ import { HALF_PI as i, FORTPI as n, EPSLN as b, SPI as M, TWO_PI as F } from "../constants/values.js";
2
+ var u = {
3
+ FRONT: 1,
4
+ RIGHT: 2,
5
+ BACK: 3,
6
+ LEFT: 4,
7
+ TOP: 5,
8
+ BOTTOM: 6
9
+ }, h = {
10
+ AREA_0: 1,
11
+ AREA_1: 2,
12
+ AREA_2: 3,
13
+ AREA_3: 4
14
+ };
15
+ function B() {
16
+ this.x0 = this.x0 || 0, this.y0 = this.y0 || 0, this.lat0 = this.lat0 || 0, this.long0 = this.long0 || 0, this.lat_ts = this.lat_ts || 0, this.title = this.title || "Quadrilateralized Spherical Cube", this.lat0 >= i - n / 2 ? this.face = u.TOP : this.lat0 <= -(i - n / 2) ? this.face = u.BOTTOM : Math.abs(this.long0) <= n ? this.face = u.FRONT : Math.abs(this.long0) <= i + n ? this.face = this.long0 > 0 ? u.RIGHT : u.LEFT : this.face = u.BACK, this.es !== 0 && (this.one_minus_f = 1 - (this.a - this.b) / this.a, this.one_minus_f_squared = this.one_minus_f * this.one_minus_f);
17
+ }
18
+ function C(s) {
19
+ var e = { x: 0, y: 0 }, f, a, t, o, m, A, l = { value: 0 };
20
+ if (s.x -= this.long0, this.es !== 0 ? f = Math.atan(this.one_minus_f_squared * Math.tan(s.y)) : f = s.y, a = s.x, this.face === u.TOP)
21
+ o = i - f, a >= n && a <= i + n ? (l.value = h.AREA_0, t = a - i) : a > i + n || a <= -(i + n) ? (l.value = h.AREA_1, t = a > 0 ? a - M : a + M) : a > -(i + n) && a <= -n ? (l.value = h.AREA_2, t = a + i) : (l.value = h.AREA_3, t = a);
22
+ else if (this.face === u.BOTTOM)
23
+ o = i + f, a >= n && a <= i + n ? (l.value = h.AREA_0, t = -a + i) : a < n && a >= -n ? (l.value = h.AREA_1, t = -a) : a < -n && a >= -(i + n) ? (l.value = h.AREA_2, t = -a - i) : (l.value = h.AREA_3, t = a > 0 ? -a + M : -a - M);
24
+ else {
25
+ var r, _, c, R, v, E, y;
26
+ this.face === u.RIGHT ? a = T(a, +i) : this.face === u.BACK ? a = T(a, +M) : this.face === u.LEFT && (a = T(a, -i)), R = Math.sin(f), v = Math.cos(f), E = Math.sin(a), y = Math.cos(a), r = v * y, _ = v * E, c = R, this.face === u.FRONT ? (o = Math.acos(r), t = O(o, c, _, l)) : this.face === u.RIGHT ? (o = Math.acos(_), t = O(o, c, -r, l)) : this.face === u.BACK ? (o = Math.acos(-r), t = O(o, c, -_, l)) : this.face === u.LEFT ? (o = Math.acos(-_), t = O(o, c, r, l)) : (o = t = 0, l.value = h.AREA_0);
27
+ }
28
+ return A = Math.atan(12 / M * (t + Math.acos(Math.sin(t) * Math.cos(n)) - i)), m = Math.sqrt((1 - Math.cos(o)) / (Math.cos(A) * Math.cos(A)) / (1 - Math.cos(Math.atan(1 / Math.cos(t))))), l.value === h.AREA_1 ? A += i : l.value === h.AREA_2 ? A += M : l.value === h.AREA_3 && (A += 1.5 * M), e.x = m * Math.cos(A), e.y = m * Math.sin(A), e.x = e.x * this.a + this.x0, e.y = e.y * this.a + this.y0, s.x = e.x, s.y = e.y, s;
29
+ }
30
+ function I(s) {
31
+ var e = { lam: 0, phi: 0 }, f, a, t, o, m, A, l, r, _, c = { value: 0 };
32
+ if (s.x = (s.x - this.x0) / this.a, s.y = (s.y - this.y0) / this.a, a = Math.atan(Math.sqrt(s.x * s.x + s.y * s.y)), f = Math.atan2(s.y, s.x), s.x >= 0 && s.x >= Math.abs(s.y) ? c.value = h.AREA_0 : s.y >= 0 && s.y >= Math.abs(s.x) ? (c.value = h.AREA_1, f -= i) : s.x < 0 && -s.x >= Math.abs(s.y) ? (c.value = h.AREA_2, f = f < 0 ? f + M : f - M) : (c.value = h.AREA_3, f += i), _ = M / 12 * Math.tan(f), m = Math.sin(_) / (Math.cos(_) - 1 / Math.sqrt(2)), A = Math.atan(m), t = Math.cos(f), o = Math.tan(a), l = 1 - t * t * o * o * (1 - Math.cos(Math.atan(1 / Math.cos(A)))), l < -1 ? l = -1 : l > 1 && (l = 1), this.face === u.TOP)
33
+ r = Math.acos(l), e.phi = i - r, c.value === h.AREA_0 ? e.lam = A + i : c.value === h.AREA_1 ? e.lam = A < 0 ? A + M : A - M : c.value === h.AREA_2 ? e.lam = A - i : e.lam = A;
34
+ else if (this.face === u.BOTTOM)
35
+ r = Math.acos(l), e.phi = r - i, c.value === h.AREA_0 ? e.lam = -A + i : c.value === h.AREA_1 ? e.lam = -A : c.value === h.AREA_2 ? e.lam = -A - i : e.lam = A < 0 ? -A - M : -A + M;
36
+ else {
37
+ var R, v, E;
38
+ R = l, _ = R * R, _ >= 1 ? E = 0 : E = Math.sqrt(1 - _) * Math.sin(A), _ += E * E, _ >= 1 ? v = 0 : v = Math.sqrt(1 - _), c.value === h.AREA_1 ? (_ = v, v = -E, E = _) : c.value === h.AREA_2 ? (v = -v, E = -E) : c.value === h.AREA_3 && (_ = v, v = E, E = -_), this.face === u.RIGHT ? (_ = R, R = -v, v = _) : this.face === u.BACK ? (R = -R, v = -v) : this.face === u.LEFT && (_ = R, R = v, v = -_), e.phi = Math.acos(-E) - i, e.lam = Math.atan2(v, R), this.face === u.RIGHT ? e.lam = T(e.lam, -i) : this.face === u.BACK ? e.lam = T(e.lam, -M) : this.face === u.LEFT && (e.lam = T(e.lam, +i));
39
+ }
40
+ if (this.es !== 0) {
41
+ var y, d, x;
42
+ y = e.phi < 0 ? 1 : 0, d = Math.tan(e.phi), x = this.b / Math.sqrt(d * d + this.one_minus_f_squared), e.phi = Math.atan(Math.sqrt(this.a * this.a - x * x) / (this.one_minus_f * x)), y && (e.phi = -e.phi);
43
+ }
44
+ return e.lam += this.long0, s.x = e.lam, s.y = e.phi, s;
45
+ }
46
+ function O(s, e, f, a) {
47
+ var t;
48
+ return s < b ? (a.value = h.AREA_0, t = 0) : (t = Math.atan2(e, f), Math.abs(t) <= n ? a.value = h.AREA_0 : t > n && t <= i + n ? (a.value = h.AREA_1, t -= i) : t > i + n || t <= -(i + n) ? (a.value = h.AREA_2, t = t >= 0 ? t - M : t + M) : (a.value = h.AREA_3, t += i)), t;
49
+ }
50
+ function T(s, e) {
51
+ var f = s + e;
52
+ return f < -M ? f += F : f > +M && (f -= F), f;
53
+ }
54
+ var P = ["Quadrilateralized Spherical Cube", "Quadrilateralized_Spherical_Cube", "qsc"];
55
+ const g = {
56
+ init: B,
57
+ forward: C,
58
+ inverse: I,
59
+ names: P
60
+ };
61
+ export {
62
+ g as default,
63
+ C as forward,
64
+ B as init,
65
+ I as inverse,
66
+ P as names
67
+ };
@@ -0,0 +1,104 @@
1
+ import { HALF_PI as y, D2R as _, R2D as f, EPSLN as m } from "../constants/values.js";
2
+ import l from "../common/adjust_lon.js";
3
+ var v = [
4
+ [1, 22199e-21, -715515e-10, 31103e-10],
5
+ [0.9986, -482243e-9, -24897e-9, -13309e-10],
6
+ [0.9954, -83103e-8, -448605e-10, -986701e-12],
7
+ [0.99, -135364e-8, -59661e-9, 36777e-10],
8
+ [0.9822, -167442e-8, -449547e-11, -572411e-11],
9
+ [0.973, -214868e-8, -903571e-10, 18736e-12],
10
+ [0.96, -305085e-8, -900761e-10, 164917e-11],
11
+ [0.9427, -382792e-8, -653386e-10, -26154e-10],
12
+ [0.9216, -467746e-8, -10457e-8, 481243e-11],
13
+ [0.8962, -536223e-8, -323831e-10, -543432e-11],
14
+ [0.8679, -609363e-8, -113898e-9, 332484e-11],
15
+ [0.835, -698325e-8, -640253e-10, 934959e-12],
16
+ [0.7986, -755338e-8, -500009e-10, 935324e-12],
17
+ [0.7597, -798324e-8, -35971e-9, -227626e-11],
18
+ [0.7186, -851367e-8, -701149e-10, -86303e-10],
19
+ [0.6732, -986209e-8, -199569e-9, 191974e-10],
20
+ [0.6213, -0.010418, 883923e-10, 624051e-11],
21
+ [0.5722, -906601e-8, 182e-6, 624051e-11],
22
+ [0.5322, -677797e-8, 275608e-9, 624051e-11]
23
+ ], s = [
24
+ [-520417e-23, 0.0124, 121431e-23, -845284e-16],
25
+ [0.062, 0.0124, -126793e-14, 422642e-15],
26
+ [0.124, 0.0124, 507171e-14, -160604e-14],
27
+ [0.186, 0.0123999, -190189e-13, 600152e-14],
28
+ [0.248, 0.0124002, 710039e-13, -224e-10],
29
+ [0.31, 0.0123992, -264997e-12, 835986e-13],
30
+ [0.372, 0.0124029, 988983e-12, -311994e-12],
31
+ [0.434, 0.0123893, -369093e-11, -435621e-12],
32
+ [0.4958, 0.0123198, -102252e-10, -345523e-12],
33
+ [0.5571, 0.0121916, -154081e-10, -582288e-12],
34
+ [0.6176, 0.0119938, -241424e-10, -525327e-12],
35
+ [0.6769, 0.011713, -320223e-10, -516405e-12],
36
+ [0.7346, 0.0113541, -397684e-10, -609052e-12],
37
+ [0.7903, 0.0109107, -489042e-10, -104739e-11],
38
+ [0.8435, 0.0103431, -64615e-9, -140374e-14],
39
+ [0.8936, 969686e-8, -64636e-9, -8547e-9],
40
+ [0.9394, 840947e-8, -192841e-9, -42106e-10],
41
+ [0.9761, 616527e-8, -256e-6, -42106e-10],
42
+ [1, 328947e-8, -319159e-9, -42106e-10]
43
+ ], u = 0.8487, x = 1.3523, b = f / 5, p = 1 / b, n = 18, h = function(t, e) {
44
+ return t[0] + e * (t[1] + e * (t[2] + e * t[3]));
45
+ }, C = function(t, e) {
46
+ return t[1] + e * (2 * t[2] + e * 3 * t[3]);
47
+ };
48
+ function d(t, e, r, i) {
49
+ for (var a = e; i; --i) {
50
+ var o = t(a);
51
+ if (a -= o, Math.abs(o) < r)
52
+ break;
53
+ }
54
+ return a;
55
+ }
56
+ function F() {
57
+ this.x0 = this.x0 || 0, this.y0 = this.y0 || 0, this.long0 = this.long0 || 0, this.es = 0, this.title = this.title || "Robinson";
58
+ }
59
+ function M(t) {
60
+ var e = l(t.x - this.long0, this.over), r = Math.abs(t.y), i = Math.floor(r * b);
61
+ i < 0 ? i = 0 : i >= n && (i = n - 1), r = f * (r - p * i);
62
+ var a = {
63
+ x: h(v[i], r) * e,
64
+ y: h(s[i], r)
65
+ };
66
+ return t.y < 0 && (a.y = -a.y), a.x = a.x * this.a * u + this.x0, a.y = a.y * this.a * x + this.y0, a;
67
+ }
68
+ function R(t) {
69
+ var e = {
70
+ x: (t.x - this.x0) / (this.a * u),
71
+ y: Math.abs(t.y - this.y0) / (this.a * x)
72
+ };
73
+ if (e.y >= 1)
74
+ e.x /= v[n][0], e.y = t.y < 0 ? -y : y;
75
+ else {
76
+ var r = Math.floor(e.y * n);
77
+ for (r < 0 ? r = 0 : r >= n && (r = n - 1); ; )
78
+ if (s[r][0] > e.y)
79
+ --r;
80
+ else if (s[r + 1][0] <= e.y)
81
+ ++r;
82
+ else
83
+ break;
84
+ var i = s[r], a = 5 * (e.y - i[0]) / (s[r + 1][0] - i[0]);
85
+ a = d(function(o) {
86
+ return (h(i, o) - e.y) / C(i, o);
87
+ }, a, m, 100), e.x /= h(v[r], a), e.y = (5 * r + a) * _, t.y < 0 && (e.y = -e.y);
88
+ }
89
+ return e.x = l(e.x + this.long0, this.over), e;
90
+ }
91
+ var g = ["Robinson", "robin"];
92
+ const w = {
93
+ init: F,
94
+ forward: M,
95
+ inverse: R,
96
+ names: g
97
+ };
98
+ export {
99
+ w as default,
100
+ M as forward,
101
+ F as init,
102
+ R as inverse,
103
+ g as names
104
+ };
@@ -0,0 +1,47 @@
1
+ import r from "../common/adjust_lon.js";
2
+ import _ from "../common/adjust_lat.js";
3
+ import x from "../common/pj_enfn.js";
4
+ import y from "../common/pj_mlfn.js";
5
+ import u from "../common/pj_inv_mlfn.js";
6
+ import { HALF_PI as f, EPSLN as M } from "../constants/values.js";
7
+ import l from "../common/asinz.js";
8
+ var c = 20;
9
+ function C() {
10
+ this.sphere ? (this.n = 1, this.m = 0, this.es = 0, this.C_y = Math.sqrt((this.m + 1) / this.n), this.C_x = this.C_y / (this.m + 1)) : this.en = x(this.es);
11
+ }
12
+ function d(i) {
13
+ var s, a, h = i.x, t = i.y;
14
+ if (h = r(h - this.long0, this.over), this.sphere) {
15
+ if (!this.m)
16
+ t = this.n !== 1 ? Math.asin(this.n * Math.sin(t)) : t;
17
+ else
18
+ for (var v = this.n * Math.sin(t), e = c; e; --e) {
19
+ var o = (this.m * t + Math.sin(t) - v) / (this.m + Math.cos(t));
20
+ if (t -= o, Math.abs(o) < M)
21
+ break;
22
+ }
23
+ s = this.a * this.C_x * h * (this.m + Math.cos(t)), a = this.a * this.C_y * t;
24
+ } else {
25
+ var n = Math.sin(t), m = Math.cos(t);
26
+ a = this.a * y(t, n, m, this.en), s = this.a * h * m / Math.sqrt(1 - this.es * n * n);
27
+ }
28
+ return i.x = s, i.y = a, i;
29
+ }
30
+ function j(i) {
31
+ var s, a, h, t;
32
+ return i.x -= this.x0, h = i.x / this.a, i.y -= this.y0, s = i.y / this.a, this.sphere ? (s /= this.C_y, h = h / (this.C_x * (this.m + Math.cos(s))), this.m ? s = l((this.m * s + Math.sin(s)) / this.n) : this.n !== 1 && (s = l(Math.sin(s) / this.n)), h = r(h + this.long0, this.over), s = _(s)) : (s = u(i.y / this.a, this.es, this.en), t = Math.abs(s), t < f ? (t = Math.sin(s), a = this.long0 + i.x * Math.sqrt(1 - this.es * t * t) / (this.a * Math.cos(s)), h = r(a, this.over)) : t - M < f && (h = this.long0)), i.x = h, i.y = s, i;
33
+ }
34
+ var g = ["Sinusoidal", "sinu"];
35
+ const L = {
36
+ init: C,
37
+ forward: d,
38
+ inverse: j,
39
+ names: g
40
+ };
41
+ export {
42
+ L as default,
43
+ d as forward,
44
+ C as init,
45
+ j as inverse,
46
+ g as names
47
+ };
@@ -0,0 +1,34 @@
1
+ function b() {
2
+ var a = this.lat0;
3
+ this.lambda0 = this.long0;
4
+ var s = Math.sin(a), o = this.a, i = this.rf, h = 1 / i, t = 2 * h - Math.pow(h, 2), M = this.e = Math.sqrt(t);
5
+ this.R = this.k0 * o * Math.sqrt(1 - t) / (1 - t * Math.pow(s, 2)), this.alpha = Math.sqrt(1 + t / (1 - t) * Math.pow(Math.cos(a), 4)), this.b0 = Math.asin(s / this.alpha);
6
+ var n = Math.log(Math.tan(Math.PI / 4 + this.b0 / 2)), v = Math.log(Math.tan(Math.PI / 4 + a / 2)), r = Math.log((1 + M * s) / (1 - M * s));
7
+ this.K = n - this.alpha * v + this.alpha * M / 2 * r;
8
+ }
9
+ function c(a) {
10
+ var s = Math.log(Math.tan(Math.PI / 4 - a.y / 2)), o = this.e / 2 * Math.log((1 + this.e * Math.sin(a.y)) / (1 - this.e * Math.sin(a.y))), i = -this.alpha * (s + o) + this.K, h = 2 * (Math.atan(Math.exp(i)) - Math.PI / 4), t = this.alpha * (a.x - this.lambda0), M = Math.atan(Math.sin(t) / (Math.sin(this.b0) * Math.tan(h) + Math.cos(this.b0) * Math.cos(t))), n = Math.asin(Math.cos(this.b0) * Math.sin(h) - Math.sin(this.b0) * Math.cos(h) * Math.cos(t));
11
+ return a.y = this.R / 2 * Math.log((1 + Math.sin(n)) / (1 - Math.sin(n))) + this.y0, a.x = this.R * M + this.x0, a;
12
+ }
13
+ function y(a) {
14
+ for (var s = a.x - this.x0, o = a.y - this.y0, i = s / this.R, h = 2 * (Math.atan(Math.exp(o / this.R)) - Math.PI / 4), t = Math.asin(Math.cos(this.b0) * Math.sin(h) + Math.sin(this.b0) * Math.cos(h) * Math.cos(i)), M = Math.atan(Math.sin(i) / (Math.cos(this.b0) * Math.cos(i) - Math.sin(this.b0) * Math.tan(h))), n = this.lambda0 + M / this.alpha, v = 0, r = t, e = -1e3, l = 0; Math.abs(r - e) > 1e-7; ) {
15
+ if (++l > 20)
16
+ return;
17
+ v = 1 / this.alpha * (Math.log(Math.tan(Math.PI / 4 + t / 2)) - this.K) + this.e * Math.log(Math.tan(Math.PI / 4 + Math.asin(this.e * Math.sin(r)) / 2)), e = r, r = 2 * Math.atan(Math.exp(v)) - Math.PI / 2;
18
+ }
19
+ return a.x = n, a.y = r, a;
20
+ }
21
+ var I = ["somerc"];
22
+ const x = {
23
+ init: b,
24
+ forward: c,
25
+ inverse: y,
26
+ names: I
27
+ };
28
+ export {
29
+ x as default,
30
+ c as forward,
31
+ b as init,
32
+ y as inverse,
33
+ I as names
34
+ };
@@ -0,0 +1,46 @@
1
+ import { HALF_PI as f, EPSLN as a } from "../constants/values.js";
2
+ import m from "../common/sign.js";
3
+ import v from "../common/msfnz.js";
4
+ import X from "../common/tsfnz.js";
5
+ import g from "../common/phi2z.js";
6
+ import M from "../common/adjust_lon.js";
7
+ function x(t, s, h) {
8
+ return s *= h, Math.tan(0.5 * (f + t)) * Math.pow((1 - s) / (1 + s), 0.5 * h);
9
+ }
10
+ function u() {
11
+ this.x0 = this.x0 || 0, this.y0 = this.y0 || 0, this.lat0 = this.lat0 || 0, this.long0 = this.long0 || 0, this.coslat0 = Math.cos(this.lat0), this.sinlat0 = Math.sin(this.lat0), this.sphere ? this.k0 === 1 && !isNaN(this.lat_ts) && Math.abs(this.coslat0) <= a && (this.k0 = 0.5 * (1 + m(this.lat0) * Math.sin(this.lat_ts))) : (Math.abs(this.coslat0) <= a && (this.lat0 > 0 ? this.con = 1 : this.con = -1), this.cons = Math.sqrt(Math.pow(1 + this.e, 1 + this.e) * Math.pow(1 - this.e, 1 - this.e)), this.k0 === 1 && !isNaN(this.lat_ts) && Math.abs(this.coslat0) <= a && Math.abs(Math.cos(this.lat_ts)) > a && (this.k0 = 0.5 * this.cons * v(this.e, Math.sin(this.lat_ts), Math.cos(this.lat_ts)) / X(this.e, this.con * this.lat_ts, this.con * Math.sin(this.lat_ts))), this.ms1 = v(this.e, this.sinlat0, this.coslat0), this.X0 = 2 * Math.atan(x(this.lat0, this.sinlat0, this.e)) - f, this.cosX0 = Math.cos(this.X0), this.sinX0 = Math.sin(this.X0));
12
+ }
13
+ function b(t) {
14
+ var s = t.x, h = t.y, r = Math.sin(h), n = Math.cos(h), o, i, l, c, _, y, e = M(s - this.long0, this.over);
15
+ return Math.abs(Math.abs(s - this.long0) - Math.PI) <= a && Math.abs(h + this.lat0) <= a ? (t.x = NaN, t.y = NaN, t) : this.sphere ? (o = 2 * this.k0 / (1 + this.sinlat0 * r + this.coslat0 * n * Math.cos(e)), t.x = this.a * o * n * Math.sin(e) + this.x0, t.y = this.a * o * (this.coslat0 * r - this.sinlat0 * n * Math.cos(e)) + this.y0, t) : (i = 2 * Math.atan(x(h, r, this.e)) - f, c = Math.cos(i), l = Math.sin(i), Math.abs(this.coslat0) <= a ? (_ = X(this.e, h * this.con, this.con * r), y = 2 * this.a * this.k0 * _ / this.cons, t.x = this.x0 + y * Math.sin(s - this.long0), t.y = this.y0 - this.con * y * Math.cos(s - this.long0), t) : (Math.abs(this.sinlat0) < a ? (o = 2 * this.a * this.k0 / (1 + c * Math.cos(e)), t.y = o * l) : (o = 2 * this.a * this.k0 * this.ms1 / (this.cosX0 * (1 + this.sinX0 * l + this.cosX0 * c * Math.cos(e))), t.y = o * (this.cosX0 * l - this.sinX0 * c * Math.cos(e)) + this.y0), t.x = o * c * Math.sin(e) + this.x0, t));
16
+ }
17
+ function k(t) {
18
+ t.x -= this.x0, t.y -= this.y0;
19
+ var s, h, r, n, o, i = Math.sqrt(t.x * t.x + t.y * t.y);
20
+ if (this.sphere) {
21
+ var l = 2 * Math.atan(i / (2 * this.a * this.k0));
22
+ return s = this.long0, h = this.lat0, i <= a ? (t.x = s, t.y = h, t) : (h = Math.asin(Math.cos(l) * this.sinlat0 + t.y * Math.sin(l) * this.coslat0 / i), Math.abs(this.coslat0) < a ? this.lat0 > 0 ? s = M(this.long0 + Math.atan2(t.x, -1 * t.y), this.over) : s = M(this.long0 + Math.atan2(t.x, t.y), this.over) : s = M(this.long0 + Math.atan2(t.x * Math.sin(l), i * this.coslat0 * Math.cos(l) - t.y * this.sinlat0 * Math.sin(l)), this.over), t.x = s, t.y = h, t);
23
+ } else if (Math.abs(this.coslat0) <= a) {
24
+ if (i <= a)
25
+ return h = this.lat0, s = this.long0, t.x = s, t.y = h, t;
26
+ t.x *= this.con, t.y *= this.con, r = i * this.cons / (2 * this.a * this.k0), h = this.con * g(this.e, r), s = this.con * M(this.con * this.long0 + Math.atan2(t.x, -1 * t.y), this.over);
27
+ } else
28
+ n = 2 * Math.atan(i * this.cosX0 / (2 * this.a * this.k0 * this.ms1)), s = this.long0, i <= a ? o = this.X0 : (o = Math.asin(Math.cos(n) * this.sinX0 + t.y * Math.sin(n) * this.cosX0 / i), s = M(this.long0 + Math.atan2(t.x * Math.sin(n), i * this.cosX0 * Math.cos(n) - t.y * this.sinX0 * Math.sin(n)), this.over)), h = -1 * g(this.e, Math.tan(0.5 * (f + o)));
29
+ return t.x = s, t.y = h, t;
30
+ }
31
+ var N = ["stere", "Stereographic_South_Pole", "Polar_Stereographic_variant_A", "Polar_Stereographic_variant_B", "Polar_Stereographic"];
32
+ const q = {
33
+ init: u,
34
+ forward: b,
35
+ inverse: k,
36
+ names: N,
37
+ ssfn_: x
38
+ };
39
+ export {
40
+ q as default,
41
+ b as forward,
42
+ u as init,
43
+ k as inverse,
44
+ N as names,
45
+ x as ssfn_
46
+ };