jobiqo-cl
Version:
[](https://circleci.com/gh/jobiqo/jobiqo-cl)
27 lines (21 loc) • 791 B
JavaScript
;
Object.defineProperty(exports, '__esModule', { value: true });
function _interopDefault (ex) { return (ex && (typeof ex === 'object') && 'default' in ex) ? ex['default'] : ex; }
var React = require('react');
var React__default = _interopDefault(React);
var index$2 = require('../context/index.js');
/**
* @file index.tsx
*
* @fileoverview Renders a step of the wizard.
*/
const WizardStep = ({ children, stepIndex }) => {
const wizardContext = React.useContext(index$2.WizardContext);
if (wizardContext.currentStep !== stepIndex) {
// Prop: The current step
return null;
}
// The markup for the Step 1 UI
return React__default.createElement(React__default.Fragment, null, children);
};
exports.WizardStep = WizardStep;