diff options
| author | anika-ahluwalia <anika.ahluwalia@gmail.com> | 2020-07-23 13:51:27 -0500 |
|---|---|---|
| committer | anika-ahluwalia <anika.ahluwalia@gmail.com> | 2020-07-23 13:51:27 -0500 |
| commit | 88176a166d78481d8f2f2f49ecf54e0f79926646 (patch) | |
| tree | 6067cf61e1ab03d1a2cc7a1797ac86937fd5851d /src/client/views/linking/LinkEditor.tsx | |
| parent | feb86078832da5f7207bc5775a61d7dd93681e98 (diff) | |
| parent | 3bcc0e3a8ce4ab67dff4b3d62191c346764aa351 (diff) | |
Merge branch 'master' of https://github.com/browngraphicslab/Dash-Web into menu_restructure
Diffstat (limited to 'src/client/views/linking/LinkEditor.tsx')
| -rw-r--r-- | src/client/views/linking/LinkEditor.tsx | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/src/client/views/linking/LinkEditor.tsx b/src/client/views/linking/LinkEditor.tsx index ed2bea722..04329182e 100644 --- a/src/client/views/linking/LinkEditor.tsx +++ b/src/client/views/linking/LinkEditor.tsx @@ -14,6 +14,7 @@ import { DocumentLinksButton } from "../nodes/DocumentLinksButton"; import { EditableView } from "../EditableView"; import { RefObject } from "react"; import { Tooltip } from "@material-ui/core"; +import { undoBatch } from "../../util/UndoManager"; library.add(faArrowLeft, faEllipsisV, faTable, faTrash, faCog, faExchangeAlt, faTimes, faPlus); @@ -295,6 +296,7 @@ export class LinkEditor extends React.Component<LinkEditorProps> { //@observable description = this.props.linkDoc.description ? StrCast(this.props.linkDoc.description) : "DESCRIPTION"; + @undoBatch @action deleteLink = (): void => { LinkManager.Instance.deleteLink(this.props.linkDoc); @@ -422,8 +424,6 @@ export class LinkEditor extends React.Component<LinkEditorProps> { </Tooltip> <p className="linkEditor-linkedTo">Editing Link to: <b>{ destination.proto?.title ?? destination.title ?? "untitled"}</b></p> - {/* <button className="linkEditor-button" onPointerDown={() => this.deleteLink()} title="Delete link"> - <FontAwesomeIcon icon="trash" size="sm" /></button> */} <Tooltip title={<><div className="dash-tooltip">Show more link information</div></>} placement="top"> <div className="linkEditor-downArrow"><FontAwesomeIcon className="button" icon={this.infoIcon} size="lg" onPointerDown={this.changeInfo} /></div> </Tooltip> |
