Action it, tag it, sorted.
Actions & Tags (AT), also known as Zotero Tag, is a plugin for Zotero.
AT can help you:
Download the latest release (.xpi file) from:
Note: If you're using Firefox as your browser, right click the xpi and select "Save As.."
In Zotero click "Tools" in the top menu bar and then click "Addons"
Go to the Extensions page and then click the gear icon in the top right.
Select Install Add-on from file.
Browse to where you downloaded the .xpi file and select it.
Restart Zotero, by clicking "restart now" in the extensions list where the plugin is now listed.
This plugin is designed to be easy to use. Start in 1 minutes!
unread
We have prepared a simple example for you to get started. The example is called unread
, which will tag the item with unread
when you add it to the library (create, import, or from zotero-connector) and remove the tag when you close the item.
Steps:
/unread
!Don't know where to find the tag? Check the "Tags" tab in the right panel. See also Zotero Doc:adding tags to items
Now that you have learned how to use the example, you can create your own actions!
Steps to open the list of actions:
Now you can see a list of actions.
The community contributed some useful actions via custom script
. Take an example of copy item link
, You can use it by:
customScript
, assign shortcut
and menu label
.Paste the script to the data
field of the action.
Click "Save" to save the action.
Great! Now you can use the action by:
Right click the item in the library and select the action in the menu -> trigger action -> Copy item link.
Use the shortcut you assigned to the action.
Check your clipboard and you will find the link of the item!
You can find more actions by searching community.
An action has the following settings:
Data: The action data.
Click
โคค
in the edit action popup to open editor for multi-line data.
Shortcut: The shortcut that triggers the action. Leave it empty if you don't want to use a shortcut.
Click shortcut button in the edit action popup to record custom shortcut from keyboard.
Menu Label: The label of the menu item to be displayed in the right-click menu in the library / reader popup menu.
Leave empty to hide in the menu. Sort by the menu label alphabetically.
Enabled: Whether the action is enabled. Uncheck it to disable the action.
You can colorize your tags by assigning a color to the tag in the tag selector. See Zotero Doc:colored tags for more details.
Use cases:
/unread
tag so that you can easily find the unread items in your library.โญ๏ธ
, โญ๏ธโญ๏ธ
, โญ๏ธโญ๏ธโญ๏ธ
, ... tags so that you can easily sort the items by their importance.โ ๏ธ Warning: Custom script is a powerful feature. It can do anything that you can do in the Zotero client. Use it with caution!
All the scripts shared in the community will be manually reviewed by me to make sure it is not malicious. However, they may still cause data loss if you does not use them properly! Do not run the script that you do not trust!
You can run custom script with the customScript
operation. The script will be executed in the context of the Zotero client.
Share & find custom scripts here: https://github.com/windingwind/zotero-actions-tags/discussions/categories/action-scripts
You can use the following variables in the script:
triggerType
: The trigger type. Can be menu
, shortcut
, createItem
, openFile
, closeTab
, createAnnotation
, createNote
, appendAnnotation
, appendNote
, programStartup
, mainWindowLoad
, mainWindowUnload
.
item
: The target item. Might be null
if the action is triggered by an event that doesn't have a target item, e.g. shortcut in the Zotero client without selecting an item. (Not available in programStartup
, mainWindowLoad
, and mainWindowUnload
event)
items
: The target items[] array. Only available in menu/shortcut-triggered actions, otherwise it's null
.
When selecting multiple items in the library, the action will be triggered once for all items (items=[...], item=undefined
) and then one by one for each item (items=[], item=...
). You can use the items
variable to get the selected items array and avoid duplicate executions.
Please always use the
items
instead ofZoteroPane.getSelectedItems()
. The action can be triggered from entrances outside the library, where the items are not fromZoteroPane
.
collection
: The target collection object, is only available when triggered by the collection menu.
require
: The require
function to import global variables. Use const window = require('window')
to import the window
variable.
window
: Only available in mainWindowLoad
and mainWindowUnload
event. In other events, you should use require('Zotero').getMainWindow()
to import the window
variable.
This plugin is built based on the Zotero Plugin Template. See the setup and debug details there.
To startup, run
git clone https://github.com/windingwind/zotero-actions-tags.git
cd zotero-actions-tags
npm install
npm run build
The plugin is built to ./build/*.xpi
.
Use this code under AGPL. No warranties are provided. Keep the laws of your locality in mind!
I'm windingwind, an active Zotero(https://www.zotero.org) plugin developer. Devoting to making reading papers easier.
Sponsor me to buy a cup of coffee. I spend more than 24 hours every week coding, debugging, and replying to issues in my plugin repositories. The plugins are open-source and totally free.
If you sponsor more than $10 a month, you can list your name/logo here and have priority for feature requests/bug fixes!
Thanks peachgirl100, [Juan Gimenez](), and other anonymous sponsors!
If you want to leave your name here, please email me or leave a message with the donation.