Unified · Split
| @@ -1,6 +1,9 @@ | ||
| 1 | 1 | #= require views/pages/base |
| 2 | 2 | |
| 3 | 3 | class app.views.GithubPage extends app.views.BasePage |
| 4 | + LANGUAGE_RGX = /highlight-source-(\w+)/ | |
| 5 | + | |
| 4 | 6 | prepare: -> |
| 5 | − @highlightCode @findAll('pre.highlight-source-lua'), 'lua' | |
| 7 | + for el in @findAll('pre.highlight') | |
| 8 | + @highlightCode(el, el.className.match(LANGUAGE_RGX)[1]) | |
| 6 | 9 | return |
| @@ -26,7 +26,6 @@ app.views.MomentPage = · 25 unmodified lines | ||
| 26 | 26 | app.views.MongoosePage = |
| 27 | 27 | app.views.NodePage = |
| 28 | 28 | app.views.PhaserPage = |
| 29 | −app.views.QPage = | |
| 30 | 29 | app.views.RamdaPage = |
| 31 | 30 | app.views.RethinkdbPage = |
| 32 | 31 | app.views.SinonPage = |
| @@ -45,6 +45,7 @@ · 44 unmodified lines | ||
| 45 | 45 | 'pages/erlang', |
| 46 | 46 | 'pages/express', |
| 47 | 47 | 'pages/git', |
| 48 | + 'pages/github', | |
| 48 | 49 | 'pages/go', |
| 49 | 50 | 'pages/haskell', |
| 50 | 51 | 'pages/jquery', |
| @@ -63,7 +64,6 @@ · 12 unmodified lines | ||
| 63 | 64 | 'pages/php', |
| 64 | 65 | 'pages/phpunit', |
| 65 | 66 | 'pages/postgres', |
| 66 | − 'pages/q', | |
| 67 | 67 | 'pages/ramda', |
| 68 | 68 | 'pages/rdoc', |
| 69 | 69 | 'pages/react', |
| @@ -45,6 +45,7 @@ · 44 unmodified lines | ||
| 45 | 45 | 'pages/erlang', |
| 46 | 46 | 'pages/express', |
| 47 | 47 | 'pages/git', |
| 48 | + 'pages/github', | |
| 48 | 49 | 'pages/go', |
| 49 | 50 | 'pages/haskell', |
| 50 | 51 | 'pages/jquery', |
| @@ -63,7 +64,6 @@ · 12 unmodified lines | ||
| 63 | 64 | 'pages/php', |
| 64 | 65 | 'pages/phpunit', |
| 65 | 66 | 'pages/postgres', |
| 66 | − 'pages/q', | |
| 67 | 67 | 'pages/ramda', |
| 68 | 68 | 'pages/rdoc', |
| 69 | 69 | 'pages/react', |
| @@ -17,7 +17,6 @@ · 16 unmodified lines | ||
| 17 | 17 | } |
| 18 | 18 | |
| 19 | 19 | ._cordova, |
| 20 | −._github, | |
| 21 | 20 | ._grunt, |
| 22 | 21 | ._less, |
| 23 | 22 | ._lodash, |
| @@ -0,0 +1,5 @@ | ||
| 1 | +._github { | |
| 2 | + @extend %simple; | |
| 3 | + | |
| 4 | + h4 { @extend %block-label; } | |
| 5 | +} | |
| @@ -1,5 +0,0 @@ | ||
| 1 | −._q { | |
| 2 | − > h2, > h3 { @extend %block-heading; } | |
| 3 | − > h4 { @extend %block-label, %label-blue; } | |
| 4 | − code { @extend %label; } | |
| 5 | −} | |
| @@ -1,18 +0,0 @@ | ||
| 1 | −module Docs | |
| 2 | − class Q | |
| 3 | − class CleanHtmlFilter < Filter | |
| 4 | − def call | |
| 5 | − css('.anchor').each do |node| | |
| 6 | − node.parent['id'] = node['href'].remove('#') | |
| 7 | − node.remove | |
| 8 | − end | |
| 9 | − | |
| 10 | − css('.highlight > pre').each do |node| | |
| 11 | − node.content = node.content.gsub(' ', ' ') | |
| 12 | − end | |
| 13 | − | |
| 14 | − doc | |
| 15 | − end | |
| 16 | − end | |
| 17 | − end | |
| 18 | −end | |
| @@ -1,7 +1,6 @@ | ||
| 1 | 1 | module Docs |
| 2 | − class Q < UrlScraper | |
| 2 | + class Q < Github | |
| 3 | 3 | self.name = 'Q' |
| 4 | − self.type = 'q' | |
| 5 | 4 | self.release = '1.4.1' |
| 6 | 5 | self.base_url = 'https://github.com/kriskowal/q/wiki/' |
| 7 | 6 | self.root_path = 'API-Reference' |
| @@ -10,7 +9,7 @@ module Docs · 2 unmodified lines | ||
| 10 | 9 | code: 'https://github.com/kriskowal/q' |
| 11 | 10 | } |
| 12 | 11 | |
| 13 | − html_filters.push 'q/clean_html', 'q/entries', 'title' | |
| 12 | + html_filters.push 'q/entries', 'title' | |
| 14 | 13 | |
| 15 | 14 | options[:container] = '.markdown-body' |
| 16 | 15 | options[:title] = 'Q' |