{"name":"@aomao/plugin-alignment","version":"2.1.1","main":"dist/index.ts","module":"dist/index.esm.js","typings":"dist/index.d.ts","author":{"name":"me@aomao.com"},"license":"MIT","homepage":"https://github.com/itellyou-com/am-editor#readme","repository":{"type":"git","url":"git+https://github.com/itellyou-com/am-editor.git"},"bugs":{"url":"https://github.com/itellyou-com/am-editor/issues"},"dependencies":{"@aomao/engine":"^2.1.1","@babel/runtime":"^7.13.10"},"gitHead":"496149b6862092134040907b1f01352d394a37c4","description":"对齐方式：左对齐、居中对齐、右对齐、两端对齐","_id":"@aomao/plugin-alignment@2.1.1","_nodeVersion":"14.16.1","_npmVersion":"lerna/3.22.1/node@v14.16.1+x64 (darwin)","dist":{"integrity":"sha512-dWuVDEQhhRSaN12w5zQAanVgxtWqRppMbdsQD5t7hGUd/Yd7JIto3GvTFWdvXvnyewfXztAEovlrG1Hk1idSig==","shasum":"48c8aae4f61af74886444a38cf521833c80207ba","tarball":"http://registry-npm.ywwl.com/@aomao/plugin-alignment/download/@aomao/plugin-alignment-2.1.1.tgz","fileCount":7,"unpackedSize":19385,"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v3.0.13\r\nComment: https://openpgpjs.org\r\n\r\nwsFcBAEBCAAQBQJgrlF5CRA9TVsSAnZWagAARDcP/iaHtBrJZLLrMMBR9a9o\nH7dDMO/WTioUcl8t5AaVoDez6WKIZvTExE9v0STe9Zpf3N3iXY9LcLSfJZPK\nvgy98iW97VB4ws3qSiQUHsNJ9O3f15hoM7+w+nwgkH11KKJMeCCEHwLPc+Af\nYCNlLuOudDXY3ap1xieSTLlgW6BfYHmQzLZBgIHrZ7AziBOPGXcRzaPzuDHO\n90+ET9d7BEDs8+q/qp+K7xCKC5kxLsOX8Kfm1M4zMjCH3npEfUh9nY/4NtFd\nhQFVNtx4dS1MmFGX2iGiiAa72ZuyD2cG7ZRlOruvWlWiKV81Lbc3yki5cDzI\ngV1gFeuq3Dqs4OQEe12mje3Y11tHiSOmOpW6kLZMWp1uZevQLQ3VBvXunWl3\nhWQnzJInukULAqJJZEbOwOHsgMDlhy5iWu9SI7asFmJQCplFRQT9nQgDByiZ\nmNnkJP2itrnEfCy2IsUPs45IC9Q9XbWK74J75hbNCH3gKF5JKEPHOULDqXUN\nas/uOSge0PQytCMBJV6W8dROitZaPb0Bo2Py+5tYRYWDx18BqbU8T2XM9IL+\n4JkpkEjbJGTzxIg3t9lhQfNwwwA1pO3/gliHVnEeGgDn4MKjeaw02/yCUcVd\naB+RMRb9dCmjxOMNZTy9IxQeqzETwLHAZbv+NorTgqNmatsft1J8uyFHAQ2Y\n90RI\r\n=bXyM\r\n-----END PGP SIGNATURE-----\r\n","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEUCIFtgApz/9fFUaYpciy/6DyxpPZIX+v+A1rrOWKKMdZLTAiEArCRrhJhhcmPOcpY49ecOMKbJ2iVybBbnfyGaMDovQQM="}],"size":4978,"noattachment":false,"key":"/@aomao/plugin-alignment/-/@aomao/plugin-alignment-2.1.1.tgz"},"_npmUser":{"name":"aomao","email":"me@aomao.com"},"directories":{},"maintainers":[{"name":"aomao","email":"me@aomao.com"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/plugin-alignment_2.1.1_1622036856744_0.166007086087536"},"_hasShrinkwrap":false,"readme":"# @aomao/plugin-alignment\n\n对齐方式：左对齐、居中对齐、右对齐、两端对齐\n\n## 安装\n\n```bash\n$ yarn add @aomao/plugin-alignment\n```\n\n添加到引擎\n\n```ts\nimport Engine, { EngineInterface } from '@aomao/engine';\nimport Alignment from '@aomao/plugin-alignment';\n\nnew Engine(...,{ plugins:[Alignment] })\n```\n\n## 可选项\n\n```ts\n//快捷键\nhotkey?: {\n    left?: string;//左对齐，默认 mod+shift+l\n    center?: string;//居中对齐，默认 mod+shift+c\n    right?: string;//右对齐，默认 mod+shift+r\n    justify?: string;//两端对齐，默认 mod+shift+j\n};\n//使用配置\nnew Engine(...,{\n    config:{\n        \"alignment\":{\n            //修改 左对齐 快捷键\n            hotkey:{\n                left:\"快捷键\"\n            }\n        }\n    }\n })\n```\n\n## 命令\n\n对齐插件可选参数，`left` | `center` | `right` | `justify`，分别表示 左对齐、居中对齐、右对齐、两端对齐\n\n```ts\n//使用 command 执行插件、并传入所需参数\nengine.command.execute('alignment', 'left' | 'center' | 'right' | 'justify');\n//使用 command 执行查询当前状态，返回 string | undefined，光标所在处节点对齐样式 \"left\" | \"center\" | \"right\" | \"justify\"\nengine.command.queryState('alignment');\n```\n","publish_time":1622036856867,"_cnpm_publish_time":1622036856867,"dist-tags":{"latest":"2.10.0"}}