|
|
@ -4,7 +4,7 @@
|
|
|
|
* @Github:
|
|
|
|
* @Github:
|
|
|
|
* @Date: 2019-12-17 17:35:17
|
|
|
|
* @Date: 2019-12-17 17:35:17
|
|
|
|
* @LastEditors : tangjiang
|
|
|
|
* @LastEditors : tangjiang
|
|
|
|
* @LastEditTime : 2019-12-24 17:11:59
|
|
|
|
* @LastEditTime : 2019-12-24 18:05:18
|
|
|
|
*/
|
|
|
|
*/
|
|
|
|
import './index.scss';
|
|
|
|
import './index.scss';
|
|
|
|
import React, { useState } from 'react';
|
|
|
|
import React, { useState } from 'react';
|
|
|
@ -14,6 +14,7 @@ import { Icon } from 'antd';
|
|
|
|
import CommentForm from './CommentForm';
|
|
|
|
import CommentForm from './CommentForm';
|
|
|
|
|
|
|
|
|
|
|
|
function CommentItem ({
|
|
|
|
function CommentItem ({
|
|
|
|
|
|
|
|
isAdmin,
|
|
|
|
options,
|
|
|
|
options,
|
|
|
|
confirm,
|
|
|
|
confirm,
|
|
|
|
comment,
|
|
|
|
comment,
|
|
|
@ -60,7 +61,7 @@ function CommentItem ({
|
|
|
|
const commentAvatar = (author) => (
|
|
|
|
const commentAvatar = (author) => (
|
|
|
|
<img
|
|
|
|
<img
|
|
|
|
className="item-flex flex-image"
|
|
|
|
className="item-flex flex-image"
|
|
|
|
src={author.image_url ? getImageUrl(`/images/${author.image_url}`) : 'https://b-ssl.duitang.com/uploads/item/201511/13/20151113110434_kyReJ.jpeg'}
|
|
|
|
src={author.image_url ? getImageUrl(`images/${author.image_url}`) : 'https://b-ssl.duitang.com/uploads/item/201511/13/20151113110434_kyReJ.jpeg'}
|
|
|
|
alt=""
|
|
|
|
alt=""
|
|
|
|
/>
|
|
|
|
/>
|
|
|
|
);
|
|
|
|
);
|
|
|
@ -176,6 +177,7 @@ function CommentItem ({
|
|
|
|
|
|
|
|
|
|
|
|
<div className="comment_icon_area">
|
|
|
|
<div className="comment_icon_area">
|
|
|
|
<CommentIcon
|
|
|
|
<CommentIcon
|
|
|
|
|
|
|
|
style={{ display: isAdmin ? 'inline-block' : 'none'}}
|
|
|
|
className='comment-icon-margin'
|
|
|
|
className='comment-icon-margin'
|
|
|
|
type={!hidden ? "eye" : 'eye-invisible'}
|
|
|
|
type={!hidden ? "eye" : 'eye-invisible'}
|
|
|
|
iconClick={() => handleShowOrHide(id, !hidden ? 1 : 0)}
|
|
|
|
iconClick={() => handleShowOrHide(id, !hidden ? 1 : 0)}
|
|
|
|