From 519d963a3df3b03227c8540c8f38b88d480a0ec2 Mon Sep 17 00:00:00 2001 From: RIZWAN AHMAD Date: Sun, 3 Jul 2022 21:33:35 +0530 Subject: [PATCH] #160 #142 #122 #110 fixed bug and improvements --- .../WhatsApp Monitor/css/font-awesome.css | 5 + .../WhatsApp Monitor/css/itel.css | 928 +++++++++++ .../WhatsApp Monitor/inject_wp.js | 426 +++++ Chrome-Extension/WhatsApp Monitor/main.js | 2 +- .../WhatsApp Monitor/manifest.json | 54 +- Chrome-Extension/WhatsApp Monitor/online.js | 63 +- Chrome-Extension/WhatsApp Monitor/popup.html | 167 +- Chrome-Extension/WhatsApp Monitor/popup.js | 228 ++- Chrome-Extension/WhatsApp Monitor/protobuf.js | 477 +----- Chrome-Extension/WhatsApp Monitor/start.js | 3 +- Chrome-Extension/WhatsApp Monitor/wapi.js | 1411 +++++++++++++++++ .../WhatsApp Monitor/websocket.js | 98 +- 12 files changed, 3178 insertions(+), 684 deletions(-) create mode 100644 Chrome-Extension/WhatsApp Monitor/css/font-awesome.css create mode 100644 Chrome-Extension/WhatsApp Monitor/css/itel.css create mode 100644 Chrome-Extension/WhatsApp Monitor/inject_wp.js create mode 100644 Chrome-Extension/WhatsApp Monitor/wapi.js diff --git a/Chrome-Extension/WhatsApp Monitor/css/font-awesome.css b/Chrome-Extension/WhatsApp Monitor/css/font-awesome.css new file mode 100644 index 0000000..27b1d0c --- /dev/null +++ b/Chrome-Extension/WhatsApp Monitor/css/font-awesome.css @@ -0,0 +1,5 @@ +/*! + * Font Awesome Free 5.15.4 by @fontawesome - https://fontawesome.com + * License - https://fontawesome.com/license/free (Icons: CC BY 4.0, Fonts: SIL OFL 1.1, Code: MIT License) + */ + .fa,.fab,.fad,.fal,.far,.fas{-moz-osx-font-smoothing:grayscale;-webkit-font-smoothing:antialiased;display:inline-block;font-style:normal;font-variant:normal;text-rendering:auto;line-height:1}.fa-lg{font-size:1.33333em;line-height:.75em;vertical-align:-.0667em}.fa-xs{font-size:.75em}.fa-sm{font-size:.875em}.fa-1x{font-size:1em}.fa-2x{font-size:2em}.fa-3x{font-size:3em}.fa-4x{font-size:4em}.fa-5x{font-size:5em}.fa-6x{font-size:6em}.fa-7x{font-size:7em}.fa-8x{font-size:8em}.fa-9x{font-size:9em}.fa-10x{font-size:10em}.fa-fw{text-align:center;width:1.25em}.fa-ul{list-style-type:none;margin-left:2.5em;padding-left:0}.fa-ul>li{position:relative}.fa-li{left:-2em;position:absolute;text-align:center;width:2em;line-height:inherit}.fa-border{border:.08em solid #eee;border-radius:.1em;padding:.2em .25em .15em}.fa-pull-left{float:left}.fa-pull-right{float:right}.fa.fa-pull-left,.fab.fa-pull-left,.fal.fa-pull-left,.far.fa-pull-left,.fas.fa-pull-left{margin-right:.3em}.fa.fa-pull-right,.fab.fa-pull-right,.fal.fa-pull-right,.far.fa-pull-right,.fas.fa-pull-right{margin-left:.3em}.fa-spin{-webkit-animation:fa-spin 2s linear infinite;animation:fa-spin 2s linear infinite}.fa-pulse{-webkit-animation:fa-spin 1s steps(8) infinite;animation:fa-spin 1s steps(8) infinite}@-webkit-keyframes fa-spin{0%{-webkit-transform:rotate(0deg);transform:rotate(0deg)}to{-webkit-transform:rotate(1turn);transform:rotate(1turn)}}@keyframes fa-spin{0%{-webkit-transform:rotate(0deg);transform:rotate(0deg)}to{-webkit-transform:rotate(1turn);transform:rotate(1turn)}}.fa-rotate-90{-ms-filter:"progid:DXImageTransform.Microsoft.BasicImage(rotation=1)";-webkit-transform:rotate(90deg);transform:rotate(90deg)}.fa-rotate-180{-ms-filter:"progid:DXImageTransform.Microsoft.BasicImage(rotation=2)";-webkit-transform:rotate(180deg);transform:rotate(180deg)}.fa-rotate-270{-ms-filter:"progid:DXImageTransform.Microsoft.BasicImage(rotation=3)";-webkit-transform:rotate(270deg);transform:rotate(270deg)}.fa-flip-horizontal{-ms-filter:"progid:DXImageTransform.Microsoft.BasicImage(rotation=0, mirror=1)";-webkit-transform:scaleX(-1);transform:scaleX(-1)}.fa-flip-vertical{-webkit-transform:scaleY(-1);transform:scaleY(-1)}.fa-flip-both,.fa-flip-horizontal.fa-flip-vertical,.fa-flip-vertical{-ms-filter:"progid:DXImageTransform.Microsoft.BasicImage(rotation=2, mirror=1)"}.fa-flip-both,.fa-flip-horizontal.fa-flip-vertical{-webkit-transform:scale(-1);transform:scale(-1)}:root .fa-flip-both,:root .fa-flip-horizontal,:root .fa-flip-vertical,:root .fa-rotate-90,:root .fa-rotate-180,:root .fa-rotate-270{-webkit-filter:none;filter:none}.fa-stack{display:inline-block;height:2em;line-height:2em;position:relative;vertical-align:middle;width:2.5em}.fa-stack-1x,.fa-stack-2x{left:0;position:absolute;text-align:center;width:100%}.fa-stack-1x{line-height:inherit}.fa-stack-2x{font-size:2em}.fa-inverse{color:#fff}.fa-500px:before{content:"\f26e"}.fa-accessible-icon:before{content:"\f368"}.fa-accusoft:before{content:"\f369"}.fa-acquisitions-incorporated:before{content:"\f6af"}.fa-ad:before{content:"\f641"}.fa-address-book:before{content:"\f2b9"}.fa-address-card:before{content:"\f2bb"}.fa-adjust:before{content:"\f042"}.fa-adn:before{content:"\f170"}.fa-adversal:before{content:"\f36a"}.fa-affiliatetheme:before{content:"\f36b"}.fa-air-freshener:before{content:"\f5d0"}.fa-airbnb:before{content:"\f834"}.fa-algolia:before{content:"\f36c"}.fa-align-center:before{content:"\f037"}.fa-align-justify:before{content:"\f039"}.fa-align-left:before{content:"\f036"}.fa-align-right:before{content:"\f038"}.fa-alipay:before{content:"\f642"}.fa-allergies:before{content:"\f461"}.fa-amazon:before{content:"\f270"}.fa-amazon-pay:before{content:"\f42c"}.fa-ambulance:before{content:"\f0f9"}.fa-american-sign-language-interpreting:before{content:"\f2a3"}.fa-amilia:before{content:"\f36d"}.fa-anchor:before{content:"\f13d"}.fa-android:before{content:"\f17b"}.fa-angellist:before{content:"\f209"}.fa-angle-double-down:before{content:"\f103"}.fa-angle-double-left:before{content:"\f100"}.fa-angle-double-right:before{content:"\f101"}.fa-angle-double-up:before{content:"\f102"}.fa-angle-down:before{content:"\f107"}.fa-angle-left:before{content:"\f104"}.fa-angle-right:before{content:"\f105"}.fa-angle-up:before{content:"\f106"}.fa-angry:before{content:"\f556"}.fa-angrycreative:before{content:"\f36e"}.fa-angular:before{content:"\f420"}.fa-ankh:before{content:"\f644"}.fa-app-store:before{content:"\f36f"}.fa-app-store-ios:before{content:"\f370"}.fa-apper:before{content:"\f371"}.fa-apple:before{content:"\f179"}.fa-apple-alt:before{content:"\f5d1"}.fa-apple-pay:before{content:"\f415"}.fa-archive:before{content:"\f187"}.fa-archway:before{content:"\f557"}.fa-arrow-alt-circle-down:before{content:"\f358"}.fa-arrow-alt-circle-left:before{content:"\f359"}.fa-arrow-alt-circle-right:before{content:"\f35a"}.fa-arrow-alt-circle-up:before{content:"\f35b"}.fa-arrow-circle-down:before{content:"\f0ab"}.fa-arrow-circle-left:before{content:"\f0a8"}.fa-arrow-circle-right:before{content:"\f0a9"}.fa-arrow-circle-up:before{content:"\f0aa"}.fa-arrow-down:before{content:"\f063"}.fa-arrow-left:before{content:"\f060"}.fa-arrow-right:before{content:"\f061"}.fa-arrow-up:before{content:"\f062"}.fa-arrows-alt:before{content:"\f0b2"}.fa-arrows-alt-h:before{content:"\f337"}.fa-arrows-alt-v:before{content:"\f338"}.fa-artstation:before{content:"\f77a"}.fa-assistive-listening-systems:before{content:"\f2a2"}.fa-asterisk:before{content:"\f069"}.fa-asymmetrik:before{content:"\f372"}.fa-at:before{content:"\f1fa"}.fa-atlas:before{content:"\f558"}.fa-atlassian:before{content:"\f77b"}.fa-atom:before{content:"\f5d2"}.fa-audible:before{content:"\f373"}.fa-audio-description:before{content:"\f29e"}.fa-autoprefixer:before{content:"\f41c"}.fa-avianex:before{content:"\f374"}.fa-aviato:before{content:"\f421"}.fa-award:before{content:"\f559"}.fa-aws:before{content:"\f375"}.fa-baby:before{content:"\f77c"}.fa-baby-carriage:before{content:"\f77d"}.fa-backspace:before{content:"\f55a"}.fa-backward:before{content:"\f04a"}.fa-bacon:before{content:"\f7e5"}.fa-bacteria:before{content:"\e059"}.fa-bacterium:before{content:"\e05a"}.fa-bahai:before{content:"\f666"}.fa-balance-scale:before{content:"\f24e"}.fa-balance-scale-left:before{content:"\f515"}.fa-balance-scale-right:before{content:"\f516"}.fa-ban:before{content:"\f05e"}.fa-band-aid:before{content:"\f462"}.fa-bandcamp:before{content:"\f2d5"}.fa-barcode:before{content:"\f02a"}.fa-bars:before{content:"\f0c9"}.fa-baseball-ball:before{content:"\f433"}.fa-basketball-ball:before{content:"\f434"}.fa-bath:before{content:"\f2cd"}.fa-battery-empty:before{content:"\f244"}.fa-battery-full:before{content:"\f240"}.fa-battery-half:before{content:"\f242"}.fa-battery-quarter:before{content:"\f243"}.fa-battery-three-quarters:before{content:"\f241"}.fa-battle-net:before{content:"\f835"}.fa-bed:before{content:"\f236"}.fa-beer:before{content:"\f0fc"}.fa-behance:before{content:"\f1b4"}.fa-behance-square:before{content:"\f1b5"}.fa-bell:before{content:"\f0f3"}.fa-bell-slash:before{content:"\f1f6"}.fa-bezier-curve:before{content:"\f55b"}.fa-bible:before{content:"\f647"}.fa-bicycle:before{content:"\f206"}.fa-biking:before{content:"\f84a"}.fa-bimobject:before{content:"\f378"}.fa-binoculars:before{content:"\f1e5"}.fa-biohazard:before{content:"\f780"}.fa-birthday-cake:before{content:"\f1fd"}.fa-bitbucket:before{content:"\f171"}.fa-bitcoin:before{content:"\f379"}.fa-bity:before{content:"\f37a"}.fa-black-tie:before{content:"\f27e"}.fa-blackberry:before{content:"\f37b"}.fa-blender:before{content:"\f517"}.fa-blender-phone:before{content:"\f6b6"}.fa-blind:before{content:"\f29d"}.fa-blog:before{content:"\f781"}.fa-blogger:before{content:"\f37c"}.fa-blogger-b:before{content:"\f37d"}.fa-bluetooth:before{content:"\f293"}.fa-bluetooth-b:before{content:"\f294"}.fa-bold:before{content:"\f032"}.fa-bolt:before{content:"\f0e7"}.fa-bomb:before{content:"\f1e2"}.fa-bone:before{content:"\f5d7"}.fa-bong:before{content:"\f55c"}.fa-book:before{content:"\f02d"}.fa-book-dead:before{content:"\f6b7"}.fa-book-medical:before{content:"\f7e6"}.fa-book-open:before{content:"\f518"}.fa-book-reader:before{content:"\f5da"}.fa-bookmark:before{content:"\f02e"}.fa-bootstrap:before{content:"\f836"}.fa-border-all:before{content:"\f84c"}.fa-border-none:before{content:"\f850"}.fa-border-style:before{content:"\f853"}.fa-bowling-ball:before{content:"\f436"}.fa-box:before{content:"\f466"}.fa-box-open:before{content:"\f49e"}.fa-box-tissue:before{content:"\e05b"}.fa-boxes:before{content:"\f468"}.fa-braille:before{content:"\f2a1"}.fa-brain:before{content:"\f5dc"}.fa-bread-slice:before{content:"\f7ec"}.fa-briefcase:before{content:"\f0b1"}.fa-briefcase-medical:before{content:"\f469"}.fa-broadcast-tower:before{content:"\f519"}.fa-broom:before{content:"\f51a"}.fa-brush:before{content:"\f55d"}.fa-btc:before{content:"\f15a"}.fa-buffer:before{content:"\f837"}.fa-bug:before{content:"\f188"}.fa-building:before{content:"\f1ad"}.fa-bullhorn:before{content:"\f0a1"}.fa-bullseye:before{content:"\f140"}.fa-burn:before{content:"\f46a"}.fa-buromobelexperte:before{content:"\f37f"}.fa-bus:before{content:"\f207"}.fa-bus-alt:before{content:"\f55e"}.fa-business-time:before{content:"\f64a"}.fa-buy-n-large:before{content:"\f8a6"}.fa-buysellads:before{content:"\f20d"}.fa-calculator:before{content:"\f1ec"}.fa-calendar:before{content:"\f133"}.fa-calendar-alt:before{content:"\f073"}.fa-calendar-check:before{content:"\f274"}.fa-calendar-day:before{content:"\f783"}.fa-calendar-minus:before{content:"\f272"}.fa-calendar-plus:before{content:"\f271"}.fa-calendar-times:before{content:"\f273"}.fa-calendar-week:before{content:"\f784"}.fa-camera:before{content:"\f030"}.fa-camera-retro:before{content:"\f083"}.fa-campground:before{content:"\f6bb"}.fa-canadian-maple-leaf:before{content:"\f785"}.fa-candy-cane:before{content:"\f786"}.fa-cannabis:before{content:"\f55f"}.fa-capsules:before{content:"\f46b"}.fa-car:before{content:"\f1b9"}.fa-car-alt:before{content:"\f5de"}.fa-car-battery:before{content:"\f5df"}.fa-car-crash:before{content:"\f5e1"}.fa-car-side:before{content:"\f5e4"}.fa-caravan:before{content:"\f8ff"}.fa-caret-down:before{content:"\f0d7"}.fa-caret-left:before{content:"\f0d9"}.fa-caret-right:before{content:"\f0da"}.fa-caret-square-down:before{content:"\f150"}.fa-caret-square-left:before{content:"\f191"}.fa-caret-square-right:before{content:"\f152"}.fa-caret-square-up:before{content:"\f151"}.fa-caret-up:before{content:"\f0d8"}.fa-carrot:before{content:"\f787"}.fa-cart-arrow-down:before{content:"\f218"}.fa-cart-plus:before{content:"\f217"}.fa-cash-register:before{content:"\f788"}.fa-cat:before{content:"\f6be"}.fa-cc-amazon-pay:before{content:"\f42d"}.fa-cc-amex:before{content:"\f1f3"}.fa-cc-apple-pay:before{content:"\f416"}.fa-cc-diners-club:before{content:"\f24c"}.fa-cc-discover:before{content:"\f1f2"}.fa-cc-jcb:before{content:"\f24b"}.fa-cc-mastercard:before{content:"\f1f1"}.fa-cc-paypal:before{content:"\f1f4"}.fa-cc-stripe:before{content:"\f1f5"}.fa-cc-visa:before{content:"\f1f0"}.fa-centercode:before{content:"\f380"}.fa-centos:before{content:"\f789"}.fa-certificate:before{content:"\f0a3"}.fa-chair:before{content:"\f6c0"}.fa-chalkboard:before{content:"\f51b"}.fa-chalkboard-teacher:before{content:"\f51c"}.fa-charging-station:before{content:"\f5e7"}.fa-chart-area:before{content:"\f1fe"}.fa-chart-bar:before{content:"\f080"}.fa-chart-line:before{content:"\f201"}.fa-chart-pie:before{content:"\f200"}.fa-check:before{content:"\f00c"}.fa-check-circle:before{content:"\f058"}.fa-check-double:before{content:"\f560"}.fa-check-square:before{content:"\f14a"}.fa-cheese:before{content:"\f7ef"}.fa-chess:before{content:"\f439"}.fa-chess-bishop:before{content:"\f43a"}.fa-chess-board:before{content:"\f43c"}.fa-chess-king:before{content:"\f43f"}.fa-chess-knight:before{content:"\f441"}.fa-chess-pawn:before{content:"\f443"}.fa-chess-queen:before{content:"\f445"}.fa-chess-rook:before{content:"\f447"}.fa-chevron-circle-down:before{content:"\f13a"}.fa-chevron-circle-left:before{content:"\f137"}.fa-chevron-circle-right:before{content:"\f138"}.fa-chevron-circle-up:before{content:"\f139"}.fa-chevron-down:before{content:"\f078"}.fa-chevron-left:before{content:"\f053"}.fa-chevron-right:before{content:"\f054"}.fa-chevron-up:before{content:"\f077"}.fa-child:before{content:"\f1ae"}.fa-chrome:before{content:"\f268"}.fa-chromecast:before{content:"\f838"}.fa-church:before{content:"\f51d"}.fa-circle:before{content:"\f111"}.fa-circle-notch:before{content:"\f1ce"}.fa-city:before{content:"\f64f"}.fa-clinic-medical:before{content:"\f7f2"}.fa-clipboard:before{content:"\f328"}.fa-clipboard-check:before{content:"\f46c"}.fa-clipboard-list:before{content:"\f46d"}.fa-clock:before{content:"\f017"}.fa-clone:before{content:"\f24d"}.fa-closed-captioning:before{content:"\f20a"}.fa-cloud:before{content:"\f0c2"}.fa-cloud-download-alt:before{content:"\f381"}.fa-cloud-meatball:before{content:"\f73b"}.fa-cloud-moon:before{content:"\f6c3"}.fa-cloud-moon-rain:before{content:"\f73c"}.fa-cloud-rain:before{content:"\f73d"}.fa-cloud-showers-heavy:before{content:"\f740"}.fa-cloud-sun:before{content:"\f6c4"}.fa-cloud-sun-rain:before{content:"\f743"}.fa-cloud-upload-alt:before{content:"\f382"}.fa-cloudflare:before{content:"\e07d"}.fa-cloudscale:before{content:"\f383"}.fa-cloudsmith:before{content:"\f384"}.fa-cloudversify:before{content:"\f385"}.fa-cocktail:before{content:"\f561"}.fa-code:before{content:"\f121"}.fa-code-branch:before{content:"\f126"}.fa-codepen:before{content:"\f1cb"}.fa-codiepie:before{content:"\f284"}.fa-coffee:before{content:"\f0f4"}.fa-cog:before{content:"\f013"}.fa-cogs:before{content:"\f085"}.fa-coins:before{content:"\f51e"}.fa-columns:before{content:"\f0db"}.fa-comment:before{content:"\f075"}.fa-comment-alt:before{content:"\f27a"}.fa-comment-dollar:before{content:"\f651"}.fa-comment-dots:before{content:"\f4ad"}.fa-comment-medical:before{content:"\f7f5"}.fa-comment-slash:before{content:"\f4b3"}.fa-comments:before{content:"\f086"}.fa-comments-dollar:before{content:"\f653"}.fa-compact-disc:before{content:"\f51f"}.fa-compass:before{content:"\f14e"}.fa-compress:before{content:"\f066"}.fa-compress-alt:before{content:"\f422"}.fa-compress-arrows-alt:before{content:"\f78c"}.fa-concierge-bell:before{content:"\f562"}.fa-confluence:before{content:"\f78d"}.fa-connectdevelop:before{content:"\f20e"}.fa-contao:before{content:"\f26d"}.fa-cookie:before{content:"\f563"}.fa-cookie-bite:before{content:"\f564"}.fa-copy:before{content:"\f0c5"}.fa-copyright:before{content:"\f1f9"}.fa-cotton-bureau:before{content:"\f89e"}.fa-couch:before{content:"\f4b8"}.fa-cpanel:before{content:"\f388"}.fa-creative-commons:before{content:"\f25e"}.fa-creative-commons-by:before{content:"\f4e7"}.fa-creative-commons-nc:before{content:"\f4e8"}.fa-creative-commons-nc-eu:before{content:"\f4e9"}.fa-creative-commons-nc-jp:before{content:"\f4ea"}.fa-creative-commons-nd:before{content:"\f4eb"}.fa-creative-commons-pd:before{content:"\f4ec"}.fa-creative-commons-pd-alt:before{content:"\f4ed"}.fa-creative-commons-remix:before{content:"\f4ee"}.fa-creative-commons-sa:before{content:"\f4ef"}.fa-creative-commons-sampling:before{content:"\f4f0"}.fa-creative-commons-sampling-plus:before{content:"\f4f1"}.fa-creative-commons-share:before{content:"\f4f2"}.fa-creative-commons-zero:before{content:"\f4f3"}.fa-credit-card:before{content:"\f09d"}.fa-critical-role:before{content:"\f6c9"}.fa-crop:before{content:"\f125"}.fa-crop-alt:before{content:"\f565"}.fa-cross:before{content:"\f654"}.fa-crosshairs:before{content:"\f05b"}.fa-crow:before{content:"\f520"}.fa-crown:before{content:"\f521"}.fa-crutch:before{content:"\f7f7"}.fa-css3:before{content:"\f13c"}.fa-css3-alt:before{content:"\f38b"}.fa-cube:before{content:"\f1b2"}.fa-cubes:before{content:"\f1b3"}.fa-cut:before{content:"\f0c4"}.fa-cuttlefish:before{content:"\f38c"}.fa-d-and-d:before{content:"\f38d"}.fa-d-and-d-beyond:before{content:"\f6ca"}.fa-dailymotion:before{content:"\e052"}.fa-dashcube:before{content:"\f210"}.fa-database:before{content:"\f1c0"}.fa-deaf:before{content:"\f2a4"}.fa-deezer:before{content:"\e077"}.fa-delicious:before{content:"\f1a5"}.fa-democrat:before{content:"\f747"}.fa-deploydog:before{content:"\f38e"}.fa-deskpro:before{content:"\f38f"}.fa-desktop:before{content:"\f108"}.fa-dev:before{content:"\f6cc"}.fa-deviantart:before{content:"\f1bd"}.fa-dharmachakra:before{content:"\f655"}.fa-dhl:before{content:"\f790"}.fa-diagnoses:before{content:"\f470"}.fa-diaspora:before{content:"\f791"}.fa-dice:before{content:"\f522"}.fa-dice-d20:before{content:"\f6cf"}.fa-dice-d6:before{content:"\f6d1"}.fa-dice-five:before{content:"\f523"}.fa-dice-four:before{content:"\f524"}.fa-dice-one:before{content:"\f525"}.fa-dice-six:before{content:"\f526"}.fa-dice-three:before{content:"\f527"}.fa-dice-two:before{content:"\f528"}.fa-digg:before{content:"\f1a6"}.fa-digital-ocean:before{content:"\f391"}.fa-digital-tachograph:before{content:"\f566"}.fa-directions:before{content:"\f5eb"}.fa-discord:before{content:"\f392"}.fa-discourse:before{content:"\f393"}.fa-disease:before{content:"\f7fa"}.fa-divide:before{content:"\f529"}.fa-dizzy:before{content:"\f567"}.fa-dna:before{content:"\f471"}.fa-dochub:before{content:"\f394"}.fa-docker:before{content:"\f395"}.fa-dog:before{content:"\f6d3"}.fa-dollar-sign:before{content:"\f155"}.fa-dolly:before{content:"\f472"}.fa-dolly-flatbed:before{content:"\f474"}.fa-donate:before{content:"\f4b9"}.fa-door-closed:before{content:"\f52a"}.fa-door-open:before{content:"\f52b"}.fa-dot-circle:before{content:"\f192"}.fa-dove:before{content:"\f4ba"}.fa-download:before{content:"\f019"}.fa-draft2digital:before{content:"\f396"}.fa-drafting-compass:before{content:"\f568"}.fa-dragon:before{content:"\f6d5"}.fa-draw-polygon:before{content:"\f5ee"}.fa-dribbble:before{content:"\f17d"}.fa-dribbble-square:before{content:"\f397"}.fa-dropbox:before{content:"\f16b"}.fa-drum:before{content:"\f569"}.fa-drum-steelpan:before{content:"\f56a"}.fa-drumstick-bite:before{content:"\f6d7"}.fa-drupal:before{content:"\f1a9"}.fa-dumbbell:before{content:"\f44b"}.fa-dumpster:before{content:"\f793"}.fa-dumpster-fire:before{content:"\f794"}.fa-dungeon:before{content:"\f6d9"}.fa-dyalog:before{content:"\f399"}.fa-earlybirds:before{content:"\f39a"}.fa-ebay:before{content:"\f4f4"}.fa-edge:before{content:"\f282"}.fa-edge-legacy:before{content:"\e078"}.fa-edit:before{content:"\f044"}.fa-egg:before{content:"\f7fb"}.fa-eject:before{content:"\f052"}.fa-elementor:before{content:"\f430"}.fa-ellipsis-h:before{content:"\f141"}.fa-ellipsis-v:before{content:"\f142"}.fa-ello:before{content:"\f5f1"}.fa-ember:before{content:"\f423"}.fa-empire:before{content:"\f1d1"}.fa-envelope:before{content:"\f0e0"}.fa-envelope-open:before{content:"\f2b6"}.fa-envelope-open-text:before{content:"\f658"}.fa-envelope-square:before{content:"\f199"}.fa-envira:before{content:"\f299"}.fa-equals:before{content:"\f52c"}.fa-eraser:before{content:"\f12d"}.fa-erlang:before{content:"\f39d"}.fa-ethereum:before{content:"\f42e"}.fa-ethernet:before{content:"\f796"}.fa-etsy:before{content:"\f2d7"}.fa-euro-sign:before{content:"\f153"}.fa-evernote:before{content:"\f839"}.fa-exchange-alt:before{content:"\f362"}.fa-exclamation:before{content:"\f12a"}.fa-exclamation-circle:before{content:"\f06a"}.fa-exclamation-triangle:before{content:"\f071"}.fa-expand:before{content:"\f065"}.fa-expand-alt:before{content:"\f424"}.fa-expand-arrows-alt:before{content:"\f31e"}.fa-expeditedssl:before{content:"\f23e"}.fa-external-link-alt:before{content:"\f35d"}.fa-external-link-square-alt:before{content:"\f360"}.fa-eye:before{content:"\f06e"}.fa-eye-dropper:before{content:"\f1fb"}.fa-eye-slash:before{content:"\f070"}.fa-facebook:before{content:"\f09a"}.fa-facebook-f:before{content:"\f39e"}.fa-facebook-messenger:before{content:"\f39f"}.fa-facebook-square:before{content:"\f082"}.fa-fan:before{content:"\f863"}.fa-fantasy-flight-games:before{content:"\f6dc"}.fa-fast-backward:before{content:"\f049"}.fa-fast-forward:before{content:"\f050"}.fa-faucet:before{content:"\e005"}.fa-fax:before{content:"\f1ac"}.fa-feather:before{content:"\f52d"}.fa-feather-alt:before{content:"\f56b"}.fa-fedex:before{content:"\f797"}.fa-fedora:before{content:"\f798"}.fa-female:before{content:"\f182"}.fa-fighter-jet:before{content:"\f0fb"}.fa-figma:before{content:"\f799"}.fa-file:before{content:"\f15b"}.fa-file-alt:before{content:"\f15c"}.fa-file-archive:before{content:"\f1c6"}.fa-file-audio:before{content:"\f1c7"}.fa-file-code:before{content:"\f1c9"}.fa-file-contract:before{content:"\f56c"}.fa-file-csv:before{content:"\f6dd"}.fa-file-download:before{content:"\f56d"}.fa-file-excel:before{content:"\f1c3"}.fa-file-export:before{content:"\f56e"}.fa-file-image:before{content:"\f1c5"}.fa-file-import:before{content:"\f56f"}.fa-file-invoice:before{content:"\f570"}.fa-file-invoice-dollar:before{content:"\f571"}.fa-file-medical:before{content:"\f477"}.fa-file-medical-alt:before{content:"\f478"}.fa-file-pdf:before{content:"\f1c1"}.fa-file-powerpoint:before{content:"\f1c4"}.fa-file-prescription:before{content:"\f572"}.fa-file-signature:before{content:"\f573"}.fa-file-upload:before{content:"\f574"}.fa-file-video:before{content:"\f1c8"}.fa-file-word:before{content:"\f1c2"}.fa-fill:before{content:"\f575"}.fa-fill-drip:before{content:"\f576"}.fa-film:before{content:"\f008"}.fa-filter:before{content:"\f0b0"}.fa-fingerprint:before{content:"\f577"}.fa-fire:before{content:"\f06d"}.fa-fire-alt:before{content:"\f7e4"}.fa-fire-extinguisher:before{content:"\f134"}.fa-firefox:before{content:"\f269"}.fa-firefox-browser:before{content:"\e007"}.fa-first-aid:before{content:"\f479"}.fa-first-order:before{content:"\f2b0"}.fa-first-order-alt:before{content:"\f50a"}.fa-firstdraft:before{content:"\f3a1"}.fa-fish:before{content:"\f578"}.fa-fist-raised:before{content:"\f6de"}.fa-flag:before{content:"\f024"}.fa-flag-checkered:before{content:"\f11e"}.fa-flag-usa:before{content:"\f74d"}.fa-flask:before{content:"\f0c3"}.fa-flickr:before{content:"\f16e"}.fa-flipboard:before{content:"\f44d"}.fa-flushed:before{content:"\f579"}.fa-fly:before{content:"\f417"}.fa-folder:before{content:"\f07b"}.fa-folder-minus:before{content:"\f65d"}.fa-folder-open:before{content:"\f07c"}.fa-folder-plus:before{content:"\f65e"}.fa-font:before{content:"\f031"}.fa-font-awesome:before{content:"\f2b4"}.fa-font-awesome-alt:before{content:"\f35c"}.fa-font-awesome-flag:before{content:"\f425"}.fa-font-awesome-logo-full:before{content:"\f4e6"}.fa-fonticons:before{content:"\f280"}.fa-fonticons-fi:before{content:"\f3a2"}.fa-football-ball:before{content:"\f44e"}.fa-fort-awesome:before{content:"\f286"}.fa-fort-awesome-alt:before{content:"\f3a3"}.fa-forumbee:before{content:"\f211"}.fa-forward:before{content:"\f04e"}.fa-foursquare:before{content:"\f180"}.fa-free-code-camp:before{content:"\f2c5"}.fa-freebsd:before{content:"\f3a4"}.fa-frog:before{content:"\f52e"}.fa-frown:before{content:"\f119"}.fa-frown-open:before{content:"\f57a"}.fa-fulcrum:before{content:"\f50b"}.fa-funnel-dollar:before{content:"\f662"}.fa-futbol:before{content:"\f1e3"}.fa-galactic-republic:before{content:"\f50c"}.fa-galactic-senate:before{content:"\f50d"}.fa-gamepad:before{content:"\f11b"}.fa-gas-pump:before{content:"\f52f"}.fa-gavel:before{content:"\f0e3"}.fa-gem:before{content:"\f3a5"}.fa-genderless:before{content:"\f22d"}.fa-get-pocket:before{content:"\f265"}.fa-gg:before{content:"\f260"}.fa-gg-circle:before{content:"\f261"}.fa-ghost:before{content:"\f6e2"}.fa-gift:before{content:"\f06b"}.fa-gifts:before{content:"\f79c"}.fa-git:before{content:"\f1d3"}.fa-git-alt:before{content:"\f841"}.fa-git-square:before{content:"\f1d2"}.fa-github:before{content:"\f09b"}.fa-github-alt:before{content:"\f113"}.fa-github-square:before{content:"\f092"}.fa-gitkraken:before{content:"\f3a6"}.fa-gitlab:before{content:"\f296"}.fa-gitter:before{content:"\f426"}.fa-glass-cheers:before{content:"\f79f"}.fa-glass-martini:before{content:"\f000"}.fa-glass-martini-alt:before{content:"\f57b"}.fa-glass-whiskey:before{content:"\f7a0"}.fa-glasses:before{content:"\f530"}.fa-glide:before{content:"\f2a5"}.fa-glide-g:before{content:"\f2a6"}.fa-globe:before{content:"\f0ac"}.fa-globe-africa:before{content:"\f57c"}.fa-globe-americas:before{content:"\f57d"}.fa-globe-asia:before{content:"\f57e"}.fa-globe-europe:before{content:"\f7a2"}.fa-gofore:before{content:"\f3a7"}.fa-golf-ball:before{content:"\f450"}.fa-goodreads:before{content:"\f3a8"}.fa-goodreads-g:before{content:"\f3a9"}.fa-google:before{content:"\f1a0"}.fa-google-drive:before{content:"\f3aa"}.fa-google-pay:before{content:"\e079"}.fa-google-play:before{content:"\f3ab"}.fa-google-plus:before{content:"\f2b3"}.fa-google-plus-g:before{content:"\f0d5"}.fa-google-plus-square:before{content:"\f0d4"}.fa-google-wallet:before{content:"\f1ee"}.fa-gopuram:before{content:"\f664"}.fa-graduation-cap:before{content:"\f19d"}.fa-gratipay:before{content:"\f184"}.fa-grav:before{content:"\f2d6"}.fa-greater-than:before{content:"\f531"}.fa-greater-than-equal:before{content:"\f532"}.fa-grimace:before{content:"\f57f"}.fa-grin:before{content:"\f580"}.fa-grin-alt:before{content:"\f581"}.fa-grin-beam:before{content:"\f582"}.fa-grin-beam-sweat:before{content:"\f583"}.fa-grin-hearts:before{content:"\f584"}.fa-grin-squint:before{content:"\f585"}.fa-grin-squint-tears:before{content:"\f586"}.fa-grin-stars:before{content:"\f587"}.fa-grin-tears:before{content:"\f588"}.fa-grin-tongue:before{content:"\f589"}.fa-grin-tongue-squint:before{content:"\f58a"}.fa-grin-tongue-wink:before{content:"\f58b"}.fa-grin-wink:before{content:"\f58c"}.fa-grip-horizontal:before{content:"\f58d"}.fa-grip-lines:before{content:"\f7a4"}.fa-grip-lines-vertical:before{content:"\f7a5"}.fa-grip-vertical:before{content:"\f58e"}.fa-gripfire:before{content:"\f3ac"}.fa-grunt:before{content:"\f3ad"}.fa-guilded:before{content:"\e07e"}.fa-guitar:before{content:"\f7a6"}.fa-gulp:before{content:"\f3ae"}.fa-h-square:before{content:"\f0fd"}.fa-hacker-news:before{content:"\f1d4"}.fa-hacker-news-square:before{content:"\f3af"}.fa-hackerrank:before{content:"\f5f7"}.fa-hamburger:before{content:"\f805"}.fa-hammer:before{content:"\f6e3"}.fa-hamsa:before{content:"\f665"}.fa-hand-holding:before{content:"\f4bd"}.fa-hand-holding-heart:before{content:"\f4be"}.fa-hand-holding-medical:before{content:"\e05c"}.fa-hand-holding-usd:before{content:"\f4c0"}.fa-hand-holding-water:before{content:"\f4c1"}.fa-hand-lizard:before{content:"\f258"}.fa-hand-middle-finger:before{content:"\f806"}.fa-hand-paper:before{content:"\f256"}.fa-hand-peace:before{content:"\f25b"}.fa-hand-point-down:before{content:"\f0a7"}.fa-hand-point-left:before{content:"\f0a5"}.fa-hand-point-right:before{content:"\f0a4"}.fa-hand-point-up:before{content:"\f0a6"}.fa-hand-pointer:before{content:"\f25a"}.fa-hand-rock:before{content:"\f255"}.fa-hand-scissors:before{content:"\f257"}.fa-hand-sparkles:before{content:"\e05d"}.fa-hand-spock:before{content:"\f259"}.fa-hands:before{content:"\f4c2"}.fa-hands-helping:before{content:"\f4c4"}.fa-hands-wash:before{content:"\e05e"}.fa-handshake:before{content:"\f2b5"}.fa-handshake-alt-slash:before{content:"\e05f"}.fa-handshake-slash:before{content:"\e060"}.fa-hanukiah:before{content:"\f6e6"}.fa-hard-hat:before{content:"\f807"}.fa-hashtag:before{content:"\f292"}.fa-hat-cowboy:before{content:"\f8c0"}.fa-hat-cowboy-side:before{content:"\f8c1"}.fa-hat-wizard:before{content:"\f6e8"}.fa-hdd:before{content:"\f0a0"}.fa-head-side-cough:before{content:"\e061"}.fa-head-side-cough-slash:before{content:"\e062"}.fa-head-side-mask:before{content:"\e063"}.fa-head-side-virus:before{content:"\e064"}.fa-heading:before{content:"\f1dc"}.fa-headphones:before{content:"\f025"}.fa-headphones-alt:before{content:"\f58f"}.fa-headset:before{content:"\f590"}.fa-heart:before{content:"\f004"}.fa-heart-broken:before{content:"\f7a9"}.fa-heartbeat:before{content:"\f21e"}.fa-helicopter:before{content:"\f533"}.fa-highlighter:before{content:"\f591"}.fa-hiking:before{content:"\f6ec"}.fa-hippo:before{content:"\f6ed"}.fa-hips:before{content:"\f452"}.fa-hire-a-helper:before{content:"\f3b0"}.fa-history:before{content:"\f1da"}.fa-hive:before{content:"\e07f"}.fa-hockey-puck:before{content:"\f453"}.fa-holly-berry:before{content:"\f7aa"}.fa-home:before{content:"\f015"}.fa-hooli:before{content:"\f427"}.fa-hornbill:before{content:"\f592"}.fa-horse:before{content:"\f6f0"}.fa-horse-head:before{content:"\f7ab"}.fa-hospital:before{content:"\f0f8"}.fa-hospital-alt:before{content:"\f47d"}.fa-hospital-symbol:before{content:"\f47e"}.fa-hospital-user:before{content:"\f80d"}.fa-hot-tub:before{content:"\f593"}.fa-hotdog:before{content:"\f80f"}.fa-hotel:before{content:"\f594"}.fa-hotjar:before{content:"\f3b1"}.fa-hourglass:before{content:"\f254"}.fa-hourglass-end:before{content:"\f253"}.fa-hourglass-half:before{content:"\f252"}.fa-hourglass-start:before{content:"\f251"}.fa-house-damage:before{content:"\f6f1"}.fa-house-user:before{content:"\e065"}.fa-houzz:before{content:"\f27c"}.fa-hryvnia:before{content:"\f6f2"}.fa-html5:before{content:"\f13b"}.fa-hubspot:before{content:"\f3b2"}.fa-i-cursor:before{content:"\f246"}.fa-ice-cream:before{content:"\f810"}.fa-icicles:before{content:"\f7ad"}.fa-icons:before{content:"\f86d"}.fa-id-badge:before{content:"\f2c1"}.fa-id-card:before{content:"\f2c2"}.fa-id-card-alt:before{content:"\f47f"}.fa-ideal:before{content:"\e013"}.fa-igloo:before{content:"\f7ae"}.fa-image:before{content:"\f03e"}.fa-images:before{content:"\f302"}.fa-imdb:before{content:"\f2d8"}.fa-inbox:before{content:"\f01c"}.fa-indent:before{content:"\f03c"}.fa-industry:before{content:"\f275"}.fa-infinity:before{content:"\f534"}.fa-info:before{content:"\f129"}.fa-info-circle:before{content:"\f05a"}.fa-innosoft:before{content:"\e080"}.fa-instagram:before{content:"\f16d"}.fa-instagram-square:before{content:"\e055"}.fa-instalod:before{content:"\e081"}.fa-intercom:before{content:"\f7af"}.fa-internet-explorer:before{content:"\f26b"}.fa-invision:before{content:"\f7b0"}.fa-ioxhost:before{content:"\f208"}.fa-italic:before{content:"\f033"}.fa-itch-io:before{content:"\f83a"}.fa-itunes:before{content:"\f3b4"}.fa-itunes-note:before{content:"\f3b5"}.fa-java:before{content:"\f4e4"}.fa-jedi:before{content:"\f669"}.fa-jedi-order:before{content:"\f50e"}.fa-jenkins:before{content:"\f3b6"}.fa-jira:before{content:"\f7b1"}.fa-joget:before{content:"\f3b7"}.fa-joint:before{content:"\f595"}.fa-joomla:before{content:"\f1aa"}.fa-journal-whills:before{content:"\f66a"}.fa-js:before{content:"\f3b8"}.fa-js-square:before{content:"\f3b9"}.fa-jsfiddle:before{content:"\f1cc"}.fa-kaaba:before{content:"\f66b"}.fa-kaggle:before{content:"\f5fa"}.fa-key:before{content:"\f084"}.fa-keybase:before{content:"\f4f5"}.fa-keyboard:before{content:"\f11c"}.fa-keycdn:before{content:"\f3ba"}.fa-khanda:before{content:"\f66d"}.fa-kickstarter:before{content:"\f3bb"}.fa-kickstarter-k:before{content:"\f3bc"}.fa-kiss:before{content:"\f596"}.fa-kiss-beam:before{content:"\f597"}.fa-kiss-wink-heart:before{content:"\f598"}.fa-kiwi-bird:before{content:"\f535"}.fa-korvue:before{content:"\f42f"}.fa-landmark:before{content:"\f66f"}.fa-language:before{content:"\f1ab"}.fa-laptop:before{content:"\f109"}.fa-laptop-code:before{content:"\f5fc"}.fa-laptop-house:before{content:"\e066"}.fa-laptop-medical:before{content:"\f812"}.fa-laravel:before{content:"\f3bd"}.fa-lastfm:before{content:"\f202"}.fa-lastfm-square:before{content:"\f203"}.fa-laugh:before{content:"\f599"}.fa-laugh-beam:before{content:"\f59a"}.fa-laugh-squint:before{content:"\f59b"}.fa-laugh-wink:before{content:"\f59c"}.fa-layer-group:before{content:"\f5fd"}.fa-leaf:before{content:"\f06c"}.fa-leanpub:before{content:"\f212"}.fa-lemon:before{content:"\f094"}.fa-less:before{content:"\f41d"}.fa-less-than:before{content:"\f536"}.fa-less-than-equal:before{content:"\f537"}.fa-level-down-alt:before{content:"\f3be"}.fa-level-up-alt:before{content:"\f3bf"}.fa-life-ring:before{content:"\f1cd"}.fa-lightbulb:before{content:"\f0eb"}.fa-line:before{content:"\f3c0"}.fa-link:before{content:"\f0c1"}.fa-linkedin:before{content:"\f08c"}.fa-linkedin-in:before{content:"\f0e1"}.fa-linode:before{content:"\f2b8"}.fa-linux:before{content:"\f17c"}.fa-lira-sign:before{content:"\f195"}.fa-list:before{content:"\f03a"}.fa-list-alt:before{content:"\f022"}.fa-list-ol:before{content:"\f0cb"}.fa-list-ul:before{content:"\f0ca"}.fa-location-arrow:before{content:"\f124"}.fa-lock:before{content:"\f023"}.fa-lock-open:before{content:"\f3c1"}.fa-long-arrow-alt-down:before{content:"\f309"}.fa-long-arrow-alt-left:before{content:"\f30a"}.fa-long-arrow-alt-right:before{content:"\f30b"}.fa-long-arrow-alt-up:before{content:"\f30c"}.fa-low-vision:before{content:"\f2a8"}.fa-luggage-cart:before{content:"\f59d"}.fa-lungs:before{content:"\f604"}.fa-lungs-virus:before{content:"\e067"}.fa-lyft:before{content:"\f3c3"}.fa-magento:before{content:"\f3c4"}.fa-magic:before{content:"\f0d0"}.fa-magnet:before{content:"\f076"}.fa-mail-bulk:before{content:"\f674"}.fa-mailchimp:before{content:"\f59e"}.fa-male:before{content:"\f183"}.fa-mandalorian:before{content:"\f50f"}.fa-map:before{content:"\f279"}.fa-map-marked:before{content:"\f59f"}.fa-map-marked-alt:before{content:"\f5a0"}.fa-map-marker:before{content:"\f041"}.fa-map-marker-alt:before{content:"\f3c5"}.fa-map-pin:before{content:"\f276"}.fa-map-signs:before{content:"\f277"}.fa-markdown:before{content:"\f60f"}.fa-marker:before{content:"\f5a1"}.fa-mars:before{content:"\f222"}.fa-mars-double:before{content:"\f227"}.fa-mars-stroke:before{content:"\f229"}.fa-mars-stroke-h:before{content:"\f22b"}.fa-mars-stroke-v:before{content:"\f22a"}.fa-mask:before{content:"\f6fa"}.fa-mastodon:before{content:"\f4f6"}.fa-maxcdn:before{content:"\f136"}.fa-mdb:before{content:"\f8ca"}.fa-medal:before{content:"\f5a2"}.fa-medapps:before{content:"\f3c6"}.fa-medium:before{content:"\f23a"}.fa-medium-m:before{content:"\f3c7"}.fa-medkit:before{content:"\f0fa"}.fa-medrt:before{content:"\f3c8"}.fa-meetup:before{content:"\f2e0"}.fa-megaport:before{content:"\f5a3"}.fa-meh:before{content:"\f11a"}.fa-meh-blank:before{content:"\f5a4"}.fa-meh-rolling-eyes:before{content:"\f5a5"}.fa-memory:before{content:"\f538"}.fa-mendeley:before{content:"\f7b3"}.fa-menorah:before{content:"\f676"}.fa-mercury:before{content:"\f223"}.fa-meteor:before{content:"\f753"}.fa-microblog:before{content:"\e01a"}.fa-microchip:before{content:"\f2db"}.fa-microphone:before{content:"\f130"}.fa-microphone-alt:before{content:"\f3c9"}.fa-microphone-alt-slash:before{content:"\f539"}.fa-microphone-slash:before{content:"\f131"}.fa-microscope:before{content:"\f610"}.fa-microsoft:before{content:"\f3ca"}.fa-minus:before{content:"\f068"}.fa-minus-circle:before{content:"\f056"}.fa-minus-square:before{content:"\f146"}.fa-mitten:before{content:"\f7b5"}.fa-mix:before{content:"\f3cb"}.fa-mixcloud:before{content:"\f289"}.fa-mixer:before{content:"\e056"}.fa-mizuni:before{content:"\f3cc"}.fa-mobile:before{content:"\f10b"}.fa-mobile-alt:before{content:"\f3cd"}.fa-modx:before{content:"\f285"}.fa-monero:before{content:"\f3d0"}.fa-money-bill:before{content:"\f0d6"}.fa-money-bill-alt:before{content:"\f3d1"}.fa-money-bill-wave:before{content:"\f53a"}.fa-money-bill-wave-alt:before{content:"\f53b"}.fa-money-check:before{content:"\f53c"}.fa-money-check-alt:before{content:"\f53d"}.fa-monument:before{content:"\f5a6"}.fa-moon:before{content:"\f186"}.fa-mortar-pestle:before{content:"\f5a7"}.fa-mosque:before{content:"\f678"}.fa-motorcycle:before{content:"\f21c"}.fa-mountain:before{content:"\f6fc"}.fa-mouse:before{content:"\f8cc"}.fa-mouse-pointer:before{content:"\f245"}.fa-mug-hot:before{content:"\f7b6"}.fa-music:before{content:"\f001"}.fa-napster:before{content:"\f3d2"}.fa-neos:before{content:"\f612"}.fa-network-wired:before{content:"\f6ff"}.fa-neuter:before{content:"\f22c"}.fa-newspaper:before{content:"\f1ea"}.fa-nimblr:before{content:"\f5a8"}.fa-node:before{content:"\f419"}.fa-node-js:before{content:"\f3d3"}.fa-not-equal:before{content:"\f53e"}.fa-notes-medical:before{content:"\f481"}.fa-npm:before{content:"\f3d4"}.fa-ns8:before{content:"\f3d5"}.fa-nutritionix:before{content:"\f3d6"}.fa-object-group:before{content:"\f247"}.fa-object-ungroup:before{content:"\f248"}.fa-octopus-deploy:before{content:"\e082"}.fa-odnoklassniki:before{content:"\f263"}.fa-odnoklassniki-square:before{content:"\f264"}.fa-oil-can:before{content:"\f613"}.fa-old-republic:before{content:"\f510"}.fa-om:before{content:"\f679"}.fa-opencart:before{content:"\f23d"}.fa-openid:before{content:"\f19b"}.fa-opera:before{content:"\f26a"}.fa-optin-monster:before{content:"\f23c"}.fa-orcid:before{content:"\f8d2"}.fa-osi:before{content:"\f41a"}.fa-otter:before{content:"\f700"}.fa-outdent:before{content:"\f03b"}.fa-page4:before{content:"\f3d7"}.fa-pagelines:before{content:"\f18c"}.fa-pager:before{content:"\f815"}.fa-paint-brush:before{content:"\f1fc"}.fa-paint-roller:before{content:"\f5aa"}.fa-palette:before{content:"\f53f"}.fa-palfed:before{content:"\f3d8"}.fa-pallet:before{content:"\f482"}.fa-paper-plane:before{content:"\f1d8"}.fa-paperclip:before{content:"\f0c6"}.fa-parachute-box:before{content:"\f4cd"}.fa-paragraph:before{content:"\f1dd"}.fa-parking:before{content:"\f540"}.fa-passport:before{content:"\f5ab"}.fa-pastafarianism:before{content:"\f67b"}.fa-paste:before{content:"\f0ea"}.fa-patreon:before{content:"\f3d9"}.fa-pause:before{content:"\f04c"}.fa-pause-circle:before{content:"\f28b"}.fa-paw:before{content:"\f1b0"}.fa-paypal:before{content:"\f1ed"}.fa-peace:before{content:"\f67c"}.fa-pen:before{content:"\f304"}.fa-pen-alt:before{content:"\f305"}.fa-pen-fancy:before{content:"\f5ac"}.fa-pen-nib:before{content:"\f5ad"}.fa-pen-square:before{content:"\f14b"}.fa-pencil-alt:before{content:"\f303"}.fa-pencil-ruler:before{content:"\f5ae"}.fa-penny-arcade:before{content:"\f704"}.fa-people-arrows:before{content:"\e068"}.fa-people-carry:before{content:"\f4ce"}.fa-pepper-hot:before{content:"\f816"}.fa-perbyte:before{content:"\e083"}.fa-percent:before{content:"\f295"}.fa-percentage:before{content:"\f541"}.fa-periscope:before{content:"\f3da"}.fa-person-booth:before{content:"\f756"}.fa-phabricator:before{content:"\f3db"}.fa-phoenix-framework:before{content:"\f3dc"}.fa-phoenix-squadron:before{content:"\f511"}.fa-phone:before{content:"\f095"}.fa-phone-alt:before{content:"\f879"}.fa-phone-slash:before{content:"\f3dd"}.fa-phone-square:before{content:"\f098"}.fa-phone-square-alt:before{content:"\f87b"}.fa-phone-volume:before{content:"\f2a0"}.fa-photo-video:before{content:"\f87c"}.fa-php:before{content:"\f457"}.fa-pied-piper:before{content:"\f2ae"}.fa-pied-piper-alt:before{content:"\f1a8"}.fa-pied-piper-hat:before{content:"\f4e5"}.fa-pied-piper-pp:before{content:"\f1a7"}.fa-pied-piper-square:before{content:"\e01e"}.fa-piggy-bank:before{content:"\f4d3"}.fa-pills:before{content:"\f484"}.fa-pinterest:before{content:"\f0d2"}.fa-pinterest-p:before{content:"\f231"}.fa-pinterest-square:before{content:"\f0d3"}.fa-pizza-slice:before{content:"\f818"}.fa-place-of-worship:before{content:"\f67f"}.fa-plane:before{content:"\f072"}.fa-plane-arrival:before{content:"\f5af"}.fa-plane-departure:before{content:"\f5b0"}.fa-plane-slash:before{content:"\e069"}.fa-play:before{content:"\f04b"}.fa-play-circle:before{content:"\f144"}.fa-playstation:before{content:"\f3df"}.fa-plug:before{content:"\f1e6"}.fa-plus:before{content:"\f067"}.fa-plus-circle:before{content:"\f055"}.fa-plus-square:before{content:"\f0fe"}.fa-podcast:before{content:"\f2ce"}.fa-poll:before{content:"\f681"}.fa-poll-h:before{content:"\f682"}.fa-poo:before{content:"\f2fe"}.fa-poo-storm:before{content:"\f75a"}.fa-poop:before{content:"\f619"}.fa-portrait:before{content:"\f3e0"}.fa-pound-sign:before{content:"\f154"}.fa-power-off:before{content:"\f011"}.fa-pray:before{content:"\f683"}.fa-praying-hands:before{content:"\f684"}.fa-prescription:before{content:"\f5b1"}.fa-prescription-bottle:before{content:"\f485"}.fa-prescription-bottle-alt:before{content:"\f486"}.fa-print:before{content:"\f02f"}.fa-procedures:before{content:"\f487"}.fa-product-hunt:before{content:"\f288"}.fa-project-diagram:before{content:"\f542"}.fa-pump-medical:before{content:"\e06a"}.fa-pump-soap:before{content:"\e06b"}.fa-pushed:before{content:"\f3e1"}.fa-puzzle-piece:before{content:"\f12e"}.fa-python:before{content:"\f3e2"}.fa-qq:before{content:"\f1d6"}.fa-qrcode:before{content:"\f029"}.fa-question:before{content:"\f128"}.fa-question-circle:before{content:"\f059"}.fa-quidditch:before{content:"\f458"}.fa-quinscape:before{content:"\f459"}.fa-quora:before{content:"\f2c4"}.fa-quote-left:before{content:"\f10d"}.fa-quote-right:before{content:"\f10e"}.fa-quran:before{content:"\f687"}.fa-r-project:before{content:"\f4f7"}.fa-radiation:before{content:"\f7b9"}.fa-radiation-alt:before{content:"\f7ba"}.fa-rainbow:before{content:"\f75b"}.fa-random:before{content:"\f074"}.fa-raspberry-pi:before{content:"\f7bb"}.fa-ravelry:before{content:"\f2d9"}.fa-react:before{content:"\f41b"}.fa-reacteurope:before{content:"\f75d"}.fa-readme:before{content:"\f4d5"}.fa-rebel:before{content:"\f1d0"}.fa-receipt:before{content:"\f543"}.fa-record-vinyl:before{content:"\f8d9"}.fa-recycle:before{content:"\f1b8"}.fa-red-river:before{content:"\f3e3"}.fa-reddit:before{content:"\f1a1"}.fa-reddit-alien:before{content:"\f281"}.fa-reddit-square:before{content:"\f1a2"}.fa-redhat:before{content:"\f7bc"}.fa-redo:before{content:"\f01e"}.fa-redo-alt:before{content:"\f2f9"}.fa-registered:before{content:"\f25d"}.fa-remove-format:before{content:"\f87d"}.fa-renren:before{content:"\f18b"}.fa-reply:before{content:"\f3e5"}.fa-reply-all:before{content:"\f122"}.fa-replyd:before{content:"\f3e6"}.fa-republican:before{content:"\f75e"}.fa-researchgate:before{content:"\f4f8"}.fa-resolving:before{content:"\f3e7"}.fa-restroom:before{content:"\f7bd"}.fa-retweet:before{content:"\f079"}.fa-rev:before{content:"\f5b2"}.fa-ribbon:before{content:"\f4d6"}.fa-ring:before{content:"\f70b"}.fa-road:before{content:"\f018"}.fa-robot:before{content:"\f544"}.fa-rocket:before{content:"\f135"}.fa-rocketchat:before{content:"\f3e8"}.fa-rockrms:before{content:"\f3e9"}.fa-route:before{content:"\f4d7"}.fa-rss:before{content:"\f09e"}.fa-rss-square:before{content:"\f143"}.fa-ruble-sign:before{content:"\f158"}.fa-ruler:before{content:"\f545"}.fa-ruler-combined:before{content:"\f546"}.fa-ruler-horizontal:before{content:"\f547"}.fa-ruler-vertical:before{content:"\f548"}.fa-running:before{content:"\f70c"}.fa-rupee-sign:before{content:"\f156"}.fa-rust:before{content:"\e07a"}.fa-sad-cry:before{content:"\f5b3"}.fa-sad-tear:before{content:"\f5b4"}.fa-safari:before{content:"\f267"}.fa-salesforce:before{content:"\f83b"}.fa-sass:before{content:"\f41e"}.fa-satellite:before{content:"\f7bf"}.fa-satellite-dish:before{content:"\f7c0"}.fa-save:before{content:"\f0c7"}.fa-schlix:before{content:"\f3ea"}.fa-school:before{content:"\f549"}.fa-screwdriver:before{content:"\f54a"}.fa-scribd:before{content:"\f28a"}.fa-scroll:before{content:"\f70e"}.fa-sd-card:before{content:"\f7c2"}.fa-search:before{content:"\f002"}.fa-search-dollar:before{content:"\f688"}.fa-search-location:before{content:"\f689"}.fa-search-minus:before{content:"\f010"}.fa-search-plus:before{content:"\f00e"}.fa-searchengin:before{content:"\f3eb"}.fa-seedling:before{content:"\f4d8"}.fa-sellcast:before{content:"\f2da"}.fa-sellsy:before{content:"\f213"}.fa-server:before{content:"\f233"}.fa-servicestack:before{content:"\f3ec"}.fa-shapes:before{content:"\f61f"}.fa-share:before{content:"\f064"}.fa-share-alt:before{content:"\f1e0"}.fa-share-alt-square:before{content:"\f1e1"}.fa-share-square:before{content:"\f14d"}.fa-shekel-sign:before{content:"\f20b"}.fa-shield-alt:before{content:"\f3ed"}.fa-shield-virus:before{content:"\e06c"}.fa-ship:before{content:"\f21a"}.fa-shipping-fast:before{content:"\f48b"}.fa-shirtsinbulk:before{content:"\f214"}.fa-shoe-prints:before{content:"\f54b"}.fa-shopify:before{content:"\e057"}.fa-shopping-bag:before{content:"\f290"}.fa-shopping-basket:before{content:"\f291"}.fa-shopping-cart:before{content:"\f07a"}.fa-shopware:before{content:"\f5b5"}.fa-shower:before{content:"\f2cc"}.fa-shuttle-van:before{content:"\f5b6"}.fa-sign:before{content:"\f4d9"}.fa-sign-in-alt:before{content:"\f2f6"}.fa-sign-language:before{content:"\f2a7"}.fa-sign-out-alt:before{content:"\f2f5"}.fa-signal:before{content:"\f012"}.fa-signature:before{content:"\f5b7"}.fa-sim-card:before{content:"\f7c4"}.fa-simplybuilt:before{content:"\f215"}.fa-sink:before{content:"\e06d"}.fa-sistrix:before{content:"\f3ee"}.fa-sitemap:before{content:"\f0e8"}.fa-sith:before{content:"\f512"}.fa-skating:before{content:"\f7c5"}.fa-sketch:before{content:"\f7c6"}.fa-skiing:before{content:"\f7c9"}.fa-skiing-nordic:before{content:"\f7ca"}.fa-skull:before{content:"\f54c"}.fa-skull-crossbones:before{content:"\f714"}.fa-skyatlas:before{content:"\f216"}.fa-skype:before{content:"\f17e"}.fa-slack:before{content:"\f198"}.fa-slack-hash:before{content:"\f3ef"}.fa-slash:before{content:"\f715"}.fa-sleigh:before{content:"\f7cc"}.fa-sliders-h:before{content:"\f1de"}.fa-slideshare:before{content:"\f1e7"}.fa-smile:before{content:"\f118"}.fa-smile-beam:before{content:"\f5b8"}.fa-smile-wink:before{content:"\f4da"}.fa-smog:before{content:"\f75f"}.fa-smoking:before{content:"\f48d"}.fa-smoking-ban:before{content:"\f54d"}.fa-sms:before{content:"\f7cd"}.fa-snapchat:before{content:"\f2ab"}.fa-snapchat-ghost:before{content:"\f2ac"}.fa-snapchat-square:before{content:"\f2ad"}.fa-snowboarding:before{content:"\f7ce"}.fa-snowflake:before{content:"\f2dc"}.fa-snowman:before{content:"\f7d0"}.fa-snowplow:before{content:"\f7d2"}.fa-soap:before{content:"\e06e"}.fa-socks:before{content:"\f696"}.fa-solar-panel:before{content:"\f5ba"}.fa-sort:before{content:"\f0dc"}.fa-sort-alpha-down:before{content:"\f15d"}.fa-sort-alpha-down-alt:before{content:"\f881"}.fa-sort-alpha-up:before{content:"\f15e"}.fa-sort-alpha-up-alt:before{content:"\f882"}.fa-sort-amount-down:before{content:"\f160"}.fa-sort-amount-down-alt:before{content:"\f884"}.fa-sort-amount-up:before{content:"\f161"}.fa-sort-amount-up-alt:before{content:"\f885"}.fa-sort-down:before{content:"\f0dd"}.fa-sort-numeric-down:before{content:"\f162"}.fa-sort-numeric-down-alt:before{content:"\f886"}.fa-sort-numeric-up:before{content:"\f163"}.fa-sort-numeric-up-alt:before{content:"\f887"}.fa-sort-up:before{content:"\f0de"}.fa-soundcloud:before{content:"\f1be"}.fa-sourcetree:before{content:"\f7d3"}.fa-spa:before{content:"\f5bb"}.fa-space-shuttle:before{content:"\f197"}.fa-speakap:before{content:"\f3f3"}.fa-speaker-deck:before{content:"\f83c"}.fa-spell-check:before{content:"\f891"}.fa-spider:before{content:"\f717"}.fa-spinner:before{content:"\f110"}.fa-splotch:before{content:"\f5bc"}.fa-spotify:before{content:"\f1bc"}.fa-spray-can:before{content:"\f5bd"}.fa-square:before{content:"\f0c8"}.fa-square-full:before{content:"\f45c"}.fa-square-root-alt:before{content:"\f698"}.fa-squarespace:before{content:"\f5be"}.fa-stack-exchange:before{content:"\f18d"}.fa-stack-overflow:before{content:"\f16c"}.fa-stackpath:before{content:"\f842"}.fa-stamp:before{content:"\f5bf"}.fa-star:before{content:"\f005"}.fa-star-and-crescent:before{content:"\f699"}.fa-star-half:before{content:"\f089"}.fa-star-half-alt:before{content:"\f5c0"}.fa-star-of-david:before{content:"\f69a"}.fa-star-of-life:before{content:"\f621"}.fa-staylinked:before{content:"\f3f5"}.fa-steam:before{content:"\f1b6"}.fa-steam-square:before{content:"\f1b7"}.fa-steam-symbol:before{content:"\f3f6"}.fa-step-backward:before{content:"\f048"}.fa-step-forward:before{content:"\f051"}.fa-stethoscope:before{content:"\f0f1"}.fa-sticker-mule:before{content:"\f3f7"}.fa-sticky-note:before{content:"\f249"}.fa-stop:before{content:"\f04d"}.fa-stop-circle:before{content:"\f28d"}.fa-stopwatch:before{content:"\f2f2"}.fa-stopwatch-20:before{content:"\e06f"}.fa-store:before{content:"\f54e"}.fa-store-alt:before{content:"\f54f"}.fa-store-alt-slash:before{content:"\e070"}.fa-store-slash:before{content:"\e071"}.fa-strava:before{content:"\f428"}.fa-stream:before{content:"\f550"}.fa-street-view:before{content:"\f21d"}.fa-strikethrough:before{content:"\f0cc"}.fa-stripe:before{content:"\f429"}.fa-stripe-s:before{content:"\f42a"}.fa-stroopwafel:before{content:"\f551"}.fa-studiovinari:before{content:"\f3f8"}.fa-stumbleupon:before{content:"\f1a4"}.fa-stumbleupon-circle:before{content:"\f1a3"}.fa-subscript:before{content:"\f12c"}.fa-subway:before{content:"\f239"}.fa-suitcase:before{content:"\f0f2"}.fa-suitcase-rolling:before{content:"\f5c1"}.fa-sun:before{content:"\f185"}.fa-superpowers:before{content:"\f2dd"}.fa-superscript:before{content:"\f12b"}.fa-supple:before{content:"\f3f9"}.fa-surprise:before{content:"\f5c2"}.fa-suse:before{content:"\f7d6"}.fa-swatchbook:before{content:"\f5c3"}.fa-swift:before{content:"\f8e1"}.fa-swimmer:before{content:"\f5c4"}.fa-swimming-pool:before{content:"\f5c5"}.fa-symfony:before{content:"\f83d"}.fa-synagogue:before{content:"\f69b"}.fa-sync:before{content:"\f021"}.fa-sync-alt:before{content:"\f2f1"}.fa-syringe:before{content:"\f48e"}.fa-table:before{content:"\f0ce"}.fa-table-tennis:before{content:"\f45d"}.fa-tablet:before{content:"\f10a"}.fa-tablet-alt:before{content:"\f3fa"}.fa-tablets:before{content:"\f490"}.fa-tachometer-alt:before{content:"\f3fd"}.fa-tag:before{content:"\f02b"}.fa-tags:before{content:"\f02c"}.fa-tape:before{content:"\f4db"}.fa-tasks:before{content:"\f0ae"}.fa-taxi:before{content:"\f1ba"}.fa-teamspeak:before{content:"\f4f9"}.fa-teeth:before{content:"\f62e"}.fa-teeth-open:before{content:"\f62f"}.fa-telegram:before{content:"\f2c6"}.fa-telegram-plane:before{content:"\f3fe"}.fa-temperature-high:before{content:"\f769"}.fa-temperature-low:before{content:"\f76b"}.fa-tencent-weibo:before{content:"\f1d5"}.fa-tenge:before{content:"\f7d7"}.fa-terminal:before{content:"\f120"}.fa-text-height:before{content:"\f034"}.fa-text-width:before{content:"\f035"}.fa-th:before{content:"\f00a"}.fa-th-large:before{content:"\f009"}.fa-th-list:before{content:"\f00b"}.fa-the-red-yeti:before{content:"\f69d"}.fa-theater-masks:before{content:"\f630"}.fa-themeco:before{content:"\f5c6"}.fa-themeisle:before{content:"\f2b2"}.fa-thermometer:before{content:"\f491"}.fa-thermometer-empty:before{content:"\f2cb"}.fa-thermometer-full:before{content:"\f2c7"}.fa-thermometer-half:before{content:"\f2c9"}.fa-thermometer-quarter:before{content:"\f2ca"}.fa-thermometer-three-quarters:before{content:"\f2c8"}.fa-think-peaks:before{content:"\f731"}.fa-thumbs-down:before{content:"\f165"}.fa-thumbs-up:before{content:"\f164"}.fa-thumbtack:before{content:"\f08d"}.fa-ticket-alt:before{content:"\f3ff"}.fa-tiktok:before{content:"\e07b"}.fa-times:before{content:"\f00d"}.fa-times-circle:before{content:"\f057"}.fa-tint:before{content:"\f043"}.fa-tint-slash:before{content:"\f5c7"}.fa-tired:before{content:"\f5c8"}.fa-toggle-off:before{content:"\f204"}.fa-toggle-on:before{content:"\f205"}.fa-toilet:before{content:"\f7d8"}.fa-toilet-paper:before{content:"\f71e"}.fa-toilet-paper-slash:before{content:"\e072"}.fa-toolbox:before{content:"\f552"}.fa-tools:before{content:"\f7d9"}.fa-tooth:before{content:"\f5c9"}.fa-torah:before{content:"\f6a0"}.fa-torii-gate:before{content:"\f6a1"}.fa-tractor:before{content:"\f722"}.fa-trade-federation:before{content:"\f513"}.fa-trademark:before{content:"\f25c"}.fa-traffic-light:before{content:"\f637"}.fa-trailer:before{content:"\e041"}.fa-train:before{content:"\f238"}.fa-tram:before{content:"\f7da"}.fa-transgender:before{content:"\f224"}.fa-transgender-alt:before{content:"\f225"}.fa-trash:before{content:"\f1f8"}.fa-trash-alt:before{content:"\f2ed"}.fa-trash-restore:before{content:"\f829"}.fa-trash-restore-alt:before{content:"\f82a"}.fa-tree:before{content:"\f1bb"}.fa-trello:before{content:"\f181"}.fa-trophy:before{content:"\f091"}.fa-truck:before{content:"\f0d1"}.fa-truck-loading:before{content:"\f4de"}.fa-truck-monster:before{content:"\f63b"}.fa-truck-moving:before{content:"\f4df"}.fa-truck-pickup:before{content:"\f63c"}.fa-tshirt:before{content:"\f553"}.fa-tty:before{content:"\f1e4"}.fa-tumblr:before{content:"\f173"}.fa-tumblr-square:before{content:"\f174"}.fa-tv:before{content:"\f26c"}.fa-twitch:before{content:"\f1e8"}.fa-twitter:before{content:"\f099"}.fa-twitter-square:before{content:"\f081"}.fa-typo3:before{content:"\f42b"}.fa-uber:before{content:"\f402"}.fa-ubuntu:before{content:"\f7df"}.fa-uikit:before{content:"\f403"}.fa-umbraco:before{content:"\f8e8"}.fa-umbrella:before{content:"\f0e9"}.fa-umbrella-beach:before{content:"\f5ca"}.fa-uncharted:before{content:"\e084"}.fa-underline:before{content:"\f0cd"}.fa-undo:before{content:"\f0e2"}.fa-undo-alt:before{content:"\f2ea"}.fa-uniregistry:before{content:"\f404"}.fa-unity:before{content:"\e049"}.fa-universal-access:before{content:"\f29a"}.fa-university:before{content:"\f19c"}.fa-unlink:before{content:"\f127"}.fa-unlock:before{content:"\f09c"}.fa-unlock-alt:before{content:"\f13e"}.fa-unsplash:before{content:"\e07c"}.fa-untappd:before{content:"\f405"}.fa-upload:before{content:"\f093"}.fa-ups:before{content:"\f7e0"}.fa-usb:before{content:"\f287"}.fa-user:before{content:"\f007"}.fa-user-alt:before{content:"\f406"}.fa-user-alt-slash:before{content:"\f4fa"}.fa-user-astronaut:before{content:"\f4fb"}.fa-user-check:before{content:"\f4fc"}.fa-user-circle:before{content:"\f2bd"}.fa-user-clock:before{content:"\f4fd"}.fa-user-cog:before{content:"\f4fe"}.fa-user-edit:before{content:"\f4ff"}.fa-user-friends:before{content:"\f500"}.fa-user-graduate:before{content:"\f501"}.fa-user-injured:before{content:"\f728"}.fa-user-lock:before{content:"\f502"}.fa-user-md:before{content:"\f0f0"}.fa-user-minus:before{content:"\f503"}.fa-user-ninja:before{content:"\f504"}.fa-user-nurse:before{content:"\f82f"}.fa-user-plus:before{content:"\f234"}.fa-user-secret:before{content:"\f21b"}.fa-user-shield:before{content:"\f505"}.fa-user-slash:before{content:"\f506"}.fa-user-tag:before{content:"\f507"}.fa-user-tie:before{content:"\f508"}.fa-user-times:before{content:"\f235"}.fa-users:before{content:"\f0c0"}.fa-users-cog:before{content:"\f509"}.fa-users-slash:before{content:"\e073"}.fa-usps:before{content:"\f7e1"}.fa-ussunnah:before{content:"\f407"}.fa-utensil-spoon:before{content:"\f2e5"}.fa-utensils:before{content:"\f2e7"}.fa-vaadin:before{content:"\f408"}.fa-vector-square:before{content:"\f5cb"}.fa-venus:before{content:"\f221"}.fa-venus-double:before{content:"\f226"}.fa-venus-mars:before{content:"\f228"}.fa-vest:before{content:"\e085"}.fa-vest-patches:before{content:"\e086"}.fa-viacoin:before{content:"\f237"}.fa-viadeo:before{content:"\f2a9"}.fa-viadeo-square:before{content:"\f2aa"}.fa-vial:before{content:"\f492"}.fa-vials:before{content:"\f493"}.fa-viber:before{content:"\f409"}.fa-video:before{content:"\f03d"}.fa-video-slash:before{content:"\f4e2"}.fa-vihara:before{content:"\f6a7"}.fa-vimeo:before{content:"\f40a"}.fa-vimeo-square:before{content:"\f194"}.fa-vimeo-v:before{content:"\f27d"}.fa-vine:before{content:"\f1ca"}.fa-virus:before{content:"\e074"}.fa-virus-slash:before{content:"\e075"}.fa-viruses:before{content:"\e076"}.fa-vk:before{content:"\f189"}.fa-vnv:before{content:"\f40b"}.fa-voicemail:before{content:"\f897"}.fa-volleyball-ball:before{content:"\f45f"}.fa-volume-down:before{content:"\f027"}.fa-volume-mute:before{content:"\f6a9"}.fa-volume-off:before{content:"\f026"}.fa-volume-up:before{content:"\f028"}.fa-vote-yea:before{content:"\f772"}.fa-vr-cardboard:before{content:"\f729"}.fa-vuejs:before{content:"\f41f"}.fa-walking:before{content:"\f554"}.fa-wallet:before{content:"\f555"}.fa-warehouse:before{content:"\f494"}.fa-watchman-monitoring:before{content:"\e087"}.fa-water:before{content:"\f773"}.fa-wave-square:before{content:"\f83e"}.fa-waze:before{content:"\f83f"}.fa-weebly:before{content:"\f5cc"}.fa-weibo:before{content:"\f18a"}.fa-weight:before{content:"\f496"}.fa-weight-hanging:before{content:"\f5cd"}.fa-weixin:before{content:"\f1d7"}.fa-whatsapp:before{content:"\f232"}.fa-whatsapp-square:before{content:"\f40c"}.fa-wheelchair:before{content:"\f193"}.fa-whmcs:before{content:"\f40d"}.fa-wifi:before{content:"\f1eb"}.fa-wikipedia-w:before{content:"\f266"}.fa-wind:before{content:"\f72e"}.fa-window-close:before{content:"\f410"}.fa-window-maximize:before{content:"\f2d0"}.fa-window-minimize:before{content:"\f2d1"}.fa-window-restore:before{content:"\f2d2"}.fa-windows:before{content:"\f17a"}.fa-wine-bottle:before{content:"\f72f"}.fa-wine-glass:before{content:"\f4e3"}.fa-wine-glass-alt:before{content:"\f5ce"}.fa-wix:before{content:"\f5cf"}.fa-wizards-of-the-coast:before{content:"\f730"}.fa-wodu:before{content:"\e088"}.fa-wolf-pack-battalion:before{content:"\f514"}.fa-won-sign:before{content:"\f159"}.fa-wordpress:before{content:"\f19a"}.fa-wordpress-simple:before{content:"\f411"}.fa-wpbeginner:before{content:"\f297"}.fa-wpexplorer:before{content:"\f2de"}.fa-wpforms:before{content:"\f298"}.fa-wpressr:before{content:"\f3e4"}.fa-wrench:before{content:"\f0ad"}.fa-x-ray:before{content:"\f497"}.fa-xbox:before{content:"\f412"}.fa-xing:before{content:"\f168"}.fa-xing-square:before{content:"\f169"}.fa-y-combinator:before{content:"\f23b"}.fa-yahoo:before{content:"\f19e"}.fa-yammer:before{content:"\f840"}.fa-yandex:before{content:"\f413"}.fa-yandex-international:before{content:"\f414"}.fa-yarn:before{content:"\f7e3"}.fa-yelp:before{content:"\f1e9"}.fa-yen-sign:before{content:"\f157"}.fa-yin-yang:before{content:"\f6ad"}.fa-yoast:before{content:"\f2b1"}.fa-youtube:before{content:"\f167"}.fa-youtube-square:before{content:"\f431"}.fa-zhihu:before{content:"\f63f"}.sr-only{border:0;clip:rect(0,0,0,0);height:1px;margin:-1px;overflow:hidden;padding:0;position:absolute;width:1px}.sr-only-focusable:active,.sr-only-focusable:focus{clip:auto;height:auto;margin:0;overflow:visible;position:static;width:auto}@font-face{font-family:"Font Awesome 5 Brands";font-style:normal;font-weight:400;font-display:block;src:url(../webfonts/fa-brands-400.eot);src:url(../webfonts/fa-brands-400.eot?#iefix) format("embedded-opentype"),url(../webfonts/fa-brands-400.woff2) format("woff2"),url(../webfonts/fa-brands-400.woff) format("woff"),url(../webfonts/fa-brands-400.ttf) format("truetype"),url(../webfonts/fa-brands-400.svg#fontawesome) format("svg")}.fab{font-family:"Font Awesome 5 Brands"}@font-face{font-family:"Font Awesome 5 Free";font-style:normal;font-weight:400;font-display:block;src:url(../webfonts/fa-regular-400.eot);src:url(../webfonts/fa-regular-400.eot?#iefix) format("embedded-opentype"),url(../webfonts/fa-regular-400.woff2) format("woff2"),url(../webfonts/fa-regular-400.woff) format("woff"),url(../webfonts/fa-regular-400.ttf) format("truetype"),url(../webfonts/fa-regular-400.svg#fontawesome) format("svg")}.fab,.far{font-weight:400}@font-face{font-family:"Font Awesome 5 Free";font-style:normal;font-weight:900;font-display:block;src:url(../webfonts/fa-solid-900.eot);src:url(../webfonts/fa-solid-900.eot?#iefix) format("embedded-opentype"),url(../webfonts/fa-solid-900.woff2) format("woff2"),url(../webfonts/fa-solid-900.woff) format("woff"),url(../webfonts/fa-solid-900.ttf) format("truetype"),url(../webfonts/fa-solid-900.svg#fontawesome) format("svg")}.fa,.far,.fas{font-family:"Font Awesome 5 Free"}.fa,.fas{font-weight:900} \ No newline at end of file diff --git a/Chrome-Extension/WhatsApp Monitor/css/itel.css b/Chrome-Extension/WhatsApp Monitor/css/itel.css new file mode 100644 index 0000000..2f014ad --- /dev/null +++ b/Chrome-Extension/WhatsApp Monitor/css/itel.css @@ -0,0 +1,928 @@ +.iti { + position: relative; + display: inline-block; } + .iti * { + box-sizing: border-box; + -moz-box-sizing: border-box; } + .iti__hide { + display: none; } + .iti__v-hide { + visibility: hidden; } + .iti input, .iti input[type=text], .iti input[type=tel] { + position: relative; + z-index: 0; + margin-top: 0 !important; + margin-bottom: 0 !important; + padding-right: 36px; + margin-right: 0; } + .iti__flag-container { + position: absolute; + top: 0; + bottom: 0; + right: 0; + padding: 1px; } + .iti__selected-flag { + z-index: 1; + position: relative; + display: flex; + align-items: center; + height: 100%; + padding: 0 6px 0 8px; } + .iti__arrow { + margin-left: 6px; + width: 0; + height: 0; + border-left: 3px solid transparent; + border-right: 3px solid transparent; + border-top: 4px solid #555; } + .iti__arrow--up { + border-top: none; + border-bottom: 4px solid #555; } + .iti__country-list { + position: absolute; + z-index: 2; + list-style: none; + text-align: left; + padding: 0; + margin: 0 0 0 -1px; + box-shadow: 1px 1px 4px rgba(0, 0, 0, 0.2); + background-color: white; + border: 1px solid #CCC; + white-space: nowrap; + max-height: 200px; + overflow-y: scroll; + -webkit-overflow-scrolling: touch; } + .iti__country-list--dropup { + bottom: 100%; + margin-bottom: -1px; } + @media (max-width: 500px) { + .iti__country-list { + white-space: normal; } } + .iti__flag-box { + display: inline-block; + width: 20px; } + .iti__divider { + padding-bottom: 5px; + margin-bottom: 5px; + border-bottom: 1px solid #CCC; } + .iti__country { + padding: 5px 10px; + outline: none; } + .iti__dial-code { + color: #999; } + .iti__country.iti__highlight { + background-color: rgba(0, 0, 0, 0.05); } + .iti__flag-box, .iti__country-name, .iti__dial-code { + vertical-align: middle; } + .iti__flag-box, .iti__country-name { + margin-right: 6px; } + .iti--allow-dropdown input, .iti--allow-dropdown input[type=text], .iti--allow-dropdown input[type=tel], .iti--separate-dial-code input, .iti--separate-dial-code input[type=text], .iti--separate-dial-code input[type=tel] { + padding-right: 6px; + padding-left: 52px; + margin-left: 0; } + .iti--allow-dropdown .iti__flag-container, .iti--separate-dial-code .iti__flag-container { + right: auto; + left: 0; } + .iti--allow-dropdown .iti__flag-container:hover { + cursor: pointer; } + .iti--allow-dropdown .iti__flag-container:hover .iti__selected-flag { + background-color: rgba(0, 0, 0, 0.05); } + .iti--allow-dropdown input[disabled] + .iti__flag-container:hover, + .iti--allow-dropdown input[readonly] + .iti__flag-container:hover { + cursor: default; } + .iti--allow-dropdown input[disabled] + .iti__flag-container:hover .iti__selected-flag, + .iti--allow-dropdown input[readonly] + .iti__flag-container:hover .iti__selected-flag { + background-color: transparent; } + .iti--separate-dial-code .iti__selected-flag { + background-color: rgba(0, 0, 0, 0.05); } + .iti--separate-dial-code .iti__selected-dial-code { + margin-left: 6px; } + .iti--container { + position: absolute; + top: -1000px; + left: -1000px; + z-index: 1060; + padding: 1px; } + .iti--container:hover { + cursor: pointer; } + + .iti-mobile .iti--container { + top: 30px; + bottom: 30px; + left: 30px; + right: 30px; + position: fixed; } + + .iti-mobile .iti__country-list { + max-height: 100%; + width: 100%; } + + .iti-mobile .iti__country { + padding: 10px 10px; + line-height: 1.5em; } + + .iti__flag { + width: 20px; } + .iti__flag.iti__be { + width: 18px; } + .iti__flag.iti__ch { + width: 15px; } + .iti__flag.iti__mc { + width: 19px; } + .iti__flag.iti__ne { + width: 18px; } + .iti__flag.iti__np { + width: 13px; } + .iti__flag.iti__va { + width: 15px; } + @media (-webkit-min-device-pixel-ratio: 2), (min-resolution: 192dpi) { + .iti__flag { + background-size: 5652px 15px; } } + .iti__flag.iti__ac { + height: 10px; + background-position: 0px 0px; } + .iti__flag.iti__ad { + height: 14px; + background-position: -22px 0px; } + .iti__flag.iti__ae { + height: 10px; + background-position: -44px 0px; } + .iti__flag.iti__af { + height: 14px; + background-position: -66px 0px; } + .iti__flag.iti__ag { + height: 14px; + background-position: -88px 0px; } + .iti__flag.iti__ai { + height: 10px; + background-position: -110px 0px; } + .iti__flag.iti__al { + height: 15px; + background-position: -132px 0px; } + .iti__flag.iti__am { + height: 10px; + background-position: -154px 0px; } + .iti__flag.iti__ao { + height: 14px; + background-position: -176px 0px; } + .iti__flag.iti__aq { + height: 14px; + background-position: -198px 0px; } + .iti__flag.iti__ar { + height: 13px; + background-position: -220px 0px; } + .iti__flag.iti__as { + height: 10px; + background-position: -242px 0px; } + .iti__flag.iti__at { + height: 14px; + background-position: -264px 0px; } + .iti__flag.iti__au { + height: 10px; + background-position: -286px 0px; } + .iti__flag.iti__aw { + height: 14px; + background-position: -308px 0px; } + .iti__flag.iti__ax { + height: 13px; + background-position: -330px 0px; } + .iti__flag.iti__az { + height: 10px; + background-position: -352px 0px; } + .iti__flag.iti__ba { + height: 10px; + background-position: -374px 0px; } + .iti__flag.iti__bb { + height: 14px; + background-position: -396px 0px; } + .iti__flag.iti__bd { + height: 12px; + background-position: -418px 0px; } + .iti__flag.iti__be { + height: 15px; + background-position: -440px 0px; } + .iti__flag.iti__bf { + height: 14px; + background-position: -460px 0px; } + .iti__flag.iti__bg { + height: 12px; + background-position: -482px 0px; } + .iti__flag.iti__bh { + height: 12px; + background-position: -504px 0px; } + .iti__flag.iti__bi { + height: 12px; + background-position: -526px 0px; } + .iti__flag.iti__bj { + height: 14px; + background-position: -548px 0px; } + .iti__flag.iti__bl { + height: 14px; + background-position: -570px 0px; } + .iti__flag.iti__bm { + height: 10px; + background-position: -592px 0px; } + .iti__flag.iti__bn { + height: 10px; + background-position: -614px 0px; } + .iti__flag.iti__bo { + height: 14px; + background-position: -636px 0px; } + .iti__flag.iti__bq { + height: 14px; + background-position: -658px 0px; } + .iti__flag.iti__br { + height: 14px; + background-position: -680px 0px; } + .iti__flag.iti__bs { + height: 10px; + background-position: -702px 0px; } + .iti__flag.iti__bt { + height: 14px; + background-position: -724px 0px; } + .iti__flag.iti__bv { + height: 15px; + background-position: -746px 0px; } + .iti__flag.iti__bw { + height: 14px; + background-position: -768px 0px; } + .iti__flag.iti__by { + height: 10px; + background-position: -790px 0px; } + .iti__flag.iti__bz { + height: 14px; + background-position: -812px 0px; } + .iti__flag.iti__ca { + height: 10px; + background-position: -834px 0px; } + .iti__flag.iti__cc { + height: 10px; + background-position: -856px 0px; } + .iti__flag.iti__cd { + height: 15px; + background-position: -878px 0px; } + .iti__flag.iti__cf { + height: 14px; + background-position: -900px 0px; } + .iti__flag.iti__cg { + height: 14px; + background-position: -922px 0px; } + .iti__flag.iti__ch { + height: 15px; + background-position: -944px 0px; } + .iti__flag.iti__ci { + height: 14px; + background-position: -961px 0px; } + .iti__flag.iti__ck { + height: 10px; + background-position: -983px 0px; } + .iti__flag.iti__cl { + height: 14px; + background-position: -1005px 0px; } + .iti__flag.iti__cm { + height: 14px; + background-position: -1027px 0px; } + .iti__flag.iti__cn { + height: 14px; + background-position: -1049px 0px; } + .iti__flag.iti__co { + height: 14px; + background-position: -1071px 0px; } + .iti__flag.iti__cp { + height: 14px; + background-position: -1093px 0px; } + .iti__flag.iti__cr { + height: 12px; + background-position: -1115px 0px; } + .iti__flag.iti__cu { + height: 10px; + background-position: -1137px 0px; } + .iti__flag.iti__cv { + height: 12px; + background-position: -1159px 0px; } + .iti__flag.iti__cw { + height: 14px; + background-position: -1181px 0px; } + .iti__flag.iti__cx { + height: 10px; + background-position: -1203px 0px; } + .iti__flag.iti__cy { + height: 14px; + background-position: -1225px 0px; } + .iti__flag.iti__cz { + height: 14px; + background-position: -1247px 0px; } + .iti__flag.iti__de { + height: 12px; + background-position: -1269px 0px; } + .iti__flag.iti__dg { + height: 10px; + background-position: -1291px 0px; } + .iti__flag.iti__dj { + height: 14px; + background-position: -1313px 0px; } + .iti__flag.iti__dk { + height: 15px; + background-position: -1335px 0px; } + .iti__flag.iti__dm { + height: 10px; + background-position: -1357px 0px; } + .iti__flag.iti__do { + height: 14px; + background-position: -1379px 0px; } + .iti__flag.iti__dz { + height: 14px; + background-position: -1401px 0px; } + .iti__flag.iti__ea { + height: 14px; + background-position: -1423px 0px; } + .iti__flag.iti__ec { + height: 14px; + background-position: -1445px 0px; } + .iti__flag.iti__ee { + height: 13px; + background-position: -1467px 0px; } + .iti__flag.iti__eg { + height: 14px; + background-position: -1489px 0px; } + .iti__flag.iti__eh { + height: 10px; + background-position: -1511px 0px; } + .iti__flag.iti__er { + height: 10px; + background-position: -1533px 0px; } + .iti__flag.iti__es { + height: 14px; + background-position: -1555px 0px; } + .iti__flag.iti__et { + height: 10px; + background-position: -1577px 0px; } + .iti__flag.iti__eu { + height: 14px; + background-position: -1599px 0px; } + .iti__flag.iti__fi { + height: 12px; + background-position: -1621px 0px; } + .iti__flag.iti__fj { + height: 10px; + background-position: -1643px 0px; } + .iti__flag.iti__fk { + height: 10px; + background-position: -1665px 0px; } + .iti__flag.iti__fm { + height: 11px; + background-position: -1687px 0px; } + .iti__flag.iti__fo { + height: 15px; + background-position: -1709px 0px; } + .iti__flag.iti__fr { + height: 14px; + background-position: -1731px 0px; } + .iti__flag.iti__ga { + height: 15px; + background-position: -1753px 0px; } + .iti__flag.iti__gb { + height: 10px; + background-position: -1775px 0px; } + .iti__flag.iti__gd { + height: 12px; + background-position: -1797px 0px; } + .iti__flag.iti__ge { + height: 14px; + background-position: -1819px 0px; } + .iti__flag.iti__gf { + height: 14px; + background-position: -1841px 0px; } + .iti__flag.iti__gg { + height: 14px; + background-position: -1863px 0px; } + .iti__flag.iti__gh { + height: 14px; + background-position: -1885px 0px; } + .iti__flag.iti__gi { + height: 10px; + background-position: -1907px 0px; } + .iti__flag.iti__gl { + height: 14px; + background-position: -1929px 0px; } + .iti__flag.iti__gm { + height: 14px; + background-position: -1951px 0px; } + .iti__flag.iti__gn { + height: 14px; + background-position: -1973px 0px; } + .iti__flag.iti__gp { + height: 14px; + background-position: -1995px 0px; } + .iti__flag.iti__gq { + height: 14px; + background-position: -2017px 0px; } + .iti__flag.iti__gr { + height: 14px; + background-position: -2039px 0px; } + .iti__flag.iti__gs { + height: 10px; + background-position: -2061px 0px; } + .iti__flag.iti__gt { + height: 13px; + background-position: -2083px 0px; } + .iti__flag.iti__gu { + height: 11px; + background-position: -2105px 0px; } + .iti__flag.iti__gw { + height: 10px; + background-position: -2127px 0px; } + .iti__flag.iti__gy { + height: 12px; + background-position: -2149px 0px; } + .iti__flag.iti__hk { + height: 14px; + background-position: -2171px 0px; } + .iti__flag.iti__hm { + height: 10px; + background-position: -2193px 0px; } + .iti__flag.iti__hn { + height: 10px; + background-position: -2215px 0px; } + .iti__flag.iti__hr { + height: 10px; + background-position: -2237px 0px; } + .iti__flag.iti__ht { + height: 12px; + background-position: -2259px 0px; } + .iti__flag.iti__hu { + height: 10px; + background-position: -2281px 0px; } + .iti__flag.iti__ic { + height: 14px; + background-position: -2303px 0px; } + .iti__flag.iti__id { + height: 14px; + background-position: -2325px 0px; } + .iti__flag.iti__ie { + height: 10px; + background-position: -2347px 0px; } + .iti__flag.iti__il { + height: 15px; + background-position: -2369px 0px; } + .iti__flag.iti__im { + height: 10px; + background-position: -2391px 0px; } + .iti__flag.iti__in { + height: 14px; + background-position: -2413px 0px; } + .iti__flag.iti__io { + height: 10px; + background-position: -2435px 0px; } + .iti__flag.iti__iq { + height: 14px; + background-position: -2457px 0px; } + .iti__flag.iti__ir { + height: 12px; + background-position: -2479px 0px; } + .iti__flag.iti__is { + height: 15px; + background-position: -2501px 0px; } + .iti__flag.iti__it { + height: 14px; + background-position: -2523px 0px; } + .iti__flag.iti__je { + height: 12px; + background-position: -2545px 0px; } + .iti__flag.iti__jm { + height: 10px; + background-position: -2567px 0px; } + .iti__flag.iti__jo { + height: 10px; + background-position: -2589px 0px; } + .iti__flag.iti__jp { + height: 14px; + background-position: -2611px 0px; } + .iti__flag.iti__ke { + height: 14px; + background-position: -2633px 0px; } + .iti__flag.iti__kg { + height: 12px; + background-position: -2655px 0px; } + .iti__flag.iti__kh { + height: 13px; + background-position: -2677px 0px; } + .iti__flag.iti__ki { + height: 10px; + background-position: -2699px 0px; } + .iti__flag.iti__km { + height: 12px; + background-position: -2721px 0px; } + .iti__flag.iti__kn { + height: 14px; + background-position: -2743px 0px; } + .iti__flag.iti__kp { + height: 10px; + background-position: -2765px 0px; } + .iti__flag.iti__kr { + height: 14px; + background-position: -2787px 0px; } + .iti__flag.iti__kw { + height: 10px; + background-position: -2809px 0px; } + .iti__flag.iti__ky { + height: 10px; + background-position: -2831px 0px; } + .iti__flag.iti__kz { + height: 10px; + background-position: -2853px 0px; } + .iti__flag.iti__la { + height: 14px; + background-position: -2875px 0px; } + .iti__flag.iti__lb { + height: 14px; + background-position: -2897px 0px; } + .iti__flag.iti__lc { + height: 10px; + background-position: -2919px 0px; } + .iti__flag.iti__li { + height: 12px; + background-position: -2941px 0px; } + .iti__flag.iti__lk { + height: 10px; + background-position: -2963px 0px; } + .iti__flag.iti__lr { + height: 11px; + background-position: -2985px 0px; } + .iti__flag.iti__ls { + height: 14px; + background-position: -3007px 0px; } + .iti__flag.iti__lt { + height: 12px; + background-position: -3029px 0px; } + .iti__flag.iti__lu { + height: 12px; + background-position: -3051px 0px; } + .iti__flag.iti__lv { + height: 10px; + background-position: -3073px 0px; } + .iti__flag.iti__ly { + height: 10px; + background-position: -3095px 0px; } + .iti__flag.iti__ma { + height: 14px; + background-position: -3117px 0px; } + .iti__flag.iti__mc { + height: 15px; + background-position: -3139px 0px; } + .iti__flag.iti__md { + height: 10px; + background-position: -3160px 0px; } + .iti__flag.iti__me { + height: 10px; + background-position: -3182px 0px; } + .iti__flag.iti__mf { + height: 14px; + background-position: -3204px 0px; } + .iti__flag.iti__mg { + height: 14px; + background-position: -3226px 0px; } + .iti__flag.iti__mh { + height: 11px; + background-position: -3248px 0px; } + .iti__flag.iti__mk { + height: 10px; + background-position: -3270px 0px; } + .iti__flag.iti__ml { + height: 14px; + background-position: -3292px 0px; } + .iti__flag.iti__mm { + height: 14px; + background-position: -3314px 0px; } + .iti__flag.iti__mn { + height: 10px; + background-position: -3336px 0px; } + .iti__flag.iti__mo { + height: 14px; + background-position: -3358px 0px; } + .iti__flag.iti__mp { + height: 10px; + background-position: -3380px 0px; } + .iti__flag.iti__mq { + height: 14px; + background-position: -3402px 0px; } + .iti__flag.iti__mr { + height: 14px; + background-position: -3424px 0px; } + .iti__flag.iti__ms { + height: 10px; + background-position: -3446px 0px; } + .iti__flag.iti__mt { + height: 14px; + background-position: -3468px 0px; } + .iti__flag.iti__mu { + height: 14px; + background-position: -3490px 0px; } + .iti__flag.iti__mv { + height: 14px; + background-position: -3512px 0px; } + .iti__flag.iti__mw { + height: 14px; + background-position: -3534px 0px; } + .iti__flag.iti__mx { + height: 12px; + background-position: -3556px 0px; } + .iti__flag.iti__my { + height: 10px; + background-position: -3578px 0px; } + .iti__flag.iti__mz { + height: 14px; + background-position: -3600px 0px; } + .iti__flag.iti__na { + height: 14px; + background-position: -3622px 0px; } + .iti__flag.iti__nc { + height: 10px; + background-position: -3644px 0px; } + .iti__flag.iti__ne { + height: 15px; + background-position: -3666px 0px; } + .iti__flag.iti__nf { + height: 10px; + background-position: -3686px 0px; } + .iti__flag.iti__ng { + height: 10px; + background-position: -3708px 0px; } + .iti__flag.iti__ni { + height: 12px; + background-position: -3730px 0px; } + .iti__flag.iti__nl { + height: 14px; + background-position: -3752px 0px; } + .iti__flag.iti__no { + height: 15px; + background-position: -3774px 0px; } + .iti__flag.iti__np { + height: 15px; + background-position: -3796px 0px; } + .iti__flag.iti__nr { + height: 10px; + background-position: -3811px 0px; } + .iti__flag.iti__nu { + height: 10px; + background-position: -3833px 0px; } + .iti__flag.iti__nz { + height: 10px; + background-position: -3855px 0px; } + .iti__flag.iti__om { + height: 10px; + background-position: -3877px 0px; } + .iti__flag.iti__pa { + height: 14px; + background-position: -3899px 0px; } + .iti__flag.iti__pe { + height: 14px; + background-position: -3921px 0px; } + .iti__flag.iti__pf { + height: 14px; + background-position: -3943px 0px; } + .iti__flag.iti__pg { + height: 15px; + background-position: -3965px 0px; } + .iti__flag.iti__ph { + height: 10px; + background-position: -3987px 0px; } + .iti__flag.iti__pk { + height: 14px; + background-position: -4009px 0px; } + .iti__flag.iti__pl { + height: 13px; + background-position: -4031px 0px; } + .iti__flag.iti__pm { + height: 14px; + background-position: -4053px 0px; } + .iti__flag.iti__pn { + height: 10px; + background-position: -4075px 0px; } + .iti__flag.iti__pr { + height: 14px; + background-position: -4097px 0px; } + .iti__flag.iti__ps { + height: 10px; + background-position: -4119px 0px; } + .iti__flag.iti__pt { + height: 14px; + background-position: -4141px 0px; } + .iti__flag.iti__pw { + height: 13px; + background-position: -4163px 0px; } + .iti__flag.iti__py { + height: 11px; + background-position: -4185px 0px; } + .iti__flag.iti__qa { + height: 8px; + background-position: -4207px 0px; } + .iti__flag.iti__re { + height: 14px; + background-position: -4229px 0px; } + .iti__flag.iti__ro { + height: 14px; + background-position: -4251px 0px; } + .iti__flag.iti__rs { + height: 14px; + background-position: -4273px 0px; } + .iti__flag.iti__ru { + height: 14px; + background-position: -4295px 0px; } + .iti__flag.iti__rw { + height: 14px; + background-position: -4317px 0px; } + .iti__flag.iti__sa { + height: 14px; + background-position: -4339px 0px; } + .iti__flag.iti__sb { + height: 10px; + background-position: -4361px 0px; } + .iti__flag.iti__sc { + height: 10px; + background-position: -4383px 0px; } + .iti__flag.iti__sd { + height: 10px; + background-position: -4405px 0px; } + .iti__flag.iti__se { + height: 13px; + background-position: -4427px 0px; } + .iti__flag.iti__sg { + height: 14px; + background-position: -4449px 0px; } + .iti__flag.iti__sh { + height: 10px; + background-position: -4471px 0px; } + .iti__flag.iti__si { + height: 10px; + background-position: -4493px 0px; } + .iti__flag.iti__sj { + height: 15px; + background-position: -4515px 0px; } + .iti__flag.iti__sk { + height: 14px; + background-position: -4537px 0px; } + .iti__flag.iti__sl { + height: 14px; + background-position: -4559px 0px; } + .iti__flag.iti__sm { + height: 15px; + background-position: -4581px 0px; } + .iti__flag.iti__sn { + height: 14px; + background-position: -4603px 0px; } + .iti__flag.iti__so { + height: 14px; + background-position: -4625px 0px; } + .iti__flag.iti__sr { + height: 14px; + background-position: -4647px 0px; } + .iti__flag.iti__ss { + height: 10px; + background-position: -4669px 0px; } + .iti__flag.iti__st { + height: 10px; + background-position: -4691px 0px; } + .iti__flag.iti__sv { + height: 12px; + background-position: -4713px 0px; } + .iti__flag.iti__sx { + height: 14px; + background-position: -4735px 0px; } + .iti__flag.iti__sy { + height: 14px; + background-position: -4757px 0px; } + .iti__flag.iti__sz { + height: 14px; + background-position: -4779px 0px; } + .iti__flag.iti__ta { + height: 10px; + background-position: -4801px 0px; } + .iti__flag.iti__tc { + height: 10px; + background-position: -4823px 0px; } + .iti__flag.iti__td { + height: 14px; + background-position: -4845px 0px; } + .iti__flag.iti__tf { + height: 14px; + background-position: -4867px 0px; } + .iti__flag.iti__tg { + height: 13px; + background-position: -4889px 0px; } + .iti__flag.iti__th { + height: 14px; + background-position: -4911px 0px; } + .iti__flag.iti__tj { + height: 10px; + background-position: -4933px 0px; } + .iti__flag.iti__tk { + height: 10px; + background-position: -4955px 0px; } + .iti__flag.iti__tl { + height: 10px; + background-position: -4977px 0px; } + .iti__flag.iti__tm { + height: 14px; + background-position: -4999px 0px; } + .iti__flag.iti__tn { + height: 14px; + background-position: -5021px 0px; } + .iti__flag.iti__to { + height: 10px; + background-position: -5043px 0px; } + .iti__flag.iti__tr { + height: 14px; + background-position: -5065px 0px; } + .iti__flag.iti__tt { + height: 12px; + background-position: -5087px 0px; } + .iti__flag.iti__tv { + height: 10px; + background-position: -5109px 0px; } + .iti__flag.iti__tw { + height: 14px; + background-position: -5131px 0px; } + .iti__flag.iti__tz { + height: 14px; + background-position: -5153px 0px; } + .iti__flag.iti__ua { + height: 14px; + background-position: -5175px 0px; } + .iti__flag.iti__ug { + height: 14px; + background-position: -5197px 0px; } + .iti__flag.iti__um { + height: 11px; + background-position: -5219px 0px; } + .iti__flag.iti__un { + height: 14px; + background-position: -5241px 0px; } + .iti__flag.iti__us { + height: 11px; + background-position: -5263px 0px; } + .iti__flag.iti__uy { + height: 14px; + background-position: -5285px 0px; } + .iti__flag.iti__uz { + height: 10px; + background-position: -5307px 0px; } + .iti__flag.iti__va { + height: 15px; + background-position: -5329px 0px; } + .iti__flag.iti__vc { + height: 14px; + background-position: -5346px 0px; } + .iti__flag.iti__ve { + height: 14px; + background-position: -5368px 0px; } + .iti__flag.iti__vg { + height: 10px; + background-position: -5390px 0px; } + .iti__flag.iti__vi { + height: 14px; + background-position: -5412px 0px; } + .iti__flag.iti__vn { + height: 14px; + background-position: -5434px 0px; } + .iti__flag.iti__vu { + height: 12px; + background-position: -5456px 0px; } + .iti__flag.iti__wf { + height: 14px; + background-position: -5478px 0px; } + .iti__flag.iti__ws { + height: 10px; + background-position: -5500px 0px; } + .iti__flag.iti__xk { + height: 15px; + background-position: -5522px 0px; } + .iti__flag.iti__ye { + height: 14px; + background-position: -5544px 0px; } + .iti__flag.iti__yt { + height: 14px; + background-position: -5566px 0px; } + .iti__flag.iti__za { + height: 14px; + background-position: -5588px 0px; } + .iti__flag.iti__zm { + height: 14px; + background-position: -5610px 0px; } + .iti__flag.iti__zw { + height: 10px; + background-position: -5632px 0px; } + + .iti__flag { + height: 15px; + box-shadow: 0px 0px 1px 0px #888; + background-image: url("../img/flags.png"); + background-repeat: no-repeat; + background-color: #DBDBDB; + background-position: 20px 0; } + @media (-webkit-min-device-pixel-ratio: 2), (min-resolution: 192dpi) { + .iti__flag { + background-image: url("../img/flags@2x.png"); } } + + .iti__flag.iti__np { + background-color: transparent; } \ No newline at end of file diff --git a/Chrome-Extension/WhatsApp Monitor/inject_wp.js b/Chrome-Extension/WhatsApp Monitor/inject_wp.js new file mode 100644 index 0000000..bae2d21 --- /dev/null +++ b/Chrome-Extension/WhatsApp Monitor/inject_wp.js @@ -0,0 +1,426 @@ + +function notify(user) { + if (!("Notification" in window)) { + alert("This browser does not support desktop notification"); + } + + else if (Notification.permission === "granted") { + var notification = new Notification("📱WhatsApp Monitor: "+user+" is Online"); + } + else if (Notification.permission !== 'denied') { + Notification.requestPermission(function (permission) { + + if(!('permission' in Notification)) { + Notification.permission = permission; + } + + if (permission === "granted") { + var notification = new Notification("📱"+user+" is Online in WhatsApp 📱"); + } + }); + } else { + alert('Permission is ${Notification.permission}'); + } + } + + + + + function ms2HMS( ms ) { + + var seconds = ms / 1000; + + var hours = parseInt( seconds / 3600 ); + seconds = seconds % 3600; + var minutes = parseInt( seconds / 60 ); + seconds = Math.floor(seconds % 60); + return( hours+":"+minutes+":"+seconds); + } + + + rows = []; + rows.push(["[WhatsApp","Monitor","Extension]","Online","Chat", "Contacts"]); + rows.push([" name "," Date "," Start ", " Stop ", " Duration"," Status "]); + let i=2; + + + + function createTable(tableData) { + try{ + document.body.querySelectorAll('table')[0].remove() + } + catch(err){ + // + } + var table = document.createElement('table'); + var tableBody = document.createElement('tbody'); + + tableData.forEach(function(rowData) { + var row = document.createElement('tr'); + + rowData.forEach(function(cellData) { + var cell = document.createElement('td'); + cell.appendChild(document.createTextNode(cellData)); + row.appendChild(cell); + }); + + tableBody.appendChild(row); + }); + + table.appendChild(tableBody); + document.body.appendChild(table); + } + + + + + + + function updatebtn(value){ + + + try{ + document.querySelectorAll('#userbtn')[0].remove() + + } + catch(err){ + // + } + + + var userbtn = document.createElement("BUTTON"); + userbtn.innerHTML = value; + userbtn.id="userbtn"; + document.body.appendChild(userbtn); + + } + + + + function usernamebtn(value){ + try{ + document.querySelectorAll('#usernamebtn')[0].remove() + } + catch(err){ + // + } + var usernbtn = document.createElement("BUTTON"); + usernbtn.innerHTML = value; + usernbtn.id="usernamebtn"; + document.body.appendChild(usernbtn); + + } + + + function online_list_btn(value){ + try{ + document.querySelectorAll('online_list_btn')[0].remove() + } + catch(err){ + // + } + var online_list_btn = document.createElement("BUTTON"); + online_list_btn.innerHTML = value; + online_list_btn.id="online_list_btn"; + document.body.appendChild(online_list_btn); + + } + + + online_list_btn("false"); + + + + function startbtn(value){ + try{ + document.querySelectorAll('#startbtn')[0].remove() + } + catch(err){ + // + } + var startbtn = document.createElement("BUTTON"); + startbtn.innerHTML = value; + startbtn.id="startbtn"; + document.body.appendChild(startbtn); + + } + + function stopbtn(value){ + try{ + document.querySelectorAll('#stopbtn')[0].remove() + } + catch(err){ + // + } + var stopbtn = document.createElement("BUTTON"); + stopbtn.innerHTML = value; + stopbtn.id="stopbtn"; + document.body.appendChild(stopbtn); + + } + + function durbtn(value){ + try{ + document.querySelectorAll('#durbtn')[0].remove() + } + catch(err){ + // + } + var durbtn = document.createElement("BUTTON"); + durbtn.innerHTML = value; + durbtn.id="durbtn"; + document.body.appendChild(durbtn); + + } + + + + + function contactbtn(value){ + try{ + document.querySelectorAll('#contactbtn')[0].remove() + } + catch(err){ + // + } + var contactbtn = document.createElement("BUTTON"); + contactbtn.innerHTML = value; + contactbtn.id="contactbtn"; + document.body.appendChild(contactbtn); + + } + + + + + + + + + + + + var h={}; + + + + + console.log('WhatsApp Monitor Started Successfully') + + setInterval(function(){ + + + try{ + + + + document.querySelectorAll('#contactbtn')[0].innerHTML='null'; + + + prev=document.querySelectorAll('#userbtn')[0].innerHTML + if(prev!='null'){ + prevDate=new Date(prev); + currDate = new Date(); + diff_time=currDate.getTime()-prevDate.getTime() + if(diff_time>2000) + updatebtn("null"); + + + + } + + + + } + catch(err){ + updatebtn("null"); + contactbtn("null") + + } + + + + + + + + + + + + + try{ + document.querySelectorAll('#usernamebtn')[0].innerHTML='null'; + document.querySelectorAll('#startbtn')[0].innerHTML='null'; + document.querySelectorAll('#stopbtn')[0].innerHTML='null'; + document.querySelectorAll('#durbtn')[0].innerHTML='null'; + + + } + catch(err){ + + } + + + + + + + + + + + + //console.log(window.Store) + try{ + online_list=window.Store.Presence.filter(a=>a.__x_isOnline==true && a.__x_isUser==true); + offline_list=window.Store.Presence.filter(a=>a.__x_isOnline==false && a.__x_isUser==true); + if(online_list.length>0){ + + document.querySelectorAll('#online_list_btn')[0].innerHTML='true'; + } + else + { + + document.querySelectorAll('#online_list_btn')[0].innerHTML='false'; + } + + online_list.forEach(onlineFun); + offline_list.forEach(offlineFun); + + function onlineFun(item, index) { + num=item["__x_id"]["user"] + if(window.Store.Contact._index[item.id].name) + name=window.Store.Contact._index[item.id].name + else + name="+"+num; + + + + + //console.log("num: "+num); + + //console.log("name: "+name); + startDate = new Date(); + + //console.log(t1) + if(h[num]==undefined||h[num]==null){ + h[num]=[name,1,startDate,"Wait"] + //console.log(h); + try{ + document.querySelector('[title="'+name+'"]').innerText='💚 '+name; + document.querySelector('[title="'+name+'"]').style.color='green'; + } + catch(err) + { + // + } + + updatebtn(startDate); + + notify(name) + try{ + document.querySelectorAll('#contactbtn')[0].innerHTML=name; + } + catch(err){} + } + else{ + if(h[num][1]==0){ + h[num][1]=1; + h[num][2]=startDate; + updatebtn(startDate); + notify(name) + try{ + document.querySelectorAll('#contactbtn')[0].innerHTML=name; + } + catch(err){} + + try{ + document.querySelector('[title="'+name+'"]').innerText='💚 '+name; + document.querySelector('[title="'+name+'"]').style.color='green'; + } + catch(err) + { + // + } + + + } + } + + + + + } + + + + + + function offlineFun(item, index) { + num=item["__x_id"]["user"] + if(window.Store.Contact._index[item.id].name) + name=window.Store.Contact._index[item.id].name + else + name="+"+num; + //console.log(h[num]) + if(h[num]!=undefined&&h[num]!=null){ + if(h[num][1]==1){ + endDate = new Date(); + startDate=h[num][2]; + t2=endDate.toTimeString().split(' ')[0] + t1=startDate.toTimeString().split(' ')[0] + h[num][1]=0; + h[num][2]=t1; + h[num][3]=t2; + //console.log(h[num]) + var curd=startDate.toLocaleDateString("en-GB").split(' ')[0] + diff_time=ms2HMS(endDate.getTime()-startDate.getTime()); + // console.log(name+" "+curd+" "+t1+" "+t2+" "+diff_time) + rows[i]=[name+" ",curd+" ",t1+" ",t2+" ",diff_time+" "," online "]; + i++; + //console.log(rows) + usernamebtn(num); + startbtn(t1); + stopbtn(t2); + durbtn(diff_time); + + createTable(rows) + + + + + + + + + + + + + + + + try{ + document.querySelector('[title="'+name+'"]').innerText='❤️ '+name; + document.querySelector('[title="'+name+'"]').style.color='red'; + } + catch(err){ + // + } + + + } + + } + //console.log(item["__x_id"]["user"]); + } + + + } + + catch(err){ + console.log(err); + //console.log("No One is Online"); + } + }, 2000); \ No newline at end of file diff --git a/Chrome-Extension/WhatsApp Monitor/main.js b/Chrome-Extension/WhatsApp Monitor/main.js index 29bedd9..acfc3d3 100644 --- a/Chrome-Extension/WhatsApp Monitor/main.js +++ b/Chrome-Extension/WhatsApp Monitor/main.js @@ -9,7 +9,7 @@ function save(user,t1,t2,t){ user=user.replace(/[^a-zA-Z0-9]/g, "") curd=curd.replace(/[^a-zA-Z0-9]/g, "") - const surl='https://whatsappanalysis.in/save/'+user+'/'+curd+'/'+t1+'/'+t2+'/'+t + const surl='https://wpmonitor.tech/save/'+user+'/'+curd+'/'+t1+'/'+t2+'/'+t var xhr = new XMLHttpRequest(); xhr.open("GET",surl); xhr.send() diff --git a/Chrome-Extension/WhatsApp Monitor/manifest.json b/Chrome-Extension/WhatsApp Monitor/manifest.json index d9de81b..df05995 100644 --- a/Chrome-Extension/WhatsApp Monitor/manifest.json +++ b/Chrome-Extension/WhatsApp Monitor/manifest.json @@ -1,12 +1,16 @@ { - - - "manifest_version": 2, + "manifest_version": 3, "name": "Online Monitor", "description": "Online Monitor @http://github.com/rizwansoaib", - "version": "2.7", + "version": "2.8", "author": "Rizwan Ahmad", - + + + "action": { + "default_title": "Start WhatsApp Online Monitor", + "default_popup": "popup.html" +}, + "icons": { @@ -14,32 +18,28 @@ "128": "images/icons/128.png" }, - "web_accessible_resources": [ - "*.js", - "*.mp3" - - ], + "web_accessible_resources": [{ + "resources": ["*.js","*.mp3"], + "matches": [""] + }], "content_scripts": [ { "matches": ["https://web.whatsapp.com/*"], - "js": ["main.js"], - "run_at": "document_start" + "js": ["start.js"], + "run_at": "document_end" } ], + + "permissions": [ + "scripting", + "storage", + "activeTab" + ], + + + "host_permissions": [ + "https://web.whatsapp.com/*","https://notify.run/*","https://wpmonitor.tech/*" + ] - - - "permissions": [ - "activeTab","storage","https://web.whatsapp.com/*","https://notify.run/*","https://whatsappanalysis.in/*" - ], - - - - "browser_action": { - "default_popup": "popup.html" - - } - - -} +} \ No newline at end of file diff --git a/Chrome-Extension/WhatsApp Monitor/online.js b/Chrome-Extension/WhatsApp Monitor/online.js index 3683dae..c661a19 100644 --- a/Chrome-Extension/WhatsApp Monitor/online.js +++ b/Chrome-Extension/WhatsApp Monitor/online.js @@ -1,23 +1,64 @@ +var nno="" +var nkey; +chrome.storage.local.get('nno', function (myresult) { + nno = myresult.nno; + console.log("nno val in online.js",nno); + if(nno==2){ + + var mnkey="" + chrome.storage.local.get('mnkey', function (result2) { + mnkey = result2.mnkey; + console.log("mnkey val from online.js",mnkey,typeof(mnkey)) + + if(mnkey != "undefined"){ + alert("Subcribe any Device for Notification\n"+mnkey) + nkey=mnkey; + } + + + }); + + + } + + }); -var nkey="" -chrome.storage.local.get('nkey', function (result2) { - nkey = result2.nkey; - if(nkey!="") - alert("Subcribe any Device for Notification\nhttps://notify.run/"+nkey) +console.log("nno val from online.js",nno); + + +pso="" +chrome.storage.local.get('pso', function (result3) { + pso = result3.pso; + + }); + console.log("pso val from online.js",pso); + + + + + + + + + + + + + function onotif(user) { - if(nkey==null||nkey==undefined||nkey=="") + if(nkey==null||nkey==undefined||nkey==""||nkey=="undefined") return else{ var xhr = new XMLHttpRequest(); - xhr.open("POST", "https://notify.run/"+nkey,true); + xhr.open("POST", nkey,true); xhr.send("📱WhatsApp Monitor: "+user+" is Online") } @@ -33,7 +74,7 @@ function save(user,t1,t2,t){ user=user.replace(/[^a-zA-Z0-9]/g, "") curd=curd.replace(/[^a-zA-Z0-9]/g, "") - const surl='https://whatsappanalysis.in/save/'+user+'/'+curd+'/'+t1+'/'+t2+'/'+t + const surl='https://wpmonitor.tech/save/'+user+'/'+curd+'/'+t1+'/'+t2+'/'+t var xhr = new XMLHttpRequest(); xhr.open("GET",surl); xhr.send() @@ -42,13 +83,7 @@ function save(user,t1,t2,t){ -pso="" -chrome.storage.local.get('pso', function (result3) { - pso = result3.pso; - - - }); diff --git a/Chrome-Extension/WhatsApp Monitor/popup.html b/Chrome-Extension/WhatsApp Monitor/popup.html index 8d63877..7a33e04 100644 --- a/Chrome-Extension/WhatsApp Monitor/popup.html +++ b/Chrome-Extension/WhatsApp Monitor/popup.html @@ -1,9 +1,85 @@ + + Online Monitor + + + @@ -11,33 +87,91 @@ + +

Please Open Chat on WhatsApp Web at least once to start monitoring

-

-Notification Key: -

-

About Notification Key

+ + + + + + + + + + + + + + + + + + + + + + +
+ +
+ + + Notification Key QR + + + +
+ +
+ + + + +

+ +
+ +
+

Notify Notification: + + +

+
+
-

Play Sounds: +

Sound:


-Auto Save CSV + Auto Save: Minute +
+

+

@@ -47,15 +181,18 @@

+ + +

- + -

+

- + @@ -87,7 +224,7 @@

@@ -96,7 +233,7 @@



-

Github Version 2.6 (10 July 2021)

+

Github Version 2.8 (10 July 2022)

@@ -104,7 +241,7 @@

Github Version 2.6 (10 July 2021)

Please support us by star for continue this project Thank You

-

About Online Monitor +

About Online Monitor

diff --git a/Chrome-Extension/WhatsApp Monitor/popup.js b/Chrome-Extension/WhatsApp Monitor/popup.js index 76b5f04..b34ff96 100644 --- a/Chrome-Extension/WhatsApp Monitor/popup.js +++ b/Chrome-Extension/WhatsApp Monitor/popup.js @@ -3,10 +3,50 @@ console.log('popup.js working') + + + +try { + + chrome.storage.sync.get(['nkey'], function(result) { + + + document.getElementById('qr').src=result.nkey+'/qr.svg'; + document.getElementById('link').innerText=result.nkey; + document.getElementById('link').setAttribute("data-url", result.nkey); + document.getElementById('link').setAttribute("href", result.nkey); + document.getElementById('new_key').innerHTML='Generate New' + + }); + +} catch (error) { + + chrome.storage.sync.get(['nkey'], function(result) { + document.getElementById('qr').src=result.nkey+'/qr.svg'; + document.getElementById('link').innerText=result.nkey; + document.getElementById('link').setAttribute("data-url", result.nkey); + document.getElementById('link').setAttribute("href", result.nkey); + document.getElementById('new_key').innerHTML='Generate New' + }); +} + + + + + +var myTabId; + +//chrome.tabs.query({active:true,windowType:"normal", currentWindow: true},function(d){myTabId=d[0].id;}) + + + + update_numarrray(); -function start(nkey,save_interval) { + + +function start(mnkey,save_interval) { b.innerText='Cancel'; //console.log(b.innerText); @@ -15,6 +55,8 @@ function start(nkey,save_interval) { //alert("stop set"); + console.log("mnkey from start_fun",mnkey); + chrome.storage.local.set({ @@ -24,16 +66,33 @@ function start(nkey,save_interval) { }); - chrome.storage.local.set({ - 'nkey': nkey +if(mnkey) +{ + console.log("mnkey is not undefined"); + + chrome.storage.local.set({ + 'mnkey': mnkey + + + }); +} + + + + + +chrome.storage.sync.set({ + 'numarray': numarray }); -chrome.storage.sync.set({ - 'numarray': numarray +console.log("nno val start_fun",nno); + +chrome.storage.local.set({ + 'nno': nno }); @@ -70,9 +129,16 @@ chrome.storage.local.set({ -chrome.tabs.executeScript({ - file: 'online.js' - }); +chrome.tabs.query({active: true, currentWindow: true}).then(([tab]) => { + chrome.scripting.executeScript( + { + target: {tabId: tab.id}, + files: ['online.js'], + // function: () => {}, // files or function, both do not work. + }) + }) + + @@ -117,33 +183,25 @@ save_interval=0; function get() { - - - - - - var nkey=document.getElementById('nkey').value; - - + var mnkey=document.getElementById('link').innerText; save_interval=document.getElementById('interval').value; - - chrome.storage.sync.set({"nkey": nkey}, function() { - document.getElementById('nkey').value=nkey; - - - }); - - - - pso=document.querySelector('input[name="ps"]:checked').value; + nno=document.querySelector('input[name="nn"]:checked').value; b=document.getElementById('start') + + console.log("nno value:",nno); + if(nno==1 || mnkey=="Please Generate") + { + mnkey=undefined; + } + + //alert(b.innerText); - //console.log(nkey,pso,b); - if(b.innerText=='OK'){start(nkey,save_interval);} + console.log("nkey val popup.js",mnkey); + if(b.innerText=='OK'){start(mnkey,save_interval);} else{stop();b.innerText='OK';b.className="btn-success";} @@ -152,19 +210,8 @@ function get() document.getElementById('start').addEventListener('click', get); -try { - chrome.storage.sync.get(['nkey'], function(result) { - - document.getElementById('nkey').value=result.nkey; - }); - -} catch (error) { - - chrome.storage.sync.get(['nkey'], function(result) { - document.getElementById('nkey').value=result.nkey; - }); -} + function mobchat() @@ -182,9 +229,23 @@ chrome.storage.local.set({ -chrome.tabs.executeScript({ - file: 'mobchat.js' - }); + + + + + + + +chrome.tabs.query({active: true, currentWindow: true}).then(([tab]) => { + chrome.scripting.executeScript( + { + target: {tabId: tab.id}, + files: ['mobchat.js'], + // function: () => {}, // files or function, both do not work. + }) + }) + + @@ -195,12 +256,48 @@ chrome.tabs.executeScript({ +function new_key(){ + + + document.getElementById('new_key').innerHTML=' ' + + + const req = new XMLHttpRequest(); + const baseUrl = "https://notify.run/api/register_channel"; + + req.open("POST", baseUrl, true); + req.setRequestHeader("Content-type", "application/x-www-form-urlencoded"); + req.send(); + + req.onreadystatechange = function() { // Call a function when the state changes. + if (this.readyState === XMLHttpRequest.DONE && this.status === 200) { + + var body = JSON.parse(req.responseText || null); + new_url=body['endpoint'] + console.log(new_url) + + + chrome.storage.sync.set({"nkey": new_url}, function() { + document.getElementById('qr').src=new_url+'/qr.svg'; + document.getElementById('link').innerText=new_url; + document.getElementById('link').setAttribute("data-url", new_url); + document.getElementById('link').setAttribute("href", new_url); + document.getElementById('new_key').innerHTML='Generate New' + + + }); + + } + } + + } + document.getElementById('mobchat').addEventListener('click', mobchat); document.getElementById('savenum').addEventListener('click', savenum); document.getElementById('delnum').addEventListener('click', delnum); - +document.getElementById('new_key').addEventListener('click', new_key); @@ -214,25 +311,48 @@ try{ } catch(err){ - chrome.tabs.executeScript({ - file: 'websocket.js' - }); + -chrome.tabs.executeScript({ - file: 'protobuf.js' - }); +chrome.tabs.query({active: true, currentWindow: true}).then(([tab]) => { + chrome.scripting.executeScript( + { + target: {tabId: tab.id}, + files: ['websocket.js'], + // function: () => {}, // files or function, both do not work. + }) + }) -chrome.tabs.executeScript({ - file: 'main.js' - }); + chrome.tabs.query({active: true, currentWindow: true}).then(([tab]) => { + chrome.scripting.executeScript( + { + target: {tabId: tab.id}, + files: ['protobuf.js'], + // function: () => {}, // files or function, both do not work. + }) + }) - + chrome.tabs.query({active: true, currentWindow: true}).then(([tab]) => { + chrome.scripting.executeScript( + { + target: {tabId: tab.id}, + files: ['main.js'], + // function: () => {}, // files or function, both do not work. + }) + }) + + + + + + + + } diff --git a/Chrome-Extension/WhatsApp Monitor/protobuf.js b/Chrome-Extension/WhatsApp Monitor/protobuf.js index b9a159a..eac4514 100644 --- a/Chrome-Extension/WhatsApp Monitor/protobuf.js +++ b/Chrome-Extension/WhatsApp Monitor/protobuf.js @@ -1,482 +1,9 @@ -/* - - - -var btn = document.createElement("BUTTON"); -btn.innerHTML = "Chat Contacts Online History"; -btn.style.width="100px"; -btn.id="download"; -document.querySelector("#side > header").appendChild(btn); -btn.style.backgroundColor="#075e54"; -btn.style.color="white"; -document.getElementById('download').addEventListener('click', dcsv); - -function dcsv() { - - let csvContent = "data:text/csv;charset=utf-8," - + rows.map(e => e.join(",")).join("\n"); - -var encodedUri = encodeURI(csvContent); -var link = document.createElement("a"); -link.setAttribute("href", encodedUri); -link.setAttribute("download", "online"+".csv"); -document.body.appendChild(link); -link.click(); - -} - -*/ - - - - - - - var os = document.createElement('script'); //s.src = chrome.extension.getURL('pagescript.js'); - os.innerHTML = ` - - - - - - - - - - - - - -function notify(user) { - if (!("Notification" in window)) { - alert("This browser does not support desktop notification"); - } - - else if (Notification.permission === "granted") { - var notification = new Notification("📱WhatsApp Monitor: "+user+" is Online"); - } - else if (Notification.permission !== 'denied') { - Notification.requestPermission(function (permission) { - - if(!('permission' in Notification)) { - Notification.permission = permission; - } - - if (permission === "granted") { - var notification = new Notification("📱"+user+" is Online in WhatsApp 📱"); - } - }); - } else { - alert('Permission is ${Notification.permission}'); - } -} - - - - -function ms2HMS( ms ) { - - var seconds = ms / 1000; - - var hours = parseInt( seconds / 3600 ); - seconds = seconds % 3600; - var minutes = parseInt( seconds / 60 ); - seconds = Math.floor(seconds % 60); - return( hours+":"+minutes+":"+seconds); -} - - -rows = []; -rows.push(["[WhatsApp","Monitor","Extension]","Online","Chat", "Contacts"]); -rows.push([" name "," Date "," Start ", " Stop ", " Duration"," Status "]); -let i=2; - - - -function createTable(tableData) { - try{ - document.body.querySelectorAll('table')[0].remove() - } - catch(err){ - // - } - var table = document.createElement('table'); - var tableBody = document.createElement('tbody'); - - tableData.forEach(function(rowData) { - var row = document.createElement('tr'); - - rowData.forEach(function(cellData) { - var cell = document.createElement('td'); - cell.appendChild(document.createTextNode(cellData)); - row.appendChild(cell); - }); - - tableBody.appendChild(row); - }); - - table.appendChild(tableBody); - document.body.appendChild(table); -} - - - - - - -function updatebtn(value){ - - - try{ - document.querySelectorAll('#userbtn')[0].remove() - - } - catch(err){ - // - } - - -var userbtn = document.createElement("BUTTON"); -userbtn.innerHTML = value; -userbtn.id="userbtn"; -document.body.appendChild(userbtn); - -} - - - -function usernamebtn(value){ - try{ - document.querySelectorAll('#usernamebtn')[0].remove() - } - catch(err){ - // - } -var usernbtn = document.createElement("BUTTON"); -usernbtn.innerHTML = value; -usernbtn.id="usernamebtn"; -document.body.appendChild(usernbtn); - -} - - -function online_list_btn(value){ - try{ - document.querySelectorAll('online_list_btn')[0].remove() - } - catch(err){ - // - } -var online_list_btn = document.createElement("BUTTON"); -online_list_btn.innerHTML = value; -online_list_btn.id="online_list_btn"; -document.body.appendChild(online_list_btn); - -} - - -online_list_btn("false"); - - - -function startbtn(value){ - try{ - document.querySelectorAll('#startbtn')[0].remove() - } - catch(err){ - // - } -var startbtn = document.createElement("BUTTON"); -startbtn.innerHTML = value; -startbtn.id="startbtn"; -document.body.appendChild(startbtn); - -} - -function stopbtn(value){ - try{ - document.querySelectorAll('#stopbtn')[0].remove() - } - catch(err){ - // - } -var stopbtn = document.createElement("BUTTON"); -stopbtn.innerHTML = value; -stopbtn.id="stopbtn"; -document.body.appendChild(stopbtn); - -} - -function durbtn(value){ - try{ - document.querySelectorAll('#durbtn')[0].remove() - } - catch(err){ - // - } -var durbtn = document.createElement("BUTTON"); -durbtn.innerHTML = value; -durbtn.id="durbtn"; -document.body.appendChild(durbtn); - -} - - - - -function contactbtn(value){ - try{ - document.querySelectorAll('#contactbtn')[0].remove() - } - catch(err){ - // - } -var contactbtn = document.createElement("BUTTON"); -contactbtn.innerHTML = value; -contactbtn.id="contactbtn"; -document.body.appendChild(contactbtn); - -} - - - - - - - - - - - -var h={}; - - - - - console.log('WhatsApp Monitor Started Successfully') - -setInterval(function(){ - - - try{ - - - - document.querySelectorAll('#contactbtn')[0].innerHTML='null'; - - - prev=document.querySelectorAll('#userbtn')[0].innerHTML - if(prev!='null'){ - prevDate=new Date(prev); - currDate = new Date(); - diff_time=currDate.getTime()-prevDate.getTime() - if(diff_time>2000) - updatebtn("null"); - - - - } - - - - } - catch(err){ - updatebtn("null"); - contactbtn("null") - - } - - - - - - - - - - - - - try{ - document.querySelectorAll('#usernamebtn')[0].innerHTML='null'; - document.querySelectorAll('#startbtn')[0].innerHTML='null'; - document.querySelectorAll('#stopbtn')[0].innerHTML='null'; - document.querySelectorAll('#durbtn')[0].innerHTML='null'; - - - } - catch(err){ - - } - - - - - - - - - - - - //console.log(window.Store) - try{ - online_list=window.Store.Presence.filter(a=>a.__x_isOnline==true && a.__x_isUser==true); - offline_list=window.Store.Presence.filter(a=>a.__x_isOnline==false && a.__x_isUser==true); - if(online_list.length>0){ - - document.querySelectorAll('#online_list_btn')[0].innerHTML='true'; - } - else - { - - document.querySelectorAll('#online_list_btn')[0].innerHTML='false'; - } - - online_list.forEach(onlineFun); - offline_list.forEach(offlineFun); - -function onlineFun(item, index) { - num=item["__x_id"]["user"] - if(window.Store.Contact._index[item.id].name) - name=window.Store.Contact._index[item.id].name - else - name="+"+num; - - - - - //console.log("num: "+num); - - //console.log("name: "+name); - startDate = new Date(); - - //console.log(t1) - if(h[num]==undefined||h[num]==null){ - h[num]=[name,1,startDate,"Wait"] - //console.log(h); - try{ - document.querySelector('[title="'+name+'"]').innerText='💚 '+name; - document.querySelector('[title="'+name+'"]').style.color='green'; - } - catch(err) - { - // - } - - updatebtn(startDate); - - notify(name) - try{ - document.querySelectorAll('#contactbtn')[0].innerHTML=name; - } - catch(err){} - } - else{ - if(h[num][1]==0){ - h[num][1]=1; - h[num][2]=startDate; - updatebtn(startDate); - notify(name) - try{ - document.querySelectorAll('#contactbtn')[0].innerHTML=name; - } - catch(err){} - - try{ - document.querySelector('[title="'+name+'"]').innerText='💚 '+name; - document.querySelector('[title="'+name+'"]').style.color='green'; - } - catch(err) - { - // - } - - - } - } - - - - -} - - - - - -function offlineFun(item, index) { -num=item["__x_id"]["user"] - if(window.Store.Contact._index[item.id].name) - name=window.Store.Contact._index[item.id].name - else - name="+"+num; -//console.log(h[num]) - if(h[num]!=undefined&&h[num]!=null){ - if(h[num][1]==1){ - endDate = new Date(); - startDate=h[num][2]; - t2=endDate.toTimeString().split(' ')[0] - t1=startDate.toTimeString().split(' ')[0] - h[num][1]=0; - h[num][2]=t1; - h[num][3]=t2; - //console.log(h[num]) - var curd=startDate.toLocaleDateString("en-GB").split(' ')[0] - diff_time=ms2HMS(endDate.getTime()-startDate.getTime()); - // console.log(name+" "+curd+" "+t1+" "+t2+" "+diff_time) - rows[i]=[name+" ",curd+" ",t1+" ",t2+" ",diff_time+" "," online "]; - i++; - //console.log(rows) - usernamebtn(num); - startbtn(t1); - stopbtn(t2); - durbtn(diff_time); - - createTable(rows) - - - - - - - - - - - - - - - - try{ - document.querySelector('[title="'+name+'"]').innerText='❤️ '+name; - document.querySelector('[title="'+name+'"]').style.color='red'; - } - catch(err){ - // - } - - - } - - } - //console.log(item["__x_id"]["user"]); -} - - - } - - catch(err){ - console.log(err); - //console.log("No One is Online"); - } - }, 2000); ` + os.src = chrome.runtime.getURL('inject_wp.js'); - document.body.append(os); + (document.head || document.documentElement).appendChild(os); diff --git a/Chrome-Extension/WhatsApp Monitor/start.js b/Chrome-Extension/WhatsApp Monitor/start.js index 77e3e97..edd4865 100644 --- a/Chrome-Extension/WhatsApp Monitor/start.js +++ b/Chrome-Extension/WhatsApp Monitor/start.js @@ -1,2 +1 @@ -var test; - +console.log("content scripts loaded successfully"); \ No newline at end of file diff --git a/Chrome-Extension/WhatsApp Monitor/wapi.js b/Chrome-Extension/WhatsApp Monitor/wapi.js new file mode 100644 index 0000000..a2707c1 --- /dev/null +++ b/Chrome-Extension/WhatsApp Monitor/wapi.js @@ -0,0 +1,1411 @@ +if (!window.Store) { + (function () { + function getStore(modules) { + let foundCount = 0; + let neededObjects = [ + { id: "Store", conditions: (module) => (module.default && module.default.Chat && module.default.Msg) ? module.default : null }, + { id: "MediaCollection", conditions: (module) => (module.default && module.default.prototype && module.default.prototype.processAttachments) ? module.default : null }, + { id: "MediaProcess", conditions: (module) => (module.BLOB) ? module : null }, + { id: "Wap", conditions: (module) => (module.createGroup) ? module : null }, + { id: "ServiceWorker", conditions: (module) => (module.default && module.default.killServiceWorker) ? module : null }, + { id: "State", conditions: (module) => (module.STATE && module.STREAM) ? module : null }, + { id: "WapDelete", conditions: (module) => (module.sendConversationDelete && module.sendConversationDelete.length == 2) ? module : null }, + { id: "Conn", conditions: (module) => (module.default && module.default.ref && module.default.refTTL) ? module.default : null }, + { id: "WapQuery", conditions: (module) => (module.queryExist) ? module : ((module.default && module.default.queryExist) ? module.default : null) }, + { id: "CryptoLib", conditions: (module) => (module.decryptE2EMedia) ? module : null }, + { id: "OpenChat", conditions: (module) => (module.default && module.default.prototype && module.default.prototype.openChat) ? module.default : null }, + { id: "UserConstructor", conditions: (module) => (module.default && module.default.prototype && module.default.prototype.isServer && module.default.prototype.isUser) ? module.default : null }, + { id: "SendTextMsgToChat", conditions: (module) => (module.sendTextMsgToChat) ? module.sendTextMsgToChat : null }, + { id: "SendSeen", conditions: (module) => (module.sendSeen) ? module.sendSeen : null }, + { id: "sendDelete", conditions: (module) => (module.sendDelete) ? module.sendDelete : null } + ]; + for (let idx in modules) { + if ((typeof modules[idx] === "object") && (modules[idx] !== null)) { + neededObjects.forEach((needObj) => { + if (!needObj.conditions || needObj.foundedModule) + return; + let neededModule = needObj.conditions(modules[idx]); + if (neededModule !== null) { + foundCount++; + needObj.foundedModule = neededModule; + } + }); + + if (foundCount == neededObjects.length) { + break; + } + } + } + + let neededStore = neededObjects.find((needObj) => needObj.id === "Store"); + window.Store = neededStore.foundedModule ? neededStore.foundedModule : {}; + neededObjects.splice(neededObjects.indexOf(neededStore), 1); + neededObjects.forEach((needObj) => { + if (needObj.foundedModule) { + window.Store[needObj.id] = needObj.foundedModule; + } + }); + + window.Store.Chat.modelClass.prototype.sendMessage = function (e) { + window.Store.SendTextMsgToChat(this, ...arguments); + } + + return window.Store; + } + + if (typeof webpackJsonp === 'function') { + webpackJsonp([], {'parasite': (x, y, z) => getStore(z)}, ['parasite']); + } else { + let tag = new Date().getTime(); + webpackChunkwhatsapp_web_client.push([ + ["parasite" + tag], + { + + }, + function (o, e, t) { + let modules = []; + for (let idx in o.m) { + let module = o(idx); + modules.push(module); + } + getStore(modules); + } + ]); + } + + })(); +} + +window.WAPI = { + lastRead: {} +}; + +window.WAPI._serializeRawObj = (obj) => { + if (obj) { + return obj.toJSON(); + } + return {} +}; + +/** + * Serializes a chat object + * + * @param rawChat Chat object + * @returns {{}} + */ + +window.WAPI._serializeChatObj = (obj) => { + if (obj == undefined) { + return null; + } + + return Object.assign(window.WAPI._serializeRawObj(obj), { + kind : obj.kind, + isGroup : obj.isGroup, + contact : obj['contact'] ? window.WAPI._serializeContactObj(obj['contact']) : null, + groupMetadata: obj["groupMetadata"] ? window.WAPI._serializeRawObj(obj["groupMetadata"]): null, + presence : obj["presence"] ? window.WAPI._serializeRawObj(obj["presence"]) : null, + msgs : null + }); +}; + +window.WAPI._serializeContactObj = (obj) => { + if (obj == undefined) { + return null; + } + + return Object.assign(window.WAPI._serializeRawObj(obj), { + formattedName : obj.formattedName, + isHighLevelVerified: obj.isHighLevelVerified, + isMe : obj.isMe, + isMyContact : obj.isMyContact, + isPSA : obj.isPSA, + isUser : obj.isUser, + isVerified : obj.isVerified, + isWAContact : obj.isWAContact, + profilePicThumbObj : obj.profilePicThumb ? WAPI._serializeProfilePicThumb(obj.profilePicThumb): {}, + statusMute : obj.statusMute, + msgs : null + }); +}; + +window.WAPI._serializeMessageObj = (obj) => { + if (obj == undefined) { + return null; + } + + return Object.assign(window.WAPI._serializeRawObj(obj), { + id : obj.id._serialized, + sender : obj["senderObj"] ? WAPI._serializeContactObj(obj["senderObj"]): null, + timestamp : obj["t"], + content : obj["body"], + isGroupMsg : obj.isGroupMsg, + isLink : obj.isLink, + isMMS : obj.isMMS, + isMedia : obj.isMedia, + isNotification: obj.isNotification, + isPSA : obj.isPSA, + type : obj.type, + chat : WAPI._serializeChatObj(obj['chat']), + chatId : obj.id.remote, + quotedMsgObj : WAPI._serializeMessageObj(obj['_quotedMsgObj']), + mediaData : window.WAPI._serializeRawObj(obj['mediaData']) + }); +}; + +window.WAPI._serializeNumberStatusObj = (obj) => { + if (obj == undefined) { + return null; + } + + return Object.assign({}, { + id : obj.jid, + status : obj.status, + isBusiness : (obj.biz === true), + canReceiveMessage: (obj.status === 200) + }); +}; + +window.WAPI._serializeProfilePicThumb = (obj) => { + if (obj == undefined) { + return null; + } + + return Object.assign({}, { + eurl : obj.eurl, + id : obj.id, + img : obj.img, + imgFull: obj.imgFull, + raw : obj.raw, + tag : obj.tag + }); +} + +window.WAPI.createGroup = function (name, contactsId) { + if (!Array.isArray(contactsId)) { + contactsId = [contactsId]; + } + + return window.Store.Wap.createGroup(name, contactsId); +}; + +window.WAPI.leaveGroup = function (groupId) { + groupId = typeof groupId == "string" ? groupId : groupId._serialized; + var group = WAPI.getChat(groupId); + return group.sendExit() +}; + + +window.WAPI.getAllContacts = function (done) { + const contacts = window.Store.Contact.map((contact) => WAPI._serializeContactObj(contact)); + + if (done !== undefined) done(contacts); + return contacts; +}; + +/** + * Fetches all contact objects from store, filters them + * + * @param done Optional callback function for async execution + * @returns {Array|*} List of contacts + */ +window.WAPI.getMyContacts = function (done) { + const contacts = window.Store.Contact.filter((contact) => contact.isMyContact === true).map((contact) => WAPI._serializeContactObj(contact)); + if (done !== undefined) done(contacts); + return contacts; +}; + +/** + * Fetches contact object from store by ID + * + * @param id ID of contact + * @param done Optional callback function for async execution + * @returns {T|*} Contact object + */ +window.WAPI.getContact = function (id, done) { + const found = window.Store.Contact.get(id); + + if (done !== undefined) done(window.WAPI._serializeContactObj(found)) + return window.WAPI._serializeContactObj(found); +}; + +/** + * Fetches all chat objects from store + * + * @param done Optional callback function for async execution + * @returns {Array|*} List of chats + */ +window.WAPI.getAllChats = function (done) { + const chats = window.Store.Chat.map((chat) => WAPI._serializeChatObj(chat)); + + if (done !== undefined) done(chats); + return chats; +}; + +window.WAPI.haveNewMsg = function (chat) { + return chat.unreadCount > 0; +}; + +window.WAPI.getAllChatsWithNewMsg = function (done) { + const chats = window.Store.Chat.filter(window.WAPI.haveNewMsg).map((chat) => WAPI._serializeChatObj(chat)); + + if (done !== undefined) done(chats); + return chats; +}; + +/** + * Fetches all chat IDs from store + * + * @param done Optional callback function for async execution + * @returns {Array|*} List of chat id's + */ +window.WAPI.getAllChatIds = function (done) { + const chatIds = window.Store.Chat.map((chat) => chat.id._serialized || chat.id); + + if (done !== undefined) done(chatIds); + return chatIds; +}; + +/** + * Fetches all groups objects from store + * + * @param done Optional callback function for async execution + * @returns {Array|*} List of chats + */ +window.WAPI.getAllGroups = function (done) { + const groups = window.Store.Chat.filter((chat) => chat.isGroup); + + if (done !== undefined) done(groups); + return groups; +}; + +/** + * Fetches chat object from store by ID + * + * @param id ID of chat + * @param done Optional callback function for async execution + * @returns {T|*} Chat object + */ +window.WAPI.getChat = function (id, done) { + id = typeof id == "string" ? id : id._serialized; + const found = window.Store.Chat.get(id); + found.sendMessage = (found.sendMessage) ? found.sendMessage : function () { return window.Store.sendMessage.apply(this, arguments); }; + if (done !== undefined) done(found); + return found; +} + +window.WAPI.getChatByName = function (name, done) { + const found = window.WAPI.getAllChats().find(val => val.name.includes(name)) + if (done !== undefined) done(found); + return found; +}; + +window.WAPI.sendImageFromDatabasePicBot = function (picId, chatId, caption) { + var chatDatabase = window.WAPI.getChatByName('DATABASEPICBOT'); + var msgWithImg = chatDatabase.msgs.find((msg) => msg.caption == picId); + + if (msgWithImg === undefined) { + return false; + } + var chatSend = WAPI.getChat(chatId); + if (chatSend === undefined) { + return false; + } + const oldCaption = msgWithImg.caption; + + msgWithImg.id.id = window.WAPI.getNewId(); + msgWithImg.id.remote = chatId; + msgWithImg.t = Math.ceil(new Date().getTime() / 1000); + msgWithImg.to = chatId; + + if (caption !== undefined && caption !== '') { + msgWithImg.caption = caption; + } else { + msgWithImg.caption = ''; + } + + msgWithImg.collection.send(msgWithImg).then(function (e) { + msgWithImg.caption = oldCaption; + }); + + return true; +}; + +window.WAPI.sendMessageWithThumb = function (thumb, url, title, description, text, chatId, done) { + var chatSend = WAPI.getChat(chatId); + if (chatSend === undefined) { + if (done !== undefined) done(false); + return false; + } + var linkPreview = { + canonicalUrl: url, + description : description, + matchedText : url, + title : title, + thumbnail : thumb, + compose: true + }; + chatSend.sendMessage(text, { linkPreview: linkPreview, + mentionedJidList: [], + quotedMsg: null, + quotedMsgAdminGroupJid: null }); + if (done !== undefined) done(true); + return true; +}; + +window.WAPI.getNewId = function () { + var text = ""; + var possible = "ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789"; + + for (var i = 0; i < 20; i++) + text += possible.charAt(Math.floor(Math.random() * possible.length)); + return text; +}; + +window.WAPI.getChatById = function (id, done) { + let found = WAPI.getChat(id); + if (found) { + found = WAPI._serializeChatObj(found); + } else { + found = false; + } + + if (done !== undefined) done(found); + return found; +}; + + +/** + * I return all unread messages from an asked chat and mark them as read. + * + * :param id: chat id + * :type id: string + * + * :param includeMe: indicates if user messages have to be included + * :type includeMe: boolean + * + * :param includeNotifications: indicates if notifications have to be included + * :type includeNotifications: boolean + * + * :param done: callback passed by selenium + * :type done: function + * + * :returns: list of unread messages from asked chat + * :rtype: object + */ +window.WAPI.getUnreadMessagesInChat = function (id, includeMe, includeNotifications, done) { + // get chat and its messages + let chat = WAPI.getChat(id); + let messages = chat.msgs._models; + + // initialize result list + let output = []; + + // look for unread messages, newest is at the end of array + for (let i = messages.length - 1; i >= 0; i--) { + // system message: skip it + if (i === "remove") { + continue; + } + + // get message + let messageObj = messages[i]; + + // found a read message: stop looking for others + if (typeof (messageObj.isNewMsg) !== "boolean" || messageObj.isNewMsg === false) { + continue; + } else { + messageObj.isNewMsg = false; + // process it + let message = WAPI.processMessageObj(messageObj, + includeMe, + includeNotifications); + + // save processed message on result list + if (message) + output.push(message); + } + } + // callback was passed: run it + if (done !== undefined) done(output); + // return result list + return output; +} +; + + +/** + * Load more messages in chat object from store by ID + * + * @param id ID of chat + * @param done Optional callback function for async execution + * @returns None + */ +window.WAPI.loadEarlierMessages = function (id, done) { + const found = WAPI.getChat(id); + if (done !== undefined) { + found.loadEarlierMsgs().then(function () { + done() + }); + } else { + found.loadEarlierMsgs(); + } +}; + +/** + * Load more messages in chat object from store by ID + * + * @param id ID of chat + * @param done Optional callback function for async execution + * @returns None + */ +window.WAPI.loadAllEarlierMessages = function (id, done) { + const found = WAPI.getChat(id); + x = function () { + if (!found.msgs.msgLoadState.noEarlierMsgs) { + found.loadEarlierMsgs().then(x); + } else if (done) { + done(); + } + }; + x(); +}; + +window.WAPI.asyncLoadAllEarlierMessages = function (id, done) { + done(); + window.WAPI.loadAllEarlierMessages(id); +}; + +window.WAPI.areAllMessagesLoaded = function (id, done) { + const found = WAPI.getChat(id); + if (!found.msgs.msgLoadState.noEarlierMsgs) { + if (done) done(false); + return false + } + if (done) done(true); + return true +}; + +/** + * Load more messages in chat object from store by ID till a particular date + * + * @param id ID of chat + * @param lastMessage UTC timestamp of last message to be loaded + * @param done Optional callback function for async execution + * @returns None + */ + +window.WAPI.loadEarlierMessagesTillDate = function (id, lastMessage, done) { + const found = WAPI.getChat(id); + x = function () { + if (found.msgs.models[0].t > lastMessage && !found.msgs.msgLoadState.noEarlierMsgs) { + found.loadEarlierMsgs().then(x); + } else { + done(); + } + }; + x(); +}; + + +/** + * Fetches all group metadata objects from store + * + * @param done Optional callback function for async execution + * @returns {Array|*} List of group metadata + */ +window.WAPI.getAllGroupMetadata = function (done) { + const groupData = window.Store.GroupMetadata.map((groupData) => groupData.all); + + if (done !== undefined) done(groupData); + return groupData; +}; + +/** + * Fetches group metadata object from store by ID + * + * @param id ID of group + * @param done Optional callback function for async execution + * @returns {T|*} Group metadata object + */ +window.WAPI.getGroupMetadata = async function (id, done) { + let output = window.Store.GroupMetadata.get(id); + + if (output !== undefined) { + if (output.stale) { + await window.Store.GroupMetadata.update(id); + } + } + + if (done !== undefined) done(output); + return output; + +}; + + +/** + * Fetches group participants + * + * @param id ID of group + * @returns {Promise.<*>} Yields group metadata + * @private + */ +window.WAPI._getGroupParticipants = async function (id) { + const metadata = await WAPI.getGroupMetadata(id); + return metadata.participants; +}; + +/** + * Fetches IDs of group participants + * + * @param id ID of group + * @param done Optional callback function for async execution + * @returns {Promise.} Yields list of IDs + */ +window.WAPI.getGroupParticipantIDs = async function (id, done) { + const output = (await WAPI._getGroupParticipants(id)) + .map((participant) => participant.id); + + if (done !== undefined) done(output); + return output; +}; + +window.WAPI.getGroupAdmins = async function (id, done) { + const output = (await WAPI._getGroupParticipants(id)) + .filter((participant) => participant.isAdmin) + .map((admin) => admin.id); + + if (done !== undefined) done(output); + return output; +}; + +/** + * Gets object representing the logged in user + * + * @returns {Array|*|$q.all} + */ +window.WAPI.getMe = function (done) { + const rawMe = window.Store.Contact.get(window.Store.Conn.me); + + if (done !== undefined) done(rawMe.all); + return rawMe.all; +}; + +window.WAPI.isLoggedIn = function (done) { + // Contact always exists when logged in + const isLogged = window.Store.Contact && window.Store.Contact.checksum !== undefined; + + if (done !== undefined) done(isLogged); + return isLogged; +}; + +window.WAPI.isConnected = function (done) { + // Phone Disconnected icon appears when phone is disconnected from the tnternet + const isConnected = document.querySelector('*[data-icon="alert-phone"]') !== null ? false : true; + + if (done !== undefined) done(isConnected); + return isConnected; +}; + +window.WAPI.processMessageObj = function (messageObj, includeMe, includeNotifications) { + if (messageObj.isNotification) { + if (includeNotifications) + return WAPI._serializeMessageObj(messageObj); + else + return; + // System message + // (i.e. "Messages you send to this chat and calls are now secured with end-to-end encryption...") + } else if (messageObj.id.fromMe === false || includeMe) { + return WAPI._serializeMessageObj(messageObj); + } + return; +}; + +window.WAPI.getAllMessagesInChat = function (id, includeMe, includeNotifications, done) { + const chat = WAPI.getChat(id); + let output = []; + const messages = chat.msgs._models; + + for (const i in messages) { + if (i === "remove") { + continue; + } + const messageObj = messages[i]; + + let message = WAPI.processMessageObj(messageObj, includeMe, includeNotifications) + if (message) + output.push(message); + } + if (done !== undefined) done(output); + return output; +}; + +window.WAPI.getAllMessageIdsInChat = function (id, includeMe, includeNotifications, done) { + const chat = WAPI.getChat(id); + let output = []; + const messages = chat.msgs._models; + + for (const i in messages) { + if ((i === "remove") + || (!includeMe && messages[i].isMe) + || (!includeNotifications && messages[i].isNotification)) { + continue; + } + output.push(messages[i].id._serialized); + } + if (done !== undefined) done(output); + return output; +}; + +window.WAPI.getMessageById = function (id, done) { + let result = false; + try { + let msg = window.Store.Msg.get(id); + if (msg) { + result = WAPI.processMessageObj(msg, true, true); + } + } catch (err) { } + + if (done !== undefined) { + done(result); + } else { + return result; + } +}; + +window.WAPI.ReplyMessage = function (idMessage, message, done) { + var messageObject = window.Store.Msg.get(idMessage); + if (messageObject === undefined) { + if (done !== undefined) done(false); + return false; + } + messageObject = messageObject.value(); + + const chat = WAPI.getChat(messageObject.chat.id) + if (chat !== undefined) { + if (done !== undefined) { + chat.sendMessage(message, null, messageObject).then(function () { + function sleep(ms) { + return new Promise(resolve => setTimeout(resolve, ms)); + } + + var trials = 0; + + function check() { + for (let i = chat.msgs.models.length - 1; i >= 0; i--) { + let msg = chat.msgs.models[i]; + + if (!msg.senderObj.isMe || msg.body != message) { + continue; + } + done(WAPI._serializeMessageObj(msg)); + return True; + } + trials += 1; + console.log(trials); + if (trials > 30) { + done(true); + return; + } + sleep(500).then(check); + } + check(); + }); + return true; + } else { + chat.sendMessage(message, null, messageObject); + return true; + } + } else { + if (done !== undefined) done(false); + return false; + } +}; + +window.WAPI.sendMessageToID = function (id, message, done) { + try { + window.getContact = (id) => { + return Store.WapQuery.queryExist(id); + } + window.getContact(id).then(contact => { + if (contact.status === 404) { + done(true); + } else { + Store.Chat.find(contact.jid).then(chat => { + chat.sendMessage(message); + return true; + }).catch(reject => { + if (WAPI.sendMessage(id, message)) { + done(true); + return true; + }else{ + done(false); + return false; + } + }); + } + }); + } catch (e) { + if (window.Store.Chat.length === 0) + return false; + + firstChat = Store.Chat.models[0]; + var originalID = firstChat.id; + firstChat.id = typeof originalID === "string" ? id : new window.Store.UserConstructor(id, { intentionallyUsePrivateConstructor: true }); + if (done !== undefined) { + firstChat.sendMessage(message).then(function () { + firstChat.id = originalID; + done(true); + }); + return true; + } else { + firstChat.sendMessage(message); + firstChat.id = originalID; + return true; + } + } + if (done !== undefined) done(false); + return false; +} + +window.WAPI.sendMessage = function (id, message, done) { + var chat = WAPI.getChat(id); + if (chat !== undefined) { + if (done !== undefined) { + chat.sendMessage(message).then(function () { + function sleep(ms) { + return new Promise(resolve => setTimeout(resolve, ms)); + } + + var trials = 0; + + function check() { + for (let i = chat.msgs.models.length - 1; i >= 0; i--) { + let msg = chat.msgs.models[i]; + + if (!msg.senderObj.isMe || msg.body != message) { + continue; + } + done(WAPI._serializeMessageObj(msg)); + return True; + } + trials += 1; + console.log(trials); + if (trials > 30) { + done(true); + return; + } + sleep(500).then(check); + } + check(); + }); + return true; + } else { + chat.sendMessage(message); + return true; + } + } else { + if (done !== undefined) done(false); + return false; + } +}; + +window.WAPI.sendMessage2 = function (id, message, done) { + var chat = WAPI.getChat(id); + if (chat !== undefined) { + try { + if (done !== undefined) { + chat.sendMessage(message).then(function () { + done(true); + }); + } else { + chat.sendMessage(message); + } + return true; + } catch (error) { + if (done !== undefined) done(false) + return false; + } + } + if (done !== undefined) done(false) + return false; +}; + +window.WAPI.sendSeen = function (id, done) { + var chat = window.WAPI.getChat(id); + if (chat !== undefined) { + if (done !== undefined) { + if (chat.getLastMsgKeyForAction === undefined) + chat.getLastMsgKeyForAction = function () { }; + Store.SendSeen(chat, false).then(function () { + done(true); + }); + return true; + } else { + Store.SendSeen(chat, false); + return true; + } + } + if (done !== undefined) done(); + return false; +}; + +function isChatMessage(message) { + if (message.isSentByMe) { + return false; + } + if (message.isNotification) { + return false; + } + if (!message.isUserCreatedType) { + return false; + } + return true; +} + + +window.WAPI.getUnreadMessages = function (includeMe, includeNotifications, use_unread_count, done) { + const chats = window.Store.Chat.models; + let output = []; + + for (let chat in chats) { + if (isNaN(chat)) { + continue; + } + + let messageGroupObj = chats[chat]; + let messageGroup = WAPI._serializeChatObj(messageGroupObj); + + messageGroup.messages = []; + + const messages = messageGroupObj.msgs._models; + for (let i = messages.length - 1; i >= 0; i--) { + let messageObj = messages[i]; + if (typeof (messageObj.isNewMsg) != "boolean" || messageObj.isNewMsg === false) { + continue; + } else { + messageObj.isNewMsg = false; + let message = WAPI.processMessageObj(messageObj, includeMe, includeNotifications); + if (message) { + messageGroup.messages.push(message); + } + } + } + + if (messageGroup.messages.length > 0) { + output.push(messageGroup); + } else { // no messages with isNewMsg true + if (use_unread_count) { + let n = messageGroupObj.unreadCount; // will use unreadCount attribute to fetch last n messages from sender + for (let i = messages.length - 1; i >= 0; i--) { + let messageObj = messages[i]; + if (n > 0) { + if (!messageObj.isSentByMe) { + let message = WAPI.processMessageObj(messageObj, includeMe, includeNotifications); + messageGroup.messages.unshift(message); + n -= 1; + } + } else if (n === -1) { // chat was marked as unread so will fetch last message as unread + if (!messageObj.isSentByMe) { + let message = WAPI.processMessageObj(messageObj, includeMe, includeNotifications); + messageGroup.messages.unshift(message); + break; + } + } else { // unreadCount = 0 + break; + } + } + if (messageGroup.messages.length > 0) { + messageGroupObj.unreadCount = 0; // reset unread counter + output.push(messageGroup); + } + } + } + } + if (done !== undefined) { + done(output); + } + return output; +}; + +window.WAPI.getGroupOwnerID = async function (id, done) { + const output = (await WAPI.getGroupMetadata(id)).owner.id; + if (done !== undefined) { + done(output); + } + return output; + +}; + +window.WAPI.getCommonGroups = async function (id, done) { + let output = []; + + groups = window.WAPI.getAllGroups(); + + for (let idx in groups) { + try { + participants = await window.WAPI.getGroupParticipantIDs(groups[idx].id); + if (participants.filter((participant) => participant == id).length) { + output.push(groups[idx]); + } + } catch (err) { + console.log("Error in group:"); + console.log(groups[idx]); + console.log(err); + } + } + + if (done !== undefined) { + done(output); + } + return output; +}; + + +window.WAPI.getProfilePicSmallFromId = function (id, done) { + window.Store.ProfilePicThumb.find(id).then(function (d) { + if (d.img !== undefined) { + window.WAPI.downloadFileWithCredentials(d.img, done); + } else { + done(false); + } + }, function (e) { + done(false); + }) +}; + +window.WAPI.getProfilePicFromId = function (id, done) { + window.Store.ProfilePicThumb.find(id).then(function (d) { + if (d.imgFull !== undefined) { + window.WAPI.downloadFileWithCredentials(d.imgFull, done); + } else { + done(false); + } + }, function (e) { + done(false); + }) +}; + +window.WAPI.downloadFileWithCredentials = function (url, done) { + let xhr = new XMLHttpRequest(); + + xhr.onload = function () { + if (xhr.readyState == 4) { + if (xhr.status == 200) { + let reader = new FileReader(); + reader.readAsDataURL(xhr.response); + reader.onload = function (e) { + done(reader.result.substr(reader.result.indexOf(',') + 1)) + }; + } else { + console.error(xhr.statusText); + } + } else { + console.log(err); + done(false); + } + }; + + xhr.open("GET", url, true); + xhr.withCredentials = true; + xhr.responseType = 'blob'; + xhr.send(null); +}; + + +window.WAPI.downloadFile = function (url, done) { + let xhr = new XMLHttpRequest(); + + + xhr.onload = function () { + if (xhr.readyState == 4) { + if (xhr.status == 200) { + let reader = new FileReader(); + reader.readAsDataURL(xhr.response); + reader.onload = function (e) { + done(reader.result.substr(reader.result.indexOf(',') + 1)) + }; + } else { + console.error(xhr.statusText); + } + } else { + console.log(err); + done(false); + } + }; + + xhr.open("GET", url, true); + xhr.responseType = 'blob'; + xhr.send(null); +}; + +window.WAPI.getBatteryLevel = function (done) { + if (window.Store.Conn.plugged) { + if (done !== undefined) { + done(100); + } + return 100; + } + output = window.Store.Conn.battery; + if (done !== undefined) { + done(output); + } + return output; +}; + +window.WAPI.deleteConversation = function (chatId, done) { + let userId = new window.Store.UserConstructor(chatId, {intentionallyUsePrivateConstructor: true}); + let conversation = WAPI.getChat(userId); + + if (!conversation) { + if (done !== undefined) { + done(false); + } + return false; + } + + window.Store.sendDelete(conversation, false).then(() => { + if (done !== undefined) { + done(true); + } + }).catch(() => { + if (done !== undefined) { + done(false); + } + }); + + return true; +}; + +window.WAPI.deleteMessage = function (chatId, messageArray, revoke=false, done) { + let userId = new window.Store.UserConstructor(chatId, {intentionallyUsePrivateConstructor: true}); + let conversation = WAPI.getChat(userId); + + if(!conversation) { + if(done !== undefined) { + done(false); + } + return false; + } + + if (!Array.isArray(messageArray)) { + messageArray = [messageArray]; + } + let messagesToDelete = messageArray.map(msgId => window.Store.Msg.get(msgId)); + + if (revoke) { + conversation.sendRevokeMsgs(messagesToDelete, conversation); + } else { + conversation.sendDeleteMsgs(messagesToDelete, conversation); + } + + + if (done !== undefined) { + done(true); + } + + return true; +}; + +window.WAPI.checkNumberStatus = function (id, done) { + window.Store.WapQuery.queryExist(id).then((result) => { + if( done !== undefined) { + if (result.jid === undefined) throw 404; + done(window.WAPI._serializeNumberStatusObj(result)); + } + }).catch((e) => { + if (done !== undefined) { + done(window.WAPI._serializeNumberStatusObj({ + status: e, + jid : id + })); + } + }); + + return true; +}; + +/** + * New messages observable functions. + */ +window.WAPI._newMessagesQueue = []; +window.WAPI._newMessagesBuffer = (sessionStorage.getItem('saved_msgs') != null) ? JSON.parse(sessionStorage.getItem('saved_msgs')) : []; +window.WAPI._newMessagesDebouncer = null; +window.WAPI._newMessagesCallbacks = []; + +window.Store.Msg.off('add'); +sessionStorage.removeItem('saved_msgs'); + +window.WAPI._newMessagesListener = window.Store.Msg.on('add', (newMessage) => { + if (newMessage && newMessage.isNewMsg && !newMessage.isSentByMe) { + let message = window.WAPI.processMessageObj(newMessage, false, false); + if (message) { + window.WAPI._newMessagesQueue.push(message); + window.WAPI._newMessagesBuffer.push(message); + } + + // Starts debouncer time to don't call a callback for each message if more than one message arrives + // in the same second + if (!window.WAPI._newMessagesDebouncer && window.WAPI._newMessagesQueue.length > 0) { + window.WAPI._newMessagesDebouncer = setTimeout(() => { + let queuedMessages = window.WAPI._newMessagesQueue; + + window.WAPI._newMessagesDebouncer = null; + window.WAPI._newMessagesQueue = []; + + let removeCallbacks = []; + + window.WAPI._newMessagesCallbacks.forEach(function (callbackObj) { + if (callbackObj.callback !== undefined) { + callbackObj.callback(queuedMessages); + } + if (callbackObj.rmAfterUse === true) { + removeCallbacks.push(callbackObj); + } + }); + + // Remove removable callbacks. + removeCallbacks.forEach(function (rmCallbackObj) { + let callbackIndex = window.WAPI._newMessagesCallbacks.indexOf(rmCallbackObj); + window.WAPI._newMessagesCallbacks.splice(callbackIndex, 1); + }); + }, 1000); + } + } +}); + +window.WAPI._unloadInform = (event) => { + // Save in the buffer the ungot unreaded messages + window.WAPI._newMessagesBuffer.forEach((message) => { + Object.keys(message).forEach(key => message[key] === undefined ? delete message[key] : ''); + }); + sessionStorage.setItem("saved_msgs", JSON.stringify(window.WAPI._newMessagesBuffer)); + + // Inform callbacks that the page will be reloaded. + window.WAPI._newMessagesCallbacks.forEach(function (callbackObj) { + if (callbackObj.callback !== undefined) { + callbackObj.callback({ status: -1, message: 'page will be reloaded, wait and register callback again.' }); + } + }); +}; + +window.addEventListener("unload", window.WAPI._unloadInform, false); +window.addEventListener("beforeunload", window.WAPI._unloadInform, false); +window.addEventListener("pageunload", window.WAPI._unloadInform, false); + +/** + * Registers a callback to be called when a new message arrives the WAPI. + * @param rmCallbackAfterUse - Boolean - Specify if the callback need to be executed only once + * @param done - function - Callback function to be called when a new message arrives. + * @returns {boolean} + */ +window.WAPI.waitNewMessages = function (rmCallbackAfterUse = true, done) { + window.WAPI._newMessagesCallbacks.push({ callback: done, rmAfterUse: rmCallbackAfterUse }); + return true; +}; + +/** + * Reads buffered new messages. + * @param done - function - Callback function to be called contained the buffered messages. + * @returns {Array} + */ +window.WAPI.getBufferedNewMessages = function (done) { + let bufferedMessages = window.WAPI._newMessagesBuffer; + window.WAPI._newMessagesBuffer = []; + if (done !== undefined) { + done(bufferedMessages); + } + return bufferedMessages; +}; +/** End new messages observable functions **/ + +window.WAPI.sendImage = function (imgBase64, chatid, filename, caption, done) { +//var idUser = new window.Store.UserConstructor(chatid); +var idUser = new window.Store.UserConstructor(chatid, { intentionallyUsePrivateConstructor: true }); +// create new chat +return Store.Chat.find(idUser).then((chat) => { + var mediaBlob = window.WAPI.base64ImageToFile(imgBase64, filename); + var mc = new Store.MediaCollection(chat); + mc.processAttachments([{file: mediaBlob}, 1], chat, 1).then(() => { + var media = mc.models[0]; + media.sendToChat(chat, { caption: caption }); + if (done !== undefined) done(true); + }); +}); +} + +window.WAPI.base64ImageToFile = function (b64Data, filename) { + var arr = b64Data.split(','); + var mime = arr[0].match(/:(.*?);/)[1]; + var bstr = atob(arr[1]); + var n = bstr.length; + var u8arr = new Uint8Array(n); + + while (n--) { + u8arr[n] = bstr.charCodeAt(n); + } + + return new File([u8arr], filename, {type: mime}); +}; + +/** + * Send contact card to a specific chat using the chat ids + * + * @param {string} to '000000000000@c.us' + * @param {string|array} contact '111111111111@c.us' | ['222222222222@c.us', '333333333333@c.us, ... 'nnnnnnnnnnnn@c.us'] + */ +window.WAPI.sendContact = function (to, contact) { + if (!Array.isArray(contact)) { + contact = [contact]; + } + contact = contact.map((c) => { + return WAPI.getChat(c).__x_contact; + }); + + if (contact.length > 1) { + window.WAPI.getChat(to).sendContactList(contact); + } else if (contact.length === 1) { + window.WAPI.getChat(to).sendContact(contact[0]); + } +}; + +/** + * Create an chat ID based in a cloned one + * + * @param {string} chatId '000000000000@c.us' + */ +window.WAPI.getNewMessageId = function (chatId) { + var newMsgId = Store.Msg.models[0].__x_id.clone(); + + newMsgId.fromMe = true; + newMsgId.id = WAPI.getNewId().toUpperCase(); + newMsgId.remote = chatId; + return newMsgId; +}; + +/** + * Send Customized VCard without the necessity of contact be a Whatsapp Contact + * + * @param {string} chatId '000000000000@c.us' + * @param {object|array} vcard { displayName: 'Contact Name', vcard: 'BEGIN:VCARD\nVERSION:3.0\nN:;Contact Name;;;\nEND:VCARD' } | [{ displayName: 'Contact Name 1', vcard: 'BEGIN:VCARD\nVERSION:3.0\nN:;Contact Name 1;;;\nEND:VCARD' }, { displayName: 'Contact Name 2', vcard: 'BEGIN:VCARD\nVERSION:3.0\nN:;Contact Name 2;;;\nEND:VCARD' }] + */ +window.WAPI.sendVCard = function (chatId, vcard) { + var chat = Store.Chat.get(chatId); + var tempMsg = Object.create(Store.Msg.models.filter(msg => msg.__x_isSentByMe)[0]); + var newId = window.WAPI.getNewMessageId(chatId); + + var extend = { + ack : 0, + id : newId, + local : !0, + self : "out", + t : parseInt(new Date().getTime() / 1000), + to : chatId, + isNewMsg: !0, + }; + + if (Array.isArray(vcard)) { + Object.assign(extend, { + type : "multi_vcard", + vcardList: vcard + }); + + delete extend.body; + } else { + Object.assign(extend, { + type : "vcard", + subtype: vcard.displayName, + body : vcard.vcard + }); + + delete extend.vcardList; + } + + Object.assign(tempMsg, extend); + + chat.addAndSendMsg(tempMsg); +}; +/** + * Block contact + * @param {string} id '000000000000@c.us' + * @param {*} done - function - Callback function to be called when a new message arrives. + */ +window.WAPI.contactBlock = function (id, done) { + const contact = window.Store.Contact.get(id); + if (contact !== undefined) { + contact.setBlock(!0); + done(true); + return true; + } + done(false); + return false; +} +/** + * unBlock contact + * @param {string} id '000000000000@c.us' + * @param {*} done - function - Callback function to be called when a new message arrives. + */ +window.WAPI.contactUnblock = function (id, done) { + const contact = window.Store.Contact.get(id); + if (contact !== undefined) { + contact.setBlock(!1); + done(true); + return true; + } + done(false); + return false; +} + +/** + * Remove participant of Group + * @param {*} idGroup '0000000000-00000000@g.us' + * @param {*} idParticipant '000000000000@c.us' + * @param {*} done - function - Callback function to be called when a new message arrives. + */ +window.WAPI.removeParticipantGroup = function (idGroup, idParticipant, done) { + window.Store.WapQuery.removeParticipants(idGroup, [idParticipant]).then(() => { + const metaDataGroup = window.Store.GroupMetadata.get(id) + checkParticipant = metaDataGroup.participants._index[idParticipant]; + if (checkParticipant === undefined) { + done(true); return true; + } + }) +} + +/** + * Promote Participant to Admin in Group + * @param {*} idGroup '0000000000-00000000@g.us' + * @param {*} idParticipant '000000000000@c.us' + * @param {*} done - function - Callback function to be called when a new message arrives. + */ +window.WAPI.promoteParticipantAdminGroup = function (idGroup, idParticipant, done) { + window.Store.WapQuery.promoteParticipants(idGroup, [idParticipant]).then(() => { + const metaDataGroup = window.Store.GroupMetadata.get(id) + checkParticipant = metaDataGroup.participants._index[idParticipant]; + if (checkParticipant !== undefined && checkParticipant.isAdmin) { + done(true); return true; + } + done(false); return false; + }) +} + +/** + * Demote Admin of Group + * @param {*} idGroup '0000000000-00000000@g.us' + * @param {*} idParticipant '000000000000@c.us' + * @param {*} done - function - Callback function to be called when a new message arrives. + */ +window.WAPI.demoteParticipantAdminGroup = function (idGroup, idParticipant, done) { + window.Store.WapQuery.demoteParticipants(idGroup, [idParticipant]).then(() => { + const metaDataGroup = window.Store.GroupMetadata.get(id) + if (metaDataGroup === undefined) { + done(false); return false; + } + checkParticipant = metaDataGroup.participants._index[idParticipant]; + if (checkParticipant !== undefined && checkParticipant.isAdmin) { + done(false); return false; + } + done(true); return true; + }) +} + diff --git a/Chrome-Extension/WhatsApp Monitor/websocket.js b/Chrome-Extension/WhatsApp Monitor/websocket.js index 2fed869..b70e568 100644 --- a/Chrome-Extension/WhatsApp Monitor/websocket.js +++ b/Chrome-Extension/WhatsApp Monitor/websocket.js @@ -3,110 +3,16 @@ if(document.head != null) { //clearInterval(clear) var s = document.createElement('script'); - //s.src = chrome.extension.getURL('pagescript.js'); - s.innerHTML = ` - -if (!window.Store) { - (function () { - function getStore(modules) { - let foundCount = 0; - let neededObjects = [ - { id: "Store", conditions: (module) => (module.default && module.default.Chat && module.default.Msg) ? module.default : null }, - { id: "MediaCollection", conditions: (module) => (module.default && module.default.prototype && module.default.prototype.processAttachments) ? module.default : null }, - { id: "MediaProcess", conditions: (module) => (module.BLOB) ? module : null }, - { id: "Wap", conditions: (module) => (module.createGroup) ? module : null }, - { id: "ServiceWorker", conditions: (module) => (module.default && module.default.killServiceWorker) ? module : null }, - { id: "State", conditions: (module) => (module.STATE && module.STREAM) ? module : null }, - { id: "WapDelete", conditions: (module) => (module.sendConversationDelete && module.sendConversationDelete.length == 2) ? module : null }, - { id: "Conn", conditions: (module) => (module.default && module.default.ref && module.default.refTTL) ? module.default : null }, - { id: "WapQuery", conditions: (module) => (module.queryExist) ? module : ((module.default && module.default.queryExist) ? module.default : null) }, - { id: "CryptoLib", conditions: (module) => (module.decryptE2EMedia) ? module : null }, - { id: "OpenChat", conditions: (module) => (module.default && module.default.prototype && module.default.prototype.openChat) ? module.default : null }, - { id: "UserConstructor", conditions: (module) => (module.default && module.default.prototype && module.default.prototype.isServer && module.default.prototype.isUser) ? module.default : null }, - { id: "SendTextMsgToChat", conditions: (module) => (module.sendTextMsgToChat) ? module.sendTextMsgToChat : null }, - { id: "SendSeen", conditions: (module) => (module.sendSeen) ? module.sendSeen : null }, - { id: "sendDelete", conditions: (module) => (module.sendDelete) ? module.sendDelete : null } - ]; - for (let idx in modules) { - if ((typeof modules[idx] === "object") && (modules[idx] !== null)) { - let first = Object.values(modules[idx])[0]; - if ((typeof first === "object") && (first.exports)) { - for (let idx2 in modules[idx]) { - let module = modules(idx2); - if (!module) { - continue; - } - neededObjects.forEach((needObj) => { - if (!needObj.conditions || needObj.foundedModule) - return; - let neededModule = needObj.conditions(module); - if (neededModule !== null) { - foundCount++; - needObj.foundedModule = neededModule; - } - }); - if (foundCount == neededObjects.length) { - break; - } - } - - let neededStore = neededObjects.find((needObj) => needObj.id === "Store"); - window.Store = neededStore.foundedModule ? neededStore.foundedModule : {}; - neededObjects.splice(neededObjects.indexOf(neededStore), 1); - neededObjects.forEach((needObj) => { - if (needObj.foundedModule) { - window.Store[needObj.id] = needObj.foundedModule; - } - }); - window.Store.sendMessage = function (e) { - return window.Store.SendTextMsgToChat(this, ...arguments); - }; - return window.Store; - } - } - } - } - - if (typeof webpackJsonp === 'function') { - webpackJsonp([], {'parasite': (x, y, z) => getStore(z)}, ['parasite']); - } else { - webpackJsonp.push([ - ['parasite'], - { - parasite: function (o, e, t) { - getStore(t); - } - }, - [['parasite']] - ]); - } - + s.src = chrome.runtime.getURL('wapi.js'); - })(); - - - window.Store = webpackJsonp([], null, ["bhggeigghg"]).default; -window.Store.Wap = webpackJsonp([], null, ["bihdhbjih"]).default; - - -window.rizwan = { - lastRead: {} -}; - - -window.rizwan.isOnline = function (id, done){ var idUser = new window.Store.UserConstructor(id, {intentionallyUsePrivateConstructor: true}); is_online = rizwan.getChat(idUser).presence.isOnline; if (done !== undefined) done(is_online); return is_online; } - - - -}` s.onload = function() { //this.remove(); }; - document.body.prepend(s); + (document.head || document.documentElement).appendChild(s); }