From 2bca6acdaf12607e8c8c5f5bb5175401ec65ab8f Mon Sep 17 00:00:00 2001 From: Jonathan Kim Date: Tue, 4 Oct 2016 07:54:17 -0700 Subject: [PATCH] Maintain whitespace in propType documentation Summary: When looking at PropType information for certain props the formatting puts everything on one line which makes it quite hard to read. This PR ensures that the whitespace extracted from react-docgen is preserved. For example the documentation for [Transforms](http://facebook.github.io/react-native/releases/0.34/docs/transforms.html#transform) goes from: screenshot 2016-10-01 17 32 23 to: screenshot 2016-10-01 17 32 30 **Test plan:** Check PropType documentation is being rendered correctly on other components. **N.B.** more style tweaks could be made here to make things more readable (e.g. reducing line height, monospace font) but I'll refrain from making them here in case there are explicit designs for the docs. Closes https://github.com/facebook/react-native/pull/10197 Differential Revision: D3967759 Pulled By: hramos fbshipit-source-id: bf3d3b2032dc6e9f5f1acf3907ecb7f57a2c57be --- website/src/react-native/css/react-native.css | 1 + 1 file changed, 1 insertion(+) diff --git a/website/src/react-native/css/react-native.css b/website/src/react-native/css/react-native.css index 6688e217c98..afd0032edbd 100644 --- a/website/src/react-native/css/react-native.css +++ b/website/src/react-native/css/react-native.css @@ -1262,6 +1262,7 @@ div[data-twttr-id] iframe { .propType { font-weight: normal; font-size: 15px; + white-space: pre; } .compactProps .propType {