diff --git a/packages/gitbook/e2e/internal.spec.ts b/packages/gitbook/e2e/internal.spec.ts index 3350eabf1..4b52103c8 100644 --- a/packages/gitbook/e2e/internal.spec.ts +++ b/packages/gitbook/e2e/internal.spec.ts @@ -149,6 +149,7 @@ const searchTestCases: Test[] = [ mode: CustomizationAIMode.Assistant, }, }), + screenshot: false, run: async (page) => { await waitForCookiesDialog(page); const searchInput = page.locator('css=[data-testid="search-input"]'); @@ -185,6 +186,7 @@ const searchTestCases: Test[] = [ mode: CustomizationAIMode.Assistant, }, }), + screenshot: false, run: async (page) => { await waitForCookiesDialog(page); await page.keyboard.press('ControlOrMeta+I'); @@ -218,6 +220,7 @@ const searchTestCases: Test[] = [ mode: CustomizationAIMode.Assistant, }, })}&ask=`, + screenshot: false, run: async (page) => { await waitForCookiesDialog(page); await expect(page.getByTestId('search-input')).not.toBeFocused(); @@ -235,6 +238,7 @@ const searchTestCases: Test[] = [ mode: CustomizationAIMode.Assistant, }, })}&ask=${encodeURIComponent(AI_PROMPT)}`, + screenshot: false, run: async (page) => { await waitForCookiesDialog(page); await expect(page.getByTestId('search-input')).not.toBeFocused(); diff --git a/packages/gitbook/src/components/Ads/AdCoverRendering.tsx b/packages/gitbook/src/components/Ads/AdCoverRendering.tsx index 7c03b7594..02143a5b3 100644 --- a/packages/gitbook/src/components/Ads/AdCoverRendering.tsx +++ b/packages/gitbook/src/components/Ads/AdCoverRendering.tsx @@ -77,7 +77,8 @@ export async function AdCoverRendering({ 'shadow-md', 'max-h-32', 'group-hover/ad:max-h-16', - 'motion-safe:transition-all' + 'transition-all', + 'motion-reduce:transition-none' )} /> @@ -93,7 +94,8 @@ export async function AdCoverRendering({ 'opacity-0', 'group-hover/ad:h-16', 'group-hover/ad:opacity-10', - 'motion-safe:transition-all' + 'transition-all', + 'motion-reduce:transition-none' )} > {ad.description} diff --git a/packages/gitbook/src/components/Announcement/AnnouncementBanner.tsx b/packages/gitbook/src/components/Announcement/AnnouncementBanner.tsx index 9112aa352..e1e2996ad 100644 --- a/packages/gitbook/src/components/Announcement/AnnouncementBanner.tsx +++ b/packages/gitbook/src/components/Announcement/AnnouncementBanner.tsx @@ -34,7 +34,7 @@ export function AnnouncementBanner(props: { className="theme-bold:bg-header-background pt-4 pb-2" data-nosnippet="" > -
+
+
{children}
); diff --git a/packages/gitbook/src/components/Footer/Footer.tsx b/packages/gitbook/src/components/Footer/Footer.tsx index cd73a0063..c50b68f8e 100644 --- a/packages/gitbook/src/components/Footer/Footer.tsx +++ b/packages/gitbook/src/components/Footer/Footer.tsx @@ -35,7 +35,7 @@ export function Footer(props: { context: GitBookSiteContext }) { mobileOnly ? 'xl:hidden' : null )} > -
+
-
+
@@ -120,7 +120,7 @@ export function Header(props: { 'justify-self-end', 'items-center', 'gap-2', - 'transition-[margin] duration-300', + 'transition-[margin] duration-300 motion-reduce:transition-none', 'search' in customization.styling && customization.styling.search === 'prominent' ? [ @@ -201,7 +201,7 @@ export function Header(props: {
{visibleSections && withSections ? ( -
+
{variants.translations.length > 1 ? ( +

{(() => { switch (state.status) { case 'pending': diff --git a/packages/gitbook/src/components/PageAside/PageAside.tsx b/packages/gitbook/src/components/PageAside/PageAside.tsx index 8874c6ba0..a69a2e56e 100644 --- a/packages/gitbook/src/components/PageAside/PageAside.tsx +++ b/packages/gitbook/src/components/PageAside/PageAside.tsx @@ -59,7 +59,7 @@ export function PageAside(props: { 'hydrated:starting:max-w-0', 'hydrated:starting:opacity-0', - 'transition-[margin,max-width,opacity,display] duration-300', + 'transition-[margin,max-width,opacity,display] duration-300 motion-reduce:transition-none', 'transition-discrete', 'basis-56', diff --git a/packages/gitbook/src/components/PageAside/ScrollSectionsList.tsx b/packages/gitbook/src/components/PageAside/ScrollSectionsList.tsx index 0fb2bb263..6cae4624c 100644 --- a/packages/gitbook/src/components/PageAside/ScrollSectionsList.tsx +++ b/packages/gitbook/src/components/PageAside/ScrollSectionsList.tsx @@ -73,6 +73,7 @@ export function ScrollSectionsList({ sections }: { sections: DocumentSection[] } 'px-3', 'transition-all', + 'motion-reduce:transition-none', 'duration-200', 'rounded-md', diff --git a/packages/gitbook/src/components/PageBody/PageCover.tsx b/packages/gitbook/src/components/PageBody/PageCover.tsx index cc31cd81f..39525c1e5 100644 --- a/packages/gitbook/src/components/PageBody/PageCover.tsx +++ b/packages/gitbook/src/components/PageBody/PageCover.tsx @@ -86,6 +86,7 @@ export async function PageCover(props: { // Negative margin to balance the container padding '-mx-4', 'transition-all', + 'motion-reduce:transition-none', as === 'full' ? [ 'sm:-mx-6', diff --git a/packages/gitbook/src/components/SpaceLayout/SpaceLayout.tsx b/packages/gitbook/src/components/SpaceLayout/SpaceLayout.tsx index 0c6b5f8bb..62f1f0d9b 100644 --- a/packages/gitbook/src/components/SpaceLayout/SpaceLayout.tsx +++ b/packages/gitbook/src/components/SpaceLayout/SpaceLayout.tsx @@ -121,7 +121,7 @@ export function SpaceLayout(props: SpaceLayoutProps) { {customization.ai?.mode === CustomizationAIMode.Assistant ? : null} -

+