From cf2802ce7a5ed8df1a81ae05f97d5440b040f9b3 Mon Sep 17 00:00:00 2001 From: Jack Lukic Date: Wed, 24 Apr 2013 14:06:11 -0400 Subject: [PATCH] fixes logic for more complex example source --- docs/form.html | 3 +++ docs/javascript/semantic.js | 6 +++++- 2 files changed, 8 insertions(+), 1 deletion(-) diff --git a/docs/form.html b/docs/form.html index fb6ff947d..4e54a0881 100755 --- a/docs/form.html +++ b/docs/form.html @@ -180,6 +180,9 @@
Submit
+
+

This example uses a ui segment to add the padding and background color. This is not required.

+

Types of Content

diff --git a/docs/javascript/semantic.js b/docs/javascript/semantic.js index f9aaf8093..2d10bad83 100755 --- a/docs/javascript/semantic.js +++ b/docs/javascript/semantic.js @@ -42,12 +42,16 @@ semantic.ready = function() { var $example = $(this).closest('.example'), $shape = $example.find('.shape.module'), - $demo = $example.children().slice(2).not('.annotated'), + $demo = $example.children().slice(3).not('.annotated'), $annotated = $example.find('.annotated'), $code = $annotated.find('.code'), whiteSpace = new RegExp('\\n\\s{4}', 'g'), code = '' ; + // if ui has wrapper use that + if($demo.filter('.ui').size() === 0) { + $demo = $example.children().eq(3).children(); + } // add source if doesnt exist and initialize if($annotated.size() === 0) { $annotated = $('
')