diff --git a/app/css/app.css b/app/css/app.css
index f8bf0eb7..b8c8f2d0 100644
--- a/app/css/app.css
+++ b/app/css/app.css
@@ -771,7 +771,7 @@ a.tg_radio_on:hover i.icon-radio {
display: inline-block;
vertical-align: top;
background: url(../img/icons/General.png) no-repeat -5px -10px;
- background-size: 40px 678px;
+ background-size: 40px 778px;
margin-right: 18px;
}
.icon-tg-title {
@@ -809,7 +809,7 @@ a.tg_radio_on:hover i.icon-radio {
display: inline-block;
vertical-align: middle;
background: url(../img/icons/General.png) no-repeat -18px -50px;
- background-size: 40px 678px;
+ background-size: 40px 778px;
margin-left: 12px;
margin-top: -1px;
}
@@ -1453,7 +1453,7 @@ div.im_message_video_thumb {
display: inline-block;
line-height: 0;
background: url(../img/icons/General.png) no-repeat -14px -509px;
- background-size: 40px 678px;
+ background-size: 40px 778px;
width: 12px;
height: 18px;
margin: 12px 15px;
@@ -1476,7 +1476,7 @@ div.im_message_video_thumb {
width: 14px;
height: 16px;
background: url(../img/icons/General.png) no-repeat -13px -611px;
- background-size: 40px 678px;;
+ background-size: 40px 778px;;
margin: 13px 16px;
}
.is_1x .im_message_file_button_dl_audio .im_message_file_button_icon {
@@ -1775,42 +1775,6 @@ a.im_message_fwd_photo {
line-height: 150%;
}
-span.emoji {
- display: -moz-inline-box;
- -moz-box-orient: vertical;
- display: inline-block;
- vertical-align: baseline;
- *vertical-align: auto;
- *zoom: 1;
- *display: inline;
- height: 18px;
- width: 18px;
- background-repeat: no-repeat;
- text-indent: -9999px;
-}
-
-/* widths and heights calculated according to spritesheet dimensions and icon size */
-.emoji-spritesheet-0 {
- background-size: 486px 126px;
- background-image: url('../img/emojisprite_0.png');
-}
-.emoji-spritesheet-1 {
- background-size: 522px 72px;
- background-image: url('../img/emojisprite_1.png');
-}
-.emoji-spritesheet-2 {
- background-size: 594px 126px;
- background-image: url('../img/emojisprite_2.png');
-}
-.emoji-spritesheet-3 {
- background-size: 612px 54px;
- background-image: url('../img/emojisprite_3.png');
-}
-.emoji-spritesheet-4 {
- background-size: 612px 126px;
- background-image: url('../img/emojisprite_4.png');
-}
-
.im_history_not_selected,
.im_history_empty {
visibility: hidden;
@@ -1951,159 +1915,306 @@ img.img_fullsize {
-/* Emoji area */
-.emoji-wysiwyg-editor:empty:before {
- content: attr(placeholder);
- color: #9aa2ab;
-}
-.emoji-wysiwyg-editor:active:before,
-.emoji-wysiwyg-editor:focus:before {
- content: none;
-}
-
-.emoji-wysiwyg-editor {
- box-sizing: content-box;
- -moz-box-sizing: content-box;
- font-size: 12px;
- margin-bottom: 10px;
- padding: 6px;
- min-height: 38px;
- height: auto;
- width: auto;
- max-height: 284px;
- overflow: auto;
- line-height: 17px;
-
- border: 1px solid #d2dbe3;
- border-radius: 2px;
- -webkit-box-shadow: none;
- box-shadow: none;
- -webkit-transition: border-color ease-in-out 0.15s, box-shadow ease-in-out 0.15s;
- transition: border-color ease-in-out 0.15s, box-shadow ease-in-out 0.15s;
-
- -webkit-user-select: text;
- word-wrap: break-word;
+/* Message composer */
+.composer_emoji_insert_btn {
+ display: block;
+ position: absolute;
+ right: 3px;
+ top: 2px;
+ cursor: pointer;
+ padding: 0;
- -webkit-user-select: text;
- -moz-user-select: text;
- -ms-user-select: text;
- user-select: text;
+ width: 22px;
+ height: 22px;
+ margin-top: 1px;
}
-.emoji-wysiwyg-editor img {
- width: 20px;
- height: 20px;
- vertical-align: middle;
- margin: -3px 0 0 0;
+.icon-emoji {
+ display: inline-block;
+ width: 22px;
+ height: 22px;
+ vertical-align: top;
+ background: url(../img/icons/General.png) no-repeat -9px -335px;
+ background-size: 40px 778px;
+ opacity: 0.8;
}
-.emoji-menu {
+.composer_emoji_tooltip {
+ display: none;
position: absolute;
z-index: 999;
width: 220px;
- margin-left: -107px;
- margin-top: -252px;
- overflow: hidden;
+ margin-left: -100px;
+ margin-top: -248px;
border: 1px #dfdfdf solid;
-webkit-border-radius: 3px;
-moz-border-radius: 3px;
border-radius: 3px;
- overflow: hidden;
-webkit-box-shadow: 0px 1px 1px rgba(0, 0, 0, 0.1);
-moz-box-shadow: 0px 1px 1px rgba(0, 0, 0, 0.1);
box-shadow: 0px 1px 1px rgba(0, 0, 0, 0.1);
-}
-.emoji-items-wrap1 {
background: #FFF;
padding: 5px 2px 5px 5px;
}
-.emoji-items-wrap1 .emoji-menu-tabs {
+.composer_emoji_tooltip_shown {
+ display: block;
+}
+.composer_emoji_tooltip_tail {
+ position: absolute;
+ bottom: -14px;
+ left: 50%;
+ margin-left: -13px;
+ overflow: hidden;
+ width: 26px;
+ height: 14px;
+}
+.icon-tooltip-tail {
+ background: #FFF;
+ width: 18px;
+ height: 18px;
+ -webkit-transform: rotate(45deg);
+ -moz-transform: rotate(45deg);
+ -ms-transform: rotate(45deg);
+ -o-transform: rotate(45deg);
+ transform: rotate(45deg);
+ display: inline-block;
+ -webkit-box-shadow: 1px 1px 1px rgba(0, 0, 0, 0.1);
+ -moz-box-shadow: 1px 1px 1px rgba(0, 0, 0, 0.1);
+ box-shadow: 1px 1px 1px rgba(0, 0, 0, 0.1);
+ border: 1px #dfdfdf solid;
+ border-width: 0 1px 1px 0;
+ -webkit-border-radius: 2px;
+ -moz-border-radius: 2px;
+ border-radius: 2px;
+ position: relative;
+ top: -8px;
+ left: 4px;
+
+}
+
+.composer_emoji_tooltip_tabs {
width: 100%;
margin-bottom: 8px;
margin-top: 3px;
}
-.emoji-items-wrap1 .emoji-menu-tabs td {
- text-align: center;
- color: white;
+.composer_emoji_tooltip_tab {
line-height: 0;
-}
-.emoji-menu-tabs .emoji-menu-tab {
+ color: white;
display: inline-block;
width: 24px;
height: 29px;
background: url(../img/icons/IconsetSmiles.png) no-repeat;
- background-size: 42px 350px;
+ background-size: 42px 470px;
+ cursor: pointer;
+ opacity: 0.7;
+ margin: 0 3px;
}
-.is_1x .emoji-menu-tabs .emoji-menu-tab {
+.is_1x .composer_emoji_tooltip_tab {
background-image: url(../img/icons/IconsetSmiles_1x.png);
}
+.composer_emoji_tooltip_tab.active {
+ opacity: 1;
+}
-.emoji-menu-tabs .icon-recent {background-position: -9px -306px; }
-.emoji-menu-tabs .icon-recent-selected {background-position: -9px -277px; }
+.composer_emoji_tooltip_tab_recent {background-position: -9px -306px; }
+.composer_emoji_tooltip_tab_recent.active {background-position: -9px -277px; }
-.emoji-menu-tabs .icon-smile {background-position: -9px -34px; }
-.emoji-menu-tabs .icon-smile-selected {background-position: -9px -5px; }
+.composer_emoji_tooltip_tab_smile {background-position: -9px -34px; }
+.composer_emoji_tooltip_tab_smile.active {background-position: -9px -5px; }
-.emoji-menu-tabs .icon-flower {background-position: -9px -145px; }
-.emoji-menu-tabs .icon-flower-selected {background-position: -9px -118px; }
+.composer_emoji_tooltip_tab_flower {background-position: -9px -145px; }
+.composer_emoji_tooltip_tab_flower.active {background-position: -9px -118px; }
-.emoji-menu-tabs .icon-bell {background-position: -9px -89px; }
-.emoji-menu-tabs .icon-bell-selected {background-position: -9px -61px; }
+.composer_emoji_tooltip_tab_bell {background-position: -9px -89px; }
+.composer_emoji_tooltip_tab_bell.active {background-position: -9px -61px; }
-.emoji-menu-tabs .icon-car {background-position: -9px -196px; }
-.emoji-menu-tabs .icon-car-selected {background-position: -9px -170px; }
+.composer_emoji_tooltip_tab_car {background-position: -9px -196px; }
+.composer_emoji_tooltip_tab_car.active {background-position: -9px -170px; }
-.emoji-menu-tabs .icon-grid {background-position: -9px -248px; }
-.emoji-menu-tabs .icon-grid-selected {background-position: -9px -222px; }
+.composer_emoji_tooltip_tab_grid {background-position: -9px -248px; }
+.composer_emoji_tooltip_tab_grid.active {background-position: -9px -222px; }
-.emoji-menu-tabs .icon-recent,
-.emoji-menu-tabs .icon-smile,
-.emoji-menu-tabs .icon-flower,
-.emoji-menu-tabs .icon-bell,
-.emoji-menu-tabs .icon-car,
-.emoji-menu-tabs .icon-grid {
- opacity: 0.7;
-}
-.emoji-menu-tabs .icon-recent:hover,
-.emoji-menu-tabs .icon-smile:hover,
-.emoji-menu-tabs .icon-flower:hover,
-.emoji-menu-tabs .icon-bell:hover,
-.emoji-menu-tabs .icon-car:hover,
-.emoji-menu-tabs .icon-grid:hover {
- opacity: 1;
-}
+.composer_emoji_tooltip_tab_stickers {background-position: -9px -361px; }
+.composer_emoji_tooltip_tab_stickers.active {background-position: -9px -333px; }
-.emoji-menu .emoji-items-wrap {
- position: relative;
+.nano.composer_emoji_tooltip_content_wrap {
height: 174px;
+ position: relative;
}
-.emoji-menu .emoji-items {
+.composer_emoji_tooltip_content {
+ /*position: relative;*/
+ /*overflow: hidden;
+ overflow-y: auto;*/
padding-right: 8px;
- outline: 0 !important;
-}
-.emoji-menu img {
- width: 20px;
- height: 20px;
- vertical-align: middle;
- border: 0 none;
+ outline: 0!important;
}
-.emoji-menu .emoji-items a {
+
+
+a.composer_emoji_btn {
margin: -1px 0 0 -1px;
padding: 5px;
display: block;
float: left;
border-radius: 2px;
}
-.emoji-menu .emoji-items a:hover {
+a.composer_emoji_btn:hover {
background-color: #edf2f5;
}
-.emoji-menu:after {
- content: ' ';
- display: block;
- clear: left;
+
+.emoji {
+ display: -moz-inline-box;
+ -moz-box-orient: vertical;
+ display: inline-block;
+ vertical-align: baseline;
+ *vertical-align: auto;
+ *zoom: 1;
+ *display: inline;
+ height: 18px;
+ width: 18px;
+ background-repeat: no-repeat;
+ text-indent: -9999px;
+ border: 0 none;
+}
+
+/* widths and heights calculated according to spritesheet dimensions and icon size */
+.emoji-spritesheet-0 {
+ background-size: 486px 126px;
+ background-image: url('../img/emojisprite_0.png');
+}
+.emoji-spritesheet-1 {
+ background-size: 522px 72px;
+ background-image: url('../img/emojisprite_1.png');
+}
+.emoji-spritesheet-2 {
+ background-size: 594px 126px;
+ background-image: url('../img/emojisprite_2.png');
+}
+.emoji-spritesheet-3 {
+ background-size: 612px 54px;
+ background-image: url('../img/emojisprite_3.png');
+}
+.emoji-spritesheet-4 {
+ background-size: 612px 126px;
+ background-image: url('../img/emojisprite_4.png');
+}
+
+.emoji-w20 {
+ width: 20px;
+ height: 20px;
+ vertical-align: middle;
+ display: inline-block;
+}
+.emoji-w20.emoji-spritesheet-0 {background-size: 540px 140px;}
+.emoji-w20.emoji-spritesheet-1 {background-size: 580px 80px;}
+.emoji-w20.emoji-spritesheet-2 {background-size: 660px 140px;}
+.emoji-w20.emoji-spritesheet-3 {background-size: 680px 60px;}
+.emoji-w20.emoji-spritesheet-4 {background-size: 680px 140px;}
+
+.emoji-w26 {
+ width: 26px;
+ height: 26px;
+ vertical-align: middle;
+ display: inline-block;
}
-.emoji-menu a .label {
+.emoji-w26.emoji-spritesheet-0 {background-size: 702px 182px;}
+.emoji-w26.emoji-spritesheet-1 {background-size: 754px 104px;}
+.emoji-w26.emoji-spritesheet-2 {background-size: 858px 182px;}
+.emoji-w26.emoji-spritesheet-3 {background-size: 884px 78px;}
+.emoji-w26.emoji-spritesheet-4 {background-size: 884px 182px;}
+
+.composer_dropdown {
display: none;
+ /*max-width: 100%;*/
+ border-radius: 2px;
+ padding: 6px 0;
+ border: 1px solid rgba(15, 60, 96, 0.2);
+ -webkit-box-shadow: 0px 1px 3px 0px rgba(60,75,87,0.27);
+ -moz-box-shadow: 0px 1px 3px 0px rgba(60,75,87,0.27);
+ box-shadow: 0px 1px 3px 0px rgba(60,75,87,0.27);
+}
+
+.composer_dropdown > li > a {
+ display: block;
+ font-size: 13px;
+ line-height: 15px;
+ padding: 4px 10px;
+ color: #52719a;
+}
+.composer_dropdown li a:hover,
+.composer_dropdown li a.composer_emoji_option_active {
+ color: #52719a;
+ background: #f2f6fa;
+}
+.composer_emoji_shortcut {
+ display: inline-block;
+ vertical-align: top;
+ margin-left: 15px;
+ line-height: 20px;
+}
+.composer_sticker_btn {
+ width: 67px;
+ height: 67px;
+ display: block;
+ display: inline-block;
+ text-align: center;
+ padding: 3px;
+}
+.composer_sticker_btn:hover {
+ background: #f2f6fa;
+}
+.composer_sticker_image {
+ max-width: 64px;
+ max-height: 64px;
+}
+
+.composer_rich_textarea {
+ box-sizing: content-box;
+ -moz-box-sizing: content-box;
+ font-size: 12px;
+ margin-bottom: 10px;
+ padding: 6px;
+ min-height: 38px;
+ height: auto;
+ width: auto;
+ max-height: 284px;
+ overflow: auto;
+ line-height: 17px;
+
+ border: 1px solid #d2dbe3;
+ border-radius: 2px;
+ -webkit-box-shadow: none;
+ box-shadow: none;
+ -webkit-transition: border-color ease-in-out 0.15s, box-shadow ease-in-out 0.15s;
+ transition: border-color ease-in-out 0.15s, box-shadow ease-in-out 0.15s;
+
+ -webkit-user-select: text;
+ word-wrap: break-word;
+
+ -webkit-user-select: text;
+ -moz-user-select: text;
+ -ms-user-select: text;
+ user-select: text;
+}
+
+.composer_rich_textarea:empty:before {
+ content: attr(placeholder);
+ color: #9aa2ab;
+}
+.composer_rich_textarea:active:before,
+.composer_rich_textarea:focus:before {
+ content: none;
+}
+.composer_rich_textarea:empty:active:before,
+.composer_rich_textarea:empty:focus:before {
+ content: attr(placeholder);
+ color: #9aa2ab;
+}
+
+.composer_rich_textarea img {
+ width: 20px;
+ height: 20px;
+ vertical-align: middle;
+ margin: -3px 0 0 0;
}
diff --git a/app/css/desktop.css b/app/css/desktop.css
index b2cc8bd9..ac190f4d 100644
--- a/app/css/desktop.css
+++ b/app/css/desktop.css
@@ -171,7 +171,7 @@
margin-right: 38px;
display: inline-block;
background: url(../img/icons/General.png) no-repeat -10px -111px;
- background-size: 40px 678px;
+ background-size: 40px 778px;
vertical-align: top;
margin-top: 3px;
}
@@ -183,7 +183,7 @@
display: inline-block;
vertical-align: top;
background: url(../img/icons/General.png) no-repeat -11px -135px;
- background-size: 40px 678px;
+ background-size: 40px 778px;
}
.icon-settings {
width: 20px;
@@ -193,7 +193,7 @@
display: inline-block;
vertical-align: top;
background: url(../img/icons/General.png) no-repeat -10px -163px;
- background-size: 40px 678px;
+ background-size: 40px 778px;
}
.icon-faq {
width: 20px;
@@ -203,7 +203,7 @@
display: inline-block;
vertical-align: top;
background: url(../img/icons/General.png) no-repeat -10px -637px;
- background-size: 40px 678px;
+ background-size: 40px 778px;
}
.icon-about {
width: 21px;
@@ -212,7 +212,7 @@
display: inline-block;
vertical-align: top;
background: url(../img/icons/General.png) no-repeat -10px -193px;
- background-size: 40px 678px;
+ background-size: 40px 778px;
}
.is_1x .icon-new-group,
.is_1x .icon-contacts,
@@ -315,7 +315,7 @@
.icon-filter-audio {
display: inline-block;
background: url(../img/icons/General.png) no-repeat 0 0;
- background-size: 40px 678px;
+ background-size: 40px 778px;
margin-right: 12px;
vertical-align: top;
}
@@ -408,11 +408,11 @@
opacity : 0.99;
}
-.emoji-menu .nano > .nano-pane {
+.composer_emoji_tooltip .nano > .nano-pane {
background : rgba(255,255,255,0.0);
right: -2px;
}
-.emoji-menu .nano > .nano-pane > .nano-slider {
+.composer_emoji_tooltip .nano > .nano-pane > .nano-slider {
background: #d1d1d1;
margin: 0 3px 0 4px;
}
@@ -722,26 +722,21 @@ a.footer_link.active:active {
background: inherit;
}
-.im_emoji_quick_select_area {
+.composer_emoji_panel {
display: block;
height: 30px;
overflow: hidden;
max-width: 210px;
}
-
-.im_emoji_quick_select_area a {
+.composer_emoji_panel a {
display: inline-block;
padding: 5px;
outline: 0;
border-radius: 2px;
}
-
-.im_emoji_quick_select_area a:hover {
+/*.composer_emoji_panel a:hover {
background-color: #edf2f5;
-}
-.im_emoji_quick_select_area a .label {
- display: none;
-}
+}*/
.im_message_selected .im_message_date,
.im_message_selected .im_message_document_size,
@@ -940,7 +935,8 @@ a.im_panel_peer_photo .peer_initials {
margin-left: 36px;
}
-.im_emoji_btn {
+/*.composer_emoji_insert_btn {
+ display: block;
position: absolute;
right: 3px;
top: 2px;
@@ -950,33 +946,48 @@ a.im_panel_peer_photo .peer_initials {
width: 22px;
height: 22px;
margin-top: 1px;
-}
-.icon-emoji {
+}*/
+/*.icon-emoji {
display: inline-block;
width: 22px;
height: 22px;
vertical-align: top;
background: url(../img/icons/General.png) no-repeat -9px -335px;
- background-size: 40px 678px;
+ background-size: 40px 778px;
opacity: 0.8;
-}
+}*/
.is_1x .icon-emoji {
background-image: url(../img/icons/General_1x.png);
}
-.im_emoji_btn:hover .icon-emoji {
+.composer_emoji_insert_btn:hover .icon-emoji {
opacity: 1;
}
-.im_emoji_btn:active .icon-emoji,
-.im_emoji_btn.on .icon-emoji {
+.composer_emoji_insert_btn:active .icon-emoji,
+.composer_emoji_insert_btn.composer_emoji_insert_btn_on .icon-emoji {
background-position: -9px -367px;
opacity: 1;
}
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
.im_send_field_wrap {
margin-bottom: 15px;
}
-.emoji-wysiwyg-editor,
-.form-control.im_message_field {
+.composer_rich_textarea,
+.composer_textarea {
border-radius: 0;
border: 0;
box-shadow: none;
@@ -988,8 +999,8 @@ a.im_panel_peer_photo .peer_initials {
line-height: 20px;
height: auto;
}
-.emoji-wysiwyg-editor:focus,
-.form-control.im_message_field:focus {
+.composer_rich_textarea:focus,
+.composer_textarea:focus {
border: 0;
box-shadow: none;
outline: none;
@@ -1014,7 +1025,7 @@ a.im_panel_peer_photo .peer_initials {
height: 17px;
vertical-align: top;
background: url(../img/icons/General.png) no-repeat -11px -455px;
- background-size: 40px 678px;
+ background-size: 40px 778px;
opacity: 0.8;
margin: 0;
}
@@ -1050,7 +1061,7 @@ a.im_panel_peer_photo .peer_initials {
height: 18px;
vertical-align: top;
background: url(../img/icons/General.png) no-repeat -10px -399px;
- background-size: 40px 678px;
+ background-size: 40px 778px;
opacity: 0.8;
}
.is_1x .icon-camera {
diff --git a/app/css/mobile.css b/app/css/mobile.css
index e02939ec..1e84e566 100644
--- a/app/css/mobile.css
+++ b/app/css/mobile.css
@@ -1105,7 +1105,7 @@ a.mobile_modal_action .tg_checkbox_label {
display: block;
}
-.im_emoji_btn {
+.composer_emoji_insert_btn {
position: absolute;
left: 0;
top: 0;
@@ -1127,10 +1127,10 @@ a.mobile_modal_action .tg_checkbox_label {
.is_1x .icon-emoji {
background-image: url(../img/icons/IconsetW_1x.png);
}
-.im_emoji_btn:active .icon-emoji,
-.is_1x .im_emoji_btn:active .icon-emoji,
-.im_emoji_btn.on .icon-emoji,
-.is_1x .im_emoji_btn.on .icon-emoji {
+.composer_emoji_insert_btn:active .icon-emoji,
+.is_1x .composer_emoji_insert_btn:active .icon-emoji,
+.composer_emoji_insert_btn.on .icon-emoji,
+.is_1x .composer_emoji_insert_btn.on .icon-emoji {
background-position: -10px -803px;
}
@@ -1141,21 +1141,21 @@ a.mobile_modal_action .tg_checkbox_label {
.im_send_field_wrap .form-control {
border-radius: 4px;
}
-.emoji-wysiwyg-editor {
+.composer_rich_textarea {
min-height: 18px;
max-height: 136px;
margin-bottom: 0;
font-size: 15px;
}
-.emoji-wysiwyg-editor:empty {
+.composer_rich_textarea:empty {
background: #f1f1f1;
border-color: #f1f1f1;
}
-.emoji-wysiwyg-editor:empty:before {
+.composer_rich_textarea:empty:before {
color: #999;
}
-.emoji-wysiwyg-editor:active,
-.emoji-wysiwyg-editor:focus {
+.composer_rich_textarea:active,
+.composer_rich_textarea:focus {
box-shadow: none;
outline: 0;
background: #FFF;
@@ -1164,17 +1164,33 @@ a.mobile_modal_action .tg_checkbox_label {
}
-.emoji-menu {
- margin-left: -20px;
- margin-top: -202px;
+.composer_emoji_tooltip {
+ margin-left: 10px;
+ margin-top: -175px;
width: 262px;
}
-.emoji-menu .emoji-items-wrap {
+.composer_emoji_tooltip .composer_emoji_tooltip_content {
height: 106px;
}
-.emoji-menu .emoji-items a {
+.composer_emoji_tooltip .composer_emoji_tooltip_content .composer_emoji_btn {
padding: 5px;
}
+.icon-tooltip-tail {
+ display: none;
+}
+.composer_emoji_tooltip_tab {
+ margin: 0 5px;
+}
+
+.composer_sticker_btn {
+ width: 80px;
+ height: 80px;
+ padding: 3px;
+}
+.composer_sticker_image {
+ max-width: 64px;
+ max-height: 64px;
+}
.contacts_modal_search {
diff --git a/app/img/icons/General.png b/app/img/icons/General.png
index b6f3fdf6..aa2e7ec8 100644
Binary files a/app/img/icons/General.png and b/app/img/icons/General.png differ
diff --git a/app/img/icons/General_1x.png b/app/img/icons/General_1x.png
index 271503ca..045dccad 100644
Binary files a/app/img/icons/General_1x.png and b/app/img/icons/General_1x.png differ
diff --git a/app/img/icons/IconsetSmiles.png b/app/img/icons/IconsetSmiles.png
index 4fb10645..6618c24b 100644
Binary files a/app/img/icons/IconsetSmiles.png and b/app/img/icons/IconsetSmiles.png differ
diff --git a/app/img/icons/IconsetSmiles_1x.png b/app/img/icons/IconsetSmiles_1x.png
index 9679265d..b244cb76 100644
Binary files a/app/img/icons/IconsetSmiles_1x.png and b/app/img/icons/IconsetSmiles_1x.png differ
diff --git a/app/index.html b/app/index.html
index 78eb06a2..1164326e 100644
--- a/app/index.html
+++ b/app/index.html
@@ -48,7 +48,6 @@
-
@@ -83,6 +82,7 @@
PRODUCTION_ONLY_END-->
+
diff --git a/app/js/app.js b/app/js/app.js
index e8ec4a78..a80ee454 100644
--- a/app/js/app.js
+++ b/app/js/app.js
@@ -27,25 +27,25 @@ angular.module('myApp', [
]).
config(['$locationProvider', '$routeProvider', '$compileProvider', 'StorageProvider', function($locationProvider, $routeProvider, $compileProvider, StorageProvider) {
- var icons = {}, reverseIcons = {}, i, j, hex, name, dataItem, row, column, totalColumns;
-
- for (j = 0; j < Config.EmojiCategories.length; j++) {
- totalColumns = Config.EmojiCategorySpritesheetDimens[j][1];
- for (i = 0; i < Config.EmojiCategories[j].length; i++) {
- dataItem = Config.Emoji[Config.EmojiCategories[j][i]];
- name = dataItem[1][0];
- row = Math.floor(i / totalColumns);
- column = (i % totalColumns);
- icons[':' + name + ':'] = [j, row, column, ':'+name+':'];
- reverseIcons[name] = dataItem[0];
- }
- }
-
- $.emojiarea.spritesheetPath = 'img/emojisprite_!.png';
- $.emojiarea.spritesheetDimens = Config.EmojiCategorySpritesheetDimens;
- $.emojiarea.iconSize = 20;
- $.emojiarea.icons = icons;
- $.emojiarea.reverseIcons = reverseIcons;
+ // var icons = {}, reverseIcons = {}, i, j, hex, name, dataItem, row, column, totalColumns;
+
+ // for (j = 0; j < Config.EmojiCategories.length; j++) {
+ // totalColumns = Config.EmojiCategorySpritesheetDimens[j][1];
+ // for (i = 0; i < Config.EmojiCategories[j].length; i++) {
+ // dataItem = Config.Emoji[Config.EmojiCategories[j][i]];
+ // name = dataItem[1][0];
+ // row = Math.floor(i / totalColumns);
+ // column = (i % totalColumns);
+ // icons[':' + name + ':'] = [j, row, column, ':'+name+':'];
+ // reverseIcons[name] = dataItem[0];
+ // }
+ // }
+
+ // $.emojiarea.spritesheetPath = 'img/emojisprite_!.png';
+ // $.emojiarea.spritesheetDimens = Config.EmojiCategorySpritesheetDimens;
+ // $.emojiarea.iconSize = 20;
+ // $.emojiarea.icons = icons;
+ // $.emojiarea.reverseIcons = reverseIcons;
$compileProvider.imgSrcSanitizationWhitelist(/^\s*(https?|ftp|file|blob|filesystem|chrome-extension|app):|data:image\//);
$compileProvider.aHrefSanitizationWhitelist(/^\s*(https?|ftp|file|mailto|blob|filesystem|chrome-extension|app):|data:image\//);
diff --git a/app/js/controllers.js b/app/js/controllers.js
index b0ece371..890119b0 100644
--- a/app/js/controllers.js
+++ b/app/js/controllers.js
@@ -316,7 +316,7 @@ angular.module('myApp.controllers', ['myApp.i18n'])
LayoutSwitchService.start();
})
- .controller('AppIMController', function ($scope, $location, $routeParams, $modal, $rootScope, $modalStack, MtpApiManager, AppUsersManager, AppChatsManager, AppPeersManager, ContactsSelectService, ChangelogNotifyService, ErrorService, AppRuntimeManager, HttpsMigrateService, LayoutSwitchService, LocationParamsService) {
+ .controller('AppIMController', function ($scope, $location, $routeParams, $modal, $rootScope, $modalStack, MtpApiManager, AppUsersManager, AppChatsManager, AppPeersManager, ContactsSelectService, ChangelogNotifyService, ErrorService, AppRuntimeManager, HttpsMigrateService, LayoutSwitchService, LocationParamsService, AppStickersManager) {
$scope.$on('$routeUpdate', updateCurDialog);
@@ -496,6 +496,7 @@ angular.module('myApp.controllers', ['myApp.i18n'])
HttpsMigrateService.start();
LayoutSwitchService.start();
LocationParamsService.start();
+ AppStickersManager.start();
})
.controller('AppImDialogsController', function ($scope, $location, $q, $timeout, $routeParams, MtpApiManager, AppUsersManager, AppChatsManager, AppMessagesManager, AppPeersManager, PhonebookContactsService, ErrorService, AppRuntimeManager) {
@@ -1454,7 +1455,7 @@ angular.module('myApp.controllers', ['myApp.i18n'])
$scope.$on('user_update', angular.noop);
})
- .controller('AppImSendController', function ($scope, $timeout, MtpApiManager, Storage, AppPeersManager, AppMessagesManager, ApiUpdatesManager, MtpApiFileManager) {
+ .controller('AppImSendController', function ($scope, $timeout, MtpApiManager, Storage, AppPeersManager, AppDocsManager, AppMessagesManager, ApiUpdatesManager, MtpApiFileManager) {
$scope.$watch('curDialog.peer', resetDraft);
$scope.$on('user_update', angular.noop);
@@ -1463,6 +1464,7 @@ angular.module('myApp.controllers', ['myApp.i18n'])
$scope.draftMessage = {text: '', send: sendMessage};
$scope.$watch('draftMessage.text', onMessageChange);
$scope.$watch('draftMessage.files', onFilesSelected);
+ $scope.$watch('draftMessage.sticker', onStickerSelected);
function sendMessage (e) {
$scope.$broadcast('ui_message_before_send');
@@ -1471,10 +1473,10 @@ angular.module('myApp.controllers', ['myApp.i18n'])
var text = $scope.draftMessage.text;
if (angular.isString(text) && text.length > 0) {
- text = text.replace(/:([a-z0-9\-\+\*_]+?):/gi, function (all, name) {
- var utfChar = $.emojiarea.reverseIcons[name];
- if (utfChar !== undefined) {
- return utfChar;
+ text = text.replace(/:([a-z0-9\-\+\*_]+?):/gi, function (all, shortcut) {
+ var emojiCode = EmojiHelper.shortcuts[shortcut];
+ if (emojiCode !== undefined) {
+ return EmojiHelper.emojis[emojiCode][0];
}
return all;
});
@@ -1529,10 +1531,10 @@ angular.module('myApp.controllers', ['myApp.i18n'])
var backupDraftObj = {};
backupDraftObj['draft' + $scope.curDialog.peerID] = newVal;
Storage.set(backupDraftObj);
- // console.log('draft save', backupDraftObj);
+ // console.log(dT(), 'draft save', backupDraftObj);
} else {
Storage.remove('draft' + $scope.curDialog.peerID);
- // console.log('draft delete', 'draft' + $scope.curDialog.peerID);
+ // console.log(dT(), 'draft delete', 'draft' + $scope.curDialog.peerID);
}
}
@@ -1555,6 +1557,28 @@ angular.module('myApp.controllers', ['myApp.i18n'])
$scope.$broadcast('ui_message_send');
}
}
+
+ function onStickerSelected (newVal) {
+ if (!newVal) {
+ return;
+ }
+
+ var doc = AppDocsManager.getDoc(newVal);
+ if (doc.id && doc.access_hash) {
+ console.log('sticker', doc);
+ var inputMedia = {
+ _: 'inputMediaDocument',
+ id: {
+ _: 'inputDocument',
+ id: doc.id,
+ access_hash: doc.access_hash
+ }
+ }
+ AppMessagesManager.sendOther($scope.curDialog.peerID, inputMedia);
+ $scope.$broadcast('ui_message_send');
+ }
+ delete $scope.draftMessage.sticker;
+ }
})
.controller('AppLangSelectController', function ($scope, _, Storage, ErrorService, AppRuntimeManager) {
@@ -3017,7 +3041,7 @@ angular.module('myApp.controllers', ['myApp.i18n'])
})
- .controller('CountrySelectModalController', function ($scope, $modalInstance, $rootScope, SearchIndexManager, _) {
+ .controller('CountrySelectModalController', function ($scope, $modalInstance, $rootScope, _) {
$scope.search = {};
$scope.slice = {limit: 20, limitDelta: 20}
@@ -3060,7 +3084,7 @@ angular.module('myApp.controllers', ['myApp.i18n'])
})
- .controller('PhonebookModalController', function ($scope, $modalInstance, $rootScope, AppUsersManager, PhonebookContactsService, SearchIndexManager, ErrorService) {
+ .controller('PhonebookModalController', function ($scope, $modalInstance, $rootScope, AppUsersManager, PhonebookContactsService, ErrorService) {
$scope.search = {};
$scope.phonebook = [];
diff --git a/app/js/directives.js b/app/js/directives.js
index 6d919047..6899fc1d 100755
--- a/app/js/directives.js
+++ b/app/js/directives.js
@@ -1061,7 +1061,7 @@ angular.module('myApp.directives', ['myApp.filters'])
})
- .directive('mySendForm', function ($timeout, $modalStack, $http, $interpolate, Storage, ErrorService) {
+ .directive('mySendForm', function ($timeout, $modalStack, $http, $interpolate, Storage, AppStickersManager, ErrorService) {
return {
link: link,
@@ -1071,139 +1071,107 @@ angular.module('myApp.directives', ['myApp.filters'])
};
function link ($scope, element, attrs) {
- var messageField = $('textarea', element)[0],
- fileSelects = $('input', element),
- dropbox = $('.im_send_dropbox_wrap', element)[0],
- emojiButton = $('.im_emoji_btn', element)[0],
- emojiQuickSelect = !Config.Mobile ? $('.im_emoji_quick_select_area', element)[0] : false,
- editorElement = messageField,
- dragStarted, dragTimeout,
- emojiArea = $(messageField).emojiarea({button: emojiButton, norealTime: true, quickSelect: emojiQuickSelect}),
- emojiMenu = $('.emoji-menu', element)[0],
- submitBtn = $('.im_submit', element)[0],
- richTextarea = $('.emoji-wysiwyg-editor', element)[0];
- if (richTextarea) {
- editorElement = richTextarea;
- $(richTextarea).addClass('form-control');
- $(richTextarea).attr('placeholder', $interpolate($(messageField).attr('placeholder'))($scope));
-
- var updatePromise;
- $(richTextarea)
- .on('DOMNodeInserted', onPastedImageEvent)
- .on('keyup', function (e) {
- updateHeight();
-
- if (!sendAwaiting) {
- $scope.$apply(function () {
- $scope.draftMessage.text = richTextarea.textContent;
- });
- }
-
- $timeout.cancel(updatePromise);
- updatePromise = $timeout(updateValue, 1000);
- });
- }
-
- // Head is sometimes slower
- $timeout(function () {
- fileSelects
- .on('change', function () {
- var self = this;
- $scope.$apply(function () {
- $scope.draftMessage.files = Array.prototype.slice.call(self.files);
- $scope.draftMessage.isMedia = $(self).hasClass('im_media_attach_input') || Config.Mobile;
- setTimeout(function () {
- try {
- self.value = '';
- } catch (e) {};
- }, 1000);
+ var messageField = $('textarea', element)[0];
+ var emojiButton = $('.composer_emoji_insert_btn', element)[0];
+ var emojiPanel = $('.composer_emoji_panel', element)[0];
+ var fileSelects = $('input', element);
+ var dropbox = $('.im_send_dropbox_wrap', element)[0];
+ var messageFieldWrap = $('.im_send_field_wrap', element)[0];
+ var dragStarted, dragTimeout;
+ var submitBtn = $('.im_submit', element)[0];
+
+ new EmojiTooltip(emojiButton, {
+ getStickers: function (callback) {
+ AppStickersManager.getStickers().then(function () {
+ AppStickersManager.getStickersImages().then(function (stickersData) {
+ callback(stickersData);
});
});
- }, 1000);
-
- var sendOnEnter = true,
- updateSendSettings = function () {
- Storage.get('send_ctrlenter').then(function (sendOnCtrl) {
- sendOnEnter = !sendOnCtrl;
- });
- };
-
- $scope.$on('settings_changed', updateSendSettings);
- updateSendSettings();
-
- $(editorElement).on('keydown', function (e) {
- if (richTextarea) {
- updateHeight();
+ },
+ onEmojiSelected: function (code) {
+ $scope.$apply(function () {
+ composer.onEmojiSelected(code);
+ })
+ },
+ onStickerSelected: function (docID) {
+ $scope.$apply(function () {
+ $scope.draftMessage.sticker = docID;
+ });
}
+ });
- if (e.keyCode == 13) {
- var submit = false;
- if (sendOnEnter && !e.shiftKey) {
- submit = true;
- } else if (!sendOnEnter && (e.ctrlKey || e.metaKey)) {
- submit = true;
- }
-
- if (submit) {
- $timeout.cancel(updatePromise);
- updateValue();
- $scope.draftMessage.send();
- $(element).trigger('message_send');
- resetTyping();
- return cancelEvent(e);
+ var composerEmojiPanel;
+ if (emojiPanel) {
+ composerEmojiPanel = new EmojiPanel(emojiPanel, {
+ onEmojiSelected: function (code) {
+ composer.onEmojiSelected(code);
}
- }
-
- });
+ });
+ }
- $(submitBtn).on('mousedown touchstart', function (e) {
- $timeout.cancel(updatePromise);
- updateValue();
- $scope.draftMessage.send();
- $(element).trigger('message_send');
- resetTyping();
- return cancelEvent(e);
+ var composer = new MessageComposer(messageField, {
+ onTyping: function () {
+ $scope.$emit('ui_typing');
+ },
+ getSendOnEnter: function () {
+ return sendOnEnter;
+ },
+ onMessageSubmit: onMessageSubmit,
+ onFilesPaste: onFilesPaste
});
- var lastTyping = 0,
- lastLength;
- $(editorElement).on('keyup', function (e) {
- var now = tsNow(),
- length = (editorElement[richTextarea ? 'textContent' : 'value']).length;
-
+ var richTextarea = composer.richTextareaEl[0];
+ if (richTextarea) {
+ $(richTextarea)
+ .attr('placeholder', $interpolate($(messageField).attr('placeholder'))($scope))
+ .on('keydown keyup', updateHeight);
+ }
- if (now - lastTyping > 5000 && length != lastLength) {
- lastTyping = now;
- lastLength = length;
- $scope.$emit('ui_typing');
- }
+ fileSelects.on('change', function () {
+ var self = this;
+ $scope.$apply(function () {
+ $scope.draftMessage.files = Array.prototype.slice.call(self.files);
+ $scope.draftMessage.isMedia = $(self).hasClass('im_media_attach_input') || Config.Mobile;
+ setTimeout(function () {
+ try {
+ self.value = '';
+ } catch (e) {};
+ }, 1000);
+ });
});
- function resetTyping () {
- lastTyping = 0;
- lastLength = 0;
+ var sendOnEnter = true;
+ function updateSendSettings () {
+ Storage.get('send_ctrlenter').then(function (sendOnCtrl) {
+ sendOnEnter = !sendOnCtrl;
+ });
};
+ $scope.$on('settings_changed', updateSendSettings);
+ updateSendSettings();
- function updateRichTextarea () {
- if (richTextarea) {
- $timeout.cancel(updatePromise);
- var html = $('
').text($scope.draftMessage.text || '').html();
- html = html.replace(/\n/g, '
');
- $(richTextarea).html(html);
- lastLength = html.length;
- updateHeight();
- }
+ $(submitBtn).on('mousedown touchstart', onMessageSubmit);
+
+ function onMessageSubmit (e) {
+ $scope.$apply(function () {
+ updateValue();
+ $scope.draftMessage.send();
+ composer.resetTyping();
+ if (composerEmojiPanel) {
+ composerEmojiPanel.update();
+ }
+ });
+ return cancelEvent(e);
}
function updateValue () {
if (richTextarea) {
- $(richTextarea).trigger('change');
+ composer.onChange();
updateHeight();
}
}
- var height = richTextarea.offsetHeight;
+ var height = richTextarea && richTextarea.offsetHeight;
function updateHeight () {
var newHeight = richTextarea.offsetHeight;
if (height != newHeight) {
@@ -1214,7 +1182,7 @@ angular.module('myApp.directives', ['myApp.filters'])
function onKeyDown(e) {
if (e.keyCode == 9 && !e.shiftKey && !e.ctrlKey && !e.metaKey && !$modalStack.getTop()) { // TAB
- editorElement.focus();
+ composer.focus();
return cancelEvent(e);
}
}
@@ -1229,13 +1197,18 @@ angular.module('myApp.directives', ['myApp.filters'])
$scope.$on('ui_history_change', focusField);
}
- $scope.$on('ui_peer_change', resetTyping);
- $scope.$on('ui_peer_draft', updateRichTextarea);
+ $scope.$on('ui_peer_change', composer.resetTyping.bind(composer));
+ $scope.$on('ui_peer_draft', function () {
+ if (richTextarea) {
+ composer.setValue($scope.draftMessage.text || '');
+ updateHeight();
+ }
+ composer.focus();
+ });
var sendAwaiting = false;
$scope.$on('ui_message_before_send', function () {
sendAwaiting = true;
- $timeout.cancel(updatePromise);
updateValue();
});
$scope.$on('ui_message_send', function () {
@@ -1243,35 +1216,17 @@ angular.module('myApp.directives', ['myApp.filters'])
focusField();
});
-
function focusField () {
onContentLoaded(function () {
- editorElement.focus();
+ composer.focus();
});
}
- function onPastedImageEvent (e) {
- var element = (e.originalEvent || e).target,
- src = (element || {}).src || '',
- remove = false;
-
- if (src.substr(0, 5) == 'data:') {
- remove = true;
- var blob = dataUrlToBlob(src);
- ErrorService.confirm({type: 'FILE_CLIPBOARD_PASTE'}).then(function () {
- $scope.draftMessage.files = [blob];
- $scope.draftMessage.isMedia = true;
- });
- setZeroTimeout(function () {
- element.parentNode.removeChild(element);
- })
- }
- else if (src && !src.match(/img\/blank\.gif/)) {
- var replacementNode = document.createTextNode(' ' + src + ' ');
- setTimeout(function () {
- element.parentNode.replaceChild(replacementNode, element);
- }, 100);
- }
+ function onFilesPaste (blobs) {
+ ErrorService.confirm({type: 'FILE_CLIPBOARD_PASTE'}).then(function () {
+ $scope.draftMessage.files = blobs;
+ $scope.draftMessage.isMedia = true;
+ });
};
function onPasteEvent (e) {
@@ -1312,7 +1267,7 @@ angular.module('myApp.directives', ['myApp.filters'])
if (e.type == 'dragenter' || e.type == 'dragover') {
if (dragStateChanged) {
$(dropbox)
- .css({height: editorElement.offsetHeight + 2, width: editorElement.offsetWidth})
+ .css({height: messageFieldWrap.offsetHeight + 2, width: messageFieldWrap.offsetWidth})
.show();
}
} else {
@@ -1335,15 +1290,11 @@ angular.module('myApp.directives', ['myApp.filters'])
$scope.$on('$destroy', function cleanup() {
- $('body').off('dragenter dragleave dragover drop', onDragDropEvent);
$(document).off('paste', onPasteEvent);
$(document).off('keydown', onKeyDown);
- $(submitBtn).off('mousedown')
+ $('body').off('dragenter dragleave dragover drop', onDragDropEvent);
+ $(submitBtn).off('mousedown touchstart');
fileSelects.off('change');
- if (richTextarea) {
- $(richTextarea).off('DOMNodeInserted keyup', onPastedImageEvent);
- }
- $(editorElement).off('keydown');
});
if (!Config.Navigator.touch) {
@@ -2587,4 +2538,4 @@ angular.module('myApp.directives', ['myApp.filters'])
}
};
- })
+ })
\ No newline at end of file
diff --git a/app/js/lib/config.js b/app/js/lib/config.js
index 443e05e5..b0a832f8 100644
--- a/app/js/lib/config.js
+++ b/app/js/lib/config.js
@@ -85,7 +85,7 @@ Config.Schema.MTProto = {"constructors":[{"id":"481674261","predicate":"vector",
-Config.Schema.API = {"constructors":[{"id":"-1132882121","predicate":"boolFalse","params":[],"type":"Bool"},{"id":"-1720552011","predicate":"boolTrue","params":[],"type":"Bool"},{"id":"481674261","predicate":"vector","params":[],"type":"Vector t"},{"id":"-994444869","predicate":"error","params":[{"name":"code","type":"int"},{"name":"text","type":"string"}],"type":"Error"},{"id":"1450380236","predicate":"null","params":[],"type":"Null"},{"id":"2134579434","predicate":"inputPeerEmpty","params":[],"type":"InputPeer"},{"id":"2107670217","predicate":"inputPeerSelf","params":[],"type":"InputPeer"},{"id":"270785512","predicate":"inputPeerContact","params":[{"name":"user_id","type":"int"}],"type":"InputPeer"},{"id":"-1690012891","predicate":"inputPeerForeign","params":[{"name":"user_id","type":"int"},{"name":"access_hash","type":"long"}],"type":"InputPeer"},{"id":"396093539","predicate":"inputPeerChat","params":[{"name":"chat_id","type":"int"}],"type":"InputPeer"},{"id":"-1182234929","predicate":"inputUserEmpty","params":[],"type":"InputUser"},{"id":"-138301121","predicate":"inputUserSelf","params":[],"type":"InputUser"},{"id":"-2031530139","predicate":"inputUserContact","params":[{"name":"user_id","type":"int"}],"type":"InputUser"},{"id":"1700689151","predicate":"inputUserForeign","params":[{"name":"user_id","type":"int"},{"name":"access_hash","type":"long"}],"type":"InputUser"},{"id":"-208488460","predicate":"inputPhoneContact","params":[{"name":"client_id","type":"long"},{"name":"phone","type":"string"},{"name":"first_name","type":"string"},{"name":"last_name","type":"string"}],"type":"InputContact"},{"id":"-181407105","predicate":"inputFile","params":[{"name":"id","type":"long"},{"name":"parts","type":"int"},{"name":"name","type":"string"},{"name":"md5_checksum","type":"string"}],"type":"InputFile"},{"id":"-1771768449","predicate":"inputMediaEmpty","params":[],"type":"InputMedia"},{"id":"767900285","predicate":"inputMediaUploadedPhoto","params":[{"name":"file","type":"InputFile"}],"type":"InputMedia"},{"id":"-1893027092","predicate":"inputMediaPhoto","params":[{"name":"id","type":"InputPhoto"}],"type":"InputMedia"},{"id":"-104578748","predicate":"inputMediaGeoPoint","params":[{"name":"geo_point","type":"InputGeoPoint"}],"type":"InputMedia"},{"id":"-1494984313","predicate":"inputMediaContact","params":[{"name":"phone_number","type":"string"},{"name":"first_name","type":"string"},{"name":"last_name","type":"string"}],"type":"InputMedia"},{"id":"322623222","predicate":"inputMediaUploadedVideo","params":[{"name":"file","type":"InputFile"},{"name":"duration","type":"int"},{"name":"w","type":"int"},{"name":"h","type":"int"},{"name":"mime_type","type":"string"}],"type":"InputMedia"},{"id":"-1726817601","predicate":"inputMediaUploadedThumbVideo","params":[{"name":"file","type":"InputFile"},{"name":"thumb","type":"InputFile"},{"name":"duration","type":"int"},{"name":"w","type":"int"},{"name":"h","type":"int"},{"name":"mime_type","type":"string"}],"type":"InputMedia"},{"id":"2130852582","predicate":"inputMediaVideo","params":[{"name":"id","type":"InputVideo"}],"type":"InputMedia"},{"id":"480546647","predicate":"inputChatPhotoEmpty","params":[],"type":"InputChatPhoto"},{"id":"-1809496270","predicate":"inputChatUploadedPhoto","params":[{"name":"file","type":"InputFile"},{"name":"crop","type":"InputPhotoCrop"}],"type":"InputChatPhoto"},{"id":"-1293828344","predicate":"inputChatPhoto","params":[{"name":"id","type":"InputPhoto"},{"name":"crop","type":"InputPhotoCrop"}],"type":"InputChatPhoto"},{"id":"-457104426","predicate":"inputGeoPointEmpty","params":[],"type":"InputGeoPoint"},{"id":"-206066487","predicate":"inputGeoPoint","params":[{"name":"lat","type":"double"},{"name":"long","type":"double"}],"type":"InputGeoPoint"},{"id":"483901197","predicate":"inputPhotoEmpty","params":[],"type":"InputPhoto"},{"id":"-74070332","predicate":"inputPhoto","params":[{"name":"id","type":"long"},{"name":"access_hash","type":"long"}],"type":"InputPhoto"},{"id":"1426648181","predicate":"inputVideoEmpty","params":[],"type":"InputVideo"},{"id":"-296249774","predicate":"inputVideo","params":[{"name":"id","type":"long"},{"name":"access_hash","type":"long"}],"type":"InputVideo"},{"id":"342061462","predicate":"inputFileLocation","params":[{"name":"volume_id","type":"long"},{"name":"local_id","type":"int"},{"name":"secret","type":"long"}],"type":"InputFileLocation"},{"id":"1023632620","predicate":"inputVideoFileLocation","params":[{"name":"id","type":"long"},{"name":"access_hash","type":"long"}],"type":"InputFileLocation"},{"id":"-1377390588","predicate":"inputPhotoCropAuto","params":[],"type":"InputPhotoCrop"},{"id":"-644787419","predicate":"inputPhotoCrop","params":[{"name":"crop_left","type":"double"},{"name":"crop_top","type":"double"},{"name":"crop_width","type":"double"}],"type":"InputPhotoCrop"},{"id":"1996904104","predicate":"inputAppEvent","params":[{"name":"time","type":"double"},{"name":"type","type":"string"},{"name":"peer","type":"long"},{"name":"data","type":"string"}],"type":"InputAppEvent"},{"id":"-1649296275","predicate":"peerUser","params":[{"name":"user_id","type":"int"}],"type":"Peer"},{"id":"-1160714821","predicate":"peerChat","params":[{"name":"chat_id","type":"int"}],"type":"Peer"},{"id":"-1432995067","predicate":"storage.fileUnknown","params":[],"type":"storage.FileType"},{"id":"8322574","predicate":"storage.fileJpeg","params":[],"type":"storage.FileType"},{"id":"-891180321","predicate":"storage.fileGif","params":[],"type":"storage.FileType"},{"id":"172975040","predicate":"storage.filePng","params":[],"type":"storage.FileType"},{"id":"-1373745011","predicate":"storage.filePdf","params":[],"type":"storage.FileType"},{"id":"1384777335","predicate":"storage.fileMp3","params":[],"type":"storage.FileType"},{"id":"1258941372","predicate":"storage.fileMov","params":[],"type":"storage.FileType"},{"id":"1086091090","predicate":"storage.filePartial","params":[],"type":"storage.FileType"},{"id":"-1278304028","predicate":"storage.fileMp4","params":[],"type":"storage.FileType"},{"id":"276907596","predicate":"storage.fileWebp","params":[],"type":"storage.FileType"},{"id":"2086234950","predicate":"fileLocationUnavailable","params":[{"name":"volume_id","type":"long"},{"name":"local_id","type":"int"},{"name":"secret","type":"long"}],"type":"FileLocation"},{"id":"1406570614","predicate":"fileLocation","params":[{"name":"dc_id","type":"int"},{"name":"volume_id","type":"long"},{"name":"local_id","type":"int"},{"name":"secret","type":"long"}],"type":"FileLocation"},{"id":"537022650","predicate":"userEmpty","params":[{"name":"id","type":"int"}],"type":"User"},{"id":"1879553105","predicate":"userSelf","params":[{"name":"id","type":"int"},{"name":"first_name","type":"string"},{"name":"last_name","type":"string"},{"name":"username","type":"string"},{"name":"phone","type":"string"},{"name":"photo","type":"UserProfilePhoto"},{"name":"status","type":"UserStatus"},{"name":"inactive","type":"Bool"}],"type":"User"},{"id":"-894214632","predicate":"userContact","params":[{"name":"id","type":"int"},{"name":"first_name","type":"string"},{"name":"last_name","type":"string"},{"name":"username","type":"string"},{"name":"access_hash","type":"long"},{"name":"phone","type":"string"},{"name":"photo","type":"UserProfilePhoto"},{"name":"status","type":"UserStatus"}],"type":"User"},{"id":"-640891665","predicate":"userRequest","params":[{"name":"id","type":"int"},{"name":"first_name","type":"string"},{"name":"last_name","type":"string"},{"name":"username","type":"string"},{"name":"access_hash","type":"long"},{"name":"phone","type":"string"},{"name":"photo","type":"UserProfilePhoto"},{"name":"status","type":"UserStatus"}],"type":"User"},{"id":"123533224","predicate":"userForeign","params":[{"name":"id","type":"int"},{"name":"first_name","type":"string"},{"name":"last_name","type":"string"},{"name":"username","type":"string"},{"name":"access_hash","type":"long"},{"name":"photo","type":"UserProfilePhoto"},{"name":"status","type":"UserStatus"}],"type":"User"},{"id":"-704549510","predicate":"userDeleted","params":[{"name":"id","type":"int"},{"name":"first_name","type":"string"},{"name":"last_name","type":"string"},{"name":"username","type":"string"}],"type":"User"},{"id":"1326562017","predicate":"userProfilePhotoEmpty","params":[],"type":"UserProfilePhoto"},{"id":"-715532088","predicate":"userProfilePhoto","params":[{"name":"photo_id","type":"long"},{"name":"photo_small","type":"FileLocation"},{"name":"photo_big","type":"FileLocation"}],"type":"UserProfilePhoto"},{"id":"164646985","predicate":"userStatusEmpty","params":[],"type":"UserStatus"},{"id":"-306628279","predicate":"userStatusOnline","params":[{"name":"expires","type":"int"}],"type":"UserStatus"},{"id":"9203775","predicate":"userStatusOffline","params":[{"name":"was_online","type":"int"}],"type":"UserStatus"},{"id":"-1683826688","predicate":"chatEmpty","params":[{"name":"id","type":"int"}],"type":"Chat"},{"id":"1855757255","predicate":"chat","params":[{"name":"id","type":"int"},{"name":"title","type":"string"},{"name":"photo","type":"ChatPhoto"},{"name":"participants_count","type":"int"},{"name":"date","type":"int"},{"name":"left","type":"Bool"},{"name":"version","type":"int"}],"type":"Chat"},{"id":"-83047359","predicate":"chatForbidden","params":[{"name":"id","type":"int"},{"name":"title","type":"string"},{"name":"date","type":"int"}],"type":"Chat"},{"id":"1661886910","predicate":"chatFull","params":[{"name":"id","type":"int"},{"name":"participants","type":"ChatParticipants"},{"name":"chat_photo","type":"Photo"},{"name":"notify_settings","type":"PeerNotifySettings"}],"type":"ChatFull"},{"id":"-925415106","predicate":"chatParticipant","params":[{"name":"user_id","type":"int"},{"name":"inviter_id","type":"int"},{"name":"date","type":"int"}],"type":"ChatParticipant"},{"id":"265468810","predicate":"chatParticipantsForbidden","params":[{"name":"chat_id","type":"int"}],"type":"ChatParticipants"},{"id":"2017571861","predicate":"chatParticipants","params":[{"name":"chat_id","type":"int"},{"name":"admin_id","type":"int"},{"name":"participants","type":"Vector
"},{"name":"version","type":"int"}],"type":"ChatParticipants"},{"id":"935395612","predicate":"chatPhotoEmpty","params":[],"type":"ChatPhoto"},{"id":"1632839530","predicate":"chatPhoto","params":[{"name":"photo_small","type":"FileLocation"},{"name":"photo_big","type":"FileLocation"}],"type":"ChatPhoto"},{"id":"-2082087340","predicate":"messageEmpty","params":[{"name":"id","type":"int"}],"type":"Message"},{"id":"1450613171","predicate":"message","params":[{"name":"flags","type":"int"},{"name":"id","type":"int"},{"name":"from_id","type":"int"},{"name":"to_id","type":"Peer"},{"name":"date","type":"int"},{"name":"message","type":"string"},{"name":"media","type":"MessageMedia"}],"type":"Message"},{"id":"-1553471722","predicate":"messageForwarded","params":[{"name":"flags","type":"int"},{"name":"id","type":"int"},{"name":"fwd_from_id","type":"int"},{"name":"fwd_date","type":"int"},{"name":"from_id","type":"int"},{"name":"to_id","type":"Peer"},{"name":"date","type":"int"},{"name":"message","type":"string"},{"name":"media","type":"MessageMedia"}],"type":"Message"},{"id":"495384334","predicate":"messageService","params":[{"name":"flags","type":"int"},{"name":"id","type":"int"},{"name":"from_id","type":"int"},{"name":"to_id","type":"Peer"},{"name":"date","type":"int"},{"name":"action","type":"MessageAction"}],"type":"Message"},{"id":"1038967584","predicate":"messageMediaEmpty","params":[],"type":"MessageMedia"},{"id":"-926655958","predicate":"messageMediaPhoto","params":[{"name":"photo","type":"Photo"}],"type":"MessageMedia"},{"id":"-1563278704","predicate":"messageMediaVideo","params":[{"name":"video","type":"Video"}],"type":"MessageMedia"},{"id":"1457575028","predicate":"messageMediaGeo","params":[{"name":"geo","type":"GeoPoint"}],"type":"MessageMedia"},{"id":"1585262393","predicate":"messageMediaContact","params":[{"name":"phone_number","type":"string"},{"name":"first_name","type":"string"},{"name":"last_name","type":"string"},{"name":"user_id","type":"int"}],"type":"MessageMedia"},{"id":"694364726","predicate":"messageMediaUnsupported","params":[{"name":"bytes","type":"bytes"}],"type":"MessageMedia"},{"id":"-1230047312","predicate":"messageActionEmpty","params":[],"type":"MessageAction"},{"id":"-1503425638","predicate":"messageActionChatCreate","params":[{"name":"title","type":"string"},{"name":"users","type":"Vector"}],"type":"MessageAction"},{"id":"-1247687078","predicate":"messageActionChatEditTitle","params":[{"name":"title","type":"string"}],"type":"MessageAction"},{"id":"2144015272","predicate":"messageActionChatEditPhoto","params":[{"name":"photo","type":"Photo"}],"type":"MessageAction"},{"id":"-1780220945","predicate":"messageActionChatDeletePhoto","params":[],"type":"MessageAction"},{"id":"1581055051","predicate":"messageActionChatAddUser","params":[{"name":"user_id","type":"int"}],"type":"MessageAction"},{"id":"-1297179892","predicate":"messageActionChatDeleteUser","params":[{"name":"user_id","type":"int"}],"type":"MessageAction"},{"id":"-1422222932","predicate":"dialog","params":[{"name":"peer","type":"Peer"},{"name":"top_message","type":"int"},{"name":"unread_count","type":"int"},{"name":"notify_settings","type":"PeerNotifySettings"}],"type":"Dialog"},{"id":"590459437","predicate":"photoEmpty","params":[{"name":"id","type":"long"}],"type":"Photo"},{"id":"582313809","predicate":"photo","params":[{"name":"id","type":"long"},{"name":"access_hash","type":"long"},{"name":"user_id","type":"int"},{"name":"date","type":"int"},{"name":"caption","type":"string"},{"name":"geo","type":"GeoPoint"},{"name":"sizes","type":"Vector"}],"type":"Photo"},{"id":"236446268","predicate":"photoSizeEmpty","params":[{"name":"type","type":"string"}],"type":"PhotoSize"},{"id":"2009052699","predicate":"photoSize","params":[{"name":"type","type":"string"},{"name":"location","type":"FileLocation"},{"name":"w","type":"int"},{"name":"h","type":"int"},{"name":"size","type":"int"}],"type":"PhotoSize"},{"id":"-374917894","predicate":"photoCachedSize","params":[{"name":"type","type":"string"},{"name":"location","type":"FileLocation"},{"name":"w","type":"int"},{"name":"h","type":"int"},{"name":"bytes","type":"bytes"}],"type":"PhotoSize"},{"id":"-1056548696","predicate":"videoEmpty","params":[{"name":"id","type":"long"}],"type":"Video"},{"id":"948937617","predicate":"video","params":[{"name":"id","type":"long"},{"name":"access_hash","type":"long"},{"name":"user_id","type":"int"},{"name":"date","type":"int"},{"name":"caption","type":"string"},{"name":"duration","type":"int"},{"name":"mime_type","type":"string"},{"name":"size","type":"int"},{"name":"thumb","type":"PhotoSize"},{"name":"dc_id","type":"int"},{"name":"w","type":"int"},{"name":"h","type":"int"}],"type":"Video"},{"id":"286776671","predicate":"geoPointEmpty","params":[],"type":"GeoPoint"},{"id":"541710092","predicate":"geoPoint","params":[{"name":"long","type":"double"},{"name":"lat","type":"double"}],"type":"GeoPoint"},{"id":"-486486981","predicate":"auth.checkedPhone","params":[{"name":"phone_registered","type":"Bool"},{"name":"phone_invited","type":"Bool"}],"type":"auth.CheckedPhone"},{"id":"-269659687","predicate":"auth.sentCode","params":[{"name":"phone_registered","type":"Bool"},{"name":"phone_code_hash","type":"string"},{"name":"send_call_timeout","type":"int"},{"name":"is_password","type":"Bool"}],"type":"auth.SentCode"},{"id":"-155815004","predicate":"auth.authorization","params":[{"name":"expires","type":"int"},{"name":"user","type":"User"}],"type":"auth.Authorization"},{"id":"-543777747","predicate":"auth.exportedAuthorization","params":[{"name":"id","type":"int"},{"name":"bytes","type":"bytes"}],"type":"auth.ExportedAuthorization"},{"id":"-1195615476","predicate":"inputNotifyPeer","params":[{"name":"peer","type":"InputPeer"}],"type":"InputNotifyPeer"},{"id":"423314455","predicate":"inputNotifyUsers","params":[],"type":"InputNotifyPeer"},{"id":"1251338318","predicate":"inputNotifyChats","params":[],"type":"InputNotifyPeer"},{"id":"-1540769658","predicate":"inputNotifyAll","params":[],"type":"InputNotifyPeer"},{"id":"-265263912","predicate":"inputPeerNotifyEventsEmpty","params":[],"type":"InputPeerNotifyEvents"},{"id":"-395694988","predicate":"inputPeerNotifyEventsAll","params":[],"type":"InputPeerNotifyEvents"},{"id":"1185074840","predicate":"inputPeerNotifySettings","params":[{"name":"mute_until","type":"int"},{"name":"sound","type":"string"},{"name":"show_previews","type":"Bool"},{"name":"events_mask","type":"int"}],"type":"InputPeerNotifySettings"},{"id":"-1378534221","predicate":"peerNotifyEventsEmpty","params":[],"type":"PeerNotifyEvents"},{"id":"1830677896","predicate":"peerNotifyEventsAll","params":[],"type":"PeerNotifyEvents"},{"id":"1889961234","predicate":"peerNotifySettingsEmpty","params":[],"type":"PeerNotifySettings"},{"id":"-1923214866","predicate":"peerNotifySettings","params":[{"name":"mute_until","type":"int"},{"name":"sound","type":"string"},{"name":"show_previews","type":"Bool"},{"name":"events_mask","type":"int"}],"type":"PeerNotifySettings"},{"id":"1089848634","predicate":"globalPrivacySettings","params":[{"name":"no_suggestions","type":"Bool"},{"name":"hide_contacts","type":"Bool"},{"name":"hide_located","type":"Bool"},{"name":"hide_last_visit","type":"Bool"}],"type":"GlobalPrivacySettings"},{"id":"-860866985","predicate":"wallPaper","params":[{"name":"id","type":"int"},{"name":"title","type":"string"},{"name":"sizes","type":"Vector"},{"name":"color","type":"int"}],"type":"WallPaper"},{"id":"1997575642","predicate":"userFull","params":[{"name":"user","type":"User"},{"name":"link","type":"contacts.Link"},{"name":"profile_photo","type":"Photo"},{"name":"notify_settings","type":"PeerNotifySettings"},{"name":"blocked","type":"Bool"},{"name":"real_first_name","type":"string"},{"name":"real_last_name","type":"string"}],"type":"UserFull"},{"id":"-116274796","predicate":"contact","params":[{"name":"user_id","type":"int"},{"name":"mutual","type":"Bool"}],"type":"Contact"},{"id":"-805141448","predicate":"importedContact","params":[{"name":"user_id","type":"int"},{"name":"client_id","type":"long"}],"type":"ImportedContact"},{"id":"1444661369","predicate":"contactBlocked","params":[{"name":"user_id","type":"int"},{"name":"date","type":"int"}],"type":"ContactBlocked"},{"id":"1038193057","predicate":"contactSuggested","params":[{"name":"user_id","type":"int"},{"name":"mutual_contacts","type":"int"}],"type":"ContactSuggested"},{"id":"-748155807","predicate":"contactStatus","params":[{"name":"user_id","type":"int"},{"name":"status","type":"UserStatus"}],"type":"ContactStatus"},{"id":"909233996","predicate":"chatLocated","params":[{"name":"chat_id","type":"int"},{"name":"distance","type":"int"}],"type":"ChatLocated"},{"id":"322183672","predicate":"contacts.foreignLinkUnknown","params":[],"type":"contacts.ForeignLink"},{"id":"-1484775609","predicate":"contacts.foreignLinkRequested","params":[{"name":"has_phone","type":"Bool"}],"type":"contacts.ForeignLink"},{"id":"468356321","predicate":"contacts.foreignLinkMutual","params":[],"type":"contacts.ForeignLink"},{"id":"-768992160","predicate":"contacts.myLinkEmpty","params":[],"type":"contacts.MyLink"},{"id":"1818882030","predicate":"contacts.myLinkRequested","params":[{"name":"contact","type":"Bool"}],"type":"contacts.MyLink"},{"id":"-1035932711","predicate":"contacts.myLinkContact","params":[],"type":"contacts.MyLink"},{"id":"-322001931","predicate":"contacts.link","params":[{"name":"my_link","type":"contacts.MyLink"},{"name":"foreign_link","type":"contacts.ForeignLink"},{"name":"user","type":"User"}],"type":"contacts.Link"},{"id":"-1219778094","predicate":"contacts.contactsNotModified","params":[],"type":"contacts.Contacts"},{"id":"1871416498","predicate":"contacts.contacts","params":[{"name":"contacts","type":"Vector"},{"name":"users","type":"Vector"}],"type":"contacts.Contacts"},{"id":"-1387117803","predicate":"contacts.importedContacts","params":[{"name":"imported","type":"Vector"},{"name":"retry_contacts","type":"Vector"},{"name":"users","type":"Vector"}],"type":"contacts.ImportedContacts"},{"id":"471043349","predicate":"contacts.blocked","params":[{"name":"blocked","type":"Vector"},{"name":"users","type":"Vector"}],"type":"contacts.Blocked"},{"id":"-1878523231","predicate":"contacts.blockedSlice","params":[{"name":"count","type":"int"},{"name":"blocked","type":"Vector"},{"name":"users","type":"Vector"}],"type":"contacts.Blocked"},{"id":"1447681221","predicate":"contacts.suggested","params":[{"name":"results","type":"Vector"},{"name":"users","type":"Vector"}],"type":"contacts.Suggested"},{"id":"364538944","predicate":"messages.dialogs","params":[{"name":"dialogs","type":"Vector