UNPKG

3.11 kBTypeScriptView Raw
1import Collection from './Collection';
2import Interaction from './interaction/Interaction';
3
4export { default as DoubleClickZoom } from './interaction/DoubleClickZoom';
5export { default as DragAndDrop } from './interaction/DragAndDrop';
6export { default as DragBox } from './interaction/DragBox';
7export { default as DragPan } from './interaction/DragPan';
8export { default as DragRotate } from './interaction/DragRotate';
9export { default as DragRotateAndZoom } from './interaction/DragRotateAndZoom';
10export { default as DragZoom } from './interaction/DragZoom';
11export { default as Draw } from './interaction/Draw';
12export { default as Extent } from './interaction/Extent';
13export { default as Interaction } from './interaction/Interaction';
14export { default as KeyboardPan } from './interaction/KeyboardPan';
15export { default as KeyboardZoom } from './interaction/KeyboardZoom';
16export { default as Modify } from './interaction/Modify';
17export { default as MouseWheelZoom } from './interaction/MouseWheelZoom';
18export { default as PinchRotate } from './interaction/PinchRotate';
19export { default as PinchZoom } from './interaction/PinchZoom';
20export { default as Pointer } from './interaction/Pointer';
21export { default as Select } from './interaction/Select';
22export { default as Snap } from './interaction/Snap';
23export { default as Translate } from './interaction/Translate';
24
25export interface DefaultsOptions {
26 altShiftDragRotate?: boolean | undefined;
27 onFocusOnly?: boolean | undefined;
28 doubleClickZoom?: boolean | undefined;
29 keyboard?: boolean | undefined;
30 mouseWheelZoom?: boolean | undefined;
31 shiftDragZoom?: boolean | undefined;
32 dragPan?: boolean | undefined;
33 pinchRotate?: boolean | undefined;
34 pinchZoom?: boolean | undefined;
35 zoomDelta?: number | undefined;
36 zoomDuration?: number | undefined;
37}
38/**
39 * Set of interactions included in maps by default. Specific interactions can be
40 * excluded by setting the appropriate option to false in the constructor
41 * options, but the order of the interactions is fixed. If you want to specify
42 * a different order for interactions, you will need to create your own
43 * {@link module:ol/interaction/Interaction} instances and insert
44 * them into a {@link module:ol/Collection} in the order you want
45 * before creating your {@link module:ol/Map~Map} instance. Changing the order can
46 * be of interest if the event propagation needs to be stopped at a point.
47 * The default set of interactions, in sequence, is:
48 *
49 * {@link module:ol/interaction/DragRotate~DragRotate}
50 * {@link module:ol/interaction/DoubleClickZoom~DoubleClickZoom}
51 * {@link module:ol/interaction/DragPan~DragPan}
52 * {@link module:ol/interaction/PinchRotate~PinchRotate}
53 * {@link module:ol/interaction/PinchZoom~PinchZoom}
54 * {@link module:ol/interaction/KeyboardPan~KeyboardPan}
55 * {@link module:ol/interaction/KeyboardZoom~KeyboardZoom}
56 * {@link module:ol/interaction/MouseWheelZoom~MouseWheelZoom}
57 * {@link module:ol/interaction/DragZoom~DragZoom}
58 *
59 */
60export function defaults(opt_options?: DefaultsOptions): Collection<Interaction>;