Why do two blue lines appear when scrolling to a section linked through buttons in the navbar on iPad and iPhone X in Webflow, but not on other devices?

Published on
September 22, 2023

When scrolling to a section linked through buttons in the navbar on iPad and iPhone X in Webflow, you may notice that two blue lines appear. This issue is specific to these devices due to their unique browser behavior. The blue lines are indicators of focus, indicating that the section has been scrolled to and is currently in focus. Here's why these blue lines appear:

  1. Overlapping Navigation Bar: On iPad and iPhone X, the Safari browser on Webflow includes a feature called "Smart App" banners that overlap with the navigation bar. These banners typically appear when a website is optimized for a mobile app. Due to this overlapping behavior, the browser adds the blue focus lines to indicate that the section is in focus.

  2. Custom CSS Styling: If you have applied custom CSS styles to your navigation bar or any other element, it is possible that these styles may conflict with the browser's default behavior on iPad and iPhone X. This conflict can result in the appearance of the blue lines.

  3. Viewport Height: iPad and iPhone X have taller screen heights compared to other devices, resulting in different viewport heights. This difference in height can sometimes trigger the appearance of the blue focus lines.

To address the issue of the blue lines appearing on iPad and iPhone X in Webflow, you can take the following steps:

  • Option 1: Check Custom CSS: Review your custom CSS styles, especially those applied to the navigation bar or any elements that are related to the blue lines' appearance. Remove or modify any conflicting styles that might trigger the appearance of the focus lines.

  • Option 2: Disable Smart App Banners: If you are not using mobile app banners or do not require them for your website, you can disable this feature by adding a specific meta tag to the head section of your website. Add the following tag: <meta name="apple-itunes-app" content="app-id=APP_ID, app-argument=URL">. Replace "APP_ID" with your app's ID and "URL" with the URL of your website.

  • Option 3: Modify Viewport Height: Adjusting the viewport height specifically for iPad and iPhone X may help mitigate the appearance of the blue lines. You can achieve this by using custom CSS or Webflow's built-in CSS styles to target these specific devices. By adjusting the viewport height, you can potentially eliminate the issue.

Remember to test these solutions on actual iPad and iPhone X devices to ensure the desired outcome. Additionally, consider testing your website on different versions of iOS to identify any version-specific quirks that may affect the appearance of the blue lines.

Additional Questions:

  1. How can I style and customize the navigation bar in Webflow?
  2. What are some best practices for optimizing Webflow websites for mobile devices?
  3. How do I troubleshoot cross-browser compatibility issues in Webflow?