<commit_before>import '!style!css!less!./App.less';
import React, { Component } from 'react';
import Nav from '../Nav';
import Banner from '../Banner';
import Footer from '../Footer';
import About from '../About';
import SignUp from '../SignUp';
import Prospect from '../Prospect';
import Speaker from '../Speaker';
import Schedule from '../Schedule';
import Location from '../Location';
import Sponsor from '../Sponsor';

class App extends Component {

  componentDidMount() {
    let title = document.title;
    let $w = $(window);
    let $g = $('nav');
    let $b = (window.opera) ?
      (document.compatMode === 'CSS1Compat' ? $('html') : $('body')) :
      $('html,body');

    $(function() {
      $g.on('click', function() {
        $(window).trigger('hashchange');
      });

      $w.on('hashchange', function () {
        let hash = window.location.hash || '#top-section',
          $link = $('a[href="' + hash + '"]'),
          pageId = hash.replace('-section', ''),
          subTitle = $link.text() || '首頁',
          top = $(pageId).offset().top || 0;

        $('nav a').css('border-bottom', '0px');
        $link.css('border-bottom', '1px solid #fff');

        $b.animate({
          scrollTop: top
        }, 600, function () {<commit_msg>fix #24 remove trigger twice event of hash change..<commit_after>import '!style!css!less!./App.less';
import React, { Component } from 'react';
import Nav from '../Nav';
import Banner from '../Banner';
import Footer from '../Footer';
import About from '../About';
import SignUp from '../SignUp';
import Prospect from '../Prospect';
import Speaker from '../Speaker';
import Schedule from '../Schedule';
import Location from '../Location';
import Sponsor from '../Sponsor';

class App extends Component {

  componentDidMount() {
    let title = document.title;
    let $w = $(window);
    let $b = (window.opera) ?
      (document.compatMode === 'CSS1Compat' ? $('html') : $('body')) :
      $('html,body');

    $(function() {
      $w.on('hashchange', function () {
        let hash = window.location.hash || '#top-section';
        let $link = $('a[href="' + hash + '"]');
        let pageId = hash.replace('-section', '');
        let subTitle = $link.text() || '首頁';
        let top = ($(pageId).offset() && $(pageId).offset().top) || 0;

        $('nav a').css('border-bottom', '0px');
        $link.css('border-bottom', '1px solid #fff');

        $b.animate({
          scrollTop: top
        }, 600, function () {
{'fraction_non_alphanumeric': 0.2079806529625151, 'fraction_numerical': 0.006449012494961709, 'mean_word_length': 2.7720364741641337, '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': '1436519', 'n_tokens_mistral': 771, 'n_tokens_neox': 738, 'n_words': 211}