michalochman / react-pixi-fiber

Write PixiJS applications using React declarative style.
MIT License
858 stars 94 forks source link

Support Pixi 7.1 events #306

Closed zOadT closed 1 year ago

zOadT commented 1 year ago

Utilizes the work in https://github.com/pixijs/pixijs/pull/8876 to support event handler props for Pixi.js >= 7.1

Note: Pixi.js 7.1 isn't released yet and I also have to test the typings for Pixi < 7

codesandbox[bot] commented 1 year ago

CodeSandbox logoCodeSandbox logo  Open in CodeSandbox Web Editor | VS Code | VS Code Insiders

codesandbox-ci[bot] commented 1 year ago

This pull request is automatically built and testable in CodeSandbox.

To see build info of the built libraries, click here or the icon next to each commit SHA.

Latest deployment of this branch, based on commit 1110ef634587aa9f850e7d51226c283a0c534e12:

Sandbox Source
React Configuration
React Typescript Configuration
examples Configuration
React Pixi Fiber template Configuration
React Pixi Fiber TypeScript template Configuration
React Pixi Fiber demo – Rotating Bunny Configuration
React Pixi Fiber demo – AnimatedSprite Configuration
react-pixi-fiber text alignment Configuration
React Pixi Fiber with Redux Configuration
React Pixi Fiber demo – Animated.ValueXY Configuration
zOadT commented 1 year ago

Hey! Pixi.js 7.1 got released yesterday. I tested this branch with pixi.js 7.1 and pixi.js 6.5.1 and it seems to work fine for both of them.

I found another issue with pixi.js 7.1 (unrelated to this PR) though. But I would open an issue for that and handle that in another PR if that's ok.

michalochman commented 1 year ago

Hi @zOadT, please do!

zOadT commented 1 year ago

Hello @michalochman, the issue I meant is #311. I want to handle that separately (because it is unrelated) but actually still wanted to get this PR merged 😅 (of course only if you don't have any issues with this PR)

michalochman commented 1 year ago

Sorry @zOadT! I misunderstood and thought your changes are not needed after fix in PixiJS 7.1.

michalochman commented 1 year ago

Now I remember that they have prepended event props with on. Looks good, thanks for your contribution.

zOadT commented 1 year ago

No problem, thank you! 🙂

michalochman commented 1 year ago

Released in react-pixi-fiber@1.0.6 🎉