mirror of
https://github.com/zotero/zotero.git
synced 2026-09-26 01:11:23 +00:00
* citation dialog: interactive before io.getFields - added io.allCitedDataLoadedPromise, which is resolved when both io.fieldIndexPromise and io.citationsByItemIDPromise are resolved. Resolved io.allCitedDataLoadedPromise essentially means that calls to io.sort() and io.getItems() will be fast because all necessary data is already loaded. - citation dialog uses io.allCitedDataLoadedPromise to not await for functions relying on io.sort() and io.getItems() before the data is loaded, as it could take an arbitrary amoung of time. Speicifcally, SearchHandler._getCitedItems() and CitationDataManager.sort. As soon as allCitedDataLoadedPromise is resolved, cited items will be sorted. This means that when retrieving fields takes a long time, one can still add new items, their bubbles will just not immediately be sorted. - this replaces earlier SearchHandler.loadCitedItemsPromise, which was a special case of this handling. - added a new test ensuring that bubbles can be added even when io.allCitedDataLoadedPromise is not resolved yet - cleanup for buildCitation function to remove handling of io.citation.sortedItems, which is always empty on load before io.sort() runs - added a few Zotero.debug statements for future debugging - Uses a dummy promise if no allCitedDataLoadedPromise (e.g. to accomodate the note editor) |
||
|---|---|---|
| .. | ||
| content | ||
| locale | ||
| skin/default/zotero | ||