<commit_before>import React, { Component } from 'react';
import Audio from 'react-audioplayer';

class AudioPlayer extends Component {
	render() {
		const ROOT_URL = 'http://localhost:3090';
		const { name, imagename, filename } = this.props;
		const imageURL = imagename ? `${ROOT_URL}/files/${imagename}` : 'http://lorempixel.com/500/500/abstract';
		const songURL = `${ROOT_URL}/files/${filename}`;
		const songObj = {
			name: name, // song name
			src: songURL, // song source address
			img: imageURL // (optional) song image source address
		}
		const playList=[songObj];
		return(
			<Audio
				width={1100}
				fullPlayer={true}
				color="#865cd6"
				playlist={playList}
				style={{
					boxShadow: '0px 2px 6px rgba(0, 0, 0, 0.28)',<commit_msg>#39 Make endpoint dynamic in AudioPlayer.js<commit_after>import React, { Component } from 'react';
import Audio from 'react-audioplayer';
import { API_ROOT } from '../actions/api-config';

class AudioPlayer extends Component {
	render() {
		const { name, imagename, filename } = this.props;
		const imageURL = imagename ? `${API_ROOT}files/${imagename}` : 'http://lorempixel.com/500/500/abstract';
		const songURL = `${API_ROOT}files/${filename}`;
		const songObj = {
			name: name, // song name
			src: songURL, // song source address
			img: imageURL // (optional) song image source address
		}
		const playList=[songObj];
		return(
			<Audio
				width={1100}
				fullPlayer={true}
				color="#865cd6"
				playlist={playList}
				style={{
					boxShadow: '0px 2px 6px rgba(0, 0, 0, 0.28)',
{'fraction_non_alphanumeric': 0.14987080103359174, 'fraction_numerical': 0.03359173126614987, 'mean_word_length': 3.7808641975308643, 'pattern_counts': {'":': 0, '<': 5, '<?xml version=': 0, '>': 3, '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': '1052135', 'n_tokens_mistral': 605, 'n_tokens_neox': 512, 'n_words': 135}