Skip to content

Commit

Permalink
[components] No pointer-events on arrow. pointer events on functions (#…
Browse files Browse the repository at this point in the history
  • Loading branch information
Kristoffer J. Sivertsen authored and bjoerge committed Mar 15, 2018
1 parent 88cf94c commit 477f012
Show file tree
Hide file tree
Showing 2 changed files with 11 additions and 2 deletions.
12 changes: 10 additions & 2 deletions packages/@sanity/components/src/selects/styles/DefaultSelect.css
Original file line number Diff line number Diff line change
Expand Up @@ -11,8 +11,8 @@
}

.select {
composes: textInput from 'part:@sanity/base/theme/forms/text-input-style';
padding-right: 2rem;
composes: root from 'part:@sanity/base/theme/forms/text-input-style';
box-sizing: border-box;
min-width: 7rem;
appearance: none;
position: relative;
Expand Down Expand Up @@ -70,6 +70,14 @@
z-index: 1;
pointer-events: none;

@nest & > * {
pointer-events: initial;
}

@nest & .arrow {
pointer-events: none;
}

@nest & > *:not(:first-child) {
margin-left: 0.5em;
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,7 @@
.arrow {
transition: transform 0.1s linear, opacity 0.1s linear;
outline: none;
user-select: initial;

@nest &:hover, &:focus {
opacity: 1;
Expand Down

0 comments on commit 477f012

Please sign in to comment.