Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
7 changes: 5 additions & 2 deletions _config.yml
Original file line number Diff line number Diff line change
Expand Up @@ -91,9 +91,12 @@ docs:
name: Quick Start Guide
url: https://userguide.mdanalysis.org/stable/examples/quickstart.html

# The algolia.read_only_api_key may be safely put into frontend code
# and this is not a security issue.
algolia:
index_name: mdanalysis
read_only_api_key: 307d780013d06fdde7a4eae462db0e74
index_name: mdanalysis
appId: Y8HJT3NO22
read_only_api_key: 68fa6789d0a275a311f68914e0c2366e

numfocus:
donate: https://numfocus.org/donate-to-mdanalysis
Expand Down
12 changes: 6 additions & 6 deletions _includes/footer.html
Original file line number Diff line number Diff line change
@@ -1,12 +1,12 @@


<!-- Algolia DocSearch https://community.algolia.com/docsearch/ -->
<script type="text/javascript" src="https://cdn.jsdelivr.net/npm/docsearch.js@2/dist/cdn/docsearch.min.js"></script>
<script type="text/javascript"> docsearch({
apiKey: '{{ site.algolia.read_only_api_key }}',
indexName: '{{ site.algolia.index_name }}',
inputSelector: 'input[type=text]',
debug: true // Set debug to true if you want to inspect the dropdown
<script type="text/javascript" src="https://cdn.jsdelivr.net/npm/@docsearch/js@alpha"></script>
<script type="text/javascript"> docsearch({
container: '#docsearch',
appId: '{{ site.algolia.appId }}',
indexName: '{{ site.algolia.index_name }}',
apiKey: '{{ site.algolia.read_only_api_key }}',
});
</script>

Expand Down
7 changes: 3 additions & 4 deletions _includes/head.html
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,9 @@
<link rel="stylesheet" href="{{ site.baseurl }}/public/css/hyde.css">
<link rel="stylesheet" href="{{ site.baseurl }}/public/css/local.css">
<link rel="stylesheet" href="https://fonts.googleapis.com/css?family=PT+Sans:400,400italic,700|Abril+Fatface">

<!-- Algolia DocSearch https://community.algolia.com/docsearch/ -->
<link rel="stylesheet" href="https://cdn.jsdelivr.net/npm/@docsearch/css@alpha" />
<link rel="stylesheet" href="{{ site.baseurl }}/public/css/search.css">
<!-- Icons -->
<link rel="apple-touch-icon-precomposed" sizes="144x144" href="{{ site.baseurl }}/public/apple-touch-icon-144-precomposed.png">
<link rel="shortcut icon" href="{{ site.baseurl }}/public/favicon.ico">
Expand All @@ -37,7 +39,4 @@
anchors.add('h1, h2, h3, h4, h5, h6');
});
</script>

<!-- Algolia DocSearch https://community.algolia.com/docsearch/ -->
<link rel="stylesheet" href="https://cdn.jsdelivr.net/npm/docsearch.js@2/dist/cdn/docsearch.min.css" />
</head>
2 changes: 1 addition & 1 deletion _includes/sidebar.html
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ <h1>
<p class="lead">{{ site.description }}</p>
</div>

<input type="text" class="searchbox" autocomplete="off" name="query" placeholder="Search mdanalysis.org..." />
<div id="docsearch">Enable javascript for search.</div>

<nav class="sidebar-nav">
{% assign site_base_url = site.baseurl | append: "/" %}
Expand Down
12 changes: 12 additions & 0 deletions public/css/search.css
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
/* CSS for customizing Algolia search box */
/* https://github.com/algolia/docsearch/tree/next/packages/docsearch-css/src */

/* override variables in _variables.css */

:root {
--docsearch-primary-color: #FF9200;
--docsearch-text-color: #343131;
--docsearch-muted-color: #808080;
--docsearch-logo-color: rgba(0, 0, 0);
}