-
Notifications
You must be signed in to change notification settings - Fork 49
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
2840a82
commit 5355f24
Showing
13 changed files
with
54 additions
and
32 deletions.
There are no files selected for viewing
4 changes: 2 additions & 2 deletions
4
...n/question/widgets/common/DefaultBadge.js → ...mponents/main/question/QuestionDefault.js
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,11 +1,11 @@ | ||
import React from 'react' | ||
|
||
const DefaultBadge = () => { | ||
const QuestionDefault = () => { | ||
return ( | ||
<div className="badge badge-default" title={gettext('This is a default answer that can be customized.')}> | ||
{gettext('Default')} | ||
</div> | ||
) | ||
} | ||
|
||
export default DefaultBadge | ||
export default QuestionDefault |
22 changes: 22 additions & 0 deletions
22
rdmo/projects/assets/js/interview/components/main/question/QuestionEraseValue.js
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,22 @@ | ||
import React from 'react' | ||
import PropTypes from 'prop-types' | ||
|
||
const QuestionEraseValue = ({ value, updateValue }) => { | ||
const handleEraseValue = () => { | ||
updateValue(value, {}) | ||
} | ||
|
||
return ( | ||
<button type="button" className="btn btn-link btn-erase-value" onClick={handleEraseValue} | ||
title={gettext('Erase input')}> | ||
<i className="fa fa-eraser fa-btn"></i> | ||
</button> | ||
) | ||
} | ||
|
||
QuestionEraseValue.propTypes = { | ||
value: PropTypes.object.isRequired, | ||
updateValue: PropTypes.func.isRequired | ||
} | ||
|
||
export default QuestionEraseValue |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters