Commit graph

9917 commits

Author SHA1 Message Date
abaevbog
2835d6fe83
tag selector focus edits, fix windowing breakage (#3984)
* tag selector focus edits

- no tabstop on the tag selector scrollable area
- change tag selector's role from default "grid" to "group".
"grid" is not quite correct semantically and leads to
voiceover suggesting irrelevant commands.
- move all keyboard handling logic to tagSelectorList.jsx.
Tabbing through tag selector is now handled in ZoteroPane,
so the only logic left there is arrow navigation
between tags, and there's no reason to not have it
together with the tags list.
- a workaround to deal with focused tags when windowing
kicks in. When a tag is focused, record its index.
Each time tags are re-rendered, if the saved index is not
among rendered tags, refocus it, otherwise, move focus
to the tags list.
2024-04-18 08:39:36 +03:00
abaevbog
816aaca380
vpat 5: do not include separator in qf list count (#4001)
Screen readers announce the index of the selected item
from the list of citations in the panel. This removes
the separators from the count, since they are not focusable
and should be skipped.
2024-04-18 00:35:27 -04:00
windingwind
e2b72944be
Fix attachments section not updated when attachments are changed (#3992)
fix: #3989
2024-04-17 05:12:32 -04:00
abaevbog
80ac628d98
vpat 52: added aria label to quick search button (#3986)
Plus minor tweaks to get fluent to work in shadow doms
of the search textbox components
2024-04-17 04:15:47 -04:00
windingwind
e2970f242c
fx115: Fix popupset display (#3998)
fixes #3979
2024-04-17 03:34:02 -04:00
Adomas Venčkauskas
c9561f1041 Prevent itemlist in classic cit and edit bibl dialogs from expanding
Also
- Cleanup the XUL of said dialogs
- Refactor, spearate and clarify custom CSS injection into FX XUL
  elements
2024-04-16 11:47:01 +03:00
Adomas Venčkauskas
76b7f4be4f Fix styling in the generate bibliography dialog 2024-04-16 11:47:01 +03:00
abaevbog
363f97325f
vpat 9: set aria properties on the sync button (#3988)
Set the aria-label on the sync button. On focus,
register the sync status and set the aria-description
to be the last sync status.
2024-04-16 04:12:51 -04:00
abaevbog
d4905854eb
vpat 18: added aria labels to inputs in settings (#3985) 2024-04-16 00:51:49 -04:00
windingwind
687ba53afd
Fix attachment preview of the first added attachment (#3980)
Fixes #3973
2024-04-16 00:47:00 -04:00
Dan Stillman
86ee56cfac Automatically focus collection name in New Collection window
https://forums.zotero.org/discussion/113706/zotero-beta-7-adding-new-collection
2024-04-15 23:49:13 -04:00
Adomas Venčkauskas
cdacc42fd2 Set a reasonable min-height for classic citation and edit bibl dialogs 2024-04-15 14:54:54 +03:00
Dan Stillman
c6e5850e1c Update utilities submodule
Includes capitalizeTitle() fix:

https://forums.zotero.org/discussion/113653/zotero-7-beta-incorrect-behaviour-applying-title-case-action-to-titles-with-rich-text-markup
2024-04-14 03:22:41 -04:00
abaevbog
c7c3784413
fix focus test breakage after zotero@6859614 (#3977)
- edits to zoteroPaneTest.js focus tests to expect the updated focus
sequence: selected tab -> tabs menu -> sync button -> collectionTree
toolbar -> collectionTree -> tags selector -> itemTree toolbar
- updated tags selector keydown handling to explicitly handle all
tab/shift-tab events using moveFocus. It is more readable and explicit
focus handling for all components is required for programmic tab/shiftTab
events dispatched in tests to actually move focus
Fixes: #3975
2024-04-14 02:16:16 -04:00
Abe Jellinek
fc648a949a
Set main window min-width/height dynamically (#3841)
Correctly calculates minimums when window is too small, so it grows
when the collection tree is made bigger.
2024-04-13 03:44:17 -04:00
Abe Jellinek
860e2ce7ca Import AppConstants globally, lazily 2024-04-13 01:07:00 -04:00
Abe Jellinek
210d815173 Prevent duplicate main window
Fixes #3964
2024-04-13 01:07:00 -04:00
Dan Stillman
c31c091cb0 Fix size of progress meter at startup
(Though it still doesn't animate, for some reason)

Addresses #3961
2024-04-13 00:32:36 -04:00
Dan Stillman
d236058351 Fix styling in Document Preferences window 2024-04-13 00:30:29 -04:00
Dan Stillman
45fbf8bb12 fx115: Fix Edit Bibliography dialog
https://forums.zotero.org/discussion/113647/zotero-7-beta-73-fails-to-open-add-edit-bibliography-window-in-word
2024-04-13 00:29:36 -04:00
Abe Jellinek
c031e1fbbd Scaffold: Disable sticky headers in Tests editor 2024-04-12 13:21:17 -07:00
Abe Jellinek
b029e561f3 fx115: Scaffold: Restore flex ratio in Tests tab 2024-04-12 13:18:52 -07:00
Dan Stillman
b3b0f04214 fx-compat: Add OS.Path.split() to shim 2024-04-12 06:41:38 -04:00
abaevbog
68596148b0
vpat: 4 change focus sequence in zotero pane (#3954)
From the sync button, tabbing will move focus in the following mannger:
collections toolbar -> collections -> tags selector -> itemTree toolbar
-> itemTree.
2024-04-12 06:32:02 -04:00
abaevbog
9421e09e84
vpat 3: consistent focus order in all directions (#3953)
On last tab in the itemPane/contextPane, focus will wrap around
to the selected tab to complete the loop. It ensures
that the focus order is consistent regardless of the
directions.

Also, minor tweaks to focusWrapAround in Zotero_Tabs
to properly move focus to the last focusable entry in
the contextPane.
2024-04-12 06:26:47 -04:00
abaevbog
4432f88f1d
vpat_11: add roles and states to tags in selector (#3967)
- set each tag's role as "checkbox"
- set "aria-checked" status depending on if the tag
is selected
- added aria-label to tag selector so it does not
default to "grid"
2024-04-12 06:22:16 -04:00
abaevbog
91bc1a3e2d
vpat 6: aria labels for buttons in item/context panes (#3957)
Added aria labels and button roles for buttons in the
item/Collection pane. This includes buttons in the header
as well as rows from notes, related, collections, and
attachments section that act as buttons. Also added
missing aria-labelledby for mini-itembox rows below
attachment preview to have filename, dateModified
and etc. properly labelled.

This also covers most of vpat 16.

This does not affect how tags/header/itemBox entries are announced.
There is a separate issue with NVDA and JAWS sometimes struggling
with announcing text inside of `editable-text` component,
so this will be handled separately.
2024-04-12 04:53:35 -04:00
Adomas Venčkauskas
7f573d7717 Replace UA rv to potentially fix bot detection avoidance 2024-04-12 10:34:39 +03:00
abaevbog
117197e11d
vpat: 1 add role="link" to links components (#3952)
- added role="link" to "zotero-text-link" custom component,
using that instead of directly setting the class
wherever possible
- in all other cases, added role="link" directly to links
- added tooltiptext and "noClick" option to zotero-text-link
so that this component could be used in attachmentBox.js
- use "keyboard-clickable" class in zotero-text-link
instead of a separate listener to handle keypresses for brevity
2024-04-11 23:02:53 -04:00
Abe Jellinek
5263c79ea8 BlockingObserver: Re-enable in CI 2024-04-11 22:59:48 -04:00
Abe Jellinek
35f5b19ffd BlockingObserver: Remove platformMajorVersion check 2024-04-11 22:59:48 -04:00
Abe Jellinek
5099da355c BlockingObserver: Don't block when browserId is 0 2024-04-11 22:59:48 -04:00
Abe Jellinek
6ebb15778b
fx115: Fix Scaffold richlistboxes and load dialog sizing (#3968) 2024-04-11 22:53:59 -04:00
Tom Najdek
14586d72b0
Use theme colors in debug viewer 2024-04-11 20:08:10 +02:00
Dan Stillman
80357b1938 CI: Proper disabling of BlockingObserver for #3962 2024-04-11 06:08:02 -04:00
Dan Stillman
df3b9fa425 CI: Temporarily disable BlockingObserver to fix HTTP request failures 2024-04-11 05:30:01 -04:00
Adomas Venčkauskas
70d999291b Fix Dictionary window missing a scrollbar. Closes #3960 2024-04-11 10:53:54 +03:00
Abe Jellinek
398454f85b
zotero://open handler: Decode CFI and selector (#3955) 2024-04-10 19:54:04 -04:00
Tom Najdek
878fc20cec
fx115: Migrate or remove -moz-box-flex which is no longer recognized
* feed settings: part of the grid, not needed
* progress queue: migrated to flex
* tab-bar-container: already fixed in scss
* zotero-lookup-multiline-progress: migrated to flex
* zotero-lookup-textbox: removed, does nothing
* #zotero-prefpane-advanced #data-dir-path: migrated to flex
* #zotero-prefpane-sync: migrated to flex on #storage-url, removed from #storage-password to fix layout
* .search-condition: migrated to flex
* updates.css: migrated to flex
2024-04-10 17:32:04 +02:00
Dan Stillman
914a8d8956 fx-compat: Fix width of read-only data directory field in Advanced prefs 2024-04-10 07:17:21 -04:00
Martynas Bagdonas
1951c95e6b Wait until annotation saving is finished before triggering another save 2024-04-10 11:38:28 +01:00
Tom Najdek
fcc366abe2
Fix narrow input fields in "Attach link to URI" dialog 2024-04-10 11:51:09 +02:00
Adomas Venčkauskas
61db9ff0cc Advanced search: do not run search on adding condition
https://forums.zotero.org/discussion/113522/zotero-7-beta-unresponsive-during-advanced-search
2024-04-10 12:29:29 +03:00
Adomas Venčkauskas
1811c77f85 Advanced search: Fix window size issues
- Set minimum dimensions
- Make sure adding/removing conditions only resizes the window
  by the appropriate vertical amount

https://forums.zotero.org/discussion/113523/zotero-7-beta-advanced-search-window-resized-when-pressing
2024-04-10 12:29:25 +03:00
Dan Stillman
0da1702589 Revert "fx115: fix element width/height persist (#3944)"
This reverts commit ecea550a37.

It seems to be causing various UI issues, including the items list
sliding under the item pane when the collections pane is expanded
(though I can no longer reproduce that).
2024-04-09 18:22:52 -04:00
Martynas Bagdonas
81eb0b51bc Fix incorrect flex value that prevents showing reader content in window 2024-04-09 23:15:23 +01:00
windingwind
ecea550a37
fx115: fix element width/height persist (#3944) 2024-04-09 18:00:40 -04:00
windingwind
49923780ca
fx115: replace text/unicode with text/plain in clipboard code (#3945) 2024-04-09 17:47:40 -04:00
windingwind
8b37a9889a Hide item notes in reader
fix: #3941
2024-04-09 20:36:28 +08:00
Dan Stillman
d654daae28 Add try/catch when loading plugin bootstrap.js 2024-04-08 23:17:25 -04:00
Dan Stillman
591132a2d9 Add brand.ftl to update wizard 2024-04-08 05:23:41 -04:00
Tom Najdek
91cd9814e1
Improve error message in the Mendeley importer (#3900) 2024-04-08 01:46:59 -04:00
windingwind
8b30f08db8 Update warning of ItemPaneSectionElementBase
fix: #3905
2024-04-07 23:21:34 +08:00
Dan Stillman
78c0a3d050 Remove Zotero.platform and Zotero.oscpu and add Zotero.arch
`Zotero.arch` == `aarch64`, `x86_64`, `x86`
2024-04-06 04:41:04 -04:00
Dan Stillman
c6256402e4 Fix logged error when changing data directory 2024-04-05 07:39:53 -04:00
Tom Najdek
b9de90c485
Mendeley importer: Sniff for mime-type if octet-stream reported. #3454 2024-04-05 12:57:52 +02:00
windingwind
4d05367f1d
Fix progress window title bar on win and linux (#3915) 2024-04-05 06:41:33 -04:00
windingwind
808fe9b665 Fix ItemDetails notifier type key 2024-04-05 18:39:53 +08:00
Tom Najdek
9e5831a0bf
Fix misaligned spinner and flickering button in sync pref pane. Fix #3923
Using timeout in credentialsChange caused button to become momentarily disabled
making it flicker. I've verified that the delay is no longer needed and that the
button becomes disabled when using backspace to clear the login/password input field.
2024-04-05 12:05:47 +02:00
abaevbog
5f076dfeea
fx115: Citation dialog fixes (#3889)
- css tweaks for proper sizing and minor cleanup
of unused classes and properties
- added flip="none" for the panels to not bounce
around window's edges
- removed dialog's marginBottom on macOS - it doesn't
seem needed anymore
- close and reopen panel when window's height changes
on all platforms. It used to only happen on windows
but now the panel remains at it's original location on
macOS as well, so we'll always reopen the panel so
that is is positioned close to the dialog
- try to postion the panel in the middle on windows
- fix progress meter not appearing

* improved qf window drag

- not using old windowDraggingUtils since it causes
issues on windows with the mouse outrunning the window.
- instead, set -moz-window-drag: drag on dialog when
the mouse is over the red border
- added chromeutils param to the window. These are required
for dragging to work on windows and their values are
important because wrong values will cause the window to
shrink and basically disappear. 0,0,15,0 seems to work
most reliably though the reason why other values (e.g.
0,2,2,2 as on the ZoteroPane window) break window is not
clear
- added margins around the dialog on windows. moz-window-drag
doesn't seem to properly work for mouse clicks very close
to the window's edge
- with fx115, the <panel> does not follow the window
when it is dragged, so we have to hide the panel during dragging.
Unfortunately, mouseup/down events don't fire on the dialog when
moz-window-drag: drag is set on windows. Without these events,
as a workaround, we check window's position periodically and
hide/display the reference panel based on that.
- removed initial window.resizeTo() right when the content is
loaded. It's not needed and sometimes causes rendering
issues when the dialog appears shrunk.

* fx115 linux css edits

- try to make the dialog look like dialogs on other platforms.
Red background, no chrome etc. The actual window's background can't seem
to be transparant, so no round borders
- minor edits to sizing on linux
2024-04-05 12:07:24 +03:00
Tom Najdek
09eb9b4e77
fx115: Fix a couple of long tag fixer window size issues 2024-04-04 18:15:49 +02:00
Adomas Venčkauskas
34d857d310 fx115: Generate bibliography and doc prefs dialog fixes
- Use min-width: 100vw on the <dialog> element to prevent
  window.sizeToContent() from expanding the dialog unnecessarily on
  style selection
- Set the window min-width since fx115 width attribute on the window is
  ignored
- Set ids to persist position and dimensions
2024-04-04 15:24:53 +03:00
Dan Stillman
9df39c941b Fix error when unlinking account and deleting data
Fixes #3919
2024-04-04 07:10:04 -04:00
Tom Najdek
124b64f3a2
Skip importing annotations for non-PDF attachments 2024-04-03 13:21:52 +02:00
Abe Jellinek
ad661e9c8d
Preferences: Fix overflow at small window sizes (#3916) 2024-04-02 16:16:05 -04:00
Tom Najdek
5242851421
fx115: Fix "libraries to sync" appears in a tiny window
Also increased the width of the icon column to avoid truncation
2024-04-02 17:56:03 +02:00
Abe Jellinek
009f2a5607
Bring Check for Updates to front if re-triggered, unify functions (#3861) 2024-04-02 06:42:35 -04:00
Abe Jellinek
0b04a518e7
Open CSL tools as chrome and use native controls (#3908) 2024-04-02 06:39:17 -04:00
Dan Stillman
db5db03c9c HTTP.checkSecurity(): Only throw for state == 'broken' 2024-04-02 06:22:14 -04:00
Dan Stillman
423393c78b Include domain in insecure-connection error 2024-04-02 06:22:14 -04:00
Dan Stillman
35aaa013ed Move ZoteroPane.syncAlert() to Sync.Runner.alert()
And use for sync setup in prefs so that it includes the dialog header
from the sync error messages
2024-04-02 06:22:14 -04:00
Tom Najdek
c16f5d1524 fx115: Fix detecting insecure connection no longer works 2024-04-02 06:22:14 -04:00
windingwind
29c0460930
Fix ZoteroPane#loadURI with zotero: URLs (#3904) 2024-04-01 16:58:55 -04:00
Abe Jellinek
a78d1c3876
Fix window shrinking on each launch (#3910) 2024-04-01 16:33:38 -04:00
Abe Jellinek
669574b484
subprocess(): Use isAbsolute instead of checking for slash (#3911) 2024-04-01 16:22:05 -04:00
Abe Jellinek
2a114cef9b Preferences: Restore subpane Back button
It was technically still there, just offscreen. The wrapper element
was display: block, and some block layout quirk caused the button to
grow to fill the wrapper, which then put it offscreen when rotated.

This removes the wrapper and replaces it with a margin. Also fixes an
incorrect margin in RTL locales.
2024-04-01 11:57:00 -04:00
windingwind
751457268b Fix ItemDetails pinned pane with custom sections 2024-04-01 12:41:08 +08:00
windingwind
ee6b9d7af7 Refactor ItemPaneSection#_handleDataChange
Remove unused _handleDataChange and rename it to _handleItemChange
2024-04-01 11:35:36 +08:00
Tom Najdek
db499fdf2b
fx115: Fix basic viewer wrong window size 2024-03-31 13:00:41 +02:00
Tom Najdek
7bf0aa4958
fx115: Fix wizards
* Fix wrong window dimensions
* Fix missing buttons in import wizard
* Fix tiny items selector in RTF Scan Wizard
2024-03-31 12:39:12 +02:00
Dan Stillman
72168a27ec Add default value for args parameter in subprocess() 2024-03-31 05:26:12 -04:00
Dan Stillman
5d150958de Use absolute path when running sw_vers 2024-03-31 05:26:12 -04:00
Dan Stillman
a45be190ea Fix incorrect instance of PathUtils.join() instead of joinRelative() 2024-03-30 08:10:33 -04:00
Dan Stillman
26bfe3dbdc CI: Fix "invalid ELF header" error for libc.so in OS.File.unixSymLink() 2024-03-30 07:00:52 -04:00
Dan Stillman
38e4fea455 Change "Add-ons" to "Plugins" in Tools menu
Addresses #3354
2024-03-30 05:13:03 -04:00
Dan Stillman
1ae4d12a39 Tweak error text when registering custom item-pane sections 2024-03-30 04:44:32 -04:00
Dan Stillman
56e02b3cad headheader in ItemPaneManager.registerSection() 2024-03-30 04:44:20 -04:00
Abe Jellinek
4e912b84c0 fx-compat: Copy over fx115 Window menu changes (#3899) 2024-03-30 01:02:09 -04:00
Abe Jellinek
1b646fb6e2 fx-compat: Fix up Scaffold a bit
- Output pane no longer gets huge after load
- URL box grows
- Metadata grid fills available space (but still needs work re overflow)
- row-resize cursor on Tests splitter
2024-03-30 01:02:09 -04:00
Abe Jellinek
0f61646e26 fx-compat: Preferences: Fix content not growing with window 2024-03-30 01:02:09 -04:00
windingwind
4407c24329 Support tooltiptext on ItemPane custom section head buttons
Fix ItemPane custom section head button event listener
Update ItemPaneManager document
2024-03-30 01:02:08 -04:00
Dan Stillman
849ffe0133 Don't try to register command line handler if already registered
Avoids an error when reiniting during tests
2024-03-30 01:02:08 -04:00
abaevbog
89320a7ee4 fx115: fix tags autocomplete breakage (#3882)
With fx115, changes from 49fe2b98d9
made the autocomplete popup appear blank when the reader tab is opened.
Not re-creating the PopupAutoComplete in tagsBox makes the items from
autocomplete popup visible again. But it makes the autocomplete appear
below the "Add tags" popup for annotations (what 49fe2b98d9
originally fixed), and it also creates a duplicate <popupset>
with a new autocomplete panel at the bottom of the DOM every time autocomplete runs.
The duplicate <panel>s do not have an id.

Manually adding a <popupset> with a <panel> whose id="PopupAutoComplete"
does not create any duplicates and properly positions the popup.

Fixes: #3881
2024-03-30 01:02:08 -04:00
windingwind
98ed686212 fx115: fix the itemBox rows stretching on menu open (#3898) 2024-03-30 01:02:08 -04:00
abaevbog
2f4a232c41 fx115: fix tooltips for tabs, tabs menu and virtualized table (#3877)
Fix and improve tooltip logic

- fx115: move main html-tooltip outside of the deck, otherwise it only
shows up in the library tab.
- Zotero_Tooltip is not required in the tabs bar and the button of the
tag selector. Setting the tooltip attribute on the closest XUL parent
and adding title attribute makes the tooltip properly appear.
- Remove manual handling of the hover effect from tabs manu. The
hover effect doesn't stick around after drag-drop with fx115 anymore,
so it's not required. And then the usual title attribute works for the
tooltip.
- Set title instead of tooltiptext attribute in tagSelectorList
so that the tooltip appears

After zotero@8e2790e,
the pointer effects don't fire on the actual cells of the table
(only on the parent row), so the tooltips do not appear for the cells.
This is a (hopefully) temporary solution to handle mousemove events over the row
of the table, find the right cell that the mouse is over, and
use Zotero_Tooltip to manually display the tooltip.

Tweaked Zotero_Tooltip to create the fake tooltip and place it into
the DOM. Zotero_Tooltip is also imported by virtualized-table as a module
because one shouldn't have to load it in .xhtml file for every new window
where the virtualized-table is used.
2024-03-30 01:02:08 -04:00
Adomas Venčkauskas
dca7dcccab fx115: Changes for word processor plugin support 2024-03-30 00:58:58 -04:00
Adomas Venčkauskas
7276b8c50d fx115: Readd support for -file, -url and winword command line handlers 2024-03-30 00:58:58 -04:00
windingwind
e51739e1d4 fx115: fix layout on Windows 2024-03-30 00:58:58 -04:00
windingwind
a110e86cff fx115: fix main window element layout 2024-03-30 00:58:58 -04:00
windingwind
bda096a26f fx115: fix attachment box label overflow 2024-03-30 00:58:57 -04:00
windingwind
42724d13f7 fx115: fix context pane notes list layout 2024-03-30 00:58:57 -04:00
windingwind
64489b243f fx115: fix context pane sidenav render 2024-03-30 00:58:57 -04:00
windingwind
41acf4c737 Implement ItemPane custom section API
Unify properties as getter in ContextPane
Replace section `mode` with `editable`
Remove section `inTrash`
2024-03-30 00:58:57 -04:00
windingwind
b34859d882 CEify contextPane 2024-03-30 00:58:57 -04:00
windingwind
b2ad17d604 CEify itemPane 2024-03-30 00:58:57 -04:00
Dan Stillman
827bcd704d fx115: Fix "Check for Updates" window
Also:

- Tweak text to be less alarming (fixes #3074)
- Don't show "No updates found" if update was already downloaded
  (fixes #3148)

Download progress still isn't shown (#3130) but I'll fix that later
2024-03-30 00:58:57 -04:00
Dan Stillman
b42e412c4f Spaces to tabs in updates.js 2024-03-30 00:58:57 -04:00
Dan Stillman
cd3fda98d1 Fix broken tests due to protocol handler and autocomplete re-registration
For the protocol handler, unregister on reinit(). For autocomplete, just
skip registration if already registered.
2024-03-30 00:58:57 -04:00
abaevbog
349ae52b9c fx115: working autocomplete (#3789)
- autocomplete registration removed from chrome.manifest
- static registration happening in zotero.js
- tweaks to autocomplete methods to implement nsIAutoCompleteSearch based on
https://searchfox.org/mozilla-central/source/toolkit/components/autocomplete/tests/unit/test_378079.js#154
2024-03-30 00:58:57 -04:00
Abe Jellinek
8cb0c58b60 Restore old flags
Fixes reports!
2024-03-30 00:58:56 -04:00
Abe Jellinek
506482551d Register protocol handler dynamically
Fixes reader but not reports yet.
2024-03-30 00:58:56 -04:00
Bogdan Abaev
1b12b66e48 fx115: classic citation dialog fixes
- have panes for item selection occupy all available space
- use Zotero ES module to fix simple editor

search in classic citation dialog seems broken
2024-03-30 00:58:56 -04:00
Bogdan Abaev
2d3bc12ca0 fx115: lookup panel fixes
- do not resize based on scrollable content - it shrinks the panel
- add padding into the stylesheet
- remove onShowing, since it doesn't seem needed anymore
2024-03-30 00:58:56 -04:00
Bogdan Abaev
5f37ae4ab1 fx115: fix tabs menu
Fixed visuals and working drag-drop again.

Fx115 made previously used toolbarbuttons act very strange wih drag-drop:
instead of dragging the actual button, the #text node would receive
dragstart event and a single letter would end up being dragged.
During troubleshooting, elements created via document.createXULElement
had this issues while being dragged (or acted oddly in other ways, e.g.
refusing to be dragged at all).

This includes a minor rewrite to use div-s instead of XUL components.
2024-03-30 00:58:56 -04:00
Bogdan Abaev
87297f8d29 fx115 fixes
A number of style changes to fix layout for fx115.

- Make panes occupy all width/height based on layout.
- Display the tag splitter on windows and mac.
- Fix to odd fx115 behavior that gives an un-collapsed pane the
initial width of min-width * 2.
- Ensure that whenever there is a width attribute on contextPane, it will
be present in the style as well.
- Set width = 0 on zotero pane when it is not selected because it kept
preventing the contextPane from properly expanding.
- Context pane has its height changed on splitter drag.
- Set height of the context pane in stacked mode to 0 to avoid
having a blank gap after collapse.
- Remove negative margin before the toolbar if the collection tree
is collapsed on mac.
- Tweaks splitter styles to have mouse target of more than 1px.
Added positive z-index to make sure splitters are not covered by panes.
Splitter styles are somewhat unified for all platforms.
- Fix lookup panel sizing
- Quicksearch margin edits to not squize the input field.
- Collection and quick search fields layout fixed
- Use flex properties to fix layout
- fix outline display for editable-text
- fix the contextpane width going out of bounds
- stacked itemPane is visible after layout change
- In stacked view, prevent itemPane from being dragged so high that
it covers itemTree and overlaps with toolbar
2024-03-30 00:58:56 -04:00
Dan Stillman
dd745ed1aa fx115: PathUtils.normalize() requires files to exist
Unlike OS.Path.normalize()
2024-03-30 00:58:55 -04:00
windingwind
c8d49e76e5 Fix title bar layout 2024-03-30 00:58:55 -04:00
Abe Jellinek
6854ad814b fx115: Preferences: Make style manager scroll again 2024-03-30 00:58:55 -04:00
Abe Jellinek
5ca626c143 Don't resize window when Sync preferences are loaded 2024-03-30 00:58:55 -04:00
Abe Jellinek
0c5479f033 Replace TEMP_ strings in hiddenWindow.xhtml
Restores correct menuitem labels and shortcuts.
2024-03-30 00:58:55 -04:00
Dan Stillman
32793b80ae fx115: Temporarily disable missing entities for localized keys 2024-03-30 00:58:54 -04:00
Dan Stillman
f38506bccb fx115: Remove dialogOverlay.dtd include 2024-03-30 00:58:54 -04:00
Dan Stillman
65a7bf7fc0 Fix doctype declaration in updates.xhtml 2024-03-30 00:58:54 -04:00
Dan Stillman
92dfca2dc9 fx115: Temporarily disable integration loading 2024-03-30 00:58:54 -04:00
Dan Stillman
b6a597a7f9 fx115: nsIPromptService → Services.prompt 2024-03-30 00:58:54 -04:00
Dan Stillman
ef75f59037 fx115: Remove support for OS.File instance from md5Async() 2024-03-30 00:58:54 -04:00
Dan Stillman
95caebde2b Remove some old connector code 2024-03-30 00:58:54 -04:00
Dan Stillman
920461cd9d fx115: Update lots of OS.File/OS.Path uses 2024-03-30 00:58:54 -04:00
Dan Stillman
5a8a7ebccc fx115: Bundle PluralForm.jsm from older Firefox 2024-03-30 00:58:54 -04:00
Dan Stillman
f472ee6a4c fx115: Remove global.dtd includes and chromedir attribute
It only had `locale.dir`, which it looks like we can handle in different
ways now:

- CSS rules with `:-moz-locale-dir(ltr)`
- `let isLTR = document.documentElement.matches(":-moz-locale-dir(ltr)");`
2024-03-30 00:58:53 -04:00
Dan Stillman
13ab3bd87f fx115: Add command-line handling to Firefox command-line handler
XPCOM objects have to be statically registered now, so instead of
creating our own command-line handler, just stuff our code into the
Firefox one.

A few parameters require the Zotero object, which isn't available in the
Firefox CLH, so I've left those in zotero-service.js for now until we
decide how to deal with those.
2024-03-30 00:58:53 -04:00
Dan Stillman
e76c6c6a1a fx115: Update loadURI() calls to take nsIURI and remove loadURIWithFlags
https://bugzilla.mozilla.org/show_bug.cgi?id=1810141
https://bugzilla.mozilla.org/show_bug.cgi?id=1444760
2024-03-30 00:58:53 -04:00
Dan Stillman
c36f40735c fx115: Change FilePicker to Mozilla ESM style
var { FilePicker } = ChromeUtils.importESModule('chrome://zotero/content/modules/filePicker.mjs');
2024-03-30 00:58:53 -04:00
Dan Stillman
95d577beb6 fx115: Add shims for most of OS.File, OS.Path, and OS.Constants.Path
var { OS } = ChromeUtils.importESModule("chrome://zotero/content/osfile.mjs");
2024-03-30 00:58:53 -04:00
Dan Stillman
2051f08b4c fx115: Move Zotero object initialization to zotero.mjs 2024-03-30 00:58:53 -04:00
Tom Najdek
45bd374530
Fix error when dealing with invalid certificates (#3893) 2024-03-29 07:44:40 -04:00
Bogdan Abaev
0f8dce630d qf: fix insertNote dialog breakage
Fix breakage in insert note dialog caused by missing icon container after 1eaff81
2024-03-29 09:59:26 +02:00
Abe Jellinek
37a6df4ccb
editable-text: Clean up render() (#3895) 2024-03-29 01:16:58 -04:00
Abe Jellinek
f9e25675f0 editable-text: Prevent dropping text into read-only field 2024-03-28 13:13:10 -04:00
Abe Jellinek
489cee6b24 FileHandlers: Throw error when handler is missing on Windows/Linux
Not awaiting exec() has the side effect that we no longer get errors
if the executable is missing / isn't actually executable. Extract those
checks to prevent problems of the sort fixed in 63f54d3 in the future.
2024-03-27 13:52:15 -04:00
Abe Jellinek
63f54d3184 FileHandlers: Fall back when _getSystemHandler() fails
Continue to Zotero.launchFile() as intended.

https://forums.zotero.org/discussion/113179/pdfs-will-not-open-in-system-reader-when-double-clicked
2024-03-27 13:23:54 -04:00
windingwind
54b9ff6e8a
Preferences: Dispatch showing on all children (#3876) 2024-03-26 23:05:05 -04:00
Abe Jellinek
4f0e9bb9bb Scaffold: Enable syntax highlighting/formatting in Test Input 2024-03-26 16:36:05 -04:00
Abe Jellinek
a7044db15e Scaffold: Remember cookies set in browser by default
Making this configurable - it's worth testing translators to make sure
that they *aren't* dependent on some specific cookie configuration,
apart from obvious cases like login-gated sites.
2024-03-26 14:22:08 -04:00
Abe Jellinek
37ac6f9058 Update translate submodule 2024-03-26 14:19:47 -04:00
Tom Najdek
a0658b5ada
Fix styles in CSL Preview window (#3873) 2024-03-24 05:56:23 -04:00
Abe Jellinek
750f53aa53 Update translate submodule 2024-03-22 13:14:43 -04:00
Abe Jellinek
bef7ecd409 Scaffold: Print attachment URLs
Useful for debugging. This doesn't apply to tests.
2024-03-22 12:44:30 -04:00
Abe Jellinek
ff96de8723 Scaffold: Remove id field from returned items
Generates confusing diff output and isn't necessary.
2024-03-22 11:41:14 -04:00
Tom Najdek
19f4509075
Fix incorrectly colored icons in create collection dialog (#3872) 2024-03-22 01:23:31 -04:00
Martynas Bagdonas
a50b7ef04a Finish dictionary installation even if file cleanup fails (on Windows) 2024-03-19 12:03:27 +02:00
Abe Jellinek
0e087c8441 Update translate submodule 2024-03-18 15:50:30 -04:00
Abe Jellinek
cee1e3a596 Scaffold: Update copyright year automatically 2024-03-18 12:20:22 -04:00
Sebastian Karcher
6d02076a1c
Scaffold: Fix MARC template, update copyright (#3856) 2024-03-18 12:17:48 -04:00
abaevbog
1eaff8110c
Quick-format: do not hide reference panel (#3816)
Citation dialog: keep reference panel open without selection

- Reference panel remains opened while the focus is on an input
- The first item from the reference panel is no longer selected by default
to avoid unwanted items being added as a bubble
- The first item from the reference panel is selected only when the
dialog has no bubbles or when a search for a non-empty input has ran
- Shift-Enter from input or reference panel will accept the dialog's
state instead of creating a bubble
- Ensure that the reference panel reloads when a bubble is deleted
- Added button to accept the citation dialog

Some other changes:
- Z-icon and spinner/accept icon occupy the same amount
of space
- Ensure that window's width is 800px
- Set the editor's width dynamically when DOM is loaded
- Remove not used css classes and css adding margins to
z-icon.
- Do not accept/bubbleize while loading
2024-03-18 14:27:21 +02:00
Bogdan Abaev
3dc37183b4 qf: fix wrong references panel position on windows
- use dialog as the anchor, not the document element
- after the window is resized, the panel will remain
where it was, so if it's far away from the dialog,
if gets closed and re-opened to reposition it.
2024-03-18 13:00:17 +02:00
Tom Najdek
f144f3a725
Don't use link icon in tabs or open-tabs menu. Resolve #3837 2024-03-15 13:49:43 +01:00
abaevbog
e5dd25fbd5
Fix collections filter not hiding on windows (#3850)
On windows, if the cross icon from the collection filter
search-textbox is clicked, the 'blur' event fires before
the input is cleared, and the filter is never hidden.
To make sure that the search field ends up going away,
hide it if the field is empty and not focused in input
handler.

Fixes: #3840
2024-03-15 03:37:42 -04:00
Bogdan Abaev
eb2ef8a2d1 shortcuts of tab navigation capturing events
2 listeners handle shortcuts and hotkeys: bubbling ZoteroPane.handleKeyDown
and capturing Zoteropane.captureKeyDown.
We generally want shortcuts to be handled by the non-capturing listener
to avoid a conflict with lower level component that may want to handle the event
(e.g. we want to handle Escape keypress only if nothing else took care of it).
Tab navigation is an exception, since we want it to happen all the time.
For example, Ctrl+PageUp can be handled by itemTree but we want to override
it to make sure that it selects the tab regardless of other listeners.

This fixes regression after 5f0e3d5
where the tab selection logic was never reached because the event was handled
by itemTree.
2024-03-13 15:38:40 +02:00
Bogdan Abaev
e07ac555af fix collection highlight regression
- Bring back un-highlighting of collections on keydown if any other
control key besides Ctrl/Options is pressed (with better comments).
It fixes regression after 527fa5b12f
where if one presses, for example, Ctrl-Shift-A to copy an item,
collection highlighting would scroll the collection tree for no reason.

- To decrease the chance of collection highlighting being activated when
it is not intended, only highlight collections when the itemTree is focused
2024-03-13 15:38:40 +02:00
Tom Najdek
f8d59d14bc
Move tags back to beginning of item rows #3781 (#3839)
To get the current behaviour (tags after title), set
pref `extensions.zotero.ui.tagsAfterTitle` to true.
2024-03-12 19:02:52 -04:00
abaevbog
8e5732cf9c
fix to "show in library" not focusing the itemTree (#3836)
- handle additional focusElementID options value in Zotero_Tabs.select to
focus a node with the specified ID, instead of what was recorded
as last focused element
- use that parameter in ZoteroPane.selectItems to make sure that
itemTree is focused after the tab is switched to zotero-pane
- removed redundant calls to Zotero_Tabs.select('zotero-pane') after
Zotero_Pane.selectItems
2024-03-12 18:57:48 -04:00
Abe Jellinek
c31a40c749
editable-text: Make dropping text work when field is unfocused (#3730) 2024-03-12 01:38:00 -04:00
Abe Jellinek
5489b6cc4b
Scaffold: Show current Git branch in title (#3834) 2024-03-12 01:33:03 -04:00
abaevbog
844fd98c72
qf: fix suppress author checkbox click (#3832)
Use <checkbox> instead of <html:input type="checkbox"> for the
suppress author checkbox. <html:input> on mousedown on the actual box
looses focus, so the popover is immediately closed by focusout listener.
Fixes: #3830
2024-03-11 17:53:58 -04:00
windingwind
92a04fcffa
Revert editable text style on Windows (#3828) 2024-03-11 02:25:26 -04:00
windingwind
f0db826b72
Fix update.xhtml style on Windows (#3824) 2024-03-10 01:57:38 -05:00
Tom Najdek
16fa1ac893
Fix attachment icon remains after deleting attachment. Fix #3779 2024-03-08 15:22:15 +01:00
Adomas Venčkauskas
633bee45af Fix Citation dialog not working on Windows with high refresh rates
Closes #3804
2024-03-08 12:24:01 +02:00
Abe Jellinek
ac196a5944
Preferences: Don't reopen to subpane (#3802) 2024-03-07 03:09:30 -05:00
Abe Jellinek
1ca23fedb2 FileHandlers: Don't await long-running exec() on Windows/Linux
We can await /usr/bin/open on macOS because it returns as soon as the
application has begun launching, but we can't await when we exec a
program directly on other platforms.

Fixes #3799
2024-03-06 14:03:17 -05:00
Abe Jellinek
ba86e9b4c9 Preferences: Catch l10n failure and print a more helpful error 2024-03-04 11:24:32 -05:00
windingwind
23da0d70b0
Implement Windows redesign for native elements (#3727) 2024-03-02 02:51:55 -05:00
windingwind
337f54ac03
Fix attachmetsBox inTrash? (#3780) 2024-03-01 17:11:11 -05:00
abaevbog
b047f3d903
itemBox: ensure the grippy is hidden if <2 authors (#3735)
When contextmenu closes, it clears visibility style from all components.
It is added temporarily so that the options buttons do not
disappear if the mouse leaves the row. The visibility setting for
the grippy for items with only one author should be in
a separate class so that grippy is not displayed by accident.

Fixes: zotero#3732
2024-03-01 00:46:09 -05:00
Abe Jellinek
9e78957c72 Preferences: Fix freeze/double dialog when setting data directory
Addresses #3767
2024-02-29 10:45:52 -08:00
Abe Jellinek
19b12b613b Preferences: Dispatch synctopreference *before* setting preference
Matches pre-fx102 behavior.
2024-02-29 10:44:05 -08:00
Abe Jellinek
ae441c6db1 FileHandlers: Fix Acrobat and PDF Expert not opening on macOS
Fixes #3771
2024-02-29 09:24:11 -08:00
Abe Jellinek
352f71e32e
Fix zotero://open/ and FileHandlers regressions (#3761) 2024-02-29 05:08:33 -05:00
Abe Jellinek
5e10e627c3
Replace calls to keepParents() with keepTopLevel() (#3766) 2024-02-28 19:13:20 -05:00
Abe Jellinek
cbe75f1de4
New Collection dialog: Widen (#3733) 2024-02-28 01:53:32 -05:00
abaevbog
1a48e4d3f6
quick-format: post-accessibility update edits (#3753)
- Backspace from the very beginning of the input will delete the previous
bubble, as opposed to removing the input itself. If it makes it so that
two inputs are next to each other, they are merged.
- When a new input is created via a mouse click, and the current input
is empty, manually delete it right away. Waiting for the blur handler
to remove it makes it so that the bubbles shift back and forth for a moment
when a new input is added and the old input is not removed.
- Minor tweak to make sure that even if there's a 'br' before an input,
clicking before it will not make a new input and just refocus it.

Fixes: zotero#3749
2024-02-28 00:20:54 -05:00
Abe Jellinek
368e94fbb1
Locate menu: Don't show "New Tab" when external, fix bugs (#3755)
- Run label update logic once instead of repeating on every item
- Show plural attachment type when multiple attachments of same type
  are selected (instead of "Attachments")
- Fix incorrect icon and label showing when openReaderInNewWindow = true
2024-02-28 00:13:07 -05:00
Abe Jellinek
e1538d9f10
Use HTTPS when opening DOIs via Locate menu and double-click (#3757) 2024-02-27 17:42:08 -05:00
Abe Jellinek
50331b9a04 editable-text: Accurately set height limits from min/max-lines
2ex wasn't quite right, so let's use the actual line-height when
possible.
2024-02-27 11:34:02 -08:00
Dan Stillman
98fc32a65e Add Tamil locale from Transifex
Contributed by @TamilNeram
2024-02-27 07:01:49 -05:00
abaevbog
5f0e3d550b
make shortcuts keypress listener non-capturing (#3743)
- ZoteroPane.handleKeyDown does not capture events. It is not strictly
necessary now but it helps to avoid future issues such as one solved in
b15fb36f1b. One benefit from this now is
if one tabs onto a toolbarbutton that opens a menu in contextPane (e.g.
an options button in itemBox), clicks space to open the menu and then
escape to close it, this will keep focus where it was, while the capturing
listener would immediately shift the focus to the reader.
- Removed shift-tab specific case from the handler. It looks like it
was handling the shift-tab in the following scenarios:
from notes search bar (can just be handled by Tab),
from "Return to notes list button" in note editor toolbar (it's no longer there),
from a child of zotero-view-item e.g. itembox. (does not apply,
since zotero-view-item itself is a focusable scrollable area)
- use reader.focus() instead of reader.focusFirst() in tab handler,
since focusFirst() focuses the <body> of the browser and it's not interactable.
2024-02-27 01:52:40 -05:00
Abe Jellinek
bbab56837e Set Abstract section summary to abstract 2024-02-27 01:50:40 -05:00
Abe Jellinek
cb420fb570 Add support for collapsible-section summaries 2024-02-27 01:50:40 -05:00
abaevbog
0007d077cc
accessibility improvements for quick format dialog (#3464)
- removed all cursor-related logic. Instead, insert a new input component
each time the user wants to type. The input remain between bubbles
and focusing on one will open the reference panel. Leaving the input hides
the reference panel.
- during drag-drop reordering, lock the editor height so that it doesn't
get out of sync with the window.
- removed the iframe, since it was no longer needed.
- keyboard navigation: Home/End will place an input at the start/end
of the editor and focus it. Tab focuses the last active input if any, or
the input in the end otherwise. Shift-Tab from the editor focuses the
dropdown button if it is active. Tab from the input will focus the first
entry of the reference list. Tab from the reference list will focus the
active input. Shift-ArrowLeft/Right from focused bubble will swap the bubble
with its neighbor. ArrowDown/Up from bubble will open/close the citation dialog.
- when a reference item is selected, previously active input is re-focused.
- aria-properties to have voiceover, JAWS and NVDA read bubbles, inputs and
reference items, as well as announce hints about available keypresses.
- typing from bubble or the reference panel will refocus previously active
input
- different minor updates to make the functionality less janky
- refactoring of refreshing and resizing of the reference panel to
be more straightforward and to only do it when necessary.
E.g. clicking on a bubble and closing the
popover after will not rerun search and just display the old results.
- some throttling logic so that two escape keypresses one after another
when the itemPopover is open do not close the entire dialog
- renamed variables: qfb=dialog, qfe=editor, panel=itemPopover
- use short form of locator string for bubbles
2024-02-27 01:00:14 -05:00
Martynas Bagdonas
5dcaf65757 Don't show context pane toggle in standalone reader window 2024-02-26 20:43:20 +02:00
Tom Najdek
cffb5cdd4b
Fix best attachment type sometimes missing. Fix #3740 2024-02-26 13:14:27 +01:00
Abe Jellinek
52856ae696 Fully block all HTTP requests in the reader 2024-02-24 02:21:06 -05:00
Abe Jellinek
6095ee91ff Generalize RemoteResourceBlockingObserver -> BlockingObserver 2024-02-24 02:21:06 -05:00
Abe Jellinek
a7d59a90d3
Unify attachment opening code and support EPUB/snapshot note links (#3705) 2024-02-23 06:38:11 -05:00
Tom Najdek
b1333d0e9d
More attachment type icons in the item tree (#3645) 2024-02-23 06:11:40 -05:00
windingwind
ae8cbdf3b7
Support keyboard navigation in attachment preview (#3739) 2024-02-23 05:58:09 -05:00
Abe Jellinek
93536a1592 Fix autocomplete issues caused by stopping 'change' propagation
Only stop propagation when the window is inactive, and don't fire the
synthetic event on blur. Does the same thing as efd7ec6 was intended to
do, but in a less heavy-handed way.

Fixes #3734
2024-02-22 16:39:20 -05:00
Abe Jellinek
efd7ec6dc2 Fix title/abstract saving when window becomes inactive
We weren't stopping 'change' from propagating upwards when the change hadn't
actually been committed yet, and the pane-header and abstract-box CEs
listen to that event instead of 'blur'.
2024-02-22 09:56:28 -05:00
abaevbog
26fd57398c
do not focus contextPane after it's opened (#3728)
When contextPane is toggled open, keep the focused element unchanged

Fixes: #3716
2024-02-22 02:36:51 -05:00
Abe Jellinek
b15fb36f1b editable-text: Don't put 'null'/'undefined' in the field
In case something deleted dataset.initialValue after focus and before we
received this keypress.

Addresses #3725. Might still want to rework that listener, but this
change made sense regardless, since the same kind of race condition
could be triggered elsewhere.
2024-02-21 16:07:02 -05:00
Abe Jellinek
07296b4506 Merge: Count last word when calculating most frequent words
Not that it really matters.
2024-02-21 15:12:14 -05:00
Abe Jellinek
69d9b01b6e Preferences: Exclude HTML hidden="" elements from search 2024-02-21 14:58:49 -05:00
Abe Jellinek
71a85e4d06 Preferences: Delete menulist observer after disconnecting 2024-02-21 12:47:03 -05:00
Martynas Bagdonas
38a42d3c91 Properly trigger shifted annotation sync after deleting PDF pages 2024-02-21 15:04:24 +02:00
Abe Jellinek
64b8c7b250
SingleFile actor: Skip cross-origin frames to fix error (#3721) 2024-02-21 06:43:45 -05:00
Abe Jellinek
130a72af1b
Fix empty Quick Copy locale dropdown (without a freeze) (#3720) 2024-02-21 06:42:59 -05:00
Martynas Bagdonas
2918e5d1a4 Don't use sortable property when inserting a citation inside note editor
Fixes #3723
2024-02-21 09:12:49 +02:00
Abe Jellinek
1f599283df
Fix indexing files with text content types that Firefox won't display (#3708) 2024-02-19 05:11:16 -05:00
Tom Najdek
24cb38cfc8
Fix attachment column icon flickering upon selection (#3695) 2024-02-19 05:04:28 -05:00
abaevbog
826774b1f7
keyboard navigation for tag selector (#3615)
- Tab from the tags list or shift-tab from the tags filter field
focuses the first non-disabled tag. If there are none, the tags are
skipped and the focus moves directly to the input field or the tags list.
- Arrow Right/Left move focus between tags skipping over disabled tags
- Space/Enter clicks on the selected tag
- Space/Enter click on the search button when focused
2024-02-19 04:57:03 -05:00
Tom Najdek
1b751d675b
Trim spaces from values in getFileBaseNameFromItem (#3711) 2024-02-19 04:43:19 -05:00
abaevbog
61d3c5c85c
revision of focus management through the reader (#3687)
- brought back escape behavior that just focuses the reader whenever
a reader tab is opened, wherever it comes from (unless it's from an
element that is .open - like an item type menu, in which case just
let it get closed)
- removed moving focus from contextPane title to sync button on shift-tab
- using new reader methods onIframeTab, onToolbarShiftTab to move focus
to the contextPane on tab from reader iframe or to the sync button
on shift-tab from the toolbar

So now, the focus path is: tab bar -> tabs menu -> sync button -> reader
toolbar -> reader sidebar -> reader scrollable area -> contextPane title
(if visible) or tab bar
2024-02-19 04:03:00 -05:00
windingwind
294835b995
Fix csl editor style in dark theme (#3702) 2024-02-19 03:35:57 -05:00
Dan Stillman
5940b63908 Revert "Fix empty Quick Copy locale dropdown"
This reverts commit 0dfe276d9b.

Causing a hang when some people mouse over the Export tab:

https://forums.zotero.org/discussion/111956/zotero-7-beta-freezes-in-the-settings-panel
2024-02-19 03:32:53 -05:00
Martynas Bagdonas
009a2ca38a Properly trigger note image attachment sync and display it when finished 2024-02-16 14:38:17 +02:00
Martynas Bagdonas
d47ed5f747 Hide unnecessary menu separators in Tools menu 2024-02-16 12:31:58 +02:00
Tom Najdek
abe8def0f1
Trim leading/trailing space in filename format string. Fix #3701 2024-02-16 10:17:03 +01:00
Adomas Venčkauskas
f548efde15 Citation dialog: Allow citing the same item multiple times
Removed as part of #3544 but it turns out there's good uses for it:
https://forums.zotero.org/discussion/111831/multiple-citations-of-the-same-source

The same item still won't appear multiple times in the Open Documents
section, but you can look for it in your Library or Cited section
2024-02-15 08:47:57 +02:00
Abe Jellinek
fbc82f687d updateLocaleList: Append menuitem to menupopup, not parent menulist
Appending to the menulist sort of worked - the text of the added
menuitem appeared in the menulist label, albeit off to the right -
but the item didn't actually show in the menu and didn't get removed
on subsequent calls.
2024-02-14 16:38:54 -05:00
Abe Jellinek
ba5d34876e Don't fire syncfrompreference when value hasn't changed
Except during initialization. Fixes an infinite loop when the Quick Copy
locale is set to a custom value.
2024-02-14 16:36:22 -05:00
Abe Jellinek
0dfe276d9b Fix empty Quick Copy locale dropdown
Closes #3254
2024-02-14 16:09:06 -05:00
Abe Jellinek
43d9d604a6 Fix blockRemoteResources passed to wrong method
After OOPification of HiddenBrowser.jsm. The constructor accepts
blockRemoteResources, the load() method ignores it.
2024-02-14 11:25:44 -05:00
Adomas Venčkauskas
beb7b51cb3 Adjust the titlebar/menubar xml and styling.
Reasoning:
- Different Linux DEs specify different titlebar button (min, max,
close) locations which we did not and could not support before.
- Previous approach copied from Firefox depended on custom offsets
specified in CSS instead of allowing the browser engine to place
elements

Changes:
- Titlebar and menubar no longer collapsed into each other with a
negative margin, instead just a single flexbox (on macOS the titlebar
is still collapsed into the tab bar)
- Support for -moz-gtk-csd-reversed-placement to correctly place the
titlebar buttons on Linux
- Removed/changed some code copied from Firefox that does not apply or
uses the wrong selectors
- Fixed the display of Linux Unity DE buttons with icons appearing outside
of button borders
- Removed the Z in the titlebar on Linux since only a few DEs use that.
- Aligned the tabbar on Linux and Windows to the left margin of the
window.
2024-02-14 06:24:00 -05:00
Adomas Venčkauskas
34b389d118 Fix the startup missing data directory picker not working 2024-02-14 13:22:41 +02:00
Abe Jellinek
f729172bdd Fix error after setting custom file handler 2024-02-13 13:58:49 -05:00
Abe Jellinek
872e7b2427 Item/attachment box: Prevent default label focus/blur behavior
Since ceb1dd7da3 added a tabindex on
#zotero-view-item, clicking anywhere outside a field in the pane will
blur the active field. That's an improvement, but it conflicted with our
custom label behavior - when an active field's label is clicked, we want
to blur it and keep it blurred, but the default behavior is to re-focus
it on mouseup.

Fix by preventing the default focus behavior on mousedown/click.
2024-02-09 14:38:56 -05:00
Abe Jellinek
6a39980a97 Save Abstract edits when switching items
Since itemPane.js sets mode before item, the editable-text's value would
get reset before save() ran.

Not touching the header since we're replacing that with an item-box
field (which does not have this bug) soon anyway.

Fixes #3679
2024-02-09 12:21:56 -05:00
Adomas Venčkauskas
0aea17581e Citation Dialog: Show selected notes in the Add Note dialog
Closes #3642
2024-02-09 14:24:05 +02:00
Adomas Venčkauskas
d852185950 Citation Dialog: Fix open documents being matched multiple times.
Closes #3690
2024-02-09 14:17:43 +02:00
Abe Jellinek
4a91df1b1d
Add test for SandboxItem#setExtra() (#3572) 2024-02-09 09:34:47 +02:00
Adomas Venčkauskas
90282b3739 Clear item tree pivot after switching collections. Closes #3551
After switching collections and shift-clicking on the item tree
will no longer group-select from the pivot of the previous selection
2024-02-08 15:03:02 +02:00
Bogdan Abaev
527fa5b12f linux: collection highlight on control
On Linux, trigger collection highlighting on Control instead of Alt
to not interfere with the menubar.

Addresses: #3683
2024-02-08 10:07:36 +02:00
Adomas Venčkauskas
88482bd776 Do not register the menu access key handlers multiple times 2024-02-07 17:18:56 +02:00
Bogdan Abaev
fc5aa1a6ba win: no collection highlight if input is focused
So that collections do not randomly get highlighted when one clicks
Ctrl-C/Ctrl-V to copy-paste something in the itemPane
2024-02-06 15:20:43 -05:00
abaevbog
ceb1dd7da3
additions to keyboard nav for toolbar buttons and reader (#3602)
- handle space and enter in zotero pane to always click on toolbarbutton.
It ensures consistent behavior across all components to avoid Enter
triggering click on some buttons but not others.
- address the issue of focus not being able to leave the reader once it
gets there. On Escape, when reader is opened, instead of re-focusing the reader,
focus the selected tab. From there, Enter will focus the reader, and tabbing
allows you to reach the itemPane.
- Tab/Shift-tab moves focus between Sync button and itemPane when
reader is opened
2024-02-06 12:51:06 -05:00
Bogdan Abaev
e69ce9b86c avoid ztabindex overlap when new creator is added
Increated the ztabindex offset for non-creator rows, so that when a new
creator is added but not saved yet, there is no two elements with
the same ztabindex which would break tab-based navigation

Fixes: #3666
2024-02-06 12:44:29 -05:00
Bogdan Abaev
15d5dcaaee itemBox creator names fixes
- Instead of setting default name as the value of the field when a
creator name is empty, set the default names as a placeholder so that
it shows up only when the field is empty.
- Have the creator options show up before the creator is saved so that
the mode can be switches before saving the creator.
- Re-do of capitalizeCreatorName to not break when one of the names is focused.

Fixes: #3610
2024-02-06 12:44:29 -05:00
abaevbog
3a2cd70684
update tab when collection row is updated (#3673)
When saved search, collection or feed is renamed, update the zotero-pane
tab so that it has the new title.

Fixes: #3664
2024-02-06 02:23:09 -05:00
Abe Jellinek
de89e82e75 Make Tags/Related sections functional in note windows
Fixes #3581
2024-02-05 17:11:42 -05:00
Dan Stillman
f29f87ad5b Fix missing "Edit Saved Search" label
Regression from f8108aca45

https://forums.zotero.org/discussion/111486/zotero-7-beta-edit-saved-search-from-right-click-on-a-saved-search-collection
2024-02-04 06:22:50 -05:00
Abe Jellinek
6486c509ad Fix customElements.js error when editing saved search
Fixes #3672
2024-02-02 15:32:55 -05:00
windingwind
3acef799f5
Fix custom elements import (#3639)
Fixes #3600
2024-02-02 04:02:08 -05:00
abaevbog
a74c86d948
collection search tooltiptext and placeholder cleanup (#3632)
Fluent tooltiptext for collection search button and placeholder
for collection search input
2024-02-02 03:58:27 -05:00
abaevbog
4a3a80b4f8
editable-text min/max-lines attributes (#3649)
- min/max-lines attribute on editable-text determines how tall the field
can/has to be
- if max-lines is not specified (or is below 1), the textarea will expand
as much as needed without overflow
- removed hardcoded height and variables from css, substituted them with
usage of these attributes for consistency
- No fields have any max-lines at this point, so all fields will expand as
needed
2024-02-02 03:53:23 -05:00
Abe Jellinek
c10dabcbba Ignore editable-text blurs caused by window becoming inactive
Fixes #3588
2024-02-02 03:39:55 -05:00
Abe Jellinek
6b1940cebb Add generic menu for all unfocused editable-texts 2024-02-02 03:39:55 -05:00
Abe Jellinek
af79e9c405 Ignore base-mapped fields more robustly 2024-02-02 03:39:55 -05:00
Abe Jellinek
b8c1b7c139 Fix DOI View Online/Copy as URL regression
Was opening/copying the bare DOI, not the URL.
2024-02-02 03:39:55 -05:00
Abe Jellinek
fa6e6f9458 Make existing edit context menus more context-aware
- Don't show the default text editing context menu when right-clicking
  an unfocused editable-text
- In item box/header context menus, only show Copy and Paste (plus
  field-specific transform options) when unfocused

Fixes #3619
2024-02-02 03:39:35 -05:00