|
13 | 13 | {% set script_files = script_files + ['_static/contentsFix.js'] %}
|
14 | 14 | {% set script_files = script_files + ['_static/ga.js'] %}
|
15 | 15 | {% set script_files = script_files + ['_static/warnOldDocs.js'] %}
|
| 16 | +{% set script_files = script_files + ['https://cdn.jsdelivr.net/docsearch.js/1/docsearch.min.js'] %} |
16 | 17 | {% set css_files = css_files + ['_static/prettify.css'] %}
|
17 | 18 | {% set css_files = css_files + ['_static/base.css'] %}
|
18 | 19 | {% set css_files = css_files + ['_static/docs.css'] %}
|
19 | 20 | {% set css_files = css_files + ['http://fonts.googleapis.com/css?family=Source+Sans+Pro:300,400,600,700'] %}
|
| 21 | +{% set css_files = css_files + ['https://cdn.jsdelivr.net/docsearch.js/1/docsearch.min.css'] %} |
20 | 22 |
|
21 | 23 | {# do not display relbars #}
|
22 | 24 | {% block relbar1 %}{% endblock %}
|
|
70 | 72 | })();
|
71 | 73 | </script>
|
72 | 74 | {%- endif %}
|
| 75 | + |
73 | 76 | {% endblock %}
|
74 | 77 |
|
75 | 78 | {% block content %}
|
|
116 | 119 | <span class="divider">«</span> <a href="{{ prev.link|e }}">{{ prev.title }}</a> <span class="divider">|</span>
|
117 | 120 | {%- endif %}
|
118 | 121 | </li>
|
119 |
| - <li> |
| 122 | + <li style="float: left"> |
120 | 123 | Version {{ release|e }}
|
121 | 124 | </li>
|
| 125 | + <li style="float: left"> |
| 126 | + <input type="search" id="q" class="form-control" /> |
| 127 | + </li> |
122 | 128 | </ul>
|
123 | 129 | </div>
|
124 | 130 | </div>
|
125 | 131 | <div class="row">
|
126 |
| - {%- if include_analytics %} |
127 |
| - <div class="span9"> |
128 |
| - <div id="cse">Loading</div> |
129 |
| - </div> |
130 |
| - {%- endif -%} |
131 | 132 | <div class="span9">
|
132 | 133 | {% block body %}{% endblock %}
|
133 | 134 | </div>
|
|
184 | 185 | </div>
|
185 | 186 | </div>
|
186 | 187 | {%- if include_analytics %}
|
187 |
| -<script src="http://www.google.com/jsapi" type="text/javascript"></script> |
188 |
| -<script type="text/javascript"> |
189 |
| - google.load('search', '1', {language : 'en', style : google.loader.themes.MINIMALIST}); |
190 |
| - google.setOnLoadCallback(function() { |
191 |
| - var customSearchOptions = {}; var customSearchControl = new google.search.CustomSearchControl( |
192 |
| - '003065520604945464838:izzukx8-qba', customSearchOptions); |
193 |
| - customSearchControl.setResultSetSize(google.search.Search.FILTERED_CSE_RESULTSET); |
194 |
| - customSearchControl.draw('cse'); |
195 |
| - var path = window.location.pathname.split('/').slice(0,4); |
196 |
| - if(window.location.hostname && path.length >= 4) { |
197 |
| - var site = "site:" + window.location.hostname + path.join('/').toString(); |
198 |
| - customSearchControl.setSearchStartingCallback(this, function(c, s, q) { s.setQueryAddition(site); }); |
199 |
| - } |
200 |
| - }, true); |
201 |
| -</script> |
202 |
| -<style type="text/css"> |
203 |
| - .gsc-control-cse { |
204 |
| - font-family: Arial, sans-serif; |
205 |
| - border-color: rgb(242, 242, 235); |
206 |
| - background-color: rgb(242, 242, 235); |
207 |
| - } |
208 |
| - .gsc-control-cse .gsc-table-result { |
209 |
| - font-family: Arial, sans-serif; |
210 |
| - display: block; |
211 |
| - } |
212 |
| - input.gsc-input { |
213 |
| - border-color: #BBBBBB; |
214 |
| - } |
215 |
| - input.gsc-search-button { |
216 |
| - border-color: rgb(34, 57, 64); |
217 |
| - background-color: rgb(68, 114, 129); |
218 |
| - color: #FFFFFF; |
219 |
| - } |
220 |
| - .gsc-tabHeader.gsc-tabhInactive { |
221 |
| - border-color: #777777; |
222 |
| - background-color: #777777; |
223 |
| - } |
224 |
| - .gsc-tabHeader.gsc-tabhActive { |
225 |
| - border-color: #333333; |
226 |
| - background-color: #333333; |
227 |
| - } |
228 |
| - .gsc-tabsArea { |
229 |
| - border-color: #333333; |
230 |
| - } |
231 |
| - .gsc-webResult.gsc-result, |
232 |
| - .gsc-results .gsc-imageResult { |
233 |
| - border-color: #666666; |
234 |
| - background-color: #FFFFFF; |
235 |
| - padding: 0.5em 0.5em; |
236 |
| - } |
237 |
| - .gsc-webResult.gsc-result:hover, |
238 |
| - .gsc-imageResult:hover { |
239 |
| - border-color: #AAAAAA; |
240 |
| - background-color: #FFFFFF; |
241 |
| - padding: 0.5em 0.5em; |
242 |
| - } |
243 |
| - .gsc-webResult.gsc-result.gsc-promotion:hover { |
244 |
| - border-color: #AAAAAA; |
245 |
| - background-color: #FFFFFF; |
246 |
| - } |
247 |
| - .gs-webResult.gs-result a.gs-title:link, |
248 |
| - .gs-webResult.gs-result a.gs-title:link b, |
249 |
| - .gs-imageResult a.gs-title:link, |
250 |
| - .gs-imageResult a.gs-title:link b { |
251 |
| - color: #444444; |
252 |
| - } |
253 |
| - .gs-webResult.gs-result a.gs-title:visited, |
254 |
| - .gs-webResult.gs-result a.gs-title:visited b, |
255 |
| - .gs-imageResult a.gs-title:visited, |
256 |
| - .gs-imageResult a.gs-title:visited b { |
257 |
| - color: #444444; |
258 |
| - } |
259 |
| - .gs-webResult.gs-result a.gs-title:hover, |
260 |
| - .gs-webResult.gs-result a.gs-title:hover b, |
261 |
| - .gs-imageResult a.gs-title:hover, |
262 |
| - .gs-imageResult a.gs-title:hover b { |
263 |
| - color: #444444; |
264 |
| - } |
265 |
| - .gs-webResult.gs-result a.gs-title:active, |
266 |
| - .gs-webResult.gs-result a.gs-title:active b, |
267 |
| - .gs-imageResult a.gs-title:active, |
268 |
| - .gs-imageResult a.gs-title:active b { |
269 |
| - color: #777777; |
270 |
| - } |
271 |
| - .gsc-cursor-page { |
272 |
| - color: #444444; |
273 |
| - } |
274 |
| - a.gsc-trailing-more-results:link { |
275 |
| - color: #444444; |
276 |
| - } |
277 |
| - .gs-webResult .gs-snippet, |
278 |
| - .gs-imageResult .gs-snippet, |
279 |
| - .gs-fileFormatType { |
280 |
| - color: #333333; |
281 |
| - } |
282 |
| - .gs-webResult div.gs-visibleUrl, |
283 |
| - .gs-imageResult div.gs-visibleUrl { |
284 |
| - color: #000000; |
285 |
| - } |
286 |
| - .gs-webResult div.gs-visibleUrl-short { |
287 |
| - color: #000000; |
288 |
| - } |
289 |
| - .gs-webResult div.gs-visibleUrl-short { |
290 |
| - display: none; |
291 |
| - } |
292 |
| - .gs-webResult div.gs-visibleUrl-long { |
293 |
| - display: block; |
294 |
| - } |
295 |
| - .gs-promotion div.gs-visibleUrl-short { |
296 |
| - display: none; |
297 |
| - } |
298 |
| - .gs-promotion div.gs-visibleUrl-long { |
299 |
| - display: block; |
300 |
| - } |
301 |
| - .gsc-cursor-box { |
302 |
| - border-color: #FFFFFF; |
303 |
| - } |
304 |
| - .gsc-results .gsc-cursor-box .gsc-cursor-page { |
305 |
| - border-color: #777777; |
306 |
| - background-color: #FFFFFF; |
307 |
| - color: #444444; |
308 |
| - } |
309 |
| - .gsc-results .gsc-cursor-box .gsc-cursor-current-page { |
310 |
| - border-color: #333333; |
311 |
| - background-color: #333333; |
312 |
| - color: #444444; |
313 |
| - } |
314 |
| - .gsc-webResult.gsc-result.gsc-promotion { |
315 |
| - border-color: #CCCCCC; |
316 |
| - background-color: #E6E6E6; |
317 |
| - } |
318 |
| - .gsc-completion-title { |
319 |
| - color: #444444; |
320 |
| - } |
321 |
| - .gsc-completion-snippet { |
322 |
| - color: #333333; |
323 |
| - } |
324 |
| - .gs-promotion a.gs-title:link, |
325 |
| - .gs-promotion a.gs-title:link *, |
326 |
| - .gs-promotion .gs-snippet a:link { |
327 |
| - color: #0000CC; |
328 |
| - } |
329 |
| - .gs-promotion a.gs-title:visited, |
330 |
| - .gs-promotion a.gs-title:visited *, |
331 |
| - .gs-promotion .gs-snippet a:visited { |
332 |
| - color: #0000CC; |
333 |
| - } |
334 |
| - .gs-promotion a.gs-title:hover, |
335 |
| - .gs-promotion a.gs-title:hover *, |
336 |
| - .gs-promotion .gs-snippet a:hover { |
337 |
| - color: #444444; |
338 |
| - } |
339 |
| - .gs-promotion a.gs-title:active, |
340 |
| - .gs-promotion a.gs-title:active *, |
341 |
| - .gs-promotion .gs-snippet a:active { |
342 |
| - color: #00CC00; |
343 |
| - } |
344 |
| - .gs-promotion .gs-snippet, |
345 |
| - .gs-promotion .gs-title .gs-promotion-title-right, |
346 |
| - .gs-promotion .gs-title .gs-promotion-title-right * { |
347 |
| - color: #333333; |
348 |
| - } |
349 |
| - .gs-promotion .gs-visibleUrl, |
350 |
| - .gs-promotion .gs-visibleUrl-short { |
351 |
| - color: #00CC00; |
352 |
| - } |
353 |
| -</style> |
| 188 | + |
354 | 189 | {%- endif %}
|
355 | 190 | <script type="text/javascript">
|
356 | 191 | var $toc = $('#toc');
|
|
362 | 197 | $el.prepend($("<a class='section-marker' href='#" + $el.attr("id") + "'>§</a>"))
|
363 | 198 | });
|
364 | 199 | </script>
|
| 200 | + |
| 201 | +<!-- Algolia docs search --> |
| 202 | +<script type="text/javascript"> |
| 203 | + var version = DOCUMENTATION_OPTIONS.VERSION; |
| 204 | + |
| 205 | + var lang = "scala"; |
| 206 | + var path = window.location.pathname; |
| 207 | + if (path.includes("/java/") || path.includes("java.html")) lang = "java"; |
| 208 | + |
| 209 | + console.log("Search configured for:", lang, "@", version); |
| 210 | + |
| 211 | + docsearch({ |
| 212 | + apiKey: '543bad5ad786495d9ccd445ed34ed082', |
| 213 | + indexName: 'akka_io', |
| 214 | + inputSelector: '#q', |
| 215 | + algoliaOptions: { |
| 216 | + hitsPerPage: 10, |
| 217 | + facetFilters: '["language:' + lang + '","version:' + version + '"]' |
| 218 | + } |
| 219 | + }); |
| 220 | + |
| 221 | + // set up "/" as global shortcut for focusing on search |
| 222 | + $(document).keypress(function (event) { |
| 223 | + if (event.keyCode == 47) { |
| 224 | + $("#q").focus(); |
| 225 | + return false; // swallow key event, otherwise the / char would be input into the search box |
| 226 | + } |
| 227 | + }); |
| 228 | +</script> |
| 229 | + |
365 | 230 | {% block footer %}{% endblock %}
|
366 | 231 | {%- endblock %}
|
367 | 232 | {% endblock %}
|
|
0 commit comments