Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
12 changes: 7 additions & 5 deletions docs/app/styles/_base.scss
Original file line number Diff line number Diff line change
@@ -1,3 +1,5 @@
@use 'variables';

* {
box-sizing: border-box;
}
Expand All @@ -16,12 +18,12 @@ html {
}

body {
color: $text-color;
color: variables.$text-color;
}

a {
text-decoration: none;
color: $link-color;
color: variables.$link-color;
}

img,
Expand All @@ -39,7 +41,7 @@ h6 {
margin-bottom: 0.5rem;
font-weight: bold;
line-height: 1.25;
color: $headings-text-color;
color: variables.$headings-text-color;
text-rendering: optimizeLegibility;
}
h1 {
Expand Down Expand Up @@ -108,7 +110,7 @@ pre {
font-family: Menlo, Monaco, 'Courier New', monospace;
}
code {
color: $code-text-color;
color: variables.$code-text-color;
padding: 0.2em 0;
margin: 0;
font-size: 75%;
Expand All @@ -122,7 +124,7 @@ code {
}
}
pre {
max-width: calc(100vw - #{2 * $wrapper-padding});
max-width: calc(100vw - #{2 * variables.$wrapper-padding});
display: block;
margin-top: 0;
margin-bottom: 1rem;
Expand Down
6 changes: 4 additions & 2 deletions docs/app/styles/_utilities.scss
Original file line number Diff line number Diff line change
@@ -1,3 +1,5 @@
@use 'variables';

// Utility classes
.text-center {
text-align: center;
Expand All @@ -16,8 +18,8 @@
}
%wrapper {
max-width: 1024px; // not 960px because it's 2015
padding-left: $wrapper-padding;
padding-right: $wrapper-padding;
padding-left: variables.$wrapper-padding;
padding-right: variables.$wrapper-padding;
margin-left: auto;
margin-right: auto;
}
34 changes: 17 additions & 17 deletions docs/app/styles/app.scss
Original file line number Diff line number Diff line change
@@ -1,33 +1,33 @@
// Legacy demo
@use 'ember-power-select/scss/variables.scss';
@use 'ember-power-select/scss/variables.scss' as epsVariables;
@use 'ember-basic-dropdown';
@use 'ember-power-select';

@import 'variables';
@import 'base';
@import 'utilities';
@import 'layout';
@use 'variables';
@use 'base';
@use 'utilities';
@use 'layout';

// Components
@import 'components/main-header';
@import 'components/link-to-other-version';
@import 'components/main-footer';
@import 'components/index';
@import 'components/side-nav';
@import 'components/docs';
@import 'components/cookbook';
@import 'components/code-block';
@use 'components/main-header';
@use 'components/link-to-other-version';
@use 'components/main-footer';
@use 'components/index';
@use 'components/side-nav';
@use 'components/docs';
@use 'components/cookbook';
@use 'components/code-block';

// Docs
@import 'docs/code-example';
@include ember-code-example($brand-color);
@use 'docs/code-example';
@include code-example.ember-code-example(variables.$brand-color);

// Utility classes
.evenly-splitted {
> * {
margin-bottom: 1rem;
}
@media only screen and (min-width: $small-breakpoint) {
@media only screen and (min-width: variables.$small-breakpoint) {
display: flex;
> * {
padding: 0 5px;
Expand Down Expand Up @@ -396,7 +396,7 @@ $material-demo-line-height: 2.5;
0 2px 5px 0 rgba(0, 0, 0, 0.16),
0 2px 10px 0 rgba(0, 0, 0, 0.12);
.ember-power-select-options[role='listbox'] {
max-height: #{variables.$ember-power-select-number-of-visible-options *
max-height: #{epsVariables.$ember-power-select-number-of-visible-options *
$material-demo-line-height}em;
}
.ember-power-select-search-input {
Expand Down
2 changes: 2 additions & 0 deletions docs/app/styles/components/cookbook.scss
Original file line number Diff line number Diff line change
@@ -1,3 +1,5 @@
@use '../utilities';

// Cookbook
.cookbook {
@extend %wrapper;
Expand Down
11 changes: 7 additions & 4 deletions docs/app/styles/components/docs.scss
Original file line number Diff line number Diff line change
@@ -1,3 +1,6 @@
@use '../utilities';
@use '../variables';

// Docs
.docs {
@extend %wrapper;
Expand All @@ -19,7 +22,7 @@
}
.doc-page-nav-link-next,
.doc-page-nav-link-prev {
border: 1px solid $brand-color;
border: 1px solid variables.$brand-color;
padding: 0.2rem 0.5rem;
font-weight: 600;
border-radius: 4px;
Expand All @@ -34,15 +37,15 @@
.section-selector {
margin-bottom: 1rem;
}
@media only screen and (min-width: $medium-breakpoint) {
@media only screen and (min-width: variables.$medium-breakpoint) {
display: none;
}
}
.branded-graph {
color: $brand-color;
color: variables.$brand-color;
font-size: 38px;
.shape-element {
fill: $brand-color;
fill: variables.$brand-color;
}
}

Expand Down
18 changes: 11 additions & 7 deletions docs/app/styles/components/index.scss
Original file line number Diff line number Diff line change
@@ -1,12 +1,16 @@
@use '../utilities';
@use '../variables';

// Headline
.main-page-headline {
background: $brand-color linear-gradient($brand-color, $brand-color-brighter);
background: variables.$brand-color
linear-gradient(variables.$brand-color, variables.$brand-color-brighter);
height: 300px;
color: white;
display: flex;
align-items: center;
justify-content: center;
@media only screen and (max-width: $medium-breakpoint) {
@media only screen and (max-width: variables.$medium-breakpoint) {
height: 200px;
}
}
Expand All @@ -19,13 +23,13 @@
img {
vertical-align: top;
}
@media only screen and (max-width: $small-breakpoint) {
@media only screen and (max-width: variables.$small-breakpoint) {
font-size: 34px;
img {
height: 40px;
}
}
@media only screen and (min-width: $small-breakpoint) {
@media only screen and (min-width: variables.$small-breakpoint) {
font-size: 42px;
img {
height: 48px;
Expand All @@ -36,7 +40,7 @@
.selling-points {
@extend %wrapper;
display: flex;
@media only screen and (max-width: $small-breakpoint) {
@media only screen and (max-width: variables.$small-breakpoint) {
flex-direction: column;
}
}
Expand Down Expand Up @@ -64,7 +68,7 @@
}
}
.selling-point-text {
color: $gray;
color: variables.$gray;
display: flex;
flex-direction: column;
justify-content: center;
Expand All @@ -81,7 +85,7 @@
.get-started-button {
margin-top: 2rem;
margin-bottom: 2rem;
border: 1px solid $brand-color;
border: 1px solid variables.$brand-color;
border-radius: 4px;
padding: 0.5rem 2rem;
display: inline-block;
Expand Down
22 changes: 13 additions & 9 deletions docs/app/styles/components/main-footer.scss
Original file line number Diff line number Diff line change
@@ -1,20 +1,24 @@
@use 'sass:color';
@use '../utilities';
@use '../variables';

// Main footer
.main-footer {
color: $gray;
background-color: $light-gray;
color: variables.$gray;
background-color: variables.$light-gray;
border-top: 1px solid #bbb;
padding-left: 1rem;
padding-right: 1rem;

a {
color: $link-gray;
color: variables.$link-gray;
}
}
.main-footer-content {
@extend %wrapper;
padding: 1rem 0;
}
@media only screen and (min-width: $medium-breakpoint) {
@media only screen and (min-width: variables.$medium-breakpoint) {
.icons-attributions {
float: right;
}
Expand All @@ -24,15 +28,15 @@
border-radius: 4px;
padding: 5px 10px;
text-align: center;
background-color: $brand-color;
background-color: variables.$brand-color;
color: white;
border: 1px solid darken($brand-color, 12%);
box-shadow: 0 2px darken($brand-color, 18%);
border: 1px solid color.adjust(variables.$brand-color, $lightness: -12%);
box-shadow: 0 2px color.adjust(variables.$brand-color, $lightness: -18%);
&:hover {
background-color: darken($brand-color, 5%);
background-color: color.adjust(variables.$brand-color, $lightness: -5%);
}
}
@media only screen and (min-width: $small-breakpoint) {
@media only screen and (min-width: variables.$small-breakpoint) {
.contribute-call-to-action {
float: right;
}
Expand Down
15 changes: 9 additions & 6 deletions docs/app/styles/components/main-header.scss
Original file line number Diff line number Diff line change
@@ -1,6 +1,9 @@
@use '../utilities';
@use '../variables';

// main header
.main-header {
background-color: $brand-color;
background-color: variables.$brand-color;
color: white;
}
.main-header-nav {
Expand Down Expand Up @@ -58,7 +61,7 @@ $almost-white: #fff2f2;
font-size: 24px;
border: 2px solid $almost-white;
border-top: none;
background: $brand-color linear-gradient(#e61a1a, #eb3e3e);
background: variables.$brand-color linear-gradient(#e61a1a, #eb3e3e);
.ember-power-select-option {
font-weight: 600;
}
Expand All @@ -71,10 +74,10 @@ $almost-white: #fff2f2;
}
.ember-power-select-option[aria-current='true'] {
background-color: $almost-white;
color: $brand-color;
color: variables.$brand-color;
}
}
@media only screen and (max-width: $small-breakpoint) {
@media only screen and (max-width: variables.$small-breakpoint) {
.main-header {
line-height: 44px;
}
Expand All @@ -87,7 +90,7 @@ $almost-white: #fff2f2;
background-color: rgba(black, 0.2);
}
}
@media only screen and (min-width: $small-breakpoint) {
@media only screen and (min-width: variables.$small-breakpoint) {
.main-header {
line-height: 66px;
}
Expand All @@ -98,6 +101,6 @@ $almost-white: #fff2f2;
}
.main-header-nav-link.active {
background-color: white;
color: $brand-color;
color: variables.$brand-color;
}
}
10 changes: 6 additions & 4 deletions docs/app/styles/components/side-nav.scss
Original file line number Diff line number Diff line change
@@ -1,10 +1,12 @@
@use '../variables';

$side-nav-color: #343434;
.side-nav {
width: 200px;
color: $side-nav-color;
flex: 0 0 25%;
margin-right: 2rem;
@media only screen and (max-width: $medium-breakpoint) {
@media only screen and (max-width: variables.$medium-breakpoint) {
display: none;
}
}
Expand All @@ -30,11 +32,11 @@ $side-nav-color: #343434;
font-size: 80%;
}
&.active {
border-left: 3px solid $brand-color;
color: $brand-color;
border-left: 3px solid variables.$brand-color;
color: variables.$brand-color;
padding-left: 16px - 3px;
.beta-label {
background-color: $brand-color;
background-color: variables.$brand-color;
}
}
}