A plugin to help users edit font sizes in the TUI Editor
Supports editing font sizes in both the Markdown and WYSIWYG modes.
Install this package with the package manager of your choice.
npm install tui-font-size-picker
yarn add tui-font-size-picker
import fontSizePicker from 'tui-font-size-picker';
const fontSizePicker = require('tui-font-size-picker')
To use this in the TUI Editor, it is required to install the TUI Editor or its relevant wrappers (eg React, Vue wrappers) in your project. Then create a new Editor instance and the plugin:
const editor = new Editor({
el: document.querySelector('#editor'),
previewStyle: 'vertical',
height: '500px',
initialEditType: 'markdown',
initialValue: 'Hello!',
plugins: [fontSizePicker] // include the font size picker as a plugin
});
Clone this repository: git clone https://github.com/C-likethis123/tui-font-size-picker
Install dependencies: yarn install
or npm install
To run: yarn serve
or npm run serve
Navigate to localhost:8080/demo/editor.html
to load the demo.