@7365admin1/layer-common 4.5.1-staging.300 → 4.6.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +20 -4
- package/components/AreaChecklistHistoryLogs.vue +0 -81
- package/components/Chat/Bubbles.vue +30 -94
- package/components/Chat/Message.vue +67 -281
- package/components/Facility/BookingSetup.vue +0 -63
- package/components/FeedbackDetail.vue +1 -1
- package/components/HidIntercomManagement.vue +42 -145
- package/components/HidReaderUserRoster.vue +2 -32
- package/components/HidUserEnrollment.vue +212 -771
- package/components/InvitationClientForm.vue +1 -19
- package/components/ManageChecklistMain.vue +2 -34
- package/components/SwitchContext.vue +2 -46
- package/components/VisitorManagement.vue +5 -267
- package/components/WorkOrder/Detail.vue +1 -1
- package/composables/useCleaningPermission.ts +0 -5
- package/composables/useComment.ts +1 -9
- package/composables/useFacility.ts +0 -11
- package/composables/useHidAmico.ts +0 -73
- package/composables/useHidNavigation.ts +1 -25
- package/composables/useLandscapingPermission.ts +0 -5
- package/composables/useMechanicalElectricalPermission.ts +0 -6
- package/composables/usePeople.ts +0 -19
- package/composables/usePestControlPermission.ts +0 -5
- package/composables/usePoolMaintenancePermission.ts +0 -5
- package/composables/usePropertyPermission.ts +0 -5
- package/composables/useSecurityPermission.ts +0 -5
- package/package.json +1 -1
- package/types/cleaner-schedule.d.ts +0 -2
- package/types/comment.d.ts +0 -2
- package/types/facility.d.ts +0 -4
- package/types/people.d.ts +1 -4
- package/utils/materialSymbols.ts +0 -3
- package/components/HidProfileQrCode.vue +0 -323
- package/pages/[org]/[site]/access-mgmt/hid-qr-code/index.vue +0 -23
- package/utils/chat-sender.ts +0 -47
- package/utils/module-applications.ts +0 -146
package/CHANGELOG.md
CHANGED
|
@@ -1,5 +1,21 @@
|
|
|
1
1
|
# @iservice365/layer-common
|
|
2
2
|
|
|
3
|
+
## 4.6.0
|
|
4
|
+
|
|
5
|
+
### Minor Changes
|
|
6
|
+
|
|
7
|
+
- 40b7a6c: Add a search to both role dialogs, and stop Unselect All clearing what is hidden (R5).
|
|
8
|
+
|
|
9
|
+
A client builds a role out of up to 47 modules and about 127 actions inside a
|
|
10
|
+
modal. The search matches the names a person reads as well as the raw keys, so
|
|
11
|
+
"statements" and "soa" both find `SOA-mgmt`.
|
|
12
|
+
|
|
13
|
+
It filters the DISPLAY only — a permission ticked and then filtered out of view
|
|
14
|
+
is still ticked and still saved. Select All and Unselect All now act on the
|
|
15
|
+
visible set: with no search that is the whole catalogue, unchanged; with a search
|
|
16
|
+
active, Unselect All no longer discards every permission outside the filter,
|
|
17
|
+
which on the edit dialog would have been a role somebody is already using.
|
|
18
|
+
|
|
3
19
|
## 4.5.0
|
|
4
20
|
|
|
5
21
|
### Minor Changes
|
|
@@ -895,11 +911,11 @@
|
|
|
895
911
|
`utils/console-tier.ts` + `composables/useConsoleTier.ts` mirror the server's
|
|
896
912
|
own rule from two endpoints the console already calls, unprojected:
|
|
897
913
|
|
|
898
|
-
|
|
899
|
-
|
|
914
|
+
GET /api/members/user/:user/app/admin the Seven365 staff membership
|
|
915
|
+
GET /api/roles/id/:role that membership's role document
|
|
900
916
|
|
|
901
|
-
|
|
902
|
-
|
|
917
|
+
owner = member.type === "admin" && role.type === "admin" && role.default === true
|
|
918
|
+
staff = member.type === "admin" && role.type === "admin"
|
|
903
919
|
|
|
904
920
|
`role.default` is the marker because it is the only property of a platform
|
|
905
921
|
staff role no API caller can set - `role.controller.ts` validates create and
|
|
@@ -170,63 +170,6 @@
|
|
|
170
170
|
/>
|
|
171
171
|
</v-col>
|
|
172
172
|
</v-row>
|
|
173
|
-
|
|
174
|
-
<!-- The photos the technician took to complete the
|
|
175
|
-
unit. The API has always returned these ids on the
|
|
176
|
-
history record; nothing drew them, so the office
|
|
177
|
-
had no way to see the proof of work. -->
|
|
178
|
-
<v-row
|
|
179
|
-
v-if="unit.attachment?.length"
|
|
180
|
-
no-gutters
|
|
181
|
-
class="pb-2"
|
|
182
|
-
>
|
|
183
|
-
<v-col cols="12">
|
|
184
|
-
<div class="text-body-2 text-medium-emphasis mb-1">
|
|
185
|
-
Attached Photos ({{ unit.attachment.length }})
|
|
186
|
-
</div>
|
|
187
|
-
<div class="d-flex flex-wrap ga-2">
|
|
188
|
-
<v-img
|
|
189
|
-
v-for="id in unit.attachment"
|
|
190
|
-
:key="id"
|
|
191
|
-
:src="getFileUrl(id)"
|
|
192
|
-
width="72"
|
|
193
|
-
height="72"
|
|
194
|
-
cover
|
|
195
|
-
rounded="lg"
|
|
196
|
-
class="border-thin"
|
|
197
|
-
style="cursor: zoom-in; flex: 0 0 auto"
|
|
198
|
-
@click="openFullImage(getFileUrl(id))"
|
|
199
|
-
>
|
|
200
|
-
<template v-slot:placeholder>
|
|
201
|
-
<v-row
|
|
202
|
-
class="fill-height ma-0"
|
|
203
|
-
align="center"
|
|
204
|
-
justify="center"
|
|
205
|
-
>
|
|
206
|
-
<v-progress-circular
|
|
207
|
-
indeterminate
|
|
208
|
-
size="20"
|
|
209
|
-
color="grey-lighten-4"
|
|
210
|
-
/>
|
|
211
|
-
</v-row>
|
|
212
|
-
</template>
|
|
213
|
-
<template v-slot:error>
|
|
214
|
-
<v-row
|
|
215
|
-
class="fill-height ma-0"
|
|
216
|
-
align="center"
|
|
217
|
-
justify="center"
|
|
218
|
-
>
|
|
219
|
-
<v-icon
|
|
220
|
-
icon="mdi-image-broken"
|
|
221
|
-
size="24"
|
|
222
|
-
color="grey"
|
|
223
|
-
/>
|
|
224
|
-
</v-row>
|
|
225
|
-
</template>
|
|
226
|
-
</v-img>
|
|
227
|
-
</div>
|
|
228
|
-
</v-col>
|
|
229
|
-
</v-row>
|
|
230
173
|
</v-list-item>
|
|
231
174
|
|
|
232
175
|
<v-divider
|
|
@@ -243,22 +186,6 @@
|
|
|
243
186
|
</AppCard>
|
|
244
187
|
</v-col>
|
|
245
188
|
</v-row>
|
|
246
|
-
|
|
247
|
-
<v-dialog v-model="showLightbox" max-width="900">
|
|
248
|
-
<v-card class="screen-modal">
|
|
249
|
-
<v-card-actions class="pa-2 justify-end">
|
|
250
|
-
<v-btn
|
|
251
|
-
icon="mdi-close"
|
|
252
|
-
variant="text"
|
|
253
|
-
class="screen-modal__close"
|
|
254
|
-
@click="showLightbox = false"
|
|
255
|
-
/>
|
|
256
|
-
</v-card-actions>
|
|
257
|
-
<v-card-text class="screen-modal__body pa-2 pt-0">
|
|
258
|
-
<v-img :src="lightboxSrc" contain max-height="80vh" />
|
|
259
|
-
</v-card-text>
|
|
260
|
-
</v-card>
|
|
261
|
-
</v-dialog>
|
|
262
189
|
</template>
|
|
263
190
|
|
|
264
191
|
<script setup lang="ts">
|
|
@@ -300,14 +227,6 @@ watchEffect(() => {
|
|
|
300
227
|
}
|
|
301
228
|
});
|
|
302
229
|
|
|
303
|
-
const showLightbox = ref(false);
|
|
304
|
-
const lightboxSrc = ref("");
|
|
305
|
-
|
|
306
|
-
const openFullImage = (src: string) => {
|
|
307
|
-
lightboxSrc.value = src;
|
|
308
|
-
showLightbox.value = true;
|
|
309
|
-
};
|
|
310
|
-
|
|
311
230
|
const createdAt = ref<string>("N/A");
|
|
312
231
|
const createdBy = ref<string>("N/A");
|
|
313
232
|
const timeOut = ref<string>("N/A");
|
|
@@ -1,120 +1,62 @@
|
|
|
1
1
|
<template>
|
|
2
|
-
<v-card
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
elevation="0"
|
|
6
|
-
>
|
|
7
|
-
<v-row no-gutters align="start" class="flex-nowrap">
|
|
8
|
-
<v-col cols="auto" :class="isCurrentUser ? 'order-last ml-3' : 'mr-3'">
|
|
2
|
+
<v-card class="chat-bubble screen-card mb-2 pa-4" width="400" elevation="0">
|
|
3
|
+
<v-row no-gutters align="center">
|
|
4
|
+
<v-col cols="auto" class="mr-3">
|
|
9
5
|
<v-avatar class="chat-bubble__avatar" size="35">
|
|
10
|
-
|
|
11
|
-
sender with a profile picture got a blank 15px box instead of a
|
|
12
|
-
photo - and never fell through to their initials either. -->
|
|
13
|
-
<v-img v-if="avatarUrl" :src="avatarUrl" cover />
|
|
6
|
+
<v-img v-if="currentUser?.profile" width="15" height="15" />
|
|
14
7
|
<span v-else>{{ getNameInitials(senderName) }}</span>
|
|
15
8
|
</v-avatar>
|
|
16
9
|
</v-col>
|
|
17
10
|
|
|
18
|
-
<v-col class="
|
|
19
|
-
<
|
|
20
|
-
<
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
<div v-if="attachments?.length" class="d-flex flex-wrap ga-2 mt-2">
|
|
25
|
-
<v-img
|
|
26
|
-
v-for="file in attachments"
|
|
27
|
-
:key="file.id"
|
|
28
|
-
:src="getFileUrl(file.id)"
|
|
29
|
-
width="110"
|
|
30
|
-
height="90"
|
|
31
|
-
cover
|
|
32
|
-
rounded="lg"
|
|
33
|
-
class="border-thin"
|
|
34
|
-
style="cursor: zoom-in; flex: 0 0 auto"
|
|
35
|
-
@click="emit('preview', getFileUrl(file.id))"
|
|
36
|
-
>
|
|
37
|
-
<template #placeholder>
|
|
38
|
-
<v-row class="fill-height ma-0" align="center" justify="center">
|
|
39
|
-
<v-progress-circular
|
|
40
|
-
indeterminate
|
|
41
|
-
size="20"
|
|
42
|
-
color="grey-lighten-4"
|
|
43
|
-
/>
|
|
44
|
-
</v-row>
|
|
45
|
-
</template>
|
|
46
|
-
<template #error>
|
|
47
|
-
<v-row class="fill-height ma-0" align="center" justify="center">
|
|
48
|
-
<v-icon icon="mdi-image-broken" size="24" color="grey" />
|
|
49
|
-
</v-row>
|
|
50
|
-
</template>
|
|
51
|
-
</v-img>
|
|
52
|
-
</div>
|
|
11
|
+
<v-col class="d-flex flex-column">
|
|
12
|
+
<span class="chat-bubble__sender">{{ senderName }}</span>
|
|
13
|
+
<span class="chat-bubble__sub">{{ role }}</span>
|
|
14
|
+
</v-col>
|
|
15
|
+
</v-row>
|
|
53
16
|
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
</
|
|
17
|
+
<v-row no-gutters class="mt-1">
|
|
18
|
+
<v-col>
|
|
19
|
+
<span class="chat-bubble__text py-2">{{ message }}</span>
|
|
20
|
+
|
|
21
|
+
<v-row no-gutters justify="space-between" align="center" class="mt-1">
|
|
22
|
+
<v-col cols="auto">
|
|
23
|
+
<span class="chat-bubble__sub">{{ timestamp }}</span>
|
|
24
|
+
</v-col>
|
|
25
|
+
<v-col v-if="isCurrentUser" cols="auto" class="d-flex align-center">
|
|
26
|
+
<v-icon size="16" class="chat-bubble__sub mr-1"
|
|
27
|
+
>mdi-eye-outline</v-icon
|
|
28
|
+
>
|
|
29
|
+
<span class="chat-bubble__sub">{{ seenLabel }}</span>
|
|
30
|
+
</v-col>
|
|
31
|
+
</v-row>
|
|
57
32
|
</v-col>
|
|
58
33
|
</v-row>
|
|
59
34
|
</v-card>
|
|
60
35
|
</template>
|
|
61
36
|
|
|
62
37
|
<script setup lang="ts">
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
/**
|
|
66
|
-
* One message bubble, drawn the same way for both people in the conversation
|
|
67
|
-
* and matching the mobile apps' bubble field for field: avatar, sender, role,
|
|
68
|
-
* message, photos, time.
|
|
69
|
-
*
|
|
70
|
-
* It used to be a fixed `width="400"` card with no left/right distinction, an
|
|
71
|
-
* avatar that could not render a photo, and a "Seen" line that only the current
|
|
72
|
-
* user's own messages carried.
|
|
73
|
-
*/
|
|
74
|
-
const props = defineProps<{
|
|
38
|
+
defineProps<{
|
|
75
39
|
isCurrentUser: boolean;
|
|
76
40
|
message: string;
|
|
77
41
|
timestamp: string;
|
|
42
|
+
seenLabel?: string;
|
|
78
43
|
senderName: string;
|
|
79
44
|
role?: string;
|
|
80
|
-
attachments?: TAttachment[];
|
|
81
|
-
avatarId?: string;
|
|
82
45
|
}>();
|
|
83
46
|
|
|
84
|
-
const
|
|
85
|
-
|
|
47
|
+
const { currentUser } = useLocalAuth();
|
|
86
48
|
const { getNameInitials } = useUtils();
|
|
87
|
-
const { getFileUrl } = useFile();
|
|
88
|
-
|
|
89
|
-
const roleLabel = computed(() => formatSenderRole(props.role));
|
|
90
|
-
const avatarUrl = computed(() =>
|
|
91
|
-
props.avatarId ? getFileUrl(props.avatarId) : ""
|
|
92
|
-
);
|
|
93
49
|
</script>
|
|
94
50
|
|
|
95
51
|
<style scoped>
|
|
96
52
|
.chat-bubble {
|
|
97
53
|
font-family: var(--font-sans);
|
|
98
54
|
color: var(--text);
|
|
99
|
-
/* Was a fixed 400px, which is both too wide on a narrow panel and unable to
|
|
100
|
-
grow on a wide one. The thread caps the column instead. */
|
|
101
|
-
max-width: 100%;
|
|
102
|
-
}
|
|
103
|
-
|
|
104
|
-
/* Alignment alone is a weak signal on a panel this narrow, so the two sides
|
|
105
|
-
also differ in fill - the same distinction the mobile bubbles make. */
|
|
106
|
-
.chat-bubble--mine {
|
|
107
|
-
background: var(--hover);
|
|
108
|
-
}
|
|
109
|
-
|
|
110
|
-
.chat-bubble--theirs {
|
|
111
|
-
background: var(--card);
|
|
112
|
-
}
|
|
113
|
-
|
|
114
|
-
.chat-bubble__body {
|
|
115
|
-
min-width: 0;
|
|
116
55
|
}
|
|
117
56
|
|
|
57
|
+
/* Was `color="surface-variant"` with the initials at `text-h5`, i.e. a 24px
|
|
58
|
+
pair of letters in a 35px circle. The design's avatar is the tone wash with
|
|
59
|
+
the accent ink, and the initials fit inside it. */
|
|
118
60
|
.chat-bubble__avatar {
|
|
119
61
|
background: var(--hover);
|
|
120
62
|
color: var(--text2);
|
|
@@ -129,8 +71,6 @@ const avatarUrl = computed(() =>
|
|
|
129
71
|
|
|
130
72
|
.chat-bubble__text {
|
|
131
73
|
font-size: var(--fs-cell);
|
|
132
|
-
white-space: pre-wrap;
|
|
133
|
-
overflow-wrap: anywhere;
|
|
134
74
|
}
|
|
135
75
|
|
|
136
76
|
/* The role, the timestamp and the seen label were `text-grey`, `text-caption`
|
|
@@ -139,8 +79,4 @@ const avatarUrl = computed(() =>
|
|
|
139
79
|
font-size: var(--fs-chip);
|
|
140
80
|
color: var(--muted);
|
|
141
81
|
}
|
|
142
|
-
|
|
143
|
-
.chat-bubble__time {
|
|
144
|
-
text-align: right;
|
|
145
|
-
}
|
|
146
82
|
</style>
|