Tim Schaub
054af09032
Make code prettier
...
This updates ESLint and our shared eslint-config-openlayers to use Prettier. Most formatting changes were automatically applied with this:
npm run lint -- --fix
A few manual changes were required:
* In `examples/offscreen-canvas.js`, the `//eslint-disable-line` comment needed to be moved to the appropriate line to disable the error about the `'worker-loader!./offscreen-canvas.worker.js'` import.
* In `examples/webpack/exapmle-builder.js`, spaces could not be added after a couple `function`s for some reason. While editing this, I reworked `ExampleBuilder` to be a class.
* In `src/ol/format/WMSGetFeatureInfo.js`, the `// @ts-ignore` comment needed to be moved down one line so it applied to the `parsersNS` argument.
2020-04-06 12:54:09 -06:00
ahocevar
74e8e013cf
Use pepjs instead of our own pointerevent polyfill
2019-08-29 18:58:53 +02:00
Frederic Junod
7c215b2532
Remove TOUCH, POINTER and MSPOINTER from ol/has
2019-06-01 07:18:23 +02:00
Niklas Alt
4bc9216e41
Add ': void' to non returning functions (error TS7014)
2018-12-06 19:57:45 +01:00
Frederic Junod
59c95dbe90
Simplify import path in ol/pointer/
2018-11-05 16:26:45 +01:00
ahocevar
9163558511
Replace instanceof checks with other logic
2018-10-12 20:35:59 +02:00
Kevin Schmidt
d3a82b0586
Fix type check errors in ol/pointer
2018-10-03 10:41:29 -06:00
ahocevar
3f79edba67
Use setTimeout with any return type
2018-10-03 10:50:44 +02:00
Kevin Schmidt
b6846d6b3d
Use window.setTimeout to avoid TS conflict with Node's setTimeout
2018-10-01 15:41:03 -06:00
Frederic Junod
05c0b77a52
Move functions out of the PointerEvent class
2018-09-27 13:49:18 +02:00
Frederic Junod
821a08ea79
Remove extra imports in jsdoc
...
The symbols are already imported (es6 import)
2018-09-21 09:12:06 +02:00
Florent gravin
25ade66017
Fix type conflict between Event and events/Event.js
2018-09-19 16:48:51 +02:00
Frederic Junod
960b433a2c
Remove webkit specific properties from Touch
...
Remove the following errors from the TypeScript checks:
```
src/ol/pointer/TouchSource.js(231,23): error TS2339: Property 'webkitRadiusX' does not exist on type 'Touch'.
src/ol/pointer/TouchSource.js(232,24): error TS2339: Property 'webkitRadiusY' does not exist on type 'Touch'.
src/ol/pointer/TouchSource.js(233,26): error TS2339: Property 'webkitForce' does not exist on type 'Touch'.
```
The only reference that I've found for these properties is a warning message from Google Chrome:
```
'Touch.webkitRadiusX' is deprecated and will be removed in M47, around November 2015. Please use 'Touch.radiusX' instead.
```
2018-09-18 13:36:38 +02:00
Frederic Junod
ea616e7751
Don't import ourselves
2018-09-06 09:05:32 +02:00
Tim Schaub
ccfacc5ee6
Transformed types
...
Using the [ts.js codemod](https://gist.github.com/tschaub/1ea498c9d1e5268cf36d212b3949be4e ):
jscodeshift --transform ts.js src
2018-09-05 08:05:29 -06:00
Marc Jansen
281873f22a
Cast POINTER_ID before comparison
2018-09-04 09:37:15 +02:00
ahocevar
2f92e48e93
Use super.method instead of prototype.method.call
2018-08-06 15:30:17 +02:00
ahocevar
c74b9c1d55
Do not prevent default on pointermove
...
Instead, only prevent default on handled pointerdown events. This makes
the `focus` condition work with interactions that involve dragging on
touch devices.
2018-07-31 08:33:15 +02:00
Tim Schaub
40486a0ecc
Avoid shadowing EventTarget
2018-07-26 10:14:58 -06:00
Tim Schaub
affbf59b77
Use Object<Foo, Bar> instead of Object.<Foo, Bar>
2018-07-25 18:33:49 -07:00
Tim Schaub
d12ef20b12
Use Array<Foo> instead of Array.<Foo>
2018-07-25 18:32:43 -07:00
Tim Schaub
e5493d1288
Add ol/pixel module for Pixel type
2018-07-19 10:17:00 -06:00
Tim Schaub
069187859d
Cleaned up ol/pointer classes
2018-07-17 17:48:27 -06:00
Tim Schaub
d0ab8dce38
Lint removal
2018-07-16 17:57:57 -06:00
Tim Schaub
7b4a73f3b9
Automated class transform
...
npx lebab --replace src --transform class
2018-07-16 16:18:16 -06:00
Frederic Junod
6da2e4cef4
More precise Event typing
2018-06-29 12:53:20 +02:00
ahocevar
28409486a5
Make classes in ol/ available as named exports from ol
2018-06-21 18:08:17 +02:00
Frederic Junod
90ce02941a
Better code indentation
2018-05-14 14:58:36 +02:00
Frederic Junod
9f3b103bbf
Better variables scoping
2018-05-14 14:49:09 +02:00
Frederic Junod
14deb417a9
Use MSPointerEvent event type in ol/pointer/MsSource
2018-05-09 16:39:59 +02:00
ahocevar
440d1ad3e1
Shorter module paths for default exports
2018-04-25 17:25:39 +02:00
Frederic Junod
b2d9f94cb2
Module type for ol.pointer.MouseSource
2018-04-20 08:53:01 +02:00
Frederic Junod
2f45d51f9b
Module type for ol.pointer.EventSource
2018-04-20 08:50:39 +02:00
Frederic Junod
a84863528c
Module type for ol.pointer.PointerEvent
2018-04-20 08:47:27 +02:00
Frederic Junod
a43b90056b
Module type for ol.pointer.PointerEventHandler
2018-04-20 08:44:01 +02:00
Frederic Junod
857b946f3e
Module type for ol.events.Event
2018-03-19 14:31:04 +01:00
Andreas Hocevar
95d6251dbb
Get rid of olx.js and typedef.js typedefs for ol
2018-03-08 18:57:24 +01:00
Andreas Hocevar
d818817117
Fix exports and use of constants
2018-03-02 17:26:17 +01:00
Björn Harrtell
6d1e8cb38b
Rework away static members from pointer related classes
2018-02-24 16:24:53 +01:00
Tim Schaub
9cfee0f40b
Named exports from ol/has
2018-02-05 10:42:47 -07:00
Tim Schaub
7e7631c42a
Named exports from ol/events
2018-01-24 10:09:57 -07:00
Frederic Junod
aeee8e67a9
Rename _ol_pointer_MsSource_ to MsSource
2018-01-18 15:50:27 +01:00
Frederic Junod
b39a6f4cae
Rename _ol_pointer_NativeSource_ to NativeSource
2018-01-18 15:50:27 +01:00
Frederic Junod
e7bb9e8484
Rename _ol_pointer_TouchSource_ to TouchSource
2018-01-18 15:50:27 +01:00
Frederic Junod
107362b9fb
Rename _ol_pointer_MouseSource_ to MouseSource
2018-01-18 15:50:27 +01:00
Frederic Junod
d97151b825
Rename _ol_pointer_EventSource_ to EventSource
2018-01-18 15:50:27 +01:00
Tim Schaub
ad62739a6e
Use blocked scoped variables
...
In addition to using const and let, this also upgrades our linter config and removes lint (mostly whitespace).
2018-01-12 00:50:30 -07:00
Tim Schaub
8cba211ecd
Rename _ol_pointer_PointerEvent_ to PointerEvent
2018-01-11 13:44:45 -07:00
Tim Schaub
8a74d6b8db
Rename _ol_pointer_PointerEventHandler_ to PointerEventHandler
2018-01-11 12:06:59 -07:00
Marc Jansen
8ef8f59cd9
Merge pull request #7636 from marcjansen/named-exports-array
...
Named exports from the ol/array module
2017-12-19 22:32:14 +01:00