Skip to content
This repository was archived by the owner on Mar 13, 2025. It is now read-only.

Commit 98ab018

Browse files
authored
Merge pull request #265 from topcoder-platform/feature/interviewer-bugfix
Feature/interviewer bugfix
2 parents b6e939c + 836eeae commit 98ab018

File tree

19 files changed

+59
-23
lines changed

19 files changed

+59
-23
lines changed

src/assets/images/icon-check.svg

+1-1
Loading

src/assets/images/icon-cross-light.svg

+1-1
Loading

src/assets/images/icon-cross.svg

+1-1
Loading

src/assets/images/icon-moon.svg

+1-1
Loading

src/assets/images/icon-resume.svg

+1-1
Loading

src/assets/images/icon-sun.svg

+1-1
Loading

src/components/BaseModal/index.jsx

+3-1
Original file line numberDiff line numberDiff line change
@@ -34,6 +34,7 @@ function BaseModal({
3434
children,
3535
title,
3636
button,
37+
closeButtonText,
3738
disabled,
3839
extraModalStyle,
3940
}) {
@@ -58,7 +59,7 @@ function BaseModal({
5859
onClick={onClose}
5960
disabled={disabled}
6061
>
61-
Cancel
62+
{closeButtonText ? closeButtonText : "Cancel"}
6263
</Button>
6364
</div>
6465
</Modal>
@@ -71,6 +72,7 @@ BaseModal.propTypes = {
7172
children: PT.node,
7273
title: PT.string,
7374
button: PT.element,
75+
closeButtonText: PT.string,
7476
disabled: PT.bool,
7577
extraModalStyle: PT.object,
7678
};

src/components/BaseModal/styles.module.scss

+4
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,9 @@
11
@import "styles/include";
22

3+
svg {
4+
pointer-events: none;
5+
}
6+
37
.title {
48
@include font-barlow-condensed;
59
font-weight: normal;

src/components/MarkdownEditor/styles.module.scss

+4
Original file line numberDiff line numberDiff line change
@@ -43,6 +43,10 @@
4343
border: 1px solid #aaaaab;
4444
border-radius: 4px;
4545
overflow: hidden;
46+
&:focus-within:not(.error) {
47+
border-color: #55a5ff;
48+
box-shadow: 0 0 2px 1px #cee6ff;
49+
}
4650
}
4751

4852
.te-toolbar-section {

src/components/Select/styles.module.scss

+1-2
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@
55
c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gxODIsMC43MzM2OTU2NTIgQzEuMDQ0MDQxMDgsMC4zNDM5MTIzMTggMS42NTM2NjI1OCwwLjMyMTU3MDE2OSAyLjA0MzQ0NTkxLDAuNjgzNzkzMDY1IEMyLjA1MjU3NDU3LDAuNjkyMjc2MjYxIDIuMDYxNTM3NzgsMC43MDA5MzU3NjggMi4wNzAzMzA0OCwwLjcwOTc2NjcgTDcuNSw2LjE2MzA0MzQ4IEw3LjUsNi4xNjMwNDM0OCBMMTIuOTI5NjY5NSwwLjcwOTc2NjcgQzEzLjMwNTEwOCwwLjMzMjY5NTg2NyAxMy45MTUxMzc0LDAuMzMxMzcyNTkzIDE0LjI5MjIwODIsMC43MDY4MTEwODUgQzE0LjMwMTAzOTEsMC43MTU2MDM3ODcgMTQuMzA5Njk4NiwwLjcyNDU2Njk5NiAxNC4zMTgxODE4LDAuNzMzNjk1NjUyIEMxNC42OTg5NDM5LDEuMTQzNDI4NzUgMTQuNjg3OTU5OSwxLjc4MDc4ODA2IDE0LjI5MzMwNTksMi4xNzcxNTggTDguMjA4NjM4OTcsOC4yODgyNzk5OSBDNy44MTg5NjI3Miw4LjY3OTY1MDQ5IDcuMTg1Nzk5MjMsOC42ODEwMjM5NCA2Ljc5NDQyODczLDguMjkxMzQ3NjkgQzYuNzkzNDAzOTUsOC4yOTAzMjczNSA2Ljc5MjM4MTM4LDguMjg5MzA0NzggNi43OTEzNjEwMyw4LjI4ODI3OTk5IFoiIGlkPSJhcnJvdyI+PC9wYXRoPgogICAgICAgICAgICAgICAgICAgIDwvZz4KICAgICAgICAgICAgICAgIDwvZz4KICAgICAgICAgICAgPC9nPgogICAgICAgIDwvZz4KICAgIDwvZz4KPC9zdmc+Cg==")
8-
no-repeat center right;
8+
no-repeat 96% center;
99
border: 0;
1010
color: #2a2a2a;
1111
outline: none;
@@ -23,7 +23,6 @@
2323
border-radius: 6px;
2424
display: flex;
2525
height: 40px;
26-
padding-right: 15px;
2726
position: relative;
2827
}
2928

src/components/SkillsSummary/index.jsx

+1-1
Original file line numberDiff line numberDiff line change
@@ -21,7 +21,7 @@ const SkillsSummary = ({ skills, requiredSkills = [], limit }) => {
2121
<div>
2222
<div styleName="percentage">
2323
<PercentageBar ratio={skillsMatchedRatio} styleName="percentage-bar" />
24-
{Math.round(skillsMatchedRatio * 100)}% skill matched
24+
{Math.round(skillsMatchedRatio * 100)}% skills matched
2525
</div>
2626
<SkillsList
2727
skills={skills}

src/constants/index.js

+10-1
Original file line numberDiff line numberDiff line change
@@ -7,6 +7,11 @@
77
*/
88
export const DAY_FORMAT = "MM/DD/YYYY";
99

10+
/**
11+
* Date with time format
12+
*/
13+
export const DATE_WITH_TIME_FORMAT = "MM/DD/YYYY HH:mm";
14+
1015
/**
1116
* How many team member show per page by default
1217
*/
@@ -123,24 +128,28 @@ export const CANDIDATE_STATUS_FILTERS = [
123128
key: CANDIDATE_STATUS_FILTER_KEY.TO_REVIEW,
124129
buttonText: "To Review",
125130
title: "Candidates to Review",
131+
noCandidateMessage: "No Candidates To Review",
126132
statuses: [CANDIDATE_STATUS.OPEN],
127133
},
128134
{
129135
key: CANDIDATE_STATUS_FILTER_KEY.INTERESTED,
130136
buttonText: "Interviews",
131137
title: "Interviews",
138+
noCandidateMessage: "No Interviews",
132139
statuses: [CANDIDATE_STATUS.INTERVIEW],
133140
},
134141
{
135142
key: CANDIDATE_STATUS_FILTER_KEY.SELECTED,
136143
buttonText: "Selected",
137144
title: "Selected",
145+
noCandidateMessage: "No Selected Candidates",
138146
statuses: [CANDIDATE_STATUS.SELECTED],
139147
},
140148
{
141149
key: CANDIDATE_STATUS_FILTER_KEY.NOT_INTERESTED,
142150
buttonText: "Declined",
143151
title: "Declined",
152+
noCandidateMessage: "No Declined Candidates",
144153
statuses: [
145154
CANDIDATE_STATUS.CLIENT_REJECTED_SCREENING,
146155
CANDIDATE_STATUS.CLIENT_REJECTED_INTERVIEW,
@@ -162,7 +171,7 @@ export const CANDIDATES_SORT_BY = {
162171
* Candidates "sort by" select options
163172
*/
164173
export const CANDIDATES_SORT_OPTIONS = [
165-
{ label: "Skill Matched", value: CANDIDATES_SORT_BY.SKILL_MATCHED },
174+
{ label: "Skills Matched", value: CANDIDATES_SORT_BY.SKILL_MATCHED },
166175
{ label: "Handle", value: CANDIDATES_SORT_BY.HANDLE },
167176
];
168177

src/routes/PositionDetails/components/InterviewDetailsPopup/index.jsx

+6-1
Original file line numberDiff line numberDiff line change
@@ -86,7 +86,12 @@ function InterviewDetailsPopup({ open, onClose, candidate, openNext }) {
8686
candidate.interviews.length >= MAX_ALLOWED_INTERVIEWS
8787
) {
8888
return (
89-
<BaseModal open={open} onClose={onClose} title="Schedule an Interview">
89+
<BaseModal
90+
open={open}
91+
onClose={onClose}
92+
closeButtonText="Close"
93+
title="Schedule an Interview"
94+
>
9095
<p styleName="exceeds-max-number-txt">
9196
You've reached the cap of {MAX_ALLOWED_INTERVIEWS} interviews with
9297
this candidate. Now please make your decision to Select and Decline

src/routes/PositionDetails/components/LatestInterview/index.jsx

+2-2
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@
66
import React from "react";
77
import PT from "prop-types";
88
import "./styles.module.scss";
9-
import { formatDate } from "utils/format";
9+
import { formatInterviewDate } from "utils/format";
1010

1111
function LatestInterview({ interviews }) {
1212
if (!interviews || !interviews.length) {
@@ -19,7 +19,7 @@ function LatestInterview({ interviews }) {
1919
<>
2020
<p styleName="small">Interview Round {latestInterview.round}</p>
2121
<p styleName="strong">{latestInterview.status}</p>
22-
<p>{formatDate(latestInterview.startTimestamp)}</p>
22+
<p>{formatInterviewDate(latestInterview.startTimestamp)}</p>
2323
</>
2424
);
2525
}

src/routes/PositionDetails/components/PositionCandidates/index.jsx

+1-1
Original file line numberDiff line numberDiff line change
@@ -200,7 +200,7 @@ const PositionCandidates = ({ position, statusFilterKey, updateCandidate }) => {
200200
/>
201201

202202
{filteredCandidates.length === 0 && (
203-
<div styleName="no-candidates">No {statusFilter.title}</div>
203+
<div styleName="no-candidates">{statusFilter.noCandidateMessage}</div>
204204
)}
205205
{filteredCandidates.length > 0 && (
206206
<div styleName="table">

src/routes/PositionDetails/components/PrevInterviewItem/index.jsx

+2-2
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@
55
*/
66
import React from "react";
77
import PT from "prop-types";
8-
import { formatDate } from "utils/format";
8+
import { formatInterviewDate } from "utils/format";
99
import Accordion from "components/Accordion";
1010
import "./styles.module.scss";
1111

@@ -15,7 +15,7 @@ function PrevInterviewItem(props) {
1515
return (
1616
<Accordion
1717
title={`Interview Round ${round}`}
18-
subhead={formatDate(date)}
18+
subhead={formatInterviewDate(date)}
1919
sidebar={`${guestEmails.length + 1} Attendee(s)`}
2020
>
2121
<ul>

src/routes/PositionDetails/components/SelectCandidatePopup/index.jsx

+2-2
Original file line numberDiff line numberDiff line change
@@ -70,13 +70,13 @@ const SelectCandidatePopup = ({
7070
) : (
7171
<>
7272
<p>
73-
You have selected this applicant - you want this member on your
73+
You have selected this candidate - you want this member on your
7474
team! What happens next:
7575
</p>
7676
<ol>
7777
<li>
7878
Upon confirmation, Topcoder will confirm the arrangement with
79-
the selected member
79+
the selected candidate
8080
</li>
8181
<li>
8282
A Topcoder Rep will contact you with details on the work

src/styles/main.module.scss

+3
Original file line numberDiff line numberDiff line change
@@ -5,4 +5,7 @@
55
.topcoder-micro-frontends-teams-app {
66
@include font-roboto;
77
color: #2a2a2a;
8+
svg {
9+
pointer-events: none;
10+
}
811
}

src/utils/format.js

+14-4
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@ import _ from "lodash";
55
import { RATE_TYPE } from "constants";
66
import { EMAIL_REQUEST_EXTENSION, CONNECT_WEBSITE_URL } from "../../config";
77
import moment from "moment";
8-
import { DAY_FORMAT } from "constants/";
8+
import { DAY_FORMAT, DATE_WITH_TIME_FORMAT } from "constants/";
99

1010
/**
1111
* Format URL to the project (team) in Connect App.
@@ -233,11 +233,11 @@ export const formatDateRange = (startDate, endDate) => {
233233
* Format date
234234
*
235235
* @param {string|Date|moment.Moment} date date
236-
*
236+
* @param {string} format date/time format
237237
* @returns {string} formatted date range
238238
*/
239-
export const formatDate = (date) => {
240-
const dateStr = date ? moment(date).format(DAY_FORMAT) : "";
239+
export const formatDate = (date, format = DAY_FORMAT) => {
240+
const dateStr = date ? moment(date).format(format) : "";
241241

242242
if (!dateStr) {
243243
return "TBD";
@@ -246,6 +246,16 @@ export const formatDate = (date) => {
246246
return `${dateStr}`;
247247
};
248248

249+
/**
250+
* Format interview date/time.
251+
*
252+
* @param {string|Date|moment.Moment} date date
253+
* @returns {string} formatted date
254+
*/
255+
export const formatInterviewDate = (date) => {
256+
return formatDate(date, DATE_WITH_TIME_FORMAT);
257+
};
258+
249259
/**
250260
* Format page title to show in the browser header.
251261
*

0 commit comments

Comments
 (0)