<commit_before>import Ember from 'ember';
import CoughDrop from '../../app';
import i18n from '../../utils/i18n';

export default Ember.Component.extend({
  didInsertElement: function() {
    this.draw();
  },
  elem_class: function() {
    if(this.get('side_by_side')) {
      return Ember.String.htmlSafe('col-sm-6');
    } else {
      return Ember.String.htmlSafe('col-sm-8');
    }
  }.property('side_by_side'),
  elem_style: function() {
    if(this.get('right_side')) {
      return Ember.String.htmlSafe('border-left: 1px solid #eee;');
    } else {
      return Ember.String.htmlSafe('');
    }
  }.property('right_side'),
  draw: function() {
    var $elem = Ember.$(this.get('element'));
    if(this.get('ref_stats') && this.get('usage_stats')) {
      this.set('usage_stats.ref_max_time_block', this.get('ref_stats.max_time_block'));
      this.set('usage_stats.ref_max_combined_time_block', this.get('ref_stats.max_combined_time_block'));
      this.set('usage_stats.ref_max_modeled_time_block', this.get('ref_stats.max_modeled_time_block'));
      this.set('usage_stats.ref_max_combined_modeled_time_block', this.get('ref_stats.max_combined_modeled_time_block'));
    }
    $elem.find(".time_block").tooltip({container: 'body'});
  }.observes('usage_stats.draw_id', 'ref_stats.draw_id', 'modeling')
});

<commit_msg>ensure time of day tooltips appear<commit_after>import Ember from 'ember';
import CoughDrop from '../../app';
import i18n from '../../utils/i18n';

export default Ember.Component.extend({
  didInsertElement: function() {
    this.draw();
  },
  elem_class: function() {
    if(this.get('side_by_side')) {
      return Ember.String.htmlSafe('col-sm-6');
    } else {
      return Ember.String.htmlSafe('col-sm-8');
    }
  }.property('side_by_side'),
  elem_style: function() {
    if(this.get('right_side')) {
      return Ember.String.htmlSafe('border-left: 1px solid #eee;');
    } else {
      return Ember.String.htmlSafe('');
    }
  }.property('right_side'),
  draw: function() {
    var $elem = Ember.$(this.get('element'));
    if(this.get('ref_stats') && this.get('usage_stats')) {
      this.set('usage_stats.ref_max_time_block', this.get('ref_stats.max_time_block'));
      this.set('usage_stats.ref_max_combined_time_block', this.get('ref_stats.max_combined_time_block'));
      this.set('usage_stats.ref_max_modeled_time_block', this.get('ref_stats.max_modeled_time_block'));
      this.set('usage_stats.ref_max_combined_modeled_time_block', this.get('ref_stats.max_combined_modeled_time_block'));
    }
    Ember.run.later(function() {
      $elem.find(".time_block").tooltip({container: 'body'});
    }, 1000);
  }.observes('usage_stats.draw_id', 'ref_stats.draw_id', 'usage_stats.modeling')
});


{'fraction_non_alphanumeric': 0.17906637490882568, 'fraction_numerical': 0.006564551422319475, 'mean_word_length': 4.326213592233009, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 3, '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': '4325297', 'n_tokens_mistral': 980, 'n_tokens_neox': 965, 'n_words': 125}