6565 @keydown.space.prevent =" $emit('toggle-expand', $event)" >
6666 <div class =" envelope__header__left__sender-subject-tags" >
6767 <div class =" sender" :class =" { 'sender--expanded': expanded }" >
68+ <NcChip
69+ :title =" mailboxName (mailbox )"
70+ variant="tertiary"
71+ no-close="true">
72+ <MailboxIcon
73+ :account =" account "
74+ :mailbox =" mailbox " />
75+ </NcChip >
76+
6877 {{ envelope.from && envelope.from[0] ? envelope.from[0].label : '' }}
6978 </div >
7079 <NcButton
@@ -390,6 +399,7 @@ import { loadState } from '@nextcloud/initial-state'
390399import moment from ' @nextcloud/moment'
391400import { generateUrl } from ' @nextcloud/router'
392401import { NcActionButton , NcButton } from ' @nextcloud/vue'
402+ import NcChip from ' @nextcloud/vue/components/NcChip'
393403import { mapStores } from ' pinia'
394404import NcActions from ' @nextcloud/vue/components/NcActions'
395405import NcActionText from ' @nextcloud/vue/components/NcActionText'
@@ -411,6 +421,7 @@ import ConfirmModal from './ConfirmationModal.vue'
411421import Error from ' ./Error.vue'
412422import EventModal from ' ./EventModal.vue'
413423import JunkIcon from ' ./icons/JunkIcon.vue'
424+ import MailboxIcon from ' ./icons/MailboxIcon.vue'
414425import MailFilterFromEnvelope from ' ./mailFilter/MailFilterFromEnvelope.vue'
415426import MenuEnvelope from ' ./MenuEnvelope.vue'
416427import Message from ' ./Message.vue'
@@ -426,6 +437,7 @@ import importantSvg from '../../img/important.svg'
426437import { isPgpText } from ' ../crypto/pgp.js'
427438import { matchError } from ' ../errors/match.js'
428439import NoTrashMailboxConfiguredError from ' ../errors/NoTrashMailboxConfiguredError.js'
440+ import { translate as translateMailboxName } from ' ../i18n/MailboxTranslator.js'
429441import logger from ' ../logger.js'
430442import { buildRecipients as buildReplyRecipients } from ' ../ReplyBuilder.js'
431443import { smartReply } from ' ../service/AiIntergrationsService.js'
@@ -459,8 +471,10 @@ export default {
459471 RecipientBubble,
460472 NcActionButton,
461473 NcButton,
474+ NcChip,
462475 Error ,
463476 IconFavorite,
477+ MailboxIcon,
464478 JunkIcon,
465479 MessageLoadingSkeleton,
466480 MenuEnvelope,
@@ -489,16 +503,6 @@ export default {
489503 type: Object ,
490504 },
491505
492- mailboxId: {
493- required: false ,
494- type: [
495- String ,
496- Number ,
497- ],
498-
499- default: undefined ,
500- },
501-
502506 expanded: {
503507 required: false ,
504508 type: Boolean ,
@@ -702,7 +706,7 @@ export default {
702706 },
703707
704708 mailbox () {
705- return this .mainStore .getMailbox (this .mailboxId )
709+ return this .mainStore .getMailbox (this .envelope . mailboxId )
706710 },
707711
708712 archiveMailbox () {
@@ -1071,6 +1075,10 @@ export default {
10711075 })
10721076 },
10731077
1078+ mailboxName () {
1079+ return translateMailboxName (this .mailbox )
1080+ },
1081+
10741082 async unsubscribeViaOneClick () {
10751083 try {
10761084 this .unsubscribing = true
@@ -1213,7 +1221,9 @@ export default {
12131221
12141222< style lang= " scss" scoped>
12151223 .sender {
1224+ display: flex;
12161225 margin- inline- start: calc (var (-- default- grid- baseline) * 3 );
1226+ gap: var (-- default- grid- baseline);
12171227
12181228 & -- expanded {
12191229 color: var (-- color- text- maxcontrast);
@@ -1410,7 +1420,7 @@ export default {
14101420 }
14111421
14121422 .subline {
1413- margin- inline- start: 8px ;
1423+ margin- inline- start: calc ( var ( -- default - grid - baseline) * 3 ) ;
14141424 color: var (-- color- text- maxcontrast);
14151425 cursor: default;
14161426 overflow: hidden;
0 commit comments