# editorjs-layout

Layout block tool for Editor.js.

Alternative solution: [editorjs-inline](https://github.com/hata6502/editorjs-inline)

### ✨ [Demo](https://hata6502.github.io/editorjs-layout/)

![demo](https://user-images.githubusercontent.com/7702653/105721139-97eb9100-5f67-11eb-8dca-dd4d89314377.gif)

## Install

```bash
$ npm i editorjs-layout
```

or

```html
<script src="https://cdn.jsdelivr.net/npm/editorjs-layout@latest"></script>
```

## Usage

Please see [demo HTML](https://github.com/hata6502/editorjs-layout/blob/main/docs/index.html).

## Config params

Please see type declaration of [LayoutBlockToolConfig](https://github.com/hata6502/editorjs-layout/blob/main/src/LayoutBlockTool.ts).

## Output data

Please see type declaration of [ValidatedLayoutBlockToolData](https://github.com/hata6502/editorjs-layout/blob/main/src/LayoutBlockTool.ts).

## Copied data

Please see type declaration of [LayoutBlockToolData](https://github.com/hata6502/editorjs-layout/blob/main/src/LayoutBlockTool.ts).

NOTE:
Copied block data by `ctrl+c` are not [validated](https://editorjs.io/blockapi#methods).
So copied block data and output block data may be different.
Please see also [this comment](https://github.com/codex-team/editor.js/issues/1280#issuecomment-706482368).

## Disclaimer

The following creations are included in this product:

- [ionic-team/ionicons](https://github.com/ionic-team/ionicons/blob/master/LICENSE)
