Merge pull request #1181 from dart-lang/show_entire_first_line_text

show the entire text for the first line of dartdoc
diff --git a/lib/resources/styles.css b/lib/resources/styles.css
index ab649eb..8bc2416 100644
--- a/lib/resources/styles.css
+++ b/lib/resources/styles.css
@@ -255,7 +255,6 @@
 }
 
 dd p {
-  white-space: nowrap;
   overflow-x: hidden;
   text-overflow: ellipsis;
   margin-bottom: 0;
diff --git a/lib/src/html/templates.dart b/lib/src/html/templates.dart
index bd7ecaa..ca82c08 100644
--- a/lib/src/html/templates.dart
+++ b/lib/src/html/templates.dart
@@ -10,8 +10,6 @@
 typedef String TemplateRenderer(context,
     {bool assumeNullNonExistingProperty, bool errorOnMissingProperty});
 
-// TODO: if we can ever enumerate the contents of a package, we
-// won't need this.
 const _partials = const <String>[
   'callable',
   'callable_multiline',
@@ -26,7 +24,6 @@
   'sidebar_for_class',
   'source_code',
   'sidebar_for_library',
-  'has_more_docs',
   'accessor_getter',
   'accessor_setter'
 ];
diff --git a/lib/src/markdown_processor.dart b/lib/src/markdown_processor.dart
index 09cc53a..833a540 100644
--- a/lib/src/markdown_processor.dart
+++ b/lib/src/markdown_processor.dart
@@ -163,7 +163,6 @@
   final String raw;
   final String asHtml;
   final String asOneLiner;
-  final bool hasMoreThanOneLineDocs;
 
   factory Documentation(String markdown) {
     String tempHtml = _renderMarkdownToHtml(markdown);
@@ -175,8 +174,7 @@
     return new Documentation._internal(element.documentation, tempHtml);
   }
 
-  Documentation._(
-      this.raw, this.asHtml, this.hasMoreThanOneLineDocs, this.asOneLiner);
+  Documentation._(this.raw, this.asHtml, this.asOneLiner);
 
   factory Documentation._internal(String markdown, String rawHtml) {
     var asHtmlDocument = parse(rawHtml);
@@ -206,18 +204,14 @@
     }
     var asHtml = asHtmlDocument.body.innerHtml;
 
-    // Fixes issue with line ending differences between mac and windows, affecting tests
+    // Fixes issue with line ending differences between mac and windows.
     if (asHtml != null) asHtml = asHtml.trim();
 
-    var asOneLiner = '';
-    var moreThanOneLineDoc = asHtmlDocument.body.children.length > 1;
+    var asOneLiner = asHtmlDocument.body.children.isEmpty
+        ? ''
+        : asHtmlDocument.body.children.first.innerHtml;
 
-    if (asHtmlDocument.body.children.isNotEmpty) {
-      asOneLiner = asHtmlDocument.body.children.first.innerHtml;
-    }
-
-    return new Documentation._(
-        markdown, asHtml, moreThanOneLineDoc, asOneLiner);
+    return new Documentation._(markdown, asHtml, asOneLiner);
   }
 }
 
diff --git a/lib/src/model.dart b/lib/src/model.dart
index 8cc9d4a..f34802b 100644
--- a/lib/src/model.dart
+++ b/lib/src/model.dart
@@ -659,7 +659,6 @@
   String get documentation;
   String get documentationAsHtml;
   bool get hasDocumentation;
-  bool get hasMoreThanOneLineDocs;
   String get oneLineDoc;
 }
 
@@ -1364,9 +1363,6 @@
   bool get hasDocumentation =>
       documentation != null && documentation.isNotEmpty;
 
-  @override
-  bool get hasMoreThanOneLineDocs => _documentation.hasMoreThanOneLineDocs;
-
   bool get hasParameters => parameters.isNotEmpty;
 
   String get href;
@@ -1789,8 +1785,6 @@
   // plain text or markdown.
   bool get hasDocumentationFile => documentationFile != null;
 
-  bool get hasMoreThanOneLineDocs => true;
-
   // TODO: make this work
   String get href => 'index.html';
 
diff --git a/lib/templates/_callable.html b/lib/templates/_callable.html
index 8b8280f..ad9f1b8 100644
--- a/lib/templates/_callable.html
+++ b/lib/templates/_callable.html
@@ -4,7 +4,7 @@
   </span>
 </dt>
 <dd{{ #isInherited }} class="inherited"{{ /isInherited}}>
-  <p>{{{ oneLineDoc }}}{{>has_more_docs}}</p>
+  <p>{{{ oneLineDoc }}}</p>
   {{#isInherited}}
   <div class="features">inherited</div>
   {{/isInherited}}
diff --git a/lib/templates/_constant.html b/lib/templates/_constant.html
index 845cd66..1247359 100644
--- a/lib/templates/_constant.html
+++ b/lib/templates/_constant.html
@@ -3,7 +3,7 @@
   <span class="signature">&#8594; {{{ linkedReturnType }}}</span>
 </dt>
 <dd>
-  <p>{{{ oneLineDoc }}}{{>has_more_docs}}</p>
+  <p>{{{ oneLineDoc }}}</p>
   <div>
     <span class="signature"><code>{{{ constantValue }}}</code></span>
   </div>
diff --git a/lib/templates/_has_more_docs.html b/lib/templates/_has_more_docs.html
deleted file mode 100644
index 0678a72..0000000
--- a/lib/templates/_has_more_docs.html
+++ /dev/null
@@ -1,3 +0,0 @@
-{{#hasMoreThanOneLineDocs}}
-<a href="{{href}}">&hellip;</a>
-{{/hasMoreThanOneLineDocs}}
diff --git a/lib/templates/_property.html b/lib/templates/_property.html
index 3d3d9df..95ac054 100644
--- a/lib/templates/_property.html
+++ b/lib/templates/_property.html
@@ -3,6 +3,6 @@
   <span class="signature">&#8594; {{{ linkedReturnType }}}</span>
 </dt>
 <dd{{ #isInherited }} class="inherited"{{ /isInherited}}>
-  <p>{{{ oneLineDoc }}}{{>has_more_docs}}</p>
+  <p>{{{ oneLineDoc }}}</p>
   {{>readable_writable}}
 </dd>
diff --git a/lib/templates/class.html b/lib/templates/class.html
index c25ae95..f420e9d 100644
--- a/lib/templates/class.html
+++ b/lib/templates/class.html
@@ -114,7 +114,7 @@
           <span class="name">{{{linkedName}}}</span><span class="signature">({{{ linkedParams }}})</span>
         </dt>
         <dd>
-          <p>{{{ oneLineDoc }}}{{>has_more_docs}}</p>
+          <p>{{{ oneLineDoc }}}</p>
           {{#isConst}}
           <div class="constructor-modifier features">const</div>
           {{/isConst}}
diff --git a/lib/templates/library.html b/lib/templates/library.html
index 813c5f3..40bc9a3 100644
--- a/lib/templates/library.html
+++ b/lib/templates/library.html
@@ -91,7 +91,7 @@
           {{{linkedName}}}
         </dt>
         <dd>
-          <p>{{{ oneLineDoc }}}{{>has_more_docs}}</p>
+          <p>{{{ oneLineDoc }}}</p>
         </dd>
         {{/library.enums}}
       </dl>
@@ -108,7 +108,7 @@
           <span class="name {{#isDeprecated}}deprecated{{/isDeprecated}}">{{{linkedName}}}</span>
         </dt>
         <dd>
-          <p>{{{ oneLineDoc }}}{{>has_more_docs}}</p>
+          <p>{{{ oneLineDoc }}}</p>
         </dd>
         {{/library.classes}}
       </dl>
@@ -125,7 +125,7 @@
           <span class="name {{#isDeprecated}}deprecated{{/isDeprecated}}">{{{linkedName}}}</span>
         </dt>
         <dd>
-          <p>{{{ oneLineDoc }}}{{>has_more_docs}}</p>
+          <p>{{{ oneLineDoc }}}</p>
         </dd>
         {{/library.exceptions}}
       </dl>
diff --git a/test/model_test.dart b/test/model_test.dart
index 814917a..2007786 100644
--- a/test/model_test.dart
+++ b/test/model_test.dart
@@ -165,11 +165,6 @@
               'WOW FAKE PACKAGE IS <strong>BEST</strong> <a href="http://example.org">PACKAGE</a>'));
     });
 
-    test('has more than one line docs (or not)', () {
-      expect(fakeLibrary.hasMoreThanOneLineDocs, true);
-      expect(exLibrary.hasMoreThanOneLineDocs, false);
-    });
-
     test('has properties', () {
       expect(exLibrary.hasProperties, isTrue);
     });