Skip to content

Commit ae6a0ca

Browse files
authored
Merge pull request #3532 from processing/banner-fixes
Banner fixes
2 parents 74e6a84 + 00e8c00 commit ae6a0ca

File tree

5 files changed

+18
-16
lines changed

5 files changed

+18
-16
lines changed

client/common/icons.jsx

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -35,20 +35,20 @@ import Copy from '../images/copy.svg';
3535
function withLabel(SvgComponent) {
3636
const StyledIcon = styled(SvgComponent)`
3737
&&& {
38-
color: ${prop('Icon.default')};
38+
color: ${(props) => props.Icon?.default};
3939
& g,
4040
& path,
4141
& polygon {
4242
opacity: 1;
43-
fill: ${prop('Icon.default')};
43+
fill: ${(props) => props.Icon?.default};
4444
}
4545
&:hover {
46-
color: ${prop('Icon.hover')};
46+
color: ${(props) => props.Icon?.hover};
4747
& g,
4848
& path,
4949
& polygon {
5050
opacity: 1;
51-
fill: ${prop('Icon.hover')};
51+
fill: ${(props) => props.Icon?.hover};
5252
}
5353
}
5454
}

client/images/cross.svg

Lines changed: 1 addition & 1 deletion
Loading

client/modules/IDE/components/Banner.jsx

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -26,8 +26,8 @@ const Banner = ({ onClose }) => {
2626
const bannerURL = 'https://openprocessing.org/curation/89576';
2727
const bannerCopy = (
2828
<>
29-
We’re accepting p5.js sketches for a special curation exploring the new
30-
features in p5.js 2.0!{' '}
29+
We’re accepting p5.js sketches for a special curation exploring mental
30+
health and the newest features in p5.js 2.0!{' '}
3131
<span style={{ fontWeight: 600 }}>Submit by July 13!</span>
3232
</>
3333
);
@@ -36,7 +36,7 @@ const Banner = ({ onClose }) => {
3636
<div className="banner">
3737
<a href={bannerURL}>{bannerCopy}</a>
3838
<button className="banner-close-button" onClick={onClose}>
39-
<CrossIcon />
39+
<CrossIcon Icon={{ default: '#000', hover: '#333' }} />
4040
</button>
4141
</div>
4242
);

client/modules/IDE/components/Header/__snapshots__/Nav.unit.test.jsx.snap

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -335,7 +335,7 @@ exports[`Nav renders dashboard version for mobile 1`] = `
335335
>
336336
<test-file-stub
337337
aria-hidden="true"
338-
classname="icons__StyledIcon-sc-xmer15-0 dStXqm"
338+
classname="icons__StyledIcon-sc-xmer15-0 kjSZIe"
339339
focusable="false"
340340
/>
341341
</button>
@@ -351,7 +351,7 @@ exports[`Nav renders dashboard version for mobile 1`] = `
351351
>
352352
<test-file-stub
353353
aria-hidden="true"
354-
classname="icons__StyledIcon-sc-xmer15-0 dStXqm"
354+
classname="icons__StyledIcon-sc-xmer15-0 kjSZIe"
355355
focusable="false"
356356
/>
357357
</button>
@@ -930,7 +930,7 @@ exports[`Nav renders editor version for mobile 1`] = `
930930
>
931931
<test-file-stub
932932
aria-hidden="true"
933-
classname="icons__StyledIcon-sc-xmer15-0 dStXqm"
933+
classname="icons__StyledIcon-sc-xmer15-0 kjSZIe"
934934
focusable="false"
935935
/>
936936
</button>
@@ -946,7 +946,7 @@ exports[`Nav renders editor version for mobile 1`] = `
946946
>
947947
<test-file-stub
948948
aria-hidden="true"
949-
classname="icons__StyledIcon-sc-xmer15-0 dStXqm"
949+
classname="icons__StyledIcon-sc-xmer15-0 kjSZIe"
950950
focusable="false"
951951
/>
952952
</button>

client/styles/components/_banner.scss

Lines changed: 6 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -7,11 +7,12 @@
77
border-bottom: 1px solid #000;
88

99
a {
10-
color: #000;
11-
}
10+
color: $black;
1211

13-
a:hover {
14-
text-decoration: underline;
12+
&:hover {
13+
color: $black;
14+
text-decoration: underline;
15+
}
1516
}
1617

1718
@media (max-width: 770px) {
@@ -27,4 +28,5 @@
2728
height: 20px;
2829
width:20px;
2930
float: right;
31+
cursor: pointer;
3032
}

0 commit comments

Comments
 (0)