How can I make the embedded Google slides on my website responsive so that they shrink when viewed on a mobile device?

Published on
September 22, 2023

To make the embedded Google Slides on your website responsive and ensure they shrink when viewed on a mobile device, you can follow these steps:

  1. Obtain the embed code: In order to embed Google Slides on your website, you need to start by obtaining the embed code from Google. Go to your Google Slides presentation and click on the "File" menu. Select "Publish to the web" and then click on the "Embed" tab. Adjust any settings you want and then copy the generated embed code.

  2. Add the embed code to your Webflow project: Access your Webflow project and navigate to the page where you want to display the embedded Google Slides. Drag and drop an Embed element from the "Add" panel to the desired section of your page.

  3. Paste the embed code: Double-click on the Embed element to open its settings. Paste the embed code obtained from Google into the code field.

  4. Apply responsive design: To ensure that the embedded Google Slides shrink and adjust accordingly on mobile devices, you need to apply responsive design techniques. This can be achieved by incorporating CSS media queries.

  • Click on the "Settings" tab and then on the "Custom Code" section of the Webflow Designer.

  • Click on the "Add custom code" button. In the "Head Code" section, include the following CSS media query:

    ```css

    ```

  • Replace .your-embed-class with the class name of the embed element containing the Google Slides. You can find and set the class name in the "Settings" tab of the element's settings.

  • The CSS code ensures that the embedded Google Slides take up 100% of the available width and adjust the height automatically when the maximum viewport width (767px) is reached.

  1. Preview and test: Lastly, preview your website across various devices and screen sizes to confirm that the embedded Google Slides respond as intended. Make any necessary adjustments to the CSS code or other settings until you achieve the desired responsive behavior.

By following these steps, you can make the embedded Google Slides on your website responsive and ensure they shrink when viewed on mobile devices. This will provide a better user experience and ensure that your content remains accessible across different screen sizes.

Additional Questions:

  1. How do I embed Google Slides on my website using Webflow?
  2. What is responsive design in web development?
  3. What are CSS media queries and how are they used for responsive design?