mirror of
https://github.com/HabitRPG/habitica.git
synced 2025-12-15 05:37:22 +01:00
* client: semantic ui -> bootstrap 4 and less -> scss * start porting components to boostrap * port header, start porting menu * port loading screen * port most of the menu * port secondary menus * port guilds and stable * disable tavern for now, port inbox * typo * put back old tavern code
36 lines
742 B
Vue
36 lines
742 B
Vue
<template lang="pug">
|
|
.row
|
|
.col-12
|
|
h2(v-once) {{ $t('inbox') }}
|
|
.card(v-for="conversation in conversations")
|
|
.card-block
|
|
router-link(:to="{ name: 'conversation', params: { id: conversation.fromUserId } }")
|
|
| {{ conversation.from }}
|
|
|
|
</template>
|
|
|
|
<script>
|
|
export default {
|
|
data () {
|
|
// @TODO: Abstract to Store
|
|
let messages = [
|
|
{
|
|
from: 'Paglias',
|
|
fromUserId: 1234,
|
|
to: 'TheHollidayInn',
|
|
message: 'I love the Gang of Four',
|
|
},
|
|
];
|
|
|
|
let conversations = {};
|
|
for (let message of messages) {
|
|
if (!conversations[message.fromUserId]) conversations[message.fromUserId] = message;
|
|
}
|
|
|
|
return {
|
|
conversations,
|
|
};
|
|
},
|
|
};
|
|
</script>
|