diff --git a/docs/app/js/demo.js b/docs/app/js/demo.js index d0e1a3a086b..a0592b2e1ac 100644 --- a/docs/app/js/demo.js +++ b/docs/app/js/demo.js @@ -3,7 +3,7 @@ DocsApp .directive('layout', function() { return angular.noop; }) .directive('docsDemo', [ '$mdUtil', -function($mdUtil) { +function() { return { restrict: 'E', scope: true, @@ -14,13 +14,23 @@ function($mdUtil) { bindToController: true }; - function DocsDemoCtrl($scope, $element, $attrs, $interpolate, codepen) { + function DocsDemoCtrl($scope, $element, $attrs, codepen) { var self = this; self.interpolateCode = angular.isDefined($attrs.interpolateCode); - self.demoId = $interpolate($attrs.demoId || '')($scope.$parent); - self.demoTitle = $interpolate($attrs.demoTitle || '')($scope.$parent); - self.demoModule = $interpolate($attrs.demoModule || '')($scope.$parent); + + $attrs.$observe('demoTitle', function(value) { + self.demoTitle = value; + }); + + $attrs.$observe('demoId', function(value) { + self.demoId = value; + }); + + $attrs.$observe('demoModule', function(value) { + self.demoModule = value; + }); + self.files = { css: [], js: [], html: [] }; diff --git a/docs/app/partials/layout-alignment.tmpl.html b/docs/app/partials/layout-alignment.tmpl.html index adefae2ffec..0d4e67dff70 100644 --- a/docs/app/partials/layout-alignment.tmpl.html +++ b/docs/app/partials/layout-alignment.tmpl.html @@ -23,7 +23,7 @@ layout-align Sets default alignment unless overridden by another breakpoint. - + layout-align-xs width < 600px @@ -67,20 +67,18 @@ Below is an interactive demo that lets you explore the visual results of the different settings:

-
-
- - -
-
one
-
two
-
three
-
-
-
-
-
+
+ + +
+
one
+
two
+
three
+
+
+
+