Creating an "edit" form in a lightbox/modal window with node.js

I'm somewhat new to Node.js, currently working on an application using node and the Jade templating engine. I'm trying to figure out the best approach to create a lightbox in the interface that allows a user to edit a selected record.

Any advice on how to achieve this:

  1. User accesses a list view page
  2. Clicks edit next to one of the items in the list
  3. Using some sort of javascript, the item ID# is passed into the modal/lightbox window along with default values for form fields, for the edit form in the lightbox. For example, "item name" field is prefilled so they can change it or leave it as is.
  4. When they click submit, the form is posted to the backend function and the ID# in step 3 is passed in as an invisible field.

I can handle the post function and the invisible field thing, just need help with how to render these lightboxes dynamically.

Thanks!

you can use twitter bootstrap to implement the modal window. Its simply awesome and very easy to use.