How do I override CSS that makes divs stack on top of each other and run full-width, to instead make the divs run left to right?
Specifically, how do I modify mine, 3 x .notion-callout or a child, at the bottom of this card, which run left to right, to ensure that they run side-by-side each other?
The objective is to have the grey boxes be only about as wide as the icons contained within, rather than stretch full-width, starting from the left.
(1) One thing I have done is to apply visibility: hidden to some anchor text in those boxes (I'm not in a position to alter the mark-up, only the CSS and CSS overrides).
(2) I have also poured over many similar Stackoverflow threads.
(3) I have tried applying a range of display values, ie. inline, inline-block, but can't get the box width to constrain.
/*I believe this is the relevant CSS. There is also an ultimate parent class with `display: flex`.*/
.notion-root.full-width {
width: 100%;
}
.notion-root {
display: -webkit-flex;
display: -moz-box;
display: flex;
-webkit-flex-direction: column;
-moz-box-orient: vertical;
-moz-box-direction: normal;
flex-direction: column;
}
.notion-callout {
display: -webkit-flex;
display: -moz-box;
display: flex;
border-radius: 5px;
padding: 16px 16px 16px 12px;
margin-top: 2px;
margin-bottom: 4px;
border: 1px solid transparent;
}
.notion-callout {
position: relative !important;
}
.notion-callout__icon {
width: 1.8em;
line-height: 1.3em;
padding: 1.2px;
}
.notion-callout__content {
margin-left: 8px;
visibility: hidden;
}
.notion-semantic-string {
line-height: 1.5;
}
.notion-semantic-string {
line-height: 1.5;
}
.notion-semantic-string .link {
color: inherit;
text-decoration: none;
border-bottom: 1px solid var(--color-text-default-light);
opacity: .7;
-moz-transition: border-color .1s ease-in, opacity .1s ease-in;
transition: border-color .1s ease-in, opacity .1s ease-in;
}
.notion-callout a {
padding: 0 0 2px 50px !important;
align-items: center !important;
position: absolute !important;
display: flex !important;
border: none !important;
bottom: 0 !important;
right: 0 !important;
left: 0 !important;
top: 0 !important;
}
<article id="block-44da810a1ed446bf9bf9c9ce058b1702" class="notion-root full-width">
<h3 id="block-d55821810b9b4f199d3befb349f1b29e" class="notion-heading">
<span class="notion-heading__anchor" id="d55821810b9b4f199d3befb349f1b29e"></span
><span class="notion-semantic-string"><span>Multiverse analyst</span></span>
</h3>
<div id="block-b26901cad4bf4def825f154ebe30e0c7" class="notion-text">
<p class="notion-text__content">
<span class="notion-semantic-string"><span
>Lorem ipsum dolor ex magna. Interdum malesuada fames ac ante ipsum
amet et faucibus. Pellentesque et venenatis.</span
></span
>
</p>
</div>
<div id="block-d6140ff909d34f99833ae73922f1a2e1" class="notion-text">
<p class="notion-text__content">
<span class="notion-semantic-string"></span>
</p>
</div>
<div id="block-974b3353883a4998b6ca59807914ceb9" class="notion-callout bg-gray-light border">
<div class="notion-callout__icon">
<div style="
overflow: hidden;
box-sizing: border-box;
display: inline-block;
position: relative;
width: 24px;
height: 24px;
">
<img alt="icon" src="/_next/image?url=https%3A%2F%2Fapi.super.so%2Fasset%2Fdemo.notionware.shop%2F755f0732-a73d-4410-b418-ff2f269a66b0.png&w=640&q=100" decoding="async" class="notion-icon" style="
visibility: visible;
position: absolute;
inset: 0px;
box-sizing: border-box;
padding: 0px;
border: medium none;
margin: auto;
display: block;
width: 0px;
height: 0px;
min-width: 100%;
max-width: 100%;
min-height: 100%;
max-height: 100%;
" srcset="
/_next/image?url=https%3A%2F%2Fapi.super.so%2Fasset%2Fdemo.notionware.shop%2F755f0732-a73d-4410-b418-ff2f269a66b0.png&w=640&q=100 1x
" />
</div>
</div>
<p class="notion-callout__content">
<span class="notion-semantic-string"><span
><a
href="http://www.notionhq.com"
class="notion-link link"
target="_blank"
rel="noopener noreferrer"
>PollardsProgress</a
></span
></span
>
</p>
</div>
<div
id="block-99956269608948c2a97ac5603368a892"
class="notion-callout bg-gray-light border"
>
<div class="notion-callout__icon">
<div
style="
overflow: hidden;
box-sizing: border-box;
display: inline-block;
position: relative;
width: 24px;
height: 24px;
"
>
<img
alt="icon"
src="/_next/image?url=https%3A%2F%2Fapi.super.so%2Fasset%2Fdemo.notionware.shop%2F3f605f41-8b78-4e86-b128-69e547cb34a3.png&w=640&q=100"
decoding="async"
class="notion-icon"
style="
visibility: visible;
position: absolute;
inset: 0px;
box-sizing: border-box;
padding: 0px;
border: medium none;
margin: auto;
display: block;
width: 0px;
height: 0px;
min-width: 100%;
max-width: 100%;
min-height: 100%;
max-height: 100%;
"
srcset="
/_next/image?url=https%3A%2F%2Fapi.super.so%2Fasset%2Fdemo.notionware.shop%2F3f605f41-8b78-4e86-b128-69e547cb34a3.png&w=640&q=100 1x
"
/>
</div>
</div>
<p class="notion-callout__content">
<span class="notion-semantic-string"
><span
><a
href="http://www.notionhq.com"
class="notion-link link"
target="_blank"
rel="noopener noreferrer"
>CaycePollard</a
></span
></span
>
</p>
</div>
<div
id="block-22e0c2a2e50a409ba6606503372bfa41"
class="notion-callout bg-gray-light border"
>
<div class="notion-callout__icon">
<div
style="
overflow: hidden;
box-sizing: border-box;
display: inline-block;
position: relative;
width: 24px;
height: 24px;
"
>
<img
alt="icon"
src="/_next/image?url=https%3A%2F%2Fapi.super.so%2Fasset%2Fdemo.notionware.shop%2Fee17734e-3566-4b32-b1e1-952dabc764bf.png&w=640&q=100"
decoding="async"
class="notion-icon"
style="
visibility: visible;
position: absolute;
inset: 0px;
box-sizing: border-box;
padding: 0px;
border: medium none;
margin: auto;
display: block;
width: 0px;
height: 0px;
min-width: 100%;
max-width: 100%;
min-height: 100%;
max-height: 100%;
"
srcset="
/_next/image?url=https%3A%2F%2Fapi.super.so%2Fasset%2Fdemo.notionware.shop%2Fee17734e-3566-4b32-b1e1-952dabc764bf.png&w=640&q=100 1x
"
/>
</div>
</div>
<p class="notion-callout__content">
<span class="notion-semantic-string"
><span
><a
href="http://www.medium.com"
class="notion-link link"
target="_blank"
rel="noopener noreferrer"
>Cayce's Musings</a
></span
></span
>
</p>
</div>
<div id="block-06ddcfa82b06404c87c3329408b97d7d" class="notion-text">
<p class="notion-text__content">
<span class="notion-semantic-string"></span>
</p>
</div>
</article>
As written above you can use CSS flex layout or you can also build a CSS grid layout.
/*I believe this is the relevant CSS. There is also an ultimate parent class with `display: flex`.*/
.notion-root{
display: grid;
grid-gap: 10px;
grid-template-columns: auto auto auto;
}
.notion-heading{
grid-column: 1 /span 3;
grid-row: 1;
}
.notion-text{
grid-column: 1 /span 3;
grid-row: 2;
}
.notion-callout {
grid-row: 3;
border-radius: 5px;
padding: 16px 16px 16px 12px;
margin-top: 2px;
margin-bottom: 4px;
border: 1px solid red;
}
.notion-callout__icon {
width: 1.8em;
line-height: 1.3em;
padding: 1.2px;
}
.notion-callout__content {
margin-left: 8px;
visibility: hidden;
}
.notion-semantic-string {
line-height: 1.5;
}
.notion-semantic-string {
line-height: 1.5;
}
.notion-semantic-string .link {
color: inherit;
text-decoration: none;
border-bottom: 1px solid var(--color-text-default-light);
opacity: .7;
-moz-transition: border-color .1s ease-in, opacity .1s ease-in;
transition: border-color .1s ease-in, opacity .1s ease-in;
}
.notion-callout a {
padding: 0 0 2px 50px !important;
align-items: center !important;
position: absolute !important;
display: flex !important;
border: none !important;
bottom: 0 !important;
right: 0 !important;
left: 0 !important;
top: 0 !important;
}
<article id="block-44da810a1ed446bf9bf9c9ce058b1702" class="notion-root full-width">
<h3 id="block-d55821810b9b4f199d3befb349f1b29e" class="notion-heading">
<span class="notion-heading__anchor" id="d55821810b9b4f199d3befb349f1b29e"></span
><span class="notion-semantic-string"><span>Multiverse analyst</span></span>
</h3>
<div id="block-b26901cad4bf4def825f154ebe30e0c7" class="notion-text">
<p class="notion-text__content">
<span class="notion-semantic-string"><span
>Lorem ipsum dolor ex magna. Interdum malesuada fames ac ante ipsum
amet et faucibus. Pellentesque et venenatis.</span
></span
>
</p>
</div>
<div id="block-d6140ff909d34f99833ae73922f1a2e1" class="notion-text">
<p class="notion-text__content">
<span class="notion-semantic-string"></span>
</p>
</div>
<div id="block-974b3353883a4998b6ca59807914ceb9" class="notion-callout bg-gray-light border">
<div class="notion-callout__icon">
<div style="
overflow: hidden;
box-sizing: border-box;
display: inline-block;
position: relative;
width: 24px;
height: 24px;
">
<img alt="icon" src="https://picsum.photos/200" decoding="async" class="notion-icon" style="
visibility: visible;
position: absolute;
inset: 0px;
box-sizing: border-box;
padding: 0px;
border: medium none;
margin: auto;
display: block;
width: 0px;
height: 0px;
min-width: 100%;
max-width: 100%;
min-height: 100%;
max-height: 100%;
" srcset="
https://picsum.photos/200
" />
</div>
</div>
<p class="notion-callout__content">
<span class="notion-semantic-string"><span
><a
href="http://www.notionhq.com"
class="notion-link link"
target="_blank"
rel="noopener noreferrer"
>PollardsProgress</a
></span
></span
>
</p>
</div>
<div
id="block-99956269608948c2a97ac5603368a892"
class="notion-callout bg-gray-light border"
>
<div class="notion-callout__icon">
<div
style="
overflow: hidden;
box-sizing: border-box;
display: inline-block;
position: relative;
width: 24px;
height: 24px;
"
>
<img
alt="icon"
src="https://picsum.photos/200"
decoding="async"
class="notion-icon"
style="
visibility: visible;
position: absolute;
inset: 0px;
box-sizing: border-box;
padding: 0px;
border: medium none;
margin: auto;
display: block;
width: 0px;
height: 0px;
min-width: 100%;
max-width: 100%;
min-height: 100%;
max-height: 100%;
"
srcset="
https://picsum.photos/200
"
/>
</div>
</div>
<p class="notion-callout__content">
<span class="notion-semantic-string"
><span
><a
href="http://www.notionhq.com"
class="notion-link link"
target="_blank"
rel="noopener noreferrer"
>CaycePollard</a
></span
></span
>
</p>
</div>
<div
id="block-22e0c2a2e50a409ba6606503372bfa41"
class="notion-callout bg-gray-light border"
>
<div class="notion-callout__icon">
<div
style="
overflow: hidden;
box-sizing: border-box;
display: inline-block;
position: relative;
width: 24px;
height: 24px;
"
>
<img
alt="icon"
src="https://picsum.photos/200"
decoding="async"
class="notion-icon"
style="
visibility: visible;
position: absolute;
inset: 0px;
box-sizing: border-box;
padding: 0px;
border: medium none;
margin: auto;
display: block;
width: 0px;
height: 0px;
min-width: 100%;
max-width: 100%;
min-height: 100%;
max-height: 100%;
"
srcset="
https://picsum.photos/200
"
/>
</div>
</div>
<p class="notion-callout__content">
<span class="notion-semantic-string"
><span
><a
href="http://www.medium.com"
class="notion-link link"
target="_blank"
rel="noopener noreferrer"
>Cayce's Musings</a
></span
></span
>
</p>
</div>
<div id="block-06ddcfa82b06404c87c3329408b97d7d" class="notion-text">
<p class="notion-text__content">
<span class="notion-semantic-string"></span>
</p>
</div>
</article>
Related
I'm trying to achieve the following:
The problem I still have is the line before the first element and after the last element should be hidden.
The second issue is that the numbers are not vertically centered even when I use a flexbox with align-items and justify-content, if I zoom the picture a bit you can see that there is some difference:
The difference without zooming is about 2px~3px.
This is what I tried:
.container {
margin-top: 60px;
position: relative;
}
ol {
counter-reset: section;
list-style-type: none;
border-top: 1px solid #D9DEEA;
padding: 0;
margin: 36px 0 210px 0;
}
li {
float: left;
width: 20%;
padding-top: calc(58px / 2);
position: relative;
font-family: 'Antonio', sans-serif;
font-weight: 700;
display: flex;
flex-direction: column;
align-items: center;
}
li::before {
counter-increment: section;
content: counters(section, ".") " ";
width: 56px;
height: 56px;
background: #fff;
border: 2px dashed #D9DEEA;
border-radius: 50%;
box-shadow: 0 0 0 6px #fff;
position: absolute;
top: -30.5px;
left: calc(50% - 30px);
display: flex;
justify-content: center;
align-items: center;
line-height: 34px;
font-size: 24px;
}
.title {
margin: 6px 0;
line-height: 30px;
letter-spacing: -0.77px;
font-size: 25px;
display: block;
text-align: center;
}
.illustration {
display: block;
width: 165px;
height: 140px;
display: flex;
align-items: center;
justify-content: center;
background-color: #E6E9F0;
}
<link rel="preconnect" href="https://fonts.gstatic.com">
<link href="https://fonts.googleapis.com/css2?family=Antonio:wght#300;400;700&family=Roboto:wght#300;400;500;700&display=swap" rel="stylesheet">
<section class="container">
<ol>
<li>
<span class="title">Lorem.</span>
<span class="illustration">
<img src="" alt="">
</span>
</li>
<li>
<span class="title">Lorem, ipsum.</span>
<span class="illustration">
<img src="" alt="">
</span>
</li>
<li>
<span class="title">Lorem, ipsum dolor.</span>
<span class="illustration">
<img src="" alt="">
</span>
</li>
<li>
<span class="title">Lorem ipsum.</span>
<span class="illustration">
<img src="" alt="">
</span>
</li>
<li>
<span class="title">Lorem, ipsum dolor.</span>
<span class="illustration">
<img src="" alt="">
</span>
</li>
</ol>
</section>
I finally found a solution for the first issue.
The idea is to use a pseudo-element for ol that will act as a border with limited width.
.container {
margin-top: 60px;
position: relative;
}
ol {
counter-reset: section;
list-style-type: none;
padding: 0;
margin: 36px 0 0 0;
}
ol::before {
content: "";
display: block;
background: #D9DEEA;
position: absolute;
top: 0;
left: 10%;
height: 1px;
width: 80%;
}
li {
float: left;
width: 20%;
padding-top: calc(58px / 2);
position: relative;
font-family: 'Antonio', sans-serif;
font-weight: 700;
display: flex;
flex-direction: column;
align-items: center;
}
li::before {
counter-increment: section;
content: counters(section, ".") " ";
width: 56px;
height: 56px;
background: #fff;
border: 2px dashed #D9DEEA;
border-radius: 50%;
box-shadow: 0 0 0 6px #fff;
position: absolute;
top: -30.5px;
left: calc(50% - 30px);
display: flex;
justify-content: center;
align-items: center;
line-height: 34px;
font-size: 24px;
}
.title {
margin: 6px 0;
line-height: 30px;
letter-spacing: -0.77px;
font-size: 25px;
display: block;
text-align: center;
}
.illustration {
display: block;
width: 165px;
height: 140px;
display: flex;
align-items: center;
justify-content: center;
background-color: #E6E9F0;
}
<link rel="preconnect" href="https://fonts.gstatic.com">
<link href="https://fonts.googleapis.com/css2?family=Antonio:wght#300;400;700&family=Roboto:wght#300;400;500;700&display=swap" rel="stylesheet">
<section class="container">
<ol>
<li>
<span class="title">Lorem.</span>
<span class="illustration">
<img src="" alt="">
</span>
</li>
<li>
<span class="title">Lorem, ipsum.</span>
<span class="illustration">
<img src="" alt="">
</span>
</li>
<li>
<span class="title">Lorem, ipsum dolor.</span>
<span class="illustration">
<img src="" alt="">
</span>
</li>
<li>
<span class="title">Lorem ipsum.</span>
<span class="illustration">
<img src="" alt="">
</span>
</li>
<li>
<span class="title">Lorem, ipsum dolor.</span>
<span class="illustration">
<img src="" alt="">
</span>
</li>
</ol>
</section>
I'm not sure how to fix your problem with the styling of the li::before element, but here is a solution for your timeline not extending past 1 or 5. Add a ::before element to the ol element.
Edit: Solution was sourced from Border length smaller than div width?
.container {
margin-top: 60px;
position: relative;
}
ol {
counter-reset: section;
list-style-type: none;
padding: 0;
margin: 36px 0 210px 0;
}
ol::before {
content: "";
height: 10px;
width: 90%;
position: absolute;
top: -10px;
left: 5%;
/* or 100px */
border-bottom: 1px solid magenta;
}
li {
float: left;
width: 20%;
padding-top: calc(58px / 2);
position: relative;
font-family: 'Antonio', sans-serif;
font-weight: 700;
display: flex;
flex-direction: column;
align-items: center;
}
li::before {
counter-increment: section;
content: counters(section, ".") " ";
width: 56px;
height: 56px;
background: #fff;
border: 2px dashed #D9DEEA;
border-radius: 50%;
box-shadow: 0 0 0 6px #fff;
position: absolute;
top: -30.5px;
left: calc(50% - 30px);
display: flex;
justify-content: center;
align-items: center;
line-height: 34px;
font-size: 24px;
}
.title {
margin: 6px 0;
line-height: 30px;
letter-spacing: -0.77px;
font-size: 25px;
display: block;
text-align: center;
}
.illustration {
display: block;
width: 165px;
height: 140px;
background: url("../Images/API_EDI/catalog-bg.png") no-repeat center center;
display: flex;
align-items: center;
justify-content: center;
background-color: #E6E9F0;
}
<link rel="preconnect" href="https://fonts.gstatic.com">
<link href="https://fonts.googleapis.com/css2?family=Antonio:wght#300;400;700&family=Roboto:wght#300;400;500;700&display=swap" rel="stylesheet">
<section class="container">
<ol>
<li>
<span class="title">Lorem.</span>
<span class="illustration">
<img src="" alt="">
</span>
</li>
<li>
<span class="title">Lorem, ipsum.</span>
<span class="illustration">
<img src="" alt="">
</span>
</li>
<li>
<span class="title">Lorem, ipsum dolor.</span>
<span class="illustration">
<img src="" alt="">
</span>
</li>
<li>
<span class="title">Lorem ipsum.</span>
<span class="illustration">
<img src="" alt="">
</span>
</li>
<li>
<span class="title">Lorem, ipsum dolor.</span>
<span class="illustration">
<img src="" alt="">
</span>
</li>
</ol>
</section>
I'm trying to fit my sticky left menu to the height of my content, but I'm not be able to do it.
I try adding height: 100% to all parents div, but nothing happens
My code is: (before is and )
<main>
<div class="container">
<div class="content-wrapper">
<router-view />
</div>
<div class="navigation__menu">
<div
class="container-menu"
:class="{'show': this.$store.getters.showSidebar}">
<main-menu
#click.native="showNav" />
<menu-options />
</div>
</div>
</div>
</main>
<template>
<div id="main-menu">
<div class="control">
<i
class="fas fa-angle-double-right" />
</div>
</div>
</template>
<template>
<div id="menu-options">
<div
class="navigation-icons-menu">
<a
title="Home"
href="/"><i class="fas fa-home" /></a>
<a
title="FIG"
href="/fig-console"><i class="fas fa-clipboard-list" /></a>
<a
title="Service client"
href="/"><i class="fas fa-users" /></a>
<a
title="Budget"
href="/"><i class="fas fa-file-invoice" /></a>
<a
title="Contracting"
href="/"><i class="fas fa-file-contract" /></a>
<a
title="Invoicing"
href="/"><i class="fas fa-file-invoice-dollar" /></a>
<a
title="Administration"
href="/"><i class="fas fa-cogs" /></a>
</div>
<div
v-if="this.$store.getters.showSidebar"
class="navigation-links-menu">
<transition-group name="fade">
<div
v-show="this.$store.getters.showLink"
key="1">
<a
title="Home"
href="/">Home</a>
</div>
<div
v-show="this.$store.getters.showLink"
key="2">
<a
title="FIG"
href="/fig-console">FIG</a>
</div>
<div
v-show="this.$store.getters.showLink"
key="3">Service client</div>
<div
v-show="this.$store.getters.showLink"
key="4">Budget</div>
<div
v-show="this.$store.getters.showLink"
key="5">Contracting</div>
<div
v-show="this.$store.getters.showLink"
key="6">Invoicing</div>
<div
v-show="this.$store.getters.showLink"
key="7">Administration</div>
</transition-group>
</div>
</div>
</template>
.container-menu {
position: absolute;
top: 65px;
padding-top: 10px;
left: 0;
width: 62px;
min-height: 100%;
height: 100%;
background-color: $navy;
border: solid $white;
border-width: 0 1px 0 0;
z-index: 1001;
transition: all .5s ease-in-out;
.control {
display: flex;
justify-content: center;
align-items: center;
//width: 50px;
margin-bottom: 10px;
color: $white;
i {
font-size: 2rem;
cursor: pointer;
transition: all .5s ease-in-out;
}
}
&.show {
width: 170px;
.control > i {
color: $white;
transform: rotateZ(-180deg);
}
}
.navigation-icons-menu {
display: flex;
justify-content: center;
align-items: center;
flex-direction: column;
width: 50px;
float: left;
i {
color: $white;
font-size: 2rem;
padding: 10px 0;
cursor: pointer;
transition: all .5s ease-in-out;
&:hover {
color: $white;
}
}
}
.navigation-links-menu {
//padding:14px;
float: left;
color: $white;
div {
font-size: 1.35rem;
padding: 10px;
cursor: pointer;
#include breakpoint-only(tablet) {
font-size: 7px;
padding: 10px 5px;
}
a {
color: $white;
}
}
}
}
vh will solve your problem.
Instead of a pixel or percentage value. Use vh which stands for "viewport height".
An element with height: 100vh will be given a height the full height of the viewport.
.container-menu {
position: absolute;
top: 65px;
padding-top: 10px;
left: 0;
width: 62px;
height: 100vh;
background-color: $navy;
border: solid $white;
border-width: 0 1px 0 0;
z-index: 1001;
transition: all .5s ease-in-out;
.control {
display: flex;
justify-content: center;
align-items: center;
//width: 50px;
margin-bottom: 10px;
color: $white;
i {
font-size: 2rem;
cursor: pointer;
transition: all .5s ease-in-out;
}
}
&.show {
width: 170px;
.control > i {
color: $white;
transform: rotateZ(-180deg);
}
}
.navigation-icons-menu {
display: flex;
justify-content: center;
align-items: center;
flex-direction: column;
width: 50px;
float: left;
i {
color: $white;
font-size: 2rem;
padding: 10px 0;
cursor: pointer;
transition: all .5s ease-in-out;
&:hover {
color: $white;
}
}
}
.navigation-links-menu {
//padding:14px;
float: left;
color: $white;
div {
font-size: 1.35rem;
padding: 10px;
cursor: pointer;
#include breakpoint-only(tablet) {
font-size: 7px;
padding: 10px 5px;
}
a {
color: $white;
}
}
}
}
I am trying to get a div height take the remaining space between two divs.
<div id='company_col' class='contact_columns'>
<div id='company_title' class ='col_title'>
<h3>Company</h3>
</div>
<hr>
<div id='company_list' class='contact_lists'>
</div>
<div id='company_edit_bar' class='edit_bar'>
<div id='company_add_btn' class='edit_btn'>
<i class='fa fa-plus' aria-hidden='true'></i>
</div>
<div id='company_delete_btn' class='edit_btn'>
<i class='fa fa-minus' aria-hidden='true'></i>
</div>
</div>
Here is the JS Fiddle: https://jsfiddle.net/xqLpqsdk/
I need to make .contact_lists to fill the space between .col_title and .edit_bar so the scroll bar is only displayed between those 2 divs
I've tried making .contact_lists position absolute but that didn't work.
If I am not wrong this will solve your issue. Please take a look at this,
#contact_editor_wrapper {
display: block;
position: absolute;
top: 0;
left: 0;
width: 100%;
height: 100%;
background-color: rgba(0, 0, 0, .5);
z-index: 10000;
}
#contact_editor {
display: block;
position: absolute;
width: 100%;
max-width: 1400px;
height: 100%;
min-height: 400px;
max-height: 800px;
background-color: #99AFC5;
border: solid 1px black;
border-radius: 10px;
margin: 0 auto;
padding: 2.5px 5px;
}
#x_contact_editor {
display: inline-block;
position: absolute;
right: 5px;
cursor: pointer;
}
.contact_editor_row {
margin: .5% 0;
}
#contact_editor_title_wrapper {
display: block;
width: 100%;
height: 4%;
}
#contact_editor_title {
padding: 6px 0;
text-align: center;
font-size: 20px;
text-shadow: 0 1px 1px rgba(0,0,0,.2);
}
#contact_columns {
display: flex;
height: 89%;
width: 100%;
flex-direction: row;
justify-content: center;
}
.contact_columns {
display: flex;
flex-flow: column;
height: 100%;
background-color: white;
margin: 0 .25%;
border: 1px solid black;
border-radius: 5px;
overflow: hidden;
}
#type_col {
width: 14.5%;
}
#company_col {
width: 42%;
}
#contact_col {
width: 42%
}
#contact_editor_btns {
display: block;
width: 100%;
height: 4%;
}
.col_title {
display: block;
text-align: center;
width: 100%;
height: auto;
margin-top: 9px;
text-shadow: 0 1px 1px rgba(0,0,0,.2);
border-bottom: 1px solid black;
}
.contact_lists {
position: relative;
height: 100%;
overflow-y: scroll;
}
.edit_bar {
display: block;
//position: absolute;
bottom: 0;
width: 100%;
height: auto;
border-top: 1px solid black;
border-radius: 0 0 5px 5px;
background-color: #00162C;
}
.edit_btn {
color: white;
display: inline-block;
height: 100%;
margin: 0;
padding: 0;
border-right: 1px solid black;
transition: all .5s ease;
}
.edit_btn:hover {
background-color: #99AFC5;
transition: all .5s ease;
}
.edit_btn i {
margin: 4px 8px;
}
#company_delete_btn, #contact_delete_btn {
margin-left: -2.5px;
}
<div id='contact_editor_wrapper' class='hide_contact_editor'>
<div id='contact_editor'>
<div id='x_contact_editor'>
<i class='fa fa-times' aria-hidden='true'></i>
</div>
<div id='contact_editor_title_wrapper' class='contact_editor_row'>
<div id='contact_editor_title'>Contact Editor</div>
</div>
<div id='contact_columns' class='contact_editor_row'>
<div id='type_col' class='contact_columns'>
<div id='type_title' class ='col_title'>
<h3>Type</h3>
</div>
<hr>
<div id='type_list' class='contact_lists'>
</div>
</div>
<div id='company_col' class='contact_columns'>
<div id='company_title' class ='col_title'>
<h3>Company</h3>
</div>
<hr>
<div id='company_list' class='contact_lists'>
</div>
<div id='company_edit_bar' class='edit_bar'>
<div id='company_add_btn' class='edit_btn'>
<i class='fa fa-plus' aria-hidden='true'></i>
</div>
<div id='company_delete_btn' class='edit_btn'>
<i class='fa fa-minus' aria-hidden='true'></i>
</div>
</div>
</div>
<div id='contact_col' class='contact_columns'>
<div id='contact_title' class ='col_title'>
<h3>Contact</h3>
</div>
<hr>
<div id='contact_list' class='contact_lists'>
</div>
<div id='contact_edit_bar' class='edit_bar'>
<div id='contact_add_btn' class='edit_btn'>
<i class='fa fa-plus' aria-hidden='true'></i>
</div>
<div id='contact_delete_btn' class='edit_btn'>
<i class='fa fa-minus' aria-hidden='true'></i>
</div>
</div>
</div>
</div>
<div id='contact_editor_btns' class='contact_editor_row'>
</div>
</div>
</div>
So, I'm using a while loop with PHP. The while loop makes the following code:
<img src='$user_six' class='avatar_friend'>
Please don't worry about $user_six or the background info on the while loop. I know it works. I'm trying to put three avatars on top of a movie. The problem is that each image takes space and is ruining the spacing with the movies.
This is the information of .avatar_friend:
.avatar_friend {
width: 36px;
height: 36px;
position: relative;
z-index: 10;
border: 1px solid white;
}
I think absolute positioning works better, but the images overlap each other.
This is the information of .avatar_friend:
.avatar_friend {
width: 36px;
height: 36px;
position: absolute;
z-index: 10;
border: 1px solid white;
}
How can I have the best of both positions? I want proper spacing, but no overlapping. How can I achieve this effect?
EDIT:
I've tried doing the following:
html
<div id='container'> <img src='$user_six' class='avatar_friend'> </div>
css
#container {
position: absolute;
}
.avatar_friend {
width: 36px;
height: 36px;
position: relative;
z-index: 10;
border: 1px solid white;
}
This did not work...
EDIT 2:
html
<!DOCTYPE html>
<html>
<head>
<title> Movies </title>
<link rel="stylesheet" href="http://fontawesome.io/assets/font-awesome/css/font-awesome.css">
<link rel='stylesheet' href='main.css'>
<script src="https://ajax.googleapis.com/ajax/libs/jquery/1.12.0/jquery.min.js"></script>
<script src='main.js'></script>
</head>
<body>
<!-- Navigation -->
<div id='nav'>
<!-- Profile Wrapper -->
<ul class="profile-wrapper">
<li>
<!-- user profile -->
<div class="profile">
<img src="avatars/default.png" />
MatthewMalan <i class="fa fa-caret-down" id="caret-down"></i>
<!-- more menu -->
<ul class="menu">
<li>Sign Out</li>
<li>Sign Out</li>
<li>Sign Out</li>
</ul>
</div>
</li>
</ul>
<!-- End of Profile Wrapper -->
</div>
<!-- End of Navigation -->
<!-- Movie Content -->
<div id='movie_content2'>
<div id='movie_line'>
<div id='movie_line2'></div>
<!-- Dropdown Selection -->
<nav>
<ul id="dropdown_selection">
<li>Most Recent
<ul>
<li> Most Liked </li>
<li> My History </li>
<li> My Likes </li>
</ul>
</li>
</ul>
</nav>
<!-- End of Dropdown Selection -->
<div id='descriptive_div' number='1'> <i class='fa fa-caret-left' id='descriptive_caret' number='1'></i> <a href='like.php?number=7&page=1'><a href='like.php?number=7&page=1&code=1&sorting=recent'> <div class='like_button' number='1'> Like </div> </a></a> <span id='descriptive_div_text'> Professional, Clean, Ready to Go </span> <div id='files_left'> 3 Copies Left </div> </div><a href='open.php?destination=movies/56c7ede7d3ed3658.44679765.mp4'> <div class='movie_length' number='1'> <div id='movie_length_text' number='1'> 1h 20m </div> </div> </a><a href='open.php?destination=movies/56c7ede7d3ed3658.44679765.mp4'> <div class='movie_rating3' number='1'> <span id='movie_rating_text' number='1'> G </span> </div> </a><a href='open.php?destination=movies/56c7ede7d3ed3658.44679765.mp4'> <img src='covers/inside.jpg' class='movie_size' number='1'> </a><div id='descriptive_div' number='2'> <i class='fa fa-caret-left' id='descriptive_caret' number='2'></i> <a href='like.php?number=8&page=1'><a href='like.php?number=8&page=1&code=1&sorting=recent'> <div class='like_button' number='2'> Like </div> </a></a> <span id='descriptive_div_text'> s </span> <div id='files_left'> 1 Copy Left </div> </div><a href='open.php?destination=movies/56c7ede7d3ed3108.44679765.mp4'> <div class='movie_length' number='2'> <div id='movie_length_text' number='2'> 2h 16m </div> </div> </a><a href='open.php?destination=movies/56c7ede7d3ed3108.44679765.mp4'> <div class='movie_rating' number='2'> <span id='movie_rating_text' number='2'> PG-13 </span> </div> </a><a href='open.php?destination=movies/56c7ede7d3ed3108.44679765.mp4'> <img src='covers/star wars.jpg' class='movie_size' number='2'> </a><img src='avatars/sam.jpg' class='avatar_friend'><img src='avatars/traek.jpg' class='avatar_friend'><img src='avatars/jessie.jpg' class='avatar_friend'><div id='descriptive_div' number='3'> <i class='fa fa-caret-left' id='descriptive_caret' number='3'></i> <a href='like.php?number=9&page=1'><a href='like.php?number=9&page=1&sorting=recent'> <div class='liked_button' number='3'> Like </div> </a></a> <span id='descriptive_div_text'> r </span> <div id='files_left'> 7 Copies Left </div> </div><a href='open.php?destination=movies/56e06853166618.33290858.mp4'> <div class='movie_length' number='3'> <div id='movie_length_text' number='3'> r </div> </div> </a><a href='open.php?destination=movies/56e06853166618.33290858.mp4'> <div class='movie_rating4' number='3'> <span id='movie_rating_text' number='3'> PG-13 </span> </div> </a><a href='open.php?destination=movies/56e06853166618.33290858.mp4'> <img src='covers/56e068530dc9f9.52895782.jpg' class='movie_size3' number='3'> </a><br><div class="complete_page">1</div> </div>
</div>
<!-- End of Movie Content -->
</body>
</html>
css
/* Rating of Movie Content */
.movie_rating, .movie_rating2, .movie_rating3, .movie_rating4, .movie_rating5, .movie_rating6, .movie_length, .movie_length2 {
display: inline-block;
width: 100px;
height: 30px;
background: #E10E0D;
color: white;
text-align: center;
position: absolute;
z-index: 5;
font-family: 'Days One', sans-serif;
cursor: pointer;
margin-top: -10px;
margin-left: 16px;
-webkit-touch-callout: none;
-webkit-user-select: none;
-khtml-user-select: none;
-moz-user-select: none;
-ms-user-select: none;
user-select: none;
border: 1px solid #FE4042;
}
.movie_rating4, .movie_rating5, .movie_rating6 {
background: #7D5505;
border: 1px solid #F9BA01;
}
.movie_length, .movie_length2 {
width: 120px;
background: #02477D;
border: 1px solid #97D0F2;
margin-top: 239px;
}
.movie_length2 {
width: 75px;
}
.movie_rating2, .movie_rating5 {
width: 60px;
}
.movie_rating3, .movie_rating6 {
width: 40px;
}
#movie_rating_text, #movie_length_text {
font-size: 25px;
position: relative;
top: 0px;
font-family: 'Days One', sans-serif;
letter-spacing: 1px;
}
/* Description of Movie */
#descriptive_div {
position: absolute;
width: 400px;
min-height: 241px;
background: black;
color: white;
z-index: 6;
margin-left: 228px;
margin-top: -10px;
font-size: 16px;
line-height: 25px;
padding-bottom: 30px;
border: 5px solid #ccc;
display: none;
}
#descriptive_div_text {
width: 370px;
display: inline-block;
position: relative;
left: 14px;
top: 14px;
text-align: left;
}
#descriptive_caret {
color: #ccc;
font-size: 51px;
position: absolute;
margin-left: -19px;
margin-top: 115px;
display: none;
}
/* End of Description of Movie */
/* Movie Line */
#movie_line2 {
width: 1px;
height: 635px;
background: #ccc;
position: absolute;
left: 1120px;
top: 10px;
z-index: 2;
}
/* End of Movie Line */
/* End of Rating of Movie Content */
/* Like Button */
.like_button, .liked_button {
background: #0566AE;
width: 50px;
padding: 3px;
color: white;
text-align: center;
position: absolute;
margin-left: -95px;
z-index: 6;
border-radius: 3px;
cursor: pointer;
font-family: 'Days One', sans-serif;
font-size: 18px;
letter-spacing: 1px;
-webkit-touch-callout: none;
-webkit-user-select: none;
-khtml-user-select: none;
-moz-user-select: none;
-ms-user-select: none;
user-select: none;
}
.liked_button {
background: #2C599D;
margin-left: -95px;
margin-top: 0;
}
.like_button:hover {
background: #2C599D;
}
.show {
opacity: 1;
}
/* End of Like Button */
/* End of Movie Content */
/* Tab System for admin.php */
h1, h2, h3, h4 {
padding: 0;
margin: .1rem 0;
border-left: 4px solid #4F2CCA;
padding-left: 8px;
}
.material-tabs {
display: block;
float: left;
padding: 16px;
padding-top: 0;
width: 100%;
max-width: 480px;
left: calc(50% - 480px/2);
position: relative;
margin: 96px auto;
background: #fff;
box-shadow: 0 10px 20px rgba(0, 0, 0, 0.19), 0 6px 6px rgba(0, 0, 0, 0.23) !important;
border-radius: 2px;
}
#media all and (max-width: 480px) {
.material-tabs {
max-width: 100%;
left: 0;
}
}
.visible {
position: relative;
opacity: 1;
width: 100%;
height: auto;
float: left;
-webkit-transition: opacity .35s ease;
transition: opacity .35s ease;
z-index: 3;
}
.hidden {
position: absolute;
opacity: 0;
z-index: 0;
-webkit-transition: opacity 0s ease;
transition: opacity 0s ease;
}
.hidden img {
display: none;
}
[class*="tabbed-section-"] {
float: left;
color: #000;
}
[class*="tabbed-section-"] img {
display: block;
width: 80%;
margin: auto 10%;
}
.tabbed-section__selector {
position: relative;
height: 32px;
top: -31.2px;
left: -16px;
padding: 0;
margin: 0;
width: 100%;
float: left;
}
.tabbed-section__selector [class*="-tab-"] {
float: left;
display: block;
height: 32px;
line-height: 32px;
width: 100px;
text-align: center;
background: #fff;
font-weight: bold;
text-decoration: none;
color: black;
font-size: 14px;
}
.tabbed-section__selector [class*="-tab-"].active {
color: #4F2CCA;
}
.tabbed-section__selector a:first-child {
border-top-left-radius: 2px;
}
.tabbed-section__selector a:last-of-type {
border-top-right-radius: 2px;
}
.tabbed-section__highlighter {
position: absolute;
z-index: 10;
bottom: 0;
height: 2px;
background: #4F2CCA;
max-width: 100px;
width: 100%;
-webkit-transform: translateX(0);
transform: translateX(0);
display: block;
left: 0;
-webkit-transition: -webkit-transform 0.23s ease;
transition: -webkit-transform 0.23s ease;
transition: transform 0.23s ease;
transition: transform 0.23s ease, -webkit-transform 0.23s ease;
}
.tabbed-section__selector-tab-3.active ~ .tabbed-section__highlighter {
-webkit-transform: translateX(200px);
transform: translateX(200px);
}
.tabbed-section__selector-tab-2.active ~ .tabbed-section__highlighter {
-webkit-transform: translateX(100px);
transform: translateX(100px);
}
.tabbed-section__selector-tab-1.active ~ .tabbed-section__highlighter {
-webkit-transform: translateX(0);
transform: translateX(0);
}
.divider {
background: rgba(0, 0, 0, 0.1);
position: relative;
display: block;
float: left;
width: 100%;
height: 1px;
margin: 8px 0;
padding: 0;
overflow: hidden;
}
/* End of Tab system for admin.php */
/* Create */
#title, #length {
font-size: 16px;
border: 1px solid #ccc;
padding: 11px;
outline: none;
border-radius: 3px;
width: 400px;
}
#title:focus, #description:focus, #length:focus {
border: 1px solid #A9A9A9;
}
#description {
font-size: 16px;
border: 1px solid #ccc;
padding: 11px;
outline: none;
border-radius: 3px;
width: 400px;
resize: vertical;
max-height: 70px;
}
#rating_text {
position: relative;
top: -10px;
}
#length_text {
position: relative;
top: -10px;
}
/* End of Create */
/* Dropdown Selection */
nav {
margin: 10rem auto;
width: 220px;
position: absolute;
left: 1150px;
top: -140px;
}
nav ul {
color: #fff;
font-family: sans-serif;
font-size: 1.4rem;
letter-spacing: .1rem;
position: relative;
width: 100%;
}
nav a {
background: #1A1A1A;
color: inherit;
display: block;
text-decoration: none;
padding: 1rem;
}
nav ul ul a:hover {
background: #666;
}
nav ul ul {
display: none;
padding-top: 1rem;
position: absolute;
}
nav ul:hover ul {
display: block;
}
nav ul:first-child:hover > li:first-child:before {
border: .7rem solid transparent;
border-top-color: #fff;
}
nav ul ul > li:not(:last-child) {
border-bottom: 1px solid white;
}
nav ul > li:first-child:before {
content: "";
position: absolute;
}
nav ul:first-child > li:first-child:before {
border: .7rem solid transparent;
border-top-color: #fff;
pointer-events: none;
left: 175px;
top: 30px;
}
.fa {
margin-right: .5rem;
}
/* End of Dropdown Selection */
/* Files Left */
#files_left {
color: red;
width: 110px;
padding: 1px;
border: 1px solid red;
text-align: center;
border-radius: 10%;
position: relative;
left: 15px;
top: 20px;
}
/* End of Files Left */
/* Avatar */
.avatar_friend {
width: 36px;
height: 36px;
position: relative;
z-index: 10;
border: 1px solid white;
}
/* End of Avatar */
Some of the CSS may be for other pages. I realize this is a lot of information. Let me know if you need anything else...
First of all, you use the same id in 6 elements for every movie, which you shouldn't. An id is unique, so change that to like 'descriptive_div_1', 'descriptive_caret_1', etc (I did that in the samples below so you can see where).
This is how a movie section looks like (repeated for each movie, no wrapper around each of them)
<div id='descriptive_div_2' number='2'>
<i class='fa fa-caret-left' id='descriptive_caret_2' number='2'></i>
<a href='like.php?number=8&page=1'>
<a href='like.php?number=8&page=1&code=1&sorting=recent'>
<div class='like_button' number='2'> Like </div>
</a>
</a>
<span id='descriptive_div_text_2'> s </span>
<div id='files_left_2'> 1 Copy Left </div>
</div>
<a href='open.php?destination=movies/56c7ede7d3ed3108.44679765.mp4'>
<div class='movie_length' number='2'>
<div id='movie_length_text_2' number='2'> 2h 16m </div>
</div>
</a>
<a href='open.php?destination=movies/56c7ede7d3ed3108.44679765.mp4'>
<div class='movie_rating_2' number='2'>
<span id='movie_rating_text_2' number='2'> PG-13 </span>
</div>
</a>
<a href='open.php?destination=movies/56c7ede7d3ed3108.44679765.mp4'>
<img src='covers/star wars.jpg' class='movie_size' number='2'>
</a>
<img src='avatars/sam.jpg' class='avatar_friend'>
<img src='avatars/traek.jpg' class='avatar_friend'>
<img src='avatars/jessie.jpg' class='avatar_friend'>
So to be able to target each avatar_friend in each movie section, you need CSS rules like this
.avatar_friend {
width: 36px;
height: 36px;
position: absolute;
z-index: 10;
border: 1px solid white;
}
div[number] + a + a + a ~ .avatar_friend:nth-of-type(3n+1) {
left: 0px;
}
div[number] + a + a + a ~ .avatar_friend:nth-of-type(3n+2) {
left: 36px;
}
div[number] + a + a + a ~ .avatar_friend:nth-of-type(3n+3) {
left: 72px;
}
The problem with this is you need to know how many avatars_friend's it is, as you need to change the nth-of-type counter and the amount of CSS rules accordingly.
By adding a wrapper like this for the avatar's, will fix it for you
<div id='descriptive_div_2' number='2'>
<i class='fa fa-caret-left' id='descriptive_caret_2' number='2'></i>
<a href='like.php?number=8&page=1'>
<a href='like.php?number=8&page=1&code=1&sorting=recent'>
<div class='like_button' number='2'> Like </div>
</a>
</a>
<span id='descriptive_div_text_2'> s </span>
<div id='files_left_2'> 1 Copy Left </div>
</div>
<a href='open.php?destination=movies/56c7ede7d3ed3108.44679765.mp4'>
<div class='movie_length' number='2'>
<div id='movie_length_text_2' number='2'> 2h 16m </div>
</div>
</a>
<a href='open.php?destination=movies/56c7ede7d3ed3108.44679765.mp4'>
<div class='movie_rating_2' number='2'>
<span id='movie_rating_text_2' number='2'> PG-13 </span>
</div>
</a>
<a href='open.php?destination=movies/56c7ede7d3ed3108.44679765.mp4'>
<img src='covers/star wars.jpg' class='movie_size' number='2'>
</a>
<div class='avatar_friend_wrapper'>
<img src='avatars/sam.jpg' class='avatar_friend'>
<img src='avatars/traek.jpg' class='avatar_friend'>
<img src='avatars/jessie.jpg' class='avatar_friend'>
</div>
.avatar_friend_wrapper {
position: absolute;
left: 0;
}
.avatar_friend {
width: 36px;
height: 36px;
position: relative;
z-index: 10;
border: 1px solid white;
}
What I recommend to do, would be to change your PHP loops so they generate something like this instead, where each movie item has its own wrapper.
With that you get a completely different control how to layout each movie info item based on screen size etc.
<div class='movie_div_2' number='2'>
<div id='descriptive_div_2' number='2'>
<i class='fa fa-caret-left' id='descriptive_caret_2' number='2'></i>
<a href='like.php?number=8&page=1'>
<a href='like.php?number=8&page=1&code=1&sorting=recent'>
<div class='like_button' number='2'> Like </div>
</a>
</a>
<span id='descriptive_div_text_2'> s </span>
<div id='files_left_2'> 1 Copy Left </div>
</div>
<a href='open.php?destination=movies/56c7ede7d3ed3108.44679765.mp4'>
<div class='movie_length' number='2'>
<div id='movie_length_text_2' number='2'> 2h 16m </div>
</div>
</a>
<a href='open.php?destination=movies/56c7ede7d3ed3108.44679765.mp4'>
<div class='movie_rating_2' number='2'>
<span id='movie_rating_text_2' number='2'> PG-13 </span>
</div>
</a>
<a href='open.php?destination=movies/56c7ede7d3ed3108.44679765.mp4'>
<img src='covers/star wars.jpg' class='movie_size' number='2'>
</a>
<div class='avatar_friend_wrapper'>
<img src='avatars/sam.jpg' class='avatar_friend'>
<img src='avatars/traek.jpg' class='avatar_friend'>
<img src='avatars/jessie.jpg' class='avatar_friend'>
</div>
</div>
I've been trying to get this list of buttons to have a scroll bar and scroll on table and smaller screens. I've add two divs for inner and outter to add overflow: hidden on outter and overflow: auto on inner. I can't seem to get this to work. Can anyone tell me what I'm missing?
Created a JSFiddle as asked and it works here. Maybe it is an issue with my SASS
http://jsfiddle.net/tuckerjoenz/p9afq4y9/
HTML
<div class="circle-outer">
<div class="circle-button-menu-container">
<ul class="field field-name-field-link-button field-type-entityreference field-label-hidden">
<li class="link-button">
<span property="dc:title" class="rdf-meta element-hidden"></span>
<a class="circle-button" href="#parents">
<div class="circle-image">
<img class="active" src="../images/Parent_2_0.jpg">
</div>
<div class="button-title">Parents</div>
</a>
</li>
<li class="link-button">
<span property="dc:title" class="rdf-meta element-hidden"></span>
<a class="circle-button" href="#kids">
<div class="circle-image">
<img class="active" src="../images/kids_JPEG_0.jpg">
</div>
<div class="button-title">Kids</div>
</a>
</li>
<li class="link-button">
<span property="dc:title" class="rdf-meta element-hidden"></span>
<a class="circle-button" href="#educators">
<div class="circle-image">
<img class="active" src="../images/Educator_JPEG_0.jpg">
</div>
<div class="button-title">Educators</div>
</a>
</li>
<li class="link-button">
<span property="dc:title" class="rdf-meta element-hidden"></span>
<a class="circle-button" href="#volunteer">
<div class="circle-image">
<img class="active" src="../images/volunteer_JPEG_0.jpg">
</div>
<div class="button-title">Volunteer</div>
</a>
</li>
</ul>
</div>
</div>
SASS
.circle-outer {
height: 350px;
display: block;
margin: 0 auto;
width: 100%;
margin-top: -200px;
padding: 100px 0px 0px;
overflow: hidden;
.circle-button-menu-container {
overflow: auto;
.field-name-field-link-button {
text-align: center;
display: block;
width: 1000%;
z-index: 100;
list-style-type: none;
position: absolute;
-webkit-transform-style: preserve-3d;
-ms-transform-style: preserve-3d;
transform-style: preserve-3d;
.link-button {
margin: 0px 46px 10px;
float: left;
text-decoration: none;
list-style: none;
position: relative;
display: block;
width: 170px;
a.circle-button {
display: block;
text-decoration: none;
.circle-image {
border: 10px solid white;
border-radius: 50%;
box-shadow: 0 4px 2px -2px gray;
overflow: hidden;
width: 170px;
height: 170px;
img {
display: block;
min-width: 100%;
min-height: 100%;
width: 100%;
}
&:hover, &:active {
border: 10px solid #b6b6b6;
box-shadow: none;
}
}
.button-title {
text-transform: uppercase;
color: #40749e;
font-weight: bold;
font-size: 1.3em;
margin-top: 10px;
}
&:before, &:after {
content: "";
position: absolute;
width: 0;
height: 0;
border-style: solid;
border-color: transparent;
border-bottom: 0;
}
&:before {
bottom: -33px;
left: 39%;
border-top-color: #b6b6b6;
border-width: 17px;
}
&:after {
bottom: -28px;
left: 40%;
border-top-color: #fff;
border-width: 15px;
}
}
}
}
}
}
Ok I figured this out. I had to remove the position: absolue on the .circle-button-menu-container class and it works! Thanks!
You could try overflow:scroll