fix: add/rename missing sub :current-chat/one-to-one-chat? (#19628)

Signed-off-by: yqrashawn <namy.19@gmail.com>
This commit is contained in:
yqrashawn 2024-04-15 17:10:12 +08:00 committed by GitHub
parent 82a8f9f44d
commit 32fc7b14e8
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
2 changed files with 7 additions and 1 deletions

View File

@ -30,7 +30,7 @@
(defn pinned-message
[{:keys [from quoted-message timestamp-str]}]
(let [[primary-name _] (rf/sub [:contacts/contact-two-names-by-identity from])
one-to-one-chat? (rf/sub [:current-chat/one-to-one-chat?])
one-to-one-chat? (rf/sub [:chats/current-chat-one-to-one?])
current-chat-color (rf/sub [:chats/current-chat-color])
contact-customization-color (rf/sub [:contacts/contact-customization-color-by-address from])]
[quo/system-message

View File

@ -241,6 +241,12 @@
:message-pin-enabled message-pin-enabled
:can-delete-message-for-everyone? can-delete-message-for-everyone?})))
(re-frame/reg-sub
:chats/current-chat-one-to-one?
:<- [:chats/current-raw-chat]
(fn [{:keys [chat-type]}]
(= chat-type constants/one-to-one-chat-type)))
(re-frame/reg-sub
:chats/photo-path
:<- [:contacts/contacts]