[Support request] Change icon in off canvas

Home Forums Support [Support request] Change icon in off canvas

Home Forums Support Change icon in off canvas

  • This topic has 1 reply, 2 voices, and was last updated 4 months ago by Fernando.
Viewing 2 posts - 1 through 2 (of 2 total)
  • Author
    Posts
  • #2189340
    jose

    How can I change the off canvas exit icon?

    #2189368
    Fernando
    Customer Support

    Hi Jose,

    If you have the Close Button of the Off canvas menu to appear Inside in Appearance > Customize > Layout > Off Canvas Panel, you may add a PHP snippet like this to alter it:

    add_filter( 'generate_close_slideout_navigation_button', function() {
        return sprintf(
    				'<button class="slideout-exit %2$s">%1$s</button>',
    				'YOUR CUSTOM HTML HERE',
    				'has-svg-icon'
    			);
    } );

    Kindly replace YOUR CUSTOM HTML HERE with your HTML.

    Adding PHP: https://docs.generatepress.com/article/adding-php/#code-snippets

    Adding it through Code Snippets should work.

    Hope this clarifies. Kindly let us know how it goes. 🙂

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