All notable changes to this project will be documented in this file.
Changelog entries are classified using the following labels (from Keep a changelog):
Project versions conform to Semantic Versioning
-
Added: for new features -
Bumped: updated dependencies, only minor or higher will be listed -
Changed: for changes in existing functionality -
Deprecated: for once-stable features removed in upcoming releases -
Fixed: for any bug fixes -
Removed: for deprecated features removed in this release
- added a few more examples of LinkedArt data from the PMA
- adjusted the logic around 'getPrimaryName' to fallback to
Nameentries when a qualified name isn't used and no qualification is entered
- Added a few more constants to the constants file
- adjusts the readme to link to the issues and contributions section on GitHub
- exposed the constants and the AAT file to the standard export. This is useful for those who want to use AND/OR or other internal constants as well as common LinkedArt fields e.g.:
// import all the constants
import aat from "@thegetty/linkedart.js/aat";
import constants from "@thegetty/linkedart.js/constants";
// import selected constants
import { REFERRED_TO_BY } from "@thegetty/linkedart.js/constants";
- adjusted the
carriedOutBylogic to be able to support more general relationships than just production
- added constants for
encountered_by - added a sample record from yale
- fixed a bug with
_getAssignedPropertywhere we were expecting an object to always be returned but the new data model includes an array instead.
- modified many of our mid-level functions to take an options object instead of feeding in optional params. This is a potentially breaking change for
getClassified,getClassifiedBy,getClassifiedAs,getClassifiedAsWithClassification,getClassifiedByWithClassification,getFieldValuesByClassification,getObjectsClassifiedAsWithClassification,getObjectsClassifiedByWithClassification,getValueByClassification, andgetValuesByClassification. This change introduces the ability to pass in anoperatoras well as thelanguage, andlanguageOptions.
- exported all public functions from ObjectHelpers
- updated JSDoc
- added
getWorkTypesto ObjectHelpers - added
getClassificationsto ObjectHelpers
- added
getMaterialStatementsto ObjectHelpers
- added
getDescriptionsto LinkedArtHelpers - added test cases from the LinkedArt Showcase
- Changed
getValuesByClassificationto return [] when nothing's found instead ofundefined
- added
getCulturesto ObjectHelpers
getDigitalImages: added function for getting URLs to digital imagesgetRightsStatement: added function for getting rights statementsgetCopyrightStatements: added function for getting copyright/licensing statementsgetRightsAssertion: added function for getting rights assertions, (e.g., from https://rightsstatements.org/)getAcknowledgementStatements: added function for getting acknowledgment/credit statements- added tests and test data
- added a function for getting the production date for an object
getProductionTimespans
- refactored shared methods to separate out constants into a dedicated file
- refactored imports to be specific to more easily facilitate bundling
- added
getAccessionNumbersto ObjectHelpers
- added a function for managing fields with parts in BasicHelpers
normalizeFieldWithParts - added a function to get a field out of a production
getFieldPartSubfieldwhich can be used for similar top-level fields (like creation)
- adds
ObjectHelpers.jswith initialgetDimensionDescriptionshelper and tests
- added functions for handling primary names of objects
getPrimaryNameandgetPrimaryNames, configurable with different language and aat values - added a function for normalizing AAT values
normalizeAatIdbetween aat:#### and http://vocabs.getty.edu/aat/####
- fixed duplicate content in the jsdoc
- updated JSDoc theme to make it easier to read
- added additional languages to the
DEFAULT_LANGUAGE_LOOKUP - added dedicated
lookupAatFromIsoandlookupIsoFromAatmethods to help with resolution of languages.
- updated the license to be BSD-3
- updated some of the intro text
- Added a .github/CONTRIBUTING.md file with some pull request guidelines, and added a link in the readme so that users can navigate to it easily
- Added information to jsdoc_home.md
- Replaced the default readme with one more specific to our library
- Jsdoc for helper descriptions have been updated and more @examples have been added
- changed
_getClassificationsWithNestedClassand_getObjectWithNestedClassto use a helper function_getObjectsAndClassificationsWithNestedClassto avoid repetitive logic - moved all private helper functions used in
LinkedArtHelpers.jsto the end of the file to avoid clutter among exported functions
- expanded test coverage
-
renamed the following functions to fit naming convention:
- resourcesByClassifications -> getClassified
- classfiedAs -> getClassifiedAs
- classifiedBy -> getClassifiedBy
- checkEmptyField -> normalizeFieldToArray
- normalizeLanguage -> normalizeLanguageId
- doesLanguageMatch -> doesObjectLanguageMatch
-
the following functions were renamed and made @private as well
- resourceParamToArray ->_convertToArrayIfNeeded
- classificationsByNestedClass -> _getClassificationsWithNestedClass
- objectsByNestedClass -> _getObjectWithNestedClass
- getClassifiedAsWithClassification and getClassifiedByWithClassification were added as public helpers for _getClassificationsWithNestedClass which help get a classification that is classified by a specified value.
- getObjectsClassifiedAsWithClassification and getObjectsClassifiedByWithClassification were added as public helpers for _getObjectWithNestedClass which help get an object with a classification that is classified by a specified value.
- checkEmptyArray was removed as it is no longer needed and it's inconsistent return could be confusing, use normalizeFieldToArray instead
- Added
getObjectPartsto LinkedArtHelpers - this helper takes in a LinkedArt object and a requested field. It checks to see if that field exists and if it has anypartvalues. It will either return an array of parts, the requested field or an empty array.
- This version was
unpublished.
- Initial fork from Getty LinkedArt Library.