Initial version
This commit is contained in:
295
demos/responsive-pagination/style.css
Normal file
295
demos/responsive-pagination/style.css
Normal file
@@ -0,0 +1,295 @@
|
||||
html,
|
||||
body {
|
||||
height: 100%;
|
||||
background: #f2f2f2;
|
||||
}
|
||||
|
||||
*,
|
||||
*:before,
|
||||
*:after {
|
||||
box-sizing: border-box;
|
||||
}
|
||||
|
||||
/* Controls
|
||||
---------------------------------------------------------------------- */
|
||||
|
||||
.controls {
|
||||
padding: 1rem;
|
||||
background: #333;
|
||||
font-size: 0.1px;
|
||||
}
|
||||
|
||||
.control {
|
||||
position: relative;
|
||||
display: inline-block;
|
||||
width: 2.7rem;
|
||||
height: 2.7rem;
|
||||
background: #444;
|
||||
cursor: pointer;
|
||||
font-size: 0.1px;
|
||||
color: white;
|
||||
transition: background 150ms;
|
||||
}
|
||||
|
||||
.control:hover {
|
||||
background: #3f3f3f;
|
||||
}
|
||||
|
||||
.control[data-filter]:after {
|
||||
content: '';
|
||||
position: absolute;
|
||||
width: 10px;
|
||||
height: 10px;
|
||||
top: calc(50% - 6px);
|
||||
left: calc(50% - 6px);
|
||||
border: 2px solid currentColor;
|
||||
border-radius: 2px;
|
||||
background: currentColor;
|
||||
transition: background-color 150ms, border-color 150ms;
|
||||
}
|
||||
|
||||
.control[data-sort]:after {
|
||||
content: '';
|
||||
position: absolute;
|
||||
width: 10px;
|
||||
height: 10px;
|
||||
border-top: 2px solid;
|
||||
border-left: 2px solid;
|
||||
top: calc(50% - 6px);
|
||||
left: calc(50% - 6px);
|
||||
transform: translateY(1px) rotate(45deg);
|
||||
}
|
||||
|
||||
.control[data-sort*=":desc"]:after {
|
||||
transform: translateY(-4px) rotate(-135deg);
|
||||
}
|
||||
|
||||
.mixitup-control-active {
|
||||
background: #393939;
|
||||
}
|
||||
|
||||
.mixitup-control-active[data-filter]:after {
|
||||
background: transparent;
|
||||
}
|
||||
|
||||
.control:first-of-type {
|
||||
border-radius: 3px 0 0 3px;
|
||||
}
|
||||
|
||||
.control:last-of-type {
|
||||
border-radius: 0 3px 3px 0;
|
||||
}
|
||||
|
||||
.control[data-filter] + .control[data-sort] {
|
||||
margin-left: .75rem;
|
||||
}
|
||||
|
||||
.control[data-filter=".green"] {
|
||||
color: #91e6c7;
|
||||
}
|
||||
|
||||
.control[data-filter=".blue"] {
|
||||
color: #5ecdde;
|
||||
}
|
||||
|
||||
.control[data-filter=".pink"] {
|
||||
color: #d595aa;
|
||||
}
|
||||
|
||||
.control[data-filter="none"] {
|
||||
color: #2f2f2f;
|
||||
}
|
||||
|
||||
/* Pagination Controls
|
||||
---------------------------------------------------------------------- */
|
||||
|
||||
.controls-pagination {
|
||||
padding: 1rem;
|
||||
font-size: 0.1px;
|
||||
text-align: justify;
|
||||
}
|
||||
|
||||
.controls-pagination:after {
|
||||
content: '';
|
||||
display: inline-block;
|
||||
width: 100%;
|
||||
}
|
||||
|
||||
.mixitup-page-list,
|
||||
.mixitup-page-stats {
|
||||
display: inline-block;
|
||||
vertical-align: middle;
|
||||
}
|
||||
|
||||
.mixitup-page-list {
|
||||
text-align: left;
|
||||
}
|
||||
|
||||
.mixitup-page-stats {
|
||||
font-size: .9rem;
|
||||
color: #333;
|
||||
font-weight: bold;
|
||||
font-family: 'helvetica', arial, sans-serif;
|
||||
}
|
||||
|
||||
.mixitup-control {
|
||||
position: relative;
|
||||
display: inline-block;
|
||||
text-align: center;
|
||||
width: 2.7rem;
|
||||
height: 2.7rem;
|
||||
background: #fff;
|
||||
border-top: 3px solid transparent;
|
||||
border-bottom: 3px solid transparent;
|
||||
margin-right: 1px;
|
||||
cursor: pointer;
|
||||
font-size: .9rem;
|
||||
color: #333;
|
||||
font-weight: bold;
|
||||
font-family: 'helvetica', arial, sans-serif;
|
||||
transition: color 150ms, border-color 150ms;
|
||||
vertical-align: middle;
|
||||
}
|
||||
|
||||
.mixitup-control:first-child {
|
||||
border-radius: 3px 0 0 3px;
|
||||
}
|
||||
|
||||
.mixitup-control:last-child {
|
||||
border-radius: 0 3px 3px 0;
|
||||
}
|
||||
|
||||
.mixitup-control:not(.mixitup-control-active):hover {
|
||||
color: #91e6c7;
|
||||
}
|
||||
|
||||
.mixitup-control-active {
|
||||
border-bottom-color: #91e6c7;
|
||||
cursor: default;
|
||||
}
|
||||
|
||||
.mixitup-control:disabled {
|
||||
background: #eaeaea;
|
||||
color: #aaa;
|
||||
cursor: default;
|
||||
}
|
||||
|
||||
.mixitup-control-truncation-marker {
|
||||
background: transparent;
|
||||
pointer-events: none;
|
||||
line-height: 2.2em;
|
||||
}
|
||||
|
||||
/* Container
|
||||
---------------------------------------------------------------------- */
|
||||
|
||||
.container {
|
||||
padding: 1rem;
|
||||
text-align: justify;
|
||||
font-size: 0.1px;
|
||||
}
|
||||
|
||||
.container:after {
|
||||
content: '';
|
||||
display: inline-block;
|
||||
width: 100%;
|
||||
}
|
||||
|
||||
/* Target Elements
|
||||
---------------------------------------------------------------------- */
|
||||
|
||||
.mix,
|
||||
.gap {
|
||||
display: inline-block;
|
||||
vertical-align: top;
|
||||
}
|
||||
|
||||
.mix {
|
||||
background: #fff;
|
||||
border-top: .5rem solid currentColor;
|
||||
border-radius: 2px;
|
||||
margin-bottom: 1rem;
|
||||
position: relative;
|
||||
}
|
||||
|
||||
.mix:before {
|
||||
content: '';
|
||||
display: inline-block;
|
||||
padding-top: 56.25%;
|
||||
}
|
||||
|
||||
.mix.green {
|
||||
color: #91e6c7;
|
||||
}
|
||||
|
||||
.mix.pink {
|
||||
color: #d595aa;
|
||||
}
|
||||
|
||||
.mix.blue {
|
||||
color: #5ecdde;
|
||||
}
|
||||
|
||||
/* Grid Breakpoints & Column Counts
|
||||
---------------------------------------------------------------------- */
|
||||
|
||||
/* 2 Columns */
|
||||
|
||||
.mix,
|
||||
.gap {
|
||||
width: calc(100%/2 - (((2 - 1) * 1rem) / 2));
|
||||
}
|
||||
|
||||
/**
|
||||
* NB: The `font-size` property on the hidden `.column-counter` element is set to
|
||||
* a value representing the number of columns. We will parse this value on init and
|
||||
* on resize, which avoids the need to track viewport width and define
|
||||
* breakpoints in our JavaScript which can also be unreliable when scrollbars
|
||||
* are added/removed. Any CSS property which supports a numeric value could
|
||||
* be used instead of font-size.
|
||||
*/
|
||||
|
||||
.column-counter {
|
||||
font-size: 2px;
|
||||
}
|
||||
|
||||
/* 3 Columns */
|
||||
|
||||
@media screen and (min-width: 541px) {
|
||||
.mix,
|
||||
.gap {
|
||||
width: calc(100%/3 - (((3 - 1) * 1rem) / 3));
|
||||
}
|
||||
|
||||
.column-counter {
|
||||
font-size: 3px;
|
||||
}
|
||||
}
|
||||
|
||||
/* 4 Columns */
|
||||
|
||||
@media screen and (min-width: 961px) {
|
||||
.mix,
|
||||
.gap {
|
||||
width: calc(100%/4 - (((4 - 1) * 1rem) / 4));
|
||||
}
|
||||
|
||||
.column-counter {
|
||||
font-size: 4px;
|
||||
}
|
||||
}
|
||||
|
||||
/* 5 Columns */
|
||||
|
||||
@media screen and (min-width: 1281px) {
|
||||
.mix,
|
||||
.gap {
|
||||
width: calc(100%/5 - (((5 - 1) * 1rem) / 5));
|
||||
}
|
||||
|
||||
.column-counter {
|
||||
font-size: 5px;
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user