diff --git a/docs/guide/FAQ.md b/docs/guide/FAQ.md index 7a0b90f..6ec1100 100644 --- a/docs/guide/FAQ.md +++ b/docs/guide/FAQ.md @@ -2,7 +2,7 @@ ## **Q** What is the difference between data and celldata in luckysheetfile? -**A**: Use one-dimensional array format [celldata](/zh/guide/sheet.html#celldata), after the initialization is completed, the data converted into a two-dimensional array format is used for storage and update, and celldata is no longer used. +**A**: Use one-dimensional array format [celldata](/guide/sheet.html#celldata), after the initialization is completed, the data converted into a two-dimensional array format is used for storage and update, and celldata is no longer used. If you need to take out `data` as initial data, you need to execute [transToCellData(data)](/guide/api.html#transtocelldata-data-setting) to convert it to celldata data. Among them, the celldata in `{ r, c, v }` format is converted to a two-dimensional array using [transToData(celldata)](/guide/api.html#transtodata-celldata-setting) @@ -20,7 +20,7 @@ luckysheet.transToData(celldata) ## **Q** What are the cell types? -**A**: Refer to [Cell Format List](/zh/guide/cell.html), with examples of available cell formats +**A**: Refer to [Cell Format List](/guide/cell.html), with examples of available cell formats ------------ @@ -35,13 +35,13 @@ luckysheet.transToData(celldata) ## **Q** Why will the formula in the table not be triggered after initialization? -**A** : Refer to [Table data format](/zh/guide/sheet.html#calcchain) ,just set the calcChain corresponding to the cell data. +**A** : Refer to [Table data format](/guide/sheet.html#calcchain) ,just set the calcChain corresponding to the cell data. ------------ ## **Q** Is the remote loading data loadUrl or updateUrl? -**A**: [loadUrl](/zh/guide/config.html#loadurl). Configure loadUrl, Luckysheet will request the entire table data through ajax, and updateUrl will be used as the interface address for collaborative editing in real-time saving. +**A**: [loadUrl](/guide/config.html#loadurl). Configure loadUrl, Luckysheet will request the entire table data through ajax, and updateUrl will be used as the interface address for collaborative editing in real-time saving. Note: Initial data needs to be configured with loadUrl and loadSheetUrl parameters, while for collaborative editing, the four parameters of loadUrl, loadSheetUrl, updateUrl and allowUpdate can be configured to take effect. ------------ @@ -90,14 +90,14 @@ refer this article: ## **Q** How to monitor cell hover or click events? how to monitor `cellRenderAfter` in real-time? -**A** :我们搜集到需要针对单元格事件的二次开发需求,规划了单元格相关的钩子函数,参考[单元格钩子函数](/zh/guide/config.html#cellrenderafter)(显示的TODO的暂未开放) +**A** :我们搜集到需要针对单元格事件的二次开发需求,规划了单元格相关的钩子函数,参考[单元格钩子函数](/guide/config.html#cellrenderafter)(显示的TODO的暂未开放) ------------ ## **Q** How to customize the top toolbar? **A** : -reference: [options.showtoolbarconfig](/zh/guide/config.html#showtoolbarconfig)(TODO means waiting to developed) +reference: [options.showtoolbarconfig](/guide/config.html#showtoolbarconfig)(TODO means waiting to developed) ------------ @@ -113,7 +113,7 @@ if you want to remove jQuery in `Luckysheet`, you can find `jQuery` in source co ## **Q** How to add a field to a cell object? -**A** reference [cell object format](/zh/guide/cell.html),then read this annotation[src/controllers/postil.js](https://github.com/mengshukeji/Luckysheet/blob/master/src/controllers/postil.js)。the annotation is a configuration in a cell object. +**A** reference [cell object format](/guide/cell.html),then read this annotation[src/controllers/postil.js](https://github.com/mengshukeji/Luckysheet/blob/master/src/controllers/postil.js)。the annotation is a configuration in a cell object. ------------ @@ -121,7 +121,7 @@ if you want to remove jQuery in `Luckysheet`, you can find `jQuery` in source co **A** The luckysheet use iconfont icon in this project, if any icon cannot be loaded ,plz check your iconfont.css. we are so sorry that we did not describe it clearly in the old version documents. -Now the documents have been updated.[official documents](/zh/guide/#使用步骤) +Now the documents have been updated.[official documents](/guide/#steps-for-usage) ------------ @@ -140,7 +140,7 @@ more information:[Luckyexcel](https://github.com/mengshukeji/Luckyexcel/) ## **Q** How to disable editing of cells?How to open sheet protection? -**A** Sheet protection includes disable editing of cells that you need to make some configurations on each sheets. `config.authority`, the latest configurations[sheet protection](/zh/guide/sheet.html#config-authority)。 +**A** Sheet protection includes disable editing of cells that you need to make some configurations on each sheets. `config.authority`, the latest configurations[sheet protection](/guide/sheet.html#config-authority)。 In order to make it easier for you to understand the function of sheet protection, the following video shows how to make the whole sheet uneditable, but allow a column of cells to be edited: @@ -152,7 +152,7 @@ In you local browser, you can open the control pannel, use `luckysheet.getLuckys ## **Q** How to configure data validation? -**A** there is the configuration of data validation,[data validation](/zh/guide/sheet.html#dataVerification)。Also there is the API that you can use `data validation` in any time. [setDataVerification](/zh/guide/api.html#setdataverification-optionitem-setting). +**A** there is the configuration of data validation,[data validation](/guide/sheet.html#dataVerification)。Also there is the API that you can use `data validation` in any time. [setDataVerification](/guide/api.html#setdataverification-optionitem-setting). ------------ @@ -181,6 +181,30 @@ if you want to get the position of the picture, you can overlap the picture with **A** There are two ways to get it - 1. use `luckysheet.getLuckysheetfile()` to get all configuration data, so you can get the `defaultRowHeight` and `defaultColWidth` in the sheet configuration data。 -- 2. use API to get the default row height [getDefaultRowHeight](/zh/guide/api.html#getdefaultrowheight-setting) and column width.[getDefaultColWidth](/zh/guide/api.html#getdefaultcolwidth-setting) +- 2. use API to get the default row height [getDefaultRowHeight](/guide/api.html#getdefaultrowheight-setting) and column width.[getDefaultColWidth](/guide/api.html#getdefaultcolwidth-setting) +------------ + +## **Q** How to hide the add row button and the back to top button below the worksheet? + +**A** Configuration is open +- Allow adding rows [enableAddRow](/guide/config.html#enableaddrow) +- Allow back to top [enableAddBackTop](/guide/config.html#enableAddBackTop) + +------------ + +## **Q** How to hide the row and column headings of the worksheet? + +**A** Configuration is open +- The width of the row header area [rowHeaderWidth](/guide/config.html#rowheaderwidth) +- The height of the column header area [columeHeaderHeight](/guide/config.html#columeheaderheight) + +------------ + +## **Q** What method can be called to set `config.merge`? + +**A** Three methods +- Interface operation +- Use API: [setRangeMerge](/guide/api.html#setrangemerge-type-setting) +- Manually assemble merge parameters ------------ \ No newline at end of file diff --git a/docs/guide/api.md b/docs/guide/api.md index bdd25b0..05153c1 100644 --- a/docs/guide/api.md +++ b/docs/guide/api.md @@ -1828,7 +1828,7 @@ Use note: Return all worksheet configurations, the format is the same as the worksheet configuration, and the results obtained can be used as options.data when the form is initialized. - Therefore, this API is suitable for manually operating and configuring a table, and then taking out all the worksheet information to save it, and then use it for table creation in other places. If you want to get all the workbook data including the workbook configuration, you can use [toJson](#toJson()) + Therefore, this API is suitable for manually operating and configuring a table, and then taking out all the worksheet information to save it, and then use it for table creation in other places. If you want to get all the workbook data including the workbook configuration, it is recommended to use [toJson](#toJson()), and it can be directly used to initialize Luckysheet. - **Usage**: @@ -2568,8 +2568,6 @@ Use note: ### toJson() -[todo] - - **Explanation**: The exported json string can be directly used as the parameter `options` when the workbook is initialized by `luckysheet.create(options)`. The usage scenario is to manually save all the parameters after the user manipulates the table, and then initialize the table elsewhere. Use, similar to the import and export of a luckysheet proprietary format. diff --git a/docs/guide/config.md b/docs/guide/config.md index d50edd7..d1ea88f 100644 --- a/docs/guide/config.md +++ b/docs/guide/config.md @@ -28,7 +28,6 @@ Luckysheet has opened more detailed custom configuration options, which are as f - Customize the toolbar ([showtoolbarConfig](#showtoolbarConfig)) - Customize the bottom sheet bar ([showsheetbarConfig](#showsheetbarConfig)) - Customize the counting bar ([showstatisticBarConfig](#showstatisticBarConfig)) -- Custom add row and back to the top ([sheetBottomConfig](#sheetBottomConfig)) - Custom cell right-click menu ([cellRightClickConfig](#cellRightClickConfig)) - Customize the right-click menu of the bottom sheet bar ([sheetRightClickConfig](#sheetRightClickConfig)) @@ -59,10 +58,9 @@ The following are all supported setting parameters - Customize the bottom sheet bar [showsheetbarConfig](#showsheetbarConfig) - The bottom count bar [showstatisticBar](#showstatisticBar) - Custom Count Bar [showstatisticBarConfig](#showstatisticBarConfig) -- Custom add row and back to top [sheetBottomConfig](#sheetBottomConfig) - Allow editing [allowEdit](#allowEdit) - Allow adding rows [enableAddRow](#enableAddRow) -- Allow adding columns [enableAddCol](#enableAddCol) +- Allow back to top [enableAddBackTop](#enableAddBackTop) - User Info [userInfo](#userInfo) - User Information Menu [userMenuItem](#userMenuItem) - Back button link [myFolderUrl](#myFolderUrl) @@ -73,8 +71,8 @@ The following are all supported setting parameters - Refresh formula [forceCalculation](#forceCalculation) - Custom cell right-click menu [cellRightClickConfig](#cellRightClickConfig) - Customize the right-click menu of the bottom sheet bar [sheetRightClickConfig](#sheetRightClickConfig) -- Whether to show the row number area [showRowBar](#showRowBar) -- Whether to show the column number area [showColumnBar](#showColumnBar) +- The width of the row header area [rowHeaderWidth](#rowHeaderWidth) +- The height of the column header area [columeHeaderHeight](#columeHeaderHeight) - Whether to show the formula bar [sheetFormulaBar](#sheetFormulaBar) - Initialize the default font size [defaultFontSize](#defaultFontSize) @@ -350,21 +348,6 @@ Note that you also need to configure `loadUrl` and `loadSheetUrl` to take effect } ``` ------------ -### sheetBottomConfig - -[todo] - -- Type: Object -- Default: {} -- Usage: Add row button and back to top button configuration below the worksheet -- Format: - ```json - { - addRow: false, // Add row button - backTop: false // Back to the top - } - ------------- ### allowEdit - Type: Boolean - Default: true @@ -377,10 +360,10 @@ Note that you also need to configure `loadUrl` and `loadSheetUrl` to take effect - Usage: Allow additional rows ------------ -### enableAddCol +### enableAddBackTop - Type: Boolean - Default: true -- Usage: Allow adding columns +- Usage: Allow back to top ------------ ### userInfo @@ -439,27 +422,61 @@ Note that you also need to configure `loadUrl` and `loadSheetUrl` to take effect ------------ ### cellRightClickConfig -[todo] - - Type: Object - Default: {} - Usage: Custom configuration cell right-click menu -- Format: - ```json +- Format: + ```json { - copy: false, //Copy - copyAs: false, //Copy as - paste: false, //Paste - insert: false, //Insert - delete: false, //Delete - hide: false, //Hide - deleteCell: false, //Delete cell - clear: false, //Clear content - matrix: false, //Matrix operation selection - sort: false, //Sort selection - filter: false, //Filter selection - chart: false //Chart generation - } + copy: false, // copy + copyAs: false, // copy as + paste: false, // paste + insertRow: false, // insert row + insertColumn: false, // insert column + deleteRow: false, // delete the selected row + deleteColumn: false, // delete the selected column + deleteCell: false, // delete cell + hideRow: false, // hide the selected row and display the selected row + hideColumn: false, // hide the selected column and display the selected column + rowHeight: false, // row height + columnWidth: false, // column width + clear: false, // clear content + matrix: false, // matrix operation selection + sort: false, // sort selection + filter: false, // filter selection + chart: false, // chart generation + image: false, // insert picture + link: false, // insert link + data: false, // data verification + cellFormat: false // Set cell format + } + ``` + + In addition to the cells, the configuration here also includes the row header right-click menu, the column header right-click menu, and the column header drop-down arrow menu. The specific configuration relationships are as follows: + + |Right-click menu configuration|Cell|Row header|Column header|Column arrow| + | ------------ | ------------ | ------------ | ----------- | ------------ | + |copy|copy|copy|copy|copy| + |copyAs|copy as|copy as|copy as|copy as| + |paste|paste|paste|paste|paste| + |insertRow|Insert a row|Increase N rows upwards and N rows downwards|-|-| + |insertColumn|Insert Column|-|Add N columns to the left and N columns to the right|Add N columns to the left and N columns to the right| + |deleteRow|Delete selected row|Delete selected row|-|-| + |deleteColumn|Delete selected column|-|Delete selected column|Delete selected column| + |deleteCell|Delete cell|-|-|-| + |hideRow|Hide the selected row and show the selected row|Hide the selected row and show the selected row|-|-| + |hideColumn|Hide the selected column and show the selected column|-|Hide the selected column and show the selected column|Hide the selected column and show the selected column| + |rowHeight|-|row height|-|-| + |columnWidth|-|-|Column Width|Column Width| + |clear|clear content|clear content|clear content|-| + |matrix|Matrix Operation Selection|Matrix Operation Selection|Matrix Operation Selection|-| + |sort|Sort selection|Sort selection|Sort selection|A-Z sort and Z-A sort| + |filter|Filter selection|Filter selection|Filter selection|-| + |chart|chart generation|chart generation|chart generation|-| + |image|Insert Picture|Insert Picture|Insert Picture|-| + |link|Insert link|Insert link|Insert link|-| + |data|Data Verification|Data Verification|Data Verification|-| + |cellFormat|Set cell format|Set cell format|Set cell format|-| ------------ ### sheetRightClickConfig @@ -483,16 +500,16 @@ Note that you also need to configure `loadUrl` and `loadSheetUrl` to take effect } ------------ -### showRowBar -- Type: Boolean -- Default: true -- Usage: Whether to show the row number area +### rowHeaderWidth +- Type: Number +- Default: 46 +- Usage: The width of the row header area, if set to 0, it means to hide the row header ------------ -### showColumnBar -- Type: Boolean -- Default: true -- Usage: Whether to show the column number area +### columeHeaderHeight +- Type: Number +- Default: 20 +- Usage: The height of the column header area, if set to 0, it means hide the column header ------------ ### sheetFormulaBar diff --git a/docs/zh/guide/FAQ.md b/docs/zh/guide/FAQ.md index 5954caf..8de3025 100644 --- a/docs/zh/guide/FAQ.md +++ b/docs/zh/guide/FAQ.md @@ -184,4 +184,29 @@ Luckyexcel是excel导入导出库,项目采用了gulp作为打包工具,旧 - 一是使用`luckysheet.getLuckysheetfile()`获取到所有工作表配置后,在各个工作表的配置中直接取得默认行高`defaultRowHeight`和默认列宽`defaultColWidth`。 - 二是开放了API可以获取到工作表默认的行高[getDefaultRowHeight](/zh/guide/api.html#getdefaultrowheight-setting)和列宽[getDefaultColWidth](/zh/guide/api.html#getdefaultcolwidth-setting) +------------ + +## **Q** 如何隐藏工作表下方的添加行按钮和回到顶部按钮? + +**A** 已开放配置 +- 允许添加行 [enableAddRow](/zh/guide/config.html#enableaddrow) +- 允许回到顶部 [enableAddBackTop](/zh/guide/config.html#enableAddBackTop) + +------------ + +## **Q** 如何隐藏工作表的行标题和列标题? + +**A** 已开放配置 +- 行标题区域的宽度 [rowHeaderWidth](/zh/guide/config.html#rowheaderwidth) +- 列标题区域的高度 [columeHeaderHeight](/zh/guide/config.html#columeheaderheight) + +------------ + +## **Q** 调用什么方法能设置`config.merge`? + +**A** 三个方法 +- 界面操作 +- 用API:[setRangeMerge](/zh/guide/api.html#setrangemerge-type-setting) +- 手动组装merge参数 + ------------ \ No newline at end of file diff --git a/docs/zh/guide/api.md b/docs/zh/guide/api.md index 756918b..a67d942 100644 --- a/docs/zh/guide/api.md +++ b/docs/zh/guide/api.md @@ -1791,7 +1791,7 @@ Luckysheet针对常用的数据操作需求,开放了主要功能的API,开 返回所有工作表配置,格式同工作表配置,得到的结果可用于表格初始化时作为options.data使用。 - 所以此API适用于,手动操作配置完一个表格后,将所有工作表信息取出来自行保存,再用于其他地方的表格创建。如果想得到包括工作簿配置在内的所有工作簿数据,可以使用 [toJson](#toJson()) + 所以此API适用于,手动操作配置完一个表格后,将所有工作表信息取出来自行保存,再用于其他地方的表格创建。如果想得到包括工作簿配置在内的所有工作簿数据,推荐使用 [toJson](#toJson()),并且可以直接用于初始化Luckysheet。 - **示例**: @@ -2474,7 +2474,6 @@ Luckysheet针对常用的数据操作需求,开放了主要功能的API,开 ### toJson() -[todo] - **说明**: diff --git a/docs/zh/guide/config.md b/docs/zh/guide/config.md index e44f242..40494e6 100644 --- a/docs/zh/guide/config.md +++ b/docs/zh/guide/config.md @@ -28,7 +28,6 @@ Luckysheet开放了更细致的自定义配置选项,分别有 - 自定义工具栏([showtoolbarConfig](#showtoolbarConfig)) - 自定义底部sheet页([showsheetbarConfig](#showsheetbarConfig)) - 自定义计数栏([showstatisticBarConfig](#showstatisticBarConfig)) -- 自定义添加行和回到顶部([sheetBottomConfig](#sheetBottomConfig)) - 自定义单元格右键菜单([cellRightClickConfig](#cellRightClickConfig)) - 自定义底部sheet页右击菜单([sheetRightClickConfig](#sheetRightClickConfig)) @@ -60,10 +59,9 @@ Luckysheet开放了更细致的自定义配置选项,分别有 - 自定义底部sheet页 [showsheetbarConfig](#showsheetbarConfig) - 底部计数栏 [showstatisticBar](#showstatisticBar) - 自定义计数栏 [showstatisticBarConfig](#showstatisticBarConfig) -- 自定义添加行和回到顶部 [sheetBottomConfig](#sheetBottomConfig) - 允许编辑 [allowEdit](#allowEdit) -- 允许增加行 [enableAddRow](#enableAddRow) -- 允许增加列 [enableAddCol](#enableAddCol) +- 允许添加行 [enableAddRow](#enableAddRow) +- 允许回到顶部 [enableAddBackTop](#enableAddBackTop) - 用户信息 [userInfo](#userInfo) - 用户信息菜单 [userMenuItem](#userMenuItem) - 返回按钮链接 [myFolderUrl](#myFolderUrl) @@ -74,8 +72,8 @@ Luckysheet开放了更细致的自定义配置选项,分别有 - 刷新公式 [forceCalculation](#forceCalculation) - 自定义单元格右键菜单 [cellRightClickConfig](#cellRightClickConfig) - 自定义sheet页右击菜单 [sheetRightClickConfig](#sheetRightClickConfig) -- 是否显示行号区域 [showRowBar](#showRowBar) -- 是否显示列号区域 [showColumnBar](#showColumnBar) +- 行标题区域的宽度 [rowHeaderWidth](#rowHeaderWidth) +- 列标题区域的高度 [columeHeaderHeight](#columeHeaderHeight) - 是否显示公式栏 [sheetFormulaBar](#sheetFormulaBar) - 初始化默认字体大小 [defaultFontSize](#defaultFontSize) @@ -438,21 +436,6 @@ Luckysheet开放了更细致的自定义配置选项,分别有 } ``` ------------- -### sheetBottomConfig - -[todo] - -- 类型:Object -- 默认值:{} -- 作用:sheet页下方的添加行按钮和回到顶部按钮配置 -- 格式: - ```json - { - addRow: false, // 添加行按钮 - backTop: false // 回到顶部 - } - ------------ ### allowEdit - 类型:Boolean @@ -463,13 +446,13 @@ Luckysheet开放了更细致的自定义配置选项,分别有 ### enableAddRow - 类型:Boolean - 默认值:true -- 作用:允许增加行 +- 作用:允许添加行 ------------ -### enableAddCol +### enableAddBackTop - 类型:Boolean - 默认值:true -- 作用:允许增加列 +- 作用:允许回到顶部 ------------ ### userInfo @@ -528,8 +511,6 @@ Luckysheet开放了更细致的自定义配置选项,分别有 ------------ ### cellRightClickConfig -[todo] - - 类型:Object - 默认值:{} - 作用:自定义配置单元格右击菜单 @@ -539,16 +520,51 @@ Luckysheet开放了更细致的自定义配置选项,分别有 copy: false, // 复制 copyAs: false, // 复制为 paste: false, // 粘贴 - insert: false, // 插入 - delete: false, // 删除 - hide: false, // 隐藏 + insertRow: false, // 插入行 + insertColumn: false, // 插入列 + deleteRow: false, // 删除选中行 + deleteColumn: false, // 删除选中列 deleteCell: false, // 删除单元格 + hideRow: false, // 隐藏选中行和显示选中行 + hideColumn: false, // 隐藏选中列和显示选中列 + rowHeight: false, // 行高 + columnWidth: false, // 列宽 clear: false, // 清除内容 matrix: false, // 矩阵操作选区 sort: false, // 排序选区 filter: false, // 筛选选区 - chart: false // 图表生成 + chart: false, // 图表生成 + image: false, // 插入图片 + link: false, // 插入链接 + data: false, // 数据验证 + cellFormat: false // 设置单元格格式 } + ``` + 除了单元格,这里的配置还包括行标题右击菜单、列标题右击菜单和列标题下拉箭头的菜单,具体配置关系如下表格: + + |右击菜单配置|单元格|行标题|列标题|列箭头| + | ------------ | ------------ | ------------ | ------------ | ------------ | + |copy|复制|复制|复制|复制| + |copyAs|复制为|复制为|复制为|复制为| + |paste|粘贴|粘贴|粘贴|粘贴| + |insertRow|插入行|向上增加N行,向下增加N行|-|-| + |insertColumn|插入列|-|向左增加N列,向右增加N列|向左增加N列,向右增加N列| + |deleteRow|删除选中行|删除选中行|-|-| + |deleteColumn|删除选中列|-|删除选中列|删除选中列| + |hideRow|隐藏选中行和显示选中行|隐藏选中行和显示选中行|-|-| + |hideColumn|隐藏选中列和显示选中列|-|隐藏选中列和显示选中列|隐藏选中列和显示选中列| + |rowHeight|-|行高|-|-| + |columnWidth|-|-|列宽|列宽| + |clear|清除内容|清除内容|清除内容|-| + |matrix|矩阵操作选区|矩阵操作选区|矩阵操作选区|-| + |sort|排序选区|排序选区|排序选区|A-Z排序和Z-A排序| + |filter|筛选选区|筛选选区|筛选选区|-| + |chart|图表生成|图表生成|图表生成|-| + |image|插入图片|插入图片|插入图片|-| + |link|插入链接|插入链接|插入链接|-| + |data|数据验证|数据验证|数据验证|-| + |cellFormat|设置单元格格式|设置单元格格式|设置单元格格式|-| + ------------ ### sheetRightClickConfig @@ -572,22 +588,22 @@ Luckysheet开放了更细致的自定义配置选项,分别有 } ------------ -### showRowBar -[todo] -- 类型:Boolean -- 默认值:true -- 作用:是否显示行号区域 +### rowHeaderWidth + +- 类型:Number +- 默认值:46 +- 作用:行标题区域的宽度,如果设置为0,则表示隐藏行标题 ------------ -### showColumnBar -[todo] -- 类型:Boolean -- 默认值:true -- 作用:是否显示列号区域 +### columeHeaderHeight + +- 类型:Number +- 默认值:20 +- 作用:列标题区域的高度,如果设置为0,则表示隐藏列标题 ------------ ### sheetFormulaBar -[todo] + - 类型:Boolean - 默认值:true - 作用:是否显示公式栏 diff --git a/src/config.js b/src/config.js index 31cb7dd..f6a3fef 100644 --- a/src/config.js +++ b/src/config.js @@ -31,8 +31,8 @@ export default { allowUpdate: false, //是否允许编辑后的后台更新 functionButton: "", //右上角功能按钮,例如' ' showConfigWindowResize: true, //图表和数据透视表的配置会在右侧弹出,设置弹出后表格是否会自动缩进 - enableAddRow: true,//允许增加行 - enableAddCol: true,//允许增加列 + enableAddRow: true,//允许添加行 + enableAddBackTop: true,//允许回到顶部 enablePage: false,//允许加载下一页 autoFormatw: false, //自动格式化超过4位数的数字为 亿万格式 例:true or "true" or "TRUE" accuracy: undefined, //设置传输来的数值的精确位数,小数点后n位 传参数为数字或数字字符串,例: "0" 或 0 @@ -58,13 +58,10 @@ export default { defaultRowHeight:19, defaultFontSize:10, - showRowBar:true, //是否显示行号区域 - showColumnBar:true, //是否显示列号区域 sheetFormulaBar:true, //是否显示公式栏 showtoolbarConfig:{}, //自定义工具栏 showsheetbarConfig:{}, //自定义底部sheet页 showstatisticBarConfig:{}, //自定义计数栏 - sheetBottomConfig:{}, //自定义添加行和回到顶部 cellRightClickConfig:{}, //自定义单元格右键菜单 sheetRightClickConfig:{}, //自定义底部sheet页右击菜单 } \ No newline at end of file diff --git a/src/controllers/constant.js b/src/controllers/constant.js index 086da93..9f755cd 100644 --- a/src/controllers/constant.js +++ b/src/controllers/constant.js @@ -1,5 +1,6 @@ import locale from '../locale/locale'; import Store from '../store'; +import luckysheetConfigsetting from './luckysheetConfigsetting'; //dom variable const gridHTML = function(){ @@ -259,36 +260,51 @@ function rightclickHTML(){ const rightclick = _locale.rightclick; const toolbar = _locale.toolbar; - return `