Skip to content

Extends a textarea that can be controlled by UI elements for inserting markdown

License

Notifications You must be signed in to change notification settings

MaritzSTL/mtz-marked-editor

Repository files navigation

Build Status Published on webcomponents.org

<mtz-marked-editor>

Extends a textarea that can be controlled by UI elements for inserting markdown.

<mtz-marked-editor>
  <div slot="controls">
    <mtz-marked-control-generic-wrap
      icon="editor:format-bold"
      title="Bold"
      syntax-prefix="**"
      syntax-suffix="**"
      keys="ctrl+b"
    ></mtz-marked-control-generic-wrap>
    <mtz-marked-control-generic-wrap
      icon="editor:format-italic"
      title="Italic"
      syntax-prefix="_"
      syntax-suffix="_"
      keys="ctrl+i"
    ></mtz-marked-control-generic-wrap>
    <mtz-marked-control-generic-line
      icon="editor:format-size"
      title="Heading 1"
      syntax-prefix="# "
    ></mtz-marked-control-generic-line>
    <mtz-marked-control-generic-line
      icon="editor:format-list-numbered"
      title="Ordered List"
      syntax-prefix="1. "
    ></mtz-marked-control-generic-line>
    <mtz-marked-control-generic-line
      icon="editor:format-list-bulleted"
      title="Unordered List"
      syntax-prefix="- "
    ></mtz-marked-control-generic-line>
    <mtz-marked-control-link
      icon="editor:insert-link"
      title="Link"
    ></mtz-marked-control-link>
  </div>
  <textarea slot="textarea"></textarea>
</mtz-marked-editor>

Install the Polymer-CLI

First, make sure you have the Polymer CLI installed. Then run polymer serve to serve your element locally.

Viewing Your Element

$ polymer serve

Running Tests

$ polymer test

Your application is already set up to be tested via web-component-tester. Run polymer test to run your application's test suite locally.

About

Extends a textarea that can be controlled by UI elements for inserting markdown

Topics

Resources

License

Stars

Watchers

Forks

Packages

No packages published

Languages