Re: [FlexJS] Stuck with Images vía CSS

2016-11-11 Thread Carlos Rovira
Hi Alex, just tracked in JIRA: https://issues.apache.org/jira/browse/FLEX-35172 thanks Carlos El 10 de noviembre de 2016, 17:01, Carlos Rovira < carlos.rov...@codeoscopic.com> escribió: > Ok Thanks! > > El 10 de noviembre de 2016, 16:50, Alex Harui escribió: > >> That's a compiler issue. I w

Re: [FlexJS] Stuck with Images vía CSS

2016-11-10 Thread Carlos Rovira
Ok Thanks! El 10 de noviembre de 2016, 16:50, Alex Harui escribió: > That's a compiler issue. I will take a look today. > > On 11/10/16, 5:07 AM, "carlos.rov...@gmail.com on behalf of Carlos Rovira" > > wrote: > > >Hi Alex, > > > >seems the problem is caused when we have a CSS property with mo

Re: [FlexJS] Stuck with Images vía CSS

2016-11-10 Thread Alex Harui
That's a compiler issue. I will take a look today. On 11/10/16, 5:07 AM, "carlos.rov...@gmail.com on behalf of Carlos Rovira" wrote: >Hi Alex, > >seems the problem is caused when we have a CSS property with more than one >value. If you have color and is #fff all is ok, but if you have backgroun

Re: [FlexJS] Stuck with Images vía CSS

2016-11-10 Thread Carlos Rovira
Hi Alex, seems the problem is caused when we have a CSS property with more than one value. If you have color and is #fff all is ok, but if you have background and instead of only url property you append "center", or more things, then you have a subobject that is not considered. In init method we

Re: [FlexJS] Stuck with Images vía CSS

2016-11-10 Thread Carlos Rovira
Hi Alex, I changed from inline styles to a CSS external file so I have now: .cardTitle { color: #fff; height: 176px; background:url('assets/Unknown.jpg') center / cover; } in the external css file and in mxml I have: The result in the Safari browser console is: this["background"] = [unexpect

Re: [FlexJS] Stuck with Images vía CSS

2016-11-09 Thread Alex Harui
On 11/9/16, 3:38 PM, "carlos.rov...@gmail.com on behalf of Carlos Rovira" wrote: >Now, we have inline styles fixed (and committed it in Chris branch), but >as >I traslated the same example to a css class, I get this: > >this["background"] = [unexpected value type: url('assets/Unknown.jpg'), >"c

Re: [FlexJS] Stuck with Images vía CSS

2016-11-09 Thread Carlos Rovira
Now, we have inline styles fixed (and committed it in Chris branch), but as I traslated the same example to a css class, I get this: this["background"] = [unexpected value type: url('assets/Unknown.jpg'), "center", "/", "cover"]; Unexpected identifier 'value'. Expected either a closing ']' or a '

Re: [FlexJS] Stuck with Images vía CSS

2016-11-09 Thread Carlos Rovira
That was Alex, now Image appears...is the leading space... so we need to trim Thanks! this was really hard to get 2016-11-09 23:54 GMT+01:00 Alex Harui : > > > On 11/9/16, 2:17 PM, "carlos.rov...@gmail.com on behalf of Carlos Rovira" > > wrote: > > >That line is right, if I put trace("styles: "

Re: [FlexJS] Stuck with Images vía CSS

2016-11-09 Thread Alex Harui
On 11/9/16, 2:17 PM, "carlos.rov...@gmail.com on behalf of Carlos Rovira" wrote: >That line is right, if I put trace("styles: " + p + " :: " + value); I get > >"styles: background :: url('assets/Unknown.jpeg') center / cover" > >so right... > >but in the DOM we get: > > > >So the background is

Re: [FlexJS] Stuck with Images vía CSS

2016-11-09 Thread Carlos Rovira
That line is right, if I put trace("styles: " + p + " :: " + value); I get "styles: background :: url('assets/Unknown.jpeg') center / cover" so right... but in the DOM we get: So the background is eliminated... 2016-11-09 23:10 GMT+01:00 Alex Harui : > > > On 11/9/16, 2:02 PM, "carlos.

Re: [FlexJS] Stuck with Images vía CSS

2016-11-09 Thread Alex Harui
On 11/9/16, 2:02 PM, "carlos.rov...@gmail.com on behalf of Carlos Rovira" wrote: >Hi Alex, > >both "parseStyles" and "applyStyles" trace output shows background >property. >But in "getValue" if I check for valueName == "background", I can't get >nothing (I get iBeadModel, iBeadController, width

Re: [FlexJS] Stuck with Images vía CSS

2016-11-09 Thread Carlos Rovira
Hi Alex, both "parseStyles" and "applyStyles" trace output shows background property. But in "getValue" if I check for valueName == "background", I can't get nothing (I get iBeadModel, iBeadController, width, height) I'm very confused about this. from what code are this methods be called? Tha

Re: [FlexJS] Stuck with Images vía CSS

2016-11-09 Thread Alex Harui
On 11/9/16, 10:58 AM, "carlos.rov...@gmail.com on behalf of Carlos Rovira" wrote: >Hi Alex, > >I think I have something, I'll explain later. I need to know how and where >the returning obj is write >I'm getting the "background" property (as I see with a trace) but this >continues to not be writ

Re: [FlexJS] Stuck with Images vía CSS

2016-11-09 Thread Carlos Rovira
Hi Alex, I think I have something, I'll explain later. I need to know how and where the returning obj is write I'm getting the "background" property (as I see with a trace) but this continues to not be write in the resulting HTML, os I think there's a block in the final dump of the obj 2016-11-09

Re: [FlexJS] Stuck with Images vía CSS

2016-11-09 Thread Alex Harui
On 11/9/16, 10:31 AM, "carlos.rov...@gmail.com on behalf of Carlos Rovira" wrote: >Hi Alex, > >maybe you said ";" and you want to say "/", I think the algorithm should >break in: > >parts[0] -> color: #666 >parts[1] -> height: 176px >parts[2] -> background: url('assets/Unknown.jpeg') center / c

Re: [FlexJS] Stuck with Images vía CSS

2016-11-09 Thread Carlos Rovira
Hi Alex, maybe you said ";" and you want to say "/", I think the algorithm should break in: parts[0] -> color: #666 parts[1] -> height: 176px parts[2] -> background: url('assets/Unknown.jpeg') center / cover and then when reach the latest, split in: pieces = ["background", "url('assets/Unknown.

Re: [FlexJS] Stuck with Images vía CSS

2016-11-09 Thread Alex Harui
Hi Carlos, I'm wondering if you get an error without your code in there. It might be that the trailing ';' in the string creates a problem for the algorithm. It might split the parts into 4 parts where the last part is essentially an empty string and thus there is no ':' and so pieces[1] will be

Re: [FlexJS] Stuck with Images vía CSS

2016-11-09 Thread Carlos Rovira
I want that having this line: avoid background property removal. So in this method I added the bold lines: public function parseStyles(styles:String):Object { var obj:Object = {}; var parts:Array = styles.split(";"); for each (var part:String in part

Re: [FlexJS] Stuck with Images vía CSS

2016-11-09 Thread Alex Harui
On 11/9/16, 9:22 AM, "carlos.rov...@gmail.com on behalf of Carlos Rovira" wrote: >Hi Alex, > >I'm trying to do this simple String operation: > >if(value.indexOf("url") >= 0) > obj[pieces[0]] = pieces[1]; > >and browser is reporting this error: > >"TypeError: null is not an object (evaluat

Re: [FlexJS] Stuck with Images vía CSS

2016-11-09 Thread Carlos Rovira
Hi Alex, I'm trying to do this simple String operation: if(value.indexOf("url") >= 0) obj[pieces[0]] = pieces[1]; and browser is reporting this error: "TypeError: null is not an object (evaluating 'value.indexOf')" maybe is something simple I can't see, but I can't see the problem here.

Re: [FlexJS] Stuck with Images vía CSS

2016-11-09 Thread Carlos Rovira
I'll try to see it and report about my findings thanks 2016-11-09 0:04 GMT+01:00 Alex Harui : > > > On 11/8/16, 2:53 PM, "carlos.rov...@gmail.com on behalf of Carlos Rovira" > > wrote: > > >Hi Alex, > > > >I think I only need for now, "background-image" management. > >So could you add the abi

Re: [FlexJS] Stuck with Images vía CSS

2016-11-08 Thread Alex Harui
On 11/8/16, 2:53 PM, "carlos.rov...@gmail.com on behalf of Carlos Rovira" wrote: >Hi Alex, > >I think I only need for now, "background-image" management. >So could you add the ability to not cut this property? >In this way, I could continue my work, and eventually change at some point >for Adva

Re: [FlexJS] Stuck with Images vía CSS

2016-11-08 Thread Carlos Rovira
Hi Alex, I think I only need for now, "background-image" management. So could you add the ability to not cut this property? In this way, I could continue my work, and eventually change at some point for AdvancedCSSValueImpl to make more things Could this be possible? Thanks 2016-11-08 0:36 GM

Re: [FlexJS] Stuck with Images vía CSS

2016-11-07 Thread Alex Harui
On 11/6/16, 12:13 PM, "carlos.rov...@gmail.com on behalf of Carlos Rovira" wrote: >@Alex, thanks for looking into this OK, finally got around to looking into this. The compiler passes the styles into the output JS. But when a component's style property is a String, UIBase tries to have the v

Re: [FlexJS] Stuck with Images vía CSS

2016-11-07 Thread Alex Harui
On 11/7/16, 8:58 AM, "Christofer Dutz" wrote: >I’m totally fine with that too ... makes things a lot easier ;-) >And we don’t even have to switch off the resouce copying from a maven >point of view. The only thing we could require for ant would be for it to >deal with multiple source paths. OK

Re: [FlexJS] Stuck with Images vía CSS

2016-11-07 Thread Christofer Dutz
I’m totally fine with that too ... makes things a lot easier ;-) And we don’t even have to switch off the resouce copying from a maven point of view. The only thing we could require for ant would be for it to deal with multiple source paths. Chris Am 07.11.16, 17:51 schrieb "Josh Tynjala" :

Re: [FlexJS] Stuck with Images vía CSS

2016-11-07 Thread Alex Harui
Thinking about this some more: What really would be the harm if the compiler didn't clean out the output folder? I'm not sure we even need a flag. Most compilers don't clean the output folder. Thoughts? -Alex On 11/7/16, 6:41 AM, "Josh Tynjala" wrote: >A flag that tells the compiler not to d

Re: [FlexJS] Stuck with Images vía CSS

2016-11-07 Thread Josh Tynjala
That sounds even better to me. - Josh On Mon, Nov 7, 2016 at 8:43 AM, Alex Harui wrote: > Thinking about this some more: What really would be the harm if the > compiler didn't clean out the output folder? I'm not sure we even need a > flag. Most compilers don't clean the output folder. > > T

Re: [FlexJS] Stuck with Images vía CSS

2016-11-07 Thread Josh Tynjala
A flag that tells the compiler not to delete the contents of the output directory might be useful for other things too. I've sometimes wanted to copy files there and just leave them instead of recopying every time (or having to write a script to recopy). - Josh On Nov 7, 2016 12:12 AM, "Christofe

Re: [FlexJS] Stuck with Images vía CSS

2016-11-07 Thread Christofer Dutz
Hi Alex, It could, but only by configuring the resources plugin to run in a phase after the compiler which is not the default and looks more like a hack to me. I would like to keep things default as everything else complicates things and could confuse users. Another option would be to set a fl

Re: [FlexJS] Stuck with Images vía CSS

2016-11-06 Thread Alex Harui
Can the resources plugin run after the compiler? -Alex On 11/6/16, 11:04 PM, "Christofer Dutz" wrote: >Hi Carlos, > >I found the cause for the problem. > >The thing is that the resources plugin correctly copies stuff to the >target directory. Unfortunately the first thing the flexjs compiler do

Re: [FlexJS] Stuck with Images vía CSS

2016-11-06 Thread Christofer Dutz
Hi Carlos, I found the cause for the problem. The thing is that the resources plugin correctly copies stuff to the target directory. Unfortunately the first thing the flexjs compiler does is clean the output directory. In order to solve this, I would like to have the clean code separated from t

Re: [FlexJS] Stuck with Images vía CSS

2016-11-06 Thread Carlos Rovira
@Alex, thanks for looking into this @Chris, I tried to copy from commit a07e0a2e34c8b749f9cb3009860a9a3e34942621 ${basedir}/target/javascript/bin/js-debug and org.apache.maven.plugins maven-resources-plugin 3.0.1 ${co

Re: [FlexJS] Stuck with Images vía CSS

2016-11-06 Thread Christofer Dutz
Hi Carlos, have a look at my feature branch where I cleaned up the directory structure of the examples. I also separated the resources and configured the maven-resource-plugin to copy the resources. Unfortunately I am currently not able to build that branch due to some really strange compilatio

Re: [FlexJS] Stuck with Images vía CSS

2016-11-06 Thread Alex Harui
This is next in my queue after I get the MapSearch example running again. Thanks, -Alex On 11/6/16, 3:50 AM, "carlos.rov...@gmail.com on behalf of Carlos Rovira" wrote: >Hi, > >I'm was expending several hours to get FlexJS MDLExample to get images vía >CSS with no luck. > >I think we need to gi

[FlexJS] Stuck with Images vía CSS

2016-11-06 Thread Carlos Rovira
Hi, I'm was expending several hours to get FlexJS MDLExample to get images vía CSS with no luck. I think we need to give some love to CSS image management since this is basic. Not always people should use an Image component to show an image. Some times a Container needs a background image and rig