From 997aec8660416c67cd2ced7666df7dc8d5a8cb84 Mon Sep 17 00:00:00 2001 From: Andy Joslin Date: Wed, 26 Feb 2014 13:56:42 -0500 Subject: [PATCH] docs(ionContent): add doc comments --- js/ext/angular/src/directive/ionicContent.js | 29 ++++++++++++++++++-- package.json | 4 ++- 2 files changed, 30 insertions(+), 3 deletions(-) diff --git a/js/ext/angular/src/directive/ionicContent.js b/js/ext/angular/src/directive/ionicContent.js index fd1c6b6b1d..f1abd1a57d 100644 --- a/js/ext/angular/src/directive/ionicContent.js +++ b/js/ext/angular/src/directive/ionicContent.js @@ -16,8 +16,33 @@ angular.module('ionic.ui.content', ['ionic.ui.service', 'ionic.ui.scroll']) }; }) -// The content directive is a core scrollable content area -// that is part of many View hierarchies +/* + * @ngdoc directive + * @name ionContent + * + * @description + * The ionContent directive provides an easy to use content area that can be configured to use + * Ionic's custom Scroll View, or the built in overflow scorlling of the browser. + * + * While we recommend using the custom Scroll features in Ionic in most cases, sometimes (for performance reasons) only the browser's native overflow scrolling will suffice, and so we've made it easy to toggle between the Ionic scroll implementation and overflow scrolling. + * + * When using the Ionic scroll features, you'll get pull-to-refresh, customizable scroll mechanics (like bounce easing, momentum acceleration, etc.) which aligns Ionic with native SDKs that give you access to scroll behavior. You'll also get events while in a momentum scroll, which -webkit-overflow-scrolling: touch will not, making it of limited use in real applications. + * + * Also, we are working on virtual list rendering which will only work when using Ionic's scroll view. That is on the upcoming roadmap. + * + * @restrict E + * @param {boolean=} scroll Whether to allow scrolling of content. Defaults to true. + * @param {boolean=} overflow-scroll Whether to use overflow-scrolling instead of Ionic scroll. + * @param {boolean=} padding Whether to add padding to the content. + * @param {boolean=} has-header Whether to offset the content for a header bar. + * @param {boolean=} has-subheader Whether to offset the content for a subheader bar. + * @param {boolean=} has-footer Whether to offset the content for a footer bar. + * @param {boolean=} has-bouncing Whether to allow scrolling to bounce past the edges of the content. Defaults to true on iOS, false on Android. + * @param {expression=} on-refresh Expression to evaluate on refresh completion. + * @param {expression=} on-refresh-opening Expression to evaluate on refresh opening. + * @param {expression=} on-scroll Expression to evaluate when the content is scrolled. + * @param {expression=} on-scroll-complete Expression to evaluate when a scroll action completes. + */ .directive('ionContent', [ '$parse', '$timeout', diff --git a/package.json b/package.json index a4dfb186f4..f7fdff3d74 100644 --- a/package.json +++ b/package.json @@ -29,7 +29,9 @@ "grunt-remove-logging": "~0.2.0", "grunt-conventional-changelog": "~1.1.0", "grunt-contrib-connect": "^0.6.0", - "sauce-connect-launcher": "^0.2.2" + "sauce-connect-launcher": "^0.2.2", + "dgeni": "^0.1.1", + "dgeni-packages": "^0.2.4" }, "licenses": [ {