Skip to content

[Map] Deprecate property rawOptions from ux:map:*:before-create events, in favor of bridgeOptions #2860

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 1 commit into from
Jun 22, 2025

Conversation

Kocal
Copy link
Member

@Kocal Kocal commented Jun 22, 2025

Q A
Bug fix? no
New feature? yes
Docs? yes
Issues Fix #...
License MIT

Following #2859, the rawOptions does not really reflect its purpose, I find bridgeOptions much better.

With the follwing code:

		this.element.addEventListener("ux:map:marker:before-create", (event) => {
			event.detail.definition.rawOptions = { opacity: 0.5};
			event.detail.definition.bridgeOptions = { title: 'Paris!!'};
		});

Both options are used, but a deprecation warning is nicely trigged:
image

@carsonbot carsonbot added Feature New Feature Map Status: Needs Review Needs to be reviewed labels Jun 22, 2025
Copy link
Contributor

github-actions bot commented Jun 22, 2025

📊 Packages dist files size difference

Thanks for the PR! Here is the difference in size of the packages dist files between the base branch and the PR.
Please review the changes and make sure they are expected.

FileBefore (Size / Gzip)After (Size / Gzip)
Map
abstract_map_controller.d.ts 6.9 kB / 1.35 kB 7.2 kB+4% 📈 / 1.37 kB+2% 📈
abstract_map_controller.js 5.01 kB / 1.2 kB 5.31 kB+6% 📈 / 1.35 kB+12% 📈
Map (Bridge Google)
map_controller.js 13.46 kB / 2.87 kB 14 kB+4% 📈 / 3 kB+5% 📈
Map (Bridge Leaflet)
map_controller.d.ts 2.91 kB / 831 B 2.94 kB+1% 📈 / 844 B+2% 📈
map_controller.js 12.18 kB / 2.92 kB 13.15 kB+8% 📈 / 3.18 kB+9% 📈

Comment on lines -3 to -13
## 2.29

- Add support for creating `Rectangle` by passing two `Point` instances to the `Rectangle` constructor, e.g.:
```php
$map->addRectangle(new Rectangle(
southWest: new Point(48.856613, 2.352222), // Paris
northEast: new Point(48.51238 2.21080) // Gare de Lyon (Paris)
));
```
## 2.27

## 2.28
Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The changelog was wrong... 😅 cc @Valmonzo

@Kocal Kocal force-pushed the map-deprecate-raw-options branch from 9e788bf to 9158b93 Compare June 22, 2025 22:17
@Kocal Kocal merged commit 523c591 into symfony:2.x Jun 22, 2025
23 checks passed
@Kocal Kocal deleted the map-deprecate-raw-options branch June 22, 2025 22:23
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Feature New Feature Map Status: Needs Review Needs to be reviewed
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants