Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
E
EBI-Framework
Manage
Activity
Members
Code
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Locked files
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Container Registry
Operate
Environments
Analyze
Contributor analytics
CI/CD analytics
Repository analytics
Insights
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Terms and privacy
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
ebiwd
EBI-Framework
Commits
d93eb065
Commit
d93eb065
authored
8 years ago
by
khawkins
Browse files
Options
Downloads
Patches
Plain Diff
Disable global search when told
parent
996627ba
No related branches found
Branches containing commit
No related tags found
Tags containing commit
No related merge requests found
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
css/ebi-global.css
+4
-0
4 additions, 0 deletions
css/ebi-global.css
js/script.js
+13
-0
13 additions, 0 deletions
js/script.js
with
17 additions
and
0 deletions
css/ebi-global.css
+
4
−
0
View file @
d93eb065
...
...
@@ -187,6 +187,10 @@ nav a:hover {
#local-masthead
nav
ul
#global-nav
.menu
li
#home-mobile
{
display
:
none
;
}
}
/* Disable global-masthead search when told */
body
.no-global-search
#global-masthead
ul
#global-nav
li
#search
{
display
:
none
;
}
#global-masthead
{
/* custom colour for Home */
/* custom colour for Services */
...
...
This diff is collapsed.
Click to expand it.
js/script.js
+
13
−
0
View file @
d93eb065
...
...
@@ -79,6 +79,19 @@
catch
(
err
)
{}
})();
// disable the global search if a page defines a local search
// can also be disable by adding class 'no-global-search' to the body element
(
function
manageGlobalSearch
()
{
try
{
var
hasLocalSearch
=
document
.
getElementById
(
'
local-search
'
)
!==
null
;
var
hasLocalEBISearch
=
document
.
getElementById
(
'
ebi_search
'
)
!==
null
;
if
(
hasLocalSearch
||
hasLocalEBISearch
)
{
document
.
body
.
className
+=
'
no-global-search
'
;
}
}
catch
(
err
)
{}
})();
// Add error alerts for 'no input' on search boxes
(
function
searchNullError
()
{
try
{
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment