this post was submitted on 20 Apr 2024
28 points (91.2% liked)

Web Development

3454 readers
1 users here now

Welcome to the web development community! This is a place to post, discuss, get help about, etc. anything related to web development

What is web development?

Web development is the process of creating websites or web applications

Rules/Guidelines

Related Communities

Wormhole

Some webdev blogsNot sure what to post in here? Want some web development related things to read?

Heres a couple blogs that have web development related content

CreditsIcon base by Delapouite under CC BY 3.0 with modifications to add a gradient

founded 2 years ago
MODERATORS
you are viewing a single comment's thread
view the rest of the comments
[–] [email protected] 8 points 8 months ago (2 children)

The article is very interesting but the fake cursors are infuriating and make it nearly impossible to focus on the content. It's a clever joke but without a way to disable it, the author is just sabotaging his own content.

[–] [email protected] 8 points 8 months ago (2 children)

Huh, I had read this on mobile, where they didn't show up (which I guess, makes sense).

In the HTML, all the way at the bottom, there's a <div id="pointers" ...>, which you can delete to make them disappear...

[–] [email protected] 6 points 8 months ago

This guy webdevs

[–] [email protected] 2 points 8 months ago (1 children)

How does one make this edit permanent? I've been looking to delete the sidebar on fandom, but an adblocker like uBO is not enough, since I need to edit the backgrounds margin. I don't know anything about webdev, and would be grateful for help.

[–] [email protected] 3 points 8 months ago (2 children)

Well, making such a change permanent on a foreign webpage, that's not really something you do in webdev, but I happen to know anyways.
What you want is usually referred to as a "user style" and you can achieve that with e.g. the Stylus extension.

You can create a new style and then paste this into it:

@-moz-document domain("fandom.com") {
    .global-navigation {
        display: none;
    }

    body {
        margin-left: 0 !important;
    }
}

Then save it and fandom.com should look nicer.

If you ignore the first and the last line, these are normal CSS rules, so that is then where webdev knowledge can help...

[–] [email protected] 2 points 8 months ago (1 children)

I don't want to step on any toes but your CSS only works on the home page.

I added more CSS for it to work on the fan pages:

@-moz-document domain("fandom.com") {
    .global-navigation {
        display: none;
    }

    body > .main-container {
        margin-left: 0 !important;
    }

    body {

        margin-left: 0 !important;

        & > .main-container {

            width: 100% !important;

            margin-left: 0 !important;
        }

        & > .fandom-sticky-header {
            left: 0 !important;
        }
    }
}
[–] [email protected] 2 points 8 months ago (1 children)

Ah, absolutely no toes stepped on. I've never used Fandom myself, this was just what I could whip up real quick.

If you happen to use Fandom more often, maybe you'd like to publish this in Stylus? Even if it's just as a personal backup.
I mainly didn't do it, because without me using Fandom, the user style could be broken by tomorrow.

P.S.: I think, the first body > .main-container {-block can be removed, as you set the same style in the nested block underneath...

[–] [email protected] 2 points 8 months ago

Yes, you are correct. Good catch.

    @-moz-document domain("fandom.com") {
        .global-navigation {
            display: none;
        }

        body {
            margin-left: 0 !important;

            & > .main-container {
                width: 100% !important;
                margin-left: 0 !important;
            }

            & > .fandom-sticky-header {
                left: 0 !important;
            }
        }
    }

It was very nice of you to write this out for the other guy. I will look through the uploads and see if anyone else has the same idea.

[–] [email protected] 2 points 8 months ago

Thank you! I had to change "body" to ".main-container" to get it to work, but thank you nonetheless!

[–] [email protected] 1 points 8 months ago

The "dark mode" is even more frustrating.