Re: SinglePage app design thoughts
I, too recommend valums/file-uplodaer (as Bob said, now called Fine Uploader). In the interest of full disclosure, I should probably mention that I am the maintainer of Fine Uploader. Andrew Valums handed over the project to me (just before the name change) after he realized that he no longer had time to deal with support and evolution of the library. That said, the link to Taha's blog that Bob provided is a good start, but Fine Uploader has evolved quite a bit since that blog post. I've meant to develop a T5 component using Fine Uploader, but I haven't been able to find the time yet as Fine Uploader is quite time consuming. T5 jQuery is also using the same uploader, but it, again, is using a very old version (last time I checked). I should coordinate with Emmanuel Demey and see if he needs assistance upgrading T5 jquery to the newest version of Fine Uploader. There are quite a few new features and countless bugfixes. Regarding the initial topic here, I second the developer who recommended Angular. I've been slowly integrating Angular into one of my projects, and it's quite an amazing library. Definitely a library you should check out if you want to build a single-page app, or even improve a complex page an existing app. -- View this message in context: http://tapestry.1045711.n5.nabble.com/SinglePage-app-design-thoughts-tp5718264p5720091.html Sent from the Tapestry - User mailing list archive at Nabble.com. - To unsubscribe, e-mail: users-unsubscr...@tapestry.apache.org For additional commands, e-mail: users-h...@tapestry.apache.org
Re: PersistenceConstants.FLASH
On Mon, 18 Feb 2013 20:38:03 -0300, John wrote: If a field uses the FLASH persist constant but is not a @Property is it the same as being persisted in the session with plain @Persist because the field is not read by the template directly to take it out of the session? No. @Persist with @Property and @Persist without @Property work absolutely the same. There's absolutely no relationship between @Persist and @Property. Using one won't affect the usage of the other in any way. @Property is just a Tapestry way of having a getter and a setter for a field without you writing them. I'm concerned that my useage below will leave a lot of clutter in the session. @Persist(PersistenceConstants.FLASH) private List venueColleagueBeansFlash; This clutter won't happen. -- Thiago H. de Paula Figueiredo - To unsubscribe, e-mail: users-unsubscr...@tapestry.apache.org For additional commands, e-mail: users-h...@tapestry.apache.org
PersistenceConstants.FLASH
If a field uses the FLASH persist constant but is not a @Property is it the same as being persisted in the session with plain @Persist because the field is not read by the template directly to take it out of the session? I'm concerned that my useage below will leave a lot of clutter in the session. @Persist(PersistenceConstants.FLASH) private List venueColleagueBeansFlash;
Re: Spinner - Prototype to JQuery (ie tapestry5-jquery)
Problem is that I cant switch alias on prototype but I have do it on jquery and that is not the best solution :) -- View this message in context: http://tapestry.1045711.n5.nabble.com/Spinner-Prototype-to-JQuery-ie-tapestry5-jquery-tp5720077p5720087.html Sent from the Tapestry - User mailing list archive at Nabble.com. - To unsubscribe, e-mail: users-unsubscr...@tapestry.apache.org For additional commands, e-mail: users-h...@tapestry.apache.org
Re: Spinner - Prototype to JQuery (ie tapestry5-jquery)
Yea I guess I could try to run Prototype as well. Thought I would be more happy to have only one framework if possible. Thanks for the suggestion will keep it in mind :D -- View this message in context: http://tapestry.1045711.n5.nabble.com/Spinner-Prototype-to-JQuery-ie-tapestry5-jquery-tp5720077p5720086.html Sent from the Tapestry - User mailing list archive at Nabble.com. - To unsubscribe, e-mail: users-unsubscr...@tapestry.apache.org For additional commands, e-mail: users-h...@tapestry.apache.org
how to send a row information in ajaxformloop
I have a ajaxformloop. The list of objects that I want to display has two fields. Both of them are enums and I want to be able to refresh the second enum when I make my selection on the first. For example Field 1 Filed 2 name is startDate before My code looks like Now I have done this before when but not in the ajaxformloop. The problem that I have here is that I have a list of object and I am not sure how I can signal what row is being changed. I have looked at the documentation of the select but I cant find any way to send information about the row in question. If I could send that then I could modify the list. Any suggestions how this can be achieved? cheers -- View this message in context: http://tapestry.1045711.n5.nabble.com/how-to-send-a-row-information-in-ajaxformloop-tp5720085.html Sent from the Tapestry - User mailing list archive at Nabble.com. - To unsubscribe, e-mail: users-unsubscr...@tapestry.apache.org For additional commands, e-mail: users-h...@tapestry.apache.org
Re: SinglePage app design thoughts
For uploading, take a look at http://tapestry5-jquery.com/components/docsajaxupload and http://tawus.wordpress.com/2011/06/25/ajax-upload-for-tapestry/ -- both of which use the highly regarded valums file uploader (now called "Fine Uploader"). On Mon, Feb 18, 2013 at 2:49 PM, bigcache1 wrote: > UPDATE #2 > So I have built a prototype of my single page application. I am using > Tapestry activation context as a router, and it fits into architecture veery > nicely. I have hierarchical content structure there, and I am navigating > across this ocean of content by specifying (by various ways), or not > specifying the id of current folder, or branch if you want. In total, I'm > using 3 parameters for navigation. Later I could provide access for core > developers, to illustrate the idea. Also it is great app for notes, much > simplier and efficient than Evernote. > Recently I've transformed large client JavaScript, into AMD modules, using > requireJS, and it feels so good, to have properly organized heirarchy of > components. Today I'm also using Tapestry5-jQuery. Strange thing -- when I > tried to remove it -- requireJS broke. > I tried to use REST Easy from tynamo, but I have failed to understand how am > I supposed to format JSON, to push it to the server. Will do later, as it is > not critical right now. Today JSON pushing / pulling is done through links. > Can't wait to see official WebSockets support in Tapestry. > Also, I want to implement image uploading by drag and drop. Is there > solutions, to upload file via JS? Will it be simple POST to some link or > REST link? > > > > -- > View this message in context: > http://tapestry.1045711.n5.nabble.com/SinglePage-app-design-thoughts-tp5718264p5720075.html > Sent from the Tapestry - User mailing list archive at Nabble.com. > > - > To unsubscribe, e-mail: users-unsubscr...@tapestry.apache.org > For additional commands, e-mail: users-h...@tapestry.apache.org > - To unsubscribe, e-mail: users-unsubscr...@tapestry.apache.org For additional commands, e-mail: users-h...@tapestry.apache.org
RE: css layout problems, strange runtime behavior - help
So it seems I need to dismantle this thing and take it apart to isolate the trouble
RE: css layout problems, strange runtime behavior - help
Well the css rules came from me and a library I integrated. My custom head component overloads DIV, and other variations of DIV definitions. Here is the output http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd";>http://www.w3.org/1999/xhtml";> html, body { width: auto; margin: 5px; border:0px solid orange; background: #fff url( /tynamo/blob/adminlayout/1/background ) top left repeat; background-attachment:fixed; } div#eventcolumn { position: relative; top: 0; left: 0; float: left; width: 180px; margin: 40px 0 20px 0; padding: 0; display: inline; background-color:rgb(123,223,223); border-top-color: #ccc; border-top-style: solid; border-top-width: 1px; border-right-color: #ccc; border-right-style: solid; border-right-width: 1px; border-bottom-color: #ccc; border-bottom-style: solid; border-bottom-width: 1px; background-color:rgb(123,223,223); border:3px solid red; } div#menubar { align: center; } div#page { width: 96%; margin: 15px; border:2px solid green; background-color:#FFF0F0; } div#header { background-height: auto; margin: 15px; z-index : 50; border:2px solid blue; background: #fff url( /tynamo/blob/adminlayout/1/header ) top left no-repeat; background-size: 100% 100%; } div#content { border:2px solid yellow; } div#footer { width: 95%; margin: 30px 15px 5px 15px; position: relative; border:2px solid orange; } div#splash { border:2px solid white; background: #fff url( /tynamo/blob/adminlayout/1/splash ) top left no-repeat; } blah blah blah
Re: How to command the child component?
On Mon, 18 Feb 2013 18:37:55 -0300, René Bernhardsgrütter wrote: Hi, Hi! in Ninja, you could do something like this @Component Katana katana; You need to use @InjectComponent if you define the component on the template. @Component should only be used when you just use t:id in the template and declare everything else (component type and parameters) in the Java class. -- Thiago H. de Paula Figueiredo - To unsubscribe, e-mail: users-unsubscr...@tapestry.apache.org For additional commands, e-mail: users-h...@tapestry.apache.org
Re: Spinner - Prototype to JQuery (ie tapestry5-jquery)
Why bother converting it? You can run Prototype along with jQuery. On Mon, Feb 18, 2013 at 1:04 PM, Thiago H de Paula Figueiredo < thiag...@gmail.com> wrote: > On Mon, 18 Feb 2013 17:54:25 -0300, bhorvat > wrote: > > Probably not the best place to ask (and probably not the best question as >> well) >> > > Yep, this is really the wrong place to ask. This is completely unrelated > to Tapestry. You'll probably should post this on the jQuery mailing lists > or some site like Stack Overflow. Or maybe just reading the jQuery API > documentation will be enough. > > -- > Thiago H. de Paula Figueiredo > > > --**--**- > To unsubscribe, e-mail: > users-unsubscribe@tapestry.**apache.org > For additional commands, e-mail: users-h...@tapestry.apache.org > >
Re: How to command the child component?
Hi, in Ninja, you could do something like this @Component Katana katana; @Inject AjaxResponseRenderer ajaxResponseRenderer; onActionFromNinjaLink() { ajaxResponseRenderer.addRender(katana.getZone.getClientId(), katana.getZone()); } with a getter in the Katana component that returns the zone. Or, if katana is not in Ninja, via @InjectPage Page pageThatContainsKatana; and then pageThatContainsKatana.getKatana().getZone()... (I don't know if it's possilbe to inject components directly so you don't have to inject the page) > Here ninja is parent, and katana is child, and I want to command as the > parent, saying display. Do you mean parent/child like in class inheritance? Why would you do that? Ninja and Katana are totally different things. Or did I get you somehow wrong? René On 18.02.2013 20:13, bigcache1 wrote: > Metaphorically. I have a component, that displays ninja. When I click on > ninja -- I want to see his katana. > Here ninja is parent, and katana is child, and I want to command as the > parent, saying display. > How could ninja send commands to katana, to fire the zone update in katana? > > Alternative pattern is to host katana component in a special zone in ninja, > and update this special zone. > However, the first pattern seems less complex. > > Simpler version of the question crushes into server to client communication, > I guess. > > Would not it be great, to just call myZone.update()? > > > > -- > View this message in context: > http://tapestry.1045711.n5.nabble.com/How-to-command-the-child-component-tp5720074.html > Sent from the Tapestry - User mailing list archive at Nabble.com. > > - > To unsubscribe, e-mail: users-unsubscr...@tapestry.apache.org > For additional commands, e-mail: users-h...@tapestry.apache.org >
Re: Spinner - Prototype to JQuery (ie tapestry5-jquery)
On Mon, 18 Feb 2013 17:54:25 -0300, bhorvat wrote: Probably not the best place to ask (and probably not the best question as well) Yep, this is really the wrong place to ask. This is completely unrelated to Tapestry. You'll probably should post this on the jQuery mailing lists or some site like Stack Overflow. Or maybe just reading the jQuery API documentation will be enough. -- Thiago H. de Paula Figueiredo - To unsubscribe, e-mail: users-unsubscr...@tapestry.apache.org For additional commands, e-mail: users-h...@tapestry.apache.org
Spinner - Prototype to JQuery (ie tapestry5-jquery)
Probably not the best place to ask (and probably not the best question as well) but I am not that good at jquery so I have no real idea where to start. But does anyone have an idea how to covert // A script that detects when any Form is being submitted or any component issues a request involving a zone. It reacts by overlaying the // zone with a div of class "zone-loading-overlay". The idea is that you should define that class, in css, to display an animated GIF. // // Based on a solution by Howard Lewis Ship at http://tapestryjava.blogspot.co.uk/2011/12/adding-ajax-throbbers-to-zone-updates.html . // Written in Protoype style because Tapestry includes the Protoype library (http://www.prototypejs.org/). Tapestry.onDOMLoaded(function() { function addZoneOverlay(event, element) { var mgr = Tapestry.findZoneManager(element); var zone = mgr && mgr.element; if (!zone) { return; } zone.insert({top:""}); var zoneDims = zone.getDimensions() var overlay = zone.down("div"); overlay.setStyle({ width: zoneDims.width + "px", height: zoneDims.height + "px" }); } // Tell document body to call addAjaxOverlay whenever a Form is submitted or a zone-related form or link is clicked. $(document.body).on(Tapestry.FORM_PROCESS_SUBMIT_EVENT, addZoneOverlay); $(document.body).on(Tapestry.TRIGGER_ZONE_UPDATE_EVENT, addZoneOverlay); }); to jquery??? I really appreciate any input you can share -- View this message in context: http://tapestry.1045711.n5.nabble.com/Spinner-Prototype-to-JQuery-ie-tapestry5-jquery-tp5720077.html Sent from the Tapestry - User mailing list archive at Nabble.com. - To unsubscribe, e-mail: users-unsubscr...@tapestry.apache.org For additional commands, e-mail: users-h...@tapestry.apache.org
Re: How to command the child component?
If you want to update a given zone using JavaScript, you'll need to use something like this: http://jumpstart.doublenegative.com.au/jumpstart/examples/ajax/onevent. var zoneManager = Tapestry.findZoneManagerByZoneId(zoneId); zoneManager.updateFromURL(listenerURIWithValue); On Mon, 18 Feb 2013 16:13:13 -0300, bigcache1 wrote: Metaphorically. I have a component, that displays ninja. When I click on ninja -- I want to see his katana. Here ninja is parent, and katana is child, and I want to command as the parent, saying display. How could ninja send commands to katana, to fire the zone update in katana? I'd keep each component as different templates and JavaScript files and having the child providing some kind of JavaScript API/functions to ask it to do stuff. Components are supposed to be black boxes: the least one needs to know how to use the other, the better. -- Thiago H. de Paula Figueiredo - To unsubscribe, e-mail: users-unsubscr...@tapestry.apache.org For additional commands, e-mail: users-h...@tapestry.apache.org
Re: SinglePage app design thoughts
UPDATE #2 So I have built a prototype of my single page application. I am using Tapestry activation context as a router, and it fits into architecture veery nicely. I have hierarchical content structure there, and I am navigating across this ocean of content by specifying (by various ways), or not specifying the id of current folder, or branch if you want. In total, I'm using 3 parameters for navigation. Later I could provide access for core developers, to illustrate the idea. Also it is great app for notes, much simplier and efficient than Evernote. Recently I've transformed large client JavaScript, into AMD modules, using requireJS, and it feels so good, to have properly organized heirarchy of components. Today I'm also using Tapestry5-jQuery. Strange thing -- when I tried to remove it -- requireJS broke. I tried to use REST Easy from tynamo, but I have failed to understand how am I supposed to format JSON, to push it to the server. Will do later, as it is not critical right now. Today JSON pushing / pulling is done through links. Can't wait to see official WebSockets support in Tapestry. Also, I want to implement image uploading by drag and drop. Is there solutions, to upload file via JS? Will it be simple POST to some link or REST link? -- View this message in context: http://tapestry.1045711.n5.nabble.com/SinglePage-app-design-thoughts-tp5718264p5720075.html Sent from the Tapestry - User mailing list archive at Nabble.com. - To unsubscribe, e-mail: users-unsubscr...@tapestry.apache.org For additional commands, e-mail: users-h...@tapestry.apache.org
How to command the child component?
Metaphorically. I have a component, that displays ninja. When I click on ninja -- I want to see his katana. Here ninja is parent, and katana is child, and I want to command as the parent, saying display. How could ninja send commands to katana, to fire the zone update in katana? Alternative pattern is to host katana component in a special zone in ninja, and update this special zone. However, the first pattern seems less complex. Simpler version of the question crushes into server to client communication, I guess. Would not it be great, to just call myZone.update()? -- View this message in context: http://tapestry.1045711.n5.nabble.com/How-to-command-the-child-component-tp5720074.html Sent from the Tapestry - User mailing list archive at Nabble.com. - To unsubscribe, e-mail: users-unsubscr...@tapestry.apache.org For additional commands, e-mail: users-h...@tapestry.apache.org
Re: css layout problems, strange runtime behavior - help
"Unless your CSS files aren't included or included in the wrong order, this isn't a Tapestry issue at all." Exactly. So the OP needs to find out exactly which CSS rules are being followed, and where they came from... On Mon, Feb 18, 2013 at 9:03 AM, Thiago H de Paula Figueiredo < thiag...@gmail.com> wrote: > On Mon, 18 Feb 2013 13:13:30 -0300, George Ludwig > wrote: > > In CSS, the problem is almost always that some unexpected rule is being >> followed rather than the one you think. I've found Chrome to be an >> invaluable tool in locating the exact source of the CSS rule being >> followed, plus it enables you to play around with >> changing the value. >> > > Firefox add-on Firebug is also very good for this. > > By the way, the original message in this thread seems to be a > misunderstanding of how CSS works. Tapestry doesn't change CSS files: it > just includes them. Unless your CSS files aren't included or included in > the wrong order, this isn't a Tapestry issue at all. > > -- > Thiago H. de Paula Figueiredo > > --**--**- > To unsubscribe, e-mail: > users-unsubscribe@tapestry.**apache.org > For additional commands, e-mail: users-h...@tapestry.apache.org > >
Re: css layout problems, strange runtime behavior - help
On Mon, 18 Feb 2013 13:13:30 -0300, George Ludwig wrote: In CSS, the problem is almost always that some unexpected rule is being followed rather than the one you think. I've found Chrome to be an invaluable tool in locating the exact source of the CSS rule being followed, plus it enables you to play around with changing the value. Firefox add-on Firebug is also very good for this. By the way, the original message in this thread seems to be a misunderstanding of how CSS works. Tapestry doesn't change CSS files: it just includes them. Unless your CSS files aren't included or included in the wrong order, this isn't a Tapestry issue at all. -- Thiago H. de Paula Figueiredo - To unsubscribe, e-mail: users-unsubscr...@tapestry.apache.org For additional commands, e-mail: users-h...@tapestry.apache.org
RE: simple page render
Thanks guys, That was terrific.
Re: Using a modal dialog window for ValidationException?
Hi, i think the only for overring the errors components, is to create a new component ! This component will call a JavaScript method, with all the errors (ValidationTracker.getErrors();), and open the dialog. Manu 2013/2/18 George Ludwig > Is it possible to launch a modal window based on a server event? My first > use case is to deal with a ValidationException. I think it's cleaner to put > up a modal window indicating the exception, rather than using > Tapestry's tag to display it within a form. > > Anyone tried this? > > Best, > > George > -- Emmanuel DEMEY Ingénieur Etude et Développement ATOS Worldline +33 (0)6 47 47 42 02 demey.emman...@gmail.com http://emmanueldemey.fr/ Twitter : @EmmanuelDemey
Re: simple page render
I think you'll actually find Ivan's second suggestion more productive. Each page (tml and empty java class) should take you no more than 60 seconds to create by copying and pasting, and then you'll have a good starting point for fleshing out real functionality later. On Mon, Feb 18, 2013 at 3:00 AM, Ivan Khalopik wrote: > You can create your own component for rendering plain html files. I had > something similar to your issue - source code rendering. > > https://github.com/sody/heroku-samples/blob/master/src/main/java/com/example/ui/components/Source.java > > usage: > > > Or you can convert your html file to tapestry component template and add > empty java class. > > > On Mon, Feb 18, 2013 at 5:07 AM, Ken in Nashua wrote: > >> Folks, >> >> I am prototyping and want to fill in some navigation points with plain >> HTML within a tml... just for temporary sake. I will eventually get to >> these navigation points and implement some real tapestry. >> >> But I have some html files... that I want to render inside some tab control >> >> So I am using this tab control >> > t:mixins="kawwa2/tabs" class="k-tabbed-data"> >> >> Photo Gallery >> Schedule >> Teams >> Stats >> Stanley KEG >> Payment >> DryLand Conditioning >> >> >> >> >> >> >> I have a legacy schedule.html file >> >> is there a tapestry component that will delegate and embed and render my >> html file inside the tab above ? >> >> Something psuedo like this... >> >> >> >> I know its crude but just for proof of concept >> >> Then I could have this... >> >> >> >> >> >> does such a component exist in tapestry? >> >> Just trying to fill in the tabs with some proof of concept stuff too >> >> sorry for such primitive question >> >> kcola...@live.com >> >> >> > > > > > -- > BR > Ivan - To unsubscribe, e-mail: users-unsubscr...@tapestry.apache.org For additional commands, e-mail: users-h...@tapestry.apache.org
Re: simple page render
You can create your own component for rendering plain html files. I had something similar to your issue - source code rendering. https://github.com/sody/heroku-samples/blob/master/src/main/java/com/example/ui/components/Source.java usage: wrote: > Folks, > > I am prototyping and want to fill in some navigation points with plain > HTML within a tml... just for temporary sake. I will eventually get to > these navigation points and implement some real tapestry. > > But I have some html files... that I want to render inside some tab control > > So I am using this tab control > t:mixins="kawwa2/tabs" class="k-tabbed-data"> > > Photo Gallery > Schedule > Teams > Stats > Stanley KEG > Payment > DryLand Conditioning > > > > > > > I have a legacy schedule.html file > > is there a tapestry component that will delegate and embed and render my > html file inside the tab above ? > > Something psuedo like this... > > > > I know its crude but just for proof of concept > > Then I could have this... > > > > > > does such a component exist in tapestry? > > Just trying to fill in the tabs with some proof of concept stuff too > > sorry for such primitive question > > kcola...@live.com > > > -- BR Ivan