Skip to content

Commit

Permalink
feat(docs): Add Improve this doc link in each doc page, which links t…
Browse files Browse the repository at this point in the history
…o the edit mode of that file in github
  • Loading branch information
shyamseshadri authored and mhevery committed Mar 16, 2013
1 parent 1c1cd4f commit f197e39
Show file tree
Hide file tree
Showing 3 changed files with 7 additions and 2 deletions.
2 changes: 1 addition & 1 deletion docs/src/gen-docs.js
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,7 @@ writer.makeDir('build/docs/', true).then(function() {
});
}).then(function printStats() {
console.log('DONE. Generated ' + docs.length + ' pages in ' + (now()-start) + 'ms.' );
}).done();
});


function writeTheRest(writesFuture) {
Expand Down
3 changes: 2 additions & 1 deletion docs/src/ngdoc.js
Original file line number Diff line number Diff line change
Expand Up @@ -272,8 +272,9 @@ Doc.prototype = {
self = this;

dom.h(title(this.name), function() {
notice('deprecated', 'Deprecated API', self.deprecated);

notice('deprecated', 'Deprecated API', self.deprecated);
dom.tag('a', {href: 'http://github.com/angular/angular.js/edit/master/' + self.file, class: 'improve-docs btn btn-primary'}, 'Improve this doc');
if (self.ngdoc != 'overview') {
dom.h('Description', self.description, dom.html);
}
Expand Down
4 changes: 4 additions & 0 deletions docs/src/templates/css/docs.css
Original file line number Diff line number Diff line change
Expand Up @@ -86,6 +86,10 @@ img.AngularJS-small {
/* Content */
/* =============================== */

.improve-docs {
float: right;
}

.hint {
font-size: .7em;
color: #c0c0c0;
Expand Down

0 comments on commit f197e39

Please sign in to comment.