• Stars
    star
    142
  • Rank 258,495 (Top 6 %)
  • Language
    JavaScript
  • License
    Other
  • Created almost 12 years ago
  • Updated 3 months ago

Reviews

There are no reviews yet. Be the first to send feedback to the community and the maintainers!

Repository Details

CI

Web Library

This is zotero.org's Web Library capable of being installed/run on other websites.

Web Library is a single-page application implemented in Javascript. It uses Zotero API via CORS requests and requires keys configured in order to access private libraries.

Installation

  1. Clone git repository into target web directory (git clone --recursive https://github.com/zotero/web-library.git)
  2. Ensure up-to-date version of Node is used. It should be possible to build Web Library with any recent version of Node, see .nvmrc for recommended version of Node (usually current LTS). On systems where nvm is available it's possible to use nvm install and nvm use to install and switch to a preferred version of node.
  3. Run npm install to install dependencies
  4. Tweak configuration in src/html/index.html and/or src/html/embedded.html. Default configuration displays a public library in read-only mode. In order to edit a library, change userId and provide apiKey.
  5. Run development proces: npm start
  6. Point browser at http://localhost:8001/ to see the demo
  7. Modyfing source files will trigger incremental build

Production-ready version can be built with npm run build and served with npm run serve.

Configuration

Web Library reads configuration from a DOM node with ID zotero-web-library-config. See example config in src/html/index.html. To access private libraries, userId and apiKey must be provided. It's also possible to configure Web Library to only display public libraries, in which case libraries object must be populated and it must include value for defaultLibraryKey as well as includeMyLibrary set to false.

Build targets

There are two build targets controlled by TARGET environment variable: zotero and embedded. Former produces a single-page app as seen on zotero.org, latter produces a web-library widget that can be embedded on other pages. Embedded build is currently considered experimental. It's also possible to build both variants using TARGET set to all (default behaviour).

Build & Development options

The following environment variables are recognized:

  • DEBUG - if set to 1 extra info about produced bundle will be printed to the console. Increases build time.
  • EMBEDDED - if set to 1 dev server will default to src/html/embedded.html, otherwise it will serve src/html/index.html.
  • LOCALE_CACHE_TIME - advanced usage, see scripts/fetch-locale.cjs.
  • NODE_ENV - used by build scripts to control various debug options. See package.json.
  • PORT - port on which development server listens for incoming connections.
  • STYLES_CACHE_TIME - advanced usage, see scripts/build-styles-json.cjs.
  • TARGET - see Build targets above.
  • TRANSLATE_URL - URL where to proxy translation requests.
  • USE_HTTPS - if set to 1 dev server will use HTTPS. Requires certificates, see scripts/server.cjs.

More Repositories

1

zotero

Zotero is a free, easy-to-use tool to help you collect, organize, annotate, cite, and share your research sources.
JavaScript
9,904
star
2

translators

Zotero Translators
JavaScript
1,229
star
3

zotero-connectors

Chrome, Firefox, Edge, and Safari extensions for Zotero
JavaScript
503
star
4

zotero-android

Zotero for Android
Kotlin
276
star
5

dataserver

Zotero Data Server
PHP
270
star
6

zotero-ios

Zotero for iOS
Swift
223
star
7

reader

PDF/EPUB/HTML reader for Zotero
JavaScript
121
star
8

translation-server

A Node.js-based server to run Zotero translators
JavaScript
121
star
9

zotero-standalone-build

Zotero client build utility
C++
120
star
10

citeproc-rs

CSL processor in Rust.
Rust
70
star
11

zoterobib

ZoteroBib is a free online bibliography generator from the makers of Zotero
JavaScript
68
star
12

zotero-libreoffice-integration

Zotero LibreOffice integration
Java
64
star
13

citeproc-js-server

Web service to generate citations and bibliographies using citeproc-js
JavaScript
60
star
14

zotero-bits

CSL-related community feedback for Zotero
56
star
15

make-it-red

Sample plugin for Zotero 7
JavaScript
47
star
16

zotero-word-for-windows-integration

Zotero Word for Windows integration
C++
46
star
17

zotero-schema

JSON representation of the Zotero data model
JavaScript
43
star
18

scaffold

Zotero translator creation IDE
Shell
38
star
19

translation-server-old

Server-side Zotero translation based on Mozilla xpcshell (deprecated)
JavaScript
35
star
20

publications

Easily display Zotero items on a webpage
JavaScript
32
star
21

zotero-google-docs-integration

JavaScript
32
star
22

note-editor

Note editor for Zotero
JavaScript
31
star
23

zotero-api-node

Zotero API client for Node.js
JavaScript
29
star
24

safari-app-extension

Swift
29
star
25

web-components

JS components used throughout zotero.org outside the web library
JavaScript
28
star
26

zotero-hello-world

Sample plugin for Zotero for Firefox
JavaScript
25
star
27

zotero-word-for-mac-integration

Zotero Word for Mac integration
Objective-C
23
star
28

pdf-worker

JavaScript
22
star
29

translate

Browser standalone zotero translator
JavaScript
16
star
30

cross-poppler

Compiles modified Poppler PDF tools for macOS, Windows and Linux
C++
15
star
31

styles-repo

Zotero styles page
PHP
13
star
32

zotero-build

Zotero client build scripts
Python
11
star
33

bundled-styles

CSL styles bundled with Zotero client
Shell
10
star
34

utilities

Zotero utility code
JavaScript
10
star
35

stream-server

Zotero Streaming API Server
JavaScript
9
star
36

cross-xpdf

C++
9
star
37

arkivo

JavaScript
8
star
38

epub.js

JavaScript
7
star
39

s3-full-text-indexer

JavaScript
5
star
40

full-text-indexer

Lambda functions to process full text from S3 and index in Elasticsearch
JavaScript
5
star
41

attachment-proxy

Allows online viewing of Zotero attachments
JavaScript
4
star
42

arkivo-sufia

A Zotero/Arkivo plugin to connect to Project Hydra services
JavaScript
3
star
43

provo

Zotero translator test automation
Shell
3
star
44

zfs-purge

Purge unused storage files from S3
JavaScript
3
star
45

eslint-config-zotero

ESLint shareable config for Zotero projects
JavaScript
3
star
46

markdown-translator-builder

Builds Markdown translator for Zotero notes export
JavaScript
3
star
47

client-downloads

Generate download links and update manifests for Zotero client
PHP
3
star
48

tinymce-clean-server

Node.js HTTP server to clean HTML using TinyMCE parsing/filtering logic
JavaScript
3
star
49

full-text-es-to-s3-migration

Script to migrate full-text content from Elasticsearch to S3
JavaScript
2
star
50

web-common

JavaScript
2
star
51

full-text-extractor

JavaScript
1
star