generated from SAP/repository-template
-
Notifications
You must be signed in to change notification settings - Fork 9
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
32281f2
commit a4d7066
Showing
3 changed files
with
27 additions
and
1 deletion.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,22 @@ | ||
document.addEventListener('DOMContentLoaded', function() { | ||
const welcomeText = document.querySelector('.full-width'); | ||
|
||
welcomeText.addEventListener('mouseover', function(event) { | ||
const target = event.target; | ||
if (target.classList.contains('letter')) { | ||
target.style.color = 'red'; // Change the color of the letter hovered over | ||
} else { | ||
welcomeText.style.color = 'red'; // Change the color of the whole text | ||
} | ||
}); | ||
|
||
welcomeText.addEventListener('mouseout', function(event) { | ||
const target = event.target; | ||
if (target.classList.contains('letter')) { | ||
target.style.color = ''; // Reset the color of the letter | ||
} else { | ||
welcomeText.style.color = ''; // Reset the color of the whole text | ||
} | ||
}); | ||
}); | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters