{"name":"@aomao/plugin-alignment","version":"2.2.8","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.2.8","@babel/runtime":"^7.13.10"},"gitHead":"52a678f4f6e629447a3fe83637f9a4576fa368c8","description":"对齐方式：左对齐、居中对齐、右对齐、两端对齐","_id":"@aomao/plugin-alignment@2.2.8","_nodeVersion":"12.18.4","_npmVersion":"lerna/4.0.0/node@v12.18.4+x64 (win32)","dist":{"integrity":"sha512-kDhZS75YzypwGoAmav+SsPSvIcaY7AIVVSNExA/jkEocrfNT5xfK0Re6IY7i1NZpkMo4otxU7x9qWl7Kxg0wVA==","shasum":"cd1fa102f0aebdd923adc5ca756fa729466fddf5","tarball":"http://registry-npm.ywwl.com/@aomao/plugin-alignment/download/@aomao/plugin-alignment-2.2.8.tgz","fileCount":7,"unpackedSize":19900,"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v3.0.13\r\nComment: https://openpgpjs.org\r\n\r\nwsFcBAEBCAAQBQJg3TczCRA9TVsSAnZWagAArwUQAKGnzJMFvzOp0tH9yMo5\nxUqKUJEwg3A4ib4p3uVuZIcwAVLshEXOZr13JYheS0ichEd+Ykv2S/O0bUvY\nw4vdbwc2jNMWs+lNfI4PBazV/LIvs66npt/toxfKZpyNZ0iRyP032mDl/xbe\nv4/a6vgj9lhIu4BPxhonDBXjoYubIZKjCrUXdtwfhaowqOLZFu0BYL0IJxyv\nFeeySmAneKPPVqYJJbqp2qMMTskozSZt8kZg0vkS2u00ICTlS6jSQidXK/2I\n2BdS3cx7BIsFhdXZz8I4G7ySH8O7bO3l5IfIUowPDcFu+Tp1m1Sv4KjeeLA9\ncAds2MNuZ7PDZuBviAgZEyp0Aw1nqOTYsXNTMTRcwaBphE2t+S5CVDYLFhfn\nOD0pi0cI+QlPlU1aC56eU/JHcPFT5NGRK8aj4bVAgW+2ywuO83F2Obz6fJqo\nxVvCaC+fBkeGsGY5A/Az5Y9fQa0IXrxkRFSi981HxU4LphLZe4Bo3UvTGYv+\ng76njwp6gDMZJKHE5BWNpwJuReN80cFvjCVJQTpXNP02k3cOZHqPqYZ5bnRi\nboGZGNzykIR8JxLeLe0+eTRpJzVP6iTF1PsxLK8hI4xBR5bhgAc6Ff1kV3+i\neYnyMUsEjnT39Yk/cK/sbFof+2cuOx/dCYXl1SWyghnpp4v4/fPVpeBwgxe5\n4nAu\r\n=0q6p\r\n-----END PGP SIGNATURE-----\r\n","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEUCIQDrfiIckFPcyfkbbghbKsVdLzAo2mqQE5AxSIBgDAzkwgIgMgLZYE8HYvUjW+GEFoivIBNlhr0/1o7C1gw7/xui4p0="}],"size":5070,"noattachment":false,"key":"/@aomao/plugin-alignment/-/@aomao/plugin-alignment-2.2.8.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.2.8_1625110323010_0.28546619547069674"},"_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":1625110323140,"_cnpm_publish_time":1625110323140,"dist-tags":{"latest":"2.10.0"}}