Skip to content
This repository has been archived by the owner on Sep 5, 2024. It is now read-only.

Commit

Permalink
update(bottomsheet): remove not existing targetEvent property from demo
Browse files Browse the repository at this point in the history
Remove the not existing option property from the demo, this confuses.

Fixes #6925

  Closes #6932
  • Loading branch information
devversion authored and ThomasBurleson committed Jan 31, 2016
1 parent 64b0bb9 commit f9109fc
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 8 deletions.
4 changes: 2 additions & 2 deletions src/components/bottomSheet/demoBasicUsage/index.html
Original file line number Diff line number Diff line change
Expand Up @@ -5,8 +5,8 @@ <h2 class="md-title">Usage</h2>
<h2 class="md-title">Actions</h2>
<p>Use one of the following buttons to display a bottom sheet.</p>
<div class="bottom-sheet-demo inset" layout="row" layout-sm="column" layout-align="center" >
<md-button flex="50" class="md-primary md-raised" ng-click="showListBottomSheet($event)">Show as List</md-button>
<md-button flex="50" class="md-primary md-raised" ng-click="showGridBottomSheet($event)">Show as Grid</md-button>
<md-button flex="50" class="md-primary md-raised" ng-click="showListBottomSheet()">Show as List</md-button>
<md-button flex="50" class="md-primary md-raised" ng-click="showGridBottomSheet()">Show as Grid</md-button>
</div>

<div ng-if="alert">
Expand Down
10 changes: 4 additions & 6 deletions src/components/bottomSheet/demoBasicUsage/script.js
Original file line number Diff line number Diff line change
Expand Up @@ -15,24 +15,22 @@ angular.module('bottomSheetDemo1', ['ngMaterial'])
.controller('BottomSheetExample', function($scope, $timeout, $mdBottomSheet, $mdToast) {
$scope.alert = '';

$scope.showListBottomSheet = function($event) {
$scope.showListBottomSheet = function() {
$scope.alert = '';
$mdBottomSheet.show({
templateUrl: 'bottom-sheet-list-template.html',
controller: 'ListBottomSheetCtrl',
targetEvent: $event
controller: 'ListBottomSheetCtrl'
}).then(function(clickedItem) {
$scope.alert = clickedItem['name'] + ' clicked!';
});
};

$scope.showGridBottomSheet = function($event) {
$scope.showGridBottomSheet = function() {
$scope.alert = '';
$mdBottomSheet.show({
templateUrl: 'bottom-sheet-grid-template.html',
controller: 'GridBottomSheetCtrl',
clickOutsideToClose: false,
targetEvent: $event
clickOutsideToClose: false
}).then(function(clickedItem) {
$mdToast.show(
$mdToast.simple()
Expand Down

0 comments on commit f9109fc

Please sign in to comment.