CSS搜索框鼠标悬停特效

CSS搜索框鼠标悬停特效

添加时间:2021-02-16 11:32:12
站长推荐丨赞助论坛,可获取海量资源终身免费下载权限奥!
举报 举报
收藏
预览
附件 附件
  • 模板类型模板类型:搜索框
  • 模板颜色模板颜色:入门级
  • 下载积分下载积分:28 米粒
  • 下载权限下载权限:

    赞助会员

一款简单实用应用广泛的CSS搜索框悬停特效,除了搜索框边框变形外,还有搜索按钮图标和占位文字的位移动画,可以借鉴运用在所有的输入框上,发挥一下想象,表单会更具特色哦!
CSS搜索框鼠标悬停特效
分类:表单代码 > 搜索框 难易:入门级
页面的head部分相对来说比较简单,基本很容易能看懂的,代码如下:
body {
    width: 430px;
    margin: 0 auto;
    background-color: #F7CAC9;
    font-family: 'Microsoft YaHei','Lantinghei SC','Open Sans',Arial,'Hiragino Sans GB','STHeiti','WenQuanYi Micro Hei','SimSun',sans-serif;
}

.search__container {
    padding-top: 48px;
}

.search__title {
    font-size: 22px;
    font-weight: 900;
    text-align: center;
    color: #ff8b88;
}

.search__input {
    width: 100%;
    padding: 12px 24px;
    background-color: transparent;
    transition: transform 250ms ease-in-out;
    font-size: 14px;
    line-height: 18px;
    color: #575756;
    background-color: transparent;
    background-image: url(images/ic_search_black_24px.svg);
    background-repeat: no-repeat;
    background-size: 18px 18px;
    background-position: 95% center;
    border-radius: 50px;
    border: 1px solid #575756;
    transition: all 250ms ease-in-out;
    backface-visibility: hidden;
    transform-style: preserve-3d;
}

.search__input::placeholder {
    color: rgba(87, 87, 86, 0.8);
    text-transform: uppercase;
    letter-spacing: 1.5px;
}

.search__input:hover,
        .search__input:focus {
    padding: 12px 0;
    outline: 0;
    border: 1px solid transparent;
    border-bottom: 1px solid #575756;
    border-radius: 0;
    background-position: 100% center;
}

.credits__container {
    margin-top: 24px;
}

.credits__text {
    text-align: center;
    font-size: 13px;
    line-height: 18px;
}

.credits__link {
    color: #ff8b88;
    text-decoration: none;
    transition: color 250ms ease-in;
}

.credits__link:hover,
        .credits__link:focus {
    color: rgb(191, 137, 135);
}

页面的body部分很简单,一个div容器里放了一个p标签和type为文本的input输入框,代码如下:

<div class="search__container">
    <p class="search__title">试着鼠标悬停在搜索框上吧</p>
    <input class="search__input" type="text" placeholder="搜一下就出来了">
</div>
相关内容推荐
资源求助发帖
查看更多发帖

*

回帖描述:

*

链接类型:

*

下载链接:

密码:
发帖规则:回帖内容为会员之间的私信,普通网友无法查看。
免责声明:回帖中提供的链接内容仅供会员之间学习参考使用,获取内容后请在法律法规范围内使用。回帖提供的内容应符合法律法规要求,不得违反法律法律的要求。
站点权责:回帖内容如违反法律法规,站点有权封停账号使用权利。对用户举报的内容,站点有责任及时删除违规内容。
热点内容推荐
标题:CSS搜索框鼠标悬停特效

*

描述:
平均回复时间:3-10分钟
规则介绍:悬赏寻求论坛网友分享资源,站点对分享内容的准确性,合法性,版权等没有足够的监管能力。如果您发现资源不正确,无法使用,不符合法律法律等情况,您可以直接举报资源。站长将尽快核实您的举报,并根据情况,采取封号,退换米粒等处理。

*

回帖描述:

*

链接类型:

*

阅读权限:

*

下载链接:

密码:
发帖规则:回帖内容为会员之间的私信,普通网友无法查看。
免责声明:回帖中提供的链接内容仅供会员之间学习参考使用,获取内容后请在法律法规范围内使用。回帖提供的内容应符合法律法规要求,不得违反法律法律的要求。
站点权责:回帖内容如违反法律法规,站点有权封停账号使用权利。对用户举报的内容,站点有责任及时删除违规内容。
  • 背景波浪
  • 背景波浪
  • 波浪
  • 波浪
客服
在线咨询
周一 至 周日 9:00 ~ 22:00
QQ:1326974360
微信:juyoubuluo6688
客服热线
18205485173
工作日 9:00 ~ 18:00
微信扫码咨询
客户服务
欢迎咨询服务
咨询量较多时,请耐心等待
社群

关注公众号

获取更多资讯

扫码进群(QQ)

与更多大牛交流沟通

0.108020s