From 93ee98717d961f1d987fc34bfc5e3fac5c8caa19 Mon Sep 17 00:00:00 2001 From: Paul Date: Sat, 10 Jul 2021 18:06:21 +0100 Subject: [PATCH] Fix: Session icon alignment. Fix: i18n blocked messages / users. --- external/lang | 2 +- .../common/messaging/attachments/MessageReply.tsx | 6 ++++-- src/pages/channels/messaging/MessageRenderer.tsx | 7 ++++++- src/pages/settings/panes/Panes.module.scss | 6 ++++-- 4 files changed, 15 insertions(+), 6 deletions(-) diff --git a/external/lang b/external/lang index 2054052c..3931bf87 160000 --- a/external/lang +++ b/external/lang @@ -1 +1 @@ -Subproject commit 2054052c791ff2396dcbde68ae257fa13a93ab6c +Subproject commit 3931bf87e94264d92556a2f3ee96c6051be75b02 diff --git a/src/components/common/messaging/attachments/MessageReply.tsx b/src/components/common/messaging/attachments/MessageReply.tsx index 50f605df..6c5a2486 100644 --- a/src/components/common/messaging/attachments/MessageReply.tsx +++ b/src/components/common/messaging/attachments/MessageReply.tsx @@ -6,7 +6,7 @@ import { Users } from "revolt.js/dist/api/objects"; import styled, { css } from "styled-components"; import { Text } from "preact-i18n"; -import { useEffect, useLayoutEffect, useState } from "preact/hooks"; +import { useLayoutEffect, useState } from "preact/hooks"; import { useRenderState } from "../../../../lib/renderer/Singleton"; @@ -157,7 +157,9 @@ export function MessageReply({ index, channel, id }: Props) { {user?.relationship === Users.Relationship.Blocked ? ( - <>Blocked User + <> + + ) : ( <> {message.author === SYSTEM_USER_ID ? ( diff --git a/src/pages/channels/messaging/MessageRenderer.tsx b/src/pages/channels/messaging/MessageRenderer.tsx index 483d0d8f..a8499877 100644 --- a/src/pages/channels/messaging/MessageRenderer.tsx +++ b/src/pages/channels/messaging/MessageRenderer.tsx @@ -3,6 +3,7 @@ import { Users } from "revolt.js/dist/api/objects"; import styled from "styled-components"; import { decodeTime } from "ulid"; +import { Text } from "preact-i18n"; import { memo } from "preact/compat"; import { useContext, useEffect, useState } from "preact/hooks"; @@ -116,7 +117,11 @@ function MessageRenderer({ id, state, queue, highlight }: Props) { function pushBlocked() { render.push( - {blocked} blocked messages + {" "} + , ); blocked = 0; diff --git a/src/pages/settings/panes/Panes.module.scss b/src/pages/settings/panes/Panes.module.scss index 42957ac7..0f1464c3 100644 --- a/src/pages/settings/panes/Panes.module.scss +++ b/src/pages/settings/panes/Panes.module.scss @@ -354,9 +354,11 @@ display: flex; gap: 12px; flex-grow: 1; + + svg { + vertical-align: auto; + } } - - } .entry {