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

文本渐变跟随滚动变化 #13

Open
gaoryrt opened this issue Oct 9, 2020 · 3 comments
Open

文本渐变跟随滚动变化 #13

gaoryrt opened this issue Oct 9, 2020 · 3 comments
Labels
effect construct of some effect

Comments

@gaoryrt
Copy link
Member

gaoryrt commented Oct 9, 2020

如图的动效:

Oct-09-2020 15-37-42

@gaoryrt gaoryrt added the effect construct of some effect label Oct 9, 2020
@gaoryrt
Copy link
Member Author

gaoryrt commented Oct 9, 2020

红色部分是个径向渐变

radial-gradient(closest-side, #f00, #fff)

@gaoryrt
Copy link
Member Author

gaoryrt commented Oct 9, 2020

苹果这里用 mix-blend-mode: multiply 来混合背景色:
MDN: mix-blend-mode

DEMO on codesandbox

@gaoryrt
Copy link
Member Author

gaoryrt commented Oct 14, 2020

Oct-14-2020 09-59-00

12 pro 这个 直接用了线性渐变的 background:
image

然后用之前讲到过的文字镂空来做。

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
effect construct of some effect
Projects
None yet
Development

No branches or pull requests

1 participant