designer
designer copied to clipboard
Template Editing
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
todesigner-html-editor
- [ ] Move top-level command handling from
designer-app
todesigner-ui-editor
- [ ] Add
SimpleHtmlEditor
that handles all commands before passing todesigner-document
- [ ] Add
TemplateHtmlEditor
to transform commands from synthetic to source documents.