projects/storefrontlib/cms-components/navigation/search-box/search-box.events.ts
Indicates that the user chose a product suggestion
Properties |
|
| freeText |
Type : string
|
| productCode |
Type : string
|
| Static Readonly type |
Type : string
|
Default value : 'SearchBoxProductSelectedEvent'
|
|
Inherited from
CxEvent
|
|
Defined in
CxEvent:23
|
|
Event's type |
import { CxEvent, Suggestion } from '@spartacus/core';
/**
* Indicates that the user chose a suggestion
*/
export class SearchBoxSuggestionSelectedEvent extends CxEvent {
/**
* Event's type
*/
static readonly type = 'SearchBoxSuggestionSelectedEvent';
freeText: string;
selectedSuggestion: string;
searchSuggestions: Suggestion[];
}
/**
* Indicates that the user chose a product suggestion
*/
export class SearchBoxProductSelectedEvent extends CxEvent {
/**
* Event's type
*/
static readonly type = 'SearchBoxProductSelectedEvent';
freeText: string;
productCode: string;
}