UNPKG

react-onsenui

Version:

Onsen UI - React Components for Hybrid Cordova/PhoneGap Apps with Material Design and iOS UI components

63 lines (55 loc) 1.6 kB
import PropTypes from 'prop-types'; import 'onsenui/esm/elements/ons-progress-bar'; import onsCustomElement from '../onsCustomElement'; /** * @original ons-progress-bar * @category visual * @tutorial react/Reference/progress * @description * [en] The component is used to display a linear progress bar. It can either display a progress bar that shows the user how much of a task has been completed. In the case where the percentage is not known it can be used to display an animated progress bar so the user can see that an operation is in progress. [/en] * [ja][/ja] * @example *<ProgressBar value={55} secondaryValue={87} /> *<ProgressBar indeterminate /> */ const ProgressBar = onsCustomElement('ons-progress-bar'); ProgressBar.propTypes = { /** * @name modifier * @type string * @required false * @description * [en]The appearance of the progress indicator.[/en] * [ja][/ja] */ modifier: PropTypes.string, /** * @name value * @type number * @description * [en] * Current progress. Should be a value between 0 and 100. * [/en] * [ja][/ja] */ value: PropTypes.number, /** * @name secondaryValue * @type bool * @description * [en] * Current secondary progress. Should be a value between 0 and 100. * [/en] * [ja][/ja] */ secondaryValue: PropTypes.number, /** * @name indeterminate * @type bool * @description * [en] If this property is set, an infinite looping animation will be shown. [/en] * [ja][/ja] */ indeterminate: PropTypes.bool }; export default ProgressBar;