@soma-vertical-web/multi-lib 1.0.1 → 1.0.2

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.
package/layout/index.d.ts CHANGED
@@ -331,7 +331,7 @@ export declare const layout: {
331
331
  };
332
332
  LPCadastro: typeof LPCadastro;
333
333
  SearchModal: {
334
- ({ className, trends, CONSTANTS, cmsConfig }: import('../types/layout/templates/SearchModal').SearchModalProps): import("react/jsx-runtime").JSX.Element;
334
+ ({ className, trends, CONSTANTS, SectionZone }: import('../types/layout/templates/SearchModal').SearchModalProps): import("react/jsx-runtime").JSX.Element;
335
335
  displayName: string;
336
336
  };
337
337
  };
@@ -1,3 +1,5 @@
1
- import { SearchContentProps } from '../../../../types/cms/ContentTypes/Search';
1
+ import { SearchModalProps } from '../../../../types/layout/templates/SearchModal';
2
2
 
3
- export default function Recommendations(cmsConfig: SearchContentProps): import("react/jsx-runtime").JSX.Element;
3
+ export default function Recommendations({ SectionZone }: {
4
+ SectionZone: SearchModalProps['SectionZone'];
5
+ }): import("react/jsx-runtime").JSX.Element;
@@ -1,7 +1,7 @@
1
1
  import { SearchModalProps } from '../../../types/layout/templates/SearchModal/index';
2
2
 
3
3
  declare const SearchModal: {
4
- ({ className, trends, CONSTANTS, cmsConfig }: SearchModalProps): import("react/jsx-runtime").JSX.Element;
4
+ ({ className, trends, CONSTANTS, SectionZone }: SearchModalProps): import("react/jsx-runtime").JSX.Element;
5
5
  displayName: string;
6
6
  };
7
7
  export default SearchModal;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@soma-vertical-web/multi-lib",
3
- "version": "1.0.1",
3
+ "version": "1.0.2",
4
4
  "main": "./index.js",
5
5
  "types": "./index.d.ts",
6
6
  "exports": {
package/server.d.ts CHANGED
@@ -31,6 +31,22 @@ declare const serverHelpers: {
31
31
  filterNonCategorySelected: (facets: import('./types/data/api/search/facets').Facet[], base?: string | null) => import('./types/data/api/search/facets').Facet<import('./types/data/api/search/facets').FacetValueBoolean | import('./types/data/api/search/facets').FacetValueRange>[];
32
32
  };
33
33
  product: typeof productHelpers;
34
+ cms: {
35
+ fetchCMS(url: URL, params?: Record<string, unknown>, previewMode?: boolean): Promise<Response>;
36
+ createUrl(contentType: string, params: Record<string, unknown>): string;
37
+ spreadStrapiData<T>(data: T): T | null;
38
+ mergePreviewDocument<T>(contentType: string, documents?: T[], params?: Record<string, unknown>): Promise<any[]>;
39
+ strapiCMSData<T>(url: URL, params?: Record<string, unknown>, spreadData?: boolean): Promise<{
40
+ status: number | string;
41
+ data: T[];
42
+ error?: string;
43
+ }>;
44
+ vtexCMSData<T>(contentType: string, url: URL, params?: Record<string, unknown>): Promise<{
45
+ status: number | string;
46
+ data: T[] | T | null;
47
+ error?: string;
48
+ }>;
49
+ };
34
50
  };
35
51
  declare const serverComponents: {
36
52
  template: {
@@ -2,7 +2,7 @@ import { ComponentType, Dispatch, PropsWithChildren, SetStateAction } from 'reac
2
2
  import { ICONSType, ITEMS_DEFAULT_SORTType, ITEMS_PER_PAGEType, SEARCH_MODALType } from '../../../../types/constants';
3
3
  import { SearchContentProps } from '../../../cms/ContentTypes/Search';
4
4
 
5
- export interface SearchModalProps extends PropsWithChildren {
5
+ export interface SearchModalProps extends PropsWithChildren, Pick<SearchContentProps, 'SectionZone'> {
6
6
  Recommendations?: ComponentType<any>;
7
7
  trends?: boolean;
8
8
  CONSTANTS: {
@@ -11,7 +11,6 @@ export interface SearchModalProps extends PropsWithChildren {
11
11
  ITEMS_PER_PAGE: ITEMS_PER_PAGEType;
12
12
  ITEMS_DEFAULT_SORT: ITEMS_DEFAULT_SORTType;
13
13
  };
14
- cmsConfig?: SearchContentProps;
15
14
  className?: string;
16
15
  }
17
16
  export interface SearchModalHeaderProps {