Skip to content

Commit 4168cf2

Browse files
gabriellshggazzo
andauthored
fix: outline input and Select text wrapping (#177)
Co-authored-by: Guilherme Gazzo <guilhermegazzo@gmail.com>
1 parent e3d7d7d commit 4168cf2

File tree

37 files changed

+13
-3
lines changed

37 files changed

+13
-3
lines changed
Loading
Loading
Loading
Loading
Loading
Loading
Loading
Loading
Loading
Loading
Loading
Loading
Loading
Loading
Loading
Loading
Loading
Loading
Loading
Loading
Loading
Loading
Loading
Loading
Loading
Loading
Loading
Loading
Loading
Loading
Loading
Loading

packages/fuselage/src/components/Select/Select.js

+2-2
Original file line numberDiff line numberDiff line change
@@ -81,9 +81,9 @@ export const Select = ({
8181
<Flex.Container>
8282
<Margins inline='neg-x4'>
8383
<Wrapper mod-hidden={!!visibleText}>
84-
{ visibleText && <Flex.Item grow={1}>
84+
{ visibleText && <Flex.Item grow={1} shrink={1}>
8585
<Margins inline='x4'>
86-
<Box is='span' textStyle='p2' textColor={ valueLabel ? 'default' : 'hint' }>{visibleText}</Box>
86+
<Box is='span' componentClassName='rcx-select__item' textStyle='p2' textColor={ valueLabel ? 'default' : 'hint' }>{visibleText}</Box>
8787
</Margins>
8888
</Flex.Item>}
8989
<Anchor disabled={disabled} mod-undecorated={true} filter={filter} ref={ref} aria-haspopup='listbox' onClick={show} onBlur={hide} onKeyUp={handleKeyUp} onKeyDown={handleKeyDown} />

packages/fuselage/src/components/Select/styles.scss

+10
Original file line numberDiff line numberDiff line change
@@ -5,6 +5,12 @@
55

66
align-items: center; // TODO move to .rcx-input-box
77

8+
&__item {
9+
white-space: nowrap;
10+
11+
@include use-text-ellipsis;
12+
}
13+
814
&__focus,
915
&__placeholder {
1016
display: inline-block;
@@ -31,10 +37,14 @@
3137
}
3238

3339
&__wrapper {
40+
41+
min-width: 0;
42+
3443
user-select: none;
3544

3645
opacity: 1;
3746
flex-grow: 1;
47+
flex-shrink: 1;
3848

3949
&--hidden {
4050
.rcx-select__focus {

packages/fuselage/src/styles/mixins/shadows.scss

+1-1
Original file line numberDiff line numberDiff line change
@@ -3,5 +3,5 @@
33
}
44

55
@mixin use-focus-shadow($outer-color) {
6-
box-shadow: 0 0 0 #{ to-rem(6) } #{ $outer-color };
6+
box-shadow: 0 0 0 #{ to-rem($spaces-x4) } #{ $outer-color };
77
}

0 commit comments

Comments
 (0)