From 5eb21eb8decfa09034e042d796f9fb720a38e712 Mon Sep 17 00:00:00 2001 From: Juzlus Date: Wed, 11 Dec 2024 18:02:02 +0100 Subject: [PATCH] v1.11 --- css/style.css | 95 +++- data/cases.json | 648 ++++++++++++++++++++++--- data/icons/Keydrop+_Icon-Christmas.png | Bin 6437 -> 6399 bytes data/serverData.json | 2 +- js/alertBanner.js | 2 +- js/caseBattleButton.js | 9 +- js/caseInfoGames.js | 4 +- js/caseOdds.js | 81 +++- js/freeOpen.js | 2 +- js/freeOpenGames.js | 2 +- js/giveawayBack.js | 4 +- js/giveawaysList.js | 4 +- js/joinCaseBattle.js | 51 +- js/main.js | 23 +- js/paymentPromocode.js | 51 +- js/settingsPanel.js | 46 +- js/skinChanger.js | 22 +- js/statisticsButton.js | 5 +- manifest.json | 7 +- 19 files changed, 887 insertions(+), 171 deletions(-) diff --git a/css/style.css b/css/style.css index d5ca88e..0fddac2 100644 --- a/css/style.css +++ b/css/style.css @@ -217,6 +217,30 @@ div.relative.flex-1.css-lx3yvj { opacity: 1; } +#keydrop-plus-modal { + filter: opacity(0); + display: none; + animation-name: hideSettings; + animation-duration: 0.4s; +} + +#keydrop-plus-modal.is-open { + filter: opacity(1); + display: block; + animation-name: showSettings; + animation-duration: 0.4s; +} + +@keyframes hideSettings { + 0% { filter: opacity(1); display: block; } + 100% { filter: opacity(0); display: block; } +} + +@keyframes showSettings { + 0% { filter: opacity(0) } + 100% { filter: opacity(1); } +} + #skinChanger-best-skins-panel { border-radius: 15px; position: fixed; @@ -488,9 +512,76 @@ img[alt="KeyDrop"] { cursor: unset; } -.keydrop-plus-freeOpen-nonce:checked + p { +.freeOpen div.grid-rows-1 { + border-color: rgb(74 71 94); +} + +.keydrop-plus-auto-casebattle-button { + border: 1px solid rgb(119 255 157); + border-radius: .375rem; + padding: 0px 32px !important; + background-color: rgb(25 43 5); + margin-left: 15px; + height: 48px; + color: white; + font-weight: bolder; + font-size: .75rem; +} + +div#caseBattle-root label[for] { + cursor: pointer; + user-select: none; +} + +#autoCaseBattleButton { + width: 170px; + margin-right: 28px; +} + +input[name="caseMode"]:checked + label, input[name="casePlayers"]:checked + label, input[name="caseCount"]:checked + label { + background: rgba(220, 174, 100, 0.99); + color: black; +} + +#keydrop-plus-free-open label { + background: transparent; + color: rgb(106 109 129); + width: 50px; + height: 50px; + border: 1px solid rgb(74 71 94); + cursor: pointer; + text-align: center; + transition: all 0.4s; +} + +label[for="keydrop-plus-select-nonce-6"] { + border-radius: 8px 0px 0px 8px; +} + +label[for="keydrop-plus-select-nonce-42"] { + border-radius: 0px 8px 8px 0px; +} + +#keydrop-plus-free-open div.flex.h-10 input { + display: none; +} + +.keydrop-plus-freeOpen-nonce:checked + label { + border: 2px solid rgb(220 174 100) !important; + box-shadow: inset 0px 0px 7px rgb(220 174 100); +} + +#keydrop-plus-free-open div.flex.h-10 label:hover { + background: #ffffff07; +} + +#keydrop-plus-free-open div.flex.h-10 label p { + margin-top: 12px; + user-select: none; +} + +.keydrop-plus-freeOpen-nonce:checked + label p { color: rgb(220 174 100); - cursor: unset !important; } .keydorop-show-menu + label { diff --git a/data/cases.json b/data/cases.json index 6b0e354..29fa56a 100644 --- a/data/cases.json +++ b/data/cases.json @@ -1,107 +1,565 @@ [ { - "name": "ZONY", - "price_USD": 9, - "img": "https://key-drop.com/uploads/skins/ZONY1.png", - "url": "https://key-drop.com/pl/skins/category/zony", - "youtuber": true, - "odds": 13 + "name": "CIASTKO", + "price_USD": 16, + "odds": 19 }, { "name": "FOREVER", "price_USD": 9, "img": "https://key-drop.com/uploads/skins/FOREVER1.png", - "url": "https://key-drop.com/pl/skins/category/forever", + "url": "https://key-drop.com/en/skins/category/FOREVER", "youtuber": true, "odds": 17 }, { - "name": "NEXE", - "price_USD": 6.66, - "img": "https://key-drop.com/uploads/skins/NEXE1.png", - "url": "https://key-drop.com/pl/skins/category/nexe", + "name": "MEDUSA", + "price_USD": 6.7, + "img": "https://key-drop.com/uploads/skins/MEDUSA1.png", + "url": "https://key-drop.com/en/skins/category/MEDUSA", "youtuber": true, - "odds": 18 + "odds": 15 + }, + { + "name": "PUNIOGAMING", + "price_USD": 10, + "img": "https://key-drop.com/uploads/skins/PUNIOGAMING.png", + "url": "https://key-drop.com/en/skins/category/PUNIOGAMING", + "youtuber": true, + "odds": 4 + }, + { + "name": "ISAMU", + "price_USD": 15, + "img": "https://key-drop.com/uploads/skins/ISAMU_.png", + "url": "https://key-drop.com/en/skins/category/ISAMU", + "youtuber": true, + "odds": 15 + }, + { + "name": "JRKZ", + "price_USD": 10, + "odds": 5 + }, + { + "name": "MISZCZU", + "price_USD": 20, + "odds": 16 + }, + { + "name": "VYSOTZKY", + "price_USD": 18, + "img": "https://key-drop.com/uploads/skins/VYSOTZKY.png", + "url": "https://key-drop.com/en/skins/category/VYSOTZKY", + "youtuber": true, + "odds": 8 }, { "name": "DMG", "price_USD": 37, "img": "https://key-drop.com/uploads/skins/DMG_.png", - "url": "https://key-drop.com/pl/skins/category/dmg", + "url": "https://key-drop.com/en/skins/category/DMG", "youtuber": true, "odds": 11 }, + { + "name": "OKTA", + "price_USD": 9, + "odds": 15 + }, + { + "name": "GIGO", + "price_USD": 10, + "img": "https://key-drop.com/uploads/skins/GIGO.png", + "url": "https://key-drop.com/en/skins/category/GIGO", + "youtuber": true, + "odds": 20 + }, + { + "name": "DEXON", + "price_USD": 2.5, + "img": "https://key-drop.com/uploads/skins/DEXON.png", + "url": "https://key-drop.com/en/skins/category/DEXON", + "youtuber": true, + "odds": 1 + }, + { + "name": "MOPO", + "price_USD": 10.8, + "img": "https://key-drop.com/uploads/skins/MOPO1.png", + "url": "https://key-drop.com/en/skins/category/MOPO", + "youtuber": true, + "odds": 14 + }, + { + "name": "NEXE", + "price_USD": 6.66, + "img": "https://key-drop.com/uploads/skins/NEXE1.png", + "url": "https://key-drop.com/en/skins/category/NEXE", + "youtuber": true, + "odds": 18 + }, + { + "name": "CHINIYO", + "price_USD": 70, + "img": "https://key-drop.com/uploads/skins/CHINIYO1.png", + "url": "https://key-drop.com/en/skins/category/CHINIYO", + "youtuber": true, + "odds": 19 + }, + { + "name": "PEVOR", + "price_USD": 40, + "odds": 9 + }, + { + "name": "MLODZIUTKI7", + "price_USD": 7.5, + "img": "https://key-drop.com/uploads/skins/MLODZIUTKI7.png", + "url": "https://key-drop.com/en/skins/category/MLODZIUTKI7", + "youtuber": true, + "odds": 3 + }, + { + "name": "POPO", + "price_USD": 20, + "img": "https://key-drop.com/uploads/skins/POPO1.png", + "url": "https://key-drop.com/en/skins/category/POPO", + "youtuber": true, + "odds": 6 + }, + { + "name": "REMSUA", + "price_USD": 20, + "img": "https://key-drop.com/uploads/skins/remsua.png", + "url": "https://key-drop.com/en/skins/category/REMSUA", + "youtuber": true, + "odds": 8 + }, + { + "name": "LUKISTEVE", + "price_USD": 20, + "img": "https://key-drop.com/uploads/skins/LUKISTEVE.png", + "url": "https://key-drop.com/en/skins/category/LUKISTEVE", + "youtuber": true, + "odds": 3 + }, + { + "name": "TARIFA BRONZE", + "price_USD": 30, + "img": "https://key-drop.com/uploads/skins/TARIFA1.png", + "url": "https://key-drop.com/en/skins/category/tarifa-bronze", + "youtuber": true, + "odds": 5 + }, + { + "name": "TARIFA", + "price_USD": 80, + "img": "https://key-drop.com/uploads/skins/TARIFA.png", + "url": "https://key-drop.com/en/skins/category/tarifa-3", + "youtuber": true, + "odds": 10 + }, + { + "name": "TARIFA GOLD", + "price_USD": 160, + "img": "https://key-drop.com/uploads/skins/TARIFA2.png", + "url": "https://key-drop.com/en/skins/category/tarifa-gold", + "youtuber": true, + "odds": 14 + }, + { + "name": "MOKRYSUCHAR", + "price_USD": 4, + "img": "https://key-drop.com/uploads/skins/MOKRYSUCHAR.png", + "url": "https://key-drop.com/en/skins/category/MOKRYSUCHAR", + "youtuber": true, + "odds": 22 + }, + { + "name": "OLSZAKUMPEL", + "price_USD": 1, + "img": "https://key-drop.com/uploads/skins/OLSZAKUMPEL.png", + "url": "https://key-drop.com/en/skins/category/OLSZAKUMPEL", + "youtuber": true, + "odds": 9 + }, + { + "name": "GRACZOL", + "price_USD": 5, + "odds": 19 + }, + { + "name": "DEJVID", + "price_USD": 1, + "img": "https://key-drop.com/uploads/skins/dejvid.png", + "url": "https://key-drop.com/en/skins/category/DEJVID", + "youtuber": true, + "odds": 4 + }, + { + "name": "ZONY", + "price_USD": 9, + "img": "https://key-drop.com/uploads/skins/ZONY1.png", + "url": "https://key-drop.com/en/skins/category/ZONY", + "youtuber": true, + "odds": 13 + }, { "name": "INNOCENT", "price_USD": 5.53, "img": "https://key-drop.com/uploads/skins/INNOCENT_.png", - "url": "https://key-drop.com/pl/skins/category/innocent", + "url": "https://key-drop.com/en/skins/category/INNOCENT", "youtuber": true, "odds": 22 }, { - "name": "MEDUSA", - "price_USD": 6.7, - "img": "https://key-drop.com/uploads/skins/MEDUSA1.png", - "url": "https://key-drop.com/pl/skins/category/medusa", + "name": "ZIGGY", + "price_USD": 8.25, + "img": "https://key-drop.com/uploads/skins/ZIGGY.png", + "url": "https://key-drop.com/en/skins/category/ZIGGY", + "youtuber": true, + "odds": 10 + }, + { + "name": "AKI", + "price_USD": 10, + "img": "https://key-drop.com/uploads/skins/AKI1.png", + "url": "https://key-drop.com/en/skins/category/AKI", "youtuber": true, "odds": 15 }, { - "name": "ISAMU", + "name": "VURAL UCAR", + "price_USD": 6.32, + "img": "https://key-drop.com/uploads/skins/VULAR_UCAR.png", + "url": "https://key-drop.com/en/skins/category/VURAL-UCAR", + "youtuber": true, + "odds": 17 + }, + { + "name": "MAAILINH", + "price_USD": 35, + "img": "https://key-drop.com/uploads/skins/MAAILINH1.png", + "url": "https://key-drop.com/en/skins/category/MAAILINH", + "youtuber": true, + "odds": 11 + }, + { + "name": "NATURAL", + "price_USD": 10, + "odds": 9 + }, + { + "name": "KACPER RIETZ", + "price_USD": 3.94, + "img": "https://key-drop.com/uploads/skins/KACPER_RIETZ1.png", + "url": "https://key-drop.com/en/skins/category/KACPER-RIETZ", + "youtuber": true, + "odds": 28 + }, + { + "name": "SAMPEV2", "price_USD": 15, - "img": "https://key-drop.com/uploads/skins/ISAMU_.png", - "url": "https://key-drop.com/pl/skins/category/isamu", + "img": "https://key-drop.com/uploads/skins/SAMPEV2.png", + "url": "https://key-drop.com/en/skins/category/SAMPEV2", "youtuber": true, - "odds": 15 + "odds": 5 + }, + { + "name": "XAYOO", + "price_USD": 25, + "img": "https://key-drop.com/uploads/skins/XAYOO1.png", + "url": "https://key-drop.com/en/skins/category/XAYOO", + "youtuber": true, + "odds": 24 }, { "name": "MATEO", "price_USD": 3.94, "img": "https://key-drop.com/uploads/skins/MATEO1.png", - "url": "https://key-drop.com/pl/skins/category/mateo", + "url": "https://key-drop.com/en/skins/category/MATEO", "youtuber": true, "odds": 10 }, { - "name": "KACPER RIETZ", - "price_USD": 3.94, - "img": "https://key-drop.com/uploads/skins/KACPER_RIETZ1.png", - "url": "https://key-drop.com/pl/skins/category/kacper-rietz", + "name": "WTCN", + "price_USD": 10, + "odds": 7 + }, + { + "name": "ATADOGANN", + "price_USD": 21.5, + "odds": 35 + }, + { + "name": "CIASTKO JOKER", + "price_USD": 402.9, + "odds": 33 + }, + { + "name": "FOREVER JOKER", + "price_USD": 405.2, + "img": "https://key-drop.com/uploads/skins/FOREVER1.png", + "url": "https://key-drop.com/en/skins/category/FOREVER-JOKER", "youtuber": true, - "odds": 28 + "odds": 17 }, { - "name": "MOPO", - "price_USD": 10.8, + "name": "MEDUSA JOKER", + "price_USD": 408.36, + "img": "https://key-drop.com/uploads/skins/MEDUSA1.png", + "url": "https://key-drop.com/en/skins/category/MEDUSA-JOKER", + "youtuber": true, + "odds": 21 + }, + { + "name": "PUNIOGAMING JOKER", + "price_USD": 440.56, + "img": "https://key-drop.com/uploads/skins/PUNIOGAMING.png", + "url": "https://key-drop.com/en/skins/category/PUNIOGAMING-JOKER", + "youtuber": true, + "odds": 25 + }, + { + "name": "ISAMU JOKER", + "price_USD": 517.45, + "img": "https://key-drop.com/uploads/skins/ISAMU_.png", + "url": "https://key-drop.com/en/skins/category/ISAMU-JOKER", + "youtuber": true, + "odds": 22 + }, + { + "name": "JRKZ JOKER", + "price_USD": 524.92, + "odds": 8 + }, + { + "name": "MISZCZU JOKER", + "price_USD": 528.86, + "odds": 26 + }, + { + "name": "VYSOTZKY JOKER", + "price_USD": 597.41, + "img": "https://key-drop.com/uploads/skins/VYSOTZKY.png", + "url": "https://key-drop.com/en/skins/category/VYSOTZKY-JOKER", + "youtuber": true, + "odds": 33 + }, + { + "name": "DMG JOKER", + "price_USD": 611, + "img": "https://key-drop.com/uploads/skins/DMG_.png", + "url": "https://key-drop.com/en/skins/category/DMG-JOKER", + "youtuber": true, + "odds": 25 + }, + { + "name": "OKTA JOKER", + "price_USD": 655.45, + "odds": 8 + }, + { + "name": "GIGO JOKER", + "price_USD": 657.69, + "img": "https://key-drop.com/uploads/skins/GIGO.png", + "url": "https://key-drop.com/en/skins/category/GIGO-JOKER", + "youtuber": true, + "odds": 27 + }, + { + "name": "DEXON JOKER", + "price_USD": 719.96, + "img": "https://key-drop.com/uploads/skins/DEXON.png", + "url": "https://key-drop.com/en/skins/category/DEXON-JOKER", + "youtuber": true, + "odds": 25 + }, + { + "name": "MOPO JOKER", + "price_USD": 784.36, "img": "https://key-drop.com/uploads/skins/MOPO1.png", - "url": "https://key-drop.com/pl/skins/category/mopo", + "url": "https://key-drop.com/en/skins/category/MOPO-JOKER", "youtuber": true, - "odds": 14 + "odds": 17 }, { - "name": "XM1NN", - "price_USD": 7.1, - "img": "https://key-drop.com/uploads/skins/XM1NN1.png", - "url": "https://key-drop.com/pl/skins/category/xm1nn", + "name": "NEXE JOKER", + "price_USD": 940.36, + "img": "https://key-drop.com/uploads/skins/NEXE1.png", + "url": "https://key-drop.com/en/skins/category/NEXE-JOKER", "youtuber": true, - "odds": 15 + "odds": 28 }, { - "name": "RENNOW", - "price_USD": 5.13, - "img": "https://key-drop.com/uploads/skins/RENNOW.png", - "url": "https://key-drop.com/pl/skins/category/rennow", + "name": "CHINIYO JOKER", + "price_USD": 1078.37, + "img": "https://key-drop.com/uploads/skins/CHINIYO2.png", + "url": "https://key-drop.com/en/skins/category/CHINIYO-JOKER", + "youtuber": true, + "odds": 17 + }, + { + "name": "PEVOR JOKER", + "price_USD": 1162.08, + "odds": 50 + }, + { + "name": "MLODZIUTKI7 JOKER", + "price_USD": 1169.74, + "img": "https://key-drop.com/uploads/skins/MLODZIUTKI7.png", + "url": "https://key-drop.com/en/skins/category/MLODZIUTKI7-JOKER", + "youtuber": true, + "odds": 33 + }, + { + "name": "POPO JOKER", + "price_USD": 1320.7, + "img": "https://key-drop.com/uploads/skins/POPO1.png", + "url": "https://key-drop.com/en/skins/category/POPO-JOKER", + "youtuber": true, + "odds": 8 + }, + { + "name": "REMSUA JOKER", + "price_USD": 1395.42, + "img": "https://key-drop.com/uploads/skins/remsua.png", + "url": "https://key-drop.com/en/skins/category/REMSUA-JOKER", "youtuber": true, "odds": 22 }, { - "name": "ENERQIA", - "price_USD": 4.95, - "img": "https://key-drop.com/uploads/skins/ENERQIA1.png", - "url": "https://key-drop.com/pl/skins/category/enerqia", + "name": "LUKISTEVE JOKER", + "price_USD": 1950.57, + "img": "https://key-drop.com/uploads/skins/LUKISTEVE.png", + "url": "https://key-drop.com/en/skins/category/LUKISTEVE-JOKER", "youtuber": true, - "odds": 26 + "odds": 42 + }, + { + "name": "MOKRYSUCHAR JOKER", + "price_USD": 15.66, + "img": "https://key-drop.com/uploads/skins/MOKRYSUCHAR.png", + "url": "https://key-drop.com/en/skins/category/MOKRYSUCHAR-JOKER", + "youtuber": true, + "odds": 15 + }, + { + "name": "OLSZAKUMPEL JOKER", + "price_USD": 68.49, + "img": "https://key-drop.com/uploads/skins/OLSZAKUMPEL.png", + "url": "https://key-drop.com/en/skins/category/OLSZAKUMPEL-JOKER", + "youtuber": true, + "odds": 25 + }, + { + "name": "GRACZOL JOKER", + "price_USD": 134.65, + "odds": 33 + }, + { + "name": "DEJVID JOKER", + "price_USD": 135, + "img": "https://key-drop.com/uploads/skins/dejvid.png", + "url": "https://key-drop.com/en/skins/category/DEJVID-JOKER", + "youtuber": true, + "odds": 13 + }, + { + "name": "ZONY JOKER", + "price_USD": 162.45, + "img": "https://key-drop.com/uploads/skins/ZONY1.png", + "url": "https://key-drop.com/en/skins/category/ZONY-JOKER", + "youtuber": true, + "odds": 23 + }, + { + "name": "INNOCENT JOKER", + "price_USD": 166.23, + "img": "https://key-drop.com/uploads/skins/INNOCENT_.png", + "url": "https://key-drop.com/en/skins/category/INNOCENT-JOKER", + "youtuber": true, + "odds": 21 + }, + { + "name": "ZIGGY JOKER", + "price_USD": 174.19, + "img": "https://key-drop.com/uploads/skins/ZIGGY.png", + "url": "https://key-drop.com/en/skins/category/ZIGGY-JOKER", + "youtuber": true, + "odds": 33 + }, + { + "name": "AKI JOKER", + "price_USD": 187, + "img": "https://key-drop.com/uploads/skins/AKI1.png", + "url": "https://key-drop.com/en/skins/category/AKI-JOKER", + "youtuber": true, + "odds": 17 + }, + { + "name": "VURAL UCAR JOKER", + "price_USD": 249.18, + "img": "https://key-drop.com/uploads/skins/VULAR_UCAR.png", + "url": "https://key-drop.com/en/skins/category/VURAL-UCAR-JOKER", + "youtuber": true, + "odds": 20 + }, + { + "name": "MAAILINH JOKER", + "price_USD": 267.5, + "img": "https://key-drop.com/uploads/skins/MAAILINH1.png", + "url": "https://key-drop.com/en/skins/category/MAAILINH-JOKER", + "youtuber": true, + "odds": 30 + }, + { + "name": "NATURAL JOKER", + "price_USD": 296.6, + "odds": 25 + }, + { + "name": "KACPER RIETZ JOKER", + "price_USD": 305.95, + "img": "https://key-drop.com/uploads/skins/KACPER_RIETZ1.png", + "url": "https://key-drop.com/en/skins/category/KACPER-RIETZ-JOKER", + "youtuber": true, + "odds": 17 + }, + { + "name": "SAMPEV2 JOKER", + "price_USD": 326.13, + "img": "https://key-drop.com/uploads/skins/SAMPEV2.png", + "url": "https://key-drop.com/en/skins/category/SAMPEV2-JOKER", + "youtuber": true, + "odds": 28 + }, + { + "name": "XAYOO JOKER", + "price_USD": 341.47, + "img": "https://key-drop.com/uploads/skins/XAYOO1.png", + "url": "https://key-drop.com/en/skins/category/XAYOO-JOKER", + "youtuber": true, + "odds": 17 + }, + { + "name": "MATEO JOKER", + "price_USD": 346.52, + "img": "https://key-drop.com/uploads/skins/MATEO1.png", + "url": "https://key-drop.com/en/skins/category/MATEO-JOKER", + "youtuber": true, + "odds": 11 + }, + { + "name": "WTCN JOKER", + "price_USD": 369.8, + "odds": 11 + }, + { + "name": "ATADOGANN JOKER", + "price_USD": 373.14, + "odds": 25 }, { "name": "CLEVER BOY", @@ -704,6 +1162,56 @@ "price_USD": 1668.12, "odds": 27 }, + { + "name": "EMERALD", + "price_USD": 1000, + "odds": 25 + }, + { + "name": "EMERALD JOKER", + "price_USD": 2526.57, + "odds": 25 + }, + { + "name": "PEARL", + "price_USD": 3300, + "odds": 25 + }, + { + "name": "PEARL JOKER", + "price_USD": 6658.57, + "odds": 31 + }, + { + "name": "PANDORA", + "price_USD": 5000, + "odds": 22 + }, + { + "name": "GUNGNIR", + "price_USD": 4000, + "odds": 25 + }, + { + "name": "TALON", + "price_USD": 2500, + "odds": 25 + }, + { + "name": "TALON JOKER", + "price_USD": 5722.79, + "odds": 27 + }, + { + "name": "SPORT", + "price_USD": 1700, + "odds": 25 + }, + { + "name": "SPORT JOKER", + "price_USD": 3295.78, + "odds": 33 + }, { "name": "SNUGTOES", "price_USD": 27, @@ -2023,102 +2531,102 @@ { "name": "TOPAZ", "price_USD": 700, - "goldProfit": "15146520.14" + "goldProfit": "15114803.34" }, { "name": "BONY", "price_USD": 2000, - "goldProfit": "13419196.45" + "goldProfit": "13417659.75" }, { "name": "MAGENT", "price_USD": 6200, - "goldProfit": "12965842.38" + "goldProfit": "13051166.95" }, { "name": "ASSAULT", "price_USD": 13600, - "goldProfit": "16031912.77" + "goldProfit": "16085336.62" }, { "name": "RECON", "price_USD": 35000, - "goldProfit": "16804015.63" + "goldProfit": "16919318.17" }, { "name": "FOSTER", "price_USD": 610, - "goldProfit": "23545897.16" + "goldProfit": "23543359.15" }, { "name": "PREDATOR", "price_USD": 1200, - "goldProfit": "32061144.66" + "goldProfit": "32052094.55" }, { "name": "OPTIMAL", "price_USD": 1930, - "goldProfit": "29104585.25" + "goldProfit": "29095941.06" }, { "name": "SOLAR", "price_USD": 5600, - "goldProfit": "24657584.23" + "goldProfit": "24635342.11" }, { "name": "WIND", "price_USD": 12500, - "goldProfit": "23168517.96" + "goldProfit": "23223435.04" }, { "name": "RUBY", "price_USD": 1300, - "goldProfit": "24847985.15" + "goldProfit": "24857858.13" }, { "name": "SHARK", "price_USD": 680, - "goldProfit": "26433974.16" + "goldProfit": "26432050.54" }, { "name": "WRAP", "price_USD": 4900, - "goldProfit": "24371486.79" + "goldProfit": "24320061.52" }, { "name": "SAMURAI", "price_USD": 9900, - "goldProfit": "24943432.45" + "goldProfit": "24949722.09" }, { "name": "ATUM", "price_USD": 2670, - "goldProfit": "24604990.28" + "goldProfit": "24586161.60" }, { "name": "GOLD DIGGER", "price_USD": 480, - "goldProfit": "28273966.58" + "goldProfit": "28279643.17" }, { "name": "RUBIN RAIN", "price_USD": 840, - "goldProfit": "24322189.98" + "goldProfit": "24333473.39" }, { "name": "AMETHYST LIGHT", "price_USD": 1400, - "goldProfit": "30827231.53" + "goldProfit": "30816507.70" }, { "name": "DIAMOND SKY", "price_USD": 6200, - "goldProfit": "27099687.46" + "goldProfit": "27118384.10" }, { "name": "EMERALD CUT", "price_USD": 19200, - "goldProfit": "23357920.64" + "goldProfit": "23346053.17" }, { "name": "VALEK", @@ -2264,14 +2772,6 @@ "youtuber": true, "odds": 19 }, - { - "name": "TARIFA", - "price_USD": 80, - "img": "https://key-drop.com/uploads/skins/TARIFA.png", - "url": "https://key-drop.com/en/skins/category/tarifa-3", - "youtuber": true, - "odds": 10 - }, { "name": "VIRUZZ", "price_USD": 20, diff --git a/data/icons/Keydrop+_Icon-Christmas.png b/data/icons/Keydrop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-ULF&8{@%%-o05&jS+x z3cIPU=^#AHBo2IhJb})6w#GjAiz%rC${kwd=t?N0(gDW9|AsC{aX}zPc=qF<*E&DN z@L8ke^t<;S=KFh(k$u`(eMr*x)SM_HpY(3w{DXd3S1R`|htT;WzSXn8UIwMAem34$ zLQBmSI_mQtm-2<*>q=4lFOWk8WPiv(Z+<_LV05ZnJpK5;B($-=<{E@3q { if(!server?.current_versions?.includes(version)) createToast('info', 'info_update', language['info_updateDownload'], server?.updateLink || 'https://www.github.com/Juzlus/KeydropPlus/releases/latest/'); - + if(server?.globalAlertVersion?.includes(config?.version)) $('div#app-root')?.eq(0) ?.prepend($(document.createElement('div')) diff --git a/js/caseBattleButton.js b/js/caseBattleButton.js index a208b37..8098ff6 100644 --- a/js/caseBattleButton.js +++ b/js/caseBattleButton.js @@ -1,5 +1,5 @@ $( document ).ready(function(){ - waitForElm('.mx-auto.mb-5.max-w-screen-xxl.transition.duration-500.opacity-100 label').then(()=>{ + waitForElm('[data-testid="bttls-create-bttl-btn"]').then(()=>{ createCaseBattleButton(); }); }); @@ -9,13 +9,12 @@ const createCaseBattleButton = async() => { const server = await getServerData(); const language = await getLanguageData(config?.lang); - $('.mx-auto.mb-5.max-w-screen-xxl.transition.duration-500.opacity-100 label') + $('[data-testid="bttls-create-bttl-btn"]') .before($(document.createElement('a')) - .css({ 'font-weight': 'bolder', color: 'black' }) - .addClass('order-5 mt-5 flex cursor-pointer items-center whitespace-nowrap p-2 text-center font-semibold uppercase text-white sm:p-3 xl:order-7 xl:mt-0 xl:w-auto css-9c7r58 keydrop-plus-svg') + .addClass('keydrop-plus-auto-casebattle-button order-5 mt-5 flex cursor-pointer items-center whitespace-nowrap p-2 text-center font-semibold uppercase text-white sm:p-3 xl:order-7 xl:mt-0 xl:w-auto css-9c7r58') .attr('href', `https://key-drop.com/panel/profil/fast-case-battle`) .append($(document.createElement('svg')) - .addClass('w-5 h-5 mr-2 fill-current') + .addClass('w-5 h-5 mr-2 fill-current keydrop-plus-svg') .attr({ viewbox: "0 0 24 24" }) .append($(document.createElement('img')) .attr({ src: `${githubUrl}${server?.iconsPath}KD+_Icon.svg` }) diff --git a/js/caseInfoGames.js b/js/caseInfoGames.js index 6f43393..6d773d7 100644 --- a/js/caseInfoGames.js +++ b/js/caseInfoGames.js @@ -158,7 +158,7 @@ const getGamesCaseData = async(languageText, server) => { if(target && newValue) _caseInfo = _caseInfo?.replace(new RegExp(target, 'g'), newValue); }); - + _caseInfo = `${_caseInfo?.slice(0, _caseInfo?.search('.\n"lang": {'))}}`; let caseJSON = JSON?.parse(_caseInfo); @@ -242,7 +242,7 @@ const gamesCaseDataCombine = async(caseJSON, languageText, currency) => { const avgPriceText = `${drawsPriceSum == 0 ? 0 : (drawsPriceSum / drawsCount)?.toFixed(2)} ${currency}`; let profitPercentText = `${Math?.round(betterSkinsOdds) || 0}%`; - $('#main-view .container').eq(2) + $('#main-view .container').eq(1) .prepend($(document?.createElement('section')) .addClass('mb-8 py-8') .attr('id', 'caseInfoPanel') diff --git a/js/caseOdds.js b/js/caseOdds.js index 27d1562..864e9a9 100644 --- a/js/caseOdds.js +++ b/js/caseOdds.js @@ -6,10 +6,10 @@ $( document ).ready(async() => { if(!cases?.length) return; waitForElm('section#gold-area').then(async() => { - refreshOdds(config, cases); + refreshOdds(config, cases, true); }); - const observer = new MutationObserver(function () { refreshOdds(config, cases) }); + const observer = new MutationObserver(function () { refreshOdds(config, cases, true) }); function addObserverIfDesiredNodeAvailable() { let panel = document.querySelectorAll(".slider-handles button"); if(!panel?.length) @@ -20,17 +20,22 @@ $( document ).ready(async() => { addObserverIfDesiredNodeAvailable(); }); -const refreshOdds = async(config, cases) => { +const refreshOdds = async(config, cases, init) => { + const index = await getIndexData(); + const currencyRates = index?.currencyRates; + const currency = await getCurrency(); + const currentRate = currencyRates?.filter(el => el?.id == currency)[0]?.rate || 1; + $('section#youtubers-cases div.group.relative')?.attr('case-orginal', 'true'); - await createYTcases(cases); + await createYTcases(currentRate, currency, cases); $('div.relative.grid.transform.grid-cols-1')?.each(function() { - createCaseOdds(cases, this, false); + createCaseOdds(config, currentRate, currency, cases, this, false, init); }); $('div[data-testid="case-card-container"]')?.each(function() { - createCaseOdds(cases, this, true); + createCaseOdds(config, currentRate, currency, cases, this, true, init); }); if(!config?.showAllYoutuberCases) @@ -48,17 +53,18 @@ const refreshOdds = async(config, cases) => { waitForElm('section#favorite').then(() => { $('section#favorite div.relative.grid.transform.grid-cols-1')?.each(function() { - createCaseOdds(cases, this, false); + createCaseOdds(config, currentRate, currency, cases, this, false, init); }); }); } -const createCaseOdds = async(cases, thisElement, eventCase) => { - const caseName = $(thisElement)?.find('div[data-testid=case-card-badge-btn] p')?.text(); +const createCaseOdds = async(config, currentRate, currency, cases, thisElement, eventCase, init) => { + const caseName = $(thisElement)?.find('div[data-testid=case-card-badge-btn] p')?.last()?.text(); if(!caseName) return; let odds; - const thisCase = cases?.filter(el => el?.name == caseName); + const jokerCase = config?.showJokerOdds ? cases?.filter(el => el?.name == `${caseName} JOKER`) : null; + const thisCase = config?.showJokerOdds && jokerCase && jokerCase?.length ? jokerCase : cases?.filter(el => el?.name == caseName); if(!thisCase || !thisCase?.length) return; if (thisCase[0]?.goldProfit !== undefined) { const profit = thisCase[0]?.goldProfit; @@ -87,33 +93,60 @@ const createCaseOdds = async(cases, thisElement, eventCase) => { } else odds = `${thisCase[0]?.odds}%`; - $(thisElement)?.find(eventCase ? 'div[data-testid="case-card-price-btn"]' : 'div.absolute.right-3.rounded.bg-navy-900.px-3.text-xs.font-semibold.text-gold-500') - ?.eq(0)?.after($(document?.createElement('div')) - ?.addClass(eventCase ? 'absolute right-3 top-3 rounded bg-navy-900 px-3 py-1.5 text-xs font-semibold text-white' : 'absolute right-3 rounded bg-navy-900 px-3 py-1.5 text-xs font-semibold text-gold-500') - ?.css({ 'margin-top': eventCase ? '35px' : '45px' }) + const isJoker = thisCase[0]?.name?.endsWith(' JOKER') || false; + const cardEl = $(thisElement)?.find(eventCase ? 'div[data-testid="case-card-price-btn"]' : 'div.absolute.right-3.rounded.bg-navy-900.px-3.text-xs.font-semibold.text-gold-500') + ?.eq(0); + + if (init) + $(cardEl).after($(document?.createElement('div')) + ?.addClass(eventCase ? 'cardOdds absolute right-3 top-3 rounded bg-navy-900 px-3 py-1.5 text-xs font-semibold text-white' : 'cardOdds absolute right-3 rounded bg-navy-900 px-3 py-1.5 text-xs font-semibold text-gold-500') + ?.css({ 'margin-top': eventCase ? '35px' : '45px', 'background': isJoker ? 'rgb(129 72 234)' : 'rgb(23 23 28)' }) ?.text($(thisElement)?.attr('case-orginal') ? odds : (thisCase[0]?.lang || odds)) ); + $(thisElement)?.find('.cardOdds')?.text($(thisElement)?.attr('case-orginal') ? odds : (thisCase[0]?.lang || odds)) + $(thisElement)?.find('.cardOdds')?.css({ 'background': isJoker ? 'rgb(129 72 234)' : 'rgb(23 23 28)' }) + $(thisElement)?.find('div[data-testid=case-card-badge-btn] p') ?.eq(0) ?.removeClass('min-w-[8rem] max-w-full rounded-lg bg-navy-700 p-2 text-center text-sm font-normal uppercase leading-none text-white') ?.html(`

${odds}

${caseName}

`) + + $(thisElement)?.find('[data-testid="case-card-badge-btn"]') + ?.css({ 'background': isJoker ? 'rgb(129 72 234)' : 'rgb(23 23 28)' }) + + $(thisElement)?.find('[data-testid="case-card-price-btn"]') + ?.css({ 'background': isJoker ? 'rgb(129 72 234)' : 'rgb(23 23 28)' }) + + $(thisElement)?.find('div.css-hmmmg1') + ?.css({ 'background': isJoker ? 'rgb(129 72 234)' : 'rgb(23 23 28)' }) + + const formattedPrice = new Intl.NumberFormat('en-US', { + minimumFractionDigits: 2, + maximumFractionDigits: 2, + }).format(thisCase[0]?.price_USD * currentRate); + + const priceText = `${formattedPrice} ${currency}`; + if (isJoker || !init) + $(thisElement)?.find('[data-testid="case-card-price-btn"]') + ?.text(priceText); }; -const createYTcases = async(cases) => { - const YTcases = cases?.filter(el => el?.youtuber ); - +const createYTcases = async(currentRate, currency, cases) => { + + const YTcases = cases?.filter(el => el?.youtuber && !el?.name?.endsWith(' JOKER')); if(!YTcases || !YTcases?.length) return; - const index = await getIndexData(); - const currencyRates = index?.currencyRates; - const currency = await getCurrency(); - const currentRate = currencyRates?.filter(el => el?.id == currency)[0]?.rate || 1; YTcases?.forEach(el => { - const priceText = `${(el?.price_USD * currentRate)?.toFixed(2)} ${currency}`.replace('.',','); + const formattedPrice = new Intl.NumberFormat('en-US', { + minimumFractionDigits: 2, + maximumFractionDigits: 2, + }).format(el?.price_USD * currentRate); + + const priceText = `${formattedPrice} ${currency}`; $('section#youtubers-cases div.grid.gap-6')?.eq(0)?.append($(document.createElement('div')) - ?.addClass("keydrop-plus-ytcases group relative transition-all duration-200 will-change-transform hover:-translate-y-0.5 aspect-[270/375]") - ?.html(``) + ?.addClass("keydrop-plus-ytcases group relative transition-all duration-200 will-change-transform hover:-translate-y-0.5 aspect-[270/375] col-span-2") + ?.html(``) ); }); }; \ No newline at end of file diff --git a/js/freeOpen.js b/js/freeOpen.js index e0e26a6..3677ba6 100644 --- a/js/freeOpen.js +++ b/js/freeOpen.js @@ -103,7 +103,7 @@ const createCaseDropSelection = async(languageText, profitEnable) => { $('#caseInfoPanel') ?.after($(document.createElement('selection')) ?.attr({ id: 'keydrop-plus-free-open' }) - ?.html(`

${languageText?.testDrops}


    ${languageText?.caseCount}: 0${languageText?.caseSum}: 0${languageText?.skinsSum}: 0${profitEnable ? `${languageText?.profit}: 0` : ''}
    `) + ?.html(`

    ${languageText?.testDrops}


      ${languageText?.caseCount}: 0${languageText?.caseSum}: 0${languageText?.skinsSum}: 0${profitEnable ? `${languageText?.profit}: 0` : ''}
      `) ); }; diff --git a/js/freeOpenGames.js b/js/freeOpenGames.js index a1c9f21..53f0316 100644 --- a/js/freeOpenGames.js +++ b/js/freeOpenGames.js @@ -101,7 +101,7 @@ const createGamesCaseDropSelection = async(languageText) => { $('#caseInfoPanel') ?.after($(document.createElement('selection')) ?.attr({ id: 'keydrop-plus-free-open' }) - ?.html(`

      ${languageText?.testDrops}


      ${languageText?.gamesInfo}

        ${languageText?.caseCount}: 0${languageText?.caseSum}: 0${languageText?.skinsSum}: 0${`${languageText?.profit}: 0`}
        `) + ?.html(`

        ${languageText?.testDrops}


        ${languageText?.gamesInfo}

          ${languageText?.caseCount}: 0${languageText?.caseSum}: 0${languageText?.skinsSum}: 0${`${languageText?.profit}: 0`}
          `) ); }; diff --git a/js/giveawayBack.js b/js/giveawayBack.js index c5b5c72..aaf2a03 100644 --- a/js/giveawayBack.js +++ b/js/giveawayBack.js @@ -1,5 +1,5 @@ -waitForElm(`a.button[href="${window?.location?.pathname?.slice(0, 4)}giveaways/"]`).then(() => { - $(`a.button[href="${window?.location?.pathname?.slice(0, 4)}giveaways/"]`).on('click', async() => { +waitForElm(`header.grid.items-center a[data-testid="home-btn"]`).then(() => { + $(`[data-testid="home-btn"]`).on('click', async() => { try { window.open('https://key-drop.com/giveaways/list', '_self'); } catch(e) {}; }); }); \ No newline at end of file diff --git a/js/giveawaysList.js b/js/giveawaysList.js index 7854266..0893408 100644 --- a/js/giveawaysList.js +++ b/js/giveawaysList.js @@ -57,7 +57,7 @@ const createGiveawayListPanel = async() => { endDate: language?.autogiveaway_endDate, }; - $('#main-view div.min-h-screen.pt-4.pb-16 div.container').eq(1) + $('#main-view div.min-h-screen.pb-16 div.container').eq(2) .after($(document.createElement('div')) .addClass('container giveaway-keydropPlus-info') .html(`
          Keydrop Plus

          ${panelText?.settings}

          ${panelText?.settings_p1}

          ${panelText?.settings_a1}

          ${panelText?.settings_p2}: 0

          ${panelText?.settings_a2}

          ${panelText?.settings_p5}: PLN

          ${panelText?.settings_a5}

          ${panelText?.settings_p3}: N/A

          ${panelText?.settings_a3}

          ${panelText?.settings_p4}: N/A

          ${panelText?.settings_a4}${panelText?.settings_desc}

          ${panelText?.history}

          ${panelText?.id}${panelText?.salary}${panelText?.joined2}${panelText?.endDate}
          `) @@ -179,7 +179,7 @@ waitForElm('#main-view div.grid-stack.relative.grid.overflow-hidden:nth-child(4) createCard(); }); -waitForElm('#main-view div.min-h-screen.pt-4.pb-16 div.container').then(() => { +waitForElm('#main-view div.min-h-screen.pb-16 div.container').then(() => { createGiveawayListPanel(); }); diff --git a/js/joinCaseBattle.js b/js/joinCaseBattle.js index 69a41f4..952658f 100644 --- a/js/joinCaseBattle.js +++ b/js/joinCaseBattle.js @@ -21,7 +21,13 @@ const createAutoCaseBattlePanel = async() => { search: language?.autoJoinFreeCaseBattle_search, notFound: language?.autoJoinFreeCaseBattle_notFound, interrupted: language?.autoJoinFreeCaseBattle_interrupted, - caseCount: language?.autoJoinFreeCaseBattle_caseCount + caseCount: language?.autoJoinFreeCaseBattle_caseCount, + + caseMode: language?.autoJoinFreeCaseBattle_caseMode, + solo: language?.autoJoinFreeCaseBattle_solo, + team2v2: language?.autoJoinFreeCaseBattle_team2v2, + team3v3: language?.autoJoinFreeCaseBattle_team3v3, + noCaseMode: language?.autoJoinFreeCaseBattle_noCaseMode }; let cards = ''; @@ -36,16 +42,24 @@ const createAutoCaseBattlePanel = async() => { server?.freeCaseBattle?.forEach(el => { cards += ``; }); - $('main') - .html(`
          ${cards}

          ${languageText?.caseCount}

          ${languageText?.time}

          00:00:00

          ${languageText?.status}

          -

          ${languageText?.synopsis}

          ${languageText?.desc}

          `) - - if(fastCaseBattleConfigData?.players?.includes('2')) $('[name=casePlayers]').eq(0).prop('checked', true); - if(fastCaseBattleConfigData?.players?.includes('3')) $('[name=casePlayers]').eq(1).prop('checked', true); - if(fastCaseBattleConfigData?.players?.includes('4')) $('[name=casePlayers]').eq(2).prop('checked', true); - if(fastCaseBattleConfigData?.minCaseCount == 2) $('[name=caseCount]').eq(1).prop('checked', true); - else if(fastCaseBattleConfigData?.minCaseCount == 3) $('[name=caseCount]').eq(2).prop('checked', true); waitForElm('div.pb-16.pt-4.text-white').then(() => { + $('main') + .html(`
          ${cards}
          ` + + `

          ${languageText?.caseMode}

          ${languageText?.players}

          ${languageText?.caseCount}

          Searching time

          02:17:33

          Status

          Interrupted!
          ` + + `

          ${languageText?.synopsis}

          ${languageText?.desc}

          `) + + if(fastCaseBattleConfigData?.caseMode?.includes('X1')) $('[name=caseMode]').eq(0).prop('checked', true); + if(fastCaseBattleConfigData?.caseMode?.includes('X2')) $('[name=caseMode]').eq(1).prop('checked', true); + if(fastCaseBattleConfigData?.caseMode?.includes('X3')) $('[name=caseMode]').eq(2).prop('checked', true); + + if(fastCaseBattleConfigData?.players?.includes('2')) $('[name=casePlayers]').eq(0).prop('checked', true); + if(fastCaseBattleConfigData?.players?.includes('3')) $('[name=casePlayers]').eq(1).prop('checked', true); + if(fastCaseBattleConfigData?.players?.includes('4')) $('[name=casePlayers]').eq(2).prop('checked', true); + + if(fastCaseBattleConfigData?.minCaseCount == 1) $('[name=caseCount]').eq(0).prop('checked', true); + else if(fastCaseBattleConfigData?.minCaseCount == 2) $('[name=caseCount]').eq(1).prop('checked', true); + $('div.pb-16.pt-4.text-white').remove(); }); }; @@ -55,7 +69,10 @@ const findFreeCaseBattle = async(fastCaseBattleConfig) => { const fetch = await fetchUrl('GET', 'https://key-drop.app/v2/battle?type=active&page=0&priceFrom=0&priceTo=undefined&searchText=&sort=latest&roundsCount=all', null, true); if(!fetch || !fetch?.data) return 'end'; - const filtered = await fetch?.data?.filter(el => el?.status == 'new' && el?.freeBattleTicketCost == 1 && el?.roundsCount >= fastCaseBattleConfig?.minCaseCount && el?.users?.length == 0 && fastCaseBattleConfig?.players?.includes(`${el?.maxUserCount}`) && el?.isFreeBattle == true && (fastCaseBattleConfig?.casesName?.includes(el?.cases[0]?.name) || fastCaseBattleConfig?.casesName?.includes(el?.cases[1]?.name))); + let filtered = await fetch?.data?.filter(el => el?.status == 'new' && el?.roundsCount >= fastCaseBattleConfig?.minCaseCount && el?.users?.length == 0 && el?.isFreeBattle == true && (fastCaseBattleConfig?.casesName?.includes(el?.cases[0]?.name) || fastCaseBattleConfig?.casesName?.includes(el?.cases[1]?.name))); + if(!filtered || filtered?.length <= 0) return; + + filtered = await filtered?.filter(el => fastCaseBattleConfig?.caseMode?.includes(el?.mode) && (el?.mode == "X1" ? fastCaseBattleConfig?.players?.includes(`${el?.maxUserCount}`) : true)); if(!filtered || filtered?.length <= 0) return; if(fastCaseBattleConfig?.minCaseCount == 2) { @@ -111,23 +128,31 @@ let count = 0; function autoJoinCaseBattle() { let casesName = []; let playersNumber = []; + let caseMode = []; const cases = $('[name=caseCard]:checked'); - for(i=0; i { @@ -83,6 +83,7 @@ const getConfigData = async() => { toastSoundEnable_info: true, toastSoundEnable_success: true, toastSoundEnable_warning: true, + showJokerOdds: false, } const refreshedConfigData = await checkToken(storageData || configData); if(refreshedConfigData?.tokenExp && refreshedConfigData?.tokenExp > (new Date().getTime() + tokenExpiresTime)) { @@ -216,14 +217,14 @@ const createToast = async(type, text, urlText, url, altText) => { } catch {}; const toast = await $(document.createElement('div')) - .addClass(`toast toast-keydrop-plus z-[9999] flex w-screen origin-bottom overflow-hidden rounded border-y-2 border-l-2 border-r-4 bg-gradient-to-r py-6 pl-4 pr-14 md:w-auto md:max-w-lg md:origin-top-left border-y-red-500/20 border-l-red-500/20 border-r-red-500 from-[#46212A] via-[#261B21] to-[#18181D]" style="position: fixed; left: 1505px; top: 466px; transition-property: opacity, transform; transition-duration: 200ms;`) + .addClass(`toast toast-keydrop-plus z-[9999] flex w-screen origin-bottom overflow-hidden rounded border-y-2 border-l-2 border-r-4 bg-gradient-to-r py-6 pl-4 md:w-auto md:max-w-lg md:origin-bottom-right border-y-red-400/20 border-l-red-400/20 border-r-red-400 from-[#46212A] via-[#261B21] to-[#18181D]`) .attr({ 'tabindex': -1, 'data-time': new Date().getTime() }) - .css({ 'margin-top': '-10px', width: '495px', scale: '0.8', + .css({ 'margin-top': '-10px', width: '450px', scale: '0.8', 'padding-right': '2rem', 'border-top': `2px solid ${borderColor.split(' ')[0]}`, 'border-left': `2px solid ${borderColor.split(' ')[0]}`, 'border-right': `4px solid ${borderColor.split(' ')[1]}`, 'border-bottom': `2px solid ${borderColor.split(' ')[0]}`, - 'background' : `linear-gradient(90deg, ${borderColor.split(' ')[0]} 49%, rgba(28,28,28,0) 89%)` + 'background' : `linear-gradient(90deg, ${borderColor.split(' ')[0]} 49%, rgba(28 28 28 / 81%) 85%)` }) .html(`
          Keydrop+

          ${altText || langText || errorText} ${urlText || ''}

          `) .click(function() { @@ -295,7 +296,7 @@ const showNav = async() => { await setTimeout(async () => { const server = await getServerData(); $('img[alt="KeyDrop"]') - .attr('src', `${githubUrl}${server?.iconsPath}Keydrop%2B_Icon.svg`) + .attr('src', await changeLogo()) .css({ "animation-name": "show", "filter": "opacity(100)" }) .end(); @@ -318,6 +319,14 @@ const showNav = async() => { }, 1 * 1000); } +const changeLogo = async() => { + const date = new Date(); + const server = await getServerData(); + if (date.getMonth() == 11 && (date.getDate() >= 5 && date.getDate() <= 30)) + return `${githubUrl}${server?.iconsPath}Keydrop%2B_Icon-Christmas.png`; + return `${githubUrl}${server?.iconsPath}Keydrop%2B_Icon.svg`; +}; + createWaterMark(); showNav(); @@ -338,7 +347,7 @@ const verifyUser = async() => { if(!steamId) { $('main') ?.css({ height: "100vh", width: '100vw', margin: 0, color: '#fff', overflow: 'hidden', display: 'flex', 'justify-content': 'center', 'flex-direction': 'column', 'align-items': 'center', position: 'relative', 'background-color': '#181e27', 'background-image': "url('https://github.com/Juzlus/KeydropPlus/blob/main/data/icons/background.png?raw=true')", 'background-size': 'cover', 'background-blend-mode': 'overlay', 'background-repeat': 'no-repeat', 'background-attachment': 'fixed', 'background-position': 'center' }) - ?.html(`

          ${langText?.mainText}

          ${language?.warning_mustLogin}

          ${langText?.info?.split('|')[0]} ${langText?.userName} ${langText?.info?.split('|')[1]} ${langText?.serverName}.

          `) + ?.html(`

          ${langText?.mainText}

          ${language?.warning_mustLogin}

          ${langText?.info?.split('|')[0]} ${langText?.userName} ${langText?.info?.split('|')[1]} ${langText?.serverName}.

          `) return createToast('warning', 'warning_mustLogin'); } diff --git a/js/paymentPromocode.js b/js/paymentPromocode.js index 801090b..52879cb 100644 --- a/js/paymentPromocode.js +++ b/js/paymentPromocode.js @@ -5,31 +5,48 @@ $( document ).ready(async() => { setTimeout(async() => { $('[data-testid="refill-deposit-btn"]')?.on('click', async() => { - waitForElm('[data-testid="deposit-modal-submit-promocode"]').then(()=>{ + waitForElm('[data-testid="deposit-modal-promocode-edit-btn"]').then(()=>{ createPromocodeButton(language?.paymentPromocode_useCode, true); }); }); }, 500); - if(window?.location?.href?.includes('#payment/')) + if(window?.location?.href?.includes('/#/payment/')) createPromocodeButton(language?.paymentPromocode_useCode, true); }); const createPromocodeButton = async(lnagText, isFirst) => { - setTimeout(async() => { - if(isFirst) - $(`li.aspect-\\[5\\/4\\]`)?.on('click', async() => { - createPromocodeButton(lnagText, false); - }); + if(isFirst) + waitForElm('[data-testid="deposit-modal-promocode-edit-btn"]').then(() => { + const panel = document?.querySelector('[data-reach-dialog-content] .grid-stack.grid.h-full'); + const observer = new MutationObserver(async() => createPromocodeButton(lnagText, false)); + if (panel instanceof Node) { + observer.observe(panel, { attributes: true, childList: true }); + } + createPromocodeButton(lnagText, false); + }); + else { + $('[data-testid="deposit-modal-promocode-edit-btn"]')?.on('click', async() => { + waitForElm('[data-testid="deposit-modal-promocode-container"]').then(() => { - $('button.button.button-light-green.h-13.text-lightgreen-100.ml-auto')?.eq(0)?.after($(document.createElement('span')) - ?.addClass('button button-light-green h-13 text-lightgreen-100 sm:min-w-[110px] ml-auto') - ?.css({ 'cursor': 'pointer', 'user-select': 'none' }) - ?.html(`${lnagText}
          JUZLUS
          `) - ?.on('click', async() => { - await fetchUrl('POST', 'https://key-drop.com/en/apiData/Bonus/promocode_activation_code', false, false, { promoCode: 'JUZLUS' }); - window?.location?.reload(); - }) - ); - }, 500); + $('[data-reach-dialog-content] div.flex.justify-between button')?.on('click', async() => { + waitForElm('[data-testid="deposit-modal-promocode-edit-btn"]').then(()=>{ + createPromocodeButton(lnagText, false); + }); + }); + + if (!$('.juzlus-promocode')?.length) + $('[data-testid="deposit-modal-submit-promocode"]')?.eq(0)?.after($(document.createElement('button')) + ?.addClass('button juzlus-promocode button-light-green -ml-8 h-15 text-green-300 disabled:opacity-75 sm:min-w-[120px]') + ?.css({ 'cursor': 'pointer', 'user-select': 'none', 'margin-left': '-10px' }) + ?.html(`${lnagText}
          JUZLUS
          `) + ?.on('click', async() => { + await fetchUrl('POST', 'https://key-drop.com/en/apiData/Bonus/promocode_activation_code', false, false, { promoCode: 'JUZLUS' }); + window?.location?.reload(); + }) + ); + $('strong.text-green').eq(0).text("JUZLUS"); + }); + }); + } }; \ No newline at end of file diff --git a/js/settingsPanel.js b/js/settingsPanel.js index c9ad2ec..2666db6 100644 --- a/js/settingsPanel.js +++ b/js/settingsPanel.js @@ -9,8 +9,8 @@ $( document ).ready(async() => { if(window?.location?.href?.includes('/#keydrop_plus')) $('div#keydrop-plus-modal')?.addClass('is-open'); - $('#close-keydrop-plus-modal').click(function(e) { - if(e?.target?.id == 'close-keydrop-plus-modal') + $('#keydrop-plus-modal').click(function(e) { + if(e?.target?.id == 'close-keydrop-plus-modal' || e?.target?.id == "keydrop-plus-modal") $('#keydrop-plus-modal') .removeClass('is-open'); }); @@ -61,26 +61,31 @@ $( document ).ready(async() => { if(config?.hideLiveDrop) { $('#hideLiveDrop')?.prop('checked', true); - $('div.flex.flex-col.overflow-hidden.bg-darknavy-200.lg\\:flex-row')?.eq(0)?.css('display', 'none'); + waitForElm('div.flex.flex-col.overflow-hidden.bg-navy-900.lg\\:flex-row').then(() => { + if(config?.hideLiveDrop) + $('div.flex.flex-col.overflow-hidden.bg-navy-900.lg\\:flex-row')?.eq(0)?.css('display', 'none'); + }); } $('#hideLiveDrop')?.on('change', function(e) { config.hideLiveDrop = e?.target?.checked; try { chrome.storage.sync.set({ config: config }); } catch(e) {}; - $('div.flex.flex-col.overflow-hidden.bg-darknavy-200.lg\\:flex-row')?.eq(0)?.css('display', e?.target?.checked ? 'none' : 'flex'); + $('div.flex.flex-col.overflow-hidden.bg-navy-900.lg\\:flex-row')?.eq(0)?.css('display', e?.target?.checked ? 'none' : 'flex'); }); if(config?.hideCaseBattle) { $('#hideCaseBattle')?.prop('checked', true); - setTimeout(() => { - $('div#app-root section.container.mb-10')?.eq(0)?.css('display', 'none'); - $('div#caseList-root div.mx-auto.max-w-screen-xxl.xxl\\:px-5')?.eq(0)?.css('margin-top', '50px'); - }, 200); + waitForElm('[data-testid="single-bttl-rounds-counter"]').then(() => { + if(!config?.hideCaseBattle) + return; + $('div#caseList-root div.container.mb-8')?.eq(0)?.css('display', 'none'); + $('div#caseList-root div.mx-auto.max-w-screen-2xl.2xl\\:px-5')?.eq(0)?.css('margin-top', '50px'); + }); } $('#hideCaseBattle')?.on('change', function(e) { config.hideCaseBattle = e?.target?.checked; try { chrome.storage.sync.set({ config: config }); } catch(e) {}; - $('div#app-root section.container.mb-10')?.eq(0)?.css('display', e?.target?.checked ? 'none' : 'block'); - $('div#caseList-root div.mx-auto.max-w-screen-xxl.xxl\\:px-5')?.eq(0)?.css('margin-top', e?.target?.checked ? '50px' : '0px'); + $('div#caseList-root div.container.mb-8')?.eq(0)?.css('display', e?.target?.checked ? 'none' : 'block'); + $('div#caseList-root div.mx-auto.max-w-screen-2xl.2xl\\:px-5')?.eq(0)?.css('margin-top', e?.target?.checked ? '50px' : '0px'); }); if(config?.hideFavourite) { @@ -101,6 +106,20 @@ $( document ).ready(async() => { }, 200); }); + if(config?.showJokerOdds) { + $('#showJokerOdds')?.prop('checked', true); + } + $('#showJokerOdds')?.on('change', async(e) => { + const config = await getConfigData(); + const casesFetch = await fetchUrl('GET', `${githubUrl}/cases.json`) + if(!casesFetch || !config) return; + const cases = JSON.parse(`{"cases": ${casesFetch}}`)?.cases; + if(!cases?.length) return; + + config.showJokerOdds = e?.target?.checked; + try { chrome.storage.sync.set({ config: config }); refreshOdds(config, cases); } catch(e) {}; + }); + $(`.keydorp-plus-change-language[data-lang="${config?.lang}"]`) ?.css('filter', 'opacity(0.8)'); @@ -135,15 +154,16 @@ const createSettingsPanel = async(config, language, server) => { discord: language?.settingsPanel_discord, findBug: language?.settingsPanel_findBug, by: language?.settingsPanel_by, + joker: language?.settingsPanel_joker, }; const versionNumber = config?.version?.slice(1); $('#app-root')?.before($(document.createElement('div')) ?.attr({ 'id': 'keydrop-plus-modal', 'aria-hidden': 'false' }) - ?.addClass('z-50 modal modal--700') - ?.css({ 'z-index': 99 }) - ?.html(``) + ?.addClass('flex h-fit max-h-full w-full flex-col space-y-2 rounded-2xl bg-navy-800 md:space-y-0.5') + ?.css({ 'z-index': 99, position: 'fixed', background: 'rgb(8 10 13 / 90%)', height: '100%' }) + ?.html(``) ); server?.languages?.forEach(el => { diff --git a/js/skinChanger.js b/js/skinChanger.js index cf191a4..5c79cde 100644 --- a/js/skinChanger.js +++ b/js/skinChanger.js @@ -31,7 +31,7 @@ const refreshPrices = async() => { const skinportMarket = await getStorageData('local', 'skinportMarketJSON'); $('div[data-testid="items-browser-item-card"]') - ?.each(function() { + ?.each(function () { const keydrop_price_text = $(this)?.find('div[data-testid="items-browser-item-price"] div')?.eq(0)?.text().trim() || $(this)?.find('div[data-testid="items-browser-item-price"]')?.eq(0)?.text().trim();; const typeText = $(this)?.find('[data-testid="items-browser-item-condition"]')?.text().trim(); let skinEx = null; @@ -68,6 +68,11 @@ const refreshPrices = async() => { if(!$(this)?.find('.keydrop-price')?.length) $(this)?.find('div[data-testid="items-browser-item-price"]')?.eq(0)?.addClass('keydrop-price flex')?.prepend($(document.createElement('img'))?.addClass('keydrop-price-icon')); + if (!$(this)?.find('div.keydrop_plus_custom_price')?.length) + $(this)?.find('div.flex.w-full.items-center')?.eq(0)?.after($(document?.createElement('div')) + ?.addClass(`keydrop_plus_custom_price`) + ?.css({ position: 'absolute', top: '34px', right: 0 })); + if(skinportMarket?.skins?.length) refreshPriceText(this, skinData, skinportMarket, language, 'skinport', !config?.skinportPrice); @@ -80,7 +85,10 @@ const getCurrencyAndPrice = (text) => { text = text.trim().replace(/ /g, ''); if(text.indexOf(',') != -1 && text.indexOf('.') != -1) - text = text.replace(/\./g, ''); + if (text.indexOf(',') < text.indexOf('.')) + text = text.replace(/,/g, '') + else + text = text.replace(/\./g, ''); else text = text.replace(/,/g, '.'); @@ -140,6 +148,7 @@ const refreshPriceText = async(tihsElement, skinData, market, language, cssName, $(`#refreshButton${cssName?.charAt(0)?.toUpperCase()}${cssName?.slice(1)}`)?.attr('title', `${langText?.currency}${market?.currency || '-'}\n${langText?.refresh}${new Date(parseInt(market?.updateTime)).toLocaleString() || '-'}`) if(skinInfo?.length && currency == market?.currency) { + console.log(skinData?.price_keydrop, skinInfo[0]?.price) if(skinData?.price_keydrop * 1.1 < skinInfo[0]?.price) color = "greenyellow"; else if(skinData?.price_keydrop < skinInfo[0]?.price) @@ -147,11 +156,18 @@ const refreshPriceText = async(tihsElement, skinData, market, language, cssName, } if(!$(tihsElement)?.find(`.${cssName}-price`)?.length) - $(tihsElement)?.find('div.flex.w-full.items-center')?.eq(0)?.after($(document?.createElement('div')) + { + let element = $(tihsElement)?.find('div.keydrop_plus_custom_price')?.eq(0) + let newElement = ($(document?.createElement('div')) ?.addClass(`flex w-full items-center ${cssName}-price-div`) ?.css({ display: hidden ? "none" : "flex" }) ?.html(``) ); + if (cssName == 'steam') + $(element).prepend(newElement); + else + $(element).append(newElement); + } else { $(tihsElement)?.find(`.${cssName}-price a`)?.text(priceText)?.css({ color: color }); $(tihsElement)?.find(`.${cssName}-price-div`)?.css({ display: hidden ? "none" : "flex" }); diff --git a/js/statisticsButton.js b/js/statisticsButton.js index a6c0552..66394cb 100644 --- a/js/statisticsButton.js +++ b/js/statisticsButton.js @@ -20,7 +20,10 @@ const createStatisticsButton = async() => { $('#statistics_button img')?.css('filter', 'invert(99%) sepia(27%) saturate(184%) hue-rotate(127deg) brightness(108%) contrast(100%)'); $('.statistics_container')?.css('display', 'none'); }); - observer.observe(panel, { childList: true }); + try { + observer.observe(panel, { childList: true }); + } + catch {}; }; waitForElm('div[data-testid="user-nav-bar"]').then(() => { diff --git a/manifest.json b/manifest.json index 037f8f8..132ee21 100644 --- a/manifest.json +++ b/manifest.json @@ -1,7 +1,7 @@ { "manifest_version": 3, "name": "Keydrop+ v2", - "version": "2.10", + "version": "2.11", "short_name": "kd+", "author": ["🇯🅤🇿🅛🇺🅢#0420"], "icons": { @@ -54,7 +54,10 @@ }, { "matches": [ - "*://key-drop.com/*/giveaways/user/*" + "*://key-drop.com/*/giveaways", + "*://key-drop.com/*/giveaways/list", + "*://key-drop.com/*/giveaways/user/*", + "*://key-drop.com/*/giveaways/keydrop/*" ], "js": [ "js/giveawayBack.js"