Skip to content

Commit fa60dee

Browse files
committed
Merge branch 'develop' into update-from-template-merged
2 parents 0f40b18 + 1d47d22 commit fa60dee

File tree

114 files changed

+8721
-35
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

114 files changed

+8721
-35
lines changed

.github/FUNDING.yml

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,2 @@
1+
github: Leaflet
2+
open_collective: leafletjs

.github/ISSUE_TEMPLATE/bug_report.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -14,9 +14,9 @@ body:
1414
attributes:
1515
label: "Checklist"
1616
options:
17-
- label: "I am able to reproduce the bug with the [latest version](https://github.com/xdev-software/template-placeholder/releases/latest)"
17+
- label: "I am able to reproduce the bug with the [latest version](https://github.com/xdev-software/vaadin-maps-leaflet-flow/releases/latest)"
1818
required: true
19-
- label: "I made sure that there are *no existing issues* - [open](https://github.com/xdev-software/template-placeholder/issues) or [closed](https://github.com/xdev-software/template-placeholder/issues?q=is%3Aissue+is%3Aclosed) - which I could contribute my information to."
19+
- label: "I made sure that there are *no existing issues* - [open](https://github.com/xdev-software/vaadin-maps-leaflet-flow/issues) or [closed](https://github.com/xdev-software/vaadin-maps-leaflet-flow/issues?q=is%3Aissue+is%3Aclosed) - which I could contribute my information to."
2020
required: true
2121
- label: "I have taken the time to fill in all the required details. I understand that the bug report will be dismissed otherwise."
2222
required: true

.github/ISSUE_TEMPLATE/enhancement.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,7 @@ body:
1212
attributes:
1313
label: "Checklist"
1414
options:
15-
- label: "I made sure that there are *no existing issues* - [open](https://github.com/xdev-software/template-placeholder/issues) or [closed](https://github.com/xdev-software/template-placeholder/issues?q=is%3Aissue+is%3Aclosed) - which I could contribute my information to."
15+
- label: "I made sure that there are *no existing issues* - [open](https://github.com/xdev-software/vaadin-maps-leaflet-flow/issues) or [closed](https://github.com/xdev-software/vaadin-maps-leaflet-flow/issues?q=is%3Aissue+is%3Aclosed) - which I could contribute my information to."
1616
required: true
1717
- label: "I have taken the time to fill in all the required details. I understand that the feature request will be dismissed otherwise."
1818
required: true

.github/ISSUE_TEMPLATE/question.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,7 @@ body:
1212
attributes:
1313
label: "Checklist"
1414
options:
15-
- label: "I made sure that there are *no existing issues* - [open](https://github.com/xdev-software/template-placeholder/issues) or [closed](https://github.com/xdev-software/template-placeholder/issues?q=is%3Aissue+is%3Aclosed) - which I could contribute my information to."
15+
- label: "I made sure that there are *no existing issues* - [open](https://github.com/xdev-software/vaadin-maps-leaflet-flow/issues) or [closed](https://github.com/xdev-software/vaadin-maps-leaflet-flow/issues?q=is%3Aissue+is%3Aclosed) - which I could contribute my information to."
1616
required: true
1717
- label: "I have taken the time to fill in all the required details. I understand that the question will be dismissed otherwise."
1818
required: true

.github/workflows/no-response.yml

Lines changed: 26 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,26 @@
1+
name: No Response
2+
3+
on:
4+
workflow_dispatch:
5+
issue_comment:
6+
types: [created]
7+
schedule:
8+
- cron: '5 5 * * *'
9+
10+
jobs:
11+
noResponse:
12+
runs-on: ubuntu-latest
13+
permissions:
14+
issues: write
15+
steps:
16+
- uses: actions/stale@v9
17+
with:
18+
days-before-issue-stale: 7
19+
days-before-issue-close: 3
20+
stale-issue-label: "stale"
21+
only-labels: "waiting-for-response"
22+
labels-to-remove-when-unstale: "waiting-for-response"
23+
stale-issue-message: "This issue will be closed soon because there has been no further activity."
24+
days-before-pr-stale: -1
25+
days-before-pr-close: -1
26+
repo-token: ${{ secrets.GITHUB_TOKEN }}

.run/Run Demo.run.xml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
<component name="ProjectRunConfigurationManager">
22
<configuration default="false" name="Run Demo" type="Application" factoryName="Application">
33
<option name="MAIN_CLASS_NAME" value="software.xdev.vaadin.Application" />
4-
<module name="template-placeholder-demo" />
4+
<module name="vaadin-maps-leaflet-flow-demo" />
55
<option name="WORKING_DIRECTORY" value="$MODULE_DIR$" />
66
<extension name="coverage">
77
<pattern>

CHANGELOG.md

Lines changed: 88 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,88 @@
1+
## 4.2.2
2+
* Deduplicated ``tLMapZoomPanOptions``
3+
4+
## 4.2.1
5+
* Handle ``LEvented#off`` in the same way as ``LEvented#on``
6+
* Fix incorrect formatting leading to JS error
7+
* Updated dependencies
8+
9+
## 4.2.0
10+
* Fixed some invalid built JavaScript commands #330
11+
* Add basic support for CRS #333
12+
* Added a few new showcase demos
13+
* Updated dependencies
14+
15+
## 4.1.1
16+
* ⚠️ GroupId changed from ``com.xdev-software`` to ``software.xdev``
17+
* Updated dependencies
18+
19+
## 4.1.0
20+
* Provide a workaround that fixes a problem where certain methods didn't work instantly after the map was created #305
21+
* Moved some container specific methods to ``MapContainer``
22+
23+
## 4.0.1
24+
* Added shortcut method ``invokeSelfReturn`` #282
25+
* Updated dependencies
26+
27+
## 4.0.0
28+
⚠️<i>This release contains breaking changes</i>
29+
30+
* The complete API got reworked and now has the [same structure as Leaflet](https://leafletjs.com/reference.html).
31+
* Added lots of new Leaflet APIs - currently around 90% of the Leaflet API are implemented. These include the most useful bits:
32+
* GeoLocation
33+
* A lot of new methods for Map
34+
* Tooltips & Popups
35+
* Image, Video and SVG-Overlays
36+
* Rectangles
37+
* Controls for Scale, Layers, ...
38+
* and much more
39+
* Abstracted the elements similar to how this is done inside Leaflet itself so that they can easily be extended
40+
* The API only supports sending instructions to the client. Retrieving client side data is not supported as data integrity can't be guaranteed (client-side data can be modified by users).
41+
* Event listeners can still be registered but this needs to be done manually. A example is available in the demo.
42+
* All Leaflet elements are now tracked on the client and on the server and can therefore be modified/reused (using ``LComponentManagementRegistry``).
43+
* Before it was only possible to create an element and then send it to the client
44+
* However keep in mind when creating a lot of elements that you may have to free up memory on the client (manually)
45+
* Integrated default Leaflet resources
46+
47+
## 3.0.2
48+
* Added support for Polyline #266 (thanks to @blitzdose)
49+
50+
## 3.0.1
51+
* Fixed ``divIcon`` being displayed incorrectly [due to a default ``iconSize`` of ``12px``](https://github.com/Leaflet/Leaflet/issues/4238) #246
52+
* Updated dependencies
53+
* Updated leaflet to [``1.9.4``](https://github.com/Leaflet/Leaflet/blob/b6b56f6e707142c177fad2f67827a5007e56736a/CHANGELOG.md#194-2023-05-18) #247
54+
55+
## 3.0.0
56+
⚠️<i>This release contains breaking changes</i>
57+
58+
* Adds support for Vaadin 24+, drops support for Vaadin 23<br/>
59+
<i>If you are still using Vaadin 23, use the ``2.x`` versions.</i>
60+
* Requires Java 17+
61+
62+
## 2.0.4
63+
* Added method ``centerAndZoom`` in ``LMap``
64+
* Fixed a problem where an invalid ``iconSize`` was transferred to leaflet which caused a client side exception (#199)
65+
* Updated various dependencies
66+
67+
## 2.0.3
68+
* Updated dependencies
69+
* Fixed problem with setting lon/lan in LMarker
70+
* Added constructors for LMap
71+
72+
## 2.0.2
73+
* Updated dependencies
74+
75+
## 2.0.1
76+
* Updated dependencies
77+
* Vaadin 23.2
78+
79+
## 2.0.0
80+
⚠️<i>This release contains breaking changes</i>
81+
82+
* Update to Vaadin 23
83+
* Removed deprecated polymer-connector - replaced by ``executeJs``
84+
* Fixed a problem where the map was not rendered/aligned correctly
85+
* Don't load anything from remote servers that are not under control of the user
86+
* Shrunk the jar
87+
* Removed default leafletmap tile layer; has to be set manually due to usage policy
88+
* Updated dependency versions

CONTRIBUTING.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -47,10 +47,10 @@ Bigger changes may require a complete restart.
4747
* [Vaadin automatically reloads the UI on each restart](https://vaadin.com/docs/latest/configuration/live-reload/spring-boot).<br/>
4848
You can control this behavior with the ``vaadin.devmode.liveReload.enabled`` property (default: ``true``).
4949

50-
## Releasing [![Build](https://img.shields.io/github/actions/workflow/status/xdev-software/template-placeholder/release.yml?branch=master)](https://github.com/xdev-software/template-placeholder/actions/workflows/release.yml)
50+
## Releasing [![Build](https://img.shields.io/github/actions/workflow/status/xdev-software/vaadin-maps-leaflet-flow/release.yml?branch=master)](https://github.com/xdev-software/vaadin-maps-leaflet-flow/actions/workflows/release.yml)
5151

5252
Before releasing:
53-
* Consider doing a [test-deployment](https://github.com/xdev-software/template-placeholder/actions/workflows/test-deploy.yml?query=branch%3Adevelop) before actually releasing.
53+
* Consider doing a [test-deployment](https://github.com/xdev-software/vaadin-maps-leaflet-flow/actions/workflows/test-deploy.yml?query=branch%3Adevelop) before actually releasing.
5454
* Check the [changelog](CHANGELOG.md)
5555

5656
If the ``develop`` is ready for release, create a pull request to the ``master``-Branch and merge the changes

README.md

Lines changed: 24 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -1,21 +1,36 @@
1-
[![Published on Vaadin Directory](https://img.shields.io/badge/Vaadin%20Directory-published-00b4f0?logo=vaadin)](https://vaadin.com/directory/component/template-placeholder)
2-
[![Latest version](https://img.shields.io/maven-central/v/software.xdev/template-placeholder?logo=apache%20maven)](https://mvnrepository.com/artifact/software.xdev/template-placeholder)
3-
[![Build](https://img.shields.io/github/actions/workflow/status/xdev-software/template-placeholder/check-build.yml?branch=develop)](https://github.com/xdev-software/template-placeholder/actions/workflows/check-build.yml?query=branch%3Adevelop)
4-
[![Quality Gate Status](https://sonarcloud.io/api/project_badges/measure?project=xdev-software_template-placeholder&metric=alert_status)](https://sonarcloud.io/dashboard?id=xdev-software_template-placeholder)
1+
[![Published on Vaadin Directory](https://img.shields.io/badge/Vaadin%20Directory-published-00b4f0?logo=vaadin)](https://vaadin.com/directory/component/leafletmap-for-vaadin)
2+
[![Latest version](https://img.shields.io/maven-central/v/software.xdev/vaadin-maps-leaflet-flow?logo=apache%20maven)](https://mvnrepository.com/artifact/software.xdev/vaadin-maps-leaflet-flow)
3+
[![Build](https://img.shields.io/github/actions/workflow/status/xdev-software/vaadin-maps-leaflet-flow/check-build.yml?branch=develop)](https://github.com/xdev-software/vaadin-maps-leaflet-flow/actions/workflows/check-build.yml?query=branch%3Adevelop)
4+
[![Quality Gate Status](https://sonarcloud.io/api/project_badges/measure?project=xdev-software_vaadin-maps-leaflet-flow&metric=alert_status)](https://sonarcloud.io/dashboard?id=xdev-software_vaadin-maps-leaflet-flow)
55
![Vaadin 24+](https://img.shields.io/badge/Vaadin%20Platform/Flow-24+-00b4f0)
66

7-
# template-placeholder
8-
A Vaadin Template Repo
7+
# vaadin-maps-leaflet-flow
8+
A Vaadin Flow Java API for [Leaflet](https://leafletjs.com/)
99

1010
![demo](assets/demo.png)
1111

12+
## Usage
13+
14+
This API wraps the Leaflet API in a Vaadin friendly way.<br/>It uses a similar structure (classes, methods) as the [Leaflet JavaScript API](https://leafletjs.com/reference.html).
15+
16+
To get started it's recommended to have a look at the [demo](./vaadin-maps-leaflet-flow-demo), notably the [minimalistic example](./vaadin-maps-leaflet-flow-demo/src/main/java/software/xdev/vaadin/maps/leaflet/flow/demo/MinimalisticDemo.java).
17+
18+
> [!NOTE]
19+
> **The API only supports sending instructions to the client**<br/>
20+
> Due to data integrity retrieving client-side data (that can be modified by users) is not supported.
21+
> * Event listeners can still be registered but this needs to be done manually.<br/>[An example is available in the demo](https://github.com/xdev-software/vaadin-maps-leaflet-flow/blob/5a008511935105ea977187112cd0053c7de33e19/vaadin-maps-leaflet-flow-demo/src/main/java/software/xdev/vaadin/maps/leaflet/flow/demo/ComplexDemo.java#L223).
1222
1323
## Installation
14-
[Installation guide for the latest release](https://github.com/xdev-software/template-placeholder/releases/latest#Installation)
24+
[Installation guide of the latest release](https://github.com/xdev-software/vaadin-maps-leaflet-flow/releases/latest#Installation)
25+
26+
#### Compatibility with Vaadin
27+
| Vaadin version | vaadin-maps-leaflet-flow version |
28+
| --- | --- |
29+
| Vaadin 24+ (latest) | ``3+`` |
1530

1631
## Run the Demo
1732
* Checkout the repo
18-
* Run ``mvn install && mvn -f template-placeholder-demo spring-boot:run``
33+
* Run ``mvn install && mvn -f vaadin-maps-leaflet-flow-demo spring-boot:run``
1934
* Open http://localhost:8080
2035

2136
<details>
@@ -31,4 +46,4 @@ If you need support as soon as possible and you can't wait for any pull request,
3146
See the [contributing guide](./CONTRIBUTING.md) for detailed instructions on how to get started with our project.
3247

3348
## Dependencies and Licenses
34-
View the [license of the current project](LICENSE) or the [summary including all dependencies](https://xdev-software.github.io/template-placeholder/dependencies)
49+
View the [license of the current project](LICENSE) or the [summary including all dependencies](https://xdev-software.github.io/vaadin-maps-leaflet-flow/dependencies)

SECURITY.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,4 +2,4 @@
22

33
## Reporting a Vulnerability
44

5-
Please report a security vulnerability [on GitHub Security Advisories](https://github.com/xdev-software/template-placeholder/security/advisories/new).
5+
Please report a security vulnerability [on GitHub Security Advisories](https://github.com/xdev-software/vaadin-maps-leaflet-flow/security/advisories/new).

0 commit comments

Comments
 (0)