Browse Source

右键菜单栏 UI适配

master
CN\wuwx26 5 years ago
parent
commit
25e3300398
  1. 11
      docs/zh/guide/config.md
  2. 6
      src/controllers/filter.js
  3. 6
      src/controllers/pivotTable.js
  4. 2
      src/css/luckysheet-core.css
  5. 1
      src/global/api.js

11
docs/zh/guide/config.md

@ -1434,7 +1434,16 @@ Luckysheet开放了更细致的自定义配置选项,分别有
- {Object} [size]: 整个工作簿区域的宽高
------------
### scroll
- 类型:Function
- 默认值:null
- 作用:监听表格滚动值
- 参数:
- {Number} [scrollLeft]: 水平方向滚动值
- {Number} [scrollTop]: 垂直方向滚动值
- {Number} [canvasHeight]: 滚动容器的高度
------------
## 图片
### imageInsertBefore

6
src/controllers/filter.js

@ -726,8 +726,10 @@ function initialFilterHandler(){
}
}
}
$("#luckysheet-filter-byvalue-select").html("<div class='ListBox luckysheet-mousedown-cancel' style='min-height: 100px; max-height: " + (winH - toffset.top - 350) + "px; overflow-y: auto; overflow-x: hidden;'><table cellspacing='0' style='width:100%;' class='luckysheet-mousedown-cancel'>" + item.join("") + "</table></div>");
// 适配小屏设备
let containerH = winH - toffset.top - 350
if (containerH < 0) containerH = 100
$("#luckysheet-filter-byvalue-select").html("<div class='ListBox luckysheet-mousedown-cancel' style='min-height: 100px; max-height: " + containerH + "px; overflow-y: auto; overflow-x: hidden;'><table cellspacing='0' style='width:100%;' class='luckysheet-mousedown-cancel'>" + item.join("") + "</table></div>");
}, 1);
showrightclickmenu($menu, toffset.left, toffset.top + 20);

6
src/controllers/pivotTable.js

@ -532,8 +532,10 @@ const pivotTable = {
}
}
}
$("#luckysheet-pivotTableFilter-byvalue-select").html("<div class='ListBox luckysheet-mousedown-cancel' style='max-height:" + (winH - toffset.top - 350) + "px;overflow-y:auto;overflow-x:hidden;'>" + item.join("") + "</div>");
// 适配小屏设备
let containerH = winH - toffset.top - 350
if (containerH < 0) containerH = 100
$("#luckysheet-pivotTableFilter-byvalue-select").html("<div class='ListBox luckysheet-mousedown-cancel' style='max-height:" + containerH + "px;overflow-y:auto;overflow-x:hidden;'>" + item.join("") + "</div>");
}, 1);
showrightclickmenu($menu, toffset.left - 250, toffset.top);

2
src/css/luckysheet-core.css

@ -2225,6 +2225,8 @@ body:not(.ewa-ipad) .luckysheet-rows-h-cell-sel:hover {
}
.luckysheet-cols-menu {
max-height: 100%;
overflow-y: auto;
-webkit-border-radius: 0;
-moz-border-radius: 0;
border-radius: 0;

1
src/global/api.js

@ -6549,7 +6549,6 @@ export function getTxtByRange(range=Store.luckysheet_select_save){
*/
export function pagerInit (config) {
const {prevPage, nextPage, total} = locale().button;
console.log(locale().button, prevPage, locale())
$('#luckysheet-bottom-pager').remove()
$('#luckysheet-sheet-content').after('<div id="luckysheet-bottom-pager" style="font-size: 14px; margin-left: 10px; display: inline-block;"></div>')
$("#luckysheet-bottom-pager").sPage({

Loading…
Cancel
Save