<commit_before>VersionsView = require 'views/kinds/VersionsView'
ModalView = require 'views/kinds/ModalView'
template = require 'templates/editor/level/versions'

module.exports = class ModalVersionsView extends VersionsView
  id: 'version-history-modal'
  url: "/db/level/"
  page: "level"
  template: template

  className: "modal fade"
  closeButton: true
  closesOnClickOutside: true
  modalWidthPercent: null

  shortcuts:
    'esc': 'hide'

  constructor: (options, @ID) ->
    super options, ID, require 'models/Level'
    _.extend @, ModalView
    ModalView.prototype.constructor options

  getRenderData: (context={}) ->
    context = super(context)
    context.closeButton = true
    context

  hide: ->
    @$el.removeClass('fade').modal "hide"<commit_msg>History now shows a loading bar upon opening<commit_after>VersionsView = require 'views/kinds/VersionsView'
ModalView = require 'views/kinds/ModalView'
template = require 'templates/editor/level/versions'

module.exports = class ModalVersionsView extends VersionsView
  id: 'version-history-modal'
  url: "/db/level/"
  page: "level"
  template: template
  startsLoading: true

  className: "modal fade"
  closeButton: true
  closesOnClickOutside: true
  modalWidthPercent: null

  shortcuts:
    'esc': 'hide'

  constructor: (options, @ID) ->
    super options, ID, require 'models/Level'
    _.extend @, ModalView
    ModalView.prototype.constructor options

  getRenderData: (context={}) ->
    context = super(context)
    context.closeButton = true
    context

  hide: ->
    @$el.removeClass('fade').modal "hide"
{'fraction_non_alphanumeric': 0.11531190926275993, 'fraction_numerical': 0.0, 'mean_word_length': 4.089743589743589, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 9, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '6191161', 'n_tokens_mistral': 496, 'n_tokens_neox': 480, 'n_words': 120}