mirror of
https://github.com/zoriya/v10.git
synced 2026-08-05 05:37:21 +00:00
22 lines
752 B
TypeScript
22 lines
752 B
TypeScript
import { FullscreenButton } from '@videojs/react';
|
|
import { FullscreenEnterIcon, FullscreenExitIcon } from '@videojs/react/icons';
|
|
import styles from './FullscreenButton.module.css';
|
|
|
|
/**
|
|
* Basic FullscreenButton example demonstrating:
|
|
* - Icon switching based on fullscreen state
|
|
* - Data attribute state selectors
|
|
* - Enter/exit fullscreen functionality
|
|
*
|
|
* Note: This component must be used within a VideoProvider context.
|
|
* See the usage example in the documentation.
|
|
*/
|
|
export function BasicFullscreenButton() {
|
|
return (
|
|
<FullscreenButton className={styles.button}>
|
|
<FullscreenEnterIcon className={styles.fullscreenEnterIcon} />
|
|
<FullscreenExitIcon className={styles.fullscreenExitIcon} />
|
|
</FullscreenButton>
|
|
);
|
|
}
|