bills busted fixes ™️

This commit is contained in:
Layne 2021-07-06 22:39:28 -04:00
parent c9b7fcd841
commit eac7794091
2 changed files with 34 additions and 32 deletions

View File

@ -7,7 +7,7 @@
} }
.inventory-badge-overflow { .inventory-badge-overflow {
height: calc(100% - 86px); height: calc(100% - 91px);
} }
@import './item/InventoryBadgeItemView'; @import './item/InventoryBadgeItemView';

View File

@ -163,41 +163,43 @@ export const InventoryTradeView: FC<InventoryTradeViewProps> = props =>
}) } }) }
</NitroCardGridView> </NitroCardGridView>
</div> </div>
<div className="d-flex flex-column col-4"> <div className="col-8 row mx-0">
<div className="badge bg-primary w-100 p-1 mb-1 me-1">{ LocalizeText('inventory.trading.you') }</div> <div className="d-flex flex-column col-6">
<NitroCardGridView columns={ 3 }> <div className="badge bg-primary w-100 p-1 mb-1 me-1">{ LocalizeText('inventory.trading.you') }</div>
{ Array.from(Array(MAX_ITEMS_TO_TRADE), (e, i) => <NitroCardGridView columns={ 3 }>
{ { Array.from(Array(MAX_ITEMS_TO_TRADE), (e, i) =>
const item = (tradeData.ownUser.items.getWithIndex(i) || null); {
const item = (tradeData.ownUser.items.getWithIndex(i) || null);
if(!item) return <NitroCardGridItemView key={ i } />; if(!item) return <NitroCardGridItemView key={ i } />;
return ( return (
<NitroCardGridItemView key={ i } itemActive={ (item === selectedGroupItem) } itemImage={ item.iconUrl } itemCount={ item.getTotalCount() } itemUnique={ item.stuffData.isUnique } itemUniqueNumber={ item.stuffData.uniqueNumber } onClick={ event => setSelectedGroupItem(item) }> <NitroCardGridItemView key={ i } itemActive={ (item === selectedGroupItem) } itemImage={ item.iconUrl } itemCount={ item.getTotalCount() } itemUnique={ item.stuffData.isUnique } itemUniqueNumber={ item.stuffData.uniqueNumber } onClick={ event => setSelectedGroupItem(item) }>
{ (item === selectedGroupItem) && { (item === selectedGroupItem) &&
<button className="btn btn-danger btn-sm trade-button left" onClick={ event => removeItem(item) }> <button className="btn btn-danger btn-sm trade-button left" onClick={ event => removeItem(item) }>
<i className="fas fa-chevron-left" /> <i className="fas fa-chevron-left" />
</button> } </button> }
</NitroCardGridItemView> </NitroCardGridItemView>
); );
}) } }) }
</NitroCardGridView> </NitroCardGridView>
</div> </div>
<div className="d-flex flex-column col-4"> <div className="d-flex flex-column col-6">
<div className="badge bg-primary w-100 p-1 mb-1 me-1">{ tradeData.otherUser.userName }</div> <div className="badge bg-primary w-100 p-1 mb-1 me-1">{ tradeData.otherUser.userName }</div>
<NitroCardGridView columns={ 3 }> <NitroCardGridView columns={ 3 }>
{ Array.from(Array(MAX_ITEMS_TO_TRADE), (e, i) => { Array.from(Array(MAX_ITEMS_TO_TRADE), (e, i) =>
{ {
const item = (tradeData.otherUser.items.getWithIndex(i) || null); const item = (tradeData.otherUser.items.getWithIndex(i) || null);
if(!item) return <NitroCardGridItemView key={ i } />; if(!item) return <NitroCardGridItemView key={ i } />;
return <NitroCardGridItemView key={ i } itemActive={ (item === selectedGroupItem) } itemImage={ item.iconUrl } itemCount={ item.getTotalCount() } itemUnique={ item.stuffData.isUnique } itemUniqueNumber={ item.stuffData.uniqueNumber } onClick={ event => setSelectedGroupItem(item) } />; return <NitroCardGridItemView key={ i } itemActive={ (item === selectedGroupItem) } itemImage={ item.iconUrl } itemCount={ item.getTotalCount() } itemUnique={ item.stuffData.isUnique } itemUniqueNumber={ item.stuffData.uniqueNumber } onClick={ event => setSelectedGroupItem(item) } />;
}) } }) }
</NitroCardGridView> </NitroCardGridView>
</div> </div>
<div className="d-flex col-8 offset-4"> <div className="d-flex col-12 bg-muted">
plz plz
</div>
</div> </div>
</div> </div>
); );