diff --git a/android/app/src/main/res/drawable-hdpi/livechat.png b/android/app/src/main/res/drawable-hdpi/livechat.png
new file mode 100644
index 0000000000..b2190ca738
Binary files /dev/null and b/android/app/src/main/res/drawable-hdpi/livechat.png differ
diff --git a/android/app/src/main/res/drawable-mdpi/livechat.png b/android/app/src/main/res/drawable-mdpi/livechat.png
new file mode 100644
index 0000000000..5047b8e50c
Binary files /dev/null and b/android/app/src/main/res/drawable-mdpi/livechat.png differ
diff --git a/android/app/src/main/res/drawable-xhdpi/livechat.png b/android/app/src/main/res/drawable-xhdpi/livechat.png
new file mode 100644
index 0000000000..64e12138a2
Binary files /dev/null and b/android/app/src/main/res/drawable-xhdpi/livechat.png differ
diff --git a/android/app/src/main/res/drawable-xxhdpi/livechat.png b/android/app/src/main/res/drawable-xxhdpi/livechat.png
new file mode 100644
index 0000000000..14e8a801b3
Binary files /dev/null and b/android/app/src/main/res/drawable-xxhdpi/livechat.png differ
diff --git a/android/app/src/main/res/drawable-xxxhdpi/livechat.png b/android/app/src/main/res/drawable-xxxhdpi/livechat.png
new file mode 100644
index 0000000000..6cc6f9071b
Binary files /dev/null and b/android/app/src/main/res/drawable-xxxhdpi/livechat.png differ
diff --git a/app/containers/RoomTypeIcon.js b/app/containers/RoomTypeIcon.js
index 0f377ce67d..6933f35827 100644
--- a/app/containers/RoomTypeIcon.js
+++ b/app/containers/RoomTypeIcon.js
@@ -32,6 +32,8 @@ const RoomTypeIcon = React.memo(({
return ;
} if (type === 'd') {
return ;
+ } if (type === 'l') {
+ return ;
}
return ;
});
diff --git a/app/lib/rocketchat.js b/app/lib/rocketchat.js
index 75d343c542..d173122d3c 100644
--- a/app/lib/rocketchat.js
+++ b/app/lib/rocketchat.js
@@ -949,7 +949,7 @@ const RocketChat = {
},
roomTypeToApiType(t) {
const types = {
- c: 'channels', d: 'im', p: 'groups'
+ c: 'channels', d: 'im', p: 'groups', l: 'channels'
};
return types[t];
},
diff --git a/app/notifications/push/index.js b/app/notifications/push/index.js
index 37b2b0391c..865a6ad613 100644
--- a/app/notifications/push/index.js
+++ b/app/notifications/push/index.js
@@ -14,9 +14,12 @@ export const onNotification = (notification) => {
} = EJSON.parse(data.ejson);
const types = {
- c: 'channel', d: 'direct', p: 'group'
+ c: 'channel', d: 'direct', p: 'group', l: 'channels'
};
- const roomName = type === 'd' ? sender.username : name;
+ let roomName = type === 'd' ? sender.username : name;
+ if (type === 'l') {
+ roomName = sender.name;
+ }
const params = {
host,
diff --git a/app/sagas/deepLinking.js b/app/sagas/deepLinking.js
index ef66fac4f1..ddc8af0ecf 100644
--- a/app/sagas/deepLinking.js
+++ b/app/sagas/deepLinking.js
@@ -13,7 +13,7 @@ import EventEmitter from '../utils/events';
import { appStart } from '../actions';
const roomTypes = {
- channel: 'c', direct: 'd', group: 'p'
+ channel: 'c', direct: 'd', group: 'p', channels: 'l'
};
const handleInviteLink = function* handleInviteLink({ params, requireLogin = false }) {
diff --git a/app/views/RoomActionsView/index.js b/app/views/RoomActionsView/index.js
index a1de380226..18e4a05796 100644
--- a/app/views/RoomActionsView/index.js
+++ b/app/views/RoomActionsView/index.js
@@ -349,7 +349,10 @@ class RoomActionsView extends React.Component {
renderItem: this.renderItem
});
}
+ } else if (t === 'l') {
+ sections[2].data = [notificationsAction];
}
+
return sections;
}
diff --git a/app/views/RoomInfoView/index.js b/app/views/RoomInfoView/index.js
index f19fdfb728..ada9df185a 100644
--- a/app/views/RoomInfoView/index.js
+++ b/app/views/RoomInfoView/index.js
@@ -117,7 +117,7 @@ class RoomInfoView extends React.Component {
}
}
const permissions = await RocketChat.hasPermission([PERMISSION_EDIT_ROOM], room.rid);
- if (permissions[PERMISSION_EDIT_ROOM] && !room.prid) {
+ if (permissions[PERMISSION_EDIT_ROOM] && !room.prid && this.t !== 'l') {
navigation.setParams({ showEdit: true });
}
}
diff --git a/app/views/RoomView/Header/Icon.js b/app/views/RoomView/Header/Icon.js
index 7247d88fed..de490b7d46 100644
--- a/app/views/RoomView/Header/Icon.js
+++ b/app/views/RoomView/Header/Icon.js
@@ -40,6 +40,8 @@ const Icon = React.memo(({ type, status, theme }) => {
icon = 'thread';
} else if (type === 'c') {
icon = 'hashtag';
+ } else if (type === 'l') {
+ icon = 'livechat';
} else {
icon = 'lock';
}
diff --git a/app/views/RoomsListView/index.js b/app/views/RoomsListView/index.js
index 845f28f293..468370a7ea 100644
--- a/app/views/RoomsListView/index.js
+++ b/app/views/RoomsListView/index.js
@@ -380,8 +380,7 @@ class RoomsListView extends React.Component {
.get('subscriptions')
.query(
Q.where('archived', false),
- Q.where('open', true),
- Q.where('t', Q.notEq('l'))
+ Q.where('open', true)
)
.observeWithColumns(['room_updated_at', 'unread', 'alert', 'user_mentions', 'f', 't']);
diff --git a/ios/RocketChatRN/Images.xcassets/Icons/livechat.imageset/Contents.json b/ios/RocketChatRN/Images.xcassets/Icons/livechat.imageset/Contents.json
new file mode 100644
index 0000000000..e3919e8e02
--- /dev/null
+++ b/ios/RocketChatRN/Images.xcassets/Icons/livechat.imageset/Contents.json
@@ -0,0 +1,23 @@
+{
+ "images" : [
+ {
+ "idiom" : "universal",
+ "filename" : "livechat.png",
+ "scale" : "1x"
+ },
+ {
+ "idiom" : "universal",
+ "filename" : "livechat@2x.png",
+ "scale" : "2x"
+ },
+ {
+ "idiom" : "universal",
+ "filename" : "livechat@3x.png",
+ "scale" : "3x"
+ }
+ ],
+ "info" : {
+ "version" : 1,
+ "author" : "xcode"
+ }
+}
\ No newline at end of file
diff --git a/ios/RocketChatRN/Images.xcassets/Icons/livechat.imageset/livechat.png b/ios/RocketChatRN/Images.xcassets/Icons/livechat.imageset/livechat.png
new file mode 100644
index 0000000000..b2190ca738
Binary files /dev/null and b/ios/RocketChatRN/Images.xcassets/Icons/livechat.imageset/livechat.png differ
diff --git a/ios/RocketChatRN/Images.xcassets/Icons/livechat.imageset/livechat@2x.png b/ios/RocketChatRN/Images.xcassets/Icons/livechat.imageset/livechat@2x.png
new file mode 100644
index 0000000000..64e12138a2
Binary files /dev/null and b/ios/RocketChatRN/Images.xcassets/Icons/livechat.imageset/livechat@2x.png differ
diff --git a/ios/RocketChatRN/Images.xcassets/Icons/livechat.imageset/livechat@3x.png b/ios/RocketChatRN/Images.xcassets/Icons/livechat.imageset/livechat@3x.png
new file mode 100644
index 0000000000..14e8a801b3
Binary files /dev/null and b/ios/RocketChatRN/Images.xcassets/Icons/livechat.imageset/livechat@3x.png differ