diff options
author | 2020-08-04 16:27:53 -0700 | |
---|---|---|
committer | 2020-08-04 16:27:53 -0700 | |
commit | 3ec2f4a87d8509aed4f42975d8a03b75e78c5218 (patch) | |
tree | 96b172b7b49476567331ed4b0758383dfb7870a4 /assets/sass/components | |
parent | e37306449b036fc192ddee5db78d3a30197a8f21 (diff) | |
download | Portfolio-master.tar.gz Portfolio-master.tar.zst Portfolio-master.zip |
Diffstat (limited to 'assets/sass/components')
-rw-r--r-- | assets/sass/components/_actions.scss | 101 | ||||
-rw-r--r-- | assets/sass/components/_box.scss | 30 | ||||
-rw-r--r-- | assets/sass/components/_button.scss | 80 | ||||
-rw-r--r-- | assets/sass/components/_form.scss | 135 | ||||
-rw-r--r-- | assets/sass/components/_gallery.scss | 72 | ||||
-rw-r--r-- | assets/sass/components/_icon.scss | 33 | ||||
-rw-r--r-- | assets/sass/components/_icons.scss | 24 | ||||
-rw-r--r-- | assets/sass/components/_image.scss | 53 | ||||
-rw-r--r-- | assets/sass/components/_list.scss | 45 | ||||
-rw-r--r-- | assets/sass/components/_poptrox-popup.scss | 183 | ||||
-rw-r--r-- | assets/sass/components/_section.scss | 21 | ||||
-rw-r--r-- | assets/sass/components/_table.scss | 38 |
12 files changed, 815 insertions, 0 deletions
diff --git a/assets/sass/components/_actions.scss b/assets/sass/components/_actions.scss new file mode 100644 index 0000000..8dc340a --- /dev/null +++ b/assets/sass/components/_actions.scss @@ -0,0 +1,101 @@ +/// +/// Big Picture by Pixelarity +/// pixelarity.com | hello@pixelarity.com +/// License: pixelarity.com/license +/// + +/* Actions */ + + ul.actions { + @include vendor('display', 'flex'); + cursor: default; + list-style: none; + margin-left: (_size(element-margin) * -0.5); + padding-left: 0; + + li { + padding: 0 0 0 (_size(element-margin) * 0.5); + vertical-align: middle; + } + + &.special { + @include vendor('justify-content', 'center'); + width: 100%; + margin-left: 0; + + li { + &:first-child { + padding-left: 0; + } + } + } + + &.stacked { + @include vendor('flex-direction', 'column'); + margin-left: 0; + + li { + padding: (_size(element-margin) * 0.65) 0 0 0; + + &:first-child { + padding-top: 0; + } + } + } + + &.fit { + width: calc(100% + #{_size(element-margin) * 0.5}); + + li { + @include vendor('flex-grow', '1'); + @include vendor('flex-shrink', '1'); + width: 100%; + + > * { + width: 100%; + } + } + + &.stacked { + width: 100%; + } + } + + @include breakpoint('<=xsmall') { + &:not(.fixed) { + @include vendor('flex-direction', 'column'); + margin-left: 0; + width: 100% !important; + + li { + @include vendor('flex-grow', '1'); + @include vendor('flex-shrink', '1'); + padding: (_size(element-margin) * 0.5) 0 0 0; + text-align: center; + width: 100%; + + > * { + width: 100%; + } + + &:first-child { + padding-top: 0; + } + + input[type="submit"], + input[type="reset"], + input[type="button"], + button, + .button { + width: 100%; + + &.icon { + &:before { + margin-left: -0.5rem; + } + } + } + } + } + } + }
\ No newline at end of file diff --git a/assets/sass/components/_box.scss b/assets/sass/components/_box.scss new file mode 100644 index 0000000..077e1f9 --- /dev/null +++ b/assets/sass/components/_box.scss @@ -0,0 +1,30 @@ +/// +/// Big Picture by Pixelarity +/// pixelarity.com | hello@pixelarity.com +/// License: pixelarity.com/license +/// + +/* Box */ + + .box { + background: _palette(bg); + color: _palette(fg); + padding: 2em; + + > :last-child { + margin-bottom: 0; + } + + &.style2 { + padding: 3.5em 2.5em 3.5em 2.5em; + } + + @include breakpoint('<=small') { + padding: 1em; + + &.style2 { + padding: 1.5em 1.25em 1.5em 1.25em; + background-color: transparentize(_palette(bg), 0.1); + } + } + }
\ No newline at end of file diff --git a/assets/sass/components/_button.scss b/assets/sass/components/_button.scss new file mode 100644 index 0000000..9f2eb4d --- /dev/null +++ b/assets/sass/components/_button.scss @@ -0,0 +1,80 @@ +/// +/// Big Picture by Pixelarity +/// pixelarity.com | hello@pixelarity.com +/// License: pixelarity.com/license +/// + +/* Button */ + + input[type="button"], + input[type="submit"], + input[type="reset"], + .button, + button { + @include vendor('appearance', 'none'); + @include vendor('transition', 'background-color #{_duration(transition)} ease-in-out'); + background-color: _palette(accent1, bg); + border: 0; + border-radius: 3.5em; + color: _palette(accent1, fg); + cursor: pointer; + display: inline-block; + height: 3.5em; + line-height: 3.5em; + outline: 0; + padding: 0 2em 0 2em; + position: relative; + text-align: center; + text-decoration: none; + + &.down { + width: 5em; + height: 5em; + line-height: 4.5em; + padding: 0; + background-image: url('images/dark-arrow.svg'); + background-position: center center; + background-repeat: no-repeat; + text-indent: -10em; + overflow: hidden; + + &.anchored { + bottom: 0; + border-bottom: 0; + border-radius: 3em 3em 0 0; + height: 4.5em; + margin-left: -2.5em; + } + } + + &.anchored { + position: absolute; + left: 50%; + } + + &:hover { + background-color: lighten(_palette(accent1, bg), 5); + } + + &:active { + background-color: darken(_palette(accent1, bg), 5); + } + + &.style2 { + background-color: transparent; + border: solid 2px _palette(border); + color: inherit; + + &:hover { + background-color: transparentize(_palette(border), 0.75); + } + + &:active { + background-color: transparentize(_palette(border), 0.625); + } + + &.down { + background-image: url('images/arrow.svg'); + } + } + }
\ No newline at end of file diff --git a/assets/sass/components/_form.scss b/assets/sass/components/_form.scss new file mode 100644 index 0000000..301e203 --- /dev/null +++ b/assets/sass/components/_form.scss @@ -0,0 +1,135 @@ +/// +/// Big Picture by Pixelarity +/// pixelarity.com | hello@pixelarity.com +/// License: pixelarity.com/license +/// + +/* Form */ + + form { + margin: 0 0 _size(element-margin) 0; + + > :last-child { + margin-bottom: 0; + } + + > .fields { + $gutter: (_size(element-margin) * 0.75); + + @include vendor('display', 'flex'); + @include vendor('flex-wrap', 'wrap'); + width: calc(100% + #{$gutter * 2}); + margin: ($gutter * -1) 0 _size(element-margin) ($gutter * -1); + + > .field { + @include vendor('flex-grow', '0'); + @include vendor('flex-shrink', '0'); + padding: $gutter 0 0 $gutter; + width: calc(100% - #{$gutter * 1}); + + &.half { + width: calc(50% - #{$gutter * 0.5}); + } + + &.third { + width: calc(#{100% / 3} - #{$gutter * (1 / 3)}); + } + + &.quarter { + width: calc(25% - #{$gutter * 0.25}); + } + } + } + + @include breakpoint('<=xsmall') { + > .fields { + $gutter: (_size(element-margin) * 0.5); + + width: calc(100% + #{$gutter * 2}); + margin: ($gutter * -1) 0 _size(element-margin) ($gutter * -1); + + > .field { + padding: $gutter 0 0 $gutter; + width: calc(100% - #{$gutter * 1}); + + &.half { + width: calc(100% - #{$gutter * 1}); + } + + &.third { + width: calc(100% - #{$gutter * 1}); + } + + &.quarter { + width: calc(100% - #{$gutter * 1}); + } + } + } + } + } + + label { + display: block; + } + + input[type="text"], + input[type="password"], + input[type="email"], + input[type="tel"], + input[type="search"], + input[type="url"], + select, + textarea { + @include vendor('appearance', 'none'); + @include vendor('transition', ( + 'border-color #{_duration(transition)} ease-in-out', + 'color #{_duration(transition)} ease-in-out' + )); + color: _palette(fg); + display: block; + width: 100%; + padding: 0.65em 0.75em; + background: none; + border: solid 2px _palette(border); + color: inherit; + border-radius: 0.5em; + outline: none; + + &:focus { + border-color: _palette(accent2, bg); + } + } + + input[type="text"], + input[type="password"], + input[type="email"], + input[type="tel"], + input[type="search"], + input[type="url"], + select { + line-height: 1.35em; + } + + textarea { + min-height: 8em; + } + + ::-moz-focus-inner { + border: 0; + } + + ::-webkit-input-placeholder { + opacity: 0.375; + } + + :-moz-placeholder { + opacity: 0.375; + } + + ::-moz-placeholder { + opacity: 0.375; + } + + :-ms-input-placeholder { + opacity: 0.375; + }
\ No newline at end of file diff --git a/assets/sass/components/_gallery.scss b/assets/sass/components/_gallery.scss new file mode 100644 index 0000000..27d4e84 --- /dev/null +++ b/assets/sass/components/_gallery.scss @@ -0,0 +1,72 @@ +/// +/// Big Picture by Pixelarity +/// pixelarity.com | hello@pixelarity.com +/// License: pixelarity.com/license +/// + +/* Gallery */ + + .gallery { + @include vendor('display', 'flex'); + @include vendor('flex-wrap', 'wrap'); + width: 45em; + max-width: 100%; + margin: 0 auto _size(element-margin) auto; + + article { + @include vendor('transition', ( + 'transform 1s ease', + 'opacity 1s ease' + )); + @include vendor('transform', 'translateX(0)'); + width: 50%; + position: relative; + opacity: 1.0; + + .image { + margin: 0; + display: block; + } + + @for $i from 1 through 23 { + &:nth-last-child(#{$i}n) { + @include vendor('transition-delay', '#{(0.05s * $i)}'); + } + + &:nth-last-child(#{$i + 1}n) { + @include vendor('transition-delay', '#{(0.05s * $i)}'); + } + } + } + + &.inactive { + article { + opacity: 0; + + &.from-left { + @include vendor('transform', 'translateX(-14em)'); + } + + &.from-right { + @include vendor('transform', 'translateX(14em)'); + } + + &.from-top { + @include vendor('transform', 'translateY(-7em)'); + } + + &.from-bottom { + @include vendor('transform', 'translateY(7em)'); + } + } + } + + @include breakpoint('<=xsmall') { + @include vendor('flex-wrap', 'nowrap'); + @include vendor('flex-direction', 'column'); + + article { + width: 100%; + } + } + }
\ No newline at end of file diff --git a/assets/sass/components/_icon.scss b/assets/sass/components/_icon.scss new file mode 100644 index 0000000..b4fac9b --- /dev/null +++ b/assets/sass/components/_icon.scss @@ -0,0 +1,33 @@ +/// +/// Big Picture by Pixelarity +/// pixelarity.com | hello@pixelarity.com +/// License: pixelarity.com/license +/// + +/* Icon */ + + .icon { + @include icon; + position: relative; + text-decoration: none; + + &:before { + line-height: inherit; + } + + > .label { + display: none; + } + + &.solid { + &:before { + font-weight: 900; + } + } + + &.brands { + &:before { + font-family: 'Font Awesome 5 Brands'; + } + } + }
\ No newline at end of file diff --git a/assets/sass/components/_icons.scss b/assets/sass/components/_icons.scss new file mode 100644 index 0000000..01150a8 --- /dev/null +++ b/assets/sass/components/_icons.scss @@ -0,0 +1,24 @@ +/// +/// Big Picture by Pixelarity +/// pixelarity.com | hello@pixelarity.com +/// License: pixelarity.com/license +/// + +/* Icons */ + + ul.icons { + cursor: default; + + li { + display: inline-block; + } + + a { + display: inline-block; + width: 2em; + height: 2em; + line-height: 2em; + text-align: center; + border: 0; + } + }
\ No newline at end of file diff --git a/assets/sass/components/_image.scss b/assets/sass/components/_image.scss new file mode 100644 index 0000000..df4c91b --- /dev/null +++ b/assets/sass/components/_image.scss @@ -0,0 +1,53 @@ +/// +/// Big Picture by Pixelarity +/// pixelarity.com | hello@pixelarity.com +/// License: pixelarity.com/license +/// + +/* Image */ + + .image { + position: relative; + display: inline-block; + + &:before { + content: ''; + position: absolute; + left: 0; + top: 0; + width: 100%; + height: 100%; + background: url('images/overlay.png'); + } + + img { + display: block; + width: 100%; + } + + &.featured { + display: block; + width: 100%; + margin: 0 0 2em 0; + } + + &.fit { + display: block; + width: 100%; + } + + &.left { + float: left; + margin: 0 2em 2em 0; + } + + &.centered { + display: block; + margin: 0 0 2em 0; + + img { + margin: 0 auto; + width: auto; + } + } + }
\ No newline at end of file diff --git a/assets/sass/components/_list.scss b/assets/sass/components/_list.scss new file mode 100644 index 0000000..445c472 --- /dev/null +++ b/assets/sass/components/_list.scss @@ -0,0 +1,45 @@ +/// +/// Big Picture by Pixelarity +/// pixelarity.com | hello@pixelarity.com +/// License: pixelarity.com/license +/// + +/* List */ + + ul { + &.default { + list-style: disc; + padding-left: 1em; + + li { + padding-left: 0.5em; + } + } + + &.menu { + cursor: default; + + li { + display: inline-block; + line-height: 1em; + border-left: solid 1px _palette(border); + padding: 0 0 0 0.5em; + margin: 0 0 0 0.5em; + + &:first-child { + border-left: 0; + padding-left: 0; + margin-left: 0; + } + } + } + } + + ol.default { + list-style: decimal; + padding-left: 1.25em; + + li { + padding-left: 0.25em; + } + }
\ No newline at end of file diff --git a/assets/sass/components/_poptrox-popup.scss b/assets/sass/components/_poptrox-popup.scss new file mode 100644 index 0000000..dd883fd --- /dev/null +++ b/assets/sass/components/_poptrox-popup.scss @@ -0,0 +1,183 @@ +/// +/// Big Picture by Pixelarity +/// pixelarity.com | hello@pixelarity.com +/// License: pixelarity.com/license +/// + +/* Poptrox */ + + .poptrox-popup { + @include vendor('box-sizing', 'content-box'); + background: #fff; + padding-bottom: 3em; + box-shadow: 0 0.1em 0.15em 0 rgba(0, 0, 0, 0.15); + + .loader { + position: absolute; + top: 50%; + left: 50%; + margin: -1em 0 0 -1em; + width: 2em; + height: 2em; + display: block; + font-size: 2em; + + &:before { + @include vendor('animation', 'spinner-rotate 0.75s infinite linear !important'); + -moz-osx-font-smoothing: grayscale; + -webkit-font-smoothing: antialiased; + font-family: FontAwesome; + font-style: normal; + font-weight: normal; + text-transform: none !important; + color: _palette(border); + content: '\f1ce'; + cursor: default; + display: block; + height: 2em; + left: 0; + line-height: 2em; + position: absolute; + text-align: center; + top: 0; + width: 2em; + } + } + + .caption { + position: absolute; + bottom: 0; + left: 0; + background: _palette(bg); + width: 100%; + height: 3em; + line-height: 2.8em; + text-align: center; + cursor: default; + z-index: 1; + font-size: 0.9em; + } + + .nav-next, + .nav-previous { + @include vendor('transition', 'opacity #{_duration(transition)} ease-in-out'); + position: absolute; + top: 0; + width: 50%; + height: 100%; + opacity: 0; + cursor: pointer; + background: rgba(0, 0, 0, 0.01); + -webkit-tap-highlight-color: rgba(255, 255, 255, 0); + } + + .nav-next:before, + .nav-previous:before { + content: ''; + position: absolute; + width: 96px; + height: 64px; + background: url('images/poptrox-nav.svg'); + top: calc(50% - 1.5em); + margin: -32px 0 0 0; + } + + &:hover { + .nav-next, + .nav-previous { + opacity: 0.5; + } + + .nav-next:hover, + .nav-previous:hover { + opacity: 1.0; + } + } + + .nav-previous:before { + @include vendor('transform', 'scaleX(-1)'); + -ms-filter: "FlipH"; + filter: FlipH; + } + + .nav-next { + right: 0; + + &:before { + right: 0; + } + } + + .nav-previous { + left: 0; + + &:before { + left: 0; + } + } + + .closer { + @include vendor('transition', 'opacity #{_duration(transition)} ease-in-out'); + position: absolute; + top: 0; + right: 0; + width: 64px; + height: 64px; + text-indent: -9999px; + z-index: 2; + opacity: 0; + -webkit-tap-highlight-color: rgba(255, 255, 255, 0); + + &:before { + content: ''; + display: block; + position: absolute; + right: 16px; + top: 16px; + width: 40px; + height: 40px; + border-radius: 100%; + box-shadow: inset 0 0 0 2px #fff; + background: url('images/poptrox-closer.svg') center center; + color: _palette(bg) !important; + } + } + + &:hover { + .closer { + opacity: 0.5; + + &:hover { + opacity: 1.0; + } + } + } + + body.is-touch & { + .nav-next, + .nav-previous, + .closer { + opacity: 1.0 !important; + } + } + + @include breakpoint('<=small') { + .nav-next:before, + .nav-previous:before { + width: 48px; + height: 32px; + background-size: contain; + margin: -16px 0 0 0; + } + + .closer:before { + right: 12px; + top: 12px; + width: 20px; + height: 20px; + box-shadow: inset 0 0 0 1px #fff; + background-size: contain; + opacity: 0.65; + } + } + }
\ No newline at end of file diff --git a/assets/sass/components/_section.scss b/assets/sass/components/_section.scss new file mode 100644 index 0000000..d8ba58b --- /dev/null +++ b/assets/sass/components/_section.scss @@ -0,0 +1,21 @@ +/// +/// Big Picture by Pixelarity +/// pixelarity.com | hello@pixelarity.com +/// License: pixelarity.com/license +/// + +/* Sections/Article */ + + header { + margin-bottom: 1em; + + p { + display: block; + margin: 1em 0 0 0; + padding: 0 0 0.5em 0; + } + } + + footer { + margin-top: 2em; + }
\ No newline at end of file diff --git a/assets/sass/components/_table.scss b/assets/sass/components/_table.scss new file mode 100644 index 0000000..1d00ab4 --- /dev/null +++ b/assets/sass/components/_table.scss @@ -0,0 +1,38 @@ +/// +/// Big Picture by Pixelarity +/// pixelarity.com | hello@pixelarity.com +/// License: pixelarity.com/license +/// + +/* Table */ + + table { + width: 100%; + + &.default { + width: 100%; + + tbody tr:nth-child(2n+2) { + background: transparentize(_palette(border), 0.5); + } + + td { + padding: 0.5em 1em 0.5em 1em; + } + + th { + text-align: left; + font-weight: 900; + padding: 0.5em 1em 0.5em 1em; + } + + thead { + background: _palette(fg); + color: _palette(bg); + } + + tfoot { + background: _palette(border); + } + } + }
\ No newline at end of file |