algolia / instantsearch

⚡️ Libraries for building performant and instant search and recommend experiences with Algolia. Compatible with JavaScript, TypeScript, React and Vue.
https://www.algolia.com/doc/guides/building-search-ui/what-is-instantsearch/js/
MIT License
3.73k stars 525 forks source link

feat(infinite-hits): add banners to vue flavor #6281

Closed taylorcjohnson closed 4 months ago

taylorcjohnson commented 4 months ago

Summary

This PR adds the new top banner to the Vue InfiniteHits widget and updates associated tests. The top banner feature has already been added to Hits and InfiniteHits for the JS and React flavors of InstantSearch.

This widget is slightly different from the React version by using a showBanner prop (defaulted to true) since relying on whether a parent component passed included content with the banner slot could be difficult. I'm open to changing this implementation if anyone has a recommended approach though.

Jira issue

Result

Getting Started example app: image

codesandbox-ci[bot] commented 4 months ago

This pull request is automatically built and testable in CodeSandbox.

To see build info of the built libraries, click here or the icon next to each commit SHA.

Latest deployment of this branch, based on commit 1c6a1209e90f6fc583a3db045df390cf07715c9e:

Sandbox Source
example-instantsearch-getting-started Configuration
example-react-instantsearch-getting-started Configuration
example-react-instantsearch-next-app-dir-example Configuration
example-react-instantsearch-next-routing-example Configuration
example-vue-instantsearch-getting-started Configuration