GithubHelp home page GithubHelp logo

dashboard-unfucker's Introduction

funky fresh!

dashboard-unfucker's People

Contributors

cortan122 avatar enchanted-sword avatar estecka avatar marcustyphoon avatar twilight-sparkle-irl avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

dashboard-unfucker's Issues

when attempting to load a dashboard url with infinite scrolling disabled, content is rendered for a split second before doing a blackout

title; the script manages scrolling to the next page from the main dash. after a little while the error "Unexpected Application Error!
Node.insertBefore: Child to insert before is not a child of this node" appears. There are other messages, and they all follow the trend of "lu@https://assets.tumblr.com/pop/js/modern/vendor-522962a4.js:22:97411". Not sure if this could be an asset loading error or anything else but yeah.
image

Script causes tumblr to fail to load any posts

Expected behavior

Old tumblr layout is used to load posts as expected

Actual behavior

Old tumblr layout is used, but fails to load posts or recognize that I'm logged in'

Repro steps

  1. Install and enable script
  2. Go to tumblr.com
  3. "Server turned to dust" or something along those lines is displayed. A green log in button is shown where the user profile would be found.

Inconsistent nav element item removal

I noticed this line of code:

$nav.children(":nth-child(2),:nth-child(10),:nth-child(11),:nth-child(12)").remove();`

Unfortunately, we can't rely on element order here, since (for example) I don't have Tumblr Live muted, so I have an extra button after explore. This means that, for me, this removes the settings menu dropdown, which I assume is unintentional.

I think something like this should work:

$nav.children().has('use[href="#managed-icon__explore"], use["href="#managed-icon__live-video"], use[href="#managed-icon__shop"]', use[href="#managed-icon__earth"]).remove();

I can't finish this myself, since I don't have the "get ad-free" icon on my account with the new layout, but I've seen it in screenshots and I assume that's one you probably want to hide!

DMs layout

hello! would it be possible to change the DMs layout to the old one? i haven't seen anyone talk about it but i got an update for them (both mobile and desktop) and it looks like twitter too. i hate it. i miss the old dms. thank you

Option to show dashboard tab bar

For users with accounts new enough to have the "for you" tab as the default (i.e. those made after May 8th, 2023), it's pretty important to be able to access the "following" tab to actually be able to use your dash, so while I don't really know how to do options in a user script it seems important to allow that particular element hide to be disabled in some way!

(Also, I personally use it for the "blog subs" tab, so even though I don't have a new account it's a must have for me.)

Avatars stay blank after a few posts

What it says on the tin.

After three or four posts or so, the places where an avatar should be are left blank. They aren't merely still loading in either, and it's not because one user posts multiple things one after another that the website doesn't care to load in the avatar multiple times.

Issues when searching a tag on v.3.2.2b

In this image, the buttons are missing:
tumblrdashbug
While in this image, the content isn't centered, like I remember it being. The version I downloaded was 3.2.1 at first, so I went to update it because I noticed the option, but it provided similar results. This seems to be what happens most of the time. (I'd prefer it if there was more content presented per row too, but I imagine that's harder to do.)
tumblrdashbug2
I have "hide recommended blogs" unchecked, but otherwise I haven't messed with it at all.

help im a noob

The resource at “https://assets.tumblr.com/pop/src/assets/fonts/favorit/favorit-medium-fbc7316f.woff2” preloaded with link preload was not used within a few seconds. Make sure all attributes of the preload tag are set correctly. dragongirlsnout
The resource at “https://assets.tumblr.com/pop/src/assets/fonts/favorit/favorit-85-cf2f6136.woff2” preloaded with link preload was not used within a few seconds. Make sure all attributes of the preload tag are set correctly. dragongirlsnout
Content-Security-Policy: Ignoring “'unsafe-inline'” within script-src: nonce-source or hash-source specified dragongirlsnout
Content-Security-Policy: The page’s settings blocked the loading of a resource at inline (“script-src”). content.js:64:422
Content-Security-Policy: The page’s settings blocked the loading of a resource at inline (“script-src”). content.js:65:165
Loading failed for the <script> with source “https://s0.wp.com/wp-content/js/bilmur.min.js?m=202333&f=3”. dragongirlsnout:344:3
Cross-Origin Request Blocked: The Same Origin Policy disallows reading the remote resource at https://assets.tumblr.com/pop/js/modern/sentry-579c304a.js. (Reason: CORS request did not succeed). Status code: (null).

<script> source URI is not allowed in this document: “https://assets.tumblr.com/pop/js/modern/sentry-579c304a.js”. dragongirlsnout:1:1 Cross-Origin Request Blocked: The Same Origin Policy disallows reading the remote resource at https://assets.tumblr.com/pop/js/modern/sentry-579c304a.js?1692367142473. (Reason: CORS request did not succeed). Status code: (null). <script> source URI is not allowed in this document: “https://assets.tumblr.com/pop/js/modern/sentry-579c304a.js?1692367142473”. dragongirlsnout:1:1 Cross-Origin Request Blocked: The Same Origin Policy disallows reading the remote resource at https://assets.tumblr.com/pop/js/modern/sentry-579c304a.js?1692367143592. (Reason: CORS request did not succeed). Status code: (null). <script> source URI is not allowed in this document: “https://assets.tumblr.com/pop/js/modern/sentry-579c304a.js?1692367143592”. dragongirlsnout:1:1 ChunkLoadError: Loading chunk 2897 failed after 2 retries. (js/modern/sentry-579c304a.js) j https://assets.tumblr.com/pop/js/modern/runtime-c4dd1a23.js:1 e https://assets.tumblr.com/pop/js/modern/runtime-c4dd1a23.js:1 e https://assets.tumblr.com/pop/js/modern/runtime-c4dd1a23.js:1 e https://assets.tumblr.com/pop/js/modern/runtime-c4dd1a23.js:1 e https://assets.tumblr.com/pop/js/modern/runtime-c4dd1a23.js:1 setTimeout handler*r.e/ https://assets.tumblr.com/pop/js/modern/main-30b6100d.js:136 O https://assets.tumblr.com/pop/js/modern/runtime-c4dd1a23.js:1 https://assets.tumblr.com/pop/js/modern/main-30b6100d.js:136 a https://assets.tumblr.com/pop/js/modern/runtime-c4dd1a23.js:1 https://assets.tumblr.com/pop/js/modern/main-30b6100d.js:1 main-30b6100d.js:136:3171 The resource at “https://assets.tumblr.com/pop/src/assets/fonts/favorit/favorit-medium-fbc7316f.woff2” preloaded with link preload was not used within a few seconds. Make sure all attributes of the preload tag are set correctly. dragongirlsnout The resource at “https://assets.tumblr.com/pop/src/assets/fonts/favorit/favorit-85-cf2f6136.woff2” preloaded with link preload was not used within a few seconds. Make sure all attributes of the preload tag are set correctly. dragongirlsnout ReferenceError: tumblr is not defined page.js line 67 > eval:470:24

Gap between "create post" and actual dashboard contents remain even with "hide dashboard tabs" on

Fairly self-explanatory but um. Just in case, here's an image of the exact thing we're talking about. Checked, and it was not the result of Stylus or some other extension, so... No idea what that's all about?

It's very selective, as sometimes the gap will be present, but sometimes it'll fix itself... And then un-fix itself a few reloads later. Just kinda refresh a bunch and it should crop up eventually.
image

element overlap/off center + own blog icon missing

the "following-for you- your tags- manage..." bar is pushed too far to the right and overlaps with the unfucker menu/ other elements on the right. also my own blog's icon which would be on the left of the new post buttons isn't there
image

dashboard centered to the far far left

i got the latest update and this happens?? the dash board gets centered to far far left of the screen and a bunch of features get obscured, ive attempted messing with the settings but nothing fixes it other than turning off the dashboard unfucker (picture attached)
uh oh

Issue with legacy editor reversion

On version v3.3.0a, the legacy editor is brought back on reblogged posts, but I can't get it to work when making new posts. I've switched the box on and off and reloaded multiple times. I am using Firefox.

Bug Report

Hello! I just installed Version B of your dashboard unfucker, and it works great aside from one small thing. Every time I refresh the page, or close Tumblr and open it in a new tab, all of my chosen settings have been reset (despite all of the boxes I checked off remaining as such) and all of the stuff I chose to hide, like Tumblr live, the shop, etc., just show up all over again. Thank you so much, and have a great rest of your day!
Screenshot 2023-08-18 233943
Screenshot 2023-08-18 234032

Possible inconsistent following-tab-is-default manipulation

Take this with a grain of salt, as I could only test this by commenting a bunch of code (my account that has the "for you" tab as the default doesn't have the vertical navigation layout). But:

  • I observed navigating from a non-dash page to the dash not triggering the re-ordering and navigation. timelineOptionsItemWrapper probably renders a bit late and thus might need a waitFor like the search box.
  • I observed the navigate() firing from a non-default dashboard tab, like if you intentionally go to https://www.tumblr.com/dashboard/hubs to see posts from your tracked tags. It probably should only override the current location if the user is on the default dashboard. (I used if (['/dashboard', '/'].includes(location.pathname)) { } in one of my user scripts: basically just a shortened form of your compare code using some cool array and window.location builtins!)

Blog avatars don't show up on dashboard

this only started happening today (8/22) and idk if it's something to do with this script or tumblr itself but on my dashboard, the icons of blogs i follow no longer appear to the left of posts like normal. (see attachment)
Screen Shot 2023-08-22 at 10 12 41 AM

missing reblog chain

The first three posts on my dash have icons and reblog chain information, and all posts after that are missing those. I saw the previous profile picture issue, which I also have, and appears to coincide with this bug in that posts with profile pictures have reblog chains and posts without pfps do not.

first post:
image
later post:
image

If I click the header of the post and go to the blog, the reblog chain will show up.

this happens in both versions of the script (version A 3.2.4 and version B 3.2.2)

when resizing window, site throws an error and forces reload

title, it turns out the node thing from my earlier issue was from me leaving and re-entering fullscreen on firefox. for convience the error is "Unexpected Application Error!
Node.removeChild: The node to be removed is not a child of this node". I can work around for the time being but it is kinda annoying to have to do

Individual blog menu dropdown disappeared

Previously didn't have this problem, but the dropdown function seems to have disappeared from the blog menu recently (it used to appear next to the organization icon). Without it there's no way I can find to access blog settings/drafts/followers without disabling the script.

Screenshot (2702)

updates after 1.3 not working

on firefox, any version of the script after 1.3 just does not work for me. they install, but nothing gets changed- dash remains on the sidebar, all the layout is the same. i've tried clearing the cache, turning off all my other extensions, and both, to no avail.

Can't see bloggers icons

Can't see the icons of the blogs I follow that are on my dash, which is a new tumblr feature on the new dash

"New XKit" button missing or nonfunctional

I observe that on the initial page load, the legacy XKit button is sometimes missing from the header, and when one soft navigates anywhere, it appears but doesn't do anything when clicked. (The legacy XKit code is kind of poorly written and tries to add the click handler using $("#xkit_button"), but if this userscript runs first and doesn't result in a DOM structure XKit recognizes, the button doesn't get inserted and then $("#xkit_button") matches nothing).

This should be easy to solve: as per https://github.com/new-xkit/XKit/blob/master/Extensions/xkit_preferences.js#L88-L103 (which I wrote, as it happens), either there needs to be a <nav> element somewhere in the header that this script makes so that the vertical nav layout code gets triggered, or there needs to be a <header> element and all of the buttons need a translated menuContainer class so the classic layout code gets triggered. My guess is the first one is easier.

Code suggestion: mouseenter/mouseleave -> :hover

Essentially no benefit to this one, but now that there's a place to put CSS with selectors, the mouseenter/mouseleave handlers should be replaceable with a style rule and another one with :hover!

"Permission denied to access object" when navigating

Whenever I try to navigate to any page on tumblr, or even just hitting the home button to refresh the dashboard, the page blanks out and shows the following text:

Unexpected Application Error!
Permission denied to access object

21669/tY/<@https://assets.tumblr.com/pop/js/modern/main-dd027c03.js:87:639
21669/tX/<@https://assets.tumblr.com/pop/js/modern/main-dd027c03.js:87:3297
46306/n/<@https://assets.tumblr.com/pop/js/modern/main-dd027c03.js:129:328875
sn@https://assets.tumblr.com/pop/js/modern/vendor-a23415fc.js:22:96138
lh@https://assets.tumblr.com/pop/js/modern/vendor-a23415fc.js:22:114163
s9@https://assets.tumblr.com/pop/js/modern/vendor-a23415fc.js:22:108341
ib@https://assets.tumblr.com/pop/js/modern/vendor-a23415fc.js:22:47327
s7@https://assets.tumblr.com/pop/js/modern/vendor-a23415fc.js:22:108716
eU@https://assets.tumblr.com/pop/js/modern/vendor-a23415fc.js:22:15845
nR@https://assets.tumblr.com/pop/js/modern/vendor-a23415fc.js:22:39706
tJ@https://assets.tumblr.com/pop/js/modern/vendor-a23415fc.js:22:24057
tY@https://assets.tumblr.com/pop/js/modern/vendor-a23415fc.js:22:23839

Caret icons incorrectly colored

On a search page:

Looks like the #managed-icon__caret-thin rule needs a parent selector so it only applies to the nav menus/blog menu!

briefly works, then gets wonky

okay my issue is hard to describe with words so im gonna attach a gif and a photo and say what the issue is as it comes up. the following gif is what tumblr looks like upon reload
drPeace
as you can see, it briefly loads the correct layout of the old dashboard, and then changes it into a wide version shortly after. is this a bug, or is this wide version the intended result?
drPeace2
image above depicts the correct layout of the old dash. thanks ✌️

Dark Mode Not Working on Creating a Post

I've turned off everything else so that only the unfucker is running on my browser (latest chrome-) and while using dark mode on the dash and going to make a new text post, the new text window is white, Not grey. when I remove un-fucker, it works as normal - (but I cant cope with the new dash, lol-)

messages don't open unless viewing blog on dashboard

i noticed clicking on a message in my messages list won't actually cause the message to open (whether i have the message redesign enabled or disabled, and whether i'm using the current or reverted dashboard layout). it's only when i click on someone's icon/url to open their blog in dashboard view (tumblr.com/username) that the message window pops up. when i close the blog, the message window disappears as well. messages work normally when i disable tampermonkey.

Room for improvements

Hello there, I've been using this script for a while but I think there should be a room for improvement for the following reasons.
chrome_J40Thw1KQp

  1. The text on recommended blogs is black and isn't visible to the background.
  2. At least make the UI on the right scrollable as well.
  3. Maybe I'd suggest changing the vulgar title to either "Better Tumblr" or "Dashboard Restore" because imagine if I wanted to screencap my tumblr page and post it in front of a Discord server that don't allow swear. Just unfucking fuck fuck fuck.
  4. My chrome version is 115 and Tumblr Unf**ker version is 2.0

Porn Ban Toggle (lazy patch enclosed as proof of concept)

If you recurse through PeeprRoute.initialTimeline, the only thing that causes flagged posts not to show up when browsing someone's blog or looking directly at a URL is a "isNsfw: true" key being set on the specific post. Here's a barebones preview of what you'd have to do to change this — don't add this version, though. The proper way to do it would be to actually parse the initialTimeline object and check specifically on post objects instead of blindly checking every object down the tree for 'isNsfw'.

const updateObject = (old) => {
    let copy = JSON.parse(JSON.stringify(old));
    //console.log(copy)
    for (let i in old) {
        if (typeof old[i] === "object") {
            copy[i] = updateObject(copy[i]);
        } else if (typeof old[i] === "array") {
            copy[i] = copy[i].map(x=>typeof x === "object"?updateObject(x):x)
        } else {
            if(i==='isNsfw') copy['isNsfw'] = false;
        }
    }
    return copy;
};

Object.defineProperty(window, "___INITIAL_STATE___", { // thanks twilight-sparkle-irl!
    set(x) {
        state = x;
    },
    get() {
        try {
            return {
                ...state,
                PeeprRoute: updateObject(state.PeeprRoute),
                obfuscatedFeatures: modifyObfuscatedFeatures(state.obfuscatedFeatures, featureSet)
            };
        } catch (e) {
            console.error("Failed to modify features", e);
        }

It's worth noting that this doesn't work that well and it's probably worth doing some other way, because if you change views it stops being "initial timeline," but I wanted to document that it's possible somewhere.

990px hard crash 2: Electric boogaloo

Likely because of the new tweaks to the sub-navigation menu, the 990px hard crash is once again an issue. I'm currently not sure how to rearrange the menu items without triggering the crash.

Search bar is sometimes not moved

Apparently the search bar loads in way later than the rest of the page? No clue why; it's not like it has to get loaded from a server. But because of this, when I refresh, sometimes the search bar is still in the sidebar instead of in the header.

Could probably solve this with another waiting loop; one can do like:

const waitFor = async selector => {
    let retries = 0;
    while (retries++ < 25 && !$(selector).length) {
        await new Promise(requestAnimationFrame);
    }
}

Or, if one wishes to have the code after using this function never run if it never finds the element in question (this code is probably slightly harder to understand to a reader not familiar with new Promise()):

// recursive
const waitFor = (selector, retried = 0) => new Promise(resolve => {
    $(selector).length
        ? resolve()
        : retried < 25 && requestAnimationFrame(() => waitFor(selector, retried + 1));
});
// not recursive
const waitFor = (selector) => new Promise(async resolve => {
    for (let i = 0; i < 25; i++) {
        if ($(selector).length) {
            resolve();
            break;
        }
        await new Promise(requestAnimationFrame);
    }
});

(I didn't test these snippets; might have typos. Also, the number 25 is completely arbitrary. I put in a counter and saw a single-digit number of requestAnimationFrame loops before the search bar appeared.)

Algorithmic Content Appearing

Using this script is causing Tumblr Live and Recommended Blogs to appear for me, even though I have those things turned off in my account settings and in my XKit Extension that I also use. Here's a screenshot I took of Tumblr Live popping up despite these settings.
Screen Shot 2023-08-18 at 1 28 28 PM

Dashboard Types Menu is Hidden

image
This bar you use to access the seperate dashboards and... whatever settings menu that manage gives you is entirely inacessible with dashboard unfucker.
Since some are still on default for you for some reason, and others who like having access to followed tags, this bar should probably be moved or reimplemented somehow.

Feature or Bug?

I've noticed that sometimes when I or someone else on my dash reblog a post, the username of the person reblogged from doesn't show up in the header of the post. This only really happens when the post is reblogged either directly from the original post or from whoever made the last reblog with text. I can't tell if this is an intentional feature or a glitch, but either way it's a bit buggy, since even if the username doesn't appear, if you aren't following whoever the post was reblogged from, the "Follow" button still shows up.
Screenshot 2023-08-22 110156

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.