diff options
author | Jörn Zaefferer <joern.zaefferer@gmail.com> | 2009-01-08 21:51:13 +0000 |
---|---|---|
committer | Jörn Zaefferer <joern.zaefferer@gmail.com> | 2009-01-08 21:51:13 +0000 |
commit | d3d933066c65f32ea52eef5c46472ed97fba974f (patch) | |
tree | 455b1e183074fc2b35564e9be96cd3cdcc948dc8 /demos/index.html | |
parent | d232d207b540ad8de92086d3aac18a83a7b519fb (diff) | |
download | jquery-ui-d3d933066c65f32ea52eef5c46472ed97fba974f.tar.gz jquery-ui-d3d933066c65f32ea52eef5c46472ed97fba974f.zip |
integrating documentation into demo files, first draft; run Ant targets docs-download and docs-process to generate the files
Diffstat (limited to 'demos/index.html')
-rw-r--r-- | demos/index.html | 22 |
1 files changed, 21 insertions, 1 deletions
diff --git a/demos/index.html b/demos/index.html index 8aeabfc15..e7f19ab84 100644 --- a/demos/index.html +++ b/demos/index.html @@ -162,8 +162,28 @@ $('#demo-frame').empty().html(data); $('#demo-link a').attr('href', path); updateDemoNotes(); - }); + if (/default.html$/.test(path)) { + $.get("../documentation/" + path.match(/demos\/(.+)\//)[1] + ".html", function(html) { + $("#demo-notes").after(html); + $("#widget-docs").tabs(); + $(".param-header").click(function() { + $(this).parent().toggleClass("param-open").end().next().toggle(); + }); + $(".docs-list-header").each(function() { + var header = $(this); + var details = header.next().find(".param-details").hide(); + $("a:first", header).click(function() { + details.show().parent().addClass("param-open"); + return false; + }); + $("a:last", header).click(function() { + details.hide().parent().removeClass("param-open"); + return false; + }); + }); + }); + } } function updateDemoNotes() { |