import { baseUniDriverFactory } from '../../utils/test-utils/unidriver';
export function FloatingScrollBarUniDriver(base, _body) {
    const getStyle = async (el) => {
        const style = await el.attr('style');
        return (style ?? '').split(';').reduce((acc, prop) => {
            const [key = '', value = ''] = prop.split(':');
            acc[key.trim()] = value.trim();
            return acc;
        }, {});
    };
    return {
        ...baseUniDriverFactory(base),
        getScrollContainerTopPosition: async () => (await getStyle(base)).top,
        getScrollContainerWidth: async () => (await getStyle(base)).width,
        getScrollContainerLeftPosition: async () => (await getStyle(base)).left,
        getScrollContainerVisibility: async () => (await getStyle(base)).visibility,
        getScrollContainerScrollWidth: async () => (await getStyle(base.$('[data-hook="floating-scroll-bar-content"]')))
            .width,
    };
}
//# sourceMappingURL=FloatingScrollBar.uni.driver.js.map