Skip to content

Commit 1b94713

Browse files
committed
Website updates
1 parent 2caa325 commit 1b94713

File tree

10 files changed

+777
-156
lines changed

10 files changed

+777
-156
lines changed

dist/en/main/apidoc/module-ol_interaction_Modify-Modify.html

Lines changed: 375 additions & 7 deletions
Large diffs are not rendered by default.

dist/en/main/apidoc/module-ol_interaction_Modify.html

Lines changed: 61 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -63,6 +63,19 @@
6363
</div>
6464
<div class="navigation-list-wrapper">
6565
<ul class="navigation-list search-empty">
66+
<li class="item item-module toggle-manual toggle-manual-show" data-longname="module:ol/interaction/Modify" data-name="ol/interaction/modify">
67+
<span class="title toggle">
68+
<span class="fa fa-plus me-2 mt-1"></span>
69+
<span><a href="module-ol_interaction_Modify.html">ol​/interaction​/Modify</a></span>
70+
</span>
71+
<div class="member-list" data-type="typedefs">
72+
<span class="subtitle">Typedefs</span>
73+
<ul>
74+
<li data-name="dragsegment"><a href="module-ol_interaction_Modify.html#~DragSegment">DragSegment</a>
75+
<li data-name="options"><a href="module-ol_interaction_Modify.html#~Options">Options</a>
76+
<li data-name="segmentdata"><a href="module-ol_interaction_Modify.html#~SegmentData">SegmentData</a>
77+
</ul>
78+
</div>
6679
<li class="loading">Loading …
6780
</ul>
6881
</div>
@@ -166,6 +179,52 @@ <h3 class="subsection-title">Type Definitions</h3>
166179

167180
<dl>
168181

182+
<dt class="">
183+
<div class="nameContainer">
184+
<div class="anchor" id="~DragSegment">
185+
</div>
186+
<h4 class="name">
187+
DragSegment<span class="type-signature type array">{Array}</span>
188+
189+
190+
</h4>
191+
</div>
192+
193+
</dt>
194+
<dd class="">
195+
196+
197+
198+
<dl class="details">
199+
200+
201+
202+
203+
204+
205+
206+
207+
208+
209+
210+
211+
212+
213+
214+
215+
216+
217+
218+
219+
220+
</dl>
221+
222+
223+
224+
</dd>
225+
226+
227+
169228
<dt class="">
170229
<div class="nameContainer">
171230
<div class="anchor" id="~Options">
@@ -333,7 +392,8 @@ <h5 class="subsection-title">Properties:</h5>
333392
<p>Style used for the modification point or vertex. For linestrings and polygons, this will
334393
be the affected vertex, for circles a point along the circle, and for points the actual
335394
point. If not configured, the default edit style is used (see <a href="module-ol_style_Style-Style.html"><code>Style</code></a>).
336-
When using a style function, the point feature passed to the function will have a <code>features</code>
395+
When using a style function, the point feature passed to the function will have an <code>existing</code> property -
396+
indicating whether there is an existing vertex underneath or not, a <code>features</code>
337397
property - an array whose entries are the features that are being modified, and a <code>geometries</code>
338398
property - an array whose entries are the geometries that are being modified. Both arrays are
339399
in the same order. The <code>geometries</code> are only useful when modifying geometry collections, where

dist/en/main/apidoc/navigation.tmpl.html

Lines changed: 16 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2836,6 +2836,8 @@
28362836
<div class="member-list" data-type="methods">
28372837
<span class="subtitle">Methods</span>
28382838
<ul>
2839+
<li data-name="caninsertpoint"><a href="module-ol_interaction_Modify-Modify.html#canInsertPoint">canInsertPoint</a>
2840+
<li data-name="canremovepoint"><a href="module-ol_interaction_Modify-Modify.html#canRemovePoint">canRemovePoint</a>
28392841
<li data-name="changed"><a href="module-ol_interaction_Modify-Modify.html#changed">changed</a>
28402842
<li data-name="dispatchevent"><a href="module-ol_interaction_Modify-Modify.html#dispatchEvent">dispatchEvent</a>
28412843
<li data-name="get"><a href="module-ol_interaction_Modify-Modify.html#get">get</a>
@@ -2846,6 +2848,7 @@
28462848
<li data-name="getpointercount"><a href="module-ol_interaction_Modify-Modify.html#getPointerCount">getPointerCount</a>
28472849
<li data-name="getproperties"><a href="module-ol_interaction_Modify-Modify.html#getProperties">getProperties</a>
28482850
<li data-name="getrevision"><a href="module-ol_interaction_Modify-Modify.html#getRevision">getRevision</a>
2851+
<li data-name="insertpoint"><a href="module-ol_interaction_Modify-Modify.html#insertPoint">insertPoint</a>
28492852
<li data-name="on"><a href="module-ol_interaction_Modify-Modify.html#on">on</a>
28502853
<li data-name="once"><a href="module-ol_interaction_Modify-Modify.html#once">once</a>
28512854
<li data-name="removepoint"><a href="module-ol_interaction_Modify-Modify.html#removePoint">removePoint</a>
@@ -2867,6 +2870,19 @@
28672870
<li data-name="propertychange"><a href="module-ol_Object.ObjectEvent.html#event:propertychange">propertychange</a>
28682871
</ul>
28692872
</div>
2873+
<li class="item item-module" data-longname="module:ol/interaction/Modify" data-name="ol/interaction/modify">
2874+
<span class="title toggle">
2875+
<span class="fa fa-plus me-2 mt-1"></span>
2876+
<span><a href="module-ol_interaction_Modify.html">ol​/interaction​/Modify</a></span>
2877+
</span>
2878+
<div class="member-list" data-type="typedefs">
2879+
<span class="subtitle">Typedefs</span>
2880+
<ul>
2881+
<li data-name="dragsegment"><a href="module-ol_interaction_Modify.html#~DragSegment">DragSegment</a>
2882+
<li data-name="options"><a href="module-ol_interaction_Modify.html#~Options">Options</a>
2883+
<li data-name="segmentdata"><a href="module-ol_interaction_Modify.html#~SegmentData">SegmentData</a>
2884+
</ul>
2885+
</div>
28702886
<li class="item item-class" data-longname="module:ol/interaction/Modify.ModifyEvent" data-name="ol/interaction/modify.modifyevent">
28712887
<span class="title toggle">
28722888
<span class="fa fa-chevron-right me-2 mt-1"></span>

dist/en/main/examples/common.js

Lines changed: 1 addition & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

dist/en/main/examples/common.js.map

Lines changed: 1 addition & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

dist/en/main/ol/dist/ol.js

Lines changed: 1 addition & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

dist/en/main/ol/dist/ol.js.map

Lines changed: 1 addition & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

dist/en/main/ol/interaction/Modify.d.ts

Lines changed: 46 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -7,6 +7,9 @@
77
* @property {Array<Array<number>>} segment Segment.
88
* @property {Array<SegmentData>} [featureSegments] FeatureSegments.
99
*/
10+
/**
11+
* @typedef {[SegmentData, number]} DragSegment
12+
*/
1013
/**
1114
* @typedef {Object} Options
1215
* @property {import("../events/condition.js").Condition} [condition] A function that
@@ -29,7 +32,8 @@
2932
* Style used for the modification point or vertex. For linestrings and polygons, this will
3033
* be the affected vertex, for circles a point along the circle, and for points the actual
3134
* point. If not configured, the default edit style is used (see {@link module:ol/style/Style~Style}).
32-
* When using a style function, the point feature passed to the function will have a `features`
35+
* When using a style function, the point feature passed to the function will have an `existing` property -
36+
* indicating whether there is an existing vertex underneath or not, a `features`
3337
* property - an array whose entries are the features that are being modified, and a `geometries`
3438
* property - an array whose entries are the geometries that are being modified. Both arrays are
3539
* in the same order. The `geometries` are only useful when modifying geometry collections, where
@@ -103,6 +107,7 @@ export type SegmentData = {
103107
*/
104108
featureSegments?: SegmentData[] | undefined;
105109
};
110+
export type DragSegment = [SegmentData, number];
106111
export type Options = {
107112
/**
108113
* A function that
@@ -136,7 +141,8 @@ export type Options = {
136141
* Style used for the modification point or vertex. For linestrings and polygons, this will
137142
* be the affected vertex, for circles a point along the circle, and for points the actual
138143
* point. If not configured, the default edit style is used (see {@link module :ol/style/Style~Style}).
139-
* When using a style function, the point feature passed to the function will have a `features`
144+
* When using a style function, the point feature passed to the function will have an `existing` property -
145+
* indicating whether there is an existing vertex underneath or not, a `features`
140146
* property - an array whose entries are the features that are being modified, and a `geometries`
141147
* property - an array whose entries are the geometries that are being modified. Both arrays are
142148
* in the same order. The `geometries` are only useful when modifying geometry collections, where
@@ -307,7 +313,7 @@ declare class Modify extends PointerInteraction {
307313
*/
308314
private changingFeature_;
309315
/**
310-
* @type {Array}
316+
* @type {Array<DragSegment>}
311317
* @private
312318
*/
313319
private dragSegments_;
@@ -360,7 +366,7 @@ declare class Modify extends PointerInteraction {
360366
private addFeature_;
361367
/**
362368
* @param {import("../MapBrowserEvent.js").default} evt Map browser event.
363-
* @param {Array<Array<SegmentData>>} segments The segments subject to modification.
369+
* @param {Array<SegmentData>} segments The segments subject to modification.
364370
* @private
365371
*/
366372
private willModifyFeatures_;
@@ -471,40 +477,71 @@ declare class Modify extends PointerInteraction {
471477
* @param {import("../coordinate.js").Coordinate} coordinates Coordinates.
472478
* @param {Array<Feature>} features The features being modified.
473479
* @param {Array<import("../geom/SimpleGeometry.js").default>} geometries The geometries being modified.
480+
* @param {boolean} existing The vertex represents an existing vertex.
474481
* @return {Feature} Vertex feature.
475482
* @private
476483
*/
477484
private createOrUpdateVertexFeature_;
485+
findInsertVerticesAndUpdateDragSegments_(pixelCoordinate: any): SegmentData[] | undefined;
478486
/**
479487
* @param {import("../MapBrowserEvent.js").default} evt Event.
480488
* @private
481489
*/
482490
private handlePointerMove_;
483491
/**
484-
* @param {import("../pixel.js").Pixel} pixel Pixel
485-
* @param {import("../Map.js").default} map Map.
486-
* @param {import("../coordinate.js").Coordinate} [coordinate] The pixel Coordinate.
492+
* @param {import("../coordinate.js").Coordinate} pixelCoordinate The pixel Coordinate.
487493
* @private
488494
*/
489495
private handlePointerAtPixel_;
490496
/**
491497
* @param {SegmentData} segmentData Segment data.
492498
* @param {import("../coordinate.js").Coordinate} vertex Vertex.
499+
* @return {boolean} A vertex was inserted.
493500
* @private
494501
*/
495502
private insertVertex_;
503+
updatePointer_(coordinate: any): import("../coordinate.js").Coordinate;
504+
/**
505+
* Get the current pointer position.
506+
* @return {import("../coordinate.js").Coordinate | null} The current pointer coordinate.
507+
*/
508+
getPoint(): import("../coordinate.js").Coordinate | null;
509+
/**
510+
* Check if a point can be removed from the current linestring or polygon at the current
511+
* pointer position.
512+
* @return {boolean} A point can be deleted at the current pointer position.
513+
* @api
514+
*/
515+
canRemovePoint(): boolean;
496516
/**
497-
* Removes the vertex currently being pointed.
517+
* Removes the vertex currently being pointed from the current linestring or polygon.
518+
* @param {import('../coordinate.js').Coordinate} [coordinate] If provided, the pointer
519+
* will be set to the provided coordinate. If not, the current pointer coordinate will be used.
498520
* @return {boolean} True when a vertex was removed.
499521
* @api
500522
*/
501-
removePoint(): boolean;
523+
removePoint(coordinate?: import("../coordinate.js").Coordinate | undefined): boolean;
502524
/**
503525
* Removes a vertex from all matching features.
504526
* @return {boolean} True when a vertex was removed.
505527
* @private
506528
*/
507529
private removeVertex_;
530+
/**
531+
* Check if a point can be inserted to the current linestring or polygon at the current
532+
* pointer position.
533+
* @return {boolean} A point can be inserted at the current pointer position.
534+
* @api
535+
*/
536+
canInsertPoint(): boolean;
537+
/**
538+
* Inserts the vertex currently being pointed to the current linestring or polygon.
539+
* @param {import('../coordinate.js').Coordinate} [coordinate] If provided, the pointer
540+
* will be set to the provided coordinate. If not, the current pointer coordinate will be used.
541+
* @return {boolean} A vertex was inserted.
542+
* @api
543+
*/
544+
insertPoint(coordinate?: import("../coordinate.js").Coordinate | undefined): boolean;
508545
/**
509546
* @param {import("../geom/SimpleGeometry.js").default} geometry Geometry.
510547
* @param {Array} coordinates Coordinates.

dist/en/main/ol/interaction/Modify.d.ts.map

Lines changed: 1 addition & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

0 commit comments

Comments
 (0)