<commit_before>import {
  MTMergeModal, MTMergeModalParams, MTMergeModalStateProps, MTMergeModalDispatchProps, MTTranslationStatus
} from '../../components/MTMerge/MTMergeModal';
// import {
//   toggleMTMergeModal,
//   mergeVersionFromMT,
//   // Note: trying the existing TM process functions for now
//   queryTMMergeProgress as queryMTMergeProgress,
//   cancelTMMergeRequest as cancelMTMergeRequest,
//   currentMTMergeProcessFinished,
//   MTMergeOptions
// } from '../../actions/version-actions'
import { connect } from 'react-redux'
import { LocaleId, Locale } from '../../utils/prop-types-util';
import { TopLevelState } from '../../reducers/state';

const mapReduxStateToProps = (state: TopLevelState): MTMergeModalStateProps => {
  const {
    projectVersion: {
      locales,
      // notification,
      MTMerge: {
        showMTMerge,
        // triggered,
        // projectVersions,
        // processStatus,
        // queryStatus
      }
    }
  } = state
  return {
    showMTMerge,
    // triggered,
    availableLocales: locales as Locale[],
    // projectVersions,
    // notification,
    // processStatus,
    // queryStatus
  }
}

const mapDispatchToProps = (_dispatch: any): MTMergeModalDispatchProps => {
  return {
    // toggleMTMergeModal: () => {
    //   dispatch(toggleMTMergeModal())
    // },
    // queryMTMergeProgress: (url: string) => {
    //   dispatch(queryMTMergeProgress(url))
    // },
    // onCancelMTMerge: (url: string) => {
    //   dispatch(cancelMTMergeRequest(url))
    // },
    // mergeProcessFinished: () => {
    //   dispatch(currentMTMergeProcessFinished())
    // },
    onCancel: () => {
      // TODO<commit_msg>feat: modal onCancel to trigger toggleMTMergeModal action<commit_after>import {
  MTMergeModal, MTMergeModalParams, MTMergeModalStateProps, MTMergeModalDispatchProps, MTTranslationStatus
} from '../../components/MTMerge/MTMergeModal';
import {
  toggleMTMergeModal,
  // mergeVersionFromMT,
  // Note: trying the existing TM process functions for now
  // queryTMMergeProgress as queryMTMergeProgress,
  // cancelTMMergeRequest as cancelMTMergeRequest,
  // currentMTMergeProcessFinished,
  // MTMergeOptions
} from '../../actions/version-actions'
import { connect } from 'react-redux'
import { LocaleId, Locale } from '../../utils/prop-types-util';
import { TopLevelState } from '../../reducers/state';

const mapReduxStateToProps = (state: TopLevelState): MTMergeModalStateProps => {
  const {
    projectVersion: {
      locales,
      // notification,
      MTMerge: {
        showMTMerge,
        // triggered,
        // projectVersions,
        // processStatus,
        // queryStatus
      }
    }
  } = state
  return {
    showMTMerge,
    // triggered,
    availableLocales: locales as Locale[],
    // projectVersions,
    // notification,
    // processStatus,
    // queryStatus
  }
}

const mapDispatchToProps = (dispatch: any): MTMergeModalDispatchProps => {
  return {
    // toggleMTMergeModal: () => {
    //   dispatch(toggleMTMergeModal())
    // },
    // queryMTMergeProgress: (url: string) => {
    //   dispatch(queryMTMergeProgress(url))
    // },
    // onCancelMTMerge: (url: string) => {
    //   dispatch(cancelMTMergeRequest(url))
    // },
    // mergeProcessFinished: () => {
    //   dispatch(currentMTMergeProcessFinished())
    // },
    onCancel: () => {
      dispatch(toggleMTMergeModal())
{'fraction_non_alphanumeric': 0.13719153936545242, 'fraction_numerical': 0.0, 'mean_word_length': 2.741758241758242, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 17, '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': '5713717', 'n_tokens_mistral': 987, 'n_tokens_neox': 999, 'n_words': 185}