aboutsummaryrefslogtreecommitdiffstats
path: root/docs/app
diff options
context:
space:
mode:
Diffstat (limited to 'docs/app')
-rw-r--r--docs/app/assets/Error404.html13
-rw-r--r--docs/app/src/docs.js2
-rw-r--r--docs/app/src/search.js4
3 files changed, 18 insertions, 1 deletions
diff --git a/docs/app/assets/Error404.html b/docs/app/assets/Error404.html
new file mode 100644
index 00000000..d9ba1d72
--- /dev/null
+++ b/docs/app/assets/Error404.html
@@ -0,0 +1,13 @@
+<h1>Welcome To AngularJS</h1>
+
+<p>The page you were looking for is not here. Perhaps you were looking for something else...</p>
+
+<div class="search-results-frame" ng-controller="Error404SearchCtrl">
+
+ <div ng-repeat="(key, value) in results" ng-show="value.length">
+ <h4>{{ key }}</h4>
+ <ul class="search-results">
+ <li ng-repeat="item in value"><a ng-href="{{ item.path }}">{{ item.name }}</a></li>
+ </ul>
+ </div>
+</div>
diff --git a/docs/app/src/docs.js b/docs/app/src/docs.js
index 5163e982..74d78136 100644
--- a/docs/app/src/docs.js
+++ b/docs/app/src/docs.js
@@ -87,7 +87,7 @@ angular.module('DocsController', [])
breadcrumbPath += '/';
});
} else {
- $scope.currentArea = null;
+ $scope.currentArea = NG_NAVIGATION['api'];
$scope.breadcrumb = [];
}
});
diff --git a/docs/app/src/search.js b/docs/app/src/search.js
index 9ae18ff6..49d73343 100644
--- a/docs/app/src/search.js
+++ b/docs/app/src/search.js
@@ -45,6 +45,10 @@ angular.module('search', [])
};
}])
+.controller('Error404SearchCtrl', ['$scope', '$location', 'docsSearch', function($scope, $location, docsSearch) {
+ $scope.results = docsSearch($location.path().split(/[\/\.:]/).pop());
+}])
+
.factory('lunrSearch', function() {
return function(properties) {
if (window.RUNNING_IN_NG_TEST_RUNNER) return null;