<commit_before><!--
    @license
    Copyright (c) 2014 The Polymer Project Authors. All rights reserved.
    This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt
    The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt
    The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt
    Code distributed by Google as part of the polymer project is also
    subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt
-->
<link rel="import" href="../polymer/polymer.html">
<link rel="import" href="../core-tooltip/core-tooltip.html">

<polymer-element name="mini-gauge" attributes="tooltip value max delay transition type path">
  <template>
    <link rel="stylesheet" href="mini-gauge.css">

    <core-tooltip label="{{tooltip}}" position="bottom">
      <div class="mini-graph">
        <svg width="70" height="70">
          <path id="path" d="m2.619049,35c0,-17.890028 14.490923,-32.38095 32.380951,-32.38095c17.890026,0 32.380951,14.490922 32.380951,32.38095c0,17.89003 -14.490925,32.380951 -32.380951,32.380951c-17.890028,0 -32.380951,-14.490921 -32.380951,-32.380951z"/>
        </svg>
        <content select="h2"></content>
        <content class="label"></content>
      </div>
    </core-tooltip>

  </template>
  <script>

  Polymer({
    tooltip: null,
    value: null,
    delay: 0,
    max: 200,
    transition: null,
    type: 'circle',

    observe: {
      'type': 'updatePath',
      'path': 'updatePath'
    },

    ready: function() {
      this.updatePath();
      this.draw();
    },

    updatePath: function() {

    },

    draw: function() {
      this.length = this.$.path.getTotalLength();
      this.$.path.style.strokeDashoffset = this.length - this.value;
      this.$.path.style.strokeDasharray = this.length + ' ' + this.length;

      if (this.transition) {
        this.$.path.style.transition = this.$.path.style.WebkitTransition = this.transition;
      }

      setTimeout(function() {
        this.setValue();
      }.bind(this), this.delay);
    },

    setValue: function() {
      this.$.path.style.strokeDashoffset = (this.length - this.max);
    }
  });

  </script>

</polymer-element>
<commit_msg>bring in count-scroll to display value<commit_after><!--
    @license
    Copyright (c) 2014 The Polymer Project Authors. All rights reserved.
    This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt
    The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt
    The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt
    Code distributed by Google as part of the polymer project is also
    subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt
-->
<link rel="import" href="../polymer/polymer.html">
<link rel="import" href="../core-tooltip/core-tooltip.html">
<link rel="import" href="../count-scroll/count-scroll.html">

<polymer-element name="mini-gauge" attributes="tooltip value max delay transition type path">
  <template>
    <link rel="stylesheet" href="mini-gauge.css">

    <core-tooltip label="{{tooltip}}" position="bottom">
      <div class="mini-graph">
        <svg width="70" height="70">
          <path id="path" d="m2.619049,35c0,-17.890028 14.490923,-32.38095 32.380951,-32.38095c17.890026,0 32.380951,14.490922 32.380951,32.38095c0,17.89003 -14.490925,32.380951 -32.380951,32.380951c-17.890028,0 -32.380951,-14.490921 -32.380951,-32.380951z"/>
        </svg>

        <count-scroll value="{{value}}" delay="{{delay}}" max="{{max}}"></count-scroll>
        <content select="h2"></content>
        <content class="label"></content>
      </div>
    </core-tooltip>

  </template>
  <script>

  Polymer({
    tooltip: null,
    value: null,
    delay: 0,
    max: 200,
    transition: null,
    type: 'circle',

    observe: {
      'type': 'updatePath',
      'path': 'updatePath'
    },

    ready: function() {
      this.updatePath();
      this.draw();
    },

    updatePath: function() {

    },

    draw: function() {
      this.length = this.$.path.getTotalLength();
      this.$.path.style.strokeDashoffset = this.length - this.value;
      this.$.path.style.strokeDasharray = this.length + ' ' + this.length;

      if (this.transition) {
        this.$.path.style.transition = this.$.path.style.WebkitTransition = this.transition;
      }

      setTimeout(function() {
        this.setValue();
      }.bind(this), this.delay);
    },

    setValue: function() {
      this.$.path.style.strokeDashoffset = (this.length - this.max);
    }
  });

  </script>

</polymer-element>

{'fraction_non_alphanumeric': 0.15937433946311563, 'fraction_numerical': 0.07693933629253857, 'mean_word_length': 2.881870385561936, 'pattern_counts': {'":': 0, '<': 48, '<?xml version=': 0, '>': 48, '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': '3573474', 'n_tokens_mistral': 1774, 'n_tokens_neox': 1493, 'n_words': 342}