Automattic\WooCommerce\Blocks\BlockTypes
MiniCart::get_cart_price_markup()
Returns the markup for the cart price.
Method of the class: MiniCart{}
No Hooks.
Return
String
.
Usage
// protected - for code of main (parent) or child class $result = $this->get_cart_price_markup( $attributes );
- $attributes(array) (required)
- Block attributes.
MiniCart::get_cart_price_markup() MiniCart::get cart price markup code WC 9.4.2
protected function get_cart_price_markup( $attributes ) { if ( isset( $attributes['hasHiddenPrice'] ) && false !== $attributes['hasHiddenPrice'] ) { return; } $price_color = array_key_exists( 'priceColor', $attributes ) ? $attributes['priceColor']['color'] : ''; return '<span class="wc-block-mini-cart__amount" style="color:' . esc_attr( $price_color ) . ' "></span>' . $this->get_include_tax_label_markup( $attributes ); }