Commit graph

1360 commits

Author SHA1 Message Date
Dan Stillman
76f2f0c783 Don't show items with annotated attachments after moving to trash
https://forums.zotero.org/discussion/100775/deleted-items-keep-reappearing-in-my-library

Regression from c3ee588bf
2022-11-28 04:34:49 -05:00
Adomas Venčkauskas
f98ab3b0a6 Import URL from XPCOM code instead of relying on window for Proxy code
Also fix other failing proxy tests. Closes #2928
2022-11-22 15:58:49 +02:00
Adomas Venčkauskas
7e4e66b54d Fix proxy test 2022-11-22 15:51:54 +02:00
Dan Stillman
7ffc509ee6 Fix response content type in Find Available PDF test 2022-11-21 01:14:07 -05:00
Dan Stillman
c6df0b586c Use clearer name for Find Available PDF tests 2022-11-21 01:14:07 -05:00
Dan Stillman
b5862ba780 Handle relative PDF links when using custom PDF resolver 2022-11-21 01:14:07 -05:00
Abe Jellinek
74492e40c4
Improve bidi & RTL support (#2415)
- Render cell text in its native direction
- Fix context menu positioning
- Fix item box (localizations needed)
- Fix column resizing
- Fix bidi text in collection tree
- Always right-align in RTL, always left-align in LTR.
  I'm going off advice from this excellent guide for RTL website design
  by Ahmad Shadeed: https://rtlstyling.com/posts/rtl-styling#tables
- Join creators in the tree ("Smith and Jones") using a format string to
  support languages like Arabic and Hebrew where there shouldn't be a
  space after the "and".
- Fix tabs
- Fix toolbar on Mac, flip icons on other platforms
2022-11-20 18:23:17 -05:00
Abe Jellinek
b6591dba5a
Make Feeds row into a selectable global view of feed items (#2800) 2022-11-14 16:55:28 -05:00
Adomas Venčkauskas
56229136be Adjust tests to not use the dotsToHyphens proxy option 2022-11-10 12:46:14 +02:00
Dan Stillman
8e59e49d29 Avoid infinite/excessive loops in Find Available PDF
https://forums.zotero.org/discussion/100634/potential-infinite-loop-when-trying-to-find-available-pdf

Closes #2883
2022-10-30 04:44:31 -04:00
Dan Stillman
9869eb4bc8 Restore cell.csl for style tests
Removed in a28908f0b4
2022-10-27 05:07:46 -04:00
Dan Stillman
3a77eb85ed Don't match all attachments with annotations for "not" search conditions
Fixes #2867
2022-10-27 03:46:18 -04:00
Adomas Venčkauskas
0d1b194b6b Add an integration test for citation merging 2022-10-25 14:50:22 +03:00
Adomas Venčkauskas
19558a425b Fix wrong given name disambiguation after editing author for citeproc-js
Closes #2870
2022-10-25 14:50:05 +03:00
Adomas Venčkauskas
a28908f0b4 Change integration test citation style to APA and some refactoring 2022-10-25 14:50:05 +03:00
Adomas Venčkauskas
87a567122e Fx102: Fix Integration tests 2022-10-25 13:48:39 +03:00
Abe Jellinek
c1bb910d1c
Clear sync error and start sync after logging in in prefs (#2802)
Also fixes an existing error due to an argumentless call to
Zotero.Sync.Runner.updateIcons() in ZoteroPane.
2022-10-16 15:47:54 -04:00
Martynas Bagdonas
81c6c8deff Add annotation update test to pdf-reader tests 2022-10-13 02:20:42 -04:00
Abe Jellinek
5f9e8f5b7e Automatically relink attachments from LABD (#2374)
Fixes #2092
2022-10-10 10:38:43 -04:00
Martynas Bagdonas
ecd0e50ac4 Tweak pdf-reader annotation creation test 2022-10-10 17:06:00 +03:00
Martynas Bagdonas
3a26f6eb6f Add pdf-reader annotation creation test
(cherry picked from commit af436d34a8)
2022-10-10 16:56:17 +03:00
Tom Najdek
223f44fdfd Map annotation colors colors on import #2819 (#2822) 2022-09-12 19:58:21 -04:00
Dan Stillman
a63c634e3f Add "Create Note from Annotations" option to items list context menu
To allow creation of a standalone note with annotations from all the
selected top-level items and/or attachments. Annotations will be sorted
by the order of the items in the items list.

"Add Note from Annotations" remains when a single regular item or one or
more attachments under a single regular item are selected.
2022-09-12 15:54:03 -04:00
Dan Stillman
e81b43be98 Add collectionID option to EditorInstance.createNoteFromAnnotations()
For adding a standalone note to the current collection
2022-09-12 15:54:03 -04:00
Dan Stillman
39e45221b1 Rename Zotero.Items::keepParents() to keepTopLevel()
So that it works for more than two levels of items

Also fix a bug where the parent item could be returned more than once if
multiple child items were selected.
2022-09-12 15:54:03 -04:00
Dan Stillman
497d6376c8 Add Zotero.Item::topLevelItem and Zotero.Items.getTopLevel(items) 2022-09-12 15:54:03 -04:00
Martynas Bagdonas
f70ec29881 EditorInstance.createNoteFromAnnotations(): Handle multiple attachments 2022-09-12 15:54:03 -04:00
Abe Jellinek
5d6ad703c1 Preferences: Fix tests, improve clarity, and more
- Fix sync and advanced preferences tests; use a new waitForFirstPaneLoad()
  functions instead of the old paneload event listener
- Remove empty preferences_searchTest.js
- Rename some Zotero_Preferences members/functions for better clarity and
  public/private differentiation
- Reorder, also for clarity
- Fix tabIndex parameter causing an error if invalid
- Remove window.sizeToContent() call in Sync.displayFields()
    - So *that's* why the window resized every time the sync pane was loaded...
- Deprecate openURL() and simplify openInViewer()
2022-09-02 11:01:37 -04:00
Dan Stillman
00b24f85c9 Fix HTTP.request() 5xx handling with errorDelayMax=0
This was causing delay-less infinite loops for OPTIONS requests to Box,
which are returning 502 errors.
2022-08-29 23:46:58 +02:00
Abe Jellinek
63864f2f86
duplicateAndConvertSelectedItem: Don't copy abstracts (#2799) 2022-08-29 16:15:31 -04:00
Dan Stillman
170f1962ad Don't repeatedly upload relations
Fixes #2772
2022-08-22 01:15:21 -04:00
Dan Stillman
5103d904f3 Include proper test for b373291c02 for #2771 2022-08-19 12:05:30 -04:00
Dan Stillman
e9e1add9b8 Fixed filed items with annotations appearing in Unfiled Items
Fixes #2771

Regression from 20c6fe67
2022-08-19 12:05:30 -04:00
Abe Jellinek
22b00c33de Empty Trash: Visually remove deleted items, refresh icon (#2606)
There were a few problems causing the incorrect behavior:
1. Rows were being removed only if they had no non-deleted children, which
   wasn't the right check. We want to remove all rows with no *deleted*
   children.
2. Children of the removed rows weren't being removed with them.
3. We weren't invalidating the tree (which _removeRows() doesn't do).

Also:

* Erase trashed annotation after getAnnotations() test

Because ItemTree#notify() doesn't yet correctly handle refresh events on
parent items that are themselves children (three-level nesting: item ->
attachment -> annotation), this test was causing a failure in
itemTreeTest.js.
2022-08-19 09:14:24 -04:00
Dan Stillman
d3d6a6be48 Fix and disable item-tree test for emptying trash
20c6fe6737 caused this to start failing, but only because the test was
testing something too specific. The change in that commit caused more
rows to be left behind when emptying the trash (for reasons I should
probably look into), but the trash wasn't being emptied properly before,
which #2606 should fix. This test should be restored as part of that PR.
2022-08-17 03:35:54 -04:00
Dan Stillman
c3ee588bfe Match parent attachments for annotation tags
Expose annotation tags in tag selector and match parent attachments when
filtering/searching

This also fixes searching for annotation text or comments when using
Everything quick search.

This is temporary until we display annotations in the items list
directly.
2022-08-17 03:35:28 -04:00
Dan Stillman
6cd1a41a32 Fix importing of standalone attachments without URLs
And allow `importSnapshotFromFile()` without `parentItemID` or
`libraryID`, which is more consistent with other attachment functions

Follow-up to 318e4852e9

https://forums.zotero.org/discussion/comment/414802/#Comment_414802
2022-08-16 06:09:00 -04:00
Dan Stillman
676abca671 Fix importing of standalone attachments
Maybe has been broken for years?

https://forums.zotero.org/discussion/99020/warning-data-loss-when-exporting-collections
2022-08-13 16:24:14 -04:00
Dan Stillman
d546caca4c Don't relate book sections to each other when creating from book
Fixes #2757
2022-08-13 05:46:04 -04:00
Dan Stillman
344a10421a Fix copying of standalone attachments between libraries
Regression in f684984b07 (maybe a race condition)
2022-08-13 02:04:07 -04:00
Dan Stillman
c90f8415b3 Improve test for event-title substitution
And add comments

Follow-up to 20d0f103f
2022-08-11 03:57:25 -04:00
Dan Stillman
ebacb83563 Reset Zotero.locale to 'en-US' after cite test 2022-08-11 03:57:20 -04:00
Dan Stillman
7eab91a160 Automatically substitute event-title for event in styles
Stopgap until styles are updated in citation-style-language/styles#6151
2022-08-11 03:57:15 -04:00
Abe Jellinek
df5bde79e5 Add test for 87455d 2022-08-11 03:57:09 -04:00
Abe Jellinek
1f9e518581 Duplicates Merge: Preserve embedded annotations (#2728) 2022-08-11 03:52:40 -04:00
Martynas Bagdonas
d595b3f195 Freeze note schema version to 8
We can do it because it was only used to create a note from annotations.

No need to update schema version in Zotero client, unless using new
features when creating a note from annotations.
2022-08-11 03:50:06 -04:00
Dan Stillman
1e5fd2d551 Disable sort tests from 26a5e2900a for now
Until I can figure out the race-condition breakage they trigger later in
the file
2022-08-11 03:46:56 -04:00
Dan Stillman
612fec8961 Fix test failure after 26a5e2900a 2022-08-11 02:48:39 -04:00
Dan Stillman
d3942ad1f0 Better fix for errors from invalid sort fields
Just catch the error from `ItemTree::sort()` and clear the
secondary-sort and fallback-sort prefs so that sorting works on the next
attempt.

Replacement for a8ed30ce80

https://groups.google.com/g/zotero-dev/c/kc0-C6-SA74/m/bhHniGceAQAJ
2022-08-11 02:48:35 -04:00
Dan Stillman
d747da7c65 Revert "Validate fields in ItemTree::getSortFields()"
This reverts commit a8ed30ce80 and related
commits.

We'll address breakage from invalid sort fields another way, without
inconveniencing plugin authors.

https://groups.google.com/g/zotero-dev/c/kc0-C6-SA74/m/bhHniGceAQAJ
2022-08-11 02:48:31 -04:00