• CrayonRosary@lemmy.world
    link
    fedilink
    English
    arrow-up
    6
    ·
    4 days ago

    They need to fix their mobile website. It has large side margins for no reason, and the comic is tiny. I have to zoom in every time I visit to read the comic. Makes no sense.

    • schnurritoOP
      link
      fedilink
      English
      arrow-up
      4
      ·
      4 days ago

      There is m.xkcd.com but I don’t link to that when I post here, only use it to copy the title text.

      • CrayonRosary@lemmy.world
        link
        fedilink
        English
        arrow-up
        8
        ·
        4 days ago

        In this day and age, the regular site should serve a mobile-friendly page on a phone. There is CSS to detect the browser size and orientation and change the style.

        • thevoidzero@lemmy.world
          link
          fedilink
          English
          arrow-up
          1
          ·
          3 days ago

          Can you do it without loading a bunch of heavy scripts? Making a html responsive is always something challenging I face since I’m not a web developer. I just make htmls when I have to share some data visualization. And I couldn’t find how to make it responsive without using bootstrap, sth-ui, etc and using their classes and scripts.

          I’d love if vanilla CSS just had if statement like thing for “portrait/landscape” or “>threshold/not” for contents width and fonts.

          • Ironfacebuster@lemmy.world
            link
            fedilink
            English
            arrow-up
            7
            ·
            3 days ago

            It actually does, there’s “@media” which lets you query stuff about the browser like if it’s touchscreen vs mouse (and maximum/minimum width/height)

            Example:

            @media screen and (max-width: 1300px) {
                do stuff for screens less than 1300px
            }