Skip to content
This repository was archived by the owner on Apr 12, 2024. It is now read-only.

Commit f0be543

Browse files
committed
doc(ngdoc): clean up doc generation and add missing documentation links
1 parent a3a37c2 commit f0be543

File tree

5 files changed

+58
-23
lines changed

5 files changed

+58
-23
lines changed

docs/src/ngdoc.js

Lines changed: 4 additions & 19 deletions
Original file line numberDiff line numberDiff line change
@@ -726,7 +726,7 @@ function scenarios(docs){
726726

727727
//////////////////////////////////////////////////////////
728728
function metadata(docs){
729-
var words = [];
729+
var pages = [];
730730
docs.forEach(function(doc){
731731
var path = (doc.name || '').split(/(\.|\:\s+)/);
732732
for ( var i = 1; i < path.length; i++) {
@@ -738,7 +738,7 @@ function metadata(docs){
738738
shortName = 'input [' + shortName + ']';
739739
}
740740

741-
words.push({
741+
pages.push({
742742
section: doc.section,
743743
id: doc.id,
744744
name: title(doc.name),
@@ -747,27 +747,12 @@ function metadata(docs){
747747
keywords:doc.keywords()
748748
});
749749
});
750-
words.sort(keywordSort);
751-
return words;
750+
pages.sort(keywordSort);
751+
return pages;
752752
}
753753

754754
var KEYWORD_PRIORITY = {
755755
'.index': 1,
756-
'.guide': 2,
757-
'.angular': 7,
758-
'.angular.Module': 7,
759-
'.angular.module': 8,
760-
'.angular.module.ng': 2,
761-
'.angular.module.AUTO': 1,
762-
'.angular.mock': 9,
763-
'.angular.module.ng.$filter': 7,
764-
'.angular.module.ng.$rootScope.Scope': 7,
765-
'.angular.module.ng': 7,
766-
'.angular.mock': 8,
767-
'.angular.directive': 6,
768-
'.angular.inputType': 6,
769-
'.angular.widget': 6,
770-
'.angular.module.ngMock': 8,
771756
'.overview': 1,
772757
'.bootstrap': 2,
773758
'.mvc': 3,

src/ng/compile.js

Lines changed: 51 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -135,7 +135,7 @@
135135
*
136136
*
137137
* For information on how the compiler works, see the
138-
* {@link guide/dev_guide.compiler Angular HTML Compiler} section of the Developer Guide.
138+
* {@link guide/compiler Angular HTML Compiler} section of the Developer Guide.
139139
*/
140140

141141

@@ -145,7 +145,20 @@
145145
* @function
146146
*
147147
* @description
148+
*/
149+
150+
/**
151+
* @ngdoc function
152+
* @name angular.module.ng.$compileProvider#directive
153+
* @methodOf angular.module.ng.$compileProvider
154+
* @function
155+
*
156+
* @description
157+
* Register a new directive with compiler
148158
*
159+
* @param {string} name name of the directive.
160+
* @param {function} directiveFactory An injectable directive factory function.
161+
* @returns {angular.module.ng.$compileProvider} Self for chaining.
149162
*/
150163
$CompileProvider.$inject = ['$provide'];
151164
function $CompileProvider($provide) {
@@ -1045,6 +1058,43 @@ function directiveNormalize(name) {
10451058
return camelCase(name.replace(PREFIX_REGEXP, ''));
10461059
}
10471060

1061+
/**
1062+
* @ngdoc object
1063+
* @name angular.module.ng.$compile.directive.Attributes
1064+
* @description
1065+
*
1066+
* A shared object between directive compile / linking functions which contains normalized DOM element
1067+
* attributes. The the values reflect current binding state `{{ }}`. The normalization is needed
1068+
* since all of these are treated as equivalent in Angular:
1069+
*
1070+
* <span ng:bind="a" ng-bind="a" data-ng-bind="a" x-ng-bind="a">
1071+
*/
1072+
1073+
/**
1074+
* @ngdoc property
1075+
* @name angular.module.ng.$compile.directive.Attributes#$attr
1076+
* @propertyOf angular.module.ng.$compile.directive.Attributes
1077+
* @returns {object} A map of DOM element attribute names to the normalized name. This is
1078+
* needed to do reverse lookup from normalized name back to actual name.
1079+
*/
1080+
1081+
1082+
/**
1083+
* @ngdoc function
1084+
* @name angular.module.ng.$compile.directive.Attributes#$set
1085+
* @methodOf angular.module.ng.$compile.directive.Attributes
1086+
* @function
1087+
*
1088+
* @description
1089+
* Set DOM element attribute value.
1090+
*
1091+
*
1092+
* @param {string} name Normalized element attribute name of the property to modify. The name is
1093+
* revers translated using the {@link angular.module.ng.$compile.directive.Attributes#$attr $attr}
1094+
* property to the original name.
1095+
* @param {string} value Value to set the attribute to.
1096+
*/
1097+
10481098

10491099

10501100
/**

src/ng/filter/filters.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -270,7 +270,7 @@ var DATE_FORMATS_SPLIT = /((?:[^yMdHhmsaZE']+)|(?:'(?:[^']|'')*')|(?:E+|y+|M+|d+
270270
* * `'Z'`: 4 digit (+sign) representation of the timezone offset (-1200-1200)
271271
*
272272
* `format` string can also be one of the following predefined
273-
* {@link guide/dev_guide.i18n localizable formats}:
273+
* {@link guide/i18n localizable formats}:
274274
*
275275
* * `'medium'`: equivalent to `'MMM d, y h:mm:ss a'` for en_US locale
276276
* (e.g. Sep 3, 2010 12:05:08 pm)

src/ng/parse.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -814,7 +814,7 @@ function getterFn(path, csp) {
814814
*
815815
* @description
816816
*
817-
* Converts Angular {@link guid/expression expression} into a function.
817+
* Converts Angular {@link guide/expression expression} into a function.
818818
*
819819
* <pre>
820820
* var getter = $parse('user.name');

src/ng/rootScope.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -165,7 +165,7 @@ function $RootScopeProvider(){
165165
* the scope and its child scopes to be permanently detached from the parent and thus stop
166166
* participating in model change detection and listener notification by invoking.
167167
*
168-
* @params {boolean} isolate if true then the scoped does not prototypically inherit from the
168+
* @param {boolean} isolate if true then the scoped does not prototypically inherit from the
169169
* parent scope. The scope is isolated, as it can not se parent scope properties.
170170
* When creating widgets it is useful for the widget to not accidently read parent
171171
* state.

0 commit comments

Comments
 (0)