Skip to content

Release v1.9.1 #5508

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 19 commits into from
May 7, 2021
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
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
1 change: 0 additions & 1 deletion .circleci/config.yml
Original file line number Diff line number Diff line change
Expand Up @@ -305,7 +305,6 @@ workflows:
branches:
only:
- develop
- nursoltan-s-issue-5490
- "approve-smoke-test-on-staging":
type: approval
requires:
Expand Down
Binary file removed src/assets/images/og_image.jpg
Binary file not shown.
Binary file not shown.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file not shown.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file not shown.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file not shown.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file not shown.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
2 changes: 1 addition & 1 deletion src/shared/actions/recruitCRM.js
Original file line number Diff line number Diff line change
Expand Up @@ -69,7 +69,7 @@ function normalizeRecruitPayload(job, payload) {
contact_number: payload.phone,
city: payload.city,
locality: _.find(payload.country, { selected: true }).label,
salary_expectation: payload.payExpectation,
salary_expectation: _.trim(payload.payExpectation),
skill: payload.skills.filter(s => s.selected).map(s => s.label).join(','),
custom_fields: [
{
Expand Down
2 changes: 1 addition & 1 deletion src/shared/components/GUIKit/JobListCard/index.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ import { config, Link } from 'topcoder-react-utils';
import { getSalaryType, getCustomField } from 'utils/gigs';
import { withOptimizely } from '@optimizely/react-sdk';
import './style.scss';
import IconBlackDuration from 'assets/images/icon-black-duration.svg';
import IconBlackDuration from 'assets/images/icon-black-calendar.svg';
import IconBlackLocation from 'assets/images/icon-black-location.svg';
import IconBlackPayment from 'assets/images/icon-black-payment.svg';
import iconBlackSkills from 'assets/images/icon-skills.png';
Expand Down
4 changes: 3 additions & 1 deletion src/shared/components/GUIKit/JobListCard/style.scss
Original file line number Diff line number Diff line change
Expand Up @@ -77,7 +77,7 @@
}

&:nth-child(3) {
width: 263px;
width: 345px;

@media (max-width: 1280px) {
width: auto;
Expand All @@ -102,6 +102,8 @@
svg,
img {
margin-right: 7px;
width: 20px;
height: 20px;
}
}

Expand Down
4 changes: 2 additions & 2 deletions src/shared/components/Gigs/GigApply/index.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -207,9 +207,9 @@ export default function GigApply(props) {
<h4>RESUME & SKILLS</h4>
{
recruitProfile.resume ? (
<p>Upload Your Resume or CV, <a href={recruitProfile.resume.file_link} target="_blank" rel="noreferrer">{recruitProfile.resume.filename}</a></p>
<p>Please upload your resume/CV. Double-check that all of your tech skills are listed in your resume/CV and add them to the tech skills section below, <a href={recruitProfile.resume.file_link} target="_blank" rel="noreferrer">{recruitProfile.resume.filename}</a></p>
) : (
<p>Upload Your Resume or CV</p>
<p>Please upload your resume/CV. Double-check that all of your tech skills are listed in your resume/CV and add them to the tech skills section below.</p>
)
}
<div styleName="form-section">
Expand Down
19 changes: 14 additions & 5 deletions src/shared/containers/Gigs/RecruitCRMJobs.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -202,11 +202,11 @@ class RecruitCRMJobsContainer extends React.Component {
}
// Sort controlled by sortBy state
jobsToDisplay = jobsToDisplay.sort((a, b) => {
// sort tags first no matter the sortBy
const tagA = getCustomField(a.custom_fields, 'Job Tag');
const tagB = getCustomField(b.custom_fields, 'Job Tag');
if (tagB !== 'n/a' && tagA === 'n/a') return Number.MAX_VALUE;
if (tagB === 'n/a' && tagA !== 'n/a') return -Number.MIN_VALUE;
// sort featured gigs first no matter the sortBy
const featuredA = getCustomField(a.custom_fields, 'Featured');
const featuredB = getCustomField(b.custom_fields, 'Featured');
if (featuredB !== 'n/a' && featuredA === 'n/a') return Number.MAX_VALUE;
if (featuredB === 'n/a' && featuredA !== 'n/a') return -Number.MIN_VALUE;
return new Date(b[sortBy]) - new Date(a[sortBy]);
});
// Calc pages
Expand Down Expand Up @@ -248,6 +248,15 @@ class RecruitCRMJobsContainer extends React.Component {
<div styleName="location"><IconBlackLocation /> {hjob.country}</div>
<h5 styleName="job-title">{hjob.name}</h5>
<div styleName="job-money">${hjob.min_annual_salary} - {hjob.max_annual_salary} / {getSalaryType(hjob.salary_type)}</div>
{
getCustomField(hjob.custom_fields, 'Hotlist excerpt') !== 'n/a' ? (
<div styleName="job-desc">
{
`${getCustomField(hjob.custom_fields, 'Hotlist excerpt').substring(0, CONTENT_PREVIEW_LENGTH)}${getCustomField(hjob.custom_fields, 'Hotlist excerpt').length > CONTENT_PREVIEW_LENGTH ? '...' : ''}`
}
</div>
) : null
}
</Link>
) : (
<div styleName={`hotlist-item-${indx + 1}`} to={`${config.GIGS_PAGES_PATH}/${hjob.slug}`} key={`hotlist-item-${indx + 1}`}>
Expand Down
47 changes: 22 additions & 25 deletions src/shared/containers/challenge-detail/index.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -49,30 +49,22 @@ import { getService } from 'services/contentful';
// getRecommendedTags,
// } from 'utils/challenge-detail/helper';

import ogWireframe from
'../../../assets/images/open-graph/challenges/01-wireframe.jpg';
import ogUiDesign from
'../../../assets/images/open-graph/challenges/02-ui-design.jpg';
import ogUiPrototype from
'../../../assets/images/open-graph/challenges/03-ui-prototype.jpg';
'../../../assets/images/open-graph/challenges/02-Design-Preview.png';
import ogFirst2Finish from
'../../../assets/images/open-graph/challenges/04-first-2-finish.jpg';
'../../../assets/images/open-graph/challenges/09-First2Finish.png';
import ogDevelopment from
'../../../assets/images/open-graph/challenges/05-development.jpg';
'../../../assets/images/open-graph/challenges/03-Development.png';
import ogBigPrizesChallenge from
'../../../assets/images/open-graph/challenges/09-big-prizes-challenge.jpg';
import ogLuxChallenge from
'../../../assets/images/open-graph/challenges/10-lux-challenge.jpg';
import ogRuxChallenge from
'../../../assets/images/open-graph/challenges/11-rux-challenge.jpg';
import og24hUiPrototype from
'../../../assets/images/open-graph/challenges/12-24h-ui-prototype-challenge.jpg';
import og48hUiPrototype from
'../../../assets/images/open-graph/challenges/13-48h-ui-prototype-challenge.jpg';
'../../../assets/images/open-graph/challenges/06-Big-Prize.png';
import ogQAChallenge from
'../../../assets/images/open-graph/challenges/05-QA.png';
import ogDSChallenge from
'../../../assets/images/open-graph/challenges/04-Data-Science.png';

/* A fallback image, just in case we missed some corner case. */
import ogImage from
'../../../assets/images/og_image.jpg';
'../../../assets/images/social.png';

import './styles.scss';

Expand All @@ -88,9 +80,9 @@ const DAY = 24 * 60 * MIN;
*/
function getOgImage(challenge) {
const { legacy } = challenge;
const { track, subTrack } = legacy;
if (challenge.name.startsWith('LUX -')) return ogLuxChallenge;
if (challenge.name.startsWith('RUX -')) return ogRuxChallenge;
const { subTrack } = legacy;
if (challenge.name.startsWith('LUX -')) return ogBigPrizesChallenge;
if (challenge.name.startsWith('RUX -')) return ogBigPrizesChallenge;
if (challenge.prizes) {
const totalPrize = challenge.prizes.reduce((p, sum) => p + sum, 0);
if (totalPrize > 2500) return ogBigPrizesChallenge;
Expand All @@ -102,17 +94,22 @@ function getOgImage(challenge) {
const submission = (challenge.phases || [])
.find(p => p.name === CHALLENGE_PHASE_TYPES.SUBMISSION);
if (submission) {
if (submission.duration < 1.1 * DAY) return og24hUiPrototype;
if (submission.duration < 2.1 * DAY) return og48hUiPrototype;
if (submission.duration < 1.1 * DAY) return ogDevelopment;
if (submission.duration < 2.1 * DAY) return ogDevelopment;
}
return ogUiPrototype;
return ogDevelopment;
}
case SUBTRACKS.WIREFRAMES: return ogWireframe;
case SUBTRACKS.WIREFRAMES: return ogUiDesign;
case SUBTRACKS.QA:
case SUBTRACKS.TEST_SUITES:
return ogQAChallenge;
case SUBTRACKS.DS: return ogDSChallenge;
default:
}
switch (track) {
switch (challenge.track) {
case COMPETITION_TRACKS_V3.DEVELOP: return ogDevelopment;
case COMPETITION_TRACKS_V3.DESIGN: return ogUiDesign;
case COMPETITION_TRACKS_V3.DS: return ogDSChallenge;
default: return ogImage;
}
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@ import MetaTags from 'components/MetaTags';
import { USER_GROUP_MAXAGE } from 'config';
import { updateChallengeType } from 'utils/challenge';

import ogImage from '../../../../assets/images/og_image.jpg';
import ogImage from '../../../../assets/images/social.png';
import style from './styles.scss';

// const { combine, mapToBackend } = challengeUtils.filter;
Expand Down
8 changes: 6 additions & 2 deletions src/shared/utils/tc.js
Original file line number Diff line number Diff line change
Expand Up @@ -31,8 +31,9 @@ export const CHALLENGE_PHASE_TYPES = {
*/

export const COMPETITION_TRACKS_V3 = {
DESIGN: 'DESIGN',
DEVELOP: 'DEVELOP',
DESIGN: 'Design',
DEVELOP: 'Development',
DS: 'Data Science',
};

/* Holds valid subtracks (only some of possible values are included into this
Expand All @@ -41,6 +42,9 @@ export const SUBTRACKS = {
FIRST_2_FINISH: 'FIRST_2_FINISH',
UI_PROTOTYPE_COMPETITION: 'UI_PROTOTYPE_COMPETITION',
WIREFRAMES: 'WIREFRAMES',
QA: 'BUG_HUNT',
TEST_SUITES: 'TEST_SUITES',
DS: 'DEVELOP_MARATHON_MATCH',
};

/**
Expand Down