import { defaultCharWidth, defaultContainerWidth, defaultMarginWidth } from "../constants/rowviewContants";
export default function getBpsPerRow(_ref) {
  var _ref$charWidth = _ref.charWidth,
    charWidth = _ref$charWidth === void 0 ? defaultCharWidth : _ref$charWidth,
    _ref$width = _ref.width,
    width = _ref$width === void 0 ? defaultContainerWidth : _ref$width,
    _ref$dimensions = _ref.dimensions;
  _ref$dimensions = _ref$dimensions === void 0 ? {} : _ref$dimensions;
  var width2 = _ref$dimensions.width,
    _ref$marginWidth = _ref.marginWidth,
    marginWidth = _ref$marginWidth === void 0 ? defaultMarginWidth : _ref$marginWidth,
    sequenceData = _ref.sequenceData;
  var toRet = Math.floor(((width2 || width) - marginWidth) / (sequenceData.isProtein ? charWidth * 3 : charWidth));
  return sequenceData.isProtein ? toRet * 3 : toRet;
}