diff options
author | crupest <crupest@outlook.com> | 2021-06-15 17:14:04 +0800 |
---|---|---|
committer | crupest <crupest@outlook.com> | 2021-06-15 17:14:04 +0800 |
commit | 0be1f595578153765d081cdb4478140da9cb8fc9 (patch) | |
tree | 1bd5f459479603df379edb7c0b55de963391c6ca /FrontEnd/src/views/timeline-common/TimelinePostView.tsx | |
parent | 1f242271a98900ca0a72a13ab05efbf65090df0d (diff) | |
download | timeline-0be1f595578153765d081cdb4478140da9cb8fc9.tar.gz timeline-0be1f595578153765d081cdb4478140da9cb8fc9.tar.bz2 timeline-0be1f595578153765d081cdb4478140da9cb8fc9.zip |
...
Diffstat (limited to 'FrontEnd/src/views/timeline-common/TimelinePostView.tsx')
-rw-r--r-- | FrontEnd/src/views/timeline-common/TimelinePostView.tsx | 25 |
1 files changed, 12 insertions, 13 deletions
diff --git a/FrontEnd/src/views/timeline-common/TimelinePostView.tsx b/FrontEnd/src/views/timeline-common/TimelinePostView.tsx index f7b81478..e9dd3443 100644 --- a/FrontEnd/src/views/timeline-common/TimelinePostView.tsx +++ b/FrontEnd/src/views/timeline-common/TimelinePostView.tsx @@ -8,6 +8,8 @@ import { getHttpTimelineClient, HttpTimelinePostInfo } from "@/http/timeline"; import { pushAlert } from "@/services/alert"; import UserAvatar from "../common/user/UserAvatar"; +import Card from "../common/Card"; +import FlatButton from "../common/button/FlatButton"; import TimelineLine from "./TimelineLine"; import TimelinePostContentView from "./TimelinePostContentView"; import TimelinePostDeleteConfirmDialog from "./TimelinePostDeleteConfirmDialog"; @@ -60,7 +62,7 @@ const TimelinePostView: React.FC<TimelinePostViewProps> = (props) => { style={style} > <TimelineLine center="node" current={current} /> - <div ref={cardRef} className="timeline-item-card" style={cardStyle}> + <Card ref={cardRef} className="timeline-item-card" style={cardStyle}> {post.editable ? ( <i className="bi-chevron-down text-info icon-button float-end" @@ -91,32 +93,29 @@ const TimelinePostView: React.FC<TimelinePostViewProps> = (props) => { </div> {operationMaskVisible ? ( <div - className="position-absolute position-lt w-100 h-100 mask d-flex justify-content-around align-items-center" + className="timeline-post-item-options-mask d-flex justify-content-around align-items-center" onClick={() => { setOperationMaskVisible(false); }} > - <span - className="tl-color-primary" + <FlatButton + text="changeProperty" onClick={(e) => { setDialog("changeproperty"); e.stopPropagation(); }} - > - {t("changeProperty")} - </span> - <span - className="tl-color-danger" + /> + <FlatButton + text="delete" + color="danger" onClick={(e) => { setDialog("delete"); e.stopPropagation(); }} - > - {t("delete")} - </span> + /> </div> ) : null} - </div> + </Card> {dialog === "delete" ? ( <TimelinePostDeleteConfirmDialog onClose={() => { |