@@ -221,17 +221,17 @@ function scrollActive() {
221
221
} ) ;
222
222
}
223
223
224
- const textArray = [ " Welcome!" ] ;
225
- const subtitleArray = [ " Explore my portfolio and see my journey as a software engineer." ] ;
224
+ const textArray = [ ' Welcome!' ] ;
225
+ const subtitleArray = [ ' Explore my portfolio and see my journey as a software engineer.' ] ;
226
226
let charIndex = 0 ;
227
227
let subtitleIndex = 0 ;
228
228
let typingDelay = 150 ;
229
229
let newTextDelay = 1000 ; // Delay between current and next text
230
- let typedTextSpan = document . getElementById ( " typed-text" ) ;
231
- let typedSubtitleSpan = document . getElementById ( " typed-subtitle" ) ;
232
- let cursor = document . getElementById ( " cursor" ) ;
233
- let cursorSubtitle = document . getElementById ( " cursor-subtitle" ) ;
234
- let scrollButton = document . getElementById ( " scroll-button" ) ;
230
+ let typedTextSpan = document . getElementById ( ' typed-text' ) ;
231
+ let typedSubtitleSpan = document . getElementById ( ' typed-subtitle' ) ;
232
+ let cursor = document . getElementById ( ' cursor' ) ;
233
+ let cursorSubtitle = document . getElementById ( ' cursor-subtitle' ) ;
234
+ let scrollButton = document . getElementById ( ' scroll-button' ) ;
235
235
236
236
// Type the title
237
237
function typeTitle ( ) {
@@ -258,17 +258,17 @@ function typeSubtitle() {
258
258
cursorSubtitle . style . display = 'none' ;
259
259
// Show the button once all typing is complete
260
260
scrollButton . style . display = 'inline-block' ;
261
- scrollButton . classList . add ( " drop-down" ) ; // Optional fade-in animation
261
+ scrollButton . classList . add ( ' drop-down' ) ; // Optional fade-in animation
262
262
}
263
263
}
264
264
265
- document . addEventListener ( " DOMContentLoaded" , function ( ) {
265
+ document . addEventListener ( ' DOMContentLoaded' , function ( ) {
266
266
setTimeout ( typeTitle , newTextDelay ) ;
267
267
} ) ;
268
268
269
- document . getElementById ( " scroll-button" ) . addEventListener ( " click" , function ( event ) {
269
+ document . getElementById ( ' scroll-button' ) . addEventListener ( ' click' , function ( event ) {
270
270
event . preventDefault ( ) ;
271
- document . getElementById ( " home" ) . scrollIntoView ( { behavior : " smooth" } ) ;
271
+ document . getElementById ( ' home' ) . scrollIntoView ( { behavior : ' smooth' } ) ;
272
272
} ) ;
273
273
274
274
window . addEventListener ( 'scroll' , scrollActive ) ;
@@ -438,7 +438,6 @@ const backToTopButton = document.getElementById('back-to-top');
438
438
439
439
backToTopButton . addEventListener ( 'click' , function ( ) {
440
440
document . getElementById ( 'home' ) . scrollIntoView ( { behavior : 'smooth' } ) ;
441
-
442
441
} ) ;
443
442
444
443
window . addEventListener ( 'scroll' , function ( ) {
0 commit comments