import React, { useMemo } from 'react';
import { Box, Text } from '@wix/design-system';
import { observer } from 'mobx-react-lite';
function _GridSectionHeader({ sectionTitle, suffix, state, }) {
    const { minimizedHeaderHeight, toolbarRect: { rect: { height: toolbarHeight }, }, internalScroll, } = state;
    const top = useMemo(() => {
        if (toolbarHeight == null || internalScroll) {
            return 0;
        }
        return toolbarHeight + minimizedHeaderHeight;
    }, [minimizedHeaderHeight, toolbarHeight, internalScroll]);
    return (React.createElement(Box, { dataHook: "section-header", height: "42px", verticalAlign: "middle", align: "space-between", background: "linear-gradient(0deg, rgba(22, 45, 61, 0.03), rgba(22, 45, 61, 0.03)), #FFFFFF", paddingRight: "30px", paddingLeft: "30px", top: top, position: "sticky", zIndex: 2 },
        React.createElement(Text, null, sectionTitle),
        suffix));
}
export const GridSectionHeader = observer(_GridSectionHeader);
//# sourceMappingURL=GridSectionHeader.js.map