diff --git a/src/components/VHeader/VHeaderMobile/VHeaderMobile.vue b/src/components/VHeader/VHeaderMobile/VHeaderMobile.vue
index 8d5c397458..a5302c6dbb 100644
--- a/src/components/VHeader/VHeaderMobile/VHeaderMobile.vue
+++ b/src/components/VHeader/VHeaderMobile/VHeaderMobile.vue
@@ -292,6 +292,7 @@ export default defineComponent({
} = useDialogControl({
visibleRef: contentSettingsOpen,
nodeRef: headerRef,
+ lockBodyScroll: true,
emit,
})
diff --git a/src/layouts/content-layout.vue b/src/layouts/content-layout.vue
new file mode 100644
index 0000000000..650d212b43
--- /dev/null
+++ b/src/layouts/content-layout.vue
@@ -0,0 +1,211 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/src/layouts/default.vue b/src/layouts/default.vue
index 8bc4fba8a5..35ea07a099 100644
--- a/src/layouts/default.vue
+++ b/src/layouts/default.vue
@@ -1,62 +1,21 @@
-
-
-
-
-
-
-
-
+
-
+
-
+
-
-
-
@@ -64,60 +23,34 @@
-
-
diff --git a/src/pages/about.vue b/src/pages/about.vue
index 85e0c618ba..6235c18c20 100644
--- a/src/pages/about.vue
+++ b/src/pages/about.vue
@@ -145,6 +145,7 @@ import VContentPage from "~/components/VContentPage.vue"
export default defineComponent({
name: "AboutPage",
components: { VLink, VContentPage },
+ layout: "content-layout",
setup() {
const i18n = useI18n()
const featureFlagStore = useFeatureFlagStore()
diff --git a/src/pages/audio/_id/index.vue b/src/pages/audio/_id/index.vue
index 0842aeb1c0..0aab27294e 100644
--- a/src/pages/audio/_id/index.vue
+++ b/src/pages/audio/_id/index.vue
@@ -50,6 +50,7 @@ export default defineComponent({
}
next()
},
+ layout: "content-layout",
setup() {
const route = useRoute()
const singleResultStore = useSingleResultStore()
diff --git a/src/pages/external-sources.vue b/src/pages/external-sources.vue
index 860fa7dc95..962673468c 100644
--- a/src/pages/external-sources.vue
+++ b/src/pages/external-sources.vue
@@ -76,6 +76,7 @@ import VLink from "~/components/VLink.vue"
export default defineComponent({
name: "ExternalSourcesPage",
components: { VContentPage, VLink },
+ layout: "content-layout",
setup() {
const i18n = useI18n()
const featureFlagStore = useFeatureFlagStore()
diff --git a/src/pages/feedback.vue b/src/pages/feedback.vue
index a457d91a46..9c20fc047b 100644
--- a/src/pages/feedback.vue
+++ b/src/pages/feedback.vue
@@ -64,6 +64,7 @@ const tabs = Object.keys(forms) as (keyof typeof forms)[]
export default defineComponent({
name: "FeedbackPage",
components: { VLink, VContentPage, VTabs, VTab, VTabPanel },
+ layout: "content-layout",
setup() {
const i18n = useI18n()
const featureFlagStore = useFeatureFlagStore()
diff --git a/src/pages/image/_id/index.vue b/src/pages/image/_id/index.vue
index 23d0176fa7..896b05d429 100644
--- a/src/pages/image/_id/index.vue
+++ b/src/pages/image/_id/index.vue
@@ -137,6 +137,7 @@ export default defineComponent({
}
next()
},
+ layout: "content-layout",
setup() {
const route = useRoute()
diff --git a/src/pages/preferences.vue b/src/pages/preferences.vue
index a5f90e5531..13489636d8 100644
--- a/src/pages/preferences.vue
+++ b/src/pages/preferences.vue
@@ -87,6 +87,7 @@ export default defineComponent({
VContentPage,
VCheckbox,
},
+ layout: "content-layout",
setup() {
const { $cookies } = useContext()
const featureFlagStore = useFeatureFlagStore()
diff --git a/src/pages/privacy.vue b/src/pages/privacy.vue
index 0dea8f2bc9..712ebbd07d 100644
--- a/src/pages/privacy.vue
+++ b/src/pages/privacy.vue
@@ -56,6 +56,7 @@ import VContentPage from "~/components/VContentPage.vue"
export default defineComponent({
name: "VPrivacyPage",
components: { VLink, VContentPage },
+ layout: "content-layout",
setup() {
const i18n = useI18n()
const featureFlagStore = useFeatureFlagStore()
diff --git a/src/pages/search-help.vue b/src/pages/search-help.vue
index cff399baf4..aa1e01e835 100644
--- a/src/pages/search-help.vue
+++ b/src/pages/search-help.vue
@@ -236,6 +236,7 @@ import VContentPage from "~/components/VContentPage.vue"
export default defineComponent({
name: "VSearchHelpPage",
components: { VLink, VContentPage },
+ layout: "content-layout",
setup() {
const i18n = useI18n()
const featureFlagStore = useFeatureFlagStore()
diff --git a/src/pages/search.vue b/src/pages/search.vue
index 79e8af051a..ab29472700 100644
--- a/src/pages/search.vue
+++ b/src/pages/search.vue
@@ -68,6 +68,7 @@ export default defineComponent({
}
next()
},
+ layout: "content-layout",
middleware({ route, redirect }) {
/**
* This anonymous middleware redirects any search without a query to the homepage.
diff --git a/src/pages/sources.vue b/src/pages/sources.vue
index 11a98036c2..f40fa24e0f 100644
--- a/src/pages/sources.vue
+++ b/src/pages/sources.vue
@@ -104,6 +104,7 @@ import externalLinkIcon from "~/assets/icons/external-link.svg"
export default defineComponent({
name: "SourcePage",
components: { VButton, VContentPage, VIcon, VLink, VSourcesTable },
+ layout: "content-layout",
setup() {
const i18n = useI18n()
const featureFlagStore = useFeatureFlagStore()
diff --git a/test/playwright/visual-regression/pages/pages.spec.ts b/test/playwright/visual-regression/pages/pages.spec.ts
index d61a6bb4f4..e2f5864f6e 100644
--- a/test/playwright/visual-regression/pages/pages.spec.ts
+++ b/test/playwright/visual-regression/pages/pages.spec.ts
@@ -1,4 +1,4 @@
-import { expect, test } from "@playwright/test"
+import { expect, Page, test } from "@playwright/test"
import breakpoints from "~~/test/playwright/utils/breakpoints"
import { removeHiddenOverflow } from "~~/test/playwright/utils/page"
@@ -47,6 +47,13 @@ for (const contentPage of contentPages) {
}
}
+const cleanImageResults = async (page: Page) => {
+ await page.addStyleTag({
+ content: ".results-grid img { filter: brightness(0%); }",
+ })
+ await page.waitForTimeout(500)
+}
+
test.describe("Layout color is set correctly", () => {
breakpoints.describeLg(() => {
test.use({
@@ -61,8 +68,13 @@ test.describe("Layout color is set correctly", () => {
await page.getByRole("combobox", { name: "Language" }).selectOption("ar")
await page.getByPlaceholder("البحث عن محتوى").fill("cat")
- await page.getByRole("button", { name: "يبحث" }).click()
- await page.waitForNavigation()
+
+ await Promise.all([
+ page.waitForNavigation(),
+ page.getByRole("button", { name: "يبحث" }).click(),
+ ])
+
+ await cleanImageResults(page)
expect(await page.screenshot()).toMatchSnapshot("search-page-rtl-lg.png")
})
diff --git a/test/playwright/visual-regression/pages/pages.spec.ts-snapshots/search-page-rtl-lg-linux.png b/test/playwright/visual-regression/pages/pages.spec.ts-snapshots/search-page-rtl-lg-linux.png
index 33158bc49f..dd04bbd1b0 100644
Binary files a/test/playwright/visual-regression/pages/pages.spec.ts-snapshots/search-page-rtl-lg-linux.png and b/test/playwright/visual-regression/pages/pages.spec.ts-snapshots/search-page-rtl-lg-linux.png differ