With all the smoothness of Discourse, I’m surprised this doesn’t already exist (it exists in Wordpress - you know, that ugl…wonderfully coded thing).
I many times link to existing topics on our Discourse installation, and I have to navigate to it, copy the link to clipboard, come to the new post and paste it. When pressing the Hyperlink button, could we have an inline search like we have with the “Tags” box for titles? Start typing a few letters and get a list of matching topics that we can just select? That would be awesome and helpful.
This has been discussed many times. You should be able to find the discussion with a search. I think it’s just that it’s harder than it seems. You can navigate to the topic while you are composing and even quote from it, so you don’t have to navigate back.
I for one am a now a big fan of the secret shortcut. Now if only it could also search the github repo so that I could quickly link to INSTALL_cloud. Maybe CTRL-ALT-SUPER-F could search that too.
Actually, what would be cool and pretty easy here is that replace-a-word theme that would re-write INSTALL-cloud (and something for the EMAIL-cloud or whatever that is) as a link to the install document. Several hundred times a week, I have to track down that link.
I think a transparent inline search with suggestions like the Tags box (with a longer delay after last keypress, if we’re worried about traffic/cpu) is much better than a secret shortcut. Anyone else? Is there a chance it will get implemented?
I was initially suggesting that it could be first implemented for the “Insert hyperlink” button. Click/tap that, start typing in the box and get auto-completion … why hasn’t that been a thing for Discourse when it has been for ages for Shartpress? You don’t need any triggers there and should be easy to get going (famous last words?).
That would be a great start, and better than the current option.
Right but that changes the semantics of “Insert Link” considerably. It becomes "Insert Link… to this forum!"
It’s not a bad idea, I do like that it puts the functionality into an existing dialog, but it would be … weird. I am linking to the outside web way more than I am linking internally to meta, for example.
You’re not forced to insert any of the suggested entries. In my first post I was pointing to the fact that you guys literally implemented exactly that for the "Optional tags +" box in the “Edit title” (where you can create a new tag if none of the matching ones that it suggests in the dropdown as you type are appealing). You could do the same for the Insert hyperlink box:
click “Insert hyperlink”
start typing
open underneath a dropdown list of matching existing topics
continue typing and ignore dropdown if not interested
The Wordpress functionality really works quite well in this regard. You don’t have to choose between internal and external, nor does it assume one or the other.
If you’re inserting an external link, you’re generally not going to be typing it, but pasting it. If a link gets pasted in, don’t bother to search. If words start getting typed, run a live search for suggestions.
Not sure it would need to prevent one-boxing either. Presumably it already puts the whole link in if they don’t add the optional title. Isn’t that how a one-box is created anyway?