Skip to content
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

Added the ability to run and combine multiple animations simultaneously #4979

Open
wants to merge 24 commits into
base: master
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from 7 commits
Commits
Show all changes
24 commits
Select commit Hold shift + click to select a range
3c96aec
Added the ability to run and combine multiple animations simultaneous…
mohammadbaghaei Dec 22, 2024
ce1d45e
fix build warnings and errors and replace rollup-plugin-polyfill with…
mohammadbaghaei Dec 22, 2024
ee4c276
fix fidelity-tests chrome error
mohammadbaghaei Dec 23, 2024
80e7299
fix chrome install error on fidelity-tests
mohammadbaghaei Dec 23, 2024
044e7a9
fix fidelity-tests error on Fix dependencies step
mohammadbaghaei Dec 23, 2024
859fcfd
add no-sandbox args to puppeteer.launch
mohammadbaghaei Dec 23, 2024
194f682
cleanup github workflow
mohammadbaghaei Dec 23, 2024
0e7a581
add example for appendAnimation, improve modelviewer.dev styles, impr…
mohammadbaghaei Dec 28, 2024
1cadb92
Fix all requested changes in #4979 PR, improve the flexibility of app…
mohammadbaghaei Dec 28, 2024
523e1e3
improve detachAnimation flexibility
mohammadbaghaei Dec 28, 2024
4740302
update dependencies to latest version
mohammadbaghaei Dec 29, 2024
2035fde
fix #4960 issue
mohammadbaghaei Dec 29, 2024
e2dd816
Fix animation skipping when updating with appendAnimation method and …
mohammadbaghaei Jan 8, 2025
9066abc
Upgrade to three.js r172 and update dependencies and fix peer depende…
mohammadbaghaei Jan 8, 2025
3d0df06
add Cineon, Reinhard, Linear, none tone mapping options and update do…
mohammadbaghaei Jan 9, 2025
d945f08
revert peetDependencies change
mohammadbaghaei Jan 9, 2025
4b2e77b
fix package-lock error
mohammadbaghaei Jan 9, 2025
cceb8c1
fix repetitions and pingpong update bug
mohammadbaghaei Jan 22, 2025
d47a67c
add time option to appendAnimation function
mohammadbaghaei Jan 24, 2025
72910a4
fix editor "js-beautify" invalid src
mohammadbaghaei Jan 24, 2025
72b99ce
update dependencies
mohammadbaghaei Jan 25, 2025
2f9671a
improve editor and modelviewer.dev styles, add mobile responsive to e…
mohammadbaghaei Jan 29, 2025
51ff5d3
update dependencies
mohammadbaghaei Jan 30, 2025
5763db9
add ar-usdz-max-texture-size (related #4984 issue)
mohammadbaghaei Jan 30, 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
5,621 changes: 1,140 additions & 4,481 deletions package-lock.json

Large diffs are not rendered by default.

14 changes: 7 additions & 7 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -39,15 +39,15 @@
},
"homepage": "https://github.com/google/model-viewer#readme",
"devDependencies": {
"@typescript-eslint/eslint-plugin": "^5.31.0",
"@typescript-eslint/parser": "^5.31.0",
"@typescript-eslint/eslint-plugin": "^8.18.1",
"@typescript-eslint/parser": "^8.18.1",
"clang-format": "^1.8.0",
"eslint": "^8.20.0",
"eslint": "^9.17.0",
"eslint-config-google": "^0.14.0",
"eslint-plugin-mocha": "^10.1.0",
"eslint-plugin-wc": "^1.3.0",
"eslint-plugin-mocha": "^10.5.0",
"eslint-plugin-wc": "^2.2.0",
"http-server": "^14.1.1",
"husky": "^7.0.1",
"typescript": "5.6.3"
"husky": "^9.1.7",
"typescript": "5.7.2"
}
}
37 changes: 19 additions & 18 deletions packages/model-viewer-effects/package.json
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
{
"name": "@google/model-viewer-effects",
"type": "module",
"version": "1.4.0",
"version": "1.5.0",
"description": "Easily add and combine post-processing effects with <model-viewer>!",
"repository": "https://github.com/google/model-viewer/tree/master/packages/model-viewer-effects",
"bugs": {
Expand Down Expand Up @@ -76,33 +76,34 @@
"postprocessing": "^6.36.4"
},
"peerDependencies": {
"@google/model-viewer": "^4.0.0"
"@google/model-viewer": "^5.0.0"
},
"devDependencies": {
"@google/model-viewer": "^4.0.0",
"@rollup/plugin-commonjs": "^28.0.1",
"@rollup/plugin-node-resolve": "^15.3.0",
"@rollup/plugin-replace": "^6.0.1",
"@types/mocha": "^10.0.9",
"@types/pngjs": "^6.0.1",
"@types/three": "^0.169.0",
"@ungap/event-target": "^0.2.3",
"@google/model-viewer": "^5.0.0",
"@rollup/plugin-commonjs": "^28.0.2",
"@rollup/plugin-node-resolve": "^16.0.0",
"@rollup/plugin-replace": "^6.0.2",
"@rollup/plugin-swc": "^0.4.0",
"@rollup/plugin-terser": "^0.4.4",
"@swc/core": "^1.10.1",
"@types/mocha": "^10.0.10",
"@types/pngjs": "^6.0.5",
"@types/three": "^0.171.0",
"@ungap/event-target": "^0.2.4",
"@web/test-runner": "^0.19.0",
"@web/test-runner-playwright": "^0.11.0",
"chai": "^5.1.2",
"focus-visible": "^5.2.0",
"focus-visible": "^5.2.1",
"http-server": "^14.1.1",
"mocha": "^10.0.0",
"mocha": "^11.0.1",
"npm-run-all": "^4.1.5",
"rollup": "^4.24.0",
"rollup": "^4.29.1",
"rollup-plugin-cleanup": "^3.2.1",
"rollup-plugin-dts": "^6.1.1",
"rollup-plugin-polyfill": "^3.0.0",
"@rollup/plugin-terser": "^0.4.4",
"three": "^0.170.0",
"typescript": "5.6.3"
"three": "^0.171.0",
"typescript": "5.7.2"
},
"publishConfig": {
"access": "public"
}
}
}
10 changes: 5 additions & 5 deletions packages/model-viewer-effects/rollup.config.js
Original file line number Diff line number Diff line change
Expand Up @@ -14,14 +14,14 @@
*/

import commonjs from '@rollup/plugin-commonjs';
import {nodeResolve as resolve} from '@rollup/plugin-node-resolve';
import { nodeResolve as resolve } from '@rollup/plugin-node-resolve';
import replace from '@rollup/plugin-replace';
import terser from '@rollup/plugin-terser';
import cleanup from 'rollup-plugin-cleanup';
import dts from 'rollup-plugin-dts';
import polyfill from 'rollup-plugin-polyfill';
import swc from '@rollup/plugin-swc';

const {NODE_ENV} = process.env;
const { NODE_ENV } = process.env;

const onwarn = (warning, warn) => {
// Suppress non-actionable warning caused by TypeScript boilerplate:
Expand All @@ -30,7 +30,7 @@ const onwarn = (warning, warn) => {
}
};

let plugins = [resolve(), replace({'Reflect.decorate': 'undefined'})];
let plugins = [resolve(), replace({ 'Reflect.decorate': 'undefined', preventAssignment: true })];

const watchFiles = ['lib/**'];

Expand Down Expand Up @@ -59,7 +59,7 @@ if (NODE_ENV !== 'development') {
const pluginsIE11 = [
...plugins,
commonjs(),
polyfill(['object.values/auto']),
swc(),
cleanup({
// Ideally we'd also clean third_party/three, which saves
// ~45kb in filesize alone... but takes 2 minutes to build
Expand Down
37 changes: 19 additions & 18 deletions packages/model-viewer/package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "@google/model-viewer",
"version": "4.0.0",
"version": "5.0.0",
mohammadbaghaei marked this conversation as resolved.
Show resolved Hide resolved
"description": "Easily display interactive 3D models on the web and in AR!",
"repository": "https://github.com/google/model-viewer",
"bugs": {
Expand Down Expand Up @@ -83,35 +83,36 @@
"3d"
],
"dependencies": {
"lit": "^3.2.1",
"@monogrid/gainmap-js": "^3.0.1"
"@monogrid/gainmap-js": "^3.1.0",
"lit": "^3.2.1"
},
"peerDependencies": {
"three": "^0.170.0"
"three": "^0.171.0"
},
"devDependencies": {
"@rollup/plugin-commonjs": "^28.0.1",
"@rollup/plugin-node-resolve": "^15.3.0",
"@rollup/plugin-replace": "^6.0.1",
"@types/mocha": "^10.0.9",
"@types/pngjs": "^6.0.1",
"@types/three": "^0.169.0",
"@ungap/event-target": "^0.2.3",
"@rollup/plugin-commonjs": "^28.0.2",
"@rollup/plugin-node-resolve": "^16.0.0",
"@rollup/plugin-replace": "^6.0.2",
"@rollup/plugin-swc": "^0.4.0",
"@rollup/plugin-terser": "^0.4.4",
"@swc/core": "^1.10.1",
"@types/mocha": "^10.0.10",
"@types/pngjs": "^6.0.5",
"@types/three": "^0.171.0",
"@ungap/event-target": "^0.2.4",
"@web/test-runner": "^0.19.0",
"@web/test-runner-playwright": "^0.11.0",
"chai": "^5.1.2",
"http-server": "^14.1.1",
"mocha": "^10.0.0",
"mocha": "^11.0.1",
"npm-run-all": "^4.1.5",
"rollup": "^4.24.0",
"rollup": "^4.29.1",
"rollup-plugin-cleanup": "^3.2.1",
"rollup-plugin-dts": "^6.1.1",
"rollup-plugin-polyfill": "^3.0.0",
"@rollup/plugin-terser": "^0.4.4",
"typescript": "5.6.3",
"three": "^0.170.0"
"three": "^0.171.0",
"typescript": "5.7.2"
},
"publishConfig": {
"access": "public"
}
}
}
86 changes: 43 additions & 43 deletions packages/model-viewer/rollup.config.js
Original file line number Diff line number Diff line change
Expand Up @@ -14,14 +14,14 @@
*/

import commonjs from '@rollup/plugin-commonjs';
import {nodeResolve as resolve} from '@rollup/plugin-node-resolve';
import { nodeResolve as resolve } from '@rollup/plugin-node-resolve';
import replace from '@rollup/plugin-replace';
import terser from '@rollup/plugin-terser';
import cleanup from 'rollup-plugin-cleanup';
import dts from 'rollup-plugin-dts';
import polyfill from 'rollup-plugin-polyfill';
import swc from '@rollup/plugin-swc';

const {NODE_ENV} = process.env;
const { NODE_ENV } = process.env;

const onwarn = (warning, warn) => {
// Suppress non-actionable warning caused by TypeScript boilerplate:
Expand All @@ -31,45 +31,45 @@ const onwarn = (warning, warn) => {
};

let commonPlugins =
[resolve({dedupe: 'three'}), replace({'Reflect.decorate': 'undefined'})];
[resolve({ dedupe: 'three' }), replace({ 'Reflect.decorate': 'undefined', preventAssignment: true })];

const watchFiles = ['lib/**'];

const createModelViewerOutput =
(file, format, plugins = commonPlugins, external = []) => {
const globals = external.reduce((acc, mod) => {
acc[mod] =
mod; // Assuming global variable names are the same as module names
return acc;
}, {});
(file, format, plugins = commonPlugins, external = []) => {
const globals = external.reduce((acc, mod) => {
acc[mod] =
mod; // Assuming global variable names are the same as module names
return acc;
}, {});

return {
input: './lib/model-viewer.js',
output: {
file,
format,
sourcemap: true,
name: 'ModelViewerElement',
globals
},
external,
watch: {include: watchFiles},
plugins,
onwarn
};
return {
input: './lib/model-viewer.js',
output: {
file,
format,
sourcemap: true,
name: 'ModelViewerElement',
globals
},
external,
watch: { include: watchFiles },
plugins,
onwarn
};
};

const outputOptions = [
createModelViewerOutput('./dist/model-viewer.js', 'esm'),
createModelViewerOutput(
'./dist/model-viewer-module.js', 'esm', commonPlugins, ['three'])
'./dist/model-viewer-module.js', 'esm', commonPlugins, ['three'])
];

if (NODE_ENV !== 'development') {
const pluginsIE11 = [
...commonPlugins,
commonjs(),
polyfill(['object.values/auto']),
swc(),
cleanup({
// Ideally we'd also clean third_party/three, which saves
// ~45kb in filesize alone... but takes 2 minutes to build
Expand All @@ -81,28 +81,28 @@ if (NODE_ENV !== 'development') {
// IE11 does not support modules, so they are removed here, as well as in a
// dedicated unit test build which is needed for the same reason.
outputOptions.push(
createModelViewerOutput('./dist/model-viewer-umd.js', 'umd', pluginsIE11),
/** Bundled w/o three */
createModelViewerOutput(
'./dist/model-viewer-module-umd.js', 'umd', pluginsIE11, ['three']));
createModelViewerOutput('./dist/model-viewer-umd.js', 'umd', pluginsIE11),
/** Bundled w/o three */
createModelViewerOutput(
'./dist/model-viewer-module-umd.js', 'umd', pluginsIE11, ['three']));

// Minified Versions
const minifiedPlugins = [...commonPlugins, terser()];

outputOptions.push(
createModelViewerOutput(
'./dist/model-viewer.min.js', 'esm', minifiedPlugins),
createModelViewerOutput(
'./dist/model-viewer-umd.min.js', 'umd', minifiedPlugins),
createModelViewerOutput(
'./dist/model-viewer-module.min.js',
'esm',
minifiedPlugins,
['three']),
createModelViewerOutput(
'./dist/model-viewer-module-umd.min.js', 'umd', minifiedPlugins, [
'three'
]));
createModelViewerOutput(
'./dist/model-viewer.min.js', 'esm', minifiedPlugins),
createModelViewerOutput(
'./dist/model-viewer-umd.min.js', 'umd', minifiedPlugins),
createModelViewerOutput(
'./dist/model-viewer-module.min.js',
'esm',
minifiedPlugins,
['three']),
createModelViewerOutput(
'./dist/model-viewer-module-umd.min.js', 'umd', minifiedPlugins, [
'three'
]));

outputOptions.push({
input: './lib/model-viewer.d.ts',
Expand Down
Loading
Loading