• (nodebb)

    I think the loop with the ResourceHelper might be a frist attempt at localization of the month names. Probably not the best way to do it, but not nearly as much of a WTF as the colors.

  • (nodebb)

    I'm with @Dragnslcr on the ResourceHelper stuff, both for what it's trying to be for and for its suboptimality.

    As for the colors stuff, I'm leaning toward it being a way to "pale out" ("grey out" using very pale colours) deactivated/disabled things.

    Note: not a good way of doing that (one should trust the browser to do something intelligent, or if the browser can't be trusted, one should use different CSS style IDs to indicate it(1)...), but just a way.

    (1) And go for reduction-to-more-greyish rather than fade-to-pale, but ...

  • Rob (unregistered) in reply to Dragnslcr

    If this is Java, the best way would be to use DateFormatSymbols (https://docs.oracle.com/en/java/javase/24/docs/api/java.base/java/text/DateFormatSymbols.html). After all, why reinvent the wheel?

  • Jason Stringify (unregistered)

    That doesn't look like JavaScript to me.

  • (nodebb)

    There's the obvious issue of using JavaScript to manage colors

    That's not JavaScript... Probably Java.

  • TrueWill (unregistered)

    Sometimes rockstars just explode.

  • Loren Pechtel (unregistered)

    I agree this is probably Java. Which means no browser to trust to do things. And I agree with Steve that this is greying out stuff, and I'll add that it's probably an afterthought to the original design. Good, no. Horrible, probably not.

  • (nodebb)

    Rock star developers were more rock stars (drinking and partying hard) than developers, which explains everything.

  • (nodebb)

    "After all, why reinvent the wheel?" Because the wheel wasn't invented here of course.

  • (nodebb)

    What's terrifying is that there must be code somewhere that does colors.get("#6699ff") to set something's color.

  • (nodebb)

    The thing that worries me the most is why is there one single object that does some month stuff, gets a bank holiday list, and has a bunch of color conversions? What in the world is this object?

  • (nodebb) in reply to Jason Stringify

    It's Java. Looks like they're generating the list of colors server-side.

  • Bob (unregistered)

    Maybe there is some code somewhere defining styling = { titles: '#6699ff', etc } and then doing colors.get(styling.titles)? People happily worked with the constants on the top layers, and at some stage there was a mixup in the deeper layers. So when they changed the title color to #99ccff, they couldn't change the constants. It would also explain why there is no concern about "applying colors that are not in the table", also avoids the absurdity of something like colors.get("#6699ff").

  • (nodebb) in reply to Rob

    So your code gets published to a world-wide audience, of course. Who cares if it's TDWTF, it's still world-wide audience!

    1. Write rockstar code
    2. Rockstar fan publishes code to world-wide audience.
    3. ?????
    4. Profit!
  • TVJohn (unregistered)

    Maybe he was going for a whiter shade of pale.

  • (nodebb)

    Maybe he was going for a whiter shade of pale.

    Ouch. Well played, sir.

  • Graculus (unregistered) in reply to tom103

    Well its not the Rockstar language for sure

    https://codewithrockstar.com/

Leave a comment on “Off Color”

Log In or post as a guest

Replying to comment #682245:

« Return to Article