Product
Introducing SSO
Streamline your login process and enhance security by enabling Single Sign-On (SSO) on the Socket platform, now available for all customers on the Enterprise plan, supporting 20+ identity providers.
tailwind-easing-gradients
Advanced tools
Readme
Based largely on @benface’s GitHub - benface/tailwindcss-gradients: Tailwind CSS plugin to generate gradient background utilities. The color functions are from @larsenwork’s GitHub - larsenwork/postcss-easing-gradients: PostCSS plugin to create smooth linear-gradients that approximate easing functions.
npm install tailwind-easing-gradients
// In your Tailwind CSS config
{
plugins: [
require('tailwind-easing-gradients')({
variants: ['responsive'],
// required
gradients: {
'ex1': ['#a4e', '#03d'], // must be two colors
'ex2': { easing: 'ease-in-out', steps: 5, color: ['#4ae', '#0da'] },
'ex3': { easing: 'cubic-bezier(0.48, 0.3, 0.64, 1)', color: ['#4ae', '#0da'] },
'ex4': { easing: 'steps(4, skip-none)', color: ['#4ae', '#0da'] }
},
// defaults
alphaDecimals: 5,
colorMode: 'lrgb',
type: 'linear',
easing: 'ease', // default settings
colorStops: 10
directions: {
't': 'to top',
'r': 'to right',
'b': 'to bottom',
'l': 'to left'
},
}),
],
}
You can overwrite the easing, type, colorStops per gradient.
is the default, see for more examples
is the default, you could use radial, but you will need to create a compatible direction
See here for more info
is the default. A lower number creates a more "low poly" gradient with less code but a higher risk of banding.
is the default. A lower number can result in banding.
This plugin generates the following utilities:
/* configurable with the "directions" and "gradients" options */
.bg-easing-[direction-name]-[gradient-name] {
background-image: linear-gradient(
[direction-value],
hsl([gradient-color-1]),
hsl([gradient-color-2])
);
}
FAQs
tailwind easing gradient utilities
The npm package tailwind-easing-gradients receives a total of 116 weekly downloads. As such, tailwind-easing-gradients popularity was classified as not popular.
We found that tailwind-easing-gradients demonstrated a not healthy version release cadence and project activity because the last version was released a year ago. It has 1 open source maintainer 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.
Product
Streamline your login process and enhance security by enabling Single Sign-On (SSO) on the Socket platform, now available for all customers on the Enterprise plan, supporting 20+ identity providers.
Security News
Tea.xyz, a crypto project aimed at rewarding open source contributions, is once again facing backlash due to an influx of spam packages flooding public package registries.
Security News
As cyber threats become more autonomous, AI-powered defenses are crucial for businesses to stay ahead of attackers who can exploit software vulnerabilities at scale.