-
Notifications
You must be signed in to change notification settings - Fork 14
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
Hash link does not work #5
Comments
@jonnitto We cannot reproduce this. Can you provide more informations |
Ahh now i got it ... you can workaround that by linking the current document with an anchor. Not exactly the same but close enough for now i assume. |
For me yes, for a customer not… |
We have the same issue here. We have some urls to pdf documents prepended with a hash. For example sth. like this: |
For the issue pointed out by @jonnitto, i think this can simply be prevented by adding some checks before allowing the customer to save the link:
|
but this is a matter of definition:
But this is rather a super edgecasy thing ... About johns problem: Currently its not anticipated that the host is empty but the anchor is set. Instead of treating the href (protocol + host + path + anchor) as one unit, we allow the anchor to be specified as additional options. But this requires the protocol and host to be present. |
It maybe is, but it is not disallowed to use anchors in assets and as you see above, there are valid cases where you might need them. Example link: TransnetBW Nachhaltigkeitsbericht (Seite 6) And as it might brake the editor if you switch from the "old" editor, i'd rather prefer adding it then having a bad editor experience, where a developer is needed to fix the link. |
Could this be solved using a custom link? #27 |
The problem in our case is, that the Backend-Domain is different from the Frontend-Domain. Therefore we can't simply set a custom link, as we need to set the domain there and on the live-domain that target may not exist yet. And: When switching from the "old" editor, i'd expect such links to still work and not show an error. To solve the problem @jonnitto has, an editor should at least be able to add relative links. Then it should be possible to create links like |
@Benjamin-K I see, now I get it. In the core LinkEditor, it is possible to add a hash to the This also means that the package wouldn't work with https://github.com/flownative/neos-anchorlinks. To me, the most beautiful solution would be the ability to select any content node inside a selected page as link target. However, since Neos doesn't define the frontend output, this would only work if the So maybe a configurable (disabled by default) separate "anchor" field (or "link parameter") would be a good solution? |
@lorenzulrich Sry, you were right. The |
@Benjamin-K I agree that this should be addressed if this package should go into the core - especially if it will work as drop-in replacement. But I think @mficzel would need to agree with a solution to the problem since it is Sitegeist's package. |
I think the custom link as defined here #27 is a good solution. Having yet another extra tab "Anchor" or similar will confuse as many editors as it will help. |
@mficzel I totally agree, that we should not add another new link editor to this package. The CustomLink solves the original issue described here. But the edge cases mentioned by @mhsdesign are still valid and will break the backend for some users in some places, of they use node or asset links with a hash in the sidebar. So yes, no new tab please! But this editor should keep links working that worked in the old editor. |
@mficzel As you can see in my screenshot, it would not be an extra tab, but an extra property in the existing tag. This is just a suggestion. But maybe @Benjamin-K and we should open a new issue for this. |
There is also a new package in the wild: https://github.com/PaesslerAG/Paessler.Anchorlink I think it would be nice to make Archaeopteryx extendable with own packages… |
@lorenzulrich @mficzel I have created a new issue #59 for the sub-problem mentioned here about existing links and a breaking editor, and a fix #60 |
If you have an link with an hash (e.g.
#newsletter
) the editor returns following error:And if I try to click
+ Create Link
I got the error:The text was updated successfully, but these errors were encountered: