Skip to content

fix reverse animation play and improve code structure #5028

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

Open
wants to merge 21 commits into
base: master
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
21 commits
Select commit Hold shift + click to select a range
9f27799
fix reverse animation play and improve code structure
mohammadbaghaei Apr 16, 2025
9ec889b
improve if segments readablity
mohammadbaghaei Apr 16, 2025
6f4e6a5
update dependencies and upgrade to threejs r175
mohammadbaghaei Apr 16, 2025
5fea94a
update documention
mohammadbaghaei Apr 16, 2025
d3cce80
fix #5009 issue
mohammadbaghaei Apr 16, 2025
8ab2c7c
Merge branch 'google:master' into master
mohammadbaghaei May 24, 2025
7a898b8
Merge branch 'google:master' into master
mohammadbaghaei Jun 28, 2025
6c62d7e
update all dependencies and upgrade to Three.js r176
mohammadbaghaei May 24, 2025
a069cd5
refactor: replace .eslintrc.yaml with eslint.config.js and consolidat…
mohammadbaghaei May 24, 2025
e8d2f6d
fix: enhance screenshot functionality to support multiple image formats
mohammadbaghaei May 25, 2025
c4e4ee2
add test for appendAnimation and detachAnimation functions
mohammadbaghaei Jun 1, 2025
a040f9e
update dependencies
mohammadbaghaei Jun 1, 2025
ed183f1
update dependencies and upgrade to threejs 177
mohammadbaghaei Jun 28, 2025
a041344
add script to auto sync threejs and model-viewer versions on deploy t…
mohammadbaghaei Jun 28, 2025
51b430b
format and lint codes
mohammadbaghaei Jun 29, 2025
514ae4e
fix eslint config
mohammadbaghaei Jun 29, 2025
d0454c5
improve webxr support detection and fix loading error on some devices…
mohammadbaghaei Jun 29, 2025
1f26b5e
lint codes and improve codes structure
mohammadbaghaei Jun 29, 2025
056d168
fix test errors
mohammadbaghaei Jun 30, 2025
ce0d188
fix fidelity test error
mohammadbaghaei Jul 1, 2025
eed51b5
update dependencies
mohammadbaghaei Jul 1, 2025
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
12 changes: 0 additions & 12 deletions .eslintignore

This file was deleted.

68 changes: 0 additions & 68 deletions .eslintrc.yaml

This file was deleted.

133 changes: 133 additions & 0 deletions eslint.config.mjs
Original file line number Diff line number Diff line change
@@ -0,0 +1,133 @@
import js from '@eslint/js';
import globals from 'globals';
import tseslint from '@typescript-eslint/eslint-plugin';
import tsParser from '@typescript-eslint/parser';
import mochaPlugin from 'eslint-plugin-mocha';
import wcPlugin from 'eslint-plugin-wc';

export default [
{
ignores: [
'**/node_modules',
'scripts/**/*.js',
'packages/*/dist',
'packages/**/*.d.ts',
'packages/*/src/*-css.ts',
],
},
js.configs.recommended,
{
files: ['**/*.ts', '**/*.js'],
languageOptions: {
ecmaVersion: 2017,
sourceType: 'module',
globals: {
...globals.browser,
goog: false,
},
parser: tsParser,
parserOptions: {
ecmaVersion: 2017,
sourceType: 'module',
},
},
plugins: {
'@typescript-eslint': tseslint,
mocha: mochaPlugin,
wc: wcPlugin,
},
settings: {
wc: {
elementBaseClasses: ['BaseElement', 'LitElement', 'FormElement'],
},
},
rules: {
// قوانین پایه
'@typescript-eslint/explicit-function-return-type': 'off',
'@typescript-eslint/indent': 'off',
'indent': 'off',
'max-len': 'off',
'block-spacing': 'off',
'keyword-spacing': 'off',
'space-before-function-paren': 'off',
'@typescript-eslint/explicit-member-accessibility': ['error', { accessibility: 'no-public' }],

// سبک کدنویسی
'no-new': 'warn',
'quotes': ['error', 'single', { avoidEscape: true }],
'no-var': 'error',
'curly': 'error',
'no-floating-decimal': 'error',
'prefer-const': 'error',
'comma-dangle': 'off',
'require-jsdoc': 'off',
'valid-jsdoc': 'off',

// برای type/const هم‌نام و shadow
'no-redeclare': 'off',
'no-shadow': 'off',
'@typescript-eslint/no-shadow': 'off',
'no-undef': 'off',

// استفاده نشده‌ها
'no-unused-vars': 'error',
'@typescript-eslint/no-unused-vars': 'off',

// قوانین mocha
'mocha/handle-done-callback': 'error',
'mocha/no-exclusive-tests': 'error',
'mocha/no-identical-title': 'error',
'mocha/no-nested-tests': 'error',
'mocha/no-pending-tests': 'error',
},
},
{
files: ['packages/**/*.ts'],
rules: {
'no-unused-vars': 'off',
'no-invalid-this': 'off',
'new-cap': 'off',
'@typescript-eslint/no-non-null-assertion': 'off',
'no-undef': 'off',
},
},
{
files: [
'packages/**/test/**/*.ts',
'packages/**/test/**/*.js',
'packages/**/*.spec.ts',
'packages/**/*.spec.js',
'packages/**/*.spec.mjs',
'packages/**/*.spec.cjs',
'packages/**/*.test.ts',
'packages/**/*.test.js',
'packages/**/*.test.mjs',
'packages/**/*.test.cjs',
],
languageOptions: {
globals: {
...globals.mocha,
...globals.browser,
goog: false,
},
},
},
{
files: [
'scripts/**/*.js',
'packages/render-fidelity-tools/**/*.{js,ts}',
'packages/model-viewer/scripts/**/*.js',
'packages/model-viewer/tools/**/*.js',
'packages/model-viewer/tools/**/*.ts',
'packages/model-viewer-effects/scripts/**/*.js',
'packages/model-viewer-effects/tools/**/*.js',
'packages/model-viewer-effects/tools/**/*.ts',
],
languageOptions: {
globals: {
...globals.node,
goog: false,
},
},
},
];
Loading