<commit_before>import React from 'react'
import PropTypes from 'prop-types'
import rokka from '../../rokka'
import Alert from '../Alert'
import Spinner from '../Spinner'

// TODO: Naming
const PreviewSidebar = ({organization, onChange, previewImage = null, currentPreviewImage = null, error = null, imageLoading = false}) => {
  if (!previewImage) {
    return null
  }

  const previewImages = {
    original: rokka.render.getUrl(organization, previewImage.hash, previewImage.format),
    dynamic: currentPreviewImage
      ? currentPreviewImage.src
      : rokka.render.getUrl(organization, previewImage.hash, previewImage.format)
  }

  return (
    <div className="col-md-5 col-sm-5">
      <h3 className="rka-h2 mv-md">
        Preview
        <a href="#" onClick={onChange} className="rka-link flo-r txt-sm">
          Change picture
        </a>
      </h3><commit_msg>Remove unnecessary TODO<commit_after>import React from 'react'
import PropTypes from 'prop-types'
import rokka from '../../rokka'
import Alert from '../Alert'
import Spinner from '../Spinner'

const PreviewSidebar = ({organization, onChange, previewImage = null, currentPreviewImage = null, error = null, imageLoading = false}) => {
  if (!previewImage) {
    return null
  }

  const previewImages = {
    original: rokka.render.getUrl(organization, previewImage.hash, previewImage.format),
    dynamic: currentPreviewImage
      ? currentPreviewImage.src
      : rokka.render.getUrl(organization, previewImage.hash, previewImage.format)
  }

  return (
    <div className="col-md-5 col-sm-5">
      <h3 className="rka-h2 mv-md">
        Preview
        <a href="#" onClick={onChange} className="rka-link flo-r txt-sm">
          Change picture
        </a>
      </h3>
{'fraction_non_alphanumeric': 0.12886597938144329, 'fraction_numerical': 0.0057273768613974796, 'mean_word_length': 3.281862745098039, 'pattern_counts': {'":': 0, '<': 13, '<?xml version=': 0, '>': 15, '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': '6333179', 'n_tokens_mistral': 530, 'n_tokens_neox': 523, 'n_words': 135}