import React, { Component } from 'react' import PropTypes from 'prop-types' import { connect } from 'react-redux' import { setContentViewDescription, setContent } from '../../ducks/ui/flow' import withContentLoader from './ContentLoader' import { MessageUtils } from '../../flow/utils' import CodeEditor from './CodeEditor' const isImage = /^image\/(png|jpe?g|gif|vnc.microsoft.icon|x-icon)$/i ViewImage.matches = msg => isImage.test(MessageUtils.getContentType(msg)) ViewImage.propTypes = { flow: PropTypes.object.isRequired, message: PropTypes.object.isRequired, } function ViewImage({ flow, message }) { return (
                    {lines.map((line, i) =>
                        
                            {line.map((element, j) => {
                                let [style, text] = element
                                return (
                                    
                                        {text}
                                    
                                )
                            })}
                        
                    )}