import { FontAwesomeIcon } from '@fortawesome/react-fontawesome'; import React, { Component } from 'react'; import { BoolCast } from '../../../../../fields/Types'; import { Colors } from '../../../global/globalEnums'; import { IButtonProps } from '../ButtonInterface'; export class ToggleButton extends Component { render() { const type = this.props.type; // Determine the type of toggle button const switchToggle: boolean = BoolCast(this.props.rootDoc.switchToggle); if (switchToggle) { return (
); } else { return (
{this.props.label}
); } } }