designer icon indicating copy to clipboard operation
designer copied to clipboard

Template Editing

Open justinfagnani opened this issue 8 years ago • 0 comments

Template editing requires some refactoring of bits to allow for synthetic documents to be loaded into the frame, map operations back to the source document, etc. These are prerequisites for Polymer element editing as well.

The general approach will be to introduce a "document editor" concept that will interpret all commands generated by the stage and the DocumentServer. A SimpleHtmlEditor will just pass through commands. A TemplateHtmlEditor will do the correct mapping.

Synthetic documents need to be generated on the server in order to have the same domain as the rest of the project, and so that relative URLs resolve correctly. After initial load, synthetic documents will be modified in place like source documents.

  • [x] Add designer-template-inspector with "Edit Template" button
  • [ ] Add support for edit-template query parameter to project server to generate synthetic document.
  • [ ] Rename designer-ui-editor to designer-html-editor
  • [ ] Move top-level command handling from designer-app to designer-ui-editor
  • [ ] Add SimpleHtmlEditor that handles all commands before passing to designer-document
  • [ ] Add TemplateHtmlEditor to transform commands from synthetic to source documents.

justinfagnani avatar Nov 16 '15 21:11 justinfagnani