import React, {FC} from 'react';

import {TabsContextStore} from './stores/context/tabs-context-store';
import {ITabsProvider} from './tabs.type';

export const TabsProviderComponent: FC<ITabsProvider> = (props) => {
    const values = {
        buttonVariant: props.defaultButtonVariant || 'pale',
        activeColor: props.defaultActiveColor || 'primary',
        value: props.defaultValue || '',
        variant: props.defaultVariant || 'standard',
    };

    return (
        <TabsContextStore.Provider value={values}>
            {props.children}
        </TabsContextStore.Provider>
    );
};
