Skip to content

Commit

Permalink
✨ feat(button.css): Fixed up quirks
Browse files Browse the repository at this point in the history
- Fixed issue with header dropdown having incorrect positioning
- Removed side padding for .row
- more predictable behavior with button being inline-flex
  • Loading branch information
Spiderpig86 committed Jun 7, 2020
1 parent ee552dc commit fcf11e8
Show file tree
Hide file tree
Showing 9 changed files with 570 additions and 346 deletions.
303 changes: 189 additions & 114 deletions dist/cirrus-core.css

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion dist/cirrus-core.min.css

Large diffs are not rendered by default.

305 changes: 190 additions & 115 deletions dist/cirrus.css

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion dist/cirrus.min.css

Large diffs are not rendered by default.

213 changes: 141 additions & 72 deletions src/core/button.css

Large diffs are not rendered by default.

4 changes: 4 additions & 0 deletions src/core/header.css
Original file line number Diff line number Diff line change
Expand Up @@ -77,6 +77,10 @@
transition: all 0.3s;
}

.nav-item.has-sub {
position: relative;
}

/* Allow the user to scroll through navbar items if it exceeds nav-left, nav-center, or nav-right widths */
.nav-overflow-x {
-webkit-box-pack: inherit;
Expand Down
63 changes: 32 additions & 31 deletions src/core/layout.css
Original file line number Diff line number Diff line change
Expand Up @@ -37,52 +37,53 @@ section {

/* This works well with spans and maybe even hr */
.divider {
border-top: .05rem solid rgba(173, 173, 173, 0.5);
height: .1rem;
border-top: 0.05rem solid rgba(173, 173, 173, 0.5);
height: 0.1rem;
margin: 1.8rem 0 1.6rem;
}

.divider[data-content] {
margin: .8rem 0;
margin: 0.8rem 0;
}

.divider--v[data-content] {
display: block;
padding: .8rem;
padding: 0.8rem;
}

.divider--v::before {
border-left: .05rem solid rgba(173, 173, 173, 0.5);
bottom: .4rem;
content: "";
border-left: 0.05rem solid rgba(173, 173, 173, 0.5);
bottom: 0.4rem;
content: '';
display: block;
left: 50%;
position: absolute;
top: 0;
transform: translateX(-50%);
}

.divider--v[data-content]::after, .divider[data-content]::after {
.divider--v[data-content]::after,
.divider[data-content]::after {
background: #fff;
color: #bcc3ce;
content: attr(data-content);
left: 50%;
display: inline-block;
padding: 0 .4rem;
padding: 0 0.4rem;
position: absolute;
transform: translate(-50%,-50%);
transform: translate(-50%, -50%);
top: 50%;
}

.divider--v[data-content] {
left: 50%;
padding: .2rem 0;
padding: 0.2rem 0;
position: absolute;
top: 50%;
transform: translate(-50%,-50%);
transform: translate(-50%, -50%);
}

/* Removed 0.5.5 */
/* Removed 0.5.5 */
/* .divider-short {
max-width: 15rem;
width: 100%;
Expand Down Expand Up @@ -147,12 +148,13 @@ section {
flex: 1;
/* max-width: 100%; */
flex-wrap: wrap;
padding: 0.5rem;
padding: 0.5rem 0;
}

.r { /* Legacy row pre 0.5.5 */
.r {
/* Legacy row pre 0.5.5 */
max-width: 100%;
padding: .5rem;
padding: 0.5rem;
}

.row.row--no-wrap {
Expand All @@ -163,7 +165,7 @@ section {
}

.row::after {
content: "";
content: '';
clear: both;
display: table;
}
Expand All @@ -172,7 +174,7 @@ section {
.row .col {
display: block;
flex: 1;
padding: .15rem .75rem;
padding: 0.15rem 0.75rem;
}

.row .col-1 {
Expand Down Expand Up @@ -329,15 +331,15 @@ section {
} */

/* Some offset values */
.row [class^="col-"],
.row [class*=" col-"] {
.row [class^='col-'],
.row [class*=' col-'] {
float: left; /* Keeps the elements in 1 row */
padding: 0 0.5rem;
}

/* Columns without the spacing */
.row.no-space [class^="col-"],
.row.no-space [class*=" col-"] {
.row.no-space [class^='col-'],
.row.no-space [class*=' col-'] {
padding: 0;
}

Expand Down Expand Up @@ -534,7 +536,6 @@ section {
}

@media screen and (min-width: 769px) {

.row {
display: flex;
}
Expand All @@ -556,25 +557,25 @@ section {

/* MOBILE */
@media screen and (max-width: 768px) {
.container {
width: 100%;
}

.row {
margin-top: 0;
}

.row [class^="col-"]:not(.ignore-screen),
.row [class*=" col-"]:not(.ignore-screen) {
.row [class^='col-']:not(.ignore-screen),
.row [class*=' col-']:not(.ignore-screen) {
/* Remove the grid structure for smaller screens */
width: 100%;
margin-left: 0;
padding: 0;
}

/* .fluid-container { DEPRECATED 0.5.5
display: inherit;
} */

/* Dividers for mobile layout */
.divided > .row [class^="col-"],
.divided > .row [class*=" col-"] {
.divided > .row [class^='col-'],
.divided > .row [class*=' col-'] {
box-shadow: 0 -1px 0 0 rgba(34, 36, 38, 0.15);
}

Expand Down
14 changes: 12 additions & 2 deletions src/core/links.css
Original file line number Diff line number Diff line change
Expand Up @@ -33,10 +33,20 @@ a.underline {
text-decoration: underline;
}

p a, h1 a, h2 a, h3 a, h4 a, h5 a, h6 a, blockquote a, article a {
p a,
h1 a,
h2 a,
h3 a,
h4 a,
h5 a,
h6 a,
blockquote a,
article a {
display: inline;
}

a .btn, a button {
a .btn,
a button,
[type='submit'] a {
margin-bottom: 0; /* Remove random excess space */
}
10 changes: 0 additions & 10 deletions src/core/theme.css
Original file line number Diff line number Diff line change
Expand Up @@ -91,16 +91,6 @@
--yellow-700: #7C4D09;
--yellow-800: #6C3E0C;
--yellow-900: #5D320F;

--green-100: #E1F7EB;
--green-200: #C2ECD6;
--green-300: #98D9B7;
--green-400: #64C192;
--green-500: #44A675;
--green-600: #33855D;
--green-700: #27684A;
--green-800: #275440;
--green-900: #234535;

--green-100: #E1F7EB;
--green-200: #C2ECD6;
Expand Down

0 comments on commit fcf11e8

Please sign in to comment.