Skip to content

v6.5.0

Latest

Choose a tag to compare

@raj-cometchat raj-cometchat released this 02 Dec 12:36
b363155

New

  • Added CometChatLayoutDirection with the values auto, ltr and rtl to set the direction the UI Kit lays out in, separately from the app's language. Set it for the whole UI Kit with UIKitSettingsBuilder..layoutDirection, change it at runtime with CometChatUIKit.setLayoutDirection, and read it with CometChatUIKit.layoutDirection. The default, auto, follows the app's direction, so an app with an Arabic locale is right to left with no extra code.
  • Added a layoutDirection parameter to every screen component (conversations, users, groups, group members, message header, message list, message composer, threaded header, message information, pinned messages, saved messages, search, notification feed, AI assistant chat history, call buttons, call logs, outgoing call and ongoing call). It overrides the global setting for that component and everything inside it; leave it null to inherit.
  • Added the newLabel, notificationFeedEmptyTitle and notificationFeedEmptySubtitle translations in all 18 languages.
  • Added a Language and direction option to the sample app's profile menu, with a Kit direction switch (Auto, LTR, RTL) and a language picker, so integrators can try every combination. The sample app's own screens follow the chosen direction.

Enhancements

  • Mirrored every screen component in right-to-left layouts: avatars, titles, timestamps, badges, receipts, buttons, message bubbles, menus, sheets and swipe actions move to the opposite side. Sent messages sit on the left and received messages on the right.
  • Opened dialogs, bottom sheets, menus, snack bars and the screens the UI Kit pushes (media viewer, pinned messages, message actions) in the direction of the component that opened them, instead of the app's direction.
  • Kept audio and video players, including voice notes and the recorder, left to right in every language, as the design specifies.
  • Flipped directional icons in RTL following the design's rules. Arrows such as back, send, reply, reply in thread and call direction flip on every platform; the video camera, copy, chat and sticker icons flip on Android and web and stay as drawn on iOS and macOS.
  • Made each line of a message read in its own direction, decided by its first letter, so an English line in an Arabic chat reads left to right. Names, mentions and numbers keep their order inside the surrounding text, and a mention always reads @name.
  • Made the message composer follow the direction of the line the cursor is on. On iOS, the keyboard's language sets the direction while typing.
  • Showed dates, times, counts, durations and file sizes with Arabic digits when the UI Kit's language is Arabic. Sentences the UI Kit writes itself keep their language's word order, so an English app laid out RTL keeps English dates and punctuation in place.
  • Updated the new-messages divider to a line with a "New" label at its end, matching the design.
  • Aligned the Arabic translations with the design's wording across the UI Kit, and added Arabic for strings that previously fell back to English.
  • Placed the message action menu icon next to its text on every platform, as the design shows. On iOS, the icon previously sat at the far end of the row in both directions.
  • Moved the poll option drag handle to the start of each option row: left in left-to-right layouts and right in right-to-left layouts.
  • Kept the ellipsis at the end of cut-off text in its own reading direction, so a truncated English name, status line or mention description in an RTL screen ends in "…" after the text instead of before it.

Fixes

  • Fixed the notification feed's empty state showing English text in every language.
  • Fixed the notification feed's default header title showing a hard-coded English "Notifications" regardless of the app's language.
  • Fixed the scrolling status line in the message header measuring and scrolling its text left to right in RTL layouts, which cut off the start of the text.
  • Fixed several Arabic translations with the wrong meaning, including "OK", which read as "No", and the group type label, which read as "Write".

Breaking Changes

  • Changed the video camera and copy icons on Android and web to direction-following copies, so app widget tests that use find.byIcon(Icons.videocam) or find.byIcon(Icons.copy) no longer match them. Match on the glyph instead, for example find.byWidgetPredicate((w) => w is Icon && w.icon?.codePoint == Icons.copy.codePoint).
  • Added invisible Unicode isolates (U+2066 to U+2069) around the names, "You", typing text, mentions and dates the UI Kit places inside its own sentences, so they keep their own reading order. They are added only in an RTL layout or around right-to-left text, so LTR apps with left-to-right text get the same strings as in 6.4.0. RTL widget tests that match such text exactly, for example find.text('Bob:'), no longer match it. Use find.textContaining or include the isolates, for example find.text('\u2068Bob\u2069:').