chuckh / polymer-quill

Polymer Quill Rich Text Editor
51 stars 29 forks source link

Quill settings and AP are not exposed #3

Open marcelklehr opened 8 years ago

marcelklehr commented 8 years ago

Hi,

According to the docs the only way to interface with quill is to create an instance and read the content property. This is a bit thin.

I would like to supply quill with config options using attributes, get the documented events and methods (or at least access to the original Quill object).

chuckh commented 8 years ago

You should be able to get to the original Quill object by doing this.$.demo1.quill. Assuming you polymer-quill id is demo1.

<polymer-quill id="demo1"
       content='{"ops":[{"insert":"Hello World! - Store as Delta - "},{"attributes":{"link":"//proplanr.com"},"insert":"proplanr.com"},{"attributes":{"header":2},"insert":"\n"}]}'
      store-as="delta">
</polymer-quill>

I have not had any luck yet passing options using attributes. That is why I created toolbar options of full and standard to at least give two choices. I am open to suggestions on how to do so.