You may be able to get data-dismiss
working on a non-modal element, but it's just as easy to do your own jQuery function:
http://jsfiddle.net/isherwood/KeChx/6
$('.close').click(function () {
$(this).parent('div').slideUp();
});
In this case there's no reason to dismiss the parent element once it's empty, but you certainly could like this:
$('.close').click(function () {
$(this).parent('div').slideUp();
if (! $('.wrapper > div') ) {
$('.wrapper').hide();
}
});
Here's an example of the above in action. I've set it to close the parent .wrapper
if the child count gets below 2 for clarity.
http://jsfiddle.net/isherwood/KeChx/8
function closeEmptyWrapper() {
var divCt = $('.wrapper').find('div').not(':hidden').size();
if (divCt < 2) {
$('.wrapper').fadeOut();
}
}
$('.close').click(function () {
$(this).parent('div').slideUp('', closeEmptyWrapper);
});