Gazebo_simulation-Frontend/node_modules/.cache/babel-loader/91ab1d81e65b81abc5cd8314222...

1 line
2.5 KiB
JSON

{"ast":null,"code":"import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nimport React from 'react';\nimport PropTypes from 'prop-types';\nimport classNames from 'classnames';\nimport { mapToCssModules, tagPropType, toNumber } from './utils';\nvar propTypes = {\n children: PropTypes.node,\n bar: PropTypes.bool,\n multi: PropTypes.bool,\n tag: tagPropType,\n value: PropTypes.oneOfType([PropTypes.string, PropTypes.number]),\n max: PropTypes.oneOfType([PropTypes.string, PropTypes.number]),\n animated: PropTypes.bool,\n striped: PropTypes.bool,\n color: PropTypes.string,\n className: PropTypes.string,\n barClassName: PropTypes.string,\n cssModule: PropTypes.object\n};\nvar defaultProps = {\n tag: 'div',\n value: 0,\n max: 100\n};\n\nvar Progress = function Progress(props) {\n var children = props.children,\n className = props.className,\n barClassName = props.barClassName,\n cssModule = props.cssModule,\n value = props.value,\n max = props.max,\n animated = props.animated,\n striped = props.striped,\n color = props.color,\n bar = props.bar,\n multi = props.multi,\n Tag = props.tag,\n attributes = _objectWithoutPropertiesLoose(props, [\"children\", \"className\", \"barClassName\", \"cssModule\", \"value\", \"max\", \"animated\", \"striped\", \"color\", \"bar\", \"multi\", \"tag\"]);\n\n var percent = toNumber(value) / toNumber(max) * 100;\n var progressClasses = mapToCssModules(classNames(className, 'progress'), cssModule);\n var progressBarClasses = mapToCssModules(classNames('progress-bar', bar ? className || barClassName : barClassName, animated ? 'progress-bar-animated' : null, color ? \"bg-\" + color : null, striped || animated ? 'progress-bar-striped' : null), cssModule);\n var ProgressBar = multi ? children : React.createElement(\"div\", {\n className: progressBarClasses,\n style: {\n width: percent + \"%\"\n },\n role: \"progressbar\",\n \"aria-valuenow\": value,\n \"aria-valuemin\": \"0\",\n \"aria-valuemax\": max,\n children: children\n });\n\n if (bar) {\n return ProgressBar;\n }\n\n return React.createElement(Tag, _extends({}, attributes, {\n className: progressClasses,\n children: ProgressBar\n }));\n};\n\nProgress.propTypes = propTypes;\nProgress.defaultProps = defaultProps;\nexport default Progress;","map":null,"metadata":{},"sourceType":"module"}