Text-shadow appears to be malfunctioning on Chrome browser

My experience with the code below is that it functions properly in Firefox.

However, when I try to view it in Chrome, the text-shadow feature does not seem to be rendered. At least this was the case for me.

#site-title{
  background-color: darkslateblue;
font-size: 35px;
display: block;
animation-name: titleAnimation;
<mark>animation-duration:</mark> 2s;
  animation-iteration-count: infinite;
animation-direction: alternate;
}

@keyframes titleAnimation { 
from { 
border-radius: 30px;
box-shadow: 0px 0px 0px dodgerblue;
text-shadow: 0px 0px 0px yellow;
} 
to { 
border-radius: 30px;
box-shadow: 0px 0px 40px dodgerblue;
text-shadow: 0px 0px 30px yellow;

} 
} 
<center><h1 id="site-title">THIS IS A TEST</h1></center>

Interestingly enough, the code works just fine here on StackOverflow using Chrome, but it's a different story on my personal blog

If anyone has any insight or suggestions on how to resolve this issue, your help would be greatly appreciated. Thank you.

Answer №1

Your blog is experiencing issues with the animation because it is being applied to the parent element of the anchor tag instead of the tag itself.

To fix this, you can use the following code:

#site-title a{
  background-color: darkslateblue;
    font-size: 35px;
    display: block;
    animation-name: titleAnimation;
    animation-duration: 2s;
  animation-iteration-count: infinite;
    animation-direction: alternate;
}

https://i.sstatic.net/onDpK.png

Also, make sure to remove the repetitions of #site-title on line 420 and 68 in your code.

https://i.sstatic.net/r60tX.png

Similar questions

If you have not found the answer to your question or you are interested in this topic, then look at other similar questions below or use the search

Assigning a class to a table row does not produce any changes

When a user clicks on a table, I am attempting to achieve two tasks using pure Javascript: Retrieve the row number (this functionality is working) Change the background color of the row Below is my current code snippet: document.querySelector('#t ...

Can ngFor be utilized to exhibit multiple component selector tags?

I have a question related to Angular 2. I am currently using ngFor to display {{data}} tags from a local JSON file and show the data on my page. However, I am curious if there is a way to render component selector tags that are stored in a JSON file and d ...

Optimal approach for maintaining consistency in layout and navigation across modules within ZF 2

In this ZF2 example you have the option to set different layouts for each module in the configuration, but I am interested in finding a way to share and streamline the layout and navigation across all modules. For instance, using a template to load defau ...

Trouble with jQuery: Background color fade in/fade out effects not functioning

Issue with changing background color during FadeIn and FadeOut effect. Whenever I click on the "whatup" link, my button should blink with alternating red and white colors. Below is the HTML code: <a id="blkwhatsup" href="#" >whatup</a> <in ...

experiencing a problem with the scrollTo() function

I am encountering difficulty in finding the correct X and Y coordinate values to move an image using mouse scroll within a div. I have included my sample code below. I have successfully managed to scroll the image without using a div. Can anyone assist m ...

Ensuring the height of the body and content div in Bootstrap 4 combined with Angular set to

Is there a way to center the <div class="card"> in the middle of the page or body? It works perfectly on a desktop browser, but on mobile view, it's not aligning properly. How can I center it using... html, body { height: 100%; background: ...

Utilizing CSS for Aligning Horizontal Lists

How can I create a horizontal list with square bullets using the following style type? When I use display: inline, the squares don't appear. Any ideas on how to fix this issue? .vertical li {display: inline; list-style-type: square; padding-right: 5p ...

What is the best way to instantly update multiple form input fields with the slider value as it changes?

When a value is selected from a dropdown in a form, three input fields with the same value are displayed. For example, selecting "2" from the dropdown will result in two rows with six input fields - three in the first row and another three in the second ro ...

Height setting for flex column layout

.flex-body { display: flex; flex-wrap: wrap; } .flex-body div{ width: 50%; align-items: flex-start; } <div class="flex-body"> <div style="background: #0980cc; height:100px;"></div> <div style="background: #09cc69;height: 20 ...

When dealing with errors in multiline textarea content, an error may occur with the error handling

Currently, I have created an HTML/PHP form with a 'textarea' element. As I work on implementing error handling, I want to ensure that if a mistake is made in the form, the content entered by the user is retained. Specifically, when a user makes ...

Sliding through a webpage effortlessly with jQuery slider equipped with main navigation and sub

Currently, my slider utilizes arrows and dots for navigation. I am looking to enhance it by adding a multi-page directory on the right side of the slider. This directory will have numbered pages, each containing a different set of images in arrays correspo ...

What is preventing the table from extending to the full 100% width?

Displayed above is an image showing an accordion on the left side and content within a table on the right side. I have a concern regarding the width of the content part (right side) as to why the table is not occupying 100% width while the heading at the ...

JavaScript date input formatting with HTML

When using the input date picker in HTML, the default format displayed is MM-DD-YYYY. <input type="date" id="gdatum" /> Is there any method to change the mask to DD-MM-YYYY? ...

What could be causing the HTML page to not interpret the PHP page properly?

Whenever I click on the submit button, nothing happens and my data is not inserted into the database. I'm in the process of creating a registration page (register2.html) and db_reg.php to manage database entry. However, it seems that the HTML page i ...

Styling Text with CSS

I am currently using axios to fetch data from my backend. The data consists of a string format similar to "phone number: {enter phone number here}". My goal is to add CSS styling wherever there is a curly brace. let testString = "hello this ...

Form Controller Indicates Missing Data

Issue Resolved I've encountered an issue with my form controller's values not populating when I submit the form - they remain as empty strings. My suspicion is that there might be an error on the HTML side. Here is the register.component.ts file ...

The header, main content, and footer sections expand to occupy the entire page

I am in need of HTML structure that looks like the following: <header></header> <div id='main'></div> <footer></footer> I want all elements to be positioned relatively. The header and footer will have fixed h ...

Using Flexbox for Input Elements Causes Additional Margins in Webkit Browser

My form has a straightforward layout with an email field and a submit button. I am using a flexbox design for this form, which is working well overall. However, I have noticed that there seems to be some extra spacing added next to input elements in webkit ...

What is the method for updating the content within a div element?

I am trying to add multiple elements to my content, including an h1 element, an input field, and some buttons. I have written a function to create the h1 and input elements, but when trying to add them to my content div, I encountered an error (TypeError ...

Creating a custom page in Wordpress is a great way to personalize your

As a newcomer to the world of WordPress, I have embarked on theme development and encountered a few obstacles along the way. Although I believe that every problem has a solution, I am struggling to find one. Currently, I am working on creating a custom pa ...