import * as React from 'react'; export enum ProgressState { none = 'none', loading = 'loading', error = 'error', completed = 'completed', } export interface ProgressBarProps { state: ProgressState; percent?: number; height?: number; } const CLASS_NAME = 'ontodia-progress-bar'; export class ProgressBar extends React.Component { render() { const {state, percent = 100, height = 20} = this.props; const className = `${CLASS_NAME} ${CLASS_NAME}--${state}`; const showBar = state === ProgressState.loading || state === ProgressState.error; return (
); } }