Refactor annotations handling, update to 0.9. (#1349)
This refactoring of annotations handling drops adding @s from templates in some cases, unifies code for pulling data out of analyzer, and eliminates hard to maintain and bug-causing returns in the middle of complex functions. It fixes multiple issues, including #1081, #1268, #1162 and more.
diff --git a/CHANGELOG.md b/CHANGELOG.md
index 97cce79..2bd3129 100644
--- a/CHANGELOG.md
+++ b/CHANGELOG.md
@@ -1,3 +1,7 @@
+## 0.9.13
+
+* fix multiple issues in annotation/feature list handling (#1268, #1162, #1081)
+
## 0.9.12
* add print styles
diff --git a/lib/dartdoc.dart b/lib/dartdoc.dart
index af8c6dd..3509384 100644
--- a/lib/dartdoc.dart
+++ b/lib/dartdoc.dart
@@ -40,7 +40,7 @@
const String name = 'dartdoc';
// Update when pubspec version changes.
-const String version = '0.9.12';
+const String version = '0.9.13';
final String defaultOutDir = path.join('doc', 'api');
diff --git a/lib/resources/styles.css b/lib/resources/styles.css
index 57d3255..fd65cf0 100644
--- a/lib/resources/styles.css
+++ b/lib/resources/styles.css
@@ -456,10 +456,6 @@
display: inline;
}
-.annotation-list li:before {
- content: "@";
-}
-
.comma-separated {
list-style: none;
padding: 0;
diff --git a/lib/src/model.dart b/lib/src/model.dart
index e6ee522..34c03ec 100644
--- a/lib/src/model.dart
+++ b/lib/src/model.dart
@@ -9,7 +9,8 @@
import 'dart:io';
import 'package:analyzer/dart/ast/ast.dart'
- show AnnotatedNode, Annotation, Declaration;
+ show AnnotatedNode, Declaration, FormalParameter, FieldDeclaration,
+ VariableDeclaration, VariableDeclarationList;
import 'package:analyzer/dart/element/element.dart';
import 'package:analyzer/dart/element/type.dart';
import 'package:analyzer/src/generated/resolver.dart'
@@ -914,8 +915,22 @@
bool get writeOnly => hasSetter && !hasGetter;
@override
+ List<String> get annotations {
+ List<String> all_annotations = new List<String>();
+ all_annotations.addAll(super.annotations);
+
+ if (element is PropertyInducingElement) {
+ var pie = element as PropertyInducingElement;
+ all_annotations.addAll(annotationsFromMetadata(pie.getter?.metadata));
+ all_annotations.addAll(annotationsFromMetadata(pie.setter?.metadata));
+ }
+ return all_annotations.toList(growable: false);
+ }
+
+ @override
Set<String> get features {
Set<String> all_features = super.features;
+ all_features.addAll(annotations);
/// final/const implies read-only, so don't display both strings.
if (readOnly && !isFinal && !isConst) all_features.add('read-only');
if (writeOnly) all_features.add('write-only');
@@ -1475,43 +1490,56 @@
}
List<String> get annotations {
- // Check https://code.google.com/p/dart/issues/detail?id=23181
- // If that is fixed, this code might get a lot easier
- if (element.computeNode() != null &&
- element.computeNode() is AnnotatedNode) {
- return (element.computeNode() as AnnotatedNode)
- .metadata
- .map((Annotation a) {
- var annotationString = a.toSource().substring(1); // remove the @
- var e = a.element;
- if (e != null && (e is ConstructorElement)) {
- var me = new ModelElement.from(
- e.enclosingElement, package._getLibraryFor(e.enclosingElement));
- if (me.href != null) {
- return annotationString.replaceAll(me.name, me.linkedName);
- }
- }
- return annotationString;
- }).toList(growable: false);
- } else {
- return element.metadata.map((ElementAnnotation a) {
- // TODO link to the element's href
- return a.element.name;
- }).toList(growable: false);
+ List<dynamic> metadata;
+ if (element.computeNode() is AnnotatedNode) {
+ AnnotatedNode node = element.computeNode() as AnnotatedNode;
+
+ // Declarations are contained inside FieldDeclarations, and that is where
+ // the actual annotations are.
+ while ((node is VariableDeclaration || node is VariableDeclarationList) &&
+ node is! FieldDeclaration) {
+ assert (null != (node as AnnotatedNode).parent);
+ node = node.parent;
+ }
+ metadata = node.metadata;
+ } else if (element.computeNode() is! FormalParameter) {
+ // TODO(jcollins-g): This is special cased to suppress annotations for
+ // parameters in constructor documentation. Do we
+ // want to do this?
+ metadata = element.metadata;
}
+ return annotationsFromMetadata(metadata);
}
- /// const and static are not needed here because const/static elements get
- /// their own sections in the doc.
+ /// Returns annotations from a given metadata set, with escaping.
+ /// md is a dynamic parameter since ElementAnnotation and Annotation have no
+ /// common class for calling toSource() and element.
+ List<String> annotationsFromMetadata(List<dynamic> md) {
+ if (md == null) md = new List<dynamic>();
+ return md.map((dynamic a) {
+ String annotation = (const HtmlEscape()).convert(a.toSource());
+ if (a.element is ConstructorElement) {
+ var me = new ModelElement.from(a.element.enclosingElement,
+ package._getLibraryFor(a.element.enclosingElement));
+ annotation = annotation.replaceFirst(me.name, me.linkedName);
+ }
+ return annotation;
+ }).toList(growable: false);
+ }
+
Set<String> get features {
Set<String> all_features = new Set<String>();
all_features.addAll(annotations);
- /// override as an annotation should be replaced with direct information
- /// from the analyzer if we decide to display it at this level.
- all_features.remove('override');
- /// Drop the plain "deprecated" annotation, that's indicated via
- /// strikethroughs. Custom @Deprecated() will still appear.
- all_features.remove('deprecated');
+
+ // override as an annotation should be replaced with direct information
+ // from the analyzer if we decide to display it at this level.
+ all_features.remove('@override');
+
+ // Drop the plain "deprecated" annotation, that's indicated via
+ // strikethroughs. Custom @Deprecated() will still appear.
+ all_features.remove('@deprecated');
+ // const and static are not needed here because const/static elements get
+ // their own sections in the doc.
if (isFinal) all_features.add('final');
return all_features;
}
@@ -1749,7 +1777,7 @@
buf.write('<span class="parameter" id="${param.htmlId}">');
if (showMetadata && param.hasAnnotations) {
param.annotations.forEach((String annotation) {
- buf.write('<span>@$annotation</span> ');
+ buf.write('<span>$annotation</span> ');
});
}
if (param.modelType.isFunctionType) {
@@ -2575,6 +2603,7 @@
@override
Set<String> get features {
Set<String> all_features = super.features;
+
/// final/const implies read-only, so don't display both strings.
if (readOnly && !isFinal && !isConst) all_features.add('read-only');
if (writeOnly) all_features.add('write-only');
diff --git a/pubspec.lock b/pubspec.lock
index 5869f9d..7324faa 100644
--- a/pubspec.lock
+++ b/pubspec.lock
@@ -6,7 +6,7 @@
name: analyzer
url: "https://pub.dartlang.org"
source: hosted
- version: "0.29.0"
+ version: "0.29.8"
ansicolor:
description:
name: ansicolor
@@ -43,6 +43,12 @@
url: "https://pub.dartlang.org"
source: hosted
version: "1.1.0"
+ cli_util:
+ description:
+ name: cli_util
+ url: "https://pub.dartlang.org"
+ source: hosted
+ version: "0.0.1+2"
collection:
description:
name: collection
@@ -301,6 +307,18 @@
url: "https://pub.dartlang.org"
source: hosted
version: "1.0.4"
+ when:
+ description:
+ name: when
+ url: "https://pub.dartlang.org"
+ source: hosted
+ version: "0.2.0"
+ which:
+ description:
+ name: which
+ url: "https://pub.dartlang.org"
+ source: hosted
+ version: "0.1.3"
yaml:
description:
name: yaml
diff --git a/pubspec.yaml b/pubspec.yaml
index 5c6cbd3..f26e286 100644
--- a/pubspec.yaml
+++ b/pubspec.yaml
@@ -7,7 +7,7 @@
environment:
sdk: '>=1.14.0 <2.0.0'
dependencies:
- analyzer: ^0.29.0
+ analyzer: ^0.29.8
args: ^0.13.0
collection: ^1.2.0
html: '>=0.12.1 <0.14.0'
diff --git a/test/model_test.dart b/test/model_test.dart
index a1634d9..b67f391 100644
--- a/test/model_test.dart
+++ b/test/model_test.dart
@@ -1645,24 +1645,24 @@
test('has one annotation',
() => expect(forAnnotation.annotations, hasLength(1)));
- test('has the right annotation', () {
+ test('has the right annotation and is escaped', () {
expect(
forAnnotation.annotations.first,
equals(
- '<a href="ex/ForAnnotation-class.html">ForAnnotation</a>(\'my value\')'));
+ '@<a href="ex/ForAnnotation-class.html">ForAnnotation</a>('my value')'));
});
test('methods has the right annotation', () {
var m = dog.instanceMethods.singleWhere((m) => m.name == 'getClassA');
expect(m.hasAnnotations, isTrue);
- expect(m.annotations.first, equals('deprecated'));
+ expect(m.annotations.first, equals('@deprecated'));
});
- test('method annotations have the right link', () {
+ test('method annotations have the right link and are escaped', () {
expect(
ctr.annotations[0],
equals(
- '<a href="ex/Deprecated-class.html">Deprecated</a>("Internal use")'));
+ '@<a href="ex/Deprecated-class.html">Deprecated</a>("Internal use")'));
});
});
diff --git a/testing/test_package_docs/ex/B-class.html b/testing/test_package_docs/ex/B-class.html
index 6594120..3bfed6d 100644
--- a/testing/test_package_docs/ex/B-class.html
+++ b/testing/test_package_docs/ex/B-class.html
@@ -198,7 +198,7 @@
</dt>
<dd>
<p></p>
- <div class="features">read-only</div>
+ <div class="features">@override, read-only</div>
</dd>
<dt id="list" class="property">
<span class="name"><a href="ex/B/list.html">list</a></span>
@@ -214,7 +214,7 @@
</dt>
<dd>
<p></p>
- <div class="features">read-only</div>
+ <div class="features">@override, read-only</div>
</dd>
<dt id="fieldWithTypedef" class="property inherited">
<span class="name"><a href="ex/Apple/fieldWithTypedef.html">fieldWithTypedef</a></span>
diff --git a/testing/test_package_docs/ex/B/abstractMethod.html b/testing/test_package_docs/ex/B/abstractMethod.html
index a069013..ea29395 100644
--- a/testing/test_package_docs/ex/B/abstractMethod.html
+++ b/testing/test_package_docs/ex/B/abstractMethod.html
@@ -116,7 +116,7 @@
<section class="multi-line-signature">
<div>
<ol class="annotation-list">
- <li>override</li>
+ <li>@override</li>
</ol>
</div>
<span class="returntype">void</span>
diff --git a/testing/test_package_docs/ex/B/doNothing.html b/testing/test_package_docs/ex/B/doNothing.html
index 2fd8943..1f502d8 100644
--- a/testing/test_package_docs/ex/B/doNothing.html
+++ b/testing/test_package_docs/ex/B/doNothing.html
@@ -116,7 +116,7 @@
<section class="multi-line-signature">
<div>
<ol class="annotation-list">
- <li>deprecated</li>
+ <li>@deprecated</li>
</ol>
</div>
<span class="returntype">Future</span>
diff --git a/testing/test_package_docs/ex/B/m1.html b/testing/test_package_docs/ex/B/m1.html
index 6657d1a..84c90d8 100644
--- a/testing/test_package_docs/ex/B/m1.html
+++ b/testing/test_package_docs/ex/B/m1.html
@@ -116,7 +116,7 @@
<section class="multi-line-signature">
<div>
<ol class="annotation-list">
- <li>override</li>
+ <li>@override</li>
</ol>
</div>
<span class="returntype">void</span>
diff --git a/testing/test_package_docs/ex/ConstantCat-class.html b/testing/test_package_docs/ex/ConstantCat-class.html
index b69af3a..b7ef423 100644
--- a/testing/test_package_docs/ex/ConstantCat-class.html
+++ b/testing/test_package_docs/ex/ConstantCat-class.html
@@ -181,7 +181,7 @@
</dt>
<dd>
<p></p>
- <div class="features">read-only</div>
+ <div class="features">@override, read-only</div>
</dd>
<dt id="name" class="property">
<span class="name"><a href="ex/ConstantCat/name.html">name</a></span>
diff --git a/testing/test_package_docs/ex/ConstantCat/abstractMethod.html b/testing/test_package_docs/ex/ConstantCat/abstractMethod.html
index e06d248..b8c1da7 100644
--- a/testing/test_package_docs/ex/ConstantCat/abstractMethod.html
+++ b/testing/test_package_docs/ex/ConstantCat/abstractMethod.html
@@ -102,7 +102,7 @@
<section class="multi-line-signature">
<div>
<ol class="annotation-list">
- <li>override</li>
+ <li>@override</li>
</ol>
</div>
<span class="returntype">void</span>
diff --git a/testing/test_package_docs/ex/Dog-class.html b/testing/test_package_docs/ex/Dog-class.html
index 48f6a20..1c27c7c 100644
--- a/testing/test_package_docs/ex/Dog-class.html
+++ b/testing/test_package_docs/ex/Dog-class.html
@@ -224,7 +224,7 @@
</dt>
<dd>
<p></p>
- <div class="features"><a href="ex/Deprecated-class.html">Deprecated</a>("Internal use")</div>
+ <div class="features">@<a href="ex/Deprecated-class.html">Deprecated</a>("Internal use")</div>
</dd>
</dl>
</section>
@@ -274,7 +274,7 @@
</dt>
<dd>
<p></p>
- <div class="features">final</div>
+ <div class="features">@protected, final</div>
</dd>
<dt id="deprecatedField" class="property">
<span class="name"><a class="deprecated" href="ex/Dog/deprecatedField.html">deprecatedField</a></span>
@@ -282,7 +282,7 @@
</dt>
<dd>
<p></p>
- <div class="features">read / write</div>
+ <div class="features">@deprecated, read / write</div>
</dd>
<dt id="deprecatedGetter" class="property">
<span class="name"><a class="deprecated" href="ex/Dog/deprecatedGetter.html">deprecatedGetter</a></span>
@@ -290,7 +290,7 @@
</dt>
<dd>
<p></p>
- <div class="features">read-only</div>
+ <div class="features">@deprecated, read-only</div>
</dd>
<dt id="deprecatedSetter" class="property">
<span class="name"><a class="deprecated" href="ex/Dog/deprecatedSetter.html">deprecatedSetter</a></span>
@@ -298,7 +298,7 @@
</dt>
<dd>
<p></p>
- <div class="features">write-only</div>
+ <div class="features">@deprecated, write-only</div>
</dd>
<dt id="isImplemented" class="property">
<span class="name"><a href="ex/Dog/isImplemented.html">isImplemented</a></span>
@@ -306,7 +306,7 @@
</dt>
<dd>
<p></p>
- <div class="features">read-only</div>
+ <div class="features">@override, read-only</div>
</dd>
<dt id="name" class="property">
<span class="name"><a href="ex/Dog/name.html">name</a></span>
@@ -378,7 +378,7 @@
</dt>
<dd>
<p></p>
- <div class="features"><a href="ex/Deprecated-class.html">Deprecated</a>('before v27.3')</div>
+ <div class="features">@<a href="ex/Deprecated-class.html">Deprecated</a>('before v27.3')</div>
</dd>
<dt id="getClassA" class="callable">
<span class="name deprecated"><a class="deprecated" href="ex/Dog/getClassA.html">getClassA</a></span><span class="signature">(<wbr>)
diff --git a/testing/test_package_docs/ex/Dog/aProtectedFinalField.html b/testing/test_package_docs/ex/Dog/aProtectedFinalField.html
index 742aabe..3440312 100644
--- a/testing/test_package_docs/ex/Dog/aProtectedFinalField.html
+++ b/testing/test_package_docs/ex/Dog/aProtectedFinalField.html
@@ -124,7 +124,7 @@
<section class="multi-line-signature">
<span class="returntype">int</span>
- <span class="name ">aProtectedFinalField</span> <div class="features">final</div>
+ <span class="name ">aProtectedFinalField</span> <div class="features">@protected, final</div>
</section>
diff --git a/testing/test_package_docs/ex/Dog/abstractMethod.html b/testing/test_package_docs/ex/Dog/abstractMethod.html
index b68bb0c..ab51995 100644
--- a/testing/test_package_docs/ex/Dog/abstractMethod.html
+++ b/testing/test_package_docs/ex/Dog/abstractMethod.html
@@ -124,7 +124,7 @@
<section class="multi-line-signature">
<div>
<ol class="annotation-list">
- <li>override</li>
+ <li>@override</li>
</ol>
</div>
<span class="returntype">void</span>
diff --git a/testing/test_package_docs/ex/Dog/createDog.html b/testing/test_package_docs/ex/Dog/createDog.html
index cbf6b02..6a224e6 100644
--- a/testing/test_package_docs/ex/Dog/createDog.html
+++ b/testing/test_package_docs/ex/Dog/createDog.html
@@ -124,7 +124,7 @@
<section class="multi-line-signature">
<div>
<ol class="annotation-list">
- <li><a href="ex/Deprecated-class.html">Deprecated</a>("Internal use")</li>
+ <li>@<a href="ex/Deprecated-class.html">Deprecated</a>("Internal use")</li>
</ol>
</div>
<span class="returntype"><a href="ex/Dog-class.html">Dog</a></span>
diff --git a/testing/test_package_docs/ex/Dog/deprecatedField.html b/testing/test_package_docs/ex/Dog/deprecatedField.html
index 2242471..61d7048 100644
--- a/testing/test_package_docs/ex/Dog/deprecatedField.html
+++ b/testing/test_package_docs/ex/Dog/deprecatedField.html
@@ -124,7 +124,7 @@
<section class="multi-line-signature">
<span class="returntype">int</span>
- <span class="name deprecated">deprecatedField</span> <div class="features">read / write</div>
+ <span class="name deprecated">deprecatedField</span> <div class="features">@deprecated, read / write</div>
</section>
diff --git a/testing/test_package_docs/ex/Dog/getAnotherClassD.html b/testing/test_package_docs/ex/Dog/getAnotherClassD.html
index f79a88d..624fa04 100644
--- a/testing/test_package_docs/ex/Dog/getAnotherClassD.html
+++ b/testing/test_package_docs/ex/Dog/getAnotherClassD.html
@@ -124,7 +124,7 @@
<section class="multi-line-signature">
<div>
<ol class="annotation-list">
- <li><a href="ex/Deprecated-class.html">Deprecated</a>('before v27.3')</li>
+ <li>@<a href="ex/Deprecated-class.html">Deprecated</a>('before v27.3')</li>
</ol>
</div>
<span class="returntype">List<<a href="ex/Dog-class.html">Dog</a>></span>
diff --git a/testing/test_package_docs/ex/Dog/getClassA.html b/testing/test_package_docs/ex/Dog/getClassA.html
index 7707d35..b8e12f1 100644
--- a/testing/test_package_docs/ex/Dog/getClassA.html
+++ b/testing/test_package_docs/ex/Dog/getClassA.html
@@ -124,7 +124,7 @@
<section class="multi-line-signature">
<div>
<ol class="annotation-list">
- <li>deprecated</li>
+ <li>@deprecated</li>
</ol>
</div>
<span class="returntype">List<<a href="ex/Apple-class.html">Apple</a>></span>
diff --git a/testing/test_package_docs/ex/Dog/operator_equals.html b/testing/test_package_docs/ex/Dog/operator_equals.html
index add426e..521a97c 100644
--- a/testing/test_package_docs/ex/Dog/operator_equals.html
+++ b/testing/test_package_docs/ex/Dog/operator_equals.html
@@ -124,7 +124,7 @@
<section class="multi-line-signature">
<div>
<ol class="annotation-list">
- <li>override</li>
+ <li>@override</li>
</ol>
</div>
<span class="returntype">dynamic</span>
diff --git a/testing/test_package_docs/ex/F-class.html b/testing/test_package_docs/ex/F-class.html
index 7b9b71b..c4dd133 100644
--- a/testing/test_package_docs/ex/F-class.html
+++ b/testing/test_package_docs/ex/F-class.html
@@ -196,7 +196,7 @@
</dt>
<dd class="inherited">
<p></p>
- <div class="features">final, inherited</div>
+ <div class="features">@protected, final, inherited</div>
</dd>
<dt id="deprecatedField" class="property inherited">
<span class="name"><a class="deprecated" href="ex/Dog/deprecatedField.html">deprecatedField</a></span>
@@ -204,7 +204,7 @@
</dt>
<dd class="inherited">
<p></p>
- <div class="features">read / write, inherited</div>
+ <div class="features">@deprecated, read / write, inherited</div>
</dd>
<dt id="deprecatedGetter" class="property inherited">
<span class="name"><a class="deprecated" href="ex/Dog/deprecatedGetter.html">deprecatedGetter</a></span>
@@ -212,7 +212,7 @@
</dt>
<dd class="inherited">
<p></p>
- <div class="features">read-only, inherited</div>
+ <div class="features">@deprecated, read-only, inherited</div>
</dd>
<dt id="deprecatedSetter" class="property inherited">
<span class="name"><a class="deprecated" href="ex/Dog/deprecatedSetter.html">deprecatedSetter</a></span>
@@ -220,7 +220,7 @@
</dt>
<dd class="inherited">
<p></p>
- <div class="features">write-only, inherited</div>
+ <div class="features">@deprecated, write-only, inherited</div>
</dd>
<dt id="hashCode" class="property inherited">
<span class="name"><a href="ex/F/hashCode.html">hashCode</a></span>
@@ -236,7 +236,7 @@
</dt>
<dd class="inherited">
<p></p>
- <div class="features">read-only, inherited</div>
+ <div class="features">@override, read-only, inherited</div>
</dd>
<dt id="name" class="property inherited">
<span class="name"><a href="ex/Dog/name.html">name</a></span>
@@ -309,7 +309,7 @@
</dt>
<dd class="inherited">
<p></p>
- <div class="features"><a href="ex/Deprecated-class.html">Deprecated</a>('before v27.3'), inherited</div>
+ <div class="features">@<a href="ex/Deprecated-class.html">Deprecated</a>('before v27.3'), inherited</div>
</dd>
<dt id="getClassA" class="callable inherited">
<span class="name deprecated"><a class="deprecated" href="ex/Dog/getClassA.html">getClassA</a></span><span class="signature">(<wbr>)
diff --git a/testing/test_package_docs/ex/HasAnnotation-class.html b/testing/test_package_docs/ex/HasAnnotation-class.html
index 6f4748b..cb674f0 100644
--- a/testing/test_package_docs/ex/HasAnnotation-class.html
+++ b/testing/test_package_docs/ex/HasAnnotation-class.html
@@ -147,7 +147,7 @@
<dt>Annotations</dt>
<dd><ul class="annotation-list clazz-relationships">
- <li><a href="ex/ForAnnotation-class.html">ForAnnotation</a>('my value')</li>
+ <li>@<a href="ex/ForAnnotation-class.html">ForAnnotation</a>('my value')</li>
</ul></dd>
</dl>
</section>
diff --git a/testing/test_package_docs/ex/Klass-class.html b/testing/test_package_docs/ex/Klass-class.html
index 1d370f7..0aff23f 100644
--- a/testing/test_package_docs/ex/Klass-class.html
+++ b/testing/test_package_docs/ex/Klass-class.html
@@ -216,7 +216,7 @@
</dt>
<dd>
<p>A method with a custom annotation</p>
- <div class="features"><a href="ex/aThingToDo-class.html">aThingToDo</a>('from', 'thing')</div>
+ <div class="features">@<a href="ex/aThingToDo-class.html">aThingToDo</a>('from', 'thing')</div>
</dd>
<dt id="imAFactoryNoReally" class="callable">
<span class="name"><a href="ex/Klass/imAFactoryNoReally.html">imAFactoryNoReally</a></span><span class="signature">(<wbr>)
@@ -225,7 +225,7 @@
</dt>
<dd>
<p>Not really a factory, but...</p>
- <div class="features">factory</div>
+ <div class="features">@factory</div>
</dd>
<dt id="imProtected" class="callable">
<span class="name"><a href="ex/Klass/imProtected.html">imProtected</a></span><span class="signature">(<wbr>)
@@ -234,7 +234,7 @@
</dt>
<dd>
<p>A protected method</p>
- <div class="features">protected</div>
+ <div class="features">@protected</div>
</dd>
<dt id="method" class="callable">
<span class="name"><a href="ex/Klass/method.html">method</a></span><span class="signature">(<wbr>)
diff --git a/testing/test_package_docs/ex/Klass/anotherMethod.html b/testing/test_package_docs/ex/Klass/anotherMethod.html
index 0cda0e2..d89d4fe 100644
--- a/testing/test_package_docs/ex/Klass/anotherMethod.html
+++ b/testing/test_package_docs/ex/Klass/anotherMethod.html
@@ -104,7 +104,7 @@
<section class="multi-line-signature">
<div>
<ol class="annotation-list">
- <li><a href="ex/aThingToDo-class.html">aThingToDo</a>('from', 'thing')</li>
+ <li>@<a href="ex/aThingToDo-class.html">aThingToDo</a>('from', 'thing')</li>
</ol>
</div>
<span class="returntype">dynamic</span>
diff --git a/testing/test_package_docs/ex/Klass/imAFactoryNoReally.html b/testing/test_package_docs/ex/Klass/imAFactoryNoReally.html
index 91595a8..e38d882 100644
--- a/testing/test_package_docs/ex/Klass/imAFactoryNoReally.html
+++ b/testing/test_package_docs/ex/Klass/imAFactoryNoReally.html
@@ -104,7 +104,7 @@
<section class="multi-line-signature">
<div>
<ol class="annotation-list">
- <li>factory</li>
+ <li>@factory</li>
</ol>
</div>
<span class="returntype">dynamic</span>
diff --git a/testing/test_package_docs/ex/Klass/imProtected.html b/testing/test_package_docs/ex/Klass/imProtected.html
index 321fb6b..90cc900 100644
--- a/testing/test_package_docs/ex/Klass/imProtected.html
+++ b/testing/test_package_docs/ex/Klass/imProtected.html
@@ -104,7 +104,7 @@
<section class="multi-line-signature">
<div>
<ol class="annotation-list">
- <li>protected</li>
+ <li>@protected</li>
</ol>
</div>
<span class="returntype">dynamic</span>
diff --git a/testing/test_package_docs/ex/Klass/toString.html b/testing/test_package_docs/ex/Klass/toString.html
index fd3327f..bd00daa 100644
--- a/testing/test_package_docs/ex/Klass/toString.html
+++ b/testing/test_package_docs/ex/Klass/toString.html
@@ -104,7 +104,7 @@
<section class="multi-line-signature">
<div>
<ol class="annotation-list">
- <li>override</li>
+ <li>@override</li>
</ol>
</div>
<span class="returntype">dynamic</span>
diff --git a/testing/test_package_docs/ex/MyErrorImplements-class.html b/testing/test_package_docs/ex/MyErrorImplements-class.html
index d95d81f..a4cdb8d 100644
--- a/testing/test_package_docs/ex/MyErrorImplements-class.html
+++ b/testing/test_package_docs/ex/MyErrorImplements-class.html
@@ -180,7 +180,7 @@
</dt>
<dd>
<p></p>
- <div class="features">read-only</div>
+ <div class="features">@override, read-only</div>
</dd>
<dt id="hashCode" class="property inherited">
<span class="name"><a href="ex/MyErrorImplements/hashCode.html">hashCode</a></span>
diff --git a/testing/test_package_docs/ex/PublicClassImplementsPrivateInterface/test.html b/testing/test_package_docs/ex/PublicClassImplementsPrivateInterface/test.html
index 92c141b..68d3b37 100644
--- a/testing/test_package_docs/ex/PublicClassImplementsPrivateInterface/test.html
+++ b/testing/test_package_docs/ex/PublicClassImplementsPrivateInterface/test.html
@@ -100,7 +100,7 @@
<section class="multi-line-signature">
<div>
<ol class="annotation-list">
- <li>override</li>
+ <li>@override</li>
</ol>
</div>
<span class="returntype">void</span>
diff --git a/testing/test_package_docs/ex/ShapeType/toString.html b/testing/test_package_docs/ex/ShapeType/toString.html
index 0b44f38..90b3470 100644
--- a/testing/test_package_docs/ex/ShapeType/toString.html
+++ b/testing/test_package_docs/ex/ShapeType/toString.html
@@ -101,7 +101,7 @@
<section class="multi-line-signature">
<div>
<ol class="annotation-list">
- <li>override</li>
+ <li>@override</li>
</ol>
</div>
<span class="returntype">String</span>
diff --git a/testing/test_package_docs/fake/Doh-class.html b/testing/test_package_docs/fake/Doh-class.html
index 8f873ca..73856bc 100644
--- a/testing/test_package_docs/fake/Doh-class.html
+++ b/testing/test_package_docs/fake/Doh-class.html
@@ -169,7 +169,7 @@
<dt>Annotations</dt>
<dd><ul class="annotation-list clazz-relationships">
- <li>deprecated</li>
+ <li>@deprecated</li>
</ul></dd>
</dl>
</section>
diff --git a/testing/test_package_docs/fake/FakeProcesses.html b/testing/test_package_docs/fake/FakeProcesses.html
index 6fdb15f..d5e1f76 100644
--- a/testing/test_package_docs/fake/FakeProcesses.html
+++ b/testing/test_package_docs/fake/FakeProcesses.html
@@ -147,7 +147,7 @@
<section class="multi-line-signature">
<div>
<ol class="annotation-list">
- <li>deprecated</li>
+ <li>@deprecated</li>
</ol>
</div>
<span class="returntype">String</span>
diff --git a/testing/test_package_docs/fake/LongFirstLine-class.html b/testing/test_package_docs/fake/LongFirstLine-class.html
index a501d61..c912e01 100644
--- a/testing/test_package_docs/fake/LongFirstLine-class.html
+++ b/testing/test_package_docs/fake/LongFirstLine-class.html
@@ -185,7 +185,7 @@
<dt>Annotations</dt>
<dd><ul class="annotation-list clazz-relationships">
- <li><a href="fake/Annotation-class.html">Annotation</a>('value')</li>
+ <li>@<a href="fake/Annotation-class.html">Annotation</a>('value')</li>
</ul></dd>
</dl>
</section>
diff --git a/testing/test_package_docs/fake/LongFirstLine/noParams.html b/testing/test_package_docs/fake/LongFirstLine/noParams.html
index 88394a5..2e79ea1 100644
--- a/testing/test_package_docs/fake/LongFirstLine/noParams.html
+++ b/testing/test_package_docs/fake/LongFirstLine/noParams.html
@@ -123,7 +123,7 @@
<section class="multi-line-signature">
<div>
<ol class="annotation-list">
- <li>deprecated</li>
+ <li>@deprecated</li>
</ol>
</div>
<span class="returntype">void</span>
diff --git a/testing/test_package_docs/fake/OperatorReferenceClass/operator_equals.html b/testing/test_package_docs/fake/OperatorReferenceClass/operator_equals.html
index 134f915..f835889 100644
--- a/testing/test_package_docs/fake/OperatorReferenceClass/operator_equals.html
+++ b/testing/test_package_docs/fake/OperatorReferenceClass/operator_equals.html
@@ -99,7 +99,7 @@
<section class="multi-line-signature">
<div>
<ol class="annotation-list">
- <li>override</li>
+ <li>@override</li>
</ol>
</div>
<span class="returntype">bool</span>
diff --git a/testing/test_package_docs/fake/SuperAwesomeClass-class.html b/testing/test_package_docs/fake/SuperAwesomeClass-class.html
index cb5d635..42a92df 100644
--- a/testing/test_package_docs/fake/SuperAwesomeClass-class.html
+++ b/testing/test_package_docs/fake/SuperAwesomeClass-class.html
@@ -167,7 +167,7 @@
<dt>Annotations</dt>
<dd><ul class="annotation-list clazz-relationships">
- <li>deprecated</li>
+ <li>@deprecated</li>
</ul></dd>
</dl>
</section>
diff --git a/testing/test_package_docs/fake/fake-library.html b/testing/test_package_docs/fake/fake-library.html
index 4150d03..9f8bc5f 100644
--- a/testing/test_package_docs/fake/fake-library.html
+++ b/testing/test_package_docs/fake/fake-library.html
@@ -408,7 +408,7 @@
</dt>
<dd>
<p>A single optional positional param, no type annotation, no default value.</p>
- <div class="features">greatAnnotation</div>
+ <div class="features">@greatAnnotation</div>
</dd>
<dt id="paintImage1" class="callable">
<span class="name"><a href="fake/paintImage1.html">paintImage1</a></span><span class="signature">(<wbr>{<span class="parameter" id="paintImage1-param-canvas"><span class="type-annotation">String</span> <span class="parameter-name">canvas</span>, </span> <span class="parameter" id="paintImage1-param-rect"><span class="type-annotation">int</span> <span class="parameter-name">rect</span>, </span> <span class="parameter" id="paintImage1-param-image"><span class="type-annotation"><a href="fake/ExtraSpecialList-class.html">ExtraSpecialList</a></span> <span class="parameter-name">image</span>, </span> <span class="parameter" id="paintImage1-param-colorFilter"><span class="type-annotation"><a href="fake/BaseForDocComments-class.html">BaseForDocComments</a></span> <span class="parameter-name">colorFilter</span>, </span> <span class="parameter" id="paintImage1-param-repeat"><span class="type-annotation">String</span> <span class="parameter-name">repeat</span>: <span class="default-value">LongFirstLine.THING</span></span> })
diff --git a/testing/test_package_docs/fake/onlyPositionalWithNoDefaultNoType.html b/testing/test_package_docs/fake/onlyPositionalWithNoDefaultNoType.html
index 7f3ba65..7868a11 100644
--- a/testing/test_package_docs/fake/onlyPositionalWithNoDefaultNoType.html
+++ b/testing/test_package_docs/fake/onlyPositionalWithNoDefaultNoType.html
@@ -147,11 +147,11 @@
<section class="multi-line-signature">
<div>
<ol class="annotation-list">
- <li>greatAnnotation</li>
+ <li>@greatAnnotation</li>
</ol>
</div>
<span class="returntype">void</span>
- <span class="name ">onlyPositionalWithNoDefaultNoType</span>(<wbr>[<span class="parameter" id="onlyPositionalWithNoDefaultNoType-param-anything"><span>@greatestAnnotation</span> <span class="parameter-name">anything</span></span> ])
+ <span class="name ">onlyPositionalWithNoDefaultNoType</span>(<wbr>[<span class="parameter" id="onlyPositionalWithNoDefaultNoType-param-anything"><span class="parameter-name">anything</span></span> ])
</section>
<section class="desc markdown">
<p>A single optional positional param, no type annotation, no default value.</p>
diff --git a/testing/test_package_docs/fake/paintImage1.html b/testing/test_package_docs/fake/paintImage1.html
index 582e7cc..30fb43e 100644
--- a/testing/test_package_docs/fake/paintImage1.html
+++ b/testing/test_package_docs/fake/paintImage1.html
@@ -146,7 +146,7 @@
<section class="multi-line-signature">
<span class="returntype">void</span>
- <span class="name ">paintImage1</span>(<wbr>{<span class="parameter" id="paintImage1-param-canvas"><span>@required</span> <span class="type-annotation">String</span> <span class="parameter-name">canvas</span>, </span> <span class="parameter" id="paintImage1-param-rect"><span>@required</span> <span class="type-annotation">int</span> <span class="parameter-name">rect</span>, </span> <span class="parameter" id="paintImage1-param-image"><span>@required</span> <span class="type-annotation"><a href="fake/ExtraSpecialList-class.html">ExtraSpecialList</a></span> <span class="parameter-name">image</span>, </span> <span class="parameter" id="paintImage1-param-colorFilter"><span class="type-annotation"><a href="fake/BaseForDocComments-class.html">BaseForDocComments</a></span> <span class="parameter-name">colorFilter</span>, </span> <span class="parameter" id="paintImage1-param-repeat"><span class="type-annotation">String</span> <span class="parameter-name">repeat</span>: <span class="default-value">LongFirstLine.THING</span></span> })
+ <span class="name ">paintImage1</span>(<wbr>{<span class="parameter" id="paintImage1-param-canvas"><span class="type-annotation">String</span> <span class="parameter-name">canvas</span>, </span> <span class="parameter" id="paintImage1-param-rect"><span class="type-annotation">int</span> <span class="parameter-name">rect</span>, </span> <span class="parameter" id="paintImage1-param-image"><span class="type-annotation"><a href="fake/ExtraSpecialList-class.html">ExtraSpecialList</a></span> <span class="parameter-name">image</span>, </span> <span class="parameter" id="paintImage1-param-colorFilter"><span class="type-annotation"><a href="fake/BaseForDocComments-class.html">BaseForDocComments</a></span> <span class="parameter-name">colorFilter</span>, </span> <span class="parameter" id="paintImage1-param-repeat"><span class="type-annotation">String</span> <span class="parameter-name">repeat</span>: <span class="default-value">LongFirstLine.THING</span></span> })
</section>
<section class="desc markdown">
<p>Paints an image into the given rectangle in the canvas.</p>
diff --git a/testing/test_package_docs/fake/paintImage2.html b/testing/test_package_docs/fake/paintImage2.html
index 8ae249b..fb174cc 100644
--- a/testing/test_package_docs/fake/paintImage2.html
+++ b/testing/test_package_docs/fake/paintImage2.html
@@ -146,7 +146,7 @@
<section class="multi-line-signature">
<span class="returntype">void</span>
- <span class="name ">paintImage2</span>(<wbr><span class="parameter" id="paintImage2-param-fooParam"><span class="type-annotation">String</span> <span class="parameter-name">fooParam</span>, [</span> <span class="parameter" id="paintImage2-param-canvas"><span>@required</span> <span class="type-annotation">String</span> <span class="parameter-name">canvas</span>, </span> <span class="parameter" id="paintImage2-param-rect"><span>@required</span> <span class="type-annotation">int</span> <span class="parameter-name">rect</span>, </span> <span class="parameter" id="paintImage2-param-image"><span>@required</span> <span class="type-annotation"><a href="fake/ExtraSpecialList-class.html">ExtraSpecialList</a></span> <span class="parameter-name">image</span>, </span> <span class="parameter" id="paintImage2-param-colorFilter"><span class="type-annotation"><a href="fake/BaseForDocComments-class.html">BaseForDocComments</a></span> <span class="parameter-name">colorFilter</span>, </span> <span class="parameter" id="paintImage2-param-repeat"><span class="type-annotation">String</span> <span class="parameter-name">repeat</span> = <span class="default-value">LongFirstLine.THING</span></span> ])
+ <span class="name ">paintImage2</span>(<wbr><span class="parameter" id="paintImage2-param-fooParam"><span class="type-annotation">String</span> <span class="parameter-name">fooParam</span>, [</span> <span class="parameter" id="paintImage2-param-canvas"><span class="type-annotation">String</span> <span class="parameter-name">canvas</span>, </span> <span class="parameter" id="paintImage2-param-rect"><span class="type-annotation">int</span> <span class="parameter-name">rect</span>, </span> <span class="parameter" id="paintImage2-param-image"><span class="type-annotation"><a href="fake/ExtraSpecialList-class.html">ExtraSpecialList</a></span> <span class="parameter-name">image</span>, </span> <span class="parameter" id="paintImage2-param-colorFilter"><span class="type-annotation"><a href="fake/BaseForDocComments-class.html">BaseForDocComments</a></span> <span class="parameter-name">colorFilter</span>, </span> <span class="parameter" id="paintImage2-param-repeat"><span class="type-annotation">String</span> <span class="parameter-name">repeat</span> = <span class="default-value">LongFirstLine.THING</span></span> ])
</section>
<section class="desc markdown">
<p>Paints an image into the given rectangle in the canvas.</p>
diff --git a/testing/test_package_docs/fake/topLevelFunction.html b/testing/test_package_docs/fake/topLevelFunction.html
index 871c601..eff312d 100644
--- a/testing/test_package_docs/fake/topLevelFunction.html
+++ b/testing/test_package_docs/fake/topLevelFunction.html
@@ -147,7 +147,7 @@
<section class="multi-line-signature">
<div>
<ol class="annotation-list">
- <li>deprecated</li>
+ <li>@deprecated</li>
</ol>
</div>
<span class="returntype">String</span>
diff --git a/testing/test_package_docs/index.html b/testing/test_package_docs/index.html
index 0456f2d..9f0ad8d 100644
--- a/testing/test_package_docs/index.html
+++ b/testing/test_package_docs/index.html
@@ -4,7 +4,7 @@
<meta charset="utf-8">
<meta http-equiv="X-UA-Compatible" content="IE=edge">
<meta name="viewport" content="width=device-width, initial-scale=1">
- <meta name="generator" content="made with love by dartdoc 0.9.12">
+ <meta name="generator" content="made with love by dartdoc 0.9.13">
<meta name="description" content="test_package API docs, for the Dart programming language.">
<title>test_package - Dart API docs</title>
diff --git a/testing/test_package_docs/static-assets/styles.css b/testing/test_package_docs/static-assets/styles.css
index 57d3255..fd65cf0 100644
--- a/testing/test_package_docs/static-assets/styles.css
+++ b/testing/test_package_docs/static-assets/styles.css
@@ -456,10 +456,6 @@
display: inline;
}
-.annotation-list li:before {
- content: "@";
-}
-
.comma-separated {
list-style: none;
padding: 0;