Woocommerce 3.6.1 template changes

This commit is contained in:
Chris Bibby 2019-04-19 13:36:13 +08:00
parent 1ab2f98382
commit d60c6d4428
1 changed files with 4 additions and 6 deletions

View File

@ -12,7 +12,7 @@
*
* @see https://docs.woocommerce.com/document/template-structure/
* @package WooCommerce/Templates
* @version 3.4.0
* @version 3.6.0
*/
defined( 'ABSPATH' ) || exit;
@ -25,10 +25,10 @@ if ( $max_value && $min_value === $max_value ) {
<?php
} else {
/* translators: %s: Quantity. */
$labelledby = ! empty( $args['product_name'] ) ? sprintf( __( '%s quantity', 'understrap' ), strip_tags( $args['product_name'] ) ) : '';
$label = ! empty( $args['product_name'] ) ? sprintf( __( '%s quantity', 'understrap' ), wp_strip_all_tags( $args['product_name'] ) ) : __( 'Quantity', 'understrap' );
?>
<div class="quantity">
<label class="sr-only" for="<?php echo esc_attr( $input_id ); ?>"><?php esc_html_e( 'Quantity', 'understrap' ); ?></label>
<label class="sr-only" for="<?php echo esc_attr( $input_id ); ?>"><?php echo esc_attr( $label ); ?></label>
<input
type="number"
id="<?php echo esc_attr( $input_id ); ?>"
@ -40,9 +40,7 @@ if ( $max_value && $min_value === $max_value ) {
value="<?php echo esc_attr( $input_value ); ?>"
title="<?php echo esc_attr_x( 'Qty', 'Product quantity input tooltip', 'understrap' ); ?>"
size="4"
pattern="<?php echo esc_attr( $pattern ); ?>"
inputmode="<?php echo esc_attr( $inputmode ); ?>"
aria-labelledby="<?php echo esc_attr( $labelledby ); ?>" />
inputmode="<?php echo esc_attr( $inputmode ); ?>" />
</div>
<?php
}