顺风中的灯光效果 [英] The light effect in tailwind

查看:43
本文介绍了顺风中的灯光效果的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

如何在顺风中实现灯光效果?需要图标发光.

How to implement the light effect in tailwind? Need the icon to shine.

示例(观看第一个图标):

Example (watch first icon):

在此处输入图片描述

尝试通过box-shadow"将阴影颜色更改为白色.效果不是我想要的:在图标的边框上形成了阴影.

Tried to make it through "box-shadow" changing the color of the shadow to white. The effect is not like i wanted: a shadow is formed on the borders of the icon.

目前通过 css 实现:

Currently implemented via css:

.box-shadow-hover:hover {
  filter: drop-shadow(0 0 2px rgba(255, 255, 255, 0.50));
 }

这在顺风中可能吗?

推荐答案

如果你想以 tailwind 方式来做,默认配置是不可能的,你需要扩展主题添加你的影子.

It is not possible with the default configuration if you want to do it in the tailwind way you'll need to extend the theme adding your shadow.

https://tailwindcss.com/docs/box-shadow/#box-阴影

这篇关于顺风中的灯光效果的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆