-
- Challenge Name
-
- {
- !isCopilot ? (
-
Placement
- ) : null
- }
-
- TCO Points
+ this.state = {
+ sortParam: {
+ order: '',
+ field: '',
+ },
+ };
+ }
+
+ render() {
+ const {
+ challenges,
+ competitor,
+ onCancel,
+ loading,
+ isCopilot,
+ isAlgo,
+ } = this.props;
+ const { sortParam } = this.state;
+ const challengesOrdered = _.orderBy(challenges, [sortParam.field], [sortParam.order]);
+
+ return (
+
+
+ Completed Challenges History
+
+
-
-
- {
- challenges.map(challenge => (
-
-
+
+
+
+ Challenge Name
{
!isCopilot ? (
- {challenge.place}
+
+
+
Placement
+
{
+ if (!sortParam.field || sortParam.field !== 'place') {
+ sortParam.field = 'place';
+ sortParam.order = 'desc';
+ } else {
+ sortParam.order = sortParam.order === 'asc' ? 'desc' : 'asc';
+ }
+ this.setState({ sortParam });
+ }}
+ type="button"
+ >
+
+
+
+
+
) : null
}
-
- {challenge.points}
-
-
- ))
+
+
+
Points
+
{
+ if (!sortParam.field || sortParam.field !== 'points') {
+ sortParam.field = 'points';
+ sortParam.order = 'desc';
+ } else {
+ sortParam.order = sortParam.order === 'asc' ? 'desc' : 'asc';
+ }
+ this.setState({ sortParam });
+ }}
+ type="button"
+ >
+
+
+
+
+
+
+
+
+ {
+ challengesOrdered.map(challenge => (
+
+
+
+ {challenge.challenge_name || challenge.challenge_id}
+
+
+ {
+ !isCopilot ? (
+ {challenge.place}
+ ) : null
+ }
+
+ {challenge.points}
+
+
+ ))
+ }
+
+
+ {
+ loading ?
: null
}
-
- {
- loading ?
: null
- }
-
-
- );
+
+
+ Return to page
+
+
+
+ );
+ }
}
const CHALLENGES_TYPE = PT.arrayOf(PT.shape({
diff --git a/src/shared/components/Leaderboard/ChallengeHistoryModal/styles.scss b/src/shared/components/Leaderboard/ChallengeHistoryModal/styles.scss
index 6ef72af9aa..a0eb6e36df 100644
--- a/src/shared/components/Leaderboard/ChallengeHistoryModal/styles.scss
+++ b/src/shared/components/Leaderboard/ChallengeHistoryModal/styles.scss
@@ -1,75 +1,60 @@
@import "~styles/mixins";
-.col-1 {
- padding: 0 30px;
- width: 55%;
-
- .challenge-name {
- color: $tc-gray-90;
- font-weight: 700;
- }
-
- @media (max-width: 768px) {
- padding-left: 2 * $base-unit;
- }
-}
-
-.col-2 {
- width: 22.5%;
- text-align: center;
-}
-
-.col-3 {
- color: $tc-gray-40;
- width: 22.5%;
- text-align: center;
-}
-
-.body {
- border: $tc-gray-10 1px solid;
-}
-
-.buttons {
- margin-top: 10px;
- display: flex;
- flex-direction: row;
- justify-content: center;
-}
+$light-gray: #d4d4d4;
.container {
@include roboto-regular;
color: $tc-gray-50;
background: $tc-white;
- border-radius: 3 * $corner-radius 3 * $corner-radius;
+ border-radius: 10px;
top: 50%;
width: 70%;
max-height: 90%;
overflow-y: auto;
+ padding: 80px 78px;
@media (max-width: 768px) {
width: 80%;
}
- h1 {
- color: $tc-gray-80;
+ h3 {
+ color: #1e94a3;
+ font-family: BarlowCondensed, sans-serif;
+ font-size: 34px;
+ font-weight: 500;
+ line-height: 38px;
text-align: center;
- font-size: 22px;
- font-weight: 400;
- margin-bottom: 10px;
+ margin-bottom: 60px;
+ text-transform: uppercase;
@media (max-width: 768px) {
- font-size: 4vw;
+ font-size: 31px !important;
+ font-weight: 500 !important;
+ line-height: 33px !important;
+ margin-bottom: 30px;
}
}
}
+.overlay {
+ background-color: #2a2a2a;
+ opacity: 0.95;
+ border: none;
+ height: 100%;
+ left: 0;
+ outline: none;
+ position: fixed;
+ top: 0;
+ width: 100%;
+ z-index: 998;
+}
+
.podium-spot-wrapper {
text-align: center;
display: flex;
justify-content: center;
- margin-top: 15px;
- margin-bottom: 1em;
+ margin-bottom: 50px;
> div > span {
height: 128px;
@@ -86,51 +71,119 @@
}
}
-.head {
- background: $tc-gray-neutral-light;
- border: $tc-gray-10 1px solid;
- border-bottom: none;
- color: $tc-gray-40;
- font-weight: 400;
- font-size: 13px;
- line-height: 15px;
- padding: 12.5px 0;
+.history-table {
+ width: 100%;
+ margin-bottom: 62px;
+
+ thead {
+ th {
+ color: #2a2a2a;
+ font-family: Roboto, sans-serif;
+ font-size: 14px;
+ font-weight: 500;
+ letter-spacing: 0.5px;
+ line-height: 18px;
+ text-align: left;
+ text-transform: uppercase;
+ border-bottom: 1px solid #d4d4d4;
+ padding-bottom: 15px;
+ }
+ }
+
+ .row {
+ border-bottom: 1px solid #d4d4d4;
+
+ .name {
+ .link {
+ color: #0d61bf;
+ font-size: 14px;
+ font-weight: 400;
+ line-height: 51px;
+ text-decoration: underline;
+
+ &:hover {
+ text-decoration: none;
+ }
+ }
+ }
+
+ .placement {
+ color: #2a2a2a;
+ font-size: 14px;
+ font-weight: 500;
+ line-height: 51px;
+ }
+
+ .points {
+ color: #2a2a2a;
+ font-size: 14px;
+ font-weight: 400;
+ line-height: 51px;
+ }
+ }
+}
+
+.buttons {
+ margin-top: 10px;
display: flex;
+ flex-direction: row;
+ justify-content: center;
- @media (max-width: 768px) {
- font-size: 3vw;
- padding: 2 * $base-unit 0;
+ .close-btn {
+ color: #fafafb;
+ font-family: Roboto, sans-serif;
+ font-size: 14px;
+ font-weight: 700;
+ letter-spacing: 0.8px;
+ line-height: 40px;
+ background-color: #137d60;
+ border-radius: 20px;
+ border: none;
+ text-transform: uppercase;
+ padding: 0 20px;
+
+ &:hover {
+ background-color: #0ab88a !important;
+ box-shadow: 0 1px 5px 0 rgba(0, 0, 0, 0.2);
+ }
}
}
-.row {
+.header-table-content {
display: flex;
align-items: center;
- line-height: 40px;
- color: $tc-gray-70;
- font-size: 15px;
- border-bottom: 1px solid $tc-gray-10;
+}
- @media (max-width: 768px) {
- font-size: 3vw;
- }
+.sort-container {
+ display: flex;
+ flex-direction: column;
+ margin-left: 5px;
+ padding: 0;
+ border: none;
+ outline: none;
+ background: transparent;
}
-.title {
- color: $tc-gray-50;
- font-size: 13px;
- line-height: 15px;
- font-weight: 500;
+.sort-container > div {
+ width: 0;
+ height: 0;
+ border-left: 4px solid transparent;
+ border-right: 4px solid transparent;
+}
+
+.sort-up {
+ border-bottom: 4px solid $light-gray;
+ margin-bottom: 2px;
+
+ &.active {
+ border-bottom: 4px solid $tc-black;
+ }
}
-.link {
- color: #0681ff;
- display: block;
- line-height: 1.5;
+.sort-down {
+ border-top: 4px solid $light-gray;
- &:visited,
- &:hover,
- &:active {
- color: #0681ff;
+ &.active {
+ border-top: 4px solid $tc-black;
}
}
diff --git a/src/shared/components/NewsletterArchive/index.jsx b/src/shared/components/NewsletterArchive/index.jsx
index f38a745761..7e4c9cc089 100644
--- a/src/shared/components/NewsletterArchive/index.jsx
+++ b/src/shared/components/NewsletterArchive/index.jsx
@@ -1,36 +1,118 @@
import _ from 'lodash';
import moment from 'moment';
-import React, { Fragment } from 'react';
+import React, { Component } from 'react';
import PT from 'prop-types';
import { themr } from 'react-css-super-themr';
+import cn from 'classnames';
import defaultStyle from './style.scss';
/* Date/time format to use in the link. */
-const FORMAT = 'MMM DD, HH:mm';
+const FORMAT = 'MMM DD, YYYY';
-function NewsletterArchive({
- archive,
-}) {
-// console.log(archive)
- return _.map(
- archive.campaigns,
- (link, indx) => (
-
-
- {link.settings.title}
-
- Sent: {moment(link.send_time).format(FORMAT)}
-
- ),
- );
-}
+class NewsletterArchive extends Component {
+ constructor(props) {
+ super(props);
-NewsletterArchive.defaultProps = {
- token: null,
-};
+ this.state = {
+ sortParam: {
+ order: '',
+ field: '',
+ },
+ };
+ }
+
+ render() {
+ const {
+ archive,
+ } = this.props;
+ const { sortParam } = this.state;
+ const archiveOrdered = _.orderBy(archive.campaigns, [sortParam.field], [sortParam.order]);
+
+ return (
+
+
+
+ Item
+
+
+
NEWSLETTER
+
{
+ if (!sortParam.field || sortParam.field !== 'settings.title') {
+ sortParam.field = 'settings.title';
+ sortParam.order = 'desc';
+ } else {
+ sortParam.order = sortParam.order === 'asc' ? 'desc' : 'asc';
+ }
+ this.setState({ sortParam });
+ }}
+ type="button"
+ >
+
+
+
+
+
+
+
+
SEND DATE
+
{
+ if (!sortParam.field || sortParam.field !== 'send_time') {
+ sortParam.field = 'send_time';
+ sortParam.order = 'desc';
+ } else {
+ sortParam.order = sortParam.order === 'asc' ? 'desc' : 'asc';
+ }
+ this.setState({ sortParam });
+ }}
+ type="button"
+ >
+
+
+
+
+
+
+
+
+ {
+ archiveOrdered.map((archiveItem, indx) => (
+
+ {indx + 1}
+
+
+ {archiveItem.settings.title}
+
+
+
+ {moment(archiveItem.send_time).format(FORMAT)}
+
+
+ ))
+ }
+
+
+ );
+ }
+}
NewsletterArchive.propTypes = {
- archive: PT.shape().isRequired,
+ archive: PT.arrayOf().isRequired,
};
export default themr('NewsletterArchive', defaultStyle)(NewsletterArchive);
diff --git a/src/shared/components/NewsletterArchive/style.scss b/src/shared/components/NewsletterArchive/style.scss
index e55b8bff9d..6c0292052c 100644
--- a/src/shared/components/NewsletterArchive/style.scss
+++ b/src/shared/components/NewsletterArchive/style.scss
@@ -1,5 +1,7 @@
@import "~styles/mixins";
+$light-gray: #d4d4d4;
+
.archive-link {
display: block;
font-size: 15px;
@@ -20,3 +22,93 @@
margin-bottom: 10px;
display: block;
}
+
+.history-table {
+ width: 100%;
+ margin-bottom: 62px;
+
+ thead {
+ th {
+ color: #2a2a2a;
+ font-family: Roboto, sans-serif;
+ font-size: 14px;
+ font-weight: 500;
+ letter-spacing: 0.5px;
+ line-height: 18px;
+ text-align: left;
+ text-transform: uppercase;
+ border-bottom: 1px solid #d4d4d4;
+ padding-bottom: 15px;
+ }
+ }
+
+ .row {
+ border-bottom: 1px solid #d4d4d4;
+
+ td {
+ padding: 0;
+ border-bottom: 1px solid #d4d4d4;
+ }
+
+ .name {
+ .archive-link {
+ color: #0d61bf;
+ font-size: 14px;
+ font-weight: 500;
+ line-height: 51px;
+ text-decoration: underline;
+
+ &:hover {
+ text-decoration: none;
+ }
+ }
+ }
+
+ .index,
+ .sent-date {
+ color: #2a2a2a;
+ font-size: 14px;
+ font-weight: 400;
+ line-height: 51px;
+ }
+ }
+}
+
+.header-table-content {
+ display: flex;
+ align-items: center;
+}
+
+.sort-container {
+ display: flex;
+ flex-direction: column;
+ margin-left: 5px;
+ padding: 0;
+ border: none;
+ outline: none;
+ background: transparent;
+}
+
+.sort-container > div {
+ width: 0;
+ height: 0;
+ border-left: 4px solid transparent;
+ border-right: 4px solid transparent;
+}
+
+.sort-up {
+ border-bottom: 4px solid $light-gray;
+ margin-bottom: 2px;
+
+ &.active {
+ border-bottom: 4px solid $tc-black;
+ }
+}
+
+.sort-down {
+ border-top: 4px solid $light-gray;
+
+ &.active {
+ border-top: 4px solid $tc-black;
+ }
+}
diff --git a/src/shared/components/TopcoderFooter/index.jsx b/src/shared/components/TopcoderFooter/index.jsx
index 6f97a5c674..e079531f08 100644
--- a/src/shared/components/TopcoderFooter/index.jsx
+++ b/src/shared/components/TopcoderFooter/index.jsx
@@ -91,6 +91,7 @@ export default function TopcoderFooter() {
About Community
Changelog
Talk to Sales
+
Terms
diff --git a/src/shared/components/challenge-detail/Specification/index.jsx b/src/shared/components/challenge-detail/Specification/index.jsx
index 3f425545c8..5c9af5d04a 100644
--- a/src/shared/components/challenge-detail/Specification/index.jsx
+++ b/src/shared/components/challenge-detail/Specification/index.jsx
@@ -1,3 +1,4 @@
+/* eslint-disable max-len */
/*
Component renders challenge details and specifications
*/
@@ -468,41 +469,21 @@ export default function ChallengeDetailsView(props) {
) : (
- Topcoder will compensate members in accordance with our
- standard payment policies, unless otherwise specified in this
- challenge. For information on payment policies, setting up your
- profile to receive payments, and general payment questions,
- please refer to
+ Topcoder will compensate members in accordance with our standard payment policies, unless
+ otherwise specified in this challenge. For information on payment policies, setting up your profile to
+ receive payments, and general payment questions, please refer to
- https://www.topcoder.com/thrive/articles/Payment%20Policies%20and%20Instructions
-
+ Payment Policies and Instructions
+ .
)
}
-
-
- Reliability Rating and Bonus
-
-
- For challenges that have a reliability bonus, the bonus depends
- on the reliability rating at the moment of registration for that
- project. A participant with no previous projects is considered to
- have no reliability rating, and therefore gets no bonus.
- Reliability bonus does not apply to Digital Run winnings. Since
- reliability rating is based on the past 15 projects, it can only
- have 15 discrete values.
-
-
- Read more.
-
-
-