<commit_before><!-- Import Polymer -->
<script src="rectangle.js"></script>
<script src="package.js"></script>
<link rel="import" href="pj-sortable-tiles-editor.html">
<link rel="import" href="element-selector.html">

<!-- Define your custom element -->
<polymer-element name="pj-sortable-tiles" attributes="priorities rowspans colspans cellWidth cellHeight layersOrientation">
    <template>
    <style>
        :host {
            display: table;
        }
        #container{
            display: block;
            position: relative;
        }
        polyfill-next-selector { content: ':host #container> *'; }
        #container ::content>* {
            position: absolute;
            -webkit-transition:width 1s, height 1s, top 1s, left 1s, -webkit-transform 1s;
            transition:width 1s, height 1s, top 1s, left 1s, transform 1s;
        }
    </style>
    <div id="container"><content></content></div>
    <pj-sortable-tiles-editor editedItem="{{editedItem}}" editedItemIndex="{{editedItemIndex}}"></pj-sortable-tiles-editor>
    <element-selector id="elementSelector"></element-selector>
    </template>
    <script>
    (function( scope ){
      /**
       * Counts index of element within its parent
       * @see http://jsperf.com/sibling-index/10
       * @param {Element} elem
       * @return {Number}
       */
      function elementIndex (elem) {
        var i = 0;
        while (elem = elem.previousElementSibling) {
		  if(elem.nodeName != "TEMPLATE") {
			++i
		  }
        }
        return i;
      };

        var defaultSetupNode = {
            width: 1,<commit_msg>Disregard all TemplateElement nodes while counting element index<commit_after><!-- Import Polymer -->
<script src="rectangle.js"></script>
<script src="package.js"></script>
<link rel="import" href="pj-sortable-tiles-editor.html">
<link rel="import" href="element-selector.html">

<!-- Define your custom element -->
<polymer-element name="pj-sortable-tiles" attributes="priorities rowspans colspans cellWidth cellHeight layersOrientation">
    <template>
    <style>
        :host {
            display: table;
        }
        #container{
            display: block;
            position: relative;
        }
        polyfill-next-selector { content: ':host #container> *'; }
        #container ::content>* {
            position: absolute;
            -webkit-transition:width 1s, height 1s, top 1s, left 1s, -webkit-transform 1s;
            transition:width 1s, height 1s, top 1s, left 1s, transform 1s;
        }
    </style>
    <div id="container"><content></content></div>
    <pj-sortable-tiles-editor editedItem="{{editedItem}}" editedItemIndex="{{editedItemIndex}}"></pj-sortable-tiles-editor>
    <element-selector id="elementSelector"></element-selector>
    </template>
    <script>
    (function( scope ){
      /**
       * Counts index of element within its parent
       * @see http://jsperf.com/sibling-index/10
       * @param {Element} elem
       * @return {Number}
       */
      function elementIndex (elem) {
        var i = 0;
        while (elem = elem.previousElementSibling) {
          if(!(elem instanceof HTMLTemplateElement)) {
            ++i
          }
        }
        return i;
      };

        var defaultSetupNode = {
            width: 1,
{'fraction_non_alphanumeric': 0.14124809741248098, 'fraction_numerical': 0.00852359208523592, 'mean_word_length': 2.408713692946058, 'pattern_counts': {'":': 0, '<': 47, '<?xml version=': 0, '>': 51, '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': '2821296', 'n_tokens_mistral': 996, 'n_tokens_neox': 945, 'n_words': 221}