diff --git a/assets/javascripts/views/pages/javascript.coffee b/assets/javascripts/views/pages/javascript.coffee index 6dc520a5..114bbe24 100644 --- a/assets/javascripts/views/pages/javascript.coffee +++ b/assets/javascripts/views/pages/javascript.coffee @@ -15,7 +15,6 @@ class app.views.JavascriptWithMarkupCheckPage extends app.views.BasePage @highlightCode el, language return -app.views.ChaiPage = app.views.GruntPage = app.views.MochaPage = app.views.JavascriptPage diff --git a/assets/javascripts/views/pages/simple.coffee b/assets/javascripts/views/pages/simple.coffee index 33b47deb..281ff308 100644 --- a/assets/javascripts/views/pages/simple.coffee +++ b/assets/javascripts/views/pages/simple.coffee @@ -9,6 +9,7 @@ class app.views.SimplePage extends app.views.BasePage app.views.AngularPage = app.views.AngularjsPage = app.views.CakephpPage = +app.views.ChaiPage = app.views.ElixirPage = app.views.EmberPage = app.views.ExpressPage = diff --git a/assets/stylesheets/application-dark.css.scss b/assets/stylesheets/application-dark.css.scss index 1b79638e..56e605da 100644 --- a/assets/stylesheets/application-dark.css.scss +++ b/assets/stylesheets/application-dark.css.scss @@ -37,7 +37,6 @@ 'pages/bower', 'pages/c', 'pages/cakephp', - 'pages/chai', 'pages/clojure', 'pages/coffeescript', 'pages/d3', diff --git a/assets/stylesheets/application.css.scss b/assets/stylesheets/application.css.scss index 75bd4805..365e7636 100644 --- a/assets/stylesheets/application.css.scss +++ b/assets/stylesheets/application.css.scss @@ -37,7 +37,6 @@ 'pages/bower', 'pages/c', 'pages/cakephp', - 'pages/chai', 'pages/clojure', 'pages/coffeescript', 'pages/d3', diff --git a/assets/stylesheets/pages/_chai.scss b/assets/stylesheets/pages/_chai.scss deleted file mode 100644 index 19c24ab5..00000000 --- a/assets/stylesheets/pages/_chai.scss +++ /dev/null @@ -1,5 +0,0 @@ -._chai { - @extend %simple; - - li.tag span { margin-right: 5px; } -} diff --git a/assets/stylesheets/pages/_simple.scss b/assets/stylesheets/pages/_simple.scss index a3e5a0bf..137d4920 100644 --- a/assets/stylesheets/pages/_simple.scss +++ b/assets/stylesheets/pages/_simple.scss @@ -17,6 +17,7 @@ } ._apache_pig, +._chai, ._cordova, ._gnu, ._grunt, diff --git a/lib/docs/filters/chai/clean_html.rb b/lib/docs/filters/chai/clean_html.rb index 9a444abd..6892c664 100644 --- a/lib/docs/filters/chai/clean_html.rb +++ b/lib/docs/filters/chai/clean_html.rb @@ -2,7 +2,7 @@ module Docs class Chai class CleanHtmlFilter < Filter def call - @doc = at_css('.documentation .rendered') + @doc = at_css('.documentation .rendered') if at_css('.documentation .rendered') if root_page? at_css('h1').content = 'Chai Assertion Library' @@ -12,9 +12,9 @@ module Docs node.before(node.children).remove end - # Remove code highlighting css('pre').each do |node| node.content = node.content + node['data-language'] = 'javascript' end doc diff --git a/lib/docs/filters/chai/entries.rb b/lib/docs/filters/chai/entries.rb index 8875ed3e..726dabf6 100644 --- a/lib/docs/filters/chai/entries.rb +++ b/lib/docs/filters/chai/entries.rb @@ -6,12 +6,12 @@ module Docs end def get_type - subpath.start_with?('/guide') ? 'Guides' : nil + subpath.start_with?('/guide') ? 'Guides' : name end def additional_entries css('.antiscroll-inner a').each_with_object [] do |node, entries| - id = node['href'].remove('#') + '-section' + id = node['href'].remove('#') node.content.strip.split(' / ').uniq { |name| name.downcase }.each do |name| entries << [name, id, self.name] end