Site logo

[Support request] File block and button disappears

Home Forums Support [Support request] File block and button disappears

Home Forums Support File block and button disappears

Viewing 12 posts - 1 through 12 (of 12 total)
  • Author
    Posts
  • #2540633
    Jennifer

    Hi Support,

    Since the last update all my file block PDF links are smaller than the text size and the download button has disappeared leaving just the word download.

    The file block is the standard WP block used for adding a PDF file to the page, gives you the option to inline embed, download link or open link.

    Regards Jen

    #2540652
    Fernando
    Customer Support

    Hi Jeniffer,

    That Block would be out of our scope of support.

    Is the download “word” not clickable?

    #2542299
    Jennifer

    The link the block generates is clickable as is the word download. However, the back ground of the button has disappeared and the link text is smaller than the styles. I have been advised it is an issue with Generate Press.

    #2542307
    Fernando
    Customer Support

    How would you like the Download button to look? Do you have a reference or image you can share?

    #2542339
    Jennifer

    It was a standard button with a black back background that could be changed in colour. The other issue is the theme changes the point size of the link smaller than the text, this also needs to be corrected.

    #2542496
    David
    Staff
    Customer Support

    Hi there,

    try adding this CSS to your site:

    .wp-block-file__button,
    .wp-block-file__button:visited {
        background-color: #000;
        color: #ffffff;
        border-radius: 0;
        padding: 0.5em 1.5em 0.6em 1.5em;
    }
    
    .wp-block-file__button:hover,
    .wp-block-file__button:active,
    .wp-block-file__button:focus {
        background-color: #000;
        color: #ffffff;
    }

    The issue arose when WP changed the file buttons HTML and dropped the core styles for it.
    We are looking at how we now make up for those changes in the theme.

    Let me know how the CSS works for you.

    #2543402
    Jennifer

    Thanks David, The CSS does work but uses the link style set in the theme, there is also a conflict with the font size when using the ‘file block’. The link is a smaller size than the text.

    Hoping you can resolve this issue with the theme and WordPress.

    #2543406
    Fernando
    Customer Support

    For reference, can you share the link to where you’re showing this File Block?

    You may use the Private Information field for this: https://docs.generatepress.com/article/using-the-premium-support-forum/#private-information

    #2546083
    Jennifer

    You will notice the button background has disappeared with the functions and the link text has become smaller font size.

    Normally there is a download button where the word download is now.

    #2546427
    David
    Staff
    Customer Support

    We just need to adjust the CSS to suit your needs for example:

    .wp-block-file__button,
    .wp-block-file__button:visited {
        background-color: #000;
        color: #ffffff;
        font-size: 12px;
    }
    
    .wp-block-file__button:hover,
    .wp-block-file__button:active,
    .wp-block-file__button:focus {
        background-color: #000;
        color: #ffffff;
    }

    This reduces the font-size to 12px and sets just the colors.
    The rest of the styles will be those that are the WordPress defaults, eg. Border Radius and Padding.

    #2548166
    Jennifer

    Nope sadly still no change int he file block setting:(

    #2548497
    David
    Staff
    Customer Support

    Are you adding the CSS to the Customizer > Additional CSS?
    If so can you move it to the very top of the CSS

Viewing 12 posts - 1 through 12 (of 12 total)
  • You must be logged in to reply to this topic.