<commit_before>Template.sidebarDesktop.helpers({
  sidebarType: function() {
    return this.subSidebarType ? this.subSidebarType : "sidebarDefault";
  }
});

Template.tutorialSelector.helpers({
  tutorialLink: function() {
    var route = Router.current().route.path(this) || 'angular';

    if (route.indexOf('tutorials/whatsapp/ionic') !== -1 || route.indexOf('tutorials/whatsapp/meteor') !== -1) {
      return 'tutorials.whatsapp.intro';
    }
    else {
      return 'tutorials.socially.intro';
    }
  },
  pages: function() {
    var route = Router.current().route.path(this) || 'angular';

    if (route.indexOf('tutorials/whatsapp/ionic') !== -1 || route.indexOf('tutorials/whatsapp/meteor') !== -1) {
      return [];
    }
    else {
      return [PAGES[0], PAGES[1]];
    }
  }
});

Template.tutorialSelector.helpers({
  selected: function() {
    var self = this;
    var rData = Router.current().data();
    return rData.route == self.route || rData.parent.route == self.route ? "active" : "";
  }
});

Template.sidebarDefault.helpers({
  pages: function() {
    var route = Router.current().route.path(this) || 'angular';

    if (route.indexOf('tutorials/whatsapp/ionic') !== -1) {
      return WHATSAPP_IONIC;
    }
    else {
      return SOCIALLY_ANGULAR1;
    }
  }
});

Template.sidebarDefault.helpers({
  index: function () {
    return Number(this.id);
  }
});

Template.sidebarMobile.helpers({
  selectedMobile: function () {
    return Router.current().data().route == this.route ? {selected: ""} : null;
  }
});
Template.sidebarMobile.events({
  "change .component-sidebar-mobile": function(event, template){<commit_msg>Fix side bar<commit_after>Template.sidebarDesktop.helpers({
  sidebarType: function() {
    return this.subSidebarType ? this.subSidebarType : "sidebarDefault";
  }
});

Template.tutorialSelector.helpers({
  tutorialLink: function() {
    var route = Router.current().route.path(this) || 'angular';

    if (route.indexOf('tutorials/whatsapp/ionic') !== -1 || route.indexOf('tutorials/whatsapp/meteor') !== -1) {
      return 'tutorials.whatsapp.intro';
    }
    else {
      return 'tutorials.socially.intro';
    }
  },
  pages: function() {
    var route = Router.current().route.path(this) || 'angular';

    if (route.indexOf('tutorials/whatsapp/ionic') !== -1 || route.indexOf('tutorials/whatsapp/meteor') !== -1) {
      return [];
    }
    else {
      return [PAGES[0], PAGES[1]];
    }
  }
});

Template.tutorialSelector.helpers({
  selected: function() {
    var self = this;
    var rData = Router.current().data();
    return rData.route == self.route || rData.parent.route == self.route ? "active" : "";
  }
});

Template.sidebarDefault.helpers({
  pages: function() {
    var route = Router.current().route.path(this) || 'angular';

    if (route.indexOf('tutorials/whatsapp/ionic') !== -1) {
      return WHATSAPP_IONIC;
    }
    if (route.indexOf('tutorials/whatsapp/meteor') !== -1) {
      return WHATSAPP_METEOR;
    }
    else {
      return SOCIALLY_ANGULAR1;
    }
  }
});

Template.sidebarDefault.helpers({
  index: function () {
    return Number(this.id);
  }
});

Template.sidebarMobile.helpers({
  selectedMobile: function () {
    return Router.current().data().route == this.route ? {selected: ""} : null;
  }
});
Template.sidebarMobile.events({
  "change .component-sidebar-mobile": function(event, template){
{'fraction_non_alphanumeric': 0.17640117994100296, 'fraction_numerical': 0.005014749262536873, 'mean_word_length': 3.398184176394293, 'pattern_counts': {'":': 2, '<': 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': '4882425', 'n_tokens_mistral': 1170, 'n_tokens_neox': 1128, 'n_words': 182}