No each variant can be its own CSS file. Just like you have it. For the Ant builds, there is no need to create a SWC in each of the 144 folders. The -theme option will list the path directly to the CSS file. We are currently only creating a SWC for themes/Basic/src/Basic.css because I haven't figured out how to make a CSS file a valid Maven artifact. If you can figure that out, then we won't need to generate 144 new SWCs.
-Alex On 4/9/18, 11:11 AM, "[email protected] on behalf of Carlos Rovira" <[email protected] on behalf of [email protected]> wrote: >Hi Alex, > >2018-04-09 19:37 GMT+02:00 Alex Harui <[email protected]>: > >> Hi Carlos, >> >> Ideally, all variants of the main theme can be expressed in a single CSS >> file. > > >all variants in a single CSS? so you're talking about an huge CSS file >that >will be processed >by the compiler to only strip the needed rules? >mmm...I think that's an alternate approach to how I create it. We could >change it, but: >1) it will make processing times higher by the compiler, since it needs to >deal with a very huge css file >(imagine the size of the final CSS as all components will be >represented...) >2) I think the problem continues there, since instead of build 144 tiny >projects will have to compile 4 huge projects, >but at the end the time is mostly the same, but for time invested in >created 144 SWCs vs 4 SWCs.. > >for now we are doing the same as MDL themes since those are regenerated >CSS >files. >But we have a difference due to our nature. They are plain CSS while we >are >a compilation technology, and our >themes can have for example View classes that will modify final code if >used using View classes instead of the current ones >in (for example) a library. > > >> I would hope you would be willing to make trade-offs to make that >> so. I think the main theme can be a SWC and contain assets only used >>by a >> single variant. Sort of like a central library. Then the variant's CSS >> would describe new CSS and new URLs for assets from the main theme SWC. >> > >I think it's already as you describe. >Primary themes are "main theme" (light or dark) plus a primary color >(blue, >red,...) >But we have 4 variations, light-dark-flat-no flat (so light-flat, >light-noflat, dark-flat and dark-noflat) >then I separate secondary and emphasized in separate libraries so users >can >combine it as they need. >For example Adobe would want to use red colors, while we at Codeoscopic >yellows or in our Avant blue-green >the "central library" concept is what we are offering to our users, themes >that are ready out of the box. >you can as well use JewelTheme as only theme configuring the variables in >_theme.sass file but you'll need to compile it >This is what I use while developing > > >> >> IOW, blueIcon and redIcon would be in JewelTheme.SWC. And JewelBlue.css >> would reference blueIcon.png. >> > >images are inline SVGs code since I'm using variable substitution to >change >the color of an icon to match the theme color >(see checkbox or radio button as and example), I tried lots of things and >see this is the best method (similar to what MDL does) > > >> >> Then it would be a rare case that a variant theme needs to be part of >>the >> build (assuming we can figure out how to make a single CSS file a Maven >> artifact). > > >As I said, right now is a rare case, since I'm the only one working on >this. Maybe for a month or so >we'll be lots of CSS changes as Jewel grows, but at some point, with Jewel >and Themes more stable, will see less changes. >But again, I'm not in favor of single CSS artifacts, but single SWC >artifacts, the same we had in flex. >Think that at some point we'll we want to make SWF version of Jewel (I >hope >so), and that would mean more AS3 classes >in a .SWC library. > > >> Then it wouldn't be like the examples folder. And if you need >> to run Maven deploy on those CSS files, I think that could also be in a >> Maven profile and only run when you need it. >> > >I'm thinking of this and maybe we should maintain as it's now. >People in our team working with Maven (not me), can build once and then >build from "projects" folder to skip theme build >but a first time they should build all, not like in examples that's >totally >optional. > >That's my latest vision on this, but since this is new code, let's see how >we deal with this in the next hours to see if this method > settled or not... > >> >> Of course, I could be wrong... >> -Alex >> >> On 4/9/18, 10:25 AM, "[email protected] on behalf of Carlos >>Rovira" >> <[email protected] on behalf of [email protected]> wrote: >> >> >Hi Alex, >> > >> >not sure if we are talking about the same problem. I think 1 CSS - 1 >> >project theme relation is ok. maybe as I progress with jewel and its >> >themes >> >we would need to put some code or assets, and so it's ok to have that >> >structure. In the other hand, I choose to break a theme in three pieces >> >(themes) so people could combine it. so as well is ok to me. >> > >> >the main problem I arise here is about compilation times due to lots of >> >themes begin added to the build. >> >and that maybe we don't need to have themes wired to the build to >> >projects, >> >the same as examples is separated. >> >That's my main point, separate themes in the same way we have examples. >> > >> >The rest for me is optimal >> > >> >To give an example, I just run the SASS compilation only to showcase >> >effects and upload in my latest commit >> > >> >c4b337fb9b7c4d1f1739cb7cfee769e09f24f5a8 (example of batch themes >>update >> >based on SASS compilation) >> > >> >This commit upgrade all CSS to remove the Firefox specific inner >>outline: >> > >> >1) This is optimal since only touching in JewelTheme, we ensure we can >> >easily update the rest of themes >> >2) As I'm the only one working on themes, I can change things and >>commit >> >the final CSS (as the latest commit) so others that doesn't use maven, >>can >> >use directly the final generated CSS. >> >3) All people, using ANT or MAVEN must deal with a theme just like >>other >> >library and must to compile it to a .SWC as we did the same in the Flex >> >world. I don't think a .CSS file alone will be ok, since as I said >>before >> >the theme can be composed of only a .CSS and as well have many other >>files >> >(images, classes, fonts, and more) >> > >> > >> > >> > >> > >> > >> > >> > >> > >> >2018-04-09 17:34 GMT+02:00 Alex Harui <[email protected]>: >> > >> >> Hi Carlos, >> >> >> >> Seems like a separate Maven profile and/or Ant target should run >>SASS to >> >> generate the .css files. There is no requirement from other Royale >>code >> >> for the themes to be built into SWCs. You can specify a .CSS file >>or a >> >> .SWC file as a theme. It is only for Maven that theme CSS files are >> >>built >> >> into SWCs and that is only because I didn't want to take the time to >> >> figure out how to make a CSS file a valid Maven artifact. I still >>don't >> >> want to take that time. Maybe you can figure it out. Then I think >>this >> >> build problem will mostly go away. >> >> >> >> HTH, >> >> -Alex >> >> >> >> On 4/9/18, 7:32 AM, "[email protected] on behalf of Carlos >> Rovira" >> >> <[email protected] on behalf of [email protected]> wrote: >> >> >> >> >Hi, >> >> > >> >> >I just committed first No flat themes in 12 color variations and >>Light >> >>/ >> >> >Dark versions. These are 36 * 2 projects = 72 projects >> >> >Still I must commit the Flat versions this means another 72 theme >> >>projects >> >> >to make a total of 144 project themes >> >> > >> >> >You will use it using picking up 3 of them (Primary, Secondary and >> >> >Emphasized) and normally you'll choose all light/flat, or light/no >> >>flat, >> >> >and so on... (4 options here) >> >> > >> >> >So these means to build 144 projects. In my machine (MacBook Pro >>2014 >> >>i7), >> >> >these means 6 minutes. >> >> > >> >> >So, until now I use to build "royale-asjs", that means all >>"frameworks" >> >> >project that means "projects" and "themes" >> >> > >> >> >Now my plan is to build "royale-asjs", "projects" or "themes" as I >> >>needed, >> >> >and rest of you (not working on themes), should run"royale-asjs" >>when >> >> >needed and most of the time run "projects", to skip overhead of >>build >> >> >themes, since you'll have already the latest CSS that I generate and >> >> >committed. >> >> > >> >> >Another options we can do is make themes separate build from >>framework >> >> >projects the same as "examples" since you mostly will not need to >> >> >regenerate each time all that 144 CSS files. >> >> > >> >> >Let me know what you prefer. >> >> > >> >> >thanks >> >> > >> >> >-- >> >> >Carlos Rovira >> >> >https://na01.safelinks.protection.outlook.com/?url= >> >> http%3A%2F%2Fabout.me%2 >> >> >Fcarlosrovira&data=02%7C01%7Caharui%40adobe.com% >> >> 7Cc79fa77fcb0e4343acef08d5 >> >> >9e26da64%7Cfa7b1b5a7b34438794aed2c178decee1%7C0%7C0% >> >> 7C636588812206485899&s >> >> >data=dcom19OuBTePmd3bDW80UCG0oEtQralxqaS%2Fv4%2BQvSE%3D&reserved=0 >> >> >> >> >> > >> > >> >-- >> >Carlos Rovira >> >https://na01.safelinks.protection.outlook.com/?url= >> http%3A%2F%2Fabout.me%2 >> >Fcarlosrovira&data=02%7C01%7Caharui%40adobe.com% >> 7Cc09d2dcb40724aa07c3708d5 >> >9e3f009d%7Cfa7b1b5a7b34438794aed2c178decee1%7C0%7C0% >> 7C636588915787260209&s >> >data=YTTh8ATPFywv7nEp5%2BLNXFONY1EKPSbWh1qGMPwd8IU%3D&reserved=0 >> >> > > >-- >Carlos Rovira >https://na01.safelinks.protection.outlook.com/?url=http%3A%2F%2Fabout.me%2 >Fcarlosrovira&data=02%7C01%7Caharui%40adobe.com%7C737be13e0fda47d55dfe08d5 >9e45683c%7Cfa7b1b5a7b34438794aed2c178decee1%7C0%7C0%7C636588943304185237&s >data=MckXrAZQXSXIKUOtYBS0Lovw%2BUGMhnK0vTpWuCY7Z8o%3D&reserved=0
