Skip to content

Commit

Permalink
chore: update deps
Browse files Browse the repository at this point in the history
  • Loading branch information
mistic100 committed Nov 15, 2024
1 parent 3d71c63 commit c49574e
Show file tree
Hide file tree
Showing 17 changed files with 1,287 additions and 1,382 deletions.
3 changes: 2 additions & 1 deletion .eslintrc.js
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,8 @@ module.exports = {
'@typescript-eslint/array-type': ['error', { default: 'array-simple' }],
'@typescript-eslint/consistent-type-definitions': ['error', 'type'],
'@typescript-eslint/class-literal-property-style': 'off',
'@typescript-eslint/no-unused-vars': ['error', { argsIgnorePattern: '^_' }]
'@typescript-eslint/no-unused-vars': ['error', { argsIgnorePattern: '^_' }],
'@typescript-eslint/no-unused-expressions': ['error', { allowShortCircuit: true, allowTernary: true }],
},
ignorePatterns: ['**/dist/**/*', '*.js'],
};
4 changes: 2 additions & 2 deletions .github/workflows/close-milestone.yml
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ on:

jobs:
close:
if: github.repository == 'mistic100/Photo-Sphere-Viewer'
if: ${{ github.repository == 'mistic100/Photo-Sphere-Viewer' }}

runs-on: ubuntu-latest

Expand All @@ -25,4 +25,4 @@ jobs:
with:
milestone: ${{ steps.close.outputs.milestone_id }}
body: |
This feature/bug fix has been released in [version ${{ github.ref_name }}](https://github.com/mistic100/Photo-Sphere-Viewer/releases/tag/${{ github.ref_name }}).
This feature/bug fix has been released in [version ${{ github.ref_name }}](https://github.com/${{ github.repository }}/releases/tag/${{ github.ref_name }}).
5 changes: 3 additions & 2 deletions .github/workflows/comment-issues.yml
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
name: comment-issues
run-name: Comment on issues

on:
issues:
Expand All @@ -10,7 +11,7 @@ permissions:

jobs:
missing-demo:
if: github.event.label.name == 'missing demo'
if: ${{ github.event.label.name == 'missing demo' }}

runs-on: ubuntu-latest

Expand All @@ -21,7 +22,7 @@ jobs:
GH_TOKEN: ${{ secrets.GITHUB_TOKEN }}
GH_REPO: ${{ github.repository }}
NUMBER: ${{ github.event.issue.number }}
BODY: >
BODY: |
An isolated working demo is required in order to analyze this issue.
You can easily create a demo on Codepen/JSFiddle/CodeSandBox by clicking the buttons on the top of every example in the documentation.
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/pre-release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ on:

jobs:
release:
if: github.repository == 'mistic100/Photo-Sphere-Viewer'
if: ${{ github.repository == 'mistic100/Photo-Sphere-Viewer' }}

runs-on: ubuntu-latest

Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ on:

jobs:
release:
if: github.repository == 'mistic100/Photo-Sphere-Viewer'
if: ${{ github.repository == 'mistic100/Photo-Sphere-Viewer' }}

runs-on: ubuntu-latest

Expand Down
5 changes: 3 additions & 2 deletions .github/workflows/stale-issues.yml
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
name: stale-issues
run-name: Update stale issues

on:
schedule:
Expand All @@ -11,7 +12,7 @@ permissions:

jobs:
stale-awaiting-answer:
if: github.repository == 'mistic100/Photo-Sphere-Viewer'
if: ${{ github.repository == 'mistic100/Photo-Sphere-Viewer' }}

runs-on: ubuntu-latest

Expand All @@ -27,7 +28,7 @@ jobs:
This pulll request has been automatically marked as stale because not enough information was provided. It will be closed if no further activity occurs.
stale-help-wanted:
if: github.repository == 'mistic100/Photo-Sphere-Viewer'
if: ${{ github.repository == 'mistic100/Photo-Sphere-Viewer' }}

runs-on: ubuntu-latest

Expand Down
8 changes: 2 additions & 6 deletions cypress/e2e/plugins/gallery.cy.ts
Original file line number Diff line number Diff line change
Expand Up @@ -168,9 +168,7 @@ describe('plugin: gallery', () => {
cy.get('[data-psv-gallery-item=1]')
.click()
.should('have.class', 'psv-gallery-item--active')
.then(() => {
expect(callback).to.be.calledOnceWith('1');
});
.then(() => expect(callback).to.be.calledOnceWith('1'));

// not changed
checkPanorama('sphere-small.jpg');
Expand All @@ -182,9 +180,7 @@ describe('plugin: gallery', () => {

cy.get('[data-psv-gallery-item=1]')
.click()
.then(() => {
expect(callback).to.not.have.been.called;
});
.then(() => expect(callback).to.not.have.been.called);
});

it('should hide the button when no items', () => {
Expand Down
31 changes: 17 additions & 14 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -33,41 +33,44 @@
"devDependencies": {
"@cypress/code-coverage": "^3.13.6",
"@lcov-viewer/istanbul-report": "^1.4.0",
"@stylistic/stylelint-plugin": "^3.1.0",
"@stylistic/stylelint-plugin": "^3.1.1",
"@types/mocha": "^10.0.9",
"@types/three": "^0.169.0",
"@typescript-eslint/eslint-plugin": "^7.16.0",
"@typescript-eslint/parser": "^7.16.0",
"@typescript-eslint/eslint-plugin": "^8.14.0",
"@typescript-eslint/parser": "^8.14.0",
"alive-server": "^1.3.0",
"cypress": "^13.15.0",
"cypress": "^13.15.2",
"cypress-mochawesome-reporter": "^3.8.2",
"cypress-on-fix": "^1.0.3",
"cypress-visual-regression": "^5.2.2",
"esbuild-sass-plugin": "^3.3.0",
"eslint": "^8.57.0",
"inquirer": "^12.0.0",
"esbuild-sass-plugin": "^3.3.1",
"eslint": "^8.57.1",
"inquirer": "^12.1.0",
"mocha": "^10.8.2",
"mocha-junit-reporter": "^2.2.1",
"nyc": "^17.1.0",
"postcss": "^8.4.21",
"postcss": "^8.4.49",
"prettier": "^2.8.8",
"queue": "^7.0.0",
"scss-bundle": "^3.1.2",
"selfsigned": "^2.4.1",
"set-versions": "^1.0.3",
"sort-package-json": "^2.10.0",
"sort-package-json": "^2.10.1",
"stylelint": "^16.10.0",
"stylelint-config-standard-scss": "^13.1.0",
"ts-node": "^10.9.1",
"ts-node": "^10.9.2",
"tsc": "^2.0.4",
"tsup": "^8.3.0",
"turbo": "^2.2.3",
"typedoc": "^0.26.7",
"tsup": "^8.3.5",
"turbo": "^2.3.0",
"typedoc": "^0.26.11",
"typedoc-plugin-extras": "^3.1.0",
"typescript": "^5.6.2"
"typescript": "^5.6.3"
},
"resolutions": {
"yargs": "^16.2.0",
"nyc": "^17.1.0"
},
"dependencies": {
"yargs": "^17.7.2"
}
}
4 changes: 2 additions & 2 deletions packages/core/src/data/system.ts
Original file line number Diff line number Diff line change
Expand Up @@ -85,7 +85,7 @@ function getWebGLCtx(): WebGLRenderingContext | null {
try {
const canvas = document.createElement('canvas');
return canvas.getContext('webgl2');
} catch (e) {
} catch {
return null;
}
}
Expand Down Expand Up @@ -153,7 +153,7 @@ function getMaxCanvasWidth(maxWidth: number): number {
if (ctx.getImageData(0, 0, 1, 1).data[0] > 0) {
pass = true;
}
} catch (e) {
} catch {
// continue
}

Expand Down
2 changes: 1 addition & 1 deletion packages/core/src/services/EventsHandler.ts
Original file line number Diff line number Diff line change
Expand Up @@ -501,7 +501,7 @@ export class EventsHandler extends AbstractService {
try {
const textureCoords = this.viewer.dataHelper.sphericalCoordsToTextureCoords(data);
Object.assign(data, textureCoords);
} catch (e) {
} catch {
// nothing
}

Expand Down
2 changes: 1 addition & 1 deletion packages/cubemap-adapter/src/CubemapAdapter.ts
Original file line number Diff line number Diff line change
Expand Up @@ -267,7 +267,7 @@ export class CubemapAdapter extends AbstractAdapter<CubemapPanorama, CubemapData
const ratio = Math.min(1, SYSTEM.maxCanvasWidth / img.height);
const tileWidth = Math.floor(img.height * ratio);

const textures = {} as { [K in CubemapFaces]: Texture };
const textures = {} as Record<CubemapFaces, Texture>;

for (let i = 0; i < 6; i++) {
const buffer = new OffscreenCanvas(tileWidth, tileWidth);
Expand Down
2 changes: 1 addition & 1 deletion packages/cubemap-adapter/src/model.ts
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ export type CubemapFaces = 'left' | 'front' | 'right' | 'back' | 'top' | 'bottom
/**
* Object defining a cubemap as separated files
*/
export type Cubemap = { [K in CubemapFaces]: string };
export type Cubemap = Record<CubemapFaces, string>;

/**
* Object defining a cubemap as separated files
Expand Down
2 changes: 1 addition & 1 deletion packages/cubemap-adapter/src/utils.ts
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@ export function cleanCubemapArray<T>(panorama: T[]): T[] {
/**
* Given an object where keys are faces names, returns an array in 3JS order
*/
export function cleanCubemap<T>(cubemap: { [K in CubemapFaces]: T }): T[] {
export function cleanCubemap<T>(cubemap: Record<CubemapFaces, T>): T[] {
const cleanPanorama: T[] = [];

if (!isCubemap(cubemap)) {
Expand Down
2 changes: 1 addition & 1 deletion packages/shared/autorotate-utils.ts
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ export function debugCurve(markers: MarkersPlugin, curve: Array<[number, number]
debugMarkers.forEach((marker) => {
try {
markers.removeMarker(marker);
} catch (e) {
} catch {
// noop
}
});
Expand Down
2 changes: 1 addition & 1 deletion packages/virtual-tour-plugin/src/VirtualTourPlugin.ts
Original file line number Diff line number Diff line change
Expand Up @@ -627,7 +627,7 @@ export class VirtualTourPlugin extends AbstractConfigurablePlugin<
width: 20,
height: 20,
},
}),
});

this.__getTooltipContent(link).then((content) => {
if (content) {
Expand Down
4 changes: 3 additions & 1 deletion turbo.json
Original file line number Diff line number Diff line change
@@ -1,7 +1,9 @@
{
"$schema": "https://turborepo.org/schema.json",
"globalDependencies": [
"build/**",
"build/*.{ts,mjs}",
"build/plugins/*",
"build/templates/*",
"tsconfig.json",
".eslintrc.json",
".mocharc.json",
Expand Down
Loading

0 comments on commit c49574e

Please sign in to comment.