Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Improve message quoting #233

Merged
merged 10 commits into from
Jun 8, 2024
Merged
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Next Next commit
Fix colors
easafe committed Jun 8, 2024

Verified

This commit was created on GitHub.com and signed with GitHub’s verified signature. The key has expired.
commit 092c9bcbe9c6c620746f034762397c1d46faf691
10 changes: 8 additions & 2 deletions src/Client/css/im.css
Original file line number Diff line number Diff line change
@@ -1015,11 +1015,17 @@ svg.toolbar-action {
}

.user-menu.in-message {
background-color: #373737;
background-color: #212120;
right:10px;
top:32px;
}

.incoming-message .message-context-menu.outer-user-menu {
background-color: #373737 !important;
}

.user-menu.in-message.menu-up {
top: -82px;
top: -92px;
}

.modal-menu .back {
3 changes: 1 addition & 2 deletions src/Server/Im/Database.purs
Original file line number Diff line number Diff line change
@@ -281,8 +281,7 @@ insertMessage loggedUserId recipient temporaryId content = SD.withTransaction $
insertKarma ∷ ∀ r. Int → Int → Tuple Int Int → BaseEffect { pool ∷ Pool | r } Unit
insertKarma loggedUserId userId (Tuple senderKarma recipientKarma)
| senderKarma <= 0 && recipientKarma <= 0 = pure unit
| otherwise = do
liftEffect $ EC.log $ "karma turn: users " <> show loggedUserId <> " and " <> show userId <> " making " <> show senderKarma <> " and " <> show recipientKarma
| otherwise =
SD.withTransaction $ \connection → do
when (senderKarma > 0) (SD.executeWith connection $ insert # into karma_histories (_amount /\ _target) # values (senderKarma /\ loggedUserId))
when (recipientKarma > 0) (SD.executeWith connection $ insert # into karma_histories (_amount /\ _target) # values (recipientKarma /\ userId))