diff --git a/src/Header.css b/src/Header.css index 39647b385..8288736f9 100644 --- a/src/Header.css +++ b/src/Header.css @@ -44,3 +44,9 @@ #menu-lines { padding: 0 40px; } + +.Header__info-banner { + padding-left: 0; + padding-right: 0; + max-width: 1200px; +} diff --git a/src/InfoBanner.tsx b/src/InfoBanner.tsx new file mode 100644 index 000000000..285f6b5e8 --- /dev/null +++ b/src/InfoBanner.tsx @@ -0,0 +1,36 @@ +import React, { useState } from 'react' +import Alert from 'react-bootstrap/Alert' +import './Header.css' +import { Container } from 'react-bootstrap' +import { set as setCookie, get as getCookie } from 'es-cookie' + +function InfoBanner(): JSX.Element | null { + const initialState = getCookie('eblShowInfoBanner') !== 'false' + const [show, setShow] = useState(initialState) + + const midnight = new Date() + midnight.setHours(23, 59, 59) + + return show ? ( + + { + setShow(false) + setCookie('eblShowInfoBanner', 'false', { expires: midnight }) + }} + dismissible + > + Scheduled Maintenance Notice: On{' '} + Monday, July 15, 2024, from 10:00 AM to 12:00 PM CEST, + the eBL servers will be undergoing scheduled maintenance. During this + time, you will not be able to log in or make any changes to records. The + maintenance may also cause temporary service interruptions. Registered + users will receive an email notification once the maintenance is + complete. + + + ) : null +} + +export default InfoBanner diff --git a/src/about/ui/__snapshots__/about.test.tsx.snap b/src/about/ui/__snapshots__/about.test.tsx.snap index 5eb8acccd..d48f474bc 100644 --- a/src/about/ui/__snapshots__/about.test.tsx.snap +++ b/src/about/ui/__snapshots__/about.test.tsx.snap @@ -8,6 +8,39 @@ exports[`Snapshot 1`] = `
+
+ +
diff --git a/src/common/AppContent.tsx b/src/common/AppContent.tsx index 479984126..a643ee421 100644 --- a/src/common/AppContent.tsx +++ b/src/common/AppContent.tsx @@ -6,6 +6,7 @@ import _ from 'lodash' import Breadcrumbs, { Crumb } from 'common/Breadcrumbs' import './AppContent.sass' +import Banner from 'InfoBanner' interface Props { crumbs?: readonly Crumb[] @@ -31,6 +32,7 @@ export default function AppContent({ })} >
+

{title || _.last(crumbs)?.text}

diff --git a/src/corpus/ui/__snapshots__/ChapterView.integration.test.ts.snap b/src/corpus/ui/__snapshots__/ChapterView.integration.test.ts.snap index 15b2ad59d..c3295f06a 100644 --- a/src/corpus/ui/__snapshots__/ChapterView.integration.test.ts.snap +++ b/src/corpus/ui/__snapshots__/ChapterView.integration.test.ts.snap @@ -204,6 +204,39 @@ exports[`Display chapter How to cite 1`] = `
+
+ +
@@ -830,6 +863,39 @@ exports[`Display chapter Show manuscripts 1`] = `
+
+ +
@@ -1737,6 +1803,39 @@ exports[`Display chapter Show notes 1`] = `
+
+ +
@@ -2380,6 +2479,39 @@ exports[`Display chapter Show parallels 1`] = `
+
+ +
@@ -3028,6 +3160,39 @@ exports[`Display chapter Sidebar 1`] = `
+
+ +
@@ -4019,6 +4184,39 @@ exports[`Display chapter Sidebar 2`] = `
+
+ +
@@ -5020,6 +5218,39 @@ exports[`Display chapter Sidebar 3`] = `
+
+ +
@@ -6065,6 +6296,39 @@ exports[`Display chapter Sidebar 4`] = `
+
+ +
@@ -7144,6 +7408,39 @@ exports[`Display chapter Sidebar 5`] = `
+
+ +
@@ -8223,6 +8520,39 @@ exports[`Display chapter Sidebar 6`] = `
+
+ +
@@ -9133,6 +9463,39 @@ exports[`Display chapter Snapshot 1`] = `
+
+ +
diff --git a/src/corpus/ui/__snapshots__/Corpus.integration.test.ts.snap b/src/corpus/ui/__snapshots__/Corpus.integration.test.ts.snap index 54166f286..7c0f96f7f 100644 --- a/src/corpus/ui/__snapshots__/Corpus.integration.test.ts.snap +++ b/src/corpus/ui/__snapshots__/Corpus.integration.test.ts.snap @@ -204,6 +204,39 @@ exports[`With session 1`] = `
+
+ +
@@ -780,6 +813,39 @@ exports[`Without session 1`] = `
+
+ +
diff --git a/src/corpus/ui/__snapshots__/TextView.integration.test.ts.snap b/src/corpus/ui/__snapshots__/TextView.integration.test.ts.snap index 0a441cd55..ec0a228d1 100644 --- a/src/corpus/ui/__snapshots__/TextView.integration.test.ts.snap +++ b/src/corpus/ui/__snapshots__/TextView.integration.test.ts.snap @@ -204,6 +204,39 @@ exports[`Chapter Show chapter 1`] = `
+
+ +
@@ -587,6 +620,39 @@ exports[`Chapter Show list of manuscripts 1`] = `
+
+ +
@@ -1144,6 +1210,39 @@ exports[`With session 1`] = `
+
+ +
diff --git a/src/dictionary/ui/display/__snapshots__/WordDisplay.test.tsx.snap b/src/dictionary/ui/display/__snapshots__/WordDisplay.test.tsx.snap index 4603fd139..ca60b7a82 100644 --- a/src/dictionary/ui/display/__snapshots__/WordDisplay.test.tsx.snap +++ b/src/dictionary/ui/display/__snapshots__/WordDisplay.test.tsx.snap @@ -8,6 +8,39 @@ exports[`Fetch word correctly displays word parts 1`] = `
+
+ +
diff --git a/src/dictionary/ui/editor/__snapshots__/WordEditor.integration.test.ts.snap b/src/dictionary/ui/editor/__snapshots__/WordEditor.integration.test.ts.snap index 43886d94d..eeeeadec9 100644 --- a/src/dictionary/ui/editor/__snapshots__/WordEditor.integration.test.ts.snap +++ b/src/dictionary/ui/editor/__snapshots__/WordEditor.integration.test.ts.snap @@ -204,6 +204,39 @@ exports[`Edit 1`] = `
+
+ +
@@ -2106,6 +2139,39 @@ exports[`Snapshot 1`] = `
+
+ +
diff --git a/src/dictionary/ui/search/__snapshots__/Dictionary.integration.test.ts.snap b/src/dictionary/ui/search/__snapshots__/Dictionary.integration.test.ts.snap index b9cd571c9..63ac451c6 100644 --- a/src/dictionary/ui/search/__snapshots__/Dictionary.integration.test.ts.snap +++ b/src/dictionary/ui/search/__snapshots__/Dictionary.integration.test.ts.snap @@ -204,6 +204,39 @@ exports[`Meaning 1`] = `
+
+ +
@@ -738,6 +771,39 @@ exports[`Root 1`] = `
+
+ +
@@ -1272,6 +1338,39 @@ exports[`Snapshot 1`] = `
+
+ +
@@ -1691,6 +1790,39 @@ exports[`Vowel class 1`] = `
+
+ +
@@ -2225,6 +2357,39 @@ exports[`Word 1`] = `
+
+ +
diff --git a/src/fragmentarium/ui/image-annotation/__snapshots__/AnnotationsView.integration.test.ts.snap b/src/fragmentarium/ui/image-annotation/__snapshots__/AnnotationsView.integration.test.ts.snap index 671a7cdb3..04aec3a39 100644 --- a/src/fragmentarium/ui/image-annotation/__snapshots__/AnnotationsView.integration.test.ts.snap +++ b/src/fragmentarium/ui/image-annotation/__snapshots__/AnnotationsView.integration.test.ts.snap @@ -204,6 +204,39 @@ exports[`Display annotate view Snapshot 1`] = `
+
+ +
diff --git a/src/fragmentarium/ui/search/__snapshots__/FragmentariumSearch.test.tsx.snap b/src/fragmentarium/ui/search/__snapshots__/FragmentariumSearch.test.tsx.snap index 3eb485de8..035e4e75a 100644 --- a/src/fragmentarium/ui/search/__snapshots__/FragmentariumSearch.test.tsx.snap +++ b/src/fragmentarium/ui/search/__snapshots__/FragmentariumSearch.test.tsx.snap @@ -8,6 +8,39 @@ exports[`Searching fragments by transliteration Displays corpus results when cli
+
+ +
diff --git a/src/research-projects/subpages/__snapshots__/subpages.test.tsx.snap b/src/research-projects/subpages/__snapshots__/subpages.test.tsx.snap index 3bb28ef97..14054bcfe 100644 --- a/src/research-projects/subpages/__snapshots__/subpages.test.tsx.snap +++ b/src/research-projects/subpages/__snapshots__/subpages.test.tsx.snap @@ -8,6 +8,39 @@ exports[`Project pages displays CAIC page 1`] = `
+
+ +
diff --git a/src/signs/ui/display/__snapshots__/SignDisplay.test.tsx.snap b/src/signs/ui/display/__snapshots__/SignDisplay.test.tsx.snap index c9dd17287..c6305bb1d 100644 --- a/src/signs/ui/display/__snapshots__/SignDisplay.test.tsx.snap +++ b/src/signs/ui/display/__snapshots__/SignDisplay.test.tsx.snap @@ -8,6 +8,39 @@ exports[`Sign Display Sign Display Snapshot 1`] = `
+
+ +