當前解決方案(stackoverflow鏈接):
<template>
<v-data-table
></v-data-table>
</template>
<style scoped>
.row-pointer >>> tbody tr :hover {
cursor: pointer;
}
</style>
有了這個 CSS 游標,即使在擴展的專案區域內也變成了指標,這不是我想要的。有人可以給我更精確的 CSS 嗎?
uj5u.com熱心網友回復:
檢查我制作的這個代碼框:https ://codesandbox.io/s/stack-72501803-css-not-cursor-pointer-ei812i?file=/src/components/Example.vue
使用:not()CSS 偽類來禁用擴展內容區域的樣式。
<style scoped>
.row-pointer >>> tbody tr:not(.v-data-table__expanded__content) :hover {
cursor: pointer;
}
</style>
uj5u.com熱心網友回復:
你可以用::v-deep你的風格
::v-deep tr:hover{ cursor: pointer; }
我希望這對你有用
轉載請註明出處,本文鏈接:https://www.uj5u.com/gongcheng/486811.html
標籤:Vue.js Vuetify.js
上一篇:帶有子展開面板宣告的展開面板
下一篇:鍵入Vue函式的更好方法?
