-
-
Notifications
You must be signed in to change notification settings - Fork 5.6k
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
Pasted images have wrong repo-based URL #15550
Comments
Possible regression from #15088. |
I think we need to either generate absolute URLs (like github) or add something else on the produced link that marks it as an server attachment instead of a repo-relative file. Absolute URLs of course won't be portable. |
how about |
Don't think we can distinguish based on leading characters, GitHub does support all three variants in repo files but notable does not support repo-relative images in issue comments at all. https://github.com/silverwind/gitea/blob/e71060b08986d747c57cb07cee9dfc53593579a8/test.md Test code:
|
I guess what we could do is check for those |
Or we can add a new route |
I'd be fine with a |
Use a uuid rather than id is better. |
Before the upgrade [Normal preview] after upgrade [Unable to preview] The pictures of my whole issue can no longer be viewed. 😭 |
this is great, just today I went ahead and hotfixed this on my proxy (nginx string rewrites), now I don't need it anymore. |
1.15.0+dev-165-g5e85cdad2
Description
Pasting an image results in it being linked on the wrong URL:
But it should be
Markdown and HTML:
Image attachments via dropzone are not affected, see comment below.
The text was updated successfully, but these errors were encountered: