From d5a6c9b90f40c5bdb8e54af3fb15c26a08e3e8d4 Mon Sep 17 00:00:00 2001 From: xiazeyu_2011 Date: Sat, 28 Oct 2017 10:46:21 +0800 Subject: [PATCH] Update READMEs --- readme.md | 22 +++++++++++++--------- readme.zh-CN.md | 39 ++++++++++++++------------------------- 2 files changed, 27 insertions(+), 34 deletions(-) diff --git a/readme.md b/readme.md index 05505fc..1940e59 100644 --- a/readme.md +++ b/readme.md @@ -60,7 +60,6 @@ Add configuration in hexo's `_config.yml` file. ``` yml live2d: model: nipsilon - bottom: -60 ``` > Notes: Option 2 has higher priority, it will overwrite Option 1. @@ -73,15 +72,16 @@ live2d: ## https://github.com/EYHN/hexo-helper-live2d live2d: model: z16 # The model that you are willing to show. default: z16 - height: 300 # The height of your model. default: 300 width: 150 # The width of your model. default: 150 + height: 300 # The height of your model. default: 300 mobileShow: true # Whether to show on mobile devices. default: true - mobileHeight: 150 # The height of your model on mobile devices. default: 75 mobileWidth: 75 # The width of your model on mobile devices. default: 150 - isLeft: false # Whether the model is shown at the left side. default: false + mobileHeight: 150 # The height of your model on mobile devices. default: 75 + position: right # Which side the model is shown at. default: right + horizontalOffset: 0 # The horizontal offset. default: 0 + bottomOffset: -20 # The offset of the bottom. default: -20 className: live2d # The class name of the element. default: live2d id: live2dcanvas # The ID of the live2d element. default: live2dcanvas - bottom: -20 # The offset of the bottom. default: -20 ``` > To use settings in Chinese, please have a look at Chinese document. @@ -106,15 +106,19 @@ live2d: - Unitychan - tororo - hijiki -- `height`: The height of your model. default: 300 + +Attention! **The path of the model's json must be `name/name.model.json`** + - `width`: The width of your model. default: 150 +- `height`: The height of your model. default: 300 - `mobileShow`: Whether to show on mobile devices. default: true - `mobileWidth`: The width of your model on mobile devices. default: 150 - `mobileHeight`: The height of your model on mobile devices. default: 75 -- `isLeft`: Whether the model is shown at the left side. default: false +- `horizontalOffset`: The horizontal offset. default: 0 +- `bottomOffset`: The offset of the bottom. default: -20 +- `position`: `left` or `right` side the model is shown at. default: right - `className`: The class name of the `` element. default: live2d - `id`: The ID of the `` element. default: live2dcanvas -- `bottom`: The offset of the bottom. default: -20 Change this variable to adjust the position of model. @@ -203,7 +207,7 @@ issues: [https://github.com/EYHN/hexo-helper-live2d/issues](https://github.com/E - Only generate selected model(#14) -- Change model selection into json, so that the list won't reset everytime you update. +- [Working]Change model selection into json, so that the list won't reset everytime you update. This verison now isn't fully tested yet, so be carefully. diff --git a/readme.zh-CN.md b/readme.zh-CN.md index 0390b92..924a3e4 100644 --- a/readme.zh-CN.md +++ b/readme.zh-CN.md @@ -62,7 +62,6 @@ swig (next主题): ``` yml live2d: model: nipsilon - bottom: -60 ``` > 第二种配置会覆盖第一种 @@ -75,15 +74,16 @@ live2d: ## https://github.com/EYHN/hexo-helper-live2d live2d: model: z16 # 模型名称 默认值: z16 - height: 300 # 高度 默认值: 300 width: 150 # 宽度 默认值: 150 + height: 300 # 高度 默认值: 300 mobileShow: true # 是否在移动设备上显示 默认值: true - mobileHeight: 150 # 移动设备上的高度 默认值: 150 mobileWidth: 75 # 移动设备上的宽度 默认值: 75 - isLeft: false # 模型是否放置在左侧 默认值: false + mobileHeight: 150 # 移动设备上的高度 默认值: 150 + position: right # 模型左右侧放置位置 默认值: right + horizontalOffset: 0 # 元素的水平偏移 默认值: 0 + bottomOffset: -20 # 元素的底部偏移 默认值: -20 className: live2d # 元素的类名 默认值: live2d id: live2dcanvas # 元素的id 默认值: live2dcanvas - bottom: -20 # 元素的底部偏移 默认值: -20 ``` @@ -108,24 +108,18 @@ live2d: - tororo - hijiki -- `height`: 高度 默认值: 300 +注意! **模型json路径必须为 `name/name.model.json`** - `width`: 宽度 默认值: 150 - +- `height`: 高度 默认值: 300 - `mobileShow`: 是否在移动设备上显示 默认值: true - -- `mobileHeight`: 移动设备上的高度 默认值: 150 - - `mobileWidth`: 移动设备上的宽度 默认值: 75 - -- `isLeft`: 模型是否放置在左侧 默认值: false - +- `mobileHeight`: 移动设备上的高度 默认值: 150 +- `position`: 模型左右侧放置位置 `left` 或 `right` 默认值: false +- `horizontalOffset`: `` 元素的水平偏移 默认值: 0 +- `bottomOffset`: `` 元素的底部偏移 默认值: -20 - `className`: `` 元素的类名 默认值: live2d - - `id`: `` 元素的id 默认值: live2dcanvas - -- `bottom`: `` 元素的底部偏移 默认值: -20 - 如果嫌模型位置不正确 可以调整这个参数 @@ -206,21 +200,16 @@ issues: [https://github.com/EYHN/hexo-helper-live2d/issues](https://github.com/E ## Todo -- [working]增加模型左右设置(#10)(#19)(#21)(#23) - 最简单的修改是在 \node_modules\hexo-helper-live2d\index.js 中的 71 行 right 改为 left - -- [working]增加移动端模型更多功能(#12) - -- 更新英文README +- 更新英文README Settings - 接入每日一句(json) 接入互动对话框(#16) -- 仅生成选择的模型(#14) +- [working]仅生成选择的模型(#14) - 模型列表更改为json(#14) 这样以后插件更新后模型列表不会重置 -可用性与稳定性请大大仔细验证 xiazeyu未经生产环境测试 +可用性与稳定性请大大仔细验证 xiazeyu未经仔细的生产环境测试 觉得可以请等待最终完成然后发布npm新版本