pass a list to a mixin as a single argument with SASS

后端 未结 6 1084
悲哀的现实
悲哀的现实 2021-01-30 06:35

I like to make mixins with SASS that help me make good cross-browser compatibility. I want to make a mixin that looks like this:

@mixin box-shadow($value) {
             


        
6条回答
  •  灰色年华
    2021-01-30 07:27

    Use string interpolation

    @include box-shadow(#{"inset -2px -2px 2px rgba(0,0,0,0.5), inset 1px 1px 2px rgba(255,255,255,0.5), inset 0px 0px 0px 1px #ff800f"});
    

提交回复
热议问题