Unified · Split
Binary file not shown.
Binary file not shown.
| @@ -1,7 +1,7 @@ | |||
| 1 | [ | 1 | [ |
| 2 | [ | 2 | [ |
| 3 | "2015-11-22", | 3 | "2015-11-22", |
| 4 | "New documentations: <a href=\"/dojo/\">Dojo</a> and <a href=\"/flow/\">Flow</a>" | 4 | "New documentations: <a href=\"/dojo/\">Dojo</a>, <a href=\"/relay/\">Relay</a> and <a href=\"/flow/\">Flow</a>" |
| 5 | ], [ | 5 | ], [ |
| 6 | "2015-11-08", | 6 | "2015-11-08", |
| 7 | "New documentations: <a href=\"/elixir/\">Elixir</a> and <a href=\"/vagrant/\">Vagrant</a>" | 7 | "New documentations: <a href=\"/elixir/\">Elixir</a> and <a href=\"/vagrant/\">Vagrant</a>" |
| @@ -325,7 +325,7 @@ credits = [ · 324 unmodified lines | |||
| 325 | 'MIT', | 325 | 'MIT', |
| 326 | 'https://raw.githubusercontent.com/kriskowal/q/v1/LICENSE' | 326 | 'https://raw.githubusercontent.com/kriskowal/q/v1/LICENSE' |
| 327 | ], [ | 327 | ], [ |
| 328 | 'React, React Native, Flow', | 328 | 'React, React Native, Flow, Relay', |
| 329 | '2013-2015 Facebook Inc.', | 329 | '2013-2015 Facebook Inc.', |
| 330 | 'CC BY', | 330 | 'CC BY', |
| 331 | 'https://raw.githubusercontent.com/facebook/react/master/LICENSE-docs' | 331 | 'https://raw.githubusercontent.com/facebook/react/master/LICENSE-docs' |
| @@ -120,3 +120,4 @@ · 119 unmodified lines | |||
| 120 | ._icon-vagrant:before { background-position: -5rem -9rem; } | 120 | ._icon-vagrant:before { background-position: -5rem -9rem; } |
| 121 | ._icon-dojo:before { background-position: -6rem -9rem; } | 121 | ._icon-dojo:before { background-position: -6rem -9rem; } |
| 122 | ._icon-flow:before { background-position: -7rem -9rem; } | 122 | ._icon-flow:before { background-position: -7rem -9rem; } |
| 123 | ._icon-relay:before { background-position: -8rem -9rem; } | ||
| @@ -3,7 +3,7 @@ · 2 unmodified lines | |||
| 3 | > h3 { @extend %block-label, %label-blue; } | 3 | > h3 { @extend %block-label, %label-blue; } |
| 4 | > h4 { @extend %block-label; } | 4 | > h4 { @extend %block-label; } |
| 5 | 5 | ||
| 6 | p code { @extend %label; } | 6 | p code, li code { @extend %label; } |
| 7 | blockquote { @extend %note; } | 7 | blockquote { @extend %note; } |
| 8 | 8 | ||
| 9 | span.platform { float: right; } | 9 | span.platform { float: right; } |
| @@ -41,6 +41,14 @@ module Docs · 40 unmodified lines | |||
| 41 | node.before(node.children).remove | 41 | node.before(node.children).remove |
| 42 | end | 42 | end |
| 43 | 43 | ||
| 44 | css('a pre').each do |node| | ||
| 45 | node.name = 'code' | ||
| 46 | end | ||
| 47 | |||
| 48 | css('a[target]').each do |node| | ||
| 49 | node.remove_attribute('target') | ||
| 50 | end | ||
| 51 | |||
| 44 | doc | 52 | doc |
| 45 | end | 53 | end |
| 46 | end | 54 | end |
| @@ -37,7 +37,9 @@ module Docs · 36 unmodified lines | |||
| 37 | [name, id, type] | 37 | [name, id, type] |
| 38 | end | 38 | end |
| 39 | else | 39 | else |
| 40 | css('.props > .prop > .propTitle').each_with_object([]) do |node, entries| | 40 | entries = [] |
| 41 | |||
| 42 | css('.props > .prop > .propTitle').each do |node| # react-native | ||
| 41 | name = node.children.find(&:text?).try(:content) | 43 | name = node.children.find(&:text?).try(:content) |
| 42 | next if name.blank? | 44 | next if name.blank? |
| 43 | sep = node.content.include?('static') ? '.' : '#' | 45 | sep = node.content.include?('static') ? '.' : '#' |
| @@ -46,6 +48,19 @@ module Docs · 2 unmodified lines | |||
| 46 | id = node.at_css('.anchor')['name'] | 48 | id = node.at_css('.anchor')['name'] |
| 47 | entries << [name, id] | 49 | entries << [name, id] |
| 48 | end | 50 | end |
| 51 | |||
| 52 | css('.apiIndex a pre').each do |node| # relay | ||
| 53 | next unless node.parent['href'].start_with?('#') | ||
| 54 | id = node.parent['href'].remove('#') | ||
| 55 | name = node.content.strip | ||
| 56 | sep = name.start_with?('static') ? '.' : '#' | ||
| 57 | name.remove! %r{(abstract|static) } | ||
| 58 | name.sub! %r{\(.*\)}, '()' | ||
| 59 | name.prepend(self.name + sep) | ||
| 60 | entries << [name, id] | ||
| 61 | end | ||
| 62 | |||
| 63 | entries | ||
| 49 | end | 64 | end |
| 50 | end | 65 | end |
| 51 | end | 66 | end |
| @@ -0,0 +1,21 @@ | |||
| 1 | module Docs | ||
| 2 | class Relay < React | ||
| 3 | self.type = 'react' | ||
| 4 | self.version = '0.5' | ||
| 5 | self.base_url = 'https://facebook.github.io/relay/docs/' | ||
| 6 | self.root_path = 'getting-started.html' | ||
| 7 | self.links = { | ||
| 8 | home: 'https://facebook.github.io/relay/', | ||
| 9 | code: 'https://github.com/facebook/relay' | ||
| 10 | } | ||
| 11 | |||
| 12 | options[:root_title] = 'Relay Documentation' | ||
| 13 | options[:only_patterns] = nil | ||
| 14 | options[:skip] = %w(videos.html graphql-further-reading.html) | ||
| 15 | |||
| 16 | options[:attribution] = <<-HTML | ||
| 17 | © 2013–2015 Facebook Inc.<br> | ||
| 18 | Licensed under the BSD License. | ||
| 19 | HTML | ||
| 20 | end | ||
| 21 | end | ||
Binary file not shown.
Binary file not shown.