Redirect when clicking on edit for a macro

Hi! I’m creating a macro similar to draw.io and I would like to redirect to a separate page where we can actually edit a diagram when clicking on the pen/edit button.
Currently all I found in the documentation is a way to reveal a panel with some properties that we can use in the macro, but nothing to redirect to an actual page. (Add configuration to a macro)
I guess, this involves the router, but no idea how to use that with a configuration (as it seems we need to use a configuration option to be able to edit the macro…)

1 Like

Hi @GildasOlympio,

Are you using UI Kit or Custom UI?

Unfortunately, this cannot be done in the edit button.
Please try to create a button inside your app to achieve the redirect functionality.

If you’re using a Custom UI app, you can use Router to navigate to another URL.
See: https://developer.atlassian.com/platform/forge/custom-ui-bridge/router/

Hi @DganitZuriel Sorry for the super late reply. Thanks for your response.
I am using Custom UI, but I was wondering how did draw io manage to achieve this? Using the edit button (standard pen button) they are achieving a redirect to their own page. Maybe is there a trick to make this happen as a two step process or something like that?
Thanks again