Commit graph

13471 commits

Author SHA1 Message Date
Abe Jellinek
524560799f Fix references to numbered --accent-blue colors 2024-01-24 04:03:35 -05:00
Abe Jellinek
6724ff8378 Annotation rows: Make transparent border visible
Only works with outline instead of border for some reason.
2024-01-24 04:03:35 -05:00
Abe Jellinek
c78739bf2f Update and improve attachment-row initialization
- Actually show un-deleted rows as context rows within trash
- Add all rows, hide ones that shouldn't be shown
- Check whether attachment is file before calling getAnnotations()
  - Fixes errors on update and new link attachments being shown as empty rows
2024-01-24 04:03:35 -05:00
Abe Jellinek
e4b329bffc Only scroll/pin section on left-click
To prevent a right-click on the Info section (which has no context menu) from
scrolling to it, along with other weirdness.
2024-01-24 04:03:35 -05:00
Abe Jellinek
c16a2d4b05 Resize editable-text after Esc pressed 2024-01-24 04:03:35 -05:00
Abe Jellinek
b2eed77914 Limit editable-text height
Current values are kind of arbitrary and could be made configurable.
2024-01-24 04:03:31 -05:00
Abe Jellinek
c50a3a8615 Use system color for Debug Output background 2024-01-24 04:03:28 -05:00
Abe Jellinek
dacfe68a28 Fix overscroll growing the item pane on Windows 11 2024-01-24 04:03:26 -05:00
Abe Jellinek
ef608c094a Remove Windows .zotero-view-item style overrides 2024-01-24 04:03:23 -05:00
Abe Jellinek
9b80d9def5 Always pad clicky-item .icon/.label as in design 2024-01-24 04:03:21 -05:00
Abe Jellinek
4a15b2633a Remove section title highlight on sidenav click 2024-01-24 04:03:18 -05:00
Tom Najdek
a8a1b8fe06 Reduce gap between tags in the tag selector 2024-01-24 04:03:17 -05:00
Abe Jellinek
19b78e2b20 Implement new pane selection algorithm, remove bottom padding 2024-01-24 04:03:17 -05:00
abaevbog
cc9d58e6be adjust spacing within tag selector
1. Decrease the gap after colored tags.
2. In compact mode, decrease the splitter height.
2024-01-24 04:03:17 -05:00
windingwind
97996310ea Show accessKey when press alt 2024-01-24 04:03:14 -05:00
Abe Jellinek
663c1e62fd editable-text: Set overflow-wrap on ::after and input
There really are too many different wrapping properties
2024-01-24 04:03:13 -05:00
Tom Najdek
f67efc90f1 Fix: Tags now have a proper drop target size 2024-01-24 04:03:13 -05:00
Tom Najdek
8627e92cb4 Fix items table potentially not rendering after merge
In d4f8c7c an entry has been removed from zotero.properties that is still being
used in items table. If `numNotes` column is visible, items table would not
render.

Instead of re-adding to zotero.properties, I've migrated this string to
zotero.ftl to fix this problem.
2024-01-24 04:03:13 -05:00
windingwind
cec0592e14 Use SelectedItem color on non-Windows 2024-01-24 04:03:13 -05:00
windingwind
82a9aee21c Unify item tree & v-table style on Windows & Linux 2024-01-24 04:03:13 -05:00
Tom Najdek
f5be1b26f4 Remove cell padding from the first-column 2024-01-24 04:03:13 -05:00
Tom Najdek
60dedf7d95 Fix items table header bottom border 2024-01-24 04:03:13 -05:00
Abe Jellinek
bf72c9d828 Notes/Tags/Related redesign 2024-01-24 04:03:13 -05:00
Tom Najdek
374b5337d8 Items table redesign 2024-01-24 04:03:13 -05:00
windingwind
d16abb1a15 Remove duplications of chevron-12.svg 2024-01-24 04:03:13 -05:00
windingwind
077214a327 Add menu icons and unify Open PDF/EPUB/Snapshot options 2024-01-24 04:03:13 -05:00
Bogdan Abaev
a7fe2130ce no override of arrow up/down actions in toolbar search fields 2024-01-24 04:03:12 -05:00
Bogdan Abaev
f8a6b82c63 collection search 2024-01-24 04:03:12 -05:00
windingwind
7da00957ef Unify tab bar on Windows/Linux 2024-01-24 04:03:12 -05:00
Tom Najdek
464c37e66f Don't use color for background of emoji tags 2024-01-24 04:03:12 -05:00
Tom Najdek
7fe5f0145d Restyle tags splitter 2024-01-24 04:03:12 -05:00
Tom Najdek
9ff76d2dd9 Restyle Tag Selector
* Render a colored dot for colored tags
* Improve spacing and positioning, especially on 2x screens
* Add scss map for tag colors in light/dark scheme
* Add support for compact/comfortable in tag selector
* Restyle filter box, add a placeholder and a new icon
2024-01-24 04:03:12 -05:00
Tom Najdek
ff115b0873 Tweak search component to accept data-/aria- props 2024-01-24 04:03:12 -05:00
Tom Najdek
ce64147aa8 Add "pick" and "omit" utils
Helpful when dealing with props in react components
2024-01-24 04:03:12 -05:00
Tom Najdek
54ce9e8b3c Add color-scheme mixin 2024-01-24 04:03:12 -05:00
Tom Najdek
a68424658a Fix a bug in the build process
Fixes TypeError: Cannot read properties of undefined (reading 'toFixed')
2024-01-24 04:03:12 -05:00
Abe Jellinek
fe6fdd3ff6 Ensure require() is available to CEs 2024-01-24 04:03:08 -05:00
abaevbog
71af85adb3 minor fixes to keyboard navigation
1. Swap focus direction for ArrowUp and ArrowDown events when applicable.
ArrowUp = Shift-Tab, ArrowDown - Tab.
2. Remove ArrowLeft, ArrowRight event listeners from quicksearch menus
to not prevent cursor navigation within the actual text field.
3. Tweaks to fix advanced search mode from quicksearch when " is typed.
2024-01-24 04:03:02 -05:00
Abe Jellinek
6bc97a6af6 Extract field transform menu and use for title header
And extract edit context menu building code into a separate function in
`editMenuOverlay.js` so we can build menus on top of it.
2024-01-24 03:42:43 -05:00
Abe Jellinek
17f758d0cf Use Zotero.isMac in customElements CE patch
AppConstants is occasionally undefined - not sure why.
2024-01-24 03:42:43 -05:00
Abe Jellinek
810402c9c7 Implement pane header, non-tabbed layout, collapsible sections, and new abstract box 2024-01-24 03:42:43 -05:00
Abe Jellinek
d2694bfba7 Add attachmentEPUB[Link] to getImageSrc() 2024-01-24 03:42:43 -05:00
Abe Jellinek
a2f259d14c Use item type CSS icons in more places
.icon-item-type is now global, with extra styling to handle row selection when
it's inside the item tree.

getImageSrc() is still used for progress windows, which is probably OK for now
because those don't stay on screen for very long. I've updated it to return SVGs
based on the current UI color scheme.

Other code uses treeitem-* images directly; getting rid of those references will
cause a lot of conflicts and be a bit more involved than this initial pass, so
I'll put that in a separate PR.
2024-01-24 03:42:43 -05:00
abaevbog
200e1d7564 toolbar and keyboard navigation updates
1. Toolbarbuttons changes:
	1. “New Library” moved from toolbar to File menu
	2. “New note” on click makes a standalone note
	3. “New attachment” on click adds stored copy of a file
	4. Menuitems from old note or attachment menus moved to the File menu
	5. “Advanced search” removed. Sync and Locate buttons moved to the top-right corner (Locate - temporarily)
	6. Added “Opened tabs” toolbarbutton
	7. Updated tooltips
2. Added a toolbarbutton that reveals collection search field on click. Search field is hidden on blur if empty. Keyboard accessibility via tab/shift-tab.
3. Tab based navigation restructuring. For each component, create a mapping of target ids with desired focus destination for each relevant keyboard event and use that to determine where to move focus next. Fixed bugs with focus wraparound not working when a note or attachment is opened in contextMenu.
4. Make quick-search dropmarker a sibling of the textfield. QuickSearchTextbox does not extend search-textfield anymore. It serves as a container to house dropmarker and textfield as siblings. This is needed to remove focus ring from quick search textbook when focus moves onto the dropmarker.
5. Separate toolbars for item and collection trees. Removed unused code manually setting the width of toolbar section
6. Focusable tabs + keyboard navigation:
	1. Shift-tab from opened tabs menu moves focus to the currently opened tab
	2. When a tab has focus, use left/right arrows to select tabs, or CMD/Ctrl + arrows to move focus between tabs
	3. Enter or Space on a focused tab will select it if needed and move focus to the contentPane of the reader of this tab
	4. Shift-tab from tabs wraps focus around to itemTree or itemPane
7. “New collection” creates collection contextually within currently selected library or collection.
8. Items pane minimum width increase to avoid quicksearch from being squashed
9. Do not move focus to title field of itemBox after itemTypeMenu is closed with ESC.
10. Display all itemTypes without "Show more" submenu in "New Item" meunu. Removed "Store Copy of File" and "Link to File" from "New Item" menu.
2024-01-24 03:42:42 -05:00
Tom Najdek
3f91729141 collections tree redesign
- new icons
- new twisty (also for items tree)
- new mixin focus-states that can be re-used for less boilerplate
- dark/white compatible with tweaks for when tree is focused (these changes also affect items tree)
- removed macOS specific behaviour (blue-ish background, gradient for selected row)
- border-radius on highlight + spacing tweaks
- tweaked colors and fonts
- Support for "compact"/"comfortable"
2024-01-24 03:42:42 -05:00
Tom Najdek
78d82d22cc Fix item type icons broken on 2x screens
Icons preloading introduced in 247755c5 overrides entire background
property, not just background-image. On 2x screens (and anywhere else
where svg icons need to be scaled) icons need property `background-size:
contain` to be displayed correctly. This previously came from
`.icon-css` class but have been overriden by code generated in
`svgicon`, so to fix this, these properties need to be added to the
`svgicon`.
2024-01-24 03:42:42 -05:00
Abe Jellinek
8b9d8b1be5 Add compact/comfortable utility mixins 2024-01-24 03:42:38 -05:00
Abe Jellinek
c6ad31ca0a Preload variants of item type SVG icons 2024-01-24 03:42:34 -05:00
Tom Najdek
c7286194f8 Convert theme to css variables
* Opt-in for light and dark color schemes
* Convert scss variables in _light.scss to css variables
* Add _dark.scss for dark color scheme
* Remove unused, theme-related variables
2024-01-24 03:42:29 -05:00
Tom Najdek
03d10f7de7 Switch to new svg icons for item types 2024-01-24 03:39:09 -05:00