import React, { createContext, useContext, useState, } from 'react';
class FloatingScrollBarContextValue {
    constructor() {
        this.viewportRef = undefined;
        this.scrollableContentRef = {
            current: null,
        };
        this.scrollElementRef = {
            current: null,
        };
        this.floatingScrollBarStateRef = {
            current: null,
        };
    }
}
export const FloatingScrollBarContext = createContext(new FloatingScrollBarContextValue());
export const useFloatingScrollBarContext = () => useContext(FloatingScrollBarContext);
export function FloatingScrollBarContextProvider({ children, scrollableContentRef, viewportRef, scrollElementRef, }) {
    const [value] = useState(() => new FloatingScrollBarContextValue());
    value.viewportRef = viewportRef;
    value.scrollableContentRef = scrollableContentRef;
    value.scrollElementRef = scrollElementRef;
    return (React.createElement(FloatingScrollBarContext.Provider, { value: value }, children));
}
//# sourceMappingURL=FloatingScrollBarContext.js.map