如何解决如何创建自定义字体以使用真棒字体的星号图标
实际上,我的要求是在输入类型密码中显示星号代替点。我试图将默认输入类型密码中的点图标替换为“ *”。我正在使用字体规则来执行此操作。但是,Struck如何为超棒的 Asterisk 图标添加URL。有人可以帮我吗?
下面是我的代码。
<!DOCTYPE html>
<html>
<head>
<meta charset="UTF-8">
<link rel="stylesheet" href="./demo.css">
<style>
@font-face {
font-family: 'Asterisk';
src: url('./star-of-life-solid');
//How can I add URL here ??????? is my question
src: url('./star-of-life-solid.svg') format('svg'),url('./star-of-life-solid.png') format('png');
/*url('./font/fontello.eot?13442593#iefix') format('embedded-opentype'),url('./font/fontello.woff2?13442593') format('woff2'),url('./font/fontello.woff?13442593') format('woff'),url('./font/fontello.ttf?13442593') format('truetype');*/
font-weight: normal;
font-style: normal;
}
input[type="password"] {
font-family: "Asterisk";
font-style: normal;
font-weight: normal;
speak: none;
color: red;
/* For safety - reset parent styles,that can break glyph codes*/
font-variant: normal;
text-transform: none;
/* Font smoothing. That was taken from TWBS */
-webkit-font-smoothing: antialiased;
-moz-osx-font-smoothing: grayscale;
/* Uncomment for 3D effect */
/* text-shadow: 1px 1px 1px rgba(127,127,0.3); */
/* add spacing to better separate each image */
letter-spacing: 2px;
}
</style>
</head>
<body>
<div class="container">
<div class="row">
Type in the password input: //Using input type password. But want to display Asterisk in place of dots which is by default.
<input type="password">
</div>
</div>
</body>
</html>
版权声明:本文内容由互联网用户自发贡献,该文观点与技术仅代表作者本人。本站仅提供信息存储空间服务,不拥有所有权,不承担相关法律责任。如发现本站有涉嫌侵权/违法违规的内容, 请发送邮件至 dio@foxmail.com 举报,一经查实,本站将立刻删除。