mirror of https://github.com/layui/layui
commit
701c48d844
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
|
@ -1,6 +1,6 @@
|
|||
{
|
||||
"name": "layui",
|
||||
"version": "2.8.0-rc.12",
|
||||
"version": "2.8.0-rc.13",
|
||||
"description": "Classic modular Front-End UI library",
|
||||
"main": "dist/layui.js",
|
||||
"license": "MIT",
|
||||
|
|
|
@ -29,6 +29,7 @@ a cite{font-style: normal; *cursor:pointer;}
|
|||
/* 消除第三方ui可能造成的冲突 */.layui-box, .layui-box *{box-sizing: content-box;}
|
||||
.layui-clear{clear: both; *zoom: 1;}
|
||||
.layui-clear:after{content:'\20'; clear:both; *zoom:1; display:block; height:0;}
|
||||
.layui-clear-space{word-spacing: -5px;}
|
||||
.layui-inline{position: relative; display: inline-block; *display:inline; *zoom:1; vertical-align: middle;}
|
||||
/* 三角形 */.layui-edge{position: relative; display: inline-block; vertical-align: middle; width: 0; height: 0; border-width: 6px; border-style: dashed; border-color: transparent; overflow: hidden;}
|
||||
.layui-edge-top{top: -4px; border-bottom-color: #999; border-bottom-style: solid;}
|
||||
|
@ -47,12 +48,12 @@ a cite{font-style: normal; *cursor:pointer;}
|
|||
/** 图标字体 **/
|
||||
@font-face {
|
||||
font-family: 'layui-icon';
|
||||
src: url('../font/iconfont.eot?v=256');
|
||||
src: url('../font/iconfont.eot?v=256#iefix') format('embedded-opentype'),
|
||||
url('../font/iconfont.woff2?v=256') format('woff2'),
|
||||
url('../font/iconfont.woff?v=256') format('woff'),
|
||||
url('../font/iconfont.ttf?v=256') format('truetype'),
|
||||
url('../font/iconfont.svg?v=256#layui-icon') format('svg');
|
||||
src: url('../font/iconfont.eot?v=280');
|
||||
src: url('../font/iconfont.eot?v=280#iefix') format('embedded-opentype'),
|
||||
url('../font/iconfont.woff2?v=280') format('woff2'),
|
||||
url('../font/iconfont.woff?v=280') format('woff'),
|
||||
url('../font/iconfont.ttf?v=280') format('truetype'),
|
||||
url('../font/iconfont.svg?v=280#layui-icon') format('svg');
|
||||
}
|
||||
|
||||
.layui-icon{
|
||||
|
@ -1016,7 +1017,6 @@ a cite{font-style: normal; *cursor:pointer;}
|
|||
.layui-table-tool-panel li .layui-form-checkbox[lay-skin="primary"] span{padding: 0;}
|
||||
.layui-table-tool .layui-table-tool-self .layui-table-tool-panel{left: auto; right: -1px;}
|
||||
|
||||
.layui-table-col-special{word-spacing: -5px;}
|
||||
.layui-table-col-set{position: absolute; right: 0; top: 0; width: 20px; height: 100%; border-width: 0; border-left-width: 1px; background-color: #fff;}
|
||||
|
||||
.layui-table-sort{width: 10px; height: 20px; margin-left: 5px; cursor: pointer!important;}
|
||||
|
@ -1344,9 +1344,9 @@ body .layui-table-tips .layui-layer-content{background: none; padding: 0; box-sh
|
|||
.layui-carousel[lay-indicator="outside"] .layui-carousel-ind ul{background-color: rgba(0,0,0,.5);}
|
||||
.layui-carousel[lay-indicator="none"] .layui-carousel-ind{display: none;}
|
||||
.layui-carousel-ind ul{display: inline-block; padding: 5px; background-color: rgba(0,0,0,.2); border-radius: 10px; -webkit-transition-duration: .3s; transition-duration: .3s;}
|
||||
.layui-carousel-ind li{display: inline-block; width: 10px; height: 10px; margin: 0 3px; font-size: 14px; background-color: #eee; background-color: rgba(255,255,255,.5); border-radius: 50%; cursor: pointer; -webkit-transition-duration: .3s; transition-duration: .3s;}
|
||||
.layui-carousel-ind li:hover{background-color: rgba(255,255,255,.7);}
|
||||
.layui-carousel-ind li.layui-this{background-color: #fff;}
|
||||
.layui-carousel-ind ul li{display: inline-block; width: 10px; height: 10px; margin: 0 3px; font-size: 14px; background-color: #eee; background-color: rgba(255,255,255,.5); border-radius: 50%; cursor: pointer; -webkit-transition-duration: .3s; transition-duration: .3s;}
|
||||
.layui-carousel-ind ul li:hover{background-color: rgba(255,255,255,.7);}
|
||||
.layui-carousel-ind ul li.layui-this{background-color: #fff;}
|
||||
.layui-carousel>*[carousel-item]>.layui-this,
|
||||
.layui-carousel>*[carousel-item]>.layui-carousel-prev,
|
||||
.layui-carousel>*[carousel-item]>.layui-carousel-next{display: block}
|
||||
|
|
|
@ -15,7 +15,7 @@
|
|||
}
|
||||
|
||||
,Layui = function(){
|
||||
this.v = '2.8.0-rc.12'; // Layui 版本号
|
||||
this.v = '2.8.0-rc.13'; // Layui 版本号
|
||||
}
|
||||
|
||||
//识别预先可能定义的指定全局对象
|
||||
|
|
|
@ -153,9 +153,9 @@ layui.define('jquery', function(exports){
|
|||
,tabDelete: function(e, othis){
|
||||
var li = othis || $(this).parent();
|
||||
var index = li.index();
|
||||
var parents = li.parents('.layui-tab').eq(0);
|
||||
var item = parents.children('.layui-tab-content>.layui-tab-item');
|
||||
var filter = parents.attr('lay-filter');
|
||||
var tabElem = li.closest('.layui-tab');
|
||||
var item = tabElem.children('.layui-tab-content').children('.layui-tab-item');
|
||||
var filter = tabElem.attr('lay-filter');
|
||||
|
||||
if(li.hasClass(THIS)){
|
||||
if (li.next()[0] && li.next().is('li')){
|
||||
|
@ -174,7 +174,7 @@ layui.define('jquery', function(exports){
|
|||
}, 50);
|
||||
|
||||
layui.event.call(this, MOD_NAME, 'tabDelete('+ filter +')', {
|
||||
elem: parents,
|
||||
elem: tabElem,
|
||||
index: index
|
||||
});
|
||||
}
|
||||
|
|
|
@ -1691,19 +1691,19 @@ layui.define(['lay', 'laytpl', 'laypage', 'form', 'util'], function(exports){
|
|||
|
||||
//滚动条补丁
|
||||
Class.prototype.scrollPatch = function(){
|
||||
var that = this
|
||||
,layMainTable = that.layMain.children('table')
|
||||
,scollWidth = that.layMain.width() - that.layMain.prop('clientWidth') //纵向滚动条宽度
|
||||
,scollHeight = that.layMain.height() - that.layMain.prop('clientHeight') //横向滚动条高度
|
||||
,getScrollWidth = that.getScrollWidth(that.layMain[0]) //获取主容器滚动条宽度,如果有的话
|
||||
,outWidth = layMainTable.outerWidth() - that.layMain.width() //表格内容器的超出宽度
|
||||
var that = this;
|
||||
var layMainTable = that.layMain.children('table');
|
||||
var scollWidth = that.layMain.width() - that.layMain.prop('clientWidth'); // 纵向滚动条宽度
|
||||
var scollHeight = that.layMain.height() - that.layMain.prop('clientHeight'); // 横向滚动条高度
|
||||
var getScrollWidth = that.getScrollWidth(that.layMain[0]); // 获取主容器滚动条宽度,如果有的话
|
||||
var outWidth = layMainTable.outerWidth() - that.layMain.width(); // 表格内容器的超出宽度
|
||||
|
||||
//添加补丁
|
||||
,addPatch = function(elem){
|
||||
// 添加补丁
|
||||
var addPatch = function(elem){
|
||||
if(scollWidth && scollHeight){
|
||||
elem = elem.eq(0);
|
||||
if(!elem.find('.layui-table-patch')[0]){
|
||||
var patchElem = $('<th class="layui-table-patch"><div class="layui-table-cell"></div></th>'); //补丁元素
|
||||
var patchElem = $('<th class="layui-table-patch"><div class="layui-table-cell"></div></th>'); // 补丁元素
|
||||
patchElem.find('div').css({
|
||||
width: scollWidth
|
||||
});
|
||||
|
@ -1712,20 +1712,28 @@ layui.define(['lay', 'laytpl', 'laypage', 'form', 'util'], function(exports){
|
|||
} else {
|
||||
elem.find('.layui-table-patch').remove();
|
||||
}
|
||||
}
|
||||
};
|
||||
|
||||
addPatch(that.layHeader);
|
||||
addPatch(that.layTotal);
|
||||
|
||||
//固定列区域高度
|
||||
var mainHeight = that.layMain.height()
|
||||
,fixHeight = mainHeight - scollHeight;
|
||||
that.layFixed.find(ELEM_BODY).css('height', layMainTable.height() >= fixHeight ? fixHeight : 'auto');
|
||||
// 固定列区域高度
|
||||
var mainHeight = that.layMain.height();
|
||||
var fixHeight = mainHeight - scollHeight;
|
||||
|
||||
//表格宽度小于容器宽度时,隐藏固定列
|
||||
that.layFixRight[outWidth > 0 ? 'removeClass' : 'addClass'](HIDE);
|
||||
that.layFixed.find(ELEM_BODY).css(
|
||||
'height',
|
||||
layMainTable.height() >= fixHeight ? fixHeight : 'auto'
|
||||
);
|
||||
|
||||
//操作栏
|
||||
// 表格宽度小于容器宽度时,隐藏固定列
|
||||
that.layFixRight[
|
||||
table.cache[that.key].length && outWidth > 0
|
||||
? 'removeClass'
|
||||
: 'addClass'
|
||||
](HIDE);
|
||||
|
||||
// 操作栏
|
||||
that.layFixRight.css('right', scollWidth - 1);
|
||||
};
|
||||
|
||||
|
|
Loading…
Reference in New Issue