Jump to content

Text-Indent Animation on Link Hover

Recommended Posts

Site URL: https://www.roosbrothers.com/

I would like to add a text-indent animation to my project links on my homepage. I have managed to figure out the css to achieve the text-indent animation, however, I would like them to stay in the indented position until the mouse is no longer hovering over the link. Right now they bounce back to their original position immediately.

Site is: https://www.roosbrothers.com/

 

 

 

Link to comment
  • Replies 2
  • Views 939
  • Created
  • Last Reply

I think you want to use transitions and transforms instead of animations.

Something like the following. This is just a start. You'd need to extend to meet your needs.

.portfolio-hover-item-title {

  transition : transform 1s linear;
  
  }

.portfolio-hover-item-title:hover {

  transform : translateX( 15px );
  
  }

This is for a v7.1 site.

You'll need to remove the animation code or comment it out. If you remove make a copy somewhere.

Let us know how it goes.

Find my contributions useful? Please like, upvote, mark my answer as the best ( solution ), and see my profile. Thanks for your support! I am a Squarespace ( and other technological things ) consultant open for new projects.

Link to comment
8 hours ago, creedon said:

I think you want to use transitions and transforms instead of animations.

Something like the following. This is just a start. You'd need to extend to meet your needs.



.portfolio-hover-item-title {

  transition : transform 1s linear;
  
  }

.portfolio-hover-item-title:hover {

  transform : translateX( 15px );
  
  }

This is for a v7.1 site.

You'll need to remove the animation code or comment it out. If you remove make a copy somewhere.

Let us know how it goes.

Thanks @creedon, works perfectly!

Link to comment

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...

Squarespace Webinars

Free online sessions where you’ll learn the basics and refine your Squarespace skills.

Hire a Designer

Stand out online with the help of an experienced designer or developer.