Overview of Projects

The CollectionSpace UI is just one of several related projects being developed simultaneously. This document gives a high-level overview of these projects.

CollectionSpace JS

All of the projects are written in JavaScript, and intended for use in JavaScript environments like web browsers and Node.js. Collectively, the suite of projects is called CollectionSpace JS, or cspace.js for short. The code name "Drydock" is used in JIRA, and also refers to this suite.

CollectionSpace JS includes four projects. A "project" is also sometimes referred to as a "repository" (in git parlance), a "package" (in Node.js/npm parlance), or a "module" (in JavaScript parlance). The full name of each project (and its GitHub repository name) has the form cspace-project.js, but the ".js" extension is usually omitted in documentation.

cspace-api.js

The cspace-api project implements a library for accessing the CollectionSpace REST API. It presents a relatively low level JavaScript API that mirrors the CRUD operations available via the REST API, while managing the details of the HTTP connection. The library works in both browsers and Node.js. cspace-api may be used by any JavaScript program that wants to access CollectionSpace resources, especially when HTTP basic authentication is sufficient. To use token-based authentication, the cspace-client library may be a better choice, since that library handles the details of managing those tokens.

cspace-client.js

The cspace-client project implements a CollectionSpace client library. It is a wrapper around cspace-api that provides a session-oriented API with login and logout functions. Authentication tokens are transparently managed within each logged-in session. cspace-client works in browsers and Node.js, and it may be used by any JavaScript program that wants to access CollectionSpace resources. In browsers,tokens are persistently stored for automatic re-login.

cspace-refname.js

The cspace-refname project implements a library of functions that may be used to read and manipulate CollectionSpace ref names. It may be used in web browsers and in Node.js programs.

cspace-layout.js

The cspace-layout project implements a library of user interface components for web browsers that may be used to lay out UI elements in various useful ways. This includes components to render children inside of rows, columns, and tables, as well as in popups or modal dialogs.

cspace-input.js

The cspace-input project implements a library of user interface components for web browsers that display and allow entry of CollectionSpace data. It includes simple components like plain text and calendar date inputs, as well as more complex ones like structured date, authority-controlled autocomplete, and number pattern generator inputs. These components are designed to be uncoupled to implementation details of the CollectionSpace UI application, so they may be used in other browser-based JavaScript applications that require data entry components.

cspace-ui.js

The cspace-ui project implements a browser-based, single-page JavaScript application that is the standard user interface for CollectionSpace. It uses cspace-client to communicate with the CollectionSpace server, cspace-input and cspace-layout to display data, and cspace-refname to work with ref names.

More to come...

Additional projects will be created as groups of functionality are identified that may be reused in other applications.