fix: show default theme for donation related pages (#37956)

* fix: show default theme for donation related pages

* feat: add default theme to stripForm
This commit is contained in:
Ahmad Abdolsaheb
2019-12-18 17:40:48 +03:00
committed by GitHub
parent 8db0f89634
commit 1289d35435
2 changed files with 6 additions and 2 deletions

View File

@ -13,7 +13,7 @@ function YearEndGiftPage() {
<main> <main>
<Spacer /> <Spacer />
<FullWidthRow> <FullWidthRow>
<YearEndDonationForm /> <YearEndDonationForm defaultTheme='light' />
</FullWidthRow> </FullWidthRow>
<Spacer /> <Spacer />
<Spacer /> <Spacer />

View File

@ -29,7 +29,11 @@ export default function layoutSelector({ element, props }) {
</DefaultLayout> </DefaultLayout>
); );
} }
if (/^\/donation(\/.*)*|^\/donate(\/.*)*/.test(pathname)) { if (
/^\/donation(\/.*)*|^\/donate(\/.*)*/.test(pathname) ||
/^\/year-end-gift-successful(\/.*)*/.test(pathname) ||
/^\/year-end-gift(\/.*)*/.test(pathname)
) {
return ( return (
<DefaultLayout pathname={pathname} useTheme={false}> <DefaultLayout pathname={pathname} useTheme={false}>
{element} {element}