Polymer / designer

Polymer Designer Tool
839 stars 310 forks source link

Template Editing #205

Open justinfagnani opened 8 years ago

justinfagnani commented 8 years ago

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.