diff --git a/demo/snapshot/annotations.js b/demo/snapshot/annotations.js index 1eeaa9ce..d6d1738d 100644 --- a/demo/snapshot/annotations.js +++ b/demo/snapshot/annotations.js @@ -1,164 +1 @@ -export default [ - { - type: "highlight", - color: "#5fb236", - sortIndex: "00008186", - position: { - type: "CssSelector", - value: "#the_zotero_pdf_reader_and_note_editor" - }, - text: "The Zotero PDF Reader and Note Editor", - pageLabel: "", - comment: "interesting!", - tags: [], - id: "ZVQG2R4M", - dateCreated: "2023-05-09T17:05:57.843Z", - dateModified: "2023-06-23T19:00:02.837Z", - authorName: "John", - isAuthorNameAuthoritative: true - }, - { - type: "note", - color: "#ffd400", - sortIndex: "00008353", - position: { - type: "CssSelector", - value: "div:nth-child(3) > div:first-of-type > p:last-child" - }, - pageLabel: "", - comment: "Good screenshot", - tags: [], - id: "UIRHN27J", - dateCreated: "2023-05-09T17:05:02.325Z", - dateModified: "2023-06-23T19:00:02.838Z", - authorName: "John", - isAuthorNameAuthoritative: true - }, - { - type: "note", - color: "#ffd400", - sortIndex: "00008353", - position: { - type: "CssSelector", - value: "div:nth-child(3) > div:first-of-type > p:last-child" - }, - pageLabel: "", - comment: "To do: read that paper", - tags: [], - id: "NQV7SU47", - dateCreated: "2023-05-09T17:11:35.478Z", - dateModified: "2023-06-23T19:00:02.838Z", - authorName: "John", - isAuthorNameAuthoritative: true - }, - { - type: "highlight", - color: "#2ea8e5", - sortIndex: "00009678", - position: { - type: "CssSelector", - value: "#content > div > div:first-child > div:nth-child(3)", - refinedBy: { - type: "TextPositionSelector", - start: 1536, - end: 1705 - } - }, - text: "In the items list\n\n\nYou can create a note from all annotations in a PDF by right-clicking on the parent item in the items list and choosing Add Note from Annotations.\n\n\n", - pageLabel: "", - comment: "", - tags: [], - id: "73N2RIZ5", - dateCreated: "2023-05-09T17:05:30.346Z", - dateModified: "2023-06-23T19:00:02.838Z", - authorName: "John", - isAuthorNameAuthoritative: true - }, - { - type: "underline", - color: "#2ea8e5", - sortIndex: "00011104", - position: { - type: "CssSelector", - value: "div:nth-child(18) > p:first-child", - refinedBy: { - type: "TextPositionSelector", - start: 42, - end: 62 - } - }, - text: "click the “…” button", - pageLabel: "", - comment: "", - tags: [], - id: "N4IFWQZX", - dateCreated: "2023-06-23T18:59:44.374Z", - dateModified: "2023-06-23T19:00:02.838Z", - authorName: "John", - isAuthorNameAuthoritative: true - }, - { - type: "highlight", - color: "#a28ae5", - sortIndex: "00012053", - position: { - type: "CssSelector", - value: "div:nth-child(3) > div:last-child > p:last-child", - refinedBy: { - type: "TextPositionSelector", - start: 1, - end: 91 - } - }, - text: "Note that annotations created in the built-in PDF reader are stored in the Zotero database", - pageLabel: "", - comment: "good to know", - tags: [], - id: "MVMY3NWI", - dateCreated: "2023-05-09T17:05:16.087Z", - dateModified: "2023-06-23T19:00:02.838Z", - authorName: "John", - isAuthorNameAuthoritative: true - }, - { - type: "underline", - color: "#f19837", - sortIndex: "00012284", - position: { - type: "CssSelector", - value: "#dw__toc > h3" - }, - text: "Table of Contents", - pageLabel: "", - comment: "Come back to this", - tags: [], - id: "5RAMSIAA", - dateCreated: "2023-06-23T18:59:31.824Z", - dateModified: "2023-06-23T19:00:02.838Z", - authorName: "John", - isAuthorNameAuthoritative: true - }, - { - type: "highlight", - color: "#ff6666", - sortIndex: "00012596", - position: { - type: "CssSelector", - value: "div:first-child > div:last-child > div:first-child > div:last-child", - refinedBy: { - type: "TextPositionSelector", - start: 19, - end: 63 - } - }, - text: "Last modified: 2022/04/08 04:25 by dstillman", - pageLabel: "", - comment: "", - tags: [], - id: "RL69GNWI", - dateCreated: "2023-05-09T17:05:51.707Z", - dateModified: "2023-06-23T19:00:02.838Z", - authorName: "John", - isAuthorNameAuthoritative: true - } -]; +export default []; diff --git a/src/common/components/toolbar.js b/src/common/components/toolbar.js index 3dbd2173..d9ad52cb 100644 --- a/src/common/components/toolbar.js +++ b/src/common/components/toolbar.js @@ -175,17 +175,15 @@ function Toolbar(props) { )} - {props.type === 'pdf' && ( - - )} + {props.type === 'pdf' && (