perfectionist-plugins 2.4.4 → 2.4.6

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -361,7 +361,6 @@ let topLevelOrder = [];
361
361
  let ownedTopLevelIds = null;
362
362
  let currentChampionId = null;
363
363
  let carouselOrder = [];
364
- let selectedSkinId = null;
365
364
  let failure = null;
366
365
  let requestToken = 0;
367
366
  let refreshTimer = null;
@@ -371,7 +370,6 @@ let selectInFlight = false;
371
370
  let sessionMisses = 0;
372
371
  let championMisses = 0;
373
372
  let renderObserver = null;
374
- const skinSuffixCache = new Map();
375
373
  let removeStyle = null;
376
374
 
377
375
  function logError(scope, error) {
@@ -536,7 +534,6 @@ function nextOwnedSkin(owned, fromId, direction) {
536
534
  }
537
535
 
538
536
  async function selectSkin(skinId) {
539
- selectedSkinId = skinId;
540
537
  selectInFlight = true;
541
538
  const guard = setTimeout(() => {
542
539
  selectInFlight = false;
@@ -556,7 +553,6 @@ function resetState() {
556
553
  topLevelOrder = [];
557
554
  ownedTopLevelIds = null;
558
555
  currentChampionId = null;
559
- selectedSkinId = null;
560
556
  carouselOrder = [];
561
557
  clientSkinOrder = [];
562
558
  failure = null;
@@ -576,7 +572,7 @@ function loadChampion(championId) {
576
572
  const token = ++requestToken;
577
573
 
578
574
  Promise.all([loadOwnedSkins(championId), loadCarouselOrder()]).then(
579
- ([{ owned, order: inventoryOrder, topLevel, ownedTopLevel, entries }, carouselIds]) => {
575
+ ([{ owned, order: inventoryOrder, topLevel, ownedTopLevel }, carouselIds]) => {
580
576
  if (token !== requestToken) return;
581
577
  ownedSkinIds = owned;
582
578
  allSkinIds = new Set(inventoryOrder);
@@ -613,8 +609,6 @@ function updateForSession(session, selection) {
613
609
  if (ownedSkinIds === null) return;
614
610
 
615
611
  const serverSkinId = selection?.selectedSkinId || me.selectedSkinId || null;
616
- const belongsToChampion = serverSkinId !== null && Math.floor(serverSkinId / 1000) === championId;
617
- if (!selectInFlight && belongsToChampion) selectedSkinId = serverSkinId;
618
612
 
619
613
  const knownUnownedSkin = allSkinIds !== null && allSkinIds.has(serverSkinId) && !ownedSkinIds.has(serverSkinId);
620
614
  if (!selectInFlight && knownUnownedSkin) {
@@ -697,7 +691,6 @@ export function init() {
697
691
  name: "Hide Unowned Skins",
698
692
  description: "In champion select, only shows the skins you own for the picked champion.",
699
693
  version,
700
- defaultEnabled: true,
701
694
  onEnable,
702
695
  onDisable,
703
696
  });
@@ -708,4 +701,4 @@ export function init() {
708
701
  } else {
709
702
  addEventListener("perfectionist:utils-ready", (event) => registerWith(event.detail), { once: true });
710
703
  }
711
- }
704
+ }
package/package.json CHANGED
@@ -1,40 +1,40 @@
1
- {
2
- "name": "perfectionist-plugins",
3
- "version": "2.4.4",
4
- "description": "Small plugins that fix the annoying parts of League of Legends champ select. Built for Pengu Loader.",
5
- "type": "module",
6
- "main": "perfectionist-utils.js",
7
- "exports": {
8
- ".": "./perfectionist-utils.js",
9
- "./perfectionist-utils.js": "./perfectionist-utils.js",
10
- "./ban-blocker.js": "./ban-blocker.js",
11
- "./hide-unowned-skins.js": "./hide-unowned-skins.js",
12
- "./unlock-profile-skins.js": "./unlock-profile-skins.js",
13
- "./auto-claimer.js": "./auto-claimer.js",
14
- "./auto-read.js": "./auto-read.js",
15
- "./better-client.js": "./better-client.js",
16
- "./dodge-helper.js": "./dodge-helper.js",
17
- "./auto-accept.js": "./auto-accept.js"
18
- },
19
- "files": [
20
- "perfectionist-utils.js",
21
- "ban-blocker.js",
22
- "hide-unowned-skins.js",
23
- "unlock-profile-skins.js",
24
- "auto-claimer.js",
25
- "auto-read.js",
26
- "better-client.js",
27
- "dodge-helper.js",
28
- "auto-accept.js"
29
- ],
30
- "repository": {
31
- "type": "git",
32
- "url": "git+https://github.com/SrKing-9812/Perfectionist-Plugins.git"
33
- },
34
- "keywords": [
35
- "pengu-loader",
36
- "league-of-legends",
37
- "plugin"
38
- ],
39
- "author": "Sr. King"
40
- }
1
+ {
2
+ "name": "perfectionist-plugins",
3
+ "version": "2.4.6",
4
+ "description": "Small plugins that fix the annoying parts of League of Legends champ select. Built for Pengu Loader.",
5
+ "type": "module",
6
+ "main": "perfectionist-utils.js",
7
+ "exports": {
8
+ ".": "./perfectionist-utils.js",
9
+ "./perfectionist-utils.js": "./perfectionist-utils.js",
10
+ "./ban-blocker.js": "./ban-blocker.js",
11
+ "./hide-unowned-skins.js": "./hide-unowned-skins.js",
12
+ "./unlock-profile-skins.js": "./unlock-profile-skins.js",
13
+ "./auto-claimer.js": "./auto-claimer.js",
14
+ "./auto-read.js": "./auto-read.js",
15
+ "./better-client.js": "./better-client.js",
16
+ "./dodge-helper.js": "./dodge-helper.js",
17
+ "./auto-accept.js": "./auto-accept.js"
18
+ },
19
+ "files": [
20
+ "perfectionist-utils.js",
21
+ "ban-blocker.js",
22
+ "hide-unowned-skins.js",
23
+ "unlock-profile-skins.js",
24
+ "auto-claimer.js",
25
+ "auto-read.js",
26
+ "better-client.js",
27
+ "dodge-helper.js",
28
+ "auto-accept.js"
29
+ ],
30
+ "repository": {
31
+ "type": "git",
32
+ "url": "git+https://github.com/SrKing-9812/Perfectionist-Plugins.git"
33
+ },
34
+ "keywords": [
35
+ "pengu-loader",
36
+ "league-of-legends",
37
+ "plugin"
38
+ ],
39
+ "author": "Sr. King"
40
+ }