mirror of https://github.com/layui/layui
pre-release
parent
91736dad70
commit
caaff263bd
23
CHANGELOG.md
23
CHANGELOG.md
|
@ -1,4 +1,26 @@
|
||||||
|
|
||||||
|
# v1.0.9 2017-02-27
|
||||||
|
|
||||||
|
* 新增滑块组件
|
||||||
|
* select组件增加输入联想功能
|
||||||
|
* 导航增加三级菜单
|
||||||
|
* 新增“面板”页面显示结构
|
||||||
|
* 复选框增加原始风格样式(跟系统自带的类似样貌)
|
||||||
|
* 升级 layer弹层组件到 3.0.2
|
||||||
|
|
||||||
|
* 分页组件pages的改造、增加总数量、每页显示的数量
|
||||||
|
* 表单元素增加属性 lay-ignore ,设置后,将不会对对应的标签进行美化渲染
|
||||||
|
* 开关增加ON/OFF的文字自定义
|
||||||
|
|
||||||
|
* 修复Tab选项卡嵌套的Tab没有对应的内容结构时,切换到了父级内容的bug
|
||||||
|
* 修复Tab选项卡容器中使用下拉框时,被溢出隐藏的问题
|
||||||
|
* 修复Tab选项卡bug:http://fly.layui.com/jie/7492.html
|
||||||
|
* 用于操作Tab选项卡的tabAdd/tabDelete/tabChange改动,增加ID,用于在删除和切换时,以id作为匹配媒介
|
||||||
|
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
|
||||||
# v1.0.8 2017-02-21
|
# v1.0.8 2017-02-21
|
||||||
|
|
||||||
* 新增“进度条”页面元素及相关操作方法
|
* 新增“进度条”页面元素及相关操作方法
|
||||||
|
@ -6,6 +28,7 @@
|
||||||
* 新增按钮组样式
|
* 新增按钮组样式
|
||||||
* 新增赤、橙、绿、青、蓝、黑、灰7中背景样式(见文档:页面元素→CSS公共类)
|
* 新增赤、橙、绿、青、蓝、黑、灰7中背景样式(见文档:页面元素→CSS公共类)
|
||||||
* 新增7个字体图标
|
* 新增7个字体图标
|
||||||
|
|
||||||
* 完善loading图标在旋转时出现偏移的不友好问题
|
* 完善loading图标在旋转时出现偏移的不友好问题
|
||||||
* 完善表单元素设置为盒子风格时,复选框/单选框等区块的别扭问题。需对特定区块设置pane属性。
|
* 完善表单元素设置为盒子风格时,复选框/单选框等区块的别扭问题。需对特定区块设置pane属性。
|
||||||
* 对盒子风格的表单字段开启验证高亮提示,以及hover/focus效果
|
* 对盒子风格的表单字段开启验证高亮提示,以及hover/focus效果
|
||||||
|
|
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
|
@ -0,0 +1,6 @@
|
||||||
|
[{000214A0-0000-0000-C000-000000000046}]
|
||||||
|
Prop3=19,11
|
||||||
|
[InternetShortcut]
|
||||||
|
URL=https://github.com/sentsin/layui/
|
||||||
|
IDList=
|
||||||
|
HotKey=0
|
|
@ -0,0 +1,8 @@
|
||||||
|
[{000214A0-0000-0000-C000-000000000046}]
|
||||||
|
Prop3=19,2
|
||||||
|
[InternetShortcut]
|
||||||
|
URL=http://www.layui.com/demo/
|
||||||
|
IDList=
|
||||||
|
HotKey=0
|
||||||
|
IconIndex=0
|
||||||
|
IconFile=C:\Program Files (x86)\Google\Chrome\Application\chrome.exe
|
|
@ -0,0 +1,8 @@
|
||||||
|
[{000214A0-0000-0000-C000-000000000046}]
|
||||||
|
Prop3=19,2
|
||||||
|
[InternetShortcut]
|
||||||
|
URL=http://www.layui.com/doc/
|
||||||
|
IDList=
|
||||||
|
HotKey=0
|
||||||
|
IconIndex=0
|
||||||
|
IconFile=C:\Program Files (x86)\Google\Chrome\Application\chrome.exe
|
|
@ -406,6 +406,7 @@ a cite{font-style: normal; *cursor:pointer;}
|
||||||
.layui-tab-title{position: relative; left: 0; height: 40px; white-space: nowrap; font-size: 0; border-bottom: 1px solid #e2e2e2; transition: all .2s; -webkit-transition: all .2s;}
|
.layui-tab-title{position: relative; left: 0; height: 40px; white-space: nowrap; font-size: 0; border-bottom: 1px solid #e2e2e2; transition: all .2s; -webkit-transition: all .2s;}
|
||||||
.layui-tab-title li{display: inline-block; *display: inline; *zoom: 1; vertical-align: middle; font-size: 14px; transition: all .3s; -webkit-transition: all .3s;}
|
.layui-tab-title li{display: inline-block; *display: inline; *zoom: 1; vertical-align: middle; font-size: 14px; transition: all .3s; -webkit-transition: all .3s;}
|
||||||
.layui-tab-title li{position: relative; line-height: 40px; min-width: 65px; padding: 0 10px; text-align: center; cursor: pointer;}
|
.layui-tab-title li{position: relative; line-height: 40px; min-width: 65px; padding: 0 10px; text-align: center; cursor: pointer;}
|
||||||
|
.layui-tab-title li a{display: block;}
|
||||||
.layui-tab-title .layui-this{color: #000;}
|
.layui-tab-title .layui-this{color: #000;}
|
||||||
|
|
||||||
.layui-tab-title .layui-this:after{position: absolute; left:0; top: 0; content: ''; width:100%; height: 41px; border: 1px solid #e2e2e2; border-bottom-color: #fff; border-radius: 2px 2px 0 0; -webkit-box-sizing: border-box !important; -moz-box-sizing: border-box !important; box-sizing: border-box !important; pointer-events: none;}
|
.layui-tab-title .layui-this:after{position: absolute; left:0; top: 0; content: ''; width:100%; height: 41px; border: 1px solid #e2e2e2; border-bottom-color: #fff; border-radius: 2px 2px 0 0; -webkit-box-sizing: border-box !important; -moz-box-sizing: border-box !important; box-sizing: border-box !important; pointer-events: none;}
|
||||||
|
|
|
@ -1,9 +1,9 @@
|
||||||
/**
|
/**
|
||||||
|
|
||||||
@Name: layer
|
@Name: layer
|
||||||
@Author: 贤心
|
@Author: 贤心
|
||||||
|
|
||||||
*/
|
**/
|
||||||
|
|
||||||
*html{background-image: url(about:blank); background-attachment: fixed;}
|
*html{background-image: url(about:blank); background-attachment: fixed;}
|
||||||
html #layuicss-skinlayercss{display: none; position: absolute; width: 1989px;}
|
html #layuicss-skinlayercss{display: none; position: absolute; width: 1989px;}
|
||||||
|
@ -16,7 +16,7 @@ html #layuicss-skinlayercss{display: none; position: absolute; width: 1989px;}
|
||||||
.layui-layer-close{position:absolute;}
|
.layui-layer-close{position:absolute;}
|
||||||
.layui-layer-content{position:relative;}
|
.layui-layer-content{position:relative;}
|
||||||
.layui-layer-border{border: 1px solid #B2B2B2; border: 1px solid rgba(0,0,0,.1); box-shadow: 1px 1px 5px rgba(0,0,0,.2);}
|
.layui-layer-border{border: 1px solid #B2B2B2; border: 1px solid rgba(0,0,0,.1); box-shadow: 1px 1px 5px rgba(0,0,0,.2);}
|
||||||
.layui-layer-load{background:url(loading-1.gif) center center no-repeat;}
|
.layui-layer-load{background:url(loading-1.gif) #eee center center no-repeat;}
|
||||||
.layui-layer-ico{ background:url(icon.png) no-repeat;}
|
.layui-layer-ico{ background:url(icon.png) no-repeat;}
|
||||||
.layui-layer-dialog .layui-layer-ico,
|
.layui-layer-dialog .layui-layer-ico,
|
||||||
.layui-layer-setwin a,
|
.layui-layer-setwin a,
|
||||||
|
@ -48,19 +48,7 @@ html #layuicss-skinlayercss{display: none; position: absolute; width: 1989px;}
|
||||||
|
|
||||||
@keyframes layer-fadeIn{0%{opacity:0}100%{opacity:1}}.layer-anim-05{-webkit-animation-name:layer-fadeIn;animation-name:layer-fadeIn}
|
@keyframes layer-fadeIn{0%{opacity:0}100%{opacity:1}}.layer-anim-05{-webkit-animation-name:layer-fadeIn;animation-name:layer-fadeIn}
|
||||||
|
|
||||||
@-webkit-keyframes shake{0%,100%{-webkit-transform:translateX(0);transform:translateX(0)}10%,30%,50%,70%,90%{-webkit-transform:translateX(-10px);transform:translateX(-10px)}20%,40%,60%,80%{-webkit-transform:translateX(10px);transform:translateX(10px)}}@keyframes shake{0%,100%{-webkit-transform:translateX(0);-ms-transform:translateX(0);transform:translateX(0)}10%,30%,50%,70%,90%{-webkit-transform:translateX(-10px);-ms-transform:translateX(-10px);transform:translateX(-10px)}20%,40%,60%,80%{-webkit-transform:translateX(10px);-ms-transform:translateX(10px);transform:translateX(10px)}}.layer-anim-06{-webkit-animation-name:shake;animation-name:shake}@-webkit-keyframes layer-fadeIn{0%{opacity:0}100%{opacity:1}}
|
@-webkit-keyframes layer-shake{0%,100%{-webkit-transform:translateX(0);transform:translateX(0)}10%,30%,50%,70%,90%{-webkit-transform:translateX(-10px);transform:translateX(-10px)}20%,40%,60%,80%{-webkit-transform:translateX(10px);transform:translateX(10px)}}@keyframes layer-shake{0%,100%{-webkit-transform:translateX(0);-ms-transform:translateX(0);transform:translateX(0)}10%,30%,50%,70%,90%{-webkit-transform:translateX(-10px);-ms-transform:translateX(-10px);transform:translateX(-10px)}20%,40%,60%,80%{-webkit-transform:translateX(10px);-ms-transform:translateX(10px);transform:translateX(10px)}}.layer-anim-06{-webkit-animation-name:layer-shake;animation-name:layer-shake}@-webkit-keyframes fadeIn{0%{opacity:0}100%{opacity:1}}
|
||||||
|
|
||||||
@-webkit-keyframes layer-bounceOut { /* 关闭动画 */
|
|
||||||
100% {opacity: 0; -webkit-transform: scale(.7); transform: scale(.7)}
|
|
||||||
30% {-webkit-transform: scale(1.05); transform: scale(1.05)}
|
|
||||||
0% {-webkit-transform: scale(1); transform: scale(1);}
|
|
||||||
}
|
|
||||||
@keyframes layer-bounceOut {
|
|
||||||
100% {opacity: 0; -webkit-transform: scale(.7); -ms-transform: scale(.7); transform: scale(.7);}
|
|
||||||
30% {-webkit-transform: scale(1.05); -ms-transform: scale(1.05); transform: scale(1.05);}
|
|
||||||
0% {-webkit-transform: scale(1); -ms-transform: scale(1);transform: scale(1);}
|
|
||||||
}
|
|
||||||
.layer-anim-close{-webkit-animation-name: layer-bounceOut;animation-name: layer-bounceOut; -webkit-animation-duration:.2s; animation-duration:.2s;}
|
|
||||||
|
|
||||||
/* 标题栏 */
|
/* 标题栏 */
|
||||||
.layui-layer-title{padding:0 80px 0 20px; height:42px; line-height:42px; border-bottom:1px solid #eee; font-size:14px; color:#333; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; background-color: #F8F8F8; border-radius: 2px 2px 0 0;}
|
.layui-layer-title{padding:0 80px 0 20px; height:42px; line-height:42px; border-bottom:1px solid #eee; font-size:14px; color:#333; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; background-color: #F8F8F8; border-radius: 2px 2px 0 0;}
|
||||||
|
@ -72,14 +60,14 @@ html #layuicss-skinlayercss{display: none; position: absolute; width: 1989px;}
|
||||||
.layui-layer-setwin .layui-layer-max:hover{background-position:-16px -40px;}
|
.layui-layer-setwin .layui-layer-max:hover{background-position:-16px -40px;}
|
||||||
.layui-layer-setwin .layui-layer-maxmin{background-position:-65px -40px;}
|
.layui-layer-setwin .layui-layer-maxmin{background-position:-65px -40px;}
|
||||||
.layui-layer-setwin .layui-layer-maxmin:hover{background-position:-49px -40px;}
|
.layui-layer-setwin .layui-layer-maxmin:hover{background-position:-49px -40px;}
|
||||||
.layui-layer-setwin .layui-layer-close1{background-position:0 -40px; cursor:pointer;}
|
.layui-layer-setwin .layui-layer-close1{background-position: 1px -40px; cursor: pointer;}
|
||||||
.layui-layer-setwin .layui-layer-close1:hover{opacity:0.7;}
|
.layui-layer-setwin .layui-layer-close1:hover{opacity:0.7;}
|
||||||
.layui-layer-setwin .layui-layer-close2{position:absolute; right:-28px; top:-28px; width:30px; height:30px; margin-left:0; background-position:-149px -31px; *right:-18px; _display:none;}
|
.layui-layer-setwin .layui-layer-close2{position:absolute; right:-28px; top:-28px; width:30px; height:30px; margin-left:0; background-position:-149px -31px; *right:-18px; _display:none;}
|
||||||
.layui-layer-setwin .layui-layer-close2:hover{ background-position:-180px -31px;}
|
.layui-layer-setwin .layui-layer-close2:hover{ background-position:-180px -31px;}
|
||||||
|
|
||||||
/* 按钮栏 */
|
/* 按钮栏 */
|
||||||
.layui-layer-btn{text-align: right; padding:0 10px 12px; pointer-events: auto; user-select: none; -webkit-user-select: none;}
|
.layui-layer-btn{text-align: right; padding:0 10px 12px; pointer-events: auto; user-select: none; -webkit-user-select: none;}
|
||||||
.layui-layer-btn a{height: 28px; line-height: 28px; margin: 0 6px; padding: 0 15px; border:1px #dedede solid; background-color:#f1f1f1; color: #333; border-radius: 2px; font-weight:400; cursor:pointer; text-decoration: none;}
|
.layui-layer-btn a{height: 28px; line-height: 28px; margin: 6px 6px 0; padding: 0 15px; border:1px #dedede solid; background-color:#f1f1f1; color: #333; border-radius: 2px; font-weight:400; cursor:pointer; text-decoration: none;}
|
||||||
.layui-layer-btn a:hover{opacity: 0.9; text-decoration: none;}
|
.layui-layer-btn a:hover{opacity: 0.9; text-decoration: none;}
|
||||||
.layui-layer-btn a:active{opacity: 0.8;}
|
.layui-layer-btn a:active{opacity: 0.8;}
|
||||||
.layui-layer-btn .layui-layer-btn0{border-color: #4898d5; background-color: #2e8ded; color:#fff;}
|
.layui-layer-btn .layui-layer-btn0{border-color: #4898d5; background-color: #2e8ded; color:#fff;}
|
||||||
|
@ -124,7 +112,7 @@ html #layuicss-skinlayercss{display: none; position: absolute; width: 1989px;}
|
||||||
/* skin */
|
/* skin */
|
||||||
.layui-layer-lan[type="dialog"]{min-width:280px;}
|
.layui-layer-lan[type="dialog"]{min-width:280px;}
|
||||||
.layui-layer-lan .layui-layer-title{background:#4476A7; color:#fff; border: none;}
|
.layui-layer-lan .layui-layer-title{background:#4476A7; color:#fff; border: none;}
|
||||||
.layui-layer-lan .layui-layer-btn{padding:10px; text-align: right; border-top:1px solid #E9E7E7}
|
.layui-layer-lan .layui-layer-btn{padding: 5px 10px 10px; text-align: right; border-top:1px solid #E9E7E7}
|
||||||
.layui-layer-lan .layui-layer-btn a{background:#BBB5B5; border:none;}
|
.layui-layer-lan .layui-layer-btn a{background:#BBB5B5; border:none;}
|
||||||
.layui-layer-lan .layui-layer-btn .layui-layer-btn1{background:#C9C5C5;}
|
.layui-layer-lan .layui-layer-btn .layui-layer-btn1{background:#C9C5C5;}
|
||||||
.layui-layer-molv .layui-layer-title{background:#009f95; color:#fff; border: none;}
|
.layui-layer-molv .layui-layer-title{background:#009f95; color:#fff; border: none;}
|
||||||
|
@ -159,7 +147,7 @@ html #layuicss-skinlayercss{display: none; position: absolute; width: 1989px;}
|
||||||
.xubox_tabclose{position:absolute; right:10px; top:5px; cursor:pointer;}
|
.xubox_tabclose{position:absolute; right:10px; top:5px; cursor:pointer;}
|
||||||
|
|
||||||
/* photo模式 */
|
/* photo模式 */
|
||||||
.layui-layer-photos{-webkit-animation-duration:1s; animation-duration:1s;}
|
.layui-layer-photos{-webkit-animation-duration: .8s; animation-duration: .8s;}
|
||||||
.layui-layer-photos .layui-layer-content{overflow:hidden; text-align: center;}
|
.layui-layer-photos .layui-layer-content{overflow:hidden; text-align: center;}
|
||||||
.layui-layer-photos .layui-layer-phimg img{position: relative; width:100%; display: inline-block; *display:inline; *zoom:1; vertical-align:top;}
|
.layui-layer-photos .layui-layer-phimg img{position: relative; width:100%; display: inline-block; *display:inline; *zoom:1; vertical-align:top;}
|
||||||
.layui-layer-imguide,.layui-layer-imgbar{display:none;}
|
.layui-layer-imguide,.layui-layer-imgbar{display:none;}
|
||||||
|
@ -175,6 +163,18 @@ html #layuicss-skinlayercss{display: none; position: absolute; width: 1989px;}
|
||||||
.layui-layer-imgtit a:hover{color:#fff; text-decoration:underline;}
|
.layui-layer-imgtit a:hover{color:#fff; text-decoration:underline;}
|
||||||
.layui-layer-imgtit em{padding-left:10px; font-style: normal;}
|
.layui-layer-imgtit em{padding-left:10px; font-style: normal;}
|
||||||
|
|
||||||
|
/* 关闭动画 */
|
||||||
|
@-webkit-keyframes layer-bounceOut {
|
||||||
|
100% {opacity: 0; -webkit-transform: scale(.7); transform: scale(.7)}
|
||||||
|
30% {-webkit-transform: scale(1.05); transform: scale(1.05)}
|
||||||
|
0% {-webkit-transform: scale(1); transform: scale(1);}
|
||||||
|
}
|
||||||
|
@keyframes layer-bounceOut {
|
||||||
|
100% {opacity: 0; -webkit-transform: scale(.7); -ms-transform: scale(.7); transform: scale(.7);}
|
||||||
|
30% {-webkit-transform: scale(1.05); -ms-transform: scale(1.05); transform: scale(1.05);}
|
||||||
|
0% {-webkit-transform: scale(1); -ms-transform: scale(1);transform: scale(1);}
|
||||||
|
}
|
||||||
|
.layer-anim-close{-webkit-animation-name: layer-bounceOut;animation-name: layer-bounceOut; -webkit-animation-duration:.2s; animation-duration:.2s;}
|
||||||
|
|
||||||
@media screen and (max-width: 1100px) {
|
@media screen and (max-width: 1100px) {
|
||||||
.layui-layer-iframe{overflow-y: auto; -webkit-overflow-scrolling: touch;}
|
.layui-layer-iframe{overflow-y: auto; -webkit-overflow-scrolling: touch;}
|
||||||
|
|
|
@ -1,6 +1,6 @@
|
||||||
/**
|
/**
|
||||||
|
|
||||||
@Name:layer v3.0.1 Web弹层组件
|
@Name:layer v3.0.2 Web弹层组件
|
||||||
@Author:贤心
|
@Author:贤心
|
||||||
@Site:http://layer.layui.com
|
@Site:http://layer.layui.com
|
||||||
@License:MIT
|
@License:MIT
|
||||||
|
@ -26,7 +26,7 @@ var isLayui = window.layui && layui.define, $, win, ready = {
|
||||||
|
|
||||||
//默认内置方法。
|
//默认内置方法。
|
||||||
var layer = {
|
var layer = {
|
||||||
v: '3.0.1',
|
v: '3.0.2',
|
||||||
ie: function(){ //ie版本
|
ie: function(){ //ie版本
|
||||||
var agent = navigator.userAgent.toLowerCase();
|
var agent = navigator.userAgent.toLowerCase();
|
||||||
return (!!window.ActiveXObject || "ActiveXObject" in window) ? (
|
return (!!window.ActiveXObject || "ActiveXObject" in window) ? (
|
||||||
|
@ -83,7 +83,7 @@ var layer = {
|
||||||
},
|
},
|
||||||
|
|
||||||
ready: function(callback){
|
ready: function(callback){
|
||||||
var cssname = 'skinlayercss', ver = '1110';
|
var cssname = 'skinlayercss', ver = '302';
|
||||||
isLayui ? layui.addcss('modules/layer/default/layer.css?v='+layer.v+ver, callback, cssname)
|
isLayui ? layui.addcss('modules/layer/default/layer.css?v='+layer.v+ver, callback, cssname)
|
||||||
: layer.link('skin/default/layer.css?v='+layer.v+ver, callback, cssname);
|
: layer.link('skin/default/layer.css?v='+layer.v+ver, callback, cssname);
|
||||||
return this;
|
return this;
|
||||||
|
@ -167,9 +167,11 @@ var Class = function(setings){
|
||||||
var that = this;
|
var that = this;
|
||||||
that.index = ++layer.index;
|
that.index = ++layer.index;
|
||||||
that.config = $.extend({}, that.config, ready.config, setings);
|
that.config = $.extend({}, that.config, ready.config, setings);
|
||||||
|
layer.ready(function(){
|
||||||
document.body ? that.creat() : setTimeout(function(){
|
document.body ? that.creat() : setTimeout(function(){
|
||||||
that.creat();
|
that.creat();
|
||||||
}, 50);
|
}, 50);
|
||||||
|
});
|
||||||
};
|
};
|
||||||
|
|
||||||
Class.pt = Class.prototype;
|
Class.pt = Class.prototype;
|
||||||
|
@ -942,6 +944,9 @@ layer.prompt = function(options, yes){
|
||||||
return '<input type="'+ (options.formType == 1 ? 'password' : 'text') +'" class="layui-layer-input" value="'+ (options.value||'') +'">';
|
return '<input type="'+ (options.formType == 1 ? 'password' : 'text') +'" class="layui-layer-input" value="'+ (options.value||'') +'">';
|
||||||
}();
|
}();
|
||||||
|
|
||||||
|
var success = options.success;
|
||||||
|
delete options.success;
|
||||||
|
|
||||||
return layer.open($.extend({
|
return layer.open($.extend({
|
||||||
type: 1
|
type: 1
|
||||||
,btn: ['确定','取消']
|
,btn: ['确定','取消']
|
||||||
|
@ -951,6 +956,7 @@ layer.prompt = function(options, yes){
|
||||||
,success: function(layero){
|
,success: function(layero){
|
||||||
prompt = layero.find('.layui-layer-input');
|
prompt = layero.find('.layui-layer-input');
|
||||||
prompt.focus();
|
prompt.focus();
|
||||||
|
typeof success === 'function' && success(layero);
|
||||||
}
|
}
|
||||||
,resize: false
|
,resize: false
|
||||||
,yes: function(index){
|
,yes: function(index){
|
||||||
|
@ -969,7 +975,12 @@ layer.prompt = function(options, yes){
|
||||||
//tab层
|
//tab层
|
||||||
layer.tab = function(options){
|
layer.tab = function(options){
|
||||||
options = options || {};
|
options = options || {};
|
||||||
var tab = options.tab || {};
|
|
||||||
|
var tab = options.tab || {}
|
||||||
|
,success = options.success;
|
||||||
|
|
||||||
|
delete options.success;
|
||||||
|
|
||||||
return layer.open($.extend({
|
return layer.open($.extend({
|
||||||
type: 1,
|
type: 1,
|
||||||
skin: 'layui-layer-tab' + skin('tab'),
|
skin: 'layui-layer-tab' + skin('tab'),
|
||||||
|
@ -1004,6 +1015,7 @@ layer.tab = function(options){
|
||||||
main.eq(index).show().siblings().hide();
|
main.eq(index).show().siblings().hide();
|
||||||
typeof options.change === 'function' && options.change(index);
|
typeof options.change === 'function' && options.change(index);
|
||||||
});
|
});
|
||||||
|
typeof success === 'function' && success(layero);
|
||||||
}
|
}
|
||||||
}, options));
|
}, options));
|
||||||
};
|
};
|
||||||
|
@ -1020,6 +1032,9 @@ layer.photos = function(options, loop, key){
|
||||||
|
|
||||||
options.img = options.img || 'img';
|
options.img = options.img || 'img';
|
||||||
|
|
||||||
|
var success = options.success;
|
||||||
|
delete options.success;
|
||||||
|
|
||||||
if(!type){ //页面直接获取
|
if(!type){ //页面直接获取
|
||||||
var parent = $(options.photos), pushData = function(){
|
var parent = $(options.photos), pushData = function(){
|
||||||
data = [];
|
data = [];
|
||||||
|
@ -1098,7 +1113,9 @@ layer.photos = function(options, loop, key){
|
||||||
if(data.length <= 1) return;
|
if(data.length <= 1) return;
|
||||||
photos.start = dict.imgIndex - 1;
|
photos.start = dict.imgIndex - 1;
|
||||||
layer.close(dict.index);
|
layer.close(dict.index);
|
||||||
|
setTimeout(function(){
|
||||||
layer.photos(options, true, key);
|
layer.photos(options, true, key);
|
||||||
|
}, 200);
|
||||||
}
|
}
|
||||||
|
|
||||||
//一些动作
|
//一些动作
|
||||||
|
@ -1143,10 +1160,12 @@ layer.photos = function(options, loop, key){
|
||||||
shade: 'shade' in options ? false : 0.9,
|
shade: 'shade' in options ? false : 0.9,
|
||||||
scrollbar: false
|
scrollbar: false
|
||||||
});
|
});
|
||||||
|
|
||||||
loadImage(data[start].src, function(img){
|
loadImage(data[start].src, function(img){
|
||||||
layer.close(dict.loadi);
|
layer.close(dict.loadi);
|
||||||
dict.index = layer.open($.extend({
|
dict.index = layer.open($.extend({
|
||||||
type: 1,
|
type: 1,
|
||||||
|
id: 'layui-layer-photos',
|
||||||
area: function(){
|
area: function(){
|
||||||
var imgarea = [img.width, img.height];
|
var imgarea = [img.width, img.height];
|
||||||
var winarea = [$(window).width() - 100, $(window).height() - 100];
|
var winarea = [$(window).width() - 100, $(window).height() - 100];
|
||||||
|
@ -1187,6 +1206,7 @@ layer.photos = function(options, loop, key){
|
||||||
dict.imgsee = layero.find('.layui-layer-imguide,.layui-layer-imgbar');
|
dict.imgsee = layero.find('.layui-layer-imguide,.layui-layer-imgbar');
|
||||||
dict.event(layero);
|
dict.event(layero);
|
||||||
options.tab && options.tab(data[start], layero);
|
options.tab && options.tab(data[start], layero);
|
||||||
|
typeof success === 'function' && success(layero);
|
||||||
}, end: function(){
|
}, end: function(){
|
||||||
dict.end = true;
|
dict.end = true;
|
||||||
$(document).off('keyup', dict.keyup);
|
$(document).off('keyup', dict.keyup);
|
||||||
|
@ -1227,7 +1247,7 @@ window.layui && layui.define ? (
|
||||||
exports('layer', layer);
|
exports('layer', layer);
|
||||||
})
|
})
|
||||||
) : (
|
) : (
|
||||||
typeof define === 'function' ? define(['jquery'], function(){ //requirejs加载
|
(typeof define === 'function' && define.amd) ? define(['jquery'], function(){ //requirejs加载
|
||||||
ready.run(window.jQuery);
|
ready.run(window.jQuery);
|
||||||
return layer;
|
return layer;
|
||||||
}) : function(){ //普通script标签加载
|
}) : function(){ //普通script标签加载
|
||||||
|
|
|
@ -1,6 +1,6 @@
|
||||||
/**
|
/**
|
||||||
|
|
||||||
@Name:layim mobile 1.0.2 Beta 临时版
|
@Name:layim mobile 1.0.3
|
||||||
@Author:贤心
|
@Author:贤心
|
||||||
@Site:http://layim.layui.com
|
@Site:http://layim.layui.com
|
||||||
@License:LGPL
|
@License:LGPL
|
||||||
|
@ -9,7 +9,7 @@
|
||||||
|
|
||||||
layui.define(['laytpl', 'upload-mobile', 'layer-mobile', 'zepto'], function(exports){
|
layui.define(['laytpl', 'upload-mobile', 'layer-mobile', 'zepto'], function(exports){
|
||||||
|
|
||||||
var v = '1.0 Beta';
|
var v = '1.0.3';
|
||||||
var $ = layui.zepto;
|
var $ = layui.zepto;
|
||||||
var laytpl = layui.laytpl;
|
var laytpl = layui.laytpl;
|
||||||
var layer = layui['layer-mobile'];
|
var layer = layui['layer-mobile'];
|
||||||
|
@ -684,6 +684,6 @@ layui.define(['laytpl', 'upload-mobile', 'layer-mobile', 'zepto'], function(expo
|
||||||
exports('layim-mobile', new LAYIM());
|
exports('layim-mobile', new LAYIM());
|
||||||
|
|
||||||
}).addcss(
|
}).addcss(
|
||||||
'modules/layim/mobile/layim.css?v=1.0Beta'
|
'modules/layim/mobile/layim.css?v=1.03'
|
||||||
,'skinlayim-mobilecss'
|
,'skinlayim-mobilecss'
|
||||||
);
|
);
|
Loading…
Reference in New Issue