Skip to content
Permalink
Browse files

demos/index.html: added functionality to pull descriptions from indiv…

…idual html files.
  • Loading branch information
Ca-Phun Ung
Ca-Phun Ung committed Dec 30, 2008
1 parent 31b8edc commit 5d1b0cb7557d89d790858cef2c5cdb7ca888a552
Showing with 13 additions and 0 deletions.
  1. +13 −0 demos/index.html
@@ -37,8 +37,21 @@
$(this).click(function() {
$(this).parents('ul').find('li').removeClass('demo-config-on');
$(this).parent().addClass('demo-config-on');
$('#demo-notes').hide();
$('#demo-frame').fadeOut();
});
});
$('#demo-frame').load(function(){
var notes = $('.demo-description *', $(this).contents()[0]);
if ($('#demo-notes').length == 0) {
$('<div id="demo-notes" />').insertAfter('#demo-config');
}
$('#demo-notes').hide().empty().html(notes);
$('#demo-frame').fadeIn({complete: function() {
$('#demo-notes').fadeIn();
}});
});
})
.end()
.end()

0 comments on commit 5d1b0cb

Please sign in to comment.
You can’t perform that action at this time.