diff --git a/plugins/activity-resources/src/components/activity-message/ActivityMessageTemplate.svelte b/plugins/activity-resources/src/components/activity-message/ActivityMessageTemplate.svelte index 50eb3f2c33..c191522aa4 100644 --- a/plugins/activity-resources/src/components/activity-message/ActivityMessageTemplate.svelte +++ b/plugins/activity-resources/src/components/activity-message/ActivityMessageTemplate.svelte @@ -145,7 +145,7 @@ {:else}
{/if} -
+
{#if person} diff --git a/plugins/chunter-resources/src/components/ChannelScrollView.svelte b/plugins/chunter-resources/src/components/ChannelScrollView.svelte index 640e24369b..e322eac172 100644 --- a/plugins/chunter-resources/src/components/ChannelScrollView.svelte +++ b/plugins/chunter-resources/src/components/ChannelScrollView.svelte @@ -294,6 +294,10 @@ } async function updateSelectedDate () { + if (!withDates) { + return + } + if (scrollContentBox === undefined || scrollElement === undefined) { return } @@ -456,7 +460,7 @@ {#if startFromBottom}
{/if} - {#if selectedDate} + {#if withDates && selectedDate}
@@ -522,7 +526,9 @@ margin: 0 1.5rem; min-height: 4.375rem; height: auto; - display: contents; + display: flex; + flex-direction: column; + flex-shrink: 0; } .grower { diff --git a/plugins/chunter-resources/src/components/chat/ChannelAside.svelte b/plugins/chunter-resources/src/components/chat/ChannelAside.svelte index 9e069f246c..941eae24e8 100644 --- a/plugins/chunter-resources/src/components/chat/ChannelAside.svelte +++ b/plugins/chunter-resources/src/components/chat/ChannelAside.svelte @@ -31,7 +31,7 @@ const currentAccount = getCurrentAccount() - let members: Ref[] = [] + let members = new Set>() $: creatorPersonRef = object?.createdBy ? $personAccountByIdStore.get(object.createdBy as Ref)?.person @@ -42,19 +42,21 @@ function updateMembers (object: Channel | undefined) { if (object === undefined) { - members = [] + members = new Set() return } - members = object.members - .map((accountId) => { - const personAccount = $personAccountByIdStore.get(accountId as Ref) - if (personAccount === undefined) { - return undefined - } - return personAccount.person - }) - .filter((_id): _id is Ref => !!_id) + members = new Set( + object.members + .map((accountId) => { + const personAccount = $personAccountByIdStore.get(accountId as Ref) + if (personAccount === undefined) { + return undefined + } + return personAccount.person + }) + .filter((_id): _id is Ref => !!_id) + ) } async function changeMembers (personRefs: Ref[], object?: Channel) { @@ -85,13 +87,15 @@ return } - const personAccount = Array.from($personAccountByIdStore.values()).find((account) => account.person === personId) + const accounts = Array.from($personAccountByIdStore.values()) + .filter((account) => account.person === personId) + .map(({ _id }) => _id) - if (personAccount === undefined) { + if (accounts.length === 0) { return } - await leaveChannel(object, personAccount._id) + await leaveChannel(object, accounts) } function openSelectUsersPopup () { @@ -139,7 +143,7 @@
button:first-child') - this.textActivityContent = page.locator('div.activityMessage div.content div.content') + this.textActivityContent = page.locator('div.activityMessage div.content') this.linkInActivity = page.locator('div[id="activity:string:Activity"] a') this.inputCommentFile = page.locator('input#file') this.commentImg = page.locator('div.activityMessage div.content img')