1.0.2 • Published 1 year ago

quill-text-indent v1.0.2

Weekly downloads
-
License
MIT
Repository
-
Last release
1 year ago

quill-text-indent

✨ A simple tool for first line indentation in Quill editor.

一个简单 Quill 的首行缩进工具。

Install

NPM

npm install quill-text-indent

Usage

Webpack/ES6

import QuillTextIndent, { QuillTextIndentStyle } from "quill-text-indent";

Quill.register("modules/text-indent", QuillTextIndent);
Quill.register("formats/text-indent", QuillTextIndentStyle);

const toolbarOptions = {
  container: [
    // ...other toolbar item
    ["text-indent"],
  ],
  handlers: { "text-indent": function() {} }
}

const quill = new Quill("#editor", {
    modules: {
        toolbar: toolbarOptions,
        "text-indent": true,
    },
});

Style

// Use when the SVG button has no color.
// 当工具栏 svg 按钮没有选中状态颜色时使用
.ql-first-line-indent.ql-active path {
  fill: #06c;
}
1.0.2

1 year ago

1.0.1

1 year ago

1.0.0

1 year ago