• Resolved eric3d

    (@eric3d)


    While testing the plugin with the Twenty Twenty-One theme, I was not able to scroll the PDF horizontally.
    I tracked down the issue to a conflict between the pdfemb-viewer div width and the following rule from the theme:

    .entry-content > *:not(.alignwide):not(.alignfull):not(.alignleft):not(.alignright):not(.wp-block-separator):not(.woocommerce) {
        max-width: var(--responsive--aligndefault-width);
    }

    PDF Embedder sets the width of the div to match entry-content’s width, but the rule above reduces its width.

    I can override this on my site, but you may want to revise the way width is calculated.

Viewing 1 replies (of 1 total)
  • Hi @eric3d,

    The Twenty Twenty-One theme has a maximum content width of 610px. The way to fix the issue you are having with the responsive CSS conflict is to set the maximum width of the embedded viewer to 610 in the plugin settings. This will prevent the theme’s CSS from overriding the plugin’s calculation to display the embedded document correctly.

    I will also submit a ticket to the developers to see they can add a rule to accommodate the odd behaviour from this theme.

Viewing 1 replies (of 1 total)

The topic ‘Width calculation error with Twenty Twenty-One theme’ is closed to new replies.