<commit_before>import counterpart from 'counterpart';
import Translate from 'react-translate-component';
import React from 'react';
import ZooniverseLogotype from '../partials/zooniverse-logotype';
import AdminOnly from '../components/admin-only';
import AdminToggle from './admin-toggle';
import { Link, IndexLink } from 'react-router';


counterpart.registerTranslations('en', {
  footer: {
    discover: {
      projectList: 'Projects',
      collectionList: 'Collections',
      projectBuilder: 'Build a Project',
      howToGuide: 'How to Build',
      projectBuilderPolicies: 'Project Policies',
      faq: 'FAQ',
    },
    about: {
      aboutUs: 'About Us',
      ourTeam: 'Our Team',
      education: 'Education',
      publications: 'Publications',
      acknowledgements: 'Acknowledgements'
    },
    talk: {
      zooTalk: 'Zooniverse Talk',
      daily: 'Daily Zooniverse',
      blog: 'Blog',
    },
    boilerplate: {
      contact: 'Contact Us',
      jobs: 'Jobs',
      privacyPolicy: 'Privacy Policy',
      status: 'System Status',
      security: 'Security',
    },
  },
});

const AppFooter = React.createClass({
  contextTypes: {
    geordi: React.PropTypes.object,
  },

  propTypes: {
    user: React.PropTypes.shape({
      admin: React.PropTypes.bool,
    }),
  },

  logMenuClick(linkName) {
    !!this.context.geordi && this.context.geordi.logEvent({
      type: 'footer-menu',
      relatedID: linkName,
    });
  },

  loggableLink(aLink, linkSymbolicName) {
    return React.cloneElement(aLink, {
      onClick: this.logMenuClick.bind(this, linkSymbolicName),
    });
  },

  render() {
    return (
      <div className="app-footer">
        <div className="app-footer__upper">
          <div className="app-footer__section app-footer__brand">
            <IndexLink to="/">
              <ZooniverseLogotype />
            </IndexLink>
            <br />
            <AdminOnly>
              <AdminToggle />
            </AdminOnly>
          </div>

          <nav className="app-footer__section app-footer__nav-lists">
            <ul className="app-footer__nav-list">
              <li>
                {this.loggableLink(<Link to="/projects">
                  <Translate content="footer.discover.projectList" />
                </Link>, 'footer.discover.projectList')}
              </li>
              <li>
                {this.loggableLink(<Link to="/collections">
                  <Translate content="footer.discover.collectionList" />
                </Link>, 'footer.discover.collectionList')}
              </li>
              <li>
                {this.loggableLink(<Link to="/lab">
                  <Translate content="footer.discover.projectBuilder" />
                </Link>, 'footer.discover.projectBuilder')}
              </li>
              <li>
                {this.loggableLink(<Link to="/help">
                  <Translate content="footer.discover.howToGuide" />
                </Link>, 'footer.discover.howToGuide')}
              </li>
              <li>
                {this.loggableLink(<Link to="/help/lab-policies">
                  <Translate content="footer.discover.projectBuilderPolicies" />
                </Link>, 'footer.discover.projectBuilderPolicies')}
              </li>
              <li>
                {this.loggableLink(<Link to="/faq">
                  <Translate content="footer.discover.faq" />
                </Link>, 'footer.discover.faq')}
              </li>
              {process.env.NODE_ENV !== 'production' &&
                <li>
                  <Link to="/dev/classifier">Dev Classifier</Link>
                </li>}
            </ul>

            <ul className="app-footer__nav-list">
              <li>
                {this.loggableLink(<Link to="/about">
                  <Translate content="footer.about.aboutUs" />
                </Link>, 'footer.about.aboutUs')}
              </li>
              <li>
                {this.loggableLink(<Link to="/get-involved/education">
                  <Translate content="footer.about.education" />
                </Link>, 'footer.about.education')}
              </li>
              <li>
                {this.loggableLink(<Link to="/about/team">
                  <Translate content="footer.about.ourTeam" />
                </Link>, 'footer.about.ourTeam')}
              </li>
              <li>
                {this.loggableLink(<Link to="/about/publications">
                  <Translate content="footer.about.publications" />
                </Link>, 'footer.about.publications')}
              </li>
              <li><commit_msg>Fix link to faq page (#3793)<commit_after>import counterpart from 'counterpart';
import Translate from 'react-translate-component';
import React from 'react';
import ZooniverseLogotype from '../partials/zooniverse-logotype';
import AdminOnly from '../components/admin-only';
import AdminToggle from './admin-toggle';
import { Link, IndexLink } from 'react-router';


counterpart.registerTranslations('en', {
  footer: {
    discover: {
      projectList: 'Projects',
      collectionList: 'Collections',
      projectBuilder: 'Build a Project',
      howToGuide: 'How to Build',
      projectBuilderPolicies: 'Project Policies',
      faq: 'FAQ',
    },
    about: {
      aboutUs: 'About Us',
      ourTeam: 'Our Team',
      education: 'Education',
      publications: 'Publications',
      acknowledgements: 'Acknowledgements'
    },
    talk: {
      zooTalk: 'Zooniverse Talk',
      daily: 'Daily Zooniverse',
      blog: 'Blog',
    },
    boilerplate: {
      contact: 'Contact Us',
      jobs: 'Jobs',
      privacyPolicy: 'Privacy Policy',
      status: 'System Status',
      security: 'Security',
    },
  },
});

const AppFooter = React.createClass({
  contextTypes: {
    geordi: React.PropTypes.object,
  },

  propTypes: {
    user: React.PropTypes.shape({
      admin: React.PropTypes.bool,
    }),
  },

  logMenuClick(linkName) {
    !!this.context.geordi && this.context.geordi.logEvent({
      type: 'footer-menu',
      relatedID: linkName,
    });
  },

  loggableLink(aLink, linkSymbolicName) {
    return React.cloneElement(aLink, {
      onClick: this.logMenuClick.bind(this, linkSymbolicName),
    });
  },

  render() {
    return (
      <div className="app-footer">
        <div className="app-footer__upper">
          <div className="app-footer__section app-footer__brand">
            <IndexLink to="/">
              <ZooniverseLogotype />
            </IndexLink>
            <br />
            <AdminOnly>
              <AdminToggle />
            </AdminOnly>
          </div>

          <nav className="app-footer__section app-footer__nav-lists">
            <ul className="app-footer__nav-list">
              <li>
                {this.loggableLink(<Link to="/projects">
                  <Translate content="footer.discover.projectList" />
                </Link>, 'footer.discover.projectList')}
              </li>
              <li>
                {this.loggableLink(<Link to="/collections">
                  <Translate content="footer.discover.collectionList" />
                </Link>, 'footer.discover.collectionList')}
              </li>
              <li>
                {this.loggableLink(<Link to="/lab">
                  <Translate content="footer.discover.projectBuilder" />
                </Link>, 'footer.discover.projectBuilder')}
              </li>
              <li>
                {this.loggableLink(<Link to="/help">
                  <Translate content="footer.discover.howToGuide" />
                </Link>, 'footer.discover.howToGuide')}
              </li>
              <li>
                {this.loggableLink(<Link to="/help/lab-policies">
                  <Translate content="footer.discover.projectBuilderPolicies" />
                </Link>, 'footer.discover.projectBuilderPolicies')}
              </li>
              <li>
                {this.loggableLink(<Link to="/about/faq">
                  <Translate content="footer.discover.faq" />
                </Link>, 'footer.discover.faq')}
              </li>
              {process.env.NODE_ENV !== 'production' &&
                <li>
                  <Link to="/dev/classifier">Dev Classifier</Link>
                </li>}
            </ul>

            <ul className="app-footer__nav-list">
              <li>
                {this.loggableLink(<Link to="/about">
                  <Translate content="footer.about.aboutUs" />
                </Link>, 'footer.about.aboutUs')}
              </li>
              <li>
                {this.loggableLink(<Link to="/get-involved/education">
                  <Translate content="footer.about.education" />
                </Link>, 'footer.about.education')}
              </li>
              <li>
                {this.loggableLink(<Link to="/about/team">
                  <Translate content="footer.about.ourTeam" />
                </Link>, 'footer.about.ourTeam')}
              </li>
              <li>
                {this.loggableLink(<Link to="/about/publications">
                  <Translate content="footer.about.publications" />
                </Link>, 'footer.about.publications')}
              </li>
              <li>
{'fraction_non_alphanumeric': 0.14123006833712984, 'fraction_numerical': 0.00043388653867013776, 'mean_word_length': 1.7367171267438408, 'pattern_counts': {'":': 0, '<': 143, '<?xml version=': 0, '>': 143, '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': '2235586', 'n_tokens_mistral': 2682, 'n_tokens_neox': 2557, 'n_words': 452}