문제

I have a function:

.box-shadow(@bxsh: none) {
    -moz-box-shadow: @bxsh;
    -webkit-box-shadow: @bxsh;
    box-shadow: @bxsh;
}

How to add !important to function parameter? I right this:

.box-shadow(inset 0 0 10px rgba(0,0,0,0.2), 0 1px 0 #fff !important;);

But it doesn't work.

도움이 되었습니까?

해결책

You would want to call the !important keyword after the mixin itsef, as the documentation states.

.box-shadow(inset 0 0 10px rgba(0,0,0,0.2), 0 1px 0 #fff) !important;

Additionally, you are attempting to call a mixin with two parameters, when it only accepts one.

라이센스 : CC-BY-SA ~와 함께 속성
제휴하지 않습니다 StackOverflow
scroll top