import React from "react";
import style from "./sortBar.module.sass";
import {connect} from "react-redux";
import {sortBar} from "../../constants/sortBar";
import SortBarElement from "./sortBarElement/SortBarElement";

const SortBar = () => {
    return(
      <div className={style.mainContainer}>
          Сортировать по:
          {sortBar.map((elem, id) => (
              <SortBarElement
                  name={elem.name}
                  sort={elem.typeSort}
                  order={elem.order}
                  key={id}
              />
          ))}
      </div>
    );
};

export default SortBar;