mirror of
https://github.com/zhigang1992/DefinitelyTyped.git
synced 2026-05-31 11:07:32 +08:00
Merge pull request #19823 from Namue/master
Added minArea to @types/openlayers DragBoxOptions
This commit is contained in:
2
types/openlayers/index.d.ts
vendored
2
types/openlayers/index.d.ts
vendored
@@ -12436,11 +12436,13 @@ declare module olx {
|
||||
/**
|
||||
* @typedef {{className: (string|undefined),
|
||||
* condition: (ol.EventsConditionType|undefined),
|
||||
* minArea: (number|undefined),
|
||||
* boxEndCondition: (ol.DragBoxEndConditionType|undefined)}}
|
||||
*/
|
||||
interface DragBoxOptions {
|
||||
className?: string;
|
||||
condition?: ol.EventsConditionType;
|
||||
minArea?: number;
|
||||
boxEndCondition?: ol.DragBoxEndConditionType;
|
||||
}
|
||||
|
||||
|
||||
@@ -695,6 +695,7 @@ draw = new ol.interaction.Draw({
|
||||
|
||||
let dragbox: ol.interaction.DragBox = new ol.interaction.DragBox({
|
||||
className: stringValue,
|
||||
minArea: 10,
|
||||
condition: ol.events.condition.always,
|
||||
boxEndCondition: function (mapBrowserEvent: ol.MapBrowserEvent, startPixel: ol.Pixel, endPixel: ol.Pixel) {
|
||||
let width: number = endPixel[0] - startPixel[0];
|
||||
|
||||
Reference in New Issue
Block a user