ranui
Version:
A framework-agnostic Web Components UI library built on native custom elements, with TypeScript types, light/dark theming, SSR and PWA support.
16 lines (15 loc) • 836 B
TypeScript
/**
* Transient, self-dismissing message on `.ran-player-gesture-flash` — the
* show/hide-with-timer logic `core/gestures.ts`'s double-tap seek indicator
* already needed, extracted so a second caller (the remote-playback-failure
* notice in `core/chrome.ts`) doesn't hand-roll its own copy of the same
* three lines. Position is caller-supplied via `className` (one of the
* `ran-player-gesture-flash-{left,right,center}` modifiers in `index.less`)
* since different callers anchor the message differently — seek flashes sit
* over the half of the video that was tapped, a general notice sits centered.
*/
export interface FlashController {
show: (text: string, className?: string) => void;
destroy: () => void;
}
export declare function createFlashController(el: HTMLElement, visibleMs: number): FlashController;