Skip to content
GitLab
Explore
Sign in
Register
Primary navigation
Search or go to…
Project
X
xpub-faraday
Manage
Activity
Members
Labels
Plan
Issues
2
Issue boards
Milestones
Iterations
Wiki
Requirements
Code
Merge requests
0
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Locked files
Deploy
Releases
Container Registry
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
Repository analytics
Code review analytics
Issue analytics
Insights
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
This is an archived project. Repository and other project resources are read-only.
Show more breadcrumbs
xpub
xpub-faraday
Commits
fd382922
Commit
fd382922
authored
6 years ago
by
Daniel Sandu
Browse files
Options
Downloads
Patches
Plain Diff
fix(ValidatedField): UI issues Checkbox for Agree with Terms and Conditions in Sign-up
parent
96a86f36
No related branches found
No related tags found
2 merge requests
!110
Sprint 21 Features
,
!86
fix(ValidatedField): UI issues Checkbox for Agree with Terms and Conditions in Sign-up
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
packages/components-faraday/src/components/SignUp/SignUpStep0.js
+12
-6
12 additions, 6 deletions
...s/components-faraday/src/components/SignUp/SignUpStep0.js
with
12 additions
and
6 deletions
packages/components-faraday/src/components/SignUp/SignUpStep0.js
+
12
−
6
View file @
fd382922
...
@@ -4,6 +4,7 @@ import { reduxForm } from 'redux-form'
...
@@ -4,6 +4,7 @@ import { reduxForm } from 'redux-form'
import
{
get
,
isUndefined
}
from
'
lodash
'
import
{
get
,
isUndefined
}
from
'
lodash
'
import
{
required
as
requiredValidator
}
from
'
xpub-validators
'
import
{
required
as
requiredValidator
}
from
'
xpub-validators
'
import
{
Menu
,
Button
,
Checkbox
,
TextField
,
ValidatedField
}
from
'
@pubsweet/ui
'
import
{
Menu
,
Button
,
Checkbox
,
TextField
,
ValidatedField
}
from
'
@pubsweet/ui
'
import
styled
from
'
styled-components
'
import
{
import
{
Row
,
Row
,
...
@@ -16,7 +17,7 @@ import {
...
@@ -16,7 +17,7 @@ import {
}
from
'
pubsweet-component-faraday-ui
'
}
from
'
pubsweet-component-faraday-ui
'
const
AgreeCheckbox
=
({
value
,
onChange
})
=>
(
const
AgreeCheckbox
=
({
value
,
onChange
})
=>
(
<
Row
alignItems
=
"
center
"
justify
=
"
flex-start
"
mb
=
{
4
}
mt
=
{
3
}
>
<
Row
alignItems
=
"
center
"
justify
=
"
flex-start
"
mb
=
{
3
}
mt
=
{
3
}
>
<
Checkbox
checked
=
{
value
}
onChange
=
{
onChange
}
value
=
{
value
}
/
>
<
Checkbox
checked
=
{
value
}
onChange
=
{
onChange
}
value
=
{
value
}
/
>
<
Text
>
<
Text
>
I
agree
with
the
{
'
'
}
I
agree
with
the
{
'
'
}
...
@@ -26,6 +27,9 @@ const AgreeCheckbox = ({ value, onChange }) => (
...
@@ -26,6 +27,9 @@ const AgreeCheckbox = ({ value, onChange }) => (
<
/Text
>
<
/Text
>
<
/Row
>
<
/Row
>
)
)
const
ValidationRow
=
styled
(
Row
)
`
justify-content: left;
`
const
Step0
=
({
const
Step0
=
({
type
,
type
,
...
@@ -98,11 +102,13 @@ const Step0 = ({
...
@@ -98,11 +102,13 @@ const Step0 = ({
<
/Item
>
<
/Item
>
<
/Row
>
<
/Row
>
<
ValidatedField
<
ValidationRow
mb
=
{
2
}
>
component
=
{
AgreeCheckbox
}
<
ValidatedField
name
=
"
agreeTC
"
component
=
{
AgreeCheckbox
}
validate
=
{[
requiredValidator
]}
name
=
"
agreeTC
"
/
>
validate
=
{[
requiredValidator
]}
/
>
<
/ValidationRow
>
<
Row
>
<
Row
>
<
Text
secondary
small
>
<
Text
secondary
small
>
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment