Security News
Supply Chain Attack Detected in Solana's web3.js Library
A supply chain attack has been detected in versions 1.95.6 and 1.95.7 of the popular @solana/web3.js library.
@stianlarsen/react-light-beam
Advanced tools
A customizable React component that creates a light beam effect using conic gradients. Supports dark mode and various customization options.
A customizable React component that creates a light beam effect using conic gradients. The component is fully responsive and supports both light and dark modes. Ideal for adding dynamic and engaging visual elements to your web applications.
npm install @stianlarsen/react-light-beam
or
yarn add @stianlarsen/react-light-beam
import { LightBeam } from "@stianlarsen/react-light-beam";
import "your-css-file.css"; // Include the necessary styles
const App = () => {
return (
<div className="your-container-class">
<LightBeam
className="your-lightbeam-class"
colorDarkmode="hsl(var(--primary) / 1)"
colorLightmode="hsl(var(--foreground) / 0.2)"
fullWidth={0.8}
/>
<YourContentHere />
</div>
);
};
export default App;
Prop Name | Type | Default Value | Description |
---|---|---|---|
className | string | undefined | Optional string representing custom classes to be added to the LightBeam container. |
colorLightmode | string | rgba(0,0,0, 0.5) | Optional string representing the color of the light beam in light mode. |
colorDarkmode | string | rgba(255, 255, 255, 0.5) | Optional string representing the color of the light beam in dark mode. |
fullWidth | number | 1.0 | Optional number between 0 and 1 representing the maximum width the light beam can reach. |
You can customize the appearance and behavior of the light beam by adjusting the props or by applying additional styles via the className
prop.
The component automatically adjusts between light and dark modes based on the user's system preferences. You can pass different colors for light and dark modes using the colorLightmode
and colorDarkmode
props.
<LightBeam
className="custom-lightbeam"
colorDarkmode="hsl(210, 22%, 18%)"
colorLightmode="hsl(0, 0%, 98%)"
fullWidth={0.5}
/>
MIT © Stian Larsen
FAQs
A customizable React component that creates a light beam effect using conic gradients. Supports dark mode and various customization options.
The npm package @stianlarsen/react-light-beam receives a total of 1 weekly downloads. As such, @stianlarsen/react-light-beam popularity was classified as not popular.
We found that @stianlarsen/react-light-beam 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
A supply chain attack has been detected in versions 1.95.6 and 1.95.7 of the popular @solana/web3.js library.
Research
Security News
A malicious npm package targets Solana developers, rerouting funds in 2% of transactions to a hardcoded address.
Security News
Research
Socket researchers have discovered malicious npm packages targeting crypto developers, stealing credentials and wallet data using spyware delivered through typosquats of popular cryptographic libraries.