File indexing completed on 2025-01-26 05:27:59
0001 import React, { Component } from 'react'; 0002 0003 class RatingContainer extends React.Component { 0004 render(){ 0005 let ratingContainer; 0006 if (this.props.votes){ 0007 const votes = this.props.votes.map((cm,index) => ( 0008 <li key={index}> 0009 <div className="cm-content"> 0010 <span className="cm-userinfo"> 0011 <img src={cm.profile_image_url}/> 0012 <span className="username"><a href={this.props.baseUrlStore+"/member/"+cm.member_id}>{cm.username}</a></span> 0013 </span> 0014 <a className="title" href={this.props.baseUrlStore+"/p/"+cm.project_id}>{cm.title}</a> 0015 <span className="content"> 0016 Score:{cm.score} {cm.comment_text} 0017 </span> 0018 <span className="info-row"> 0019 <span className="date"> 0020 {cm.created_at} 0021 0022 </span> 0023 </span> 0024 </div> 0025 </li> 0026 )); 0027 ratingContainer = <ul>{votes}</ul> 0028 } 0029 return ( 0030 <div className="panelContainer"> 0031 <div className="title">{this.props.title}</div> 0032 {ratingContainer} 0033 </div> 0034 ) 0035 } 0036 } 0037 0038 export default RatingContainer;