* applied eslint * add locales and lint the project * removed error boundary * updated locales * fix min files * fix locales
16 lines
468 B
JavaScript
16 lines
468 B
JavaScript
import React from 'react';
|
|
import { numberWithCommas } from 'App/utils';
|
|
|
|
function AvgLabel({ className = '', text, count, unit }) {
|
|
return (
|
|
<div className={className}>
|
|
<span className="text-sm color-gray-medium">{text}</span>
|
|
<span className="text-2xl ml-1 font-medium">
|
|
{count ? numberWithCommas(Math.round(count)) : 0}
|
|
</span>
|
|
{unit && <span className="font-lg ml-1">{unit}</span>}
|
|
</div>
|
|
);
|
|
}
|
|
|
|
export default AvgLabel;
|