Skip to content

Commit 6e27b37

Browse files
committed
ui tweaks
1 parent 35e4af3 commit 6e27b37

File tree

4 files changed

+9
-4
lines changed

4 files changed

+9
-4
lines changed

package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -153,7 +153,7 @@
153153
"supertest": "^3.1.0",
154154
"tc-core-library-js": "github:appirio-tech/tc-core-library-js#v2.6.3",
155155
"tc-ui": "^1.0.12",
156-
"topcoder-react-lib": "1000.29.2",
156+
"topcoder-react-lib": "1.2.9",
157157
"topcoder-react-ui-kit": "2.0.1",
158158
"topcoder-react-utils": "0.7.8",
159159
"turndown": "^4.0.2",

src/shared/components/ProfilePage/Awards/AwardModal/index.jsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -26,7 +26,7 @@ const AwatarModal = ({
2626
<span>{title}</span>
2727
</div>
2828

29-
<div styleName="description" dangerouslySetInnerHTML={{ __html: description }} />
29+
<div styleName="description">{description}</div>
3030

3131
</div>
3232
</div>

src/shared/components/ProfilePage/Awards/AwardModal/styles.scss

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,5 @@
11
@import "~styles/mixins";
2+
@import "~components/Contentful/brackets";
23

34
.awardModal {
45
display: flex;
@@ -40,7 +41,7 @@
4041
}
4142

4243
.description {
43-
@include roboto-regular;
44+
@include brackets-content;
4445

4546
font-weight: 400;
4647
color: $tco-black;

src/shared/components/ProfilePage/Awards/index.jsx

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,6 +3,7 @@ import PT from 'prop-types';
33
import { Modal } from 'topcoder-react-ui-kit';
44
import IconClose from 'assets/images/tc-edu/icon-close-big.svg';
55
import _ from 'lodash';
6+
import md from 'utils/markdown';
67

78
import style from './styles.scss';
89
import AwardBadge from './AwardBadge';
@@ -23,8 +24,11 @@ const Awards = ({ badges }) => {
2324
{
2425
badges.map((reward) => {
2526
const title = _.get(reward, 'org_badge.badge_name');
26-
const description = _.get(reward, 'org_badge.badge_description');
2727
const imageUrl = _.get(reward, 'org_badge.badge_image_url');
28+
let description = _.get(reward, 'org_badge.badge_description');
29+
if (description) {
30+
description = md(description);
31+
}
2832

2933
return (
3034
<AwardBadge

0 commit comments

Comments
 (0)