mediawiki-skins-Citizen/resources/skins.citizen.search/searchResults.js
2024-05-21 21:43:59 -04:00

21 lines
563 B
JavaScript

// const config = require( './config.json' );
// const htmlHelper = require( './htmlHelper.js' )();
const searchAction = require( './searchAction.js' )();
function searchResults() {
return {
fetch: function ( queryValue, activeSearchClient ) {
return activeSearchClient.fetchByTitle( queryValue );
},
render: function ( typeaheadEl, searchQuery ) {
searchAction.render( typeaheadEl, searchQuery );
},
clear: function ( typeaheadEl ) {
searchAction.clear( typeaheadEl );
}
};
}
/** @module searchResults */
module.exports = searchResults;