Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
A
amundsen_dev
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Surendar Reddy Mangannagari
amundsen_dev
Commits
dbb33e1d
Unverified
Commit
dbb33e1d
authored
Dec 18, 2019
by
Tamika Tannis
Committed by
GitHub
Dec 18, 2019
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Consolidate look&feel of request/feedback forms (#359)
parent
c74346bd
Changes
10
Hide whitespace changes
Inline
Side-by-side
Showing
10 changed files
with
24 additions
and
32 deletions
+24
-32
index.tsx
...nts/Feedback/FeedbackForm/BugReportFeedbackForm/index.tsx
+2
-2
index.spec.tsx
...k/FeedbackForm/BugReportFeedbackForm/tests/index.spec.tsx
+1
-1
index.tsx
...onents/Feedback/FeedbackForm/RatingFeedbackForm/index.tsx
+2
-2
index.spec.tsx
...back/FeedbackForm/RatingFeedbackForm/tests/index.spec.tsx
+1
-1
index.tsx
...nents/Feedback/FeedbackForm/RequestFeedbackForm/index.tsx
+2
-2
index.spec.tsx
...ack/FeedbackForm/RequestFeedbackForm/tests/index.spec.tsx
+1
-1
index.tsx
amundsen_application/static/js/components/Feedback/index.tsx
+3
-3
styles.scss
...sen_application/static/js/components/Feedback/styles.scss
+7
-19
index.spec.tsx
...cation/static/js/components/Feedback/tests/index.spec.tsx
+1
-1
styles.scss
...js/components/TableDetail/RequestMetadataForm/styles.scss
+4
-0
No files found.
amundsen_application/static/js/components/Feedback/FeedbackForm/BugReportFeedbackForm/index.tsx
View file @
dbb33e1d
...
@@ -21,7 +21,7 @@ export class BugReportFeedbackForm extends AbstractFeedbackForm {
...
@@ -21,7 +21,7 @@ export class BugReportFeedbackForm extends AbstractFeedbackForm {
constructor
(
props
)
{
constructor
(
props
)
{
super
(
props
);
super
(
props
);
}
}
renderCustom
()
{
renderCustom
()
{
return
(
return
(
<
form
id=
{
AbstractFeedbackForm
.
FORM_ID
}
onSubmit=
{
this
.
submitForm
}
>
<
form
id=
{
AbstractFeedbackForm
.
FORM_ID
}
onSubmit=
{
this
.
submitForm
}
>
...
@@ -40,7 +40,7 @@ export class BugReportFeedbackForm extends AbstractFeedbackForm {
...
@@ -40,7 +40,7 @@ export class BugReportFeedbackForm extends AbstractFeedbackForm {
<
textarea
name=
"repro-steps"
className=
"form-control"
rows=
{
5
}
required=
{
true
}
<
textarea
name=
"repro-steps"
className=
"form-control"
rows=
{
5
}
required=
{
true
}
maxLength=
{
2000
}
placeholder=
{
REPRO_STEPS_PLACEHOLDER
}
/>
maxLength=
{
2000
}
placeholder=
{
REPRO_STEPS_PLACEHOLDER
}
/>
</
div
>
</
div
>
<
button
className=
"btn btn-
default submit
"
type=
"submit"
>
{
SUBMIT_TEXT
}
</
button
>
<
button
className=
"btn btn-
primary
"
type=
"submit"
>
{
SUBMIT_TEXT
}
</
button
>
</
form
>
</
form
>
);
);
}
}
...
...
amundsen_application/static/js/components/Feedback/FeedbackForm/BugReportFeedbackForm/tests/index.spec.tsx
View file @
dbb33e1d
...
@@ -106,7 +106,7 @@ describe('BugReportFeedbackForm', () => {
...
@@ -106,7 +106,7 @@ describe('BugReportFeedbackForm', () => {
it
(
'renders submit button with correct props'
,
()
=>
{
it
(
'renders submit button with correct props'
,
()
=>
{
expect
(
form
.
find
(
'button'
).
props
()).
toMatchObject
({
expect
(
form
.
find
(
'button'
).
props
()).
toMatchObject
({
className
:
'btn btn-
default submit
'
,
className
:
'btn btn-
primary
'
,
type
:
'submit'
,
type
:
'submit'
,
});
});
});
});
...
...
amundsen_application/static/js/components/Feedback/FeedbackForm/RatingFeedbackForm/index.tsx
View file @
dbb33e1d
...
@@ -19,7 +19,7 @@ export class RatingFeedbackForm extends AbstractFeedbackForm {
...
@@ -19,7 +19,7 @@ export class RatingFeedbackForm extends AbstractFeedbackForm {
constructor
(
props
)
{
constructor
(
props
)
{
super
(
props
);
super
(
props
);
}
}
renderCustom
()
{
renderCustom
()
{
const
ratings
=
[
1
,
2
,
3
,
4
,
5
,
6
,
7
,
8
,
9
,
10
];
const
ratings
=
[
1
,
2
,
3
,
4
,
5
,
6
,
7
,
8
,
9
,
10
];
const
radioButtonSet
=
ratings
.
map
(
rating
=>
(
const
radioButtonSet
=
ratings
.
map
(
rating
=>
(
...
@@ -46,7 +46,7 @@ export class RatingFeedbackForm extends AbstractFeedbackForm {
...
@@ -46,7 +46,7 @@ export class RatingFeedbackForm extends AbstractFeedbackForm {
</
div
>
</
div
>
<
textarea
className=
"form-control form-group"
name=
"comment"
form=
{
AbstractFeedbackForm
.
FORM_ID
}
<
textarea
className=
"form-control form-group"
name=
"comment"
form=
{
AbstractFeedbackForm
.
FORM_ID
}
rows=
{
8
}
maxLength=
{
2000
}
placeholder=
{
COMMENTS_PLACEHOLDER
}
/>
rows=
{
8
}
maxLength=
{
2000
}
placeholder=
{
COMMENTS_PLACEHOLDER
}
/>
<
button
className=
"btn btn-
default submit
"
type=
"submit"
>
{
SUBMIT_TEXT
}
</
button
>
<
button
className=
"btn btn-
primary
"
type=
"submit"
>
{
SUBMIT_TEXT
}
</
button
>
</
form
>
</
form
>
);
);
}
}
...
...
amundsen_application/static/js/components/Feedback/FeedbackForm/RatingFeedbackForm/tests/index.spec.tsx
View file @
dbb33e1d
...
@@ -110,7 +110,7 @@ describe('RatingFeedbackForm', () => {
...
@@ -110,7 +110,7 @@ describe('RatingFeedbackForm', () => {
it
(
'renders submit button with correct props as fourth child'
,
()
=>
{
it
(
'renders submit button with correct props as fourth child'
,
()
=>
{
expect
(
form
.
children
().
at
(
3
).
find
(
'button'
).
props
()).
toMatchObject
({
expect
(
form
.
children
().
at
(
3
).
find
(
'button'
).
props
()).
toMatchObject
({
className
:
'btn btn-
default submit
'
,
className
:
'btn btn-
primary
'
,
type
:
'submit'
,
type
:
'submit'
,
});
});
});
});
...
...
amundsen_application/static/js/components/Feedback/FeedbackForm/RequestFeedbackForm/index.tsx
View file @
dbb33e1d
...
@@ -21,7 +21,7 @@ export class RequestFeedbackForm extends AbstractFeedbackForm {
...
@@ -21,7 +21,7 @@ export class RequestFeedbackForm extends AbstractFeedbackForm {
constructor
(
props
)
{
constructor
(
props
)
{
super
(
props
);
super
(
props
);
}
}
renderCustom
()
{
renderCustom
()
{
return
(
return
(
<
form
id=
{
AbstractFeedbackForm
.
FORM_ID
}
onSubmit=
{
this
.
submitForm
}
>
<
form
id=
{
AbstractFeedbackForm
.
FORM_ID
}
onSubmit=
{
this
.
submitForm
}
>
...
@@ -40,7 +40,7 @@ export class RequestFeedbackForm extends AbstractFeedbackForm {
...
@@ -40,7 +40,7 @@ export class RequestFeedbackForm extends AbstractFeedbackForm {
<
textarea
name=
"value-prop"
className=
"form-control"
rows=
{
5
}
required=
{
true
}
<
textarea
name=
"value-prop"
className=
"form-control"
rows=
{
5
}
required=
{
true
}
maxLength=
{
2000
}
placeholder=
{
PROPOSITION_PLACEHOLDER
}
/>
maxLength=
{
2000
}
placeholder=
{
PROPOSITION_PLACEHOLDER
}
/>
</
div
>
</
div
>
<
button
className=
"btn btn-
default submit
"
type=
"submit"
>
{
SUBMIT_TEXT
}
</
button
>
<
button
className=
"btn btn-
primary
"
type=
"submit"
>
{
SUBMIT_TEXT
}
</
button
>
</
form
>
</
form
>
);
);
}
}
...
...
amundsen_application/static/js/components/Feedback/FeedbackForm/RequestFeedbackForm/tests/index.spec.tsx
View file @
dbb33e1d
...
@@ -106,7 +106,7 @@ describe('RequestFeedbackForm', () => {
...
@@ -106,7 +106,7 @@ describe('RequestFeedbackForm', () => {
it
(
'renders submit button with correct props'
,
()
=>
{
it
(
'renders submit button with correct props'
,
()
=>
{
expect
(
form
.
find
(
'button'
).
props
()).
toMatchObject
({
expect
(
form
.
find
(
'button'
).
props
()).
toMatchObject
({
className
:
'btn btn-
default submit
'
,
className
:
'btn btn-
primary
'
,
type
:
'submit'
,
type
:
'submit'
,
});
});
});
});
...
...
amundsen_application/static/js/components/Feedback/index.tsx
View file @
dbb33e1d
...
@@ -80,9 +80,9 @@ export default class Feedback extends React.Component<FeedbackProps, FeedbackSta
...
@@ -80,9 +80,9 @@ export default class Feedback extends React.Component<FeedbackProps, FeedbackSta
this
.
state
.
isOpen
&&
this
.
state
.
isOpen
&&
<
div
className=
"feedback-component"
>
<
div
className=
"feedback-component"
>
<
div
className=
"feedback-header"
>
<
div
className=
"feedback-header"
>
<
div
className=
"title"
>
<
h3
className=
"title"
>
{
this
.
props
.
title
.
toUpperCase
()
}
{
this
.
props
.
title
}
</
div
>
</
h3
>
<
button
type=
"button"
className=
"btn btn-close"
aria
-
label=
{
BUTTON_CLOSE_TEXT
}
onClick=
{
this
.
toggle
}
/>
<
button
type=
"button"
className=
"btn btn-close"
aria
-
label=
{
BUTTON_CLOSE_TEXT
}
onClick=
{
this
.
toggle
}
/>
</
div
>
</
div
>
<
div
className=
"text-center"
>
<
div
className=
"text-center"
>
...
...
amundsen_application/static/js/components/Feedback/styles.scss
View file @
dbb33e1d
...
@@ -40,34 +40,22 @@
...
@@ -40,34 +40,22 @@
color
:
$text-primary
;
color
:
$text-primary
;
.title
{
color
:
$text-secondary
;
flex-grow
:
1
;
font-size
:
12px
;
font-family
:
$font-family-header
;
font-weight
:
$font-weight-header-regular
;
height
:
24px
;
line-height
:
32px
;
}
.feedback-header
{
.feedback-header
{
display
:
flex
;
display
:
flex
;
margin-bottom
:
8px
;
margin-bottom
:
8px
;
.title
{
flex-grow
:
1
;
}
button
{
margin
:
auto
0
;
}
}
}
.btn-group
{
.btn-group
{
margin
:
8px
auto
16px
;
margin
:
8px
auto
16px
;
}
}
.submit
{
float
:
right
;
margin-top
:
16px
;
}
.submit
:hover
{
background-color
:
$gray-lighter
;
}
.radio-set
{
.radio-set
{
display
:
flex
;
display
:
flex
;
margin-top
:
8px
;
margin-top
:
8px
;
...
...
amundsen_application/static/js/components/Feedback/tests/index.spec.tsx
View file @
dbb33e1d
...
@@ -120,7 +120,7 @@ describe('Feedback', () => {
...
@@ -120,7 +120,7 @@ describe('Feedback', () => {
button
=
header
.
children
().
at
(
1
);
button
=
header
.
children
().
at
(
1
);
});
});
it
(
'renders correct title'
,
()
=>
{
it
(
'renders correct title'
,
()
=>
{
expect
(
title
.
text
()).
toEqual
(
props
.
title
.
toUpperCase
()
);
expect
(
title
.
text
()).
toEqual
(
props
.
title
);
});
});
it
(
'renders close button with correct props'
,
()
=>
{
it
(
'renders close button with correct props'
,
()
=>
{
...
...
amundsen_application/static/js/components/TableDetail/RequestMetadataForm/styles.scss
View file @
dbb33e1d
...
@@ -22,6 +22,10 @@
...
@@ -22,6 +22,10 @@
.request-header
{
.request-header
{
display
:
flex
;
display
:
flex
;
button
{
margin
:
auto
0
;
}
}
}
.select-label
{
.select-label
{
...
...
Write
Preview
Markdown
is supported
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