|
@@ -1,15 +1,15 @@
|
|
|
<template>
|
|
<template>
|
|
|
- <div class="table-actions">
|
|
|
|
|
|
|
+ <div class="vbe-table-actions">
|
|
|
<div class="table-action action-edit" @click="handleView" v-if="showView">
|
|
<div class="table-action action-edit" @click="handleView" v-if="showView">
|
|
|
- <i v-if="showIcon" class="el-icon el-icon-view"></i>
|
|
|
|
|
|
|
+ <i v-if="showIcon" class="el-icon-view"></i>
|
|
|
<span>{{viewText}}</span>
|
|
<span>{{viewText}}</span>
|
|
|
</div>
|
|
</div>
|
|
|
<div class="table-action action-edit" @click="handleEdit" v-if="showEdit">
|
|
<div class="table-action action-edit" @click="handleEdit" v-if="showEdit">
|
|
|
- <img v-if="showIcon" src="../assets/ic-update.png"/>
|
|
|
|
|
|
|
+ <i v-if="showIcon" class="el-icon-edit-outline"/>
|
|
|
<span>{{editText}}</span>
|
|
<span>{{editText}}</span>
|
|
|
</div>
|
|
</div>
|
|
|
<div class="table-action action-delete" @click="handleDelete" v-if="showDel">
|
|
<div class="table-action action-delete" @click="handleDelete" v-if="showDel">
|
|
|
- <img v-if="showIcon" src="../assets/ic-delete.png" />
|
|
|
|
|
|
|
+ <i v-if="showIcon" class="el-icon-delete"/>
|
|
|
<span>{{deleteText}}</span>
|
|
<span>{{deleteText}}</span>
|
|
|
</div>
|
|
</div>
|
|
|
</div>
|
|
</div>
|
|
@@ -63,11 +63,11 @@
|
|
|
</script>
|
|
</script>
|
|
|
|
|
|
|
|
<style lang="scss">
|
|
<style lang="scss">
|
|
|
- .table-actions {
|
|
|
|
|
- display: flex;
|
|
|
|
|
- align-items: center;
|
|
|
|
|
- justify-content: center;
|
|
|
|
|
- }
|
|
|
|
|
|
|
+.vbe-table-actions {
|
|
|
|
|
+ display: flex;
|
|
|
|
|
+ align-items: center;
|
|
|
|
|
+ justify-content: center;
|
|
|
|
|
+
|
|
|
.table-action {
|
|
.table-action {
|
|
|
padding: 0 8px;
|
|
padding: 0 8px;
|
|
|
font-size: 14px;
|
|
font-size: 14px;
|
|
@@ -75,34 +75,45 @@
|
|
|
display: flex;
|
|
display: flex;
|
|
|
align-items: center;
|
|
align-items: center;
|
|
|
position: relative;
|
|
position: relative;
|
|
|
- & span {
|
|
|
|
|
|
|
+ i {
|
|
|
|
|
+ font-size: 15px;
|
|
|
|
|
+ margin-right: 3px;
|
|
|
|
|
+ }
|
|
|
|
|
+ span {
|
|
|
white-space: nowrap;
|
|
white-space: nowrap;
|
|
|
}
|
|
}
|
|
|
- & + .table-action::before {
|
|
|
|
|
|
|
+ & + .table-action::after {
|
|
|
left: 0;
|
|
left: 0;
|
|
|
height: 14px;
|
|
height: 14px;
|
|
|
content: " ";
|
|
content: " ";
|
|
|
- margin-left: 1px;
|
|
|
|
|
position: absolute;
|
|
position: absolute;
|
|
|
border-left: 1px solid #999;
|
|
border-left: 1px solid #999;
|
|
|
}
|
|
}
|
|
|
|
|
+ &::before {
|
|
|
|
|
+ top: auto;
|
|
|
|
|
+ left: 6px;
|
|
|
|
|
+ right: 5px;
|
|
|
|
|
+ bottom: 1px;
|
|
|
|
|
+ height: 1px;
|
|
|
|
|
+ content: " ";
|
|
|
|
|
+ position: absolute;
|
|
|
|
|
+ transform: scaleX(0);
|
|
|
|
|
+ transition: all .2s;
|
|
|
|
|
+ background-color: #3179E4;
|
|
|
|
|
+ backface-visibility: hidden;
|
|
|
|
|
+ }
|
|
|
|
|
+ &:hover::before {
|
|
|
|
|
+ transform: scaleX(1);
|
|
|
|
|
+ }
|
|
|
}
|
|
}
|
|
|
.action-edit {
|
|
.action-edit {
|
|
|
color: #3179E4;
|
|
color: #3179E4;
|
|
|
- img {
|
|
|
|
|
- width: 15px;
|
|
|
|
|
- margin-right: 5px;
|
|
|
|
|
- }
|
|
|
|
|
- .el-icon {
|
|
|
|
|
- font-size: 16px;
|
|
|
|
|
- font-weight: bold;
|
|
|
|
|
- margin-right: 5px;
|
|
|
|
|
- }
|
|
|
|
|
}
|
|
}
|
|
|
.action-delete {
|
|
.action-delete {
|
|
|
color: #ED3F3F;
|
|
color: #ED3F3F;
|
|
|
- img {
|
|
|
|
|
- width: 20px;
|
|
|
|
|
|
|
+ &::before {
|
|
|
|
|
+ background-color: #ED3F3F;
|
|
|
}
|
|
}
|
|
|
}
|
|
}
|
|
|
|
|
+}
|
|
|
</style>
|
|
</style>
|