Jump to content
Go to solution Solved by Ziggy,

Recommended Posts

@Ziggy

Hello,

 

Thanks - I tried that way (with code block) but doesn't seem to be working for me. Just showing as plain text on my site.

Also, supposedly this results in a 'round box with 2 lines going down' according to OP, I'd like an arrow similar to my example if possible!

 

2032133556_Screenshot2023-01-06at00_11_27.png.8e17c971e8fc9fc82ccc48b55fa4a2b5.png

Link to comment

@Ziggy Appreciate your help, thanks. That works - realised I had the drop down set to css not html.

One more question, is there a way to add a smooth 'scroll' transition when I click on the arrow? (Currently it just jumps to the next section)

This is the code I'm using:

Quote

 

<div class="bottom">
  <a class="scroll-indicator" href="#tscroll"></a>
</div>
<style>
.bottom {
    position: absolute;
    bottom: 0;
    width: 100%;
    left: 50%;
    transform: translateX(-50%);
  text-align: center;
}

.scroll-indicator {
display: inline-block;
  width: 24px;
  height: 24px;
  margin: 16px auto;
  border-right: 2px solid #FFF;
  border-bottom: 2px solid #FFF;
  border-bottom-right-radius: 2px;
  -webkit-transform: rotate(45deg);
          transform: rotate(45deg);
  -webkit-animation-duration: 2s;
          animation-duration: 2s;
  -webkit-animation-name: fade;
          animation-name: fade;
  -webkit-animation-iteration-count: infinite;
          animation-iteration-count: infinite;
  -webkit-animation-timing-function: linear;
          animation-timing-function: linear;
}

@-webkit-keyframes fade {
  0% {
    -webkit-transform: rotate(45deg);
            transform: rotate(45deg);
    opacity: 1;
  }
  75% {
    -webkit-transform: rotate(45deg) translateY(-6px) translateX(-6px);
            transform: rotate(45deg) translateY(-6px) translateX(-6px);
    opacity: 0;
  }
  100% {
    opacity: 0;
  }
}

@keyframes fade {
  0% {
    -webkit-transform: rotate(45deg);
            transform: rotate(45deg);
    opacity: 1;
  }
  75% {
    -webkit-transform: rotate(45deg) translateY(-6px) translateX(-6px);
            transform: rotate(45deg) translateY(-6px) translateX(-6px);
    opacity: 0;
  }
  100% {
    opacity: 0;
  }
}
</style>

 

 

Link to comment

Create an account or sign in to comment

You need to be a member in order to leave a comment

×
×
  • 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.