diff --git a/client/src/components/Header/header.css b/client/src/components/Header/header.css index 29ed47851b4..34010ecf6de 100644 --- a/client/src/components/Header/header.css +++ b/client/src/components/Header/header.css @@ -4,3 +4,15 @@ header { width: 100%; z-index: 200; } +.skip-to-content-button { + position: absolute; + top: var(--header-height); + border-radius: 15px; + font-weight: 600; + padding-block: 1em; + padding-inline: 1.5em; + left: -1000px; +} +.skip-to-content-button:focus { + left: 0px; +} diff --git a/client/src/components/Header/index.tsx b/client/src/components/Header/index.tsx index 6b9bed4da48..01644bbf54a 100644 --- a/client/src/components/Header/index.tsx +++ b/client/src/components/Header/index.tsx @@ -91,6 +91,9 @@ export class Header extends React.Component<
+ + Skip To Content + -

+

{name ? `${t('learn.welcome-1', { name: name })}` : `${t('learn.welcome-2')}`} diff --git a/client/src/components/layouts/default.tsx b/client/src/components/layouts/default.tsx index c6588e8d60f..557738f4ad7 100644 --- a/client/src/components/layouts/default.tsx +++ b/client/src/components/layouts/default.tsx @@ -26,6 +26,7 @@ import { userFetchStateSelector } from '../../redux/selectors'; import { UserFetchState, User } from '../../redux/prop-types'; +import BreadCrumb from '../../templates/Challenges/components/bread-crumb'; import Flash from '../Flash'; import { flashMessageSelector, removeFlashMessage } from '../Flash/redux'; @@ -84,6 +85,9 @@ interface DefaultLayoutProps extends StateProps, DispatchProps { children: ReactNode; pathname: string; showFooter?: boolean; + isChallenge?: boolean; + block?: string; + superBlock?: string; t: TFunction; useTheme?: boolean; } @@ -133,6 +137,9 @@ class DefaultLayout extends Component { isSignedIn, removeFlashMessage, showFooter = true, + isChallenge = false, + block, + superBlock, t, theme = 'default', user, @@ -211,7 +218,17 @@ class DefaultLayout extends Component { removeFlashMessage={removeFlashMessage} /> ) : null} - {fetchState.complete && children} + {isChallenge && ( +
+ +
+ )} +
+ {fetchState.complete && children} +
{showFooter &&