Merge pull request #10644 from keymanapp/chore/web/remove-unused-banner-events

chore(web): removes unused banner events
This commit is contained in:
Joshua Horton 2024-02-07 13:26:54 +07:00 committed by GitHub
commit dcba2da22d
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
2 changed files with 0 additions and 13 deletions

View file

@ -81,7 +81,6 @@ export class BannerController {
} else {
let suggestBanner = banner = new SuggestionBanner(this.hostDevice, this.container.activeBannerHeight);
suggestBanner.predictionContext = this.predictionContext;
suggestBanner.events.on('apply', (selection) => this.predictionContext.accept(selection.suggestion));
// Registers for prediction-engine events & handles its needed connections.
this.container.banner = suggestBanner;

View file

@ -384,8 +384,6 @@ export class SuggestionBanner extends Banner {
public readonly type = "suggestion";
public readonly events: EventEmitter<SuggestionInputEventMap>;
private currentSuggestions: Suggestion[] = [];
private options : BannerSuggestion[] = [];
@ -418,8 +416,6 @@ export class SuggestionBanner extends Banner {
this.getDiv().appendChild(this.container);
this.buildInternals(false);
this.events = new EventEmitter<SuggestionInputEventMap>(); //this.manager.events;
this.gestureEngine = this.setupInputHandling();
}
@ -781,14 +777,6 @@ export class SuggestionBanner extends Banner {
}
}
interface SuggestionInputEventMap {
highlight: (bannerSuggestion: BannerSuggestion, state: boolean) => void,
apply: (bannerSuggestion: BannerSuggestion) => void;
hold: (bannerSuggestion: BannerSuggestion) => void;
scrollLeft: (val: number) => void;
}
class SuggestionExpandContractAnimation {
private scrollContainer: HTMLElement | null;
private option: BannerSuggestion;