Commit bf46a02b authored by hbcui1984's avatar hbcui1984

修正列表中checkbox无法点击的bug,并编译至mui v1.9.0

parent 2fa59ab1
/*!
* =====================================================
* Mui v1.8.0 (https://github.com/dcloudio/mui)
* Mui v1.9.0 (https://github.com/dcloudio/mui)
* =====================================================
*/
......
This diff is collapsed.
/*!
* =====================================================
* Mui v1.8.0 (https://github.com/dcloudio/mui)
* Mui v1.9.0 (https://github.com/dcloudio/mui)
* =====================================================
*/
/**
......@@ -5679,7 +5679,7 @@ var mui = (function(document, undefined) {
timer = $.later(function() {
toggleActive(true);
}, 100);
} else if (!(cell.querySelector('input') || cell.querySelector(SELECTOR_BUTTON) || cell.querySelector('.' + CLASS_TOGGLE))) {
} else{
toggleActive(true);
}
}
......@@ -5959,7 +5959,11 @@ var mui = (function(document, undefined) {
toggleActive(false);
sliderHandle && toggleEvents(cell, true);
});
var radioOrCheckboxClick = function() {
var radioOrCheckboxClick = function(event) {
var type = event.target&&event.target.type||'';
if(type==='radio'||type==='checkbox'){
return;
}
var classList = cell.classList;
if (classList.contains('mui-radio')) {
var input = cell.querySelector('input[type=radio]');
......@@ -5983,7 +5987,7 @@ var mui = (function(document, undefined) {
});
window.addEventListener('doubletap', function(event) {
if (cell) {
radioOrCheckboxClick();
radioOrCheckboxClick(event);
}
});
var preventDefaultException = /^(INPUT|TEXTAREA|BUTTON|SELECT)$/;
......@@ -5991,11 +5995,6 @@ var mui = (function(document, undefined) {
if (!cell) {
return;
}
var type = event.target && event.target.type;
if (type === 'radio' || type === 'checkbox') {
radioOrCheckboxClick();
return;
}
var isExpand = false;
var classList = cell.classList;
var ul = cell.parentNode;
......@@ -6044,7 +6043,7 @@ var mui = (function(document, undefined) {
// }
}
} else {
radioOrCheckboxClick();
radioOrCheckboxClick(event);
}
});
})(mui, window, document);
......
This source diff could not be displayed because it is too large. You can view the blob instead.
/*!
* =====================================================
* Mui v1.8.0 (https://github.com/dcloudio/mui)
* Mui v1.9.0 (https://github.com/dcloudio/mui)
* =====================================================
*/
......
This diff is collapsed.
/*!
* =====================================================
* Mui v1.8.0 (https://github.com/dcloudio/mui)
* Mui v1.9.0 (https://github.com/dcloudio/mui)
* =====================================================
*/
/**
......@@ -5679,7 +5679,7 @@ var mui = (function(document, undefined) {
timer = $.later(function() {
toggleActive(true);
}, 100);
} else if (!(cell.querySelector('input') || cell.querySelector(SELECTOR_BUTTON) || cell.querySelector('.' + CLASS_TOGGLE))) {
} else{
toggleActive(true);
}
}
......@@ -5959,7 +5959,11 @@ var mui = (function(document, undefined) {
toggleActive(false);
sliderHandle && toggleEvents(cell, true);
});
var radioOrCheckboxClick = function() {
var radioOrCheckboxClick = function(event) {
var type = event.target&&event.target.type||'';
if(type==='radio'||type==='checkbox'){
return;
}
var classList = cell.classList;
if (classList.contains('mui-radio')) {
var input = cell.querySelector('input[type=radio]');
......@@ -5983,7 +5987,7 @@ var mui = (function(document, undefined) {
});
window.addEventListener('doubletap', function(event) {
if (cell) {
radioOrCheckboxClick();
radioOrCheckboxClick(event);
}
});
var preventDefaultException = /^(INPUT|TEXTAREA|BUTTON|SELECT)$/;
......@@ -5991,11 +5995,6 @@ var mui = (function(document, undefined) {
if (!cell) {
return;
}
var type = event.target && event.target.type;
if (type === 'radio' || type === 'checkbox') {
radioOrCheckboxClick();
return;
}
var isExpand = false;
var classList = cell.classList;
var ul = cell.parentNode;
......@@ -6044,7 +6043,7 @@ var mui = (function(document, undefined) {
// }
}
} else {
radioOrCheckboxClick();
radioOrCheckboxClick(event);
}
});
})(mui, window, document);
......
This source diff could not be displayed because it is too large. You can view the blob instead.
......@@ -145,7 +145,7 @@
timer = $.later(function() {
toggleActive(true);
}, 100);
} else if (!(cell.querySelector('input') || cell.querySelector(SELECTOR_BUTTON) || cell.querySelector('.' + CLASS_TOGGLE))) {
} else{
toggleActive(true);
}
}
......@@ -425,7 +425,11 @@
toggleActive(false);
sliderHandle && toggleEvents(cell, true);
});
var radioOrCheckboxClick = function() {
var radioOrCheckboxClick = function(event) {
var type = event.target&&event.target.type||'';
if(type==='radio'||type==='checkbox'){
return;
}
var classList = cell.classList;
if (classList.contains($.className('radio'))) {
var input = cell.querySelector('input[type=radio]');
......@@ -449,7 +453,7 @@
});
window.addEventListener('doubletap', function(event) {
if (cell) {
radioOrCheckboxClick();
radioOrCheckboxClick(event);
}
});
var preventDefaultException = /^(INPUT|TEXTAREA|BUTTON|SELECT)$/;
......@@ -457,11 +461,6 @@
if (!cell) {
return;
}
var type = event.target && event.target.type;
if (type === 'radio' || type === 'checkbox') {
radioOrCheckboxClick();
return;
}
var isExpand = false;
var classList = cell.classList;
var ul = cell.parentNode;
......@@ -510,7 +509,7 @@
// }
}
} else {
radioOrCheckboxClick();
radioOrCheckboxClick(event);
}
});
})(mui, window, document);
\ No newline at end of file
{
"name": "mui",
"description": "Build mobile apps with simple HTML, CSS, and JS components.",
"version": "1.8.0",
"version": "1.9.0",
"keywords": [
"css",
"fonts",
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment