Registrations currently disabled due to spam. Contact me externally if you need an account

Commit c8ad244e authored by Gabriel Engel's avatar Gabriel Engel Committed by GitHub
Browse files

Merge pull request #5250 from RocketChat/livechat-improvements

Livechat improvements
parents a18d1641 bbf30821
Loading
Loading
Loading
Loading
+3 −3
Changes for packages/rocketchat-i18n/i18n/pt.i18n.json: 3 added lines, 3 removed lines.
Original line number Diff line number Diff line
@@ -1202,9 +1202,9 @@
  "User_joined_channel": "Entrou no canal.",
  "User_joined_channel_female": "Entrou no canal.",
  "User_joined_channel_male": "Entrou no canal.",
  "User_left": "Usuário <em>__user_left__</em> deixou a conversa.",
  "User_left_female": "Usuário <em>__user_left__</em> deixou a conversa.",
  "User_left_male": "Usuário <em>__user_left__</em> deixou a conversa.",
  "User_left": "Saiu da conversa.",
  "User_left_female": "Saiu da conversa.",
  "User_left_male": "Saiu da conversa.",
  "User_logged_out": "Usuário não logado",
  "User_management": "Gerenciamento de usuários",
  "User_muted_by": "Usuário <em>__user_muted__</em> silenciado por <em>__user_by__</em>.",
+5 −1
Changes for packages/rocketchat-lib/server/functions/Notifications.coffee: 5 added lines, 1 removed line.
Original line number Diff line number Diff line
@@ -33,7 +33,11 @@ RocketChat.Notifications = new class
			roomId = eventName.split('/')[0]

			user = Meteor.users.findOne @userId, {fields: {username: 1}}
			return RocketChat.models.Rooms.findOneByIdContainigUsername(roomId, user.username, {fields: {_id: 1}})?
			room = RocketChat.models.Rooms.findOneById(roomId)
			if room.t is 'l' and room.v._id is user._id
				return true

			return room.usernames.indexOf(user.username) > -1

		@streamRoomUsers.allowRead('none');

+5 −1
Changes for packages/rocketchat-lib/server/functions/sendMessage.coffee: 5 added lines, 1 removed line.
Original line number Diff line number Diff line
@@ -13,7 +13,11 @@ RocketChat.sendMessage = (user, message, room, upsert = false) ->
	message.rid = room._id

	if not room.usernames? || room.usernames.length is 0
		room = RocketChat.models.Rooms.findOneById(room._id)
		updated_room = RocketChat.models.Rooms.findOneById(room._id)
		if updated_room?
			room = updated_room
		else
			room.usernames = []

	if message.parseUrls isnt false
		if urls = message.msg.match /([A-Za-z]{3,9}):\/\/([-;:&=\+\$,\w]+@{1})?([-A-Za-z0-9\.]+)+:?(\d+)?((\/[-\+=!:~%\/\.@\,\w]*)?\??([-\+=&!:;%@\/\.\,\w]+)?(?:#([^\s\)]+))?)?/g
+1 −1
Changes for packages/rocketchat-livechat/app/client/lib/msgTyping.coffee: 1 added line, 1 removed line.
Original line number Diff line number Diff line
@@ -28,7 +28,7 @@
						dep.changed()

	Tracker.autorun ->
		if visitor.getRoom()
		if visitor.getRoom() and Meteor.userId()
			addStream visitor.getRoom()

	start = (room) ->
+21 −8
Changes for packages/rocketchat-livechat/app/client/stylesheets/main.less: 21 added lines, 8 removed lines.
Original line number Diff line number Diff line
@@ -142,8 +142,8 @@ input:focus {
		cursor: pointer;
		h1 {
			margin: 0;
			padding: 0 5px;
			font-size: 9pt;
			padding: 0 10px;
			font-size: 10pt;
			display: inline-block;
		}

@@ -151,13 +151,14 @@ input:focus {
			display: inline-block;
			float: right;
			padding-right: 5px;
			padding-top: 3px;
			height: 30px;

			svg {
				cursor: pointer;
				fill: currentColor;
				width: 14px;
				margin: 0 2px;
				vertical-align: middle;
			}
		}
	}
@@ -191,10 +192,10 @@ input:focus {

			.message {
				font-size: 12px;
				padding-left: 40px;
				padding: 3px 10px 3px 50px;
				position: relative;
				line-height: 18px;
				margin: 12px 10px 0;
				margin: 3px 0 3px 0;
				min-height: 36px;
				&:nth-child(1) {
					margin-top: 0;
@@ -236,6 +237,9 @@ input:focus {
				&.own:hover:not(.system) .edit-message {
					display: inline-block;
				}
				&.own {
					background-color: #f5f5f5;
				}
				.delete-message {
					display: none;
					cursor: pointer;
@@ -255,8 +259,8 @@ input:focus {
				}
				.thumb {
					position: absolute;
					left: 0;
					top: 0;
					left: 10px;
					top: 6px;
					display: block;
					width: 30px;
					height: 30px;
@@ -280,7 +284,7 @@ input:focus {
					.info {
						position: absolute;
						text-align: right;
						left: -20px;
						left: -10px;
						width: 55px;
						.time {
							display: none;
@@ -456,6 +460,15 @@ input:focus {
			font-size: 0.65rem;
		}

		.typing {
			clear: both;
			color: @secondary-font-color;
			margin-left: 8px;
			outline: none;
			margin-top: 2px;
			font-size: 0.65rem;
		}

		.options-menu {
			min-width: 100px;
			// min-height: 40px;
Loading