import * as React from "react" ; import { IDetailsWidgetProps } from "../interfaces" ; import { IIdentity } from "../model" ; import { BaseWidgetComponent } from "./widgetbase" ; export class AssignedComponent extends BaseWidgetComponent < void > { public render ( ) { let identities = this . _renderIdentities ( ) ; return < div className = "widget" > < div className = "title" > People < /div> < div className = "content assigned-to" > < ul className = "" > { identities } < /ul> < /div> < /div>; } private _renderIdentities ( ) { if ( this . props . backlogDetailsModel ) { return this . props . backlogDetailsModel . identities . map ( i => { return < IdentityComponent key = { i . uniqueName } identity = { i } / > ; } ) ; } } } class IdentityComponent extends React . Component < { identity : IIdentity ; } , void > { public render ( ) { return < li > < img src = { this . props . identity . imageUrl } />&nbsp;{this.props.identity.displayName}</li > ; } }