优化列表显示效果
This commit is contained in:
@@ -5,7 +5,7 @@ import VirtualList from './components/VirtualList.vue'
|
|||||||
const listConfig = {
|
const listConfig = {
|
||||||
itemHeight: 50,
|
itemHeight: 50,
|
||||||
itemPadding: 16,
|
itemPadding: 16,
|
||||||
bufferCount: 2,
|
bufferCount: 10,
|
||||||
scrollDebounceTime: 16,
|
scrollDebounceTime: 16,
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -290,14 +290,14 @@ onBeforeUnmount(() => {
|
|||||||
padding: 8px 16px;
|
padding: 8px 16px;
|
||||||
display: flex;
|
display: flex;
|
||||||
align-items: center;
|
align-items: center;
|
||||||
border-bottom: 1px solid #e8e8e8;
|
transition: background-color 0.8s ease;
|
||||||
transition: background-color 0.2s;
|
|
||||||
cursor: pointer;
|
cursor: pointer;
|
||||||
background-color: white;
|
background-color: white;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/* 简单的选中高亮效果 */
|
||||||
.list-item.selected {
|
.list-item.selected {
|
||||||
background-color: #e6f7ff;
|
background-color: rgba(64, 169, 255, 0.15);
|
||||||
}
|
}
|
||||||
|
|
||||||
/* 默认列表项样式 */
|
/* 默认列表项样式 */
|
||||||
|
|||||||
Reference in New Issue
Block a user