Skip to content
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

ObjectBrowserWidget is too smart with internal links #4017

Open
erral opened this issue Dec 2, 2022 · 2 comments
Open

ObjectBrowserWidget is too smart with internal links #4017

erral opened this issue Dec 2, 2022 · 2 comments

Comments

@erral
Copy link
Member

erral commented Dec 2, 2022

Is your feature request related to a problem? Please describe.

When using a object_browser widget in a block with allow_externals = true to allow entering either external or internal links, the widgets tries to be very smart and if you enter a link to a internal object as a full url, it parses it and converts it to a internal object.

So far so good.

But if you try to enter a internal link with parameters (say you want to enter a link to a page with a search block with given filters selected), the widget converts that link to a internal link to the page where the search block is, and removes all parameters from the request, thus invalidating the link the end user entered.

Describe the solution you'd like
I would like a dumb widget that leaves the link as it is if I enter it, no matter is internal or external. I have the option to browse through the portal if I want to add an internal link, so this should not affect the widget's functionality.

Additional context
I have been fighting this even in Classic UI with TinyMCE with little or no success

Opinions? @gorkafernandez @ionlizarazu @UnaiEtxaburu

@tiberiuichim
Copy link
Contributor

I think the easiest fix is for the object widget to keep the query part, even after converting to internal url.

@erral
Copy link
Member Author

erral commented Dec 4, 2022

I still need to test what happens if I enter a link yo a non-content-route. Will the object widget convert it yo something else?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants