Commit graph

29 commits

Author SHA1 Message Date
Adomas Venčkauskas
51db52a5ea Changes for note insertion in non-GoogleDocs 2021-03-02 17:43:10 -05:00
Adomas Venčkauskas
2e9e655479 Add ability to cite Zotero notes.
<span class=citation data-citation=serialized-citation-data/>
elements will automatically be converted to zotero citations
2021-03-02 17:43:09 -05:00
Adomas Venčkauskas
2b3669afd8 Consolidate Integration.Fields into Integration.Session 2021-03-02 17:43:09 -05:00
Dan Stillman
e8dd1f7824 Test updates for newer Sinon 2019-09-16 01:27:30 -04:00
Adomas Venčkauskas
c4f40c38e9 Unsuppress accidental test suppression from fe01e17 2019-07-04 15:46:24 +03:00
Adomas Venčkauskas
fe01e17e93 Fix integration test breakage (regression cd14a53) 2019-07-04 15:38:46 +03:00
Adomas Venčkauskas
cd14a536dc Add retracted citation warning tests. Fix a bug with embedded prompts 2019-07-04 15:16:26 +03:00
Adomas Ven
48778f2847 Document export-import UI and integration code (#1501) 2019-05-14 21:06:18 -04:00
Adomas Venčkauskas
78c3d5808b Fix citeproc errors due to improper citeproc state updates
The error is triggered upon initial interaction with a doc after Zotero
restart or if new external citations (copied into the document) are
peresnt and `session.updateSession()` is called without a subsequent
`session.updateDocument()` call. `session.updateSession()` is called
without a subsequent `session.updateDocument()` call every time the
user cancels a citation insert.

More specifically, `session.updateSession()` is called every time a
citation dialog is invoked. It retrieves all citations and writes them
into a local `session.citationsByIndex` object. Moreover, it marks
each citation that hasn't seen before in a `session.newIndices` object.
`session.newIndices` is there to ensure that we load every new citation
into citeproc upon document update. This object is built by marking any
citation that does not appear in the previous invocation's list of
citations as new. However, if the document is never updated (because the
user cancels the insertion) then the new indices are not loaded
into citeproc. This commit fixes that, by excluding citeproc unloaded
items from the previous invocation's citation list.
2019-04-08 17:43:52 +03:00
Frank Bennett
2c136ffbb0 Add test of multiple new insertions with implicit update on the first 2019-02-13 10:18:05 +02:00
Frank Bennett
bffbe00399 Test of implicit citation update 2019-02-13 10:17:58 +02:00
Frank Bennett
0e18c5f1de Test for bibliography sort update on change to item 2019-02-10 11:07:10 +09:00
Adomas Venčkauskas
01f3159b2f Ensure all failing integration tests are fixed (8d8410ff). Closes #1546 2018-08-14 11:40:19 +03:00
Adomas Venčkauskas
8d8410ffa0 Fix failing integration test (regr 0f1687f). Closes #1546 2018-08-13 14:22:15 +03:00
Adomas Venčkauskas
593153eebe Adds a progress bar for non quick-format integration actions
The progress percentage is based on the most recent transaction
(or undeterminate if this is the first session transaction)

Fix undefined function call error
2018-04-24 01:37:10 -04:00
Adomas Venčkauskas
5e5b567782 Add a connector document integration endpoint
Specifically for google docs via the connector, but could potentially be
used for any integration via HTTP or connector.
2018-04-20 13:08:34 +03:00
Adomas Venčkauskas
bff7cee374 Add a test case for copied citations (for 9c7271c6) 2018-03-28 14:55:46 +03:00
Adomas Venčkauskas
3445519714 Fix citationByIndex[i].sortedItem errors during citation insertion
Caused by inproper handling of copy-pasted citations in documents
2018-03-26 15:31:26 +03:00
Adomas Venčkauskas
d857a813b9 Fix integration test errors. Closes #1426 2018-01-25 12:48:12 +02:00
Adomas Venčkauskas
2827f70daa Option to delay updating citation in document.
The checkbox in doc prefs is hidden until an update takes 5s or longer
after which the user is prompted to enable delaying.
2018-01-03 14:27:16 +02:00
Adomas Venčkauskas
6d05c3472b Add more integration tests 2018-01-03 14:27:16 +02:00
Adomas Venčkauskas
f44d563a15 Add Zotero.Integration.Citation
- Moves a bunch of citation related processing from Integration.Session
- Replaces missing item handling with a function instead of exception
- Solves some really confusing flow issues in _processFields
2018-01-03 14:27:16 +02:00
Adomas Venčkauskas
a1acbd4038 Make current session globally available
Decoupling! Sessions can be instantiated without
Zotero.Integration.Interface
2018-01-03 14:27:16 +02:00
Adomas Venčkauskas
41c93ab034 Rename Integration.Document to Integration.Interface 2018-01-03 14:27:16 +02:00
Tom Najdek
063e13ef22 Modernize sinon.stub() calls 2017-06-01 11:36:17 -04:00
Adomas Venčkauskas
37fa0c203f Write sessionID into the doc on new session creation 2017-05-03 14:34:00 +03:00
Adomas Venčkauskas
3c19bbffe4 Remove store references in document option. Closes #1216 2017-05-02 16:29:19 +03:00
Adomas Venčkauskas
5e3c7bf63d Fix test breakage from a76493f60 2017-05-02 15:09:12 +03:00
Dan Stillman
32b1769f2f integrationTests.js -> integrationTest.js 2017-04-28 04:12:19 -04:00
Renamed from test/tests/integrationTests.js (Browse further)