@coveo/quantic 3.30.6-pre.409ea88fd6 → 3.30.6-pre.8a8d443d40
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/force-app/main/default/staticresources/coveoheadless/case-assist/headless.js +8 -8
- package/force-app/main/default/staticresources/coveoheadless/definitions/controllers/insight/attach-to-case/headless-attach-to-case.d.ts +2 -0
- package/force-app/main/default/staticresources/coveoheadless/definitions/controllers/insight/attached-results/headless-attached-results.d.ts +58 -0
- package/force-app/main/default/staticresources/coveoheadless/definitions/features/generated-answer/generated-answer-actions.d.ts +0 -1
- package/force-app/main/default/staticresources/coveoheadless/definitions/features/generated-answer/generated-answer-state.d.ts +0 -2
- package/force-app/main/default/staticresources/coveoheadless/definitions/insight.index.d.ts +2 -0
- package/force-app/main/default/staticresources/coveoheadless/headless.js +10 -10
- package/force-app/main/default/staticresources/coveoheadless/insight/headless.js +9 -9
- package/force-app/main/default/staticresources/coveoheadless/recommendation/headless.js +7 -7
- package/package.json +2 -2
|
@@ -23,6 +23,7 @@ export interface AttachToCaseOptions {
|
|
|
23
23
|
*
|
|
24
24
|
* @group Controllers
|
|
25
25
|
* @category AttachToCase
|
|
26
|
+
* @deprecated Use `buildAttachedResults` instead. This controller will be removed in ui-kit v4.
|
|
26
27
|
*/
|
|
27
28
|
export interface AttachToCase extends Controller {
|
|
28
29
|
/**
|
|
@@ -50,5 +51,6 @@ export interface AttachToCase extends Controller {
|
|
|
50
51
|
*
|
|
51
52
|
* @group Controllers
|
|
52
53
|
* @category AttachToCase
|
|
54
|
+
* @deprecated Use `buildAttachedResults` instead. This controller will be removed in ui-kit v4.
|
|
53
55
|
*/
|
|
54
56
|
export declare function buildAttachToCase(engine: InsightEngine, props: AttachToCaseProps): AttachToCase;
|
|
@@ -0,0 +1,58 @@
|
|
|
1
|
+
import type { Result } from '../../../api/search/search/result.js';
|
|
2
|
+
import type { InsightEngine } from '../../../app/insight-engine/insight-engine.js';
|
|
3
|
+
import type { AttachedResult } from '../../../features/attached-results/attached-results-state.js';
|
|
4
|
+
import { type Controller } from '../../controller/headless-controller.js';
|
|
5
|
+
export interface AttachedResultsProps {
|
|
6
|
+
/**
|
|
7
|
+
* The options for the `AttachedResults` controller.
|
|
8
|
+
*/
|
|
9
|
+
options: AttachedResultsOptions;
|
|
10
|
+
}
|
|
11
|
+
export interface AttachedResultsOptions {
|
|
12
|
+
/**
|
|
13
|
+
* The Id of the record to attach to.
|
|
14
|
+
*/
|
|
15
|
+
recordId: string;
|
|
16
|
+
}
|
|
17
|
+
/**
|
|
18
|
+
* The AttachedResults controller manages all attached results for a given record.
|
|
19
|
+
* It provides a unified API to attach/detach results, check attachment status,
|
|
20
|
+
* and access all attached results for the record.
|
|
21
|
+
*
|
|
22
|
+
* @group Controllers
|
|
23
|
+
* @category AttachedResults
|
|
24
|
+
*/
|
|
25
|
+
export interface AttachedResults extends Controller {
|
|
26
|
+
/**
|
|
27
|
+
* Check if a specific result is attached to this record.
|
|
28
|
+
* @param result - The result to check if attached, with SearchAPI fields
|
|
29
|
+
* @returns A boolean indicating if the result is attached.
|
|
30
|
+
*/
|
|
31
|
+
isAttached(result: Result): boolean;
|
|
32
|
+
/**
|
|
33
|
+
* Attach a new result by adding it to the attachedResults state.
|
|
34
|
+
* @param result - A result to add to the list of currently attached results.
|
|
35
|
+
*/
|
|
36
|
+
attach(result: Result): void;
|
|
37
|
+
/**
|
|
38
|
+
* Detach a result by removing it from the attachedResults state.
|
|
39
|
+
* @param result - A result to remove from the list of currently attached results.
|
|
40
|
+
*/
|
|
41
|
+
detach(result: Result): void;
|
|
42
|
+
/**
|
|
43
|
+
* The state of the `AttachedResults` controller.
|
|
44
|
+
* Returns all attached results for this record.
|
|
45
|
+
*/
|
|
46
|
+
state: AttachedResult[];
|
|
47
|
+
}
|
|
48
|
+
/**
|
|
49
|
+
* Creates an AttachedResults controller instance.
|
|
50
|
+
*
|
|
51
|
+
* @param engine - The headless engine.
|
|
52
|
+
* @param props - The configurable `AttachedResults` properties.
|
|
53
|
+
* @returns A `AttachedResults` controller instance.
|
|
54
|
+
*
|
|
55
|
+
* @group Controllers
|
|
56
|
+
* @category AttachedResults
|
|
57
|
+
*/
|
|
58
|
+
export declare function buildAttachedResults(engine: InsightEngine, props: AttachedResultsProps): AttachedResults;
|
|
@@ -10,7 +10,6 @@ export interface GeneratedAnswerErrorPayload {
|
|
|
10
10
|
code?: number;
|
|
11
11
|
}
|
|
12
12
|
export declare const setIsVisible: import("@reduxjs/toolkit").ActionCreatorWithPreparedPayload<[payload: boolean], boolean, "generatedAnswer/setIsVisible", never, never>;
|
|
13
|
-
export declare const setAnswerId: import("@reduxjs/toolkit").ActionCreatorWithPreparedPayload<[payload: string], string, "generatedAnswer/setAnswerId", never, never>;
|
|
14
13
|
export declare const setIsEnabled: import("@reduxjs/toolkit").ActionCreatorWithPreparedPayload<[payload: boolean], boolean, "generatedAnswer/setIsEnabled", never, never>;
|
|
15
14
|
export declare const updateMessage: import("@reduxjs/toolkit").ActionCreatorWithPreparedPayload<[payload: GeneratedAnswerMessagePayload], GeneratedAnswerMessagePayload, "generatedAnswer/updateMessage", never, never>;
|
|
16
15
|
export declare const updateCitations: import("@reduxjs/toolkit").ActionCreatorWithPreparedPayload<[payload: GeneratedAnswerCitationsPayload], GeneratedAnswerCitationsPayload, "generatedAnswer/updateCitations", never, never>;
|
|
@@ -91,7 +91,5 @@ export interface GeneratedAnswerState {
|
|
|
91
91
|
* The query parameters used for the answer API request cache key
|
|
92
92
|
*/
|
|
93
93
|
answerApiQueryParams?: AnswerApiQueryParams;
|
|
94
|
-
/** The unique identifier of the answer returned by the Answer API. */
|
|
95
|
-
answerId?: string;
|
|
96
94
|
}
|
|
97
95
|
export declare function getGeneratedAnswerInitialState(): GeneratedAnswerState;
|
|
@@ -29,6 +29,8 @@ export type { Controller, Subscribable, } from './controllers/controller/headles
|
|
|
29
29
|
export { buildController } from './controllers/controller/headless-controller.js';
|
|
30
30
|
export type { AttachToCase, AttachToCaseOptions, AttachToCaseProps, } from './controllers/insight/attach-to-case/headless-attach-to-case.js';
|
|
31
31
|
export { buildAttachToCase } from './controllers/insight/attach-to-case/headless-attach-to-case.js';
|
|
32
|
+
export type { AttachedResults, AttachedResultsOptions, AttachedResultsProps, } from './controllers/insight/attached-results/headless-attached-results.js';
|
|
33
|
+
export { buildAttachedResults } from './controllers/insight/attached-results/headless-attached-results.js';
|
|
32
34
|
export type { Breadcrumb, BreadcrumbManager, BreadcrumbManagerState, BreadcrumbValue, CategoryFacetBreadcrumb, DateFacetBreadcrumb, DeselectableValue, FacetBreadcrumb, NumericFacetBreadcrumb, StaticFilterBreadcrumb, } from './controllers/insight/breadcrumb-manager/headless-insight-breadcrumb-manager.js';
|
|
33
35
|
export { buildBreadcrumbManager } from './controllers/insight/breadcrumb-manager/headless-insight-breadcrumb-manager.js';
|
|
34
36
|
export type { DidYouMean, DidYouMeanOptions, DidYouMeanProps, DidYouMeanState, QueryCorrection, WordCorrection, } from './controllers/insight/did-you-mean/headless-insight-did-you-mean.js';
|