Skip to content

Conversation

nuno-vieira
Copy link
Member

@nuno-vieira nuno-vieira commented Feb 27, 2025

🔗 Issue Link

https://linear.app/stream/issue/IOS-713/add-moderation-flow-bounce-to-swiftui

🎯 Goal

Adds support for bounced message alert actions. This new UI is aligned with UIKit and other platforms, including the Figma design files. In order to avoid introducing a breaking change, a new MessageListConfig.bouncedMessagesAlertActionsEnabled has been introduced.

🧪 Testing

Pre-condition:
The following git patch should be applied to include the environment for bounced messages:
bounce-demo.patch

Scenario:

  1. Send "each me on my phone +38970555333" message (Without the "r" word)
  2. Should show an error indicator
  3. Long tap the message
  4. Should show the bounced message alert actions:
    • Tapping "Send Anyway" should block the message
    • Tapping "Edit Message" should edit the message
    • Tapping "Delete Message" should delete the message
    • Tapping "Cancel" should cancel the alert

🎨 Changes

☑️ Checklist

  • I have signed the Stream CLA (required)
  • Changelog is updated with client-facing changes
  • New code is covered by unit tests
  • Affected documentation updated (docusaurus, tutorial, CMS (task created)

@nuno-vieira nuno-vieira requested a review from a team as a code owner February 27, 2025 00:47
@Stream-SDK-Bot
Copy link
Collaborator

Stream-SDK-Bot commented Feb 27, 2025

SDK Size

title develop branch diff status
StreamChatSwiftUI 7.6 MB 7.6 MB +4 KB 🟢

}
}

public private(set) var bouncedMessage: ChatMessage?
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Shouldn't this be @Published?

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

At the moment I don't need it to be, but could be useful for customers maybe 🤔

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Done

isMessageEditedLabelEnabled: Bool = true,
markdownSupportEnabled: Bool = true,
userBlockingEnabled: Bool = false,
bouncedMessagesAlertActionsEnabled: Bool = false,
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

We can use true here.

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Done

Copy link

Quality Gate Failed Quality Gate failed

Failed conditions
25.5% Coverage on New Code (required ≥ 80%)

See analysis details on SonarQube Cloud

Copy link
Contributor

@laevandus laevandus left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

✅ Looks great!

@nuno-vieira nuno-vieira merged commit e6be9e2 into develop Feb 27, 2025
11 of 12 checks passed
@nuno-vieira nuno-vieira deleted the add/bounce-moderation-ui-support branch February 27, 2025 13:36
@Stream-SDK-Bot Stream-SDK-Bot mentioned this pull request Feb 28, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants