Use CSS and Bootstrap icons to create an up and down jumping indicator arrow animation effect

Use CSS and Bootstrap icons to create an up and down jumping indicator arrow animation effect

Sometimes the page is very long and needs an arrow to tell the user that there is more content below. This can be achieved using pure CSS.

HTML: Add a link that modifies the anchor point so that it slides to a specified position when clicked. Here, a down arrow from the Bootstrap 3.x version is used as the icon.

<a href="#" class="scroll-down">
  <span> <i class="glyphicon glyphicon-chevron-down"></i> </span>
</a>

CSS: Adding animation effects

/*Slide down animation effect*/
@-webkit-keyframes drop {
  0% { top:0px; opacity: 0;}
  30% { top:10px; opacity: 1;}
  100% { top:25px; opacity: 0;}
}
@keyframes drop {
  0% { top:0px; opacity: 0;}
  30% { top:10px; opacity: 1;}
  100% { top:25px; opacity: 0;}
}
/*Apply animation and add button effects*/
.scroll-down {
    border: 2px solid #bbb;
    border-radius: 50%;
    margin: 0 auto;
    height: 50px;
    width: 50px;
    display: block;
    text-align: center;
    z-index: 10;
    -webkit-transition: all 0.125s ease-in-out 0s;
    -moz-transition: all 0.125s ease-in-out 0s;
    -ms-transition: all 0.125s ease-in-out 0s;
    -o-transition: all 0.125s ease-in-out 0s;
    transition: all 0.125s ease-in-out 0s;
}
.scroll-down span {
    position: relative;
    color: #bbb;
    font-size: 24px;
    -webkit-animation-name: drop;
    -webkit-animation-duration: 1s;
    -webkit-animation-timing-function: linear;
    -webkit-animation-delay: 0s;
    -webkit-animation-iteration-count: infinite;
    -webkit-animation-play-state: running;
    animation-name: drop;
    animation-duration: 1s;
    animation-timing-function: linear;
    animation-delay: 0s;
    animation-iteration-count: infinite;
    animation-play-state: running;
}

Summarize

The above is what I introduced to you about using CSS and Bootstrap icons to create an up and down jumping indicator arrow animation effect. I hope it will be helpful to you. If you have any questions, please leave me a message and I will reply to you in time. I would also like to thank everyone for their support of the 123WORDPRESS.COM website!

<<:  Answers to several high-frequency MySQL interview questions

>>:  HTML Web Page List Tags Learning Tutorial

Recommend

A universal nginx interface to implement reverse proxy configuration

1. What is a proxy server? Proxy server, when the...

Vue implements graphic verification code login

This article example shares the specific code of ...

JavaScript+html implements random QR code verification on front-end pages

Share the cool front-end page random QR code veri...

How to position the header at the top using CSS sticky layout

Application scenarios: One of the new requirement...

5 ways to make your JavaScript codebase cleaner

Table of contents 1. Use default parameters inste...

MySQL implementation of lastInfdexOf function example

Sometimes MySQL needs to use a function similar t...

MySQL 8.0.2 offline installation and configuration method graphic tutorial

The offline installation method of MySQL_8.0.2 is...

K3s Getting Started Guide - Detailed Tutorial on Running K3s in Docker

What is k3d? k3d is a small program for running a...

Solution to the ineffective global style of the mini program custom component

Table of contents Too long to read Component styl...

VSCode configuration Git method steps

Git is integrated in vscode, and many operations ...

How to install MySQL database on Debian 9 system

Preface Seeing the title, everyone should be thin...

vue3+ts+EsLint+Prettier standard code implementation

Table of contents use Use of EsLint Add a profile...

Detailed explanation of the basic use of react-navigation6.x routing library

Table of contents react-native project initializa...

Steps to create a WEBSERVER using NODE.JS

Table of contents What is nodejs Install NodeJS H...