Skip to content

Commit

Permalink
General Restructuring of Showcase Module
Browse files Browse the repository at this point in the history
- added showcase service
- added workaround for tab.select misbehaviour
-- issue: angular-ui/bootstrap#2155
-- workaround: use ng-click to signify selection of tab
  • Loading branch information
lancecaraccioli committed Jun 4, 2014
1 parent 2bfcf86 commit a4e7713
Show file tree
Hide file tree
Showing 17 changed files with 4,345 additions and 111 deletions.
6 changes: 2 additions & 4 deletions app/app-controller.js
Original file line number Diff line number Diff line change
Expand Up @@ -11,23 +11,22 @@ angular.module('RightAnglesShowcase').
$scope.nav = {
items: [
{"name": "home", "heading": "", "glyph": "home"},
{"name": "showcase", "heading": "Showcase", "glyph": "briefcase"}
{"name": "showcases", "heading": "Showcase", "glyph": "briefcase"}
]
};
$scope.navItemSelected = function (navItem) {
$state.go(navItem.name);
};
$scope.$on('theme:chosen', function(){
$scope.themeName = themeService.getSelectedTheme().name;
console.log('theme was chosen:%s', $scope.themeName);
});
$scope.themeName = themeService.getSelectedTheme().name;
$state.go('home');
}
])
.config(function ($stateProvider) {
$stateProvider
.state('showcase', {
.state('showcases', {//todo use constant "rightAngles.showcase.STATES".ROOT,
url: "/showcase",
views: {
"appBody": {
Expand All @@ -43,6 +42,5 @@ angular.module('RightAnglesShowcase').
}
}
})

});

2 changes: 1 addition & 1 deletion app/app.css
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,7 @@ body {
.app-menu-panel{
position:absolute;
right:0;
top:0;
top:51px;
display:none;
height:100%;
}
Expand Down
5 changes: 3 additions & 2 deletions app/app.html
Original file line number Diff line number Diff line change
Expand Up @@ -56,11 +56,12 @@
<script type="text/javascript" src='bower_components/angular-resource/angular-resource.min.js'></script>
<script type="text/javascript" src='bower_components/angular-sanitize/angular-sanitize.min.js'></script>
<script type="text/javascript" src='bower_components/angular-ui-router/release/angular-ui-router.min.js'></script>
<script type="text/javascript" src='bower_components/angular-bootstrap/ui-bootstrap.min.js'></script>
<script type="text/javascript" src='bower_components/angular-bootstrap/ui-bootstrap-tpls.min.js'></script>
<script type="text/javascript" src='bower_components/angular-bootstrap/ui-bootstrap-tpls.js'></script>
<script type="text/javascript" src='app.js'></script>
<script type="text/javascript" src='info/info-service.js'></script>
<script type="text/javascript" src='app-controller.js'></script>
<script type="text/javascript" src='showcase/showcase.js'></script>
<script type="text/javascript" src='showcase/showcase-service.js'></script>
<script type="text/javascript" src='showcase/showcase-controller.js'></script>
<script type="text/javascript" src='home/home-controller.js'></script>
<script type="text/javascript" src='theme/theme.js'></script>
Expand Down
22 changes: 20 additions & 2 deletions app/app.js
Original file line number Diff line number Diff line change
Expand Up @@ -4,8 +4,26 @@ angular.module('RightAnglesShowcase', [
'ngSanitize',
'ui.router',
'ui.bootstrap',
'rightAngles.theme'
]);
'rightAngles.theme',
'rightAngles.showcase'
]).run(function($rootScope){
/*$rootScope.$on('$stateChangeStart',
function(event, toState, toParams, fromState, fromParams){
console.log(toState);
$rootScope.stateIsChanging = true;
}
);
$rootScope.$on('$stateChangeSuccess',
function(event, toState, toParams, fromState, fromParams){
$rootScope.stateIsChanging = false;
}
);
$rootScope.$on('$stateChangeError',
function(event, toState, toParams, fromState, fromParams, error){
$rootScope.stateIsChanging = false;
}
);*/
});



1 change: 1 addition & 0 deletions app/nursery/angular-bootstrap/TODO.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
See https://github.com/angular-ui/bootstrap/issues/2155
Loading

0 comments on commit a4e7713

Please sign in to comment.