Skip to content
This repository has been archived by the owner on Aug 26, 2022. It is now read-only.

Bugfix in tag creations in the Russian language #5027

Closed
wants to merge 2 commits into from

Conversation

A-Mikhail
Copy link

@A-Mikhail A-Mikhail commented Oct 7, 2018

In Russian keyboard layout letter "б" work as a comma, that in the library used to separate tags between each other as well as tab and enter.

The bug prevents writing any words containing this letter.

In Russian keyboard layout letter "б" work as a comma, which prevents to write any word containing the letter
@A-Mikhail A-Mikhail changed the title Fixed error with Russian letter "б" Bugfix in tag creations in the Russian language Oct 7, 2018
@jwhitlock
Copy link
Contributor

@A-Mikhail Thanks for tackling bug 1298017.

Unfortunately, this PR is a bit of a mess. It looks like your last commit did a global search and replace for "let" to "var", changing variable declarations but also "deleted" to "devared" and "autocomplete" to "autocompvare", which probably breaks it.

Our copy of tag-it.js was added in dc657b5, from the version at aehlke/tag-it@f5fe54e. The tag-it maintainers continued making changes, but didn't bump the version number (this was a few changes after v2.0 was tagged).

This PR resembles the latest code from https://github.com/aehlke/tag-it, but not quite, and with a patch similar to aehlke/tag-it#251 applied. It would be clearer if this was explicit in the commits, breaking the change into a few commits:

  1. A commit from the current version in Kuma to the latest in aehlke/tag-it. It would be nice to identify the current tag-it commit in the comments, since the upstream project does a poor job of bumping version numbers.
  2. A commit fixing any linting errors, to make it clear where we're deviating from upstream.
  3. A commit bringing back changes from 6280ffb#diff-40e89d0482b1bd7797dd5f7ceecd748f and de10cdb#diff-40e89d0482b1bd7797dd5f7ceecd748f, if needed, or adjusted to work with new tag-it.js features.
  4. A commit fixing the issue with "б"/"," , which probably requires switching from a keyDown to keyPress handler.

I wonder if there is a more recent, maintained library that would be better for entering tags (I couldn't see a good one linked from the django-taggit docs, or if the goal of "pretty" tags is a bad one, and we should just have a plain, comma-delimited text field.

@jwhitlock
Copy link
Contributor

There's still a lot of work to make this PR mergable. Let's revisit after some sidebar work in Q1 2019 - I suspect tags will be a bit different after that project.

@jwhitlock jwhitlock closed this Jan 7, 2019
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants