mirror of https://github.com/zulip/zulip.git
5e49ddf4e1
This changes the method of rendering list of alert words in DOM, earlier it was rendered using 'for' loop over the array of alert_words which is now changed to render using ListWidget, which gets a array of objects from get_word_list() in alert_words.js. The use of ListWidget helps to define a parent_container and $container in table-body of alert-words-table using which we can now apply sorting over alert words with the help of handle_sort() function in list_widget.js Changed the method of adding alert_word_settings_item row in table body through {{#with}} loop because of rendering through ListWidget, which was done earlier using for loop over each alert-word in while rendering the list. this commit also mocks template of render_alert_word_item while mocking ListWidget.create() function in render_alert_words_ui(). and checks that ListWidget.create() is not called when variable `loaded` is set as false. Fixes #21142. |
||
---|---|---|
.. | ||
assets | ||
audio | ||
generated | ||
html | ||
images | ||
js | ||
shared | ||
styles | ||
templates | ||
third | ||
.gitignore |