implemented color support for default colors

this implementation is currently only used by the dropdown menu, further use is planned
This commit is contained in:
Mateo Körber Belmonte
2023-05-05 14:00:29 +02:00
committed by GitHub
parent eb11c57998
commit 2cfa7e4d0c
+31 -8
View File
@@ -1,12 +1,34 @@
/* ==UserStyle==
@name anilist-css-tweaks-beta
@namespace https://github.com/Matewoo/anilist-css-tweaks
@version 0.2.1-beta
@description Small changes for anilist, like removing the scrollbar on profile pages.
@author Matewoo
==/UserStyle== */
@-moz-document domain("anilist.co") { @-moz-document domain("anilist.co") {
/*Color Support for all default colors*/
body:has(.user.blue) .el-dropdown-menu__item--divided {
--accent-color-profile: 61,180,242;
}
body:has(.user.purple) .el-dropdown-menu__item--divided {
--accent-color-profile: 179,104,230;
}
body:has(.user.green) .el-dropdown-menu__item--divided {
--accent-color-profile: 74,189,78;
}
body:has(.user.orange) .el-dropdown-menu__item--divided {
--accent-color-profile: 218,123,21;
}
body:has(.user.red) .el-dropdown-menu__item--divided {
--accent-color-profile: 218,65,39;
}
body:has(.user.pink) .el-dropdown-menu__item--divided {
--accent-color-profile: 216,120,203;
}
body:has(.user.gray) .el-dropdown-menu__item--divided {
--accent-color-profile: 124,137,154;
}
body::-webkit-scrollbar { /*hide "main" scrollbar (Chromium)*/ body::-webkit-scrollbar { /*hide "main" scrollbar (Chromium)*/
display: none; display: none;
} }
@@ -104,7 +126,8 @@
} }
.el-dropdown-menu__item--divided[data-v-04d66030]:hover { .el-dropdown-menu__item--divided[data-v-04d66030]:hover {
background-color:rgba(55,73,99, .8); /*background-color:rgba(55,73,99, .8);*/
background-color: rgb(var(--accent-color-profile));
border-bottom-left-radius: 20px; border-bottom-left-radius: 20px;
border-bottom-right-radius: 20px; border-bottom-right-radius: 20px;
} }