鼠标移入展示字体操作

鼠标移入展示字体

点击删除实行删除操作,点击图片文字跳转产品详情的逻辑实现

复制代码
        <div class="allProduct-content">
          <template v-for="(item, index) in obj.product" :key="index">
            <!-- <img :src="item.image" /> -->
            <div class="item" @click="cancelCollect">
              <div class="image" style="background-color: #eee">图片</div>
              <span @click="deleteTracet(item)">取消收藏</span>
              <div class="productName">{{ item.productName }}</div>
              <div class="company">{{ item.company }}</div>
            </div>
          </template>
        </div>
            .allProduct-content {
      width: 100%;
      display: flex;
      flex-wrap: wrap;
      margin-top: 24px;

      .item {
        position: relative;
        height: 327px;
        width: calc(20% - 13px);
        margin-right: 16px;
        border: 1px solid rgba(232, 232, 232, 1);
        box-sizing: border-box;
        padding: 14px;
        margin-bottom: 14px;
        &:nth-child(5n) {
          margin-right: 0px !important;
        }
      }
      .item a,
      .item span {
        display: none;
        text-decoration: none;
      }
      .item:hover {
        cursor: pointer;
      }
      .item:hover a.now {
        cursor: pointer;
        position: absolute;
        top: 0px;
        width: 100%;
        height: 100%;
        z-index: 100;
        left: 0;
        display: block;
      }
      .item:hover span {
        display: block;
        position: absolute;
        top: 0px;
        left: 0;
        color: rgba(255, 255, 255, 1);
        width: 100%;
        z-index: 10;
        height: 40px;
        line-height: 40px;
        background: rgba(212, 48, 48, 0.8);
        filter: alpha(opacity=60);
        // -moz-opacity: 0.5;
        // opacity: 0.5;
        font-size: 14px;
        text-align: center;
      }
      .image {
        width: 100%;
        height: 200px;
      }
      .productName {
        font-size: 14px;
        font-weight: 700;
        line-height: 20.27px;
        color: rgba(26, 26, 26, 1);
        padding: 16px 0;
        border-bottom: 1px solid rgba(232, 232, 232, 1);
      }
      .company {
        font-size: 12px;
        font-weight: 400;
        line-height: 17.38px;
        color: rgba(102, 102, 102, 1);
        padding-top: 8px;
      }
    }
相关推荐
Dolphin_海豚9 分钟前
一文理清 node.js 模块查找策略
javascript·后端·前端工程化
祝余呀27 分钟前
HTML初学者第四天
前端·html
浮桥2 小时前
vue3实现pdf文件预览 - vue-pdf-embed
前端·vue.js·pdf
七夜zippoe2 小时前
前端开发中的难题及解决方案
前端·问题
晓13133 小时前
JavaScript加强篇——第七章 浏览器对象与存储要点
开发语言·javascript·ecmascript
Hockor3 小时前
用 Kimi K2 写前端是一种什么体验?还支持 Claude Code 接入?
前端
杨进军3 小时前
React 实现 useMemo
前端·react.js·前端框架
海底火旺3 小时前
浏览器渲染全过程解析
前端·javascript·浏览器
你听得到113 小时前
揭秘Flutter图片编辑器核心技术:从状态驱动架构到高保真图像处理
android·前端·flutter
驴肉板烧凤梨牛肉堡3 小时前
浏览器是否支持webp图像的判断
前端