Setup wizard: Style shipping unit selection

This commit is contained in:
Valerie 2017-09-21 00:27:19 +03:00 committed by Jeff Stieler
parent 43949c2b74
commit 18deb4dc2e
2 changed files with 50 additions and 19 deletions

View File

@ -594,7 +594,7 @@ body {
display: none;
}
// Shipping
// Shipping list of services
.wc-wizard-services.shipping {
.wc-wizard-service-name {
@ -634,6 +634,17 @@ body {
font-size: 0.92em;
}
}
.wc-setup-shipping-units {
p {
line-height: 1.5em;
font-size: 14px;
margin-bottom: 0.25em;
}
.wc-setup-shipping-unit {
margin-bottom: 1.75em
}
}
.hide {
display: none;

View File

@ -728,8 +728,18 @@ class WC_Admin_Setup_Wizard {
</li>
</ul>
<div>
<label for="weight_unit"><?php esc_html_e( 'Weight unit—used to calculate shipping rates, and more.', 'woocommerce' ); ?></label>
<div class="wc-setup-shipping-units">
<div class="wc-setup-shipping-unit">
<p>
<label for="weight_unit">
<?php
printf( wp_kses(
__( '<strong>Weight unit</strong>—used to calculate shipping rates, and more.', 'woocommerce' ),
array( 'strong' => array() )
) );
?>
</label>
</p>
<select id="weight_unit" name="weight_unit" class="wc-enhanced-select" style="width:100%">
<option value="kg" <?php selected( $weight_unit, 'kg' ); ?>><?php esc_html_e( 'kg', 'woocommerce' ); ?></option>
<option value="g" <?php selected( $weight_unit, 'g' ); ?>><?php esc_html_e( 'g', 'woocommerce' ); ?></option>
@ -737,8 +747,17 @@ class WC_Admin_Setup_Wizard {
<option value="oz" <?php selected( $weight_unit, 'oz' ); ?>><?php esc_html_e( 'oz', 'woocommerce' ); ?></option>
</select>
</div>
<div>
<label for="dimension_unit"><?php esc_html_e( 'Dimension unit—helps for accurate package selection.', 'woocommerce' ); ?></label>
<div class="wc-setup-shipping-unit">
<p>
<label for="dimension_unit">
<?php
printf( wp_kses(
__( '<strong>Dimension unit</strong>—helps for accurate package selection.', 'woocommerce' ),
array( 'strong' => array() )
) );
?>
</label>
</p>
<select id="dimension_unit" name="dimension_unit" class="wc-enhanced-select" style="width:100%">
<option value="m" <?php selected( $dimension_unit, 'm' ); ?>><?php esc_html_e( 'm', 'woocommerce' ); ?></option>
<option value="cm" <?php selected( $dimension_unit, 'cm' ); ?>><?php esc_html_e( 'cm', 'woocommerce' ); ?></option>
@ -747,6 +766,7 @@ class WC_Admin_Setup_Wizard {
<option value="yd" <?php selected( $dimension_unit, 'yd' ); ?>><?php esc_html_e( 'yd', 'woocommerce' ); ?></option>
</select>
</div>
</div>
<p class="wc-setup-actions step">
<input type="submit" class="button-primary button button-large button-next" value="<?php esc_attr_e( 'Continue', 'woocommerce' ); ?>" name="save_step" />