-
-
Notifications
You must be signed in to change notification settings - Fork 356
[Map][Docs] Improve "Interact with the map" section #2638
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
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
A great contribution! Hugo, thanks a lot for taking care of the docs.
I made some minor comments about grammar, minor rewords, etc.
src/Map/doc/index.rst
Outdated
Advanced: Passing extra data from PHP to the Stimulus controller | ||
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ | ||
|
||
For higher customization and extensibility, you can also pass extra data from PHP to the Stimulus controller. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
For greater customization and extensibility, you can pass additional data from PHP
to the Stimulus controller. This can be useful when associating extra information
with a specific marker; for example, indicating the type of location it represents.
src/Map/doc/index.rst
Outdated
For higher customization and extensibility, you can also pass extra data from PHP to the Stimulus controller. | ||
It may be useful to pass data for a specific marker, e.g. the type of place it represents. | ||
|
||
Those extra data are only defined and used by you, UX Map only passes them to the Stimulus controller. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
These additional data points are defined and used exclusively by you; UX Map
only forwards them to the Stimulus controller.
src/Map/doc/index.rst
Outdated
], | ||
)); | ||
|
||
JavaScript side, you can access your extra data through the ``event.detail.definition.extra`` object |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
On the JavaScript side, you can access your extra data via the
``event.detail.definition.extra`` object, available in the
``ux:map:*:before-create`` and ``ux:map:*:after-create`` events:
Thanks @javiereguiluz, your reviews are always appreciated! |
After some public and private interactions on Slack, I think it's time to correctly document
rawOptions
andextra
features.In bonus, I rewrote and moved some sections in order to be more understandable and logic.