Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Update deps #70

Merged
merged 4 commits into from
Nov 15, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
7 changes: 7 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,12 @@
# @digitalbazaar/cborld ChangeLog

## 5.2.0 - 2023-11-dd

### Changed
- Update dependencies:
- Use `cborg@4`.
- Use `uuid@9`.

## 5.1.0 - 2023-11-15

### Added
Expand Down
8 changes: 4 additions & 4 deletions lib/Compressor.js
Original file line number Diff line number Diff line change
@@ -1,18 +1,18 @@
/*!
* Copyright (c) 2021 Digital Bazaar, Inc. All rights reserved.
* Copyright (c) 2021-2023 Digital Bazaar, Inc. All rights reserved.
*/
import * as cborg from 'cborg';
import {CborldError} from './CborldError.js';
import {FIRST_CUSTOM_TERM_ID, KEYWORDS} from './keywords.js';
import {CborldEncoder} from './codecs/CborldEncoder.js';
import {CborldError} from './CborldError.js';
import {ContextEncoder} from './codecs/ContextEncoder.js';
import {inspect} from './util.js';
import {MultibaseEncoder} from './codecs/MultibaseEncoder.js';
import {Transformer} from './Transformer.js';
import {UriEncoder} from './codecs/UriEncoder.js';
import {VocabTermEncoder} from './codecs/VocabTermEncoder.js';
import {XsdDateEncoder} from './codecs/XsdDateEncoder.js';
import {XsdDateTimeEncoder} from './codecs/XsdDateTimeEncoder.js';
import {inspect} from './util.js';
import {FIRST_CUSTOM_TERM_ID, KEYWORDS} from './keywords.js';

export const TYPE_ENCODERS = new Map([
['@id', UriEncoder],
Expand Down
6 changes: 3 additions & 3 deletions lib/Decompressor.js
Original file line number Diff line number Diff line change
@@ -1,17 +1,17 @@
/*!
* Copyright (c) 2021 Digital Bazaar, Inc. All rights reserved.
* Copyright (c) 2021-2023 Digital Bazaar, Inc. All rights reserved.
*/
import * as cborg from 'cborg';
import {FIRST_CUSTOM_TERM_ID, KEYWORDS} from './keywords.js';
import {CborldError} from './CborldError.js';
import {ContextDecoder} from './codecs/ContextDecoder.js';
import {inspect} from './util.js';
import {MultibaseDecoder} from './codecs/MultibaseDecoder.js';
import {Transformer} from './Transformer.js';
import {UriDecoder} from './codecs/UriDecoder.js';
import {VocabTermDecoder} from './codecs/VocabTermDecoder.js';
import {XsdDateDecoder} from './codecs/XsdDateDecoder.js';
import {XsdDateTimeDecoder} from './codecs/XsdDateTimeDecoder.js';
import {inspect} from './util.js';
import {FIRST_CUSTOM_TERM_ID, KEYWORDS} from './keywords.js';

export const TYPE_DECODERS = new Map([
['@id', UriDecoder],
Expand Down
4 changes: 2 additions & 2 deletions lib/codecs/Base58DidUrlEncoder.js
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
/*!
* Copyright (c) 2021 Digital Bazaar, Inc. All rights reserved.
* Copyright (c) 2021-2023 Digital Bazaar, Inc. All rights reserved.
*/
import {CborldEncoder} from './CborldEncoder.js';
import {Token, Type} from 'cborg';
import {CborldEncoder} from './CborldEncoder.js';
import {decode as decodeBase58} from 'base58-universal';

const SCHEME_TO_ID = new Map([
Expand Down
4 changes: 2 additions & 2 deletions lib/codecs/ContextEncoder.js
Original file line number Diff line number Diff line change
@@ -1,9 +1,9 @@
/*!
* Copyright (c) 2021 Digital Bazaar, Inc. All rights reserved.
* Copyright (c) 2021-2023 Digital Bazaar, Inc. All rights reserved.
*/
import {Token, Type} from 'cborg';
import {CborldEncoder} from './CborldEncoder.js';
import {URL_TO_ID} from './registeredContexts.js';
import {Token, Type} from 'cborg';

export class ContextEncoder extends CborldEncoder {
constructor({context, appContextMap} = {}) {
Expand Down
4 changes: 2 additions & 2 deletions lib/codecs/HttpUrlEncoder.js
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
/*!
* Copyright (c) 2021 Digital Bazaar, Inc. All rights reserved.
* Copyright (c) 2021-2023 Digital Bazaar, Inc. All rights reserved.
*/
import {CborldEncoder} from './CborldEncoder.js';
import {Token, Type} from 'cborg';
import {CborldEncoder} from './CborldEncoder.js';

export class HttpUrlEncoder extends CborldEncoder {
constructor({value, secure} = {}) {
Expand Down
4 changes: 2 additions & 2 deletions lib/codecs/MultibaseDecoder.js
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
/*!
* Copyright (c) 2021 Digital Bazaar, Inc. All rights reserved.
* Copyright (c) 2021-2023 Digital Bazaar, Inc. All rights reserved.
*/
import {CborldDecoder} from './CborldDecoder.js';
import {Base64} from 'js-base64';
import {CborldDecoder} from './CborldDecoder.js';
import {encode as encodeBase58} from 'base58-universal';

// this class is used to encode a multibase encoded value in CBOR-LD, which
Expand Down
4 changes: 2 additions & 2 deletions lib/codecs/MultibaseEncoder.js
Original file line number Diff line number Diff line change
@@ -1,10 +1,10 @@
/*!
* Copyright (c) 2021 Digital Bazaar, Inc. All rights reserved.
* Copyright (c) 2021-2023 Digital Bazaar, Inc. All rights reserved.
*/
import {Token, Type} from 'cborg';
import {Base64} from 'js-base64';
import {CborldEncoder} from './CborldEncoder.js';
import {decode as decodeBase58} from 'base58-universal';
import {Token, Type} from 'cborg';

// this class is used to encode a multibase encoded value in CBOR-LD, which
// actually means transforming a multibase-encoded string to bytes
Expand Down
4 changes: 2 additions & 2 deletions lib/codecs/UriDecoder.js
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
/*!
* Copyright (c) 2021 Digital Bazaar, Inc. All rights reserved.
* Copyright (c) 2021-2023 Digital Bazaar, Inc. All rights reserved.
*/
import {CborldDecoder} from './CborldDecoder.js';
import {Base58DidUrlDecoder} from './Base58DidUrlDecoder.js';
import {CborldDecoder} from './CborldDecoder.js';
import {HttpUrlDecoder} from './HttpUrlDecoder.js';
import {UuidUrnDecoder} from './UuidUrnDecoder.js';

Expand Down
4 changes: 2 additions & 2 deletions lib/codecs/UriEncoder.js
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
/*!
* Copyright (c) 2021 Digital Bazaar, Inc. All rights reserved.
* Copyright (c) 2021-2023 Digital Bazaar, Inc. All rights reserved.
*/
import {CborldEncoder} from './CborldEncoder.js';
import {Base58DidUrlEncoder} from './Base58DidUrlEncoder.js';
import {CborldEncoder} from './CborldEncoder.js';
import {HttpUrlEncoder} from './HttpUrlEncoder.js';
import {UuidUrnEncoder} from './UuidUrnEncoder.js';

Expand Down
4 changes: 2 additions & 2 deletions lib/codecs/UuidUrnEncoder.js
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
/*!
* Copyright (c) 2021 Digital Bazaar, Inc. All rights reserved.
* Copyright (c) 2021-2023 Digital Bazaar, Inc. All rights reserved.
*/
import {CborldEncoder} from './CborldEncoder.js';
import {Token, Type} from 'cborg';
import {CborldEncoder} from './CborldEncoder.js';
import {parse} from 'uuid';

export class UuidUrnEncoder extends CborldEncoder {
Expand Down
4 changes: 2 additions & 2 deletions lib/codecs/VocabTermEncoder.js
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
/*!
* Copyright (c) 2021 Digital Bazaar, Inc. All rights reserved.
* Copyright (c) 2021-2023 Digital Bazaar, Inc. All rights reserved.
*/
import {CborldEncoder} from './CborldEncoder.js';
import {Token, Type} from 'cborg';
import {CborldEncoder} from './CborldEncoder.js';
import {UriEncoder} from './UriEncoder.js';

export class VocabTermEncoder extends CborldEncoder {
Expand Down
4 changes: 2 additions & 2 deletions lib/codecs/XsdDateEncoder.js
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
/*!
* Copyright (c) 2021 Digital Bazaar, Inc. All rights reserved.
* Copyright (c) 2021-2023 Digital Bazaar, Inc. All rights reserved.
*/
import {CborldEncoder} from './CborldEncoder.js';
import {Token, Type} from 'cborg';
import {CborldEncoder} from './CborldEncoder.js';

export class XsdDateEncoder extends CborldEncoder {
constructor({value, parsed} = {}) {
Expand Down
4 changes: 2 additions & 2 deletions lib/codecs/XsdDateTimeEncoder.js
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
/*!
* Copyright (c) 2021 Digital Bazaar, Inc. All rights reserved.
* Copyright (c) 2021-2023 Digital Bazaar, Inc. All rights reserved.
*/
import {CborldEncoder} from './CborldEncoder.js';
import {Token, Type} from 'cborg';
import {CborldEncoder} from './CborldEncoder.js';

export class XsdDateTimeEncoder extends CborldEncoder {
constructor({value, parsed} = {}) {
Expand Down
4 changes: 2 additions & 2 deletions lib/encode.js
Original file line number Diff line number Diff line change
@@ -1,9 +1,9 @@
/*!
* Copyright (c) 2020-2021 Digital Bazaar, Inc. All rights reserved.
* Copyright (c) 2020-2023 Digital Bazaar, Inc. All rights reserved.
*/
import * as cborg from 'cborg';
import {inspect} from './util.js';
import {Compressor} from './Compressor.js';
import {inspect} from './util.js';

/**
* Encodes a given JSON-LD document into a CBOR-LD byte array.
Expand Down
14 changes: 7 additions & 7 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -45,25 +45,25 @@
},
"dependencies": {
"base58-universal": "^2.0.0",
"cborg": "^1.9.4",
"cborg": "^4.0.5",
"js-base64": "^3.7.2",
"uuid": "^8.3.2"
"uuid": "^9.0.1"
},
"devDependencies": {
"c8": "^7.11.3",
"c8": "^8.0.1",
"chai": "^4.3.6",
"chai-bytes": "^0.1.2",
"cross-env": "^7.0.3",
"eslint": "^8.17.0",
"eslint-config-digitalbazaar": "^3.0.0",
"eslint-plugin-jsdoc": "^39.3.2",
"eslint-plugin-unicorn": "^42.0.0",
"eslint-config-digitalbazaar": "^5.0.1",
"eslint-plugin-jsdoc": "^46.9.0",
"eslint-plugin-unicorn": "^49.0.0",
"karma": "^6.3.20",
"karma-chai": "^0.1.0",
"karma-chrome-launcher": "^3.1.1",
"karma-mocha": "^2.0.1",
"karma-mocha-reporter": "^2.2.5",
"karma-sourcemap-loader": "^0.3.8",
"karma-sourcemap-loader": "^0.4.0",
"karma-webpack": "^5.0.0",
"mocha": "^10.0.0",
"mocha-lcov-reporter": "^1.3.0",
Expand Down
4 changes: 2 additions & 2 deletions tests/test.spec.js
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
/*!
* Copyright (c) 2020-2022 Digital Bazaar, Inc. All rights reserved.
* Copyright (c) 2020-2023 Digital Bazaar, Inc. All rights reserved.
*/
import {
default as chai,
Expand All @@ -8,7 +8,7 @@ import {
import {default as chaiBytes} from 'chai-bytes';
chai.use(chaiBytes);

import {encode, decode} from '../lib/index.js';
import {decode, encode} from '../lib/index.js';

describe('cborld', () => {
describe('encode', () => {
Expand Down
Loading