entry_list.js 905 B

123456789101112131415161718192021222324252627282930313233
  1. // TODO: This file was created by bulk-decaffeinate.
  2. // Sanity-check the conversion and remove this comment.
  3. /*
  4. * decaffeinate suggestions:
  5. * DS102: Remove unnecessary code created because of implicit returns
  6. * DS206: Consider reworking classes to avoid initClass
  7. * Full docs: https://github.com/decaffeinate/decaffeinate/blob/main/docs/suggestions.md
  8. */
  9. //= require views/list/paginated_list
  10. app.views.EntryList = class EntryList extends app.views.PaginatedList {
  11. static initClass() {
  12. this.tagName = "div";
  13. this.className = "_list _list-sub";
  14. }
  15. constructor(entries) {
  16. super(...arguments);
  17. this.entries = entries;
  18. this.init0(); // needs this.data from PaginatedList
  19. this.refreshElements();
  20. }
  21. init0() {
  22. this.renderPaginated();
  23. this.activate();
  24. }
  25. render(entries) {
  26. return this.tmpl("sidebarEntry", entries);
  27. }
  28. };
  29. app.views.EntryList.initClass();