107 Commits

Author SHA1 Message Date
Davide Tantillo
0fa960251a WIP - Added/Changed:
- overlay loading: now overlay is moved as the last element from where it is inserted to avoid widgets covered by backgrounds of html elements after it.
- default overlayId
- widget position in overlay coordinates (worldX, worldY) (experimental)
- cursor position on widget world (cursorWorldX, cursorWorldY) (experimental)
- jsonSkeletonKey: allow to load a specific skeleton in json containing multiple skeletons
- onViewportManualStart: start the widget when in manual-start and enters the viewport the first time
- overlayAssignedPromise: a promise that resolves when the overlay is assigned to the widget. Reads the comment on it
- appendTo: to append the widget created using js and wait for the overlayAssignedPromise to resolve
- changed how loadingPromise works
- added cursorCanvasX, cursorCanvasY, cursorWorldX, cursorWorldY to overlay (experimental)
2024-10-18 16:42:57 +02:00
Davide Tantillo
de7494036c Initial support of spine-widget into scrollable containers, and overlay-id for multiple spine-overlay.
working
2024-10-14 18:22:09 +02:00
Davide Tantillo
e9a07bd6b9 Changes to make the widget more dynamic while changing attributes. See now webcomponent-gui.html. 2024-10-08 17:26:31 +02:00
Davide Tantillo
a34b8273b3 Exposed parameters to set bounds.
Deeply changed how bounds work, especially for the fact that they are not auto recalculated anymore if the animation is changed (unless autoRecalculateBounds is set to true).
2024-10-04 17:38:23 +02:00
Davide Tantillo
f4837ad8eb Add padding attributes/properties. 2024-10-03 13:05:12 +02:00
Davide Tantillo
bedce14780 Restore resize observer since the window resize event does not fire on body resize, but on window resize. It's supported by 93% of the browsers. 2024-10-03 11:05:14 +02:00
Davide Tantillo
8cc5a2ba5e Fix widget using overlay before overlay webcomponent is fully upgraded. 2024-10-03 09:23:48 +02:00
Davide Tantillo
6fa149756a Fix x-axis and y-axis not working in clip mode. 2024-10-01 13:01:53 +02:00
Davide Tantillo
6108d625c0 Fixed infinite requestAnimationFrame calls. 2024-09-30 12:07:36 +02:00
Davide Tantillo
95f2119e46 Fixed input remove listener. Run tsfmt. 2024-09-30 11:52:02 +02:00
Davide Tantillo
2db1873fd5 Managed lifecycle for SpineWebComponentWidget. 2024-09-30 11:36:39 +02:00
Davide Tantillo
5c42b6fa2d Manage lifecycle for Input and SpineWebComponentOverlay. Missing SpineWebComponentWidget. 2024-09-27 16:06:23 +02:00
Davide Tantillo
e26034426a Made some changes to make it work on old browsers. 2024-09-27 12:30:09 +02:00
Davide Tantillo
27edd8a284 Made span fps display configurable. 2024-09-26 17:09:15 +02:00
Davide Tantillo
3b4ab02d92 Fix 1 pixel misalignment in non clip mode. 2024-09-26 15:45:19 +02:00
Davide Tantillo
3d77f1c26e Removed custom LoadingSpinnerWindget class. Added a new specific method in LoadingSpinner. 2024-09-26 15:40:16 +02:00
Davide Tantillo
9399c42ec7 Removed useless changes on other classes. 2024-09-26 14:41:41 +02:00
Davide Tantillo
e9873147c2 Fix zoom bug due to screen size remaining the same at different zoom level. 2024-09-26 14:22:59 +02:00
Davide Tantillo
e8511ca8b2 Modified export script to copy chibi 2024-09-26 14:22:59 +02:00
Davide Tantillo
4536789e39 WIP - Refactor + animation and skin attribute change will reinit the widget 2024-09-26 14:22:59 +02:00
Davide Tantillo
d178f5de7c WIP - Doc before refactor 2024-09-26 14:22:59 +02:00
Davide Tantillo
b4f11c2f21 Refactor drag logic. Drag works with clip too. 2024-09-26 14:22:59 +02:00
Davide Tantillo
d2c29c5cfb Removed code duplication for clipping into div 2024-09-26 14:22:59 +02:00
Davide Tantillo
e67aa324fe Removed SpineCanvasApp dependency. 2024-09-26 14:22:59 +02:00
Davide Tantillo
847c152f2a Added clip. 2024-09-26 14:22:59 +02:00
Davide Tantillo
034c6266e8 Translate is done each frame through requestAnimationFrame. 2024-09-26 14:22:59 +02:00
Davide Tantillo
26d1ca739d Add OffScreenUpdateBehaviour 2024-09-26 14:22:59 +02:00
Davide Tantillo
bc192f4178 Renamed 2024-09-26 14:22:59 +02:00
Davide Tantillo
59a7715b2e mostly work - when overflow top/bottom...are > 0, widgets slightly jump on up and down fast scroll. 2024-09-26 14:22:59 +02:00
Davide Tantillo
96282273f8 Loading 2024-09-26 14:22:59 +02:00
Davide Tantillo
221e3f6624 web component 2024-09-26 14:22:59 +02:00
Davide Tantillo
d92046f325 Scroll should be resolved 2024-09-26 14:22:58 +02:00
Davide Tantillo
394b97b105 Zoom fix - WIP horizontal scroll bug see comment at line 495 2024-09-26 14:22:58 +02:00
Davide Tantillo
7f5b934a64 overlay fix scroll cut 2024-09-26 14:22:58 +02:00
Davide Tantillo
2da5b06c2d overlay 2024-09-26 14:22:58 +02:00
Davide Tantillo
3b5d74e0e8 overlay 4 2024-09-26 14:22:58 +02:00
Davide Tantillo
9d1109c9dc canvas4 2024-09-26 14:22:58 +02:00
Davide Tantillo
09ea76aa14 [ts] poc wegl overlay 2024-09-26 14:22:58 +02:00
Davide Tantillo
b4d61790f7 [ts] Port of earlier clipping cleanup commit 485de74: SkeletonClipping.ClipTriangles clean up. 2024-06-11 15:18:26 +02:00
Davide Tantillo
f3097222f9 [ts] Skeleton.getBounds() applies clipping, see #2515. Port of commits b043e5c, 637321a and 2049bed. 2024-05-03 10:42:25 +02:00
Mario Zechner
944ccdce3e Merge branch '4.1' into 4.2-beta
# Conflicts:
#	spine-ts/package-lock.json
#	spine-ts/package.json
#	spine-ts/spine-canvas/package.json
#	spine-ts/spine-core/package.json
#	spine-ts/spine-phaser/package.json
#	spine-ts/spine-pixi/package.json
#	spine-ts/spine-player/package.json
#	spine-ts/spine-threejs/package.json
#	spine-ts/spine-webgl/package.json
2023-11-06 12:47:46 +01:00
Mario Zechner
9d4d86ced3 [ts] Attempt to fix incompatibility with Node's ESM implementation. See #2407 2023-11-06 12:42:00 +01:00
Mario Zechner
087b2688db [c] Closes #2394, double free of sequences in mesh attachments. 2023-10-11 11:44:36 +02:00
Nathan Sweet
351d42f511 [ts] Source whitespace. 2023-10-06 14:08:04 -04:00
Mario Zechner
1e657e8cac Merge branch '4.1' into 4.2-beta
# Conflicts:
#	spine-ts/package-lock.json
#	spine-ts/package.json
#	spine-ts/spine-canvas/package.json
#	spine-ts/spine-core/package.json
#	spine-ts/spine-phaser/package.json
#	spine-ts/spine-pixi/package.json
#	spine-ts/spine-player/package.json
#	spine-ts/spine-threejs/package.json
#	spine-ts/spine-webgl/package.json
2023-09-22 16:06:38 +02:00
Mario Zechner
c198203695 [ts] Closes #2370, added SpineCanvas.dispose and callback. 2023-09-22 15:55:59 +02:00
Mario Zechner
4e7c4a9159 Merge branch '4.1' into 4.2-beta 2023-09-14 13:13:02 +02:00
Mario Zechner
b5c5fb6bde Formatting. 2023-09-14 13:12:53 +02:00
Mario Zechner
b33c6c58cc Merge branch '4.1' into 4.2-beta
# Conflicts:
#	spine-ts/package-lock.json
#	spine-ts/package.json
#	spine-ts/spine-canvas/package.json
#	spine-ts/spine-core/package.json
#	spine-ts/spine-phaser/package.json
#	spine-ts/spine-pixi/package.json
#	spine-ts/spine-player/package.json
#	spine-ts/spine-threejs/package.json
#	spine-ts/spine-webgl/package.json
2023-09-13 22:29:16 +02:00
Mario Zechner
a397b8fe3f [webgl] Fix blend modes, see #2025, #2347 2023-09-13 22:26:27 +02:00