<commit_before>include _masthead
include _questions
include _comments
include _writers
include _objectives
include _draft
include _buttons
include _dashboard
include _policy
include _progress_indicator
include _profile
include _secondary_navigation

// initialization
- var blocks = {};

mixin set(key)
  - blocks[key] = this.block

mixin shareIcon(icon, platform)
  li.modal-share-icon
    a.modal-share-icon-link(class="clj-share-on-#{platform}", href="!sharing url", target="_blank", data-l8n="attr/title:sharing/#{platform}-link-title", title="!share on platform")
      span.visuallyhidden(data-l8n="content:sharing/#{platform}-link-title") !share on platform
      i(class="fa #{icon}")

mixin guidanceText(heading,l8n)
  - l8n = l8n || 'content:create-objective-guidance/heading'
  .guidance-text-wrapper.js-hide-me
    .guidance-text
      .guidance-buttons.clj-guidance-buttons
        a.button-hide-guidance-text.js-hide-button(href="#")
          span Hide
          =" "
          i.fa.fa-times
      h2.guidance-text-heading.clj-guidance-heading.l8n-guidance-heading(data-l8n=l8n) #{heading}
      block

mixin goalItem()
  li.goal-item
    i.fa-li.fa.fa-dot-circle-o
    block

mixin voteUpDownControls()
  - voteUpCount = Math.floor(Math.random() * 100) + 1
  - voteDownCount = Math.floor(Math.random() * 100) + 1
  form.clj-up-down-vote-form.actions-up-down-vote-form(action="/meta/up-vote", method="post")
    input.clj-vote-on-uri(type="hidden", value="!vote-on-uri", name="vote-on-uri")
    input.clj-refer(type="hidden", value="!current-url", name="refer")
    button.func--up-vote.clj-actions-vote-button.actions-vote-up(type="submit")
      span.func--up-score.clj-up-vote-count.actions-vote-count #{voteUpCount}
      i.fa.fa-fw.fa-angle-up
      span.vote-direction-text !Vote up
  form.clj-up-down-vote-form.actions-up-down-vote-form(action="/meta/down-vote", method="post")
    input.clj-vote-on-uri(type="hidden", value="!vote-on-uri", name="vote-on-uri")
    input.clj-refer(type="hidden", value="!current-url", name="refer")
    button.func--down-vote.clj-actions-vote-button.actions-vote-down(type="submit")
      span.func--down-score.clj-down-vote-count.actions-vote-count #{voteDownCount}
      i.fa.fa-fw.fa-angle-down
      span.vote-direction-text !Vote down

mixin pleaseSignIn(reason)
  p(class="clj-#{reason}-please-sign-in")
    span(data-l8n="content:#{reason}/before-sign-in-link") !Please
    =" "
    a(class="clj-#{reason}-sign-in-link", href='/sign-in', data-l8n="content:#{reason}/sign-in-link") !sign in
    =" "
    span(data-l8n="content:#{reason}/after-sign-in-link") !to ...

mixin modal(title, titleTranslationKey, funcClass)
  .modal-contents.clj-modal-contents.js-modal-content
    .modal-header
      h2.modal-title(class="#{funcClass}", data-l8n="content:#{titleTranslationKey}") !Your modal title
    .modal-body
      block

mixin googleAnalytics(trackingID)
  script.clj-google-analytics.
    (function(i,s,o,g,r,a,m) {
      i['GoogleAnalyticsObject']=r;
      i[r]=i[r]||function() {(i[r].q=i[r].q||[]).push(arguments)},
      i[r].l = 1*new Date();
      a = s.createElement(o), m = s.getElementsByTagName(o)[0];
      a.async = 1;
      a.src = g;
      m.parentNode.insertBefore(a,m)})
    (window,document,'script','//www.google-analytics.com/analytics.js','ga');

    ga('create', '#{trackingID}', 'auto');
    ga('send', 'pageview');

mixin cookieWarning
  script.clj-cookie-message(type='text/javascript').
    window.cookieconsent_options = {"message":'${cookieMessage}',"dismiss":'${cookieDismiss}',"learnMore":'${cookieLearnMore}',"link":'${cookieLink}',"theme":"dark-bottom"};
  script.clj-cookie-library(type='text/javascript', src='/static/cookieconsent.min.js')

<commit_msg>FM + AW | 370 | Google Analytics cookies are now kept for a maximum of 6 months<commit_after>include _masthead
include _questions
include _comments
include _writers
include _objectives
include _draft
include _buttons
include _dashboard
include _policy
include _progress_indicator
include _profile
include _secondary_navigation

// initialization
- var blocks = {};

mixin set(key)
  - blocks[key] = this.block

mixin shareIcon(icon, platform)
  li.modal-share-icon
    a.modal-share-icon-link(class="clj-share-on-#{platform}", href="!sharing url", target="_blank", data-l8n="attr/title:sharing/#{platform}-link-title", title="!share on platform")
      span.visuallyhidden(data-l8n="content:sharing/#{platform}-link-title") !share on platform
      i(class="fa #{icon}")

mixin guidanceText(heading,l8n)
  - l8n = l8n || 'content:create-objective-guidance/heading'
  .guidance-text-wrapper.js-hide-me
    .guidance-text
      .guidance-buttons.clj-guidance-buttons
        a.button-hide-guidance-text.js-hide-button(href="#")
          span Hide
          =" "
          i.fa.fa-times
      h2.guidance-text-heading.clj-guidance-heading.l8n-guidance-heading(data-l8n=l8n) #{heading}
      block

mixin goalItem()
  li.goal-item
    i.fa-li.fa.fa-dot-circle-o
    block

mixin voteUpDownControls()
  - voteUpCount = Math.floor(Math.random() * 100) + 1
  - voteDownCount = Math.floor(Math.random() * 100) + 1
  form.clj-up-down-vote-form.actions-up-down-vote-form(action="/meta/up-vote", method="post")
    input.clj-vote-on-uri(type="hidden", value="!vote-on-uri", name="vote-on-uri")
    input.clj-refer(type="hidden", value="!current-url", name="refer")
    button.func--up-vote.clj-actions-vote-button.actions-vote-up(type="submit")
      span.func--up-score.clj-up-vote-count.actions-vote-count #{voteUpCount}
      i.fa.fa-fw.fa-angle-up
      span.vote-direction-text !Vote up
  form.clj-up-down-vote-form.actions-up-down-vote-form(action="/meta/down-vote", method="post")
    input.clj-vote-on-uri(type="hidden", value="!vote-on-uri", name="vote-on-uri")
    input.clj-refer(type="hidden", value="!current-url", name="refer")
    button.func--down-vote.clj-actions-vote-button.actions-vote-down(type="submit")
      span.func--down-score.clj-down-vote-count.actions-vote-count #{voteDownCount}
      i.fa.fa-fw.fa-angle-down
      span.vote-direction-text !Vote down

mixin pleaseSignIn(reason)
  p(class="clj-#{reason}-please-sign-in")
    span(data-l8n="content:#{reason}/before-sign-in-link") !Please
    =" "
    a(class="clj-#{reason}-sign-in-link", href='/sign-in', data-l8n="content:#{reason}/sign-in-link") !sign in
    =" "
    span(data-l8n="content:#{reason}/after-sign-in-link") !to ...

mixin modal(title, titleTranslationKey, funcClass)
  .modal-contents.clj-modal-contents.js-modal-content
    .modal-header
      h2.modal-title(class="#{funcClass}", data-l8n="content:#{titleTranslationKey}") !Your modal title
    .modal-body
      block

mixin googleAnalytics(trackingID)
  script.clj-google-analytics.
    (function(i,s,o,g,r,a,m) {
      i['GoogleAnalyticsObject']=r;
      i[r]=i[r]||function() {(i[r].q=i[r].q||[]).push(arguments)},
      i[r].l = 1*new Date();
      a = s.createElement(o), m = s.getElementsByTagName(o)[0];
      a.async = 1;
      a.src = g;
      m.parentNode.insertBefore(a,m)})
    (window,document,'script','//www.google-analytics.com/analytics.js','ga');

    ga('create', '#{trackingID}', {'cookieExpires': 15778463});
    ga('send', 'pageview');

mixin cookieWarning
  script.clj-cookie-message(type='text/javascript').
    window.cookieconsent_options = {"message":'${cookieMessage}',"dismiss":'${cookieDismiss}',"learnMore":'${cookieLearnMore}',"link":'${cookieLink}',"theme":"dark-bottom"};
  script.clj-cookie-library(type='text/javascript', src='/static/cookieconsent.min.js')


{'fraction_non_alphanumeric': 0.18605876927131373, 'fraction_numerical': 0.008169719330610094, 'mean_word_length': 4.00990099009901, 'pattern_counts': {'":': 10, '<': 3, '<?xml version=': 0, '>': 3, 'https://': 0, 'lorem ipsum': 0, 'www.': 2, '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': '5883967', 'n_tokens_mistral': 2770, 'n_tokens_neox': 2721, 'n_words': 347}