<commit_before>import { merge } from '../../src/updates.js';
import { substantiveElements } from '../../src/content.js';
import * as symbols from '../../src/symbols.js';
import ReactiveElement from '../../src/ReactiveElement.js';
import SlotContentMixin from '../../src/SlotContentMixin.js';


const Base =
  SlotContentMixin(
    ReactiveElement
  );


class RenderState extends Base {

  get defaultState() {
    return Object.assign({}, super.defaultState, {
      fixtureState: {}
    });
  }

  get [symbols.contentSlot]() {
    return this.$.fixtureSlot;
  }

  get fixture() {
    if (!this.state.content) {
      return;
    }
    const elements = substantiveElements(this.state.content);
    if (!elements || elements.length < 1) {
      return;
    }
    // Look for an element (or subelement) with class "fixture".
    const fixtures = elements.map(element =>
      element.classList.contains('fixture') ?
        element :
        element.querySelector('.fixture')
    ).filter(item => item !== null);

    // If no fixture was found, return the first element.
    const fixture = fixtures[0] || elements[0];<commit_msg>Lint fixes<commit_after>import { merge } from '../../src/updates.js';
import { substantiveElements } from '../../src/content.js';
import * as symbols from '../../src/symbols.js';
import ReactiveElement from '../../src/ReactiveElement.js';
import SlotContentMixin from '../../src/SlotContentMixin.js';


const Base =
  SlotContentMixin(
    ReactiveElement
  );


class RenderState extends Base {

  get defaultState() {
    return Object.assign({}, super.defaultState, {
      fixtureState: {}
    });
  }

  get [symbols.contentSlot]() {
    return this.$.fixtureSlot;
  }

  get fixture() {
    if (!this.state.content) {
      return null;
    }
    const elements = substantiveElements(this.state.content);
    if (!elements || elements.length < 1) {
      return null;
    }
    // Look for an element (or subelement) with class "fixture".
    const fixtures = elements.map(element =>
      element.classList.contains('fixture') ?
        element :
        element.querySelector('.fixture')
    ).filter(item => item !== null);

    // If no fixture was found, return the first element.
    const fixture = fixtures[0] || elements[0];
{'fraction_non_alphanumeric': 0.15147512109202993, 'fraction_numerical': 0.002642007926023778, 'mean_word_length': 2.824915824915825, 'pattern_counts': {'":': 0, '<': 5, '<?xml version=': 0, '>': 7, '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': '4017615', 'n_tokens_mistral': 668, 'n_tokens_neox': 660, 'n_words': 168}