سؤال

I want to select all buttons with a certain skinClass, I've been trying this but it doesn't work:

s|Button[skinClass="local.MyButtonSkin"]{
    fontWeight: normal;
}

My problem is that I have many buttons with different skins, all of them need to have bold text except one.

How can I select a component by its skinClass?

هل كانت مفيدة؟

المحلول

I don't think it's possible and either way I would do it the other way around: I'd rather select using a styleName and assign the skinClass through CSS:

<s:Button styleName="myButton"/>

CSS

s|Button.myButton{
    fontWeight: normal;
    skinClass: ClassReference("local.MyButtonSkin");
}
مرخصة بموجب: CC-BY-SA مع الإسناد
لا تنتمي إلى StackOverflow
scroll top