Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat(select): Eva style #1391

Merged
merged 62 commits into from
Apr 24, 2019
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
62 commits
Select commit Hold shift + click to select a range
c6ca022
feat(select): use common shape, size and status types
yggg Apr 15, 2019
a82fd74
feat(select): use nb-icon for arrow
yggg Apr 15, 2019
4e85e95
refactor(select): remove named inputs
yggg Apr 15, 2019
5e885fd
fix(select): import icon module
yggg Apr 15, 2019
33ef96a
refactor(select): boolean attributes for appearance, width and multiple
yggg Apr 15, 2019
4ddee44
refactor(option): remove named input
yggg Apr 15, 2019
f0f99c7
feat(select): add missing 'filled' appearance input
yggg Apr 15, 2019
e7cc521
refactor(select): move open class to host
yggg Apr 15, 2019
1f548c1
refactor(select): use native button
yggg Apr 15, 2019
6c73390
refactor(select): remove unnecessary undefined selection model check
yggg Apr 15, 2019
9fc9b46
refactor(select): use ngIfElse syntax
yggg Apr 15, 2019
06a5454
refactor(option): change disabled class to attribute
yggg Apr 15, 2019
d7f0242
refactor(option): make fields protected
yggg Apr 15, 2019
199e7d9
feat(select): add size, shape and status class bindings
yggg Apr 15, 2019
d7d0d1f
refactor(select): use ngIfElse syntax
yggg Apr 15, 2019
dc69928
fix(select): update button selector
yggg Apr 15, 2019
dc83f39
docs(select): wrap examples into card
yggg Apr 17, 2019
a625c63
docs(select): add all combinations
yggg Apr 17, 2019
5846361
feat(select): add Eva outline and filled style
yggg Apr 17, 2019
ff01751
docs(select): add missing appearance binding
yggg Apr 17, 2019
f1db824
docs(select): change combinations into interactive example
yggg Apr 17, 2019
8304687
fix(select): use status theme variable
yggg Apr 17, 2019
8245037
feat(select): add hero status
yggg Apr 17, 2019
4cf708a
docs(select): add button to select disabled option
yggg Apr 17, 2019
8e5bc4b
refactor(option group): remove unnecessary style
yggg Apr 17, 2019
5abae6f
feat(select): add missing animation properties
yggg Apr 17, 2019
1cb16ef
fix(select): remove broken scss
yggg Apr 17, 2019
8f658cc
refactor(select): remove unused import
yggg Apr 17, 2019
289add0
fix(select): add missing methods
yggg Apr 17, 2019
d817d4e
refactor: remove commented lines
yggg Apr 18, 2019
012f3b1
Merge branch 'next' into feat/eva-select
yggg Apr 18, 2019
5bbeaf6
refactor(select): use common name for theme file
yggg Apr 18, 2019
97b7e1f
fix(select): update property name
yggg Apr 18, 2019
7ca9085
docs(select): update theme properties list
yggg Apr 18, 2019
4648ced
fix(select): correct file path
yggg Apr 18, 2019
4febc47
Merge branch 'next' into feat/eva-select
yggg Apr 19, 2019
02144b0
fix(select): align text to start
yggg Apr 19, 2019
1de27ed
docs(select): show appearance name
yggg Apr 19, 2019
d125dfa
fix(select): change icons size with font size
yggg Apr 19, 2019
f08db69
feat(select): add min width theme property
yggg Apr 19, 2019
ddc5625
fix(select): add missing full width class
yggg Apr 19, 2019
c47dd87
feat(select): add min width theme property
yggg Apr 19, 2019
b26e292
fix(select): change icon placement based on document direction
yggg Apr 19, 2019
2a7b147
docs(select interactive example): put configuration card on own row
yggg Apr 19, 2019
15a38e3
feat(select): increase min width
yggg Apr 19, 2019
75185f8
docs(select): include interactive example into docs
yggg Apr 19, 2019
928b413
docs(select interactive): fix scrolling
yggg Apr 19, 2019
43a3c98
refactor(select): make option look same across appearances
yggg Apr 19, 2019
fb1293a
refactor(select): make option look same across appearances
yggg Apr 19, 2019
62b7c05
docs(select): refactor interactive example
yggg Apr 19, 2019
c8eeb89
refactor(select): add parentheses
nnixaa Apr 22, 2019
3fc377b
docs(select): update sizes example
yggg Apr 22, 2019
d4b6158
docs(select): remove status from placeholder example
yggg Apr 22, 2019
0890f6b
docs(select): add common example styles
yggg Apr 22, 2019
4e12e51
fix(select): appearance setting
yggg Apr 22, 2019
8c3624f
docs(select): update sizes count
yggg Apr 22, 2019
c665d02
docs(select): replace outline with filled
yggg Apr 22, 2019
f8c5de6
Merge branch 'next' into feat/eva-select
yggg Apr 22, 2019
7346978
Merge branch 'next' into feat/eva-select
yggg Apr 22, 2019
f20a192
refactor(select): add parentheses
yggg Apr 24, 2019
1d11e41
Merge branch 'next' into feat/eva-select
yggg Apr 24, 2019
a5091e8
docs(select): update theme properties list
yggg Apr 24, 2019
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
14 changes: 10 additions & 4 deletions src/app/playground-components.ts
Original file line number Diff line number Diff line change
Expand Up @@ -895,10 +895,10 @@ export const PLAYGROUND_COMPONENTS: ComponentLink[] = [
name: 'Select Multiple',
},
{
path: 'select-outline.component',
link: '/select/select-outline.component',
component: 'SelectOutlineComponent',
name: 'Select Outline',
path: 'select-filled.component',
link: '/select/select-filled.component',
component: 'SelectFilledComponent',
name: 'Select Filled',
},
{
path: 'select-placeholder.component',
Expand Down Expand Up @@ -930,6 +930,12 @@ export const PLAYGROUND_COMPONENTS: ComponentLink[] = [
component: 'SelectStatusComponent',
name: 'Select Status',
},
{
path: 'select-interactive.component',
link: '/select/select-interactive.component',
component: 'SelectInteractiveComponent',
name: 'Select Interactive',
},
],
},
{
Expand Down
66 changes: 66 additions & 0 deletions src/framework/theme/components/select/_select-filled.scss
Original file line number Diff line number Diff line change
@@ -0,0 +1,66 @@
@mixin select-filled {
nb-select.appearance-filled .select-button {
background-color: nb-theme(select-filled-background-color);
border-color: nb-theme(select-filled-border-color);
border-style: nb-theme(select-filled-border-style);
border-width: nb-theme(select-filled-border-width);
color: nb-theme(select-filled-text-color);

&.placeholder {
color: nb-theme(select-filled-placeholder-text-color);
}

&:focus {
border-color: nb-theme(select-filled-focus-border-color);
}
&:hover {
background-color: nb-theme(select-filled-hover-background-color);
border-color: nb-theme(select-filled-hover-border-color);
}
&[disabled] {
color: nb-theme(select-filled-disabled-text-color);
background-color: nb-theme(select-filled-disabled-background-color);
border-color: nb-theme(select-filled-disabled-border-color);
}
}

@each $size in nb-get-sizes() {
nb-select.appearance-filled.size-#{$size} .select-button {
padding: nb-theme(select-filled-#{$size}-padding);
}
.appearance-filled.size-#{$size} {
nb-option-group .option-group-title,
nb-option {
padding: nb-theme(select-option-filled-#{$size}-padding);
}
nb-option-group nb-option {
padding-left: nb-theme(select-group-option-outline-#{$size}-start-padding);
}
}
}

@each $status in nb-get-statuses() {
nb-select.appearance-filled.status-#{$status} .select-button {
background-color: nb-theme(select-filled-#{$status}-background-color);
border-color: nb-theme(select-filled-#{$status}-border-color);
color: nb-theme(select-filled-#{$status}-text-color);

&.placeholder {
color: nb-theme(select-filled-#{$status}-placeholder-text-color);
}

&:focus {
background-color: nb-theme(select-filled-#{$status}-focus-background-color);
border-color: nb-theme(select-filled-#{$status}-focus-border-color);
}
&:hover {
background-color: nb-theme(select-filled-#{$status}-hover-background-color);
border-color: nb-theme(select-filled-#{$status}-hover-border-color);
}
&[disabled] {
background-color: nb-theme(select-filled-#{$status}-disabled-background-color);
border-color: nb-theme(select-filled-#{$status}-disabled-border-color);
}
}
}
}
77 changes: 77 additions & 0 deletions src/framework/theme/components/select/_select-hero.scss
Original file line number Diff line number Diff line change
@@ -0,0 +1,77 @@
@mixin select-hero {
nb-select.appearance-hero .select-button {
$left-color: nb-theme(select-hero-left-background-color);
$right-color: nb-theme(select-hero-right-background-color);
background-image: linear-gradient(to right, $left-color, $right-color);
border-color: nb-theme(select-hero-border-color);
border-style: nb-theme(select-hero-border-style);
border-width: nb-theme(select-hero-border-width);
color: nb-theme(select-hero-text-color);

&.placeholder {
color: nb-theme(select-hero-placeholder-text-color);
}

&:focus {
$left-color: nb-theme(select-hero-focus-left-background-color);
$right-color: nb-theme(select-hero-focus-right-background-color);
background-image: linear-gradient(to right, $left-color, $right-color);
}
&:hover {
$left-color: nb-theme(select-hero-hover-left-background-color);
$right-color: nb-theme(select-hero-hover-right-background-color);
background-image: linear-gradient(to right, $left-color, $right-color);
}
&[disabled] {
color: nb-theme(select-hero-disabled-text-color);
$left-color: nb-theme(select-hero-disabled-left-background-color);
$right-color: nb-theme(select-hero-disabled-right-background-color);
background-image: linear-gradient(to right, $left-color, $right-color);
}
}

@each $size in nb-get-sizes() {
nb-select.appearance-hero.size-#{$size} .select-button {
padding: nb-theme(select-hero-#{$size}-padding);
}
.appearance-hero.size-#{$size} {
nb-option-group .option-group-title,
nb-option {
padding: nb-theme(select-option-hero-#{$size}-padding);
}
nb-option-group nb-option {
padding-left: nb-theme(select-group-option-outline-#{$size}-start-padding);
}
}
}

@each $status in nb-get-statuses() {
nb-select.appearance-hero.status-#{$status} .select-button {
$left-color: nb-theme(select-hero-#{$status}-left-background-color);
$right-color: nb-theme(select-hero-#{$status}-right-background-color);
background-image: linear-gradient(to right, $left-color, $right-color);
color: nb-theme(select-hero-#{$status}-text-color);

&.placeholder {
color: nb-theme(select-hero-#{$status}-placeholder-text-color);
}

&:focus {
$left-color: nb-theme(select-hero-#{$status}-focus-left-background-color);
$right-color: nb-theme(select-hero-#{$status}-focus-right-background-color);
background-image: linear-gradient(to right, $left-color, $right-color);
}
&:hover {
$left-color: nb-theme(select-hero-#{$status}-hover-left-background-color);
$right-color: nb-theme(select-hero-#{$status}-hover-right-background-color);
background-image: linear-gradient(to right, $left-color, $right-color);
}
&[disabled] {
color: nb-theme(select-hero-#{$status}-disabled-text-color);
$left-color: nb-theme(select-hero-#{$status}-disabled-left-background-color);
$right-color: nb-theme(select-hero-#{$status}-disabled-right-background-color);
background-image: linear-gradient(to right, $left-color, $right-color);
}
}
}
}
55 changes: 55 additions & 0 deletions src/framework/theme/components/select/_select-outline.scss
Original file line number Diff line number Diff line change
@@ -0,0 +1,55 @@
@mixin select-outline {
nb-select.appearance-outline .select-button {
background-color: nb-theme(select-outline-background-color);
border-color: nb-theme(select-outline-border-color);
border-style: nb-theme(select-outline-border-style);
border-width: nb-theme(select-outline-border-width);
color: nb-theme(select-outline-text-color);

&.placeholder {
color: nb-theme(select-outline-placeholder-text-color);
}

&:focus {
border-color: nb-theme(select-outline-focus-border-color);
}
&:hover {
border-color: nb-theme(select-outline-hover-border-color);
}
&[disabled] {
color: nb-theme(select-outline-disabled-text-color);
background-color: nb-theme(select-outline-disabled-background-color);
border-color: nb-theme(select-outline-disabled-border-color);
}
}

@each $status in nb-get-statuses() {
nb-select.appearance-outline.status-#{$status} .select-button {
border-color: nb-theme(select-outline-#{$status}-border-color);
&.selected {
background-color: nb-theme(select-option-outline-#{$status}-selected-background-color);
}
&:focus {
border-color: nb-theme(select-outline-#{$status}-focus-border-color);
}
&:hover {
border-color: nb-theme(select-outline-#{$status}-hover-border-color);
}
}
}

@each $size in nb-get-sizes() {
nb-select.appearance-outline.size-#{$size} .select-button {
padding: nb-theme(select-outline-#{$size}-padding);
}
.appearance-outline.size-#{$size} {
nb-option-group .option-group-title,
nb-option {
padding: nb-theme(select-option-outline-#{$size}-padding);
}
nb-option-group nb-option {
padding-left: nb-theme(select-group-option-outline-#{$size}-start-padding);
}
}
}
}
Loading