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

Add FluidPlugin for fluid-like movement #5214

Closed
wants to merge 8 commits into from
Closed

Conversation

sweep-ai[bot]
Copy link

@sweep-ai sweep-ai bot commented Sep 18, 2023

Description

This PR adds a new FluidPlugin to the tsParticles codebase, which enables a fluid-like movement for the particles. The plugin provides its own fluid options that can be toggled on or off to control the behavior of the fluid-like movement. The implementation is based on the codepen provided by the user.

Summary of Changes

  • Added FluidPlugin.ts to engine/src/Plugins:
    • Implemented the logic for the fluid-like movement in the FluidPlugin class.
  • Modified IOptions.ts in engine/src/Options/Interfaces:
    • Added a new property fluid of type FluidOptions to the IOptions interface.
  • Added FluidOptions.ts to engine/src/Options/Interfaces:
    • Defined the FluidOptions interface with properties to control the behavior of the fluid-like movement.
  • Modified install.js in engine/scripts:
    • Added the FluidPlugin to the list of installed plugins.

Please review and merge this PR to incorporate the fluid-like movement feature into tsParticles.

Fixes #208.


🎉 Latest improvements to Sweep:


💡 To get Sweep to edit this pull request, you can:

  • Leave a comment below to get Sweep to edit the entire PR
  • Leave a comment in the code will only modify the file
  • Edit the original issue to get Sweep to recreate the PR from scratch

@sweep-ai sweep-ai bot added the sweep Assigns Sweep to an issue or pull request. label Sep 18, 2023
@sweep-ai sweep-ai bot mentioned this pull request Sep 18, 2023
4 tasks
@sweep-ai
Copy link
Author

sweep-ai bot commented Sep 18, 2023

GitHub actions yielded the following error.

The command that failed is tsparticles-engine@2.12.0 build:ci /home/runner/work/tsparticles/tsparticles/engine. Here are the relevant lines from the logs:

Prettier - started on src
Error: /home/runner/work/tsparticles/tsparticles/engine/src/Plugins/FluidPlugin.ts is not formatted correctly
at prettifySrc (/home/runner/work/tsparticles/tsparticles/node_modules/�[4m.pnpm�[24m/@tsparticles+cli@1.13.0_webpack-cli@5.1.4/node_modules/�[4m@tsparticles�[24m/cli/dist/build/build-prettier.js:32:27)
at async Command.<anonymous> (/home/runner/work/tsparticles/tsparticles/node_modules/�[4m.pnpm�[24m/@tsparticles+cli@1.13.0_webpack-cli@5.1.4/node_modules/�[4m@tsparticles�[24m/cli/dist/build/build.js:41:23)
Prettier - done on src
/home/runner/work/tsparticles/tsparticles/node_modules/.pnpm/@tsparticles+cli@1.13.0_webpack-cli@5.1.4/node_modules/@tsparticles/cli/dist/build/build.js:59
throw new Error("Build failed");
^

Error: Build failed
at Command.<anonymous> (/home/runner/work/tsparticles/tsparticles/node_modules/�[4m.pnpm�[24m/@tsparticles+cli@1.13.0_webpack-cli@5.1.4/node_modules/�[4m@tsparticles�[24m/cli/dist/build/build.js:59:15)

Please note that some parts of the logs have been truncated for brevity.

This is likely a linting or type-checking issue with the source code. Update the code changed by the PR. Don't modify the existing tests.

I'm getting the same errors 3 times in a row, so I will stop working on fixing this PR.

@sweep-ai
Copy link
Author

sweep-ai bot commented Sep 18, 2023

GitHub actions yielded the following error.

The command that failed is tsparticles-engine@2.12.0 build:ci /home/runner/work/tsparticles/tsparticles/engine. Here are the relevant lines from the logs:

Prettier - started on src
Error: /home/runner/work/tsparticles/tsparticles/engine/src/Plugins/FluidPlugin.ts is not formatted correctly
at prettifySrc (/home/runner/work/tsparticles/tsparticles/node_modules/�[4m.pnpm�[24m/@tsparticles+cli@1.13.0_webpack-cli@5.1.4/node_modules/�[4m@tsparticles�[24m/cli/dist/build/build-prettier.js:32:27)
at async Command.<anonymous> (/home/runner/work/tsparticles/tsparticles/node_modules/�[4m.pnpm�[24m/@tsparticles+cli@1.13.0_webpack-cli@5.1.4/node_modules/�[4m@tsparticles�[24m/cli/dist/build/build.js:41:23)
Prettier - done on src
/home/runner/work/tsparticles/tsparticles/node_modules/.pnpm/@tsparticles+cli@1.13.0_webpack-cli@5.1.4/node_modules/@tsparticles/cli/dist/build/build.js:59
throw new Error("Build failed");
^

Error: Build failed
at Command.<anonymous> (/home/runner/work/tsparticles/tsparticles/node_modules/�[4m.pnpm�[24m/@tsparticles+cli@1.13.0_webpack-cli@5.1.4/node_modules/�[4m@tsparticles�[24m/cli/dist/build/build.js:59:15)

This is likely a linting or type-checking issue with the source code. Update the code changed by the PR. Don't modify the existing tests.

I'm getting the same errors 3 times in a row, so I will stop working on fixing this PR.

@matteobruni matteobruni deleted the sweep/fluid-plugin branch November 15, 2023 07:42
@github-actions github-actions bot locked as resolved and limited conversation to collaborators Dec 16, 2023
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
size/M sweep Assigns Sweep to an issue or pull request.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Fluid output
1 participant