feat(SW-237): Implemented page based toggle for BW
This commit is contained in:
@@ -0,0 +1,5 @@
|
||||
import BookingWidgetContainer from "@/components/BookingWidgetContainer"
|
||||
|
||||
export default function BookingWidgetPage() {
|
||||
return <BookingWidgetContainer />
|
||||
}
|
||||
@@ -0,0 +1,3 @@
|
||||
export default function DefaultBookingWidgetPage() {
|
||||
return null
|
||||
}
|
||||
@@ -3,18 +3,23 @@ import Sidebar from "@/components/MyPages/Sidebar"
|
||||
import styles from "./layout.module.css"
|
||||
|
||||
export default async function MyPagesLayout({
|
||||
bookingwidget,
|
||||
breadcrumbs,
|
||||
children,
|
||||
}: React.PropsWithChildren & {
|
||||
bookingwidget: React.ReactNode
|
||||
breadcrumbs: React.ReactNode
|
||||
}) {
|
||||
return (
|
||||
<section className={styles.layout}>
|
||||
{breadcrumbs}
|
||||
<section className={styles.content}>
|
||||
<Sidebar />
|
||||
{children}
|
||||
<>
|
||||
{bookingwidget}
|
||||
<section className={styles.layout}>
|
||||
{breadcrumbs}
|
||||
<section className={styles.content}>
|
||||
<Sidebar />
|
||||
{children}
|
||||
</section>
|
||||
</section>
|
||||
</section>
|
||||
</>
|
||||
)
|
||||
}
|
||||
|
||||
@@ -1,3 +1,5 @@
|
||||
import BookingWidgetContainer from "@/components/BookingWidgetContainer"
|
||||
|
||||
import styles from "./layout.module.css"
|
||||
|
||||
import {
|
||||
@@ -16,9 +18,12 @@ export default function ContentTypeLayout({
|
||||
}
|
||||
>) {
|
||||
return (
|
||||
<section className={styles.layout}>
|
||||
{breadcrumbs}
|
||||
{children}
|
||||
</section>
|
||||
<>
|
||||
<BookingWidgetContainer />
|
||||
<section className={styles.layout}>
|
||||
{breadcrumbs}
|
||||
{children}
|
||||
</section>
|
||||
</>
|
||||
)
|
||||
}
|
||||
|
||||
@@ -1,3 +1,5 @@
|
||||
import BookingWidgetContainer from "@/components/BookingWidgetContainer"
|
||||
|
||||
import styles from "./layout.module.css"
|
||||
|
||||
import { LangParams, LayoutArgs } from "@/types/params"
|
||||
@@ -5,5 +7,10 @@ import { LangParams, LayoutArgs } from "@/types/params"
|
||||
export default function HotelReservationLayout({
|
||||
children,
|
||||
}: React.PropsWithChildren<LayoutArgs<LangParams>>) {
|
||||
return <div className={styles.layout}>{children}</div>
|
||||
return (
|
||||
<>
|
||||
<BookingWidgetContainer />
|
||||
<div className={styles.layout}>{children}</div>
|
||||
</>
|
||||
)
|
||||
}
|
||||
|
||||
@@ -4,6 +4,7 @@ import "@scandic-hotels/design-system/style.css"
|
||||
import Script from "next/script"
|
||||
|
||||
import TokenRefresher from "@/components/Auth/TokenRefresher"
|
||||
import BookingWidgetContainer from "@/components/BookingWidgetContainer"
|
||||
import AdobeScript from "@/components/Current/AdobeScript"
|
||||
import Footer from "@/components/Current/Footer"
|
||||
import Header from "@/components/Current/Header"
|
||||
@@ -71,6 +72,7 @@ export default async function RootLayout({
|
||||
myPagesMobileDropdown={myPagesMobileDropdown}
|
||||
languageSwitcher={languageSwitcher}
|
||||
/>
|
||||
<BookingWidgetContainer />
|
||||
{children}
|
||||
<Footer />
|
||||
<TokenRefresher />
|
||||
|
||||
Reference in New Issue
Block a user