2012-04-30 5 views
0

私は、既存のバックグラウンド文字列を知らないSASS/Compassのバックグラウンドを追加したいと考えています。私はグローバルなvarに書き込むことで達成することができますが、それはちょっと面倒です。SASS:既存の背景文字列の値を取得して追加しますか?

疑似:

=mixin-add-icon 
    // add a background icon 
=mixin-add-gradient-from-color($color: blue !default) 
    // add a background gradient 
=mixin-add-texture-bg 
    // add a bg texture 

a 
    background: blue 
    +mixin-add-texture-bg 
    // this should take the existing bg and add texture to it 
    &.selected 
    +mixin-add-gradient-from-color() 
    +mixin-add-icon 
     // these two should take the existing bgs strings from <a> and add to them 

私は明らかに何かが足りないのですか?前もって感謝します。

答えて

1

現在Sass経由でオブジェクトのプロパティにアクセスする方法はありませんが、Sassは開いているプロジェクトなので、いつでもデベロッパーにGithub repoでそのような機能が可能かどうか尋ねることができます。

関連する問題