terra-draw 0.0.1-alpha.16 → 0.0.1-alpha.18

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/CHANGELOG.md CHANGED
@@ -2,6 +2,36 @@
2
2
 
3
3
  All notable changes to this project will be documented in this file. See [standard-version](https://github.com/conventional-changelog/standard-version) for commit guidelines.
4
4
 
5
+ ### [0.0.1-alpha.18](https://github.com/JamesLMilner/terra-draw/compare/v0.0.1-alpha.17...v0.0.1-alpha.18) (2023-03-19)
6
+
7
+
8
+ ### Bug Fixes
9
+
10
+ * better parity between mouse and pointer experiences ([00c219d](https://github.com/JamesLMilner/terra-draw/commit/00c219de114383d7e3f7ad58d91fc6de9c2bb7c9))
11
+ * ensure that closing points for polygons are update on click ([25c0886](https://github.com/JamesLMilner/terra-draw/commit/25c0886237c56881073e44da839b07527362662c))
12
+
13
+
14
+ ### Chore
15
+
16
+ * fix issues with prettier conflicting with eslint ([9849bce](https://github.com/JamesLMilner/terra-draw/commit/9849bce825f2073d1b72b0dc9a29718a0cb994d9))
17
+
18
+ ### [0.0.1-alpha.17](https://github.com/JamesLMilner/terra-draw/compare/v0.0.1-alpha.16...v0.0.1-alpha.17) (2023-03-12)
19
+
20
+
21
+ ### Bug Fixes
22
+
23
+ * fix unit test for great-circle-snapping.behavior ([c90cd86](https://github.com/JamesLMilner/terra-draw/commit/c90cd86125339d43768bf6f0936f85bc09bd6833))
24
+ * use project/unproject to get midpoints that are visually centered ([3581da2](https://github.com/JamesLMilner/terra-draw/commit/3581da2cd89ace7c555c747cdae8115c90ec851d))
25
+
26
+
27
+ ### Chore
28
+
29
+ * add better test coverage for great circle mode ([4073553](https://github.com/JamesLMilner/terra-draw/commit/4073553563cdfece1f48c3b00a86a6a19457a820))
30
+ * husk precommit only readd linted files ([2eb6138](https://github.com/JamesLMilner/terra-draw/commit/2eb6138a47fc5f48334bcf7b657fa4ac8783dc76))
31
+ * make sure all mode tests are labelled correctly ([a5dfe4b](https://github.com/JamesLMilner/terra-draw/commit/a5dfe4bd79cfb33daaf47195e05b72e0fba4087c))
32
+ * make sure test files are no covered in jest coverage when type checking disabled ([0b271b6](https://github.com/JamesLMilner/terra-draw/commit/0b271b6bf9f764c03bea1f3f4a9bc949ffa830e6))
33
+ * remove unused import from static.mode.spec.ts ([e2bf578](https://github.com/JamesLMilner/terra-draw/commit/e2bf5785f00bf92c72f6054441212a1e98d07abe))
34
+
5
35
  ### [0.0.1-alpha.16](https://github.com/JamesLMilner/terra-draw/compare/v0.0.1-alpha.15...v0.0.1-alpha.16) (2023-02-19)
6
36
 
7
37
 
@@ -5,7 +5,7 @@ export declare class AdapterListener {
5
5
  register: any;
6
6
  unregister: any;
7
7
  private listeners;
8
- constructor({ name, callback, unregister, register }: {
8
+ constructor({ name, callback, unregister, register, }: {
9
9
  name: string;
10
10
  callback: (...args: any[]) => any;
11
11
  unregister: (...callbacks: any[]) => void;
@@ -1,12 +1,12 @@
1
1
  import { TerraDrawCallbacks, TerraDrawAdapter, TerraDrawModeRegisterConfig, TerraDrawAdapterStyling, TerraDrawChanges } from "../common";
2
2
  import { GeoJSONStoreFeatures } from "../store/store";
3
- import CircleGeom from 'ol/geom/Circle';
4
- import Feature from 'ol/Feature';
5
- import GeoJSON from 'ol/format/GeoJSON';
6
- import Map from 'ol/Map';
7
- import Circle from 'ol/style/Circle';
8
- import Stroke from 'ol/style/Stroke';
9
- import Style from 'ol/style/Style';
3
+ import CircleGeom from "ol/geom/Circle";
4
+ import Feature from "ol/Feature";
5
+ import GeoJSON from "ol/format/GeoJSON";
6
+ import Map from "ol/Map";
7
+ import Circle from "ol/style/Circle";
8
+ import Stroke from "ol/style/Stroke";
9
+ import Style from "ol/style/Style";
10
10
  import VectorSource from "ol/source/Vector";
11
11
  import VectorLayer from "ol/layer/Vector";
12
12
  import { toLonLat } from "ol/proj";
@@ -1,7 +1,8 @@
1
1
  import { Point, Position } from "geojson";
2
+ import { Project, Unproject } from "../common";
2
3
  import { JSONObject } from "../store/store";
3
- export declare function getMidPointCoordinates(featureCoords: Position[], precision: number): Position[];
4
- export declare function getMidPoints(selectedCoords: Position[], properties: (index: number) => JSONObject, precision: number): {
4
+ export declare function getMidPointCoordinates(featureCoords: Position[], precision: number, project: Project, unproject: Unproject): Position[];
5
+ export declare function getMidPoints(selectedCoords: Position[], properties: (index: number) => JSONObject, precision: number, project: Project, unproject: Unproject): {
5
6
  geometry: Point;
6
7
  properties: JSONObject;
7
8
  }[];
@@ -1,2 +1,3 @@
1
1
  import { Position } from "geojson";
2
- export declare function midpointCoordinate(coordinates1: Position, coordinates2: Position, precision: number): number[];
2
+ import { Project, Unproject } from "../common";
3
+ export declare function midpointCoordinate(coordinates1: Position, coordinates2: Position, precision: number, project: Project, unproject: Unproject): number[];
@@ -1,6 +1,6 @@
1
1
  import { Feature, LineString, Position } from "geojson";
2
2
  import { JSONObject } from "../../store/store";
3
- export declare function greatCircleLine<Properties extends JSONObject>({ start, end, options }: {
3
+ export declare function greatCircleLine<Properties extends JSONObject>({ start, end, options, }: {
4
4
  start: Position;
5
5
  end: Position;
6
6
  options?: {
@@ -22,6 +22,7 @@ export declare class TerraDrawLineStringMode extends TerraDrawBaseDrawMode<LineS
22
22
  private allowSelfIntersections;
23
23
  private keyEvents;
24
24
  private snappingEnabled;
25
+ private mouseMove;
25
26
  private snapping;
26
27
  constructor(options?: {
27
28
  snapping?: boolean;
@@ -23,10 +23,10 @@ export declare class TerraDrawPolygonMode extends TerraDrawBaseDrawMode<PolygonS
23
23
  private allowSelfIntersections;
24
24
  private keyEvents;
25
25
  private snappingEnabled;
26
- private isClosed;
27
26
  private snapping;
28
27
  private pixelDistance;
29
28
  private closingPoints;
29
+ private mouseMove;
30
30
  constructor(options?: {
31
31
  allowSelfIntersections?: boolean;
32
32
  snapping?: boolean;