@coveo/atomic 3.34.0-pre.d9575786e7 → 3.34.0-pre.e32f61aedf
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/dist/atomic/_atomic.esm.js +1 -1
- package/dist/atomic/components/analytics-config.js +1 -1
- package/dist/atomic/components/components/commerce/atomic-product/atomic-product.js +26 -58
- package/dist/atomic/components/components/common/layout/custom-render-controller.js +37 -0
- package/dist/atomic/components/components/common/layout/item-layout-controller.js +103 -0
- package/dist/atomic/components/global/environment.js +1 -1
- package/dist/atomic/{p-f0064e10.entry.js → p-34023eb7.entry.js} +2 -2
- package/dist/atomic/{p-852fbcd4.js → p-81254bbc.js} +2 -2
- package/dist/atomic/{p-4a71315f.entry.js → p-99b26ca1.entry.js} +2 -2
- package/dist/cjs/{analytics-config-c700ceb3.js → analytics-config-0c366536.js} +2 -2
- package/dist/cjs/{analytics-config-c700ceb3.js.map → analytics-config-0c366536.js.map} +1 -1
- package/dist/cjs/atomic-insight-interface.cjs.entry.js +1 -1
- package/dist/cjs/atomic-recs-interface.cjs.entry.js +1 -1
- package/dist/cjs/version.cjs.js +2 -2
- package/dist/esm/{analytics-config-c0ff31a9.js → analytics-config-2f6cc743.js} +2 -2
- package/dist/esm/{analytics-config-c0ff31a9.js.map → analytics-config-2f6cc743.js.map} +1 -1
- package/dist/esm/atomic-insight-interface.entry.js +1 -1
- package/dist/esm/atomic-recs-interface.entry.js +1 -1
- package/dist/esm/version.js +2 -2
- package/dist/types/components/commerce/atomic-product/atomic-product.d.ts +4 -16
- package/dist/types/components/common/layout/custom-render-controller.d.ts +25 -0
- package/dist/types/components/common/layout/item-layout-controller.d.ts +47 -0
- package/docs/atomic-docs.json +1 -1
- package/package.json +7 -7
- /package/dist/atomic/{p-f0064e10.entry.js.map → p-34023eb7.entry.js.map} +0 -0
- /package/dist/atomic/{p-852fbcd4.js.map → p-81254bbc.js.map} +0 -0
- /package/dist/atomic/{p-4a71315f.entry.js.map → p-99b26ca1.entry.js.map} +0 -0
@@ -1,7 +1,7 @@
|
|
1
1
|
import { r as registerInstance, s as setNonce, h, H as Host, g as getElement } from './index-3f35faca.js';
|
2
2
|
import { m as markParentAsReady } from './init-queue-fbe942c3.js';
|
3
3
|
import { buildResultsPerPage, loadFieldActions, buildInsightEngine } from '@coveo/headless/insight';
|
4
|
-
import { g as getNextAnalyticsConfig, a as augmentWithExternalMiddleware, b as augmentAnalyticsWithAtomicVersion, C as CommonAtomicInterfaceHelper, i as instance } from './analytics-config-
|
4
|
+
import { g as getNextAnalyticsConfig, a as augmentWithExternalMiddleware, b as augmentAnalyticsWithAtomicVersion, C as CommonAtomicInterfaceHelper, i as instance } from './analytics-config-2f6cc743.js';
|
5
5
|
import { A as ArrayProp } from './props-utils-e97ad6bd.js';
|
6
6
|
import { D as DEFAULT_MOBILE_BREAKPOINT } from './replace-breakpoint-utils-7a336631.js';
|
7
7
|
import { u as unsetLoadingFlag, s as setLoadingFlag, r as registerFacet, g as getFacetElements, w as waitUntilAppLoaded, a as createBaseStore } from './store-015afa83.js';
|
@@ -1,7 +1,7 @@
|
|
1
1
|
import { r as registerInstance, s as setNonce, h, g as getElement } from './index-3f35faca.js';
|
2
2
|
import { m as markParentAsReady } from './init-queue-fbe942c3.js';
|
3
3
|
import { loadRecommendationActions, loadSearchConfigurationActions, EcommerceDefaultFieldsToInclude, loadFieldActions, buildRecommendationEngine } from '@coveo/headless/recommendation';
|
4
|
-
import { g as getNextAnalyticsConfig, c as augmentAnalyticsConfigWithDocument, d as augmentAnalyticsConfigWithAtomicVersion, a as augmentWithExternalMiddleware, b as augmentAnalyticsWithAtomicVersion, C as CommonAtomicInterfaceHelper, i as instance, m as mismatchedInterfaceAndEnginePropError } from './analytics-config-
|
4
|
+
import { g as getNextAnalyticsConfig, c as augmentAnalyticsConfigWithDocument, d as augmentAnalyticsConfigWithAtomicVersion, a as augmentWithExternalMiddleware, b as augmentAnalyticsWithAtomicVersion, C as CommonAtomicInterfaceHelper, i as instance, m as mismatchedInterfaceAndEnginePropError } from './analytics-config-2f6cc743.js';
|
5
5
|
import { A as ArrayProp } from './props-utils-e97ad6bd.js';
|
6
6
|
import { u as unsetLoadingFlag, s as setLoadingFlag, a as createBaseStore } from './store-015afa83.js';
|
7
7
|
import './dayjs.min-d04628c6.js';
|
package/dist/esm/version.js
CHANGED
@@ -1,2 +1,2 @@
|
|
1
|
-
export const headlessVersion = '3.31.
|
2
|
-
export const atomicVersion = '3.34.0-pre.
|
1
|
+
export const headlessVersion = '3.31.2-pre.e32f61aedf';
|
2
|
+
export const atomicVersion = '3.34.0-pre.e32f61aedf';
|
@@ -1,20 +1,19 @@
|
|
1
1
|
import type { InteractiveProduct, Product } from '@coveo/headless/commerce';
|
2
2
|
import { type CSSResultGroup, LitElement } from 'lit';
|
3
|
+
import type { CommerceStore } from "../atomic-commerce-interface/store";
|
4
|
+
import type { CommerceRecommendationStore } from "../atomic-commerce-recommendation-interface/store";
|
3
5
|
import type { DisplayConfig } from "../../common/item-list/context/item-display-config-context-controller";
|
4
6
|
import { type ItemRenderingFunction } from "../../common/item-list/item-list-common";
|
5
|
-
import {
|
7
|
+
import type { ItemDisplayDensity, ItemDisplayImageSize, ItemDisplayLayout } from "../../common/layout/display-options";
|
6
8
|
import type { InteractiveProductContextEvent, ProductContextEvent } from "../../../decorators/commerce/product-template-decorators";
|
7
|
-
import type { CommerceStore } from '../atomic-commerce-interface/store';
|
8
|
-
import type { CommerceRecommendationStore } from '../atomic-commerce-recommendation-interface/store';
|
9
9
|
declare const AtomicProduct_base: typeof LitElement;
|
10
10
|
/**
|
11
11
|
* The `atomic-product` component is used internally by the `atomic-commerce-product-list` and `atomic-commerce-recommendation-list` components.
|
12
12
|
*/
|
13
13
|
export declare class AtomicProduct extends AtomicProduct_base {
|
14
|
-
private layout;
|
15
14
|
private productRootRef?;
|
16
15
|
private linkContainerRef?;
|
17
|
-
private
|
16
|
+
private itemLayoutController;
|
18
17
|
static styles: CSSResultGroup;
|
19
18
|
/**
|
20
19
|
* Whether `atomic-product-link` components nested in the `atomic-product` should stop click event propagation.
|
@@ -84,25 +83,14 @@ export declare class AtomicProduct extends AtomicProduct_base {
|
|
84
83
|
clickLinkContainer: () => void;
|
85
84
|
connectedCallback(): Promise<void>;
|
86
85
|
disconnectedCallback(): void;
|
87
|
-
private get isCustomRenderFunctionMode();
|
88
86
|
private getContentHTML;
|
89
87
|
private getLinkHTML;
|
90
|
-
private shouldExecuteRenderFunction;
|
91
88
|
render(): import("lit-html").TemplateResult<1>;
|
92
89
|
firstUpdated(_changedProperties: Map<string, unknown>): void;
|
93
|
-
private getCombinedClasses;
|
94
|
-
private applyClassesToChildren;
|
95
|
-
updated(_changedProperties: Map<string, unknown>): void;
|
96
90
|
}
|
97
91
|
declare global {
|
98
92
|
interface HTMLElementTagNameMap {
|
99
93
|
'atomic-product': AtomicProduct;
|
100
94
|
}
|
101
|
-
interface HTMLElementEventMap {
|
102
|
-
'atomic/resolveResult': ProductContextEvent;
|
103
|
-
'atomic/resolveInteractiveResult': InteractiveProductContextEvent;
|
104
|
-
'atomic/resolveStopPropagation': CustomEvent;
|
105
|
-
'atomic/resolveResultDisplayConfig': ProductContextEvent<DisplayConfig>;
|
106
|
-
}
|
107
95
|
}
|
108
96
|
export {};
|
@@ -0,0 +1,25 @@
|
|
1
|
+
import type { LitElement, ReactiveController, ReactiveControllerHost } from 'lit';
|
2
|
+
import type { ItemRenderingFunction } from "../item-list/item-list-common";
|
3
|
+
import type { AnyItem } from "../item-list/unfolded-item";
|
4
|
+
export interface CustomRenderHost extends ReactiveControllerHost {
|
5
|
+
shadowRoot?: ShadowRoot | null;
|
6
|
+
}
|
7
|
+
export interface CustomRenderOptions {
|
8
|
+
renderingFunction: () => ItemRenderingFunction<AnyItem> | undefined;
|
9
|
+
itemData: () => AnyItem | undefined;
|
10
|
+
rootElementRef: () => HTMLElement | undefined;
|
11
|
+
linkContainerRef?: () => HTMLElement | undefined;
|
12
|
+
onRenderComplete?: (element: HTMLElement, output: string) => void;
|
13
|
+
}
|
14
|
+
/**
|
15
|
+
* A reactive controller that manages custom rendering function execution for item components.
|
16
|
+
*/
|
17
|
+
export declare class CustomRenderController implements ReactiveController {
|
18
|
+
private options;
|
19
|
+
private hasExecutedRenderFunction;
|
20
|
+
constructor(host: CustomRenderHost & LitElement, options: CustomRenderOptions);
|
21
|
+
hostConnected(): void;
|
22
|
+
hostUpdated(): void;
|
23
|
+
private resetRenderState;
|
24
|
+
private executeRenderFunction;
|
25
|
+
}
|
@@ -0,0 +1,47 @@
|
|
1
|
+
import type { LitElement, ReactiveController, ReactiveControllerHost } from 'lit';
|
2
|
+
import type { ItemRenderingFunction } from "../item-list/item-list-common";
|
3
|
+
import type { AnyItem } from "../item-list/unfolded-item";
|
4
|
+
import { type ItemDisplayDensity, type ItemDisplayImageSize, type ItemDisplayLayout, ItemLayout } from './display-options';
|
5
|
+
export interface ItemLayoutHost extends ReactiveControllerHost {
|
6
|
+
shadowRoot?: ShadowRoot | null;
|
7
|
+
}
|
8
|
+
export interface LayoutDisplayConfig {
|
9
|
+
display: ItemDisplayLayout;
|
10
|
+
density: ItemDisplayDensity;
|
11
|
+
imageSize: ItemDisplayImageSize;
|
12
|
+
}
|
13
|
+
export interface ItemLayoutOptions {
|
14
|
+
elementPrefix: string;
|
15
|
+
renderingFunction: () => ItemRenderingFunction<AnyItem> | undefined;
|
16
|
+
content: () => ParentNode | undefined;
|
17
|
+
layoutConfig: () => LayoutDisplayConfig;
|
18
|
+
itemClasses: () => string;
|
19
|
+
}
|
20
|
+
/**
|
21
|
+
* A reactive controller that manages layout creation and class application for item components.
|
22
|
+
*/
|
23
|
+
export declare class ItemLayoutController implements ReactiveController {
|
24
|
+
private host;
|
25
|
+
private options;
|
26
|
+
private layoutInstance;
|
27
|
+
constructor(host: ItemLayoutHost & LitElement, options: ItemLayoutOptions);
|
28
|
+
hostConnected(): void;
|
29
|
+
hostUpdated(): void;
|
30
|
+
/**
|
31
|
+
* Gets the current layout instance
|
32
|
+
*/
|
33
|
+
getLayout(): ItemLayout | null;
|
34
|
+
/**
|
35
|
+
* Gets combined layout and extra classes
|
36
|
+
*/
|
37
|
+
getCombinedClasses(additionalContent?: string): string[];
|
38
|
+
/**
|
39
|
+
* Applies layout classes to a specific element (useful for custom rendering)
|
40
|
+
*/
|
41
|
+
applyLayoutClassesToElement(element: HTMLElement, additionalContent?: string): void;
|
42
|
+
private applyLayoutClasses;
|
43
|
+
private createLayout;
|
44
|
+
private hasCustomRenderFunction;
|
45
|
+
private addClassesToElements;
|
46
|
+
private observeAndApplyClasses;
|
47
|
+
}
|
package/docs/atomic-docs.json
CHANGED
package/package.json
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
{
|
2
2
|
"name": "@coveo/atomic",
|
3
3
|
"type": "module",
|
4
|
-
"version": "3.34.0-pre.
|
4
|
+
"version": "3.34.0-pre.e32f61aedf",
|
5
5
|
"description": "A web-component library for building modern UIs interfacing with the Coveo platform",
|
6
6
|
"homepage": "https://docs.coveo.com/en/atomic/latest/",
|
7
7
|
"repository": {
|
@@ -47,10 +47,10 @@
|
|
47
47
|
"licenses/"
|
48
48
|
],
|
49
49
|
"scripts": {
|
50
|
-
"clean": "
|
50
|
+
"clean": "node ../../utils/ci/rm-rf.mjs dist/* dist-storybook/* www/* docs/* playwright-report/*",
|
51
51
|
"build:storybook": "storybook build -o dist-storybook",
|
52
52
|
"build:cem": "cem analyze",
|
53
|
-
"build:stencil-lit": "node --max_old_space_size=6144 ../../node_modules/@stencil/core/bin/stencil build --tsConfig tsconfig.stencil.json && node ./scripts/stencil-proxy.mjs && node ./scripts/build.mjs --config=tsconfig.lit.json && esbuild src/autoloader/index.ts --format=esm --outfile=dist/atomic/autoloader/index.esm.js && esbuild src/autoloader/index.ts --format=cjs --outfile=dist/atomic/autoloader/index.cjs.js && rollup -c rollup.config.js &&
|
53
|
+
"build:stencil-lit": "node --max_old_space_size=6144 ../../node_modules/@stencil/core/bin/stencil build --tsConfig tsconfig.stencil.json && node ./scripts/stencil-proxy.mjs && node ./scripts/build.mjs --config=tsconfig.lit.json && esbuild src/autoloader/index.ts --format=esm --outfile=dist/atomic/autoloader/index.esm.js && esbuild src/autoloader/index.ts --format=cjs --outfile=dist/atomic/autoloader/index.cjs.js && rollup -c rollup.config.js && node ../../utils/ci/rm-rf.mjs ./dist/atomic/loader/package.json && tsc --noEmit --esModuleInterop --skipLibCheck ./dist/types/components.d.ts",
|
54
54
|
"build:angular": "npx turbo gen:lit --filter=@coveo/atomic-angular-builder",
|
55
55
|
"build:react": "npx turbo gen:lit --filter=@coveo/atomic-react",
|
56
56
|
"build:locales": "node ./scripts/create-generated-folder.mjs && node ./scripts/split-locales.mjs && node ./scripts/copy-dayjs-locales.mjs",
|
@@ -80,8 +80,8 @@
|
|
80
80
|
"validate:definitions": "tsc --noEmit --esModuleInterop --skipLibCheck ./dist/types/components.d.ts"
|
81
81
|
},
|
82
82
|
"dependencies": {
|
83
|
-
"@coveo/bueno": "1.1.
|
84
|
-
"@coveo/headless": "3.31.
|
83
|
+
"@coveo/bueno": "1.1.3-pre.e32f61aedf",
|
84
|
+
"@coveo/headless": "3.31.2-pre.e32f61aedf",
|
85
85
|
"@lit/context": "1.1.6",
|
86
86
|
"@open-wc/lit-helpers": "0.7.0",
|
87
87
|
"@popperjs/core": "2.11.8",
|
@@ -152,8 +152,8 @@
|
|
152
152
|
"wait-on": "8.0.4"
|
153
153
|
},
|
154
154
|
"peerDependencies": {
|
155
|
-
"@coveo/bueno": "1.1.
|
156
|
-
"@coveo/headless": "3.31.
|
155
|
+
"@coveo/bueno": "1.1.3-pre.e32f61aedf",
|
156
|
+
"@coveo/headless": "3.31.2-pre.e32f61aedf",
|
157
157
|
"typescript": ">=5.0.0"
|
158
158
|
},
|
159
159
|
"peerDependenciesMeta": {
|
File without changes
|
File without changes
|
File without changes
|