Goal - end-users will be able to narrow their search results, according to the filter-tags set by our users - For example, type of results like All, Video, Audio & News - or - Comedies, Dramas, Thrillers etc.
once enabling search filters - end-users will see a filters bar below and sticked to the search bar.
filters order will be according to the Data Feed:
should support RTL & LTR
first filter-tag is selected by default (same as tabs)
users will be able to set “all” as the first filter-tag via zapp. when enabled - this filter-tag will appear first in the filter tags bar and will show all results ignoring the filter-tags. in this case - the first filter tag in the data feed will appear second on the filters bar.
moving from one filter to another - keeps the query as is
every change in the query will jump the user back to the first filter tag
When we want to filter based on a subject type such as news, video, or audio we should use the filter parameter within the URL . To clarify, without the filter parameter, we present everything.
- meaning that search data feed URL should include the following parameters:
-
queryTerm - (required, string) the term we want to search for. The device will dynamically replace {{q}} with the user's typed search term. This should be encoded with URL encoding.
-
filterTag - (optional, string) if a user wants to filter the result based on a certain filter tag.
- The URL should look something like this: https://mobapi.kan.org.il/api/search?queryTerm={{queryTerm}}&filterTag={{tag}}&page=1
The device will dynamically replace {{q}} and {{tag}} with the user's typed search term and chosen filter selection.
same structure as the screen picker DS:
- feed id
- feed title
- feed type
and for each entry:
- Id - should be same as the filter tag (video=video)
- title - this will be presented for end users
- type - will always be the same (search-results)
user can choose to develop a dynamic feed taking the search query in consideration. or to use a static feed - and in that case they can use zapp's manual feed tool.
- manual
- dynamic: includes search query and potentially can present only relevant categories - allowing users to choose whether to present empty categories (using empty group component) or not and only show categories with results, for example
In the “general section”: enable search filters (on/off - default should be off).