Skip to content

Commit 0d78f13

Browse files
Merge pull request #5653 from topcoder-platform/develop
Release v.1.10.8
2 parents ecda4d7 + 5ddca53 commit 0d78f13

File tree

6 files changed

+28
-6
lines changed

6 files changed

+28
-6
lines changed

src/shared/components/Contentful/ContentSlider/ContentSlider.jsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -101,7 +101,7 @@ ContentSlider.defaultProps = {
101101
cellSpacing: null,
102102
cellAlign: 'center',
103103
wrapAround: true,
104-
heightMode: 'current',
104+
heightMode: 'max',
105105
arrowTheme: 'Gray',
106106
};
107107

src/shared/components/Leaderboard/ChallengeHistoryModal/index.jsx

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -28,6 +28,7 @@ class ChallengeHistoryModal extends Component {
2828
loading,
2929
isCopilot,
3030
isAlgo,
31+
themeName,
3132
} = this.props;
3233
const { sortParam } = this.state;
3334
const challengesOrdered = _.orderBy(challenges, [sortParam.field], [sortParam.order]);
@@ -44,7 +45,7 @@ class ChallengeHistoryModal extends Component {
4445
competitor={competitor}
4546
isCopilot={isCopilot}
4647
isAlgo={isAlgo}
47-
themeName="TCO22"
48+
themeName={themeName}
4849
/>
4950
</div>
5051
<table styleName="history-table">
@@ -178,6 +179,7 @@ ChallengeHistoryModal.propTypes = {
178179
loading: PT.bool.isRequired,
179180
isAlgo: PT.bool,
180181
isCopilot: PT.bool,
182+
themeName: PT.string.isRequired,
181183
};
182184

183185
export default ChallengeHistoryModal;

src/shared/components/Leaderboard/ChallengeHistoryModal/styles.scss

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,7 @@ $light-gray: #d4d4d4;
1212
width: 70%;
1313
max-height: 90%;
1414
overflow-y: auto;
15-
padding: 80px 78px;
15+
padding: 60px 78px 80px;
1616

1717
@media (max-width: 768px) {
1818
width: 90%;
@@ -26,7 +26,7 @@ $light-gray: #d4d4d4;
2626
font-weight: 500;
2727
line-height: 38px;
2828
text-align: center;
29-
margin-bottom: 60px;
29+
margin-bottom: 40px;
3030
text-transform: uppercase;
3131

3232
@media (max-width: 768px) {

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

Lines changed: 17 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -35,12 +35,27 @@ const isActiveSubtrack = (subtrack) => {
3535
}
3636
if (subtrack.rank && subtrack.rank.rating > 0) {
3737
return true;
38-
} if (_.isNumber(subtrack.submissions)) {
38+
}
39+
if (_.isNumber(subtrack.submissions)) {
3940
return subtrack.submissions > 0;
4041
}
4142
return subtrack.submissions && subtrack.submissions.submissions > 0;
4243
};
4344

45+
/**
46+
* Inspects a subtrack and determines if it should be hidden
47+
*
48+
* @param {Object} subtrack Subtrack object
49+
* @returns {Boolean}
50+
*/
51+
const isHidden = (subtrack) => {
52+
if (subtrack.name === 'DEVELOP_MARATHON_MATCH') {
53+
return true;
54+
}
55+
56+
return false;
57+
};
58+
4459
class StatsCategory extends React.Component {
4560
getActiveTracks() {
4661
let { stats } = this.props;
@@ -72,7 +87,7 @@ class StatsCategory extends React.Component {
7287
}
7388

7489
subTracks.forEach((subtrack) => {
75-
if (isActiveSubtrack(subtrack)) {
90+
if (isActiveSubtrack(subtrack) && !isHidden(subtrack)) {
7691
active.push({ ...subtrack, active: true });
7792
}
7893
});

src/shared/containers/tco/Leaderboard/ChallengeHistoryModal/index.jsx

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -13,6 +13,7 @@ function ChallengeHistoryModalContainer({
1313
loading,
1414
isCopilot,
1515
isAlgo,
16+
themeName,
1617
}) {
1718
useEffect(() => {
1819
getChallengesHistory(dataUrl, competitor);
@@ -26,6 +27,7 @@ function ChallengeHistoryModalContainer({
2627
loading={loading}
2728
isCopilot={isCopilot}
2829
isAlgo={isAlgo}
30+
themeName={themeName}
2931
/>
3032
);
3133
}
@@ -36,6 +38,7 @@ ChallengeHistoryModalContainer.defaultProps = {
3638
loading: false,
3739
isCopilot: false,
3840
isAlgo: false,
41+
themeName: 'Default',
3942
};
4043

4144
const CHALLENGES_TYPE = PT.arrayOf(PT.shape({
@@ -61,6 +64,7 @@ ChallengeHistoryModalContainer.propTypes = {
6164
loading: PT.bool,
6265
isAlgo: PT.bool,
6366
isCopilot: PT.bool,
67+
themeName: PT.string,
6468
};
6569

6670
function mapStateToProps(state, ownProps) {

src/shared/containers/tco/Leaderboard/index.jsx

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -97,6 +97,7 @@ class LeaderboardPageContainer extends React.Component {
9797
dataUrl={tcoPointsApiUrl}
9898
isCopilot={isCopilot}
9999
isAlgo={isAlgo}
100+
themeName={themeName}
100101
/>
101102
) : null
102103
}

0 commit comments

Comments
 (0)