-
Notifications
You must be signed in to change notification settings - Fork 291
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
Autocompletion in the 'search by tag' field? #49
Comments
In my opinion, the 'search by tag' field is useless, and not worth readding jQuery + jQueryUI on every pages :
I believe in earlier versions you couldn't search tags through the regular search field, and that's why it exists. Anyway, it's a wontfix for me. |
I for one often use the "search by tag" field because:
So while it's not high priority, I see 4 possible solutions
|
Do we just use jQuery for autocompletion? If so, your solution is probably the best thing to do, yes. |
@ArthurHoaro It's also used for lazy loading in the picwall. But again, specialized libs exist for that. Eg blazy which is used by MinigalNano by @sebsauvage |
https://github.com/aehlke/tag-it is another autocompletino lib (but still relies on Jquery UI) |
I took a look at it yesterday, and I didn't find a single proper lib which doesn't rely on jQuery (or angular and cie) and supports multiple tags. :( |
What about http://leaverou.github.io/awesomplete/ ? |
@Marsup this is the lib I suggested initially but it appears that it doesn't support autocompletion on multiple words which is something we need. Edit: there might be progress on this, as per the issue comments ;) |
Sorry, didn't notice, it worked on the demo at least :) |
That's really interesting! However, the way this lib works, it means we need to write every tags in the HTML page. I don't think it's a big issue, but it might be important to notice. |
Autocompletion for multiple words is now working at https://leaverou.github.io/awesomplete/#advanced-examples (scroll to "Multiple values"). As I said we still need to find a way to
Edit: this is on a good way so I suggest closing Pull Request #118 if @ArthurHoaro or someone else is able to put up something that uses this lib. Sorry for @s1dh but (see discussion at #92 (comment)) I believe the behavior he requests is a nasty edge case, it can be worked around with CTRL+C/CTRL+V, and it may still be implemented later using awesomplete. Having a cleaner, jQuery-less autocomplete is more important in my eyes. |
You're right. I closed my PR. The tag order code can be changed later if it's necessary anyway.
In the example provided, you can use your arrow keys and press Enter. I'd say it's good enough. Also, the autocomplete algorithm is not exactly the same since it also searches inside words (not only starting with). It's even better IMHO. And finally the HTML storage, as I said in my previous comment, which shouldn't be an issue. So, 👍 for awesomplete for me. |
Agreed with everything you said. |
We should keep in mind: Tag suggestions should be case-insenstive to help with #146 (comment) |
Should be easy to fix since the new autocompletion library is now live. |
@ArthurHoaro do you want to take a look at this? Since you are familiar with awesomplete.. |
It's done. :) |
Fixed in 65d6251, thanks. |
Reported at sebsauvage#104. The 'search by tag' field has no autocompletion feature (the 'tags' field in the "Edit link" dialog still has it)
The proposed fix doesn't merge anymore (it relies on an old Shaarli version that still had jQuery on the main page). We may not want to re-add jQuery so another solution would be welcome.
Is this really wanted, or should we mark this as wontfix?
The text was updated successfully, but these errors were encountered: