mirror of
https://github.com/scratchfoundation/paper.js.git
synced 2025-01-22 07:19:57 -05:00
More work on jsdoc method linking.
This commit is contained in:
parent
8bfc9c3e2a
commit
079692bdc3
1 changed files with 2 additions and 2 deletions
|
@ -127,13 +127,13 @@ Link.prototype._makeSymbolLink = function(alias, parameters) {
|
||||||
var target = (this.targetName)? " target=\""+this.targetName+"\"" : "";
|
var target = (this.targetName)? " target=\""+this.targetName+"\"" : "";
|
||||||
// if there is no symbol by that name just return the name unaltered
|
// if there is no symbol by that name just return the name unaltered
|
||||||
if (!linkTo) {
|
if (!linkTo) {
|
||||||
return this.text || alias;
|
return this.text || alias + (parameters || '');
|
||||||
} else {
|
} else {
|
||||||
// it's a symbol in another file
|
// it's a symbol in another file
|
||||||
if (!linkTo.is("CONSTRUCTOR") && !linkTo.isNamespace) { // it's a method or property
|
if (!linkTo.is("CONSTRUCTOR") && !linkTo.isNamespace) { // it's a method or property
|
||||||
linkPath= (Link.filemap) ? Link.filemap[linkTo.memberOf] :
|
linkPath= (Link.filemap) ? Link.filemap[linkTo.memberOf] :
|
||||||
escape(linkTo.memberOf) || "_global_";
|
escape(linkTo.memberOf) || "_global_";
|
||||||
linkPath += publish.conf.ext + "#" + Link.symbolNameToLinkName(linkTo);
|
linkPath += publish.conf.ext + "#" + Link.symbolNameToLinkName(linkTo).toLowerCase();
|
||||||
if (parameters) {
|
if (parameters) {
|
||||||
linkPath += '-' + parameters.replace(/[()]+/g, '').split(', ').join('-').toLowerCase();
|
linkPath += '-' + parameters.replace(/[()]+/g, '').split(', ').join('-').toLowerCase();
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue