Commit Graph

76 Commits

Author SHA1 Message Date
Tim Schaub
85ef563ba8 Remove PluggableMap 2022-07-31 10:08:13 -06:00
Maximilian Krög
c90c4c84c5 Remove MousePosition's deprecated undefinedHTML option
Simplify the placeholder option to only accept strings or undefined.
2022-07-31 02:23:35 +02:00
EvertEt
15de4bb5ab Improve some nullable map types
Closes #13326
2022-02-04 17:05:52 +01:00
Simon Seyock
ce4f6ccb0d OnSignatures return more specific type 2021-09-10 16:11:38 +02:00
Tim Schaub
c0bfcfb7ba Move description above type tag 2021-09-05 11:29:15 -06:00
Tim Schaub
53156ab936 Add a new placeholder option and deprecate undefinedHTML 2021-07-10 09:12:31 -06:00
Andreas Hocevar
e9e664f3c9 Add typed signature for Observable#un() 2021-07-10 11:28:50 +02:00
Simon Seyock
d914006d51 Add signatures for once. 2021-07-10 11:28:49 +02:00
Simon Seyock
1870a64984 Add CombinedOnSignature. 2021-07-10 11:28:49 +02:00
Simon Seyock
e9a161740a controls and interactions. 2021-07-10 11:28:48 +02:00
Simon Seyock
c8f43050c4 Revert "Merge pull request #12416 from ahocevar/eventtype-generics"
This reverts commit b6c143deb2, reversing
changes made to 7777821df5.
2021-07-10 11:28:46 +02:00
Jakob Miksch
bfe5afe069 MousePosition: allow rendering of empty string 2021-07-08 20:54:45 +02:00
Andreas Hocevar
79f5f46d27 Remove lint 2021-06-28 18:10:51 +02:00
Andreas Hocevar
b6c143deb2 Merge pull request #12416 from ahocevar/eventtype-generics
Use generics to limit event types in on(), once() and un()
2021-06-21 09:36:25 +02:00
Andreas Hocevar
018ad97f25 Use generics to limit event types in on(), once() and un() 2021-06-20 22:25:47 +02:00
Andreas Hocevar
343e0ffce9 Replace getChangeEventType() with add/removeChangeListener methods 2021-06-19 23:16:26 +02:00
Simon Seyock
8facb252f1 Replace google closure syntax = with brackets around name 2021-02-03 14:06:02 +01:00
Andreas Hocevar
886ca26c6a Remove elm-pep dependency 2020-06-11 13:11:28 +02:00
Tim Schaub
bfee5c00c9 Update function return types 2020-05-18 17:11:13 -06:00
Andreas Hocevar
e5167f4e12 Fix custom controls with user-provided element 2020-05-15 17:50:44 +02:00
Andreas Hocevar
c6341bbcd9 Fix types for events 2020-05-10 18:19:45 +02:00
Andreas Hocevar
7f6258dd0d Set pointerEvents style programmatically instead of relying on ol.css 2020-04-16 17:34:40 +02:00
Andreas Hocevar
f4d64700ef Fix private scope type issues in controls 2020-04-15 10:53:24 +02:00
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
Frederic Junod
706dd3c87c Remove all inheritDoc tags from src/ol/control 2020-04-03 07:52:51 +02:00
Andreas Hocevar
f8f7f83be7 Do not expose static render function of controls 2020-01-29 20:21:08 +01:00
Andreas Hocevar
569deddd06 Use elm-pep instead of PEP as pointer events polyfill 2019-11-20 07:59:32 +01:00
Frederic Junod
f67476dd8f Mark properties as nullable 2019-09-27 13:57:59 +02:00
Tobias Kohr
b1196e7601 fix linting 2019-09-24 17:58:56 +02:00
Tobias Kohr
686c185de3 Call internal method in MousePosition 2019-09-24 17:58:56 +02:00
Tobias Kohr
d4c1589a01 Seperate internal and API methods for the map 2019-09-24 17:58:56 +02:00
ahocevar
9366dee233 Use fixed fork of pepjs 2019-09-04 21:37:38 +02:00
ahocevar
ebfb20440a Simplify events and store listeners only in one place 2019-09-04 16:48:43 +02:00
ahocevar
d416866108 Use pointer events everywhere 2019-08-31 23:40:11 +02:00
Frederic Junod
2d2f4eb1a2 Remove unused variable in MousePosition control
`this.lastMouseMovePixel_` value is never read.
2019-07-26 14:54:14 +02:00
Frederic Junod
9ab201642c Simplify import path in ol/control/ 2018-11-05 16:26:45 +01:00
Frederic Junod
3746ba99cf Change target type from Element to HTMLElement
Same as the parent class type for `MousePosition` and the type returned by the
`getViewport` function.
2018-10-23 09:17:17 +02:00
Frederic Junod
94fd57f690 Set projection property in MousePosition option optional 2018-10-17 10:56:11 +02:00
ahocevar
3c500e0b4b Sensible touch behavior of the MousePosition control 2018-09-08 11:10:56 +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
Frederic Junod
8fdc4cc9fc Change property test in MousePosition options
TypeScript doesn't like the current implementation:
```
src/ol/control/MousePosition.js(82,64): error TS2339: Property 'undefinedHTML' does not exist on type 'never'.
```
2018-09-03 15:25:33 +02:00
Matthias Schiffer
94c6afd65d Avoid HTML entities like   and ©
Use numerical entities instead for XHTML compatiblity.
2018-08-18 13:13:27 +02:00
Matthias Schiffer
321166849b Consistently use lowercase HTML tag names
Unlike HTML, XHTML is case-sensitive.
2018-08-18 12:48:14 +02:00
Tim Schaub
e5493d1288 Add ol/pixel module for Pixel type 2018-07-19 10:17:00 -06:00
Frederic Junod
f140ff368d Move jsdoc constructor comments for controls 2018-07-17 16:44:53 +02:00
ahocevar
353a00af89 Use extends and super for control/MousePosition 2018-07-17 14:41:26 +02:00
Tim Schaub
7b4a73f3b9 Automated class transform
npx lebab --replace src --transform class
2018-07-16 16:18:16 -06:00
ahocevar
28409486a5 Make classes in ol/ available as named exports from ol 2018-06-21 18:08:17 +02:00
ahocevar
440d1ad3e1 Shorter module paths for default exports 2018-04-25 17:25:39 +02:00