Support » Theme: Storefront » Inconsistant meta icons

  • Resolved mesmer7

    (@mesmer7)


    On the post pages, the Category and Tag data are preceded by an icon. But on the product pages, they’re preceded by the words “Category” and “Tags” How can I make these consistent?

Viewing 7 replies - 1 through 7 (of 7 total)
  • Job

    (@jobthomas)

    Automattic Happiness Engineer

    Hey @mesmer7 – you can do that with some custom coding and you can find help for that (at a cost) here: WooCommerce Customizations Page

    mesmer7

    (@mesmer7)

    Yes. Took me a week, but I fixed it on my site by overwriting the function that displays the tags on the product page. But it’s still a major inconsistency that should be fixed in the storefront theme.

    Job

    (@jobthomas)

    Automattic Happiness Engineer

    I’ve shared the suggestion with our Storefront developers, but I think the decision is related to posts and products just having very different templates (the product pages follow WooCommerce’s default styling).

    Job

    (@jobthomas)

    Automattic Happiness Engineer

    UPDATE @mesmer7 – it seems that our developer has already created a pull request to update this: https://github.com/woocommerce/storefront/pull/1040#issue-242711158 – you can expect this to be consistent in the next version of Storefront. Thanks for the input!

    mesmer7

    (@mesmer7)

    Oops. Your developer wants to pull the storefront icons from the post pages. I went in the opposite direction. I added the storefront icons to the woocommerce product pages. If he pulls them, then I’ll have the opposite inconsistency.

    Took me a week to figure out this code. (I’m a novelist, not a programmer.) :

    
    
     add_action( 'woocommerce_single_product_summary', 'hd_product_cat_tags', 7 );
    
    function hd_product_cat_tags(){
    	global $product;
    	//echo ('<div class="product_meta">');
    	echo ('<aside id="hd-product-taxonomy" class="entry-taxonomy">');
    	echo ('<div class="cat-links">');
    	echo wc_get_product_category_list( $product->get_id(), ', ', '<span class="posted_in">' . _n('', '', count( $product->get_category_ids() ), 'woocommerce' )  . ' ', '</span>' );
    	echo ('</div><div class="tags-links">');
    	echo wc_get_product_tag_list( $product->get_id(), ', ', '<span class="tagged_as">' . _n( '', '', count(  $product->get_tag_ids() ), 'woocommerce' )  . ' ', '</span>' );
    	echo ('</div></aside>');
    	//echo ('</div>');
    	}
    
    
    Job

    (@jobthomas)

    Automattic Happiness Engineer

    Thanks for sharing that. Just to confirm, with the next version; you’ll just have to delete your custom code again. (Or add the icons to the blog pages as well.)

    Theme Author Automattic

    (@automattic)

    We haven’t heard back from you in a while, so I’m going to mark this as resolved – if you have any further questions, you can start a new thread.

Viewing 7 replies - 1 through 7 (of 7 total)
  • The topic ‘Inconsistant meta icons’ is closed to new replies.