Open ArmchairQuarterback opened 10 years ago
@ArmchairQuarterback By "the link won't work in preview", you mean that [[index は]] isn't a clickable link in a markdown preview window? Or that [[index は]] isn't clickable as a search link in the note editing view?
The first shouldn't work. [[links]] aren't translated by markdown into html.
As for the second, [[index は]] works for me. See attached screenshot.
Apologies for being unclear. I think I see the problem here. I forgot that I have modified the template file to make the wiki links (internal note links) clickable according to the directions given by Brett "Clickable wiki links in the nvALT preview" http://brettterpstra.com/2013/08/25/clickable-wiki-links-in-the-nvalt-preview/
Everything works fine in the note editing view, but for some reason, only this combination of English and Asian characters fails in the preview window. There may be other combinations I have not encountered.
I find having the links clickable in the preview window is a huge improvement to the app, and I hope you'll consider making it part of the standard functionality in the next release -- perhaps in the default template. I guess that, at the moment, I am on my own, though, because this is Brett's hack?
I didn't understand at first either, but if it's an issue in the JS I might be able to find the cause easily. I'll take a look today.
On 19 Aug 2014, at 7:15, ArmchairQuarterback wrote:
Apologies for being unclear. I think I see the problem here. I forgot that I have modified the template file to make the wiki links (internal note links) clickable according to the directions given by Brett "Clickable wiki links in the nvALT preview" http://brettterpstra.com/2013/08/25/clickable-wiki-links-in-the-nvalt-preview/
Everything works fine in the note editing view, but for some reason, only this combination of English and Asian characters fails in the preview window. There may be other combinations I have not encountered.
I find having the links clickable in the preview window is a huge improvement to the app, and I hope you'll consider making it part of the standard functionality in the next release -- perhaps in the default template. I guess that, at the moment, I am on my own, though, because this is Brett's hack?
Reply to this email directly or view it on GitHub: https://github.com/ttscoff/nv/issues/297#issuecomment-52624633
Hm, I'm using the exact script from that post and the example you posted works fine and shows up clickable in the preview. Clicking it creates a new note "index は". Not sure what would be going on there…
OK. I figured it out. Screenshots help, right? I should have started this thread with them.
If the headline (using the single hash tag) contains the word "index" and the link contains the word index, then the link won't work (see the second image). Weird, but true. I haven't tested all possible combinations. This probably explains why I have been using the script for so long but only just now recognized the problem!
And, further testing shows what you probably already suspected. This has nothing to do with Asian characters at all! If the word in the headline matches a word in the link, then the preview link won't work.
I've come across an odd bug in preview (nvALT 2.2b) involving the word "index" and Asian characters. If I have the following text in my note, the link won't work in preview.
[[index は]]
The key, for some reason, seems to be the combination of "index" + space + Asian character. "index" + underbar + Asian character works fine. "indeex" (misspelled) + space + Asian character works fine as well.
Let me know if you need any testing. Here are a couple of characters to cut/paste and try: 英 国