• Home
  • Features
  • Pricing
  • Docs
  • Announcements
  • Sign In

Freegle / iznik-nuxt3 / f1b2e232-33ec-457b-9de8-c38d9a34f62e

28 Nov 2025 11:02PM UTC coverage: 44.781% (+1.2%) from 43.578%
f1b2e232-33ec-457b-9de8-c38d9a34f62e

push

circleci

actions-user
Auto-merge production to app-ci-fd (daily scheduled)

Automated merge from production branch after successful tests.

🤖 Automated by GitHub Actions

3197 of 7643 branches covered (41.83%)

Branch coverage included in aggregate %.

9 of 9 new or added lines in 1 file covered. (100.0%)

112 existing lines in 11 files now uncovered.

3470 of 7245 relevant lines covered (47.9%)

12.42 hits per line

Source File
Press 'n' to go to next uncovered line, 'b' for previous

40.98
/components/ChatMessageDateRead.vue
1
<template>
2
  <div
3
    v-if="
4
      !chatmessage?.sameasnext ||
5
      last ||
6
      chatmessage?.bymailid ||
7
      chatmessage?.gap
8
    "
9
    class="text-muted fontsize mb-1"
10
  >
11
    <div v-if="!messageIsFromCurrentUser">
12
      <span
13
        class="chat__dateread--theirs"
14
        :title="datetimeshort(chatmessage?.date)"
2!
15
      >
16
        {{ timeadapt(chatmessage?.date) }}
6!
17
      </span>
18
      <b-badge
19
        v-if="chatmessage?.replyexpected && !chatmessage?.replyreceived"
×
20
        variant="danger"
21
        class="ml-1"
22
      >
23
        RSVP - reply expected
24
      </b-badge>
×
25
    </div>
26
    <div v-else class="d-flex justify-content-end chat__dateread--mine">
27
      <span v-if="chatmessage?.seenbyall" title="This message has been read.">
28
        <v-icon icon="check" class="text-success" />
29
      </span>
20!
30
      <span
31
        v-else-if="chatmessage?.mailedtoall"
32
        title="This message has been sent out by email from our system."
33
      >
34
        <v-icon icon="envelope" />
35
      </span>
36
      <span
37
        v-else-if="
10!
38
          mod &&
39
          chat &&
40
          chat.chattype === 'User2Mod' &&
41
          otheruser &&
42
          otheruser.settings &&
43
          otheruser.settings.notifications &&
44
          !otheruser.settings.notifications.email
45
        "
46
        title="This freegler normally has email notifications turned off.  We always email messages from mods though."
47
      >
48
        <v-icon icon="envelope" class="text-danger" />
49
      </span>
50
      <span
51
        v-else
52
        title="This message has been delivered in Chat.  Depending on the other freegler's settings it may also be sent out by email soon - then this would turn into a little envelope."
53
      >
54
        <v-icon icon="check" class="text-muted" />
55
      </span>
56
      <span v-if="chat.chattype === 'User2Mod'" class="ml-1">
10!
57
        <span v-if="chatmessage?.userid === me.id"> You </span>
58
        <span v-else-if="othermodname">
×
59
          {{ othermodname }}
60
        </span>
61
        <span v-else>
62
          <v-icon icon="hashtag" class="text-muted fa-0-8x" />{{
63
            chatmessage?.userid
×
64
          }}
65
        </span>
66
        sent this
67
      </span>
68
      <span v-if="chatmessage?.reviewrequired" class="text-danger small">
10!
69
        Pending review
70
      </span>
71
      <span :title="datetimeshort(chatmessage?.date)" class="ml-1">{{
10!
72
        timeadapt(chatmessage?.date)
30!
73
      }}</span>
74
      <b-badge
75
        v-if="chatmessage?.replyexpected && !chatmessage?.replyreceived"
×
76
        variant="danger"
77
        class="ml-1"
78
      >
79
        RSVP - reply requested
80
      </b-badge>
×
81
    </div>
82
  </div>
83
</template>
84
<script setup>
85
import { useUserStore } from '~/stores/user'
86
import { useChatMessageBase } from '~/composables/useChat'
87
import { datetimeshort, timeadapt } from '~/composables/useTimeFormat'
88
import { ref, computed, onMounted } from '#imports'
89
import { useMe } from '~/composables/useMe'
90

91
const props = defineProps({
4✔
92
  chatid: {
93
    type: Number,
94
    required: true,
95
  },
96
  id: {
97
    type: Number,
98
    required: true,
99
  },
100
  pov: {
101
    type: Number,
102
    required: false,
103
    default: null,
104
  },
105
  last: {
106
    type: Boolean,
107
    required: false,
108
    default: false,
109
  },
110
})
111

112
const userStore = useUserStore()
4✔
113
const { me, mod } = useMe()
4✔
114

115
// Use ChatBase functionality via composable
116
const { chat, otheruser, chatmessage, messageIsFromCurrentUser } =
4✔
117
  useChatMessageBase(props.chatid, props.id, props.pov)
118

119
// Data properties
120
const chatMessageUser = ref(null)
4✔
121

122
// Computed properties
123
const othermodname = computed(() => {
4✔
UNCOV
124
  return chatMessageUser.value?.displayname
×
125
})
126

127
// Methods
128
// Load chatMessageUser data
129
onMounted(async () => {
4✔
130
  if (chatmessage.value?.userid) {
4!
131
    await userStore.fetch(chatmessage.value.userid)
4✔
132
    chatMessageUser.value = userStore.byId(chatmessage.value.userid)
4✔
133
  }
134
})
135
</script>
136
<style scoped lang="scss">
137
@import 'bootstrap/scss/functions';
138
@import 'bootstrap/scss/variables';
139
@import 'bootstrap/scss/mixins/_breakpoints';
140

141
.chat__dateread--theirs {
142
  padding-left: 40px;
143
  margin-bottom: 5px;
144
}
145

146
.chat__dateread--mine {
147
  padding-right: 40px;
148
  padding-left: 10px;
149
  margin-bottom: 5px;
150
}
151

152
.fontsize {
153
  font-size: 0.7em;
154

155
  @include media-breakpoint-up(md) {
156
    font-size: 0.875em;
157
  }
158
}
159
</style>
STATUS · Troubleshooting · Open an Issue · Sales · Support · CAREERS · ENTERPRISE · START FREE · SCHEDULE DEMO
ANNOUNCEMENTS · TWITTER · TOS & SLA · Supported CI Services · What's a CI service? · Automated Testing

© 2026 Coveralls, Inc