Skip to content

Commit b30748a

Browse files
authored
Merge pull request #3633 from yoution/feature-details-page-suggestion-cards
#3631 fix review issues on challenge 30113877
2 parents 813fc9b + 530fb6a commit b30748a

File tree

4 files changed

+8
-4
lines changed

4 files changed

+8
-4
lines changed

config/default.js

+2
Original file line numberDiff line numberDiff line change
@@ -115,6 +115,8 @@ module.exports = {
115115
FORUMS: 'https://apps.topcoder-dev.com/forums',
116116
HELP: 'https://help.topcoder-dev.com',
117117

118+
THRIVE: 'https://www.topcoder.com/thrive',
119+
118120
COMMUNITIES: {
119121
BLOCKCHAIN: 'https://blockchain.topcoder-dev.com',
120122
COGNITIVE: 'https://cognitive.topcoder-dev.com',

src/shared/components/challenge-detail/Header/style.scss

+1-1
Original file line numberDiff line numberDiff line change
@@ -127,12 +127,12 @@
127127
.tag-container {
128128
display: flex;
129129
align-items: center;
130-
cursor: pointer;
131130
}
132131

133132
.recommend-tag {
134133
@include roboto-regular;
135134

135+
cursor: pointer;
136136
width: 199px;
137137
margin-left: 12px;
138138
font-size: 14px;

src/shared/components/challenge-detail/ThriveArticles/index.jsx

+1-1
Original file line numberDiff line numberDiff line change
@@ -44,7 +44,7 @@ export default function ThriveArticles({ articles }) {
4444
Recommended THRIVE Articles
4545
</div>
4646
<div styleName="right-url">
47-
<a href="http://topcoder.com/thrive" rel="noopener noreferrer" target="_blank">Explore THRIVE</a>
47+
<a href={config.URL.THRIVE} rel="noopener noreferrer" target="_blank">Explore THRIVE</a>
4848
</div>
4949
</div>
5050
<div styleName="articles">

src/shared/containers/challenge-detail/index.jsx

+4-2
Original file line numberDiff line numberDiff line change
@@ -203,10 +203,12 @@ class ChallengeDetailPageContainer extends React.Component {
203203
}
204204
if (nextProps.challenge.track && nextProps.challenge.track.toLowerCase() !== 'design'
205205
&& thriveArticles.length === 0) {
206-
if (!(nextProps.challenge.technologies.length === 1 && nextProps.challenge.technologies[0] === 'Other')) {
206+
const { technologies } = nextProps.challenge;
207+
if (technologies.length > 0 && !(technologies.length === 1 && technologies[0] === 'Other')) {
208+
// for technologies = ['Other', ...], if 'Other' is first, use second value
207209
this.apiService.getEDUContent({
208210
limit: 3,
209-
phrase: nextProps.challenge.technologies[0],
211+
phrase: technologies[0] === 'Other' ? technologies[1] : technologies[0],
210212
types: ['Article'],
211213
}).then((content) => {
212214
// format image file data

0 commit comments

Comments
 (0)