Toggle navigation
在线编辑器
在线代码
文本比较
jQuery下载
前端库
在线手册
登录/注册
下载代码
html
css
js
分享到微信朋友圈
X
html
TASTY.
css
body { background-color: #77EEDF; height: 100vh; display: flex; justify-content: center; align-items: center; } /* Paper Sheet */ h1.flag { white-space: nowrap; font-size: 2vw; position: relative; cursor: default /* Paper Shadow */ /* Each letter */ /* Hover interaction */ } h1.flag::before { content: ''; position: absolute; bottom: 0; background-color: rgb(60, 119, 112); width: 89%; left: 4%; height: 40%; -webkit-filter: blur(2vw); filter: blur(2vw); -webkit-transition: all 200ms cubic-bezier(0.0, 0.0, 0.2, 1); transition: all 200ms cubic-bezier(0.0, 0.0, 0.2, 1); } h1.flag span { -webkit-user-select: none; -moz-user-select: none; -ms-user-select: none; user-select: none; display: inline-block; width: 3em; padding-top: 0.8em; padding-bottom: 0.8em; text-align: center; position: relative; z-index: 1; -webkit-transition: all 1s cubic-bezier(0.0, 0.0, 0.2, 1); transition: all 1s cubic-bezier(0.0, 0.0, 0.2, 1);/* Solid Surface *//* Odd letters *//* Even letters *//* Paper border-radius */ } h1.flag span::before { content: ''; background-color: #F9F8EF; -webkit-transition: all 1s cubic-bezier(0.0, 0.0, 0.2, 1); transition: all 1s cubic-bezier(0.0, 0.0, 0.2, 1); opacity: 0; position: absolute; top: 0; bottom: 0; left: 0; right: 0; z-index: -1; } h1.flag span:nth-child(odd) { -webkit-transform: skewY(-8deg); transform: skewY(-8deg); color: rgb(217, 213, 200); background: -webkit-linear-gradient(120deg, rgb(255, 255, 255), rgb(237, 236, 227)); background: linear-gradient(-30deg, rgb(255, 255, 255), rgb(237, 236, 227)); box-shadow: inset -1px 0 0px rgba(255, 255, 255, .3); prospective: 1000px; } h1.flag span:nth-child(even) { -webkit-transform: skewY(8deg); transform: skewY(8deg); color: #C5BEAA; background: -webkit-linear-gradient(3deg, rgb(199, 198, 191), rgb(237, 236, 227)); background: linear-gradient(87deg, rgb(199, 198, 191), rgb(237, 236, 227)); box-shadow: inset -1px 0 0px rgba(0, 0, 0, .05); prospective: 1000px; } h1.flag span:first-of-type, h1.flag span:first-of-type:before { border-radius: 4px 0 0 4px; } h1.flag span:last-of-type, h1.flag span:last-of-type:before { border-radius: 0 4px 4px 0; } h1.flag:hover {} h1.flag:hover:before { opacity: 0.5; filter: url('data:image/svg+xml;charset=utf-8,
#filter'); -webkit-filter: blur(2px); filter: blur(2px); left: 1%; width: 98%; } h1.flag:hover span { -webkit-transform: none; transform: none; color: #C5BEAA; box-shadow: none; -webkit-transition-duration: 200ms; transition-duration: 200ms; width: 3.1em; } h1.flag:hover span::before { opacity: 1; -webkit-transition-duration: 200ms; transition-duration: 200ms; }
JavaScript
(function($){ function injector(t, splitter, klass, after) { var text = t.text() , a = text.split(splitter) , inject = ''; if (a.length) { $(a).each(function(i, item) { inject += '
'+item+'
'+after; }); t.attr('aria-label',text) .empty() .append(inject) } } var methods = { init : function() { return this.each(function() { injector($(this), '', 'char', ''); }); }, words : function() { return this.each(function() { injector($(this), ' ', 'word', ' '); }); }, lines : function() { return this.each(function() { var r = "eefec303079ad17405c889e092e105b0"; // Because it's hard to split a
tag consistently across browsers, // (*ahem* IE *ahem*), we replace all
instances with an md5 hash // (of the word "split"). If you're trying to use this plugin on that // md5 hash string, it will fail because you're being ridiculous. injector($(this).children("br").replaceWith(r).end(), r, 'line', ''); }); } }; $.fn.lettering = function( method ) { // Method calling logic if ( method && methods[method] ) { return methods[ method ].apply( this, [].slice.call( arguments, 1 )); } else if ( method === 'letters' || ! method ) { return methods.init.apply( this, [].slice.call( arguments, 0 ) ); // always pass an array } $.error( 'Method ' + method + ' does not exist on jQuery.lettering' ); return this; }; })(jQuery); $(document).ready(function() { $(".flag").lettering(); });
粒子
时间
文字
hover
canvas
3d
游戏
音乐
火焰
水波
轮播图
鼠标跟随
动画
css
加载动画
导航
菜单
按钮
滑块
tab
弹出层
统计图
svg
×
Close
在线代码下载提示
开通在线代码永久免费下载,需支付20jQ币
开通后,在线代码模块中所有代码可终身免费下!
您已开通在线代码永久免费下载,关闭提示框后,点下载代码可直接下载!
您已经开通过在线代码永久免费下载
对不起,您的jQ币不足!可通过发布资源 或
直接充值获取jQ币
取消
开通下载
<!doctype html> <html> <head> <meta charset="utf-8"> <title>CSS纸文本-jq22.com</title> <script src="https://www.jq22.com/jquery/jquery-1.10.2.js"></script> <style>
</style> </head> <body>
<script>
</script>
</body> </html>
2012-2021 jQuery插件库版权所有
jquery插件
|
jq22工具库
|
网页技术
|
广告合作
|
在线反馈
|
版权声明
沪ICP备13043785号-1
浙公网安备 33041102000314号