diff --git a/Gruntfile.js b/Gruntfile.js index 0c190e7413..da09aff756 100644 --- a/Gruntfile.js +++ b/Gruntfile.js @@ -10,6 +10,7 @@ module.exports = function(grunt) { grunt.loadNpmTasks('grunt-html2js'); grunt.loadNpmTasks('grunt-karma'); grunt.loadNpmTasks('grunt-conventional-changelog'); + grunt.loadNpmTasks('grunt-ngdocs'); // Project configuration. grunt.util.linefeed = '\n'; @@ -147,6 +148,25 @@ module.exports = function(grunt) { 'grunt version:minor:"SNAPSHOT"', 'git commit package.json -m "chore(): Starting v%version%"' ] + }, + ngdocs: { + options: { + dest: 'dist/docs', + scripts: [ + 'angular.js', + '<%= concat.dist_tpls.dest %>' + ], + styles: [ + 'docs/css/style.css' + ], + navTemplate: 'docs/nav.html', + title: 'ui-bootstrap', + html5Mode: false + }, + api: { + src: ["src/**/*.js", "src/**/*.ngdoc"], + title: "API Documentation" + } } }); diff --git a/docs/css/style.css b/docs/css/style.css new file mode 100644 index 0000000000..0bbd3ad262 --- /dev/null +++ b/docs/css/style.css @@ -0,0 +1,21 @@ +.bs-docs-social { + margin-top: 1em; + padding: 15px 0; + text-align: center; + background-color: rgba(245,245,245,0.3); + border-top: 1px solid rgba(255,255,255,0.3); + border-bottom: 1px solid rgba(221,221,221,0.3); +} +.bs-docs-social-buttons { + position: absolute; + top: 8px; + margin-left: 0; + margin-bottom: 0; + padding-left: 0; + list-style: none; +} +.bs-docs-social-buttons li { + list-style: none; + display: inline-block; + line-height: 1; +} diff --git a/docs/nav.html b/docs/nav.html new file mode 100644 index 0000000000..078fd91200 --- /dev/null +++ b/docs/nav.html @@ -0,0 +1,13 @@ +
+ + + diff --git a/misc/changelog.tpl.md b/misc/changelog.tpl.md deleted file mode 100644 index f311f47c54..0000000000 --- a/misc/changelog.tpl.md +++ /dev/null @@ -1,28 +0,0 @@ -# <%= version%> (<%= today%>) - -## Features - -<% _(changelog.feat).forEach(function(changes, component) { %> -- **<%= component%>:** - <% changes.forEach(function(change) { %> - - <%= change.msg%> ([<%= change.sha1%>](https://github.com/angular-ui/bootstrap/commit/<%= change.sha1%>)) - <% }) %> -<% }) %> - -## Bug Fixes - -<% _(changelog.fix).forEach(function(changes, component) { %> -- **<%= component%>:** - <% changes.forEach(function(change) { %> - - <%= change.msg%> ([<%= change.sha1%>](https://github.com/angular-ui/bootstrap/commit/<%= change.sha1%>)) - <% }) %> -<% }) %> - -## Breaking Changes - -<% _(changelog.breaking).forEach(function(changes, component) { %> -- **<%= component%>:** - <% changes.forEach(function(change) { %> - <%= change.msg%> - <% }) %> -<% }) %> diff --git a/package.json b/package.json index f74b6c6692..d063fd1a0b 100644 --- a/package.json +++ b/package.json @@ -14,6 +14,7 @@ "grunt-html2js": "~0.1.3", "grunt-karma": "~0.4.4", "semver": "~1.1.4", - "shelljs": "~0.1.4" + "shelljs": "~0.1.4", + "grunt-ngdocs": "git://github.com/m7r/grunt-ngdocs" } } diff --git a/src/tabs/tabs.js b/src/tabs/tabs.js index 3971e30331..2a0a620694 100644 --- a/src/tabs/tabs.js +++ b/src/tabs/tabs.js @@ -1,3 +1,12 @@ + +/** + * @ngdoc overview + * @name ui.bootstrap.tabs + * + * @description + * AngularJS version of the tabs directive. + */ + angular.module('ui.bootstrap.tabs', []) .directive('tabs', function() { @@ -37,6 +46,31 @@ function TabsetCtrl($scope, $element) { }; }]) +/** + * @ngdoc directive + * @name ui.bootstrap.tabs.directive:tabset + * @restrict EA + * + * @description + * Tabset is the outer container for the tabs directive + * + * @param {boolean=} vertical Whether or not to use vertical styling for the tabs. + * + * @example +