Link Previews, Custom Message Actions in the Flutter SDK, and More!

We just added Link Previews to TalkJS.

For most websites, the preview will show the title and a description of the page, but for media sites like YouTube, we'll embed the media right inside the message.

If you haven't made any changes to the UserMessage or SystemMessage component of the theme you use in TalkJS, they should start working automatically. If you did already change these templates, head over to our docs to learn how to add link previews to your theme.

Improvements to the Flutter SDK

The Flutter SDK also has some new goodies in store:

  • The Chatbox and ConversationList widget now accepts an onLoadingStateChanged parameter, which can notify you when the widget's content has fully loaded.
  • The Chatbox widget now takes an onCustomMessageAction handler, which you can use to respond when the user triggers custom message actions.
  • Fixed a scrolling issue when the Chatbox widget is placed in a bottom sheet.

Easily Set Up a Custom Domain for Emails 📧

For a long time now, TalkJS has let you use your own domain for sending emails, and handling email replies, but up until recently, this required contacting support. Now, you can easily do this yourself.

To add a custom email domain, click the account menu in the top right of the TalkJS dashboard, then click "Email domains". After adding the domain, click "details". You'll see some instructions on how to set up the necessary DNS records. Lastly, you'll want to go to the Settings page of your dashboard, and under Email Domain, select the domain you just added.

Bugfixes 🐞 

We've fixed several bugs since our last changelog entry, including:

  • Fixed an issue where flag emoji wouldn't show up on Windows in most browsers
  • Fixed an issue where in dark themes, the scroll bar wasn't visible.
  • Fixed an issue where we sometimes sent the same email notification multiple times

An Eventful Release

Custom Message Actions


We added the ability to add custom actions to the message menu. This lets you build features like reporting, favouriting or quoting messages. When a user selects a custom message action, an event is triggered in the JavaScript SDK. Check out our documentation on message actions for more info.

New event handlers in the JS SDK

The TalkJS JavaScript SDK emits events in many situations, so you can react to things that happen within our systems or in the chat UI. For instance, we fire an event when a conversation is selected in the inbox. The code to listen for such an event used to look like this: 

inbox.on("conversationSelected", function(event) {
  console.log(event);
});

This style of event handlers is now deprecated. Instead, you can now this:

inbox.onConversationSelected(function(event) {
  console.log(event);
});

These new event methods return a Subscription object that you can use to unsubscribe from events. This replaces the "off()" methods, which are now deprecated too. We never want to break existing code, so even though they're deprecated, the old methods will always continue to work.


For a full list of deprecated methods and their alternatives, see the deprecated methods sections on Session and its associated Unreads object, Chatbox, Popup and Inbox.

TalkJS for React Native v0.3.0

New Expo SDK

To properly support users of Expo's Managed Workflow, we have released a new package: @talkjs/expo. This package is identical to @talkjs/react-native except it has push notifications disabled. This is because the push notification libraries used have native code which make them incompatible with the Managed Workflow. 

If you need push notifications, you can send them from your own backend using our webhooks or you can use @talkjs/react-native and create a development build for your project using EAS Build or eject to the bare workflow.

The versioning for this new package will be identical to @talkjs/react-native

Better Notifications

We have changed the libraries we use for push notifications which has allowed us to greatly improve notifications, particularly on Android. Notifications are now shown as Conversations and grouped accordingly. Applies only to devices running Android 7.0 (API level 24) and up.

Image showing an two Android notifications representing two dummy conversations.

Images sent will also appear in the notifications. (Android only).

Image showing an Android notification that includes an image.

The function, registerPushNotificationHandlers, now allows for more configuration options when creating Android's Notification Channels. It also supports providing iOS notification related permissions you want your app to have.

As part of these changes you'll need to update your android/build.gradle file by adding the following block to the repositories section of allprojects:

maven {
url "$rootDir/../node_modules/@notifee/react-native/android/libs" }

Better Error Reporting

It should now be clearer what is wrong with your code. Should you encounter a scenario where an error has occurred but React Native's Logbox doesn't show, notify us via our livesupport.

Image showing an error in React Native from the TalkJS SDK

Other changes

  • Add support for Guest Access through the addition of asGuest prop in Chatbox.
  • Enable capturing of keyup events in Chatbox through the captureKeyboardEvents and onKeyup props.
  • Added the methods: getText and typeText to MessageField.
  • Changed oneOnOneId to also accept User Objects.
  • Changed showFeedHeader default to false.
  • Fix issue when user and/or conversation synchronization were disabled.
  • Deprecated the following props in ConversationList: feedConversationTitleMode, thirdParties, onBlur and onFocus.
  • Deprecated the following props in Chatbox: chatSubtitleMode, chatTitleMode, thirdParties, translateConversations, onBlur and onFocus.


Flutter SDK and Team Access to the Dashboard

Flutter SDK

Want to add chat functionality to your Flutter app? We made that a lot easier with the TalkJS Flutter SDK. To get started with it, check out our docs. With the release of this new SDK, we're expanding our support for mobile app platforms. We released an SDK for React Native last year, and we've always supported embedding TalkJS in a WebView in Ionic and native mobile applications.

Invite your team to the TalkJS dashboard

It used to be that one TalkJS account was linked to one TalkJS instance with a test and live environment. We've heard from many customers that they'd like to give members of their team access to the TalkJS dashboard, without needing to share login details. Now you can!

If you open the account menu in the top right of the dashboard, you'll see some new items. The first set of menu items is related to your projectwhich is what we call these TalkJS instances now. Each project still has a test environment and a live environment. Billing settings are also saved on a per-project bases.

If you click Manage members, you'll be able to invite your team members to your project. We've also created a set of roles that can limit which sections of the dashboard they can access.

On that same page you'll be able to see and manage current project members and pending invitations.

An account can be associated with multiple projects now too. So if you'd like to make another project to have an extra separate environment for staging or testing, or you work in an agency where you use TalkJS with multiple clients, you can create new projects under the same account.

Bug Fixes:

  • Fixed an issue where conversations with ids containing percentage signs or slashes could not be retrieved.
  • Fixed an issue where a conversation a user was removed from would still show up in the conversation list in the inbox.
  • Fixed an issue whee some attachment URLs would lead to a 403 response.
  • Fixed a bug in the TranslationToggled event causing the "conversation" attribute to hold an empty object.
  • Fixed an issue where removing a user from a conversation could cause an error if that user sent the most recent message, and the app was using a legacy theme.

Users can now delete messages

TalkJS lets you build a chat feature in hours instead of months.


Added:

  • Added a menu for message actions:

For now, "Delete message" is the only action in there, but watch this space for more to come.

If you've customised your theme, you'll need to modify the UserMessage or MessageBody component to add the MessageActionMenu component to it. The code for it should look something like this:

<ActionMenu class="action-menu">
  <Icon type="horizontalDots" />
</ActionMenu>

Feel free to reach out to customer support if you need help setting it up.

If there are no actions that the current user has permission to perform on a message, then the menu won't show up at all there. Speaking of permissions...

  • Added a message permissions section to roles. In this section, you can give permission to users with this role to perform actions on their own messages, all messages or no messages at all. To match the behaviour of your existing roles, the deletion permission has been set to "None". For newly created roles, it'll default to "Own", so that users can delete their own messages.

Fixed:

  • Fixed an issue where removing a participant from a conversation could cause problems when loading the inbox for other participants.
  • Fixed an issue where a conversation could still show up in a user's inbox after being deleted. No more zombie conversations!

React Native SDK:

  • Added a ConversationList component. It works just like the conversation list in our Inbox for the JavaScript SDK.
  • Added the messageField property to the Chatbox component
  • Fix bug in ConversationBuilder.setAttributes that prevented setting a value to null or undefined after previously having given it a value.
  • (iOS): Fix push notification registration token not getting received.
  • (iOS): Fix zooming when messageField is focused.

🎄Happy holidays from the TalkJS team!

Keyboard events

TalkJS lets you build a chat feature in hours instead of months.

Added

Improved

  • Bugfix: Users sporadically unable to send messages after seeing "Conversation not found" or creating a conversation in parallel with loading a chat UI
  • Bugfix: when enterSendsMessage is true, pressing enter did not inserts a newline
  • Security improvements

React Native SDK

New We have some exciting news! We have shipped a React Native SDK 😄.

Prior to this release, getting TalkJS running in React Native applications required developers to perform multiple tasks like creating an HTML file for the webview, passing parameters from the app to the JavaScript running in the webview and sometimes even adding handlers so the code in the webview could call back to the app.

With the React Native SDK you can get TalkJS running in your React Native application with a few lines of code:

<TalkRn.Session appId='YOUR_APP_ID' me={me}>
  <TalkRn.Chatbox conversationBuilder={conversationBuilder} />
</TalkRn.Session>

The new SDK makes it easier to use TalkJS in React Native applications by providing React Native Components that will feel natural to anyone using React Native.

Developers will now write significantly less code, save time and also make their code less error-prone. Additionally by using the SDK developers are guaranteed of backwards compatibility, meaning their code will always run even as TalkJS evolves.

So go ahead and check out our React Native Getting Started Guide.

We can't wait to see the cool stuff you are building!

 

New Conversation List Item theme component, Push notification improvements, message.deleted add to webhooks, added idempotency keys


Added

Conversation List Item component: Theme your inbox list items with the new component.

Idempotency keys: Ensure exactly-once delivery of messages - Read more.

Webhooks: message.deleted added to the webhooks list in the dashboard.

API: Fully delete participants when leaving a conversation - Read more.

Push notification tester: You can now test your push notifications via the dashboard UI.

Improved

Android Push Notifications: Priority changed to high, which helps apps that aren't running in the background.

Emojis 😲: Updated to include newer emojis.

Dashboard Settings: Improved layout to give saving settings more visible.

Improved UX for autoscrolling new messages.

Security and performance improvements.

Fixed

System messages suppressed in emails: Fixed a bug where system messages containing contact information were incorrectly being suppressed.

Show Previous EntriesShow Previous Entries