forked from xwiki-contrib/application-diagram
-
Notifications
You must be signed in to change notification settings - Fork 8
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
Downloading SVG makes links non functional #319
Labels
Comments
Farcasut
added a commit
to Farcasut/application-diagram-fork
that referenced
this issue
Dec 5, 2024
*This issue appears to be more nuanced because there are multiple ways to add links to a page, and there are different types of links. You can add a link directly by selecting the plus button, choosing either "internal" or "external," and adding it or by highlighting text and inserting the link. Regarding the types of links there are three categories: Custom: These are internal links within XWiki. External (prefixed): These links are prefixed with https://domain and work correctly, redirecting to the external site. External (non-prefixed): These links lack an https:// prefix. Instead of redirecting to the external site, they redirect to localdomain/externalLink. From my understanding, this behavior is not a bug but the intended design of drawio, as it can be reproduced on https://app.diagrams.net. To solve the issue raised by Gabrila, I can override the updateSvgLinks method in Graph.js and retain the custom links instead of removing them. As for the external non-prefixed links, I am unsure whether I should add the https:// prefix myself or retain drawio's default behavior.
Farcasut
added a commit
to Farcasut/application-diagram-fork
that referenced
this issue
Dec 9, 2024
* Removed debug statements
Issue reproducing on XWiki 15.10.14, Chrome 131, Windows 11 Pro |
Farcasut
added a commit
to Farcasut/application-diagram-fork
that referenced
this issue
Dec 12, 2024
Co-authored-by: Sorin Chiuchiu <[email protected]>
Farcasut
added a commit
that referenced
this issue
Dec 13, 2024
The issue has been fixed, and everything should work as expected starting with version 1.22. To fix older diagrams(created in 1.21-1-rc-1) before exporting, resave them and make sure the cache is deleted |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Seems to be a regression for #130
Steps to reproduce:
Create a new Diagram
Add some shapes
Add a word in each shape
Select the word from one of the shapes
Click on the Link... button below Insert from the right panel
Select a wiki page > Apply

Select another shape/word
Click on the Link... button below Insert from the right panel
Select External and paste an URL eg. https://en.wikipedia.org/wiki/Flower

Click File > Export as > SVG...
Click on Export
Click on Download > Save
Open the SVG
Click on each of the links
Expected results: The links are showing as expected.
Actual results: When clicking on the link to the internal page it gives "javascript:void(0);" and the link to the external url doesn't work at all - it's just like text not a link.
Environment: XWiki 14.10.18 with Diagram version 1.21.1-rc-1, Chrome 131, Windows 11 Pro
The text was updated successfully, but these errors were encountered: