2017-07-28 20:06:01 +02:00
|
|
|
import React from 'react';
|
2017-07-28 20:15:07 +02:00
|
|
|
import Mod from './Mod.jsx';
|
2017-07-28 20:06:01 +02:00
|
|
|
|
|
|
|
class ModOverview extends React.Component {
|
|
|
|
render() {
|
2017-07-28 20:08:08 +02:00
|
|
|
return(
|
|
|
|
<div className="box">
|
|
|
|
<div className="box-header">
|
|
|
|
<h3 className="box-title">Manage Mods</h3>
|
|
|
|
</div>
|
2017-07-28 20:06:01 +02:00
|
|
|
|
2017-07-28 20:08:08 +02:00
|
|
|
<div className="box-body">
|
|
|
|
<div className="table-responsive">
|
|
|
|
<table className="table table-striped">
|
|
|
|
<thead>
|
|
|
|
<tr>
|
|
|
|
<th>Name</th>
|
|
|
|
<th>Status</th>
|
|
|
|
<th>Toggle Status</th>
|
|
|
|
</tr>
|
|
|
|
</thead>
|
|
|
|
<tbody>
|
|
|
|
{this.props.installedMods.map ( (mod, i) => {
|
2017-07-28 20:22:08 +02:00
|
|
|
if(mod != "base")
|
|
|
|
return(
|
|
|
|
<Mod
|
|
|
|
key={i}
|
|
|
|
mod={mod}
|
|
|
|
{...this.props}
|
|
|
|
/>
|
|
|
|
)
|
2017-07-28 20:08:08 +02:00
|
|
|
})}
|
|
|
|
</tbody>
|
|
|
|
</table>
|
|
|
|
</div>
|
2017-07-28 20:06:01 +02:00
|
|
|
</div>
|
|
|
|
</div>
|
2017-07-28 20:08:08 +02:00
|
|
|
);
|
2017-07-28 20:06:01 +02:00
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
ModOverview.propTypes = {
|
|
|
|
installedMods: React.PropTypes.array.isRequired
|
|
|
|
}
|
|
|
|
|
|
|
|
export default ModOverview;
|