Skip to content

Commit

Permalink
add banner for newsletter
Browse files Browse the repository at this point in the history
  • Loading branch information
alisman committed Apr 5, 2024
1 parent 1c126fc commit 3d4f700
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 18 deletions.
21 changes: 4 additions & 17 deletions src/shared/components/userMessager/UserMessage.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,7 @@ import classNames from 'classnames';
import { Portal } from 'react-portal';
import { getBrowserWindow, MobxPromise } from 'cbioportal-frontend-commons';
import ExtendedRouterStore from 'shared/lib/ExtendedRouterStore';
import { getServerConfig } from 'config/config';

export interface IUserMessage {
dateStart?: number;
Expand Down Expand Up @@ -38,25 +39,11 @@ if (

{
dateEnd: 100000000000000,
content: `P and q-values on this page have changed recently. The 1-sided Fisher exact test is now a 2-sided test
(<a href="https://docs.cbioportal.org/news/#aug-1-2023" target="_blank">Read more</a>).`,
content: `Re-introducing the cBioPortal Newsletter! Subscribe via <a href="https://www.linkedin.com/pulse/april-update-hello-cbioportal-community-cbioportal-22vle/" target="_blank">LinkedIn</a> or <a href="https://groups.google.com/g/cbioportal-news" target="_blank">Google Groups</a>`,
showCondition: routingStore => {
return _.some(
[
/comparison_subtab=alterations/i,
/results\/mutualExclusivity/i,
/comparison\/alterations/i,
/comparison\/mutations/i,
],
(re: RegExp) => {
return re.test(
routingStore.location.pathname +
routingStore.location.search
);
}
);
return getServerConfig().app_name === 'public-portal';
},
id: '2023_qval_change',
id: '2024_newsletter_intro',
},
];

Expand Down
3 changes: 2 additions & 1 deletion src/shared/components/userMessager/styles.module.scss
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,8 @@
a {
color: lightblue;

&:hover {
&:hover,
&:visited {
color: lightblue;
opacity: 0.6;
}
Expand Down

0 comments on commit 3d4f700

Please sign in to comment.