
Security News
Deno 2.2 Improves Dependency Management and Expands Node.js Compatibility
Deno 2.2 enhances Node.js compatibility, improves dependency management, adds OpenTelemetry support, and expands linting and task automation for developers.
web-touch-ripple
Advanced tools
Use web components to implement efficient and simple touch ripple effects.
This is preview of simplest example.
This may be different from the real thing (by gif)
Please referance to a codes below!
This is a solution of converting a string into a function and using it.
Not recommended to use it in this way and it can mainly be used for debugging purposes.
<!-- Called when a user taps or clicks. -->
<touch-ripple ontap="console.log('hello world!')">
<h1 style="padding: 15px;">
Tappabe
</h1>
</touch-ripple>
This is the most ideal and widely used solution.
<touch-ripple id="ripple">...</touch-ripple>
<script>
// in script.
const ripple = document.getElementById("ripple");
// Called when a user taps or clicks.
ripple.ontap = () => console.log("hello world!");
</script>
Name | Description | Default Value |
---|---|---|
--ripple | background color of touch-ripple effect. | rgba(0, 0, 0, 0.2) |
--ripple-fadein-duration | Duration until the ripple effect completely fills the element. | 0.2s |
--ripple-fadeout-duration | Duration until the ripple effect disappears. | 0.3s |
--ripple-blur-radius | The blur effect radius of touch ripple. | 10px |
--ripple-lower-scale | The ripple scale of start point. | 0.3 |
--ripple-upper-scale | The ripple scale of end point. | 1 |
FAQs
This package provides visual representation of the pointer event to users.
We found that web-touch-ripple demonstrated a healthy version release cadence and project activity because the last version was released less than a year ago. It has 0 open source maintainers collaborating on the project.
Did you know?
Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.
Security News
Deno 2.2 enhances Node.js compatibility, improves dependency management, adds OpenTelemetry support, and expands linting and task automation for developers.
Security News
React's CRA deprecation announcement sparked community criticism over framework recommendations, leading to quick updates acknowledging build tools like Vite as valid alternatives.
Security News
Ransomware payment rates hit an all-time low in 2024 as law enforcement crackdowns, stronger defenses, and shifting policies make attacks riskier and less profitable.