From 2871346e19e98b179065015a850109c1cfc4c60c Mon Sep 17 00:00:00 2001 From: Wesley Cho Date: Thu, 13 Aug 2015 11:02:08 -0700 Subject: [PATCH] feat(carousel): add model binding support to slide - Add support for binding slide model to slide --- src/carousel/carousel.js | 1 + src/carousel/docs/README.md | 6 ++++-- 2 files changed, 5 insertions(+), 2 deletions(-) diff --git a/src/carousel/carousel.js b/src/carousel/carousel.js index 733c1caa61..4e48d95850 100644 --- a/src/carousel/carousel.js +++ b/src/carousel/carousel.js @@ -316,6 +316,7 @@ function CarouselDemoCtrl($scope) { }, scope: { active: '=?', + actual: '=?', index: '=?' }, link: function (scope, element, attrs, carouselCtrl) { diff --git a/src/carousel/docs/README.md b/src/carousel/docs/README.md index bf8bbe2225..69da16a93a 100644 --- a/src/carousel/docs/README.md +++ b/src/carousel/docs/README.md @@ -4,6 +4,8 @@ The carousel also offers support for touchscreen devices in the form of swiping. Use a `` element with `` elements inside it. It will automatically cycle through the slides at a given rate, and a current-index variable will be kept in sync with the currently visible slide. -Use the `no-wrap` attribute on a `` element to control the looping of slides; setting `no-wrap` to an expression which evaluates to a truthy value will prevent looping +Use the `no-wrap` attribute on a `` element to control the looping of slides; setting `no-wrap` to an expression which evaluates to a truthy value will prevent looping. -Use the `template-url` attribute on a `` or `` element to specify the url of a custom template to override the default templates +Use the `template-url` attribute on a `` or `` element to specify the url of a custom template to override the default templates. + +Use the `actual` attribute on a `` element to bind the slide model (or any object of interest) onto the slide directive's `$scope`, which makes it available for customization in the carousel template.