Skip to content

Commit

Permalink
overridden: Add Banner to all pages
Browse files Browse the repository at this point in the history
  • Loading branch information
sakshamarora1 authored and kpsherva committed Oct 30, 2024
1 parent 062c0e6 commit 4ab9018
Show file tree
Hide file tree
Showing 2 changed files with 19 additions and 0 deletions.
4 changes: 4 additions & 0 deletions demo-invenioils/ui/src/overridableMapping.js
Original file line number Diff line number Diff line change
Expand Up @@ -4,11 +4,15 @@ import {
} from './overridden/components/Menu';
import { LoginDocs } from './overridden/authentication/#';
import { FeaturesRoute } from './overridden/routes/FrontsiteUrls';
import { CustomBanner } from './overridden/CustomBanner';

export const overriddenCmps = {
'SectionsWrapper.servicesInstallationSections': () => null,
'ILSMenu.RightMenuItems': RightMenuItem,
'ILSMenu.RightMenuItemsMobile': RightMenuItemMobile,
'Login.layout.extras': LoginDocs,
'FrontSite.CustomRoute': FeaturesRoute,
'Login.extras': CustomBanner,
'BackOffice.extras': CustomBanner,
'FrontSite.extras': CustomBanner,
};
15 changes: 15 additions & 0 deletions demo-invenioils/ui/src/overridden/CustomBanner.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
import React from 'react';
import { Message } from 'semantic-ui-react';

export const CustomBanner = () => {
return (
<Message className="center no-margin warning">
<div
dangerouslySetInnerHTML={{
__html:
'<i class="exclamation triangle icon"></i> This is the Invenio ILS <b>demo instance</b>: data might be periodically deleted and recreated.',
}}
/>
</Message>
);
};

0 comments on commit 4ab9018

Please # to comment.