Skip to content
GitLab
Menu
Projects
Groups
Snippets
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Open sidebar
RocketChat
Rocket.Chat.Fuselage
Commits
630e622d
Unverified
Commit
630e622d
authored
Feb 05, 2020
by
Guilherme Gazzo
Committed by
GitHub
Feb 05, 2020
Browse files
fix: Select/MultiSelect focus submitting form (#134)
parent
cc590460
Changes
2
Hide whitespace changes
Inline
Side-by-side
packages/fuselage-ui-kit/src/index.js
View file @
630e622d
...
...
@@ -35,7 +35,7 @@ export const defaultContext = {
action
:
(...
args
)
=>
console
.
log
(
JSON
.
stringify
(
args
)),
state
:
console
.
log
,
appId
:
'
123456789ABCDEFGHJKLMNPQRSTUVWXYZabcdefghijkmnopqrstuvwxyz
'
,
errors
:
{}
errors
:
{}
,
};
export
const
kitContext
=
React
.
createContext
(
defaultContext
);
...
...
packages/fuselage/src/components/Select/Select.js
View file @
630e622d
...
...
@@ -11,7 +11,7 @@ export const Addon = Box.extend('rcx-select__addon', 'div');
const
Wrapper
=
Box
.
extend
(
'
rcx-select__wrapper
'
,
'
div
'
);
// ({ children, ...props }) => <InnerWrapper children={React.Children.map(children, (c, i) => <Margins key={i} inline='x4'>{c}</Margins>)} {...props} />;
export
const
Focus
=
React
.
forwardRef
((
props
,
ref
)
=>
<
Box
ref
=
{
ref
}
textStyle
=
'
p2
'
textColor
=
'
hint
'
componentClassName
=
'
rcx-select__focus
'
is
=
'
button
'
{...
props
}
/>
)
;
export
const
Focus
=
React
.
forwardRef
((
props
,
ref
)
=>
<
Box
ref
=
{
ref
}
textStyle
=
'
p2
'
textColor
=
'
hint
'
componentClassName
=
'
rcx-select__focus
'
is
=
'
button
'
type
=
'
button
'
{...
props
}
/>
)
;
export
const
Select
=
({
value
,
...
...
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment