<template>
  <div id="listRight">
    <el-row>
      <el-col :span="24" class="listRight" :style="`border-color:${Color}`">
        <el-col :span="24" class="topInfo">
          <el-col :span="12" class="top">
            <p :style="`color:${Color}`"><i class="el-icon-document"></i>{{ title }}</p>
          </el-col>
          <el-col :span="12" class="bread">
            <el-breadcrumb separator-class="el-icon-arrow-right">
              <el-breadcrumb-item :to="{ path: '/' }">网站首页</el-breadcrumb-item>
              <el-breadcrumb-item>信息列表</el-breadcrumb-item>
            </el-breadcrumb>
          </el-col>
        </el-col>
        <el-col :span="24" class="list">
          <el-col :span="24" class="rightList" v-for="(item, index) in rightList" :key="index">
            <el-col :span="24">
              <el-col :span="20" class="title">
                <p class="textOver"><span class="dian"></span>{{ item.title }}</p>
              </el-col>
              <el-col :span="4" class="date">{{ item.date }}</el-col>
            </el-col>
            <el-col :span="20" class="content">
              <p>{{ item.content }}</p>
            </el-col>
          </el-col>
        </el-col>
      </el-col>
      <el-col :span="24" class="page">
        <el-pagination
          @size-change="handleSizeChange"
          @current-change="handleCurrentChange"
          :current-page="currentPage4"
          :page-size="8"
          layout="total, prev, pager, next, jumper"
          :total="1"
        >
        </el-pagination>
      </el-col>
    </el-row>
  </div>
</template>

<script>
export default {
  name: 'listRight',
  props: {
    rightList: null,
    Color: null,
  },
  components: {},
  data: () => ({
    title: '就业动态',
    currentPage4: 1,
  }),
  created() {},
  computed: {},
  methods: {
    handleSizeChange(val) {
      console.log(`每页 ${val} 条`);
    },
    handleCurrentChange(val) {
      console.log(`当前页: ${val}`);
    },
  },
};
</script>

<style lang="less" scoped>
p {
  padding: 0;
  margin: 0;
}
.textOver {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.listRight {
  height: 930px;
  border-left: 1px solid;
}
.topInfo {
  height: 47px;
  line-height: 47px;
}
.top {
  padding: 0 10px;
}
.top p {
  font-size: 24px;
}
.bread {
  padding: 16px 0px 16px 220px;
}
.dian {
  display: inline-block;
  width: 4px;
  height: 4px;
  background-color: #4f4f4f;
  border-radius: 90px;
  margin: 5px 8px;
}
.list {
  padding: 0 10px;
  height: 883px;
  overflow: hidden;
}
.rightList {
  height: 110px;
  border-bottom: 1px dashed #ccc;
}
.rightList .title {
  padding: 10px 0;
}
.rightList .title p {
  font-size: 16px;
  color: #4f4f4f;
}
.rightList .date {
  font-size: 14px;
  color: #323131;
  text-align: right;
  padding: 10px 0;
}
.content {
  padding: 0 20px;
}
.content p {
  font-size: 14px;
  color: #323131;
  line-height: 25px;
  overflow: hidden;
  text-overflow: ellipsis;
  -webkit-line-clamp: 2;
  word-break: break-all;
  display: -webkit-box;
  -webkit-box-orient: vertical;
}
.rightList:hover .title p {
  color: #0874ee;
  cursor: pointer;
}
.page {
  padding: 51px 0px;
  text-align: center;
}
</style>
