Project-Image-Uploader/frontend/src/Components/ComponentUtils/StatsDisplay/StatsDisplay.js
matthias.lotz e4712f9e7e refactor: Extract ConsentFilter and StatsDisplay components from ModerationGroupsPage
- Created ConsentFilter component with proper styling
- Created StatsDisplay component for statistics display
- Added ModerationGroupsPage.css to remove inline styles
- Removed 83 lines of inline CSS from ModerationGroupsPage
- Components now reusable across admin pages
- Added container wrappers and titles to both components
- Improved code maintainability and separation of concerns
2025-11-29 15:21:51 +01:00

27 lines
779 B
JavaScript

import React from 'react';
import './StatsDisplay.css';
/**
* StatsDisplay Component
* Displays statistics in a grid layout
*
* @param {Array} stats - Array of stat objects { number, label }
*/
const StatsDisplay = ({ stats }) => {
return (
<div className="stats-display-container">
<h2 className="stats-title">Statistiken</h2>
<div className="stats-display">
{stats.map((stat, index) => (
<div key={index} className="stat-item">
<span className="stat-number">{stat.number}</span>
<span className="stat-label">{stat.label}</span>
</div>
))}
</div>
</div>
);
};
export default StatsDisplay;