zulip/frontend_tests/casper_tests
Steve Howell 9986e41999 top left: Simplify markup for main links.
The following elements in the top left corner
are major components of our app:

    All messages
    Private messages
    Starred messages
    Mentions

We can now find them directly:

    $('.top_left_all_messages')
    $('.top_left_private_messages')
    $('.top_left_starred_messages')
    $('.top_left_mentions')

Before this, we had to build up complicated selectors
like below:

    exports.get_global_filter_li = function (filter_name) {
        var selector = "#global_filters li[data-name='"
            + filter_name + "']";
        return $(selector);
    };

I don't think any newbie would know to grep for "global_filter",
and I've seen a PR where somebody added specific markup here
to "Private messages" because they couldn't grok the old scheme.

Another thing to note is that we still have a "home-link"
class for "All messages", which overlapped with portico
code that had the same name.  (There were some inaccurate
comments in the code relating to the tab bar, but we don't
actually have a way to click to the home view in the tab
bar any more.)  I'll eliminate that cruft in another commit.

For this commit the four elements still have the
"global-filter" class, since there's some benefit to being
able to style them all as a group, although we should give
it a nicer name in a subsequent commit.

Most of this PR is basic search/replace, but I did add a
two-line helper: `top_left_corner.update_starred_count`
2019-01-30 13:53:20 -08:00
..
00-realm-creation.js casper: Fix test broken by recent signup refactor. 2018-12-10 16:55:07 -08:00
01-login.js Avoid double redirects to /login and then to /login/. 2018-12-04 16:12:58 -08:00
02-site.js eslint: Add key-spacing linter rule. 2018-12-18 10:41:06 -08:00
03-narrow.js top left: Simplify markup for main links. 2019-01-30 13:53:20 -08:00
04-compose.js eslint: Add key-spacing linter rule. 2018-12-18 10:41:06 -08:00
05-subscriptions.js js: Fix indentation issues in casper tests. 2018-05-06 19:35:18 -07:00
06-settings.js eslint: Add key-spacing linter rule. 2018-12-18 10:41:06 -08:00
07-stars.js eslint: Add key-spacing linter rule. 2018-12-18 10:41:06 -08:00
08-edit.js eslint: Add key-spacing linter rule. 2018-12-18 10:41:06 -08:00
09-navigation.js Add stream ids to urls for stream-related narrows. 2018-02-19 09:03:11 -08:00
10-admin.js casper: Fix admin tests failing. 2018-12-17 13:43:13 -08:00
11-mention.js eslint: Add key-spacing linter rule. 2018-12-18 10:41:06 -08:00
12-toggle-message-editing.js eslint: Add key-spacing linter rule. 2018-12-18 10:41:06 -08:00
13-user-deactivation.js Rename "Administration" to "Organization" in the settings UI. 2017-04-07 17:32:56 -07:00
14-drafts.js subject -> topic: Rename compose fields. 2018-12-09 21:28:45 -08:00
15-delete-message.js messages: Add loading spinner for deleting messages. 2019-01-25 11:07:02 -08:00
16-copy-and-paste.js eslint: Add key-spacing linter rule. 2018-12-18 10:41:06 -08:00