• Resolved Rolf Allard van Hagen

    (@ravanh)


    Hi, I just noticed that the style sheet blocks.style.build.css has repeated content. All rules are repeated 10 more times, making it way too large.

    To see what I mean: open the style sheet in a browser and select the first three lines, then ctrl+c, ctrl+f and ctrl+v. The search result will mark 10 more of the exact same CSS?code… You can do this with any random bunch of lines, so I can only conclude it’s repeating itself exactly over and over again.

    By the way, it’s a bit frustrating that stuff like link color is defined in this plugin stylesheet, instead of leaving that up to the theme style.

    For example .ab-text-link:hover{color:inherit;-webkit-box-shadow:0 -2px 0 inset;box-shadow:0 -2px 0 inset;color:#5a3fd6} first sets color:inherit and then color:#5a3fd6 within the same rule. That does not even make sense while overwriting theme styles at the same time!

    And the plugin is less compatible with many themes than it needs to be because of it. Why do that?

    Would it not be better to leave those kind of rules (including the box-shadow stuff) up to the theme style?

Viewing 3 replies - 1 through 3 (of 3 total)
  • Plugin Author atomicblocks

    (@atomicblocks)

    Hi there,

    We’ll take a look at the duplicate styles, that should definitely not be happening.

    As far as the styles, it’s not necessarily as easy as “leave it to the theme!” If left to the theme entirely, you can get very unexpected results. We’re aiming for somewhere between providing a basic design framework and also allowing for customization. I’ve tested the plugin with many themes and can confirm that the blocks work quite well with most.

    Also, keep in mind Atomic Blocks is still in early development, as Gutenberg itself hasn’t even been released yet. What you see in the plugin isn’t set in stone and will likely change with the course of Gutenberg. There are some new methods for styling blocks that will alleviate some of these issues.

    I disagree that the plugin is inherently less compatible because of this. Because theme styles are largely written poorly for themes themselves, it makes styling for them a moving target. The styles might be a little specific for the time being, but this is something we’re currently working on.

    At any rate, we’re very open to your feedback and will be considering this while we work on some more improvements going forward. Thanks for taking the time to send along your thoughts!

    Hi, even though Atomic Blocks is still in the early stages, it’s already a great extension for Gutenberg!

    As far as the styles, it’s not necessarily as easy as “leave it to the theme!” If left to the theme entirely, you can get very unexpected results.

    In case of link color or underline on hover, I’d argue the opposite: results would be as expected (even when not entirely optimal for the block) … but I completely understand your predicament: leaving that kind of styling up to the theme will likely cause many support questions like “why does it not look good” that need a response like “that’s a theme issue” while setting these styles will at least make the blocks look coherent even if not perfectly in match with the rest of the theme…

    Tough call to make!

    Because theme styles are largely written poorly for themes themselves, it makes styling for them a moving target.

    I’d certainly not argue to add specific theme styles trying to work around poorly written themes ??

    Anyway, great work so far!

    Plugin Author atomicblocks

    (@atomicblocks)

    Good thoughts here, I appreciate the follow up. I’ve taken these notes down for some further discussion with the team. Thanks again!

Viewing 3 replies - 1 through 3 (of 3 total)
  • The topic ‘Style sheet contains 11 times the same content’ is closed to new replies.