diff --git a/data/web/gateway.telegram.org/js/gateway.js b/data/web/gateway.telegram.org/js/gateway.js new file mode 100644 index 0000000000..e7e70c5dd3 --- /dev/null +++ b/data/web/gateway.telegram.org/js/gateway.js @@ -0,0 +1,751 @@ + +var Gateway = { + init: function() { + Aj.onLoad(function(state) { + Gateway.updateTime(Aj.ajContainer); + $('.logout-link').on('click', Gateway.eLogOut); + }); + Aj.onUnload(function(state) { + $('.logout-link').off('click', Gateway.eLogOut); + }); + }, + checkAuth: function (e) { + if (Aj.needAuth()) { + e.preventDefault(); + return false; + } + }, + eUpdateField: function(e) { + var $fieldEl = $(this); + if (e.type == 'focus' || e.type == 'focusin') { + Gateway.updateField($fieldEl, true); + } else if (e.type == 'blur' || e.type == 'focusout') { + Gateway.updateField($fieldEl, false); + } else { + Gateway.updateField($fieldEl); + } + }, + eUpdateDropdown: function(e) { + var $ddItemEl = $(this); + var $ddItemWrapEl = $ddItemEl.parents('li'); + var $ddWrapEl = $ddItemEl.parents('.input-dropdown'); + var $ddInputEl = $('.input', $ddWrapEl); + var value = $ddItemEl.data('value'); + var label = $ddItemEl.html(); + $('.dropdown-menu > li.selected', $ddWrapEl).removeClass('selected'); + $ddItemWrapEl.addClass('selected'); + $ddInputEl.data('value', value); + $ddInputEl.html(label); + $ddInputEl.trigger('ddchange'); + }, + eSetDropdownValue: function(e, val) { + var $ddInputEl = $(this); + var $ddWrapEl = $ddInputEl.parents('.input-dropdown'); + $('.input-dropdown-item', $ddWrapEl).each(function() { + var $ddItemEl = $(this); + var $ddItemWrapEl = $ddItemEl.parents('li'); + var value = $ddItemEl.data('value'); + var label = $ddItemEl.html(); + if (value == val) { + $('.dropdown-menu > li.selected', $ddWrapEl).removeClass('selected'); + $ddItemWrapEl.addClass('selected'); + $ddInputEl.data('value', value); + $ddInputEl.html(label); + } + }); + }, + eShownDropdown: function(e) { + $('.dropdown-menu > li.selected', this).scrollIntoView({position: 'top', padding: 40}); + }, + dateTimeFieldValue: function($form, date_field, time_field) { + var $dateFieldEl = time_field ? $form.field(date_field) : $form; + var $timeFieldEl = time_field ? $form.field(time_field) : date_field; + var date_value = $dateFieldEl.value(); + var time_value = $timeFieldEl.value(); + if (!date_value || !time_value) { + return ''; + } + var tz_offset = -60 * (new Date()).getTimezoneOffset(); + var is_pos = tz_offset >= 0; + if (!is_pos) tz_offset *= -1; + var h = Math.floor(tz_offset / 3600); + var m = Math.floor((tz_offset % 3600) / 60); + if (h < 10) h = '0' + h; + if (m < 10) m = '0' + m; + return date_value + 'T' + time_value + (tz_offset ? (is_pos ? '+' : '-') + h + m : 'Z'); + }, + ownerCurrencyDecimals: function() { + if (typeof Aj.state.ownerCurrencyDecimals === 'undefined') { + return 2; + } + return Aj.state.ownerCurrencyDecimals; + }, + wrapAmount: function(value, no_currency, field_format, decimals) { + var base_decimals = Gateway.ownerCurrencyDecimals(); + if (typeof decimals === 'undefined') { + decimals = base_decimals; + } + while (decimals > base_decimals) { + var val = Math.round(value * Math.pow(10, decimals)); + if (val % 10) break; + decimals--; + } + var amount_str = formatNumber(value, decimals, '.', field_format ? '' : ','); + if (no_currency) { + return amount_str; + } + var currency_str = Aj.state.ownerCurrency || ''; + var parts = amount_str.split('.'); + amount_str = parts[0] + (parts.length > 1 && parts[1].length ? '.' + parts[1] + '' : ''); + return currency_str + amount_str; + }, + wrapEurAmount: function(value, field_format) { + var rate = Aj.state.ownerCurrencyRate || 1; + value = Math.round(value * rate * 100) / 100; + return '~' + formatNumber(value, (value % 1) && value < 1000 ? 2 : 0, '.', field_format ? '' : ','); + }, + amountFieldValue: function($form, field) { + var $fieldEl = field ? $form.field(field) : $($form); + var minValue = $fieldEl.attr('data-min') || null; + var maxValue = $fieldEl.attr('data-max') || null; + var decPoint = $fieldEl.attr('data-dec-point') || '.'; + var decimals = $fieldEl.attr('data-decimals') || Gateway.ownerCurrencyDecimals(); + var value = $fieldEl.value(); + + var float_value = value.length ? value : '0'; + if (decPoint != '.') { + float_value.split(decPoint).join('.'); + } + float_value = parseFloat(float_value); + if (isNaN(float_value) || float_value >= 1e9) { + return false; + } + if (minValue !== null && float_value < minValue || + maxValue !== null && float_value > maxValue) { + return false; + } else { + return float_value; + } + }, + updateAmountEurValue: function(field) { + var $eurEl = $('~*>.js-amount-eur', field); + if (Aj.state.ownerCurrencyRate) { + var float_value = Gateway.amountFieldValue(field); + if (float_value !== false && $(field).value()) { + $eurEl.addClass('active').html(Gateway.wrapEurAmount(float_value)); + } else { + $eurEl.removeClass('active'); + } + } else { + $eurEl.removeClass('active'); + } + }, + eUpdateAmountField: function(e) { + var $fieldEl = $(this); + var minValue = $fieldEl.attr('data-min') || null; + var maxValue = $fieldEl.attr('data-max') || null; + var decPoint = $fieldEl.attr('data-dec-point') || '.'; + var decimals = $fieldEl.attr('data-decimals') || Gateway.ownerCurrencyDecimals(); + var sel_dir = this.selectionDirection; + var sel_start = this.selectionStart; + var sel_end = this.selectionEnd; + var value = this.value; + var new_sel_start = sel_start; + var new_sel_end = sel_end; + var new_value = ''; + var has_decimal = false; + var chars_len = 0; + var decimal_len = 0; + for (var i = 0; i < value.length; i++) { + var char = value[i]; + if ((char == '.' || char == ',') && !has_decimal && decimals > 0) { + if (!chars_len) { + new_value += '0'; + if (i < sel_start) new_sel_start++; + if (i < sel_end) new_sel_end++; + } + has_decimal = true; + new_value += decPoint; + } else if (char >= '0' && char <= '9' && (!has_decimal || decimal_len < decimals)) { + new_value += char; + if (has_decimal) decimal_len++; + else chars_len++; + } else { + if (i < sel_start) new_sel_start--; + if (i < sel_end) new_sel_end--; + } + } + this.value = new_value; + this.setSelectionRange(new_sel_start, new_sel_end, sel_dir); + var float_value = new_value.length ? new_value : '0'; + if (decPoint != '.') { + float_value.split(decPoint).join('.'); + } + float_value = parseFloat(float_value); + var is_invalid = (isNaN(float_value) || float_value >= 1e9); + if (minValue !== null && float_value < minValue || + maxValue !== null && float_value > maxValue || + is_invalid) { + Gateway.showFieldError($fieldEl); + } else { + Gateway.hideFieldError($fieldEl); + } + if (e.type == 'change') { + if (new_value.length && !is_invalid) { + this.value = Gateway.wrapAmount(float_value, true, true, decimals); + } + } + Gateway.updateAmountEurValue(this); + }, + updateField: function($fieldEl, focused) { + var $formGroup = $fieldEl.fieldEl().parents('.form-group'); + if (typeof focused !== 'undefined') { + $formGroup.toggleClass('field-focused', focused); + } + var $select = $fieldEl.parents('.select'); + var selectedCnt = $select.find('.selected-item').size(); + $formGroup.toggleClass('noinput', $select.hasClass('no-search') && !selectedCnt); + var hasValue = $fieldEl.value().length > 0 || selectedCnt > 0; + $formGroup.toggleClass('field-has-value', hasValue); + }, + showFieldHint: function($fieldEl, hint_text, field_invalid) { + var $formGroup = $fieldEl.fieldEl().parents('.form-group'); + var $hint = $formGroup.find('>.gw-form-control-hint'); + var $msg = $formGroup.find('>.gw-form-control-msg'); + if (!$msg.size() && hint_text) { + $msg = $('
'); + $formGroup.find('>.gw-form-control-wrap,>.datetime-group,>.gw-btn').after($msg); + } + $msg.toggleClass('no-hint', !$hint.text().length); + if (hint_text) { + $msg.html('
' + hint_text + '
').redraw().slideShow(); + } else { + $msg.slideHide(); + } + $formGroup.toggleClass('field-invalid', !!field_invalid); + }, + showFieldError: function($fieldEl, error_text, focus) { + Gateway.showFieldHint($fieldEl, error_text, true); + if (focus) { + if ($fieldEl.hasClass('select')) { + $fieldEl.trigger('click'); + $fieldEl.find('.items-list').addClass('collapsed'); + $fieldEl.removeClass('open'); + } else if (!$fieldEl.is('[type="file"],[type="date"],[type="time"]')) { + $fieldEl.focusAndSelect(); + } + } + }, + hideFieldError: function($fieldEl) { + Gateway.showFieldHint($fieldEl, '', false); + }, + onSelectChange: function(field, value, valueFull) { + var $fieldEl = Aj.state.$form.field(field); + Gateway.hideFieldError($fieldEl); + if (Aj.state.selectList) { + for (var i = 0; i < Aj.state.selectList.length; i++) { + var selectData = Aj.state.selectList[i]; + if (selectData.field == field && + selectData.update_cpm) { + NewAd.adPostCheck(Aj.state.$form); + } + } + } + }, + updateTime: function(context) { + $('time[datetime]', context).each(function () { + var $time = $(this), datetime = $time.attr('datetime'), title = $time.attr('title'), html = $time.html(), new_html = formatDateTime(datetime, $time.hasClass('short')); + if (html != new_html) { + $time.html(new_html); + } + if ($time.hasClass('short') && title) { + var new_title = formatDateTime(datetime); + if (title != new_title) { + $time.attr('title', new_title); + } + } + $time.removeAttr('datetime'); + }); + }, + formatTableDate: function(timestamp) { + var date = new Date(timestamp * 1000); + var j = date.getDate(); + var M = ['Jan', 'Feb', 'Mar', 'Apr', 'May', 'Jun', 'Jul', 'Aug', 'Sep', 'Oct', 'Nov', 'Dec'][date.getMonth()]; + var y = date.getFullYear() % 100; + return j + ' ' + M + ' ' + y + ' ' + formatTime(timestamp * 1000); + }, + fieldInit: function(field) { + $(field).on('focus blur keyup change input', Gateway.eUpdateField); + $(field).parents('.gw-search-input-wrap').find('.gw-search-reset').on('click', Gateway.eClearField); + Gateway.updateField($(field)); + }, + fieldDestroy: function(field) { + $(field).off('focus blur keyup change input', Gateway.eUpdateField); + $(field).parents('.gw-search-input-wrap').find('.gw-search-reset').off('click', Gateway.eClearField); + }, + formInit: function(form) { + var $form = $(form); + $('.gw-form-control', $form).each(function(){ Gateway.fieldInit(this); }); + $('.js-amount-input', $form).on('keyup change input', Gateway.eUpdateAmountField); + $('input.checkbox,input.radio', $form).on('focus blur', Gateway.eUpdateField); + $('.input-dropdown', $form).on('click', '.input-dropdown-item', Gateway.eUpdateDropdown); + $('.input-dropdown > .input', $form).on('selectval', Gateway.eSetDropdownValue); + $('.input-dropdown', $form).on('shown.bs.dropdown', Gateway.eShownDropdown); + $('.js-hint-tooltip', $form).on('mouseover mouseout click', Gateway.eHintEvent); + $('textarea.gw-form-control', $form).initAutosize(); + $('.upload-input input', $form).on('change', Gateway.eFileChange); + $('.upload-input .js-file-reset', $form).on('click', Gateway.eFileReset); + $(document).on('touchstart click', Gateway.eHideAllHints); + $form.on('click.curPage', '.file-upload', stopImmediatePropagation); + setTimeout(function(){ $form.removeClass('no-transition'); }, 100); + }, + formDestroy: function(form) { + var $form = $(form); + $('.gw-form-control', $form).each(function(){ Gateway.fieldDestroy(this); }); + $('.js-amount-input', $form).off('keyup change input', Gateway.eUpdateAmountField); + $('input.checkbox,input.radio', $form).off('focus blur', Gateway.eUpdateField); + $('.input-dropdown', $form).off('click', '.input-dropdown-item', Gateway.eUpdateDropdown); + $('.input-dropdown > .input', $form).off('selectval', Gateway.eSetDropdownValue); + $('.input-dropdown', $form).off('shown.bs.dropdown', Gateway.eShownDropdown); + $('.js-hint-tooltip', $form).off('mouseover mouseout click', Gateway.eHintEvent); + $('textarea.gw-form-control', $form).destroyAutosize(); + $('.upload-input input', $form).off('change', Gateway.eFileChange); + $('.upload-input .js-file-reset', $form).off('click', Gateway.eFileReset); + $(document).off('touchstart click', Gateway.eHideAllHints); + $form.off('click.curPage', '.file-upload', stopImmediatePropagation); + }, + eClearField: function(e) { + var $fieldEl = $(this).parents('.gw-search-input-wrap').find('.gw-search-input'); + $fieldEl.value('').trigger('input').focus(); + }, + eFileChange: function(e) { + var files = this.files || []; + var $field = $(this); + var $input = $field.parents('.upload-input'); + var $fileName = $('.js-selected-value', $input); + if (files.length > 0) { + var file = files[0]; + $field.data('file', file) + $fileName.attr('data-filename', file.name); + $input.addClass('selected'); + } else { + $field.data('file', null); + $fileName.attr('data-filename', ''); + $input.removeClass('selected'); + } + Gateway.hideFieldError($field); + }, + eFileReset: function(e) { + var $input = $(this).parents('.upload-input'); + var $field = $input.find('input'); + var $fileName = $('.js-selected-value', $input); + $field.data('file', null).val(''); + $fileName.attr('data-filename', ''); + $input.removeClass('selected'); + Gateway.hideFieldError($field); + }, + showHint: function($hint, delay, hide_delay) { + hide_delay = hide_delay || 0; + var show_to = $hint.data('show_to'); + var hide_to = $hint.data('hide_to'); + clearTimeout(show_to); + clearTimeout(hide_to); + show_to = setTimeout(function() { + $hint.addClass('show-hint'); + if (hide_delay > 0) { + Gateway.hideHint($hint, hide_delay); + } + }, delay); + $hint.data('show_to', show_to); + }, + hideHint: function($hint, delay) { + var show_to = $hint.data('show_to'); + var hide_to = $hint.data('hide_to'); + clearTimeout(show_to); + clearTimeout(hide_to); + hide_to = setTimeout(function() { + $hint.removeClass('show-hint'); + }, delay); + $hint.data('hide_to', hide_to); + }, + eHintEvent: function(e) { + var $hint = $(this); + if (e.type == 'click') { + Gateway.showHint($hint, 50, 2000); + } else if (e.type == 'mouseover') { + Gateway.showHint($hint, 400); + } else if (e.type == 'mouseout') { + Gateway.hideHint($hint, 100); + } + }, + eHideAllHints: function(e) { + var $closestHint = $(e.target).closest('.js-hint-tooltip'); + $('.js-hint-tooltip.show-hint').each(function() { + if (!$closestHint.filter(this).size()) { + Gateway.hideHint($(this), 1); + } + }); + }, + updateTextShadow: function(footerEl, textSel, shadowedSel, add_margin) { + var textEl = footerEl.previousElementSibling; + if (textEl && $(textEl).is(textSel)) { + var text_rect = textEl.getBoundingClientRect(); + var tnode = textEl.firstChild; + while (tnode && tnode.nodeType == tnode.ELEMENT_NODE) { + tnode = tnode.firstChild; + } + $(textEl).removeClass('before_footer'); + if (tnode) { + var r = document.createRange(); + r.setStart(tnode, 0); + r.setEnd(tnode, 1); + var char_rect = r.getBoundingClientRect(); + if (Math.abs(char_rect.right - text_rect.right) > 3) { + var $infoEl = $(footerEl).find(shadowedSel); + if ($infoEl.size()) { + $(textEl).find('span.js-shadow').remove(); + var $shadowEl = $('').css('display', 'inline-block').width($infoEl.width() + (add_margin || 0)); + $(textEl).append($shadowEl).addClass('before_footer'); + } + } + } + } + }, + initSelect: function($form, field, options) { + var $selectEl = $form.field(field); + var $selectInput = $('.input', $selectEl); + options = options || {}; + $selectEl.data('selOpts', options); + var onload = function(state) { + var cachedData; + $selectEl.initSelect({ + multiSelect: !options.noMultiSelect, + noCloseOnSelect: false, + noCloseOnEnter: !!options.onEnter, + enterOnClose: true, + enterEnabled: function() { + return !!options.onEnter; + }, + prepareQuery: function(str) { + return $.trim(str).toLowerCase(); + }, + renderItem: options.renderItem, + appendToItems: options.appendToItems, + renderSelectedItem: options.renderSelectedItem, + renderNoItems: function(q) { + return q && options.l_no_items_found ? '
' + options.l_no_items_found + '
' : ''; + }, + getData: function(value) { + if (cachedData !== false && !cachedData) { + cachedData = false; + if (options.items) { + var data = options.items; + for (var i = 0; i < data.length; i++) { + var item = data[i]; + item._values = [item.name.toLowerCase()]; + } + cachedData = data; + } + } + if (options.getData) { + return options.getData(value, cachedData, options.getDataOpts); + } else { + return cachedData; + } + }, + onBlur: function(value) { + options.onBlur && options.onBlur(field, options.getDataOpts); + }, + onEnter: function(value) { + options.onEnter && options.onEnter(field, value); + }, + onChange: function(value, valueFull) { + options.onChange && options.onChange(field, value, valueFull); + }, + onUpdate: function(value, valueFull) { + Gateway.updateField($selectInput); + options.onUpdate && options.onUpdate(field, value, valueFull); + } + }); + Gateway.updateField($selectInput); + }; + var onunload = function(state) { + $selectEl.destroySelect(); + }; + if (options.insideLayer) { + Aj.onLayerLoad(onload); + Aj.onLayerUnload(onunload); + } else { + Aj.onLoad(onload); + Aj.onUnload(onunload); + } + }, + getSelectItems: function(method, need_fields) { + var _data = Aj.globalState.adsList; + if (_data === false) { + return false; + } else if (_data) { + return _data; + } + Aj.state.adsList = false; + Aj.state.adsListIsLoading = true; + if (Aj.state.initialAdsList) { + setTimeout(function() { + OwnerGateway.processAdsList(Aj.state.initialAdsList); + }, 10); + } else { + OwnerGateway.loadAdsList({offset: 0}); + } + return false; + }, + getTimezoneText: function(tz_offset) { + if (typeof tz_offset === 'undefined') { + tz_offset = -60 * (new Date()).getTimezoneOffset(); + } + var is_pos = tz_offset >= 0; + if (!is_pos) tz_offset *= -1; + var h = Math.floor(tz_offset / 3600); + var m = Math.floor((tz_offset % 3600) / 60); + if (m < 10) m = '0' + m; + return 'UTC' + (tz_offset ? (is_pos ? '+' : '-') + h + ':' + m : ''); + }, + eLogOut: function(e) { + e.preventDefault(); + e.stopImmediatePropagation(); + Aj.apiRequest('logOut', {}, function(result) { + location.reload(); + }); + return false; + } +}; + +var Account = { + formFields: [ + 'name', + 'full_name', + 'email', + 'phone_number', + 'country', + 'city' + ], + init: function() { + var cont = Aj.ajContainer; + Aj.onLoad(function(state) { + state.$form = $('.account-edit-form', cont); + Gateway.formInit(state.$form); + state.$form.on('submit', preventDefault); + cont.on('click.curPage', '.save-info-btn', Account.eSubmitForm); + cont.on('change.curPage', '.gw-form-control', Account.onFieldChange); + Aj.onLoad(function(state) { + state.initFormData = Account.getFormData(state.$form); + Aj.onBeforeUnload(function() { + var curFormData = Account.getFormData(state.$form); + if (Aj.state.initFormData != curFormData) { + return l('WEB_LEAVE_PAGE_CONFIRM_TEXT'); + } + return false; + }); + }); + }); + Aj.onUnload(function(state) { + Gateway.formDestroy(state.$form); + state.$form.off('submit', preventDefault); + }); + }, + onFieldChange: function() { + if (!$(this).hasClass('js-amount-input')) { + Gateway.hideFieldError($(this)); + } + }, + getFormData: function($form) { + var form = $form.get(0); + if (!form) return false; + var values = []; + for (var i = 0; i < Account.formFields.length; i++) { + var field = Account.formFields[i]; + var value = $form.field(field).value(); + values.push(value); + } + return values.join('|'); + }, + eSubmitForm: function(e) { + e.preventDefault(); + var $form = Aj.state.$form; + var $button = $(this); + var method = 'createAccount'; + var params = {}; + if (Aj.state.accountId) { + method = 'editAccountInfo'; + params.account_id = Aj.state.accountId; + } + for (var i = 0; i < Account.formFields.length; i++) { + var field = Account.formFields[i]; + var value = $form.field(field).value(); + if (!value.length && !Account.optFields[field]) { + $form.field(field).focus(); + return false; + } + params[field] = value; + } + + $button.prop('disabled', true); + Aj.apiRequest(method, params, function(result) { + if (result.error) { + $button.prop('disabled', false); + if (result.field) { + var $field = $form.field(result.field); + if ($field.size()) { + Gateway.showFieldError($field, result.error, true); + return false; + } + } + return showAlert(result.error); + } + Aj.state.initFormData = Account.getFormData($form); + if (result.redirect_to) { + Aj.location(result.redirect_to); + } + }); + return false; + }, + initToken: function() { + var cont = Aj.ajContainer; + Aj.onLoad(function(state) { + cont.on('click.curPage', '.js-copy-token-btn', Account.eCopyToken); + cont.on('click.curPage', '.js-revoke-token-btn', Account.eRevokeToken); + state.$form = $('.api-edit-form', cont); + Gateway.formInit(state.$form); + state.$form.on('submit', preventDefault); + cont.on('click.curPage', '.js-save-settings-btn', Account.eApiSubmitForm); + cont.on('change.curPage', '.gw-form-control', Account.onFieldChange); + }); + }, + eCopyToken: function(e) { + e.preventDefault(); + copyToClipboard(Aj.state.token); + showToast(l('WEB_TOKEN_COPIED', 'Copied.')); + }, + revokeTokenPopup: function (onConfirm) { + var $confirm = $(''); + var confirm = function() { + onConfirm && onConfirm($confirm); + closePopup($confirm); + } + var $primaryBtn = $('.popup-primary-btn', $confirm); + $primaryBtn.on('click', confirm); + $confirm.one('popup:close', function() { + $primaryBtn.off('click', confirm); + $confirm.remove(); + }); + openPopup($confirm, { + closeByClickOutside: '.popup-no-close', + }); + return $confirm; + }, + eRevokeToken: function(e) { + e.preventDefault(); + var $btn = $(this); + if ($btn.data('disabled')) { + return false; + } + Account.revokeTokenPopup(function() { + $btn.data('disabled', true); + Aj.apiRequest('revokeToken', { + account_id: Aj.state.accountId + }, function(result) { + $btn.data('disabled', false); + if (result.error) { + return showAlert(result.error); + } + if (result.new_token) { + Aj.state.token = result.new_token; + } + if (result.new_token_value) { + $('.js-token-value', Aj.ajContainer).value(result.new_token_value); + } + if (result.toast) { + showToast(result.toast); + } + }); + }); + return false; + }, + eApiSubmitForm: function(e) { + e.preventDefault(); + var $form = Aj.state.$form; + var $button = $(this); + var params = { + account_id: Aj.state.accountId, + ip_list: $form.field('ip_list').value() + }; + $button.prop('disabled', true); + Aj.apiRequest('saveApiSettings', params, function(result) { + $button.prop('disabled', false); + if (result.error) { + if (result.field) { + var $field = $form.field(result.field); + if ($field.size()) { + Gateway.showFieldError($field, result.error, true); + return false; + } + } + return showAlert(result.error); + } + if (result.new_ip_list) { + $form.field('ip_list').value(result.new_ip_list).updateAutosize(); + } + if (result.toast) { + showToast(result.toast); + } + }); + return false; + } +}; + +var LogHistory = { + init: function() { + Aj.onLoad(function(state) { + $(document).on('click.curPage', '.js-load-more-rows', LogHistory.eLoadMoreRows); + $(window).on('scroll resize', LogHistory.onScroll); + LogHistory.onScroll(); + }); + Aj.onUnload(function(state) { + $(window).off('scroll resize', LogHistory.onScroll); + }); + }, + onScroll: function() { + $('.js-load-more-rows').each(function() { + var $loadMore = $(this); + var top = $loadMore.offset().top - $(window).scrollTop(); + if (top < $(window).height() * 2) { + LogHistory.loadRows($loadMore); + } + }); + }, + eLoadMoreRows: function(e) { + e.preventDefault(); + var $loadMore = $(this); + LogHistory.loadRows($loadMore); + }, + loadRows: function($loadMore) { + if ($loadMore.data('loading')) { + return; + } + var $table = $loadMore.closest('table'); + var offset = $loadMore.attr('data-next-offset'); + $loadMore.data('loading', true); + Aj.apiRequest('getLogHistory', { + account_id: Aj.state.accountId, + offset: offset + }, function(result) { + $loadMore.data('loading', false); + if (result.error) { + return showAlert(result.error); + } + $('tbody', $table).append(result.body); + $('tfoot', $table).html(result.foot); + LogHistory.onScroll(); + }); + } +}; + diff --git a/data/web/telegram.org/moderation.html b/data/web/telegram.org/moderation.html index 97b5eea2ac..612f48a3d2 100644 --- a/data/web/telegram.org/moderation.html +++ b/data/web/telegram.org/moderation.html @@ -278,12 +278,12 @@
Moderation
}, 0); setTimeout(function () { - var chart = renderGraph('chart_csam_banned_wrap', {"title":"","columns":[["x",1705190400000,1705276800000,1705363200000,1705449600000,1705536000000,1705622400000,1705708800000,1705795200000,1705881600000,1705968000000,1706054400000,1706140800000,1706227200000,1706313600000,1706400000000,1706486400000,1706572800000,1706659200000,1706745600000,1706832000000,1706918400000,1707004800000,1707091200000,1707177600000,1707264000000,1707350400000,1707436800000,1707523200000,1707609600000,1707696000000,1707782400000,1707868800000,1707955200000,1708041600000,1708128000000,1708214400000,1708300800000,1708387200000,1708473600000,1708560000000,1708646400000,1708732800000,1708819200000,1708905600000,1708992000000,1709078400000,1709164800000,1709251200000,1709337600000,1709424000000,1709510400000,1709596800000,1709683200000,1709769600000,1709856000000,1709942400000,1710028800000,1710115200000,1710201600000,1710288000000,1710374400000,1710460800000,1710547200000,1710633600000,1710720000000,1710806400000,1710892800000,1710979200000,1711065600000,1711152000000,1711238400000,1711324800000,1711411200000,1711497600000,1711584000000,1711670400000,1711756800000,1711843200000,1711929600000,1712016000000,1712102400000,1712188800000,1712275200000,1712361600000,1712448000000,1712534400000,1712620800000,1712707200000,1712793600000,1712880000000,1712966400000,1713052800000,1713139200000,1713225600000,1713312000000,1713398400000,1713484800000,1713571200000,1713657600000,1713744000000,1713830400000,1713916800000,1714003200000,1714089600000,1714176000000,1714262400000,1714348800000,1714435200000,1714521600000,1714608000000,1714694400000,1714780800000,1714867200000,1714953600000,1715040000000,1715126400000,1715212800000,1715299200000,1715385600000,1715472000000,1715558400000,1715644800000,1715731200000,1715817600000,1715904000000,1715990400000,1716076800000,1716163200000,1716249600000,1716336000000,1716422400000,1716508800000,1716595200000,1716681600000,1716768000000,1716854400000,1716940800000,1717027200000,1717113600000,1717200000000,1717286400000,1717372800000,1717459200000,1717545600000,1717632000000,1717718400000,1717804800000,1717891200000,1717977600000,1718064000000,1718150400000,1718236800000,1718323200000,1718409600000,1718496000000,1718582400000,1718668800000,1718755200000,1718841600000,1718928000000,1719014400000,1719100800000,1719187200000,1719273600000,1719360000000,1719446400000,1719532800000,1719619200000,1719705600000,1719792000000,1719878400000,1719964800000,1720051200000,1720137600000,1720224000000,1720310400000,1720396800000,1720483200000,1720569600000,1720656000000,1720742400000,1720828800000,1720915200000,1721001600000,1721088000000,1721174400000,1721260800000,1721347200000,1721433600000,1721520000000,1721606400000,1721692800000,1721779200000,1721865600000,1721952000000,1722038400000,1722124800000,1722211200000,1722297600000,1722384000000,1722470400000,1722556800000,1722643200000,1722729600000,1722816000000,1722902400000,1722988800000,1723075200000,1723161600000,1723248000000,1723334400000,1723420800000,1723507200000,1723593600000,1723680000000,1723766400000,1723852800000,1723939200000,1724025600000,1724112000000,1724198400000,1724284800000,1724371200000,1724457600000,1724544000000,1724630400000,1724716800000,1724803200000,1724889600000,1724976000000,1725062400000,1725148800000,1725235200000,1725321600000,1725408000000,1725494400000,1725580800000,1725667200000,1725753600000,1725840000000,1725926400000,1726012800000,1726099200000,1726185600000,1726272000000,1726358400000,1726444800000,1726531200000,1726617600000,1726704000000,1726790400000,1726876800000,1726963200000,1727049600000,1727136000000,1727222400000,1727308800000,1727395200000,1727481600000,1727568000000,1727654400000,1727740800000,1727827200000,1727913600000,1728000000000,1728086400000,1728172800000,1728259200000,1728345600000,1728432000000,1728518400000,1728604800000,1728691200000,1728777600000,1728864000000,1728950400000,1729036800000,1729123200000,1729209600000,1729296000000,1729382400000,1729468800000,1729555200000,1729641600000,1729728000000,1729814400000,1729900800000,1729987200000,1730073600000,1730160000000,1730246400000,1730332800000,1730419200000,1730505600000,1730592000000,1730678400000,1730764800000,1730851200000,1730937600000,1731024000000,1731110400000,1731196800000,1731283200000,1731369600000,1731456000000,1731542400000,1731628800000,1731715200000,1731801600000,1731888000000,1731974400000,1732060800000,1732147200000,1732233600000,1732320000000,1732406400000,1732492800000,1732579200000,1732665600000,1732752000000,1732838400000,1732924800000,1733011200000,1733097600000,1733184000000,1733270400000,1733356800000,1733443200000,1733529600000,1733616000000,1733702400000,1733788800000,1733875200000,1733961600000,1734048000000,1734134400000,1734220800000,1734307200000,1734393600000,1734480000000,1734566400000,1734652800000,1734739200000,1734825600000,1734912000000,1734998400000,1735084800000,1735171200000,1735257600000,1735344000000,1735430400000,1735516800000,1735603200000,1735689600000,1735776000000,1735862400000,1735948800000,1736035200000,1736121600000,1736208000000,1736294400000,1736380800000,1736467200000,1736553600000,1736640000000,1736726400000],["y0",2047,2051,2528,2072,1877,1607,1593,2282,1702,1650,2518,2204,2509,2159,1770,2518,2670,2169,2024,2232,1572,1879,1836,2651,2048,2021,2344,2676,2057,2121,2502,2317,3402,2288,2100,1642,2353,1970,1949,2107,1681,1796,1702,2003,1857,2690,1703,1843,1910,2123,2326,1987,2241,2551,1754,1587,2073,2002,2103,1979,1839,1681,1880,2387,2281,2453,1812,1867,2338,1815,1974,2071,2643,1979,2418,2230,1996,1801,2276,2015,2596,2590,1754,2219,1910,2735,2472,2572,1987,1967,2405,1943,2346,1950,2295,2336,2096,1781,2622,2164,2497,1852,2100,2088,2639,2029,2335,1958,2070,2015,2151,1975,1800,1976,2312,1764,2362,1859,2067,2226,2207,2323,2134,2349,1939,2134,2207,2323,2362,2046,2007,2502,2252,2328,2394,2327,2299,2195,1938,1926,2124,2725,2196,2386,2257,1866,2050,2127,2161,2321,1516,1705,1833,1962,1820,2049,1916,1978,1738,2315,2204,2677,2034,2345,2497,1809,2036,2116,1698,1719,2238,2408,1963,1854,1796,2047,2417,1982,1968,1910,2071,1841,1736,1958,1641,2256,1879,2303,2156,2372,1973,2262,2423,1643,2193,2156,2384,2210,1883,1761,1736,1680,1704,1915,1840,1815,1882,1742,1953,1784,1707,1710,1821,1933,1571,1552,1604,1634,1914,1826,1548,1558,1581,1655,1650,2119,1615,1505,1732,1824,1849,1863,1839,1792,2065,2222,1972,1951,2156,1823,1786,1678,1919,1984,2007,2080,1910,1705,2033,2114,1772,1963,1939,1788,2015,1765,1860,1527,2228,2027,2347,2027,2056,1817,1714,1666,1768,1888,1733,1966,1918,1697,1818,2020,1862,1632,1894,1632,1434,1474,2108,2123,1752,1925,1577,1707,1655,1704,1942,1631,1778,1623,1717,1588,1654,1815,1466,1861,1837,1461,1557,1981,1671,1973,1839,1726,1497,1805,1759,1948,1521,1814,1458,1777,2016,2243,2097,2148,1644,1766,3683,3965,3516,3034,2400,2356,2398,1973,2305,2032,2343,2070,2074,1927,1859,1888,1908,2092,2305,2231,2043,2324,1945,2103,1917,2159,2343,2196,2489,2015,2243,2183,1835,1872,2110,2075,2419,1954,2301,2720,1998,2070,1973,1672,1879,0]],"types":{"y0":"bar","x":"x"},"names":{"y0":"CSAM Groups and Channels Banned"},"colors":{"y0":"#3ea6f0"},"hidden":[],"subchart":{"show":true,"defaultZoom":[1734134400000,1736726400000]},"strokeWidth":2,"xTickFormatter":"statsFormat('day')","xTooltipFormatter":"statsTooltipFormat('day')","xRangeFormatter":"null","yTickFormatter":"null","yTooltipFormatter":"statsFormatTooltipValue","sideLegend":"statsNeedSideLegend()","tooltipOnHover":true}, true); + var chart = renderGraph('chart_csam_banned_wrap', {"title":"","columns":[["x",1705190400000,1705276800000,1705363200000,1705449600000,1705536000000,1705622400000,1705708800000,1705795200000,1705881600000,1705968000000,1706054400000,1706140800000,1706227200000,1706313600000,1706400000000,1706486400000,1706572800000,1706659200000,1706745600000,1706832000000,1706918400000,1707004800000,1707091200000,1707177600000,1707264000000,1707350400000,1707436800000,1707523200000,1707609600000,1707696000000,1707782400000,1707868800000,1707955200000,1708041600000,1708128000000,1708214400000,1708300800000,1708387200000,1708473600000,1708560000000,1708646400000,1708732800000,1708819200000,1708905600000,1708992000000,1709078400000,1709164800000,1709251200000,1709337600000,1709424000000,1709510400000,1709596800000,1709683200000,1709769600000,1709856000000,1709942400000,1710028800000,1710115200000,1710201600000,1710288000000,1710374400000,1710460800000,1710547200000,1710633600000,1710720000000,1710806400000,1710892800000,1710979200000,1711065600000,1711152000000,1711238400000,1711324800000,1711411200000,1711497600000,1711584000000,1711670400000,1711756800000,1711843200000,1711929600000,1712016000000,1712102400000,1712188800000,1712275200000,1712361600000,1712448000000,1712534400000,1712620800000,1712707200000,1712793600000,1712880000000,1712966400000,1713052800000,1713139200000,1713225600000,1713312000000,1713398400000,1713484800000,1713571200000,1713657600000,1713744000000,1713830400000,1713916800000,1714003200000,1714089600000,1714176000000,1714262400000,1714348800000,1714435200000,1714521600000,1714608000000,1714694400000,1714780800000,1714867200000,1714953600000,1715040000000,1715126400000,1715212800000,1715299200000,1715385600000,1715472000000,1715558400000,1715644800000,1715731200000,1715817600000,1715904000000,1715990400000,1716076800000,1716163200000,1716249600000,1716336000000,1716422400000,1716508800000,1716595200000,1716681600000,1716768000000,1716854400000,1716940800000,1717027200000,1717113600000,1717200000000,1717286400000,1717372800000,1717459200000,1717545600000,1717632000000,1717718400000,1717804800000,1717891200000,1717977600000,1718064000000,1718150400000,1718236800000,1718323200000,1718409600000,1718496000000,1718582400000,1718668800000,1718755200000,1718841600000,1718928000000,1719014400000,1719100800000,1719187200000,1719273600000,1719360000000,1719446400000,1719532800000,1719619200000,1719705600000,1719792000000,1719878400000,1719964800000,1720051200000,1720137600000,1720224000000,1720310400000,1720396800000,1720483200000,1720569600000,1720656000000,1720742400000,1720828800000,1720915200000,1721001600000,1721088000000,1721174400000,1721260800000,1721347200000,1721433600000,1721520000000,1721606400000,1721692800000,1721779200000,1721865600000,1721952000000,1722038400000,1722124800000,1722211200000,1722297600000,1722384000000,1722470400000,1722556800000,1722643200000,1722729600000,1722816000000,1722902400000,1722988800000,1723075200000,1723161600000,1723248000000,1723334400000,1723420800000,1723507200000,1723593600000,1723680000000,1723766400000,1723852800000,1723939200000,1724025600000,1724112000000,1724198400000,1724284800000,1724371200000,1724457600000,1724544000000,1724630400000,1724716800000,1724803200000,1724889600000,1724976000000,1725062400000,1725148800000,1725235200000,1725321600000,1725408000000,1725494400000,1725580800000,1725667200000,1725753600000,1725840000000,1725926400000,1726012800000,1726099200000,1726185600000,1726272000000,1726358400000,1726444800000,1726531200000,1726617600000,1726704000000,1726790400000,1726876800000,1726963200000,1727049600000,1727136000000,1727222400000,1727308800000,1727395200000,1727481600000,1727568000000,1727654400000,1727740800000,1727827200000,1727913600000,1728000000000,1728086400000,1728172800000,1728259200000,1728345600000,1728432000000,1728518400000,1728604800000,1728691200000,1728777600000,1728864000000,1728950400000,1729036800000,1729123200000,1729209600000,1729296000000,1729382400000,1729468800000,1729555200000,1729641600000,1729728000000,1729814400000,1729900800000,1729987200000,1730073600000,1730160000000,1730246400000,1730332800000,1730419200000,1730505600000,1730592000000,1730678400000,1730764800000,1730851200000,1730937600000,1731024000000,1731110400000,1731196800000,1731283200000,1731369600000,1731456000000,1731542400000,1731628800000,1731715200000,1731801600000,1731888000000,1731974400000,1732060800000,1732147200000,1732233600000,1732320000000,1732406400000,1732492800000,1732579200000,1732665600000,1732752000000,1732838400000,1732924800000,1733011200000,1733097600000,1733184000000,1733270400000,1733356800000,1733443200000,1733529600000,1733616000000,1733702400000,1733788800000,1733875200000,1733961600000,1734048000000,1734134400000,1734220800000,1734307200000,1734393600000,1734480000000,1734566400000,1734652800000,1734739200000,1734825600000,1734912000000,1734998400000,1735084800000,1735171200000,1735257600000,1735344000000,1735430400000,1735516800000,1735603200000,1735689600000,1735776000000,1735862400000,1735948800000,1736035200000,1736121600000,1736208000000,1736294400000,1736380800000,1736467200000,1736553600000,1736640000000,1736726400000],["y0",2047,2051,2528,2072,1877,1607,1593,2282,1702,1650,2518,2204,2509,2159,1770,2518,2670,2169,2024,2232,1572,1879,1836,2651,2048,2021,2344,2676,2057,2121,2502,2317,3402,2288,2100,1642,2353,1970,1949,2107,1681,1796,1702,2003,1857,2690,1703,1843,1910,2123,2326,1987,2241,2551,1754,1587,2073,2002,2103,1979,1839,1681,1880,2387,2281,2453,1812,1867,2338,1815,1974,2071,2643,1979,2418,2230,1996,1801,2276,2015,2596,2590,1754,2219,1910,2735,2472,2572,1987,1967,2405,1943,2346,1950,2295,2336,2096,1781,2622,2164,2497,1852,2100,2088,2639,2029,2335,1958,2070,2015,2151,1975,1800,1976,2312,1764,2362,1859,2067,2226,2207,2323,2134,2349,1939,2134,2207,2323,2362,2046,2007,2502,2252,2328,2394,2327,2299,2195,1938,1926,2124,2725,2196,2386,2257,1866,2050,2127,2161,2321,1516,1705,1833,1962,1820,2049,1916,1978,1738,2315,2204,2677,2034,2345,2497,1809,2036,2116,1698,1719,2238,2408,1963,1854,1796,2047,2417,1982,1968,1910,2071,1841,1736,1958,1641,2256,1879,2303,2156,2372,1973,2262,2423,1643,2193,2156,2384,2210,1883,1761,1736,1680,1704,1915,1840,1815,1882,1742,1953,1784,1707,1710,1821,1933,1571,1552,1604,1634,1914,1826,1548,1558,1581,1655,1650,2119,1615,1505,1732,1824,1849,1863,1839,1792,2065,2222,1972,1951,2156,1823,1786,1678,1919,1984,2007,2080,1910,1705,2033,2114,1772,1963,1939,1788,2015,1765,1860,1527,2228,2027,2347,2027,2056,1817,1714,1666,1768,1888,1733,1966,1918,1697,1818,2020,1862,1632,1894,1632,1434,1474,2108,2123,1752,1925,1577,1707,1655,1704,1942,1631,1778,1623,1717,1588,1654,1815,1466,1861,1837,1461,1557,1981,1671,1973,1839,1726,1497,1805,1759,1948,1521,1814,1458,1777,2016,2243,2097,2148,1644,1766,3683,3965,3516,3034,2400,2356,2398,1973,2305,2032,2343,2070,2074,1927,1859,1888,1908,2092,2305,2231,2043,2324,1945,2103,1917,2159,2343,2196,2489,2015,2243,2183,1835,1872,2110,2075,2419,1954,2301,2720,1998,2070,1973,1672,1879,2620]],"types":{"y0":"bar","x":"x"},"names":{"y0":"CSAM Groups and Channels Banned"},"colors":{"y0":"#3ea6f0"},"hidden":[],"subchart":{"show":true,"defaultZoom":[1734134400000,1736726400000]},"strokeWidth":2,"xTickFormatter":"statsFormat('day')","xTooltipFormatter":"statsTooltipFormat('day')","xRangeFormatter":"null","yTickFormatter":"null","yTooltipFormatter":"statsFormatTooltipValue","sideLegend":"statsNeedSideLegend()","tooltipOnHover":true}, true); }, 50); setTimeout(function () { - var chart = renderGraph('chart_terror_banned_wrap', {"title":"","columns":[["x",1705190400000,1705276800000,1705363200000,1705449600000,1705536000000,1705622400000,1705708800000,1705795200000,1705881600000,1705968000000,1706054400000,1706140800000,1706227200000,1706313600000,1706400000000,1706486400000,1706572800000,1706659200000,1706745600000,1706832000000,1706918400000,1707004800000,1707091200000,1707177600000,1707264000000,1707350400000,1707436800000,1707523200000,1707609600000,1707696000000,1707782400000,1707868800000,1707955200000,1708041600000,1708128000000,1708214400000,1708300800000,1708387200000,1708473600000,1708560000000,1708646400000,1708732800000,1708819200000,1708905600000,1708992000000,1709078400000,1709164800000,1709251200000,1709337600000,1709424000000,1709510400000,1709596800000,1709683200000,1709769600000,1709856000000,1709942400000,1710028800000,1710115200000,1710201600000,1710288000000,1710374400000,1710460800000,1710547200000,1710633600000,1710720000000,1710806400000,1710892800000,1710979200000,1711065600000,1711152000000,1711238400000,1711324800000,1711411200000,1711497600000,1711584000000,1711670400000,1711756800000,1711843200000,1711929600000,1712016000000,1712102400000,1712188800000,1712275200000,1712361600000,1712448000000,1712534400000,1712620800000,1712707200000,1712793600000,1712880000000,1712966400000,1713052800000,1713139200000,1713225600000,1713312000000,1713398400000,1713484800000,1713571200000,1713657600000,1713744000000,1713830400000,1713916800000,1714003200000,1714089600000,1714176000000,1714262400000,1714348800000,1714435200000,1714521600000,1714608000000,1714694400000,1714780800000,1714867200000,1714953600000,1715040000000,1715126400000,1715212800000,1715299200000,1715385600000,1715472000000,1715558400000,1715644800000,1715731200000,1715817600000,1715904000000,1715990400000,1716076800000,1716163200000,1716249600000,1716336000000,1716422400000,1716508800000,1716595200000,1716681600000,1716768000000,1716854400000,1716940800000,1717027200000,1717113600000,1717200000000,1717286400000,1717372800000,1717459200000,1717545600000,1717632000000,1717718400000,1717804800000,1717891200000,1717977600000,1718064000000,1718150400000,1718236800000,1718323200000,1718409600000,1718496000000,1718582400000,1718668800000,1718755200000,1718841600000,1718928000000,1719014400000,1719100800000,1719187200000,1719273600000,1719360000000,1719446400000,1719532800000,1719619200000,1719705600000,1719792000000,1719878400000,1719964800000,1720051200000,1720137600000,1720224000000,1720310400000,1720396800000,1720483200000,1720569600000,1720656000000,1720742400000,1720828800000,1720915200000,1721001600000,1721088000000,1721174400000,1721260800000,1721347200000,1721433600000,1721520000000,1721606400000,1721692800000,1721779200000,1721865600000,1721952000000,1722038400000,1722124800000,1722211200000,1722297600000,1722384000000,1722470400000,1722556800000,1722643200000,1722729600000,1722816000000,1722902400000,1722988800000,1723075200000,1723161600000,1723248000000,1723334400000,1723420800000,1723507200000,1723593600000,1723680000000,1723766400000,1723852800000,1723939200000,1724025600000,1724112000000,1724198400000,1724284800000,1724371200000,1724457600000,1724544000000,1724630400000,1724716800000,1724803200000,1724889600000,1724976000000,1725062400000,1725148800000,1725235200000,1725321600000,1725408000000,1725494400000,1725580800000,1725667200000,1725753600000,1725840000000,1725926400000,1726012800000,1726099200000,1726185600000,1726272000000,1726358400000,1726444800000,1726531200000,1726617600000,1726704000000,1726790400000,1726876800000,1726963200000,1727049600000,1727136000000,1727222400000,1727308800000,1727395200000,1727481600000,1727568000000,1727654400000,1727740800000,1727827200000,1727913600000,1728000000000,1728086400000,1728172800000,1728259200000,1728345600000,1728432000000,1728518400000,1728604800000,1728691200000,1728777600000,1728864000000,1728950400000,1729036800000,1729123200000,1729209600000,1729296000000,1729382400000,1729468800000,1729555200000,1729641600000,1729728000000,1729814400000,1729900800000,1729987200000,1730073600000,1730160000000,1730246400000,1730332800000,1730419200000,1730505600000,1730592000000,1730678400000,1730764800000,1730851200000,1730937600000,1731024000000,1731110400000,1731196800000,1731283200000,1731369600000,1731456000000,1731542400000,1731628800000,1731715200000,1731801600000,1731888000000,1731974400000,1732060800000,1732147200000,1732233600000,1732320000000,1732406400000,1732492800000,1732579200000,1732665600000,1732752000000,1732838400000,1732924800000,1733011200000,1733097600000,1733184000000,1733270400000,1733356800000,1733443200000,1733529600000,1733616000000,1733702400000,1733788800000,1733875200000,1733961600000,1734048000000,1734134400000,1734220800000,1734307200000,1734393600000,1734480000000,1734566400000,1734652800000,1734739200000,1734825600000,1734912000000,1734998400000,1735084800000,1735171200000,1735257600000,1735344000000,1735430400000,1735516800000,1735603200000,1735689600000,1735776000000,1735862400000,1735948800000,1736035200000,1736121600000,1736208000000,1736294400000,1736380800000,1736467200000,1736553600000,1736640000000,1736726400000],["y0",105,285,220,340,257,254,112,219,444,272,427,309,273,190,218,383,266,375,420,396,164,200,578,528,255,422,289,227,171,256,181,348,77,351,263,221,348,256,164,464,265,178,168,357,160,308,206,329,117,231,258,431,312,202,241,152,136,333,321,355,136,201,242,136,328,195,182,304,833,466,686,509,495,199,1452,775,373,886,349,838,759,564,959,329,360,835,566,480,183,341,300,485,527,356,681,317,425,236,124,330,380,172,280,182,165,202,272,1099,200,486,157,219,240,374,369,119,310,176,259,127,180,161,274,366,302,158,185,143,399,299,140,120,64,205,217,403,124,48,209,289,85,215,323,158,243,200,148,145,169,328,158,262,187,186,215,251,166,111,142,273,125,86,90,185,73,398,218,77,167,124,189,174,374,250,103,286,227,174,191,92,305,144,187,376,275,220,28,266,132,121,251,114,202,55,328,42,213,219,56,122,166,524,173,222,62,85,113,82,218,48,85,98,209,138,152,314,82,55,135,580,298,151,153,100,453,355,171,80,184,363,69,150,198,588,179,140,363,262,191,628,386,587,400,471,236,85,258,743,405,193,272,84,63,378,248,350,336,144,206,249,305,549,757,494,386,547,190,617,259,298,200,263,217,173,524,4714,280,2110,1010,784,831,618,587,755,2230,872,258,1113,232,1304,434,1024,479,397,806,461,850,904,503,422,174,611,314,717,425,427,274,1680,532,271,1436,776,148,860,1086,67,648,312,122,142,2249,1801,758,536,842,395,1055,766,1823,126,291,681,137,186,887,133,1001,669,1197,1487,145,633,885,1726,326,268,82,417,32,815,606,1327,263,749,633,769,504,45,277,423,208,720,1834,169,408,0]],"types":{"y0":"bar","x":"x"},"names":{"y0":"Banned Terrorist Communities"},"colors":{"y0":"#3ea6f0"},"hidden":[],"subchart":{"show":true,"defaultZoom":[1734134400000,1736726400000]},"strokeWidth":2,"xTickFormatter":"statsFormat('day')","xTooltipFormatter":"statsTooltipFormat('day')","xRangeFormatter":"null","yTickFormatter":"null","yTooltipFormatter":"statsFormatTooltipValue","sideLegend":"statsNeedSideLegend()","tooltipOnHover":true}, true); + var chart = renderGraph('chart_terror_banned_wrap', {"title":"","columns":[["x",1705190400000,1705276800000,1705363200000,1705449600000,1705536000000,1705622400000,1705708800000,1705795200000,1705881600000,1705968000000,1706054400000,1706140800000,1706227200000,1706313600000,1706400000000,1706486400000,1706572800000,1706659200000,1706745600000,1706832000000,1706918400000,1707004800000,1707091200000,1707177600000,1707264000000,1707350400000,1707436800000,1707523200000,1707609600000,1707696000000,1707782400000,1707868800000,1707955200000,1708041600000,1708128000000,1708214400000,1708300800000,1708387200000,1708473600000,1708560000000,1708646400000,1708732800000,1708819200000,1708905600000,1708992000000,1709078400000,1709164800000,1709251200000,1709337600000,1709424000000,1709510400000,1709596800000,1709683200000,1709769600000,1709856000000,1709942400000,1710028800000,1710115200000,1710201600000,1710288000000,1710374400000,1710460800000,1710547200000,1710633600000,1710720000000,1710806400000,1710892800000,1710979200000,1711065600000,1711152000000,1711238400000,1711324800000,1711411200000,1711497600000,1711584000000,1711670400000,1711756800000,1711843200000,1711929600000,1712016000000,1712102400000,1712188800000,1712275200000,1712361600000,1712448000000,1712534400000,1712620800000,1712707200000,1712793600000,1712880000000,1712966400000,1713052800000,1713139200000,1713225600000,1713312000000,1713398400000,1713484800000,1713571200000,1713657600000,1713744000000,1713830400000,1713916800000,1714003200000,1714089600000,1714176000000,1714262400000,1714348800000,1714435200000,1714521600000,1714608000000,1714694400000,1714780800000,1714867200000,1714953600000,1715040000000,1715126400000,1715212800000,1715299200000,1715385600000,1715472000000,1715558400000,1715644800000,1715731200000,1715817600000,1715904000000,1715990400000,1716076800000,1716163200000,1716249600000,1716336000000,1716422400000,1716508800000,1716595200000,1716681600000,1716768000000,1716854400000,1716940800000,1717027200000,1717113600000,1717200000000,1717286400000,1717372800000,1717459200000,1717545600000,1717632000000,1717718400000,1717804800000,1717891200000,1717977600000,1718064000000,1718150400000,1718236800000,1718323200000,1718409600000,1718496000000,1718582400000,1718668800000,1718755200000,1718841600000,1718928000000,1719014400000,1719100800000,1719187200000,1719273600000,1719360000000,1719446400000,1719532800000,1719619200000,1719705600000,1719792000000,1719878400000,1719964800000,1720051200000,1720137600000,1720224000000,1720310400000,1720396800000,1720483200000,1720569600000,1720656000000,1720742400000,1720828800000,1720915200000,1721001600000,1721088000000,1721174400000,1721260800000,1721347200000,1721433600000,1721520000000,1721606400000,1721692800000,1721779200000,1721865600000,1721952000000,1722038400000,1722124800000,1722211200000,1722297600000,1722384000000,1722470400000,1722556800000,1722643200000,1722729600000,1722816000000,1722902400000,1722988800000,1723075200000,1723161600000,1723248000000,1723334400000,1723420800000,1723507200000,1723593600000,1723680000000,1723766400000,1723852800000,1723939200000,1724025600000,1724112000000,1724198400000,1724284800000,1724371200000,1724457600000,1724544000000,1724630400000,1724716800000,1724803200000,1724889600000,1724976000000,1725062400000,1725148800000,1725235200000,1725321600000,1725408000000,1725494400000,1725580800000,1725667200000,1725753600000,1725840000000,1725926400000,1726012800000,1726099200000,1726185600000,1726272000000,1726358400000,1726444800000,1726531200000,1726617600000,1726704000000,1726790400000,1726876800000,1726963200000,1727049600000,1727136000000,1727222400000,1727308800000,1727395200000,1727481600000,1727568000000,1727654400000,1727740800000,1727827200000,1727913600000,1728000000000,1728086400000,1728172800000,1728259200000,1728345600000,1728432000000,1728518400000,1728604800000,1728691200000,1728777600000,1728864000000,1728950400000,1729036800000,1729123200000,1729209600000,1729296000000,1729382400000,1729468800000,1729555200000,1729641600000,1729728000000,1729814400000,1729900800000,1729987200000,1730073600000,1730160000000,1730246400000,1730332800000,1730419200000,1730505600000,1730592000000,1730678400000,1730764800000,1730851200000,1730937600000,1731024000000,1731110400000,1731196800000,1731283200000,1731369600000,1731456000000,1731542400000,1731628800000,1731715200000,1731801600000,1731888000000,1731974400000,1732060800000,1732147200000,1732233600000,1732320000000,1732406400000,1732492800000,1732579200000,1732665600000,1732752000000,1732838400000,1732924800000,1733011200000,1733097600000,1733184000000,1733270400000,1733356800000,1733443200000,1733529600000,1733616000000,1733702400000,1733788800000,1733875200000,1733961600000,1734048000000,1734134400000,1734220800000,1734307200000,1734393600000,1734480000000,1734566400000,1734652800000,1734739200000,1734825600000,1734912000000,1734998400000,1735084800000,1735171200000,1735257600000,1735344000000,1735430400000,1735516800000,1735603200000,1735689600000,1735776000000,1735862400000,1735948800000,1736035200000,1736121600000,1736208000000,1736294400000,1736380800000,1736467200000,1736553600000,1736640000000,1736726400000],["y0",105,285,220,340,257,254,112,219,444,272,427,309,273,190,218,383,266,375,420,396,164,200,578,528,255,422,289,227,171,256,181,348,77,351,263,221,348,256,164,464,265,178,168,357,160,308,206,329,117,231,258,431,312,202,241,152,136,333,321,355,136,201,242,136,328,195,182,304,833,466,686,509,495,199,1452,775,373,886,349,838,759,564,959,329,360,835,566,480,183,341,300,485,527,356,681,317,425,236,124,330,380,172,280,182,165,202,272,1099,200,486,157,219,240,374,369,119,310,176,259,127,180,161,274,366,302,158,185,143,399,299,140,120,64,205,217,403,124,48,209,289,85,215,323,158,243,200,148,145,169,328,158,262,187,186,215,251,166,111,142,273,125,86,90,185,73,398,218,77,167,124,189,174,374,250,103,286,227,174,191,92,305,144,187,376,275,220,28,266,132,121,251,114,202,55,328,42,213,219,56,122,166,524,173,222,62,85,113,82,218,48,85,98,209,138,152,314,82,55,135,580,298,151,153,100,453,355,171,80,184,363,69,150,198,588,179,140,363,262,191,628,386,587,400,471,236,85,258,743,405,193,272,84,63,378,248,350,336,144,206,249,305,549,757,494,386,547,190,617,259,298,200,263,217,173,524,4714,280,2110,1010,784,831,618,587,755,2230,872,258,1113,232,1304,434,1024,479,397,806,461,850,904,503,422,174,611,314,717,425,427,274,1680,532,271,1436,776,148,860,1086,67,648,312,122,142,2249,1801,758,536,842,395,1055,766,1823,126,291,681,137,186,887,133,1001,669,1197,1487,145,633,885,1726,326,268,82,417,32,815,606,1327,263,749,633,769,504,45,277,423,208,720,1834,169,408,199]],"types":{"y0":"bar","x":"x"},"names":{"y0":"Banned Terrorist Communities"},"colors":{"y0":"#3ea6f0"},"hidden":[],"subchart":{"show":true,"defaultZoom":[1734134400000,1736726400000]},"strokeWidth":2,"xTickFormatter":"statsFormat('day')","xTooltipFormatter":"statsTooltipFormat('day')","xRangeFormatter":"null","yTickFormatter":"null","yTooltipFormatter":"statsFormatTooltipValue","sideLegend":"statsNeedSideLegend()","tooltipOnHover":true}, true); }, 100); backToTopInit("Go up");