Skip to content

Release 2020/11/10 #5187

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 68 commits into from
Nov 10, 2020
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
68 commits
Select commit Hold shift + click to select a range
ec9cbfd
fix: #5082 blank page on clicking challenges tab from stats history page
gets0ul Oct 16, 2020
3c4498a
fix: hide roles section if challenge does not have roles data
gets0ul Oct 19, 2020
38957f2
fix: test snapshot
gets0ul Oct 19, 2020
b455299
fix: reset review opportunity filter
gets0ul Oct 19, 2020
3aecb56
fix: remove unused code
gets0ul Oct 19, 2020
4004032
fix: toggle checkpoint feedback
gets0ul Oct 19, 2020
555390d
fix: lint
gets0ul Oct 19, 2020
9bbcc83
fix: more lint error
gets0ul Oct 19, 2020
978935c
fix: allow member to download own submission for design challenge
gets0ul Oct 20, 2020
7dd5542
fix: refactor code
gets0ul Oct 20, 2020
82349a3
fix: remove unused code
gets0ul Oct 20, 2020
726618a
fix: lint
gets0ul Oct 20, 2020
5c4a9ea
fix: test snapshot
gets0ul Oct 20, 2020
99721cb
Fix #4897
kkartunov Oct 21, 2020
2f4d297
Fix #5132
kkartunov Oct 21, 2020
0218dc9
fix for job descriptionn
skyhit Oct 25, 2020
c1f1297
Fixed copilot fulfillment
kkartunov Oct 27, 2020
09efe5d
refactor: use v4 api for member stats history
gets0ul Oct 27, 2020
26d680f
Merge pull request #5144 from gets0ul/use_v4_for_stats_history
luizrrodrigues Nov 4, 2020
e868fbe
fix: for issue #4527
luizrrodrigues Nov 4, 2020
d5d101c
ci: deploy stats-history-v4 to Stag env
luizrrodrigues Nov 4, 2020
d123a64
SEO: Update Challenge Listing and Details
luizrrodrigues Nov 4, 2020
00e0fa4
Merge pull request #5158 from topcoder-platform/issue-5157
luizrrodrigues Nov 4, 2020
8310b1e
ci: deploy seo-fix to Test env
luizrrodrigues Nov 4, 2020
ed117a7
ci: deploy fix_for_job_description to Stag env
luizrrodrigues Nov 4, 2020
dcfdad7
ci: deploying on test env
sushilshinde Nov 4, 2020
968961a
#4897 fixed podium too
kkartunov Nov 4, 2020
b64abf4
#4897 fixed tco20 challenge id bug
kkartunov Nov 4, 2020
b00763c
Merge pull request #5127 from topcoder-platform/issue-5125-gets0ul
luizrrodrigues Nov 5, 2020
e903d80
Merge pull request #5123 from topcoder-platform/issue-5082-gets0ul
luizrrodrigues Nov 5, 2020
ebd7933
Merge pull request #5129 from topcoder-platform/issue-4212-gets0ul
luizrrodrigues Nov 5, 2020
21a24e3
fix: the rendering of ordered list numbering and unordered list bullet
gets0ul Nov 6, 2020
4d565ff
fix: list style to be in the same format as challenge spec
gets0ul Nov 7, 2020
57e7f9a
Fix #5172
kkartunov Nov 9, 2020
7b1eaef
ci: deploy media-queries-fix to Stag env
luizrrodrigues Nov 9, 2020
9bb0e1d
fix: for issue #4659
luizrrodrigues Nov 9, 2020
bfd737d
ci: deploy fix_for_job_description to Dev env
luizrrodrigues Nov 9, 2020
3e45cd7
Fixes #5165
kkartunov Nov 9, 2020
bf8ac56
Merge branch 'develop' into fix_for_job_description
luizrrodrigues Nov 9, 2020
df9b671
fix: for issue #4659 sync with develop
luizrrodrigues Nov 9, 2020
f550746
Implements #5165
kkartunov Nov 9, 2020
c833dcc
ci: deploy pass-screen-updates to Stag env
luizrrodrigues Nov 9, 2020
4f368ea
fix: for issue #4659 - LookupService - Call v4 api /technologies inst…
luizrrodrigues Nov 9, 2020
cf6e3ec
ci: deploy bug-bash to Dev env
luizrrodrigues Nov 9, 2020
c8c6634
Merge pull request #5170 from gets0ul/issue_5168
luizrrodrigues Nov 10, 2020
185c319
Hide Challenge Email
luizrrodrigues Nov 10, 2020
6cc5989
Merge pull request #5177 from topcoder-platform/issue-5107
luizrrodrigues Nov 10, 2020
8e6fbd9
ci: deploy tcx-202011 to Stag env
luizrrodrigues Nov 10, 2020
e26da89
Merge pull request #5128 from topcoder-platform/issue-1532-gets0ul
luizrrodrigues Nov 10, 2020
423143e
Merge branch 'bug-bash-develop-sync' into bug-bash
luizrrodrigues Nov 10, 2020
f71c884
Merge pull request #5178 from topcoder-platform/bug-bash
luizrrodrigues Nov 10, 2020
e3d9f3d
Merge pull request #5179 from topcoder-platform/bug-bash-develop-sync
luizrrodrigues Nov 10, 2020
6d0f941
Merge branch 'develop' into tcx-202011
luizrrodrigues Nov 10, 2020
1bb3ae0
Merge branch 'develop' into seo-fix
luizrrodrigues Nov 10, 2020
47a09e7
Merge branch 'develop' into leaderboards-fixes
luizrrodrigues Nov 10, 2020
a5c0cc6
Merge pull request #5180 from topcoder-platform/tcx-202011
luizrrodrigues Nov 10, 2020
9793680
Merge pull request #5181 from topcoder-platform/seo-fix
luizrrodrigues Nov 10, 2020
1ec116f
Merge pull request #5161 from topcoder-platform/leaderboards-fixes
luizrrodrigues Nov 10, 2020
ce5c06f
Merge branch 'develop' into stats-history-v4
luizrrodrigues Nov 10, 2020
12d27f6
Merge pull request #5182 from topcoder-platform/stats-history-v4
luizrrodrigues Nov 10, 2020
b9e43aa
Merge branch 'develop' into fix_for_job_description
luizrrodrigues Nov 10, 2020
f2bdeb6
Merge pull request #5184 from topcoder-platform/pass-screen-updates
luizrrodrigues Nov 10, 2020
d7b3ce0
Merge branch 'develop' into media-queries-fix
luizrrodrigues Nov 10, 2020
b6fe5e6
Merge pull request #5139 from topcoder-platform/fix_for_job_description
luizrrodrigues Nov 10, 2020
5a4a704
Merge pull request #5185 from topcoder-platform/media-queries-fix
luizrrodrigues Nov 10, 2020
502e89b
Revert "fix for job description new PR"
luizrrodrigues Nov 10, 2020
3554094
Merge pull request #5186 from topcoder-platform/revert-5139-fix_for_j…
luizrrodrigues Nov 10, 2020
b2952f7
release : bug fixes
sushilshinde Nov 10, 2020
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 1 addition & 2 deletions .circleci/config.yml
Original file line number Diff line number Diff line change
Expand Up @@ -231,14 +231,13 @@ workflows:
branches:
only:
- develop
- auth0-hotfix-v3
# This is alternate dev env for parallel testing
- "build-test":
context : org-global
filters:
branches:
only:
- apollo-site
- free
# This is alternate dev env for parallel testing
- "build-qa":
context : org-global
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -241,9 +241,6 @@ exports[`renders marathon 1`] = `
</p>
</div>
</div>
<p
className="src-shared-components-ChallengeTile-___style__roles___1V-WA"
/>
</div>
</div>
</div>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,7 @@ exports[`Default render 1`] = `
defaultValue=""
onBlur={[Function]}
onChange={[Function]}
onKeyPress={[Function]}
placeholder=""
type="text"
/>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@ import Submission from 'components/SubmissionManagement/Submission';
import TU from 'react-dom/test-utils';

const mockOnDelete = jest.fn();
const mockOnDownload = jest.fn();
const mockOnShowDetails = jest.fn();

const rnd = new Rnd();
Expand All @@ -12,6 +13,7 @@ test('Snapshot match', () => {
rnd.render((
<Submission
onDelete={mockOnDelete}
onDownload={mockOnDownload}
onShowDetails={mockOnShowDetails}
showScreeningDetails
type="develop"
Expand All @@ -21,6 +23,7 @@ test('Snapshot match', () => {
rnd.render((
<Submission
onDelete={mockOnDelete}
onDownload={mockOnDownload}
onShowDetails={mockOnShowDetails}
submissionObject={{
id: '12345',
Expand Down Expand Up @@ -49,6 +52,7 @@ class Wrapper extends React.Component {
const page = TU.renderIntoDocument((
<Wrapper
onDelete={mockOnDelete}
onDownload={mockOnDownload}
onShowDetails={mockOnShowDetails}
submissionObject={{
id: '12345',
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -21,14 +21,17 @@ exports[`Snapshot match 1`] = `
className="src-shared-components-SubmissionManagement-Submission-___styles__action-col___2M1RY"
>
<div>
<a>
<button
onClick={[Function]}
type="button"
>
<DownloadIcon
height="16"
viewBox="0 0 16 16"
width="16"
xmlns="http://www.w3.org/2000/svg"
/>
</a>
</button>
<button
className="src-shared-components-SubmissionManagement-Submission-___styles__delete-icon___2M67z"
disabled={true}
Expand Down Expand Up @@ -81,14 +84,17 @@ exports[`Snapshot match 2`] = `
className="src-shared-components-SubmissionManagement-Submission-___styles__action-col___2M1RY"
>
<div>
<a>
<button
onClick={[Function]}
type="button"
>
<DownloadIcon
height="16"
viewBox="0 0 16 16"
width="16"
xmlns="http://www.w3.org/2000/svg"
/>
</a>
</button>
<button
className="src-shared-components-SubmissionManagement-Submission-___styles__delete-icon___2M67z"
disabled={true}
Expand Down
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -140,7 +140,7 @@
"supertest": "^3.1.0",
"tc-core-library-js": "github:appirio-tech/tc-core-library-js#v2.6.3",
"tc-ui": "^1.0.12",
"topcoder-react-lib": "1.1.1",
"topcoder-react-lib": "1.1.2",
"topcoder-react-ui-kit": "2.0.1",
"topcoder-react-utils": "0.7.8",
"turndown": "^4.0.2",
Expand Down
2 changes: 1 addition & 1 deletion src/shared/actions/page/challenge-details.js
Original file line number Diff line number Diff line change
Expand Up @@ -59,7 +59,7 @@ function setSpecsTabState(state) {
* @param {Boolean} open
* @return {Object}
*/
function toggleCheckpointFeedback(id, open) {
function toggleCheckpointFeedback(id, open = false) {
return { id, open };
}

Expand Down
13 changes: 9 additions & 4 deletions src/shared/components/ChallengeTile/index.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@
* Challenge tile.
*/
/* eslint-env browser */
import _ from 'lodash';
import React from 'react';
import PT from 'prop-types';
import { Link } from 'react-router-dom';
Expand Down Expand Up @@ -74,6 +75,7 @@ class ChallengeTile extends React.Component {
} = this.props;

const { track, type } = challenge;
const roles = _.get(challenge, 'userDetails.roles');

const outStyleName = `challenge tile-view ${track.replace(' ', '-').toLowerCase()}`;
const extraStyle = {
Expand Down Expand Up @@ -307,19 +309,22 @@ class ChallengeTile extends React.Component {
) }
</div>

<p styleName="roles">
{ track !== COMPETITION_TRACKS.DS
{ !_.isEmpty(roles)
&& (
<p styleName="roles">
{ track !== COMPETITION_TRACKS.DS
&& (
<span>
<span>
Role: &nbsp;
</span>
<span>
{ listRoles(challenge.userDetails.roles) }
{ listRoles(roles) }
</span>
</span>
) }
</p>
</p>
) }
</div>
</div>
</div>
Expand Down
31 changes: 25 additions & 6 deletions src/shared/components/Contentful/PasswordScreen/index.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -21,10 +21,12 @@ export default class PasswordScreen extends React.Component {

onSubmit() {
const { password } = this.props;
const { inputVal } = this.state;
this.setState({
authorized: password === inputVal,
errorMsg: password === inputVal ? '' : 'Password incorrect',
this.setState((state) => {
const { inputVal } = state;
return {
authorized: password === inputVal,
errorMsg: password === inputVal ? '' : 'Password incorrect',
};
});
}

Expand All @@ -41,7 +43,7 @@ export default class PasswordScreen extends React.Component {
authorized, errorMsg, inputVal,
} = this.state;
const {
viewPortId, preview, spaceName, environment, baseUrl, title,
viewPortId, preview, spaceName, environment, baseUrl, title, btnText, content,
} = this.props;
return authorized ? (
<Viewport
Expand All @@ -62,11 +64,24 @@ export default class PasswordScreen extends React.Component {
onChange={val => this.onPasswordInput(val)}
errorMsg={errorMsg}
required
type="password"
onEnterKey={this.onSubmit}
/>
<div styleName="cta">
<button type="button" styleName="submit" onClick={this.onSubmit} disabled={!inputVal}>SUBMIT</button>
<button type="button" styleName="submit" onClick={this.onSubmit} disabled={!inputVal}>{btnText}</button>
</div>
</div>
{
content ? (
<Viewport
id={content.sys.id}
preview={preview}
spaceName={spaceName}
environment={environment}
baseUrl={baseUrl}
/>
) : null
}
</div>
);
}
Expand All @@ -78,6 +93,8 @@ PasswordScreen.defaultProps = {
environment: null,
baseUrl: '',
title: 'GET ACCESS WITH PASSWORD',
btnText: 'SUBMIT',
content: null,
};

PasswordScreen.propTypes = {
Expand All @@ -88,4 +105,6 @@ PasswordScreen.propTypes = {
environment: PT.string,
baseUrl: PT.string,
title: PT.string,
btnText: PT.string,
content: PT.shape(),
};
2 changes: 2 additions & 0 deletions src/shared/components/Contentful/Route.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -71,6 +71,8 @@ function ChildRoutesLoader(props) {
environment={environment}
baseUrl={url}
title={fields.passwordScreenTitle}
btnText={fields.passwordScreenButtonText}
content={fields.passwordScreenContent}
/>
)
) : <Error404 />
Expand Down
13 changes: 12 additions & 1 deletion src/shared/components/GUIKit/TextInput/index.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,8 @@ function TextInput({
onChange,
required,
size,
type,
onEnterKey,
}) {
const [val, setVal] = useState(value);
const delayedOnChange = useRef(
Expand All @@ -28,7 +30,7 @@ function TextInput({
<div className="textInputContainer" styleName={`container ${sizeStyle}`}>
<input
defaultValue={value}
type="text"
type={type}
placeholder={`${placeholder}${placeholder && required ? ' *' : ''}`}
styleName={`${value || val ? 'haveValue' : ''} ${errorMsg ? 'haveError' : ''}`}
onChange={(e) => {
Expand All @@ -39,6 +41,11 @@ function TextInput({
delayedOnChange(e.target.value, onChange);
setVal(e.target.value);
}}
onKeyPress={(e) => {
if (e.key === 'Enter') {
onEnterKey();
}
}}
/>
{label ? (
<label htmlFor="textBoxInput">
Expand All @@ -58,6 +65,8 @@ TextInput.defaultProps = {
onChange: () => {},
required: false,
size: 'lg',
type: 'text',
onEnterKey: () => {},
};

TextInput.propTypes = {
Expand All @@ -68,6 +77,8 @@ TextInput.propTypes = {
onChange: PT.func,
required: PT.bool,
size: PT.oneOf(['xs', 'lg']),
type: PT.string,
onEnterKey: PT.func,
};

export default TextInput;
Original file line number Diff line number Diff line change
Expand Up @@ -116,7 +116,7 @@ class ChallengeHistoryModal extends Component {
challengesOrdered.map(challenge => (
<tr styleName="row" key={`${challenge['tco_leaderboard.challenge_id'] || challenge.challenge_id}`}>
<td styleName="name">
<a href={`${config.URL.BASE}/challenges/${challenge['tco_leaderboard.challenge_id'] || challenge.challenge_id}/`} styleName="link" target="_blank" rel="noopener noreferrer">
<a href={`${config.URL.BASE}/challenges/${challenge['tco_leaderboard.challenge_id'] || challenge['challenge.challenge_id'] || challenge.challenge_id}/`} styleName="link" target="_blank" rel="noopener noreferrer">
{challenge.challenge_name || challenge['challenge.challenge_name'] || challenge['tco_leaderboard.challenge_id'] || challenge.challenge_id}
</a>
</td>
Expand Down
15 changes: 12 additions & 3 deletions src/shared/components/Leaderboard/LeaderboardTable/index.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -65,6 +65,9 @@ export default function LeaderboardTable(props) {
photoUrl = `${config.CDN.PUBLIC}/avatar/${
encodeURIComponent(photoUrl)}?size=40`;
}
const fulfillment = competitor['tco_leaderboard.fulfillment']
? (parseFloat(competitor['tco_leaderboard.fulfillment']) * 100).toFixed(2).replace(/[.,]00$/, '')
: competitor.fulfillment;
return (
<tr key={competitor.rank}>
<td styleName={`${stylesName}.col-rank`}>{competitor.rank}</td>
Expand Down Expand Up @@ -105,7 +108,7 @@ export default function LeaderboardTable(props) {
</td>
{
isCopilot ? (
<td styleName={`${stylesName}.col-fulfillment`}>{competitor.fulfillment}</td>
<td styleName={`${stylesName}.col-fulfillment`}>{fulfillment}</td>
) : null
}
<td styleName={`${stylesName}.col-challenges`}>{competitor['tco_leaderboard.challenge_count'] || competitor.challengecount}</td>
Expand All @@ -122,7 +125,7 @@ export default function LeaderboardTable(props) {
}
{
isAlgo ? (
<td styleName={`${stylesName}.col-points`}>{competitor['srm_tco19.score']}</td>
<td styleName={`${stylesName}.col-points`}>{competitor['tco_leaderboard.total_score'] || competitor['srm_tco19.score']}</td>
) : null
}
</tr>
Expand All @@ -141,7 +144,13 @@ export default function LeaderboardTable(props) {
<th styleName={`${stylesName}.col-fulfillment`}>Fulfillment</th>
) : null
}
<th styleName={`${stylesName}.col-challenges`}># of Challenges</th>
{
isAlgo ? (
<th styleName={`${stylesName}.col-challenges`}># of Matches</th>
) : (
<th styleName={`${stylesName}.col-challenges`}># of Challenges</th>
)
}
<th styleName={`${stylesName}.col-points`}>Points</th>
{
isTopGear ? (
Expand Down
15 changes: 12 additions & 3 deletions src/shared/components/Leaderboard/PodiumSpot/index.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -107,6 +107,9 @@ export default function PodiumSpot(props) {
}
let rootStyle = `${stylesName}.PodiumSpot`;
if (PODIUM_ITEM_MODIFIER[competitor.rank]) rootStyle += ` ${stylesName}.PodiumSpot--${PODIUM_ITEM_MODIFIER[competitor.rank]}`;
const fulfillment = competitor['tco_leaderboard.fulfillment']
? (parseFloat(competitor['tco_leaderboard.fulfillment']) * 100).toFixed(2).replace(/[.,]00$/, '')
: competitor.fulfillment;

return (
<div styleName={rootStyle}>
Expand Down Expand Up @@ -175,14 +178,20 @@ export default function PodiumSpot(props) {
{
isCopilot ? (
<div styleName={`${stylesName}.stats`}>
<span styleName={`${stylesName}.value`}>{competitor.fulfillment}</span>
<span styleName={`${stylesName}.value`}>{fulfillment}</span>
<span styleName={`${stylesName}.value-title`}>fulfillment</span>
</div>
) : null
}
<div styleName={`${stylesName}.stats`}>
<span styleName={`${stylesName}.value`}>{competitor['tco_leaderboard.challenge_count'] || competitor.challengecount}</span>
<span styleName={`${stylesName}.value-title`}>challenges</span>
{
isAlgo ? (
<span styleName={`${stylesName}.value-title`}># of matches</span>
) : (
<span styleName={`${stylesName}.value-title`}>challenges</span>
)
}
</div>
<div styleName={`${stylesName}.stats`}>
<span styleName={`${stylesName}.value`}>{formatPoints(competitor['tco_leaderboard.tco_points'] || competitor.points)}</span>
Expand All @@ -207,7 +216,7 @@ export default function PodiumSpot(props) {
{
isAlgo ? (
<div styleName={`${stylesName}.stats`}>
<span styleName={`${stylesName}.value`}>{competitor['srm_tco19.score']}</span>
<span styleName={`${stylesName}.value`}>{competitor['tco_leaderboard.total_score'] || competitor['srm_tco19.score']}</span>
<span styleName={`${stylesName}.value-title`}>total score</span>
</div>
) : null
Expand Down
Loading