Skip to content

Commit f6f67c4

Browse files
author
Nicholas Thomson
committed
Hide video if coming from shared search results
1 parent fc30d0a commit f6f67c4

File tree

2 files changed

+4
-2
lines changed

2 files changed

+4
-2
lines changed

app/index.html

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -55,7 +55,7 @@
5555
<div class='header-text'>
5656
Slice, Filter &amp; Explore CrunchBase Data
5757
</div>
58-
<video preload="" width="720" height="450">
58+
<video ng-if="!shared_results" preload="" width="720" height="450">
5959
<source src="data/NYConsumerWebCosShortIntro.webm" type="video/webm">
6060
<source src="data/NYConsumerWebCosShortIntro.mp4" type="video/mp4">
6161
</video>

app/scripts/app.js

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -41,12 +41,14 @@ angular.module('crunchinatorApp', [
4141
.run(function run() {
4242
})
4343

44-
.controller('AppCtrl', function AppCtrl($scope) {
44+
.controller('AppCtrl', function AppCtrl($scope, $location) {
4545
$scope.isIE = function() {
4646
var myNav = navigator.userAgent.toLowerCase();
4747
return (myNav.indexOf('msie') !== -1) ? parseInt(myNav.split('msie')[1]) : false;
4848
};
4949

50+
$scope.shared_results = !!$location.search().filters;
51+
5052
$scope.$on('$stateChangeSuccess', function(event, toState){
5153
if (angular.isDefined(toState.data.pageTitle)) {
5254
$scope.pageTitle = toState.data.pageTitle;

0 commit comments

Comments
 (0)