Skip to content

Commit 9c0c7d6

Browse files
authored
Package Updates (#197)
1 parent 857cb2a commit 9c0c7d6

8 files changed

Lines changed: 3463 additions & 2091 deletions

File tree

.eslintignore

Lines changed: 0 additions & 12 deletions
This file was deleted.

.eslintrc.json

Lines changed: 0 additions & 3 deletions
This file was deleted.

CHANGELOG.md

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,8 @@
1+
### 1.42.0 - 2025-06-24
2+
- Package updates
3+
- Update ESLint configuration
4+
- Specify `containerPath` on `Query.Command`. Already supported by server-side.
5+
16
### 1.41.2 - 2025-05-28
27
- Update `isBoolean` to directly check for boolean type and be tolerant of undefined/null value.
38
- Switch `isArray` to be `Array.isArray`. Deprecate.

eslint.config.mjs

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,2 @@
1+
import config from '@labkey/eslint-config';
2+
export default config;

package-lock.json

Lines changed: 3434 additions & 2062 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

package.json

Lines changed: 10 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "@labkey/api",
3-
"version": "1.41.2",
3+
"version": "1.42.0",
44
"description": "JavaScript client API for LabKey Server",
55
"scripts": {
66
"build": "npm run build:dist && npm run build:docs",
@@ -35,25 +35,25 @@
3535
"registry": "https://labkey.jfrog.io/artifactory/api/npm/libs-client"
3636
},
3737
"devDependencies": {
38-
"@babel/core": "7.26.10",
39-
"@babel/plugin-transform-modules-commonjs": "7.26.3",
40-
"@labkey/eslint-config-base": "0.0.15",
38+
"@babel/core": "7.27.4",
39+
"@babel/plugin-transform-modules-commonjs": "7.27.1",
40+
"@labkey/eslint-config": "1.0.0",
4141
"@tinyhttp/content-disposition": "2.2.2",
42-
"@types/jest": "29.5.14",
42+
"@types/jest": "30.0.0",
4343
"@types/nise": "1.4.5",
4444
"ajv": "~8.17.1",
4545
"cross-env": "7.0.3",
4646
"gh-pages": "6.3.0",
47-
"jest": "29.7.0",
48-
"jest-environment-jsdom": "29.7.0",
47+
"jest": "30.0.2",
48+
"jest-environment-jsdom": "30.0.2",
4949
"jest-teamcity-reporter": "0.9.0",
5050
"nise": "6.1.1",
5151
"rimraf": "6.0.1",
52-
"ts-jest": "29.3.2",
52+
"ts-jest": "29.4.0",
5353
"ts-loader": "9.5.2",
54-
"typedoc": "0.28.3",
54+
"typedoc": "0.28.5",
5555
"typescript": "5.8.3",
56-
"webpack": "5.99.6",
56+
"webpack": "5.99.9",
5757
"webpack-cli": "6.0.1"
5858
}
5959
}

src/labkey/dom/Utils.spec.ts

Lines changed: 7 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -30,7 +30,12 @@ describe('dom/Utils', () => {
3030
it('submits form', () => {
3131
// Arrange
3232
const formId = 'postToAction-form';
33-
const onSubmit = jest.fn().mockImplementation(e => e.preventDefault());
33+
34+
// js-dom does not implement HTMLFormElement.prototype.submit
35+
// See https://github.com/jsdom/jsdom/issues/1937
36+
const onSubmit = jest.fn();
37+
jest.spyOn(HTMLFormElement.prototype, 'submit').mockImplementation(onSubmit);
38+
3439
const inject = '<script>alert("8(");</script>';
3540
const url = '#';
3641
const formData = {
@@ -53,9 +58,7 @@ describe('dom/Utils', () => {
5358
expect(form.getAttribute('action')).toEqual(url);
5459
expect(form.getAttribute('method')).toEqual('POST');
5560
expect(form.getAttribute('target')).toEqual('_blank');
56-
57-
const inputs = form.querySelectorAll('input');
58-
expect(inputs.length).toEqual(3);
61+
expect(form.querySelectorAll('input')).toHaveLength(3);
5962

6063
expect(onSubmit).toHaveBeenCalled();
6164
});

src/labkey/query/Rows.ts

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -217,6 +217,11 @@ export interface Command {
217217
auditUserComment?: string;
218218
/** Name of the command to be performed. Must be one of "insert", "update", or "delete". */
219219
command: CommandType;
220+
/**
221+
* The container path in which the command is executed.
222+
* If not supplied, the current container path will be used.
223+
*/
224+
containerPath?: string;
220225
/** **Experimental:** Optional extra context object passed into the transformation/validation script environment. */
221226
extraContext?: any;
222227
/**

0 commit comments

Comments
 (0)