From 2dccbffb2e4cb76ab37e0388923140fd2a6617a3 Mon Sep 17 00:00:00 2001 From: Kay Robbins <1189050+VisLab@users.noreply.github.com> Date: Mon, 23 Dec 2024 09:15:31 -0600 Subject: [PATCH] Updated the index values and the package number --- bids/index.js | 8 +++---- bids/types/tsv.js | 28 ----------------------- index.js | 6 +---- package-lock.json | 30 +++++++++++++------------ package.json | 2 +- validator/index.js | 56 +++++++++++++++++++++++----------------------- 6 files changed, 49 insertions(+), 81 deletions(-) diff --git a/bids/index.js b/bids/index.js index bc8426cf..729bb851 100644 --- a/bids/index.js +++ b/bids/index.js @@ -1,7 +1,7 @@ import buildBidsSchemas from './schema' import validateBidsDataset from './validate' import { BidsJsonFile, BidsSidecar } from './types/json' -import { BidsEventFile, BidsTabularFile, BidsTsvFile } from './types/tsv' +import { BidsTabularFile, BidsTsvFile } from './types/tsv' import BidsDataset from './types/dataset' import { BidsHedIssue, BidsIssue } from './types/issues' import BidsHedSidecarValidator from './validator/sidecarValidator' @@ -10,7 +10,6 @@ import BidsHedTsvValidator from './validator/tsvValidator' export { BidsDataset, BidsTsvFile, - BidsEventFile, BidsTabularFile, BidsJsonFile, BidsSidecar, @@ -25,14 +24,13 @@ export { export default { BidsDataset, BidsTsvFile, - BidsEventFile, BidsTabularFile, BidsJsonFile, BidsSidecar, BidsIssue, BidsHedIssue, - BidsHedSidecarValidator: BidsHedSidecarValidator, - BidsHedTsvValidator: BidsHedTsvValidator, + BidsHedSidecarValidator, + BidsHedTsvValidator, buildBidsSchemas, validateBidsDataset, } diff --git a/bids/types/tsv.js b/bids/types/tsv.js index 10e10848..ad0f919e 100644 --- a/bids/types/tsv.js +++ b/bids/types/tsv.js @@ -157,34 +157,6 @@ export class BidsTsvRow extends BidsTsvElement { } } -/** - * An event in a BIDS TSV file. - */ -export class BidsTsvEvent extends BidsTsvElement { - /** - * The TSV rows making up this event. - * @type {BidsTsvRow[]} - */ - tsvRows - - /** - * Constructor. - * - * @param {BidsTsvFile} tsvFile The file this row belongs to. - * @param {BidsTsvRow[]} tsvRows The TSV rows making up this event. - */ - constructor(tsvFile, tsvRows) { - const hedString = tsvRows.map((tsvRow) => tsvRow.hedString).join(', ') - const tsvLine = tsvRows - .map((tsvRow) => tsvRow.tsvLine) - .flat() - .join(', ') - const onset = tsvRows[0].onset ? tsvRows[0].onset : undefined - super(hedString, tsvFile, onset, tsvLine) - this.tsvRows = tsvRows - } -} - /** * A BIDS events.tsv file. * diff --git a/index.js b/index.js index 415ea575..56c08d91 100644 --- a/index.js +++ b/index.js @@ -1,11 +1,7 @@ import bids from './bids' -import converter from './converter' -import validator from './validator' -export { bids, converter, validator } +export { bids } export default { bids, - converter, - validator, } diff --git a/package-lock.json b/package-lock.json index 54a4afff..84018c82 100644 --- a/package-lock.json +++ b/package-lock.json @@ -2216,10 +2216,11 @@ } }, "node_modules/cross-spawn": { - "version": "7.0.3", - "resolved": "https://registry.npmjs.org/cross-spawn/-/cross-spawn-7.0.3.tgz", - "integrity": "sha512-iRDPJKUPVEND7dHPO8rkbOnPpyDygcDFtWjpeWNCgy8WP2rXcxXL8TskReQl6OrB2G7+UJrags1q15Fudc7G6w==", + "version": "7.0.6", + "resolved": "https://registry.npmjs.org/cross-spawn/-/cross-spawn-7.0.6.tgz", + "integrity": "sha512-uV2QOWP2nWzsy2aMp8aRibhi9dlzF5Hgh5SHaB9OiTGEyDTiJJyx0uy51QXdyWbtAHNua4XJzUKca3OzKUd3vA==", "dev": true, + "license": "MIT", "dependencies": { "path-key": "^3.1.0", "shebang-command": "^2.0.0", @@ -4124,12 +4125,13 @@ } }, "node_modules/micromatch": { - "version": "4.0.5", - "resolved": "https://registry.npmjs.org/micromatch/-/micromatch-4.0.5.tgz", - "integrity": "sha512-DMy+ERcEW2q8Z2Po+WNXuw3c5YaUSFjAO5GsJqfEl7UjvtIuFKO6ZrKvcItdy98dwFI2N1tg3zNIdKaQT+aNdA==", + "version": "4.0.8", + "resolved": "https://registry.npmjs.org/micromatch/-/micromatch-4.0.8.tgz", + "integrity": "sha512-PXwfBhYu0hBCPw8Dn0E+WDYb7af3dSLVWKi3HGv84IdF4TyFoC0ysxFd0Goxw7nSv4T/PzEJQxsYsEiFCKo2BA==", "dev": true, + "license": "MIT", "dependencies": { - "braces": "^3.0.2", + "braces": "^3.0.3", "picomatch": "^2.3.1" }, "engines": { @@ -6970,9 +6972,9 @@ } }, "cross-spawn": { - "version": "7.0.3", - "resolved": "https://registry.npmjs.org/cross-spawn/-/cross-spawn-7.0.3.tgz", - "integrity": "sha512-iRDPJKUPVEND7dHPO8rkbOnPpyDygcDFtWjpeWNCgy8WP2rXcxXL8TskReQl6OrB2G7+UJrags1q15Fudc7G6w==", + "version": "7.0.6", + "resolved": "https://registry.npmjs.org/cross-spawn/-/cross-spawn-7.0.6.tgz", + "integrity": "sha512-uV2QOWP2nWzsy2aMp8aRibhi9dlzF5Hgh5SHaB9OiTGEyDTiJJyx0uy51QXdyWbtAHNua4XJzUKca3OzKUd3vA==", "dev": true, "requires": { "path-key": "^3.1.0", @@ -8375,12 +8377,12 @@ "dev": true }, "micromatch": { - "version": "4.0.5", - "resolved": "https://registry.npmjs.org/micromatch/-/micromatch-4.0.5.tgz", - "integrity": "sha512-DMy+ERcEW2q8Z2Po+WNXuw3c5YaUSFjAO5GsJqfEl7UjvtIuFKO6ZrKvcItdy98dwFI2N1tg3zNIdKaQT+aNdA==", + "version": "4.0.8", + "resolved": "https://registry.npmjs.org/micromatch/-/micromatch-4.0.8.tgz", + "integrity": "sha512-PXwfBhYu0hBCPw8Dn0E+WDYb7af3dSLVWKi3HGv84IdF4TyFoC0ysxFd0Goxw7nSv4T/PzEJQxsYsEiFCKo2BA==", "dev": true, "requires": { - "braces": "^3.0.2", + "braces": "^3.0.3", "picomatch": "^2.3.1" } }, diff --git a/package.json b/package.json index 39dd98bc..a1bf1b2f 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "hed-validator", - "version": "3.15.5", + "version": "4.0.0", "description": "A JavaScript validator for HED (Hierarchical Event Descriptor) strings.", "main": "./dist/commonjs/index.js", "exports": { diff --git a/validator/index.js b/validator/index.js index 62a8d57c..4b66a8c0 100644 --- a/validator/index.js +++ b/validator/index.js @@ -1,28 +1,28 @@ -import { BidsDataset, BidsEventFile, BidsJsonFile, BidsSidecar, validateBidsDataset } from '../bids' -import { validateHedDataset } from './dataset' -import { validateHedEvent, validateHedString } from './event' -import { buildSchemas } from '../schema/init' - -export { - BidsDataset, - BidsEventFile, - BidsJsonFile, - BidsSidecar, - validateBidsDataset, - validateHedDataset, - validateHedEvent, - validateHedString, - buildSchemas, -} - -export default { - BidsDataset, - BidsEventFile, - BidsJsonFile, - BidsSidecar, - validateBidsDataset, - validateHedDataset, - validateHedEvent, - validateHedString, - buildSchemas, -} +// import { BidsDataset, BidsEventFile, BidsJsonFile, BidsSidecar, validateBidsDataset } from '../bids' +// import { validateHedDataset } from './dataset' +// import { validateHedEvent, validateHedString } from './event' +// import { buildSchemas } from '../schema/init' +// +// export { +// BidsDataset, +// BidsEventFile, +// BidsJsonFile, +// BidsSidecar, +// validateBidsDataset, +// validateHedDataset, +// validateHedEvent, +// validateHedString, +// buildSchemas, +// } +// +// export default { +// BidsDataset, +// BidsEventFile, +// BidsJsonFile, +// BidsSidecar, +// validateBidsDataset, +// validateHedDataset, +// validateHedEvent, +// validateHedString, +// buildSchemas, +// }