import React, { Component } from 'react';
import PropTypes from 'prop-types';

import TipSearch from './../../common/tip/Search';

class SearchService extends Component {

  static propTypes = {
    showText: PropTypes.bool
  };

  render() {
    const { showText } = this.props;
    const placeholder = showText ? '搜索服务' : '';
    return (
      <div className="header-search">
        <TipSearch
          placeholder={placeholder}
          to="/main/service"
        />
      </div>
    );
  }
}

export default SearchService;
