import PropTypes from 'prop-types'; import React, { Component } from 'react'; import SiteOrigin from '../../ui/site-origin/site-origin'; export default class PermissionsConnectHeader extends Component { static propTypes = { iconUrl: PropTypes.string, iconName: PropTypes.string.isRequired, siteOrigin: PropTypes.string.isRequired, headerTitle: PropTypes.node, headerText: PropTypes.string, }; static defaultProps = { iconUrl: null, headerTitle: '', headerText: '', }; renderHeaderIcon() { const { iconUrl, iconName, siteOrigin } = this.props; return (
); } render() { const { headerTitle, headerText } = this.props; return (
{this.renderHeaderIcon()}
{headerTitle}
{headerText}
); } }