@faststore/components 3.98.0-dev.0 → 3.98.0-dev.3

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (28) hide show
  1. package/dist/cjs/molecules/SearchProducts/SearchProductItem.d.ts +1 -1
  2. package/dist/cjs/molecules/SearchProducts/SearchProductItem.d.ts.map +1 -1
  3. package/dist/cjs/molecules/SearchProducts/SearchProductItem.js +2 -2
  4. package/dist/cjs/molecules/SearchProducts/SearchProductItem.js.map +1 -1
  5. package/dist/cjs/molecules/SearchProvider/SearchProvider.d.ts +5 -1
  6. package/dist/cjs/molecules/SearchProvider/SearchProvider.d.ts.map +1 -1
  7. package/dist/cjs/molecules/SearchProvider/SearchProvider.js +2 -2
  8. package/dist/cjs/molecules/SearchProvider/SearchProvider.js.map +1 -1
  9. package/dist/cjs/organisms/SearchInput/SearchInput.d.ts +8 -0
  10. package/dist/cjs/organisms/SearchInput/SearchInput.d.ts.map +1 -1
  11. package/dist/cjs/organisms/SearchInput/SearchInput.js +2 -2
  12. package/dist/cjs/organisms/SearchInput/SearchInput.js.map +1 -1
  13. package/dist/esm/molecules/SearchProducts/SearchProductItem.d.ts +1 -1
  14. package/dist/esm/molecules/SearchProducts/SearchProductItem.d.ts.map +1 -1
  15. package/dist/esm/molecules/SearchProducts/SearchProductItem.js +2 -2
  16. package/dist/esm/molecules/SearchProducts/SearchProductItem.js.map +1 -1
  17. package/dist/esm/molecules/SearchProvider/SearchProvider.d.ts +5 -1
  18. package/dist/esm/molecules/SearchProvider/SearchProvider.d.ts.map +1 -1
  19. package/dist/esm/molecules/SearchProvider/SearchProvider.js +2 -2
  20. package/dist/esm/molecules/SearchProvider/SearchProvider.js.map +1 -1
  21. package/dist/esm/organisms/SearchInput/SearchInput.d.ts +8 -0
  22. package/dist/esm/organisms/SearchInput/SearchInput.d.ts.map +1 -1
  23. package/dist/esm/organisms/SearchInput/SearchInput.js +2 -2
  24. package/dist/esm/organisms/SearchInput/SearchInput.js.map +1 -1
  25. package/package.json +2 -2
  26. package/src/molecules/SearchProducts/SearchProductItem.tsx +8 -3
  27. package/src/molecules/SearchProvider/SearchProvider.tsx +6 -1
  28. package/src/organisms/SearchInput/SearchInput.tsx +6 -0
@@ -1,7 +1,7 @@
1
1
  import type { HTMLAttributes } from 'react';
2
2
  import React from 'react';
3
3
  import { type LinkElementType, type LinkProps } from '../..';
4
- export interface SearchProductItemProps extends HTMLAttributes<HTMLDivElement> {
4
+ export interface SearchProductItemProps extends HTMLAttributes<HTMLLIElement> {
5
5
  /**
6
6
  * ID to find this component in testing tools (e.g.: cypress,
7
7
  * testing-library, and jest).
@@ -1 +1 @@
1
- {"version":3,"file":"SearchProductItem.d.ts","sourceRoot":"","sources":["../../../../src/molecules/SearchProducts/SearchProductItem.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,OAAO,CAAA;AAC3C,OAAO,KAAqB,MAAM,OAAO,CAAA;AAEzC,OAAO,EAAQ,KAAK,eAAe,EAAE,KAAK,SAAS,EAAE,MAAM,OAAO,CAAA;AAElE,MAAM,WAAW,sBAAuB,SAAQ,cAAc,CAAC,cAAc,CAAC;IAC5E;;;OAGG;IACH,MAAM,CAAC,EAAE,MAAM,CAAA;IACf;;OAEG;IACH,SAAS,CAAC,EAAE,OAAO,CAAC,SAAS,CAAC,eAAe,CAAC,CAAC,CAAA;CAChD;AAED,QAAA,MAAM,iBAAiB,8FAatB,CAAA;AAED,eAAe,iBAAiB,CAAA"}
1
+ {"version":3,"file":"SearchProductItem.d.ts","sourceRoot":"","sources":["../../../../src/molecules/SearchProducts/SearchProductItem.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,OAAO,CAAA;AAC3C,OAAO,KAAqB,MAAM,OAAO,CAAA;AAEzC,OAAO,EAAQ,KAAK,eAAe,EAAE,KAAK,SAAS,EAAE,MAAM,OAAO,CAAA;AAElE,MAAM,WAAW,sBAAuB,SAAQ,cAAc,CAAC,aAAa,CAAC;IAC3E;;;OAGG;IACH,MAAM,CAAC,EAAE,MAAM,CAAA;IACf;;OAEG;IACH,SAAS,CAAC,EAAE,OAAO,CAAC,SAAS,CAAC,eAAe,CAAC,CAAC,CAAA;CAChD;AAED,QAAA,MAAM,iBAAiB,8FAkBtB,CAAA;AAED,eAAe,iBAAiB,CAAA"}
@@ -3,8 +3,8 @@ Object.defineProperty(exports, "__esModule", { value: true });
3
3
  const tslib_1 = require("tslib");
4
4
  const react_1 = tslib_1.__importStar(require("react"));
5
5
  const __1 = require("../..");
6
- const SearchProductItem = (0, react_1.forwardRef)(function ProductItem({ testId = 'fs-search-product-item', linkProps, children }, ref) {
7
- return (react_1.default.createElement("li", { ref: ref, "data-fs-search-product-item": true, "data-testid": testId },
6
+ const SearchProductItem = (0, react_1.forwardRef)(function ProductItem({ testId = 'fs-search-product-item', linkProps, children, ...otherProps }, ref) {
7
+ return (react_1.default.createElement("li", { ref: ref, "data-fs-search-product-item": true, "data-testid": testId, ...otherProps },
8
8
  react_1.default.createElement(__1.Link, { ...linkProps, "data-fs-search-product-item-link": true, variant: "display" }, children)));
9
9
  });
10
10
  exports.default = SearchProductItem;
@@ -1 +1 @@
1
- {"version":3,"file":"SearchProductItem.js","sourceRoot":"","sources":["../../../../src/molecules/SearchProducts/SearchProductItem.tsx"],"names":[],"mappings":";;;AACA,uDAAyC;AAEzC,6BAAkE;AAclE,MAAM,iBAAiB,GAAG,IAAA,kBAAU,EAClC,SAAS,WAAW,CAClB,EAAE,MAAM,GAAG,wBAAwB,EAAE,SAAS,EAAE,QAAQ,EAAE,EAC1D,GAAG;IAEH,OAAO,CACL,sCAAI,GAAG,EAAE,GAAG,sDAA2C,MAAM;QAC3D,8BAAC,QAAI,OAAK,SAAS,4CAAmC,OAAO,EAAC,SAAS,IACpE,QAAQ,CACJ,CACJ,CACN,CAAA;AACH,CAAC,CACF,CAAA;AAED,kBAAe,iBAAiB,CAAA"}
1
+ {"version":3,"file":"SearchProductItem.js","sourceRoot":"","sources":["../../../../src/molecules/SearchProducts/SearchProductItem.tsx"],"names":[],"mappings":";;;AACA,uDAAyC;AAEzC,6BAAkE;AAclE,MAAM,iBAAiB,GAAG,IAAA,kBAAU,EAClC,SAAS,WAAW,CAClB,EAAE,MAAM,GAAG,wBAAwB,EAAE,SAAS,EAAE,QAAQ,EAAE,GAAG,UAAU,EAAE,EACzE,GAAG;IAEH,OAAO,CACL,sCACE,GAAG,EAAE,GAAG,sDAEK,MAAM,KACf,UAAU;QAEd,8BAAC,QAAI,OAAK,SAAS,4CAAmC,OAAO,EAAC,SAAS,IACpE,QAAQ,CACJ,CACJ,CACN,CAAA;AACH,CAAC,CACF,CAAA;AAED,kBAAe,iBAAiB,CAAA"}
@@ -23,8 +23,12 @@ export interface SearchProviderContextValue {
23
23
  * Callback function when a search term is selected.
24
24
  */
25
25
  onSearchSelection?: (term: string, path: string) => void;
26
+ /**
27
+ * Search result searchId.
28
+ */
29
+ searchId?: string;
26
30
  }
27
31
  export declare const SearchContext: React.Context<SearchProviderContextValue | null>;
28
- declare function SearchProvider({ onSearchSelection, children, term, terms, products, isLoading, }: PropsWithChildren<SearchProviderContextValue>): React.JSX.Element;
32
+ declare function SearchProvider({ onSearchSelection, children, term, terms, products, isLoading, searchId, }: PropsWithChildren<SearchProviderContextValue>): React.JSX.Element;
29
33
  export default SearchProvider;
30
34
  //# sourceMappingURL=SearchProvider.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"SearchProvider.d.ts","sourceRoot":"","sources":["../../../../src/molecules/SearchProvider/SearchProvider.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,MAAM,OAAO,CAAA;AACzB,OAAO,KAAK,EAAE,iBAAiB,EAAE,MAAM,OAAO,CAAA;AAG9C,MAAM,WAAW,0BAA0B;IACzC;;OAEG;IACH,IAAI,EAAE,MAAM,CAAA;IACZ;;OAEG;IACH,SAAS,EAAE,OAAO,CAAA;IAClB;;OAEG;IACH,KAAK,EAAE,KAAK,CAAC;QAAE,KAAK,EAAE,MAAM,CAAA;KAAE,CAAC,CAAA;IAC/B;;OAEG;IACH,QAAQ,EAAE,EAAE,EAAE,CAAA;IACd;;OAEG;IACH,iBAAiB,CAAC,EAAE,CAAC,IAAI,EAAE,MAAM,EAAE,IAAI,EAAE,MAAM,KAAK,IAAI,CAAA;CACzD;AAED,eAAO,MAAM,aAAa,kDAEzB,CAAA;AAED,iBAAS,cAAc,CAAC,EACtB,iBAAiB,EACjB,QAAQ,EACR,IAAI,EACJ,KAAK,EACL,QAAQ,EACR,SAAS,GACV,EAAE,iBAAiB,CAAC,0BAA0B,CAAC,qBAQ/C;AAED,eAAe,cAAc,CAAA"}
1
+ {"version":3,"file":"SearchProvider.d.ts","sourceRoot":"","sources":["../../../../src/molecules/SearchProvider/SearchProvider.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,MAAM,OAAO,CAAA;AACzB,OAAO,KAAK,EAAE,iBAAiB,EAAE,MAAM,OAAO,CAAA;AAG9C,MAAM,WAAW,0BAA0B;IACzC;;OAEG;IACH,IAAI,EAAE,MAAM,CAAA;IACZ;;OAEG;IACH,SAAS,EAAE,OAAO,CAAA;IAClB;;OAEG;IACH,KAAK,EAAE,KAAK,CAAC;QAAE,KAAK,EAAE,MAAM,CAAA;KAAE,CAAC,CAAA;IAC/B;;OAEG;IACH,QAAQ,EAAE,EAAE,EAAE,CAAA;IACd;;OAEG;IACH,iBAAiB,CAAC,EAAE,CAAC,IAAI,EAAE,MAAM,EAAE,IAAI,EAAE,MAAM,KAAK,IAAI,CAAA;IACxD;;OAEG;IACH,QAAQ,CAAC,EAAE,MAAM,CAAA;CAClB;AAED,eAAO,MAAM,aAAa,kDAEzB,CAAA;AAED,iBAAS,cAAc,CAAC,EACtB,iBAAiB,EACjB,QAAQ,EACR,IAAI,EACJ,KAAK,EACL,QAAQ,EACR,SAAS,EACT,QAAQ,GACT,EAAE,iBAAiB,CAAC,0BAA0B,CAAC,qBAQ/C;AAED,eAAe,cAAc,CAAA"}
@@ -5,8 +5,8 @@ const tslib_1 = require("tslib");
5
5
  const react_1 = tslib_1.__importDefault(require("react"));
6
6
  const react_2 = require("react");
7
7
  exports.SearchContext = (0, react_2.createContext)(null);
8
- function SearchProvider({ onSearchSelection, children, term, terms, products, isLoading, }) {
9
- return (react_1.default.createElement(exports.SearchContext.Provider, { value: { onSearchSelection, term, terms, products, isLoading } }, children));
8
+ function SearchProvider({ onSearchSelection, children, term, terms, products, isLoading, searchId, }) {
9
+ return (react_1.default.createElement(exports.SearchContext.Provider, { value: { onSearchSelection, term, terms, products, isLoading, searchId } }, children));
10
10
  }
11
11
  exports.default = SearchProvider;
12
12
  //# sourceMappingURL=SearchProvider.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"SearchProvider.js","sourceRoot":"","sources":["../../../../src/molecules/SearchProvider/SearchProvider.tsx"],"names":[],"mappings":";;;;AAAA,0DAAyB;AAEzB,iCAAqC;AAyBxB,QAAA,aAAa,GAAG,IAAA,qBAAa,EACxC,IAAI,CACL,CAAA;AAED,SAAS,cAAc,CAAC,EACtB,iBAAiB,EACjB,QAAQ,EACR,IAAI,EACJ,KAAK,EACL,QAAQ,EACR,SAAS,GACqC;IAC9C,OAAO,CACL,8BAAC,qBAAa,CAAC,QAAQ,IACrB,KAAK,EAAE,EAAE,iBAAiB,EAAE,IAAI,EAAE,KAAK,EAAE,QAAQ,EAAE,SAAS,EAAE,IAE7D,QAAQ,CACc,CAC1B,CAAA;AACH,CAAC;AAED,kBAAe,cAAc,CAAA"}
1
+ {"version":3,"file":"SearchProvider.js","sourceRoot":"","sources":["../../../../src/molecules/SearchProvider/SearchProvider.tsx"],"names":[],"mappings":";;;;AAAA,0DAAyB;AAEzB,iCAAqC;AA6BxB,QAAA,aAAa,GAAG,IAAA,qBAAa,EACxC,IAAI,CACL,CAAA;AAED,SAAS,cAAc,CAAC,EACtB,iBAAiB,EACjB,QAAQ,EACR,IAAI,EACJ,KAAK,EACL,QAAQ,EACR,SAAS,EACT,QAAQ,GACsC;IAC9C,OAAO,CACL,8BAAC,qBAAa,CAAC,QAAQ,IACrB,KAAK,EAAE,EAAE,iBAAiB,EAAE,IAAI,EAAE,KAAK,EAAE,QAAQ,EAAE,SAAS,EAAE,QAAQ,EAAE,IAEvE,QAAQ,CACc,CAC1B,CAAA;AACH,CAAC;AAED,kBAAe,cAAc,CAAA"}
@@ -11,6 +11,10 @@ export type SearchInputProps = {
11
11
  * The current status of the Search Dropdown.
12
12
  */
13
13
  visibleDropdown: boolean;
14
+ /**
15
+ * Search result searchId.
16
+ */
17
+ searchId?: string;
14
18
  } & HTMLAttributes<HTMLDivElement> & SearchProviderContextValue;
15
19
  declare const SearchInput: React.ForwardRefExoticComponent<{
16
20
  /**
@@ -22,6 +26,10 @@ declare const SearchInput: React.ForwardRefExoticComponent<{
22
26
  * The current status of the Search Dropdown.
23
27
  */
24
28
  visibleDropdown: boolean;
29
+ /**
30
+ * Search result searchId.
31
+ */
32
+ searchId?: string | undefined;
25
33
  } & React.HTMLAttributes<HTMLDivElement> & SearchProviderContextValue & React.RefAttributes<HTMLDivElement>>;
26
34
  export default SearchInput;
27
35
  //# sourceMappingURL=SearchInput.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"SearchInput.d.ts","sourceRoot":"","sources":["../../../../src/organisms/SearchInput/SearchInput.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAqB,MAAM,OAAO,CAAA;AACzC,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,OAAO,CAAA;AAC3C,OAAuB,EACrB,KAAK,0BAA0B,EAChC,MAAM,gCAAgC,CAAA;AAEvC,MAAM,MAAM,gBAAgB,GAAG;IAC7B;;;OAGG;IACH,MAAM,CAAC,EAAE,MAAM,CAAA;IACf;;OAEG;IACH,eAAe,EAAE,OAAO,CAAA;CACzB,GAAG,cAAc,CAAC,cAAc,CAAC,GAChC,0BAA0B,CAAA;AAE5B,QAAA,MAAM,WAAW;IAZf;;;OAGG;;IAEH;;OAEG;qBACc,OAAO;4GAuCzB,CAAA;AAED,eAAe,WAAW,CAAA"}
1
+ {"version":3,"file":"SearchInput.d.ts","sourceRoot":"","sources":["../../../../src/organisms/SearchInput/SearchInput.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAqB,MAAM,OAAO,CAAA;AACzC,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,OAAO,CAAA;AAC3C,OAAuB,EACrB,KAAK,0BAA0B,EAChC,MAAM,gCAAgC,CAAA;AAEvC,MAAM,MAAM,gBAAgB,GAAG;IAC7B;;;OAGG;IACH,MAAM,CAAC,EAAE,MAAM,CAAA;IACf;;OAEG;IACH,eAAe,EAAE,OAAO,CAAA;IACxB;;OAEG;IACH,QAAQ,CAAC,EAAE,MAAM,CAAA;CAClB,GAAG,cAAc,CAAC,cAAc,CAAC,GAChC,0BAA0B,CAAA;AAE5B,QAAA,MAAM,WAAW;IAhBf;;;OAGG;;IAEH;;OAEG;qBACc,OAAO;IACxB;;OAEG;;4GA0CJ,CAAA;AAED,eAAe,WAAW,CAAA"}
@@ -3,9 +3,9 @@ Object.defineProperty(exports, "__esModule", { value: true });
3
3
  const tslib_1 = require("tslib");
4
4
  const react_1 = tslib_1.__importStar(require("react"));
5
5
  const SearchProvider_1 = tslib_1.__importDefault(require("../../molecules/SearchProvider"));
6
- const SearchInput = (0, react_1.forwardRef)(function SearchInput({ children, visibleDropdown = false, testId = 'fs-search-input', isLoading, products, term, terms, onSearchSelection, ...otherProps }, ref) {
6
+ const SearchInput = (0, react_1.forwardRef)(function SearchInput({ children, visibleDropdown = false, testId = 'fs-search-input', isLoading, products, term, terms, onSearchSelection, searchId, ...otherProps }, ref) {
7
7
  return (react_1.default.createElement("div", { ref: ref, "data-fs-search-input": true, "data-fs-search-input-dropdown-visible": visibleDropdown, "data-testid": testId, ...otherProps },
8
- react_1.default.createElement(SearchProvider_1.default, { onSearchSelection: onSearchSelection, isLoading: isLoading, term: term, products: products, terms: terms }, children)));
8
+ react_1.default.createElement(SearchProvider_1.default, { onSearchSelection: onSearchSelection, isLoading: isLoading, term: term, products: products, terms: terms, searchId: searchId }, children)));
9
9
  });
10
10
  exports.default = SearchInput;
11
11
  //# sourceMappingURL=SearchInput.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"SearchInput.js","sourceRoot":"","sources":["../../../../src/organisms/SearchInput/SearchInput.tsx"],"names":[],"mappings":";;;AAAA,uDAAyC;AAEzC,4FAEuC;AAevC,MAAM,WAAW,GAAG,IAAA,kBAAU,EAC5B,SAAS,WAAW,CAClB,EACE,QAAQ,EACR,eAAe,GAAG,KAAK,EACvB,MAAM,GAAG,iBAAiB,EAC1B,SAAS,EACT,QAAQ,EACR,IAAI,EACJ,KAAK,EACL,iBAAiB,EACjB,GAAG,UAAU,EACd,EACD,GAAG;IAEH,OAAO,CACL,uCACE,GAAG,EAAE,GAAG,yEAE+B,eAAe,iBACzC,MAAM,KACf,UAAU;QAEd,8BAAC,wBAAc,IACb,iBAAiB,EAAE,iBAAiB,EACpC,SAAS,EAAE,SAAS,EACpB,IAAI,EAAE,IAAI,EACV,QAAQ,EAAE,QAAQ,EAClB,KAAK,EAAE,KAAK,IAEX,QAAQ,CACM,CACb,CACP,CAAA;AACH,CAAC,CACF,CAAA;AAED,kBAAe,WAAW,CAAA"}
1
+ {"version":3,"file":"SearchInput.js","sourceRoot":"","sources":["../../../../src/organisms/SearchInput/SearchInput.tsx"],"names":[],"mappings":";;;AAAA,uDAAyC;AAEzC,4FAEuC;AAmBvC,MAAM,WAAW,GAAG,IAAA,kBAAU,EAC5B,SAAS,WAAW,CAClB,EACE,QAAQ,EACR,eAAe,GAAG,KAAK,EACvB,MAAM,GAAG,iBAAiB,EAC1B,SAAS,EACT,QAAQ,EACR,IAAI,EACJ,KAAK,EACL,iBAAiB,EACjB,QAAQ,EACR,GAAG,UAAU,EACd,EACD,GAAG;IAEH,OAAO,CACL,uCACE,GAAG,EAAE,GAAG,yEAE+B,eAAe,iBACzC,MAAM,KACf,UAAU;QAEd,8BAAC,wBAAc,IACb,iBAAiB,EAAE,iBAAiB,EACpC,SAAS,EAAE,SAAS,EACpB,IAAI,EAAE,IAAI,EACV,QAAQ,EAAE,QAAQ,EAClB,KAAK,EAAE,KAAK,EACZ,QAAQ,EAAE,QAAQ,IAEjB,QAAQ,CACM,CACb,CACP,CAAA;AACH,CAAC,CACF,CAAA;AAED,kBAAe,WAAW,CAAA"}
@@ -1,7 +1,7 @@
1
1
  import type { HTMLAttributes } from 'react';
2
2
  import React from 'react';
3
3
  import { type LinkElementType, type LinkProps } from '../..';
4
- export interface SearchProductItemProps extends HTMLAttributes<HTMLDivElement> {
4
+ export interface SearchProductItemProps extends HTMLAttributes<HTMLLIElement> {
5
5
  /**
6
6
  * ID to find this component in testing tools (e.g.: cypress,
7
7
  * testing-library, and jest).
@@ -1 +1 @@
1
- {"version":3,"file":"SearchProductItem.d.ts","sourceRoot":"","sources":["../../../../src/molecules/SearchProducts/SearchProductItem.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,OAAO,CAAA;AAC3C,OAAO,KAAqB,MAAM,OAAO,CAAA;AAEzC,OAAO,EAAQ,KAAK,eAAe,EAAE,KAAK,SAAS,EAAE,MAAM,OAAO,CAAA;AAElE,MAAM,WAAW,sBAAuB,SAAQ,cAAc,CAAC,cAAc,CAAC;IAC5E;;;OAGG;IACH,MAAM,CAAC,EAAE,MAAM,CAAA;IACf;;OAEG;IACH,SAAS,CAAC,EAAE,OAAO,CAAC,SAAS,CAAC,eAAe,CAAC,CAAC,CAAA;CAChD;AAED,QAAA,MAAM,iBAAiB,8FAatB,CAAA;AAED,eAAe,iBAAiB,CAAA"}
1
+ {"version":3,"file":"SearchProductItem.d.ts","sourceRoot":"","sources":["../../../../src/molecules/SearchProducts/SearchProductItem.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,OAAO,CAAA;AAC3C,OAAO,KAAqB,MAAM,OAAO,CAAA;AAEzC,OAAO,EAAQ,KAAK,eAAe,EAAE,KAAK,SAAS,EAAE,MAAM,OAAO,CAAA;AAElE,MAAM,WAAW,sBAAuB,SAAQ,cAAc,CAAC,aAAa,CAAC;IAC3E;;;OAGG;IACH,MAAM,CAAC,EAAE,MAAM,CAAA;IACf;;OAEG;IACH,SAAS,CAAC,EAAE,OAAO,CAAC,SAAS,CAAC,eAAe,CAAC,CAAC,CAAA;CAChD;AAED,QAAA,MAAM,iBAAiB,8FAkBtB,CAAA;AAED,eAAe,iBAAiB,CAAA"}
@@ -1,7 +1,7 @@
1
1
  import React, { forwardRef } from 'react';
2
2
  import { Link } from '../..';
3
- const SearchProductItem = forwardRef(function ProductItem({ testId = 'fs-search-product-item', linkProps, children }, ref) {
4
- return (React.createElement("li", { ref: ref, "data-fs-search-product-item": true, "data-testid": testId },
3
+ const SearchProductItem = forwardRef(function ProductItem({ testId = 'fs-search-product-item', linkProps, children, ...otherProps }, ref) {
4
+ return (React.createElement("li", { ref: ref, "data-fs-search-product-item": true, "data-testid": testId, ...otherProps },
5
5
  React.createElement(Link, { ...linkProps, "data-fs-search-product-item-link": true, variant: "display" }, children)));
6
6
  });
7
7
  export default SearchProductItem;
@@ -1 +1 @@
1
- {"version":3,"file":"SearchProductItem.js","sourceRoot":"","sources":["../../../../src/molecules/SearchProducts/SearchProductItem.tsx"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAE,EAAE,UAAU,EAAE,MAAM,OAAO,CAAA;AAEzC,OAAO,EAAE,IAAI,EAAwC,MAAM,OAAO,CAAA;AAclE,MAAM,iBAAiB,GAAG,UAAU,CAClC,SAAS,WAAW,CAClB,EAAE,MAAM,GAAG,wBAAwB,EAAE,SAAS,EAAE,QAAQ,EAAE,EAC1D,GAAG;IAEH,OAAO,CACL,4BAAI,GAAG,EAAE,GAAG,sDAA2C,MAAM;QAC3D,oBAAC,IAAI,OAAK,SAAS,4CAAmC,OAAO,EAAC,SAAS,IACpE,QAAQ,CACJ,CACJ,CACN,CAAA;AACH,CAAC,CACF,CAAA;AAED,eAAe,iBAAiB,CAAA"}
1
+ {"version":3,"file":"SearchProductItem.js","sourceRoot":"","sources":["../../../../src/molecules/SearchProducts/SearchProductItem.tsx"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAE,EAAE,UAAU,EAAE,MAAM,OAAO,CAAA;AAEzC,OAAO,EAAE,IAAI,EAAwC,MAAM,OAAO,CAAA;AAclE,MAAM,iBAAiB,GAAG,UAAU,CAClC,SAAS,WAAW,CAClB,EAAE,MAAM,GAAG,wBAAwB,EAAE,SAAS,EAAE,QAAQ,EAAE,GAAG,UAAU,EAAE,EACzE,GAAG;IAEH,OAAO,CACL,4BACE,GAAG,EAAE,GAAG,sDAEK,MAAM,KACf,UAAU;QAEd,oBAAC,IAAI,OAAK,SAAS,4CAAmC,OAAO,EAAC,SAAS,IACpE,QAAQ,CACJ,CACJ,CACN,CAAA;AACH,CAAC,CACF,CAAA;AAED,eAAe,iBAAiB,CAAA"}
@@ -23,8 +23,12 @@ export interface SearchProviderContextValue {
23
23
  * Callback function when a search term is selected.
24
24
  */
25
25
  onSearchSelection?: (term: string, path: string) => void;
26
+ /**
27
+ * Search result searchId.
28
+ */
29
+ searchId?: string;
26
30
  }
27
31
  export declare const SearchContext: React.Context<SearchProviderContextValue | null>;
28
- declare function SearchProvider({ onSearchSelection, children, term, terms, products, isLoading, }: PropsWithChildren<SearchProviderContextValue>): React.JSX.Element;
32
+ declare function SearchProvider({ onSearchSelection, children, term, terms, products, isLoading, searchId, }: PropsWithChildren<SearchProviderContextValue>): React.JSX.Element;
29
33
  export default SearchProvider;
30
34
  //# sourceMappingURL=SearchProvider.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"SearchProvider.d.ts","sourceRoot":"","sources":["../../../../src/molecules/SearchProvider/SearchProvider.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,MAAM,OAAO,CAAA;AACzB,OAAO,KAAK,EAAE,iBAAiB,EAAE,MAAM,OAAO,CAAA;AAG9C,MAAM,WAAW,0BAA0B;IACzC;;OAEG;IACH,IAAI,EAAE,MAAM,CAAA;IACZ;;OAEG;IACH,SAAS,EAAE,OAAO,CAAA;IAClB;;OAEG;IACH,KAAK,EAAE,KAAK,CAAC;QAAE,KAAK,EAAE,MAAM,CAAA;KAAE,CAAC,CAAA;IAC/B;;OAEG;IACH,QAAQ,EAAE,EAAE,EAAE,CAAA;IACd;;OAEG;IACH,iBAAiB,CAAC,EAAE,CAAC,IAAI,EAAE,MAAM,EAAE,IAAI,EAAE,MAAM,KAAK,IAAI,CAAA;CACzD;AAED,eAAO,MAAM,aAAa,kDAEzB,CAAA;AAED,iBAAS,cAAc,CAAC,EACtB,iBAAiB,EACjB,QAAQ,EACR,IAAI,EACJ,KAAK,EACL,QAAQ,EACR,SAAS,GACV,EAAE,iBAAiB,CAAC,0BAA0B,CAAC,qBAQ/C;AAED,eAAe,cAAc,CAAA"}
1
+ {"version":3,"file":"SearchProvider.d.ts","sourceRoot":"","sources":["../../../../src/molecules/SearchProvider/SearchProvider.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,MAAM,OAAO,CAAA;AACzB,OAAO,KAAK,EAAE,iBAAiB,EAAE,MAAM,OAAO,CAAA;AAG9C,MAAM,WAAW,0BAA0B;IACzC;;OAEG;IACH,IAAI,EAAE,MAAM,CAAA;IACZ;;OAEG;IACH,SAAS,EAAE,OAAO,CAAA;IAClB;;OAEG;IACH,KAAK,EAAE,KAAK,CAAC;QAAE,KAAK,EAAE,MAAM,CAAA;KAAE,CAAC,CAAA;IAC/B;;OAEG;IACH,QAAQ,EAAE,EAAE,EAAE,CAAA;IACd;;OAEG;IACH,iBAAiB,CAAC,EAAE,CAAC,IAAI,EAAE,MAAM,EAAE,IAAI,EAAE,MAAM,KAAK,IAAI,CAAA;IACxD;;OAEG;IACH,QAAQ,CAAC,EAAE,MAAM,CAAA;CAClB;AAED,eAAO,MAAM,aAAa,kDAEzB,CAAA;AAED,iBAAS,cAAc,CAAC,EACtB,iBAAiB,EACjB,QAAQ,EACR,IAAI,EACJ,KAAK,EACL,QAAQ,EACR,SAAS,EACT,QAAQ,GACT,EAAE,iBAAiB,CAAC,0BAA0B,CAAC,qBAQ/C;AAED,eAAe,cAAc,CAAA"}
@@ -1,8 +1,8 @@
1
1
  import React from 'react';
2
2
  import { createContext } from 'react';
3
3
  export const SearchContext = createContext(null);
4
- function SearchProvider({ onSearchSelection, children, term, terms, products, isLoading, }) {
5
- return (React.createElement(SearchContext.Provider, { value: { onSearchSelection, term, terms, products, isLoading } }, children));
4
+ function SearchProvider({ onSearchSelection, children, term, terms, products, isLoading, searchId, }) {
5
+ return (React.createElement(SearchContext.Provider, { value: { onSearchSelection, term, terms, products, isLoading, searchId } }, children));
6
6
  }
7
7
  export default SearchProvider;
8
8
  //# sourceMappingURL=SearchProvider.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"SearchProvider.js","sourceRoot":"","sources":["../../../../src/molecules/SearchProvider/SearchProvider.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,MAAM,OAAO,CAAA;AAEzB,OAAO,EAAE,aAAa,EAAE,MAAM,OAAO,CAAA;AAyBrC,MAAM,CAAC,MAAM,aAAa,GAAG,aAAa,CACxC,IAAI,CACL,CAAA;AAED,SAAS,cAAc,CAAC,EACtB,iBAAiB,EACjB,QAAQ,EACR,IAAI,EACJ,KAAK,EACL,QAAQ,EACR,SAAS,GACqC;IAC9C,OAAO,CACL,oBAAC,aAAa,CAAC,QAAQ,IACrB,KAAK,EAAE,EAAE,iBAAiB,EAAE,IAAI,EAAE,KAAK,EAAE,QAAQ,EAAE,SAAS,EAAE,IAE7D,QAAQ,CACc,CAC1B,CAAA;AACH,CAAC;AAED,eAAe,cAAc,CAAA"}
1
+ {"version":3,"file":"SearchProvider.js","sourceRoot":"","sources":["../../../../src/molecules/SearchProvider/SearchProvider.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,MAAM,OAAO,CAAA;AAEzB,OAAO,EAAE,aAAa,EAAE,MAAM,OAAO,CAAA;AA6BrC,MAAM,CAAC,MAAM,aAAa,GAAG,aAAa,CACxC,IAAI,CACL,CAAA;AAED,SAAS,cAAc,CAAC,EACtB,iBAAiB,EACjB,QAAQ,EACR,IAAI,EACJ,KAAK,EACL,QAAQ,EACR,SAAS,EACT,QAAQ,GACsC;IAC9C,OAAO,CACL,oBAAC,aAAa,CAAC,QAAQ,IACrB,KAAK,EAAE,EAAE,iBAAiB,EAAE,IAAI,EAAE,KAAK,EAAE,QAAQ,EAAE,SAAS,EAAE,QAAQ,EAAE,IAEvE,QAAQ,CACc,CAC1B,CAAA;AACH,CAAC;AAED,eAAe,cAAc,CAAA"}
@@ -11,6 +11,10 @@ export type SearchInputProps = {
11
11
  * The current status of the Search Dropdown.
12
12
  */
13
13
  visibleDropdown: boolean;
14
+ /**
15
+ * Search result searchId.
16
+ */
17
+ searchId?: string;
14
18
  } & HTMLAttributes<HTMLDivElement> & SearchProviderContextValue;
15
19
  declare const SearchInput: React.ForwardRefExoticComponent<{
16
20
  /**
@@ -22,6 +26,10 @@ declare const SearchInput: React.ForwardRefExoticComponent<{
22
26
  * The current status of the Search Dropdown.
23
27
  */
24
28
  visibleDropdown: boolean;
29
+ /**
30
+ * Search result searchId.
31
+ */
32
+ searchId?: string | undefined;
25
33
  } & React.HTMLAttributes<HTMLDivElement> & SearchProviderContextValue & React.RefAttributes<HTMLDivElement>>;
26
34
  export default SearchInput;
27
35
  //# sourceMappingURL=SearchInput.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"SearchInput.d.ts","sourceRoot":"","sources":["../../../../src/organisms/SearchInput/SearchInput.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAqB,MAAM,OAAO,CAAA;AACzC,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,OAAO,CAAA;AAC3C,OAAuB,EACrB,KAAK,0BAA0B,EAChC,MAAM,gCAAgC,CAAA;AAEvC,MAAM,MAAM,gBAAgB,GAAG;IAC7B;;;OAGG;IACH,MAAM,CAAC,EAAE,MAAM,CAAA;IACf;;OAEG;IACH,eAAe,EAAE,OAAO,CAAA;CACzB,GAAG,cAAc,CAAC,cAAc,CAAC,GAChC,0BAA0B,CAAA;AAE5B,QAAA,MAAM,WAAW;IAZf;;;OAGG;;IAEH;;OAEG;qBACc,OAAO;4GAuCzB,CAAA;AAED,eAAe,WAAW,CAAA"}
1
+ {"version":3,"file":"SearchInput.d.ts","sourceRoot":"","sources":["../../../../src/organisms/SearchInput/SearchInput.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAqB,MAAM,OAAO,CAAA;AACzC,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,OAAO,CAAA;AAC3C,OAAuB,EACrB,KAAK,0BAA0B,EAChC,MAAM,gCAAgC,CAAA;AAEvC,MAAM,MAAM,gBAAgB,GAAG;IAC7B;;;OAGG;IACH,MAAM,CAAC,EAAE,MAAM,CAAA;IACf;;OAEG;IACH,eAAe,EAAE,OAAO,CAAA;IACxB;;OAEG;IACH,QAAQ,CAAC,EAAE,MAAM,CAAA;CAClB,GAAG,cAAc,CAAC,cAAc,CAAC,GAChC,0BAA0B,CAAA;AAE5B,QAAA,MAAM,WAAW;IAhBf;;;OAGG;;IAEH;;OAEG;qBACc,OAAO;IACxB;;OAEG;;4GA0CJ,CAAA;AAED,eAAe,WAAW,CAAA"}
@@ -1,8 +1,8 @@
1
1
  import React, { forwardRef } from 'react';
2
2
  import SearchProvider from '../../molecules/SearchProvider';
3
- const SearchInput = forwardRef(function SearchInput({ children, visibleDropdown = false, testId = 'fs-search-input', isLoading, products, term, terms, onSearchSelection, ...otherProps }, ref) {
3
+ const SearchInput = forwardRef(function SearchInput({ children, visibleDropdown = false, testId = 'fs-search-input', isLoading, products, term, terms, onSearchSelection, searchId, ...otherProps }, ref) {
4
4
  return (React.createElement("div", { ref: ref, "data-fs-search-input": true, "data-fs-search-input-dropdown-visible": visibleDropdown, "data-testid": testId, ...otherProps },
5
- React.createElement(SearchProvider, { onSearchSelection: onSearchSelection, isLoading: isLoading, term: term, products: products, terms: terms }, children)));
5
+ React.createElement(SearchProvider, { onSearchSelection: onSearchSelection, isLoading: isLoading, term: term, products: products, terms: terms, searchId: searchId }, children)));
6
6
  });
7
7
  export default SearchInput;
8
8
  //# sourceMappingURL=SearchInput.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"SearchInput.js","sourceRoot":"","sources":["../../../../src/organisms/SearchInput/SearchInput.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,EAAE,UAAU,EAAE,MAAM,OAAO,CAAA;AAEzC,OAAO,cAEN,MAAM,gCAAgC,CAAA;AAevC,MAAM,WAAW,GAAG,UAAU,CAC5B,SAAS,WAAW,CAClB,EACE,QAAQ,EACR,eAAe,GAAG,KAAK,EACvB,MAAM,GAAG,iBAAiB,EAC1B,SAAS,EACT,QAAQ,EACR,IAAI,EACJ,KAAK,EACL,iBAAiB,EACjB,GAAG,UAAU,EACd,EACD,GAAG;IAEH,OAAO,CACL,6BACE,GAAG,EAAE,GAAG,yEAE+B,eAAe,iBACzC,MAAM,KACf,UAAU;QAEd,oBAAC,cAAc,IACb,iBAAiB,EAAE,iBAAiB,EACpC,SAAS,EAAE,SAAS,EACpB,IAAI,EAAE,IAAI,EACV,QAAQ,EAAE,QAAQ,EAClB,KAAK,EAAE,KAAK,IAEX,QAAQ,CACM,CACb,CACP,CAAA;AACH,CAAC,CACF,CAAA;AAED,eAAe,WAAW,CAAA"}
1
+ {"version":3,"file":"SearchInput.js","sourceRoot":"","sources":["../../../../src/organisms/SearchInput/SearchInput.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,EAAE,UAAU,EAAE,MAAM,OAAO,CAAA;AAEzC,OAAO,cAEN,MAAM,gCAAgC,CAAA;AAmBvC,MAAM,WAAW,GAAG,UAAU,CAC5B,SAAS,WAAW,CAClB,EACE,QAAQ,EACR,eAAe,GAAG,KAAK,EACvB,MAAM,GAAG,iBAAiB,EAC1B,SAAS,EACT,QAAQ,EACR,IAAI,EACJ,KAAK,EACL,iBAAiB,EACjB,QAAQ,EACR,GAAG,UAAU,EACd,EACD,GAAG;IAEH,OAAO,CACL,6BACE,GAAG,EAAE,GAAG,yEAE+B,eAAe,iBACzC,MAAM,KACf,UAAU;QAEd,oBAAC,cAAc,IACb,iBAAiB,EAAE,iBAAiB,EACpC,SAAS,EAAE,SAAS,EACpB,IAAI,EAAE,IAAI,EACV,QAAQ,EAAE,QAAQ,EAClB,KAAK,EAAE,KAAK,EACZ,QAAQ,EAAE,QAAQ,IAEjB,QAAQ,CACM,CACb,CACP,CAAA;AACH,CAAC,CACF,CAAA;AAED,eAAe,WAAW,CAAA"}
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@faststore/components",
3
- "version": "3.98.0-dev.0",
3
+ "version": "3.98.0-dev.3",
4
4
  "main": "dist/cjs/index.js",
5
5
  "module": "dist/esm/index.js",
6
6
  "typings": "dist/esm/index.d.ts",
@@ -59,5 +59,5 @@
59
59
  "publishConfig": {
60
60
  "access": "public"
61
61
  },
62
- "gitHead": "489781e3714743d7bede2ba23cf243fd1e5d81e4"
62
+ "gitHead": "c6e0f65660673a92f9de733b7502551ef755e86c"
63
63
  }
@@ -3,7 +3,7 @@ import React, { forwardRef } from 'react'
3
3
 
4
4
  import { Link, type LinkElementType, type LinkProps } from '../..'
5
5
 
6
- export interface SearchProductItemProps extends HTMLAttributes<HTMLDivElement> {
6
+ export interface SearchProductItemProps extends HTMLAttributes<HTMLLIElement> {
7
7
  /**
8
8
  * ID to find this component in testing tools (e.g.: cypress,
9
9
  * testing-library, and jest).
@@ -17,11 +17,16 @@ export interface SearchProductItemProps extends HTMLAttributes<HTMLDivElement> {
17
17
 
18
18
  const SearchProductItem = forwardRef<HTMLLIElement, SearchProductItemProps>(
19
19
  function ProductItem(
20
- { testId = 'fs-search-product-item', linkProps, children },
20
+ { testId = 'fs-search-product-item', linkProps, children, ...otherProps },
21
21
  ref
22
22
  ) {
23
23
  return (
24
- <li ref={ref} data-fs-search-product-item data-testid={testId}>
24
+ <li
25
+ ref={ref}
26
+ data-fs-search-product-item
27
+ data-testid={testId}
28
+ {...otherProps}
29
+ >
25
30
  <Link {...linkProps} data-fs-search-product-item-link variant="display">
26
31
  {children}
27
32
  </Link>
@@ -23,6 +23,10 @@ export interface SearchProviderContextValue {
23
23
  * Callback function when a search term is selected.
24
24
  */
25
25
  onSearchSelection?: (term: string, path: string) => void
26
+ /**
27
+ * Search result searchId.
28
+ */
29
+ searchId?: string
26
30
  }
27
31
 
28
32
  export const SearchContext = createContext<SearchProviderContextValue | null>(
@@ -36,10 +40,11 @@ function SearchProvider({
36
40
  terms,
37
41
  products,
38
42
  isLoading,
43
+ searchId,
39
44
  }: PropsWithChildren<SearchProviderContextValue>) {
40
45
  return (
41
46
  <SearchContext.Provider
42
- value={{ onSearchSelection, term, terms, products, isLoading }}
47
+ value={{ onSearchSelection, term, terms, products, isLoading, searchId }}
43
48
  >
44
49
  {children}
45
50
  </SearchContext.Provider>
@@ -14,6 +14,10 @@ export type SearchInputProps = {
14
14
  * The current status of the Search Dropdown.
15
15
  */
16
16
  visibleDropdown: boolean
17
+ /**
18
+ * Search result searchId.
19
+ */
20
+ searchId?: string
17
21
  } & HTMLAttributes<HTMLDivElement> &
18
22
  SearchProviderContextValue
19
23
 
@@ -28,6 +32,7 @@ const SearchInput = forwardRef<HTMLDivElement, SearchInputProps>(
28
32
  term,
29
33
  terms,
30
34
  onSearchSelection,
35
+ searchId,
31
36
  ...otherProps
32
37
  },
33
38
  ref
@@ -46,6 +51,7 @@ const SearchInput = forwardRef<HTMLDivElement, SearchInputProps>(
46
51
  term={term}
47
52
  products={products}
48
53
  terms={terms}
54
+ searchId={searchId}
49
55
  >
50
56
  {children}
51
57
  </SearchProvider>