Anders Kaseorg
527b6a36b3
js: Convert static/js/reload.js to ES6 module.
...
Signed-off-by: Anders Kaseorg <anders@zulip.com>
2021-02-28 14:23:00 -08:00
Anders Kaseorg
e05293a257
js: Convert static/js/reload_state.js to ES6 module.
...
Signed-off-by: Anders Kaseorg <anders@zulip.com>
2021-02-28 14:23:00 -08:00
Anders Kaseorg
b830f53eb5
js: Convert static/js/narrow_state.js to ES6 module.
...
Signed-off-by: Anders Kaseorg <anders@zulip.com>
2021-02-28 14:23:00 -08:00
Anders Kaseorg
a1e9be884d
js: Convert static/js/message_live_update.js to ES6 module.
...
Signed-off-by: Anders Kaseorg <anders@zulip.com>
2021-02-28 14:23:00 -08:00
Anders Kaseorg
817358ce00
js: Convert static/js/message_list_view.js to ES6 module.
...
Signed-off-by: Anders Kaseorg <anders@zulip.com>
2021-02-28 14:23:00 -08:00
Anders Kaseorg
68f7bfff56
js: Convert static/js/submessage.js to ES6 module.
...
Signed-off-by: Anders Kaseorg <anders@zulip.com>
2021-02-28 14:23:00 -08:00
Anders Kaseorg
472f3bc478
js: Convert static/js/poll_widget.js to ES6 module.
...
Signed-off-by: Anders Kaseorg <anders@zulip.com>
2021-02-28 14:23:00 -08:00
Anders Kaseorg
cfacf68fb8
js: Convert static/js/filter.js to ES6 module.
...
Signed-off-by: Anders Kaseorg <anders@zulip.com>
2021-02-28 14:23:00 -08:00
Anders Kaseorg
16668904c1
js: Convert static/js/top_left_corner.js to ES6 module.
...
Signed-off-by: Anders Kaseorg <anders@zulip.com>
2021-02-28 14:23:00 -08:00
Anders Kaseorg
1b151d0472
js: Convert static/js/recent_senders.js to ES6 module.
...
Signed-off-by: Anders Kaseorg <anders@zulip.com>
2021-02-28 14:23:00 -08:00
Anders Kaseorg
850c3c65e7
js: Convert static/js/pm_list.js to ES6 module.
...
Signed-off-by: Anders Kaseorg <anders@zulip.com>
2021-02-28 14:23:00 -08:00
Anders Kaseorg
666938f46c
js: Convert static/js/pm_list_dom.js to ES6 module.
...
Signed-off-by: Anders Kaseorg <anders@zulip.com>
2021-02-28 14:23:00 -08:00
Anders Kaseorg
20cfb9ef09
js: Convert static/js/topic_list.js to ES6 module.
...
Signed-off-by: Anders Kaseorg <anders@zulip.com>
2021-02-28 14:23:00 -08:00
Anders Kaseorg
5a68bda15b
js: Convert static/js/user_groups.js to ES6 module.
...
Signed-off-by: Anders Kaseorg <anders@zulip.com>
2021-02-28 14:23:00 -08:00
Anders Kaseorg
592cd780f5
js: Convert static/js/rows.js to ES6 module.
...
Signed-off-by: Anders Kaseorg <anders@zulip.com>
2021-02-28 14:23:00 -08:00
Anders Kaseorg
fe4d1e839c
js: Convert static/js/message_viewport.js to ES6 module.
...
Signed-off-by: Anders Kaseorg <anders@zulip.com>
2021-02-28 14:23:00 -08:00
Anders Kaseorg
6e045e4470
js: Convert static/js/muting_ui.js to ES6 module.
...
Signed-off-by: Anders Kaseorg <anders@zulip.com>
2021-02-28 14:23:00 -08:00
Anders Kaseorg
94a5da325c
js: Convert static/js/muting.js to ES6 module.
...
Signed-off-by: Anders Kaseorg <anders@zulip.com>
2021-02-28 14:23:00 -08:00
Anders Kaseorg
ece27a19bc
js: Convert static/js/unread_ui.js to ES6 module.
...
Signed-off-by: Anders Kaseorg <anders@zulip.com>
2021-02-28 14:23:00 -08:00
Anders Kaseorg
09920af211
js: Convert static/js/channel.js to ES6 module.
...
Signed-off-by: Anders Kaseorg <anders@zulip.com>
2021-02-28 14:23:00 -08:00
Anders Kaseorg
1dafb143e3
js: Convert static/js/compose_pm_pill.js to ES6 module.
...
Signed-off-by: Anders Kaseorg <anders@zulip.com>
2021-02-28 14:23:00 -08:00
Anders Kaseorg
000865ceb1
js: Convert static/js/user_pill.js to ES6 module.
...
Signed-off-by: Anders Kaseorg <anders@zulip.com>
2021-02-28 14:23:00 -08:00
Anders Kaseorg
977e7dfe07
js: Convert static/js/drafts.js to ES6 module.
...
Signed-off-by: Anders Kaseorg <anders@zulip.com>
2021-02-28 14:23:00 -08:00
Anders Kaseorg
98c4ffa700
js: Convert static/js/scroll_util.js to ES6 module.
...
Signed-off-by: Anders Kaseorg <anders@zulip.com>
2021-02-28 14:23:00 -08:00
Anders Kaseorg
6477b7631c
js: Convert static/js/rtl.js to ES6 module.
...
Signed-off-by: Anders Kaseorg <anders@zulip.com>
2021-02-28 14:23:00 -08:00
Anders Kaseorg
f85924dd0a
js: Convert static/js/keydown_util.js to ES6 module.
...
Signed-off-by: Anders Kaseorg <anders@zulip.com>
2021-02-28 14:23:00 -08:00
Anders Kaseorg
d5740d43f3
js: Convert static/js/vdom.js to ES6 module.
...
Signed-off-by: Anders Kaseorg <anders@zulip.com>
2021-02-28 14:23:00 -08:00
Anders Kaseorg
3faae49dc0
js: Convert static/js/loading.js to ES6 module.
...
Signed-off-by: Anders Kaseorg <anders@zulip.com>
2021-02-28 14:23:00 -08:00
Anders Kaseorg
a3e6ebb04c
js: Convert static/js/common.js to ES6 module.
...
Signed-off-by: Anders Kaseorg <anders@zulip.com>
2021-02-28 14:23:00 -08:00
Anders Kaseorg
4df3fef88f
zjsunit: Add babel-plugin-lazy-require.
...
Signed-off-by: Anders Kaseorg <anders@zulip.com>
2021-02-28 14:23:00 -08:00
Anders Kaseorg
b93e00f213
zjsunit: Enable Babel lazy imports.
...
Signed-off-by: Anders Kaseorg <anders@zulip.com>
2021-02-28 14:23:00 -08:00
Anders Kaseorg
48c67700ed
node_tests: Convert rewiremock.proxy uses to low level API.
...
This seems easier to understand and much easier to produce
automatically.
Signed-off-by: Anders Kaseorg <anders@zulip.com>
2021-02-28 14:23:00 -08:00
Anders Kaseorg
aee94f141d
zjsunit: Remove _patched_with_set_global check.
...
Most of our set_global usage will disappear as our globals do, anyway.
Signed-off-by: Anders Kaseorg <anders@zulip.com>
2021-02-28 14:23:00 -08:00
Anders Kaseorg
db50451a5a
zjsunit: Use __Rewire__ for ES modules in with_field.
...
Signed-off-by: Anders Kaseorg <anders@zulip.com>
2021-02-28 14:23:00 -08:00
Anders Kaseorg
8985b5ffc7
zjsunit: Use __Rewire__ for ES modules in override.
...
Signed-off-by: Anders Kaseorg <anders@zulip.com>
2021-02-28 14:23:00 -08:00
Anders Kaseorg
7c860caffc
node_tests: Remove unnecessary zrequire calls for ES6 modules.
...
Signed-off-by: Anders Kaseorg <anders@zulip.com>
2021-02-28 14:23:00 -08:00
Anders Kaseorg
8947ff10a4
compose: Add setter for wildcard_mention_large_stream_threshold.
...
Signed-off-by: Anders Kaseorg <anders@zulip.com>
2021-02-28 14:23:00 -08:00
Anders Kaseorg
cc3d33b386
node_tests: Unroll ignore_modules loop in ui_init test.
...
Signed-off-by: Anders Kaseorg <anders@zulip.com>
2021-02-28 14:23:00 -08:00
Steve Howell
07b213bd2e
node tests: Remove unused parameters.
...
We were not setting shiftKey or ctrlKey to true.
2021-02-26 14:11:42 -05:00
Steve Howell
4543554daf
node tests: Add overrides for hotkeys.
2021-02-26 14:11:42 -05:00
Steve Howell
bfcb84774c
node tests: Default overlay functions to false.
2021-02-26 14:11:42 -05:00
Steve Howell
87f4fa3323
node tests: Split up hotkey tests.
2021-02-26 14:11:42 -05:00
Steve Howell
70d204ddce
node tests: Promote code to module level in hotkeys test.
2021-02-26 14:11:42 -05:00
Steve Howell
3035d1790b
node tests: Inline return_true and return_false.
...
We just use the concise es6 idiom now.
2021-02-26 14:11:42 -05:00
Anders Kaseorg
54c97c4457
node_tests: Consistently move set_global mocks before zrequire calls.
...
This way, as we convert them to rewiremock, they will become available
before they are imported.
Signed-off-by: Anders Kaseorg <anders@zulip.com>
2021-02-26 07:55:53 -08:00
Anders Kaseorg
15b1abef3d
puppeteer_tests: Fix for recent topics title change.
...
Signed-off-by: Anders Kaseorg <anders@zulip.com>
2021-02-25 18:31:54 -08:00
Wesley Aptekar-Cassels
673af19a4d
typeahead: Always rank exact string match first.
...
Previously, exact matches could be pushed off the typeahead list in the
case where there were more prefix matches that happened to rank first,
which is confusing to the user: if an emoji, for instance, falls into
this category, it will never show up in typeahead, which is easy to
confuse with the emoji not existing.
This isn't a perfect fix — there are still cases where it's hard to find
emojis because the prefix-space is very crowded, but it does fix a
category of surprising and frustrating behaviour.
This doesn't come completely without downside - it means that the exact
match emoji will jump to the front of the list, which changes what is
currently conceptually a "filtering" operation to a "filtering and
sorting" operation, but it seems on the whole to be a more ideal
experience. This is particularly notable in the non-typeahead emoji
picker, which uses the same codepath, but this change seems somewhat
desirable even there, since it allows the user to type the name of an
emoji and press enter and have that emoji show up, without having to
visually confirm that they aren't inadvertently selecting a
prefix-matching emoji.
A better solution to this in the long term might be ordering emoji
results by shortest-first as a tiebreaker for alphabetical ordering,
since that should provide the same behaviour while keeping the mental
model as "filtering" (since the sort order won't change as the user
types), but this seems like a reasonable first pass, and changing to
shortest-first ordering after making this change won't break any muscle
memory for existing users.
2021-02-25 17:55:54 -08:00
Aman Agrawal
f9537053ea
narrow_title: Correct title of RT and all messages narrow.
...
Recent topics, being the default view, is no longer beta.
2021-02-25 17:32:51 -08:00
Aman Agrawal
ce3f1355e1
zulip_logo: Remove custom click handling.
...
We don't need to handle user clicking on Zulip logo since
changing the hash via the `a` tag takes care of it automatically.
Also, cleanup the narrow.restore_home_state function since
it is no longer being used.
2021-02-25 17:32:32 -08:00
Aman Agrawal
f4f37fca14
hashchange: Extract func which checks current hash is in RT.
2021-02-25 17:31:33 -08:00