campanflaviu / plexius

Plex Web 3.0 Chrome extension for added features https://chrome.google.com/webstore/detail/plexius/cghenlijcboahfbcgiccpnmagdhihiho
MIT License
23 stars 4 forks source link

DOM element watch outdated #7

Closed kev007 closed 7 years ago

kev007 commented 7 years ago

Plex is now obfuscating their classes so pageHeaderToolbar-toolbar- is now something like _3bZbSG _2o14Fw _18RSwsS


The affected code: https://github.com/campanflaviu/plexius/blob/e24ffe7a24317f852013b58c76466b37892bcf2e/js/content.js#L4-L9

var criticRatingRtEl = "div[class^='CriticRating-rt'], div[class*=' CriticRating-rt']";
var titleRatingContainerEl = "div[class^='PrePlayRatingRightTitle-ratingRightTitle-'], div[class*=' PrePlayRatingRightTitle-ratingRightTitle-']";
var titleCriticRatingContainerEl = "span[class^='PrePlayRatingRightTitle-criticRating'], span[class*=' PrePlayRatingRightTitle-criticRating']";
var criticRatingContainerEl = "div[class^='CriticRating-container-'], div[class*=' CriticRating-container-']";
var imdbRatingContainerEl = "div[class^='CriticRating-imdb-'], div[class*=' CriticRating-imdb-']";
var headerToolbarContainerEl = "div[class^='pageHeaderToolbar-toolbar-'], div[class*=' pageHeaderToolbar-toolbar-']";

....

 jQuery(document).arrive(titleRatingContainerEl, {existing: true}, function() {