diff --git a/.babelrc b/.babelrc
index 8aa924d..1320b9a 100644
--- a/.babelrc
+++ b/.babelrc
@@ -1,3 +1,3 @@
{
"presets": ["@babel/preset-env"]
-}
\ No newline at end of file
+}
diff --git a/extension/assets/mute.png b/extension/assets/mute.png
deleted file mode 100644
index d952e3d..0000000
Binary files a/extension/assets/mute.png and /dev/null differ
diff --git a/extension/dist/background.js b/extension/dist/background.js
index 7af208b..697d5c2 100644
--- a/extension/dist/background.js
+++ b/extension/dist/background.js
@@ -1,117 +1,6 @@
-/******/ (function(modules) { // webpackBootstrap
-/******/ // The module cache
-/******/ var installedModules = {};
-/******/
-/******/ // The require function
-/******/ function __webpack_require__(moduleId) {
-/******/
-/******/ // Check if module is in cache
-/******/ if(installedModules[moduleId]) {
-/******/ return installedModules[moduleId].exports;
-/******/ }
-/******/ // Create a new module (and put it into the cache)
-/******/ var module = installedModules[moduleId] = {
-/******/ i: moduleId,
-/******/ l: false,
-/******/ exports: {}
-/******/ };
-/******/
-/******/ // Execute the module function
-/******/ modules[moduleId].call(module.exports, module, module.exports, __webpack_require__);
-/******/
-/******/ // Flag the module as loaded
-/******/ module.l = true;
-/******/
-/******/ // Return the exports of the module
-/******/ return module.exports;
-/******/ }
-/******/
-/******/
-/******/ // expose the modules object (__webpack_modules__)
-/******/ __webpack_require__.m = modules;
-/******/
-/******/ // expose the module cache
-/******/ __webpack_require__.c = installedModules;
-/******/
-/******/ // define getter function for harmony exports
-/******/ __webpack_require__.d = function(exports, name, getter) {
-/******/ if(!__webpack_require__.o(exports, name)) {
-/******/ Object.defineProperty(exports, name, { enumerable: true, get: getter });
-/******/ }
-/******/ };
-/******/
-/******/ // define __esModule on exports
-/******/ __webpack_require__.r = function(exports) {
-/******/ if(typeof Symbol !== 'undefined' && Symbol.toStringTag) {
-/******/ Object.defineProperty(exports, Symbol.toStringTag, { value: 'Module' });
-/******/ }
-/******/ Object.defineProperty(exports, '__esModule', { value: true });
-/******/ };
-/******/
-/******/ // create a fake namespace object
-/******/ // mode & 1: value is a module id, require it
-/******/ // mode & 2: merge all properties of value into the ns
-/******/ // mode & 4: return value when already ns object
-/******/ // mode & 8|1: behave like require
-/******/ __webpack_require__.t = function(value, mode) {
-/******/ if(mode & 1) value = __webpack_require__(value);
-/******/ if(mode & 8) return value;
-/******/ if((mode & 4) && typeof value === 'object' && value && value.__esModule) return value;
-/******/ var ns = Object.create(null);
-/******/ __webpack_require__.r(ns);
-/******/ Object.defineProperty(ns, 'default', { enumerable: true, value: value });
-/******/ if(mode & 2 && typeof value != 'string') for(var key in value) __webpack_require__.d(ns, key, function(key) { return value[key]; }.bind(null, key));
-/******/ return ns;
-/******/ };
-/******/
-/******/ // getDefaultExport function for compatibility with non-harmony modules
-/******/ __webpack_require__.n = function(module) {
-/******/ var getter = module && module.__esModule ?
-/******/ function getDefault() { return module['default']; } :
-/******/ function getModuleExports() { return module; };
-/******/ __webpack_require__.d(getter, 'a', getter);
-/******/ return getter;
-/******/ };
-/******/
-/******/ // Object.prototype.hasOwnProperty.call
-/******/ __webpack_require__.o = function(object, property) { return Object.prototype.hasOwnProperty.call(object, property); };
-/******/
-/******/ // __webpack_public_path__
-/******/ __webpack_require__.p = "";
-/******/
-/******/
-/******/ // Load entry module and return exports
-/******/ return __webpack_require__(__webpack_require__.s = "./src/background/background.js");
-/******/ })
-/************************************************************************/
-/******/ ({
-
-/***/ "./src/background/background.js":
-/*!**************************************!*\
- !*** ./src/background/background.js ***!
- \**************************************/
-/*! no static exports found */
-/***/ (function(module, exports) {
-
-chrome.runtime.onInstalled.addListener(function () {
- chrome.storage.sync.set({
- isExtensionOn: true
- }, function () {
- console.log('isExtensionOn: ' + true);
- });
- chrome.declarativeContent.onPageChanged.removeRules(undefined, function () {
- chrome.declarativeContent.onPageChanged.addRules([{
- conditions: [new chrome.declarativeContent.PageStateMatcher({
- pageUrl: {
- hostEquals: 'vk.com'
- }
- })],
- actions: [new chrome.declarativeContent.ShowPageAction()]
- }]);
- });
-});
-
-/***/ })
-
-/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nZWQucmVtb3ZlUnVsZXModW5kZWZpbmVkLCBmdW5jdGlvbiAoKSB7XG4gICAgICAgIGNocm9tZS5kZWNsYXJhdGl2ZUNvbnRlbnQub25QYWdlQ2hhbmdlZC5hZGRSdWxlcyhbe1xuICAgICAgICAgICAgY29uZGl0aW9uczogW25ldyBjaHJvbWUuZGVjbGFyYXRpdmVDb250ZW50LlBhZ2VTdGF0ZU1hdGNoZXIoe1xuICAgICAgICAgICAgICAgIHBhZ2VVcmw6IHsgaG9zdEVxdWFsczogJ3ZrLmNvbScgfSxcbiAgICAgICAgICAgIH0pXSxcbiAgICAgICAgICAgIGFjdGlvbnM6IFtuZXcgY2hyb21lLmRlY2xhcmF0aXZlQ29udGVudC5TaG93UGFnZUFjdGlvbigpXVxuICAgICAgICB9XSk7XG4gICAgfSk7XG59KTsiXSwic291cmNlUm9vdCI6IiJ9
\ No newline at end of file
+/******/ (() => { // webpackBootstrap
+/******/ "use strict";
+/******/
+/******/
+/******/ })()
+;
\ No newline at end of file
diff --git a/extension/dist/dom.js b/extension/dist/dom.js
index b081778..b741f52 100644
--- a/extension/dist/dom.js
+++ b/extension/dist/dom.js
@@ -1,850 +1,942 @@
-/******/ (function(modules) { // webpackBootstrap
-/******/ // The module cache
-/******/ var installedModules = {};
-/******/
-/******/ // The require function
-/******/ function __webpack_require__(moduleId) {
-/******/
-/******/ // Check if module is in cache
-/******/ if(installedModules[moduleId]) {
-/******/ return installedModules[moduleId].exports;
-/******/ }
-/******/ // Create a new module (and put it into the cache)
-/******/ var module = installedModules[moduleId] = {
-/******/ i: moduleId,
-/******/ l: false,
-/******/ exports: {}
-/******/ };
-/******/
-/******/ // Execute the module function
-/******/ modules[moduleId].call(module.exports, module, module.exports, __webpack_require__);
-/******/
-/******/ // Flag the module as loaded
-/******/ module.l = true;
-/******/
-/******/ // Return the exports of the module
-/******/ return module.exports;
-/******/ }
-/******/
-/******/
-/******/ // expose the modules object (__webpack_modules__)
-/******/ __webpack_require__.m = modules;
-/******/
-/******/ // expose the module cache
-/******/ __webpack_require__.c = installedModules;
-/******/
-/******/ // define getter function for harmony exports
-/******/ __webpack_require__.d = function(exports, name, getter) {
-/******/ if(!__webpack_require__.o(exports, name)) {
-/******/ Object.defineProperty(exports, name, { enumerable: true, get: getter });
-/******/ }
-/******/ };
-/******/
-/******/ // define __esModule on exports
-/******/ __webpack_require__.r = function(exports) {
-/******/ if(typeof Symbol !== 'undefined' && Symbol.toStringTag) {
-/******/ Object.defineProperty(exports, Symbol.toStringTag, { value: 'Module' });
-/******/ }
-/******/ Object.defineProperty(exports, '__esModule', { value: true });
-/******/ };
-/******/
-/******/ // create a fake namespace object
-/******/ // mode & 1: value is a module id, require it
-/******/ // mode & 2: merge all properties of value into the ns
-/******/ // mode & 4: return value when already ns object
-/******/ // mode & 8|1: behave like require
-/******/ __webpack_require__.t = function(value, mode) {
-/******/ if(mode & 1) value = __webpack_require__(value);
-/******/ if(mode & 8) return value;
-/******/ if((mode & 4) && typeof value === 'object' && value && value.__esModule) return value;
-/******/ var ns = Object.create(null);
-/******/ __webpack_require__.r(ns);
-/******/ Object.defineProperty(ns, 'default', { enumerable: true, value: value });
-/******/ if(mode & 2 && typeof value != 'string') for(var key in value) __webpack_require__.d(ns, key, function(key) { return value[key]; }.bind(null, key));
-/******/ return ns;
-/******/ };
-/******/
-/******/ // getDefaultExport function for compatibility with non-harmony modules
-/******/ __webpack_require__.n = function(module) {
-/******/ var getter = module && module.__esModule ?
-/******/ function getDefault() { return module['default']; } :
-/******/ function getModuleExports() { return module; };
-/******/ __webpack_require__.d(getter, 'a', getter);
-/******/ return getter;
-/******/ };
-/******/
-/******/ // Object.prototype.hasOwnProperty.call
-/******/ __webpack_require__.o = function(object, property) { return Object.prototype.hasOwnProperty.call(object, property); };
-/******/
-/******/ // __webpack_public_path__
-/******/ __webpack_require__.p = "";
-/******/
-/******/
-/******/ // Load entry module and return exports
-/******/ return __webpack_require__(__webpack_require__.s = "./src/dom/main.js");
-/******/ })
-/************************************************************************/
-/******/ ({
-
-/***/ "./node_modules/css-loader/dist/cjs.js!./src/dom/dom.css":
-/*!***************************************************************!*\
- !*** ./node_modules/css-loader/dist/cjs.js!./src/dom/dom.css ***!
- \***************************************************************/
-/*! no static exports found */
-/***/ (function(module, exports, __webpack_require__) {
-
-// Imports
-var ___CSS_LOADER_API_IMPORT___ = __webpack_require__(/*! ../../node_modules/css-loader/dist/runtime/api.js */ "./node_modules/css-loader/dist/runtime/api.js");
-exports = ___CSS_LOADER_API_IMPORT___(false);
-// Module
-exports.push([module.i, ".mute_tooltip {\n position: absolute;\n left: -50px;\n top: -33px;\n display: none;\n}\n\n.mute_tooltip::after {\n left: 61px !important;\n}\n\n/* Show the tooltip text when you mouse over the tooltip container */\n.mute_message:hover .mute_tooltip {\n display: block !important;\n opacity: 1;\n}\n\n.mute_message {\n position: relative;\n display: inline-block;\n vertical-align: top;\n padding-top: 2px;\n width: 24px;\n height: 24px;\n background-size: 11px !important;\n}\n\n.im-mess--actions {\n margin-right: -30px !important;\n}", ""]);
-// Exports
-module.exports = exports;
-
+/******/ (() => { // webpackBootstrap
+/******/ var __webpack_modules__ = ({
-/***/ }),
-
-/***/ "./node_modules/css-loader/dist/runtime/api.js":
-/*!*****************************************************!*\
- !*** ./node_modules/css-loader/dist/runtime/api.js ***!
- \*****************************************************/
-/*! no static exports found */
-/***/ (function(module, exports, __webpack_require__) {
+/***/ "./src/dom/controls.js":
+/*!*****************************!*\
+ !*** ./src/dom/controls.js ***!
+ \*****************************/
+/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => {
"use strict";
+__webpack_require__.r(__webpack_exports__);
+/* harmony export */ __webpack_require__.d(__webpack_exports__, {
+/* harmony export */ "createTryToInitInterval": () => (/* binding */ createTryToInitInterval),
+/* harmony export */ "hideExistingMessages": () => (/* binding */ hideExistingMessages),
+/* harmony export */ "tryToAddControls": () => (/* binding */ tryToAddControls),
+/* harmony export */ "tryToInitControls": () => (/* binding */ tryToInitControls)
+/* harmony export */ });
+/* harmony import */ var _utils_getChatBody__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ../utils/getChatBody */ "./src/utils/getChatBody.js");
+/* harmony import */ var _mute_svg__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ./mute.svg */ "./src/dom/mute.svg");
+function _createForOfIteratorHelper(o) { if (typeof Symbol === "undefined" || o[Symbol.iterator] == null) { if (Array.isArray(o) || (o = _unsupportedIterableToArray(o))) { var i = 0; var F = function F() {}; return { s: F, n: function n() { if (i >= o.length) return { done: true }; return { done: false, value: o[i++] }; }, e: function e(_e) { throw _e; }, f: F }; } throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method."); } var it, normalCompletion = true, didErr = false, err; return { s: function s() { it = o[Symbol.iterator](); }, n: function n() { var step = it.next(); normalCompletion = step.done; return step; }, e: function e(_e2) { didErr = true; err = _e2; }, f: function f() { try { if (!normalCompletion && it["return"] != null) it["return"](); } finally { if (didErr) throw err; } } }; }
+function _unsupportedIterableToArray(o, minLen) { if (!o) return; if (typeof o === "string") return _arrayLikeToArray(o, minLen); var n = Object.prototype.toString.call(o).slice(8, -1); if (n === "Object" && o.constructor) n = o.constructor.name; if (n === "Map" || n === "Set") return Array.from(n); if (n === "Arguments" || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)) return _arrayLikeToArray(o, minLen); }
+function _arrayLikeToArray(arr, len) { if (len == null || len > arr.length) len = arr.length; for (var i = 0, arr2 = new Array(len); i < len; i++) { arr2[i] = arr[i]; } return arr2; }
-/*
- MIT License http://www.opensource.org/licenses/mit-license.php
- Author Tobias Koppers @sokra
-*/
-// css base code, injected by the css-loader
-// eslint-disable-next-line func-names
-module.exports = function (useSourceMap) {
- var list = []; // return the list of modules as css string
- list.toString = function toString() {
- return this.map(function (item) {
- var content = cssWithMappingToString(item, useSourceMap);
+/**
+ *
+ * @param id {String}
+ * @return {HTMLSpanElement}
+ */
+function muteBtnHTML(id) {
+ var element = document.createElement('span');
+ element.setAttribute('class', 'im-mess--mute');
+ element.setAttribute('id', "mute".concat(id));
+ element.setAttribute('label', 'Заглушить');
+ element.innerHTML = _mute_svg__WEBPACK_IMPORTED_MODULE_1__["default"] + '
';
+ return element;
+}
- if (item[2]) {
- return "@media ".concat(item[2], " {").concat(content, "}");
- }
+/**
+ *
+ * @param target {HTMLElenemt}
+ */
+function tryToAddControls(target) {
+ if (target.className === 'im-mess--check fl_l') {
+ var message = target.parentElement;
+ addControlButton(message);
+ }
+}
- return content;
- }).join('');
- }; // import a list of modules into the list
- // eslint-disable-next-line func-names
+/**
+ * Create mute button and inset it to the actionArea
+ * @param actionArea {HTMLElement}
+ * @param senderId {String}
+ * @return {HTMLElement}
+ */
+function addMuteButton(actionArea, senderId) {
+ var muteButton = muteBtnHTML(senderId);
+ actionArea.appendChild(muteButton);
+ muteButton.style.visibility = "hidden";
+ return muteButton;
+}
+/**
+ * Add event listeners to the actionArea
+ * @param actionsArea {HTMLElement}
+ */
+function addActionAreaEvents(actionsArea) {
+ actionsArea.parentElement.addEventListener("mouseenter", function (event) {
+ event.target.getElementsByClassName("im-mess--mute")[0].style.visibility = "visible";
+ });
+ actionsArea.parentElement.addEventListener("mouseleave", function (event) {
+ event.target.getElementsByClassName("im-mess--mute")[0].style.visibility = "hidden";
+ });
+}
- list.i = function (modules, mediaQuery, dedupe) {
- if (typeof modules === 'string') {
- // eslint-disable-next-line no-param-reassign
- modules = [[null, modules, '']];
+/**
+ *
+ * @this {HTMLElement}
+ */
+function setIdToHideHandle() {
+ var clickedId = this.id.substring(4);
+ var clickedName = this.parentElement.parentElement.parentElement.parentElement;
+ clickedName = clickedName.children[0].children[0].children[0].innerText;
+ chrome.storage.sync.get('idsToHide', function (data) {
+ var idsToHide = data.idsToHide || [];
+ if (idsToHide.filter(function (user) {
+ return user.id == clickedId;
+ }).length === 0) {
+ idsToHide.push({
+ id: clickedId,
+ name: clickedName
+ });
+ chrome.storage.sync.set({
+ idsToHide: idsToHide
+ }, function () {
+ chrome.storage.sync.get('isExtensionOn', function (data) {
+ if (data.isExtensionOn) {
+ hideExistingMessages();
+ }
+ });
+ });
}
-
- var alreadyImportedModules = {};
-
- if (dedupe) {
- for (var i = 0; i < this.length; i++) {
- // eslint-disable-next-line prefer-destructuring
- var id = this[i][0];
-
- if (id != null) {
- alreadyImportedModules[id] = true;
+ });
+}
+function hideExistingMessages() {
+ chrome.storage.sync.get('idsToHide', function (data) {
+ var chatBody = (0,_utils_getChatBody__WEBPACK_IMPORTED_MODULE_0__.getChatBody)();
+ var _iterator = _createForOfIteratorHelper(chatBody.children),
+ _step;
+ try {
+ var _loop = function _loop() {
+ var item = _step.value;
+ if (data.idsToHide.filter(function (user) {
+ return user.id == item.dataset.peer;
+ }).length > 0) {
+ item.style.display = "none";
}
+ };
+ for (_iterator.s(); !(_step = _iterator.n()).done;) {
+ _loop();
}
+ } catch (err) {
+ _iterator.e(err);
+ } finally {
+ _iterator.f();
}
+ });
+}
- for (var _i = 0; _i < modules.length; _i++) {
- var item = [].concat(modules[_i]);
-
- if (dedupe && alreadyImportedModules[item[0]]) {
- // eslint-disable-next-line no-continue
- continue;
- }
+// Try to add controls until successful. Needed for page refresh.
+function createTryToInitInterval() {
+ var controlsInterval = setInterval(function () {
+ if (!tryToInitControls(controlsInterval)) {
+ clearInterval(controlsInterval);
+ }
+ }, 200);
+ return controlsInterval;
+}
- if (mediaQuery) {
- if (!item[2]) {
- item[2] = mediaQuery;
- } else {
- item[2] = "".concat(mediaQuery, " and ").concat(item[2]);
+/**
+ *
+ * @param message {HTMLElement}
+ */
+function addControlButton(message) {
+ // Check if message is not an outgoing one
+ if (!message.classList.contains('im-mess_out')) {
+ var actionsArea = message.getElementsByClassName("im-mess--actions")[0];
+ if (actionsArea && actionsArea.lastChild.className !== "im-mess--mute") {
+ var senderId = message.parentElement.parentElement.parentElement["dataset"].peer;
+ var muteBtn = addMuteButton(actionsArea, senderId);
+ addActionAreaEvents(actionsArea);
+ muteBtn.addEventListener("click", setIdToHideHandle);
+ return true;
+ } else {
+ return false;
+ }
+ }
+}
+function tryToInitControls() {
+ var status = true;
+ var chatBody = (0,_utils_getChatBody__WEBPACK_IMPORTED_MODULE_0__.getChatBody)();
+ if (!chatBody) return false;
+ var _iterator2 = _createForOfIteratorHelper(chatBody.children),
+ _step2;
+ try {
+ for (_iterator2.s(); !(_step2 = _iterator2.n()).done;) {
+ var item = _step2.value;
+ if (item.className.includes('im-mess-stack _im_mess_stack')) {
+ var messages = item.children[1].children[1].getElementsByClassName('im-mess _im_mess');
+ var _iterator3 = _createForOfIteratorHelper(messages),
+ _step3;
+ try {
+ for (_iterator3.s(); !(_step3 = _iterator3.n()).done;) {
+ var message = _step3.value;
+ status = addControlButton(message);
+ }
+ } catch (err) {
+ _iterator3.e(err);
+ } finally {
+ _iterator3.f();
}
}
-
- list.push(item);
}
- };
-
- return list;
-};
-
-function cssWithMappingToString(item, useSourceMap) {
- var content = item[1] || ''; // eslint-disable-next-line prefer-destructuring
-
- var cssMapping = item[3];
-
- if (!cssMapping) {
- return content;
- }
-
- if (useSourceMap && typeof btoa === 'function') {
- var sourceMapping = toComment(cssMapping);
- var sourceURLs = cssMapping.sources.map(function (source) {
- return "/*# sourceURL=".concat(cssMapping.sourceRoot || '').concat(source, " */");
- });
- return [content].concat(sourceURLs).concat([sourceMapping]).join('\n');
+ } catch (err) {
+ _iterator2.e(err);
+ } finally {
+ _iterator2.f();
}
-
- return [content].join('\n');
-} // Adapted from convert-source-map (MIT)
-
-
-function toComment(sourceMap) {
- // eslint-disable-next-line no-undef
- var base64 = btoa(unescape(encodeURIComponent(JSON.stringify(sourceMap))));
- var data = "sourceMappingURL=data:application/json;charset=utf-8;base64,".concat(base64);
- return "/*# ".concat(data, " */");
+ return status;
}
/***/ }),
-/***/ "./node_modules/style-loader/dist/runtime/injectStylesIntoStyleTag.js":
-/*!****************************************************************************!*\
- !*** ./node_modules/style-loader/dist/runtime/injectStylesIntoStyleTag.js ***!
- \****************************************************************************/
-/*! no static exports found */
-/***/ (function(module, exports, __webpack_require__) {
+/***/ "./src/dom/hide_element.js":
+/*!*********************************!*\
+ !*** ./src/dom/hide_element.js ***!
+ \*********************************/
+/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => {
"use strict";
+__webpack_require__.r(__webpack_exports__);
+/* harmony export */ __webpack_require__.d(__webpack_exports__, {
+/* harmony export */ "addNewMessageEventListener": () => (/* binding */ addNewMessageEventListener),
+/* harmony export */ "returnMessagesEventListener": () => (/* binding */ returnMessagesEventListener)
+/* harmony export */ });
+/* harmony import */ var _utils_getChatBody__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ../utils/getChatBody */ "./src/utils/getChatBody.js");
+/* harmony import */ var _controls__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ./controls */ "./src/dom/controls.js");
+function _createForOfIteratorHelper(o) { if (typeof Symbol === "undefined" || o[Symbol.iterator] == null) { if (Array.isArray(o) || (o = _unsupportedIterableToArray(o))) { var i = 0; var F = function F() {}; return { s: F, n: function n() { if (i >= o.length) return { done: true }; return { done: false, value: o[i++] }; }, e: function e(_e) { throw _e; }, f: F }; } throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method."); } var it, normalCompletion = true, didErr = false, err; return { s: function s() { it = o[Symbol.iterator](); }, n: function n() { var step = it.next(); normalCompletion = step.done; return step; }, e: function e(_e2) { didErr = true; err = _e2; }, f: function f() { try { if (!normalCompletion && it["return"] != null) it["return"](); } finally { if (didErr) throw err; } } }; }
+function _unsupportedIterableToArray(o, minLen) { if (!o) return; if (typeof o === "string") return _arrayLikeToArray(o, minLen); var n = Object.prototype.toString.call(o).slice(8, -1); if (n === "Object" && o.constructor) n = o.constructor.name; if (n === "Map" || n === "Set") return Array.from(n); if (n === "Arguments" || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)) return _arrayLikeToArray(o, minLen); }
+function _arrayLikeToArray(arr, len) { if (len == null || len > arr.length) len = arr.length; for (var i = 0, arr2 = new Array(len); i < len; i++) { arr2[i] = arr[i]; } return arr2; }
-var isOldIE = function isOldIE() {
- var memo;
- return function memorize() {
- if (typeof memo === 'undefined') {
- // Test for IE <= 9 as proposed by Browserhacks
- // @see http://browserhacks.com/#hack-e71d8692f65334173fee715c222cb805
- // Tests for existence of standard globals is to allow style-loader
- // to operate correctly into non-standard environments
- // @see https://github.com/webpack-contrib/style-loader/issues/177
- memo = Boolean(window && document && document.all && !window.atob);
- }
-
- return memo;
- };
-}();
-
-var getTarget = function getTarget() {
- var memo = {};
- return function memorize(target) {
- if (typeof memo[target] === 'undefined') {
- var styleTarget = document.querySelector(target); // Special case to return head of iframe instead of iframe itself
-
- if (window.HTMLIFrameElement && styleTarget instanceof window.HTMLIFrameElement) {
+function addNewMessageEventListener() {
+ var chatBody = (0,_utils_getChatBody__WEBPACK_IMPORTED_MODULE_0__.getChatBody)();
+ chatBody.addEventListener('DOMNodeInserted', function (event) {
+ newMessageHandler(event.target);
+ });
+}
+function newMessageHandler(message) {
+ (0,_controls__WEBPACK_IMPORTED_MODULE_1__.tryToAddControls)(message);
+ if (message.className === 'im-mess-stack _im_mess_stack ') {
+ chrome.storage.sync.get('isExtensionOn', function (data) {
+ if (data.isExtensionOn) {
+ chrome.storage.sync.get('idsToHide', function (data) {
+ if (data.idsToHide.filter(function (user) {
+ return user.id == message.dataset.peer;
+ }).length > 0) {
+ message.style.display = "none";
+ }
+ });
+ }
+ });
+ }
+}
+function returnMessagesEventListener() {
+ chrome.storage.onChanged.addListener(function (changes) {
+ var isExtensionOn = changes.isExtensionOn;
+ var idsToHide = changes.idsToHide;
+ var chatBody = (0,_utils_getChatBody__WEBPACK_IMPORTED_MODULE_0__.getChatBody)();
+ if (isExtensionOn) {
+ if (isExtensionOn.newValue === false) {
+ var _iterator = _createForOfIteratorHelper(chatBody.children),
+ _step;
try {
- // This will throw an exception if access to iframe is blocked
- // due to cross-origin restrictions
- styleTarget = styleTarget.contentDocument.head;
- } catch (e) {
- // istanbul ignore next
- styleTarget = null;
+ for (_iterator.s(); !(_step = _iterator.n()).done;) {
+ var item = _step.value;
+ item.style.display = "block";
+ }
+ } catch (err) {
+ _iterator.e(err);
+ } finally {
+ _iterator.f();
}
+ } else {
+ (0,_controls__WEBPACK_IMPORTED_MODULE_1__.hideExistingMessages)();
}
-
- memo[target] = styleTarget;
- }
-
- return memo[target];
- };
-}();
-
-var stylesInDom = [];
-
-function getIndexByIdentifier(identifier) {
- var result = -1;
-
- for (var i = 0; i < stylesInDom.length; i++) {
- if (stylesInDom[i].identifier === identifier) {
- result = i;
- break;
}
- }
-
- return result;
-}
-
-function modulesToDom(list, options) {
- var idCountMap = {};
- var identifiers = [];
-
- for (var i = 0; i < list.length; i++) {
- var item = list[i];
- var id = options.base ? item[0] + options.base : item[0];
- var count = idCountMap[id] || 0;
- var identifier = "".concat(id, " ").concat(count);
- idCountMap[id] = count + 1;
- var index = getIndexByIdentifier(identifier);
- var obj = {
- css: item[1],
- media: item[2],
- sourceMap: item[3]
- };
-
- if (index !== -1) {
- stylesInDom[index].references++;
- stylesInDom[index].updater(obj);
- } else {
- stylesInDom.push({
- identifier: identifier,
- updater: addStyle(obj, options),
- references: 1
+ if (idsToHide) {
+ chrome.storage.sync.get('isExtensionOn', function (data) {
+ if (data.isExtensionOn) {
+ if (idsToHide.newValue.length < idsToHide.oldValue.length) {
+ // for (let item of chatBody.children) {
+ // item.style.display = "block";
+ // }
+ // hideExistingMessages();
+ var _iterator2 = _createForOfIteratorHelper(chatBody.children),
+ _step2;
+ try {
+ var _loop = function _loop() {
+ var item = _step2.value;
+ if (idsToHide.newValue.filter(function (user) {
+ return user.id == item.dataset.peer;
+ }).length === 0) {
+ item.style.display = "block";
+ }
+ };
+ for (_iterator2.s(); !(_step2 = _iterator2.n()).done;) {
+ _loop();
+ }
+ } catch (err) {
+ _iterator2.e(err);
+ } finally {
+ _iterator2.f();
+ }
+ }
+ }
});
}
-
- identifiers.push(identifier);
- }
-
- return identifiers;
+ });
}
-function insertStyleElement(options) {
- var style = document.createElement('style');
- var attributes = options.attributes || {};
+/***/ }),
- if (typeof attributes.nonce === 'undefined') {
- var nonce = true ? __webpack_require__.nc : undefined;
+/***/ "./src/utils/Url.js":
+/*!**************************!*\
+ !*** ./src/utils/Url.js ***!
+ \**************************/
+/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => {
- if (nonce) {
- attributes.nonce = nonce;
- }
+"use strict";
+__webpack_require__.r(__webpack_exports__);
+/* harmony export */ __webpack_require__.d(__webpack_exports__, {
+/* harmony export */ "UrlController": () => (/* binding */ UrlController)
+/* harmony export */ });
+function _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError("Cannot call a class as a function"); } }
+function _defineProperties(target, props) { for (var i = 0; i < props.length; i++) { var descriptor = props[i]; descriptor.enumerable = descriptor.enumerable || false; descriptor.configurable = true; if ("value" in descriptor) descriptor.writable = true; Object.defineProperty(target, descriptor.key, descriptor); } }
+function _createClass(Constructor, protoProps, staticProps) { if (protoProps) _defineProperties(Constructor.prototype, protoProps); if (staticProps) _defineProperties(Constructor, staticProps); return Constructor; }
+var INTERVAL_TIME = 100;
+var UrlController = /*#__PURE__*/function () {
+ function UrlController() {
+ _classCallCheck(this, UrlController);
+ this._changeListeners = [];
+ this._interval = null;
+ this._url = window.location.href;
}
-
- Object.keys(attributes).forEach(function (key) {
- style.setAttribute(key, attributes[key]);
- });
-
- if (typeof options.insert === 'function') {
- options.insert(style);
- } else {
- var target = getTarget(options.insert || 'head');
-
- if (!target) {
- throw new Error("Couldn't find a style target. This probably means that the value for the 'insert' parameter is invalid.");
+ _createClass(UrlController, [{
+ key: "onChange",
+ value: function onChange(cb) {
+ this._changeListeners.push(cb);
+ if (this._interval === null) {
+ this._createInterval();
+ }
}
-
- target.appendChild(style);
- }
-
- return style;
-}
-
-function removeStyleElement(style) {
- // istanbul ignore if
- if (style.parentNode === null) {
- return false;
- }
-
- style.parentNode.removeChild(style);
-}
-/* istanbul ignore next */
-
-
-var replaceText = function replaceText() {
- var textStore = [];
- return function replace(index, replacement) {
- textStore[index] = replacement;
- return textStore.filter(Boolean).join('\n');
- };
+ }, {
+ key: "removeEventListener",
+ value: function removeEventListener(cb) {
+ this._changeListeners = this._changeListeners.filter(function (item) {
+ return item !== cb;
+ });
+ if (this._changeListeners.length === 0) {
+ this._clearInterval();
+ }
+ }
+ }, {
+ key: "_intervalTick",
+ value: function _intervalTick() {
+ var currentUrl = window.location.href;
+ if (currentUrl !== this.url) {
+ this._broadcast(this.url, currentUrl);
+ this.url = currentUrl;
+ }
+ }
+ }, {
+ key: "_broadcast",
+ value: function _broadcast(oldUrl, newUrl) {
+ this._changeListeners.forEach(function (cb) {
+ return cb(oldUrl, newUrl);
+ });
+ }
+ }, {
+ key: "_createInterval",
+ value: function _createInterval() {
+ var _this = this;
+ this.interval = setInterval(function () {
+ return _this._intervalTick();
+ }, INTERVAL_TIME);
+ }
+ }, {
+ key: "_clearInterval",
+ value: function _clearInterval() {
+ clearInterval(this.interval);
+ this.interval = null;
+ }
+ }]);
+ return UrlController;
}();
-function applyToSingletonTag(style, index, remove, obj) {
- var css = remove ? '' : obj.media ? "@media ".concat(obj.media, " {").concat(obj.css, "}") : obj.css; // For old IE
-
- /* istanbul ignore if */
-
- if (style.styleSheet) {
- style.styleSheet.cssText = replaceText(index, css);
- } else {
- var cssNode = document.createTextNode(css);
- var childNodes = style.childNodes;
+/***/ }),
- if (childNodes[index]) {
- style.removeChild(childNodes[index]);
- }
+/***/ "./src/utils/getChatBody.js":
+/*!**********************************!*\
+ !*** ./src/utils/getChatBody.js ***!
+ \**********************************/
+/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => {
- if (childNodes.length) {
- style.insertBefore(cssNode, childNodes[index]);
- } else {
- style.appendChild(cssNode);
- }
- }
+"use strict";
+__webpack_require__.r(__webpack_exports__);
+/* harmony export */ __webpack_require__.d(__webpack_exports__, {
+/* harmony export */ "getChatBody": () => (/* binding */ getChatBody)
+/* harmony export */ });
+function getChatBody() {
+ return document.getElementsByClassName("_im_peer_history im-page-chat-contain")[0];
}
-function applyToTag(style, options, obj) {
- var css = obj.css;
- var media = obj.media;
- var sourceMap = obj.sourceMap;
+/***/ }),
- if (media) {
- style.setAttribute('media', media);
- } else {
- style.removeAttribute('media');
- }
+/***/ "./node_modules/css-loader/dist/cjs.js!./src/dom/dom.css":
+/*!***************************************************************!*\
+ !*** ./node_modules/css-loader/dist/cjs.js!./src/dom/dom.css ***!
+ \***************************************************************/
+/***/ ((module, __webpack_exports__, __webpack_require__) => {
- if (sourceMap && btoa) {
- css += "\n/*# sourceMappingURL=data:application/json;base64,".concat(btoa(unescape(encodeURIComponent(JSON.stringify(sourceMap)))), " */");
- } // For old IE
+"use strict";
+__webpack_require__.r(__webpack_exports__);
+/* harmony export */ __webpack_require__.d(__webpack_exports__, {
+/* harmony export */ "default": () => (__WEBPACK_DEFAULT_EXPORT__)
+/* harmony export */ });
+/* harmony import */ var _node_modules_css_loader_dist_runtime_sourceMaps_js__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ../../node_modules/css-loader/dist/runtime/sourceMaps.js */ "./node_modules/css-loader/dist/runtime/sourceMaps.js");
+/* harmony import */ var _node_modules_css_loader_dist_runtime_sourceMaps_js__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(_node_modules_css_loader_dist_runtime_sourceMaps_js__WEBPACK_IMPORTED_MODULE_0__);
+/* harmony import */ var _node_modules_css_loader_dist_runtime_api_js__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ../../node_modules/css-loader/dist/runtime/api.js */ "./node_modules/css-loader/dist/runtime/api.js");
+/* harmony import */ var _node_modules_css_loader_dist_runtime_api_js__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(_node_modules_css_loader_dist_runtime_api_js__WEBPACK_IMPORTED_MODULE_1__);
+// Imports
- /* istanbul ignore if */
+var ___CSS_LOADER_EXPORT___ = _node_modules_css_loader_dist_runtime_api_js__WEBPACK_IMPORTED_MODULE_1___default()((_node_modules_css_loader_dist_runtime_sourceMaps_js__WEBPACK_IMPORTED_MODULE_0___default()));
+// Module
+___CSS_LOADER_EXPORT___.push([module.id, ".mute_tooltip {\n position: absolute;\n left: -50px;\n top: -33px;\n display: none;\n}\n\n.mute_tooltip::after {\n left: 61px !important;\n}\n\n/* Show the tooltip text when you mouse over the tooltip container */\n.im-mess--mute:hover .mute_tooltip {\n display: block !important;\n opacity: 1;\n}\n\n.im-mess--mute {\n position: relative;\n display: inline-flex;\n align-items: center;\n justify-content: center;\n width: 24px;\n height: 24px;\n opacity: .5;\n color: var(--vkui--color_icon_secondary);\n}\n\n.im-mess--mute:hover {\n opacity: 1;\n}\n\n.im-mess--actions {\n margin-right: -30px !important;\n}", "",{"version":3,"sources":["webpack://./src/dom/dom.css"],"names":[],"mappings":"AAAA;IACI,kBAAkB;IAClB,WAAW;IACX,UAAU;IACV,aAAa;AACjB;;AAEA;IACI,qBAAqB;AACzB;;AAEA,oEAAoE;AACpE;IACI,yBAAyB;IACzB,UAAU;AACd;;AAEA;IACI,kBAAkB;IAClB,oBAAoB;IACpB,mBAAmB;IACnB,uBAAuB;IACvB,WAAW;IACX,YAAY;IACZ,WAAW;IACX,wCAAwC;AAC5C;;AAEA;IACI,UAAU;AACd;;AAEA;IACI,8BAA8B;AAClC","sourcesContent":[".mute_tooltip {\n position: absolute;\n left: -50px;\n top: -33px;\n display: none;\n}\n\n.mute_tooltip::after {\n left: 61px !important;\n}\n\n/* Show the tooltip text when you mouse over the tooltip container */\n.im-mess--mute:hover .mute_tooltip {\n display: block !important;\n opacity: 1;\n}\n\n.im-mess--mute {\n position: relative;\n display: inline-flex;\n align-items: center;\n justify-content: center;\n width: 24px;\n height: 24px;\n opacity: .5;\n color: var(--vkui--color_icon_secondary);\n}\n\n.im-mess--mute:hover {\n opacity: 1;\n}\n\n.im-mess--actions {\n margin-right: -30px !important;\n}"],"sourceRoot":""}]);
+// Exports
+/* harmony default export */ const __WEBPACK_DEFAULT_EXPORT__ = (___CSS_LOADER_EXPORT___);
- if (style.styleSheet) {
- style.styleSheet.cssText = css;
- } else {
- while (style.firstChild) {
- style.removeChild(style.firstChild);
- }
- style.appendChild(document.createTextNode(css));
- }
-}
+/***/ }),
-var singleton = null;
-var singletonCounter = 0;
+/***/ "./node_modules/css-loader/dist/runtime/api.js":
+/*!*****************************************************!*\
+ !*** ./node_modules/css-loader/dist/runtime/api.js ***!
+ \*****************************************************/
+/***/ ((module) => {
-function addStyle(obj, options) {
- var style;
- var update;
- var remove;
+"use strict";
- if (options.singleton) {
- var styleIndex = singletonCounter++;
- style = singleton || (singleton = insertStyleElement(options));
- update = applyToSingletonTag.bind(null, style, styleIndex, false);
- remove = applyToSingletonTag.bind(null, style, styleIndex, true);
- } else {
- style = insertStyleElement(options);
- update = applyToTag.bind(null, style, options);
- remove = function remove() {
- removeStyleElement(style);
- };
- }
+/*
+ MIT License http://www.opensource.org/licenses/mit-license.php
+ Author Tobias Koppers @sokra
+*/
+module.exports = function (cssWithMappingToString) {
+ var list = [];
- update(obj);
- return function updateStyle(newObj) {
- if (newObj) {
- if (newObj.css === obj.css && newObj.media === obj.media && newObj.sourceMap === obj.sourceMap) {
- return;
+ // return the list of modules as css string
+ list.toString = function toString() {
+ return this.map(function (item) {
+ var content = "";
+ var needLayer = typeof item[5] !== "undefined";
+ if (item[4]) {
+ content += "@supports (".concat(item[4], ") {");
}
-
- update(obj = newObj);
- } else {
- remove();
- }
+ if (item[2]) {
+ content += "@media ".concat(item[2], " {");
+ }
+ if (needLayer) {
+ content += "@layer".concat(item[5].length > 0 ? " ".concat(item[5]) : "", " {");
+ }
+ content += cssWithMappingToString(item);
+ if (needLayer) {
+ content += "}";
+ }
+ if (item[2]) {
+ content += "}";
+ }
+ if (item[4]) {
+ content += "}";
+ }
+ return content;
+ }).join("");
};
-}
-
-module.exports = function (list, options) {
- options = options || {}; // Force single-tag solution on IE6-9, which has a hard limit on the # of