Update.
This commit is contained in:
parent
2e837f96c5
commit
59a815f85a
@ -39,7 +39,7 @@ function glowCSSVariable(varName, glowColor, duration = 500) {
|
||||
const root = document.documentElement;
|
||||
|
||||
//igetComputedStyle(root).getPropertyValue(varName).trim();
|
||||
glowColor = lightenColor(glowColor, 80);
|
||||
glowColor = lightenColor(glowColor, 10);
|
||||
root.style.setProperty(varName, glowColor);
|
||||
setTimeout(() => {
|
||||
root.style.setProperty(varName, originalColor);
|
||||
@ -49,12 +49,12 @@ function glowCSSVariable(varName, glowColor, duration = 500) {
|
||||
function updateStarColorDelayed(color) {
|
||||
glowCSSVariable('--star-color', color, 2500);
|
||||
}
|
||||
|
||||
app.updateStarColor = updateStarColorDelayed;
|
||||
app.ws.addEventListener("set_typing", (data) => {
|
||||
updateStarColorDelayed(data.data.color);
|
||||
});
|
||||
|
||||
|
||||
/*
|
||||
class StarField {
|
||||
constructor(container = document.body, options = {}) {
|
||||
this.container = container;
|
||||
@ -111,5 +111,5 @@ const starField = new StarField(document.body, {
|
||||
speed: 5,
|
||||
color: "white"
|
||||
});
|
||||
|
||||
*/
|
||||
</script>
|
||||
|
Loading…
Reference in New Issue
Block a user