UNPKG

@ebay/ebayui-core

Version:

Collection of core eBay components; considered to be the building blocks for all composite structures, pages & apps.

39 lines (38 loc) 1.12 kB
import type { AttrClass, AttrString } from "marko/tags-html"; import type { WithNormalizedProps } from "../../global"; interface ViewerInput { "cdn-url"?: string; version?: string; class?: AttrClass; "a11y-text"?: AttrString; src?: string; "error-text"?: AttrString; "a11y-start-text"?: AttrString; "a11y-load-text"?: AttrString; poster?: string; loading?: "auto" | "lazy" | "eager"; reveal?: "auto" | "manual"; "with-credentials"?: boolean; "on-load-error"?: (err: CustomEvent) => void; "on-load"?: () => void; "on-progress"?: () => void; "on-model-visibility"?: () => void; "on-poster-dismissed"?: () => void; "on-render-scale"?: () => void; } export interface Input extends WithNormalizedProps<ViewerInput> { } interface State { showLoading: boolean; isLoaded: boolean; failed: boolean; } declare class Viewer extends Marko.Component<Input, State> { viewer: HTMLElement; handleError(err: Error): void; onCreate(): void; handleSuccess(): void; onMount(): void; _loadViewer(): void; } export default Viewer;