UNPKG

vidstack

Version:

Build awesome media experiences on the web.

64 lines (63 loc) 2.52 kB
import { ComponentInstance, type HTMLCustomElement } from 'maverick.js/element'; import { type MediaContext } from '../../core/api/context'; import type { TextTrack } from '../../core/tracks/text/text-track'; import { Thumbnail } from '../thumbnail'; import { MenuItems, type MenuItemsAPI } from './menu-items'; import { Radio } from './radio/radio'; import { RadioGroup, type RadioGroupChangeEvent } from './radio/radio-group'; declare global { interface MaverickElements { 'media-chapters-menu-items': MediaChaptersMenuItemsElement; } } /** * This component displays media chapters inside of a menu. * * @docs {@link https://www.vidstack.io/docs/player/components/menu/chapters-menu} * @example * ```html * <media-menu> * <media-menu-button aria-label="Chapters"> * <media-icon type="chapters"></media-icon> * </media-menu-button> * <media-chapters-menu-items></media-chapters-menu-items> * </media-menu> * ``` */ export declare class ChaptersMenuItems extends MenuItems<ChaptersMenuItemsAPI> { static el: import("maverick.js/element").CustomElementDefinition<ChaptersMenuItemsAPI>; static register: (typeof Radio | typeof RadioGroup | typeof Thumbnail)[]; protected _media: MediaContext; protected _index: import("maverick.js").WriteSignal<number>; protected _track: import("maverick.js").WriteSignal<TextTrack | null>; constructor(instance: ComponentInstance<ChaptersMenuItemsAPI>); protected onAttach(el: any): void; protected _onOpen(): void; protected onConnect(el: HTMLElement): void; protected _hasThumbnails(): boolean; protected _watchCurrentTime(): void; protected _watchControllerDisabled(): void; protected _isDisabled(): boolean; protected _onChange(event: RadioGroupChangeEvent): void; protected _onTrackModeChange(): void; protected _getValue(): string; protected _getOptions(): { value: string; content: () => import("maverick.js").JSX.Element; }[]; render(): import("maverick.js").JSX.Element; } export interface ChaptersMenuItemsAPI extends MenuItemsAPI { props: ChapterMenuItemsProps; } export interface ChapterMenuItemsProps { containerClass: string | null; chapterClass: string | null; thumbnailClass: string | null; contentClass: string | null; titleClass: string | null; startTimeClass: string | null; durationClass: string | null; } export interface MediaChaptersMenuItemsElement extends HTMLCustomElement<ChaptersMenuItems> { }