From 65989c6f0d13b8f205ab929999a4b9f66c8c1c93 Mon Sep 17 00:00:00 2001 From: Igor Minar Date: Wed, 17 Nov 2010 17:26:25 -0800 Subject: add support for {@link} tags within @description and remove implicit linking use as: - foo {@link bar} - foo {@link bar desc} I'm removing implicit linking because it unintentionally links stuff and generally interferes with other conversions. We have to link stuff explicitely from now on. --- docs/spec/collectSpec.js | 18 +++++++++++++++--- 1 file changed, 15 insertions(+), 3 deletions(-) (limited to 'docs/spec') diff --git a/docs/spec/collectSpec.js b/docs/spec/collectSpec.js index 822e97fb..f6b5a319 100644 --- a/docs/spec/collectSpec.js +++ b/docs/spec/collectSpec.js @@ -13,11 +13,11 @@ describe('collect', function(){ }); it('should not replace anything in
', function(){
-      expect(collect.markdown('angular.x\n
\nangular.k\n
\nangular.x')). + expect(collect.markdown('bah x\n
\nangular.k\n
\n asdf x')). toEqual( - '

angular.x

' + + '

bah x

' + '
\nangular.k\n
' + - '

angular.x

'); + '

asdf x

'); }); }); @@ -196,6 +196,18 @@ describe('collect', function(){ '
cba
'); }); + + it('should support nested @link annotations with or without description', function() { + TAG.description(doc, 'description', + 'foo {@link angular.foo}\n\n da {@link angular.foo bar foo bar } \n\n' + + 'dad{@link angular.foo}\n\n' + + '{@link angular.directive.ng:foo ng:foo}'); + expect(doc.description). + toBe('

foo angular.foo

\n\n' + + '

da bar foo bar

\n\n' + + '

dadangular.foo

\n\n' + + '

ng:foo

'); + }); }); describe('@example', function(){ -- cgit v1.2.3