Only document enums when they have API properties
This commit is contained in:
@@ -73,9 +73,6 @@ function includeAugments(doclet) {
|
||||
});
|
||||
}
|
||||
cls._hideConstructor = true;
|
||||
if (!cls.undocumented) {
|
||||
cls._documented = true;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -182,13 +179,14 @@ exports.handlers = {
|
||||
doclet._hideConstructor = true;
|
||||
includeAugments(doclet);
|
||||
sortOtherMembers(doclet);
|
||||
} else if (!doclet._hideConstructor
|
||||
&& !(doclet.longname in defaultExports && byLongname[doclet.longname].some(d => d.isEnum))) {
|
||||
} else if (!doclet._hideConstructor) {
|
||||
// Remove all other undocumented symbols
|
||||
doclet.undocumented = true;
|
||||
}
|
||||
if (doclet._documented) {
|
||||
delete doclet.undocumented;
|
||||
if (doclet.memberof && byLongname[doclet.memberof] &&
|
||||
byLongname[doclet.memberof][0].isEnum &&
|
||||
!byLongname[doclet.memberof][0].properties.some(p => p.stability)) {
|
||||
byLongname[doclet.memberof][0].undocumented = true;
|
||||
}
|
||||
}
|
||||
},
|
||||
|
||||
@@ -64,7 +64,7 @@ var self = this;
|
||||
<ul><?js fires.forEach(function(f) {
|
||||
var parts = f.split(/#?event:/);
|
||||
var type = parts.pop();
|
||||
var eventClassName = parts[0];
|
||||
var eventClass = self.find({longname: parts[0]})[0];
|
||||
parts = type.split(' ');
|
||||
type = parts.shift();
|
||||
var description = parts.length ? parts.join(' ') : '';
|
||||
@@ -74,12 +74,9 @@ var self = this;
|
||||
}
|
||||
?>
|
||||
<li class="<?js= (eventDoclet || data).stability !== 'stable' ? 'unstable' : '' ?>">
|
||||
<code><?js= eventClassName ? self.linkto(f, type) : type ?></code>
|
||||
<?js if (eventClassName) {
|
||||
var eventClass = self.find({longname: eventClassName})[0];
|
||||
if (eventClass) { ?>
|
||||
(<?js= self.linkto(eventClass.longname) ?>)
|
||||
<?js } ?>
|
||||
<code><?js= eventClass ? self.linkto(f, type) : type ?></code>
|
||||
<?js if (eventClass) { ?>
|
||||
(<?js= self.linkto(eventClass.longname) ?>)
|
||||
<?js } ?>
|
||||
<?js= self.partial('stability.tmpl', eventDoclet || (data.stability ? data : {})) ?>
|
||||
<?js if (description) { ?> -
|
||||
|
||||
Reference in New Issue
Block a user