amundsen
amundsen copied to clipboard
fix: Fix links in Announcements
Signed-off-by: Ozan Dogrultan [email protected]
Fixes https://github.com/amundsen-io/amundsen/issues/1875
Summary of Changes
Previously, when there were links in the Announcement html content, they were overridden by the navigation of the Card component and when they were clicked, announcement list page was shown instead of the link itself.
The changes in the PR introduces the logic the stop bubbling up the click event to the Card component so that the link navigation works as expected.
Tests
No test change is needed.
Documentation
No documentation change is needed.
CheckList
Make sure you have checked all steps below to ensure a timely review.
- [x] PR title addresses the issue accurately and concisely. Example: "Updates the version of Flask to v1.0.2"
- In case you are adding a dependency, check if the license complies with the ASF 3rd Party License Policy.
- [x] PR includes a summary of changes.
- [x] PR adds unit tests, updates existing unit tests, OR documents why no test additions or modifications are needed.
- [ ] In case of new functionality, my PR adds documentation that describes how to use it.
- All the public functions and the classes in the PR contain docstrings that explain what it does
cc @Golodhros
@Golodhros could you review this please? 🙏🏼
@Golodhros I've changed the fix strategy slightly with the latest changes. Now the only change is to allow onclick
handlers to be customized in the sanitized announcement content, so stopping event propagation logic can be set if needed by the content which is passed. Can you please review again?