maplibre-gl 2.1.8-pre.1 → 2.1.8

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 (51) hide show
  1. package/build/readme.md +1 -1
  2. package/build/rollup_plugins.ts +7 -7
  3. package/dist/maplibre-gl-csp-worker.js +1 -1
  4. package/dist/maplibre-gl-csp-worker.js.map +1 -1
  5. package/dist/maplibre-gl-csp.js +1 -1
  6. package/dist/maplibre-gl-csp.js.map +1 -1
  7. package/dist/maplibre-gl-dev.js +90 -93
  8. package/dist/maplibre-gl.d.ts +56 -23
  9. package/dist/maplibre-gl.js +3 -3
  10. package/dist/maplibre-gl.js.map +1 -1
  11. package/package.json +3 -4
  12. package/src/data/feature_index.ts +3 -2
  13. package/src/geo/lng_lat_bounds.ts +1 -1
  14. package/src/geo/transform.test.ts +14 -0
  15. package/src/geo/transform.ts +5 -5
  16. package/src/index.ts +2 -0
  17. package/src/render/painter.ts +2 -2
  18. package/src/render/program/fill_extrusion_program.ts +1 -1
  19. package/src/source/load_tilejson.ts +1 -1
  20. package/src/source/query_features.ts +3 -2
  21. package/src/source/raster_tile_source.ts +2 -4
  22. package/src/source/source.ts +0 -1
  23. package/src/source/source_cache.test.ts +39 -0
  24. package/src/source/source_cache.ts +4 -1
  25. package/src/source/tile.ts +2 -1
  26. package/src/source/vector_tile_worker_source.ts +2 -4
  27. package/src/style/query_utils.test.ts +107 -0
  28. package/src/style/query_utils.ts +25 -0
  29. package/src/style/style.test.ts +9 -2
  30. package/src/style/style.ts +6 -6
  31. package/src/style/style_layer/circle_style_layer.ts +2 -2
  32. package/src/style/style_layer/custom_style_layer.ts +4 -4
  33. package/src/style/style_layer/fill_extrusion_style_layer.ts +1 -1
  34. package/src/style/style_layer/line_style_layer.ts +1 -25
  35. package/src/style-spec/package.json +1 -1
  36. package/src/style-spec/reference/v8.json +1 -1
  37. package/src/symbol/collision_index.test.ts +18 -0
  38. package/src/symbol/collision_index.ts +1 -1
  39. package/src/symbol/projection.test.ts +12 -0
  40. package/src/symbol/projection.ts +2 -2
  41. package/src/ui/control/logo_control.test.ts +34 -78
  42. package/src/ui/control/logo_control.ts +27 -37
  43. package/src/ui/events.ts +1 -1
  44. package/src/ui/map.test.ts +2 -2
  45. package/src/ui/map.ts +15 -14
  46. package/src/util/ajax.test.ts +12 -4
  47. package/src/util/ajax.ts +16 -7
  48. package/src/util/test/util.ts +1 -0
  49. package/src/util/vectortile_to_geojson.ts +9 -1
  50. package/dist/maplibre-gl-unminified.js +0 -39022
  51. package/dist/maplibre-gl-unminified.js.map +0 -1
package/build/readme.md CHANGED
@@ -8,7 +8,7 @@ The bundeling process can be split into several steps:
8
8
  `npm run build-css`
9
9
  This command will compile the css code and create the css file.
10
10
 
11
- `npm run build-prod` or `npm run build-prod-min` or `npm run build-dev`
11
+ `npm run build-prod` and `npm run build-dev`
12
12
  These commands will use rollup to bundle the code. This is where the magic happens and uses some files in this folder.
13
13
 
14
14
  `banner.ts` is used to create a banner at the beginning of the output file
@@ -17,7 +17,7 @@ export const nodeResolve = resolve({
17
17
  preferBuiltins: false
18
18
  });
19
19
 
20
- export const plugins = (minified: boolean, production: boolean): Plugin[] => [
20
+ export const plugins = (production: boolean): Plugin[] => [
21
21
  minifyStyleSpec(),
22
22
  json(),
23
23
  // https://github.com/zaach/jison/issues/351
@@ -29,20 +29,20 @@ export const plugins = (minified: boolean, production: boolean): Plugin[] => [
29
29
  '_token_stack:': ''
30
30
  }
31
31
  }),
32
- production ? strip({
32
+ production && strip({
33
33
  sourceMap: true,
34
34
  functions: ['PerformanceUtils.*', 'Debug.*']
35
- }) : false,
36
- minified ? terser({
35
+ }),
36
+ production && terser({
37
37
  compress: {
38
38
  // eslint-disable-next-line camelcase
39
39
  pure_getters: true,
40
40
  passes: 3
41
41
  }
42
- }) : false,
43
- production ? unassert({
42
+ }),
43
+ production && unassert({
44
44
  include: ['**/*'], // by default, unassert only includes .js files
45
- }) : false,
45
+ }),
46
46
  nodeResolve,
47
47
  typescript(),
48
48
  commonjs({