fix(docs): remove stray tool-call tags breaking the MDX build (#6081)
This is a fix to pnpm deployment which needs testing as the final part of origin/master release No functional changes * fix(docs): remove stray tool-call tags breaking the MDX build platform/docs/docs/migration-guide/3p12-to-3p13/build-tooling.md ended with two orphan closing tags (leftover tool-call serialization artifacts): </content> </invoke> Docusaurus compiles Markdown as MDX (JSX-aware), so the orphan closing tag failed the docs build: MDX compilation failed ... Unexpected closing slash in tag, expected an open tag first (build-tooling.md line 402) This was the remaining blocker for build-and-deploy-docs once the --no-frozen-lockfile change let the install step succeed. A scan of the docs tree found no other such artifacts. Verified locally: docusaurus build now generates static files with no MDX errors. Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com> * Update lockfile and avoid freshness check on every command * fix(release): keep workspace:* in the repo, concretize only at publish The release flow rewrote internal @ohif/* dependency specifiers to the concrete version and committed them, so pnpm-lock.yaml (which records workspace links) drifted from the manifests on every version bump. The resulting ERR_PNPM_OUTDATED_LOCKFILE broke every frozen install: Netlify (viewer-dev), the docs deploy, pnpm's pre-run deps check, and post-merge installs. Keep workspace:* everywhere in the committed repo and move the concrete-version substitution to publish time only: - publish-version.mjs: bump each package's own `version` field only; stop rewriting @ohif/* dependency/peerDependency specifiers. - publish-package.mjs: publish with `pnpm publish --no-git-checks` instead of `npm publish`. pnpm rewrites workspace:* to the exact version in the published tarball; npm would publish the literal "workspace:*", which npm/yarn consumers cannot resolve. - One-time: revert the 25 workspace manifests' @ohif/* specifiers to workspace:* (version fields untouched) and regenerate pnpm-lock.yaml to match. Because internal deps are workspace:* (links, not versions in the lockfile), version bumps no longer change pnpm-lock.yaml, so it stays in sync and frozen installs keep working. Verified: `pnpm install --frozen-lockfile` passes, and `pnpm pack` of @ohif/core emits a tarball whose @ohif/ui dependency is the exact version (3.13.0-beta.92), not workspace:*. Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com> * docs(ci): correct build-docs install comment for workspace:* release flow publish-version.mjs no longer rewrites @ohif/* deps to concrete versions, so the old comment was stale. Internal deps stay workspace:* and the lockfile stays consistent; pnpm publish concretizes only the published tarball. Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com> * ci(docs): use --frozen-lockfile now that the lockfile no longer drifts With internal deps as workspace:* the lockfile stays in sync across version bumps, so the docs deploy can install frozen -- failing fast on genuine lockfile drift instead of silently reconciling. The --no-frozen-lockfile workaround is no longer needed. Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com> * ci: use --frozen-lockfile in CI install steps now that the lockfile is stable Internal @ohif/* deps are workspace:* so pnpm-lock.yaml no longer drifts; the UNIT_TESTS/BUILD/NPM_PUBLISH installs can run frozen and fail fast on genuine drift. Kept --no-frozen-lockfile only where it is still required: the Dockerfile (platform/docs is excluded from the build context) and the playwright CS3D-version step (mutates @cornerstonejs versions before installing). Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com> * test: stability of seg load mpr test * Better drag fix for crosshairs --------- Co-authored-by: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
This commit is contained in:
parent
da9fd9057d
commit
256b8347e7
@ -37,7 +37,7 @@ jobs:
|
|||||||
- checkout
|
- checkout
|
||||||
- run:
|
- run:
|
||||||
name: Install Dependencies
|
name: Install Dependencies
|
||||||
command: pnpm install --no-frozen-lockfile
|
command: pnpm install --frozen-lockfile
|
||||||
# RUN TESTS
|
# RUN TESTS
|
||||||
- run:
|
- run:
|
||||||
name: 'JavaScript Test Suite'
|
name: 'JavaScript Test Suite'
|
||||||
@ -78,7 +78,7 @@ jobs:
|
|||||||
- install_pnpm
|
- install_pnpm
|
||||||
- run:
|
- run:
|
||||||
name: Install Dependencies
|
name: Install Dependencies
|
||||||
command: pnpm install --no-frozen-lockfile
|
command: pnpm install --frozen-lockfile
|
||||||
# Build & Test
|
# Build & Test
|
||||||
- run:
|
- run:
|
||||||
name: 'Perform the versioning before build'
|
name: 'Perform the versioning before build'
|
||||||
@ -197,7 +197,7 @@ jobs:
|
|||||||
at: ~/repo
|
at: ~/repo
|
||||||
- run:
|
- run:
|
||||||
name: Install Dependencies
|
name: Install Dependencies
|
||||||
command: pnpm install --no-frozen-lockfile
|
command: pnpm install --frozen-lockfile
|
||||||
- run:
|
- run:
|
||||||
name: Avoid hosts unknown for github
|
name: Avoid hosts unknown for github
|
||||||
command: |
|
command: |
|
||||||
|
|||||||
15
.github/workflows/build-docs.yml
vendored
15
.github/workflows/build-docs.yml
vendored
@ -36,13 +36,14 @@ jobs:
|
|||||||
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
|
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
|
||||||
|
|
||||||
- name: Install dependencies
|
- name: Install dependencies
|
||||||
# Use --no-frozen-lockfile to match every CircleCI job. The release flow
|
# Internal @ohif/* deps are workspace:* in the committed manifests and the
|
||||||
# (publish-version.mjs) rewrites @ohif/* workspace deps from "workspace:*"
|
# lockfile records them as links, so pnpm-lock.yaml stays in sync across
|
||||||
# to the concrete version and commits that bump to master, which leaves
|
# version bumps and a frozen install passes. Frozen is the right choice
|
||||||
# pnpm-lock.yaml out of sync with the manifests. pnpm-workspace.yaml sets
|
# for a deploy job: it fails fast if a PR ever changed a real dependency
|
||||||
# frozenLockfile:true, so a master-triggered install must opt out or it
|
# without committing the lockfile update, instead of silently reconciling.
|
||||||
# fails with ERR_PNPM_OUTDATED_LOCKFILE.
|
# (Exact versions appear only in published tarballs, where pnpm publish
|
||||||
run: pnpm install --no-frozen-lockfile
|
# rewrites workspace:* at pack time -- not publish-version.mjs.)
|
||||||
|
run: pnpm install --frozen-lockfile
|
||||||
|
|
||||||
# Removed Playwright tests and coverage generation steps
|
# Removed Playwright tests and coverage generation steps
|
||||||
|
|
||||||
|
|||||||
@ -40,8 +40,10 @@ ENV PATH=/usr/src/app/node_modules/.bin:$PATH
|
|||||||
# script file must already be present or install fails with MODULE_NOT_FOUND.
|
# script file must already be present or install fails with MODULE_NOT_FOUND.
|
||||||
COPY package.json pnpm-lock.yaml pnpm-workspace.yaml .npmrc preinstall.js ./
|
COPY package.json pnpm-lock.yaml pnpm-workspace.yaml .npmrc preinstall.js ./
|
||||||
COPY --parents ./extensions/*/package.json ./modes/*/package.json ./platform/*/package.json ./
|
COPY --parents ./extensions/*/package.json ./modes/*/package.json ./platform/*/package.json ./
|
||||||
# Run the install before copying the rest of the files
|
# Run the install before copying the rest of the files.
|
||||||
|
# Keep --no-frozen-lockfile here (unlike CI): .dockerignore excludes
|
||||||
|
# platform/docs, so the lockfile's docs importer has no manifest in the build
|
||||||
|
# context and a frozen install would fail. pnpm reconciles (drops docs) instead.
|
||||||
RUN pnpm install --no-frozen-lockfile
|
RUN pnpm install --no-frozen-lockfile
|
||||||
# Copy the local directory
|
# Copy the local directory
|
||||||
COPY --link --exclude=pnpm-lock.yaml --exclude=package.json --exclude=Dockerfile . .
|
COPY --link --exclude=pnpm-lock.yaml --exclude=package.json --exclude=Dockerfile . .
|
||||||
|
|||||||
@ -28,10 +28,10 @@
|
|||||||
"start": "pnpm run dev"
|
"start": "pnpm run dev"
|
||||||
},
|
},
|
||||||
"peerDependencies": {
|
"peerDependencies": {
|
||||||
"@ohif/core": "3.13.0-beta.92",
|
"@ohif/core": "workspace:*",
|
||||||
"@ohif/extension-cornerstone": "3.13.0-beta.92",
|
"@ohif/extension-cornerstone": "workspace:*",
|
||||||
"@ohif/extension-default": "3.13.0-beta.92",
|
"@ohif/extension-default": "workspace:*",
|
||||||
"@ohif/i18n": "3.13.0-beta.92",
|
"@ohif/i18n": "workspace:*",
|
||||||
"prop-types": "15.8.1",
|
"prop-types": "15.8.1",
|
||||||
"react": "18.3.1",
|
"react": "18.3.1",
|
||||||
"react-dom": "18.3.1",
|
"react-dom": "18.3.1",
|
||||||
|
|||||||
@ -28,10 +28,10 @@
|
|||||||
"start": "pnpm run dev"
|
"start": "pnpm run dev"
|
||||||
},
|
},
|
||||||
"peerDependencies": {
|
"peerDependencies": {
|
||||||
"@ohif/core": "3.13.0-beta.92",
|
"@ohif/core": "workspace:*",
|
||||||
"@ohif/extension-cornerstone": "3.13.0-beta.92",
|
"@ohif/extension-cornerstone": "workspace:*",
|
||||||
"@ohif/extension-default": "3.13.0-beta.92",
|
"@ohif/extension-default": "workspace:*",
|
||||||
"@ohif/i18n": "3.13.0-beta.92",
|
"@ohif/i18n": "workspace:*",
|
||||||
"prop-types": "15.8.1",
|
"prop-types": "15.8.1",
|
||||||
"react": "18.3.1",
|
"react": "18.3.1",
|
||||||
"react-dom": "18.3.1",
|
"react-dom": "18.3.1",
|
||||||
|
|||||||
@ -28,10 +28,10 @@
|
|||||||
"start": "pnpm run dev"
|
"start": "pnpm run dev"
|
||||||
},
|
},
|
||||||
"peerDependencies": {
|
"peerDependencies": {
|
||||||
"@ohif/core": "3.13.0-beta.92",
|
"@ohif/core": "workspace:*",
|
||||||
"@ohif/extension-cornerstone": "3.13.0-beta.92",
|
"@ohif/extension-cornerstone": "workspace:*",
|
||||||
"@ohif/extension-default": "3.13.0-beta.92",
|
"@ohif/extension-default": "workspace:*",
|
||||||
"@ohif/i18n": "3.13.0-beta.92",
|
"@ohif/i18n": "workspace:*",
|
||||||
"prop-types": "15.8.1",
|
"prop-types": "15.8.1",
|
||||||
"react": "18.3.1",
|
"react": "18.3.1",
|
||||||
"react-dom": "18.3.1",
|
"react-dom": "18.3.1",
|
||||||
|
|||||||
@ -29,9 +29,9 @@
|
|||||||
"test:unit:ci": "jest --ci --runInBand --collectCoverage --passWithNoTests"
|
"test:unit:ci": "jest --ci --runInBand --collectCoverage --passWithNoTests"
|
||||||
},
|
},
|
||||||
"peerDependencies": {
|
"peerDependencies": {
|
||||||
"@ohif/core": "3.13.0-beta.92",
|
"@ohif/core": "workspace:*",
|
||||||
"@ohif/extension-cornerstone": "3.13.0-beta.92",
|
"@ohif/extension-cornerstone": "workspace:*",
|
||||||
"@ohif/ui": "3.13.0-beta.92",
|
"@ohif/ui": "workspace:*",
|
||||||
"dcmjs": "0.49.4",
|
"dcmjs": "0.49.4",
|
||||||
"dicom-parser": "1.8.21",
|
"dicom-parser": "1.8.21",
|
||||||
"hammerjs": "2.0.8",
|
"hammerjs": "2.0.8",
|
||||||
|
|||||||
@ -32,11 +32,11 @@
|
|||||||
"test:unit:ci": "jest --ci --runInBand --collectCoverage --passWithNoTests"
|
"test:unit:ci": "jest --ci --runInBand --collectCoverage --passWithNoTests"
|
||||||
},
|
},
|
||||||
"peerDependencies": {
|
"peerDependencies": {
|
||||||
"@ohif/core": "3.13.0-beta.92",
|
"@ohif/core": "workspace:*",
|
||||||
"@ohif/extension-cornerstone": "3.13.0-beta.92",
|
"@ohif/extension-cornerstone": "workspace:*",
|
||||||
"@ohif/extension-default": "3.13.0-beta.92",
|
"@ohif/extension-default": "workspace:*",
|
||||||
"@ohif/i18n": "3.13.0-beta.92",
|
"@ohif/i18n": "workspace:*",
|
||||||
"@ohif/ui": "3.13.0-beta.92",
|
"@ohif/ui": "workspace:*",
|
||||||
"dcmjs": "0.49.4",
|
"dcmjs": "0.49.4",
|
||||||
"dicom-parser": "1.8.21",
|
"dicom-parser": "1.8.21",
|
||||||
"hammerjs": "2.0.8",
|
"hammerjs": "2.0.8",
|
||||||
|
|||||||
@ -39,9 +39,9 @@
|
|||||||
"@cornerstonejs/codec-openjpeg": "1.3.0",
|
"@cornerstonejs/codec-openjpeg": "1.3.0",
|
||||||
"@cornerstonejs/codec-openjph": "2.4.7",
|
"@cornerstonejs/codec-openjph": "2.4.7",
|
||||||
"@cornerstonejs/dicom-image-loader": "5.0.2",
|
"@cornerstonejs/dicom-image-loader": "5.0.2",
|
||||||
"@ohif/core": "3.13.0-beta.92",
|
"@ohif/core": "workspace:*",
|
||||||
"@ohif/extension-default": "3.13.0-beta.92",
|
"@ohif/extension-default": "workspace:*",
|
||||||
"@ohif/ui": "3.13.0-beta.92",
|
"@ohif/ui": "workspace:*",
|
||||||
"dcmjs": "0.49.4",
|
"dcmjs": "0.49.4",
|
||||||
"dicom-parser": "1.8.21",
|
"dicom-parser": "1.8.21",
|
||||||
"hammerjs": "2.0.8",
|
"hammerjs": "2.0.8",
|
||||||
|
|||||||
@ -29,8 +29,8 @@
|
|||||||
"test:unit:ci": "jest --ci --runInBand --collectCoverage --passWithNoTests"
|
"test:unit:ci": "jest --ci --runInBand --collectCoverage --passWithNoTests"
|
||||||
},
|
},
|
||||||
"peerDependencies": {
|
"peerDependencies": {
|
||||||
"@ohif/core": "3.13.0-beta.92",
|
"@ohif/core": "workspace:*",
|
||||||
"@ohif/i18n": "3.13.0-beta.92",
|
"@ohif/i18n": "workspace:*",
|
||||||
"dcmjs": "0.49.4",
|
"dcmjs": "0.49.4",
|
||||||
"dicomweb-client": "0.10.4",
|
"dicomweb-client": "0.10.4",
|
||||||
"prop-types": "15.8.1",
|
"prop-types": "15.8.1",
|
||||||
|
|||||||
@ -25,10 +25,10 @@
|
|||||||
"start": "pnpm run dev"
|
"start": "pnpm run dev"
|
||||||
},
|
},
|
||||||
"peerDependencies": {
|
"peerDependencies": {
|
||||||
"@ohif/core": "3.13.0-beta.92",
|
"@ohif/core": "workspace:*",
|
||||||
"@ohif/extension-default": "3.13.0-beta.92",
|
"@ohif/extension-default": "workspace:*",
|
||||||
"@ohif/i18n": "3.13.0-beta.92",
|
"@ohif/i18n": "workspace:*",
|
||||||
"@ohif/ui": "3.13.0-beta.92",
|
"@ohif/ui": "workspace:*",
|
||||||
"prop-types": "15.8.1",
|
"prop-types": "15.8.1",
|
||||||
"react": "18.3.1",
|
"react": "18.3.1",
|
||||||
"react-dom": "18.3.1",
|
"react-dom": "18.3.1",
|
||||||
|
|||||||
@ -28,8 +28,8 @@
|
|||||||
"test:unit:ci": "jest --ci --runInBand --collectCoverage --passWithNoTests"
|
"test:unit:ci": "jest --ci --runInBand --collectCoverage --passWithNoTests"
|
||||||
},
|
},
|
||||||
"peerDependencies": {
|
"peerDependencies": {
|
||||||
"@ohif/core": "3.13.0-beta.92",
|
"@ohif/core": "workspace:*",
|
||||||
"@ohif/ui": "3.13.0-beta.92",
|
"@ohif/ui": "workspace:*",
|
||||||
"dcmjs": "0.49.4",
|
"dcmjs": "0.49.4",
|
||||||
"dicom-parser": "1.8.21",
|
"dicom-parser": "1.8.21",
|
||||||
"hammerjs": "2.0.8",
|
"hammerjs": "2.0.8",
|
||||||
|
|||||||
@ -28,8 +28,8 @@
|
|||||||
"test:unit:ci": "jest --ci --runInBand --collectCoverage --passWithNoTests"
|
"test:unit:ci": "jest --ci --runInBand --collectCoverage --passWithNoTests"
|
||||||
},
|
},
|
||||||
"peerDependencies": {
|
"peerDependencies": {
|
||||||
"@ohif/core": "3.13.0-beta.92",
|
"@ohif/core": "workspace:*",
|
||||||
"@ohif/ui": "3.13.0-beta.92",
|
"@ohif/ui": "workspace:*",
|
||||||
"dcmjs": "0.49.4",
|
"dcmjs": "0.49.4",
|
||||||
"dicom-parser": "1.8.21",
|
"dicom-parser": "1.8.21",
|
||||||
"hammerjs": "2.0.8",
|
"hammerjs": "2.0.8",
|
||||||
|
|||||||
@ -29,10 +29,10 @@
|
|||||||
"peerDependencies": {
|
"peerDependencies": {
|
||||||
"@cornerstonejs/core": "5.0.2",
|
"@cornerstonejs/core": "5.0.2",
|
||||||
"@cornerstonejs/tools": "5.0.2",
|
"@cornerstonejs/tools": "5.0.2",
|
||||||
"@ohif/core": "3.13.0-beta.92",
|
"@ohif/core": "workspace:*",
|
||||||
"@ohif/extension-cornerstone-dicom-sr": "3.13.0-beta.92",
|
"@ohif/extension-cornerstone-dicom-sr": "workspace:*",
|
||||||
"@ohif/extension-default": "3.13.0-beta.92",
|
"@ohif/extension-default": "workspace:*",
|
||||||
"@ohif/ui": "3.13.0-beta.92",
|
"@ohif/ui": "workspace:*",
|
||||||
"classnames": "2.5.1",
|
"classnames": "2.5.1",
|
||||||
"dcmjs": "0.49.4",
|
"dcmjs": "0.49.4",
|
||||||
"lodash.debounce": "4.0.8",
|
"lodash.debounce": "4.0.8",
|
||||||
@ -43,7 +43,7 @@
|
|||||||
},
|
},
|
||||||
"dependencies": {
|
"dependencies": {
|
||||||
"@babel/runtime": "7.29.7",
|
"@babel/runtime": "7.29.7",
|
||||||
"@ohif/ui": "3.13.0-beta.92",
|
"@ohif/ui": "workspace:*",
|
||||||
"@xstate/react": "3.2.2",
|
"@xstate/react": "3.2.2",
|
||||||
"xstate": "4.38.3"
|
"xstate": "4.38.3"
|
||||||
},
|
},
|
||||||
|
|||||||
@ -28,8 +28,8 @@
|
|||||||
"test:unit:ci": "jest --ci --runInBand --collectCoverage --passWithNoTests"
|
"test:unit:ci": "jest --ci --runInBand --collectCoverage --passWithNoTests"
|
||||||
},
|
},
|
||||||
"peerDependencies": {
|
"peerDependencies": {
|
||||||
"@ohif/core": "3.13.0-beta.92",
|
"@ohif/core": "workspace:*",
|
||||||
"@ohif/ui": "3.13.0-beta.92",
|
"@ohif/ui": "workspace:*",
|
||||||
"dcmjs": "0.49.4",
|
"dcmjs": "0.49.4",
|
||||||
"dicom-parser": "1.8.21",
|
"dicom-parser": "1.8.21",
|
||||||
"hammerjs": "2.0.8",
|
"hammerjs": "2.0.8",
|
||||||
|
|||||||
@ -28,8 +28,8 @@
|
|||||||
"test:unit:ci": "jest --ci --runInBand --collectCoverage --passWithNoTests"
|
"test:unit:ci": "jest --ci --runInBand --collectCoverage --passWithNoTests"
|
||||||
},
|
},
|
||||||
"peerDependencies": {
|
"peerDependencies": {
|
||||||
"@ohif/core": "3.13.0-beta.92",
|
"@ohif/core": "workspace:*",
|
||||||
"@ohif/ui": "3.13.0-beta.92",
|
"@ohif/ui": "workspace:*",
|
||||||
"dcmjs": "0.49.4",
|
"dcmjs": "0.49.4",
|
||||||
"dicom-parser": "1.8.21",
|
"dicom-parser": "1.8.21",
|
||||||
"hammerjs": "2.0.8",
|
"hammerjs": "2.0.8",
|
||||||
|
|||||||
@ -38,11 +38,11 @@
|
|||||||
"@babel/runtime": "7.29.7",
|
"@babel/runtime": "7.29.7",
|
||||||
"@cornerstonejs/core": "5.0.2",
|
"@cornerstonejs/core": "5.0.2",
|
||||||
"@cornerstonejs/tools": "5.0.2",
|
"@cornerstonejs/tools": "5.0.2",
|
||||||
"@ohif/core": "3.13.0-beta.92",
|
"@ohif/core": "workspace:*",
|
||||||
"@ohif/extension-cornerstone": "3.13.0-beta.92",
|
"@ohif/extension-cornerstone": "workspace:*",
|
||||||
"@ohif/extension-default": "3.13.0-beta.92",
|
"@ohif/extension-default": "workspace:*",
|
||||||
"@ohif/i18n": "3.13.0-beta.92",
|
"@ohif/i18n": "workspace:*",
|
||||||
"@ohif/ui-next": "3.13.0-beta.92"
|
"@ohif/ui-next": "workspace:*"
|
||||||
},
|
},
|
||||||
"devDependencies": {
|
"devDependencies": {
|
||||||
"@babel/core": "7.29.7",
|
"@babel/core": "7.29.7",
|
||||||
|
|||||||
@ -29,12 +29,12 @@
|
|||||||
"test:unit:ci": "jest --ci --runInBand --collectCoverage --passWithNoTests"
|
"test:unit:ci": "jest --ci --runInBand --collectCoverage --passWithNoTests"
|
||||||
},
|
},
|
||||||
"peerDependencies": {
|
"peerDependencies": {
|
||||||
"@ohif/core": "3.13.0-beta.92",
|
"@ohif/core": "workspace:*",
|
||||||
"@ohif/extension-cornerstone": "3.13.0-beta.92",
|
"@ohif/extension-cornerstone": "workspace:*",
|
||||||
"@ohif/extension-cornerstone-dicom-sr": "3.13.0-beta.92",
|
"@ohif/extension-cornerstone-dicom-sr": "workspace:*",
|
||||||
"@ohif/extension-default": "3.13.0-beta.92",
|
"@ohif/extension-default": "workspace:*",
|
||||||
"@ohif/extension-dicom-pdf": "3.13.0-beta.92",
|
"@ohif/extension-dicom-pdf": "workspace:*",
|
||||||
"@ohif/extension-dicom-video": "3.13.0-beta.92"
|
"@ohif/extension-dicom-video": "workspace:*"
|
||||||
},
|
},
|
||||||
"dependencies": {
|
"dependencies": {
|
||||||
"@babel/runtime": "7.29.7",
|
"@babel/runtime": "7.29.7",
|
||||||
|
|||||||
@ -29,14 +29,14 @@
|
|||||||
"test:unit:ci": "jest --ci --runInBand --collectCoverage --passWithNoTests"
|
"test:unit:ci": "jest --ci --runInBand --collectCoverage --passWithNoTests"
|
||||||
},
|
},
|
||||||
"peerDependencies": {
|
"peerDependencies": {
|
||||||
"@ohif/core": "3.13.0-beta.92",
|
"@ohif/core": "workspace:*",
|
||||||
"@ohif/extension-cornerstone": "3.13.0-beta.92",
|
"@ohif/extension-cornerstone": "workspace:*",
|
||||||
"@ohif/extension-cornerstone-dicom-sr": "3.13.0-beta.92",
|
"@ohif/extension-cornerstone-dicom-sr": "workspace:*",
|
||||||
"@ohif/extension-default": "3.13.0-beta.92",
|
"@ohif/extension-default": "workspace:*",
|
||||||
"@ohif/extension-dicom-pdf": "3.13.0-beta.92",
|
"@ohif/extension-dicom-pdf": "workspace:*",
|
||||||
"@ohif/extension-dicom-video": "3.13.0-beta.92",
|
"@ohif/extension-dicom-video": "workspace:*",
|
||||||
"@ohif/extension-measurement-tracking": "3.13.0-beta.92",
|
"@ohif/extension-measurement-tracking": "workspace:*",
|
||||||
"@ohif/extension-test": "3.13.0-beta.92"
|
"@ohif/extension-test": "workspace:*"
|
||||||
},
|
},
|
||||||
"dependencies": {
|
"dependencies": {
|
||||||
"@babel/runtime": "7.29.7",
|
"@babel/runtime": "7.29.7",
|
||||||
|
|||||||
@ -25,14 +25,14 @@
|
|||||||
"test:unit:ci": "jest --ci --runInBand --collectCoverage --passWithNoTests"
|
"test:unit:ci": "jest --ci --runInBand --collectCoverage --passWithNoTests"
|
||||||
},
|
},
|
||||||
"peerDependencies": {
|
"peerDependencies": {
|
||||||
"@ohif/core": "3.13.0-beta.92",
|
"@ohif/core": "workspace:*",
|
||||||
"@ohif/extension-cornerstone": "3.13.0-beta.92",
|
"@ohif/extension-cornerstone": "workspace:*",
|
||||||
"@ohif/extension-cornerstone-dicom-rt": "3.13.0-beta.92",
|
"@ohif/extension-cornerstone-dicom-rt": "workspace:*",
|
||||||
"@ohif/extension-cornerstone-dicom-seg": "3.13.0-beta.92",
|
"@ohif/extension-cornerstone-dicom-seg": "workspace:*",
|
||||||
"@ohif/extension-cornerstone-dicom-sr": "3.13.0-beta.92",
|
"@ohif/extension-cornerstone-dicom-sr": "workspace:*",
|
||||||
"@ohif/extension-default": "3.13.0-beta.92",
|
"@ohif/extension-default": "workspace:*",
|
||||||
"@ohif/extension-dicom-pdf": "3.13.0-beta.92",
|
"@ohif/extension-dicom-pdf": "workspace:*",
|
||||||
"@ohif/extension-dicom-video": "3.13.0-beta.92"
|
"@ohif/extension-dicom-video": "workspace:*"
|
||||||
},
|
},
|
||||||
"dependencies": {
|
"dependencies": {
|
||||||
"@babel/runtime": "7.29.7"
|
"@babel/runtime": "7.29.7"
|
||||||
|
|||||||
@ -29,16 +29,16 @@
|
|||||||
"test:unit:ci": "jest --ci --runInBand --collectCoverage --passWithNoTests"
|
"test:unit:ci": "jest --ci --runInBand --collectCoverage --passWithNoTests"
|
||||||
},
|
},
|
||||||
"peerDependencies": {
|
"peerDependencies": {
|
||||||
"@ohif/core": "3.13.0-beta.92",
|
"@ohif/core": "workspace:*",
|
||||||
"@ohif/extension-cornerstone": "3.13.0-beta.92",
|
"@ohif/extension-cornerstone": "workspace:*",
|
||||||
"@ohif/extension-cornerstone-dicom-rt": "3.13.0-beta.92",
|
"@ohif/extension-cornerstone-dicom-rt": "workspace:*",
|
||||||
"@ohif/extension-cornerstone-dicom-seg": "3.13.0-beta.92",
|
"@ohif/extension-cornerstone-dicom-seg": "workspace:*",
|
||||||
"@ohif/extension-cornerstone-dicom-sr": "3.13.0-beta.92",
|
"@ohif/extension-cornerstone-dicom-sr": "workspace:*",
|
||||||
"@ohif/extension-default": "3.13.0-beta.92",
|
"@ohif/extension-default": "workspace:*",
|
||||||
"@ohif/extension-dicom-pdf": "3.13.0-beta.92",
|
"@ohif/extension-dicom-pdf": "workspace:*",
|
||||||
"@ohif/extension-dicom-video": "3.13.0-beta.92",
|
"@ohif/extension-dicom-video": "workspace:*",
|
||||||
"@ohif/extension-measurement-tracking": "3.13.0-beta.92",
|
"@ohif/extension-measurement-tracking": "workspace:*",
|
||||||
"@ohif/mode-basic": "3.13.0-beta.92"
|
"@ohif/mode-basic": "workspace:*"
|
||||||
},
|
},
|
||||||
"dependencies": {
|
"dependencies": {
|
||||||
"@babel/runtime": "7.29.7",
|
"@babel/runtime": "7.29.7",
|
||||||
|
|||||||
@ -30,8 +30,8 @@
|
|||||||
"test:unit:ci": "jest --ci --runInBand --collectCoverage --passWithNoTests"
|
"test:unit:ci": "jest --ci --runInBand --collectCoverage --passWithNoTests"
|
||||||
},
|
},
|
||||||
"peerDependencies": {
|
"peerDependencies": {
|
||||||
"@ohif/core": "3.13.0-beta.92",
|
"@ohif/core": "workspace:*",
|
||||||
"@ohif/extension-dicom-microscopy": "3.13.0-beta.92"
|
"@ohif/extension-dicom-microscopy": "workspace:*"
|
||||||
},
|
},
|
||||||
"dependencies": {
|
"dependencies": {
|
||||||
"@babel/runtime": "7.29.7",
|
"@babel/runtime": "7.29.7",
|
||||||
|
|||||||
@ -28,12 +28,12 @@
|
|||||||
"test:unit:ci": "jest --ci --runInBand --collectCoverage --passWithNoTests"
|
"test:unit:ci": "jest --ci --runInBand --collectCoverage --passWithNoTests"
|
||||||
},
|
},
|
||||||
"peerDependencies": {
|
"peerDependencies": {
|
||||||
"@ohif/core": "3.13.0-beta.92",
|
"@ohif/core": "workspace:*",
|
||||||
"@ohif/extension-cornerstone": "3.13.0-beta.92",
|
"@ohif/extension-cornerstone": "workspace:*",
|
||||||
"@ohif/extension-cornerstone-dicom-seg": "3.13.0-beta.92",
|
"@ohif/extension-cornerstone-dicom-seg": "workspace:*",
|
||||||
"@ohif/extension-cornerstone-dynamic-volume": "3.13.0-beta.92",
|
"@ohif/extension-cornerstone-dynamic-volume": "workspace:*",
|
||||||
"@ohif/extension-default": "3.13.0-beta.92",
|
"@ohif/extension-default": "workspace:*",
|
||||||
"@ohif/extension-tmtv": "3.13.0-beta.92"
|
"@ohif/extension-tmtv": "workspace:*"
|
||||||
},
|
},
|
||||||
"dependencies": {
|
"dependencies": {
|
||||||
"@babel/runtime": "7.29.7"
|
"@babel/runtime": "7.29.7"
|
||||||
|
|||||||
@ -30,15 +30,15 @@
|
|||||||
"test:unit:ci": "jest --ci --runInBand --collectCoverage --passWithNoTests"
|
"test:unit:ci": "jest --ci --runInBand --collectCoverage --passWithNoTests"
|
||||||
},
|
},
|
||||||
"peerDependencies": {
|
"peerDependencies": {
|
||||||
"@ohif/core": "3.13.0-beta.92",
|
"@ohif/core": "workspace:*",
|
||||||
"@ohif/extension-cornerstone": "3.13.0-beta.92",
|
"@ohif/extension-cornerstone": "workspace:*",
|
||||||
"@ohif/extension-cornerstone-dicom-rt": "3.13.0-beta.92",
|
"@ohif/extension-cornerstone-dicom-rt": "workspace:*",
|
||||||
"@ohif/extension-cornerstone-dicom-seg": "3.13.0-beta.92",
|
"@ohif/extension-cornerstone-dicom-seg": "workspace:*",
|
||||||
"@ohif/extension-cornerstone-dicom-sr": "3.13.0-beta.92",
|
"@ohif/extension-cornerstone-dicom-sr": "workspace:*",
|
||||||
"@ohif/extension-default": "3.13.0-beta.92",
|
"@ohif/extension-default": "workspace:*",
|
||||||
"@ohif/extension-dicom-pdf": "3.13.0-beta.92",
|
"@ohif/extension-dicom-pdf": "workspace:*",
|
||||||
"@ohif/extension-dicom-video": "3.13.0-beta.92",
|
"@ohif/extension-dicom-video": "workspace:*",
|
||||||
"@ohif/mode-basic": "3.13.0-beta.92"
|
"@ohif/mode-basic": "workspace:*"
|
||||||
},
|
},
|
||||||
"dependencies": {
|
"dependencies": {
|
||||||
"@babel/runtime": "7.29.7",
|
"@babel/runtime": "7.29.7",
|
||||||
|
|||||||
@ -29,13 +29,13 @@
|
|||||||
"test:unit:ci": "jest --ci --runInBand --collectCoverage --passWithNoTests"
|
"test:unit:ci": "jest --ci --runInBand --collectCoverage --passWithNoTests"
|
||||||
},
|
},
|
||||||
"peerDependencies": {
|
"peerDependencies": {
|
||||||
"@ohif/core": "3.13.0-beta.92",
|
"@ohif/core": "workspace:*",
|
||||||
"@ohif/extension-cornerstone": "3.13.0-beta.92",
|
"@ohif/extension-cornerstone": "workspace:*",
|
||||||
"@ohif/extension-cornerstone-dicom-sr": "3.13.0-beta.92",
|
"@ohif/extension-cornerstone-dicom-sr": "workspace:*",
|
||||||
"@ohif/extension-default": "3.13.0-beta.92",
|
"@ohif/extension-default": "workspace:*",
|
||||||
"@ohif/extension-dicom-pdf": "3.13.0-beta.92",
|
"@ohif/extension-dicom-pdf": "workspace:*",
|
||||||
"@ohif/extension-dicom-video": "3.13.0-beta.92",
|
"@ohif/extension-dicom-video": "workspace:*",
|
||||||
"@ohif/extension-measurement-tracking": "3.13.0-beta.92"
|
"@ohif/extension-measurement-tracking": "workspace:*"
|
||||||
},
|
},
|
||||||
"dependencies": {
|
"dependencies": {
|
||||||
"@babel/runtime": "7.29.7",
|
"@babel/runtime": "7.29.7",
|
||||||
|
|||||||
@ -31,9 +31,9 @@
|
|||||||
"@babel/runtime": "7.29.7",
|
"@babel/runtime": "7.29.7",
|
||||||
"@cornerstonejs/core": "5.0.2",
|
"@cornerstonejs/core": "5.0.2",
|
||||||
"@cornerstonejs/tools": "5.0.2",
|
"@cornerstonejs/tools": "5.0.2",
|
||||||
"@ohif/core": "3.13.0-beta.92",
|
"@ohif/core": "workspace:*",
|
||||||
"@ohif/extension-cornerstone-dicom-sr": "3.13.0-beta.92",
|
"@ohif/extension-cornerstone-dicom-sr": "workspace:*",
|
||||||
"@ohif/extension-ultrasound-pleura-bline": "3.13.0-beta.92",
|
"@ohif/extension-ultrasound-pleura-bline": "workspace:*",
|
||||||
"i18next": "17.3.1"
|
"i18next": "17.3.1"
|
||||||
},
|
},
|
||||||
"devDependencies": {
|
"devDependencies": {
|
||||||
|
|||||||
@ -53,10 +53,10 @@
|
|||||||
"@cornerstonejs/codec-openjph": "2.4.7",
|
"@cornerstonejs/codec-openjph": "2.4.7",
|
||||||
"@cornerstonejs/dicom-image-loader": "5.0.2",
|
"@cornerstonejs/dicom-image-loader": "5.0.2",
|
||||||
"@emotion/serialize": "1.3.3",
|
"@emotion/serialize": "1.3.3",
|
||||||
"@ohif/core": "3.13.0-beta.92",
|
"@ohif/core": "workspace:*",
|
||||||
"@ohif/i18n": "3.13.0-beta.92",
|
"@ohif/i18n": "workspace:*",
|
||||||
"@ohif/ui": "3.13.0-beta.92",
|
"@ohif/ui": "workspace:*",
|
||||||
"@ohif/ui-next": "3.13.0-beta.92",
|
"@ohif/ui-next": "workspace:*",
|
||||||
"@svgr/webpack": "8.1.0",
|
"@svgr/webpack": "8.1.0",
|
||||||
"@types/react": "18.3.23",
|
"@types/react": "18.3.23",
|
||||||
"classnames": "2.5.1",
|
"classnames": "2.5.1",
|
||||||
|
|||||||
@ -38,7 +38,7 @@
|
|||||||
"@cornerstonejs/core": "5.0.2",
|
"@cornerstonejs/core": "5.0.2",
|
||||||
"@cornerstonejs/dicom-image-loader": "5.0.2",
|
"@cornerstonejs/dicom-image-loader": "5.0.2",
|
||||||
"@cornerstonejs/metadata": "5.0.2",
|
"@cornerstonejs/metadata": "5.0.2",
|
||||||
"@ohif/ui": "3.13.0-beta.92",
|
"@ohif/ui": "workspace:*",
|
||||||
"cornerstone-math": "0.1.10",
|
"cornerstone-math": "0.1.10",
|
||||||
"dicom-parser": "1.8.21"
|
"dicom-parser": "1.8.21"
|
||||||
},
|
},
|
||||||
|
|||||||
@ -399,5 +399,3 @@ template, do the following:
|
|||||||
it is kept on for normal local dev.
|
it is kept on for normal local dev.
|
||||||
- The `dev:no:cache` script is now identical to `dev` — keep it as an
|
- The `dev:no:cache` script is now identical to `dev` — keep it as an
|
||||||
alias if external scripts call it, or delete it.
|
alias if external scripts call it, or delete it.
|
||||||
</content>
|
|
||||||
</invoke>
|
|
||||||
|
|||||||
@ -16,6 +16,9 @@ minimumReleaseAgeExclude:
|
|||||||
- '@cornerstonejs/*'
|
- '@cornerstonejs/*'
|
||||||
frozenLockfile: true
|
frozenLockfile: true
|
||||||
|
|
||||||
|
# Skip the pre-`pnpm run` frozen deps-check; installs set freshness explicitly.
|
||||||
|
verifyDepsBeforeRun: false
|
||||||
|
|
||||||
# Equivalent of the bun `audit --ignore=...` flags. These GHSAs are accepted
|
# Equivalent of the bun `audit --ignore=...` flags. These GHSAs are accepted
|
||||||
# risk: minimatch/picomatch advisories reached only via build/CI tooling, never
|
# risk: minimatch/picomatch advisories reached only via build/CI tooling, never
|
||||||
# fed user-supplied expressions. Kept in sync with the .circleci SECURITY_AUDIT
|
# fed user-supplied expressions. Kept in sync with the .circleci SECURITY_AUDIT
|
||||||
|
|||||||
@ -37,13 +37,18 @@ async function run() {
|
|||||||
while (retries < MAX_RETRIES) {
|
while (retries < MAX_RETRIES) {
|
||||||
try {
|
try {
|
||||||
console.log(`Tying to publishing package at ${packageDirectory}`);
|
console.log(`Tying to publishing package at ${packageDirectory}`);
|
||||||
const publishArgs = ['publish'];
|
// Use `pnpm publish` (not npm) so the workspace:* specifiers on our
|
||||||
|
// internal @ohif/* deps are rewritten to the exact version in the
|
||||||
|
// published tarball. npm would publish the literal "workspace:*",
|
||||||
|
// which npm/yarn consumers cannot resolve. --no-git-checks because
|
||||||
|
// the bump commit/tag is created in CI on a possibly-detached ref.
|
||||||
|
const publishArgs = ['publish', '--no-git-checks'];
|
||||||
|
|
||||||
if (branchName === 'master') {
|
if (branchName === 'master') {
|
||||||
publishArgs.push('--tag', 'beta');
|
publishArgs.push('--tag', 'beta');
|
||||||
}
|
}
|
||||||
|
|
||||||
await execa('npm', publishArgs);
|
await execa('pnpm', publishArgs);
|
||||||
console.log(`Successfully published package at ${packageDirectory}`);
|
console.log(`Successfully published package at ${packageDirectory}`);
|
||||||
break;
|
break;
|
||||||
} catch (error) {
|
} catch (error) {
|
||||||
|
|||||||
@ -30,27 +30,13 @@ async function run() {
|
|||||||
try {
|
try {
|
||||||
const packageJson = JSON.parse(await fs.readFile(packageJsonPath, 'utf-8'));
|
const packageJson = JSON.parse(await fs.readFile(packageJsonPath, 'utf-8'));
|
||||||
|
|
||||||
// Update the package version
|
// Bump only the package's own version. Internal @ohif/* references stay
|
||||||
|
// as workspace:* in the committed manifests (and therefore the lockfile,
|
||||||
|
// which records them as links), so pnpm-lock.yaml never drifts on a
|
||||||
|
// version bump and frozen installs keep working. pnpm publish rewrites
|
||||||
|
// workspace:* to the exact version in the published tarball only.
|
||||||
packageJson.version = nextVersion;
|
packageJson.version = nextVersion;
|
||||||
|
|
||||||
// Update peerDependencies
|
|
||||||
if (packageJson.peerDependencies) {
|
|
||||||
for (const dep of Object.keys(packageJson.peerDependencies)) {
|
|
||||||
if (dep.startsWith('@ohif/')) {
|
|
||||||
packageJson.peerDependencies[dep] = nextVersion;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
// Update dependencies
|
|
||||||
if (packageJson.dependencies) {
|
|
||||||
for (const dep of Object.keys(packageJson.dependencies)) {
|
|
||||||
if (dep.startsWith('@ohif/')) {
|
|
||||||
packageJson.dependencies[dep] = nextVersion;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
await fs.writeFile(packageJsonPath, JSON.stringify(packageJson, null, 2) + '\n');
|
await fs.writeFile(packageJsonPath, JSON.stringify(packageJson, null, 2) + '\n');
|
||||||
updatedFiles.push(packageJsonPath);
|
updatedFiles.push(packageJsonPath);
|
||||||
|
|
||||||
|
|||||||
@ -3,7 +3,6 @@ import {
|
|||||||
screenShotPaths,
|
screenShotPaths,
|
||||||
test,
|
test,
|
||||||
visitStudy,
|
visitStudy,
|
||||||
waitForPaintToSettle,
|
|
||||||
waitForViewportRenderCycle,
|
waitForViewportRenderCycle,
|
||||||
waitForViewportsRendered,
|
waitForViewportsRendered,
|
||||||
} from './utils';
|
} from './utils';
|
||||||
@ -36,11 +35,11 @@ test('should properly display MPR for MR', async ({
|
|||||||
|
|
||||||
await leftPanelPageObject.loadSeriesByDescription('SEG');
|
await leftPanelPageObject.loadSeriesByDescription('SEG');
|
||||||
|
|
||||||
|
// SEG load triggers a progressive labelmap volume upload. waitForViewportsRendered
|
||||||
|
// (waitVolumeLoad defaults to true) polls the viewport volume actors until the
|
||||||
|
// labelmap reports loadStatus.loaded, then settles, so the screenshot captures the
|
||||||
|
// finished upload rather than a mid-stream frame.
|
||||||
await waitForViewportsRendered(page);
|
await waitForViewportsRendered(page);
|
||||||
// SEG load triggers an additional progressive labelmap upload after the
|
|
||||||
// viewports first report 'rendered'; let that finish before screenshotting.
|
|
||||||
await page.waitForTimeout(1500);
|
|
||||||
await waitForPaintToSettle(page);
|
|
||||||
|
|
||||||
await checkForScreenshot(
|
await checkForScreenshot(
|
||||||
page,
|
page,
|
||||||
@ -54,11 +53,11 @@ test('should properly display MPR for MR', async ({
|
|||||||
await DOMOverlayPageObject.viewport.segmentationHydration.yes.click();
|
await DOMOverlayPageObject.viewport.segmentationHydration.yes.click();
|
||||||
|
|
||||||
await viewportRenderCycle;
|
await viewportRenderCycle;
|
||||||
// Hydration propagates the labelmap volume to the sagittal/coronal MPR
|
// Hydration propagates the labelmap volume to the sagittal/coronal MPR viewports
|
||||||
// viewports asynchronously; wait for that propagation to render before
|
// asynchronously, adding new volume actors after the first render cycle resolves.
|
||||||
// capturing.
|
// waitForViewportsRendered re-polls every viewport's volume actors until those
|
||||||
await page.waitForTimeout(1500);
|
// propagated labelmaps report loadStatus.loaded, then settles.
|
||||||
await waitForPaintToSettle(page);
|
await waitForViewportsRendered(page);
|
||||||
|
|
||||||
await checkForScreenshot(
|
await checkForScreenshot(
|
||||||
page,
|
page,
|
||||||
@ -71,8 +70,9 @@ test('should properly display MPR for MR', async ({
|
|||||||
await mainToolbarPageObject.layoutSelection.axialPrimary.click();
|
await mainToolbarPageObject.layoutSelection.axialPrimary.click();
|
||||||
|
|
||||||
await viewportRenderAfterLayoutChange;
|
await viewportRenderAfterLayoutChange;
|
||||||
await page.waitForTimeout(1000);
|
// The layout change rebuilds the viewports; wait for their volume actors (image
|
||||||
await waitForPaintToSettle(page);
|
// + labelmap) to report loaded before settling and capturing.
|
||||||
|
await waitForViewportsRendered(page);
|
||||||
|
|
||||||
await checkForScreenshot(
|
await checkForScreenshot(
|
||||||
page,
|
page,
|
||||||
|
|||||||
@ -1,6 +1,5 @@
|
|||||||
import { Locator, Page } from '@playwright/test';
|
import { Locator, Page } from '@playwright/test';
|
||||||
import {
|
import {
|
||||||
getMousePosition,
|
|
||||||
simulateClicksOnElement,
|
simulateClicksOnElement,
|
||||||
simulateDoubleClickOnElement,
|
simulateDoubleClickOnElement,
|
||||||
simulateNormalizedClicksOnElement,
|
simulateNormalizedClicksOnElement,
|
||||||
@ -362,6 +361,28 @@ export class ViewportPageObject {
|
|||||||
throw new Error('Could not find slab thickness handle for crosshairs interaction');
|
throw new Error('Could not find slab thickness handle for crosshairs interaction');
|
||||||
}
|
}
|
||||||
|
|
||||||
|
// Drive the drag from the handle's own bounding-box center rather than the
|
||||||
|
// async window.mouseX/Y tracker: the tracker can lag behind the hover, which
|
||||||
|
// makes the drag start from a stale point and rotate/resize nothing. Stepped
|
||||||
|
// moves emit intermediate mousemove events so cornerstone registers a real
|
||||||
|
// drag instead of a single teleport (which can be dropped or mis-deltad).
|
||||||
|
const DRAG_DISTANCE = 100;
|
||||||
|
const DRAG_STEPS = 10;
|
||||||
|
|
||||||
|
async function dragHandleFromCenter(handle: Locator, dx: number, dy: number) {
|
||||||
|
const box = await handle.boundingBox();
|
||||||
|
if (!box) {
|
||||||
|
throw new Error('Could not resolve crosshairs handle bounding box for drag');
|
||||||
|
}
|
||||||
|
const cx = box.x + box.width / 2;
|
||||||
|
const cy = box.y + box.height / 2;
|
||||||
|
|
||||||
|
await page.mouse.move(cx, cy);
|
||||||
|
await page.mouse.down();
|
||||||
|
await page.mouse.move(cx + dx, cy + dy, { steps: DRAG_STEPS });
|
||||||
|
await page.mouse.up();
|
||||||
|
}
|
||||||
|
|
||||||
async function increaseSlabThickness(locator: Locator, lineNumber: number, axis: string) {
|
async function increaseSlabThickness(locator: Locator, lineNumber: number, axis: string) {
|
||||||
const lineLocator = locator.locator('line').nth(lineNumber);
|
const lineLocator = locator.locator('line').nth(lineNumber);
|
||||||
await lineLocator.click({ force: true });
|
await lineLocator.click({ force: true });
|
||||||
@ -370,18 +391,9 @@ export class ViewportPageObject {
|
|||||||
const slabHandleLocator = await getSlabHandleLocator(locator);
|
const slabHandleLocator = await getSlabHandleLocator(locator);
|
||||||
await slabHandleLocator.hover({ force: true, timeout: crosshairHoverTimeout });
|
await slabHandleLocator.hover({ force: true, timeout: crosshairHoverTimeout });
|
||||||
|
|
||||||
await page.mouse.down();
|
const dx = axis === 'x' ? DRAG_DISTANCE : 0;
|
||||||
|
const dy = axis === 'y' ? DRAG_DISTANCE : 0;
|
||||||
const position = await getMousePosition(page);
|
await dragHandleFromCenter(slabHandleLocator, dx, dy);
|
||||||
switch (axis) {
|
|
||||||
case 'x':
|
|
||||||
await page.mouse.move(position.x + 100, position.y);
|
|
||||||
break;
|
|
||||||
case 'y':
|
|
||||||
await page.mouse.move(position.x, position.y + 100);
|
|
||||||
break;
|
|
||||||
}
|
|
||||||
await page.mouse.up();
|
|
||||||
}
|
}
|
||||||
|
|
||||||
async function rotateCrosshairs(locator: Locator, lineNumber: number) {
|
async function rotateCrosshairs(locator: Locator, lineNumber: number) {
|
||||||
@ -393,11 +405,7 @@ export class ViewportPageObject {
|
|||||||
await circleLocator.waitFor({ state: 'attached', timeout: crosshairHoverTimeout });
|
await circleLocator.waitFor({ state: 'attached', timeout: crosshairHoverTimeout });
|
||||||
await circleLocator.hover({ force: true, timeout: crosshairHoverTimeout });
|
await circleLocator.hover({ force: true, timeout: crosshairHoverTimeout });
|
||||||
|
|
||||||
await page.mouse.down();
|
await dragHandleFromCenter(circleLocator, 0, DRAG_DISTANCE);
|
||||||
|
|
||||||
const position = await getMousePosition(page);
|
|
||||||
await page.mouse.move(position.x, position.y + 100);
|
|
||||||
await page.mouse.up();
|
|
||||||
}
|
}
|
||||||
|
|
||||||
function crosshairsFactory(
|
function crosshairsFactory(
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user