flex-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Carlos Rovira <carlos.rov...@codeoscopic.com>
Subject Re: [FlexJS] How to manage className correctly
Date Thu, 10 Nov 2016 21:13:48 GMT
Hi Alex,

I refactored MDL class selectors taking account of this and now is working
ok, so now user can decorate with is own selectors.
I only have one strange issue with a simple color style.

I want to set a color:#fff
If I put in a css class external selector, this is not applied (but rest of
rules works ok).
If I put in inline style, this is working ok.

If you want to see the code is in MDLExample, App.mxml line 117:

<mdl:CardTitle className="cardTitle" style="color: #fff;">.    <-- I need
to set the color here to get text inside this component white, if not it
gets black

The css style is mdl-styles.css

.cardTitle
{
color: #fff;     <--- this rule is not working
height: 176px;
}


Some idea of what could be going here?

Thanks



2016-11-07 6:42 GMT+01:00 Alex Harui <aharui@adobe.com>:

>
>
> On 11/6/16, 3:19 PM, "carlos.rovira@gmail.com on behalf of Carlos Rovira"
> <carlos.rovira@gmail.com on behalf of carlosrovira@apache.org> wrote:
>
> >Hi,
> >
> >className in flexjs translates to class.
> >There's as well typeNames.
> >
> >If I write a component that uses some css class (in its definition), but I
> >want to add some new css rule in app instantiation...what's the
> >recommended
> >way to manage this situation?
> >
> >should I override the className UIBase method? (that's the way I'm
> >thinking
> >right now to use so always reattach the basic css rules needed for the
> >compoenent) or maybe there's some other trick in flexjs arsenal.
>
> I think that's what typeNames is for.  TypeNames should get appended to
> any classNames specified by the developer.
>
> Or maybe I don't understand the scenario.  We could also change they way
> things work now.  My thinking was that typeNames contained the list of
> class selectors that should act like type selectors.  The type selector
> set is not extensible, so typeNames effectively allows specification of
> things that act like type selectors.
>
> HTH,
> -Alex
>
>


-- 

Carlos Rovira
Director General
M: +34 607 22 60 05
http://www.codeoscopic.com
http://www.avant2.es


Este mensaje se dirige exclusivamente a su destinatario y puede contener
información privilegiada o confidencial. Si ha recibido este mensaje por
error, le rogamos que nos lo comunique inmediatamente por esta misma vía y
proceda a su destrucción.

De la vigente Ley Orgánica de Protección de Datos (15/1999), le comunicamos
que sus datos forman parte de un fichero cuyo responsable es CODEOSCOPIC
S.A. La finalidad de dicho tratamiento es facilitar la prestación del
servicio o información solicitados, teniendo usted derecho de acceso,
rectificación, cancelación y oposición de sus datos dirigiéndose a nuestras
oficinas c/ Paseo de la Habana 9-11, 28036, Madrid con la documentación
necesaria.

Mime
  • Unnamed multipart/alternative (inline, None, 0 bytes)
View raw message