From ece6ff80fd9d720d4635585a66b45e24982c7f2e Mon Sep 17 00:00:00 2001 From: Thibaut Date: Sun, 19 Jan 2014 16:38:03 -0500 Subject: [PATCH] Add Knockout.js documentation --- assets/images/icons.png | Bin 14161 -> 14979 bytes assets/images/icons@2x.png | Bin 37247 -> 39742 bytes .../templates/pages/about_tmpl.coffee | 5 +++ .../templates/pages/news_tmpl.coffee | 4 +- .../javascripts/views/pages/knockout.coffee | 8 ++++ assets/stylesheets/application.css.scss | 1 + assets/stylesheets/global/_icons.scss | 3 +- assets/stylesheets/pages/_knockout.scss | 6 +++ lib/docs/filters/knockout/clean_html.rb | 30 ++++++++++++++ lib/docs/filters/knockout/entries.rb | 38 ++++++++++++++++++ lib/docs/scrapers/knockout.rb | 32 +++++++++++++++ public/icons/docs/knockout/16.png | Bin 0 -> 902 bytes public/icons/docs/knockout/16@2x.png | Bin 0 -> 2378 bytes public/icons/docs/knockout/SOURCE | 1 + 14 files changed, 125 insertions(+), 3 deletions(-) create mode 100644 assets/javascripts/views/pages/knockout.coffee create mode 100644 assets/stylesheets/pages/_knockout.scss create mode 100644 lib/docs/filters/knockout/clean_html.rb create mode 100644 lib/docs/filters/knockout/entries.rb create mode 100644 lib/docs/scrapers/knockout.rb create mode 100644 public/icons/docs/knockout/16.png create mode 100644 public/icons/docs/knockout/16@2x.png create mode 100644 public/icons/docs/knockout/SOURCE diff --git a/assets/images/icons.png b/assets/images/icons.png index c58499ee9f34e8806fb4a0cdfdca7f6d090a6514..e6c3318bd5929c64eabbbd57803daed9118503aa 100644 GIT binary patch delta 5260 zcmV;76m#p*Zi97@7Y=|31^@s6oGbh0(QE9 zD4>9J6njZDf{NWJb`b?ZqzX!tB1NQwf+Au=ut!B=!Nh_E0|8Mi^l8uCXL2#9Au;Q_ zS>L)VK5IQ|=Dg>fe|~H4{q9rd94;80eRQZ>fa|U{P5-|F*cH;>8G9V=zwLmMH2nIr z_|ek6e~_#|rUfKZRTj5a&d2i&vrsk9oS&&I!HXh*(c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*#D(MLOqc0$uU|WW0JRZM$5Q-ULmk`9AGBi!l`0 dwvO result app.news = [ - [ 1390089600000, # January 19, 2013 - """ New D3.js documentation """, + [ 1390089600001, # January 19, 2013 + """ New D3.js and Knockout.js documentations """, ], [ 1390003200000, # January 18, 2013 """ DevDocs is now available as a Firefox web app (currently requires Aurora). """, diff --git a/assets/javascripts/views/pages/knockout.coffee b/assets/javascripts/views/pages/knockout.coffee new file mode 100644 index 00000000..cb23d779 --- /dev/null +++ b/assets/javascripts/views/pages/knockout.coffee @@ -0,0 +1,8 @@ +#= require views/pages/base + +class app.views.KnockoutPage extends app.views.BasePage + afterRender: -> + for el in @findAll('pre') + language = if el.innerHTML.indexOf('data-bind="') > 0 then 'markup' else 'javascript' + @highlightCode el, language + return diff --git a/assets/stylesheets/application.css.scss b/assets/stylesheets/application.css.scss index cba47101..de05a2e0 100644 --- a/assets/stylesheets/application.css.scss +++ b/assets/stylesheets/application.css.scss @@ -32,6 +32,7 @@ 'pages/d3', 'pages/ember', 'pages/jquery', + 'pages/knockout', 'pages/git', 'pages/less', 'pages/lodash', diff --git a/assets/stylesheets/global/_icons.scss b/assets/stylesheets/global/_icons.scss index 21bb45f9..a1f490f2 100644 --- a/assets/stylesheets/global/_icons.scss +++ b/assets/stylesheets/global/_icons.scss @@ -4,7 +4,7 @@ width: 1rem; height: 1rem; background-image: image-url('icons.png'); - background-size: 5rem 7rem; + background-size: 5rem 8rem; } @media (-webkit-min-device-pixel-ratio: 1.5), (min-resolution: 144dpi) { @@ -46,3 +46,4 @@ ._icon-redis:before { background-position: -2rem -6rem; } ._icon-postgresql:before { background-position: -3rem -6rem; } ._icon-d3:before { background-position: -4rem -6rem; } +._icon-knockout:before { background-position: 0 -7rem; } diff --git a/assets/stylesheets/pages/_knockout.scss b/assets/stylesheets/pages/_knockout.scss new file mode 100644 index 00000000..d6bd68ec --- /dev/null +++ b/assets/stylesheets/pages/_knockout.scss @@ -0,0 +1,6 @@ +._knockout { + > h2 { @extend %block-heading; } + > h3 { @extend %block-label, %label-blue; } + p > code { @extend %label; } + .liveExample { @extend %note; } +} diff --git a/lib/docs/filters/knockout/clean_html.rb b/lib/docs/filters/knockout/clean_html.rb new file mode 100644 index 00000000..17c1e603 --- /dev/null +++ b/lib/docs/filters/knockout/clean_html.rb @@ -0,0 +1,30 @@ +module Docs + class Knockout + class CleanHtmlFilter < Filter + def call + root_page? ? root : other + + css('pre > code').each do |node| + node.before(node.children).remove + end + + doc + end + + def root + @doc = at_css '.content' + at_css('h1').content = 'Knockout.js' + end + + def other + css('h1 ~ h1').each do |node| + node.name = 'h2' + end + + css('.liveExample').each do |node| + node.content = 'Live examples are not available on DevDocs, sorry.' + end + end + end + end +end diff --git a/lib/docs/filters/knockout/entries.rb b/lib/docs/filters/knockout/entries.rb new file mode 100644 index 00000000..08db5f59 --- /dev/null +++ b/lib/docs/filters/knockout/entries.rb @@ -0,0 +1,38 @@ +module Docs + class Knockout + class EntriesFilter < Docs::EntriesFilter + NAME_BY_SLUG = { + 'custom-bindings' => 'Custom bindings', + 'custom-bindings-controlling-descendant-bindings' => 'Descendant bindings', + 'custom-bindings-for-virtual-elements' => 'Virtual elements', + 'binding-preprocessing' => 'Binding preprocessing', + 'json-data' => 'JSON data', + 'extenders' => 'Extending observables', + 'unobtrusive-event-handling' => 'Event handling', + 'fn' => 'Custom functions' } + + def get_name + return NAME_BY_SLUG[slug] if NAME_BY_SLUG.has_key?(slug) + name = at_css('h1').content.strip + name.sub! 'The ', '' + name.sub! %r{"(.+?)"}, '\1' + name.gsub!(/ [A-Z]/) { |str| str.downcase! } + name + end + + def get_type + if name =~ /observable/i || slug =~ /extender/ + 'Observables' + elsif slug.include?('binding') && !name.end_with?('binding') + 'Binding' + elsif slug.include? 'binding' + 'Bindings' + elsif slug.include? 'plugin' + 'Plugins' + else + 'Miscellaneous' + end + end + end + end +end diff --git a/lib/docs/scrapers/knockout.rb b/lib/docs/scrapers/knockout.rb new file mode 100644 index 00000000..941927aa --- /dev/null +++ b/lib/docs/scrapers/knockout.rb @@ -0,0 +1,32 @@ +module Docs + class Knockout < UrlScraper + self.name = 'Knockout.js' + self.slug = 'knockout' + self.type = 'knockout' + self.version = '3.0.0' + self.base_url = 'http://knockoutjs.com/documentation/' + self.root_path = 'introduction.html' + + html_filters.push 'knockout/clean_html', 'knockout/entries' + + options[:follow_links] = ->(filter) { filter.root_page? } + options[:container] = ->(filter) { filter.root_page? ? '#wrapper' : '.content' } + + options[:only] = %w( + json-data.html + extenders.html + throttle-extender.html + unobtrusive-event-handling.html + fn.html) + + options[:only_patterns] = [ + /observable/i, + /binding/, + /plugin/] + + options[:attribution] = <<-HTML + © Steven Sanderson, the Knockout.js team, and other contributors
+ Licensed under the MIT License. + HTML + end +end diff --git a/public/icons/docs/knockout/16.png b/public/icons/docs/knockout/16.png new file mode 100644 index 0000000000000000000000000000000000000000..b872f2ddf3d9879d51ba07fcd7cd433697d9b48f GIT binary patch literal 902 zcmV;119|+3P)4XjEAm2I@Z6k&W-rjt)u z0+_0R;9y@yomng-U(S1;_nh;d^Zt+WmA#;J z_;4Y^_QMQ2?2HsS7!@v-6fq%8{!eicQ^g_cV5-Q@HHn?F+e?)ptA!z(l_9H@{_Jc9 zEEWcBHU@HY2^8crCdCED3k$d`v6n14jOW{!D9B?X&xX>U`98ge4$+&L$<59V7H4O9 zI6u#CfdC_+j&icOXvt+n;(qRE=l=B9jLCfIp?c4Od zmqCxj{3OZ$Zfvj`3=)tLhYqAOdhh^BdtxHrG&BJ4aAAR-vNDEiYFJxcW##Epx-&AE z@p*Y6zQByvi~r3Odf!fC@GUb+bG(V)Z`}geOs?9tjn=Fz{#jXJd2x}6`g&HM1zBHP z<647{rq_4Sz9)(9J-hfaX(vi!jDbJz+yS7^<-)0s+2|jtk#`-#wlI+=P z#Ft>Ad54L%ggDNawxfI!9?lOfEdZ59>#xFRBO8w}hyf1cU#aW1&sypVS9-@VJPQ&Rv8xQnrC6<|P>R^X!pN6yez|%TfbPmlPKxdT_rCv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NQKlb;@l0DV42l0I4M9%sovC9?g za!OMeNJ}tNTpbqNu*97(pG!(j8!ar5N4d0t)-tI|9SfVd+Q5%Y{>&LDm~DfbUw(oAwLBgkMm0}Eh0@1}=K;|s zDzzcj#Z*KEq^3N|9V1UK-A_m8mM)F7utQK w8ZFdB+o-{ZSZhVTa`nFRbPax98Zq|20fj-nmf1sVPXGV_07*qoM6N<$g0OOZxc~qF literal 0 HcmV?d00001 diff --git a/public/icons/docs/knockout/SOURCE b/public/icons/docs/knockout/SOURCE new file mode 100644 index 00000000..69980549 --- /dev/null +++ b/public/icons/docs/knockout/SOURCE @@ -0,0 +1 @@ +http://learn.knockoutjs.com/