2024-11-10 07:01:22 +00:00
|
|
|
function isActive(current, index, disabled) {
|
|
|
|
if (disabled) {
|
|
|
|
return false;
|
|
|
|
}
|
|
|
|
return (current || []).indexOf(index) >= 0;
|
|
|
|
}
|
|
|
|
function getStyleHeight(index, contentHeight, disabled) {
|
|
|
|
if (disabled) {
|
|
|
|
return 'height: 0px';
|
|
|
|
}
|
2024-12-01 11:56:54 +00:00
|
|
|
var height = contentHeight[index];
|
2024-11-10 07:01:22 +00:00
|
|
|
if (height === '') {
|
|
|
|
return '';
|
|
|
|
}
|
|
|
|
if (height) {
|
2024-12-01 11:56:54 +00:00
|
|
|
return "height: ".concat(height);
|
2024-11-10 07:01:22 +00:00
|
|
|
}
|
|
|
|
return 'height: 0px';
|
|
|
|
}
|
2024-12-01 11:56:54 +00:00
|
|
|
export default {
|
|
|
|
isActive: isActive,
|
|
|
|
getStyleHeight: getStyleHeight
|
|
|
|
};
|