Commit c567a7df by Takuya Ogawa

Merge branch 'features/1.3.0' into 'features/1.3.0_test'

Features/1.3.0

See merge request !48
parents 4c3f5c1b 2e8f8963
......@@ -104,7 +104,7 @@ img {
color: #707070;
font-size: 18px;
}
.srch_bar .input-group-addon { margin: 0 0 0 -27px;}
.srch_bar .input-group-addon { margin: 0 0 0 0px;}
.chat_ib h5, .group_ib h5, .user_ib h5 {
font-size:1rem;
......@@ -124,15 +124,15 @@ img {
max-height: calc(100vh - 92px);
}
.room_srch_bar input{ border:1px solid #cdcdcd; border-width:0 0 1px 0; width:100%; padding:2px 0 4px 6px; background:none;}
.room_srch_bar input{ border:1px solid #cdcdcd; border-width:0 0 1px 0; width:75%; padding:2px 0 4px 6px; background:none;}
.room_srch_bar .input-group-addon button {
background: rgba(0, 0, 0, 0) none repeat scroll 0 0;
border: medium none;
padding: 0;
padding: 1;
color: #707070;
font-size: 18px;
}
.room_srch_bar .input-group-addon { margin: 0 0 0 -27px;}
.room_srch_bar .input-group-addon { margin: 0 0 0 0px;}
.inbox_chat {
overflow-y: scroll;
......
......@@ -301,7 +301,7 @@ jQuery('#roomDeleteButton').on('click', function(e){
//loadingIndicatorを表示
showLoadingIndicator();
let roomId = jQuery(this).data('roomId');
let roomName = jQuery(this).data('roomName');
let roomName = jQuery(this).data('roomname');
socket.emit('joinRoom', roomId, roomName, function (){
jQuery('#messages').html('');
jQuery('.titleRoomName').text(roomName).data('roomName', roomName);
......@@ -327,7 +327,8 @@ jQuery('#roomDeleteButton').on('click', function(e){
// チャットルームの削除アイコンにクリックイベントを与える
jQuery('.deleteBox').off('click');
jQuery('.deleteBox').on('click', function(e){
if (window.confirm('Do you want to leave this room?')) {
// #36128
if (window.confirm('Do you want to delete this room?')) {
//loadingIndicatorを表示
showLoadingIndicator();
// 現在接続されているチャットルームを離れるとメッセージテップを初期化する
......@@ -338,7 +339,7 @@ jQuery('#roomDeleteButton').on('click', function(e){
// チャットルームから退場する
socket.emit('exitRoom', jQuery(this).data('roomId'));
// #36129に対応
// #36129に対応
let roomListTitle = getLocalizedString("roomListTitle")
$('.titleRoomName').text(roomListTitle)
}
......@@ -959,6 +960,16 @@ socket.on('refreshUserListInGroup', function(users, isInvite){
jQuery('#pills-user-tab').tab('show');
});
// #36135, #36142
jQuery('#newRoomName').on('keyup', function(event) {
if ($('#newRoomName').val().trim().length >= 20) {
alert("Please enter room name less than 20 characters");
var inputText = $('#newRoomName').val();
$('#newRoomName').val(inputText.substr(0, $('#newRoomName').prop("maxlength")));
event.preventDefault();
}
})
// グループ画面での検索
jQuery('#groupListKeyword').on('input', function(event) {
// data-name値で当該キーワードが入っているグループのみを表示する。
......
......@@ -16,7 +16,7 @@
<button class="btn btn-primary" type="button" id="backButton">
<i class="fa fa-arrow-left"></i>
</button>
<input class="form-control mr-sm-2" id="newRoomName" placeholder="Room name" aria-label="Search">
<input class="form-control mr-sm-2" id="newRoomName" placeholder="Room name" aria-label="Search" maxlength="20">
</ul>
<a class="navbar-brand col-6 mr-0 text-truncate titleRoomName text-center" href="#">Chat</a>
<ul class="navbar-nav col-3" id="navbarRight">
......@@ -41,10 +41,12 @@
</a>
<div class="dropdown-menu dropdown-menu-right" aria-labelledby="roomKeywordSearch">
<div class="room_srch_bar">
<div class="stylish-input-group">
<div class="input-group">
<input id="roomKeyword" type="text" class="search-bar" placeholder="Search">
<span class="input-group-addon">
<button id="roomKeyButton" type="button"> <i class="fa fa-search" aria-hidden="true"></i> </button>
<button id="roomKeyButton" type="button">
<i class="fa fa-search" aria-hidden="true"></i>
</button>
</span>
</div>
</div>
......
......@@ -1430,4 +1430,7 @@
<string name="msg_error_chat_join">チャットサーバーと接続に失敗しました。\n再度操作してください。</string>
<string name="msg_error_chat_text_length">メッセージの長さは0です。1文字以上を入力してください。</string>
<string name="msg_error_chat_input_roomname">ルーム名を入力してください。</string>
<string name="msg_chat_confirm_member">選択したメンバーをリストから削除しますか?</string>
<string name="msg_chat_confirm_delete">このチャットルームを削除しますか?</string>
<string name="msg_error_chat_room_name_too_long">ルーム名は文字列20字以内に入力してください。</string>
</resources>
......@@ -1438,4 +1438,7 @@
<string name="msg_error_chat_join">채팅서버 접속에 실패했습니다.\n다시 접속을 시도해보시기 바랍니다.</string>
<string name="msg_error_chat_text_length">메시지 길이가 0입니다. 한글자 이상의 문자를 입력하십시오.</string>
<string name="msg_error_chat_input_roomname">방 제목을 입력해 주십시오.</string>
<string name="msg_chat_confirm_member">목록에서 선택된 멤버를 삭제하시겠습니까?</string>
<string name="msg_chat_confirm_delete">이 방을 삭제 하시겠습니까?</string>
<string name="msg_error_chat_room_name_too_long">방 제목은 20자 이내로 입력해 주세요.</string>
</resources>
\ No newline at end of file
......@@ -1436,4 +1436,7 @@
<string name="msg_error_chat_join">Failed to connect to chat server.\nplease try again.</string>
<string name="msg_error_chat_text_length">Message length is 0. please type 1 or more character.</string>
<string name="msg_error_chat_input_roomname">Please enter a room name.</string>
<string name="msg_chat_confirm_member">Do you want to remove selected members from the list?</string>
<string name="msg_chat_confirm_delete">Do you want to delete this room?</string>
<string name="msg_error_chat_room_name_too_long">Please enter room name less than 20 characters.</string>
</resources>
\ No newline at end of file
......@@ -179,6 +179,9 @@ public class ChatWebviewActivity extends ParentWebViewActivity {
} else if (message.equals("Input RoomName")) {
message = getString(R.string.msg_error_chat_input_roomname);
// #36130 end
// #36142
} else if (message.equals("Please enter room name less than 20 characters")) {
message = getString(R.string.msg_error_chat_room_name_too_long);
} else {
message = message;
}
......@@ -220,6 +223,11 @@ public class ChatWebviewActivity extends ParentWebViewActivity {
public boolean onJsConfirm(WebView view, String url, String message, final JsResult result) {
if (message.equals("Do you want to leave this room?")) {
message = getString(R.string.msg_chat_confirm_exit);
} else if (message.equals("Do you want to remove selected members from the list?")) {
message = getString(R.string.msg_chat_confirm_member);
// #36128
} else if (message.equals("Do you want to delete this room?")) {
message = getString(R.string.msg_chat_confirm_delete);
} else {
message = "Confirm ?";
}
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment