Here is a reference picture.
https://i.sstatic.net/wsp6R.png
I am trying to create a slide effect for my arrow when clicking on different menu items. The arrow should move over the active menu item. By default, the arrow should point to the active menu. Each menu item should act like a tab, displaying a list of items when clicked. I have included the code snippet below, but I have been unable to achieve the desired effect.
Code Snippet:
.db-new-filters {
margin-bottom: 20px;
position: relative;
-webkit-box-sizing: border-box;
-moz-box-sizing: border-box;
box-sizing: border-box;
}
.db-new-filters .tabs {
border-bottom: 1px #dddddd solid;
position: relative;
}
ul,
ol,
nav ul,
nav ol {
list-style: none;
list-style-image: none;
}
.db-new-filters .tabs li:first-child {
margin-left: 0;
}
.db-new-filters .tabs li {
display: inline-block;
margin-left: 11px;
-webkit-transition: left 0.3s;
-moz-transition: left 0.3s;
-o-transition: left 0.3s;
transition: left 0.3s;
}
.db-new-filters .tabs li a {
padding: 3px 5px 10px 5px;
color: #999999;
font-size: 14px;
line-height: 42px;
font-weight: 400;
text-decoration: none;
text-transform: uppercase;
}
.db-new-filters .tabs li.pointer {
position: absolute;
z-index: 1;
width: 0;
height: 0;
left: 10px;
bottom: 0;
margin: 0;
border-bottom: 10px solid #dddddd;
border-right: 10px solid transparent;
border-left: 10px solid transparent;
}
<div class="db-new-filters">
<ul class="tabs js-db-status-tabs">
<li><a>Active</a>
</li>
<li><a>Paused</a>
</li>
<li><a>Pending</a>
</li>
<li><a>Unapproved</a>
</li>
<li class="pointer" style="left: 193.5px;"></li>
</ul>
</div>
I have searched on Google extensively for a solution but have been unsuccessful. If anyone knows how to solve this problem, please share the solution. I have spent more than an hour trying to figure this out, so any help would be greatly appreciated. Thank you in advance.