Headings mixin generates an error #182

marcinkrawiec opened this Issue Mar 19, 2013 · 1 comment

2 participants


The headings mixin seems to be broken (inuit v5.0, fetched yesterday). The following code:

@include headings(1,6) {
    color: #aaa;

generates an error:

error scss/screen.scss (Line 40 of scss/inuit.css/generic/_mixins.scss: Invalid CSS after "": expected selector_comma_sequence, was ", h1, h2, h3, h...")

As you can see there is a comma at the beginning instead of the first heading selector.

Probably it should be something like that:

@mixin headings($from: 1, $to: 6){
    @if $from >= 1 and $to <= 6{
        $heading-selector: (unquote("h#{$from}"));
        @for $i from ($from+1) through $to {
            $heading-selector: $heading-selector, unquote("h#{$i}")

This has been patched in v5.0.1; feel free to copy/paste the changes ahead of time: https://github.com/csswizardry/inuit.css/blob/0c1bcc2d033b28ffb226af42aa6cdbf016d256e7/generic/_mixins.scss#L22-L46

@nicoespeon nicoespeon added a commit to nicoespeon/inuit.css that referenced this issue May 18, 2013
@nicoespeon nicoespeon [refs #182] Use new headings mixin courtesy of @thierrylemoulec
Still commented in LESS
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment