Skip to content

Commit 11a5aa6

Browse files
Merge pull request #6763 from topcoder-platform/feature-timeline-wall
Remaining timeline wall features and bug fixes
2 parents d13bbea + 00bb74b commit 11a5aa6

File tree

6 files changed

+24
-9
lines changed

6 files changed

+24
-9
lines changed

src/shared/containers/timeline-wall/index.jsx

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -24,6 +24,8 @@ import './styles.scss';
2424
const FETCHING_PENDING_APPROVAL_EVENTS_INTERVAL = _.get(config, 'TIMELINE.FETCHING_PENDING_APPROVAL_EVENTS_INTERVAL', 0);
2525
const FORUM_LINK = _.get(config, 'TIMELINE.FORUM_LINK', '');
2626
function TimelineWallContainer(props) {
27+
const currentTime = new Date();
28+
const thisYear = currentTime.getFullYear();
2729
const [tab, setTab] = useState(0);
2830
const fetchingApprovalsInterval = useRef(null);
2931
const [showRightFilterMobile, setShowRightFilterMobile] = useState(false);
@@ -223,7 +225,7 @@ function TimelineWallContainer(props) {
223225
type="button"
224226
styleName="filter-dropdown hide-desktop show-mobile"
225227
>
226-
<span>{selectedFilterValue.year ? selectedFilterValue.year : ''}</span>
228+
<span>{selectedFilterValue.year ? selectedFilterValue.year : thisYear}</span>
227229
<IconCheveronDownBlue />
228230
</button>
229231
</div>

src/shared/containers/timeline-wall/modal-event-add/index.jsx

Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -3,6 +3,7 @@ import PT from 'prop-types';
33
import { Modal } from 'topcoder-react-ui-kit';
44
import IconCloseGreen from 'assets/images/icon-close-green.svg';
55
import LoadingIndicator from 'components/LoadingIndicator';
6+
import cn from 'classnames';
67

78
import style from './styles.scss';
89

@@ -17,14 +18,17 @@ function ModalEventAdd({
1718
onCancel={onClose}
1819
>
1920
<div styleName="header">
20-
<span styleName="text-title">Confirmation</span>
21+
<span styleName="text-title">{uploadResult ? 'Error' : 'Confirmation'}</span>
2122
<button styleName="btn-close" onClick={onClose} type="button"><IconCloseGreen /></button>
2223
</div>
2324
{
2425
uploading ? (
2526
<LoadingIndicator />
2627
) : (
27-
<span styleName="text-description">
28+
<span styleName={cn('text-description', {
29+
error: !!uploadResult,
30+
})}
31+
>
2832
{
2933
uploadResult || successMessage
3034
}

src/shared/containers/timeline-wall/modal-event-add/styles.scss

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -44,6 +44,10 @@
4444
strong {
4545
@include roboto-bold;
4646
}
47+
48+
&.error {
49+
color: #ef476f;
50+
}
4751
}
4852

4953
.separator {

src/shared/containers/timeline-wall/styles.scss

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -86,6 +86,7 @@
8686
border: none;
8787
color: white;
8888

89+
&:visited,
8990
&:hover {
9091
color: white;
9192
}

src/shared/containers/timeline-wall/timeline-events/right-filter/styles.scss

Lines changed: 9 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -3,6 +3,7 @@
33
.container {
44
display: flex;
55
flex-direction: column;
6+
z-index: 1;
67

78
@media (max-width: 768px) {
89
position: fixed;
@@ -53,16 +54,16 @@
5354
border-top-left-radius: 8px;
5455
border-bottom-left-radius: 8px;
5556
padding: 10px 0;
56-
position: fixed;
57-
right: 0;
58-
left: 1374px;
57+
position: sticky;
58+
margin-bottom: 80px;
59+
top: 0;
5960
max-height: 70%;
6061
overflow: scroll;
61-
-ms-overflow-style: none; /* Internet Explorer 10+ */
62-
scrollbar-width: none; /* Firefox */
62+
-ms-overflow-style: none; /* Internet Explorer 10+ */
63+
scrollbar-width: none; /* Firefox */
6364

6465
&::-webkit-scrollbar {
65-
display: none; /* Safari and Chrome */
66+
display: none; /* Safari and Chrome */
6667
}
6768

6869
@media (max-width: 1500px) {
@@ -72,6 +73,8 @@
7273
@media (max-width: 768px) {
7374
border-radius: 0;
7475
width: calc(100% - 10px);
76+
position: relative;
77+
margin-bottom: unset;
7578
}
7679

7780
span {

src/shared/containers/timeline-wall/timeline-events/styles.scss

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,7 @@
44
display: flex;
55
flex-direction: row;
66
justify-content: space-between;
7+
max-width: 1492px;
78
}
89

910
.left-content {

0 commit comments

Comments
 (0)