Skip to content

Commit

Permalink
chore(atomic): replace HTMLStencilElement with HTMLElement (#4835)
Browse files Browse the repository at this point in the history
`HTMLStencilElement` is not used anywhere in the codebase. It's simply a
type enhancer over HTMLElement.
Since we migrate to Lit, there is no point in keeping that type

https://coveord.atlassian.net/browse/KIT-3827

---------

Co-authored-by: GitHub Actions Bot <>
  • Loading branch information
y-lakhdar committed Jan 14, 2025
1 parent 7876a24 commit 32294c1
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 5 deletions.
5 changes: 2 additions & 3 deletions packages/atomic/src/components/common/interface/bindings.ts
Original file line number Diff line number Diff line change
@@ -1,7 +1,6 @@
import type {SearchEngine} from '@coveo/headless';
import {CommerceEngine} from '@coveo/headless/commerce';
import type {RecommendationEngine} from '@coveo/headless/recommendation';
import {HTMLStencilElement} from '@stencil/core/internal';
import {i18n} from 'i18next';
import {InsightEngine} from '../../insight';
import {AtomicCommonStore, AtomicCommonStoreData} from './store';
Expand Down Expand Up @@ -30,7 +29,7 @@ export interface CommonStencilStore<StoreData extends AtomicCommonStoreData> {
export interface CommonBindings<
Engine extends AnyEngineType,
Store extends AtomicCommonStore<AtomicCommonStoreData>,
InterfaceElement extends HTMLStencilElement,
InterfaceElement extends HTMLElement,
> {
/**
* A headless engine instance.
Expand Down Expand Up @@ -68,7 +67,7 @@ export interface NonceBindings {
export type AnyBindings = CommonBindings<
AnyEngineType,
AtomicCommonStore<AtomicCommonStoreData>,
HTMLStencilElement
HTMLElement
>;

export type AnyEngineType =
Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,5 @@
import {LogLevel} from '@coveo/headless';
import {ComponentInterface, h} from '@stencil/core';
import {HTMLStencilElement} from '@stencil/core/internal';
import {i18n, TFunction} from 'i18next';
import Backend from 'i18next-http-backend';
import {setCoveoGlobal} from '../../../global/environment';
Expand All @@ -23,7 +22,7 @@ export interface BaseAtomicInterface<EngineType extends AnyEngineType>
iconAssetsPath: string;
logLevel?: LogLevel;
language?: string;
host: HTMLStencilElement;
host: HTMLElement;
bindings: AnyBindings;
error?: Error;

Expand Down

0 comments on commit 32294c1

Please sign in to comment.