column-setter icon indicating copy to clipboard operation
column-setter copied to clipboard

Feature request: expressions in `colspan()` arguments?

Open beep opened this issue 8 years ago • 0 comments

Something that came up when working on the “Get Involved” module: when padding is applied to a container, it adds quite a bit of complexity to inner colspan() calculations. Just e.g.,

.promo-get-involved .brief-thumb {
    float: left;
    width: ( colspan( 1, 4 ) - colspan( p, 4 ) ) + colspan( p, 12 );
    @include breakpoint-range(sm, lg) {
        float: right;
        margin-left: $scale-5;
        width: 25%;
    }
}

One possible solution for this—though probably not the only one!—would be to allow the two colspan() arguments to accept expressions, like so

colspan( 1 - g, 4 - p )

I realize that, uh, would probably get pretty complicated pretty quickly, but thought I’d mention it as a possibility.

beep avatar Jul 21 '17 16:07 beep