UI fixes, adds blanket impls of buy/sell signals

This commit is contained in:
2019-08-01 21:57:47 +02:00
parent f1d088596d
commit e56c8df121
6 changed files with 70 additions and 19 deletions

View File

@@ -37,7 +37,7 @@
v-show="!playerIsGroup">
<a @click="switchView('player')">Mon coffre</a></li>
<li :class="{'is-active': activeView == 'adding' }">
<a @click="switchView('adding')">
<a class="has-text-grey-light" @click="switchView('adding')">
+ {{ playerIsGroup ? 'Nouveau Loot' : 'Acheter' }}
</a>
</li>
@@ -49,7 +49,8 @@
<h2 v-show="playerIsGroup">ItemInput</h2>
<Chest
:items="playerIsGroup ? [] : shopInventory"
:perms="playerIsGroup ? {} : { canBuy: true }">
:perms="playerIsGroup ? {} : { canBuy: true }"
@buy="(data) => { switchView('player'); actions.buyItems(data); }">
</Chest>
</template>
<Chest v-else
@@ -58,6 +59,7 @@
canGrab: !(showPlayerChest || playerIsGroup),
canSell: showPlayerChest || playerIsGroup
}"
@sell="actions.sellItems"
@claim="actions.putClaim"
@unclaim="actions.withdrawClaim">
</Chest>