import React, { FC } from "react";
import { MarginLeverage, MarginLeverageProps } from "./MarginLeverage";
import { PreferenceMore, PreferenceMoreProps } from "./PreferenceMore";

interface Props extends MarginLeverageProps, PreferenceMoreProps {
  isLogin?: boolean;
}

export const PlaceOrderHeader: FC<Props> = props => {
  const { isLogin } = props;
  return (
    <div className="h-[44px] flex justify-between items-center px-[16px] border-b border-solid border-gray-4">
      <MarginLeverage
        leverage={props.leverage}
        marginType={props.marginType}
        onShowLeverageModal={props.onShowLeverageModal}
        isLogin={isLogin}
      />
      <PreferenceMore
        onShowPreferenceModal={props.onShowPreferenceModal}
        preferenceType={props.preferenceType}
        isLogin={isLogin}
      />
    </div>
  );
};
