On 10/21/16, 4:35 PM, "carlos.rov...@gmail.com on behalf of Carlos Rovira"
<carlos.rov...@gmail.com on behalf of carlosrov...@apache.org> wrote:

>> Hmm. Why not?  I thought this was a great long-term solution.  You can
>>try
>> different component sets merely by changing URIs.  That's better than
>> changing the js: to mdi: in every file.  How else would you want to do
>>it?
>>
>>
>both are the same, implies make a multifile search/replace in all project.
>while this is possible, I think is not what people could think as the best
>solution.
>For me this way is not solved by technology (FlexJS), and by tooling (your
>text editor or IDE).
>I think the right way would be change the css file by configuration.
>And if you want to switch styles at runtime? Not possible in that
>scenario..

Interesting:  It just occurred to me that Maven can have a really
different workflow than the IDEs.  For IDEs we typically put every SWC in
the library-path.  You can deselect them, at least in FB, but they default
is that they are all available.  In Maven, you could "change the css file
by configuration" just by specifying a different set of SWCs as
dependencies to the project.  I don't know that we'd want to do that to
our IDE users, but maybe.

Here's another idea idea:  what if there was a compiler option that would
override the xmlns in the MXML files?

  mxmlc -compiler.mxml.xmlns=js,library://ns.apache.org/flexjs/mdl



>
>
>Does CSS have a way to do that?  If not, we can cook up something else. We
>> have extended the type selector model.  We could make it possible to set
>> the class in from a TypeSelector.
>>
>>
>If something could be done in the compiler/language space, it would be
>great, since it will
>improve the technology. I think CSS does not has the ability, but I'm not
>a
>guru in CSS and
>I didn't find such way, for that reason I said I think is not possible
>

Just so I'm clear, is your concern that you don't like setting the
className property in ActionScript?  But isn't that essentially how you
would do it in HTML?  IOW, you would open an HTML editor and write:

   <html>
     <body>
        <button class="mdl-button" />

IMO, what we are doing in writing AS components is taking common patterns
from HTML and reproducing them in AS.  So I'm not really sure it is wrong
to be setting className="mdl-button" in the Button.as for the MDL.swc.

Thanks,
-Alex

Reply via email to