diff options
| author | Henry Jameson <me@hjkos.com> | 2018-09-20 16:12:00 +0300 |
|---|---|---|
| committer | Henry Jameson <me@hjkos.com> | 2018-09-20 16:12:00 +0300 |
| commit | 537b1ff2d8e04d18d65a74b743f31762b8c85079 (patch) | |
| tree | 5cd3721b18a649f005832b5328f404daa897f05b /src/components | |
| parent | 0c14dd95754f465bf571ed4583425c4414590a6f (diff) | |
| parent | 7887e42fca28f16859d2046c0f9085e6f48d77d5 (diff) | |
Merge remote-tracking branch 'upstream/develop' into translations-separation
* upstream/develop:
Update Hebrew translation
fixed autocomplete
Debug
Diffstat (limited to 'src/components')
| -rw-r--r-- | src/components/post_status_form/post_status_form.js | 7 | ||||
| -rw-r--r-- | src/components/who_to_follow_panel/who_to_follow_panel.js | 2 |
2 files changed, 6 insertions, 3 deletions
diff --git a/src/components/post_status_form/post_status_form.js b/src/components/post_status_form/post_status_form.js index d7f1ffb2..7babe236 100644 --- a/src/components/post_status_form/post_status_form.js +++ b/src/components/post_status_form/post_status_form.js @@ -75,8 +75,11 @@ const PostStatusForm = { candidates () { const firstchar = this.textAtCaret.charAt(0) if (firstchar === '@') { - const matchedUsers = filter(this.users, (user) => (String(user.name + user.screen_name)).toUpperCase() - .startsWith(this.textAtCaret.slice(1).toUpperCase())) + const query = this.textAtCaret.slice(1).toUpperCase() + const matchedUsers = filter(this.users, (user) => { + return user.screen_name.toUpperCase().startsWith(query) || + user.name && user.name.toUpperCase().startsWith(query) + }) if (matchedUsers.length <= 0) { return false } diff --git a/src/components/who_to_follow_panel/who_to_follow_panel.js b/src/components/who_to_follow_panel/who_to_follow_panel.js index ce60308f..bc62f455 100644 --- a/src/components/who_to_follow_panel/who_to_follow_panel.js +++ b/src/components/who_to_follow_panel/who_to_follow_panel.js @@ -47,8 +47,8 @@ function showWhoToFollow (panel, reply) { } }) } + cn = (cn + step) % users.length } - cn = (cn + step) % users.length } function getWhoToFollow (panel) { |
