From e8e5b40ba827d63cf8e4b69be8c3921e281a0a9e Mon Sep 17 00:00:00 2001 From: Mike Jolley Date: Wed, 7 Mar 2018 13:45:25 +0000 Subject: [PATCH 01/61] Just a basic class --- includes/class-wc-privacy.php | 44 ++++++++++++++++++++++++++++++++++ includes/class-woocommerce.php | 1 + 2 files changed, 45 insertions(+) create mode 100644 includes/class-wc-privacy.php diff --git a/includes/class-wc-privacy.php b/includes/class-wc-privacy.php new file mode 100644 index 00000000000..97424e54c64 --- /dev/null +++ b/includes/class-wc-privacy.php @@ -0,0 +1,44 @@ + Date: Wed, 7 Mar 2018 13:57:33 +0000 Subject: [PATCH 02/61] notes --- includes/class-wc-privacy.php | 22 +++++++++++++++++++++- 1 file changed, 21 insertions(+), 1 deletion(-) diff --git a/includes/class-wc-privacy.php b/includes/class-wc-privacy.php index 97424e54c64..4d5f137e63a 100644 --- a/includes/class-wc-privacy.php +++ b/includes/class-wc-privacy.php @@ -25,7 +25,27 @@ class WC_Privacy { * @param string $email Email address. */ public static function remove_personal_data( $email ) { - // Do something. + /** + * Order Data: + * + * Transaction ID + * Customer's IP Address and User Agent + * Billing Address First Name, Last Name, Company, Address Line 1, Address Line 2, City, Postcode/ZIP, Country, State/County, Phone, Email Address + * "Billing Fields" (_billing_address_index) + * Same as above for shipping + * + * Customer Data (meta): + * + * Billing and shipping addresses + * + * Misc: + * + * Downloadable Product User Email + * Download Log Entry User IP Address + * Carts for user ID/Sessions + * File based logs containing their email e.g. from webhooks + * Payment tokens? + */ } /** From f1107e94e218f4ce6525867326770d37b6d9732b Mon Sep 17 00:00:00 2001 From: Gerhard Potgieter Date: Thu, 8 Mar 2018 14:49:02 +0200 Subject: [PATCH 03/61] Basic personal info lookup and dump --- includes/class-wc-privacy.php | 74 ++++++++++++++++++++++++++++++++++- 1 file changed, 72 insertions(+), 2 deletions(-) diff --git a/includes/class-wc-privacy.php b/includes/class-wc-privacy.php index 4d5f137e63a..20723cc6504 100644 --- a/includes/class-wc-privacy.php +++ b/includes/class-wc-privacy.php @@ -55,8 +55,78 @@ class WC_Privacy { * @return array Array of personal data. */ public static function get_personal_data( $email ) { - // Do something. - return array(); + if ( ! is_email( $email ) ) { + return array(); + } + + $personal_data = array(); + + // Check if user has an ID in the DB to load stored personal data. + $user = get_user_by( 'email', $email ); + if ( $user instanceof WP_User ) { + $customer = new WC_Customer( $user->ID ); + if ( $customer ) { + $personal_data['Billing First Name'] = $customer->get_billing_first_name(); + $personal_data['Billing Last Name'] = $customer->get_billing_last_name(); + $personal_data['Billing Company'] = $customer->get_billing_company(); + $personal_data['Billing Address 1'] = $customer->get_billing_address_1(); + $personal_data['Billing Address 2'] = $customer->get_billing_address_2(); + $personal_data['Billing City'] = $customer->get_billing_city(); + $personal_data['Billing Postal/Zip Code'] = $customer->get_billing_postcode(); + $personal_data['Billing State'] = $customer->get_billing_state(); + $personal_data['Billing Country'] = $customer->get_billing_country(); + $personal_data['Billing Phone'] = $customer->get_billing_phone(); + $personal_data['Shipping First Name'] = $customer->get_shipping_first_name(); + $personal_data['Shipping Last Name'] = $customer->get_shipping_last_name(); + $personal_data['Shipping Company'] = $customer->get_shipping_company(); + $personal_data['Shipping Address 1'] = $customer->get_shipping_address_1(); + $personal_data['Shipping Address 2'] = $customer->get_shipping_address_2(); + $personal_data['Shipping City'] = $customer->get_shipping_city(); + $personal_data['Shipping Postal/Zip Code'] = $customer->get_shipping_postcode(); + $personal_data['Shipping State'] = $customer->get_shipping_state(); + $personal_data['Shipping Country'] = $customer->get_shipping_country(); + $personal_data['Shipping Phone'] = $customer->get_shipping_phone(); + } + } + + // Retrieve all orders with billing email set to user's email. + $orders = wc_get_orders( array( + 'billing_email' => $email, + 'limit' => -1, + ) ); + + if ( 0 < count( $orders ) ) { + $personal_data['orders'] = array(); + foreach ( $orders as $order ) { + $order_data = array( + 'Transaction ID' => $order->get_order_number(), + 'IP Address' => $order->get_customer_ip_address(), + 'User Agent' => $order->get_customer_user_agent(), + 'Billing First Name' => $order->get_billing_first_name(), + 'Billing Last Name' => $order->get_billing_last_name(), + 'Billing Company' => $order->get_billing_company(), + 'Billing Address 1' => $order->get_billing_address_1(), + 'Billing Address 2' => $order->get_billing_address_2(), + 'Billing City' => $order->get_billing_city(), + 'Billing Postal/Zip Code' => $order->get_billing_postcode(), + 'Billing State' => $order->get_billing_state(), + 'Billing Country' => $order->get_billing_country(), + 'Billing Phone' => $order->get_billing_phone(), + 'Shipping First Name' => $order->get_shipping_first_name(), + 'Shipping Last Name' => $order->get_shipping_last_name(), + 'Shipping Company' => $order->get_shipping_company(), + 'Shipping Address 1' => $order->get_shipping_address_1(), + 'Shipping Address 2' => $order->get_shipping_address_2(), + 'Shipping City' => $order->get_shipping_city(), + 'Shipping Postal/Zip Code' => $order->get_shipping_postcode(), + 'Shipping State' => $order->get_shipping_state(), + 'Shipping Country' => $order->get_shipping_country(), + 'Shipping Phone' => $order->get_shipping_phone(), + ); + $personal_data['orders'][] = $order_data; + } + } + return $personal_data; } } From 8ce660e73191d0119a6bd04fbdeb83b613a79f73 Mon Sep 17 00:00:00 2001 From: Gerhard Potgieter Date: Fri, 9 Mar 2018 07:14:21 +0200 Subject: [PATCH 04/61] Add note about pining tracker to anonomize/delete on that side as well. --- includes/class-wc-privacy.php | 2 ++ 1 file changed, 2 insertions(+) diff --git a/includes/class-wc-privacy.php b/includes/class-wc-privacy.php index 20723cc6504..40d4fa6434f 100644 --- a/includes/class-wc-privacy.php +++ b/includes/class-wc-privacy.php @@ -45,6 +45,8 @@ class WC_Privacy { * Carts for user ID/Sessions * File based logs containing their email e.g. from webhooks * Payment tokens? + * + * Ping tracker to anonomize data there as well. */ } From e08b447c14e5ff928ac71abfd5dce53aab2957f6 Mon Sep 17 00:00:00 2001 From: Gerhard Potgieter Date: Fri, 9 Mar 2018 14:13:16 +0200 Subject: [PATCH 05/61] Add both order id and order number to export --- includes/class-wc-privacy.php | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/includes/class-wc-privacy.php b/includes/class-wc-privacy.php index 40d4fa6434f..7f60fc9a491 100644 --- a/includes/class-wc-privacy.php +++ b/includes/class-wc-privacy.php @@ -101,7 +101,8 @@ class WC_Privacy { $personal_data['orders'] = array(); foreach ( $orders as $order ) { $order_data = array( - 'Transaction ID' => $order->get_order_number(), + 'Order ID' => $order->get_id(), + 'Order Number' => $order->get_order_number(), 'IP Address' => $order->get_customer_ip_address(), 'User Agent' => $order->get_customer_user_agent(), 'Billing First Name' => $order->get_billing_first_name(), From f166e25b19c7a75526c0d555057b70540e40dc2c Mon Sep 17 00:00:00 2001 From: Mike Jolley Date: Wed, 14 Mar 2018 14:11:42 +0000 Subject: [PATCH 06/61] basic integration with https://core.trac.wordpress.org/ticket/43438 --- includes/class-wc-privacy.php | 219 +++++++++++++++++++++------------- 1 file changed, 135 insertions(+), 84 deletions(-) diff --git a/includes/class-wc-privacy.php b/includes/class-wc-privacy.php index 7f60fc9a491..1061500068d 100644 --- a/includes/class-wc-privacy.php +++ b/includes/class-wc-privacy.php @@ -16,7 +16,141 @@ class WC_Privacy { * Init - hook into events. */ public static function init() { - // Add hooks here. + add_filter( 'wp_privacy_personal_data_exporters', array( __CLASS__, 'register_data_exporter' ), 10 ); + } + + /** + * Registers the personal data exporter for comments. + * + * @param array $exporters An array of personal data exporters. + * @return array An array of personal data exporters. + */ + public static function register_data_exporter( $exporters ) { + $exporters[] = array( + 'exporter_friendly_name' => __( 'WooCommerce Data', 'woocommerce' ), + 'callback' => array( __CLASS__, 'data_exporter' ), + ); + return $exporters; + } + + /** + * Finds and exports data which could be used to identify a person from WooCommerce data assocated with an email address. + * + * To split the export into manangeable chunks we'll export customer profile data on page 0, and orders from then on until done. + * + * @param string $email_address The user email address. + * @param int $page Page, zero based. + * @return array An array of personal data in name value pairs + */ + public static function data_exporter( $email_address, $page ) { + $personal_data = array(); + $done = false; + $user = get_user_by( 'email', $email ); // Check if user has an ID in the DB to load stored personal data. + + // Export customer data first. + if ( 0 === $page ) { + if ( $user instanceof WP_User ) { + $personal_data = self::get_user_personal_data( $user ); + } + } else { // Export orders - 10 at a time. + $order_query = array( + 'limit' => 10, + 'page' => $page, + ); + + if ( $user instanceof WP_User ) { + $order_query['customer_id'] = $user->ID; + } else { + $order_query['billing_email'] = $email; + } + $orders = wc_get_orders( $order_query ); + + if ( 0 < count( $orders ) ) { + $personal_data['orders'] = array(); + + foreach ( $orders as $order ) { + $personal_data['orders'][] = self::get_order_personal_data( $order ); + } + } else { + $done = true; + } + } + + return array( + 'data' => $personal_data, + 'done' => $done, + ); + } + + /** + * Get personal data (key/value pairs) for a user object. + * + * @param WP_User $user user object. + * @return array + */ + protected static function get_user_personal_data( $user ) { + $personal_data = array(); + $customer = new WC_Customer( $user->ID ); + + if ( $customer ) { + $personal_data['Billing First Name'] = $customer->get_billing_first_name(); + $personal_data['Billing Last Name'] = $customer->get_billing_last_name(); + $personal_data['Billing Company'] = $customer->get_billing_company(); + $personal_data['Billing Address 1'] = $customer->get_billing_address_1(); + $personal_data['Billing Address 2'] = $customer->get_billing_address_2(); + $personal_data['Billing City'] = $customer->get_billing_city(); + $personal_data['Billing Postal/Zip Code'] = $customer->get_billing_postcode(); + $personal_data['Billing State'] = $customer->get_billing_state(); + $personal_data['Billing Country'] = $customer->get_billing_country(); + $personal_data['Billing Phone'] = $customer->get_billing_phone(); + $personal_data['Shipping First Name'] = $customer->get_shipping_first_name(); + $personal_data['Shipping Last Name'] = $customer->get_shipping_last_name(); + $personal_data['Shipping Company'] = $customer->get_shipping_company(); + $personal_data['Shipping Address 1'] = $customer->get_shipping_address_1(); + $personal_data['Shipping Address 2'] = $customer->get_shipping_address_2(); + $personal_data['Shipping City'] = $customer->get_shipping_city(); + $personal_data['Shipping Postal/Zip Code'] = $customer->get_shipping_postcode(); + $personal_data['Shipping State'] = $customer->get_shipping_state(); + $personal_data['Shipping Country'] = $customer->get_shipping_country(); + $personal_data['Shipping Phone'] = $customer->get_shipping_phone(); + } + + return $personal_data; + } + + /** + * Get personal data (key/value pairs) for an order object. + * + * @param WC_Order $order Order object. + * @return array + */ + protected static function get_order_personal_data( $order ) { + return array( + 'Order ID' => $order->get_id(), + 'Order Number' => $order->get_order_number(), + 'IP Address' => $order->get_customer_ip_address(), + 'User Agent' => $order->get_customer_user_agent(), + 'Billing First Name' => $order->get_billing_first_name(), + 'Billing Last Name' => $order->get_billing_last_name(), + 'Billing Company' => $order->get_billing_company(), + 'Billing Address 1' => $order->get_billing_address_1(), + 'Billing Address 2' => $order->get_billing_address_2(), + 'Billing City' => $order->get_billing_city(), + 'Billing Postal/Zip Code' => $order->get_billing_postcode(), + 'Billing State' => $order->get_billing_state(), + 'Billing Country' => $order->get_billing_country(), + 'Billing Phone' => $order->get_billing_phone(), + 'Shipping First Name' => $order->get_shipping_first_name(), + 'Shipping Last Name' => $order->get_shipping_last_name(), + 'Shipping Company' => $order->get_shipping_company(), + 'Shipping Address 1' => $order->get_shipping_address_1(), + 'Shipping Address 2' => $order->get_shipping_address_2(), + 'Shipping City' => $order->get_shipping_city(), + 'Shipping Postal/Zip Code' => $order->get_shipping_postcode(), + 'Shipping State' => $order->get_shipping_state(), + 'Shipping Country' => $order->get_shipping_country(), + 'Shipping Phone' => $order->get_shipping_phone(), + ); } /** @@ -49,89 +183,6 @@ class WC_Privacy { * Ping tracker to anonomize data there as well. */ } - - /** - * Get personal data for a given email address. This can be used for exports. - * - * @param string $email Email address. - * @return array Array of personal data. - */ - public static function get_personal_data( $email ) { - if ( ! is_email( $email ) ) { - return array(); - } - - $personal_data = array(); - - // Check if user has an ID in the DB to load stored personal data. - $user = get_user_by( 'email', $email ); - if ( $user instanceof WP_User ) { - $customer = new WC_Customer( $user->ID ); - if ( $customer ) { - $personal_data['Billing First Name'] = $customer->get_billing_first_name(); - $personal_data['Billing Last Name'] = $customer->get_billing_last_name(); - $personal_data['Billing Company'] = $customer->get_billing_company(); - $personal_data['Billing Address 1'] = $customer->get_billing_address_1(); - $personal_data['Billing Address 2'] = $customer->get_billing_address_2(); - $personal_data['Billing City'] = $customer->get_billing_city(); - $personal_data['Billing Postal/Zip Code'] = $customer->get_billing_postcode(); - $personal_data['Billing State'] = $customer->get_billing_state(); - $personal_data['Billing Country'] = $customer->get_billing_country(); - $personal_data['Billing Phone'] = $customer->get_billing_phone(); - $personal_data['Shipping First Name'] = $customer->get_shipping_first_name(); - $personal_data['Shipping Last Name'] = $customer->get_shipping_last_name(); - $personal_data['Shipping Company'] = $customer->get_shipping_company(); - $personal_data['Shipping Address 1'] = $customer->get_shipping_address_1(); - $personal_data['Shipping Address 2'] = $customer->get_shipping_address_2(); - $personal_data['Shipping City'] = $customer->get_shipping_city(); - $personal_data['Shipping Postal/Zip Code'] = $customer->get_shipping_postcode(); - $personal_data['Shipping State'] = $customer->get_shipping_state(); - $personal_data['Shipping Country'] = $customer->get_shipping_country(); - $personal_data['Shipping Phone'] = $customer->get_shipping_phone(); - } - } - - // Retrieve all orders with billing email set to user's email. - $orders = wc_get_orders( array( - 'billing_email' => $email, - 'limit' => -1, - ) ); - - if ( 0 < count( $orders ) ) { - $personal_data['orders'] = array(); - foreach ( $orders as $order ) { - $order_data = array( - 'Order ID' => $order->get_id(), - 'Order Number' => $order->get_order_number(), - 'IP Address' => $order->get_customer_ip_address(), - 'User Agent' => $order->get_customer_user_agent(), - 'Billing First Name' => $order->get_billing_first_name(), - 'Billing Last Name' => $order->get_billing_last_name(), - 'Billing Company' => $order->get_billing_company(), - 'Billing Address 1' => $order->get_billing_address_1(), - 'Billing Address 2' => $order->get_billing_address_2(), - 'Billing City' => $order->get_billing_city(), - 'Billing Postal/Zip Code' => $order->get_billing_postcode(), - 'Billing State' => $order->get_billing_state(), - 'Billing Country' => $order->get_billing_country(), - 'Billing Phone' => $order->get_billing_phone(), - 'Shipping First Name' => $order->get_shipping_first_name(), - 'Shipping Last Name' => $order->get_shipping_last_name(), - 'Shipping Company' => $order->get_shipping_company(), - 'Shipping Address 1' => $order->get_shipping_address_1(), - 'Shipping Address 2' => $order->get_shipping_address_2(), - 'Shipping City' => $order->get_shipping_city(), - 'Shipping Postal/Zip Code' => $order->get_shipping_postcode(), - 'Shipping State' => $order->get_shipping_state(), - 'Shipping Country' => $order->get_shipping_country(), - 'Shipping Phone' => $order->get_shipping_phone(), - ); - $personal_data['orders'][] = $order_data; - } - } - return $personal_data; - } - } WC_Privacy::init(); From fec36ff4b29bbc4f43059bed72df055bd9fb7e85 Mon Sep 17 00:00:00 2001 From: Mike Jolley Date: Wed, 14 Mar 2018 14:29:03 +0000 Subject: [PATCH 07/61] Test runner --- includes/class-wc-privacy.php | 8 ++-- tests/unit-tests/privacy/export.php | 70 +++++++++++++++++++++++++++++ 2 files changed, 73 insertions(+), 5 deletions(-) create mode 100644 tests/unit-tests/privacy/export.php diff --git a/includes/class-wc-privacy.php b/includes/class-wc-privacy.php index 1061500068d..2c6656df490 100644 --- a/includes/class-wc-privacy.php +++ b/includes/class-wc-privacy.php @@ -45,7 +45,7 @@ class WC_Privacy { public static function data_exporter( $email_address, $page ) { $personal_data = array(); $done = false; - $user = get_user_by( 'email', $email ); // Check if user has an ID in the DB to load stored personal data. + $user = get_user_by( 'email', $email_address ); // Check if user has an ID in the DB to load stored personal data. // Export customer data first. if ( 0 === $page ) { @@ -59,9 +59,9 @@ class WC_Privacy { ); if ( $user instanceof WP_User ) { - $order_query['customer_id'] = $user->ID; + $order_query['customer_id'] = $user->ID; } else { - $order_query['billing_email'] = $email; + $order_query['billing_email'] = $email_address; } $orders = wc_get_orders( $order_query ); @@ -112,7 +112,6 @@ class WC_Privacy { $personal_data['Shipping Postal/Zip Code'] = $customer->get_shipping_postcode(); $personal_data['Shipping State'] = $customer->get_shipping_state(); $personal_data['Shipping Country'] = $customer->get_shipping_country(); - $personal_data['Shipping Phone'] = $customer->get_shipping_phone(); } return $personal_data; @@ -149,7 +148,6 @@ class WC_Privacy { 'Shipping Postal/Zip Code' => $order->get_shipping_postcode(), 'Shipping State' => $order->get_shipping_state(), 'Shipping Country' => $order->get_shipping_country(), - 'Shipping Phone' => $order->get_shipping_phone(), ); } diff --git a/tests/unit-tests/privacy/export.php b/tests/unit-tests/privacy/export.php new file mode 100644 index 00000000000..6adc51182cd --- /dev/null +++ b/tests/unit-tests/privacy/export.php @@ -0,0 +1,70 @@ +orders as $object ) { + $object->delete( true ); + } + foreach ( $this->customers as $object ) { + $object->delete( true ); + } + } + + /** + * Test: Data exporter. + */ + public function test_data_exporter() { + $customer1 = WC_Helper_Customer::create_customer( 'customer1', 'password', 'test1@test.com' ); + $customer1->set_billing_email( 'customer1@test.com' ); + $customer1->save(); + + $customer2 = WC_Helper_Customer::create_customer( 'customer2', 'password', 'test2@test.com' ); + $customer2->set_billing_email( 'customer2@test.com' ); + $customer2->save(); + + $this->customers[] = $customer1; + $this->customers[] = $customer2; + + // Create a bunch of dummy orders for some users. + $this->orders[] = WC_Helper_Order::create_order( 1 ); + $this->orders[] = WC_Helper_Order::create_order( 1 ); + $this->orders[] = WC_Helper_Order::create_order( 1 ); + $this->orders[] = WC_Helper_Order::create_order( 1 ); + $this->orders[] = WC_Helper_Order::create_order( 1 ); + $this->orders[] = WC_Helper_Order::create_order( 1 ); + $this->orders[] = WC_Helper_Order::create_order( 1 ); + $this->orders[] = WC_Helper_Order::create_order( 1 ); + $this->orders[] = WC_Helper_Order::create_order( 1 ); + $this->orders[] = WC_Helper_Order::create_order( 1 ); + $this->orders[] = WC_Helper_Order::create_order( 1 ); + $this->orders[] = WC_Helper_Order::create_order( 2 ); + $this->orders[] = WC_Helper_Order::create_order( 2 ); + + // Do a test export and check response. + $response = WC_Privacy::data_exporter( 'test1@test.com', 0 ); + + $this->assertEquals( array(), $response ); + } +} From e0ab13bd3c9bce913657c782b6d94039d6e3dde2 Mon Sep 17 00:00:00 2001 From: Mike Jolley Date: Wed, 14 Mar 2018 15:14:45 +0000 Subject: [PATCH 08/61] Tests and test pass --- includes/class-wc-privacy.php | 13 +++-- tests/unit-tests/privacy/export.php | 76 +++++++++++++++++++++++------ 2 files changed, 72 insertions(+), 17 deletions(-) diff --git a/includes/class-wc-privacy.php b/includes/class-wc-privacy.php index 2c6656df490..9a8aae5ac64 100644 --- a/includes/class-wc-privacy.php +++ b/includes/class-wc-privacy.php @@ -63,6 +63,7 @@ class WC_Privacy { } else { $order_query['billing_email'] = $email_address; } + $orders = wc_get_orders( $order_query ); if ( 0 < count( $orders ) ) { @@ -71,6 +72,10 @@ class WC_Privacy { foreach ( $orders as $order ) { $personal_data['orders'][] = self::get_order_personal_data( $order ); } + + if ( 10 > count( $orders ) ) { + $done = true; + } } else { $done = true; } @@ -103,6 +108,7 @@ class WC_Privacy { $personal_data['Billing State'] = $customer->get_billing_state(); $personal_data['Billing Country'] = $customer->get_billing_country(); $personal_data['Billing Phone'] = $customer->get_billing_phone(); + $personal_data['Billing Email'] = $customer->get_billing_email(); $personal_data['Shipping First Name'] = $customer->get_shipping_first_name(); $personal_data['Shipping Last Name'] = $customer->get_shipping_last_name(); $personal_data['Shipping Company'] = $customer->get_shipping_company(); @@ -114,7 +120,7 @@ class WC_Privacy { $personal_data['Shipping Country'] = $customer->get_shipping_country(); } - return $personal_data; + return array_filter( $personal_data ); } /** @@ -124,7 +130,7 @@ class WC_Privacy { * @return array */ protected static function get_order_personal_data( $order ) { - return array( + return array_filter( array( 'Order ID' => $order->get_id(), 'Order Number' => $order->get_order_number(), 'IP Address' => $order->get_customer_ip_address(), @@ -139,6 +145,7 @@ class WC_Privacy { 'Billing State' => $order->get_billing_state(), 'Billing Country' => $order->get_billing_country(), 'Billing Phone' => $order->get_billing_phone(), + 'Billing Email' => $order->get_billing_email(), 'Shipping First Name' => $order->get_shipping_first_name(), 'Shipping Last Name' => $order->get_shipping_last_name(), 'Shipping Company' => $order->get_shipping_company(), @@ -148,7 +155,7 @@ class WC_Privacy { 'Shipping Postal/Zip Code' => $order->get_shipping_postcode(), 'Shipping State' => $order->get_shipping_state(), 'Shipping Country' => $order->get_shipping_country(), - ); + ) ); } /** diff --git a/tests/unit-tests/privacy/export.php b/tests/unit-tests/privacy/export.php index 6adc51182cd..ef6f3837545 100644 --- a/tests/unit-tests/privacy/export.php +++ b/tests/unit-tests/privacy/export.php @@ -48,23 +48,71 @@ class WC_Test_Privacy_Export extends WC_Unit_Test_Case { $this->customers[] = $customer2; // Create a bunch of dummy orders for some users. - $this->orders[] = WC_Helper_Order::create_order( 1 ); - $this->orders[] = WC_Helper_Order::create_order( 1 ); - $this->orders[] = WC_Helper_Order::create_order( 1 ); - $this->orders[] = WC_Helper_Order::create_order( 1 ); - $this->orders[] = WC_Helper_Order::create_order( 1 ); - $this->orders[] = WC_Helper_Order::create_order( 1 ); - $this->orders[] = WC_Helper_Order::create_order( 1 ); - $this->orders[] = WC_Helper_Order::create_order( 1 ); - $this->orders[] = WC_Helper_Order::create_order( 1 ); - $this->orders[] = WC_Helper_Order::create_order( 1 ); - $this->orders[] = WC_Helper_Order::create_order( 1 ); - $this->orders[] = WC_Helper_Order::create_order( 2 ); - $this->orders[] = WC_Helper_Order::create_order( 2 ); + $this->orders[] = WC_Helper_Order::create_order( $customer1->get_id() ); + $this->orders[] = WC_Helper_Order::create_order( $customer1->get_id() ); + $this->orders[] = WC_Helper_Order::create_order( $customer1->get_id() ); + $this->orders[] = WC_Helper_Order::create_order( $customer1->get_id() ); + $this->orders[] = WC_Helper_Order::create_order( $customer1->get_id() ); + $this->orders[] = WC_Helper_Order::create_order( $customer1->get_id() ); + $this->orders[] = WC_Helper_Order::create_order( $customer1->get_id() ); + $this->orders[] = WC_Helper_Order::create_order( $customer1->get_id() ); + $this->orders[] = WC_Helper_Order::create_order( $customer1->get_id() ); + $this->orders[] = WC_Helper_Order::create_order( $customer1->get_id() ); + $this->orders[] = WC_Helper_Order::create_order( $customer1->get_id() ); + $this->orders[] = WC_Helper_Order::create_order( $customer2->get_id() ); + $this->orders[] = WC_Helper_Order::create_order( $customer2->get_id() ); + + // Test a non existing user. + $response = WC_Privacy::data_exporter( 'doesnotexist@test.com', 0 ); + $this->assertEquals( array(), $response['data'] ); // Do a test export and check response. $response = WC_Privacy::data_exporter( 'test1@test.com', 0 ); + $this->assertFalse( $response['done'] ); + $this->assertEquals( array( + // 'Billing First Name' => '', + // 'Billing Last Name', => '', + // 'Billing Company', => '', + 'Billing Address 1' => '123 South Street', + 'Billing Address 2' => 'Apt 1', + 'Billing City' => 'Philadelphia', + 'Billing Postal/Zip Code' => '19123', + 'Billing State' => 'PA', + 'Billing Country' => 'US', + // 'Billing Phone' => '', + 'Billing Email' => 'customer1@test.com', + // 'Shipping First Name' => '', + // 'Shipping Last Name', => '', + // 'Shipping Company', => '', + 'Shipping Address 1' => '123 South Street', + 'Shipping Address 2' => 'Apt 1', + 'Shipping City' => 'Philadelphia', + 'Shipping Postal/Zip Code' => '19123', + 'Shipping State' => 'PA', + 'Shipping Country' => 'US', + ), $response['data'] ); - $this->assertEquals( array(), $response ); + // Next page should be orders. + $response = WC_Privacy::data_exporter( 'test1@test.com', 1 ); + $this->assertFalse( $response['done'] ); + $this->assertArrayHasKey( 'orders', $response['data'] ); + $this->assertTrue( 10 === count( $response['data']['orders'] ), print_r( $response, true ) ); + $this->assertArrayHasKey( 'Order ID', $response['data']['orders'][0] ); + $this->assertArrayHasKey( 'Order Number', $response['data']['orders'][0] ); + $this->assertArrayHasKey( 'IP Address', $response['data']['orders'][0] ); + $this->assertArrayHasKey( 'Billing First Name', $response['data']['orders'][0] ); + $this->assertArrayHasKey( 'Billing Last Name', $response['data']['orders'][0] ); + $this->assertArrayHasKey( 'Billing Company', $response['data']['orders'][0] ); + $this->assertArrayHasKey( 'Billing Address 1', $response['data']['orders'][0] ); + $this->assertArrayHasKey( 'Billing City', $response['data']['orders'][0] ); + $this->assertArrayHasKey( 'Billing Postal/Zip Code', $response['data']['orders'][0] ); + $this->assertArrayHasKey( 'Billing State', $response['data']['orders'][0] ); + $this->assertArrayHasKey( 'Billing Country', $response['data']['orders'][0] ); + + // Next page should be orders. + $response = WC_Privacy::data_exporter( 'test1@test.com', 2 ); + $this->assertTrue( $response['done'] ); + $this->assertArrayHasKey( 'orders', $response['data'] ); + $this->assertTrue( 1 === count( $response['data']['orders'] ), count( $response['data']['orders'] ) ); } } From 27f07807a5a25ab118f0ba7b8506542c2f483b9d Mon Sep 17 00:00:00 2001 From: Mike Jolley Date: Wed, 14 Mar 2018 15:23:39 +0000 Subject: [PATCH 09/61] Clean up --- includes/class-wc-privacy.php | 29 +++++++++-------------------- tests/unit-tests/privacy/export.php | 9 +-------- 2 files changed, 10 insertions(+), 28 deletions(-) diff --git a/includes/class-wc-privacy.php b/includes/class-wc-privacy.php index 9a8aae5ac64..e602d66bb31 100644 --- a/includes/class-wc-privacy.php +++ b/includes/class-wc-privacy.php @@ -73,9 +73,7 @@ class WC_Privacy { $personal_data['orders'][] = self::get_order_personal_data( $order ); } - if ( 10 > count( $orders ) ) { - $done = true; - } + $done = 10 > count( $orders ); } else { $done = true; } @@ -165,27 +163,18 @@ class WC_Privacy { */ public static function remove_personal_data( $email ) { /** - * Order Data: + * Personal Data: * - * Transaction ID - * Customer's IP Address and User Agent - * Billing Address First Name, Last Name, Company, Address Line 1, Address Line 2, City, Postcode/ZIP, Country, State/County, Phone, Email Address - * "Billing Fields" (_billing_address_index) - * Same as above for shipping - * - * Customer Data (meta): - * - * Billing and shipping addresses + * - Everything exported above for orders and customers + * - _billing_address_index - just an index for searching which needs clearing? + * - _shipping_address_index - just an index for searching which needs clearing? * * Misc: * - * Downloadable Product User Email - * Download Log Entry User IP Address - * Carts for user ID/Sessions - * File based logs containing their email e.g. from webhooks - * Payment tokens? - * - * Ping tracker to anonomize data there as well. + * - Downloadable Product User Email (does not export becasue it matches order/user data). + * - Download logs by user ID and IP address. + * - File based logs containing email? Do search and clear if found. + * - Payment tokens? Check if these need exporting/clearing. Based on User ID. */ } } diff --git a/tests/unit-tests/privacy/export.php b/tests/unit-tests/privacy/export.php index ef6f3837545..75cc649c5e2 100644 --- a/tests/unit-tests/privacy/export.php +++ b/tests/unit-tests/privacy/export.php @@ -70,20 +70,13 @@ class WC_Test_Privacy_Export extends WC_Unit_Test_Case { $response = WC_Privacy::data_exporter( 'test1@test.com', 0 ); $this->assertFalse( $response['done'] ); $this->assertEquals( array( - // 'Billing First Name' => '', - // 'Billing Last Name', => '', - // 'Billing Company', => '', 'Billing Address 1' => '123 South Street', 'Billing Address 2' => 'Apt 1', 'Billing City' => 'Philadelphia', 'Billing Postal/Zip Code' => '19123', 'Billing State' => 'PA', 'Billing Country' => 'US', - // 'Billing Phone' => '', 'Billing Email' => 'customer1@test.com', - // 'Shipping First Name' => '', - // 'Shipping Last Name', => '', - // 'Shipping Company', => '', 'Shipping Address 1' => '123 South Street', 'Shipping Address 2' => 'Apt 1', 'Shipping City' => 'Philadelphia', @@ -96,7 +89,7 @@ class WC_Test_Privacy_Export extends WC_Unit_Test_Case { $response = WC_Privacy::data_exporter( 'test1@test.com', 1 ); $this->assertFalse( $response['done'] ); $this->assertArrayHasKey( 'orders', $response['data'] ); - $this->assertTrue( 10 === count( $response['data']['orders'] ), print_r( $response, true ) ); + $this->assertTrue( 10 === count( $response['data']['orders'] ) ); $this->assertArrayHasKey( 'Order ID', $response['data']['orders'][0] ); $this->assertArrayHasKey( 'Order Number', $response['data']['orders'][0] ); $this->assertArrayHasKey( 'IP Address', $response['data']['orders'][0] ); From 94bfd3b336757705207b745f9bdab97b9dbf713c Mon Sep 17 00:00:00 2001 From: Mike Jolley Date: Thu, 15 Mar 2018 10:54:32 +0000 Subject: [PATCH 10/61] Update formatting and tests --- includes/class-wc-privacy.php | 132 ++++++++++++++++------------ tests/unit-tests/privacy/export.php | 90 +++++++++++++------ 2 files changed, 139 insertions(+), 83 deletions(-) diff --git a/includes/class-wc-privacy.php b/includes/class-wc-privacy.php index e602d66bb31..6b7ed8283b8 100644 --- a/includes/class-wc-privacy.php +++ b/includes/class-wc-privacy.php @@ -45,6 +45,7 @@ class WC_Privacy { public static function data_exporter( $email_address, $page ) { $personal_data = array(); $done = false; + $page = (int) $page; $user = get_user_by( 'email', $email_address ); // Check if user has an ID in the DB to load stored personal data. // Export customer data first. @@ -67,12 +68,9 @@ class WC_Privacy { $orders = wc_get_orders( $order_query ); if ( 0 < count( $orders ) ) { - $personal_data['orders'] = array(); - foreach ( $orders as $order ) { - $personal_data['orders'][] = self::get_order_personal_data( $order ); + $personal_data = array_merge( $personal_data, self::get_order_personal_data( $order ) ); } - $done = 10 > count( $orders ); } else { $done = true; @@ -92,33 +90,52 @@ class WC_Privacy { * @return array */ protected static function get_user_personal_data( $user ) { - $personal_data = array(); - $customer = new WC_Customer( $user->ID ); + $personal_data = array(); + $customer = new WC_Customer( $user->ID ); + $props_to_export = array( + 'billing_first_name' => 'Billing First Name', + 'billing_last_name' => 'Billing Last Name', + 'billing_company' => 'Billing Company', + 'billing_address_1' => 'Billing Address 1', + 'billing_address_2' => 'Billing Address 2', + 'billing_city' => 'Billing City', + 'billing_postcode' => 'Billing Postal/Zip Code', + 'billing_state' => 'Billing State', + 'billing_country' => 'Billing Country', + 'billing_phone' => 'Billing Phone', + 'billing_email' => 'Billing Email', + 'shipping_first_name' => 'Shipping First Name', + 'shipping_last_name' => 'Shipping Last Name', + 'shipping_company' => 'Shipping Company', + 'shipping_address_1' => 'Shipping Address 1', + 'shipping_address_2' => 'Shipping Address 2', + 'shipping_city' => 'Shipping City', + 'shipping_postcode' => 'Shipping Postal/Zip Code', + 'shipping_state' => 'Shipping State', + 'shipping_country' => 'Shipping Country', + ); - if ( $customer ) { - $personal_data['Billing First Name'] = $customer->get_billing_first_name(); - $personal_data['Billing Last Name'] = $customer->get_billing_last_name(); - $personal_data['Billing Company'] = $customer->get_billing_company(); - $personal_data['Billing Address 1'] = $customer->get_billing_address_1(); - $personal_data['Billing Address 2'] = $customer->get_billing_address_2(); - $personal_data['Billing City'] = $customer->get_billing_city(); - $personal_data['Billing Postal/Zip Code'] = $customer->get_billing_postcode(); - $personal_data['Billing State'] = $customer->get_billing_state(); - $personal_data['Billing Country'] = $customer->get_billing_country(); - $personal_data['Billing Phone'] = $customer->get_billing_phone(); - $personal_data['Billing Email'] = $customer->get_billing_email(); - $personal_data['Shipping First Name'] = $customer->get_shipping_first_name(); - $personal_data['Shipping Last Name'] = $customer->get_shipping_last_name(); - $personal_data['Shipping Company'] = $customer->get_shipping_company(); - $personal_data['Shipping Address 1'] = $customer->get_shipping_address_1(); - $personal_data['Shipping Address 2'] = $customer->get_shipping_address_2(); - $personal_data['Shipping City'] = $customer->get_shipping_city(); - $personal_data['Shipping Postal/Zip Code'] = $customer->get_shipping_postcode(); - $personal_data['Shipping State'] = $customer->get_shipping_state(); - $personal_data['Shipping Country'] = $customer->get_shipping_country(); + foreach ( $props_to_export as $prop => $description ) { + $value = $customer->{"get_$prop"}( 'edit' ); + + if ( $value ) { + $personal_data[] = array( + 'name' => $description, + 'value' => $value, + ); + } } - return array_filter( $personal_data ); + /** + * Allow extensions to register their own personal data for this customer for the export. + * + * @since 3.4.0 + * @param array $personal_data Array of name value pairs. + * @param WC_Order $order A customer object. + */ + $personal_data = apply_filters( 'woocommerce_personal_data_export_customer', $personal_data, $customer ); + + return $personal_data; } /** @@ -128,32 +145,39 @@ class WC_Privacy { * @return array */ protected static function get_order_personal_data( $order ) { - return array_filter( array( - 'Order ID' => $order->get_id(), - 'Order Number' => $order->get_order_number(), - 'IP Address' => $order->get_customer_ip_address(), - 'User Agent' => $order->get_customer_user_agent(), - 'Billing First Name' => $order->get_billing_first_name(), - 'Billing Last Name' => $order->get_billing_last_name(), - 'Billing Company' => $order->get_billing_company(), - 'Billing Address 1' => $order->get_billing_address_1(), - 'Billing Address 2' => $order->get_billing_address_2(), - 'Billing City' => $order->get_billing_city(), - 'Billing Postal/Zip Code' => $order->get_billing_postcode(), - 'Billing State' => $order->get_billing_state(), - 'Billing Country' => $order->get_billing_country(), - 'Billing Phone' => $order->get_billing_phone(), - 'Billing Email' => $order->get_billing_email(), - 'Shipping First Name' => $order->get_shipping_first_name(), - 'Shipping Last Name' => $order->get_shipping_last_name(), - 'Shipping Company' => $order->get_shipping_company(), - 'Shipping Address 1' => $order->get_shipping_address_1(), - 'Shipping Address 2' => $order->get_shipping_address_2(), - 'Shipping City' => $order->get_shipping_city(), - 'Shipping Postal/Zip Code' => $order->get_shipping_postcode(), - 'Shipping State' => $order->get_shipping_state(), - 'Shipping Country' => $order->get_shipping_country(), - ) ); + $personal_data = array(); + $props_to_export = array( + 'customer_ip_address' => 'IP Address', + 'customer_user_agent' => 'User Agent', + 'formatted_billing_address' => 'Billing Address', + 'formatted_shipping_address' => 'Shipping Address', + 'billing_phone' => 'Billing Phone', + 'billing_email' => 'Billing Email', + ); + + foreach ( $props_to_export as $prop => $description ) { + /* translators: %1$d: ID of an order, %2$s: Description of an order field */ + $name = sprintf( __( 'Order %1$d: %2$s', 'woocommerce' ), $order->get_id(), $description ); + $value = $order->{"get_$prop"}( 'edit' ); + + if ( $value ) { + $personal_data[] = array( + 'name' => $name, + 'value' => $value, + ); + } + } + + /** + * Allow extensions to register their own personal data for this order for the export. + * + * @since 3.4.0 + * @param array $personal_data Array of name value pairs. + * @param WC_Order $order An order object. + */ + $personal_data = apply_filters( 'woocommerce_personal_data_export_order', $personal_data, $order ); + + return $personal_data; } /** diff --git a/tests/unit-tests/privacy/export.php b/tests/unit-tests/privacy/export.php index 75cc649c5e2..898f012701c 100644 --- a/tests/unit-tests/privacy/export.php +++ b/tests/unit-tests/privacy/export.php @@ -70,42 +70,74 @@ class WC_Test_Privacy_Export extends WC_Unit_Test_Case { $response = WC_Privacy::data_exporter( 'test1@test.com', 0 ); $this->assertFalse( $response['done'] ); $this->assertEquals( array( - 'Billing Address 1' => '123 South Street', - 'Billing Address 2' => 'Apt 1', - 'Billing City' => 'Philadelphia', - 'Billing Postal/Zip Code' => '19123', - 'Billing State' => 'PA', - 'Billing Country' => 'US', - 'Billing Email' => 'customer1@test.com', - 'Shipping Address 1' => '123 South Street', - 'Shipping Address 2' => 'Apt 1', - 'Shipping City' => 'Philadelphia', - 'Shipping Postal/Zip Code' => '19123', - 'Shipping State' => 'PA', - 'Shipping Country' => 'US', + array( + 'name' => 'Billing Address 1', + 'value' => '123 South Street', + ), + array( + 'name' => 'Billing Address 2', + 'value' => 'Apt 1', + ), + array( + 'name' => 'Billing City', + 'value' => 'Philadelphia', + ), + array( + 'name' => 'Billing Postal/Zip Code', + 'value' => '19123', + ), + array( + 'name' => 'Billing State', + 'value' => 'PA', + ), + array( + 'name' => 'Billing Country', + 'value' => 'US', + ), + array( + 'name' => 'Billing Email', + 'value' => 'customer1@test.com', + ), + array( + 'name' => 'Shipping Address 1', + 'value' => '123 South Street', + ), + array( + 'name' => 'Shipping Address 2', + 'value' => 'Apt 1', + ), + array( + 'name' => 'Shipping City', + 'value' => 'Philadelphia', + ), + array( + 'name' => 'Shipping Postal/Zip Code', + 'value' => '19123', + ), + array( + 'name' => 'Shipping State', + 'value' => 'PA', + ), + array( + 'name' => 'Shipping Country', + 'value' => 'US', + ), ), $response['data'] ); // Next page should be orders. $response = WC_Privacy::data_exporter( 'test1@test.com', 1 ); - $this->assertFalse( $response['done'] ); - $this->assertArrayHasKey( 'orders', $response['data'] ); - $this->assertTrue( 10 === count( $response['data']['orders'] ) ); - $this->assertArrayHasKey( 'Order ID', $response['data']['orders'][0] ); - $this->assertArrayHasKey( 'Order Number', $response['data']['orders'][0] ); - $this->assertArrayHasKey( 'IP Address', $response['data']['orders'][0] ); - $this->assertArrayHasKey( 'Billing First Name', $response['data']['orders'][0] ); - $this->assertArrayHasKey( 'Billing Last Name', $response['data']['orders'][0] ); - $this->assertArrayHasKey( 'Billing Company', $response['data']['orders'][0] ); - $this->assertArrayHasKey( 'Billing Address 1', $response['data']['orders'][0] ); - $this->assertArrayHasKey( 'Billing City', $response['data']['orders'][0] ); - $this->assertArrayHasKey( 'Billing Postal/Zip Code', $response['data']['orders'][0] ); - $this->assertArrayHasKey( 'Billing State', $response['data']['orders'][0] ); - $this->assertArrayHasKey( 'Billing Country', $response['data']['orders'][0] ); + $this->assertTrue( 50 === count( $response['data'] ) ); + $this->assertArrayHasKey( 'name', $response['data'][0] ); + $this->assertArrayHasKey( 'value', $response['data'][0] ); + $this->assertContains( 'IP Address', $response['data'][0]['name'] ); + $this->assertContains( 'Billing Address', $response['data'][1]['name'] ); + $this->assertContains( 'Shipping Address', $response['data'][2]['name'] ); + $this->assertContains( 'Billing Phone', $response['data'][3]['name'] ); + $this->assertContains( 'Billing Email', $response['data'][4]['name'] ); // Next page should be orders. $response = WC_Privacy::data_exporter( 'test1@test.com', 2 ); $this->assertTrue( $response['done'] ); - $this->assertArrayHasKey( 'orders', $response['data'] ); - $this->assertTrue( 1 === count( $response['data']['orders'] ), count( $response['data']['orders'] ) ); + $this->assertTrue( 5 === count( $response['data'] ) ); } } From 7a568e2f68552c5f577ec539ced0cd300050a9b1 Mon Sep 17 00:00:00 2001 From: Mike Jolley Date: Fri, 16 Mar 2018 13:53:18 +0000 Subject: [PATCH 11/61] Personal data removal experiment --- .../class-wc-admin-list-table-orders.php | 88 +++++----- .../class-wc-meta-box-order-data.php | 8 +- includes/class-wc-privacy.php | 153 ++++++++++++++++-- includes/wc-core-functions.php | 2 +- 4 files changed, 195 insertions(+), 56 deletions(-) diff --git a/includes/admin/list-tables/class-wc-admin-list-table-orders.php b/includes/admin/list-tables/class-wc-admin-list-table-orders.php index fdc80d1bb25..eca4550cb86 100644 --- a/includes/admin/list-tables/class-wc-admin-list-table-orders.php +++ b/includes/admin/list-tables/class-wc-admin-list-table-orders.php @@ -135,9 +135,10 @@ class WC_Admin_List_Table_Orders extends WC_Admin_List_Table { unset( $actions['edit'] ); } - $actions['mark_processing'] = __( 'Change status to processing', 'woocommerce' ); - $actions['mark_on-hold'] = __( 'Change status to on-hold', 'woocommerce' ); - $actions['mark_completed'] = __( 'Change status to completed', 'woocommerce' ); + $actions['mark_processing'] = __( 'Change status to processing', 'woocommerce' ); + $actions['mark_on-hold'] = __( 'Change status to on-hold', 'woocommerce' ); + $actions['mark_completed'] = __( 'Change status to completed', 'woocommerce' ); + $actions['remove_personal_data'] = __( 'Remove personal data', 'woocommerce' ); return $actions; } @@ -622,39 +623,46 @@ class WC_Admin_List_Table_Orders extends WC_Admin_List_Table { * @return string */ public function handle_bulk_actions( $redirect_to, $action, $ids ) { - // Bail out if this is not a status-changing action. - if ( false === strpos( $action, 'mark_' ) ) { - return $redirect_to; - } - - $order_statuses = wc_get_order_statuses(); - $new_status = substr( $action, 5 ); // Get the status name from action. - $report_action = 'marked_' . $new_status; - - // Sanity check: bail out if this is actually not a status, or is - // not a registered status. - if ( ! isset( $order_statuses[ 'wc-' . $new_status ] ) ) { - return $redirect_to; - } - - $changed = 0; $ids = array_map( 'absint', $ids ); + $changed = 0; - foreach ( $ids as $id ) { - $order = wc_get_order( $id ); - $order->update_status( $new_status, __( 'Order status changed by bulk edit:', 'woocommerce' ), true ); - do_action( 'woocommerce_order_edit_status', $id, $new_status ); - $changed++; + if ( 'remove_personal_data' === $action ) { + $report_action = 'removed_personal_data'; + + foreach ( $ids as $id ) { + $order = wc_get_order( $id ); + + if ( $order ) { + do_action( 'woocommerce_remove_order_personal_data', $order ); + $changed++; + } + } + } elseif ( false !== strpos( $action, 'mark_' ) ) { + $order_statuses = wc_get_order_statuses(); + $new_status = substr( $action, 5 ); // Get the status name from action. + $report_action = 'marked_' . $new_status; + + // Sanity check: bail out if this is actually not a status, or is not a registered status. + if ( isset( $order_statuses[ 'wc-' . $new_status ] ) ) { + foreach ( $ids as $id ) { + $order = wc_get_order( $id ); + $order->update_status( $new_status, __( 'Order status changed by bulk edit:', 'woocommerce' ), true ); + do_action( 'woocommerce_order_edit_status', $id, $new_status ); + $changed++; + } + } } - $redirect_to = add_query_arg( - array( - 'post_type' => $this->list_table_type, - $report_action => true, - 'changed' => $changed, - 'ids' => join( ',', $ids ), - ), $redirect_to - ); + if ( $changed ) { + $redirect_to = add_query_arg( + array( + 'post_type' => $this->list_table_type, + 'bulk_action' => $report_action, + 'changed' => $changed, + 'ids' => join( ',', $ids ), + ), $redirect_to + ); + } return esc_url_raw( $redirect_to ); } @@ -666,23 +674,29 @@ class WC_Admin_List_Table_Orders extends WC_Admin_List_Table { global $post_type, $pagenow; // Bail out if not on shop order list page. - if ( 'edit.php' !== $pagenow || 'shop_order' !== $post_type ) { + if ( 'edit.php' !== $pagenow || 'shop_order' !== $post_type || ! isset( $_REQUEST['bulk_action'] ) ) { // WPCS: input var ok, CSRF ok. return; } $order_statuses = wc_get_order_statuses(); + $number = isset( $_REQUEST['changed'] ) ? absint( $_REQUEST['changed'] ) : 0; // WPCS: input var ok, CSRF ok. + $bulk_action = wc_clean( wp_unslash( $_REQUEST['bulk_action'] ) ); // WPCS: input var ok, CSRF ok. // Check if any status changes happened. foreach ( $order_statuses as $slug => $name ) { - if ( isset( $_REQUEST[ 'marked_' . str_replace( 'wc-', '', $slug ) ] ) ) { // WPCS: input var ok. - - $number = isset( $_REQUEST['changed'] ) ? absint( $_REQUEST['changed'] ) : 0; // WPCS: input var ok. - /* translators: %s: orders count */ + if ( 'marked_' . str_replace( 'wc-', '', $slug ) === $bulk_action ) { // WPCS: input var ok, CSRF ok. + /* translators: %d: orders count */ $message = sprintf( _n( '%d order status changed.', '%d order statuses changed.', $number, 'woocommerce' ), number_format_i18n( $number ) ); echo '

' . esc_html( $message ) . '

'; break; } } + + if ( 'removed_personal_data' === $bulk_action ) { // WPCS: input var ok, CSRF ok. + /* translators: %d: orders count */ + $message = sprintf( _n( 'Removed personal data from %d order.', 'Removed personal data from %d orders.', $number, 'woocommerce' ), number_format_i18n( $number ) ); + echo '

' . esc_html( $message ) . '

'; + } } /** diff --git a/includes/admin/meta-boxes/class-wc-meta-box-order-data.php b/includes/admin/meta-boxes/class-wc-meta-box-order-data.php index f4fe56b0dcb..b12b94b9fb1 100644 --- a/includes/admin/meta-boxes/class-wc-meta-box-order-data.php +++ b/includes/admin/meta-boxes/class-wc-meta-box-order-data.php @@ -344,7 +344,9 @@ class WC_Meta_Box_Order_Data { $field_value = make_clickable( esc_html( $field_value ) ); } - echo '

' . esc_html( $field['label'] ) . ': ' . wp_kses_post( $field_value ) . '

'; + if ( $field_value ) { + echo '

' . esc_html( $field['label'] ) . ': ' . wp_kses_post( $field_value ) . '

'; + } } ?> @@ -440,7 +442,9 @@ class WC_Meta_Box_Order_Data { $field_value = $order->get_meta( '_' . $field_name ); } - echo '

' . esc_html( $field['label'] ) . ': ' . make_clickable( esc_html( $field_value ) ) . '

'; + if ( $field_value ) { + echo '

' . esc_html( $field['label'] ) . ': ' . wp_kses_post( $field_value ) . '

'; + } } } diff --git a/includes/class-wc-privacy.php b/includes/class-wc-privacy.php index 6b7ed8283b8..dbc505b1aa8 100644 --- a/includes/class-wc-privacy.php +++ b/includes/class-wc-privacy.php @@ -17,6 +17,7 @@ class WC_Privacy { */ public static function init() { add_filter( 'wp_privacy_personal_data_exporters', array( __CLASS__, 'register_data_exporter' ), 10 ); + add_action( 'woocommerce_remove_order_personal_data', array( __CLASS__, 'remove_order_personal_data' ) ); } /** @@ -83,6 +84,28 @@ class WC_Privacy { ); } + /** + * Anonymize/remove personal data for a given email address. + * + * @param string $email Email address. + */ + public static function remove_personal_data( $email ) { + /** + * Personal Data: + * + * - Everything exported above for orders and customers + * - _billing_address_index - just an index for searching which needs clearing? + * - _shipping_address_index - just an index for searching which needs clearing? + * + * Misc: + * + * - Downloadable Product User Email (does not export becasue it matches order/user data). + * - Download logs by user ID and IP address. + * - File based logs containing email? Do search and clear if found. + * - Payment tokens? Check if these need exporting/clearing. Based on User ID. + */ + } + /** * Get personal data (key/value pairs) for a user object. * @@ -133,7 +156,7 @@ class WC_Privacy { * @param array $personal_data Array of name value pairs. * @param WC_Order $order A customer object. */ - $personal_data = apply_filters( 'woocommerce_personal_data_export_customer', $personal_data, $customer ); + $personal_data = apply_filters( 'woocommerce_privacy_export_personal_data_customer', $personal_data, $customer ); return $personal_data; } @@ -175,31 +198,129 @@ class WC_Privacy { * @param array $personal_data Array of name value pairs. * @param WC_Order $order An order object. */ - $personal_data = apply_filters( 'woocommerce_personal_data_export_order', $personal_data, $order ); + $personal_data = apply_filters( 'woocommerce_privacy_export_personal_data_order', $personal_data, $order ); return $personal_data; } /** - * Anonymize/remove personal data for a given email address. + * Remove personal data specific to WooCommerce from a user object. * - * @param string $email Email address. + * @param WP_User $user user object. */ - public static function remove_personal_data( $email ) { + protected static function remove_user_personal_data( $user ) { + $customer = new WC_Customer( $user->ID ); + $props_to_remove = array( + 'billing_first_name' => '__return_empty_string', + 'billing_last_name' => '__return_empty_string', + 'billing_company' => '__return_empty_string', + 'billing_address_1' => '__return_empty_string', + 'billing_address_2' => '__return_empty_string', + 'billing_city' => '__return_empty_string', + 'billing_postcode' => '__return_empty_string', + 'billing_state' => '__return_empty_string', + 'billing_country' => '__return_empty_string', + 'billing_phone' => '__return_empty_string', + 'billing_email' => '__return_empty_string', + 'shipping_first_name' => '__return_empty_string', + 'shipping_last_name' => '__return_empty_string', + 'shipping_company' => '__return_empty_string', + 'shipping_address_1' => '__return_empty_string', + 'shipping_address_2' => '__return_empty_string', + 'shipping_city' => '__return_empty_string', + 'shipping_postcode' => '__return_empty_string', + 'shipping_state' => '__return_empty_string', + 'shipping_country' => '__return_empty_string', + ); + foreach ( $props_to_remove as $prop => $callback ) { + $customer->{"set_$prop"}( call_user_func( $callback, $customer->{"get_$prop"} ) ); + } + /** - * Personal Data: + * Allow extensions to remove their own personal data for this customer. * - * - Everything exported above for orders and customers - * - _billing_address_index - just an index for searching which needs clearing? - * - _shipping_address_index - just an index for searching which needs clearing? - * - * Misc: - * - * - Downloadable Product User Email (does not export becasue it matches order/user data). - * - Download logs by user ID and IP address. - * - File based logs containing email? Do search and clear if found. - * - Payment tokens? Check if these need exporting/clearing. Based on User ID. + * @since 3.4.0 + * @param WC_Order $order A customer object. */ + do_action( 'woocommerce_privacy_remove_personal_data_customer', $customer ); + + $customer->save(); + } + + /** + * Remove personal data specific to WooCommerce from an order object. + * + * Note; this will hinder order processing for obvious reasons! + * + * @param WC_Order $order Order object. + */ + public static function remove_order_personal_data( $order ) { + $props_to_remove = array( + 'customer_ip_address' => '__return_empty_string', + 'customer_user_agent' => '__return_empty_string', + 'billing_first_name' => '__return_empty_string', + 'billing_last_name' => '__return_empty_string', + 'billing_company' => '__return_empty_string', + 'billing_address_1' => '__return_empty_string', + 'billing_address_2' => '__return_empty_string', + 'billing_city' => '__return_empty_string', + 'billing_postcode' => '__return_empty_string', + 'billing_state' => '__return_empty_string', + 'billing_country' => '__return_empty_string', + 'billing_phone' => '__return_empty_string', + 'billing_email' => array( __CLASS__, 'mask_email' ), + 'shipping_first_name' => '__return_empty_string', + 'shipping_last_name' => '__return_empty_string', + 'shipping_company' => '__return_empty_string', + 'shipping_address_1' => '__return_empty_string', + 'shipping_address_2' => '__return_empty_string', + 'shipping_city' => '__return_empty_string', + 'shipping_postcode' => '__return_empty_string', + 'shipping_state' => '__return_empty_string', + 'shipping_country' => '__return_empty_string', + ); + foreach ( $props_to_remove as $prop => $callback ) { + $order->{"set_$prop"}( call_user_func( $callback, $order->{"get_$prop"}( 'edit' ) ) ); + } + + /** + * Allow extensions to remove their own personal data for this order. + * + * @since 3.4.0 + * @param WC_Order $order A customer object. + */ + do_action( 'woocommerce_privacy_remove_personal_data_order', $order ); + + $order->save(); + $order->add_order_note( __( 'Personal data removed.', 'woocommerce' ) ); + } + + /** + * Mask an email address. + * + * @param string $email Email to mask. + * @return string + */ + protected static function mask_email( $email ) { + if ( ! $email ) { + return ''; + } + + $min_length = 3; + $max_length = 10; + $mask = "***"; + $at_pos = strrpos( $email, '@' ); + $name = substr( $email, 0, $at_pos ); + $length = strlen( $name ); + $domain = substr( $email, $at_pos ); + + if ( ( $length / 2 ) < $max_length ) { + $max_length = $length / 2; + } + + $masked_email = $length > $min_length ? substr( $name, 0, $max_length ) : ''; + + return "{$masked_email}{$mask}{$domain}"; } } diff --git a/includes/wc-core-functions.php b/includes/wc-core-functions.php index 6822904ec20..1d5011f3f4b 100644 --- a/includes/wc-core-functions.php +++ b/includes/wc-core-functions.php @@ -1866,7 +1866,7 @@ function wc_restore_locale() { function wc_make_phone_clickable( $phone ) { $number = trim( preg_replace( '/[^\d|\+]/', '', $phone ) ); - return '' . esc_html( $phone ) . ''; + return $number ? '' . esc_html( $phone ) . '' : ''; } /** From c1b5fcb343405652e6840527d01f87ae54ef4d95 Mon Sep 17 00:00:00 2001 From: Shahjahan Jewel Date: Mon, 2 Apr 2018 20:53:07 +0600 Subject: [PATCH 12/61] The new spellings of BD Districts Bangladesh Government changed names of 5 Districts --- i18n/states/BD.php | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/i18n/states/BD.php b/i18n/states/BD.php index 3d0a099d0b7..26f7a3eccf3 100644 --- a/i18n/states/BD.php +++ b/i18n/states/BD.php @@ -14,15 +14,15 @@ $states['BD'] = array( 'BAG' => __( 'Bagerhat', 'woocommerce' ), 'BAN' => __( 'Bandarban', 'woocommerce' ), 'BAR' => __( 'Barguna', 'woocommerce' ), - 'BARI' => __( 'Barisal', 'woocommerce' ), + 'BARI' => __( 'Barishal', 'woocommerce' ), 'BHO' => __( 'Bhola', 'woocommerce' ), - 'BOG' => __( 'Bogra', 'woocommerce' ), + 'BOG' => __( 'Bogura', 'woocommerce' ), 'BRA' => __( 'Brahmanbaria', 'woocommerce' ), 'CHA' => __( 'Chandpur', 'woocommerce' ), - 'CHI' => __( 'Chittagong', 'woocommerce' ), + 'CHA' => __( 'Chattogram', 'woocommerce' ), 'CHU' => __( 'Chuadanga', 'woocommerce' ), - 'COM' => __( 'Comilla', 'woocommerce' ), 'COX' => __( "Cox's Bazar", 'woocommerce' ), + 'CUM' => __( 'Cumilla', 'woocommerce' ), 'DHA' => __( 'Dhaka', 'woocommerce' ), 'DIN' => __( 'Dinajpur', 'woocommerce' ), 'FAR' => __( 'Faridpur ', 'woocommerce' ), @@ -32,7 +32,7 @@ $states['BD'] = array( 'GOP' => __( 'Gopalganj', 'woocommerce' ), 'HAB' => __( 'Habiganj', 'woocommerce' ), 'JAM' => __( 'Jamalpur', 'woocommerce' ), - 'JES' => __( 'Jessore', 'woocommerce' ), + 'JAS' => __( 'Jashore', 'woocommerce' ), 'JHA' => __( 'Jhalokati', 'woocommerce' ), 'JHE' => __( 'Jhenaidah', 'woocommerce' ), 'JOY' => __( 'Joypurhat', 'woocommerce' ), From 1f5d4050b3fa43c67e07c91c31752ca6adf3c71b Mon Sep 17 00:00:00 2001 From: Daniel Bitzer Date: Thu, 5 Apr 2018 13:58:51 +0200 Subject: [PATCH 13/61] Set created_via propery for orders created in admin area --- includes/admin/meta-boxes/class-wc-meta-box-order-data.php | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/includes/admin/meta-boxes/class-wc-meta-box-order-data.php b/includes/admin/meta-boxes/class-wc-meta-box-order-data.php index 7a3543a3787..ce8297aec76 100644 --- a/includes/admin/meta-boxes/class-wc-meta-box-order-data.php +++ b/includes/admin/meta-boxes/class-wc-meta-box-order-data.php @@ -600,6 +600,11 @@ class WC_Meta_Box_Order_Data { $props['date_created'] = $date; + // Set created via prop if new post. + if ( isset( $_POST['original_post_status'] ) && $_POST['original_post_status'] === 'auto-draft' ) { + $props['created_via'] = 'admin'; + } + // Save order data. $order->set_props( $props ); $order->set_status( wc_clean( $_POST['order_status'] ), '', true ); From b3bf2459298eeb043d135f32d7968d62c4c0e27b Mon Sep 17 00:00:00 2001 From: Claudio Sanches Date: Fri, 6 Apr 2018 13:58:59 -0300 Subject: [PATCH 14/61] Introduced new wc_get_product_class() and wc_product_class functions --- includes/wc-template-functions.php | 118 +++++++++++++++++++++++++++++ 1 file changed, 118 insertions(+) diff --git a/includes/wc-template-functions.php b/includes/wc-template-functions.php index 7083b89ab80..f65bebbbdc7 100644 --- a/includes/wc-template-functions.php +++ b/includes/wc-template-functions.php @@ -512,6 +512,124 @@ function wc_product_post_class( $classes, $class = '', $post_id = '' ) { return $classes; } +/** + * Retrieves the classes for the post div as an array. + * + * This method is clone from WordPress's get_post_class(), allowing removing taxonomies. + * + * @since 3.4.0 + * @param string|array $class One or more classes to add to the class list. + * @param int|WP_Post|WC_Product $product_id Product ID or product object. + * @return array + */ +function wc_get_product_class( $class = '', $product_id = null ) { + if ( is_a( $product_id, 'WC_Product' ) ) { + $product_id = $product_id->get_id(); + } + + $post = get_post( $product_id ); + $classes = array(); + + if ( $class ) { + if ( ! is_array( $class ) ) { + $class = preg_split( '#\s+#', $class ); + } + $classes = array_map( 'esc_attr', $class ); + } else { + // Ensure that we always coerce class to being an array. + $class = array(); + } + + if ( ! $post ) { + return $classes; + } + + $classes[] = 'post-' . $post->ID; + if ( ! is_admin() ) { + $classes[] = $post->post_type; + } + $classes[] = 'type-' . $post->post_type; + $classes[] = 'status-' . $post->post_status; + + // Post format. + if ( post_type_supports( $post->post_type, 'post-formats' ) ) { + $post_format = get_post_format( $post->ID ); + + if ( $post_format && ! is_wp_error( $post_format ) ) { + $classes[] = 'format-' . sanitize_html_class( $post_format ); + } else { + $classes[] = 'format-standard'; + } + } + + // Post requires password. + $post_password_required = post_password_required( $post->ID ); + if ( $post_password_required ) { + $classes[] = 'post-password-required'; + } elseif ( ! empty( $post->post_password ) ) { + $classes[] = 'post-password-protected'; + } + + // Post thumbnails. + if ( current_theme_supports( 'post-thumbnails' ) && has_post_thumbnail( $post->ID ) && ! is_attachment( $post ) && ! $post_password_required ) { + $classes[] = 'has-post-thumbnail'; + } + + // Sticky for Sticky Posts. + if ( is_sticky( $post->ID ) ) { + if ( is_home() && ! is_paged() ) { + $classes[] = 'sticky'; + } elseif ( is_admin() ) { + $classes[] = 'status-sticky'; + } + } + + // Hentry for hAtom compliance. + $classes[] = 'hentry'; + + // All public taxonomies. + if ( apply_filters( 'woocommerce_get_product_class_include_taxonomies', false ) ) { + $taxonomies = get_taxonomies( array( 'public' => true ) ); + foreach ( (array) $taxonomies as $taxonomy ) { + if ( is_object_in_taxonomy( $post->post_type, $taxonomy ) ) { + foreach ( (array) get_the_terms( $post->ID, $taxonomy ) as $term ) { + if ( empty( $term->slug ) ) { + continue; + } + + $term_class = sanitize_html_class( $term->slug, $term->term_id ); + if ( is_numeric( $term_class ) || ! trim( $term_class, '-' ) ) { + $term_class = $term->term_id; + } + + // 'post_tag' uses the 'tag' prefix for backward compatibility. + if ( 'post_tag' === $taxonomy ) { + $classes[] = 'tag-' . $term_class; + } else { + $classes[] = sanitize_html_class( $taxonomy . '-' . $term_class, $taxonomy . '-' . $term->term_id ); + } + } + } + } + } + + $classes = array_map( 'esc_attr', $classes ); + $classes = apply_filters( 'post_class', $classes, $class, $post->ID ); + + return array_unique( $classes ); +} + +/** + * Display the classes for the product div. + * + * @since 3.4.0 + * @param string|array $class One or more classes to add to the class list. + * @param int|WP_Post|WC_Product $product_id Product ID or product object. + */ +function wc_product_class( $class = '', $product_id = null ) { + echo 'class="' . join( ' ', wc_get_product_class( $classes, $product_id ) ) . '"'; // WPCS: XSS ok. +} + /** * Outputs hidden form inputs for each query string variable. * From 1e58c3f2a0ed25877f8cfae8beb19d70da50acef Mon Sep 17 00:00:00 2001 From: Claudio Sanches Date: Fri, 6 Apr 2018 14:03:38 -0300 Subject: [PATCH 15/61] Replaced post_class() to wc_product_class() --- templates/content-product.php | 21 ++++++++----------- templates/content-single-product.php | 15 ++++++------- .../single-product/add-to-cart/grouped.php | 2 +- 3 files changed, 16 insertions(+), 22 deletions(-) diff --git a/templates/content-product.php b/templates/content-product.php index bc8204642b8..36ffa701aa0 100644 --- a/templates/content-product.php +++ b/templates/content-product.php @@ -11,33 +11,30 @@ * the readme will list any important changes. * * @see https://docs.woocommerce.com/document/template-structure/ - * @author WooThemes * @package WooCommerce/Templates - * @version 3.0.0 + * @version 3.4.0 */ -if ( ! defined( 'ABSPATH' ) ) { - exit; // Exit if accessed directly -} +defined( 'ABSPATH' ) || exit; global $product; -// Ensure visibility +// Ensure visibility. if ( empty( $product ) || ! $product->is_visible() ) { return; } ?> -
  • > +
  • > is_visible() ) { do_action( 'woocommerce_before_shop_loop_item_title' ); /** - * woocommerce_shop_loop_item_title hook. + * Hook: woocommerce_shop_loop_item_title. * * @hooked woocommerce_template_loop_product_title - 10 */ do_action( 'woocommerce_shop_loop_item_title' ); /** - * woocommerce_after_shop_loop_item_title hook. + * Hook: woocommerce_after_shop_loop_item_title. * * @hooked woocommerce_template_loop_rating - 5 * @hooked woocommerce_template_loop_price - 10 @@ -60,7 +57,7 @@ if ( empty( $product ) || ! $product->is_visible() ) { do_action( 'woocommerce_after_shop_loop_item_title' ); /** - * woocommerce_after_shop_loop_item hook. + * Hook: woocommerce_after_shop_loop_item. * * @hooked woocommerce_template_loop_product_link_close - 5 * @hooked woocommerce_template_loop_add_to_cart - 10 diff --git a/templates/content-single-product.php b/templates/content-single-product.php index e26a6421b97..875eff16f4c 100644 --- a/templates/content-single-product.php +++ b/templates/content-single-product.php @@ -10,18 +10,15 @@ * happen. When this occurs the version of the template file will be bumped and * the readme will list any important changes. * - * @see https://docs.woocommerce.com/document/template-structure/ - * @author WooThemes - * @package WooCommerce/Templates - * @version 3.0.0 + * @see https://docs.woocommerce.com/document/template-structure/ + * @package WooCommerce/Templates + * @version 3.4.0 */ -if ( ! defined( 'ABSPATH' ) ) { - exit; -} +defined( 'ABSPATH' ) || exit; /** - * Hook Woocommerce_before_single_product. + * Hook: woocommerce_before_single_product. * * @hooked wc_print_notices - 10 */ @@ -32,7 +29,7 @@ if ( post_password_required() ) { return; } ?> -
    > +
    > $post = $post_object; // WPCS: override ok. setup_postdata( $post ); - echo ''; + echo ''; // Output columns for each product. foreach ( $grouped_product_columns as $column_id ) { From a10689ce40744659f63d19a64c1742e54cc26406 Mon Sep 17 00:00:00 2001 From: Claudio Sanches Date: Fri, 6 Apr 2018 14:47:18 -0300 Subject: [PATCH 16/61] Added unit tests for wc_get_product_class() --- tests/unit-tests/templates/functions.php | 41 ++++++++++++++++++++++++ 1 file changed, 41 insertions(+) create mode 100644 tests/unit-tests/templates/functions.php diff --git a/tests/unit-tests/templates/functions.php b/tests/unit-tests/templates/functions.php new file mode 100644 index 00000000000..266908a8b5e --- /dev/null +++ b/tests/unit-tests/templates/functions.php @@ -0,0 +1,41 @@ +set_virtual( true ); + $product->set_regular_price( '10' ); + $product->set_sale_price( '5' ); + $product->save(); + + $expected = array( + 'foo', + 'post-' . $product->get_id(), + 'product', + 'type-product', + 'status-publish', + 'first', + 'instock', + 'sale', + 'virtual', + 'purchasable', + 'product-type-simple', + ); + + $this->assertEquals( $expected, array_values( wc_get_product_class( 'foo', $product ) ) ); + } +} From 53b000cb8782ff1a318f55c248b2417deca893fe Mon Sep 17 00:00:00 2001 From: Claudio Sanches Date: Fri, 6 Apr 2018 14:49:20 -0300 Subject: [PATCH 17/61] Remove product after unit test --- tests/unit-tests/templates/functions.php | 2 ++ 1 file changed, 2 insertions(+) diff --git a/tests/unit-tests/templates/functions.php b/tests/unit-tests/templates/functions.php index 266908a8b5e..1f2fb58961a 100644 --- a/tests/unit-tests/templates/functions.php +++ b/tests/unit-tests/templates/functions.php @@ -37,5 +37,7 @@ class WC_Tests_Template_Functions extends WC_Unit_Test_Case { ); $this->assertEquals( $expected, array_values( wc_get_product_class( 'foo', $product ) ) ); + + $product->delete( true ); } } From 60ad91266da49891073e1d655f22949640aca641 Mon Sep 17 00:00:00 2001 From: Claudio Sanches Date: Fri, 6 Apr 2018 15:08:11 -0300 Subject: [PATCH 18/61] Fixed wrong variable --- includes/wc-template-functions.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/includes/wc-template-functions.php b/includes/wc-template-functions.php index f65bebbbdc7..19ae0701433 100644 --- a/includes/wc-template-functions.php +++ b/includes/wc-template-functions.php @@ -627,7 +627,7 @@ function wc_get_product_class( $class = '', $product_id = null ) { * @param int|WP_Post|WC_Product $product_id Product ID or product object. */ function wc_product_class( $class = '', $product_id = null ) { - echo 'class="' . join( ' ', wc_get_product_class( $classes, $product_id ) ) . '"'; // WPCS: XSS ok. + echo 'class="' . join( ' ', wc_get_product_class( $class, $product_id ) ) . '"'; // WPCS: XSS ok. } /** From 6dff55354825d9d15961c1347c660d2591b9ec19 Mon Sep 17 00:00:00 2001 From: Mike Jolley Date: Tue, 10 Apr 2018 11:45:31 +0100 Subject: [PATCH 19/61] Make markup in external product add to cart form mirror simple products with button/form elements. --- .../single-product/add-to-cart/external.php | 21 +++++++++++-------- 1 file changed, 12 insertions(+), 9 deletions(-) diff --git a/templates/single-product/add-to-cart/external.php b/templates/single-product/add-to-cart/external.php index afd25e86bea..d0f6a684c5a 100644 --- a/templates/single-product/add-to-cart/external.php +++ b/templates/single-product/add-to-cart/external.php @@ -10,18 +10,21 @@ * happen. When this occurs the version of the template file will be bumped and * the readme will list any important changes. * - * @see https://docs.woocommerce.com/document/template-structure/ - * @author WooThemes - * @package WooCommerce/Templates - * @version 2.1.0 + * @see https://docs.woocommerce.com/document/template-structure/ + * @package WooCommerce/Templates + * @version 3.4.0 */ defined( 'ABSPATH' ) || exit; -do_action( 'woocommerce_before_add_to_cart_button' ); ?> +do_action( 'woocommerce_before_add_to_cart_form' ); ?> -

    - -

    +
    + - + + + +
    + + From 2983753809f45694af2365b6ea099e2840ccf8be Mon Sep 17 00:00:00 2001 From: Mike Jolley Date: Tue, 10 Apr 2018 11:57:49 +0100 Subject: [PATCH 20/61] Update action placement so all product types are consistent. Also fixes phpcs. --- .../single-product/add-to-cart/simple.php | 42 +++++++------------ .../single-product/add-to-cart/variable.php | 34 ++++++++------- .../variation-add-to-cart-button.php | 31 +++++++------- 3 files changed, 48 insertions(+), 59 deletions(-) diff --git a/templates/single-product/add-to-cart/simple.php b/templates/single-product/add-to-cart/simple.php index 3806c9267ef..bc4cfc02c4d 100644 --- a/templates/single-product/add-to-cart/simple.php +++ b/templates/single-product/add-to-cart/simple.php @@ -10,9 +10,9 @@ * happen. When this occurs the version of the template file will be bumped and * the readme will list any important changes. * - * @see https://docs.woocommerce.com/document/template-structure/ - * @package WooCommerce/Templates - * @version 3.4.0 + * @see https://docs.woocommerce.com/document/template-structure/ + * @package WooCommerce/Templates + * @version 3.4.0 */ defined( 'ABSPATH' ) || exit; @@ -23,44 +23,30 @@ if ( ! $product->is_purchasable() ) { return; } -echo wc_get_stock_html( $product ); +echo wc_get_stock_html( $product ); // WPCS: XSS ok. if ( $product->is_in_stock() ) : ?>
    + + apply_filters( 'woocommerce_quantity_input_min', $product->get_min_purchase_quantity(), $product ), + 'max_value' => apply_filters( 'woocommerce_quantity_input_max', $product->get_max_purchase_quantity(), $product ), + 'input_value' => isset( $_POST['quantity'] ) ? wc_stock_amount( wp_unslash( $_POST['quantity'] ) ) : $product->get_min_purchase_quantity(), // WPCS: CSRF ok, input var ok. + ) ); - woocommerce_quantity_input( array( - 'min_value' => apply_filters( 'woocommerce_quantity_input_min', $product->get_min_purchase_quantity(), $product ), - 'max_value' => apply_filters( 'woocommerce_quantity_input_max', $product->get_max_purchase_quantity(), $product ), - 'input_value' => isset( $_POST['quantity'] ) ? wc_stock_amount( $_POST['quantity'] ) : $product->get_min_purchase_quantity(), - ) ); - - /** - * @since 3.0.0. - */ - do_action( 'woocommerce_after_add_to_cart_quantity' ); + do_action( 'woocommerce_after_add_to_cart_quantity' ); ?> - +
    diff --git a/templates/single-product/add-to-cart/variable.php b/templates/single-product/add-to-cart/variable.php index cbc536f8608..74f3d7f5682 100644 --- a/templates/single-product/add-to-cart/variable.php +++ b/templates/single-product/add-to-cart/variable.php @@ -10,7 +10,7 @@ * happen. When this occurs the version of the template file will be bumped and * the readme will list any important changes. * - * @see https://docs.woocommerce.com/document/template-structure/ + * @see https://docs.woocommerce.com/document/template-structure/ * @package WooCommerce/Templates * @version 3.4.0 */ @@ -23,40 +23,46 @@ $attribute_keys = array_keys( $attributes ); do_action( 'woocommerce_before_add_to_cart_form' ); ?> -
    + -

    +

    $options ) : ?> - + - +
    get_variation_default_attribute( $attribute_name ); - wc_dropdown_variation_attribute_options( array( 'options' => $options, 'attribute' => $attribute_name, 'product' => $product, 'selected' => $selected ) ); - echo end( $attribute_keys ) === $attribute_name ? apply_filters( 'woocommerce_reset_variations_link', '' . esc_html__( 'Clear', 'woocommerce' ) . '' ) : ''; + $selected = isset( $_REQUEST[ 'attribute_' . $attribute_name ] ) ? wc_clean( urldecode( wp_unslash( $_REQUEST[ 'attribute_' . $attribute_name ] ) ) ) : $product->get_variation_default_attribute( $attribute_name ); // WPCS: input var ok, CSRF ok, sanitization ok. + + wc_dropdown_variation_attribute_options( array( + 'options' => $options, + 'attribute' => $attribute_name, + 'product' => $product, + 'selected' => $selected, + ) ); + + echo end( $attribute_keys ) === $attribute_name ? wp_kses_post( apply_filters( 'woocommerce_reset_variations_link', '' . esc_html__( 'Clear', 'woocommerce' ) . '' ) ) : ''; ?>
    - -
    do_action( 'woocommerce_single_variation' ); /** - * woocommerce_after_single_variation Hook. + * Woocommerce_after_single_variation Hook. */ do_action( 'woocommerce_after_single_variation' ); ?>
    - - diff --git a/templates/single-product/add-to-cart/variation-add-to-cart-button.php b/templates/single-product/add-to-cart/variation-add-to-cart-button.php index baf41c90242..81019ce85a6 100644 --- a/templates/single-product/add-to-cart/variation-add-to-cart-button.php +++ b/templates/single-product/add-to-cart/variation-add-to-cart-button.php @@ -2,10 +2,9 @@ /** * Single variation cart button * - * @see https://docs.woocommerce.com/document/template-structure/ - * @author WooThemes + * @see https://docs.woocommerce.com/document/template-structure/ * @package WooCommerce/Templates - * @version 3.0.0 + * @version 3.4.0 */ defined( 'ABSPATH' ) || exit; @@ -13,24 +12,24 @@ defined( 'ABSPATH' ) || exit; global $product; ?>
    + + apply_filters( 'woocommerce_quantity_input_min', $product->get_min_purchase_quantity(), $product ), - 'max_value' => apply_filters( 'woocommerce_quantity_input_max', $product->get_max_purchase_quantity(), $product ), - 'input_value' => isset( $_POST['quantity'] ) ? wc_stock_amount( $_POST['quantity'] ) : $product->get_min_purchase_quantity(), - ) ); + woocommerce_quantity_input( array( + 'min_value' => apply_filters( 'woocommerce_quantity_input_min', $product->get_min_purchase_quantity(), $product ), + 'max_value' => apply_filters( 'woocommerce_quantity_input_max', $product->get_max_purchase_quantity(), $product ), + 'input_value' => isset( $_POST['quantity'] ) ? wc_stock_amount( wp_unslash( $_POST['quantity'] ) ) : $product->get_min_purchase_quantity(), // WPCS: CSRF ok, input var ok. + ) ); - /** - * @since 3.0.0. - */ - do_action( 'woocommerce_after_add_to_cart_quantity' ); + do_action( 'woocommerce_after_add_to_cart_quantity' ); ?> + + + + From 73709ee7cd18dab2065e0d35d0737413f31d03dd Mon Sep 17 00:00:00 2001 From: Mike Jolley Date: Tue, 10 Apr 2018 14:43:38 +0100 Subject: [PATCH 21/61] Slash meta values before updating the DB in the data store --- includes/data-stores/class-wc-product-data-store-cpt.php | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/includes/data-stores/class-wc-product-data-store-cpt.php b/includes/data-stores/class-wc-product-data-store-cpt.php index 58907a4897c..d96aa24f045 100644 --- a/includes/data-stores/class-wc-product-data-store-cpt.php +++ b/includes/data-stores/class-wc-product-data-store-cpt.php @@ -532,6 +532,7 @@ class WC_Product_Data_Store_CPT extends WC_Data_Store_WP implements WC_Object_Da foreach ( $props_to_update as $meta_key => $prop ) { $value = $product->{"get_$prop"}( 'edit' ); + $value = is_string( $value ) ? wp_slash( $value ) : $value; switch ( $prop ) { case 'virtual': case 'downloadable': @@ -566,12 +567,15 @@ class WC_Product_Data_Store_CPT extends WC_Data_Store_WP implements WC_Object_Da // Update extra data associated with the product like button text or product URL for external products. if ( ! $this->extra_data_saved ) { foreach ( $extra_data_keys as $key ) { - if ( ! array_key_exists( $key, $props_to_update ) ) { + if ( ! array_key_exists( '_' . $key, $props_to_update ) ) { continue; } $function = 'get_' . $key; if ( is_callable( array( $product, $function ) ) ) { - if ( update_post_meta( $product->get_id(), '_' . $key, $product->{$function}( 'edit' ) ) ) { + $value = $product->{$function}( 'edit' ); + $value = is_string( $value ) ? wp_slash( $value ) : $value; + + if ( update_post_meta( $product->get_id(), '_' . $key, $value ) ) { $this->updated_props[] = $key; } } From 704ee893cf4a55f22a44801ce096348ef2dd6965 Mon Sep 17 00:00:00 2001 From: Mike Jolley Date: Thu, 12 Apr 2018 17:32:02 +0100 Subject: [PATCH 22/61] Update for new patch in core --- includes/class-wc-privacy.php | 34 ++++++++++++++++++++++------------ 1 file changed, 22 insertions(+), 12 deletions(-) diff --git a/includes/class-wc-privacy.php b/includes/class-wc-privacy.php index dbc505b1aa8..5a286cbb7e4 100644 --- a/includes/class-wc-privacy.php +++ b/includes/class-wc-privacy.php @@ -44,20 +44,25 @@ class WC_Privacy { * @return array An array of personal data in name value pairs */ public static function data_exporter( $email_address, $page ) { - $personal_data = array(); - $done = false; - $page = (int) $page; - $user = get_user_by( 'email', $email_address ); // Check if user has an ID in the DB to load stored personal data. + $done = false; + $page = (int) $page; + $user = get_user_by( 'email', $email_address ); // Check if user has an ID in the DB to load stored personal data. + $data_to_export = array(); // Export customer data first. - if ( 0 === $page ) { + if ( 1 === $page ) { if ( $user instanceof WP_User ) { - $personal_data = self::get_user_personal_data( $user ); + $data_to_export[] = array( + 'group_id' => 'woocommerce_customer', + 'group_label' => __( 'Customer Data', 'woocommerce' ), + 'item_id' => 'user', + 'data' => self::get_user_personal_data( $user ), + ); } } else { // Export orders - 10 at a time. $order_query = array( 'limit' => 10, - 'page' => $page, + 'page' => $page - 1, ); if ( $user instanceof WP_User ) { @@ -70,7 +75,12 @@ class WC_Privacy { if ( 0 < count( $orders ) ) { foreach ( $orders as $order ) { - $personal_data = array_merge( $personal_data, self::get_order_personal_data( $order ) ); + $data_to_export[] = array( + 'group_id' => 'woocommerce_orders', + 'group_label' => __( 'Orders', 'woocommerce' ), + 'item_id' => 'order-' . $order->get_id(), + 'data' => self::get_order_personal_data( $order ), + ); } $done = 10 > count( $orders ); } else { @@ -79,7 +89,7 @@ class WC_Privacy { } return array( - 'data' => $personal_data, + 'data' => $data_to_export, 'done' => $done, ); } @@ -125,8 +135,8 @@ class WC_Privacy { 'billing_postcode' => 'Billing Postal/Zip Code', 'billing_state' => 'Billing State', 'billing_country' => 'Billing Country', - 'billing_phone' => 'Billing Phone', - 'billing_email' => 'Billing Email', + 'billing_phone' => 'Phone Number', + 'billing_email' => 'Email Address', 'shipping_first_name' => 'Shipping First Name', 'shipping_last_name' => 'Shipping Last Name', 'shipping_company' => 'Shipping Company', @@ -308,7 +318,7 @@ class WC_Privacy { $min_length = 3; $max_length = 10; - $mask = "***"; + $mask = '***'; $at_pos = strrpos( $email, '@' ); $name = substr( $email, 0, $at_pos ); $length = strlen( $name ); From 6cb72c2e032e2fa6c3771d318cc51a9bf7c0baaf Mon Sep 17 00:00:00 2001 From: Mike Jolley Date: Fri, 13 Apr 2018 11:49:03 +0100 Subject: [PATCH 23/61] Add extra data to export --- includes/class-wc-privacy.php | 89 ++++++++++++++++++++++------------- 1 file changed, 55 insertions(+), 34 deletions(-) diff --git a/includes/class-wc-privacy.php b/includes/class-wc-privacy.php index 5a286cbb7e4..c1b4716729c 100644 --- a/includes/class-wc-privacy.php +++ b/includes/class-wc-privacy.php @@ -1,7 +1,8 @@ ID; + $order_query['customer_id'] = (int) $user->ID; } else { $order_query['billing_email'] = $email_address; } @@ -126,26 +127,26 @@ class WC_Privacy { $personal_data = array(); $customer = new WC_Customer( $user->ID ); $props_to_export = array( - 'billing_first_name' => 'Billing First Name', - 'billing_last_name' => 'Billing Last Name', - 'billing_company' => 'Billing Company', - 'billing_address_1' => 'Billing Address 1', - 'billing_address_2' => 'Billing Address 2', - 'billing_city' => 'Billing City', - 'billing_postcode' => 'Billing Postal/Zip Code', - 'billing_state' => 'Billing State', - 'billing_country' => 'Billing Country', - 'billing_phone' => 'Phone Number', - 'billing_email' => 'Email Address', - 'shipping_first_name' => 'Shipping First Name', - 'shipping_last_name' => 'Shipping Last Name', - 'shipping_company' => 'Shipping Company', - 'shipping_address_1' => 'Shipping Address 1', - 'shipping_address_2' => 'Shipping Address 2', - 'shipping_city' => 'Shipping City', - 'shipping_postcode' => 'Shipping Postal/Zip Code', - 'shipping_state' => 'Shipping State', - 'shipping_country' => 'Shipping Country', + 'billing_first_name' => __( 'Billing First Name', 'woocommerce' ), + 'billing_last_name' => __( 'Billing Last Name', 'woocommerce' ), + 'billing_company' => __( 'Billing Company', 'woocommerce' ), + 'billing_address_1' => __( 'Billing Address 1', 'woocommerce' ), + 'billing_address_2' => __( 'Billing Address 2', 'woocommerce' ), + 'billing_city' => __( 'Billing City', 'woocommerce' ), + 'billing_postcode' => __( 'Billing Postal/Zip Code', 'woocommerce' ), + 'billing_state' => __( 'Billing State', 'woocommerce' ), + 'billing_country' => __( 'Billing Country', 'woocommerce' ), + 'billing_phone' => __( 'Phone Number', 'woocommerce' ), + 'billing_email' => __( 'Email Address', 'woocommerce' ), + 'shipping_first_name' => __( 'Shipping First Name', 'woocommerce' ), + 'shipping_last_name' => __( 'Shipping Last Name', 'woocommerce' ), + 'shipping_company' => __( 'Shipping Company', 'woocommerce' ), + 'shipping_address_1' => __( 'Shipping Address 1', 'woocommerce' ), + 'shipping_address_2' => __( 'Shipping Address 2', 'woocommerce' ), + 'shipping_city' => __( 'Shipping City', 'woocommerce' ), + 'shipping_postcode' => __( 'Shipping Postal/Zip Code', 'woocommerce' ), + 'shipping_state' => __( 'Shipping State', 'woocommerce' ), + 'shipping_country' => __( 'Shipping Country', 'woocommerce' ), ); foreach ( $props_to_export as $prop => $description ) { @@ -180,18 +181,38 @@ class WC_Privacy { protected static function get_order_personal_data( $order ) { $personal_data = array(); $props_to_export = array( - 'customer_ip_address' => 'IP Address', - 'customer_user_agent' => 'User Agent', - 'formatted_billing_address' => 'Billing Address', - 'formatted_shipping_address' => 'Shipping Address', - 'billing_phone' => 'Billing Phone', - 'billing_email' => 'Billing Email', + 'order_number' => __( 'Order Number', 'woocommerce' ), + 'date_created' => __( 'Order Date', 'woocommerce' ), + 'total' => __( 'Order Total', 'woocommerce' ), + 'items' => __( 'Items Purchased', 'woocommerce' ), + 'customer_ip_address' => __( 'IP Address', 'woocommerce' ), + 'customer_user_agent' => __( 'Browser User Agent', 'woocommerce' ), + 'formatted_billing_address' => __( 'Billing Address', 'woocommerce' ), + 'formatted_shipping_address' => __( 'Shipping Address', 'woocommerce' ), + 'billing_phone' => __( 'Phone Number', 'woocommerce' ), + 'billing_email' => __( 'Email Address', 'woocommerce' ), ); - foreach ( $props_to_export as $prop => $description ) { - /* translators: %1$d: ID of an order, %2$s: Description of an order field */ - $name = sprintf( __( 'Order %1$d: %2$s', 'woocommerce' ), $order->get_id(), $description ); - $value = $order->{"get_$prop"}( 'edit' ); + foreach ( $props_to_export as $prop => $name ) { + switch ( $prop ) { + case 'items': + $item_names = array(); + foreach ( $order->get_items() as $item ) { + $item_names[] = $item->get_name() . ' x ' . $item->get_quantity(); + } + $value = implode( ', ', $item_names ); + break; + case 'date_created': + $value = wc_format_datetime( $order->get_date_created(), get_option( 'date_format' ) . ', ' . get_option( 'time_format' ) ); + break; + case 'formatted_billing_address': + case 'formatted_shipping_address': + $value = preg_replace( '##i', ', ', $order->{"get_$prop"}() ); + break; + default: + $value = $order->{"get_$prop"}(); + break; + } if ( $value ) { $personal_data[] = array( @@ -205,7 +226,7 @@ class WC_Privacy { * Allow extensions to register their own personal data for this order for the export. * * @since 3.4.0 - * @param array $personal_data Array of name value pairs. + * @param array $personal_data Array of name value pairs to expose in the export. * @param WC_Order $order An order object. */ $personal_data = apply_filters( 'woocommerce_privacy_export_personal_data_order', $personal_data, $order ); From 0d70b3b34eeaa29f0d71e0e5ec92d28dc78189d7 Mon Sep 17 00:00:00 2001 From: Ernest Date: Fri, 13 Apr 2018 14:20:46 +0300 Subject: [PATCH 24/61] Recent Product Reviews template --- .../class-wc-widget-recent-reviews.php | 26 ++++---------- templates/content-widget-reviews.php | 36 +++++++++++++++++++ 2 files changed, 43 insertions(+), 19 deletions(-) create mode 100644 templates/content-widget-reviews.php diff --git a/includes/widgets/class-wc-widget-recent-reviews.php b/includes/widgets/class-wc-widget-recent-reviews.php index da6fef7fd4d..c609610db3c 100644 --- a/includes/widgets/class-wc-widget-recent-reviews.php +++ b/includes/widgets/class-wc-widget-recent-reviews.php @@ -70,31 +70,19 @@ class WC_Widget_Recent_Reviews extends WC_Widget { if ( $comments ) { $this->widget_start( $args, $instance ); - echo '
      '; + echo wp_kses_post( apply_filters( 'woocommerce_before_widget_product_review_list', '
        ' ) ); foreach ( (array) $comments as $comment ) { - - $_product = wc_get_product( $comment->comment_post_ID ); - - $rating = intval( get_comment_meta( $comment->comment_ID, 'rating', true ) ); - - $rating_html = wc_get_rating_html( $rating ); - - echo '
      • '; - - echo $_product->get_image() . wp_kses_post( $_product->get_name() ) . ''; // WPCS: XSS ok. - - echo $rating_html; // WPCS: XSS ok. - - /* translators: %s: review author */ - echo '' . sprintf( esc_html__( 'by %s', 'woocommerce' ), get_comment_author() ) . ''; // WPCS: XSS ok. - - echo '
      • '; + wc_get_template( 'content-widget-reviews.php', array( + 'comment' => $comment, + 'product' => wc_get_product( $comment->comment_post_ID ), + ) ); } - echo '
      '; + echo wp_kses_post( apply_filters( 'woocommerce_after_widget_product_review_list', '
    ' ) ); $this->widget_end( $args ); + } $content = ob_get_clean(); diff --git a/templates/content-widget-reviews.php b/templates/content-widget-reviews.php new file mode 100644 index 00000000000..735884ddb5b --- /dev/null +++ b/templates/content-widget-reviews.php @@ -0,0 +1,36 @@ + +
  • + + + + get_image(); ?> + get_name(); ?> + + + comment_ID, 'rating', true ) ) );?> + + comment_ID ) ); ?> + + +
  • From 53a93fd3b1f55f91f34fc947d24e752da522949c Mon Sep 17 00:00:00 2001 From: Mike Jolley Date: Fri, 13 Apr 2018 15:07:38 +0100 Subject: [PATCH 25/61] Clean up user data on delete. --- includes/wc-user-functions.php | 39 ++++++++++++++++++++++++++++++++++ 1 file changed, 39 insertions(+) diff --git a/includes/wc-user-functions.php b/includes/wc-user-functions.php index a82044abd60..43e5bd33b15 100644 --- a/includes/wc-user-functions.php +++ b/includes/wc-user-functions.php @@ -623,3 +623,42 @@ function wc_user_search_columns( $search_columns ) { return $search_columns; } add_filter( 'user_search_columns', 'wc_user_search_columns' ); + +/** + * When a user is deleted in WordPress, delete corresponding WooCommerce data. + * + * @param int $user_id User ID being deleted. + */ +function wc_delete_user_data( $user_id ) { + global $wpdb; + + // Clean up sessions. + $wpdb->delete( + $wpdb->prefix . 'woocommerce_sessions', + array( + 'session_key' => $user_id, + ) + ); + + wp_cache_delete( WC_Cache_Helper::get_cache_prefix( WC_SESSION_CACHE_GROUP ) . $user_id, WC_SESSION_CACHE_GROUP ); + + // Revoke API keys. + $wpdb->delete( + $wpdb->prefix . 'woocommerce_api_keys', + array( + 'user_id' => $user_id, + ) + ); + + // Revoke download permissioons. + $data_store = WC_Data_Store::load( 'customer-download' ); + $data_store->delete_by_user_id( $user_id ); + + // Clean up payment tokens. + $payment_tokens = WC_Payment_Tokens::get_customer_tokens( $user_id ); + + foreach ( $payment_tokens as $payment_token ) { + $payment_token->delete(); + } +} +add_action( 'delete_user', 'wc_delete_user_data' ); From 3f2d8e8eefa6616dba7c9c0c37f871c7793a1af5 Mon Sep 17 00:00:00 2001 From: Mike Jolley Date: Fri, 13 Apr 2018 15:07:58 +0100 Subject: [PATCH 26/61] delete_by_user_id method for customer downloads --- .../class-wc-customer-download-data-store.php | 17 +++++++++++++++++ 1 file changed, 17 insertions(+) diff --git a/includes/data-stores/class-wc-customer-download-data-store.php b/includes/data-stores/class-wc-customer-download-data-store.php index 951e50bd61a..f2a6e4851ff 100644 --- a/includes/data-stores/class-wc-customer-download-data-store.php +++ b/includes/data-stores/class-wc-customer-download-data-store.php @@ -225,6 +225,23 @@ class WC_Customer_Download_Data_Store implements WC_Customer_Download_Data_Store ); } + /** + * Method to delete a download permission from the database by user ID. + * + * @since 3.4.0 + * @param int $id user ID of the downloads that will be deleted. + */ + public function delete_by_user_id( $id ) { + global $wpdb; + $wpdb->query( + $wpdb->prepare( + "DELETE FROM {$wpdb->prefix}woocommerce_downloadable_product_permissions + WHERE user_id = %d", + $id + ) + ); + } + /** * Get a download object. * From 965712a1d7cbdf27f566903ad63d883427443ab6 Mon Sep 17 00:00:00 2001 From: Mike Jolley Date: Fri, 13 Apr 2018 15:35:03 +0100 Subject: [PATCH 27/61] Data removal for accounts/guests --- includes/class-wc-privacy.php | 405 ++++++++++++------ .../class-wc-customer-download-data-store.php | 17 + 2 files changed, 286 insertions(+), 136 deletions(-) diff --git a/includes/class-wc-privacy.php b/includes/class-wc-privacy.php index c1b4716729c..18620b64e83 100644 --- a/includes/class-wc-privacy.php +++ b/includes/class-wc-privacy.php @@ -17,76 +17,105 @@ class WC_Privacy { * Init - hook into events. */ public static function init() { - add_filter( 'wp_privacy_personal_data_exporters', array( __CLASS__, 'register_data_exporter' ), 10 ); + // We need to ensure we're using a version of WP with GDPR support. + if ( ! function_exists( 'wp_privacy_anonymize_data' ) ) { + return; + } + add_filter( 'wp_privacy_personal_data_exporters', array( __CLASS__, 'register_data_exporters' ), 10 ); add_action( 'woocommerce_remove_order_personal_data', array( __CLASS__, 'remove_order_personal_data' ) ); + add_filter( 'wp_privacy_anonymize_data', array( __CLASS__, 'privacy_anonymize_data_custom_types' ), 10, 3 ); } /** * Registers the personal data exporter for comments. * + * @since 3.4.0 * @param array $exporters An array of personal data exporters. * @return array An array of personal data exporters. */ - public static function register_data_exporter( $exporters ) { + public static function register_data_exporters( $exporters ) { $exporters[] = array( - 'exporter_friendly_name' => __( 'WooCommerce Data', 'woocommerce' ), - 'callback' => array( __CLASS__, 'data_exporter' ), + 'exporter_friendly_name' => __( 'WooCommerce Customer Data', 'woocommerce' ), + 'callback' => array( __CLASS__, 'customer_data_exporter' ), + ); + $exporters[] = array( + 'exporter_friendly_name' => __( 'WooCommerce Order Data', 'woocommerce' ), + 'callback' => array( __CLASS__, 'order_data_exporter' ), + ); + $exporters[] = array( + 'exporter_friendly_name' => __( 'WooCommerce Download Logs', 'woocommerce' ), + 'callback' => array( __CLASS__, 'download_log_data_exporter' ), ); return $exporters; } + /** + * Finds and exports customer data by email address. + * + * @since 3.4.0 + * @param string $email_address The user email address. + * @param int $page Page. + * @return array An array of personal data in name value pairs + */ + public static function customer_data_exporter( $email_address, $page ) { + $user = get_user_by( 'email', $email_address ); // Check if user has an ID in the DB to load stored personal data. + $data_to_export = array(); + + if ( $user instanceof WP_User ) { + $data_to_export[] = array( + 'group_id' => 'woocommerce_customer', + 'group_label' => __( 'Customer Data', 'woocommerce' ), + 'item_id' => 'user', + 'data' => self::get_user_personal_data( $user ), + ); + } + + return array( + 'data' => $data_to_export, + 'done' => true, + ); + } + /** * Finds and exports data which could be used to identify a person from WooCommerce data assocated with an email address. * * Orders are exported in blocks of 10 to avoid timeouts. * + * @since 3.4.0 * @param string $email_address The user email address. - * @param int $page Page, zero based. + * @param int $page Page. * @return array An array of personal data in name value pairs */ - public static function data_exporter( $email_address, $page ) { + public static function order_data_exporter( $email_address, $page ) { $done = false; $page = (int) $page; $user = get_user_by( 'email', $email_address ); // Check if user has an ID in the DB to load stored personal data. $data_to_export = array(); + $order_query = array( + 'limit' => 10, + 'page' => $page, + ); - // Export customer data first. - if ( 1 === $page ) { - if ( $user instanceof WP_User ) { + if ( $user instanceof WP_User ) { + $order_query['customer_id'] = (int) $user->ID; + } else { + $order_query['billing_email'] = $email_address; + } + + $orders = wc_get_orders( $order_query ); + + if ( 0 < count( $orders ) ) { + foreach ( $orders as $order ) { $data_to_export[] = array( - 'group_id' => 'woocommerce_customer', - 'group_label' => __( 'Customer Data', 'woocommerce' ), - 'item_id' => 'user', - 'data' => self::get_user_personal_data( $user ), + 'group_id' => 'woocommerce_orders', + 'group_label' => __( 'Orders', 'woocommerce' ), + 'item_id' => 'order-' . $order->get_id(), + 'data' => self::get_order_personal_data( $order ), ); } - } else { // Export orders - 10 at a time. - $order_query = array( - 'limit' => 10, - 'page' => $page - 1, - ); - - if ( $user instanceof WP_User ) { - $order_query['customer_id'] = (int) $user->ID; - } else { - $order_query['billing_email'] = $email_address; - } - - $orders = wc_get_orders( $order_query ); - - if ( 0 < count( $orders ) ) { - foreach ( $orders as $order ) { - $data_to_export[] = array( - 'group_id' => 'woocommerce_orders', - 'group_label' => __( 'Orders', 'woocommerce' ), - 'item_id' => 'order-' . $order->get_id(), - 'data' => self::get_order_personal_data( $order ), - ); - } - $done = 10 > count( $orders ); - } else { - $done = true; - } + $done = 10 > count( $orders ); + } else { + $done = true; } return array( @@ -96,30 +125,25 @@ class WC_Privacy { } /** - * Anonymize/remove personal data for a given email address. + * Finds and exports customer download logs by email address. * - * @param string $email Email address. + * @since 3.4.0 + * @param string $email_address The user email address. + * @param int $page Page. + * @return array An array of personal data in name value pairs */ - public static function remove_personal_data( $email ) { - /** - * Personal Data: - * - * - Everything exported above for orders and customers - * - _billing_address_index - just an index for searching which needs clearing? - * - _shipping_address_index - just an index for searching which needs clearing? - * - * Misc: - * - * - Downloadable Product User Email (does not export becasue it matches order/user data). - * - Download logs by user ID and IP address. - * - File based logs containing email? Do search and clear if found. - * - Payment tokens? Check if these need exporting/clearing. Based on User ID. - */ + public static function download_log_data_exporter( $email_address, $page ) { + // @todo + return array( + 'data' => array(), + 'done' => true, + ); } /** * Get personal data (key/value pairs) for a user object. * + * @since 3.4.0 * @param WP_User $user user object. * @return array */ @@ -175,6 +199,7 @@ class WC_Privacy { /** * Get personal data (key/value pairs) for an order object. * + * @since 3.4.0 * @param WC_Order $order Order object. * @return array */ @@ -235,47 +260,128 @@ class WC_Privacy { } /** - * Remove personal data specific to WooCommerce from a user object. + * Anonymize/remove personal data for a given EMAIL ADDRESS. This user may not have an account. * - * @param WP_User $user user object. + * Note; this is separate to account deletion. WooCommerce handles account deletion/cleanup elsewhere. + * This logic is simply to clean up data for guest users. + * + * @param string $email_address Customer email address. */ - protected static function remove_user_personal_data( $user ) { - $customer = new WC_Customer( $user->ID ); - $props_to_remove = array( - 'billing_first_name' => '__return_empty_string', - 'billing_last_name' => '__return_empty_string', - 'billing_company' => '__return_empty_string', - 'billing_address_1' => '__return_empty_string', - 'billing_address_2' => '__return_empty_string', - 'billing_city' => '__return_empty_string', - 'billing_postcode' => '__return_empty_string', - 'billing_state' => '__return_empty_string', - 'billing_country' => '__return_empty_string', - 'billing_phone' => '__return_empty_string', - 'billing_email' => '__return_empty_string', - 'shipping_first_name' => '__return_empty_string', - 'shipping_last_name' => '__return_empty_string', - 'shipping_company' => '__return_empty_string', - 'shipping_address_1' => '__return_empty_string', - 'shipping_address_2' => '__return_empty_string', - 'shipping_city' => '__return_empty_string', - 'shipping_postcode' => '__return_empty_string', - 'shipping_state' => '__return_empty_string', - 'shipping_country' => '__return_empty_string', + public static function remove_personal_data( $email_address ) { + $user = get_user_by( 'email', $email_address ); // Check if user has an ID in the DB. + $has_account = $user instanceof WP_User; + + // Remove personal data from the user's orders. @todo add option for this. + $order_query = array( + 'limit' => -1, ); - foreach ( $props_to_remove as $prop => $callback ) { - $customer->{"set_$prop"}( call_user_func( $callback, $customer->{"get_$prop"} ) ); + + if ( $has_account ) { + $order_query['customer_id'] = (int) $user->ID; + } else { + $order_query['billing_email'] = $email_address; + } + + $orders = wc_get_orders( $order_query ); + + if ( 0 < count( $orders ) ) { + foreach ( $orders as $order ) { + self::remove_order_personal_data( $order ); + } + } + + // Revoke things such as download permissions for this email if it's a guest account. This is handled elsewhere for user accounts on delete. + if ( ! $has_account ) { + $data_store = WC_Data_Store::load( 'customer-download' ); + $data_store->delete_by_user_email( $email_address ); + } else { + self::remove_customer_personal_data( $user ); } /** * Allow extensions to remove their own personal data for this customer. * * @since 3.4.0 - * @param WC_Order $order A customer object. + * @param string $email_address Customer email address. */ - do_action( 'woocommerce_privacy_remove_personal_data_customer', $customer ); + do_action( 'woocommerce_privacy_remove_personal_data', $email_address ); + } + /** + * Remove personal data specific to WooCommerce from a user object. + * + * @param WP_User $user user object. + */ + protected static function remove_customer_personal_data( $user ) { + $customer = new WC_Customer( $user->ID ); + $anonymized_data = array(); + + /** + * Expose props and data types we'll be anonymizing. + * + * @since 3.4.0 + * @param array $props Keys are the prop names, values are the data type we'll be passing to wp_privacy_anonymize_data(). + * @param WC_Customer $customer A customer object. + */ + $props_to_remove = apply_filters( 'woocommerce_privacy_remove_customer_personal_data_props', array( + 'billing_first_name' => 'address', + 'billing_last_name' => 'address', + 'billing_company' => 'address', + 'billing_address_1' => 'address', + 'billing_address_2' => 'address', + 'billing_city' => 'address', + 'billing_postcode' => 'address', + 'billing_state' => 'address', + 'billing_country' => 'address', + 'billing_phone' => 'phone', + 'billing_email' => 'email', + 'shipping_first_name' => 'address', + 'shipping_last_name' => 'address', + 'shipping_company' => 'address', + 'shipping_address_1' => 'address', + 'shipping_address_2' => 'address', + 'shipping_city' => 'address', + 'shipping_postcode' => 'address', + 'shipping_state' => 'address', + 'shipping_country' => 'address', + ), $customer ); + + if ( ! empty( $props_to_remove ) && is_array( $props_to_remove ) ) { + foreach ( $props_to_remove as $prop => $data_type ) { + // Get the current value in edit context. + $value = $customer->{"get_$prop"}( 'edit' ); + + // If the value is empty, it does not need to be anonymized. + if ( empty( $value ) ) { + continue; + } + + /** + * Expose a way to control the anonymized value of a prop via 3rd party code. + * + * @since 3.4.0 + * @param bool $anonymized_data Value of this prop after anonymization. + * @param string $prop Name of the prop being removed. + * @param string $value Current value of the data. + * @param string $data_type Type of data. + * @param WC_Customer $customer A customer object. + */ + $anonymized_data[ $prop ] = apply_filters( 'woocommerce_privacy_remove_personal_data_customer_prop_value', wp_privacy_anonymize_data( $data_type, $value ), $prop, $value, $data_type, $customer ); + } + } + + // Set all new props and persist the new data to the database. + $customer->set_props( $anonymized_data ); $customer->save(); + + /** + * Allow extensions to remove their own personal data for this customer. + * + * @since 3.4.0 + * @param WC_Customer $customer A customer object. + * @param WP_User $user User object. + */ + do_action( 'woocommerce_privacy_remove_customer_personal_data', $customer, $user ); } /** @@ -286,72 +392,99 @@ class WC_Privacy { * @param WC_Order $order Order object. */ public static function remove_order_personal_data( $order ) { - $props_to_remove = array( - 'customer_ip_address' => '__return_empty_string', - 'customer_user_agent' => '__return_empty_string', - 'billing_first_name' => '__return_empty_string', - 'billing_last_name' => '__return_empty_string', - 'billing_company' => '__return_empty_string', - 'billing_address_1' => '__return_empty_string', - 'billing_address_2' => '__return_empty_string', - 'billing_city' => '__return_empty_string', - 'billing_postcode' => '__return_empty_string', - 'billing_state' => '__return_empty_string', - 'billing_country' => '__return_empty_string', - 'billing_phone' => '__return_empty_string', - 'billing_email' => array( __CLASS__, 'mask_email' ), - 'shipping_first_name' => '__return_empty_string', - 'shipping_last_name' => '__return_empty_string', - 'shipping_company' => '__return_empty_string', - 'shipping_address_1' => '__return_empty_string', - 'shipping_address_2' => '__return_empty_string', - 'shipping_city' => '__return_empty_string', - 'shipping_postcode' => '__return_empty_string', - 'shipping_state' => '__return_empty_string', - 'shipping_country' => '__return_empty_string', - ); - foreach ( $props_to_remove as $prop => $callback ) { - $order->{"set_$prop"}( call_user_func( $callback, $order->{"get_$prop"}( 'edit' ) ) ); + $anonymized_data = array(); + + /** + * Expose props and data types we'll be anonymizing. + * + * @since 3.4.0 + * @param array $props Keys are the prop names, values are the data type we'll be passing to wp_privacy_anonymize_data(). + * @param WC_Order $order A customer object. + */ + $props_to_remove = apply_filters( 'woocommerce_privacy_remove_order_personal_data_props', array( + 'customer_ip_address' => 'ip', + 'customer_user_agent' => 'text', + 'billing_first_name' => 'text', + 'billing_last_name' => 'text', + 'billing_company' => 'text', + 'billing_address_1' => 'text', + 'billing_address_2' => 'text', + 'billing_city' => 'text', + 'billing_postcode' => 'text', + 'billing_state' => 'address_state', + 'billing_country' => 'address_country', + 'billing_phone' => 'phone', + 'billing_email' => 'email', + 'shipping_first_name' => 'text', + 'shipping_last_name' => 'text', + 'shipping_company' => 'text', + 'shipping_address_1' => 'text', + 'shipping_address_2' => 'text', + 'shipping_city' => 'text', + 'shipping_postcode' => 'text', + 'shipping_state' => 'address_state', + 'shipping_country' => 'address_country', + ), $order ); + + if ( ! empty( $props_to_remove ) && is_array( $props_to_remove ) ) { + foreach ( $props_to_remove as $prop => $data_type ) { + // Get the current value in edit context. + $value = $order->{"get_$prop"}( 'edit' ); + + // If the value is empty, it does not need to be anonymized. + if ( empty( $value ) || empty( $data_type ) ) { + continue; + } + + /** + * Expose a way to control the anonymized value of a prop via 3rd party code. + * + * @since 3.4.0 + * @param bool $anonymized_data Value of this prop after anonymization. + * @param string $prop Name of the prop being removed. + * @param string $value Current value of the data. + * @param string $data_type Type of data. + * @param WC_Order $order An order object. + */ + $anonymized_data[ $prop ] = apply_filters( 'woocommerce_privacy_remove_order_personal_data_prop_value', wp_privacy_anonymize_data( $data_type, $value ), $prop, $value, $data_type, $order ); + } } + // Set all new props and persist the new data to the database. + $order->set_props( $anonymized_data ); + $order->save(); + /** * Allow extensions to remove their own personal data for this order. * * @since 3.4.0 * @param WC_Order $order A customer object. */ - do_action( 'woocommerce_privacy_remove_personal_data_order', $order ); + do_action( 'woocommerce_privacy_remove_order_personal_data', $order ); - $order->save(); + // Add note that this event occured. $order->add_order_note( __( 'Personal data removed.', 'woocommerce' ) ); } /** - * Mask an email address. + * Handle some custom types of data and anonymize them. * - * @param string $email Email to mask. - * @return string + * @param string $anonymous Anonymized string. + * @param string $type Type of data. + * @param string $data The data being anonymized. + * @return string Anonymized string. */ - protected static function mask_email( $email ) { - if ( ! $email ) { - return ''; + public static function privacy_anonymize_data_custom_types( $anonymous, $type, $data ) { + switch ( $type ) { + case 'address_state': + case 'address_country': + $anonymous = ''; // Empty string - we don't want to store anything after removal. + break; + case 'phone': + $anonymous = preg_replace( '/\d/u', '0', $data ); + break; } - - $min_length = 3; - $max_length = 10; - $mask = '***'; - $at_pos = strrpos( $email, '@' ); - $name = substr( $email, 0, $at_pos ); - $length = strlen( $name ); - $domain = substr( $email, $at_pos ); - - if ( ( $length / 2 ) < $max_length ) { - $max_length = $length / 2; - } - - $masked_email = $length > $min_length ? substr( $name, 0, $max_length ) : ''; - - return "{$masked_email}{$mask}{$domain}"; + return $anonymous; } } diff --git a/includes/data-stores/class-wc-customer-download-data-store.php b/includes/data-stores/class-wc-customer-download-data-store.php index f2a6e4851ff..6aae9080a09 100644 --- a/includes/data-stores/class-wc-customer-download-data-store.php +++ b/includes/data-stores/class-wc-customer-download-data-store.php @@ -242,6 +242,23 @@ class WC_Customer_Download_Data_Store implements WC_Customer_Download_Data_Store ); } + /** + * Method to delete a download permission from the database by user email. + * + * @since 3.4.0 + * @param string $email email of the downloads that will be deleted. + */ + public function delete_by_user_email( $email ) { + global $wpdb; + $wpdb->query( + $wpdb->prepare( + "DELETE FROM {$wpdb->prefix}woocommerce_downloadable_product_permissions + WHERE user_email = %s", + $email + ) + ); + } + /** * Get a download object. * From eb6d230d38b1091378d07e0859577870f2af73fb Mon Sep 17 00:00:00 2001 From: Mike Jolley Date: Fri, 13 Apr 2018 17:00:26 +0100 Subject: [PATCH 28/61] Export downloads and logs --- includes/class-wc-privacy.php | 157 ++++++++++++++---- .../class-wc-customer-download-data-store.php | 8 +- ...ss-wc-customer-download-log-data-store.php | 11 +- 3 files changed, 137 insertions(+), 39 deletions(-) diff --git a/includes/class-wc-privacy.php b/includes/class-wc-privacy.php index 18620b64e83..095cc29e024 100644 --- a/includes/class-wc-privacy.php +++ b/includes/class-wc-privacy.php @@ -43,8 +43,8 @@ class WC_Privacy { 'callback' => array( __CLASS__, 'order_data_exporter' ), ); $exporters[] = array( - 'exporter_friendly_name' => __( 'WooCommerce Download Logs', 'woocommerce' ), - 'callback' => array( __CLASS__, 'download_log_data_exporter' ), + 'exporter_friendly_name' => __( 'WooCommerce Downloads', 'woocommerce' ), + 'callback' => array( __CLASS__, 'download_data_exporter' ), ); return $exporters; } @@ -132,11 +132,100 @@ class WC_Privacy { * @param int $page Page. * @return array An array of personal data in name value pairs */ - public static function download_log_data_exporter( $email_address, $page ) { - // @todo + public static function download_data_exporter( $email_address, $page ) { + $done = false; + $page = (int) $page; + $user = get_user_by( 'email', $email_address ); // Check if user has an ID in the DB to load stored personal data. + $data_to_export = array(); + $downloads_query = array( + 'limit' => 10, + 'page' => $page, + ); + + if ( $user instanceof WP_User ) { + $downloads_query['user_id'] = (int) $user->ID; + } else { + $downloads_query['user_email'] = $email_address; + } + + $customer_download_data_store = WC_Data_Store::load( 'customer-download' ); + $customer_download_log_data_store = WC_Data_Store::load( 'customer-download-log' ); + $downloads = $customer_download_data_store->get_downloads( $downloads_query ); + + if ( 0 < count( $downloads ) ) { + foreach ( $downloads as $download ) { + $data_to_export[] = array( + 'group_id' => 'woocommerce_downloads', + 'group_label' => __( 'Order Downloads', 'woocommerce' ), + 'item_id' => 'download-' . $download->get_id(), + 'data' => array( + array( + 'name' => __( 'Download ID', 'woocommerce' ), + 'value' => $download->get_id(), + ), + array( + 'name' => __( 'Order ID', 'woocommerce' ), + 'value' => $download->get_order_id(), + ), + array( + 'name' => __( 'Product', 'woocommerce' ), + 'value' => get_the_title( $download->get_product_id() ), + ), + array( + 'name' => __( 'User email', 'woocommerce' ), + 'value' => $download->get_user_email(), + ), + array( + 'name' => __( 'Downloads remaining', 'woocommerce' ), + 'value' => $download->get_downloads_remaining(), + ), + array( + 'name' => __( 'Download count', 'woocommerce' ), + 'value' => $download->get_download_count(), + ), + array( + 'name' => __( 'Access granted', 'woocommerce' ), + 'value' => date( 'Y-m-d', $download->get_access_granted( 'edit' )->getTimestamp() ), + ), + array( + 'name' => __( 'Access expires', 'woocommerce' ), + 'value' => ! is_null( $download->get_access_expires( 'edit' ) ) ? date( 'Y-m-d', $download->get_access_expires( 'edit' )->getTimestamp() ) : null, + ), + ), + ); + + $download_logs = $customer_download_log_data_store->get_download_logs_for_permission( $download->get_id() ); + + foreach ( $download_logs as $download_log ) { + $data_to_export[] = array( + 'group_id' => 'woocommerce_download_logs', + 'group_label' => __( 'Download Logs', 'woocommerce' ), + 'item_id' => 'download-log-' . $download_log->get_id(), + 'data' => array( + array( + 'name' => __( 'Download ID', 'woocommerce' ), + 'value' => $download_log->get_permission_id(), + ), + array( + 'name' => __( 'Timestamp', 'woocommerce' ), + 'value' => $download_log->get_timestamp(), + ), + array( + 'name' => __( 'IP Address', 'woocommerce' ), + 'value' => $download_log->get_user_ip_address(), + ), + ), + ); + } + } + $done = 10 > count( $downloads ); + } else { + $done = true; + } + return array( - 'data' => array(), - 'done' => true, + 'data' => $data_to_export, + 'done' => $done, ); } @@ -265,13 +354,15 @@ class WC_Privacy { * Note; this is separate to account deletion. WooCommerce handles account deletion/cleanup elsewhere. * This logic is simply to clean up data for guest users. * + * @todo Add option to determine if order data should be left alone when removing personal data for a user. + * * @param string $email_address Customer email address. */ public static function remove_personal_data( $email_address ) { $user = get_user_by( 'email', $email_address ); // Check if user has an ID in the DB. $has_account = $user instanceof WP_User; - // Remove personal data from the user's orders. @todo add option for this. + // Remove personal data from the user's orders. $order_query = array( 'limit' => -1, ); @@ -290,11 +381,12 @@ class WC_Privacy { } } - // Revoke things such as download permissions for this email if it's a guest account. This is handled elsewhere for user accounts on delete. if ( ! $has_account ) { + // Revoke things such as download permissions for this email if it's a guest account. This is handled elsewhere for user accounts on delete. $data_store = WC_Data_Store::load( 'customer-download' ); $data_store->delete_by_user_email( $email_address ); } else { + // Remove address data from the user object. This is in case the user is not deleted for whatever reason. self::remove_customer_personal_data( $user ); } @@ -317,37 +409,37 @@ class WC_Privacy { $anonymized_data = array(); /** - * Expose props and data types we'll be anonymizing. + * Expose props and data types we'll be removing. * * @since 3.4.0 - * @param array $props Keys are the prop names, values are the data type we'll be passing to wp_privacy_anonymize_data(). + * @param array $props A list of props we're removing from the user object. * @param WC_Customer $customer A customer object. */ $props_to_remove = apply_filters( 'woocommerce_privacy_remove_customer_personal_data_props', array( - 'billing_first_name' => 'address', - 'billing_last_name' => 'address', - 'billing_company' => 'address', - 'billing_address_1' => 'address', - 'billing_address_2' => 'address', - 'billing_city' => 'address', - 'billing_postcode' => 'address', - 'billing_state' => 'address', - 'billing_country' => 'address', - 'billing_phone' => 'phone', - 'billing_email' => 'email', - 'shipping_first_name' => 'address', - 'shipping_last_name' => 'address', - 'shipping_company' => 'address', - 'shipping_address_1' => 'address', - 'shipping_address_2' => 'address', - 'shipping_city' => 'address', - 'shipping_postcode' => 'address', - 'shipping_state' => 'address', - 'shipping_country' => 'address', + 'billing_first_name', + 'billing_last_name', + 'billing_company', + 'billing_address_1', + 'billing_address_2', + 'billing_city', + 'billing_postcode', + 'billing_state', + 'billing_country', + 'billing_phone', + 'billing_email', + 'shipping_first_name', + 'shipping_last_name', + 'shipping_company', + 'shipping_address_1', + 'shipping_address_2', + 'shipping_city', + 'shipping_postcode', + 'shipping_state', + 'shipping_country', ), $customer ); if ( ! empty( $props_to_remove ) && is_array( $props_to_remove ) ) { - foreach ( $props_to_remove as $prop => $data_type ) { + foreach ( $props_to_remove as $prop ) { // Get the current value in edit context. $value = $customer->{"get_$prop"}( 'edit' ); @@ -363,10 +455,9 @@ class WC_Privacy { * @param bool $anonymized_data Value of this prop after anonymization. * @param string $prop Name of the prop being removed. * @param string $value Current value of the data. - * @param string $data_type Type of data. * @param WC_Customer $customer A customer object. */ - $anonymized_data[ $prop ] = apply_filters( 'woocommerce_privacy_remove_personal_data_customer_prop_value', wp_privacy_anonymize_data( $data_type, $value ), $prop, $value, $data_type, $customer ); + $anonymized_data[ $prop ] = apply_filters( 'woocommerce_privacy_remove_personal_data_customer_prop_value', '', $prop, $value, $customer ); } } diff --git a/includes/data-stores/class-wc-customer-download-data-store.php b/includes/data-stores/class-wc-customer-download-data-store.php index 6aae9080a09..30fd321a7ad 100644 --- a/includes/data-stores/class-wc-customer-download-data-store.php +++ b/includes/data-stores/class-wc-customer-download-data-store.php @@ -281,6 +281,7 @@ class WC_Customer_Download_Data_Store implements WC_Customer_Download_Data_Store $args = wp_parse_args( $args, array( 'user_email' => '', + 'user_id' => '', 'order_id' => '', 'order_key' => '', 'product_id' => '', @@ -288,6 +289,7 @@ class WC_Customer_Download_Data_Store implements WC_Customer_Download_Data_Store 'orderby' => 'permission_id', 'order' => 'ASC', 'limit' => -1, + 'page' => 1, 'return' => 'objects', ) ); @@ -312,6 +314,10 @@ class WC_Customer_Download_Data_Store implements WC_Customer_Download_Data_Store $query[] = $wpdb->prepare( 'AND user_email = %s', sanitize_email( $args['user_email'] ) ); } + if ( $args['user_id'] ) { + $query[] = $wpdb->prepare( 'AND user_id = %d', absint( $args['user_id'] ) ); + } + if ( $args['order_id'] ) { $query[] = $wpdb->prepare( 'AND order_id = %d', $args['order_id'] ); } @@ -334,7 +340,7 @@ class WC_Customer_Download_Data_Store implements WC_Customer_Download_Data_Store $query[] = "ORDER BY {$orderby_sql}"; if ( 0 < $args['limit'] ) { - $query[] = $wpdb->prepare( 'LIMIT %d', $args['limit'] ); + $query[] = $wpdb->prepare( 'LIMIT %d, %d', absint( $args['limit'] ) * absint( $args['page'] - 1 ), absint( $args['limit'] ) ); } // phpcs:ignore WordPress.WP.PreparedSQL.NotPrepared diff --git a/includes/data-stores/class-wc-customer-download-log-data-store.php b/includes/data-stores/class-wc-customer-download-log-data-store.php index 69dc756263a..47e427ad2e8 100644 --- a/includes/data-stores/class-wc-customer-download-log-data-store.php +++ b/includes/data-stores/class-wc-customer-download-log-data-store.php @@ -160,10 +160,11 @@ class WC_Customer_Download_Log_Data_Store implements WC_Customer_Download_Log_Da 'permission_id' => '', 'user_id' => '', 'user_ip_address' => '', - 'orderby' => 'download_log_id', - 'order' => 'DESC', - 'limit' => -1, - 'return' => 'objects', + 'orderby' => 'download_log_id', + 'order' => 'DESC', + 'limit' => -1, + 'page' => 1, + 'return' => 'objects', ) ); $query = array(); @@ -188,7 +189,7 @@ class WC_Customer_Download_Log_Data_Store implements WC_Customer_Download_Log_Da $query[] = "ORDER BY {$orderby_sql}"; if ( 0 < $args['limit'] ) { - $query[] = $wpdb->prepare( "LIMIT %d", $args['limit'] ); + $query[] = $wpdb->prepare( 'LIMIT %d, %d', absint( $args['limit'] ) * absint( $args['page'] - 1 ), absint( $args['limit'] ) ); } $raw_download_logs = $wpdb->get_results( implode( ' ', $query ) ); From 93d20d9c9326c9733161b8bcb3c3dfe989e95755 Mon Sep 17 00:00:00 2001 From: Mike Jolley Date: Fri, 13 Apr 2018 18:03:02 +0100 Subject: [PATCH 29/61] Data removal handling --- includes/class-wc-install.php | 3 + includes/class-wc-privacy.php | 131 +++++------------- ...ss-wc-customer-download-log-data-store.php | 92 ++++++------ includes/wc-user-functions.php | 6 - 4 files changed, 88 insertions(+), 144 deletions(-) diff --git a/includes/class-wc-install.php b/includes/class-wc-install.php index 1b228f90b6e..84a589bf501 100644 --- a/includes/class-wc-install.php +++ b/includes/class-wc-install.php @@ -525,6 +525,9 @@ class WC_Install { // used by WC_Comments::wp_count_comments() to get the number of comments by type. $wpdb->query( "ALTER TABLE {$wpdb->comments} ADD INDEX woo_idx_comment_type (comment_type)" ); } + + // Add constraint to download logs. + $wpdb->query( "ALTER TABLE {$wpdb->prefix}wc_download_log ADD FOREIGN KEY (permission_id) REFERENCES {$wpdb->prefix}woocommerce_downloadable_product_permissions(permission_id) ON DELETE CASCADE" ); } /** diff --git a/includes/class-wc-privacy.php b/includes/class-wc-privacy.php index 095cc29e024..765d23891d4 100644 --- a/includes/class-wc-privacy.php +++ b/includes/class-wc-privacy.php @@ -21,9 +21,15 @@ class WC_Privacy { if ( ! function_exists( 'wp_privacy_anonymize_data' ) ) { return; } + + // This hook registers WooCommerce data exporters. add_filter( 'wp_privacy_personal_data_exporters', array( __CLASS__, 'register_data_exporters' ), 10 ); + + // When this is fired, data is removed in a given order. Called from bulk actions. add_action( 'woocommerce_remove_order_personal_data', array( __CLASS__, 'remove_order_personal_data' ) ); - add_filter( 'wp_privacy_anonymize_data', array( __CLASS__, 'privacy_anonymize_data_custom_types' ), 10, 3 ); + + // Handles custom anonomization types not included in core. + add_filter( 'wp_privacy_anonymize_data', array( __CLASS__, 'anonymize_custom_data_types' ), 10, 3 ); } /** @@ -355,6 +361,7 @@ class WC_Privacy { * This logic is simply to clean up data for guest users. * * @todo Add option to determine if order data should be left alone when removing personal data for a user. + * @todo Hook into core UI. * * @param string $email_address Customer email address. */ @@ -362,32 +369,38 @@ class WC_Privacy { $user = get_user_by( 'email', $email_address ); // Check if user has an ID in the DB. $has_account = $user instanceof WP_User; - // Remove personal data from the user's orders. - $order_query = array( - 'limit' => -1, - ); + /** + * Allow 3rd parties to modify this behavior. If true, orders belonging to this user will be anonyimized. + * + * @since 3.4.0 + */ + if ( apply_filters( 'woocommerce_privacy_remove_personal_data_includes_orders', true, $email_address ) ) { + $order_query = array( + 'limit' => -1, + ); - if ( $has_account ) { - $order_query['customer_id'] = (int) $user->ID; - } else { - $order_query['billing_email'] = $email_address; - } + if ( $user instanceof WP_User ) { + $order_query['customer_id'] = (int) $user->ID; + } else { + $order_query['billing_email'] = $email_address; + } - $orders = wc_get_orders( $order_query ); + $orders = wc_get_orders( $order_query ); - if ( 0 < count( $orders ) ) { - foreach ( $orders as $order ) { - self::remove_order_personal_data( $order ); + if ( 0 < count( $orders ) ) { + foreach ( $orders as $order ) { + self::remove_order_personal_data( $order ); + } } } - if ( ! $has_account ) { - // Revoke things such as download permissions for this email if it's a guest account. This is handled elsewhere for user accounts on delete. - $data_store = WC_Data_Store::load( 'customer-download' ); - $data_store->delete_by_user_email( $email_address ); + // Revoke download permissions. + $data_store = WC_Data_Store::load( 'customer-download' ); + + if ( $user instanceof WP_User ) { + $data_store->delete_by_user_id( (int) $user->ID ); } else { - // Remove address data from the user object. This is in case the user is not deleted for whatever reason. - self::remove_customer_personal_data( $user ); + $data_store->delete_by_user_email( $email_address ); } /** @@ -399,82 +412,6 @@ class WC_Privacy { do_action( 'woocommerce_privacy_remove_personal_data', $email_address ); } - /** - * Remove personal data specific to WooCommerce from a user object. - * - * @param WP_User $user user object. - */ - protected static function remove_customer_personal_data( $user ) { - $customer = new WC_Customer( $user->ID ); - $anonymized_data = array(); - - /** - * Expose props and data types we'll be removing. - * - * @since 3.4.0 - * @param array $props A list of props we're removing from the user object. - * @param WC_Customer $customer A customer object. - */ - $props_to_remove = apply_filters( 'woocommerce_privacy_remove_customer_personal_data_props', array( - 'billing_first_name', - 'billing_last_name', - 'billing_company', - 'billing_address_1', - 'billing_address_2', - 'billing_city', - 'billing_postcode', - 'billing_state', - 'billing_country', - 'billing_phone', - 'billing_email', - 'shipping_first_name', - 'shipping_last_name', - 'shipping_company', - 'shipping_address_1', - 'shipping_address_2', - 'shipping_city', - 'shipping_postcode', - 'shipping_state', - 'shipping_country', - ), $customer ); - - if ( ! empty( $props_to_remove ) && is_array( $props_to_remove ) ) { - foreach ( $props_to_remove as $prop ) { - // Get the current value in edit context. - $value = $customer->{"get_$prop"}( 'edit' ); - - // If the value is empty, it does not need to be anonymized. - if ( empty( $value ) ) { - continue; - } - - /** - * Expose a way to control the anonymized value of a prop via 3rd party code. - * - * @since 3.4.0 - * @param bool $anonymized_data Value of this prop after anonymization. - * @param string $prop Name of the prop being removed. - * @param string $value Current value of the data. - * @param WC_Customer $customer A customer object. - */ - $anonymized_data[ $prop ] = apply_filters( 'woocommerce_privacy_remove_personal_data_customer_prop_value', '', $prop, $value, $customer ); - } - } - - // Set all new props and persist the new data to the database. - $customer->set_props( $anonymized_data ); - $customer->save(); - - /** - * Allow extensions to remove their own personal data for this customer. - * - * @since 3.4.0 - * @param WC_Customer $customer A customer object. - * @param WP_User $user User object. - */ - do_action( 'woocommerce_privacy_remove_customer_personal_data', $customer, $user ); - } - /** * Remove personal data specific to WooCommerce from an order object. * @@ -565,7 +502,7 @@ class WC_Privacy { * @param string $data The data being anonymized. * @return string Anonymized string. */ - public static function privacy_anonymize_data_custom_types( $anonymous, $type, $data ) { + public static function anonymize_custom_data_types( $anonymous, $type, $data ) { switch ( $type ) { case 'address_state': case 'address_country': diff --git a/includes/data-stores/class-wc-customer-download-log-data-store.php b/includes/data-stores/class-wc-customer-download-log-data-store.php index 47e427ad2e8..0c550f92b45 100644 --- a/includes/data-stores/class-wc-customer-download-log-data-store.php +++ b/includes/data-stores/class-wc-customer-download-log-data-store.php @@ -1,14 +1,15 @@ date( 'Y-m-d H:i:s', $download_log->get_timestamp( 'edit' )->getTimestamp() ), - 'permission_id' => $download_log->get_permission_id( 'edit' ), - 'user_id' => $download_log->get_user_id( 'edit' ), - 'user_ip_address' => $download_log->get_user_ip_address( 'edit' ), + 'timestamp' => date( 'Y-m-d H:i:s', $download_log->get_timestamp( 'edit' )->getTimestamp() ), + 'permission_id' => $download_log->get_permission_id( 'edit' ), + 'user_id' => $download_log->get_user_id( 'edit' ), + 'user_ip_address' => $download_log->get_user_ip_address( 'edit' ), ); $format = array( @@ -62,18 +63,16 @@ class WC_Customer_Download_Log_Data_Store implements WC_Customer_Download_Log_Da if ( $result ) { $download_log->set_id( $wpdb->insert_id ); $download_log->apply_changes(); - } - else { - wp_die( __( 'Unable to insert download log entry in database.', 'woocommerce' ) ); + } else { + wp_die( esc_html__( 'Unable to insert download log entry in database.', 'woocommerce' ) ); } } /** * Method to read a download log from the database. * - * @param $download_log - * - * @throws Exception + * @param WC_Customer_Download_Log $download_log Download log object. + * @throws Exception Exception when read is not possible. */ public function read( &$download_log ) { global $wpdb; @@ -85,20 +84,20 @@ class WC_Customer_Download_Log_Data_Store implements WC_Customer_Download_Log_Da throw new Exception( __( 'Invalid download log: no ID.', 'woocommerce' ) ); } + $table = $wpdb->prefix . self::get_table_name(); + // Query the DB for the download log. - $raw_download_log_query = $wpdb->prepare( - "SELECT * FROM {$wpdb->prefix}" . self::get_table_name() . " WHERE download_log_id = %d", $download_log->get_id() - ); - $raw_download_log = $wpdb->get_row( $raw_download_log_query ); + $raw_download_log = $wpdb->get_row( $wpdb->prepare( "SELECT * FROM {$table} WHERE download_log_id = %d", $download_log->get_id() ) ); // WPCS: unprepared SQL ok. + if ( ! $raw_download_log ) { throw new Exception( __( 'Invalid download log: not found.', 'woocommerce' ) ); } $download_log->set_props( array( - 'timestamp' => strtotime( $raw_download_log->timestamp ), - 'permission_id' => $raw_download_log->permission_id, - 'user_id' => $raw_download_log->user_id, - 'user_ip_address' => $raw_download_log->user_ip_address, + 'timestamp' => strtotime( $raw_download_log->timestamp ), + 'permission_id' => $raw_download_log->permission_id, + 'user_id' => $raw_download_log->user_id, + 'user_ip_address' => $raw_download_log->user_ip_address, ) ); $download_log->set_object_read( true ); @@ -107,16 +106,16 @@ class WC_Customer_Download_Log_Data_Store implements WC_Customer_Download_Log_Da /** * Method to update a download log in the database. * - * @param WC_Customer_Download_Log $download_log + * @param WC_Customer_Download_Log $download_log Download log object. */ public function update( &$download_log ) { global $wpdb; $data = array( - 'timestamp' => date( 'Y-m-d H:i:s', $download_log->get_timestamp( 'edit' )->getTimestamp() ), - 'permission_id' => $download_log->get_permission_id( 'edit' ), - 'user_id' => $download_log->get_user_id( 'edit' ), - 'user_ip_address' => $download_log->get_user_ip_address( 'edit' ), + 'timestamp' => date( 'Y-m-d H:i:s', $download_log->get_timestamp( 'edit' )->getTimestamp() ), + 'permission_id' => $download_log->get_permission_id( 'edit' ), + 'user_id' => $download_log->get_user_id( 'edit' ), + 'user_ip_address' => $download_log->get_user_ip_address( 'edit' ), ); $format = array( @@ -150,7 +149,7 @@ class WC_Customer_Download_Log_Data_Store implements WC_Customer_Download_Log_Da /** * Get array of download log ids by specified args. * - * @param array $args + * @param array $args Args to query. * @return array */ public function get_download_logs( $args = array() ) { @@ -168,22 +167,23 @@ class WC_Customer_Download_Log_Data_Store implements WC_Customer_Download_Log_Da ) ); $query = array(); - $query[] = "SELECT * FROM {$wpdb->prefix}" . self::get_table_name() . " WHERE 1=1"; + $table = $wpdb->prefix . self::get_table_name(); + $query[] = "SELECT * FROM {$table} WHERE 1=1"; if ( $args['permission_id'] ) { - $query[] = $wpdb->prepare( "AND permission_id = %d", $args['permission_id'] ); + $query[] = $wpdb->prepare( 'AND permission_id = %d', $args['permission_id'] ); } if ( $args['user_id'] ) { - $query[] = $wpdb->prepare( "AND user_id = %d", $args['user_id'] ); + $query[] = $wpdb->prepare( 'AND user_id = %d', $args['user_id'] ); } if ( $args['user_ip_address'] ) { - $query[] = $wpdb->prepare( "AND user_ip_address = %s", $args['user_ip_address'] ); + $query[] = $wpdb->prepare( 'AND user_ip_address = %s', $args['user_ip_address'] ); } $allowed_orders = array( 'download_log_id', 'timestamp', 'permission_id', 'user_id' ); - $order = in_array( $args['order'], $allowed_orders ) ? $args['order'] : 'download_log_id'; + $order = in_array( $args['order'], $allowed_orders, true ) ? $args['order'] : 'download_log_id'; $orderby = 'DESC' === strtoupper( $args['orderby'] ) ? 'DESC' : 'ASC'; $orderby_sql = sanitize_sql_orderby( "{$order} {$orderby}" ); $query[] = "ORDER BY {$orderby_sql}"; @@ -192,12 +192,12 @@ class WC_Customer_Download_Log_Data_Store implements WC_Customer_Download_Log_Da $query[] = $wpdb->prepare( 'LIMIT %d, %d', absint( $args['limit'] ) * absint( $args['page'] - 1 ), absint( $args['limit'] ) ); } - $raw_download_logs = $wpdb->get_results( implode( ' ', $query ) ); + $raw_download_logs = $wpdb->get_results( implode( ' ', $query ) ); // WPCS: unprepared SQL ok. switch ( $args['return'] ) { - case 'ids' : + case 'ids': return wp_list_pluck( $raw_download_logs, 'download_log_id' ); - default : + default: return array_map( array( $this, 'get_download_log' ), $raw_download_logs ); } } @@ -205,7 +205,7 @@ class WC_Customer_Download_Log_Data_Store implements WC_Customer_Download_Log_Da /** * Get download logs for a given download permission. * - * @param int $permission_id + * @param int $permission_id Permission to get logs for. * @return array */ public function get_download_logs_for_permission( $permission_id ) { @@ -215,8 +215,18 @@ class WC_Customer_Download_Log_Data_Store implements WC_Customer_Download_Log_Da } return $this->get_download_logs( array( - 'permission_id' => $permission_id + 'permission_id' => $permission_id, ) ); } + /** + * Method to delete download logs for a given permission ID. + * + * @since 3.4.0 + * @param int $id download_id of the downloads that will be deleted. + */ + public function delete_by_permission_id( $id ) { + global $wpdb; + $wpdb->query( $wpdb->prepare( "DELETE FROM {$wpdb->prefix}woocommerce_downloadable_product_permissions WHERE permission_id = %d", $id ) ); + } } diff --git a/includes/wc-user-functions.php b/includes/wc-user-functions.php index 43e5bd33b15..69197dc61fd 100644 --- a/includes/wc-user-functions.php +++ b/includes/wc-user-functions.php @@ -640,8 +640,6 @@ function wc_delete_user_data( $user_id ) { ) ); - wp_cache_delete( WC_Cache_Helper::get_cache_prefix( WC_SESSION_CACHE_GROUP ) . $user_id, WC_SESSION_CACHE_GROUP ); - // Revoke API keys. $wpdb->delete( $wpdb->prefix . 'woocommerce_api_keys', @@ -650,10 +648,6 @@ function wc_delete_user_data( $user_id ) { ) ); - // Revoke download permissioons. - $data_store = WC_Data_Store::load( 'customer-download' ); - $data_store->delete_by_user_id( $user_id ); - // Clean up payment tokens. $payment_tokens = WC_Payment_Tokens::get_customer_tokens( $user_id ); From f3388d8cd656a47d40a4f5fea80aa2e31ffa65fa Mon Sep 17 00:00:00 2001 From: Mike Jolley Date: Fri, 13 Apr 2018 18:25:51 +0100 Subject: [PATCH 30/61] tests --- tests/unit-tests/privacy/export.php | 174 +++++++++++++++------------- 1 file changed, 94 insertions(+), 80 deletions(-) diff --git a/tests/unit-tests/privacy/export.php b/tests/unit-tests/privacy/export.php index 898f012701c..d2470f3bcfd 100644 --- a/tests/unit-tests/privacy/export.php +++ b/tests/unit-tests/privacy/export.php @@ -21,21 +21,9 @@ class WC_Test_Privacy_Export extends WC_Unit_Test_Case { protected $customers = array(); /** - * Clean up after test. + * Load up the importer classes since they aren't loaded by default. */ - public function tearDown() { - foreach ( $this->orders as $object ) { - $object->delete( true ); - } - foreach ( $this->customers as $object ) { - $object->delete( true ); - } - } - - /** - * Test: Data exporter. - */ - public function test_data_exporter() { + public function setUp() { $customer1 = WC_Helper_Customer::create_customer( 'customer1', 'password', 'test1@test.com' ); $customer1->set_billing_email( 'customer1@test.com' ); $customer1->save(); @@ -61,83 +49,109 @@ class WC_Test_Privacy_Export extends WC_Unit_Test_Case { $this->orders[] = WC_Helper_Order::create_order( $customer1->get_id() ); $this->orders[] = WC_Helper_Order::create_order( $customer2->get_id() ); $this->orders[] = WC_Helper_Order::create_order( $customer2->get_id() ); + } + /** + * Clean up after test. + */ + public function tearDown() { + foreach ( $this->orders as $object ) { + $object->delete( true ); + } + foreach ( $this->customers as $object ) { + $object->delete( true ); + } + } + + /** + * Test: Customer data exporter. + */ + public function test_customer_data_exporter() { // Test a non existing user. - $response = WC_Privacy::data_exporter( 'doesnotexist@test.com', 0 ); + $response = WC_Privacy::customer_data_exporter( 'doesnotexist@test.com', 1 ); $this->assertEquals( array(), $response['data'] ); // Do a test export and check response. - $response = WC_Privacy::data_exporter( 'test1@test.com', 0 ); - $this->assertFalse( $response['done'] ); + $response = WC_Privacy::customer_data_exporter( 'test1@test.com', 1 ); + $this->assertTrue( $response['done'] ); $this->assertEquals( array( array( - 'name' => 'Billing Address 1', - 'value' => '123 South Street', - ), - array( - 'name' => 'Billing Address 2', - 'value' => 'Apt 1', - ), - array( - 'name' => 'Billing City', - 'value' => 'Philadelphia', - ), - array( - 'name' => 'Billing Postal/Zip Code', - 'value' => '19123', - ), - array( - 'name' => 'Billing State', - 'value' => 'PA', - ), - array( - 'name' => 'Billing Country', - 'value' => 'US', - ), - array( - 'name' => 'Billing Email', - 'value' => 'customer1@test.com', - ), - array( - 'name' => 'Shipping Address 1', - 'value' => '123 South Street', - ), - array( - 'name' => 'Shipping Address 2', - 'value' => 'Apt 1', - ), - array( - 'name' => 'Shipping City', - 'value' => 'Philadelphia', - ), - array( - 'name' => 'Shipping Postal/Zip Code', - 'value' => '19123', - ), - array( - 'name' => 'Shipping State', - 'value' => 'PA', - ), - array( - 'name' => 'Shipping Country', - 'value' => 'US', + 'group_id' => 'woocommerce_customer', + 'group_label' => 'Customer Data', + 'item_id' => 'user', + 'data' => array( + array( + 'name' => 'Billing Address 1', + 'value' => '123 South Street', + ), + array( + 'name' => 'Billing Address 2', + 'value' => 'Apt 1', + ), + array( + 'name' => 'Billing City', + 'value' => 'Philadelphia', + ), + array( + 'name' => 'Billing Postal/Zip Code', + 'value' => '19123', + ), + array( + 'name' => 'Billing State', + 'value' => 'PA', + ), + array( + 'name' => 'Billing Country', + 'value' => 'US', + ), + array( + 'name' => 'Email Address', + 'value' => 'customer1@test.com', + ), + array( + 'name' => 'Shipping Address 1', + 'value' => '123 South Street', + ), + array( + 'name' => 'Shipping Address 2', + 'value' => 'Apt 1', + ), + array( + 'name' => 'Shipping City', + 'value' => 'Philadelphia', + ), + array( + 'name' => 'Shipping Postal/Zip Code', + 'value' => '19123', + ), + array( + 'name' => 'Shipping State', + 'value' => 'PA', + ), + array( + 'name' => 'Shipping Country', + 'value' => 'US', + ), + ), ), ), $response['data'] ); + } + + /** + * Test: Order data exporter. + */ + public function test_order_data_exporter() { + $response = WC_Privacy::order_data_exporter( 'test1@test.com', 1 ); + + $this->assertEquals( 'woocommerce_orders', $response['data'][0]['group_id'] ); + $this->assertEquals( 'Orders', $response['data'][0]['group_label'] ); + $this->assertContains( 'order-', $response['data'][0]['item_id'] ); + $this->assertArrayHasKey( 'data', $response['data'][0] ); + $this->assertTrue( 8 === count( $response['data'][0]['data'] ), count( $response['data'][0]['data'] ) ); // Next page should be orders. - $response = WC_Privacy::data_exporter( 'test1@test.com', 1 ); - $this->assertTrue( 50 === count( $response['data'] ) ); - $this->assertArrayHasKey( 'name', $response['data'][0] ); - $this->assertArrayHasKey( 'value', $response['data'][0] ); - $this->assertContains( 'IP Address', $response['data'][0]['name'] ); - $this->assertContains( 'Billing Address', $response['data'][1]['name'] ); - $this->assertContains( 'Shipping Address', $response['data'][2]['name'] ); - $this->assertContains( 'Billing Phone', $response['data'][3]['name'] ); - $this->assertContains( 'Billing Email', $response['data'][4]['name'] ); - - // Next page should be orders. - $response = WC_Privacy::data_exporter( 'test1@test.com', 2 ); + $response = WC_Privacy::order_data_exporter( 'test1@test.com', 2 ); $this->assertTrue( $response['done'] ); - $this->assertTrue( 5 === count( $response['data'] ) ); + $this->assertTrue( 8 === count( $response['data'][0]['data'] ), count( $response['data'][0]['data'] ) ); } } From 3814796a248ddef604eced625bccdb07962d5f63 Mon Sep 17 00:00:00 2001 From: Paul Dechov Date: Mon, 16 Apr 2018 07:16:59 -0400 Subject: [PATCH 31/61] Enhance plugin installer to accept plugin 'file' 'file' string as part of plugin information is used for activating plugin in combination with slug, or instead of slug in the case of plugins already installed. Defaults to [slug].php. --- includes/class-wc-install.php | 22 +++++++++++----------- 1 file changed, 11 insertions(+), 11 deletions(-) diff --git a/includes/class-wc-install.php b/includes/class-wc-install.php index 76541cf99ff..e46053c9134 100644 --- a/includes/class-wc-install.php +++ b/includes/class-wc-install.php @@ -1058,13 +1058,12 @@ CREATE TABLE {$wpdb->prefix}woocommerce_termmeta ( /** * Get slug from path and associate it with the path. * - * @param array $plugins Associative array of plugin slugs to paths. + * @param array $plugins Associative array of plugin files to paths. * @param string $key Plugin relative path. Example: woocommerce/woocommerce.php. */ - private static function associate_plugin_slug( $plugins, $key ) { - $slug = explode( '/', $key ); - $slug = explode( '.', end( $slug ) ); - $plugins[ $slug[0] ] = $key; + private static function associate_plugin_file( $plugins, $key ) { + $path = explode( '/', $key ); + $plugins[ $path[1] ] = $key; return $plugins; } @@ -1091,15 +1090,16 @@ CREATE TABLE {$wpdb->prefix}woocommerce_termmeta ( $skin = new Automatic_Upgrader_Skin(); $upgrader = new WP_Upgrader( $skin ); - $installed_plugins = array_reduce( array_keys( get_plugins() ), array( __CLASS__, 'associate_plugin_slug' ), array() ); + $installed_plugins = array_reduce( array_keys( get_plugins() ), array( __CLASS__, 'associate_plugin_file' ), array() ); $plugin_slug = $plugin_to_install['repo-slug']; + $plugin_file = isset( $plugin_to_install['file'] ) ? $plugin_to_install['file'] : $plugin_slug . '.php'; $installed = false; $activate = false; // See if the plugin is installed already. - if ( isset( $installed_plugins[ $plugin_slug ] ) ) { + if ( isset( $installed_plugins[ $plugin_file ] ) ) { $installed = true; - $activate = ! is_plugin_active( $installed_plugins[ $plugin_slug ] ); + $activate = ! is_plugin_active( $installed_plugins[ $plugin_file ] ); } // Install this thing! @@ -1111,7 +1111,7 @@ CREATE TABLE {$wpdb->prefix}woocommerce_termmeta ( $plugin_information = plugins_api( 'plugin_information', array( - 'slug' => $plugin_to_install['repo-slug'], + 'slug' => $plugin_slug, 'fields' => array( 'short_description' => false, 'sections' => false, @@ -1175,7 +1175,7 @@ CREATE TABLE {$wpdb->prefix}woocommerce_termmeta ( __( '%1$s could not be installed (%2$s). Please install it manually by clicking here.', 'woocommerce' ), $plugin_to_install['name'], $e->getMessage(), - esc_url( admin_url( 'index.php?wc-install-plugin-redirect=' . $plugin_to_install['repo-slug'] ) ) + esc_url( admin_url( 'index.php?wc-install-plugin-redirect=' . $plugin_slug ) ) ) ); } @@ -1189,7 +1189,7 @@ CREATE TABLE {$wpdb->prefix}woocommerce_termmeta ( // Activate this thing. if ( $activate ) { try { - $result = activate_plugin( $installed_plugins[ $plugin_slug ] ); + $result = activate_plugin( $installed_plugins[ $plugin_file ] ); if ( is_wp_error( $result ) ) { throw new Exception( $result->get_error_message() ); From 2b118c8ba88c89ecc50bee3a89ba9cdfef3dbc16 Mon Sep 17 00:00:00 2001 From: Paul Dechov Date: Mon, 16 Apr 2018 07:20:42 -0400 Subject: [PATCH 32/61] Always check for active plugin in wizard before scheduling install Check for active plugin independent of whether 'file' is present. Also omits directory from 'file' string and prepends [slug]/ to it. --- includes/admin/class-wc-admin-setup-wizard.php | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/includes/admin/class-wc-admin-setup-wizard.php b/includes/admin/class-wc-admin-setup-wizard.php index d8f80974c07..9ed55b955b3 100644 --- a/includes/admin/class-wc-admin-setup-wizard.php +++ b/includes/admin/class-wc-admin-setup-wizard.php @@ -593,7 +593,7 @@ class WC_Admin_Setup_Wizard { * Helper method to queue the background install of a plugin. * * @param string $plugin_id Plugin id used for background install. - * @param array $plugin_info Plugin info array containing at least main file and repo slug. + * @param array $plugin_info Plugin info array containing name and repo-slug, and optionally file if different from [repo-slug].php. */ protected function install_plugin( $plugin_id, $plugin_info ) { // Make sure we don't trigger multiple simultaneous installs. @@ -601,7 +601,8 @@ class WC_Admin_Setup_Wizard { return; } - if ( ! empty( $plugin_info['file'] ) && is_plugin_active( $plugin_info['file'] ) ) { + $plugin_file = isset( $plugin_info['file'] ) ? $plugin_info['file'] : $plugin_info['repo-slug'] . '.php'; + if ( is_plugin_active( $plugin_info['repo-slug'] . '/' . $plugin_file ) ) { return; } From 73884400f1676da2770e6b9703e7b091ab8d3541 Mon Sep 17 00:00:00 2001 From: Paul Dechov Date: Mon, 16 Apr 2018 07:21:04 -0400 Subject: [PATCH 33/61] Remove unnecessary 'file' value for existing plugins --- includes/admin/class-wc-admin-setup-wizard.php | 3 --- 1 file changed, 3 deletions(-) diff --git a/includes/admin/class-wc-admin-setup-wizard.php b/includes/admin/class-wc-admin-setup-wizard.php index 9ed55b955b3..84d2cbddef0 100644 --- a/includes/admin/class-wc-admin-setup-wizard.php +++ b/includes/admin/class-wc-admin-setup-wizard.php @@ -648,7 +648,6 @@ class WC_Admin_Setup_Wizard { $this->install_plugin( 'jetpack', array( - 'file' => 'jetpack/jetpack.php', 'name' => __( 'Jetpack', 'woocommerce' ), 'repo-slug' => 'jetpack', ) @@ -663,7 +662,6 @@ class WC_Admin_Setup_Wizard { $this->install_plugin( 'woocommerce-services', array( - 'file' => 'woocommerce-services/woocommerce-services.php', 'name' => __( 'WooCommerce Services', 'woocommerce' ), 'repo-slug' => 'woocommerce-services', ) @@ -1892,7 +1890,6 @@ class WC_Admin_Setup_Wizard { } WC_Install::background_installer( 'jetpack', array( - 'file' => 'jetpack/jetpack.php', 'name' => __( 'Jetpack', 'woocommerce' ), 'repo-slug' => 'jetpack', ) ); From a4f76e3529d046ee4284b6611df9929890c5f656 Mon Sep 17 00:00:00 2001 From: Paul Dechov Date: Mon, 16 Apr 2018 07:22:15 -0400 Subject: [PATCH 34/61] Fix broken activation when done immediately after installation --- includes/class-wc-install.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/includes/class-wc-install.php b/includes/class-wc-install.php index e46053c9134..8a2c9115a3c 100644 --- a/includes/class-wc-install.php +++ b/includes/class-wc-install.php @@ -1189,7 +1189,7 @@ CREATE TABLE {$wpdb->prefix}woocommerce_termmeta ( // Activate this thing. if ( $activate ) { try { - $result = activate_plugin( $installed_plugins[ $plugin_file ] ); + $result = activate_plugin( $installed ? $installed_plugins[ $plugin_file ] : $plugin_slug . '/' . $plugin_file ); if ( is_wp_error( $result ) ) { throw new Exception( $result->get_error_message() ); From 7342807674889a15b43874a9e8c955e4c2e42690 Mon Sep 17 00:00:00 2001 From: claudiulodro Date: Mon, 16 Apr 2018 11:17:39 -0700 Subject: [PATCH 35/61] Update comments --- templates/content-single-product.php | 7 +++---- templates/single-product/add-to-cart/variable.php | 6 +++--- 2 files changed, 6 insertions(+), 7 deletions(-) diff --git a/templates/content-single-product.php b/templates/content-single-product.php index e26a6421b97..94ec098189c 100644 --- a/templates/content-single-product.php +++ b/templates/content-single-product.php @@ -10,9 +10,8 @@ * happen. When this occurs the version of the template file will be bumped and * the readme will list any important changes. * - * @see https://docs.woocommerce.com/document/template-structure/ - * @author WooThemes - * @package WooCommerce/Templates + * @see https://docs.woocommerce.com/document/template-structure/ + * @package WooCommerce/Templates * @version 3.0.0 */ @@ -21,7 +20,7 @@ if ( ! defined( 'ABSPATH' ) ) { } /** - * Hook Woocommerce_before_single_product. + * Hook: woocommerce_before_single_product. * * @hooked wc_print_notices - 10 */ diff --git a/templates/single-product/add-to-cart/variable.php b/templates/single-product/add-to-cart/variable.php index 74f3d7f5682..3bad96cdebe 100644 --- a/templates/single-product/add-to-cart/variable.php +++ b/templates/single-product/add-to-cart/variable.php @@ -56,12 +56,12 @@ do_action( 'woocommerce_before_add_to_cart_form' ); ?>
    do_action( 'woocommerce_single_variation' ); /** - * Woocommerce_after_single_variation Hook. + * Hook: woocommerce_after_single_variation. */ do_action( 'woocommerce_after_single_variation' ); ?> From 7869d5bc8319d4381b28ca1ea6cb6817cbf87889 Mon Sep 17 00:00:00 2001 From: Mohammed Saimon Date: Tue, 17 Apr 2018 20:37:33 +0600 Subject: [PATCH 36/61] fix(csv-importer): export/import: unlimited downloads/time on downloadable products conflict is fixed #19720 (#19732) * fix(csv-importer): export/import: unlimited downloads/time on downloadable products conflict is fixed #19720 * added -- which was removed unwillingly * changed method name to parse_int_field and removed unnecessary checking --- .../import/class-wc-product-csv-importer.php | 17 +++++++++++++++-- 1 file changed, 15 insertions(+), 2 deletions(-) diff --git a/includes/import/class-wc-product-csv-importer.php b/includes/import/class-wc-product-csv-importer.php index 622c7c6d07e..20eeb6cfa0b 100644 --- a/includes/import/class-wc-product-csv-importer.php +++ b/includes/import/class-wc-product-csv-importer.php @@ -536,6 +536,19 @@ class WC_Product_CSV_Importer extends WC_Product_Importer { return wc_clean( $value ); } + /** + * Parse an int value field + * + * @param int $value field value. + * @return int + */ + public function parse_int_field( $value ) { + // Remove the ' prepended to fields that start with - if needed + $value = $this->unescape_negative_number( $value ); + + return intval( $value ); + } + /** * Get formatting callback. * @@ -578,8 +591,8 @@ class WC_Product_CSV_Importer extends WC_Product_Importer { 'grouped_products' => array( $this, 'parse_relative_comma_field' ), 'upsell_ids' => array( $this, 'parse_relative_comma_field' ), 'cross_sell_ids' => array( $this, 'parse_relative_comma_field' ), - 'download_limit' => 'intval', - 'download_expiry' => 'intval', + 'download_limit' => array( $this, 'parse_int_field' ), + 'download_expiry' => array( $this, 'parse_int_field' ), 'product_url' => 'esc_url_raw', 'menu_order' => 'intval', ); From 8d393c6951ab2320f22a470aba42e78b3b518156 Mon Sep 17 00:00:00 2001 From: Mike Jolley Date: Tue, 17 Apr 2018 15:53:40 +0100 Subject: [PATCH 37/61] Bangladeshi states (districts) - ISO codes not made up codes --- i18n/states/BD.php | 129 ++++++++++++++++++++++----------------------- 1 file changed, 64 insertions(+), 65 deletions(-) diff --git a/i18n/states/BD.php b/i18n/states/BD.php index 26f7a3eccf3..aa769517c68 100644 --- a/i18n/states/BD.php +++ b/i18n/states/BD.php @@ -3,7 +3,6 @@ * Bangladeshi states (districts) * * @package WooCommerce/i18n - * @version 2.0.0 */ global $states; @@ -11,68 +10,68 @@ global $states; defined( 'ABSPATH' ) || exit; $states['BD'] = array( - 'BAG' => __( 'Bagerhat', 'woocommerce' ), - 'BAN' => __( 'Bandarban', 'woocommerce' ), - 'BAR' => __( 'Barguna', 'woocommerce' ), - 'BARI' => __( 'Barishal', 'woocommerce' ), - 'BHO' => __( 'Bhola', 'woocommerce' ), - 'BOG' => __( 'Bogura', 'woocommerce' ), - 'BRA' => __( 'Brahmanbaria', 'woocommerce' ), - 'CHA' => __( 'Chandpur', 'woocommerce' ), - 'CHA' => __( 'Chattogram', 'woocommerce' ), - 'CHU' => __( 'Chuadanga', 'woocommerce' ), - 'COX' => __( "Cox's Bazar", 'woocommerce' ), - 'CUM' => __( 'Cumilla', 'woocommerce' ), - 'DHA' => __( 'Dhaka', 'woocommerce' ), - 'DIN' => __( 'Dinajpur', 'woocommerce' ), - 'FAR' => __( 'Faridpur ', 'woocommerce' ), - 'FEN' => __( 'Feni', 'woocommerce' ), - 'GAI' => __( 'Gaibandha', 'woocommerce' ), - 'GAZI' => __( 'Gazipur', 'woocommerce' ), - 'GOP' => __( 'Gopalganj', 'woocommerce' ), - 'HAB' => __( 'Habiganj', 'woocommerce' ), - 'JAM' => __( 'Jamalpur', 'woocommerce' ), - 'JAS' => __( 'Jashore', 'woocommerce' ), - 'JHA' => __( 'Jhalokati', 'woocommerce' ), - 'JHE' => __( 'Jhenaidah', 'woocommerce' ), - 'JOY' => __( 'Joypurhat', 'woocommerce' ), - 'KHA' => __( 'Khagrachhari', 'woocommerce' ), - 'KHU' => __( 'Khulna', 'woocommerce' ), - 'KIS' => __( 'Kishoreganj', 'woocommerce' ), - 'KUR' => __( 'Kurigram', 'woocommerce' ), - 'KUS' => __( 'Kushtia', 'woocommerce' ), - 'LAK' => __( 'Lakshmipur', 'woocommerce' ), - 'LAL' => __( 'Lalmonirhat', 'woocommerce' ), - 'MAD' => __( 'Madaripur', 'woocommerce' ), - 'MAG' => __( 'Magura', 'woocommerce' ), - 'MAN' => __( 'Manikganj ', 'woocommerce' ), - 'MEH' => __( 'Meherpur', 'woocommerce' ), - 'MOU' => __( 'Moulvibazar', 'woocommerce' ), - 'MUN' => __( 'Munshiganj', 'woocommerce' ), - 'MYM' => __( 'Mymensingh', 'woocommerce' ), - 'NAO' => __( 'Naogaon', 'woocommerce' ), - 'NAR' => __( 'Narail', 'woocommerce' ), - 'NARG' => __( 'Narayanganj', 'woocommerce' ), - 'NARD' => __( 'Narsingdi', 'woocommerce' ), - 'NAT' => __( 'Natore', 'woocommerce' ), - 'NAW' => __( 'Nawabganj', 'woocommerce' ), - 'NET' => __( 'Netrakona', 'woocommerce' ), - 'NIL' => __( 'Nilphamari', 'woocommerce' ), - 'NOA' => __( 'Noakhali', 'woocommerce' ), - 'PAB' => __( 'Pabna', 'woocommerce' ), - 'PAN' => __( 'Panchagarh', 'woocommerce' ), - 'PAT' => __( 'Patuakhali', 'woocommerce' ), - 'PIR' => __( 'Pirojpur', 'woocommerce' ), - 'RAJB' => __( 'Rajbari', 'woocommerce' ), - 'RAJ' => __( 'Rajshahi', 'woocommerce' ), - 'RAN' => __( 'Rangamati', 'woocommerce' ), - 'RANP' => __( 'Rangpur', 'woocommerce' ), - 'SAT' => __( 'Satkhira', 'woocommerce' ), - 'SHA' => __( 'Shariatpur', 'woocommerce' ), - 'SHE' => __( 'Sherpur', 'woocommerce' ), - 'SIR' => __( 'Sirajganj', 'woocommerce' ), - 'SUN' => __( 'Sunamganj', 'woocommerce' ), - 'SYL' => __( 'Sylhet', 'woocommerce' ), - 'TAN' => __( 'Tangail', 'woocommerce' ), - 'THA' => __( 'Thakurgaon', 'woocommerce' ), + 'BD-05' => __( 'Bagerhat', 'woocommerce' ), + 'BD-01' => __( 'Bandarban', 'woocommerce' ), + 'BD-02' => __( 'Barguna', 'woocommerce' ), + 'BD-06' => __( 'Barishal', 'woocommerce' ), + 'BD-07' => __( 'Bhola', 'woocommerce' ), + 'BD-03' => __( 'Bogura', 'woocommerce' ), + 'BD-04' => __( 'Brahmanbaria', 'woocommerce' ), + 'BD-09' => __( 'Chandpur', 'woocommerce' ), + 'BD-10' => __( 'Chattogram', 'woocommerce' ), + 'BD-12' => __( 'Chuadanga', 'woocommerce' ), + 'BD-11' => __( "Cox's Bazar", 'woocommerce' ), + 'BD-08' => __( 'Cumilla', 'woocommerce' ), + 'BD-13' => __( 'Dhaka', 'woocommerce' ), + 'BD-14' => __( 'Dinajpur', 'woocommerce' ), + 'BD-15' => __( 'Faridpur ', 'woocommerce' ), + 'BD-16' => __( 'Feni', 'woocommerce' ), + 'BD-19' => __( 'Gaibandha', 'woocommerce' ), + 'BD-18' => __( 'Gazipur', 'woocommerce' ), + 'BD-17' => __( 'Gopalganj', 'woocommerce' ), + 'BD-20' => __( 'Habiganj', 'woocommerce' ), + 'BD-21' => __( 'Jamalpur', 'woocommerce' ), + 'BD-22' => __( 'Jashore', 'woocommerce' ), + 'BD-25' => __( 'Jhalokati', 'woocommerce' ), + 'BD-23' => __( 'Jhenaidah', 'woocommerce' ), + 'BD-24' => __( 'Joypurhat', 'woocommerce' ), + 'BD-29' => __( 'Khagrachhari', 'woocommerce' ), + 'BD-27' => __( 'Khulna', 'woocommerce' ), + 'BD-26' => __( 'Kishoreganj', 'woocommerce' ), + 'BD-28' => __( 'Kurigram', 'woocommerce' ), + 'BD-30' => __( 'Kushtia', 'woocommerce' ), + 'BD-31' => __( 'Lakshmipur', 'woocommerce' ), + 'BD-32' => __( 'Lalmonirhat', 'woocommerce' ), + 'BD-36' => __( 'Madaripur', 'woocommerce' ), + 'BD-37' => __( 'Magura', 'woocommerce' ), + 'BD-33' => __( 'Manikganj ', 'woocommerce' ), + 'BD-39' => __( 'Meherpur', 'woocommerce' ), + 'BD-38' => __( 'Moulvibazar', 'woocommerce' ), + 'BD-35' => __( 'Munshiganj', 'woocommerce' ), + 'BD-34' => __( 'Mymensingh', 'woocommerce' ), + 'BD-48' => __( 'Naogaon', 'woocommerce' ), + 'BD-43' => __( 'Narail', 'woocommerce' ), + 'BD-40' => __( 'Narayanganj', 'woocommerce' ), + 'BD-42' => __( 'Narsingdi', 'woocommerce' ), + 'BD-44' => __( 'Natore', 'woocommerce' ), + 'BD-45' => __( 'Nawabganj', 'woocommerce' ), + 'BD-41' => __( 'Netrakona', 'woocommerce' ), + 'BD-46' => __( 'Nilphamari', 'woocommerce' ), + 'BD-47' => __( 'Noakhali', 'woocommerce' ), + 'BD-49' => __( 'Pabna', 'woocommerce' ), + 'BD-52' => __( 'Panchagarh', 'woocommerce' ), + 'BD-51' => __( 'Patuakhali', 'woocommerce' ), + 'BD-50' => __( 'Pirojpur', 'woocommerce' ), + 'BD-53' => __( 'Rajbari', 'woocommerce' ), + 'BD-54' => __( 'Rajshahi', 'woocommerce' ), + 'BD-56' => __( 'Rangamati', 'woocommerce' ), + 'BD-55' => __( 'Rangpur', 'woocommerce' ), + 'BD-58' => __( 'Satkhira', 'woocommerce' ), + 'BD-62' => __( 'Shariatpur', 'woocommerce' ), + 'BD-57' => __( 'Sherpur', 'woocommerce' ), + 'BD-59' => __( 'Sirajganj', 'woocommerce' ), + 'BD-61' => __( 'Sunamganj', 'woocommerce' ), + 'BD-60' => __( 'Sylhet', 'woocommerce' ), + 'BD-63' => __( 'Tangail', 'woocommerce' ), + 'BD-64' => __( 'Thakurgaon', 'woocommerce' ), ); From 9b043868e9031e26f6e36277127ce0f5c9dc9ea2 Mon Sep 17 00:00:00 2001 From: Mike Jolley Date: Tue, 17 Apr 2018 16:13:44 +0100 Subject: [PATCH 38/61] Update routine --- includes/class-wc-install.php | 2 +- includes/wc-update-functions.php | 139 +++++++++++++++++++++++-------- 2 files changed, 105 insertions(+), 36 deletions(-) diff --git a/includes/class-wc-install.php b/includes/class-wc-install.php index 76541cf99ff..c7090b6d006 100644 --- a/includes/class-wc-install.php +++ b/includes/class-wc-install.php @@ -100,7 +100,7 @@ class WC_Install { 'wc_update_330_db_version', ), '3.4.0' => array( - 'wc_update_340_irish_states', + 'wc_update_340_states', 'wc_update_340_db_version', ), ); diff --git a/includes/wc-update-functions.php b/includes/wc-update-functions.php index 1a32ad42924..bdb2262b80e 100644 --- a/includes/wc-update-functions.php +++ b/includes/wc-update-functions.php @@ -1635,46 +1635,115 @@ function wc_update_330_db_version() { } /** - * Update state codes for Ireland. + * Update state codes for Ireland and BD. */ -function wc_update_340_irish_states() { +function wc_update_340_states() { global $wpdb; - $ie_states = array( - 'CK' => 'CO', - 'DN' => 'D', - 'GY' => 'G', - 'TY' => 'TA', + $country_states = array( + 'IE' => array( + 'CK' => 'CO', + 'DN' => 'D', + 'GY' => 'G', + 'TY' => 'TA', + ), + 'BD' => array( + 'BAG' => 'BD-05', + 'BAN' => 'BD-01', + 'BAR' => 'BD-02', + 'BARI' => 'BD-06', + 'BHO' => 'BD-07', + 'BOG' => 'BD-03', + 'BRA' => 'BD-04', + 'CHA' => 'BD-09', + 'CHI' => 'BD-10', + 'CHU' => 'BD-12', + 'COX' => 'BD-11', + 'CUM' => 'BD-08', + 'DHA' => 'BD-13', + 'DIN' => 'BD-14', + 'FAR' => 'BD-15', + 'FEN' => 'BD-16', + 'GAI' => 'BD-19', + 'GAZI' => 'BD-18', + 'GOP' => 'BD-17', + 'HAB' => 'BD-20', + 'JAM' => 'BD-21', + 'JAS' => 'BD-22', + 'JHA' => 'BD-25', + 'JHE' => 'BD-23', + 'JOY' => 'BD-24', + 'KHA' => 'BD-29', + 'KHU' => 'BD-27', + 'KIS' => 'BD-26', + 'KUR' => 'BD-28', + 'KUS' => 'BD-30', + 'LAK' => 'BD-31', + 'LAL' => 'BD-32', + 'MAD' => 'BD-36', + 'MAG' => 'BD-37', + 'MAN' => 'BD-33', + 'MEH' => 'BD-39', + 'MOU' => 'BD-38', + 'MUN' => 'BD-35', + 'MYM' => 'BD-34', + 'NAO' => 'BD-48', + 'NAR' => 'BD-43', + 'NARG' => 'BD-40', + 'NARD' => 'BD-42', + 'NAT' => 'BD-44', + 'NAW' => 'BD-45', + 'NET' => 'BD-41', + 'NIL' => 'BD-46', + 'NOA' => 'BD-47', + 'PAB' => 'BD-49', + 'PAN' => 'BD-52', + 'PAT' => 'BD-51', + 'PIR' => 'BD-50', + 'RAJB' => 'BD-53', + 'RAJ' => 'BD-54', + 'RAN' => 'BD-56', + 'RANP' => 'BD-55', + 'SAT' => 'BD-58', + 'SHA' => 'BD-57', + 'SIR' => 'BD-59', + 'SUN' => 'BD-61', + 'SYL' => 'BD-60', + 'TAN' => 'BD-63', + 'THA' => 'BD-64', + ), ); - foreach ( $ie_states as $old => $new ) { - $wpdb->query( - $wpdb->prepare( - "UPDATE $wpdb->postmeta - SET meta_value = %s - WHERE meta_key IN ( '_billing_state', '_shipping_state' ) - AND meta_value = %s", - $new, $old - ) - ); - $wpdb->update( - "{$wpdb->prefix}woocommerce_shipping_zone_locations", - array( - 'location_code' => 'IE:' . $new, - ), - array( - 'location_code' => 'IE:' . $old, - ) - ); - $wpdb->update( - "{$wpdb->prefix}woocommerce_tax_rates", - array( - 'tax_rate_state' => strtoupper( $new ), - ), - array( - 'tax_rate_state' => strtoupper( $old ), - ) - ); + foreach ( $country_states as $country => $states ) { + foreach ( $states as $old => $new ) { + $wpdb->query( + $wpdb->prepare( + "UPDATE $wpdb->postmeta + SET meta_value = %s + WHERE meta_key IN ( '_billing_state', '_shipping_state' ) + AND meta_value = %s", + $new, $old + ) + ); + $wpdb->update( + "{$wpdb->prefix}woocommerce_shipping_zone_locations", + array( + 'location_code' => $country . ':' . $new, + ), + array( + 'location_code' => $country . ':' . $old, + ) + ); + $wpdb->update( + "{$wpdb->prefix}woocommerce_tax_rates", + array( + 'tax_rate_state' => strtoupper( $new ), + ), + array( + 'tax_rate_state' => strtoupper( $old ), + ) + ); + } } } From 627292d62748c51ef423930940bc9ce63536cebc Mon Sep 17 00:00:00 2001 From: Claudio Sanches Date: Tue, 17 Apr 2018 12:14:18 -0300 Subject: [PATCH 39/61] Include categories and tags by default --- includes/wc-template-functions.php | 68 +++++++++++++++++++++--------- 1 file changed, 47 insertions(+), 21 deletions(-) diff --git a/includes/wc-template-functions.php b/includes/wc-template-functions.php index 19ae0701433..d9dee65fa69 100644 --- a/includes/wc-template-functions.php +++ b/includes/wc-template-functions.php @@ -512,6 +512,40 @@ function wc_product_post_class( $classes, $class = '', $post_id = '' ) { return $classes; } +/** + * Get product taxonomy HTML classes. + * + * @since 3.4.0 + * @param array $term_ids Array of terms IDs or objects. + * @param string $taxonomy Taxonomy. + * @return array + */ +function wc_get_product_taxonomy_class( $term_ids, $taxonomy ) { + $classes = array(); + + foreach ( $term_ids as $term_id ) { + $term = get_term( $term_id, $taxonomy ); + + if ( empty( $term->slug ) ) { + continue; + } + + $term_class = sanitize_html_class( $term->slug, $term->term_id ); + if ( is_numeric( $term_class ) || ! trim( $term_class, '-' ) ) { + $term_class = $term->term_id; + } + + // 'post_tag' uses the 'tag' prefix for backward compatibility. + if ( 'post_tag' === $taxonomy ) { + $classes[] = 'tag-' . $term_class; + } else { + $classes[] = sanitize_html_class( $taxonomy . '-' . $term_class, $taxonomy . '-' . $term->term_id ); + } + } + + return $classes; +} + /** * Retrieves the classes for the post div as an array. * @@ -524,10 +558,13 @@ function wc_product_post_class( $classes, $class = '', $post_id = '' ) { */ function wc_get_product_class( $class = '', $product_id = null ) { if ( is_a( $product_id, 'WC_Product' ) ) { + $product = $product_id; $product_id = $product_id->get_id(); + } else { + $post = get_post( $product_id ); + $product = wc_get_product( $post->ID ); } - $post = get_post( $product_id ); $classes = array(); if ( $class ) { @@ -540,7 +577,7 @@ function wc_get_product_class( $class = '', $product_id = null ) { $class = array(); } - if ( ! $post ) { + if ( ! $post || ! $product ) { return $classes; } @@ -587,31 +624,20 @@ function wc_get_product_class( $class = '', $product_id = null ) { // Hentry for hAtom compliance. $classes[] = 'hentry'; - // All public taxonomies. + // Include attributes and any extra taxonomy. if ( apply_filters( 'woocommerce_get_product_class_include_taxonomies', false ) ) { $taxonomies = get_taxonomies( array( 'public' => true ) ); foreach ( (array) $taxonomies as $taxonomy ) { - if ( is_object_in_taxonomy( $post->post_type, $taxonomy ) ) { - foreach ( (array) get_the_terms( $post->ID, $taxonomy ) as $term ) { - if ( empty( $term->slug ) ) { - continue; - } - - $term_class = sanitize_html_class( $term->slug, $term->term_id ); - if ( is_numeric( $term_class ) || ! trim( $term_class, '-' ) ) { - $term_class = $term->term_id; - } - - // 'post_tag' uses the 'tag' prefix for backward compatibility. - if ( 'post_tag' === $taxonomy ) { - $classes[] = 'tag-' . $term_class; - } else { - $classes[] = sanitize_html_class( $taxonomy . '-' . $term_class, $taxonomy . '-' . $term->term_id ); - } - } + if ( is_object_in_taxonomy( $post->post_type, $taxonomy ) && in_array( $taxonomy, array( 'product_cat', 'product_tag' ), true ) ) { + $classes = array_merge( $classes, wc_get_product_taxonomy_class( (array) get_the_terms( $post->ID, $taxonomy ), $taxonomy ) ); } } } + // Categories. + $classes = array_merge( $classes, wc_get_product_taxonomy_class( $product->get_category_ids(), 'product_cat' ) ); + + // Tags. + $classes = array_merge( $classes, wc_get_product_taxonomy_class( $product->get_tag_ids(), 'product_tag' ) ); $classes = array_map( 'esc_attr', $classes ); $classes = apply_filters( 'post_class', $classes, $class, $post->ID ); From 77b73e05c84a9b3b1268e1a3ea1a595310edfa8f Mon Sep 17 00:00:00 2001 From: Mike Jolley Date: Tue, 17 Apr 2018 16:16:11 +0100 Subject: [PATCH 40/61] Trigger updater --- includes/class-woocommerce.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/includes/class-woocommerce.php b/includes/class-woocommerce.php index f5da5e81c9f..61d77ae32b3 100644 --- a/includes/class-woocommerce.php +++ b/includes/class-woocommerce.php @@ -20,7 +20,7 @@ final class WooCommerce { * * @var string */ - public $version = '3.3.0'; + public $version = '3.4.0'; /** * The single instance of the class. From ba3da2fc1ff26fb6ea9c4e28a7bcbc595e6729a9 Mon Sep 17 00:00:00 2001 From: Mike Jolley Date: Tue, 17 Apr 2018 16:18:14 +0100 Subject: [PATCH 41/61] Use original code --- includes/wc-update-functions.php | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/includes/wc-update-functions.php b/includes/wc-update-functions.php index bdb2262b80e..7addb9fc5a3 100644 --- a/includes/wc-update-functions.php +++ b/includes/wc-update-functions.php @@ -1659,7 +1659,7 @@ function wc_update_340_states() { 'CHI' => 'BD-10', 'CHU' => 'BD-12', 'COX' => 'BD-11', - 'CUM' => 'BD-08', + 'COM' => 'BD-08', 'DHA' => 'BD-13', 'DIN' => 'BD-14', 'FAR' => 'BD-15', @@ -1669,7 +1669,7 @@ function wc_update_340_states() { 'GOP' => 'BD-17', 'HAB' => 'BD-20', 'JAM' => 'BD-21', - 'JAS' => 'BD-22', + 'JES' => 'BD-22', 'JHA' => 'BD-25', 'JHE' => 'BD-23', 'JOY' => 'BD-24', From c19836b0e45ac921ea6dea447b5e3e6266872cca Mon Sep 17 00:00:00 2001 From: Claudio Sanches Date: Tue, 17 Apr 2018 12:18:21 -0300 Subject: [PATCH 42/61] Moved espace to wc_product_class --- includes/wc-template-functions.php | 7 ++----- 1 file changed, 2 insertions(+), 5 deletions(-) diff --git a/includes/wc-template-functions.php b/includes/wc-template-functions.php index d9dee65fa69..cefb6e14ca7 100644 --- a/includes/wc-template-functions.php +++ b/includes/wc-template-functions.php @@ -639,10 +639,7 @@ function wc_get_product_class( $class = '', $product_id = null ) { // Tags. $classes = array_merge( $classes, wc_get_product_taxonomy_class( $product->get_tag_ids(), 'product_tag' ) ); - $classes = array_map( 'esc_attr', $classes ); - $classes = apply_filters( 'post_class', $classes, $class, $post->ID ); - - return array_unique( $classes ); + return array_unique( apply_filters( 'post_class', $classes, $class, $post->ID ) ); } /** @@ -653,7 +650,7 @@ function wc_get_product_class( $class = '', $product_id = null ) { * @param int|WP_Post|WC_Product $product_id Product ID or product object. */ function wc_product_class( $class = '', $product_id = null ) { - echo 'class="' . join( ' ', wc_get_product_class( $class, $product_id ) ) . '"'; // WPCS: XSS ok. + echo 'class="' . join( ' ', array_map( 'esc_attr', wc_get_product_class( $class, $product_id ) ) ) . '"'; } /** From 54b6174b342da806fe964294d38652dbdb85b6d2 Mon Sep 17 00:00:00 2001 From: Claudio Sanches Date: Tue, 17 Apr 2018 12:21:56 -0300 Subject: [PATCH 43/61] Fixed $post when using product instance --- includes/wc-template-functions.php | 1 + 1 file changed, 1 insertion(+) diff --git a/includes/wc-template-functions.php b/includes/wc-template-functions.php index cefb6e14ca7..62e2462a1e6 100644 --- a/includes/wc-template-functions.php +++ b/includes/wc-template-functions.php @@ -560,6 +560,7 @@ function wc_get_product_class( $class = '', $product_id = null ) { if ( is_a( $product_id, 'WC_Product' ) ) { $product = $product_id; $product_id = $product_id->get_id(); + $post = get_post( $product_id ); } else { $post = get_post( $product_id ); $product = wc_get_product( $post->ID ); From f18220a0090413cd9b1bf7f65a49916510cf2de2 Mon Sep 17 00:00:00 2001 From: Claudio Sanches Date: Tue, 17 Apr 2018 12:31:14 -0300 Subject: [PATCH 44/61] Updated unit tests --- includes/wc-template-functions.php | 2 +- tests/unit-tests/templates/functions.php | 27 +++++++++++++++++++++++- 2 files changed, 27 insertions(+), 2 deletions(-) diff --git a/includes/wc-template-functions.php b/includes/wc-template-functions.php index 62e2462a1e6..18517a78478 100644 --- a/includes/wc-template-functions.php +++ b/includes/wc-template-functions.php @@ -640,7 +640,7 @@ function wc_get_product_class( $class = '', $product_id = null ) { // Tags. $classes = array_merge( $classes, wc_get_product_taxonomy_class( $product->get_tag_ids(), 'product_tag' ) ); - return array_unique( apply_filters( 'post_class', $classes, $class, $post->ID ) ); + return array_filter( array_unique( apply_filters( 'post_class', $classes, $class, $post->ID ) ) ); } /** diff --git a/tests/unit-tests/templates/functions.php b/tests/unit-tests/templates/functions.php index 1f2fb58961a..3eccf479cab 100644 --- a/tests/unit-tests/templates/functions.php +++ b/tests/unit-tests/templates/functions.php @@ -13,13 +13,17 @@ class WC_Tests_Template_Functions extends WC_Unit_Test_Case { * * @covers wc_product_class() * @covers wc_product_post_class() - * @since 2.3.0 + * @covers wc_get_product_taxonomy_class() + * @since 3.4.0 */ public function test_wc_get_product_class() { + $category = wp_insert_term( 'Some Category', 'product_cat' ); + $product = new WC_Product_Simple(); $product->set_virtual( true ); $product->set_regular_price( '10' ); $product->set_sale_price( '5' ); + $product->set_category_ids( array( $category['term_id'] ) ); $product->save(); $expected = array( @@ -28,6 +32,7 @@ class WC_Tests_Template_Functions extends WC_Unit_Test_Case { 'product', 'type-product', 'status-publish', + 'product_cat-some-category', 'first', 'instock', 'sale', @@ -38,6 +43,26 @@ class WC_Tests_Template_Functions extends WC_Unit_Test_Case { $this->assertEquals( $expected, array_values( wc_get_product_class( 'foo', $product ) ) ); + // All taxonomies. + add_filter( 'woocommerce_get_product_class_include_taxonomies', '__return_true' ); + $expected = array( + 'foo', + 'post-' . $product->get_id(), + 'product', + 'type-product', + 'status-publish', + 'product_cat-some-category', + 'instock', + 'sale', + 'virtual', + 'purchasable', + 'product-type-simple', + ); + + $this->assertEquals( $expected, array_values( wc_get_product_class( 'foo', $product ) ) ); + add_filter( 'woocommerce_get_product_class_include_taxonomies', '__return_false' ); + $product->delete( true ); + wp_delete_term( $category['term_id'], 'product_cat' ); } } From a7ce4ff6d32f61782837b928b6b27e5f9e0675d8 Mon Sep 17 00:00:00 2001 From: Claudio Sanches Date: Tue, 17 Apr 2018 12:54:01 -0300 Subject: [PATCH 45/61] Escape all at the same time --- includes/wc-template-functions.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/includes/wc-template-functions.php b/includes/wc-template-functions.php index 18517a78478..cf1cefa8564 100644 --- a/includes/wc-template-functions.php +++ b/includes/wc-template-functions.php @@ -651,7 +651,7 @@ function wc_get_product_class( $class = '', $product_id = null ) { * @param int|WP_Post|WC_Product $product_id Product ID or product object. */ function wc_product_class( $class = '', $product_id = null ) { - echo 'class="' . join( ' ', array_map( 'esc_attr', wc_get_product_class( $class, $product_id ) ) ) . '"'; + echo 'class="' . esc_attr( join( ' ', wc_get_product_class( $class, $product_id ) ) ) . '"'; } /** From cadcd562d89876f3f208df3dcd5d129b4fe776a9 Mon Sep 17 00:00:00 2001 From: Valerie Date: Sat, 14 Apr 2018 23:34:26 -0400 Subject: [PATCH 46/61] OBW: Rename Extras Step as Recommended --- .../admin/class-wc-admin-setup-wizard.php | 39 ++++++++++++------- 1 file changed, 25 insertions(+), 14 deletions(-) diff --git a/includes/admin/class-wc-admin-setup-wizard.php b/includes/admin/class-wc-admin-setup-wizard.php index 84d2cbddef0..24835d2c442 100644 --- a/includes/admin/class-wc-admin-setup-wizard.php +++ b/includes/admin/class-wc-admin-setup-wizard.php @@ -71,7 +71,7 @@ class WC_Admin_Setup_Wizard { * * @return boolean */ - protected function should_show_theme_extra() { + protected function should_show_theme() { $support_woocommerce = current_theme_supports( 'woocommerce' ) && ! $this->is_default_theme(); return ( @@ -106,7 +106,7 @@ class WC_Admin_Setup_Wizard { * The "automated tax" extra should only be shown if the current user can * install plugins and the store is in a supported country. */ - protected function should_show_automated_tax_extra() { + protected function should_show_automated_tax() { if ( ! current_user_can( 'install_plugins' ) ) { return false; } @@ -121,6 +121,17 @@ class WC_Admin_Setup_Wizard { return in_array( $country_code, $tax_supported_countries, true ); } + /** + * Should we display the 'Recommended' step? + * True if at least one of the recommendations will be displayed. + * + * @return boolean + */ + protected function should_show_recommended_step() { + return $this->should_show_theme() + || $this->should_show_automated_tax(); + } + /** * Show the setup wizard. */ @@ -144,10 +155,10 @@ class WC_Admin_Setup_Wizard { 'view' => array( $this, 'wc_setup_shipping' ), 'handler' => array( $this, 'wc_setup_shipping_save' ), ), - 'extras' => array( - 'name' => __( 'Extras', 'woocommerce' ), - 'view' => array( $this, 'wc_setup_extras' ), - 'handler' => array( $this, 'wc_setup_extras_save' ), + 'recommended' => array( + 'name' => __( 'Recommended', 'woocommerce' ), + 'view' => array( $this, 'wc_setup_recommended' ), + 'handler' => array( $this, 'wc_setup_recommended_save' ), ), 'activate' => array( 'name' => __( 'Activate', 'woocommerce' ), @@ -161,9 +172,9 @@ class WC_Admin_Setup_Wizard { ), ); - // Hide the extras step if this store/user isn't eligible for them. - if ( ! $this->should_show_theme_extra() && ! $this->should_show_automated_tax_extra() ) { - unset( $default_steps['extras'] ); + // Hide recommended step if nothing is going to be shown there. + if ( ! $this->should_show_recommended_step() ) { + unset( $default_steps['recommended'] ); } // Hide shipping step if the store is selling digital products only. @@ -1559,11 +1570,11 @@ class WC_Admin_Setup_Wizard { } /** - * Extras. + * Recommended step */ - public function wc_setup_extras() { + public function wc_setup_recommended() { ?> -

    +

    should_show_theme_extra() ) : ?>
    + + ?> +

    @@ -1651,18 +1673,18 @@ class WC_Admin_Setup_Wizard { public function wc_setup_recommended_save() { check_admin_referer( 'wc-setup' ); + $setup_storefront = isset( $_POST['setup_storefront_theme'] ) && 'yes' === $_POST['setup_storefront_theme']; $setup_automated_tax = isset( $_POST['setup_automated_taxes'] ) && 'yes' === $_POST['setup_automated_taxes']; - $install_storefront = isset( $_POST['setup_storefront_theme'] ) && 'yes' === $_POST['setup_storefront_theme']; update_option( 'woocommerce_calc_taxes', $setup_automated_tax ? 'yes' : 'no' ); update_option( 'woocommerce_setup_automated_taxes', $setup_automated_tax ); + if ( $setup_storefront ) { + $this->install_theme( 'storefront' ); if ( $setup_automated_tax ) { $this->install_woocommerce_services(); } - if ( $install_storefront ) { - $this->install_theme( 'storefront' ); } wp_redirect( esc_url_raw( $this->get_next_step_link() ) ); From c1e55cd6a5f5a6e5578ad03082202a85f623522e Mon Sep 17 00:00:00 2001 From: Valerie Date: Sat, 14 Apr 2018 23:50:49 -0400 Subject: [PATCH 48/61] OBW: Update automated taxes option --- assets/css/wc-setup-rtl.css | 2 +- assets/css/wc-setup.css | 2 +- assets/css/wc-setup.scss | 6 +++ assets/images/obw-taxes-icon.svg | 1 + .../admin/class-wc-admin-setup-wizard.php | 44 +++++-------------- 5 files changed, 21 insertions(+), 34 deletions(-) create mode 100644 assets/images/obw-taxes-icon.svg diff --git a/assets/css/wc-setup-rtl.css b/assets/css/wc-setup-rtl.css index ce53a1158c1..af9802b4f45 100644 --- a/assets/css/wc-setup-rtl.css +++ b/assets/css/wc-setup-rtl.css @@ -1 +1 @@ -@charset "UTF-8";body{margin:65px auto 24px;box-shadow:none;background:#f1f1f1;padding:0}#wc-logo{border:0;margin:0 0 24px;padding:0;text-align:center}#wc-logo img{max-width:30%}.wc-setup{text-align:center}.wc-setup .select2-container{text-align:right}.wc-setup .hidden{display:none}.wc-setup-content{box-shadow:0 1px 3px rgba(0,0,0,.13);padding:2em;margin:0 0 20px;background:#fff;overflow:hidden;zoom:1;text-align:right}.wc-setup-content h1,.wc-setup-content h2,.wc-setup-content h3,.wc-setup-content table{margin:0 0 20px;border:0;padding:0;color:#666;clear:none;font-weight:500}.wc-setup-content p{margin:20px 0;font-size:1em;line-height:1.75em;color:#666}.wc-setup-content table{font-size:1em;line-height:1.75em;color:#666}.wc-setup-content a{color:#a16696}.wc-setup-content a:focus,.wc-setup-content a:hover{color:#111}.wc-setup-content .form-table th{width:35%;vertical-align:top;font-weight:400}.wc-setup-content .form-table td{vertical-align:top}.wc-setup-content .form-table td input,.wc-setup-content .form-table td select{width:100%;box-sizing:border-box}.wc-setup-content .form-table td input[size]{width:auto}.wc-setup-content .form-table td .description{line-height:1.5em;display:block;margin-top:.25em;color:#999;font-style:italic}.wc-setup-content .form-table td .input-checkbox,.wc-setup-content .form-table td .input-radio{width:auto;box-sizing:inherit;padding:inherit;margin:0 0 0 .5em;box-shadow:none}.wc-setup-content .form-table .section_title td{padding:0}.wc-setup-content .form-table .section_title td h2,.wc-setup-content .form-table .section_title td p{margin:12px 0 0}.wc-setup-content .form-table td,.wc-setup-content .form-table th{padding:12px 0;margin:0;border:0}.wc-setup-content .form-table td:first-child,.wc-setup-content .form-table th:first-child{padding-left:1em}.wc-setup-content table.tax-rates{width:100%;font-size:.92em}.wc-setup-content table.tax-rates th{padding:0;text-align:center;width:auto;vertical-align:middle}.wc-setup-content table.tax-rates td{border:1px solid #f5f5f5;padding:6px;text-align:center;vertical-align:middle}.wc-setup-content table.tax-rates td input{outline:0;border:0;padding:0;box-shadow:none;text-align:center;width:100%}.wc-setup-content table.tax-rates td.sort{cursor:move;color:#ccc}.wc-setup-content table.tax-rates td.sort::before{content:'\f333';font-family:dashicons}.wc-setup-content table.tax-rates td.readonly{background:#f5f5f5}.wc-setup-content table.tax-rates .add{padding:1em 1em 0 0;line-height:1em;font-size:1em;width:0;margin:6px 0 0;height:0;overflow:hidden;position:relative;display:inline-block}.wc-setup-content table.tax-rates .add::before{content:'\f502';font-family:dashicons;position:absolute;right:0;top:0}.wc-setup-content table.tax-rates .remove{padding:1em 1em 0 0;line-height:1em;font-size:1em;width:0;margin:0;height:0;overflow:hidden;position:relative;display:inline-block}.wc-setup-content table.tax-rates .remove::before{content:'\f182';font-family:dashicons;position:absolute;right:0;top:0}.wc-setup-content .wc-setup-pages{width:100%;border-top:1px solid #eee}.wc-setup-content .wc-setup-pages thead th{display:none}.wc-setup-content .wc-setup-pages .page-name{width:30%;font-weight:700}.wc-setup-content .wc-setup-pages td,.wc-setup-content .wc-setup-pages th{padding:14px 0;border-bottom:1px solid #eee}.wc-setup-content .wc-setup-pages td:first-child,.wc-setup-content .wc-setup-pages th:first-child{padding-left:9px}.wc-setup-content .wc-setup-pages th{padding-top:0}.wc-setup-content .wc-setup-pages .page-options p{color:#777;margin:6px 24px 0 0;line-height:1.75em}.wc-setup-content .wc-setup-pages .page-options p input{vertical-align:middle;margin:1px 0 0;height:1.75em;width:1.75em;line-height:1.75em}.wc-setup-content .wc-setup-pages .page-options p label{line-height:1}@media screen and (max-width:782px){.wc-setup-content .form-table tbody th{width:auto}}.wc-setup-content .twitter-share-button{float:left}.wc-setup-content .wc-setup-next-steps{overflow:hidden;margin:0 0 24px;padding-bottom:2px}.wc-setup-content .wc-setup-next-steps h2{margin-bottom:12px}.wc-setup-content .wc-setup-next-steps .wc-setup-next-steps-first{float:right;width:50%;box-sizing:border-box}.wc-setup-content .wc-setup-next-steps .wc-setup-next-steps-last{float:left;width:50%;box-sizing:border-box}.wc-setup-content .wc-setup-next-steps ul{padding:0 0 0 2em;list-style:none outside;margin:0}.wc-setup-content .wc-setup-next-steps ul li a{display:block;padding:0 0 .75em}.wc-setup-content .wc-setup-next-steps ul .setup-product a.button{background-color:#f7f7f7;border-color:#ccc;color:#23282d;box-shadow:inset 0 1px 0 rgba(255,255,255,.25),0 1px 0 #ccc;text-shadow:-1px 0 1px #eee,0 1px 1px #eee;font-size:1em;height:auto;line-height:1.75em;margin:0 0 .75em;opacity:1;padding:1em;text-align:center}.wc-setup-content .wc-setup-next-steps ul .setup-product a.button:active,.wc-setup-content .wc-setup-next-steps ul .setup-product a.button:focus,.wc-setup-content .wc-setup-next-steps ul .setup-product a.button:hover{background:#f5f5f5;border-color:#aaa}.wc-setup-content .wc-setup-next-steps ul .setup-product a.button-primary{color:#fff;background-color:#bb77ae;border-color:#a36597;box-shadow:inset 0 1px 0 rgba(255,255,255,.25),0 1px 0 #a36597;text-shadow:0 -1px 1px #a36597,-1px 0 1px #a36597,0 1px 1px #a36597,1px 0 1px #a36597}.wc-setup-content .wc-setup-next-steps ul .setup-product a.button-primary:active,.wc-setup-content .wc-setup-next-steps ul .setup-product a.button-primary:focus,.wc-setup-content .wc-setup-next-steps ul .setup-product a.button-primary:hover{color:#fff;background:#a36597;border-color:#a36597;box-shadow:inset 0 1px 0 rgba(255,255,255,.25),0 1px 0 #a36597}.wc-setup-content .wc-setup-next-steps ul li a::before{color:#82878c;font:normal 20px/1 dashicons;speak:none;display:inline-block;padding:0 0 0 10px;top:1px;position:relative;text-decoration:none!important;vertical-align:top}.wc-setup-content .wc-setup-next-steps ul .learn-more a::before{content:'\f105'}.wc-setup-content .wc-setup-next-steps ul .video-walkthrough a::before{content:'\f126'}.wc-setup-content .wc-setup-next-steps ul .newsletter a::before{content:'\f465'}.wc-setup-content .updated,.wc-setup-content .woocommerce-newsletter{padding:24px 24px 0;margin:0 0 24px;overflow:hidden;background:#f5f5f5}.wc-setup-content .updated p,.wc-setup-content .woocommerce-newsletter p{padding:0;margin:0 0 12px}.wc-setup-content .updated form,.wc-setup-content .updated p:last-child,.wc-setup-content .woocommerce-newsletter form,.wc-setup-content .woocommerce-newsletter p:last-child{margin:0 0 24px}.wc-setup-content .woocommerce-tracker{margin:24px 0;border:1px solid #eee;padding:20px;border-radius:4px;overflow:hidden}.wc-setup-content .woocommerce-tracker p{font-size:14px;line-height:1.5em}.wc-setup-content .woocommerce-tracker .checkbox{line-height:24px;font-weight:500;font-size:1em;margin-top:0;margin-bottom:20px}.wc-setup-content .woocommerce-tracker .checkbox input[type=checkbox]{opacity:0;position:absolute;right:-9999px}.wc-setup-content .woocommerce-tracker .checkbox label{position:relative;display:inline-block;padding-right:28px}.wc-setup-content .woocommerce-tracker .checkbox label:after,.wc-setup-content .woocommerce-tracker .checkbox label:before{position:absolute;content:"";display:inline-block}.wc-setup-content .woocommerce-tracker .checkbox label:before{height:16px;width:16px;right:0;top:3px;border:1px solid #aaa;background-color:#fff;border-radius:3px}.wc-setup-content .woocommerce-tracker .checkbox label:after{height:5px;width:9px;border-right:2px solid;border-bottom:2px solid;-webkit-transform:rotate(45deg);-ms-transform:rotate(45deg);transform:rotate(45deg);right:4px;top:7px;color:#fff}.wc-setup-content .woocommerce-tracker .checkbox input[type=checkbox]+label::after{content:none}.wc-setup-content .woocommerce-tracker .checkbox input[type=checkbox]:checked+label::after{content:""}.wc-setup-content .woocommerce-tracker .checkbox input[type=checkbox]:focus+label::before{outline:#3b99fc auto 5px}.wc-setup-content .woocommerce-tracker .checkbox input[type=checkbox]:checked+label::before{background:#935687;border-color:#935687;outline:0}.wc-setup-steps{padding:0 0 24px;margin:0;list-style:none outside;overflow:hidden;color:#ccc;width:100%;display:-webkit-inline-box;display:-ms-inline-flexbox;display:inline-flex}.wc-setup-steps li{width:100%;float:right;padding:0 0 .8em;margin:0;text-align:center;position:relative;border-bottom:4px solid #ccc;line-height:1.4em}.wc-setup-steps li a{color:#a16696;text-decoration:none;padding:1.5em;margin:-1.5em;position:relative;z-index:1}.wc-setup-steps li a:focus,.wc-setup-steps li a:hover{color:#111;text-decoration:underline}.wc-setup-steps li::before{content:'';border:4px solid #ccc;border-radius:100%;width:4px;height:4px;position:absolute;bottom:0;right:50%;margin-right:-6px;margin-bottom:-8px;background:#fff}.wc-setup-steps li.active{border-color:#a16696;color:#a16696;font-weight:700}.wc-setup-steps li.active::before{border-color:#a16696}.wc-setup-steps li.done{border-color:#a16696;color:#a16696}.wc-setup-steps li.done::before{border-color:#a16696;background:#a16696}.wc-setup .wc-setup-actions{overflow:hidden;margin:20px 0 0;position:relative}.wc-setup .wc-setup-actions .button{font-size:1.25em;padding:.5em 1em;line-height:1em;margin-left:.5em;margin-bottom:2px;height:auto;border-radius:4px}.wc-setup .wc-setup-actions .button-primary{background-color:#bb77ae;border-color:#a36597;box-shadow:inset 0 1px 0 rgba(255,255,255,.25),0 1px 0 #a36597;text-shadow:0 -1px 1px #a36597,-1px 0 1px #a36597,0 1px 1px #a36597,1px 0 1px #a36597;margin:0;opacity:1}.wc-setup .wc-setup-actions .button-primary:active,.wc-setup .wc-setup-actions .button-primary:focus,.wc-setup .wc-setup-actions .button-primary:hover{background:#a36597;border-color:#a36597;box-shadow:inset 0 1px 0 rgba(255,255,255,.25),0 1px 0 #a36597}.wc-setup-content p:last-child{margin-bottom:0}.wc-setup-content p.store-setup{margin-top:0}.wc-setup-footer-links{font-size:.85em;color:#b5b5b5;margin:1.18em auto;display:inline-block;text-align:center}.wc-wizard-storefront .wc-wizard-storefront-intro{padding:40px 40px 0;background:#f5f5f5;text-align:center}.wc-wizard-storefront .wc-wizard-storefront-intro img{margin:40px 0 0 0;width:100%;display:block}.wc-wizard-storefront .wc-wizard-storefront-features{list-style:none outside;margin:0 0 20px;padding:0 30px 0 0;overflow:hidden}.wc-wizard-storefront .wc-wizard-storefront-feature{margin:0;padding:20px 2em 20px 30px;width:50%;box-sizing:border-box}.wc-wizard-storefront .wc-wizard-storefront-feature::before{margin-right:-2em;position:absolute}.wc-wizard-storefront .wc-wizard-storefront-feature.first{clear:both;float:right}.wc-wizard-storefront .wc-wizard-storefront-feature.last{float:left}.wc-wizard-storefront .wc-wizard-storefront-feature__bulletproof::before{content:'πŸ”’'}.wc-wizard-storefront .wc-wizard-storefront-feature__mobile::before{content:'πŸ“±'}.wc-wizard-storefront .wc-wizard-storefront-feature__accessibility::before{content:'πŸ‘“'}.wc-wizard-storefront .wc-wizard-storefront-feature__search::before{content:'πŸ”'}.wc-wizard-storefront .wc-wizard-storefront-feature__compatibility::before{content:'πŸ”§'}.wc-wizard-storefront .wc-wizard-storefront-feature__extendable::before{content:'🎨'}.wc-wizard-services{border:1px solid #eee;padding:0;margin:0 0 1em;list-style:none outside;border-radius:4px;overflow:hidden}.wc-wizard-services p{margin:0 0 1em 0;padding:0;font-size:1em;line-height:1.5em}.wc-wizard-service-item,.wc-wizard-services-list-toggle{display:-webkit-box;display:-ms-flexbox;display:flex;-ms-flex-wrap:nowrap;flex-wrap:nowrap;-webkit-box-pack:justify;-ms-flex-pack:justify;justify-content:space-between;padding:0;border-bottom:1px solid #eee;color:#666;-webkit-box-align:center;-ms-flex-align:center;align-items:center}.wc-wizard-service-item:last-child,.wc-wizard-services-list-toggle:last-child{border-bottom:0}.wc-wizard-service-item .payment-gateway-fee,.wc-wizard-services-list-toggle .payment-gateway-fee{color:#a6a6a6}.wc-wizard-service-item .wc-wizard-service-name,.wc-wizard-services-list-toggle .wc-wizard-service-name{-ms-flex-preferred-size:0;flex-basis:0;min-width:160px;text-align:center;font-weight:700;padding:2em 0;-ms-flex-item-align:stretch;align-self:stretch;display:-webkit-box;display:-ms-flexbox;display:flex;-webkit-box-align:baseline;-ms-flex-align:baseline;align-items:baseline}.wc-wizard-payment-gateway-form .wc-wizard-service-item .wc-wizard-service-name,.wc-wizard-payment-gateway-form .wc-wizard-services-list-toggle .wc-wizard-service-name{-webkit-box-pack:center;-ms-flex-pack:center;justify-content:center}.wc-wizard-service-item .wc-wizard-service-name img,.wc-wizard-services-list-toggle .wc-wizard-service-name img{max-width:75px}.wc-wizard-service-item.stripe-logo .wc-wizard-service-name img,.wc-wizard-services-list-toggle.stripe-logo .wc-wizard-service-name img{padding:8px 0}.wc-wizard-service-item.paypal-logo .wc-wizard-service-name img,.wc-wizard-services-list-toggle.paypal-logo .wc-wizard-service-name img{max-width:87px;padding:2px 0}.wc-wizard-service-item.klarna-logo .wc-wizard-service-name,.wc-wizard-services-list-toggle.klarna-logo .wc-wizard-service-name{background:#000}.wc-wizard-service-item.klarna-logo .wc-wizard-service-name img,.wc-wizard-services-list-toggle.klarna-logo .wc-wizard-service-name img{max-width:87px;padding:12px 0}.wc-wizard-service-item.square-logo .wc-wizard-service-name,.wc-wizard-services-list-toggle.square-logo .wc-wizard-service-name{background:#000}.wc-wizard-service-item.square-logo .wc-wizard-service-name img,.wc-wizard-services-list-toggle.square-logo .wc-wizard-service-name img{max-width:95px;padding:12px 0}.wc-wizard-service-item .wc-wizard-service-description,.wc-wizard-services-list-toggle .wc-wizard-service-description{-webkit-box-flex:1;-ms-flex-positive:1;flex-grow:1;padding:20px}.wc-wizard-service-item .wc-wizard-service-description p,.wc-wizard-services-list-toggle .wc-wizard-service-description p{margin-bottom:1em}.wc-wizard-service-item .wc-wizard-service-description p:last-child,.wc-wizard-services-list-toggle .wc-wizard-service-description p:last-child{margin-bottom:0}.wc-wizard-service-item .wc-wizard-service-description .wc-wizard-service-settings-description,.wc-wizard-services-list-toggle .wc-wizard-service-description .wc-wizard-service-settings-description{display:block;font-style:italic;color:#999}.wc-wizard-service-item .wc-wizard-service-enable,.wc-wizard-services-list-toggle .wc-wizard-service-enable{-ms-flex-preferred-size:0;flex-basis:0;min-width:75px;text-align:center;cursor:pointer;padding:2em 0;position:relative;max-height:1.5em;-ms-flex-item-align:start;align-self:flex-start}.wc-wizard-service-item .wc-wizard-service-toggle,.wc-wizard-services-list-toggle .wc-wizard-service-toggle{height:16px;width:32px;border:2px solid #935687;background-color:#935687;display:inline-block;text-indent:-9999px;border-radius:10em;position:relative}.wc-wizard-service-item .wc-wizard-service-toggle input[type=checkbox],.wc-wizard-services-list-toggle .wc-wizard-service-toggle input[type=checkbox]{display:none}.wc-wizard-service-item .wc-wizard-service-toggle:before,.wc-wizard-services-list-toggle .wc-wizard-service-toggle:before{content:"";display:block;width:16px;height:16px;background:#fff;position:absolute;top:0;left:0;border-radius:100%}.wc-wizard-service-item .wc-wizard-service-toggle.disabled,.wc-wizard-services-list-toggle .wc-wizard-service-toggle.disabled{border-color:#999;background-color:#999}.wc-wizard-service-item .wc-wizard-service-toggle.disabled:before,.wc-wizard-services-list-toggle .wc-wizard-service-toggle.disabled:before{left:auto;right:0}.wc-wizard-service-item .wc-wizard-service-settings,.wc-wizard-services-list-toggle .wc-wizard-service-settings{display:none;margin-bottom:0;cursor:default}.wc-wizard-service-item .wc-wizard-service-settings.hide,.wc-wizard-services-list-toggle .wc-wizard-service-settings.hide{display:none}.wc-wizard-service-item.checked .wc-wizard-service-settings,.wc-wizard-services-list-toggle.checked .wc-wizard-service-settings{display:inline-block}.wc-wizard-service-item.checked .wc-wizard-service-settings.hide,.wc-wizard-services-list-toggle.checked .wc-wizard-service-settings.hide{display:none}.wc-wizard-service-item.closed,.wc-wizard-services-list-toggle.closed{border-bottom:0}.wc-wizard-services-list-toggle{cursor:pointer}.wc-wizard-services-list-toggle .wc-wizard-service-enable::before{content:"\f343";font-family:dashicons;visibility:initial;color:#666;font-size:25px;margin-top:-7px;margin-right:-5px;position:absolute;visibility:visible}.wc-wizard-services-list-toggle.closed .wc-wizard-service-enable::before{content:"\f347"}.wc-wizard-services-list-toggle .wc-wizard-service-enable input{visibility:hidden;position:relative}.wc-wizard-services.manual .wc-wizard-service-item{display:none}.wc-wizard-services.shipping .wc-wizard-service-name{font-weight:400;text-align:right;-webkit-box-align:center;-ms-flex-align:center;align-items:center;max-height:5em;padding:0}.wc-wizard-services.shipping .wc-wizard-service-item{padding-right:2em;padding-top:.67em}.wc-wizard-services.shipping .wc-wizard-service-item:first-child{border-bottom:0;padding-bottom:0;font-weight:700}.wc-wizard-services.shipping .wc-wizard-service-item:first-child .wc-wizard-service-name{font-weight:700}.wc-wizard-services.shipping .shipping-method-setting,.wc-wizard-services.shipping .wc-wizard-shipping-method-select{display:-webkit-box;display:-ms-flexbox;display:flex}.wc-wizard-services.shipping .shipping-method-setting.hide,.wc-wizard-services.shipping .wc-wizard-shipping-method-select.hide{display:none}.wc-wizard-services.shipping .shipping-method-setting input,.wc-wizard-services.shipping .wc-wizard-shipping-method-dropdown{margin-left:2em;margin-bottom:1em}.wc-wizard-services.shipping .shipping-method-setting input .select2,.wc-wizard-services.shipping .wc-wizard-shipping-method-dropdown .select2{min-width:130px}.wc-wizard-services.shipping .wc-wizard-service-description{display:-webkit-box;display:-ms-flexbox;display:flex;-webkit-box-orient:vertical;-webkit-box-direction:normal;-ms-flex-direction:column;flex-direction:column;color:#a6a6a6}.wc-wizard-services.shipping .wc-wizard-service-item:not(:first-child) .wc-wizard-service-description{font-size:.92em;padding-bottom:10px}.wc-wizard-services.shipping .shipping-method-setting input{width:95px;border:1px solid #aaa;border-color:#ddd;border-radius:4px;height:28px;padding-right:8px;padding-left:24px;font-size:14px;color:#444;background-color:#fff;display:inline-block}.wc-wizard-services.shipping .shipping-method-description,.wc-wizard-services.shipping .shipping-method-setting .description{color:#7e7e7e;font-size:.9em}.wc-wizard-services.shipping .shipping-method-setting input::-webkit-input-placeholder{color:#e1e1e1}.wc-wizard-services.shipping .shipping-method-setting input::-moz-placeholder{color:#e1e1e1}.wc-wizard-services.shipping .shipping-method-setting input:-ms-input-placeholder{color:#e1e1e1}.wc-wizard-services.shipping .shipping-method-setting input::placeholder{color:#e1e1e1}.wc-setup-shipping-units p{line-height:1.5em;font-size:13px;margin-bottom:.25em}.wc-setup-shipping-units .wc-setup-shipping-unit{margin-bottom:1.75em}.wc-setup-shipping-units .wc-setup-shipping-unit .select2{min-width:100%}.hide{display:none}.wc-wizard-features{display:-webkit-box;display:-ms-flexbox;display:flex;-ms-flex-wrap:wrap;flex-wrap:wrap;list-style:none;padding:0}.wc-wizard-features .wc-wizard-feature-item{-ms-flex-preferred-size:calc(50% - 4em - 3px);flex-basis:calc(50% - 4em - 3px);border:1px solid #eee;padding:2em}.wc-wizard-features .wc-wizard-feature-item:nth-child(1){border-radius:0 4px 0 0}.wc-wizard-features .wc-wizard-feature-item:nth-child(2){border-right:0;border-radius:4px 0 0 0}.wc-wizard-features .wc-wizard-feature-item:nth-child(3){border-top:0;border-radius:0 0 4px 0}.wc-wizard-features .wc-wizard-feature-item:nth-child(4){border-top:0;border-right:0;border-radius:0 0 0 4px}.wc-wizard-features p.wc-wizard-feature-description,.wc-wizard-features p.wc-wizard-feature-name{margin:0;line-height:1.5em}h3.jetpack-reasons{text-align:center;margin:3em 0 1em 0;font-size:14px}.jetpack-logo,.wcs-notice{display:block;margin:1.75em auto 2em auto;max-height:175px}.activate-splash .jetpack-logo{width:170px;margin-bottom:0}.activate-splash .wcs-notice{margin-top:1em;padding-right:57px}.step{text-align:center}.wc-setup .wc-setup-actions .button{font-weight:300;font-size:16px;padding:1em 2em;box-shadow:none;min-width:12em;min-width:auto;margin-top:10px}.wc-setup .wc-setup-actions .button:active,.wc-setup .wc-setup-actions .button:focus,.wc-setup .wc-setup-actions .button:hover{box-shadow:none}.location-prompt{color:#666;font-size:13px;font-weight:500;margin-bottom:.5em;margin-top:.85em;display:inline-block}.location-input{border:1px solid #aaa;border-color:#ddd;border-radius:4px;height:30px;width:calc(100% - 8px - 24px - 2px);padding-right:8px;padding-left:24px;font-size:16px;color:#444;background-color:#fff;display:inline-block}.location-input.dropdown{width:100%}.address-step .select2{min-width:100%}.store-address-container .city-and-postcode{display:-webkit-box;display:-ms-flexbox;display:flex}.store-address-container .city-and-postcode div{-ms-flex-preferred-size:50%;flex-basis:50%;margin-left:1em}.store-address-container .city-and-postcode div:last-of-type{margin-left:0}.store-address-container .select2-container,.store-address-container input[type=text],.store-address-container select{margin-bottom:10px}.product-type-container{margin-top:14px;margin-bottom:1px}#woocommerce_sell_in_person{margin-right:0}.wc-wizard-service-settings .payment-email-input{border:1px solid #aaa;border-color:#ddd;border-radius:4px;height:30px;padding:0 8px;font-size:14px;color:#444;background-color:#fff;display:inline-block}.newsletter-form-container{display:-webkit-box;display:-ms-flexbox;display:flex}.newsletter-form-container .newsletter-form-email{border:1px solid #aaa;border-color:#ddd;border-radius:4px;height:42px;padding:0 8px;font-size:16px;color:#666;background-color:#fff;display:inline-block;margin-left:6px;-webkit-box-flex:1;-ms-flex-positive:1;flex-grow:1}.newsletter-form-container .newsletter-form-button-container{-webkit-box-flex:0;-ms-flex-positive:0;flex-grow:0}.wc-setup .wc-setup-actions .button.newsletter-form-button{height:42px;padding:0 1em;margin:0}.wc-wizard-next-steps{border:1px solid #eee;border-radius:4px;list-style:none;padding:0}.wc-wizard-next-steps li{padding:0}.wc-wizard-next-steps .wc-wizard-next-step-item{display:-webkit-box;display:-ms-flexbox;display:flex;border-top:1px solid #eee}.wc-wizard-next-steps .wc-wizard-next-step-item:first-child{border-top:0}.wc-wizard-next-steps .wc-wizard-next-step-description{-webkit-box-flex:1;-ms-flex-positive:1;flex-grow:1;margin:1.5em}.wc-wizard-next-steps .wc-wizard-next-step-action{-webkit-box-flex:0;-ms-flex-positive:0;flex-grow:0;display:-webkit-box;display:-ms-flexbox;display:flex;-webkit-box-align:center;-ms-flex-align:center;align-items:center}.wc-wizard-next-steps .wc-wizard-next-step-action .button{margin:1em 1.5em}.wc-wizard-next-steps p.next-step-heading{margin:0;font-size:.95em;font-weight:400;font-variant:all-petite-caps}.wc-wizard-next-steps p.next-step-extra-info{margin:0}.wc-wizard-next-steps h3.next-step-description{margin:0;font-size:16px;font-weight:600}.wc-wizard-next-steps .wc-wizard-additional-steps{border-top:1px solid #eee}.wc-wizard-next-steps .wc-wizard-additional-steps .wc-wizard-next-step-description{margin-bottom:0}.wc-wizard-next-steps .wc-wizard-additional-steps .wc-setup-actions{margin:0 0 1.5em 0}.wc-wizard-next-steps .wc-wizard-additional-steps .wc-setup-actions .button{font-size:15px;margin:1em 1.5em 1em 0}.wc-wizard-next-steps .wc-wizard-additional-steps .wc-setup-actions .button::last-child{margin-left:1.5em}p.next-steps-help-text{color:#9f9f9f;padding:0 2em;text-align:center;font-size:.9em}p.jetpack-terms{font-size:.8em;text-align:center;max-width:480px;margin:0 auto;line-height:1.5em}.woocommerce-error{background:#ffe6e5;border-color:#ffc5c2;padding:1em;margin-bottom:1em}.woocommerce-error p{margin-top:0;margin-bottom:.5em;color:#444}.woocommerce-error a{color:#ff645c}.woocommerce-error .reconnect-reminder{font-size:.85em}.woocommerce-error .wc-setup-actions .button{font-size:14px}.wc-wizard-service-setting-ppec_paypal_reroute_requests,.wc-wizard-service-setting-stripe_create_account{display:-webkit-box;display:-ms-flexbox;display:flex;-webkit-box-align:start;-ms-flex-align:start;align-items:flex-start;margin-top:.75em}.wc-wizard-service-setting-ppec_paypal_reroute_requests .payment-checkbox-input,.wc-wizard-service-setting-stripe_create_account .payment-checkbox-input{-webkit-box-ordinal-group:2;-ms-flex-order:1;order:1;margin-top:5px;margin-right:0;margin-left:0;width:1.5em}.wc-wizard-service-setting-ppec_paypal_reroute_requests .ppec_paypal_reroute_requests,.wc-wizard-service-setting-ppec_paypal_reroute_requests .stripe_create_account,.wc-wizard-service-setting-stripe_create_account .ppec_paypal_reroute_requests,.wc-wizard-service-setting-stripe_create_account .stripe_create_account{-webkit-box-ordinal-group:3;-ms-flex-order:2;order:2;margin-right:.3em}.wc-wizard-service-setting-ppec_paypal_email,.wc-wizard-service-setting-stripe_email{margin-top:.75em}.wc-wizard-service-setting-ppec_paypal_email label.ppec_paypal_email,.wc-wizard-service-setting-ppec_paypal_email label.stripe_email,.wc-wizard-service-setting-stripe_email label.ppec_paypal_email,.wc-wizard-service-setting-stripe_email label.stripe_email{position:absolute;margin:-1px;padding:0;height:1px;width:1px;overflow:hidden;clip:rect(0 0 0 0);border:0}.wc-wizard-service-setting-ppec_paypal_email input.payment-email-input,.wc-wizard-service-setting-stripe_email input.payment-email-input{margin-right:1.5em;margin-bottom:.5em;width:100%}.wc-wizard-service-setting-ppec_paypal_email .wc-wizard-service-settings-description,.wc-wizard-service-setting-stripe_email .wc-wizard-service-settings-description{margin-right:1.5em}.recommended-step{border:1px solid #ebebeb;border-radius:4px;padding:2.5em}.recommended-step li{list-style:none}.recommended-step li:last-child .recommended-item{margin-bottom:0}.recommended-step .recommended-item{display:-webkit-box;display:-ms-flexbox;display:flex;-webkit-box-align:center;-ms-flex-align:center;align-items:center;margin-bottom:1.5em}.recommended-step .recommended-item-icon{border:1px solid #fff;border-radius:7px;height:3.5em;margin-left:1em;margin-right:1em}.recommended-step .recommended-item-icon.recommended-item-icon-storefront_theme{background-color:#f4a224;max-height:3em;max-width:3em;padding:.25em}.recommended-step .recommended-item-description-container h3{font-size:15px;font-weight:700;letter-spacing:.5px;margin-bottom:0}.recommended-step .recommended-item-description-container p{margin-top:0;line-height:1.5em} \ No newline at end of file +@charset "UTF-8";body{margin:65px auto 24px;box-shadow:none;background:#f1f1f1;padding:0}#wc-logo{border:0;margin:0 0 24px;padding:0;text-align:center}#wc-logo img{max-width:30%}.wc-setup{text-align:center}.wc-setup .select2-container{text-align:right}.wc-setup .hidden{display:none}.wc-setup-content{box-shadow:0 1px 3px rgba(0,0,0,.13);padding:2em;margin:0 0 20px;background:#fff;overflow:hidden;zoom:1;text-align:right}.wc-setup-content h1,.wc-setup-content h2,.wc-setup-content h3,.wc-setup-content table{margin:0 0 20px;border:0;padding:0;color:#666;clear:none;font-weight:500}.wc-setup-content p{margin:20px 0;font-size:1em;line-height:1.75em;color:#666}.wc-setup-content table{font-size:1em;line-height:1.75em;color:#666}.wc-setup-content a{color:#a16696}.wc-setup-content a:focus,.wc-setup-content a:hover{color:#111}.wc-setup-content .form-table th{width:35%;vertical-align:top;font-weight:400}.wc-setup-content .form-table td{vertical-align:top}.wc-setup-content .form-table td input,.wc-setup-content .form-table td select{width:100%;box-sizing:border-box}.wc-setup-content .form-table td input[size]{width:auto}.wc-setup-content .form-table td .description{line-height:1.5em;display:block;margin-top:.25em;color:#999;font-style:italic}.wc-setup-content .form-table td .input-checkbox,.wc-setup-content .form-table td .input-radio{width:auto;box-sizing:inherit;padding:inherit;margin:0 0 0 .5em;box-shadow:none}.wc-setup-content .form-table .section_title td{padding:0}.wc-setup-content .form-table .section_title td h2,.wc-setup-content .form-table .section_title td p{margin:12px 0 0}.wc-setup-content .form-table td,.wc-setup-content .form-table th{padding:12px 0;margin:0;border:0}.wc-setup-content .form-table td:first-child,.wc-setup-content .form-table th:first-child{padding-left:1em}.wc-setup-content table.tax-rates{width:100%;font-size:.92em}.wc-setup-content table.tax-rates th{padding:0;text-align:center;width:auto;vertical-align:middle}.wc-setup-content table.tax-rates td{border:1px solid #f5f5f5;padding:6px;text-align:center;vertical-align:middle}.wc-setup-content table.tax-rates td input{outline:0;border:0;padding:0;box-shadow:none;text-align:center;width:100%}.wc-setup-content table.tax-rates td.sort{cursor:move;color:#ccc}.wc-setup-content table.tax-rates td.sort::before{content:'\f333';font-family:dashicons}.wc-setup-content table.tax-rates td.readonly{background:#f5f5f5}.wc-setup-content table.tax-rates .add{padding:1em 1em 0 0;line-height:1em;font-size:1em;width:0;margin:6px 0 0;height:0;overflow:hidden;position:relative;display:inline-block}.wc-setup-content table.tax-rates .add::before{content:'\f502';font-family:dashicons;position:absolute;right:0;top:0}.wc-setup-content table.tax-rates .remove{padding:1em 1em 0 0;line-height:1em;font-size:1em;width:0;margin:0;height:0;overflow:hidden;position:relative;display:inline-block}.wc-setup-content table.tax-rates .remove::before{content:'\f182';font-family:dashicons;position:absolute;right:0;top:0}.wc-setup-content .wc-setup-pages{width:100%;border-top:1px solid #eee}.wc-setup-content .wc-setup-pages thead th{display:none}.wc-setup-content .wc-setup-pages .page-name{width:30%;font-weight:700}.wc-setup-content .wc-setup-pages td,.wc-setup-content .wc-setup-pages th{padding:14px 0;border-bottom:1px solid #eee}.wc-setup-content .wc-setup-pages td:first-child,.wc-setup-content .wc-setup-pages th:first-child{padding-left:9px}.wc-setup-content .wc-setup-pages th{padding-top:0}.wc-setup-content .wc-setup-pages .page-options p{color:#777;margin:6px 24px 0 0;line-height:1.75em}.wc-setup-content .wc-setup-pages .page-options p input{vertical-align:middle;margin:1px 0 0;height:1.75em;width:1.75em;line-height:1.75em}.wc-setup-content .wc-setup-pages .page-options p label{line-height:1}@media screen and (max-width:782px){.wc-setup-content .form-table tbody th{width:auto}}.wc-setup-content .twitter-share-button{float:left}.wc-setup-content .wc-setup-next-steps{overflow:hidden;margin:0 0 24px;padding-bottom:2px}.wc-setup-content .wc-setup-next-steps h2{margin-bottom:12px}.wc-setup-content .wc-setup-next-steps .wc-setup-next-steps-first{float:right;width:50%;box-sizing:border-box}.wc-setup-content .wc-setup-next-steps .wc-setup-next-steps-last{float:left;width:50%;box-sizing:border-box}.wc-setup-content .wc-setup-next-steps ul{padding:0 0 0 2em;list-style:none outside;margin:0}.wc-setup-content .wc-setup-next-steps ul li a{display:block;padding:0 0 .75em}.wc-setup-content .wc-setup-next-steps ul .setup-product a.button{background-color:#f7f7f7;border-color:#ccc;color:#23282d;box-shadow:inset 0 1px 0 rgba(255,255,255,.25),0 1px 0 #ccc;text-shadow:-1px 0 1px #eee,0 1px 1px #eee;font-size:1em;height:auto;line-height:1.75em;margin:0 0 .75em;opacity:1;padding:1em;text-align:center}.wc-setup-content .wc-setup-next-steps ul .setup-product a.button:active,.wc-setup-content .wc-setup-next-steps ul .setup-product a.button:focus,.wc-setup-content .wc-setup-next-steps ul .setup-product a.button:hover{background:#f5f5f5;border-color:#aaa}.wc-setup-content .wc-setup-next-steps ul .setup-product a.button-primary{color:#fff;background-color:#bb77ae;border-color:#a36597;box-shadow:inset 0 1px 0 rgba(255,255,255,.25),0 1px 0 #a36597;text-shadow:0 -1px 1px #a36597,-1px 0 1px #a36597,0 1px 1px #a36597,1px 0 1px #a36597}.wc-setup-content .wc-setup-next-steps ul .setup-product a.button-primary:active,.wc-setup-content .wc-setup-next-steps ul .setup-product a.button-primary:focus,.wc-setup-content .wc-setup-next-steps ul .setup-product a.button-primary:hover{color:#fff;background:#a36597;border-color:#a36597;box-shadow:inset 0 1px 0 rgba(255,255,255,.25),0 1px 0 #a36597}.wc-setup-content .wc-setup-next-steps ul li a::before{color:#82878c;font:normal 20px/1 dashicons;speak:none;display:inline-block;padding:0 0 0 10px;top:1px;position:relative;text-decoration:none!important;vertical-align:top}.wc-setup-content .wc-setup-next-steps ul .learn-more a::before{content:'\f105'}.wc-setup-content .wc-setup-next-steps ul .video-walkthrough a::before{content:'\f126'}.wc-setup-content .wc-setup-next-steps ul .newsletter a::before{content:'\f465'}.wc-setup-content .updated,.wc-setup-content .woocommerce-newsletter{padding:24px 24px 0;margin:0 0 24px;overflow:hidden;background:#f5f5f5}.wc-setup-content .updated p,.wc-setup-content .woocommerce-newsletter p{padding:0;margin:0 0 12px}.wc-setup-content .updated form,.wc-setup-content .updated p:last-child,.wc-setup-content .woocommerce-newsletter form,.wc-setup-content .woocommerce-newsletter p:last-child{margin:0 0 24px}.wc-setup-content .woocommerce-tracker{margin:24px 0;border:1px solid #eee;padding:20px;border-radius:4px;overflow:hidden}.wc-setup-content .woocommerce-tracker p{font-size:14px;line-height:1.5em}.wc-setup-content .woocommerce-tracker .checkbox{line-height:24px;font-weight:500;font-size:1em;margin-top:0;margin-bottom:20px}.wc-setup-content .woocommerce-tracker .checkbox input[type=checkbox]{opacity:0;position:absolute;right:-9999px}.wc-setup-content .woocommerce-tracker .checkbox label{position:relative;display:inline-block;padding-right:28px}.wc-setup-content .woocommerce-tracker .checkbox label:after,.wc-setup-content .woocommerce-tracker .checkbox label:before{position:absolute;content:"";display:inline-block}.wc-setup-content .woocommerce-tracker .checkbox label:before{height:16px;width:16px;right:0;top:3px;border:1px solid #aaa;background-color:#fff;border-radius:3px}.wc-setup-content .woocommerce-tracker .checkbox label:after{height:5px;width:9px;border-right:2px solid;border-bottom:2px solid;-webkit-transform:rotate(45deg);-ms-transform:rotate(45deg);transform:rotate(45deg);right:4px;top:7px;color:#fff}.wc-setup-content .woocommerce-tracker .checkbox input[type=checkbox]+label::after{content:none}.wc-setup-content .woocommerce-tracker .checkbox input[type=checkbox]:checked+label::after{content:""}.wc-setup-content .woocommerce-tracker .checkbox input[type=checkbox]:focus+label::before{outline:#3b99fc auto 5px}.wc-setup-content .woocommerce-tracker .checkbox input[type=checkbox]:checked+label::before{background:#935687;border-color:#935687;outline:0}.wc-setup-steps{padding:0 0 24px;margin:0;list-style:none outside;overflow:hidden;color:#ccc;width:100%;display:-webkit-inline-box;display:-ms-inline-flexbox;display:inline-flex}.wc-setup-steps li{width:100%;float:right;padding:0 0 .8em;margin:0;text-align:center;position:relative;border-bottom:4px solid #ccc;line-height:1.4em}.wc-setup-steps li a{color:#a16696;text-decoration:none;padding:1.5em;margin:-1.5em;position:relative;z-index:1}.wc-setup-steps li a:focus,.wc-setup-steps li a:hover{color:#111;text-decoration:underline}.wc-setup-steps li::before{content:'';border:4px solid #ccc;border-radius:100%;width:4px;height:4px;position:absolute;bottom:0;right:50%;margin-right:-6px;margin-bottom:-8px;background:#fff}.wc-setup-steps li.active{border-color:#a16696;color:#a16696;font-weight:700}.wc-setup-steps li.active::before{border-color:#a16696}.wc-setup-steps li.done{border-color:#a16696;color:#a16696}.wc-setup-steps li.done::before{border-color:#a16696;background:#a16696}.wc-setup .wc-setup-actions{overflow:hidden;margin:20px 0 0;position:relative}.wc-setup .wc-setup-actions .button{font-size:1.25em;padding:.5em 1em;line-height:1em;margin-left:.5em;margin-bottom:2px;height:auto;border-radius:4px}.wc-setup .wc-setup-actions .button-primary{background-color:#bb77ae;border-color:#a36597;box-shadow:inset 0 1px 0 rgba(255,255,255,.25),0 1px 0 #a36597;text-shadow:0 -1px 1px #a36597,-1px 0 1px #a36597,0 1px 1px #a36597,1px 0 1px #a36597;margin:0;opacity:1}.wc-setup .wc-setup-actions .button-primary:active,.wc-setup .wc-setup-actions .button-primary:focus,.wc-setup .wc-setup-actions .button-primary:hover{background:#a36597;border-color:#a36597;box-shadow:inset 0 1px 0 rgba(255,255,255,.25),0 1px 0 #a36597}.wc-setup-content p:last-child{margin-bottom:0}.wc-setup-content p.store-setup{margin-top:0}.wc-setup-footer-links{font-size:.85em;color:#b5b5b5;margin:1.18em auto;display:inline-block;text-align:center}.wc-wizard-storefront .wc-wizard-storefront-intro{padding:40px 40px 0;background:#f5f5f5;text-align:center}.wc-wizard-storefront .wc-wizard-storefront-intro img{margin:40px 0 0 0;width:100%;display:block}.wc-wizard-storefront .wc-wizard-storefront-features{list-style:none outside;margin:0 0 20px;padding:0 30px 0 0;overflow:hidden}.wc-wizard-storefront .wc-wizard-storefront-feature{margin:0;padding:20px 2em 20px 30px;width:50%;box-sizing:border-box}.wc-wizard-storefront .wc-wizard-storefront-feature::before{margin-right:-2em;position:absolute}.wc-wizard-storefront .wc-wizard-storefront-feature.first{clear:both;float:right}.wc-wizard-storefront .wc-wizard-storefront-feature.last{float:left}.wc-wizard-storefront .wc-wizard-storefront-feature__bulletproof::before{content:'πŸ”’'}.wc-wizard-storefront .wc-wizard-storefront-feature__mobile::before{content:'πŸ“±'}.wc-wizard-storefront .wc-wizard-storefront-feature__accessibility::before{content:'πŸ‘“'}.wc-wizard-storefront .wc-wizard-storefront-feature__search::before{content:'πŸ”'}.wc-wizard-storefront .wc-wizard-storefront-feature__compatibility::before{content:'πŸ”§'}.wc-wizard-storefront .wc-wizard-storefront-feature__extendable::before{content:'🎨'}.wc-wizard-services{border:1px solid #eee;padding:0;margin:0 0 1em;list-style:none outside;border-radius:4px;overflow:hidden}.wc-wizard-services p{margin:0 0 1em 0;padding:0;font-size:1em;line-height:1.5em}.wc-wizard-service-item,.wc-wizard-services-list-toggle{display:-webkit-box;display:-ms-flexbox;display:flex;-ms-flex-wrap:nowrap;flex-wrap:nowrap;-webkit-box-pack:justify;-ms-flex-pack:justify;justify-content:space-between;padding:0;border-bottom:1px solid #eee;color:#666;-webkit-box-align:center;-ms-flex-align:center;align-items:center}.wc-wizard-service-item:last-child,.wc-wizard-services-list-toggle:last-child{border-bottom:0}.wc-wizard-service-item .payment-gateway-fee,.wc-wizard-services-list-toggle .payment-gateway-fee{color:#a6a6a6}.wc-wizard-service-item .wc-wizard-service-name,.wc-wizard-services-list-toggle .wc-wizard-service-name{-ms-flex-preferred-size:0;flex-basis:0;min-width:160px;text-align:center;font-weight:700;padding:2em 0;-ms-flex-item-align:stretch;align-self:stretch;display:-webkit-box;display:-ms-flexbox;display:flex;-webkit-box-align:baseline;-ms-flex-align:baseline;align-items:baseline}.wc-wizard-payment-gateway-form .wc-wizard-service-item .wc-wizard-service-name,.wc-wizard-payment-gateway-form .wc-wizard-services-list-toggle .wc-wizard-service-name{-webkit-box-pack:center;-ms-flex-pack:center;justify-content:center}.wc-wizard-service-item .wc-wizard-service-name img,.wc-wizard-services-list-toggle .wc-wizard-service-name img{max-width:75px}.wc-wizard-service-item.stripe-logo .wc-wizard-service-name img,.wc-wizard-services-list-toggle.stripe-logo .wc-wizard-service-name img{padding:8px 0}.wc-wizard-service-item.paypal-logo .wc-wizard-service-name img,.wc-wizard-services-list-toggle.paypal-logo .wc-wizard-service-name img{max-width:87px;padding:2px 0}.wc-wizard-service-item.klarna-logo .wc-wizard-service-name,.wc-wizard-services-list-toggle.klarna-logo .wc-wizard-service-name{background:#000}.wc-wizard-service-item.klarna-logo .wc-wizard-service-name img,.wc-wizard-services-list-toggle.klarna-logo .wc-wizard-service-name img{max-width:87px;padding:12px 0}.wc-wizard-service-item.square-logo .wc-wizard-service-name,.wc-wizard-services-list-toggle.square-logo .wc-wizard-service-name{background:#000}.wc-wizard-service-item.square-logo .wc-wizard-service-name img,.wc-wizard-services-list-toggle.square-logo .wc-wizard-service-name img{max-width:95px;padding:12px 0}.wc-wizard-service-item .wc-wizard-service-description,.wc-wizard-services-list-toggle .wc-wizard-service-description{-webkit-box-flex:1;-ms-flex-positive:1;flex-grow:1;padding:20px}.wc-wizard-service-item .wc-wizard-service-description p,.wc-wizard-services-list-toggle .wc-wizard-service-description p{margin-bottom:1em}.wc-wizard-service-item .wc-wizard-service-description p:last-child,.wc-wizard-services-list-toggle .wc-wizard-service-description p:last-child{margin-bottom:0}.wc-wizard-service-item .wc-wizard-service-description .wc-wizard-service-settings-description,.wc-wizard-services-list-toggle .wc-wizard-service-description .wc-wizard-service-settings-description{display:block;font-style:italic;color:#999}.wc-wizard-service-item .wc-wizard-service-enable,.wc-wizard-services-list-toggle .wc-wizard-service-enable{-ms-flex-preferred-size:0;flex-basis:0;min-width:75px;text-align:center;cursor:pointer;padding:2em 0;position:relative;max-height:1.5em;-ms-flex-item-align:start;align-self:flex-start}.wc-wizard-service-item .wc-wizard-service-toggle,.wc-wizard-services-list-toggle .wc-wizard-service-toggle{height:16px;width:32px;border:2px solid #935687;background-color:#935687;display:inline-block;text-indent:-9999px;border-radius:10em;position:relative}.wc-wizard-service-item .wc-wizard-service-toggle input[type=checkbox],.wc-wizard-services-list-toggle .wc-wizard-service-toggle input[type=checkbox]{display:none}.wc-wizard-service-item .wc-wizard-service-toggle:before,.wc-wizard-services-list-toggle .wc-wizard-service-toggle:before{content:"";display:block;width:16px;height:16px;background:#fff;position:absolute;top:0;left:0;border-radius:100%}.wc-wizard-service-item .wc-wizard-service-toggle.disabled,.wc-wizard-services-list-toggle .wc-wizard-service-toggle.disabled{border-color:#999;background-color:#999}.wc-wizard-service-item .wc-wizard-service-toggle.disabled:before,.wc-wizard-services-list-toggle .wc-wizard-service-toggle.disabled:before{left:auto;right:0}.wc-wizard-service-item .wc-wizard-service-settings,.wc-wizard-services-list-toggle .wc-wizard-service-settings{display:none;margin-bottom:0;cursor:default}.wc-wizard-service-item .wc-wizard-service-settings.hide,.wc-wizard-services-list-toggle .wc-wizard-service-settings.hide{display:none}.wc-wizard-service-item.checked .wc-wizard-service-settings,.wc-wizard-services-list-toggle.checked .wc-wizard-service-settings{display:inline-block}.wc-wizard-service-item.checked .wc-wizard-service-settings.hide,.wc-wizard-services-list-toggle.checked .wc-wizard-service-settings.hide{display:none}.wc-wizard-service-item.closed,.wc-wizard-services-list-toggle.closed{border-bottom:0}.wc-wizard-services-list-toggle{cursor:pointer}.wc-wizard-services-list-toggle .wc-wizard-service-enable::before{content:"\f343";font-family:dashicons;visibility:initial;color:#666;font-size:25px;margin-top:-7px;margin-right:-5px;position:absolute;visibility:visible}.wc-wizard-services-list-toggle.closed .wc-wizard-service-enable::before{content:"\f347"}.wc-wizard-services-list-toggle .wc-wizard-service-enable input{visibility:hidden;position:relative}.wc-wizard-services.manual .wc-wizard-service-item{display:none}.wc-wizard-services.shipping .wc-wizard-service-name{font-weight:400;text-align:right;-webkit-box-align:center;-ms-flex-align:center;align-items:center;max-height:5em;padding:0}.wc-wizard-services.shipping .wc-wizard-service-item{padding-right:2em;padding-top:.67em}.wc-wizard-services.shipping .wc-wizard-service-item:first-child{border-bottom:0;padding-bottom:0;font-weight:700}.wc-wizard-services.shipping .wc-wizard-service-item:first-child .wc-wizard-service-name{font-weight:700}.wc-wizard-services.shipping .shipping-method-setting,.wc-wizard-services.shipping .wc-wizard-shipping-method-select{display:-webkit-box;display:-ms-flexbox;display:flex}.wc-wizard-services.shipping .shipping-method-setting.hide,.wc-wizard-services.shipping .wc-wizard-shipping-method-select.hide{display:none}.wc-wizard-services.shipping .shipping-method-setting input,.wc-wizard-services.shipping .wc-wizard-shipping-method-dropdown{margin-left:2em;margin-bottom:1em}.wc-wizard-services.shipping .shipping-method-setting input .select2,.wc-wizard-services.shipping .wc-wizard-shipping-method-dropdown .select2{min-width:130px}.wc-wizard-services.shipping .wc-wizard-service-description{display:-webkit-box;display:-ms-flexbox;display:flex;-webkit-box-orient:vertical;-webkit-box-direction:normal;-ms-flex-direction:column;flex-direction:column;color:#a6a6a6}.wc-wizard-services.shipping .wc-wizard-service-item:not(:first-child) .wc-wizard-service-description{font-size:.92em;padding-bottom:10px}.wc-wizard-services.shipping .shipping-method-setting input{width:95px;border:1px solid #aaa;border-color:#ddd;border-radius:4px;height:28px;padding-right:8px;padding-left:24px;font-size:14px;color:#444;background-color:#fff;display:inline-block}.wc-wizard-services.shipping .shipping-method-description,.wc-wizard-services.shipping .shipping-method-setting .description{color:#7e7e7e;font-size:.9em}.wc-wizard-services.shipping .shipping-method-setting input::-webkit-input-placeholder{color:#e1e1e1}.wc-wizard-services.shipping .shipping-method-setting input::-moz-placeholder{color:#e1e1e1}.wc-wizard-services.shipping .shipping-method-setting input:-ms-input-placeholder{color:#e1e1e1}.wc-wizard-services.shipping .shipping-method-setting input::placeholder{color:#e1e1e1}.wc-setup-shipping-units p{line-height:1.5em;font-size:13px;margin-bottom:.25em}.wc-setup-shipping-units .wc-setup-shipping-unit{margin-bottom:1.75em}.wc-setup-shipping-units .wc-setup-shipping-unit .select2{min-width:100%}.hide{display:none}.wc-wizard-features{display:-webkit-box;display:-ms-flexbox;display:flex;-ms-flex-wrap:wrap;flex-wrap:wrap;list-style:none;padding:0}.wc-wizard-features .wc-wizard-feature-item{-ms-flex-preferred-size:calc(50% - 4em - 3px);flex-basis:calc(50% - 4em - 3px);border:1px solid #eee;padding:2em}.wc-wizard-features .wc-wizard-feature-item:nth-child(1){border-radius:0 4px 0 0}.wc-wizard-features .wc-wizard-feature-item:nth-child(2){border-right:0;border-radius:4px 0 0 0}.wc-wizard-features .wc-wizard-feature-item:nth-child(3){border-top:0;border-radius:0 0 4px 0}.wc-wizard-features .wc-wizard-feature-item:nth-child(4){border-top:0;border-right:0;border-radius:0 0 0 4px}.wc-wizard-features p.wc-wizard-feature-description,.wc-wizard-features p.wc-wizard-feature-name{margin:0;line-height:1.5em}h3.jetpack-reasons{text-align:center;margin:3em 0 1em 0;font-size:14px}.jetpack-logo,.wcs-notice{display:block;margin:1.75em auto 2em auto;max-height:175px}.activate-splash .jetpack-logo{width:170px;margin-bottom:0}.activate-splash .wcs-notice{margin-top:1em;padding-right:57px}.step{text-align:center}.wc-setup .wc-setup-actions .button{font-weight:300;font-size:16px;padding:1em 2em;box-shadow:none;min-width:12em;min-width:auto;margin-top:10px}.wc-setup .wc-setup-actions .button:active,.wc-setup .wc-setup-actions .button:focus,.wc-setup .wc-setup-actions .button:hover{box-shadow:none}.location-prompt{color:#666;font-size:13px;font-weight:500;margin-bottom:.5em;margin-top:.85em;display:inline-block}.location-input{border:1px solid #aaa;border-color:#ddd;border-radius:4px;height:30px;width:calc(100% - 8px - 24px - 2px);padding-right:8px;padding-left:24px;font-size:16px;color:#444;background-color:#fff;display:inline-block}.location-input.dropdown{width:100%}.address-step .select2{min-width:100%}.store-address-container .city-and-postcode{display:-webkit-box;display:-ms-flexbox;display:flex}.store-address-container .city-and-postcode div{-ms-flex-preferred-size:50%;flex-basis:50%;margin-left:1em}.store-address-container .city-and-postcode div:last-of-type{margin-left:0}.store-address-container .select2-container,.store-address-container input[type=text],.store-address-container select{margin-bottom:10px}.product-type-container{margin-top:14px;margin-bottom:1px}#woocommerce_sell_in_person{margin-right:0}.wc-wizard-service-settings .payment-email-input{border:1px solid #aaa;border-color:#ddd;border-radius:4px;height:30px;padding:0 8px;font-size:14px;color:#444;background-color:#fff;display:inline-block}.newsletter-form-container{display:-webkit-box;display:-ms-flexbox;display:flex}.newsletter-form-container .newsletter-form-email{border:1px solid #aaa;border-color:#ddd;border-radius:4px;height:42px;padding:0 8px;font-size:16px;color:#666;background-color:#fff;display:inline-block;margin-left:6px;-webkit-box-flex:1;-ms-flex-positive:1;flex-grow:1}.newsletter-form-container .newsletter-form-button-container{-webkit-box-flex:0;-ms-flex-positive:0;flex-grow:0}.wc-setup .wc-setup-actions .button.newsletter-form-button{height:42px;padding:0 1em;margin:0}.wc-wizard-next-steps{border:1px solid #eee;border-radius:4px;list-style:none;padding:0}.wc-wizard-next-steps li{padding:0}.wc-wizard-next-steps .wc-wizard-next-step-item{display:-webkit-box;display:-ms-flexbox;display:flex;border-top:1px solid #eee}.wc-wizard-next-steps .wc-wizard-next-step-item:first-child{border-top:0}.wc-wizard-next-steps .wc-wizard-next-step-description{-webkit-box-flex:1;-ms-flex-positive:1;flex-grow:1;margin:1.5em}.wc-wizard-next-steps .wc-wizard-next-step-action{-webkit-box-flex:0;-ms-flex-positive:0;flex-grow:0;display:-webkit-box;display:-ms-flexbox;display:flex;-webkit-box-align:center;-ms-flex-align:center;align-items:center}.wc-wizard-next-steps .wc-wizard-next-step-action .button{margin:1em 1.5em}.wc-wizard-next-steps p.next-step-heading{margin:0;font-size:.95em;font-weight:400;font-variant:all-petite-caps}.wc-wizard-next-steps p.next-step-extra-info{margin:0}.wc-wizard-next-steps h3.next-step-description{margin:0;font-size:16px;font-weight:600}.wc-wizard-next-steps .wc-wizard-additional-steps{border-top:1px solid #eee}.wc-wizard-next-steps .wc-wizard-additional-steps .wc-wizard-next-step-description{margin-bottom:0}.wc-wizard-next-steps .wc-wizard-additional-steps .wc-setup-actions{margin:0 0 1.5em 0}.wc-wizard-next-steps .wc-wizard-additional-steps .wc-setup-actions .button{font-size:15px;margin:1em 1.5em 1em 0}.wc-wizard-next-steps .wc-wizard-additional-steps .wc-setup-actions .button::last-child{margin-left:1.5em}p.next-steps-help-text{color:#9f9f9f;padding:0 2em;text-align:center;font-size:.9em}p.jetpack-terms{font-size:.8em;text-align:center;max-width:480px;margin:0 auto;line-height:1.5em}.woocommerce-error{background:#ffe6e5;border-color:#ffc5c2;padding:1em;margin-bottom:1em}.woocommerce-error p{margin-top:0;margin-bottom:.5em;color:#444}.woocommerce-error a{color:#ff645c}.woocommerce-error .reconnect-reminder{font-size:.85em}.woocommerce-error .wc-setup-actions .button{font-size:14px}.wc-wizard-service-setting-ppec_paypal_reroute_requests,.wc-wizard-service-setting-stripe_create_account{display:-webkit-box;display:-ms-flexbox;display:flex;-webkit-box-align:start;-ms-flex-align:start;align-items:flex-start;margin-top:.75em}.wc-wizard-service-setting-ppec_paypal_reroute_requests .payment-checkbox-input,.wc-wizard-service-setting-stripe_create_account .payment-checkbox-input{-webkit-box-ordinal-group:2;-ms-flex-order:1;order:1;margin-top:5px;margin-right:0;margin-left:0;width:1.5em}.wc-wizard-service-setting-ppec_paypal_reroute_requests .ppec_paypal_reroute_requests,.wc-wizard-service-setting-ppec_paypal_reroute_requests .stripe_create_account,.wc-wizard-service-setting-stripe_create_account .ppec_paypal_reroute_requests,.wc-wizard-service-setting-stripe_create_account .stripe_create_account{-webkit-box-ordinal-group:3;-ms-flex-order:2;order:2;margin-right:.3em}.wc-wizard-service-setting-ppec_paypal_email,.wc-wizard-service-setting-stripe_email{margin-top:.75em}.wc-wizard-service-setting-ppec_paypal_email label.ppec_paypal_email,.wc-wizard-service-setting-ppec_paypal_email label.stripe_email,.wc-wizard-service-setting-stripe_email label.ppec_paypal_email,.wc-wizard-service-setting-stripe_email label.stripe_email{position:absolute;margin:-1px;padding:0;height:1px;width:1px;overflow:hidden;clip:rect(0 0 0 0);border:0}.wc-wizard-service-setting-ppec_paypal_email input.payment-email-input,.wc-wizard-service-setting-stripe_email input.payment-email-input{margin-right:1.5em;margin-bottom:.5em;width:100%}.wc-wizard-service-setting-ppec_paypal_email .wc-wizard-service-settings-description,.wc-wizard-service-setting-stripe_email .wc-wizard-service-settings-description{margin-right:1.5em}.recommended-step{border:1px solid #ebebeb;border-radius:4px;padding:2.5em}.recommended-step li{list-style:none}.recommended-step li:last-child .recommended-item{margin-bottom:0}.recommended-step .recommended-item{display:-webkit-box;display:-ms-flexbox;display:flex;-webkit-box-align:center;-ms-flex-align:center;align-items:center;margin-bottom:1.5em}.recommended-step .recommended-item-icon{border:1px solid #fff;border-radius:7px;height:3.5em;margin-left:1em;margin-right:1em}.recommended-step .recommended-item-icon.recommended-item-icon-storefront_theme{background-color:#f4a224;max-height:3em;max-width:3em;padding:.25em}.recommended-step .recommended-item-icon.recommended-item-icon-automated_taxes{background-color:#d0011b;max-height:1.75em;padding:.875em}.recommended-step .recommended-item-description-container h3{font-size:15px;font-weight:700;letter-spacing:.5px;margin-bottom:0}.recommended-step .recommended-item-description-container p{margin-top:0;line-height:1.5em} \ No newline at end of file diff --git a/assets/css/wc-setup.css b/assets/css/wc-setup.css index eeb29e749b7..e2d77ec9da3 100644 --- a/assets/css/wc-setup.css +++ b/assets/css/wc-setup.css @@ -1 +1 @@ -@charset "UTF-8";body{margin:65px auto 24px;box-shadow:none;background:#f1f1f1;padding:0}#wc-logo{border:0;margin:0 0 24px;padding:0;text-align:center}#wc-logo img{max-width:30%}.wc-setup{text-align:center}.wc-setup .select2-container{text-align:left}.wc-setup .hidden{display:none}.wc-setup-content{box-shadow:0 1px 3px rgba(0,0,0,.13);padding:2em;margin:0 0 20px;background:#fff;overflow:hidden;zoom:1;text-align:left}.wc-setup-content h1,.wc-setup-content h2,.wc-setup-content h3,.wc-setup-content table{margin:0 0 20px;border:0;padding:0;color:#666;clear:none;font-weight:500}.wc-setup-content p{margin:20px 0;font-size:1em;line-height:1.75em;color:#666}.wc-setup-content table{font-size:1em;line-height:1.75em;color:#666}.wc-setup-content a{color:#a16696}.wc-setup-content a:focus,.wc-setup-content a:hover{color:#111}.wc-setup-content .form-table th{width:35%;vertical-align:top;font-weight:400}.wc-setup-content .form-table td{vertical-align:top}.wc-setup-content .form-table td input,.wc-setup-content .form-table td select{width:100%;box-sizing:border-box}.wc-setup-content .form-table td input[size]{width:auto}.wc-setup-content .form-table td .description{line-height:1.5em;display:block;margin-top:.25em;color:#999;font-style:italic}.wc-setup-content .form-table td .input-checkbox,.wc-setup-content .form-table td .input-radio{width:auto;box-sizing:inherit;padding:inherit;margin:0 .5em 0 0;box-shadow:none}.wc-setup-content .form-table .section_title td{padding:0}.wc-setup-content .form-table .section_title td h2,.wc-setup-content .form-table .section_title td p{margin:12px 0 0}.wc-setup-content .form-table td,.wc-setup-content .form-table th{padding:12px 0;margin:0;border:0}.wc-setup-content .form-table td:first-child,.wc-setup-content .form-table th:first-child{padding-right:1em}.wc-setup-content table.tax-rates{width:100%;font-size:.92em}.wc-setup-content table.tax-rates th{padding:0;text-align:center;width:auto;vertical-align:middle}.wc-setup-content table.tax-rates td{border:1px solid #f5f5f5;padding:6px;text-align:center;vertical-align:middle}.wc-setup-content table.tax-rates td input{outline:0;border:0;padding:0;box-shadow:none;text-align:center;width:100%}.wc-setup-content table.tax-rates td.sort{cursor:move;color:#ccc}.wc-setup-content table.tax-rates td.sort::before{content:'\f333';font-family:dashicons}.wc-setup-content table.tax-rates td.readonly{background:#f5f5f5}.wc-setup-content table.tax-rates .add{padding:1em 0 0 1em;line-height:1em;font-size:1em;width:0;margin:6px 0 0;height:0;overflow:hidden;position:relative;display:inline-block}.wc-setup-content table.tax-rates .add::before{content:'\f502';font-family:dashicons;position:absolute;left:0;top:0}.wc-setup-content table.tax-rates .remove{padding:1em 0 0 1em;line-height:1em;font-size:1em;width:0;margin:0;height:0;overflow:hidden;position:relative;display:inline-block}.wc-setup-content table.tax-rates .remove::before{content:'\f182';font-family:dashicons;position:absolute;left:0;top:0}.wc-setup-content .wc-setup-pages{width:100%;border-top:1px solid #eee}.wc-setup-content .wc-setup-pages thead th{display:none}.wc-setup-content .wc-setup-pages .page-name{width:30%;font-weight:700}.wc-setup-content .wc-setup-pages td,.wc-setup-content .wc-setup-pages th{padding:14px 0;border-bottom:1px solid #eee}.wc-setup-content .wc-setup-pages td:first-child,.wc-setup-content .wc-setup-pages th:first-child{padding-right:9px}.wc-setup-content .wc-setup-pages th{padding-top:0}.wc-setup-content .wc-setup-pages .page-options p{color:#777;margin:6px 0 0 24px;line-height:1.75em}.wc-setup-content .wc-setup-pages .page-options p input{vertical-align:middle;margin:1px 0 0;height:1.75em;width:1.75em;line-height:1.75em}.wc-setup-content .wc-setup-pages .page-options p label{line-height:1}@media screen and (max-width:782px){.wc-setup-content .form-table tbody th{width:auto}}.wc-setup-content .twitter-share-button{float:right}.wc-setup-content .wc-setup-next-steps{overflow:hidden;margin:0 0 24px;padding-bottom:2px}.wc-setup-content .wc-setup-next-steps h2{margin-bottom:12px}.wc-setup-content .wc-setup-next-steps .wc-setup-next-steps-first{float:left;width:50%;box-sizing:border-box}.wc-setup-content .wc-setup-next-steps .wc-setup-next-steps-last{float:right;width:50%;box-sizing:border-box}.wc-setup-content .wc-setup-next-steps ul{padding:0 2em 0 0;list-style:none outside;margin:0}.wc-setup-content .wc-setup-next-steps ul li a{display:block;padding:0 0 .75em}.wc-setup-content .wc-setup-next-steps ul .setup-product a.button{background-color:#f7f7f7;border-color:#ccc;color:#23282d;box-shadow:inset 0 1px 0 rgba(255,255,255,.25),0 1px 0 #ccc;text-shadow:1px 0 1px #eee,0 1px 1px #eee;font-size:1em;height:auto;line-height:1.75em;margin:0 0 .75em;opacity:1;padding:1em;text-align:center}.wc-setup-content .wc-setup-next-steps ul .setup-product a.button:active,.wc-setup-content .wc-setup-next-steps ul .setup-product a.button:focus,.wc-setup-content .wc-setup-next-steps ul .setup-product a.button:hover{background:#f5f5f5;border-color:#aaa}.wc-setup-content .wc-setup-next-steps ul .setup-product a.button-primary{color:#fff;background-color:#bb77ae;border-color:#a36597;box-shadow:inset 0 1px 0 rgba(255,255,255,.25),0 1px 0 #a36597;text-shadow:0 -1px 1px #a36597,1px 0 1px #a36597,0 1px 1px #a36597,-1px 0 1px #a36597}.wc-setup-content .wc-setup-next-steps ul .setup-product a.button-primary:active,.wc-setup-content .wc-setup-next-steps ul .setup-product a.button-primary:focus,.wc-setup-content .wc-setup-next-steps ul .setup-product a.button-primary:hover{color:#fff;background:#a36597;border-color:#a36597;box-shadow:inset 0 1px 0 rgba(255,255,255,.25),0 1px 0 #a36597}.wc-setup-content .wc-setup-next-steps ul li a::before{color:#82878c;font:normal 20px/1 dashicons;speak:none;display:inline-block;padding:0 10px 0 0;top:1px;position:relative;text-decoration:none!important;vertical-align:top}.wc-setup-content .wc-setup-next-steps ul .learn-more a::before{content:'\f105'}.wc-setup-content .wc-setup-next-steps ul .video-walkthrough a::before{content:'\f126'}.wc-setup-content .wc-setup-next-steps ul .newsletter a::before{content:'\f465'}.wc-setup-content .updated,.wc-setup-content .woocommerce-newsletter{padding:24px 24px 0;margin:0 0 24px;overflow:hidden;background:#f5f5f5}.wc-setup-content .updated p,.wc-setup-content .woocommerce-newsletter p{padding:0;margin:0 0 12px}.wc-setup-content .updated form,.wc-setup-content .updated p:last-child,.wc-setup-content .woocommerce-newsletter form,.wc-setup-content .woocommerce-newsletter p:last-child{margin:0 0 24px}.wc-setup-content .woocommerce-tracker{margin:24px 0;border:1px solid #eee;padding:20px;border-radius:4px;overflow:hidden}.wc-setup-content .woocommerce-tracker p{font-size:14px;line-height:1.5em}.wc-setup-content .woocommerce-tracker .checkbox{line-height:24px;font-weight:500;font-size:1em;margin-top:0;margin-bottom:20px}.wc-setup-content .woocommerce-tracker .checkbox input[type=checkbox]{opacity:0;position:absolute;left:-9999px}.wc-setup-content .woocommerce-tracker .checkbox label{position:relative;display:inline-block;padding-left:28px}.wc-setup-content .woocommerce-tracker .checkbox label:after,.wc-setup-content .woocommerce-tracker .checkbox label:before{position:absolute;content:"";display:inline-block}.wc-setup-content .woocommerce-tracker .checkbox label:before{height:16px;width:16px;left:0;top:3px;border:1px solid #aaa;background-color:#fff;border-radius:3px}.wc-setup-content .woocommerce-tracker .checkbox label:after{height:5px;width:9px;border-left:2px solid;border-bottom:2px solid;-webkit-transform:rotate(-45deg);-ms-transform:rotate(-45deg);transform:rotate(-45deg);left:4px;top:7px;color:#fff}.wc-setup-content .woocommerce-tracker .checkbox input[type=checkbox]+label::after{content:none}.wc-setup-content .woocommerce-tracker .checkbox input[type=checkbox]:checked+label::after{content:""}.wc-setup-content .woocommerce-tracker .checkbox input[type=checkbox]:focus+label::before{outline:#3b99fc auto 5px}.wc-setup-content .woocommerce-tracker .checkbox input[type=checkbox]:checked+label::before{background:#935687;border-color:#935687;outline:0}.wc-setup-steps{padding:0 0 24px;margin:0;list-style:none outside;overflow:hidden;color:#ccc;width:100%;display:-webkit-inline-box;display:-ms-inline-flexbox;display:inline-flex}.wc-setup-steps li{width:100%;float:left;padding:0 0 .8em;margin:0;text-align:center;position:relative;border-bottom:4px solid #ccc;line-height:1.4em}.wc-setup-steps li a{color:#a16696;text-decoration:none;padding:1.5em;margin:-1.5em;position:relative;z-index:1}.wc-setup-steps li a:focus,.wc-setup-steps li a:hover{color:#111;text-decoration:underline}.wc-setup-steps li::before{content:'';border:4px solid #ccc;border-radius:100%;width:4px;height:4px;position:absolute;bottom:0;left:50%;margin-left:-6px;margin-bottom:-8px;background:#fff}.wc-setup-steps li.active{border-color:#a16696;color:#a16696;font-weight:700}.wc-setup-steps li.active::before{border-color:#a16696}.wc-setup-steps li.done{border-color:#a16696;color:#a16696}.wc-setup-steps li.done::before{border-color:#a16696;background:#a16696}.wc-setup .wc-setup-actions{overflow:hidden;margin:20px 0 0;position:relative}.wc-setup .wc-setup-actions .button{font-size:1.25em;padding:.5em 1em;line-height:1em;margin-right:.5em;margin-bottom:2px;height:auto;border-radius:4px}.wc-setup .wc-setup-actions .button-primary{background-color:#bb77ae;border-color:#a36597;box-shadow:inset 0 1px 0 rgba(255,255,255,.25),0 1px 0 #a36597;text-shadow:0 -1px 1px #a36597,1px 0 1px #a36597,0 1px 1px #a36597,-1px 0 1px #a36597;margin:0;opacity:1}.wc-setup .wc-setup-actions .button-primary:active,.wc-setup .wc-setup-actions .button-primary:focus,.wc-setup .wc-setup-actions .button-primary:hover{background:#a36597;border-color:#a36597;box-shadow:inset 0 1px 0 rgba(255,255,255,.25),0 1px 0 #a36597}.wc-setup-content p:last-child{margin-bottom:0}.wc-setup-content p.store-setup{margin-top:0}.wc-setup-footer-links{font-size:.85em;color:#b5b5b5;margin:1.18em auto;display:inline-block;text-align:center}.wc-wizard-storefront .wc-wizard-storefront-intro{padding:40px 40px 0;background:#f5f5f5;text-align:center}.wc-wizard-storefront .wc-wizard-storefront-intro img{margin:40px 0 0 0;width:100%;display:block}.wc-wizard-storefront .wc-wizard-storefront-features{list-style:none outside;margin:0 0 20px;padding:0 0 0 30px;overflow:hidden}.wc-wizard-storefront .wc-wizard-storefront-feature{margin:0;padding:20px 30px 20px 2em;width:50%;box-sizing:border-box}.wc-wizard-storefront .wc-wizard-storefront-feature::before{margin-left:-2em;position:absolute}.wc-wizard-storefront .wc-wizard-storefront-feature.first{clear:both;float:left}.wc-wizard-storefront .wc-wizard-storefront-feature.last{float:right}.wc-wizard-storefront .wc-wizard-storefront-feature__bulletproof::before{content:'πŸ”’'}.wc-wizard-storefront .wc-wizard-storefront-feature__mobile::before{content:'πŸ“±'}.wc-wizard-storefront .wc-wizard-storefront-feature__accessibility::before{content:'πŸ‘“'}.wc-wizard-storefront .wc-wizard-storefront-feature__search::before{content:'πŸ”'}.wc-wizard-storefront .wc-wizard-storefront-feature__compatibility::before{content:'πŸ”§'}.wc-wizard-storefront .wc-wizard-storefront-feature__extendable::before{content:'🎨'}.wc-wizard-services{border:1px solid #eee;padding:0;margin:0 0 1em;list-style:none outside;border-radius:4px;overflow:hidden}.wc-wizard-services p{margin:0 0 1em 0;padding:0;font-size:1em;line-height:1.5em}.wc-wizard-service-item,.wc-wizard-services-list-toggle{display:-webkit-box;display:-ms-flexbox;display:flex;-ms-flex-wrap:nowrap;flex-wrap:nowrap;-webkit-box-pack:justify;-ms-flex-pack:justify;justify-content:space-between;padding:0;border-bottom:1px solid #eee;color:#666;-webkit-box-align:center;-ms-flex-align:center;align-items:center}.wc-wizard-service-item:last-child,.wc-wizard-services-list-toggle:last-child{border-bottom:0}.wc-wizard-service-item .payment-gateway-fee,.wc-wizard-services-list-toggle .payment-gateway-fee{color:#a6a6a6}.wc-wizard-service-item .wc-wizard-service-name,.wc-wizard-services-list-toggle .wc-wizard-service-name{-ms-flex-preferred-size:0;flex-basis:0;min-width:160px;text-align:center;font-weight:700;padding:2em 0;-ms-flex-item-align:stretch;align-self:stretch;display:-webkit-box;display:-ms-flexbox;display:flex;-webkit-box-align:baseline;-ms-flex-align:baseline;align-items:baseline}.wc-wizard-payment-gateway-form .wc-wizard-service-item .wc-wizard-service-name,.wc-wizard-payment-gateway-form .wc-wizard-services-list-toggle .wc-wizard-service-name{-webkit-box-pack:center;-ms-flex-pack:center;justify-content:center}.wc-wizard-service-item .wc-wizard-service-name img,.wc-wizard-services-list-toggle .wc-wizard-service-name img{max-width:75px}.wc-wizard-service-item.stripe-logo .wc-wizard-service-name img,.wc-wizard-services-list-toggle.stripe-logo .wc-wizard-service-name img{padding:8px 0}.wc-wizard-service-item.paypal-logo .wc-wizard-service-name img,.wc-wizard-services-list-toggle.paypal-logo .wc-wizard-service-name img{max-width:87px;padding:2px 0}.wc-wizard-service-item.klarna-logo .wc-wizard-service-name,.wc-wizard-services-list-toggle.klarna-logo .wc-wizard-service-name{background:#000}.wc-wizard-service-item.klarna-logo .wc-wizard-service-name img,.wc-wizard-services-list-toggle.klarna-logo .wc-wizard-service-name img{max-width:87px;padding:12px 0}.wc-wizard-service-item.square-logo .wc-wizard-service-name,.wc-wizard-services-list-toggle.square-logo .wc-wizard-service-name{background:#000}.wc-wizard-service-item.square-logo .wc-wizard-service-name img,.wc-wizard-services-list-toggle.square-logo .wc-wizard-service-name img{max-width:95px;padding:12px 0}.wc-wizard-service-item .wc-wizard-service-description,.wc-wizard-services-list-toggle .wc-wizard-service-description{-webkit-box-flex:1;-ms-flex-positive:1;flex-grow:1;padding:20px}.wc-wizard-service-item .wc-wizard-service-description p,.wc-wizard-services-list-toggle .wc-wizard-service-description p{margin-bottom:1em}.wc-wizard-service-item .wc-wizard-service-description p:last-child,.wc-wizard-services-list-toggle .wc-wizard-service-description p:last-child{margin-bottom:0}.wc-wizard-service-item .wc-wizard-service-description .wc-wizard-service-settings-description,.wc-wizard-services-list-toggle .wc-wizard-service-description .wc-wizard-service-settings-description{display:block;font-style:italic;color:#999}.wc-wizard-service-item .wc-wizard-service-enable,.wc-wizard-services-list-toggle .wc-wizard-service-enable{-ms-flex-preferred-size:0;flex-basis:0;min-width:75px;text-align:center;cursor:pointer;padding:2em 0;position:relative;max-height:1.5em;-ms-flex-item-align:start;align-self:flex-start}.wc-wizard-service-item .wc-wizard-service-toggle,.wc-wizard-services-list-toggle .wc-wizard-service-toggle{height:16px;width:32px;border:2px solid #935687;background-color:#935687;display:inline-block;text-indent:-9999px;border-radius:10em;position:relative}.wc-wizard-service-item .wc-wizard-service-toggle input[type=checkbox],.wc-wizard-services-list-toggle .wc-wizard-service-toggle input[type=checkbox]{display:none}.wc-wizard-service-item .wc-wizard-service-toggle:before,.wc-wizard-services-list-toggle .wc-wizard-service-toggle:before{content:"";display:block;width:16px;height:16px;background:#fff;position:absolute;top:0;right:0;border-radius:100%}.wc-wizard-service-item .wc-wizard-service-toggle.disabled,.wc-wizard-services-list-toggle .wc-wizard-service-toggle.disabled{border-color:#999;background-color:#999}.wc-wizard-service-item .wc-wizard-service-toggle.disabled:before,.wc-wizard-services-list-toggle .wc-wizard-service-toggle.disabled:before{right:auto;left:0}.wc-wizard-service-item .wc-wizard-service-settings,.wc-wizard-services-list-toggle .wc-wizard-service-settings{display:none;margin-bottom:0;cursor:default}.wc-wizard-service-item .wc-wizard-service-settings.hide,.wc-wizard-services-list-toggle .wc-wizard-service-settings.hide{display:none}.wc-wizard-service-item.checked .wc-wizard-service-settings,.wc-wizard-services-list-toggle.checked .wc-wizard-service-settings{display:inline-block}.wc-wizard-service-item.checked .wc-wizard-service-settings.hide,.wc-wizard-services-list-toggle.checked .wc-wizard-service-settings.hide{display:none}.wc-wizard-service-item.closed,.wc-wizard-services-list-toggle.closed{border-bottom:0}.wc-wizard-services-list-toggle{cursor:pointer}.wc-wizard-services-list-toggle .wc-wizard-service-enable::before{content:"\f343";font-family:dashicons;visibility:initial;color:#666;font-size:25px;margin-top:-7px;margin-left:-5px;position:absolute;visibility:visible}.wc-wizard-services-list-toggle.closed .wc-wizard-service-enable::before{content:"\f347"}.wc-wizard-services-list-toggle .wc-wizard-service-enable input{visibility:hidden;position:relative}.wc-wizard-services.manual .wc-wizard-service-item{display:none}.wc-wizard-services.shipping .wc-wizard-service-name{font-weight:400;text-align:left;-webkit-box-align:center;-ms-flex-align:center;align-items:center;max-height:5em;padding:0}.wc-wizard-services.shipping .wc-wizard-service-item{padding-left:2em;padding-top:.67em}.wc-wizard-services.shipping .wc-wizard-service-item:first-child{border-bottom:0;padding-bottom:0;font-weight:700}.wc-wizard-services.shipping .wc-wizard-service-item:first-child .wc-wizard-service-name{font-weight:700}.wc-wizard-services.shipping .shipping-method-setting,.wc-wizard-services.shipping .wc-wizard-shipping-method-select{display:-webkit-box;display:-ms-flexbox;display:flex}.wc-wizard-services.shipping .shipping-method-setting.hide,.wc-wizard-services.shipping .wc-wizard-shipping-method-select.hide{display:none}.wc-wizard-services.shipping .shipping-method-setting input,.wc-wizard-services.shipping .wc-wizard-shipping-method-dropdown{margin-right:2em;margin-bottom:1em}.wc-wizard-services.shipping .shipping-method-setting input .select2,.wc-wizard-services.shipping .wc-wizard-shipping-method-dropdown .select2{min-width:130px}.wc-wizard-services.shipping .wc-wizard-service-description{display:-webkit-box;display:-ms-flexbox;display:flex;-webkit-box-orient:vertical;-webkit-box-direction:normal;-ms-flex-direction:column;flex-direction:column;color:#a6a6a6}.wc-wizard-services.shipping .wc-wizard-service-item:not(:first-child) .wc-wizard-service-description{font-size:.92em;padding-bottom:10px}.wc-wizard-services.shipping .shipping-method-setting input{width:95px;border:1px solid #aaa;border-color:#ddd;border-radius:4px;height:28px;padding-left:8px;padding-right:24px;font-size:14px;color:#444;background-color:#fff;display:inline-block}.wc-wizard-services.shipping .shipping-method-description,.wc-wizard-services.shipping .shipping-method-setting .description{color:#7e7e7e;font-size:.9em}.wc-wizard-services.shipping .shipping-method-setting input::-webkit-input-placeholder{color:#e1e1e1}.wc-wizard-services.shipping .shipping-method-setting input::-moz-placeholder{color:#e1e1e1}.wc-wizard-services.shipping .shipping-method-setting input:-ms-input-placeholder{color:#e1e1e1}.wc-wizard-services.shipping .shipping-method-setting input::placeholder{color:#e1e1e1}.wc-setup-shipping-units p{line-height:1.5em;font-size:13px;margin-bottom:.25em}.wc-setup-shipping-units .wc-setup-shipping-unit{margin-bottom:1.75em}.wc-setup-shipping-units .wc-setup-shipping-unit .select2{min-width:100%}.hide{display:none}.wc-wizard-features{display:-webkit-box;display:-ms-flexbox;display:flex;-ms-flex-wrap:wrap;flex-wrap:wrap;list-style:none;padding:0}.wc-wizard-features .wc-wizard-feature-item{-ms-flex-preferred-size:calc(50% - 4em - 3px);flex-basis:calc(50% - 4em - 3px);border:1px solid #eee;padding:2em}.wc-wizard-features .wc-wizard-feature-item:nth-child(1){border-radius:4px 0 0 0}.wc-wizard-features .wc-wizard-feature-item:nth-child(2){border-left:0;border-radius:0 4px 0 0}.wc-wizard-features .wc-wizard-feature-item:nth-child(3){border-top:0;border-radius:0 0 0 4px}.wc-wizard-features .wc-wizard-feature-item:nth-child(4){border-top:0;border-left:0;border-radius:0 0 4px 0}.wc-wizard-features p.wc-wizard-feature-description,.wc-wizard-features p.wc-wizard-feature-name{margin:0;line-height:1.5em}h3.jetpack-reasons{text-align:center;margin:3em 0 1em 0;font-size:14px}.jetpack-logo,.wcs-notice{display:block;margin:1.75em auto 2em auto;max-height:175px}.activate-splash .jetpack-logo{width:170px;margin-bottom:0}.activate-splash .wcs-notice{margin-top:1em;padding-left:57px}.step{text-align:center}.wc-setup .wc-setup-actions .button{font-weight:300;font-size:16px;padding:1em 2em;box-shadow:none;min-width:12em;min-width:auto;margin-top:10px}.wc-setup .wc-setup-actions .button:active,.wc-setup .wc-setup-actions .button:focus,.wc-setup .wc-setup-actions .button:hover{box-shadow:none}.location-prompt{color:#666;font-size:13px;font-weight:500;margin-bottom:.5em;margin-top:.85em;display:inline-block}.location-input{border:1px solid #aaa;border-color:#ddd;border-radius:4px;height:30px;width:calc(100% - 8px - 24px - 2px);padding-left:8px;padding-right:24px;font-size:16px;color:#444;background-color:#fff;display:inline-block}.location-input.dropdown{width:100%}.address-step .select2{min-width:100%}.store-address-container .city-and-postcode{display:-webkit-box;display:-ms-flexbox;display:flex}.store-address-container .city-and-postcode div{-ms-flex-preferred-size:50%;flex-basis:50%;margin-right:1em}.store-address-container .city-and-postcode div:last-of-type{margin-right:0}.store-address-container .select2-container,.store-address-container input[type=text],.store-address-container select{margin-bottom:10px}.product-type-container{margin-top:14px;margin-bottom:1px}#woocommerce_sell_in_person{margin-left:0}.wc-wizard-service-settings .payment-email-input{border:1px solid #aaa;border-color:#ddd;border-radius:4px;height:30px;padding:0 8px;font-size:14px;color:#444;background-color:#fff;display:inline-block}.newsletter-form-container{display:-webkit-box;display:-ms-flexbox;display:flex}.newsletter-form-container .newsletter-form-email{border:1px solid #aaa;border-color:#ddd;border-radius:4px;height:42px;padding:0 8px;font-size:16px;color:#666;background-color:#fff;display:inline-block;margin-right:6px;-webkit-box-flex:1;-ms-flex-positive:1;flex-grow:1}.newsletter-form-container .newsletter-form-button-container{-webkit-box-flex:0;-ms-flex-positive:0;flex-grow:0}.wc-setup .wc-setup-actions .button.newsletter-form-button{height:42px;padding:0 1em;margin:0}.wc-wizard-next-steps{border:1px solid #eee;border-radius:4px;list-style:none;padding:0}.wc-wizard-next-steps li{padding:0}.wc-wizard-next-steps .wc-wizard-next-step-item{display:-webkit-box;display:-ms-flexbox;display:flex;border-top:1px solid #eee}.wc-wizard-next-steps .wc-wizard-next-step-item:first-child{border-top:0}.wc-wizard-next-steps .wc-wizard-next-step-description{-webkit-box-flex:1;-ms-flex-positive:1;flex-grow:1;margin:1.5em}.wc-wizard-next-steps .wc-wizard-next-step-action{-webkit-box-flex:0;-ms-flex-positive:0;flex-grow:0;display:-webkit-box;display:-ms-flexbox;display:flex;-webkit-box-align:center;-ms-flex-align:center;align-items:center}.wc-wizard-next-steps .wc-wizard-next-step-action .button{margin:1em 1.5em}.wc-wizard-next-steps p.next-step-heading{margin:0;font-size:.95em;font-weight:400;font-variant:all-petite-caps}.wc-wizard-next-steps p.next-step-extra-info{margin:0}.wc-wizard-next-steps h3.next-step-description{margin:0;font-size:16px;font-weight:600}.wc-wizard-next-steps .wc-wizard-additional-steps{border-top:1px solid #eee}.wc-wizard-next-steps .wc-wizard-additional-steps .wc-wizard-next-step-description{margin-bottom:0}.wc-wizard-next-steps .wc-wizard-additional-steps .wc-setup-actions{margin:0 0 1.5em 0}.wc-wizard-next-steps .wc-wizard-additional-steps .wc-setup-actions .button{font-size:15px;margin:1em 0 1em 1.5em}.wc-wizard-next-steps .wc-wizard-additional-steps .wc-setup-actions .button::last-child{margin-right:1.5em}p.next-steps-help-text{color:#9f9f9f;padding:0 2em;text-align:center;font-size:.9em}p.jetpack-terms{font-size:.8em;text-align:center;max-width:480px;margin:0 auto;line-height:1.5em}.woocommerce-error{background:#ffe6e5;border-color:#ffc5c2;padding:1em;margin-bottom:1em}.woocommerce-error p{margin-top:0;margin-bottom:.5em;color:#444}.woocommerce-error a{color:#ff645c}.woocommerce-error .reconnect-reminder{font-size:.85em}.woocommerce-error .wc-setup-actions .button{font-size:14px}.wc-wizard-service-setting-ppec_paypal_reroute_requests,.wc-wizard-service-setting-stripe_create_account{display:-webkit-box;display:-ms-flexbox;display:flex;-webkit-box-align:start;-ms-flex-align:start;align-items:flex-start;margin-top:.75em}.wc-wizard-service-setting-ppec_paypal_reroute_requests .payment-checkbox-input,.wc-wizard-service-setting-stripe_create_account .payment-checkbox-input{-webkit-box-ordinal-group:2;-ms-flex-order:1;order:1;margin-top:5px;margin-left:0;margin-right:0;width:1.5em}.wc-wizard-service-setting-ppec_paypal_reroute_requests .ppec_paypal_reroute_requests,.wc-wizard-service-setting-ppec_paypal_reroute_requests .stripe_create_account,.wc-wizard-service-setting-stripe_create_account .ppec_paypal_reroute_requests,.wc-wizard-service-setting-stripe_create_account .stripe_create_account{-webkit-box-ordinal-group:3;-ms-flex-order:2;order:2;margin-left:.3em}.wc-wizard-service-setting-ppec_paypal_email,.wc-wizard-service-setting-stripe_email{margin-top:.75em}.wc-wizard-service-setting-ppec_paypal_email label.ppec_paypal_email,.wc-wizard-service-setting-ppec_paypal_email label.stripe_email,.wc-wizard-service-setting-stripe_email label.ppec_paypal_email,.wc-wizard-service-setting-stripe_email label.stripe_email{position:absolute;margin:-1px;padding:0;height:1px;width:1px;overflow:hidden;clip:rect(0 0 0 0);border:0}.wc-wizard-service-setting-ppec_paypal_email input.payment-email-input,.wc-wizard-service-setting-stripe_email input.payment-email-input{margin-left:1.5em;margin-bottom:.5em;width:100%}.wc-wizard-service-setting-ppec_paypal_email .wc-wizard-service-settings-description,.wc-wizard-service-setting-stripe_email .wc-wizard-service-settings-description{margin-left:1.5em}.recommended-step{border:1px solid #ebebeb;border-radius:4px;padding:2.5em}.recommended-step li{list-style:none}.recommended-step li:last-child .recommended-item{margin-bottom:0}.recommended-step .recommended-item{display:-webkit-box;display:-ms-flexbox;display:flex;-webkit-box-align:center;-ms-flex-align:center;align-items:center;margin-bottom:1.5em}.recommended-step .recommended-item-icon{border:1px solid #fff;border-radius:7px;height:3.5em;margin-right:1em;margin-left:1em}.recommended-step .recommended-item-icon.recommended-item-icon-storefront_theme{background-color:#f4a224;max-height:3em;max-width:3em;padding:.25em}.recommended-step .recommended-item-description-container h3{font-size:15px;font-weight:700;letter-spacing:.5px;margin-bottom:0}.recommended-step .recommended-item-description-container p{margin-top:0;line-height:1.5em} \ No newline at end of file +@charset "UTF-8";body{margin:65px auto 24px;box-shadow:none;background:#f1f1f1;padding:0}#wc-logo{border:0;margin:0 0 24px;padding:0;text-align:center}#wc-logo img{max-width:30%}.wc-setup{text-align:center}.wc-setup .select2-container{text-align:left}.wc-setup .hidden{display:none}.wc-setup-content{box-shadow:0 1px 3px rgba(0,0,0,.13);padding:2em;margin:0 0 20px;background:#fff;overflow:hidden;zoom:1;text-align:left}.wc-setup-content h1,.wc-setup-content h2,.wc-setup-content h3,.wc-setup-content table{margin:0 0 20px;border:0;padding:0;color:#666;clear:none;font-weight:500}.wc-setup-content p{margin:20px 0;font-size:1em;line-height:1.75em;color:#666}.wc-setup-content table{font-size:1em;line-height:1.75em;color:#666}.wc-setup-content a{color:#a16696}.wc-setup-content a:focus,.wc-setup-content a:hover{color:#111}.wc-setup-content .form-table th{width:35%;vertical-align:top;font-weight:400}.wc-setup-content .form-table td{vertical-align:top}.wc-setup-content .form-table td input,.wc-setup-content .form-table td select{width:100%;box-sizing:border-box}.wc-setup-content .form-table td input[size]{width:auto}.wc-setup-content .form-table td .description{line-height:1.5em;display:block;margin-top:.25em;color:#999;font-style:italic}.wc-setup-content .form-table td .input-checkbox,.wc-setup-content .form-table td .input-radio{width:auto;box-sizing:inherit;padding:inherit;margin:0 .5em 0 0;box-shadow:none}.wc-setup-content .form-table .section_title td{padding:0}.wc-setup-content .form-table .section_title td h2,.wc-setup-content .form-table .section_title td p{margin:12px 0 0}.wc-setup-content .form-table td,.wc-setup-content .form-table th{padding:12px 0;margin:0;border:0}.wc-setup-content .form-table td:first-child,.wc-setup-content .form-table th:first-child{padding-right:1em}.wc-setup-content table.tax-rates{width:100%;font-size:.92em}.wc-setup-content table.tax-rates th{padding:0;text-align:center;width:auto;vertical-align:middle}.wc-setup-content table.tax-rates td{border:1px solid #f5f5f5;padding:6px;text-align:center;vertical-align:middle}.wc-setup-content table.tax-rates td input{outline:0;border:0;padding:0;box-shadow:none;text-align:center;width:100%}.wc-setup-content table.tax-rates td.sort{cursor:move;color:#ccc}.wc-setup-content table.tax-rates td.sort::before{content:'\f333';font-family:dashicons}.wc-setup-content table.tax-rates td.readonly{background:#f5f5f5}.wc-setup-content table.tax-rates .add{padding:1em 0 0 1em;line-height:1em;font-size:1em;width:0;margin:6px 0 0;height:0;overflow:hidden;position:relative;display:inline-block}.wc-setup-content table.tax-rates .add::before{content:'\f502';font-family:dashicons;position:absolute;left:0;top:0}.wc-setup-content table.tax-rates .remove{padding:1em 0 0 1em;line-height:1em;font-size:1em;width:0;margin:0;height:0;overflow:hidden;position:relative;display:inline-block}.wc-setup-content table.tax-rates .remove::before{content:'\f182';font-family:dashicons;position:absolute;left:0;top:0}.wc-setup-content .wc-setup-pages{width:100%;border-top:1px solid #eee}.wc-setup-content .wc-setup-pages thead th{display:none}.wc-setup-content .wc-setup-pages .page-name{width:30%;font-weight:700}.wc-setup-content .wc-setup-pages td,.wc-setup-content .wc-setup-pages th{padding:14px 0;border-bottom:1px solid #eee}.wc-setup-content .wc-setup-pages td:first-child,.wc-setup-content .wc-setup-pages th:first-child{padding-right:9px}.wc-setup-content .wc-setup-pages th{padding-top:0}.wc-setup-content .wc-setup-pages .page-options p{color:#777;margin:6px 0 0 24px;line-height:1.75em}.wc-setup-content .wc-setup-pages .page-options p input{vertical-align:middle;margin:1px 0 0;height:1.75em;width:1.75em;line-height:1.75em}.wc-setup-content .wc-setup-pages .page-options p label{line-height:1}@media screen and (max-width:782px){.wc-setup-content .form-table tbody th{width:auto}}.wc-setup-content .twitter-share-button{float:right}.wc-setup-content .wc-setup-next-steps{overflow:hidden;margin:0 0 24px;padding-bottom:2px}.wc-setup-content .wc-setup-next-steps h2{margin-bottom:12px}.wc-setup-content .wc-setup-next-steps .wc-setup-next-steps-first{float:left;width:50%;box-sizing:border-box}.wc-setup-content .wc-setup-next-steps .wc-setup-next-steps-last{float:right;width:50%;box-sizing:border-box}.wc-setup-content .wc-setup-next-steps ul{padding:0 2em 0 0;list-style:none outside;margin:0}.wc-setup-content .wc-setup-next-steps ul li a{display:block;padding:0 0 .75em}.wc-setup-content .wc-setup-next-steps ul .setup-product a.button{background-color:#f7f7f7;border-color:#ccc;color:#23282d;box-shadow:inset 0 1px 0 rgba(255,255,255,.25),0 1px 0 #ccc;text-shadow:1px 0 1px #eee,0 1px 1px #eee;font-size:1em;height:auto;line-height:1.75em;margin:0 0 .75em;opacity:1;padding:1em;text-align:center}.wc-setup-content .wc-setup-next-steps ul .setup-product a.button:active,.wc-setup-content .wc-setup-next-steps ul .setup-product a.button:focus,.wc-setup-content .wc-setup-next-steps ul .setup-product a.button:hover{background:#f5f5f5;border-color:#aaa}.wc-setup-content .wc-setup-next-steps ul .setup-product a.button-primary{color:#fff;background-color:#bb77ae;border-color:#a36597;box-shadow:inset 0 1px 0 rgba(255,255,255,.25),0 1px 0 #a36597;text-shadow:0 -1px 1px #a36597,1px 0 1px #a36597,0 1px 1px #a36597,-1px 0 1px #a36597}.wc-setup-content .wc-setup-next-steps ul .setup-product a.button-primary:active,.wc-setup-content .wc-setup-next-steps ul .setup-product a.button-primary:focus,.wc-setup-content .wc-setup-next-steps ul .setup-product a.button-primary:hover{color:#fff;background:#a36597;border-color:#a36597;box-shadow:inset 0 1px 0 rgba(255,255,255,.25),0 1px 0 #a36597}.wc-setup-content .wc-setup-next-steps ul li a::before{color:#82878c;font:normal 20px/1 dashicons;speak:none;display:inline-block;padding:0 10px 0 0;top:1px;position:relative;text-decoration:none!important;vertical-align:top}.wc-setup-content .wc-setup-next-steps ul .learn-more a::before{content:'\f105'}.wc-setup-content .wc-setup-next-steps ul .video-walkthrough a::before{content:'\f126'}.wc-setup-content .wc-setup-next-steps ul .newsletter a::before{content:'\f465'}.wc-setup-content .updated,.wc-setup-content .woocommerce-newsletter{padding:24px 24px 0;margin:0 0 24px;overflow:hidden;background:#f5f5f5}.wc-setup-content .updated p,.wc-setup-content .woocommerce-newsletter p{padding:0;margin:0 0 12px}.wc-setup-content .updated form,.wc-setup-content .updated p:last-child,.wc-setup-content .woocommerce-newsletter form,.wc-setup-content .woocommerce-newsletter p:last-child{margin:0 0 24px}.wc-setup-content .woocommerce-tracker{margin:24px 0;border:1px solid #eee;padding:20px;border-radius:4px;overflow:hidden}.wc-setup-content .woocommerce-tracker p{font-size:14px;line-height:1.5em}.wc-setup-content .woocommerce-tracker .checkbox{line-height:24px;font-weight:500;font-size:1em;margin-top:0;margin-bottom:20px}.wc-setup-content .woocommerce-tracker .checkbox input[type=checkbox]{opacity:0;position:absolute;left:-9999px}.wc-setup-content .woocommerce-tracker .checkbox label{position:relative;display:inline-block;padding-left:28px}.wc-setup-content .woocommerce-tracker .checkbox label:after,.wc-setup-content .woocommerce-tracker .checkbox label:before{position:absolute;content:"";display:inline-block}.wc-setup-content .woocommerce-tracker .checkbox label:before{height:16px;width:16px;left:0;top:3px;border:1px solid #aaa;background-color:#fff;border-radius:3px}.wc-setup-content .woocommerce-tracker .checkbox label:after{height:5px;width:9px;border-left:2px solid;border-bottom:2px solid;-webkit-transform:rotate(-45deg);-ms-transform:rotate(-45deg);transform:rotate(-45deg);left:4px;top:7px;color:#fff}.wc-setup-content .woocommerce-tracker .checkbox input[type=checkbox]+label::after{content:none}.wc-setup-content .woocommerce-tracker .checkbox input[type=checkbox]:checked+label::after{content:""}.wc-setup-content .woocommerce-tracker .checkbox input[type=checkbox]:focus+label::before{outline:#3b99fc auto 5px}.wc-setup-content .woocommerce-tracker .checkbox input[type=checkbox]:checked+label::before{background:#935687;border-color:#935687;outline:0}.wc-setup-steps{padding:0 0 24px;margin:0;list-style:none outside;overflow:hidden;color:#ccc;width:100%;display:-webkit-inline-box;display:-ms-inline-flexbox;display:inline-flex}.wc-setup-steps li{width:100%;float:left;padding:0 0 .8em;margin:0;text-align:center;position:relative;border-bottom:4px solid #ccc;line-height:1.4em}.wc-setup-steps li a{color:#a16696;text-decoration:none;padding:1.5em;margin:-1.5em;position:relative;z-index:1}.wc-setup-steps li a:focus,.wc-setup-steps li a:hover{color:#111;text-decoration:underline}.wc-setup-steps li::before{content:'';border:4px solid #ccc;border-radius:100%;width:4px;height:4px;position:absolute;bottom:0;left:50%;margin-left:-6px;margin-bottom:-8px;background:#fff}.wc-setup-steps li.active{border-color:#a16696;color:#a16696;font-weight:700}.wc-setup-steps li.active::before{border-color:#a16696}.wc-setup-steps li.done{border-color:#a16696;color:#a16696}.wc-setup-steps li.done::before{border-color:#a16696;background:#a16696}.wc-setup .wc-setup-actions{overflow:hidden;margin:20px 0 0;position:relative}.wc-setup .wc-setup-actions .button{font-size:1.25em;padding:.5em 1em;line-height:1em;margin-right:.5em;margin-bottom:2px;height:auto;border-radius:4px}.wc-setup .wc-setup-actions .button-primary{background-color:#bb77ae;border-color:#a36597;box-shadow:inset 0 1px 0 rgba(255,255,255,.25),0 1px 0 #a36597;text-shadow:0 -1px 1px #a36597,1px 0 1px #a36597,0 1px 1px #a36597,-1px 0 1px #a36597;margin:0;opacity:1}.wc-setup .wc-setup-actions .button-primary:active,.wc-setup .wc-setup-actions .button-primary:focus,.wc-setup .wc-setup-actions .button-primary:hover{background:#a36597;border-color:#a36597;box-shadow:inset 0 1px 0 rgba(255,255,255,.25),0 1px 0 #a36597}.wc-setup-content p:last-child{margin-bottom:0}.wc-setup-content p.store-setup{margin-top:0}.wc-setup-footer-links{font-size:.85em;color:#b5b5b5;margin:1.18em auto;display:inline-block;text-align:center}.wc-wizard-storefront .wc-wizard-storefront-intro{padding:40px 40px 0;background:#f5f5f5;text-align:center}.wc-wizard-storefront .wc-wizard-storefront-intro img{margin:40px 0 0 0;width:100%;display:block}.wc-wizard-storefront .wc-wizard-storefront-features{list-style:none outside;margin:0 0 20px;padding:0 0 0 30px;overflow:hidden}.wc-wizard-storefront .wc-wizard-storefront-feature{margin:0;padding:20px 30px 20px 2em;width:50%;box-sizing:border-box}.wc-wizard-storefront .wc-wizard-storefront-feature::before{margin-left:-2em;position:absolute}.wc-wizard-storefront .wc-wizard-storefront-feature.first{clear:both;float:left}.wc-wizard-storefront .wc-wizard-storefront-feature.last{float:right}.wc-wizard-storefront .wc-wizard-storefront-feature__bulletproof::before{content:'πŸ”’'}.wc-wizard-storefront .wc-wizard-storefront-feature__mobile::before{content:'πŸ“±'}.wc-wizard-storefront .wc-wizard-storefront-feature__accessibility::before{content:'πŸ‘“'}.wc-wizard-storefront .wc-wizard-storefront-feature__search::before{content:'πŸ”'}.wc-wizard-storefront .wc-wizard-storefront-feature__compatibility::before{content:'πŸ”§'}.wc-wizard-storefront .wc-wizard-storefront-feature__extendable::before{content:'🎨'}.wc-wizard-services{border:1px solid #eee;padding:0;margin:0 0 1em;list-style:none outside;border-radius:4px;overflow:hidden}.wc-wizard-services p{margin:0 0 1em 0;padding:0;font-size:1em;line-height:1.5em}.wc-wizard-service-item,.wc-wizard-services-list-toggle{display:-webkit-box;display:-ms-flexbox;display:flex;-ms-flex-wrap:nowrap;flex-wrap:nowrap;-webkit-box-pack:justify;-ms-flex-pack:justify;justify-content:space-between;padding:0;border-bottom:1px solid #eee;color:#666;-webkit-box-align:center;-ms-flex-align:center;align-items:center}.wc-wizard-service-item:last-child,.wc-wizard-services-list-toggle:last-child{border-bottom:0}.wc-wizard-service-item .payment-gateway-fee,.wc-wizard-services-list-toggle .payment-gateway-fee{color:#a6a6a6}.wc-wizard-service-item .wc-wizard-service-name,.wc-wizard-services-list-toggle .wc-wizard-service-name{-ms-flex-preferred-size:0;flex-basis:0;min-width:160px;text-align:center;font-weight:700;padding:2em 0;-ms-flex-item-align:stretch;align-self:stretch;display:-webkit-box;display:-ms-flexbox;display:flex;-webkit-box-align:baseline;-ms-flex-align:baseline;align-items:baseline}.wc-wizard-payment-gateway-form .wc-wizard-service-item .wc-wizard-service-name,.wc-wizard-payment-gateway-form .wc-wizard-services-list-toggle .wc-wizard-service-name{-webkit-box-pack:center;-ms-flex-pack:center;justify-content:center}.wc-wizard-service-item .wc-wizard-service-name img,.wc-wizard-services-list-toggle .wc-wizard-service-name img{max-width:75px}.wc-wizard-service-item.stripe-logo .wc-wizard-service-name img,.wc-wizard-services-list-toggle.stripe-logo .wc-wizard-service-name img{padding:8px 0}.wc-wizard-service-item.paypal-logo .wc-wizard-service-name img,.wc-wizard-services-list-toggle.paypal-logo .wc-wizard-service-name img{max-width:87px;padding:2px 0}.wc-wizard-service-item.klarna-logo .wc-wizard-service-name,.wc-wizard-services-list-toggle.klarna-logo .wc-wizard-service-name{background:#000}.wc-wizard-service-item.klarna-logo .wc-wizard-service-name img,.wc-wizard-services-list-toggle.klarna-logo .wc-wizard-service-name img{max-width:87px;padding:12px 0}.wc-wizard-service-item.square-logo .wc-wizard-service-name,.wc-wizard-services-list-toggle.square-logo .wc-wizard-service-name{background:#000}.wc-wizard-service-item.square-logo .wc-wizard-service-name img,.wc-wizard-services-list-toggle.square-logo .wc-wizard-service-name img{max-width:95px;padding:12px 0}.wc-wizard-service-item .wc-wizard-service-description,.wc-wizard-services-list-toggle .wc-wizard-service-description{-webkit-box-flex:1;-ms-flex-positive:1;flex-grow:1;padding:20px}.wc-wizard-service-item .wc-wizard-service-description p,.wc-wizard-services-list-toggle .wc-wizard-service-description p{margin-bottom:1em}.wc-wizard-service-item .wc-wizard-service-description p:last-child,.wc-wizard-services-list-toggle .wc-wizard-service-description p:last-child{margin-bottom:0}.wc-wizard-service-item .wc-wizard-service-description .wc-wizard-service-settings-description,.wc-wizard-services-list-toggle .wc-wizard-service-description .wc-wizard-service-settings-description{display:block;font-style:italic;color:#999}.wc-wizard-service-item .wc-wizard-service-enable,.wc-wizard-services-list-toggle .wc-wizard-service-enable{-ms-flex-preferred-size:0;flex-basis:0;min-width:75px;text-align:center;cursor:pointer;padding:2em 0;position:relative;max-height:1.5em;-ms-flex-item-align:start;align-self:flex-start}.wc-wizard-service-item .wc-wizard-service-toggle,.wc-wizard-services-list-toggle .wc-wizard-service-toggle{height:16px;width:32px;border:2px solid #935687;background-color:#935687;display:inline-block;text-indent:-9999px;border-radius:10em;position:relative}.wc-wizard-service-item .wc-wizard-service-toggle input[type=checkbox],.wc-wizard-services-list-toggle .wc-wizard-service-toggle input[type=checkbox]{display:none}.wc-wizard-service-item .wc-wizard-service-toggle:before,.wc-wizard-services-list-toggle .wc-wizard-service-toggle:before{content:"";display:block;width:16px;height:16px;background:#fff;position:absolute;top:0;right:0;border-radius:100%}.wc-wizard-service-item .wc-wizard-service-toggle.disabled,.wc-wizard-services-list-toggle .wc-wizard-service-toggle.disabled{border-color:#999;background-color:#999}.wc-wizard-service-item .wc-wizard-service-toggle.disabled:before,.wc-wizard-services-list-toggle .wc-wizard-service-toggle.disabled:before{right:auto;left:0}.wc-wizard-service-item .wc-wizard-service-settings,.wc-wizard-services-list-toggle .wc-wizard-service-settings{display:none;margin-bottom:0;cursor:default}.wc-wizard-service-item .wc-wizard-service-settings.hide,.wc-wizard-services-list-toggle .wc-wizard-service-settings.hide{display:none}.wc-wizard-service-item.checked .wc-wizard-service-settings,.wc-wizard-services-list-toggle.checked .wc-wizard-service-settings{display:inline-block}.wc-wizard-service-item.checked .wc-wizard-service-settings.hide,.wc-wizard-services-list-toggle.checked .wc-wizard-service-settings.hide{display:none}.wc-wizard-service-item.closed,.wc-wizard-services-list-toggle.closed{border-bottom:0}.wc-wizard-services-list-toggle{cursor:pointer}.wc-wizard-services-list-toggle .wc-wizard-service-enable::before{content:"\f343";font-family:dashicons;visibility:initial;color:#666;font-size:25px;margin-top:-7px;margin-left:-5px;position:absolute;visibility:visible}.wc-wizard-services-list-toggle.closed .wc-wizard-service-enable::before{content:"\f347"}.wc-wizard-services-list-toggle .wc-wizard-service-enable input{visibility:hidden;position:relative}.wc-wizard-services.manual .wc-wizard-service-item{display:none}.wc-wizard-services.shipping .wc-wizard-service-name{font-weight:400;text-align:left;-webkit-box-align:center;-ms-flex-align:center;align-items:center;max-height:5em;padding:0}.wc-wizard-services.shipping .wc-wizard-service-item{padding-left:2em;padding-top:.67em}.wc-wizard-services.shipping .wc-wizard-service-item:first-child{border-bottom:0;padding-bottom:0;font-weight:700}.wc-wizard-services.shipping .wc-wizard-service-item:first-child .wc-wizard-service-name{font-weight:700}.wc-wizard-services.shipping .shipping-method-setting,.wc-wizard-services.shipping .wc-wizard-shipping-method-select{display:-webkit-box;display:-ms-flexbox;display:flex}.wc-wizard-services.shipping .shipping-method-setting.hide,.wc-wizard-services.shipping .wc-wizard-shipping-method-select.hide{display:none}.wc-wizard-services.shipping .shipping-method-setting input,.wc-wizard-services.shipping .wc-wizard-shipping-method-dropdown{margin-right:2em;margin-bottom:1em}.wc-wizard-services.shipping .shipping-method-setting input .select2,.wc-wizard-services.shipping .wc-wizard-shipping-method-dropdown .select2{min-width:130px}.wc-wizard-services.shipping .wc-wizard-service-description{display:-webkit-box;display:-ms-flexbox;display:flex;-webkit-box-orient:vertical;-webkit-box-direction:normal;-ms-flex-direction:column;flex-direction:column;color:#a6a6a6}.wc-wizard-services.shipping .wc-wizard-service-item:not(:first-child) .wc-wizard-service-description{font-size:.92em;padding-bottom:10px}.wc-wizard-services.shipping .shipping-method-setting input{width:95px;border:1px solid #aaa;border-color:#ddd;border-radius:4px;height:28px;padding-left:8px;padding-right:24px;font-size:14px;color:#444;background-color:#fff;display:inline-block}.wc-wizard-services.shipping .shipping-method-description,.wc-wizard-services.shipping .shipping-method-setting .description{color:#7e7e7e;font-size:.9em}.wc-wizard-services.shipping .shipping-method-setting input::-webkit-input-placeholder{color:#e1e1e1}.wc-wizard-services.shipping .shipping-method-setting input::-moz-placeholder{color:#e1e1e1}.wc-wizard-services.shipping .shipping-method-setting input:-ms-input-placeholder{color:#e1e1e1}.wc-wizard-services.shipping .shipping-method-setting input::placeholder{color:#e1e1e1}.wc-setup-shipping-units p{line-height:1.5em;font-size:13px;margin-bottom:.25em}.wc-setup-shipping-units .wc-setup-shipping-unit{margin-bottom:1.75em}.wc-setup-shipping-units .wc-setup-shipping-unit .select2{min-width:100%}.hide{display:none}.wc-wizard-features{display:-webkit-box;display:-ms-flexbox;display:flex;-ms-flex-wrap:wrap;flex-wrap:wrap;list-style:none;padding:0}.wc-wizard-features .wc-wizard-feature-item{-ms-flex-preferred-size:calc(50% - 4em - 3px);flex-basis:calc(50% - 4em - 3px);border:1px solid #eee;padding:2em}.wc-wizard-features .wc-wizard-feature-item:nth-child(1){border-radius:4px 0 0 0}.wc-wizard-features .wc-wizard-feature-item:nth-child(2){border-left:0;border-radius:0 4px 0 0}.wc-wizard-features .wc-wizard-feature-item:nth-child(3){border-top:0;border-radius:0 0 0 4px}.wc-wizard-features .wc-wizard-feature-item:nth-child(4){border-top:0;border-left:0;border-radius:0 0 4px 0}.wc-wizard-features p.wc-wizard-feature-description,.wc-wizard-features p.wc-wizard-feature-name{margin:0;line-height:1.5em}h3.jetpack-reasons{text-align:center;margin:3em 0 1em 0;font-size:14px}.jetpack-logo,.wcs-notice{display:block;margin:1.75em auto 2em auto;max-height:175px}.activate-splash .jetpack-logo{width:170px;margin-bottom:0}.activate-splash .wcs-notice{margin-top:1em;padding-left:57px}.step{text-align:center}.wc-setup .wc-setup-actions .button{font-weight:300;font-size:16px;padding:1em 2em;box-shadow:none;min-width:12em;min-width:auto;margin-top:10px}.wc-setup .wc-setup-actions .button:active,.wc-setup .wc-setup-actions .button:focus,.wc-setup .wc-setup-actions .button:hover{box-shadow:none}.location-prompt{color:#666;font-size:13px;font-weight:500;margin-bottom:.5em;margin-top:.85em;display:inline-block}.location-input{border:1px solid #aaa;border-color:#ddd;border-radius:4px;height:30px;width:calc(100% - 8px - 24px - 2px);padding-left:8px;padding-right:24px;font-size:16px;color:#444;background-color:#fff;display:inline-block}.location-input.dropdown{width:100%}.address-step .select2{min-width:100%}.store-address-container .city-and-postcode{display:-webkit-box;display:-ms-flexbox;display:flex}.store-address-container .city-and-postcode div{-ms-flex-preferred-size:50%;flex-basis:50%;margin-right:1em}.store-address-container .city-and-postcode div:last-of-type{margin-right:0}.store-address-container .select2-container,.store-address-container input[type=text],.store-address-container select{margin-bottom:10px}.product-type-container{margin-top:14px;margin-bottom:1px}#woocommerce_sell_in_person{margin-left:0}.wc-wizard-service-settings .payment-email-input{border:1px solid #aaa;border-color:#ddd;border-radius:4px;height:30px;padding:0 8px;font-size:14px;color:#444;background-color:#fff;display:inline-block}.newsletter-form-container{display:-webkit-box;display:-ms-flexbox;display:flex}.newsletter-form-container .newsletter-form-email{border:1px solid #aaa;border-color:#ddd;border-radius:4px;height:42px;padding:0 8px;font-size:16px;color:#666;background-color:#fff;display:inline-block;margin-right:6px;-webkit-box-flex:1;-ms-flex-positive:1;flex-grow:1}.newsletter-form-container .newsletter-form-button-container{-webkit-box-flex:0;-ms-flex-positive:0;flex-grow:0}.wc-setup .wc-setup-actions .button.newsletter-form-button{height:42px;padding:0 1em;margin:0}.wc-wizard-next-steps{border:1px solid #eee;border-radius:4px;list-style:none;padding:0}.wc-wizard-next-steps li{padding:0}.wc-wizard-next-steps .wc-wizard-next-step-item{display:-webkit-box;display:-ms-flexbox;display:flex;border-top:1px solid #eee}.wc-wizard-next-steps .wc-wizard-next-step-item:first-child{border-top:0}.wc-wizard-next-steps .wc-wizard-next-step-description{-webkit-box-flex:1;-ms-flex-positive:1;flex-grow:1;margin:1.5em}.wc-wizard-next-steps .wc-wizard-next-step-action{-webkit-box-flex:0;-ms-flex-positive:0;flex-grow:0;display:-webkit-box;display:-ms-flexbox;display:flex;-webkit-box-align:center;-ms-flex-align:center;align-items:center}.wc-wizard-next-steps .wc-wizard-next-step-action .button{margin:1em 1.5em}.wc-wizard-next-steps p.next-step-heading{margin:0;font-size:.95em;font-weight:400;font-variant:all-petite-caps}.wc-wizard-next-steps p.next-step-extra-info{margin:0}.wc-wizard-next-steps h3.next-step-description{margin:0;font-size:16px;font-weight:600}.wc-wizard-next-steps .wc-wizard-additional-steps{border-top:1px solid #eee}.wc-wizard-next-steps .wc-wizard-additional-steps .wc-wizard-next-step-description{margin-bottom:0}.wc-wizard-next-steps .wc-wizard-additional-steps .wc-setup-actions{margin:0 0 1.5em 0}.wc-wizard-next-steps .wc-wizard-additional-steps .wc-setup-actions .button{font-size:15px;margin:1em 0 1em 1.5em}.wc-wizard-next-steps .wc-wizard-additional-steps .wc-setup-actions .button::last-child{margin-right:1.5em}p.next-steps-help-text{color:#9f9f9f;padding:0 2em;text-align:center;font-size:.9em}p.jetpack-terms{font-size:.8em;text-align:center;max-width:480px;margin:0 auto;line-height:1.5em}.woocommerce-error{background:#ffe6e5;border-color:#ffc5c2;padding:1em;margin-bottom:1em}.woocommerce-error p{margin-top:0;margin-bottom:.5em;color:#444}.woocommerce-error a{color:#ff645c}.woocommerce-error .reconnect-reminder{font-size:.85em}.woocommerce-error .wc-setup-actions .button{font-size:14px}.wc-wizard-service-setting-ppec_paypal_reroute_requests,.wc-wizard-service-setting-stripe_create_account{display:-webkit-box;display:-ms-flexbox;display:flex;-webkit-box-align:start;-ms-flex-align:start;align-items:flex-start;margin-top:.75em}.wc-wizard-service-setting-ppec_paypal_reroute_requests .payment-checkbox-input,.wc-wizard-service-setting-stripe_create_account .payment-checkbox-input{-webkit-box-ordinal-group:2;-ms-flex-order:1;order:1;margin-top:5px;margin-left:0;margin-right:0;width:1.5em}.wc-wizard-service-setting-ppec_paypal_reroute_requests .ppec_paypal_reroute_requests,.wc-wizard-service-setting-ppec_paypal_reroute_requests .stripe_create_account,.wc-wizard-service-setting-stripe_create_account .ppec_paypal_reroute_requests,.wc-wizard-service-setting-stripe_create_account .stripe_create_account{-webkit-box-ordinal-group:3;-ms-flex-order:2;order:2;margin-left:.3em}.wc-wizard-service-setting-ppec_paypal_email,.wc-wizard-service-setting-stripe_email{margin-top:.75em}.wc-wizard-service-setting-ppec_paypal_email label.ppec_paypal_email,.wc-wizard-service-setting-ppec_paypal_email label.stripe_email,.wc-wizard-service-setting-stripe_email label.ppec_paypal_email,.wc-wizard-service-setting-stripe_email label.stripe_email{position:absolute;margin:-1px;padding:0;height:1px;width:1px;overflow:hidden;clip:rect(0 0 0 0);border:0}.wc-wizard-service-setting-ppec_paypal_email input.payment-email-input,.wc-wizard-service-setting-stripe_email input.payment-email-input{margin-left:1.5em;margin-bottom:.5em;width:100%}.wc-wizard-service-setting-ppec_paypal_email .wc-wizard-service-settings-description,.wc-wizard-service-setting-stripe_email .wc-wizard-service-settings-description{margin-left:1.5em}.recommended-step{border:1px solid #ebebeb;border-radius:4px;padding:2.5em}.recommended-step li{list-style:none}.recommended-step li:last-child .recommended-item{margin-bottom:0}.recommended-step .recommended-item{display:-webkit-box;display:-ms-flexbox;display:flex;-webkit-box-align:center;-ms-flex-align:center;align-items:center;margin-bottom:1.5em}.recommended-step .recommended-item-icon{border:1px solid #fff;border-radius:7px;height:3.5em;margin-right:1em;margin-left:1em}.recommended-step .recommended-item-icon.recommended-item-icon-storefront_theme{background-color:#f4a224;max-height:3em;max-width:3em;padding:.25em}.recommended-step .recommended-item-icon.recommended-item-icon-automated_taxes{background-color:#d0011b;max-height:1.75em;padding:.875em}.recommended-step .recommended-item-description-container h3{font-size:15px;font-weight:700;letter-spacing:.5px;margin-bottom:0}.recommended-step .recommended-item-description-container p{margin-top:0;line-height:1.5em} \ No newline at end of file diff --git a/assets/css/wc-setup.scss b/assets/css/wc-setup.scss index 74fe6a59112..0631d4de132 100644 --- a/assets/css/wc-setup.scss +++ b/assets/css/wc-setup.scss @@ -1233,6 +1233,12 @@ p.jetpack-terms { max-width: 3em; padding: ( 3.5em - 3em ) / 2; } + + &.recommended-item-icon-automated_taxes { + background-color: #d0011b; + max-height: 1.75em; + padding: ( 3.5em - 1.75em ) / 2; + } } .recommended-item-description-container { diff --git a/assets/images/obw-taxes-icon.svg b/assets/images/obw-taxes-icon.svg new file mode 100644 index 00000000000..ff9e702715f --- /dev/null +++ b/assets/images/obw-taxes-icon.svg @@ -0,0 +1 @@ + diff --git a/includes/admin/class-wc-admin-setup-wizard.php b/includes/admin/class-wc-admin-setup-wizard.php index f72dc1d2252..8028c309a10 100644 --- a/includes/admin/class-wc-admin-setup-wizard.php +++ b/includes/admin/class-wc-admin-setup-wizard.php @@ -1611,20 +1611,6 @@ class WC_Admin_Setup_Wizard { ?>

    - should_show_automated_tax_extra() ) : ?> -

    @@ -1674,17 +1654,17 @@ class WC_Admin_Setup_Wizard { check_admin_referer( 'wc-setup' ); $setup_storefront = isset( $_POST['setup_storefront_theme'] ) && 'yes' === $_POST['setup_storefront_theme']; - $setup_automated_tax = isset( $_POST['setup_automated_taxes'] ) && 'yes' === $_POST['setup_automated_taxes']; + $setup_automated_tax = isset( $_POST['setup_automated_taxes'] ) && 'yes' === $_POST['setup_automated_taxes']; update_option( 'woocommerce_calc_taxes', $setup_automated_tax ? 'yes' : 'no' ); update_option( 'woocommerce_setup_automated_taxes', $setup_automated_tax ); if ( $setup_storefront ) { $this->install_theme( 'storefront' ); - if ( $setup_automated_tax ) { - $this->install_woocommerce_services(); } + if ( $setup_automated_tax ) { + $this->install_woocommerce_services(); } wp_redirect( esc_url_raw( $this->get_next_step_link() ) ); From 551db8246e6ebbb19c8c40f4c71305cca6e164b1 Mon Sep 17 00:00:00 2001 From: Valerie Date: Sat, 14 Apr 2018 23:54:55 -0400 Subject: [PATCH 49/61] OBW: Add MailChimp to recommended step --- assets/css/wc-setup-rtl.css | 2 +- assets/css/wc-setup.css | 2 +- assets/css/wc-setup.scss | 6 ++++ assets/images/obw-mailchimp-icon.svg | 1 + .../admin/class-wc-admin-setup-wizard.php | 35 ++++++++++++++++++- 5 files changed, 43 insertions(+), 3 deletions(-) create mode 100644 assets/images/obw-mailchimp-icon.svg diff --git a/assets/css/wc-setup-rtl.css b/assets/css/wc-setup-rtl.css index af9802b4f45..6c8ae382c25 100644 --- a/assets/css/wc-setup-rtl.css +++ b/assets/css/wc-setup-rtl.css @@ -1 +1 @@ -@charset "UTF-8";body{margin:65px auto 24px;box-shadow:none;background:#f1f1f1;padding:0}#wc-logo{border:0;margin:0 0 24px;padding:0;text-align:center}#wc-logo img{max-width:30%}.wc-setup{text-align:center}.wc-setup .select2-container{text-align:right}.wc-setup .hidden{display:none}.wc-setup-content{box-shadow:0 1px 3px rgba(0,0,0,.13);padding:2em;margin:0 0 20px;background:#fff;overflow:hidden;zoom:1;text-align:right}.wc-setup-content h1,.wc-setup-content h2,.wc-setup-content h3,.wc-setup-content table{margin:0 0 20px;border:0;padding:0;color:#666;clear:none;font-weight:500}.wc-setup-content p{margin:20px 0;font-size:1em;line-height:1.75em;color:#666}.wc-setup-content table{font-size:1em;line-height:1.75em;color:#666}.wc-setup-content a{color:#a16696}.wc-setup-content a:focus,.wc-setup-content a:hover{color:#111}.wc-setup-content .form-table th{width:35%;vertical-align:top;font-weight:400}.wc-setup-content .form-table td{vertical-align:top}.wc-setup-content .form-table td input,.wc-setup-content .form-table td select{width:100%;box-sizing:border-box}.wc-setup-content .form-table td input[size]{width:auto}.wc-setup-content .form-table td .description{line-height:1.5em;display:block;margin-top:.25em;color:#999;font-style:italic}.wc-setup-content .form-table td .input-checkbox,.wc-setup-content .form-table td .input-radio{width:auto;box-sizing:inherit;padding:inherit;margin:0 0 0 .5em;box-shadow:none}.wc-setup-content .form-table .section_title td{padding:0}.wc-setup-content .form-table .section_title td h2,.wc-setup-content .form-table .section_title td p{margin:12px 0 0}.wc-setup-content .form-table td,.wc-setup-content .form-table th{padding:12px 0;margin:0;border:0}.wc-setup-content .form-table td:first-child,.wc-setup-content .form-table th:first-child{padding-left:1em}.wc-setup-content table.tax-rates{width:100%;font-size:.92em}.wc-setup-content table.tax-rates th{padding:0;text-align:center;width:auto;vertical-align:middle}.wc-setup-content table.tax-rates td{border:1px solid #f5f5f5;padding:6px;text-align:center;vertical-align:middle}.wc-setup-content table.tax-rates td input{outline:0;border:0;padding:0;box-shadow:none;text-align:center;width:100%}.wc-setup-content table.tax-rates td.sort{cursor:move;color:#ccc}.wc-setup-content table.tax-rates td.sort::before{content:'\f333';font-family:dashicons}.wc-setup-content table.tax-rates td.readonly{background:#f5f5f5}.wc-setup-content table.tax-rates .add{padding:1em 1em 0 0;line-height:1em;font-size:1em;width:0;margin:6px 0 0;height:0;overflow:hidden;position:relative;display:inline-block}.wc-setup-content table.tax-rates .add::before{content:'\f502';font-family:dashicons;position:absolute;right:0;top:0}.wc-setup-content table.tax-rates .remove{padding:1em 1em 0 0;line-height:1em;font-size:1em;width:0;margin:0;height:0;overflow:hidden;position:relative;display:inline-block}.wc-setup-content table.tax-rates .remove::before{content:'\f182';font-family:dashicons;position:absolute;right:0;top:0}.wc-setup-content .wc-setup-pages{width:100%;border-top:1px solid #eee}.wc-setup-content .wc-setup-pages thead th{display:none}.wc-setup-content .wc-setup-pages .page-name{width:30%;font-weight:700}.wc-setup-content .wc-setup-pages td,.wc-setup-content .wc-setup-pages th{padding:14px 0;border-bottom:1px solid #eee}.wc-setup-content .wc-setup-pages td:first-child,.wc-setup-content .wc-setup-pages th:first-child{padding-left:9px}.wc-setup-content .wc-setup-pages th{padding-top:0}.wc-setup-content .wc-setup-pages .page-options p{color:#777;margin:6px 24px 0 0;line-height:1.75em}.wc-setup-content .wc-setup-pages .page-options p input{vertical-align:middle;margin:1px 0 0;height:1.75em;width:1.75em;line-height:1.75em}.wc-setup-content .wc-setup-pages .page-options p label{line-height:1}@media screen and (max-width:782px){.wc-setup-content .form-table tbody th{width:auto}}.wc-setup-content .twitter-share-button{float:left}.wc-setup-content .wc-setup-next-steps{overflow:hidden;margin:0 0 24px;padding-bottom:2px}.wc-setup-content .wc-setup-next-steps h2{margin-bottom:12px}.wc-setup-content .wc-setup-next-steps .wc-setup-next-steps-first{float:right;width:50%;box-sizing:border-box}.wc-setup-content .wc-setup-next-steps .wc-setup-next-steps-last{float:left;width:50%;box-sizing:border-box}.wc-setup-content .wc-setup-next-steps ul{padding:0 0 0 2em;list-style:none outside;margin:0}.wc-setup-content .wc-setup-next-steps ul li a{display:block;padding:0 0 .75em}.wc-setup-content .wc-setup-next-steps ul .setup-product a.button{background-color:#f7f7f7;border-color:#ccc;color:#23282d;box-shadow:inset 0 1px 0 rgba(255,255,255,.25),0 1px 0 #ccc;text-shadow:-1px 0 1px #eee,0 1px 1px #eee;font-size:1em;height:auto;line-height:1.75em;margin:0 0 .75em;opacity:1;padding:1em;text-align:center}.wc-setup-content .wc-setup-next-steps ul .setup-product a.button:active,.wc-setup-content .wc-setup-next-steps ul .setup-product a.button:focus,.wc-setup-content .wc-setup-next-steps ul .setup-product a.button:hover{background:#f5f5f5;border-color:#aaa}.wc-setup-content .wc-setup-next-steps ul .setup-product a.button-primary{color:#fff;background-color:#bb77ae;border-color:#a36597;box-shadow:inset 0 1px 0 rgba(255,255,255,.25),0 1px 0 #a36597;text-shadow:0 -1px 1px #a36597,-1px 0 1px #a36597,0 1px 1px #a36597,1px 0 1px #a36597}.wc-setup-content .wc-setup-next-steps ul .setup-product a.button-primary:active,.wc-setup-content .wc-setup-next-steps ul .setup-product a.button-primary:focus,.wc-setup-content .wc-setup-next-steps ul .setup-product a.button-primary:hover{color:#fff;background:#a36597;border-color:#a36597;box-shadow:inset 0 1px 0 rgba(255,255,255,.25),0 1px 0 #a36597}.wc-setup-content .wc-setup-next-steps ul li a::before{color:#82878c;font:normal 20px/1 dashicons;speak:none;display:inline-block;padding:0 0 0 10px;top:1px;position:relative;text-decoration:none!important;vertical-align:top}.wc-setup-content .wc-setup-next-steps ul .learn-more a::before{content:'\f105'}.wc-setup-content .wc-setup-next-steps ul .video-walkthrough a::before{content:'\f126'}.wc-setup-content .wc-setup-next-steps ul .newsletter a::before{content:'\f465'}.wc-setup-content .updated,.wc-setup-content .woocommerce-newsletter{padding:24px 24px 0;margin:0 0 24px;overflow:hidden;background:#f5f5f5}.wc-setup-content .updated p,.wc-setup-content .woocommerce-newsletter p{padding:0;margin:0 0 12px}.wc-setup-content .updated form,.wc-setup-content .updated p:last-child,.wc-setup-content .woocommerce-newsletter form,.wc-setup-content .woocommerce-newsletter p:last-child{margin:0 0 24px}.wc-setup-content .woocommerce-tracker{margin:24px 0;border:1px solid #eee;padding:20px;border-radius:4px;overflow:hidden}.wc-setup-content .woocommerce-tracker p{font-size:14px;line-height:1.5em}.wc-setup-content .woocommerce-tracker .checkbox{line-height:24px;font-weight:500;font-size:1em;margin-top:0;margin-bottom:20px}.wc-setup-content .woocommerce-tracker .checkbox input[type=checkbox]{opacity:0;position:absolute;right:-9999px}.wc-setup-content .woocommerce-tracker .checkbox label{position:relative;display:inline-block;padding-right:28px}.wc-setup-content .woocommerce-tracker .checkbox label:after,.wc-setup-content .woocommerce-tracker .checkbox label:before{position:absolute;content:"";display:inline-block}.wc-setup-content .woocommerce-tracker .checkbox label:before{height:16px;width:16px;right:0;top:3px;border:1px solid #aaa;background-color:#fff;border-radius:3px}.wc-setup-content .woocommerce-tracker .checkbox label:after{height:5px;width:9px;border-right:2px solid;border-bottom:2px solid;-webkit-transform:rotate(45deg);-ms-transform:rotate(45deg);transform:rotate(45deg);right:4px;top:7px;color:#fff}.wc-setup-content .woocommerce-tracker .checkbox input[type=checkbox]+label::after{content:none}.wc-setup-content .woocommerce-tracker .checkbox input[type=checkbox]:checked+label::after{content:""}.wc-setup-content .woocommerce-tracker .checkbox input[type=checkbox]:focus+label::before{outline:#3b99fc auto 5px}.wc-setup-content .woocommerce-tracker .checkbox input[type=checkbox]:checked+label::before{background:#935687;border-color:#935687;outline:0}.wc-setup-steps{padding:0 0 24px;margin:0;list-style:none outside;overflow:hidden;color:#ccc;width:100%;display:-webkit-inline-box;display:-ms-inline-flexbox;display:inline-flex}.wc-setup-steps li{width:100%;float:right;padding:0 0 .8em;margin:0;text-align:center;position:relative;border-bottom:4px solid #ccc;line-height:1.4em}.wc-setup-steps li a{color:#a16696;text-decoration:none;padding:1.5em;margin:-1.5em;position:relative;z-index:1}.wc-setup-steps li a:focus,.wc-setup-steps li a:hover{color:#111;text-decoration:underline}.wc-setup-steps li::before{content:'';border:4px solid #ccc;border-radius:100%;width:4px;height:4px;position:absolute;bottom:0;right:50%;margin-right:-6px;margin-bottom:-8px;background:#fff}.wc-setup-steps li.active{border-color:#a16696;color:#a16696;font-weight:700}.wc-setup-steps li.active::before{border-color:#a16696}.wc-setup-steps li.done{border-color:#a16696;color:#a16696}.wc-setup-steps li.done::before{border-color:#a16696;background:#a16696}.wc-setup .wc-setup-actions{overflow:hidden;margin:20px 0 0;position:relative}.wc-setup .wc-setup-actions .button{font-size:1.25em;padding:.5em 1em;line-height:1em;margin-left:.5em;margin-bottom:2px;height:auto;border-radius:4px}.wc-setup .wc-setup-actions .button-primary{background-color:#bb77ae;border-color:#a36597;box-shadow:inset 0 1px 0 rgba(255,255,255,.25),0 1px 0 #a36597;text-shadow:0 -1px 1px #a36597,-1px 0 1px #a36597,0 1px 1px #a36597,1px 0 1px #a36597;margin:0;opacity:1}.wc-setup .wc-setup-actions .button-primary:active,.wc-setup .wc-setup-actions .button-primary:focus,.wc-setup .wc-setup-actions .button-primary:hover{background:#a36597;border-color:#a36597;box-shadow:inset 0 1px 0 rgba(255,255,255,.25),0 1px 0 #a36597}.wc-setup-content p:last-child{margin-bottom:0}.wc-setup-content p.store-setup{margin-top:0}.wc-setup-footer-links{font-size:.85em;color:#b5b5b5;margin:1.18em auto;display:inline-block;text-align:center}.wc-wizard-storefront .wc-wizard-storefront-intro{padding:40px 40px 0;background:#f5f5f5;text-align:center}.wc-wizard-storefront .wc-wizard-storefront-intro img{margin:40px 0 0 0;width:100%;display:block}.wc-wizard-storefront .wc-wizard-storefront-features{list-style:none outside;margin:0 0 20px;padding:0 30px 0 0;overflow:hidden}.wc-wizard-storefront .wc-wizard-storefront-feature{margin:0;padding:20px 2em 20px 30px;width:50%;box-sizing:border-box}.wc-wizard-storefront .wc-wizard-storefront-feature::before{margin-right:-2em;position:absolute}.wc-wizard-storefront .wc-wizard-storefront-feature.first{clear:both;float:right}.wc-wizard-storefront .wc-wizard-storefront-feature.last{float:left}.wc-wizard-storefront .wc-wizard-storefront-feature__bulletproof::before{content:'πŸ”’'}.wc-wizard-storefront .wc-wizard-storefront-feature__mobile::before{content:'πŸ“±'}.wc-wizard-storefront .wc-wizard-storefront-feature__accessibility::before{content:'πŸ‘“'}.wc-wizard-storefront .wc-wizard-storefront-feature__search::before{content:'πŸ”'}.wc-wizard-storefront .wc-wizard-storefront-feature__compatibility::before{content:'πŸ”§'}.wc-wizard-storefront .wc-wizard-storefront-feature__extendable::before{content:'🎨'}.wc-wizard-services{border:1px solid #eee;padding:0;margin:0 0 1em;list-style:none outside;border-radius:4px;overflow:hidden}.wc-wizard-services p{margin:0 0 1em 0;padding:0;font-size:1em;line-height:1.5em}.wc-wizard-service-item,.wc-wizard-services-list-toggle{display:-webkit-box;display:-ms-flexbox;display:flex;-ms-flex-wrap:nowrap;flex-wrap:nowrap;-webkit-box-pack:justify;-ms-flex-pack:justify;justify-content:space-between;padding:0;border-bottom:1px solid #eee;color:#666;-webkit-box-align:center;-ms-flex-align:center;align-items:center}.wc-wizard-service-item:last-child,.wc-wizard-services-list-toggle:last-child{border-bottom:0}.wc-wizard-service-item .payment-gateway-fee,.wc-wizard-services-list-toggle .payment-gateway-fee{color:#a6a6a6}.wc-wizard-service-item .wc-wizard-service-name,.wc-wizard-services-list-toggle .wc-wizard-service-name{-ms-flex-preferred-size:0;flex-basis:0;min-width:160px;text-align:center;font-weight:700;padding:2em 0;-ms-flex-item-align:stretch;align-self:stretch;display:-webkit-box;display:-ms-flexbox;display:flex;-webkit-box-align:baseline;-ms-flex-align:baseline;align-items:baseline}.wc-wizard-payment-gateway-form .wc-wizard-service-item .wc-wizard-service-name,.wc-wizard-payment-gateway-form .wc-wizard-services-list-toggle .wc-wizard-service-name{-webkit-box-pack:center;-ms-flex-pack:center;justify-content:center}.wc-wizard-service-item .wc-wizard-service-name img,.wc-wizard-services-list-toggle .wc-wizard-service-name img{max-width:75px}.wc-wizard-service-item.stripe-logo .wc-wizard-service-name img,.wc-wizard-services-list-toggle.stripe-logo .wc-wizard-service-name img{padding:8px 0}.wc-wizard-service-item.paypal-logo .wc-wizard-service-name img,.wc-wizard-services-list-toggle.paypal-logo .wc-wizard-service-name img{max-width:87px;padding:2px 0}.wc-wizard-service-item.klarna-logo .wc-wizard-service-name,.wc-wizard-services-list-toggle.klarna-logo .wc-wizard-service-name{background:#000}.wc-wizard-service-item.klarna-logo .wc-wizard-service-name img,.wc-wizard-services-list-toggle.klarna-logo .wc-wizard-service-name img{max-width:87px;padding:12px 0}.wc-wizard-service-item.square-logo .wc-wizard-service-name,.wc-wizard-services-list-toggle.square-logo .wc-wizard-service-name{background:#000}.wc-wizard-service-item.square-logo .wc-wizard-service-name img,.wc-wizard-services-list-toggle.square-logo .wc-wizard-service-name img{max-width:95px;padding:12px 0}.wc-wizard-service-item .wc-wizard-service-description,.wc-wizard-services-list-toggle .wc-wizard-service-description{-webkit-box-flex:1;-ms-flex-positive:1;flex-grow:1;padding:20px}.wc-wizard-service-item .wc-wizard-service-description p,.wc-wizard-services-list-toggle .wc-wizard-service-description p{margin-bottom:1em}.wc-wizard-service-item .wc-wizard-service-description p:last-child,.wc-wizard-services-list-toggle .wc-wizard-service-description p:last-child{margin-bottom:0}.wc-wizard-service-item .wc-wizard-service-description .wc-wizard-service-settings-description,.wc-wizard-services-list-toggle .wc-wizard-service-description .wc-wizard-service-settings-description{display:block;font-style:italic;color:#999}.wc-wizard-service-item .wc-wizard-service-enable,.wc-wizard-services-list-toggle .wc-wizard-service-enable{-ms-flex-preferred-size:0;flex-basis:0;min-width:75px;text-align:center;cursor:pointer;padding:2em 0;position:relative;max-height:1.5em;-ms-flex-item-align:start;align-self:flex-start}.wc-wizard-service-item .wc-wizard-service-toggle,.wc-wizard-services-list-toggle .wc-wizard-service-toggle{height:16px;width:32px;border:2px solid #935687;background-color:#935687;display:inline-block;text-indent:-9999px;border-radius:10em;position:relative}.wc-wizard-service-item .wc-wizard-service-toggle input[type=checkbox],.wc-wizard-services-list-toggle .wc-wizard-service-toggle input[type=checkbox]{display:none}.wc-wizard-service-item .wc-wizard-service-toggle:before,.wc-wizard-services-list-toggle .wc-wizard-service-toggle:before{content:"";display:block;width:16px;height:16px;background:#fff;position:absolute;top:0;left:0;border-radius:100%}.wc-wizard-service-item .wc-wizard-service-toggle.disabled,.wc-wizard-services-list-toggle .wc-wizard-service-toggle.disabled{border-color:#999;background-color:#999}.wc-wizard-service-item .wc-wizard-service-toggle.disabled:before,.wc-wizard-services-list-toggle .wc-wizard-service-toggle.disabled:before{left:auto;right:0}.wc-wizard-service-item .wc-wizard-service-settings,.wc-wizard-services-list-toggle .wc-wizard-service-settings{display:none;margin-bottom:0;cursor:default}.wc-wizard-service-item .wc-wizard-service-settings.hide,.wc-wizard-services-list-toggle .wc-wizard-service-settings.hide{display:none}.wc-wizard-service-item.checked .wc-wizard-service-settings,.wc-wizard-services-list-toggle.checked .wc-wizard-service-settings{display:inline-block}.wc-wizard-service-item.checked .wc-wizard-service-settings.hide,.wc-wizard-services-list-toggle.checked .wc-wizard-service-settings.hide{display:none}.wc-wizard-service-item.closed,.wc-wizard-services-list-toggle.closed{border-bottom:0}.wc-wizard-services-list-toggle{cursor:pointer}.wc-wizard-services-list-toggle .wc-wizard-service-enable::before{content:"\f343";font-family:dashicons;visibility:initial;color:#666;font-size:25px;margin-top:-7px;margin-right:-5px;position:absolute;visibility:visible}.wc-wizard-services-list-toggle.closed .wc-wizard-service-enable::before{content:"\f347"}.wc-wizard-services-list-toggle .wc-wizard-service-enable input{visibility:hidden;position:relative}.wc-wizard-services.manual .wc-wizard-service-item{display:none}.wc-wizard-services.shipping .wc-wizard-service-name{font-weight:400;text-align:right;-webkit-box-align:center;-ms-flex-align:center;align-items:center;max-height:5em;padding:0}.wc-wizard-services.shipping .wc-wizard-service-item{padding-right:2em;padding-top:.67em}.wc-wizard-services.shipping .wc-wizard-service-item:first-child{border-bottom:0;padding-bottom:0;font-weight:700}.wc-wizard-services.shipping .wc-wizard-service-item:first-child .wc-wizard-service-name{font-weight:700}.wc-wizard-services.shipping .shipping-method-setting,.wc-wizard-services.shipping .wc-wizard-shipping-method-select{display:-webkit-box;display:-ms-flexbox;display:flex}.wc-wizard-services.shipping .shipping-method-setting.hide,.wc-wizard-services.shipping .wc-wizard-shipping-method-select.hide{display:none}.wc-wizard-services.shipping .shipping-method-setting input,.wc-wizard-services.shipping .wc-wizard-shipping-method-dropdown{margin-left:2em;margin-bottom:1em}.wc-wizard-services.shipping .shipping-method-setting input .select2,.wc-wizard-services.shipping .wc-wizard-shipping-method-dropdown .select2{min-width:130px}.wc-wizard-services.shipping .wc-wizard-service-description{display:-webkit-box;display:-ms-flexbox;display:flex;-webkit-box-orient:vertical;-webkit-box-direction:normal;-ms-flex-direction:column;flex-direction:column;color:#a6a6a6}.wc-wizard-services.shipping .wc-wizard-service-item:not(:first-child) .wc-wizard-service-description{font-size:.92em;padding-bottom:10px}.wc-wizard-services.shipping .shipping-method-setting input{width:95px;border:1px solid #aaa;border-color:#ddd;border-radius:4px;height:28px;padding-right:8px;padding-left:24px;font-size:14px;color:#444;background-color:#fff;display:inline-block}.wc-wizard-services.shipping .shipping-method-description,.wc-wizard-services.shipping .shipping-method-setting .description{color:#7e7e7e;font-size:.9em}.wc-wizard-services.shipping .shipping-method-setting input::-webkit-input-placeholder{color:#e1e1e1}.wc-wizard-services.shipping .shipping-method-setting input::-moz-placeholder{color:#e1e1e1}.wc-wizard-services.shipping .shipping-method-setting input:-ms-input-placeholder{color:#e1e1e1}.wc-wizard-services.shipping .shipping-method-setting input::placeholder{color:#e1e1e1}.wc-setup-shipping-units p{line-height:1.5em;font-size:13px;margin-bottom:.25em}.wc-setup-shipping-units .wc-setup-shipping-unit{margin-bottom:1.75em}.wc-setup-shipping-units .wc-setup-shipping-unit .select2{min-width:100%}.hide{display:none}.wc-wizard-features{display:-webkit-box;display:-ms-flexbox;display:flex;-ms-flex-wrap:wrap;flex-wrap:wrap;list-style:none;padding:0}.wc-wizard-features .wc-wizard-feature-item{-ms-flex-preferred-size:calc(50% - 4em - 3px);flex-basis:calc(50% - 4em - 3px);border:1px solid #eee;padding:2em}.wc-wizard-features .wc-wizard-feature-item:nth-child(1){border-radius:0 4px 0 0}.wc-wizard-features .wc-wizard-feature-item:nth-child(2){border-right:0;border-radius:4px 0 0 0}.wc-wizard-features .wc-wizard-feature-item:nth-child(3){border-top:0;border-radius:0 0 4px 0}.wc-wizard-features .wc-wizard-feature-item:nth-child(4){border-top:0;border-right:0;border-radius:0 0 0 4px}.wc-wizard-features p.wc-wizard-feature-description,.wc-wizard-features p.wc-wizard-feature-name{margin:0;line-height:1.5em}h3.jetpack-reasons{text-align:center;margin:3em 0 1em 0;font-size:14px}.jetpack-logo,.wcs-notice{display:block;margin:1.75em auto 2em auto;max-height:175px}.activate-splash .jetpack-logo{width:170px;margin-bottom:0}.activate-splash .wcs-notice{margin-top:1em;padding-right:57px}.step{text-align:center}.wc-setup .wc-setup-actions .button{font-weight:300;font-size:16px;padding:1em 2em;box-shadow:none;min-width:12em;min-width:auto;margin-top:10px}.wc-setup .wc-setup-actions .button:active,.wc-setup .wc-setup-actions .button:focus,.wc-setup .wc-setup-actions .button:hover{box-shadow:none}.location-prompt{color:#666;font-size:13px;font-weight:500;margin-bottom:.5em;margin-top:.85em;display:inline-block}.location-input{border:1px solid #aaa;border-color:#ddd;border-radius:4px;height:30px;width:calc(100% - 8px - 24px - 2px);padding-right:8px;padding-left:24px;font-size:16px;color:#444;background-color:#fff;display:inline-block}.location-input.dropdown{width:100%}.address-step .select2{min-width:100%}.store-address-container .city-and-postcode{display:-webkit-box;display:-ms-flexbox;display:flex}.store-address-container .city-and-postcode div{-ms-flex-preferred-size:50%;flex-basis:50%;margin-left:1em}.store-address-container .city-and-postcode div:last-of-type{margin-left:0}.store-address-container .select2-container,.store-address-container input[type=text],.store-address-container select{margin-bottom:10px}.product-type-container{margin-top:14px;margin-bottom:1px}#woocommerce_sell_in_person{margin-right:0}.wc-wizard-service-settings .payment-email-input{border:1px solid #aaa;border-color:#ddd;border-radius:4px;height:30px;padding:0 8px;font-size:14px;color:#444;background-color:#fff;display:inline-block}.newsletter-form-container{display:-webkit-box;display:-ms-flexbox;display:flex}.newsletter-form-container .newsletter-form-email{border:1px solid #aaa;border-color:#ddd;border-radius:4px;height:42px;padding:0 8px;font-size:16px;color:#666;background-color:#fff;display:inline-block;margin-left:6px;-webkit-box-flex:1;-ms-flex-positive:1;flex-grow:1}.newsletter-form-container .newsletter-form-button-container{-webkit-box-flex:0;-ms-flex-positive:0;flex-grow:0}.wc-setup .wc-setup-actions .button.newsletter-form-button{height:42px;padding:0 1em;margin:0}.wc-wizard-next-steps{border:1px solid #eee;border-radius:4px;list-style:none;padding:0}.wc-wizard-next-steps li{padding:0}.wc-wizard-next-steps .wc-wizard-next-step-item{display:-webkit-box;display:-ms-flexbox;display:flex;border-top:1px solid #eee}.wc-wizard-next-steps .wc-wizard-next-step-item:first-child{border-top:0}.wc-wizard-next-steps .wc-wizard-next-step-description{-webkit-box-flex:1;-ms-flex-positive:1;flex-grow:1;margin:1.5em}.wc-wizard-next-steps .wc-wizard-next-step-action{-webkit-box-flex:0;-ms-flex-positive:0;flex-grow:0;display:-webkit-box;display:-ms-flexbox;display:flex;-webkit-box-align:center;-ms-flex-align:center;align-items:center}.wc-wizard-next-steps .wc-wizard-next-step-action .button{margin:1em 1.5em}.wc-wizard-next-steps p.next-step-heading{margin:0;font-size:.95em;font-weight:400;font-variant:all-petite-caps}.wc-wizard-next-steps p.next-step-extra-info{margin:0}.wc-wizard-next-steps h3.next-step-description{margin:0;font-size:16px;font-weight:600}.wc-wizard-next-steps .wc-wizard-additional-steps{border-top:1px solid #eee}.wc-wizard-next-steps .wc-wizard-additional-steps .wc-wizard-next-step-description{margin-bottom:0}.wc-wizard-next-steps .wc-wizard-additional-steps .wc-setup-actions{margin:0 0 1.5em 0}.wc-wizard-next-steps .wc-wizard-additional-steps .wc-setup-actions .button{font-size:15px;margin:1em 1.5em 1em 0}.wc-wizard-next-steps .wc-wizard-additional-steps .wc-setup-actions .button::last-child{margin-left:1.5em}p.next-steps-help-text{color:#9f9f9f;padding:0 2em;text-align:center;font-size:.9em}p.jetpack-terms{font-size:.8em;text-align:center;max-width:480px;margin:0 auto;line-height:1.5em}.woocommerce-error{background:#ffe6e5;border-color:#ffc5c2;padding:1em;margin-bottom:1em}.woocommerce-error p{margin-top:0;margin-bottom:.5em;color:#444}.woocommerce-error a{color:#ff645c}.woocommerce-error .reconnect-reminder{font-size:.85em}.woocommerce-error .wc-setup-actions .button{font-size:14px}.wc-wizard-service-setting-ppec_paypal_reroute_requests,.wc-wizard-service-setting-stripe_create_account{display:-webkit-box;display:-ms-flexbox;display:flex;-webkit-box-align:start;-ms-flex-align:start;align-items:flex-start;margin-top:.75em}.wc-wizard-service-setting-ppec_paypal_reroute_requests .payment-checkbox-input,.wc-wizard-service-setting-stripe_create_account .payment-checkbox-input{-webkit-box-ordinal-group:2;-ms-flex-order:1;order:1;margin-top:5px;margin-right:0;margin-left:0;width:1.5em}.wc-wizard-service-setting-ppec_paypal_reroute_requests .ppec_paypal_reroute_requests,.wc-wizard-service-setting-ppec_paypal_reroute_requests .stripe_create_account,.wc-wizard-service-setting-stripe_create_account .ppec_paypal_reroute_requests,.wc-wizard-service-setting-stripe_create_account .stripe_create_account{-webkit-box-ordinal-group:3;-ms-flex-order:2;order:2;margin-right:.3em}.wc-wizard-service-setting-ppec_paypal_email,.wc-wizard-service-setting-stripe_email{margin-top:.75em}.wc-wizard-service-setting-ppec_paypal_email label.ppec_paypal_email,.wc-wizard-service-setting-ppec_paypal_email label.stripe_email,.wc-wizard-service-setting-stripe_email label.ppec_paypal_email,.wc-wizard-service-setting-stripe_email label.stripe_email{position:absolute;margin:-1px;padding:0;height:1px;width:1px;overflow:hidden;clip:rect(0 0 0 0);border:0}.wc-wizard-service-setting-ppec_paypal_email input.payment-email-input,.wc-wizard-service-setting-stripe_email input.payment-email-input{margin-right:1.5em;margin-bottom:.5em;width:100%}.wc-wizard-service-setting-ppec_paypal_email .wc-wizard-service-settings-description,.wc-wizard-service-setting-stripe_email .wc-wizard-service-settings-description{margin-right:1.5em}.recommended-step{border:1px solid #ebebeb;border-radius:4px;padding:2.5em}.recommended-step li{list-style:none}.recommended-step li:last-child .recommended-item{margin-bottom:0}.recommended-step .recommended-item{display:-webkit-box;display:-ms-flexbox;display:flex;-webkit-box-align:center;-ms-flex-align:center;align-items:center;margin-bottom:1.5em}.recommended-step .recommended-item-icon{border:1px solid #fff;border-radius:7px;height:3.5em;margin-left:1em;margin-right:1em}.recommended-step .recommended-item-icon.recommended-item-icon-storefront_theme{background-color:#f4a224;max-height:3em;max-width:3em;padding:.25em}.recommended-step .recommended-item-icon.recommended-item-icon-automated_taxes{background-color:#d0011b;max-height:1.75em;padding:.875em}.recommended-step .recommended-item-description-container h3{font-size:15px;font-weight:700;letter-spacing:.5px;margin-bottom:0}.recommended-step .recommended-item-description-container p{margin-top:0;line-height:1.5em} \ No newline at end of file +@charset "UTF-8";body{margin:65px auto 24px;box-shadow:none;background:#f1f1f1;padding:0}#wc-logo{border:0;margin:0 0 24px;padding:0;text-align:center}#wc-logo img{max-width:30%}.wc-setup{text-align:center}.wc-setup .select2-container{text-align:right}.wc-setup .hidden{display:none}.wc-setup-content{box-shadow:0 1px 3px rgba(0,0,0,.13);padding:2em;margin:0 0 20px;background:#fff;overflow:hidden;zoom:1;text-align:right}.wc-setup-content h1,.wc-setup-content h2,.wc-setup-content h3,.wc-setup-content table{margin:0 0 20px;border:0;padding:0;color:#666;clear:none;font-weight:500}.wc-setup-content p{margin:20px 0;font-size:1em;line-height:1.75em;color:#666}.wc-setup-content table{font-size:1em;line-height:1.75em;color:#666}.wc-setup-content a{color:#a16696}.wc-setup-content a:focus,.wc-setup-content a:hover{color:#111}.wc-setup-content .form-table th{width:35%;vertical-align:top;font-weight:400}.wc-setup-content .form-table td{vertical-align:top}.wc-setup-content .form-table td input,.wc-setup-content .form-table td select{width:100%;box-sizing:border-box}.wc-setup-content .form-table td input[size]{width:auto}.wc-setup-content .form-table td .description{line-height:1.5em;display:block;margin-top:.25em;color:#999;font-style:italic}.wc-setup-content .form-table td .input-checkbox,.wc-setup-content .form-table td .input-radio{width:auto;box-sizing:inherit;padding:inherit;margin:0 0 0 .5em;box-shadow:none}.wc-setup-content .form-table .section_title td{padding:0}.wc-setup-content .form-table .section_title td h2,.wc-setup-content .form-table .section_title td p{margin:12px 0 0}.wc-setup-content .form-table td,.wc-setup-content .form-table th{padding:12px 0;margin:0;border:0}.wc-setup-content .form-table td:first-child,.wc-setup-content .form-table th:first-child{padding-left:1em}.wc-setup-content table.tax-rates{width:100%;font-size:.92em}.wc-setup-content table.tax-rates th{padding:0;text-align:center;width:auto;vertical-align:middle}.wc-setup-content table.tax-rates td{border:1px solid #f5f5f5;padding:6px;text-align:center;vertical-align:middle}.wc-setup-content table.tax-rates td input{outline:0;border:0;padding:0;box-shadow:none;text-align:center;width:100%}.wc-setup-content table.tax-rates td.sort{cursor:move;color:#ccc}.wc-setup-content table.tax-rates td.sort::before{content:'\f333';font-family:dashicons}.wc-setup-content table.tax-rates td.readonly{background:#f5f5f5}.wc-setup-content table.tax-rates .add{padding:1em 1em 0 0;line-height:1em;font-size:1em;width:0;margin:6px 0 0;height:0;overflow:hidden;position:relative;display:inline-block}.wc-setup-content table.tax-rates .add::before{content:'\f502';font-family:dashicons;position:absolute;right:0;top:0}.wc-setup-content table.tax-rates .remove{padding:1em 1em 0 0;line-height:1em;font-size:1em;width:0;margin:0;height:0;overflow:hidden;position:relative;display:inline-block}.wc-setup-content table.tax-rates .remove::before{content:'\f182';font-family:dashicons;position:absolute;right:0;top:0}.wc-setup-content .wc-setup-pages{width:100%;border-top:1px solid #eee}.wc-setup-content .wc-setup-pages thead th{display:none}.wc-setup-content .wc-setup-pages .page-name{width:30%;font-weight:700}.wc-setup-content .wc-setup-pages td,.wc-setup-content .wc-setup-pages th{padding:14px 0;border-bottom:1px solid #eee}.wc-setup-content .wc-setup-pages td:first-child,.wc-setup-content .wc-setup-pages th:first-child{padding-left:9px}.wc-setup-content .wc-setup-pages th{padding-top:0}.wc-setup-content .wc-setup-pages .page-options p{color:#777;margin:6px 24px 0 0;line-height:1.75em}.wc-setup-content .wc-setup-pages .page-options p input{vertical-align:middle;margin:1px 0 0;height:1.75em;width:1.75em;line-height:1.75em}.wc-setup-content .wc-setup-pages .page-options p label{line-height:1}@media screen and (max-width:782px){.wc-setup-content .form-table tbody th{width:auto}}.wc-setup-content .twitter-share-button{float:left}.wc-setup-content .wc-setup-next-steps{overflow:hidden;margin:0 0 24px;padding-bottom:2px}.wc-setup-content .wc-setup-next-steps h2{margin-bottom:12px}.wc-setup-content .wc-setup-next-steps .wc-setup-next-steps-first{float:right;width:50%;box-sizing:border-box}.wc-setup-content .wc-setup-next-steps .wc-setup-next-steps-last{float:left;width:50%;box-sizing:border-box}.wc-setup-content .wc-setup-next-steps ul{padding:0 0 0 2em;list-style:none outside;margin:0}.wc-setup-content .wc-setup-next-steps ul li a{display:block;padding:0 0 .75em}.wc-setup-content .wc-setup-next-steps ul .setup-product a.button{background-color:#f7f7f7;border-color:#ccc;color:#23282d;box-shadow:inset 0 1px 0 rgba(255,255,255,.25),0 1px 0 #ccc;text-shadow:-1px 0 1px #eee,0 1px 1px #eee;font-size:1em;height:auto;line-height:1.75em;margin:0 0 .75em;opacity:1;padding:1em;text-align:center}.wc-setup-content .wc-setup-next-steps ul .setup-product a.button:active,.wc-setup-content .wc-setup-next-steps ul .setup-product a.button:focus,.wc-setup-content .wc-setup-next-steps ul .setup-product a.button:hover{background:#f5f5f5;border-color:#aaa}.wc-setup-content .wc-setup-next-steps ul .setup-product a.button-primary{color:#fff;background-color:#bb77ae;border-color:#a36597;box-shadow:inset 0 1px 0 rgba(255,255,255,.25),0 1px 0 #a36597;text-shadow:0 -1px 1px #a36597,-1px 0 1px #a36597,0 1px 1px #a36597,1px 0 1px #a36597}.wc-setup-content .wc-setup-next-steps ul .setup-product a.button-primary:active,.wc-setup-content .wc-setup-next-steps ul .setup-product a.button-primary:focus,.wc-setup-content .wc-setup-next-steps ul .setup-product a.button-primary:hover{color:#fff;background:#a36597;border-color:#a36597;box-shadow:inset 0 1px 0 rgba(255,255,255,.25),0 1px 0 #a36597}.wc-setup-content .wc-setup-next-steps ul li a::before{color:#82878c;font:normal 20px/1 dashicons;speak:none;display:inline-block;padding:0 0 0 10px;top:1px;position:relative;text-decoration:none!important;vertical-align:top}.wc-setup-content .wc-setup-next-steps ul .learn-more a::before{content:'\f105'}.wc-setup-content .wc-setup-next-steps ul .video-walkthrough a::before{content:'\f126'}.wc-setup-content .wc-setup-next-steps ul .newsletter a::before{content:'\f465'}.wc-setup-content .updated,.wc-setup-content .woocommerce-newsletter{padding:24px 24px 0;margin:0 0 24px;overflow:hidden;background:#f5f5f5}.wc-setup-content .updated p,.wc-setup-content .woocommerce-newsletter p{padding:0;margin:0 0 12px}.wc-setup-content .updated form,.wc-setup-content .updated p:last-child,.wc-setup-content .woocommerce-newsletter form,.wc-setup-content .woocommerce-newsletter p:last-child{margin:0 0 24px}.wc-setup-content .woocommerce-tracker{margin:24px 0;border:1px solid #eee;padding:20px;border-radius:4px;overflow:hidden}.wc-setup-content .woocommerce-tracker p{font-size:14px;line-height:1.5em}.wc-setup-content .woocommerce-tracker .checkbox{line-height:24px;font-weight:500;font-size:1em;margin-top:0;margin-bottom:20px}.wc-setup-content .woocommerce-tracker .checkbox input[type=checkbox]{opacity:0;position:absolute;right:-9999px}.wc-setup-content .woocommerce-tracker .checkbox label{position:relative;display:inline-block;padding-right:28px}.wc-setup-content .woocommerce-tracker .checkbox label:after,.wc-setup-content .woocommerce-tracker .checkbox label:before{position:absolute;content:"";display:inline-block}.wc-setup-content .woocommerce-tracker .checkbox label:before{height:16px;width:16px;right:0;top:3px;border:1px solid #aaa;background-color:#fff;border-radius:3px}.wc-setup-content .woocommerce-tracker .checkbox label:after{height:5px;width:9px;border-right:2px solid;border-bottom:2px solid;-webkit-transform:rotate(45deg);-ms-transform:rotate(45deg);transform:rotate(45deg);right:4px;top:7px;color:#fff}.wc-setup-content .woocommerce-tracker .checkbox input[type=checkbox]+label::after{content:none}.wc-setup-content .woocommerce-tracker .checkbox input[type=checkbox]:checked+label::after{content:""}.wc-setup-content .woocommerce-tracker .checkbox input[type=checkbox]:focus+label::before{outline:#3b99fc auto 5px}.wc-setup-content .woocommerce-tracker .checkbox input[type=checkbox]:checked+label::before{background:#935687;border-color:#935687;outline:0}.wc-setup-steps{padding:0 0 24px;margin:0;list-style:none outside;overflow:hidden;color:#ccc;width:100%;display:-webkit-inline-box;display:-ms-inline-flexbox;display:inline-flex}.wc-setup-steps li{width:100%;float:right;padding:0 0 .8em;margin:0;text-align:center;position:relative;border-bottom:4px solid #ccc;line-height:1.4em}.wc-setup-steps li a{color:#a16696;text-decoration:none;padding:1.5em;margin:-1.5em;position:relative;z-index:1}.wc-setup-steps li a:focus,.wc-setup-steps li a:hover{color:#111;text-decoration:underline}.wc-setup-steps li::before{content:'';border:4px solid #ccc;border-radius:100%;width:4px;height:4px;position:absolute;bottom:0;right:50%;margin-right:-6px;margin-bottom:-8px;background:#fff}.wc-setup-steps li.active{border-color:#a16696;color:#a16696;font-weight:700}.wc-setup-steps li.active::before{border-color:#a16696}.wc-setup-steps li.done{border-color:#a16696;color:#a16696}.wc-setup-steps li.done::before{border-color:#a16696;background:#a16696}.wc-setup .wc-setup-actions{overflow:hidden;margin:20px 0 0;position:relative}.wc-setup .wc-setup-actions .button{font-size:1.25em;padding:.5em 1em;line-height:1em;margin-left:.5em;margin-bottom:2px;height:auto;border-radius:4px}.wc-setup .wc-setup-actions .button-primary{background-color:#bb77ae;border-color:#a36597;box-shadow:inset 0 1px 0 rgba(255,255,255,.25),0 1px 0 #a36597;text-shadow:0 -1px 1px #a36597,-1px 0 1px #a36597,0 1px 1px #a36597,1px 0 1px #a36597;margin:0;opacity:1}.wc-setup .wc-setup-actions .button-primary:active,.wc-setup .wc-setup-actions .button-primary:focus,.wc-setup .wc-setup-actions .button-primary:hover{background:#a36597;border-color:#a36597;box-shadow:inset 0 1px 0 rgba(255,255,255,.25),0 1px 0 #a36597}.wc-setup-content p:last-child{margin-bottom:0}.wc-setup-content p.store-setup{margin-top:0}.wc-setup-footer-links{font-size:.85em;color:#b5b5b5;margin:1.18em auto;display:inline-block;text-align:center}.wc-wizard-storefront .wc-wizard-storefront-intro{padding:40px 40px 0;background:#f5f5f5;text-align:center}.wc-wizard-storefront .wc-wizard-storefront-intro img{margin:40px 0 0 0;width:100%;display:block}.wc-wizard-storefront .wc-wizard-storefront-features{list-style:none outside;margin:0 0 20px;padding:0 30px 0 0;overflow:hidden}.wc-wizard-storefront .wc-wizard-storefront-feature{margin:0;padding:20px 2em 20px 30px;width:50%;box-sizing:border-box}.wc-wizard-storefront .wc-wizard-storefront-feature::before{margin-right:-2em;position:absolute}.wc-wizard-storefront .wc-wizard-storefront-feature.first{clear:both;float:right}.wc-wizard-storefront .wc-wizard-storefront-feature.last{float:left}.wc-wizard-storefront .wc-wizard-storefront-feature__bulletproof::before{content:'πŸ”’'}.wc-wizard-storefront .wc-wizard-storefront-feature__mobile::before{content:'πŸ“±'}.wc-wizard-storefront .wc-wizard-storefront-feature__accessibility::before{content:'πŸ‘“'}.wc-wizard-storefront .wc-wizard-storefront-feature__search::before{content:'πŸ”'}.wc-wizard-storefront .wc-wizard-storefront-feature__compatibility::before{content:'πŸ”§'}.wc-wizard-storefront .wc-wizard-storefront-feature__extendable::before{content:'🎨'}.wc-wizard-services{border:1px solid #eee;padding:0;margin:0 0 1em;list-style:none outside;border-radius:4px;overflow:hidden}.wc-wizard-services p{margin:0 0 1em 0;padding:0;font-size:1em;line-height:1.5em}.wc-wizard-service-item,.wc-wizard-services-list-toggle{display:-webkit-box;display:-ms-flexbox;display:flex;-ms-flex-wrap:nowrap;flex-wrap:nowrap;-webkit-box-pack:justify;-ms-flex-pack:justify;justify-content:space-between;padding:0;border-bottom:1px solid #eee;color:#666;-webkit-box-align:center;-ms-flex-align:center;align-items:center}.wc-wizard-service-item:last-child,.wc-wizard-services-list-toggle:last-child{border-bottom:0}.wc-wizard-service-item .payment-gateway-fee,.wc-wizard-services-list-toggle .payment-gateway-fee{color:#a6a6a6}.wc-wizard-service-item .wc-wizard-service-name,.wc-wizard-services-list-toggle .wc-wizard-service-name{-ms-flex-preferred-size:0;flex-basis:0;min-width:160px;text-align:center;font-weight:700;padding:2em 0;-ms-flex-item-align:stretch;align-self:stretch;display:-webkit-box;display:-ms-flexbox;display:flex;-webkit-box-align:baseline;-ms-flex-align:baseline;align-items:baseline}.wc-wizard-payment-gateway-form .wc-wizard-service-item .wc-wizard-service-name,.wc-wizard-payment-gateway-form .wc-wizard-services-list-toggle .wc-wizard-service-name{-webkit-box-pack:center;-ms-flex-pack:center;justify-content:center}.wc-wizard-service-item .wc-wizard-service-name img,.wc-wizard-services-list-toggle .wc-wizard-service-name img{max-width:75px}.wc-wizard-service-item.stripe-logo .wc-wizard-service-name img,.wc-wizard-services-list-toggle.stripe-logo .wc-wizard-service-name img{padding:8px 0}.wc-wizard-service-item.paypal-logo .wc-wizard-service-name img,.wc-wizard-services-list-toggle.paypal-logo .wc-wizard-service-name img{max-width:87px;padding:2px 0}.wc-wizard-service-item.klarna-logo .wc-wizard-service-name,.wc-wizard-services-list-toggle.klarna-logo .wc-wizard-service-name{background:#000}.wc-wizard-service-item.klarna-logo .wc-wizard-service-name img,.wc-wizard-services-list-toggle.klarna-logo .wc-wizard-service-name img{max-width:87px;padding:12px 0}.wc-wizard-service-item.square-logo .wc-wizard-service-name,.wc-wizard-services-list-toggle.square-logo .wc-wizard-service-name{background:#000}.wc-wizard-service-item.square-logo .wc-wizard-service-name img,.wc-wizard-services-list-toggle.square-logo .wc-wizard-service-name img{max-width:95px;padding:12px 0}.wc-wizard-service-item .wc-wizard-service-description,.wc-wizard-services-list-toggle .wc-wizard-service-description{-webkit-box-flex:1;-ms-flex-positive:1;flex-grow:1;padding:20px}.wc-wizard-service-item .wc-wizard-service-description p,.wc-wizard-services-list-toggle .wc-wizard-service-description p{margin-bottom:1em}.wc-wizard-service-item .wc-wizard-service-description p:last-child,.wc-wizard-services-list-toggle .wc-wizard-service-description p:last-child{margin-bottom:0}.wc-wizard-service-item .wc-wizard-service-description .wc-wizard-service-settings-description,.wc-wizard-services-list-toggle .wc-wizard-service-description .wc-wizard-service-settings-description{display:block;font-style:italic;color:#999}.wc-wizard-service-item .wc-wizard-service-enable,.wc-wizard-services-list-toggle .wc-wizard-service-enable{-ms-flex-preferred-size:0;flex-basis:0;min-width:75px;text-align:center;cursor:pointer;padding:2em 0;position:relative;max-height:1.5em;-ms-flex-item-align:start;align-self:flex-start}.wc-wizard-service-item .wc-wizard-service-toggle,.wc-wizard-services-list-toggle .wc-wizard-service-toggle{height:16px;width:32px;border:2px solid #935687;background-color:#935687;display:inline-block;text-indent:-9999px;border-radius:10em;position:relative}.wc-wizard-service-item .wc-wizard-service-toggle input[type=checkbox],.wc-wizard-services-list-toggle .wc-wizard-service-toggle input[type=checkbox]{display:none}.wc-wizard-service-item .wc-wizard-service-toggle:before,.wc-wizard-services-list-toggle .wc-wizard-service-toggle:before{content:"";display:block;width:16px;height:16px;background:#fff;position:absolute;top:0;left:0;border-radius:100%}.wc-wizard-service-item .wc-wizard-service-toggle.disabled,.wc-wizard-services-list-toggle .wc-wizard-service-toggle.disabled{border-color:#999;background-color:#999}.wc-wizard-service-item .wc-wizard-service-toggle.disabled:before,.wc-wizard-services-list-toggle .wc-wizard-service-toggle.disabled:before{left:auto;right:0}.wc-wizard-service-item .wc-wizard-service-settings,.wc-wizard-services-list-toggle .wc-wizard-service-settings{display:none;margin-bottom:0;cursor:default}.wc-wizard-service-item .wc-wizard-service-settings.hide,.wc-wizard-services-list-toggle .wc-wizard-service-settings.hide{display:none}.wc-wizard-service-item.checked .wc-wizard-service-settings,.wc-wizard-services-list-toggle.checked .wc-wizard-service-settings{display:inline-block}.wc-wizard-service-item.checked .wc-wizard-service-settings.hide,.wc-wizard-services-list-toggle.checked .wc-wizard-service-settings.hide{display:none}.wc-wizard-service-item.closed,.wc-wizard-services-list-toggle.closed{border-bottom:0}.wc-wizard-services-list-toggle{cursor:pointer}.wc-wizard-services-list-toggle .wc-wizard-service-enable::before{content:"\f343";font-family:dashicons;visibility:initial;color:#666;font-size:25px;margin-top:-7px;margin-right:-5px;position:absolute;visibility:visible}.wc-wizard-services-list-toggle.closed .wc-wizard-service-enable::before{content:"\f347"}.wc-wizard-services-list-toggle .wc-wizard-service-enable input{visibility:hidden;position:relative}.wc-wizard-services.manual .wc-wizard-service-item{display:none}.wc-wizard-services.shipping .wc-wizard-service-name{font-weight:400;text-align:right;-webkit-box-align:center;-ms-flex-align:center;align-items:center;max-height:5em;padding:0}.wc-wizard-services.shipping .wc-wizard-service-item{padding-right:2em;padding-top:.67em}.wc-wizard-services.shipping .wc-wizard-service-item:first-child{border-bottom:0;padding-bottom:0;font-weight:700}.wc-wizard-services.shipping .wc-wizard-service-item:first-child .wc-wizard-service-name{font-weight:700}.wc-wizard-services.shipping .shipping-method-setting,.wc-wizard-services.shipping .wc-wizard-shipping-method-select{display:-webkit-box;display:-ms-flexbox;display:flex}.wc-wizard-services.shipping .shipping-method-setting.hide,.wc-wizard-services.shipping .wc-wizard-shipping-method-select.hide{display:none}.wc-wizard-services.shipping .shipping-method-setting input,.wc-wizard-services.shipping .wc-wizard-shipping-method-dropdown{margin-left:2em;margin-bottom:1em}.wc-wizard-services.shipping .shipping-method-setting input .select2,.wc-wizard-services.shipping .wc-wizard-shipping-method-dropdown .select2{min-width:130px}.wc-wizard-services.shipping .wc-wizard-service-description{display:-webkit-box;display:-ms-flexbox;display:flex;-webkit-box-orient:vertical;-webkit-box-direction:normal;-ms-flex-direction:column;flex-direction:column;color:#a6a6a6}.wc-wizard-services.shipping .wc-wizard-service-item:not(:first-child) .wc-wizard-service-description{font-size:.92em;padding-bottom:10px}.wc-wizard-services.shipping .shipping-method-setting input{width:95px;border:1px solid #aaa;border-color:#ddd;border-radius:4px;height:28px;padding-right:8px;padding-left:24px;font-size:14px;color:#444;background-color:#fff;display:inline-block}.wc-wizard-services.shipping .shipping-method-description,.wc-wizard-services.shipping .shipping-method-setting .description{color:#7e7e7e;font-size:.9em}.wc-wizard-services.shipping .shipping-method-setting input::-webkit-input-placeholder{color:#e1e1e1}.wc-wizard-services.shipping .shipping-method-setting input::-moz-placeholder{color:#e1e1e1}.wc-wizard-services.shipping .shipping-method-setting input:-ms-input-placeholder{color:#e1e1e1}.wc-wizard-services.shipping .shipping-method-setting input::placeholder{color:#e1e1e1}.wc-setup-shipping-units p{line-height:1.5em;font-size:13px;margin-bottom:.25em}.wc-setup-shipping-units .wc-setup-shipping-unit{margin-bottom:1.75em}.wc-setup-shipping-units .wc-setup-shipping-unit .select2{min-width:100%}.hide{display:none}.wc-wizard-features{display:-webkit-box;display:-ms-flexbox;display:flex;-ms-flex-wrap:wrap;flex-wrap:wrap;list-style:none;padding:0}.wc-wizard-features .wc-wizard-feature-item{-ms-flex-preferred-size:calc(50% - 4em - 3px);flex-basis:calc(50% - 4em - 3px);border:1px solid #eee;padding:2em}.wc-wizard-features .wc-wizard-feature-item:nth-child(1){border-radius:0 4px 0 0}.wc-wizard-features .wc-wizard-feature-item:nth-child(2){border-right:0;border-radius:4px 0 0 0}.wc-wizard-features .wc-wizard-feature-item:nth-child(3){border-top:0;border-radius:0 0 4px 0}.wc-wizard-features .wc-wizard-feature-item:nth-child(4){border-top:0;border-right:0;border-radius:0 0 0 4px}.wc-wizard-features p.wc-wizard-feature-description,.wc-wizard-features p.wc-wizard-feature-name{margin:0;line-height:1.5em}h3.jetpack-reasons{text-align:center;margin:3em 0 1em 0;font-size:14px}.jetpack-logo,.wcs-notice{display:block;margin:1.75em auto 2em auto;max-height:175px}.activate-splash .jetpack-logo{width:170px;margin-bottom:0}.activate-splash .wcs-notice{margin-top:1em;padding-right:57px}.step{text-align:center}.wc-setup .wc-setup-actions .button{font-weight:300;font-size:16px;padding:1em 2em;box-shadow:none;min-width:12em;min-width:auto;margin-top:10px}.wc-setup .wc-setup-actions .button:active,.wc-setup .wc-setup-actions .button:focus,.wc-setup .wc-setup-actions .button:hover{box-shadow:none}.location-prompt{color:#666;font-size:13px;font-weight:500;margin-bottom:.5em;margin-top:.85em;display:inline-block}.location-input{border:1px solid #aaa;border-color:#ddd;border-radius:4px;height:30px;width:calc(100% - 8px - 24px - 2px);padding-right:8px;padding-left:24px;font-size:16px;color:#444;background-color:#fff;display:inline-block}.location-input.dropdown{width:100%}.address-step .select2{min-width:100%}.store-address-container .city-and-postcode{display:-webkit-box;display:-ms-flexbox;display:flex}.store-address-container .city-and-postcode div{-ms-flex-preferred-size:50%;flex-basis:50%;margin-left:1em}.store-address-container .city-and-postcode div:last-of-type{margin-left:0}.store-address-container .select2-container,.store-address-container input[type=text],.store-address-container select{margin-bottom:10px}.product-type-container{margin-top:14px;margin-bottom:1px}#woocommerce_sell_in_person{margin-right:0}.wc-wizard-service-settings .payment-email-input{border:1px solid #aaa;border-color:#ddd;border-radius:4px;height:30px;padding:0 8px;font-size:14px;color:#444;background-color:#fff;display:inline-block}.newsletter-form-container{display:-webkit-box;display:-ms-flexbox;display:flex}.newsletter-form-container .newsletter-form-email{border:1px solid #aaa;border-color:#ddd;border-radius:4px;height:42px;padding:0 8px;font-size:16px;color:#666;background-color:#fff;display:inline-block;margin-left:6px;-webkit-box-flex:1;-ms-flex-positive:1;flex-grow:1}.newsletter-form-container .newsletter-form-button-container{-webkit-box-flex:0;-ms-flex-positive:0;flex-grow:0}.wc-setup .wc-setup-actions .button.newsletter-form-button{height:42px;padding:0 1em;margin:0}.wc-wizard-next-steps{border:1px solid #eee;border-radius:4px;list-style:none;padding:0}.wc-wizard-next-steps li{padding:0}.wc-wizard-next-steps .wc-wizard-next-step-item{display:-webkit-box;display:-ms-flexbox;display:flex;border-top:1px solid #eee}.wc-wizard-next-steps .wc-wizard-next-step-item:first-child{border-top:0}.wc-wizard-next-steps .wc-wizard-next-step-description{-webkit-box-flex:1;-ms-flex-positive:1;flex-grow:1;margin:1.5em}.wc-wizard-next-steps .wc-wizard-next-step-action{-webkit-box-flex:0;-ms-flex-positive:0;flex-grow:0;display:-webkit-box;display:-ms-flexbox;display:flex;-webkit-box-align:center;-ms-flex-align:center;align-items:center}.wc-wizard-next-steps .wc-wizard-next-step-action .button{margin:1em 1.5em}.wc-wizard-next-steps p.next-step-heading{margin:0;font-size:.95em;font-weight:400;font-variant:all-petite-caps}.wc-wizard-next-steps p.next-step-extra-info{margin:0}.wc-wizard-next-steps h3.next-step-description{margin:0;font-size:16px;font-weight:600}.wc-wizard-next-steps .wc-wizard-additional-steps{border-top:1px solid #eee}.wc-wizard-next-steps .wc-wizard-additional-steps .wc-wizard-next-step-description{margin-bottom:0}.wc-wizard-next-steps .wc-wizard-additional-steps .wc-setup-actions{margin:0 0 1.5em 0}.wc-wizard-next-steps .wc-wizard-additional-steps .wc-setup-actions .button{font-size:15px;margin:1em 1.5em 1em 0}.wc-wizard-next-steps .wc-wizard-additional-steps .wc-setup-actions .button::last-child{margin-left:1.5em}p.next-steps-help-text{color:#9f9f9f;padding:0 2em;text-align:center;font-size:.9em}p.jetpack-terms{font-size:.8em;text-align:center;max-width:480px;margin:0 auto;line-height:1.5em}.woocommerce-error{background:#ffe6e5;border-color:#ffc5c2;padding:1em;margin-bottom:1em}.woocommerce-error p{margin-top:0;margin-bottom:.5em;color:#444}.woocommerce-error a{color:#ff645c}.woocommerce-error .reconnect-reminder{font-size:.85em}.woocommerce-error .wc-setup-actions .button{font-size:14px}.wc-wizard-service-setting-ppec_paypal_reroute_requests,.wc-wizard-service-setting-stripe_create_account{display:-webkit-box;display:-ms-flexbox;display:flex;-webkit-box-align:start;-ms-flex-align:start;align-items:flex-start;margin-top:.75em}.wc-wizard-service-setting-ppec_paypal_reroute_requests .payment-checkbox-input,.wc-wizard-service-setting-stripe_create_account .payment-checkbox-input{-webkit-box-ordinal-group:2;-ms-flex-order:1;order:1;margin-top:5px;margin-right:0;margin-left:0;width:1.5em}.wc-wizard-service-setting-ppec_paypal_reroute_requests .ppec_paypal_reroute_requests,.wc-wizard-service-setting-ppec_paypal_reroute_requests .stripe_create_account,.wc-wizard-service-setting-stripe_create_account .ppec_paypal_reroute_requests,.wc-wizard-service-setting-stripe_create_account .stripe_create_account{-webkit-box-ordinal-group:3;-ms-flex-order:2;order:2;margin-right:.3em}.wc-wizard-service-setting-ppec_paypal_email,.wc-wizard-service-setting-stripe_email{margin-top:.75em}.wc-wizard-service-setting-ppec_paypal_email label.ppec_paypal_email,.wc-wizard-service-setting-ppec_paypal_email label.stripe_email,.wc-wizard-service-setting-stripe_email label.ppec_paypal_email,.wc-wizard-service-setting-stripe_email label.stripe_email{position:absolute;margin:-1px;padding:0;height:1px;width:1px;overflow:hidden;clip:rect(0 0 0 0);border:0}.wc-wizard-service-setting-ppec_paypal_email input.payment-email-input,.wc-wizard-service-setting-stripe_email input.payment-email-input{margin-right:1.5em;margin-bottom:.5em;width:100%}.wc-wizard-service-setting-ppec_paypal_email .wc-wizard-service-settings-description,.wc-wizard-service-setting-stripe_email .wc-wizard-service-settings-description{margin-right:1.5em}.recommended-step{border:1px solid #ebebeb;border-radius:4px;padding:2.5em}.recommended-step li{list-style:none}.recommended-step li:last-child .recommended-item{margin-bottom:0}.recommended-step .recommended-item{display:-webkit-box;display:-ms-flexbox;display:flex;-webkit-box-align:center;-ms-flex-align:center;align-items:center;margin-bottom:1.5em}.recommended-step .recommended-item-icon{border:1px solid #fff;border-radius:7px;height:3.5em;margin-left:1em;margin-right:1em}.recommended-step .recommended-item-icon.recommended-item-icon-storefront_theme{background-color:#f4a224;max-height:3em;max-width:3em;padding:.25em}.recommended-step .recommended-item-icon.recommended-item-icon-automated_taxes{background-color:#d0011b;max-height:1.75em;padding:.875em}.recommended-step .recommended-item-icon.recommended-item-icon-mailchimp{background-color:#209bbb;height:2em;padding:.75em}.recommended-step .recommended-item-description-container h3{font-size:15px;font-weight:700;letter-spacing:.5px;margin-bottom:0}.recommended-step .recommended-item-description-container p{margin-top:0;line-height:1.5em} \ No newline at end of file diff --git a/assets/css/wc-setup.css b/assets/css/wc-setup.css index e2d77ec9da3..e9a09cb0366 100644 --- a/assets/css/wc-setup.css +++ b/assets/css/wc-setup.css @@ -1 +1 @@ -@charset "UTF-8";body{margin:65px auto 24px;box-shadow:none;background:#f1f1f1;padding:0}#wc-logo{border:0;margin:0 0 24px;padding:0;text-align:center}#wc-logo img{max-width:30%}.wc-setup{text-align:center}.wc-setup .select2-container{text-align:left}.wc-setup .hidden{display:none}.wc-setup-content{box-shadow:0 1px 3px rgba(0,0,0,.13);padding:2em;margin:0 0 20px;background:#fff;overflow:hidden;zoom:1;text-align:left}.wc-setup-content h1,.wc-setup-content h2,.wc-setup-content h3,.wc-setup-content table{margin:0 0 20px;border:0;padding:0;color:#666;clear:none;font-weight:500}.wc-setup-content p{margin:20px 0;font-size:1em;line-height:1.75em;color:#666}.wc-setup-content table{font-size:1em;line-height:1.75em;color:#666}.wc-setup-content a{color:#a16696}.wc-setup-content a:focus,.wc-setup-content a:hover{color:#111}.wc-setup-content .form-table th{width:35%;vertical-align:top;font-weight:400}.wc-setup-content .form-table td{vertical-align:top}.wc-setup-content .form-table td input,.wc-setup-content .form-table td select{width:100%;box-sizing:border-box}.wc-setup-content .form-table td input[size]{width:auto}.wc-setup-content .form-table td .description{line-height:1.5em;display:block;margin-top:.25em;color:#999;font-style:italic}.wc-setup-content .form-table td .input-checkbox,.wc-setup-content .form-table td .input-radio{width:auto;box-sizing:inherit;padding:inherit;margin:0 .5em 0 0;box-shadow:none}.wc-setup-content .form-table .section_title td{padding:0}.wc-setup-content .form-table .section_title td h2,.wc-setup-content .form-table .section_title td p{margin:12px 0 0}.wc-setup-content .form-table td,.wc-setup-content .form-table th{padding:12px 0;margin:0;border:0}.wc-setup-content .form-table td:first-child,.wc-setup-content .form-table th:first-child{padding-right:1em}.wc-setup-content table.tax-rates{width:100%;font-size:.92em}.wc-setup-content table.tax-rates th{padding:0;text-align:center;width:auto;vertical-align:middle}.wc-setup-content table.tax-rates td{border:1px solid #f5f5f5;padding:6px;text-align:center;vertical-align:middle}.wc-setup-content table.tax-rates td input{outline:0;border:0;padding:0;box-shadow:none;text-align:center;width:100%}.wc-setup-content table.tax-rates td.sort{cursor:move;color:#ccc}.wc-setup-content table.tax-rates td.sort::before{content:'\f333';font-family:dashicons}.wc-setup-content table.tax-rates td.readonly{background:#f5f5f5}.wc-setup-content table.tax-rates .add{padding:1em 0 0 1em;line-height:1em;font-size:1em;width:0;margin:6px 0 0;height:0;overflow:hidden;position:relative;display:inline-block}.wc-setup-content table.tax-rates .add::before{content:'\f502';font-family:dashicons;position:absolute;left:0;top:0}.wc-setup-content table.tax-rates .remove{padding:1em 0 0 1em;line-height:1em;font-size:1em;width:0;margin:0;height:0;overflow:hidden;position:relative;display:inline-block}.wc-setup-content table.tax-rates .remove::before{content:'\f182';font-family:dashicons;position:absolute;left:0;top:0}.wc-setup-content .wc-setup-pages{width:100%;border-top:1px solid #eee}.wc-setup-content .wc-setup-pages thead th{display:none}.wc-setup-content .wc-setup-pages .page-name{width:30%;font-weight:700}.wc-setup-content .wc-setup-pages td,.wc-setup-content .wc-setup-pages th{padding:14px 0;border-bottom:1px solid #eee}.wc-setup-content .wc-setup-pages td:first-child,.wc-setup-content .wc-setup-pages th:first-child{padding-right:9px}.wc-setup-content .wc-setup-pages th{padding-top:0}.wc-setup-content .wc-setup-pages .page-options p{color:#777;margin:6px 0 0 24px;line-height:1.75em}.wc-setup-content .wc-setup-pages .page-options p input{vertical-align:middle;margin:1px 0 0;height:1.75em;width:1.75em;line-height:1.75em}.wc-setup-content .wc-setup-pages .page-options p label{line-height:1}@media screen and (max-width:782px){.wc-setup-content .form-table tbody th{width:auto}}.wc-setup-content .twitter-share-button{float:right}.wc-setup-content .wc-setup-next-steps{overflow:hidden;margin:0 0 24px;padding-bottom:2px}.wc-setup-content .wc-setup-next-steps h2{margin-bottom:12px}.wc-setup-content .wc-setup-next-steps .wc-setup-next-steps-first{float:left;width:50%;box-sizing:border-box}.wc-setup-content .wc-setup-next-steps .wc-setup-next-steps-last{float:right;width:50%;box-sizing:border-box}.wc-setup-content .wc-setup-next-steps ul{padding:0 2em 0 0;list-style:none outside;margin:0}.wc-setup-content .wc-setup-next-steps ul li a{display:block;padding:0 0 .75em}.wc-setup-content .wc-setup-next-steps ul .setup-product a.button{background-color:#f7f7f7;border-color:#ccc;color:#23282d;box-shadow:inset 0 1px 0 rgba(255,255,255,.25),0 1px 0 #ccc;text-shadow:1px 0 1px #eee,0 1px 1px #eee;font-size:1em;height:auto;line-height:1.75em;margin:0 0 .75em;opacity:1;padding:1em;text-align:center}.wc-setup-content .wc-setup-next-steps ul .setup-product a.button:active,.wc-setup-content .wc-setup-next-steps ul .setup-product a.button:focus,.wc-setup-content .wc-setup-next-steps ul .setup-product a.button:hover{background:#f5f5f5;border-color:#aaa}.wc-setup-content .wc-setup-next-steps ul .setup-product a.button-primary{color:#fff;background-color:#bb77ae;border-color:#a36597;box-shadow:inset 0 1px 0 rgba(255,255,255,.25),0 1px 0 #a36597;text-shadow:0 -1px 1px #a36597,1px 0 1px #a36597,0 1px 1px #a36597,-1px 0 1px #a36597}.wc-setup-content .wc-setup-next-steps ul .setup-product a.button-primary:active,.wc-setup-content .wc-setup-next-steps ul .setup-product a.button-primary:focus,.wc-setup-content .wc-setup-next-steps ul .setup-product a.button-primary:hover{color:#fff;background:#a36597;border-color:#a36597;box-shadow:inset 0 1px 0 rgba(255,255,255,.25),0 1px 0 #a36597}.wc-setup-content .wc-setup-next-steps ul li a::before{color:#82878c;font:normal 20px/1 dashicons;speak:none;display:inline-block;padding:0 10px 0 0;top:1px;position:relative;text-decoration:none!important;vertical-align:top}.wc-setup-content .wc-setup-next-steps ul .learn-more a::before{content:'\f105'}.wc-setup-content .wc-setup-next-steps ul .video-walkthrough a::before{content:'\f126'}.wc-setup-content .wc-setup-next-steps ul .newsletter a::before{content:'\f465'}.wc-setup-content .updated,.wc-setup-content .woocommerce-newsletter{padding:24px 24px 0;margin:0 0 24px;overflow:hidden;background:#f5f5f5}.wc-setup-content .updated p,.wc-setup-content .woocommerce-newsletter p{padding:0;margin:0 0 12px}.wc-setup-content .updated form,.wc-setup-content .updated p:last-child,.wc-setup-content .woocommerce-newsletter form,.wc-setup-content .woocommerce-newsletter p:last-child{margin:0 0 24px}.wc-setup-content .woocommerce-tracker{margin:24px 0;border:1px solid #eee;padding:20px;border-radius:4px;overflow:hidden}.wc-setup-content .woocommerce-tracker p{font-size:14px;line-height:1.5em}.wc-setup-content .woocommerce-tracker .checkbox{line-height:24px;font-weight:500;font-size:1em;margin-top:0;margin-bottom:20px}.wc-setup-content .woocommerce-tracker .checkbox input[type=checkbox]{opacity:0;position:absolute;left:-9999px}.wc-setup-content .woocommerce-tracker .checkbox label{position:relative;display:inline-block;padding-left:28px}.wc-setup-content .woocommerce-tracker .checkbox label:after,.wc-setup-content .woocommerce-tracker .checkbox label:before{position:absolute;content:"";display:inline-block}.wc-setup-content .woocommerce-tracker .checkbox label:before{height:16px;width:16px;left:0;top:3px;border:1px solid #aaa;background-color:#fff;border-radius:3px}.wc-setup-content .woocommerce-tracker .checkbox label:after{height:5px;width:9px;border-left:2px solid;border-bottom:2px solid;-webkit-transform:rotate(-45deg);-ms-transform:rotate(-45deg);transform:rotate(-45deg);left:4px;top:7px;color:#fff}.wc-setup-content .woocommerce-tracker .checkbox input[type=checkbox]+label::after{content:none}.wc-setup-content .woocommerce-tracker .checkbox input[type=checkbox]:checked+label::after{content:""}.wc-setup-content .woocommerce-tracker .checkbox input[type=checkbox]:focus+label::before{outline:#3b99fc auto 5px}.wc-setup-content .woocommerce-tracker .checkbox input[type=checkbox]:checked+label::before{background:#935687;border-color:#935687;outline:0}.wc-setup-steps{padding:0 0 24px;margin:0;list-style:none outside;overflow:hidden;color:#ccc;width:100%;display:-webkit-inline-box;display:-ms-inline-flexbox;display:inline-flex}.wc-setup-steps li{width:100%;float:left;padding:0 0 .8em;margin:0;text-align:center;position:relative;border-bottom:4px solid #ccc;line-height:1.4em}.wc-setup-steps li a{color:#a16696;text-decoration:none;padding:1.5em;margin:-1.5em;position:relative;z-index:1}.wc-setup-steps li a:focus,.wc-setup-steps li a:hover{color:#111;text-decoration:underline}.wc-setup-steps li::before{content:'';border:4px solid #ccc;border-radius:100%;width:4px;height:4px;position:absolute;bottom:0;left:50%;margin-left:-6px;margin-bottom:-8px;background:#fff}.wc-setup-steps li.active{border-color:#a16696;color:#a16696;font-weight:700}.wc-setup-steps li.active::before{border-color:#a16696}.wc-setup-steps li.done{border-color:#a16696;color:#a16696}.wc-setup-steps li.done::before{border-color:#a16696;background:#a16696}.wc-setup .wc-setup-actions{overflow:hidden;margin:20px 0 0;position:relative}.wc-setup .wc-setup-actions .button{font-size:1.25em;padding:.5em 1em;line-height:1em;margin-right:.5em;margin-bottom:2px;height:auto;border-radius:4px}.wc-setup .wc-setup-actions .button-primary{background-color:#bb77ae;border-color:#a36597;box-shadow:inset 0 1px 0 rgba(255,255,255,.25),0 1px 0 #a36597;text-shadow:0 -1px 1px #a36597,1px 0 1px #a36597,0 1px 1px #a36597,-1px 0 1px #a36597;margin:0;opacity:1}.wc-setup .wc-setup-actions .button-primary:active,.wc-setup .wc-setup-actions .button-primary:focus,.wc-setup .wc-setup-actions .button-primary:hover{background:#a36597;border-color:#a36597;box-shadow:inset 0 1px 0 rgba(255,255,255,.25),0 1px 0 #a36597}.wc-setup-content p:last-child{margin-bottom:0}.wc-setup-content p.store-setup{margin-top:0}.wc-setup-footer-links{font-size:.85em;color:#b5b5b5;margin:1.18em auto;display:inline-block;text-align:center}.wc-wizard-storefront .wc-wizard-storefront-intro{padding:40px 40px 0;background:#f5f5f5;text-align:center}.wc-wizard-storefront .wc-wizard-storefront-intro img{margin:40px 0 0 0;width:100%;display:block}.wc-wizard-storefront .wc-wizard-storefront-features{list-style:none outside;margin:0 0 20px;padding:0 0 0 30px;overflow:hidden}.wc-wizard-storefront .wc-wizard-storefront-feature{margin:0;padding:20px 30px 20px 2em;width:50%;box-sizing:border-box}.wc-wizard-storefront .wc-wizard-storefront-feature::before{margin-left:-2em;position:absolute}.wc-wizard-storefront .wc-wizard-storefront-feature.first{clear:both;float:left}.wc-wizard-storefront .wc-wizard-storefront-feature.last{float:right}.wc-wizard-storefront .wc-wizard-storefront-feature__bulletproof::before{content:'πŸ”’'}.wc-wizard-storefront .wc-wizard-storefront-feature__mobile::before{content:'πŸ“±'}.wc-wizard-storefront .wc-wizard-storefront-feature__accessibility::before{content:'πŸ‘“'}.wc-wizard-storefront .wc-wizard-storefront-feature__search::before{content:'πŸ”'}.wc-wizard-storefront .wc-wizard-storefront-feature__compatibility::before{content:'πŸ”§'}.wc-wizard-storefront .wc-wizard-storefront-feature__extendable::before{content:'🎨'}.wc-wizard-services{border:1px solid #eee;padding:0;margin:0 0 1em;list-style:none outside;border-radius:4px;overflow:hidden}.wc-wizard-services p{margin:0 0 1em 0;padding:0;font-size:1em;line-height:1.5em}.wc-wizard-service-item,.wc-wizard-services-list-toggle{display:-webkit-box;display:-ms-flexbox;display:flex;-ms-flex-wrap:nowrap;flex-wrap:nowrap;-webkit-box-pack:justify;-ms-flex-pack:justify;justify-content:space-between;padding:0;border-bottom:1px solid #eee;color:#666;-webkit-box-align:center;-ms-flex-align:center;align-items:center}.wc-wizard-service-item:last-child,.wc-wizard-services-list-toggle:last-child{border-bottom:0}.wc-wizard-service-item .payment-gateway-fee,.wc-wizard-services-list-toggle .payment-gateway-fee{color:#a6a6a6}.wc-wizard-service-item .wc-wizard-service-name,.wc-wizard-services-list-toggle .wc-wizard-service-name{-ms-flex-preferred-size:0;flex-basis:0;min-width:160px;text-align:center;font-weight:700;padding:2em 0;-ms-flex-item-align:stretch;align-self:stretch;display:-webkit-box;display:-ms-flexbox;display:flex;-webkit-box-align:baseline;-ms-flex-align:baseline;align-items:baseline}.wc-wizard-payment-gateway-form .wc-wizard-service-item .wc-wizard-service-name,.wc-wizard-payment-gateway-form .wc-wizard-services-list-toggle .wc-wizard-service-name{-webkit-box-pack:center;-ms-flex-pack:center;justify-content:center}.wc-wizard-service-item .wc-wizard-service-name img,.wc-wizard-services-list-toggle .wc-wizard-service-name img{max-width:75px}.wc-wizard-service-item.stripe-logo .wc-wizard-service-name img,.wc-wizard-services-list-toggle.stripe-logo .wc-wizard-service-name img{padding:8px 0}.wc-wizard-service-item.paypal-logo .wc-wizard-service-name img,.wc-wizard-services-list-toggle.paypal-logo .wc-wizard-service-name img{max-width:87px;padding:2px 0}.wc-wizard-service-item.klarna-logo .wc-wizard-service-name,.wc-wizard-services-list-toggle.klarna-logo .wc-wizard-service-name{background:#000}.wc-wizard-service-item.klarna-logo .wc-wizard-service-name img,.wc-wizard-services-list-toggle.klarna-logo .wc-wizard-service-name img{max-width:87px;padding:12px 0}.wc-wizard-service-item.square-logo .wc-wizard-service-name,.wc-wizard-services-list-toggle.square-logo .wc-wizard-service-name{background:#000}.wc-wizard-service-item.square-logo .wc-wizard-service-name img,.wc-wizard-services-list-toggle.square-logo .wc-wizard-service-name img{max-width:95px;padding:12px 0}.wc-wizard-service-item .wc-wizard-service-description,.wc-wizard-services-list-toggle .wc-wizard-service-description{-webkit-box-flex:1;-ms-flex-positive:1;flex-grow:1;padding:20px}.wc-wizard-service-item .wc-wizard-service-description p,.wc-wizard-services-list-toggle .wc-wizard-service-description p{margin-bottom:1em}.wc-wizard-service-item .wc-wizard-service-description p:last-child,.wc-wizard-services-list-toggle .wc-wizard-service-description p:last-child{margin-bottom:0}.wc-wizard-service-item .wc-wizard-service-description .wc-wizard-service-settings-description,.wc-wizard-services-list-toggle .wc-wizard-service-description .wc-wizard-service-settings-description{display:block;font-style:italic;color:#999}.wc-wizard-service-item .wc-wizard-service-enable,.wc-wizard-services-list-toggle .wc-wizard-service-enable{-ms-flex-preferred-size:0;flex-basis:0;min-width:75px;text-align:center;cursor:pointer;padding:2em 0;position:relative;max-height:1.5em;-ms-flex-item-align:start;align-self:flex-start}.wc-wizard-service-item .wc-wizard-service-toggle,.wc-wizard-services-list-toggle .wc-wizard-service-toggle{height:16px;width:32px;border:2px solid #935687;background-color:#935687;display:inline-block;text-indent:-9999px;border-radius:10em;position:relative}.wc-wizard-service-item .wc-wizard-service-toggle input[type=checkbox],.wc-wizard-services-list-toggle .wc-wizard-service-toggle input[type=checkbox]{display:none}.wc-wizard-service-item .wc-wizard-service-toggle:before,.wc-wizard-services-list-toggle .wc-wizard-service-toggle:before{content:"";display:block;width:16px;height:16px;background:#fff;position:absolute;top:0;right:0;border-radius:100%}.wc-wizard-service-item .wc-wizard-service-toggle.disabled,.wc-wizard-services-list-toggle .wc-wizard-service-toggle.disabled{border-color:#999;background-color:#999}.wc-wizard-service-item .wc-wizard-service-toggle.disabled:before,.wc-wizard-services-list-toggle .wc-wizard-service-toggle.disabled:before{right:auto;left:0}.wc-wizard-service-item .wc-wizard-service-settings,.wc-wizard-services-list-toggle .wc-wizard-service-settings{display:none;margin-bottom:0;cursor:default}.wc-wizard-service-item .wc-wizard-service-settings.hide,.wc-wizard-services-list-toggle .wc-wizard-service-settings.hide{display:none}.wc-wizard-service-item.checked .wc-wizard-service-settings,.wc-wizard-services-list-toggle.checked .wc-wizard-service-settings{display:inline-block}.wc-wizard-service-item.checked .wc-wizard-service-settings.hide,.wc-wizard-services-list-toggle.checked .wc-wizard-service-settings.hide{display:none}.wc-wizard-service-item.closed,.wc-wizard-services-list-toggle.closed{border-bottom:0}.wc-wizard-services-list-toggle{cursor:pointer}.wc-wizard-services-list-toggle .wc-wizard-service-enable::before{content:"\f343";font-family:dashicons;visibility:initial;color:#666;font-size:25px;margin-top:-7px;margin-left:-5px;position:absolute;visibility:visible}.wc-wizard-services-list-toggle.closed .wc-wizard-service-enable::before{content:"\f347"}.wc-wizard-services-list-toggle .wc-wizard-service-enable input{visibility:hidden;position:relative}.wc-wizard-services.manual .wc-wizard-service-item{display:none}.wc-wizard-services.shipping .wc-wizard-service-name{font-weight:400;text-align:left;-webkit-box-align:center;-ms-flex-align:center;align-items:center;max-height:5em;padding:0}.wc-wizard-services.shipping .wc-wizard-service-item{padding-left:2em;padding-top:.67em}.wc-wizard-services.shipping .wc-wizard-service-item:first-child{border-bottom:0;padding-bottom:0;font-weight:700}.wc-wizard-services.shipping .wc-wizard-service-item:first-child .wc-wizard-service-name{font-weight:700}.wc-wizard-services.shipping .shipping-method-setting,.wc-wizard-services.shipping .wc-wizard-shipping-method-select{display:-webkit-box;display:-ms-flexbox;display:flex}.wc-wizard-services.shipping .shipping-method-setting.hide,.wc-wizard-services.shipping .wc-wizard-shipping-method-select.hide{display:none}.wc-wizard-services.shipping .shipping-method-setting input,.wc-wizard-services.shipping .wc-wizard-shipping-method-dropdown{margin-right:2em;margin-bottom:1em}.wc-wizard-services.shipping .shipping-method-setting input .select2,.wc-wizard-services.shipping .wc-wizard-shipping-method-dropdown .select2{min-width:130px}.wc-wizard-services.shipping .wc-wizard-service-description{display:-webkit-box;display:-ms-flexbox;display:flex;-webkit-box-orient:vertical;-webkit-box-direction:normal;-ms-flex-direction:column;flex-direction:column;color:#a6a6a6}.wc-wizard-services.shipping .wc-wizard-service-item:not(:first-child) .wc-wizard-service-description{font-size:.92em;padding-bottom:10px}.wc-wizard-services.shipping .shipping-method-setting input{width:95px;border:1px solid #aaa;border-color:#ddd;border-radius:4px;height:28px;padding-left:8px;padding-right:24px;font-size:14px;color:#444;background-color:#fff;display:inline-block}.wc-wizard-services.shipping .shipping-method-description,.wc-wizard-services.shipping .shipping-method-setting .description{color:#7e7e7e;font-size:.9em}.wc-wizard-services.shipping .shipping-method-setting input::-webkit-input-placeholder{color:#e1e1e1}.wc-wizard-services.shipping .shipping-method-setting input::-moz-placeholder{color:#e1e1e1}.wc-wizard-services.shipping .shipping-method-setting input:-ms-input-placeholder{color:#e1e1e1}.wc-wizard-services.shipping .shipping-method-setting input::placeholder{color:#e1e1e1}.wc-setup-shipping-units p{line-height:1.5em;font-size:13px;margin-bottom:.25em}.wc-setup-shipping-units .wc-setup-shipping-unit{margin-bottom:1.75em}.wc-setup-shipping-units .wc-setup-shipping-unit .select2{min-width:100%}.hide{display:none}.wc-wizard-features{display:-webkit-box;display:-ms-flexbox;display:flex;-ms-flex-wrap:wrap;flex-wrap:wrap;list-style:none;padding:0}.wc-wizard-features .wc-wizard-feature-item{-ms-flex-preferred-size:calc(50% - 4em - 3px);flex-basis:calc(50% - 4em - 3px);border:1px solid #eee;padding:2em}.wc-wizard-features .wc-wizard-feature-item:nth-child(1){border-radius:4px 0 0 0}.wc-wizard-features .wc-wizard-feature-item:nth-child(2){border-left:0;border-radius:0 4px 0 0}.wc-wizard-features .wc-wizard-feature-item:nth-child(3){border-top:0;border-radius:0 0 0 4px}.wc-wizard-features .wc-wizard-feature-item:nth-child(4){border-top:0;border-left:0;border-radius:0 0 4px 0}.wc-wizard-features p.wc-wizard-feature-description,.wc-wizard-features p.wc-wizard-feature-name{margin:0;line-height:1.5em}h3.jetpack-reasons{text-align:center;margin:3em 0 1em 0;font-size:14px}.jetpack-logo,.wcs-notice{display:block;margin:1.75em auto 2em auto;max-height:175px}.activate-splash .jetpack-logo{width:170px;margin-bottom:0}.activate-splash .wcs-notice{margin-top:1em;padding-left:57px}.step{text-align:center}.wc-setup .wc-setup-actions .button{font-weight:300;font-size:16px;padding:1em 2em;box-shadow:none;min-width:12em;min-width:auto;margin-top:10px}.wc-setup .wc-setup-actions .button:active,.wc-setup .wc-setup-actions .button:focus,.wc-setup .wc-setup-actions .button:hover{box-shadow:none}.location-prompt{color:#666;font-size:13px;font-weight:500;margin-bottom:.5em;margin-top:.85em;display:inline-block}.location-input{border:1px solid #aaa;border-color:#ddd;border-radius:4px;height:30px;width:calc(100% - 8px - 24px - 2px);padding-left:8px;padding-right:24px;font-size:16px;color:#444;background-color:#fff;display:inline-block}.location-input.dropdown{width:100%}.address-step .select2{min-width:100%}.store-address-container .city-and-postcode{display:-webkit-box;display:-ms-flexbox;display:flex}.store-address-container .city-and-postcode div{-ms-flex-preferred-size:50%;flex-basis:50%;margin-right:1em}.store-address-container .city-and-postcode div:last-of-type{margin-right:0}.store-address-container .select2-container,.store-address-container input[type=text],.store-address-container select{margin-bottom:10px}.product-type-container{margin-top:14px;margin-bottom:1px}#woocommerce_sell_in_person{margin-left:0}.wc-wizard-service-settings .payment-email-input{border:1px solid #aaa;border-color:#ddd;border-radius:4px;height:30px;padding:0 8px;font-size:14px;color:#444;background-color:#fff;display:inline-block}.newsletter-form-container{display:-webkit-box;display:-ms-flexbox;display:flex}.newsletter-form-container .newsletter-form-email{border:1px solid #aaa;border-color:#ddd;border-radius:4px;height:42px;padding:0 8px;font-size:16px;color:#666;background-color:#fff;display:inline-block;margin-right:6px;-webkit-box-flex:1;-ms-flex-positive:1;flex-grow:1}.newsletter-form-container .newsletter-form-button-container{-webkit-box-flex:0;-ms-flex-positive:0;flex-grow:0}.wc-setup .wc-setup-actions .button.newsletter-form-button{height:42px;padding:0 1em;margin:0}.wc-wizard-next-steps{border:1px solid #eee;border-radius:4px;list-style:none;padding:0}.wc-wizard-next-steps li{padding:0}.wc-wizard-next-steps .wc-wizard-next-step-item{display:-webkit-box;display:-ms-flexbox;display:flex;border-top:1px solid #eee}.wc-wizard-next-steps .wc-wizard-next-step-item:first-child{border-top:0}.wc-wizard-next-steps .wc-wizard-next-step-description{-webkit-box-flex:1;-ms-flex-positive:1;flex-grow:1;margin:1.5em}.wc-wizard-next-steps .wc-wizard-next-step-action{-webkit-box-flex:0;-ms-flex-positive:0;flex-grow:0;display:-webkit-box;display:-ms-flexbox;display:flex;-webkit-box-align:center;-ms-flex-align:center;align-items:center}.wc-wizard-next-steps .wc-wizard-next-step-action .button{margin:1em 1.5em}.wc-wizard-next-steps p.next-step-heading{margin:0;font-size:.95em;font-weight:400;font-variant:all-petite-caps}.wc-wizard-next-steps p.next-step-extra-info{margin:0}.wc-wizard-next-steps h3.next-step-description{margin:0;font-size:16px;font-weight:600}.wc-wizard-next-steps .wc-wizard-additional-steps{border-top:1px solid #eee}.wc-wizard-next-steps .wc-wizard-additional-steps .wc-wizard-next-step-description{margin-bottom:0}.wc-wizard-next-steps .wc-wizard-additional-steps .wc-setup-actions{margin:0 0 1.5em 0}.wc-wizard-next-steps .wc-wizard-additional-steps .wc-setup-actions .button{font-size:15px;margin:1em 0 1em 1.5em}.wc-wizard-next-steps .wc-wizard-additional-steps .wc-setup-actions .button::last-child{margin-right:1.5em}p.next-steps-help-text{color:#9f9f9f;padding:0 2em;text-align:center;font-size:.9em}p.jetpack-terms{font-size:.8em;text-align:center;max-width:480px;margin:0 auto;line-height:1.5em}.woocommerce-error{background:#ffe6e5;border-color:#ffc5c2;padding:1em;margin-bottom:1em}.woocommerce-error p{margin-top:0;margin-bottom:.5em;color:#444}.woocommerce-error a{color:#ff645c}.woocommerce-error .reconnect-reminder{font-size:.85em}.woocommerce-error .wc-setup-actions .button{font-size:14px}.wc-wizard-service-setting-ppec_paypal_reroute_requests,.wc-wizard-service-setting-stripe_create_account{display:-webkit-box;display:-ms-flexbox;display:flex;-webkit-box-align:start;-ms-flex-align:start;align-items:flex-start;margin-top:.75em}.wc-wizard-service-setting-ppec_paypal_reroute_requests .payment-checkbox-input,.wc-wizard-service-setting-stripe_create_account .payment-checkbox-input{-webkit-box-ordinal-group:2;-ms-flex-order:1;order:1;margin-top:5px;margin-left:0;margin-right:0;width:1.5em}.wc-wizard-service-setting-ppec_paypal_reroute_requests .ppec_paypal_reroute_requests,.wc-wizard-service-setting-ppec_paypal_reroute_requests .stripe_create_account,.wc-wizard-service-setting-stripe_create_account .ppec_paypal_reroute_requests,.wc-wizard-service-setting-stripe_create_account .stripe_create_account{-webkit-box-ordinal-group:3;-ms-flex-order:2;order:2;margin-left:.3em}.wc-wizard-service-setting-ppec_paypal_email,.wc-wizard-service-setting-stripe_email{margin-top:.75em}.wc-wizard-service-setting-ppec_paypal_email label.ppec_paypal_email,.wc-wizard-service-setting-ppec_paypal_email label.stripe_email,.wc-wizard-service-setting-stripe_email label.ppec_paypal_email,.wc-wizard-service-setting-stripe_email label.stripe_email{position:absolute;margin:-1px;padding:0;height:1px;width:1px;overflow:hidden;clip:rect(0 0 0 0);border:0}.wc-wizard-service-setting-ppec_paypal_email input.payment-email-input,.wc-wizard-service-setting-stripe_email input.payment-email-input{margin-left:1.5em;margin-bottom:.5em;width:100%}.wc-wizard-service-setting-ppec_paypal_email .wc-wizard-service-settings-description,.wc-wizard-service-setting-stripe_email .wc-wizard-service-settings-description{margin-left:1.5em}.recommended-step{border:1px solid #ebebeb;border-radius:4px;padding:2.5em}.recommended-step li{list-style:none}.recommended-step li:last-child .recommended-item{margin-bottom:0}.recommended-step .recommended-item{display:-webkit-box;display:-ms-flexbox;display:flex;-webkit-box-align:center;-ms-flex-align:center;align-items:center;margin-bottom:1.5em}.recommended-step .recommended-item-icon{border:1px solid #fff;border-radius:7px;height:3.5em;margin-right:1em;margin-left:1em}.recommended-step .recommended-item-icon.recommended-item-icon-storefront_theme{background-color:#f4a224;max-height:3em;max-width:3em;padding:.25em}.recommended-step .recommended-item-icon.recommended-item-icon-automated_taxes{background-color:#d0011b;max-height:1.75em;padding:.875em}.recommended-step .recommended-item-description-container h3{font-size:15px;font-weight:700;letter-spacing:.5px;margin-bottom:0}.recommended-step .recommended-item-description-container p{margin-top:0;line-height:1.5em} \ No newline at end of file +@charset "UTF-8";body{margin:65px auto 24px;box-shadow:none;background:#f1f1f1;padding:0}#wc-logo{border:0;margin:0 0 24px;padding:0;text-align:center}#wc-logo img{max-width:30%}.wc-setup{text-align:center}.wc-setup .select2-container{text-align:left}.wc-setup .hidden{display:none}.wc-setup-content{box-shadow:0 1px 3px rgba(0,0,0,.13);padding:2em;margin:0 0 20px;background:#fff;overflow:hidden;zoom:1;text-align:left}.wc-setup-content h1,.wc-setup-content h2,.wc-setup-content h3,.wc-setup-content table{margin:0 0 20px;border:0;padding:0;color:#666;clear:none;font-weight:500}.wc-setup-content p{margin:20px 0;font-size:1em;line-height:1.75em;color:#666}.wc-setup-content table{font-size:1em;line-height:1.75em;color:#666}.wc-setup-content a{color:#a16696}.wc-setup-content a:focus,.wc-setup-content a:hover{color:#111}.wc-setup-content .form-table th{width:35%;vertical-align:top;font-weight:400}.wc-setup-content .form-table td{vertical-align:top}.wc-setup-content .form-table td input,.wc-setup-content .form-table td select{width:100%;box-sizing:border-box}.wc-setup-content .form-table td input[size]{width:auto}.wc-setup-content .form-table td .description{line-height:1.5em;display:block;margin-top:.25em;color:#999;font-style:italic}.wc-setup-content .form-table td .input-checkbox,.wc-setup-content .form-table td .input-radio{width:auto;box-sizing:inherit;padding:inherit;margin:0 .5em 0 0;box-shadow:none}.wc-setup-content .form-table .section_title td{padding:0}.wc-setup-content .form-table .section_title td h2,.wc-setup-content .form-table .section_title td p{margin:12px 0 0}.wc-setup-content .form-table td,.wc-setup-content .form-table th{padding:12px 0;margin:0;border:0}.wc-setup-content .form-table td:first-child,.wc-setup-content .form-table th:first-child{padding-right:1em}.wc-setup-content table.tax-rates{width:100%;font-size:.92em}.wc-setup-content table.tax-rates th{padding:0;text-align:center;width:auto;vertical-align:middle}.wc-setup-content table.tax-rates td{border:1px solid #f5f5f5;padding:6px;text-align:center;vertical-align:middle}.wc-setup-content table.tax-rates td input{outline:0;border:0;padding:0;box-shadow:none;text-align:center;width:100%}.wc-setup-content table.tax-rates td.sort{cursor:move;color:#ccc}.wc-setup-content table.tax-rates td.sort::before{content:'\f333';font-family:dashicons}.wc-setup-content table.tax-rates td.readonly{background:#f5f5f5}.wc-setup-content table.tax-rates .add{padding:1em 0 0 1em;line-height:1em;font-size:1em;width:0;margin:6px 0 0;height:0;overflow:hidden;position:relative;display:inline-block}.wc-setup-content table.tax-rates .add::before{content:'\f502';font-family:dashicons;position:absolute;left:0;top:0}.wc-setup-content table.tax-rates .remove{padding:1em 0 0 1em;line-height:1em;font-size:1em;width:0;margin:0;height:0;overflow:hidden;position:relative;display:inline-block}.wc-setup-content table.tax-rates .remove::before{content:'\f182';font-family:dashicons;position:absolute;left:0;top:0}.wc-setup-content .wc-setup-pages{width:100%;border-top:1px solid #eee}.wc-setup-content .wc-setup-pages thead th{display:none}.wc-setup-content .wc-setup-pages .page-name{width:30%;font-weight:700}.wc-setup-content .wc-setup-pages td,.wc-setup-content .wc-setup-pages th{padding:14px 0;border-bottom:1px solid #eee}.wc-setup-content .wc-setup-pages td:first-child,.wc-setup-content .wc-setup-pages th:first-child{padding-right:9px}.wc-setup-content .wc-setup-pages th{padding-top:0}.wc-setup-content .wc-setup-pages .page-options p{color:#777;margin:6px 0 0 24px;line-height:1.75em}.wc-setup-content .wc-setup-pages .page-options p input{vertical-align:middle;margin:1px 0 0;height:1.75em;width:1.75em;line-height:1.75em}.wc-setup-content .wc-setup-pages .page-options p label{line-height:1}@media screen and (max-width:782px){.wc-setup-content .form-table tbody th{width:auto}}.wc-setup-content .twitter-share-button{float:right}.wc-setup-content .wc-setup-next-steps{overflow:hidden;margin:0 0 24px;padding-bottom:2px}.wc-setup-content .wc-setup-next-steps h2{margin-bottom:12px}.wc-setup-content .wc-setup-next-steps .wc-setup-next-steps-first{float:left;width:50%;box-sizing:border-box}.wc-setup-content .wc-setup-next-steps .wc-setup-next-steps-last{float:right;width:50%;box-sizing:border-box}.wc-setup-content .wc-setup-next-steps ul{padding:0 2em 0 0;list-style:none outside;margin:0}.wc-setup-content .wc-setup-next-steps ul li a{display:block;padding:0 0 .75em}.wc-setup-content .wc-setup-next-steps ul .setup-product a.button{background-color:#f7f7f7;border-color:#ccc;color:#23282d;box-shadow:inset 0 1px 0 rgba(255,255,255,.25),0 1px 0 #ccc;text-shadow:1px 0 1px #eee,0 1px 1px #eee;font-size:1em;height:auto;line-height:1.75em;margin:0 0 .75em;opacity:1;padding:1em;text-align:center}.wc-setup-content .wc-setup-next-steps ul .setup-product a.button:active,.wc-setup-content .wc-setup-next-steps ul .setup-product a.button:focus,.wc-setup-content .wc-setup-next-steps ul .setup-product a.button:hover{background:#f5f5f5;border-color:#aaa}.wc-setup-content .wc-setup-next-steps ul .setup-product a.button-primary{color:#fff;background-color:#bb77ae;border-color:#a36597;box-shadow:inset 0 1px 0 rgba(255,255,255,.25),0 1px 0 #a36597;text-shadow:0 -1px 1px #a36597,1px 0 1px #a36597,0 1px 1px #a36597,-1px 0 1px #a36597}.wc-setup-content .wc-setup-next-steps ul .setup-product a.button-primary:active,.wc-setup-content .wc-setup-next-steps ul .setup-product a.button-primary:focus,.wc-setup-content .wc-setup-next-steps ul .setup-product a.button-primary:hover{color:#fff;background:#a36597;border-color:#a36597;box-shadow:inset 0 1px 0 rgba(255,255,255,.25),0 1px 0 #a36597}.wc-setup-content .wc-setup-next-steps ul li a::before{color:#82878c;font:normal 20px/1 dashicons;speak:none;display:inline-block;padding:0 10px 0 0;top:1px;position:relative;text-decoration:none!important;vertical-align:top}.wc-setup-content .wc-setup-next-steps ul .learn-more a::before{content:'\f105'}.wc-setup-content .wc-setup-next-steps ul .video-walkthrough a::before{content:'\f126'}.wc-setup-content .wc-setup-next-steps ul .newsletter a::before{content:'\f465'}.wc-setup-content .updated,.wc-setup-content .woocommerce-newsletter{padding:24px 24px 0;margin:0 0 24px;overflow:hidden;background:#f5f5f5}.wc-setup-content .updated p,.wc-setup-content .woocommerce-newsletter p{padding:0;margin:0 0 12px}.wc-setup-content .updated form,.wc-setup-content .updated p:last-child,.wc-setup-content .woocommerce-newsletter form,.wc-setup-content .woocommerce-newsletter p:last-child{margin:0 0 24px}.wc-setup-content .woocommerce-tracker{margin:24px 0;border:1px solid #eee;padding:20px;border-radius:4px;overflow:hidden}.wc-setup-content .woocommerce-tracker p{font-size:14px;line-height:1.5em}.wc-setup-content .woocommerce-tracker .checkbox{line-height:24px;font-weight:500;font-size:1em;margin-top:0;margin-bottom:20px}.wc-setup-content .woocommerce-tracker .checkbox input[type=checkbox]{opacity:0;position:absolute;left:-9999px}.wc-setup-content .woocommerce-tracker .checkbox label{position:relative;display:inline-block;padding-left:28px}.wc-setup-content .woocommerce-tracker .checkbox label:after,.wc-setup-content .woocommerce-tracker .checkbox label:before{position:absolute;content:"";display:inline-block}.wc-setup-content .woocommerce-tracker .checkbox label:before{height:16px;width:16px;left:0;top:3px;border:1px solid #aaa;background-color:#fff;border-radius:3px}.wc-setup-content .woocommerce-tracker .checkbox label:after{height:5px;width:9px;border-left:2px solid;border-bottom:2px solid;-webkit-transform:rotate(-45deg);-ms-transform:rotate(-45deg);transform:rotate(-45deg);left:4px;top:7px;color:#fff}.wc-setup-content .woocommerce-tracker .checkbox input[type=checkbox]+label::after{content:none}.wc-setup-content .woocommerce-tracker .checkbox input[type=checkbox]:checked+label::after{content:""}.wc-setup-content .woocommerce-tracker .checkbox input[type=checkbox]:focus+label::before{outline:#3b99fc auto 5px}.wc-setup-content .woocommerce-tracker .checkbox input[type=checkbox]:checked+label::before{background:#935687;border-color:#935687;outline:0}.wc-setup-steps{padding:0 0 24px;margin:0;list-style:none outside;overflow:hidden;color:#ccc;width:100%;display:-webkit-inline-box;display:-ms-inline-flexbox;display:inline-flex}.wc-setup-steps li{width:100%;float:left;padding:0 0 .8em;margin:0;text-align:center;position:relative;border-bottom:4px solid #ccc;line-height:1.4em}.wc-setup-steps li a{color:#a16696;text-decoration:none;padding:1.5em;margin:-1.5em;position:relative;z-index:1}.wc-setup-steps li a:focus,.wc-setup-steps li a:hover{color:#111;text-decoration:underline}.wc-setup-steps li::before{content:'';border:4px solid #ccc;border-radius:100%;width:4px;height:4px;position:absolute;bottom:0;left:50%;margin-left:-6px;margin-bottom:-8px;background:#fff}.wc-setup-steps li.active{border-color:#a16696;color:#a16696;font-weight:700}.wc-setup-steps li.active::before{border-color:#a16696}.wc-setup-steps li.done{border-color:#a16696;color:#a16696}.wc-setup-steps li.done::before{border-color:#a16696;background:#a16696}.wc-setup .wc-setup-actions{overflow:hidden;margin:20px 0 0;position:relative}.wc-setup .wc-setup-actions .button{font-size:1.25em;padding:.5em 1em;line-height:1em;margin-right:.5em;margin-bottom:2px;height:auto;border-radius:4px}.wc-setup .wc-setup-actions .button-primary{background-color:#bb77ae;border-color:#a36597;box-shadow:inset 0 1px 0 rgba(255,255,255,.25),0 1px 0 #a36597;text-shadow:0 -1px 1px #a36597,1px 0 1px #a36597,0 1px 1px #a36597,-1px 0 1px #a36597;margin:0;opacity:1}.wc-setup .wc-setup-actions .button-primary:active,.wc-setup .wc-setup-actions .button-primary:focus,.wc-setup .wc-setup-actions .button-primary:hover{background:#a36597;border-color:#a36597;box-shadow:inset 0 1px 0 rgba(255,255,255,.25),0 1px 0 #a36597}.wc-setup-content p:last-child{margin-bottom:0}.wc-setup-content p.store-setup{margin-top:0}.wc-setup-footer-links{font-size:.85em;color:#b5b5b5;margin:1.18em auto;display:inline-block;text-align:center}.wc-wizard-storefront .wc-wizard-storefront-intro{padding:40px 40px 0;background:#f5f5f5;text-align:center}.wc-wizard-storefront .wc-wizard-storefront-intro img{margin:40px 0 0 0;width:100%;display:block}.wc-wizard-storefront .wc-wizard-storefront-features{list-style:none outside;margin:0 0 20px;padding:0 0 0 30px;overflow:hidden}.wc-wizard-storefront .wc-wizard-storefront-feature{margin:0;padding:20px 30px 20px 2em;width:50%;box-sizing:border-box}.wc-wizard-storefront .wc-wizard-storefront-feature::before{margin-left:-2em;position:absolute}.wc-wizard-storefront .wc-wizard-storefront-feature.first{clear:both;float:left}.wc-wizard-storefront .wc-wizard-storefront-feature.last{float:right}.wc-wizard-storefront .wc-wizard-storefront-feature__bulletproof::before{content:'πŸ”’'}.wc-wizard-storefront .wc-wizard-storefront-feature__mobile::before{content:'πŸ“±'}.wc-wizard-storefront .wc-wizard-storefront-feature__accessibility::before{content:'πŸ‘“'}.wc-wizard-storefront .wc-wizard-storefront-feature__search::before{content:'πŸ”'}.wc-wizard-storefront .wc-wizard-storefront-feature__compatibility::before{content:'πŸ”§'}.wc-wizard-storefront .wc-wizard-storefront-feature__extendable::before{content:'🎨'}.wc-wizard-services{border:1px solid #eee;padding:0;margin:0 0 1em;list-style:none outside;border-radius:4px;overflow:hidden}.wc-wizard-services p{margin:0 0 1em 0;padding:0;font-size:1em;line-height:1.5em}.wc-wizard-service-item,.wc-wizard-services-list-toggle{display:-webkit-box;display:-ms-flexbox;display:flex;-ms-flex-wrap:nowrap;flex-wrap:nowrap;-webkit-box-pack:justify;-ms-flex-pack:justify;justify-content:space-between;padding:0;border-bottom:1px solid #eee;color:#666;-webkit-box-align:center;-ms-flex-align:center;align-items:center}.wc-wizard-service-item:last-child,.wc-wizard-services-list-toggle:last-child{border-bottom:0}.wc-wizard-service-item .payment-gateway-fee,.wc-wizard-services-list-toggle .payment-gateway-fee{color:#a6a6a6}.wc-wizard-service-item .wc-wizard-service-name,.wc-wizard-services-list-toggle .wc-wizard-service-name{-ms-flex-preferred-size:0;flex-basis:0;min-width:160px;text-align:center;font-weight:700;padding:2em 0;-ms-flex-item-align:stretch;align-self:stretch;display:-webkit-box;display:-ms-flexbox;display:flex;-webkit-box-align:baseline;-ms-flex-align:baseline;align-items:baseline}.wc-wizard-payment-gateway-form .wc-wizard-service-item .wc-wizard-service-name,.wc-wizard-payment-gateway-form .wc-wizard-services-list-toggle .wc-wizard-service-name{-webkit-box-pack:center;-ms-flex-pack:center;justify-content:center}.wc-wizard-service-item .wc-wizard-service-name img,.wc-wizard-services-list-toggle .wc-wizard-service-name img{max-width:75px}.wc-wizard-service-item.stripe-logo .wc-wizard-service-name img,.wc-wizard-services-list-toggle.stripe-logo .wc-wizard-service-name img{padding:8px 0}.wc-wizard-service-item.paypal-logo .wc-wizard-service-name img,.wc-wizard-services-list-toggle.paypal-logo .wc-wizard-service-name img{max-width:87px;padding:2px 0}.wc-wizard-service-item.klarna-logo .wc-wizard-service-name,.wc-wizard-services-list-toggle.klarna-logo .wc-wizard-service-name{background:#000}.wc-wizard-service-item.klarna-logo .wc-wizard-service-name img,.wc-wizard-services-list-toggle.klarna-logo .wc-wizard-service-name img{max-width:87px;padding:12px 0}.wc-wizard-service-item.square-logo .wc-wizard-service-name,.wc-wizard-services-list-toggle.square-logo .wc-wizard-service-name{background:#000}.wc-wizard-service-item.square-logo .wc-wizard-service-name img,.wc-wizard-services-list-toggle.square-logo .wc-wizard-service-name img{max-width:95px;padding:12px 0}.wc-wizard-service-item .wc-wizard-service-description,.wc-wizard-services-list-toggle .wc-wizard-service-description{-webkit-box-flex:1;-ms-flex-positive:1;flex-grow:1;padding:20px}.wc-wizard-service-item .wc-wizard-service-description p,.wc-wizard-services-list-toggle .wc-wizard-service-description p{margin-bottom:1em}.wc-wizard-service-item .wc-wizard-service-description p:last-child,.wc-wizard-services-list-toggle .wc-wizard-service-description p:last-child{margin-bottom:0}.wc-wizard-service-item .wc-wizard-service-description .wc-wizard-service-settings-description,.wc-wizard-services-list-toggle .wc-wizard-service-description .wc-wizard-service-settings-description{display:block;font-style:italic;color:#999}.wc-wizard-service-item .wc-wizard-service-enable,.wc-wizard-services-list-toggle .wc-wizard-service-enable{-ms-flex-preferred-size:0;flex-basis:0;min-width:75px;text-align:center;cursor:pointer;padding:2em 0;position:relative;max-height:1.5em;-ms-flex-item-align:start;align-self:flex-start}.wc-wizard-service-item .wc-wizard-service-toggle,.wc-wizard-services-list-toggle .wc-wizard-service-toggle{height:16px;width:32px;border:2px solid #935687;background-color:#935687;display:inline-block;text-indent:-9999px;border-radius:10em;position:relative}.wc-wizard-service-item .wc-wizard-service-toggle input[type=checkbox],.wc-wizard-services-list-toggle .wc-wizard-service-toggle input[type=checkbox]{display:none}.wc-wizard-service-item .wc-wizard-service-toggle:before,.wc-wizard-services-list-toggle .wc-wizard-service-toggle:before{content:"";display:block;width:16px;height:16px;background:#fff;position:absolute;top:0;right:0;border-radius:100%}.wc-wizard-service-item .wc-wizard-service-toggle.disabled,.wc-wizard-services-list-toggle .wc-wizard-service-toggle.disabled{border-color:#999;background-color:#999}.wc-wizard-service-item .wc-wizard-service-toggle.disabled:before,.wc-wizard-services-list-toggle .wc-wizard-service-toggle.disabled:before{right:auto;left:0}.wc-wizard-service-item .wc-wizard-service-settings,.wc-wizard-services-list-toggle .wc-wizard-service-settings{display:none;margin-bottom:0;cursor:default}.wc-wizard-service-item .wc-wizard-service-settings.hide,.wc-wizard-services-list-toggle .wc-wizard-service-settings.hide{display:none}.wc-wizard-service-item.checked .wc-wizard-service-settings,.wc-wizard-services-list-toggle.checked .wc-wizard-service-settings{display:inline-block}.wc-wizard-service-item.checked .wc-wizard-service-settings.hide,.wc-wizard-services-list-toggle.checked .wc-wizard-service-settings.hide{display:none}.wc-wizard-service-item.closed,.wc-wizard-services-list-toggle.closed{border-bottom:0}.wc-wizard-services-list-toggle{cursor:pointer}.wc-wizard-services-list-toggle .wc-wizard-service-enable::before{content:"\f343";font-family:dashicons;visibility:initial;color:#666;font-size:25px;margin-top:-7px;margin-left:-5px;position:absolute;visibility:visible}.wc-wizard-services-list-toggle.closed .wc-wizard-service-enable::before{content:"\f347"}.wc-wizard-services-list-toggle .wc-wizard-service-enable input{visibility:hidden;position:relative}.wc-wizard-services.manual .wc-wizard-service-item{display:none}.wc-wizard-services.shipping .wc-wizard-service-name{font-weight:400;text-align:left;-webkit-box-align:center;-ms-flex-align:center;align-items:center;max-height:5em;padding:0}.wc-wizard-services.shipping .wc-wizard-service-item{padding-left:2em;padding-top:.67em}.wc-wizard-services.shipping .wc-wizard-service-item:first-child{border-bottom:0;padding-bottom:0;font-weight:700}.wc-wizard-services.shipping .wc-wizard-service-item:first-child .wc-wizard-service-name{font-weight:700}.wc-wizard-services.shipping .shipping-method-setting,.wc-wizard-services.shipping .wc-wizard-shipping-method-select{display:-webkit-box;display:-ms-flexbox;display:flex}.wc-wizard-services.shipping .shipping-method-setting.hide,.wc-wizard-services.shipping .wc-wizard-shipping-method-select.hide{display:none}.wc-wizard-services.shipping .shipping-method-setting input,.wc-wizard-services.shipping .wc-wizard-shipping-method-dropdown{margin-right:2em;margin-bottom:1em}.wc-wizard-services.shipping .shipping-method-setting input .select2,.wc-wizard-services.shipping .wc-wizard-shipping-method-dropdown .select2{min-width:130px}.wc-wizard-services.shipping .wc-wizard-service-description{display:-webkit-box;display:-ms-flexbox;display:flex;-webkit-box-orient:vertical;-webkit-box-direction:normal;-ms-flex-direction:column;flex-direction:column;color:#a6a6a6}.wc-wizard-services.shipping .wc-wizard-service-item:not(:first-child) .wc-wizard-service-description{font-size:.92em;padding-bottom:10px}.wc-wizard-services.shipping .shipping-method-setting input{width:95px;border:1px solid #aaa;border-color:#ddd;border-radius:4px;height:28px;padding-left:8px;padding-right:24px;font-size:14px;color:#444;background-color:#fff;display:inline-block}.wc-wizard-services.shipping .shipping-method-description,.wc-wizard-services.shipping .shipping-method-setting .description{color:#7e7e7e;font-size:.9em}.wc-wizard-services.shipping .shipping-method-setting input::-webkit-input-placeholder{color:#e1e1e1}.wc-wizard-services.shipping .shipping-method-setting input::-moz-placeholder{color:#e1e1e1}.wc-wizard-services.shipping .shipping-method-setting input:-ms-input-placeholder{color:#e1e1e1}.wc-wizard-services.shipping .shipping-method-setting input::placeholder{color:#e1e1e1}.wc-setup-shipping-units p{line-height:1.5em;font-size:13px;margin-bottom:.25em}.wc-setup-shipping-units .wc-setup-shipping-unit{margin-bottom:1.75em}.wc-setup-shipping-units .wc-setup-shipping-unit .select2{min-width:100%}.hide{display:none}.wc-wizard-features{display:-webkit-box;display:-ms-flexbox;display:flex;-ms-flex-wrap:wrap;flex-wrap:wrap;list-style:none;padding:0}.wc-wizard-features .wc-wizard-feature-item{-ms-flex-preferred-size:calc(50% - 4em - 3px);flex-basis:calc(50% - 4em - 3px);border:1px solid #eee;padding:2em}.wc-wizard-features .wc-wizard-feature-item:nth-child(1){border-radius:4px 0 0 0}.wc-wizard-features .wc-wizard-feature-item:nth-child(2){border-left:0;border-radius:0 4px 0 0}.wc-wizard-features .wc-wizard-feature-item:nth-child(3){border-top:0;border-radius:0 0 0 4px}.wc-wizard-features .wc-wizard-feature-item:nth-child(4){border-top:0;border-left:0;border-radius:0 0 4px 0}.wc-wizard-features p.wc-wizard-feature-description,.wc-wizard-features p.wc-wizard-feature-name{margin:0;line-height:1.5em}h3.jetpack-reasons{text-align:center;margin:3em 0 1em 0;font-size:14px}.jetpack-logo,.wcs-notice{display:block;margin:1.75em auto 2em auto;max-height:175px}.activate-splash .jetpack-logo{width:170px;margin-bottom:0}.activate-splash .wcs-notice{margin-top:1em;padding-left:57px}.step{text-align:center}.wc-setup .wc-setup-actions .button{font-weight:300;font-size:16px;padding:1em 2em;box-shadow:none;min-width:12em;min-width:auto;margin-top:10px}.wc-setup .wc-setup-actions .button:active,.wc-setup .wc-setup-actions .button:focus,.wc-setup .wc-setup-actions .button:hover{box-shadow:none}.location-prompt{color:#666;font-size:13px;font-weight:500;margin-bottom:.5em;margin-top:.85em;display:inline-block}.location-input{border:1px solid #aaa;border-color:#ddd;border-radius:4px;height:30px;width:calc(100% - 8px - 24px - 2px);padding-left:8px;padding-right:24px;font-size:16px;color:#444;background-color:#fff;display:inline-block}.location-input.dropdown{width:100%}.address-step .select2{min-width:100%}.store-address-container .city-and-postcode{display:-webkit-box;display:-ms-flexbox;display:flex}.store-address-container .city-and-postcode div{-ms-flex-preferred-size:50%;flex-basis:50%;margin-right:1em}.store-address-container .city-and-postcode div:last-of-type{margin-right:0}.store-address-container .select2-container,.store-address-container input[type=text],.store-address-container select{margin-bottom:10px}.product-type-container{margin-top:14px;margin-bottom:1px}#woocommerce_sell_in_person{margin-left:0}.wc-wizard-service-settings .payment-email-input{border:1px solid #aaa;border-color:#ddd;border-radius:4px;height:30px;padding:0 8px;font-size:14px;color:#444;background-color:#fff;display:inline-block}.newsletter-form-container{display:-webkit-box;display:-ms-flexbox;display:flex}.newsletter-form-container .newsletter-form-email{border:1px solid #aaa;border-color:#ddd;border-radius:4px;height:42px;padding:0 8px;font-size:16px;color:#666;background-color:#fff;display:inline-block;margin-right:6px;-webkit-box-flex:1;-ms-flex-positive:1;flex-grow:1}.newsletter-form-container .newsletter-form-button-container{-webkit-box-flex:0;-ms-flex-positive:0;flex-grow:0}.wc-setup .wc-setup-actions .button.newsletter-form-button{height:42px;padding:0 1em;margin:0}.wc-wizard-next-steps{border:1px solid #eee;border-radius:4px;list-style:none;padding:0}.wc-wizard-next-steps li{padding:0}.wc-wizard-next-steps .wc-wizard-next-step-item{display:-webkit-box;display:-ms-flexbox;display:flex;border-top:1px solid #eee}.wc-wizard-next-steps .wc-wizard-next-step-item:first-child{border-top:0}.wc-wizard-next-steps .wc-wizard-next-step-description{-webkit-box-flex:1;-ms-flex-positive:1;flex-grow:1;margin:1.5em}.wc-wizard-next-steps .wc-wizard-next-step-action{-webkit-box-flex:0;-ms-flex-positive:0;flex-grow:0;display:-webkit-box;display:-ms-flexbox;display:flex;-webkit-box-align:center;-ms-flex-align:center;align-items:center}.wc-wizard-next-steps .wc-wizard-next-step-action .button{margin:1em 1.5em}.wc-wizard-next-steps p.next-step-heading{margin:0;font-size:.95em;font-weight:400;font-variant:all-petite-caps}.wc-wizard-next-steps p.next-step-extra-info{margin:0}.wc-wizard-next-steps h3.next-step-description{margin:0;font-size:16px;font-weight:600}.wc-wizard-next-steps .wc-wizard-additional-steps{border-top:1px solid #eee}.wc-wizard-next-steps .wc-wizard-additional-steps .wc-wizard-next-step-description{margin-bottom:0}.wc-wizard-next-steps .wc-wizard-additional-steps .wc-setup-actions{margin:0 0 1.5em 0}.wc-wizard-next-steps .wc-wizard-additional-steps .wc-setup-actions .button{font-size:15px;margin:1em 0 1em 1.5em}.wc-wizard-next-steps .wc-wizard-additional-steps .wc-setup-actions .button::last-child{margin-right:1.5em}p.next-steps-help-text{color:#9f9f9f;padding:0 2em;text-align:center;font-size:.9em}p.jetpack-terms{font-size:.8em;text-align:center;max-width:480px;margin:0 auto;line-height:1.5em}.woocommerce-error{background:#ffe6e5;border-color:#ffc5c2;padding:1em;margin-bottom:1em}.woocommerce-error p{margin-top:0;margin-bottom:.5em;color:#444}.woocommerce-error a{color:#ff645c}.woocommerce-error .reconnect-reminder{font-size:.85em}.woocommerce-error .wc-setup-actions .button{font-size:14px}.wc-wizard-service-setting-ppec_paypal_reroute_requests,.wc-wizard-service-setting-stripe_create_account{display:-webkit-box;display:-ms-flexbox;display:flex;-webkit-box-align:start;-ms-flex-align:start;align-items:flex-start;margin-top:.75em}.wc-wizard-service-setting-ppec_paypal_reroute_requests .payment-checkbox-input,.wc-wizard-service-setting-stripe_create_account .payment-checkbox-input{-webkit-box-ordinal-group:2;-ms-flex-order:1;order:1;margin-top:5px;margin-left:0;margin-right:0;width:1.5em}.wc-wizard-service-setting-ppec_paypal_reroute_requests .ppec_paypal_reroute_requests,.wc-wizard-service-setting-ppec_paypal_reroute_requests .stripe_create_account,.wc-wizard-service-setting-stripe_create_account .ppec_paypal_reroute_requests,.wc-wizard-service-setting-stripe_create_account .stripe_create_account{-webkit-box-ordinal-group:3;-ms-flex-order:2;order:2;margin-left:.3em}.wc-wizard-service-setting-ppec_paypal_email,.wc-wizard-service-setting-stripe_email{margin-top:.75em}.wc-wizard-service-setting-ppec_paypal_email label.ppec_paypal_email,.wc-wizard-service-setting-ppec_paypal_email label.stripe_email,.wc-wizard-service-setting-stripe_email label.ppec_paypal_email,.wc-wizard-service-setting-stripe_email label.stripe_email{position:absolute;margin:-1px;padding:0;height:1px;width:1px;overflow:hidden;clip:rect(0 0 0 0);border:0}.wc-wizard-service-setting-ppec_paypal_email input.payment-email-input,.wc-wizard-service-setting-stripe_email input.payment-email-input{margin-left:1.5em;margin-bottom:.5em;width:100%}.wc-wizard-service-setting-ppec_paypal_email .wc-wizard-service-settings-description,.wc-wizard-service-setting-stripe_email .wc-wizard-service-settings-description{margin-left:1.5em}.recommended-step{border:1px solid #ebebeb;border-radius:4px;padding:2.5em}.recommended-step li{list-style:none}.recommended-step li:last-child .recommended-item{margin-bottom:0}.recommended-step .recommended-item{display:-webkit-box;display:-ms-flexbox;display:flex;-webkit-box-align:center;-ms-flex-align:center;align-items:center;margin-bottom:1.5em}.recommended-step .recommended-item-icon{border:1px solid #fff;border-radius:7px;height:3.5em;margin-right:1em;margin-left:1em}.recommended-step .recommended-item-icon.recommended-item-icon-storefront_theme{background-color:#f4a224;max-height:3em;max-width:3em;padding:.25em}.recommended-step .recommended-item-icon.recommended-item-icon-automated_taxes{background-color:#d0011b;max-height:1.75em;padding:.875em}.recommended-step .recommended-item-icon.recommended-item-icon-mailchimp{background-color:#209bbb;height:2em;padding:.75em}.recommended-step .recommended-item-description-container h3{font-size:15px;font-weight:700;letter-spacing:.5px;margin-bottom:0}.recommended-step .recommended-item-description-container p{margin-top:0;line-height:1.5em} \ No newline at end of file diff --git a/assets/css/wc-setup.scss b/assets/css/wc-setup.scss index 0631d4de132..c84b233414f 100644 --- a/assets/css/wc-setup.scss +++ b/assets/css/wc-setup.scss @@ -1239,6 +1239,12 @@ p.jetpack-terms { max-height: 1.75em; padding: ( 3.5em - 1.75em ) / 2; } + + &.recommended-item-icon-mailchimp { + background-color: #209bbb; + height: 2em; + padding: ( 3.5em - 2em ) / 2; + } } .recommended-item-description-container { diff --git a/assets/images/obw-mailchimp-icon.svg b/assets/images/obw-mailchimp-icon.svg new file mode 100644 index 00000000000..73f72b88bc9 --- /dev/null +++ b/assets/images/obw-mailchimp-icon.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/includes/admin/class-wc-admin-setup-wizard.php b/includes/admin/class-wc-admin-setup-wizard.php index 8028c309a10..59ce5b3c16f 100644 --- a/includes/admin/class-wc-admin-setup-wizard.php +++ b/includes/admin/class-wc-admin-setup-wizard.php @@ -121,6 +121,16 @@ class WC_Admin_Setup_Wizard { return in_array( $country_code, $tax_supported_countries, true ); } + /** + * Should we show the MailChimp install option? + * True only if the user can install plugins. + * + * @return boolean + */ + protected function should_show_mailchimp() { + return current_user_can( 'install_plugins' ); + } + /** * Should we display the 'Recommended' step? * True if at least one of the recommendations will be displayed. @@ -129,7 +139,8 @@ class WC_Admin_Setup_Wizard { */ protected function should_show_recommended_step() { return $this->should_show_theme() - || $this->should_show_automated_tax(); + || $this->should_show_automated_tax() + || $this->should_show_mailchimp(); } /** @@ -1637,6 +1648,16 @@ class WC_Admin_Setup_Wizard { 'img_alt' => __( 'automated taxes icon', 'woocommerce' ), ) ); endif; + + if ( $this->should_show_mailchimp() ) : + $this->display_recommended_item( array( + 'type' => 'mailchimp', + 'title' => __( 'MailChimp', 'woocommerce' ), + 'description' => __( 'Join the 16 million customers who use MailChimp. Sync list and store data to send automated emails, and targeted campaigns.', 'woocommerce' ), + 'img_url' => WC()->plugin_url() . '/assets/images/obw-mailchimp-icon.svg', + 'img_alt' => __( 'MailChimp icon', 'woocommerce' ), + ) ); + endif; ?>

    @@ -1655,6 +1676,7 @@ class WC_Admin_Setup_Wizard { $setup_storefront = isset( $_POST['setup_storefront_theme'] ) && 'yes' === $_POST['setup_storefront_theme']; $setup_automated_tax = isset( $_POST['setup_automated_taxes'] ) && 'yes' === $_POST['setup_automated_taxes']; + $setup_mailchimp = isset( $_POST['setup_mailchimp'] ) && 'yes' === $_POST['setup_mailchimp']; update_option( 'woocommerce_calc_taxes', $setup_automated_tax ? 'yes' : 'no' ); update_option( 'woocommerce_setup_automated_taxes', $setup_automated_tax ); @@ -1667,6 +1689,17 @@ class WC_Admin_Setup_Wizard { $this->install_woocommerce_services(); } + if ( $setup_mailchimp ) { + $this->install_plugin( + 'mailchimp-for-woocommerce', + array( + 'name' => __( 'MailChimp for WooCommerce', 'woocommerce' ), + 'repo-slug' => 'mailchimp-for-woocommerce', + 'file' => 'mailchimp-woocommerce.php', + ) + ); + } + wp_redirect( esc_url_raw( $this->get_next_step_link() ) ); exit; } From 43ab4b25ae87fd01fa7b6b9565c5663d2f6fb535 Mon Sep 17 00:00:00 2001 From: Valerie Date: Sat, 14 Apr 2018 23:56:53 -0400 Subject: [PATCH 50/61] OBW: Update Recommended step description --- includes/admin/class-wc-admin-setup-wizard.php | 14 ++++++++++++++ 1 file changed, 14 insertions(+) diff --git a/includes/admin/class-wc-admin-setup-wizard.php b/includes/admin/class-wc-admin-setup-wizard.php index 59ce5b3c16f..afb62ea2fa3 100644 --- a/includes/admin/class-wc-admin-setup-wizard.php +++ b/includes/admin/class-wc-admin-setup-wizard.php @@ -1621,6 +1621,20 @@ class WC_Admin_Setup_Wizard { public function wc_setup_recommended() { ?>

    +

    should_show_theme() + && $this->should_show_automated_tax() + && $this->should_show_mailchimp() + ) : + esc_html_e( 'Select from the list below to enable automated taxes and MailChimp’s best-in-class email services β€” and design your store with our official, free WooCommerce theme.', 'woocommerce' ); + else : + esc_html_e( 'Enhance your store with these recommended features.', 'woocommerce' ); + endif; + ?>