mirror of
https://github.com/hasura/graphql-engine.git
synced 2024-12-15 17:31:56 +03:00
cc30f08f6e
PR-URL: https://github.com/hasura/graphql-engine-mono/pull/4261 GitOrigin-RevId: 3d80068acdd61b5350fc36ec3444db47508f9c09
24 lines
570 B
HTML
24 lines
570 B
HTML
{% extends "layout.html" %}
|
|
|
|
{% block extrafooter %}
|
|
<!-- handle search query -->
|
|
<script>
|
|
const handleQueryParams = function() {
|
|
const urlParams = new URLSearchParams(window.location.search);
|
|
const searchTerm = urlParams.get('query');
|
|
|
|
if (searchTerm) {
|
|
const searchInput = document.getElementById('search_element');
|
|
|
|
searchInput.value = searchTerm;
|
|
searchInput.dispatchEvent(new Event('input'));
|
|
}
|
|
};
|
|
|
|
if (window.location.search.length > 0) {
|
|
handleQueryParams();
|
|
}
|
|
|
|
</script>
|
|
{% endblock %}
|