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

Global Search, Tags, Markdown Editor and more #551

Merged
merged 34 commits into from Jan 21, 2016

Conversation

Projects
None yet
3 participants
@morebrownies
Contributor

morebrownies commented Jan 20, 2016

Big changes in this branch related to keywords and search. First, I personally thought the search experience was confusing (as did others) and needed some changes to reflect both how it works behind the scenes and also better match user expectations.

Behind the scenes results are returned based on an exact match on a keyword and does not check against the title or description of the listing. This is completely fine and we can work with it as is, but when the search input says something like, "Enter a keyword", you expect to get results back when you type in something generic like "Rolex". When nothing came back for "Rolex", it felt like search was broken, instead of it feeling like nobody used that keyword yet.

How do we do solve this problem without having to re-engineer everything? It's pretty simple. To solve these issues, I simply changed the entire concept of keywords to tags, everywhere. Tags are something like #theme, #natureTheme or #rolexWatch, where as keywords are "Nature Theme" or "Rolex Watch".

Tags are hugely popular on Twitter, Instagram and other social networks and our users should catch on quickly to the idea. Instagram uses tags to power discovery and search, like so https://www.instagram.com/explore/tags/crystals/ and almost everyone tags their photos these days (like so https://www.instagram.com/p/BAw-fh1QEBf/?tagged=crystals) so that they can be discovered. The same will be true with OpenBazaar.

So now, it is much much more clear that you're searching for things tagged to certain word(s), and if no results come back, you'll understand more clearly that the reason is because nobody used the tag yet.

It also opens up more opportunities for vendors to tag listings to current trends. For example #superbowl2016 could become a popular tag and people could use it to find and discoer awesome superbowl merch or tickets.

Lastly, give it a try and let me know how you feel about it after playing around with it a bit. It takes a little getting use to, but quickly becomes useful in time.

Changes

  • Introduced a language change. Keywords are now tags.
  • Tags no longer allow spaces
  • On the contract detail screen, I added a # before each tag to drive the tagging concept more.
  • On submit of the discover search input, the input text will be converted into a tag (for example, you can type nature theme and it will convert to #naturetheme)
  • GLOBAL SEARCH NOW WORKS. Type in theme or #theme into the address bar to see it in action. :)
  • Clicking a tag on any listing detail page now takes the user to discover and display listings that match the given tag
  • If discover search input is empty and you hit enter, it will clear the existing search
  • Added a no results found message in discover
  • Added copy for when the spinner is displaynig during a search withing discover
  • Added tooltips for minimize and maximize buttons
  • Markdown editor added to the listing details input
  • Markdown editor added to the about page input
  • Markdown editor added to chat window
  • Made a slight tweak to a default theme
  • Cleaned up the styling of the listing detail screen a bit
  • You'll new see an edit button when hovering your avatar
  • You'll now see an edit buttons on your own about section and social media accounts
@hoffmabc

This comment has been minimized.

Show comment
Hide comment
@hoffmabc

hoffmabc Jan 18, 2016

Member

What is simple mde

Member

hoffmabc commented on 2310b51 Jan 18, 2016

What is simple mde

This comment has been minimized.

Show comment
Hide comment
@morebrownies

morebrownies Jan 18, 2016

Contributor

It's a markdown editor I'm trying to get working to make changing your about section and contract details easier. https://www.npmjs.com/package/simplemde

Contributor

morebrownies replied Jan 18, 2016

It's a markdown editor I'm trying to get working to make changing your about section and contract details easier. https://www.npmjs.com/package/simplemde

This comment has been minimized.

Show comment
Hide comment
@hoffmabc

hoffmabc Jan 18, 2016

Member

Ok cool

Member

hoffmabc replied Jan 18, 2016

Ok cool

@hoffmabc

This comment has been minimized.

Show comment
Hide comment
@hoffmabc

hoffmabc Jan 18, 2016

Member

What is simple mde

Member

hoffmabc commented on 2310b51 Jan 18, 2016

What is simple mde

This comment has been minimized.

Show comment
Hide comment
@morebrownies

morebrownies Jan 18, 2016

Contributor

It's a markdown editor I'm trying to get working to make changing your about section and contract details easier. https://www.npmjs.com/package/simplemde

Contributor

morebrownies replied Jan 18, 2016

It's a markdown editor I'm trying to get working to make changing your about section and contract details easier. https://www.npmjs.com/package/simplemde

This comment has been minimized.

Show comment
Hide comment
@hoffmabc

hoffmabc Jan 18, 2016

Member

Ok cool

Member

hoffmabc replied Jan 18, 2016

Ok cool

@jjeffryes

This comment has been minimized.

Show comment
Hide comment
@jjeffryes

jjeffryes Jan 19, 2016

Contributor

Changing <%- to <%= would be the simpler way to get it to parse the tags.

We switched to using <%- in most places to prevent malicious code. That's still an issue, so whichever way we inject the content, it needs to go through the HTML sanitizer first, since someone could be using their own client that allows them to put dangerous content in.

Contributor

jjeffryes commented on js/templates/item.html in 71efd8f Jan 19, 2016

Changing <%- to <%= would be the simpler way to get it to parse the tags.

We switched to using <%- in most places to prevent malicious code. That's still an issue, so whichever way we inject the content, it needs to go through the HTML sanitizer first, since someone could be using their own client that allows them to put dangerous content in.

This comment has been minimized.

Show comment
Hide comment
@jjeffryes

jjeffryes Jan 19, 2016

Contributor

That comment was pre-coffee. You did exactly what I suggested farther down. Good work!

Contributor

jjeffryes replied Jan 19, 2016

That comment was pre-coffee. You did exactly what I suggested farther down. Good work!

@jjeffryes

This comment has been minimized.

Show comment
Hide comment
@jjeffryes

jjeffryes Jan 19, 2016

Contributor

It would be more efficient to do this in the model js parse function, so there would only be one change to the DOM instead of two. But that's a bit complicated. This works fine, if I can I'll modify it later.

Contributor

jjeffryes commented on js/views/itemVw.js in 71efd8f Jan 19, 2016

It would be more efficient to do this in the model js parse function, so there would only be one change to the DOM instead of two. But that's a bit complicated. This works fine, if I can I'll modify it later.

@morebrownies

This comment has been minimized.

Show comment
Hide comment
@morebrownies

morebrownies Jan 20, 2016

Contributor

@jjeffryes tons of new things going on here. Might want to double check this one to make sure I didn't screw anything up in the router or html injections via the markdown editor.

Contributor

morebrownies commented Jan 20, 2016

@jjeffryes tons of new things going on here. Might want to double check this one to make sure I didn't screw anything up in the router or html injections via the markdown editor.

@jjeffryes

This comment has been minimized.

Show comment
Hide comment
@jjeffryes

jjeffryes Jan 20, 2016

Contributor

@morebrownies Roger that. I'll take a look after I wrap up what I'm doing now.

Contributor

jjeffryes commented Jan 20, 2016

@morebrownies Roger that. I'll take a look after I wrap up what I'm doing now.

jjeffryes and others added some commits Jan 20, 2016

Merge remote-tracking branch 'refs/remotes/origin/master' into misc4
# Conflicts:
#	js/models/languagesMd.js

morebrownies and others added some commits Jan 20, 2016

jjeffryes added a commit that referenced this pull request Jan 21, 2016

Merge pull request #551 from OpenBazaar/misc4
Global Search, Tags, Markdown Editor and more

@jjeffryes jjeffryes merged commit cca4d7a into master Jan 21, 2016

2 checks passed

continuous-integration/travis-ci/pr The Travis CI build passed
Details
continuous-integration/travis-ci/push The Travis CI build passed
Details

@jjeffryes jjeffryes removed the In progress label Jan 21, 2016

@morebrownies morebrownies deleted the misc4 branch Jan 21, 2016

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment