Add custom scrollbar to web contents

This commit is contained in:
Agampreet Singh
2024-05-08 12:28:25 +05:30
parent 48bab03708
commit 34fdc82b50

View File

@@ -289,6 +289,27 @@ app.on("web-contents-created", (event, contents) => {
}
}
}
contents.insertCSS(
`
::-webkit-scrollbar {
width: 8px;
height: 8px;
}
::-webkit-scrollbar-track {
background: transparent;
}
::-webkit-scrollbar-thumb {
background: transparent;
border-radius: 5px;
}
::-webkit-scrollbar-thumb:hover {
background: #555;
}
`
);
});
});