mirror of https://github.com/zulip/zulip.git
36707a33ca
Following points have been implemented in this commit: 1.) Add search pill on selecting typeahead. 2.) Re-narrow after removing a search pill. 3.) Add quiet optional parameter to removeLastPill. 4.) Pre populate search pills in narrow.activate. 5.) Clear existing search pills on narrow.deactivate. Description of above points: 1.) I tried out using the description from suggestions.lookup_table to append a pill using appendValidatedData so that the description had not to be calculated again. But the description in the suggestions lookup contains html due to highlighting. This html is escaped when inputed in a pill. An attempt was also made to remove the higlighting by replacing the tags. But other espaced characters like < also popped up, so it was better to use append_search_string. 3.) If one wants to refresh the pill using pill.clear and wants to repopulate them, evaluating the event_handler associated with the action of removing the pill may not be desired. 4.) Pill population code is added to narrow.activate. Pills are not populated if the narrow was triggered by search as search handles the addition and removal of pill by itself. The reason for not handling search too in narrow.activate is to avoid clearing the pills and repopulating them. Example of some of the triggers for narrow.activate include `restore draft`, `topic change`,`sidebar`. Also modifies tests for search.js |
||
---|---|---|
.. | ||
activity.scss | ||
alerts.scss | ||
app_components.scss | ||
archive.scss | ||
components.scss | ||
compose.scss | ||
drafts.scss | ||
hotspots.scss | ||
informational-overlays.scss | ||
input_pill.scss | ||
landing-page.scss | ||
left-sidebar.scss | ||
lightbox.scss | ||
media.scss | ||
night_mode.scss | ||
popovers.scss | ||
portico-signin.scss | ||
portico-styles.scss | ||
portico.scss | ||
pygments.scss | ||
reactions.scss | ||
reuseable_components.scss | ||
right-sidebar.scss | ||
settings.scss | ||
stats.scss | ||
subscriptions.scss | ||
typing_notifications.scss | ||
widgets.scss | ||
zulip.scss |