From ee13f29230f89341ac4106034b7a760869cbe2aa Mon Sep 17 00:00:00 2001 From: dushusir <1414556676@qq.com> Date: Tue, 19 Jan 2021 09:33:53 +0800 Subject: [PATCH] docs(config): config n --- README-zh.md | 4 +++- README.md | 5 +++-- docs/about/sponsor.md | 1 + docs/guide/config.md | 26 +++++++++++++------------- docs/zh/about/sponsor.md | 3 ++- docs/zh/guide/config.md | 36 ++++++++++++++++++------------------ 6 files changed, 40 insertions(+), 35 deletions(-) diff --git a/README-zh.md b/README-zh.md index bb5fba8..c626467 100644 --- a/README-zh.md +++ b/README-zh.md @@ -64,7 +64,8 @@ ## 📖 学习资源 -社区提供的教程、学习资料及配套解决方案请查阅 [教程与资源](https://mengshukeji.github.io/LuckysheetDocs/zh/guide/resource.html) +- 新用户优先阅读:[用户指引](https://github.com/mengshukeji/Luckysheet/wiki/User-Guide) +- 社区提供的教程、学习资料及配套解决方案请查阅:[教程与资源](https://mengshukeji.github.io/LuckysheetDocs/zh/guide/resource.html) ## 📜 更新日志 @@ -188,6 +189,7 @@ Luckysheet是MIT许可的开源项目,其持续稳定的开发离不开这些 - 曹治军 ¥ 1 - *特 ¥ 10 - **权 ¥ 9.9 +- **sdmq ¥ 20 ## 贡献者和感谢 diff --git a/README.md b/README.md index c19851d..cfa9c29 100644 --- a/README.md +++ b/README.md @@ -57,8 +57,8 @@ English| [简体中文](./README-zh.md) For a more detailed feature list, please refer to: [Features](https://mengshukeji.github.io/LuckysheetDocs/guide/#features) ## 📖 Resources - -For the tutorials, learning materials and supporting solutions provided by the community, please refer to [Tutorials and Resources](https://mengshukeji.github.io/LuckysheetDocs/guide/resource.html) +- Priority reading for new users: [User Guide](https://github.com/mengshukeji/Luckysheet/wiki/User-Guide) +- For the tutorials, learning materials and supporting solutions provided by the community, please refer to: [Tutorials and Resources](https://mengshukeji.github.io/LuckysheetDocs/guide/resource.html) ## 📜 Changelog @@ -173,6 +173,7 @@ Funds donated via Patreon go directly to support mengshukeji's work on Luckyshee - 曹治军 ¥ 1 - *特 ¥ 10 - **权 ¥ 9.9 +- **sdmq ¥ 20 ## Authors and acknowledgment diff --git a/docs/about/sponsor.md b/docs/about/sponsor.md index 6d618a3..ec8597e 100644 --- a/docs/about/sponsor.md +++ b/docs/about/sponsor.md @@ -41,3 +41,4 @@ Funds donated via Patreon go directly to support mengshukeji's work on Luckyshee - 曹治军 ¥ 1 - *特 ¥ 10 - **权 ¥ 9.9 +- **sdmq ¥ 20 diff --git a/docs/guide/config.md b/docs/guide/config.md index 21a7728..f847327 100644 --- a/docs/guide/config.md +++ b/docs/guide/config.md @@ -636,7 +636,7 @@ The hook functions are uniformly configured under ʻoptions.hook`, and configura - Usage: Triggered before the cell is rendered, `return false` will not render the cell - Parameter: - {Object} [cell]:Cell object - - {Object} [postion]: + - {Object} [position]: + {Number} [r]: The row number of the cell + {Number} [c]: The column number of the cell + {Number} [start_r]: The horizontal coordinate of the upper left corner of the cell @@ -654,7 +654,7 @@ The hook functions are uniformly configured under ʻoptions.hook`, and configura - Usage: Triggered after the cell rendering ends, `return false` will not render the cell - Parameter: - {Object} [cell]: Cell object - - {Object} [postion]: + - {Object} [position]: + {Number} [r]: The row number of the cell + {Number} [c]: The column number of the cell + {Number} [start_r]: The horizontal coordinate of the upper left corner of the cell @@ -671,9 +671,9 @@ The hook functions are uniformly configured under ʻoptions.hook`, and configura ```js luckysheet.create({ hook: { - cellRenderAfter: function (cell, postion, sheetFile, ctx) { - var r = postion.r; - var c = postion.c; + cellRenderAfter: function (cell, position, sheetFile, ctx) { + var r = position.r; + var c = position.c; if (r === 0 && c === 3) { // Specify to process cell D1 if (!window.storeUserImage) { window.storeUserImage = {} @@ -708,20 +708,20 @@ The hook functions are uniformly configured under ʻoptions.hook`, and configura if (img.complete) { //Direct rendering that has been loaded - ctx.drawImage(img, postion.start_c, postion.start_r, 10, 10); + ctx.drawImage(img, position.start_c, position.start_r, 10, 10); } else { img.onload = function () { - ctx.drawImage(img, postion.start_c, postion.start_r, 10, 10); + ctx.drawImage(img, position.start_c, position.start_r, 10, 10); } } if (imgRight.complete) { - ctx.drawImage(imgRight, postion.end_c - 10, postion.end_r - 10, 10, 10); + ctx.drawImage(imgRight, position.end_c - 10, position.end_r - 10, 10, 10); } else { imgRight.onload = function () { - ctx.drawImage(imgRight, postion.end_c - 10, postion.end_r - 10, 10, 10); + ctx.drawImage(imgRight, position.end_c - 10, position.end_r - 10, 10, 10); } } @@ -751,7 +751,7 @@ The hook functions are uniformly configured under ʻoptions.hook`, and configura - Usage: Triggered before the row header cell is rendered, `return false` will not render the row header - Parameter: - {String} [rowNum]: Row number - - {Object} [postion]: + - {Object} [position]: + {Number} [r]: The row number of the cell + {Number} [top]: The vertical coordinate of the upper left corner of the cell + {Number} [width]: Cell width @@ -766,7 +766,7 @@ The hook functions are uniformly configured under ʻoptions.hook`, and configura - Usage: Triggered after the row header cell is rendered, `return false` will not render the row header - Parameter: - {String} [rowNum]: Row number - - {Object} [postion]: + - {Object} [position]: + {Number} [r]: The row number of the cell + {Number} [top]: The vertical coordinate of the upper left corner of the cell + {Number} [width]: Cell width @@ -781,7 +781,7 @@ The hook functions are uniformly configured under ʻoptions.hook`, and configura - Usage: Triggered before the column header cell is rendered, `return false` will not render the column header - Parameter: - {Object} [columnAbc]: Column header characters - - {Object} [postion]: + - {Object} [position]: - {Number} [c]: The column number of the cell - {Number} [left]: The horizontal coordinate of the upper left corner of the cell - {Number} [width]: Cell width @@ -796,7 +796,7 @@ The hook functions are uniformly configured under ʻoptions.hook`, and configura - Usage: Triggered after the column header cell is rendered, `return false` will not render the column header - Parameter: - {Object} [columnAbc]: Column header characters - - {Object} [postion]: + - {Object} [position]: - {Number} [c]: The column number of the cell - {Number} [left]: The horizontal coordinate of the upper left corner of the cell - {Number} [width]: Cell width diff --git a/docs/zh/about/sponsor.md b/docs/zh/about/sponsor.md index 306bbe0..1c91632 100644 --- a/docs/zh/about/sponsor.md +++ b/docs/zh/about/sponsor.md @@ -40,4 +40,5 @@ Luckysheet是MIT许可的开源项目,其持续稳定的开发离不开这些 - 张铭 ¥ 200 - 曹治军 ¥ 1 - *特 ¥ 10 -- **权 ¥ 9.9 \ No newline at end of file +- **权 ¥ 9.9 +- **sdmq ¥ 20 \ No newline at end of file diff --git a/docs/zh/guide/config.md b/docs/zh/guide/config.md index ee67f4e..2219f73 100644 --- a/docs/zh/guide/config.md +++ b/docs/zh/guide/config.md @@ -734,7 +734,7 @@ Luckysheet开放了更细致的自定义配置选项,分别有 - 作用:单元格渲染前触发,`return false` 则不渲染该单元格 - 参数: - {Object} [cell]:单元格对象 - - {Object} [postion]: + - {Object} [position]: + {Number} [r]:单元格所在行号 + {Number} [c]:单元格所在列号 + {Number} [start_r]:单元格左上角的水平坐标 @@ -752,7 +752,7 @@ Luckysheet开放了更细致的自定义配置选项,分别有 - 作用:单元格渲染结束后触发,`return false` 则不渲染该单元格 - 参数: - {Object} [cell]:单元格对象 - - {Object} [postion]: + - {Object} [position]: + {Number} [r]:单元格所在行号 + {Number} [c]:单元格所在列号 + {Number} [start_r]:单元格左上角的水平坐标 @@ -769,9 +769,9 @@ Luckysheet开放了更细致的自定义配置选项,分别有 ```js luckysheet.create({ hook: { - cellRenderAfter: function (cell, postion, sheetFile, ctx) { - var r = postion.r; - var c = postion.c; + cellRenderAfter: function (cell, position, sheetFile, ctx) { + var r = position.r; + var c = position.c; if (r === 0 && c === 3) { // 指定处理D1单元格 if (!window.storeUserImage) { window.storeUserImage = {} @@ -806,20 +806,20 @@ Luckysheet开放了更细致的自定义配置选项,分别有 if (img.complete) { // 已经加载完成的直接渲染 - ctx.drawImage(img, postion.start_c, postion.start_r, 10, 10); + ctx.drawImage(img, position.start_c, position.start_r, 10, 10); } else { img.onload = function () { - ctx.drawImage(img, postion.start_c, postion.start_r, 10, 10); + ctx.drawImage(img, position.start_c, position.start_r, 10, 10); } } if (imgRight.complete) { - ctx.drawImage(imgRight, postion.end_c - 10, postion.end_r - 10, 10, 10); + ctx.drawImage(imgRight, position.end_c - 10, position.end_r - 10, 10, 10); } else { imgRight.onload = function () { - ctx.drawImage(imgRight, postion.end_c - 10, postion.end_r - 10, 10, 10); + ctx.drawImage(imgRight, position.end_c - 10, position.end_r - 10, 10, 10); } } @@ -849,7 +849,7 @@ Luckysheet开放了更细致的自定义配置选项,分别有 - 作用:行标题单元格渲染前触发,`return false` 则不渲染行标题 - 参数: - {String} [rowNum]:行号 - - {Object} [postion]: + - {Object} [position]: + {Number} [r]:单元格所在行号 + {Number} [top]:单元格左上角的垂直坐标 + {Number} [width]:单元格宽度 @@ -864,7 +864,7 @@ Luckysheet开放了更细致的自定义配置选项,分别有 - 作用:行标题单元格渲染后触发,`return false` 则不渲染行标题 - 参数: - {String} [rowNum]:行号 - - {Object} [postion]: + - {Object} [position]: + {Number} [r]:单元格所在行号 + {Number} [top]:单元格左上角的垂直坐标 + {Number} [width]:单元格宽度 @@ -879,7 +879,7 @@ Luckysheet开放了更细致的自定义配置选项,分别有 - 作用:列标题单元格渲染前触发,`return false` 则不渲染列标题 - 参数: - {Object} [columnAbc]:列标题字符 - - {Object} [postion]: + - {Object} [position]: - {Number} [c]:单元格所在列号 - {Number} [left]:单元格左上角的水平坐标 - {Number} [width]:单元格宽度 @@ -894,7 +894,7 @@ Luckysheet开放了更细致的自定义配置选项,分别有 - 作用:列标题单元格渲染后触发,`return false` 则不渲染列标题 - 参数: - {Object} [columnAbc]:列标题字符 - - {Object} [postion]: + - {Object} [position]: - {Number} [c]:单元格所在列号 - {Number} [left]:单元格左上角的水平坐标 - {Number} [width]:单元格宽度 @@ -912,7 +912,7 @@ Luckysheet开放了更细致的自定义配置选项,分别有 - 作用:单元格点击前的事件,`return false`则终止之后的点击操作 - 参数: - {Object} [cell]:单元格对象 - - {Object} [postion]: + - {Object} [position]: + {Number} [r]:单元格所在行号 + {Number} [c]:单元格所在列号 + {Number} [start_r]:单元格左上角的水平坐标 @@ -930,7 +930,7 @@ Luckysheet开放了更细致的自定义配置选项,分别有 - 作用:单元格点击后的事件,`return false`则终止之后的点击操作 - 参数: - {Object} [cell]:单元格对象 - - {Object} [postion]: + - {Object} [position]: + {Number} [r]:单元格所在行号 + {Number} [c]:单元格所在列号 + {Number} [start_r]:单元格左上角的水平坐标 @@ -948,7 +948,7 @@ Luckysheet开放了更细致的自定义配置选项,分别有 - 作用:鼠标移动事件,可通过cell判断鼠标停留在哪个单元格 - 参数: - {Object} [cell]:单元格对象 - - {Object} [postion]: + - {Object} [position]: + {Number} [r]:单元格所在行号 + {Number} [c]:单元格所在列号 + {Number} [start_r]:单元格左上角的水平坐标 @@ -984,7 +984,7 @@ Luckysheet开放了更细致的自定义配置选项,分别有 - 作用:鼠标按钮释放事件,可通过cell判断鼠标停留在哪个单元格 - 参数: - {Object} [cell]:单元格对象 - - {Object} [postion]: + - {Object} [position]: + {Number} [r]:单元格所在行号 + {Number} [c]:单元格所在列号 + {Number} [start_r]:单元格左上角的水平坐标 @@ -1037,7 +1037,7 @@ Luckysheet开放了更细致的自定义配置选项,分别有 - 作用:鼠标拖拽文件到Luckysheet内部的结束事件 - 参数: - {Object} [cell]:单元格对象 - - {Object} [postion]: + - {Object} [position]: + {Number} [r]:单元格所在行号 + {Number} [c]:单元格所在列号 + {Number} [start_r]:单元格左上角的水平坐标