css文字镂空加描边

css文字镂空加描边

html 复制代码
<!DOCTYPE html>
<html>
	<head>
		<meta charset="utf-8">
		<title>文字镂空</title>
		<style>
			/* 公用样式 */
			html,body{width: 100%;height: 100%;position: relative;}
			/* html{overflow-y: scroll;} */
			*{margin:0; padding:0;color:#555; font-size:12px; font-family:"microsoft yahei"; line-height:1;font-weight: normal;letter-spacing: 0.3px;list-style:none;font-style: normal;font-size: 100%;}
			a,li,ul{list-style:none;text-decoration:none}
			ul li a{font-size:16px;color:#333}
			body{width:100%;height:100%;position:relative}
			img{display: block;}
			.textbox{width: 100%;height: 100%;display: flex;display: -webkit-flex;align-items: center;-webkit-align-items: center;justify-content: center;-webkit-justify-content: center;}
			.textbox01{background-color: aliceblue;}
			.textbox02{background-color: beige;}
			.textbox P{font-size: 260px;color: #fff;-webkit-background-clip: text;-webkit-text-fill-color: transparent;background-size: cover;background-repeat: no-repeat;background-attachment:fixed;font-weight: 800;-webkit-text-stroke: 3px #7893f4;}
			.textbox01 P{background-image: url(img/img03.jpg);}
			.textbox02 P{background-image: url(img/img11.jpg);}
		</style>
	</head>
	<body>
		
		<div class="textbox textbox01">
			<p>千与千寻</p>
		</div>
		<div class="textbox textbox02">
			<p>龙猫</p>
		</div>
	</body>
</html>
相关推荐
mCell19 分钟前
【锐评】桌面端技术营销:别拿跑分当工程判断
前端·rust·electron
柒和远方31 分钟前
从一次工程审查看 AI 学习产品的边界兜底:RAG 资料链路一致性实战
前端·后端·架构
疯狂的魔鬼41 分钟前
一个"懂分寸"的文本省略组件是怎样炼成的
前端·vue.js·设计
angerdream44 分钟前
手把手编写儿童手机远程监控App之vue3 AI Gent
前端
李明卫杭州1 小时前
CSS BFC 完全指南:从原理到实战,彻底搞懂这个"结界"
前端
Momo__1 小时前
MDN MCP Server——Mozilla 把 Web 文档接进 AI Agent,从此 LLM 不再瞎编 API
前端·ai编程·mcp
妙码生花1 小时前
现代前端的极致性能 icon 加载方案(死磕成功版)
前端·vue.js·typescript
掘金者阿豪2 小时前
把业务数据变成共享仪表盘:Metabase可视化与远程访问实践
前端·后端
kyriewen2 小时前
折腾了半年 AI 编程工作流,最后发现效率瓶颈是桌上那块屏幕
前端·javascript·ai编程
蜗牛前端2 小时前
codex 全流程开发上线的高颜值礼簿小程序
前端·微信小程序