mirror of
https://github.com/zoriya/v10.git
synced 2026-08-16 02:45:09 +00:00
feat(packages): add UI support for gestures and hotkeys (#1388)
Co-authored-by: Rahim <rahim.alwer@gmail.com> Co-authored-by: Claude Opus 4.6 <noreply@anthropic.com>
This commit is contained in:
co-authored by
Rahim
Claude Opus 4.6
parent
6c81f2d190
commit
0620814a67
@@ -2,7 +2,7 @@
|
||||
|
||||
import type { SliderState, StateAttrMap } from '@videojs/core';
|
||||
import type { SliderThumbProps } from '@videojs/core/dom';
|
||||
import type { RefCallback } from 'react';
|
||||
import type { ProviderProps, RefCallback } from 'react';
|
||||
import { createContext, useContext } from 'react';
|
||||
|
||||
export interface SliderContextValue {
|
||||
@@ -18,7 +18,9 @@ export interface SliderContextValue {
|
||||
|
||||
const SliderContext = createContext<SliderContextValue | null>(null);
|
||||
|
||||
export function SliderProvider({ value, children }: { value: SliderContextValue; children: React.ReactNode }) {
|
||||
type SliderProviderProps = ProviderProps<SliderContextValue>;
|
||||
|
||||
export function SliderProvider({ value, children }: SliderProviderProps) {
|
||||
return <SliderContext.Provider value={value}>{children}</SliderContext.Provider>;
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user