Why Gemfury? Push, build, and install  RubyGems npm packages Python packages Maven artifacts PHP packages Go Modules Debian packages RPM packages NuGet packages

Repository URL to install this package:

Details    
@skava/ui / dist / components / atoms / ProgressBar / renderProps.js
Size: Mime:
"use strict";

Object.defineProperty(exports, "__esModule", {
  value: true
});

const tslib_1 = require("tslib");

const react_1 = tslib_1.__importDefault(require("react"));

const deps_1 = require("./deps");

const styled_1 = require("./styled");

function renderFillBar(props) {
  const {
    barColor,
    currentValue,
    totalValue
  } = props;
  const fillProps = {
    barColor,
    progressWidth: deps_1.percentageConversion(currentValue, totalValue)
  };
  return react_1.default.createElement(styled_1.ProgressBarFill, Object.assign({}, fillProps));
}

exports.renderFillBar = renderFillBar;

function renderWrapper(props) {
  const {
    children,
    className,
    barColor,
    barWidth
  } = props;
  const wrapProps = {
    className,
    barColor,
    barWidth
  };
  return react_1.default.createElement(styled_1.ProgressBarWrap, Object.assign({}, wrapProps), children);
}

exports.renderWrapper = renderWrapper; //# sourceMappingURL=renderProps.js.map