From 7a139fb58f3b3b7a10369257c5ed1e180e958323 Mon Sep 17 00:00:00 2001 From: Yen Truong <36055303+yen-tt@users.noreply.github.com> Date: Thu, 8 Sep 2022 17:27:02 -0400 Subject: [PATCH] v1.0.0 (#306) ## Library Overview This library provides a set of React Components to integrate Yext Search onto your site. These Components are easily incorporated into a new or existing React application. They are powered by an instance of [Search Headless](https://github.com/yext/search-headless), provided to them via the `SearchHeadlessProvider`: ```tsx import { SearchHeadlessProvider, provideHeadless } from '@yext/search-headless-react'; import { SearchBar, UniversalResults } from '@yext/search-ui-react'; const config = { apiKey: '', experienceKey: '', locale: 'en', experienceVersion: 'PRODUCTION', } const searcher = provideHeadless(config); function App() { return ( ); } export default App; ``` Using this Headless instance, Components perform actions such as setting a filter or executing a search. Component `State` is also connected to the relevant portions of Headless `State`. ### Included Components The following Components are made available by the library: - [Search Bar](https://github.com/yext/search-ui-react/blob/main/docs/search-ui-react.searchbar.md) - [Universal Results](https://github.com/yext/search-ui-react/blob/main/docs/search-ui-react.universalresults.md) - [Vertical Results](https://github.com/yext/search-ui-react/blob/main/docs/search-ui-react.verticalresults.md) - [Direct Answer](https://github.com/yext/search-ui-react/blob/main/docs/search-ui-react.directanswer.md) - [Filter Search](https://github.com/yext/search-ui-react/blob/main/docs/search-ui-react.filtersearch.md) - [Standard Facets](https://github.com/yext/search-ui-react/blob/main/docs/search-ui-react.standardfacets.md) - [Static Filters](https://github.com/yext/search-ui-react/blob/main/docs/search-ui-react.staticfilters.md) - [Spell Check](https://github.com/yext/search-ui-react/blob/main/docs/search-ui-react.spellcheck.md) - [Alternative Verticals](https://github.com/yext/search-ui-react/blob/main/docs/search-ui-react.alternativeverticals.md) - [Applied Filters](https://github.com/yext/search-ui-react/blob/main/docs/search-ui-react.appliedfilters.md) - [Hierarchical Facets](https://github.com/yext/search-ui-react/blob/main/docs/search-ui-react.hierarchicalfacets.md) - [Location Bias](https://github.com/yext/search-ui-react/blob/main/docs/search-ui-react.locationbias.md) - [Numerical Facets](https://github.com/yext/search-ui-react/blob/main/docs/search-ui-react.numericalfacets.md) - [Results Count](https://github.com/yext/search-ui-react/blob/main/docs/search-ui-react.resultscount.md) - [Pagination](https://github.com/yext/search-ui-react/blob/main/docs/search-ui-react.pagination.md) To explore these Components individually, you can access our [Component Sandbox](https://storybook.hitchhikers.yext.com). ## Using the Library If you are using NPM 7+, you can install the components with the following command: ```bash npm install @yext/search-ui-react ``` The @yext/search-headless-react peer dependency will be automatically installed. If you are using NPM 6 or Yarn, you can install the library and its peer dependencies with this command: ```bash npx install-peerdeps @yext/search-ui-react ``` The command will work with Yarn so long as NPM 6+ is installed on the machine. ### Tailwind The library uses Tailwind to provide minimal, out-of-the-box styling of the Components. To use the Component Library's Styling without adding Tailwind to your project, add the following import: ```tsx import '@yext/search-ui-react/bundle.css' ``` If you have Tailwind already, you can add our styles to your `tailwind.config.js`: ```tsx const { ComponentsContentPath } = require('@yext/search-ui-react'); module.exports = { content: [ ComponentsContentPath ], // ... the rest of your tailwind config }; ``` --- THIRD-PARTY-NOTICES | 6 +++--- package-lock.json | 52 ++++++++++++++++++++++----------------------- package.json | 6 +++--- 3 files changed, 32 insertions(+), 32 deletions(-) diff --git a/THIRD-PARTY-NOTICES b/THIRD-PARTY-NOTICES index 09c3c834d..c8a3c3e6e 100644 --- a/THIRD-PARTY-NOTICES +++ b/THIRD-PARTY-NOTICES @@ -758,7 +758,7 @@ OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. The following NPM package may be included in this product: - - @yext/search-core@2.0.0-alpha.221 + - @yext/search-core@2.0.0 This package contains the following license and notice below: @@ -802,7 +802,7 @@ OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. The following NPM package may be included in this product: - - @yext/search-headless-react@2.0.0-alpha.158 + - @yext/search-headless-react@2.0.0 This package contains the following license and notice below: @@ -846,7 +846,7 @@ OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. The following NPM package may be included in this product: - - @yext/search-headless@2.0.0-alpha.136 + - @yext/search-headless@2.0.0 This package contains the following license and notice below: diff --git a/package-lock.json b/package-lock.json index f0db689e7..5c4b8220f 100644 --- a/package-lock.json +++ b/package-lock.json @@ -1,12 +1,12 @@ { "name": "@yext/search-ui-react", - "version": "1.0.0-alpha.301", + "version": "1.0.0", "lockfileVersion": 2, "requires": true, "packages": { "": { "name": "@yext/search-ui-react", - "version": "1.0.0-alpha.301", + "version": "1.0.0", "license": "BSD-3-Clause", "dependencies": { "@microsoft/api-documenter": "^7.15.3", @@ -51,7 +51,7 @@ "@typescript-eslint/eslint-plugin": "^5.16.0", "@typescript-eslint/parser": "^5.16.0", "@yext/eslint-config-slapshot": "^0.5.0", - "@yext/search-headless-react": "2.0.0-alpha.158", + "@yext/search-headless-react": "^2.0.0", "axe-playwright": "^1.1.11", "babel-jest": "^27.0.6", "babel-loader": "^8.2.3", @@ -69,7 +69,7 @@ "typescript": "~4.4.3" }, "peerDependencies": { - "@yext/search-headless-react": "2.0.0-alpha.158", + "@yext/search-headless-react": "^2.0.0", "react": "^16.14 || ^17 || ^18" } }, @@ -7759,9 +7759,9 @@ } }, "node_modules/@yext/search-core": { - "version": "2.0.0-alpha.221", - "resolved": "https://registry.npmjs.org/@yext/search-core/-/search-core-2.0.0-alpha.221.tgz", - "integrity": "sha512-zMWT+UObHEwl+FY6euhHR1VYHcC9Ie9k+CjZUX0qKRZsUlGuWO3rbQ4GqkfUaEPqZuRBGZGBPSRB84VmoDKF5w==", + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/@yext/search-core/-/search-core-2.0.0.tgz", + "integrity": "sha512-V5Z8aJrNAtuagB4y/ipzGUCfFBPdhXt3NTrGgUS5cguxCFM+AjlNyCZCjQyMa9BiITqWUBnSjIWVvCjnpsBf0w==", "dev": true, "dependencies": { "@babel/runtime-corejs3": "^7.12.5", @@ -7772,24 +7772,24 @@ } }, "node_modules/@yext/search-headless": { - "version": "2.0.0-alpha.136", - "resolved": "https://registry.npmjs.org/@yext/search-headless/-/search-headless-2.0.0-alpha.136.tgz", - "integrity": "sha512-cuPhi0KXbe9QjnuYLcffSBkWVaPE9I+4TttfvFuWl9MgPfIDe40WHff6s48jUWuyY+Fm/3R//59SNEAKeb2beA==", + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/@yext/search-headless/-/search-headless-2.0.0.tgz", + "integrity": "sha512-+YWcpH30ghDoM0G4WCmo5c6NzSNZ4gkOjXis67WlOQ9wOf6+EWsi/H0o3PR0Vrri45LKXFYEpS5oNVet7z1dGg==", "dev": true, "dependencies": { "@reduxjs/toolkit": "^1.8.1", - "@yext/search-core": "2.0.0-alpha.221", + "@yext/search-core": "^2.0.0", "js-levenshtein": "^1.1.6", "lodash": "^4.17.21" } }, "node_modules/@yext/search-headless-react": { - "version": "2.0.0-alpha.158", - "resolved": "https://registry.npmjs.org/@yext/search-headless-react/-/search-headless-react-2.0.0-alpha.158.tgz", - "integrity": "sha512-wAmEGdzCIhEXE4wNvR5DpgHEmugj9WOffLCa+kmmZJ/d7TQrE2pPQXp9OPmtSXEAjKNl1EfEOTspINPCnTZelw==", + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/@yext/search-headless-react/-/search-headless-react-2.0.0.tgz", + "integrity": "sha512-Ad5h9tdU3ESu7+oH3pUSEXm3LgHLpXEA3q+aWAOu7b1i3FMEa3bv/R+az+eX4wQAr28mZs8R1+aKfu4S2Rm1dg==", "dev": true, "dependencies": { - "@yext/search-headless": "2.0.0-alpha.136", + "@yext/search-headless": "^2.0.0", "use-sync-external-store": "^1.1.0" }, "peerDependencies": { @@ -32993,9 +32993,9 @@ } }, "@yext/search-core": { - "version": "2.0.0-alpha.221", - "resolved": "https://registry.npmjs.org/@yext/search-core/-/search-core-2.0.0-alpha.221.tgz", - "integrity": "sha512-zMWT+UObHEwl+FY6euhHR1VYHcC9Ie9k+CjZUX0qKRZsUlGuWO3rbQ4GqkfUaEPqZuRBGZGBPSRB84VmoDKF5w==", + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/@yext/search-core/-/search-core-2.0.0.tgz", + "integrity": "sha512-V5Z8aJrNAtuagB4y/ipzGUCfFBPdhXt3NTrGgUS5cguxCFM+AjlNyCZCjQyMa9BiITqWUBnSjIWVvCjnpsBf0w==", "dev": true, "requires": { "@babel/runtime-corejs3": "^7.12.5", @@ -33003,13 +33003,13 @@ } }, "@yext/search-headless": { - "version": "2.0.0-alpha.136", - "resolved": "https://registry.npmjs.org/@yext/search-headless/-/search-headless-2.0.0-alpha.136.tgz", - "integrity": "sha512-cuPhi0KXbe9QjnuYLcffSBkWVaPE9I+4TttfvFuWl9MgPfIDe40WHff6s48jUWuyY+Fm/3R//59SNEAKeb2beA==", + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/@yext/search-headless/-/search-headless-2.0.0.tgz", + "integrity": "sha512-+YWcpH30ghDoM0G4WCmo5c6NzSNZ4gkOjXis67WlOQ9wOf6+EWsi/H0o3PR0Vrri45LKXFYEpS5oNVet7z1dGg==", "dev": true, "requires": { "@reduxjs/toolkit": "^1.8.1", - "@yext/search-core": "2.0.0-alpha.221", + "@yext/search-core": "^2.0.0", "js-levenshtein": "^1.1.6", "lodash": "^4.17.21" }, @@ -33029,12 +33029,12 @@ } }, "@yext/search-headless-react": { - "version": "2.0.0-alpha.158", - "resolved": "https://registry.npmjs.org/@yext/search-headless-react/-/search-headless-react-2.0.0-alpha.158.tgz", - "integrity": "sha512-wAmEGdzCIhEXE4wNvR5DpgHEmugj9WOffLCa+kmmZJ/d7TQrE2pPQXp9OPmtSXEAjKNl1EfEOTspINPCnTZelw==", + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/@yext/search-headless-react/-/search-headless-react-2.0.0.tgz", + "integrity": "sha512-Ad5h9tdU3ESu7+oH3pUSEXm3LgHLpXEA3q+aWAOu7b1i3FMEa3bv/R+az+eX4wQAr28mZs8R1+aKfu4S2Rm1dg==", "dev": true, "requires": { - "@yext/search-headless": "2.0.0-alpha.136", + "@yext/search-headless": "^2.0.0", "use-sync-external-store": "^1.1.0" } }, diff --git a/package.json b/package.json index ceb5d2121..c27664182 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "@yext/search-ui-react", - "version": "1.0.0-alpha.301", + "version": "1.0.0", "description": "A library of React Components for powering Yext Search integrations", "author": "slapshot@yext.com", "license": "BSD-3-Clause", @@ -73,7 +73,7 @@ "@typescript-eslint/eslint-plugin": "^5.16.0", "@typescript-eslint/parser": "^5.16.0", "@yext/eslint-config-slapshot": "^0.5.0", - "@yext/search-headless-react": "2.0.0-alpha.158", + "@yext/search-headless-react": "^2.0.0", "axe-playwright": "^1.1.11", "babel-jest": "^27.0.6", "babel-loader": "^8.2.3", @@ -91,7 +91,7 @@ "typescript": "~4.4.3" }, "peerDependencies": { - "@yext/search-headless-react": "2.0.0-alpha.158", + "@yext/search-headless-react": "^2.0.0", "react": "^16.14 || ^17 || ^18" }, "jest": {