1
0
mirror of https://github.com/mgerb/ps-launcher synced 2026-01-12 03:12:50 +00:00

lots of progress - basic functionality work - bundling working

This commit is contained in:
2017-10-18 23:37:05 -05:00
parent c4e028d102
commit 96f9c4ca5d
27 changed files with 1178 additions and 174 deletions

View File

@@ -5,10 +5,11 @@
border-bottom: 1px solid $dark-blue--3;
display: flex;
height: 100px;
overflow: auto;
overflow-x: auto;
.sub-header__item {
width: 100px;
min-width: 180px;
width: 180px;
display: flex;
align-items: center;
justify-content: center;
@@ -17,6 +18,10 @@
&:hover, &.selected {
background: $dark-blue--3;
}
}
.exp-image {
width: 90%;
height: auto;
}
}

View File

@@ -3,6 +3,16 @@ import { inject, observer } from 'mobx-react';
import * as _ from 'lodash';
import { AppState } from '../../state/AppState';
import vanilla from '../../assets/vanilla.png';
import bc from '../../assets/bc.png';
import wotlk from '../../assets/wotlk.png';
const images: any = {
vanilla,
bc,
wotlk,
};
import './SubHeader.scss';
interface Props {
@@ -26,10 +36,10 @@ export class SubHeader extends React.Component<Props, any> {
private renderItems(): any {
const { selectedExpKey } = this.props.AppState;
return _.map(this.props.AppState.expansions, (exp, key) => {
return _.map(this.props.AppState.expansions, (_, key) => {
return (
<div key={key} className={'sub-header__item ' + (key === selectedExpKey && 'selected')} onClick={() => this.selectExpansion(key)}>
<div style={{ textAlign: 'center' }}>{exp.name}</div>
<img src={images[key]} className="exp-image"/>
</div>
);
});