Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
D
diaspora
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Commits
Issue Boards
Open sidebar
Gigadoc 2
diaspora
Commits
f073a96b
Commit
f073a96b
authored
Apr 08, 2016
by
Dennis Schubert
Browse files
Options
Browse Files
Download
Plain Diff
Merge pull request #6788 from svbergerem/improve-search-suggestions
Improve search and mentions suggestions
parents
a414fb23
75384d50
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
6 additions
and
3 deletions
+6
-3
Changelog.md
Changelog.md
+1
-0
app/assets/javascripts/app/views/search_base_view.js
app/assets/javascripts/app/views/search_base_view.js
+5
-3
No files found.
Changelog.md
View file @
f073a96b
...
...
@@ -95,6 +95,7 @@ Contributions are very welcome, the hard work is done!
*
Prune and do not create aspect visibilities for public posts
[
#6732
](
https://github.com/diaspora/diaspora/pull/6732
)
*
Optimized mobile login and registration forms
[
#6764
](
https://github.com/diaspora/diaspora/pull/6764
)
*
Redesign stream pages
[
#6535
](
https://github.com/diaspora/diaspora/pull/6535
)
*
Improve search and mentions suggestions
[
#6788
](
https://github.com/diaspora/diaspora/pull/6788
)
## Bug fixes
*
Destroy Participation when removing interactions with a post
[
#5852
](
https://github.com/diaspora/diaspora/pull/5852
)
...
...
app/assets/javascripts/app/views/search_base_view.js
View file @
f073a96b
...
...
@@ -18,9 +18,11 @@ app.views.SearchBase = app.views.Base.extend({
setupBloodhound
:
function
(
options
)
{
var
bloodhoundOptions
=
{
datumTokenizer
:
function
(
datum
)
{
var
nameTokens
=
this
.
bloodhoundTokenizer
(
datum
.
name
);
var
handleTokens
=
datum
.
handle
?
this
.
bloodhoundTokenizer
(
datum
.
handle
)
:
[];
return
nameTokens
.
concat
(
handleTokens
);
// hashtags
if
(
typeof
datum
.
handle
===
"
undefined
"
)
{
return
[
datum
.
name
];
}
// people
if
(
datum
.
name
===
datum
.
handle
)
{
return
[
datum
.
handle
];
}
return
this
.
bloodhoundTokenizer
(
datum
.
name
).
concat
(
datum
.
handle
);
}.
bind
(
this
),
queryTokenizer
:
Bloodhound
.
tokenizers
.
whitespace
,
prefetch
:
{
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment