zulip/static/shared/js
Sumanth V Rao ca7f84ac58 markdown: bugfix: Fix importing pygments data for codeblock header creation.
In c563cdba61 we imported the generated
pygments data from outside `/shared` folder. This had a couple of
problems:
    * Using `require` was the wrong way to do the import in ES6 modules.
    * Since we get the data from outside `/shared`, clients like
      zulip-mobile would not receive it - this case had to be handeled.

Here, we fix the above problems by receiving the data when initializing
through fenced_code.initialize, and when the pygments data structure is
empty (for zulip-mobile) we fallback to the old header structure without
the data-code-language tag.

Also, this commit does a small refactor to improve the way we fetch
canonicalized_alias from pygments_data.

Tests amended.
2020-09-28 15:39:31 -07:00
..
emoji.js eslint: Replace empty-returns with consistent-return. 2020-09-25 15:17:59 -07:00
fenced_code.js markdown: bugfix: Fix importing pygments data for codeblock header creation. 2020-09-28 15:39:31 -07:00
typeahead.js emoji: Rename :slight_smile: to 😄. 2020-07-21 16:49:54 -07:00
typing_status.js js: Replace underscore with lodash and remove it from globals. 2020-07-26 16:12:06 -07:00
typing_status.js.flow typing_status: Switch sentinel "recipient" value to `null`. 2019-10-24 14:56:56 -07:00