Unknown provider: $mdBottomSheetProvider <- $mdBottomSheet, Why??

320 views
Skip to first unread message

Mauricio nunes

unread,
Oct 22, 2014, 9:44:43 AM10/22/14
to ang...@googlegroups.com
<!doctype html>
<html lang="pt-BR">
<head>
  <title>BottomSheet</title>
  <meta charset="utf-8">
  <link rel="stylesheet" href="style.css"/>
  <link rel="stylesheet" href="angular-material.css"/>
  <meta name="viewport" content="width=device-width, user-scalable=no">
</head>
<body data-ng-app="app">  
 
 <div ng-controller="MyController">
  <md-button ng-click="openBottomSheet()">
    Open a Bottom Sheet!
  </md-button>
</div>

 
<script src="js/angular.min.js"></script>
<script src="js/hammer.min.js"></script>
<script src="js/angular-material-swipe.js"></script>  
<script src="js/angular-animate.min.js"></script>
<script src="js/angular-route.min.js"></script>
<script src="js/angular-aria.min.js"></script>

<script src="js/angular-material.min.js"></script>
<script>
 var app = angular.module('app', ['ngMaterial']);
 
app.controller('MyController', function($scope, $mdBottomSheet) {
 $scope.openBottomSheet = function() {
$mdBottomSheet.show({
 template: '<md-bottom-sheet>Hello!</md-bottom-sheet>'
});
 };
});

</script>

</body>
</html>

Emmanuel DEMEY

unread,
Oct 22, 2014, 10:31:47 AM10/22/14
to ang...@googlegroups.com
Where the $mdBottomSheet service come from ? is it one of your service ? or coming from ans external lib ?
Manu

--
You received this message because you are subscribed to the Google Groups "AngularJS" group.
To unsubscribe from this group and stop receiving emails from it, send an email to angular+u...@googlegroups.com.
To post to this group, send email to ang...@googlegroups.com.
Visit this group at http://groups.google.com/group/angular.
For more options, visit https://groups.google.com/d/optout.



--
Emmanuel DEMEY
Ingénieur Etude et Développement
Worldline, an atos company
+33 (0)6 47 47 42 02
demey.e...@gmail.com

Twitter : @EmmanuelDemey

Mauricio nunes

unread,
Oct 22, 2014, 10:40:38 AM10/22/14
to ang...@googlegroups.com
Them came from angular-material.min.js, right?
and I pass $mdBottomSheet service as a parameter in my controller.



--
You received this message because you are subscribed to a topic in the Google Groups "AngularJS" group.
To unsubscribe from this topic, visit https://groups.google.com/d/topic/angular/AcTjhpVqZlo/unsubscribe.
To unsubscribe from this group and all its topics, send an email to angular+u...@googlegroups.com.

Raul Vieira

unread,
Oct 22, 2014, 5:47:47 PM10/22/14
to ang...@googlegroups.com
Have you registered the module as a dependency of your module?

Raul

Sent from my iPhone

Mauricio nunes

unread,
Oct 22, 2014, 6:33:36 PM10/22/14
to ang...@googlegroups.com

Yes!
I guess is some version problems
I change The lib version and it works.

Reply all
Reply to author
Forward
0 new messages