layedit build 第一个参数支持html对象

更新layedit的build方法,使其第一个参数支持传入原生html textarea对象。
This commit is contained in:
Eric Wong 2018-01-24 21:22:03 +08:00 committed by GitHub
parent ce3a0e7478
commit 7e9f523d57
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -54,7 +54,7 @@ layui.define(['layer', 'form'], function(exports){
var that = this
,config = that.config
,ELEM = 'layui-layedit', textArea = $('#'+id)
,ELEM = 'layui-layedit', textArea = $(typeof(id)=='string'?'#'+id:id)
,name = 'LAY_layedit_'+ (++that.index)
,haveBuild = textArea.next('.'+ELEM)