Version Description
Download this release
Release Info
Developer | louwie17 |
Plugin | WooCommerce Admin |
Version | 3.0.3 |
Comparing to | |
See all releases |
Code changes from version 3.0.2 to 3.0.3
- changelog.txt +5 -0
- languages/woocommerce-admin.pot +4 -4
- readme.txt +1 -1
- src/Composer/Package.php +1 -1
- src/FeaturePlugin.php +1 -1
- src/Features/WcPayPromotion/Init.php +7 -0
- trunk/changelog.txt +1653 -0
- trunk/dist/activity-panels-help/style-rtl.css +1 -0
- trunk/dist/activity-panels-inbox/style-rtl.css +1 -0
- trunk/dist/analytics-report-categories/style-rtl.css +1 -0
- trunk/dist/analytics-report-customers/style-rtl.css +1 -0
- trunk/dist/analytics-report-orders/style-rtl.css +1 -0
- trunk/dist/analytics-report-products/style-rtl.css +1 -0
- trunk/dist/analytics-report-stock/style-rtl.css +1 -0
- trunk/dist/analytics-report/style-rtl.css +1 -0
- trunk/dist/analytics-settings/style-rtl.css +1 -0
- trunk/dist/app/index.js +13091 -0
- trunk/dist/app/index.min.asset.php +1 -0
- trunk/dist/app/index.min.js +2 -0
- trunk/dist/app/style-rtl.css +1 -0
- trunk/dist/app/style.css +1 -0
- trunk/dist/app/style.rtl.css +1 -0
- trunk/dist/beta-features-tracking-modal/style-rtl.css +1 -0
- trunk/dist/beta-features-tracking-modal/style.css +1 -0
- trunk/dist/beta-features-tracking-modal/style.rtl.css +1 -0
- trunk/dist/chunks/0.js +1820 -0
- trunk/dist/chunks/0.min.js +1 -0
- trunk/dist/chunks/0.style.css +1 -0
- trunk/dist/chunks/0.style.rtl.css +1 -0
- trunk/dist/chunks/1.js +1365 -0
- trunk/dist/chunks/1.min.js +2 -0
- trunk/dist/chunks/10.style.css +1 -0
- trunk/dist/chunks/10.style.rtl.css +1 -0
- trunk/dist/chunks/11.style.css +1 -0
- trunk/dist/chunks/11.style.rtl.css +1 -0
- trunk/dist/chunks/12.style.css +1 -0
- trunk/dist/chunks/12.style.rtl.css +1 -0
- trunk/dist/chunks/13.style.css +1 -0
- trunk/dist/chunks/14.style.css +1 -0
- trunk/dist/chunks/14.style.rtl.css +1 -0
- trunk/dist/chunks/15.style.css +1 -0
- trunk/dist/chunks/15.style.rtl.css +1 -0
- trunk/dist/chunks/16.style.css +1 -0
- trunk/dist/chunks/17.style.css +1 -0
- trunk/dist/chunks/17.style.rtl.css +1 -0
- trunk/dist/chunks/2.js +1143 -0
- trunk/dist/chunks/2.min.js +1 -0
changelog.txt
CHANGED
@@ -1,3 +1,8 @@
|
|
|
|
|
|
|
|
|
|
|
|
1 |
== 3.0.2 01/05/2022 ==
|
2 |
|
3 |
- Render the activity panel when the experimental tasklist is hidden. #8111
|
1 |
+
== 3.0.3 01/06/2022 ==
|
2 |
+
|
3 |
+
- Fix: Fix blank payment gateway method in table when WooCommerce Payments is not supported. #8122
|
4 |
+
- Add: Add woocommerce_allow_marketplace_suggestions filter to WooCommerce Payments payment method promotion. #8117
|
5 |
+
|
6 |
== 3.0.2 01/05/2022 ==
|
7 |
|
8 |
- Render the activity panel when the experimental tasklist is hidden. #8111
|
languages/woocommerce-admin.pot
CHANGED
@@ -2,10 +2,10 @@
|
|
2 |
# This file is distributed under the same license as the WooCommerce Admin package.
|
3 |
msgid ""
|
4 |
msgstr ""
|
5 |
-
"Project-Id-Version: WooCommerce Admin 3.0.
|
6 |
"Report-Msgid-Bugs-To: "
|
7 |
-
"https://wordpress.org/support/plugin/woocommerce-admin
|
8 |
-
"POT-Creation-Date: 2022-01-
|
9 |
"MIME-Version: 1.0\n"
|
10 |
"Content-Type: text/plain; charset=utf-8\n"
|
11 |
"Content-Transfer-Encoding: 8bit\n"
|
@@ -123,8 +123,8 @@ msgstr ""
|
|
123 |
#: src/API/Reports/Taxes/Controller.php:307
|
124 |
#: src/API/Reports/Variations/Controller.php:416 src/Features/Analytics.php:228
|
125 |
#: src/Features/Navigation/CoreMenu.php:95 src/ReportCSVEmail.php:36
|
126 |
-
#: client/analytics/report/get-reports.js:78
|
127 |
#: client/analytics/report/revenue/table.js:65
|
|
|
128 |
#: client/analytics/report/taxes/config.js:47
|
129 |
#: client/analytics/report/taxes/table.js:58
|
130 |
#: client/analytics/report/variations/config.js:44
|
2 |
# This file is distributed under the same license as the WooCommerce Admin package.
|
3 |
msgid ""
|
4 |
msgstr ""
|
5 |
+
"Project-Id-Version: WooCommerce Admin 3.0.3\n"
|
6 |
"Report-Msgid-Bugs-To: "
|
7 |
+
"https://wordpress.org/support/plugin/woocommerce-admin\n"
|
8 |
+
"POT-Creation-Date: 2022-01-06 22:39:14+00:00\n"
|
9 |
"MIME-Version: 1.0\n"
|
10 |
"Content-Type: text/plain; charset=utf-8\n"
|
11 |
"Content-Transfer-Encoding: 8bit\n"
|
123 |
#: src/API/Reports/Taxes/Controller.php:307
|
124 |
#: src/API/Reports/Variations/Controller.php:416 src/Features/Analytics.php:228
|
125 |
#: src/Features/Navigation/CoreMenu.php:95 src/ReportCSVEmail.php:36
|
|
|
126 |
#: client/analytics/report/revenue/table.js:65
|
127 |
+
#: client/analytics/report/get-reports.js:78
|
128 |
#: client/analytics/report/taxes/config.js:47
|
129 |
#: client/analytics/report/taxes/table.js:58
|
130 |
#: client/analytics/report/variations/config.js:44
|
readme.txt
CHANGED
@@ -4,7 +4,7 @@ Tags: ecommerce, e-commerce, store, sales, reports, analytics, dashboard, activi
|
|
4 |
Requires at least: 5.4.0
|
5 |
Tested up to: 5.8.2
|
6 |
Requires PHP: 7.0
|
7 |
-
Stable tag: 3.0.
|
8 |
License: GPLv3
|
9 |
License URI: https://github.com/woocommerce/woocommerce-admin/blob/main/license.txt
|
10 |
|
4 |
Requires at least: 5.4.0
|
5 |
Tested up to: 5.8.2
|
6 |
Requires PHP: 7.0
|
7 |
+
Stable tag: 3.0.3
|
8 |
License: GPLv3
|
9 |
License URI: https://github.com/woocommerce/woocommerce-admin/blob/main/license.txt
|
10 |
|
src/Composer/Package.php
CHANGED
@@ -26,7 +26,7 @@ class Package {
|
|
26 |
*
|
27 |
* @var string
|
28 |
*/
|
29 |
-
const VERSION = '3.0.
|
30 |
|
31 |
/**
|
32 |
* Package active.
|
26 |
*
|
27 |
* @var string
|
28 |
*/
|
29 |
+
const VERSION = '3.0.3';
|
30 |
|
31 |
/**
|
32 |
* Package active.
|
src/FeaturePlugin.php
CHANGED
@@ -147,7 +147,7 @@ class FeaturePlugin {
|
|
147 |
$this->define( 'WC_ADMIN_PLUGIN_FILE', WC_ADMIN_ABSPATH . 'woocommerce-admin.php' );
|
148 |
// WARNING: Do not directly edit this version number constant.
|
149 |
// It is updated as part of the prebuild process from the package.json value.
|
150 |
-
$this->define( 'WC_ADMIN_VERSION_NUMBER', '3.0.
|
151 |
}
|
152 |
|
153 |
/**
|
147 |
$this->define( 'WC_ADMIN_PLUGIN_FILE', WC_ADMIN_ABSPATH . 'woocommerce-admin.php' );
|
148 |
// WARNING: Do not directly edit this version number constant.
|
149 |
// It is updated as part of the prebuild process from the package.json value.
|
150 |
+
$this->define( 'WC_ADMIN_VERSION_NUMBER', '3.0.3' );
|
151 |
}
|
152 |
|
153 |
/**
|
src/Features/WcPayPromotion/Init.php
CHANGED
@@ -102,7 +102,14 @@ class Init {
|
|
102 |
if ( 'no' === get_option( 'woocommerce_show_marketplace_suggestions', 'yes' ) ) {
|
103 |
return false;
|
104 |
}
|
|
|
|
|
|
|
105 |
|
|
|
|
|
|
|
|
|
106 |
return true;
|
107 |
}
|
108 |
|
102 |
if ( 'no' === get_option( 'woocommerce_show_marketplace_suggestions', 'yes' ) ) {
|
103 |
return false;
|
104 |
}
|
105 |
+
if ( ! apply_filters( 'woocommerce_allow_marketplace_suggestions', true ) ) {
|
106 |
+
return false;
|
107 |
+
}
|
108 |
|
109 |
+
$wc_pay_spec = self::get_wc_pay_promotion_spec();
|
110 |
+
if ( ! $wc_pay_spec ) {
|
111 |
+
return false;
|
112 |
+
}
|
113 |
return true;
|
114 |
}
|
115 |
|
trunk/changelog.txt
ADDED
@@ -0,0 +1,1653 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
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|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
== 3.0.3 01/06/2022 ==
|
2 |
+
|
3 |
+
- Fix: Fix blank payment gateway method in table when WooCommerce Payments is not supported. #8122
|
4 |
+
- Add: Add woocommerce_allow_marketplace_suggestions filter to WooCommerce Payments payment method promotion. #8117
|
5 |
+
|
6 |
+
== 3.0.2 01/05/2022 ==
|
7 |
+
|
8 |
+
- Render the activity panel when the experimental tasklist is hidden. #8111
|
9 |
+
|
10 |
+
== 3.0.1 12/30/2021 ==
|
11 |
+
|
12 |
+
- Do not initialize WC Pay promotion if spec is empty. #8087
|
13 |
+
|
14 |
+
== 3.0.0 12/28/2021 ==
|
15 |
+
|
16 |
+
- Fix: Fix an issue with the code that makes use of an invalid parameter with a PHP function. The use of this invalid parameter causes PHP 8 to throw a Fatal Error. #7855
|
17 |
+
- Fix: Fix TaskList UI experiment enablement logic. #7930
|
18 |
+
- Fix: Navigation nudge note and navigation feedback notes will delete themselves if the navigation feature is not available. #7914
|
19 |
+
- Fix: Replace old task list option calls with data store selectors. #7820
|
20 |
+
- Fix: Self-delete NavigationFeedbackFollowUp note when navigation feature is not present. #7939
|
21 |
+
- Fix: Fix PHP Warning on 'Add new product' page. #7989
|
22 |
+
- Fix: Fix usage of Wordpress DatePicker component. #7982
|
23 |
+
- Fix: Fix shipping task completion status. #8031
|
24 |
+
- Add: Add option to dismiss promotional payment gateway. #7965
|
25 |
+
- Add: OBW - Add number of employees field. #7963
|
26 |
+
- Update: Ending wcpay promotion experiment and always displaying in payment methods table.
|
27 |
+
- Update: Hide InboxPanel header when it is rendered in the sidebar. #7952
|
28 |
+
- Update: Introduce a 320 character limit for inbox note contents. #7958
|
29 |
+
- Update: Move payments task to extended task list when WC Pay task is shown. #7980
|
30 |
+
- Update: Rename Inbox to Activity from the activity header. #7879
|
31 |
+
- Update: Load both actioned and unactioned notes. #7983
|
32 |
+
- Dev: Explicitly sets the Node version to 14 in .nvmrc to prevent incompatible versions of Node from being used with nvm. #7932
|
33 |
+
- Dev: Remove unused npm package @woocommerce/settings. #7949
|
34 |
+
- Dev: Update payment method recommendation to new woocommerce.com endpoint. #7913
|
35 |
+
- Dev: Use abstraction to add and retrieve task data. #7918
|
36 |
+
- Tweak: Added dismiss all button for inbox notes.
|
37 |
+
- Tweak: Implement note read state. #7896
|
38 |
+
- Tweak: Add inbox_panel_view tracks event. #8002
|
39 |
+
- Enhancement: Add tests to Subscriptions inclusion. #7804
|
40 |
+
|
41 |
+
== 2.9.3 12/15/2021 ==
|
42 |
+
|
43 |
+
- Fix: Correctly match payment gateways by id #7994
|
44 |
+
|
45 |
+
== 2.9.2 12/13/2021 ==
|
46 |
+
|
47 |
+
- Fix: Fix shipping task completion status #8031
|
48 |
+
|
49 |
+
== 2.9.1 12/07/2021 ==
|
50 |
+
|
51 |
+
- Fix: Fix shipping task not offering step 3. #7985
|
52 |
+
|
53 |
+
== 2.9.0 11/30/2021 ==
|
54 |
+
|
55 |
+
- Fix: Do not clear `current` class from the entire page when updating wp-admin's menu. #7773
|
56 |
+
- Fix: Fix calendar not being dismissed when clicking outside. #7714
|
57 |
+
- Fix: fixed warnings when using AdvancedFilters component. #7704
|
58 |
+
- Fix: Fix Tasklist UI illustrations styling #7858
|
59 |
+
- Fix: Revert experiment task titles back to original #7853
|
60 |
+
- Fix: Fix ordering and styling issue with WooCommerce Payments payment method promotion. #7943
|
61 |
+
- Fix: Fix ExPlat PHP client #7926
|
62 |
+
- Fix: Fix marketing extensions tracks #7908
|
63 |
+
- Fix: Ensure homescreen defaults to single column layout. #7969
|
64 |
+
- Add: Add 2col expirement. #7872
|
65 |
+
- Add: Add Avalara to tax task #7874
|
66 |
+
- Add: Added two column experimental task list #7669
|
67 |
+
- Add: Add header cards for all tasks in Tasklist UI experiment #7838
|
68 |
+
- Add: Add onboarding task docs #7762
|
69 |
+
- Update: Add marketing extensions back to onboarding wizard #7831
|
70 |
+
- Update: Add profile notes. #7861
|
71 |
+
- Update: Change CTA text for personalize store task after completion #7852
|
72 |
+
- Update: Increased number of possible items in Recommended Extensions list from 6 to 9 #7887
|
73 |
+
- Update: Refactor data source poller for re-usability. #7671
|
74 |
+
- Update: Reverts addition of Marketplace and My Subscriptions pages to the Marketplace menu. #7902
|
75 |
+
- Update: Update the inbox panel with the new design #7864
|
76 |
+
- Update: Update WC Pay card to include in-person information #7830
|
77 |
+
- Update: Updating navigation link colors #7833
|
78 |
+
- Dev: Add method to check for install status #7808
|
79 |
+
- Dev: Refactor tax task into separate components
|
80 |
+
- Dev: Update the task list to use the new task list REST API #7736
|
81 |
+
- Dev: Remove task status endpoint #7841
|
82 |
+
- Tweak: Add route and layout for unmatched path #7503
|
83 |
+
- Tweak: Avoid caching extended info #7819
|
84 |
+
- Tweak: Minor design update for Marketing task. #7732
|
85 |
+
- Tweak: Remove the Spinner component to prevent undesired page flickering. #7886
|
86 |
+
- Tweak: Use page title Extensions for Marketplace and My Subscriptions pages. #7901
|
87 |
+
- Performance: Only load default tasks during REST requests #7904
|
88 |
+
|
89 |
+
== 2.8.0 11/02/2021 ==
|
90 |
+
|
91 |
+
- Add: Store Profiler and Product task - include Subscriptions #7734
|
92 |
+
- Fix: Fix issue where stock activity panel was not rendering correctly. #7817
|
93 |
+
- Fix: Increase CSS specificity to avoid conflicts and broken panel styling. #7813
|
94 |
+
- Fix: Updated link to WooCommerce Developers Blog in readme.txt #7824
|
95 |
+
- Fix: Fixed navigation menu text color after Gutenberg 11.6.0 #7771
|
96 |
+
- Fix: Add status param to notes/delete/all REST endpoint, to correctly delete all notes. #7743
|
97 |
+
- Fix: Allow already installed marketing extensions to be activated #7740
|
98 |
+
- Fix: Add missing title text for marketing task. #7640
|
99 |
+
- Fix: Assign parent order status as children order status if refund order #7253
|
100 |
+
- Fix: Fix category lookup logic to update children correctly. #7709
|
101 |
+
- Fix: Fixing an unwanted page refresh when using Woo Navigation. #7615
|
102 |
+
- Fix: Fix naming of event names and properties. #7677
|
103 |
+
- Fix: Fix white screen for variation analytic data without a name. #7686
|
104 |
+
- Update: Update back up copy of free extension for Google Listing & Ads plugin. #7798
|
105 |
+
- Update: Update Eway payment gateway capitalization (was eWAY). #7678
|
106 |
+
- Update: Enable Square in France. #7679
|
107 |
+
- Update: Update WC pay supported country list for the default free extensions. #7873
|
108 |
+
- Enhancement: Add experiment for promoting WooCommerce Payments in payment methods table. #7666
|
109 |
+
- Performance: Only load tasks during rest api requests #7856
|
110 |
+
|
111 |
+
== 2.7.2 10/11/2021 ==
|
112 |
+
|
113 |
+
- Fix: Fix analytics crashing on daylight saving #7763
|
114 |
+
|
115 |
+
== 2.7.1 10/01/2021 ==
|
116 |
+
|
117 |
+
- Fix: Allow super admins all capabilities within WooCommerce Admin #7489
|
118 |
+
- Fix: Fix end date for last periods #6584
|
119 |
+
- Fix: Fix up onboarding profiler not working when opted out of tracking #7490
|
120 |
+
- Fix: Making Business Details sticky in onboarding wizard #7426
|
121 |
+
- Fix: Missing RTL for onboarding styles. #7531
|
122 |
+
- Fix: Skip scheduling action if Action Scheduler tables have not been set up #7521
|
123 |
+
- Fix: Update country region typeahead for better autofill support. #7497
|
124 |
+
- Fix: Use installable extensions for local state versus free extensions. #7585
|
125 |
+
- Fix: Fix fatal error and unrelated results in analytics. #7682
|
126 |
+
- Fix: Harden the reports directory #7691
|
127 |
+
- Fix: Update task-item logic to only display content when expanded is true. #7611
|
128 |
+
- Add: Show Pinterest in installed marketing extensions (if installed) #7417
|
129 |
+
- Add: Added MailchimpScheduler that runs daily to subscribe store_email in the profile data #7579
|
130 |
+
- Add: Added shipping plugin recommendations to settings page (#7446).
|
131 |
+
- Add: Adding endpoint to snooze onboarding task #7539
|
132 |
+
- Add: Adding undo snooze task endpoint #7560
|
133 |
+
- Add: Add task dismissal endpoints #7538
|
134 |
+
- Update: Add HK and SG countries to WC Pay intl support. #7558
|
135 |
+
- Update: Create task list REST API endpoint #7512
|
136 |
+
- Update: Deleted OnboardingEmailMarketing note class #7595
|
137 |
+
- Update: Removes the use of the depreciated woocommerce_shared_settings hook. #7480
|
138 |
+
- Update: Removes non WooCommerce Admin specific settings from the `wc_admin` namespace in the `wc/data` settings store (ex
|
139 |
+
- Update: Updating eway logo in payment suggestions defaults #7562
|
140 |
+
- Update: Update marketing task completion logic. #7586
|
141 |
+
- Dev: Add email address field to OBW #7552
|
142 |
+
- Tweak: Add navigation items for the Marketplace menu. #7529
|
143 |
+
- Tweak: Change all analytics strings and labels to sentence case. #6501
|
144 |
+
- Tweak: Delete unneeded double spaces in text strings. #7502
|
145 |
+
- Tweak: Remove the preloaded onboarding options #7338
|
146 |
+
- Tweak: Update analytics card header text styles #6506
|
147 |
+
- Enhancement: Align Table fields with the fallback on isNumeric. #7431
|
148 |
+
|
149 |
+
== 2.6.5 09/22/2021 ==
|
150 |
+
|
151 |
+
- Fix: Add filters to get new hidden options #7698
|
152 |
+
|
153 |
+
== 2.6.4 09/21/2021 ==
|
154 |
+
|
155 |
+
- Fix: Use installable extensions for local state versus free extensions. #7585
|
156 |
+
|
157 |
+
== 2.6.3 09/21/2021 ==
|
158 |
+
|
159 |
+
== 2.6.2 09/14/2021 ==
|
160 |
+
|
161 |
+
== 2.6.1 09/01/2021 ==
|
162 |
+
|
163 |
+
- Update: Update marketing task completion logic. #7586
|
164 |
+
|
165 |
+
== 2.6.0 08/31/2021 ==
|
166 |
+
|
167 |
+
- Fix: Fixes action button mis-alignment within card footer. #7412
|
168 |
+
- Fix: Fixing issues with ReportTable component data not populating correctly #7355
|
169 |
+
- Fix: Fix tracks events for payment gateway suggestions #7304
|
170 |
+
- Fix: Update status values in CSV download to match the table #7284
|
171 |
+
- Fix: Allow super admins all capabilities within WooCommerce Admin #7489
|
172 |
+
- Fix: Fix blank screen by setting a default value #7506
|
173 |
+
- Fix: Fix analytics overview re-arrangement on initial load. #7475
|
174 |
+
- Fix: Fix up onboarding profiler not working when opted out of tracking #7490
|
175 |
+
- Fix: Fix blank screen on analytics screens when searching #7482
|
176 |
+
- Fix: Fix all links with hash to behind query parameters #7483
|
177 |
+
- Fix: Fix Stats module CSS issue introduced by Gutenberg #7488
|
178 |
+
- Fix: Fix marketing task visibility #7580
|
179 |
+
- Fix: Fix stats-overview card padding issue #7594
|
180 |
+
- Fix: Fix layout issue on marketing task #7598
|
181 |
+
- Add: Add boolean isReverseTrend prop to SummaryNumber to show "positive" delta for negative numbers. #7357
|
182 |
+
- Add: Adding links to help panel for marketing task #7384
|
183 |
+
- Add: Add installed marketing extensions card to extensions task #7419
|
184 |
+
- Add: Add marketing extensions task to task list #7383
|
185 |
+
- Add: Add tracks to marketing manage button click #7467
|
186 |
+
- Add: Add default marketing extensions as fallbacks #7466
|
187 |
+
- Add: Add marketing task completion check and tests #7451
|
188 |
+
- Add: navigation items for the Marketplace menu. #7529
|
189 |
+
- Update: Add locale param as part of free extensions request #7391
|
190 |
+
- Update: Increase per_page value for search results on the Analytics pages. #7385
|
191 |
+
- Update: Removing grow section from local free extensions in OBW #7386
|
192 |
+
- Update: Don't show the marketing task if no marketing tasks exist #7460
|
193 |
+
- Update: Delete free extensions transient on WCA update #7454
|
194 |
+
- Update: Update business details to use extensions data store #7452
|
195 |
+
- Update: Split Extensions page into Marketplace and My Subscriptions. #7471
|
196 |
+
- Dev: Added utm_medium=product to woocommerce.com links. #7408
|
197 |
+
- Dev: Update Jest to version 27. #7430
|
198 |
+
- Tweak: Refactor on payment settings recommendations eligibility component for reuse. #7447
|
199 |
+
- Tweak: Register wc-admin page for all users and handle authorization in client #7285
|
200 |
+
|
201 |
+
== 2.5.1 08/16/2021 ==
|
202 |
+
|
203 |
+
- Fix: Fix blank screen by setting a default value #7506
|
204 |
+
|
205 |
+
== 2.5.0 08/09/2021 ==
|
206 |
+
|
207 |
+
- Add: Add a delete option to completed tasks #7300
|
208 |
+
- Add: Add unit tests around extended payment gateway controller #7133
|
209 |
+
- Add: Add payment gateway suggestion unit tests #7142
|
210 |
+
- Add: Add TableSummaryPlaceholder to support skeleton loading #7294
|
211 |
+
- Add: Feature toggle to disable Analytics UI #7168
|
212 |
+
- Add: Hook reference slotFill support #6833
|
213 |
+
- Add: Adding tests for PaymentGatewaySuggestions > List component #7201
|
214 |
+
- Add: Remote Inbox feature setting toggle #7298
|
215 |
+
- Dev: Add `woocommerce_admin_export_id` filter for customizing the export file name #7178
|
216 |
+
- Dev: Allow packages to be build independently, fix commonjs module builds. #7286
|
217 |
+
- Dev: Point the changelog linter to updated changelog entry location #7318
|
218 |
+
- Dev: Remove old payment gateway task components #7224
|
219 |
+
- Fix: Attribute filter bug with "any X" variations. #7046
|
220 |
+
- Fix: Currency display on Orders activity card on homescreen #7181
|
221 |
+
- Fix: Fix obsolete key property in gateway defaults #7229
|
222 |
+
- Fix: Fixing button state logic for remote payment gateways #7200
|
223 |
+
- Fix: Recommended gateway suggestions not displayed properly #7231
|
224 |
+
- Fix: Include onboarding settings on the analytic pages #7109
|
225 |
+
- Fix: Load Analytics API only when feature is turned on #7193
|
226 |
+
- Fix: Localize string for description #7219
|
227 |
+
- Fix: Filters. On update respect all other queries, not just persistedQueries #7155
|
228 |
+
- Fix: Use saved form values if available when switching tabs #7226
|
229 |
+
- Fix: Skip schedule customer data deletion on site deletion #7214
|
230 |
+
- Fix: WCPay not working in local payments task #7151
|
231 |
+
- Fix: Report export filtering bug. #7165
|
232 |
+
- Fix: Add padding on table header button #7213
|
233 |
+
- Fix: Use tab char for the CSV injection prevention. #7154
|
234 |
+
- Fix: Add height auto on autocomplete popover button #7225
|
235 |
+
- Fix: Make WooCommerce-admin full-screen minimum height 100vh important #7230
|
236 |
+
- Fix: Cache product/variation revenue query results. #7067
|
237 |
+
- Fix: Transient overlapping adjacent content. #7302
|
238 |
+
- Fix: Unused feature preloaded options #7299
|
239 |
+
- Fix: Fix missing translation strings for CES #7270
|
240 |
+
- Fix: Add missing translation strings in the business features section #7268
|
241 |
+
- Fix: Fix inbox note dismiss dropdown not closing on Safari #7278
|
242 |
+
- Fix: Fixed OBW Business details style #7353
|
243 |
+
- Fix: Fix links on the dismiss dropdown are not clickable #7342
|
244 |
+
- Fix: Fix undefined method error when setting up WC Tax #7344
|
245 |
+
- Fix: Invalidate task status when enabling a payment gateway #7330
|
246 |
+
- Fix: Redirect to homescreen after payment gateway setup #7332
|
247 |
+
- Fix: Create workable defaults for Reports that don’t have AdvancedFilters #7186
|
248 |
+
- Fix: Sync the category lookup table when a new category gets created #7290
|
249 |
+
- Fix: Set default value for performanceIndicators variable #7343
|
250 |
+
- Fix: Add limit clause to coupons data store query #7399
|
251 |
+
- Fix: Fix analytics filter Gutenberg CSS conflict #7410
|
252 |
+
- Fix: Fix Gutenberg CardBody styles for task card #7411
|
253 |
+
- Fix: Fix orders panel not displaying any orders when analytics is disabled #7395
|
254 |
+
- Fix: Fix recommended card Gutenberg CSS conflict #7409
|
255 |
+
- Fix: Update tooltip styling to fix new Gutenberg updates. #7414
|
256 |
+
- Fix: Allow super admins all capabilities within WooCommerce Admin #7489
|
257 |
+
- Fix: Fix analytics overview re-arrangement on initial load. #7475
|
258 |
+
- Fix: Fixes action button mis-alignment within card footer. #7412
|
259 |
+
- Fix: Fix up onboarding profiler not working when opted out of tracking #7490
|
260 |
+
- Tweak: Remove performance indicators when Analytics Flag disabled #7234
|
261 |
+
- Tweak: Change event name when installing Google Listings and Ads. #7276
|
262 |
+
- Tweak: Removed unused feature flags #7233 and #7273
|
263 |
+
- Tweak: Render a spinner while woocommerce_setup_jetpack_opted_in is being loaded #7269
|
264 |
+
- Tweak: Repurpose disable wc-admin filter to remove optional features #7232
|
265 |
+
- Update: Add additional countries to WCPay for business features and payment task fallback #7436
|
266 |
+
- Update: Notes to use a date range. #7222
|
267 |
+
- Update: Remove facebook extension from onboarding extensions fallback list #7287
|
268 |
+
- Performance: Add lazy loading by checking panel open status #7379
|
269 |
+
|
270 |
+
== 2.4.4 07/21/2021 ==
|
271 |
+
|
272 |
+
- Fix: Fix homepage stock panel regression in 2.4.3. #7389
|
273 |
+
|
274 |
+
== 2.4.3 07/21/2021 ==
|
275 |
+
|
276 |
+
- Fix: Add a new low stock products endpoint to improve the performance. #7377
|
277 |
+
|
278 |
+
== 2.4.2 07/19/2021 ==
|
279 |
+
|
280 |
+
- Fix: Add lazy loading by checking panel open status #7376
|
281 |
+
- Fix: Add cache-control header to low stock REST API response #7364
|
282 |
+
|
283 |
+
== 2.4.1 07/01/2021 ==
|
284 |
+
|
285 |
+
- Fix: Fix and refactor explat polling to use setTimeout #7274
|
286 |
+
|
287 |
+
== 2.4.0 06/29/2021 ==
|
288 |
+
|
289 |
+
- Add: SlotFill to Abbreviated Notification panel #7091
|
290 |
+
- Add: Consume remote payment methods on frontend #6867
|
291 |
+
- Add: Extend payment gateways REST endpoint #6919
|
292 |
+
- Add: Add remote payment gateway recommendations initial docs #6962
|
293 |
+
- Add: Add loading placeholders for payment gateways task #7123
|
294 |
+
- Add: Note date range logic for GivingFeedback, and InsightFirstSale note. #6969
|
295 |
+
- Add: Add transient notices feature #6809
|
296 |
+
- Add: Add transformers in remote inbox notifications #6948
|
297 |
+
- Add: Add Mercado Pago as default fallback payment gateway #7043
|
298 |
+
- Add: Add in Razorpay as default fallback payment gateway #7096
|
299 |
+
- Add: Get post install scripts from gateway and enqueue in client #6967
|
300 |
+
- Add: Add eWAY as default fallback gateway #7108
|
301 |
+
- Add: Free extension list powered by remote config #6952
|
302 |
+
- Add: Add PayPal to fallback payment gateways #7001
|
303 |
+
- Add: Add a data store for WC Payments REST APIs #6918
|
304 |
+
- Add: Progressive setup checklist copy and call to action buttons. #6956
|
305 |
+
- Add: Add Paystack as fallback gateway #7025
|
306 |
+
- Add: Add Square as default fallback gateway #7107
|
307 |
+
- Add: Add COD method to default payment gateway recommendations #7057
|
308 |
+
- Add: Add BACS as default fallback payment gateway #7073
|
309 |
+
- Add: A/B test of progressive checklist features. #7089
|
310 |
+
- Add: Add payment gateway return URL and action #7095
|
311 |
+
- Add: Add Mollie to the default payment gateways. #7092
|
312 |
+
- Add: Show task and activity notifications in the Inbox panel #7017
|
313 |
+
- Add: Adding WCPay payment configuration defaults. #7097
|
314 |
+
- Add: Create onboarding package to house refactored WCPay card and relevant components #7058
|
315 |
+
- Dev: Add Jetpack Backup admin note #6738
|
316 |
+
- Dev: Reduce the specificity and complexity of the ReportError component #6846
|
317 |
+
- Dev: Converting <SettingsForm /> component to TypeScript. #6981
|
318 |
+
- Dev: Update package-lock to fix versioning of local packages. #6843
|
319 |
+
- Dev: Use rule processing for remote payment methods #6830
|
320 |
+
- Dev: Update E2E jest config, so it correctly creates screenshots on failure. #6858
|
321 |
+
- Dev: Fixed storybook build script #6875
|
322 |
+
- Dev: Removed allowed keys list for adding woocommerce_meta data. #6889 🎉 @xristos3490
|
323 |
+
- Dev: Delete all products when running product import tests, unskip previously skipped test. #6905
|
324 |
+
- Dev: Add payment method selector to onboarding store #6921
|
325 |
+
- Dev: Add disabled prop to SelectControl #6902
|
326 |
+
- Dev: Add filter variation to tracks data in products analytics. #6913
|
327 |
+
- Dev: Offload remote inbox notifications engine run using action-scheduler. #6995
|
328 |
+
- Dev: Add source param support for notes query. #6979
|
329 |
+
- Dev: Remove the use of Dashicons and replace with @wordpress/icons or gridicons. #7020
|
330 |
+
- Dev: Refactor inbox panel components and moved to experimental package. #7006
|
331 |
+
- Dev: Business features uncheck creative mail by default #7139
|
332 |
+
- Dev: Remove support for IE11. #7112
|
333 |
+
- Dev: Drop styling support for IE11. #7137
|
334 |
+
- Dev: Remove react-docgen docs in favor of Storybook #7055
|
335 |
+
- Enhancement: Add expand/collapse to extendable task list. #6910
|
336 |
+
- Enhancement: Add task hierarchy support to extended task list. #6916
|
337 |
+
- Enhancement: Add remind me later option to task list. #6923
|
338 |
+
- Enhancement: Enable Remote Free Extensions List #7144
|
339 |
+
- Enhancement: Adding Slotfills for remote payments and SettingsForm component. #6932
|
340 |
+
- Fix: Update the wordpress/babel-preset to avoid crashes in WP5.8 beta2 #7202
|
341 |
+
- Fix: Add fallback for the select/dispatch data-controls for older WP versions #7204
|
342 |
+
- Fix: RemoteFreeExtension hide bundle when all of its plugins are not visible #7182
|
343 |
+
- Fix: Issue where summary stats were not showing in Analytics > Stock. #7161
|
344 |
+
- Fix: Rule Processing Transformer to handle dotNotation default value #7009
|
345 |
+
- Fix: Remove Navigation's uneeded SlotFill context #6832
|
346 |
+
- Fix: Report filters expecting specific ordering. #6847
|
347 |
+
- Fix: Render bug with report comparison mode selections. #6862
|
348 |
+
- Fix: Throw exception if the data store cannot be loaded when trying to use notes. #6771
|
349 |
+
- Fix: Autocompleter for custom Search in FilterPicker #6880
|
350 |
+
- Fix: Get currency from CurrencyContext #6723
|
351 |
+
- Fix: Correct the left position of transient notices when the new nav is used. #6914
|
352 |
+
- Fix: Exclude WC Shipping for store that are only offering downloadable products #6917
|
353 |
+
- Fix: SelectControl focus and de-focus bug #6906
|
354 |
+
- Fix: Multiple preload tag output bug. #6998
|
355 |
+
- Fix: Call existing filters for leaderboards in analytics. #6626
|
356 |
+
- Fix: Set target to blank for the external links #6999
|
357 |
+
- Fix: Fix style regression with the Chart header. #7002
|
358 |
+
- Fix: Fix styling of the advanced filter operator selection. #7005
|
359 |
+
- Fix: Deprecated warnings from select control @wordpress/data-controls. #7007
|
360 |
+
- Fix: Bug with Orders Report coupon exclusion filter. #7021
|
361 |
+
- Fix: Show Google Listing and Ads in installed marketing extensions section. #7029
|
362 |
+
- Fix: Notices not dissapearing. #7077
|
363 |
+
- Fix: Keyboard accessibility on the free features tab. #7149
|
364 |
+
- Fix: Fix error handling when remote free extension API returns empty array. #7147
|
365 |
+
- Fix: Transformer casing is incorrect and creates an error on case-sensitive systems #7104
|
366 |
+
- Fix: Preventing redundant notices when installing plugins via payments task list. #7026
|
367 |
+
- Fix: Autocompleter for custom Search in CompareFilter #6911
|
368 |
+
- Fix: Add target to the button to open it in a new tab #7110
|
369 |
+
- Fix: Make `Search` accept synchronous `autocompleter.options`. #6884
|
370 |
+
- Fix: Set autoload to false for all remote inbox notifications options. #7060
|
371 |
+
- Fix: The use of gridicons for Analytics section controls. #7237
|
372 |
+
- Fix: WordPress 5.8 compatibility UI fixes #7255
|
373 |
+
- Fix: CurrencyFactory constructor to use proper function #7261
|
374 |
+
- Tweak: Setup checklist copy revert. #7015
|
375 |
+
- Tweak: Revert Card component removal #7167
|
376 |
+
- Update: Task list component with new Experimental Task list. #6849
|
377 |
+
- Update: Optimize payment gateway resolution #7124
|
378 |
+
- Update: Experimental task list import to the experimental package. #6950
|
379 |
+
- Update: Redirect to WC Home after setting up a payment method #6891
|
380 |
+
- Update: Hook up payments gateway data store #7038
|
381 |
+
- Update: Update remote payment docs gateway methods #7079
|
382 |
+
- Update: Remove original business step flow #7103
|
383 |
+
- Update: WooCommerce Shipping copy on onboarding steps #7148
|
384 |
+
|
385 |
+
== 2.3.1 05/24/2021 ==
|
386 |
+
|
387 |
+
- Tweak: Store profiler Changed MailPoet's title and description #6990
|
388 |
+
- Tweak: Adjust WC Pay supported countries #7048
|
389 |
+
- Update: Payment recommendation screen transition and add external link icon. #7022
|
390 |
+
- Fix: A JS exception being thrown on the product tags page. #7053
|
391 |
+
- Fix: Show Google Listing and Ads in installed marketing extensions section. #7029
|
392 |
+
|
393 |
+
== 2.3.0 05/13/2021 ==
|
394 |
+
|
395 |
+
- Add: Add plugin installer to allow installation of plugins via URL #6805
|
396 |
+
- Add: Optional children prop to SummaryNumber component #6748
|
397 |
+
- Dev: Add data source filter to remote inbox notification system #6794
|
398 |
+
- Dev: Introduce usage of ExPlat, an A/B testing tool. See https
|
399 |
+
- Dev: Add support for nonces in note actions #6726
|
400 |
+
- Dev: Add support for running php unit tests in PHP 8. #6678
|
401 |
+
- Dev: Add event recording to start of gateway connections #6801
|
402 |
+
- Feature: Add recommended payment methods in payment settings. #6760
|
403 |
+
- Fix: Event tracking for merchant email notes #6616
|
404 |
+
- Fix: Use the store timezone to make time data requests #6632
|
405 |
+
- Fix: Update the checked input radio button margin style #6701
|
406 |
+
- Fix: Convert date to timestamp before passing to set_date_prop to persist timezone #6795
|
407 |
+
- Fix: Make pagination buttons height and width consistent #6725
|
408 |
+
- Fix: Retain persisted queries when navigating to Homescreen #6614
|
409 |
+
- Fix: Update folded header style #6724
|
410 |
+
- Fix: Unreleated variations showing up in the Products reports #6647
|
411 |
+
- Fix: Check active plugins before getting the PayPal onboarding status #6625
|
412 |
+
- Fix: Remove noreply from inbox notification emails #6644
|
413 |
+
- Fix: Set up shipping costs task, redirect to shipping settings after completion. #6791
|
414 |
+
- Fix: Onboarding logic on WooCommerce update to keep task list present. #6803
|
415 |
+
- Fix: Pause inbox message “GivingFeedbackNotes” #6802
|
416 |
+
- Fix: Missed DB version number updates causing unnecessary upgrades. #6818
|
417 |
+
- Fix: Parsing bad JSON string data from user WooCommerce meta. #6819
|
418 |
+
- Fix: Remove PayPal for India #6828
|
419 |
+
- Performance: Avoid updating customer info synchronously from the front end. #6765
|
420 |
+
- Tweak: Add settings_section event prop for CES #6762
|
421 |
+
- Tweak: Refactor payments to allow management of methods #6786
|
422 |
+
- Tweak: Add tracking data for the preview site button #6623
|
423 |
+
- Tweak: Update WC Payments copy on the task list #6734
|
424 |
+
- Tweak: Update payment gateway suggestions semantics to be more consistent #7130
|
425 |
+
- Tweak: Add check to see if value for contains is array, show warning if not. #6645
|
426 |
+
- Tweak: Sort the extension task list by completion status and allow toggling visibility. #6792
|
427 |
+
- Tweak: Only fetch remote payment gateway recommendations when opted in #6964
|
428 |
+
- Update: Replace marketing extension Google Listings and Ads. #6939
|
429 |
+
- Update: Update choose niche note cta URL #6733
|
430 |
+
- Update: UI updates to Payment Task screen #6766
|
431 |
+
- Update: Update payment gateway suggestions semantics to be more consistent #7130
|
432 |
+
- Update: Adding setup required icon for nonconfigured payment methods #6811
|
433 |
+
|
434 |
+
== 2.2.6 05/07/2021 ==
|
435 |
+
|
436 |
+
- Fix: Address an issue with OBW when installing only WooCommerce payments and Jetpack. #6957
|
437 |
+
|
438 |
+
== 2.2.5 05/07/2021 ==
|
439 |
+
|
440 |
+
- Fix: Calling of get_script_asset_filename with extra parameter #6955
|
441 |
+
|
442 |
+
== 2.2.4 05/07/2021 ==
|
443 |
+
|
444 |
+
- Dev: Fix a bug where trying to load an asset registry causes a crash. #6951
|
445 |
+
|
446 |
+
== 2.2.3 05/06/2021 ==
|
447 |
+
|
448 |
+
- Dev: Do a git clean before the core release. #6945
|
449 |
+
|
450 |
+
== 2.2.2 04/28/2021 ==
|
451 |
+
|
452 |
+
- Fix: Disable the continue btn on OBW when requested are being made #6838
|
453 |
+
- Tweak: Revert WCPay international support for bundled package #6901
|
454 |
+
- Tweak: Store profiler Changed MailPoet's title and description #6886
|
455 |
+
- Tweak: Update PayU logo #6829
|
456 |
+
|
457 |
+
== 2.2.0 03/30/2021 ==
|
458 |
+
|
459 |
+
- Fix: Check if features are currently being enabled #6688
|
460 |
+
- Fix: Fix the activity panel toggle not closing on click #6679
|
461 |
+
- Fix: Fix use of feature checks and remove deprecated method calls #6687
|
462 |
+
- Fix: Allow the manager role to query certain options #6577
|
463 |
+
- Fix: Delete customer data on network user deletion #6574
|
464 |
+
- Fix: Fix Themes step visibility in IE 11 #6578
|
465 |
+
- Fix: Fix hidden menu title on smaller screens #6562
|
466 |
+
- Fix: Add gross sales column to CSV export #6567
|
467 |
+
- Fix: Add check for navigating being enabled. #6462
|
468 |
+
- Fix: Move the shipping input and text 1px lower. #6408
|
469 |
+
- Fix: Correct the Klarna slug #6440
|
470 |
+
- Fix: Broken link anchors to online documentation. #6455
|
471 |
+
- Fix: Update payment card style on mobile #6413
|
472 |
+
- Fix: Missing i18n in Welcome modal. #6456
|
473 |
+
- Fix: Restore visual styles back to Analytics tabs. #5913
|
474 |
+
- Fix: Update contrast and hover / active colors for analytics dropdown buttons #6504
|
475 |
+
- Fix: Associated Order Number for refunds was hidden #6428
|
476 |
+
- Fix: Fix issue where Loader
|
477 |
+
- Fix: Correct a bug where the JP connection flow would not happen when installing JP in the OBW. #6521
|
478 |
+
- Fix: Show management links when the task list is complete (even if its not hidden). #6657
|
479 |
+
- Fix: Adding New Zealand and Ireland to selective bundle option, previously missed. #6649
|
480 |
+
- Fix: Update the Mercado option used for enabling/disabling. #6677
|
481 |
+
- Fix: Improve AddFirstProduct email note contents. #6617
|
482 |
+
- Fix: Missing margin between cards and viewport in setup wizard #6620
|
483 |
+
- Add: Next new novel navigation nudge note #6610
|
484 |
+
- Add: Add legacy report items to new navigation #6507
|
485 |
+
- Add: Add preview site button on the appearance task #6457
|
486 |
+
- Add: Back button to go to home screen from tasks in the task list. #6397
|
487 |
+
- Add: Add a "rather not say" option to revenue in the profile wizard. #6475
|
488 |
+
- Add: Remove Mollie promo note on install #6510
|
489 |
+
- Add: Remote Inbox Notifications rule to trigger when WooCommerce Admin is upgraded. #6040
|
490 |
+
- Add: Add Ireland to Square payment method #6559
|
491 |
+
- Add: CES survey for search product, order, customer #6420
|
492 |
+
- Add: CES survey for importing products #6419
|
493 |
+
- Add: CES survey for adding product categories, tags, and attributes #6418
|
494 |
+
- Add: Additional analytics tracking for the business details step. #6575
|
495 |
+
- Add: Include tracking for mail poet installs in the selective bundle install #6603
|
496 |
+
- Add: Paystack payment provider to several african countries. #6579
|
497 |
+
- Tweak: Add default value for contains op #6622
|
498 |
+
- Tweak: Adjust targeting store age for the Add First Product note #6554
|
499 |
+
- Tweak: Improve WC Shipping & Tax logic #6547
|
500 |
+
- Tweak: Update Insight inbox note content #6555
|
501 |
+
- Tweak: Remove mobile activity panel toggle #6539
|
502 |
+
- Tweak: Refactor autoloader to remove global variable. #6412
|
503 |
+
- Dev: Close activity panel tabs by default and track #6566
|
504 |
+
- Dev: Update undefined task name properties for help panel tracks #6565
|
505 |
+
- Dev: Refactor profile wizard benefits step and add tests #6583
|
506 |
+
- Dev: Add filter to profile wizard steps #6564
|
507 |
+
- Dev: Add nav intro modal tests #6518
|
508 |
+
- Dev: Use wc filter to get status tabs for tools category #6525
|
509 |
+
- Dev: Add nav header component tests #6509
|
510 |
+
- Dev: Add initial tests for navigation Menu class #6492
|
511 |
+
- Dev: Remove active item from navigation store #6486
|
512 |
+
- Dev: Add navigation container tests #6464
|
513 |
+
- Dev: Add nav favorite button tests #6446
|
514 |
+
- Dev: Add a changelog lint check to PRs. #6414
|
515 |
+
- Dev: Add navigation favorites tests #6409
|
516 |
+
- Dev: support use of Array.flat in client and packages. #6411
|
517 |
+
- Dev: Deprecate Onboarding
|
518 |
+
- Dev: Add Dependency Extraction Webpack Plugin #5762
|
519 |
+
- Dev: Add clientside filter for Navigation rootBackUrl #6505
|
520 |
+
- Dev: Remove `items_purchased` and `account_type` props from onboarding profile API. #6520
|
521 |
+
- Dev: Added warning when WCAdmin is active but not being used #6453
|
522 |
+
- Dev: Store profiler Added MailPoet to Business Details step #6503
|
523 |
+
- Dev: Store profiler Added MailPoet to new Business Details step #6515
|
524 |
+
- Dev: Add tilde (~) to represent client root directory for imports. #6517
|
525 |
+
- Dev: Add script automation for gathering hooks and filters. #6454
|
526 |
+
- Dev: Add TypeScript to CustomerFeedbackModal component. #6498
|
527 |
+
- Dev: Add TypeScript and page objects to the E2E test suite. #6582
|
528 |
+
- Dev: Introduce Typescript to Navigation utils #6477
|
529 |
+
- Dev: Payments task
|
530 |
+
- Dev: Ensure script asset.php files are included in builds #6635
|
531 |
+
- Dev: Ensure production script asset names don't include .min suffix #6681
|
532 |
+
|
533 |
+
== 2.1.4 03/29/2021 ==
|
534 |
+
|
535 |
+
- Fix: Adding New Zealand and Ireland to selective bundle option, previously missed. #6649
|
536 |
+
|
537 |
+
== 2.1.3 03/14/2021 ==
|
538 |
+
|
539 |
+
- Feature: Increase target audience for business feature step. #6508
|
540 |
+
- Fix: Correct a bug where the JP connection flow would not happen when installing JP in the OBW. #6521
|
541 |
+
- Fix: Add customer name column to CSV export #6556
|
542 |
+
|
543 |
+
== 2.1.2 03/10/2021 ==
|
544 |
+
|
545 |
+
- Fix: Add guard to "Deactivate Plugin" note handlers to prevent fatal error. #6532
|
546 |
+
- Fix: Crash of Analytics > Settings page when Gutenberg is installed. #6540
|
547 |
+
|
548 |
+
== 2.1.1 03/04/2021 ==
|
549 |
+
|
550 |
+
- Fix: Restore missing Correct the Klarna slug #6440
|
551 |
+
|
552 |
+
== 2.1.0 03/04/2021 ==
|
553 |
+
|
554 |
+
- Dev: Allow highlight tooltip to use body tag as parent. #6309
|
555 |
+
- Dev: Remove Google fonts and material icons. #6343
|
556 |
+
- Dev: Add filter to allow enabling the WP toolbar within the new navigation. #6371
|
557 |
+
- Dev: Add unit tests to Navigation's Container component. #6344
|
558 |
+
- Dev: Use box sizing and padding to fix nav and admin menu styling #6335
|
559 |
+
- Dev: Refactor head and body heights #6247
|
560 |
+
- Dev: Fix the react state update error on homescreen. #6320
|
561 |
+
- Dev: Change `siteUrl` to `homeUrl` on navigation site title #6240
|
562 |
+
- Dev: Add navigation favorites data store #6275
|
563 |
+
- Dev: Add a changelog lint check to PRs. #6414
|
564 |
+
- Add: Remove CES actions for adding and editing a product and editing an order #6355
|
565 |
+
- Add: CES track settings tab on updating settings #6368
|
566 |
+
- Add: Favorites tooltip to the navigation #6312
|
567 |
+
- Add: Core settings redirection to new settings pages #6091
|
568 |
+
- Add: Settings feature and pages #6089
|
569 |
+
- Add: Settings client pages #6092
|
570 |
+
- Add: Favoriting extensions client UI #6287
|
571 |
+
- Add: Add navigation intro modal. #6367
|
572 |
+
- Add: WC Admin Docker setup with WPENV
|
573 |
+
- Fix: Enqueue scripts called incorrectly in php unit tests #6358
|
574 |
+
- Fix: Removed @woocommerce/components/card from OBW #6374
|
575 |
+
- Fix: Email notes now are turned off by default #6324
|
576 |
+
- Fix: Top bar slightly overlaps wpadmin navigation on mobile #6292
|
577 |
+
- Fix: Hide tooltip in welcome modal #6142
|
578 |
+
- Fix: update single column home screen width to 680px #6297
|
579 |
+
- Fix: Recommended Payment Banner missing in Safari #6375
|
580 |
+
- Fix: Empty nav menu #6366
|
581 |
+
- Fix: Check if tax was successfully added before displaying notice #6229
|
582 |
+
- Fix: Update timing of InboxPanel state changes for the unread indicator #6246
|
583 |
+
- Fix: Display" option fails to collapse upon invoking "Help" option #6233
|
584 |
+
- Fix: Removal of core settings pages #6328
|
585 |
+
- Fix: Fix double prefixing of full navigation URLs #6460
|
586 |
+
- Fix: Reset Navigation submenu before making Flyout #6396
|
587 |
+
- Fix: Move the shipping input and text 1px lower. #6408
|
588 |
+
- Tweak: Order and styles updates to nav footer #6373
|
589 |
+
- Tweak: Enqueue beta features scripts on enqueue_scripts action instead of filter #6358
|
590 |
+
- Tweak: Set `is_deleted` from the database when instantiating a `Note` #6322
|
591 |
+
- Tweak: New Settings
|
592 |
+
- Tweak: Update inline documentation for navigation Screen class #6173
|
593 |
+
- Tweak: Remove categories without menu items #6329
|
594 |
+
- Tweak: Navigation
|
595 |
+
- Tweak: Move admin menu manipulation from admin_head to admin_menu #6310
|
596 |
+
- Tweak: Updates to copy and punctuation to be more conversational and consistent. #6298
|
597 |
+
- Enhancement: Move capability checks to client #6365
|
598 |
+
- Enhancement: Navigation
|
599 |
+
- Enhancement: override wpbody styles when nav present #6354
|
600 |
+
- Enhancement: Move favorited menu items to primary menu #6290
|
601 |
+
|
602 |
+
== 2.0.3 03/10/2021 ==
|
603 |
+
|
604 |
+
- Fix: Crash of Analytics > Settings page when Gutenberg is installed. #6540
|
605 |
+
|
606 |
+
== 2.0.2 05/25/2021 ==
|
607 |
+
|
608 |
+
- Fix: Correct the Klarna slug #6440
|
609 |
+
|
610 |
+
== 2.0.0 02/05/2021 ==
|
611 |
+
|
612 |
+
- Tweak: Bump minimum supported version of PHP to 7.0. #6046
|
613 |
+
- Tweak: update the content and timing of the NeedSomeInspiration note. #6076
|
614 |
+
- Tweak: Adjust the Marketing note not to show until store is at least 5 days. #6083
|
615 |
+
- Tweak: Refactored extended task list. #6081
|
616 |
+
- Fix: allow for more terms to be shown for product attributes in the Analytics orders report. #5868
|
617 |
+
- Fix: Add support for a floatingpoint number as a SummaryNumber's delta. #5926
|
618 |
+
- Fix: Fixed the Add First Product email note checks. #6260
|
619 |
+
- Fix: Onboarding Fixed "Business Details" error. #6271
|
620 |
+
- Fix: Show management links when only main task list is hidden. #6291
|
621 |
+
- Fix: Persist the enabling of plugins in the payments setup task. #6332
|
622 |
+
- Add: new inbox message Getting started in Ecommerce watch this webinar. #6086
|
623 |
+
- Add: Remote inbox notifications contains comparison and fix product rule. #6073
|
624 |
+
- Add: Task list payments include Mollie as an option. #6257
|
625 |
+
- Add: Allow users to install the PayU plugin in the payments setup task. #6332
|
626 |
+
- Update: store deprecation welcome modal support doc link #6094
|
627 |
+
- Update: Homescreen layout, moving Inbox panel for better interaction. #6122
|
628 |
+
- Enhancement: Allowing users to create products by selecting a template. #5892
|
629 |
+
- Enhancement: Use the new Paypal payments plugin for onboarding. #6261
|
630 |
+
- Dev: Add wait script for mysql to be ready for phpunit tests in docker. #6185
|
631 |
+
- Dev: Remove old debug code for connecting to Calypso / Wordpress.com. #6097
|
632 |
+
- Dev: Allow highlight tooltip to use body tag as parent. #6309
|
633 |
+
|
634 |
+
== 1.9.0 01/15/2021 ==
|
635 |
+
|
636 |
+
- Fix: Add Customer Type column to the Orders report table. #5820
|
637 |
+
- Fix: Product exclusion filter on Orders Report.
|
638 |
+
- Fix: Typo in Variation Stats DataStore context filter value.
|
639 |
+
- Fix: support custom attributes in Attribute advanced report filter.
|
640 |
+
- Fix: Don't show Stock and Reviews Homescreen panels too early.
|
641 |
+
- Fix: Undefined $collate variable when database does not have collation capability. #5992
|
642 |
+
- Fix: Moved certified owner label for review to title. ##5877
|
643 |
+
- Fix: Move collapsible config to panels object, to allow for more control. #5855
|
644 |
+
- Fix: Invalidate product count if the last product was updated in the list. #5790
|
645 |
+
- Fix: Updating (non wordpress user) customer with order data
|
646 |
+
- Fix: Fixed error hiding core task list. #6050
|
647 |
+
- Fix: Generate JSON translation chunks on plugin activation #6028
|
648 |
+
- Tweak: Remove deprecated use of Jetpack in shipping label banner. #5929
|
649 |
+
- Tweak: Remove visit_count from track, and update task count logic. #5996
|
650 |
+
- Tweak: Fix inconsistent REST API paramater name for customer type filtering.
|
651 |
+
- Tweak: update the content for the ChooseNiche note. #6048
|
652 |
+
- Enhancement: Show Help panel tooltip when user visits unfinished task more then once. #5826
|
653 |
+
- Enhancement: Tasks extensibility in Home Screen. #5794
|
654 |
+
- Enhancement: Add page parameter to override default wcadmin page in Navigation API. #5821
|
655 |
+
- Enhancement: Add an a/b experiment for installing free business features #5786
|
656 |
+
- Enhancement: Add an "unread" indicator to inbox messages. #6047
|
657 |
+
- Dev: Add documentation for filter `woocommerce_admin_pages_list` and `wc_admin_register_page` #5844
|
658 |
+
- Dev: Revert work done in #4857 for automated shipping after OBW is completed #5971
|
659 |
+
- Dev: Add `onChangeCallback` feature to the wcadmin <Form> component #5786
|
660 |
+
- Dev: Add merchant email notifications #5922
|
661 |
+
- Dev: Update travis CI distribution. #6067
|
662 |
+
- Add: Welcome modal when coming from Calypso #6004
|
663 |
+
- Add: Email note to add first product. #6024
|
664 |
+
- Add: Note for users coming from Calypso. #6030
|
665 |
+
- Add: Manage activity from home screen inbox message. #6072
|
666 |
+
|
667 |
+
== 1.8.3 01/05/2021 ==
|
668 |
+
|
669 |
+
- Fix: Compile the debug module so it can be used in older browsers like IE11. #5987
|
670 |
+
|
671 |
+
== 1.8.2 12/22/2020 ==
|
672 |
+
|
673 |
+
- Fix: Completed tasks tracking causing infinite loop #5941
|
674 |
+
- Fix: Remove Navigation access #5940
|
675 |
+
|
676 |
+
== 1.8.1 12/15/2020 ==
|
677 |
+
|
678 |
+
- Fix: Product exclusion filter on Orders Report.
|
679 |
+
- Fix: Typo in Variation Stats DataStore context filter value. #5784
|
680 |
+
|
681 |
+
== 1.8.0 12/07/2020 ==
|
682 |
+
|
683 |
+
- Enhancement: Add "filter by variations in reports" inbox note. #5208
|
684 |
+
- Enhancement: Tasks extensibility in Home Screen. #5794
|
685 |
+
- Enhancement: Add page parameter to override default wcadmin page in Navigation API. #5821
|
686 |
+
- Enhancement: Introduce the customer effort score (CES) feature.
|
687 |
+
- Enhancement: Rework task extensibility in the homescreen. #5794
|
688 |
+
- Enhancement: Migrate the reviews panel to the homescreen. #5706
|
689 |
+
- Enhancement: Migrate reviews panel to home screen. #5706
|
690 |
+
- Enhancement: Add Razorpay to payment task for stores in India #5775
|
691 |
+
- Enhancement: Migrate Stock Panel to Homescreen. #5729
|
692 |
+
- Enhancement: Add enhanced placeholders for Marketing components. #5611
|
693 |
+
- Enhancement: Allow switching on/off the navigation feature in plugin and core builds. #5697
|
694 |
+
- Tweak: Fix inconsistent REST API parameter name for customer type filtering. #5823
|
695 |
+
- Tweak: Improve styles of the tax task. #5709
|
696 |
+
- Tweak: Do not show store setup link on the homescreen. #5801
|
697 |
+
- Tweak: Revert the #5001 work to order tasks by completion. #5721
|
698 |
+
- Tweak: Revert the smart tax defaults work. #5720
|
699 |
+
- Tweak: Do not show store setup activity panel on the homescreen. #5801
|
700 |
+
- Tweak: Don't show the Orders panel on the homescreen with the Task List. #5552
|
701 |
+
- Tweak: Continue showing tasklist even if list is complete, only hide if set to hidden. #5673
|
702 |
+
- Tweak: Remove check for Jetpack and WCS from Stripe onboarding task. #4933
|
703 |
+
- Fix: Move collapsible config to panels object, to allow for more control. #5855
|
704 |
+
- Fix: Invalidate product count if the last product was updated in the list. #5790
|
705 |
+
- Fix: Add Customer Type column to the Orders report table. #5820
|
706 |
+
- Fix: Product exclusion filter on Orders Report. #5822
|
707 |
+
- Fix: Show the customer type column in Orders report table. #5820
|
708 |
+
- Fix: make sure 'Customers' page updates after order update. #5776
|
709 |
+
- Fix: Fix fatal errors when child themes are installed in a subdirectory. #5783
|
710 |
+
- Fix: Allow actionable statuses in orders endpoint(s) filters. #5733
|
711 |
+
- Fix: snackbar dismissal bug. #5696
|
712 |
+
- Fix: Only import the Gridicons we need, to reduce package size. #5668
|
713 |
+
- Fix: Stop order panels flickering on load. #5655
|
714 |
+
- Fix: Load wctracks to avoid fatal errors. #5645 #5638
|
715 |
+
- Fix: Preventing desktopsized navigation placeholder from appearing on mobile during load. #5616
|
716 |
+
|
717 |
+
== 1.7.0 11/11/2020 ==
|
718 |
+
|
719 |
+
- Enhancement: Variations report. #5167
|
720 |
+
- Enhancement: Add ability to toggle homescreen layouts. #5429
|
721 |
+
- Enhancement: Accordion component #5474
|
722 |
+
- Enhancement: Badge component #5520
|
723 |
+
- Fix: Added support for custom actionable statuses. #5550
|
724 |
+
- Fix: wrong casing used on the PayPal brand name #5514 🎉 @rtpHarry
|
725 |
+
- Fix: Import @wordpress/basestyles/defaultcustomproperties #5491
|
726 |
+
- Fix: downloads report #5441
|
727 |
+
- Fix: missing custom autocompleter attribute in Search component of Advanced Filter #5448
|
728 |
+
- Fix: empty no posts state on Marketing page. #5411
|
729 |
+
- Fix: visual issues in the Search component. #5199
|
730 |
+
- Fix: Inconsistent line endings in readme.txt. #5281
|
731 |
+
- Fix: popover menu to expand menu item width to 100% #5519
|
732 |
+
- Fix: Wrong class name for querying Categories Report #5522 🎉 @zzap
|
733 |
+
- Fix: Remove label printing mention for non us countries #5527
|
734 |
+
- Fix: First product script navigation dependency #5584
|
735 |
+
- Fix: Added support for custom actionable statuses #5550
|
736 |
+
- Fix: Display the store management links last on the homescreen #5579
|
737 |
+
- Fix: Ensure the "Set up additional payment providers" inbox notification is shown when relevant after completing the OBW. #5547
|
738 |
+
- Tweak: Remove customer analytics data upon order deletion #5171
|
739 |
+
- Tweak: Updating Stripe key field validation to support test keys #5201
|
740 |
+
- Tweak: Wrap search control selected items in list #5231
|
741 |
+
- Tweak: Update store setup link to redirect to setup wizard #5200
|
742 |
+
- Tweak: Removing breadcrumbs from wcadmin header #5232
|
743 |
+
- Tweak: Use consistent markdown headers in navigation readme #5417
|
744 |
+
- Tweak: Remove Store Setup Alert #5499
|
745 |
+
- Tweak: Customers
|
746 |
+
- Tweak: alter homescreen layout. #5465
|
747 |
+
- Dev: Home Screen migrate orders panel. #5455
|
748 |
+
- Dev: Store Profiler include Creative Mail as a free extension #5543
|
749 |
+
- Dev: Add undefined check in intervals data util #5546
|
750 |
+
- Dev: Fix wakeup visibility for PHP 8 compatibility #5211
|
751 |
+
- Dev: Fix header height and positioning for wc nav #5173
|
752 |
+
- Dev: Add remote inbox notification rule processors for country and state #5203
|
753 |
+
- Dev: Rename admin notes classes and file names to fit conventions #514
|
754 |
+
- Dev: remove checks of store registration that are no longer needed. #5170
|
755 |
+
- Dev: Fix version update script for composer.json #5165
|
756 |
+
- Dev: Remove getAdminLink from data package #5158
|
757 |
+
- Dev: Bump @woocommerce/components dependencies. #5153
|
758 |
+
- Dev: Add note status remote inbox notifications rule processor #5207
|
759 |
+
- Dev: Make code chunk filenames more stable. #5229
|
760 |
+
- Dev: Inbox Panel component moved #5252
|
761 |
+
- Dev: Added animation to Inbox note deletion #5263
|
762 |
+
- Dev: Update starter pack dependencies #5254
|
763 |
+
- Dev: Ensure test zips have latest packages from npm and composer. #5313
|
764 |
+
- Dev: Add remote inbox notifications rule allowing access to any option #5206
|
765 |
+
- Dev: Add manage orders on the go admin note #5159
|
766 |
+
- Dev: Add WooCommerceDependencyExtractionWebpackPlugin package #5198
|
767 |
+
- Dev: Migrate devdocs examples to Storybook stories #5271
|
768 |
+
- Dev: Remove Enzyme in favor of React Testing Library #5299
|
769 |
+
- Dev: Add exclusion rule to PHPCS config for TODO comments #5388
|
770 |
+
- Dev: Remove no longer used isPanelEmpty logic. #5423
|
771 |
+
- Dev: Use new @wordpress/components Card on Marketing page. #5428
|
772 |
+
- Dev: Add PSR4 naming checks to PHP linting. #5512
|
773 |
+
- Dev: Rearrange the store management links under categories add filter woocommerce_admin_homescreen_quicklinks. #5476
|
774 |
+
- Dev: Restyle the setup task list header to display incomplete tasks #5520
|
775 |
+
|
776 |
+
== 1.6.2 10/16/2020 ==
|
777 |
+
|
778 |
+
- Fix: Missing activity panels on ugraded sites #5400
|
779 |
+
- Fix: Casting of onboarding profile data to array #5415
|
780 |
+
- Fix: Gutenberg 9.1.1 compat for inbox on home screen not showing #5416
|
781 |
+
- Fix: i18n of Performance Indicator strings #5405
|
782 |
+
- Fix: Gutenberg 9.1.1 compat for empty data sets #5409
|
783 |
+
|
784 |
+
== 1.6.1 10/13/2020 ==
|
785 |
+
|
786 |
+
- Fix: Hide setup checklist shortcut when setup checklist skipped #5360
|
787 |
+
- Fix: use of undefined function on WC < 4.0.0.
|
788 |
+
|
789 |
+
== 1.6.0 10/09/2020 ==
|
790 |
+
|
791 |
+
- Dev: Reviews wp.data store #4941
|
792 |
+
- Dev: Notes wp.data store #4943
|
793 |
+
- Dev: Add woocommerce_analytics_update_order_stats_data filter #4934
|
794 |
+
- Dev: Remove unused lib/date #4987
|
795 |
+
- Dev: Exports wp.data store #4958
|
796 |
+
- Dev: Remove _experimentalResolveSelect usage #4949
|
797 |
+
- Dev: Items wp.data store #5009
|
798 |
+
- Dev: Import wp.data store #4982
|
799 |
+
- Dev: Remove `freshdata` wcapi dependency #5075
|
800 |
+
- Dev: Add initial e2e test suite #5028
|
801 |
+
- Dev: Combine translation chunks when languages updated #5094
|
802 |
+
- Dev: Add filters for columns in reports #5134
|
803 |
+
- Dev: Don't include "min" suffix in build JS files for core build #5130
|
804 |
+
- Enhancement: Add free local shipping zone on profile complete #4857
|
805 |
+
- Enhancement: Add woocommerce/tracks package #5107
|
806 |
+
- Enhancement: Add filter to allow modification of report columns #4984
|
807 |
+
- Enhancement: Add WooCommerce Mobile Banner #5037
|
808 |
+
- Enhancement: Add Product Attribute advanced filter #5038
|
809 |
+
- Enhancement: Add support for advanced filters with multiple instances #5050
|
810 |
+
- Enhancement: Automated taxes smart default #5076
|
811 |
+
- Enhancement: Add product attribute filter to Orders report #5068
|
812 |
+
- Tweak: Remove payment task actions #4917
|
813 |
+
- Tweak: Don't import from React, use @wordpress/element #4978
|
814 |
+
- Tweak: Use filtered headers array in onColumnsChange callback #4964
|
815 |
+
- Tweak: Orders panel get selectors form wcapi #4997
|
816 |
+
- Tweak: Group tasks by completion in setup checklist #5001
|
817 |
+
- Tweak: Replace useFilters with WP withFilters #4962
|
818 |
+
- Tweak: Refactor header component to function #5023
|
819 |
+
- Tweak: Refactor task list status to onboarding data store #4998
|
820 |
+
- Tweak: Add monthly pricing toggle in OBW #5015
|
821 |
+
- Tweak: OBW style updates #5059
|
822 |
+
- Tweak: Remove chevron icons from Fish Setup task list #5114
|
823 |
+
- Tweak: Add option to not charge sales tax in setup checklist #5111
|
824 |
+
- Tweak: Enable homescreen for all sites #5108
|
825 |
+
- Tweak: Enable remote inbox in all envs #5160
|
826 |
+
- Tweak: Add optout for remote inbox #5162
|
827 |
+
- Fix: Table component onQueryChange default prop #4959
|
828 |
+
- Fix: Dependency declarations in woocommerce/components #4972
|
829 |
+
- Fix: Text domains in stock report #4980
|
830 |
+
- Fix: Typo in reports store action creators #4992
|
831 |
+
- Fix: Note data actions and consolidate query constants #4990
|
832 |
+
- Fix: Advanced filters screen reader text #5032
|
833 |
+
- Fix: Show full variation name in products report #5056
|
834 |
+
- Fix: Card to connect to woocommerce.com #5129
|
835 |
+
- Fix: Search all variation attribute values #5141
|
836 |
+
- Fix: Force float before addition in taxes #5149
|
837 |
+
|
838 |
+
== 1.5.0 08/07/2020 ==
|
839 |
+
|
840 |
+
- Dev: New notification
|
841 |
+
- Dev: Enable tax calculation before redirecting to standard tax rates page. #4878
|
842 |
+
- Dev: Added event recording to Orders, Stock, and Reviews panels. #4861
|
843 |
+
- Dev: Added personalization to purchase extension task. #4849
|
844 |
+
- Dev: Display modal with more info about the new homescreen. #4890
|
845 |
+
- Dev: Task list add a shortcut back to store setup. #4853
|
846 |
+
- Dev: Update the colors of the illustrations in the welcome modal. #4945
|
847 |
+
- Fix: Use clipRule and fillRule props. #4889, part of #4864
|
848 |
+
- Enhancement: Add eWAY to Payment Setup for AU/NZ Stores. #4947
|
849 |
+
|
850 |
+
== 1.4.0 07/22/2020 ==
|
851 |
+
|
852 |
+
- Fix: Update returning customer total to include customers whose first order was within the report date range #4430
|
853 |
+
- Fix: Fix an error in the Analytics/Orders table when there is an order deleted directly from the database #4630
|
854 |
+
- Fix: Reselecting advanced filters in the customer list #4650
|
855 |
+
- Fix: Reporting of deleted coupons #4671
|
856 |
+
- Fix: Preventing refresh after answering a survey note #4711
|
857 |
+
- Fix: Regular filters not working #4704
|
858 |
+
- Fix: React warning in test that the key prop wasn't assigned in List #4808
|
859 |
+
- Fix: Center continue buttons in the onboarding profile wizard #4082
|
860 |
+
- Fix: Homepage template used in setup checklist customization task #4807
|
861 |
+
- Fix: Errant Jetpack activation prompt in Stats Overview home screen widget #4817
|
862 |
+
- Fix: Unable to activate theme with uppercase name #4393 🎉 @ayubadiputra
|
863 |
+
- Fix: Set active theme when OBW is shown via the task list #4834
|
864 |
+
- Enhancement: Add option to dismiss tasks in Setup Checklist #4733
|
865 |
+
- Enhancement: Show contextual help menu when working on store setup tasks. #4779
|
866 |
+
- Enhancement: Add automatic PayPal account creation flow. #4804
|
867 |
+
- Enhancement: Move the WooCommerce > Coupons dashboard menu item to Marketing > Coupons. #4786
|
868 |
+
- Tweak: Add education and travel to the onboarding industry types #4694
|
869 |
+
- Tweak: Refactor Jetpack connection flows #4655
|
870 |
+
- Tweak: Refactor tax task to use promise chain #4683
|
871 |
+
- Tweak: Add bundle install UI to Business Details step #4695
|
872 |
+
- Tweak: Include Product Bundles and Product Addons as OBW product options #4705
|
873 |
+
- Tweak: Toggle the “Physical products” checkbox on by default #4702
|
874 |
+
- Tweak: Variation Names
|
875 |
+
- Tweak: Limit inbox status to unactioned notes #4765
|
876 |
+
- Tweak: Only show usage tracking modal once in OBW. #4766
|
877 |
+
- Tweak: Add WooCommerce Payments to Setup Checklist. #4793
|
878 |
+
- Tweak: Update connection flow for Bundle UI #4717
|
879 |
+
- Tweak: Style improvements for Marketing hub. #4794
|
880 |
+
- Tweak: Added skip profiler functionality #4721
|
881 |
+
- Tweak: Reordered home screen tasks #4754
|
882 |
+
- Tweak: Create single source of truth for task list array #4825
|
883 |
+
- Tweak: Rework the store details onboarding screen #4771
|
884 |
+
- Tweak: Design of Product Types step in Onboarding #4707
|
885 |
+
- Tweak: Add copy that WCS TOS will be accepted upon install #4799
|
886 |
+
- Dev: Customize webpack jsonpFunction to avoid potential collision with other Webpack bundles #4644 🎉 @aaemnnosttv
|
887 |
+
- Dev: Update @wordpress/basestyles and replace deprecated variables #4759
|
888 |
+
|
889 |
+
== 1.3.2 07/29/2020 ==
|
890 |
+
|
891 |
+
- Fix: bug preventing saving user preferences on WP 5.3. #4869
|
892 |
+
|
893 |
+
== 1.3.1 07/20/2020 ==
|
894 |
+
|
895 |
+
- Fix: PHP Fatal errors when columns are missing from the Notes table. #4831
|
896 |
+
|
897 |
+
== 1.3.0 07/08/2020 ==
|
898 |
+
|
899 |
+
- Enhancement: Add Jetpack stats to performance indicatorts / homepage #4291
|
900 |
+
- Enhancement: New "Store Management" quick links card on WooCommerce home screen. #4350
|
901 |
+
- Enhancement: Inbox notifications layout updates #4218
|
902 |
+
- Enhancement: New Home Screen #4303
|
903 |
+
- Enhancement: Use WordPress Core colors for styling accents. #4558
|
904 |
+
- Dev: Add jestdom eslint plugin. #4327
|
905 |
+
- Dev: Migrate onboarding data store to wp.data #4433
|
906 |
+
- Dev: Remove use of `IconButton` in favor of `Button` #4415
|
907 |
+
- Dev: Fix error handling for plugins on server error #4462
|
908 |
+
- Dev: update @wordpress/components and @wordpress/basestyles #4427
|
909 |
+
- Dev: Migrate user store to wp.data #4505
|
910 |
+
- Dev: Add options data store to wp.data #4144
|
911 |
+
- Dev: Runtime feature config override #4523
|
912 |
+
- Dev: Check that the possibly_add_note function exists before calling it #4680
|
913 |
+
- Dev: Remove unnecessary rest API init action. #4691
|
914 |
+
- Dev: Don't include sourcemaps or unminified JS for "core" builds. #4642
|
915 |
+
- Fix: misaligned 'required' text on selects #4307
|
916 |
+
- Fix: exception when opening dashboard after selecting extensions to purchase #4357
|
917 |
+
- Fix: REST API collections schema #4377
|
918 |
+
- Fix: Monetary Advanced Filters in Customers Report with correct currency object prop. #4356
|
919 |
+
- Fix: In App purchase "back link" #4301
|
920 |
+
- Fix: Search results selectable by clicking on item text or icon #4474
|
921 |
+
- Fix: Filters' static query parameters #4458
|
922 |
+
- Fix: The WCPay method not appearing as recommended sometimes #4345
|
923 |
+
- Fix: Removed URLSearchParams method #4501
|
924 |
+
- Fix: REST API collections schema. #4484
|
925 |
+
- Fix: null issue in wpNavMenuClassChange #4513 🎉 @gradosevic
|
926 |
+
- Fix: RTL stylesheet loading for split code chunks. #4542
|
927 |
+
- Fix: Don't show store location step in tax and shipping tasks if the address has already been provided #4507
|
928 |
+
- Fix: Check for enabled methods before payment task completion #4530
|
929 |
+
- Fix: Solved a problem with the method onChoose in the last onboarding step. #4583
|
930 |
+
- Fix: Only mark purchase task as complete when products exist #4574
|
931 |
+
- Fix: Remove unnecessary rest_api_init action that caused incompatibility issues with other plugins. #4691
|
932 |
+
- Fix: Fix WCPay sometimes not appearing on the task list #4647
|
933 |
+
- Tweak: make revenue report total sales column optional #4397
|
934 |
+
- Tweak: Adjustments to WooCommerce Payments setup task #4373
|
935 |
+
- Tweak: Handling of plugin installs in OBW #4411
|
936 |
+
- Tweak: Update design of Setup Checklist #4434
|
937 |
+
- Tweak: Add scrollable styling to left side of Table, and keep updated #4179
|
938 |
+
- Tweak: reduce asset filename length. #4535
|
939 |
+
- Tweak: Use single dash for country/state dropdown options #4553
|
940 |
+
- Tweak: Use label tag for toggleable shipping zones #4554
|
941 |
+
- Tweak: Tweak Make it easier to add submenu items to the Marketing menu #4561
|
942 |
+
- Tweak: Remove duplicate/redundant inbox note after first order received. #4659
|
943 |
+
- Tweak: Fix the embed page CSS so the top content sits better #4622
|
944 |
+
|
945 |
+
== 1.2.4 06/11/2020 ==
|
946 |
+
|
947 |
+
- Tweak: reduce asset filename length and remove tilde characters. #4535
|
948 |
+
- Fix: RTL stylesheet loading for split code chunks. #4542
|
949 |
+
|
950 |
+
== 1.2.3 05/22/2020 ==
|
951 |
+
|
952 |
+
- Tweak: Updates to WooCommerce Payments in Setup Checklist #4293
|
953 |
+
|
954 |
+
== 1.2.2 05/18/2020 ==
|
955 |
+
|
956 |
+
- Fix: Respect tracking optin before new page load. #4368
|
957 |
+
- Enhancement: Add Jetpack connection to plugin benefits step #4374
|
958 |
+
|
959 |
+
== 1.2.0 05/18/2020 ==
|
960 |
+
|
961 |
+
- Enhancement: Add onboarding payments note #4157
|
962 |
+
- Enhancement: Marketing Inbox Note #4030
|
963 |
+
- Performance: Use Route based code splitting to reduce bundle size #4094
|
964 |
+
- Performance: trim down inbox note API request. #3977
|
965 |
+
- Fix: Proper display of elements in wcadmin pages when in a RTL environment. #4051
|
966 |
+
- Fix: Update UX when knowledge base articles fail to retrieve #4133
|
967 |
+
- Fix: Updated messaging after last step in OBW. #4148
|
968 |
+
- Fix: Reset profiler when visiting old OBW URL #4166.
|
969 |
+
- Fix: Dashboard flash before OBW chunk loads #4259
|
970 |
+
- Tweak: Enable the default homepage template to be filtered #4072 🎉 @stevegrunwell
|
971 |
+
- Tweak: Create admin note if Jetpack or WooCommerce Services plugin doesn't get installed due to an error during OBW #3888
|
972 |
+
- Tweak: Update Email Marketing note. #4167
|
973 |
+
- Tweak: Adjust "demo products" verbiage to "Sample Products" #4184 🎉 @jobthomas
|
974 |
+
- Tweak: Don't reschedule imports on failed imports #4263
|
975 |
+
- Tweak: Remove obsolete inbox messages #4182
|
976 |
+
- Dev: Make query selector for admin alerts more specific #4289 🎉 @pauloiankoski
|
977 |
+
- Dev: Guard against null themes in OBW #4244
|
978 |
+
- Dev: Update wcadmin db version after db callback #4323
|
979 |
+
- Dev: Only migrate options on version change #4324
|
980 |
+
- Dev: Use PAGE_ROOT constant to reduce redundant strings #4238 🎉 @codemascot
|
981 |
+
- Dev: Decouple Plugins DataStore from onboarding feature #4048
|
982 |
+
- Dev: Move API out of Onboarding #4093
|
983 |
+
- Dev: Add Profiler Step View Tracks #4141
|
984 |
+
- Dev: Add React Testing Library #4221
|
985 |
+
- Dev: Add List and Link components to Storybook #4219
|
986 |
+
- Dev: Cast Shipping Total to float #4042 🎉 @barryhughes
|
987 |
+
- Dev: Dynamic Currency with Context API #4027
|
988 |
+
- Dev: Remove Duplicate array entry #4049 🎉 @tivnet
|
989 |
+
|
990 |
+
== 1.1.3 05/18/2020 ==
|
991 |
+
|
992 |
+
- Tweak: Onboarding
|
993 |
+
- Fix: Respect tracking optin before new page load. #4368
|
994 |
+
|
995 |
+
== 1.1.2 05/12/2020 ==
|
996 |
+
|
997 |
+
== 1.1.1 05/05/2020 ==
|
998 |
+
|
999 |
+
- Fix: Storefront should show at top of theme options in onboarding wizard. #4187
|
1000 |
+
- Tweak: Remove Stripe autoconnect from payment task. #4164
|
1001 |
+
- Tweak: Hide suggested extensions in Marketing Tab if opted out of "Marketplace Suggestions"
|
1002 |
+
|
1003 |
+
== 1.1.0 04/23/2020 ==
|
1004 |
+
|
1005 |
+
- Tweak: Added link to "go shopping" button #3712
|
1006 |
+
- Tweak: Add PayFast payment gateway option for sites in South Africa #3738
|
1007 |
+
- Tweak: Onboarding
|
1008 |
+
- Tweak: Onboarding business step
|
1009 |
+
- Tweak: Onboarding
|
1010 |
+
- Tweak: Onboarding
|
1011 |
+
- Tweak: Remove 'add first product' note. #3876
|
1012 |
+
- Tweak: Onboarding
|
1013 |
+
- Tweak: Onboarding payments task
|
1014 |
+
- Tweak: Style and icon updates for Activity Panel #3965
|
1015 |
+
- Tweak: Remove iconbutton classes from Tag component #3993
|
1016 |
+
- Tweak: Reduce the number of default widgets on the dashboard. #4035
|
1017 |
+
- Tweak: Onboarding
|
1018 |
+
- Tweak: Overwrite button overflow css from Wordpress 5.4 defaults #4108
|
1019 |
+
- Tweak: business details step
|
1020 |
+
- Fix: Make analytics tables use the site's date format setting #3715
|
1021 |
+
- Fix: Alignment of select text #3723 🎉 @edmundcwm
|
1022 |
+
- Fix: inconsistent wording downloads report #3844 🎉 @jobthomas
|
1023 |
+
- Fix: Verify Stripe API keys in payment set up step. #3910
|
1024 |
+
- Fix: Connect to WooCommerce.com note disappears before connecting. #3909
|
1025 |
+
- Fix: Add WooCommerce support if store is using default theme #3908
|
1026 |
+
- Fix: Make WooCommerce breadcrumbs use WooCommerce Branding if it is installed #3798
|
1027 |
+
- Fix: handle cases where coupon dates are in an unexpected format. #3984
|
1028 |
+
- Fix: Onboarding
|
1029 |
+
- Fix: Added hook to delete woocommerce_onboarding_homepage_post_id #4015
|
1030 |
+
- Fix: Show admin notices on legacy admin screens. #4019
|
1031 |
+
- Fix: wcadmin pages work in Internet Explorer 11. #4037
|
1032 |
+
- Fix: OBW
|
1033 |
+
- Enhancement: Improve focus on task list #3796
|
1034 |
+
- Enhancement: Allow individual payment method setup in the onboarding task list #3782
|
1035 |
+
- Enhancement: "Personalize your store" reminder
|
1036 |
+
- Enhancement: WooCommerce Shipping order page banner prompt #3955
|
1037 |
+
- Enhancement: Marketing Tab
|
1038 |
+
- Enhancement: Add WooCommerce Payments Inbox note #4013
|
1039 |
+
- Onboarding: Add offline payment methods #3832
|
1040 |
+
- Enahncement: Create flat rate or free shipping methods from the onboarding task list #3927
|
1041 |
+
- Enahncement: Add WC Pay to startup checklist
|
1042 |
+
- Performance: only query necessary data in Orders Panel. #3969
|
1043 |
+
- Performance: speed up indicators endpoint response. #3997
|
1044 |
+
- Performance: only query requested stat totals in reports. #4009
|
1045 |
+
- Dev: Handle orphaned order statuses in analytics settings. #4090
|
1046 |
+
- Dev: Fix usage of WP_Error in nonglobal namespaces. #4115
|
1047 |
+
|
1048 |
+
== 1.0.3 03/22/2020 ==
|
1049 |
+
|
1050 |
+
- Fix: Stop calling protected has_satisfied_dependencies() on outdated plugin. #3938
|
1051 |
+
- Fix: Rename image assets in OBW business details step. #3931
|
1052 |
+
- Fix: Stop using WP Post store for Action Scheduler. #3936
|
1053 |
+
|
1054 |
+
== 1.0.2 03/18/2020 ==
|
1055 |
+
|
1056 |
+
- Enhancement: Onboarding
|
1057 |
+
- Dev: Update prestart script so readme.txt stable tag is updated #3911
|
1058 |
+
- Tweak: create database tables on an earlier hook to avoid conflicts with core WooCommerce. #3896
|
1059 |
+
|
1060 |
+
== 1.0.1 03/12/2020 ==
|
1061 |
+
|
1062 |
+
- Fix: Add Report Extension Example
|
1063 |
+
- Fix: Product report sorting by SKU when some products don't have SKUs
|
1064 |
+
- Fix: type warning on install timestamp in PHP 7.4
|
1065 |
+
- Fix: PHP error when WooCommerce core is Network Active on Multisites.
|
1066 |
+
- Fix: missing database table errors on WooCommerce upgrade.
|
1067 |
+
- Fix: undefined const WC_ADMIN_VERSION_NUMBER when WP < 5.3
|
1068 |
+
- Dev: Add Changelog script
|
1069 |
+
- Dev: Fix failing tests after WC core merge.
|
1070 |
+
- Dev: Bump WooCommerce tested up to tag
|
1071 |
+
|
1072 |
+
== 1.0.0 03/05/2020 ==
|
1073 |
+
|
1074 |
+
- Fix: Customers Report
|
1075 |
+
- Fix: OBW Connect
|
1076 |
+
- Fix: OBW
|
1077 |
+
- Fix: Update Country Labeling to Match Core #3790
|
1078 |
+
- Fix: Onboarding
|
1079 |
+
- Fix: Padding on Jetpack notices when activity panel is present. $3418
|
1080 |
+
- Fix: Taxes Report search. #3815
|
1081 |
+
- Fix: Taxes Report search bug and adds initial documentation. #3816
|
1082 |
+
- Fix: Activity Panels
|
1083 |
+
- Fix: Tracking on migrated options #3828
|
1084 |
+
- Dev: Onboarding
|
1085 |
+
|
1086 |
+
== 0.26.1 02/26/2020 ==
|
1087 |
+
|
1088 |
+
- Fix: Remove free text Search option when no query exists #3755
|
1089 |
+
- Fix: StoreAlert
|
1090 |
+
- Fix: WP Coding Standards PR Regressions #3760
|
1091 |
+
- Fix: OBW
|
1092 |
+
- Fix: coding standards violations #3763
|
1093 |
+
- Fix: Product titles include encoded entities #3765
|
1094 |
+
- Fix: Add deactivation hook to Package.php #3770
|
1095 |
+
- Fix: Add active version functions #3772
|
1096 |
+
|
1097 |
+
== 0.26.0 02/21/2020 ==
|
1098 |
+
|
1099 |
+
- Fix: Warning in product data store when tax amount is nonnumeric. #3656
|
1100 |
+
- Fix: Enable onboarding in production. #3680
|
1101 |
+
- Fix: Added new control in /packages/components/src/selectcontrol/list.js #3700
|
1102 |
+
- Fix: Alignment of select text #3723 👏 @edmundcwm
|
1103 |
+
- Fix: Create Onboarding homepage without redirect #3727
|
1104 |
+
- Enhancement: Move Customers report to WooCommerce Menu #3632
|
1105 |
+
- Performance: Remove slow physical products query from non setup checklist pages #3722
|
1106 |
+
- Performance: Make Stock Panel indicator more performant. #3729
|
1107 |
+
- Performance: Remove sideloaded images to save on build size #3731
|
1108 |
+
- Tweak: use cron instead of Action Scheduler for unsnoozing notes. #3662
|
1109 |
+
- Dev: Add tracks events when profiler steps are completed #3726
|
1110 |
+
- Dev: Ensure continue setup loads the onboarding profiler #3646
|
1111 |
+
- Dev: Travis tests on Github for release branch #3751
|
1112 |
+
- Add: Deactivation note for feature plugin #3687
|
1113 |
+
|
1114 |
+
== 0.25.1 02/07/2020 ==
|
1115 |
+
|
1116 |
+
- Dev: Enable onboarding #3651 (Onboarding)
|
1117 |
+
- Fix: Fix styling of search control in report table header and filters. #3603 (Analytics, Components, Packages)
|
1118 |
+
|
1119 |
+
== 0.25.0 01/29/2020 ==
|
1120 |
+
|
1121 |
+
- Fix: Onboarding
|
1122 |
+
- Fix: Fix styling of search control in report table header and filters. #3603 (Analytics, Components, Packages)
|
1123 |
+
- Fix: report table search component. #3618 (Analytics, Components, Packages)
|
1124 |
+
- Fix: Update broken note action hooks #3535 (Activity Panel, Inbox)
|
1125 |
+
- Fix: SQL error in category table sort. #3521 (Analytics)
|
1126 |
+
- Fix: handle uninstallation when in feature plugin mode. #3546 (On Merge to WC Core)
|
1127 |
+
- Fix: Exception on dashboard once Onboarding tasks are complete #3513
|
1128 |
+
- Fix: Make packagebased load inert when plugin is active. #3555 (On Merge to WC Core)
|
1129 |
+
- Fix: Properly style theme selection button in Site Profiler #3489
|
1130 |
+
- Fix: component styles for WordPress 5.3. #3357 (Build, Components, Design, Packages)
|
1131 |
+
- Fix: `CompareFilter` functionality regression. #3421 (Analytics, Components, Packages)
|
1132 |
+
- Fix: don't run database migrations on new installs. #3473
|
1133 |
+
- Fix: WCAdmin header on settings and status pages. #3389 (Activity Panel)
|
1134 |
+
- Fix: show pending product reviews when comment moderation is disabled. #3459 (Activity Panel)
|
1135 |
+
- Fix: error when trying to download report data. #3429 (Analytics)
|
1136 |
+
- Fix: invalidate Reports cache when changing Analytics settings. #3465 (Analytics, REST API, Settings)
|
1137 |
+
- Fix: Time zone offset calculation on customer last active date. #3388 (Analytics)
|
1138 |
+
- Fix: remove the header when user doesn't have required permissions #3386 (Activity Panel)
|
1139 |
+
- Fix: make report filter date props optional #3359 (Components, Extensibility, Packages)
|
1140 |
+
- Dev: fix strict standards in Scheduler classes #3583
|
1141 |
+
- Dev: Handle custom currency formats #3349 (Components, Packages)
|
1142 |
+
- Dev: Onboarding
|
1143 |
+
- Dev: SelectControl
|
1144 |
+
- Dev: Onboarding
|
1145 |
+
- Dev: Onboarding
|
1146 |
+
- Dev: Onboarding
|
1147 |
+
- Dev: Update translation scripts and instructions for creating `.json` files. #3433 (Build)
|
1148 |
+
- Dev: Onboarding
|
1149 |
+
- Dev: Onboarding
|
1150 |
+
- Dev: AssetDataRegistry
|
1151 |
+
- Dev: DataStores
|
1152 |
+
- Dev: Update to latest PHPUnit 7 #3571 (Build)
|
1153 |
+
- Dev: Default the Calypso environment to production #3347 (Onboarding)
|
1154 |
+
- Dev: Add autocomplete props to address fields in onboarding and adjust country/state matching #3338 (Onboarding)
|
1155 |
+
- Dev: Add purchase modal at the end of the profile wizard #3444 (Onboarding)
|
1156 |
+
- Dev: Standardize hook and filter prefixes. #3339 (On Merge to WC Core)
|
1157 |
+
- Dev: Onboarding Add button to continue setup after importing products #3402 (Build, Onboarding)
|
1158 |
+
- Task: Avoid redundant/unnecessary cleanup. #3580 (On Merge to WC Core)
|
1159 |
+
- Performance: Remove unnecessary use of lodash get #3598 (Onboarding)
|
1160 |
+
- Tweak: don't modify page titles for existing WooCommerce pages. #3585 (On Merge to WC Core)
|
1161 |
+
- Tweak: Onboarding Add Skip Step link on Themes Step. #3490 (Onboarding)
|
1162 |
+
- Tweak: Included RegExp for JS files in examples.config.js #3510 (Build, Extensibility) 👏 @yashwebkul
|
1163 |
+
- Tweak: Change Refunds to Returns on the dashboard. #3514
|
1164 |
+
- Tweak: Scroll to notices when displayed while the notice area is scrolled out of view. #3390 (Activity Panel)
|
1165 |
+
- Tweak: Add/disable plugin filter #3361
|
1166 |
+
- Enhancement: add customer privacy erasure support. #3511 (Analytics)
|
1167 |
+
- Enhancement: allow filtering of hidden WP notices. #3391 (Activity Panel, Extensibility)
|
1168 |
+
- Enhancement: allow report cache layer to be turned off. #3434
|
1169 |
+
- Bug: Add SelectControl debouncing and keyboard fixes #3507 (Components, Packages)
|
1170 |
+
- Bug: Onboarding
|
1171 |
+
- Bug: Onboarding
|
1172 |
+
- Bug: Fix user data fields filter name. #3428 (Dashboard)
|
1173 |
+
- Bug: Onboarding
|
1174 |
+
- Bug: Onboarding
|
1175 |
+
- Bug: Onboarding
|
1176 |
+
|
1177 |
+
== 0.24.0 01/06/2020 ==
|
1178 |
+
|
1179 |
+
- Bug: Add SelectControl debouncing and keyboard fixes #3507 (Components, Packages)
|
1180 |
+
- Bug: Onboarding
|
1181 |
+
- Bug: CI
|
1182 |
+
- Bug: Onboarding
|
1183 |
+
- Bug: Onboarding
|
1184 |
+
- Bug: Onboarding
|
1185 |
+
- Bug: Onboarding
|
1186 |
+
- Fix: Properly style theme selection button in Site Profiler #3489
|
1187 |
+
- Fix: invalidate Reports cache when changing Analytics settings. #3465 (Analytics, REST API, Settings)
|
1188 |
+
- Fix: show pending product reviews when comment moderation is disabled. #3459 (Activity Panel)
|
1189 |
+
- Fix: component styles for WordPress 5.3. #3357 (Build, Components, Design, Packages)
|
1190 |
+
- Fix: WCAdmin header on settings and status pages. #3389 (Activity Panel)
|
1191 |
+
- Fix: make report filter date props optional #3359 (Components, Extensibility, Packages)
|
1192 |
+
- Dev: Update translation scripts and instructions for creating `.json` files. #3433 (Build)
|
1193 |
+
- Dev: Add initial documentation for the historical data import. #3506 (Documentation)
|
1194 |
+
- Dev: Onboarding
|
1195 |
+
- Dev: Onboarding
|
1196 |
+
- Dev: Add singular/plural distinction to onboarding plugins installation #3517 (Onboarding)
|
1197 |
+
- Dev: Onboarding
|
1198 |
+
- Dev: Onboarding
|
1199 |
+
- Dev: DataStores
|
1200 |
+
- Dev: AssetDataRegistry
|
1201 |
+
- Dev: Add autocomplete props to address fields in onboarding and adjust country/state matching #3338 (Onboarding)
|
1202 |
+
- Dev: Update instructions for documenting new components. #3443 (Components, Documentation)
|
1203 |
+
- Dev: Add purchase modal at the end of the profile wizard #3444 (Onboarding)
|
1204 |
+
- Dev: Fix the "is this card useful" prompt display #3427 (Onboarding)
|
1205 |
+
- Dev: Default the Calypso environment to production #3347 (Onboarding)
|
1206 |
+
- Dev: Standardize hook and filter prefixes. #3339 (On Merge to WC Core)
|
1207 |
+
- Dev: Fix revenue question translation with currency conversion #3358 (Onboarding, Packages)
|
1208 |
+
- Dev: Onboarding Add button to continue setup after importing products #3402 (Build, Onboarding)
|
1209 |
+
- Tweak: Onboarding Add Skip Step link on Themes Step. #3490 (Onboarding)
|
1210 |
+
- Tweak: Included RegExp for JS files in examples.config.js #3510 (Build, Extensibility) 👏 @yashwebkul
|
1211 |
+
- Tweak: Change Refunds to Returns on the dashboard. #3514
|
1212 |
+
- Tweak: Scroll to notices when displayed while the notice area is scrolled out of view. #3390 (Activity Panel)
|
1213 |
+
- Tweak: Add/disable plugin filter #3361
|
1214 |
+
- Enhancement: allow report cache layer to be turned off. #3434
|
1215 |
+
|
1216 |
+
== 0.23.3 12/26/2019 ==
|
1217 |
+
|
1218 |
+
- Fix: don't run database migrations on new installs. #3473
|
1219 |
+
|
1220 |
+
== 0.23.2 12/19/2019 ==
|
1221 |
+
|
1222 |
+
- Enhancement: allow filtering of hidden WP notices. #3391 (Activity Panel, Extensibility)
|
1223 |
+
- Fix: error when trying to download report data. #3429 (Analytics)
|
1224 |
+
- Fix: `CompareFilter` functionality regression. #3421 (Analytics, Components, Packages)
|
1225 |
+
- Fix: Time zone offset calculation on customer last active date. #3388 (Analytics)
|
1226 |
+
- Fix: remove the header when user doesn't have required permissions #3386 (Activity Panel)
|
1227 |
+
- Bug: Fix user data fields filter name. #3428 (Dashboard)
|
1228 |
+
|
1229 |
+
== 0.23.1 12/08/2019 ==
|
1230 |
+
|
1231 |
+
- Fix: undefined function error.
|
1232 |
+
|
1233 |
+
== 0.23.0 12/06/2019 ==
|
1234 |
+
|
1235 |
+
- Dev: Add currency extension #3328 (Packages)
|
1236 |
+
- Dev: Packages
|
1237 |
+
- Dev: Remove Newspack dependency. #3302
|
1238 |
+
- Dev: DB Updates
|
1239 |
+
- Dev: use a filter to set default locale #3273
|
1240 |
+
- Dev: Allow core inclusion via Package.php #3196 (Build)
|
1241 |
+
- Dev: Fix filter gap on analytics select controls #3259 (Components, Packages)
|
1242 |
+
- Dev: rename data store get_* to add_* functions where function does not return values #3275
|
1243 |
+
- Dev: PHPCS fixes for onboarding files #3269 (Documentation)
|
1244 |
+
- Dev: Add a tracks queue to delay event recording & log embed page views #3250
|
1245 |
+
- Dev: Make WooCommerce brand localizable #3247
|
1246 |
+
- Dev: fix typos in JS docs #3248
|
1247 |
+
- Dev: capitalize WooCommerce Services #3249
|
1248 |
+
- Fix: errant moment locale data loading. #3362 (Components, Packages)
|
1249 |
+
- Fix: beginning of next day calculation on daylight saving time on the days the time changes. #3333 (Analytics)
|
1250 |
+
- Fix: Retrieve week last year data by calendar date instead of week alignment. #3271 (Analytics, Packages)
|
1251 |
+
- Fix: Fix checkout of main branch in CI environment. #3296 (Build)
|
1252 |
+
- Fix: decouple Date package from global wcSettings object. #3278 (Components, Packages)
|
1253 |
+
- Fix: Make the order count between customer and table total consistent. #3290 (Analytics)
|
1254 |
+
- Fix: decouple Currency and Number packages from global wcSettings object. #3277 (Components, Packages)
|
1255 |
+
- Fix: Add single customer REST API end point. #3174 (REST API)
|
1256 |
+
- Bug: Settings
|
1257 |
+
- Bug: Check if extended_info is set for order report items #3315 (REST API)
|
1258 |
+
- Bug: Filter invalid statuses from saved statuses #3268
|
1259 |
+
- Bug: Correcting and clarifying analytics terms and calculations #3104 (Analytics, Components, Packages)
|
1260 |
+
- Bug: Select control
|
1261 |
+
- Tweak: Add a filter that allows disabling WooCommerce Admin. #3350 (On Merge to WC Core)
|
1262 |
+
- Tweak: remove global settings dependency from Navigation package. #3294 (Components, Packages)
|
1263 |
+
- Tweak: Search component
|
1264 |
+
|
1265 |
+
== 0.22.0 11/13/2019 ==
|
1266 |
+
|
1267 |
+
- Fix: Incorrect calculation of tax summary on Taxes screen. #3158 (Analytics)
|
1268 |
+
- Fix: Correct product and coupon count on edited orders. #3103 (Analytics)
|
1269 |
+
- Bug: Update filter picker to use key instead of id #3214 (Analytics, Components, Packages)
|
1270 |
+
- Bug: Fix ellipsis menu style #3141 (Analytics, Components, Packages)
|
1271 |
+
- Enhancement: prompt stores to add their first product(s). #3119 (Inbox)
|
1272 |
+
- Enhancement: Add query filters to data stores.
|
1273 |
+
- Dev: Move Analytics REST endpoints to `wcanalytics` namespace. #3204 (Components, Packages)
|
1274 |
+
- Dev: Refactor data store classes. #2961 (REST API)
|
1275 |
+
- Dev: WooCommerce Admin has been marked as compatible with WooCommerce 3.8.0. #3201
|
1276 |
+
- Dev: update tested to version for WC and WP #3162
|
1277 |
+
- Tweak: add usage tracking inbox notice. #3112 (Activity Panel, Inbox)
|
1278 |
+
- Tweak: Field misalignment in product edit screen. #3145
|
1279 |
+
- Task: Fix PHP linter errors. #3188
|
1280 |
+
|
1281 |
+
== 0.21.0 10/30/2019 ==
|
1282 |
+
|
1283 |
+
- Fix: report export format when generated serverside. #2987 (Analytics, Packages)
|
1284 |
+
- Fix: Address discrepancies in Revenue totals between Analytics screens. #3095 (Analytics)
|
1285 |
+
- Fix: Error in category comparison chart. #3027 (Analytics, REST API)
|
1286 |
+
- Fix: create table error during import. #3022 (Analytics, Build)
|
1287 |
+
- Tweak: automatically update DB version during plugin updates. #3113
|
1288 |
+
- Tweak: add visual feedback for Inbox Note Actions #3039 (Activity Panel, Build, Inbox)
|
1289 |
+
- Tweak: track inbox note views. #3096 (Activity Panel, Build, Inbox)
|
1290 |
+
- Tweak: Moved WCAdmin specific actions from TableCard to ReportTable. #2900 (Build, Components, Packages)
|
1291 |
+
- Dev: Fix asset image URL and business extension images #3062
|
1292 |
+
- Dev: Fix broken plugin builds by adding missing feature flag check #3053 (Build)
|
1293 |
+
- Dev: Add the ability to create custom plugin builds #3044 (Build)
|
1294 |
+
- Enhancement: add management link to Reviews panel. #3011 (Activity Panel)
|
1295 |
+
|
1296 |
+
== 0.20.1 09/24/2019 ==
|
1297 |
+
|
1298 |
+
- Fix: use category lookup id instead of term taxonomy id (#3027)
|
1299 |
+
- Fix: Update order stats table status index length. (#3022)
|
1300 |
+
|
1301 |
+
== 0.20.0 09/24/2019 ==
|
1302 |
+
|
1303 |
+
- Dev: Fix issue #2992 (order number in orders panel) #2994
|
1304 |
+
- Dev: Replace lodash isNaN() with native Number.isNaN() #2998 (Build, Packages)
|
1305 |
+
- Dev: Ignore filename rules for PSR4 classes. #2967 (Build)
|
1306 |
+
- Dev: Category Lookup Table Fix Category Segments #2253
|
1307 |
+
- Dev: Replace lodash isFinite() with native Number.isFinite() #2977 (Build, Components, Packages)
|
1308 |
+
- Dev: Add filter to notes datastore where clauses. #2819
|
1309 |
+
- Dev: Copy component READMEs to docs folder before GH page deploy. #2952 (Build)
|
1310 |
+
- Dev: Add GitHub pages deploy step to Travis config. #2940 (Build, Documentation)
|
1311 |
+
- Dev: Fix plugin installation when working from a push instead of a pull request. #2950 (Build)
|
1312 |
+
- Dev: Fix pull request branch detection on CI (try #2) #2944 (Build)
|
1313 |
+
- Dev: Only build pushes to main branch. #2941 (Build)
|
1314 |
+
- Dev: Fix pull request branch detection on CI #2942 (Build)
|
1315 |
+
- Dev: refresh component documentation #2872 (Build, Components, Documentation, Packages)
|
1316 |
+
- Dev: Simplified intervals_missing method of DataStore class #2920 👏 @codemascot
|
1317 |
+
- Dev: Simplified intervals_missing method of TimeInterval class #2920 👏 @codemascot
|
1318 |
+
- Enhancement: add option to email a download link when exporting reports. #2899 (Analytics, REST API)
|
1319 |
+
- Fix: Catch notices that are hooked earlier than priority 10. #2981
|
1320 |
+
- Performance: add caching layer to analytics. #2970 (Analytics)
|
1321 |
+
- Performance: reduce JS bundle size. #2933 (Build)
|
1322 |
+
- Bug: Fix conflict with Blocks 2.4 #2846
|
1323 |
+
|
1324 |
+
== 0.19.0 09/24/2019 ==
|
1325 |
+
|
1326 |
+
- Dev: Use upstream webpackrtlplugin #2870 (Build)
|
1327 |
+
- Dev: Fix variable name typo #2922
|
1328 |
+
- Dev: Update no data message in table #2854 (Components, Packages)
|
1329 |
+
- Fix: persist date_last_active for customer reports #2881 (Analytics) 👏 @cojennin
|
1330 |
+
- Tweak: consistent naming for report columns. #2845 (Design)
|
1331 |
+
- Tweak: schedule customer lookup table updates instead of running during checkout. #2832
|
1332 |
+
- Tweak: have Import note action scroll to import section of settings screen. #2799 (Activity Panel, Components, Inbox, Packages)
|
1333 |
+
- Tweak: change report charts filter name. #2843 (Components, Documentation, Packages)
|
1334 |
+
- Bug: Fix chart type buttons misalignment #2871 (Components, Packages)
|
1335 |
+
|
1336 |
+
== 0.18.0 08/28/2019 ==
|
1337 |
+
|
1338 |
+
- Fix: Product in dropdown clickable in FF/Safari #2839 (Components, Packages) 👏 @cojennin
|
1339 |
+
- Fix: gross order total calculation. #2817 (Analytics)
|
1340 |
+
- Fix: Date calculation on notes being double adjusted to UTC. #2818 (Inbox)
|
1341 |
+
- Fix: Bug navigating from DevDoc component pages to WP dashboard pages. #2827 (Documentation)
|
1342 |
+
- Fix: Import all used Gutenberg component styles. #2679
|
1343 |
+
- Fix: report column visibility preference bug. #2806 (Analytics, Components, Packages, Settings)
|
1344 |
+
- Fix: remove date picker from Customers Report. #2805 (Analytics)
|
1345 |
+
- Bug: Orders report now shows coupons in Coupon(s) column #2812 (Analytics) 👏 @cojennin
|
1346 |
+
- Enhancement: add Facebook extension inbox note. #2798 (Activity Panel, Inbox)
|
1347 |
+
- Enhancement: handle simple to variable product changes in reports. #2814 (Analytics)
|
1348 |
+
- Dev: Release Scripts
|
1349 |
+
- Dev: Components
|
1350 |
+
- Dev: Search List Control
|
1351 |
+
- Dev: Update List actionable items to be wrapped with Link #2779 (Components, Packages)
|
1352 |
+
- Tweak: add empty dataset treatment for report tables. #2801 (Analytics, Components, Packages)
|
1353 |
+
|
1354 |
+
== 0.17.0 08/15/2019 ==
|
1355 |
+
|
1356 |
+
- Fix: chart data fetch/render over long time periods #2785 (Analytics)
|
1357 |
+
- Fix: chart display when comparing categories. #2710 (Analytics)
|
1358 |
+
- Fix: Allow WooCommerce Admin to be deleted through the plugin screen when WooCommerce is not active. #2762
|
1359 |
+
- Fix: Charts being partially rendered on long time periods. #2776 (Analytics)
|
1360 |
+
- Fix: Customer last active date showing `Invalid date`. #2764 (Analytics)
|
1361 |
+
- Fix: issue where product category update button was not always clickable #2753
|
1362 |
+
- Fix: Add version parameter to `_doing_it_wrong` on `current_screen`. #2733
|
1363 |
+
- Fix: Short circuit admin title filter when applied by third parties too early. #2744
|
1364 |
+
- Fix: chart display when comparing categories. #2708 (Analytics)
|
1365 |
+
- Task: update the class filename exclusion to /src/ for PSR4 #2794
|
1366 |
+
- Task: update WC tested to version to 3.7.0 #2782
|
1367 |
+
- Task: Update report endpoints to be PSR4 autoloaded #2755 (Build)
|
1368 |
+
- Task: Update feature classes to be PSR4 autoloaded. #2736 (Build)
|
1369 |
+
- Tweak: Increase zIndex on popover elements. #2777
|
1370 |
+
- Bug: Fix daily cron event (PSR4) #2754 (Build)
|
1371 |
+
- Bug: Only apply current submenu CSS reset on nonembed pages. #2687
|
1372 |
+
- Dev: Add `wc_admin_get_feature_config` filter to feature config array. #2689
|
1373 |
+
|
1374 |
+
== 0.16.0 07/24/2019 ==
|
1375 |
+
|
1376 |
+
- Tweak: Change verbiage of feedback notification. #2677
|
1377 |
+
- Dev: Update unit tests to work with PHPUnit 7+. #2678
|
1378 |
+
- Dev: Webpack
|
1379 |
+
- Dev: Replace 'stringifyQuery' with 'addQueryArgs' #2655 (Build, Components, Packages)
|
1380 |
+
- Dev: Tests setup
|
1381 |
+
- Dev: show example extension list as list in readme #2619 (Documentation)
|
1382 |
+
- Fix: Bug that was preventing confirmation dialog from showing after saving settings. #2660
|
1383 |
+
- Fix: completed orders lingering in activity panel. #2659 (Activity Panel, REST API)
|
1384 |
+
- Fix: Location of unread indicators in activity panel. #2662
|
1385 |
+
- Fix: Zindex issue in empty message on chart #2646 (Components, Packages)
|
1386 |
+
- Fix: Disable placeholder animation when prefersreducedmotion is set #2645 (Accessibility)
|
1387 |
+
- Fix: reactspring breaking IE11 #2698 (Build)
|
1388 |
+
- Bug: Fix missing nav on connected admin pages. #2676
|
1389 |
+
- Task: Add priority 2 Tracks events #2633 (Components, Packages)
|
1390 |
+
- Task: Add priority 3 Tracks events #2638 (Components, Packages)
|
1391 |
+
- Task: Add instructions for translating to contributing docs. #2618 (Documentation)
|
1392 |
+
|
1393 |
+
== 0.15.0 07/11/2019 ==
|
1394 |
+
|
1395 |
+
- Fix: Compare checkboxes in report tables #2571
|
1396 |
+
- Fix: Use correct links in DevDocs. #2602 (Documentation)
|
1397 |
+
- Fix: Prevent error when no actionable order statuses are set #2577
|
1398 |
+
- Fix: exclude old WC autodraft orders from import #2612 (Analytics)
|
1399 |
+
- Fix: Only calculate one order row when the order has multiple coupons. #2484 (Analytics)
|
1400 |
+
- Fix: Cast is_snoozable as int prior to database save #2573
|
1401 |
+
- Fix: Update layout of Settings Page and notify users when settings are not saved. #2544
|
1402 |
+
- Fix: Change size of Header to 56px fixes bug in product edit page toolbar being hidden.
|
1403 |
+
- Fix: Stock notifs
|
1404 |
+
- Fix: WordPress Notifications Activity Panel falsely saying there are notices to be seen. #2552
|
1405 |
+
- Fix: Fixes issue with alerts on mobile #2537
|
1406 |
+
- Fix: Track name for activity panel open event #2532
|
1407 |
+
- Fix: margins on nonupdate notices. #2487 👏 @benignant
|
1408 |
+
- Dev: Introduce a new Products by Tag(s) block #554
|
1409 |
+
- Dev: Tracks
|
1410 |
+
- Dev: Fix
|
1411 |
+
- Dev: Update colorstudio to 1.0.5 #2575 (Build, Packages)
|
1412 |
+
- Dev: Add countLabel prop to SearchListItem #2569 (Components, Packages)
|
1413 |
+
- Dev: Route handling
|
1414 |
+
- Dev: Customizable dashboard
|
1415 |
+
- Dev: Dashboard
|
1416 |
+
- Dev: Advanced Filters
|
1417 |
+
- Performance: check for scheduled snooze action once per hour instead of every admin request. #2593
|
1418 |
+
- Task: Add tracks event to Store Alert and Inbox Notification action clicks #2559
|
1419 |
+
- Task: Send tracks event for snoozing store alerts. #2560
|
1420 |
+
- Task: Tracks
|
1421 |
+
- Enhancement: Add Report CSV Export Endpoint #2526 (Analytics, REST API)
|
1422 |
+
- Enhancement: Remove updated stock products from Activity Panel #2442 (Activity Panel)
|
1423 |
+
- Enhancement: Add Reports CSV Exporter Class #2502 (Analytics)
|
1424 |
+
- Enhancement: add state/region to Customers Report. #2463 (Analytics) 👏 @KZeni
|
1425 |
+
- Tweak: remove placeholder link. #2561
|
1426 |
+
- Tweak: Open external note action links in a new tab #2462 (Activity Panel, Inbox)
|
1427 |
+
- Tweak: fix some report endpoint default params. #2496 (REST API)
|
1428 |
+
- Bug: Fix batch queue range bug. #2521
|
1429 |
+
|
1430 |
+
== 0.14.0 06/24/2019 ==
|
1431 |
+
|
1432 |
+
- Dev: Action Scheduler
|
1433 |
+
- Dev: Fix Activity Panel being overlapped by editor toolbar #2446 (Activity Panel)
|
1434 |
+
- Dev: update tested to version in plugin repo readme.txt #2443
|
1435 |
+
- Dev: Allow keyboard interaction in Stock Activity Panel form #2447 (Accessibility, Activity Panel)
|
1436 |
+
- Dev: Activity Panels
|
1437 |
+
- Dev: Add wpapifetch script to dependencies #2460
|
1438 |
+
- Dev: Remove the "wpClosedMenu" page setting #2441 (Build)
|
1439 |
+
- Dev: Fix revenue and orders charts using the wrong endpoint in the Dashboard #2417 (Dashboard)
|
1440 |
+
- Dev: Fix conflicts with WordPress.com toolbar #2431 (Activity Panel)
|
1441 |
+
- Dev: Table queries
|
1442 |
+
- Dev: Update Dashboard Charts naming and order #2429 (Dashboard)
|
1443 |
+
- Bug: add match==any support for advanced orders table filter #2228
|
1444 |
+
- Bug: Fix search bar in Orders page not being tapable on mobile #2384
|
1445 |
+
- Fix: PHP errors on missing refund orders during import. #2464 (Analytics)
|
1446 |
+
- Fix: fix type in readme changelog for 0.13.0 #2457 (Documentation)
|
1447 |
+
- Fix: handle internal `rest_do_request()` error conditions. #2423 (Dashboard)
|
1448 |
+
- Enhancement: Report Tables
|
1449 |
+
- Tweak: Add test to catch missing version updates. #2424 (Build)
|
1450 |
+
- Tweak: Reduce style dependencies on WP core, avoid errantly including WP core's Google Fonts. #2432 (Components)
|
1451 |
+
- Task: Remove test menu from Orders panel #2438 (Activity Panel)
|
1452 |
+
|
1453 |
+
== 0.13.2 06/13/2019 ==
|
1454 |
+
|
1455 |
+
- Fix: Bump plugin version for database update.
|
1456 |
+
|
1457 |
+
== 0.13.1 06/12/2019 ==
|
1458 |
+
|
1459 |
+
- Fix: Exit deactivate early if WooCommerce not active. #2410
|
1460 |
+
|
1461 |
+
== 0.13.0 06/12/2019 ==
|
1462 |
+
|
1463 |
+
- Fix: Notes
|
1464 |
+
- Fix: Double space at 191 row #2369 👏 @shoheitanaka
|
1465 |
+
- Fix: Misspelling at update config.js #2368 👏 @shoheitanaka
|
1466 |
+
- Fix: Move StoreAlerts below screen meta links on embed pages. #2291
|
1467 |
+
- Fix: Extensions
|
1468 |
+
- Fix: Dashboard Extension Example
|
1469 |
+
- Fix: wcapi
|
1470 |
+
- Fix: Remove errant import update operation from `wpapi` spec. #2271
|
1471 |
+
- Fix: Refactor main file into singleton class structure #2226
|
1472 |
+
- Enhancement: Settings
|
1473 |
+
- Enhancement: Trigger an action server side when admin note actions are clicked #2325
|
1474 |
+
- Enhancement: Add progress bars to Historical Data Import screen #2312
|
1475 |
+
- Enhancement: Only show unactioned notes in the Inbox panel. #2327 (Inbox)
|
1476 |
+
- Enhancement: Add support for “primary” admin notice actions. #2269
|
1477 |
+
- Enhancement: Allow links in admin notice content. #2272
|
1478 |
+
- Dev: Add tracks to import jobs #2193
|
1479 |
+
- Dev: Notes
|
1480 |
+
- Dev: Fix Activity Panel layout on mobile #2405 (Activity Panel)
|
1481 |
+
- Dev: Add uninstall file to release ZIP #2402 (Build)
|
1482 |
+
- Dev: Add date_created_gmt property to orders endpoint #2086 (Activity Panel)
|
1483 |
+
- Dev: Transpile newspackcomponents package #2348 (Build)
|
1484 |
+
- Dev: Low stock handling inconsistencies with WooCommerce 3.6+ #2191
|
1485 |
+
- Dev: Remove d3array dependency #2286 (Build)
|
1486 |
+
- Dev: Dashboard Extentions
|
1487 |
+
- Dev: Fix `boxshadow8dp` error. #2290 (Components, Packages)
|
1488 |
+
- Dev: Persisted Queries
|
1489 |
+
- Dev: Remove customizable dashboard heading #2321 (Dashboard)
|
1490 |
+
- Dev: Dashboard
|
1491 |
+
- Dev: Hook up import/totals endpoint to Historical Data Import screen #2208
|
1492 |
+
- Bug: Fix wrong average numbers in chart legends #2352 (Analytics, Components, Packages)
|
1493 |
+
- Bug: Fix some data not to being imported when 'skip_existing' option is enabled #2385
|
1494 |
+
- Bug: Don't create Notices tab in Activity Panel if notices HTML element was removed by a plugin #2378
|
1495 |
+
- Bug: Prevent inactive tabs from making requests #2377
|
1496 |
+
- Bug: Add missing space in Orders Activity Panel card #2306 (Activity Panel)
|
1497 |
+
- Bug: Handle `WC_Admin_Notices`. #2245 (Activity Panel, On Merge to WC Core)
|
1498 |
+
- Bug: Exclude autodraft and trashed orders from imports. #2265
|
1499 |
+
- Tweak: Allow paragraph tags in admin notes. #2344 (Inbox)
|
1500 |
+
- Tweak: Allow note action URLs to be empty. #2324 (Inbox)
|
1501 |
+
- Task: Remove second beta warning from readme #2362
|
1502 |
+
- Task: Remove beta warning from readme. #2340
|
1503 |
+
|
1504 |
+
== 0.12.0 05/14/2019 ==
|
1505 |
+
|
1506 |
+
- Fix: dashboard issues #2194
|
1507 |
+
- Fix: Dashboard
|
1508 |
+
- Fix: Refactor page handler API #2209
|
1509 |
+
- Fix: EllipsisMenu misalignment in wide containers #2207
|
1510 |
+
- Fix: Show Y grid ticks/lines in charts where all values are lower than 1 #2147
|
1511 |
+
- Fix: Dashboard
|
1512 |
+
- Fix: add defaultOrder field to tablecard header #2139 👏 @rrennick
|
1513 |
+
- Fix: Travis
|
1514 |
+
- Fix: Vertically center Dashboard 'Add more' button #2171
|
1515 |
+
- Fix: Don't make an API call when there are no performance indicators #2157
|
1516 |
+
- Fix: Fix customer type filter param in orders report #2169
|
1517 |
+
- Fix: Persist chart interval in Dashboard #2156
|
1518 |
+
- Fix: Prevent chart type buttons breaking in two lines #2135
|
1519 |
+
- Dev: Handle “all guests” when getting customers from orders. #2038
|
1520 |
+
- Dev: Order milestones
|
1521 |
+
- Dev: Replace Rebuild reports settings with Import Historical Data #2198
|
1522 |
+
- Dev: add a defaultValue parameter to the ReportFilters component #2150 👏 @rrennick
|
1523 |
+
- Dev: Record refunds separate from order entries #2083
|
1524 |
+
- Dev: Add refund filtering to order reports #2179
|
1525 |
+
- Dev: Hook up API Historical Data screen to API endpoints #2177
|
1526 |
+
- Dev: Save section/block preferences in user data #2148
|
1527 |
+
- Dev: Add Historical Data Import Screen #2073
|
1528 |
+
- Dev: EllipsisMenu
|
1529 |
+
- Dev: Dashboard
|
1530 |
+
- Dev: Allow renaming Dashboard sections #2131
|
1531 |
+
- Dev: Add import endpoint and controller #2034
|
1532 |
+
- Dev: Support Sequential Order Numbers in Downloads Report order number filter #1907
|
1533 |
+
- Dev: Scroll to top of the table when navigating table pages #2051
|
1534 |
+
- Dev: Add empty state for the Reviews panels #2124
|
1535 |
+
|
1536 |
+
== 0.11.0 04/17/2019 ==
|
1537 |
+
|
1538 |
+
- Dev: Extend report submenu items #2033
|
1539 |
+
- Dev: Extension Examples #2018
|
1540 |
+
- Dev: Update admin notes readme #2043
|
1541 |
+
- Dev: Add profile wizard base page #1933
|
1542 |
+
- Dev: Method to publish core ready features #1863
|
1543 |
+
- Dev: Add PHP autofix to precommit hook #2022
|
1544 |
+
- Dev: PHP Lint fixes #2023
|
1545 |
+
- Dev: Update Link in readme to Proper Location #2026
|
1546 |
+
- Dev: Split D3Chart utils/axis file #2000
|
1547 |
+
- Dev: Remove coupon_total from order stats table #1975
|
1548 |
+
- Fix: Transpile acornjsx package #2064
|
1549 |
+
- Fix: Inbox
|
1550 |
+
- Fix: Check if welcome message notice exists before creating it #2063
|
1551 |
+
- Fix: Respect manual offsets in default before/after params #2035
|
1552 |
+
- Fix: Fix wrong dates in Reviews and Orders panels of the Activity Panel #2013
|
1553 |
+
- Fix: Make customer name extendable #1976
|
1554 |
+
- Fix: center mobile icon vertically #1990 👏 @rrennick
|
1555 |
+
- Fix: search filter focus #1994
|
1556 |
+
- Fix: Fix date filter layout on Android #1996
|
1557 |
+
- Fix: Order Status filter
|
1558 |
+
- Fix: add filter length condition to enable filter check #1983 👏 @rrennick
|
1559 |
+
- Fix: lookup product title in order meta if product has been deleted #1977 👏 @rrennick
|
1560 |
+
- Fix: Cast order totals as floats when calculating net total #1945
|
1561 |
+
- Enhancement: Add empty state in Stock panel #2049
|
1562 |
+
- Enhancement: Add empty state in Orders panel #2037
|
1563 |
+
- Enhancement: Hook up Stock panel #1998
|
1564 |
+
- Enhancement: Add order milestone notifications. #1872
|
1565 |
+
- Enhancement: Add leaderboard controller and endpoint #1995
|
1566 |
+
- Enhancement: Hook up leaderboards endpoint to dashboard #2004
|
1567 |
+
- Enhancement: Activity Panel
|
1568 |
+
- Enhancement: Scroll to top only when URL changes #1989
|
1569 |
+
- Enhancement: Allow negative values in charts #1979
|
1570 |
+
|
1571 |
+
== 0.10.0 04/02/2019 ==
|
1572 |
+
|
1573 |
+
- Dev: Properly namespaced methods in wcadmin.php. props @ronakganatra9 #1804
|
1574 |
+
- Dev: Changed textdomain to `woocommerceadmin` #1795
|
1575 |
+
- Dev: Updates to plugin header #1764
|
1576 |
+
- Dev: Clear scheduled actions on plugin deactivate #1715
|
1577 |
+
- Dev: Refactor getFilterQuery #1873
|
1578 |
+
- Dev: Update npm dependencies #1913
|
1579 |
+
- Fix: ESLint error in leaderboards #1914
|
1580 |
+
- Fix: REST API Requests failing with isUnboundedRequest #1954
|
1581 |
+
- Fix: Bugs in Reviews panel #1947
|
1582 |
+
- Fix: Scroll to top of page when changing reports #1958
|
1583 |
+
- Fix: Update variations controller filter names #1949
|
1584 |
+
- Fix: Sku sorting in variations report #1952 #1801 props @ronakganatra9
|
1585 |
+
- Fix: REST API customers exact match filters
|
1586 |
+
- Fix: EmptyContent on narrow viewports #1703
|
1587 |
+
- Fix: Empty chart and summary numbers in Categories Report #1698
|
1588 |
+
- Fix: Display chart and summary numbers placeholders when loading search terms #1694
|
1589 |
+
- Fix: Display order number on reports #1706
|
1590 |
+
- Fix: Missing Date Picker Calendar in RTL #1810
|
1591 |
+
- Fix: Circles on chart hover #1816
|
1592 |
+
- Fix: Date Range dropdown for RTL locales #1803
|
1593 |
+
- Fix: Sorting by tax_code in Taxes Report #1811
|
1594 |
+
- Fix: Charts in RTL locales #1794
|
1595 |
+
- Fix: RTL css #1781
|
1596 |
+
- Fix: CSS Lint issues in storealerts #1793
|
1597 |
+
- Fix: Products stats segmentation when filtering categories #1779
|
1598 |
+
- Fix: Remove timezone from appendTimestamp() output #1778
|
1599 |
+
- Fix: REST API Make variations and coupons endpoints return zerovalue items #1765
|
1600 |
+
- Fix: REST API make categories return zerovalue items #1755
|
1601 |
+
- Fix: REST API Make products and rates endpoints return zerovalue items #1722
|
1602 |
+
- Fix: Taxes report, sort taxes numerically #1766
|
1603 |
+
- Fix: Chart comparison mode single category #1762
|
1604 |
+
- Fix: Simplify options in filters #1748
|
1605 |
+
- Fix: Show compared keys in chart legends even if their values are 0 #1754
|
1606 |
+
- Fix: IE11 Leaderboard issue
|
1607 |
+
- Fix: Use IDs instead of labels to identify chart legend items #1730
|
1608 |
+
- Fix: Update table columns visibility when loading finishes #1729
|
1609 |
+
- Fix: Update chart colors #1731
|
1610 |
+
- Fix: Date Picker css tabs #1717
|
1611 |
+
- Fix: Infinite loop in customer population #1936
|
1612 |
+
- Fix: PHP notices on orders data store #1870
|
1613 |
+
- Fix: Table links to internal reports #1824
|
1614 |
+
- Accessibility: Add button focus style to report chart interval selector #1740
|
1615 |
+
- Enhancement: Add "Cancel All" method to ActionScheduler Store #1813
|
1616 |
+
- Enhancement: Add store notice for processing historical data #1763
|
1617 |
+
- Enhancement: Ensure other scheduled actions are claimed before WC Admin actions #1759
|
1618 |
+
- Enhancement: Load on hold reviews in the Activity Panel
|
1619 |
+
- Enhancement: Add overlay to Product Placeholder image #1880
|
1620 |
+
- Enhancement: Added "Remind me later" ability to StoreAlert component #1848
|
1621 |
+
- Enhancement: Set reviews Activity Panel unread indicator based off REST API data #1824
|
1622 |
+
- Enhancement: Set orders Activity Panel unread indicator based off REST API data #1860
|
1623 |
+
- Enhancement: Hide Reviews Activity Panel if reviews are disabled #1852
|
1624 |
+
- Enhancement: Lookup product title in order meta if product has been deleted #1977
|
1625 |
+
- Performance: Avoid unneeded chart rerenders #1780
|
1626 |
+
- Performance: Don't run lookup table historical population on activation of plugin #1741
|
1627 |
+
- Performance: Don't dispatch REST API requests when window/tab is hidden #1732
|
1628 |
+
- Performance: Only check for unsnooze note on admin_init #1960
|
1629 |
+
|
1630 |
+
== 0.8.0 02/28/2019 ==
|
1631 |
+
|
1632 |
+
- Table Component: Reset search on compare
|
1633 |
+
- Table Component: Fix search positioning in small viewports
|
1634 |
+
- MenuItem Component: Added isCheckBox prop
|
1635 |
+
- a11y: Enhancements to “Rows per Table” on the dashboard
|
1636 |
+
- Taxes Report: Fix comparison mode and segmentation labels
|
1637 |
+
- Test Framework: Require WordPress 5.0 or greater to run phpunit
|
1638 |
+
- Chart Component: Preserve chart colors bug fix
|
1639 |
+
- Navigation: Close wpadmin menu when navigating between reports in narrow viewports
|
1640 |
+
- Analytics: Don’t show variation table when in an active search
|
1641 |
+
- Analytics: Sort tabular data when selecting a Summary Number
|
1642 |
+
- Dashboard: Fix for style of summary number placeholders
|
1643 |
+
- Downloads/Customers Report: Fix for filters
|
1644 |
+
- Chart: Mouse pointer now displayed in entire clickable area
|
1645 |
+
- Chart: Fixes for the legend totals
|
1646 |
+
- Chart: Refactor of d3 logic
|
1647 |
+
- Chart: Add messaging when no data is available for selected filters
|
1648 |
+
- Build: Move IE11 css to specific css file
|
1649 |
+
- Downloads Report: Fix for sorting bug
|
1650 |
+
- Stock Report: fix the product link
|
1651 |
+
- Autocompleter: Increase debounce time to reduce API requests
|
1652 |
+
- Segmented Selection Component: fix for missing borders
|
1653 |
+
- Setup: Improvements to install flow
|
trunk/dist/activity-panels-help/style-rtl.css
ADDED
@@ -0,0 +1 @@
|
|
|
1 |
+
:root{--wp-admin-theme-color:#007cba;--wp-admin-theme-color-darker-10:#006ba1;--wp-admin-theme-color-darker-20:#005a87}body.admin-color-light{--wp-admin-theme-color:#0085ba;--wp-admin-theme-color-darker-10:#0073a1;--wp-admin-theme-color-darker-20:#006187}body.admin-color-modern{--wp-admin-theme-color:#3858e9;--wp-admin-theme-color-darker-10:#2145e6;--wp-admin-theme-color-darker-20:#183ad6}body.admin-color-blue{--wp-admin-theme-color:#096484;--wp-admin-theme-color-darker-10:#07526c;--wp-admin-theme-color-darker-20:#064054}body.admin-color-coffee{--wp-admin-theme-color:#46403c;--wp-admin-theme-color-darker-10:#383330;--wp-admin-theme-color-darker-20:#2b2724}body.admin-color-ectoplasm{--wp-admin-theme-color:#523f6d;--wp-admin-theme-color-darker-10:#46365d;--wp-admin-theme-color-darker-20:#3a2c4d}body.admin-color-midnight{--wp-admin-theme-color:#e14d43;--wp-admin-theme-color-darker-10:#dd382d;--wp-admin-theme-color-darker-20:#d02c21}body.admin-color-ocean{--wp-admin-theme-color:#627c83;--wp-admin-theme-color-darker-10:#576e74;--wp-admin-theme-color-darker-20:#4c6066}body.admin-color-sunrise{--wp-admin-theme-color:#dd823b;--wp-admin-theme-color-darker-10:#d97426;--wp-admin-theme-color-darker-20:#c36922}.woocommerce-layout__activity-panel-header{height:50px;background:#e0e0e0;padding:16px;display:flex;justify-content:space-between;align-items:center}@media(min-width:783px){.woocommerce-layout__activity-panel-header{padding:16px 24px}}.woocommerce-layout__activity-panel-header h3{font-size:13px;font-weight:600;line-height:16px;margin:0;padding:0}.woocommerce-layout__activity-panel-header .woocommerce-ellipsis-menu__toggle.components-button:not(:disabled):not([aria-disabled=true]):focus,.woocommerce-layout__activity-panel-header .woocommerce-ellipsis-menu__toggle.components-button:not(:disabled):not([aria-disabled=true]):hover{box-shadow:none;border-radius:10px;background:#ccc}.woocommerce-layout__inbox-title{color:#1e1e1e;display:flex;align-items:center}.woocommerce-layout__inbox-subtitle{color:#757575}.woocommerce-layout__inbox-badge{margin-right:6px;background-color:#757575;border-radius:13px;padding:0 6px;color:#fff;display:inline-block;text-align:center;vertical-align:top}
|
trunk/dist/activity-panels-inbox/style-rtl.css
ADDED
@@ -0,0 +1 @@
|
|
|
1 |
+
.woocommerce-layout__activity-panel-content .woocommerce-abbreviated-notifications{border-top:1px solid #e0e0e0}.woocommerce-layout__activity-panel-content .woocommerce-abbreviated-notifications>div{border:none;margin-bottom:0}.woocommerce-layout__activity-panel-content .woocommerce-abbreviated-notifications .woocommerce-abbreviated-notification h3{color:#007cba;color:var(--wp-admin-theme-color);font-weight:700;font-size:14px}.woocommerce-layout__activity-panel-content .woocommerce-abbreviated-notifications .woocommerce-abbreviated-notification div,.woocommerce-layout__activity-panel-content .woocommerce-abbreviated-notifications .woocommerce-abbreviated-notification p{color:#757575}.woocommerce-layout__activity-panel-content .woocommerce-abbreviated-notifications .woocommerce-abbreviated-notification .woocommerce-abbreviated-card__content{padding:12px 0 12px 24px}.woocommerce-layout__activity-panel-content .woocommerce-abbreviated-notifications .woocommerce-abbreviated-notification .woocommerce-abbreviated-card__content>:not(:first-child){margin-top:4px}.woocommerce-activity-panel .woocommerce-activity-card{position:relative;padding:24px;padding:var(--main-gap);background:#fff;border-bottom:1px solid #e0e0e0;color:#757575;font-size:13px;font-size:.8125rem}.woocommerce-activity-panel .woocommerce-activity-card:not(.woocommerce-empty-activity-card){display:grid;grid-template-columns:50px 1fr;grid-template-areas:"icon header" "icon body" "icon actions"}.woocommerce-activity-panel .woocommerce-activity-card__button{display:block;height:unset;background:none;align-items:unset;transition:unset;text-align:right;width:100%;padding:0}.woocommerce-activity-card__unread{position:absolute;top:18px;top:calc(var(--main-gap) - 6px);left:18px;left:calc(var(--main-gap) - 6px);width:6px;height:6px;border-radius:50%;background:#ca4a1f}.woocommerce-activity-card__icon{-ms-grid-row:1;-ms-grid-row-span:3;-ms-grid-column:1;grid-area:icon;fill:#e0e0e0}.woocommerce-activity-card__header{margin-bottom:16px;display:flex;flex-direction:column}.woocommerce-activity-card__header .woocommerce-activity-card__title{margin:0;font-size:14px;font-size:.875rem;order:2}.woocommerce-empty-activity-card .woocommerce-activity-card__header .woocommerce-activity-card__title{color:#1e1e1e;font-style:normal;line-height:24px;font-weight:400}.woocommerce-activity-card__button .woocommerce-activity-card__header .woocommerce-activity-card__title{margin-bottom:8px}.woocommerce-activity-card__header .woocommerce-activity-card__title a{text-decoration:none}.woocommerce-activity-card__header .woocommerce-activity-card__date{color:#757575;font-size:12px;font-size:.75rem;margin-bottom:12px;order:1}.woocommerce-activity-card__header .woocommerce-activity-card__subtitle{order:3}.woocommerce-activity-card__button .woocommerce-activity-card__header .woocommerce-activity-card__subtitle{margin-bottom:4px}@media(min-width:783px){.woocommerce-activity-card__header{-ms-grid-row:1;-ms-grid-column:2;grid-area:header;display:grid;grid-template:"title date" "subtitle date"/1fr auto}.woocommerce-activity-panel .woocommerce-activity-card.woocommerce-order-activity-card>.woocommerce-activity-card__header{-ms-grid-row:1;-ms-grid-column:1}.woocommerce-activity-card__header .woocommerce-activity-card__title{grid-area:title}.woocommerce-activity-card__header .woocommerce-activity-card__date{display:block;grid-area:date;justify-self:end;margin-bottom:0}.woocommerce-activity-card__header .woocommerce-activity-card__subtitle{grid-area:subtitle}}@media (min-width:783px){.woocommerce-activity-card__header .woocommerce-activity-card__title{-ms-grid-row:1;-ms-grid-column:1}.woocommerce-activity-card__header .woocommerce-activity-card__date{-ms-grid-row:1;-ms-grid-row-span:2;-ms-grid-column:2}.woocommerce-activity-card__header .woocommerce-activity-card__subtitle{-ms-grid-row:2;-ms-grid-column:1}}.woocommerce-activity-card__body{-ms-grid-row:2;-ms-grid-column:2;grid-area:body}.woocommerce-activity-panel .woocommerce-activity-card.woocommerce-order-activity-card>.woocommerce-activity-card__body{-ms-grid-row:2;-ms-grid-column:1}.woocommerce-activity-card__body>p:first-child{margin-top:0}.woocommerce-activity-card__body>p:last-child{margin-bottom:0}.woocommerce-empty-activity-card .woocommerce-activity-card__body{color:#757575;font-style:normal;font-weight:400;font-size:13px;font-size:.8125rem;line-height:20px}.woocommerce-activity-card__actions{-ms-grid-row:3;-ms-grid-column:2;grid-area:actions;margin-top:16px}.woocommerce-activity-panel .woocommerce-activity-card.woocommerce-order-activity-card>.woocommerce-activity-card__actions{-ms-grid-row:3;-ms-grid-column:1}.woocommerce-activity-card__actions>*+*{margin-right:.5em}.woocommerce-activity-card__actions .components-button{height:24px;padding:4px 10px;font-size:11px;font-size:.6875rem}.woocommerce-activity-card__actions .components-button.is-destructive:not(:hover){box-shadow:none}.woocommerce-activity-card.is-loading .is-placeholder{animation:loading-fade 1.6s ease-in-out infinite;background-color:#f0f0f0;color:transparent;display:inline-block;height:16px}.woocommerce-activity-card.is-loading .is-placeholder:after{content:" "}@media screen and (prefers-reduced-motion:reduce){.woocommerce-activity-card.is-loading .is-placeholder{animation:none}}.woocommerce-activity-card.is-loading .woocommerce-activity-card__title{width:80%}.woocommerce-activity-card.is-loading .woocommerce-activity-card__subtitle{margin-top:4px}.woocommerce-activity-card.is-loading .woocommerce-activity-card__date{width:100%;margin-bottom:16px}@media(min-width:783px){.woocommerce-activity-card.is-loading .woocommerce-activity-card__date{text-align:left;margin-bottom:0}}.woocommerce-activity-card.is-loading .woocommerce-activity-card__date .is-placeholder{width:68px}.woocommerce-activity-card.is-loading .woocommerce-activity-card__icon{margin-left:24px;margin-left:var(--main-gap)}.woocommerce-activity-card.is-loading .woocommerce-activity-card__icon .is-placeholder{height:33px;width:33px}.woocommerce-activity-card.is-loading .woocommerce-activity-card__body .is-placeholder{width:100%;margin-bottom:4px}.woocommerce-activity-card.is-loading .woocommerce-activity-card__body .is-placeholder:last-of-type{width:65%;margin-bottom:0}.woocommerce-activity-card.is-loading .woocommerce-activity-card__actions .is-placeholder{width:91px;height:24px}.woocommerce-activity-panel .woocommerce-activity-card.woocommerce-order-activity-card{grid-template-columns:1fr;grid-template-areas:"header" "body" "actions"}.woocommerce-activity-panel .woocommerce-activity-card.woocommerce-order-activity-card .woocommerce-activity-card__icon{display:none}.woocommerce-activity-panel .woocommerce-activity-card.woocommerce-order-activity-card .woocommerce-flag{display:inline-block}.woocommerce-activity-panel .woocommerce-activity-card.woocommerce-order-activity-card .woocommerce-activity-card__subtitle span+span:before{content:" • "}.woocommerce-activity-panel .woocommerce-activity-card.woocommerce-inbox-activity-card{grid-template-columns:72px 1fr;height:100%;opacity:1;padding:24px;padding:var(--main-gap)}@media screen and (prefers-reduced-motion:no-preference){.woocommerce-activity-panel .woocommerce-activity-card.woocommerce-inbox-activity-card{transition:opacity .3s,height 0s,padding 0s}}@media(max-width:782px){.woocommerce-activity-panel .woocommerce-activity-card.woocommerce-inbox-activity-card{grid-template-columns:64px 1fr}}.woocommerce-activity-panel .woocommerce-activity-card.woocommerce-inbox-activity-card .woocommerce-activity-card__header{margin-bottom:12px}.woocommerce-activity-panel .woocommerce-activity-card.woocommerce-inbox-activity-card.actioned{height:0;opacity:0;padding:0}@media screen and (prefers-reduced-motion:no-preference){.woocommerce-activity-panel .woocommerce-activity-card.woocommerce-inbox-activity-card.actioned{transition:opacity .3s,height 0s .3s,padding 0s .3s}}.woocommerce-stock-activity-card__image-overlay__product{height:33px;position:relative;width:33px}.woocommerce-stock-activity-card__image-overlay__product.is-placeholder:before{background-color:#757575;border-radius:2px;content:"";position:absolute;right:0;left:0;bottom:0;top:0;opacity:.1}@media screen and (prefers-reduced-motion:no-preference){.woocommerce-stock-activity-card{transition:opacity .3s}}.woocommerce-stock-activity-card.is-dimmed{opacity:.7}.woocommerce-stock-activity-card .woocommerce-stock-activity-card__stock-quantity{background:#f0f0f0;color:#757575;padding:3px 8px;border-radius:3px}.woocommerce-stock-activity-card .woocommerce-stock-activity-card__stock-quantity.out-of-stock{color:#d94f4f}.woocommerce-stock-activity-card .woocommerce-stock-activity-card__edit-quantity{display:inline-flex;width:50px;margin-left:10px}.woocommerce-stock-activity-card .woocommerce-stock-activity-card__edit-quantity input{border-radius:2px;height:30px}.woocommerce-stock-activity-card .woocommerce-stock-activity-card__edit-quantity input[type=number]{-moz-appearance:textfield}.woocommerce-stock-activity-card .woocommerce-stock-activity-card__edit-quantity input[type=number]::-webkit-inner-spin-button,.woocommerce-stock-activity-card .woocommerce-stock-activity-card__edit-quantity input[type=number]::-webkit-outer-spin-button{-webkit-appearance:none;margin:0}.woocommerce-stock-activity-card .woocommerce-activity-card__subtitle{color:#757575;font-size:12px;font-size:.75rem}.woocommerce-empty-activity-card{background:#f0f0f0;margin:20px;border-bottom:unset}:root{--wp-admin-theme-color:#007cba;--wp-admin-theme-color-darker-10:#006ba1;--wp-admin-theme-color-darker-20:#005a87}body.admin-color-light{--wp-admin-theme-color:#0085ba;--wp-admin-theme-color-darker-10:#0073a1;--wp-admin-theme-color-darker-20:#006187}body.admin-color-modern{--wp-admin-theme-color:#3858e9;--wp-admin-theme-color-darker-10:#2145e6;--wp-admin-theme-color-darker-20:#183ad6}body.admin-color-blue{--wp-admin-theme-color:#096484;--wp-admin-theme-color-darker-10:#07526c;--wp-admin-theme-color-darker-20:#064054}body.admin-color-coffee{--wp-admin-theme-color:#46403c;--wp-admin-theme-color-darker-10:#383330;--wp-admin-theme-color-darker-20:#2b2724}body.admin-color-ectoplasm{--wp-admin-theme-color:#523f6d;--wp-admin-theme-color-darker-10:#46365d;--wp-admin-theme-color-darker-20:#3a2c4d}body.admin-color-midnight{--wp-admin-theme-color:#e14d43;--wp-admin-theme-color-darker-10:#dd382d;--wp-admin-theme-color-darker-20:#d02c21}body.admin-color-ocean{--wp-admin-theme-color:#627c83;--wp-admin-theme-color-darker-10:#576e74;--wp-admin-theme-color-darker-20:#4c6066}body.admin-color-sunrise{--wp-admin-theme-color:#dd823b;--wp-admin-theme-color-darker-10:#d97426;--wp-admin-theme-color-darker-20:#c36922}#activity-panel-inbox{margin:0 24px}.woocommerce-layout__inbox-panel-header{padding:24px}.woocommerce-homepage-column .woocommerce-layout__inbox-panel-header{padding:0 24px}.woocommerce-inbox-message-enter{opacity:0;max-height:0;transform:translateX(-50%)}.woocommerce-inbox-message-enter-active{transition:opacity .5s,transform .5s,max-height .5s}.woocommerce-inbox-message-enter-active,.woocommerce-inbox-message-exit{opacity:1;max-height:100vh;transform:translateX(0)}.woocommerce-inbox-message-exit-active{opacity:0;max-height:0;transform:translateX(-50%);transition:opacity .5s,transform .5s,max-height .5s}.wooocommerce-inbox-card__header .woocommerce-badge{margin-right:16px}.woocommerce-inbox-dismiss-all-modal{width:565px;max-width:100%}.woocommerce-inbox-dismiss-all-modal .components-modal__content:before{margin-bottom:0}.woocommerce-inbox-dismiss-all-modal .components-modal__header{border-bottom:1px solid #ddd!important}.woocommerce-inbox-dismiss-all-modal .woocommerce-usage-modal__message{box-sizing:border-box;border-bottom:1px solid #ddd;padding:32px;display:flex;flex-direction:row;justify-content:space-between;background:#fff;align-items:center;height:60px;z-index:10;position:relative;position:sticky;top:0;margin:0 -32px 24px;font-size:1.2em}.woocommerce-inbox-dismiss-all-modal .woocommerce-usage-modal__actions{display:flex;justify-content:flex-end;margin-top:16px}.woocommerce-inbox-dismiss-all-modal .woocommerce-usage-modal__actions button{margin-right:16px}
|
trunk/dist/analytics-report-categories/style-rtl.css
ADDED
@@ -0,0 +1 @@
|
|
|
1 |
+
:root{--wp-admin-theme-color:#007cba;--wp-admin-theme-color-darker-10:#006ba1;--wp-admin-theme-color-darker-20:#005a87}body.admin-color-light{--wp-admin-theme-color:#0085ba;--wp-admin-theme-color-darker-10:#0073a1;--wp-admin-theme-color-darker-20:#006187}body.admin-color-modern{--wp-admin-theme-color:#3858e9;--wp-admin-theme-color-darker-10:#2145e6;--wp-admin-theme-color-darker-20:#183ad6}body.admin-color-blue{--wp-admin-theme-color:#096484;--wp-admin-theme-color-darker-10:#07526c;--wp-admin-theme-color-darker-20:#064054}body.admin-color-coffee{--wp-admin-theme-color:#46403c;--wp-admin-theme-color-darker-10:#383330;--wp-admin-theme-color-darker-20:#2b2724}body.admin-color-ectoplasm{--wp-admin-theme-color:#523f6d;--wp-admin-theme-color-darker-10:#46365d;--wp-admin-theme-color-darker-20:#3a2c4d}body.admin-color-midnight{--wp-admin-theme-color:#e14d43;--wp-admin-theme-color-darker-10:#dd382d;--wp-admin-theme-color-darker-20:#d02c21}body.admin-color-ocean{--wp-admin-theme-color:#627c83;--wp-admin-theme-color-darker-10:#576e74;--wp-admin-theme-color-darker-20:#4c6066}body.admin-color-sunrise{--wp-admin-theme-color:#dd823b;--wp-admin-theme-color-darker-10:#d97426;--wp-admin-theme-color-darker-20:#c36922}.woocommerce-table__product-categories>.woocommerce-table__breadcrumbs{display:inline-block;margin-left:12px}.woocommerce-table__product-categories .components-popover__content{padding:0 16px;text-align:right}.woocommerce-table__product-categories .components-popover__content .woocommerce-table__breadcrumbs{margin-top:12px;margin-bottom:12px}
|
trunk/dist/analytics-report-customers/style-rtl.css
ADDED
@@ -0,0 +1 @@
|
|
|
1 |
+
:root{--wp-admin-theme-color:#007cba;--wp-admin-theme-color-darker-10:#006ba1;--wp-admin-theme-color-darker-20:#005a87}body.admin-color-light{--wp-admin-theme-color:#0085ba;--wp-admin-theme-color-darker-10:#0073a1;--wp-admin-theme-color-darker-20:#006187}body.admin-color-modern{--wp-admin-theme-color:#3858e9;--wp-admin-theme-color-darker-10:#2145e6;--wp-admin-theme-color-darker-20:#183ad6}body.admin-color-blue{--wp-admin-theme-color:#096484;--wp-admin-theme-color-darker-10:#07526c;--wp-admin-theme-color-darker-20:#064054}body.admin-color-coffee{--wp-admin-theme-color:#46403c;--wp-admin-theme-color-darker-10:#383330;--wp-admin-theme-color-darker-20:#2b2724}body.admin-color-ectoplasm{--wp-admin-theme-color:#523f6d;--wp-admin-theme-color-darker-10:#46365d;--wp-admin-theme-color-darker-20:#3a2c4d}body.admin-color-midnight{--wp-admin-theme-color:#e14d43;--wp-admin-theme-color-darker-10:#dd382d;--wp-admin-theme-color-darker-20:#d02c21}body.admin-color-ocean{--wp-admin-theme-color:#627c83;--wp-admin-theme-color-darker-10:#576e74;--wp-admin-theme-color-darker-20:#4c6066}body.admin-color-sunrise{--wp-admin-theme-color:#dd823b;--wp-admin-theme-color-darker-10:#d97426;--wp-admin-theme-color-darker-20:#c36922}.woocommerce-report-table__scroll-point{position:relative;top:-48px}@media(max-width:782px){.woocommerce-report-table__scroll-point{top:-62px}}.woocommerce-feature-enabled-activity-panels .woocommerce-report-table__scroll-point{top:-108px}@media(max-width:782px){.woocommerce-feature-enabled-activity-panels .woocommerce-report-table__scroll-point{top:-122px}}.woocommerce-report-table .woocommerce-search{flex-grow:1}.woocommerce-report-table .components-card__header{display:grid;grid-gap:12px;grid-template-columns:min-content 1fr min-content}.woocommerce-report-table .woocommerce-table__compare.components-button{padding:8px}.woocommerce-report-table .woocommerce-ellipsis-menu{justify-self:flex-end}button.woocommerce-table__download-button{padding:6px 12px;color:#000;text-decoration:none;align-items:center}button.woocommerce-table__download-button svg{margin-left:8px;height:24px;width:24px}@media(max-width:782px){button.woocommerce-table__download-button svg{margin-left:0}button.woocommerce-table__download-button .woocommerce-table__download-button__label{display:none}}
|
trunk/dist/analytics-report-orders/style-rtl.css
ADDED
@@ -0,0 +1 @@
|
|
|
1 |
+
:root{--wp-admin-theme-color:#007cba;--wp-admin-theme-color-darker-10:#006ba1;--wp-admin-theme-color-darker-20:#005a87}body.admin-color-light{--wp-admin-theme-color:#0085ba;--wp-admin-theme-color-darker-10:#0073a1;--wp-admin-theme-color-darker-20:#006187}body.admin-color-modern{--wp-admin-theme-color:#3858e9;--wp-admin-theme-color-darker-10:#2145e6;--wp-admin-theme-color-darker-20:#183ad6}body.admin-color-blue{--wp-admin-theme-color:#096484;--wp-admin-theme-color-darker-10:#07526c;--wp-admin-theme-color-darker-20:#064054}body.admin-color-coffee{--wp-admin-theme-color:#46403c;--wp-admin-theme-color-darker-10:#383330;--wp-admin-theme-color-darker-20:#2b2724}body.admin-color-ectoplasm{--wp-admin-theme-color:#523f6d;--wp-admin-theme-color-darker-10:#46365d;--wp-admin-theme-color-darker-20:#3a2c4d}body.admin-color-midnight{--wp-admin-theme-color:#e14d43;--wp-admin-theme-color-darker-10:#dd382d;--wp-admin-theme-color-darker-20:#d02c21}body.admin-color-ocean{--wp-admin-theme-color:#627c83;--wp-admin-theme-color-darker-10:#576e74;--wp-admin-theme-color-darker-20:#4c6066}body.admin-color-sunrise{--wp-admin-theme-color:#dd823b;--wp-admin-theme-color-darker-10:#d97426;--wp-admin-theme-color-darker-20:#c36922}.woocommerce-orders-table__status{flex-direction:row-reverse}.woocommerce-orders-table__status .woocommerce-order-status__indicator{margin-left:0;margin-right:8px}
|
trunk/dist/analytics-report-products/style-rtl.css
ADDED
@@ -0,0 +1 @@
|
|
|
1 |
+
:root{--wp-admin-theme-color:#007cba;--wp-admin-theme-color-darker-10:#006ba1;--wp-admin-theme-color-darker-20:#005a87}body.admin-color-light{--wp-admin-theme-color:#0085ba;--wp-admin-theme-color-darker-10:#0073a1;--wp-admin-theme-color-darker-20:#006187}body.admin-color-modern{--wp-admin-theme-color:#3858e9;--wp-admin-theme-color-darker-10:#2145e6;--wp-admin-theme-color-darker-20:#183ad6}body.admin-color-blue{--wp-admin-theme-color:#096484;--wp-admin-theme-color-darker-10:#07526c;--wp-admin-theme-color-darker-20:#064054}body.admin-color-coffee{--wp-admin-theme-color:#46403c;--wp-admin-theme-color-darker-10:#383330;--wp-admin-theme-color-darker-20:#2b2724}body.admin-color-ectoplasm{--wp-admin-theme-color:#523f6d;--wp-admin-theme-color-darker-10:#46365d;--wp-admin-theme-color-darker-20:#3a2c4d}body.admin-color-midnight{--wp-admin-theme-color:#e14d43;--wp-admin-theme-color-darker-10:#dd382d;--wp-admin-theme-color-darker-20:#d02c21}body.admin-color-ocean{--wp-admin-theme-color:#627c83;--wp-admin-theme-color-darker-10:#576e74;--wp-admin-theme-color-darker-20:#4c6066}body.admin-color-sunrise{--wp-admin-theme-color:#dd823b;--wp-admin-theme-color-darker-10:#d97426;--wp-admin-theme-color-darker-20:#c36922}.woocommerce-table__product-categories>.woocommerce-table__breadcrumbs{display:inline-block;margin-left:12px}.woocommerce-table__product-categories .components-popover__content{padding:0 16px;text-align:right}.woocommerce-table__product-categories .components-popover__content .woocommerce-table__breadcrumbs{margin-top:12px;margin-bottom:12px}
|
trunk/dist/analytics-report-stock/style-rtl.css
ADDED
@@ -0,0 +1 @@
|
|
|
1 |
+
:root{--wp-admin-theme-color:#007cba;--wp-admin-theme-color-darker-10:#006ba1;--wp-admin-theme-color-darker-20:#005a87}body.admin-color-light{--wp-admin-theme-color:#0085ba;--wp-admin-theme-color-darker-10:#0073a1;--wp-admin-theme-color-darker-20:#006187}body.admin-color-modern{--wp-admin-theme-color:#3858e9;--wp-admin-theme-color-darker-10:#2145e6;--wp-admin-theme-color-darker-20:#183ad6}body.admin-color-blue{--wp-admin-theme-color:#096484;--wp-admin-theme-color-darker-10:#07526c;--wp-admin-theme-color-darker-20:#064054}body.admin-color-coffee{--wp-admin-theme-color:#46403c;--wp-admin-theme-color-darker-10:#383330;--wp-admin-theme-color-darker-20:#2b2724}body.admin-color-ectoplasm{--wp-admin-theme-color:#523f6d;--wp-admin-theme-color-darker-10:#46365d;--wp-admin-theme-color-darker-20:#3a2c4d}body.admin-color-midnight{--wp-admin-theme-color:#e14d43;--wp-admin-theme-color-darker-10:#dd382d;--wp-admin-theme-color-darker-20:#d02c21}body.admin-color-ocean{--wp-admin-theme-color:#627c83;--wp-admin-theme-color-darker-10:#576e74;--wp-admin-theme-color-darker-20:#4c6066}body.admin-color-sunrise{--wp-admin-theme-color:#dd823b;--wp-admin-theme-color-darker-10:#d97426;--wp-admin-theme-color-darker-20:#c36922}.woocommerce-report-table__scroll-point{position:relative;top:-48px}@media(max-width:782px){.woocommerce-report-table__scroll-point{top:-62px}}.woocommerce-feature-enabled-activity-panels .woocommerce-report-table__scroll-point{top:-108px}@media(max-width:782px){.woocommerce-feature-enabled-activity-panels .woocommerce-report-table__scroll-point{top:-122px}}.woocommerce-report-table .woocommerce-search{flex-grow:1}.woocommerce-report-table .components-card__header{display:grid;grid-gap:12px;grid-template-columns:min-content 1fr min-content}.woocommerce-report-table .woocommerce-table__compare.components-button{padding:8px}.woocommerce-report-table .woocommerce-ellipsis-menu{justify-self:flex-end}button.woocommerce-table__download-button{padding:6px 12px;color:#000;text-decoration:none;align-items:center}button.woocommerce-table__download-button svg{margin-left:8px;height:24px;width:24px}@media(max-width:782px){button.woocommerce-table__download-button svg{margin-left:0}button.woocommerce-table__download-button .woocommerce-table__download-button__label{display:none}}
|
trunk/dist/analytics-report/style-rtl.css
ADDED
@@ -0,0 +1 @@
|
|
|
1 |
+
:root{--wp-admin-theme-color:#007cba;--wp-admin-theme-color-darker-10:#006ba1;--wp-admin-theme-color-darker-20:#005a87}body.admin-color-light{--wp-admin-theme-color:#0085ba;--wp-admin-theme-color-darker-10:#0073a1;--wp-admin-theme-color-darker-20:#006187}body.admin-color-modern{--wp-admin-theme-color:#3858e9;--wp-admin-theme-color-darker-10:#2145e6;--wp-admin-theme-color-darker-20:#183ad6}body.admin-color-blue{--wp-admin-theme-color:#096484;--wp-admin-theme-color-darker-10:#07526c;--wp-admin-theme-color-darker-20:#064054}body.admin-color-coffee{--wp-admin-theme-color:#46403c;--wp-admin-theme-color-darker-10:#383330;--wp-admin-theme-color-darker-20:#2b2724}body.admin-color-ectoplasm{--wp-admin-theme-color:#523f6d;--wp-admin-theme-color-darker-10:#46365d;--wp-admin-theme-color-darker-20:#3a2c4d}body.admin-color-midnight{--wp-admin-theme-color:#e14d43;--wp-admin-theme-color-darker-10:#dd382d;--wp-admin-theme-color-darker-20:#d02c21}body.admin-color-ocean{--wp-admin-theme-color:#627c83;--wp-admin-theme-color-darker-10:#576e74;--wp-admin-theme-color-darker-20:#4c6066}body.admin-color-sunrise{--wp-admin-theme-color:#dd823b;--wp-admin-theme-color-darker-10:#d97426;--wp-admin-theme-color-darker-20:#c36922}.woocommerce-analytics__table-placeholder .woocommerce-card__body{padding:0}.woocommerce-analytics__table-placeholder .woocommerce-table__table{margin-bottom:0}.woocommerce-analytics__table-placeholder .woocommerce-table__table tr:last-child{border-bottom-style:none}
|
trunk/dist/analytics-settings/style-rtl.css
ADDED
@@ -0,0 +1 @@
|
|
|
1 |
+
@media(min-width:783px){.woocommerce-settings__wrapper{padding:0 13px}}.woocommerce-settings__actions{margin-bottom:40px}@media(min-width:1281px){.woocommerce-settings__actions{margin-right:15%}}.woocommerce-settings__actions button{margin-left:16px}.woocommerce-setting{display:flex;margin-bottom:24px}@media(max-width:1280px){.woocommerce-setting{flex-direction:column}}.woocommerce-setting__label{font-size:16px;font-size:1rem;margin-bottom:16px;padding-left:16px;font-weight:700}@media(min-width:1281px){.woocommerce-setting__label{width:15%}}.woocommerce-setting__input{display:flex;flex-direction:column}@media(min-width:1281px){.woocommerce-setting__input{width:35%}.woocommerce-setting__input .woocommerce-filters-filter{width:100%}}.woocommerce-setting__input label{width:100%;display:block;margin-bottom:12px;color:#757575}.woocommerce-setting__input .woocommerce-filters-filter label{margin-bottom:0}.woocommerce-setting__input button:not(.components-tab-panel__tabs-item){margin-bottom:12px;align-self:flex-start}.woocommerce-setting__input .components-base-control__field{display:flex}.woocommerce-setting__input .woocommerce-filters-date__content-controls{padding-bottom:0}.woocommerce-setting__options-group-label{display:block;font-weight:700;margin-bottom:12px}.woocommerce-setting__help{font-style:italic;color:#757575}:root{--wp-admin-theme-color:#007cba;--wp-admin-theme-color-darker-10:#006ba1;--wp-admin-theme-color-darker-20:#005a87}body.admin-color-light{--wp-admin-theme-color:#0085ba;--wp-admin-theme-color-darker-10:#0073a1;--wp-admin-theme-color-darker-20:#006187}body.admin-color-modern{--wp-admin-theme-color:#3858e9;--wp-admin-theme-color-darker-10:#2145e6;--wp-admin-theme-color-darker-20:#183ad6}body.admin-color-blue{--wp-admin-theme-color:#096484;--wp-admin-theme-color-darker-10:#07526c;--wp-admin-theme-color-darker-20:#064054}body.admin-color-coffee{--wp-admin-theme-color:#46403c;--wp-admin-theme-color-darker-10:#383330;--wp-admin-theme-color-darker-20:#2b2724}body.admin-color-ectoplasm{--wp-admin-theme-color:#523f6d;--wp-admin-theme-color-darker-10:#46365d;--wp-admin-theme-color-darker-20:#3a2c4d}body.admin-color-midnight{--wp-admin-theme-color:#e14d43;--wp-admin-theme-color-darker-10:#dd382d;--wp-admin-theme-color-darker-20:#d02c21}body.admin-color-ocean{--wp-admin-theme-color:#627c83;--wp-admin-theme-color-darker-10:#576e74;--wp-admin-theme-color-darker-20:#4c6066}body.admin-color-sunrise{--wp-admin-theme-color:#dd823b;--wp-admin-theme-color-darker-10:#d97426;--wp-admin-theme-color-darker-20:#c36922}.woocommerce-settings-historical-data__columns{display:grid;grid-column-gap:24px;grid-template-columns:calc(50% - 12px) calc(50% - 12px)}.woocommerce-settings-historical-data__columns .woocommerce-settings-historical-data__column{align-self:end;margin-top:12px}.woocommerce-settings-historical-data__columns .woocommerce-settings-historical-data__column:first-child{grid-column-start:1;grid-column-end:2;grid-row-start:1;grid-row-end:2}.woocommerce-settings-historical-data__columns .woocommerce-settings-historical-data__column:nth-child(2){grid-column-start:2;grid-column-end:3;grid-row-start:1;grid-row-end:2}@media(max-width:960px){.woocommerce-settings-historical-data__columns{grid-template-columns:100%}.woocommerce-settings-historical-data__columns .woocommerce-settings-historical-data__column:first-child{grid-column-start:1;grid-column-end:2;grid-row-start:1;grid-row-end:2}.woocommerce-settings-historical-data__columns .woocommerce-settings-historical-data__column:nth-child(2){grid-column-start:1;grid-column-end:2;grid-row-start:2;grid-row-end:3}}.woocommerce-settings-historical-data__columns .components-base-control__label,.woocommerce-settings-historical-data__columns .woocommerce-settings-historical-data__column-label{margin-bottom:12px}.woocommerce-settings-historical-data__columns .components-select-control__input{height:38px;padding:8px 2px}.woocommerce-settings-historical-data__columns .components-base-control__field{margin-bottom:0}.woocommerce-settings-historical-data__skip-checkbox{margin-top:24px}.woocommerce-settings-historical-data__skip-checkbox>.components-base-control__field{margin-bottom:0}.woocommerce-settings-historical-data__skip-checkbox>.components-base-control__field>.components-checkbox-control__label{display:inline-block;margin-bottom:0;width:auto}.woocommerce-settings-historical-data__progress-label{display:inline-block;font-weight:700;margin-bottom:12px;margin-top:24px}.woocommerce-settings-historical-data__progress-label+.woocommerce-settings-historical-data__progress-label{margin-right:.25em}.woocommerce-settings-historical-data__progress-bar{-webkit-appearance:none;appearance:none;border:0;height:8px;width:100%;background-color:#c4c4c4}.woocommerce-settings-historical-data__progress-bar::-moz-progress-bar{background-color:#0085ba}.woocommerce-settings-historical-data__progress-bar::-webkit-progress-bar{background-color:#c4c4c4}.woocommerce-settings-historical-data__progress-bar::-webkit-progress-value{background-color:#0085ba}.woocommerce-settings-historical-data__status{display:block;font-weight:700;margin-top:24px}.woocommerce-settings-historical-data__status>.components-spinner{float:none;height:12px;margin-right:6px;margin-left:6px;width:12px}.woocommerce-settings-historical-data__status>.components-spinner:before{right:2px;height:3px;top:2px;transform-origin:4px 4px;width:3px}.woocommerce-settings-historical-data__actions{align-items:center;display:flex}
|
trunk/dist/app/index.js
ADDED
@@ -0,0 +1,13091 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|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
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
this["wc"] = this["wc"] || {}; this["wc"]["app"] =
|
2 |
+
/******/ (function(modules) { // webpackBootstrap
|
3 |
+
/******/ // install a JSONP callback for chunk loading
|
4 |
+
/******/ function webpackJsonpCallback(data) {
|
5 |
+
/******/ var chunkIds = data[0];
|
6 |
+
/******/ var moreModules = data[1];
|
7 |
+
/******/
|
8 |
+
/******/
|
9 |
+
/******/ // add "moreModules" to the modules object,
|
10 |
+
/******/ // then flag all "chunkIds" as loaded and fire callback
|
11 |
+
/******/ var moduleId, chunkId, i = 0, resolves = [];
|
12 |
+
/******/ for(;i < chunkIds.length; i++) {
|
13 |
+
/******/ chunkId = chunkIds[i];
|
14 |
+
/******/ if(Object.prototype.hasOwnProperty.call(installedChunks, chunkId) && installedChunks[chunkId]) {
|
15 |
+
/******/ resolves.push(installedChunks[chunkId][0]);
|
16 |
+
/******/ }
|
17 |
+
/******/ installedChunks[chunkId] = 0;
|
18 |
+
/******/ }
|
19 |
+
/******/ for(moduleId in moreModules) {
|
20 |
+
/******/ if(Object.prototype.hasOwnProperty.call(moreModules, moduleId)) {
|
21 |
+
/******/ modules[moduleId] = moreModules[moduleId];
|
22 |
+
/******/ }
|
23 |
+
/******/ }
|
24 |
+
/******/ if(parentJsonpFunction) parentJsonpFunction(data);
|
25 |
+
/******/
|
26 |
+
/******/ while(resolves.length) {
|
27 |
+
/******/ resolves.shift()();
|
28 |
+
/******/ }
|
29 |
+
/******/
|
30 |
+
/******/ };
|
31 |
+
/******/
|
32 |
+
/******/
|
33 |
+
/******/ // The module cache
|
34 |
+
/******/ var installedModules = {};
|
35 |
+
/******/
|
36 |
+
/******/ // object to store loaded CSS chunks
|
37 |
+
/******/ var installedCssChunks = {
|
38 |
+
/******/ 17: 0
|
39 |
+
/******/ }
|
40 |
+
/******/ var isCssRtlEnabled = function() {
|
41 |
+
/******/ return document.dir === 'rtl';
|
42 |
+
/******/ }
|
43 |
+
/******/
|
44 |
+
/******/ // object to store loaded and loading chunks
|
45 |
+
/******/ // undefined = chunk not loaded, null = chunk preloaded/prefetched
|
46 |
+
/******/ // Promise = chunk loading, 0 = chunk loaded
|
47 |
+
/******/ var installedChunks = {
|
48 |
+
/******/ 17: 0
|
49 |
+
/******/ };
|
50 |
+
/******/
|
51 |
+
/******/
|
52 |
+
/******/
|
53 |
+
/******/ // script path function
|
54 |
+
/******/ function webpackJsonpScriptSrc(chunkId) {
|
55 |
+
/******/ return __webpack_require__.p + "chunks/" + ({"3":"activity-panels-help","4":"activity-panels-inbox","5":"analytics-report","6":"analytics-report-categories","7":"analytics-report-coupons","8":"analytics-report-customers","9":"analytics-report-downloads","10":"analytics-report-orders","11":"analytics-report-products","12":"analytics-report-revenue","13":"analytics-report-stock","14":"analytics-report-taxes","15":"analytics-report-variations","16":"analytics-settings","23":"customizable-dashboard","24":"dashboard","25":"dashboard-charts","30":"homescreen","31":"leaderboards","33":"marketing-overview","44":"payment-recommendations","46":"profile-wizard","47":"shipping-recommendations","48":"store-alerts","49":"store-performance","51":"two-column-tasks","52":"two-column-tasks-extended","53":"wcpay-usage-modal"}[chunkId]||chunkId) + ".js"
|
56 |
+
/******/ }
|
57 |
+
/******/
|
58 |
+
/******/ function jsonpScriptSrc(chunkId) {
|
59 |
+
/******/ var src = webpackJsonpScriptSrc(chunkId);
|
60 |
+
/******/ if ( window.wcAdminAssets && window.wcAdminAssets.version ) {
|
61 |
+
/******/ src += '?ver=' + window.wcAdminAssets.version;
|
62 |
+
/******/ }
|
63 |
+
/******/ return src;
|
64 |
+
/******/ }
|
65 |
+
/******/
|
66 |
+
/******/
|
67 |
+
/******/ // The require function
|
68 |
+
/******/ function __webpack_require__(moduleId) {
|
69 |
+
/******/
|
70 |
+
/******/ // Check if module is in cache
|
71 |
+
/******/ if(installedModules[moduleId]) {
|
72 |
+
/******/ return installedModules[moduleId].exports;
|
73 |
+
/******/ }
|
74 |
+
/******/ // Create a new module (and put it into the cache)
|
75 |
+
/******/ var module = installedModules[moduleId] = {
|
76 |
+
/******/ i: moduleId,
|
77 |
+
/******/ l: false,
|
78 |
+
/******/ exports: {}
|
79 |
+
/******/ };
|
80 |
+
/******/
|
81 |
+
/******/ // Execute the module function
|
82 |
+
/******/ modules[moduleId].call(module.exports, module, module.exports, __webpack_require__);
|
83 |
+
/******/
|
84 |
+
/******/ // Flag the module as loaded
|
85 |
+
/******/ module.l = true;
|
86 |
+
/******/
|
87 |
+
/******/ // Return the exports of the module
|
88 |
+
/******/ return module.exports;
|
89 |
+
/******/ }
|
90 |
+
/******/
|
91 |
+
/******/ // This file contains only the entry chunk.
|
92 |
+
/******/ // The chunk loading function for additional chunks
|
93 |
+
/******/ __webpack_require__.e = function requireEnsure(chunkId) {
|
94 |
+
/******/ var promises = [];
|
95 |
+
/******/
|
96 |
+
/******/
|
97 |
+
/******/ // mini-css-extract-plugin CSS loading
|
98 |
+
/******/ var cssChunks = {"0":1,"3":1,"4":1,"5":1,"6":1,"8":1,"10":1,"11":1,"13":1,"16":1,"24":1,"25":1,"30":1,"31":1,"33":1,"44":1,"46":1,"47":1,"48":1,"49":1,"51":1};
|
99 |
+
/******/ if(installedCssChunks[chunkId]) promises.push(installedCssChunks[chunkId]);
|
100 |
+
/******/ else if(installedCssChunks[chunkId] !== 0 && cssChunks[chunkId]) {
|
101 |
+
/******/ promises.push(installedCssChunks[chunkId] = new Promise(function(resolve, reject) {
|
102 |
+
/******/ var href = false && isCssRtlEnabled() ? undefined : "chunks/" + chunkId + ".style.css";
|
103 |
+
/******/ var fullhref = __webpack_require__.p + href;
|
104 |
+
/******/ var existingLinkTags = document.getElementsByTagName("link");
|
105 |
+
/******/ for(var i = 0; i < existingLinkTags.length; i++) {
|
106 |
+
/******/ var tag = existingLinkTags[i];
|
107 |
+
/******/ var dataHref = tag.getAttribute("data-href") || tag.getAttribute("href");
|
108 |
+
/******/ if(tag.rel === "stylesheet" && (dataHref === href || dataHref === fullhref)) return resolve();
|
109 |
+
/******/ }
|
110 |
+
/******/ var existingStyleTags = document.getElementsByTagName("style");
|
111 |
+
/******/ for(var i = 0; i < existingStyleTags.length; i++) {
|
112 |
+
/******/ var tag = existingStyleTags[i];
|
113 |
+
/******/ var dataHref = tag.getAttribute("data-href");
|
114 |
+
/******/ if(dataHref === href || dataHref === fullhref) return resolve();
|
115 |
+
/******/ }
|
116 |
+
/******/ var linkTag = document.createElement("link");
|
117 |
+
/******/ linkTag.rel = "stylesheet";
|
118 |
+
/******/ linkTag.type = "text/css";
|
119 |
+
/******/ linkTag.setAttribute("data-webpack", true);
|
120 |
+
/******/ linkTag.onload = resolve;
|
121 |
+
/******/ linkTag.onerror = function(event) {
|
122 |
+
/******/ var request = event && event.target && event.target.src || fullhref;
|
123 |
+
/******/ var err = new Error("Loading CSS chunk " + chunkId + " failed.\n(" + request + ")");
|
124 |
+
/******/ err.code = "CSS_CHUNK_LOAD_FAILED";
|
125 |
+
/******/ err.request = request;
|
126 |
+
/******/ delete installedCssChunks[chunkId]
|
127 |
+
/******/ linkTag.parentNode.removeChild(linkTag)
|
128 |
+
/******/ reject(err);
|
129 |
+
/******/ };
|
130 |
+
/******/ linkTag.href = fullhref;
|
131 |
+
/******/ if ( window.wcAdminAssets && window.wcAdminAssets.version ) {
|
132 |
+
/******/ linkTag.href += '?ver=' + window.wcAdminAssets.version;
|
133 |
+
/******/ }
|
134 |
+
/******/
|
135 |
+
/******/ var head = document.getElementsByTagName("head")[0];
|
136 |
+
/******/ head.appendChild(linkTag);
|
137 |
+
/******/ }).then(function() {
|
138 |
+
/******/ installedCssChunks[chunkId] = 0;
|
139 |
+
/******/ }));
|
140 |
+
/******/ }
|
141 |
+
/******/
|
142 |
+
/******/ // JSONP chunk loading for javascript
|
143 |
+
/******/
|
144 |
+
/******/ var installedChunkData = installedChunks[chunkId];
|
145 |
+
/******/ if(installedChunkData !== 0) { // 0 means "already installed".
|
146 |
+
/******/
|
147 |
+
/******/ // a Promise means "currently loading".
|
148 |
+
/******/ if(installedChunkData) {
|
149 |
+
/******/ promises.push(installedChunkData[2]);
|
150 |
+
/******/ } else {
|
151 |
+
/******/ // setup Promise in chunk cache
|
152 |
+
/******/ var promise = new Promise(function(resolve, reject) {
|
153 |
+
/******/ installedChunkData = installedChunks[chunkId] = [resolve, reject];
|
154 |
+
/******/ });
|
155 |
+
/******/ promises.push(installedChunkData[2] = promise);
|
156 |
+
/******/
|
157 |
+
/******/ // start chunk loading
|
158 |
+
/******/ var script = document.createElement('script');
|
159 |
+
/******/ var onScriptComplete;
|
160 |
+
/******/
|
161 |
+
/******/ script.charset = 'utf-8';
|
162 |
+
/******/ script.timeout = 120;
|
163 |
+
/******/ if (__webpack_require__.nc) {
|
164 |
+
/******/ script.setAttribute("nonce", __webpack_require__.nc);
|
165 |
+
/******/ }
|
166 |
+
/******/ script.src = jsonpScriptSrc(chunkId);
|
167 |
+
/******/
|
168 |
+
/******/ // create error before stack unwound to get useful stacktrace later
|
169 |
+
/******/ var error = new Error();
|
170 |
+
/******/ onScriptComplete = function (event) {
|
171 |
+
/******/ // avoid mem leaks in IE.
|
172 |
+
/******/ script.onerror = script.onload = null;
|
173 |
+
/******/ clearTimeout(timeout);
|
174 |
+
/******/ var chunk = installedChunks[chunkId];
|
175 |
+
/******/ if(chunk !== 0) {
|
176 |
+
/******/ if(chunk) {
|
177 |
+
/******/ var errorType = event && (event.type === 'load' ? 'missing' : event.type);
|
178 |
+
/******/ var realSrc = event && event.target && event.target.src;
|
179 |
+
/******/ error.message = 'Loading chunk ' + chunkId + ' failed.\n(' + errorType + ': ' + realSrc + ')';
|
180 |
+
/******/ error.name = 'ChunkLoadError';
|
181 |
+
/******/ error.type = errorType;
|
182 |
+
/******/ error.request = realSrc;
|
183 |
+
/******/ chunk[1](error);
|
184 |
+
/******/ }
|
185 |
+
/******/ installedChunks[chunkId] = undefined;
|
186 |
+
/******/ }
|
187 |
+
/******/ };
|
188 |
+
/******/ var timeout = setTimeout(function(){
|
189 |
+
/******/ onScriptComplete({ type: 'timeout', target: script });
|
190 |
+
/******/ }, 120000);
|
191 |
+
/******/ script.onerror = script.onload = onScriptComplete;
|
192 |
+
/******/ document.head.appendChild(script);
|
193 |
+
/******/ }
|
194 |
+
/******/ }
|
195 |
+
/******/ return Promise.all(promises);
|
196 |
+
/******/ };
|
197 |
+
/******/
|
198 |
+
/******/ // expose the modules object (__webpack_modules__)
|
199 |
+
/******/ __webpack_require__.m = modules;
|
200 |
+
/******/
|
201 |
+
/******/ // expose the module cache
|
202 |
+
/******/ __webpack_require__.c = installedModules;
|
203 |
+
/******/
|
204 |
+
/******/ // define getter function for harmony exports
|
205 |
+
/******/ __webpack_require__.d = function(exports, name, getter) {
|
206 |
+
/******/ if(!__webpack_require__.o(exports, name)) {
|
207 |
+
/******/ Object.defineProperty(exports, name, { enumerable: true, get: getter });
|
208 |
+
/******/ }
|
209 |
+
/******/ };
|
210 |
+
/******/
|
211 |
+
/******/ // define __esModule on exports
|
212 |
+
/******/ __webpack_require__.r = function(exports) {
|
213 |
+
/******/ if(typeof Symbol !== 'undefined' && Symbol.toStringTag) {
|
214 |
+
/******/ Object.defineProperty(exports, Symbol.toStringTag, { value: 'Module' });
|
215 |
+
/******/ }
|
216 |
+
/******/ Object.defineProperty(exports, '__esModule', { value: true });
|
217 |
+
/******/ };
|
218 |
+
/******/
|
219 |
+
/******/ // create a fake namespace object
|
220 |
+
/******/ // mode & 1: value is a module id, require it
|
221 |
+
/******/ // mode & 2: merge all properties of value into the ns
|
222 |
+
/******/ // mode & 4: return value when already ns object
|
223 |
+
/******/ // mode & 8|1: behave like require
|
224 |
+
/******/ __webpack_require__.t = function(value, mode) {
|
225 |
+
/******/ if(mode & 1) value = __webpack_require__(value);
|
226 |
+
/******/ if(mode & 8) return value;
|
227 |
+
/******/ if((mode & 4) && typeof value === 'object' && value && value.__esModule) return value;
|
228 |
+
/******/ var ns = Object.create(null);
|
229 |
+
/******/ __webpack_require__.r(ns);
|
230 |
+
/******/ Object.defineProperty(ns, 'default', { enumerable: true, value: value });
|
231 |
+
/******/ if(mode & 2 && typeof value != 'string') for(var key in value) __webpack_require__.d(ns, key, function(key) { return value[key]; }.bind(null, key));
|
232 |
+
/******/ return ns;
|
233 |
+
/******/ };
|
234 |
+
/******/
|
235 |
+
/******/ // getDefaultExport function for compatibility with non-harmony modules
|
236 |
+
/******/ __webpack_require__.n = function(module) {
|
237 |
+
/******/ var getter = module && module.__esModule ?
|
238 |
+
/******/ function getDefault() { return module['default']; } :
|
239 |
+
/******/ function getModuleExports() { return module; };
|
240 |
+
/******/ __webpack_require__.d(getter, 'a', getter);
|
241 |
+
/******/ return getter;
|
242 |
+
/******/ };
|
243 |
+
/******/
|
244 |
+
/******/ // Object.prototype.hasOwnProperty.call
|
245 |
+
/******/ __webpack_require__.o = function(object, property) { return Object.prototype.hasOwnProperty.call(object, property); };
|
246 |
+
/******/
|
247 |
+
/******/ // __webpack_public_path__
|
248 |
+
/******/ __webpack_require__.p = "";
|
249 |
+
/******/
|
250 |
+
/******/ // on error function for async loading
|
251 |
+
/******/ __webpack_require__.oe = function(err) { console.error(err); throw err; };
|
252 |
+
/******/
|
253 |
+
/******/ var jsonpArray = window["__wcAdmin_webpackJsonp"] = window["__wcAdmin_webpackJsonp"] || [];
|
254 |
+
/******/ var oldJsonpFunction = jsonpArray.push.bind(jsonpArray);
|
255 |
+
/******/ jsonpArray.push = webpackJsonpCallback;
|
256 |
+
/******/ jsonpArray = jsonpArray.slice();
|
257 |
+
/******/ for(var i = 0; i < jsonpArray.length; i++) webpackJsonpCallback(jsonpArray[i]);
|
258 |
+
/******/ var parentJsonpFunction = oldJsonpFunction;
|
259 |
+
/******/
|
260 |
+
/******/
|
261 |
+
/******/ // Load entry module and return exports
|
262 |
+
/******/ return __webpack_require__(__webpack_require__.s = 281);
|
263 |
+
/******/ })
|
264 |
+
/************************************************************************/
|
265 |
+
/******/ ({
|
266 |
+
|
267 |
+
/***/ 0:
|
268 |
+
/***/ (function(module, exports) {
|
269 |
+
|
270 |
+
(function() { module.exports = window["wp"]["element"]; }());
|
271 |
+
|
272 |
+
/***/ }),
|
273 |
+
|
274 |
+
/***/ 1:
|
275 |
+
/***/ (function(module, exports, __webpack_require__) {
|
276 |
+
|
277 |
+
/**
|
278 |
+
* Copyright (c) 2013-present, Facebook, Inc.
|
279 |
+
*
|
280 |
+
* This source code is licensed under the MIT license found in the
|
281 |
+
* LICENSE file in the root directory of this source tree.
|
282 |
+
*/
|
283 |
+
|
284 |
+
if (false) { var throwOnDirectAccess, ReactIs; } else {
|
285 |
+
// By explicitly using `prop-types` you are opting into new production behavior.
|
286 |
+
// http://fb.me/prop-types-in-prod
|
287 |
+
module.exports = __webpack_require__(48)();
|
288 |
+
}
|
289 |
+
|
290 |
+
|
291 |
+
/***/ }),
|
292 |
+
|
293 |
+
/***/ 10:
|
294 |
+
/***/ (function(module, exports) {
|
295 |
+
|
296 |
+
(function() { module.exports = window["wp"]["dataControls"]; }());
|
297 |
+
|
298 |
+
/***/ }),
|
299 |
+
|
300 |
+
/***/ 101:
|
301 |
+
/***/ (function(module, exports, __webpack_require__) {
|
302 |
+
|
303 |
+
"use strict";
|
304 |
+
var _extends=Object.assign||function(a){for(var c,b=1;b<arguments.length;b++)for(var d in c=arguments[b],c)Object.prototype.hasOwnProperty.call(c,d)&&(a[d]=c[d]);return a};Object.defineProperty(exports,'__esModule',{value:!0});exports.default=function(a){var b=a.size,c=b===void 0?24:b,d=a.onClick,e=a.icon,f=a.className,g=_objectWithoutProperties(a,['size','onClick','icon','className']),j=['gridicon','gridicons-cross-small',f,!1,!1,!1].filter(Boolean).join(' ');return _react2.default.createElement('svg',_extends({className:j,height:c,width:c,onClick:d},g,{xmlns:'http://www.w3.org/2000/svg',viewBox:'0 0 24 24'}),_react2.default.createElement('g',null,_react2.default.createElement('path',{d:'M17.705 7.705l-1.41-1.41L12 10.59 7.705 6.295l-1.41 1.41L10.59 12l-4.295 4.295 1.41 1.41L12 13.41l4.295 4.295 1.41-1.41L13.41 12l4.295-4.295z'})))};var _react=__webpack_require__(5),_react2=_interopRequireDefault(_react);function _interopRequireDefault(a){return a&&a.__esModule?a:{default:a}}function _objectWithoutProperties(a,b){var d={};for(var c in a)0<=b.indexOf(c)||Object.prototype.hasOwnProperty.call(a,c)&&(d[c]=a[c]);return d}module.exports=exports['default'];
|
305 |
+
|
306 |
+
|
307 |
+
/***/ }),
|
308 |
+
|
309 |
+
/***/ 103:
|
310 |
+
/***/ (function(module, __webpack_exports__, __webpack_require__) {
|
311 |
+
|
312 |
+
"use strict";
|
313 |
+
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "a", function() { return REVIEW_PAGE_LIMIT; });
|
314 |
+
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "c", function() { return unapprovedReviewsQuery; });
|
315 |
+
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "b", function() { return getUnapprovedReviews; });
|
316 |
+
/* harmony import */ var _woocommerce_data__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(11);
|
317 |
+
/* harmony import */ var _woocommerce_data__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(_woocommerce_data__WEBPACK_IMPORTED_MODULE_0__);
|
318 |
+
/**
|
319 |
+
* External dependencies
|
320 |
+
*/
|
321 |
+
|
322 |
+
const REVIEW_PAGE_LIMIT = 5;
|
323 |
+
const unapprovedReviewsQuery = {
|
324 |
+
page: 1,
|
325 |
+
per_page: 1,
|
326 |
+
status: 'hold',
|
327 |
+
_embed: 1,
|
328 |
+
_fields: ['id']
|
329 |
+
};
|
330 |
+
function getUnapprovedReviews(select) {
|
331 |
+
const {
|
332 |
+
getReviewsTotalCount,
|
333 |
+
getReviewsError,
|
334 |
+
isResolving
|
335 |
+
} = select(_woocommerce_data__WEBPACK_IMPORTED_MODULE_0__["REVIEWS_STORE_NAME"]); // eslint-disable-next-line @wordpress/no-unused-vars-before-return
|
336 |
+
|
337 |
+
const totalReviews = getReviewsTotalCount(unapprovedReviewsQuery);
|
338 |
+
const isError = Boolean(getReviewsError(unapprovedReviewsQuery));
|
339 |
+
const isRequesting = isResolving('getReviewsTotalCount', [unapprovedReviewsQuery]);
|
340 |
+
|
341 |
+
if (isError || isRequesting && totalReviews === undefined) {
|
342 |
+
return null;
|
343 |
+
}
|
344 |
+
|
345 |
+
return totalReviews;
|
346 |
+
}
|
347 |
+
|
348 |
+
/***/ }),
|
349 |
+
|
350 |
+
/***/ 104:
|
351 |
+
/***/ (function(module, exports, __webpack_require__) {
|
352 |
+
|
353 |
+
"use strict";
|
354 |
+
|
355 |
+
|
356 |
+
if (true) {
|
357 |
+
module.exports = __webpack_require__(129);
|
358 |
+
} else {}
|
359 |
+
|
360 |
+
|
361 |
+
/***/ }),
|
362 |
+
|
363 |
+
/***/ 11:
|
364 |
+
/***/ (function(module, exports) {
|
365 |
+
|
366 |
+
(function() { module.exports = window["wc"]["data"]; }());
|
367 |
+
|
368 |
+
/***/ }),
|
369 |
+
|
370 |
+
/***/ 116:
|
371 |
+
/***/ (function(module, __webpack_exports__, __webpack_require__) {
|
372 |
+
|
373 |
+
"use strict";
|
374 |
+
|
375 |
+
// CONCATENATED MODULE: ./node_modules/@babel/runtime/helpers/esm/defineProperty.js
|
376 |
+
function _defineProperty(obj, key, value) {
|
377 |
+
if (key in obj) {
|
378 |
+
Object.defineProperty(obj, key, {
|
379 |
+
value: value,
|
380 |
+
enumerable: true,
|
381 |
+
configurable: true,
|
382 |
+
writable: true
|
383 |
+
});
|
384 |
+
} else {
|
385 |
+
obj[key] = value;
|
386 |
+
}
|
387 |
+
|
388 |
+
return obj;
|
389 |
+
}
|
390 |
+
// EXTERNAL MODULE: ./node_modules/@babel/runtime/helpers/esm/objectWithoutPropertiesLoose.js
|
391 |
+
var objectWithoutPropertiesLoose = __webpack_require__(22);
|
392 |
+
|
393 |
+
// CONCATENATED MODULE: ./node_modules/@babel/runtime/helpers/esm/objectWithoutProperties.js
|
394 |
+
|
395 |
+
function _objectWithoutProperties(source, excluded) {
|
396 |
+
if (source == null) return {};
|
397 |
+
var target = Object(objectWithoutPropertiesLoose["a" /* default */])(source, excluded);
|
398 |
+
var key, i;
|
399 |
+
|
400 |
+
if (Object.getOwnPropertySymbols) {
|
401 |
+
var sourceSymbolKeys = Object.getOwnPropertySymbols(source);
|
402 |
+
|
403 |
+
for (i = 0; i < sourceSymbolKeys.length; i++) {
|
404 |
+
key = sourceSymbolKeys[i];
|
405 |
+
if (excluded.indexOf(key) >= 0) continue;
|
406 |
+
if (!Object.prototype.propertyIsEnumerable.call(source, key)) continue;
|
407 |
+
target[key] = source[key];
|
408 |
+
}
|
409 |
+
}
|
410 |
+
|
411 |
+
return target;
|
412 |
+
}
|
413 |
+
// EXTERNAL MODULE: external ["wp","element"]
|
414 |
+
var external_wp_element_ = __webpack_require__(0);
|
415 |
+
|
416 |
+
// CONCATENATED MODULE: ./node_modules/@wordpress/icons/build-module/icon/index.js
|
417 |
+
|
418 |
+
|
419 |
+
|
420 |
+
function ownKeys(object, enumerableOnly) { var keys = Object.keys(object); if (Object.getOwnPropertySymbols) { var symbols = Object.getOwnPropertySymbols(object); if (enumerableOnly) symbols = symbols.filter(function (sym) { return Object.getOwnPropertyDescriptor(object, sym).enumerable; }); keys.push.apply(keys, symbols); } return keys; }
|
421 |
+
|
422 |
+
function _objectSpread(target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i] != null ? arguments[i] : {}; if (i % 2) { ownKeys(Object(source), true).forEach(function (key) { _defineProperty(target, key, source[key]); }); } else if (Object.getOwnPropertyDescriptors) { Object.defineProperties(target, Object.getOwnPropertyDescriptors(source)); } else { ownKeys(Object(source)).forEach(function (key) { Object.defineProperty(target, key, Object.getOwnPropertyDescriptor(source, key)); }); } } return target; }
|
423 |
+
|
424 |
+
/**
|
425 |
+
* WordPress dependencies
|
426 |
+
*/
|
427 |
+
|
428 |
+
/** @typedef {{icon: JSX.Element, size?: number} & import('@wordpress/primitives').SVGProps} IconProps */
|
429 |
+
|
430 |
+
/**
|
431 |
+
* Return an SVG icon.
|
432 |
+
*
|
433 |
+
* @param {IconProps} props icon is the SVG component to render
|
434 |
+
* size is a number specifiying the icon size in pixels
|
435 |
+
* Other props will be passed to wrapped SVG component
|
436 |
+
*
|
437 |
+
* @return {JSX.Element} Icon component
|
438 |
+
*/
|
439 |
+
|
440 |
+
function Icon(_ref) {
|
441 |
+
var icon = _ref.icon,
|
442 |
+
_ref$size = _ref.size,
|
443 |
+
size = _ref$size === void 0 ? 24 : _ref$size,
|
444 |
+
props = _objectWithoutProperties(_ref, ["icon", "size"]);
|
445 |
+
|
446 |
+
return Object(external_wp_element_["cloneElement"])(icon, _objectSpread({
|
447 |
+
width: size,
|
448 |
+
height: size
|
449 |
+
}, props));
|
450 |
+
}
|
451 |
+
|
452 |
+
/* harmony default export */ var build_module_icon = __webpack_exports__["a"] = (Icon);
|
453 |
+
//# sourceMappingURL=index.js.map
|
454 |
+
|
455 |
+
/***/ }),
|
456 |
+
|
457 |
+
/***/ 117:
|
458 |
+
/***/ (function(module, __webpack_exports__, __webpack_require__) {
|
459 |
+
|
460 |
+
"use strict";
|
461 |
+
/* harmony import */ var _wordpress_i18n__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(2);
|
462 |
+
/* harmony import */ var _wordpress_i18n__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(_wordpress_i18n__WEBPACK_IMPORTED_MODULE_0__);
|
463 |
+
/* harmony import */ var _wordpress_hooks__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(31);
|
464 |
+
/* harmony import */ var _wordpress_hooks__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(_wordpress_hooks__WEBPACK_IMPORTED_MODULE_1__);
|
465 |
+
/* harmony import */ var _woocommerce_wc_admin_settings__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(13);
|
466 |
+
/* harmony import */ var _wordpress_element__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(0);
|
467 |
+
/* harmony import */ var _wordpress_element__WEBPACK_IMPORTED_MODULE_3___default = /*#__PURE__*/__webpack_require__.n(_wordpress_element__WEBPACK_IMPORTED_MODULE_3__);
|
468 |
+
/**
|
469 |
+
* External dependencies
|
470 |
+
*/
|
471 |
+
|
472 |
+
|
473 |
+
|
474 |
+
|
475 |
+
const manageStock = Object(_woocommerce_wc_admin_settings__WEBPACK_IMPORTED_MODULE_2__[/* getSetting */ "f"])('manageStock', 'no');
|
476 |
+
const REPORTS_FILTER = 'woocommerce_admin_reports_list';
|
477 |
+
/**
|
478 |
+
* Internal dependencies
|
479 |
+
*/
|
480 |
+
|
481 |
+
const RevenueReport = Object(_wordpress_element__WEBPACK_IMPORTED_MODULE_3__["lazy"])(() => Promise.all(/* import() | analytics-report-revenue */[__webpack_require__.e(0), __webpack_require__.e(12)]).then(__webpack_require__.bind(null, 483)));
|
482 |
+
const ProductsReport = Object(_wordpress_element__WEBPACK_IMPORTED_MODULE_3__["lazy"])(() => Promise.all(/* import() | analytics-report-products */[__webpack_require__.e(0), __webpack_require__.e(11)]).then(__webpack_require__.bind(null, 479)));
|
483 |
+
const VariationsReport = Object(_wordpress_element__WEBPACK_IMPORTED_MODULE_3__["lazy"])(() => Promise.all(/* import() | analytics-report-variations */[__webpack_require__.e(0), __webpack_require__.e(15)]).then(__webpack_require__.bind(null, 484)));
|
484 |
+
const OrdersReport = Object(_wordpress_element__WEBPACK_IMPORTED_MODULE_3__["lazy"])(() => Promise.all(/* import() | analytics-report-orders */[__webpack_require__.e(0), __webpack_require__.e(10)]).then(__webpack_require__.bind(null, 485)));
|
485 |
+
const CategoriesReport = Object(_wordpress_element__WEBPACK_IMPORTED_MODULE_3__["lazy"])(() => Promise.all(/* import() | analytics-report-categories */[__webpack_require__.e(0), __webpack_require__.e(6)]).then(__webpack_require__.bind(null, 481)));
|
486 |
+
const CouponsReport = Object(_wordpress_element__WEBPACK_IMPORTED_MODULE_3__["lazy"])(() => Promise.all(/* import() | analytics-report-coupons */[__webpack_require__.e(0), __webpack_require__.e(7)]).then(__webpack_require__.bind(null, 486)));
|
487 |
+
const TaxesReport = Object(_wordpress_element__WEBPACK_IMPORTED_MODULE_3__["lazy"])(() => Promise.all(/* import() | analytics-report-taxes */[__webpack_require__.e(0), __webpack_require__.e(14)]).then(__webpack_require__.bind(null, 487)));
|
488 |
+
const DownloadsReport = Object(_wordpress_element__WEBPACK_IMPORTED_MODULE_3__["lazy"])(() => Promise.all(/* import() | analytics-report-downloads */[__webpack_require__.e(0), __webpack_require__.e(9)]).then(__webpack_require__.bind(null, 488)));
|
489 |
+
const StockReport = Object(_wordpress_element__WEBPACK_IMPORTED_MODULE_3__["lazy"])(() => __webpack_require__.e(/* import() | analytics-report-stock */ 13).then(__webpack_require__.bind(null, 480)));
|
490 |
+
const CustomersReport = Object(_wordpress_element__WEBPACK_IMPORTED_MODULE_3__["lazy"])(() => __webpack_require__.e(/* import() | analytics-report-customers */ 8).then(__webpack_require__.bind(null, 482)));
|
491 |
+
/* harmony default export */ __webpack_exports__["a"] = (() => {
|
492 |
+
const reports = [{
|
493 |
+
report: 'revenue',
|
494 |
+
title: Object(_wordpress_i18n__WEBPACK_IMPORTED_MODULE_0__["__"])('Revenue', 'woocommerce-admin'),
|
495 |
+
component: RevenueReport,
|
496 |
+
navArgs: {
|
497 |
+
id: 'woocommerce-analytics-revenue'
|
498 |
+
}
|
499 |
+
}, {
|
500 |
+
report: 'products',
|
501 |
+
title: Object(_wordpress_i18n__WEBPACK_IMPORTED_MODULE_0__["__"])('Products', 'woocommerce-admin'),
|
502 |
+
component: ProductsReport,
|
503 |
+
navArgs: {
|
504 |
+
id: 'woocommerce-analytics-products'
|
505 |
+
}
|
506 |
+
}, {
|
507 |
+
report: 'variations',
|
508 |
+
title: Object(_wordpress_i18n__WEBPACK_IMPORTED_MODULE_0__["__"])('Variations', 'woocommerce-admin'),
|
509 |
+
component: VariationsReport,
|
510 |
+
navArgs: {
|
511 |
+
id: 'woocommerce-analytics-variations'
|
512 |
+
}
|
513 |
+
}, {
|
514 |
+
report: 'orders',
|
515 |
+
title: Object(_wordpress_i18n__WEBPACK_IMPORTED_MODULE_0__["__"])('Orders', 'woocommerce-admin'),
|
516 |
+
component: OrdersReport,
|
517 |
+
navArgs: {
|
518 |
+
id: 'woocommerce-analytics-orders'
|
519 |
+
}
|
520 |
+
}, {
|
521 |
+
report: 'categories',
|
522 |
+
title: Object(_wordpress_i18n__WEBPACK_IMPORTED_MODULE_0__["__"])('Categories', 'woocommerce-admin'),
|
523 |
+
component: CategoriesReport,
|
524 |
+
navArgs: {
|
525 |
+
id: 'woocommerce-analytics-categories'
|
526 |
+
}
|
527 |
+
}, {
|
528 |
+
report: 'coupons',
|
529 |
+
title: Object(_wordpress_i18n__WEBPACK_IMPORTED_MODULE_0__["__"])('Coupons', 'woocommerce-admin'),
|
530 |
+
component: CouponsReport,
|
531 |
+
navArgs: {
|
532 |
+
id: 'woocommerce-analytics-coupons'
|
533 |
+
}
|
534 |
+
}, {
|
535 |
+
report: 'taxes',
|
536 |
+
title: Object(_wordpress_i18n__WEBPACK_IMPORTED_MODULE_0__["__"])('Taxes', 'woocommerce-admin'),
|
537 |
+
component: TaxesReport,
|
538 |
+
navArgs: {
|
539 |
+
id: 'woocommerce-analytics-taxes'
|
540 |
+
}
|
541 |
+
}, manageStock === 'yes' ? {
|
542 |
+
report: 'stock',
|
543 |
+
title: Object(_wordpress_i18n__WEBPACK_IMPORTED_MODULE_0__["__"])('Stock', 'woocommerce-admin'),
|
544 |
+
component: StockReport,
|
545 |
+
navArgs: {
|
546 |
+
id: 'woocommerce-analytics-stock'
|
547 |
+
}
|
548 |
+
} : null, {
|
549 |
+
report: 'customers',
|
550 |
+
title: Object(_wordpress_i18n__WEBPACK_IMPORTED_MODULE_0__["__"])('Customers', 'woocommerce-admin'),
|
551 |
+
component: CustomersReport
|
552 |
+
}, {
|
553 |
+
report: 'downloads',
|
554 |
+
title: Object(_wordpress_i18n__WEBPACK_IMPORTED_MODULE_0__["__"])('Downloads', 'woocommerce-admin'),
|
555 |
+
component: DownloadsReport,
|
556 |
+
navArgs: {
|
557 |
+
id: 'woocommerce-analytics-downloads'
|
558 |
+
}
|
559 |
+
}].filter(Boolean);
|
560 |
+
return Object(_wordpress_hooks__WEBPACK_IMPORTED_MODULE_1__["applyFilters"])(REPORTS_FILTER, reports);
|
561 |
+
});
|
562 |
+
|
563 |
+
/***/ }),
|
564 |
+
|
565 |
+
/***/ 118:
|
566 |
+
/***/ (function(module, exports, __webpack_require__) {
|
567 |
+
|
568 |
+
"use strict";
|
569 |
+
|
570 |
+
|
571 |
+
var reactIs = __webpack_require__(104);
|
572 |
+
|
573 |
+
/**
|
574 |
+
* Copyright 2015, Yahoo! Inc.
|
575 |
+
* Copyrights licensed under the New BSD License. See the accompanying LICENSE file for terms.
|
576 |
+
*/
|
577 |
+
var REACT_STATICS = {
|
578 |
+
childContextTypes: true,
|
579 |
+
contextType: true,
|
580 |
+
contextTypes: true,
|
581 |
+
defaultProps: true,
|
582 |
+
displayName: true,
|
583 |
+
getDefaultProps: true,
|
584 |
+
getDerivedStateFromError: true,
|
585 |
+
getDerivedStateFromProps: true,
|
586 |
+
mixins: true,
|
587 |
+
propTypes: true,
|
588 |
+
type: true
|
589 |
+
};
|
590 |
+
var KNOWN_STATICS = {
|
591 |
+
name: true,
|
592 |
+
length: true,
|
593 |
+
prototype: true,
|
594 |
+
caller: true,
|
595 |
+
callee: true,
|
596 |
+
arguments: true,
|
597 |
+
arity: true
|
598 |
+
};
|
599 |
+
var FORWARD_REF_STATICS = {
|
600 |
+
'$$typeof': true,
|
601 |
+
render: true,
|
602 |
+
defaultProps: true,
|
603 |
+
displayName: true,
|
604 |
+
propTypes: true
|
605 |
+
};
|
606 |
+
var MEMO_STATICS = {
|
607 |
+
'$$typeof': true,
|
608 |
+
compare: true,
|
609 |
+
defaultProps: true,
|
610 |
+
displayName: true,
|
611 |
+
propTypes: true,
|
612 |
+
type: true
|
613 |
+
};
|
614 |
+
var TYPE_STATICS = {};
|
615 |
+
TYPE_STATICS[reactIs.ForwardRef] = FORWARD_REF_STATICS;
|
616 |
+
TYPE_STATICS[reactIs.Memo] = MEMO_STATICS;
|
617 |
+
|
618 |
+
function getStatics(component) {
|
619 |
+
// React v16.11 and below
|
620 |
+
if (reactIs.isMemo(component)) {
|
621 |
+
return MEMO_STATICS;
|
622 |
+
} // React v16.12 and above
|
623 |
+
|
624 |
+
|
625 |
+
return TYPE_STATICS[component['$$typeof']] || REACT_STATICS;
|
626 |
+
}
|
627 |
+
|
628 |
+
var defineProperty = Object.defineProperty;
|
629 |
+
var getOwnPropertyNames = Object.getOwnPropertyNames;
|
630 |
+
var getOwnPropertySymbols = Object.getOwnPropertySymbols;
|
631 |
+
var getOwnPropertyDescriptor = Object.getOwnPropertyDescriptor;
|
632 |
+
var getPrototypeOf = Object.getPrototypeOf;
|
633 |
+
var objectPrototype = Object.prototype;
|
634 |
+
function hoistNonReactStatics(targetComponent, sourceComponent, blacklist) {
|
635 |
+
if (typeof sourceComponent !== 'string') {
|
636 |
+
// don't hoist over string (html) components
|
637 |
+
if (objectPrototype) {
|
638 |
+
var inheritedComponent = getPrototypeOf(sourceComponent);
|
639 |
+
|
640 |
+
if (inheritedComponent && inheritedComponent !== objectPrototype) {
|
641 |
+
hoistNonReactStatics(targetComponent, inheritedComponent, blacklist);
|
642 |
+
}
|
643 |
+
}
|
644 |
+
|
645 |
+
var keys = getOwnPropertyNames(sourceComponent);
|
646 |
+
|
647 |
+
if (getOwnPropertySymbols) {
|
648 |
+
keys = keys.concat(getOwnPropertySymbols(sourceComponent));
|
649 |
+
}
|
650 |
+
|
651 |
+
var targetStatics = getStatics(targetComponent);
|
652 |
+
var sourceStatics = getStatics(sourceComponent);
|
653 |
+
|
654 |
+
for (var i = 0; i < keys.length; ++i) {
|
655 |
+
var key = keys[i];
|
656 |
+
|
657 |
+
if (!KNOWN_STATICS[key] && !(blacklist && blacklist[key]) && !(sourceStatics && sourceStatics[key]) && !(targetStatics && targetStatics[key])) {
|
658 |
+
var descriptor = getOwnPropertyDescriptor(sourceComponent, key);
|
659 |
+
|
660 |
+
try {
|
661 |
+
// Avoid failures from read-only properties
|
662 |
+
defineProperty(targetComponent, key, descriptor);
|
663 |
+
} catch (e) {}
|
664 |
+
}
|
665 |
+
}
|
666 |
+
}
|
667 |
+
|
668 |
+
return targetComponent;
|
669 |
+
}
|
670 |
+
|
671 |
+
module.exports = hoistNonReactStatics;
|
672 |
+
|
673 |
+
|
674 |
+
/***/ }),
|
675 |
+
|
676 |
+
/***/ 119:
|
677 |
+
/***/ (function(module, __webpack_exports__, __webpack_require__) {
|
678 |
+
|
679 |
+
"use strict";
|
680 |
+
|
681 |
+
// EXPORTS
|
682 |
+
__webpack_require__.d(__webpack_exports__, "c", function() { return /* binding */ layout_PrimaryLayout; });
|
683 |
+
__webpack_require__.d(__webpack_exports__, "b", function() { return /* binding */ PageLayout; });
|
684 |
+
__webpack_require__.d(__webpack_exports__, "a", function() { return /* binding */ EmbedLayout; });
|
685 |
+
|
686 |
+
// EXTERNAL MODULE: ./node_modules/@babel/runtime/helpers/extends.js
|
687 |
+
var helpers_extends = __webpack_require__(36);
|
688 |
+
var extends_default = /*#__PURE__*/__webpack_require__.n(helpers_extends);
|
689 |
+
|
690 |
+
// EXTERNAL MODULE: external ["wp","element"]
|
691 |
+
var external_wp_element_ = __webpack_require__(0);
|
692 |
+
|
693 |
+
// EXTERNAL MODULE: external ["wp","components"]
|
694 |
+
var external_wp_components_ = __webpack_require__(3);
|
695 |
+
|
696 |
+
// EXTERNAL MODULE: external ["wp","compose"]
|
697 |
+
var external_wp_compose_ = __webpack_require__(14);
|
698 |
+
|
699 |
+
// EXTERNAL MODULE: external ["wp","data"]
|
700 |
+
var external_wp_data_ = __webpack_require__(7);
|
701 |
+
|
702 |
+
// EXTERNAL MODULE: ./node_modules/@babel/runtime/helpers/esm/inheritsLoose.js + 1 modules
|
703 |
+
var inheritsLoose = __webpack_require__(25);
|
704 |
+
|
705 |
+
// EXTERNAL MODULE: external "React"
|
706 |
+
var external_React_ = __webpack_require__(5);
|
707 |
+
var external_React_default = /*#__PURE__*/__webpack_require__.n(external_React_);
|
708 |
+
|
709 |
+
// EXTERNAL MODULE: ./node_modules/prop-types/index.js
|
710 |
+
var prop_types = __webpack_require__(1);
|
711 |
+
var prop_types_default = /*#__PURE__*/__webpack_require__.n(prop_types);
|
712 |
+
|
713 |
+
// EXTERNAL MODULE: ./node_modules/history/esm/history.js + 2 modules
|
714 |
+
var esm_history = __webpack_require__(52);
|
715 |
+
|
716 |
+
// EXTERNAL MODULE: ./node_modules/mini-create-react-context/dist/esm/index.js
|
717 |
+
var esm = __webpack_require__(160);
|
718 |
+
|
719 |
+
// EXTERNAL MODULE: ./node_modules/tiny-invariant/dist/tiny-invariant.esm.js
|
720 |
+
var tiny_invariant_esm = __webpack_require__(43);
|
721 |
+
|
722 |
+
// EXTERNAL MODULE: ./node_modules/@babel/runtime/helpers/esm/extends.js
|
723 |
+
var esm_extends = __webpack_require__(23);
|
724 |
+
|
725 |
+
// EXTERNAL MODULE: ./node_modules/path-to-regexp/index.js
|
726 |
+
var path_to_regexp = __webpack_require__(161);
|
727 |
+
var path_to_regexp_default = /*#__PURE__*/__webpack_require__.n(path_to_regexp);
|
728 |
+
|
729 |
+
// EXTERNAL MODULE: ./node_modules/react-is/index.js
|
730 |
+
var react_is = __webpack_require__(104);
|
731 |
+
|
732 |
+
// EXTERNAL MODULE: ./node_modules/@babel/runtime/helpers/esm/objectWithoutPropertiesLoose.js
|
733 |
+
var objectWithoutPropertiesLoose = __webpack_require__(22);
|
734 |
+
|
735 |
+
// EXTERNAL MODULE: ./node_modules/hoist-non-react-statics/dist/hoist-non-react-statics.cjs.js
|
736 |
+
var hoist_non_react_statics_cjs = __webpack_require__(118);
|
737 |
+
var hoist_non_react_statics_cjs_default = /*#__PURE__*/__webpack_require__.n(hoist_non_react_statics_cjs);
|
738 |
+
|
739 |
+
// CONCATENATED MODULE: ./node_modules/react-router/esm/react-router.js
|
740 |
+
|
741 |
+
|
742 |
+
|
743 |
+
|
744 |
+
|
745 |
+
|
746 |
+
|
747 |
+
|
748 |
+
|
749 |
+
|
750 |
+
|
751 |
+
|
752 |
+
|
753 |
+
// TODO: Replace with React.createContext once we can assume React 16+
|
754 |
+
|
755 |
+
var react_router_createNamedContext = function createNamedContext(name) {
|
756 |
+
var context = Object(esm["a" /* default */])();
|
757 |
+
context.displayName = name;
|
758 |
+
return context;
|
759 |
+
};
|
760 |
+
|
761 |
+
var historyContext =
|
762 |
+
/*#__PURE__*/
|
763 |
+
react_router_createNamedContext("Router-History");
|
764 |
+
|
765 |
+
// TODO: Replace with React.createContext once we can assume React 16+
|
766 |
+
|
767 |
+
var createNamedContext$1 = function createNamedContext(name) {
|
768 |
+
var context = Object(esm["a" /* default */])();
|
769 |
+
context.displayName = name;
|
770 |
+
return context;
|
771 |
+
};
|
772 |
+
|
773 |
+
var react_router_context =
|
774 |
+
/*#__PURE__*/
|
775 |
+
createNamedContext$1("Router");
|
776 |
+
|
777 |
+
/**
|
778 |
+
* The public API for putting history on context.
|
779 |
+
*/
|
780 |
+
|
781 |
+
var react_router_Router =
|
782 |
+
/*#__PURE__*/
|
783 |
+
function (_React$Component) {
|
784 |
+
Object(inheritsLoose["a" /* default */])(Router, _React$Component);
|
785 |
+
|
786 |
+
Router.computeRootMatch = function computeRootMatch(pathname) {
|
787 |
+
return {
|
788 |
+
path: "/",
|
789 |
+
url: "/",
|
790 |
+
params: {},
|
791 |
+
isExact: pathname === "/"
|
792 |
+
};
|
793 |
+
};
|
794 |
+
|
795 |
+
function Router(props) {
|
796 |
+
var _this;
|
797 |
+
|
798 |
+
_this = _React$Component.call(this, props) || this;
|
799 |
+
_this.state = {
|
800 |
+
location: props.history.location
|
801 |
+
}; // This is a bit of a hack. We have to start listening for location
|
802 |
+
// changes here in the constructor in case there are any <Redirect>s
|
803 |
+
// on the initial render. If there are, they will replace/push when
|
804 |
+
// they mount and since cDM fires in children before parents, we may
|
805 |
+
// get a new location before the <Router> is mounted.
|
806 |
+
|
807 |
+
_this._isMounted = false;
|
808 |
+
_this._pendingLocation = null;
|
809 |
+
|
810 |
+
if (!props.staticContext) {
|
811 |
+
_this.unlisten = props.history.listen(function (location) {
|
812 |
+
if (_this._isMounted) {
|
813 |
+
_this.setState({
|
814 |
+
location: location
|
815 |
+
});
|
816 |
+
} else {
|
817 |
+
_this._pendingLocation = location;
|
818 |
+
}
|
819 |
+
});
|
820 |
+
}
|
821 |
+
|
822 |
+
return _this;
|
823 |
+
}
|
824 |
+
|
825 |
+
var _proto = Router.prototype;
|
826 |
+
|
827 |
+
_proto.componentDidMount = function componentDidMount() {
|
828 |
+
this._isMounted = true;
|
829 |
+
|
830 |
+
if (this._pendingLocation) {
|
831 |
+
this.setState({
|
832 |
+
location: this._pendingLocation
|
833 |
+
});
|
834 |
+
}
|
835 |
+
};
|
836 |
+
|
837 |
+
_proto.componentWillUnmount = function componentWillUnmount() {
|
838 |
+
if (this.unlisten) this.unlisten();
|
839 |
+
};
|
840 |
+
|
841 |
+
_proto.render = function render() {
|
842 |
+
return external_React_default.a.createElement(react_router_context.Provider, {
|
843 |
+
value: {
|
844 |
+
history: this.props.history,
|
845 |
+
location: this.state.location,
|
846 |
+
match: Router.computeRootMatch(this.state.location.pathname),
|
847 |
+
staticContext: this.props.staticContext
|
848 |
+
}
|
849 |
+
}, external_React_default.a.createElement(historyContext.Provider, {
|
850 |
+
children: this.props.children || null,
|
851 |
+
value: this.props.history
|
852 |
+
}));
|
853 |
+
};
|
854 |
+
|
855 |
+
return Router;
|
856 |
+
}(external_React_default.a.Component);
|
857 |
+
|
858 |
+
if (false) {}
|
859 |
+
|
860 |
+
/**
|
861 |
+
* The public API for a <Router> that stores location in memory.
|
862 |
+
*/
|
863 |
+
|
864 |
+
var react_router_MemoryRouter =
|
865 |
+
/*#__PURE__*/
|
866 |
+
function (_React$Component) {
|
867 |
+
Object(inheritsLoose["a" /* default */])(MemoryRouter, _React$Component);
|
868 |
+
|
869 |
+
function MemoryRouter() {
|
870 |
+
var _this;
|
871 |
+
|
872 |
+
for (var _len = arguments.length, args = new Array(_len), _key = 0; _key < _len; _key++) {
|
873 |
+
args[_key] = arguments[_key];
|
874 |
+
}
|
875 |
+
|
876 |
+
_this = _React$Component.call.apply(_React$Component, [this].concat(args)) || this;
|
877 |
+
_this.history = Object(esm_history["c" /* createMemoryHistory */])(_this.props);
|
878 |
+
return _this;
|
879 |
+
}
|
880 |
+
|
881 |
+
var _proto = MemoryRouter.prototype;
|
882 |
+
|
883 |
+
_proto.render = function render() {
|
884 |
+
return external_React_default.a.createElement(react_router_Router, {
|
885 |
+
history: this.history,
|
886 |
+
children: this.props.children
|
887 |
+
});
|
888 |
+
};
|
889 |
+
|
890 |
+
return MemoryRouter;
|
891 |
+
}(external_React_default.a.Component);
|
892 |
+
|
893 |
+
if (false) {}
|
894 |
+
|
895 |
+
var react_router_Lifecycle =
|
896 |
+
/*#__PURE__*/
|
897 |
+
function (_React$Component) {
|
898 |
+
Object(inheritsLoose["a" /* default */])(Lifecycle, _React$Component);
|
899 |
+
|
900 |
+
function Lifecycle() {
|
901 |
+
return _React$Component.apply(this, arguments) || this;
|
902 |
+
}
|
903 |
+
|
904 |
+
var _proto = Lifecycle.prototype;
|
905 |
+
|
906 |
+
_proto.componentDidMount = function componentDidMount() {
|
907 |
+
if (this.props.onMount) this.props.onMount.call(this, this);
|
908 |
+
};
|
909 |
+
|
910 |
+
_proto.componentDidUpdate = function componentDidUpdate(prevProps) {
|
911 |
+
if (this.props.onUpdate) this.props.onUpdate.call(this, this, prevProps);
|
912 |
+
};
|
913 |
+
|
914 |
+
_proto.componentWillUnmount = function componentWillUnmount() {
|
915 |
+
if (this.props.onUnmount) this.props.onUnmount.call(this, this);
|
916 |
+
};
|
917 |
+
|
918 |
+
_proto.render = function render() {
|
919 |
+
return null;
|
920 |
+
};
|
921 |
+
|
922 |
+
return Lifecycle;
|
923 |
+
}(external_React_default.a.Component);
|
924 |
+
|
925 |
+
/**
|
926 |
+
* The public API for prompting the user before navigating away from a screen.
|
927 |
+
*/
|
928 |
+
|
929 |
+
function Prompt(_ref) {
|
930 |
+
var message = _ref.message,
|
931 |
+
_ref$when = _ref.when,
|
932 |
+
when = _ref$when === void 0 ? true : _ref$when;
|
933 |
+
return external_React_default.a.createElement(react_router_context.Consumer, null, function (context) {
|
934 |
+
!context ? false ? undefined : Object(tiny_invariant_esm["a" /* default */])(false) : void 0;
|
935 |
+
if (!when || context.staticContext) return null;
|
936 |
+
var method = context.history.block;
|
937 |
+
return external_React_default.a.createElement(react_router_Lifecycle, {
|
938 |
+
onMount: function onMount(self) {
|
939 |
+
self.release = method(message);
|
940 |
+
},
|
941 |
+
onUpdate: function onUpdate(self, prevProps) {
|
942 |
+
if (prevProps.message !== message) {
|
943 |
+
self.release();
|
944 |
+
self.release = method(message);
|
945 |
+
}
|
946 |
+
},
|
947 |
+
onUnmount: function onUnmount(self) {
|
948 |
+
self.release();
|
949 |
+
},
|
950 |
+
message: message
|
951 |
+
});
|
952 |
+
});
|
953 |
+
}
|
954 |
+
|
955 |
+
if (false) { var messageType; }
|
956 |
+
|
957 |
+
var cache = {};
|
958 |
+
var cacheLimit = 10000;
|
959 |
+
var cacheCount = 0;
|
960 |
+
|
961 |
+
function compilePath(path) {
|
962 |
+
if (cache[path]) return cache[path];
|
963 |
+
var generator = path_to_regexp_default.a.compile(path);
|
964 |
+
|
965 |
+
if (cacheCount < cacheLimit) {
|
966 |
+
cache[path] = generator;
|
967 |
+
cacheCount++;
|
968 |
+
}
|
969 |
+
|
970 |
+
return generator;
|
971 |
+
}
|
972 |
+
/**
|
973 |
+
* Public API for generating a URL pathname from a path and parameters.
|
974 |
+
*/
|
975 |
+
|
976 |
+
|
977 |
+
function generatePath(path, params) {
|
978 |
+
if (path === void 0) {
|
979 |
+
path = "/";
|
980 |
+
}
|
981 |
+
|
982 |
+
if (params === void 0) {
|
983 |
+
params = {};
|
984 |
+
}
|
985 |
+
|
986 |
+
return path === "/" ? path : compilePath(path)(params, {
|
987 |
+
pretty: true
|
988 |
+
});
|
989 |
+
}
|
990 |
+
|
991 |
+
/**
|
992 |
+
* The public API for navigating programmatically with a component.
|
993 |
+
*/
|
994 |
+
|
995 |
+
function Redirect(_ref) {
|
996 |
+
var computedMatch = _ref.computedMatch,
|
997 |
+
to = _ref.to,
|
998 |
+
_ref$push = _ref.push,
|
999 |
+
push = _ref$push === void 0 ? false : _ref$push;
|
1000 |
+
return external_React_default.a.createElement(react_router_context.Consumer, null, function (context) {
|
1001 |
+
!context ? false ? undefined : Object(tiny_invariant_esm["a" /* default */])(false) : void 0;
|
1002 |
+
var history = context.history,
|
1003 |
+
staticContext = context.staticContext;
|
1004 |
+
var method = push ? history.push : history.replace;
|
1005 |
+
var location = Object(esm_history["b" /* createLocation */])(computedMatch ? typeof to === "string" ? generatePath(to, computedMatch.params) : Object(esm_extends["a" /* default */])({}, to, {
|
1006 |
+
pathname: generatePath(to.pathname, computedMatch.params)
|
1007 |
+
}) : to); // When rendering in a static context,
|
1008 |
+
// set the new location immediately.
|
1009 |
+
|
1010 |
+
if (staticContext) {
|
1011 |
+
method(location);
|
1012 |
+
return null;
|
1013 |
+
}
|
1014 |
+
|
1015 |
+
return external_React_default.a.createElement(react_router_Lifecycle, {
|
1016 |
+
onMount: function onMount() {
|
1017 |
+
method(location);
|
1018 |
+
},
|
1019 |
+
onUpdate: function onUpdate(self, prevProps) {
|
1020 |
+
var prevLocation = Object(esm_history["b" /* createLocation */])(prevProps.to);
|
1021 |
+
|
1022 |
+
if (!Object(esm_history["e" /* locationsAreEqual */])(prevLocation, Object(esm_extends["a" /* default */])({}, location, {
|
1023 |
+
key: prevLocation.key
|
1024 |
+
}))) {
|
1025 |
+
method(location);
|
1026 |
+
}
|
1027 |
+
},
|
1028 |
+
to: to
|
1029 |
+
});
|
1030 |
+
});
|
1031 |
+
}
|
1032 |
+
|
1033 |
+
if (false) {}
|
1034 |
+
|
1035 |
+
var cache$1 = {};
|
1036 |
+
var cacheLimit$1 = 10000;
|
1037 |
+
var cacheCount$1 = 0;
|
1038 |
+
|
1039 |
+
function compilePath$1(path, options) {
|
1040 |
+
var cacheKey = "" + options.end + options.strict + options.sensitive;
|
1041 |
+
var pathCache = cache$1[cacheKey] || (cache$1[cacheKey] = {});
|
1042 |
+
if (pathCache[path]) return pathCache[path];
|
1043 |
+
var keys = [];
|
1044 |
+
var regexp = path_to_regexp_default()(path, keys, options);
|
1045 |
+
var result = {
|
1046 |
+
regexp: regexp,
|
1047 |
+
keys: keys
|
1048 |
+
};
|
1049 |
+
|
1050 |
+
if (cacheCount$1 < cacheLimit$1) {
|
1051 |
+
pathCache[path] = result;
|
1052 |
+
cacheCount$1++;
|
1053 |
+
}
|
1054 |
+
|
1055 |
+
return result;
|
1056 |
+
}
|
1057 |
+
/**
|
1058 |
+
* Public API for matching a URL pathname to a path.
|
1059 |
+
*/
|
1060 |
+
|
1061 |
+
|
1062 |
+
function matchPath(pathname, options) {
|
1063 |
+
if (options === void 0) {
|
1064 |
+
options = {};
|
1065 |
+
}
|
1066 |
+
|
1067 |
+
if (typeof options === "string" || Array.isArray(options)) {
|
1068 |
+
options = {
|
1069 |
+
path: options
|
1070 |
+
};
|
1071 |
+
}
|
1072 |
+
|
1073 |
+
var _options = options,
|
1074 |
+
path = _options.path,
|
1075 |
+
_options$exact = _options.exact,
|
1076 |
+
exact = _options$exact === void 0 ? false : _options$exact,
|
1077 |
+
_options$strict = _options.strict,
|
1078 |
+
strict = _options$strict === void 0 ? false : _options$strict,
|
1079 |
+
_options$sensitive = _options.sensitive,
|
1080 |
+
sensitive = _options$sensitive === void 0 ? false : _options$sensitive;
|
1081 |
+
var paths = [].concat(path);
|
1082 |
+
return paths.reduce(function (matched, path) {
|
1083 |
+
if (!path && path !== "") return null;
|
1084 |
+
if (matched) return matched;
|
1085 |
+
|
1086 |
+
var _compilePath = compilePath$1(path, {
|
1087 |
+
end: exact,
|
1088 |
+
strict: strict,
|
1089 |
+
sensitive: sensitive
|
1090 |
+
}),
|
1091 |
+
regexp = _compilePath.regexp,
|
1092 |
+
keys = _compilePath.keys;
|
1093 |
+
|
1094 |
+
var match = regexp.exec(pathname);
|
1095 |
+
if (!match) return null;
|
1096 |
+
var url = match[0],
|
1097 |
+
values = match.slice(1);
|
1098 |
+
var isExact = pathname === url;
|
1099 |
+
if (exact && !isExact) return null;
|
1100 |
+
return {
|
1101 |
+
path: path,
|
1102 |
+
// the path used to match
|
1103 |
+
url: path === "/" && url === "" ? "/" : url,
|
1104 |
+
// the matched portion of the URL
|
1105 |
+
isExact: isExact,
|
1106 |
+
// whether or not we matched exactly
|
1107 |
+
params: keys.reduce(function (memo, key, index) {
|
1108 |
+
memo[key.name] = values[index];
|
1109 |
+
return memo;
|
1110 |
+
}, {})
|
1111 |
+
};
|
1112 |
+
}, null);
|
1113 |
+
}
|
1114 |
+
|
1115 |
+
function isEmptyChildren(children) {
|
1116 |
+
return external_React_default.a.Children.count(children) === 0;
|
1117 |
+
}
|
1118 |
+
|
1119 |
+
function evalChildrenDev(children, props, path) {
|
1120 |
+
var value = children(props);
|
1121 |
+
false ? undefined : void 0;
|
1122 |
+
return value || null;
|
1123 |
+
}
|
1124 |
+
/**
|
1125 |
+
* The public API for matching a single path and rendering.
|
1126 |
+
*/
|
1127 |
+
|
1128 |
+
|
1129 |
+
var react_router_Route =
|
1130 |
+
/*#__PURE__*/
|
1131 |
+
function (_React$Component) {
|
1132 |
+
Object(inheritsLoose["a" /* default */])(Route, _React$Component);
|
1133 |
+
|
1134 |
+
function Route() {
|
1135 |
+
return _React$Component.apply(this, arguments) || this;
|
1136 |
+
}
|
1137 |
+
|
1138 |
+
var _proto = Route.prototype;
|
1139 |
+
|
1140 |
+
_proto.render = function render() {
|
1141 |
+
var _this = this;
|
1142 |
+
|
1143 |
+
return external_React_default.a.createElement(react_router_context.Consumer, null, function (context$1) {
|
1144 |
+
!context$1 ? false ? undefined : Object(tiny_invariant_esm["a" /* default */])(false) : void 0;
|
1145 |
+
var location = _this.props.location || context$1.location;
|
1146 |
+
var match = _this.props.computedMatch ? _this.props.computedMatch // <Switch> already computed the match for us
|
1147 |
+
: _this.props.path ? matchPath(location.pathname, _this.props) : context$1.match;
|
1148 |
+
|
1149 |
+
var props = Object(esm_extends["a" /* default */])({}, context$1, {
|
1150 |
+
location: location,
|
1151 |
+
match: match
|
1152 |
+
});
|
1153 |
+
|
1154 |
+
var _this$props = _this.props,
|
1155 |
+
children = _this$props.children,
|
1156 |
+
component = _this$props.component,
|
1157 |
+
render = _this$props.render; // Preact uses an empty array as children by
|
1158 |
+
// default, so use null if that's the case.
|
1159 |
+
|
1160 |
+
if (Array.isArray(children) && children.length === 0) {
|
1161 |
+
children = null;
|
1162 |
+
}
|
1163 |
+
|
1164 |
+
return external_React_default.a.createElement(react_router_context.Provider, {
|
1165 |
+
value: props
|
1166 |
+
}, props.match ? children ? typeof children === "function" ? false ? undefined : children(props) : children : component ? external_React_default.a.createElement(component, props) : render ? render(props) : null : typeof children === "function" ? false ? undefined : children(props) : null);
|
1167 |
+
});
|
1168 |
+
};
|
1169 |
+
|
1170 |
+
return Route;
|
1171 |
+
}(external_React_default.a.Component);
|
1172 |
+
|
1173 |
+
if (false) {}
|
1174 |
+
|
1175 |
+
function addLeadingSlash(path) {
|
1176 |
+
return path.charAt(0) === "/" ? path : "/" + path;
|
1177 |
+
}
|
1178 |
+
|
1179 |
+
function addBasename(basename, location) {
|
1180 |
+
if (!basename) return location;
|
1181 |
+
return Object(esm_extends["a" /* default */])({}, location, {
|
1182 |
+
pathname: addLeadingSlash(basename) + location.pathname
|
1183 |
+
});
|
1184 |
+
}
|
1185 |
+
|
1186 |
+
function stripBasename(basename, location) {
|
1187 |
+
if (!basename) return location;
|
1188 |
+
var base = addLeadingSlash(basename);
|
1189 |
+
if (location.pathname.indexOf(base) !== 0) return location;
|
1190 |
+
return Object(esm_extends["a" /* default */])({}, location, {
|
1191 |
+
pathname: location.pathname.substr(base.length)
|
1192 |
+
});
|
1193 |
+
}
|
1194 |
+
|
1195 |
+
function createURL(location) {
|
1196 |
+
return typeof location === "string" ? location : Object(esm_history["d" /* createPath */])(location);
|
1197 |
+
}
|
1198 |
+
|
1199 |
+
function staticHandler(methodName) {
|
1200 |
+
return function () {
|
1201 |
+
false ? undefined : Object(tiny_invariant_esm["a" /* default */])(false) ;
|
1202 |
+
};
|
1203 |
+
}
|
1204 |
+
|
1205 |
+
function noop() {}
|
1206 |
+
/**
|
1207 |
+
* The public top-level API for a "static" <Router>, so-called because it
|
1208 |
+
* can't actually change the current location. Instead, it just records
|
1209 |
+
* location changes in a context object. Useful mainly in testing and
|
1210 |
+
* server-rendering scenarios.
|
1211 |
+
*/
|
1212 |
+
|
1213 |
+
|
1214 |
+
var react_router_StaticRouter =
|
1215 |
+
/*#__PURE__*/
|
1216 |
+
function (_React$Component) {
|
1217 |
+
Object(inheritsLoose["a" /* default */])(StaticRouter, _React$Component);
|
1218 |
+
|
1219 |
+
function StaticRouter() {
|
1220 |
+
var _this;
|
1221 |
+
|
1222 |
+
for (var _len = arguments.length, args = new Array(_len), _key = 0; _key < _len; _key++) {
|
1223 |
+
args[_key] = arguments[_key];
|
1224 |
+
}
|
1225 |
+
|
1226 |
+
_this = _React$Component.call.apply(_React$Component, [this].concat(args)) || this;
|
1227 |
+
|
1228 |
+
_this.handlePush = function (location) {
|
1229 |
+
return _this.navigateTo(location, "PUSH");
|
1230 |
+
};
|
1231 |
+
|
1232 |
+
_this.handleReplace = function (location) {
|
1233 |
+
return _this.navigateTo(location, "REPLACE");
|
1234 |
+
};
|
1235 |
+
|
1236 |
+
_this.handleListen = function () {
|
1237 |
+
return noop;
|
1238 |
+
};
|
1239 |
+
|
1240 |
+
_this.handleBlock = function () {
|
1241 |
+
return noop;
|
1242 |
+
};
|
1243 |
+
|
1244 |
+
return _this;
|
1245 |
+
}
|
1246 |
+
|
1247 |
+
var _proto = StaticRouter.prototype;
|
1248 |
+
|
1249 |
+
_proto.navigateTo = function navigateTo(location, action) {
|
1250 |
+
var _this$props = this.props,
|
1251 |
+
_this$props$basename = _this$props.basename,
|
1252 |
+
basename = _this$props$basename === void 0 ? "" : _this$props$basename,
|
1253 |
+
_this$props$context = _this$props.context,
|
1254 |
+
context = _this$props$context === void 0 ? {} : _this$props$context;
|
1255 |
+
context.action = action;
|
1256 |
+
context.location = addBasename(basename, Object(esm_history["b" /* createLocation */])(location));
|
1257 |
+
context.url = createURL(context.location);
|
1258 |
+
};
|
1259 |
+
|
1260 |
+
_proto.render = function render() {
|
1261 |
+
var _this$props2 = this.props,
|
1262 |
+
_this$props2$basename = _this$props2.basename,
|
1263 |
+
basename = _this$props2$basename === void 0 ? "" : _this$props2$basename,
|
1264 |
+
_this$props2$context = _this$props2.context,
|
1265 |
+
context = _this$props2$context === void 0 ? {} : _this$props2$context,
|
1266 |
+
_this$props2$location = _this$props2.location,
|
1267 |
+
location = _this$props2$location === void 0 ? "/" : _this$props2$location,
|
1268 |
+
rest = Object(objectWithoutPropertiesLoose["a" /* default */])(_this$props2, ["basename", "context", "location"]);
|
1269 |
+
|
1270 |
+
var history = {
|
1271 |
+
createHref: function createHref(path) {
|
1272 |
+
return addLeadingSlash(basename + createURL(path));
|
1273 |
+
},
|
1274 |
+
action: "POP",
|
1275 |
+
location: stripBasename(basename, Object(esm_history["b" /* createLocation */])(location)),
|
1276 |
+
push: this.handlePush,
|
1277 |
+
replace: this.handleReplace,
|
1278 |
+
go: staticHandler("go"),
|
1279 |
+
goBack: staticHandler("goBack"),
|
1280 |
+
goForward: staticHandler("goForward"),
|
1281 |
+
listen: this.handleListen,
|
1282 |
+
block: this.handleBlock
|
1283 |
+
};
|
1284 |
+
return external_React_default.a.createElement(react_router_Router, Object(esm_extends["a" /* default */])({}, rest, {
|
1285 |
+
history: history,
|
1286 |
+
staticContext: context
|
1287 |
+
}));
|
1288 |
+
};
|
1289 |
+
|
1290 |
+
return StaticRouter;
|
1291 |
+
}(external_React_default.a.Component);
|
1292 |
+
|
1293 |
+
if (false) {}
|
1294 |
+
|
1295 |
+
/**
|
1296 |
+
* The public API for rendering the first <Route> that matches.
|
1297 |
+
*/
|
1298 |
+
|
1299 |
+
var react_router_Switch =
|
1300 |
+
/*#__PURE__*/
|
1301 |
+
function (_React$Component) {
|
1302 |
+
Object(inheritsLoose["a" /* default */])(Switch, _React$Component);
|
1303 |
+
|
1304 |
+
function Switch() {
|
1305 |
+
return _React$Component.apply(this, arguments) || this;
|
1306 |
+
}
|
1307 |
+
|
1308 |
+
var _proto = Switch.prototype;
|
1309 |
+
|
1310 |
+
_proto.render = function render() {
|
1311 |
+
var _this = this;
|
1312 |
+
|
1313 |
+
return external_React_default.a.createElement(react_router_context.Consumer, null, function (context) {
|
1314 |
+
!context ? false ? undefined : Object(tiny_invariant_esm["a" /* default */])(false) : void 0;
|
1315 |
+
var location = _this.props.location || context.location;
|
1316 |
+
var element, match; // We use React.Children.forEach instead of React.Children.toArray().find()
|
1317 |
+
// here because toArray adds keys to all child elements and we do not want
|
1318 |
+
// to trigger an unmount/remount for two <Route>s that render the same
|
1319 |
+
// component at different URLs.
|
1320 |
+
|
1321 |
+
external_React_default.a.Children.forEach(_this.props.children, function (child) {
|
1322 |
+
if (match == null && external_React_default.a.isValidElement(child)) {
|
1323 |
+
element = child;
|
1324 |
+
var path = child.props.path || child.props.from;
|
1325 |
+
match = path ? matchPath(location.pathname, Object(esm_extends["a" /* default */])({}, child.props, {
|
1326 |
+
path: path
|
1327 |
+
})) : context.match;
|
1328 |
+
}
|
1329 |
+
});
|
1330 |
+
return match ? external_React_default.a.cloneElement(element, {
|
1331 |
+
location: location,
|
1332 |
+
computedMatch: match
|
1333 |
+
}) : null;
|
1334 |
+
});
|
1335 |
+
};
|
1336 |
+
|
1337 |
+
return Switch;
|
1338 |
+
}(external_React_default.a.Component);
|
1339 |
+
|
1340 |
+
if (false) {}
|
1341 |
+
|
1342 |
+
/**
|
1343 |
+
* A public higher-order component to access the imperative API
|
1344 |
+
*/
|
1345 |
+
|
1346 |
+
function withRouter(Component) {
|
1347 |
+
var displayName = "withRouter(" + (Component.displayName || Component.name) + ")";
|
1348 |
+
|
1349 |
+
var C = function C(props) {
|
1350 |
+
var wrappedComponentRef = props.wrappedComponentRef,
|
1351 |
+
remainingProps = Object(objectWithoutPropertiesLoose["a" /* default */])(props, ["wrappedComponentRef"]);
|
1352 |
+
|
1353 |
+
return external_React_default.a.createElement(react_router_context.Consumer, null, function (context) {
|
1354 |
+
!context ? false ? undefined : Object(tiny_invariant_esm["a" /* default */])(false) : void 0;
|
1355 |
+
return external_React_default.a.createElement(Component, Object(esm_extends["a" /* default */])({}, remainingProps, context, {
|
1356 |
+
ref: wrappedComponentRef
|
1357 |
+
}));
|
1358 |
+
});
|
1359 |
+
};
|
1360 |
+
|
1361 |
+
C.displayName = displayName;
|
1362 |
+
C.WrappedComponent = Component;
|
1363 |
+
|
1364 |
+
if (false) {}
|
1365 |
+
|
1366 |
+
return hoist_non_react_statics_cjs_default()(C, Component);
|
1367 |
+
}
|
1368 |
+
|
1369 |
+
var useContext = external_React_default.a.useContext;
|
1370 |
+
function useHistory() {
|
1371 |
+
if (false) {}
|
1372 |
+
|
1373 |
+
return useContext(historyContext);
|
1374 |
+
}
|
1375 |
+
function useLocation() {
|
1376 |
+
if (false) {}
|
1377 |
+
|
1378 |
+
return useContext(react_router_context).location;
|
1379 |
+
}
|
1380 |
+
function useParams() {
|
1381 |
+
if (false) {}
|
1382 |
+
|
1383 |
+
var match = useContext(react_router_context).match;
|
1384 |
+
return match ? match.params : {};
|
1385 |
+
}
|
1386 |
+
function useRouteMatch(path) {
|
1387 |
+
if (false) {}
|
1388 |
+
|
1389 |
+
var location = useLocation();
|
1390 |
+
var match = useContext(react_router_context).match;
|
1391 |
+
return path ? matchPath(location.pathname, path) : match;
|
1392 |
+
}
|
1393 |
+
|
1394 |
+
if (false) { var secondaryBuildName, initialBuildName, buildNames, react_router_key, global; }
|
1395 |
+
|
1396 |
+
|
1397 |
+
//# sourceMappingURL=react-router.js.map
|
1398 |
+
|
1399 |
+
// EXTERNAL MODULE: external "lodash"
|
1400 |
+
var external_lodash_ = __webpack_require__(4);
|
1401 |
+
|
1402 |
+
// EXTERNAL MODULE: ./node_modules/qs/lib/index.js
|
1403 |
+
var lib = __webpack_require__(28);
|
1404 |
+
|
1405 |
+
// EXTERNAL MODULE: external ["wc","navigation"]
|
1406 |
+
var external_wc_navigation_ = __webpack_require__(12);
|
1407 |
+
|
1408 |
+
// EXTERNAL MODULE: ./packages/wc-admin-settings/build-module/index.js
|
1409 |
+
var build_module = __webpack_require__(13);
|
1410 |
+
|
1411 |
+
// EXTERNAL MODULE: external ["wc","data"]
|
1412 |
+
var external_wc_data_ = __webpack_require__(11);
|
1413 |
+
|
1414 |
+
// EXTERNAL MODULE: external ["wc","tracks"]
|
1415 |
+
var external_wc_tracks_ = __webpack_require__(15);
|
1416 |
+
|
1417 |
+
// EXTERNAL MODULE: external ["wc","notices"]
|
1418 |
+
var external_wc_notices_ = __webpack_require__(284);
|
1419 |
+
|
1420 |
+
// EXTERNAL MODULE: external ["wp","plugins"]
|
1421 |
+
var external_wp_plugins_ = __webpack_require__(76);
|
1422 |
+
|
1423 |
+
// EXTERNAL MODULE: ./client/layout/style.scss
|
1424 |
+
var layout_style = __webpack_require__(285);
|
1425 |
+
|
1426 |
+
// EXTERNAL MODULE: external ["wp","hooks"]
|
1427 |
+
var external_wp_hooks_ = __webpack_require__(31);
|
1428 |
+
|
1429 |
+
// EXTERNAL MODULE: external ["wp","i18n"]
|
1430 |
+
var external_wp_i18n_ = __webpack_require__(2);
|
1431 |
+
|
1432 |
+
// EXTERNAL MODULE: external ["wc","components"]
|
1433 |
+
var external_wc_components_ = __webpack_require__(21);
|
1434 |
+
|
1435 |
+
// EXTERNAL MODULE: ./client/analytics/report/get-reports.js
|
1436 |
+
var get_reports = __webpack_require__(117);
|
1437 |
+
|
1438 |
+
// EXTERNAL MODULE: ./client/dashboard/utils.js
|
1439 |
+
var utils = __webpack_require__(62);
|
1440 |
+
|
1441 |
+
// EXTERNAL MODULE: ./client/layout/NoMatch.tsx
|
1442 |
+
var NoMatch = __webpack_require__(175);
|
1443 |
+
|
1444 |
+
// CONCATENATED MODULE: ./client/layout/controller.js
|
1445 |
+
|
1446 |
+
|
1447 |
+
/**
|
1448 |
+
* External dependencies
|
1449 |
+
*/
|
1450 |
+
|
1451 |
+
|
1452 |
+
|
1453 |
+
|
1454 |
+
|
1455 |
+
|
1456 |
+
|
1457 |
+
|
1458 |
+
/**
|
1459 |
+
* Internal dependencies
|
1460 |
+
*/
|
1461 |
+
|
1462 |
+
|
1463 |
+
|
1464 |
+
|
1465 |
+
const AnalyticsReport = Object(external_wp_element_["lazy"])(() => __webpack_require__.e(/* import() | analytics-report */ 5).then(__webpack_require__.bind(null, 618)));
|
1466 |
+
const AnalyticsSettings = Object(external_wp_element_["lazy"])(() => __webpack_require__.e(/* import() | analytics-settings */ 16).then(__webpack_require__.bind(null, 628)));
|
1467 |
+
const Dashboard = Object(external_wp_element_["lazy"])(() => __webpack_require__.e(/* import() | dashboard */ 24).then(__webpack_require__.bind(null, 619)));
|
1468 |
+
const Homescreen = Object(external_wp_element_["lazy"])(() => Promise.all(/* import() | homescreen */[__webpack_require__.e(1), __webpack_require__.e(2), __webpack_require__.e(30)]).then(__webpack_require__.bind(null, 625)));
|
1469 |
+
const MarketingOverview = Object(external_wp_element_["lazy"])(() => Promise.all(/* import() | marketing-overview */[__webpack_require__.e(2), __webpack_require__.e(33)]).then(__webpack_require__.bind(null, 629)));
|
1470 |
+
const ProfileWizard = Object(external_wp_element_["lazy"])(() => Promise.all(/* import() | profile-wizard */[__webpack_require__.e(1), __webpack_require__.e(46)]).then(__webpack_require__.bind(null, 626)));
|
1471 |
+
const SettingsGroup = Object(external_wp_element_["lazy"])(() => Promise.all(/* import() | profile-wizard */[__webpack_require__.e(1), __webpack_require__.e(46)]).then(__webpack_require__.bind(null, 620)));
|
1472 |
+
const PAGES_FILTER = 'woocommerce_admin_pages_list';
|
1473 |
+
const getPages = () => {
|
1474 |
+
const pages = [];
|
1475 |
+
const initialBreadcrumbs = [['', Object(build_module["f" /* getSetting */])('woocommerceTranslation')]];
|
1476 |
+
pages.push({
|
1477 |
+
container: Homescreen,
|
1478 |
+
path: '/',
|
1479 |
+
breadcrumbs: [...initialBreadcrumbs, Object(external_wp_i18n_["__"])('Home', 'woocommerce-admin')],
|
1480 |
+
wpOpenMenu: 'toplevel_page_woocommerce',
|
1481 |
+
navArgs: {
|
1482 |
+
id: 'woocommerce-home'
|
1483 |
+
},
|
1484 |
+
capability: 'manage_woocommerce'
|
1485 |
+
});
|
1486 |
+
|
1487 |
+
if (window.wcAdminFeatures.analytics) {
|
1488 |
+
pages.push({
|
1489 |
+
container: Dashboard,
|
1490 |
+
path: '/analytics/overview',
|
1491 |
+
breadcrumbs: [...initialBreadcrumbs, ['/analytics/overview', Object(external_wp_i18n_["__"])('Analytics', 'woocommerce-admin')], Object(external_wp_i18n_["__"])('Overview', 'woocommerce-admin')],
|
1492 |
+
wpOpenMenu: 'toplevel_page_wc-admin-path--analytics-overview',
|
1493 |
+
navArgs: {
|
1494 |
+
id: 'woocommerce-analytics-overview'
|
1495 |
+
},
|
1496 |
+
capability: 'view_woocommerce_reports'
|
1497 |
+
});
|
1498 |
+
pages.push({
|
1499 |
+
container: AnalyticsSettings,
|
1500 |
+
path: '/analytics/settings',
|
1501 |
+
breadcrumbs: [...initialBreadcrumbs, ['/analytics/revenue', Object(external_wp_i18n_["__"])('Analytics', 'woocommerce-admin')], Object(external_wp_i18n_["__"])('Settings', 'woocommerce-admin')],
|
1502 |
+
wpOpenMenu: 'toplevel_page_wc-admin-path--analytics-overview',
|
1503 |
+
navArgs: {
|
1504 |
+
id: 'woocommerce-analytics-settings'
|
1505 |
+
},
|
1506 |
+
capability: 'view_woocommerce_reports'
|
1507 |
+
});
|
1508 |
+
pages.push({
|
1509 |
+
container: AnalyticsReport,
|
1510 |
+
path: '/customers',
|
1511 |
+
breadcrumbs: [...initialBreadcrumbs, Object(external_wp_i18n_["__"])('Customers', 'woocommerce-admin')],
|
1512 |
+
wpOpenMenu: 'toplevel_page_woocommerce',
|
1513 |
+
navArgs: {
|
1514 |
+
id: 'woocommerce-analytics-customers'
|
1515 |
+
},
|
1516 |
+
capability: 'view_woocommerce_reports'
|
1517 |
+
});
|
1518 |
+
pages.push({
|
1519 |
+
container: AnalyticsReport,
|
1520 |
+
path: '/analytics/:report',
|
1521 |
+
breadcrumbs: ({
|
1522 |
+
match
|
1523 |
+
}) => {
|
1524 |
+
const report = Object(external_lodash_["find"])(Object(get_reports["a" /* default */])(), {
|
1525 |
+
report: match.params.report
|
1526 |
+
});
|
1527 |
+
|
1528 |
+
if (!report) {
|
1529 |
+
return [];
|
1530 |
+
}
|
1531 |
+
|
1532 |
+
return [...initialBreadcrumbs, ['/analytics/revenue', Object(external_wp_i18n_["__"])('Analytics', 'woocommerce-admin')], report.title];
|
1533 |
+
},
|
1534 |
+
wpOpenMenu: 'toplevel_page_wc-admin-path--analytics-overview',
|
1535 |
+
capability: 'view_woocommerce_reports'
|
1536 |
+
});
|
1537 |
+
}
|
1538 |
+
|
1539 |
+
if (window.wcAdminFeatures.marketing) {
|
1540 |
+
pages.push({
|
1541 |
+
container: MarketingOverview,
|
1542 |
+
path: '/marketing',
|
1543 |
+
breadcrumbs: [...initialBreadcrumbs, ['/marketing', Object(external_wp_i18n_["__"])('Marketing', 'woocommerce-admin')], Object(external_wp_i18n_["__"])('Overview', 'woocommerce-admin')],
|
1544 |
+
wpOpenMenu: 'toplevel_page_woocommerce-marketing',
|
1545 |
+
navArgs: {
|
1546 |
+
id: 'woocommerce-marketing-overview'
|
1547 |
+
},
|
1548 |
+
capability: 'view_woocommerce_reports'
|
1549 |
+
});
|
1550 |
+
}
|
1551 |
+
|
1552 |
+
if (window.wcAdminFeatures.onboarding) {
|
1553 |
+
pages.push({
|
1554 |
+
container: ProfileWizard,
|
1555 |
+
path: '/setup-wizard',
|
1556 |
+
breadcrumbs: [...initialBreadcrumbs, ['/setup-wizard', Object(external_wp_i18n_["__"])('Setup Wizard', 'woocommerce-admin')]],
|
1557 |
+
capability: 'manage_woocommerce'
|
1558 |
+
});
|
1559 |
+
}
|
1560 |
+
|
1561 |
+
if (window.wcAdminFeatures.settings) {
|
1562 |
+
pages.push({
|
1563 |
+
container: SettingsGroup,
|
1564 |
+
path: '/settings/:page',
|
1565 |
+
breadcrumbs: ({
|
1566 |
+
match
|
1567 |
+
}) => {
|
1568 |
+
// @todo This might need to be refactored to retreive groups via data store.
|
1569 |
+
const settingsPages = Object(build_module["f" /* getSetting */])('settingsPages');
|
1570 |
+
const page = settingsPages[match.params.page];
|
1571 |
+
|
1572 |
+
if (!page) {
|
1573 |
+
return [];
|
1574 |
+
}
|
1575 |
+
|
1576 |
+
return [...initialBreadcrumbs, [settingsPages.general ? '/settings/general' : `/settings/${Object.keys(settingsPages)[0]}`, Object(external_wp_i18n_["__"])('Settings', 'woocommerce-admin')], page];
|
1577 |
+
},
|
1578 |
+
wpOpenMenu: 'toplevel_page_woocommerce',
|
1579 |
+
capability: 'manage_woocommerce'
|
1580 |
+
});
|
1581 |
+
}
|
1582 |
+
|
1583 |
+
const filteredPages = Object(external_wp_hooks_["applyFilters"])(PAGES_FILTER, pages);
|
1584 |
+
filteredPages.push({
|
1585 |
+
container: NoMatch["a" /* NoMatch */],
|
1586 |
+
path: '*',
|
1587 |
+
breadcrumbs: [...initialBreadcrumbs, Object(external_wp_i18n_["__"])('Not allowed', 'woocommerce-admin')],
|
1588 |
+
wpOpenMenu: 'toplevel_page_woocommerce'
|
1589 |
+
});
|
1590 |
+
return filteredPages;
|
1591 |
+
};
|
1592 |
+
class controller_Controller extends external_wp_element_["Component"] {
|
1593 |
+
componentDidMount() {
|
1594 |
+
window.document.documentElement.scrollTop = 0;
|
1595 |
+
window.document.body.classList.remove('woocommerce-admin-is-loading');
|
1596 |
+
}
|
1597 |
+
|
1598 |
+
componentDidUpdate(prevProps) {
|
1599 |
+
const prevBaseQuery = Object(external_lodash_["omit"])(prevProps.query, 'chartType', 'filter', 'paged');
|
1600 |
+
const baseQuery = Object(external_lodash_["omit"])(this.props.query, 'chartType', 'filter', 'paged');
|
1601 |
+
|
1602 |
+
if (prevProps.query.paged > 1 && !Object(external_lodash_["isEqual"])(prevBaseQuery, baseQuery)) {
|
1603 |
+
Object(external_wc_navigation_["getHistory"])().replace(Object(external_wc_navigation_["getNewPath"])({
|
1604 |
+
paged: 1
|
1605 |
+
}));
|
1606 |
+
}
|
1607 |
+
|
1608 |
+
if (prevProps.match.url !== this.props.match.url) {
|
1609 |
+
window.document.documentElement.scrollTop = 0;
|
1610 |
+
}
|
1611 |
+
}
|
1612 |
+
|
1613 |
+
render() {
|
1614 |
+
const {
|
1615 |
+
page,
|
1616 |
+
match,
|
1617 |
+
query
|
1618 |
+
} = this.props;
|
1619 |
+
const {
|
1620 |
+
url,
|
1621 |
+
params
|
1622 |
+
} = match;
|
1623 |
+
window.wpNavMenuUrlUpdate(query);
|
1624 |
+
window.wpNavMenuClassChange(page, url);
|
1625 |
+
return Object(external_wp_element_["createElement"])(external_wp_element_["Suspense"], {
|
1626 |
+
fallback: Object(external_wp_element_["createElement"])(external_wc_components_["Spinner"], null)
|
1627 |
+
}, Object(external_wp_element_["createElement"])(page.container, {
|
1628 |
+
params: params,
|
1629 |
+
path: url,
|
1630 |
+
pathMatch: page.path,
|
1631 |
+
query: query
|
1632 |
+
}));
|
1633 |
+
}
|
1634 |
+
|
1635 |
+
}
|
1636 |
+
/**
|
1637 |
+
* Update an anchor's link in sidebar to include persisted queries. Leave excluded screens
|
1638 |
+
* as is.
|
1639 |
+
*
|
1640 |
+
* @param {HTMLElement} item - Sidebar anchor link.
|
1641 |
+
* @param {Object} nextQuery - A query object to be added to updated hrefs.
|
1642 |
+
* @param {Array} excludedScreens - wc-admin screens to avoid updating.
|
1643 |
+
*/
|
1644 |
+
|
1645 |
+
function updateLinkHref(item, nextQuery, excludedScreens) {
|
1646 |
+
if (Object(utils["f" /* isWCAdmin */])(item.href)) {
|
1647 |
+
const search = Object(external_lodash_["last"])(item.href.split('?'));
|
1648 |
+
const query = Object(lib["parse"])(search);
|
1649 |
+
const path = query.path || 'homescreen';
|
1650 |
+
const screen = Object(external_wc_navigation_["getScreenFromPath"])(path);
|
1651 |
+
const isExcludedScreen = excludedScreens.includes(screen);
|
1652 |
+
const href = 'admin.php?' + Object(lib["stringify"])(Object.assign(query, isExcludedScreen ? {} : nextQuery)); // Replace the href so you can see the url on hover.
|
1653 |
+
|
1654 |
+
item.href = href;
|
1655 |
+
|
1656 |
+
item.onclick = e => {
|
1657 |
+
e.preventDefault();
|
1658 |
+
Object(external_wc_navigation_["getHistory"])().push(href);
|
1659 |
+
};
|
1660 |
+
}
|
1661 |
+
} // Update's wc-admin links in wp-admin menu
|
1662 |
+
|
1663 |
+
window.wpNavMenuUrlUpdate = function (query) {
|
1664 |
+
const nextQuery = Object(external_wc_navigation_["getPersistedQuery"])(query);
|
1665 |
+
const excludedScreens = Object(external_wc_navigation_["getQueryExcludedScreens"])();
|
1666 |
+
Array.from(document.querySelectorAll('#adminmenu a')).forEach(item => updateLinkHref(item, nextQuery, excludedScreens));
|
1667 |
+
}; // When the route changes, we need to update wp-admin's menu with the correct section & current link
|
1668 |
+
|
1669 |
+
|
1670 |
+
window.wpNavMenuClassChange = function (page, url) {
|
1671 |
+
const wpNavMenu = document.querySelector('#adminmenu');
|
1672 |
+
Array.from(wpNavMenu.getElementsByClassName('current')).forEach(function (item) {
|
1673 |
+
item.classList.remove('current');
|
1674 |
+
});
|
1675 |
+
const submenu = Array.from(wpNavMenu.querySelectorAll('.wp-has-current-submenu'));
|
1676 |
+
submenu.forEach(function (element) {
|
1677 |
+
element.classList.remove('wp-has-current-submenu');
|
1678 |
+
element.classList.remove('wp-menu-open');
|
1679 |
+
element.classList.remove('selected');
|
1680 |
+
element.classList.add('wp-not-current-submenu');
|
1681 |
+
element.classList.add('menu-top');
|
1682 |
+
});
|
1683 |
+
const pageUrl = url === '/' ? 'admin.php?page=wc-admin' : 'admin.php?page=wc-admin&path=' + encodeURIComponent(url);
|
1684 |
+
const currentItemsSelector = url === '/' ? `li > a[href$="${pageUrl}"], li > a[href*="${pageUrl}?"]` : `li > a[href*="${pageUrl}"]`;
|
1685 |
+
const currentItems = wpNavMenu.querySelectorAll(currentItemsSelector);
|
1686 |
+
Array.from(currentItems).forEach(function (item) {
|
1687 |
+
item.parentElement.classList.add('current');
|
1688 |
+
});
|
1689 |
+
|
1690 |
+
if (page.wpOpenMenu) {
|
1691 |
+
const currentMenu = wpNavMenu.querySelector('#' + page.wpOpenMenu);
|
1692 |
+
|
1693 |
+
if (currentMenu) {
|
1694 |
+
currentMenu.classList.remove('wp-not-current-submenu');
|
1695 |
+
currentMenu.classList.add('wp-has-current-submenu');
|
1696 |
+
currentMenu.classList.add('wp-menu-open');
|
1697 |
+
currentMenu.classList.add('current');
|
1698 |
+
}
|
1699 |
+
}
|
1700 |
+
|
1701 |
+
const wpWrap = document.querySelector('#wpwrap');
|
1702 |
+
wpWrap.classList.remove('wp-responsive-open');
|
1703 |
+
};
|
1704 |
+
// EXTERNAL MODULE: ./node_modules/classnames/index.js
|
1705 |
+
var classnames = __webpack_require__(6);
|
1706 |
+
var classnames_default = /*#__PURE__*/__webpack_require__.n(classnames);
|
1707 |
+
|
1708 |
+
// EXTERNAL MODULE: external ["wp","htmlEntities"]
|
1709 |
+
var external_wp_htmlEntities_ = __webpack_require__(29);
|
1710 |
+
|
1711 |
+
// EXTERNAL MODULE: external ["wc","experimental"]
|
1712 |
+
var external_wc_experimental_ = __webpack_require__(17);
|
1713 |
+
|
1714 |
+
// EXTERNAL MODULE: ./node_modules/@wordpress/icons/build-module/icon/index.js + 2 modules
|
1715 |
+
var build_module_icon = __webpack_require__(116);
|
1716 |
+
|
1717 |
+
// EXTERNAL MODULE: ./node_modules/@wordpress/icons/build-module/library/chevron-left.js
|
1718 |
+
var chevron_left = __webpack_require__(293);
|
1719 |
+
|
1720 |
+
// EXTERNAL MODULE: external ["wp","keycodes"]
|
1721 |
+
var external_wp_keycodes_ = __webpack_require__(27);
|
1722 |
+
|
1723 |
+
// EXTERNAL MODULE: ./client/header/style.scss
|
1724 |
+
var header_style = __webpack_require__(286);
|
1725 |
+
|
1726 |
+
// EXTERNAL MODULE: external ["wp","primitives"]
|
1727 |
+
var external_wp_primitives_ = __webpack_require__(8);
|
1728 |
+
|
1729 |
+
// CONCATENATED MODULE: ./node_modules/@wordpress/icons/build-module/library/help.js
|
1730 |
+
|
1731 |
+
|
1732 |
+
/**
|
1733 |
+
* WordPress dependencies
|
1734 |
+
*/
|
1735 |
+
|
1736 |
+
var help_help = Object(external_wp_element_["createElement"])(external_wp_primitives_["SVG"], {
|
1737 |
+
xmlns: "http://www.w3.org/2000/svg",
|
1738 |
+
viewBox: "0 0 24 24"
|
1739 |
+
}, Object(external_wp_element_["createElement"])(external_wp_primitives_["Path"], {
|
1740 |
+
d: "M12 4.75a7.25 7.25 0 100 14.5 7.25 7.25 0 000-14.5zM3.25 12a8.75 8.75 0 1117.5 0 8.75 8.75 0 01-17.5 0zM12 8.75a1.5 1.5 0 01.167 2.99c-.465.052-.917.44-.917 1.01V14h1.5v-.845A3 3 0 109 10.25h1.5a1.5 1.5 0 011.5-1.5zM11.25 15v1.5h1.5V15h-1.5z"
|
1741 |
+
}));
|
1742 |
+
/* harmony default export */ var library_help = (help_help);
|
1743 |
+
//# sourceMappingURL=help.js.map
|
1744 |
+
// EXTERNAL MODULE: ./node_modules/@wordpress/icons/build-module/library/external.js
|
1745 |
+
var external = __webpack_require__(502);
|
1746 |
+
|
1747 |
+
// EXTERNAL MODULE: ./client/header/activity-panel/style.scss
|
1748 |
+
var activity_panel_style = __webpack_require__(287);
|
1749 |
+
|
1750 |
+
// EXTERNAL MODULE: ./client/inbox-panel/utils.js
|
1751 |
+
var inbox_panel_utils = __webpack_require__(164);
|
1752 |
+
|
1753 |
+
// CONCATENATED MODULE: ./client/header/activity-panel/unread-indicators.js
|
1754 |
+
/**
|
1755 |
+
* External dependencies
|
1756 |
+
*/
|
1757 |
+
|
1758 |
+
|
1759 |
+
/**
|
1760 |
+
* Internal dependencies
|
1761 |
+
*/
|
1762 |
+
|
1763 |
+
|
1764 |
+
const UNREAD_NOTES_QUERY = {
|
1765 |
+
page: 1,
|
1766 |
+
per_page: external_wc_data_["QUERY_DEFAULTS"].pageSize,
|
1767 |
+
status: 'unactioned',
|
1768 |
+
type: external_wc_data_["QUERY_DEFAULTS"].noteTypes,
|
1769 |
+
orderby: 'date',
|
1770 |
+
order: 'desc'
|
1771 |
+
};
|
1772 |
+
function isNotesPanelVisible(select) {
|
1773 |
+
const {
|
1774 |
+
getNotes,
|
1775 |
+
getNotesError,
|
1776 |
+
isResolving
|
1777 |
+
} = select(external_wc_data_["NOTES_STORE_NAME"]);
|
1778 |
+
const {
|
1779 |
+
getCurrentUser
|
1780 |
+
} = select(external_wc_data_["USER_STORE_NAME"]);
|
1781 |
+
const userData = getCurrentUser();
|
1782 |
+
const lastRead = parseInt(userData && userData.woocommerce_meta && userData.woocommerce_meta.activity_panel_inbox_last_read, 10);
|
1783 |
+
|
1784 |
+
if (!lastRead) {
|
1785 |
+
return null;
|
1786 |
+
}
|
1787 |
+
|
1788 |
+
getNotes(UNREAD_NOTES_QUERY);
|
1789 |
+
const isError = Boolean(getNotesError('getNotes', [UNREAD_NOTES_QUERY]));
|
1790 |
+
const isRequesting = isResolving('getNotes', [UNREAD_NOTES_QUERY]);
|
1791 |
+
|
1792 |
+
if (isError || isRequesting) {
|
1793 |
+
return null;
|
1794 |
+
}
|
1795 |
+
|
1796 |
+
const latestNotes = getNotes(UNREAD_NOTES_QUERY);
|
1797 |
+
const unreadNotesCount = Object(inbox_panel_utils["a" /* getUnreadNotesCount */])(latestNotes, lastRead);
|
1798 |
+
return unreadNotesCount > 0;
|
1799 |
+
}
|
1800 |
+
function getLowStockCount() {
|
1801 |
+
return Object(build_module["f" /* getSetting */])('lowStockCount', 0);
|
1802 |
+
}
|
1803 |
+
// CONCATENATED MODULE: ./client/header/activity-panel/tab/index.js
|
1804 |
+
|
1805 |
+
|
1806 |
+
/**
|
1807 |
+
* External dependencies
|
1808 |
+
*/
|
1809 |
+
|
1810 |
+
|
1811 |
+
|
1812 |
+
const Tab = ({
|
1813 |
+
icon,
|
1814 |
+
title,
|
1815 |
+
name,
|
1816 |
+
unread,
|
1817 |
+
selected,
|
1818 |
+
isPanelOpen,
|
1819 |
+
onTabClick
|
1820 |
+
}) => {
|
1821 |
+
const className = classnames_default()('woocommerce-layout__activity-panel-tab', {
|
1822 |
+
'is-active': isPanelOpen && selected,
|
1823 |
+
'has-unread': unread
|
1824 |
+
});
|
1825 |
+
const tabKey = `activity-panel-tab-${name}`;
|
1826 |
+
return Object(external_wp_element_["createElement"])(external_wp_components_["Button"], {
|
1827 |
+
role: "tab",
|
1828 |
+
className: className,
|
1829 |
+
"aria-selected": selected,
|
1830 |
+
"aria-controls": `activity-panel-${name}`,
|
1831 |
+
key: tabKey,
|
1832 |
+
id: tabKey,
|
1833 |
+
onClick: () => {
|
1834 |
+
onTabClick(name);
|
1835 |
+
}
|
1836 |
+
}, icon, title, ' ', unread && Object(external_wp_element_["createElement"])("span", {
|
1837 |
+
className: "screen-reader-text"
|
1838 |
+
}, Object(external_wp_i18n_["__"])('unread activity', 'woocommerce-admin')));
|
1839 |
+
};
|
1840 |
+
// CONCATENATED MODULE: ./client/header/activity-panel/tabs/index.js
|
1841 |
+
|
1842 |
+
|
1843 |
+
|
1844 |
+
/**
|
1845 |
+
* External dependencies
|
1846 |
+
*/
|
1847 |
+
|
1848 |
+
|
1849 |
+
|
1850 |
+
/**
|
1851 |
+
* Internal dependencies
|
1852 |
+
*/
|
1853 |
+
|
1854 |
+
|
1855 |
+
const Tabs = ({
|
1856 |
+
tabs,
|
1857 |
+
onTabClick,
|
1858 |
+
selectedTab: selectedTabName,
|
1859 |
+
tabOpen = false
|
1860 |
+
}) => {
|
1861 |
+
const [{
|
1862 |
+
tabOpen: tabIsOpenState,
|
1863 |
+
currentTab
|
1864 |
+
}, setTabState] = Object(external_wp_element_["useState"])({
|
1865 |
+
tabOpen,
|
1866 |
+
currentTab: selectedTabName
|
1867 |
+
}); // Keep state synced with props
|
1868 |
+
|
1869 |
+
Object(external_wp_element_["useEffect"])(() => {
|
1870 |
+
setTabState({
|
1871 |
+
tabOpen,
|
1872 |
+
currentTab: selectedTabName
|
1873 |
+
});
|
1874 |
+
}, [tabOpen, selectedTabName]);
|
1875 |
+
return Object(external_wp_element_["createElement"])(external_wp_components_["NavigableMenu"], {
|
1876 |
+
role: "tablist",
|
1877 |
+
orientation: "horizontal",
|
1878 |
+
className: "woocommerce-layout__activity-panel-tabs"
|
1879 |
+
}, tabs && tabs.map((tab, i) => {
|
1880 |
+
if (tab.component) {
|
1881 |
+
const {
|
1882 |
+
component: Comp,
|
1883 |
+
options
|
1884 |
+
} = tab;
|
1885 |
+
return Object(external_wp_element_["createElement"])(Comp, extends_default()({
|
1886 |
+
key: i
|
1887 |
+
}, options));
|
1888 |
+
}
|
1889 |
+
|
1890 |
+
return Object(external_wp_element_["createElement"])(Tab, extends_default()({
|
1891 |
+
key: i,
|
1892 |
+
index: i,
|
1893 |
+
isPanelOpen: tabIsOpenState,
|
1894 |
+
selected: currentTab === tab.name
|
1895 |
+
}, tab, {
|
1896 |
+
onTabClick: () => {
|
1897 |
+
const isTabOpen = currentTab === tab.name || currentTab === '' ? !tabIsOpenState : true; // If a panel is being opened, or if an existing panel is already open and a different one is being opened, record a track.
|
1898 |
+
|
1899 |
+
if (!isTabOpen || currentTab !== tab.name) {
|
1900 |
+
Object(external_wc_tracks_["recordEvent"])('activity_panel_open', {
|
1901 |
+
tab: tab.name
|
1902 |
+
});
|
1903 |
+
}
|
1904 |
+
|
1905 |
+
setTabState({
|
1906 |
+
tabOpen: isTabOpen,
|
1907 |
+
currentTab: tab.name
|
1908 |
+
});
|
1909 |
+
onTabClick(tab, isTabOpen);
|
1910 |
+
}
|
1911 |
+
}));
|
1912 |
+
}));
|
1913 |
+
};
|
1914 |
+
// CONCATENATED MODULE: ./client/header/activity-panel/setup-progress.js
|
1915 |
+
|
1916 |
+
const SetupProgress = () => Object(external_wp_element_["createElement"])("svg", {
|
1917 |
+
className: "woocommerce-layout__activity-panel-tab-icon setup-progress",
|
1918 |
+
width: "18",
|
1919 |
+
height: "18",
|
1920 |
+
viewBox: "0 0 24 24",
|
1921 |
+
fill: "none",
|
1922 |
+
xmlns: "http://www.w3.org/2000/svg"
|
1923 |
+
}, Object(external_wp_element_["createElement"])("path", {
|
1924 |
+
d: "M12 20C16.4183 20 20 16.4183 20 12C20 7.58172 16.4183 4 12 4C7.58172 4 4 7.58172 4 12C4 16.4183 7.58172 20 12 20Z",
|
1925 |
+
stroke: "#DCDCDE",
|
1926 |
+
strokeWidth: "2"
|
1927 |
+
}), Object(external_wp_element_["createElement"])("path", {
|
1928 |
+
d: "M4 12V12C4 16.4183 7.58172 20 12 20V20C16.4183 20 20 16.4183 20 12V12C20 7.58172 16.4183 4 12 4V4",
|
1929 |
+
strokeWidth: "2",
|
1930 |
+
strokeLinecap: "round"
|
1931 |
+
}));
|
1932 |
+
// CONCATENATED MODULE: ./client/header/activity-panel/icon-flag.js
|
1933 |
+
|
1934 |
+
const IconFlag = () => Object(external_wp_element_["createElement"])("svg", {
|
1935 |
+
width: "24",
|
1936 |
+
height: "24",
|
1937 |
+
viewBox: "0 0 24 24",
|
1938 |
+
fill: "none",
|
1939 |
+
xmlns: "http://www.w3.org/2000/svg"
|
1940 |
+
}, Object(external_wp_element_["createElement"])("mask", {
|
1941 |
+
id: "mask0_2915:6733",
|
1942 |
+
maskUnits: "userSpaceOnUse",
|
1943 |
+
x: "4",
|
1944 |
+
y: "3",
|
1945 |
+
width: "16",
|
1946 |
+
height: "18"
|
1947 |
+
}, Object(external_wp_element_["createElement"])("path", {
|
1948 |
+
fillRule: "evenodd",
|
1949 |
+
clipRule: "evenodd",
|
1950 |
+
d: "M4.5 3.5H13.5L13.9 5.5H19.5V15.5H12.5L12.1 13.5H6.5V20.5H4.5V3.5ZM12.26 7.5L11.86 5.5H6.5V11.5H13.74L14.14 13.5H17.5V7.5H12.26Z",
|
1951 |
+
fill: "white"
|
1952 |
+
})), Object(external_wp_element_["createElement"])("g", {
|
1953 |
+
mask: "url(#mask0_2915:6733)"
|
1954 |
+
}, Object(external_wp_element_["createElement"])("rect", {
|
1955 |
+
width: "24",
|
1956 |
+
height: "24",
|
1957 |
+
fill: "#50575E"
|
1958 |
+
})));
|
1959 |
+
// EXTERNAL MODULE: ./client/header/activity-panel/display-options/index.js + 3 modules
|
1960 |
+
var display_options = __webpack_require__(170);
|
1961 |
+
|
1962 |
+
// EXTERNAL MODULE: ./node_modules/@wordpress/icons/build-module/library/close.js
|
1963 |
+
var library_close = __webpack_require__(499);
|
1964 |
+
|
1965 |
+
// EXTERNAL MODULE: ./client/header/activity-panel/highlight-tooltip/style.scss
|
1966 |
+
var highlight_tooltip_style = __webpack_require__(288);
|
1967 |
+
|
1968 |
+
// CONCATENATED MODULE: ./client/header/activity-panel/highlight-tooltip/index.js
|
1969 |
+
|
1970 |
+
|
1971 |
+
/**
|
1972 |
+
* External dependencies
|
1973 |
+
*/
|
1974 |
+
|
1975 |
+
|
1976 |
+
|
1977 |
+
|
1978 |
+
|
1979 |
+
|
1980 |
+
/**
|
1981 |
+
* Internal dependencies
|
1982 |
+
*/
|
1983 |
+
|
1984 |
+
|
1985 |
+
const SHOW_CLASS = 'highlight-tooltip__show';
|
1986 |
+
|
1987 |
+
function HighlightTooltip({
|
1988 |
+
title,
|
1989 |
+
closeButtonText,
|
1990 |
+
content,
|
1991 |
+
show = true,
|
1992 |
+
id,
|
1993 |
+
onClose,
|
1994 |
+
delay,
|
1995 |
+
onShow = external_lodash_["noop"],
|
1996 |
+
useAnchor = false
|
1997 |
+
}) {
|
1998 |
+
const [showHighlight, setShowHighlight] = Object(external_wp_element_["useState"])(delay > 0 ? null : show);
|
1999 |
+
const [node, setNode] = Object(external_wp_element_["useState"])(null);
|
2000 |
+
const [anchorRect, setAnchorRect] = Object(external_wp_element_["useState"])(null);
|
2001 |
+
Object(external_wp_element_["useEffect"])(() => {
|
2002 |
+
const element = document.getElementById(id);
|
2003 |
+
let container, parent;
|
2004 |
+
|
2005 |
+
if (element && !node) {
|
2006 |
+
// Add tooltip container
|
2007 |
+
if (!useAnchor) {
|
2008 |
+
parent = element.parentElement;
|
2009 |
+
} else {
|
2010 |
+
parent = document.createElement('div');
|
2011 |
+
document.body.appendChild(parent);
|
2012 |
+
}
|
2013 |
+
|
2014 |
+
container = document.createElement('div');
|
2015 |
+
container.classList.add('highlight-tooltip__container');
|
2016 |
+
parent.appendChild(container);
|
2017 |
+
setNode(container);
|
2018 |
+
}
|
2019 |
+
|
2020 |
+
const timeoutId = triggerShowTooltip(container);
|
2021 |
+
return () => {
|
2022 |
+
if (container) {
|
2023 |
+
const parentElement = container.parentElement;
|
2024 |
+
parentElement.removeChild(container);
|
2025 |
+
|
2026 |
+
if (useAnchor) {
|
2027 |
+
parentElement.remove();
|
2028 |
+
}
|
2029 |
+
}
|
2030 |
+
|
2031 |
+
if (timeoutId) {
|
2032 |
+
clearTimeout(timeoutId);
|
2033 |
+
}
|
2034 |
+
};
|
2035 |
+
}, []);
|
2036 |
+
Object(external_wp_element_["useEffect"])(() => {
|
2037 |
+
if (!showHighlight && node) {
|
2038 |
+
node.classList.remove(SHOW_CLASS);
|
2039 |
+
}
|
2040 |
+
}, [showHighlight]);
|
2041 |
+
Object(external_wp_element_["useEffect"])(() => {
|
2042 |
+
if (show !== showHighlight && showHighlight !== null && node) {
|
2043 |
+
setShowHighlight(show);
|
2044 |
+
|
2045 |
+
if (!show) {
|
2046 |
+
node.classList.remove(SHOW_CLASS);
|
2047 |
+
} else if (node) {
|
2048 |
+
triggerShowTooltip(node);
|
2049 |
+
}
|
2050 |
+
}
|
2051 |
+
}, [show]);
|
2052 |
+
Object(external_wp_element_["useLayoutEffect"])(() => {
|
2053 |
+
window.addEventListener('resize', updateSize);
|
2054 |
+
return () => window.removeEventListener('resize', updateSize);
|
2055 |
+
}, []);
|
2056 |
+
|
2057 |
+
function updateSize() {
|
2058 |
+
if (useAnchor) {
|
2059 |
+
const element = document.getElementById(id);
|
2060 |
+
setAnchorRect(element.getBoundingClientRect());
|
2061 |
+
}
|
2062 |
+
}
|
2063 |
+
|
2064 |
+
const triggerShowTooltip = container => {
|
2065 |
+
let timeoutId = null;
|
2066 |
+
|
2067 |
+
if (delay > 0) {
|
2068 |
+
timeoutId = setTimeout(() => {
|
2069 |
+
timeoutId = null;
|
2070 |
+
showTooltip(container);
|
2071 |
+
}, delay);
|
2072 |
+
} else if (!showHighlight) {
|
2073 |
+
showTooltip(container);
|
2074 |
+
}
|
2075 |
+
|
2076 |
+
return timeoutId;
|
2077 |
+
};
|
2078 |
+
|
2079 |
+
const showTooltip = container => {
|
2080 |
+
const element = document.getElementById(id);
|
2081 |
+
|
2082 |
+
if (element && useAnchor) {
|
2083 |
+
setAnchorRect(element.getBoundingClientRect());
|
2084 |
+
}
|
2085 |
+
|
2086 |
+
if (container) {
|
2087 |
+
container.classList.add(SHOW_CLASS);
|
2088 |
+
}
|
2089 |
+
|
2090 |
+
setShowHighlight(true);
|
2091 |
+
onShow();
|
2092 |
+
};
|
2093 |
+
|
2094 |
+
const triggerClose = () => {
|
2095 |
+
setShowHighlight(false);
|
2096 |
+
|
2097 |
+
if (onClose) {
|
2098 |
+
onClose();
|
2099 |
+
}
|
2100 |
+
};
|
2101 |
+
|
2102 |
+
if (!node) {
|
2103 |
+
return null;
|
2104 |
+
}
|
2105 |
+
|
2106 |
+
return Object(external_wp_element_["createPortal"])(Object(external_wp_element_["createElement"])("div", {
|
2107 |
+
className: "highlight-tooltip__portal"
|
2108 |
+
}, showHighlight ? Object(external_wp_element_["createElement"])(external_wp_element_["Fragment"], null, Object(external_wp_element_["createElement"])(external_wp_components_["IsolatedEventContainer"], {
|
2109 |
+
className: "highlight-tooltip__overlay"
|
2110 |
+
}), Object(external_wp_element_["createElement"])(external_wp_components_["Popover"], {
|
2111 |
+
className: "highlight-tooltip__popover",
|
2112 |
+
noArrow: false,
|
2113 |
+
anchorRect: anchorRect,
|
2114 |
+
focusOnMount: "container"
|
2115 |
+
}, Object(external_wp_element_["createElement"])(external_wp_components_["Card"], {
|
2116 |
+
size: "medium"
|
2117 |
+
}, Object(external_wp_element_["createElement"])(external_wp_components_["CardHeader"], null, title, Object(external_wp_element_["createElement"])(external_wp_components_["Button"], {
|
2118 |
+
isSmall: true,
|
2119 |
+
onClick: triggerClose,
|
2120 |
+
icon: library_close["a" /* default */]
|
2121 |
+
})), Object(external_wp_element_["createElement"])(external_wp_components_["CardBody"], null, content || null), Object(external_wp_element_["createElement"])(external_wp_components_["CardFooter"], {
|
2122 |
+
isBorderless: true
|
2123 |
+
}, Object(external_wp_element_["createElement"])(external_wp_components_["Button"], {
|
2124 |
+
size: "small",
|
2125 |
+
isPrimary: true,
|
2126 |
+
onClick: triggerClose
|
2127 |
+
}, closeButtonText || Object(external_wp_i18n_["__"])('Close', 'woocommerce-admin')))))) : null), node);
|
2128 |
+
}
|
2129 |
+
|
2130 |
+
HighlightTooltip.propTypes = {
|
2131 |
+
/**
|
2132 |
+
* The id of the element it should highlight, should be unique per HighlightTooltip.
|
2133 |
+
*/
|
2134 |
+
id: prop_types_default.a.string.isRequired,
|
2135 |
+
|
2136 |
+
/**
|
2137 |
+
* Title of the popup
|
2138 |
+
*/
|
2139 |
+
title: prop_types_default.a.string.isRequired,
|
2140 |
+
|
2141 |
+
/**
|
2142 |
+
* Text of the close button.
|
2143 |
+
*/
|
2144 |
+
closeButtonText: prop_types_default.a.string.isRequired,
|
2145 |
+
|
2146 |
+
/**
|
2147 |
+
* Content of the popup, can be either text or react element.
|
2148 |
+
*/
|
2149 |
+
content: prop_types_default.a.oneOfType([prop_types_default.a.string, prop_types_default.a.node]),
|
2150 |
+
|
2151 |
+
/**
|
2152 |
+
* If to show the popup, defaults to true.
|
2153 |
+
*/
|
2154 |
+
show: prop_types_default.a.bool,
|
2155 |
+
|
2156 |
+
/**
|
2157 |
+
* Callback for when the user closes the popup.
|
2158 |
+
*/
|
2159 |
+
onClose: prop_types_default.a.func,
|
2160 |
+
|
2161 |
+
/**
|
2162 |
+
* This will delay the popup from appearing by the number of ms.
|
2163 |
+
*/
|
2164 |
+
delay: prop_types_default.a.number,
|
2165 |
+
|
2166 |
+
/**
|
2167 |
+
* A callback for when the tooltip is shown.
|
2168 |
+
*/
|
2169 |
+
onShow: prop_types_default.a.func,
|
2170 |
+
|
2171 |
+
/**
|
2172 |
+
* useAnchor, will append the tooltip to the body tag, and make use of the anchorRect to display the tooltip.
|
2173 |
+
* Defaults to false.
|
2174 |
+
*/
|
2175 |
+
useAnchor: prop_types_default.a.bool
|
2176 |
+
};
|
2177 |
+
|
2178 |
+
// EXTERNAL MODULE: external ["wp","dom"]
|
2179 |
+
var external_wp_dom_ = __webpack_require__(91);
|
2180 |
+
|
2181 |
+
// CONCATENATED MODULE: ./client/hooks/useFocusOnMount.js
|
2182 |
+
/**
|
2183 |
+
* This hook was directly copied from https://github.com/WordPress/gutenberg/blob/master/packages/compose/src/hooks/use-focus-on-mount/index.js
|
2184 |
+
* to avoid its absence in older versions of WordPress.
|
2185 |
+
*
|
2186 |
+
* This can be removed once the minimum supported version of WordPress includes this hook.
|
2187 |
+
*/
|
2188 |
+
|
2189 |
+
/**
|
2190 |
+
* External dependencies
|
2191 |
+
*/
|
2192 |
+
|
2193 |
+
|
2194 |
+
/**
|
2195 |
+
* Hook used to focus the first tabbable element on mount.
|
2196 |
+
*
|
2197 |
+
* @param {boolean|string} focusOnMount Focus on mount mode.
|
2198 |
+
* @return {Function} Ref callback.
|
2199 |
+
*
|
2200 |
+
* @example
|
2201 |
+
* ```js
|
2202 |
+
* import { useFocusOnMount } from '@wordpress/compose';
|
2203 |
+
*
|
2204 |
+
* const WithFocusOnMount = () => {
|
2205 |
+
* const ref = useFocusOnMount()
|
2206 |
+
* return (
|
2207 |
+
* <div ref={ ref }>
|
2208 |
+
* <Button />
|
2209 |
+
* <Button />
|
2210 |
+
* </div>
|
2211 |
+
* );
|
2212 |
+
* }
|
2213 |
+
* ```
|
2214 |
+
*/
|
2215 |
+
|
2216 |
+
function useFocusOnMount(focusOnMount = 'firstElement') {
|
2217 |
+
const focusOnMountRef = Object(external_wp_element_["useRef"])(focusOnMount);
|
2218 |
+
Object(external_wp_element_["useEffect"])(() => {
|
2219 |
+
focusOnMountRef.current = focusOnMount;
|
2220 |
+
}, [focusOnMount]);
|
2221 |
+
return Object(external_wp_element_["useCallback"])(node => {
|
2222 |
+
if (!node || focusOnMountRef.current === false) {
|
2223 |
+
return;
|
2224 |
+
}
|
2225 |
+
|
2226 |
+
if (node.contains(node.ownerDocument.activeElement)) {
|
2227 |
+
return;
|
2228 |
+
}
|
2229 |
+
|
2230 |
+
let target = node;
|
2231 |
+
|
2232 |
+
if (focusOnMountRef.current === 'firstElement') {
|
2233 |
+
const firstTabbable = external_wp_dom_["focus"].tabbable.find(node)[0];
|
2234 |
+
|
2235 |
+
if (firstTabbable) {
|
2236 |
+
target = firstTabbable;
|
2237 |
+
}
|
2238 |
+
}
|
2239 |
+
|
2240 |
+
target.focus();
|
2241 |
+
}, []);
|
2242 |
+
}
|
2243 |
+
// CONCATENATED MODULE: ./client/hooks/useFocusOutside.js
|
2244 |
+
/**
|
2245 |
+
* External dependencies
|
2246 |
+
*/
|
2247 |
+
|
2248 |
+
|
2249 |
+
/**
|
2250 |
+
* Input types which are classified as button types, for use in considering
|
2251 |
+
* whether element is a (focus-normalized) button.
|
2252 |
+
*
|
2253 |
+
* @type {string[]}
|
2254 |
+
*/
|
2255 |
+
|
2256 |
+
const INPUT_BUTTON_TYPES = ['button', 'submit'];
|
2257 |
+
/**
|
2258 |
+
* @typedef {HTMLButtonElement | HTMLLinkElement | HTMLInputElement} FocusNormalizedButton
|
2259 |
+
*/
|
2260 |
+
// Disable reason: Rule doesn't support predicate return types
|
2261 |
+
|
2262 |
+
/* eslint-disable jsdoc/valid-types */
|
2263 |
+
|
2264 |
+
/**
|
2265 |
+
* Returns true if the given element is a button element subject to focus
|
2266 |
+
* normalization, or false otherwise.
|
2267 |
+
*
|
2268 |
+
* @see https://developer.mozilla.org/en-US/docs/Web/HTML/Element/button#Clicking_and_focus
|
2269 |
+
*
|
2270 |
+
* @param {EventTarget} eventTarget The target from a mouse or touch event.
|
2271 |
+
*
|
2272 |
+
* @return {eventTarget is FocusNormalizedButton} Whether element is a button.
|
2273 |
+
*/
|
2274 |
+
|
2275 |
+
function isFocusNormalizedButton(eventTarget) {
|
2276 |
+
if (!(eventTarget instanceof window.HTMLElement)) {
|
2277 |
+
return false;
|
2278 |
+
}
|
2279 |
+
|
2280 |
+
switch (eventTarget.nodeName) {
|
2281 |
+
case 'A':
|
2282 |
+
case 'BUTTON':
|
2283 |
+
return true;
|
2284 |
+
|
2285 |
+
case 'INPUT':
|
2286 |
+
return Object(external_lodash_["includes"])(INPUT_BUTTON_TYPES,
|
2287 |
+
/** @type {HTMLInputElement} */
|
2288 |
+
eventTarget.type);
|
2289 |
+
}
|
2290 |
+
|
2291 |
+
return false;
|
2292 |
+
}
|
2293 |
+
/* eslint-enable jsdoc/valid-types */
|
2294 |
+
|
2295 |
+
/**
|
2296 |
+
* @typedef {import('react').SyntheticEvent} SyntheticEvent
|
2297 |
+
*/
|
2298 |
+
|
2299 |
+
/**
|
2300 |
+
* @callback EventCallback
|
2301 |
+
* @param {SyntheticEvent} event input related event.
|
2302 |
+
*/
|
2303 |
+
|
2304 |
+
/**
|
2305 |
+
* @typedef FocusOutsideReactElement
|
2306 |
+
* @property {EventCallback} handleFocusOutside callback for a focus outside event.
|
2307 |
+
*/
|
2308 |
+
|
2309 |
+
/**
|
2310 |
+
* @typedef {import('react').MutableRefObject<FocusOutsideReactElement | undefined>} FocusOutsideRef
|
2311 |
+
*/
|
2312 |
+
|
2313 |
+
/**
|
2314 |
+
* @typedef {Object} FocusOutsideReturnValue
|
2315 |
+
* @property {EventCallback} onFocus An event handler for focus events.
|
2316 |
+
* @property {EventCallback} onBlur An event handler for blur events.
|
2317 |
+
* @property {EventCallback} onMouseDown An event handler for mouse down events.
|
2318 |
+
* @property {EventCallback} onMouseUp An event handler for mouse up events.
|
2319 |
+
* @property {EventCallback} onTouchStart An event handler for touch start events.
|
2320 |
+
* @property {EventCallback} onTouchEnd An event handler for touch end events.
|
2321 |
+
*/
|
2322 |
+
|
2323 |
+
/**
|
2324 |
+
* A react hook that can be used to check whether focus has moved outside the
|
2325 |
+
* element the event handlers are bound to.
|
2326 |
+
*
|
2327 |
+
* @param {EventCallback} onFocusOutside A callback triggered when focus moves outside
|
2328 |
+
* the element the event handlers are bound to.
|
2329 |
+
*
|
2330 |
+
* @return {FocusOutsideReturnValue} An object containing event handlers. Bind the event handlers
|
2331 |
+
* to a wrapping element element to capture when focus moves
|
2332 |
+
* outside that element.
|
2333 |
+
*/
|
2334 |
+
|
2335 |
+
|
2336 |
+
function useFocusOutside(onFocusOutside) {
|
2337 |
+
const currentOnFocusOutside = Object(external_wp_element_["useRef"])(onFocusOutside);
|
2338 |
+
Object(external_wp_element_["useEffect"])(() => {
|
2339 |
+
currentOnFocusOutside.current = onFocusOutside;
|
2340 |
+
}, [onFocusOutside]);
|
2341 |
+
const preventBlurCheck = Object(external_wp_element_["useRef"])(false);
|
2342 |
+
/**
|
2343 |
+
* @type {import('react').MutableRefObject<number | undefined>}
|
2344 |
+
*/
|
2345 |
+
|
2346 |
+
const blurCheckTimeoutId = Object(external_wp_element_["useRef"])();
|
2347 |
+
/**
|
2348 |
+
* Cancel a blur check timeout.
|
2349 |
+
*/
|
2350 |
+
|
2351 |
+
const cancelBlurCheck = Object(external_wp_element_["useCallback"])(() => {
|
2352 |
+
clearTimeout(blurCheckTimeoutId.current);
|
2353 |
+
}, []); // Cancel blur checks on unmount.
|
2354 |
+
|
2355 |
+
Object(external_wp_element_["useEffect"])(() => {
|
2356 |
+
return () => cancelBlurCheck();
|
2357 |
+
}, []); // Cancel a blur check if the callback or ref is no longer provided.
|
2358 |
+
|
2359 |
+
Object(external_wp_element_["useEffect"])(() => {
|
2360 |
+
if (!onFocusOutside) {
|
2361 |
+
cancelBlurCheck();
|
2362 |
+
}
|
2363 |
+
}, [onFocusOutside, cancelBlurCheck]);
|
2364 |
+
/**
|
2365 |
+
* Handles a mousedown or mouseup event to respectively assign and
|
2366 |
+
* unassign a flag for preventing blur check on button elements. Some
|
2367 |
+
* browsers, namely Firefox and Safari, do not emit a focus event on
|
2368 |
+
* button elements when clicked, while others do. The logic here
|
2369 |
+
* intends to normalize this as treating click on buttons as focus.
|
2370 |
+
*
|
2371 |
+
* @see https://developer.mozilla.org/en-US/docs/Web/HTML/Element/button#Clicking_and_focus
|
2372 |
+
*
|
2373 |
+
* @param {SyntheticEvent} event Event for mousedown or mouseup.
|
2374 |
+
*/
|
2375 |
+
|
2376 |
+
const normalizeButtonFocus = Object(external_wp_element_["useCallback"])(event => {
|
2377 |
+
const {
|
2378 |
+
type,
|
2379 |
+
target
|
2380 |
+
} = event;
|
2381 |
+
const isInteractionEnd = Object(external_lodash_["includes"])(['mouseup', 'touchend'], type);
|
2382 |
+
|
2383 |
+
if (isInteractionEnd) {
|
2384 |
+
preventBlurCheck.current = false;
|
2385 |
+
} else if (isFocusNormalizedButton(target)) {
|
2386 |
+
preventBlurCheck.current = true;
|
2387 |
+
}
|
2388 |
+
}, []);
|
2389 |
+
/**
|
2390 |
+
* A callback triggered when a blur event occurs on the element the handler
|
2391 |
+
* is bound to.
|
2392 |
+
*
|
2393 |
+
* Calls the `onFocusOutside` callback in an immediate timeout if focus has
|
2394 |
+
* move outside the bound element and is still within the document.
|
2395 |
+
*
|
2396 |
+
* @param {SyntheticEvent} event Blur event.
|
2397 |
+
*/
|
2398 |
+
|
2399 |
+
const queueBlurCheck = Object(external_wp_element_["useCallback"])(event => {
|
2400 |
+
// React does not allow using an event reference asynchronously
|
2401 |
+
// due to recycling behavior, except when explicitly persisted.
|
2402 |
+
event.persist(); // Skip blur check if clicking button. See `normalizeButtonFocus`.
|
2403 |
+
|
2404 |
+
if (preventBlurCheck.current) {
|
2405 |
+
return;
|
2406 |
+
}
|
2407 |
+
|
2408 |
+
blurCheckTimeoutId.current = setTimeout(() => {
|
2409 |
+
// If document is not focused then focus should remain
|
2410 |
+
// inside the wrapped component and therefore we cancel
|
2411 |
+
// this blur event thereby leaving focus in place.
|
2412 |
+
// https://developer.mozilla.org/en-US/docs/Web/API/Document/hasFocus.
|
2413 |
+
if (!document.hasFocus()) {
|
2414 |
+
event.preventDefault();
|
2415 |
+
return;
|
2416 |
+
}
|
2417 |
+
|
2418 |
+
if (typeof currentOnFocusOutside.current === 'function') {
|
2419 |
+
currentOnFocusOutside.current(event);
|
2420 |
+
}
|
2421 |
+
}, 0);
|
2422 |
+
}, []);
|
2423 |
+
return {
|
2424 |
+
onFocus: cancelBlurCheck,
|
2425 |
+
onMouseDown: normalizeButtonFocus,
|
2426 |
+
onMouseUp: normalizeButtonFocus,
|
2427 |
+
onTouchStart: normalizeButtonFocus,
|
2428 |
+
onTouchEnd: normalizeButtonFocus,
|
2429 |
+
onBlur: queueBlurCheck
|
2430 |
+
};
|
2431 |
+
}
|
2432 |
+
// CONCATENATED MODULE: ./client/header/activity-panel/panel.js
|
2433 |
+
|
2434 |
+
|
2435 |
+
|
2436 |
+
/**
|
2437 |
+
* External dependencies
|
2438 |
+
*/
|
2439 |
+
|
2440 |
+
|
2441 |
+
|
2442 |
+
/**
|
2443 |
+
* Internal dependencies
|
2444 |
+
*/
|
2445 |
+
|
2446 |
+
|
2447 |
+
|
2448 |
+
const Panel = ({
|
2449 |
+
content,
|
2450 |
+
isPanelOpen,
|
2451 |
+
isPanelSwitching,
|
2452 |
+
currentTab,
|
2453 |
+
tab,
|
2454 |
+
closePanel,
|
2455 |
+
clearPanel
|
2456 |
+
}) => {
|
2457 |
+
const panelClass = 'woocommerce-layout__activity-panel-wrapper';
|
2458 |
+
|
2459 |
+
const handleFocusOutside = event => {
|
2460 |
+
const isClickOnModalOrSnackbar = event.relatedTarget && (event.relatedTarget.closest('.woocommerce-inbox-dismiss-confirmation_modal') || event.relatedTarget.closest('.components-snackbar__action'));
|
2461 |
+
|
2462 |
+
if (isPanelOpen && !isClickOnModalOrSnackbar) {
|
2463 |
+
closePanel();
|
2464 |
+
}
|
2465 |
+
};
|
2466 |
+
|
2467 |
+
const possibleFocusPanel = () => {
|
2468 |
+
if (!containerRef.current || !isPanelOpen || !tab) {
|
2469 |
+
return;
|
2470 |
+
}
|
2471 |
+
|
2472 |
+
focusOnMountRef(containerRef.current);
|
2473 |
+
};
|
2474 |
+
|
2475 |
+
const finishTransition = e => {
|
2476 |
+
if (e && e.propertyName === 'transform') {
|
2477 |
+
clearPanel();
|
2478 |
+
possibleFocusPanel();
|
2479 |
+
}
|
2480 |
+
};
|
2481 |
+
|
2482 |
+
const focusOnMountRef = useFocusOnMount();
|
2483 |
+
const useFocusOutsideProps = useFocusOutside(handleFocusOutside);
|
2484 |
+
const containerRef = Object(external_wp_element_["useRef"])(null);
|
2485 |
+
const mergedContainerRef = Object(external_wp_element_["useCallback"])(node => {
|
2486 |
+
containerRef.current = node;
|
2487 |
+
focusOnMountRef(node);
|
2488 |
+
}, []);
|
2489 |
+
|
2490 |
+
if (!tab) {
|
2491 |
+
return Object(external_wp_element_["createElement"])("div", {
|
2492 |
+
className: panelClass
|
2493 |
+
});
|
2494 |
+
}
|
2495 |
+
|
2496 |
+
if (!content) {
|
2497 |
+
return null;
|
2498 |
+
}
|
2499 |
+
|
2500 |
+
const classNames = classnames_default()(panelClass, {
|
2501 |
+
'is-open': isPanelOpen,
|
2502 |
+
'is-switching': isPanelSwitching
|
2503 |
+
});
|
2504 |
+
return Object(external_wp_element_["createElement"])("div", extends_default()({
|
2505 |
+
className: classNames,
|
2506 |
+
tabIndex: 0,
|
2507 |
+
role: "tabpanel",
|
2508 |
+
"aria-label": tab.title,
|
2509 |
+
onTransitionEnd: finishTransition
|
2510 |
+
}, useFocusOutsideProps, {
|
2511 |
+
ref: mergedContainerRef
|
2512 |
+
}), Object(external_wp_element_["createElement"])("div", {
|
2513 |
+
className: "woocommerce-layout__activity-panel-content",
|
2514 |
+
key: 'activity-panel-' + currentTab,
|
2515 |
+
id: 'activity-panel-' + currentTab
|
2516 |
+
}, Object(external_wp_element_["createElement"])(external_wp_element_["Suspense"], {
|
2517 |
+
fallback: Object(external_wp_element_["createElement"])(external_wc_components_["Spinner"], null)
|
2518 |
+
}, content)));
|
2519 |
+
};
|
2520 |
+
/* harmony default export */ var panel = (Panel);
|
2521 |
+
// EXTERNAL MODULE: ./client/homescreen/activity-panel/orders/utils.js
|
2522 |
+
var orders_utils = __webpack_require__(68);
|
2523 |
+
|
2524 |
+
// EXTERNAL MODULE: ./client/homescreen/activity-panel/reviews/utils.js
|
2525 |
+
var reviews_utils = __webpack_require__(103);
|
2526 |
+
|
2527 |
+
// EXTERNAL MODULE: ./client/header/activity-panel/panels/inbox/abbreviated-notifications-panel.js + 2 modules
|
2528 |
+
var abbreviated_notifications_panel = __webpack_require__(255);
|
2529 |
+
|
2530 |
+
// CONCATENATED MODULE: ./client/header/activity-panel/index.js
|
2531 |
+
|
2532 |
+
|
2533 |
+
/**
|
2534 |
+
* External dependencies
|
2535 |
+
*/
|
2536 |
+
|
2537 |
+
|
2538 |
+
|
2539 |
+
|
2540 |
+
|
2541 |
+
|
2542 |
+
|
2543 |
+
|
2544 |
+
|
2545 |
+
|
2546 |
+
|
2547 |
+
/**
|
2548 |
+
* Internal dependencies
|
2549 |
+
*/
|
2550 |
+
|
2551 |
+
|
2552 |
+
|
2553 |
+
|
2554 |
+
|
2555 |
+
|
2556 |
+
|
2557 |
+
|
2558 |
+
|
2559 |
+
|
2560 |
+
|
2561 |
+
|
2562 |
+
|
2563 |
+
const HelpPanel = Object(external_wp_element_["lazy"])(() => __webpack_require__.e(/* import() | activity-panels-help */ 3).then(__webpack_require__.bind(null, 633)));
|
2564 |
+
const InboxPanel = Object(external_wp_element_["lazy"])(() => Promise.all(/* import() | activity-panels-inbox */[__webpack_require__.e(2), __webpack_require__.e(4)]).then(__webpack_require__.bind(null, 621)));
|
2565 |
+
const ActivityPanel = ({
|
2566 |
+
isEmbedded,
|
2567 |
+
query,
|
2568 |
+
userPreferencesData
|
2569 |
+
}) => {
|
2570 |
+
const [currentTab, setCurrentTab] = Object(external_wp_element_["useState"])('');
|
2571 |
+
const [isPanelClosing, setIsPanelClosing] = Object(external_wp_element_["useState"])(false);
|
2572 |
+
const [isPanelOpen, setIsPanelOpen] = Object(external_wp_element_["useState"])(false);
|
2573 |
+
const [isPanelSwitching, setIsPanelSwitching] = Object(external_wp_element_["useState"])(false);
|
2574 |
+
const {
|
2575 |
+
fills
|
2576 |
+
} = Object(external_wc_experimental_["useSlot"])(abbreviated_notifications_panel["a" /* ABBREVIATED_NOTIFICATION_SLOT_NAME */]);
|
2577 |
+
const hasExtendedNotifications = Boolean(fills === null || fills === void 0 ? void 0 : fills.length);
|
2578 |
+
|
2579 |
+
const getPreviewSiteBtnTrackData = (select, getOption) => {
|
2580 |
+
let trackData = {};
|
2581 |
+
|
2582 |
+
if (query.page === 'wc-admin' && query.task === 'appearance') {
|
2583 |
+
var _task$additionalData, _task$additionalData2, _task$additionalData3;
|
2584 |
+
|
2585 |
+
const {
|
2586 |
+
getTaskLists
|
2587 |
+
} = select(external_wc_data_["ONBOARDING_STORE_NAME"]);
|
2588 |
+
const taskLists = getTaskLists();
|
2589 |
+
const tasks = taskLists.reduce((acc, taskList) => [...acc, ...taskList.tasks], []);
|
2590 |
+
const task = tasks.find(t => t.id === 'appearance');
|
2591 |
+
const demoNotice = getOption('woocommerce_demo_store_notice');
|
2592 |
+
trackData = {
|
2593 |
+
set_notice: demoNotice ? 'Y' : 'N',
|
2594 |
+
create_homepage: (task === null || task === void 0 ? void 0 : (_task$additionalData = task.additionalData) === null || _task$additionalData === void 0 ? void 0 : _task$additionalData.hasHomepage) === true ? 'Y' : 'N',
|
2595 |
+
upload_logo: task !== null && task !== void 0 && (_task$additionalData2 = task.additionalData) !== null && _task$additionalData2 !== void 0 && (_task$additionalData3 = _task$additionalData2.themeMods) !== null && _task$additionalData3 !== void 0 && _task$additionalData3.custom_logo ? 'Y' : 'N'
|
2596 |
+
};
|
2597 |
+
}
|
2598 |
+
|
2599 |
+
return trackData;
|
2600 |
+
};
|
2601 |
+
|
2602 |
+
function getThingsToDoNextCount(extendedTaskList) {
|
2603 |
+
if (!extendedTaskList || !extendedTaskList.tasks.length || extendedTaskList.isHidden) {
|
2604 |
+
return 0;
|
2605 |
+
}
|
2606 |
+
|
2607 |
+
return extendedTaskList.tasks.filter(task => task.canView && !task.isComplete && !task.isDismissed).length;
|
2608 |
+
}
|
2609 |
+
|
2610 |
+
function isAbbreviatedPanelVisible(select, setupTaskListHidden, thingsToDoNextCount) {
|
2611 |
+
const orderStatuses = Object(orders_utils["c" /* getOrderStatuses */])(select);
|
2612 |
+
const isOrdersCardVisible = setupTaskListHidden && isPanelOpen ? Object(orders_utils["d" /* getUnreadOrders */])(select, orderStatuses) > 0 : false;
|
2613 |
+
const isReviewsCardVisible = setupTaskListHidden && isPanelOpen ? Object(reviews_utils["b" /* getUnapprovedReviews */])(select) : false;
|
2614 |
+
const isLowStockCardVisible = setupTaskListHidden && isPanelOpen ? Object(orders_utils["a" /* getLowStockCount */])(select) : false;
|
2615 |
+
return thingsToDoNextCount > 0 || isOrdersCardVisible || isReviewsCardVisible || isLowStockCardVisible || hasExtendedNotifications;
|
2616 |
+
}
|
2617 |
+
|
2618 |
+
const {
|
2619 |
+
hasUnreadNotes,
|
2620 |
+
hasAbbreviatedNotifications,
|
2621 |
+
isCompletedTask,
|
2622 |
+
thingsToDoNextCount,
|
2623 |
+
requestingTaskListOptions,
|
2624 |
+
setupTaskListComplete,
|
2625 |
+
setupTaskListHidden,
|
2626 |
+
previewSiteBtnTrackData
|
2627 |
+
} = Object(external_wp_data_["useSelect"])(select => {
|
2628 |
+
var _getTaskList, _getTaskList2, _getTask;
|
2629 |
+
|
2630 |
+
const {
|
2631 |
+
getOption
|
2632 |
+
} = select(external_wc_data_["OPTIONS_STORE_NAME"]);
|
2633 |
+
const {
|
2634 |
+
getTask,
|
2635 |
+
getTaskList,
|
2636 |
+
hasFinishedResolution
|
2637 |
+
} = select(external_wc_data_["ONBOARDING_STORE_NAME"]);
|
2638 |
+
const isSetupTaskListHidden = (_getTaskList = getTaskList('setup')) === null || _getTaskList === void 0 ? void 0 : _getTaskList.isHidden;
|
2639 |
+
const extendedTaskList = getTaskList('extended');
|
2640 |
+
const thingsToDoCount = getThingsToDoNextCount(extendedTaskList);
|
2641 |
+
return {
|
2642 |
+
hasUnreadNotes: isNotesPanelVisible(select),
|
2643 |
+
hasAbbreviatedNotifications: isAbbreviatedPanelVisible(select, isSetupTaskListHidden, thingsToDoCount),
|
2644 |
+
thingsToDoNextCount: thingsToDoCount,
|
2645 |
+
requestingTaskListOptions: !hasFinishedResolution('getTaskLists'),
|
2646 |
+
setupTaskListComplete: (_getTaskList2 = getTaskList('setup')) === null || _getTaskList2 === void 0 ? void 0 : _getTaskList2.isComplete,
|
2647 |
+
setupTaskListHidden: isSetupTaskListHidden,
|
2648 |
+
isCompletedTask: Boolean(query.task && ((_getTask = getTask(query.task)) === null || _getTask === void 0 ? void 0 : _getTask.isComplete)),
|
2649 |
+
previewSiteBtnTrackData: getPreviewSiteBtnTrackData(select, getOption)
|
2650 |
+
};
|
2651 |
+
});
|
2652 |
+
const {
|
2653 |
+
unhideTaskList
|
2654 |
+
} = Object(external_wp_data_["useDispatch"])(external_wc_data_["ONBOARDING_STORE_NAME"]);
|
2655 |
+
const {
|
2656 |
+
currentUserCan
|
2657 |
+
} = Object(external_wc_data_["useUser"])();
|
2658 |
+
|
2659 |
+
const togglePanel = ({
|
2660 |
+
name: tabName
|
2661 |
+
}, isTabOpen) => {
|
2662 |
+
const panelSwitching = tabName !== currentTab && currentTab !== '' && isTabOpen && isPanelOpen;
|
2663 |
+
|
2664 |
+
if (isPanelClosing) {
|
2665 |
+
return;
|
2666 |
+
}
|
2667 |
+
|
2668 |
+
setCurrentTab(tabName);
|
2669 |
+
setIsPanelOpen(isTabOpen);
|
2670 |
+
setIsPanelSwitching(panelSwitching);
|
2671 |
+
};
|
2672 |
+
|
2673 |
+
const closePanel = () => {
|
2674 |
+
setIsPanelClosing(true);
|
2675 |
+
setIsPanelOpen(false);
|
2676 |
+
};
|
2677 |
+
|
2678 |
+
const clearPanel = () => {
|
2679 |
+
if (!isPanelOpen) {
|
2680 |
+
setIsPanelClosing(false);
|
2681 |
+
setIsPanelSwitching(false);
|
2682 |
+
setCurrentTab('');
|
2683 |
+
}
|
2684 |
+
};
|
2685 |
+
|
2686 |
+
const isHomescreen = () => {
|
2687 |
+
return query.page === 'wc-admin' && !query.path;
|
2688 |
+
};
|
2689 |
+
|
2690 |
+
const isPerformingSetupTask = () => {
|
2691 |
+
return query.task && !query.path && (requestingTaskListOptions === true || setupTaskListHidden === false && setupTaskListComplete === false);
|
2692 |
+
};
|
2693 |
+
|
2694 |
+
const redirectToHomeScreen = () => {
|
2695 |
+
if (Object(utils["f" /* isWCAdmin */])(window.location.href)) {
|
2696 |
+
Object(external_wc_navigation_["getHistory"])().push(Object(external_wc_navigation_["getNewPath"])({}, '/', {}));
|
2697 |
+
} else {
|
2698 |
+
window.location.href = Object(build_module["e" /* getAdminLink */])('admin.php?page=wc-admin');
|
2699 |
+
}
|
2700 |
+
}; // @todo Pull in dynamic unread status/count
|
2701 |
+
|
2702 |
+
|
2703 |
+
const getTabs = () => {
|
2704 |
+
const activity = {
|
2705 |
+
name: 'activity',
|
2706 |
+
title: Object(external_wp_i18n_["__"])('Activity', 'woocommerce-admin'),
|
2707 |
+
icon: Object(external_wp_element_["createElement"])(IconFlag, null),
|
2708 |
+
unread: hasUnreadNotes || hasAbbreviatedNotifications,
|
2709 |
+
visible: (isEmbedded || !isHomescreen()) && !isPerformingSetupTask()
|
2710 |
+
};
|
2711 |
+
const setup = {
|
2712 |
+
name: 'setup',
|
2713 |
+
title: Object(external_wp_i18n_["__"])('Finish setup', 'woocommerce-admin'),
|
2714 |
+
icon: Object(external_wp_element_["createElement"])(SetupProgress, null),
|
2715 |
+
onClick: () => {
|
2716 |
+
const currentLocation = window.location.href;
|
2717 |
+
const homescreenLocation = Object(build_module["e" /* getAdminLink */])('admin.php?page=wc-admin'); // Don't navigate if we're already on the homescreen, this will cause an infinite loop
|
2718 |
+
|
2719 |
+
if (currentLocation !== homescreenLocation) {
|
2720 |
+
// Ensure that if the user is trying to get to the task list they can see it even if
|
2721 |
+
// it was dismissed.
|
2722 |
+
if (setupTaskListHidden === 'no') {
|
2723 |
+
redirectToHomeScreen();
|
2724 |
+
} else {
|
2725 |
+
unhideTaskList('setup').then(redirectToHomeScreen);
|
2726 |
+
}
|
2727 |
+
}
|
2728 |
+
|
2729 |
+
return null;
|
2730 |
+
},
|
2731 |
+
visible: currentUserCan('manage_woocommerce') && !requestingTaskListOptions && !setupTaskListComplete && !setupTaskListHidden && !isPerformingSetupTask() && (!isHomescreen() || isEmbedded)
|
2732 |
+
};
|
2733 |
+
const help = {
|
2734 |
+
name: 'help',
|
2735 |
+
title: Object(external_wp_i18n_["__"])('Help', 'woocommerce-admin'),
|
2736 |
+
icon: Object(external_wp_element_["createElement"])(build_module_icon["a" /* default */], {
|
2737 |
+
icon: library_help
|
2738 |
+
}),
|
2739 |
+
visible: currentUserCan('manage_woocommerce') && (isHomescreen() && !isEmbedded || isPerformingSetupTask())
|
2740 |
+
};
|
2741 |
+
const displayOptions = {
|
2742 |
+
component: display_options["b" /* DisplayOptions */],
|
2743 |
+
visible: currentUserCan('manage_woocommerce') && !isEmbedded && isHomescreen() && !isPerformingSetupTask()
|
2744 |
+
};
|
2745 |
+
const previewSite = {
|
2746 |
+
name: 'previewSite',
|
2747 |
+
title: Object(external_wp_i18n_["__"])('Preview site', 'woocommerce-admin'),
|
2748 |
+
icon: Object(external_wp_element_["createElement"])(build_module_icon["a" /* default */], {
|
2749 |
+
icon: external["a" /* default */]
|
2750 |
+
}),
|
2751 |
+
visible: query.page === 'wc-admin' && query.task === 'appearance',
|
2752 |
+
onClick: () => {
|
2753 |
+
window.open(Object(build_module["f" /* getSetting */])('siteUrl'));
|
2754 |
+
Object(external_wc_tracks_["recordEvent"])('wcadmin_tasklist_previewsite', previewSiteBtnTrackData);
|
2755 |
+
return null;
|
2756 |
+
}
|
2757 |
+
};
|
2758 |
+
return [activity, setup, previewSite, displayOptions, help].filter(tab => tab.visible);
|
2759 |
+
};
|
2760 |
+
|
2761 |
+
const getPanelContent = tab => {
|
2762 |
+
const {
|
2763 |
+
task
|
2764 |
+
} = query;
|
2765 |
+
|
2766 |
+
switch (tab) {
|
2767 |
+
case 'activity':
|
2768 |
+
return Object(external_wp_element_["createElement"])(InboxPanel, {
|
2769 |
+
hasAbbreviatedNotifications: hasAbbreviatedNotifications,
|
2770 |
+
thingsToDoNextCount: thingsToDoNextCount
|
2771 |
+
});
|
2772 |
+
|
2773 |
+
case 'help':
|
2774 |
+
return Object(external_wp_element_["createElement"])(HelpPanel, {
|
2775 |
+
taskName: task
|
2776 |
+
});
|
2777 |
+
|
2778 |
+
default:
|
2779 |
+
return null;
|
2780 |
+
}
|
2781 |
+
};
|
2782 |
+
|
2783 |
+
const closedHelpPanelHighlight = () => {
|
2784 |
+
Object(external_wc_tracks_["recordEvent"])('help_tooltip_click');
|
2785 |
+
|
2786 |
+
if (userPreferencesData && userPreferencesData.updateUserPreferences) {
|
2787 |
+
userPreferencesData.updateUserPreferences({
|
2788 |
+
help_panel_highlight_shown: 'yes'
|
2789 |
+
});
|
2790 |
+
}
|
2791 |
+
};
|
2792 |
+
|
2793 |
+
const shouldShowHelpTooltip = () => {
|
2794 |
+
const {
|
2795 |
+
task
|
2796 |
+
} = query;
|
2797 |
+
const startedTasks = userPreferencesData && userPreferencesData.task_list_tracked_started_tasks;
|
2798 |
+
const highlightShown = userPreferencesData && userPreferencesData.help_panel_highlight_shown;
|
2799 |
+
|
2800 |
+
if (task && highlightShown !== 'yes' && (startedTasks || {})[task] > 1 && !isCompletedTask) {
|
2801 |
+
return true;
|
2802 |
+
}
|
2803 |
+
|
2804 |
+
return false;
|
2805 |
+
};
|
2806 |
+
|
2807 |
+
const tabs = getTabs();
|
2808 |
+
const headerId = Object(external_lodash_["uniqueId"])('activity-panel-header_');
|
2809 |
+
const showHelpHighlightTooltip = shouldShowHelpTooltip();
|
2810 |
+
return Object(external_wp_element_["createElement"])("div", null, Object(external_wp_element_["createElement"])(external_wc_components_["H"], {
|
2811 |
+
id: headerId,
|
2812 |
+
className: "screen-reader-text"
|
2813 |
+
}, Object(external_wp_i18n_["__"])('Store Activity', 'woocommerce-admin')), Object(external_wp_element_["createElement"])(external_wc_components_["Section"], {
|
2814 |
+
component: "aside",
|
2815 |
+
id: "woocommerce-activity-panel",
|
2816 |
+
className: "woocommerce-layout__activity-panel",
|
2817 |
+
"aria-labelledby": headerId
|
2818 |
+
}, Object(external_wp_element_["createElement"])(Tabs, {
|
2819 |
+
tabs: tabs,
|
2820 |
+
tabOpen: isPanelOpen,
|
2821 |
+
selectedTab: currentTab,
|
2822 |
+
onTabClick: (tab, tabOpen) => {
|
2823 |
+
if (tab.onClick) {
|
2824 |
+
tab.onClick();
|
2825 |
+
return;
|
2826 |
+
}
|
2827 |
+
|
2828 |
+
togglePanel(tab, tabOpen);
|
2829 |
+
}
|
2830 |
+
}), Object(external_wp_element_["createElement"])(Panel, {
|
2831 |
+
currentTab: true,
|
2832 |
+
isPanelOpen: isPanelOpen,
|
2833 |
+
isPanelSwitching: isPanelSwitching,
|
2834 |
+
tab: Object(external_lodash_["find"])(getTabs(), {
|
2835 |
+
name: currentTab
|
2836 |
+
}),
|
2837 |
+
content: getPanelContent(currentTab),
|
2838 |
+
closePanel: () => closePanel(),
|
2839 |
+
clearPanel: () => clearPanel()
|
2840 |
+
})), showHelpHighlightTooltip ? Object(external_wp_element_["createElement"])(HighlightTooltip, {
|
2841 |
+
delay: 1000,
|
2842 |
+
useAnchor: true,
|
2843 |
+
title: Object(external_wp_i18n_["__"])("We're here for help", 'woocommerce-admin'),
|
2844 |
+
content: Object(external_wp_i18n_["__"])('If you have any questions, feel free to explore the WooCommerce docs listed here.', 'woocommerce-admin'),
|
2845 |
+
closeButtonText: Object(external_wp_i18n_["__"])('Got it', 'woocommerce-admin'),
|
2846 |
+
id: "activity-panel-tab-help",
|
2847 |
+
onClose: () => closedHelpPanelHighlight(),
|
2848 |
+
onShow: () => Object(external_wc_tracks_["recordEvent"])('help_tooltip_view')
|
2849 |
+
}) : null);
|
2850 |
+
};
|
2851 |
+
ActivityPanel.defaultProps = {
|
2852 |
+
getHistory: external_wc_navigation_["getHistory"]
|
2853 |
+
};
|
2854 |
+
/* harmony default export */ var activity_panel = (ActivityPanel);
|
2855 |
+
// EXTERNAL MODULE: ./node_modules/gridicons/dist/cross-small.js
|
2856 |
+
var cross_small = __webpack_require__(101);
|
2857 |
+
var cross_small_default = /*#__PURE__*/__webpack_require__.n(cross_small);
|
2858 |
+
|
2859 |
+
// CONCATENATED MODULE: ./client/lib/platform/index.js
|
2860 |
+
const ANDROID_PLATFORM = 'android';
|
2861 |
+
const IOS_PLATFORM = 'ios';
|
2862 |
+
const UNKNOWN_PLATFORM = 'unknown';
|
2863 |
+
/**
|
2864 |
+
* Provide basic detection of platform based on user agent. This is not
|
2865 |
+
* a robust check for browser features or the like. You should only use
|
2866 |
+
* this for non-critical display logic.
|
2867 |
+
*/
|
2868 |
+
|
2869 |
+
const platform = () => {
|
2870 |
+
if (/iPhone|iPad|iPod/i.test(window.navigator.userAgent)) {
|
2871 |
+
return IOS_PLATFORM;
|
2872 |
+
} else if (/Android/i.test(window.navigator.userAgent)) {
|
2873 |
+
return ANDROID_PLATFORM;
|
2874 |
+
}
|
2875 |
+
|
2876 |
+
return UNKNOWN_PLATFORM;
|
2877 |
+
};
|
2878 |
+
// CONCATENATED MODULE: ./client/mobile-banner/app-icon.js
|
2879 |
+
|
2880 |
+
const AppIcon = () => {
|
2881 |
+
return Object(external_wp_element_["createElement"])("svg", {
|
2882 |
+
width: "37",
|
2883 |
+
height: "37",
|
2884 |
+
viewBox: "0 0 92 92",
|
2885 |
+
fill: "none",
|
2886 |
+
xmlns: "http://www.w3.org/2000/svg"
|
2887 |
+
}, Object(external_wp_element_["createElement"])("rect", {
|
2888 |
+
width: "92",
|
2889 |
+
height: "92",
|
2890 |
+
rx: "21.3953",
|
2891 |
+
fill: "#7F54B3"
|
2892 |
+
}), Object(external_wp_element_["createElement"])("path", {
|
2893 |
+
fillRule: "evenodd",
|
2894 |
+
clipRule: "evenodd",
|
2895 |
+
d: "M72.5937 28.043H19.8094C16.4781 28.0459 13.7783 30.7705 13.7754 34.1324V54.4501C13.7783 57.812 16.4781 60.5366 19.8094 60.5395H44.8229L56.2573 66.9607L53.6672 60.5395H72.599C74.2009 60.5402 75.7374 59.8983 76.8702 58.7552C78.0029 57.612 78.639 56.0614 78.6383 54.4447V34.1324C78.6376 32.5157 78.0002 30.9657 76.8664 29.8235C75.7327 28.6814 74.1956 28.0408 72.5937 28.043ZM19.1057 32.4208C18.4658 32.4324 17.8646 32.7359 17.467 33.2482C17.0888 33.7635 16.9404 34.4175 17.058 35.0502C18.5962 45.0986 20.0338 51.8757 21.371 55.3816C21.8779 56.658 22.4896 57.2703 23.2063 57.2185C24.3075 57.1489 25.6263 55.5968 27.1627 52.5621C27.9964 50.8412 29.2602 48.2662 30.9539 44.837C32.3785 49.88 34.309 53.6787 36.7456 56.2331C37.4291 56.9436 38.1204 57.2748 38.8195 57.2266C39.4185 57.1931 39.953 56.8315 40.217 56.2813C40.4753 55.7358 40.5806 55.1278 40.5211 54.5248C40.3516 52.0703 40.5919 48.667 41.2421 44.3149C41.9081 39.8057 42.7523 36.5818 43.7749 34.6432C43.9822 34.2526 44.0733 33.8087 44.037 33.366C44.0039 32.7587 43.7116 32.1969 43.2374 31.829C42.7745 31.4367 42.1799 31.2446 41.5803 31.2935C40.8334 31.3325 40.1682 31.7885 39.8499 32.4797C38.2331 35.5019 37.0812 40.4109 36.3943 47.2068C35.2823 44.2394 34.4509 41.1703 33.9114 38.0412C33.623 36.4613 32.9037 35.7125 31.7536 35.7946C30.9592 35.8589 30.3063 36.3944 29.7819 37.4012L24.0348 48.5643C23.0997 44.6692 22.2205 39.9289 21.3972 34.3433C21.1997 32.9652 20.4358 32.3244 19.1057 32.4208ZM69.9089 34.6877C71.6969 35.0381 73.2407 36.2 74.1186 37.8559C74.9693 39.3247 75.3946 41.1161 75.3946 43.23C75.4148 45.9567 74.7062 48.6357 73.3477 50.9687C71.7778 53.7023 69.7195 55.0691 67.1727 55.0691C66.6933 55.0668 66.2153 55.0128 65.7467 54.9078C63.9584 54.5581 62.4143 53.396 61.5371 51.7396C60.6864 50.2452 60.261 48.4411 60.261 46.3272C60.2357 43.6127 60.945 40.9454 62.3079 38.6295C63.9023 35.8959 65.9607 34.5291 68.4829 34.5291C68.9623 34.5304 69.4402 34.5836 69.9089 34.6877ZM68.7937 49.4848C69.7707 48.5773 70.4399 47.2269 70.8012 45.4337V45.4419C70.9315 44.7826 70.9959 44.1112 70.9933 43.4382C70.986 42.5849 70.8291 41.74 70.5302 40.9452C70.1443 39.901 69.6304 39.3124 68.9884 39.1793C68.0378 38.9643 67.1239 39.5256 66.2469 40.8632C65.5812 41.8393 65.109 42.9432 64.8577 44.1106C64.7276 44.7708 64.6632 45.4432 64.6657 46.1171C64.6739 46.9677 64.8308 47.8096 65.1287 48.6019C65.5146 49.6388 66.0294 50.2274 66.6731 50.3678C67.3169 50.5081 68.0237 50.2138 68.7937 49.4848ZM57.9079 37.8559C57.0291 36.2008 55.4854 35.0392 53.6976 34.6877C53.2279 34.5837 52.749 34.5306 52.2687 34.5291C49.7443 34.5291 47.6856 35.8959 46.0927 38.6295C44.7295 40.9454 44.0201 43.6127 44.0454 46.3272C44.0454 48.4411 44.4699 50.2452 45.319 51.7396C46.1976 53.3949 47.7414 54.5566 49.5294 54.9078C49.999 55.0126 50.4779 55.0667 50.9582 55.0691C53.5055 55.0691 55.5642 53.7023 57.1343 50.9687C58.4922 48.6355 59.2001 45.9565 59.1789 43.23C59.1789 41.1161 58.7544 39.3247 57.9053 37.8559H57.9079ZM54.5903 45.4337C54.2307 47.2269 53.5614 48.5773 52.5825 49.4848C51.8115 50.2065 51.101 50.5017 50.4589 50.3678C49.8169 50.2338 49.3011 49.6461 48.9169 48.6019C48.6181 47.8097 48.4603 46.9678 48.4511 46.1171C48.4495 45.4431 48.5148 44.7707 48.6459 44.1106C48.8971 42.9432 49.3694 41.8393 50.0353 40.8632C50.9124 39.5256 51.8264 38.9643 52.7773 39.1793C53.4193 39.3124 53.9333 39.901 54.3193 40.9452C54.617 41.7404 54.7739 42.585 54.7824 43.4382C54.785 44.1112 54.7207 44.7826 54.5903 45.4419V45.4337Z",
|
2896 |
+
fill: "white"
|
2897 |
+
}));
|
2898 |
+
};
|
2899 |
+
// EXTERNAL MODULE: ./client/mobile-banner/style.scss
|
2900 |
+
var mobile_banner_style = __webpack_require__(289);
|
2901 |
+
|
2902 |
+
// CONCATENATED MODULE: ./client/mobile-banner/constants.js
|
2903 |
+
// The Play Store link is defined as an exported constant mainly for the sake of testing the Mobile App Banner.
|
2904 |
+
// It is nearly impossible to fake navigation in JSDOM 16, so exposing this link for mocking allows us to
|
2905 |
+
// avoid triggering a navigation.
|
2906 |
+
const PLAY_STORE_LINK = 'https://play.google.com/store/apps/details?id=com.woocommerce.android';
|
2907 |
+
const TRACKING_EVENT_NAME = 'wcadmin_mobile_android_banner_click';
|
2908 |
+
// CONCATENATED MODULE: ./client/mobile-banner/index.js
|
2909 |
+
|
2910 |
+
|
2911 |
+
/**
|
2912 |
+
* External dependencies
|
2913 |
+
*/
|
2914 |
+
|
2915 |
+
|
2916 |
+
|
2917 |
+
|
2918 |
+
|
2919 |
+
|
2920 |
+
/**
|
2921 |
+
* Internal dependencies
|
2922 |
+
*/
|
2923 |
+
|
2924 |
+
|
2925 |
+
|
2926 |
+
|
2927 |
+
|
2928 |
+
const SHOW_APP_BANNER_MODIFIER_CLASS = 'woocommerce-layout__show-app-banner';
|
2929 |
+
const MobileAppBanner = ({
|
2930 |
+
onInstall,
|
2931 |
+
onDismiss
|
2932 |
+
}) => {
|
2933 |
+
Object(external_wp_element_["useEffect"])(() => {
|
2934 |
+
const layout = document.getElementsByClassName('woocommerce-layout')[0];
|
2935 |
+
|
2936 |
+
if (platform() === ANDROID_PLATFORM) {
|
2937 |
+
if (layout) {
|
2938 |
+
// This is a hack to allow the mobile banner to work in the context of the header which is
|
2939 |
+
// position fixed. This can be refactored away when we move away from the activity panel
|
2940 |
+
// in future.
|
2941 |
+
layout.classList.add(SHOW_APP_BANNER_MODIFIER_CLASS);
|
2942 |
+
}
|
2943 |
+
}
|
2944 |
+
|
2945 |
+
return () => {
|
2946 |
+
if (layout) {
|
2947 |
+
layout.classList.remove(SHOW_APP_BANNER_MODIFIER_CLASS);
|
2948 |
+
}
|
2949 |
+
};
|
2950 |
+
}, []);
|
2951 |
+
const [isDismissed, setDismissed] = Object(external_wp_element_["useState"])(false); // On iOS the "Smart App Banner" meta tag is used so only display this on Android.
|
2952 |
+
|
2953 |
+
if (platform() === ANDROID_PLATFORM && !isDismissed) {
|
2954 |
+
return Object(external_wp_element_["createElement"])("div", {
|
2955 |
+
className: "woocommerce-mobile-app-banner"
|
2956 |
+
}, Object(external_wp_element_["createElement"])(build_module_icon["a" /* default */], {
|
2957 |
+
icon: Object(external_wp_element_["createElement"])(cross_small_default.a, {
|
2958 |
+
"data-testid": "dismiss-btn"
|
2959 |
+
}),
|
2960 |
+
onClick: () => {
|
2961 |
+
onDismiss();
|
2962 |
+
setDismissed(true);
|
2963 |
+
Object(external_wc_tracks_["recordEvent"])(TRACKING_EVENT_NAME, {
|
2964 |
+
action: 'dismiss'
|
2965 |
+
});
|
2966 |
+
}
|
2967 |
+
}), Object(external_wp_element_["createElement"])(AppIcon, null), Object(external_wp_element_["createElement"])("div", {
|
2968 |
+
className: "woocommerce-mobile-app-banner__description"
|
2969 |
+
}, Object(external_wp_element_["createElement"])("p", {
|
2970 |
+
className: "woocommerce-mobile-app-banner__description__text"
|
2971 |
+
}, Object(external_wp_i18n_["__"])('Run your store from anywhere', 'woocommerce-admin')), Object(external_wp_element_["createElement"])("p", {
|
2972 |
+
className: "woocommerce-mobile-app-banner__description__text"
|
2973 |
+
}, Object(external_wp_i18n_["__"])('Download the WooCommerce app', 'woocommerce-admin'))), Object(external_wp_element_["createElement"])(external_wp_components_["Button"], {
|
2974 |
+
href: PLAY_STORE_LINK,
|
2975 |
+
isSecondary: true,
|
2976 |
+
onClick: () => {
|
2977 |
+
onInstall();
|
2978 |
+
setDismissed(true);
|
2979 |
+
Object(external_wc_tracks_["recordEvent"])(TRACKING_EVENT_NAME, {
|
2980 |
+
action: 'install'
|
2981 |
+
});
|
2982 |
+
}
|
2983 |
+
}, Object(external_wp_i18n_["__"])('Install', 'woocommerce-admin')));
|
2984 |
+
}
|
2985 |
+
|
2986 |
+
return null;
|
2987 |
+
};
|
2988 |
+
// CONCATENATED MODULE: ./client/hooks/useIsScrolled.js
|
2989 |
+
/**
|
2990 |
+
* External dependencies
|
2991 |
+
*/
|
2992 |
+
|
2993 |
+
function useIsScrolled() {
|
2994 |
+
const [isScrolled, setIsScrolled] = Object(external_wp_element_["useState"])(false);
|
2995 |
+
const rafHandle = Object(external_wp_element_["useRef"])(null);
|
2996 |
+
Object(external_wp_element_["useEffect"])(() => {
|
2997 |
+
const updateIsScrolled = () => {
|
2998 |
+
setIsScrolled(window.pageYOffset > 20);
|
2999 |
+
};
|
3000 |
+
|
3001 |
+
const scrollListener = () => {
|
3002 |
+
rafHandle.current = window.requestAnimationFrame(updateIsScrolled);
|
3003 |
+
};
|
3004 |
+
|
3005 |
+
window.addEventListener('scroll', scrollListener);
|
3006 |
+
return () => {
|
3007 |
+
window.removeEventListener('scroll', scrollListener);
|
3008 |
+
window.cancelAnimationFrame(rafHandle.current);
|
3009 |
+
};
|
3010 |
+
}, []);
|
3011 |
+
return isScrolled;
|
3012 |
+
}
|
3013 |
+
// EXTERNAL MODULE: ./client/navigation/style.scss
|
3014 |
+
var navigation_style = __webpack_require__(290);
|
3015 |
+
|
3016 |
+
// CONCATENATED MODULE: ./client/navigation/utils.ts
|
3017 |
+
/**
|
3018 |
+
* External dependencies
|
3019 |
+
*/
|
3020 |
+
|
3021 |
+
|
3022 |
+
/**
|
3023 |
+
* Get the full URL if a relative path is passed.
|
3024 |
+
*/
|
3025 |
+
const getFullUrl = url => {
|
3026 |
+
if (url.indexOf('http') === 0) {
|
3027 |
+
return url;
|
3028 |
+
}
|
3029 |
+
|
3030 |
+
return Object(build_module["e" /* getAdminLink */])(url);
|
3031 |
+
};
|
3032 |
+
/**
|
3033 |
+
* Get a default regex expression to match the path and provided params.
|
3034 |
+
*/
|
3035 |
+
|
3036 |
+
const getDefaultMatchExpression = url => {
|
3037 |
+
const escapedUrl = url.replace(/[-\/\\^$*+?.()|[\]{}]/gi, '\\$&');
|
3038 |
+
const [path, args, hash] = escapedUrl.split(/\\\?|#/);
|
3039 |
+
const hashExpression = hash ? `(.*#${hash}$)` : '';
|
3040 |
+
const argsExpression = args ? args.split('&').reduce((acc, param) => {
|
3041 |
+
return `${acc}(?=.*[?|&]${param}(&|$|#))`;
|
3042 |
+
}, '') : '';
|
3043 |
+
return '^' + path + argsExpression + hashExpression;
|
3044 |
+
};
|
3045 |
+
/**
|
3046 |
+
* Get a match score for a menu item given a location.
|
3047 |
+
*/
|
3048 |
+
|
3049 |
+
const getMatchScore = (location, itemUrl, itemExpression = null) => {
|
3050 |
+
if (!itemUrl) {
|
3051 |
+
return 0;
|
3052 |
+
}
|
3053 |
+
|
3054 |
+
const fullUrl = getFullUrl(itemUrl);
|
3055 |
+
const {
|
3056 |
+
href
|
3057 |
+
} = location; // Return highest possible score for exact match.
|
3058 |
+
|
3059 |
+
if (fullUrl === href) {
|
3060 |
+
return Number.MAX_SAFE_INTEGER;
|
3061 |
+
}
|
3062 |
+
|
3063 |
+
const defaultExpression = getDefaultMatchExpression(fullUrl);
|
3064 |
+
const regexp = new RegExp(itemExpression || defaultExpression, 'i');
|
3065 |
+
return (decodeURIComponent(href).match(regexp) || []).length;
|
3066 |
+
};
|
3067 |
+
|
3068 |
+
/**
|
3069 |
+
* Get the closest matching item.
|
3070 |
+
*
|
3071 |
+
* @param {Array} items An array of items to match against.
|
3072 |
+
*/
|
3073 |
+
const getMatchingItem = items => {
|
3074 |
+
let matchedItem = null;
|
3075 |
+
let highestMatchScore = 0;
|
3076 |
+
items.forEach(item => {
|
3077 |
+
const score = getMatchScore(window.location, item.url, item.matchExpression);
|
3078 |
+
|
3079 |
+
if (score > 0 && score >= highestMatchScore) {
|
3080 |
+
highestMatchScore = score;
|
3081 |
+
matchedItem = item;
|
3082 |
+
}
|
3083 |
+
});
|
3084 |
+
return matchedItem || null;
|
3085 |
+
};
|
3086 |
+
/**
|
3087 |
+
* Available menu IDs.
|
3088 |
+
*/
|
3089 |
+
|
3090 |
+
const menuIds = ['primary', 'favorites', 'plugins', 'secondary'];
|
3091 |
+
|
3092 |
+
/**
|
3093 |
+
* Default categories for the menu.
|
3094 |
+
*/
|
3095 |
+
const defaultCategories = {
|
3096 |
+
woocommerce: {
|
3097 |
+
id: 'woocommerce',
|
3098 |
+
isCategory: true,
|
3099 |
+
menuId: 'primary',
|
3100 |
+
migrate: true,
|
3101 |
+
order: 10,
|
3102 |
+
parent: '',
|
3103 |
+
title: 'WooCommerce'
|
3104 |
+
}
|
3105 |
+
};
|
3106 |
+
/**
|
3107 |
+
* Sort an array of menu items by their order property.
|
3108 |
+
*
|
3109 |
+
* @param {Array} menuItems Array of menu items.
|
3110 |
+
* @return {Array} Sorted menu items.
|
3111 |
+
*/
|
3112 |
+
|
3113 |
+
const sortMenuItems = menuItems => {
|
3114 |
+
return menuItems.sort((a, b) => {
|
3115 |
+
if (a.order === b.order) {
|
3116 |
+
return a.title.localeCompare(b.title);
|
3117 |
+
}
|
3118 |
+
|
3119 |
+
return a.order - b.order;
|
3120 |
+
});
|
3121 |
+
};
|
3122 |
+
/**
|
3123 |
+
* Get a flat tree structure of all Categories and thier children grouped by menuId
|
3124 |
+
*
|
3125 |
+
* @param {Array} menuItems Array of menu items.
|
3126 |
+
* @param {Function} currentUserCan Callback method passed the capability to determine if a menu item is visible.
|
3127 |
+
* @return {Object} Mapped menu items and categories.
|
3128 |
+
*/
|
3129 |
+
|
3130 |
+
const getMappedItemsCategories = (menuItems, currentUserCan) => {
|
3131 |
+
const categories = { ...defaultCategories
|
3132 |
+
};
|
3133 |
+
const items = sortMenuItems(menuItems).reduce((acc, item) => {
|
3134 |
+
// Set up the category if it doesn't yet exist.
|
3135 |
+
if (!acc[item.parent]) {
|
3136 |
+
acc[item.parent] = {};
|
3137 |
+
menuIds.forEach(menuId => {
|
3138 |
+
acc[item.parent][menuId] = [];
|
3139 |
+
});
|
3140 |
+
} // Incorrect menu ID.
|
3141 |
+
|
3142 |
+
|
3143 |
+
if (!acc[item.parent][item.menuId]) {
|
3144 |
+
return acc;
|
3145 |
+
} // User does not have permission to view this item.
|
3146 |
+
|
3147 |
+
|
3148 |
+
if (currentUserCan && item.capability && !currentUserCan(item.capability)) {
|
3149 |
+
return acc;
|
3150 |
+
} // Add categories.
|
3151 |
+
|
3152 |
+
|
3153 |
+
if (item.isCategory) {
|
3154 |
+
categories[item.id] = item;
|
3155 |
+
}
|
3156 |
+
|
3157 |
+
const menuIdArray = acc[item.parent][item.menuId];
|
3158 |
+
|
3159 |
+
if (menuIdArray) {
|
3160 |
+
menuIdArray.push(item);
|
3161 |
+
}
|
3162 |
+
|
3163 |
+
return acc;
|
3164 |
+
}, {});
|
3165 |
+
return {
|
3166 |
+
items,
|
3167 |
+
categories
|
3168 |
+
};
|
3169 |
+
};
|
3170 |
+
// CONCATENATED MODULE: ./node_modules/@wordpress/icons/build-module/library/wordpress.js
|
3171 |
+
|
3172 |
+
|
3173 |
+
/**
|
3174 |
+
* WordPress dependencies
|
3175 |
+
*/
|
3176 |
+
|
3177 |
+
var wordpress = Object(external_wp_element_["createElement"])(external_wp_primitives_["SVG"], {
|
3178 |
+
xmlns: "http://www.w3.org/2000/svg",
|
3179 |
+
viewBox: "-2 -2 24 24"
|
3180 |
+
}, Object(external_wp_element_["createElement"])(external_wp_primitives_["Path"], {
|
3181 |
+
d: "M20 10c0-5.51-4.49-10-10-10C4.48 0 0 4.49 0 10c0 5.52 4.48 10 10 10 5.51 0 10-4.48 10-10zM7.78 15.37L4.37 6.22c.55-.02 1.17-.08 1.17-.08.5-.06.44-1.13-.06-1.11 0 0-1.45.11-2.37.11-.18 0-.37 0-.58-.01C4.12 2.69 6.87 1.11 10 1.11c2.33 0 4.45.87 6.05 2.34-.68-.11-1.65.39-1.65 1.58 0 .74.45 1.36.9 2.1.35.61.55 1.36.55 2.46 0 1.49-1.4 5-1.4 5l-3.03-8.37c.54-.02.82-.17.82-.17.5-.05.44-1.25-.06-1.22 0 0-1.44.12-2.38.12-.87 0-2.33-.12-2.33-.12-.5-.03-.56 1.2-.06 1.22l.92.08 1.26 3.41zM17.41 10c.24-.64.74-1.87.43-4.25.7 1.29 1.05 2.71 1.05 4.25 0 3.29-1.73 6.24-4.4 7.78.97-2.59 1.94-5.2 2.92-7.78zM6.1 18.09C3.12 16.65 1.11 13.53 1.11 10c0-1.3.23-2.48.72-3.59C3.25 10.3 4.67 14.2 6.1 18.09zm4.03-6.63l2.58 6.98c-.86.29-1.76.45-2.71.45-.79 0-1.57-.11-2.29-.33.81-2.38 1.62-4.74 2.42-7.1z"
|
3182 |
+
}));
|
3183 |
+
/* harmony default export */ var library_wordpress = (wordpress);
|
3184 |
+
//# sourceMappingURL=wordpress.js.map
|
3185 |
+
// CONCATENATED MODULE: ./client/navigation/components/header/index.js
|
3186 |
+
|
3187 |
+
|
3188 |
+
/**
|
3189 |
+
* External dependencies
|
3190 |
+
*/
|
3191 |
+
|
3192 |
+
|
3193 |
+
|
3194 |
+
|
3195 |
+
|
3196 |
+
|
3197 |
+
|
3198 |
+
|
3199 |
+
|
3200 |
+
|
3201 |
+
/**
|
3202 |
+
* Internal dependencies
|
3203 |
+
*/
|
3204 |
+
|
3205 |
+
|
3206 |
+
|
3207 |
+
const Header = () => {
|
3208 |
+
const siteTitle = Object(build_module["f" /* getSetting */])('siteTitle', '');
|
3209 |
+
const homeUrl = Object(build_module["f" /* getSetting */])('homeUrl', '');
|
3210 |
+
const isScrolled = useIsScrolled();
|
3211 |
+
const [isFolded, setIsFolded] = Object(external_wp_element_["useState"])(document.body.classList.contains(false));
|
3212 |
+
const navClasses = {
|
3213 |
+
folded: 'is-wc-nav-folded',
|
3214 |
+
expanded: 'is-wc-nav-expanded'
|
3215 |
+
};
|
3216 |
+
|
3217 |
+
const foldNav = () => {
|
3218 |
+
document.body.classList.add(navClasses.folded);
|
3219 |
+
document.body.classList.remove(navClasses.expanded);
|
3220 |
+
setIsFolded(true);
|
3221 |
+
};
|
3222 |
+
|
3223 |
+
const expandNav = () => {
|
3224 |
+
document.body.classList.remove(navClasses.folded);
|
3225 |
+
document.body.classList.add(navClasses.expanded);
|
3226 |
+
setIsFolded(false);
|
3227 |
+
};
|
3228 |
+
|
3229 |
+
const toggleFolded = () => {
|
3230 |
+
if (document.body.classList.contains(navClasses.folded)) {
|
3231 |
+
expandNav();
|
3232 |
+
} else {
|
3233 |
+
foldNav();
|
3234 |
+
}
|
3235 |
+
};
|
3236 |
+
|
3237 |
+
const foldOnMobile = (screenWidth = document.body.clientWidth) => {
|
3238 |
+
if (screenWidth <= 960) {
|
3239 |
+
foldNav();
|
3240 |
+
} else {
|
3241 |
+
expandNav();
|
3242 |
+
}
|
3243 |
+
};
|
3244 |
+
|
3245 |
+
Object(external_wp_element_["useEffect"])(() => {
|
3246 |
+
foldOnMobile();
|
3247 |
+
const foldEvents = [{
|
3248 |
+
eventName: 'orientationchange',
|
3249 |
+
handler: e => foldOnMobile(e.target.screen.availWidth)
|
3250 |
+
}, {
|
3251 |
+
eventName: 'resize',
|
3252 |
+
handler: Object(external_lodash_["debounce"])(() => foldOnMobile(), 200)
|
3253 |
+
}];
|
3254 |
+
|
3255 |
+
for (const {
|
3256 |
+
eventName,
|
3257 |
+
handler
|
3258 |
+
} of foldEvents) {
|
3259 |
+
window.addEventListener(eventName, handler, false);
|
3260 |
+
}
|
3261 |
+
|
3262 |
+
Object(external_wc_navigation_["addHistoryListener"])(() => foldOnMobile());
|
3263 |
+
}, []);
|
3264 |
+
let buttonIcon = Object(external_wp_element_["createElement"])(build_module_icon["a" /* default */], {
|
3265 |
+
size: "36px",
|
3266 |
+
icon: library_wordpress
|
3267 |
+
});
|
3268 |
+
const {
|
3269 |
+
isRequestingSiteIcon,
|
3270 |
+
siteIconUrl
|
3271 |
+
} = Object(external_wp_data_["useSelect"])(select => {
|
3272 |
+
const {
|
3273 |
+
isResolving
|
3274 |
+
} = select('core/data');
|
3275 |
+
const {
|
3276 |
+
getEntityRecord
|
3277 |
+
} = select('core');
|
3278 |
+
const siteData = getEntityRecord('root', '__unstableBase', undefined) || {};
|
3279 |
+
return {
|
3280 |
+
isRequestingSiteIcon: isResolving('core', 'getEntityRecord', ['root', '__unstableBase', undefined]),
|
3281 |
+
siteIconUrl: siteData.siteIconUrl
|
3282 |
+
};
|
3283 |
+
});
|
3284 |
+
|
3285 |
+
if (siteIconUrl) {
|
3286 |
+
buttonIcon = Object(external_wp_element_["createElement"])("img", {
|
3287 |
+
alt: Object(external_wp_i18n_["__"])('Site Icon'),
|
3288 |
+
src: siteIconUrl
|
3289 |
+
});
|
3290 |
+
} else if (isRequestingSiteIcon) {
|
3291 |
+
buttonIcon = null;
|
3292 |
+
}
|
3293 |
+
|
3294 |
+
const className = classnames_default()('woocommerce-navigation-header', {
|
3295 |
+
'is-scrolled': isScrolled
|
3296 |
+
});
|
3297 |
+
return Object(external_wp_element_["createElement"])("div", {
|
3298 |
+
className: className
|
3299 |
+
}, Object(external_wp_element_["createElement"])(external_wp_components_["Button"], {
|
3300 |
+
onClick: () => toggleFolded(),
|
3301 |
+
className: "woocommerce-navigation-header__site-icon",
|
3302 |
+
"aria-label": "Fold navigation",
|
3303 |
+
role: "switch",
|
3304 |
+
"aria-checked": isFolded ? 'true' : 'false'
|
3305 |
+
}, buttonIcon), Object(external_wp_element_["createElement"])(external_wp_components_["Button"], {
|
3306 |
+
href: homeUrl,
|
3307 |
+
className: "woocommerce-navigation-header__site-title",
|
3308 |
+
as: "span"
|
3309 |
+
}, Object(external_wp_htmlEntities_["decodeEntities"])(siteTitle)));
|
3310 |
+
};
|
3311 |
+
|
3312 |
+
/* harmony default export */ var header = (Header);
|
3313 |
+
// EXTERNAL MODULE: ./client/navigation/components/category-title/style.scss
|
3314 |
+
var category_title_style = __webpack_require__(291);
|
3315 |
+
|
3316 |
+
// CONCATENATED MODULE: ./node_modules/@wordpress/icons/build-module/library/star-filled.js
|
3317 |
+
|
3318 |
+
|
3319 |
+
/**
|
3320 |
+
* WordPress dependencies
|
3321 |
+
*/
|
3322 |
+
|
3323 |
+
var starFilled = Object(external_wp_element_["createElement"])(external_wp_primitives_["SVG"], {
|
3324 |
+
xmlns: "http://www.w3.org/2000/svg",
|
3325 |
+
viewBox: "0 0 24 24"
|
3326 |
+
}, Object(external_wp_element_["createElement"])(external_wp_primitives_["Path"], {
|
3327 |
+
d: "M11.776 4.454a.25.25 0 01.448 0l2.069 4.192a.25.25 0 00.188.137l4.626.672a.25.25 0 01.139.426l-3.348 3.263a.25.25 0 00-.072.222l.79 4.607a.25.25 0 01-.362.263l-4.138-2.175a.25.25 0 00-.232 0l-4.138 2.175a.25.25 0 01-.363-.263l.79-4.607a.25.25 0 00-.071-.222L4.754 9.881a.25.25 0 01.139-.426l4.626-.672a.25.25 0 00.188-.137l2.069-4.192z"
|
3328 |
+
}));
|
3329 |
+
/* harmony default export */ var star_filled = (starFilled);
|
3330 |
+
//# sourceMappingURL=star-filled.js.map
|
3331 |
+
// CONCATENATED MODULE: ./node_modules/@wordpress/icons/build-module/library/star-empty.js
|
3332 |
+
|
3333 |
+
|
3334 |
+
/**
|
3335 |
+
* WordPress dependencies
|
3336 |
+
*/
|
3337 |
+
|
3338 |
+
var starEmpty = Object(external_wp_element_["createElement"])(external_wp_primitives_["SVG"], {
|
3339 |
+
xmlns: "http://www.w3.org/2000/svg",
|
3340 |
+
viewBox: "0 0 24 24"
|
3341 |
+
}, Object(external_wp_element_["createElement"])(external_wp_primitives_["Path"], {
|
3342 |
+
fillRule: "evenodd",
|
3343 |
+
d: "M9.706 8.646a.25.25 0 01-.188.137l-4.626.672a.25.25 0 00-.139.427l3.348 3.262a.25.25 0 01.072.222l-.79 4.607a.25.25 0 00.362.264l4.138-2.176a.25.25 0 01.233 0l4.137 2.175a.25.25 0 00.363-.263l-.79-4.607a.25.25 0 01.072-.222l3.347-3.262a.25.25 0 00-.139-.427l-4.626-.672a.25.25 0 01-.188-.137l-2.069-4.192a.25.25 0 00-.448 0L9.706 8.646zM12 7.39l-.948 1.921a1.75 1.75 0 01-1.317.957l-2.12.308 1.534 1.495c.412.402.6.982.503 1.55l-.362 2.11 1.896-.997a1.75 1.75 0 011.629 0l1.895.997-.362-2.11a1.75 1.75 0 01.504-1.55l1.533-1.495-2.12-.308a1.75 1.75 0 01-1.317-.957L12 7.39z",
|
3344 |
+
clipRule: "evenodd"
|
3345 |
+
}));
|
3346 |
+
/* harmony default export */ var star_empty = (starEmpty);
|
3347 |
+
//# sourceMappingURL=star-empty.js.map
|
3348 |
+
// EXTERNAL MODULE: ./client/navigation/components/favorite-button/style.scss
|
3349 |
+
var favorite_button_style = __webpack_require__(292);
|
3350 |
+
|
3351 |
+
// CONCATENATED MODULE: ./client/navigation/components/favorite-button/index.js
|
3352 |
+
|
3353 |
+
|
3354 |
+
/**
|
3355 |
+
* External dependencies
|
3356 |
+
*/
|
3357 |
+
|
3358 |
+
|
3359 |
+
|
3360 |
+
|
3361 |
+
|
3362 |
+
|
3363 |
+
/**
|
3364 |
+
* Internal dependencies
|
3365 |
+
*/
|
3366 |
+
|
3367 |
+
|
3368 |
+
const FavoriteButton = ({
|
3369 |
+
id
|
3370 |
+
}) => {
|
3371 |
+
const {
|
3372 |
+
favorites,
|
3373 |
+
isResolving
|
3374 |
+
} = Object(external_wp_data_["useSelect"])(select => {
|
3375 |
+
return {
|
3376 |
+
favorites: select(external_wc_data_["NAVIGATION_STORE_NAME"]).getFavorites(),
|
3377 |
+
isResolving: select(external_wc_data_["NAVIGATION_STORE_NAME"]).isResolving('getFavorites')
|
3378 |
+
};
|
3379 |
+
});
|
3380 |
+
const {
|
3381 |
+
addFavorite,
|
3382 |
+
removeFavorite
|
3383 |
+
} = Object(external_wp_data_["useDispatch"])(external_wc_data_["NAVIGATION_STORE_NAME"]);
|
3384 |
+
const isFavorited = favorites.includes(id);
|
3385 |
+
|
3386 |
+
const toggleFavorite = () => {
|
3387 |
+
const toggle = isFavorited ? removeFavorite : addFavorite;
|
3388 |
+
toggle(id);
|
3389 |
+
Object(external_wc_tracks_["recordEvent"])('navigation_favorite', {
|
3390 |
+
id,
|
3391 |
+
action: isFavorited ? 'unfavorite' : 'favorite'
|
3392 |
+
});
|
3393 |
+
};
|
3394 |
+
|
3395 |
+
if (isResolving) {
|
3396 |
+
return null;
|
3397 |
+
}
|
3398 |
+
|
3399 |
+
return Object(external_wp_element_["createElement"])(external_wp_components_["Button"], {
|
3400 |
+
id: "woocommerce-navigation-favorite-button",
|
3401 |
+
className: "woocommerce-navigation-favorite-button",
|
3402 |
+
isTertiary: true,
|
3403 |
+
onClick: toggleFavorite,
|
3404 |
+
"aria-label": isFavorited ? Object(external_wp_i18n_["__"])('Add this item to your favorites.', 'woocommerce-admin') : Object(external_wp_i18n_["__"])('Remove this item from your favorites.', 'woocommerce-admin')
|
3405 |
+
}, Object(external_wp_element_["createElement"])(build_module_icon["a" /* default */], {
|
3406 |
+
icon: isFavorited ? star_filled : star_empty,
|
3407 |
+
className: `star-${isFavorited ? 'filled' : 'empty'}-icon`
|
3408 |
+
}));
|
3409 |
+
};
|
3410 |
+
/* harmony default export */ var favorite_button = (FavoriteButton);
|
3411 |
+
// CONCATENATED MODULE: ./client/navigation/components/favorites-tooltip/index.js
|
3412 |
+
|
3413 |
+
|
3414 |
+
/**
|
3415 |
+
* External dependencies
|
3416 |
+
*/
|
3417 |
+
|
3418 |
+
|
3419 |
+
|
3420 |
+
/**
|
3421 |
+
* Internal dependencies
|
3422 |
+
*/
|
3423 |
+
|
3424 |
+
|
3425 |
+
const tooltipHiddenOption = 'woocommerce_navigation_favorites_tooltip_hidden';
|
3426 |
+
const FavoritesTooltip = () => {
|
3427 |
+
const {
|
3428 |
+
isFavoritesResolving,
|
3429 |
+
isOptionResolving,
|
3430 |
+
isTooltipHidden
|
3431 |
+
} = Object(external_wp_data_["useSelect"])(select => {
|
3432 |
+
const {
|
3433 |
+
getOption,
|
3434 |
+
isResolving
|
3435 |
+
} = select(external_wc_data_["OPTIONS_STORE_NAME"]);
|
3436 |
+
return {
|
3437 |
+
isFavoritesResolving: select(external_wc_data_["NAVIGATION_STORE_NAME"]).isResolving('getFavorites'),
|
3438 |
+
isOptionResolving: isResolving('getOption', [tooltipHiddenOption]),
|
3439 |
+
isTooltipHidden: getOption(tooltipHiddenOption) === 'yes'
|
3440 |
+
};
|
3441 |
+
});
|
3442 |
+
const {
|
3443 |
+
updateOptions
|
3444 |
+
} = Object(external_wp_data_["useDispatch"])(external_wc_data_["OPTIONS_STORE_NAME"]);
|
3445 |
+
|
3446 |
+
if (isFavoritesResolving || isTooltipHidden || isOptionResolving) {
|
3447 |
+
return null;
|
3448 |
+
}
|
3449 |
+
|
3450 |
+
if (document.body.classList.contains('is-wc-nav-folded')) {
|
3451 |
+
return null;
|
3452 |
+
}
|
3453 |
+
|
3454 |
+
return Object(external_wp_element_["createElement"])(HighlightTooltip, {
|
3455 |
+
delay: 1000,
|
3456 |
+
title: Object(external_wp_i18n_["__"])('Introducing favorites', 'woocommerce-admin'),
|
3457 |
+
content: Object(external_wp_i18n_["__"])('You can now favorite your extensions to pin them in the top level of the navigation.', 'woocommerce-admin'),
|
3458 |
+
closeButtonText: Object(external_wp_i18n_["__"])('Got it', 'woocommerce-admin'),
|
3459 |
+
id: "woocommerce-navigation-favorite-button",
|
3460 |
+
onClose: () => updateOptions({
|
3461 |
+
[tooltipHiddenOption]: 'yes'
|
3462 |
+
}),
|
3463 |
+
useAnchor: true
|
3464 |
+
});
|
3465 |
+
};
|
3466 |
+
/* harmony default export */ var favorites_tooltip = (FavoritesTooltip);
|
3467 |
+
// CONCATENATED MODULE: ./client/navigation/components/category-title/index.js
|
3468 |
+
|
3469 |
+
|
3470 |
+
/**
|
3471 |
+
* Internal dependencies
|
3472 |
+
*/
|
3473 |
+
|
3474 |
+
|
3475 |
+
|
3476 |
+
const CategoryTitle = ({
|
3477 |
+
category
|
3478 |
+
}) => {
|
3479 |
+
const {
|
3480 |
+
id,
|
3481 |
+
menuId,
|
3482 |
+
title
|
3483 |
+
} = category;
|
3484 |
+
const className = 'woocommerce-navigation-category-title';
|
3485 |
+
|
3486 |
+
if (['plugins', 'favorites'].includes(menuId)) {
|
3487 |
+
return Object(external_wp_element_["createElement"])("span", {
|
3488 |
+
className: className
|
3489 |
+
}, Object(external_wp_element_["createElement"])("span", {
|
3490 |
+
className: `${className}__text`
|
3491 |
+
}, title), Object(external_wp_element_["createElement"])(FavoriteButton, {
|
3492 |
+
id: id
|
3493 |
+
}), Object(external_wp_element_["createElement"])(FavoritesTooltip, null));
|
3494 |
+
}
|
3495 |
+
|
3496 |
+
return Object(external_wp_element_["createElement"])("span", {
|
3497 |
+
className: className
|
3498 |
+
}, title);
|
3499 |
+
};
|
3500 |
+
/* harmony default export */ var category_title = (CategoryTitle);
|
3501 |
+
// CONCATENATED MODULE: ./client/navigation/components/Item/index.js
|
3502 |
+
|
3503 |
+
|
3504 |
+
/**
|
3505 |
+
* External dependencies
|
3506 |
+
*/
|
3507 |
+
|
3508 |
+
|
3509 |
+
|
3510 |
+
|
3511 |
+
const Item = ({
|
3512 |
+
item
|
3513 |
+
}) => {
|
3514 |
+
var _slot$fills;
|
3515 |
+
|
3516 |
+
const slot = Object(external_wc_experimental_["useSlot"])('woocommerce_navigation_' + item.id);
|
3517 |
+
const hasFills = Boolean(slot === null || slot === void 0 ? void 0 : (_slot$fills = slot.fills) === null || _slot$fills === void 0 ? void 0 : _slot$fills.length);
|
3518 |
+
|
3519 |
+
const trackClick = id => {
|
3520 |
+
Object(external_wc_tracks_["recordEvent"])('navigation_click', {
|
3521 |
+
menu_item: id
|
3522 |
+
});
|
3523 |
+
}; // Disable reason: The div wrapping the slot item is used for tracking purposes
|
3524 |
+
// and should not be a tabbable element.
|
3525 |
+
|
3526 |
+
/* eslint-disable jsx-a11y/no-static-element-interactions, jsx-a11y/click-events-have-key-events */
|
3527 |
+
// Only render a slot if a coresponding Fill exists and the item is not a category
|
3528 |
+
|
3529 |
+
|
3530 |
+
if (hasFills && !item.isCategory) {
|
3531 |
+
return Object(external_wp_element_["createElement"])(external_wc_experimental_["NavigationItem"], {
|
3532 |
+
key: item.id,
|
3533 |
+
item: item.id
|
3534 |
+
}, Object(external_wp_element_["createElement"])("div", {
|
3535 |
+
onClick: () => trackClick(item.id)
|
3536 |
+
}, Object(external_wp_element_["createElement"])(external_wc_navigation_["WooNavigationItem"].Slot, {
|
3537 |
+
name: item.id
|
3538 |
+
})));
|
3539 |
+
}
|
3540 |
+
|
3541 |
+
return Object(external_wp_element_["createElement"])(external_wc_experimental_["NavigationItem"], {
|
3542 |
+
key: item.id,
|
3543 |
+
item: item.id,
|
3544 |
+
title: item.title,
|
3545 |
+
badge: item.badge ? item.badge : null,
|
3546 |
+
href: item.url,
|
3547 |
+
navigateToMenu: !item.url && item.id,
|
3548 |
+
onClick: () => trackClick(item.id),
|
3549 |
+
hideIfTargetMenuEmpty: true
|
3550 |
+
});
|
3551 |
+
/* eslint-enable jsx-a11y/no-static-element-interactions, jsx-a11y/click-events-have-key-events */
|
3552 |
+
};
|
3553 |
+
|
3554 |
+
/* harmony default export */ var components_Item = (Item);
|
3555 |
+
// CONCATENATED MODULE: ./client/navigation/components/container/primary-menu.js
|
3556 |
+
|
3557 |
+
|
3558 |
+
/**
|
3559 |
+
* External dependencies
|
3560 |
+
*/
|
3561 |
+
|
3562 |
+
|
3563 |
+
|
3564 |
+
/**
|
3565 |
+
* Internal dependencies
|
3566 |
+
*/
|
3567 |
+
|
3568 |
+
|
3569 |
+
|
3570 |
+
const PrimaryMenu = ({
|
3571 |
+
category,
|
3572 |
+
onBackClick,
|
3573 |
+
pluginItems,
|
3574 |
+
primaryItems
|
3575 |
+
}) => {
|
3576 |
+
if (!primaryItems.length && !pluginItems.length) {
|
3577 |
+
return null;
|
3578 |
+
}
|
3579 |
+
|
3580 |
+
const rootBackLabel = Object(external_wp_hooks_["applyFilters"])('woocommerce_navigation_root_back_label', Object(external_wp_i18n_["__"])('WordPress Dashboard', 'woocommerce-admin'));
|
3581 |
+
const rootBackUrl = Object(external_wp_hooks_["applyFilters"])('woocommerce_navigation_root_back_url', window.wcNavigation.rootBackUrl);
|
3582 |
+
const isRootBackVisible = category.id === 'woocommerce' && rootBackUrl;
|
3583 |
+
return Object(external_wp_element_["createElement"])(external_wc_experimental_["NavigationMenu"], {
|
3584 |
+
title: Object(external_wp_element_["createElement"])(category_title, {
|
3585 |
+
category: category
|
3586 |
+
}),
|
3587 |
+
menu: category.id,
|
3588 |
+
parentMenu: category.parent,
|
3589 |
+
backButtonLabel: isRootBackVisible ? rootBackLabel : category.backButtonLabel || null,
|
3590 |
+
onBackButtonClick: isRootBackVisible ? () => {
|
3591 |
+
onBackClick('woocommerce');
|
3592 |
+
window.location = rootBackUrl;
|
3593 |
+
} : () => onBackClick(category.id)
|
3594 |
+
}, !!primaryItems.length && Object(external_wp_element_["createElement"])(external_wc_experimental_["NavigationGroup"], null, primaryItems.map(item => Object(external_wp_element_["createElement"])(components_Item, {
|
3595 |
+
key: item.id,
|
3596 |
+
item: item
|
3597 |
+
}))), !!pluginItems.length && Object(external_wp_element_["createElement"])(external_wc_experimental_["NavigationGroup"], {
|
3598 |
+
title: category.id === 'woocommerce' ? Object(external_wp_i18n_["__"])('Extensions', 'woocommerce-admin') : null
|
3599 |
+
}, pluginItems.map(item => Object(external_wp_element_["createElement"])(components_Item, {
|
3600 |
+
key: item.id,
|
3601 |
+
item: item
|
3602 |
+
}))));
|
3603 |
+
};
|
3604 |
+
// CONCATENATED MODULE: ./client/navigation/components/container/secondary-menu.js
|
3605 |
+
|
3606 |
+
|
3607 |
+
/**
|
3608 |
+
* External dependencies
|
3609 |
+
*/
|
3610 |
+
|
3611 |
+
/**
|
3612 |
+
* Internal dependencies
|
3613 |
+
*/
|
3614 |
+
|
3615 |
+
|
3616 |
+
|
3617 |
+
const SecondaryMenu = ({
|
3618 |
+
category,
|
3619 |
+
items,
|
3620 |
+
onBackClick
|
3621 |
+
}) => {
|
3622 |
+
if (!items.length) {
|
3623 |
+
return null;
|
3624 |
+
}
|
3625 |
+
|
3626 |
+
const isRoot = category.id === 'woocommerce';
|
3627 |
+
return Object(external_wp_element_["createElement"])(external_wc_experimental_["NavigationMenu"], {
|
3628 |
+
className: "components-navigation__menu-secondary",
|
3629 |
+
title: !isRoot && Object(external_wp_element_["createElement"])(category_title, {
|
3630 |
+
category: category
|
3631 |
+
}),
|
3632 |
+
menu: category.id,
|
3633 |
+
parentMenu: category.parent,
|
3634 |
+
backButtonLabel: category.backButtonLabel || null,
|
3635 |
+
onBackButtonClick: isRoot ? null : () => onBackClick(category.id)
|
3636 |
+
}, Object(external_wp_element_["createElement"])(external_wc_experimental_["NavigationGroup"], {
|
3637 |
+
onBackButtonClick: () => onBackClick(category.id)
|
3638 |
+
}, items.map(item => Object(external_wp_element_["createElement"])(components_Item, {
|
3639 |
+
key: item.id,
|
3640 |
+
item: item
|
3641 |
+
}))));
|
3642 |
+
};
|
3643 |
+
// CONCATENATED MODULE: ./client/navigation/components/container/index.js
|
3644 |
+
|
3645 |
+
|
3646 |
+
/**
|
3647 |
+
* External dependencies
|
3648 |
+
*/
|
3649 |
+
|
3650 |
+
|
3651 |
+
|
3652 |
+
|
3653 |
+
|
3654 |
+
|
3655 |
+
|
3656 |
+
/**
|
3657 |
+
* Internal dependencies
|
3658 |
+
*/
|
3659 |
+
|
3660 |
+
|
3661 |
+
|
3662 |
+
|
3663 |
+
|
3664 |
+
|
3665 |
+
const Container = () => {
|
3666 |
+
const {
|
3667 |
+
menuItems
|
3668 |
+
} = Object(external_wp_data_["useSelect"])(select => {
|
3669 |
+
return {
|
3670 |
+
menuItems: select(external_wc_data_["NAVIGATION_STORE_NAME"]).getMenuItems()
|
3671 |
+
};
|
3672 |
+
});
|
3673 |
+
Object(external_wp_element_["useEffect"])(() => {
|
3674 |
+
// Collapse the original WP Menu.
|
3675 |
+
document.documentElement.classList.remove('wp-toolbar');
|
3676 |
+
document.body.classList.add('has-woocommerce-navigation');
|
3677 |
+
const adminMenu = document.getElementById('adminmenumain');
|
3678 |
+
|
3679 |
+
if (!adminMenu) {
|
3680 |
+
return;
|
3681 |
+
}
|
3682 |
+
|
3683 |
+
adminMenu.classList.add('folded');
|
3684 |
+
}, []);
|
3685 |
+
const [activeItem, setActiveItem] = Object(external_wp_element_["useState"])('woocommerce-home');
|
3686 |
+
const [activeLevel, setActiveLevel] = Object(external_wp_element_["useState"])('woocommerce');
|
3687 |
+
Object(external_wp_element_["useEffect"])(() => {
|
3688 |
+
const initialMatchedItem = getMatchingItem(menuItems);
|
3689 |
+
|
3690 |
+
if (initialMatchedItem && activeItem !== initialMatchedItem) {
|
3691 |
+
setActiveItem(initialMatchedItem);
|
3692 |
+
setActiveLevel(initialMatchedItem.parent);
|
3693 |
+
}
|
3694 |
+
|
3695 |
+
const removeListener = Object(external_wc_navigation_["addHistoryListener"])(() => {
|
3696 |
+
setTimeout(() => {
|
3697 |
+
const matchedItem = getMatchingItem(menuItems);
|
3698 |
+
|
3699 |
+
if (matchedItem) {
|
3700 |
+
setActiveItem(matchedItem);
|
3701 |
+
setActiveLevel(matchedItem.parent);
|
3702 |
+
}
|
3703 |
+
}, 0);
|
3704 |
+
});
|
3705 |
+
return removeListener;
|
3706 |
+
}, [menuItems]);
|
3707 |
+
const {
|
3708 |
+
currentUserCan
|
3709 |
+
} = Object(external_wc_data_["useUser"])();
|
3710 |
+
const {
|
3711 |
+
categories,
|
3712 |
+
items
|
3713 |
+
} = Object(external_wp_element_["useMemo"])(() => getMappedItemsCategories(menuItems, currentUserCan), [menuItems, currentUserCan]);
|
3714 |
+
const navDomRef = Object(external_wp_element_["useRef"])(null);
|
3715 |
+
|
3716 |
+
const onBackClick = id => {
|
3717 |
+
Object(external_wc_tracks_["recordEvent"])('navigation_back_click', {
|
3718 |
+
category: id
|
3719 |
+
});
|
3720 |
+
};
|
3721 |
+
|
3722 |
+
const isRoot = activeLevel === 'woocommerce';
|
3723 |
+
const classes = classnames_default()('woocommerce-navigation', {
|
3724 |
+
'is-root': isRoot
|
3725 |
+
});
|
3726 |
+
return Object(external_wp_element_["createElement"])("div", {
|
3727 |
+
className: classes
|
3728 |
+
}, Object(external_wp_element_["createElement"])(header, null), Object(external_wp_element_["createElement"])("div", {
|
3729 |
+
className: "woocommerce-navigation__wrapper",
|
3730 |
+
ref: navDomRef
|
3731 |
+
}, Object(external_wp_element_["createElement"])(external_wc_experimental_["Navigation"], {
|
3732 |
+
activeItem: activeItem ? activeItem.id : null,
|
3733 |
+
activeMenu: activeLevel,
|
3734 |
+
onActivateMenu: (...args) => {
|
3735 |
+
if (navDomRef && navDomRef.current) {
|
3736 |
+
navDomRef.current.scrollTop = 0;
|
3737 |
+
}
|
3738 |
+
|
3739 |
+
setActiveLevel(...args);
|
3740 |
+
}
|
3741 |
+
}, Object.values(categories).map(category => {
|
3742 |
+
const categoryItems = items[category.id];
|
3743 |
+
return !!categoryItems && [Object(external_wp_element_["createElement"])(PrimaryMenu, {
|
3744 |
+
key: category.id,
|
3745 |
+
category: category,
|
3746 |
+
onBackClick: onBackClick,
|
3747 |
+
primaryItems: [...categoryItems.primary, ...categoryItems.favorites],
|
3748 |
+
pluginItems: categoryItems.plugins
|
3749 |
+
}), Object(external_wp_element_["createElement"])(SecondaryMenu, {
|
3750 |
+
key: `secondary/${category.id}`,
|
3751 |
+
category: category,
|
3752 |
+
onBackClick: onBackClick,
|
3753 |
+
items: categoryItems.secondary
|
3754 |
+
})];
|
3755 |
+
}))));
|
3756 |
+
};
|
3757 |
+
|
3758 |
+
/* harmony default export */ var container = (Container);
|
3759 |
+
// CONCATENATED MODULE: ./client/navigation/index.js
|
3760 |
+
/**
|
3761 |
+
* External dependencies
|
3762 |
+
*/
|
3763 |
+
|
3764 |
+
/**
|
3765 |
+
* Internal dependencies
|
3766 |
+
*/
|
3767 |
+
|
3768 |
+
|
3769 |
+
|
3770 |
+
const HydratedNavigation = Object(external_wc_data_["withNavigationHydration"])(window.wcNavigation)(container);
|
3771 |
+
/* harmony default export */ var navigation = (HydratedNavigation);
|
3772 |
+
// CONCATENATED MODULE: ./client/header/index.js
|
3773 |
+
|
3774 |
+
|
3775 |
+
/**
|
3776 |
+
* External dependencies
|
3777 |
+
*/
|
3778 |
+
|
3779 |
+
|
3780 |
+
|
3781 |
+
|
3782 |
+
|
3783 |
+
|
3784 |
+
|
3785 |
+
|
3786 |
+
|
3787 |
+
|
3788 |
+
|
3789 |
+
|
3790 |
+
/**
|
3791 |
+
* Internal dependencies
|
3792 |
+
*/
|
3793 |
+
|
3794 |
+
|
3795 |
+
|
3796 |
+
|
3797 |
+
|
3798 |
+
|
3799 |
+
|
3800 |
+
const renderTaskListBackButton = () => {
|
3801 |
+
const currentUrl = new URL(window.location.href);
|
3802 |
+
const task = currentUrl.searchParams.get('task');
|
3803 |
+
|
3804 |
+
if (task) {
|
3805 |
+
const homeText = Object(external_wp_i18n_["__"])('WooCommerce Home', 'woocommerce-admin');
|
3806 |
+
|
3807 |
+
const navigateHome = () => {
|
3808 |
+
Object(external_wc_tracks_["recordEvent"])('topbar_back_button', {
|
3809 |
+
page_name: getPageTitle(window.title)
|
3810 |
+
});
|
3811 |
+
Object(external_wc_navigation_["updateQueryString"])({}, Object(external_wc_navigation_["getHistory"])().location.pathname, {});
|
3812 |
+
}; // if it's a task list page, render a back button to the homescreen
|
3813 |
+
|
3814 |
+
|
3815 |
+
return Object(external_wp_element_["createElement"])(external_wp_components_["Tooltip"], {
|
3816 |
+
text: homeText
|
3817 |
+
}, Object(external_wp_element_["createElement"])("div", {
|
3818 |
+
tabIndex: "0",
|
3819 |
+
role: "button",
|
3820 |
+
"data-testid": "header-back-button",
|
3821 |
+
className: "woocommerce-layout__header-back-button",
|
3822 |
+
onKeyDown: ({
|
3823 |
+
keyCode
|
3824 |
+
}) => {
|
3825 |
+
if (keyCode === external_wp_keycodes_["ENTER"] || keyCode === external_wp_keycodes_["SPACE"]) {
|
3826 |
+
navigateHome();
|
3827 |
+
}
|
3828 |
+
}
|
3829 |
+
}, Object(external_wp_element_["createElement"])(build_module_icon["a" /* default */], {
|
3830 |
+
icon: chevron_left["a" /* default */],
|
3831 |
+
onClick: navigateHome
|
3832 |
+
})));
|
3833 |
+
}
|
3834 |
+
|
3835 |
+
return null;
|
3836 |
+
};
|
3837 |
+
|
3838 |
+
const getPageTitle = defaultTitle => {
|
3839 |
+
const currentUrl = new URL(window.location.href);
|
3840 |
+
const task = currentUrl.searchParams.get('task'); // If it's the task list then render a title based on which task the user is on.
|
3841 |
+
|
3842 |
+
return {
|
3843 |
+
payments: Object(external_wp_i18n_["__"])('Set up payments', 'woocommerce-admin'),
|
3844 |
+
tax: Object(external_wp_i18n_["__"])('Add tax rates', 'woocommerce-admin'),
|
3845 |
+
appearance: Object(external_wp_i18n_["__"])('Personalize your store', 'woocommerce-admin'),
|
3846 |
+
marketing: Object(external_wp_i18n_["__"])('Set up marketing tools', 'woocommerce-admin'),
|
3847 |
+
products: Object(external_wp_i18n_["__"])('Add products', 'woocommerce-admin'),
|
3848 |
+
shipping: Object(external_wp_i18n_["__"])('Set up shipping costs', 'woocommerce-admin')
|
3849 |
+
}[task] || defaultTitle;
|
3850 |
+
};
|
3851 |
+
|
3852 |
+
const header_Header = ({
|
3853 |
+
sections,
|
3854 |
+
isEmbedded = false,
|
3855 |
+
query
|
3856 |
+
}) => {
|
3857 |
+
const headerElement = Object(external_wp_element_["useRef"])(null);
|
3858 |
+
const siteTitle = Object(build_module["f" /* getSetting */])('siteTitle', '');
|
3859 |
+
const pageTitle = sections.slice(-1)[0];
|
3860 |
+
const isScrolled = useIsScrolled();
|
3861 |
+
const {
|
3862 |
+
updateUserPreferences,
|
3863 |
+
...userData
|
3864 |
+
} = Object(external_wc_data_["useUserPreferences"])();
|
3865 |
+
const isModalDismissed = userData.android_app_banner_dismissed === 'yes';
|
3866 |
+
let debounceTimer = null;
|
3867 |
+
const className = classnames_default()('woocommerce-layout__header', {
|
3868 |
+
'is-scrolled': isScrolled
|
3869 |
+
});
|
3870 |
+
Object(external_wp_element_["useLayoutEffect"])(() => {
|
3871 |
+
updateBodyMargin();
|
3872 |
+
window.addEventListener('resize', updateBodyMargin);
|
3873 |
+
return () => {
|
3874 |
+
window.removeEventListener('resize', updateBodyMargin);
|
3875 |
+
const wpBody = document.querySelector('#wpbody');
|
3876 |
+
|
3877 |
+
if (!wpBody) {
|
3878 |
+
return;
|
3879 |
+
}
|
3880 |
+
|
3881 |
+
wpBody.style.marginTop = null;
|
3882 |
+
};
|
3883 |
+
}, [isModalDismissed]);
|
3884 |
+
|
3885 |
+
const updateBodyMargin = () => {
|
3886 |
+
clearTimeout(debounceTimer);
|
3887 |
+
debounceTimer = setTimeout(function () {
|
3888 |
+
const wpBody = document.querySelector('#wpbody');
|
3889 |
+
|
3890 |
+
if (!wpBody || !headerElement.current) {
|
3891 |
+
return;
|
3892 |
+
}
|
3893 |
+
|
3894 |
+
wpBody.style.marginTop = `${headerElement.current.offsetHeight}px`;
|
3895 |
+
}, 200);
|
3896 |
+
};
|
3897 |
+
|
3898 |
+
Object(external_wp_element_["useEffect"])(() => {
|
3899 |
+
if (!isEmbedded) {
|
3900 |
+
const documentTitle = sections.map(section => {
|
3901 |
+
return Array.isArray(section) ? section[1] : section;
|
3902 |
+
}).reverse().join(' ‹ ');
|
3903 |
+
const decodedTitle = Object(external_wp_htmlEntities_["decodeEntities"])(Object(external_wp_i18n_["sprintf"])(
|
3904 |
+
/* translators: 1: document title. 2: page title */
|
3905 |
+
Object(external_wp_i18n_["__"])('%1$s ‹ %2$s — WooCommerce', 'woocommerce-admin'), documentTitle, siteTitle));
|
3906 |
+
|
3907 |
+
if (document.title !== decodedTitle) {
|
3908 |
+
document.title = decodedTitle;
|
3909 |
+
}
|
3910 |
+
}
|
3911 |
+
}, [isEmbedded, sections, siteTitle]);
|
3912 |
+
|
3913 |
+
const dismissHandler = () => {
|
3914 |
+
updateUserPreferences({
|
3915 |
+
android_app_banner_dismissed: 'yes'
|
3916 |
+
});
|
3917 |
+
};
|
3918 |
+
|
3919 |
+
const backButton = renderTaskListBackButton();
|
3920 |
+
const backButtonClass = backButton ? 'with-back-button' : '';
|
3921 |
+
return Object(external_wp_element_["createElement"])("div", {
|
3922 |
+
className: className,
|
3923 |
+
ref: headerElement
|
3924 |
+
}, !isModalDismissed && Object(external_wp_element_["createElement"])(MobileAppBanner, {
|
3925 |
+
onDismiss: dismissHandler,
|
3926 |
+
onInstall: dismissHandler
|
3927 |
+
}), Object(external_wp_element_["createElement"])("div", {
|
3928 |
+
className: "woocommerce-layout__header-wrapper"
|
3929 |
+
}, window.wcAdminFeatures.navigation && Object(external_wp_element_["createElement"])(navigation, null), renderTaskListBackButton(), Object(external_wp_element_["createElement"])(external_wc_experimental_["Text"], {
|
3930 |
+
className: `woocommerce-layout__header-heading ${backButtonClass}`,
|
3931 |
+
as: "h1"
|
3932 |
+
}, getPageTitle(Object(external_wp_htmlEntities_["decodeEntities"])(pageTitle))), window.wcAdminFeatures['activity-panels'] && Object(external_wp_element_["createElement"])(activity_panel, {
|
3933 |
+
isEmbedded: isEmbedded,
|
3934 |
+
query: query,
|
3935 |
+
userPreferencesData: { ...userData,
|
3936 |
+
updateUserPreferences
|
3937 |
+
}
|
3938 |
+
})));
|
3939 |
+
};
|
3940 |
+
// CONCATENATED MODULE: ./client/layout/notices.js
|
3941 |
+
|
3942 |
+
|
3943 |
+
/**
|
3944 |
+
* External dependencies
|
3945 |
+
*/
|
3946 |
+
|
3947 |
+
|
3948 |
+
class notices_Notices extends external_wp_element_["Component"] {
|
3949 |
+
render() {
|
3950 |
+
return Object(external_wp_element_["createElement"])("div", {
|
3951 |
+
id: "woocommerce-layout__notice-list",
|
3952 |
+
className: "woocommerce-layout__notice-list"
|
3953 |
+
});
|
3954 |
+
}
|
3955 |
+
|
3956 |
+
}
|
3957 |
+
|
3958 |
+
/* harmony default export */ var layout_notices = (notices_Notices);
|
3959 |
+
// EXTERNAL MODULE: ./node_modules/react-spring/web.cjs.js
|
3960 |
+
var web_cjs = __webpack_require__(159);
|
3961 |
+
|
3962 |
+
// EXTERNAL MODULE: ./client/layout/transient-notices/snackbar/index.js
|
3963 |
+
var snackbar = __webpack_require__(257);
|
3964 |
+
|
3965 |
+
// CONCATENATED MODULE: ./client/layout/transient-notices/snackbar/list.js
|
3966 |
+
|
3967 |
+
|
3968 |
+
|
3969 |
+
/**
|
3970 |
+
* External dependencies
|
3971 |
+
*/
|
3972 |
+
|
3973 |
+
|
3974 |
+
|
3975 |
+
|
3976 |
+
|
3977 |
+
/**
|
3978 |
+
* Internal dependencies
|
3979 |
+
*/
|
3980 |
+
|
3981 |
+
|
3982 |
+
/**
|
3983 |
+
* Renders a list of notices.
|
3984 |
+
*
|
3985 |
+
* @param {Object} $0 Props passed to the component.
|
3986 |
+
* @param {Array} $0.notices Array of notices to render.
|
3987 |
+
* @param {Function} $0.onRemove Function called when a notice should be removed / dismissed.
|
3988 |
+
* @param {Function} $0.onRemove2 Function called when a notice should be removed / dismissed.
|
3989 |
+
* @param {Object} $0.className Name of the class used by the component.
|
3990 |
+
* @param {Object} $0.children Array of children to be rendered inside the notice list.
|
3991 |
+
* @return {Object} The rendered notices list.
|
3992 |
+
*/
|
3993 |
+
|
3994 |
+
function SnackbarList({
|
3995 |
+
notices,
|
3996 |
+
className,
|
3997 |
+
children,
|
3998 |
+
onRemove = external_lodash_["noop"],
|
3999 |
+
onRemove2 = external_lodash_["noop"]
|
4000 |
+
}) {
|
4001 |
+
const isReducedMotion = Object(external_wp_compose_["useReducedMotion"])();
|
4002 |
+
const [refMap] = Object(external_wp_element_["useState"])(() => new WeakMap());
|
4003 |
+
const transitions = Object(web_cjs["useTransition"])(notices, notice => notice.id, {
|
4004 |
+
from: {
|
4005 |
+
opacity: 0,
|
4006 |
+
height: 0
|
4007 |
+
},
|
4008 |
+
enter: item => async next => await next({
|
4009 |
+
opacity: 1,
|
4010 |
+
height: refMap.get(item).offsetHeight
|
4011 |
+
}),
|
4012 |
+
leave: () => async next => {
|
4013 |
+
await next({
|
4014 |
+
opacity: 0
|
4015 |
+
});
|
4016 |
+
await next({
|
4017 |
+
height: 0
|
4018 |
+
});
|
4019 |
+
},
|
4020 |
+
immediate: isReducedMotion
|
4021 |
+
});
|
4022 |
+
className = classnames_default()('components-snackbar-list', className);
|
4023 |
+
|
4024 |
+
const removeNotice = notice => () => {
|
4025 |
+
onRemove(notice.id); // To be removed when we're no longer using core/notices2.
|
4026 |
+
|
4027 |
+
onRemove2(notice.id);
|
4028 |
+
};
|
4029 |
+
|
4030 |
+
return Object(external_wp_element_["createElement"])("div", {
|
4031 |
+
className: className
|
4032 |
+
}, children, transitions.map(({
|
4033 |
+
item: notice,
|
4034 |
+
key,
|
4035 |
+
props: style
|
4036 |
+
}) => Object(external_wp_element_["createElement"])(web_cjs["animated"].div, {
|
4037 |
+
key: key,
|
4038 |
+
style: style
|
4039 |
+
}, Object(external_wp_element_["createElement"])("div", {
|
4040 |
+
className: "components-snackbar-list__notice-container",
|
4041 |
+
ref: ref => ref && refMap.set(notice, ref)
|
4042 |
+
}, Object(external_wp_element_["createElement"])(snackbar["a" /* default */], extends_default()({}, Object(external_lodash_["omit"])(notice, ['content']), {
|
4043 |
+
onRemove: removeNotice(notice)
|
4044 |
+
}), notice.content)))));
|
4045 |
+
}
|
4046 |
+
|
4047 |
+
/* harmony default export */ var list = (SnackbarList);
|
4048 |
+
// EXTERNAL MODULE: ./client/layout/transient-notices/style.scss
|
4049 |
+
var transient_notices_style = __webpack_require__(298);
|
4050 |
+
|
4051 |
+
// CONCATENATED MODULE: ./client/layout/transient-notices/index.js
|
4052 |
+
|
4053 |
+
|
4054 |
+
/**
|
4055 |
+
* External dependencies
|
4056 |
+
*/
|
4057 |
+
|
4058 |
+
|
4059 |
+
|
4060 |
+
|
4061 |
+
|
4062 |
+
|
4063 |
+
/**
|
4064 |
+
* Internal dependencies
|
4065 |
+
*/
|
4066 |
+
|
4067 |
+
|
4068 |
+
|
4069 |
+
const QUEUE_OPTION = 'woocommerce_admin_transient_notices_queue';
|
4070 |
+
const QUEUED_NOTICE_FILTER = 'woocommerce_admin_queued_notice_filter';
|
4071 |
+
|
4072 |
+
function TransientNotices(props) {
|
4073 |
+
const {
|
4074 |
+
removeNotice: onRemove
|
4075 |
+
} = Object(external_wp_data_["useDispatch"])('core/notices');
|
4076 |
+
const {
|
4077 |
+
createNotice: createNotice2,
|
4078 |
+
removeNotice: onRemove2
|
4079 |
+
} = Object(external_wp_data_["useDispatch"])('core/notices2');
|
4080 |
+
const {
|
4081 |
+
updateOptions
|
4082 |
+
} = Object(external_wp_data_["useDispatch"])(external_wc_data_["OPTIONS_STORE_NAME"]);
|
4083 |
+
const {
|
4084 |
+
currentUser = {},
|
4085 |
+
notices = [],
|
4086 |
+
notices2 = [],
|
4087 |
+
noticesQueue = {}
|
4088 |
+
} = Object(external_wp_data_["useSelect"])(select => {
|
4089 |
+
// NOTE: This uses core/notices2, if this file is copied back upstream
|
4090 |
+
// to Gutenberg this needs to be changed back to just core/notices.
|
4091 |
+
return {
|
4092 |
+
currentUser: select(external_wc_data_["USER_STORE_NAME"]).getCurrentUser(),
|
4093 |
+
notices: select('core/notices').getNotices(),
|
4094 |
+
notices2: select('core/notices2').getNotices(),
|
4095 |
+
noticesQueue: select(external_wc_data_["OPTIONS_STORE_NAME"]).getOption(QUEUE_OPTION)
|
4096 |
+
};
|
4097 |
+
});
|
4098 |
+
|
4099 |
+
const getCurrentUserNotices = () => {
|
4100 |
+
return Object.values(noticesQueue).filter(notice => notice.user_id === currentUser.id || !notice.user_id);
|
4101 |
+
};
|
4102 |
+
|
4103 |
+
const dequeueNotice = id => {
|
4104 |
+
const remainingNotices = { ...noticesQueue
|
4105 |
+
};
|
4106 |
+
delete remainingNotices[id];
|
4107 |
+
updateOptions({
|
4108 |
+
[QUEUE_OPTION]: remainingNotices
|
4109 |
+
});
|
4110 |
+
};
|
4111 |
+
|
4112 |
+
Object(external_wp_element_["useEffect"])(() => {
|
4113 |
+
getCurrentUserNotices().forEach(queuedNotice => {
|
4114 |
+
const notice = Object(external_wp_hooks_["applyFilters"])(QUEUED_NOTICE_FILTER, queuedNotice);
|
4115 |
+
createNotice2(notice.status, notice.content, {
|
4116 |
+
onDismiss: () => {
|
4117 |
+
dequeueNotice(notice.id);
|
4118 |
+
},
|
4119 |
+
...(notice.options || {})
|
4120 |
+
});
|
4121 |
+
});
|
4122 |
+
}, []);
|
4123 |
+
/**
|
4124 |
+
* Combines the two notices in the component vs in the useSelect, as we don't want to
|
4125 |
+
* create new object references on each useSelect call.
|
4126 |
+
*/
|
4127 |
+
|
4128 |
+
const getNotices = () => {
|
4129 |
+
return notices.concat(notices2);
|
4130 |
+
};
|
4131 |
+
|
4132 |
+
const {
|
4133 |
+
className
|
4134 |
+
} = props;
|
4135 |
+
const classes = classnames_default()('woocommerce-transient-notices', 'components-notices__snackbar', className);
|
4136 |
+
const combinedNotices = getNotices();
|
4137 |
+
return Object(external_wp_element_["createElement"])(list, {
|
4138 |
+
notices: combinedNotices,
|
4139 |
+
className: classes,
|
4140 |
+
onRemove: onRemove,
|
4141 |
+
onRemove2: onRemove2
|
4142 |
+
});
|
4143 |
+
}
|
4144 |
+
|
4145 |
+
TransientNotices.propTypes = {
|
4146 |
+
/**
|
4147 |
+
* Additional class name to style the component.
|
4148 |
+
*/
|
4149 |
+
className: prop_types_default.a.string,
|
4150 |
+
|
4151 |
+
/**
|
4152 |
+
* Array of notices to be displayed.
|
4153 |
+
*/
|
4154 |
+
notices: prop_types_default.a.array
|
4155 |
+
};
|
4156 |
+
/* harmony default export */ var transient_notices = (TransientNotices);
|
4157 |
+
// CONCATENATED MODULE: ./client/layout/navigation.js
|
4158 |
+
|
4159 |
+
|
4160 |
+
/**
|
4161 |
+
* External dependencies
|
4162 |
+
*/
|
4163 |
+
|
4164 |
+
|
4165 |
+
|
4166 |
+
|
4167 |
+
|
4168 |
+
|
4169 |
+
/**
|
4170 |
+
* Internal dependencies
|
4171 |
+
*/
|
4172 |
+
|
4173 |
+
|
4174 |
+
|
4175 |
+
|
4176 |
+
|
4177 |
+
const NavigationPlugin = () => {
|
4178 |
+
const {
|
4179 |
+
persistedQuery
|
4180 |
+
} = Object(external_wp_data_["useSelect"])(select => {
|
4181 |
+
return {
|
4182 |
+
persistedQuery: select(external_wc_data_["NAVIGATION_STORE_NAME"]).getPersistedQuery()
|
4183 |
+
};
|
4184 |
+
});
|
4185 |
+
/**
|
4186 |
+
* If the current page is embedded, stay with the default urls
|
4187 |
+
* provided by Navigation because the router isn't present to
|
4188 |
+
* respond to <Link /> component's manipulation of the url.
|
4189 |
+
*/
|
4190 |
+
|
4191 |
+
if (!Object(utils["f" /* isWCAdmin */])(window.location.href)) {
|
4192 |
+
return null;
|
4193 |
+
}
|
4194 |
+
|
4195 |
+
const reports = Object(get_reports["a" /* default */])().filter(item => item.navArgs);
|
4196 |
+
const pages = getPages().filter(page => page.navArgs).map(page => {
|
4197 |
+
if (page.path === '/analytics/settings') {
|
4198 |
+
return { ...page,
|
4199 |
+
breadcrumbs: [Object(external_wp_i18n_["__"])('Analytics', 'woocommerce-admin')]
|
4200 |
+
};
|
4201 |
+
}
|
4202 |
+
|
4203 |
+
return page;
|
4204 |
+
});
|
4205 |
+
return Object(external_wp_element_["createElement"])(external_wp_element_["Fragment"], null, pages.map(page => Object(external_wp_element_["createElement"])(external_wc_navigation_["WooNavigationItem"], {
|
4206 |
+
item: page.navArgs.id,
|
4207 |
+
key: page.navArgs.id
|
4208 |
+
}, Object(external_wp_element_["createElement"])(external_wc_components_["Link"], {
|
4209 |
+
className: "components-button",
|
4210 |
+
href: Object(external_wc_navigation_["getNewPath"])(Object(external_wc_navigation_["pathIsExcluded"])(page.path) ? {} : persistedQuery, page.path, {}),
|
4211 |
+
type: "wc-admin"
|
4212 |
+
}, page.breadcrumbs[page.breadcrumbs.length - 1]))), reports.map(item => Object(external_wp_element_["createElement"])(external_wc_navigation_["WooNavigationItem"], {
|
4213 |
+
item: item.navArgs.id,
|
4214 |
+
key: item.navArgs.id
|
4215 |
+
}, Object(external_wp_element_["createElement"])(external_wc_components_["Link"], {
|
4216 |
+
className: "components-button",
|
4217 |
+
href: Object(external_wc_navigation_["getNewPath"])(Object(external_wc_navigation_["pathIsExcluded"])(item.report) ? {} : persistedQuery, `/analytics/${item.report}`, {}),
|
4218 |
+
type: "wc-admin"
|
4219 |
+
}, item.title))));
|
4220 |
+
};
|
4221 |
+
|
4222 |
+
Object(external_wp_plugins_["registerPlugin"])('wc-admin-navigation', {
|
4223 |
+
render: NavigationPlugin,
|
4224 |
+
scope: 'woocommerce-navigation'
|
4225 |
+
});
|
4226 |
+
// CONCATENATED MODULE: ./client/layout/index.js
|
4227 |
+
|
4228 |
+
|
4229 |
+
|
4230 |
+
/**
|
4231 |
+
* External dependencies
|
4232 |
+
*/
|
4233 |
+
|
4234 |
+
|
4235 |
+
|
4236 |
+
|
4237 |
+
|
4238 |
+
|
4239 |
+
|
4240 |
+
|
4241 |
+
|
4242 |
+
|
4243 |
+
|
4244 |
+
|
4245 |
+
|
4246 |
+
|
4247 |
+
/**
|
4248 |
+
* Internal dependencies
|
4249 |
+
*/
|
4250 |
+
|
4251 |
+
|
4252 |
+
|
4253 |
+
|
4254 |
+
|
4255 |
+
|
4256 |
+
|
4257 |
+
const StoreAlerts = Object(external_wp_element_["lazy"])(() => Promise.all(/* import() | store-alerts */[__webpack_require__.e(1), __webpack_require__.e(48)]).then(__webpack_require__.bind(null, 632)));
|
4258 |
+
const WCPayUsageModal = Object(external_wp_element_["lazy"])(() => __webpack_require__.e(/* import() | wcpay-usage-modal */ 53).then(__webpack_require__.bind(null, 524)));
|
4259 |
+
class layout_PrimaryLayout extends external_wp_element_["Component"] {
|
4260 |
+
render() {
|
4261 |
+
const {
|
4262 |
+
children
|
4263 |
+
} = this.props;
|
4264 |
+
return Object(external_wp_element_["createElement"])("div", {
|
4265 |
+
className: "woocommerce-layout__primary",
|
4266 |
+
id: "woocommerce-layout__primary"
|
4267 |
+
}, window.wcAdminFeatures['store-alerts'] && Object(external_wp_element_["createElement"])(external_wp_element_["Suspense"], {
|
4268 |
+
fallback: null
|
4269 |
+
}, Object(external_wp_element_["createElement"])(StoreAlerts, null)), Object(external_wp_element_["createElement"])(layout_notices, null), children);
|
4270 |
+
}
|
4271 |
+
|
4272 |
+
}
|
4273 |
+
|
4274 |
+
class layout_Layout extends external_wp_element_["Component"] {
|
4275 |
+
componentDidMount() {
|
4276 |
+
this.recordPageViewTrack();
|
4277 |
+
}
|
4278 |
+
|
4279 |
+
componentDidUpdate(prevProps) {
|
4280 |
+
const previousPath = Object(external_lodash_["get"])(prevProps, 'location.pathname');
|
4281 |
+
const currentPath = Object(external_lodash_["get"])(this.props, 'location.pathname');
|
4282 |
+
|
4283 |
+
if (!previousPath || !currentPath) {
|
4284 |
+
return;
|
4285 |
+
}
|
4286 |
+
|
4287 |
+
if (previousPath !== currentPath) {
|
4288 |
+
this.recordPageViewTrack();
|
4289 |
+
}
|
4290 |
+
}
|
4291 |
+
|
4292 |
+
recordPageViewTrack() {
|
4293 |
+
const {
|
4294 |
+
activePlugins,
|
4295 |
+
installedPlugins,
|
4296 |
+
isEmbedded,
|
4297 |
+
isJetpackConnected
|
4298 |
+
} = this.props;
|
4299 |
+
const navigationFlag = {
|
4300 |
+
has_navigation: !!window.wcNavigation
|
4301 |
+
};
|
4302 |
+
|
4303 |
+
if (isEmbedded) {
|
4304 |
+
const path = document.location.pathname + document.location.search;
|
4305 |
+
Object(external_wc_tracks_["recordPageView"])(path, {
|
4306 |
+
is_embedded: true,
|
4307 |
+
...navigationFlag
|
4308 |
+
});
|
4309 |
+
return;
|
4310 |
+
}
|
4311 |
+
|
4312 |
+
const pathname = Object(external_lodash_["get"])(this.props, 'location.pathname');
|
4313 |
+
|
4314 |
+
if (!pathname) {
|
4315 |
+
return;
|
4316 |
+
} // Remove leading slash, and camel case remaining pathname
|
4317 |
+
|
4318 |
+
|
4319 |
+
let path = pathname.substring(1).replace(/\//g, '_'); // When pathname is `/` we are on the home screen.
|
4320 |
+
|
4321 |
+
if (path.length === 0) {
|
4322 |
+
path = 'home_screen';
|
4323 |
+
}
|
4324 |
+
|
4325 |
+
Object(external_wc_tracks_["recordPageView"])(path, {
|
4326 |
+
jetpack_installed: installedPlugins.includes('jetpack'),
|
4327 |
+
jetpack_active: activePlugins.includes('jetpack'),
|
4328 |
+
jetpack_connected: isJetpackConnected,
|
4329 |
+
...navigationFlag
|
4330 |
+
});
|
4331 |
+
}
|
4332 |
+
|
4333 |
+
getQuery(searchString) {
|
4334 |
+
if (!searchString) {
|
4335 |
+
return {};
|
4336 |
+
}
|
4337 |
+
|
4338 |
+
const search = searchString.substring(1);
|
4339 |
+
return Object(lib["parse"])(search);
|
4340 |
+
}
|
4341 |
+
|
4342 |
+
isWCPaySettingsPage() {
|
4343 |
+
const {
|
4344 |
+
page,
|
4345 |
+
section,
|
4346 |
+
tab
|
4347 |
+
} = Object(external_wc_navigation_["getQuery"])();
|
4348 |
+
return page === 'wc-settings' && tab === 'checkout' && section === 'woocommerce_payments';
|
4349 |
+
}
|
4350 |
+
|
4351 |
+
render() {
|
4352 |
+
const {
|
4353 |
+
isEmbedded,
|
4354 |
+
...restProps
|
4355 |
+
} = this.props;
|
4356 |
+
const {
|
4357 |
+
location,
|
4358 |
+
page
|
4359 |
+
} = this.props;
|
4360 |
+
const {
|
4361 |
+
breadcrumbs
|
4362 |
+
} = page;
|
4363 |
+
const query = this.getQuery(location && location.search);
|
4364 |
+
return Object(external_wp_element_["createElement"])(external_wp_components_["SlotFillProvider"], null, Object(external_wp_element_["createElement"])("div", {
|
4365 |
+
className: "woocommerce-layout"
|
4366 |
+
}, Object(external_wp_element_["createElement"])(header_Header, {
|
4367 |
+
sections: Object(external_lodash_["isFunction"])(breadcrumbs) ? breadcrumbs(this.props) : breadcrumbs,
|
4368 |
+
isEmbedded: isEmbedded,
|
4369 |
+
query: query
|
4370 |
+
}), Object(external_wp_element_["createElement"])(transient_notices, null), !isEmbedded && Object(external_wp_element_["createElement"])(layout_PrimaryLayout, null, Object(external_wp_element_["createElement"])("div", {
|
4371 |
+
className: "woocommerce-layout__main"
|
4372 |
+
}, Object(external_wp_element_["createElement"])(controller_Controller, extends_default()({}, restProps, {
|
4373 |
+
query: query
|
4374 |
+
})))), isEmbedded && this.isWCPaySettingsPage() && Object(external_wp_element_["createElement"])(external_wp_element_["Suspense"], {
|
4375 |
+
fallback: null
|
4376 |
+
}, Object(external_wp_element_["createElement"])(WCPayUsageModal, null))), Object(external_wp_element_["createElement"])(external_wp_plugins_["PluginArea"], {
|
4377 |
+
scope: "woocommerce-admin"
|
4378 |
+
}), window.wcAdminFeatures.navigation && Object(external_wp_element_["createElement"])(external_wp_plugins_["PluginArea"], {
|
4379 |
+
scope: "woocommerce-navigation"
|
4380 |
+
}), Object(external_wp_element_["createElement"])(external_wp_plugins_["PluginArea"], {
|
4381 |
+
scope: "woocommerce-tasks"
|
4382 |
+
}));
|
4383 |
+
}
|
4384 |
+
|
4385 |
+
}
|
4386 |
+
|
4387 |
+
layout_Layout.propTypes = {
|
4388 |
+
isEmbedded: prop_types_default.a.bool,
|
4389 |
+
page: prop_types_default.a.shape({
|
4390 |
+
container: prop_types_default.a.oneOfType([prop_types_default.a.func, prop_types_default.a.object // Support React.lazy
|
4391 |
+
]),
|
4392 |
+
path: prop_types_default.a.string,
|
4393 |
+
breadcrumbs: prop_types_default.a.oneOfType([prop_types_default.a.func, prop_types_default.a.arrayOf(prop_types_default.a.oneOfType([prop_types_default.a.arrayOf(prop_types_default.a.string), prop_types_default.a.string]))]).isRequired,
|
4394 |
+
wpOpenMenu: prop_types_default.a.string
|
4395 |
+
}).isRequired
|
4396 |
+
};
|
4397 |
+
const dataEndpoints = Object(build_module["f" /* getSetting */])('dataEndpoints');
|
4398 |
+
const Layout = Object(external_wp_compose_["compose"])(Object(external_wc_data_["withPluginsHydration"])({ ...Object(build_module["f" /* getSetting */])('plugins', {}),
|
4399 |
+
jetpackStatus: dataEndpoints && dataEndpoints.jetpackStatus || false
|
4400 |
+
}), Object(external_wp_data_["withSelect"])((select, {
|
4401 |
+
isEmbedded
|
4402 |
+
}) => {
|
4403 |
+
// Embedded pages don't send plugin info to Tracks.
|
4404 |
+
if (isEmbedded) {
|
4405 |
+
return;
|
4406 |
+
}
|
4407 |
+
|
4408 |
+
const {
|
4409 |
+
getActivePlugins,
|
4410 |
+
getInstalledPlugins,
|
4411 |
+
isJetpackConnected
|
4412 |
+
} = select(external_wc_data_["PLUGINS_STORE_NAME"]);
|
4413 |
+
return {
|
4414 |
+
activePlugins: getActivePlugins(),
|
4415 |
+
isJetpackConnected: isJetpackConnected(),
|
4416 |
+
installedPlugins: getInstalledPlugins()
|
4417 |
+
};
|
4418 |
+
}))(layout_Layout);
|
4419 |
+
|
4420 |
+
const _PageLayout = () => {
|
4421 |
+
const {
|
4422 |
+
currentUserCan
|
4423 |
+
} = Object(external_wc_data_["useUser"])();
|
4424 |
+
return Object(external_wp_element_["createElement"])(react_router_Router, {
|
4425 |
+
history: Object(external_wc_navigation_["getHistory"])()
|
4426 |
+
}, Object(external_wp_element_["createElement"])(react_router_Switch, null, getPages().filter(page => !page.capability || currentUserCan(page.capability)).map(page => {
|
4427 |
+
return Object(external_wp_element_["createElement"])(react_router_Route, {
|
4428 |
+
key: page.path,
|
4429 |
+
path: page.path,
|
4430 |
+
exact: true,
|
4431 |
+
render: props => Object(external_wp_element_["createElement"])(Layout, extends_default()({
|
4432 |
+
page: page
|
4433 |
+
}, props))
|
4434 |
+
});
|
4435 |
+
})));
|
4436 |
+
};
|
4437 |
+
|
4438 |
+
const PageLayout = Object(external_wp_compose_["compose"])(window.wcSettings.admin ? Object(external_wc_data_["withOptionsHydration"])({ ...Object(build_module["f" /* getSetting */])('preloadOptions', {})
|
4439 |
+
}) : external_lodash_["identity"])(_PageLayout);
|
4440 |
+
|
4441 |
+
const _EmbedLayout = () => Object(external_wp_element_["createElement"])(Layout, {
|
4442 |
+
page: {
|
4443 |
+
breadcrumbs: Object(build_module["f" /* getSetting */])('embedBreadcrumbs', [])
|
4444 |
+
},
|
4445 |
+
isEmbedded: true
|
4446 |
+
});
|
4447 |
+
|
4448 |
+
const EmbedLayout = Object(external_wp_compose_["compose"])(Object(build_module["f" /* getSetting */])('preloadOptions') ? Object(external_wc_data_["withOptionsHydration"])({ ...Object(build_module["f" /* getSetting */])('preloadOptions')
|
4449 |
+
}) : external_lodash_["identity"])(_EmbedLayout);
|
4450 |
+
|
4451 |
+
/***/ }),
|
4452 |
+
|
4453 |
+
/***/ 12:
|
4454 |
+
/***/ (function(module, exports) {
|
4455 |
+
|
4456 |
+
(function() { module.exports = window["wc"]["navigation"]; }());
|
4457 |
+
|
4458 |
+
/***/ }),
|
4459 |
+
|
4460 |
+
/***/ 120:
|
4461 |
+
/***/ (function(module, exports) {
|
4462 |
+
|
4463 |
+
(function() { module.exports = window["wc"]["number"]; }());
|
4464 |
+
|
4465 |
+
/***/ }),
|
4466 |
+
|
4467 |
+
/***/ 121:
|
4468 |
+
/***/ (function(module, exports) {
|
4469 |
+
|
4470 |
+
(function() { module.exports = window["wc"]["explat"]; }());
|
4471 |
+
|
4472 |
+
/***/ }),
|
4473 |
+
|
4474 |
+
/***/ 127:
|
4475 |
+
/***/ (function(module, exports) {
|
4476 |
+
|
4477 |
+
(function() { module.exports = window["wp"]["notices"]; }());
|
4478 |
+
|
4479 |
+
/***/ }),
|
4480 |
+
|
4481 |
+
/***/ 128:
|
4482 |
+
/***/ (function(module, exports) {
|
4483 |
+
|
4484 |
+
// shim for using process in browser
|
4485 |
+
var process = module.exports = {};
|
4486 |
+
|
4487 |
+
// cached from whatever global is present so that test runners that stub it
|
4488 |
+
// don't break things. But we need to wrap it in a try catch in case it is
|
4489 |
+
// wrapped in strict mode code which doesn't define any globals. It's inside a
|
4490 |
+
// function because try/catches deoptimize in certain engines.
|
4491 |
+
|
4492 |
+
var cachedSetTimeout;
|
4493 |
+
var cachedClearTimeout;
|
4494 |
+
|
4495 |
+
function defaultSetTimout() {
|
4496 |
+
throw new Error('setTimeout has not been defined');
|
4497 |
+
}
|
4498 |
+
function defaultClearTimeout () {
|
4499 |
+
throw new Error('clearTimeout has not been defined');
|
4500 |
+
}
|
4501 |
+
(function () {
|
4502 |
+
try {
|
4503 |
+
if (typeof setTimeout === 'function') {
|
4504 |
+
cachedSetTimeout = setTimeout;
|
4505 |
+
} else {
|
4506 |
+
cachedSetTimeout = defaultSetTimout;
|
4507 |
+
}
|
4508 |
+
} catch (e) {
|
4509 |
+
cachedSetTimeout = defaultSetTimout;
|
4510 |
+
}
|
4511 |
+
try {
|
4512 |
+
if (typeof clearTimeout === 'function') {
|
4513 |
+
cachedClearTimeout = clearTimeout;
|
4514 |
+
} else {
|
4515 |
+
cachedClearTimeout = defaultClearTimeout;
|
4516 |
+
}
|
4517 |
+
} catch (e) {
|
4518 |
+
cachedClearTimeout = defaultClearTimeout;
|
4519 |
+
}
|
4520 |
+
} ())
|
4521 |
+
function runTimeout(fun) {
|
4522 |
+
if (cachedSetTimeout === setTimeout) {
|
4523 |
+
//normal enviroments in sane situations
|
4524 |
+
return setTimeout(fun, 0);
|
4525 |
+
}
|
4526 |
+
// if setTimeout wasn't available but was latter defined
|
4527 |
+
if ((cachedSetTimeout === defaultSetTimout || !cachedSetTimeout) && setTimeout) {
|
4528 |
+
cachedSetTimeout = setTimeout;
|
4529 |
+
return setTimeout(fun, 0);
|
4530 |
+
}
|
4531 |
+
try {
|
4532 |
+
// when when somebody has screwed with setTimeout but no I.E. maddness
|
4533 |
+
return cachedSetTimeout(fun, 0);
|
4534 |
+
} catch(e){
|
4535 |
+
try {
|
4536 |
+
// When we are in I.E. but the script has been evaled so I.E. doesn't trust the global object when called normally
|
4537 |
+
return cachedSetTimeout.call(null, fun, 0);
|
4538 |
+
} catch(e){
|
4539 |
+
// same as above but when it's a version of I.E. that must have the global object for 'this', hopfully our context correct otherwise it will throw a global error
|
4540 |
+
return cachedSetTimeout.call(this, fun, 0);
|
4541 |
+
}
|
4542 |
+
}
|
4543 |
+
|
4544 |
+
|
4545 |
+
}
|
4546 |
+
function runClearTimeout(marker) {
|
4547 |
+
if (cachedClearTimeout === clearTimeout) {
|
4548 |
+
//normal enviroments in sane situations
|
4549 |
+
return clearTimeout(marker);
|
4550 |
+
}
|
4551 |
+
// if clearTimeout wasn't available but was latter defined
|
4552 |
+
if ((cachedClearTimeout === defaultClearTimeout || !cachedClearTimeout) && clearTimeout) {
|
4553 |
+
cachedClearTimeout = clearTimeout;
|
4554 |
+
return clearTimeout(marker);
|
4555 |
+
}
|
4556 |
+
try {
|
4557 |
+
// when when somebody has screwed with setTimeout but no I.E. maddness
|
4558 |
+
return cachedClearTimeout(marker);
|
4559 |
+
} catch (e){
|
4560 |
+
try {
|
4561 |
+
// When we are in I.E. but the script has been evaled so I.E. doesn't trust the global object when called normally
|
4562 |
+
return cachedClearTimeout.call(null, marker);
|
4563 |
+
} catch (e){
|
4564 |
+
// same as above but when it's a version of I.E. that must have the global object for 'this', hopfully our context correct otherwise it will throw a global error.
|
4565 |
+
// Some versions of I.E. have different rules for clearTimeout vs setTimeout
|
4566 |
+
return cachedClearTimeout.call(this, marker);
|
4567 |
+
}
|
4568 |
+
}
|
4569 |
+
|
4570 |
+
|
4571 |
+
|
4572 |
+
}
|
4573 |
+
var queue = [];
|
4574 |
+
var draining = false;
|
4575 |
+
var currentQueue;
|
4576 |
+
var queueIndex = -1;
|
4577 |
+
|
4578 |
+
function cleanUpNextTick() {
|
4579 |
+
if (!draining || !currentQueue) {
|
4580 |
+
return;
|
4581 |
+
}
|
4582 |
+
draining = false;
|
4583 |
+
if (currentQueue.length) {
|
4584 |
+
queue = currentQueue.concat(queue);
|
4585 |
+
} else {
|
4586 |
+
queueIndex = -1;
|
4587 |
+
}
|
4588 |
+
if (queue.length) {
|
4589 |
+
drainQueue();
|
4590 |
+
}
|
4591 |
+
}
|
4592 |
+
|
4593 |
+
function drainQueue() {
|
4594 |
+
if (draining) {
|
4595 |
+
return;
|
4596 |
+
}
|
4597 |
+
var timeout = runTimeout(cleanUpNextTick);
|
4598 |
+
draining = true;
|
4599 |
+
|
4600 |
+
var len = queue.length;
|
4601 |
+
while(len) {
|
4602 |
+
currentQueue = queue;
|
4603 |
+
queue = [];
|
4604 |
+
while (++queueIndex < len) {
|
4605 |
+
if (currentQueue) {
|
4606 |
+
currentQueue[queueIndex].run();
|
4607 |
+
}
|
4608 |
+
}
|
4609 |
+
queueIndex = -1;
|
4610 |
+
len = queue.length;
|
4611 |
+
}
|
4612 |
+
currentQueue = null;
|
4613 |
+
draining = false;
|
4614 |
+
runClearTimeout(timeout);
|
4615 |
+
}
|
4616 |
+
|
4617 |
+
process.nextTick = function (fun) {
|
4618 |
+
var args = new Array(arguments.length - 1);
|
4619 |
+
if (arguments.length > 1) {
|
4620 |
+
for (var i = 1; i < arguments.length; i++) {
|
4621 |
+
args[i - 1] = arguments[i];
|
4622 |
+
}
|
4623 |
+
}
|
4624 |
+
queue.push(new Item(fun, args));
|
4625 |
+
if (queue.length === 1 && !draining) {
|
4626 |
+
runTimeout(drainQueue);
|
4627 |
+
}
|
4628 |
+
};
|
4629 |
+
|
4630 |
+
// v8 likes predictible objects
|
4631 |
+
function Item(fun, array) {
|
4632 |
+
this.fun = fun;
|
4633 |
+
this.array = array;
|
4634 |
+
}
|
4635 |
+
Item.prototype.run = function () {
|
4636 |
+
this.fun.apply(null, this.array);
|
4637 |
+
};
|
4638 |
+
process.title = 'browser';
|
4639 |
+
process.browser = true;
|
4640 |
+
process.env = {};
|
4641 |
+
process.argv = [];
|
4642 |
+
process.version = ''; // empty string to avoid regexp issues
|
4643 |
+
process.versions = {};
|
4644 |
+
|
4645 |
+
function noop() {}
|
4646 |
+
|
4647 |
+
process.on = noop;
|
4648 |
+
process.addListener = noop;
|
4649 |
+
process.once = noop;
|
4650 |
+
process.off = noop;
|
4651 |
+
process.removeListener = noop;
|
4652 |
+
process.removeAllListeners = noop;
|
4653 |
+
process.emit = noop;
|
4654 |
+
process.prependListener = noop;
|
4655 |
+
process.prependOnceListener = noop;
|
4656 |
+
|
4657 |
+
process.listeners = function (name) { return [] }
|
4658 |
+
|
4659 |
+
process.binding = function (name) {
|
4660 |
+
throw new Error('process.binding is not supported');
|
4661 |
+
};
|
4662 |
+
|
4663 |
+
process.cwd = function () { return '/' };
|
4664 |
+
process.chdir = function (dir) {
|
4665 |
+
throw new Error('process.chdir is not supported');
|
4666 |
+
};
|
4667 |
+
process.umask = function() { return 0; };
|
4668 |
+
|
4669 |
+
|
4670 |
+
/***/ }),
|
4671 |
+
|
4672 |
+
/***/ 129:
|
4673 |
+
/***/ (function(module, exports, __webpack_require__) {
|
4674 |
+
|
4675 |
+
"use strict";
|
4676 |
+
/** @license React v16.13.1
|
4677 |
+
* react-is.production.min.js
|
4678 |
+
*
|
4679 |
+
* Copyright (c) Facebook, Inc. and its affiliates.
|
4680 |
+
*
|
4681 |
+
* This source code is licensed under the MIT license found in the
|
4682 |
+
* LICENSE file in the root directory of this source tree.
|
4683 |
+
*/
|
4684 |
+
|
4685 |
+
var b="function"===typeof Symbol&&Symbol.for,c=b?Symbol.for("react.element"):60103,d=b?Symbol.for("react.portal"):60106,e=b?Symbol.for("react.fragment"):60107,f=b?Symbol.for("react.strict_mode"):60108,g=b?Symbol.for("react.profiler"):60114,h=b?Symbol.for("react.provider"):60109,k=b?Symbol.for("react.context"):60110,l=b?Symbol.for("react.async_mode"):60111,m=b?Symbol.for("react.concurrent_mode"):60111,n=b?Symbol.for("react.forward_ref"):60112,p=b?Symbol.for("react.suspense"):60113,q=b?
|
4686 |
+
Symbol.for("react.suspense_list"):60120,r=b?Symbol.for("react.memo"):60115,t=b?Symbol.for("react.lazy"):60116,v=b?Symbol.for("react.block"):60121,w=b?Symbol.for("react.fundamental"):60117,x=b?Symbol.for("react.responder"):60118,y=b?Symbol.for("react.scope"):60119;
|
4687 |
+
function z(a){if("object"===typeof a&&null!==a){var u=a.$$typeof;switch(u){case c:switch(a=a.type,a){case l:case m:case e:case g:case f:case p:return a;default:switch(a=a&&a.$$typeof,a){case k:case n:case t:case r:case h:return a;default:return u}}case d:return u}}}function A(a){return z(a)===m}exports.AsyncMode=l;exports.ConcurrentMode=m;exports.ContextConsumer=k;exports.ContextProvider=h;exports.Element=c;exports.ForwardRef=n;exports.Fragment=e;exports.Lazy=t;exports.Memo=r;exports.Portal=d;
|
4688 |
+
exports.Profiler=g;exports.StrictMode=f;exports.Suspense=p;exports.isAsyncMode=function(a){return A(a)||z(a)===l};exports.isConcurrentMode=A;exports.isContextConsumer=function(a){return z(a)===k};exports.isContextProvider=function(a){return z(a)===h};exports.isElement=function(a){return"object"===typeof a&&null!==a&&a.$$typeof===c};exports.isForwardRef=function(a){return z(a)===n};exports.isFragment=function(a){return z(a)===e};exports.isLazy=function(a){return z(a)===t};
|
4689 |
+
exports.isMemo=function(a){return z(a)===r};exports.isPortal=function(a){return z(a)===d};exports.isProfiler=function(a){return z(a)===g};exports.isStrictMode=function(a){return z(a)===f};exports.isSuspense=function(a){return z(a)===p};
|
4690 |
+
exports.isValidElementType=function(a){return"string"===typeof a||"function"===typeof a||a===e||a===m||a===g||a===f||a===p||a===q||"object"===typeof a&&null!==a&&(a.$$typeof===t||a.$$typeof===r||a.$$typeof===h||a.$$typeof===k||a.$$typeof===n||a.$$typeof===w||a.$$typeof===x||a.$$typeof===y||a.$$typeof===v)};exports.typeOf=z;
|
4691 |
+
|
4692 |
+
|
4693 |
+
/***/ }),
|
4694 |
+
|
4695 |
+
/***/ 13:
|
4696 |
+
/***/ (function(module, __webpack_exports__, __webpack_require__) {
|
4697 |
+
|
4698 |
+
"use strict";
|
4699 |
+
/* unused harmony export ADMIN_URL */
|
4700 |
+
/* unused harmony export COUNTRIES */
|
4701 |
+
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "a", function() { return CURRENCY; });
|
4702 |
+
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "b", function() { return LOCALE; });
|
4703 |
+
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "c", function() { return ORDER_STATUSES; });
|
4704 |
+
/* unused harmony export SITE_TITLE */
|
4705 |
+
/* unused harmony export WC_ASSET_URL */
|
4706 |
+
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "f", function() { return getSetting; });
|
4707 |
+
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "g", function() { return setSetting; });
|
4708 |
+
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "e", function() { return getAdminLink; });
|
4709 |
+
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "d", function() { return enqueueScript; });
|
4710 |
+
/* harmony import */ var _wordpress_i18n__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(2);
|
4711 |
+
/* harmony import */ var _wordpress_i18n__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(_wordpress_i18n__WEBPACK_IMPORTED_MODULE_0__);
|
4712 |
+
/**
|
4713 |
+
* External dependencies
|
4714 |
+
*/
|
4715 |
+
// Remove mutable data from settings object to prevent access. Data stores should be used instead.
|
4716 |
+
|
4717 |
+
const mutableSources = ['wcAdminSettings', 'preloadSettings'];
|
4718 |
+
const settings = typeof wcSettings === 'object' ? wcSettings : {};
|
4719 |
+
const SOURCE = Object.keys(settings).reduce((source, key) => {
|
4720 |
+
if (!mutableSources.includes(key)) {
|
4721 |
+
source[key] = settings[key];
|
4722 |
+
}
|
4723 |
+
|
4724 |
+
return source;
|
4725 |
+
}, {});
|
4726 |
+
Object.keys(settings.admin || {}).forEach(key => {
|
4727 |
+
if (!mutableSources.includes(key)) {
|
4728 |
+
SOURCE[key] = settings.admin[key];
|
4729 |
+
}
|
4730 |
+
});
|
4731 |
+
const ADMIN_URL = SOURCE.adminUrl;
|
4732 |
+
const COUNTRIES = SOURCE.countries;
|
4733 |
+
const CURRENCY = SOURCE.currency;
|
4734 |
+
const LOCALE = SOURCE.locale;
|
4735 |
+
const ORDER_STATUSES = SOURCE.orderStatuses;
|
4736 |
+
const SITE_TITLE = SOURCE.siteTitle;
|
4737 |
+
const WC_ASSET_URL = SOURCE.wcAssetUrl;
|
4738 |
+
/**
|
4739 |
+
* Retrieves a setting value from the setting state.
|
4740 |
+
*
|
4741 |
+
* @param {string} name The identifier for the setting.
|
4742 |
+
* @param {*} [fallback=false] The value to use as a fallback
|
4743 |
+
* if the setting is not in the
|
4744 |
+
* state.
|
4745 |
+
* @param {Function} [filter=( val ) => val] A callback for filtering the
|
4746 |
+
* value before it's returned.
|
4747 |
+
* Receives both the found value
|
4748 |
+
* (if it exists for the key) and
|
4749 |
+
* the provided fallback arg.
|
4750 |
+
*
|
4751 |
+
* @return {*} The value present in the settings state for the given
|
4752 |
+
* name.
|
4753 |
+
*/
|
4754 |
+
|
4755 |
+
function getSetting(name, fallback = false, filter = val => val) {
|
4756 |
+
if (mutableSources.includes(name)) {
|
4757 |
+
throw new Error(Object(_wordpress_i18n__WEBPACK_IMPORTED_MODULE_0__["__"])('Mutable settings should be accessed via data store.'));
|
4758 |
+
}
|
4759 |
+
|
4760 |
+
const value = SOURCE.hasOwnProperty(name) ? SOURCE[name] : fallback;
|
4761 |
+
return filter(value, fallback);
|
4762 |
+
}
|
4763 |
+
/**
|
4764 |
+
* Sets a value to a property on the settings state.
|
4765 |
+
*
|
4766 |
+
* NOTE: This feature is to be removed in favour of data stores when a full migration
|
4767 |
+
* is complete.
|
4768 |
+
*
|
4769 |
+
* @deprecated
|
4770 |
+
*
|
4771 |
+
* @param {string} name The setting property key for the
|
4772 |
+
* setting being mutated.
|
4773 |
+
* @param {*} value The value to set.
|
4774 |
+
* @param {Function} [filter=( val ) => val] Allows for providing a callback
|
4775 |
+
* to sanitize the setting (eg.
|
4776 |
+
* ensure it's a number)
|
4777 |
+
*/
|
4778 |
+
|
4779 |
+
function setSetting(name, value, filter = val => val) {
|
4780 |
+
if (mutableSources.includes(name)) {
|
4781 |
+
throw new Error(Object(_wordpress_i18n__WEBPACK_IMPORTED_MODULE_0__["__"])('Mutable settings should be mutated via data store.'));
|
4782 |
+
}
|
4783 |
+
|
4784 |
+
SOURCE[name] = filter(value);
|
4785 |
+
}
|
4786 |
+
/**
|
4787 |
+
* Returns a string with the site's wp-admin URL appended. JS version of `admin_url`.
|
4788 |
+
*
|
4789 |
+
* @param {string} path Relative path.
|
4790 |
+
* @return {string} Full admin URL.
|
4791 |
+
*/
|
4792 |
+
|
4793 |
+
function getAdminLink(path) {
|
4794 |
+
return (ADMIN_URL || '') + path;
|
4795 |
+
}
|
4796 |
+
/**
|
4797 |
+
* Adds a script to the page if it has not already been loaded. JS version of `wp_enqueue_script`.
|
4798 |
+
*
|
4799 |
+
* @param {Object} script WP_Script
|
4800 |
+
* @param {string} script.handle Script handle.
|
4801 |
+
* @param {string} script.src Script URL.
|
4802 |
+
*/
|
4803 |
+
|
4804 |
+
function enqueueScript(script) {
|
4805 |
+
return new Promise((resolve, reject) => {
|
4806 |
+
if (document.querySelector(`#${script.handle}-js`)) {
|
4807 |
+
resolve();
|
4808 |
+
}
|
4809 |
+
|
4810 |
+
const domElement = document.createElement('script');
|
4811 |
+
domElement.src = script.src;
|
4812 |
+
domElement.id = `${script.handle}-js`;
|
4813 |
+
domElement.async = true;
|
4814 |
+
domElement.onload = resolve;
|
4815 |
+
domElement.onerror = reject;
|
4816 |
+
document.body.appendChild(domElement);
|
4817 |
+
});
|
4818 |
+
}
|
4819 |
+
|
4820 |
+
/***/ }),
|
4821 |
+
|
4822 |
+
/***/ 14:
|
4823 |
+
/***/ (function(module, exports) {
|
4824 |
+
|
4825 |
+
(function() { module.exports = window["wp"]["compose"]; }());
|
4826 |
+
|
4827 |
+
/***/ }),
|
4828 |
+
|
4829 |
+
/***/ 15:
|
4830 |
+
/***/ (function(module, exports) {
|
4831 |
+
|
4832 |
+
(function() { module.exports = window["wc"]["tracks"]; }());
|
4833 |
+
|
4834 |
+
/***/ }),
|
4835 |
+
|
4836 |
+
/***/ 159:
|
4837 |
+
/***/ (function(module, exports, __webpack_require__) {
|
4838 |
+
|
4839 |
+
"use strict";
|
4840 |
+
|
4841 |
+
|
4842 |
+
Object.defineProperty(exports, '__esModule', { value: true });
|
4843 |
+
|
4844 |
+
function _interopDefault (ex) { return (ex && (typeof ex === 'object') && 'default' in ex) ? ex['default'] : ex; }
|
4845 |
+
|
4846 |
+
var _extends = _interopDefault(__webpack_require__(36));
|
4847 |
+
var _objectWithoutPropertiesLoose = _interopDefault(__webpack_require__(294));
|
4848 |
+
var React = __webpack_require__(5);
|
4849 |
+
var React__default = _interopDefault(React);
|
4850 |
+
var _inheritsLoose = _interopDefault(__webpack_require__(295));
|
4851 |
+
var _assertThisInitialized = _interopDefault(__webpack_require__(297));
|
4852 |
+
|
4853 |
+
var is = {
|
4854 |
+
arr: Array.isArray,
|
4855 |
+
obj: function obj(a) {
|
4856 |
+
return Object.prototype.toString.call(a) === '[object Object]';
|
4857 |
+
},
|
4858 |
+
fun: function fun(a) {
|
4859 |
+
return typeof a === 'function';
|
4860 |
+
},
|
4861 |
+
str: function str(a) {
|
4862 |
+
return typeof a === 'string';
|
4863 |
+
},
|
4864 |
+
num: function num(a) {
|
4865 |
+
return typeof a === 'number';
|
4866 |
+
},
|
4867 |
+
und: function und(a) {
|
4868 |
+
return a === void 0;
|
4869 |
+
},
|
4870 |
+
nul: function nul(a) {
|
4871 |
+
return a === null;
|
4872 |
+
},
|
4873 |
+
set: function set(a) {
|
4874 |
+
return a instanceof Set;
|
4875 |
+
},
|
4876 |
+
map: function map(a) {
|
4877 |
+
return a instanceof Map;
|
4878 |
+
},
|
4879 |
+
equ: function equ(a, b) {
|
4880 |
+
if (typeof a !== typeof b) return false;
|
4881 |
+
if (is.str(a) || is.num(a)) return a === b;
|
4882 |
+
if (is.obj(a) && is.obj(b) && Object.keys(a).length + Object.keys(b).length === 0) return true;
|
4883 |
+
var i;
|
4884 |
+
|
4885 |
+
for (i in a) {
|
4886 |
+
if (!(i in b)) return false;
|
4887 |
+
}
|
4888 |
+
|
4889 |
+
for (i in b) {
|
4890 |
+
if (a[i] !== b[i]) return false;
|
4891 |
+
}
|
4892 |
+
|
4893 |
+
return is.und(i) ? a === b : true;
|
4894 |
+
}
|
4895 |
+
};
|
4896 |
+
function merge(target, lowercase) {
|
4897 |
+
if (lowercase === void 0) {
|
4898 |
+
lowercase = true;
|
4899 |
+
}
|
4900 |
+
|
4901 |
+
return function (object) {
|
4902 |
+
return (is.arr(object) ? object : Object.keys(object)).reduce(function (acc, element) {
|
4903 |
+
var key = lowercase ? element[0].toLowerCase() + element.substring(1) : element;
|
4904 |
+
acc[key] = target(key);
|
4905 |
+
return acc;
|
4906 |
+
}, target);
|
4907 |
+
};
|
4908 |
+
}
|
4909 |
+
function useForceUpdate() {
|
4910 |
+
var _useState = React.useState(false),
|
4911 |
+
f = _useState[1];
|
4912 |
+
|
4913 |
+
var forceUpdate = React.useCallback(function () {
|
4914 |
+
return f(function (v) {
|
4915 |
+
return !v;
|
4916 |
+
});
|
4917 |
+
}, []);
|
4918 |
+
return forceUpdate;
|
4919 |
+
}
|
4920 |
+
function withDefault(value, defaultValue) {
|
4921 |
+
return is.und(value) || is.nul(value) ? defaultValue : value;
|
4922 |
+
}
|
4923 |
+
function toArray(a) {
|
4924 |
+
return !is.und(a) ? is.arr(a) ? a : [a] : [];
|
4925 |
+
}
|
4926 |
+
function callProp(obj) {
|
4927 |
+
for (var _len = arguments.length, args = new Array(_len > 1 ? _len - 1 : 0), _key = 1; _key < _len; _key++) {
|
4928 |
+
args[_key - 1] = arguments[_key];
|
4929 |
+
}
|
4930 |
+
|
4931 |
+
return is.fun(obj) ? obj.apply(void 0, args) : obj;
|
4932 |
+
}
|
4933 |
+
|
4934 |
+
function getForwardProps(props) {
|
4935 |
+
var to = props.to,
|
4936 |
+
from = props.from,
|
4937 |
+
config = props.config,
|
4938 |
+
onStart = props.onStart,
|
4939 |
+
onRest = props.onRest,
|
4940 |
+
onFrame = props.onFrame,
|
4941 |
+
children = props.children,
|
4942 |
+
reset = props.reset,
|
4943 |
+
reverse = props.reverse,
|
4944 |
+
force = props.force,
|
4945 |
+
immediate = props.immediate,
|
4946 |
+
delay = props.delay,
|
4947 |
+
attach = props.attach,
|
4948 |
+
destroyed = props.destroyed,
|
4949 |
+
interpolateTo = props.interpolateTo,
|
4950 |
+
ref = props.ref,
|
4951 |
+
lazy = props.lazy,
|
4952 |
+
forward = _objectWithoutPropertiesLoose(props, ["to", "from", "config", "onStart", "onRest", "onFrame", "children", "reset", "reverse", "force", "immediate", "delay", "attach", "destroyed", "interpolateTo", "ref", "lazy"]);
|
4953 |
+
|
4954 |
+
return forward;
|
4955 |
+
}
|
4956 |
+
|
4957 |
+
function interpolateTo(props) {
|
4958 |
+
var forward = getForwardProps(props);
|
4959 |
+
if (is.und(forward)) return _extends({
|
4960 |
+
to: forward
|
4961 |
+
}, props);
|
4962 |
+
var rest = Object.keys(props).reduce(function (a, k) {
|
4963 |
+
var _extends2;
|
4964 |
+
|
4965 |
+
return !is.und(forward[k]) ? a : _extends({}, a, (_extends2 = {}, _extends2[k] = props[k], _extends2));
|
4966 |
+
}, {});
|
4967 |
+
return _extends({
|
4968 |
+
to: forward
|
4969 |
+
}, rest);
|
4970 |
+
}
|
4971 |
+
function handleRef(ref, forward) {
|
4972 |
+
if (forward) {
|
4973 |
+
// If it's a function, assume it's a ref callback
|
4974 |
+
if (is.fun(forward)) forward(ref);else if (is.obj(forward)) {
|
4975 |
+
forward.current = ref;
|
4976 |
+
}
|
4977 |
+
}
|
4978 |
+
|
4979 |
+
return ref;
|
4980 |
+
}
|
4981 |
+
|
4982 |
+
var Animated =
|
4983 |
+
/*#__PURE__*/
|
4984 |
+
function () {
|
4985 |
+
function Animated() {
|
4986 |
+
this.payload = void 0;
|
4987 |
+
this.children = [];
|
4988 |
+
}
|
4989 |
+
|
4990 |
+
var _proto = Animated.prototype;
|
4991 |
+
|
4992 |
+
_proto.getAnimatedValue = function getAnimatedValue() {
|
4993 |
+
return this.getValue();
|
4994 |
+
};
|
4995 |
+
|
4996 |
+
_proto.getPayload = function getPayload() {
|
4997 |
+
return this.payload || this;
|
4998 |
+
};
|
4999 |
+
|
5000 |
+
_proto.attach = function attach() {};
|
5001 |
+
|
5002 |
+
_proto.detach = function detach() {};
|
5003 |
+
|
5004 |
+
_proto.getChildren = function getChildren() {
|
5005 |
+
return this.children;
|
5006 |
+
};
|
5007 |
+
|
5008 |
+
_proto.addChild = function addChild(child) {
|
5009 |
+
if (this.children.length === 0) this.attach();
|
5010 |
+
this.children.push(child);
|
5011 |
+
};
|
5012 |
+
|
5013 |
+
_proto.removeChild = function removeChild(child) {
|
5014 |
+
var index = this.children.indexOf(child);
|
5015 |
+
this.children.splice(index, 1);
|
5016 |
+
if (this.children.length === 0) this.detach();
|
5017 |
+
};
|
5018 |
+
|
5019 |
+
return Animated;
|
5020 |
+
}();
|
5021 |
+
var AnimatedArray =
|
5022 |
+
/*#__PURE__*/
|
5023 |
+
function (_Animated) {
|
5024 |
+
_inheritsLoose(AnimatedArray, _Animated);
|
5025 |
+
|
5026 |
+
function AnimatedArray() {
|
5027 |
+
var _this;
|
5028 |
+
|
5029 |
+
for (var _len = arguments.length, args = new Array(_len), _key = 0; _key < _len; _key++) {
|
5030 |
+
args[_key] = arguments[_key];
|
5031 |
+
}
|
5032 |
+
|
5033 |
+
_this = _Animated.call.apply(_Animated, [this].concat(args)) || this;
|
5034 |
+
_this.payload = [];
|
5035 |
+
|
5036 |
+
_this.attach = function () {
|
5037 |
+
return _this.payload.forEach(function (p) {
|
5038 |
+
return p instanceof Animated && p.addChild(_assertThisInitialized(_this));
|
5039 |
+
});
|
5040 |
+
};
|
5041 |
+
|
5042 |
+
_this.detach = function () {
|
5043 |
+
return _this.payload.forEach(function (p) {
|
5044 |
+
return p instanceof Animated && p.removeChild(_assertThisInitialized(_this));
|
5045 |
+
});
|
5046 |
+
};
|
5047 |
+
|
5048 |
+
return _this;
|
5049 |
+
}
|
5050 |
+
|
5051 |
+
return AnimatedArray;
|
5052 |
+
}(Animated);
|
5053 |
+
var AnimatedObject =
|
5054 |
+
/*#__PURE__*/
|
5055 |
+
function (_Animated2) {
|
5056 |
+
_inheritsLoose(AnimatedObject, _Animated2);
|
5057 |
+
|
5058 |
+
function AnimatedObject() {
|
5059 |
+
var _this2;
|
5060 |
+
|
5061 |
+
for (var _len3 = arguments.length, args = new Array(_len3), _key3 = 0; _key3 < _len3; _key3++) {
|
5062 |
+
args[_key3] = arguments[_key3];
|
5063 |
+
}
|
5064 |
+
|
5065 |
+
_this2 = _Animated2.call.apply(_Animated2, [this].concat(args)) || this;
|
5066 |
+
_this2.payload = {};
|
5067 |
+
|
5068 |
+
_this2.attach = function () {
|
5069 |
+
return Object.values(_this2.payload).forEach(function (s) {
|
5070 |
+
return s instanceof Animated && s.addChild(_assertThisInitialized(_this2));
|
5071 |
+
});
|
5072 |
+
};
|
5073 |
+
|
5074 |
+
_this2.detach = function () {
|
5075 |
+
return Object.values(_this2.payload).forEach(function (s) {
|
5076 |
+
return s instanceof Animated && s.removeChild(_assertThisInitialized(_this2));
|
5077 |
+
});
|
5078 |
+
};
|
5079 |
+
|
5080 |
+
return _this2;
|
5081 |
+
}
|
5082 |
+
|
5083 |
+
var _proto2 = AnimatedObject.prototype;
|
5084 |
+
|
5085 |
+
_proto2.getValue = function getValue(animated) {
|
5086 |
+
if (animated === void 0) {
|
5087 |
+
animated = false;
|
5088 |
+
}
|
5089 |
+
|
5090 |
+
var payload = {};
|
5091 |
+
|
5092 |
+
for (var _key4 in this.payload) {
|
5093 |
+
var value = this.payload[_key4];
|
5094 |
+
if (animated && !(value instanceof Animated)) continue;
|
5095 |
+
payload[_key4] = value instanceof Animated ? value[animated ? 'getAnimatedValue' : 'getValue']() : value;
|
5096 |
+
}
|
5097 |
+
|
5098 |
+
return payload;
|
5099 |
+
};
|
5100 |
+
|
5101 |
+
_proto2.getAnimatedValue = function getAnimatedValue() {
|
5102 |
+
return this.getValue(true);
|
5103 |
+
};
|
5104 |
+
|
5105 |
+
return AnimatedObject;
|
5106 |
+
}(Animated);
|
5107 |
+
|
5108 |
+
var applyAnimatedValues;
|
5109 |
+
function injectApplyAnimatedValues(fn, transform) {
|
5110 |
+
applyAnimatedValues = {
|
5111 |
+
fn: fn,
|
5112 |
+
transform: transform
|
5113 |
+
};
|
5114 |
+
}
|
5115 |
+
var colorNames;
|
5116 |
+
function injectColorNames(names) {
|
5117 |
+
colorNames = names;
|
5118 |
+
}
|
5119 |
+
var requestFrame = function requestFrame(cb) {
|
5120 |
+
return typeof window !== 'undefined' ? window.requestAnimationFrame(cb) : -1;
|
5121 |
+
};
|
5122 |
+
var cancelFrame = function cancelFrame(id) {
|
5123 |
+
typeof window !== 'undefined' && window.cancelAnimationFrame(id);
|
5124 |
+
};
|
5125 |
+
function injectFrame(raf, caf) {
|
5126 |
+
requestFrame = raf;
|
5127 |
+
cancelFrame = caf;
|
5128 |
+
}
|
5129 |
+
var interpolation;
|
5130 |
+
function injectStringInterpolator(fn) {
|
5131 |
+
interpolation = fn;
|
5132 |
+
}
|
5133 |
+
var now = function now() {
|
5134 |
+
return Date.now();
|
5135 |
+
};
|
5136 |
+
function injectNow(nowFn) {
|
5137 |
+
now = nowFn;
|
5138 |
+
}
|
5139 |
+
var defaultElement;
|
5140 |
+
function injectDefaultElement(el) {
|
5141 |
+
defaultElement = el;
|
5142 |
+
}
|
5143 |
+
var animatedApi = function animatedApi(node) {
|
5144 |
+
return node.current;
|
5145 |
+
};
|
5146 |
+
function injectAnimatedApi(fn) {
|
5147 |
+
animatedApi = fn;
|
5148 |
+
}
|
5149 |
+
var createAnimatedStyle;
|
5150 |
+
function injectCreateAnimatedStyle(factory) {
|
5151 |
+
createAnimatedStyle = factory;
|
5152 |
+
}
|
5153 |
+
var manualFrameloop;
|
5154 |
+
function injectManualFrameloop(callback) {
|
5155 |
+
manualFrameloop = callback;
|
5156 |
+
}
|
5157 |
+
|
5158 |
+
var Globals = /*#__PURE__*/Object.freeze({
|
5159 |
+
get applyAnimatedValues () { return applyAnimatedValues; },
|
5160 |
+
injectApplyAnimatedValues: injectApplyAnimatedValues,
|
5161 |
+
get colorNames () { return colorNames; },
|
5162 |
+
injectColorNames: injectColorNames,
|
5163 |
+
get requestFrame () { return requestFrame; },
|
5164 |
+
get cancelFrame () { return cancelFrame; },
|
5165 |
+
injectFrame: injectFrame,
|
5166 |
+
get interpolation () { return interpolation; },
|
5167 |
+
injectStringInterpolator: injectStringInterpolator,
|
5168 |
+
get now () { return now; },
|
5169 |
+
injectNow: injectNow,
|
5170 |
+
get defaultElement () { return defaultElement; },
|
5171 |
+
injectDefaultElement: injectDefaultElement,
|
5172 |
+
get animatedApi () { return animatedApi; },
|
5173 |
+
injectAnimatedApi: injectAnimatedApi,
|
5174 |
+
get createAnimatedStyle () { return createAnimatedStyle; },
|
5175 |
+
injectCreateAnimatedStyle: injectCreateAnimatedStyle,
|
5176 |
+
get manualFrameloop () { return manualFrameloop; },
|
5177 |
+
injectManualFrameloop: injectManualFrameloop
|
5178 |
+
});
|
5179 |
+
|
5180 |
+
/**
|
5181 |
+
* Wraps the `style` property with `AnimatedStyle`.
|
5182 |
+
*/
|
5183 |
+
|
5184 |
+
var AnimatedProps =
|
5185 |
+
/*#__PURE__*/
|
5186 |
+
function (_AnimatedObject) {
|
5187 |
+
_inheritsLoose(AnimatedProps, _AnimatedObject);
|
5188 |
+
|
5189 |
+
function AnimatedProps(props, callback) {
|
5190 |
+
var _this;
|
5191 |
+
|
5192 |
+
_this = _AnimatedObject.call(this) || this;
|
5193 |
+
_this.update = void 0;
|
5194 |
+
_this.payload = !props.style ? props : _extends({}, props, {
|
5195 |
+
style: createAnimatedStyle(props.style)
|
5196 |
+
});
|
5197 |
+
_this.update = callback;
|
5198 |
+
|
5199 |
+
_this.attach();
|
5200 |
+
|
5201 |
+
return _this;
|
5202 |
+
}
|
5203 |
+
|
5204 |
+
return AnimatedProps;
|
5205 |
+
}(AnimatedObject);
|
5206 |
+
|
5207 |
+
var isFunctionComponent = function isFunctionComponent(val) {
|
5208 |
+
return is.fun(val) && !(val.prototype instanceof React__default.Component);
|
5209 |
+
};
|
5210 |
+
|
5211 |
+
var createAnimatedComponent = function createAnimatedComponent(Component) {
|
5212 |
+
var AnimatedComponent = React.forwardRef(function (props, ref) {
|
5213 |
+
var forceUpdate = useForceUpdate();
|
5214 |
+
var mounted = React.useRef(true);
|
5215 |
+
var propsAnimated = React.useRef(null);
|
5216 |
+
var node = React.useRef(null);
|
5217 |
+
var attachProps = React.useCallback(function (props) {
|
5218 |
+
var oldPropsAnimated = propsAnimated.current;
|
5219 |
+
|
5220 |
+
var callback = function callback() {
|
5221 |
+
var didUpdate = false;
|
5222 |
+
|
5223 |
+
if (node.current) {
|
5224 |
+
didUpdate = applyAnimatedValues.fn(node.current, propsAnimated.current.getAnimatedValue());
|
5225 |
+
}
|
5226 |
+
|
5227 |
+
if (!node.current || didUpdate === false) {
|
5228 |
+
// If no referenced node has been found, or the update target didn't have a
|
5229 |
+
// native-responder, then forceUpdate the animation ...
|
5230 |
+
forceUpdate();
|
5231 |
+
}
|
5232 |
+
};
|
5233 |
+
|
5234 |
+
propsAnimated.current = new AnimatedProps(props, callback);
|
5235 |
+
oldPropsAnimated && oldPropsAnimated.detach();
|
5236 |
+
}, []);
|
5237 |
+
React.useEffect(function () {
|
5238 |
+
return function () {
|
5239 |
+
mounted.current = false;
|
5240 |
+
propsAnimated.current && propsAnimated.current.detach();
|
5241 |
+
};
|
5242 |
+
}, []);
|
5243 |
+
React.useImperativeHandle(ref, function () {
|
5244 |
+
return animatedApi(node, mounted, forceUpdate);
|
5245 |
+
});
|
5246 |
+
attachProps(props);
|
5247 |
+
|
5248 |
+
var _getValue = propsAnimated.current.getValue(),
|
5249 |
+
scrollTop = _getValue.scrollTop,
|
5250 |
+
scrollLeft = _getValue.scrollLeft,
|
5251 |
+
animatedProps = _objectWithoutPropertiesLoose(_getValue, ["scrollTop", "scrollLeft"]); // Functions cannot have refs, see:
|
5252 |
+
// See: https://github.com/react-spring/react-spring/issues/569
|
5253 |
+
|
5254 |
+
|
5255 |
+
var refFn = isFunctionComponent(Component) ? undefined : function (childRef) {
|
5256 |
+
return node.current = handleRef(childRef, ref);
|
5257 |
+
};
|
5258 |
+
return React__default.createElement(Component, _extends({}, animatedProps, {
|
5259 |
+
ref: refFn
|
5260 |
+
}));
|
5261 |
+
});
|
5262 |
+
return AnimatedComponent;
|
5263 |
+
};
|
5264 |
+
|
5265 |
+
var active = false;
|
5266 |
+
var controllers = new Set();
|
5267 |
+
|
5268 |
+
var update = function update() {
|
5269 |
+
if (!active) return false;
|
5270 |
+
var time = now();
|
5271 |
+
|
5272 |
+
for (var _iterator = controllers, _isArray = Array.isArray(_iterator), _i = 0, _iterator = _isArray ? _iterator : _iterator[Symbol.iterator]();;) {
|
5273 |
+
var _ref;
|
5274 |
+
|
5275 |
+
if (_isArray) {
|
5276 |
+
if (_i >= _iterator.length) break;
|
5277 |
+
_ref = _iterator[_i++];
|
5278 |
+
} else {
|
5279 |
+
_i = _iterator.next();
|
5280 |
+
if (_i.done) break;
|
5281 |
+
_ref = _i.value;
|
5282 |
+
}
|
5283 |
+
|
5284 |
+
var controller = _ref;
|
5285 |
+
var isActive = false;
|
5286 |
+
|
5287 |
+
for (var configIdx = 0; configIdx < controller.configs.length; configIdx++) {
|
5288 |
+
var config = controller.configs[configIdx];
|
5289 |
+
var endOfAnimation = void 0,
|
5290 |
+
lastTime = void 0;
|
5291 |
+
|
5292 |
+
for (var valIdx = 0; valIdx < config.animatedValues.length; valIdx++) {
|
5293 |
+
var animation = config.animatedValues[valIdx]; // If an animation is done, skip, until all of them conclude
|
5294 |
+
|
5295 |
+
if (animation.done) continue;
|
5296 |
+
var from = config.fromValues[valIdx];
|
5297 |
+
var to = config.toValues[valIdx];
|
5298 |
+
var position = animation.lastPosition;
|
5299 |
+
var isAnimated = to instanceof Animated;
|
5300 |
+
var velocity = Array.isArray(config.initialVelocity) ? config.initialVelocity[valIdx] : config.initialVelocity;
|
5301 |
+
if (isAnimated) to = to.getValue(); // Conclude animation if it's either immediate, or from-values match end-state
|
5302 |
+
|
5303 |
+
if (config.immediate) {
|
5304 |
+
animation.setValue(to);
|
5305 |
+
animation.done = true;
|
5306 |
+
continue;
|
5307 |
+
} // Break animation when string values are involved
|
5308 |
+
|
5309 |
+
|
5310 |
+
if (typeof from === 'string' || typeof to === 'string') {
|
5311 |
+
animation.setValue(to);
|
5312 |
+
animation.done = true;
|
5313 |
+
continue;
|
5314 |
+
}
|
5315 |
+
|
5316 |
+
if (config.duration !== void 0) {
|
5317 |
+
/** Duration easing */
|
5318 |
+
position = from + config.easing((time - animation.startTime) / config.duration) * (to - from);
|
5319 |
+
endOfAnimation = time >= animation.startTime + config.duration;
|
5320 |
+
} else if (config.decay) {
|
5321 |
+
/** Decay easing */
|
5322 |
+
position = from + velocity / (1 - 0.998) * (1 - Math.exp(-(1 - 0.998) * (time - animation.startTime)));
|
5323 |
+
endOfAnimation = Math.abs(animation.lastPosition - position) < 0.1;
|
5324 |
+
if (endOfAnimation) to = position;
|
5325 |
+
} else {
|
5326 |
+
/** Spring easing */
|
5327 |
+
lastTime = animation.lastTime !== void 0 ? animation.lastTime : time;
|
5328 |
+
velocity = animation.lastVelocity !== void 0 ? animation.lastVelocity : config.initialVelocity; // If we lost a lot of frames just jump to the end.
|
5329 |
+
|
5330 |
+
if (time > lastTime + 64) lastTime = time; // http://gafferongames.com/game-physics/fix-your-timestep/
|
5331 |
+
|
5332 |
+
var numSteps = Math.floor(time - lastTime);
|
5333 |
+
|
5334 |
+
for (var i = 0; i < numSteps; ++i) {
|
5335 |
+
var force = -config.tension * (position - to);
|
5336 |
+
var damping = -config.friction * velocity;
|
5337 |
+
var acceleration = (force + damping) / config.mass;
|
5338 |
+
velocity = velocity + acceleration * 1 / 1000;
|
5339 |
+
position = position + velocity * 1 / 1000;
|
5340 |
+
} // Conditions for stopping the spring animation
|
5341 |
+
|
5342 |
+
|
5343 |
+
var isOvershooting = config.clamp && config.tension !== 0 ? from < to ? position > to : position < to : false;
|
5344 |
+
var isVelocity = Math.abs(velocity) <= config.precision;
|
5345 |
+
var isDisplacement = config.tension !== 0 ? Math.abs(to - position) <= config.precision : true;
|
5346 |
+
endOfAnimation = isOvershooting || isVelocity && isDisplacement;
|
5347 |
+
animation.lastVelocity = velocity;
|
5348 |
+
animation.lastTime = time;
|
5349 |
+
} // Trails aren't done until their parents conclude
|
5350 |
+
|
5351 |
+
|
5352 |
+
if (isAnimated && !config.toValues[valIdx].done) endOfAnimation = false;
|
5353 |
+
|
5354 |
+
if (endOfAnimation) {
|
5355 |
+
// Ensure that we end up with a round value
|
5356 |
+
if (animation.value !== to) position = to;
|
5357 |
+
animation.done = true;
|
5358 |
+
} else isActive = true;
|
5359 |
+
|
5360 |
+
animation.setValue(position);
|
5361 |
+
animation.lastPosition = position;
|
5362 |
+
} // Keep track of updated values only when necessary
|
5363 |
+
|
5364 |
+
|
5365 |
+
if (controller.props.onFrame) controller.values[config.name] = config.interpolation.getValue();
|
5366 |
+
} // Update callbacks in the end of the frame
|
5367 |
+
|
5368 |
+
|
5369 |
+
if (controller.props.onFrame) controller.props.onFrame(controller.values); // Either call onEnd or next frame
|
5370 |
+
|
5371 |
+
if (!isActive) {
|
5372 |
+
controllers.delete(controller);
|
5373 |
+
controller.stop(true);
|
5374 |
+
}
|
5375 |
+
} // Loop over as long as there are controllers ...
|
5376 |
+
|
5377 |
+
|
5378 |
+
if (controllers.size) {
|
5379 |
+
if (manualFrameloop) manualFrameloop();else requestFrame(update);
|
5380 |
+
} else {
|
5381 |
+
active = false;
|
5382 |
+
}
|
5383 |
+
|
5384 |
+
return active;
|
5385 |
+
};
|
5386 |
+
|
5387 |
+
var start = function start(controller) {
|
5388 |
+
if (!controllers.has(controller)) controllers.add(controller);
|
5389 |
+
|
5390 |
+
if (!active) {
|
5391 |
+
active = true;
|
5392 |
+
if (manualFrameloop) requestFrame(manualFrameloop);else requestFrame(update);
|
5393 |
+
}
|
5394 |
+
};
|
5395 |
+
|
5396 |
+
var stop = function stop(controller) {
|
5397 |
+
if (controllers.has(controller)) controllers.delete(controller);
|
5398 |
+
};
|
5399 |
+
|
5400 |
+
function createInterpolator(range, output, extrapolate) {
|
5401 |
+
if (typeof range === 'function') {
|
5402 |
+
return range;
|
5403 |
+
}
|
5404 |
+
|
5405 |
+
if (Array.isArray(range)) {
|
5406 |
+
return createInterpolator({
|
5407 |
+
range: range,
|
5408 |
+
output: output,
|
5409 |
+
extrapolate: extrapolate
|
5410 |
+
});
|
5411 |
+
}
|
5412 |
+
|
5413 |
+
if (interpolation && typeof range.output[0] === 'string') {
|
5414 |
+
return interpolation(range);
|
5415 |
+
}
|
5416 |
+
|
5417 |
+
var config = range;
|
5418 |
+
var outputRange = config.output;
|
5419 |
+
var inputRange = config.range || [0, 1];
|
5420 |
+
var extrapolateLeft = config.extrapolateLeft || config.extrapolate || 'extend';
|
5421 |
+
var extrapolateRight = config.extrapolateRight || config.extrapolate || 'extend';
|
5422 |
+
|
5423 |
+
var easing = config.easing || function (t) {
|
5424 |
+
return t;
|
5425 |
+
};
|
5426 |
+
|
5427 |
+
return function (input) {
|
5428 |
+
var range = findRange(input, inputRange);
|
5429 |
+
return interpolate(input, inputRange[range], inputRange[range + 1], outputRange[range], outputRange[range + 1], easing, extrapolateLeft, extrapolateRight, config.map);
|
5430 |
+
};
|
5431 |
+
}
|
5432 |
+
|
5433 |
+
function interpolate(input, inputMin, inputMax, outputMin, outputMax, easing, extrapolateLeft, extrapolateRight, map) {
|
5434 |
+
var result = map ? map(input) : input; // Extrapolate
|
5435 |
+
|
5436 |
+
if (result < inputMin) {
|
5437 |
+
if (extrapolateLeft === 'identity') return result;else if (extrapolateLeft === 'clamp') result = inputMin;
|
5438 |
+
}
|
5439 |
+
|
5440 |
+
if (result > inputMax) {
|
5441 |
+
if (extrapolateRight === 'identity') return result;else if (extrapolateRight === 'clamp') result = inputMax;
|
5442 |
+
}
|
5443 |
+
|
5444 |
+
if (outputMin === outputMax) return outputMin;
|
5445 |
+
if (inputMin === inputMax) return input <= inputMin ? outputMin : outputMax; // Input Range
|
5446 |
+
|
5447 |
+
if (inputMin === -Infinity) result = -result;else if (inputMax === Infinity) result = result - inputMin;else result = (result - inputMin) / (inputMax - inputMin); // Easing
|
5448 |
+
|
5449 |
+
result = easing(result); // Output Range
|
5450 |
+
|
5451 |
+
if (outputMin === -Infinity) result = -result;else if (outputMax === Infinity) result = result + outputMin;else result = result * (outputMax - outputMin) + outputMin;
|
5452 |
+
return result;
|
5453 |
+
}
|
5454 |
+
|
5455 |
+
function findRange(input, inputRange) {
|
5456 |
+
for (var i = 1; i < inputRange.length - 1; ++i) {
|
5457 |
+
if (inputRange[i] >= input) break;
|
5458 |
+
}
|
5459 |
+
|
5460 |
+
return i - 1;
|
5461 |
+
}
|
5462 |
+
|
5463 |
+
var AnimatedInterpolation =
|
5464 |
+
/*#__PURE__*/
|
5465 |
+
function (_AnimatedArray) {
|
5466 |
+
_inheritsLoose(AnimatedInterpolation, _AnimatedArray);
|
5467 |
+
|
5468 |
+
function AnimatedInterpolation(parents, range, output, extrapolate) {
|
5469 |
+
var _this;
|
5470 |
+
|
5471 |
+
_this = _AnimatedArray.call(this) || this;
|
5472 |
+
_this.calc = void 0;
|
5473 |
+
_this.payload = parents instanceof AnimatedArray && !(parents instanceof AnimatedInterpolation) ? parents.getPayload() : Array.isArray(parents) ? parents : [parents];
|
5474 |
+
_this.calc = createInterpolator(range, output, extrapolate);
|
5475 |
+
return _this;
|
5476 |
+
}
|
5477 |
+
|
5478 |
+
var _proto = AnimatedInterpolation.prototype;
|
5479 |
+
|
5480 |
+
_proto.getValue = function getValue() {
|
5481 |
+
return this.calc.apply(this, this.payload.map(function (value) {
|
5482 |
+
return value.getValue();
|
5483 |
+
}));
|
5484 |
+
};
|
5485 |
+
|
5486 |
+
_proto.updateConfig = function updateConfig(range, output, extrapolate) {
|
5487 |
+
this.calc = createInterpolator(range, output, extrapolate);
|
5488 |
+
};
|
5489 |
+
|
5490 |
+
_proto.interpolate = function interpolate(range, output, extrapolate) {
|
5491 |
+
return new AnimatedInterpolation(this, range, output, extrapolate);
|
5492 |
+
};
|
5493 |
+
|
5494 |
+
return AnimatedInterpolation;
|
5495 |
+
}(AnimatedArray);
|
5496 |
+
|
5497 |
+
var interpolate$1 = function interpolate(parents, range, output) {
|
5498 |
+
return parents && new AnimatedInterpolation(parents, range, output);
|
5499 |
+
};
|
5500 |
+
|
5501 |
+
var config = {
|
5502 |
+
default: {
|
5503 |
+
tension: 170,
|
5504 |
+
friction: 26
|
5505 |
+
},
|
5506 |
+
gentle: {
|
5507 |
+
tension: 120,
|
5508 |
+
friction: 14
|
5509 |
+
},
|
5510 |
+
wobbly: {
|
5511 |
+
tension: 180,
|
5512 |
+
friction: 12
|
5513 |
+
},
|
5514 |
+
stiff: {
|
5515 |
+
tension: 210,
|
5516 |
+
friction: 20
|
5517 |
+
},
|
5518 |
+
slow: {
|
5519 |
+
tension: 280,
|
5520 |
+
friction: 60
|
5521 |
+
},
|
5522 |
+
molasses: {
|
5523 |
+
tension: 280,
|
5524 |
+
friction: 120
|
5525 |
+
}
|
5526 |
+
};
|
5527 |
+
|
5528 |
+
/** API
|
5529 |
+
* useChain(references, timeSteps, timeFrame)
|
5530 |
+
*/
|
5531 |
+
|
5532 |
+
function useChain(refs, timeSteps, timeFrame) {
|
5533 |
+
if (timeFrame === void 0) {
|
5534 |
+
timeFrame = 1000;
|
5535 |
+
}
|
5536 |
+
|
5537 |
+
var previous = React.useRef();
|
5538 |
+
React.useEffect(function () {
|
5539 |
+
if (is.equ(refs, previous.current)) refs.forEach(function (_ref) {
|
5540 |
+
var current = _ref.current;
|
5541 |
+
return current && current.start();
|
5542 |
+
});else if (timeSteps) {
|
5543 |
+
refs.forEach(function (_ref2, index) {
|
5544 |
+
var current = _ref2.current;
|
5545 |
+
|
5546 |
+
if (current) {
|
5547 |
+
var ctrls = current.controllers;
|
5548 |
+
|
5549 |
+
if (ctrls.length) {
|
5550 |
+
var t = timeFrame * timeSteps[index];
|
5551 |
+
ctrls.forEach(function (ctrl) {
|
5552 |
+
ctrl.queue = ctrl.queue.map(function (e) {
|
5553 |
+
return _extends({}, e, {
|
5554 |
+
delay: e.delay + t
|
5555 |
+
});
|
5556 |
+
});
|
5557 |
+
ctrl.start();
|
5558 |
+
});
|
5559 |
+
}
|
5560 |
+
}
|
5561 |
+
});
|
5562 |
+
} else refs.reduce(function (q, _ref3, rI) {
|
5563 |
+
var current = _ref3.current;
|
5564 |
+
return q = q.then(function () {
|
5565 |
+
return current.start();
|
5566 |
+
});
|
5567 |
+
}, Promise.resolve());
|
5568 |
+
previous.current = refs;
|
5569 |
+
});
|
5570 |
+
}
|
5571 |
+
|
5572 |
+
/**
|
5573 |
+
* Animated works by building a directed acyclic graph of dependencies
|
5574 |
+
* transparently when you render your Animated components.
|
5575 |
+
*
|
5576 |
+
* new Animated.Value(0)
|
5577 |
+
* .interpolate() .interpolate() new Animated.Value(1)
|
5578 |
+
* opacity translateY scale
|
5579 |
+
* style transform
|
5580 |
+
* View#234 style
|
5581 |
+
* View#123
|
5582 |
+
*
|
5583 |
+
* A) Top Down phase
|
5584 |
+
* When an AnimatedValue is updated, we recursively go down through this
|
5585 |
+
* graph in order to find leaf nodes: the views that we flag as needing
|
5586 |
+
* an update.
|
5587 |
+
*
|
5588 |
+
* B) Bottom Up phase
|
5589 |
+
* When a view is flagged as needing an update, we recursively go back up
|
5590 |
+
* in order to build the new value that it needs. The reason why we need
|
5591 |
+
* this two-phases process is to deal with composite props such as
|
5592 |
+
* transform which can receive values from multiple parents.
|
5593 |
+
*/
|
5594 |
+
function addAnimatedStyles(node, styles) {
|
5595 |
+
if ('update' in node) {
|
5596 |
+
styles.add(node);
|
5597 |
+
} else {
|
5598 |
+
node.getChildren().forEach(function (child) {
|
5599 |
+
return addAnimatedStyles(child, styles);
|
5600 |
+
});
|
5601 |
+
}
|
5602 |
+
}
|
5603 |
+
|
5604 |
+
var AnimatedValue =
|
5605 |
+
/*#__PURE__*/
|
5606 |
+
function (_Animated) {
|
5607 |
+
_inheritsLoose(AnimatedValue, _Animated);
|
5608 |
+
|
5609 |
+
function AnimatedValue(_value) {
|
5610 |
+
var _this;
|
5611 |
+
|
5612 |
+
_this = _Animated.call(this) || this;
|
5613 |
+
_this.animatedStyles = new Set();
|
5614 |
+
_this.value = void 0;
|
5615 |
+
_this.startPosition = void 0;
|
5616 |
+
_this.lastPosition = void 0;
|
5617 |
+
_this.lastVelocity = void 0;
|
5618 |
+
_this.startTime = void 0;
|
5619 |
+
_this.lastTime = void 0;
|
5620 |
+
_this.done = false;
|
5621 |
+
|
5622 |
+
_this.setValue = function (value, flush) {
|
5623 |
+
if (flush === void 0) {
|
5624 |
+
flush = true;
|
5625 |
+
}
|
5626 |
+
|
5627 |
+
_this.value = value;
|
5628 |
+
if (flush) _this.flush();
|
5629 |
+
};
|
5630 |
+
|
5631 |
+
_this.value = _value;
|
5632 |
+
_this.startPosition = _value;
|
5633 |
+
_this.lastPosition = _value;
|
5634 |
+
return _this;
|
5635 |
+
}
|
5636 |
+
|
5637 |
+
var _proto = AnimatedValue.prototype;
|
5638 |
+
|
5639 |
+
_proto.flush = function flush() {
|
5640 |
+
if (this.animatedStyles.size === 0) {
|
5641 |
+
addAnimatedStyles(this, this.animatedStyles);
|
5642 |
+
}
|
5643 |
+
|
5644 |
+
this.animatedStyles.forEach(function (animatedStyle) {
|
5645 |
+
return animatedStyle.update();
|
5646 |
+
});
|
5647 |
+
};
|
5648 |
+
|
5649 |
+
_proto.clearStyles = function clearStyles() {
|
5650 |
+
this.animatedStyles.clear();
|
5651 |
+
};
|
5652 |
+
|
5653 |
+
_proto.getValue = function getValue() {
|
5654 |
+
return this.value;
|
5655 |
+
};
|
5656 |
+
|
5657 |
+
_proto.interpolate = function interpolate(range, output, extrapolate) {
|
5658 |
+
return new AnimatedInterpolation(this, range, output, extrapolate);
|
5659 |
+
};
|
5660 |
+
|
5661 |
+
return AnimatedValue;
|
5662 |
+
}(Animated);
|
5663 |
+
|
5664 |
+
var AnimatedValueArray =
|
5665 |
+
/*#__PURE__*/
|
5666 |
+
function (_AnimatedArray) {
|
5667 |
+
_inheritsLoose(AnimatedValueArray, _AnimatedArray);
|
5668 |
+
|
5669 |
+
function AnimatedValueArray(values) {
|
5670 |
+
var _this;
|
5671 |
+
|
5672 |
+
_this = _AnimatedArray.call(this) || this;
|
5673 |
+
_this.payload = values.map(function (n) {
|
5674 |
+
return new AnimatedValue(n);
|
5675 |
+
});
|
5676 |
+
return _this;
|
5677 |
+
}
|
5678 |
+
|
5679 |
+
var _proto = AnimatedValueArray.prototype;
|
5680 |
+
|
5681 |
+
_proto.setValue = function setValue(value, flush) {
|
5682 |
+
var _this2 = this;
|
5683 |
+
|
5684 |
+
if (flush === void 0) {
|
5685 |
+
flush = true;
|
5686 |
+
}
|
5687 |
+
|
5688 |
+
if (Array.isArray(value)) {
|
5689 |
+
if (value.length === this.payload.length) {
|
5690 |
+
value.forEach(function (v, i) {
|
5691 |
+
return _this2.payload[i].setValue(v, flush);
|
5692 |
+
});
|
5693 |
+
}
|
5694 |
+
} else {
|
5695 |
+
this.payload.forEach(function (p) {
|
5696 |
+
return p.setValue(value, flush);
|
5697 |
+
});
|
5698 |
+
}
|
5699 |
+
};
|
5700 |
+
|
5701 |
+
_proto.getValue = function getValue() {
|
5702 |
+
return this.payload.map(function (v) {
|
5703 |
+
return v.getValue();
|
5704 |
+
});
|
5705 |
+
};
|
5706 |
+
|
5707 |
+
_proto.interpolate = function interpolate(range, output) {
|
5708 |
+
return new AnimatedInterpolation(this, range, output);
|
5709 |
+
};
|
5710 |
+
|
5711 |
+
return AnimatedValueArray;
|
5712 |
+
}(AnimatedArray);
|
5713 |
+
|
5714 |
+
var G = 0;
|
5715 |
+
|
5716 |
+
var Controller =
|
5717 |
+
/*#__PURE__*/
|
5718 |
+
function () {
|
5719 |
+
function Controller() {
|
5720 |
+
var _this = this;
|
5721 |
+
|
5722 |
+
this.id = void 0;
|
5723 |
+
this.idle = true;
|
5724 |
+
this.hasChanged = false;
|
5725 |
+
this.guid = 0;
|
5726 |
+
this.local = 0;
|
5727 |
+
this.props = {};
|
5728 |
+
this.merged = {};
|
5729 |
+
this.animations = {};
|
5730 |
+
this.interpolations = {};
|
5731 |
+
this.values = {};
|
5732 |
+
this.configs = [];
|
5733 |
+
this.listeners = [];
|
5734 |
+
this.queue = [];
|
5735 |
+
this.localQueue = void 0;
|
5736 |
+
|
5737 |
+
this.getValues = function () {
|
5738 |
+
return _this.interpolations;
|
5739 |
+
};
|
5740 |
+
|
5741 |
+
this.id = G++;
|
5742 |
+
}
|
5743 |
+
/** update(props)
|
5744 |
+
* This function filters input props and creates an array of tasks which are executed in .start()
|
5745 |
+
* Each task is allowed to carry a delay, which means it can execute asnychroneously */
|
5746 |
+
|
5747 |
+
|
5748 |
+
var _proto = Controller.prototype;
|
5749 |
+
|
5750 |
+
_proto.update = function update$$1(args) {
|
5751 |
+
//this._id = n + this.id
|
5752 |
+
if (!args) return this; // Extract delay and the to-prop from props
|
5753 |
+
|
5754 |
+
var _ref = interpolateTo(args),
|
5755 |
+
_ref$delay = _ref.delay,
|
5756 |
+
delay = _ref$delay === void 0 ? 0 : _ref$delay,
|
5757 |
+
to = _ref.to,
|
5758 |
+
props = _objectWithoutPropertiesLoose(_ref, ["delay", "to"]);
|
5759 |
+
|
5760 |
+
if (is.arr(to) || is.fun(to)) {
|
5761 |
+
// If config is either a function or an array queue it up as is
|
5762 |
+
this.queue.push(_extends({}, props, {
|
5763 |
+
delay: delay,
|
5764 |
+
to: to
|
5765 |
+
}));
|
5766 |
+
} else if (to) {
|
5767 |
+
// Otherwise go through each key since it could be delayed individually
|
5768 |
+
var ops = {};
|
5769 |
+
Object.entries(to).forEach(function (_ref2) {
|
5770 |
+
var _to;
|
5771 |
+
|
5772 |
+
var k = _ref2[0],
|
5773 |
+
v = _ref2[1];
|
5774 |
+
|
5775 |
+
// Fetch delay and create an entry, consisting of the to-props, the delay, and basic props
|
5776 |
+
var entry = _extends({
|
5777 |
+
to: (_to = {}, _to[k] = v, _to),
|
5778 |
+
delay: callProp(delay, k)
|
5779 |
+
}, props);
|
5780 |
+
|
5781 |
+
var previous = ops[entry.delay] && ops[entry.delay].to;
|
5782 |
+
ops[entry.delay] = _extends({}, ops[entry.delay], entry, {
|
5783 |
+
to: _extends({}, previous, entry.to)
|
5784 |
+
});
|
5785 |
+
});
|
5786 |
+
this.queue = Object.values(ops);
|
5787 |
+
} // Sort queue, so that async calls go last
|
5788 |
+
|
5789 |
+
|
5790 |
+
this.queue = this.queue.sort(function (a, b) {
|
5791 |
+
return a.delay - b.delay;
|
5792 |
+
}); // Diff the reduced props immediately (they'll contain the from-prop and some config)
|
5793 |
+
|
5794 |
+
this.diff(props);
|
5795 |
+
return this;
|
5796 |
+
}
|
5797 |
+
/** start(onEnd)
|
5798 |
+
* This function either executes a queue, if present, or starts the frameloop, which animates */
|
5799 |
+
;
|
5800 |
+
|
5801 |
+
_proto.start = function start$$1(onEnd) {
|
5802 |
+
var _this2 = this;
|
5803 |
+
|
5804 |
+
// If a queue is present we must excecute it
|
5805 |
+
if (this.queue.length) {
|
5806 |
+
this.idle = false; // Updates can interrupt trailing queues, in that case we just merge values
|
5807 |
+
|
5808 |
+
if (this.localQueue) {
|
5809 |
+
this.localQueue.forEach(function (_ref3) {
|
5810 |
+
var _ref3$from = _ref3.from,
|
5811 |
+
from = _ref3$from === void 0 ? {} : _ref3$from,
|
5812 |
+
_ref3$to = _ref3.to,
|
5813 |
+
to = _ref3$to === void 0 ? {} : _ref3$to;
|
5814 |
+
if (is.obj(from)) _this2.merged = _extends({}, from, _this2.merged);
|
5815 |
+
if (is.obj(to)) _this2.merged = _extends({}, _this2.merged, to);
|
5816 |
+
});
|
5817 |
+
} // The guid helps us tracking frames, a new queue over an old one means an override
|
5818 |
+
// We discard async calls in that caseÍ
|
5819 |
+
|
5820 |
+
|
5821 |
+
var local = this.local = ++this.guid;
|
5822 |
+
var queue = this.localQueue = this.queue;
|
5823 |
+
this.queue = []; // Go through each entry and execute it
|
5824 |
+
|
5825 |
+
queue.forEach(function (_ref4, index) {
|
5826 |
+
var delay = _ref4.delay,
|
5827 |
+
props = _objectWithoutPropertiesLoose(_ref4, ["delay"]);
|
5828 |
+
|
5829 |
+
var cb = function cb(finished) {
|
5830 |
+
if (index === queue.length - 1 && local === _this2.guid && finished) {
|
5831 |
+
_this2.idle = true;
|
5832 |
+
if (_this2.props.onRest) _this2.props.onRest(_this2.merged);
|
5833 |
+
}
|
5834 |
+
|
5835 |
+
if (onEnd) onEnd();
|
5836 |
+
}; // Entries can be delayed, ansyc or immediate
|
5837 |
+
|
5838 |
+
|
5839 |
+
var async = is.arr(props.to) || is.fun(props.to);
|
5840 |
+
|
5841 |
+
if (delay) {
|
5842 |
+
setTimeout(function () {
|
5843 |
+
if (local === _this2.guid) {
|
5844 |
+
if (async) _this2.runAsync(props, cb);else _this2.diff(props).start(cb);
|
5845 |
+
}
|
5846 |
+
}, delay);
|
5847 |
+
} else if (async) _this2.runAsync(props, cb);else _this2.diff(props).start(cb);
|
5848 |
+
});
|
5849 |
+
} // Otherwise we kick of the frameloop
|
5850 |
+
else {
|
5851 |
+
if (is.fun(onEnd)) this.listeners.push(onEnd);
|
5852 |
+
if (this.props.onStart) this.props.onStart();
|
5853 |
+
|
5854 |
+
start(this);
|
5855 |
+
}
|
5856 |
+
|
5857 |
+
return this;
|
5858 |
+
};
|
5859 |
+
|
5860 |
+
_proto.stop = function stop$$1(finished) {
|
5861 |
+
this.listeners.forEach(function (onEnd) {
|
5862 |
+
return onEnd(finished);
|
5863 |
+
});
|
5864 |
+
this.listeners = [];
|
5865 |
+
return this;
|
5866 |
+
}
|
5867 |
+
/** Pause sets onEnd listeners free, but also removes the controller from the frameloop */
|
5868 |
+
;
|
5869 |
+
|
5870 |
+
_proto.pause = function pause(finished) {
|
5871 |
+
this.stop(true);
|
5872 |
+
if (finished) stop(this);
|
5873 |
+
return this;
|
5874 |
+
};
|
5875 |
+
|
5876 |
+
_proto.runAsync = function runAsync(_ref5, onEnd) {
|
5877 |
+
var _this3 = this;
|
5878 |
+
|
5879 |
+
var delay = _ref5.delay,
|
5880 |
+
props = _objectWithoutPropertiesLoose(_ref5, ["delay"]);
|
5881 |
+
|
5882 |
+
var local = this.local; // If "to" is either a function or an array it will be processed async, therefor "to" should be empty right now
|
5883 |
+
// If the view relies on certain values "from" has to be present
|
5884 |
+
|
5885 |
+
var queue = Promise.resolve(undefined);
|
5886 |
+
|
5887 |
+
if (is.arr(props.to)) {
|
5888 |
+
var _loop = function _loop(i) {
|
5889 |
+
var index = i;
|
5890 |
+
|
5891 |
+
var fresh = _extends({}, props, interpolateTo(props.to[index]));
|
5892 |
+
|
5893 |
+
if (is.arr(fresh.config)) fresh.config = fresh.config[index];
|
5894 |
+
queue = queue.then(function () {
|
5895 |
+
//this.stop()
|
5896 |
+
if (local === _this3.guid) return new Promise(function (r) {
|
5897 |
+
return _this3.diff(fresh).start(r);
|
5898 |
+
});
|
5899 |
+
});
|
5900 |
+
};
|
5901 |
+
|
5902 |
+
for (var i = 0; i < props.to.length; i++) {
|
5903 |
+
_loop(i);
|
5904 |
+
}
|
5905 |
+
} else if (is.fun(props.to)) {
|
5906 |
+
var index = 0;
|
5907 |
+
var last;
|
5908 |
+
queue = queue.then(function () {
|
5909 |
+
return props.to( // next(props)
|
5910 |
+
function (p) {
|
5911 |
+
var fresh = _extends({}, props, interpolateTo(p));
|
5912 |
+
|
5913 |
+
if (is.arr(fresh.config)) fresh.config = fresh.config[index];
|
5914 |
+
index++; //this.stop()
|
5915 |
+
|
5916 |
+
if (local === _this3.guid) return last = new Promise(function (r) {
|
5917 |
+
return _this3.diff(fresh).start(r);
|
5918 |
+
});
|
5919 |
+
return;
|
5920 |
+
}, // cancel()
|
5921 |
+
function (finished) {
|
5922 |
+
if (finished === void 0) {
|
5923 |
+
finished = true;
|
5924 |
+
}
|
5925 |
+
|
5926 |
+
return _this3.stop(finished);
|
5927 |
+
}).then(function () {
|
5928 |
+
return last;
|
5929 |
+
});
|
5930 |
+
});
|
5931 |
+
}
|
5932 |
+
|
5933 |
+
queue.then(onEnd);
|
5934 |
+
};
|
5935 |
+
|
5936 |
+
_proto.diff = function diff(props) {
|
5937 |
+
var _this4 = this;
|
5938 |
+
|
5939 |
+
this.props = _extends({}, this.props, props);
|
5940 |
+
var _this$props = this.props,
|
5941 |
+
_this$props$from = _this$props.from,
|
5942 |
+
from = _this$props$from === void 0 ? {} : _this$props$from,
|
5943 |
+
_this$props$to = _this$props.to,
|
5944 |
+
to = _this$props$to === void 0 ? {} : _this$props$to,
|
5945 |
+
_this$props$config = _this$props.config,
|
5946 |
+
config = _this$props$config === void 0 ? {} : _this$props$config,
|
5947 |
+
reverse = _this$props.reverse,
|
5948 |
+
attach = _this$props.attach,
|
5949 |
+
reset = _this$props.reset,
|
5950 |
+
immediate = _this$props.immediate; // Reverse values when requested
|
5951 |
+
|
5952 |
+
if (reverse) {
|
5953 |
+
var _ref6 = [to, from];
|
5954 |
+
from = _ref6[0];
|
5955 |
+
to = _ref6[1];
|
5956 |
+
} // This will collect all props that were ever set, reset merged props when necessary
|
5957 |
+
|
5958 |
+
|
5959 |
+
this.merged = _extends({}, from, this.merged, to);
|
5960 |
+
this.hasChanged = false; // Attachment handling, trailed springs can "attach" themselves to a previous spring
|
5961 |
+
|
5962 |
+
var target = attach && attach(this); // Reduces input { name: value } pairs into animated values
|
5963 |
+
|
5964 |
+
this.animations = Object.entries(this.merged).reduce(function (acc, _ref7) {
|
5965 |
+
var name = _ref7[0],
|
5966 |
+
value = _ref7[1];
|
5967 |
+
// Issue cached entries, except on reset
|
5968 |
+
var entry = acc[name] || {}; // Figure out what the value is supposed to be
|
5969 |
+
|
5970 |
+
var isNumber = is.num(value);
|
5971 |
+
var isString = is.str(value) && !value.startsWith('#') && !/\d/.test(value) && !colorNames[value];
|
5972 |
+
var isArray = is.arr(value);
|
5973 |
+
var isInterpolation = !isNumber && !isArray && !isString;
|
5974 |
+
var fromValue = !is.und(from[name]) ? from[name] : value;
|
5975 |
+
var toValue = isNumber || isArray ? value : isString ? value : 1;
|
5976 |
+
var toConfig = callProp(config, name);
|
5977 |
+
if (target) toValue = target.animations[name].parent;
|
5978 |
+
var parent = entry.parent,
|
5979 |
+
interpolation$$1 = entry.interpolation,
|
5980 |
+
toValues = toArray(target ? toValue.getPayload() : toValue),
|
5981 |
+
animatedValues;
|
5982 |
+
var newValue = value;
|
5983 |
+
if (isInterpolation) newValue = interpolation({
|
5984 |
+
range: [0, 1],
|
5985 |
+
output: [value, value]
|
5986 |
+
})(1);
|
5987 |
+
var currentValue = interpolation$$1 && interpolation$$1.getValue(); // Change detection flags
|
5988 |
+
|
5989 |
+
var isFirst = is.und(parent);
|
5990 |
+
var isActive = !isFirst && entry.animatedValues.some(function (v) {
|
5991 |
+
return !v.done;
|
5992 |
+
});
|
5993 |
+
var currentValueDiffersFromGoal = !is.equ(newValue, currentValue);
|
5994 |
+
var hasNewGoal = !is.equ(newValue, entry.previous);
|
5995 |
+
var hasNewConfig = !is.equ(toConfig, entry.config); // Change animation props when props indicate a new goal (new value differs from previous one)
|
5996 |
+
// and current values differ from it. Config changes trigger a new update as well (though probably shouldn't?)
|
5997 |
+
|
5998 |
+
if (reset || hasNewGoal && currentValueDiffersFromGoal || hasNewConfig) {
|
5999 |
+
var _extends2;
|
6000 |
+
|
6001 |
+
// Convert regular values into animated values, ALWAYS re-use if possible
|
6002 |
+
if (isNumber || isString) parent = interpolation$$1 = entry.parent || new AnimatedValue(fromValue);else if (isArray) parent = interpolation$$1 = entry.parent || new AnimatedValueArray(fromValue);else if (isInterpolation) {
|
6003 |
+
var prev = entry.interpolation && entry.interpolation.calc(entry.parent.value);
|
6004 |
+
prev = prev !== void 0 && !reset ? prev : fromValue;
|
6005 |
+
|
6006 |
+
if (entry.parent) {
|
6007 |
+
parent = entry.parent;
|
6008 |
+
parent.setValue(0, false);
|
6009 |
+
} else parent = new AnimatedValue(0);
|
6010 |
+
|
6011 |
+
var range = {
|
6012 |
+
output: [prev, value]
|
6013 |
+
};
|
6014 |
+
|
6015 |
+
if (entry.interpolation) {
|
6016 |
+
interpolation$$1 = entry.interpolation;
|
6017 |
+
entry.interpolation.updateConfig(range);
|
6018 |
+
} else interpolation$$1 = parent.interpolate(range);
|
6019 |
+
}
|
6020 |
+
toValues = toArray(target ? toValue.getPayload() : toValue);
|
6021 |
+
animatedValues = toArray(parent.getPayload());
|
6022 |
+
if (reset && !isInterpolation) parent.setValue(fromValue, false);
|
6023 |
+
_this4.hasChanged = true; // Reset animated values
|
6024 |
+
|
6025 |
+
animatedValues.forEach(function (value) {
|
6026 |
+
value.startPosition = value.value;
|
6027 |
+
value.lastPosition = value.value;
|
6028 |
+
value.lastVelocity = isActive ? value.lastVelocity : undefined;
|
6029 |
+
value.lastTime = isActive ? value.lastTime : undefined;
|
6030 |
+
value.startTime = now();
|
6031 |
+
value.done = false;
|
6032 |
+
value.animatedStyles.clear();
|
6033 |
+
}); // Set immediate values
|
6034 |
+
|
6035 |
+
if (callProp(immediate, name)) {
|
6036 |
+
parent.setValue(isInterpolation ? toValue : value, false);
|
6037 |
+
}
|
6038 |
+
|
6039 |
+
return _extends({}, acc, (_extends2 = {}, _extends2[name] = _extends({}, entry, {
|
6040 |
+
name: name,
|
6041 |
+
parent: parent,
|
6042 |
+
interpolation: interpolation$$1,
|
6043 |
+
animatedValues: animatedValues,
|
6044 |
+
toValues: toValues,
|
6045 |
+
previous: newValue,
|
6046 |
+
config: toConfig,
|
6047 |
+
fromValues: toArray(parent.getValue()),
|
6048 |
+
immediate: callProp(immediate, name),
|
6049 |
+
initialVelocity: withDefault(toConfig.velocity, 0),
|
6050 |
+
clamp: withDefault(toConfig.clamp, false),
|
6051 |
+
precision: withDefault(toConfig.precision, 0.01),
|
6052 |
+
tension: withDefault(toConfig.tension, 170),
|
6053 |
+
friction: withDefault(toConfig.friction, 26),
|
6054 |
+
mass: withDefault(toConfig.mass, 1),
|
6055 |
+
duration: toConfig.duration,
|
6056 |
+
easing: withDefault(toConfig.easing, function (t) {
|
6057 |
+
return t;
|
6058 |
+
}),
|
6059 |
+
decay: toConfig.decay
|
6060 |
+
}), _extends2));
|
6061 |
+
} else {
|
6062 |
+
if (!currentValueDiffersFromGoal) {
|
6063 |
+
var _extends3;
|
6064 |
+
|
6065 |
+
// So ... the current target value (newValue) appears to be different from the previous value,
|
6066 |
+
// which normally constitutes an update, but the actual value (currentValue) matches the target!
|
6067 |
+
// In order to resolve this without causing an animation update we silently flag the animation as done,
|
6068 |
+
// which it technically is. Interpolations also needs a config update with their target set to 1.
|
6069 |
+
if (isInterpolation) {
|
6070 |
+
parent.setValue(1, false);
|
6071 |
+
interpolation$$1.updateConfig({
|
6072 |
+
output: [newValue, newValue]
|
6073 |
+
});
|
6074 |
+
}
|
6075 |
+
|
6076 |
+
parent.done = true;
|
6077 |
+
_this4.hasChanged = true;
|
6078 |
+
return _extends({}, acc, (_extends3 = {}, _extends3[name] = _extends({}, acc[name], {
|
6079 |
+
previous: newValue
|
6080 |
+
}), _extends3));
|
6081 |
+
}
|
6082 |
+
|
6083 |
+
return acc;
|
6084 |
+
}
|
6085 |
+
}, this.animations);
|
6086 |
+
|
6087 |
+
if (this.hasChanged) {
|
6088 |
+
// Make animations available to frameloop
|
6089 |
+
this.configs = Object.values(this.animations);
|
6090 |
+
this.values = {};
|
6091 |
+
this.interpolations = {};
|
6092 |
+
|
6093 |
+
for (var key in this.animations) {
|
6094 |
+
this.interpolations[key] = this.animations[key].interpolation;
|
6095 |
+
this.values[key] = this.animations[key].interpolation.getValue();
|
6096 |
+
}
|
6097 |
+
}
|
6098 |
+
|
6099 |
+
return this;
|
6100 |
+
};
|
6101 |
+
|
6102 |
+
_proto.destroy = function destroy() {
|
6103 |
+
this.stop();
|
6104 |
+
this.props = {};
|
6105 |
+
this.merged = {};
|
6106 |
+
this.animations = {};
|
6107 |
+
this.interpolations = {};
|
6108 |
+
this.values = {};
|
6109 |
+
this.configs = [];
|
6110 |
+
this.local = 0;
|
6111 |
+
};
|
6112 |
+
|
6113 |
+
return Controller;
|
6114 |
+
}();
|
6115 |
+
|
6116 |
+
/** API
|
6117 |
+
* const props = useSprings(number, [{ ... }, { ... }, ...])
|
6118 |
+
* const [props, set] = useSprings(number, (i, controller) => ({ ... }))
|
6119 |
+
*/
|
6120 |
+
|
6121 |
+
var useSprings = function useSprings(length, props) {
|
6122 |
+
var mounted = React.useRef(false);
|
6123 |
+
var ctrl = React.useRef();
|
6124 |
+
var isFn = is.fun(props); // The controller maintains the animation values, starts and stops animations
|
6125 |
+
|
6126 |
+
var _useMemo = React.useMemo(function () {
|
6127 |
+
// Remove old controllers
|
6128 |
+
if (ctrl.current) {
|
6129 |
+
ctrl.current.map(function (c) {
|
6130 |
+
return c.destroy();
|
6131 |
+
});
|
6132 |
+
ctrl.current = undefined;
|
6133 |
+
}
|
6134 |
+
|
6135 |
+
var ref;
|
6136 |
+
return [new Array(length).fill().map(function (_, i) {
|
6137 |
+
var ctrl = new Controller();
|
6138 |
+
var newProps = isFn ? callProp(props, i, ctrl) : props[i];
|
6139 |
+
if (i === 0) ref = newProps.ref;
|
6140 |
+
ctrl.update(newProps);
|
6141 |
+
if (!ref) ctrl.start();
|
6142 |
+
return ctrl;
|
6143 |
+
}), ref];
|
6144 |
+
}, [length]),
|
6145 |
+
controllers = _useMemo[0],
|
6146 |
+
ref = _useMemo[1];
|
6147 |
+
|
6148 |
+
ctrl.current = controllers; // The hooks reference api gets defined here ...
|
6149 |
+
|
6150 |
+
var api = React.useImperativeHandle(ref, function () {
|
6151 |
+
return {
|
6152 |
+
start: function start() {
|
6153 |
+
return Promise.all(ctrl.current.map(function (c) {
|
6154 |
+
return new Promise(function (r) {
|
6155 |
+
return c.start(r);
|
6156 |
+
});
|
6157 |
+
}));
|
6158 |
+
},
|
6159 |
+
stop: function stop(finished) {
|
6160 |
+
return ctrl.current.forEach(function (c) {
|
6161 |
+
return c.stop(finished);
|
6162 |
+
});
|
6163 |
+
},
|
6164 |
+
|
6165 |
+
get controllers() {
|
6166 |
+
return ctrl.current;
|
6167 |
+
}
|
6168 |
+
|
6169 |
+
};
|
6170 |
+
}); // This function updates the controllers
|
6171 |
+
|
6172 |
+
var updateCtrl = React.useMemo(function () {
|
6173 |
+
return function (updateProps) {
|
6174 |
+
return ctrl.current.map(function (c, i) {
|
6175 |
+
c.update(isFn ? callProp(updateProps, i, c) : updateProps[i]);
|
6176 |
+
if (!ref) c.start();
|
6177 |
+
});
|
6178 |
+
};
|
6179 |
+
}, [length]); // Update controller if props aren't functional
|
6180 |
+
|
6181 |
+
React.useEffect(function () {
|
6182 |
+
if (mounted.current) {
|
6183 |
+
if (!isFn) updateCtrl(props);
|
6184 |
+
} else if (!ref) ctrl.current.forEach(function (c) {
|
6185 |
+
return c.start();
|
6186 |
+
});
|
6187 |
+
}); // Update mounted flag and destroy controller on unmount
|
6188 |
+
|
6189 |
+
React.useEffect(function () {
|
6190 |
+
return mounted.current = true, function () {
|
6191 |
+
return ctrl.current.forEach(function (c) {
|
6192 |
+
return c.destroy();
|
6193 |
+
});
|
6194 |
+
};
|
6195 |
+
}, []); // Return animated props, or, anim-props + the update-setter above
|
6196 |
+
|
6197 |
+
var propValues = ctrl.current.map(function (c) {
|
6198 |
+
return c.getValues();
|
6199 |
+
});
|
6200 |
+
return isFn ? [propValues, updateCtrl, function (finished) {
|
6201 |
+
return ctrl.current.forEach(function (c) {
|
6202 |
+
return c.pause(finished);
|
6203 |
+
});
|
6204 |
+
}] : propValues;
|
6205 |
+
};
|
6206 |
+
|
6207 |
+
/** API
|
6208 |
+
* const props = useSpring({ ... })
|
6209 |
+
* const [props, set] = useSpring(() => ({ ... }))
|
6210 |
+
*/
|
6211 |
+
|
6212 |
+
var useSpring = function useSpring(props) {
|
6213 |
+
var isFn = is.fun(props);
|
6214 |
+
|
6215 |
+
var _useSprings = useSprings(1, isFn ? props : [props]),
|
6216 |
+
result = _useSprings[0],
|
6217 |
+
set = _useSprings[1],
|
6218 |
+
pause = _useSprings[2];
|
6219 |
+
|
6220 |
+
return isFn ? [result[0], set, pause] : result;
|
6221 |
+
};
|
6222 |
+
|
6223 |
+
/** API
|
6224 |
+
* const trails = useTrail(number, { ... })
|
6225 |
+
* const [trails, set] = useTrail(number, () => ({ ... }))
|
6226 |
+
*/
|
6227 |
+
|
6228 |
+
var useTrail = function useTrail(length, props) {
|
6229 |
+
var mounted = React.useRef(false);
|
6230 |
+
var isFn = is.fun(props);
|
6231 |
+
var updateProps = callProp(props);
|
6232 |
+
var instances = React.useRef();
|
6233 |
+
|
6234 |
+
var _useSprings = useSprings(length, function (i, ctrl) {
|
6235 |
+
if (i === 0) instances.current = [];
|
6236 |
+
instances.current.push(ctrl);
|
6237 |
+
return _extends({}, updateProps, {
|
6238 |
+
config: callProp(updateProps.config, i),
|
6239 |
+
attach: i > 0 && function () {
|
6240 |
+
return instances.current[i - 1];
|
6241 |
+
}
|
6242 |
+
});
|
6243 |
+
}),
|
6244 |
+
result = _useSprings[0],
|
6245 |
+
set = _useSprings[1],
|
6246 |
+
pause = _useSprings[2]; // Set up function to update controller
|
6247 |
+
|
6248 |
+
|
6249 |
+
var updateCtrl = React.useMemo(function () {
|
6250 |
+
return function (props) {
|
6251 |
+
return set(function (i, ctrl) {
|
6252 |
+
var last = props.reverse ? i === 0 : length - 1 === i;
|
6253 |
+
var attachIdx = props.reverse ? i + 1 : i - 1;
|
6254 |
+
var attachController = instances.current[attachIdx];
|
6255 |
+
return _extends({}, props, {
|
6256 |
+
config: callProp(props.config || updateProps.config, i),
|
6257 |
+
attach: attachController && function () {
|
6258 |
+
return attachController;
|
6259 |
+
}
|
6260 |
+
});
|
6261 |
+
});
|
6262 |
+
};
|
6263 |
+
}, [length, updateProps.reverse]); // Update controller if props aren't functional
|
6264 |
+
|
6265 |
+
React.useEffect(function () {
|
6266 |
+
return void (mounted.current && !isFn && updateCtrl(props));
|
6267 |
+
}); // Update mounted flag and destroy controller on unmount
|
6268 |
+
|
6269 |
+
React.useEffect(function () {
|
6270 |
+
return void (mounted.current = true);
|
6271 |
+
}, []);
|
6272 |
+
return isFn ? [result, updateCtrl, pause] : result;
|
6273 |
+
};
|
6274 |
+
|
6275 |
+
/** API
|
6276 |
+
* const transitions = useTransition(items, itemKeys, { ... })
|
6277 |
+
* const [transitions, update] = useTransition(items, itemKeys, () => ({ ... }))
|
6278 |
+
*/
|
6279 |
+
|
6280 |
+
var guid = 0;
|
6281 |
+
var ENTER = 'enter';
|
6282 |
+
var LEAVE = 'leave';
|
6283 |
+
var UPDATE = 'update';
|
6284 |
+
|
6285 |
+
var mapKeys = function mapKeys(items, keys) {
|
6286 |
+
return (typeof keys === 'function' ? items.map(keys) : toArray(keys)).map(String);
|
6287 |
+
};
|
6288 |
+
|
6289 |
+
var get = function get(props) {
|
6290 |
+
var items = props.items,
|
6291 |
+
_props$keys = props.keys,
|
6292 |
+
keys = _props$keys === void 0 ? function (item) {
|
6293 |
+
return item;
|
6294 |
+
} : _props$keys,
|
6295 |
+
rest = _objectWithoutPropertiesLoose(props, ["items", "keys"]);
|
6296 |
+
|
6297 |
+
items = toArray(items !== void 0 ? items : null);
|
6298 |
+
return _extends({
|
6299 |
+
items: items,
|
6300 |
+
keys: mapKeys(items, keys)
|
6301 |
+
}, rest);
|
6302 |
+
};
|
6303 |
+
|
6304 |
+
function useTransition(input, keyTransform, config) {
|
6305 |
+
var props = _extends({
|
6306 |
+
items: input,
|
6307 |
+
keys: keyTransform || function (i) {
|
6308 |
+
return i;
|
6309 |
+
}
|
6310 |
+
}, config);
|
6311 |
+
|
6312 |
+
var _get = get(props),
|
6313 |
+
_get$lazy = _get.lazy,
|
6314 |
+
lazy = _get$lazy === void 0 ? false : _get$lazy,
|
6315 |
+
_get$unique = _get.unique,
|
6316 |
+
_get$reset = _get.reset,
|
6317 |
+
reset = _get$reset === void 0 ? false : _get$reset,
|
6318 |
+
enter = _get.enter,
|
6319 |
+
leave = _get.leave,
|
6320 |
+
update = _get.update,
|
6321 |
+
onDestroyed = _get.onDestroyed,
|
6322 |
+
keys = _get.keys,
|
6323 |
+
items = _get.items,
|
6324 |
+
onFrame = _get.onFrame,
|
6325 |
+
_onRest = _get.onRest,
|
6326 |
+
onStart = _get.onStart,
|
6327 |
+
ref = _get.ref,
|
6328 |
+
extra = _objectWithoutPropertiesLoose(_get, ["lazy", "unique", "reset", "enter", "leave", "update", "onDestroyed", "keys", "items", "onFrame", "onRest", "onStart", "ref"]);
|
6329 |
+
|
6330 |
+
var forceUpdate = useForceUpdate();
|
6331 |
+
var mounted = React.useRef(false);
|
6332 |
+
var state = React.useRef({
|
6333 |
+
mounted: false,
|
6334 |
+
first: true,
|
6335 |
+
deleted: [],
|
6336 |
+
current: {},
|
6337 |
+
transitions: [],
|
6338 |
+
prevProps: {},
|
6339 |
+
paused: !!props.ref,
|
6340 |
+
instances: !mounted.current && new Map(),
|
6341 |
+
forceUpdate: forceUpdate
|
6342 |
+
});
|
6343 |
+
React.useImperativeHandle(props.ref, function () {
|
6344 |
+
return {
|
6345 |
+
start: function start() {
|
6346 |
+
return Promise.all(Array.from(state.current.instances).map(function (_ref) {
|
6347 |
+
var c = _ref[1];
|
6348 |
+
return new Promise(function (r) {
|
6349 |
+
return c.start(r);
|
6350 |
+
});
|
6351 |
+
}));
|
6352 |
+
},
|
6353 |
+
stop: function stop(finished) {
|
6354 |
+
return Array.from(state.current.instances).forEach(function (_ref2) {
|
6355 |
+
var c = _ref2[1];
|
6356 |
+
return c.stop(finished);
|
6357 |
+
});
|
6358 |
+
},
|
6359 |
+
|
6360 |
+
get controllers() {
|
6361 |
+
return Array.from(state.current.instances).map(function (_ref3) {
|
6362 |
+
var c = _ref3[1];
|
6363 |
+
return c;
|
6364 |
+
});
|
6365 |
+
}
|
6366 |
+
|
6367 |
+
};
|
6368 |
+
}); // Update state
|
6369 |
+
|
6370 |
+
state.current = diffItems(state.current, props);
|
6371 |
+
|
6372 |
+
if (state.current.changed) {
|
6373 |
+
// Update state
|
6374 |
+
state.current.transitions.forEach(function (transition) {
|
6375 |
+
var slot = transition.slot,
|
6376 |
+
from = transition.from,
|
6377 |
+
to = transition.to,
|
6378 |
+
config = transition.config,
|
6379 |
+
trail = transition.trail,
|
6380 |
+
key = transition.key,
|
6381 |
+
item = transition.item;
|
6382 |
+
if (!state.current.instances.has(key)) state.current.instances.set(key, new Controller()); // update the map object
|
6383 |
+
|
6384 |
+
var ctrl = state.current.instances.get(key);
|
6385 |
+
|
6386 |
+
var newProps = _extends({}, extra, {
|
6387 |
+
to: to,
|
6388 |
+
from: from,
|
6389 |
+
config: config,
|
6390 |
+
ref: ref,
|
6391 |
+
onRest: function onRest(values) {
|
6392 |
+
if (state.current.mounted) {
|
6393 |
+
if (transition.destroyed) {
|
6394 |
+
// If no ref is given delete destroyed items immediately
|
6395 |
+
if (!ref && !lazy) cleanUp(state, key);
|
6396 |
+
if (onDestroyed) onDestroyed(item);
|
6397 |
+
} // A transition comes to rest once all its springs conclude
|
6398 |
+
|
6399 |
+
|
6400 |
+
var curInstances = Array.from(state.current.instances);
|
6401 |
+
var active = curInstances.some(function (_ref4) {
|
6402 |
+
var c = _ref4[1];
|
6403 |
+
return !c.idle;
|
6404 |
+
});
|
6405 |
+
if (!active && (ref || lazy) && state.current.deleted.length > 0) cleanUp(state);
|
6406 |
+
if (_onRest) _onRest(item, slot, values);
|
6407 |
+
}
|
6408 |
+
},
|
6409 |
+
onStart: onStart && function () {
|
6410 |
+
return onStart(item, slot);
|
6411 |
+
},
|
6412 |
+
onFrame: onFrame && function (values) {
|
6413 |
+
return onFrame(item, slot, values);
|
6414 |
+
},
|
6415 |
+
delay: trail,
|
6416 |
+
reset: reset && slot === ENTER // Update controller
|
6417 |
+
|
6418 |
+
});
|
6419 |
+
|
6420 |
+
ctrl.update(newProps);
|
6421 |
+
if (!state.current.paused) ctrl.start();
|
6422 |
+
});
|
6423 |
+
}
|
6424 |
+
|
6425 |
+
React.useEffect(function () {
|
6426 |
+
state.current.mounted = mounted.current = true;
|
6427 |
+
return function () {
|
6428 |
+
state.current.mounted = mounted.current = false;
|
6429 |
+
Array.from(state.current.instances).map(function (_ref5) {
|
6430 |
+
var c = _ref5[1];
|
6431 |
+
return c.destroy();
|
6432 |
+
});
|
6433 |
+
state.current.instances.clear();
|
6434 |
+
};
|
6435 |
+
}, []);
|
6436 |
+
return state.current.transitions.map(function (_ref6) {
|
6437 |
+
var item = _ref6.item,
|
6438 |
+
slot = _ref6.slot,
|
6439 |
+
key = _ref6.key;
|
6440 |
+
return {
|
6441 |
+
item: item,
|
6442 |
+
key: key,
|
6443 |
+
state: slot,
|
6444 |
+
props: state.current.instances.get(key).getValues()
|
6445 |
+
};
|
6446 |
+
});
|
6447 |
+
}
|
6448 |
+
|
6449 |
+
function cleanUp(state, filterKey) {
|
6450 |
+
var deleted = state.current.deleted;
|
6451 |
+
|
6452 |
+
var _loop = function _loop() {
|
6453 |
+
if (_isArray) {
|
6454 |
+
if (_i >= _iterator.length) return "break";
|
6455 |
+
_ref8 = _iterator[_i++];
|
6456 |
+
} else {
|
6457 |
+
_i = _iterator.next();
|
6458 |
+
if (_i.done) return "break";
|
6459 |
+
_ref8 = _i.value;
|
6460 |
+
}
|
6461 |
+
|
6462 |
+
var _ref7 = _ref8;
|
6463 |
+
var key = _ref7.key;
|
6464 |
+
|
6465 |
+
var filter = function filter(t) {
|
6466 |
+
return t.key !== key;
|
6467 |
+
};
|
6468 |
+
|
6469 |
+
if (is.und(filterKey) || filterKey === key) {
|
6470 |
+
state.current.instances.delete(key);
|
6471 |
+
state.current.transitions = state.current.transitions.filter(filter);
|
6472 |
+
state.current.deleted = state.current.deleted.filter(filter);
|
6473 |
+
}
|
6474 |
+
};
|
6475 |
+
|
6476 |
+
for (var _iterator = deleted, _isArray = Array.isArray(_iterator), _i = 0, _iterator = _isArray ? _iterator : _iterator[Symbol.iterator]();;) {
|
6477 |
+
var _ref8;
|
6478 |
+
|
6479 |
+
var _ret = _loop();
|
6480 |
+
|
6481 |
+
if (_ret === "break") break;
|
6482 |
+
}
|
6483 |
+
|
6484 |
+
state.current.forceUpdate();
|
6485 |
+
}
|
6486 |
+
|
6487 |
+
function diffItems(_ref9, props) {
|
6488 |
+
var first = _ref9.first,
|
6489 |
+
prevProps = _ref9.prevProps,
|
6490 |
+
state = _objectWithoutPropertiesLoose(_ref9, ["first", "prevProps"]);
|
6491 |
+
|
6492 |
+
var _get2 = get(props),
|
6493 |
+
items = _get2.items,
|
6494 |
+
keys = _get2.keys,
|
6495 |
+
initial = _get2.initial,
|
6496 |
+
from = _get2.from,
|
6497 |
+
enter = _get2.enter,
|
6498 |
+
leave = _get2.leave,
|
6499 |
+
update = _get2.update,
|
6500 |
+
_get2$trail = _get2.trail,
|
6501 |
+
trail = _get2$trail === void 0 ? 0 : _get2$trail,
|
6502 |
+
unique = _get2.unique,
|
6503 |
+
config = _get2.config,
|
6504 |
+
_get2$order = _get2.order,
|
6505 |
+
order = _get2$order === void 0 ? [ENTER, LEAVE, UPDATE] : _get2$order;
|
6506 |
+
|
6507 |
+
var _get3 = get(prevProps),
|
6508 |
+
_keys = _get3.keys,
|
6509 |
+
_items = _get3.items;
|
6510 |
+
|
6511 |
+
var current = _extends({}, state.current);
|
6512 |
+
|
6513 |
+
var deleted = [].concat(state.deleted); // Compare next keys with current keys
|
6514 |
+
|
6515 |
+
var currentKeys = Object.keys(current);
|
6516 |
+
var currentSet = new Set(currentKeys);
|
6517 |
+
var nextSet = new Set(keys);
|
6518 |
+
var added = keys.filter(function (item) {
|
6519 |
+
return !currentSet.has(item);
|
6520 |
+
});
|
6521 |
+
var removed = state.transitions.filter(function (item) {
|
6522 |
+
return !item.destroyed && !nextSet.has(item.originalKey);
|
6523 |
+
}).map(function (i) {
|
6524 |
+
return i.originalKey;
|
6525 |
+
});
|
6526 |
+
var updated = keys.filter(function (item) {
|
6527 |
+
return currentSet.has(item);
|
6528 |
+
});
|
6529 |
+
var delay = -trail;
|
6530 |
+
|
6531 |
+
while (order.length) {
|
6532 |
+
var changeType = order.shift();
|
6533 |
+
|
6534 |
+
switch (changeType) {
|
6535 |
+
case ENTER:
|
6536 |
+
{
|
6537 |
+
added.forEach(function (key, index) {
|
6538 |
+
// In unique mode, remove fading out transitions if their key comes in again
|
6539 |
+
if (unique && deleted.find(function (d) {
|
6540 |
+
return d.originalKey === key;
|
6541 |
+
})) deleted = deleted.filter(function (t) {
|
6542 |
+
return t.originalKey !== key;
|
6543 |
+
});
|
6544 |
+
var keyIndex = keys.indexOf(key);
|
6545 |
+
var item = items[keyIndex];
|
6546 |
+
var slot = first && initial !== void 0 ? 'initial' : ENTER;
|
6547 |
+
current[key] = {
|
6548 |
+
slot: slot,
|
6549 |
+
originalKey: key,
|
6550 |
+
key: unique ? String(key) : guid++,
|
6551 |
+
item: item,
|
6552 |
+
trail: delay = delay + trail,
|
6553 |
+
config: callProp(config, item, slot),
|
6554 |
+
from: callProp(first ? initial !== void 0 ? initial || {} : from : from, item),
|
6555 |
+
to: callProp(enter, item)
|
6556 |
+
};
|
6557 |
+
});
|
6558 |
+
break;
|
6559 |
+
}
|
6560 |
+
|
6561 |
+
case LEAVE:
|
6562 |
+
{
|
6563 |
+
removed.forEach(function (key) {
|
6564 |
+
var keyIndex = _keys.indexOf(key);
|
6565 |
+
|
6566 |
+
var item = _items[keyIndex];
|
6567 |
+
var slot = LEAVE;
|
6568 |
+
deleted.unshift(_extends({}, current[key], {
|
6569 |
+
slot: slot,
|
6570 |
+
destroyed: true,
|
6571 |
+
left: _keys[Math.max(0, keyIndex - 1)],
|
6572 |
+
right: _keys[Math.min(_keys.length, keyIndex + 1)],
|
6573 |
+
trail: delay = delay + trail,
|
6574 |
+
config: callProp(config, item, slot),
|
6575 |
+
to: callProp(leave, item)
|
6576 |
+
}));
|
6577 |
+
delete current[key];
|
6578 |
+
});
|
6579 |
+
break;
|
6580 |
+
}
|
6581 |
+
|
6582 |
+
case UPDATE:
|
6583 |
+
{
|
6584 |
+
updated.forEach(function (key) {
|
6585 |
+
var keyIndex = keys.indexOf(key);
|
6586 |
+
var item = items[keyIndex];
|
6587 |
+
var slot = UPDATE;
|
6588 |
+
current[key] = _extends({}, current[key], {
|
6589 |
+
item: item,
|
6590 |
+
slot: slot,
|
6591 |
+
trail: delay = delay + trail,
|
6592 |
+
config: callProp(config, item, slot),
|
6593 |
+
to: callProp(update, item)
|
6594 |
+
});
|
6595 |
+
});
|
6596 |
+
break;
|
6597 |
+
}
|
6598 |
+
}
|
6599 |
+
}
|
6600 |
+
|
6601 |
+
var out = keys.map(function (key) {
|
6602 |
+
return current[key];
|
6603 |
+
}); // This tries to restore order for deleted items by finding their last known siblings
|
6604 |
+
// only using the left sibling to keep order placement consistent for all deleted items
|
6605 |
+
|
6606 |
+
deleted.forEach(function (_ref10) {
|
6607 |
+
var left = _ref10.left,
|
6608 |
+
right = _ref10.right,
|
6609 |
+
item = _objectWithoutPropertiesLoose(_ref10, ["left", "right"]);
|
6610 |
+
|
6611 |
+
var pos; // Was it the element on the left, if yes, move there ...
|
6612 |
+
|
6613 |
+
if ((pos = out.findIndex(function (t) {
|
6614 |
+
return t.originalKey === left;
|
6615 |
+
})) !== -1) pos += 1; // And if nothing else helps, move it to the start ¯\_(ツ)_/¯
|
6616 |
+
|
6617 |
+
pos = Math.max(0, pos);
|
6618 |
+
out = [].concat(out.slice(0, pos), [item], out.slice(pos));
|
6619 |
+
});
|
6620 |
+
return _extends({}, state, {
|
6621 |
+
changed: added.length || removed.length || updated.length,
|
6622 |
+
first: first && added.length === 0,
|
6623 |
+
transitions: out,
|
6624 |
+
current: current,
|
6625 |
+
deleted: deleted,
|
6626 |
+
prevProps: props
|
6627 |
+
});
|
6628 |
+
}
|
6629 |
+
|
6630 |
+
var AnimatedStyle =
|
6631 |
+
/*#__PURE__*/
|
6632 |
+
function (_AnimatedObject) {
|
6633 |
+
_inheritsLoose(AnimatedStyle, _AnimatedObject);
|
6634 |
+
|
6635 |
+
function AnimatedStyle(style) {
|
6636 |
+
var _this;
|
6637 |
+
|
6638 |
+
if (style === void 0) {
|
6639 |
+
style = {};
|
6640 |
+
}
|
6641 |
+
|
6642 |
+
_this = _AnimatedObject.call(this) || this;
|
6643 |
+
|
6644 |
+
if (style.transform && !(style.transform instanceof Animated)) {
|
6645 |
+
style = applyAnimatedValues.transform(style);
|
6646 |
+
}
|
6647 |
+
|
6648 |
+
_this.payload = style;
|
6649 |
+
return _this;
|
6650 |
+
}
|
6651 |
+
|
6652 |
+
return AnimatedStyle;
|
6653 |
+
}(AnimatedObject);
|
6654 |
+
|
6655 |
+
// http://www.w3.org/TR/css3-color/#svg-color
|
6656 |
+
var colors = {
|
6657 |
+
transparent: 0x00000000,
|
6658 |
+
aliceblue: 0xf0f8ffff,
|
6659 |
+
antiquewhite: 0xfaebd7ff,
|
6660 |
+
aqua: 0x00ffffff,
|
6661 |
+
aquamarine: 0x7fffd4ff,
|
6662 |
+
azure: 0xf0ffffff,
|
6663 |
+
beige: 0xf5f5dcff,
|
6664 |
+
bisque: 0xffe4c4ff,
|
6665 |
+
black: 0x000000ff,
|
6666 |
+
blanchedalmond: 0xffebcdff,
|
6667 |
+
blue: 0x0000ffff,
|
6668 |
+
blueviolet: 0x8a2be2ff,
|
6669 |
+
brown: 0xa52a2aff,
|
6670 |
+
burlywood: 0xdeb887ff,
|
6671 |
+
burntsienna: 0xea7e5dff,
|
6672 |
+
cadetblue: 0x5f9ea0ff,
|
6673 |
+
chartreuse: 0x7fff00ff,
|
6674 |
+
chocolate: 0xd2691eff,
|
6675 |
+
coral: 0xff7f50ff,
|
6676 |
+
cornflowerblue: 0x6495edff,
|
6677 |
+
cornsilk: 0xfff8dcff,
|
6678 |
+
crimson: 0xdc143cff,
|
6679 |
+
cyan: 0x00ffffff,
|
6680 |
+
darkblue: 0x00008bff,
|
6681 |
+
darkcyan: 0x008b8bff,
|
6682 |
+
darkgoldenrod: 0xb8860bff,
|
6683 |
+
darkgray: 0xa9a9a9ff,
|
6684 |
+
darkgreen: 0x006400ff,
|
6685 |
+
darkgrey: 0xa9a9a9ff,
|
6686 |
+
darkkhaki: 0xbdb76bff,
|
6687 |
+
darkmagenta: 0x8b008bff,
|
6688 |
+
darkolivegreen: 0x556b2fff,
|
6689 |
+
darkorange: 0xff8c00ff,
|
6690 |
+
darkorchid: 0x9932ccff,
|
6691 |
+
darkred: 0x8b0000ff,
|
6692 |
+
darksalmon: 0xe9967aff,
|
6693 |
+
darkseagreen: 0x8fbc8fff,
|
6694 |
+
darkslateblue: 0x483d8bff,
|
6695 |
+
darkslategray: 0x2f4f4fff,
|
6696 |
+
darkslategrey: 0x2f4f4fff,
|
6697 |
+
darkturquoise: 0x00ced1ff,
|
6698 |
+
darkviolet: 0x9400d3ff,
|
6699 |
+
deeppink: 0xff1493ff,
|
6700 |
+
deepskyblue: 0x00bfffff,
|
6701 |
+
dimgray: 0x696969ff,
|
6702 |
+
dimgrey: 0x696969ff,
|
6703 |
+
dodgerblue: 0x1e90ffff,
|
6704 |
+
firebrick: 0xb22222ff,
|
6705 |
+
floralwhite: 0xfffaf0ff,
|
6706 |
+
forestgreen: 0x228b22ff,
|
6707 |
+
fuchsia: 0xff00ffff,
|
6708 |
+
gainsboro: 0xdcdcdcff,
|
6709 |
+
ghostwhite: 0xf8f8ffff,
|
6710 |
+
gold: 0xffd700ff,
|
6711 |
+
goldenrod: 0xdaa520ff,
|
6712 |
+
gray: 0x808080ff,
|
6713 |
+
green: 0x008000ff,
|
6714 |
+
greenyellow: 0xadff2fff,
|
6715 |
+
grey: 0x808080ff,
|
6716 |
+
honeydew: 0xf0fff0ff,
|
6717 |
+
hotpink: 0xff69b4ff,
|
6718 |
+
indianred: 0xcd5c5cff,
|
6719 |
+
indigo: 0x4b0082ff,
|
6720 |
+
ivory: 0xfffff0ff,
|
6721 |
+
khaki: 0xf0e68cff,
|
6722 |
+
lavender: 0xe6e6faff,
|
6723 |
+
lavenderblush: 0xfff0f5ff,
|
6724 |
+
lawngreen: 0x7cfc00ff,
|
6725 |
+
lemonchiffon: 0xfffacdff,
|
6726 |
+
lightblue: 0xadd8e6ff,
|
6727 |
+
lightcoral: 0xf08080ff,
|
6728 |
+
lightcyan: 0xe0ffffff,
|
6729 |
+
lightgoldenrodyellow: 0xfafad2ff,
|
6730 |
+
lightgray: 0xd3d3d3ff,
|
6731 |
+
lightgreen: 0x90ee90ff,
|
6732 |
+
lightgrey: 0xd3d3d3ff,
|
6733 |
+
lightpink: 0xffb6c1ff,
|
6734 |
+
lightsalmon: 0xffa07aff,
|
6735 |
+
lightseagreen: 0x20b2aaff,
|
6736 |
+
lightskyblue: 0x87cefaff,
|
6737 |
+
lightslategray: 0x778899ff,
|
6738 |
+
lightslategrey: 0x778899ff,
|
6739 |
+
lightsteelblue: 0xb0c4deff,
|
6740 |
+
lightyellow: 0xffffe0ff,
|
6741 |
+
lime: 0x00ff00ff,
|
6742 |
+
limegreen: 0x32cd32ff,
|
6743 |
+
linen: 0xfaf0e6ff,
|
6744 |
+
magenta: 0xff00ffff,
|
6745 |
+
maroon: 0x800000ff,
|
6746 |
+
mediumaquamarine: 0x66cdaaff,
|
6747 |
+
mediumblue: 0x0000cdff,
|
6748 |
+
mediumorchid: 0xba55d3ff,
|
6749 |
+
mediumpurple: 0x9370dbff,
|
6750 |
+
mediumseagreen: 0x3cb371ff,
|
6751 |
+
mediumslateblue: 0x7b68eeff,
|
6752 |
+
mediumspringgreen: 0x00fa9aff,
|
6753 |
+
mediumturquoise: 0x48d1ccff,
|
6754 |
+
mediumvioletred: 0xc71585ff,
|
6755 |
+
midnightblue: 0x191970ff,
|
6756 |
+
mintcream: 0xf5fffaff,
|
6757 |
+
mistyrose: 0xffe4e1ff,
|
6758 |
+
moccasin: 0xffe4b5ff,
|
6759 |
+
navajowhite: 0xffdeadff,
|
6760 |
+
navy: 0x000080ff,
|
6761 |
+
oldlace: 0xfdf5e6ff,
|
6762 |
+
olive: 0x808000ff,
|
6763 |
+
olivedrab: 0x6b8e23ff,
|
6764 |
+
orange: 0xffa500ff,
|
6765 |
+
orangered: 0xff4500ff,
|
6766 |
+
orchid: 0xda70d6ff,
|
6767 |
+
palegoldenrod: 0xeee8aaff,
|
6768 |
+
palegreen: 0x98fb98ff,
|
6769 |
+
paleturquoise: 0xafeeeeff,
|
6770 |
+
palevioletred: 0xdb7093ff,
|
6771 |
+
papayawhip: 0xffefd5ff,
|
6772 |
+
peachpuff: 0xffdab9ff,
|
6773 |
+
peru: 0xcd853fff,
|
6774 |
+
pink: 0xffc0cbff,
|
6775 |
+
plum: 0xdda0ddff,
|
6776 |
+
powderblue: 0xb0e0e6ff,
|
6777 |
+
purple: 0x800080ff,
|
6778 |
+
rebeccapurple: 0x663399ff,
|
6779 |
+
red: 0xff0000ff,
|
6780 |
+
rosybrown: 0xbc8f8fff,
|
6781 |
+
royalblue: 0x4169e1ff,
|
6782 |
+
saddlebrown: 0x8b4513ff,
|
6783 |
+
salmon: 0xfa8072ff,
|
6784 |
+
sandybrown: 0xf4a460ff,
|
6785 |
+
seagreen: 0x2e8b57ff,
|
6786 |
+
seashell: 0xfff5eeff,
|
6787 |
+
sienna: 0xa0522dff,
|
6788 |
+
silver: 0xc0c0c0ff,
|
6789 |
+
skyblue: 0x87ceebff,
|
6790 |
+
slateblue: 0x6a5acdff,
|
6791 |
+
slategray: 0x708090ff,
|
6792 |
+
slategrey: 0x708090ff,
|
6793 |
+
snow: 0xfffafaff,
|
6794 |
+
springgreen: 0x00ff7fff,
|
6795 |
+
steelblue: 0x4682b4ff,
|
6796 |
+
tan: 0xd2b48cff,
|
6797 |
+
teal: 0x008080ff,
|
6798 |
+
thistle: 0xd8bfd8ff,
|
6799 |
+
tomato: 0xff6347ff,
|
6800 |
+
turquoise: 0x40e0d0ff,
|
6801 |
+
violet: 0xee82eeff,
|
6802 |
+
wheat: 0xf5deb3ff,
|
6803 |
+
white: 0xffffffff,
|
6804 |
+
whitesmoke: 0xf5f5f5ff,
|
6805 |
+
yellow: 0xffff00ff,
|
6806 |
+
yellowgreen: 0x9acd32ff
|
6807 |
+
};
|
6808 |
+
|
6809 |
+
// const INTEGER = '[-+]?\\d+';
|
6810 |
+
var NUMBER = '[-+]?\\d*\\.?\\d+';
|
6811 |
+
var PERCENTAGE = NUMBER + '%';
|
6812 |
+
|
6813 |
+
function call() {
|
6814 |
+
for (var _len = arguments.length, parts = new Array(_len), _key = 0; _key < _len; _key++) {
|
6815 |
+
parts[_key] = arguments[_key];
|
6816 |
+
}
|
6817 |
+
|
6818 |
+
return '\\(\\s*(' + parts.join(')\\s*,\\s*(') + ')\\s*\\)';
|
6819 |
+
}
|
6820 |
+
|
6821 |
+
var rgb = new RegExp('rgb' + call(NUMBER, NUMBER, NUMBER));
|
6822 |
+
var rgba = new RegExp('rgba' + call(NUMBER, NUMBER, NUMBER, NUMBER));
|
6823 |
+
var hsl = new RegExp('hsl' + call(NUMBER, PERCENTAGE, PERCENTAGE));
|
6824 |
+
var hsla = new RegExp('hsla' + call(NUMBER, PERCENTAGE, PERCENTAGE, NUMBER));
|
6825 |
+
var hex3 = /^#([0-9a-fA-F]{1})([0-9a-fA-F]{1})([0-9a-fA-F]{1})$/;
|
6826 |
+
var hex4 = /^#([0-9a-fA-F]{1})([0-9a-fA-F]{1})([0-9a-fA-F]{1})([0-9a-fA-F]{1})$/;
|
6827 |
+
var hex6 = /^#([0-9a-fA-F]{6})$/;
|
6828 |
+
var hex8 = /^#([0-9a-fA-F]{8})$/;
|
6829 |
+
|
6830 |
+
/*
|
6831 |
+
https://github.com/react-community/normalize-css-color
|
6832 |
+
|
6833 |
+
BSD 3-Clause License
|
6834 |
+
|
6835 |
+
Copyright (c) 2016, React Community
|
6836 |
+
All rights reserved.
|
6837 |
+
|
6838 |
+
Redistribution and use in source and binary forms, with or without
|
6839 |
+
modification, are permitted provided that the following conditions are met:
|
6840 |
+
|
6841 |
+
* Redistributions of source code must retain the above copyright notice, this
|
6842 |
+
list of conditions and the following disclaimer.
|
6843 |
+
|
6844 |
+
* Redistributions in binary form must reproduce the above copyright notice,
|
6845 |
+
this list of conditions and the following disclaimer in the documentation
|
6846 |
+
and/or other materials provided with the distribution.
|
6847 |
+
|
6848 |
+
* Neither the name of the copyright holder nor the names of its
|
6849 |
+
contributors may be used to endorse or promote products derived from
|
6850 |
+
this software without specific prior written permission.
|
6851 |
+
|
6852 |
+
THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
|
6853 |
+
AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
|
6854 |
+
IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
|
6855 |
+
DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE
|
6856 |
+
FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
|
6857 |
+
DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR
|
6858 |
+
SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER
|
6859 |
+
CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
|
6860 |
+
OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
|
6861 |
+
OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
6862 |
+
*/
|
6863 |
+
function normalizeColor(color) {
|
6864 |
+
var match;
|
6865 |
+
|
6866 |
+
if (typeof color === 'number') {
|
6867 |
+
return color >>> 0 === color && color >= 0 && color <= 0xffffffff ? color : null;
|
6868 |
+
} // Ordered based on occurrences on Facebook codebase
|
6869 |
+
|
6870 |
+
|
6871 |
+
if (match = hex6.exec(color)) return parseInt(match[1] + 'ff', 16) >>> 0;
|
6872 |
+
if (colors.hasOwnProperty(color)) return colors[color];
|
6873 |
+
|
6874 |
+
if (match = rgb.exec(color)) {
|
6875 |
+
return (parse255(match[1]) << 24 | // r
|
6876 |
+
parse255(match[2]) << 16 | // g
|
6877 |
+
parse255(match[3]) << 8 | // b
|
6878 |
+
0x000000ff) >>> // a
|
6879 |
+
0;
|
6880 |
+
}
|
6881 |
+
|
6882 |
+
if (match = rgba.exec(color)) {
|
6883 |
+
return (parse255(match[1]) << 24 | // r
|
6884 |
+
parse255(match[2]) << 16 | // g
|
6885 |
+
parse255(match[3]) << 8 | // b
|
6886 |
+
parse1(match[4])) >>> // a
|
6887 |
+
0;
|
6888 |
+
}
|
6889 |
+
|
6890 |
+
if (match = hex3.exec(color)) {
|
6891 |
+
return parseInt(match[1] + match[1] + // r
|
6892 |
+
match[2] + match[2] + // g
|
6893 |
+
match[3] + match[3] + // b
|
6894 |
+
'ff', // a
|
6895 |
+
16) >>> 0;
|
6896 |
+
} // https://drafts.csswg.org/css-color-4/#hex-notation
|
6897 |
+
|
6898 |
+
|
6899 |
+
if (match = hex8.exec(color)) return parseInt(match[1], 16) >>> 0;
|
6900 |
+
|
6901 |
+
if (match = hex4.exec(color)) {
|
6902 |
+
return parseInt(match[1] + match[1] + // r
|
6903 |
+
match[2] + match[2] + // g
|
6904 |
+
match[3] + match[3] + // b
|
6905 |
+
match[4] + match[4], // a
|
6906 |
+
16) >>> 0;
|
6907 |
+
}
|
6908 |
+
|
6909 |
+
if (match = hsl.exec(color)) {
|
6910 |
+
return (hslToRgb(parse360(match[1]), // h
|
6911 |
+
parsePercentage(match[2]), // s
|
6912 |
+
parsePercentage(match[3]) // l
|
6913 |
+
) | 0x000000ff) >>> // a
|
6914 |
+
0;
|
6915 |
+
}
|
6916 |
+
|
6917 |
+
if (match = hsla.exec(color)) {
|
6918 |
+
return (hslToRgb(parse360(match[1]), // h
|
6919 |
+
parsePercentage(match[2]), // s
|
6920 |
+
parsePercentage(match[3]) // l
|
6921 |
+
) | parse1(match[4])) >>> // a
|
6922 |
+
0;
|
6923 |
+
}
|
6924 |
+
|
6925 |
+
return null;
|
6926 |
+
}
|
6927 |
+
|
6928 |
+
function hue2rgb(p, q, t) {
|
6929 |
+
if (t < 0) t += 1;
|
6930 |
+
if (t > 1) t -= 1;
|
6931 |
+
if (t < 1 / 6) return p + (q - p) * 6 * t;
|
6932 |
+
if (t < 1 / 2) return q;
|
6933 |
+
if (t < 2 / 3) return p + (q - p) * (2 / 3 - t) * 6;
|
6934 |
+
return p;
|
6935 |
+
}
|
6936 |
+
|
6937 |
+
function hslToRgb(h, s, l) {
|
6938 |
+
var q = l < 0.5 ? l * (1 + s) : l + s - l * s;
|
6939 |
+
var p = 2 * l - q;
|
6940 |
+
var r = hue2rgb(p, q, h + 1 / 3);
|
6941 |
+
var g = hue2rgb(p, q, h);
|
6942 |
+
var b = hue2rgb(p, q, h - 1 / 3);
|
6943 |
+
return Math.round(r * 255) << 24 | Math.round(g * 255) << 16 | Math.round(b * 255) << 8;
|
6944 |
+
}
|
6945 |
+
|
6946 |
+
function parse255(str) {
|
6947 |
+
var int = parseInt(str, 10);
|
6948 |
+
if (int < 0) return 0;
|
6949 |
+
if (int > 255) return 255;
|
6950 |
+
return int;
|
6951 |
+
}
|
6952 |
+
|
6953 |
+
function parse360(str) {
|
6954 |
+
var int = parseFloat(str);
|
6955 |
+
return (int % 360 + 360) % 360 / 360;
|
6956 |
+
}
|
6957 |
+
|
6958 |
+
function parse1(str) {
|
6959 |
+
var num = parseFloat(str);
|
6960 |
+
if (num < 0) return 0;
|
6961 |
+
if (num > 1) return 255;
|
6962 |
+
return Math.round(num * 255);
|
6963 |
+
}
|
6964 |
+
|
6965 |
+
function parsePercentage(str) {
|
6966 |
+
// parseFloat conveniently ignores the final %
|
6967 |
+
var int = parseFloat(str);
|
6968 |
+
if (int < 0) return 0;
|
6969 |
+
if (int > 100) return 1;
|
6970 |
+
return int / 100;
|
6971 |
+
}
|
6972 |
+
|
6973 |
+
function colorToRgba(input) {
|
6974 |
+
var int32Color = normalizeColor(input);
|
6975 |
+
if (int32Color === null) return input;
|
6976 |
+
int32Color = int32Color || 0;
|
6977 |
+
var r = (int32Color & 0xff000000) >>> 24;
|
6978 |
+
var g = (int32Color & 0x00ff0000) >>> 16;
|
6979 |
+
var b = (int32Color & 0x0000ff00) >>> 8;
|
6980 |
+
var a = (int32Color & 0x000000ff) / 255;
|
6981 |
+
return "rgba(" + r + ", " + g + ", " + b + ", " + a + ")";
|
6982 |
+
} // Problem: https://github.com/animatedjs/animated/pull/102
|
6983 |
+
// Solution: https://stackoverflow.com/questions/638565/parsing-scientific-notation-sensibly/658662
|
6984 |
+
|
6985 |
+
|
6986 |
+
var stringShapeRegex = /[+\-]?(?:0|[1-9]\d*)(?:\.\d*)?(?:[eE][+\-]?\d+)?/g; // Covers rgb, rgba, hsl, hsla
|
6987 |
+
// Taken from https://gist.github.com/olmokramer/82ccce673f86db7cda5e
|
6988 |
+
|
6989 |
+
var colorRegex = /(#(?:[0-9a-f]{2}){2,4}|(#[0-9a-f]{3})|(rgb|hsl)a?\((-?\d+%?[,\s]+){2,3}\s*[\d\.]+%?\))/gi; // Covers color names (transparent, blue, etc.)
|
6990 |
+
|
6991 |
+
var colorNamesRegex = new RegExp("(" + Object.keys(colors).join('|') + ")", 'g');
|
6992 |
+
/**
|
6993 |
+
* Supports string shapes by extracting numbers so new values can be computed,
|
6994 |
+
* and recombines those values into new strings of the same shape. Supports
|
6995 |
+
* things like:
|
6996 |
+
*
|
6997 |
+
* rgba(123, 42, 99, 0.36) // colors
|
6998 |
+
* -45deg // values with units
|
6999 |
+
* 0 2px 2px 0px rgba(0, 0, 0, 0.12) // box shadows
|
7000 |
+
*/
|
7001 |
+
|
7002 |
+
var createStringInterpolator = function createStringInterpolator(config) {
|
7003 |
+
// Replace colors with rgba
|
7004 |
+
var outputRange = config.output.map(function (rangeValue) {
|
7005 |
+
return rangeValue.replace(colorRegex, colorToRgba);
|
7006 |
+
}).map(function (rangeValue) {
|
7007 |
+
return rangeValue.replace(colorNamesRegex, colorToRgba);
|
7008 |
+
});
|
7009 |
+
var outputRanges = outputRange[0].match(stringShapeRegex).map(function () {
|
7010 |
+
return [];
|
7011 |
+
});
|
7012 |
+
outputRange.forEach(function (value) {
|
7013 |
+
value.match(stringShapeRegex).forEach(function (number, i) {
|
7014 |
+
return outputRanges[i].push(+number);
|
7015 |
+
});
|
7016 |
+
});
|
7017 |
+
var interpolations = outputRange[0].match(stringShapeRegex).map(function (_value, i) {
|
7018 |
+
return createInterpolator(_extends({}, config, {
|
7019 |
+
output: outputRanges[i]
|
7020 |
+
}));
|
7021 |
+
});
|
7022 |
+
return function (input) {
|
7023 |
+
var i = 0;
|
7024 |
+
return outputRange[0] // 'rgba(0, 100, 200, 0)'
|
7025 |
+
// ->
|
7026 |
+
// 'rgba(${interpolations[0](input)}, ${interpolations[1](input)}, ...'
|
7027 |
+
.replace(stringShapeRegex, function () {
|
7028 |
+
return interpolations[i++](input);
|
7029 |
+
}) // rgba requires that the r,g,b are integers.... so we want to round them, but we *dont* want to
|
7030 |
+
// round the opacity (4th column).
|
7031 |
+
.replace(/rgba\(([0-9\.-]+), ([0-9\.-]+), ([0-9\.-]+), ([0-9\.-]+)\)/gi, function (_, p1, p2, p3, p4) {
|
7032 |
+
return "rgba(" + Math.round(p1) + ", " + Math.round(p2) + ", " + Math.round(p3) + ", " + p4 + ")";
|
7033 |
+
});
|
7034 |
+
};
|
7035 |
+
};
|
7036 |
+
|
7037 |
+
var isUnitlessNumber = {
|
7038 |
+
animationIterationCount: true,
|
7039 |
+
borderImageOutset: true,
|
7040 |
+
borderImageSlice: true,
|
7041 |
+
borderImageWidth: true,
|
7042 |
+
boxFlex: true,
|
7043 |
+
boxFlexGroup: true,
|
7044 |
+
boxOrdinalGroup: true,
|
7045 |
+
columnCount: true,
|
7046 |
+
columns: true,
|
7047 |
+
flex: true,
|
7048 |
+
flexGrow: true,
|
7049 |
+
flexPositive: true,
|
7050 |
+
flexShrink: true,
|
7051 |
+
flexNegative: true,
|
7052 |
+
flexOrder: true,
|
7053 |
+
gridRow: true,
|
7054 |
+
gridRowEnd: true,
|
7055 |
+
gridRowSpan: true,
|
7056 |
+
gridRowStart: true,
|
7057 |
+
gridColumn: true,
|
7058 |
+
gridColumnEnd: true,
|
7059 |
+
gridColumnSpan: true,
|
7060 |
+
gridColumnStart: true,
|
7061 |
+
fontWeight: true,
|
7062 |
+
lineClamp: true,
|
7063 |
+
lineHeight: true,
|
7064 |
+
opacity: true,
|
7065 |
+
order: true,
|
7066 |
+
orphans: true,
|
7067 |
+
tabSize: true,
|
7068 |
+
widows: true,
|
7069 |
+
zIndex: true,
|
7070 |
+
zoom: true,
|
7071 |
+
// SVG-related properties
|
7072 |
+
fillOpacity: true,
|
7073 |
+
floodOpacity: true,
|
7074 |
+
stopOpacity: true,
|
7075 |
+
strokeDasharray: true,
|
7076 |
+
strokeDashoffset: true,
|
7077 |
+
strokeMiterlimit: true,
|
7078 |
+
strokeOpacity: true,
|
7079 |
+
strokeWidth: true
|
7080 |
+
};
|
7081 |
+
|
7082 |
+
var prefixKey = function prefixKey(prefix, key) {
|
7083 |
+
return prefix + key.charAt(0).toUpperCase() + key.substring(1);
|
7084 |
+
};
|
7085 |
+
|
7086 |
+
var prefixes = ['Webkit', 'Ms', 'Moz', 'O'];
|
7087 |
+
isUnitlessNumber = Object.keys(isUnitlessNumber).reduce(function (acc, prop) {
|
7088 |
+
prefixes.forEach(function (prefix) {
|
7089 |
+
return acc[prefixKey(prefix, prop)] = acc[prop];
|
7090 |
+
});
|
7091 |
+
return acc;
|
7092 |
+
}, isUnitlessNumber);
|
7093 |
+
|
7094 |
+
function dangerousStyleValue(name, value, isCustomProperty) {
|
7095 |
+
if (value == null || typeof value === 'boolean' || value === '') return '';
|
7096 |
+
if (!isCustomProperty && typeof value === 'number' && value !== 0 && !(isUnitlessNumber.hasOwnProperty(name) && isUnitlessNumber[name])) return value + 'px'; // Presumes implicit 'px' suffix for unitless numbers
|
7097 |
+
|
7098 |
+
return ('' + value).trim();
|
7099 |
+
}
|
7100 |
+
|
7101 |
+
var attributeCache = {};
|
7102 |
+
injectCreateAnimatedStyle(function (style) {
|
7103 |
+
return new AnimatedStyle(style);
|
7104 |
+
});
|
7105 |
+
injectDefaultElement('div');
|
7106 |
+
injectStringInterpolator(createStringInterpolator);
|
7107 |
+
injectColorNames(colors);
|
7108 |
+
injectApplyAnimatedValues(function (instance, props) {
|
7109 |
+
if (instance.nodeType && instance.setAttribute !== undefined) {
|
7110 |
+
var style = props.style,
|
7111 |
+
children = props.children,
|
7112 |
+
scrollTop = props.scrollTop,
|
7113 |
+
scrollLeft = props.scrollLeft,
|
7114 |
+
attributes = _objectWithoutPropertiesLoose(props, ["style", "children", "scrollTop", "scrollLeft"]);
|
7115 |
+
|
7116 |
+
var filter = instance.nodeName === 'filter' || instance.parentNode && instance.parentNode.nodeName === 'filter';
|
7117 |
+
if (scrollTop !== void 0) instance.scrollTop = scrollTop;
|
7118 |
+
if (scrollLeft !== void 0) instance.scrollLeft = scrollLeft; // Set textContent, if children is an animatable value
|
7119 |
+
|
7120 |
+
if (children !== void 0) instance.textContent = children; // Set styles ...
|
7121 |
+
|
7122 |
+
for (var styleName in style) {
|
7123 |
+
if (!style.hasOwnProperty(styleName)) continue;
|
7124 |
+
var isCustomProperty = styleName.indexOf('--') === 0;
|
7125 |
+
var styleValue = dangerousStyleValue(styleName, style[styleName], isCustomProperty);
|
7126 |
+
if (styleName === 'float') styleName = 'cssFloat';
|
7127 |
+
if (isCustomProperty) instance.style.setProperty(styleName, styleValue);else instance.style[styleName] = styleValue;
|
7128 |
+
} // Set attributes ...
|
7129 |
+
|
7130 |
+
|
7131 |
+
for (var name in attributes) {
|
7132 |
+
// Attributes are written in dash case
|
7133 |
+
var dashCase = filter ? name : attributeCache[name] || (attributeCache[name] = name.replace(/([A-Z])/g, function (n) {
|
7134 |
+
return '-' + n.toLowerCase();
|
7135 |
+
}));
|
7136 |
+
if (typeof instance.getAttribute(dashCase) !== 'undefined') instance.setAttribute(dashCase, attributes[name]);
|
7137 |
+
}
|
7138 |
+
|
7139 |
+
return;
|
7140 |
+
} else return false;
|
7141 |
+
}, function (style) {
|
7142 |
+
return style;
|
7143 |
+
});
|
7144 |
+
|
7145 |
+
var domElements = ['a', 'abbr', 'address', 'area', 'article', 'aside', 'audio', 'b', 'base', 'bdi', 'bdo', 'big', 'blockquote', 'body', 'br', 'button', 'canvas', 'caption', 'cite', 'code', 'col', 'colgroup', 'data', 'datalist', 'dd', 'del', 'details', 'dfn', 'dialog', 'div', 'dl', 'dt', 'em', 'embed', 'fieldset', 'figcaption', 'figure', 'footer', 'form', 'h1', 'h2', 'h3', 'h4', 'h5', 'h6', 'head', 'header', 'hgroup', 'hr', 'html', 'i', 'iframe', 'img', 'input', 'ins', 'kbd', 'keygen', 'label', 'legend', 'li', 'link', 'main', 'map', 'mark', 'menu', 'menuitem', 'meta', 'meter', 'nav', 'noscript', 'object', 'ol', 'optgroup', 'option', 'output', 'p', 'param', 'picture', 'pre', 'progress', 'q', 'rp', 'rt', 'ruby', 's', 'samp', 'script', 'section', 'select', 'small', 'source', 'span', 'strong', 'style', 'sub', 'summary', 'sup', 'table', 'tbody', 'td', 'textarea', 'tfoot', 'th', 'thead', 'time', 'title', 'tr', 'track', 'u', 'ul', 'var', 'video', 'wbr', // SVG
|
7146 |
+
'circle', 'clipPath', 'defs', 'ellipse', 'foreignObject', 'g', 'image', 'line', 'linearGradient', 'mask', 'path', 'pattern', 'polygon', 'polyline', 'radialGradient', 'rect', 'stop', 'svg', 'text', 'tspan'];
|
7147 |
+
// Extend animated with all the available THREE elements
|
7148 |
+
var apply = merge(createAnimatedComponent, false);
|
7149 |
+
var extendedAnimated = apply(domElements);
|
7150 |
+
|
7151 |
+
exports.apply = apply;
|
7152 |
+
exports.config = config;
|
7153 |
+
exports.update = update;
|
7154 |
+
exports.animated = extendedAnimated;
|
7155 |
+
exports.a = extendedAnimated;
|
7156 |
+
exports.interpolate = interpolate$1;
|
7157 |
+
exports.Globals = Globals;
|
7158 |
+
exports.useSpring = useSpring;
|
7159 |
+
exports.useTrail = useTrail;
|
7160 |
+
exports.useTransition = useTransition;
|
7161 |
+
exports.useChain = useChain;
|
7162 |
+
exports.useSprings = useSprings;
|
7163 |
+
|
7164 |
+
|
7165 |
+
/***/ }),
|
7166 |
+
|
7167 |
+
/***/ 16:
|
7168 |
+
/***/ (function(module, exports) {
|
7169 |
+
|
7170 |
+
(function() { module.exports = window["wp"]["url"]; }());
|
7171 |
+
|
7172 |
+
/***/ }),
|
7173 |
+
|
7174 |
+
/***/ 160:
|
7175 |
+
/***/ (function(module, __webpack_exports__, __webpack_require__) {
|
7176 |
+
|
7177 |
+
"use strict";
|
7178 |
+
/* WEBPACK VAR INJECTION */(function(global) {/* harmony import */ var react__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(5);
|
7179 |
+
/* harmony import */ var react__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(react__WEBPACK_IMPORTED_MODULE_0__);
|
7180 |
+
/* harmony import */ var _babel_runtime_helpers_esm_inheritsLoose__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(25);
|
7181 |
+
/* harmony import */ var prop_types__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(1);
|
7182 |
+
/* harmony import */ var prop_types__WEBPACK_IMPORTED_MODULE_2___default = /*#__PURE__*/__webpack_require__.n(prop_types__WEBPACK_IMPORTED_MODULE_2__);
|
7183 |
+
|
7184 |
+
|
7185 |
+
|
7186 |
+
|
7187 |
+
|
7188 |
+
var MAX_SIGNED_31_BIT_INT = 1073741823;
|
7189 |
+
var commonjsGlobal = typeof globalThis !== 'undefined' ? globalThis : typeof window !== 'undefined' ? window : typeof global !== 'undefined' ? global : {};
|
7190 |
+
|
7191 |
+
function getUniqueId() {
|
7192 |
+
var key = '__global_unique_id__';
|
7193 |
+
return commonjsGlobal[key] = (commonjsGlobal[key] || 0) + 1;
|
7194 |
+
}
|
7195 |
+
|
7196 |
+
function objectIs(x, y) {
|
7197 |
+
if (x === y) {
|
7198 |
+
return x !== 0 || 1 / x === 1 / y;
|
7199 |
+
} else {
|
7200 |
+
return x !== x && y !== y;
|
7201 |
+
}
|
7202 |
+
}
|
7203 |
+
|
7204 |
+
function createEventEmitter(value) {
|
7205 |
+
var handlers = [];
|
7206 |
+
return {
|
7207 |
+
on: function on(handler) {
|
7208 |
+
handlers.push(handler);
|
7209 |
+
},
|
7210 |
+
off: function off(handler) {
|
7211 |
+
handlers = handlers.filter(function (h) {
|
7212 |
+
return h !== handler;
|
7213 |
+
});
|
7214 |
+
},
|
7215 |
+
get: function get() {
|
7216 |
+
return value;
|
7217 |
+
},
|
7218 |
+
set: function set(newValue, changedBits) {
|
7219 |
+
value = newValue;
|
7220 |
+
handlers.forEach(function (handler) {
|
7221 |
+
return handler(value, changedBits);
|
7222 |
+
});
|
7223 |
+
}
|
7224 |
+
};
|
7225 |
+
}
|
7226 |
+
|
7227 |
+
function onlyChild(children) {
|
7228 |
+
return Array.isArray(children) ? children[0] : children;
|
7229 |
+
}
|
7230 |
+
|
7231 |
+
function createReactContext(defaultValue, calculateChangedBits) {
|
7232 |
+
var _Provider$childContex, _Consumer$contextType;
|
7233 |
+
|
7234 |
+
var contextProp = '__create-react-context-' + getUniqueId() + '__';
|
7235 |
+
|
7236 |
+
var Provider = /*#__PURE__*/function (_Component) {
|
7237 |
+
Object(_babel_runtime_helpers_esm_inheritsLoose__WEBPACK_IMPORTED_MODULE_1__[/* default */ "a"])(Provider, _Component);
|
7238 |
+
|
7239 |
+
function Provider() {
|
7240 |
+
var _this;
|
7241 |
+
|
7242 |
+
_this = _Component.apply(this, arguments) || this;
|
7243 |
+
_this.emitter = createEventEmitter(_this.props.value);
|
7244 |
+
return _this;
|
7245 |
+
}
|
7246 |
+
|
7247 |
+
var _proto = Provider.prototype;
|
7248 |
+
|
7249 |
+
_proto.getChildContext = function getChildContext() {
|
7250 |
+
var _ref;
|
7251 |
+
|
7252 |
+
return _ref = {}, _ref[contextProp] = this.emitter, _ref;
|
7253 |
+
};
|
7254 |
+
|
7255 |
+
_proto.componentWillReceiveProps = function componentWillReceiveProps(nextProps) {
|
7256 |
+
if (this.props.value !== nextProps.value) {
|
7257 |
+
var oldValue = this.props.value;
|
7258 |
+
var newValue = nextProps.value;
|
7259 |
+
var changedBits;
|
7260 |
+
|
7261 |
+
if (objectIs(oldValue, newValue)) {
|
7262 |
+
changedBits = 0;
|
7263 |
+
} else {
|
7264 |
+
changedBits = typeof calculateChangedBits === 'function' ? calculateChangedBits(oldValue, newValue) : MAX_SIGNED_31_BIT_INT;
|
7265 |
+
|
7266 |
+
if (false) {}
|
7267 |
+
|
7268 |
+
changedBits |= 0;
|
7269 |
+
|
7270 |
+
if (changedBits !== 0) {
|
7271 |
+
this.emitter.set(nextProps.value, changedBits);
|
7272 |
+
}
|
7273 |
+
}
|
7274 |
+
}
|
7275 |
+
};
|
7276 |
+
|
7277 |
+
_proto.render = function render() {
|
7278 |
+
return this.props.children;
|
7279 |
+
};
|
7280 |
+
|
7281 |
+
return Provider;
|
7282 |
+
}(react__WEBPACK_IMPORTED_MODULE_0__["Component"]);
|
7283 |
+
|
7284 |
+
Provider.childContextTypes = (_Provider$childContex = {}, _Provider$childContex[contextProp] = prop_types__WEBPACK_IMPORTED_MODULE_2___default.a.object.isRequired, _Provider$childContex);
|
7285 |
+
|
7286 |
+
var Consumer = /*#__PURE__*/function (_Component2) {
|
7287 |
+
Object(_babel_runtime_helpers_esm_inheritsLoose__WEBPACK_IMPORTED_MODULE_1__[/* default */ "a"])(Consumer, _Component2);
|
7288 |
+
|
7289 |
+
function Consumer() {
|
7290 |
+
var _this2;
|
7291 |
+
|
7292 |
+
_this2 = _Component2.apply(this, arguments) || this;
|
7293 |
+
_this2.state = {
|
7294 |
+
value: _this2.getValue()
|
7295 |
+
};
|
7296 |
+
|
7297 |
+
_this2.onUpdate = function (newValue, changedBits) {
|
7298 |
+
var observedBits = _this2.observedBits | 0;
|
7299 |
+
|
7300 |
+
if ((observedBits & changedBits) !== 0) {
|
7301 |
+
_this2.setState({
|
7302 |
+
value: _this2.getValue()
|
7303 |
+
});
|
7304 |
+
}
|
7305 |
+
};
|
7306 |
+
|
7307 |
+
return _this2;
|
7308 |
+
}
|
7309 |
+
|
7310 |
+
var _proto2 = Consumer.prototype;
|
7311 |
+
|
7312 |
+
_proto2.componentWillReceiveProps = function componentWillReceiveProps(nextProps) {
|
7313 |
+
var observedBits = nextProps.observedBits;
|
7314 |
+
this.observedBits = observedBits === undefined || observedBits === null ? MAX_SIGNED_31_BIT_INT : observedBits;
|
7315 |
+
};
|
7316 |
+
|
7317 |
+
_proto2.componentDidMount = function componentDidMount() {
|
7318 |
+
if (this.context[contextProp]) {
|
7319 |
+
this.context[contextProp].on(this.onUpdate);
|
7320 |
+
}
|
7321 |
+
|
7322 |
+
var observedBits = this.props.observedBits;
|
7323 |
+
this.observedBits = observedBits === undefined || observedBits === null ? MAX_SIGNED_31_BIT_INT : observedBits;
|
7324 |
+
};
|
7325 |
+
|
7326 |
+
_proto2.componentWillUnmount = function componentWillUnmount() {
|
7327 |
+
if (this.context[contextProp]) {
|
7328 |
+
this.context[contextProp].off(this.onUpdate);
|
7329 |
+
}
|
7330 |
+
};
|
7331 |
+
|
7332 |
+
_proto2.getValue = function getValue() {
|
7333 |
+
if (this.context[contextProp]) {
|
7334 |
+
return this.context[contextProp].get();
|
7335 |
+
} else {
|
7336 |
+
return defaultValue;
|
7337 |
+
}
|
7338 |
+
};
|
7339 |
+
|
7340 |
+
_proto2.render = function render() {
|
7341 |
+
return onlyChild(this.props.children)(this.state.value);
|
7342 |
+
};
|
7343 |
+
|
7344 |
+
return Consumer;
|
7345 |
+
}(react__WEBPACK_IMPORTED_MODULE_0__["Component"]);
|
7346 |
+
|
7347 |
+
Consumer.contextTypes = (_Consumer$contextType = {}, _Consumer$contextType[contextProp] = prop_types__WEBPACK_IMPORTED_MODULE_2___default.a.object, _Consumer$contextType);
|
7348 |
+
return {
|
7349 |
+
Provider: Provider,
|
7350 |
+
Consumer: Consumer
|
7351 |
+
};
|
7352 |
+
}
|
7353 |
+
|
7354 |
+
var index = react__WEBPACK_IMPORTED_MODULE_0___default.a.createContext || createReactContext;
|
7355 |
+
|
7356 |
+
/* harmony default export */ __webpack_exports__["a"] = (index);
|
7357 |
+
|
7358 |
+
/* WEBPACK VAR INJECTION */}.call(this, __webpack_require__(79)))
|
7359 |
+
|
7360 |
+
/***/ }),
|
7361 |
+
|
7362 |
+
/***/ 161:
|
7363 |
+
/***/ (function(module, exports, __webpack_require__) {
|
7364 |
+
|
7365 |
+
var isarray = __webpack_require__(299)
|
7366 |
+
|
7367 |
+
/**
|
7368 |
+
* Expose `pathToRegexp`.
|
7369 |
+
*/
|
7370 |
+
module.exports = pathToRegexp
|
7371 |
+
module.exports.parse = parse
|
7372 |
+
module.exports.compile = compile
|
7373 |
+
module.exports.tokensToFunction = tokensToFunction
|
7374 |
+
module.exports.tokensToRegExp = tokensToRegExp
|
7375 |
+
|
7376 |
+
/**
|
7377 |
+
* The main path matching regexp utility.
|
7378 |
+
*
|
7379 |
+
* @type {RegExp}
|
7380 |
+
*/
|
7381 |
+
var PATH_REGEXP = new RegExp([
|
7382 |
+
// Match escaped characters that would otherwise appear in future matches.
|
7383 |
+
// This allows the user to escape special characters that won't transform.
|
7384 |
+
'(\\\\.)',
|
7385 |
+
// Match Express-style parameters and un-named parameters with a prefix
|
7386 |
+
// and optional suffixes. Matches appear as:
|
7387 |
+
//
|
7388 |
+
// "/:test(\\d+)?" => ["/", "test", "\d+", undefined, "?", undefined]
|
7389 |
+
// "/route(\\d+)" => [undefined, undefined, undefined, "\d+", undefined, undefined]
|
7390 |
+
// "/*" => ["/", undefined, undefined, undefined, undefined, "*"]
|
7391 |
+
'([\\/.])?(?:(?:\\:(\\w+)(?:\\(((?:\\\\.|[^\\\\()])+)\\))?|\\(((?:\\\\.|[^\\\\()])+)\\))([+*?])?|(\\*))'
|
7392 |
+
].join('|'), 'g')
|
7393 |
+
|
7394 |
+
/**
|
7395 |
+
* Parse a string for the raw tokens.
|
7396 |
+
*
|
7397 |
+
* @param {string} str
|
7398 |
+
* @param {Object=} options
|
7399 |
+
* @return {!Array}
|
7400 |
+
*/
|
7401 |
+
function parse (str, options) {
|
7402 |
+
var tokens = []
|
7403 |
+
var key = 0
|
7404 |
+
var index = 0
|
7405 |
+
var path = ''
|
7406 |
+
var defaultDelimiter = options && options.delimiter || '/'
|
7407 |
+
var res
|
7408 |
+
|
7409 |
+
while ((res = PATH_REGEXP.exec(str)) != null) {
|
7410 |
+
var m = res[0]
|
7411 |
+
var escaped = res[1]
|
7412 |
+
var offset = res.index
|
7413 |
+
path += str.slice(index, offset)
|
7414 |
+
index = offset + m.length
|
7415 |
+
|
7416 |
+
// Ignore already escaped sequences.
|
7417 |
+
if (escaped) {
|
7418 |
+
path += escaped[1]
|
7419 |
+
continue
|
7420 |
+
}
|
7421 |
+
|
7422 |
+
var next = str[index]
|
7423 |
+
var prefix = res[2]
|
7424 |
+
var name = res[3]
|
7425 |
+
var capture = res[4]
|
7426 |
+
var group = res[5]
|
7427 |
+
var modifier = res[6]
|
7428 |
+
var asterisk = res[7]
|
7429 |
+
|
7430 |
+
// Push the current path onto the tokens.
|
7431 |
+
if (path) {
|
7432 |
+
tokens.push(path)
|
7433 |
+
path = ''
|
7434 |
+
}
|
7435 |
+
|
7436 |
+
var partial = prefix != null && next != null && next !== prefix
|
7437 |
+
var repeat = modifier === '+' || modifier === '*'
|
7438 |
+
var optional = modifier === '?' || modifier === '*'
|
7439 |
+
var delimiter = res[2] || defaultDelimiter
|
7440 |
+
var pattern = capture || group
|
7441 |
+
|
7442 |
+
tokens.push({
|
7443 |
+
name: name || key++,
|
7444 |
+
prefix: prefix || '',
|
7445 |
+
delimiter: delimiter,
|
7446 |
+
optional: optional,
|
7447 |
+
repeat: repeat,
|
7448 |
+
partial: partial,
|
7449 |
+
asterisk: !!asterisk,
|
7450 |
+
pattern: pattern ? escapeGroup(pattern) : (asterisk ? '.*' : '[^' + escapeString(delimiter) + ']+?')
|
7451 |
+
})
|
7452 |
+
}
|
7453 |
+
|
7454 |
+
// Match any characters still remaining.
|
7455 |
+
if (index < str.length) {
|
7456 |
+
path += str.substr(index)
|
7457 |
+
}
|
7458 |
+
|
7459 |
+
// If the path exists, push it onto the end.
|
7460 |
+
if (path) {
|
7461 |
+
tokens.push(path)
|
7462 |
+
}
|
7463 |
+
|
7464 |
+
return tokens
|
7465 |
+
}
|
7466 |
+
|
7467 |
+
/**
|
7468 |
+
* Compile a string to a template function for the path.
|
7469 |
+
*
|
7470 |
+
* @param {string} str
|
7471 |
+
* @param {Object=} options
|
7472 |
+
* @return {!function(Object=, Object=)}
|
7473 |
+
*/
|
7474 |
+
function compile (str, options) {
|
7475 |
+
return tokensToFunction(parse(str, options), options)
|
7476 |
+
}
|
7477 |
+
|
7478 |
+
/**
|
7479 |
+
* Prettier encoding of URI path segments.
|
7480 |
+
*
|
7481 |
+
* @param {string}
|
7482 |
+
* @return {string}
|
7483 |
+
*/
|
7484 |
+
function encodeURIComponentPretty (str) {
|
7485 |
+
return encodeURI(str).replace(/[\/?#]/g, function (c) {
|
7486 |
+
return '%' + c.charCodeAt(0).toString(16).toUpperCase()
|
7487 |
+
})
|
7488 |
+
}
|
7489 |
+
|
7490 |
+
/**
|
7491 |
+
* Encode the asterisk parameter. Similar to `pretty`, but allows slashes.
|
7492 |
+
*
|
7493 |
+
* @param {string}
|
7494 |
+
* @return {string}
|
7495 |
+
*/
|
7496 |
+
function encodeAsterisk (str) {
|
7497 |
+
return encodeURI(str).replace(/[?#]/g, function (c) {
|
7498 |
+
return '%' + c.charCodeAt(0).toString(16).toUpperCase()
|
7499 |
+
})
|
7500 |
+
}
|
7501 |
+
|
7502 |
+
/**
|
7503 |
+
* Expose a method for transforming tokens into the path function.
|
7504 |
+
*/
|
7505 |
+
function tokensToFunction (tokens, options) {
|
7506 |
+
// Compile all the tokens into regexps.
|
7507 |
+
var matches = new Array(tokens.length)
|
7508 |
+
|
7509 |
+
// Compile all the patterns before compilation.
|
7510 |
+
for (var i = 0; i < tokens.length; i++) {
|
7511 |
+
if (typeof tokens[i] === 'object') {
|
7512 |
+
matches[i] = new RegExp('^(?:' + tokens[i].pattern + ')$', flags(options))
|
7513 |
+
}
|
7514 |
+
}
|
7515 |
+
|
7516 |
+
return function (obj, opts) {
|
7517 |
+
var path = ''
|
7518 |
+
var data = obj || {}
|
7519 |
+
var options = opts || {}
|
7520 |
+
var encode = options.pretty ? encodeURIComponentPretty : encodeURIComponent
|
7521 |
+
|
7522 |
+
for (var i = 0; i < tokens.length; i++) {
|
7523 |
+
var token = tokens[i]
|
7524 |
+
|
7525 |
+
if (typeof token === 'string') {
|
7526 |
+
path += token
|
7527 |
+
|
7528 |
+
continue
|
7529 |
+
}
|
7530 |
+
|
7531 |
+
var value = data[token.name]
|
7532 |
+
var segment
|
7533 |
+
|
7534 |
+
if (value == null) {
|
7535 |
+
if (token.optional) {
|
7536 |
+
// Prepend partial segment prefixes.
|
7537 |
+
if (token.partial) {
|
7538 |
+
path += token.prefix
|
7539 |
+
}
|
7540 |
+
|
7541 |
+
continue
|
7542 |
+
} else {
|
7543 |
+
throw new TypeError('Expected "' + token.name + '" to be defined')
|
7544 |
+
}
|
7545 |
+
}
|
7546 |
+
|
7547 |
+
if (isarray(value)) {
|
7548 |
+
if (!token.repeat) {
|
7549 |
+
throw new TypeError('Expected "' + token.name + '" to not repeat, but received `' + JSON.stringify(value) + '`')
|
7550 |
+
}
|
7551 |
+
|
7552 |
+
if (value.length === 0) {
|
7553 |
+
if (token.optional) {
|
7554 |
+
continue
|
7555 |
+
} else {
|
7556 |
+
throw new TypeError('Expected "' + token.name + '" to not be empty')
|
7557 |
+
}
|
7558 |
+
}
|
7559 |
+
|
7560 |
+
for (var j = 0; j < value.length; j++) {
|
7561 |
+
segment = encode(value[j])
|
7562 |
+
|
7563 |
+
if (!matches[i].test(segment)) {
|
7564 |
+
throw new TypeError('Expected all "' + token.name + '" to match "' + token.pattern + '", but received `' + JSON.stringify(segment) + '`')
|
7565 |
+
}
|
7566 |
+
|
7567 |
+
path += (j === 0 ? token.prefix : token.delimiter) + segment
|
7568 |
+
}
|
7569 |
+
|
7570 |
+
continue
|
7571 |
+
}
|
7572 |
+
|
7573 |
+
segment = token.asterisk ? encodeAsterisk(value) : encode(value)
|
7574 |
+
|
7575 |
+
if (!matches[i].test(segment)) {
|
7576 |
+
throw new TypeError('Expected "' + token.name + '" to match "' + token.pattern + '", but received "' + segment + '"')
|
7577 |
+
}
|
7578 |
+
|
7579 |
+
path += token.prefix + segment
|
7580 |
+
}
|
7581 |
+
|
7582 |
+
return path
|
7583 |
+
}
|
7584 |
+
}
|
7585 |
+
|
7586 |
+
/**
|
7587 |
+
* Escape a regular expression string.
|
7588 |
+
*
|
7589 |
+
* @param {string} str
|
7590 |
+
* @return {string}
|
7591 |
+
*/
|
7592 |
+
function escapeString (str) {
|
7593 |
+
return str.replace(/([.+*?=^!:${}()[\]|\/\\])/g, '\\$1')
|
7594 |
+
}
|
7595 |
+
|
7596 |
+
/**
|
7597 |
+
* Escape the capturing group by escaping special characters and meaning.
|
7598 |
+
*
|
7599 |
+
* @param {string} group
|
7600 |
+
* @return {string}
|
7601 |
+
*/
|
7602 |
+
function escapeGroup (group) {
|
7603 |
+
return group.replace(/([=!:$\/()])/g, '\\$1')
|
7604 |
+
}
|
7605 |
+
|
7606 |
+
/**
|
7607 |
+
* Attach the keys as a property of the regexp.
|
7608 |
+
*
|
7609 |
+
* @param {!RegExp} re
|
7610 |
+
* @param {Array} keys
|
7611 |
+
* @return {!RegExp}
|
7612 |
+
*/
|
7613 |
+
function attachKeys (re, keys) {
|
7614 |
+
re.keys = keys
|
7615 |
+
return re
|
7616 |
+
}
|
7617 |
+
|
7618 |
+
/**
|
7619 |
+
* Get the flags for a regexp from the options.
|
7620 |
+
*
|
7621 |
+
* @param {Object} options
|
7622 |
+
* @return {string}
|
7623 |
+
*/
|
7624 |
+
function flags (options) {
|
7625 |
+
return options && options.sensitive ? '' : 'i'
|
7626 |
+
}
|
7627 |
+
|
7628 |
+
/**
|
7629 |
+
* Pull out keys from a regexp.
|
7630 |
+
*
|
7631 |
+
* @param {!RegExp} path
|
7632 |
+
* @param {!Array} keys
|
7633 |
+
* @return {!RegExp}
|
7634 |
+
*/
|
7635 |
+
function regexpToRegexp (path, keys) {
|
7636 |
+
// Use a negative lookahead to match only capturing groups.
|
7637 |
+
var groups = path.source.match(/\((?!\?)/g)
|
7638 |
+
|
7639 |
+
if (groups) {
|
7640 |
+
for (var i = 0; i < groups.length; i++) {
|
7641 |
+
keys.push({
|
7642 |
+
name: i,
|
7643 |
+
prefix: null,
|
7644 |
+
delimiter: null,
|
7645 |
+
optional: false,
|
7646 |
+
repeat: false,
|
7647 |
+
partial: false,
|
7648 |
+
asterisk: false,
|
7649 |
+
pattern: null
|
7650 |
+
})
|
7651 |
+
}
|
7652 |
+
}
|
7653 |
+
|
7654 |
+
return attachKeys(path, keys)
|
7655 |
+
}
|
7656 |
+
|
7657 |
+
/**
|
7658 |
+
* Transform an array into a regexp.
|
7659 |
+
*
|
7660 |
+
* @param {!Array} path
|
7661 |
+
* @param {Array} keys
|
7662 |
+
* @param {!Object} options
|
7663 |
+
* @return {!RegExp}
|
7664 |
+
*/
|
7665 |
+
function arrayToRegexp (path, keys, options) {
|
7666 |
+
var parts = []
|
7667 |
+
|
7668 |
+
for (var i = 0; i < path.length; i++) {
|
7669 |
+
parts.push(pathToRegexp(path[i], keys, options).source)
|
7670 |
+
}
|
7671 |
+
|
7672 |
+
var regexp = new RegExp('(?:' + parts.join('|') + ')', flags(options))
|
7673 |
+
|
7674 |
+
return attachKeys(regexp, keys)
|
7675 |
+
}
|
7676 |
+
|
7677 |
+
/**
|
7678 |
+
* Create a path regexp from string input.
|
7679 |
+
*
|
7680 |
+
* @param {string} path
|
7681 |
+
* @param {!Array} keys
|
7682 |
+
* @param {!Object} options
|
7683 |
+
* @return {!RegExp}
|
7684 |
+
*/
|
7685 |
+
function stringToRegexp (path, keys, options) {
|
7686 |
+
return tokensToRegExp(parse(path, options), keys, options)
|
7687 |
+
}
|
7688 |
+
|
7689 |
+
/**
|
7690 |
+
* Expose a function for taking tokens and returning a RegExp.
|
7691 |
+
*
|
7692 |
+
* @param {!Array} tokens
|
7693 |
+
* @param {(Array|Object)=} keys
|
7694 |
+
* @param {Object=} options
|
7695 |
+
* @return {!RegExp}
|
7696 |
+
*/
|
7697 |
+
function tokensToRegExp (tokens, keys, options) {
|
7698 |
+
if (!isarray(keys)) {
|
7699 |
+
options = /** @type {!Object} */ (keys || options)
|
7700 |
+
keys = []
|
7701 |
+
}
|
7702 |
+
|
7703 |
+
options = options || {}
|
7704 |
+
|
7705 |
+
var strict = options.strict
|
7706 |
+
var end = options.end !== false
|
7707 |
+
var route = ''
|
7708 |
+
|
7709 |
+
// Iterate over the tokens and create our regexp string.
|
7710 |
+
for (var i = 0; i < tokens.length; i++) {
|
7711 |
+
var token = tokens[i]
|
7712 |
+
|
7713 |
+
if (typeof token === 'string') {
|
7714 |
+
route += escapeString(token)
|
7715 |
+
} else {
|
7716 |
+
var prefix = escapeString(token.prefix)
|
7717 |
+
var capture = '(?:' + token.pattern + ')'
|
7718 |
+
|
7719 |
+
keys.push(token)
|
7720 |
+
|
7721 |
+
if (token.repeat) {
|
7722 |
+
capture += '(?:' + prefix + capture + ')*'
|
7723 |
+
}
|
7724 |
+
|
7725 |
+
if (token.optional) {
|
7726 |
+
if (!token.partial) {
|
7727 |
+
capture = '(?:' + prefix + '(' + capture + '))?'
|
7728 |
+
} else {
|
7729 |
+
capture = prefix + '(' + capture + ')?'
|
7730 |
+
}
|
7731 |
+
} else {
|
7732 |
+
capture = prefix + '(' + capture + ')'
|
7733 |
+
}
|
7734 |
+
|
7735 |
+
route += capture
|
7736 |
+
}
|
7737 |
+
}
|
7738 |
+
|
7739 |
+
var delimiter = escapeString(options.delimiter || '/')
|
7740 |
+
var endsWithDelimiter = route.slice(-delimiter.length) === delimiter
|
7741 |
+
|
7742 |
+
// In non-strict mode we allow a slash at the end of match. If the path to
|
7743 |
+
// match already ends with a slash, we remove it for consistency. The slash
|
7744 |
+
// is valid at the end of a path match, not in the middle. This is important
|
7745 |
+
// in non-ending mode, where "/test/" shouldn't match "/test//route".
|
7746 |
+
if (!strict) {
|
7747 |
+
route = (endsWithDelimiter ? route.slice(0, -delimiter.length) : route) + '(?:' + delimiter + '(?=$))?'
|
7748 |
+
}
|
7749 |
+
|
7750 |
+
if (end) {
|
7751 |
+
route += '$'
|
7752 |
+
} else {
|
7753 |
+
// In non-ending mode, we need the capturing groups to match as much as
|
7754 |
+
// possible by using a positive lookahead to the end or next path segment.
|
7755 |
+
route += strict && endsWithDelimiter ? '' : '(?=' + delimiter + '|$)'
|
7756 |
+
}
|
7757 |
+
|
7758 |
+
return attachKeys(new RegExp('^' + route, flags(options)), keys)
|
7759 |
+
}
|
7760 |
+
|
7761 |
+
/**
|
7762 |
+
* Normalize the given path string, returning a regular expression.
|
7763 |
+
*
|
7764 |
+
* An empty array can be passed in for the keys, which will hold the
|
7765 |
+
* placeholder key descriptions. For example, using `/user/:id`, `keys` will
|
7766 |
+
* contain `[{ name: 'id', delimiter: '/', optional: false, repeat: false }]`.
|
7767 |
+
*
|
7768 |
+
* @param {(string|RegExp|Array)} path
|
7769 |
+
* @param {(Array|Object)=} keys
|
7770 |
+
* @param {Object=} options
|
7771 |
+
* @return {!RegExp}
|
7772 |
+
*/
|
7773 |
+
function pathToRegexp (path, keys, options) {
|
7774 |
+
if (!isarray(keys)) {
|
7775 |
+
options = /** @type {!Object} */ (keys || options)
|
7776 |
+
keys = []
|
7777 |
+
}
|
7778 |
+
|
7779 |
+
options = options || {}
|
7780 |
+
|
7781 |
+
if (path instanceof RegExp) {
|
7782 |
+
return regexpToRegexp(path, /** @type {!Array} */ (keys))
|
7783 |
+
}
|
7784 |
+
|
7785 |
+
if (isarray(path)) {
|
7786 |
+
return arrayToRegexp(/** @type {!Array} */ (path), /** @type {!Array} */ (keys), options)
|
7787 |
+
}
|
7788 |
+
|
7789 |
+
return stringToRegexp(/** @type {string} */ (path), /** @type {!Array} */ (keys), options)
|
7790 |
+
}
|
7791 |
+
|
7792 |
+
|
7793 |
+
/***/ }),
|
7794 |
+
|
7795 |
+
/***/ 164:
|
7796 |
+
/***/ (function(module, __webpack_exports__, __webpack_require__) {
|
7797 |
+
|
7798 |
+
"use strict";
|
7799 |
+
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "a", function() { return getUnreadNotesCount; });
|
7800 |
+
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "b", function() { return hasValidNotes; });
|
7801 |
+
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "c", function() { return truncateRenderableHTML; });
|
7802 |
+
/* harmony import */ var lodash__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(4);
|
7803 |
+
/* harmony import */ var lodash__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(lodash__WEBPACK_IMPORTED_MODULE_0__);
|
7804 |
+
/**
|
7805 |
+
* External dependencies
|
7806 |
+
*/
|
7807 |
+
|
7808 |
+
/**
|
7809 |
+
* Get the count of the unread notes from the received list.
|
7810 |
+
*
|
7811 |
+
* @param {Array} notes - List of notes, contains read and unread notes.
|
7812 |
+
* @param {number} lastRead - The timestamp that the user read a note.
|
7813 |
+
* @return {number} - Unread notes count.
|
7814 |
+
*/
|
7815 |
+
|
7816 |
+
function getUnreadNotesCount(notes, lastRead) {
|
7817 |
+
const unreadNotes = Object(lodash__WEBPACK_IMPORTED_MODULE_0__["filter"])(notes, note => {
|
7818 |
+
const {
|
7819 |
+
is_deleted: isDeleted,
|
7820 |
+
date_created_gmt: dateCreatedGmt,
|
7821 |
+
status
|
7822 |
+
} = note;
|
7823 |
+
|
7824 |
+
if (!isDeleted) {
|
7825 |
+
const unread = !lastRead || !dateCreatedGmt || new Date(dateCreatedGmt + 'Z').getTime() > lastRead;
|
7826 |
+
return unread && status === 'unactioned';
|
7827 |
+
}
|
7828 |
+
});
|
7829 |
+
return unreadNotes.length;
|
7830 |
+
}
|
7831 |
+
/**
|
7832 |
+
* Verifies if there are any valid notes in the list.
|
7833 |
+
*
|
7834 |
+
* @param {Array} notes - List of notes, contains read and unread notes.
|
7835 |
+
* @return {boolean} - Whether there are valid notes or not.
|
7836 |
+
*/
|
7837 |
+
|
7838 |
+
function hasValidNotes(notes) {
|
7839 |
+
const validNotes = Object(lodash__WEBPACK_IMPORTED_MODULE_0__["filter"])(notes, note => {
|
7840 |
+
const {
|
7841 |
+
is_deleted: isDeleted
|
7842 |
+
} = note;
|
7843 |
+
return !isDeleted;
|
7844 |
+
});
|
7845 |
+
return validNotes.length > 0;
|
7846 |
+
}
|
7847 |
+
/**
|
7848 |
+
* Truncates characters inside of an element.
|
7849 |
+
* Currently does not count <br> as a character even though it should.
|
7850 |
+
*
|
7851 |
+
* @param {HTMLElement} element HTML element
|
7852 |
+
* @param {number} limit number of characters to limit to
|
7853 |
+
*/
|
7854 |
+
|
7855 |
+
const truncateElement = (element, limit) => {
|
7856 |
+
const truncatedNode = document.createElement('div');
|
7857 |
+
const childNodes = Array.from(element.childNodes);
|
7858 |
+
|
7859 |
+
for (let i = 0; i < childNodes.length; i++) {
|
7860 |
+
// Deep clone.
|
7861 |
+
let clone = childNodes[i].cloneNode(true);
|
7862 |
+
|
7863 |
+
if (truncatedNode.textContent.length + clone.textContent.length <= limit) {
|
7864 |
+
// No problem including a whole child node, no need to consider truncating at all.
|
7865 |
+
truncatedNode.appendChild(clone);
|
7866 |
+
} else {
|
7867 |
+
const charactersRemaining = limit - truncatedNode.textContent.length;
|
7868 |
+
|
7869 |
+
if (!clone.innerHTML || clone.textContent.slice(0, charactersRemaining) === clone.innerHTML.slice(0, charactersRemaining)) {
|
7870 |
+
// If text until the limit doesn't contain any markup, we're all good to truncate.
|
7871 |
+
clone.textContent = Object(lodash__WEBPACK_IMPORTED_MODULE_0__["truncate"])(clone.textContent, {
|
7872 |
+
length: charactersRemaining,
|
7873 |
+
separator: ' ',
|
7874 |
+
omission: ''
|
7875 |
+
});
|
7876 |
+
} else {
|
7877 |
+
// If it does, then we'd need to recursively run this with balance of characters remaining.
|
7878 |
+
clone = truncateElement(clone, charactersRemaining);
|
7879 |
+
}
|
7880 |
+
|
7881 |
+
truncatedNode.appendChild(clone); // Exceeded limit at this point, safe to exit loop.
|
7882 |
+
|
7883 |
+
break;
|
7884 |
+
}
|
7885 |
+
}
|
7886 |
+
|
7887 |
+
return truncatedNode;
|
7888 |
+
};
|
7889 |
+
/**
|
7890 |
+
* Truncates characters from a HTML string excluding markup. Truncated strings will be appended with ellipsis.
|
7891 |
+
*
|
7892 |
+
* @param {string} originalHTML HTML string
|
7893 |
+
* @param {number} limit number of characters to limit to
|
7894 |
+
*/
|
7895 |
+
|
7896 |
+
|
7897 |
+
const truncateRenderableHTML = (originalHTML, limit) => {
|
7898 |
+
const tempNode = document.createElement('div');
|
7899 |
+
tempNode.innerHTML = originalHTML;
|
7900 |
+
|
7901 |
+
if (tempNode.textContent.length > limit) {
|
7902 |
+
return truncateElement(tempNode, limit).innerHTML + '...';
|
7903 |
+
}
|
7904 |
+
|
7905 |
+
return originalHTML;
|
7906 |
+
};
|
7907 |
+
|
7908 |
+
/***/ }),
|
7909 |
+
|
7910 |
+
/***/ 17:
|
7911 |
+
/***/ (function(module, exports) {
|
7912 |
+
|
7913 |
+
(function() { module.exports = window["wc"]["experimental"]; }());
|
7914 |
+
|
7915 |
+
/***/ }),
|
7916 |
+
|
7917 |
+
/***/ 170:
|
7918 |
+
/***/ (function(module, __webpack_exports__, __webpack_require__) {
|
7919 |
+
|
7920 |
+
"use strict";
|
7921 |
+
|
7922 |
+
// EXPORTS
|
7923 |
+
__webpack_require__.d(__webpack_exports__, "a", function() { return /* binding */ Fill; });
|
7924 |
+
__webpack_require__.d(__webpack_exports__, "b", function() { return /* binding */ DisplayOptions; });
|
7925 |
+
|
7926 |
+
// EXTERNAL MODULE: external ["wp","element"]
|
7927 |
+
var external_wp_element_ = __webpack_require__(0);
|
7928 |
+
|
7929 |
+
// EXTERNAL MODULE: external ["wp","components"]
|
7930 |
+
var external_wp_components_ = __webpack_require__(3);
|
7931 |
+
|
7932 |
+
// EXTERNAL MODULE: external ["wp","data"]
|
7933 |
+
var external_wp_data_ = __webpack_require__(7);
|
7934 |
+
|
7935 |
+
// EXTERNAL MODULE: external ["wp","i18n"]
|
7936 |
+
var external_wp_i18n_ = __webpack_require__(2);
|
7937 |
+
|
7938 |
+
// EXTERNAL MODULE: external ["wc","data"]
|
7939 |
+
var external_wc_data_ = __webpack_require__(11);
|
7940 |
+
|
7941 |
+
// EXTERNAL MODULE: external ["wc","tracks"]
|
7942 |
+
var external_wc_tracks_ = __webpack_require__(15);
|
7943 |
+
|
7944 |
+
// CONCATENATED MODULE: ./client/header/activity-panel/display-options/icons/display.js
|
7945 |
+
|
7946 |
+
|
7947 |
+
/**
|
7948 |
+
* External dependencies
|
7949 |
+
*/
|
7950 |
+
|
7951 |
+
const DisplayIcon = () => Object(external_wp_element_["createElement"])(external_wp_element_["Fragment"], null, Object(external_wp_element_["createElement"])("svg", {
|
7952 |
+
className: "woocommerce-layout__activity-panel-tab-icon",
|
7953 |
+
width: "24",
|
7954 |
+
height: "24",
|
7955 |
+
viewBox: "3 3 24 24",
|
7956 |
+
fill: "none",
|
7957 |
+
xmlns: "http://www.w3.org/2000/svg"
|
7958 |
+
}, Object(external_wp_element_["createElement"])("path", {
|
7959 |
+
d: "M13.8053 15.3982C13.8053 15.7965 13.4867 16.1947 13.0089 16.1947H6.79646C6.55752 16.1947 6.39823 16.115 6.23894 15.9558C6.07965 15.7965 6 15.6372 6 15.3982V6.79646C6 6.63717 6.15929 6.39823 6.23894 6.23894C6.39823 6.07965 6.55752 6 6.79646 6H13.0089C13.4071 6 13.8053 6.31858 13.8053 6.79646V15.3982Z",
|
7960 |
+
strokeWidth: "1.5",
|
7961 |
+
strokeLinecap: "round",
|
7962 |
+
strokeLinejoin: "round"
|
7963 |
+
}), Object(external_wp_element_["createElement"])("path", {
|
7964 |
+
d: "M23.9203 10.6195C23.9203 11.0177 23.6017 11.4159 23.1238 11.4159H16.9115C16.6725 11.4159 16.5132 11.3363 16.3539 11.177C16.1946 11.0177 16.115 10.8584 16.115 10.6195V6.79646C16.115 6.39823 16.4336 6 16.9115 6H23.1238C23.5221 6 23.9203 6.31858 23.9203 6.79646V10.6195Z",
|
7965 |
+
strokeWidth: "1.5",
|
7966 |
+
strokeLinecap: "round",
|
7967 |
+
strokeLinejoin: "round"
|
7968 |
+
}), Object(external_wp_element_["createElement"])("path", {
|
7969 |
+
d: "M13.8053 23.2035C13.8053 23.4424 13.7257 23.6017 13.5664 23.761C13.4071 23.9203 13.2478 23.9999 13.0089 23.9999H6.79646C6.39823 23.9999 6 23.6813 6 23.2035V19.3804C6 19.1415 6.07965 18.9822 6.23894 18.8229C6.39823 18.6636 6.55752 18.584 6.79646 18.584H13.0089C13.4071 18.584 13.8053 18.9026 13.8053 19.3804V23.2035Z",
|
7970 |
+
strokeWidth: "1.5",
|
7971 |
+
strokeLinecap: "round",
|
7972 |
+
strokeLinejoin: "round"
|
7973 |
+
}), Object(external_wp_element_["createElement"])("path", {
|
7974 |
+
d: "M16.9912 23.9999C16.7522 23.9999 16.5929 23.9202 16.4336 23.7609C16.2743 23.6016 16.1947 23.4423 16.1947 23.2034V14.6016C16.1947 14.3627 16.2743 14.2034 16.4336 14.0441C16.5929 13.8848 16.7522 13.8052 16.9912 13.8052H23.2036C23.4425 13.8052 23.6018 13.8848 23.7611 14.0441C23.9204 14.2034 24 14.3627 24 14.6016V23.2034C24 23.6016 23.6814 23.9999 23.2036 23.9999H16.9912Z",
|
7975 |
+
strokeWidth: "1.5",
|
7976 |
+
strokeLinecap: "round",
|
7977 |
+
strokeLinejoin: "round"
|
7978 |
+
})), Object(external_wp_i18n_["__"])('Display', 'woocommerce-admin'));
|
7979 |
+
// CONCATENATED MODULE: ./client/header/activity-panel/display-options/icons/single-column.js
|
7980 |
+
|
7981 |
+
const SingleColumnIcon = () => Object(external_wp_element_["createElement"])("svg", {
|
7982 |
+
className: "woocommerce-layout__activity-panel-tab-icon",
|
7983 |
+
width: "12",
|
7984 |
+
height: "14",
|
7985 |
+
viewBox: "0 0 12 14",
|
7986 |
+
fill: "none",
|
7987 |
+
xmlns: "http://www.w3.org/2000/svg"
|
7988 |
+
}, Object(external_wp_element_["createElement"])("rect", {
|
7989 |
+
x: "0.5",
|
7990 |
+
y: "0.5",
|
7991 |
+
width: "11",
|
7992 |
+
height: "13",
|
7993 |
+
strokeWidth: "1"
|
7994 |
+
}));
|
7995 |
+
// CONCATENATED MODULE: ./client/header/activity-panel/display-options/icons/two-columns.js
|
7996 |
+
|
7997 |
+
const TwoColumnsIcon = () => Object(external_wp_element_["createElement"])("svg", {
|
7998 |
+
className: "woocommerce-layout__activity-panel-tab-icon",
|
7999 |
+
width: "18",
|
8000 |
+
height: "14",
|
8001 |
+
viewBox: "0 0 18 14",
|
8002 |
+
fill: "none",
|
8003 |
+
xmlns: "http://www.w3.org/2000/svg"
|
8004 |
+
}, Object(external_wp_element_["createElement"])("rect", {
|
8005 |
+
x: "0.5",
|
8006 |
+
y: "0.5",
|
8007 |
+
width: "7",
|
8008 |
+
height: "13",
|
8009 |
+
strokeWidth: "1"
|
8010 |
+
}), Object(external_wp_element_["createElement"])("rect", {
|
8011 |
+
x: "9.5",
|
8012 |
+
y: "0.5",
|
8013 |
+
width: "7",
|
8014 |
+
height: "13",
|
8015 |
+
strokeWidth: "1"
|
8016 |
+
}));
|
8017 |
+
// CONCATENATED MODULE: ./client/header/activity-panel/display-options/index.js
|
8018 |
+
|
8019 |
+
|
8020 |
+
/**
|
8021 |
+
* External dependencies
|
8022 |
+
*/
|
8023 |
+
|
8024 |
+
|
8025 |
+
|
8026 |
+
|
8027 |
+
|
8028 |
+
/**
|
8029 |
+
* Internal dependencies
|
8030 |
+
*/
|
8031 |
+
|
8032 |
+
|
8033 |
+
|
8034 |
+
|
8035 |
+
const {
|
8036 |
+
Fill,
|
8037 |
+
Slot
|
8038 |
+
} = Object(external_wp_components_["createSlotFill"])('DisplayOptions');
|
8039 |
+
Fill.Slot = Slot;
|
8040 |
+
|
8041 |
+
const LAYOUTS = [{
|
8042 |
+
value: 'single_column',
|
8043 |
+
label: Object(external_wp_element_["createElement"])(external_wp_element_["Fragment"], null, Object(external_wp_element_["createElement"])(SingleColumnIcon, null), Object(external_wp_i18n_["__"])('Single column', 'woocommerce-admin'))
|
8044 |
+
}, {
|
8045 |
+
value: 'two_columns',
|
8046 |
+
label: Object(external_wp_element_["createElement"])(external_wp_element_["Fragment"], null, Object(external_wp_element_["createElement"])(TwoColumnsIcon, null), Object(external_wp_i18n_["__"])('Two columns', 'woocommerce-admin'))
|
8047 |
+
}];
|
8048 |
+
const DisplayOptions = () => {
|
8049 |
+
const {
|
8050 |
+
defaultHomescreenLayout,
|
8051 |
+
taskListComplete,
|
8052 |
+
isTaskListHidden
|
8053 |
+
} = Object(external_wp_data_["useSelect"])(select => {
|
8054 |
+
const {
|
8055 |
+
getOption
|
8056 |
+
} = select(external_wc_data_["OPTIONS_STORE_NAME"]);
|
8057 |
+
const {
|
8058 |
+
getTaskList
|
8059 |
+
} = select(external_wc_data_["ONBOARDING_STORE_NAME"]);
|
8060 |
+
const taskList = getTaskList('setup');
|
8061 |
+
return {
|
8062 |
+
defaultHomescreenLayout: getOption('woocommerce_default_homepage_layout') || 'single_column',
|
8063 |
+
taskListComplete: taskList === null || taskList === void 0 ? void 0 : taskList.isComplete,
|
8064 |
+
isTaskListHidden: taskList === null || taskList === void 0 ? void 0 : taskList.isHidden
|
8065 |
+
};
|
8066 |
+
});
|
8067 |
+
const {
|
8068 |
+
updateUserPreferences,
|
8069 |
+
homepage_layout: layout
|
8070 |
+
} = Object(external_wc_data_["useUserPreferences"])();
|
8071 |
+
const shouldShowStoreLinks = taskListComplete || isTaskListHidden;
|
8072 |
+
const hasTwoColumnContent = shouldShowStoreLinks || window.wcAdminFeatures.analytics;
|
8073 |
+
return Object(external_wp_element_["createElement"])(Slot, null, fills => {
|
8074 |
+
// If there is no fill to render and only single column content, don't render the display.
|
8075 |
+
if (fills.length === 0 && !hasTwoColumnContent) {
|
8076 |
+
return null;
|
8077 |
+
}
|
8078 |
+
|
8079 |
+
return Object(external_wp_element_["createElement"])(external_wp_components_["DropdownMenu"], {
|
8080 |
+
icon: Object(external_wp_element_["createElement"])(DisplayIcon, null)
|
8081 |
+
/* translators: button label text should, if possible, be under 16 characters. */
|
8082 |
+
,
|
8083 |
+
label: Object(external_wp_i18n_["__"])('Display options', 'woocommerce-admin'),
|
8084 |
+
toggleProps: {
|
8085 |
+
className: 'woocommerce-layout__activity-panel-tab display-options',
|
8086 |
+
onClick: () => Object(external_wc_tracks_["recordEvent"])('homescreen_display_click')
|
8087 |
+
},
|
8088 |
+
popoverProps: {
|
8089 |
+
className: 'woocommerce-layout__activity-panel-popover'
|
8090 |
+
}
|
8091 |
+
}, ({
|
8092 |
+
onClose
|
8093 |
+
}) => Object(external_wp_element_["createElement"])(external_wp_element_["Fragment"], null, fills, hasTwoColumnContent ? Object(external_wp_element_["createElement"])(external_wp_components_["MenuGroup"], {
|
8094 |
+
className: "woocommerce-layout__homescreen-display-options",
|
8095 |
+
label: Object(external_wp_i18n_["__"])('Layout', 'woocommerce-admin')
|
8096 |
+
}, Object(external_wp_element_["createElement"])(external_wp_components_["MenuItemsChoice"], {
|
8097 |
+
choices: LAYOUTS,
|
8098 |
+
onSelect: newLayout => {
|
8099 |
+
updateUserPreferences({
|
8100 |
+
homepage_layout: newLayout
|
8101 |
+
});
|
8102 |
+
onClose();
|
8103 |
+
Object(external_wc_tracks_["recordEvent"])('homescreen_display_option', {
|
8104 |
+
display_option: newLayout
|
8105 |
+
});
|
8106 |
+
},
|
8107 |
+
value: layout || defaultHomescreenLayout
|
8108 |
+
})) : null));
|
8109 |
+
});
|
8110 |
+
};
|
8111 |
+
|
8112 |
+
/***/ }),
|
8113 |
+
|
8114 |
+
/***/ 175:
|
8115 |
+
/***/ (function(module, __webpack_exports__, __webpack_require__) {
|
8116 |
+
|
8117 |
+
"use strict";
|
8118 |
+
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "a", function() { return NoMatch; });
|
8119 |
+
/* harmony import */ var _wordpress_element__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(0);
|
8120 |
+
/* harmony import */ var _wordpress_element__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(_wordpress_element__WEBPACK_IMPORTED_MODULE_0__);
|
8121 |
+
/* harmony import */ var _wordpress_i18n__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(2);
|
8122 |
+
/* harmony import */ var _wordpress_i18n__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(_wordpress_i18n__WEBPACK_IMPORTED_MODULE_1__);
|
8123 |
+
/* harmony import */ var _wordpress_components__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(3);
|
8124 |
+
/* harmony import */ var _wordpress_components__WEBPACK_IMPORTED_MODULE_2___default = /*#__PURE__*/__webpack_require__.n(_wordpress_components__WEBPACK_IMPORTED_MODULE_2__);
|
8125 |
+
/* harmony import */ var _woocommerce_experimental__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(17);
|
8126 |
+
/* harmony import */ var _woocommerce_experimental__WEBPACK_IMPORTED_MODULE_3___default = /*#__PURE__*/__webpack_require__.n(_woocommerce_experimental__WEBPACK_IMPORTED_MODULE_3__);
|
8127 |
+
|
8128 |
+
|
8129 |
+
/**
|
8130 |
+
* External dependencies
|
8131 |
+
*/
|
8132 |
+
|
8133 |
+
|
8134 |
+
|
8135 |
+
|
8136 |
+
const NoMatch = () => {
|
8137 |
+
return Object(_wordpress_element__WEBPACK_IMPORTED_MODULE_0__["createElement"])("div", {
|
8138 |
+
className: "woocommerce-layout__no-match"
|
8139 |
+
}, Object(_wordpress_element__WEBPACK_IMPORTED_MODULE_0__["createElement"])(_wordpress_components__WEBPACK_IMPORTED_MODULE_2__["Card"], null, Object(_wordpress_element__WEBPACK_IMPORTED_MODULE_0__["createElement"])(_wordpress_components__WEBPACK_IMPORTED_MODULE_2__["CardBody"], null, Object(_wordpress_element__WEBPACK_IMPORTED_MODULE_0__["createElement"])(_woocommerce_experimental__WEBPACK_IMPORTED_MODULE_3__["Text"], null, Object(_wordpress_i18n__WEBPACK_IMPORTED_MODULE_1__["__"])('Sorry, you are not allowed to access this page.', 'woocommerce-admin')))));
|
8140 |
+
};
|
8141 |
+
|
8142 |
+
|
8143 |
+
|
8144 |
+
/***/ }),
|
8145 |
+
|
8146 |
+
/***/ 18:
|
8147 |
+
/***/ (function(module, exports, __webpack_require__) {
|
8148 |
+
|
8149 |
+
"use strict";
|
8150 |
+
|
8151 |
+
|
8152 |
+
Object.defineProperty(exports, "__esModule", {
|
8153 |
+
value: true
|
8154 |
+
});
|
8155 |
+
|
8156 |
+
var _typeof = typeof Symbol === "function" && typeof Symbol.iterator === "symbol" ? function (obj) { return typeof obj; } : function (obj) { return obj && typeof Symbol === "function" && obj.constructor === Symbol && obj !== Symbol.prototype ? "symbol" : typeof obj; }; /**
|
8157 |
+
* External Dependencies
|
8158 |
+
*/
|
8159 |
+
|
8160 |
+
|
8161 |
+
/**
|
8162 |
+
* Internal Dependencies
|
8163 |
+
*/
|
8164 |
+
|
8165 |
+
|
8166 |
+
var _react = __webpack_require__(5);
|
8167 |
+
|
8168 |
+
var _react2 = _interopRequireDefault(_react);
|
8169 |
+
|
8170 |
+
var _reactAddonsCreateFragment = __webpack_require__(69);
|
8171 |
+
|
8172 |
+
var _reactAddonsCreateFragment2 = _interopRequireDefault(_reactAddonsCreateFragment);
|
8173 |
+
|
8174 |
+
var _tokenize = __webpack_require__(72);
|
8175 |
+
|
8176 |
+
var _tokenize2 = _interopRequireDefault(_tokenize);
|
8177 |
+
|
8178 |
+
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
|
8179 |
+
|
8180 |
+
var currentMixedString = void 0;
|
8181 |
+
|
8182 |
+
function getCloseIndex(openIndex, tokens) {
|
8183 |
+
var openToken = tokens[openIndex],
|
8184 |
+
nestLevel = 0,
|
8185 |
+
token,
|
8186 |
+
i;
|
8187 |
+
for (i = openIndex + 1; i < tokens.length; i++) {
|
8188 |
+
token = tokens[i];
|
8189 |
+
if (token.value === openToken.value) {
|
8190 |
+
if (token.type === 'componentOpen') {
|
8191 |
+
nestLevel++;
|
8192 |
+
continue;
|
8193 |
+
}
|
8194 |
+
if (token.type === 'componentClose') {
|
8195 |
+
if (nestLevel === 0) {
|
8196 |
+
return i;
|
8197 |
+
}
|
8198 |
+
nestLevel--;
|
8199 |
+
}
|
8200 |
+
}
|
8201 |
+
}
|
8202 |
+
// if we get this far, there was no matching close token
|
8203 |
+
throw new Error('Missing closing component token `' + openToken.value + '`');
|
8204 |
+
}
|
8205 |
+
|
8206 |
+
function buildChildren(tokens, components) {
|
8207 |
+
var children = [],
|
8208 |
+
childrenObject = {},
|
8209 |
+
openComponent,
|
8210 |
+
clonedOpenComponent,
|
8211 |
+
openIndex,
|
8212 |
+
closeIndex,
|
8213 |
+
token,
|
8214 |
+
i,
|
8215 |
+
grandChildTokens,
|
8216 |
+
grandChildren,
|
8217 |
+
siblingTokens,
|
8218 |
+
siblings;
|
8219 |
+
|
8220 |
+
for (i = 0; i < tokens.length; i++) {
|
8221 |
+
token = tokens[i];
|
8222 |
+
if (token.type === 'string') {
|
8223 |
+
children.push(token.value);
|
8224 |
+
continue;
|
8225 |
+
}
|
8226 |
+
// component node should at least be set
|
8227 |
+
if (!components.hasOwnProperty(token.value) || typeof components[token.value] === 'undefined') {
|
8228 |
+
throw new Error('Invalid interpolation, missing component node: `' + token.value + '`');
|
8229 |
+
}
|
8230 |
+
// should be either ReactElement or null (both type "object"), all other types deprecated
|
8231 |
+
if (_typeof(components[token.value]) !== 'object') {
|
8232 |
+
throw new Error('Invalid interpolation, component node must be a ReactElement or null: `' + token.value + '`', '\n> ' + currentMixedString);
|
8233 |
+
}
|
8234 |
+
// we should never see a componentClose token in this loop
|
8235 |
+
if (token.type === 'componentClose') {
|
8236 |
+
throw new Error('Missing opening component token: `' + token.value + '`');
|
8237 |
+
}
|
8238 |
+
if (token.type === 'componentOpen') {
|
8239 |
+
openComponent = components[token.value];
|
8240 |
+
openIndex = i;
|
8241 |
+
break;
|
8242 |
+
}
|
8243 |
+
// componentSelfClosing token
|
8244 |
+
children.push(components[token.value]);
|
8245 |
+
continue;
|
8246 |
+
}
|
8247 |
+
|
8248 |
+
if (openComponent) {
|
8249 |
+
closeIndex = getCloseIndex(openIndex, tokens);
|
8250 |
+
grandChildTokens = tokens.slice(openIndex + 1, closeIndex);
|
8251 |
+
grandChildren = buildChildren(grandChildTokens, components);
|
8252 |
+
clonedOpenComponent = _react2.default.cloneElement(openComponent, {}, grandChildren);
|
8253 |
+
children.push(clonedOpenComponent);
|
8254 |
+
|
8255 |
+
if (closeIndex < tokens.length - 1) {
|
8256 |
+
siblingTokens = tokens.slice(closeIndex + 1);
|
8257 |
+
siblings = buildChildren(siblingTokens, components);
|
8258 |
+
children = children.concat(siblings);
|
8259 |
+
}
|
8260 |
+
}
|
8261 |
+
|
8262 |
+
if (children.length === 1) {
|
8263 |
+
return children[0];
|
8264 |
+
}
|
8265 |
+
|
8266 |
+
children.forEach(function (child, index) {
|
8267 |
+
if (child) {
|
8268 |
+
childrenObject['interpolation-child-' + index] = child;
|
8269 |
+
}
|
8270 |
+
});
|
8271 |
+
|
8272 |
+
return (0, _reactAddonsCreateFragment2.default)(childrenObject);
|
8273 |
+
}
|
8274 |
+
|
8275 |
+
function interpolate(options) {
|
8276 |
+
var mixedString = options.mixedString,
|
8277 |
+
components = options.components,
|
8278 |
+
throwErrors = options.throwErrors;
|
8279 |
+
|
8280 |
+
|
8281 |
+
currentMixedString = mixedString;
|
8282 |
+
|
8283 |
+
if (!components) {
|
8284 |
+
return mixedString;
|
8285 |
+
}
|
8286 |
+
|
8287 |
+
if ((typeof components === 'undefined' ? 'undefined' : _typeof(components)) !== 'object') {
|
8288 |
+
if (throwErrors) {
|
8289 |
+
throw new Error('Interpolation Error: unable to process `' + mixedString + '` because components is not an object');
|
8290 |
+
}
|
8291 |
+
|
8292 |
+
return mixedString;
|
8293 |
+
}
|
8294 |
+
|
8295 |
+
var tokens = (0, _tokenize2.default)(mixedString);
|
8296 |
+
|
8297 |
+
try {
|
8298 |
+
return buildChildren(tokens, components);
|
8299 |
+
} catch (error) {
|
8300 |
+
if (throwErrors) {
|
8301 |
+
throw new Error('Interpolation Error: unable to process `' + mixedString + '` because of error `' + error.message + '`');
|
8302 |
+
}
|
8303 |
+
|
8304 |
+
return mixedString;
|
8305 |
+
}
|
8306 |
+
};
|
8307 |
+
|
8308 |
+
exports.default = interpolate;
|
8309 |
+
//# sourceMappingURL=index.js.map
|
8310 |
+
|
8311 |
+
/***/ }),
|
8312 |
+
|
8313 |
+
/***/ 19:
|
8314 |
+
/***/ (function(module, exports) {
|
8315 |
+
|
8316 |
+
(function() { module.exports = window["wp"]["apiFetch"]; }());
|
8317 |
+
|
8318 |
+
/***/ }),
|
8319 |
+
|
8320 |
+
/***/ 2:
|
8321 |
+
/***/ (function(module, exports) {
|
8322 |
+
|
8323 |
+
(function() { module.exports = window["wp"]["i18n"]; }());
|
8324 |
+
|
8325 |
+
/***/ }),
|
8326 |
+
|
8327 |
+
/***/ 20:
|
8328 |
+
/***/ (function(module, exports) {
|
8329 |
+
|
8330 |
+
(function() { module.exports = window["wc"]["date"]; }());
|
8331 |
+
|
8332 |
+
/***/ }),
|
8333 |
+
|
8334 |
+
/***/ 21:
|
8335 |
+
/***/ (function(module, exports) {
|
8336 |
+
|
8337 |
+
(function() { module.exports = window["wc"]["components"]; }());
|
8338 |
+
|
8339 |
+
/***/ }),
|
8340 |
+
|
8341 |
+
/***/ 22:
|
8342 |
+
/***/ (function(module, __webpack_exports__, __webpack_require__) {
|
8343 |
+
|
8344 |
+
"use strict";
|
8345 |
+
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "a", function() { return _objectWithoutPropertiesLoose; });
|
8346 |
+
function _objectWithoutPropertiesLoose(source, excluded) {
|
8347 |
+
if (source == null) return {};
|
8348 |
+
var target = {};
|
8349 |
+
var sourceKeys = Object.keys(source);
|
8350 |
+
var key, i;
|
8351 |
+
|
8352 |
+
for (i = 0; i < sourceKeys.length; i++) {
|
8353 |
+
key = sourceKeys[i];
|
8354 |
+
if (excluded.indexOf(key) >= 0) continue;
|
8355 |
+
target[key] = source[key];
|
8356 |
+
}
|
8357 |
+
|
8358 |
+
return target;
|
8359 |
+
}
|
8360 |
+
|
8361 |
+
/***/ }),
|
8362 |
+
|
8363 |
+
/***/ 23:
|
8364 |
+
/***/ (function(module, __webpack_exports__, __webpack_require__) {
|
8365 |
+
|
8366 |
+
"use strict";
|
8367 |
+
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "a", function() { return _extends; });
|
8368 |
+
function _extends() {
|
8369 |
+
_extends = Object.assign || function (target) {
|
8370 |
+
for (var i = 1; i < arguments.length; i++) {
|
8371 |
+
var source = arguments[i];
|
8372 |
+
|
8373 |
+
for (var key in source) {
|
8374 |
+
if (Object.prototype.hasOwnProperty.call(source, key)) {
|
8375 |
+
target[key] = source[key];
|
8376 |
+
}
|
8377 |
+
}
|
8378 |
+
}
|
8379 |
+
|
8380 |
+
return target;
|
8381 |
+
};
|
8382 |
+
|
8383 |
+
return _extends.apply(this, arguments);
|
8384 |
+
}
|
8385 |
+
|
8386 |
+
/***/ }),
|
8387 |
+
|
8388 |
+
/***/ 25:
|
8389 |
+
/***/ (function(module, __webpack_exports__, __webpack_require__) {
|
8390 |
+
|
8391 |
+
"use strict";
|
8392 |
+
|
8393 |
+
// EXPORTS
|
8394 |
+
__webpack_require__.d(__webpack_exports__, "a", function() { return /* binding */ _inheritsLoose; });
|
8395 |
+
|
8396 |
+
// CONCATENATED MODULE: ./node_modules/@babel/runtime/helpers/esm/setPrototypeOf.js
|
8397 |
+
function _setPrototypeOf(o, p) {
|
8398 |
+
_setPrototypeOf = Object.setPrototypeOf || function _setPrototypeOf(o, p) {
|
8399 |
+
o.__proto__ = p;
|
8400 |
+
return o;
|
8401 |
+
};
|
8402 |
+
|
8403 |
+
return _setPrototypeOf(o, p);
|
8404 |
+
}
|
8405 |
+
// CONCATENATED MODULE: ./node_modules/@babel/runtime/helpers/esm/inheritsLoose.js
|
8406 |
+
|
8407 |
+
function _inheritsLoose(subClass, superClass) {
|
8408 |
+
subClass.prototype = Object.create(superClass.prototype);
|
8409 |
+
subClass.prototype.constructor = subClass;
|
8410 |
+
_setPrototypeOf(subClass, superClass);
|
8411 |
+
}
|
8412 |
+
|
8413 |
+
/***/ }),
|
8414 |
+
|
8415 |
+
/***/ 255:
|
8416 |
+
/***/ (function(module, __webpack_exports__, __webpack_require__) {
|
8417 |
+
|
8418 |
+
"use strict";
|
8419 |
+
|
8420 |
+
// EXPORTS
|
8421 |
+
__webpack_require__.d(__webpack_exports__, "a", function() { return /* binding */ ABBREVIATED_NOTIFICATION_SLOT_NAME; });
|
8422 |
+
__webpack_require__.d(__webpack_exports__, "b", function() { return /* binding */ AbbreviatedNotificationsPanel; });
|
8423 |
+
|
8424 |
+
// EXTERNAL MODULE: external ["wp","element"]
|
8425 |
+
var external_wp_element_ = __webpack_require__(0);
|
8426 |
+
|
8427 |
+
// EXTERNAL MODULE: external ["wp","i18n"]
|
8428 |
+
var external_wp_i18n_ = __webpack_require__(2);
|
8429 |
+
|
8430 |
+
// EXTERNAL MODULE: external ["wc","experimental"]
|
8431 |
+
var external_wc_experimental_ = __webpack_require__(17);
|
8432 |
+
|
8433 |
+
// EXTERNAL MODULE: external ["wc","tracks"]
|
8434 |
+
var external_wc_tracks_ = __webpack_require__(15);
|
8435 |
+
|
8436 |
+
// EXTERNAL MODULE: external ["wc","components"]
|
8437 |
+
var external_wc_components_ = __webpack_require__(21);
|
8438 |
+
|
8439 |
+
// EXTERNAL MODULE: external ["wp","data"]
|
8440 |
+
var external_wp_data_ = __webpack_require__(7);
|
8441 |
+
|
8442 |
+
// EXTERNAL MODULE: external ["wc","data"]
|
8443 |
+
var external_wc_data_ = __webpack_require__(11);
|
8444 |
+
|
8445 |
+
// EXTERNAL MODULE: ./node_modules/@wordpress/icons/build-module/library/page.js
|
8446 |
+
var page = __webpack_require__(500);
|
8447 |
+
|
8448 |
+
// EXTERNAL MODULE: external ["wp","primitives"]
|
8449 |
+
var external_wp_primitives_ = __webpack_require__(8);
|
8450 |
+
|
8451 |
+
// CONCATENATED MODULE: ./node_modules/@wordpress/icons/build-module/library/comment.js
|
8452 |
+
|
8453 |
+
|
8454 |
+
/**
|
8455 |
+
* WordPress dependencies
|
8456 |
+
*/
|
8457 |
+
|
8458 |
+
var comment = Object(external_wp_element_["createElement"])(external_wp_primitives_["SVG"], {
|
8459 |
+
viewBox: "0 0 24 24",
|
8460 |
+
xmlns: "http://www.w3.org/2000/svg"
|
8461 |
+
}, Object(external_wp_element_["createElement"])(external_wp_primitives_["Path"], {
|
8462 |
+
d: "M18 4H6c-1.1 0-2 .9-2 2v12.9c0 .6.5 1.1 1.1 1.1.3 0 .5-.1.8-.3L8.5 17H18c1.1 0 2-.9 2-2V6c0-1.1-.9-2-2-2zm.5 11c0 .3-.2.5-.5.5H7.9l-2.4 2.4V6c0-.3.2-.5.5-.5h12c.3 0 .5.2.5.5v9z"
|
8463 |
+
}));
|
8464 |
+
/* harmony default export */ var library_comment = (comment);
|
8465 |
+
//# sourceMappingURL=comment.js.map
|
8466 |
+
// EXTERNAL MODULE: ./node_modules/@wordpress/icons/build-module/library/box.js
|
8467 |
+
var box = __webpack_require__(501);
|
8468 |
+
|
8469 |
+
// EXTERNAL MODULE: external ["wp","components"]
|
8470 |
+
var external_wp_components_ = __webpack_require__(3);
|
8471 |
+
|
8472 |
+
// EXTERNAL MODULE: ./client/homescreen/activity-panel/orders/utils.js
|
8473 |
+
var utils = __webpack_require__(68);
|
8474 |
+
|
8475 |
+
// EXTERNAL MODULE: ./client/homescreen/activity-panel/reviews/utils.js
|
8476 |
+
var reviews_utils = __webpack_require__(103);
|
8477 |
+
|
8478 |
+
// EXTERNAL MODULE: ./client/dashboard/utils.js
|
8479 |
+
var dashboard_utils = __webpack_require__(62);
|
8480 |
+
|
8481 |
+
// CONCATENATED MODULE: ./client/header/activity-panel/panels/inbox/icons/bell.js
|
8482 |
+
|
8483 |
+
const Bell = () => Object(external_wp_element_["createElement"])("svg", {
|
8484 |
+
width: "24",
|
8485 |
+
height: "24",
|
8486 |
+
viewBox: "0 0 24 24",
|
8487 |
+
xmlns: "http://www.w3.org/2000/svg"
|
8488 |
+
}, Object(external_wp_element_["createElement"])("path", {
|
8489 |
+
d: "M0 0h24v24H0z",
|
8490 |
+
fill: "none"
|
8491 |
+
}), Object(external_wp_element_["createElement"])("path", {
|
8492 |
+
d: "M12 22c1.1 0 2-.9 2-2h-4c0 1.1.9 2 2 2zm6-6v-5c0-3.07-1.63-5.64-4.5-6.32V4c0-.83-.67-1.5-1.5-1.5s-1.5.67-1.5 1.5v.68C7.64 5.36 6 7.92 6 11v5l-2 2v1h16v-1l-2-2zm-2 1H8v-6c0-2.48 1.51-4.5 4-4.5s4 2.02 4 4.5v6z"
|
8493 |
+
}));
|
8494 |
+
// CONCATENATED MODULE: ./client/header/activity-panel/panels/inbox/abbreviated-notifications-panel.js
|
8495 |
+
|
8496 |
+
|
8497 |
+
/**
|
8498 |
+
* External dependencies
|
8499 |
+
*/
|
8500 |
+
|
8501 |
+
|
8502 |
+
|
8503 |
+
|
8504 |
+
|
8505 |
+
|
8506 |
+
|
8507 |
+
|
8508 |
+
/**
|
8509 |
+
* Internal dependencies
|
8510 |
+
*/
|
8511 |
+
|
8512 |
+
|
8513 |
+
|
8514 |
+
|
8515 |
+
|
8516 |
+
const EXTENDED_TASK_LIST_ID = 'extended_task_list';
|
8517 |
+
const ORDER_PANEL_ID = 'orders-panel';
|
8518 |
+
const REVIEWS_PANEL_ID = 'reviews-panel';
|
8519 |
+
const STOCK_PANEL_ID = 'stock-panel';
|
8520 |
+
const ABBREVIATED_NOTIFICATION_SLOT_NAME = 'AbbreviatedNotification';
|
8521 |
+
const AbbreviatedNotificationsPanel = ({
|
8522 |
+
thingsToDoNextCount
|
8523 |
+
}) => {
|
8524 |
+
const {
|
8525 |
+
ordersToProcessCount,
|
8526 |
+
reviewsToModerateCount,
|
8527 |
+
stockNoticesCount,
|
8528 |
+
isSetupTaskListHidden,
|
8529 |
+
isExtendedTaskListHidden
|
8530 |
+
} = Object(external_wp_data_["useSelect"])(select => {
|
8531 |
+
var _getTaskList, _getTaskList2;
|
8532 |
+
|
8533 |
+
const {
|
8534 |
+
getTaskList
|
8535 |
+
} = select(external_wc_data_["ONBOARDING_STORE_NAME"]);
|
8536 |
+
const orderStatuses = Object(utils["c" /* getOrderStatuses */])(select);
|
8537 |
+
return {
|
8538 |
+
ordersToProcessCount: Object(utils["d" /* getUnreadOrders */])(select, orderStatuses),
|
8539 |
+
reviewsToModerateCount: Object(reviews_utils["b" /* getUnapprovedReviews */])(select),
|
8540 |
+
stockNoticesCount: Object(utils["a" /* getLowStockCount */])(select),
|
8541 |
+
isSetupTaskListHidden: (_getTaskList = getTaskList('setup')) === null || _getTaskList === void 0 ? void 0 : _getTaskList.isHidden,
|
8542 |
+
isExtendedTaskListHidden: (_getTaskList2 = getTaskList('extended')) === null || _getTaskList2 === void 0 ? void 0 : _getTaskList2.isHidden
|
8543 |
+
};
|
8544 |
+
});
|
8545 |
+
|
8546 |
+
const trackAbbreviatedCardClick = name => {
|
8547 |
+
Object(external_wc_tracks_["recordEvent"])('activity_panel_click', {
|
8548 |
+
task: name
|
8549 |
+
});
|
8550 |
+
};
|
8551 |
+
|
8552 |
+
const {
|
8553 |
+
Slot
|
8554 |
+
} = Object(external_wp_components_["createSlotFill"])(ABBREVIATED_NOTIFICATION_SLOT_NAME);
|
8555 |
+
const isWCAdminPage = Object(dashboard_utils["f" /* isWCAdmin */])(window.location.href);
|
8556 |
+
return Object(external_wp_element_["createElement"])("div", {
|
8557 |
+
className: "woocommerce-abbreviated-notifications"
|
8558 |
+
}, thingsToDoNextCount > 0 && !isExtendedTaskListHidden && Object(external_wp_element_["createElement"])(external_wc_components_["AbbreviatedCard"], {
|
8559 |
+
className: "woocommerce-abbreviated-notification",
|
8560 |
+
icon: Object(external_wp_element_["createElement"])(Bell, null),
|
8561 |
+
href: `admin.php?page=wc-admin#${EXTENDED_TASK_LIST_ID}`,
|
8562 |
+
onClick: () => trackAbbreviatedCardClick('thingsToDoNext'),
|
8563 |
+
type: isWCAdminPage ? 'wc-admin' : 'wp-admin'
|
8564 |
+
}, Object(external_wp_element_["createElement"])(external_wc_experimental_["Text"], {
|
8565 |
+
as: "h3"
|
8566 |
+
}, Object(external_wp_i18n_["__"])('Things to do next', 'woocommerce-admin')), Object(external_wp_element_["createElement"])(external_wc_experimental_["Text"], {
|
8567 |
+
as: "p"
|
8568 |
+
}, Object(external_wp_i18n_["sprintf"])(
|
8569 |
+
/* translators: Things the user has to do */
|
8570 |
+
Object(external_wp_i18n_["_n"])('You have %d new thing to do', 'You have %d new things to do', thingsToDoNextCount, 'woocommerce-admin'), thingsToDoNextCount))), ordersToProcessCount > 0 && isSetupTaskListHidden && Object(external_wp_element_["createElement"])(external_wc_components_["AbbreviatedCard"], {
|
8571 |
+
className: "woocommerce-abbreviated-notification",
|
8572 |
+
icon: page["a" /* default */],
|
8573 |
+
href: `admin.php?page=wc-admin&opened_panel=${ORDER_PANEL_ID}`,
|
8574 |
+
onClick: () => trackAbbreviatedCardClick('ordersToProcess'),
|
8575 |
+
type: isWCAdminPage ? 'wc-admin' : 'wp-admin'
|
8576 |
+
}, Object(external_wp_element_["createElement"])(external_wc_experimental_["Text"], {
|
8577 |
+
as: "h3"
|
8578 |
+
}, Object(external_wp_i18n_["__"])('Orders to fulfill', 'woocommerce-admin')), Object(external_wp_element_["createElement"])(external_wc_experimental_["Text"], null, Object(external_wp_i18n_["sprintf"])(
|
8579 |
+
/* translators: Number of orders the user has to fulfill */
|
8580 |
+
Object(external_wp_i18n_["_n"])('You have %d order to fulfill', 'You have %d orders to fulfill', ordersToProcessCount, 'woocommerce-admin'), ordersToProcessCount))), reviewsToModerateCount > 0 && isSetupTaskListHidden && Object(external_wp_element_["createElement"])(external_wc_components_["AbbreviatedCard"], {
|
8581 |
+
className: "woocommerce-abbreviated-notification",
|
8582 |
+
icon: library_comment,
|
8583 |
+
href: `admin.php?page=wc-admin&opened_panel=${REVIEWS_PANEL_ID}`,
|
8584 |
+
onClick: () => trackAbbreviatedCardClick('reviewsToModerate'),
|
8585 |
+
type: isWCAdminPage ? 'wc-admin' : 'wp-admin'
|
8586 |
+
}, Object(external_wp_element_["createElement"])(external_wc_experimental_["Text"], {
|
8587 |
+
as: "h3"
|
8588 |
+
}, Object(external_wp_i18n_["__"])('Reviews to moderate', 'woocommerce-admin')), Object(external_wp_element_["createElement"])(external_wc_experimental_["Text"], null, Object(external_wp_i18n_["sprintf"])(
|
8589 |
+
/* translators: Number of reviews the user has to moderate */
|
8590 |
+
Object(external_wp_i18n_["_n"])('You have %d review to moderate', 'You have %d reviews to moderate', reviewsToModerateCount, 'woocommerce-admin'), reviewsToModerateCount))), stockNoticesCount > 0 && isSetupTaskListHidden && Object(external_wp_element_["createElement"])(external_wc_components_["AbbreviatedCard"], {
|
8591 |
+
className: "woocommerce-abbreviated-notification",
|
8592 |
+
icon: box["a" /* default */],
|
8593 |
+
href: `admin.php?page=wc-admin&opened_panel=${STOCK_PANEL_ID}`,
|
8594 |
+
onClick: () => trackAbbreviatedCardClick('stockNotices'),
|
8595 |
+
type: isWCAdminPage ? 'wc-admin' : 'wp-admin'
|
8596 |
+
}, Object(external_wp_element_["createElement"])(external_wc_experimental_["Text"], {
|
8597 |
+
as: "h3"
|
8598 |
+
}, Object(external_wp_i18n_["__"])('Inventory to review', 'woocommerce-admin')), Object(external_wp_element_["createElement"])(external_wc_experimental_["Text"], null, Object(external_wp_i18n_["__"])('You have inventory to review and update', 'woocommerce-admin'))), !isExtendedTaskListHidden && Object(external_wp_element_["createElement"])(Slot, null));
|
8599 |
+
};
|
8600 |
+
/* harmony default export */ var abbreviated_notifications_panel = (AbbreviatedNotificationsPanel);
|
8601 |
+
|
8602 |
+
/***/ }),
|
8603 |
+
|
8604 |
+
/***/ 256:
|
8605 |
+
/***/ (function(module, __webpack_exports__, __webpack_require__) {
|
8606 |
+
|
8607 |
+
"use strict";
|
8608 |
+
|
8609 |
+
// EXPORTS
|
8610 |
+
__webpack_require__.d(__webpack_exports__, "a", function() { return /* binding */ DEFAULT_ACTIONABLE_STATUSES; });
|
8611 |
+
__webpack_require__.d(__webpack_exports__, "b", function() { return /* binding */ config; });
|
8612 |
+
|
8613 |
+
// UNUSED EXPORTS: DEFAULT_ORDER_STATUSES, DEFAULT_DATE_RANGE
|
8614 |
+
|
8615 |
+
// EXTERNAL MODULE: external ["wp","element"]
|
8616 |
+
var external_wp_element_ = __webpack_require__(0);
|
8617 |
+
|
8618 |
+
// EXTERNAL MODULE: external ["wp","i18n"]
|
8619 |
+
var external_wp_i18n_ = __webpack_require__(2);
|
8620 |
+
|
8621 |
+
// EXTERNAL MODULE: external ["wp","hooks"]
|
8622 |
+
var external_wp_hooks_ = __webpack_require__(31);
|
8623 |
+
|
8624 |
+
// EXTERNAL MODULE: ./node_modules/interpolate-components/lib/index.js
|
8625 |
+
var lib = __webpack_require__(18);
|
8626 |
+
var lib_default = /*#__PURE__*/__webpack_require__.n(lib);
|
8627 |
+
|
8628 |
+
// EXTERNAL MODULE: ./packages/wc-admin-settings/build-module/index.js
|
8629 |
+
var build_module = __webpack_require__(13);
|
8630 |
+
|
8631 |
+
// EXTERNAL MODULE: ./node_modules/qs/lib/index.js
|
8632 |
+
var qs_lib = __webpack_require__(28);
|
8633 |
+
|
8634 |
+
// EXTERNAL MODULE: external ["wc","components"]
|
8635 |
+
var external_wc_components_ = __webpack_require__(21);
|
8636 |
+
|
8637 |
+
// EXTERNAL MODULE: external ["wc","data"]
|
8638 |
+
var external_wc_data_ = __webpack_require__(11);
|
8639 |
+
|
8640 |
+
// EXTERNAL MODULE: external ["wc","date"]
|
8641 |
+
var external_wc_date_ = __webpack_require__(20);
|
8642 |
+
|
8643 |
+
// CONCATENATED MODULE: ./client/analytics/settings/default-date.js
|
8644 |
+
|
8645 |
+
|
8646 |
+
/**
|
8647 |
+
* External dependencies
|
8648 |
+
*/
|
8649 |
+
|
8650 |
+
|
8651 |
+
|
8652 |
+
|
8653 |
+
|
8654 |
+
const DefaultDate = ({
|
8655 |
+
value,
|
8656 |
+
onChange
|
8657 |
+
}) => {
|
8658 |
+
const {
|
8659 |
+
wcAdminSettings
|
8660 |
+
} = Object(external_wc_data_["useSettings"])('wc_admin', ['wcAdminSettings']);
|
8661 |
+
const {
|
8662 |
+
woocommerce_default_date_range: defaultDateRange
|
8663 |
+
} = wcAdminSettings;
|
8664 |
+
|
8665 |
+
const change = query => {
|
8666 |
+
onChange({
|
8667 |
+
target: {
|
8668 |
+
name: 'woocommerce_default_date_range',
|
8669 |
+
value: Object(qs_lib["stringify"])(query)
|
8670 |
+
}
|
8671 |
+
});
|
8672 |
+
};
|
8673 |
+
|
8674 |
+
const query = Object(qs_lib["parse"])(value.replace(/&/g, '&'));
|
8675 |
+
const {
|
8676 |
+
period,
|
8677 |
+
compare,
|
8678 |
+
before,
|
8679 |
+
after
|
8680 |
+
} = Object(external_wc_date_["getDateParamsFromQuery"])(query, defaultDateRange);
|
8681 |
+
const {
|
8682 |
+
primary: primaryDate,
|
8683 |
+
secondary: secondaryDate
|
8684 |
+
} = Object(external_wc_date_["getCurrentDates"])(query, defaultDateRange);
|
8685 |
+
const dateQuery = {
|
8686 |
+
period,
|
8687 |
+
compare,
|
8688 |
+
before,
|
8689 |
+
after,
|
8690 |
+
primaryDate,
|
8691 |
+
secondaryDate
|
8692 |
+
};
|
8693 |
+
return Object(external_wp_element_["createElement"])(external_wc_components_["DateRangeFilterPicker"], {
|
8694 |
+
query: query,
|
8695 |
+
onRangeSelect: change,
|
8696 |
+
dateQuery: dateQuery,
|
8697 |
+
isoDateFormat: external_wc_date_["isoDateFormat"]
|
8698 |
+
});
|
8699 |
+
};
|
8700 |
+
|
8701 |
+
/* harmony default export */ var default_date = (DefaultDate);
|
8702 |
+
// CONCATENATED MODULE: ./client/analytics/settings/config.js
|
8703 |
+
|
8704 |
+
|
8705 |
+
/**
|
8706 |
+
* External dependencies
|
8707 |
+
*/
|
8708 |
+
|
8709 |
+
|
8710 |
+
|
8711 |
+
|
8712 |
+
/**
|
8713 |
+
* Internal dependencies
|
8714 |
+
*/
|
8715 |
+
|
8716 |
+
|
8717 |
+
const SETTINGS_FILTER = 'woocommerce_admin_analytics_settings';
|
8718 |
+
const DEFAULT_ACTIONABLE_STATUSES = ['processing', 'on-hold'];
|
8719 |
+
const DEFAULT_ORDER_STATUSES = ['completed', 'processing', 'refunded', 'cancelled', 'failed', 'pending', 'on-hold'];
|
8720 |
+
const DEFAULT_DATE_RANGE = 'period=month&compare=previous_year';
|
8721 |
+
const filteredOrderStatuses = Object.keys(build_module["c" /* ORDER_STATUSES */]).filter(status => status !== 'refunded').map(key => {
|
8722 |
+
return {
|
8723 |
+
value: key,
|
8724 |
+
label: build_module["c" /* ORDER_STATUSES */][key],
|
8725 |
+
description: Object(external_wp_i18n_["sprintf"])(Object(external_wp_i18n_["__"])('Exclude the %s status from reports', 'woocommerce-admin'), build_module["c" /* ORDER_STATUSES */][key])
|
8726 |
+
};
|
8727 |
+
});
|
8728 |
+
const unregisteredOrderStatuses = Object(build_module["f" /* getSetting */])('unregisteredOrderStatuses', {});
|
8729 |
+
const orderStatusOptions = [{
|
8730 |
+
key: 'defaultStatuses',
|
8731 |
+
options: filteredOrderStatuses.filter(status => DEFAULT_ORDER_STATUSES.includes(status.value))
|
8732 |
+
}, {
|
8733 |
+
key: 'customStatuses',
|
8734 |
+
label: Object(external_wp_i18n_["__"])('Custom Statuses', 'woocommerce-admin'),
|
8735 |
+
options: filteredOrderStatuses.filter(status => !DEFAULT_ORDER_STATUSES.includes(status.value))
|
8736 |
+
}, {
|
8737 |
+
key: 'unregisteredStatuses',
|
8738 |
+
label: Object(external_wp_i18n_["__"])('Unregistered Statuses', 'woocommerce-admin'),
|
8739 |
+
options: Object.keys(unregisteredOrderStatuses).map(key => {
|
8740 |
+
return {
|
8741 |
+
value: key,
|
8742 |
+
label: key,
|
8743 |
+
description: Object(external_wp_i18n_["sprintf"])(Object(external_wp_i18n_["__"])('Exclude the %s status from reports', 'woocommerce-admin'), key)
|
8744 |
+
};
|
8745 |
+
})
|
8746 |
+
}];
|
8747 |
+
const config = Object(external_wp_hooks_["applyFilters"])(SETTINGS_FILTER, {
|
8748 |
+
woocommerce_excluded_report_order_statuses: {
|
8749 |
+
label: Object(external_wp_i18n_["__"])('Excluded statuses:', 'woocommerce-admin'),
|
8750 |
+
inputType: 'checkboxGroup',
|
8751 |
+
options: orderStatusOptions,
|
8752 |
+
helpText: lib_default()({
|
8753 |
+
mixedString: Object(external_wp_i18n_["__"])('Orders with these statuses are excluded from the totals in your reports. ' + 'The {{strong}}Refunded{{/strong}} status can not be excluded.', 'woocommerce-admin'),
|
8754 |
+
components: {
|
8755 |
+
strong: Object(external_wp_element_["createElement"])("strong", null)
|
8756 |
+
}
|
8757 |
+
}),
|
8758 |
+
defaultValue: ['pending', 'cancelled', 'failed']
|
8759 |
+
},
|
8760 |
+
woocommerce_actionable_order_statuses: {
|
8761 |
+
label: Object(external_wp_i18n_["__"])('Actionable statuses:', 'woocommerce-admin'),
|
8762 |
+
inputType: 'checkboxGroup',
|
8763 |
+
options: orderStatusOptions,
|
8764 |
+
helpText: Object(external_wp_i18n_["__"])('Orders with these statuses require action on behalf of the store admin. ' + 'These orders will show up in the Home Screen - Orders task.', 'woocommerce-admin'),
|
8765 |
+
defaultValue: DEFAULT_ACTIONABLE_STATUSES
|
8766 |
+
},
|
8767 |
+
woocommerce_default_date_range: {
|
8768 |
+
name: 'woocommerce_default_date_range',
|
8769 |
+
label: Object(external_wp_i18n_["__"])('Default date range:', 'woocommerce-admin'),
|
8770 |
+
inputType: 'component',
|
8771 |
+
component: default_date,
|
8772 |
+
helpText: Object(external_wp_i18n_["__"])('Select a default date range. When no range is selected, reports will be viewed by ' + 'the default date range.', 'woocommerce-admin'),
|
8773 |
+
defaultValue: DEFAULT_DATE_RANGE
|
8774 |
+
}
|
8775 |
+
});
|
8776 |
+
|
8777 |
+
/***/ }),
|
8778 |
+
|
8779 |
+
/***/ 257:
|
8780 |
+
/***/ (function(module, __webpack_exports__, __webpack_require__) {
|
8781 |
+
|
8782 |
+
"use strict";
|
8783 |
+
/* WEBPACK VAR INJECTION */(function(process) {/* harmony import */ var _wordpress_element__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(0);
|
8784 |
+
/* harmony import */ var _wordpress_element__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(_wordpress_element__WEBPACK_IMPORTED_MODULE_0__);
|
8785 |
+
/* harmony import */ var lodash__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(4);
|
8786 |
+
/* harmony import */ var lodash__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(lodash__WEBPACK_IMPORTED_MODULE_1__);
|
8787 |
+
/* harmony import */ var classnames__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(6);
|
8788 |
+
/* harmony import */ var classnames__WEBPACK_IMPORTED_MODULE_2___default = /*#__PURE__*/__webpack_require__.n(classnames__WEBPACK_IMPORTED_MODULE_2__);
|
8789 |
+
/* harmony import */ var _wordpress_a11y__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(258);
|
8790 |
+
/* harmony import */ var _wordpress_a11y__WEBPACK_IMPORTED_MODULE_3___default = /*#__PURE__*/__webpack_require__.n(_wordpress_a11y__WEBPACK_IMPORTED_MODULE_3__);
|
8791 |
+
/* harmony import */ var _wordpress_i18n__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(2);
|
8792 |
+
/* harmony import */ var _wordpress_i18n__WEBPACK_IMPORTED_MODULE_4___default = /*#__PURE__*/__webpack_require__.n(_wordpress_i18n__WEBPACK_IMPORTED_MODULE_4__);
|
8793 |
+
/* harmony import */ var _wordpress_warning__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(259);
|
8794 |
+
/* harmony import */ var _wordpress_warning__WEBPACK_IMPORTED_MODULE_5___default = /*#__PURE__*/__webpack_require__.n(_wordpress_warning__WEBPACK_IMPORTED_MODULE_5__);
|
8795 |
+
/* harmony import */ var _wordpress_components__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(3);
|
8796 |
+
/* harmony import */ var _wordpress_components__WEBPACK_IMPORTED_MODULE_6___default = /*#__PURE__*/__webpack_require__.n(_wordpress_components__WEBPACK_IMPORTED_MODULE_6__);
|
8797 |
+
|
8798 |
+
|
8799 |
+
/**
|
8800 |
+
* External dependencies
|
8801 |
+
*/
|
8802 |
+
|
8803 |
+
|
8804 |
+
|
8805 |
+
|
8806 |
+
|
8807 |
+
|
8808 |
+
|
8809 |
+
const NOTICE_TIMEOUT = 10000;
|
8810 |
+
/** @typedef {import('@wordpress/element').WPElement} WPElement */
|
8811 |
+
|
8812 |
+
/**
|
8813 |
+
* Custom hook which announces the message with the given politeness, if a
|
8814 |
+
* valid message is provided.
|
8815 |
+
*
|
8816 |
+
* @param {string|WPElement} [message] Message to announce.
|
8817 |
+
* @param {'polite'|'assertive'} politeness Politeness to announce.
|
8818 |
+
*/
|
8819 |
+
|
8820 |
+
function useSpokenMessage(message, politeness) {
|
8821 |
+
const spokenMessage = typeof message === 'string' ? message : Object(_wordpress_element__WEBPACK_IMPORTED_MODULE_0__["renderToString"])(message);
|
8822 |
+
Object(_wordpress_element__WEBPACK_IMPORTED_MODULE_0__["useEffect"])(() => {
|
8823 |
+
if (spokenMessage) {
|
8824 |
+
Object(_wordpress_a11y__WEBPACK_IMPORTED_MODULE_3__["speak"])(spokenMessage, politeness);
|
8825 |
+
}
|
8826 |
+
}, [spokenMessage, politeness]);
|
8827 |
+
}
|
8828 |
+
|
8829 |
+
function Snackbar({
|
8830 |
+
className,
|
8831 |
+
children,
|
8832 |
+
spokenMessage = children,
|
8833 |
+
politeness = 'polite',
|
8834 |
+
actions = [],
|
8835 |
+
onRemove = lodash__WEBPACK_IMPORTED_MODULE_1__["noop"],
|
8836 |
+
icon = null,
|
8837 |
+
explicitDismiss = false,
|
8838 |
+
// onDismiss is a callback executed when the snackbar is dismissed.
|
8839 |
+
// It is distinct from onRemove, which _looks_ like a callback but is
|
8840 |
+
// actually the function to call to remove the snackbar from the UI.
|
8841 |
+
onDismiss = null
|
8842 |
+
}, ref) {
|
8843 |
+
onDismiss = onDismiss || lodash__WEBPACK_IMPORTED_MODULE_1__["noop"];
|
8844 |
+
|
8845 |
+
function dismissMe(event) {
|
8846 |
+
if (event && event.preventDefault) {
|
8847 |
+
event.preventDefault();
|
8848 |
+
}
|
8849 |
+
|
8850 |
+
onDismiss();
|
8851 |
+
onRemove();
|
8852 |
+
}
|
8853 |
+
|
8854 |
+
function onActionClick(event, onClick) {
|
8855 |
+
event.stopPropagation();
|
8856 |
+
onRemove();
|
8857 |
+
|
8858 |
+
if (onClick) {
|
8859 |
+
onClick(event);
|
8860 |
+
}
|
8861 |
+
}
|
8862 |
+
|
8863 |
+
useSpokenMessage(spokenMessage, politeness); // Only set up the timeout dismiss if we're not explicitly dismissing.
|
8864 |
+
|
8865 |
+
Object(_wordpress_element__WEBPACK_IMPORTED_MODULE_0__["useEffect"])(() => {
|
8866 |
+
const timeoutHandle = setTimeout(() => {
|
8867 |
+
if (!explicitDismiss) {
|
8868 |
+
onDismiss();
|
8869 |
+
onRemove();
|
8870 |
+
}
|
8871 |
+
}, NOTICE_TIMEOUT);
|
8872 |
+
return () => clearTimeout(timeoutHandle);
|
8873 |
+
}, [explicitDismiss, onDismiss, onRemove]);
|
8874 |
+
const classes = classnames__WEBPACK_IMPORTED_MODULE_2___default()(className, 'components-snackbar', {
|
8875 |
+
'components-snackbar-explicit-dismiss': !!explicitDismiss
|
8876 |
+
});
|
8877 |
+
|
8878 |
+
if (actions && actions.length > 1) {
|
8879 |
+
// we need to inform developers that snackbar only accepts 1 action
|
8880 |
+
typeof process !== "undefined" && process.env && "production" !== "production" ? _wordpress_warning__WEBPACK_IMPORTED_MODULE_5___default()('Snackbar can only have 1 action, use Notice if your message require many messages') : void 0; // return first element only while keeping it inside an array
|
8881 |
+
|
8882 |
+
actions = [actions[0]];
|
8883 |
+
}
|
8884 |
+
|
8885 |
+
const snackbarContentClassnames = classnames__WEBPACK_IMPORTED_MODULE_2___default()('components-snackbar__content', {
|
8886 |
+
'components-snackbar__content-with-icon': !!icon
|
8887 |
+
});
|
8888 |
+
return Object(_wordpress_element__WEBPACK_IMPORTED_MODULE_0__["createElement"])("div", {
|
8889 |
+
ref: ref,
|
8890 |
+
className: classes,
|
8891 |
+
onClick: !explicitDismiss ? dismissMe : lodash__WEBPACK_IMPORTED_MODULE_1__["noop"],
|
8892 |
+
tabIndex: "0",
|
8893 |
+
role: !explicitDismiss ? 'button' : '',
|
8894 |
+
onKeyPress: !explicitDismiss ? dismissMe : lodash__WEBPACK_IMPORTED_MODULE_1__["noop"],
|
8895 |
+
"aria-label": !explicitDismiss ? Object(_wordpress_i18n__WEBPACK_IMPORTED_MODULE_4__["__"])('Dismiss this notice') : ''
|
8896 |
+
}, Object(_wordpress_element__WEBPACK_IMPORTED_MODULE_0__["createElement"])("div", {
|
8897 |
+
className: snackbarContentClassnames
|
8898 |
+
}, icon && Object(_wordpress_element__WEBPACK_IMPORTED_MODULE_0__["createElement"])("div", {
|
8899 |
+
className: "components-snackbar__icon"
|
8900 |
+
}, icon), children, actions.map(({
|
8901 |
+
label,
|
8902 |
+
onClick,
|
8903 |
+
url
|
8904 |
+
}, index) => {
|
8905 |
+
return Object(_wordpress_element__WEBPACK_IMPORTED_MODULE_0__["createElement"])(_wordpress_components__WEBPACK_IMPORTED_MODULE_6__["Button"], {
|
8906 |
+
key: index,
|
8907 |
+
href: url,
|
8908 |
+
isTertiary: true,
|
8909 |
+
onClick: event => onActionClick(event, onClick),
|
8910 |
+
className: "components-snackbar__action"
|
8911 |
+
}, label);
|
8912 |
+
}), explicitDismiss && Object(_wordpress_element__WEBPACK_IMPORTED_MODULE_0__["createElement"])("span", {
|
8913 |
+
role: "button",
|
8914 |
+
"aria-label": "Dismiss this notice",
|
8915 |
+
tabIndex: "0",
|
8916 |
+
className: "components-snackbar__dismiss-button",
|
8917 |
+
onClick: dismissMe,
|
8918 |
+
onKeyPress: dismissMe
|
8919 |
+
}, "\u2715")));
|
8920 |
+
}
|
8921 |
+
|
8922 |
+
/* harmony default export */ __webpack_exports__["a"] = (Object(_wordpress_element__WEBPACK_IMPORTED_MODULE_0__["forwardRef"])(Snackbar));
|
8923 |
+
/* WEBPACK VAR INJECTION */}.call(this, __webpack_require__(128)))
|
8924 |
+
|
8925 |
+
/***/ }),
|
8926 |
+
|
8927 |
+
/***/ 258:
|
8928 |
+
/***/ (function(module, exports) {
|
8929 |
+
|
8930 |
+
(function() { module.exports = window["wp"]["a11y"]; }());
|
8931 |
+
|
8932 |
+
/***/ }),
|
8933 |
+
|
8934 |
+
/***/ 259:
|
8935 |
+
/***/ (function(module, exports) {
|
8936 |
+
|
8937 |
+
(function() { module.exports = window["wp"]["warning"]; }());
|
8938 |
+
|
8939 |
+
/***/ }),
|
8940 |
+
|
8941 |
+
/***/ 260:
|
8942 |
+
/***/ (function(module, exports) {
|
8943 |
+
|
8944 |
+
(function() { module.exports = window["wc"]["customerEffortScore"]; }());
|
8945 |
+
|
8946 |
+
/***/ }),
|
8947 |
+
|
8948 |
+
/***/ 27:
|
8949 |
+
/***/ (function(module, exports) {
|
8950 |
+
|
8951 |
+
(function() { module.exports = window["wp"]["keycodes"]; }());
|
8952 |
+
|
8953 |
+
/***/ }),
|
8954 |
+
|
8955 |
+
/***/ 271:
|
8956 |
+
/***/ (function(module, __webpack_exports__, __webpack_require__) {
|
8957 |
+
|
8958 |
+
"use strict";
|
8959 |
+
|
8960 |
+
// EXPORTS
|
8961 |
+
__webpack_require__.d(__webpack_exports__, "a", function() { return /* reexport */ customer_effort_score_tracks_container; });
|
8962 |
+
|
8963 |
+
// UNUSED EXPORTS: CustomerEffortScoreTracks
|
8964 |
+
|
8965 |
+
// NAMESPACE OBJECT: ./client/customer-effort-score-tracks/data/actions.js
|
8966 |
+
var actions_namespaceObject = {};
|
8967 |
+
__webpack_require__.r(actions_namespaceObject);
|
8968 |
+
__webpack_require__.d(actions_namespaceObject, "setCesSurveyQueue", function() { return setCesSurveyQueue; });
|
8969 |
+
__webpack_require__.d(actions_namespaceObject, "addCesSurvey", function() { return addCesSurvey; });
|
8970 |
+
__webpack_require__.d(actions_namespaceObject, "addCesSurveyForAnalytics", function() { return addCesSurveyForAnalytics; });
|
8971 |
+
__webpack_require__.d(actions_namespaceObject, "addCesSurveyForCustomerSearch", function() { return addCesSurveyForCustomerSearch; });
|
8972 |
+
|
8973 |
+
// NAMESPACE OBJECT: ./client/customer-effort-score-tracks/data/resolvers.js
|
8974 |
+
var resolvers_namespaceObject = {};
|
8975 |
+
__webpack_require__.r(resolvers_namespaceObject);
|
8976 |
+
__webpack_require__.d(resolvers_namespaceObject, "getCesSurveyQueue", function() { return resolvers_getCesSurveyQueue; });
|
8977 |
+
|
8978 |
+
// NAMESPACE OBJECT: ./client/customer-effort-score-tracks/data/selectors.js
|
8979 |
+
var selectors_namespaceObject = {};
|
8980 |
+
__webpack_require__.r(selectors_namespaceObject);
|
8981 |
+
__webpack_require__.d(selectors_namespaceObject, "getCesSurveyQueue", function() { return selectors_getCesSurveyQueue; });
|
8982 |
+
|
8983 |
+
// EXTERNAL MODULE: external ["wp","element"]
|
8984 |
+
var external_wp_element_ = __webpack_require__(0);
|
8985 |
+
|
8986 |
+
// EXTERNAL MODULE: ./node_modules/prop-types/index.js
|
8987 |
+
var prop_types = __webpack_require__(1);
|
8988 |
+
var prop_types_default = /*#__PURE__*/__webpack_require__.n(prop_types);
|
8989 |
+
|
8990 |
+
// EXTERNAL MODULE: external ["wc","tracks"]
|
8991 |
+
var external_wc_tracks_ = __webpack_require__(15);
|
8992 |
+
|
8993 |
+
// EXTERNAL MODULE: external ["wc","customerEffortScore"]
|
8994 |
+
var external_wc_customerEffortScore_ = __webpack_require__(260);
|
8995 |
+
var external_wc_customerEffortScore_default = /*#__PURE__*/__webpack_require__.n(external_wc_customerEffortScore_);
|
8996 |
+
|
8997 |
+
// EXTERNAL MODULE: external ["wp","compose"]
|
8998 |
+
var external_wp_compose_ = __webpack_require__(14);
|
8999 |
+
|
9000 |
+
// EXTERNAL MODULE: external ["wp","data"]
|
9001 |
+
var external_wp_data_ = __webpack_require__(7);
|
9002 |
+
|
9003 |
+
// EXTERNAL MODULE: external ["wc","data"]
|
9004 |
+
var external_wc_data_ = __webpack_require__(11);
|
9005 |
+
|
9006 |
+
// EXTERNAL MODULE: external ["wp","i18n"]
|
9007 |
+
var external_wp_i18n_ = __webpack_require__(2);
|
9008 |
+
|
9009 |
+
// CONCATENATED MODULE: ./client/customer-effort-score-tracks/customer-effort-score-tracks.js
|
9010 |
+
|
9011 |
+
|
9012 |
+
/**
|
9013 |
+
* External dependencies
|
9014 |
+
*/
|
9015 |
+
|
9016 |
+
|
9017 |
+
|
9018 |
+
|
9019 |
+
|
9020 |
+
|
9021 |
+
|
9022 |
+
|
9023 |
+
const SHOWN_FOR_ACTIONS_OPTION_NAME = 'woocommerce_ces_shown_for_actions';
|
9024 |
+
const ADMIN_INSTALL_TIMESTAMP_OPTION_NAME = 'woocommerce_admin_install_timestamp';
|
9025 |
+
const ALLOW_TRACKING_OPTION_NAME = 'woocommerce_allow_tracking';
|
9026 |
+
/**
|
9027 |
+
* A CustomerEffortScore wrapper that uses tracks to track the selected
|
9028 |
+
* customer effort score.
|
9029 |
+
*
|
9030 |
+
* @param {Object} props Component props.
|
9031 |
+
* @param {string} props.action The action name sent to Tracks.
|
9032 |
+
* @param {Object} props.trackProps Additional props sent to Tracks.
|
9033 |
+
* @param {string} props.label The label displayed in the modal.
|
9034 |
+
* @param {string} props.onSubmitLabel The label displayed upon survey submission.
|
9035 |
+
* @param {Array} props.cesShownForActions The array of actions that the CES modal has been shown for.
|
9036 |
+
* @param {boolean} props.allowTracking Whether tracking is allowed or not.
|
9037 |
+
* @param {boolean} props.resolving Are values still being resolved.
|
9038 |
+
* @param {number} props.storeAgeInWeeks The age of the store in weeks.
|
9039 |
+
* @param {Function} props.updateOptions Function to update options.
|
9040 |
+
* @param {Function} props.createNotice Function to create a snackbar.
|
9041 |
+
*/
|
9042 |
+
|
9043 |
+
function CustomerEffortScoreTracks({
|
9044 |
+
action,
|
9045 |
+
trackProps,
|
9046 |
+
label,
|
9047 |
+
onSubmitLabel = Object(external_wp_i18n_["__"])('Thank you for your feedback!', 'woocommerce-admin'),
|
9048 |
+
cesShownForActions,
|
9049 |
+
allowTracking,
|
9050 |
+
resolving,
|
9051 |
+
storeAgeInWeeks,
|
9052 |
+
updateOptions,
|
9053 |
+
createNotice
|
9054 |
+
}) {
|
9055 |
+
const [modalShown, setModalShown] = Object(external_wp_element_["useState"])(false);
|
9056 |
+
|
9057 |
+
if (resolving) {
|
9058 |
+
return null;
|
9059 |
+
} // Don't show if tracking is disallowed.
|
9060 |
+
|
9061 |
+
|
9062 |
+
if (!allowTracking) {
|
9063 |
+
return null;
|
9064 |
+
} // We only want to return null early if the modal was already shown
|
9065 |
+
// for this action *before* this component was initially instantiated.
|
9066 |
+
//
|
9067 |
+
// We want to make sure we still render CustomerEffortScore below
|
9068 |
+
// (we don't want to return null early), if the modal was shown for this
|
9069 |
+
// instantiation, so that the component doesn't go away while we are
|
9070 |
+
// still showing it.
|
9071 |
+
|
9072 |
+
|
9073 |
+
if (cesShownForActions.indexOf(action) !== -1 && !modalShown) {
|
9074 |
+
return null;
|
9075 |
+
}
|
9076 |
+
|
9077 |
+
const onNoticeShown = () => {
|
9078 |
+
Object(external_wc_tracks_["recordEvent"])('ces_snackbar_view', {
|
9079 |
+
action,
|
9080 |
+
store_age: storeAgeInWeeks,
|
9081 |
+
...trackProps
|
9082 |
+
});
|
9083 |
+
};
|
9084 |
+
|
9085 |
+
const addActionToShownOption = () => {
|
9086 |
+
updateOptions({
|
9087 |
+
[SHOWN_FOR_ACTIONS_OPTION_NAME]: [action, ...cesShownForActions]
|
9088 |
+
});
|
9089 |
+
};
|
9090 |
+
|
9091 |
+
const onNoticeDismissed = () => {
|
9092 |
+
Object(external_wc_tracks_["recordEvent"])('ces_snackbar_dismiss', {
|
9093 |
+
action,
|
9094 |
+
store_age: storeAgeInWeeks,
|
9095 |
+
...trackProps
|
9096 |
+
});
|
9097 |
+
addActionToShownOption();
|
9098 |
+
};
|
9099 |
+
|
9100 |
+
const onModalShown = () => {
|
9101 |
+
setModalShown(true);
|
9102 |
+
Object(external_wc_tracks_["recordEvent"])('ces_view', {
|
9103 |
+
action,
|
9104 |
+
store_age: storeAgeInWeeks,
|
9105 |
+
...trackProps
|
9106 |
+
});
|
9107 |
+
addActionToShownOption();
|
9108 |
+
};
|
9109 |
+
|
9110 |
+
const recordScore = (score, comments) => {
|
9111 |
+
Object(external_wc_tracks_["recordEvent"])('ces_feedback', {
|
9112 |
+
action,
|
9113 |
+
score,
|
9114 |
+
comments: comments || '',
|
9115 |
+
store_age: storeAgeInWeeks,
|
9116 |
+
...trackProps
|
9117 |
+
});
|
9118 |
+
createNotice('success', onSubmitLabel);
|
9119 |
+
};
|
9120 |
+
|
9121 |
+
return Object(external_wp_element_["createElement"])(external_wc_customerEffortScore_default.a, {
|
9122 |
+
recordScoreCallback: recordScore,
|
9123 |
+
label: label,
|
9124 |
+
onNoticeShownCallback: onNoticeShown,
|
9125 |
+
onNoticeDismissedCallback: onNoticeDismissed,
|
9126 |
+
onModalShownCallback: onModalShown,
|
9127 |
+
icon: Object(external_wp_element_["createElement"])("span", {
|
9128 |
+
style: {
|
9129 |
+
height: 21,
|
9130 |
+
width: 21
|
9131 |
+
},
|
9132 |
+
role: "img",
|
9133 |
+
"aria-label": Object(external_wp_i18n_["__"])('Pencil icon', 'woocommerce-admin')
|
9134 |
+
}, "\u270F\uFE0F")
|
9135 |
+
});
|
9136 |
+
}
|
9137 |
+
|
9138 |
+
CustomerEffortScoreTracks.propTypes = {
|
9139 |
+
/**
|
9140 |
+
* The action name sent to Tracks.
|
9141 |
+
*/
|
9142 |
+
action: prop_types_default.a.string.isRequired,
|
9143 |
+
|
9144 |
+
/**
|
9145 |
+
* Additional props sent to Tracks.
|
9146 |
+
*/
|
9147 |
+
trackProps: prop_types_default.a.object,
|
9148 |
+
|
9149 |
+
/**
|
9150 |
+
* The label displayed in the modal.
|
9151 |
+
*/
|
9152 |
+
label: prop_types_default.a.string.isRequired,
|
9153 |
+
|
9154 |
+
/**
|
9155 |
+
* The label for the snackbar that appears upon survey submission.
|
9156 |
+
*/
|
9157 |
+
onSubmitLabel: prop_types_default.a.string,
|
9158 |
+
|
9159 |
+
/**
|
9160 |
+
* The array of actions that the CES modal has been shown for.
|
9161 |
+
*/
|
9162 |
+
cesShownForActions: prop_types_default.a.arrayOf(prop_types_default.a.string).isRequired,
|
9163 |
+
|
9164 |
+
/**
|
9165 |
+
* Whether tracking is allowed or not.
|
9166 |
+
*/
|
9167 |
+
allowTracking: prop_types_default.a.bool,
|
9168 |
+
|
9169 |
+
/**
|
9170 |
+
* Whether props are still being resolved.
|
9171 |
+
*/
|
9172 |
+
resolving: prop_types_default.a.bool.isRequired,
|
9173 |
+
|
9174 |
+
/**
|
9175 |
+
* The age of the store in weeks.
|
9176 |
+
*/
|
9177 |
+
storeAgeInWeeks: prop_types_default.a.number,
|
9178 |
+
|
9179 |
+
/**
|
9180 |
+
* Function to update options.
|
9181 |
+
*/
|
9182 |
+
updateOptions: prop_types_default.a.func,
|
9183 |
+
|
9184 |
+
/**
|
9185 |
+
* Function to create a snackbar
|
9186 |
+
*/
|
9187 |
+
createNotice: prop_types_default.a.func
|
9188 |
+
};
|
9189 |
+
|
9190 |
+
function getStoreAgeInWeeks(adminInstallTimestamp) {
|
9191 |
+
if (adminInstallTimestamp === 0) {
|
9192 |
+
return null;
|
9193 |
+
} // Date.now() is ms since Unix epoch, adminInstallTimestamp is in
|
9194 |
+
// seconds since Unix epoch.
|
9195 |
+
|
9196 |
+
|
9197 |
+
const storeAgeInMs = Date.now() - adminInstallTimestamp * 1000;
|
9198 |
+
const storeAgeInWeeks = Math.round(storeAgeInMs / external_wc_data_["WEEK"]);
|
9199 |
+
return storeAgeInWeeks;
|
9200 |
+
}
|
9201 |
+
|
9202 |
+
/* harmony default export */ var customer_effort_score_tracks = (Object(external_wp_compose_["compose"])(Object(external_wp_data_["withSelect"])(select => {
|
9203 |
+
const {
|
9204 |
+
getOption,
|
9205 |
+
isResolving
|
9206 |
+
} = select(external_wc_data_["OPTIONS_STORE_NAME"]);
|
9207 |
+
const cesShownForActions = getOption(SHOWN_FOR_ACTIONS_OPTION_NAME) || [];
|
9208 |
+
const adminInstallTimestamp = getOption(ADMIN_INSTALL_TIMESTAMP_OPTION_NAME) || 0;
|
9209 |
+
const storeAgeInWeeks = getStoreAgeInWeeks(adminInstallTimestamp);
|
9210 |
+
const allowTrackingOption = getOption(ALLOW_TRACKING_OPTION_NAME) || 'no';
|
9211 |
+
const allowTracking = allowTrackingOption === 'yes';
|
9212 |
+
const resolving = isResolving('getOption', [SHOWN_FOR_ACTIONS_OPTION_NAME]) || storeAgeInWeeks === null || isResolving('getOption', [ADMIN_INSTALL_TIMESTAMP_OPTION_NAME]) || isResolving('getOption', [ALLOW_TRACKING_OPTION_NAME]);
|
9213 |
+
return {
|
9214 |
+
cesShownForActions,
|
9215 |
+
allowTracking,
|
9216 |
+
storeAgeInWeeks,
|
9217 |
+
resolving
|
9218 |
+
};
|
9219 |
+
}), Object(external_wp_data_["withDispatch"])(dispatch => {
|
9220 |
+
const {
|
9221 |
+
updateOptions
|
9222 |
+
} = dispatch(external_wc_data_["OPTIONS_STORE_NAME"]);
|
9223 |
+
const {
|
9224 |
+
createNotice
|
9225 |
+
} = dispatch('core/notices');
|
9226 |
+
return {
|
9227 |
+
updateOptions,
|
9228 |
+
createNotice
|
9229 |
+
};
|
9230 |
+
}))(CustomerEffortScoreTracks));
|
9231 |
+
// EXTERNAL MODULE: ./client/customer-effort-score-tracks/data/constants.js
|
9232 |
+
var constants = __webpack_require__(55);
|
9233 |
+
|
9234 |
+
// EXTERNAL MODULE: external ["wp","dataControls"]
|
9235 |
+
var external_wp_dataControls_ = __webpack_require__(10);
|
9236 |
+
|
9237 |
+
// CONCATENATED MODULE: ./client/customer-effort-score-tracks/data/action-types.js
|
9238 |
+
const TYPES = {
|
9239 |
+
SET_CES_SURVEY_QUEUE: 'SET_CES_SURVEY_QUEUE',
|
9240 |
+
ADD_CES_SURVEY: 'ADD_CES_SURVEY'
|
9241 |
+
};
|
9242 |
+
/* harmony default export */ var action_types = (TYPES);
|
9243 |
+
// CONCATENATED MODULE: ./client/customer-effort-score-tracks/data/actions.js
|
9244 |
+
/**
|
9245 |
+
* External dependencies
|
9246 |
+
*/
|
9247 |
+
|
9248 |
+
/**
|
9249 |
+
* Internal dependencies
|
9250 |
+
*/
|
9251 |
+
|
9252 |
+
|
9253 |
+
/**
|
9254 |
+
* Initialize the state
|
9255 |
+
*
|
9256 |
+
* @param {Object} queue initial queue
|
9257 |
+
*/
|
9258 |
+
|
9259 |
+
function setCesSurveyQueue(queue) {
|
9260 |
+
return {
|
9261 |
+
type: action_types.SET_CES_SURVEY_QUEUE,
|
9262 |
+
queue
|
9263 |
+
};
|
9264 |
+
}
|
9265 |
+
/**
|
9266 |
+
* Add a new CES track to the state.
|
9267 |
+
*
|
9268 |
+
* @param {string} action action name for the survey
|
9269 |
+
* @param {string} label label for the snackback
|
9270 |
+
* @param {string} pageNow value of window.pagenow
|
9271 |
+
* @param {string} adminPage value of window.adminpage
|
9272 |
+
* @param {string} onsubmit_label label for the snackback onsubmit
|
9273 |
+
* @param {Object} props object for optional props
|
9274 |
+
*/
|
9275 |
+
|
9276 |
+
function addCesSurvey(action, label, pageNow = window.pagenow, adminPage = window.adminpage, onsubmit_label = undefined, props = {}) {
|
9277 |
+
return {
|
9278 |
+
type: action_types.ADD_CES_SURVEY,
|
9279 |
+
action,
|
9280 |
+
label,
|
9281 |
+
pageNow,
|
9282 |
+
adminPage,
|
9283 |
+
onsubmit_label,
|
9284 |
+
props
|
9285 |
+
};
|
9286 |
+
}
|
9287 |
+
/**
|
9288 |
+
* Add a new CES survey track for the pages in Analytics menu
|
9289 |
+
*/
|
9290 |
+
|
9291 |
+
function addCesSurveyForAnalytics() {
|
9292 |
+
return addCesSurvey('analytics_filtered', Object(external_wp_i18n_["__"])('How easy was it to filter your store analytics?', 'woocommerce-admin'), 'woocommerce_page_wc-admin', 'woocommerce_page_wc-admin');
|
9293 |
+
}
|
9294 |
+
/**
|
9295 |
+
* Add a new CES survey track on searching customers.
|
9296 |
+
*/
|
9297 |
+
|
9298 |
+
function addCesSurveyForCustomerSearch() {
|
9299 |
+
return addCesSurvey('ces_search', Object(external_wp_i18n_["__"])('How easy was it to use search?', 'woocommerce-admin'), 'woocommerce_page_wc-admin', 'woocommerce_page_wc-admin', undefined, {
|
9300 |
+
search_area: 'customer'
|
9301 |
+
});
|
9302 |
+
}
|
9303 |
+
// CONCATENATED MODULE: ./client/customer-effort-score-tracks/data/resolvers.js
|
9304 |
+
/**
|
9305 |
+
* External dependencies
|
9306 |
+
*/
|
9307 |
+
|
9308 |
+
/**
|
9309 |
+
* Internal dependencies
|
9310 |
+
*/
|
9311 |
+
|
9312 |
+
|
9313 |
+
|
9314 |
+
function* resolvers_getCesSurveyQueue() {
|
9315 |
+
const response = yield Object(external_wp_dataControls_["apiFetch"])({
|
9316 |
+
path: `${constants["a" /* API_NAMESPACE */]}/options?options=${constants["b" /* QUEUE_OPTION_NAME */]}`
|
9317 |
+
});
|
9318 |
+
|
9319 |
+
if (response) {
|
9320 |
+
yield setCesSurveyQueue(response[constants["b" /* QUEUE_OPTION_NAME */]] || []);
|
9321 |
+
} else {
|
9322 |
+
throw new Error();
|
9323 |
+
}
|
9324 |
+
}
|
9325 |
+
// CONCATENATED MODULE: ./client/customer-effort-score-tracks/data/selectors.js
|
9326 |
+
function selectors_getCesSurveyQueue(state) {
|
9327 |
+
return state.queue;
|
9328 |
+
}
|
9329 |
+
// CONCATENATED MODULE: ./client/customer-effort-score-tracks/data/reducer.js
|
9330 |
+
/**
|
9331 |
+
* Internal dependencies
|
9332 |
+
*/
|
9333 |
+
|
9334 |
+
const DEFAULT_STATE = {
|
9335 |
+
queue: []
|
9336 |
+
};
|
9337 |
+
|
9338 |
+
const reducer = (state = DEFAULT_STATE, action) => {
|
9339 |
+
switch (action.type) {
|
9340 |
+
case action_types.SET_CES_SURVEY_QUEUE:
|
9341 |
+
return { ...state,
|
9342 |
+
queue: action.queue
|
9343 |
+
};
|
9344 |
+
|
9345 |
+
case action_types.ADD_CES_SURVEY:
|
9346 |
+
// Prevent duplicate
|
9347 |
+
const hasDuplicate = state.queue.filter(track => track.action === action.action);
|
9348 |
+
|
9349 |
+
if (hasDuplicate.length) {
|
9350 |
+
return state;
|
9351 |
+
}
|
9352 |
+
|
9353 |
+
const newTrack = {
|
9354 |
+
action: action.action,
|
9355 |
+
label: action.label,
|
9356 |
+
pagenow: action.pageNow,
|
9357 |
+
adminpage: action.adminPage,
|
9358 |
+
onSubmitLabel: action.onSubmitLabel,
|
9359 |
+
props: action.props
|
9360 |
+
};
|
9361 |
+
return { ...state,
|
9362 |
+
queue: [...state.queue, newTrack]
|
9363 |
+
};
|
9364 |
+
|
9365 |
+
default:
|
9366 |
+
return state;
|
9367 |
+
}
|
9368 |
+
};
|
9369 |
+
|
9370 |
+
/* harmony default export */ var data_reducer = (reducer);
|
9371 |
+
// CONCATENATED MODULE: ./client/customer-effort-score-tracks/data/index.js
|
9372 |
+
/**
|
9373 |
+
* External dependencies
|
9374 |
+
*/
|
9375 |
+
|
9376 |
+
|
9377 |
+
/**
|
9378 |
+
* Internal dependencies
|
9379 |
+
*/
|
9380 |
+
|
9381 |
+
|
9382 |
+
|
9383 |
+
|
9384 |
+
|
9385 |
+
|
9386 |
+
/* harmony default export */ var data = (Object(external_wp_data_["registerStore"])(constants["c" /* STORE_KEY */], {
|
9387 |
+
actions: actions_namespaceObject,
|
9388 |
+
selectors: selectors_namespaceObject,
|
9389 |
+
resolvers: resolvers_namespaceObject,
|
9390 |
+
controls: external_wp_dataControls_["controls"],
|
9391 |
+
reducer: data_reducer
|
9392 |
+
}));
|
9393 |
+
// CONCATENATED MODULE: ./client/customer-effort-score-tracks/customer-effort-score-tracks-container.js
|
9394 |
+
|
9395 |
+
|
9396 |
+
/**
|
9397 |
+
* External dependencies
|
9398 |
+
*/
|
9399 |
+
|
9400 |
+
|
9401 |
+
|
9402 |
+
|
9403 |
+
/**
|
9404 |
+
* Internal dependencies
|
9405 |
+
*/
|
9406 |
+
|
9407 |
+
|
9408 |
+
|
9409 |
+
|
9410 |
+
/**
|
9411 |
+
* Maps the queue of CES tracks surveys to CustomerEffortScoreTracks
|
9412 |
+
* components. Note that generally there will only be a single survey per page
|
9413 |
+
* however this is designed to be flexible if multiple surveys per page are
|
9414 |
+
* added in the future.
|
9415 |
+
*
|
9416 |
+
* @param {Object} props Component props.
|
9417 |
+
* @param {Array} props.queue The queue of surveys.
|
9418 |
+
* @param {boolean} props.resolving Whether the queue is resolving.
|
9419 |
+
* @param {Function} props.clearQueue Sets up clearing of the queue on the next page load.
|
9420 |
+
*/
|
9421 |
+
|
9422 |
+
function CustomerEffortScoreTracksContainer({
|
9423 |
+
queue,
|
9424 |
+
resolving,
|
9425 |
+
clearQueue
|
9426 |
+
}) {
|
9427 |
+
if (resolving) {
|
9428 |
+
return null;
|
9429 |
+
}
|
9430 |
+
|
9431 |
+
const queueForPage = queue.filter(item => item.pagenow === window.pagenow && item.adminpage === window.adminpage);
|
9432 |
+
|
9433 |
+
if (queueForPage.length) {
|
9434 |
+
clearQueue();
|
9435 |
+
}
|
9436 |
+
|
9437 |
+
return Object(external_wp_element_["createElement"])(external_wp_element_["Fragment"], null, queueForPage.map((item, index) => Object(external_wp_element_["createElement"])(customer_effort_score_tracks, {
|
9438 |
+
key: index,
|
9439 |
+
action: item.action,
|
9440 |
+
label: item.label,
|
9441 |
+
onSubmitLabel: item.onsubmit_label,
|
9442 |
+
trackProps: item.props || {}
|
9443 |
+
})));
|
9444 |
+
}
|
9445 |
+
|
9446 |
+
CustomerEffortScoreTracksContainer.propTypes = {
|
9447 |
+
/**
|
9448 |
+
* The queue of CES tracks surveys to display.
|
9449 |
+
*/
|
9450 |
+
queue: prop_types_default.a.arrayOf(prop_types_default.a.object),
|
9451 |
+
|
9452 |
+
/**
|
9453 |
+
* If the queue option is being resolved.
|
9454 |
+
*/
|
9455 |
+
resolving: prop_types_default.a.bool,
|
9456 |
+
|
9457 |
+
/**
|
9458 |
+
* Set up clearing the queue on the next page load.
|
9459 |
+
*/
|
9460 |
+
clearQueue: prop_types_default.a.func
|
9461 |
+
};
|
9462 |
+
/* harmony default export */ var customer_effort_score_tracks_container = (Object(external_wp_compose_["compose"])(Object(external_wp_data_["withSelect"])(select => {
|
9463 |
+
const {
|
9464 |
+
getCesSurveyQueue,
|
9465 |
+
isResolving
|
9466 |
+
} = select(constants["c" /* STORE_KEY */]);
|
9467 |
+
const queue = getCesSurveyQueue();
|
9468 |
+
const resolving = isResolving('getOption', [constants["b" /* QUEUE_OPTION_NAME */]]);
|
9469 |
+
return {
|
9470 |
+
queue,
|
9471 |
+
resolving
|
9472 |
+
};
|
9473 |
+
}), Object(external_wp_data_["withDispatch"])(dispatch => {
|
9474 |
+
const {
|
9475 |
+
updateOptions
|
9476 |
+
} = dispatch(external_wc_data_["OPTIONS_STORE_NAME"]);
|
9477 |
+
return {
|
9478 |
+
clearQueue: () => {
|
9479 |
+
// This sets an option that should be used on the next page
|
9480 |
+
// load to clear the CES tracks queue for the current page (see
|
9481 |
+
// CustomerEffortScoreTracks.php) - clearing the queue
|
9482 |
+
// directly puts this into an infinite loop which is picked
|
9483 |
+
// up by React.
|
9484 |
+
updateOptions({
|
9485 |
+
woocommerce_clear_ces_tracks_queue_for_page: {
|
9486 |
+
pagenow: window.pagenow,
|
9487 |
+
adminpage: window.adminpage
|
9488 |
+
}
|
9489 |
+
});
|
9490 |
+
}
|
9491 |
+
};
|
9492 |
+
}))(CustomerEffortScoreTracksContainer));
|
9493 |
+
// CONCATENATED MODULE: ./client/customer-effort-score-tracks/index.js
|
9494 |
+
|
9495 |
+
|
9496 |
+
|
9497 |
+
/***/ }),
|
9498 |
+
|
9499 |
+
/***/ 272:
|
9500 |
+
/***/ (function(module, __webpack_exports__, __webpack_require__) {
|
9501 |
+
|
9502 |
+
"use strict";
|
9503 |
+
|
9504 |
+
// EXPORTS
|
9505 |
+
__webpack_require__.d(__webpack_exports__, "a", function() { return /* reexport */ EmbeddedBodyLayout; });
|
9506 |
+
|
9507 |
+
// EXTERNAL MODULE: ./node_modules/@babel/runtime/helpers/extends.js
|
9508 |
+
var helpers_extends = __webpack_require__(36);
|
9509 |
+
var extends_default = /*#__PURE__*/__webpack_require__.n(helpers_extends);
|
9510 |
+
|
9511 |
+
// EXTERNAL MODULE: external ["wp","element"]
|
9512 |
+
var external_wp_element_ = __webpack_require__(0);
|
9513 |
+
|
9514 |
+
// EXTERNAL MODULE: external ["wp","hooks"]
|
9515 |
+
var external_wp_hooks_ = __webpack_require__(31);
|
9516 |
+
|
9517 |
+
// EXTERNAL MODULE: ./node_modules/qs/lib/index.js
|
9518 |
+
var lib = __webpack_require__(28);
|
9519 |
+
|
9520 |
+
// EXTERNAL MODULE: external ["wp","data"]
|
9521 |
+
var external_wp_data_ = __webpack_require__(7);
|
9522 |
+
|
9523 |
+
// EXTERNAL MODULE: external ["wc","data"]
|
9524 |
+
var external_wc_data_ = __webpack_require__(11);
|
9525 |
+
|
9526 |
+
// CONCATENATED MODULE: ./client/settings-recommendations/recommendations-eligibility-wrapper.tsx
|
9527 |
+
|
9528 |
+
|
9529 |
+
/**
|
9530 |
+
* External dependencies
|
9531 |
+
*/
|
9532 |
+
|
9533 |
+
|
9534 |
+
const SHOW_MARKETPLACE_SUGGESTION_OPTION = 'woocommerce_show_marketplace_suggestions';
|
9535 |
+
|
9536 |
+
const RecommendationsEligibilityWrapper = ({
|
9537 |
+
children
|
9538 |
+
}) => {
|
9539 |
+
const {
|
9540 |
+
currentUserCan
|
9541 |
+
} = Object(external_wc_data_["useUser"])();
|
9542 |
+
const isMarketplaceSuggestionsEnabled = Object(external_wp_data_["useSelect"])(select => {
|
9543 |
+
const {
|
9544 |
+
getOption,
|
9545 |
+
hasFinishedResolution
|
9546 |
+
} = select(external_wc_data_["OPTIONS_STORE_NAME"]);
|
9547 |
+
const hasFinishedResolving = hasFinishedResolution('getOption', [SHOW_MARKETPLACE_SUGGESTION_OPTION]);
|
9548 |
+
const canShowMarketplaceSuggestions = getOption(SHOW_MARKETPLACE_SUGGESTION_OPTION) !== 'no';
|
9549 |
+
return hasFinishedResolving && canShowMarketplaceSuggestions;
|
9550 |
+
});
|
9551 |
+
|
9552 |
+
if (!currentUserCan('install_plugins')) {
|
9553 |
+
return null;
|
9554 |
+
}
|
9555 |
+
|
9556 |
+
if (!isMarketplaceSuggestionsEnabled) {
|
9557 |
+
return null;
|
9558 |
+
}
|
9559 |
+
|
9560 |
+
return Object(external_wp_element_["createElement"])(external_wp_element_["Fragment"], null, children);
|
9561 |
+
};
|
9562 |
+
|
9563 |
+
/* harmony default export */ var recommendations_eligibility_wrapper = (RecommendationsEligibilityWrapper);
|
9564 |
+
// CONCATENATED MODULE: ./client/payments/payment-recommendations-wrapper.tsx
|
9565 |
+
|
9566 |
+
|
9567 |
+
/**
|
9568 |
+
* External dependencies
|
9569 |
+
*/
|
9570 |
+
|
9571 |
+
/**
|
9572 |
+
* Internal dependencies
|
9573 |
+
*/
|
9574 |
+
|
9575 |
+
|
9576 |
+
const PaymentRecommendationsChunk = Object(external_wp_element_["lazy"])(() => __webpack_require__.e(/* import() | payment-recommendations */ 44).then(__webpack_require__.bind(null, 622)));
|
9577 |
+
const PaymentRecommendations = ({
|
9578 |
+
page,
|
9579 |
+
tab,
|
9580 |
+
section
|
9581 |
+
}) => {
|
9582 |
+
if (page === 'wc-settings' && tab === 'checkout' && !section) {
|
9583 |
+
return Object(external_wp_element_["createElement"])(recommendations_eligibility_wrapper, null, Object(external_wp_element_["createElement"])(external_wp_element_["Suspense"], {
|
9584 |
+
fallback: null
|
9585 |
+
}, Object(external_wp_element_["createElement"])(PaymentRecommendationsChunk, null)));
|
9586 |
+
}
|
9587 |
+
|
9588 |
+
return null;
|
9589 |
+
};
|
9590 |
+
// CONCATENATED MODULE: ./client/payments/index.ts
|
9591 |
+
|
9592 |
+
// CONCATENATED MODULE: ./client/shipping/shipping-recommendations-wrapper.tsx
|
9593 |
+
|
9594 |
+
|
9595 |
+
/**
|
9596 |
+
* External dependencies
|
9597 |
+
*/
|
9598 |
+
|
9599 |
+
/**
|
9600 |
+
* Internal dependencies
|
9601 |
+
*/
|
9602 |
+
|
9603 |
+
|
9604 |
+
const ShippingRecommendationsLoader = Object(external_wp_element_["lazy"])(() => __webpack_require__.e(/* import() | shipping-recommendations */ 47).then(__webpack_require__.bind(null, 630)));
|
9605 |
+
const ShippingRecommendations = ({
|
9606 |
+
page,
|
9607 |
+
tab,
|
9608 |
+
section,
|
9609 |
+
zone_id
|
9610 |
+
}) => {
|
9611 |
+
if (page !== 'wc-settings') {
|
9612 |
+
return null;
|
9613 |
+
}
|
9614 |
+
|
9615 |
+
if (tab !== 'shipping') {
|
9616 |
+
return null;
|
9617 |
+
}
|
9618 |
+
|
9619 |
+
if (Boolean(section)) {
|
9620 |
+
return null;
|
9621 |
+
}
|
9622 |
+
|
9623 |
+
if (Boolean(zone_id)) {
|
9624 |
+
return null;
|
9625 |
+
}
|
9626 |
+
|
9627 |
+
return Object(external_wp_element_["createElement"])(recommendations_eligibility_wrapper, null, Object(external_wp_element_["createElement"])(external_wp_element_["Suspense"], {
|
9628 |
+
fallback: null
|
9629 |
+
}, Object(external_wp_element_["createElement"])(ShippingRecommendationsLoader, null)));
|
9630 |
+
};
|
9631 |
+
// CONCATENATED MODULE: ./client/shipping/index.ts
|
9632 |
+
|
9633 |
+
// EXTERNAL MODULE: ./client/embedded-body-layout/style.scss
|
9634 |
+
var style = __webpack_require__(300);
|
9635 |
+
|
9636 |
+
// CONCATENATED MODULE: ./client/embedded-body-layout/embedded-body-layout.tsx
|
9637 |
+
|
9638 |
+
|
9639 |
+
|
9640 |
+
/**
|
9641 |
+
* External dependencies
|
9642 |
+
*/
|
9643 |
+
|
9644 |
+
|
9645 |
+
/**
|
9646 |
+
* Internal dependencies
|
9647 |
+
*/
|
9648 |
+
|
9649 |
+
|
9650 |
+
|
9651 |
+
|
9652 |
+
|
9653 |
+
function isWPPage(params) {
|
9654 |
+
return params.page !== undefined;
|
9655 |
+
}
|
9656 |
+
|
9657 |
+
const EMBEDDED_BODY_COMPONENT_LIST = [PaymentRecommendations, ShippingRecommendations];
|
9658 |
+
/**
|
9659 |
+
* This component is appended to the bottom of the WooCommerce non-react pages (like settings).
|
9660 |
+
* You can add a component by writing a Fill component from slot-fill with the `embedded-body-layout` name.
|
9661 |
+
*
|
9662 |
+
* Each Fill component receives QueryParams, consisting of a page, tab, and section string.
|
9663 |
+
*/
|
9664 |
+
|
9665 |
+
const EmbeddedBodyLayout = () => {
|
9666 |
+
const query = Object(lib["parse"])(location.search.substring(1));
|
9667 |
+
let queryParams = {
|
9668 |
+
page: '',
|
9669 |
+
tab: ''
|
9670 |
+
};
|
9671 |
+
|
9672 |
+
if (isWPPage(query)) {
|
9673 |
+
queryParams = query;
|
9674 |
+
}
|
9675 |
+
|
9676 |
+
const componentList = Object(external_wp_hooks_["applyFilters"])('woocommerce_admin_embedded_layout_components', EMBEDDED_BODY_COMPONENT_LIST, queryParams);
|
9677 |
+
return Object(external_wp_element_["createElement"])("div", {
|
9678 |
+
className: "woocommerce-embedded-layout__primary",
|
9679 |
+
id: "woocommerce-embedded-layout__primary"
|
9680 |
+
}, componentList.map((Comp, index) => {
|
9681 |
+
return Object(external_wp_element_["createElement"])(Comp, extends_default()({
|
9682 |
+
key: index
|
9683 |
+
}, queryParams));
|
9684 |
+
}));
|
9685 |
+
};
|
9686 |
+
// CONCATENATED MODULE: ./client/embedded-body-layout/index.ts
|
9687 |
+
|
9688 |
+
|
9689 |
+
/***/ }),
|
9690 |
+
|
9691 |
+
/***/ 28:
|
9692 |
+
/***/ (function(module, exports, __webpack_require__) {
|
9693 |
+
|
9694 |
+
"use strict";
|
9695 |
+
|
9696 |
+
|
9697 |
+
var stringify = __webpack_require__(56);
|
9698 |
+
var parse = __webpack_require__(57);
|
9699 |
+
var formats = __webpack_require__(35);
|
9700 |
+
|
9701 |
+
module.exports = {
|
9702 |
+
formats: formats,
|
9703 |
+
parse: parse,
|
9704 |
+
stringify: stringify
|
9705 |
+
};
|
9706 |
+
|
9707 |
+
|
9708 |
+
/***/ }),
|
9709 |
+
|
9710 |
+
/***/ 281:
|
9711 |
+
/***/ (function(module, __webpack_exports__, __webpack_require__) {
|
9712 |
+
|
9713 |
+
"use strict";
|
9714 |
+
__webpack_require__.r(__webpack_exports__);
|
9715 |
+
/* WEBPACK VAR INJECTION */(function(global) {/* harmony import */ var _wordpress_element__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(0);
|
9716 |
+
/* harmony import */ var _wordpress_element__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(_wordpress_element__WEBPACK_IMPORTED_MODULE_0__);
|
9717 |
+
/* harmony import */ var _wordpress_notices__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(127);
|
9718 |
+
/* harmony import */ var _wordpress_notices__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(_wordpress_notices__WEBPACK_IMPORTED_MODULE_1__);
|
9719 |
+
/* harmony import */ var _woocommerce_data__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(11);
|
9720 |
+
/* harmony import */ var _woocommerce_data__WEBPACK_IMPORTED_MODULE_2___default = /*#__PURE__*/__webpack_require__.n(_woocommerce_data__WEBPACK_IMPORTED_MODULE_2__);
|
9721 |
+
/* harmony import */ var _woocommerce_wc_admin_settings__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(13);
|
9722 |
+
/* harmony import */ var _stylesheets_index_scss__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(283);
|
9723 |
+
/* harmony import */ var _stylesheets_index_scss__WEBPACK_IMPORTED_MODULE_4___default = /*#__PURE__*/__webpack_require__.n(_stylesheets_index_scss__WEBPACK_IMPORTED_MODULE_4__);
|
9724 |
+
/* harmony import */ var _layout__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(119);
|
9725 |
+
/* harmony import */ var _customer_effort_score_tracks__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(271);
|
9726 |
+
/* harmony import */ var _embedded_body_layout__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__(272);
|
9727 |
+
|
9728 |
+
|
9729 |
+
/**
|
9730 |
+
* External dependencies
|
9731 |
+
*/
|
9732 |
+
|
9733 |
+
|
9734 |
+
|
9735 |
+
|
9736 |
+
/**
|
9737 |
+
* Internal dependencies
|
9738 |
+
*/
|
9739 |
+
|
9740 |
+
|
9741 |
+
|
9742 |
+
|
9743 |
+
// Modify webpack pubilcPath at runtime based on location of WordPress Plugin.
|
9744 |
+
// eslint-disable-next-line no-undef,camelcase
|
9745 |
+
|
9746 |
+
__webpack_require__.p = global.wcAdminAssets.path;
|
9747 |
+
const appRoot = document.getElementById('root');
|
9748 |
+
const embeddedRoot = document.getElementById('woocommerce-embedded-root');
|
9749 |
+
const settingsGroup = 'wc_admin';
|
9750 |
+
const hydrateUser = Object(_woocommerce_wc_admin_settings__WEBPACK_IMPORTED_MODULE_3__[/* getSetting */ "f"])('currentUserData');
|
9751 |
+
|
9752 |
+
if (appRoot) {
|
9753 |
+
let HydratedPageLayout = Object(_woocommerce_data__WEBPACK_IMPORTED_MODULE_2__["withSettingsHydration"])(settingsGroup, window.wcSettings.admin)(_layout__WEBPACK_IMPORTED_MODULE_5__[/* PageLayout */ "b"]);
|
9754 |
+
const preloadSettings = window.wcSettings.admin ? window.wcSettings.admin.preloadSettings : false;
|
9755 |
+
const hydrateSettings = preloadSettings && preloadSettings.general;
|
9756 |
+
|
9757 |
+
if (hydrateSettings) {
|
9758 |
+
HydratedPageLayout = Object(_woocommerce_data__WEBPACK_IMPORTED_MODULE_2__["withSettingsHydration"])('general', {
|
9759 |
+
general: preloadSettings.general
|
9760 |
+
})(HydratedPageLayout);
|
9761 |
+
}
|
9762 |
+
|
9763 |
+
if (hydrateUser) {
|
9764 |
+
HydratedPageLayout = Object(_woocommerce_data__WEBPACK_IMPORTED_MODULE_2__["withCurrentUserHydration"])(hydrateUser)(HydratedPageLayout);
|
9765 |
+
}
|
9766 |
+
|
9767 |
+
Object(_wordpress_element__WEBPACK_IMPORTED_MODULE_0__["render"])(Object(_wordpress_element__WEBPACK_IMPORTED_MODULE_0__["createElement"])(HydratedPageLayout, null), appRoot);
|
9768 |
+
} else if (embeddedRoot) {
|
9769 |
+
let HydratedEmbedLayout = Object(_woocommerce_data__WEBPACK_IMPORTED_MODULE_2__["withSettingsHydration"])(settingsGroup, window.wcSettings.admin)(_layout__WEBPACK_IMPORTED_MODULE_5__[/* EmbedLayout */ "a"]);
|
9770 |
+
|
9771 |
+
if (hydrateUser) {
|
9772 |
+
HydratedEmbedLayout = Object(_woocommerce_data__WEBPACK_IMPORTED_MODULE_2__["withCurrentUserHydration"])(hydrateUser)(HydratedEmbedLayout);
|
9773 |
+
} // Render the header.
|
9774 |
+
|
9775 |
+
|
9776 |
+
Object(_wordpress_element__WEBPACK_IMPORTED_MODULE_0__["render"])(Object(_wordpress_element__WEBPACK_IMPORTED_MODULE_0__["createElement"])(HydratedEmbedLayout, null), embeddedRoot);
|
9777 |
+
embeddedRoot.classList.remove('is-embed-loading'); // Render notices just above the WP content div.
|
9778 |
+
|
9779 |
+
const wpBody = document.getElementById('wpbody-content');
|
9780 |
+
const wrap = wpBody.querySelector('.wrap.woocommerce') || wpBody.querySelector('.wrap');
|
9781 |
+
const noticeContainer = document.createElement('div');
|
9782 |
+
Object(_wordpress_element__WEBPACK_IMPORTED_MODULE_0__["render"])(Object(_wordpress_element__WEBPACK_IMPORTED_MODULE_0__["createElement"])("div", {
|
9783 |
+
className: "woocommerce-layout"
|
9784 |
+
}, Object(_wordpress_element__WEBPACK_IMPORTED_MODULE_0__["createElement"])(_layout__WEBPACK_IMPORTED_MODULE_5__[/* PrimaryLayout */ "c"], null)), wpBody.insertBefore(noticeContainer, wrap));
|
9785 |
+
const embeddedBodyContainer = document.createElement('div');
|
9786 |
+
Object(_wordpress_element__WEBPACK_IMPORTED_MODULE_0__["render"])(Object(_wordpress_element__WEBPACK_IMPORTED_MODULE_0__["createElement"])(_embedded_body_layout__WEBPACK_IMPORTED_MODULE_7__[/* EmbeddedBodyLayout */ "a"], null), wpBody.insertBefore(embeddedBodyContainer, wrap.nextSibling));
|
9787 |
+
} // Render the CustomerEffortScoreTracksContainer only if
|
9788 |
+
// the feature flag is enabled.
|
9789 |
+
|
9790 |
+
|
9791 |
+
if (window.wcAdminFeatures && window.wcAdminFeatures['customer-effort-score-tracks'] === true) {
|
9792 |
+
// Set up customer effort score survey.
|
9793 |
+
(function () {
|
9794 |
+
const root = appRoot || embeddedRoot;
|
9795 |
+
Object(_wordpress_element__WEBPACK_IMPORTED_MODULE_0__["render"])(Object(_wordpress_element__WEBPACK_IMPORTED_MODULE_0__["createElement"])(_customer_effort_score_tracks__WEBPACK_IMPORTED_MODULE_6__[/* CustomerEffortScoreTracksContainer */ "a"], null), root.insertBefore(document.createElement('div'), null));
|
9796 |
+
})();
|
9797 |
+
}
|
9798 |
+
/* WEBPACK VAR INJECTION */}.call(this, __webpack_require__(79)))
|
9799 |
+
|
9800 |
+
/***/ }),
|
9801 |
+
|
9802 |
+
/***/ 283:
|
9803 |
+
/***/ (function(module, exports, __webpack_require__) {
|
9804 |
+
|
9805 |
+
// extracted by mini-css-extract-plugin
|
9806 |
+
|
9807 |
+
/***/ }),
|
9808 |
+
|
9809 |
+
/***/ 284:
|
9810 |
+
/***/ (function(module, exports) {
|
9811 |
+
|
9812 |
+
(function() { module.exports = window["wc"]["notices"]; }());
|
9813 |
+
|
9814 |
+
/***/ }),
|
9815 |
+
|
9816 |
+
/***/ 285:
|
9817 |
+
/***/ (function(module, exports, __webpack_require__) {
|
9818 |
+
|
9819 |
+
// extracted by mini-css-extract-plugin
|
9820 |
+
|
9821 |
+
/***/ }),
|
9822 |
+
|
9823 |
+
/***/ 286:
|
9824 |
+
/***/ (function(module, exports, __webpack_require__) {
|
9825 |
+
|
9826 |
+
// extracted by mini-css-extract-plugin
|
9827 |
+
|
9828 |
+
/***/ }),
|
9829 |
+
|
9830 |
+
/***/ 287:
|
9831 |
+
/***/ (function(module, exports, __webpack_require__) {
|
9832 |
+
|
9833 |
+
// extracted by mini-css-extract-plugin
|
9834 |
+
|
9835 |
+
/***/ }),
|
9836 |
+
|
9837 |
+
/***/ 288:
|
9838 |
+
/***/ (function(module, exports, __webpack_require__) {
|
9839 |
+
|
9840 |
+
// extracted by mini-css-extract-plugin
|
9841 |
+
|
9842 |
+
/***/ }),
|
9843 |
+
|
9844 |
+
/***/ 289:
|
9845 |
+
/***/ (function(module, exports, __webpack_require__) {
|
9846 |
+
|
9847 |
+
// extracted by mini-css-extract-plugin
|
9848 |
+
|
9849 |
+
/***/ }),
|
9850 |
+
|
9851 |
+
/***/ 29:
|
9852 |
+
/***/ (function(module, exports) {
|
9853 |
+
|
9854 |
+
(function() { module.exports = window["wp"]["htmlEntities"]; }());
|
9855 |
+
|
9856 |
+
/***/ }),
|
9857 |
+
|
9858 |
+
/***/ 290:
|
9859 |
+
/***/ (function(module, exports, __webpack_require__) {
|
9860 |
+
|
9861 |
+
// extracted by mini-css-extract-plugin
|
9862 |
+
|
9863 |
+
/***/ }),
|
9864 |
+
|
9865 |
+
/***/ 291:
|
9866 |
+
/***/ (function(module, exports, __webpack_require__) {
|
9867 |
+
|
9868 |
+
// extracted by mini-css-extract-plugin
|
9869 |
+
|
9870 |
+
/***/ }),
|
9871 |
+
|
9872 |
+
/***/ 292:
|
9873 |
+
/***/ (function(module, exports, __webpack_require__) {
|
9874 |
+
|
9875 |
+
// extracted by mini-css-extract-plugin
|
9876 |
+
|
9877 |
+
/***/ }),
|
9878 |
+
|
9879 |
+
/***/ 293:
|
9880 |
+
/***/ (function(module, __webpack_exports__, __webpack_require__) {
|
9881 |
+
|
9882 |
+
"use strict";
|
9883 |
+
/* harmony import */ var _wordpress_element__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(0);
|
9884 |
+
/* harmony import */ var _wordpress_element__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(_wordpress_element__WEBPACK_IMPORTED_MODULE_0__);
|
9885 |
+
/* harmony import */ var _wordpress_primitives__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(8);
|
9886 |
+
/* harmony import */ var _wordpress_primitives__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(_wordpress_primitives__WEBPACK_IMPORTED_MODULE_1__);
|
9887 |
+
|
9888 |
+
|
9889 |
+
/**
|
9890 |
+
* WordPress dependencies
|
9891 |
+
*/
|
9892 |
+
|
9893 |
+
var chevronLeft = Object(_wordpress_element__WEBPACK_IMPORTED_MODULE_0__["createElement"])(_wordpress_primitives__WEBPACK_IMPORTED_MODULE_1__["SVG"], {
|
9894 |
+
xmlns: "http://www.w3.org/2000/svg",
|
9895 |
+
viewBox: "0 0 24 24"
|
9896 |
+
}, Object(_wordpress_element__WEBPACK_IMPORTED_MODULE_0__["createElement"])(_wordpress_primitives__WEBPACK_IMPORTED_MODULE_1__["Path"], {
|
9897 |
+
d: "M14.6 7l-1.2-1L8 12l5.4 6 1.2-1-4.6-5z"
|
9898 |
+
}));
|
9899 |
+
/* harmony default export */ __webpack_exports__["a"] = (chevronLeft);
|
9900 |
+
//# sourceMappingURL=chevron-left.js.map
|
9901 |
+
|
9902 |
+
/***/ }),
|
9903 |
+
|
9904 |
+
/***/ 294:
|
9905 |
+
/***/ (function(module, exports) {
|
9906 |
+
|
9907 |
+
function _objectWithoutPropertiesLoose(source, excluded) {
|
9908 |
+
if (source == null) return {};
|
9909 |
+
var target = {};
|
9910 |
+
var sourceKeys = Object.keys(source);
|
9911 |
+
var key, i;
|
9912 |
+
|
9913 |
+
for (i = 0; i < sourceKeys.length; i++) {
|
9914 |
+
key = sourceKeys[i];
|
9915 |
+
if (excluded.indexOf(key) >= 0) continue;
|
9916 |
+
target[key] = source[key];
|
9917 |
+
}
|
9918 |
+
|
9919 |
+
return target;
|
9920 |
+
}
|
9921 |
+
|
9922 |
+
module.exports = _objectWithoutPropertiesLoose;
|
9923 |
+
module.exports["default"] = module.exports, module.exports.__esModule = true;
|
9924 |
+
|
9925 |
+
/***/ }),
|
9926 |
+
|
9927 |
+
/***/ 295:
|
9928 |
+
/***/ (function(module, exports, __webpack_require__) {
|
9929 |
+
|
9930 |
+
var setPrototypeOf = __webpack_require__(296);
|
9931 |
+
|
9932 |
+
function _inheritsLoose(subClass, superClass) {
|
9933 |
+
subClass.prototype = Object.create(superClass.prototype);
|
9934 |
+
subClass.prototype.constructor = subClass;
|
9935 |
+
setPrototypeOf(subClass, superClass);
|
9936 |
+
}
|
9937 |
+
|
9938 |
+
module.exports = _inheritsLoose;
|
9939 |
+
module.exports["default"] = module.exports, module.exports.__esModule = true;
|
9940 |
+
|
9941 |
+
/***/ }),
|
9942 |
+
|
9943 |
+
/***/ 296:
|
9944 |
+
/***/ (function(module, exports) {
|
9945 |
+
|
9946 |
+
function _setPrototypeOf(o, p) {
|
9947 |
+
module.exports = _setPrototypeOf = Object.setPrototypeOf || function _setPrototypeOf(o, p) {
|
9948 |
+
o.__proto__ = p;
|
9949 |
+
return o;
|
9950 |
+
};
|
9951 |
+
|
9952 |
+
module.exports["default"] = module.exports, module.exports.__esModule = true;
|
9953 |
+
return _setPrototypeOf(o, p);
|
9954 |
+
}
|
9955 |
+
|
9956 |
+
module.exports = _setPrototypeOf;
|
9957 |
+
module.exports["default"] = module.exports, module.exports.__esModule = true;
|
9958 |
+
|
9959 |
+
/***/ }),
|
9960 |
+
|
9961 |
+
/***/ 297:
|
9962 |
+
/***/ (function(module, exports) {
|
9963 |
+
|
9964 |
+
function _assertThisInitialized(self) {
|
9965 |
+
if (self === void 0) {
|
9966 |
+
throw new ReferenceError("this hasn't been initialised - super() hasn't been called");
|
9967 |
+
}
|
9968 |
+
|
9969 |
+
return self;
|
9970 |
+
}
|
9971 |
+
|
9972 |
+
module.exports = _assertThisInitialized;
|
9973 |
+
module.exports["default"] = module.exports, module.exports.__esModule = true;
|
9974 |
+
|
9975 |
+
/***/ }),
|
9976 |
+
|
9977 |
+
/***/ 298:
|
9978 |
+
/***/ (function(module, exports, __webpack_require__) {
|
9979 |
+
|
9980 |
+
// extracted by mini-css-extract-plugin
|
9981 |
+
|
9982 |
+
/***/ }),
|
9983 |
+
|
9984 |
+
/***/ 299:
|
9985 |
+
/***/ (function(module, exports) {
|
9986 |
+
|
9987 |
+
module.exports = Array.isArray || function (arr) {
|
9988 |
+
return Object.prototype.toString.call(arr) == '[object Array]';
|
9989 |
+
};
|
9990 |
+
|
9991 |
+
|
9992 |
+
/***/ }),
|
9993 |
+
|
9994 |
+
/***/ 3:
|
9995 |
+
/***/ (function(module, exports) {
|
9996 |
+
|
9997 |
+
(function() { module.exports = window["wp"]["components"]; }());
|
9998 |
+
|
9999 |
+
/***/ }),
|
10000 |
+
|
10001 |
+
/***/ 30:
|
10002 |
+
/***/ (function(module, exports) {
|
10003 |
+
|
10004 |
+
(function() { module.exports = window["ReactDOM"]; }());
|
10005 |
+
|
10006 |
+
/***/ }),
|
10007 |
+
|
10008 |
+
/***/ 300:
|
10009 |
+
/***/ (function(module, exports, __webpack_require__) {
|
10010 |
+
|
10011 |
+
// extracted by mini-css-extract-plugin
|
10012 |
+
|
10013 |
+
/***/ }),
|
10014 |
+
|
10015 |
+
/***/ 31:
|
10016 |
+
/***/ (function(module, exports) {
|
10017 |
+
|
10018 |
+
(function() { module.exports = window["wp"]["hooks"]; }());
|
10019 |
+
|
10020 |
+
/***/ }),
|
10021 |
+
|
10022 |
+
/***/ 35:
|
10023 |
+
/***/ (function(module, exports, __webpack_require__) {
|
10024 |
+
|
10025 |
+
"use strict";
|
10026 |
+
|
10027 |
+
|
10028 |
+
var replace = String.prototype.replace;
|
10029 |
+
var percentTwenties = /%20/g;
|
10030 |
+
|
10031 |
+
var Format = {
|
10032 |
+
RFC1738: 'RFC1738',
|
10033 |
+
RFC3986: 'RFC3986'
|
10034 |
+
};
|
10035 |
+
|
10036 |
+
module.exports = {
|
10037 |
+
'default': Format.RFC3986,
|
10038 |
+
formatters: {
|
10039 |
+
RFC1738: function (value) {
|
10040 |
+
return replace.call(value, percentTwenties, '+');
|
10041 |
+
},
|
10042 |
+
RFC3986: function (value) {
|
10043 |
+
return String(value);
|
10044 |
+
}
|
10045 |
+
},
|
10046 |
+
RFC1738: Format.RFC1738,
|
10047 |
+
RFC3986: Format.RFC3986
|
10048 |
+
};
|
10049 |
+
|
10050 |
+
|
10051 |
+
/***/ }),
|
10052 |
+
|
10053 |
+
/***/ 36:
|
10054 |
+
/***/ (function(module, exports) {
|
10055 |
+
|
10056 |
+
function _extends() {
|
10057 |
+
module.exports = _extends = Object.assign || function (target) {
|
10058 |
+
for (var i = 1; i < arguments.length; i++) {
|
10059 |
+
var source = arguments[i];
|
10060 |
+
|
10061 |
+
for (var key in source) {
|
10062 |
+
if (Object.prototype.hasOwnProperty.call(source, key)) {
|
10063 |
+
target[key] = source[key];
|
10064 |
+
}
|
10065 |
+
}
|
10066 |
+
}
|
10067 |
+
|
10068 |
+
return target;
|
10069 |
+
};
|
10070 |
+
|
10071 |
+
module.exports["default"] = module.exports, module.exports.__esModule = true;
|
10072 |
+
return _extends.apply(this, arguments);
|
10073 |
+
}
|
10074 |
+
|
10075 |
+
module.exports = _extends;
|
10076 |
+
module.exports["default"] = module.exports, module.exports.__esModule = true;
|
10077 |
+
|
10078 |
+
/***/ }),
|
10079 |
+
|
10080 |
+
/***/ 4:
|
10081 |
+
/***/ (function(module, exports) {
|
10082 |
+
|
10083 |
+
(function() { module.exports = window["lodash"]; }());
|
10084 |
+
|
10085 |
+
/***/ }),
|
10086 |
+
|
10087 |
+
/***/ 41:
|
10088 |
+
/***/ (function(module, exports, __webpack_require__) {
|
10089 |
+
|
10090 |
+
"use strict";
|
10091 |
+
|
10092 |
+
|
10093 |
+
var formats = __webpack_require__(35);
|
10094 |
+
|
10095 |
+
var has = Object.prototype.hasOwnProperty;
|
10096 |
+
var isArray = Array.isArray;
|
10097 |
+
|
10098 |
+
var hexTable = (function () {
|
10099 |
+
var array = [];
|
10100 |
+
for (var i = 0; i < 256; ++i) {
|
10101 |
+
array.push('%' + ((i < 16 ? '0' : '') + i.toString(16)).toUpperCase());
|
10102 |
+
}
|
10103 |
+
|
10104 |
+
return array;
|
10105 |
+
}());
|
10106 |
+
|
10107 |
+
var compactQueue = function compactQueue(queue) {
|
10108 |
+
while (queue.length > 1) {
|
10109 |
+
var item = queue.pop();
|
10110 |
+
var obj = item.obj[item.prop];
|
10111 |
+
|
10112 |
+
if (isArray(obj)) {
|
10113 |
+
var compacted = [];
|
10114 |
+
|
10115 |
+
for (var j = 0; j < obj.length; ++j) {
|
10116 |
+
if (typeof obj[j] !== 'undefined') {
|
10117 |
+
compacted.push(obj[j]);
|
10118 |
+
}
|
10119 |
+
}
|
10120 |
+
|
10121 |
+
item.obj[item.prop] = compacted;
|
10122 |
+
}
|
10123 |
+
}
|
10124 |
+
};
|
10125 |
+
|
10126 |
+
var arrayToObject = function arrayToObject(source, options) {
|
10127 |
+
var obj = options && options.plainObjects ? Object.create(null) : {};
|
10128 |
+
for (var i = 0; i < source.length; ++i) {
|
10129 |
+
if (typeof source[i] !== 'undefined') {
|
10130 |
+
obj[i] = source[i];
|
10131 |
+
}
|
10132 |
+
}
|
10133 |
+
|
10134 |
+
return obj;
|
10135 |
+
};
|
10136 |
+
|
10137 |
+
var merge = function merge(target, source, options) {
|
10138 |
+
/* eslint no-param-reassign: 0 */
|
10139 |
+
if (!source) {
|
10140 |
+
return target;
|
10141 |
+
}
|
10142 |
+
|
10143 |
+
if (typeof source !== 'object') {
|
10144 |
+
if (isArray(target)) {
|
10145 |
+
target.push(source);
|
10146 |
+
} else if (target && typeof target === 'object') {
|
10147 |
+
if ((options && (options.plainObjects || options.allowPrototypes)) || !has.call(Object.prototype, source)) {
|
10148 |
+
target[source] = true;
|
10149 |
+
}
|
10150 |
+
} else {
|
10151 |
+
return [target, source];
|
10152 |
+
}
|
10153 |
+
|
10154 |
+
return target;
|
10155 |
+
}
|
10156 |
+
|
10157 |
+
if (!target || typeof target !== 'object') {
|
10158 |
+
return [target].concat(source);
|
10159 |
+
}
|
10160 |
+
|
10161 |
+
var mergeTarget = target;
|
10162 |
+
if (isArray(target) && !isArray(source)) {
|
10163 |
+
mergeTarget = arrayToObject(target, options);
|
10164 |
+
}
|
10165 |
+
|
10166 |
+
if (isArray(target) && isArray(source)) {
|
10167 |
+
source.forEach(function (item, i) {
|
10168 |
+
if (has.call(target, i)) {
|
10169 |
+
var targetItem = target[i];
|
10170 |
+
if (targetItem && typeof targetItem === 'object' && item && typeof item === 'object') {
|
10171 |
+
target[i] = merge(targetItem, item, options);
|
10172 |
+
} else {
|
10173 |
+
target.push(item);
|
10174 |
+
}
|
10175 |
+
} else {
|
10176 |
+
target[i] = item;
|
10177 |
+
}
|
10178 |
+
});
|
10179 |
+
return target;
|
10180 |
+
}
|
10181 |
+
|
10182 |
+
return Object.keys(source).reduce(function (acc, key) {
|
10183 |
+
var value = source[key];
|
10184 |
+
|
10185 |
+
if (has.call(acc, key)) {
|
10186 |
+
acc[key] = merge(acc[key], value, options);
|
10187 |
+
} else {
|
10188 |
+
acc[key] = value;
|
10189 |
+
}
|
10190 |
+
return acc;
|
10191 |
+
}, mergeTarget);
|
10192 |
+
};
|
10193 |
+
|
10194 |
+
var assign = function assignSingleSource(target, source) {
|
10195 |
+
return Object.keys(source).reduce(function (acc, key) {
|
10196 |
+
acc[key] = source[key];
|
10197 |
+
return acc;
|
10198 |
+
}, target);
|
10199 |
+
};
|
10200 |
+
|
10201 |
+
var decode = function (str, decoder, charset) {
|
10202 |
+
var strWithoutPlus = str.replace(/\+/g, ' ');
|
10203 |
+
if (charset === 'iso-8859-1') {
|
10204 |
+
// unescape never throws, no try...catch needed:
|
10205 |
+
return strWithoutPlus.replace(/%[0-9a-f]{2}/gi, unescape);
|
10206 |
+
}
|
10207 |
+
// utf-8
|
10208 |
+
try {
|
10209 |
+
return decodeURIComponent(strWithoutPlus);
|
10210 |
+
} catch (e) {
|
10211 |
+
return strWithoutPlus;
|
10212 |
+
}
|
10213 |
+
};
|
10214 |
+
|
10215 |
+
var encode = function encode(str, defaultEncoder, charset, kind, format) {
|
10216 |
+
// This code was originally written by Brian White (mscdex) for the io.js core querystring library.
|
10217 |
+
// It has been adapted here for stricter adherence to RFC 3986
|
10218 |
+
if (str.length === 0) {
|
10219 |
+
return str;
|
10220 |
+
}
|
10221 |
+
|
10222 |
+
var string = str;
|
10223 |
+
if (typeof str === 'symbol') {
|
10224 |
+
string = Symbol.prototype.toString.call(str);
|
10225 |
+
} else if (typeof str !== 'string') {
|
10226 |
+
string = String(str);
|
10227 |
+
}
|
10228 |
+
|
10229 |
+
if (charset === 'iso-8859-1') {
|
10230 |
+
return escape(string).replace(/%u[0-9a-f]{4}/gi, function ($0) {
|
10231 |
+
return '%26%23' + parseInt($0.slice(2), 16) + '%3B';
|
10232 |
+
});
|
10233 |
+
}
|
10234 |
+
|
10235 |
+
var out = '';
|
10236 |
+
for (var i = 0; i < string.length; ++i) {
|
10237 |
+
var c = string.charCodeAt(i);
|
10238 |
+
|
10239 |
+
if (
|
10240 |
+
c === 0x2D // -
|
10241 |
+
|| c === 0x2E // .
|
10242 |
+
|| c === 0x5F // _
|
10243 |
+
|| c === 0x7E // ~
|
10244 |
+
|| (c >= 0x30 && c <= 0x39) // 0-9
|
10245 |
+
|| (c >= 0x41 && c <= 0x5A) // a-z
|
10246 |
+
|| (c >= 0x61 && c <= 0x7A) // A-Z
|
10247 |
+
|| (format === formats.RFC1738 && (c === 0x28 || c === 0x29)) // ( )
|
10248 |
+
) {
|
10249 |
+
out += string.charAt(i);
|
10250 |
+
continue;
|
10251 |
+
}
|
10252 |
+
|
10253 |
+
if (c < 0x80) {
|
10254 |
+
out = out + hexTable[c];
|
10255 |
+
continue;
|
10256 |
+
}
|
10257 |
+
|
10258 |
+
if (c < 0x800) {
|
10259 |
+
out = out + (hexTable[0xC0 | (c >> 6)] + hexTable[0x80 | (c & 0x3F)]);
|
10260 |
+
continue;
|
10261 |
+
}
|
10262 |
+
|
10263 |
+
if (c < 0xD800 || c >= 0xE000) {
|
10264 |
+
out = out + (hexTable[0xE0 | (c >> 12)] + hexTable[0x80 | ((c >> 6) & 0x3F)] + hexTable[0x80 | (c & 0x3F)]);
|
10265 |
+
continue;
|
10266 |
+
}
|
10267 |
+
|
10268 |
+
i += 1;
|
10269 |
+
c = 0x10000 + (((c & 0x3FF) << 10) | (string.charCodeAt(i) & 0x3FF));
|
10270 |
+
out += hexTable[0xF0 | (c >> 18)]
|
10271 |
+
+ hexTable[0x80 | ((c >> 12) & 0x3F)]
|
10272 |
+
+ hexTable[0x80 | ((c >> 6) & 0x3F)]
|
10273 |
+
+ hexTable[0x80 | (c & 0x3F)];
|
10274 |
+
}
|
10275 |
+
|
10276 |
+
return out;
|
10277 |
+
};
|
10278 |
+
|
10279 |
+
var compact = function compact(value) {
|
10280 |
+
var queue = [{ obj: { o: value }, prop: 'o' }];
|
10281 |
+
var refs = [];
|
10282 |
+
|
10283 |
+
for (var i = 0; i < queue.length; ++i) {
|
10284 |
+
var item = queue[i];
|
10285 |
+
var obj = item.obj[item.prop];
|
10286 |
+
|
10287 |
+
var keys = Object.keys(obj);
|
10288 |
+
for (var j = 0; j < keys.length; ++j) {
|
10289 |
+
var key = keys[j];
|
10290 |
+
var val = obj[key];
|
10291 |
+
if (typeof val === 'object' && val !== null && refs.indexOf(val) === -1) {
|
10292 |
+
queue.push({ obj: obj, prop: key });
|
10293 |
+
refs.push(val);
|
10294 |
+
}
|
10295 |
+
}
|
10296 |
+
}
|
10297 |
+
|
10298 |
+
compactQueue(queue);
|
10299 |
+
|
10300 |
+
return value;
|
10301 |
+
};
|
10302 |
+
|
10303 |
+
var isRegExp = function isRegExp(obj) {
|
10304 |
+
return Object.prototype.toString.call(obj) === '[object RegExp]';
|
10305 |
+
};
|
10306 |
+
|
10307 |
+
var isBuffer = function isBuffer(obj) {
|
10308 |
+
if (!obj || typeof obj !== 'object') {
|
10309 |
+
return false;
|
10310 |
+
}
|
10311 |
+
|
10312 |
+
return !!(obj.constructor && obj.constructor.isBuffer && obj.constructor.isBuffer(obj));
|
10313 |
+
};
|
10314 |
+
|
10315 |
+
var combine = function combine(a, b) {
|
10316 |
+
return [].concat(a, b);
|
10317 |
+
};
|
10318 |
+
|
10319 |
+
var maybeMap = function maybeMap(val, fn) {
|
10320 |
+
if (isArray(val)) {
|
10321 |
+
var mapped = [];
|
10322 |
+
for (var i = 0; i < val.length; i += 1) {
|
10323 |
+
mapped.push(fn(val[i]));
|
10324 |
+
}
|
10325 |
+
return mapped;
|
10326 |
+
}
|
10327 |
+
return fn(val);
|
10328 |
+
};
|
10329 |
+
|
10330 |
+
module.exports = {
|
10331 |
+
arrayToObject: arrayToObject,
|
10332 |
+
assign: assign,
|
10333 |
+
combine: combine,
|
10334 |
+
compact: compact,
|
10335 |
+
decode: decode,
|
10336 |
+
encode: encode,
|
10337 |
+
isBuffer: isBuffer,
|
10338 |
+
isRegExp: isRegExp,
|
10339 |
+
maybeMap: maybeMap,
|
10340 |
+
merge: merge
|
10341 |
+
};
|
10342 |
+
|
10343 |
+
|
10344 |
+
/***/ }),
|
10345 |
+
|
10346 |
+
/***/ 43:
|
10347 |
+
/***/ (function(module, __webpack_exports__, __webpack_require__) {
|
10348 |
+
|
10349 |
+
"use strict";
|
10350 |
+
var isProduction = "production" === 'production';
|
10351 |
+
var prefix = 'Invariant failed';
|
10352 |
+
function invariant(condition, message) {
|
10353 |
+
if (condition) {
|
10354 |
+
return;
|
10355 |
+
}
|
10356 |
+
if (isProduction) {
|
10357 |
+
throw new Error(prefix);
|
10358 |
+
}
|
10359 |
+
throw new Error(prefix + ": " + (message || ''));
|
10360 |
+
}
|
10361 |
+
|
10362 |
+
/* harmony default export */ __webpack_exports__["a"] = (invariant);
|
10363 |
+
|
10364 |
+
|
10365 |
+
/***/ }),
|
10366 |
+
|
10367 |
+
/***/ 476:
|
10368 |
+
/***/ (function(module, exports) {
|
10369 |
+
|
10370 |
+
(function() { module.exports = window["wc"]["csvExport"]; }());
|
10371 |
+
|
10372 |
+
/***/ }),
|
10373 |
+
|
10374 |
+
/***/ 478:
|
10375 |
+
/***/ (function(module, exports) {
|
10376 |
+
|
10377 |
+
(function() { module.exports = window["wc"]["wcSettings"]; }());
|
10378 |
+
|
10379 |
+
/***/ }),
|
10380 |
+
|
10381 |
+
/***/ 48:
|
10382 |
+
/***/ (function(module, exports, __webpack_require__) {
|
10383 |
+
|
10384 |
+
"use strict";
|
10385 |
+
/**
|
10386 |
+
* Copyright (c) 2013-present, Facebook, Inc.
|
10387 |
+
*
|
10388 |
+
* This source code is licensed under the MIT license found in the
|
10389 |
+
* LICENSE file in the root directory of this source tree.
|
10390 |
+
*/
|
10391 |
+
|
10392 |
+
|
10393 |
+
|
10394 |
+
var ReactPropTypesSecret = __webpack_require__(49);
|
10395 |
+
|
10396 |
+
function emptyFunction() {}
|
10397 |
+
function emptyFunctionWithReset() {}
|
10398 |
+
emptyFunctionWithReset.resetWarningCache = emptyFunction;
|
10399 |
+
|
10400 |
+
module.exports = function() {
|
10401 |
+
function shim(props, propName, componentName, location, propFullName, secret) {
|
10402 |
+
if (secret === ReactPropTypesSecret) {
|
10403 |
+
// It is still safe when called from React.
|
10404 |
+
return;
|
10405 |
+
}
|
10406 |
+
var err = new Error(
|
10407 |
+
'Calling PropTypes validators directly is not supported by the `prop-types` package. ' +
|
10408 |
+
'Use PropTypes.checkPropTypes() to call them. ' +
|
10409 |
+
'Read more at http://fb.me/use-check-prop-types'
|
10410 |
+
);
|
10411 |
+
err.name = 'Invariant Violation';
|
10412 |
+
throw err;
|
10413 |
+
};
|
10414 |
+
shim.isRequired = shim;
|
10415 |
+
function getShim() {
|
10416 |
+
return shim;
|
10417 |
+
};
|
10418 |
+
// Important!
|
10419 |
+
// Keep this list in sync with production version in `./factoryWithTypeCheckers.js`.
|
10420 |
+
var ReactPropTypes = {
|
10421 |
+
array: shim,
|
10422 |
+
bool: shim,
|
10423 |
+
func: shim,
|
10424 |
+
number: shim,
|
10425 |
+
object: shim,
|
10426 |
+
string: shim,
|
10427 |
+
symbol: shim,
|
10428 |
+
|
10429 |
+
any: shim,
|
10430 |
+
arrayOf: getShim,
|
10431 |
+
element: shim,
|
10432 |
+
elementType: shim,
|
10433 |
+
instanceOf: getShim,
|
10434 |
+
node: shim,
|
10435 |
+
objectOf: getShim,
|
10436 |
+
oneOf: getShim,
|
10437 |
+
oneOfType: getShim,
|
10438 |
+
shape: getShim,
|
10439 |
+
exact: getShim,
|
10440 |
+
|
10441 |
+
checkPropTypes: emptyFunctionWithReset,
|
10442 |
+
resetWarningCache: emptyFunction
|
10443 |
+
};
|
10444 |
+
|
10445 |
+
ReactPropTypes.PropTypes = ReactPropTypes;
|
10446 |
+
|
10447 |
+
return ReactPropTypes;
|
10448 |
+
};
|
10449 |
+
|
10450 |
+
|
10451 |
+
/***/ }),
|
10452 |
+
|
10453 |
+
/***/ 49:
|
10454 |
+
/***/ (function(module, exports, __webpack_require__) {
|
10455 |
+
|
10456 |
+
"use strict";
|
10457 |
+
/**
|
10458 |
+
* Copyright (c) 2013-present, Facebook, Inc.
|
10459 |
+
*
|
10460 |
+
* This source code is licensed under the MIT license found in the
|
10461 |
+
* LICENSE file in the root directory of this source tree.
|
10462 |
+
*/
|
10463 |
+
|
10464 |
+
|
10465 |
+
|
10466 |
+
var ReactPropTypesSecret = 'SECRET_DO_NOT_PASS_THIS_OR_YOU_WILL_BE_FIRED';
|
10467 |
+
|
10468 |
+
module.exports = ReactPropTypesSecret;
|
10469 |
+
|
10470 |
+
|
10471 |
+
/***/ }),
|
10472 |
+
|
10473 |
+
/***/ 499:
|
10474 |
+
/***/ (function(module, __webpack_exports__, __webpack_require__) {
|
10475 |
+
|
10476 |
+
"use strict";
|
10477 |
+
/* harmony import */ var _wordpress_element__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(0);
|
10478 |
+
/* harmony import */ var _wordpress_element__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(_wordpress_element__WEBPACK_IMPORTED_MODULE_0__);
|
10479 |
+
/* harmony import */ var _wordpress_primitives__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(8);
|
10480 |
+
/* harmony import */ var _wordpress_primitives__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(_wordpress_primitives__WEBPACK_IMPORTED_MODULE_1__);
|
10481 |
+
|
10482 |
+
|
10483 |
+
/**
|
10484 |
+
* WordPress dependencies
|
10485 |
+
*/
|
10486 |
+
|
10487 |
+
var close = Object(_wordpress_element__WEBPACK_IMPORTED_MODULE_0__["createElement"])(_wordpress_primitives__WEBPACK_IMPORTED_MODULE_1__["SVG"], {
|
10488 |
+
xmlns: "http://www.w3.org/2000/svg",
|
10489 |
+
viewBox: "0 0 24 24"
|
10490 |
+
}, Object(_wordpress_element__WEBPACK_IMPORTED_MODULE_0__["createElement"])(_wordpress_primitives__WEBPACK_IMPORTED_MODULE_1__["Path"], {
|
10491 |
+
d: "M13 11.8l6.1-6.3-1-1-6.1 6.2-6.1-6.2-1 1 6.1 6.3-6.5 6.7 1 1 6.5-6.6 6.5 6.6 1-1z"
|
10492 |
+
}));
|
10493 |
+
/* harmony default export */ __webpack_exports__["a"] = (close);
|
10494 |
+
//# sourceMappingURL=close.js.map
|
10495 |
+
|
10496 |
+
/***/ }),
|
10497 |
+
|
10498 |
+
/***/ 5:
|
10499 |
+
/***/ (function(module, exports) {
|
10500 |
+
|
10501 |
+
(function() { module.exports = window["React"]; }());
|
10502 |
+
|
10503 |
+
/***/ }),
|
10504 |
+
|
10505 |
+
/***/ 50:
|
10506 |
+
/***/ (function(module, exports, __webpack_require__) {
|
10507 |
+
|
10508 |
+
"use strict";
|
10509 |
+
|
10510 |
+
|
10511 |
+
/**
|
10512 |
+
* Copyright (c) 2013-present, Facebook, Inc.
|
10513 |
+
*
|
10514 |
+
* This source code is licensed under the MIT license found in the
|
10515 |
+
* LICENSE file in the root directory of this source tree.
|
10516 |
+
*
|
10517 |
+
*
|
10518 |
+
*/
|
10519 |
+
|
10520 |
+
function makeEmptyFunction(arg) {
|
10521 |
+
return function () {
|
10522 |
+
return arg;
|
10523 |
+
};
|
10524 |
+
}
|
10525 |
+
|
10526 |
+
/**
|
10527 |
+
* This function accepts and discards inputs; it has no side effects. This is
|
10528 |
+
* primarily useful idiomatically for overridable function endpoints which
|
10529 |
+
* always need to be callable, since JS lacks a null-call idiom ala Cocoa.
|
10530 |
+
*/
|
10531 |
+
var emptyFunction = function emptyFunction() {};
|
10532 |
+
|
10533 |
+
emptyFunction.thatReturns = makeEmptyFunction;
|
10534 |
+
emptyFunction.thatReturnsFalse = makeEmptyFunction(false);
|
10535 |
+
emptyFunction.thatReturnsTrue = makeEmptyFunction(true);
|
10536 |
+
emptyFunction.thatReturnsNull = makeEmptyFunction(null);
|
10537 |
+
emptyFunction.thatReturnsThis = function () {
|
10538 |
+
return this;
|
10539 |
+
};
|
10540 |
+
emptyFunction.thatReturnsArgument = function (arg) {
|
10541 |
+
return arg;
|
10542 |
+
};
|
10543 |
+
|
10544 |
+
module.exports = emptyFunction;
|
10545 |
+
|
10546 |
+
/***/ }),
|
10547 |
+
|
10548 |
+
/***/ 500:
|
10549 |
+
/***/ (function(module, __webpack_exports__, __webpack_require__) {
|
10550 |
+
|
10551 |
+
"use strict";
|
10552 |
+
/* harmony import */ var _wordpress_element__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(0);
|
10553 |
+
/* harmony import */ var _wordpress_element__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(_wordpress_element__WEBPACK_IMPORTED_MODULE_0__);
|
10554 |
+
/* harmony import */ var _wordpress_primitives__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(8);
|
10555 |
+
/* harmony import */ var _wordpress_primitives__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(_wordpress_primitives__WEBPACK_IMPORTED_MODULE_1__);
|
10556 |
+
|
10557 |
+
|
10558 |
+
/**
|
10559 |
+
* WordPress dependencies
|
10560 |
+
*/
|
10561 |
+
|
10562 |
+
var page = Object(_wordpress_element__WEBPACK_IMPORTED_MODULE_0__["createElement"])(_wordpress_primitives__WEBPACK_IMPORTED_MODULE_1__["SVG"], {
|
10563 |
+
xmlns: "http://www.w3.org/2000/svg",
|
10564 |
+
viewBox: "0 0 24 24"
|
10565 |
+
}, Object(_wordpress_element__WEBPACK_IMPORTED_MODULE_0__["createElement"])(_wordpress_primitives__WEBPACK_IMPORTED_MODULE_1__["Path"], {
|
10566 |
+
d: "M7 5.5h10a.5.5 0 01.5.5v12a.5.5 0 01-.5.5H7a.5.5 0 01-.5-.5V6a.5.5 0 01.5-.5zM17 4H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V6a2 2 0 00-2-2zm-1 3.75H8v1.5h8v-1.5zM8 11h8v1.5H8V11zm6 3.25H8v1.5h6v-1.5z"
|
10567 |
+
}));
|
10568 |
+
/* harmony default export */ __webpack_exports__["a"] = (page);
|
10569 |
+
//# sourceMappingURL=page.js.map
|
10570 |
+
|
10571 |
+
/***/ }),
|
10572 |
+
|
10573 |
+
/***/ 501:
|
10574 |
+
/***/ (function(module, __webpack_exports__, __webpack_require__) {
|
10575 |
+
|
10576 |
+
"use strict";
|
10577 |
+
/* harmony import */ var _wordpress_element__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(0);
|
10578 |
+
/* harmony import */ var _wordpress_element__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(_wordpress_element__WEBPACK_IMPORTED_MODULE_0__);
|
10579 |
+
/* harmony import */ var _wordpress_primitives__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(8);
|
10580 |
+
/* harmony import */ var _wordpress_primitives__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(_wordpress_primitives__WEBPACK_IMPORTED_MODULE_1__);
|
10581 |
+
|
10582 |
+
|
10583 |
+
/**
|
10584 |
+
* WordPress dependencies
|
10585 |
+
*/
|
10586 |
+
|
10587 |
+
var box = Object(_wordpress_element__WEBPACK_IMPORTED_MODULE_0__["createElement"])(_wordpress_primitives__WEBPACK_IMPORTED_MODULE_1__["SVG"], {
|
10588 |
+
xmlns: "http://www.w3.org/2000/svg",
|
10589 |
+
viewBox: "0 0 24 24"
|
10590 |
+
}, Object(_wordpress_element__WEBPACK_IMPORTED_MODULE_0__["createElement"])(_wordpress_primitives__WEBPACK_IMPORTED_MODULE_1__["Path"], {
|
10591 |
+
fillRule: "evenodd",
|
10592 |
+
d: "M5 5.5h14a.5.5 0 01.5.5v1.5a.5.5 0 01-.5.5H5a.5.5 0 01-.5-.5V6a.5.5 0 01.5-.5zM4 9.232A2 2 0 013 7.5V6a2 2 0 012-2h14a2 2 0 012 2v1.5a2 2 0 01-1 1.732V18a2 2 0 01-2 2H6a2 2 0 01-2-2V9.232zm1.5.268V18a.5.5 0 00.5.5h12a.5.5 0 00.5-.5V9.5h-13z",
|
10593 |
+
clipRule: "evenodd"
|
10594 |
+
}));
|
10595 |
+
/* harmony default export */ __webpack_exports__["a"] = (box);
|
10596 |
+
//# sourceMappingURL=box.js.map
|
10597 |
+
|
10598 |
+
/***/ }),
|
10599 |
+
|
10600 |
+
/***/ 502:
|
10601 |
+
/***/ (function(module, __webpack_exports__, __webpack_require__) {
|
10602 |
+
|
10603 |
+
"use strict";
|
10604 |
+
/* harmony import */ var _wordpress_element__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(0);
|
10605 |
+
/* harmony import */ var _wordpress_element__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(_wordpress_element__WEBPACK_IMPORTED_MODULE_0__);
|
10606 |
+
/* harmony import */ var _wordpress_primitives__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(8);
|
10607 |
+
/* harmony import */ var _wordpress_primitives__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(_wordpress_primitives__WEBPACK_IMPORTED_MODULE_1__);
|
10608 |
+
|
10609 |
+
|
10610 |
+
/**
|
10611 |
+
* WordPress dependencies
|
10612 |
+
*/
|
10613 |
+
|
10614 |
+
var external = Object(_wordpress_element__WEBPACK_IMPORTED_MODULE_0__["createElement"])(_wordpress_primitives__WEBPACK_IMPORTED_MODULE_1__["SVG"], {
|
10615 |
+
xmlns: "http://www.w3.org/2000/svg",
|
10616 |
+
viewBox: "0 0 24 24"
|
10617 |
+
}, Object(_wordpress_element__WEBPACK_IMPORTED_MODULE_0__["createElement"])(_wordpress_primitives__WEBPACK_IMPORTED_MODULE_1__["Path"], {
|
10618 |
+
d: "M18.2 17c0 .7-.6 1.2-1.2 1.2H7c-.7 0-1.2-.6-1.2-1.2V7c0-.7.6-1.2 1.2-1.2h3.2V4.2H7C5.5 4.2 4.2 5.5 4.2 7v10c0 1.5 1.2 2.8 2.8 2.8h10c1.5 0 2.8-1.2 2.8-2.8v-3.6h-1.5V17zM14.9 3v1.5h3.7l-6.4 6.4 1.1 1.1 6.4-6.4v3.7h1.5V3h-6.3z"
|
10619 |
+
}));
|
10620 |
+
/* harmony default export */ __webpack_exports__["a"] = (external);
|
10621 |
+
//# sourceMappingURL=external.js.map
|
10622 |
+
|
10623 |
+
/***/ }),
|
10624 |
+
|
10625 |
+
/***/ 52:
|
10626 |
+
/***/ (function(module, __webpack_exports__, __webpack_require__) {
|
10627 |
+
|
10628 |
+
"use strict";
|
10629 |
+
|
10630 |
+
// EXPORTS
|
10631 |
+
__webpack_require__.d(__webpack_exports__, "a", function() { return /* binding */ createBrowserHistory; });
|
10632 |
+
__webpack_require__.d(__webpack_exports__, "c", function() { return /* binding */ createMemoryHistory; });
|
10633 |
+
__webpack_require__.d(__webpack_exports__, "b", function() { return /* binding */ createLocation; });
|
10634 |
+
__webpack_require__.d(__webpack_exports__, "e", function() { return /* binding */ locationsAreEqual; });
|
10635 |
+
__webpack_require__.d(__webpack_exports__, "d", function() { return /* binding */ createPath; });
|
10636 |
+
|
10637 |
+
// UNUSED EXPORTS: createHashHistory, parsePath
|
10638 |
+
|
10639 |
+
// EXTERNAL MODULE: ./node_modules/@babel/runtime/helpers/esm/extends.js
|
10640 |
+
var esm_extends = __webpack_require__(23);
|
10641 |
+
|
10642 |
+
// CONCATENATED MODULE: ./node_modules/resolve-pathname/esm/resolve-pathname.js
|
10643 |
+
function isAbsolute(pathname) {
|
10644 |
+
return pathname.charAt(0) === '/';
|
10645 |
+
}
|
10646 |
+
|
10647 |
+
// About 1.5x faster than the two-arg version of Array#splice()
|
10648 |
+
function spliceOne(list, index) {
|
10649 |
+
for (var i = index, k = i + 1, n = list.length; k < n; i += 1, k += 1) {
|
10650 |
+
list[i] = list[k];
|
10651 |
+
}
|
10652 |
+
|
10653 |
+
list.pop();
|
10654 |
+
}
|
10655 |
+
|
10656 |
+
// This implementation is based heavily on node's url.parse
|
10657 |
+
function resolvePathname(to, from) {
|
10658 |
+
if (from === undefined) from = '';
|
10659 |
+
|
10660 |
+
var toParts = (to && to.split('/')) || [];
|
10661 |
+
var fromParts = (from && from.split('/')) || [];
|
10662 |
+
|
10663 |
+
var isToAbs = to && isAbsolute(to);
|
10664 |
+
var isFromAbs = from && isAbsolute(from);
|
10665 |
+
var mustEndAbs = isToAbs || isFromAbs;
|
10666 |
+
|
10667 |
+
if (to && isAbsolute(to)) {
|
10668 |
+
// to is absolute
|
10669 |
+
fromParts = toParts;
|
10670 |
+
} else if (toParts.length) {
|
10671 |
+
// to is relative, drop the filename
|
10672 |
+
fromParts.pop();
|
10673 |
+
fromParts = fromParts.concat(toParts);
|
10674 |
+
}
|
10675 |
+
|
10676 |
+
if (!fromParts.length) return '/';
|
10677 |
+
|
10678 |
+
var hasTrailingSlash;
|
10679 |
+
if (fromParts.length) {
|
10680 |
+
var last = fromParts[fromParts.length - 1];
|
10681 |
+
hasTrailingSlash = last === '.' || last === '..' || last === '';
|
10682 |
+
} else {
|
10683 |
+
hasTrailingSlash = false;
|
10684 |
+
}
|
10685 |
+
|
10686 |
+
var up = 0;
|
10687 |
+
for (var i = fromParts.length; i >= 0; i--) {
|
10688 |
+
var part = fromParts[i];
|
10689 |
+
|
10690 |
+
if (part === '.') {
|
10691 |
+
spliceOne(fromParts, i);
|
10692 |
+
} else if (part === '..') {
|
10693 |
+
spliceOne(fromParts, i);
|
10694 |
+
up++;
|
10695 |
+
} else if (up) {
|
10696 |
+
spliceOne(fromParts, i);
|
10697 |
+
up--;
|
10698 |
+
}
|
10699 |
+
}
|
10700 |
+
|
10701 |
+
if (!mustEndAbs) for (; up--; up) fromParts.unshift('..');
|
10702 |
+
|
10703 |
+
if (
|
10704 |
+
mustEndAbs &&
|
10705 |
+
fromParts[0] !== '' &&
|
10706 |
+
(!fromParts[0] || !isAbsolute(fromParts[0]))
|
10707 |
+
)
|
10708 |
+
fromParts.unshift('');
|
10709 |
+
|
10710 |
+
var result = fromParts.join('/');
|
10711 |
+
|
10712 |
+
if (hasTrailingSlash && result.substr(-1) !== '/') result += '/';
|
10713 |
+
|
10714 |
+
return result;
|
10715 |
+
}
|
10716 |
+
|
10717 |
+
/* harmony default export */ var resolve_pathname = (resolvePathname);
|
10718 |
+
|
10719 |
+
// CONCATENATED MODULE: ./node_modules/value-equal/esm/value-equal.js
|
10720 |
+
function value_equal_valueOf(obj) {
|
10721 |
+
return obj.valueOf ? obj.valueOf() : Object.prototype.valueOf.call(obj);
|
10722 |
+
}
|
10723 |
+
|
10724 |
+
function valueEqual(a, b) {
|
10725 |
+
// Test for strict equality first.
|
10726 |
+
if (a === b) return true;
|
10727 |
+
|
10728 |
+
// Otherwise, if either of them == null they are not equal.
|
10729 |
+
if (a == null || b == null) return false;
|
10730 |
+
|
10731 |
+
if (Array.isArray(a)) {
|
10732 |
+
return (
|
10733 |
+
Array.isArray(b) &&
|
10734 |
+
a.length === b.length &&
|
10735 |
+
a.every(function(item, index) {
|
10736 |
+
return valueEqual(item, b[index]);
|
10737 |
+
})
|
10738 |
+
);
|
10739 |
+
}
|
10740 |
+
|
10741 |
+
if (typeof a === 'object' || typeof b === 'object') {
|
10742 |
+
var aValue = value_equal_valueOf(a);
|
10743 |
+
var bValue = value_equal_valueOf(b);
|
10744 |
+
|
10745 |
+
if (aValue !== a || bValue !== b) return valueEqual(aValue, bValue);
|
10746 |
+
|
10747 |
+
return Object.keys(Object.assign({}, a, b)).every(function(key) {
|
10748 |
+
return valueEqual(a[key], b[key]);
|
10749 |
+
});
|
10750 |
+
}
|
10751 |
+
|
10752 |
+
return false;
|
10753 |
+
}
|
10754 |
+
|
10755 |
+
/* harmony default export */ var value_equal = (valueEqual);
|
10756 |
+
|
10757 |
+
// EXTERNAL MODULE: ./node_modules/tiny-invariant/dist/tiny-invariant.esm.js
|
10758 |
+
var tiny_invariant_esm = __webpack_require__(43);
|
10759 |
+
|
10760 |
+
// CONCATENATED MODULE: ./node_modules/history/esm/history.js
|
10761 |
+
|
10762 |
+
|
10763 |
+
|
10764 |
+
|
10765 |
+
|
10766 |
+
|
10767 |
+
function addLeadingSlash(path) {
|
10768 |
+
return path.charAt(0) === '/' ? path : '/' + path;
|
10769 |
+
}
|
10770 |
+
function stripLeadingSlash(path) {
|
10771 |
+
return path.charAt(0) === '/' ? path.substr(1) : path;
|
10772 |
+
}
|
10773 |
+
function hasBasename(path, prefix) {
|
10774 |
+
return path.toLowerCase().indexOf(prefix.toLowerCase()) === 0 && '/?#'.indexOf(path.charAt(prefix.length)) !== -1;
|
10775 |
+
}
|
10776 |
+
function stripBasename(path, prefix) {
|
10777 |
+
return hasBasename(path, prefix) ? path.substr(prefix.length) : path;
|
10778 |
+
}
|
10779 |
+
function stripTrailingSlash(path) {
|
10780 |
+
return path.charAt(path.length - 1) === '/' ? path.slice(0, -1) : path;
|
10781 |
+
}
|
10782 |
+
function parsePath(path) {
|
10783 |
+
var pathname = path || '/';
|
10784 |
+
var search = '';
|
10785 |
+
var hash = '';
|
10786 |
+
var hashIndex = pathname.indexOf('#');
|
10787 |
+
|
10788 |
+
if (hashIndex !== -1) {
|
10789 |
+
hash = pathname.substr(hashIndex);
|
10790 |
+
pathname = pathname.substr(0, hashIndex);
|
10791 |
+
}
|
10792 |
+
|
10793 |
+
var searchIndex = pathname.indexOf('?');
|
10794 |
+
|
10795 |
+
if (searchIndex !== -1) {
|
10796 |
+
search = pathname.substr(searchIndex);
|
10797 |
+
pathname = pathname.substr(0, searchIndex);
|
10798 |
+
}
|
10799 |
+
|
10800 |
+
return {
|
10801 |
+
pathname: pathname,
|
10802 |
+
search: search === '?' ? '' : search,
|
10803 |
+
hash: hash === '#' ? '' : hash
|
10804 |
+
};
|
10805 |
+
}
|
10806 |
+
function createPath(location) {
|
10807 |
+
var pathname = location.pathname,
|
10808 |
+
search = location.search,
|
10809 |
+
hash = location.hash;
|
10810 |
+
var path = pathname || '/';
|
10811 |
+
if (search && search !== '?') path += search.charAt(0) === '?' ? search : "?" + search;
|
10812 |
+
if (hash && hash !== '#') path += hash.charAt(0) === '#' ? hash : "#" + hash;
|
10813 |
+
return path;
|
10814 |
+
}
|
10815 |
+
|
10816 |
+
function createLocation(path, state, key, currentLocation) {
|
10817 |
+
var location;
|
10818 |
+
|
10819 |
+
if (typeof path === 'string') {
|
10820 |
+
// Two-arg form: push(path, state)
|
10821 |
+
location = parsePath(path);
|
10822 |
+
location.state = state;
|
10823 |
+
} else {
|
10824 |
+
// One-arg form: push(location)
|
10825 |
+
location = Object(esm_extends["a" /* default */])({}, path);
|
10826 |
+
if (location.pathname === undefined) location.pathname = '';
|
10827 |
+
|
10828 |
+
if (location.search) {
|
10829 |
+
if (location.search.charAt(0) !== '?') location.search = '?' + location.search;
|
10830 |
+
} else {
|
10831 |
+
location.search = '';
|
10832 |
+
}
|
10833 |
+
|
10834 |
+
if (location.hash) {
|
10835 |
+
if (location.hash.charAt(0) !== '#') location.hash = '#' + location.hash;
|
10836 |
+
} else {
|
10837 |
+
location.hash = '';
|
10838 |
+
}
|
10839 |
+
|
10840 |
+
if (state !== undefined && location.state === undefined) location.state = state;
|
10841 |
+
}
|
10842 |
+
|
10843 |
+
try {
|
10844 |
+
location.pathname = decodeURI(location.pathname);
|
10845 |
+
} catch (e) {
|
10846 |
+
if (e instanceof URIError) {
|
10847 |
+
throw new URIError('Pathname "' + location.pathname + '" could not be decoded. ' + 'This is likely caused by an invalid percent-encoding.');
|
10848 |
+
} else {
|
10849 |
+
throw e;
|
10850 |
+
}
|
10851 |
+
}
|
10852 |
+
|
10853 |
+
if (key) location.key = key;
|
10854 |
+
|
10855 |
+
if (currentLocation) {
|
10856 |
+
// Resolve incomplete/relative pathname relative to current location.
|
10857 |
+
if (!location.pathname) {
|
10858 |
+
location.pathname = currentLocation.pathname;
|
10859 |
+
} else if (location.pathname.charAt(0) !== '/') {
|
10860 |
+
location.pathname = resolve_pathname(location.pathname, currentLocation.pathname);
|
10861 |
+
}
|
10862 |
+
} else {
|
10863 |
+
// When there is no prior location and pathname is empty, set it to /
|
10864 |
+
if (!location.pathname) {
|
10865 |
+
location.pathname = '/';
|
10866 |
+
}
|
10867 |
+
}
|
10868 |
+
|
10869 |
+
return location;
|
10870 |
+
}
|
10871 |
+
function locationsAreEqual(a, b) {
|
10872 |
+
return a.pathname === b.pathname && a.search === b.search && a.hash === b.hash && a.key === b.key && value_equal(a.state, b.state);
|
10873 |
+
}
|
10874 |
+
|
10875 |
+
function createTransitionManager() {
|
10876 |
+
var prompt = null;
|
10877 |
+
|
10878 |
+
function setPrompt(nextPrompt) {
|
10879 |
+
false ? undefined : void 0;
|
10880 |
+
prompt = nextPrompt;
|
10881 |
+
return function () {
|
10882 |
+
if (prompt === nextPrompt) prompt = null;
|
10883 |
+
};
|
10884 |
+
}
|
10885 |
+
|
10886 |
+
function confirmTransitionTo(location, action, getUserConfirmation, callback) {
|
10887 |
+
// TODO: If another transition starts while we're still confirming
|
10888 |
+
// the previous one, we may end up in a weird state. Figure out the
|
10889 |
+
// best way to handle this.
|
10890 |
+
if (prompt != null) {
|
10891 |
+
var result = typeof prompt === 'function' ? prompt(location, action) : prompt;
|
10892 |
+
|
10893 |
+
if (typeof result === 'string') {
|
10894 |
+
if (typeof getUserConfirmation === 'function') {
|
10895 |
+
getUserConfirmation(result, callback);
|
10896 |
+
} else {
|
10897 |
+
false ? undefined : void 0;
|
10898 |
+
callback(true);
|
10899 |
+
}
|
10900 |
+
} else {
|
10901 |
+
// Return false from a transition hook to cancel the transition.
|
10902 |
+
callback(result !== false);
|
10903 |
+
}
|
10904 |
+
} else {
|
10905 |
+
callback(true);
|
10906 |
+
}
|
10907 |
+
}
|
10908 |
+
|
10909 |
+
var listeners = [];
|
10910 |
+
|
10911 |
+
function appendListener(fn) {
|
10912 |
+
var isActive = true;
|
10913 |
+
|
10914 |
+
function listener() {
|
10915 |
+
if (isActive) fn.apply(void 0, arguments);
|
10916 |
+
}
|
10917 |
+
|
10918 |
+
listeners.push(listener);
|
10919 |
+
return function () {
|
10920 |
+
isActive = false;
|
10921 |
+
listeners = listeners.filter(function (item) {
|
10922 |
+
return item !== listener;
|
10923 |
+
});
|
10924 |
+
};
|
10925 |
+
}
|
10926 |
+
|
10927 |
+
function notifyListeners() {
|
10928 |
+
for (var _len = arguments.length, args = new Array(_len), _key = 0; _key < _len; _key++) {
|
10929 |
+
args[_key] = arguments[_key];
|
10930 |
+
}
|
10931 |
+
|
10932 |
+
listeners.forEach(function (listener) {
|
10933 |
+
return listener.apply(void 0, args);
|
10934 |
+
});
|
10935 |
+
}
|
10936 |
+
|
10937 |
+
return {
|
10938 |
+
setPrompt: setPrompt,
|
10939 |
+
confirmTransitionTo: confirmTransitionTo,
|
10940 |
+
appendListener: appendListener,
|
10941 |
+
notifyListeners: notifyListeners
|
10942 |
+
};
|
10943 |
+
}
|
10944 |
+
|
10945 |
+
var canUseDOM = !!(typeof window !== 'undefined' && window.document && window.document.createElement);
|
10946 |
+
function getConfirmation(message, callback) {
|
10947 |
+
callback(window.confirm(message)); // eslint-disable-line no-alert
|
10948 |
+
}
|
10949 |
+
/**
|
10950 |
+
* Returns true if the HTML5 history API is supported. Taken from Modernizr.
|
10951 |
+
*
|
10952 |
+
* https://github.com/Modernizr/Modernizr/blob/master/LICENSE
|
10953 |
+
* https://github.com/Modernizr/Modernizr/blob/master/feature-detects/history.js
|
10954 |
+
* changed to avoid false negatives for Windows Phones: https://github.com/reactjs/react-router/issues/586
|
10955 |
+
*/
|
10956 |
+
|
10957 |
+
function supportsHistory() {
|
10958 |
+
var ua = window.navigator.userAgent;
|
10959 |
+
if ((ua.indexOf('Android 2.') !== -1 || ua.indexOf('Android 4.0') !== -1) && ua.indexOf('Mobile Safari') !== -1 && ua.indexOf('Chrome') === -1 && ua.indexOf('Windows Phone') === -1) return false;
|
10960 |
+
return window.history && 'pushState' in window.history;
|
10961 |
+
}
|
10962 |
+
/**
|
10963 |
+
* Returns true if browser fires popstate on hash change.
|
10964 |
+
* IE10 and IE11 do not.
|
10965 |
+
*/
|
10966 |
+
|
10967 |
+
function supportsPopStateOnHashChange() {
|
10968 |
+
return window.navigator.userAgent.indexOf('Trident') === -1;
|
10969 |
+
}
|
10970 |
+
/**
|
10971 |
+
* Returns false if using go(n) with hash history causes a full page reload.
|
10972 |
+
*/
|
10973 |
+
|
10974 |
+
function supportsGoWithoutReloadUsingHash() {
|
10975 |
+
return window.navigator.userAgent.indexOf('Firefox') === -1;
|
10976 |
+
}
|
10977 |
+
/**
|
10978 |
+
* Returns true if a given popstate event is an extraneous WebKit event.
|
10979 |
+
* Accounts for the fact that Chrome on iOS fires real popstate events
|
10980 |
+
* containing undefined state when pressing the back button.
|
10981 |
+
*/
|
10982 |
+
|
10983 |
+
function isExtraneousPopstateEvent(event) {
|
10984 |
+
return event.state === undefined && navigator.userAgent.indexOf('CriOS') === -1;
|
10985 |
+
}
|
10986 |
+
|
10987 |
+
var PopStateEvent = 'popstate';
|
10988 |
+
var HashChangeEvent = 'hashchange';
|
10989 |
+
|
10990 |
+
function getHistoryState() {
|
10991 |
+
try {
|
10992 |
+
return window.history.state || {};
|
10993 |
+
} catch (e) {
|
10994 |
+
// IE 11 sometimes throws when accessing window.history.state
|
10995 |
+
// See https://github.com/ReactTraining/history/pull/289
|
10996 |
+
return {};
|
10997 |
+
}
|
10998 |
+
}
|
10999 |
+
/**
|
11000 |
+
* Creates a history object that uses the HTML5 history API including
|
11001 |
+
* pushState, replaceState, and the popstate event.
|
11002 |
+
*/
|
11003 |
+
|
11004 |
+
|
11005 |
+
function createBrowserHistory(props) {
|
11006 |
+
if (props === void 0) {
|
11007 |
+
props = {};
|
11008 |
+
}
|
11009 |
+
|
11010 |
+
!canUseDOM ? false ? undefined : Object(tiny_invariant_esm["a" /* default */])(false) : void 0;
|
11011 |
+
var globalHistory = window.history;
|
11012 |
+
var canUseHistory = supportsHistory();
|
11013 |
+
var needsHashChangeListener = !supportsPopStateOnHashChange();
|
11014 |
+
var _props = props,
|
11015 |
+
_props$forceRefresh = _props.forceRefresh,
|
11016 |
+
forceRefresh = _props$forceRefresh === void 0 ? false : _props$forceRefresh,
|
11017 |
+
_props$getUserConfirm = _props.getUserConfirmation,
|
11018 |
+
getUserConfirmation = _props$getUserConfirm === void 0 ? getConfirmation : _props$getUserConfirm,
|
11019 |
+
_props$keyLength = _props.keyLength,
|
11020 |
+
keyLength = _props$keyLength === void 0 ? 6 : _props$keyLength;
|
11021 |
+
var basename = props.basename ? stripTrailingSlash(addLeadingSlash(props.basename)) : '';
|
11022 |
+
|
11023 |
+
function getDOMLocation(historyState) {
|
11024 |
+
var _ref = historyState || {},
|
11025 |
+
key = _ref.key,
|
11026 |
+
state = _ref.state;
|
11027 |
+
|
11028 |
+
var _window$location = window.location,
|
11029 |
+
pathname = _window$location.pathname,
|
11030 |
+
search = _window$location.search,
|
11031 |
+
hash = _window$location.hash;
|
11032 |
+
var path = pathname + search + hash;
|
11033 |
+
false ? undefined : void 0;
|
11034 |
+
if (basename) path = stripBasename(path, basename);
|
11035 |
+
return createLocation(path, state, key);
|
11036 |
+
}
|
11037 |
+
|
11038 |
+
function createKey() {
|
11039 |
+
return Math.random().toString(36).substr(2, keyLength);
|
11040 |
+
}
|
11041 |
+
|
11042 |
+
var transitionManager = createTransitionManager();
|
11043 |
+
|
11044 |
+
function setState(nextState) {
|
11045 |
+
Object(esm_extends["a" /* default */])(history, nextState);
|
11046 |
+
|
11047 |
+
history.length = globalHistory.length;
|
11048 |
+
transitionManager.notifyListeners(history.location, history.action);
|
11049 |
+
}
|
11050 |
+
|
11051 |
+
function handlePopState(event) {
|
11052 |
+
// Ignore extraneous popstate events in WebKit.
|
11053 |
+
if (isExtraneousPopstateEvent(event)) return;
|
11054 |
+
handlePop(getDOMLocation(event.state));
|
11055 |
+
}
|
11056 |
+
|
11057 |
+
function handleHashChange() {
|
11058 |
+
handlePop(getDOMLocation(getHistoryState()));
|
11059 |
+
}
|
11060 |
+
|
11061 |
+
var forceNextPop = false;
|
11062 |
+
|
11063 |
+
function handlePop(location) {
|
11064 |
+
if (forceNextPop) {
|
11065 |
+
forceNextPop = false;
|
11066 |
+
setState();
|
11067 |
+
} else {
|
11068 |
+
var action = 'POP';
|
11069 |
+
transitionManager.confirmTransitionTo(location, action, getUserConfirmation, function (ok) {
|
11070 |
+
if (ok) {
|
11071 |
+
setState({
|
11072 |
+
action: action,
|
11073 |
+
location: location
|
11074 |
+
});
|
11075 |
+
} else {
|
11076 |
+
revertPop(location);
|
11077 |
+
}
|
11078 |
+
});
|
11079 |
+
}
|
11080 |
+
}
|
11081 |
+
|
11082 |
+
function revertPop(fromLocation) {
|
11083 |
+
var toLocation = history.location; // TODO: We could probably make this more reliable by
|
11084 |
+
// keeping a list of keys we've seen in sessionStorage.
|
11085 |
+
// Instead, we just default to 0 for keys we don't know.
|
11086 |
+
|
11087 |
+
var toIndex = allKeys.indexOf(toLocation.key);
|
11088 |
+
if (toIndex === -1) toIndex = 0;
|
11089 |
+
var fromIndex = allKeys.indexOf(fromLocation.key);
|
11090 |
+
if (fromIndex === -1) fromIndex = 0;
|
11091 |
+
var delta = toIndex - fromIndex;
|
11092 |
+
|
11093 |
+
if (delta) {
|
11094 |
+
forceNextPop = true;
|
11095 |
+
go(delta);
|
11096 |
+
}
|
11097 |
+
}
|
11098 |
+
|
11099 |
+
var initialLocation = getDOMLocation(getHistoryState());
|
11100 |
+
var allKeys = [initialLocation.key]; // Public interface
|
11101 |
+
|
11102 |
+
function createHref(location) {
|
11103 |
+
return basename + createPath(location);
|
11104 |
+
}
|
11105 |
+
|
11106 |
+
function push(path, state) {
|
11107 |
+
false ? undefined : void 0;
|
11108 |
+
var action = 'PUSH';
|
11109 |
+
var location = createLocation(path, state, createKey(), history.location);
|
11110 |
+
transitionManager.confirmTransitionTo(location, action, getUserConfirmation, function (ok) {
|
11111 |
+
if (!ok) return;
|
11112 |
+
var href = createHref(location);
|
11113 |
+
var key = location.key,
|
11114 |
+
state = location.state;
|
11115 |
+
|
11116 |
+
if (canUseHistory) {
|
11117 |
+
globalHistory.pushState({
|
11118 |
+
key: key,
|
11119 |
+
state: state
|
11120 |
+
}, null, href);
|
11121 |
+
|
11122 |
+
if (forceRefresh) {
|
11123 |
+
window.location.href = href;
|
11124 |
+
} else {
|
11125 |
+
var prevIndex = allKeys.indexOf(history.location.key);
|
11126 |
+
var nextKeys = allKeys.slice(0, prevIndex + 1);
|
11127 |
+
nextKeys.push(location.key);
|
11128 |
+
allKeys = nextKeys;
|
11129 |
+
setState({
|
11130 |
+
action: action,
|
11131 |
+
location: location
|
11132 |
+
});
|
11133 |
+
}
|
11134 |
+
} else {
|
11135 |
+
false ? undefined : void 0;
|
11136 |
+
window.location.href = href;
|
11137 |
+
}
|
11138 |
+
});
|
11139 |
+
}
|
11140 |
+
|
11141 |
+
function replace(path, state) {
|
11142 |
+
false ? undefined : void 0;
|
11143 |
+
var action = 'REPLACE';
|
11144 |
+
var location = createLocation(path, state, createKey(), history.location);
|
11145 |
+
transitionManager.confirmTransitionTo(location, action, getUserConfirmation, function (ok) {
|
11146 |
+
if (!ok) return;
|
11147 |
+
var href = createHref(location);
|
11148 |
+
var key = location.key,
|
11149 |
+
state = location.state;
|
11150 |
+
|
11151 |
+
if (canUseHistory) {
|
11152 |
+
globalHistory.replaceState({
|
11153 |
+
key: key,
|
11154 |
+
state: state
|
11155 |
+
}, null, href);
|
11156 |
+
|
11157 |
+
if (forceRefresh) {
|
11158 |
+
window.location.replace(href);
|
11159 |
+
} else {
|
11160 |
+
var prevIndex = allKeys.indexOf(history.location.key);
|
11161 |
+
if (prevIndex !== -1) allKeys[prevIndex] = location.key;
|
11162 |
+
setState({
|
11163 |
+
action: action,
|
11164 |
+
location: location
|
11165 |
+
});
|
11166 |
+
}
|
11167 |
+
} else {
|
11168 |
+
false ? undefined : void 0;
|
11169 |
+
window.location.replace(href);
|
11170 |
+
}
|
11171 |
+
});
|
11172 |
+
}
|
11173 |
+
|
11174 |
+
function go(n) {
|
11175 |
+
globalHistory.go(n);
|
11176 |
+
}
|
11177 |
+
|
11178 |
+
function goBack() {
|
11179 |
+
go(-1);
|
11180 |
+
}
|
11181 |
+
|
11182 |
+
function goForward() {
|
11183 |
+
go(1);
|
11184 |
+
}
|
11185 |
+
|
11186 |
+
var listenerCount = 0;
|
11187 |
+
|
11188 |
+
function checkDOMListeners(delta) {
|
11189 |
+
listenerCount += delta;
|
11190 |
+
|
11191 |
+
if (listenerCount === 1 && delta === 1) {
|
11192 |
+
window.addEventListener(PopStateEvent, handlePopState);
|
11193 |
+
if (needsHashChangeListener) window.addEventListener(HashChangeEvent, handleHashChange);
|
11194 |
+
} else if (listenerCount === 0) {
|
11195 |
+
window.removeEventListener(PopStateEvent, handlePopState);
|
11196 |
+
if (needsHashChangeListener) window.removeEventListener(HashChangeEvent, handleHashChange);
|
11197 |
+
}
|
11198 |
+
}
|
11199 |
+
|
11200 |
+
var isBlocked = false;
|
11201 |
+
|
11202 |
+
function block(prompt) {
|
11203 |
+
if (prompt === void 0) {
|
11204 |
+
prompt = false;
|
11205 |
+
}
|
11206 |
+
|
11207 |
+
var unblock = transitionManager.setPrompt(prompt);
|
11208 |
+
|
11209 |
+
if (!isBlocked) {
|
11210 |
+
checkDOMListeners(1);
|
11211 |
+
isBlocked = true;
|
11212 |
+
}
|
11213 |
+
|
11214 |
+
return function () {
|
11215 |
+
if (isBlocked) {
|
11216 |
+
isBlocked = false;
|
11217 |
+
checkDOMListeners(-1);
|
11218 |
+
}
|
11219 |
+
|
11220 |
+
return unblock();
|
11221 |
+
};
|
11222 |
+
}
|
11223 |
+
|
11224 |
+
function listen(listener) {
|
11225 |
+
var unlisten = transitionManager.appendListener(listener);
|
11226 |
+
checkDOMListeners(1);
|
11227 |
+
return function () {
|
11228 |
+
checkDOMListeners(-1);
|
11229 |
+
unlisten();
|
11230 |
+
};
|
11231 |
+
}
|
11232 |
+
|
11233 |
+
var history = {
|
11234 |
+
length: globalHistory.length,
|
11235 |
+
action: 'POP',
|
11236 |
+
location: initialLocation,
|
11237 |
+
createHref: createHref,
|
11238 |
+
push: push,
|
11239 |
+
replace: replace,
|
11240 |
+
go: go,
|
11241 |
+
goBack: goBack,
|
11242 |
+
goForward: goForward,
|
11243 |
+
block: block,
|
11244 |
+
listen: listen
|
11245 |
+
};
|
11246 |
+
return history;
|
11247 |
+
}
|
11248 |
+
|
11249 |
+
var HashChangeEvent$1 = 'hashchange';
|
11250 |
+
var HashPathCoders = {
|
11251 |
+
hashbang: {
|
11252 |
+
encodePath: function encodePath(path) {
|
11253 |
+
return path.charAt(0) === '!' ? path : '!/' + stripLeadingSlash(path);
|
11254 |
+
},
|
11255 |
+
decodePath: function decodePath(path) {
|
11256 |
+
return path.charAt(0) === '!' ? path.substr(1) : path;
|
11257 |
+
}
|
11258 |
+
},
|
11259 |
+
noslash: {
|
11260 |
+
encodePath: stripLeadingSlash,
|
11261 |
+
decodePath: addLeadingSlash
|
11262 |
+
},
|
11263 |
+
slash: {
|
11264 |
+
encodePath: addLeadingSlash,
|
11265 |
+
decodePath: addLeadingSlash
|
11266 |
+
}
|
11267 |
+
};
|
11268 |
+
|
11269 |
+
function stripHash(url) {
|
11270 |
+
var hashIndex = url.indexOf('#');
|
11271 |
+
return hashIndex === -1 ? url : url.slice(0, hashIndex);
|
11272 |
+
}
|
11273 |
+
|
11274 |
+
function getHashPath() {
|
11275 |
+
// We can't use window.location.hash here because it's not
|
11276 |
+
// consistent across browsers - Firefox will pre-decode it!
|
11277 |
+
var href = window.location.href;
|
11278 |
+
var hashIndex = href.indexOf('#');
|
11279 |
+
return hashIndex === -1 ? '' : href.substring(hashIndex + 1);
|
11280 |
+
}
|
11281 |
+
|
11282 |
+
function pushHashPath(path) {
|
11283 |
+
window.location.hash = path;
|
11284 |
+
}
|
11285 |
+
|
11286 |
+
function replaceHashPath(path) {
|
11287 |
+
window.location.replace(stripHash(window.location.href) + '#' + path);
|
11288 |
+
}
|
11289 |
+
|
11290 |
+
function createHashHistory(props) {
|
11291 |
+
if (props === void 0) {
|
11292 |
+
props = {};
|
11293 |
+
}
|
11294 |
+
|
11295 |
+
!canUseDOM ? false ? undefined : Object(tiny_invariant_esm["a" /* default */])(false) : void 0;
|
11296 |
+
var globalHistory = window.history;
|
11297 |
+
var canGoWithoutReload = supportsGoWithoutReloadUsingHash();
|
11298 |
+
var _props = props,
|
11299 |
+
_props$getUserConfirm = _props.getUserConfirmation,
|
11300 |
+
getUserConfirmation = _props$getUserConfirm === void 0 ? getConfirmation : _props$getUserConfirm,
|
11301 |
+
_props$hashType = _props.hashType,
|
11302 |
+
hashType = _props$hashType === void 0 ? 'slash' : _props$hashType;
|
11303 |
+
var basename = props.basename ? stripTrailingSlash(addLeadingSlash(props.basename)) : '';
|
11304 |
+
var _HashPathCoders$hashT = HashPathCoders[hashType],
|
11305 |
+
encodePath = _HashPathCoders$hashT.encodePath,
|
11306 |
+
decodePath = _HashPathCoders$hashT.decodePath;
|
11307 |
+
|
11308 |
+
function getDOMLocation() {
|
11309 |
+
var path = decodePath(getHashPath());
|
11310 |
+
false ? undefined : void 0;
|
11311 |
+
if (basename) path = stripBasename(path, basename);
|
11312 |
+
return createLocation(path);
|
11313 |
+
}
|
11314 |
+
|
11315 |
+
var transitionManager = createTransitionManager();
|
11316 |
+
|
11317 |
+
function setState(nextState) {
|
11318 |
+
Object(esm_extends["a" /* default */])(history, nextState);
|
11319 |
+
|
11320 |
+
history.length = globalHistory.length;
|
11321 |
+
transitionManager.notifyListeners(history.location, history.action);
|
11322 |
+
}
|
11323 |
+
|
11324 |
+
var forceNextPop = false;
|
11325 |
+
var ignorePath = null;
|
11326 |
+
|
11327 |
+
function locationsAreEqual$$1(a, b) {
|
11328 |
+
return a.pathname === b.pathname && a.search === b.search && a.hash === b.hash;
|
11329 |
+
}
|
11330 |
+
|
11331 |
+
function handleHashChange() {
|
11332 |
+
var path = getHashPath();
|
11333 |
+
var encodedPath = encodePath(path);
|
11334 |
+
|
11335 |
+
if (path !== encodedPath) {
|
11336 |
+
// Ensure we always have a properly-encoded hash.
|
11337 |
+
replaceHashPath(encodedPath);
|
11338 |
+
} else {
|
11339 |
+
var location = getDOMLocation();
|
11340 |
+
var prevLocation = history.location;
|
11341 |
+
if (!forceNextPop && locationsAreEqual$$1(prevLocation, location)) return; // A hashchange doesn't always == location change.
|
11342 |
+
|
11343 |
+
if (ignorePath === createPath(location)) return; // Ignore this change; we already setState in push/replace.
|
11344 |
+
|
11345 |
+
ignorePath = null;
|
11346 |
+
handlePop(location);
|
11347 |
+
}
|
11348 |
+
}
|
11349 |
+
|
11350 |
+
function handlePop(location) {
|
11351 |
+
if (forceNextPop) {
|
11352 |
+
forceNextPop = false;
|
11353 |
+
setState();
|
11354 |
+
} else {
|
11355 |
+
var action = 'POP';
|
11356 |
+
transitionManager.confirmTransitionTo(location, action, getUserConfirmation, function (ok) {
|
11357 |
+
if (ok) {
|
11358 |
+
setState({
|
11359 |
+
action: action,
|
11360 |
+
location: location
|
11361 |
+
});
|
11362 |
+
} else {
|
11363 |
+
revertPop(location);
|
11364 |
+
}
|
11365 |
+
});
|
11366 |
+
}
|
11367 |
+
}
|
11368 |
+
|
11369 |
+
function revertPop(fromLocation) {
|
11370 |
+
var toLocation = history.location; // TODO: We could probably make this more reliable by
|
11371 |
+
// keeping a list of paths we've seen in sessionStorage.
|
11372 |
+
// Instead, we just default to 0 for paths we don't know.
|
11373 |
+
|
11374 |
+
var toIndex = allPaths.lastIndexOf(createPath(toLocation));
|
11375 |
+
if (toIndex === -1) toIndex = 0;
|
11376 |
+
var fromIndex = allPaths.lastIndexOf(createPath(fromLocation));
|
11377 |
+
if (fromIndex === -1) fromIndex = 0;
|
11378 |
+
var delta = toIndex - fromIndex;
|
11379 |
+
|
11380 |
+
if (delta) {
|
11381 |
+
forceNextPop = true;
|
11382 |
+
go(delta);
|
11383 |
+
}
|
11384 |
+
} // Ensure the hash is encoded properly before doing anything else.
|
11385 |
+
|
11386 |
+
|
11387 |
+
var path = getHashPath();
|
11388 |
+
var encodedPath = encodePath(path);
|
11389 |
+
if (path !== encodedPath) replaceHashPath(encodedPath);
|
11390 |
+
var initialLocation = getDOMLocation();
|
11391 |
+
var allPaths = [createPath(initialLocation)]; // Public interface
|
11392 |
+
|
11393 |
+
function createHref(location) {
|
11394 |
+
var baseTag = document.querySelector('base');
|
11395 |
+
var href = '';
|
11396 |
+
|
11397 |
+
if (baseTag && baseTag.getAttribute('href')) {
|
11398 |
+
href = stripHash(window.location.href);
|
11399 |
+
}
|
11400 |
+
|
11401 |
+
return href + '#' + encodePath(basename + createPath(location));
|
11402 |
+
}
|
11403 |
+
|
11404 |
+
function push(path, state) {
|
11405 |
+
false ? undefined : void 0;
|
11406 |
+
var action = 'PUSH';
|
11407 |
+
var location = createLocation(path, undefined, undefined, history.location);
|
11408 |
+
transitionManager.confirmTransitionTo(location, action, getUserConfirmation, function (ok) {
|
11409 |
+
if (!ok) return;
|
11410 |
+
var path = createPath(location);
|
11411 |
+
var encodedPath = encodePath(basename + path);
|
11412 |
+
var hashChanged = getHashPath() !== encodedPath;
|
11413 |
+
|
11414 |
+
if (hashChanged) {
|
11415 |
+
// We cannot tell if a hashchange was caused by a PUSH, so we'd
|
11416 |
+
// rather setState here and ignore the hashchange. The caveat here
|
11417 |
+
// is that other hash histories in the page will consider it a POP.
|
11418 |
+
ignorePath = path;
|
11419 |
+
pushHashPath(encodedPath);
|
11420 |
+
var prevIndex = allPaths.lastIndexOf(createPath(history.location));
|
11421 |
+
var nextPaths = allPaths.slice(0, prevIndex + 1);
|
11422 |
+
nextPaths.push(path);
|
11423 |
+
allPaths = nextPaths;
|
11424 |
+
setState({
|
11425 |
+
action: action,
|
11426 |
+
location: location
|
11427 |
+
});
|
11428 |
+
} else {
|
11429 |
+
false ? undefined : void 0;
|
11430 |
+
setState();
|
11431 |
+
}
|
11432 |
+
});
|
11433 |
+
}
|
11434 |
+
|
11435 |
+
function replace(path, state) {
|
11436 |
+
false ? undefined : void 0;
|
11437 |
+
var action = 'REPLACE';
|
11438 |
+
var location = createLocation(path, undefined, undefined, history.location);
|
11439 |
+
transitionManager.confirmTransitionTo(location, action, getUserConfirmation, function (ok) {
|
11440 |
+
if (!ok) return;
|
11441 |
+
var path = createPath(location);
|
11442 |
+
var encodedPath = encodePath(basename + path);
|
11443 |
+
var hashChanged = getHashPath() !== encodedPath;
|
11444 |
+
|
11445 |
+
if (hashChanged) {
|
11446 |
+
// We cannot tell if a hashchange was caused by a REPLACE, so we'd
|
11447 |
+
// rather setState here and ignore the hashchange. The caveat here
|
11448 |
+
// is that other hash histories in the page will consider it a POP.
|
11449 |
+
ignorePath = path;
|
11450 |
+
replaceHashPath(encodedPath);
|
11451 |
+
}
|
11452 |
+
|
11453 |
+
var prevIndex = allPaths.indexOf(createPath(history.location));
|
11454 |
+
if (prevIndex !== -1) allPaths[prevIndex] = path;
|
11455 |
+
setState({
|
11456 |
+
action: action,
|
11457 |
+
location: location
|
11458 |
+
});
|
11459 |
+
});
|
11460 |
+
}
|
11461 |
+
|
11462 |
+
function go(n) {
|
11463 |
+
false ? undefined : void 0;
|
11464 |
+
globalHistory.go(n);
|
11465 |
+
}
|
11466 |
+
|
11467 |
+
function goBack() {
|
11468 |
+
go(-1);
|
11469 |
+
}
|
11470 |
+
|
11471 |
+
function goForward() {
|
11472 |
+
go(1);
|
11473 |
+
}
|
11474 |
+
|
11475 |
+
var listenerCount = 0;
|
11476 |
+
|
11477 |
+
function checkDOMListeners(delta) {
|
11478 |
+
listenerCount += delta;
|
11479 |
+
|
11480 |
+
if (listenerCount === 1 && delta === 1) {
|
11481 |
+
window.addEventListener(HashChangeEvent$1, handleHashChange);
|
11482 |
+
} else if (listenerCount === 0) {
|
11483 |
+
window.removeEventListener(HashChangeEvent$1, handleHashChange);
|
11484 |
+
}
|
11485 |
+
}
|
11486 |
+
|
11487 |
+
var isBlocked = false;
|
11488 |
+
|
11489 |
+
function block(prompt) {
|
11490 |
+
if (prompt === void 0) {
|
11491 |
+
prompt = false;
|
11492 |
+
}
|
11493 |
+
|
11494 |
+
var unblock = transitionManager.setPrompt(prompt);
|
11495 |
+
|
11496 |
+
if (!isBlocked) {
|
11497 |
+
checkDOMListeners(1);
|
11498 |
+
isBlocked = true;
|
11499 |
+
}
|
11500 |
+
|
11501 |
+
return function () {
|
11502 |
+
if (isBlocked) {
|
11503 |
+
isBlocked = false;
|
11504 |
+
checkDOMListeners(-1);
|
11505 |
+
}
|
11506 |
+
|
11507 |
+
return unblock();
|
11508 |
+
};
|
11509 |
+
}
|
11510 |
+
|
11511 |
+
function listen(listener) {
|
11512 |
+
var unlisten = transitionManager.appendListener(listener);
|
11513 |
+
checkDOMListeners(1);
|
11514 |
+
return function () {
|
11515 |
+
checkDOMListeners(-1);
|
11516 |
+
unlisten();
|
11517 |
+
};
|
11518 |
+
}
|
11519 |
+
|
11520 |
+
var history = {
|
11521 |
+
length: globalHistory.length,
|
11522 |
+
action: 'POP',
|
11523 |
+
location: initialLocation,
|
11524 |
+
createHref: createHref,
|
11525 |
+
push: push,
|
11526 |
+
replace: replace,
|
11527 |
+
go: go,
|
11528 |
+
goBack: goBack,
|
11529 |
+
goForward: goForward,
|
11530 |
+
block: block,
|
11531 |
+
listen: listen
|
11532 |
+
};
|
11533 |
+
return history;
|
11534 |
+
}
|
11535 |
+
|
11536 |
+
function clamp(n, lowerBound, upperBound) {
|
11537 |
+
return Math.min(Math.max(n, lowerBound), upperBound);
|
11538 |
+
}
|
11539 |
+
/**
|
11540 |
+
* Creates a history object that stores locations in memory.
|
11541 |
+
*/
|
11542 |
+
|
11543 |
+
|
11544 |
+
function createMemoryHistory(props) {
|
11545 |
+
if (props === void 0) {
|
11546 |
+
props = {};
|
11547 |
+
}
|
11548 |
+
|
11549 |
+
var _props = props,
|
11550 |
+
getUserConfirmation = _props.getUserConfirmation,
|
11551 |
+
_props$initialEntries = _props.initialEntries,
|
11552 |
+
initialEntries = _props$initialEntries === void 0 ? ['/'] : _props$initialEntries,
|
11553 |
+
_props$initialIndex = _props.initialIndex,
|
11554 |
+
initialIndex = _props$initialIndex === void 0 ? 0 : _props$initialIndex,
|
11555 |
+
_props$keyLength = _props.keyLength,
|
11556 |
+
keyLength = _props$keyLength === void 0 ? 6 : _props$keyLength;
|
11557 |
+
var transitionManager = createTransitionManager();
|
11558 |
+
|
11559 |
+
function setState(nextState) {
|
11560 |
+
Object(esm_extends["a" /* default */])(history, nextState);
|
11561 |
+
|
11562 |
+
history.length = history.entries.length;
|
11563 |
+
transitionManager.notifyListeners(history.location, history.action);
|
11564 |
+
}
|
11565 |
+
|
11566 |
+
function createKey() {
|
11567 |
+
return Math.random().toString(36).substr(2, keyLength);
|
11568 |
+
}
|
11569 |
+
|
11570 |
+
var index = clamp(initialIndex, 0, initialEntries.length - 1);
|
11571 |
+
var entries = initialEntries.map(function (entry) {
|
11572 |
+
return typeof entry === 'string' ? createLocation(entry, undefined, createKey()) : createLocation(entry, undefined, entry.key || createKey());
|
11573 |
+
}); // Public interface
|
11574 |
+
|
11575 |
+
var createHref = createPath;
|
11576 |
+
|
11577 |
+
function push(path, state) {
|
11578 |
+
false ? undefined : void 0;
|
11579 |
+
var action = 'PUSH';
|
11580 |
+
var location = createLocation(path, state, createKey(), history.location);
|
11581 |
+
transitionManager.confirmTransitionTo(location, action, getUserConfirmation, function (ok) {
|
11582 |
+
if (!ok) return;
|
11583 |
+
var prevIndex = history.index;
|
11584 |
+
var nextIndex = prevIndex + 1;
|
11585 |
+
var nextEntries = history.entries.slice(0);
|
11586 |
+
|
11587 |
+
if (nextEntries.length > nextIndex) {
|
11588 |
+
nextEntries.splice(nextIndex, nextEntries.length - nextIndex, location);
|
11589 |
+
} else {
|
11590 |
+
nextEntries.push(location);
|
11591 |
+
}
|
11592 |
+
|
11593 |
+
setState({
|
11594 |
+
action: action,
|
11595 |
+
location: location,
|
11596 |
+
index: nextIndex,
|
11597 |
+
entries: nextEntries
|
11598 |
+
});
|
11599 |
+
});
|
11600 |
+
}
|
11601 |
+
|
11602 |
+
function replace(path, state) {
|
11603 |
+
false ? undefined : void 0;
|
11604 |
+
var action = 'REPLACE';
|
11605 |
+
var location = createLocation(path, state, createKey(), history.location);
|
11606 |
+
transitionManager.confirmTransitionTo(location, action, getUserConfirmation, function (ok) {
|
11607 |
+
if (!ok) return;
|
11608 |
+
history.entries[history.index] = location;
|
11609 |
+
setState({
|
11610 |
+
action: action,
|
11611 |
+
location: location
|
11612 |
+
});
|
11613 |
+
});
|
11614 |
+
}
|
11615 |
+
|
11616 |
+
function go(n) {
|
11617 |
+
var nextIndex = clamp(history.index + n, 0, history.entries.length - 1);
|
11618 |
+
var action = 'POP';
|
11619 |
+
var location = history.entries[nextIndex];
|
11620 |
+
transitionManager.confirmTransitionTo(location, action, getUserConfirmation, function (ok) {
|
11621 |
+
if (ok) {
|
11622 |
+
setState({
|
11623 |
+
action: action,
|
11624 |
+
location: location,
|
11625 |
+
index: nextIndex
|
11626 |
+
});
|
11627 |
+
} else {
|
11628 |
+
// Mimic the behavior of DOM histories by
|
11629 |
+
// causing a render after a cancelled POP.
|
11630 |
+
setState();
|
11631 |
+
}
|
11632 |
+
});
|
11633 |
+
}
|
11634 |
+
|
11635 |
+
function goBack() {
|
11636 |
+
go(-1);
|
11637 |
+
}
|
11638 |
+
|
11639 |
+
function goForward() {
|
11640 |
+
go(1);
|
11641 |
+
}
|
11642 |
+
|
11643 |
+
function canGo(n) {
|
11644 |
+
var nextIndex = history.index + n;
|
11645 |
+
return nextIndex >= 0 && nextIndex < history.entries.length;
|
11646 |
+
}
|
11647 |
+
|
11648 |
+
function block(prompt) {
|
11649 |
+
if (prompt === void 0) {
|
11650 |
+
prompt = false;
|
11651 |
+
}
|
11652 |
+
|
11653 |
+
return transitionManager.setPrompt(prompt);
|
11654 |
+
}
|
11655 |
+
|
11656 |
+
function listen(listener) {
|
11657 |
+
return transitionManager.appendListener(listener);
|
11658 |
+
}
|
11659 |
+
|
11660 |
+
var history = {
|
11661 |
+
length: entries.length,
|
11662 |
+
action: 'POP',
|
11663 |
+
location: entries[index],
|
11664 |
+
index: index,
|
11665 |
+
entries: entries,
|
11666 |
+
createHref: createHref,
|
11667 |
+
push: push,
|
11668 |
+
replace: replace,
|
11669 |
+
go: go,
|
11670 |
+
goBack: goBack,
|
11671 |
+
goForward: goForward,
|
11672 |
+
canGo: canGo,
|
11673 |
+
block: block,
|
11674 |
+
listen: listen
|
11675 |
+
};
|
11676 |
+
return history;
|
11677 |
+
}
|
11678 |
+
|
11679 |
+
|
11680 |
+
|
11681 |
+
|
11682 |
+
/***/ }),
|
11683 |
+
|
11684 |
+
/***/ 55:
|
11685 |
+
/***/ (function(module, __webpack_exports__, __webpack_require__) {
|
11686 |
+
|
11687 |
+
"use strict";
|
11688 |
+
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "c", function() { return STORE_KEY; });
|
11689 |
+
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "a", function() { return API_NAMESPACE; });
|
11690 |
+
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "b", function() { return QUEUE_OPTION_NAME; });
|
11691 |
+
const STORE_KEY = 'wc/customer-effort-score';
|
11692 |
+
const API_NAMESPACE = '/wc-admin';
|
11693 |
+
const QUEUE_OPTION_NAME = 'woocommerce_ces_tracks_queue';
|
11694 |
+
|
11695 |
+
/***/ }),
|
11696 |
+
|
11697 |
+
/***/ 56:
|
11698 |
+
/***/ (function(module, exports, __webpack_require__) {
|
11699 |
+
|
11700 |
+
"use strict";
|
11701 |
+
|
11702 |
+
|
11703 |
+
var utils = __webpack_require__(41);
|
11704 |
+
var formats = __webpack_require__(35);
|
11705 |
+
var has = Object.prototype.hasOwnProperty;
|
11706 |
+
|
11707 |
+
var arrayPrefixGenerators = {
|
11708 |
+
brackets: function brackets(prefix) {
|
11709 |
+
return prefix + '[]';
|
11710 |
+
},
|
11711 |
+
comma: 'comma',
|
11712 |
+
indices: function indices(prefix, key) {
|
11713 |
+
return prefix + '[' + key + ']';
|
11714 |
+
},
|
11715 |
+
repeat: function repeat(prefix) {
|
11716 |
+
return prefix;
|
11717 |
+
}
|
11718 |
+
};
|
11719 |
+
|
11720 |
+
var isArray = Array.isArray;
|
11721 |
+
var push = Array.prototype.push;
|
11722 |
+
var pushToArray = function (arr, valueOrArray) {
|
11723 |
+
push.apply(arr, isArray(valueOrArray) ? valueOrArray : [valueOrArray]);
|
11724 |
+
};
|
11725 |
+
|
11726 |
+
var toISO = Date.prototype.toISOString;
|
11727 |
+
|
11728 |
+
var defaultFormat = formats['default'];
|
11729 |
+
var defaults = {
|
11730 |
+
addQueryPrefix: false,
|
11731 |
+
allowDots: false,
|
11732 |
+
charset: 'utf-8',
|
11733 |
+
charsetSentinel: false,
|
11734 |
+
delimiter: '&',
|
11735 |
+
encode: true,
|
11736 |
+
encoder: utils.encode,
|
11737 |
+
encodeValuesOnly: false,
|
11738 |
+
format: defaultFormat,
|
11739 |
+
formatter: formats.formatters[defaultFormat],
|
11740 |
+
// deprecated
|
11741 |
+
indices: false,
|
11742 |
+
serializeDate: function serializeDate(date) {
|
11743 |
+
return toISO.call(date);
|
11744 |
+
},
|
11745 |
+
skipNulls: false,
|
11746 |
+
strictNullHandling: false
|
11747 |
+
};
|
11748 |
+
|
11749 |
+
var isNonNullishPrimitive = function isNonNullishPrimitive(v) {
|
11750 |
+
return typeof v === 'string'
|
11751 |
+
|| typeof v === 'number'
|
11752 |
+
|| typeof v === 'boolean'
|
11753 |
+
|| typeof v === 'symbol'
|
11754 |
+
|| typeof v === 'bigint';
|
11755 |
+
};
|
11756 |
+
|
11757 |
+
var stringify = function stringify(
|
11758 |
+
object,
|
11759 |
+
prefix,
|
11760 |
+
generateArrayPrefix,
|
11761 |
+
strictNullHandling,
|
11762 |
+
skipNulls,
|
11763 |
+
encoder,
|
11764 |
+
filter,
|
11765 |
+
sort,
|
11766 |
+
allowDots,
|
11767 |
+
serializeDate,
|
11768 |
+
format,
|
11769 |
+
formatter,
|
11770 |
+
encodeValuesOnly,
|
11771 |
+
charset
|
11772 |
+
) {
|
11773 |
+
var obj = object;
|
11774 |
+
if (typeof filter === 'function') {
|
11775 |
+
obj = filter(prefix, obj);
|
11776 |
+
} else if (obj instanceof Date) {
|
11777 |
+
obj = serializeDate(obj);
|
11778 |
+
} else if (generateArrayPrefix === 'comma' && isArray(obj)) {
|
11779 |
+
obj = utils.maybeMap(obj, function (value) {
|
11780 |
+
if (value instanceof Date) {
|
11781 |
+
return serializeDate(value);
|
11782 |
+
}
|
11783 |
+
return value;
|
11784 |
+
});
|
11785 |
+
}
|
11786 |
+
|
11787 |
+
if (obj === null) {
|
11788 |
+
if (strictNullHandling) {
|
11789 |
+
return encoder && !encodeValuesOnly ? encoder(prefix, defaults.encoder, charset, 'key', format) : prefix;
|
11790 |
+
}
|
11791 |
+
|
11792 |
+
obj = '';
|
11793 |
+
}
|
11794 |
+
|
11795 |
+
if (isNonNullishPrimitive(obj) || utils.isBuffer(obj)) {
|
11796 |
+
if (encoder) {
|
11797 |
+
var keyValue = encodeValuesOnly ? prefix : encoder(prefix, defaults.encoder, charset, 'key', format);
|
11798 |
+
return [formatter(keyValue) + '=' + formatter(encoder(obj, defaults.encoder, charset, 'value', format))];
|
11799 |
+
}
|
11800 |
+
return [formatter(prefix) + '=' + formatter(String(obj))];
|
11801 |
+
}
|
11802 |
+
|
11803 |
+
var values = [];
|
11804 |
+
|
11805 |
+
if (typeof obj === 'undefined') {
|
11806 |
+
return values;
|
11807 |
+
}
|
11808 |
+
|
11809 |
+
var objKeys;
|
11810 |
+
if (generateArrayPrefix === 'comma' && isArray(obj)) {
|
11811 |
+
// we need to join elements in
|
11812 |
+
objKeys = [{ value: obj.length > 0 ? obj.join(',') || null : undefined }];
|
11813 |
+
} else if (isArray(filter)) {
|
11814 |
+
objKeys = filter;
|
11815 |
+
} else {
|
11816 |
+
var keys = Object.keys(obj);
|
11817 |
+
objKeys = sort ? keys.sort(sort) : keys;
|
11818 |
+
}
|
11819 |
+
|
11820 |
+
for (var i = 0; i < objKeys.length; ++i) {
|
11821 |
+
var key = objKeys[i];
|
11822 |
+
var value = typeof key === 'object' && key.value !== undefined ? key.value : obj[key];
|
11823 |
+
|
11824 |
+
if (skipNulls && value === null) {
|
11825 |
+
continue;
|
11826 |
+
}
|
11827 |
+
|
11828 |
+
var keyPrefix = isArray(obj)
|
11829 |
+
? typeof generateArrayPrefix === 'function' ? generateArrayPrefix(prefix, key) : prefix
|
11830 |
+
: prefix + (allowDots ? '.' + key : '[' + key + ']');
|
11831 |
+
|
11832 |
+
pushToArray(values, stringify(
|
11833 |
+
value,
|
11834 |
+
keyPrefix,
|
11835 |
+
generateArrayPrefix,
|
11836 |
+
strictNullHandling,
|
11837 |
+
skipNulls,
|
11838 |
+
encoder,
|
11839 |
+
filter,
|
11840 |
+
sort,
|
11841 |
+
allowDots,
|
11842 |
+
serializeDate,
|
11843 |
+
format,
|
11844 |
+
formatter,
|
11845 |
+
encodeValuesOnly,
|
11846 |
+
charset
|
11847 |
+
));
|
11848 |
+
}
|
11849 |
+
|
11850 |
+
return values;
|
11851 |
+
};
|
11852 |
+
|
11853 |
+
var normalizeStringifyOptions = function normalizeStringifyOptions(opts) {
|
11854 |
+
if (!opts) {
|
11855 |
+
return defaults;
|
11856 |
+
}
|
11857 |
+
|
11858 |
+
if (opts.encoder !== null && opts.encoder !== undefined && typeof opts.encoder !== 'function') {
|
11859 |
+
throw new TypeError('Encoder has to be a function.');
|
11860 |
+
}
|
11861 |
+
|
11862 |
+
var charset = opts.charset || defaults.charset;
|
11863 |
+
if (typeof opts.charset !== 'undefined' && opts.charset !== 'utf-8' && opts.charset !== 'iso-8859-1') {
|
11864 |
+
throw new TypeError('The charset option must be either utf-8, iso-8859-1, or undefined');
|
11865 |
+
}
|
11866 |
+
|
11867 |
+
var format = formats['default'];
|
11868 |
+
if (typeof opts.format !== 'undefined') {
|
11869 |
+
if (!has.call(formats.formatters, opts.format)) {
|
11870 |
+
throw new TypeError('Unknown format option provided.');
|
11871 |
+
}
|
11872 |
+
format = opts.format;
|
11873 |
+
}
|
11874 |
+
var formatter = formats.formatters[format];
|
11875 |
+
|
11876 |
+
var filter = defaults.filter;
|
11877 |
+
if (typeof opts.filter === 'function' || isArray(opts.filter)) {
|
11878 |
+
filter = opts.filter;
|
11879 |
+
}
|
11880 |
+
|
11881 |
+
return {
|
11882 |
+
addQueryPrefix: typeof opts.addQueryPrefix === 'boolean' ? opts.addQueryPrefix : defaults.addQueryPrefix,
|
11883 |
+
allowDots: typeof opts.allowDots === 'undefined' ? defaults.allowDots : !!opts.allowDots,
|
11884 |
+
charset: charset,
|
11885 |
+
charsetSentinel: typeof opts.charsetSentinel === 'boolean' ? opts.charsetSentinel : defaults.charsetSentinel,
|
11886 |
+
delimiter: typeof opts.delimiter === 'undefined' ? defaults.delimiter : opts.delimiter,
|
11887 |
+
encode: typeof opts.encode === 'boolean' ? opts.encode : defaults.encode,
|
11888 |
+
encoder: typeof opts.encoder === 'function' ? opts.encoder : defaults.encoder,
|
11889 |
+
encodeValuesOnly: typeof opts.encodeValuesOnly === 'boolean' ? opts.encodeValuesOnly : defaults.encodeValuesOnly,
|
11890 |
+
filter: filter,
|
11891 |
+
format: format,
|
11892 |
+
formatter: formatter,
|
11893 |
+
serializeDate: typeof opts.serializeDate === 'function' ? opts.serializeDate : defaults.serializeDate,
|
11894 |
+
skipNulls: typeof opts.skipNulls === 'boolean' ? opts.skipNulls : defaults.skipNulls,
|
11895 |
+
sort: typeof opts.sort === 'function' ? opts.sort : null,
|
11896 |
+
strictNullHandling: typeof opts.strictNullHandling === 'boolean' ? opts.strictNullHandling : defaults.strictNullHandling
|
11897 |
+
};
|
11898 |
+
};
|
11899 |
+
|
11900 |
+
module.exports = function (object, opts) {
|
11901 |
+
var obj = object;
|
11902 |
+
var options = normalizeStringifyOptions(opts);
|
11903 |
+
|
11904 |
+
var objKeys;
|
11905 |
+
var filter;
|
11906 |
+
|
11907 |
+
if (typeof options.filter === 'function') {
|
11908 |
+
filter = options.filter;
|
11909 |
+
obj = filter('', obj);
|
11910 |
+
} else if (isArray(options.filter)) {
|
11911 |
+
filter = options.filter;
|
11912 |
+
objKeys = filter;
|
11913 |
+
}
|
11914 |
+
|
11915 |
+
var keys = [];
|
11916 |
+
|
11917 |
+
if (typeof obj !== 'object' || obj === null) {
|
11918 |
+
return '';
|
11919 |
+
}
|
11920 |
+
|
11921 |
+
var arrayFormat;
|
11922 |
+
if (opts && opts.arrayFormat in arrayPrefixGenerators) {
|
11923 |
+
arrayFormat = opts.arrayFormat;
|
11924 |
+
} else if (opts && 'indices' in opts) {
|
11925 |
+
arrayFormat = opts.indices ? 'indices' : 'repeat';
|
11926 |
+
} else {
|
11927 |
+
arrayFormat = 'indices';
|
11928 |
+
}
|
11929 |
+
|
11930 |
+
var generateArrayPrefix = arrayPrefixGenerators[arrayFormat];
|
11931 |
+
|
11932 |
+
if (!objKeys) {
|
11933 |
+
objKeys = Object.keys(obj);
|
11934 |
+
}
|
11935 |
+
|
11936 |
+
if (options.sort) {
|
11937 |
+
objKeys.sort(options.sort);
|
11938 |
+
}
|
11939 |
+
|
11940 |
+
for (var i = 0; i < objKeys.length; ++i) {
|
11941 |
+
var key = objKeys[i];
|
11942 |
+
|
11943 |
+
if (options.skipNulls && obj[key] === null) {
|
11944 |
+
continue;
|
11945 |
+
}
|
11946 |
+
pushToArray(keys, stringify(
|
11947 |
+
obj[key],
|
11948 |
+
key,
|
11949 |
+
generateArrayPrefix,
|
11950 |
+
options.strictNullHandling,
|
11951 |
+
options.skipNulls,
|
11952 |
+
options.encode ? options.encoder : null,
|
11953 |
+
options.filter,
|
11954 |
+
options.sort,
|
11955 |
+
options.allowDots,
|
11956 |
+
options.serializeDate,
|
11957 |
+
options.format,
|
11958 |
+
options.formatter,
|
11959 |
+
options.encodeValuesOnly,
|
11960 |
+
options.charset
|
11961 |
+
));
|
11962 |
+
}
|
11963 |
+
|
11964 |
+
var joined = keys.join(options.delimiter);
|
11965 |
+
var prefix = options.addQueryPrefix === true ? '?' : '';
|
11966 |
+
|
11967 |
+
if (options.charsetSentinel) {
|
11968 |
+
if (options.charset === 'iso-8859-1') {
|
11969 |
+
// encodeURIComponent('✓'), the "numeric entity" representation of a checkmark
|
11970 |
+
prefix += 'utf8=%26%2310003%3B&';
|
11971 |
+
} else {
|
11972 |
+
// encodeURIComponent('✓')
|
11973 |
+
prefix += 'utf8=%E2%9C%93&';
|
11974 |
+
}
|
11975 |
+
}
|
11976 |
+
|
11977 |
+
return joined.length > 0 ? prefix + joined : '';
|
11978 |
+
};
|
11979 |
+
|
11980 |
+
|
11981 |
+
/***/ }),
|
11982 |
+
|
11983 |
+
/***/ 57:
|
11984 |
+
/***/ (function(module, exports, __webpack_require__) {
|
11985 |
+
|
11986 |
+
"use strict";
|
11987 |
+
|
11988 |
+
|
11989 |
+
var utils = __webpack_require__(41);
|
11990 |
+
|
11991 |
+
var has = Object.prototype.hasOwnProperty;
|
11992 |
+
var isArray = Array.isArray;
|
11993 |
+
|
11994 |
+
var defaults = {
|
11995 |
+
allowDots: false,
|
11996 |
+
allowPrototypes: false,
|
11997 |
+
arrayLimit: 20,
|
11998 |
+
charset: 'utf-8',
|
11999 |
+
charsetSentinel: false,
|
12000 |
+
comma: false,
|
12001 |
+
decoder: utils.decode,
|
12002 |
+
delimiter: '&',
|
12003 |
+
depth: 5,
|
12004 |
+
ignoreQueryPrefix: false,
|
12005 |
+
interpretNumericEntities: false,
|
12006 |
+
parameterLimit: 1000,
|
12007 |
+
parseArrays: true,
|
12008 |
+
plainObjects: false,
|
12009 |
+
strictNullHandling: false
|
12010 |
+
};
|
12011 |
+
|
12012 |
+
var interpretNumericEntities = function (str) {
|
12013 |
+
return str.replace(/&#(\d+);/g, function ($0, numberStr) {
|
12014 |
+
return String.fromCharCode(parseInt(numberStr, 10));
|
12015 |
+
});
|
12016 |
+
};
|
12017 |
+
|
12018 |
+
var parseArrayValue = function (val, options) {
|
12019 |
+
if (val && typeof val === 'string' && options.comma && val.indexOf(',') > -1) {
|
12020 |
+
return val.split(',');
|
12021 |
+
}
|
12022 |
+
|
12023 |
+
return val;
|
12024 |
+
};
|
12025 |
+
|
12026 |
+
// This is what browsers will submit when the ✓ character occurs in an
|
12027 |
+
// application/x-www-form-urlencoded body and the encoding of the page containing
|
12028 |
+
// the form is iso-8859-1, or when the submitted form has an accept-charset
|
12029 |
+
// attribute of iso-8859-1. Presumably also with other charsets that do not contain
|
12030 |
+
// the ✓ character, such as us-ascii.
|
12031 |
+
var isoSentinel = 'utf8=%26%2310003%3B'; // encodeURIComponent('✓')
|
12032 |
+
|
12033 |
+
// These are the percent-encoded utf-8 octets representing a checkmark, indicating that the request actually is utf-8 encoded.
|
12034 |
+
var charsetSentinel = 'utf8=%E2%9C%93'; // encodeURIComponent('✓')
|
12035 |
+
|
12036 |
+
var parseValues = function parseQueryStringValues(str, options) {
|
12037 |
+
var obj = {};
|
12038 |
+
var cleanStr = options.ignoreQueryPrefix ? str.replace(/^\?/, '') : str;
|
12039 |
+
var limit = options.parameterLimit === Infinity ? undefined : options.parameterLimit;
|
12040 |
+
var parts = cleanStr.split(options.delimiter, limit);
|
12041 |
+
var skipIndex = -1; // Keep track of where the utf8 sentinel was found
|
12042 |
+
var i;
|
12043 |
+
|
12044 |
+
var charset = options.charset;
|
12045 |
+
if (options.charsetSentinel) {
|
12046 |
+
for (i = 0; i < parts.length; ++i) {
|
12047 |
+
if (parts[i].indexOf('utf8=') === 0) {
|
12048 |
+
if (parts[i] === charsetSentinel) {
|
12049 |
+
charset = 'utf-8';
|
12050 |
+
} else if (parts[i] === isoSentinel) {
|
12051 |
+
charset = 'iso-8859-1';
|
12052 |
+
}
|
12053 |
+
skipIndex = i;
|
12054 |
+
i = parts.length; // The eslint settings do not allow break;
|
12055 |
+
}
|
12056 |
+
}
|
12057 |
+
}
|
12058 |
+
|
12059 |
+
for (i = 0; i < parts.length; ++i) {
|
12060 |
+
if (i === skipIndex) {
|
12061 |
+
continue;
|
12062 |
+
}
|
12063 |
+
var part = parts[i];
|
12064 |
+
|
12065 |
+
var bracketEqualsPos = part.indexOf(']=');
|
12066 |
+
var pos = bracketEqualsPos === -1 ? part.indexOf('=') : bracketEqualsPos + 1;
|
12067 |
+
|
12068 |
+
var key, val;
|
12069 |
+
if (pos === -1) {
|
12070 |
+
key = options.decoder(part, defaults.decoder, charset, 'key');
|
12071 |
+
val = options.strictNullHandling ? null : '';
|
12072 |
+
} else {
|
12073 |
+
key = options.decoder(part.slice(0, pos), defaults.decoder, charset, 'key');
|
12074 |
+
val = utils.maybeMap(
|
12075 |
+
parseArrayValue(part.slice(pos + 1), options),
|
12076 |
+
function (encodedVal) {
|
12077 |
+
return options.decoder(encodedVal, defaults.decoder, charset, 'value');
|
12078 |
+
}
|
12079 |
+
);
|
12080 |
+
}
|
12081 |
+
|
12082 |
+
if (val && options.interpretNumericEntities && charset === 'iso-8859-1') {
|
12083 |
+
val = interpretNumericEntities(val);
|
12084 |
+
}
|
12085 |
+
|
12086 |
+
if (part.indexOf('[]=') > -1) {
|
12087 |
+
val = isArray(val) ? [val] : val;
|
12088 |
+
}
|
12089 |
+
|
12090 |
+
if (has.call(obj, key)) {
|
12091 |
+
obj[key] = utils.combine(obj[key], val);
|
12092 |
+
} else {
|
12093 |
+
obj[key] = val;
|
12094 |
+
}
|
12095 |
+
}
|
12096 |
+
|
12097 |
+
return obj;
|
12098 |
+
};
|
12099 |
+
|
12100 |
+
var parseObject = function (chain, val, options, valuesParsed) {
|
12101 |
+
var leaf = valuesParsed ? val : parseArrayValue(val, options);
|
12102 |
+
|
12103 |
+
for (var i = chain.length - 1; i >= 0; --i) {
|
12104 |
+
var obj;
|
12105 |
+
var root = chain[i];
|
12106 |
+
|
12107 |
+
if (root === '[]' && options.parseArrays) {
|
12108 |
+
obj = [].concat(leaf);
|
12109 |
+
} else {
|
12110 |
+
obj = options.plainObjects ? Object.create(null) : {};
|
12111 |
+
var cleanRoot = root.charAt(0) === '[' && root.charAt(root.length - 1) === ']' ? root.slice(1, -1) : root;
|
12112 |
+
var index = parseInt(cleanRoot, 10);
|
12113 |
+
if (!options.parseArrays && cleanRoot === '') {
|
12114 |
+
obj = { 0: leaf };
|
12115 |
+
} else if (
|
12116 |
+
!isNaN(index)
|
12117 |
+
&& root !== cleanRoot
|
12118 |
+
&& String(index) === cleanRoot
|
12119 |
+
&& index >= 0
|
12120 |
+
&& (options.parseArrays && index <= options.arrayLimit)
|
12121 |
+
) {
|
12122 |
+
obj = [];
|
12123 |
+
obj[index] = leaf;
|
12124 |
+
} else {
|
12125 |
+
obj[cleanRoot] = leaf;
|
12126 |
+
}
|
12127 |
+
}
|
12128 |
+
|
12129 |
+
leaf = obj;
|
12130 |
+
}
|
12131 |
+
|
12132 |
+
return leaf;
|
12133 |
+
};
|
12134 |
+
|
12135 |
+
var parseKeys = function parseQueryStringKeys(givenKey, val, options, valuesParsed) {
|
12136 |
+
if (!givenKey) {
|
12137 |
+
return;
|
12138 |
+
}
|
12139 |
+
|
12140 |
+
// Transform dot notation to bracket notation
|
12141 |
+
var key = options.allowDots ? givenKey.replace(/\.([^.[]+)/g, '[$1]') : givenKey;
|
12142 |
+
|
12143 |
+
// The regex chunks
|
12144 |
+
|
12145 |
+
var brackets = /(\[[^[\]]*])/;
|
12146 |
+
var child = /(\[[^[\]]*])/g;
|
12147 |
+
|
12148 |
+
// Get the parent
|
12149 |
+
|
12150 |
+
var segment = options.depth > 0 && brackets.exec(key);
|
12151 |
+
var parent = segment ? key.slice(0, segment.index) : key;
|
12152 |
+
|
12153 |
+
// Stash the parent if it exists
|
12154 |
+
|
12155 |
+
var keys = [];
|
12156 |
+
if (parent) {
|
12157 |
+
// If we aren't using plain objects, optionally prefix keys that would overwrite object prototype properties
|
12158 |
+
if (!options.plainObjects && has.call(Object.prototype, parent)) {
|
12159 |
+
if (!options.allowPrototypes) {
|
12160 |
+
return;
|
12161 |
+
}
|
12162 |
+
}
|
12163 |
+
|
12164 |
+
keys.push(parent);
|
12165 |
+
}
|
12166 |
+
|
12167 |
+
// Loop through children appending to the array until we hit depth
|
12168 |
+
|
12169 |
+
var i = 0;
|
12170 |
+
while (options.depth > 0 && (segment = child.exec(key)) !== null && i < options.depth) {
|
12171 |
+
i += 1;
|
12172 |
+
if (!options.plainObjects && has.call(Object.prototype, segment[1].slice(1, -1))) {
|
12173 |
+
if (!options.allowPrototypes) {
|
12174 |
+
return;
|
12175 |
+
}
|
12176 |
+
}
|
12177 |
+
keys.push(segment[1]);
|
12178 |
+
}
|
12179 |
+
|
12180 |
+
// If there's a remainder, just add whatever is left
|
12181 |
+
|
12182 |
+
if (segment) {
|
12183 |
+
keys.push('[' + key.slice(segment.index) + ']');
|
12184 |
+
}
|
12185 |
+
|
12186 |
+
return parseObject(keys, val, options, valuesParsed);
|
12187 |
+
};
|
12188 |
+
|
12189 |
+
var normalizeParseOptions = function normalizeParseOptions(opts) {
|
12190 |
+
if (!opts) {
|
12191 |
+
return defaults;
|
12192 |
+
}
|
12193 |
+
|
12194 |
+
if (opts.decoder !== null && opts.decoder !== undefined && typeof opts.decoder !== 'function') {
|
12195 |
+
throw new TypeError('Decoder has to be a function.');
|
12196 |
+
}
|
12197 |
+
|
12198 |
+
if (typeof opts.charset !== 'undefined' && opts.charset !== 'utf-8' && opts.charset !== 'iso-8859-1') {
|
12199 |
+
throw new TypeError('The charset option must be either utf-8, iso-8859-1, or undefined');
|
12200 |
+
}
|
12201 |
+
var charset = typeof opts.charset === 'undefined' ? defaults.charset : opts.charset;
|
12202 |
+
|
12203 |
+
return {
|
12204 |
+
allowDots: typeof opts.allowDots === 'undefined' ? defaults.allowDots : !!opts.allowDots,
|
12205 |
+
allowPrototypes: typeof opts.allowPrototypes === 'boolean' ? opts.allowPrototypes : defaults.allowPrototypes,
|
12206 |
+
arrayLimit: typeof opts.arrayLimit === 'number' ? opts.arrayLimit : defaults.arrayLimit,
|
12207 |
+
charset: charset,
|
12208 |
+
charsetSentinel: typeof opts.charsetSentinel === 'boolean' ? opts.charsetSentinel : defaults.charsetSentinel,
|
12209 |
+
comma: typeof opts.comma === 'boolean' ? opts.comma : defaults.comma,
|
12210 |
+
decoder: typeof opts.decoder === 'function' ? opts.decoder : defaults.decoder,
|
12211 |
+
delimiter: typeof opts.delimiter === 'string' || utils.isRegExp(opts.delimiter) ? opts.delimiter : defaults.delimiter,
|
12212 |
+
// eslint-disable-next-line no-implicit-coercion, no-extra-parens
|
12213 |
+
depth: (typeof opts.depth === 'number' || opts.depth === false) ? +opts.depth : defaults.depth,
|
12214 |
+
ignoreQueryPrefix: opts.ignoreQueryPrefix === true,
|
12215 |
+
interpretNumericEntities: typeof opts.interpretNumericEntities === 'boolean' ? opts.interpretNumericEntities : defaults.interpretNumericEntities,
|
12216 |
+
parameterLimit: typeof opts.parameterLimit === 'number' ? opts.parameterLimit : defaults.parameterLimit,
|
12217 |
+
parseArrays: opts.parseArrays !== false,
|
12218 |
+
plainObjects: typeof opts.plainObjects === 'boolean' ? opts.plainObjects : defaults.plainObjects,
|
12219 |
+
strictNullHandling: typeof opts.strictNullHandling === 'boolean' ? opts.strictNullHandling : defaults.strictNullHandling
|
12220 |
+
};
|
12221 |
+
};
|
12222 |
+
|
12223 |
+
module.exports = function (str, opts) {
|
12224 |
+
var options = normalizeParseOptions(opts);
|
12225 |
+
|
12226 |
+
if (str === '' || str === null || typeof str === 'undefined') {
|
12227 |
+
return options.plainObjects ? Object.create(null) : {};
|
12228 |
+
}
|
12229 |
+
|
12230 |
+
var tempObj = typeof str === 'string' ? parseValues(str, options) : str;
|
12231 |
+
var obj = options.plainObjects ? Object.create(null) : {};
|
12232 |
+
|
12233 |
+
// Iterate over the keys and setup the new object
|
12234 |
+
|
12235 |
+
var keys = Object.keys(tempObj);
|
12236 |
+
for (var i = 0; i < keys.length; ++i) {
|
12237 |
+
var key = keys[i];
|
12238 |
+
var newObj = parseKeys(key, tempObj[key], options, typeof str === 'string');
|
12239 |
+
obj = utils.merge(obj, newObj, options);
|
12240 |
+
}
|
12241 |
+
|
12242 |
+
return utils.compact(obj);
|
12243 |
+
};
|
12244 |
+
|
12245 |
+
|
12246 |
+
/***/ }),
|
12247 |
+
|
12248 |
+
/***/ 6:
|
12249 |
+
/***/ (function(module, exports, __webpack_require__) {
|
12250 |
+
|
12251 |
+
/*!
|
12252 |
+
Copyright (c) 2018 Jed Watson.
|
12253 |
+
Licensed under the MIT License (MIT), see
|
12254 |
+
http://jedwatson.github.io/classnames
|
12255 |
+
*/
|
12256 |
+
/* global define */
|
12257 |
+
|
12258 |
+
(function () {
|
12259 |
+
'use strict';
|
12260 |
+
|
12261 |
+
var hasOwn = {}.hasOwnProperty;
|
12262 |
+
|
12263 |
+
function classNames() {
|
12264 |
+
var classes = [];
|
12265 |
+
|
12266 |
+
for (var i = 0; i < arguments.length; i++) {
|
12267 |
+
var arg = arguments[i];
|
12268 |
+
if (!arg) continue;
|
12269 |
+
|
12270 |
+
var argType = typeof arg;
|
12271 |
+
|
12272 |
+
if (argType === 'string' || argType === 'number') {
|
12273 |
+
classes.push(arg);
|
12274 |
+
} else if (Array.isArray(arg)) {
|
12275 |
+
if (arg.length) {
|
12276 |
+
var inner = classNames.apply(null, arg);
|
12277 |
+
if (inner) {
|
12278 |
+
classes.push(inner);
|
12279 |
+
}
|
12280 |
+
}
|
12281 |
+
} else if (argType === 'object') {
|
12282 |
+
if (arg.toString === Object.prototype.toString) {
|
12283 |
+
for (var key in arg) {
|
12284 |
+
if (hasOwn.call(arg, key) && arg[key]) {
|
12285 |
+
classes.push(key);
|
12286 |
+
}
|
12287 |
+
}
|
12288 |
+
} else {
|
12289 |
+
classes.push(arg.toString());
|
12290 |
+
}
|
12291 |
+
}
|
12292 |
+
}
|
12293 |
+
|
12294 |
+
return classes.join(' ');
|
12295 |
+
}
|
12296 |
+
|
12297 |
+
if ( true && module.exports) {
|
12298 |
+
classNames.default = classNames;
|
12299 |
+
module.exports = classNames;
|
12300 |
+
} else if (typeof define === 'function' && typeof define.amd === 'object' && define.amd) {
|
12301 |
+
// register as 'classnames', consistent with npm package name
|
12302 |
+
define('classnames', [], function () {
|
12303 |
+
return classNames;
|
12304 |
+
});
|
12305 |
+
} else {
|
12306 |
+
window.classNames = classNames;
|
12307 |
+
}
|
12308 |
+
}());
|
12309 |
+
|
12310 |
+
|
12311 |
+
/***/ }),
|
12312 |
+
|
12313 |
+
/***/ 61:
|
12314 |
+
/***/ (function(module, exports) {
|
12315 |
+
|
12316 |
+
(function() { module.exports = window["wp"]["date"]; }());
|
12317 |
+
|
12318 |
+
/***/ }),
|
12319 |
+
|
12320 |
+
/***/ 62:
|
12321 |
+
/***/ (function(module, __webpack_exports__, __webpack_require__) {
|
12322 |
+
|
12323 |
+
"use strict";
|
12324 |
+
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "b", function() { return getCountryCode; });
|
12325 |
+
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "c", function() { return getCurrencyRegion; });
|
12326 |
+
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "e", function() { return getProductIdsForCart; });
|
12327 |
+
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "a", function() { return getCategorizedOnboardingProducts; });
|
12328 |
+
/* unused harmony export getProductList */
|
12329 |
+
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "d", function() { return getPriceValue; });
|
12330 |
+
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "f", function() { return isWCAdmin; });
|
12331 |
+
/* harmony import */ var _wordpress_html_entities__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(29);
|
12332 |
+
/* harmony import */ var _wordpress_html_entities__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(_wordpress_html_entities__WEBPACK_IMPORTED_MODULE_0__);
|
12333 |
+
/* harmony import */ var lodash__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(4);
|
12334 |
+
/* harmony import */ var lodash__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(lodash__WEBPACK_IMPORTED_MODULE_1__);
|
12335 |
+
/* harmony import */ var _woocommerce_wc_admin_settings__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(13);
|
12336 |
+
/**
|
12337 |
+
* External dependencies
|
12338 |
+
*/
|
12339 |
+
|
12340 |
+
|
12341 |
+
|
12342 |
+
/**
|
12343 |
+
* Gets the country code from a country:state value string.
|
12344 |
+
*
|
12345 |
+
* @param {string} countryState Country state string, e.g. US:GA.
|
12346 |
+
* @return {string} Country string.
|
12347 |
+
*/
|
12348 |
+
|
12349 |
+
function getCountryCode(countryState) {
|
12350 |
+
if (!countryState) {
|
12351 |
+
return null;
|
12352 |
+
}
|
12353 |
+
|
12354 |
+
return countryState.split(':')[0];
|
12355 |
+
}
|
12356 |
+
function getCurrencyRegion(countryState) {
|
12357 |
+
let region = getCountryCode(countryState);
|
12358 |
+
const euCountries = Object(lodash__WEBPACK_IMPORTED_MODULE_1__["without"])(Object(_woocommerce_wc_admin_settings__WEBPACK_IMPORTED_MODULE_2__[/* getSetting */ "f"])('onboarding', {
|
12359 |
+
euCountries: []
|
12360 |
+
}).euCountries, 'GB');
|
12361 |
+
|
12362 |
+
if (euCountries.includes(region)) {
|
12363 |
+
region = 'EU';
|
12364 |
+
}
|
12365 |
+
|
12366 |
+
return region;
|
12367 |
+
}
|
12368 |
+
/**
|
12369 |
+
* Gets the product IDs for items based on the product types and theme selected in the onboarding profiler.
|
12370 |
+
*
|
12371 |
+
* @param {Object} productTypes Product Types.
|
12372 |
+
* @param {Object} profileItems Onboarding profile.
|
12373 |
+
* @param {boolean} includeInstalledItems Include installed items in returned product IDs.
|
12374 |
+
* @param {Array} installedPlugins Installed plugins.
|
12375 |
+
* @return {Array} Product Ids.
|
12376 |
+
*/
|
12377 |
+
|
12378 |
+
function getProductIdsForCart(productTypes, profileItems, includeInstalledItems = false, installedPlugins) {
|
12379 |
+
const productList = getProductList(profileItems, includeInstalledItems, installedPlugins, productTypes);
|
12380 |
+
const productIds = productList.map(product => product.id || product.product);
|
12381 |
+
return productIds;
|
12382 |
+
}
|
12383 |
+
/**
|
12384 |
+
* Gets the labeled/categorized product names and types for items based on the product types and theme selected in the onboarding profiler.
|
12385 |
+
*
|
12386 |
+
* @param {Object} productTypes Product Types.
|
12387 |
+
* @param {Object} profileItems Onboarding profile.
|
12388 |
+
* @param {Array} installedPlugins Installed plugins.
|
12389 |
+
* @return {Array} Objects with labeled/categorized product names and types.
|
12390 |
+
*/
|
12391 |
+
|
12392 |
+
function getCategorizedOnboardingProducts(productTypes, profileItems, installedPlugins) {
|
12393 |
+
const productList = {};
|
12394 |
+
productList.products = getProductList(profileItems, true, installedPlugins, productTypes);
|
12395 |
+
productList.remainingProducts = getProductList(profileItems, false, installedPlugins, productTypes);
|
12396 |
+
const uniqueItemsList = [...new Set([...productList.products, ...productList.remainingProducts])];
|
12397 |
+
productList.uniqueItemsList = uniqueItemsList.map(product => {
|
12398 |
+
let cleanedProduct;
|
12399 |
+
|
12400 |
+
if (product.label) {
|
12401 |
+
cleanedProduct = {
|
12402 |
+
type: 'extension',
|
12403 |
+
name: product.label
|
12404 |
+
};
|
12405 |
+
} else {
|
12406 |
+
cleanedProduct = {
|
12407 |
+
type: 'theme',
|
12408 |
+
name: product.title
|
12409 |
+
};
|
12410 |
+
}
|
12411 |
+
|
12412 |
+
return cleanedProduct;
|
12413 |
+
});
|
12414 |
+
return productList;
|
12415 |
+
}
|
12416 |
+
/**
|
12417 |
+
* Gets a product list for items based on the product types and theme selected in the onboarding profiler.
|
12418 |
+
*
|
12419 |
+
* @param {Object} profileItems Onboarding profile.
|
12420 |
+
* @param {boolean} includeInstalledItems Include installed items in returned product list.
|
12421 |
+
* @param {Array} installedPlugins Installed plugins.
|
12422 |
+
* @param {Object} productTypes Product Types.
|
12423 |
+
* @return {Array} Products.
|
12424 |
+
*/
|
12425 |
+
|
12426 |
+
function getProductList(profileItems, includeInstalledItems = false, installedPlugins, productTypes) {
|
12427 |
+
const productList = [];
|
12428 |
+
|
12429 |
+
if (!productTypes) {
|
12430 |
+
return productList;
|
12431 |
+
}
|
12432 |
+
|
12433 |
+
const profileItemsProductTypes = profileItems.product_types || [];
|
12434 |
+
profileItemsProductTypes.forEach(productType => {
|
12435 |
+
if (productTypes[productType] && productTypes[productType].product && (includeInstalledItems || !installedPlugins.includes(productTypes[productType].slug))) {
|
12436 |
+
productList.push(productTypes[productType]);
|
12437 |
+
}
|
12438 |
+
});
|
12439 |
+
const onboarding = Object(_woocommerce_wc_admin_settings__WEBPACK_IMPORTED_MODULE_2__[/* getSetting */ "f"])('onboarding', {});
|
12440 |
+
let theme = null;
|
12441 |
+
|
12442 |
+
if (onboarding && onboarding.themes) {
|
12443 |
+
theme = onboarding.themes.find(themeData => themeData.slug === profileItems.theme);
|
12444 |
+
}
|
12445 |
+
|
12446 |
+
if (theme && theme.id && getPriceValue(theme.price) > 0 && (includeInstalledItems || !theme.is_installed)) {
|
12447 |
+
productList.push(theme);
|
12448 |
+
}
|
12449 |
+
|
12450 |
+
return productList;
|
12451 |
+
}
|
12452 |
+
/**
|
12453 |
+
* Get the value of a price from a string, removing any non-numeric characters.
|
12454 |
+
*
|
12455 |
+
* @param {string} string Price string.
|
12456 |
+
* @return {number} Number value.
|
12457 |
+
*/
|
12458 |
+
|
12459 |
+
function getPriceValue(string) {
|
12460 |
+
return Number(Object(_wordpress_html_entities__WEBPACK_IMPORTED_MODULE_0__["decodeEntities"])(string).replace(/[^0-9.-]+/g, ''));
|
12461 |
+
}
|
12462 |
+
/**
|
12463 |
+
* Determines if a URL is a WC admin url.
|
12464 |
+
*
|
12465 |
+
* @param {*} url - the url to test
|
12466 |
+
* @return {boolean} true if the url is a wc-admin URL
|
12467 |
+
*/
|
12468 |
+
|
12469 |
+
function isWCAdmin(url) {
|
12470 |
+
return /admin.php\?page=wc-admin/.test(url);
|
12471 |
+
}
|
12472 |
+
|
12473 |
+
/***/ }),
|
12474 |
+
|
12475 |
+
/***/ 68:
|
12476 |
+
/***/ (function(module, __webpack_exports__, __webpack_require__) {
|
12477 |
+
|
12478 |
+
"use strict";
|
12479 |
+
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "d", function() { return getUnreadOrders; });
|
12480 |
+
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "c", function() { return getOrderStatuses; });
|
12481 |
+
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "b", function() { return getLowStockCountQuery; });
|
12482 |
+
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "a", function() { return getLowStockCount; });
|
12483 |
+
/* harmony import */ var _woocommerce_data__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(11);
|
12484 |
+
/* harmony import */ var _woocommerce_data__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(_woocommerce_data__WEBPACK_IMPORTED_MODULE_0__);
|
12485 |
+
/* harmony import */ var _analytics_settings_config__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(256);
|
12486 |
+
/**
|
12487 |
+
* External dependencies
|
12488 |
+
*/
|
12489 |
+
|
12490 |
+
/**
|
12491 |
+
* Internal dependencies
|
12492 |
+
*/
|
12493 |
+
|
12494 |
+
|
12495 |
+
function getUnreadOrders(select, orderStatuses) {
|
12496 |
+
const {
|
12497 |
+
getItemsTotalCount,
|
12498 |
+
getItemsError,
|
12499 |
+
isResolving
|
12500 |
+
} = select(_woocommerce_data__WEBPACK_IMPORTED_MODULE_0__["ITEMS_STORE_NAME"]);
|
12501 |
+
|
12502 |
+
if (!orderStatuses.length) {
|
12503 |
+
return 0;
|
12504 |
+
}
|
12505 |
+
|
12506 |
+
const ordersQuery = {
|
12507 |
+
page: 1,
|
12508 |
+
per_page: 1,
|
12509 |
+
// Core endpoint requires per_page > 0.
|
12510 |
+
status: orderStatuses,
|
12511 |
+
_fields: ['id']
|
12512 |
+
};
|
12513 |
+
const defaultValue = null; // Disable eslint rule requiring `totalOrders` to be defined below because the next two statements
|
12514 |
+
// depend on `getItemsTotalCount` to have been called.
|
12515 |
+
// eslint-disable-next-line @wordpress/no-unused-vars-before-return
|
12516 |
+
|
12517 |
+
const totalOrders = getItemsTotalCount('orders', ordersQuery, defaultValue);
|
12518 |
+
const isError = Boolean(getItemsError('orders', ordersQuery));
|
12519 |
+
const isRequesting = isResolving('getItemsTotalCount', ['orders', ordersQuery, defaultValue]);
|
12520 |
+
|
12521 |
+
if (isError || isRequesting) {
|
12522 |
+
return null;
|
12523 |
+
}
|
12524 |
+
|
12525 |
+
return totalOrders;
|
12526 |
+
}
|
12527 |
+
function getOrderStatuses(select) {
|
12528 |
+
const {
|
12529 |
+
getSetting: getMutableSetting
|
12530 |
+
} = select(_woocommerce_data__WEBPACK_IMPORTED_MODULE_0__["SETTINGS_STORE_NAME"]);
|
12531 |
+
const {
|
12532 |
+
woocommerce_actionable_order_statuses: orderStatuses = _analytics_settings_config__WEBPACK_IMPORTED_MODULE_1__[/* DEFAULT_ACTIONABLE_STATUSES */ "a"]
|
12533 |
+
} = getMutableSetting('wc_admin', 'wcAdminSettings', {});
|
12534 |
+
return orderStatuses;
|
12535 |
+
}
|
12536 |
+
const getLowStockCountQuery = {
|
12537 |
+
page: 1,
|
12538 |
+
per_page: 1,
|
12539 |
+
low_in_stock: true,
|
12540 |
+
status: 'publish',
|
12541 |
+
_fields: ['id']
|
12542 |
+
};
|
12543 |
+
function getLowStockCount(select) {
|
12544 |
+
const {
|
12545 |
+
getItemsTotalCount,
|
12546 |
+
getItemsError,
|
12547 |
+
isResolving
|
12548 |
+
} = select(_woocommerce_data__WEBPACK_IMPORTED_MODULE_0__["ITEMS_STORE_NAME"]);
|
12549 |
+
const defaultValue = null; // Disable eslint rule requiring `totalLowStockProducts` to be defined below because the next two statements
|
12550 |
+
// depend on `getItemsTotalCount` to have been called.
|
12551 |
+
// eslint-disable-next-line @wordpress/no-unused-vars-before-return
|
12552 |
+
|
12553 |
+
const totalLowStockProducts = getItemsTotalCount('products/low-in-stock', getLowStockCountQuery, defaultValue);
|
12554 |
+
const isError = Boolean(getItemsError('products/low-in-stock', getLowStockCountQuery));
|
12555 |
+
const isRequesting = isResolving('getItemsTotalCount', ['products/low-in-stock', getLowStockCountQuery, defaultValue]);
|
12556 |
+
|
12557 |
+
if (isError || isRequesting && totalLowStockProducts === defaultValue) {
|
12558 |
+
return null;
|
12559 |
+
}
|
12560 |
+
|
12561 |
+
return totalLowStockProducts;
|
12562 |
+
}
|
12563 |
+
|
12564 |
+
/***/ }),
|
12565 |
+
|
12566 |
+
/***/ 69:
|
12567 |
+
/***/ (function(module, exports, __webpack_require__) {
|
12568 |
+
|
12569 |
+
"use strict";
|
12570 |
+
/**
|
12571 |
+
* Copyright (c) 2015-present, Facebook, Inc.
|
12572 |
+
*
|
12573 |
+
* This source code is licensed under the MIT license found in the
|
12574 |
+
* LICENSE file in the root directory of this source tree.
|
12575 |
+
*/
|
12576 |
+
|
12577 |
+
|
12578 |
+
|
12579 |
+
var React = __webpack_require__(5);
|
12580 |
+
|
12581 |
+
var REACT_ELEMENT_TYPE =
|
12582 |
+
(typeof Symbol === 'function' && Symbol.for && Symbol.for('react.element')) ||
|
12583 |
+
0xeac7;
|
12584 |
+
|
12585 |
+
var emptyFunction = __webpack_require__(50);
|
12586 |
+
var invariant = __webpack_require__(70);
|
12587 |
+
var warning = __webpack_require__(71);
|
12588 |
+
|
12589 |
+
var SEPARATOR = '.';
|
12590 |
+
var SUBSEPARATOR = ':';
|
12591 |
+
|
12592 |
+
var didWarnAboutMaps = false;
|
12593 |
+
|
12594 |
+
var ITERATOR_SYMBOL = typeof Symbol === 'function' && Symbol.iterator;
|
12595 |
+
var FAUX_ITERATOR_SYMBOL = '@@iterator'; // Before Symbol spec.
|
12596 |
+
|
12597 |
+
function getIteratorFn(maybeIterable) {
|
12598 |
+
var iteratorFn =
|
12599 |
+
maybeIterable &&
|
12600 |
+
((ITERATOR_SYMBOL && maybeIterable[ITERATOR_SYMBOL]) ||
|
12601 |
+
maybeIterable[FAUX_ITERATOR_SYMBOL]);
|
12602 |
+
if (typeof iteratorFn === 'function') {
|
12603 |
+
return iteratorFn;
|
12604 |
+
}
|
12605 |
+
}
|
12606 |
+
|
12607 |
+
function escape(key) {
|
12608 |
+
var escapeRegex = /[=:]/g;
|
12609 |
+
var escaperLookup = {
|
12610 |
+
'=': '=0',
|
12611 |
+
':': '=2'
|
12612 |
+
};
|
12613 |
+
var escapedString = ('' + key).replace(escapeRegex, function(match) {
|
12614 |
+
return escaperLookup[match];
|
12615 |
+
});
|
12616 |
+
|
12617 |
+
return '$' + escapedString;
|
12618 |
+
}
|
12619 |
+
|
12620 |
+
function getComponentKey(component, index) {
|
12621 |
+
// Do some typechecking here since we call this blindly. We want to ensure
|
12622 |
+
// that we don't block potential future ES APIs.
|
12623 |
+
if (component && typeof component === 'object' && component.key != null) {
|
12624 |
+
// Explicit key
|
12625 |
+
return escape(component.key);
|
12626 |
+
}
|
12627 |
+
// Implicit key determined by the index in the set
|
12628 |
+
return index.toString(36);
|
12629 |
+
}
|
12630 |
+
|
12631 |
+
function traverseAllChildrenImpl(
|
12632 |
+
children,
|
12633 |
+
nameSoFar,
|
12634 |
+
callback,
|
12635 |
+
traverseContext
|
12636 |
+
) {
|
12637 |
+
var type = typeof children;
|
12638 |
+
|
12639 |
+
if (type === 'undefined' || type === 'boolean') {
|
12640 |
+
// All of the above are perceived as null.
|
12641 |
+
children = null;
|
12642 |
+
}
|
12643 |
+
|
12644 |
+
if (
|
12645 |
+
children === null ||
|
12646 |
+
type === 'string' ||
|
12647 |
+
type === 'number' ||
|
12648 |
+
// The following is inlined from ReactElement. This means we can optimize
|
12649 |
+
// some checks. React Fiber also inlines this logic for similar purposes.
|
12650 |
+
(type === 'object' && children.$$typeof === REACT_ELEMENT_TYPE)
|
12651 |
+
) {
|
12652 |
+
callback(
|
12653 |
+
traverseContext,
|
12654 |
+
children,
|
12655 |
+
// If it's the only child, treat the name as if it was wrapped in an array
|
12656 |
+
// so that it's consistent if the number of children grows.
|
12657 |
+
nameSoFar === '' ? SEPARATOR + getComponentKey(children, 0) : nameSoFar
|
12658 |
+
);
|
12659 |
+
return 1;
|
12660 |
+
}
|
12661 |
+
|
12662 |
+
var child;
|
12663 |
+
var nextName;
|
12664 |
+
var subtreeCount = 0; // Count of children found in the current subtree.
|
12665 |
+
var nextNamePrefix = nameSoFar === '' ? SEPARATOR : nameSoFar + SUBSEPARATOR;
|
12666 |
+
|
12667 |
+
if (Array.isArray(children)) {
|
12668 |
+
for (var i = 0; i < children.length; i++) {
|
12669 |
+
child = children[i];
|
12670 |
+
nextName = nextNamePrefix + getComponentKey(child, i);
|
12671 |
+
subtreeCount += traverseAllChildrenImpl(
|
12672 |
+
child,
|
12673 |
+
nextName,
|
12674 |
+
callback,
|
12675 |
+
traverseContext
|
12676 |
+
);
|
12677 |
+
}
|
12678 |
+
} else {
|
12679 |
+
var iteratorFn = getIteratorFn(children);
|
12680 |
+
if (iteratorFn) {
|
12681 |
+
if (false) {}
|
12682 |
+
|
12683 |
+
var iterator = iteratorFn.call(children);
|
12684 |
+
var step;
|
12685 |
+
var ii = 0;
|
12686 |
+
while (!(step = iterator.next()).done) {
|
12687 |
+
child = step.value;
|
12688 |
+
nextName = nextNamePrefix + getComponentKey(child, ii++);
|
12689 |
+
subtreeCount += traverseAllChildrenImpl(
|
12690 |
+
child,
|
12691 |
+
nextName,
|
12692 |
+
callback,
|
12693 |
+
traverseContext
|
12694 |
+
);
|
12695 |
+
}
|
12696 |
+
} else if (type === 'object') {
|
12697 |
+
var addendum = '';
|
12698 |
+
if (false) {}
|
12699 |
+
var childrenString = '' + children;
|
12700 |
+
invariant(
|
12701 |
+
false,
|
12702 |
+
'Objects are not valid as a React child (found: %s).%s',
|
12703 |
+
childrenString === '[object Object]'
|
12704 |
+
? 'object with keys {' + Object.keys(children).join(', ') + '}'
|
12705 |
+
: childrenString,
|
12706 |
+
addendum
|
12707 |
+
);
|
12708 |
+
}
|
12709 |
+
}
|
12710 |
+
|
12711 |
+
return subtreeCount;
|
12712 |
+
}
|
12713 |
+
|
12714 |
+
function traverseAllChildren(children, callback, traverseContext) {
|
12715 |
+
if (children == null) {
|
12716 |
+
return 0;
|
12717 |
+
}
|
12718 |
+
|
12719 |
+
return traverseAllChildrenImpl(children, '', callback, traverseContext);
|
12720 |
+
}
|
12721 |
+
|
12722 |
+
var userProvidedKeyEscapeRegex = /\/+/g;
|
12723 |
+
function escapeUserProvidedKey(text) {
|
12724 |
+
return ('' + text).replace(userProvidedKeyEscapeRegex, '$&/');
|
12725 |
+
}
|
12726 |
+
|
12727 |
+
function cloneAndReplaceKey(oldElement, newKey) {
|
12728 |
+
return React.cloneElement(
|
12729 |
+
oldElement,
|
12730 |
+
{key: newKey},
|
12731 |
+
oldElement.props !== undefined ? oldElement.props.children : undefined
|
12732 |
+
);
|
12733 |
+
}
|
12734 |
+
|
12735 |
+
var DEFAULT_POOL_SIZE = 10;
|
12736 |
+
var DEFAULT_POOLER = oneArgumentPooler;
|
12737 |
+
|
12738 |
+
var oneArgumentPooler = function(copyFieldsFrom) {
|
12739 |
+
var Klass = this;
|
12740 |
+
if (Klass.instancePool.length) {
|
12741 |
+
var instance = Klass.instancePool.pop();
|
12742 |
+
Klass.call(instance, copyFieldsFrom);
|
12743 |
+
return instance;
|
12744 |
+
} else {
|
12745 |
+
return new Klass(copyFieldsFrom);
|
12746 |
+
}
|
12747 |
+
};
|
12748 |
+
|
12749 |
+
var addPoolingTo = function addPoolingTo(CopyConstructor, pooler) {
|
12750 |
+
// Casting as any so that flow ignores the actual implementation and trusts
|
12751 |
+
// it to match the type we declared
|
12752 |
+
var NewKlass = CopyConstructor;
|
12753 |
+
NewKlass.instancePool = [];
|
12754 |
+
NewKlass.getPooled = pooler || DEFAULT_POOLER;
|
12755 |
+
if (!NewKlass.poolSize) {
|
12756 |
+
NewKlass.poolSize = DEFAULT_POOL_SIZE;
|
12757 |
+
}
|
12758 |
+
NewKlass.release = standardReleaser;
|
12759 |
+
return NewKlass;
|
12760 |
+
};
|
12761 |
+
|
12762 |
+
var standardReleaser = function standardReleaser(instance) {
|
12763 |
+
var Klass = this;
|
12764 |
+
invariant(
|
12765 |
+
instance instanceof Klass,
|
12766 |
+
'Trying to release an instance into a pool of a different type.'
|
12767 |
+
);
|
12768 |
+
instance.destructor();
|
12769 |
+
if (Klass.instancePool.length < Klass.poolSize) {
|
12770 |
+
Klass.instancePool.push(instance);
|
12771 |
+
}
|
12772 |
+
};
|
12773 |
+
|
12774 |
+
var fourArgumentPooler = function fourArgumentPooler(a1, a2, a3, a4) {
|
12775 |
+
var Klass = this;
|
12776 |
+
if (Klass.instancePool.length) {
|
12777 |
+
var instance = Klass.instancePool.pop();
|
12778 |
+
Klass.call(instance, a1, a2, a3, a4);
|
12779 |
+
return instance;
|
12780 |
+
} else {
|
12781 |
+
return new Klass(a1, a2, a3, a4);
|
12782 |
+
}
|
12783 |
+
};
|
12784 |
+
|
12785 |
+
function MapBookKeeping(mapResult, keyPrefix, mapFunction, mapContext) {
|
12786 |
+
this.result = mapResult;
|
12787 |
+
this.keyPrefix = keyPrefix;
|
12788 |
+
this.func = mapFunction;
|
12789 |
+
this.context = mapContext;
|
12790 |
+
this.count = 0;
|
12791 |
+
}
|
12792 |
+
MapBookKeeping.prototype.destructor = function() {
|
12793 |
+
this.result = null;
|
12794 |
+
this.keyPrefix = null;
|
12795 |
+
this.func = null;
|
12796 |
+
this.context = null;
|
12797 |
+
this.count = 0;
|
12798 |
+
};
|
12799 |
+
addPoolingTo(MapBookKeeping, fourArgumentPooler);
|
12800 |
+
|
12801 |
+
function mapSingleChildIntoContext(bookKeeping, child, childKey) {
|
12802 |
+
var result = bookKeeping.result;
|
12803 |
+
var keyPrefix = bookKeeping.keyPrefix;
|
12804 |
+
var func = bookKeeping.func;
|
12805 |
+
var context = bookKeeping.context;
|
12806 |
+
|
12807 |
+
var mappedChild = func.call(context, child, bookKeeping.count++);
|
12808 |
+
if (Array.isArray(mappedChild)) {
|
12809 |
+
mapIntoWithKeyPrefixInternal(
|
12810 |
+
mappedChild,
|
12811 |
+
result,
|
12812 |
+
childKey,
|
12813 |
+
emptyFunction.thatReturnsArgument
|
12814 |
+
);
|
12815 |
+
} else if (mappedChild != null) {
|
12816 |
+
if (React.isValidElement(mappedChild)) {
|
12817 |
+
mappedChild = cloneAndReplaceKey(
|
12818 |
+
mappedChild,
|
12819 |
+
// Keep both the (mapped) and old keys if they differ, just as
|
12820 |
+
// traverseAllChildren used to do for objects as children
|
12821 |
+
keyPrefix +
|
12822 |
+
(mappedChild.key && (!child || child.key !== mappedChild.key)
|
12823 |
+
? escapeUserProvidedKey(mappedChild.key) + '/'
|
12824 |
+
: '') +
|
12825 |
+
childKey
|
12826 |
+
);
|
12827 |
+
}
|
12828 |
+
result.push(mappedChild);
|
12829 |
+
}
|
12830 |
+
}
|
12831 |
+
|
12832 |
+
function mapIntoWithKeyPrefixInternal(children, array, prefix, func, context) {
|
12833 |
+
var escapedPrefix = '';
|
12834 |
+
if (prefix != null) {
|
12835 |
+
escapedPrefix = escapeUserProvidedKey(prefix) + '/';
|
12836 |
+
}
|
12837 |
+
var traverseContext = MapBookKeeping.getPooled(
|
12838 |
+
array,
|
12839 |
+
escapedPrefix,
|
12840 |
+
func,
|
12841 |
+
context
|
12842 |
+
);
|
12843 |
+
traverseAllChildren(children, mapSingleChildIntoContext, traverseContext);
|
12844 |
+
MapBookKeeping.release(traverseContext);
|
12845 |
+
}
|
12846 |
+
|
12847 |
+
var numericPropertyRegex = /^\d+$/;
|
12848 |
+
|
12849 |
+
var warnedAboutNumeric = false;
|
12850 |
+
|
12851 |
+
function createReactFragment(object) {
|
12852 |
+
if (typeof object !== 'object' || !object || Array.isArray(object)) {
|
12853 |
+
warning(
|
12854 |
+
false,
|
12855 |
+
'React.addons.createFragment only accepts a single object. Got: %s',
|
12856 |
+
object
|
12857 |
+
);
|
12858 |
+
return object;
|
12859 |
+
}
|
12860 |
+
if (React.isValidElement(object)) {
|
12861 |
+
warning(
|
12862 |
+
false,
|
12863 |
+
'React.addons.createFragment does not accept a ReactElement ' +
|
12864 |
+
'without a wrapper object.'
|
12865 |
+
);
|
12866 |
+
return object;
|
12867 |
+
}
|
12868 |
+
|
12869 |
+
invariant(
|
12870 |
+
object.nodeType !== 1,
|
12871 |
+
'React.addons.createFragment(...): Encountered an invalid child; DOM ' +
|
12872 |
+
'elements are not valid children of React components.'
|
12873 |
+
);
|
12874 |
+
|
12875 |
+
var result = [];
|
12876 |
+
|
12877 |
+
for (var key in object) {
|
12878 |
+
if (false) {}
|
12879 |
+
mapIntoWithKeyPrefixInternal(
|
12880 |
+
object[key],
|
12881 |
+
result,
|
12882 |
+
key,
|
12883 |
+
emptyFunction.thatReturnsArgument
|
12884 |
+
);
|
12885 |
+
}
|
12886 |
+
|
12887 |
+
return result;
|
12888 |
+
}
|
12889 |
+
|
12890 |
+
module.exports = createReactFragment;
|
12891 |
+
|
12892 |
+
|
12893 |
+
/***/ }),
|
12894 |
+
|
12895 |
+
/***/ 7:
|
12896 |
+
/***/ (function(module, exports) {
|
12897 |
+
|
12898 |
+
(function() { module.exports = window["wp"]["data"]; }());
|
12899 |
+
|
12900 |
+
/***/ }),
|
12901 |
+
|
12902 |
+
/***/ 70:
|
12903 |
+
/***/ (function(module, exports, __webpack_require__) {
|
12904 |
+
|
12905 |
+
"use strict";
|
12906 |
+
/**
|
12907 |
+
* Copyright (c) 2013-present, Facebook, Inc.
|
12908 |
+
*
|
12909 |
+
* This source code is licensed under the MIT license found in the
|
12910 |
+
* LICENSE file in the root directory of this source tree.
|
12911 |
+
*
|
12912 |
+
*/
|
12913 |
+
|
12914 |
+
|
12915 |
+
|
12916 |
+
/**
|
12917 |
+
* Use invariant() to assert state which your program assumes to be true.
|
12918 |
+
*
|
12919 |
+
* Provide sprintf-style format (only %s is supported) and arguments
|
12920 |
+
* to provide information about what broke and what you were
|
12921 |
+
* expecting.
|
12922 |
+
*
|
12923 |
+
* The invariant message will be stripped in production, but the invariant
|
12924 |
+
* will remain to ensure logic does not differ in production.
|
12925 |
+
*/
|
12926 |
+
|
12927 |
+
var validateFormat = function validateFormat(format) {};
|
12928 |
+
|
12929 |
+
if (false) {}
|
12930 |
+
|
12931 |
+
function invariant(condition, format, a, b, c, d, e, f) {
|
12932 |
+
validateFormat(format);
|
12933 |
+
|
12934 |
+
if (!condition) {
|
12935 |
+
var error;
|
12936 |
+
if (format === undefined) {
|
12937 |
+
error = new Error('Minified exception occurred; use the non-minified dev environment ' + 'for the full error message and additional helpful warnings.');
|
12938 |
+
} else {
|
12939 |
+
var args = [a, b, c, d, e, f];
|
12940 |
+
var argIndex = 0;
|
12941 |
+
error = new Error(format.replace(/%s/g, function () {
|
12942 |
+
return args[argIndex++];
|
12943 |
+
}));
|
12944 |
+
error.name = 'Invariant Violation';
|
12945 |
+
}
|
12946 |
+
|
12947 |
+
error.framesToPop = 1; // we don't care about invariant's own frame
|
12948 |
+
throw error;
|
12949 |
+
}
|
12950 |
+
}
|
12951 |
+
|
12952 |
+
module.exports = invariant;
|
12953 |
+
|
12954 |
+
/***/ }),
|
12955 |
+
|
12956 |
+
/***/ 71:
|
12957 |
+
/***/ (function(module, exports, __webpack_require__) {
|
12958 |
+
|
12959 |
+
"use strict";
|
12960 |
+
/**
|
12961 |
+
* Copyright (c) 2014-present, Facebook, Inc.
|
12962 |
+
*
|
12963 |
+
* This source code is licensed under the MIT license found in the
|
12964 |
+
* LICENSE file in the root directory of this source tree.
|
12965 |
+
*
|
12966 |
+
*/
|
12967 |
+
|
12968 |
+
|
12969 |
+
|
12970 |
+
var emptyFunction = __webpack_require__(50);
|
12971 |
+
|
12972 |
+
/**
|
12973 |
+
* Similar to invariant but only logs a warning if the condition is not met.
|
12974 |
+
* This can be used to log issues in development environments in critical
|
12975 |
+
* paths. Removing the logging code for production environments will keep the
|
12976 |
+
* same logic and follow the same code paths.
|
12977 |
+
*/
|
12978 |
+
|
12979 |
+
var warning = emptyFunction;
|
12980 |
+
|
12981 |
+
if (false) { var printWarning; }
|
12982 |
+
|
12983 |
+
module.exports = warning;
|
12984 |
+
|
12985 |
+
/***/ }),
|
12986 |
+
|
12987 |
+
/***/ 72:
|
12988 |
+
/***/ (function(module, exports, __webpack_require__) {
|
12989 |
+
|
12990 |
+
"use strict";
|
12991 |
+
|
12992 |
+
|
12993 |
+
function identifyToken(item) {
|
12994 |
+
// {{/example}}
|
12995 |
+
if (item.match(/^\{\{\//)) {
|
12996 |
+
return {
|
12997 |
+
type: 'componentClose',
|
12998 |
+
value: item.replace(/\W/g, '')
|
12999 |
+
};
|
13000 |
+
}
|
13001 |
+
// {{example /}}
|
13002 |
+
if (item.match(/\/\}\}$/)) {
|
13003 |
+
return {
|
13004 |
+
type: 'componentSelfClosing',
|
13005 |
+
value: item.replace(/\W/g, '')
|
13006 |
+
};
|
13007 |
+
}
|
13008 |
+
// {{example}}
|
13009 |
+
if (item.match(/^\{\{/)) {
|
13010 |
+
return {
|
13011 |
+
type: 'componentOpen',
|
13012 |
+
value: item.replace(/\W/g, '')
|
13013 |
+
};
|
13014 |
+
}
|
13015 |
+
return {
|
13016 |
+
type: 'string',
|
13017 |
+
value: item
|
13018 |
+
};
|
13019 |
+
}
|
13020 |
+
|
13021 |
+
module.exports = function (mixedString) {
|
13022 |
+
var tokenStrings = mixedString.split(/(\{\{\/?\s*\w+\s*\/?\}\})/g); // split to components and strings
|
13023 |
+
return tokenStrings.map(identifyToken);
|
13024 |
+
};
|
13025 |
+
//# sourceMappingURL=tokenize.js.map
|
13026 |
+
|
13027 |
+
/***/ }),
|
13028 |
+
|
13029 |
+
/***/ 76:
|
13030 |
+
/***/ (function(module, exports) {
|
13031 |
+
|
13032 |
+
(function() { module.exports = window["wp"]["plugins"]; }());
|
13033 |
+
|
13034 |
+
/***/ }),
|
13035 |
+
|
13036 |
+
/***/ 79:
|
13037 |
+
/***/ (function(module, exports) {
|
13038 |
+
|
13039 |
+
var g;
|
13040 |
+
|
13041 |
+
// This works in non-strict mode
|
13042 |
+
g = (function() {
|
13043 |
+
return this;
|
13044 |
+
})();
|
13045 |
+
|
13046 |
+
try {
|
13047 |
+
// This works if eval is allowed (see CSP)
|
13048 |
+
g = g || new Function("return this")();
|
13049 |
+
} catch (e) {
|
13050 |
+
// This works if the window reference is available
|
13051 |
+
if (typeof window === "object") g = window;
|
13052 |
+
}
|
13053 |
+
|
13054 |
+
// g can still be undefined, but nothing to do about it...
|
13055 |
+
// We return undefined, instead of nothing here, so it's
|
13056 |
+
// easier to handle this case. if(!global) { ...}
|
13057 |
+
|
13058 |
+
module.exports = g;
|
13059 |
+
|
13060 |
+
|
13061 |
+
/***/ }),
|
13062 |
+
|
13063 |
+
/***/ 8:
|
13064 |
+
/***/ (function(module, exports) {
|
13065 |
+
|
13066 |
+
(function() { module.exports = window["wp"]["primitives"]; }());
|
13067 |
+
|
13068 |
+
/***/ }),
|
13069 |
+
|
13070 |
+
/***/ 89:
|
13071 |
+
/***/ (function(module, exports) {
|
13072 |
+
|
13073 |
+
(function() { module.exports = window["wc"]["currency"]; }());
|
13074 |
+
|
13075 |
+
/***/ }),
|
13076 |
+
|
13077 |
+
/***/ 9:
|
13078 |
+
/***/ (function(module, exports) {
|
13079 |
+
|
13080 |
+
(function() { module.exports = window["moment"]; }());
|
13081 |
+
|
13082 |
+
/***/ }),
|
13083 |
+
|
13084 |
+
/***/ 91:
|
13085 |
+
/***/ (function(module, exports) {
|
13086 |
+
|
13087 |
+
(function() { module.exports = window["wp"]["dom"]; }());
|
13088 |
+
|
13089 |
+
/***/ })
|
13090 |
+
|
13091 |
+
/******/ });
|
trunk/dist/app/index.min.asset.php
ADDED
@@ -0,0 +1 @@
|
|
|
1 |
+
<?php return array('dependencies' => array('lodash', 'moment', 'react', 'react-dom', 'wc-components', 'wc-csv', 'wc-currency', 'wc-customer-effort-score', 'wc-date', 'wc-experimental', 'wc-explat', 'wc-navigation', 'wc-notices', 'wc-number', 'wc-settings', 'wc-store-data', 'wc-tracks', 'wp-a11y', 'wp-api-fetch', 'wp-components', 'wp-compose', 'wp-data', 'wp-data-controls', 'wp-date', 'wp-dom', 'wp-element', 'wp-hooks', 'wp-html-entities', 'wp-i18n', 'wp-keycodes', 'wp-notices', 'wp-plugins', 'wp-primitives', 'wp-url', 'wp-warning'), 'version' => '063c3916edad745c18f019a24aa04a9b');
|
trunk/dist/app/index.min.js
ADDED
@@ -0,0 +1,2 @@
|
|
|
|
|
1 |
+
/*! For license information please see index.min.js.LICENSE.txt */
|
2 |
+
this.wc=this.wc||{},this.wc.app=function(e){function t(t){for(var n,r,i=t[0],a=t[1],c=0,s=[];c<i.length;c++)r=i[c],Object.prototype.hasOwnProperty.call(o,r)&&o[r]&&s.push(o[r][0]),o[r]=0;for(n in a)Object.prototype.hasOwnProperty.call(a,n)&&(e[n]=a[n]);for(u&&u(t);s.length;)s.shift()()}var n={},r={17:0},o={17:0};function i(e){var t=function(e){return a.p+"chunks/"+({3:"activity-panels-help",4:"activity-panels-inbox",5:"analytics-report",6:"analytics-report-categories",7:"analytics-report-coupons",8:"analytics-report-customers",9:"analytics-report-downloads",10:"analytics-report-orders",11:"analytics-report-products",12:"analytics-report-revenue",13:"analytics-report-stock",14:"analytics-report-taxes",15:"analytics-report-variations",16:"analytics-settings",23:"customizable-dashboard",24:"dashboard",25:"dashboard-charts",30:"homescreen",31:"leaderboards",33:"marketing-overview",44:"payment-recommendations",46:"profile-wizard",47:"shipping-recommendations",48:"store-alerts",49:"store-performance",51:"two-column-tasks",52:"two-column-tasks-extended",53:"wcpay-usage-modal"}[e]||e)+".min.js"}(e);return window.wcAdminAssets&&window.wcAdminAssets.version&&(t+="?ver="+window.wcAdminAssets.version),t}function a(t){if(n[t])return n[t].exports;var r=n[t]={i:t,l:!1,exports:{}};return e[t].call(r.exports,r,r.exports,a),r.l=!0,r.exports}a.e=function(e){var t=[];r[e]?t.push(r[e]):0!==r[e]&&{0:1,3:1,4:1,5:1,6:1,8:1,10:1,11:1,13:1,16:1,24:1,25:1,30:1,31:1,33:1,44:1,46:1,47:1,48:1,49:1,51:1}[e]&&t.push(r[e]=new Promise((function(t,n){for(var o="chunks/"+e+".style.css",i=a.p+o,c=document.getElementsByTagName("link"),s=0;s<c.length;s++){var l=(d=c[s]).getAttribute("data-href")||d.getAttribute("href");if("stylesheet"===d.rel&&(l===o||l===i))return t()}var u=document.getElementsByTagName("style");for(s=0;s<u.length;s++){var d;if((l=(d=u[s]).getAttribute("data-href"))===o||l===i)return t()}var m=document.createElement("link");m.rel="stylesheet",m.type="text/css",m.setAttribute("data-webpack",!0),m.onload=t,m.onerror=function(t){var o=t&&t.target&&t.target.src||i,a=new Error("Loading CSS chunk "+e+" failed.\n("+o+")");a.code="CSS_CHUNK_LOAD_FAILED",a.request=o,delete r[e],m.parentNode.removeChild(m),n(a)},m.href=i,window.wcAdminAssets&&window.wcAdminAssets.version&&(m.href+="?ver="+window.wcAdminAssets.version),document.getElementsByTagName("head")[0].appendChild(m)})).then((function(){r[e]=0})));var n=o[e];if(0!==n)if(n)t.push(n[2]);else{var c=new Promise((function(t,r){n=o[e]=[t,r]}));t.push(n[2]=c);var s,l=document.createElement("script");l.charset="utf-8",l.timeout=120,a.nc&&l.setAttribute("nonce",a.nc),l.src=i(e);var u=new Error;s=function(t){l.onerror=l.onload=null,clearTimeout(d);var n=o[e];if(0!==n){if(n){var r=t&&("load"===t.type?"missing":t.type),i=t&&t.target&&t.target.src;u.message="Loading chunk "+e+" failed.\n("+r+": "+i+")",u.name="ChunkLoadError",u.type=r,u.request=i,n[1](u)}o[e]=void 0}};var d=setTimeout((function(){s({type:"timeout",target:l})}),12e4);l.onerror=l.onload=s,document.head.appendChild(l)}return Promise.all(t)},a.m=e,a.c=n,a.d=function(e,t,n){a.o(e,t)||Object.defineProperty(e,t,{enumerable:!0,get:n})},a.r=function(e){"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})},a.t=function(e,t){if(1&t&&(e=a(e)),8&t)return e;if(4&t&&"object"==typeof e&&e&&e.__esModule)return e;var n=Object.create(null);if(a.r(n),Object.defineProperty(n,"default",{enumerable:!0,value:e}),2&t&&"string"!=typeof e)for(var r in e)a.d(n,r,function(t){return e[t]}.bind(null,r));return n},a.n=function(e){var t=e&&e.__esModule?function(){return e.default}:function(){return e};return a.d(t,"a",t),t},a.o=function(e,t){return Object.prototype.hasOwnProperty.call(e,t)},a.p="",a.oe=function(e){throw console.error(e),e};var c=window.__wcAdmin_webpackJsonp=window.__wcAdmin_webpackJsonp||[],s=c.push.bind(c);c.push=t,c=c.slice();for(var l=0;l<c.length;l++)t(c[l]);var u=s;return a(a.s=281)}({0:function(e,t){e.exports=window.wp.element},1:function(e,t,n){e.exports=n(48)()},10:function(e,t){e.exports=window.wp.dataControls},101:function(e,t,n){"use strict";var r=Object.assign||function(e){for(var t,n=1;n<arguments.length;n++)for(var r in t=arguments[n])Object.prototype.hasOwnProperty.call(t,r)&&(e[r]=t[r]);return e};Object.defineProperty(t,"__esModule",{value:!0}),t.default=function(e){var t=e.size,n=void 0===t?24:t,o=e.onClick,i=(e.icon,e.className),c=function(e,t){var n={};for(var r in e)0<=t.indexOf(r)||Object.prototype.hasOwnProperty.call(e,r)&&(n[r]=e[r]);return n}(e,["size","onClick","icon","className"]),s=["gridicon","gridicons-cross-small",i,!1,!1,!1].filter(Boolean).join(" ");return a.default.createElement("svg",r({className:s,height:n,width:n,onClick:o},c,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"}),a.default.createElement("g",null,a.default.createElement("path",{d:"M17.705 7.705l-1.41-1.41L12 10.59 7.705 6.295l-1.41 1.41L10.59 12l-4.295 4.295 1.41 1.41L12 13.41l4.295 4.295 1.41-1.41L13.41 12l4.295-4.295z"})))};var o,i=n(5),a=(o=i)&&o.__esModule?o:{default:o};e.exports=t.default},103:function(e,t,n){"use strict";n.d(t,"a",(function(){return o})),n.d(t,"c",(function(){return i})),n.d(t,"b",(function(){return a}));var r=n(11);const o=5,i={page:1,per_page:1,status:"hold",_embed:1,_fields:["id"]};function a(e){const{getReviewsTotalCount:t,getReviewsError:n,isResolving:o}=e(r.REVIEWS_STORE_NAME),a=t(i),c=Boolean(n(i)),s=o("getReviewsTotalCount",[i]);return c||s&&void 0===a?null:a}},104:function(e,t,n){"use strict";e.exports=n(129)},11:function(e,t){e.exports=window.wc.data},116:function(e,t,n){"use strict";function r(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}var o=n(22);var i=n(0);function a(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}t.a=function(e){var t=e.icon,n=e.size,c=void 0===n?24:n,s=function(e,t){if(null==e)return{};var n,r,i=Object(o.a)(e,t);if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(e);for(r=0;r<a.length;r++)n=a[r],t.indexOf(n)>=0||Object.prototype.propertyIsEnumerable.call(e,n)&&(i[n]=e[n])}return i}(e,["icon","size"]);return Object(i.cloneElement)(t,function(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?a(Object(n),!0).forEach((function(t){r(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):a(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}({width:c,height:c},s))}},117:function(e,t,n){"use strict";var r=n(2),o=n(31),i=n(13),a=n(0);const c=Object(i.f)("manageStock","no"),s=Object(a.lazy)(()=>Promise.all([n.e(0),n.e(12)]).then(n.bind(null,483))),l=Object(a.lazy)(()=>Promise.all([n.e(0),n.e(11)]).then(n.bind(null,479))),u=Object(a.lazy)(()=>Promise.all([n.e(0),n.e(15)]).then(n.bind(null,484))),d=Object(a.lazy)(()=>Promise.all([n.e(0),n.e(10)]).then(n.bind(null,485))),m=Object(a.lazy)(()=>Promise.all([n.e(0),n.e(6)]).then(n.bind(null,481))),p=Object(a.lazy)(()=>Promise.all([n.e(0),n.e(7)]).then(n.bind(null,486))),f=Object(a.lazy)(()=>Promise.all([n.e(0),n.e(14)]).then(n.bind(null,487))),h=Object(a.lazy)(()=>Promise.all([n.e(0),n.e(9)]).then(n.bind(null,488))),b=Object(a.lazy)(()=>n.e(13).then(n.bind(null,480))),v=Object(a.lazy)(()=>n.e(8).then(n.bind(null,482)));t.a=()=>{const e=[{report:"revenue",title:Object(r.__)("Revenue","woocommerce-admin"),component:s,navArgs:{id:"woocommerce-analytics-revenue"}},{report:"products",title:Object(r.__)("Products","woocommerce-admin"),component:l,navArgs:{id:"woocommerce-analytics-products"}},{report:"variations",title:Object(r.__)("Variations","woocommerce-admin"),component:u,navArgs:{id:"woocommerce-analytics-variations"}},{report:"orders",title:Object(r.__)("Orders","woocommerce-admin"),component:d,navArgs:{id:"woocommerce-analytics-orders"}},{report:"categories",title:Object(r.__)("Categories","woocommerce-admin"),component:m,navArgs:{id:"woocommerce-analytics-categories"}},{report:"coupons",title:Object(r.__)("Coupons","woocommerce-admin"),component:p,navArgs:{id:"woocommerce-analytics-coupons"}},{report:"taxes",title:Object(r.__)("Taxes","woocommerce-admin"),component:f,navArgs:{id:"woocommerce-analytics-taxes"}},"yes"===c?{report:"stock",title:Object(r.__)("Stock","woocommerce-admin"),component:b,navArgs:{id:"woocommerce-analytics-stock"}}:null,{report:"customers",title:Object(r.__)("Customers","woocommerce-admin"),component:v},{report:"downloads",title:Object(r.__)("Downloads","woocommerce-admin"),component:h,navArgs:{id:"woocommerce-analytics-downloads"}}].filter(Boolean);return Object(o.applyFilters)("woocommerce_admin_reports_list",e)}},118:function(e,t,n){"use strict";var r=n(104),o={childContextTypes:!0,contextType:!0,contextTypes:!0,defaultProps:!0,displayName:!0,getDefaultProps:!0,getDerivedStateFromError:!0,getDerivedStateFromProps:!0,mixins:!0,propTypes:!0,type:!0},i={name:!0,length:!0,prototype:!0,caller:!0,callee:!0,arguments:!0,arity:!0},a={$$typeof:!0,compare:!0,defaultProps:!0,displayName:!0,propTypes:!0,type:!0},c={};function s(e){return r.isMemo(e)?a:c[e.$$typeof]||o}c[r.ForwardRef]={$$typeof:!0,render:!0,defaultProps:!0,displayName:!0,propTypes:!0},c[r.Memo]=a;var l=Object.defineProperty,u=Object.getOwnPropertyNames,d=Object.getOwnPropertySymbols,m=Object.getOwnPropertyDescriptor,p=Object.getPrototypeOf,f=Object.prototype;e.exports=function e(t,n,r){if("string"!=typeof n){if(f){var o=p(n);o&&o!==f&&e(t,o,r)}var a=u(n);d&&(a=a.concat(d(n)));for(var c=s(t),h=s(n),b=0;b<a.length;++b){var v=a[b];if(!(i[v]||r&&r[v]||h&&h[v]||c&&c[v])){var g=m(n,v);try{l(t,v,g)}catch(e){}}}}return t}},119:function(e,t,n){"use strict";n.d(t,"c",(function(){return bt})),n.d(t,"b",(function(){return wt})),n.d(t,"a",(function(){return Ot}));var r=n(36),o=n.n(r),i=n(0),a=n(3),c=n(14),s=n(7),l=n(25),u=n(5),d=n.n(u),m=n(1),p=n.n(m),f=n(52),h=n(160),b=n(43),v=n(23),g=n(161),y=n.n(g),w=(n(104),n(22)),O=(n(118),function(e){var t=Object(h.a)();return t.displayName=e,t}("Router-History")),j=function(e){var t=Object(h.a)();return t.displayName=e,t}("Router"),_=function(e){function t(t){var n;return(n=e.call(this,t)||this).state={location:t.history.location},n._isMounted=!1,n._pendingLocation=null,t.staticContext||(n.unlisten=t.history.listen((function(e){n._isMounted?n.setState({location:e}):n._pendingLocation=e}))),n}Object(l.a)(t,e),t.computeRootMatch=function(e){return{path:"/",url:"/",params:{},isExact:"/"===e}};var n=t.prototype;return n.componentDidMount=function(){this._isMounted=!0,this._pendingLocation&&this.setState({location:this._pendingLocation})},n.componentWillUnmount=function(){this.unlisten&&this.unlisten()},n.render=function(){return d.a.createElement(j.Provider,{value:{history:this.props.history,location:this.state.location,match:t.computeRootMatch(this.state.location.pathname),staticContext:this.props.staticContext}},d.a.createElement(O.Provider,{children:this.props.children||null,value:this.props.history}))},t}(d.a.Component);d.a.Component;d.a.Component;var E={},k=0;function x(e,t){void 0===t&&(t={}),("string"==typeof t||Array.isArray(t))&&(t={path:t});var n=t,r=n.path,o=n.exact,i=void 0!==o&&o,a=n.strict,c=void 0!==a&&a,s=n.sensitive,l=void 0!==s&&s;return[].concat(r).reduce((function(t,n){if(!n&&""!==n)return null;if(t)return t;var r=function(e,t){var n=""+t.end+t.strict+t.sensitive,r=E[n]||(E[n]={});if(r[e])return r[e];var o=[],i={regexp:y()(e,o,t),keys:o};return k<1e4&&(r[e]=i,k++),i}(n,{end:i,strict:c,sensitive:l}),o=r.regexp,a=r.keys,s=o.exec(e);if(!s)return null;var u=s[0],d=s.slice(1),m=e===u;return i&&!m?null:{path:n,url:"/"===n&&""===u?"/":u,isExact:m,params:a.reduce((function(e,t,n){return e[t.name]=d[n],e}),{})}}),null)}var C=function(e){function t(){return e.apply(this,arguments)||this}return Object(l.a)(t,e),t.prototype.render=function(){var e=this;return d.a.createElement(j.Consumer,null,(function(t){t||Object(b.a)(!1);var n=e.props.location||t.location,r=e.props.computedMatch?e.props.computedMatch:e.props.path?x(n.pathname,e.props):t.match,o=Object(v.a)({},t,{location:n,match:r}),i=e.props,a=i.children,c=i.component,s=i.render;return Array.isArray(a)&&0===a.length&&(a=null),d.a.createElement(j.Provider,{value:o},o.match?a?"function"==typeof a?a(o):a:c?d.a.createElement(c,o):s?s(o):null:"function"==typeof a?a(o):null)}))},t}(d.a.Component);function S(e){return"/"===e.charAt(0)?e:"/"+e}function T(e,t){if(!e)return t;var n=S(e);return 0!==t.pathname.indexOf(n)?t:Object(v.a)({},t,{pathname:t.pathname.substr(n.length)})}function A(e){return"string"==typeof e?e:Object(f.d)(e)}function P(e){return function(){Object(b.a)(!1)}}function N(){}d.a.Component;var R=function(e){function t(){return e.apply(this,arguments)||this}return Object(l.a)(t,e),t.prototype.render=function(){var e=this;return d.a.createElement(j.Consumer,null,(function(t){t||Object(b.a)(!1);var n,r,o=e.props.location||t.location;return d.a.Children.forEach(e.props.children,(function(e){if(null==r&&d.a.isValidElement(e)){n=e;var i=e.props.path||e.props.from;r=i?x(o.pathname,Object(v.a)({},e.props,{path:i})):t.match}})),r?d.a.cloneElement(n,{location:o,computedMatch:r}):null}))},t}(d.a.Component);d.a.useContext;var M=n(4),L=n(28),V=n(12),I=n(13),D=n(11),F=n(15),H=(n(284),n(76)),B=(n(285),n(31)),U=n(2),z=n(21),q=n(117),$=n(62),W=n(175);const G=Object(i.lazy)(()=>n.e(5).then(n.bind(null,618))),Q=Object(i.lazy)(()=>n.e(16).then(n.bind(null,628))),Y=Object(i.lazy)(()=>n.e(24).then(n.bind(null,619))),Z=Object(i.lazy)(()=>Promise.all([n.e(1),n.e(2),n.e(30)]).then(n.bind(null,625))),K=Object(i.lazy)(()=>Promise.all([n.e(2),n.e(33)]).then(n.bind(null,629))),J=Object(i.lazy)(()=>Promise.all([n.e(1),n.e(46)]).then(n.bind(null,626))),X=Object(i.lazy)(()=>Promise.all([n.e(1),n.e(46)]).then(n.bind(null,620))),ee=()=>{const e=[],t=[["",Object(I.f)("woocommerceTranslation")]];e.push({container:Z,path:"/",breadcrumbs:[...t,Object(U.__)("Home","woocommerce-admin")],wpOpenMenu:"toplevel_page_woocommerce",navArgs:{id:"woocommerce-home"},capability:"manage_woocommerce"}),window.wcAdminFeatures.analytics&&(e.push({container:Y,path:"/analytics/overview",breadcrumbs:[...t,["/analytics/overview",Object(U.__)("Analytics","woocommerce-admin")],Object(U.__)("Overview","woocommerce-admin")],wpOpenMenu:"toplevel_page_wc-admin-path--analytics-overview",navArgs:{id:"woocommerce-analytics-overview"},capability:"view_woocommerce_reports"}),e.push({container:Q,path:"/analytics/settings",breadcrumbs:[...t,["/analytics/revenue",Object(U.__)("Analytics","woocommerce-admin")],Object(U.__)("Settings","woocommerce-admin")],wpOpenMenu:"toplevel_page_wc-admin-path--analytics-overview",navArgs:{id:"woocommerce-analytics-settings"},capability:"view_woocommerce_reports"}),e.push({container:G,path:"/customers",breadcrumbs:[...t,Object(U.__)("Customers","woocommerce-admin")],wpOpenMenu:"toplevel_page_woocommerce",navArgs:{id:"woocommerce-analytics-customers"},capability:"view_woocommerce_reports"}),e.push({container:G,path:"/analytics/:report",breadcrumbs:({match:e})=>{const n=Object(M.find)(Object(q.a)(),{report:e.params.report});return n?[...t,["/analytics/revenue",Object(U.__)("Analytics","woocommerce-admin")],n.title]:[]},wpOpenMenu:"toplevel_page_wc-admin-path--analytics-overview",capability:"view_woocommerce_reports"})),window.wcAdminFeatures.marketing&&e.push({container:K,path:"/marketing",breadcrumbs:[...t,["/marketing",Object(U.__)("Marketing","woocommerce-admin")],Object(U.__)("Overview","woocommerce-admin")],wpOpenMenu:"toplevel_page_woocommerce-marketing",navArgs:{id:"woocommerce-marketing-overview"},capability:"view_woocommerce_reports"}),window.wcAdminFeatures.onboarding&&e.push({container:J,path:"/setup-wizard",breadcrumbs:[...t,["/setup-wizard",Object(U.__)("Setup Wizard","woocommerce-admin")]],capability:"manage_woocommerce"}),window.wcAdminFeatures.settings&&e.push({container:X,path:"/settings/:page",breadcrumbs:({match:e})=>{const n=Object(I.f)("settingsPages"),r=n[e.params.page];return r?[...t,[n.general?"/settings/general":"/settings/"+Object.keys(n)[0],Object(U.__)("Settings","woocommerce-admin")],r]:[]},wpOpenMenu:"toplevel_page_woocommerce",capability:"manage_woocommerce"});const n=Object(B.applyFilters)("woocommerce_admin_pages_list",e);return n.push({container:W.a,path:"*",breadcrumbs:[...t,Object(U.__)("Not allowed","woocommerce-admin")],wpOpenMenu:"toplevel_page_woocommerce"}),n};class te extends i.Component{componentDidMount(){window.document.documentElement.scrollTop=0,window.document.body.classList.remove("woocommerce-admin-is-loading")}componentDidUpdate(e){const t=Object(M.omit)(e.query,"chartType","filter","paged"),n=Object(M.omit)(this.props.query,"chartType","filter","paged");e.query.paged>1&&!Object(M.isEqual)(t,n)&&Object(V.getHistory)().replace(Object(V.getNewPath)({paged:1})),e.match.url!==this.props.match.url&&(window.document.documentElement.scrollTop=0)}render(){const{page:e,match:t,query:n}=this.props,{url:r,params:o}=t;return window.wpNavMenuUrlUpdate(n),window.wpNavMenuClassChange(e,r),Object(i.createElement)(i.Suspense,{fallback:Object(i.createElement)(z.Spinner,null)},Object(i.createElement)(e.container,{params:o,path:r,pathMatch:e.path,query:n}))}}window.wpNavMenuUrlUpdate=function(e){const t=Object(V.getPersistedQuery)(e),n=Object(V.getQueryExcludedScreens)();Array.from(document.querySelectorAll("#adminmenu a")).forEach(e=>function(e,t,n){if(Object($.f)(e.href)){const r=Object(M.last)(e.href.split("?")),o=Object(L.parse)(r),i=o.path||"homescreen",a=Object(V.getScreenFromPath)(i),c=n.includes(a),s="admin.php?"+Object(L.stringify)(Object.assign(o,c?{}:t));e.href=s,e.onclick=e=>{e.preventDefault(),Object(V.getHistory)().push(s)}}}(e,t,n))},window.wpNavMenuClassChange=function(e,t){const n=document.querySelector("#adminmenu");Array.from(n.getElementsByClassName("current")).forEach((function(e){e.classList.remove("current")}));Array.from(n.querySelectorAll(".wp-has-current-submenu")).forEach((function(e){e.classList.remove("wp-has-current-submenu"),e.classList.remove("wp-menu-open"),e.classList.remove("selected"),e.classList.add("wp-not-current-submenu"),e.classList.add("menu-top")}));const r="/"===t?"admin.php?page=wc-admin":"admin.php?page=wc-admin&path="+encodeURIComponent(t),o="/"===t?`li > a[href$="${r}"], li > a[href*="${r}?"]`:`li > a[href*="${r}"]`,i=n.querySelectorAll(o);if(Array.from(i).forEach((function(e){e.parentElement.classList.add("current")})),e.wpOpenMenu){const t=n.querySelector("#"+e.wpOpenMenu);t&&(t.classList.remove("wp-not-current-submenu"),t.classList.add("wp-has-current-submenu"),t.classList.add("wp-menu-open"),t.classList.add("current"))}document.querySelector("#wpwrap").classList.remove("wp-responsive-open")};var ne=n(6),re=n.n(ne),oe=n(29),ie=n(17),ae=n(116),ce=n(293),se=n(27),le=(n(286),n(8)),ue=Object(i.createElement)(le.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"},Object(i.createElement)(le.Path,{d:"M12 4.75a7.25 7.25 0 100 14.5 7.25 7.25 0 000-14.5zM3.25 12a8.75 8.75 0 1117.5 0 8.75 8.75 0 01-17.5 0zM12 8.75a1.5 1.5 0 01.167 2.99c-.465.052-.917.44-.917 1.01V14h1.5v-.845A3 3 0 109 10.25h1.5a1.5 1.5 0 011.5-1.5zM11.25 15v1.5h1.5V15h-1.5z"})),de=n(502),me=(n(287),n(164));const pe={page:1,per_page:D.QUERY_DEFAULTS.pageSize,status:"unactioned",type:D.QUERY_DEFAULTS.noteTypes,orderby:"date",order:"desc"};function fe(e){const{getNotes:t,getNotesError:n,isResolving:r}=e(D.NOTES_STORE_NAME),{getCurrentUser:o}=e(D.USER_STORE_NAME),i=o(),a=parseInt(i&&i.woocommerce_meta&&i.woocommerce_meta.activity_panel_inbox_last_read,10);if(!a)return null;t(pe);const c=Boolean(n("getNotes",[pe])),s=r("getNotes",[pe]);if(c||s)return null;const l=t(pe);return Object(me.a)(l,a)>0}const he=({icon:e,title:t,name:n,unread:r,selected:o,isPanelOpen:c,onTabClick:s})=>{const l=re()("woocommerce-layout__activity-panel-tab",{"is-active":c&&o,"has-unread":r}),u="activity-panel-tab-"+n;return Object(i.createElement)(a.Button,{role:"tab",className:l,"aria-selected":o,"aria-controls":"activity-panel-"+n,key:u,id:u,onClick:()=>{s(n)}},e,t," ",r&&Object(i.createElement)("span",{className:"screen-reader-text"},Object(U.__)("unread activity","woocommerce-admin")))},be=({tabs:e,onTabClick:t,selectedTab:n,tabOpen:r=!1})=>{const[{tabOpen:c,currentTab:s},l]=Object(i.useState)({tabOpen:r,currentTab:n});return Object(i.useEffect)(()=>{l({tabOpen:r,currentTab:n})},[r,n]),Object(i.createElement)(a.NavigableMenu,{role:"tablist",orientation:"horizontal",className:"woocommerce-layout__activity-panel-tabs"},e&&e.map((e,n)=>{if(e.component){const{component:t,options:r}=e;return Object(i.createElement)(t,o()({key:n},r))}return Object(i.createElement)(he,o()({key:n,index:n,isPanelOpen:c,selected:s===e.name},e,{onTabClick:()=>{const n=s!==e.name&&""!==s||!c;n&&s===e.name||Object(F.recordEvent)("activity_panel_open",{tab:e.name}),l({tabOpen:n,currentTab:e.name}),t(e,n)}}))}))},ve=()=>Object(i.createElement)("svg",{className:"woocommerce-layout__activity-panel-tab-icon setup-progress",width:"18",height:"18",viewBox:"0 0 24 24",fill:"none",xmlns:"http://www.w3.org/2000/svg"},Object(i.createElement)("path",{d:"M12 20C16.4183 20 20 16.4183 20 12C20 7.58172 16.4183 4 12 4C7.58172 4 4 7.58172 4 12C4 16.4183 7.58172 20 12 20Z",stroke:"#DCDCDE",strokeWidth:"2"}),Object(i.createElement)("path",{d:"M4 12V12C4 16.4183 7.58172 20 12 20V20C16.4183 20 20 16.4183 20 12V12C20 7.58172 16.4183 4 12 4V4",strokeWidth:"2",strokeLinecap:"round"})),ge=()=>Object(i.createElement)("svg",{width:"24",height:"24",viewBox:"0 0 24 24",fill:"none",xmlns:"http://www.w3.org/2000/svg"},Object(i.createElement)("mask",{id:"mask0_2915:6733",maskUnits:"userSpaceOnUse",x:"4",y:"3",width:"16",height:"18"},Object(i.createElement)("path",{fillRule:"evenodd",clipRule:"evenodd",d:"M4.5 3.5H13.5L13.9 5.5H19.5V15.5H12.5L12.1 13.5H6.5V20.5H4.5V3.5ZM12.26 7.5L11.86 5.5H6.5V11.5H13.74L14.14 13.5H17.5V7.5H12.26Z",fill:"white"})),Object(i.createElement)("g",{mask:"url(#mask0_2915:6733)"},Object(i.createElement)("rect",{width:"24",height:"24",fill:"#50575E"})));var ye=n(170),we=n(499);n(288);const Oe="highlight-tooltip__show";function je({title:e,closeButtonText:t,content:n,show:r=!0,id:o,onClose:c,delay:s,onShow:l=M.noop,useAnchor:u=!1}){const[d,m]=Object(i.useState)(s>0?null:r),[p,f]=Object(i.useState)(null),[h,b]=Object(i.useState)(null);function v(){if(u){const e=document.getElementById(o);b(e.getBoundingClientRect())}}Object(i.useEffect)(()=>{const e=document.getElementById(o);let t,n;e&&!p&&(u?(n=document.createElement("div"),document.body.appendChild(n)):n=e.parentElement,t=document.createElement("div"),t.classList.add("highlight-tooltip__container"),n.appendChild(t),f(t));const r=g(t);return()=>{if(t){const e=t.parentElement;e.removeChild(t),u&&e.remove()}r&&clearTimeout(r)}},[]),Object(i.useEffect)(()=>{!d&&p&&p.classList.remove(Oe)},[d]),Object(i.useEffect)(()=>{r!==d&&null!==d&&p&&(m(r),r?p&&g(p):p.classList.remove(Oe))},[r]),Object(i.useLayoutEffect)(()=>(window.addEventListener("resize",v),()=>window.removeEventListener("resize",v)),[]);const g=e=>{let t=null;return s>0?t=setTimeout(()=>{t=null,y(e)},s):d||y(e),t},y=e=>{const t=document.getElementById(o);t&&u&&b(t.getBoundingClientRect()),e&&e.classList.add(Oe),m(!0),l()},w=()=>{m(!1),c&&c()};return p?Object(i.createPortal)(Object(i.createElement)("div",{className:"highlight-tooltip__portal"},d?Object(i.createElement)(i.Fragment,null,Object(i.createElement)(a.IsolatedEventContainer,{className:"highlight-tooltip__overlay"}),Object(i.createElement)(a.Popover,{className:"highlight-tooltip__popover",noArrow:!1,anchorRect:h,focusOnMount:"container"},Object(i.createElement)(a.Card,{size:"medium"},Object(i.createElement)(a.CardHeader,null,e,Object(i.createElement)(a.Button,{isSmall:!0,onClick:w,icon:we.a})),Object(i.createElement)(a.CardBody,null,n||null),Object(i.createElement)(a.CardFooter,{isBorderless:!0},Object(i.createElement)(a.Button,{size:"small",isPrimary:!0,onClick:w},t||Object(U.__)("Close","woocommerce-admin")))))):null),p):null}je.propTypes={id:p.a.string.isRequired,title:p.a.string.isRequired,closeButtonText:p.a.string.isRequired,content:p.a.oneOfType([p.a.string,p.a.node]),show:p.a.bool,onClose:p.a.func,delay:p.a.number,onShow:p.a.func,useAnchor:p.a.bool};var _e=n(91);const Ee=["button","submit"];function ke(e){const t=Object(i.useRef)(e);Object(i.useEffect)(()=>{t.current=e},[e]);const n=Object(i.useRef)(!1),r=Object(i.useRef)(),o=Object(i.useCallback)(()=>{clearTimeout(r.current)},[]);Object(i.useEffect)(()=>()=>o(),[]),Object(i.useEffect)(()=>{e||o()},[e,o]);const a=Object(i.useCallback)(e=>{const{type:t,target:r}=e;Object(M.includes)(["mouseup","touchend"],t)?n.current=!1:function(e){if(!(e instanceof window.HTMLElement))return!1;switch(e.nodeName){case"A":case"BUTTON":return!0;case"INPUT":return Object(M.includes)(Ee,e.type)}return!1}(r)&&(n.current=!0)},[]),c=Object(i.useCallback)(e=>{e.persist(),n.current||(r.current=setTimeout(()=>{document.hasFocus()?"function"==typeof t.current&&t.current(e):e.preventDefault()},0))},[]);return{onFocus:o,onMouseDown:a,onMouseUp:a,onTouchStart:a,onTouchEnd:a,onBlur:c}}const xe=({content:e,isPanelOpen:t,isPanelSwitching:n,currentTab:r,tab:a,closePanel:c,clearPanel:s})=>{const l="woocommerce-layout__activity-panel-wrapper",u=function(e="firstElement"){const t=Object(i.useRef)(e);return Object(i.useEffect)(()=>{t.current=e},[e]),Object(i.useCallback)(e=>{if(!e||!1===t.current)return;if(e.contains(e.ownerDocument.activeElement))return;let n=e;if("firstElement"===t.current){const t=_e.focus.tabbable.find(e)[0];t&&(n=t)}n.focus()},[])}(),d=ke(e=>{const n=e.relatedTarget&&(e.relatedTarget.closest(".woocommerce-inbox-dismiss-confirmation_modal")||e.relatedTarget.closest(".components-snackbar__action"));t&&!n&&c()}),m=Object(i.useRef)(null),p=Object(i.useCallback)(e=>{m.current=e,u(e)},[]);if(!a)return Object(i.createElement)("div",{className:l});if(!e)return null;const f=re()(l,{"is-open":t,"is-switching":n});return Object(i.createElement)("div",o()({className:f,tabIndex:0,role:"tabpanel","aria-label":a.title,onTransitionEnd:e=>{e&&"transform"===e.propertyName&&(s(),m.current&&t&&a&&u(m.current))}},d,{ref:p}),Object(i.createElement)("div",{className:"woocommerce-layout__activity-panel-content",key:"activity-panel-"+r,id:"activity-panel-"+r},Object(i.createElement)(i.Suspense,{fallback:Object(i.createElement)(z.Spinner,null)},e)))};var Ce=n(68),Se=n(103),Te=n(255);const Ae=Object(i.lazy)(()=>n.e(3).then(n.bind(null,633))),Pe=Object(i.lazy)(()=>Promise.all([n.e(2),n.e(4)]).then(n.bind(null,621))),Ne=({isEmbedded:e,query:t,userPreferencesData:n})=>{const[r,o]=Object(i.useState)(""),[a,c]=Object(i.useState)(!1),[l,u]=Object(i.useState)(!1),[d,m]=Object(i.useState)(!1),{fills:p}=Object(ie.useSlot)(Te.a),f=Boolean(null==p?void 0:p.length),h=(e,n)=>{let r={};if("wc-admin"===t.page&&"appearance"===t.task){var o,i,a;const{getTaskLists:t}=e(D.ONBOARDING_STORE_NAME),c=t().reduce((e,t)=>[...e,...t.tasks],[]).find(e=>"appearance"===e.id);r={set_notice:n("woocommerce_demo_store_notice")?"Y":"N",create_homepage:!0===(null==c||null===(o=c.additionalData)||void 0===o?void 0:o.hasHomepage)?"Y":"N",upload_logo:null!=c&&null!==(i=c.additionalData)&&void 0!==i&&null!==(a=i.themeMods)&&void 0!==a&&a.custom_logo?"Y":"N"}}return r};function b(e,t,n){const r=Object(Ce.c)(e),o=!(!t||!l)&&Object(Ce.d)(e,r)>0,i=!(!t||!l)&&Object(Se.b)(e),a=!(!t||!l)&&Object(Ce.a)(e);return n>0||o||i||a||f}const{hasUnreadNotes:v,hasAbbreviatedNotifications:g,isCompletedTask:y,thingsToDoNextCount:w,requestingTaskListOptions:O,setupTaskListComplete:j,setupTaskListHidden:_,previewSiteBtnTrackData:E}=Object(s.useSelect)(e=>{var n,r,o;const{getOption:i}=e(D.OPTIONS_STORE_NAME),{getTask:a,getTaskList:c,hasFinishedResolution:s}=e(D.ONBOARDING_STORE_NAME),l=null===(n=c("setup"))||void 0===n?void 0:n.isHidden,u=function(e){return e&&e.tasks.length&&!e.isHidden?e.tasks.filter(e=>e.canView&&!e.isComplete&&!e.isDismissed).length:0}(c("extended"));return{hasUnreadNotes:fe(e),hasAbbreviatedNotifications:b(e,l,u),thingsToDoNextCount:u,requestingTaskListOptions:!s("getTaskLists"),setupTaskListComplete:null===(r=c("setup"))||void 0===r?void 0:r.isComplete,setupTaskListHidden:l,isCompletedTask:Boolean(t.task&&(null===(o=a(t.task))||void 0===o?void 0:o.isComplete)),previewSiteBtnTrackData:h(e,i)}}),{unhideTaskList:k}=Object(s.useDispatch)(D.ONBOARDING_STORE_NAME),{currentUserCan:x}=Object(D.useUser)(),C=()=>"wc-admin"===t.page&&!t.path,S=()=>t.task&&!t.path&&(!0===O||!1===_&&!1===j),T=()=>{Object($.f)(window.location.href)?Object(V.getHistory)().push(Object(V.getNewPath)({},"/",{})):window.location.href=Object(I.e)("admin.php?page=wc-admin")},A=()=>{const n={name:"activity",title:Object(U.__)("Activity","woocommerce-admin"),icon:Object(i.createElement)(ge,null),unread:v||g,visible:(e||!C())&&!S()},r={name:"setup",title:Object(U.__)("Finish setup","woocommerce-admin"),icon:Object(i.createElement)(ve,null),onClick:()=>(window.location.href!==Object(I.e)("admin.php?page=wc-admin")&&("no"===_?T():k("setup").then(T)),null),visible:x("manage_woocommerce")&&!O&&!j&&!_&&!S()&&(!C()||e)},o={name:"help",title:Object(U.__)("Help","woocommerce-admin"),icon:Object(i.createElement)(ae.a,{icon:ue}),visible:x("manage_woocommerce")&&(C()&&!e||S())},a={component:ye.b,visible:x("manage_woocommerce")&&!e&&C()&&!S()};return[n,r,{name:"previewSite",title:Object(U.__)("Preview site","woocommerce-admin"),icon:Object(i.createElement)(ae.a,{icon:de.a}),visible:"wc-admin"===t.page&&"appearance"===t.task,onClick:()=>(window.open(Object(I.f)("siteUrl")),Object(F.recordEvent)("wcadmin_tasklist_previewsite",E),null)},a,o].filter(e=>e.visible)},P=A(),N=Object(M.uniqueId)("activity-panel-header_"),R=(()=>{const{task:e}=t,r=n&&n.task_list_tracked_started_tasks,o=n&&n.help_panel_highlight_shown;return!(!(e&&"yes"!==o&&(r||{})[e]>1)||y)})();return Object(i.createElement)("div",null,Object(i.createElement)(z.H,{id:N,className:"screen-reader-text"},Object(U.__)("Store Activity","woocommerce-admin")),Object(i.createElement)(z.Section,{component:"aside",id:"woocommerce-activity-panel",className:"woocommerce-layout__activity-panel","aria-labelledby":N},Object(i.createElement)(be,{tabs:P,tabOpen:l,selectedTab:r,onTabClick:(e,t)=>{e.onClick?e.onClick():(({name:e},t)=>{const n=e!==r&&""!==r&&t&&l;a||(o(e),u(t),m(n))})(e,t)}}),Object(i.createElement)(xe,{currentTab:!0,isPanelOpen:l,isPanelSwitching:d,tab:Object(M.find)(A(),{name:r}),content:(e=>{const{task:n}=t;switch(e){case"activity":return Object(i.createElement)(Pe,{hasAbbreviatedNotifications:g,thingsToDoNextCount:w});case"help":return Object(i.createElement)(Ae,{taskName:n});default:return null}})(r),closePanel:()=>(c(!0),void u(!1)),clearPanel:()=>{l||(c(!1),m(!1),o(""))}})),R?Object(i.createElement)(je,{delay:1e3,useAnchor:!0,title:Object(U.__)("We're here for help","woocommerce-admin"),content:Object(U.__)("If you have any questions, feel free to explore the WooCommerce docs listed here.","woocommerce-admin"),closeButtonText:Object(U.__)("Got it","woocommerce-admin"),id:"activity-panel-tab-help",onClose:()=>(Object(F.recordEvent)("help_tooltip_click"),void(n&&n.updateUserPreferences&&n.updateUserPreferences({help_panel_highlight_shown:"yes"}))),onShow:()=>Object(F.recordEvent)("help_tooltip_view")}):null)};Ne.defaultProps={getHistory:V.getHistory};var Re=Ne,Me=n(101),Le=n.n(Me);const Ve=()=>/iPhone|iPad|iPod/i.test(window.navigator.userAgent)?"ios":/Android/i.test(window.navigator.userAgent)?"android":"unknown",Ie=()=>Object(i.createElement)("svg",{width:"37",height:"37",viewBox:"0 0 92 92",fill:"none",xmlns:"http://www.w3.org/2000/svg"},Object(i.createElement)("rect",{width:"92",height:"92",rx:"21.3953",fill:"#7F54B3"}),Object(i.createElement)("path",{fillRule:"evenodd",clipRule:"evenodd",d:"M72.5937 28.043H19.8094C16.4781 28.0459 13.7783 30.7705 13.7754 34.1324V54.4501C13.7783 57.812 16.4781 60.5366 19.8094 60.5395H44.8229L56.2573 66.9607L53.6672 60.5395H72.599C74.2009 60.5402 75.7374 59.8983 76.8702 58.7552C78.0029 57.612 78.639 56.0614 78.6383 54.4447V34.1324C78.6376 32.5157 78.0002 30.9657 76.8664 29.8235C75.7327 28.6814 74.1956 28.0408 72.5937 28.043ZM19.1057 32.4208C18.4658 32.4324 17.8646 32.7359 17.467 33.2482C17.0888 33.7635 16.9404 34.4175 17.058 35.0502C18.5962 45.0986 20.0338 51.8757 21.371 55.3816C21.8779 56.658 22.4896 57.2703 23.2063 57.2185C24.3075 57.1489 25.6263 55.5968 27.1627 52.5621C27.9964 50.8412 29.2602 48.2662 30.9539 44.837C32.3785 49.88 34.309 53.6787 36.7456 56.2331C37.4291 56.9436 38.1204 57.2748 38.8195 57.2266C39.4185 57.1931 39.953 56.8315 40.217 56.2813C40.4753 55.7358 40.5806 55.1278 40.5211 54.5248C40.3516 52.0703 40.5919 48.667 41.2421 44.3149C41.9081 39.8057 42.7523 36.5818 43.7749 34.6432C43.9822 34.2526 44.0733 33.8087 44.037 33.366C44.0039 32.7587 43.7116 32.1969 43.2374 31.829C42.7745 31.4367 42.1799 31.2446 41.5803 31.2935C40.8334 31.3325 40.1682 31.7885 39.8499 32.4797C38.2331 35.5019 37.0812 40.4109 36.3943 47.2068C35.2823 44.2394 34.4509 41.1703 33.9114 38.0412C33.623 36.4613 32.9037 35.7125 31.7536 35.7946C30.9592 35.8589 30.3063 36.3944 29.7819 37.4012L24.0348 48.5643C23.0997 44.6692 22.2205 39.9289 21.3972 34.3433C21.1997 32.9652 20.4358 32.3244 19.1057 32.4208ZM69.9089 34.6877C71.6969 35.0381 73.2407 36.2 74.1186 37.8559C74.9693 39.3247 75.3946 41.1161 75.3946 43.23C75.4148 45.9567 74.7062 48.6357 73.3477 50.9687C71.7778 53.7023 69.7195 55.0691 67.1727 55.0691C66.6933 55.0668 66.2153 55.0128 65.7467 54.9078C63.9584 54.5581 62.4143 53.396 61.5371 51.7396C60.6864 50.2452 60.261 48.4411 60.261 46.3272C60.2357 43.6127 60.945 40.9454 62.3079 38.6295C63.9023 35.8959 65.9607 34.5291 68.4829 34.5291C68.9623 34.5304 69.4402 34.5836 69.9089 34.6877ZM68.7937 49.4848C69.7707 48.5773 70.4399 47.2269 70.8012 45.4337V45.4419C70.9315 44.7826 70.9959 44.1112 70.9933 43.4382C70.986 42.5849 70.8291 41.74 70.5302 40.9452C70.1443 39.901 69.6304 39.3124 68.9884 39.1793C68.0378 38.9643 67.1239 39.5256 66.2469 40.8632C65.5812 41.8393 65.109 42.9432 64.8577 44.1106C64.7276 44.7708 64.6632 45.4432 64.6657 46.1171C64.6739 46.9677 64.8308 47.8096 65.1287 48.6019C65.5146 49.6388 66.0294 50.2274 66.6731 50.3678C67.3169 50.5081 68.0237 50.2138 68.7937 49.4848ZM57.9079 37.8559C57.0291 36.2008 55.4854 35.0392 53.6976 34.6877C53.2279 34.5837 52.749 34.5306 52.2687 34.5291C49.7443 34.5291 47.6856 35.8959 46.0927 38.6295C44.7295 40.9454 44.0201 43.6127 44.0454 46.3272C44.0454 48.4411 44.4699 50.2452 45.319 51.7396C46.1976 53.3949 47.7414 54.5566 49.5294 54.9078C49.999 55.0126 50.4779 55.0667 50.9582 55.0691C53.5055 55.0691 55.5642 53.7023 57.1343 50.9687C58.4922 48.6355 59.2001 45.9565 59.1789 43.23C59.1789 41.1161 58.7544 39.3247 57.9053 37.8559H57.9079ZM54.5903 45.4337C54.2307 47.2269 53.5614 48.5773 52.5825 49.4848C51.8115 50.2065 51.101 50.5017 50.4589 50.3678C49.8169 50.2338 49.3011 49.6461 48.9169 48.6019C48.6181 47.8097 48.4603 46.9678 48.4511 46.1171C48.4495 45.4431 48.5148 44.7707 48.6459 44.1106C48.8971 42.9432 49.3694 41.8393 50.0353 40.8632C50.9124 39.5256 51.8264 38.9643 52.7773 39.1793C53.4193 39.3124 53.9333 39.901 54.3193 40.9452C54.617 41.7404 54.7739 42.585 54.7824 43.4382C54.785 44.1112 54.7207 44.7826 54.5903 45.4419V45.4337Z",fill:"white"}));n(289);const De=({onInstall:e,onDismiss:t})=>{Object(i.useEffect)(()=>{const e=document.getElementsByClassName("woocommerce-layout")[0];return"android"===Ve()&&e&&e.classList.add("woocommerce-layout__show-app-banner"),()=>{e&&e.classList.remove("woocommerce-layout__show-app-banner")}},[]);const[n,r]=Object(i.useState)(!1);return"android"!==Ve()||n?null:Object(i.createElement)("div",{className:"woocommerce-mobile-app-banner"},Object(i.createElement)(ae.a,{icon:Object(i.createElement)(Le.a,{"data-testid":"dismiss-btn"}),onClick:()=>{t(),r(!0),Object(F.recordEvent)("wcadmin_mobile_android_banner_click",{action:"dismiss"})}}),Object(i.createElement)(Ie,null),Object(i.createElement)("div",{className:"woocommerce-mobile-app-banner__description"},Object(i.createElement)("p",{className:"woocommerce-mobile-app-banner__description__text"},Object(U.__)("Run your store from anywhere","woocommerce-admin")),Object(i.createElement)("p",{className:"woocommerce-mobile-app-banner__description__text"},Object(U.__)("Download the WooCommerce app","woocommerce-admin"))),Object(i.createElement)(a.Button,{href:"https://play.google.com/store/apps/details?id=com.woocommerce.android",isSecondary:!0,onClick:()=>{e(),r(!0),Object(F.recordEvent)("wcadmin_mobile_android_banner_click",{action:"install"})}},Object(U.__)("Install","woocommerce-admin")))};function Fe(){const[e,t]=Object(i.useState)(!1),n=Object(i.useRef)(null);return Object(i.useEffect)(()=>{const e=()=>{t(window.pageYOffset>20)},r=()=>{n.current=window.requestAnimationFrame(e)};return window.addEventListener("scroll",r),()=>{window.removeEventListener("scroll",r),window.cancelAnimationFrame(n.current)}},[]),e}n(290);const He=(e,t,n=null)=>{if(!t)return 0;const r=0===(o=t).indexOf("http")?o:Object(I.e)(o);var o;const{href:i}=e;if(r===i)return Number.MAX_SAFE_INTEGER;const a=(e=>{const t=e.replace(/[-\/\\^$*+?.()|[\]{}]/gi,"\\$&"),[n,r,o]=t.split(/\\\?|#/),i=o?`(.*#${o}$)`:"";return"^"+n+(r?r.split("&").reduce((e,t)=>`${e}(?=.*[?|&]${t}(&|$|#))`,""):"")+i})(r),c=new RegExp(n||a,"i");return(decodeURIComponent(i).match(c)||[]).length},Be=e=>{let t=null,n=0;return e.forEach(e=>{const r=He(window.location,e.url,e.matchExpression);r>0&&r>=n&&(n=r,t=e)}),t||null},Ue=["primary","favorites","plugins","secondary"],ze={woocommerce:{id:"woocommerce",isCategory:!0,menuId:"primary",migrate:!0,order:10,parent:"",title:"WooCommerce"}};var qe=Object(i.createElement)(le.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"-2 -2 24 24"},Object(i.createElement)(le.Path,{d:"M20 10c0-5.51-4.49-10-10-10C4.48 0 0 4.49 0 10c0 5.52 4.48 10 10 10 5.51 0 10-4.48 10-10zM7.78 15.37L4.37 6.22c.55-.02 1.17-.08 1.17-.08.5-.06.44-1.13-.06-1.11 0 0-1.45.11-2.37.11-.18 0-.37 0-.58-.01C4.12 2.69 6.87 1.11 10 1.11c2.33 0 4.45.87 6.05 2.34-.68-.11-1.65.39-1.65 1.58 0 .74.45 1.36.9 2.1.35.61.55 1.36.55 2.46 0 1.49-1.4 5-1.4 5l-3.03-8.37c.54-.02.82-.17.82-.17.5-.05.44-1.25-.06-1.22 0 0-1.44.12-2.38.12-.87 0-2.33-.12-2.33-.12-.5-.03-.56 1.2-.06 1.22l.92.08 1.26 3.41zM17.41 10c.24-.64.74-1.87.43-4.25.7 1.29 1.05 2.71 1.05 4.25 0 3.29-1.73 6.24-4.4 7.78.97-2.59 1.94-5.2 2.92-7.78zM6.1 18.09C3.12 16.65 1.11 13.53 1.11 10c0-1.3.23-2.48.72-3.59C3.25 10.3 4.67 14.2 6.1 18.09zm4.03-6.63l2.58 6.98c-.86.29-1.76.45-2.71.45-.79 0-1.57-.11-2.29-.33.81-2.38 1.62-4.74 2.42-7.1z"}));var $e=()=>{const e=Object(I.f)("siteTitle",""),t=Object(I.f)("homeUrl",""),n=Fe(),[r,o]=Object(i.useState)(document.body.classList.contains(!1)),c="is-wc-nav-folded",l="is-wc-nav-expanded",u=()=>{document.body.classList.add(c),document.body.classList.remove(l),o(!0)},d=()=>{document.body.classList.remove(c),document.body.classList.add(l),o(!1)},m=(e=document.body.clientWidth)=>{e<=960?u():d()};Object(i.useEffect)(()=>{m();const e=[{eventName:"orientationchange",handler:e=>m(e.target.screen.availWidth)},{eventName:"resize",handler:Object(M.debounce)(()=>m(),200)}];for(const{eventName:t,handler:n}of e)window.addEventListener(t,n,!1);Object(V.addHistoryListener)(()=>m())},[]);let p=Object(i.createElement)(ae.a,{size:"36px",icon:qe});const{isRequestingSiteIcon:f,siteIconUrl:h}=Object(s.useSelect)(e=>{const{isResolving:t}=e("core/data"),{getEntityRecord:n}=e("core"),r=n("root","__unstableBase",void 0)||{};return{isRequestingSiteIcon:t("core","getEntityRecord",["root","__unstableBase",void 0]),siteIconUrl:r.siteIconUrl}});h?p=Object(i.createElement)("img",{alt:Object(U.__)("Site Icon"),src:h}):f&&(p=null);const b=re()("woocommerce-navigation-header",{"is-scrolled":n});return Object(i.createElement)("div",{className:b},Object(i.createElement)(a.Button,{onClick:()=>{document.body.classList.contains(c)?d():u()},className:"woocommerce-navigation-header__site-icon","aria-label":"Fold navigation",role:"switch","aria-checked":r?"true":"false"},p),Object(i.createElement)(a.Button,{href:t,className:"woocommerce-navigation-header__site-title",as:"span"},Object(oe.decodeEntities)(e)))},We=(n(291),Object(i.createElement)(le.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"},Object(i.createElement)(le.Path,{d:"M11.776 4.454a.25.25 0 01.448 0l2.069 4.192a.25.25 0 00.188.137l4.626.672a.25.25 0 01.139.426l-3.348 3.263a.25.25 0 00-.072.222l.79 4.607a.25.25 0 01-.362.263l-4.138-2.175a.25.25 0 00-.232 0l-4.138 2.175a.25.25 0 01-.363-.263l.79-4.607a.25.25 0 00-.071-.222L4.754 9.881a.25.25 0 01.139-.426l4.626-.672a.25.25 0 00.188-.137l2.069-4.192z"}))),Ge=Object(i.createElement)(le.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"},Object(i.createElement)(le.Path,{fillRule:"evenodd",d:"M9.706 8.646a.25.25 0 01-.188.137l-4.626.672a.25.25 0 00-.139.427l3.348 3.262a.25.25 0 01.072.222l-.79 4.607a.25.25 0 00.362.264l4.138-2.176a.25.25 0 01.233 0l4.137 2.175a.25.25 0 00.363-.263l-.79-4.607a.25.25 0 01.072-.222l3.347-3.262a.25.25 0 00-.139-.427l-4.626-.672a.25.25 0 01-.188-.137l-2.069-4.192a.25.25 0 00-.448 0L9.706 8.646zM12 7.39l-.948 1.921a1.75 1.75 0 01-1.317.957l-2.12.308 1.534 1.495c.412.402.6.982.503 1.55l-.362 2.11 1.896-.997a1.75 1.75 0 011.629 0l1.895.997-.362-2.11a1.75 1.75 0 01.504-1.55l1.533-1.495-2.12-.308a1.75 1.75 0 01-1.317-.957L12 7.39z",clipRule:"evenodd"}));n(292);const Qe=({id:e})=>{const{favorites:t,isResolving:n}=Object(s.useSelect)(e=>({favorites:e(D.NAVIGATION_STORE_NAME).getFavorites(),isResolving:e(D.NAVIGATION_STORE_NAME).isResolving("getFavorites")})),{addFavorite:r,removeFavorite:o}=Object(s.useDispatch)(D.NAVIGATION_STORE_NAME),c=t.includes(e);return n?null:Object(i.createElement)(a.Button,{id:"woocommerce-navigation-favorite-button",className:"woocommerce-navigation-favorite-button",isTertiary:!0,onClick:()=>{(c?o:r)(e),Object(F.recordEvent)("navigation_favorite",{id:e,action:c?"unfavorite":"favorite"})},"aria-label":c?Object(U.__)("Add this item to your favorites.","woocommerce-admin"):Object(U.__)("Remove this item from your favorites.","woocommerce-admin")},Object(i.createElement)(ae.a,{icon:c?We:Ge,className:`star-${c?"filled":"empty"}-icon`}))};const Ye="woocommerce_navigation_favorites_tooltip_hidden",Ze=()=>{const{isFavoritesResolving:e,isOptionResolving:t,isTooltipHidden:n}=Object(s.useSelect)(e=>{const{getOption:t,isResolving:n}=e(D.OPTIONS_STORE_NAME);return{isFavoritesResolving:e(D.NAVIGATION_STORE_NAME).isResolving("getFavorites"),isOptionResolving:n("getOption",[Ye]),isTooltipHidden:"yes"===t(Ye)}}),{updateOptions:r}=Object(s.useDispatch)(D.OPTIONS_STORE_NAME);return e||n||t||document.body.classList.contains("is-wc-nav-folded")?null:Object(i.createElement)(je,{delay:1e3,title:Object(U.__)("Introducing favorites","woocommerce-admin"),content:Object(U.__)("You can now favorite your extensions to pin them in the top level of the navigation.","woocommerce-admin"),closeButtonText:Object(U.__)("Got it","woocommerce-admin"),id:"woocommerce-navigation-favorite-button",onClose:()=>r({[Ye]:"yes"}),useAnchor:!0})};var Ke=({category:e})=>{const{id:t,menuId:n,title:r}=e,o="woocommerce-navigation-category-title";return["plugins","favorites"].includes(n)?Object(i.createElement)("span",{className:o},Object(i.createElement)("span",{className:o+"__text"},r),Object(i.createElement)(Qe,{id:t}),Object(i.createElement)(Ze,null)):Object(i.createElement)("span",{className:o},r)};var Je=({item:e})=>{var t;const n=Object(ie.useSlot)("woocommerce_navigation_"+e.id),r=Boolean(null==n||null===(t=n.fills)||void 0===t?void 0:t.length),o=e=>{Object(F.recordEvent)("navigation_click",{menu_item:e})};return r&&!e.isCategory?Object(i.createElement)(ie.NavigationItem,{key:e.id,item:e.id},Object(i.createElement)("div",{onClick:()=>o(e.id)},Object(i.createElement)(V.WooNavigationItem.Slot,{name:e.id}))):Object(i.createElement)(ie.NavigationItem,{key:e.id,item:e.id,title:e.title,badge:e.badge?e.badge:null,href:e.url,navigateToMenu:!e.url&&e.id,onClick:()=>o(e.id),hideIfTargetMenuEmpty:!0})};const Xe=({category:e,onBackClick:t,pluginItems:n,primaryItems:r})=>{if(!r.length&&!n.length)return null;const o=Object(B.applyFilters)("woocommerce_navigation_root_back_label",Object(U.__)("WordPress Dashboard","woocommerce-admin")),a=Object(B.applyFilters)("woocommerce_navigation_root_back_url",window.wcNavigation.rootBackUrl),c="woocommerce"===e.id&&a;return Object(i.createElement)(ie.NavigationMenu,{title:Object(i.createElement)(Ke,{category:e}),menu:e.id,parentMenu:e.parent,backButtonLabel:c?o:e.backButtonLabel||null,onBackButtonClick:c?()=>{t("woocommerce"),window.location=a}:()=>t(e.id)},!!r.length&&Object(i.createElement)(ie.NavigationGroup,null,r.map(e=>Object(i.createElement)(Je,{key:e.id,item:e}))),!!n.length&&Object(i.createElement)(ie.NavigationGroup,{title:"woocommerce"===e.id?Object(U.__)("Extensions","woocommerce-admin"):null},n.map(e=>Object(i.createElement)(Je,{key:e.id,item:e}))))},et=({category:e,items:t,onBackClick:n})=>{if(!t.length)return null;const r="woocommerce"===e.id;return Object(i.createElement)(ie.NavigationMenu,{className:"components-navigation__menu-secondary",title:!r&&Object(i.createElement)(Ke,{category:e}),menu:e.id,parentMenu:e.parent,backButtonLabel:e.backButtonLabel||null,onBackButtonClick:r?null:()=>n(e.id)},Object(i.createElement)(ie.NavigationGroup,{onBackButtonClick:()=>n(e.id)},t.map(e=>Object(i.createElement)(Je,{key:e.id,item:e}))))};var tt=()=>{const{menuItems:e}=Object(s.useSelect)(e=>({menuItems:e(D.NAVIGATION_STORE_NAME).getMenuItems()}));Object(i.useEffect)(()=>{document.documentElement.classList.remove("wp-toolbar"),document.body.classList.add("has-woocommerce-navigation");const e=document.getElementById("adminmenumain");e&&e.classList.add("folded")},[]);const[t,n]=Object(i.useState)("woocommerce-home"),[r,o]=Object(i.useState)("woocommerce");Object(i.useEffect)(()=>{const r=Be(e);r&&t!==r&&(n(r),o(r.parent));return Object(V.addHistoryListener)(()=>{setTimeout(()=>{const t=Be(e);t&&(n(t),o(t.parent))},0)})},[e]);const{currentUserCan:a}=Object(D.useUser)(),{categories:c,items:l}=Object(i.useMemo)(()=>((e,t)=>{const n={...ze};return{items:(e=>e.sort((e,t)=>e.order===t.order?e.title.localeCompare(t.title):e.order-t.order))(e).reduce((e,r)=>{if(e[r.parent]||(e[r.parent]={},Ue.forEach(t=>{e[r.parent][t]=[]})),!e[r.parent][r.menuId])return e;if(t&&r.capability&&!t(r.capability))return e;r.isCategory&&(n[r.id]=r);const o=e[r.parent][r.menuId];return o&&o.push(r),e},{}),categories:n}})(e,a),[e,a]),u=Object(i.useRef)(null),d=e=>{Object(F.recordEvent)("navigation_back_click",{category:e})},m="woocommerce"===r,p=re()("woocommerce-navigation",{"is-root":m});return Object(i.createElement)("div",{className:p},Object(i.createElement)($e,null),Object(i.createElement)("div",{className:"woocommerce-navigation__wrapper",ref:u},Object(i.createElement)(ie.Navigation,{activeItem:t?t.id:null,activeMenu:r,onActivateMenu:(...e)=>{u&&u.current&&(u.current.scrollTop=0),o(...e)}},Object.values(c).map(e=>{const t=l[e.id];return!!t&&[Object(i.createElement)(Xe,{key:e.id,category:e,onBackClick:d,primaryItems:[...t.primary,...t.favorites],pluginItems:t.plugins}),Object(i.createElement)(et,{key:"secondary/"+e.id,category:e,onBackClick:d,items:t.secondary})]}))))};var nt=Object(D.withNavigationHydration)(window.wcNavigation)(tt);const rt=()=>{if(new URL(window.location.href).searchParams.get("task")){const e=Object(U.__)("WooCommerce Home","woocommerce-admin"),t=()=>{Object(F.recordEvent)("topbar_back_button",{page_name:ot(window.title)}),Object(V.updateQueryString)({},Object(V.getHistory)().location.pathname,{})};return Object(i.createElement)(a.Tooltip,{text:e},Object(i.createElement)("div",{tabIndex:"0",role:"button","data-testid":"header-back-button",className:"woocommerce-layout__header-back-button",onKeyDown:({keyCode:e})=>{e!==se.ENTER&&e!==se.SPACE||t()}},Object(i.createElement)(ae.a,{icon:ce.a,onClick:t})))}return null},ot=e=>{const t=new URL(window.location.href).searchParams.get("task");return{payments:Object(U.__)("Set up payments","woocommerce-admin"),tax:Object(U.__)("Add tax rates","woocommerce-admin"),appearance:Object(U.__)("Personalize your store","woocommerce-admin"),marketing:Object(U.__)("Set up marketing tools","woocommerce-admin"),products:Object(U.__)("Add products","woocommerce-admin"),shipping:Object(U.__)("Set up shipping costs","woocommerce-admin")}[t]||e},it=({sections:e,isEmbedded:t=!1,query:n})=>{const r=Object(i.useRef)(null),o=Object(I.f)("siteTitle",""),a=e.slice(-1)[0],c=Fe(),{updateUserPreferences:s,...l}=Object(D.useUserPreferences)(),u="yes"===l.android_app_banner_dismissed;let d=null;const m=re()("woocommerce-layout__header",{"is-scrolled":c});Object(i.useLayoutEffect)(()=>(p(),window.addEventListener("resize",p),()=>{window.removeEventListener("resize",p);const e=document.querySelector("#wpbody");e&&(e.style.marginTop=null)}),[u]);const p=()=>{clearTimeout(d),d=setTimeout((function(){const e=document.querySelector("#wpbody");e&&r.current&&(e.style.marginTop=r.current.offsetHeight+"px")}),200)};Object(i.useEffect)(()=>{if(!t){const t=e.map(e=>Array.isArray(e)?e[1]:e).reverse().join(" ‹ "),n=Object(oe.decodeEntities)(Object(U.sprintf)(Object(U.__)("%1$s ‹ %2$s — WooCommerce","woocommerce-admin"),t,o));document.title!==n&&(document.title=n)}},[t,e,o]);const f=()=>{s({android_app_banner_dismissed:"yes"})},h=rt()?"with-back-button":"";return Object(i.createElement)("div",{className:m,ref:r},!u&&Object(i.createElement)(De,{onDismiss:f,onInstall:f}),Object(i.createElement)("div",{className:"woocommerce-layout__header-wrapper"},window.wcAdminFeatures.navigation&&Object(i.createElement)(nt,null),rt(),Object(i.createElement)(ie.Text,{className:"woocommerce-layout__header-heading "+h,as:"h1"},ot(Object(oe.decodeEntities)(a))),window.wcAdminFeatures["activity-panels"]&&Object(i.createElement)(Re,{isEmbedded:t,query:n,userPreferencesData:{...l,updateUserPreferences:s}})))};class at extends i.Component{render(){return Object(i.createElement)("div",{id:"woocommerce-layout__notice-list",className:"woocommerce-layout__notice-list"})}}var ct=at,st=n(159),lt=n(257);var ut=function({notices:e,className:t,children:n,onRemove:r=M.noop,onRemove2:a=M.noop}){const s=Object(c.useReducedMotion)(),[l]=Object(i.useState)(()=>new WeakMap),u=Object(st.useTransition)(e,e=>e.id,{from:{opacity:0,height:0},enter:e=>async t=>await t({opacity:1,height:l.get(e).offsetHeight}),leave:()=>async e=>{await e({opacity:0}),await e({height:0})},immediate:s});t=re()("components-snackbar-list",t);const d=e=>()=>{r(e.id),a(e.id)};return Object(i.createElement)("div",{className:t},n,u.map(({item:e,key:t,props:n})=>Object(i.createElement)(st.animated.div,{key:t,style:n},Object(i.createElement)("div",{className:"components-snackbar-list__notice-container",ref:t=>t&&l.set(e,t)},Object(i.createElement)(lt.a,o()({},Object(M.omit)(e,["content"]),{onRemove:d(e)}),e.content)))))};n(298);const dt="woocommerce_admin_transient_notices_queue";function mt(e){const{removeNotice:t}=Object(s.useDispatch)("core/notices"),{createNotice:n,removeNotice:r}=Object(s.useDispatch)("core/notices2"),{updateOptions:o}=Object(s.useDispatch)(D.OPTIONS_STORE_NAME),{currentUser:a={},notices:c=[],notices2:l=[],noticesQueue:u={}}=Object(s.useSelect)(e=>({currentUser:e(D.USER_STORE_NAME).getCurrentUser(),notices:e("core/notices").getNotices(),notices2:e("core/notices2").getNotices(),noticesQueue:e(D.OPTIONS_STORE_NAME).getOption(dt)}));Object(i.useEffect)(()=>{Object.values(u).filter(e=>e.user_id===a.id||!e.user_id).forEach(e=>{const t=Object(B.applyFilters)("woocommerce_admin_queued_notice_filter",e);n(t.status,t.content,{onDismiss:()=>{(e=>{const t={...u};delete t[e],o({[dt]:t})})(t.id)},...t.options||{}})})},[]);const{className:d}=e,m=re()("woocommerce-transient-notices","components-notices__snackbar",d),p=c.concat(l);return Object(i.createElement)(ut,{notices:p,className:m,onRemove:t,onRemove2:r})}mt.propTypes={className:p.a.string,notices:p.a.array};var pt=mt;Object(H.registerPlugin)("wc-admin-navigation",{render:()=>{const{persistedQuery:e}=Object(s.useSelect)(e=>({persistedQuery:e(D.NAVIGATION_STORE_NAME).getPersistedQuery()}));if(!Object($.f)(window.location.href))return null;const t=Object(q.a)().filter(e=>e.navArgs),n=ee().filter(e=>e.navArgs).map(e=>"/analytics/settings"===e.path?{...e,breadcrumbs:[Object(U.__)("Analytics","woocommerce-admin")]}:e);return Object(i.createElement)(i.Fragment,null,n.map(t=>Object(i.createElement)(V.WooNavigationItem,{item:t.navArgs.id,key:t.navArgs.id},Object(i.createElement)(z.Link,{className:"components-button",href:Object(V.getNewPath)(Object(V.pathIsExcluded)(t.path)?{}:e,t.path,{}),type:"wc-admin"},t.breadcrumbs[t.breadcrumbs.length-1]))),t.map(t=>Object(i.createElement)(V.WooNavigationItem,{item:t.navArgs.id,key:t.navArgs.id},Object(i.createElement)(z.Link,{className:"components-button",href:Object(V.getNewPath)(Object(V.pathIsExcluded)(t.report)?{}:e,"/analytics/"+t.report,{}),type:"wc-admin"},t.title))))},scope:"woocommerce-navigation"});const ft=Object(i.lazy)(()=>Promise.all([n.e(1),n.e(48)]).then(n.bind(null,632))),ht=Object(i.lazy)(()=>n.e(53).then(n.bind(null,524)));class bt extends i.Component{render(){const{children:e}=this.props;return Object(i.createElement)("div",{className:"woocommerce-layout__primary",id:"woocommerce-layout__primary"},window.wcAdminFeatures["store-alerts"]&&Object(i.createElement)(i.Suspense,{fallback:null},Object(i.createElement)(ft,null)),Object(i.createElement)(ct,null),e)}}class vt extends i.Component{componentDidMount(){this.recordPageViewTrack()}componentDidUpdate(e){const t=Object(M.get)(e,"location.pathname"),n=Object(M.get)(this.props,"location.pathname");t&&n&&t!==n&&this.recordPageViewTrack()}recordPageViewTrack(){const{activePlugins:e,installedPlugins:t,isEmbedded:n,isJetpackConnected:r}=this.props,o={has_navigation:!!window.wcNavigation};if(n){const e=document.location.pathname+document.location.search;return void Object(F.recordPageView)(e,{is_embedded:!0,...o})}const i=Object(M.get)(this.props,"location.pathname");if(!i)return;let a=i.substring(1).replace(/\//g,"_");0===a.length&&(a="home_screen"),Object(F.recordPageView)(a,{jetpack_installed:t.includes("jetpack"),jetpack_active:e.includes("jetpack"),jetpack_connected:r,...o})}getQuery(e){if(!e)return{};const t=e.substring(1);return Object(L.parse)(t)}isWCPaySettingsPage(){const{page:e,section:t,tab:n}=Object(V.getQuery)();return"wc-settings"===e&&"checkout"===n&&"woocommerce_payments"===t}render(){const{isEmbedded:e,...t}=this.props,{location:n,page:r}=this.props,{breadcrumbs:c}=r,s=this.getQuery(n&&n.search);return Object(i.createElement)(a.SlotFillProvider,null,Object(i.createElement)("div",{className:"woocommerce-layout"},Object(i.createElement)(it,{sections:Object(M.isFunction)(c)?c(this.props):c,isEmbedded:e,query:s}),Object(i.createElement)(pt,null),!e&&Object(i.createElement)(bt,null,Object(i.createElement)("div",{className:"woocommerce-layout__main"},Object(i.createElement)(te,o()({},t,{query:s})))),e&&this.isWCPaySettingsPage()&&Object(i.createElement)(i.Suspense,{fallback:null},Object(i.createElement)(ht,null))),Object(i.createElement)(H.PluginArea,{scope:"woocommerce-admin"}),window.wcAdminFeatures.navigation&&Object(i.createElement)(H.PluginArea,{scope:"woocommerce-navigation"}),Object(i.createElement)(H.PluginArea,{scope:"woocommerce-tasks"}))}}vt.propTypes={isEmbedded:p.a.bool,page:p.a.shape({container:p.a.oneOfType([p.a.func,p.a.object]),path:p.a.string,breadcrumbs:p.a.oneOfType([p.a.func,p.a.arrayOf(p.a.oneOfType([p.a.arrayOf(p.a.string),p.a.string]))]).isRequired,wpOpenMenu:p.a.string}).isRequired};const gt=Object(I.f)("dataEndpoints"),yt=Object(c.compose)(Object(D.withPluginsHydration)({...Object(I.f)("plugins",{}),jetpackStatus:gt&>.jetpackStatus||!1}),Object(s.withSelect)((e,{isEmbedded:t})=>{if(t)return;const{getActivePlugins:n,getInstalledPlugins:r,isJetpackConnected:o}=e(D.PLUGINS_STORE_NAME);return{activePlugins:n(),isJetpackConnected:o(),installedPlugins:r()}}))(vt),wt=Object(c.compose)(window.wcSettings.admin?Object(D.withOptionsHydration)({...Object(I.f)("preloadOptions",{})}):M.identity)(()=>{const{currentUserCan:e}=Object(D.useUser)();return Object(i.createElement)(_,{history:Object(V.getHistory)()},Object(i.createElement)(R,null,ee().filter(t=>!t.capability||e(t.capability)).map(e=>Object(i.createElement)(C,{key:e.path,path:e.path,exact:!0,render:t=>Object(i.createElement)(yt,o()({page:e},t))}))))}),Ot=Object(c.compose)(Object(I.f)("preloadOptions")?Object(D.withOptionsHydration)({...Object(I.f)("preloadOptions")}):M.identity)(()=>Object(i.createElement)(yt,{page:{breadcrumbs:Object(I.f)("embedBreadcrumbs",[])},isEmbedded:!0}))},12:function(e,t){e.exports=window.wc.navigation},120:function(e,t){e.exports=window.wc.number},121:function(e,t){e.exports=window.wc.explat},127:function(e,t){e.exports=window.wp.notices},128:function(e,t){var n,r,o=e.exports={};function i(){throw new Error("setTimeout has not been defined")}function a(){throw new Error("clearTimeout has not been defined")}function c(e){if(n===setTimeout)return setTimeout(e,0);if((n===i||!n)&&setTimeout)return n=setTimeout,setTimeout(e,0);try{return n(e,0)}catch(t){try{return n.call(null,e,0)}catch(t){return n.call(this,e,0)}}}!function(){try{n="function"==typeof setTimeout?setTimeout:i}catch(e){n=i}try{r="function"==typeof clearTimeout?clearTimeout:a}catch(e){r=a}}();var s,l=[],u=!1,d=-1;function m(){u&&s&&(u=!1,s.length?l=s.concat(l):d=-1,l.length&&p())}function p(){if(!u){var e=c(m);u=!0;for(var t=l.length;t;){for(s=l,l=[];++d<t;)s&&s[d].run();d=-1,t=l.length}s=null,u=!1,function(e){if(r===clearTimeout)return clearTimeout(e);if((r===a||!r)&&clearTimeout)return r=clearTimeout,clearTimeout(e);try{r(e)}catch(t){try{return r.call(null,e)}catch(t){return r.call(this,e)}}}(e)}}function f(e,t){this.fun=e,this.array=t}function h(){}o.nextTick=function(e){var t=new Array(arguments.length-1);if(arguments.length>1)for(var n=1;n<arguments.length;n++)t[n-1]=arguments[n];l.push(new f(e,t)),1!==l.length||u||c(p)},f.prototype.run=function(){this.fun.apply(null,this.array)},o.title="browser",o.browser=!0,o.env={},o.argv=[],o.version="",o.versions={},o.on=h,o.addListener=h,o.once=h,o.off=h,o.removeListener=h,o.removeAllListeners=h,o.emit=h,o.prependListener=h,o.prependOnceListener=h,o.listeners=function(e){return[]},o.binding=function(e){throw new Error("process.binding is not supported")},o.cwd=function(){return"/"},o.chdir=function(e){throw new Error("process.chdir is not supported")},o.umask=function(){return 0}},129:function(e,t,n){"use strict";var r="function"==typeof Symbol&&Symbol.for,o=r?Symbol.for("react.element"):60103,i=r?Symbol.for("react.portal"):60106,a=r?Symbol.for("react.fragment"):60107,c=r?Symbol.for("react.strict_mode"):60108,s=r?Symbol.for("react.profiler"):60114,l=r?Symbol.for("react.provider"):60109,u=r?Symbol.for("react.context"):60110,d=r?Symbol.for("react.async_mode"):60111,m=r?Symbol.for("react.concurrent_mode"):60111,p=r?Symbol.for("react.forward_ref"):60112,f=r?Symbol.for("react.suspense"):60113,h=r?Symbol.for("react.suspense_list"):60120,b=r?Symbol.for("react.memo"):60115,v=r?Symbol.for("react.lazy"):60116,g=r?Symbol.for("react.block"):60121,y=r?Symbol.for("react.fundamental"):60117,w=r?Symbol.for("react.responder"):60118,O=r?Symbol.for("react.scope"):60119;function j(e){if("object"==typeof e&&null!==e){var t=e.$$typeof;switch(t){case o:switch(e=e.type){case d:case m:case a:case s:case c:case f:return e;default:switch(e=e&&e.$$typeof){case u:case p:case v:case b:case l:return e;default:return t}}case i:return t}}}function _(e){return j(e)===m}t.AsyncMode=d,t.ConcurrentMode=m,t.ContextConsumer=u,t.ContextProvider=l,t.Element=o,t.ForwardRef=p,t.Fragment=a,t.Lazy=v,t.Memo=b,t.Portal=i,t.Profiler=s,t.StrictMode=c,t.Suspense=f,t.isAsyncMode=function(e){return _(e)||j(e)===d},t.isConcurrentMode=_,t.isContextConsumer=function(e){return j(e)===u},t.isContextProvider=function(e){return j(e)===l},t.isElement=function(e){return"object"==typeof e&&null!==e&&e.$$typeof===o},t.isForwardRef=function(e){return j(e)===p},t.isFragment=function(e){return j(e)===a},t.isLazy=function(e){return j(e)===v},t.isMemo=function(e){return j(e)===b},t.isPortal=function(e){return j(e)===i},t.isProfiler=function(e){return j(e)===s},t.isStrictMode=function(e){return j(e)===c},t.isSuspense=function(e){return j(e)===f},t.isValidElementType=function(e){return"string"==typeof e||"function"==typeof e||e===a||e===m||e===s||e===c||e===f||e===h||"object"==typeof e&&null!==e&&(e.$$typeof===v||e.$$typeof===b||e.$$typeof===l||e.$$typeof===u||e.$$typeof===p||e.$$typeof===y||e.$$typeof===w||e.$$typeof===O||e.$$typeof===g)},t.typeOf=j},13:function(e,t,n){"use strict";n.d(t,"a",(function(){return s})),n.d(t,"b",(function(){return l})),n.d(t,"c",(function(){return u})),n.d(t,"f",(function(){return d})),n.d(t,"g",(function(){return m})),n.d(t,"e",(function(){return p})),n.d(t,"d",(function(){return f}));var r=n(2);const o=["wcAdminSettings","preloadSettings"],i="object"==typeof wcSettings?wcSettings:{},a=Object.keys(i).reduce((e,t)=>(o.includes(t)||(e[t]=i[t]),e),{});Object.keys(i.admin||{}).forEach(e=>{o.includes(e)||(a[e]=i.admin[e])});const c=a.adminUrl,s=(a.countries,a.currency),l=a.locale,u=a.orderStatuses;a.siteTitle,a.wcAssetUrl;function d(e,t=!1,n=(e=>e)){if(o.includes(e))throw new Error(Object(r.__)("Mutable settings should be accessed via data store."));return n(a.hasOwnProperty(e)?a[e]:t,t)}function m(e,t,n=(e=>e)){if(o.includes(e))throw new Error(Object(r.__)("Mutable settings should be mutated via data store."));a[e]=n(t)}function p(e){return(c||"")+e}function f(e){return new Promise((t,n)=>{document.querySelector(`#${e.handle}-js`)&&t();const r=document.createElement("script");r.src=e.src,r.id=e.handle+"-js",r.async=!0,r.onload=t,r.onerror=n,document.body.appendChild(r)})}},14:function(e,t){e.exports=window.wp.compose},15:function(e,t){e.exports=window.wc.tracks},159:function(e,t,n){"use strict";function r(e){return e&&"object"==typeof e&&"default"in e?e.default:e}Object.defineProperty(t,"__esModule",{value:!0});var o=r(n(36)),i=r(n(294)),a=n(5),c=r(a),s=r(n(295)),l=r(n(297)),u={arr:Array.isArray,obj:function(e){return"[object Object]"===Object.prototype.toString.call(e)},fun:function(e){return"function"==typeof e},str:function(e){return"string"==typeof e},num:function(e){return"number"==typeof e},und:function(e){return void 0===e},nul:function(e){return null===e},set:function(e){return e instanceof Set},map:function(e){return e instanceof Map},equ:function(e,t){if(typeof e!=typeof t)return!1;if(u.str(e)||u.num(e))return e===t;if(u.obj(e)&&u.obj(t)&&Object.keys(e).length+Object.keys(t).length===0)return!0;var n;for(n in e)if(!(n in t))return!1;for(n in t)if(e[n]!==t[n])return!1;return!u.und(n)||e===t}};function d(){var e=a.useState(!1)[1];return a.useCallback((function(){return e((function(e){return!e}))}),[])}function m(e,t){return u.und(e)||u.nul(e)?t:e}function p(e){return u.und(e)?[]:u.arr(e)?e:[e]}function f(e){for(var t=arguments.length,n=new Array(t>1?t-1:0),r=1;r<t;r++)n[r-1]=arguments[r];return u.fun(e)?e.apply(void 0,n):e}function h(e){var t=function(e){return e.to,e.from,e.config,e.onStart,e.onRest,e.onFrame,e.children,e.reset,e.reverse,e.force,e.immediate,e.delay,e.attach,e.destroyed,e.interpolateTo,e.ref,e.lazy,i(e,["to","from","config","onStart","onRest","onFrame","children","reset","reverse","force","immediate","delay","attach","destroyed","interpolateTo","ref","lazy"])}(e);if(u.und(t))return o({to:t},e);var n=Object.keys(e).reduce((function(n,r){var i;return u.und(t[r])?o({},n,((i={})[r]=e[r],i)):n}),{});return o({to:t},n)}var b,v,g=function(){function e(){this.payload=void 0,this.children=[]}var t=e.prototype;return t.getAnimatedValue=function(){return this.getValue()},t.getPayload=function(){return this.payload||this},t.attach=function(){},t.detach=function(){},t.getChildren=function(){return this.children},t.addChild=function(e){0===this.children.length&&this.attach(),this.children.push(e)},t.removeChild=function(e){var t=this.children.indexOf(e);this.children.splice(t,1),0===this.children.length&&this.detach()},e}(),y=function(e){function t(){for(var t,n=arguments.length,r=new Array(n),o=0;o<n;o++)r[o]=arguments[o];return(t=e.call.apply(e,[this].concat(r))||this).payload=[],t.attach=function(){return t.payload.forEach((function(e){return e instanceof g&&e.addChild(l(t))}))},t.detach=function(){return t.payload.forEach((function(e){return e instanceof g&&e.removeChild(l(t))}))},t}return s(t,e),t}(g),w=function(e){function t(){for(var t,n=arguments.length,r=new Array(n),o=0;o<n;o++)r[o]=arguments[o];return(t=e.call.apply(e,[this].concat(r))||this).payload={},t.attach=function(){return Object.values(t.payload).forEach((function(e){return e instanceof g&&e.addChild(l(t))}))},t.detach=function(){return Object.values(t.payload).forEach((function(e){return e instanceof g&&e.removeChild(l(t))}))},t}s(t,e);var n=t.prototype;return n.getValue=function(e){void 0===e&&(e=!1);var t={};for(var n in this.payload){var r=this.payload[n];(!e||r instanceof g)&&(t[n]=r instanceof g?r[e?"getAnimatedValue":"getValue"]():r)}return t},n.getAnimatedValue=function(){return this.getValue(!0)},t}(g);function O(e,t){b={fn:e,transform:t}}function j(e){v=e}var _,E=function(e){return"undefined"!=typeof window?window.requestAnimationFrame(e):-1},k=function(e){"undefined"!=typeof window&&window.cancelAnimationFrame(e)};function x(e){_=e}var C,S=function(){return Date.now()};function T(e){C=e}var A,P,N=function(e){return e.current};function R(e){A=e}var M=Object.freeze({get applyAnimatedValues(){return b},injectApplyAnimatedValues:O,get colorNames(){return v},injectColorNames:j,get requestFrame(){return E},get cancelFrame(){return k},injectFrame:function(e,t){E=e,k=t},get interpolation(){return _},injectStringInterpolator:x,get now(){return S},injectNow:function(e){S=e},get defaultElement(){return C},injectDefaultElement:T,get animatedApi(){return N},injectAnimatedApi:function(e){N=e},get createAnimatedStyle(){return A},injectCreateAnimatedStyle:R,get manualFrameloop(){return P},injectManualFrameloop:function(e){P=e}}),L=function(e){function t(t,n){var r;return(r=e.call(this)||this).update=void 0,r.payload=t.style?o({},t,{style:A(t.style)}):t,r.update=n,r.attach(),r}return s(t,e),t}(w),V=!1,I=new Set,D=function e(){if(!V)return!1;var t=S(),n=I,r=Array.isArray(n),o=0;for(n=r?n:n[Symbol.iterator]();;){var i;if(r){if(o>=n.length)break;i=n[o++]}else{if((o=n.next()).done)break;i=o.value}for(var a=i,c=!1,s=0;s<a.configs.length;s++){for(var l=a.configs[s],u=void 0,d=void 0,m=0;m<l.animatedValues.length;m++){var p=l.animatedValues[m];if(!p.done){var f=l.fromValues[m],h=l.toValues[m],b=p.lastPosition,v=h instanceof g,y=Array.isArray(l.initialVelocity)?l.initialVelocity[m]:l.initialVelocity;if(v&&(h=h.getValue()),l.immediate)p.setValue(h),p.done=!0;else if("string"!=typeof f&&"string"!=typeof h){if(void 0!==l.duration)b=f+l.easing((t-p.startTime)/l.duration)*(h-f),u=t>=p.startTime+l.duration;else if(l.decay)b=f+y/(1-.998)*(1-Math.exp(-(1-.998)*(t-p.startTime))),(u=Math.abs(p.lastPosition-b)<.1)&&(h=b);else{d=void 0!==p.lastTime?p.lastTime:t,y=void 0!==p.lastVelocity?p.lastVelocity:l.initialVelocity,t>d+64&&(d=t);for(var w=Math.floor(t-d),O=0;O<w;++O){b+=1*(y+=1*((-l.tension*(b-h)+-l.friction*y)/l.mass)/1e3)/1e3}var j=!(!l.clamp||0===l.tension)&&(f<h?b>h:b<h),_=Math.abs(y)<=l.precision,k=0===l.tension||Math.abs(h-b)<=l.precision;u=j||_&&k,p.lastVelocity=y,p.lastTime=t}v&&!l.toValues[m].done&&(u=!1),u?(p.value!==h&&(b=h),p.done=!0):c=!0,p.setValue(b),p.lastPosition=b}else p.setValue(h),p.done=!0}}a.props.onFrame&&(a.values[l.name]=l.interpolation.getValue())}a.props.onFrame&&a.props.onFrame(a.values),c||(I.delete(a),a.stop(!0))}return I.size?P?P():E(e):V=!1,V};function F(e,t,n){if("function"==typeof e)return e;if(Array.isArray(e))return F({range:e,output:t,extrapolate:n});if(_&&"string"==typeof e.output[0])return _(e);var r=e,o=r.output,i=r.range||[0,1],a=r.extrapolateLeft||r.extrapolate||"extend",c=r.extrapolateRight||r.extrapolate||"extend",s=r.easing||function(e){return e};return function(e){var t=function(e,t){for(var n=1;n<t.length-1&&!(t[n]>=e);++n);return n-1}(e,i);return function(e,t,n,r,o,i,a,c,s){var l=s?s(e):e;if(l<t){if("identity"===a)return l;"clamp"===a&&(l=t)}if(l>n){if("identity"===c)return l;"clamp"===c&&(l=n)}if(r===o)return r;if(t===n)return e<=t?r:o;t===-1/0?l=-l:n===1/0?l-=t:l=(l-t)/(n-t);l=i(l),r===-1/0?l=-l:o===1/0?l+=r:l=l*(o-r)+r;return l}(e,i[t],i[t+1],o[t],o[t+1],s,a,c,r.map)}}var H=function(e){function t(n,r,o,i){var a;return(a=e.call(this)||this).calc=void 0,a.payload=n instanceof y&&!(n instanceof t)?n.getPayload():Array.isArray(n)?n:[n],a.calc=F(r,o,i),a}s(t,e);var n=t.prototype;return n.getValue=function(){return this.calc.apply(this,this.payload.map((function(e){return e.getValue()})))},n.updateConfig=function(e,t,n){this.calc=F(e,t,n)},n.interpolate=function(e,n,r){return new t(this,e,n,r)},t}(y);var B=function(e){function t(t){var n;return(n=e.call(this)||this).animatedStyles=new Set,n.value=void 0,n.startPosition=void 0,n.lastPosition=void 0,n.lastVelocity=void 0,n.startTime=void 0,n.lastTime=void 0,n.done=!1,n.setValue=function(e,t){void 0===t&&(t=!0),n.value=e,t&&n.flush()},n.value=t,n.startPosition=t,n.lastPosition=t,n}s(t,e);var n=t.prototype;return n.flush=function(){0===this.animatedStyles.size&&function e(t,n){"update"in t?n.add(t):t.getChildren().forEach((function(t){return e(t,n)}))}(this,this.animatedStyles),this.animatedStyles.forEach((function(e){return e.update()}))},n.clearStyles=function(){this.animatedStyles.clear()},n.getValue=function(){return this.value},n.interpolate=function(e,t,n){return new H(this,e,t,n)},t}(g),U=function(e){function t(t){var n;return(n=e.call(this)||this).payload=t.map((function(e){return new B(e)})),n}s(t,e);var n=t.prototype;return n.setValue=function(e,t){var n=this;void 0===t&&(t=!0),Array.isArray(e)?e.length===this.payload.length&&e.forEach((function(e,r){return n.payload[r].setValue(e,t)})):this.payload.forEach((function(n){return n.setValue(e,t)}))},n.getValue=function(){return this.payload.map((function(e){return e.getValue()}))},n.interpolate=function(e,t){return new H(this,e,t)},t}(y),z=0,q=function(){function e(){var e=this;this.id=void 0,this.idle=!0,this.hasChanged=!1,this.guid=0,this.local=0,this.props={},this.merged={},this.animations={},this.interpolations={},this.values={},this.configs=[],this.listeners=[],this.queue=[],this.localQueue=void 0,this.getValues=function(){return e.interpolations},this.id=z++}var t=e.prototype;return t.update=function(e){if(!e)return this;var t=h(e),n=t.delay,r=void 0===n?0:n,a=t.to,c=i(t,["delay","to"]);if(u.arr(a)||u.fun(a))this.queue.push(o({},c,{delay:r,to:a}));else if(a){var s={};Object.entries(a).forEach((function(e){var t,n=e[0],i=e[1],a=o({to:(t={},t[n]=i,t),delay:f(r,n)},c),l=s[a.delay]&&s[a.delay].to;s[a.delay]=o({},s[a.delay],a,{to:o({},l,a.to)})})),this.queue=Object.values(s)}return this.queue=this.queue.sort((function(e,t){return e.delay-t.delay})),this.diff(c),this},t.start=function(e){var t,n=this;if(this.queue.length){this.idle=!1,this.localQueue&&this.localQueue.forEach((function(e){var t=e.from,r=void 0===t?{}:t,i=e.to,a=void 0===i?{}:i;u.obj(r)&&(n.merged=o({},r,n.merged)),u.obj(a)&&(n.merged=o({},n.merged,a))}));var r=this.local=++this.guid,a=this.localQueue=this.queue;this.queue=[],a.forEach((function(t,o){var c=t.delay,s=i(t,["delay"]),l=function(t){o===a.length-1&&r===n.guid&&t&&(n.idle=!0,n.props.onRest&&n.props.onRest(n.merged)),e&&e()},d=u.arr(s.to)||u.fun(s.to);c?setTimeout((function(){r===n.guid&&(d?n.runAsync(s,l):n.diff(s).start(l))}),c):d?n.runAsync(s,l):n.diff(s).start(l)}))}else u.fun(e)&&this.listeners.push(e),this.props.onStart&&this.props.onStart(),t=this,I.has(t)||I.add(t),V||(V=!0,E(P||D));return this},t.stop=function(e){return this.listeners.forEach((function(t){return t(e)})),this.listeners=[],this},t.pause=function(e){var t;return this.stop(!0),e&&(t=this,I.has(t)&&I.delete(t)),this},t.runAsync=function(e,t){var n=this,r=(e.delay,i(e,["delay"])),a=this.local,c=Promise.resolve(void 0);if(u.arr(r.to))for(var s=function(e){var t=e,i=o({},r,h(r.to[t]));u.arr(i.config)&&(i.config=i.config[t]),c=c.then((function(){if(a===n.guid)return new Promise((function(e){return n.diff(i).start(e)}))}))},l=0;l<r.to.length;l++)s(l);else if(u.fun(r.to)){var d,m=0;c=c.then((function(){return r.to((function(e){var t=o({},r,h(e));if(u.arr(t.config)&&(t.config=t.config[m]),m++,a===n.guid)return d=new Promise((function(e){return n.diff(t).start(e)}))}),(function(e){return void 0===e&&(e=!0),n.stop(e)})).then((function(){return d}))}))}c.then(t)},t.diff=function(e){var t=this;this.props=o({},this.props,e);var n=this.props,r=n.from,i=void 0===r?{}:r,a=n.to,c=void 0===a?{}:a,s=n.config,l=void 0===s?{}:s,d=n.reverse,h=n.attach,b=n.reset,g=n.immediate;if(d){var y=[c,i];i=y[0],c=y[1]}this.merged=o({},i,this.merged,c),this.hasChanged=!1;var w=h&&h(this);if(this.animations=Object.entries(this.merged).reduce((function(e,n){var r=n[0],a=n[1],c=e[r]||{},s=u.num(a),d=u.str(a)&&!a.startsWith("#")&&!/\d/.test(a)&&!v[a],h=u.arr(a),y=!s&&!h&&!d,O=u.und(i[r])?a:i[r],j=s||h||d?a:1,E=f(l,r);w&&(j=w.animations[r].parent);var k,x=c.parent,C=c.interpolation,T=p(w?j.getPayload():j),A=a;y&&(A=_({range:[0,1],output:[a,a]})(1));var P,N=C&&C.getValue(),R=!u.und(x)&&c.animatedValues.some((function(e){return!e.done})),M=!u.equ(A,N),L=!u.equ(A,c.previous),V=!u.equ(E,c.config);if(b||L&&M||V){var I;if(s||d)x=C=c.parent||new B(O);else if(h)x=C=c.parent||new U(O);else if(y){var D=c.interpolation&&c.interpolation.calc(c.parent.value);D=void 0===D||b?O:D,c.parent?(x=c.parent).setValue(0,!1):x=new B(0);var F={output:[D,a]};c.interpolation?(C=c.interpolation,c.interpolation.updateConfig(F)):C=x.interpolate(F)}return T=p(w?j.getPayload():j),k=p(x.getPayload()),b&&!y&&x.setValue(O,!1),t.hasChanged=!0,k.forEach((function(e){e.startPosition=e.value,e.lastPosition=e.value,e.lastVelocity=R?e.lastVelocity:void 0,e.lastTime=R?e.lastTime:void 0,e.startTime=S(),e.done=!1,e.animatedStyles.clear()})),f(g,r)&&x.setValue(y?j:a,!1),o({},e,((I={})[r]=o({},c,{name:r,parent:x,interpolation:C,animatedValues:k,toValues:T,previous:A,config:E,fromValues:p(x.getValue()),immediate:f(g,r),initialVelocity:m(E.velocity,0),clamp:m(E.clamp,!1),precision:m(E.precision,.01),tension:m(E.tension,170),friction:m(E.friction,26),mass:m(E.mass,1),duration:E.duration,easing:m(E.easing,(function(e){return e})),decay:E.decay}),I))}return M?e:(y&&(x.setValue(1,!1),C.updateConfig({output:[A,A]})),x.done=!0,t.hasChanged=!0,o({},e,((P={})[r]=o({},e[r],{previous:A}),P)))}),this.animations),this.hasChanged)for(var O in this.configs=Object.values(this.animations),this.values={},this.interpolations={},this.animations)this.interpolations[O]=this.animations[O].interpolation,this.values[O]=this.animations[O].interpolation.getValue();return this},t.destroy=function(){this.stop(),this.props={},this.merged={},this.animations={},this.interpolations={},this.values={},this.configs=[],this.local=0},e}(),$=function(e,t){var n=a.useRef(!1),r=a.useRef(),o=u.fun(t),i=a.useMemo((function(){var n;return r.current&&(r.current.map((function(e){return e.destroy()})),r.current=void 0),[new Array(e).fill().map((function(e,r){var i=new q,a=o?f(t,r,i):t[r];return 0===r&&(n=a.ref),i.update(a),n||i.start(),i})),n]}),[e]),c=i[0],s=i[1];r.current=c;a.useImperativeHandle(s,(function(){return{start:function(){return Promise.all(r.current.map((function(e){return new Promise((function(t){return e.start(t)}))})))},stop:function(e){return r.current.forEach((function(t){return t.stop(e)}))},get controllers(){return r.current}}}));var l=a.useMemo((function(){return function(e){return r.current.map((function(t,n){t.update(o?f(e,n,t):e[n]),s||t.start()}))}}),[e]);a.useEffect((function(){n.current?o||l(t):s||r.current.forEach((function(e){return e.start()}))})),a.useEffect((function(){return n.current=!0,function(){return r.current.forEach((function(e){return e.destroy()}))}}),[]);var d=r.current.map((function(e){return e.getValues()}));return o?[d,l,function(e){return r.current.forEach((function(t){return t.pause(e)}))}]:d},W=0,G=function(e,t){return("function"==typeof t?e.map(t):p(t)).map(String)},Q=function(e){var t=e.items,n=e.keys,r=void 0===n?function(e){return e}:n,a=i(e,["items","keys"]);return t=p(void 0!==t?t:null),o({items:t,keys:G(t,r)},a)};function Y(e,t){var n=function(){if(o){if(i>=r.length)return"break";a=r[i++]}else{if((i=r.next()).done)return"break";a=i.value}var n=a.key,c=function(e){return e.key!==n};(u.und(t)||t===n)&&(e.current.instances.delete(n),e.current.transitions=e.current.transitions.filter(c),e.current.deleted=e.current.deleted.filter(c))},r=e.current.deleted,o=Array.isArray(r),i=0;for(r=o?r:r[Symbol.iterator]();;){var a;if("break"===n())break}e.current.forceUpdate()}var Z=function(e){function t(t){var n;return void 0===t&&(t={}),n=e.call(this)||this,!t.transform||t.transform instanceof g||(t=b.transform(t)),n.payload=t,n}return s(t,e),t}(w),K={transparent:0,aliceblue:4042850303,antiquewhite:4209760255,aqua:16777215,aquamarine:2147472639,azure:4043309055,beige:4126530815,bisque:4293182719,black:255,blanchedalmond:4293643775,blue:65535,blueviolet:2318131967,brown:2771004159,burlywood:3736635391,burntsienna:3934150143,cadetblue:1604231423,chartreuse:2147418367,chocolate:3530104575,coral:4286533887,cornflowerblue:1687547391,cornsilk:4294499583,crimson:3692313855,cyan:16777215,darkblue:35839,darkcyan:9145343,darkgoldenrod:3095792639,darkgray:2846468607,darkgreen:6553855,darkgrey:2846468607,darkkhaki:3182914559,darkmagenta:2332068863,darkolivegreen:1433087999,darkorange:4287365375,darkorchid:2570243327,darkred:2332033279,darksalmon:3918953215,darkseagreen:2411499519,darkslateblue:1211993087,darkslategray:793726975,darkslategrey:793726975,darkturquoise:13554175,darkviolet:2483082239,deeppink:4279538687,deepskyblue:12582911,dimgray:1768516095,dimgrey:1768516095,dodgerblue:512819199,firebrick:2988581631,floralwhite:4294635775,forestgreen:579543807,fuchsia:4278255615,gainsboro:3705462015,ghostwhite:4177068031,gold:4292280575,goldenrod:3668254975,gray:2155905279,green:8388863,greenyellow:2919182335,grey:2155905279,honeydew:4043305215,hotpink:4285117695,indianred:3445382399,indigo:1258324735,ivory:4294963455,khaki:4041641215,lavender:3873897215,lavenderblush:4293981695,lawngreen:2096890111,lemonchiffon:4294626815,lightblue:2916673279,lightcoral:4034953471,lightcyan:3774873599,lightgoldenrodyellow:4210742015,lightgray:3553874943,lightgreen:2431553791,lightgrey:3553874943,lightpink:4290167295,lightsalmon:4288707327,lightseagreen:548580095,lightskyblue:2278488831,lightslategray:2005441023,lightslategrey:2005441023,lightsteelblue:2965692159,lightyellow:4294959359,lime:16711935,limegreen:852308735,linen:4210091775,magenta:4278255615,maroon:2147483903,mediumaquamarine:1724754687,mediumblue:52735,mediumorchid:3126187007,mediumpurple:2473647103,mediumseagreen:1018393087,mediumslateblue:2070474495,mediumspringgreen:16423679,mediumturquoise:1221709055,mediumvioletred:3340076543,midnightblue:421097727,mintcream:4127193855,mistyrose:4293190143,moccasin:4293178879,navajowhite:4292783615,navy:33023,oldlace:4260751103,olive:2155872511,olivedrab:1804477439,orange:4289003775,orangered:4282712319,orchid:3664828159,palegoldenrod:4008225535,palegreen:2566625535,paleturquoise:2951671551,palevioletred:3681588223,papayawhip:4293907967,peachpuff:4292524543,peru:3448061951,pink:4290825215,plum:3718307327,powderblue:2967529215,purple:2147516671,rebeccapurple:1714657791,red:4278190335,rosybrown:3163525119,royalblue:1097458175,saddlebrown:2336560127,salmon:4202722047,sandybrown:4104413439,seagreen:780883967,seashell:4294307583,sienna:2689740287,silver:3233857791,skyblue:2278484991,slateblue:1784335871,slategray:1887473919,slategrey:1887473919,snow:4294638335,springgreen:16744447,steelblue:1182971135,tan:3535047935,teal:8421631,thistle:3636451583,tomato:4284696575,turquoise:1088475391,violet:4001558271,wheat:4125012991,white:4294967295,whitesmoke:4126537215,yellow:4294902015,yellowgreen:2597139199},J="[-+]?\\d*\\.?\\d+";function X(){for(var e=arguments.length,t=new Array(e),n=0;n<e;n++)t[n]=arguments[n];return"\\(\\s*("+t.join(")\\s*,\\s*(")+")\\s*\\)"}var ee=new RegExp("rgb"+X(J,J,J)),te=new RegExp("rgba"+X(J,J,J,J)),ne=new RegExp("hsl"+X(J,"[-+]?\\d*\\.?\\d+%","[-+]?\\d*\\.?\\d+%")),re=new RegExp("hsla"+X(J,"[-+]?\\d*\\.?\\d+%","[-+]?\\d*\\.?\\d+%",J)),oe=/^#([0-9a-fA-F]{1})([0-9a-fA-F]{1})([0-9a-fA-F]{1})$/,ie=/^#([0-9a-fA-F]{1})([0-9a-fA-F]{1})([0-9a-fA-F]{1})([0-9a-fA-F]{1})$/,ae=/^#([0-9a-fA-F]{6})$/,ce=/^#([0-9a-fA-F]{8})$/;function se(e,t,n){return n<0&&(n+=1),n>1&&(n-=1),n<1/6?e+6*(t-e)*n:n<.5?t:n<2/3?e+(t-e)*(2/3-n)*6:e}function le(e,t,n){var r=n<.5?n*(1+t):n+t-n*t,o=2*n-r,i=se(o,r,e+1/3),a=se(o,r,e),c=se(o,r,e-1/3);return Math.round(255*i)<<24|Math.round(255*a)<<16|Math.round(255*c)<<8}function ue(e){var t=parseInt(e,10);return t<0?0:t>255?255:t}function de(e){return(parseFloat(e)%360+360)%360/360}function me(e){var t=parseFloat(e);return t<0?0:t>1?255:Math.round(255*t)}function pe(e){var t=parseFloat(e);return t<0?0:t>100?1:t/100}function fe(e){var t,n,r="number"==typeof(t=e)?t>>>0===t&&t>=0&&t<=4294967295?t:null:(n=ae.exec(t))?parseInt(n[1]+"ff",16)>>>0:K.hasOwnProperty(t)?K[t]:(n=ee.exec(t))?(ue(n[1])<<24|ue(n[2])<<16|ue(n[3])<<8|255)>>>0:(n=te.exec(t))?(ue(n[1])<<24|ue(n[2])<<16|ue(n[3])<<8|me(n[4]))>>>0:(n=oe.exec(t))?parseInt(n[1]+n[1]+n[2]+n[2]+n[3]+n[3]+"ff",16)>>>0:(n=ce.exec(t))?parseInt(n[1],16)>>>0:(n=ie.exec(t))?parseInt(n[1]+n[1]+n[2]+n[2]+n[3]+n[3]+n[4]+n[4],16)>>>0:(n=ne.exec(t))?(255|le(de(n[1]),pe(n[2]),pe(n[3])))>>>0:(n=re.exec(t))?(le(de(n[1]),pe(n[2]),pe(n[3]))|me(n[4]))>>>0:null;return null===r?e:"rgba("+((4278190080&(r=r||0))>>>24)+", "+((16711680&r)>>>16)+", "+((65280&r)>>>8)+", "+(255&r)/255+")"}var he=/[+\-]?(?:0|[1-9]\d*)(?:\.\d*)?(?:[eE][+\-]?\d+)?/g,be=/(#(?:[0-9a-f]{2}){2,4}|(#[0-9a-f]{3})|(rgb|hsl)a?\((-?\d+%?[,\s]+){2,3}\s*[\d\.]+%?\))/gi,ve=new RegExp("("+Object.keys(K).join("|")+")","g"),ge={animationIterationCount:!0,borderImageOutset:!0,borderImageSlice:!0,borderImageWidth:!0,boxFlex:!0,boxFlexGroup:!0,boxOrdinalGroup:!0,columnCount:!0,columns:!0,flex:!0,flexGrow:!0,flexPositive:!0,flexShrink:!0,flexNegative:!0,flexOrder:!0,gridRow:!0,gridRowEnd:!0,gridRowSpan:!0,gridRowStart:!0,gridColumn:!0,gridColumnEnd:!0,gridColumnSpan:!0,gridColumnStart:!0,fontWeight:!0,lineClamp:!0,lineHeight:!0,opacity:!0,order:!0,orphans:!0,tabSize:!0,widows:!0,zIndex:!0,zoom:!0,fillOpacity:!0,floodOpacity:!0,stopOpacity:!0,strokeDasharray:!0,strokeDashoffset:!0,strokeMiterlimit:!0,strokeOpacity:!0,strokeWidth:!0},ye=["Webkit","Ms","Moz","O"];function we(e,t,n){return null==t||"boolean"==typeof t||""===t?"":n||"number"!=typeof t||0===t||ge.hasOwnProperty(e)&&ge[e]?(""+t).trim():t+"px"}ge=Object.keys(ge).reduce((function(e,t){return ye.forEach((function(n){return e[function(e,t){return e+t.charAt(0).toUpperCase()+t.substring(1)}(n,t)]=e[t]})),e}),ge);var Oe={};R((function(e){return new Z(e)})),T("div"),x((function(e){var t=e.output.map((function(e){return e.replace(be,fe)})).map((function(e){return e.replace(ve,fe)})),n=t[0].match(he).map((function(){return[]}));t.forEach((function(e){e.match(he).forEach((function(e,t){return n[t].push(+e)}))}));var r=t[0].match(he).map((function(t,r){return F(o({},e,{output:n[r]}))}));return function(e){var n=0;return t[0].replace(he,(function(){return r[n++](e)})).replace(/rgba\(([0-9\.-]+), ([0-9\.-]+), ([0-9\.-]+), ([0-9\.-]+)\)/gi,(function(e,t,n,r,o){return"rgba("+Math.round(t)+", "+Math.round(n)+", "+Math.round(r)+", "+o+")"}))}})),j(K),O((function(e,t){if(!e.nodeType||void 0===e.setAttribute)return!1;var n=t.style,r=t.children,o=t.scrollTop,a=t.scrollLeft,c=i(t,["style","children","scrollTop","scrollLeft"]),s="filter"===e.nodeName||e.parentNode&&"filter"===e.parentNode.nodeName;for(var l in void 0!==o&&(e.scrollTop=o),void 0!==a&&(e.scrollLeft=a),void 0!==r&&(e.textContent=r),n)if(n.hasOwnProperty(l)){var u=0===l.indexOf("--"),d=we(l,n[l],u);"float"===l&&(l="cssFloat"),u?e.style.setProperty(l,d):e.style[l]=d}for(var m in c){var p=s?m:Oe[m]||(Oe[m]=m.replace(/([A-Z])/g,(function(e){return"-"+e.toLowerCase()})));void 0!==e.getAttribute(p)&&e.setAttribute(p,c[m])}}),(function(e){return e}));var je,_e,Ee=(je=function(e){return a.forwardRef((function(t,n){var r=d(),s=a.useRef(!0),l=a.useRef(null),m=a.useRef(null),p=a.useCallback((function(e){var t=l.current;l.current=new L(e,(function(){var e=!1;m.current&&(e=b.fn(m.current,l.current.getAnimatedValue())),m.current&&!1!==e||r()})),t&&t.detach()}),[]);a.useEffect((function(){return function(){s.current=!1,l.current&&l.current.detach()}}),[]),a.useImperativeHandle(n,(function(){return N(m,s,r)})),p(t);var f,h=l.current.getValue(),v=(h.scrollTop,h.scrollLeft,i(h,["scrollTop","scrollLeft"])),g=(f=e,!u.fun(f)||f.prototype instanceof c.Component?function(e){return m.current=function(e,t){return t&&(u.fun(t)?t(e):u.obj(t)&&(t.current=e)),e}(e,n)}:void 0);return c.createElement(e,o({},v,{ref:g}))}))},void 0===(_e=!1)&&(_e=!0),function(e){return(u.arr(e)?e:Object.keys(e)).reduce((function(e,t){var n=_e?t[0].toLowerCase()+t.substring(1):t;return e[n]=je(n),e}),je)}),ke=Ee(["a","abbr","address","area","article","aside","audio","b","base","bdi","bdo","big","blockquote","body","br","button","canvas","caption","cite","code","col","colgroup","data","datalist","dd","del","details","dfn","dialog","div","dl","dt","em","embed","fieldset","figcaption","figure","footer","form","h1","h2","h3","h4","h5","h6","head","header","hgroup","hr","html","i","iframe","img","input","ins","kbd","keygen","label","legend","li","link","main","map","mark","menu","menuitem","meta","meter","nav","noscript","object","ol","optgroup","option","output","p","param","picture","pre","progress","q","rp","rt","ruby","s","samp","script","section","select","small","source","span","strong","style","sub","summary","sup","table","tbody","td","textarea","tfoot","th","thead","time","title","tr","track","u","ul","var","video","wbr","circle","clipPath","defs","ellipse","foreignObject","g","image","line","linearGradient","mask","path","pattern","polygon","polyline","radialGradient","rect","stop","svg","text","tspan"]);t.apply=Ee,t.config={default:{tension:170,friction:26},gentle:{tension:120,friction:14},wobbly:{tension:180,friction:12},stiff:{tension:210,friction:20},slow:{tension:280,friction:60},molasses:{tension:280,friction:120}},t.update=D,t.animated=ke,t.a=ke,t.interpolate=function(e,t,n){return e&&new H(e,t,n)},t.Globals=M,t.useSpring=function(e){var t=u.fun(e),n=$(1,t?e:[e]),r=n[0],o=n[1],i=n[2];return t?[r[0],o,i]:r},t.useTrail=function(e,t){var n=a.useRef(!1),r=u.fun(t),i=f(t),c=a.useRef(),s=$(e,(function(e,t){return 0===e&&(c.current=[]),c.current.push(t),o({},i,{config:f(i.config,e),attach:e>0&&function(){return c.current[e-1]}})})),l=s[0],d=s[1],m=s[2],p=a.useMemo((function(){return function(e){return d((function(t,n){e.reverse;var r=e.reverse?t+1:t-1,a=c.current[r];return o({},e,{config:f(e.config||i.config,t),attach:a&&function(){return a}})}))}}),[e,i.reverse]);return a.useEffect((function(){n.current&&!r&&p(t)})),a.useEffect((function(){n.current=!0}),[]),r?[l,p,m]:l},t.useTransition=function(e,t,n){var r=o({items:e,keys:t||function(e){return e}},n),c=Q(r),s=c.lazy,l=void 0!==s&&s,u=(c.unique,c.reset),m=void 0!==u&&u,p=(c.enter,c.leave,c.update,c.onDestroyed),h=(c.keys,c.items,c.onFrame),b=c.onRest,v=c.onStart,g=c.ref,y=i(c,["lazy","unique","reset","enter","leave","update","onDestroyed","keys","items","onFrame","onRest","onStart","ref"]),w=d(),O=a.useRef(!1),j=a.useRef({mounted:!1,first:!0,deleted:[],current:{},transitions:[],prevProps:{},paused:!!r.ref,instances:!O.current&&new Map,forceUpdate:w});return a.useImperativeHandle(r.ref,(function(){return{start:function(){return Promise.all(Array.from(j.current.instances).map((function(e){var t=e[1];return new Promise((function(e){return t.start(e)}))})))},stop:function(e){return Array.from(j.current.instances).forEach((function(t){return t[1].stop(e)}))},get controllers(){return Array.from(j.current.instances).map((function(e){return e[1]}))}}})),j.current=function(e,t){var n=e.first,r=e.prevProps,a=i(e,["first","prevProps"]),c=Q(t),s=c.items,l=c.keys,u=c.initial,d=c.from,m=c.enter,p=c.leave,h=c.update,b=c.trail,v=void 0===b?0:b,g=c.unique,y=c.config,w=c.order,O=void 0===w?["enter","leave","update"]:w,j=Q(r),_=j.keys,E=j.items,k=o({},a.current),x=[].concat(a.deleted),C=Object.keys(k),S=new Set(C),T=new Set(l),A=l.filter((function(e){return!S.has(e)})),P=a.transitions.filter((function(e){return!e.destroyed&&!T.has(e.originalKey)})).map((function(e){return e.originalKey})),N=l.filter((function(e){return S.has(e)})),R=-v;for(;O.length;){switch(O.shift()){case"enter":A.forEach((function(e,t){g&&x.find((function(t){return t.originalKey===e}))&&(x=x.filter((function(t){return t.originalKey!==e})));var r=l.indexOf(e),o=s[r],i=n&&void 0!==u?"initial":"enter";k[e]={slot:i,originalKey:e,key:g?String(e):W++,item:o,trail:R+=v,config:f(y,o,i),from:f(n&&void 0!==u?u||{}:d,o),to:f(m,o)}}));break;case"leave":P.forEach((function(e){var t=_.indexOf(e),n=E[t];x.unshift(o({},k[e],{slot:"leave",destroyed:!0,left:_[Math.max(0,t-1)],right:_[Math.min(_.length,t+1)],trail:R+=v,config:f(y,n,"leave"),to:f(p,n)})),delete k[e]}));break;case"update":N.forEach((function(e){var t=l.indexOf(e),n=s[t];k[e]=o({},k[e],{item:n,slot:"update",trail:R+=v,config:f(y,n,"update"),to:f(h,n)})}))}}var M=l.map((function(e){return k[e]}));return x.forEach((function(e){var t,n=e.left,r=(e.right,i(e,["left","right"]));-1!==(t=M.findIndex((function(e){return e.originalKey===n})))&&(t+=1),t=Math.max(0,t),M=[].concat(M.slice(0,t),[r],M.slice(t))})),o({},a,{changed:A.length||P.length||N.length,first:n&&0===A.length,transitions:M,current:k,deleted:x,prevProps:t})}(j.current,r),j.current.changed&&j.current.transitions.forEach((function(e){var t=e.slot,n=e.from,r=e.to,i=e.config,a=e.trail,c=e.key,s=e.item;j.current.instances.has(c)||j.current.instances.set(c,new q);var u=j.current.instances.get(c),d=o({},y,{to:r,from:n,config:i,ref:g,onRest:function(n){j.current.mounted&&(e.destroyed&&(g||l||Y(j,c),p&&p(s)),!Array.from(j.current.instances).some((function(e){return!e[1].idle}))&&(g||l)&&j.current.deleted.length>0&&Y(j),b&&b(s,t,n))},onStart:v&&function(){return v(s,t)},onFrame:h&&function(e){return h(s,t,e)},delay:a,reset:m&&"enter"===t});u.update(d),j.current.paused||u.start()})),a.useEffect((function(){return j.current.mounted=O.current=!0,function(){j.current.mounted=O.current=!1,Array.from(j.current.instances).map((function(e){return e[1].destroy()})),j.current.instances.clear()}}),[]),j.current.transitions.map((function(e){var t=e.item,n=e.slot,r=e.key;return{item:t,key:r,state:n,props:j.current.instances.get(r).getValues()}}))},t.useChain=function(e,t,n){void 0===n&&(n=1e3);var r=a.useRef();a.useEffect((function(){u.equ(e,r.current)?e.forEach((function(e){var t=e.current;return t&&t.start()})):t?e.forEach((function(e,r){var i=e.current;if(i){var a=i.controllers;if(a.length){var c=n*t[r];a.forEach((function(e){e.queue=e.queue.map((function(e){return o({},e,{delay:e.delay+c})})),e.start()}))}}})):e.reduce((function(e,t,n){var r=t.current;return e.then((function(){return r.start()}))}),Promise.resolve()),r.current=e}))},t.useSprings=$},16:function(e,t){e.exports=window.wp.url},160:function(e,t,n){"use strict";(function(e){var r=n(5),o=n.n(r),i=n(25),a=n(1),c=n.n(a),s="undefined"!=typeof globalThis?globalThis:"undefined"!=typeof window?window:void 0!==e?e:{};function l(e){var t=[];return{on:function(e){t.push(e)},off:function(e){t=t.filter((function(t){return t!==e}))},get:function(){return e},set:function(n,r){e=n,t.forEach((function(t){return t(e,r)}))}}}var u=o.a.createContext||function(e,t){var n,o,a,u="__create-react-context-"+((s[a="__global_unique_id__"]=(s[a]||0)+1)+"__"),d=function(e){function n(){var t;return(t=e.apply(this,arguments)||this).emitter=l(t.props.value),t}Object(i.a)(n,e);var r=n.prototype;return r.getChildContext=function(){var e;return(e={})[u]=this.emitter,e},r.componentWillReceiveProps=function(e){if(this.props.value!==e.value){var n,r=this.props.value,o=e.value;((i=r)===(a=o)?0!==i||1/i==1/a:i!=i&&a!=a)?n=0:(n="function"==typeof t?t(r,o):1073741823,0!==(n|=0)&&this.emitter.set(e.value,n))}var i,a},r.render=function(){return this.props.children},n}(r.Component);d.childContextTypes=((n={})[u]=c.a.object.isRequired,n);var m=function(t){function n(){var e;return(e=t.apply(this,arguments)||this).state={value:e.getValue()},e.onUpdate=function(t,n){0!=((0|e.observedBits)&n)&&e.setState({value:e.getValue()})},e}Object(i.a)(n,t);var r=n.prototype;return r.componentWillReceiveProps=function(e){var t=e.observedBits;this.observedBits=null==t?1073741823:t},r.componentDidMount=function(){this.context[u]&&this.context[u].on(this.onUpdate);var e=this.props.observedBits;this.observedBits=null==e?1073741823:e},r.componentWillUnmount=function(){this.context[u]&&this.context[u].off(this.onUpdate)},r.getValue=function(){return this.context[u]?this.context[u].get():e},r.render=function(){return(e=this.props.children,Array.isArray(e)?e[0]:e)(this.state.value);var e},n}(r.Component);return m.contextTypes=((o={})[u]=c.a.object,o),{Provider:d,Consumer:m}};t.a=u}).call(this,n(79))},161:function(e,t,n){var r=n(299);e.exports=p,e.exports.parse=i,e.exports.compile=function(e,t){return c(i(e,t),t)},e.exports.tokensToFunction=c,e.exports.tokensToRegExp=m;var o=new RegExp(["(\\\\.)","([\\/.])?(?:(?:\\:(\\w+)(?:\\(((?:\\\\.|[^\\\\()])+)\\))?|\\(((?:\\\\.|[^\\\\()])+)\\))([+*?])?|(\\*))"].join("|"),"g");function i(e,t){for(var n,r=[],i=0,a=0,c="",u=t&&t.delimiter||"/";null!=(n=o.exec(e));){var d=n[0],m=n[1],p=n.index;if(c+=e.slice(a,p),a=p+d.length,m)c+=m[1];else{var f=e[a],h=n[2],b=n[3],v=n[4],g=n[5],y=n[6],w=n[7];c&&(r.push(c),c="");var O=null!=h&&null!=f&&f!==h,j="+"===y||"*"===y,_="?"===y||"*"===y,E=n[2]||u,k=v||g;r.push({name:b||i++,prefix:h||"",delimiter:E,optional:_,repeat:j,partial:O,asterisk:!!w,pattern:k?l(k):w?".*":"[^"+s(E)+"]+?"})}}return a<e.length&&(c+=e.substr(a)),c&&r.push(c),r}function a(e){return encodeURI(e).replace(/[\/?#]/g,(function(e){return"%"+e.charCodeAt(0).toString(16).toUpperCase()}))}function c(e,t){for(var n=new Array(e.length),o=0;o<e.length;o++)"object"==typeof e[o]&&(n[o]=new RegExp("^(?:"+e[o].pattern+")$",d(t)));return function(t,o){for(var i="",c=t||{},s=(o||{}).pretty?a:encodeURIComponent,l=0;l<e.length;l++){var u=e[l];if("string"!=typeof u){var d,m=c[u.name];if(null==m){if(u.optional){u.partial&&(i+=u.prefix);continue}throw new TypeError('Expected "'+u.name+'" to be defined')}if(r(m)){if(!u.repeat)throw new TypeError('Expected "'+u.name+'" to not repeat, but received `'+JSON.stringify(m)+"`");if(0===m.length){if(u.optional)continue;throw new TypeError('Expected "'+u.name+'" to not be empty')}for(var p=0;p<m.length;p++){if(d=s(m[p]),!n[l].test(d))throw new TypeError('Expected all "'+u.name+'" to match "'+u.pattern+'", but received `'+JSON.stringify(d)+"`");i+=(0===p?u.prefix:u.delimiter)+d}}else{if(d=u.asterisk?encodeURI(m).replace(/[?#]/g,(function(e){return"%"+e.charCodeAt(0).toString(16).toUpperCase()})):s(m),!n[l].test(d))throw new TypeError('Expected "'+u.name+'" to match "'+u.pattern+'", but received "'+d+'"');i+=u.prefix+d}}else i+=u}return i}}function s(e){return e.replace(/([.+*?=^!:${}()[\]|\/\\])/g,"\\$1")}function l(e){return e.replace(/([=!:$\/()])/g,"\\$1")}function u(e,t){return e.keys=t,e}function d(e){return e&&e.sensitive?"":"i"}function m(e,t,n){r(t)||(n=t||n,t=[]);for(var o=(n=n||{}).strict,i=!1!==n.end,a="",c=0;c<e.length;c++){var l=e[c];if("string"==typeof l)a+=s(l);else{var m=s(l.prefix),p="(?:"+l.pattern+")";t.push(l),l.repeat&&(p+="(?:"+m+p+")*"),a+=p=l.optional?l.partial?m+"("+p+")?":"(?:"+m+"("+p+"))?":m+"("+p+")"}}var f=s(n.delimiter||"/"),h=a.slice(-f.length)===f;return o||(a=(h?a.slice(0,-f.length):a)+"(?:"+f+"(?=$))?"),a+=i?"$":o&&h?"":"(?="+f+"|$)",u(new RegExp("^"+a,d(n)),t)}function p(e,t,n){return r(t)||(n=t||n,t=[]),n=n||{},e instanceof RegExp?function(e,t){var n=e.source.match(/\((?!\?)/g);if(n)for(var r=0;r<n.length;r++)t.push({name:r,prefix:null,delimiter:null,optional:!1,repeat:!1,partial:!1,asterisk:!1,pattern:null});return u(e,t)}(e,t):r(e)?function(e,t,n){for(var r=[],o=0;o<e.length;o++)r.push(p(e[o],t,n).source);return u(new RegExp("(?:"+r.join("|")+")",d(n)),t)}(e,t,n):function(e,t,n){return m(i(e,n),t,n)}(e,t,n)}},164:function(e,t,n){"use strict";n.d(t,"a",(function(){return o})),n.d(t,"b",(function(){return i})),n.d(t,"c",(function(){return c}));var r=n(4);function o(e,t){return Object(r.filter)(e,e=>{const{is_deleted:n,date_created_gmt:r,status:o}=e;if(!n){return(!t||!r||new Date(r+"Z").getTime()>t)&&"unactioned"===o}}).length}function i(e){return Object(r.filter)(e,e=>{const{is_deleted:t}=e;return!t}).length>0}const a=(e,t)=>{const n=document.createElement("div"),o=Array.from(e.childNodes);for(let e=0;e<o.length;e++){let i=o[e].cloneNode(!0);if(!(n.textContent.length+i.textContent.length<=t)){const e=t-n.textContent.length;i.innerHTML&&i.textContent.slice(0,e)!==i.innerHTML.slice(0,e)?i=a(i,e):i.textContent=Object(r.truncate)(i.textContent,{length:e,separator:" ",omission:""}),n.appendChild(i);break}n.appendChild(i)}return n},c=(e,t)=>{const n=document.createElement("div");return n.innerHTML=e,n.textContent.length>t?a(n,t).innerHTML+"...":e}},17:function(e,t){e.exports=window.wc.experimental},170:function(e,t,n){"use strict";n.d(t,"a",(function(){return u})),n.d(t,"b",(function(){return p}));var r=n(0),o=n(3),i=n(7),a=n(2),c=n(11),s=n(15);const l=()=>Object(r.createElement)(r.Fragment,null,Object(r.createElement)("svg",{className:"woocommerce-layout__activity-panel-tab-icon",width:"24",height:"24",viewBox:"3 3 24 24",fill:"none",xmlns:"http://www.w3.org/2000/svg"},Object(r.createElement)("path",{d:"M13.8053 15.3982C13.8053 15.7965 13.4867 16.1947 13.0089 16.1947H6.79646C6.55752 16.1947 6.39823 16.115 6.23894 15.9558C6.07965 15.7965 6 15.6372 6 15.3982V6.79646C6 6.63717 6.15929 6.39823 6.23894 6.23894C6.39823 6.07965 6.55752 6 6.79646 6H13.0089C13.4071 6 13.8053 6.31858 13.8053 6.79646V15.3982Z",strokeWidth:"1.5",strokeLinecap:"round",strokeLinejoin:"round"}),Object(r.createElement)("path",{d:"M23.9203 10.6195C23.9203 11.0177 23.6017 11.4159 23.1238 11.4159H16.9115C16.6725 11.4159 16.5132 11.3363 16.3539 11.177C16.1946 11.0177 16.115 10.8584 16.115 10.6195V6.79646C16.115 6.39823 16.4336 6 16.9115 6H23.1238C23.5221 6 23.9203 6.31858 23.9203 6.79646V10.6195Z",strokeWidth:"1.5",strokeLinecap:"round",strokeLinejoin:"round"}),Object(r.createElement)("path",{d:"M13.8053 23.2035C13.8053 23.4424 13.7257 23.6017 13.5664 23.761C13.4071 23.9203 13.2478 23.9999 13.0089 23.9999H6.79646C6.39823 23.9999 6 23.6813 6 23.2035V19.3804C6 19.1415 6.07965 18.9822 6.23894 18.8229C6.39823 18.6636 6.55752 18.584 6.79646 18.584H13.0089C13.4071 18.584 13.8053 18.9026 13.8053 19.3804V23.2035Z",strokeWidth:"1.5",strokeLinecap:"round",strokeLinejoin:"round"}),Object(r.createElement)("path",{d:"M16.9912 23.9999C16.7522 23.9999 16.5929 23.9202 16.4336 23.7609C16.2743 23.6016 16.1947 23.4423 16.1947 23.2034V14.6016C16.1947 14.3627 16.2743 14.2034 16.4336 14.0441C16.5929 13.8848 16.7522 13.8052 16.9912 13.8052H23.2036C23.4425 13.8052 23.6018 13.8848 23.7611 14.0441C23.9204 14.2034 24 14.3627 24 14.6016V23.2034C24 23.6016 23.6814 23.9999 23.2036 23.9999H16.9912Z",strokeWidth:"1.5",strokeLinecap:"round",strokeLinejoin:"round"})),Object(a.__)("Display","woocommerce-admin")),{Fill:u,Slot:d}=Object(o.createSlotFill)("DisplayOptions");u.Slot=d;const m=[{value:"single_column",label:Object(r.createElement)(r.Fragment,null,Object(r.createElement)(()=>Object(r.createElement)("svg",{className:"woocommerce-layout__activity-panel-tab-icon",width:"12",height:"14",viewBox:"0 0 12 14",fill:"none",xmlns:"http://www.w3.org/2000/svg"},Object(r.createElement)("rect",{x:"0.5",y:"0.5",width:"11",height:"13",strokeWidth:"1"})),null),Object(a.__)("Single column","woocommerce-admin"))},{value:"two_columns",label:Object(r.createElement)(r.Fragment,null,Object(r.createElement)(()=>Object(r.createElement)("svg",{className:"woocommerce-layout__activity-panel-tab-icon",width:"18",height:"14",viewBox:"0 0 18 14",fill:"none",xmlns:"http://www.w3.org/2000/svg"},Object(r.createElement)("rect",{x:"0.5",y:"0.5",width:"7",height:"13",strokeWidth:"1"}),Object(r.createElement)("rect",{x:"9.5",y:"0.5",width:"7",height:"13",strokeWidth:"1"})),null),Object(a.__)("Two columns","woocommerce-admin"))}],p=()=>{const{defaultHomescreenLayout:e,taskListComplete:t,isTaskListHidden:n}=Object(i.useSelect)(e=>{const{getOption:t}=e(c.OPTIONS_STORE_NAME),{getTaskList:n}=e(c.ONBOARDING_STORE_NAME),r=n("setup");return{defaultHomescreenLayout:t("woocommerce_default_homepage_layout")||"single_column",taskListComplete:null==r?void 0:r.isComplete,isTaskListHidden:null==r?void 0:r.isHidden}}),{updateUserPreferences:u,homepage_layout:p}=Object(c.useUserPreferences)(),f=t||n||window.wcAdminFeatures.analytics;return Object(r.createElement)(d,null,t=>0!==t.length||f?Object(r.createElement)(o.DropdownMenu,{icon:Object(r.createElement)(l,null),label:Object(a.__)("Display options","woocommerce-admin"),toggleProps:{className:"woocommerce-layout__activity-panel-tab display-options",onClick:()=>Object(s.recordEvent)("homescreen_display_click")},popoverProps:{className:"woocommerce-layout__activity-panel-popover"}},({onClose:n})=>Object(r.createElement)(r.Fragment,null,t,f?Object(r.createElement)(o.MenuGroup,{className:"woocommerce-layout__homescreen-display-options",label:Object(a.__)("Layout","woocommerce-admin")},Object(r.createElement)(o.MenuItemsChoice,{choices:m,onSelect:e=>{u({homepage_layout:e}),n(),Object(s.recordEvent)("homescreen_display_option",{display_option:e})},value:p||e})):null)):null)}},175:function(e,t,n){"use strict";n.d(t,"a",(function(){return c}));var r=n(0),o=n(2),i=n(3),a=n(17);const c=()=>Object(r.createElement)("div",{className:"woocommerce-layout__no-match"},Object(r.createElement)(i.Card,null,Object(r.createElement)(i.CardBody,null,Object(r.createElement)(a.Text,null,Object(o.__)("Sorry, you are not allowed to access this page.","woocommerce-admin")))))},18:function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},o=c(n(5)),i=c(n(69)),a=c(n(72));function c(e){return e&&e.__esModule?e:{default:e}}var s=void 0;function l(e,t){var n,a,c,u,d,m,p,f,h=[],b={};for(m=0;m<e.length;m++)if("string"!==(d=e[m]).type){if(!t.hasOwnProperty(d.value)||void 0===t[d.value])throw new Error("Invalid interpolation, missing component node: `"+d.value+"`");if("object"!==r(t[d.value]))throw new Error("Invalid interpolation, component node must be a ReactElement or null: `"+d.value+"`","\n> "+s);if("componentClose"===d.type)throw new Error("Missing opening component token: `"+d.value+"`");if("componentOpen"===d.type){n=t[d.value],c=m;break}h.push(t[d.value])}else h.push(d.value);return n&&(u=function(e,t){var n,r,o=t[e],i=0;for(r=e+1;r<t.length;r++)if((n=t[r]).value===o.value){if("componentOpen"===n.type){i++;continue}if("componentClose"===n.type){if(0===i)return r;i--}}throw new Error("Missing closing component token `"+o.value+"`")}(c,e),p=l(e.slice(c+1,u),t),a=o.default.cloneElement(n,{},p),h.push(a),u<e.length-1&&(f=l(e.slice(u+1),t),h=h.concat(f))),1===h.length?h[0]:(h.forEach((function(e,t){e&&(b["interpolation-child-"+t]=e)})),(0,i.default)(b))}t.default=function(e){var t=e.mixedString,n=e.components,o=e.throwErrors;if(s=t,!n)return t;if("object"!==(void 0===n?"undefined":r(n))){if(o)throw new Error("Interpolation Error: unable to process `"+t+"` because components is not an object");return t}var i=(0,a.default)(t);try{return l(i,n)}catch(e){if(o)throw new Error("Interpolation Error: unable to process `"+t+"` because of error `"+e.message+"`");return t}}},19:function(e,t){e.exports=window.wp.apiFetch},2:function(e,t){e.exports=window.wp.i18n},20:function(e,t){e.exports=window.wc.date},21:function(e,t){e.exports=window.wc.components},22:function(e,t,n){"use strict";function r(e,t){if(null==e)return{};var n,r,o={},i=Object.keys(e);for(r=0;r<i.length;r++)n=i[r],t.indexOf(n)>=0||(o[n]=e[n]);return o}n.d(t,"a",(function(){return r}))},23:function(e,t,n){"use strict";function r(){return(r=Object.assign||function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e}).apply(this,arguments)}n.d(t,"a",(function(){return r}))},25:function(e,t,n){"use strict";function r(e,t){return(r=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e})(e,t)}function o(e,t){e.prototype=Object.create(t.prototype),e.prototype.constructor=e,r(e,t)}n.d(t,"a",(function(){return o}))},255:function(e,t,n){"use strict";n.d(t,"a",(function(){return y})),n.d(t,"b",(function(){return w}));var r=n(0),o=n(2),i=n(17),a=n(15),c=n(21),s=n(7),l=n(11),u=n(500),d=n(8),m=Object(r.createElement)(d.SVG,{viewBox:"0 0 24 24",xmlns:"http://www.w3.org/2000/svg"},Object(r.createElement)(d.Path,{d:"M18 4H6c-1.1 0-2 .9-2 2v12.9c0 .6.5 1.1 1.1 1.1.3 0 .5-.1.8-.3L8.5 17H18c1.1 0 2-.9 2-2V6c0-1.1-.9-2-2-2zm.5 11c0 .3-.2.5-.5.5H7.9l-2.4 2.4V6c0-.3.2-.5.5-.5h12c.3 0 .5.2.5.5v9z"})),p=n(501),f=n(3),h=n(68),b=n(103),v=n(62);const g=()=>Object(r.createElement)("svg",{width:"24",height:"24",viewBox:"0 0 24 24",xmlns:"http://www.w3.org/2000/svg"},Object(r.createElement)("path",{d:"M0 0h24v24H0z",fill:"none"}),Object(r.createElement)("path",{d:"M12 22c1.1 0 2-.9 2-2h-4c0 1.1.9 2 2 2zm6-6v-5c0-3.07-1.63-5.64-4.5-6.32V4c0-.83-.67-1.5-1.5-1.5s-1.5.67-1.5 1.5v.68C7.64 5.36 6 7.92 6 11v5l-2 2v1h16v-1l-2-2zm-2 1H8v-6c0-2.48 1.51-4.5 4-4.5s4 2.02 4 4.5v6z"})),y="AbbreviatedNotification",w=({thingsToDoNextCount:e})=>{const{ordersToProcessCount:t,reviewsToModerateCount:n,stockNoticesCount:d,isSetupTaskListHidden:w,isExtendedTaskListHidden:O}=Object(s.useSelect)(e=>{var t,n;const{getTaskList:r}=e(l.ONBOARDING_STORE_NAME),o=Object(h.c)(e);return{ordersToProcessCount:Object(h.d)(e,o),reviewsToModerateCount:Object(b.b)(e),stockNoticesCount:Object(h.a)(e),isSetupTaskListHidden:null===(t=r("setup"))||void 0===t?void 0:t.isHidden,isExtendedTaskListHidden:null===(n=r("extended"))||void 0===n?void 0:n.isHidden}}),j=e=>{Object(a.recordEvent)("activity_panel_click",{task:e})},{Slot:_}=Object(f.createSlotFill)(y),E=Object(v.f)(window.location.href);return Object(r.createElement)("div",{className:"woocommerce-abbreviated-notifications"},e>0&&!O&&Object(r.createElement)(c.AbbreviatedCard,{className:"woocommerce-abbreviated-notification",icon:Object(r.createElement)(g,null),href:"admin.php?page=wc-admin#extended_task_list",onClick:()=>j("thingsToDoNext"),type:E?"wc-admin":"wp-admin"},Object(r.createElement)(i.Text,{as:"h3"},Object(o.__)("Things to do next","woocommerce-admin")),Object(r.createElement)(i.Text,{as:"p"},Object(o.sprintf)(Object(o._n)("You have %d new thing to do","You have %d new things to do",e,"woocommerce-admin"),e))),t>0&&w&&Object(r.createElement)(c.AbbreviatedCard,{className:"woocommerce-abbreviated-notification",icon:u.a,href:"admin.php?page=wc-admin&opened_panel=orders-panel",onClick:()=>j("ordersToProcess"),type:E?"wc-admin":"wp-admin"},Object(r.createElement)(i.Text,{as:"h3"},Object(o.__)("Orders to fulfill","woocommerce-admin")),Object(r.createElement)(i.Text,null,Object(o.sprintf)(Object(o._n)("You have %d order to fulfill","You have %d orders to fulfill",t,"woocommerce-admin"),t))),n>0&&w&&Object(r.createElement)(c.AbbreviatedCard,{className:"woocommerce-abbreviated-notification",icon:m,href:"admin.php?page=wc-admin&opened_panel=reviews-panel",onClick:()=>j("reviewsToModerate"),type:E?"wc-admin":"wp-admin"},Object(r.createElement)(i.Text,{as:"h3"},Object(o.__)("Reviews to moderate","woocommerce-admin")),Object(r.createElement)(i.Text,null,Object(o.sprintf)(Object(o._n)("You have %d review to moderate","You have %d reviews to moderate",n,"woocommerce-admin"),n))),d>0&&w&&Object(r.createElement)(c.AbbreviatedCard,{className:"woocommerce-abbreviated-notification",icon:p.a,href:"admin.php?page=wc-admin&opened_panel=stock-panel",onClick:()=>j("stockNotices"),type:E?"wc-admin":"wp-admin"},Object(r.createElement)(i.Text,{as:"h3"},Object(o.__)("Inventory to review","woocommerce-admin")),Object(r.createElement)(i.Text,null,Object(o.__)("You have inventory to review and update","woocommerce-admin"))),!O&&Object(r.createElement)(_,null))}},256:function(e,t,n){"use strict";n.d(t,"a",(function(){return f})),n.d(t,"b",(function(){return y}));var r=n(0),o=n(2),i=n(31),a=n(18),c=n.n(a),s=n(13),l=n(28),u=n(21),d=n(11),m=n(20);var p=({value:e,onChange:t})=>{const{wcAdminSettings:n}=Object(d.useSettings)("wc_admin",["wcAdminSettings"]),{woocommerce_default_date_range:o}=n,i=Object(l.parse)(e.replace(/&/g,"&")),{period:a,compare:c,before:s,after:p}=Object(m.getDateParamsFromQuery)(i,o),{primary:f,secondary:h}=Object(m.getCurrentDates)(i,o),b={period:a,compare:c,before:s,after:p,primaryDate:f,secondaryDate:h};return Object(r.createElement)(u.DateRangeFilterPicker,{query:i,onRangeSelect:e=>{t({target:{name:"woocommerce_default_date_range",value:Object(l.stringify)(e)}})},dateQuery:b,isoDateFormat:m.isoDateFormat})};const f=["processing","on-hold"],h=["completed","processing","refunded","cancelled","failed","pending","on-hold"],b=Object.keys(s.c).filter(e=>"refunded"!==e).map(e=>({value:e,label:s.c[e],description:Object(o.sprintf)(Object(o.__)("Exclude the %s status from reports","woocommerce-admin"),s.c[e])})),v=Object(s.f)("unregisteredOrderStatuses",{}),g=[{key:"defaultStatuses",options:b.filter(e=>h.includes(e.value))},{key:"customStatuses",label:Object(o.__)("Custom Statuses","woocommerce-admin"),options:b.filter(e=>!h.includes(e.value))},{key:"unregisteredStatuses",label:Object(o.__)("Unregistered Statuses","woocommerce-admin"),options:Object.keys(v).map(e=>({value:e,label:e,description:Object(o.sprintf)(Object(o.__)("Exclude the %s status from reports","woocommerce-admin"),e)}))}],y=Object(i.applyFilters)("woocommerce_admin_analytics_settings",{woocommerce_excluded_report_order_statuses:{label:Object(o.__)("Excluded statuses:","woocommerce-admin"),inputType:"checkboxGroup",options:g,helpText:c()({mixedString:Object(o.__)("Orders with these statuses are excluded from the totals in your reports. The {{strong}}Refunded{{/strong}} status can not be excluded.","woocommerce-admin"),components:{strong:Object(r.createElement)("strong",null)}}),defaultValue:["pending","cancelled","failed"]},woocommerce_actionable_order_statuses:{label:Object(o.__)("Actionable statuses:","woocommerce-admin"),inputType:"checkboxGroup",options:g,helpText:Object(o.__)("Orders with these statuses require action on behalf of the store admin. These orders will show up in the Home Screen - Orders task.","woocommerce-admin"),defaultValue:f},woocommerce_default_date_range:{name:"woocommerce_default_date_range",label:Object(o.__)("Default date range:","woocommerce-admin"),inputType:"component",component:p,helpText:Object(o.__)("Select a default date range. When no range is selected, reports will be viewed by the default date range.","woocommerce-admin"),defaultValue:"period=month&compare=previous_year"}})},257:function(e,t,n){"use strict";(function(e){var r=n(0),o=n(4),i=n(6),a=n.n(i),c=n(258),s=n(2),l=(n(259),n(3));t.a=Object(r.forwardRef)((function({className:t,children:n,spokenMessage:i=n,politeness:u="polite",actions:d=[],onRemove:m=o.noop,icon:p=null,explicitDismiss:f=!1,onDismiss:h=null},b){function v(e){e&&e.preventDefault&&e.preventDefault(),h(),m()}h=h||o.noop,function(e,t){const n="string"==typeof e?e:Object(r.renderToString)(e);Object(r.useEffect)(()=>{n&&Object(c.speak)(n,t)},[n,t])}(i,u),Object(r.useEffect)(()=>{const e=setTimeout(()=>{f||(h(),m())},1e4);return()=>clearTimeout(e)},[f,h,m]);const g=a()(t,"components-snackbar",{"components-snackbar-explicit-dismiss":!!f});d&&d.length>1&&(void 0!==e&&e.env,d=[d[0]]);const y=a()("components-snackbar__content",{"components-snackbar__content-with-icon":!!p});return Object(r.createElement)("div",{ref:b,className:g,onClick:f?o.noop:v,tabIndex:"0",role:f?"":"button",onKeyPress:f?o.noop:v,"aria-label":f?"":Object(s.__)("Dismiss this notice")},Object(r.createElement)("div",{className:y},p&&Object(r.createElement)("div",{className:"components-snackbar__icon"},p),n,d.map(({label:e,onClick:t,url:n},o)=>Object(r.createElement)(l.Button,{key:o,href:n,isTertiary:!0,onClick:e=>function(e,t){e.stopPropagation(),m(),t&&t(e)}(e,t),className:"components-snackbar__action"},e)),f&&Object(r.createElement)("span",{role:"button","aria-label":"Dismiss this notice",tabIndex:"0",className:"components-snackbar__dismiss-button",onClick:v,onKeyPress:v},"✕")))}))}).call(this,n(128))},258:function(e,t){e.exports=window.wp.a11y},259:function(e,t){e.exports=window.wp.warning},260:function(e,t){e.exports=window.wc.customerEffortScore},27:function(e,t){e.exports=window.wp.keycodes},271:function(e,t,n){"use strict";n.d(t,"a",(function(){return A}));var r={};n.r(r),n.d(r,"setCesSurveyQueue",(function(){return O})),n.d(r,"addCesSurvey",(function(){return j})),n.d(r,"addCesSurveyForAnalytics",(function(){return _})),n.d(r,"addCesSurveyForCustomerSearch",(function(){return E}));var o={};n.r(o),n.d(o,"getCesSurveyQueue",(function(){return k}));var i={};n.r(i),n.d(i,"getCesSurveyQueue",(function(){return x}));var a=n(0),c=n(1),s=n.n(c),l=n(15),u=n(260),d=n.n(u),m=n(14),p=n(7),f=n(11),h=n(2);function b({action:e,trackProps:t,label:n,onSubmitLabel:r=Object(h.__)("Thank you for your feedback!","woocommerce-admin"),cesShownForActions:o,allowTracking:i,resolving:c,storeAgeInWeeks:s,updateOptions:u,createNotice:m}){const[p,f]=Object(a.useState)(!1);if(c)return null;if(!i)return null;if(-1!==o.indexOf(e)&&!p)return null;const b=()=>{u({woocommerce_ces_shown_for_actions:[e,...o]})};return Object(a.createElement)(d.a,{recordScoreCallback:(n,o)=>{Object(l.recordEvent)("ces_feedback",{action:e,score:n,comments:o||"",store_age:s,...t}),m("success",r)},label:n,onNoticeShownCallback:()=>{Object(l.recordEvent)("ces_snackbar_view",{action:e,store_age:s,...t})},onNoticeDismissedCallback:()=>{Object(l.recordEvent)("ces_snackbar_dismiss",{action:e,store_age:s,...t}),b()},onModalShownCallback:()=>{f(!0),Object(l.recordEvent)("ces_view",{action:e,store_age:s,...t}),b()},icon:Object(a.createElement)("span",{style:{height:21,width:21},role:"img","aria-label":Object(h.__)("Pencil icon","woocommerce-admin")},"✏️")})}b.propTypes={action:s.a.string.isRequired,trackProps:s.a.object,label:s.a.string.isRequired,onSubmitLabel:s.a.string,cesShownForActions:s.a.arrayOf(s.a.string).isRequired,allowTracking:s.a.bool,resolving:s.a.bool.isRequired,storeAgeInWeeks:s.a.number,updateOptions:s.a.func,createNotice:s.a.func};var v=Object(m.compose)(Object(p.withSelect)(e=>{const{getOption:t,isResolving:n}=e(f.OPTIONS_STORE_NAME),r=t("woocommerce_ces_shown_for_actions")||[],o=function(e){if(0===e)return null;const t=Date.now()-1e3*e;return Math.round(t/f.WEEK)}(t("woocommerce_admin_install_timestamp")||0);return{cesShownForActions:r,allowTracking:"yes"===(t("woocommerce_allow_tracking")||"no"),storeAgeInWeeks:o,resolving:n("getOption",["woocommerce_ces_shown_for_actions"])||null===o||n("getOption",["woocommerce_admin_install_timestamp"])||n("getOption",["woocommerce_allow_tracking"])}}),Object(p.withDispatch)(e=>{const{updateOptions:t}=e(f.OPTIONS_STORE_NAME),{createNotice:n}=e("core/notices");return{updateOptions:t,createNotice:n}}))(b),g=n(55),y=n(10);var w={SET_CES_SURVEY_QUEUE:"SET_CES_SURVEY_QUEUE",ADD_CES_SURVEY:"ADD_CES_SURVEY"};function O(e){return{type:w.SET_CES_SURVEY_QUEUE,queue:e}}function j(e,t,n=window.pagenow,r=window.adminpage,o,i={}){return{type:w.ADD_CES_SURVEY,action:e,label:t,pageNow:n,adminPage:r,onsubmit_label:o,props:i}}function _(){return j("analytics_filtered",Object(h.__)("How easy was it to filter your store analytics?","woocommerce-admin"),"woocommerce_page_wc-admin","woocommerce_page_wc-admin")}function E(){return j("ces_search",Object(h.__)("How easy was it to use search?","woocommerce-admin"),"woocommerce_page_wc-admin","woocommerce_page_wc-admin",void 0,{search_area:"customer"})}function*k(){const e=yield Object(y.apiFetch)({path:`${g.a}/options?options=${g.b}`});if(!e)throw new Error;yield O(e[g.b]||[])}function x(e){return e.queue}const C={queue:[]};var S=(e=C,t)=>{switch(t.type){case w.SET_CES_SURVEY_QUEUE:return{...e,queue:t.queue};case w.ADD_CES_SURVEY:if(e.queue.filter(e=>e.action===t.action).length)return e;const n={action:t.action,label:t.label,pagenow:t.pageNow,adminpage:t.adminPage,onSubmitLabel:t.onSubmitLabel,props:t.props};return{...e,queue:[...e.queue,n]};default:return e}};Object(p.registerStore)(g.c,{actions:r,selectors:i,resolvers:o,controls:y.controls,reducer:S});function T({queue:e,resolving:t,clearQueue:n}){if(t)return null;const r=e.filter(e=>e.pagenow===window.pagenow&&e.adminpage===window.adminpage);return r.length&&n(),Object(a.createElement)(a.Fragment,null,r.map((e,t)=>Object(a.createElement)(v,{key:t,action:e.action,label:e.label,onSubmitLabel:e.onsubmit_label,trackProps:e.props||{}})))}T.propTypes={queue:s.a.arrayOf(s.a.object),resolving:s.a.bool,clearQueue:s.a.func};var A=Object(m.compose)(Object(p.withSelect)(e=>{const{getCesSurveyQueue:t,isResolving:n}=e(g.c);return{queue:t(),resolving:n("getOption",[g.b])}}),Object(p.withDispatch)(e=>{const{updateOptions:t}=e(f.OPTIONS_STORE_NAME);return{clearQueue:()=>{t({woocommerce_clear_ces_tracks_queue_for_page:{pagenow:window.pagenow,adminpage:window.adminpage}})}}}))(T)},272:function(e,t,n){"use strict";n.d(t,"a",(function(){return f}));var r=n(36),o=n.n(r),i=n(0),a=n(31),c=n(28),s=n(7),l=n(11);var u=({children:e})=>{const{currentUserCan:t}=Object(l.useUser)(),n=Object(s.useSelect)(e=>{const{getOption:t,hasFinishedResolution:n}=e(l.OPTIONS_STORE_NAME),r=n("getOption",["woocommerce_show_marketplace_suggestions"]),o="no"!==t("woocommerce_show_marketplace_suggestions");return r&&o});return t("install_plugins")&&n?Object(i.createElement)(i.Fragment,null,e):null};const d=Object(i.lazy)(()=>n.e(44).then(n.bind(null,622))),m=Object(i.lazy)(()=>n.e(47).then(n.bind(null,630)));n(300);const p=[({page:e,tab:t,section:n})=>"wc-settings"!==e||"checkout"!==t||n?null:Object(i.createElement)(u,null,Object(i.createElement)(i.Suspense,{fallback:null},Object(i.createElement)(d,null))),({page:e,tab:t,section:n,zone_id:r})=>"wc-settings"!==e||"shipping"!==t||Boolean(n)||Boolean(r)?null:Object(i.createElement)(u,null,Object(i.createElement)(i.Suspense,{fallback:null},Object(i.createElement)(m,null)))],f=()=>{const e=Object(c.parse)(location.search.substring(1));let t={page:"",tab:""};void 0!==e.page&&(t=e);const n=Object(a.applyFilters)("woocommerce_admin_embedded_layout_components",p,t);return Object(i.createElement)("div",{className:"woocommerce-embedded-layout__primary",id:"woocommerce-embedded-layout__primary"},n.map((e,n)=>Object(i.createElement)(e,o()({key:n},t))))}},28:function(e,t,n){"use strict";var r=n(56),o=n(57),i=n(35);e.exports={formats:i,parse:o,stringify:r}},281:function(e,t,n){"use strict";n.r(t),function(e){var t=n(0),r=(n(127),n(11)),o=n(13),i=(n(283),n(119)),a=n(271),c=n(272);n.p=e.wcAdminAssets.path;const s=document.getElementById("root"),l=document.getElementById("woocommerce-embedded-root"),u=Object(o.f)("currentUserData");if(s){let e=Object(r.withSettingsHydration)("wc_admin",window.wcSettings.admin)(i.b);const n=!!window.wcSettings.admin&&window.wcSettings.admin.preloadSettings;n&&n.general&&(e=Object(r.withSettingsHydration)("general",{general:n.general})(e)),u&&(e=Object(r.withCurrentUserHydration)(u)(e)),Object(t.render)(Object(t.createElement)(e,null),s)}else if(l){let e=Object(r.withSettingsHydration)("wc_admin",window.wcSettings.admin)(i.a);u&&(e=Object(r.withCurrentUserHydration)(u)(e)),Object(t.render)(Object(t.createElement)(e,null),l),l.classList.remove("is-embed-loading");const n=document.getElementById("wpbody-content"),o=n.querySelector(".wrap.woocommerce")||n.querySelector(".wrap"),a=document.createElement("div");Object(t.render)(Object(t.createElement)("div",{className:"woocommerce-layout"},Object(t.createElement)(i.c,null)),n.insertBefore(a,o));const s=document.createElement("div");Object(t.render)(Object(t.createElement)(c.a,null),n.insertBefore(s,o.nextSibling))}window.wcAdminFeatures&&!0===window.wcAdminFeatures["customer-effort-score-tracks"]&&function(){const e=s||l;Object(t.render)(Object(t.createElement)(a.a,null),e.insertBefore(document.createElement("div"),null))}()}.call(this,n(79))},283:function(e,t,n){},284:function(e,t){e.exports=window.wc.notices},285:function(e,t,n){},286:function(e,t,n){},287:function(e,t,n){},288:function(e,t,n){},289:function(e,t,n){},29:function(e,t){e.exports=window.wp.htmlEntities},290:function(e,t,n){},291:function(e,t,n){},292:function(e,t,n){},293:function(e,t,n){"use strict";var r=n(0),o=n(8),i=Object(r.createElement)(o.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"},Object(r.createElement)(o.Path,{d:"M14.6 7l-1.2-1L8 12l5.4 6 1.2-1-4.6-5z"}));t.a=i},294:function(e,t){e.exports=function(e,t){if(null==e)return{};var n,r,o={},i=Object.keys(e);for(r=0;r<i.length;r++)n=i[r],t.indexOf(n)>=0||(o[n]=e[n]);return o},e.exports.default=e.exports,e.exports.__esModule=!0},295:function(e,t,n){var r=n(296);e.exports=function(e,t){e.prototype=Object.create(t.prototype),e.prototype.constructor=e,r(e,t)},e.exports.default=e.exports,e.exports.__esModule=!0},296:function(e,t){function n(t,r){return e.exports=n=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e},e.exports.default=e.exports,e.exports.__esModule=!0,n(t,r)}e.exports=n,e.exports.default=e.exports,e.exports.__esModule=!0},297:function(e,t){e.exports=function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e},e.exports.default=e.exports,e.exports.__esModule=!0},298:function(e,t,n){},299:function(e,t){e.exports=Array.isArray||function(e){return"[object Array]"==Object.prototype.toString.call(e)}},3:function(e,t){e.exports=window.wp.components},30:function(e,t){e.exports=window.ReactDOM},300:function(e,t,n){},31:function(e,t){e.exports=window.wp.hooks},35:function(e,t,n){"use strict";var r=String.prototype.replace,o=/%20/g,i="RFC1738",a="RFC3986";e.exports={default:a,formatters:{RFC1738:function(e){return r.call(e,o,"+")},RFC3986:function(e){return String(e)}},RFC1738:i,RFC3986:a}},36:function(e,t){function n(){return e.exports=n=Object.assign||function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},e.exports.default=e.exports,e.exports.__esModule=!0,n.apply(this,arguments)}e.exports=n,e.exports.default=e.exports,e.exports.__esModule=!0},4:function(e,t){e.exports=window.lodash},41:function(e,t,n){"use strict";var r=n(35),o=Object.prototype.hasOwnProperty,i=Array.isArray,a=function(){for(var e=[],t=0;t<256;++t)e.push("%"+((t<16?"0":"")+t.toString(16)).toUpperCase());return e}(),c=function(e,t){for(var n=t&&t.plainObjects?Object.create(null):{},r=0;r<e.length;++r)void 0!==e[r]&&(n[r]=e[r]);return n};e.exports={arrayToObject:c,assign:function(e,t){return Object.keys(t).reduce((function(e,n){return e[n]=t[n],e}),e)},combine:function(e,t){return[].concat(e,t)},compact:function(e){for(var t=[{obj:{o:e},prop:"o"}],n=[],r=0;r<t.length;++r)for(var o=t[r],a=o.obj[o.prop],c=Object.keys(a),s=0;s<c.length;++s){var l=c[s],u=a[l];"object"==typeof u&&null!==u&&-1===n.indexOf(u)&&(t.push({obj:a,prop:l}),n.push(u))}return function(e){for(;e.length>1;){var t=e.pop(),n=t.obj[t.prop];if(i(n)){for(var r=[],o=0;o<n.length;++o)void 0!==n[o]&&r.push(n[o]);t.obj[t.prop]=r}}}(t),e},decode:function(e,t,n){var r=e.replace(/\+/g," ");if("iso-8859-1"===n)return r.replace(/%[0-9a-f]{2}/gi,unescape);try{return decodeURIComponent(r)}catch(e){return r}},encode:function(e,t,n,o,i){if(0===e.length)return e;var c=e;if("symbol"==typeof e?c=Symbol.prototype.toString.call(e):"string"!=typeof e&&(c=String(e)),"iso-8859-1"===n)return escape(c).replace(/%u[0-9a-f]{4}/gi,(function(e){return"%26%23"+parseInt(e.slice(2),16)+"%3B"}));for(var s="",l=0;l<c.length;++l){var u=c.charCodeAt(l);45===u||46===u||95===u||126===u||u>=48&&u<=57||u>=65&&u<=90||u>=97&&u<=122||i===r.RFC1738&&(40===u||41===u)?s+=c.charAt(l):u<128?s+=a[u]:u<2048?s+=a[192|u>>6]+a[128|63&u]:u<55296||u>=57344?s+=a[224|u>>12]+a[128|u>>6&63]+a[128|63&u]:(l+=1,u=65536+((1023&u)<<10|1023&c.charCodeAt(l)),s+=a[240|u>>18]+a[128|u>>12&63]+a[128|u>>6&63]+a[128|63&u])}return s},isBuffer:function(e){return!(!e||"object"!=typeof e)&&!!(e.constructor&&e.constructor.isBuffer&&e.constructor.isBuffer(e))},isRegExp:function(e){return"[object RegExp]"===Object.prototype.toString.call(e)},maybeMap:function(e,t){if(i(e)){for(var n=[],r=0;r<e.length;r+=1)n.push(t(e[r]));return n}return t(e)},merge:function e(t,n,r){if(!n)return t;if("object"!=typeof n){if(i(t))t.push(n);else{if(!t||"object"!=typeof t)return[t,n];(r&&(r.plainObjects||r.allowPrototypes)||!o.call(Object.prototype,n))&&(t[n]=!0)}return t}if(!t||"object"!=typeof t)return[t].concat(n);var a=t;return i(t)&&!i(n)&&(a=c(t,r)),i(t)&&i(n)?(n.forEach((function(n,i){if(o.call(t,i)){var a=t[i];a&&"object"==typeof a&&n&&"object"==typeof n?t[i]=e(a,n,r):t.push(n)}else t[i]=n})),t):Object.keys(n).reduce((function(t,i){var a=n[i];return o.call(t,i)?t[i]=e(t[i],a,r):t[i]=a,t}),a)}}},43:function(e,t,n){"use strict";t.a=function(e,t){if(!e)throw new Error("Invariant failed")}},476:function(e,t){e.exports=window.wc.csvExport},478:function(e,t){e.exports=window.wc.wcSettings},48:function(e,t,n){"use strict";var r=n(49);function o(){}function i(){}i.resetWarningCache=o,e.exports=function(){function e(e,t,n,o,i,a){if(a!==r){var c=new Error("Calling PropTypes validators directly is not supported by the `prop-types` package. Use PropTypes.checkPropTypes() to call them. Read more at http://fb.me/use-check-prop-types");throw c.name="Invariant Violation",c}}function t(){return e}e.isRequired=e;var n={array:e,bool:e,func:e,number:e,object:e,string:e,symbol:e,any:e,arrayOf:t,element:e,elementType:e,instanceOf:t,node:e,objectOf:t,oneOf:t,oneOfType:t,shape:t,exact:t,checkPropTypes:i,resetWarningCache:o};return n.PropTypes=n,n}},49:function(e,t,n){"use strict";e.exports="SECRET_DO_NOT_PASS_THIS_OR_YOU_WILL_BE_FIRED"},499:function(e,t,n){"use strict";var r=n(0),o=n(8),i=Object(r.createElement)(o.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"},Object(r.createElement)(o.Path,{d:"M13 11.8l6.1-6.3-1-1-6.1 6.2-6.1-6.2-1 1 6.1 6.3-6.5 6.7 1 1 6.5-6.6 6.5 6.6 1-1z"}));t.a=i},5:function(e,t){e.exports=window.React},50:function(e,t,n){"use strict";function r(e){return function(){return e}}var o=function(){};o.thatReturns=r,o.thatReturnsFalse=r(!1),o.thatReturnsTrue=r(!0),o.thatReturnsNull=r(null),o.thatReturnsThis=function(){return this},o.thatReturnsArgument=function(e){return e},e.exports=o},500:function(e,t,n){"use strict";var r=n(0),o=n(8),i=Object(r.createElement)(o.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"},Object(r.createElement)(o.Path,{d:"M7 5.5h10a.5.5 0 01.5.5v12a.5.5 0 01-.5.5H7a.5.5 0 01-.5-.5V6a.5.5 0 01.5-.5zM17 4H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V6a2 2 0 00-2-2zm-1 3.75H8v1.5h8v-1.5zM8 11h8v1.5H8V11zm6 3.25H8v1.5h6v-1.5z"}));t.a=i},501:function(e,t,n){"use strict";var r=n(0),o=n(8),i=Object(r.createElement)(o.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"},Object(r.createElement)(o.Path,{fillRule:"evenodd",d:"M5 5.5h14a.5.5 0 01.5.5v1.5a.5.5 0 01-.5.5H5a.5.5 0 01-.5-.5V6a.5.5 0 01.5-.5zM4 9.232A2 2 0 013 7.5V6a2 2 0 012-2h14a2 2 0 012 2v1.5a2 2 0 01-1 1.732V18a2 2 0 01-2 2H6a2 2 0 01-2-2V9.232zm1.5.268V18a.5.5 0 00.5.5h12a.5.5 0 00.5-.5V9.5h-13z",clipRule:"evenodd"}));t.a=i},502:function(e,t,n){"use strict";var r=n(0),o=n(8),i=Object(r.createElement)(o.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"},Object(r.createElement)(o.Path,{d:"M18.2 17c0 .7-.6 1.2-1.2 1.2H7c-.7 0-1.2-.6-1.2-1.2V7c0-.7.6-1.2 1.2-1.2h3.2V4.2H7C5.5 4.2 4.2 5.5 4.2 7v10c0 1.5 1.2 2.8 2.8 2.8h10c1.5 0 2.8-1.2 2.8-2.8v-3.6h-1.5V17zM14.9 3v1.5h3.7l-6.4 6.4 1.1 1.1 6.4-6.4v3.7h1.5V3h-6.3z"}));t.a=i},52:function(e,t,n){"use strict";n.d(t,"a",(function(){return w})),n.d(t,"c",(function(){return j})),n.d(t,"b",(function(){return f})),n.d(t,"e",(function(){return h})),n.d(t,"d",(function(){return p}));var r=n(23);function o(e){return"/"===e.charAt(0)}function i(e,t){for(var n=t,r=n+1,o=e.length;r<o;n+=1,r+=1)e[n]=e[r];e.pop()}var a=function(e,t){void 0===t&&(t="");var n,r=e&&e.split("/")||[],a=t&&t.split("/")||[],c=e&&o(e),s=t&&o(t),l=c||s;if(e&&o(e)?a=r:r.length&&(a.pop(),a=a.concat(r)),!a.length)return"/";if(a.length){var u=a[a.length-1];n="."===u||".."===u||""===u}else n=!1;for(var d=0,m=a.length;m>=0;m--){var p=a[m];"."===p?i(a,m):".."===p?(i(a,m),d++):d&&(i(a,m),d--)}if(!l)for(;d--;d)a.unshift("..");!l||""===a[0]||a[0]&&o(a[0])||a.unshift("");var f=a.join("/");return n&&"/"!==f.substr(-1)&&(f+="/"),f};function c(e){return e.valueOf?e.valueOf():Object.prototype.valueOf.call(e)}var s=function e(t,n){if(t===n)return!0;if(null==t||null==n)return!1;if(Array.isArray(t))return Array.isArray(n)&&t.length===n.length&&t.every((function(t,r){return e(t,n[r])}));if("object"==typeof t||"object"==typeof n){var r=c(t),o=c(n);return r!==t||o!==n?e(r,o):Object.keys(Object.assign({},t,n)).every((function(r){return e(t[r],n[r])}))}return!1},l=n(43);function u(e){return"/"===e.charAt(0)?e:"/"+e}function d(e,t){return function(e,t){return 0===e.toLowerCase().indexOf(t.toLowerCase())&&-1!=="/?#".indexOf(e.charAt(t.length))}(e,t)?e.substr(t.length):e}function m(e){return"/"===e.charAt(e.length-1)?e.slice(0,-1):e}function p(e){var t=e.pathname,n=e.search,r=e.hash,o=t||"/";return n&&"?"!==n&&(o+="?"===n.charAt(0)?n:"?"+n),r&&"#"!==r&&(o+="#"===r.charAt(0)?r:"#"+r),o}function f(e,t,n,o){var i;"string"==typeof e?(i=function(e){var t=e||"/",n="",r="",o=t.indexOf("#");-1!==o&&(r=t.substr(o),t=t.substr(0,o));var i=t.indexOf("?");return-1!==i&&(n=t.substr(i),t=t.substr(0,i)),{pathname:t,search:"?"===n?"":n,hash:"#"===r?"":r}}(e)).state=t:(void 0===(i=Object(r.a)({},e)).pathname&&(i.pathname=""),i.search?"?"!==i.search.charAt(0)&&(i.search="?"+i.search):i.search="",i.hash?"#"!==i.hash.charAt(0)&&(i.hash="#"+i.hash):i.hash="",void 0!==t&&void 0===i.state&&(i.state=t));try{i.pathname=decodeURI(i.pathname)}catch(e){throw e instanceof URIError?new URIError('Pathname "'+i.pathname+'" could not be decoded. This is likely caused by an invalid percent-encoding.'):e}return n&&(i.key=n),o?i.pathname?"/"!==i.pathname.charAt(0)&&(i.pathname=a(i.pathname,o.pathname)):i.pathname=o.pathname:i.pathname||(i.pathname="/"),i}function h(e,t){return e.pathname===t.pathname&&e.search===t.search&&e.hash===t.hash&&e.key===t.key&&s(e.state,t.state)}function b(){var e=null;var t=[];return{setPrompt:function(t){return e=t,function(){e===t&&(e=null)}},confirmTransitionTo:function(t,n,r,o){if(null!=e){var i="function"==typeof e?e(t,n):e;"string"==typeof i?"function"==typeof r?r(i,o):o(!0):o(!1!==i)}else o(!0)},appendListener:function(e){var n=!0;function r(){n&&e.apply(void 0,arguments)}return t.push(r),function(){n=!1,t=t.filter((function(e){return e!==r}))}},notifyListeners:function(){for(var e=arguments.length,n=new Array(e),r=0;r<e;r++)n[r]=arguments[r];t.forEach((function(e){return e.apply(void 0,n)}))}}}var v=!("undefined"==typeof window||!window.document||!window.document.createElement);function g(e,t){t(window.confirm(e))}function y(){try{return window.history.state||{}}catch(e){return{}}}function w(e){void 0===e&&(e={}),v||Object(l.a)(!1);var t,n=window.history,o=(-1===(t=window.navigator.userAgent).indexOf("Android 2.")&&-1===t.indexOf("Android 4.0")||-1===t.indexOf("Mobile Safari")||-1!==t.indexOf("Chrome")||-1!==t.indexOf("Windows Phone"))&&window.history&&"pushState"in window.history,i=!(-1===window.navigator.userAgent.indexOf("Trident")),a=e,c=a.forceRefresh,s=void 0!==c&&c,h=a.getUserConfirmation,w=void 0===h?g:h,O=a.keyLength,j=void 0===O?6:O,_=e.basename?m(u(e.basename)):"";function E(e){var t=e||{},n=t.key,r=t.state,o=window.location,i=o.pathname+o.search+o.hash;return _&&(i=d(i,_)),f(i,r,n)}function k(){return Math.random().toString(36).substr(2,j)}var x=b();function C(e){Object(r.a)(F,e),F.length=n.length,x.notifyListeners(F.location,F.action)}function S(e){(function(e){return void 0===e.state&&-1===navigator.userAgent.indexOf("CriOS")})(e)||P(E(e.state))}function T(){P(E(y()))}var A=!1;function P(e){if(A)A=!1,C();else{x.confirmTransitionTo(e,"POP",w,(function(t){t?C({action:"POP",location:e}):function(e){var t=F.location,n=R.indexOf(t.key);-1===n&&(n=0);var r=R.indexOf(e.key);-1===r&&(r=0);var o=n-r;o&&(A=!0,L(o))}(e)}))}}var N=E(y()),R=[N.key];function M(e){return _+p(e)}function L(e){n.go(e)}var V=0;function I(e){1===(V+=e)&&1===e?(window.addEventListener("popstate",S),i&&window.addEventListener("hashchange",T)):0===V&&(window.removeEventListener("popstate",S),i&&window.removeEventListener("hashchange",T))}var D=!1;var F={length:n.length,action:"POP",location:N,createHref:M,push:function(e,t){var r=f(e,t,k(),F.location);x.confirmTransitionTo(r,"PUSH",w,(function(e){if(e){var t=M(r),i=r.key,a=r.state;if(o)if(n.pushState({key:i,state:a},null,t),s)window.location.href=t;else{var c=R.indexOf(F.location.key),l=R.slice(0,c+1);l.push(r.key),R=l,C({action:"PUSH",location:r})}else window.location.href=t}}))},replace:function(e,t){var r=f(e,t,k(),F.location);x.confirmTransitionTo(r,"REPLACE",w,(function(e){if(e){var t=M(r),i=r.key,a=r.state;if(o)if(n.replaceState({key:i,state:a},null,t),s)window.location.replace(t);else{var c=R.indexOf(F.location.key);-1!==c&&(R[c]=r.key),C({action:"REPLACE",location:r})}else window.location.replace(t)}}))},go:L,goBack:function(){L(-1)},goForward:function(){L(1)},block:function(e){void 0===e&&(e=!1);var t=x.setPrompt(e);return D||(I(1),D=!0),function(){return D&&(D=!1,I(-1)),t()}},listen:function(e){var t=x.appendListener(e);return I(1),function(){I(-1),t()}}};return F}function O(e,t,n){return Math.min(Math.max(e,t),n)}function j(e){void 0===e&&(e={});var t=e,n=t.getUserConfirmation,o=t.initialEntries,i=void 0===o?["/"]:o,a=t.initialIndex,c=void 0===a?0:a,s=t.keyLength,l=void 0===s?6:s,u=b();function d(e){Object(r.a)(w,e),w.length=w.entries.length,u.notifyListeners(w.location,w.action)}function m(){return Math.random().toString(36).substr(2,l)}var h=O(c,0,i.length-1),v=i.map((function(e){return f(e,void 0,"string"==typeof e?m():e.key||m())})),g=p;function y(e){var t=O(w.index+e,0,w.entries.length-1),r=w.entries[t];u.confirmTransitionTo(r,"POP",n,(function(e){e?d({action:"POP",location:r,index:t}):d()}))}var w={length:v.length,action:"POP",location:v[h],index:h,entries:v,createHref:g,push:function(e,t){var r=f(e,t,m(),w.location);u.confirmTransitionTo(r,"PUSH",n,(function(e){if(e){var t=w.index+1,n=w.entries.slice(0);n.length>t?n.splice(t,n.length-t,r):n.push(r),d({action:"PUSH",location:r,index:t,entries:n})}}))},replace:function(e,t){var r=f(e,t,m(),w.location);u.confirmTransitionTo(r,"REPLACE",n,(function(e){e&&(w.entries[w.index]=r,d({action:"REPLACE",location:r}))}))},go:y,goBack:function(){y(-1)},goForward:function(){y(1)},canGo:function(e){var t=w.index+e;return t>=0&&t<w.entries.length},block:function(e){return void 0===e&&(e=!1),u.setPrompt(e)},listen:function(e){return u.appendListener(e)}};return w}},55:function(e,t,n){"use strict";n.d(t,"c",(function(){return r})),n.d(t,"a",(function(){return o})),n.d(t,"b",(function(){return i}));const r="wc/customer-effort-score",o="/wc-admin",i="woocommerce_ces_tracks_queue"},56:function(e,t,n){"use strict";var r=n(41),o=n(35),i=Object.prototype.hasOwnProperty,a={brackets:function(e){return e+"[]"},comma:"comma",indices:function(e,t){return e+"["+t+"]"},repeat:function(e){return e}},c=Array.isArray,s=Array.prototype.push,l=function(e,t){s.apply(e,c(t)?t:[t])},u=Date.prototype.toISOString,d=o.default,m={addQueryPrefix:!1,allowDots:!1,charset:"utf-8",charsetSentinel:!1,delimiter:"&",encode:!0,encoder:r.encode,encodeValuesOnly:!1,format:d,formatter:o.formatters[d],indices:!1,serializeDate:function(e){return u.call(e)},skipNulls:!1,strictNullHandling:!1},p=function e(t,n,o,i,a,s,u,d,p,f,h,b,v,g){var y,w=t;if("function"==typeof u?w=u(n,w):w instanceof Date?w=f(w):"comma"===o&&c(w)&&(w=r.maybeMap(w,(function(e){return e instanceof Date?f(e):e}))),null===w){if(i)return s&&!v?s(n,m.encoder,g,"key",h):n;w=""}if("string"==typeof(y=w)||"number"==typeof y||"boolean"==typeof y||"symbol"==typeof y||"bigint"==typeof y||r.isBuffer(w))return s?[b(v?n:s(n,m.encoder,g,"key",h))+"="+b(s(w,m.encoder,g,"value",h))]:[b(n)+"="+b(String(w))];var O,j=[];if(void 0===w)return j;if("comma"===o&&c(w))O=[{value:w.length>0?w.join(",")||null:void 0}];else if(c(u))O=u;else{var _=Object.keys(w);O=d?_.sort(d):_}for(var E=0;E<O.length;++E){var k=O[E],x="object"==typeof k&&void 0!==k.value?k.value:w[k];if(!a||null!==x){var C=c(w)?"function"==typeof o?o(n,k):n:n+(p?"."+k:"["+k+"]");l(j,e(x,C,o,i,a,s,u,d,p,f,h,b,v,g))}}return j};e.exports=function(e,t){var n,r=e,s=function(e){if(!e)return m;if(null!==e.encoder&&void 0!==e.encoder&&"function"!=typeof e.encoder)throw new TypeError("Encoder has to be a function.");var t=e.charset||m.charset;if(void 0!==e.charset&&"utf-8"!==e.charset&&"iso-8859-1"!==e.charset)throw new TypeError("The charset option must be either utf-8, iso-8859-1, or undefined");var n=o.default;if(void 0!==e.format){if(!i.call(o.formatters,e.format))throw new TypeError("Unknown format option provided.");n=e.format}var r=o.formatters[n],a=m.filter;return("function"==typeof e.filter||c(e.filter))&&(a=e.filter),{addQueryPrefix:"boolean"==typeof e.addQueryPrefix?e.addQueryPrefix:m.addQueryPrefix,allowDots:void 0===e.allowDots?m.allowDots:!!e.allowDots,charset:t,charsetSentinel:"boolean"==typeof e.charsetSentinel?e.charsetSentinel:m.charsetSentinel,delimiter:void 0===e.delimiter?m.delimiter:e.delimiter,encode:"boolean"==typeof e.encode?e.encode:m.encode,encoder:"function"==typeof e.encoder?e.encoder:m.encoder,encodeValuesOnly:"boolean"==typeof e.encodeValuesOnly?e.encodeValuesOnly:m.encodeValuesOnly,filter:a,format:n,formatter:r,serializeDate:"function"==typeof e.serializeDate?e.serializeDate:m.serializeDate,skipNulls:"boolean"==typeof e.skipNulls?e.skipNulls:m.skipNulls,sort:"function"==typeof e.sort?e.sort:null,strictNullHandling:"boolean"==typeof e.strictNullHandling?e.strictNullHandling:m.strictNullHandling}}(t);"function"==typeof s.filter?r=(0,s.filter)("",r):c(s.filter)&&(n=s.filter);var u,d=[];if("object"!=typeof r||null===r)return"";u=t&&t.arrayFormat in a?t.arrayFormat:t&&"indices"in t?t.indices?"indices":"repeat":"indices";var f=a[u];n||(n=Object.keys(r)),s.sort&&n.sort(s.sort);for(var h=0;h<n.length;++h){var b=n[h];s.skipNulls&&null===r[b]||l(d,p(r[b],b,f,s.strictNullHandling,s.skipNulls,s.encode?s.encoder:null,s.filter,s.sort,s.allowDots,s.serializeDate,s.format,s.formatter,s.encodeValuesOnly,s.charset))}var v=d.join(s.delimiter),g=!0===s.addQueryPrefix?"?":"";return s.charsetSentinel&&("iso-8859-1"===s.charset?g+="utf8=%26%2310003%3B&":g+="utf8=%E2%9C%93&"),v.length>0?g+v:""}},57:function(e,t,n){"use strict";var r=n(41),o=Object.prototype.hasOwnProperty,i=Array.isArray,a={allowDots:!1,allowPrototypes:!1,arrayLimit:20,charset:"utf-8",charsetSentinel:!1,comma:!1,decoder:r.decode,delimiter:"&",depth:5,ignoreQueryPrefix:!1,interpretNumericEntities:!1,parameterLimit:1e3,parseArrays:!0,plainObjects:!1,strictNullHandling:!1},c=function(e){return e.replace(/&#(\d+);/g,(function(e,t){return String.fromCharCode(parseInt(t,10))}))},s=function(e,t){return e&&"string"==typeof e&&t.comma&&e.indexOf(",")>-1?e.split(","):e},l=function(e,t,n,r){if(e){var i=n.allowDots?e.replace(/\.([^.[]+)/g,"[$1]"):e,a=/(\[[^[\]]*])/g,c=n.depth>0&&/(\[[^[\]]*])/.exec(i),l=c?i.slice(0,c.index):i,u=[];if(l){if(!n.plainObjects&&o.call(Object.prototype,l)&&!n.allowPrototypes)return;u.push(l)}for(var d=0;n.depth>0&&null!==(c=a.exec(i))&&d<n.depth;){if(d+=1,!n.plainObjects&&o.call(Object.prototype,c[1].slice(1,-1))&&!n.allowPrototypes)return;u.push(c[1])}return c&&u.push("["+i.slice(c.index)+"]"),function(e,t,n,r){for(var o=r?t:s(t,n),i=e.length-1;i>=0;--i){var a,c=e[i];if("[]"===c&&n.parseArrays)a=[].concat(o);else{a=n.plainObjects?Object.create(null):{};var l="["===c.charAt(0)&&"]"===c.charAt(c.length-1)?c.slice(1,-1):c,u=parseInt(l,10);n.parseArrays||""!==l?!isNaN(u)&&c!==l&&String(u)===l&&u>=0&&n.parseArrays&&u<=n.arrayLimit?(a=[])[u]=o:a[l]=o:a={0:o}}o=a}return o}(u,t,n,r)}};e.exports=function(e,t){var n=function(e){if(!e)return a;if(null!==e.decoder&&void 0!==e.decoder&&"function"!=typeof e.decoder)throw new TypeError("Decoder has to be a function.");if(void 0!==e.charset&&"utf-8"!==e.charset&&"iso-8859-1"!==e.charset)throw new TypeError("The charset option must be either utf-8, iso-8859-1, or undefined");var t=void 0===e.charset?a.charset:e.charset;return{allowDots:void 0===e.allowDots?a.allowDots:!!e.allowDots,allowPrototypes:"boolean"==typeof e.allowPrototypes?e.allowPrototypes:a.allowPrototypes,arrayLimit:"number"==typeof e.arrayLimit?e.arrayLimit:a.arrayLimit,charset:t,charsetSentinel:"boolean"==typeof e.charsetSentinel?e.charsetSentinel:a.charsetSentinel,comma:"boolean"==typeof e.comma?e.comma:a.comma,decoder:"function"==typeof e.decoder?e.decoder:a.decoder,delimiter:"string"==typeof e.delimiter||r.isRegExp(e.delimiter)?e.delimiter:a.delimiter,depth:"number"==typeof e.depth||!1===e.depth?+e.depth:a.depth,ignoreQueryPrefix:!0===e.ignoreQueryPrefix,interpretNumericEntities:"boolean"==typeof e.interpretNumericEntities?e.interpretNumericEntities:a.interpretNumericEntities,parameterLimit:"number"==typeof e.parameterLimit?e.parameterLimit:a.parameterLimit,parseArrays:!1!==e.parseArrays,plainObjects:"boolean"==typeof e.plainObjects?e.plainObjects:a.plainObjects,strictNullHandling:"boolean"==typeof e.strictNullHandling?e.strictNullHandling:a.strictNullHandling}}(t);if(""===e||null==e)return n.plainObjects?Object.create(null):{};for(var u="string"==typeof e?function(e,t){var n,l={},u=t.ignoreQueryPrefix?e.replace(/^\?/,""):e,d=t.parameterLimit===1/0?void 0:t.parameterLimit,m=u.split(t.delimiter,d),p=-1,f=t.charset;if(t.charsetSentinel)for(n=0;n<m.length;++n)0===m[n].indexOf("utf8=")&&("utf8=%E2%9C%93"===m[n]?f="utf-8":"utf8=%26%2310003%3B"===m[n]&&(f="iso-8859-1"),p=n,n=m.length);for(n=0;n<m.length;++n)if(n!==p){var h,b,v=m[n],g=v.indexOf("]="),y=-1===g?v.indexOf("="):g+1;-1===y?(h=t.decoder(v,a.decoder,f,"key"),b=t.strictNullHandling?null:""):(h=t.decoder(v.slice(0,y),a.decoder,f,"key"),b=r.maybeMap(s(v.slice(y+1),t),(function(e){return t.decoder(e,a.decoder,f,"value")}))),b&&t.interpretNumericEntities&&"iso-8859-1"===f&&(b=c(b)),v.indexOf("[]=")>-1&&(b=i(b)?[b]:b),o.call(l,h)?l[h]=r.combine(l[h],b):l[h]=b}return l}(e,n):e,d=n.plainObjects?Object.create(null):{},m=Object.keys(u),p=0;p<m.length;++p){var f=m[p],h=l(f,u[f],n,"string"==typeof e);d=r.merge(d,h,n)}return r.compact(d)}},6:function(e,t,n){!function(){"use strict";var t={}.hasOwnProperty;function n(){for(var e=[],r=0;r<arguments.length;r++){var o=arguments[r];if(o){var i=typeof o;if("string"===i||"number"===i)e.push(o);else if(Array.isArray(o)){if(o.length){var a=n.apply(null,o);a&&e.push(a)}}else if("object"===i)if(o.toString===Object.prototype.toString)for(var c in o)t.call(o,c)&&o[c]&&e.push(c);else e.push(o.toString())}}return e.join(" ")}e.exports?(n.default=n,e.exports=n):"function"==typeof define&&"object"==typeof define.amd&&define.amd?define("classnames",[],(function(){return n})):window.classNames=n}()},61:function(e,t){e.exports=window.wp.date},62:function(e,t,n){"use strict";n.d(t,"b",(function(){return a})),n.d(t,"c",(function(){return c})),n.d(t,"e",(function(){return s})),n.d(t,"a",(function(){return l})),n.d(t,"d",(function(){return d})),n.d(t,"f",(function(){return m}));var r=n(29),o=n(4),i=n(13);function a(e){return e?e.split(":")[0]:null}function c(e){let t=a(e);return Object(o.without)(Object(i.f)("onboarding",{euCountries:[]}).euCountries,"GB").includes(t)&&(t="EU"),t}function s(e,t,n=!1,r){return u(t,n,r,e).map(e=>e.id||e.product)}function l(e,t,n){const r={};r.products=u(t,!0,n,e),r.remainingProducts=u(t,!1,n,e);const o=[...new Set([...r.products,...r.remainingProducts])];return r.uniqueItemsList=o.map(e=>{let t;return t=e.label?{type:"extension",name:e.label}:{type:"theme",name:e.title},t}),r}function u(e,t=!1,n,r){const o=[];if(!r)return o;(e.product_types||[]).forEach(e=>{r[e]&&r[e].product&&(t||!n.includes(r[e].slug))&&o.push(r[e])});const a=Object(i.f)("onboarding",{});let c=null;return a&&a.themes&&(c=a.themes.find(t=>t.slug===e.theme)),c&&c.id&&d(c.price)>0&&(t||!c.is_installed)&&o.push(c),o}function d(e){return Number(Object(r.decodeEntities)(e).replace(/[^0-9.-]+/g,""))}function m(e){return/admin.php\?page=wc-admin/.test(e)}},68:function(e,t,n){"use strict";n.d(t,"d",(function(){return i})),n.d(t,"c",(function(){return a})),n.d(t,"b",(function(){return c})),n.d(t,"a",(function(){return s}));var r=n(11),o=n(256);function i(e,t){const{getItemsTotalCount:n,getItemsError:o,isResolving:i}=e(r.ITEMS_STORE_NAME);if(!t.length)return 0;const a={page:1,per_page:1,status:t,_fields:["id"]},c=n("orders",a,null),s=Boolean(o("orders",a)),l=i("getItemsTotalCount",["orders",a,null]);return s||l?null:c}function a(e){const{getSetting:t}=e(r.SETTINGS_STORE_NAME),{woocommerce_actionable_order_statuses:n=o.a}=t("wc_admin","wcAdminSettings",{});return n}const c={page:1,per_page:1,low_in_stock:!0,status:"publish",_fields:["id"]};function s(e){const{getItemsTotalCount:t,getItemsError:n,isResolving:o}=e(r.ITEMS_STORE_NAME),i=t("products/low-in-stock",c,null),a=Boolean(n("products/low-in-stock",c)),s=o("getItemsTotalCount",["products/low-in-stock",c,null]);return a||s&&null===i?null:i}},69:function(e,t,n){"use strict";var r=n(5),o="function"==typeof Symbol&&Symbol.for&&Symbol.for("react.element")||60103,i=n(50),a=n(70),c=n(71),s="function"==typeof Symbol&&Symbol.iterator;function l(e,t){return e&&"object"==typeof e&&null!=e.key?(n=e.key,r={"=":"=0",":":"=2"},"$"+(""+n).replace(/[=:]/g,(function(e){return r[e]}))):t.toString(36);var n,r}function u(e,t,n,r){var i,c=typeof e;if("undefined"!==c&&"boolean"!==c||(e=null),null===e||"string"===c||"number"===c||"object"===c&&e.$$typeof===o)return n(r,e,""===t?"."+l(e,0):t),1;var d=0,m=""===t?".":t+":";if(Array.isArray(e))for(var p=0;p<e.length;p++)d+=u(i=e[p],m+l(i,p),n,r);else{var f=function(e){var t=e&&(s&&e[s]||e["@@iterator"]);if("function"==typeof t)return t}(e);if(f){0;for(var h,b=f.call(e),v=0;!(h=b.next()).done;)d+=u(i=h.value,m+l(i,v++),n,r)}else if("object"===c){0;var g=""+e;a(!1,"Objects are not valid as a React child (found: %s).%s","[object Object]"===g?"object with keys {"+Object.keys(e).join(", ")+"}":g,"")}}return d}var d=/\/+/g;function m(e){return(""+e).replace(d,"$&/")}var p,f,h=b,b=function(e){if(this.instancePool.length){var t=this.instancePool.pop();return this.call(t,e),t}return new this(e)},v=function(e){a(e instanceof this,"Trying to release an instance into a pool of a different type."),e.destructor(),this.instancePool.length<this.poolSize&&this.instancePool.push(e)};function g(e,t,n,r){this.result=e,this.keyPrefix=t,this.func=n,this.context=r,this.count=0}function y(e,t,n){var o,a,c=e.result,s=e.keyPrefix,l=e.func,u=e.context,d=l.call(u,t,e.count++);Array.isArray(d)?w(d,c,n,i.thatReturnsArgument):null!=d&&(r.isValidElement(d)&&(o=d,a=s+(!d.key||t&&t.key===d.key?"":m(d.key)+"/")+n,d=r.cloneElement(o,{key:a},void 0!==o.props?o.props.children:void 0)),c.push(d))}function w(e,t,n,r,o){var i="";null!=n&&(i=m(n)+"/");var a=g.getPooled(t,i,r,o);!function(e,t,n){null==e||u(e,"",t,n)}(e,y,a),g.release(a)}g.prototype.destructor=function(){this.result=null,this.keyPrefix=null,this.func=null,this.context=null,this.count=0},p=function(e,t,n,r){if(this.instancePool.length){var o=this.instancePool.pop();return this.call(o,e,t,n,r),o}return new this(e,t,n,r)},(f=g).instancePool=[],f.getPooled=p||h,f.poolSize||(f.poolSize=10),f.release=v;e.exports=function(e){if("object"!=typeof e||!e||Array.isArray(e))return c(!1,"React.addons.createFragment only accepts a single object. Got: %s",e),e;if(r.isValidElement(e))return c(!1,"React.addons.createFragment does not accept a ReactElement without a wrapper object."),e;a(1!==e.nodeType,"React.addons.createFragment(...): Encountered an invalid child; DOM elements are not valid children of React components.");var t=[];for(var n in e)w(e[n],t,n,i.thatReturnsArgument);return t}},7:function(e,t){e.exports=window.wp.data},70:function(e,t,n){"use strict";e.exports=function(e,t,n,r,o,i,a,c){if(!e){var s;if(void 0===t)s=new Error("Minified exception occurred; use the non-minified dev environment for the full error message and additional helpful warnings.");else{var l=[n,r,o,i,a,c],u=0;(s=new Error(t.replace(/%s/g,(function(){return l[u++]})))).name="Invariant Violation"}throw s.framesToPop=1,s}}},71:function(e,t,n){"use strict";var r=n(50);e.exports=r},72:function(e,t,n){"use strict";function r(e){return e.match(/^\{\{\//)?{type:"componentClose",value:e.replace(/\W/g,"")}:e.match(/\/\}\}$/)?{type:"componentSelfClosing",value:e.replace(/\W/g,"")}:e.match(/^\{\{/)?{type:"componentOpen",value:e.replace(/\W/g,"")}:{type:"string",value:e}}e.exports=function(e){return e.split(/(\{\{\/?\s*\w+\s*\/?\}\})/g).map(r)}},76:function(e,t){e.exports=window.wp.plugins},79:function(e,t){var n;n=function(){return this}();try{n=n||new Function("return this")()}catch(e){"object"==typeof window&&(n=window)}e.exports=n},8:function(e,t){e.exports=window.wp.primitives},89:function(e,t){e.exports=window.wc.currency},9:function(e,t){e.exports=window.moment},91:function(e,t){e.exports=window.wp.dom}});
|
trunk/dist/app/style-rtl.css
ADDED
@@ -0,0 +1 @@
|
|
|
1 |
+
.woocommerce-page .wrap{margin:0}.woocommerce-page #wpcontent,.woocommerce-page.woocommerce_page_wc-admin #wpbody-content{padding:0;overflow-x:hidden!important;min-height:calc(100vh - 32px)}@media(min-width:783px){.woocommerce-page #wpbody-content{padding-right:0}}@media(max-width:782px){.woocommerce-page .wp-responsive-open #woocommerce-embedded-root,.woocommerce-page .wp-responsive-open #wpbody{position:relative;left:-14.5em}.woocommerce-page #wpbody-content,.woocommerce-page #wpcontent{min-height:calc(100vh - 46px)}}@media(min-width:961px){.woocommerce-page #toplevel_page_wcadmin--analytics.menu-top>a:focus,.woocommerce-page #toplevel_page_woocommerce.menu-top>a:focus{padding-bottom:1px}}#wpbody,.woocommerce-layout *{box-sizing:border-box}#wpbody{display:inline-block;width:100%;padding-top:0;margin-top:60px}#wpfooter{display:none}.woocommerce_page_wc-admin .woocommerce-filters-date__content:not(.is-mobile){z-index:2}@media(max-width:600px){#wpadminbar{position:fixed}html.wp-toolbar{padding-top:46px}}@media(max-width:782px){.jetpack-masterbar #wpadminbar #wp-admin-bar-menu-toggle{margin-top:-10px}.jetpack-masterbar #wpwrap .woocommerce-layout__header-heading{padding-right:60px}.jetpack-masterbar.wp-admin .wrap h1,.jetpack-masterbar.wp-admin .wrap h2{padding-right:0}}.woocommerce-page .wp-has-current-submenu:after{left:0;content:" ";height:0;width:0;position:absolute;pointer-events:none;border:8px solid transparent;border-left-color:#f1f1f1;top:0;margin-top:10px}@media(max-width:960px){.woocommerce-page .wp-has-current-submenu:after{border-width:4px;margin-top:14px}}:root{--large-gap:40px;--main-gap:24px}@media(max-width:960px){:root{--large-gap:24px}}@media(max-width:782px){:root{--large-gap:16px;--main-gap:16px}}@keyframes loading-fade{0%{opacity:.7}50%{opacity:1}to{opacity:.7}}.woocommerce-layout select:hover{color:#1e1e1e}.woocommerce-layout select.components-select-control__input{max-width:100%;line-height:1}body.woocommerce-page .components-button.is-primary:not(:disabled),body.woocommerce-page .components-snackbar .components-button.is-tertiary,body.woocommerce-page .components-snackbar .components-button.is-tertiary:not(:disabled):not([aria-disabled=true]):hover{color:#fff}.woocommerce-embed-page #wpbody .woocommerce-layout,.woocommerce-embed-page .woocommerce-layout__notice-list-hide+.wrap{padding-top:10px}.woocommerce-embed-page #wpbody-content,.woocommerce-embed-page #wpcontent{overflow-x:initial!important}.woocommerce-embed-page #wpbody-content{padding-top:0}.woocommerce-embed-page #wpbody-content .notice{margin-top:15px}.woocommerce-embed-page .wrap{padding:0 20px}@media(max-width:782px){.woocommerce-embed-page .wrap p.search-box{width:calc(100% - 40px)}}.woocommerce-embed-page .wrap .wrap{padding:0}.woocommerce-embed-page #screen-meta{border-left:0;margin:0}.woocommerce-embed-page #screen-meta-links{position:relative}.woocommerce-embed-page .notice{padding:1px 12px}.woocommerce-embed-page .woocommerce-layout__header.is-scrolled{box-shadow:0 8px 16px 0 rgba(85,93,102,.3)}.woocommerce-embed-page .woocommerce-layout__header .woocommerce-layout__header-heading{margin-top:0;margin-bottom:0}.woocommerce-embed-page #screen-meta-links.is-hidden-by-notices,.woocommerce-embed-page #screen-meta.is-hidden-by-notices{display:none!important}.woocommerce-embed-page .woocommerce-layout__primary{margin:0}@media(max-width:782px){.woocommerce-embed-page .woocommerce-layout__primary{padding-top:10px}}@keyframes isLoaded{0%{opacity:0}to{opacity:1}}.woocommerce-embed-page .woocommerce-layout__activity-panel-tabs{animation:isLoaded;animation-duration:2s}.woocommerce-embed-page .woocommerce-layout__notice-list-show{margin-top:10px;margin-bottom:16px}@media(max-width:600px){.woocommerce-embed-page .woocommerce-layout__notice-list-show{margin-top:80px;margin-bottom:-16px}}@media(min-width:601px)and (max-width:782px){.woocommerce-embed-page .woocommerce-layout__notice-list-show{margin-top:32px}}.woocommerce-embed-page .woocommerce-activity-card__actions a.components-button:not(.is-primary){color:#757575}.woocommerce-layout{margin:0;padding:0}.woocommerce-layout__no-match{display:flex;align-items:center;justify-content:center}.woocommerce-layout__no-match .components-card{max-width:680px;width:100%}.woocommerce-layout__primary{margin:var(--large-gap) var(--large-gap) 0 0}@media(max-width:782px){.woocommerce-layout__primary{margin-top:20px}}.woocommerce-layout .woocommerce-layout__main{padding-left:40px;padding-left:var(--large-gap);max-width:100%}.woocommerce-admin-is-loading #adminmenumain,.woocommerce-admin-is-loading #wpadminbar,.woocommerce-admin-is-loading #wpbody-content,.woocommerce-admin-is-loading #wpcontent,.woocommerce-admin-is-loading #wpfooter,.woocommerce-admin-is-loading .components-modal__screen-overlay,.woocommerce-admin-is-loading .error,.woocommerce-admin-is-loading .notice,.woocommerce-admin-is-loading .update-nag,.woocommerce-admin-is-loading .updated,.woocommerce-admin-is-loading .woocommerce-layout__header,.woocommerce-admin-is-loading .woocommerce-message,.woocommerce-admin-is-loading .woocommerce-store-alerts,.woocommerce-page .update-nag{display:none}.woocommerce-admin-full-screen{background:#f6f7f7;color:#50575e;font-family:-apple-system,BlinkMacSystemFont,Segoe UI,Roboto,Oxygen-Sans,Ubuntu,Cantarell,Helvetica Neue,sans-serif}.woocommerce-admin-full-screen #wpwrap{top:0}.woocommerce-admin-full-screen #wpbody-content{min-height:100vh!important}.woocommerce-admin-full-screen #adminmenumain,.woocommerce-admin-full-screen #wpcontent>*,.woocommerce-admin-full-screen .error,.woocommerce-admin-full-screen .notice,.woocommerce-admin-full-screen .update-nag,.woocommerce-admin-full-screen .updated,.woocommerce-admin-full-screen .woocommerce-layout__header,.woocommerce-admin-full-screen .woocommerce-message,.woocommerce-admin-full-screen .woocommerce-store-alerts{display:none}.woocommerce-admin-full-screen #wpcontent{margin-right:0!important}.woocommerce-admin-full-screen #wpcontent>#wpbody{display:block;margin-top:0!important}.woocommerce-admin-full-screen.has-woocommerce-navigation #wpbody{padding-right:0}.is-wp-toolbar-disabled #wpadminbar{display:none!important}.wp-toolbar .is-wp-toolbar-disabled{margin-top:-32px}@media(max-width:600px){.wp-toolbar .is-wp-toolbar-disabled{margin-top:-46px}}.woocommerce-page .components-modal__frame .components-button.is-button,.woocommerce-profile-wizard__body .components-button.is-button,.woocommerce-task-dashboard__container .components-button.is-button{height:48px;padding-right:25px;padding-left:25px;text-align:center;font-size:14px;line-height:36px;font-weight:500;align-items:center}.woocommerce-page .components-modal__frame .components-button.is-button:disabled,.woocommerce-profile-wizard__body .components-button.is-button:disabled,.woocommerce-task-dashboard__container .components-button.is-button:disabled{cursor:not-allowed}.components-modal__header .components-button svg+span{display:none}.components-modal__frame.woocommerce-usage-modal{width:600px;max-width:100%}.components-modal__frame.woocommerce-usage-modal .components-modal__header{border-bottom:0;margin-bottom:0}.components-modal__frame.woocommerce-usage-modal .woocommerce-usage-modal__wrapper{flex-grow:1;display:flex;flex-direction:column}.components-modal__frame.woocommerce-usage-modal .woocommerce-usage-modal__wrapper a{color:#50575e}.components-modal__frame.woocommerce-usage-modal .woocommerce-usage-modal__wrapper button.is-primary{align-self:flex-end}.components-modal__frame.woocommerce-usage-modal .woocommerce-usage-modal__actions{display:flex;justify-content:flex-end;margin-top:16px}.components-modal__frame.woocommerce-usage-modal .woocommerce-usage-modal__actions button{margin-right:16px}.woocommerce-payments__usage-modal .components-modal__header{height:auto;padding:24px 24px 0}.woocommerce-payments__usage-modal .components-modal__header .components-modal__header-heading{font-size:24px;line-height:32px;margin:0 0 24px}.woocommerce-payments__usage-modal .woocommerce-payments__usage-modal-message{padding:16px 0;font-size:16px;line-height:24px}.woocommerce-payments__usage-modal .woocommerce-payments__usage-footer{display:flex;justify-content:flex-end;padding:16px 0}.woocommerce-payments__usage-modal .woocommerce-payments__usage-footer button{margin-right:16px}.components-modal__frame.woocommerce-cart-modal{width:600px;max-width:100%}.components-modal__frame.woocommerce-cart-modal .components-modal__header{border-bottom:0;margin-bottom:16px;margin-top:16px}.components-modal__frame.woocommerce-cart-modal .components-modal__header button{display:none}.components-modal__frame.woocommerce-cart-modal .components-modal__header-heading{font-style:normal;font-weight:400;font-size:24px;line-height:32px}.components-modal__frame.woocommerce-cart-modal .woocommerce-list{margin-top:24px}.components-modal__frame.woocommerce-cart-modal .woocommerce-list .woocommerce-list__item:first-child{border-top:1px solid #dcdcde}.components-modal__frame.woocommerce-cart-modal .woocommerce-list__item{border-bottom:1px solid #dcdcde}.components-modal__frame.woocommerce-cart-modal .woocommerce-cart-modal__help-text{font-size:16px;line-height:24px}.components-modal__frame.woocommerce-cart-modal .woocommerce-cart-modal__actions{text-align:left}.components-modal__frame.woocommerce-cart-modal .woocommerce-cart-modal__actions button.is-link{margin-left:16px;text-decoration:none;font-weight:600;font-size:14px}.components-modal__frame.woocommerce-cart-modal .woocommerce-cart-modal__actions button.is-primary{align-self:flex-end}.woocommerce-layout__header{background:#fff;box-sizing:border-box;padding:0;position:fixed;width:calc(100% - 160px);top:32px;z-index:1001}.woocommerce-layout__header.is-scrolled{box-shadow:0 8px 8px 0 rgba(85,93,102,.3)}.woocommerce-layout__header .woocommerce-layout__header-wrapper{display:flex;align-items:center;min-height:60px}.woocommerce-layout__header .woocommerce-layout__header-back-button{cursor:pointer;margin-right:var(--large-gap);display:flex}.woocommerce-layout__header .woocommerce-layout__header-back-button:focus{box-shadow:inset 1px -1px 0 #757575,inset -1px 1px 0 #757575}@media(max-width:782px){.woocommerce-layout__header{flex-flow:row wrap;top:46px;width:100%}}@media(min-width:783px)and (max-width:960px){.woocommerce-layout__header{width:calc(100% - 36px)}}.woocommerce-layout__header .woocommerce-layout__header-breadcrumbs-wrapper{display:flex;justify-content:space-between;flex-direction:row}.woocommerce-layout__header .woocommerce-layout__header-heading{display:flex;align-items:center;padding:0 40px 0 0;padding:0 var(--large-gap) 0 0;flex:1 auto;height:60px;background:#fff;font-weight:600;font-size:14px}.woocommerce-layout__header .woocommerce-layout__header-heading.with-back-button{padding-right:24px}.folded .woocommerce-layout__header{width:calc(100% - 36px)}@media(max-width:782px){.folded .woocommerce-layout__header{width:100%}}.is-wp-toolbar-disabled .woocommerce-layout__header{top:0}.has-woocommerce-navigation .woocommerce-layout__header{right:0;width:100%}.woocommerce-page #contextual-help-link-wrap,.woocommerce-page #screen-options-link-wrap{margin-top:-1px}.wp-responsive-open .woocommerce-layout__header{margin-right:2px}.woocommerce-layout__activity-panel{display:flex;flex-direction:row;align-items:center;height:60px}.woocommerce-layout__activity-panel-tabs{width:100%;display:flex;height:60px;justify-content:flex-end}.woocommerce-layout__activity-panel-tabs .dashicon,.woocommerce-layout__activity-panel-tabs .gridicon{width:100%}.woocommerce-layout__activity-panel-tabs svg{width:24px;height:24px}.woocommerce-layout__activity-panel-tabs svg.woocommerce-layout__activity-panel-tab-icon{fill:none}.woocommerce-layout__activity-panel-tabs svg.woocommerce-layout__activity-panel-tab-icon path,.woocommerce-layout__activity-panel-tabs svg.woocommerce-layout__activity-panel-tab-icon rect{stroke:currentColor}.woocommerce-layout__activity-panel-tabs svg.setup-progress path:first-child{stroke:"#DCDCDE"}.woocommerce-layout__activity-panel-tabs .woocommerce-layout__homescreen-display-options svg.woocommerce-layout__activity-panel-tab-icon{height:14px}.woocommerce-layout__activity-panel-tabs .woocommerce-layout__homescreen-extension-tasklist-toggle{min-width:205px}.woocommerce-layout__activity-panel-tabs .components-icon-button{display:initial;text-indent:0;border-radius:0}.woocommerce-layout__activity-panel-tabs .components-icon-button.has-text svg{margin:0}.woocommerce-layout__activity-panel-tabs .woocommerce-layout__activity-panel-tab{display:flex;flex-direction:column;justify-content:center;align-items:center;position:relative;border:none;outline:none;cursor:pointer;background-color:#fff;max-width:min-content;min-width:80px;width:100%;height:60px;color:#757575;white-space:nowrap}.woocommerce-layout__activity-panel-tabs .woocommerce-layout__activity-panel-tab:before{background-color:#007cba;background-color:var(--wp-admin-theme-color);bottom:0;content:"";height:0;opacity:0;transition-property:height,opacity;transition-duration:.3s;transition-timing-function:ease-in-out;right:0;position:absolute;left:0}.woocommerce-layout__activity-panel-tabs .woocommerce-layout__activity-panel-tab.is-active,.woocommerce-layout__activity-panel-tabs .woocommerce-layout__activity-panel-tab.is-opened{color:#1e1e1e;box-shadow:none}.woocommerce-layout__activity-panel-tabs .woocommerce-layout__activity-panel-tab.is-active:before,.woocommerce-layout__activity-panel-tabs .woocommerce-layout__activity-panel-tab.is-opened:before{height:3px;opacity:1}.woocommerce-layout__activity-panel-tabs .woocommerce-layout__activity-panel-tab.has-unread:after,.woocommerce-layout__activity-panel-tabs .woocommerce-layout__activity-panel-tab.woocommerce-layout__activity-panel-tab-wordpress-notices:after{content:" ";position:absolute;padding:1px;background:#d94f4f;border:2px solid #fff;width:4px;height:4px;display:inline-block;border-radius:50%;top:8px;right:50%}@media(min-width:783px)and (max-width:960px){.woocommerce-layout__activity-panel-tabs .woocommerce-layout__activity-panel-tab.has-unread:after,.woocommerce-layout__activity-panel-tabs .woocommerce-layout__activity-panel-tab.woocommerce-layout__activity-panel-tab-wordpress-notices:after{left:18px;right:auto;margin-right:0}}@media(min-width:961px){.woocommerce-layout__activity-panel-tabs .woocommerce-layout__activity-panel-tab.has-unread:after,.woocommerce-layout__activity-panel-tabs .woocommerce-layout__activity-panel-tab.woocommerce-layout__activity-panel-tab-wordpress-notices:after{left:28px;right:auto;margin-right:0}}.woocommerce-layout__activity-panel-tabs .woocommerce-layout__activity-panel-tab.components-button:not(:disabled):not([aria-disabled=true]):hover,.woocommerce-layout__activity-panel-tabs .woocommerce-layout__activity-panel-tab:hover{background-color:#f0f0f0;box-shadow:none}.woocommerce-layout__activity-panel-tabs .woocommerce-layout__activity-panel-tab.components-button:not(:disabled):not([aria-disabled=true]):hover.has-unread:after,.woocommerce-layout__activity-panel-tabs .woocommerce-layout__activity-panel-tab.components-button:not(:disabled):not([aria-disabled=true]):hover.woocommerce-layout__activity-panel-tab-wordpress-notices:after,.woocommerce-layout__activity-panel-tabs .woocommerce-layout__activity-panel-tab:hover.has-unread:after,.woocommerce-layout__activity-panel-tabs .woocommerce-layout__activity-panel-tab:hover.woocommerce-layout__activity-panel-tab-wordpress-notices:after{border-color:#e0e0e0}.woocommerce-layout__activity-panel-tabs .woocommerce-layout__activity-panel-tab.components-button:not(:disabled):not([aria-disabled=true]):focus,.woocommerce-layout__activity-panel-tabs .woocommerce-layout__activity-panel-tab:focus{box-shadow:inset 1px -1px 0 #757575,inset -1px 1px 0 #757575}@media(max-width:782px){.woocommerce-layout__activity-panel-tabs .woocommerce-layout__activity-panel-tab.display-options{display:none}}.woocommerce-layout__activity-panel-tabs .woocommerce-layout__activity-panel-popover{margin-top:0;z-index:1001}.woocommerce-layout__activity-panel-tabs .woocommerce-layout__activity-panel-popover .components-menu-group{padding:12px}.woocommerce-layout__activity-panel-toggle-bubble.has-unread:after{content:" ";position:absolute;padding:1px;background:#ca4a1f;border:2px solid #fff;width:4px;height:4px;display:inline-block;border-radius:50%;top:6px;left:4px}@keyframes tabSwitch{0%,to{transform:translateX(0)}50%{transform:translateX(-100px)}}.woocommerce-layout__activity-panel-wrapper{height:calc(100vh - 106px);background:#f0f0f0;width:430px;transform:translateX(-100%);transition-property:transform box-shadow;transition-duration:.3s;transition-timing-function:ease-in-out;position:fixed;left:0;top:106px;z-index:1000;overflow-x:hidden;overflow-y:auto}@media(max-width:782px){.woocommerce-layout__activity-panel-wrapper{width:100%}}@media screen and (prefers-reduced-motion:reduce){.woocommerce-layout__activity-panel-wrapper{transition-duration:1ms}}@media(min-width:783px){.woocommerce-layout__activity-panel-wrapper{height:calc(100vh - 92px);top:92px}}.has-woocommerce-navigation .woocommerce-layout__activity-panel-wrapper{height:calc(100vh - 60px);top:60px}.woocommerce-layout__activity-panel-wrapper.is-open{transform:none;box-shadow:0 12px 12px 0 rgba(85,93,102,.3)}.woocommerce-layout__activity-panel-wrapper.is-switching{animation:tabSwitch;animation-duration:.3s}@media screen and (prefers-reduced-motion:reduce){.woocommerce-layout__activity-panel-wrapper.is-switching{animation:none}}.woocommerce-layout__activity-panel-wrapper .woocommerce-empty-content{padding-right:24px;padding-left:24px}.woocommerce-layout__activity-panel-avatar-flag-overlay{position:relative;top:-12px}.woocommerce-layout__activity-panel-avatar-flag-overlay .woocommerce-flag{position:relative;top:16px;border:2px solid #fff}.woocommerce-layout__notice-list-hide{display:none}.highlight-tooltip__container{position:absolute;width:0;height:0}.highlight-tooltip__container.highlight-tooltip__show{top:0;right:0;width:100%;height:100%}.highlight-tooltip__portal{width:100%;height:100%;position:relative}.highlight-tooltip__portal .highlight-tooltip__overlay{position:fixed;top:0;left:0;bottom:0;right:0;background-color:rgba(0,0,0,.35);z-index:100000;animation:edit-post__fade-in-animation .2s ease-out 0s;animation-fill-mode:forwards}@media(prefers-reduced-motion:reduce){.highlight-tooltip__portal .highlight-tooltip__overlay{animation-duration:1ms}}.highlight-tooltip__popover .components-card{min-width:360px}.highlight-tooltip__popover .components-card__header{font-size:16px;font-size:1rem;font-weight:600;box-sizing:border-box}.highlight-tooltip__popover .components-card__footer{justify-content:flex-end;box-sizing:border-box}.woocommerce-layout__show-app-banner{padding-top:56px}@media(min-width:783px){.woocommerce-layout__show-app-banner{padding-top:0}}.woocommerce-mobile-app-banner{background-color:#3c2861;width:100%;display:flex;height:56px;align-items:center;padding:0 4px 0 6px}@media(min-width:401px){.woocommerce-mobile-app-banner{padding:0 10px 0 13px}}@media(min-width:783px){.woocommerce-mobile-app-banner{display:none}}.woocommerce-mobile-app-banner .gridicon{fill:#fff;margin-left:10px}.woocommerce-mobile-app-banner .components-button.is-secondary{margin-right:auto;color:#fff;box-shadow:inset 0 0 0 1px #fff}.woocommerce-mobile-app-banner .components-button.is-secondary:active,.woocommerce-mobile-app-banner .components-button.is-secondary:hover{color:#fff;box-shadow:inset 0 0 0 1px #fff;background:none}.woocommerce-mobile-app-banner .woocommerce-mobile-app-banner__description{color:#fff;margin-right:8px}@media(min-width:401px){.woocommerce-mobile-app-banner .woocommerce-mobile-app-banner__description{margin-right:13px}}.woocommerce-mobile-app-banner .woocommerce-mobile-app-banner__description .woocommerce-mobile-app-banner__description__text{margin:0;font-size:10px}.woocommerce-mobile-app-banner .woocommerce-mobile-app-banner__description .woocommerce-mobile-app-banner__description__text:first-child{font-weight:700}@media(min-width:401px){.woocommerce-mobile-app-banner .woocommerce-mobile-app-banner__description .woocommerce-mobile-app-banner__description__text{margin-right:13px;font-size:13px}}.woocommerce-navigation{display:grid;grid-template-rows:min-content 1fr;height:100%}.woocommerce-navigation .woocommerce-navigation__wrapper h2>span{width:100%}.woocommerce-navigation .woocommerce-navigation__wrapper .components-navigation__menu{overflow-y:auto;margin-bottom:0;padding-bottom:24px}.woocommerce-navigation .woocommerce-navigation__wrapper .components-navigation__group+.components-navigation__group{margin-top:24px}.woocommerce-navigation .woocommerce-navigation__wrapper .components-navigation__item{margin-bottom:0}.woocommerce-navigation .woocommerce-navigation__wrapper .components-navigation__item .components-button{opacity:1}.woocommerce-navigation .woocommerce-navigation__wrapper .components-navigation__item:not(:hover) .components-button{color:#ccc}.woocommerce-navigation .woocommerce-navigation__wrapper .components-navigation__item.is-active .components-button,.woocommerce-navigation .woocommerce-navigation__wrapper .components-navigation__item:hover .components-button{color:#fff}.woocommerce-navigation .woocommerce-navigation__wrapper .components-navigation__item a.components-button{padding:6px 16px}.woocommerce-navigation .woocommerce-navigation__wrapper .components-navigation__item:not(:hover) a.components-button{color:#ccc}.woocommerce-navigation .woocommerce-navigation__wrapper .components-navigation__item.is-active a.components-button{color:#fff}.woocommerce-navigation .woocommerce-navigation__wrapper .components-navigation{height:100%}.woocommerce-navigation .woocommerce-navigation__wrapper .components-navigation>div{height:100%;display:grid;grid-template-rows:1fr min-content}.woocommerce-navigation .woocommerce-navigation__wrapper.is-root .components-navigation__menu-secondary{border-top:1px solid #2c3338;margin:0 -8px;padding:16px 8px 12px}.woocommerce-navigation .woocommerce-navigation__wrapper .components-navigation__group-title,.woocommerce-navigation .woocommerce-navigation__wrapper .components-navigation__menu-title{color:#f0f0f0;opacity:1}.woocommerce-navigation .woocommerce-navigation__wrapper .components-navigation__back-button{color:#ccc;opacity:1}.woocommerce-navigation .woocommerce-navigation__wrapper .components-navigation__back-button,.woocommerce-navigation .woocommerce-navigation__wrapper .components-navigation__back-button span{font-size:13px;line-height:normal}.woocommerce-navigation .woocommerce-navigation__wrapper .components-navigation__back-button:hover,.woocommerce-navigation .woocommerce-navigation__wrapper .components-navigation__back-button:hover:not(:disabled){color:#ddd}.woocommerce-navigation-header{display:flex;align-items:center;border:none;border-radius:0;height:auto}.woocommerce-navigation-header .woocommerce-navigation-header__site-icon.components-button{padding:12px;height:60px;color:#fff}.woocommerce-navigation-header .woocommerce-navigation-header__site-icon.components-button:focus,.woocommerce-navigation-header .woocommerce-navigation-header__site-icon.components-button:hover,.woocommerce-navigation-header .woocommerce-navigation-header__site-icon.components-button:not([aria-disabled=true]):active{color:#fff}.woocommerce-navigation-header .woocommerce-navigation-header__site-title.components-button{padding-right:0;color:#ccc;font-weight:600}.woocommerce-navigation-header .woocommerce-navigation-header__site-title.components-button:active,.woocommerce-navigation-header .woocommerce-navigation-header__site-title.components-button:focus,.woocommerce-navigation-header .woocommerce-navigation-header__site-title.components-button:hover{color:#e0e0e0}.woocommerce-navigation{position:relative;width:240px;box-sizing:border-box;background-color:#1e1e1e;z-index:1100}@media(max-width:960px){.woocommerce-navigation{width:60px;height:60px}}.woocommerce-navigation .components-navigation{box-sizing:border-box}.woocommerce-navigation .components-navigation__menu-title{overflow:visible}.woocommerce-navigation__wrapper{background-color:#1e1e1e;position:absolute;top:60px;width:100%;height:calc(100vh - 92px);overflow-y:auto}.is-wp-toolbar-disabled .woocommerce-navigation__wrapper{height:calc(100vh - 60px)}body.is-wc-nav-expanded .woocommerce-navigation{width:240px;height:100%}body.is-wc-nav-expanded font>.xdebug-error{margin-right:256px}body.is-wc-nav-folded .woocommerce-navigation{width:60px;height:60px;overflow:hidden}body.is-wc-nav-folded .woocommerce-navigation .woocommerce-navigation-header>*{display:none}body.is-wc-nav-folded .woocommerce-navigation .woocommerce-navigation-header__site-icon{display:block}body.is-wc-nav-folded .woocommerce-navigation .components-navigation{display:none}body.is-wc-nav-folded .woocommerce-transient-notices{right:16px}body.is-wc-nav-folded #wpbody{padding-right:0}.has-woocommerce-navigation #adminmenuback,.has-woocommerce-navigation #adminmenuwrap{display:none!important}.has-woocommerce-navigation.woocommerce_page_wc-reports .woo-nav-tab-wrapper,.has-woocommerce-navigation.woocommerce_page_wc-settings .woo-nav-tab-wrapper,.has-woocommerce-navigation.woocommerce_page_wc-status .woo-nav-tab-wrapper{display:none}.has-woocommerce-navigation.woocommerce_page_wc-reports .woocommerce .subsubsub,.has-woocommerce-navigation.woocommerce_page_wc-settings .woocommerce .subsubsub,.has-woocommerce-navigation.woocommerce_page_wc-status .woocommerce .subsubsub{font-size:14px;margin:5px 0}.has-woocommerce-navigation #wpcontent,.has-woocommerce-navigation #wpfooter{margin-right:0}@media(max-width:960px){.has-woocommerce-navigation #wpcontent,.has-woocommerce-navigation #wpfooter{margin-right:0}}.has-woocommerce-navigation #wpbody{padding-right:240px}@media(max-width:960px){.has-woocommerce-navigation #wpbody{padding-right:0}}.has-woocommerce-navigation .woocommerce-layout__header.is-embed-loading:before{content:"";position:fixed;width:240px;height:100%;background:#1e1e1e}@media(max-width:960px){.has-woocommerce-navigation .woocommerce-layout__header.is-embed-loading:before{width:60px;height:60px}}.has-woocommerce-navigation #woocommerce-embedded-root.is-embed-loading{margin-bottom:-32px}.has-woocommerce-navigation:not(.is-wp-toolbar-disabled) #wpbody-content{margin-top:32px}.has-woocommerce-navigation font>.xdebug-error{margin-top:60px}.woocommerce-navigation-category-title{display:flex;align-items:center;font-size:20px;line-height:28px}.woocommerce-navigation-category-title .woocommerce-navigation-favorite-button{margin-right:auto}.woocommerce-navigation-favorite-button.components-button .star-empty-icon{color:#949494}.woocommerce-navigation-favorite-button.components-button .star-filled-icon{color:#ffb900}.woocommerce-transient-notices{position:fixed;bottom:12px;right:176px;z-index:99999;width:auto}@media(max-width:960px){.woocommerce-transient-notices{right:50px}}@media(max-width:782px){.woocommerce-transient-notices{right:16px}}.woocommerce-profile-wizard__body .woocommerce-transient-notices{right:unset}.woocommerce-profile-wizard__body .woocommerce-transient-notices .components-snackbar{margin-right:auto;margin-left:auto}.has-woocommerce-navigation .woocommerce-transient-notices{right:256px}.components-snackbar.components-snackbar-explicit-dismiss{cursor:default}.components-snackbar .components-snackbar__content-with-icon{margin-right:32px}.components-snackbar .components-snackbar__icon{position:absolute;top:24px;right:26px}.components-snackbar .components-snackbar__dismiss-button{margin-right:32px;cursor:pointer}:root{--wp-admin-theme-color:#007cba;--wp-admin-theme-color-darker-10:#006ba1;--wp-admin-theme-color-darker-20:#005a87}body.admin-color-light{--wp-admin-theme-color:#0085ba;--wp-admin-theme-color-darker-10:#0073a1;--wp-admin-theme-color-darker-20:#006187}body.admin-color-modern{--wp-admin-theme-color:#3858e9;--wp-admin-theme-color-darker-10:#2145e6;--wp-admin-theme-color-darker-20:#183ad6}body.admin-color-blue{--wp-admin-theme-color:#096484;--wp-admin-theme-color-darker-10:#07526c;--wp-admin-theme-color-darker-20:#064054}body.admin-color-coffee{--wp-admin-theme-color:#46403c;--wp-admin-theme-color-darker-10:#383330;--wp-admin-theme-color-darker-20:#2b2724}body.admin-color-ectoplasm{--wp-admin-theme-color:#523f6d;--wp-admin-theme-color-darker-10:#46365d;--wp-admin-theme-color-darker-20:#3a2c4d}body.admin-color-midnight{--wp-admin-theme-color:#e14d43;--wp-admin-theme-color-darker-10:#dd382d;--wp-admin-theme-color-darker-20:#d02c21}body.admin-color-ocean{--wp-admin-theme-color:#627c83;--wp-admin-theme-color-darker-10:#576e74;--wp-admin-theme-color-darker-20:#4c6066}body.admin-color-sunrise{--wp-admin-theme-color:#dd823b;--wp-admin-theme-color-darker-10:#d97426;--wp-admin-theme-color-darker-20:#c36922}.woocommerce-embedded-layout__primary{padding:0 20px}.woocommerce-embedded-layout__primary .components-card__footer,.woocommerce-embedded-layout__primary .components-card__header{box-sizing:border-box}@media(max-width:782px){.woocommerce-embedded-layout__primary{padding:0}}
|
trunk/dist/app/style.css
ADDED
@@ -0,0 +1 @@
|
|
|
1 |
+
.woocommerce-page .wrap{margin:0}.woocommerce-page #wpcontent,.woocommerce-page.woocommerce_page_wc-admin #wpbody-content{padding:0;overflow-x:hidden!important;min-height:calc(100vh - 32px)}@media(min-width:783px){.woocommerce-page #wpbody-content{padding-left:0}}@media(max-width:782px){.woocommerce-page .wp-responsive-open #woocommerce-embedded-root,.woocommerce-page .wp-responsive-open #wpbody{position:relative;right:-14.5em}.woocommerce-page #wpbody-content,.woocommerce-page #wpcontent{min-height:calc(100vh - 46px)}}@media(min-width:961px){.woocommerce-page #toplevel_page_wcadmin--analytics.menu-top>a:focus,.woocommerce-page #toplevel_page_woocommerce.menu-top>a:focus{padding-bottom:1px}}#wpbody,.woocommerce-layout *{box-sizing:border-box}#wpbody{display:inline-block;width:100%;padding-top:0;margin-top:60px}#wpfooter{display:none}.woocommerce_page_wc-admin .woocommerce-filters-date__content:not(.is-mobile){z-index:2}@media(max-width:600px){#wpadminbar{position:fixed}html.wp-toolbar{padding-top:46px}}@media(max-width:782px){.jetpack-masterbar #wpadminbar #wp-admin-bar-menu-toggle{margin-top:-10px}.jetpack-masterbar #wpwrap .woocommerce-layout__header-heading{padding-left:60px}.jetpack-masterbar.wp-admin .wrap h1,.jetpack-masterbar.wp-admin .wrap h2{padding-left:0}}.woocommerce-page .wp-has-current-submenu:after{right:0;content:" ";height:0;width:0;position:absolute;pointer-events:none;border:8px solid transparent;border-right-color:#f1f1f1;top:0;margin-top:10px}@media(max-width:960px){.woocommerce-page .wp-has-current-submenu:after{border-width:4px;margin-top:14px}}:root{--large-gap:40px;--main-gap:24px}@media(max-width:960px){:root{--large-gap:24px}}@media(max-width:782px){:root{--large-gap:16px;--main-gap:16px}}@keyframes loading-fade{0%{opacity:.7}50%{opacity:1}to{opacity:.7}}.woocommerce-layout select:hover{color:#1e1e1e}.woocommerce-layout select.components-select-control__input{max-width:100%;line-height:1}body.woocommerce-page .components-button.is-primary:not(:disabled),body.woocommerce-page .components-snackbar .components-button.is-tertiary,body.woocommerce-page .components-snackbar .components-button.is-tertiary:not(:disabled):not([aria-disabled=true]):hover{color:#fff}.woocommerce-embed-page #wpbody .woocommerce-layout,.woocommerce-embed-page .woocommerce-layout__notice-list-hide+.wrap{padding-top:10px}.woocommerce-embed-page #wpbody-content,.woocommerce-embed-page #wpcontent{overflow-x:initial!important}.woocommerce-embed-page #wpbody-content{padding-top:0}.woocommerce-embed-page #wpbody-content .notice{margin-top:15px}.woocommerce-embed-page .wrap{padding:0 20px}@media(max-width:782px){.woocommerce-embed-page .wrap p.search-box{width:calc(100% - 40px)}}.woocommerce-embed-page .wrap .wrap{padding:0}.woocommerce-embed-page #screen-meta{border-right:0;margin:0}.woocommerce-embed-page #screen-meta-links{position:relative}.woocommerce-embed-page .notice{padding:1px 12px}.woocommerce-embed-page .woocommerce-layout__header.is-scrolled{box-shadow:0 8px 16px 0 rgba(85,93,102,.3)}.woocommerce-embed-page .woocommerce-layout__header .woocommerce-layout__header-heading{margin-top:0;margin-bottom:0}.woocommerce-embed-page #screen-meta-links.is-hidden-by-notices,.woocommerce-embed-page #screen-meta.is-hidden-by-notices{display:none!important}.woocommerce-embed-page .woocommerce-layout__primary{margin:0}@media(max-width:782px){.woocommerce-embed-page .woocommerce-layout__primary{padding-top:10px}}@keyframes isLoaded{0%{opacity:0}to{opacity:1}}.woocommerce-embed-page .woocommerce-layout__activity-panel-tabs{animation:isLoaded;animation-duration:2s}.woocommerce-embed-page .woocommerce-layout__notice-list-show{margin-top:10px;margin-bottom:16px}@media(max-width:600px){.woocommerce-embed-page .woocommerce-layout__notice-list-show{margin-top:80px;margin-bottom:-16px}}@media(min-width:601px)and (max-width:782px){.woocommerce-embed-page .woocommerce-layout__notice-list-show{margin-top:32px}}.woocommerce-embed-page .woocommerce-activity-card__actions a.components-button:not(.is-primary){color:#757575}.woocommerce-layout{margin:0;padding:0}.woocommerce-layout__no-match{display:flex;align-items:center;justify-content:center}.woocommerce-layout__no-match .components-card{max-width:680px;width:100%}.woocommerce-layout__primary{margin:var(--large-gap) 0 0 var(--large-gap)}@media(max-width:782px){.woocommerce-layout__primary{margin-top:20px}}.woocommerce-layout .woocommerce-layout__main{padding-right:40px;padding-right:var(--large-gap);max-width:100%}.woocommerce-admin-is-loading #adminmenumain,.woocommerce-admin-is-loading #wpadminbar,.woocommerce-admin-is-loading #wpbody-content,.woocommerce-admin-is-loading #wpcontent,.woocommerce-admin-is-loading #wpfooter,.woocommerce-admin-is-loading .components-modal__screen-overlay,.woocommerce-admin-is-loading .error,.woocommerce-admin-is-loading .notice,.woocommerce-admin-is-loading .update-nag,.woocommerce-admin-is-loading .updated,.woocommerce-admin-is-loading .woocommerce-layout__header,.woocommerce-admin-is-loading .woocommerce-message,.woocommerce-admin-is-loading .woocommerce-store-alerts,.woocommerce-page .update-nag{display:none}.woocommerce-admin-full-screen{background:#f6f7f7;color:#50575e;font-family:-apple-system,BlinkMacSystemFont,Segoe UI,Roboto,Oxygen-Sans,Ubuntu,Cantarell,Helvetica Neue,sans-serif}.woocommerce-admin-full-screen #wpwrap{top:0}.woocommerce-admin-full-screen #wpbody-content{min-height:100vh!important}.woocommerce-admin-full-screen #adminmenumain,.woocommerce-admin-full-screen #wpcontent>*,.woocommerce-admin-full-screen .error,.woocommerce-admin-full-screen .notice,.woocommerce-admin-full-screen .update-nag,.woocommerce-admin-full-screen .updated,.woocommerce-admin-full-screen .woocommerce-layout__header,.woocommerce-admin-full-screen .woocommerce-message,.woocommerce-admin-full-screen .woocommerce-store-alerts{display:none}.woocommerce-admin-full-screen #wpcontent{margin-left:0!important}.woocommerce-admin-full-screen #wpcontent>#wpbody{display:block;margin-top:0!important}.woocommerce-admin-full-screen.has-woocommerce-navigation #wpbody{padding-left:0}.is-wp-toolbar-disabled #wpadminbar{display:none!important}.wp-toolbar .is-wp-toolbar-disabled{margin-top:-32px}@media(max-width:600px){.wp-toolbar .is-wp-toolbar-disabled{margin-top:-46px}}.woocommerce-page .components-modal__frame .components-button.is-button,.woocommerce-profile-wizard__body .components-button.is-button,.woocommerce-task-dashboard__container .components-button.is-button{height:48px;padding-left:25px;padding-right:25px;text-align:center;font-size:14px;line-height:36px;font-weight:500;align-items:center}.woocommerce-page .components-modal__frame .components-button.is-button:disabled,.woocommerce-profile-wizard__body .components-button.is-button:disabled,.woocommerce-task-dashboard__container .components-button.is-button:disabled{cursor:not-allowed}.components-modal__header .components-button svg+span{display:none}.components-modal__frame.woocommerce-usage-modal{width:600px;max-width:100%}.components-modal__frame.woocommerce-usage-modal .components-modal__header{border-bottom:0;margin-bottom:0}.components-modal__frame.woocommerce-usage-modal .woocommerce-usage-modal__wrapper{flex-grow:1;display:flex;flex-direction:column}.components-modal__frame.woocommerce-usage-modal .woocommerce-usage-modal__wrapper a{color:#50575e}.components-modal__frame.woocommerce-usage-modal .woocommerce-usage-modal__wrapper button.is-primary{align-self:flex-end}.components-modal__frame.woocommerce-usage-modal .woocommerce-usage-modal__actions{display:flex;justify-content:flex-end;margin-top:16px}.components-modal__frame.woocommerce-usage-modal .woocommerce-usage-modal__actions button{margin-left:16px}.woocommerce-payments__usage-modal .components-modal__header{height:auto;padding:24px 24px 0}.woocommerce-payments__usage-modal .components-modal__header .components-modal__header-heading{font-size:24px;line-height:32px;margin:0 0 24px}.woocommerce-payments__usage-modal .woocommerce-payments__usage-modal-message{padding:16px 0;font-size:16px;line-height:24px}.woocommerce-payments__usage-modal .woocommerce-payments__usage-footer{display:flex;justify-content:flex-end;padding:16px 0}.woocommerce-payments__usage-modal .woocommerce-payments__usage-footer button{margin-left:16px}.components-modal__frame.woocommerce-cart-modal{width:600px;max-width:100%}.components-modal__frame.woocommerce-cart-modal .components-modal__header{border-bottom:0;margin-bottom:16px;margin-top:16px}.components-modal__frame.woocommerce-cart-modal .components-modal__header button{display:none}.components-modal__frame.woocommerce-cart-modal .components-modal__header-heading{font-style:normal;font-weight:400;font-size:24px;line-height:32px}.components-modal__frame.woocommerce-cart-modal .woocommerce-list{margin-top:24px}.components-modal__frame.woocommerce-cart-modal .woocommerce-list .woocommerce-list__item:first-child{border-top:1px solid #dcdcde}.components-modal__frame.woocommerce-cart-modal .woocommerce-list__item{border-bottom:1px solid #dcdcde}.components-modal__frame.woocommerce-cart-modal .woocommerce-cart-modal__help-text{font-size:16px;line-height:24px}.components-modal__frame.woocommerce-cart-modal .woocommerce-cart-modal__actions{text-align:right}.components-modal__frame.woocommerce-cart-modal .woocommerce-cart-modal__actions button.is-link{margin-right:16px;text-decoration:none;font-weight:600;font-size:14px}.components-modal__frame.woocommerce-cart-modal .woocommerce-cart-modal__actions button.is-primary{align-self:flex-end}.woocommerce-layout__header{background:#fff;box-sizing:border-box;padding:0;position:fixed;width:calc(100% - 160px);top:32px;z-index:1001}.woocommerce-layout__header.is-scrolled{box-shadow:0 8px 8px 0 rgba(85,93,102,.3)}.woocommerce-layout__header .woocommerce-layout__header-wrapper{display:flex;align-items:center;min-height:60px}.woocommerce-layout__header .woocommerce-layout__header-back-button{cursor:pointer;margin-left:var(--large-gap);display:flex}.woocommerce-layout__header .woocommerce-layout__header-back-button:focus{box-shadow:inset -1px -1px 0 #757575,inset 1px 1px 0 #757575}@media(max-width:782px){.woocommerce-layout__header{flex-flow:row wrap;top:46px;width:100%}}@media(min-width:783px)and (max-width:960px){.woocommerce-layout__header{width:calc(100% - 36px)}}.woocommerce-layout__header .woocommerce-layout__header-breadcrumbs-wrapper{display:flex;justify-content:space-between;flex-direction:row}.woocommerce-layout__header .woocommerce-layout__header-heading{display:flex;align-items:center;padding:0 0 0 40px;padding:0 0 0 var(--large-gap);flex:1 auto;height:60px;background:#fff;font-weight:600;font-size:14px}.woocommerce-layout__header .woocommerce-layout__header-heading.with-back-button{padding-left:24px}.folded .woocommerce-layout__header{width:calc(100% - 36px)}@media(max-width:782px){.folded .woocommerce-layout__header{width:100%}}.is-wp-toolbar-disabled .woocommerce-layout__header{top:0}.has-woocommerce-navigation .woocommerce-layout__header{left:0;width:100%}.woocommerce-page #contextual-help-link-wrap,.woocommerce-page #screen-options-link-wrap{margin-top:-1px}.wp-responsive-open .woocommerce-layout__header{margin-left:2px}.woocommerce-layout__activity-panel{display:flex;flex-direction:row;align-items:center;height:60px}.woocommerce-layout__activity-panel-tabs{width:100%;display:flex;height:60px;justify-content:flex-end}.woocommerce-layout__activity-panel-tabs .dashicon,.woocommerce-layout__activity-panel-tabs .gridicon{width:100%}.woocommerce-layout__activity-panel-tabs svg{width:24px;height:24px}.woocommerce-layout__activity-panel-tabs svg.woocommerce-layout__activity-panel-tab-icon{fill:none}.woocommerce-layout__activity-panel-tabs svg.woocommerce-layout__activity-panel-tab-icon path,.woocommerce-layout__activity-panel-tabs svg.woocommerce-layout__activity-panel-tab-icon rect{stroke:currentColor}.woocommerce-layout__activity-panel-tabs svg.setup-progress path:first-child{stroke:"#DCDCDE"}.woocommerce-layout__activity-panel-tabs .woocommerce-layout__homescreen-display-options svg.woocommerce-layout__activity-panel-tab-icon{height:14px}.woocommerce-layout__activity-panel-tabs .woocommerce-layout__homescreen-extension-tasklist-toggle{min-width:205px}.woocommerce-layout__activity-panel-tabs .components-icon-button{display:initial;text-indent:0;border-radius:0}.woocommerce-layout__activity-panel-tabs .components-icon-button.has-text svg{margin:0}.woocommerce-layout__activity-panel-tabs .woocommerce-layout__activity-panel-tab{display:flex;flex-direction:column;justify-content:center;align-items:center;position:relative;border:none;outline:none;cursor:pointer;background-color:#fff;max-width:min-content;min-width:80px;width:100%;height:60px;color:#757575;white-space:nowrap}.woocommerce-layout__activity-panel-tabs .woocommerce-layout__activity-panel-tab:before{background-color:#007cba;background-color:var(--wp-admin-theme-color);bottom:0;content:"";height:0;opacity:0;transition-property:height,opacity;transition-duration:.3s;transition-timing-function:ease-in-out;left:0;position:absolute;right:0}.woocommerce-layout__activity-panel-tabs .woocommerce-layout__activity-panel-tab.is-active,.woocommerce-layout__activity-panel-tabs .woocommerce-layout__activity-panel-tab.is-opened{color:#1e1e1e;box-shadow:none}.woocommerce-layout__activity-panel-tabs .woocommerce-layout__activity-panel-tab.is-active:before,.woocommerce-layout__activity-panel-tabs .woocommerce-layout__activity-panel-tab.is-opened:before{height:3px;opacity:1}.woocommerce-layout__activity-panel-tabs .woocommerce-layout__activity-panel-tab.has-unread:after,.woocommerce-layout__activity-panel-tabs .woocommerce-layout__activity-panel-tab.woocommerce-layout__activity-panel-tab-wordpress-notices:after{content:" ";position:absolute;padding:1px;background:#d94f4f;border:2px solid #fff;width:4px;height:4px;display:inline-block;border-radius:50%;top:8px;left:50%}@media(min-width:783px)and (max-width:960px){.woocommerce-layout__activity-panel-tabs .woocommerce-layout__activity-panel-tab.has-unread:after,.woocommerce-layout__activity-panel-tabs .woocommerce-layout__activity-panel-tab.woocommerce-layout__activity-panel-tab-wordpress-notices:after{right:18px;left:auto;margin-left:0}}@media(min-width:961px){.woocommerce-layout__activity-panel-tabs .woocommerce-layout__activity-panel-tab.has-unread:after,.woocommerce-layout__activity-panel-tabs .woocommerce-layout__activity-panel-tab.woocommerce-layout__activity-panel-tab-wordpress-notices:after{right:28px;left:auto;margin-left:0}}.woocommerce-layout__activity-panel-tabs .woocommerce-layout__activity-panel-tab.components-button:not(:disabled):not([aria-disabled=true]):hover,.woocommerce-layout__activity-panel-tabs .woocommerce-layout__activity-panel-tab:hover{background-color:#f0f0f0;box-shadow:none}.woocommerce-layout__activity-panel-tabs .woocommerce-layout__activity-panel-tab.components-button:not(:disabled):not([aria-disabled=true]):hover.has-unread:after,.woocommerce-layout__activity-panel-tabs .woocommerce-layout__activity-panel-tab.components-button:not(:disabled):not([aria-disabled=true]):hover.woocommerce-layout__activity-panel-tab-wordpress-notices:after,.woocommerce-layout__activity-panel-tabs .woocommerce-layout__activity-panel-tab:hover.has-unread:after,.woocommerce-layout__activity-panel-tabs .woocommerce-layout__activity-panel-tab:hover.woocommerce-layout__activity-panel-tab-wordpress-notices:after{border-color:#e0e0e0}.woocommerce-layout__activity-panel-tabs .woocommerce-layout__activity-panel-tab.components-button:not(:disabled):not([aria-disabled=true]):focus,.woocommerce-layout__activity-panel-tabs .woocommerce-layout__activity-panel-tab:focus{box-shadow:inset -1px -1px 0 #757575,inset 1px 1px 0 #757575}@media(max-width:782px){.woocommerce-layout__activity-panel-tabs .woocommerce-layout__activity-panel-tab.display-options{display:none}}.woocommerce-layout__activity-panel-tabs .woocommerce-layout__activity-panel-popover{margin-top:0;z-index:1001}.woocommerce-layout__activity-panel-tabs .woocommerce-layout__activity-panel-popover .components-menu-group{padding:12px}.woocommerce-layout__activity-panel-toggle-bubble.has-unread:after{content:" ";position:absolute;padding:1px;background:#ca4a1f;border:2px solid #fff;width:4px;height:4px;display:inline-block;border-radius:50%;top:6px;right:4px}@keyframes tabSwitch{0%,to{transform:translateX(0)}50%{transform:translateX(100px)}}.woocommerce-layout__activity-panel-wrapper{height:calc(100vh - 106px);background:#f0f0f0;width:430px;transform:translateX(100%);transition-property:transform box-shadow;transition-duration:.3s;transition-timing-function:ease-in-out;position:fixed;right:0;top:106px;z-index:1000;overflow-x:hidden;overflow-y:auto}@media(max-width:782px){.woocommerce-layout__activity-panel-wrapper{width:100%}}@media screen and (prefers-reduced-motion:reduce){.woocommerce-layout__activity-panel-wrapper{transition-duration:1ms}}@media(min-width:783px){.woocommerce-layout__activity-panel-wrapper{height:calc(100vh - 92px);top:92px}}.has-woocommerce-navigation .woocommerce-layout__activity-panel-wrapper{height:calc(100vh - 60px);top:60px}.woocommerce-layout__activity-panel-wrapper.is-open{transform:none;box-shadow:0 12px 12px 0 rgba(85,93,102,.3)}.woocommerce-layout__activity-panel-wrapper.is-switching{animation:tabSwitch;animation-duration:.3s}@media screen and (prefers-reduced-motion:reduce){.woocommerce-layout__activity-panel-wrapper.is-switching{animation:none}}.woocommerce-layout__activity-panel-wrapper .woocommerce-empty-content{padding-left:24px;padding-right:24px}.woocommerce-layout__activity-panel-avatar-flag-overlay{position:relative;top:-12px}.woocommerce-layout__activity-panel-avatar-flag-overlay .woocommerce-flag{position:relative;top:16px;border:2px solid #fff}.woocommerce-layout__notice-list-hide{display:none}.highlight-tooltip__container{position:absolute;width:0;height:0}.highlight-tooltip__container.highlight-tooltip__show{top:0;left:0;width:100%;height:100%}.highlight-tooltip__portal{width:100%;height:100%;position:relative}.highlight-tooltip__portal .highlight-tooltip__overlay{position:fixed;top:0;right:0;bottom:0;left:0;background-color:rgba(0,0,0,.35);z-index:100000;animation:edit-post__fade-in-animation .2s ease-out 0s;animation-fill-mode:forwards}@media(prefers-reduced-motion:reduce){.highlight-tooltip__portal .highlight-tooltip__overlay{animation-duration:1ms}}.highlight-tooltip__popover .components-card{min-width:360px}.highlight-tooltip__popover .components-card__header{font-size:16px;font-size:1rem;font-weight:600;box-sizing:border-box}.highlight-tooltip__popover .components-card__footer{justify-content:flex-end;box-sizing:border-box}.woocommerce-layout__show-app-banner{padding-top:56px}@media(min-width:783px){.woocommerce-layout__show-app-banner{padding-top:0}}.woocommerce-mobile-app-banner{background-color:#3c2861;width:100%;display:flex;height:56px;align-items:center;padding:0 6px 0 4px}@media(min-width:401px){.woocommerce-mobile-app-banner{padding:0 13px 0 10px}}@media(min-width:783px){.woocommerce-mobile-app-banner{display:none}}.woocommerce-mobile-app-banner .gridicon{fill:#fff;margin-right:10px}.woocommerce-mobile-app-banner .components-button.is-secondary{margin-left:auto;color:#fff;box-shadow:inset 0 0 0 1px #fff}.woocommerce-mobile-app-banner .components-button.is-secondary:active,.woocommerce-mobile-app-banner .components-button.is-secondary:hover{color:#fff;box-shadow:inset 0 0 0 1px #fff;background:none}.woocommerce-mobile-app-banner .woocommerce-mobile-app-banner__description{color:#fff;margin-left:8px}@media(min-width:401px){.woocommerce-mobile-app-banner .woocommerce-mobile-app-banner__description{margin-left:13px}}.woocommerce-mobile-app-banner .woocommerce-mobile-app-banner__description .woocommerce-mobile-app-banner__description__text{margin:0;font-size:10px}.woocommerce-mobile-app-banner .woocommerce-mobile-app-banner__description .woocommerce-mobile-app-banner__description__text:first-child{font-weight:700}@media(min-width:401px){.woocommerce-mobile-app-banner .woocommerce-mobile-app-banner__description .woocommerce-mobile-app-banner__description__text{margin-left:13px;font-size:13px}}.woocommerce-navigation{display:grid;grid-template-rows:min-content 1fr;height:100%}.woocommerce-navigation .woocommerce-navigation__wrapper h2>span{width:100%}.woocommerce-navigation .woocommerce-navigation__wrapper .components-navigation__menu{overflow-y:auto;margin-bottom:0;padding-bottom:24px}.woocommerce-navigation .woocommerce-navigation__wrapper .components-navigation__group+.components-navigation__group{margin-top:24px}.woocommerce-navigation .woocommerce-navigation__wrapper .components-navigation__item{margin-bottom:0}.woocommerce-navigation .woocommerce-navigation__wrapper .components-navigation__item .components-button{opacity:1}.woocommerce-navigation .woocommerce-navigation__wrapper .components-navigation__item:not(:hover) .components-button{color:#ccc}.woocommerce-navigation .woocommerce-navigation__wrapper .components-navigation__item.is-active .components-button,.woocommerce-navigation .woocommerce-navigation__wrapper .components-navigation__item:hover .components-button{color:#fff}.woocommerce-navigation .woocommerce-navigation__wrapper .components-navigation__item a.components-button{padding:6px 16px}.woocommerce-navigation .woocommerce-navigation__wrapper .components-navigation__item:not(:hover) a.components-button{color:#ccc}.woocommerce-navigation .woocommerce-navigation__wrapper .components-navigation__item.is-active a.components-button{color:#fff}.woocommerce-navigation .woocommerce-navigation__wrapper .components-navigation{height:100%}.woocommerce-navigation .woocommerce-navigation__wrapper .components-navigation>div{height:100%;display:grid;grid-template-rows:1fr min-content}.woocommerce-navigation .woocommerce-navigation__wrapper.is-root .components-navigation__menu-secondary{border-top:1px solid #2c3338;margin:0 -8px;padding:16px 8px 12px}.woocommerce-navigation .woocommerce-navigation__wrapper .components-navigation__group-title,.woocommerce-navigation .woocommerce-navigation__wrapper .components-navigation__menu-title{color:#f0f0f0;opacity:1}.woocommerce-navigation .woocommerce-navigation__wrapper .components-navigation__back-button{color:#ccc;opacity:1}.woocommerce-navigation .woocommerce-navigation__wrapper .components-navigation__back-button,.woocommerce-navigation .woocommerce-navigation__wrapper .components-navigation__back-button span{font-size:13px;line-height:normal}.woocommerce-navigation .woocommerce-navigation__wrapper .components-navigation__back-button:hover,.woocommerce-navigation .woocommerce-navigation__wrapper .components-navigation__back-button:hover:not(:disabled){color:#ddd}.woocommerce-navigation-header{display:flex;align-items:center;border:none;border-radius:0;height:auto}.woocommerce-navigation-header .woocommerce-navigation-header__site-icon.components-button{padding:12px;height:60px;color:#fff}.woocommerce-navigation-header .woocommerce-navigation-header__site-icon.components-button:focus,.woocommerce-navigation-header .woocommerce-navigation-header__site-icon.components-button:hover,.woocommerce-navigation-header .woocommerce-navigation-header__site-icon.components-button:not([aria-disabled=true]):active{color:#fff}.woocommerce-navigation-header .woocommerce-navigation-header__site-title.components-button{padding-left:0;color:#ccc;font-weight:600}.woocommerce-navigation-header .woocommerce-navigation-header__site-title.components-button:active,.woocommerce-navigation-header .woocommerce-navigation-header__site-title.components-button:focus,.woocommerce-navigation-header .woocommerce-navigation-header__site-title.components-button:hover{color:#e0e0e0}.woocommerce-navigation{position:relative;width:240px;box-sizing:border-box;background-color:#1e1e1e;z-index:1100}@media(max-width:960px){.woocommerce-navigation{width:60px;height:60px}}.woocommerce-navigation .components-navigation{box-sizing:border-box}.woocommerce-navigation .components-navigation__menu-title{overflow:visible}.woocommerce-navigation__wrapper{background-color:#1e1e1e;position:absolute;top:60px;width:100%;height:calc(100vh - 92px);overflow-y:auto}.is-wp-toolbar-disabled .woocommerce-navigation__wrapper{height:calc(100vh - 60px)}body.is-wc-nav-expanded .woocommerce-navigation{width:240px;height:100%}body.is-wc-nav-expanded font>.xdebug-error{margin-left:256px}body.is-wc-nav-folded .woocommerce-navigation{width:60px;height:60px;overflow:hidden}body.is-wc-nav-folded .woocommerce-navigation .woocommerce-navigation-header>*{display:none}body.is-wc-nav-folded .woocommerce-navigation .woocommerce-navigation-header__site-icon{display:block}body.is-wc-nav-folded .woocommerce-navigation .components-navigation{display:none}body.is-wc-nav-folded .woocommerce-transient-notices{left:16px}body.is-wc-nav-folded #wpbody{padding-left:0}.has-woocommerce-navigation #adminmenuback,.has-woocommerce-navigation #adminmenuwrap{display:none!important}.has-woocommerce-navigation.woocommerce_page_wc-reports .woo-nav-tab-wrapper,.has-woocommerce-navigation.woocommerce_page_wc-settings .woo-nav-tab-wrapper,.has-woocommerce-navigation.woocommerce_page_wc-status .woo-nav-tab-wrapper{display:none}.has-woocommerce-navigation.woocommerce_page_wc-reports .woocommerce .subsubsub,.has-woocommerce-navigation.woocommerce_page_wc-settings .woocommerce .subsubsub,.has-woocommerce-navigation.woocommerce_page_wc-status .woocommerce .subsubsub{font-size:14px;margin:5px 0}.has-woocommerce-navigation #wpcontent,.has-woocommerce-navigation #wpfooter{margin-left:0}@media(max-width:960px){.has-woocommerce-navigation #wpcontent,.has-woocommerce-navigation #wpfooter{margin-left:0}}.has-woocommerce-navigation #wpbody{padding-left:240px}@media(max-width:960px){.has-woocommerce-navigation #wpbody{padding-left:0}}.has-woocommerce-navigation .woocommerce-layout__header.is-embed-loading:before{content:"";position:fixed;width:240px;height:100%;background:#1e1e1e}@media(max-width:960px){.has-woocommerce-navigation .woocommerce-layout__header.is-embed-loading:before{width:60px;height:60px}}.has-woocommerce-navigation #woocommerce-embedded-root.is-embed-loading{margin-bottom:-32px}.has-woocommerce-navigation:not(.is-wp-toolbar-disabled) #wpbody-content{margin-top:32px}.has-woocommerce-navigation font>.xdebug-error{margin-top:60px}.woocommerce-navigation-category-title{display:flex;align-items:center;font-size:20px;line-height:28px}.woocommerce-navigation-category-title .woocommerce-navigation-favorite-button{margin-left:auto}.woocommerce-navigation-favorite-button.components-button .star-empty-icon{color:#949494}.woocommerce-navigation-favorite-button.components-button .star-filled-icon{color:#ffb900}.woocommerce-transient-notices{position:fixed;bottom:12px;left:176px;z-index:99999;width:auto}@media(max-width:960px){.woocommerce-transient-notices{left:50px}}@media(max-width:782px){.woocommerce-transient-notices{left:16px}}.woocommerce-profile-wizard__body .woocommerce-transient-notices{left:unset}.woocommerce-profile-wizard__body .woocommerce-transient-notices .components-snackbar{margin-left:auto;margin-right:auto}.has-woocommerce-navigation .woocommerce-transient-notices{left:256px}.components-snackbar.components-snackbar-explicit-dismiss{cursor:default}.components-snackbar .components-snackbar__content-with-icon{margin-left:32px}.components-snackbar .components-snackbar__icon{position:absolute;top:24px;left:26px}.components-snackbar .components-snackbar__dismiss-button{margin-left:32px;cursor:pointer}:root{--wp-admin-theme-color:#007cba;--wp-admin-theme-color-darker-10:#006ba1;--wp-admin-theme-color-darker-20:#005a87}body.admin-color-light{--wp-admin-theme-color:#0085ba;--wp-admin-theme-color-darker-10:#0073a1;--wp-admin-theme-color-darker-20:#006187}body.admin-color-modern{--wp-admin-theme-color:#3858e9;--wp-admin-theme-color-darker-10:#2145e6;--wp-admin-theme-color-darker-20:#183ad6}body.admin-color-blue{--wp-admin-theme-color:#096484;--wp-admin-theme-color-darker-10:#07526c;--wp-admin-theme-color-darker-20:#064054}body.admin-color-coffee{--wp-admin-theme-color:#46403c;--wp-admin-theme-color-darker-10:#383330;--wp-admin-theme-color-darker-20:#2b2724}body.admin-color-ectoplasm{--wp-admin-theme-color:#523f6d;--wp-admin-theme-color-darker-10:#46365d;--wp-admin-theme-color-darker-20:#3a2c4d}body.admin-color-midnight{--wp-admin-theme-color:#e14d43;--wp-admin-theme-color-darker-10:#dd382d;--wp-admin-theme-color-darker-20:#d02c21}body.admin-color-ocean{--wp-admin-theme-color:#627c83;--wp-admin-theme-color-darker-10:#576e74;--wp-admin-theme-color-darker-20:#4c6066}body.admin-color-sunrise{--wp-admin-theme-color:#dd823b;--wp-admin-theme-color-darker-10:#d97426;--wp-admin-theme-color-darker-20:#c36922}.woocommerce-embedded-layout__primary{padding:0 20px}.woocommerce-embedded-layout__primary .components-card__footer,.woocommerce-embedded-layout__primary .components-card__header{box-sizing:border-box}@media(max-width:782px){.woocommerce-embedded-layout__primary{padding:0}}
|
trunk/dist/app/style.rtl.css
ADDED
@@ -0,0 +1 @@
|
|
|
1 |
+
.woocommerce-page .wrap{margin:0}.woocommerce-page #wpcontent,.woocommerce-page.woocommerce_page_wc-admin #wpbody-content{padding:0;overflow-x:hidden!important;min-height:calc(100vh - 32px)}@media(min-width:783px){.woocommerce-page #wpbody-content{padding-right:0}}@media(max-width:782px){.woocommerce-page .wp-responsive-open #woocommerce-embedded-root,.woocommerce-page .wp-responsive-open #wpbody{position:relative;left:-14.5em}.woocommerce-page #wpbody-content,.woocommerce-page #wpcontent{min-height:calc(100vh - 46px)}}@media(min-width:961px){.woocommerce-page #toplevel_page_wcadmin--analytics.menu-top>a:focus,.woocommerce-page #toplevel_page_woocommerce.menu-top>a:focus{padding-bottom:1px}}#wpbody,.woocommerce-layout *{box-sizing:border-box}#wpbody{display:inline-block;width:100%;padding-top:0;margin-top:60px}#wpfooter{display:none}.woocommerce_page_wc-admin .woocommerce-filters-date__content:not(.is-mobile){z-index:2}@media(max-width:600px){#wpadminbar{position:fixed}html.wp-toolbar{padding-top:46px}}@media(max-width:782px){.jetpack-masterbar #wpadminbar #wp-admin-bar-menu-toggle{margin-top:-10px}.jetpack-masterbar #wpwrap .woocommerce-layout__header-heading{padding-right:60px}.jetpack-masterbar.wp-admin .wrap h1,.jetpack-masterbar.wp-admin .wrap h2{padding-right:0}}.woocommerce-page .wp-has-current-submenu:after{left:0;content:" ";height:0;width:0;position:absolute;pointer-events:none;border:8px solid transparent;border-left-color:#f1f1f1;top:0;margin-top:10px}@media(max-width:960px){.woocommerce-page .wp-has-current-submenu:after{border-width:4px;margin-top:14px}}:root{--large-gap:40px;--main-gap:24px}@media(max-width:960px){:root{--large-gap:24px}}@media(max-width:782px){:root{--large-gap:16px;--main-gap:16px}}@keyframes loading-fade{0%{opacity:.7}50%{opacity:1}to{opacity:.7}}.woocommerce-layout select:hover{color:#1e1e1e}.woocommerce-layout select.components-select-control__input{max-width:100%;line-height:1}body.woocommerce-page .components-button.is-primary:not(:disabled),body.woocommerce-page .components-snackbar .components-button.is-tertiary,body.woocommerce-page .components-snackbar .components-button.is-tertiary:not(:disabled):not([aria-disabled=true]):hover{color:#fff}.woocommerce-embed-page #wpbody .woocommerce-layout,.woocommerce-embed-page .woocommerce-layout__notice-list-hide+.wrap{padding-top:10px}.woocommerce-embed-page #wpbody-content,.woocommerce-embed-page #wpcontent{overflow-x:initial!important}.woocommerce-embed-page #wpbody-content{padding-top:0}.woocommerce-embed-page #wpbody-content .notice{margin-top:15px}.woocommerce-embed-page .wrap{padding:0 20px}@media(max-width:782px){.woocommerce-embed-page .wrap p.search-box{width:calc(100% - 40px)}}.woocommerce-embed-page .wrap .wrap{padding:0}.woocommerce-embed-page #screen-meta{border-left:0;margin:0}.woocommerce-embed-page #screen-meta-links{position:relative}.woocommerce-embed-page .notice{padding:1px 12px}.woocommerce-embed-page .woocommerce-layout__header.is-scrolled{box-shadow:0 8px 16px 0 rgba(85,93,102,.3)}.woocommerce-embed-page .woocommerce-layout__header .woocommerce-layout__header-heading{margin-top:0;margin-bottom:0}.woocommerce-embed-page #screen-meta-links.is-hidden-by-notices,.woocommerce-embed-page #screen-meta.is-hidden-by-notices{display:none!important}.woocommerce-embed-page .woocommerce-layout__primary{margin:0}@media(max-width:782px){.woocommerce-embed-page .woocommerce-layout__primary{padding-top:10px}}@keyframes isLoaded{0%{opacity:0}to{opacity:1}}.woocommerce-embed-page .woocommerce-layout__activity-panel-tabs{animation:isLoaded;animation-duration:2s}.woocommerce-embed-page .woocommerce-layout__notice-list-show{margin-top:10px;margin-bottom:16px}@media(max-width:600px){.woocommerce-embed-page .woocommerce-layout__notice-list-show{margin-top:80px;margin-bottom:-16px}}@media(min-width:601px)and (max-width:782px){.woocommerce-embed-page .woocommerce-layout__notice-list-show{margin-top:32px}}.woocommerce-embed-page .woocommerce-activity-card__actions a.components-button:not(.is-primary){color:#757575}.woocommerce-layout{margin:0;padding:0}.woocommerce-layout__primary{margin:var(--large-gap) var(--large-gap) 0 0}@media(max-width:782px){.woocommerce-layout__primary{margin-top:20px}}.woocommerce-layout .woocommerce-layout__main{padding-left:40px;padding-left:var(--large-gap);max-width:100%}.woocommerce-admin-is-loading #adminmenumain,.woocommerce-admin-is-loading #wpadminbar,.woocommerce-admin-is-loading #wpbody-content,.woocommerce-admin-is-loading #wpcontent,.woocommerce-admin-is-loading #wpfooter,.woocommerce-admin-is-loading .components-modal__screen-overlay,.woocommerce-admin-is-loading .error,.woocommerce-admin-is-loading .notice,.woocommerce-admin-is-loading .update-nag,.woocommerce-admin-is-loading .updated,.woocommerce-admin-is-loading .woocommerce-layout__header,.woocommerce-admin-is-loading .woocommerce-message,.woocommerce-admin-is-loading .woocommerce-store-alerts,.woocommerce-page .update-nag{display:none}.woocommerce-admin-full-screen{background:#f6f7f7;color:#50575e;font-family:-apple-system,BlinkMacSystemFont,Segoe UI,Roboto,Oxygen-Sans,Ubuntu,Cantarell,Helvetica Neue,sans-serif}.woocommerce-admin-full-screen #wpwrap{top:0}.woocommerce-admin-full-screen #wpbody-content{min-height:100vh!important}.woocommerce-admin-full-screen #adminmenumain,.woocommerce-admin-full-screen #wpcontent>*,.woocommerce-admin-full-screen .error,.woocommerce-admin-full-screen .notice,.woocommerce-admin-full-screen .update-nag,.woocommerce-admin-full-screen .updated,.woocommerce-admin-full-screen .woocommerce-layout__header,.woocommerce-admin-full-screen .woocommerce-message,.woocommerce-admin-full-screen .woocommerce-store-alerts{display:none}.woocommerce-admin-full-screen #wpcontent{margin-right:0!important}.woocommerce-admin-full-screen #wpcontent>#wpbody{display:block;margin-top:0!important}.woocommerce-admin-full-screen.has-woocommerce-navigation #wpbody{padding-right:0}.is-wp-toolbar-disabled #wpadminbar{display:none!important}.wp-toolbar .is-wp-toolbar-disabled{margin-top:-32px}@media(max-width:600px){.wp-toolbar .is-wp-toolbar-disabled{margin-top:-46px}}.woocommerce-onboarding .muriel-component{margin-top:16px;margin-bottom:16px}.woocommerce-onboarding .components-base-control.has-error{margin-bottom:32px!important;border-color:#d63638}@media(max-width:782px){.woocommerce-onboarding .components-base-control.has-error{margin-bottom:44px!important}}.woocommerce-onboarding .components-base-control.has-error .components-base-control__help{top:100%;right:12px;position:absolute;margin-top:4px;font-size:12px;font-style:normal;color:#d63638}.woocommerce-onboarding .components-form-toggle{display:inline-block}.woocommerce-onboarding .components-form-toggle label{font-size:14px}.woocommerce-onboarding .components-form-toggle .components-base-control{display:inline-block}.woocommerce-onboarding .components-form-toggle .components-base-control__field{margin-bottom:0}.woocommerce-page .components-modal__frame .components-button.is-button,.woocommerce-profile-wizard__body .components-button.is-button,.woocommerce-task-dashboard__container .components-button.is-button{height:48px;padding-right:25px;padding-left:25px;text-align:center;font-size:14px;line-height:36px;font-weight:500;align-items:center}.woocommerce-page .components-modal__frame .components-button.is-button:disabled,.woocommerce-profile-wizard__body .components-button.is-button:disabled,.woocommerce-task-dashboard__container .components-button.is-button:disabled{cursor:not-allowed}.components-modal__header .components-button svg+span{display:none}.components-modal__frame.woocommerce-usage-modal{width:600px;max-width:100%}.components-modal__frame.woocommerce-usage-modal .components-modal__header{border-bottom:0;margin-bottom:0}.components-modal__frame.woocommerce-usage-modal .woocommerce-usage-modal__wrapper{flex-grow:1;display:flex;flex-direction:column}.components-modal__frame.woocommerce-usage-modal .woocommerce-usage-modal__wrapper a{color:#50575e}.components-modal__frame.woocommerce-usage-modal .woocommerce-usage-modal__wrapper button.is-primary{align-self:flex-end}.components-modal__frame.woocommerce-usage-modal .woocommerce-usage-modal__actions{display:flex;justify-content:flex-end;margin-top:16px}.components-modal__frame.woocommerce-usage-modal .woocommerce-usage-modal__actions button{margin-right:16px}.woocommerce-payments__usage-modal .components-modal__header{height:auto;padding:24px 24px 0}.woocommerce-payments__usage-modal .components-modal__header .components-modal__header-heading{font-size:24px;line-height:32px;margin:0 0 24px}.woocommerce-payments__usage-modal .woocommerce-payments__usage-modal-message{padding:16px 0;font-size:16px;line-height:24px}.woocommerce-payments__usage-modal .woocommerce-payments__usage-footer{display:flex;justify-content:flex-end;padding:16px 0}.woocommerce-payments__usage-modal .woocommerce-payments__usage-footer button{margin-right:16px}.components-modal__frame.woocommerce-cart-modal{width:600px;max-width:100%}.components-modal__frame.woocommerce-cart-modal .components-modal__header{border-bottom:0;margin-bottom:16px;margin-top:16px}.components-modal__frame.woocommerce-cart-modal .components-modal__header button{display:none}.components-modal__frame.woocommerce-cart-modal .components-modal__header-heading{font-style:normal;font-weight:400;font-size:24px;line-height:32px}.components-modal__frame.woocommerce-cart-modal .woocommerce-list{margin-top:4px}.components-modal__frame.woocommerce-cart-modal .woocommerce-list .woocommerce-list__item:first-child{border-top:1px solid #dcdcde}.components-modal__frame.woocommerce-cart-modal .woocommerce-list__item{border-bottom:1px solid #dcdcde}.components-modal__frame.woocommerce-cart-modal .woocommerce-cart-modal__help-text{font-size:16px;line-height:24px}.components-modal__frame.woocommerce-cart-modal .woocommerce-cart-modal__actions{text-align:left}.components-modal__frame.woocommerce-cart-modal .woocommerce-cart-modal__actions button.is-link{margin-left:16px;text-decoration:none;font-weight:600;font-size:14px}.components-modal__frame.woocommerce-cart-modal .woocommerce-cart-modal__actions button.is-primary{align-self:flex-end}.woocommerce-layout__header{background:#fff;box-sizing:border-box;padding:0;position:fixed;width:calc(100% - 160px);top:32px;z-index:1001}.woocommerce-layout__header.is-scrolled{box-shadow:0 8px 8px 0 rgba(85,93,102,.3)}.woocommerce-layout__header .woocommerce-layout__header-wrapper{display:flex;align-items:center;min-height:60px}.woocommerce-layout__header .woocommerce-layout__header-back-button{cursor:pointer;margin-right:var(--large-gap);display:flex}.woocommerce-layout__header .woocommerce-layout__header-back-button:focus{box-shadow:inset 1px -1px 0 #757575,inset -1px 1px 0 #757575}@media(max-width:782px){.woocommerce-layout__header{flex-flow:row wrap;top:46px;width:100%}}@media(min-width:783px)and (max-width:960px){.woocommerce-layout__header{width:calc(100% - 36px)}}.woocommerce-layout__header .woocommerce-layout__header-breadcrumbs-wrapper{display:flex;justify-content:space-between;flex-direction:row}.woocommerce-layout__header .woocommerce-layout__header-heading{display:flex;align-items:center;padding:0 40px 0 0;padding:0 var(--large-gap) 0 0;flex:1 auto;height:60px;background:#fff;font-weight:600;font-size:14px}.woocommerce-layout__header .woocommerce-layout__header-heading.with-back-button{padding-right:24px}.folded .woocommerce-layout__header{width:calc(100% - 36px)}@media(max-width:782px){.folded .woocommerce-layout__header{width:100%}}.is-wp-toolbar-disabled .woocommerce-layout__header{top:0}.has-woocommerce-navigation .woocommerce-layout__header{right:0;width:100%}.woocommerce-page #contextual-help-link-wrap,.woocommerce-page #screen-options-link-wrap{margin-top:-1px}.wp-responsive-open .woocommerce-layout__header{margin-right:2px}.woocommerce-layout__activity-panel{display:flex;flex-direction:row;align-items:center;height:60px}.woocommerce-layout__activity-panel-tabs{width:100%;display:flex;height:60px;justify-content:flex-end}.woocommerce-layout__activity-panel-tabs .dashicon,.woocommerce-layout__activity-panel-tabs .gridicon{width:100%}.woocommerce-layout__activity-panel-tabs svg{width:24px;height:24px}.woocommerce-layout__activity-panel-tabs svg.woocommerce-layout__activity-panel-tab-icon{fill:none}.woocommerce-layout__activity-panel-tabs svg.woocommerce-layout__activity-panel-tab-icon path,.woocommerce-layout__activity-panel-tabs svg.woocommerce-layout__activity-panel-tab-icon rect{stroke:currentColor}.woocommerce-layout__activity-panel-tabs svg.setup-progress path:first-child{stroke:"#DCDCDE"}.woocommerce-layout__activity-panel-tabs .woocommerce-layout__homescreen-display-options svg.woocommerce-layout__activity-panel-tab-icon{height:14px}.woocommerce-layout__activity-panel-tabs .woocommerce-layout__homescreen-extension-tasklist-toggle{min-width:205px}.woocommerce-layout__activity-panel-tabs .components-icon-button{display:initial;text-indent:0;border-radius:0}.woocommerce-layout__activity-panel-tabs .components-icon-button.has-text svg{margin:0}.woocommerce-layout__activity-panel-tabs .woocommerce-layout__activity-panel-tab{display:flex;flex-direction:column;justify-content:center;align-items:center;position:relative;border:none;outline:none;cursor:pointer;background-color:#fff;max-width:min-content;min-width:80px;width:100%;height:60px;color:#757575;white-space:nowrap}.woocommerce-layout__activity-panel-tabs .woocommerce-layout__activity-panel-tab:before{background-color:#007cba;background-color:var(--wp-admin-theme-color);bottom:0;content:"";height:0;opacity:0;transition-property:height,opacity;transition-duration:.3s;transition-timing-function:ease-in-out;right:0;position:absolute;left:0}.woocommerce-layout__activity-panel-tabs .woocommerce-layout__activity-panel-tab.is-active,.woocommerce-layout__activity-panel-tabs .woocommerce-layout__activity-panel-tab.is-opened{color:#1e1e1e;box-shadow:none}.woocommerce-layout__activity-panel-tabs .woocommerce-layout__activity-panel-tab.is-active:before,.woocommerce-layout__activity-panel-tabs .woocommerce-layout__activity-panel-tab.is-opened:before{height:3px;opacity:1}.woocommerce-layout__activity-panel-tabs .woocommerce-layout__activity-panel-tab.has-unread:after,.woocommerce-layout__activity-panel-tabs .woocommerce-layout__activity-panel-tab.woocommerce-layout__activity-panel-tab-wordpress-notices:after{content:" ";position:absolute;padding:1px;background:#d94f4f;border:2px solid #fff;width:4px;height:4px;display:inline-block;border-radius:50%;top:8px;right:50%}@media(min-width:783px)and (max-width:960px){.woocommerce-layout__activity-panel-tabs .woocommerce-layout__activity-panel-tab.has-unread:after,.woocommerce-layout__activity-panel-tabs .woocommerce-layout__activity-panel-tab.woocommerce-layout__activity-panel-tab-wordpress-notices:after{left:18px;right:auto;margin-right:0}}@media(min-width:961px){.woocommerce-layout__activity-panel-tabs .woocommerce-layout__activity-panel-tab.has-unread:after,.woocommerce-layout__activity-panel-tabs .woocommerce-layout__activity-panel-tab.woocommerce-layout__activity-panel-tab-wordpress-notices:after{left:28px;right:auto;margin-right:0}}.woocommerce-layout__activity-panel-tabs .woocommerce-layout__activity-panel-tab.components-button:not(:disabled):not([aria-disabled=true]):hover,.woocommerce-layout__activity-panel-tabs .woocommerce-layout__activity-panel-tab:hover{background-color:#f0f0f0;box-shadow:none}.woocommerce-layout__activity-panel-tabs .woocommerce-layout__activity-panel-tab.components-button:not(:disabled):not([aria-disabled=true]):hover.has-unread:after,.woocommerce-layout__activity-panel-tabs .woocommerce-layout__activity-panel-tab.components-button:not(:disabled):not([aria-disabled=true]):hover.woocommerce-layout__activity-panel-tab-wordpress-notices:after,.woocommerce-layout__activity-panel-tabs .woocommerce-layout__activity-panel-tab:hover.has-unread:after,.woocommerce-layout__activity-panel-tabs .woocommerce-layout__activity-panel-tab:hover.woocommerce-layout__activity-panel-tab-wordpress-notices:after{border-color:#e0e0e0}.woocommerce-layout__activity-panel-tabs .woocommerce-layout__activity-panel-tab.components-button:not(:disabled):not([aria-disabled=true]):focus,.woocommerce-layout__activity-panel-tabs .woocommerce-layout__activity-panel-tab:focus{box-shadow:inset 1px -1px 0 #757575,inset -1px 1px 0 #757575}@media(max-width:782px){.woocommerce-layout__activity-panel-tabs .woocommerce-layout__activity-panel-tab.display-options{display:none}}.woocommerce-layout__activity-panel-tabs .woocommerce-layout__activity-panel-popover{margin-top:0;z-index:1001}.woocommerce-layout__activity-panel-tabs .woocommerce-layout__activity-panel-popover .components-menu-group{padding:12px}.woocommerce-layout__activity-panel-toggle-bubble.has-unread:after{content:" ";position:absolute;padding:1px;background:#ca4a1f;border:2px solid #fff;width:4px;height:4px;display:inline-block;border-radius:50%;top:6px;left:4px}@keyframes tabSwitch{0%,to{transform:translateX(0)}50%{transform:translateX(-100px)}}.woocommerce-layout__activity-panel-wrapper{height:calc(100vh - 106px);background:#f0f0f0;width:430px;transform:translateX(-100%);transition-property:transform box-shadow;transition-duration:.3s;transition-timing-function:ease-in-out;position:fixed;left:0;top:106px;z-index:1000;overflow-x:hidden;overflow-y:auto}@media(max-width:782px){.woocommerce-layout__activity-panel-wrapper{width:100%}}@media screen and (prefers-reduced-motion:reduce){.woocommerce-layout__activity-panel-wrapper{transition-duration:1ms}}@media(min-width:783px){.woocommerce-layout__activity-panel-wrapper{height:calc(100vh - 92px);top:92px}}.has-woocommerce-navigation .woocommerce-layout__activity-panel-wrapper{height:calc(100vh - 60px);top:60px}.woocommerce-layout__activity-panel-wrapper.is-open{transform:none;box-shadow:0 12px 12px 0 rgba(85,93,102,.3)}.woocommerce-layout__activity-panel-wrapper.is-switching{animation:tabSwitch;animation-duration:.3s}@media screen and (prefers-reduced-motion:reduce){.woocommerce-layout__activity-panel-wrapper.is-switching{animation:none}}.woocommerce-layout__activity-panel-wrapper .woocommerce-empty-content{padding-right:24px;padding-left:24px}.woocommerce-layout__activity-panel-avatar-flag-overlay{position:relative;top:-12px}.woocommerce-layout__activity-panel-avatar-flag-overlay .woocommerce-flag{position:relative;top:16px;border:2px solid #fff}.woocommerce-layout__notice-list-hide{display:none}.highlight-tooltip__container{position:absolute;width:0;height:0}.highlight-tooltip__container.highlight-tooltip__show{top:0;right:0;width:100%;height:100%}.highlight-tooltip__portal{width:100%;height:100%;position:relative}.highlight-tooltip__portal .highlight-tooltip__overlay{position:fixed;top:0;left:0;bottom:0;right:0;background-color:rgba(0,0,0,.35);z-index:100000;animation:edit-post__fade-in-animation .2s ease-out 0s;animation-fill-mode:forwards}@media(prefers-reduced-motion:reduce){.highlight-tooltip__portal .highlight-tooltip__overlay{animation-duration:1ms}}.highlight-tooltip__popover .components-card{min-width:360px}.highlight-tooltip__popover .components-card__header{font-size:16px;font-size:1rem;font-weight:600;box-sizing:border-box}.highlight-tooltip__popover .components-card__footer{justify-content:flex-end;box-sizing:border-box}.woocommerce-layout__show-app-banner{padding-top:56px}@media(min-width:783px){.woocommerce-layout__show-app-banner{padding-top:0}}.woocommerce-mobile-app-banner{background-color:#3c2861;width:100%;display:flex;height:56px;align-items:center;padding:0 4px 0 6px}@media(min-width:401px){.woocommerce-mobile-app-banner{padding:0 10px 0 13px}}@media(min-width:783px){.woocommerce-mobile-app-banner{display:none}}.woocommerce-mobile-app-banner .gridicon{fill:#fff;margin-left:10px}.woocommerce-mobile-app-banner .components-button.is-secondary{margin-right:auto;color:#fff;box-shadow:inset 0 0 0 1px #fff}.woocommerce-mobile-app-banner .components-button.is-secondary:active,.woocommerce-mobile-app-banner .components-button.is-secondary:hover{color:#fff;box-shadow:inset 0 0 0 1px #fff;background:none}.woocommerce-mobile-app-banner .woocommerce-mobile-app-banner__description{color:#fff;margin-right:8px}@media(min-width:401px){.woocommerce-mobile-app-banner .woocommerce-mobile-app-banner__description{margin-right:13px}}.woocommerce-mobile-app-banner .woocommerce-mobile-app-banner__description .woocommerce-mobile-app-banner__description__text{margin:0;font-size:10px}.woocommerce-mobile-app-banner .woocommerce-mobile-app-banner__description .woocommerce-mobile-app-banner__description__text:first-child{font-weight:700}@media(min-width:401px){.woocommerce-mobile-app-banner .woocommerce-mobile-app-banner__description .woocommerce-mobile-app-banner__description__text{margin-right:13px;font-size:13px}}.woocommerce-navigation{display:grid;grid-template-rows:min-content 1fr;height:100%}.woocommerce-navigation h2>span{width:100%}.woocommerce-navigation .components-navigation__menu{overflow-y:auto;margin-bottom:0;padding-bottom:24px}.woocommerce-navigation .components-navigation__group+.components-navigation__group{margin-top:24px}.woocommerce-navigation .components-navigation__item{margin-bottom:0}.woocommerce-navigation .components-navigation__item a.components-button{padding:6px 16px}.woocommerce-navigation .components-navigation__item:not(:hover) a.components-button{color:#949494}.woocommerce-navigation .components-navigation__item.is-active a.components-button{color:#fff}.woocommerce-navigation .components-navigation{height:100%}.woocommerce-navigation .components-navigation>div{height:100%;display:grid;grid-template-rows:1fr min-content}.woocommerce-navigation.is-root .components-navigation__menu-secondary{border-top:1px solid #2c3338;margin:0 -8px;padding:16px 8px 12px}.woocommerce-navigation-header{display:flex;align-items:center;border:none;border-radius:0;height:auto}.woocommerce-navigation-header .woocommerce-navigation-header__site-icon.components-button{padding:12px;height:60px;color:#fff}.woocommerce-navigation-header .woocommerce-navigation-header__site-icon.components-button:focus,.woocommerce-navigation-header .woocommerce-navigation-header__site-icon.components-button:hover,.woocommerce-navigation-header .woocommerce-navigation-header__site-icon.components-button:not([aria-disabled=true]):active{color:#fff}.woocommerce-navigation-header .woocommerce-navigation-header__site-title.components-button{padding-right:0;color:#ccc;font-weight:600}.woocommerce-navigation-header .woocommerce-navigation-header__site-title.components-button:active,.woocommerce-navigation-header .woocommerce-navigation-header__site-title.components-button:focus,.woocommerce-navigation-header .woocommerce-navigation-header__site-title.components-button:hover{color:#e0e0e0}.woocommerce-navigation{position:relative;width:240px;box-sizing:border-box;background-color:#1e1e1e;z-index:1100}@media(max-width:960px){.woocommerce-navigation{width:60px;height:60px}}.woocommerce-navigation .components-navigation{box-sizing:border-box}.woocommerce-navigation .components-navigation__menu-title{overflow:visible}.woocommerce-navigation__wrapper{background-color:#1e1e1e;position:absolute;top:60px;width:100%;height:calc(100vh - 92px);overflow-y:auto}.is-wp-toolbar-disabled .woocommerce-navigation__wrapper{height:calc(100vh - 60px)}body.is-wc-nav-expanded .woocommerce-navigation{width:240px;height:100%}body.is-wc-nav-expanded font>.xdebug-error{margin-right:256px}body.is-wc-nav-folded .woocommerce-navigation{width:60px;height:60px;overflow:hidden}body.is-wc-nav-folded .woocommerce-navigation .woocommerce-navigation-header>*{display:none}body.is-wc-nav-folded .woocommerce-navigation .woocommerce-navigation-header__site-icon{display:block}body.is-wc-nav-folded .woocommerce-navigation .components-navigation{display:none}body.is-wc-nav-folded .woocommerce-transient-notices{right:16px}body.is-wc-nav-folded #wpbody{padding-right:0}.has-woocommerce-navigation #adminmenuback,.has-woocommerce-navigation #adminmenuwrap{display:none!important}.has-woocommerce-navigation.woocommerce_page_wc-reports .woo-nav-tab-wrapper,.has-woocommerce-navigation.woocommerce_page_wc-settings .woo-nav-tab-wrapper,.has-woocommerce-navigation.woocommerce_page_wc-status .woo-nav-tab-wrapper{display:none}.has-woocommerce-navigation.woocommerce_page_wc-reports .woocommerce .subsubsub,.has-woocommerce-navigation.woocommerce_page_wc-settings .woocommerce .subsubsub,.has-woocommerce-navigation.woocommerce_page_wc-status .woocommerce .subsubsub{font-size:14px;margin:5px 0}.has-woocommerce-navigation #wpcontent,.has-woocommerce-navigation #wpfooter{margin-right:0}@media(max-width:960px){.has-woocommerce-navigation #wpcontent,.has-woocommerce-navigation #wpfooter{margin-right:0}}.has-woocommerce-navigation #wpbody{padding-right:240px}@media(max-width:960px){.has-woocommerce-navigation #wpbody{padding-right:0}}.has-woocommerce-navigation .woocommerce-layout__header.is-embed-loading:before{content:"";position:fixed;width:240px;height:100%;background:#1e1e1e}@media(max-width:960px){.has-woocommerce-navigation .woocommerce-layout__header.is-embed-loading:before{width:60px;height:60px}}.has-woocommerce-navigation #woocommerce-embedded-root.is-embed-loading{margin-bottom:-32px}.has-woocommerce-navigation:not(.is-wp-toolbar-disabled) #wpbody-content{margin-top:32px}.has-woocommerce-navigation font>.xdebug-error{margin-top:60px}.woocommerce-navigation-category-title{display:flex;align-items:center;font-size:20px;line-height:28px}.woocommerce-navigation-category-title .woocommerce-navigation-favorite-button{margin-right:auto}.woocommerce-navigation-favorite-button.components-button .star-empty-icon{color:#949494}.woocommerce-navigation-favorite-button.components-button .star-filled-icon{color:#ffb900}.woocommerce-transient-notices{position:fixed;bottom:12px;right:176px;z-index:99999;width:auto}@media(max-width:960px){.woocommerce-transient-notices{right:50px}}@media(max-width:782px){.woocommerce-transient-notices{right:16px}}.woocommerce-profile-wizard__body .woocommerce-transient-notices{right:unset}.woocommerce-profile-wizard__body .woocommerce-transient-notices .components-snackbar{margin-right:auto;margin-left:auto}.has-woocommerce-navigation .woocommerce-transient-notices{right:256px}.components-snackbar.components-snackbar-explicit-dismiss{cursor:default}.components-snackbar .components-snackbar__content-with-icon{margin-right:32px}.components-snackbar .components-snackbar__icon{position:absolute;top:24px;right:26px}.components-snackbar .components-snackbar__dismiss-button{margin-right:32px;cursor:pointer}:root{--wp-admin-theme-color:#007cba;--wp-admin-theme-color-darker-10:#006ba1;--wp-admin-theme-color-darker-20:#005a87}body.admin-color-light{--wp-admin-theme-color:#0085ba;--wp-admin-theme-color-darker-10:#0073a1;--wp-admin-theme-color-darker-20:#006187}body.admin-color-modern{--wp-admin-theme-color:#3858e9;--wp-admin-theme-color-darker-10:#2145e6;--wp-admin-theme-color-darker-20:#183ad6}body.admin-color-blue{--wp-admin-theme-color:#096484;--wp-admin-theme-color-darker-10:#07526c;--wp-admin-theme-color-darker-20:#064054}body.admin-color-coffee{--wp-admin-theme-color:#46403c;--wp-admin-theme-color-darker-10:#383330;--wp-admin-theme-color-darker-20:#2b2724}body.admin-color-ectoplasm{--wp-admin-theme-color:#523f6d;--wp-admin-theme-color-darker-10:#46365d;--wp-admin-theme-color-darker-20:#3a2c4d}body.admin-color-midnight{--wp-admin-theme-color:#e14d43;--wp-admin-theme-color-darker-10:#dd382d;--wp-admin-theme-color-darker-20:#d02c21}body.admin-color-ocean{--wp-admin-theme-color:#627c83;--wp-admin-theme-color-darker-10:#576e74;--wp-admin-theme-color-darker-20:#4c6066}body.admin-color-sunrise{--wp-admin-theme-color:#dd823b;--wp-admin-theme-color-darker-10:#d97426;--wp-admin-theme-color-darker-20:#c36922}.woocommerce-embedded-layout__primary{padding:0 20px}.woocommerce-embedded-layout__primary .components-card__footer,.woocommerce-embedded-layout__primary .components-card__header{box-sizing:border-box}@media(max-width:782px){.woocommerce-embedded-layout__primary{padding:0}}
|
trunk/dist/beta-features-tracking-modal/style-rtl.css
ADDED
@@ -0,0 +1 @@
|
|
|
1 |
+
:root{--wp-admin-theme-color:#007cba;--wp-admin-theme-color-darker-10:#006ba1;--wp-admin-theme-color-darker-20:#005a87}body.admin-color-light{--wp-admin-theme-color:#0085ba;--wp-admin-theme-color-darker-10:#0073a1;--wp-admin-theme-color-darker-20:#006187}body.admin-color-modern{--wp-admin-theme-color:#3858e9;--wp-admin-theme-color-darker-10:#2145e6;--wp-admin-theme-color-darker-20:#183ad6}body.admin-color-blue{--wp-admin-theme-color:#096484;--wp-admin-theme-color-darker-10:#07526c;--wp-admin-theme-color-darker-20:#064054}body.admin-color-coffee{--wp-admin-theme-color:#46403c;--wp-admin-theme-color-darker-10:#383330;--wp-admin-theme-color-darker-20:#2b2724}body.admin-color-ectoplasm{--wp-admin-theme-color:#523f6d;--wp-admin-theme-color-darker-10:#46365d;--wp-admin-theme-color-darker-20:#3a2c4d}body.admin-color-midnight{--wp-admin-theme-color:#e14d43;--wp-admin-theme-color-darker-10:#dd382d;--wp-admin-theme-color-darker-20:#d02c21}body.admin-color-ocean{--wp-admin-theme-color:#627c83;--wp-admin-theme-color-darker-10:#576e74;--wp-admin-theme-color-darker-20:#4c6066}body.admin-color-sunrise{--wp-admin-theme-color:#dd823b;--wp-admin-theme-color-darker-10:#d97426;--wp-admin-theme-color-darker-20:#c36922}.woocommerce-beta-features-tracking-modal__actions{text-align:left;margin-top:24px}.woocommerce-beta-features-tracking-modal__actions .components-button.is-primary{margin-right:16px}.woocommerce-beta-features-tracking-modal__checkbox{padding:16px 0}
|
trunk/dist/beta-features-tracking-modal/style.css
ADDED
@@ -0,0 +1 @@
|
|
|
1 |
+
:root{--wp-admin-theme-color:#007cba;--wp-admin-theme-color-darker-10:#006ba1;--wp-admin-theme-color-darker-20:#005a87}body.admin-color-light{--wp-admin-theme-color:#0085ba;--wp-admin-theme-color-darker-10:#0073a1;--wp-admin-theme-color-darker-20:#006187}body.admin-color-modern{--wp-admin-theme-color:#3858e9;--wp-admin-theme-color-darker-10:#2145e6;--wp-admin-theme-color-darker-20:#183ad6}body.admin-color-blue{--wp-admin-theme-color:#096484;--wp-admin-theme-color-darker-10:#07526c;--wp-admin-theme-color-darker-20:#064054}body.admin-color-coffee{--wp-admin-theme-color:#46403c;--wp-admin-theme-color-darker-10:#383330;--wp-admin-theme-color-darker-20:#2b2724}body.admin-color-ectoplasm{--wp-admin-theme-color:#523f6d;--wp-admin-theme-color-darker-10:#46365d;--wp-admin-theme-color-darker-20:#3a2c4d}body.admin-color-midnight{--wp-admin-theme-color:#e14d43;--wp-admin-theme-color-darker-10:#dd382d;--wp-admin-theme-color-darker-20:#d02c21}body.admin-color-ocean{--wp-admin-theme-color:#627c83;--wp-admin-theme-color-darker-10:#576e74;--wp-admin-theme-color-darker-20:#4c6066}body.admin-color-sunrise{--wp-admin-theme-color:#dd823b;--wp-admin-theme-color-darker-10:#d97426;--wp-admin-theme-color-darker-20:#c36922}.woocommerce-beta-features-tracking-modal__actions{text-align:right;margin-top:24px}.woocommerce-beta-features-tracking-modal__actions .components-button.is-primary{margin-left:16px}.woocommerce-beta-features-tracking-modal__checkbox{padding:16px 0}
|
trunk/dist/beta-features-tracking-modal/style.rtl.css
ADDED
@@ -0,0 +1 @@
|
|
|
1 |
+
:root{--wp-admin-theme-color:#007cba;--wp-admin-theme-color-darker-10:#006ba1;--wp-admin-theme-color-darker-20:#005a87}body.admin-color-light{--wp-admin-theme-color:#0085ba;--wp-admin-theme-color-darker-10:#0073a1;--wp-admin-theme-color-darker-20:#006187}body.admin-color-modern{--wp-admin-theme-color:#3858e9;--wp-admin-theme-color-darker-10:#2145e6;--wp-admin-theme-color-darker-20:#183ad6}body.admin-color-blue{--wp-admin-theme-color:#096484;--wp-admin-theme-color-darker-10:#07526c;--wp-admin-theme-color-darker-20:#064054}body.admin-color-coffee{--wp-admin-theme-color:#46403c;--wp-admin-theme-color-darker-10:#383330;--wp-admin-theme-color-darker-20:#2b2724}body.admin-color-ectoplasm{--wp-admin-theme-color:#523f6d;--wp-admin-theme-color-darker-10:#46365d;--wp-admin-theme-color-darker-20:#3a2c4d}body.admin-color-midnight{--wp-admin-theme-color:#e14d43;--wp-admin-theme-color-darker-10:#dd382d;--wp-admin-theme-color-darker-20:#d02c21}body.admin-color-ocean{--wp-admin-theme-color:#627c83;--wp-admin-theme-color-darker-10:#576e74;--wp-admin-theme-color-darker-20:#4c6066}body.admin-color-sunrise{--wp-admin-theme-color:#dd823b;--wp-admin-theme-color-darker-10:#d97426;--wp-admin-theme-color-darker-20:#c36922}.woocommerce-beta-features-tracking-modal__actions{text-align:left;margin-top:24px}.woocommerce-beta-features-tracking-modal__actions .components-button.is-primary{margin-right:16px}.woocommerce-beta-features-tracking-modal__checkbox{padding:16px 0}
|
trunk/dist/chunks/0.js
ADDED
@@ -0,0 +1,1820 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
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|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
(window["__wcAdmin_webpackJsonp"] = window["__wcAdmin_webpackJsonp"] || []).push([[0],{
|
2 |
+
|
3 |
+
/***/ 503:
|
4 |
+
/***/ (function(module, __webpack_exports__, __webpack_require__) {
|
5 |
+
|
6 |
+
"use strict";
|
7 |
+
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "b", function() { return getFilteredCurrencyInstance; });
|
8 |
+
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "a", function() { return CurrencyContext; });
|
9 |
+
/* harmony import */ var _wordpress_element__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(0);
|
10 |
+
/* harmony import */ var _wordpress_element__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(_wordpress_element__WEBPACK_IMPORTED_MODULE_0__);
|
11 |
+
/* harmony import */ var _wordpress_hooks__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(31);
|
12 |
+
/* harmony import */ var _wordpress_hooks__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(_wordpress_hooks__WEBPACK_IMPORTED_MODULE_1__);
|
13 |
+
/* harmony import */ var _woocommerce_currency__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(89);
|
14 |
+
/* harmony import */ var _woocommerce_currency__WEBPACK_IMPORTED_MODULE_2___default = /*#__PURE__*/__webpack_require__.n(_woocommerce_currency__WEBPACK_IMPORTED_MODULE_2__);
|
15 |
+
/* harmony import */ var _woocommerce_wc_admin_settings__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(13);
|
16 |
+
/**
|
17 |
+
* External dependencies
|
18 |
+
*/
|
19 |
+
|
20 |
+
|
21 |
+
|
22 |
+
|
23 |
+
const appCurrency = _woocommerce_currency__WEBPACK_IMPORTED_MODULE_2___default()(_woocommerce_wc_admin_settings__WEBPACK_IMPORTED_MODULE_3__[/* CURRENCY */ "a"]);
|
24 |
+
const getFilteredCurrencyInstance = query => {
|
25 |
+
const config = appCurrency.getCurrencyConfig();
|
26 |
+
const filteredConfig = Object(_wordpress_hooks__WEBPACK_IMPORTED_MODULE_1__["applyFilters"])('woocommerce_admin_report_currency', config, query);
|
27 |
+
return _woocommerce_currency__WEBPACK_IMPORTED_MODULE_2___default()(filteredConfig);
|
28 |
+
};
|
29 |
+
const CurrencyContext = Object(_wordpress_element__WEBPACK_IMPORTED_MODULE_0__["createContext"])(appCurrency // default value
|
30 |
+
);
|
31 |
+
|
32 |
+
/***/ }),
|
33 |
+
|
34 |
+
/***/ 506:
|
35 |
+
/***/ (function(module, __webpack_exports__, __webpack_require__) {
|
36 |
+
|
37 |
+
"use strict";
|
38 |
+
/* harmony import */ var _wordpress_element__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(0);
|
39 |
+
/* harmony import */ var _wordpress_element__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(_wordpress_element__WEBPACK_IMPORTED_MODULE_0__);
|
40 |
+
/* harmony import */ var _wordpress_i18n__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(2);
|
41 |
+
/* harmony import */ var _wordpress_i18n__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(_wordpress_i18n__WEBPACK_IMPORTED_MODULE_1__);
|
42 |
+
/* harmony import */ var prop_types__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(1);
|
43 |
+
/* harmony import */ var prop_types__WEBPACK_IMPORTED_MODULE_2___default = /*#__PURE__*/__webpack_require__.n(prop_types__WEBPACK_IMPORTED_MODULE_2__);
|
44 |
+
/* harmony import */ var _woocommerce_components__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(21);
|
45 |
+
/* harmony import */ var _woocommerce_components__WEBPACK_IMPORTED_MODULE_3___default = /*#__PURE__*/__webpack_require__.n(_woocommerce_components__WEBPACK_IMPORTED_MODULE_3__);
|
46 |
+
|
47 |
+
|
48 |
+
/**
|
49 |
+
* External dependencies
|
50 |
+
*/
|
51 |
+
|
52 |
+
|
53 |
+
|
54 |
+
/**
|
55 |
+
* Component to render when there is an error in a report component due to data
|
56 |
+
* not being loaded or being invalid.
|
57 |
+
*
|
58 |
+
* @param {Object} props React props.
|
59 |
+
* @param {string} [props.className] Additional class name to style the component.
|
60 |
+
*/
|
61 |
+
|
62 |
+
function ReportError({
|
63 |
+
className
|
64 |
+
}) {
|
65 |
+
const title = Object(_wordpress_i18n__WEBPACK_IMPORTED_MODULE_1__["__"])('There was an error getting your stats. Please try again.', 'woocommerce-admin');
|
66 |
+
|
67 |
+
const actionLabel = Object(_wordpress_i18n__WEBPACK_IMPORTED_MODULE_1__["__"])('Reload', 'woocommerce-admin');
|
68 |
+
|
69 |
+
const actionCallback = () => {
|
70 |
+
// @todo Add tracking for how often an error is displayed, and the reload action is clicked.
|
71 |
+
window.location.reload();
|
72 |
+
};
|
73 |
+
|
74 |
+
return Object(_wordpress_element__WEBPACK_IMPORTED_MODULE_0__["createElement"])(_woocommerce_components__WEBPACK_IMPORTED_MODULE_3__["EmptyContent"], {
|
75 |
+
className: className,
|
76 |
+
title: title,
|
77 |
+
actionLabel: actionLabel,
|
78 |
+
actionCallback: actionCallback
|
79 |
+
});
|
80 |
+
}
|
81 |
+
|
82 |
+
ReportError.propTypes = {
|
83 |
+
/**
|
84 |
+
* Additional class name to style the component.
|
85 |
+
*/
|
86 |
+
className: prop_types__WEBPACK_IMPORTED_MODULE_2___default.a.string
|
87 |
+
};
|
88 |
+
/* harmony default export */ __webpack_exports__["a"] = (ReportError);
|
89 |
+
|
90 |
+
/***/ }),
|
91 |
+
|
92 |
+
/***/ 508:
|
93 |
+
/***/ (function(module, __webpack_exports__, __webpack_require__) {
|
94 |
+
|
95 |
+
"use strict";
|
96 |
+
/* harmony import */ var _wordpress_element__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(0);
|
97 |
+
/* harmony import */ var _wordpress_element__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(_wordpress_element__WEBPACK_IMPORTED_MODULE_0__);
|
98 |
+
/* harmony import */ var _wordpress_compose__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(14);
|
99 |
+
/* harmony import */ var _wordpress_compose__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(_wordpress_compose__WEBPACK_IMPORTED_MODULE_1__);
|
100 |
+
/* harmony import */ var prop_types__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(1);
|
101 |
+
/* harmony import */ var prop_types__WEBPACK_IMPORTED_MODULE_2___default = /*#__PURE__*/__webpack_require__.n(prop_types__WEBPACK_IMPORTED_MODULE_2__);
|
102 |
+
/* harmony import */ var lodash__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(4);
|
103 |
+
/* harmony import */ var lodash__WEBPACK_IMPORTED_MODULE_3___default = /*#__PURE__*/__webpack_require__.n(lodash__WEBPACK_IMPORTED_MODULE_3__);
|
104 |
+
/* harmony import */ var _wordpress_data__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(7);
|
105 |
+
/* harmony import */ var _wordpress_data__WEBPACK_IMPORTED_MODULE_4___default = /*#__PURE__*/__webpack_require__.n(_wordpress_data__WEBPACK_IMPORTED_MODULE_4__);
|
106 |
+
/* harmony import */ var _woocommerce_components__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(21);
|
107 |
+
/* harmony import */ var _woocommerce_components__WEBPACK_IMPORTED_MODULE_5___default = /*#__PURE__*/__webpack_require__.n(_woocommerce_components__WEBPACK_IMPORTED_MODULE_5__);
|
108 |
+
/* harmony import */ var _woocommerce_wc_admin_settings__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(13);
|
109 |
+
/* harmony import */ var _woocommerce_data__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__(11);
|
110 |
+
/* harmony import */ var _woocommerce_data__WEBPACK_IMPORTED_MODULE_7___default = /*#__PURE__*/__webpack_require__.n(_woocommerce_data__WEBPACK_IMPORTED_MODULE_7__);
|
111 |
+
/* harmony import */ var _woocommerce_date__WEBPACK_IMPORTED_MODULE_8__ = __webpack_require__(20);
|
112 |
+
/* harmony import */ var _woocommerce_date__WEBPACK_IMPORTED_MODULE_8___default = /*#__PURE__*/__webpack_require__.n(_woocommerce_date__WEBPACK_IMPORTED_MODULE_8__);
|
113 |
+
/* harmony import */ var _woocommerce_tracks__WEBPACK_IMPORTED_MODULE_9__ = __webpack_require__(15);
|
114 |
+
/* harmony import */ var _woocommerce_tracks__WEBPACK_IMPORTED_MODULE_9___default = /*#__PURE__*/__webpack_require__.n(_woocommerce_tracks__WEBPACK_IMPORTED_MODULE_9__);
|
115 |
+
/* harmony import */ var _lib_currency_context__WEBPACK_IMPORTED_MODULE_10__ = __webpack_require__(503);
|
116 |
+
/* harmony import */ var _customer_effort_score_tracks_data_constants__WEBPACK_IMPORTED_MODULE_11__ = __webpack_require__(55);
|
117 |
+
|
118 |
+
|
119 |
+
/**
|
120 |
+
* External dependencies
|
121 |
+
*/
|
122 |
+
|
123 |
+
|
124 |
+
|
125 |
+
|
126 |
+
|
127 |
+
|
128 |
+
|
129 |
+
|
130 |
+
|
131 |
+
|
132 |
+
/**
|
133 |
+
* Internal dependencies
|
134 |
+
*/
|
135 |
+
|
136 |
+
|
137 |
+
|
138 |
+
|
139 |
+
class ReportFilters extends _wordpress_element__WEBPACK_IMPORTED_MODULE_0__["Component"] {
|
140 |
+
constructor() {
|
141 |
+
super();
|
142 |
+
this.onDateSelect = this.onDateSelect.bind(this);
|
143 |
+
this.onFilterSelect = this.onFilterSelect.bind(this);
|
144 |
+
this.onAdvancedFilterAction = this.onAdvancedFilterAction.bind(this);
|
145 |
+
}
|
146 |
+
|
147 |
+
onDateSelect(data) {
|
148 |
+
const {
|
149 |
+
report,
|
150 |
+
addCesSurveyForAnalytics
|
151 |
+
} = this.props;
|
152 |
+
addCesSurveyForAnalytics();
|
153 |
+
Object(_woocommerce_tracks__WEBPACK_IMPORTED_MODULE_9__["recordEvent"])('datepicker_update', {
|
154 |
+
report,
|
155 |
+
...Object(lodash__WEBPACK_IMPORTED_MODULE_3__["omitBy"])(data, lodash__WEBPACK_IMPORTED_MODULE_3__["isUndefined"])
|
156 |
+
});
|
157 |
+
}
|
158 |
+
|
159 |
+
onFilterSelect(data) {
|
160 |
+
const {
|
161 |
+
report,
|
162 |
+
addCesSurveyForAnalytics
|
163 |
+
} = this.props; // This event gets triggered in the following cases.
|
164 |
+
// 1. Select "Single product" and choose a product.
|
165 |
+
// 2. Select "Comparison" or any other filter types.
|
166 |
+
// The comparsion and other filter types require a user to click
|
167 |
+
// a button to execute a query, so this is not a good place to
|
168 |
+
// trigger a CES survey for those.
|
169 |
+
|
170 |
+
const triggerCesFor = ['single_product', 'single_category', 'single_coupon', 'single_variation'];
|
171 |
+
const filterName = data.filter || data['filter-variations'];
|
172 |
+
|
173 |
+
if (triggerCesFor.includes(filterName)) {
|
174 |
+
addCesSurveyForAnalytics();
|
175 |
+
}
|
176 |
+
|
177 |
+
const eventProperties = {
|
178 |
+
report,
|
179 |
+
filter: data.filter || 'all'
|
180 |
+
};
|
181 |
+
|
182 |
+
if (data.filter === 'single_product') {
|
183 |
+
eventProperties.filter_variation = data['filter-variations'] || 'all';
|
184 |
+
}
|
185 |
+
|
186 |
+
Object(_woocommerce_tracks__WEBPACK_IMPORTED_MODULE_9__["recordEvent"])('analytics_filter', eventProperties);
|
187 |
+
}
|
188 |
+
|
189 |
+
onAdvancedFilterAction(action, data) {
|
190 |
+
const {
|
191 |
+
report,
|
192 |
+
addCesSurveyForAnalytics
|
193 |
+
} = this.props;
|
194 |
+
|
195 |
+
switch (action) {
|
196 |
+
case 'add':
|
197 |
+
Object(_woocommerce_tracks__WEBPACK_IMPORTED_MODULE_9__["recordEvent"])('analytics_filters_add', {
|
198 |
+
report,
|
199 |
+
filter: data.key
|
200 |
+
});
|
201 |
+
break;
|
202 |
+
|
203 |
+
case 'remove':
|
204 |
+
Object(_woocommerce_tracks__WEBPACK_IMPORTED_MODULE_9__["recordEvent"])('analytics_filters_remove', {
|
205 |
+
report,
|
206 |
+
filter: data.key
|
207 |
+
});
|
208 |
+
break;
|
209 |
+
|
210 |
+
case 'filter':
|
211 |
+
const snakeCaseData = Object.keys(data).reduce((result, property) => {
|
212 |
+
result[Object(lodash__WEBPACK_IMPORTED_MODULE_3__["snakeCase"])(property)] = data[property];
|
213 |
+
return result;
|
214 |
+
}, {});
|
215 |
+
addCesSurveyForAnalytics();
|
216 |
+
Object(_woocommerce_tracks__WEBPACK_IMPORTED_MODULE_9__["recordEvent"])('analytics_filters_filter', {
|
217 |
+
report,
|
218 |
+
...snakeCaseData
|
219 |
+
});
|
220 |
+
break;
|
221 |
+
|
222 |
+
case 'clear_all':
|
223 |
+
Object(_woocommerce_tracks__WEBPACK_IMPORTED_MODULE_9__["recordEvent"])('analytics_filters_clear_all', {
|
224 |
+
report
|
225 |
+
});
|
226 |
+
break;
|
227 |
+
|
228 |
+
case 'match':
|
229 |
+
Object(_woocommerce_tracks__WEBPACK_IMPORTED_MODULE_9__["recordEvent"])('analytics_filters_all_any', {
|
230 |
+
report,
|
231 |
+
value: data.match
|
232 |
+
});
|
233 |
+
break;
|
234 |
+
}
|
235 |
+
}
|
236 |
+
|
237 |
+
render() {
|
238 |
+
const {
|
239 |
+
advancedFilters,
|
240 |
+
filters,
|
241 |
+
path,
|
242 |
+
query,
|
243 |
+
showDatePicker,
|
244 |
+
defaultDateRange
|
245 |
+
} = this.props;
|
246 |
+
const {
|
247 |
+
period,
|
248 |
+
compare,
|
249 |
+
before,
|
250 |
+
after
|
251 |
+
} = Object(_woocommerce_date__WEBPACK_IMPORTED_MODULE_8__["getDateParamsFromQuery"])(query, defaultDateRange);
|
252 |
+
const {
|
253 |
+
primary: primaryDate,
|
254 |
+
secondary: secondaryDate
|
255 |
+
} = Object(_woocommerce_date__WEBPACK_IMPORTED_MODULE_8__["getCurrentDates"])(query, defaultDateRange);
|
256 |
+
const dateQuery = {
|
257 |
+
period,
|
258 |
+
compare,
|
259 |
+
before,
|
260 |
+
after,
|
261 |
+
primaryDate,
|
262 |
+
secondaryDate
|
263 |
+
};
|
264 |
+
const Currency = this.context;
|
265 |
+
return Object(_wordpress_element__WEBPACK_IMPORTED_MODULE_0__["createElement"])(_woocommerce_components__WEBPACK_IMPORTED_MODULE_5__["ReportFilters"], {
|
266 |
+
query: query,
|
267 |
+
siteLocale: _woocommerce_wc_admin_settings__WEBPACK_IMPORTED_MODULE_6__[/* LOCALE */ "b"].siteLocale,
|
268 |
+
currency: Currency.getCurrencyConfig(),
|
269 |
+
path: path,
|
270 |
+
filters: filters,
|
271 |
+
advancedFilters: advancedFilters,
|
272 |
+
showDatePicker: showDatePicker,
|
273 |
+
onDateSelect: this.onDateSelect,
|
274 |
+
onFilterSelect: this.onFilterSelect,
|
275 |
+
onAdvancedFilterAction: this.onAdvancedFilterAction,
|
276 |
+
dateQuery: dateQuery,
|
277 |
+
isoDateFormat: _woocommerce_date__WEBPACK_IMPORTED_MODULE_8__["isoDateFormat"]
|
278 |
+
});
|
279 |
+
}
|
280 |
+
|
281 |
+
}
|
282 |
+
|
283 |
+
ReportFilters.contextType = _lib_currency_context__WEBPACK_IMPORTED_MODULE_10__[/* CurrencyContext */ "a"];
|
284 |
+
/* harmony default export */ __webpack_exports__["a"] = (Object(_wordpress_compose__WEBPACK_IMPORTED_MODULE_1__["compose"])(Object(_wordpress_data__WEBPACK_IMPORTED_MODULE_4__["withSelect"])(select => {
|
285 |
+
const {
|
286 |
+
woocommerce_default_date_range: defaultDateRange
|
287 |
+
} = select(_woocommerce_data__WEBPACK_IMPORTED_MODULE_7__["SETTINGS_STORE_NAME"]).getSetting('wc_admin', 'wcAdminSettings');
|
288 |
+
return {
|
289 |
+
defaultDateRange
|
290 |
+
};
|
291 |
+
}), Object(_wordpress_data__WEBPACK_IMPORTED_MODULE_4__["withDispatch"])(dispatch => {
|
292 |
+
const {
|
293 |
+
addCesSurveyForAnalytics
|
294 |
+
} = dispatch(_customer_effort_score_tracks_data_constants__WEBPACK_IMPORTED_MODULE_11__[/* STORE_KEY */ "c"]);
|
295 |
+
return {
|
296 |
+
addCesSurveyForAnalytics
|
297 |
+
};
|
298 |
+
}))(ReportFilters));
|
299 |
+
ReportFilters.propTypes = {
|
300 |
+
/**
|
301 |
+
* Config option passed through to `AdvancedFilters`
|
302 |
+
*/
|
303 |
+
advancedFilters: prop_types__WEBPACK_IMPORTED_MODULE_2___default.a.object,
|
304 |
+
|
305 |
+
/**
|
306 |
+
* Config option passed through to `FilterPicker` - if not used, `FilterPicker` is not displayed.
|
307 |
+
*/
|
308 |
+
filters: prop_types__WEBPACK_IMPORTED_MODULE_2___default.a.array,
|
309 |
+
|
310 |
+
/**
|
311 |
+
* The `path` parameter supplied by React-Router
|
312 |
+
*/
|
313 |
+
path: prop_types__WEBPACK_IMPORTED_MODULE_2___default.a.string.isRequired,
|
314 |
+
|
315 |
+
/**
|
316 |
+
* The query string represented in object form
|
317 |
+
*/
|
318 |
+
query: prop_types__WEBPACK_IMPORTED_MODULE_2___default.a.object,
|
319 |
+
|
320 |
+
/**
|
321 |
+
* Whether the date picker must be shown..
|
322 |
+
*/
|
323 |
+
showDatePicker: prop_types__WEBPACK_IMPORTED_MODULE_2___default.a.bool,
|
324 |
+
|
325 |
+
/**
|
326 |
+
* The report where filter are placed.
|
327 |
+
*/
|
328 |
+
report: prop_types__WEBPACK_IMPORTED_MODULE_2___default.a.string.isRequired
|
329 |
+
};
|
330 |
+
|
331 |
+
/***/ }),
|
332 |
+
|
333 |
+
/***/ 509:
|
334 |
+
/***/ (function(module, __webpack_exports__, __webpack_require__) {
|
335 |
+
|
336 |
+
"use strict";
|
337 |
+
|
338 |
+
// EXTERNAL MODULE: ./node_modules/@babel/runtime/helpers/extends.js
|
339 |
+
var helpers_extends = __webpack_require__(36);
|
340 |
+
var extends_default = /*#__PURE__*/__webpack_require__.n(helpers_extends);
|
341 |
+
|
342 |
+
// EXTERNAL MODULE: external ["wp","element"]
|
343 |
+
var external_wp_element_ = __webpack_require__(0);
|
344 |
+
|
345 |
+
// EXTERNAL MODULE: external ["wp","components"]
|
346 |
+
var external_wp_components_ = __webpack_require__(3);
|
347 |
+
|
348 |
+
// EXTERNAL MODULE: external ["wp","hooks"]
|
349 |
+
var external_wp_hooks_ = __webpack_require__(31);
|
350 |
+
|
351 |
+
// EXTERNAL MODULE: external ["wp","compose"]
|
352 |
+
var external_wp_compose_ = __webpack_require__(14);
|
353 |
+
|
354 |
+
// EXTERNAL MODULE: external ["wp","dom"]
|
355 |
+
var external_wp_dom_ = __webpack_require__(91);
|
356 |
+
|
357 |
+
// EXTERNAL MODULE: external ["wp","data"]
|
358 |
+
var external_wp_data_ = __webpack_require__(7);
|
359 |
+
|
360 |
+
// EXTERNAL MODULE: external "lodash"
|
361 |
+
var external_lodash_ = __webpack_require__(4);
|
362 |
+
|
363 |
+
// EXTERNAL MODULE: external ["wp","i18n"]
|
364 |
+
var external_wp_i18n_ = __webpack_require__(2);
|
365 |
+
|
366 |
+
// EXTERNAL MODULE: ./node_modules/prop-types/index.js
|
367 |
+
var prop_types = __webpack_require__(1);
|
368 |
+
var prop_types_default = /*#__PURE__*/__webpack_require__.n(prop_types);
|
369 |
+
|
370 |
+
// EXTERNAL MODULE: external ["wc","components"]
|
371 |
+
var external_wc_components_ = __webpack_require__(21);
|
372 |
+
|
373 |
+
// EXTERNAL MODULE: external ["wc","navigation"]
|
374 |
+
var external_wc_navigation_ = __webpack_require__(12);
|
375 |
+
|
376 |
+
// EXTERNAL MODULE: external ["wc","csvExport"]
|
377 |
+
var external_wc_csvExport_ = __webpack_require__(476);
|
378 |
+
|
379 |
+
// EXTERNAL MODULE: external ["wc","data"]
|
380 |
+
var external_wc_data_ = __webpack_require__(11);
|
381 |
+
|
382 |
+
// EXTERNAL MODULE: external ["wc","tracks"]
|
383 |
+
var external_wc_tracks_ = __webpack_require__(15);
|
384 |
+
|
385 |
+
// CONCATENATED MODULE: ./client/analytics/components/report-table/download-icon.js
|
386 |
+
|
387 |
+
/* harmony default export */ var download_icon = (() => Object(external_wp_element_["createElement"])("svg", {
|
388 |
+
role: "img",
|
389 |
+
"aria-hidden": "true",
|
390 |
+
focusable: "false",
|
391 |
+
version: "1.1",
|
392 |
+
xmlns: "http://www.w3.org/2000/svg",
|
393 |
+
x: "0px",
|
394 |
+
y: "0px",
|
395 |
+
viewBox: "0 0 24 24"
|
396 |
+
}, Object(external_wp_element_["createElement"])("path", {
|
397 |
+
d: "M18,9c-0.009,0-0.017,0.002-0.025,0.003C17.72,5.646,14.922,3,11.5,3C7.91,3,5,5.91,5,9.5c0,0.524,0.069,1.031,0.186,1.519 C5.123,11.016,5.064,11,5,11c-2.209,0-4,1.791-4,4c0,1.202,0.541,2.267,1.38,3h18.593C22.196,17.089,23,15.643,23,14 C23,11.239,20.761,9,18,9z M12,16l-4-5h3V8h2v3h3L12,16z"
|
398 |
+
})));
|
399 |
+
// EXTERNAL MODULE: ./client/analytics/components/report-error/index.js
|
400 |
+
var report_error = __webpack_require__(506);
|
401 |
+
|
402 |
+
// CONCATENATED MODULE: ./client/analytics/components/report-table/utils.js
|
403 |
+
/**
|
404 |
+
* External dependencies
|
405 |
+
*/
|
406 |
+
|
407 |
+
function extendTableData(extendedStoreSelector, props, queriedTableData) {
|
408 |
+
const {
|
409 |
+
extendItemsMethodNames,
|
410 |
+
itemIdField
|
411 |
+
} = props;
|
412 |
+
const itemsData = queriedTableData.items.data;
|
413 |
+
|
414 |
+
if (!Array.isArray(itemsData) || !itemsData.length || !extendItemsMethodNames || !itemIdField) {
|
415 |
+
return queriedTableData;
|
416 |
+
}
|
417 |
+
|
418 |
+
const {
|
419 |
+
[extendItemsMethodNames.getError]: getErrorMethod,
|
420 |
+
[extendItemsMethodNames.isRequesting]: isRequestingMethod,
|
421 |
+
[extendItemsMethodNames.load]: loadMethod
|
422 |
+
} = extendedStoreSelector;
|
423 |
+
const extendQuery = {
|
424 |
+
include: itemsData.map(item => item[itemIdField]).join(','),
|
425 |
+
per_page: itemsData.length
|
426 |
+
};
|
427 |
+
const extendedItems = loadMethod(extendQuery);
|
428 |
+
const isExtendedItemsRequesting = isRequestingMethod ? isRequestingMethod(extendQuery) : false;
|
429 |
+
const isExtendedItemsError = getErrorMethod ? getErrorMethod(extendQuery) : false;
|
430 |
+
const extendedItemsData = itemsData.map(item => {
|
431 |
+
const extendedItemData = Object(external_lodash_["first"])(extendedItems.filter(extendedItem => item.id === extendedItem.id));
|
432 |
+
return { ...item,
|
433 |
+
...extendedItemData
|
434 |
+
};
|
435 |
+
});
|
436 |
+
const isRequesting = queriedTableData.isRequesting || isExtendedItemsRequesting;
|
437 |
+
const isError = queriedTableData.isError || isExtendedItemsError;
|
438 |
+
return { ...queriedTableData,
|
439 |
+
isRequesting,
|
440 |
+
isError,
|
441 |
+
items: { ...queriedTableData.items,
|
442 |
+
data: extendedItemsData
|
443 |
+
}
|
444 |
+
};
|
445 |
+
}
|
446 |
+
// EXTERNAL MODULE: ./client/customer-effort-score-tracks/data/constants.js
|
447 |
+
var constants = __webpack_require__(55);
|
448 |
+
|
449 |
+
// EXTERNAL MODULE: ./client/analytics/components/report-table/style.scss
|
450 |
+
var style = __webpack_require__(518);
|
451 |
+
|
452 |
+
// CONCATENATED MODULE: ./client/analytics/components/report-table/index.js
|
453 |
+
|
454 |
+
|
455 |
+
|
456 |
+
/**
|
457 |
+
* External dependencies
|
458 |
+
*/
|
459 |
+
|
460 |
+
|
461 |
+
|
462 |
+
|
463 |
+
|
464 |
+
|
465 |
+
|
466 |
+
|
467 |
+
|
468 |
+
|
469 |
+
|
470 |
+
|
471 |
+
|
472 |
+
|
473 |
+
/**
|
474 |
+
* Internal dependencies
|
475 |
+
*/
|
476 |
+
|
477 |
+
|
478 |
+
|
479 |
+
|
480 |
+
|
481 |
+
|
482 |
+
const TABLE_FILTER = 'woocommerce_admin_report_table';
|
483 |
+
|
484 |
+
const ReportTable = props => {
|
485 |
+
const {
|
486 |
+
getHeadersContent,
|
487 |
+
getRowsContent,
|
488 |
+
getSummary,
|
489 |
+
isRequesting,
|
490 |
+
primaryData,
|
491 |
+
tableData,
|
492 |
+
endpoint,
|
493 |
+
// These props are not used in the render function, but are destructured
|
494 |
+
// so they are not included in the `tableProps` variable.
|
495 |
+
// eslint-disable-next-line no-unused-vars
|
496 |
+
itemIdField,
|
497 |
+
// eslint-disable-next-line no-unused-vars
|
498 |
+
tableQuery,
|
499 |
+
compareBy,
|
500 |
+
compareParam,
|
501 |
+
searchBy,
|
502 |
+
labels = {},
|
503 |
+
...tableProps
|
504 |
+
} = props; // Pull these props out separately because they need to be included in tableProps.
|
505 |
+
|
506 |
+
const {
|
507 |
+
query,
|
508 |
+
columnPrefsKey
|
509 |
+
} = props;
|
510 |
+
const {
|
511 |
+
items,
|
512 |
+
query: reportQuery
|
513 |
+
} = tableData;
|
514 |
+
const initialSelectedRows = query[compareParam] ? Object(external_wc_navigation_["getIdsFromQuery"])(query[compareBy]) : [];
|
515 |
+
const [selectedRows, setSelectedRows] = Object(external_wp_element_["useState"])(initialSelectedRows);
|
516 |
+
const scrollPointRef = Object(external_wp_element_["useRef"])(null);
|
517 |
+
const {
|
518 |
+
updateUserPreferences,
|
519 |
+
...userData
|
520 |
+
} = Object(external_wc_data_["useUserPreferences"])(); // Bail early if we've encountered an error.
|
521 |
+
|
522 |
+
const isError = tableData.isError || primaryData.isError;
|
523 |
+
|
524 |
+
if (isError) {
|
525 |
+
return Object(external_wp_element_["createElement"])(report_error["a" /* default */], null);
|
526 |
+
}
|
527 |
+
|
528 |
+
let userPrefColumns = [];
|
529 |
+
|
530 |
+
if (columnPrefsKey) {
|
531 |
+
userPrefColumns = userData && userData[columnPrefsKey] ? userData[columnPrefsKey] : userPrefColumns;
|
532 |
+
}
|
533 |
+
|
534 |
+
const onPageChange = (newPage, source) => {
|
535 |
+
scrollPointRef.current.scrollIntoView();
|
536 |
+
const tableElement = scrollPointRef.current.nextSibling.querySelector('.woocommerce-table__table');
|
537 |
+
const focusableElements = external_wp_dom_["focus"].focusable.find(tableElement);
|
538 |
+
|
539 |
+
if (focusableElements.length) {
|
540 |
+
focusableElements[0].focus();
|
541 |
+
}
|
542 |
+
|
543 |
+
if (source) {
|
544 |
+
if (source === 'goto') {
|
545 |
+
Object(external_wc_tracks_["recordEvent"])('analytics_table_go_to_page', {
|
546 |
+
report: endpoint,
|
547 |
+
page: newPage
|
548 |
+
});
|
549 |
+
} else {
|
550 |
+
Object(external_wc_tracks_["recordEvent"])('analytics_table_page_click', {
|
551 |
+
report: endpoint,
|
552 |
+
direction: source
|
553 |
+
});
|
554 |
+
}
|
555 |
+
}
|
556 |
+
};
|
557 |
+
|
558 |
+
const trackTableSearch = () => {
|
559 |
+
// @todo: decide if this should only fire for new tokens (not any/all changes).
|
560 |
+
Object(external_wc_tracks_["recordEvent"])('analytics_table_filter', {
|
561 |
+
report: endpoint
|
562 |
+
});
|
563 |
+
};
|
564 |
+
|
565 |
+
const onSort = (key, direction) => {
|
566 |
+
Object(external_wc_navigation_["onQueryChange"])('sort')(key, direction);
|
567 |
+
const eventProps = {
|
568 |
+
report: endpoint,
|
569 |
+
column: key,
|
570 |
+
direction
|
571 |
+
};
|
572 |
+
Object(external_wc_tracks_["recordEvent"])('analytics_table_sort', eventProps);
|
573 |
+
};
|
574 |
+
|
575 |
+
const filterShownHeaders = (headers, hiddenKeys) => {
|
576 |
+
// If no user preferences, set visibilty based on column default.
|
577 |
+
if (!hiddenKeys) {
|
578 |
+
return headers.map(header => ({ ...header,
|
579 |
+
visible: header.required || !header.hiddenByDefault
|
580 |
+
}));
|
581 |
+
} // Set visibilty based on user preferences.
|
582 |
+
|
583 |
+
|
584 |
+
return headers.map(header => ({ ...header,
|
585 |
+
visible: header.required || !hiddenKeys.includes(header.key)
|
586 |
+
}));
|
587 |
+
};
|
588 |
+
|
589 |
+
const applyTableFilters = (data, totals, totalResults) => {
|
590 |
+
const summary = getSummary ? getSummary(totals, totalResults) : null;
|
591 |
+
/**
|
592 |
+
* Filter report table for the CSV download.
|
593 |
+
*
|
594 |
+
* Enables manipulation of data used to create the report CSV.
|
595 |
+
*
|
596 |
+
* @param {Object} reportTableData - data used to create the table.
|
597 |
+
* @param {string} reportTableData.endpoint - table api endpoint.
|
598 |
+
* @param {Array} reportTableData.headers - table headers data.
|
599 |
+
* @param {Array} reportTableData.rows - table rows data.
|
600 |
+
* @param {Object} reportTableData.totals - total aggregates for request.
|
601 |
+
* @param {Array} reportTableData.summary - summary numbers data.
|
602 |
+
* @param {Object} reportTableData.items - response from api requerst.
|
603 |
+
*/
|
604 |
+
|
605 |
+
return Object(external_wp_hooks_["applyFilters"])(TABLE_FILTER, {
|
606 |
+
endpoint,
|
607 |
+
headers: getHeadersContent(),
|
608 |
+
rows: getRowsContent(data),
|
609 |
+
totals,
|
610 |
+
summary,
|
611 |
+
items
|
612 |
+
});
|
613 |
+
};
|
614 |
+
|
615 |
+
const onClickDownload = () => {
|
616 |
+
const {
|
617 |
+
createNotice,
|
618 |
+
startExport,
|
619 |
+
title
|
620 |
+
} = props;
|
621 |
+
const params = Object.assign({}, query);
|
622 |
+
const {
|
623 |
+
data,
|
624 |
+
totalResults
|
625 |
+
} = items;
|
626 |
+
let downloadType = 'browser'; // Delete unnecessary items from filename.
|
627 |
+
|
628 |
+
delete params.extended_info;
|
629 |
+
|
630 |
+
if (params.search) {
|
631 |
+
delete params[searchBy];
|
632 |
+
}
|
633 |
+
|
634 |
+
if (data && data.length === totalResults) {
|
635 |
+
const {
|
636 |
+
headers,
|
637 |
+
rows
|
638 |
+
} = applyTableFilters(data, totalResults);
|
639 |
+
Object(external_wc_csvExport_["downloadCSVFile"])(Object(external_wc_csvExport_["generateCSVFileName"])(title, params), Object(external_wc_csvExport_["generateCSVDataFromTable"])(headers, rows));
|
640 |
+
} else {
|
641 |
+
downloadType = 'email';
|
642 |
+
startExport(endpoint, reportQuery).then(() => createNotice('success', Object(external_wp_i18n_["sprintf"])(
|
643 |
+
/* translators: %s = type of report */
|
644 |
+
Object(external_wp_i18n_["__"])('Your %s Report will be emailed to you.', 'woocommerce-admin'), title))).catch(error => createNotice('error', error.message || Object(external_wp_i18n_["sprintf"])(
|
645 |
+
/* translators: %s = type of report */
|
646 |
+
Object(external_wp_i18n_["__"])('There was a problem exporting your %s Report. Please try again.', 'woocommerce-admin'), title)));
|
647 |
+
}
|
648 |
+
|
649 |
+
Object(external_wc_tracks_["recordEvent"])('analytics_table_download', {
|
650 |
+
report: endpoint,
|
651 |
+
rows: totalResults,
|
652 |
+
download_type: downloadType
|
653 |
+
});
|
654 |
+
};
|
655 |
+
|
656 |
+
const onCompare = () => {
|
657 |
+
if (compareBy) {
|
658 |
+
Object(external_wc_navigation_["onQueryChange"])('compare')(compareBy, compareParam, selectedRows.join(','));
|
659 |
+
}
|
660 |
+
};
|
661 |
+
|
662 |
+
const onSearchChange = values => {
|
663 |
+
const {
|
664 |
+
baseSearchQuery,
|
665 |
+
addCesSurveyForCustomerSearch
|
666 |
+
} = props; // A comma is used as a separator between search terms, so we want to escape
|
667 |
+
// any comma they contain.
|
668 |
+
|
669 |
+
const searchTerms = values.map(v => v.label.replace(',', '%2C'));
|
670 |
+
|
671 |
+
if (searchTerms.length) {
|
672 |
+
Object(external_wc_navigation_["updateQueryString"])({
|
673 |
+
filter: undefined,
|
674 |
+
[compareParam]: undefined,
|
675 |
+
[searchBy]: undefined,
|
676 |
+
...baseSearchQuery,
|
677 |
+
search: Object(external_lodash_["uniq"])(searchTerms).join(',')
|
678 |
+
}); // Prompt survey if user is searching for something.
|
679 |
+
|
680 |
+
addCesSurveyForCustomerSearch();
|
681 |
+
} else {
|
682 |
+
Object(external_wc_navigation_["updateQueryString"])({
|
683 |
+
search: undefined
|
684 |
+
});
|
685 |
+
}
|
686 |
+
|
687 |
+
trackTableSearch();
|
688 |
+
};
|
689 |
+
|
690 |
+
const selectAllRows = checked => {
|
691 |
+
const {
|
692 |
+
ids
|
693 |
+
} = props;
|
694 |
+
setSelectedRows(checked ? ids : []);
|
695 |
+
};
|
696 |
+
|
697 |
+
const selectRow = (i, checked) => {
|
698 |
+
const {
|
699 |
+
ids
|
700 |
+
} = props;
|
701 |
+
|
702 |
+
if (checked) {
|
703 |
+
setSelectedRows(Object(external_lodash_["uniq"])([ids[i], ...selectedRows]));
|
704 |
+
} else {
|
705 |
+
const index = selectedRows.indexOf(ids[i]);
|
706 |
+
setSelectedRows([...selectedRows.slice(0, index), ...selectedRows.slice(index + 1)]);
|
707 |
+
}
|
708 |
+
};
|
709 |
+
|
710 |
+
const getCheckbox = i => {
|
711 |
+
const {
|
712 |
+
ids = []
|
713 |
+
} = props;
|
714 |
+
const isChecked = selectedRows.indexOf(ids[i]) !== -1;
|
715 |
+
return {
|
716 |
+
display: Object(external_wp_element_["createElement"])(external_wp_components_["CheckboxControl"], {
|
717 |
+
onChange: Object(external_lodash_["partial"])(selectRow, i),
|
718 |
+
checked: isChecked
|
719 |
+
}),
|
720 |
+
value: false
|
721 |
+
};
|
722 |
+
};
|
723 |
+
|
724 |
+
const getAllCheckbox = () => {
|
725 |
+
const {
|
726 |
+
ids = []
|
727 |
+
} = props;
|
728 |
+
const hasData = ids.length > 0;
|
729 |
+
const isAllChecked = hasData && ids.length === selectedRows.length;
|
730 |
+
return {
|
731 |
+
cellClassName: 'is-checkbox-column',
|
732 |
+
key: 'compare',
|
733 |
+
label: Object(external_wp_element_["createElement"])(external_wp_components_["CheckboxControl"], {
|
734 |
+
onChange: selectAllRows,
|
735 |
+
"aria-label": Object(external_wp_i18n_["__"])('Select All'),
|
736 |
+
checked: isAllChecked,
|
737 |
+
disabled: !hasData
|
738 |
+
}),
|
739 |
+
required: true
|
740 |
+
};
|
741 |
+
};
|
742 |
+
|
743 |
+
const isLoading = isRequesting || tableData.isRequesting || primaryData.isRequesting;
|
744 |
+
const totals = Object(external_lodash_["get"])(primaryData, ['data', 'totals'], {});
|
745 |
+
const totalResults = items.totalResults || 0;
|
746 |
+
const downloadable = totalResults > 0; // Search words are in the query string, not the table query.
|
747 |
+
|
748 |
+
const searchWords = Object(external_wc_navigation_["getSearchWords"])(query);
|
749 |
+
const searchedLabels = searchWords.map(v => ({
|
750 |
+
key: v,
|
751 |
+
label: v
|
752 |
+
}));
|
753 |
+
const {
|
754 |
+
data
|
755 |
+
} = items;
|
756 |
+
const applyTableFiltersResult = applyTableFilters(data, totals, totalResults);
|
757 |
+
let {
|
758 |
+
headers,
|
759 |
+
rows
|
760 |
+
} = applyTableFiltersResult;
|
761 |
+
const {
|
762 |
+
summary
|
763 |
+
} = applyTableFiltersResult;
|
764 |
+
|
765 |
+
const onColumnsChange = (shownColumns, toggledColumn) => {
|
766 |
+
const columns = headers.map(header => header.key);
|
767 |
+
const hiddenColumns = columns.filter(column => !shownColumns.includes(column));
|
768 |
+
|
769 |
+
if (columnPrefsKey) {
|
770 |
+
const userDataFields = {
|
771 |
+
[columnPrefsKey]: hiddenColumns
|
772 |
+
};
|
773 |
+
updateUserPreferences(userDataFields);
|
774 |
+
}
|
775 |
+
|
776 |
+
if (toggledColumn) {
|
777 |
+
const eventProps = {
|
778 |
+
report: endpoint,
|
779 |
+
column: toggledColumn,
|
780 |
+
status: shownColumns.includes(toggledColumn) ? 'on' : 'off'
|
781 |
+
};
|
782 |
+
Object(external_wc_tracks_["recordEvent"])('analytics_table_header_toggle', eventProps);
|
783 |
+
}
|
784 |
+
}; // Add in selection for comparisons.
|
785 |
+
|
786 |
+
|
787 |
+
if (compareBy) {
|
788 |
+
rows = rows.map((row, i) => {
|
789 |
+
return [getCheckbox(i), ...row];
|
790 |
+
});
|
791 |
+
headers = [getAllCheckbox(), ...headers];
|
792 |
+
} // Hide any headers based on user prefs, if loaded.
|
793 |
+
|
794 |
+
|
795 |
+
const filteredHeaders = filterShownHeaders(headers, userPrefColumns);
|
796 |
+
return Object(external_wp_element_["createElement"])(external_wp_element_["Fragment"], null, Object(external_wp_element_["createElement"])("div", {
|
797 |
+
className: "woocommerce-report-table__scroll-point",
|
798 |
+
ref: scrollPointRef,
|
799 |
+
"aria-hidden": true
|
800 |
+
}), Object(external_wp_element_["createElement"])(external_wc_components_["TableCard"], extends_default()({
|
801 |
+
className: 'woocommerce-report-table',
|
802 |
+
hasSearch: !!searchBy,
|
803 |
+
actions: [compareBy && Object(external_wp_element_["createElement"])(external_wc_components_["CompareButton"], {
|
804 |
+
key: "compare",
|
805 |
+
className: "woocommerce-table__compare",
|
806 |
+
count: selectedRows.length,
|
807 |
+
helpText: labels.helpText || Object(external_wp_i18n_["__"])('Check at least two items below to compare', 'woocommerce-admin'),
|
808 |
+
onClick: onCompare,
|
809 |
+
disabled: !downloadable
|
810 |
+
}, labels.compareButton || Object(external_wp_i18n_["__"])('Compare', 'woocommerce-admin')), searchBy && Object(external_wp_element_["createElement"])(external_wc_components_["Search"], {
|
811 |
+
allowFreeTextSearch: true,
|
812 |
+
inlineTags: true,
|
813 |
+
key: "search",
|
814 |
+
onChange: onSearchChange,
|
815 |
+
placeholder: labels.placeholder || Object(external_wp_i18n_["__"])('Search by item name', 'woocommerce-admin'),
|
816 |
+
selected: searchedLabels,
|
817 |
+
showClearButton: true,
|
818 |
+
type: searchBy,
|
819 |
+
disabled: !downloadable
|
820 |
+
}), downloadable && Object(external_wp_element_["createElement"])(external_wp_components_["Button"], {
|
821 |
+
key: "download",
|
822 |
+
className: "woocommerce-table__download-button",
|
823 |
+
disabled: isLoading,
|
824 |
+
onClick: onClickDownload
|
825 |
+
}, Object(external_wp_element_["createElement"])(download_icon, null), Object(external_wp_element_["createElement"])("span", {
|
826 |
+
className: "woocommerce-table__download-button__label"
|
827 |
+
}, labels.downloadButton || Object(external_wp_i18n_["__"])('Download', 'woocommerce-admin')))],
|
828 |
+
headers: filteredHeaders,
|
829 |
+
isLoading: isLoading,
|
830 |
+
onQueryChange: external_wc_navigation_["onQueryChange"],
|
831 |
+
onColumnsChange: onColumnsChange,
|
832 |
+
onSort: onSort,
|
833 |
+
onPageChange: onPageChange,
|
834 |
+
rows: rows,
|
835 |
+
rowsPerPage: parseInt(reportQuery.per_page, 10) || external_wc_data_["QUERY_DEFAULTS"].pageSize,
|
836 |
+
summary: summary,
|
837 |
+
totalRows: totalResults
|
838 |
+
}, tableProps)));
|
839 |
+
};
|
840 |
+
|
841 |
+
ReportTable.propTypes = {
|
842 |
+
/**
|
843 |
+
* Pass in query parameters to be included in the path when onSearch creates a new url.
|
844 |
+
*/
|
845 |
+
baseSearchQuery: prop_types_default.a.object,
|
846 |
+
|
847 |
+
/**
|
848 |
+
* The string to use as a query parameter when comparing row items.
|
849 |
+
*/
|
850 |
+
compareBy: prop_types_default.a.string,
|
851 |
+
|
852 |
+
/**
|
853 |
+
* Url query parameter compare function operates on
|
854 |
+
*/
|
855 |
+
compareParam: prop_types_default.a.string,
|
856 |
+
|
857 |
+
/**
|
858 |
+
* The key for user preferences settings for column visibility.
|
859 |
+
*/
|
860 |
+
columnPrefsKey: prop_types_default.a.string,
|
861 |
+
|
862 |
+
/**
|
863 |
+
* The endpoint to use in API calls to populate the table rows and summary.
|
864 |
+
* For example, if `taxes` is provided, data will be fetched from the report
|
865 |
+
* `taxes` endpoint (ie: `/wc-analytics/reports/taxes` and `/wc/v4/reports/taxes/stats`).
|
866 |
+
* If the provided endpoint doesn't exist, an error will be shown to the user
|
867 |
+
* with `ReportError`.
|
868 |
+
*/
|
869 |
+
endpoint: prop_types_default.a.string,
|
870 |
+
|
871 |
+
/**
|
872 |
+
* Name of the methods available via `select` that will be used to
|
873 |
+
* load more data for table items. If omitted, no call will be made and only
|
874 |
+
* the data returned by the reports endpoint will be used.
|
875 |
+
*/
|
876 |
+
extendItemsMethodNames: prop_types_default.a.shape({
|
877 |
+
getError: prop_types_default.a.string,
|
878 |
+
isRequesting: prop_types_default.a.string,
|
879 |
+
load: prop_types_default.a.string
|
880 |
+
}),
|
881 |
+
|
882 |
+
/**
|
883 |
+
* Name of store on which extendItemsMethodNames can be found.
|
884 |
+
*/
|
885 |
+
extendedItemsStoreName: prop_types_default.a.string,
|
886 |
+
|
887 |
+
/**
|
888 |
+
* A function that returns the headers object to build the table.
|
889 |
+
*/
|
890 |
+
getHeadersContent: prop_types_default.a.func.isRequired,
|
891 |
+
|
892 |
+
/**
|
893 |
+
* A function that returns the rows array to build the table.
|
894 |
+
*/
|
895 |
+
getRowsContent: prop_types_default.a.func.isRequired,
|
896 |
+
|
897 |
+
/**
|
898 |
+
* A function that returns the summary object to build the table.
|
899 |
+
*/
|
900 |
+
getSummary: prop_types_default.a.func,
|
901 |
+
|
902 |
+
/**
|
903 |
+
* The name of the property in the item object which contains the id.
|
904 |
+
*/
|
905 |
+
itemIdField: prop_types_default.a.string,
|
906 |
+
|
907 |
+
/**
|
908 |
+
* Custom labels for table header actions.
|
909 |
+
*/
|
910 |
+
labels: prop_types_default.a.shape({
|
911 |
+
compareButton: prop_types_default.a.string,
|
912 |
+
downloadButton: prop_types_default.a.string,
|
913 |
+
helpText: prop_types_default.a.string,
|
914 |
+
placeholder: prop_types_default.a.string
|
915 |
+
}),
|
916 |
+
|
917 |
+
/**
|
918 |
+
* Primary data of that report. If it's not provided, it will be automatically
|
919 |
+
* loaded via the provided `endpoint`.
|
920 |
+
*/
|
921 |
+
primaryData: prop_types_default.a.object,
|
922 |
+
|
923 |
+
/**
|
924 |
+
* The string to use as a query parameter when searching row items.
|
925 |
+
*/
|
926 |
+
searchBy: prop_types_default.a.string,
|
927 |
+
|
928 |
+
/**
|
929 |
+
* List of fields used for summary numbers. (Reduces queries)
|
930 |
+
*/
|
931 |
+
summaryFields: prop_types_default.a.arrayOf(prop_types_default.a.string),
|
932 |
+
|
933 |
+
/**
|
934 |
+
* Table data of that report. If it's not provided, it will be automatically
|
935 |
+
* loaded via the provided `endpoint`.
|
936 |
+
*/
|
937 |
+
tableData: prop_types_default.a.object.isRequired,
|
938 |
+
|
939 |
+
/**
|
940 |
+
* Properties to be added to the query sent to the report table endpoint.
|
941 |
+
*/
|
942 |
+
tableQuery: prop_types_default.a.object,
|
943 |
+
|
944 |
+
/**
|
945 |
+
* String to display as the title of the table.
|
946 |
+
*/
|
947 |
+
title: prop_types_default.a.string.isRequired
|
948 |
+
};
|
949 |
+
ReportTable.defaultProps = {
|
950 |
+
primaryData: {},
|
951 |
+
tableData: {
|
952 |
+
items: {
|
953 |
+
data: [],
|
954 |
+
totalResults: 0
|
955 |
+
},
|
956 |
+
query: {}
|
957 |
+
},
|
958 |
+
tableQuery: {},
|
959 |
+
compareParam: 'filter',
|
960 |
+
downloadable: false,
|
961 |
+
onSearch: external_lodash_["noop"],
|
962 |
+
baseSearchQuery: {}
|
963 |
+
};
|
964 |
+
const EMPTY_ARRAY = [];
|
965 |
+
const EMPTY_OBJECT = {};
|
966 |
+
/* harmony default export */ var report_table = __webpack_exports__["a"] = (Object(external_wp_compose_["compose"])(Object(external_wp_data_["withSelect"])((select, props) => {
|
967 |
+
const {
|
968 |
+
endpoint,
|
969 |
+
getSummary,
|
970 |
+
isRequesting,
|
971 |
+
itemIdField,
|
972 |
+
query,
|
973 |
+
tableData,
|
974 |
+
tableQuery,
|
975 |
+
filters,
|
976 |
+
advancedFilters,
|
977 |
+
summaryFields,
|
978 |
+
extendedItemsStoreName
|
979 |
+
} = props;
|
980 |
+
/* eslint @wordpress/no-unused-vars-before-return: "off" */
|
981 |
+
|
982 |
+
const reportStoreSelector = select(external_wc_data_["REPORTS_STORE_NAME"]);
|
983 |
+
const extendedStoreSelector = extendedItemsStoreName ? select(extendedItemsStoreName) : null;
|
984 |
+
const {
|
985 |
+
woocommerce_default_date_range: defaultDateRange
|
986 |
+
} = select(external_wc_data_["SETTINGS_STORE_NAME"]).getSetting('wc_admin', 'wcAdminSettings');
|
987 |
+
|
988 |
+
if (isRequesting) {
|
989 |
+
return EMPTY_OBJECT;
|
990 |
+
} // Category charts are powered by the /reports/products/stats endpoint.
|
991 |
+
|
992 |
+
|
993 |
+
const chartEndpoint = endpoint === 'categories' ? 'products' : endpoint;
|
994 |
+
const primaryData = getSummary ? Object(external_wc_data_["getReportChartData"])({
|
995 |
+
endpoint: chartEndpoint,
|
996 |
+
selector: reportStoreSelector,
|
997 |
+
dataType: 'primary',
|
998 |
+
query,
|
999 |
+
filters,
|
1000 |
+
advancedFilters,
|
1001 |
+
defaultDateRange,
|
1002 |
+
fields: summaryFields
|
1003 |
+
}) : EMPTY_OBJECT;
|
1004 |
+
const queriedTableData = tableData || Object(external_wc_data_["getReportTableData"])({
|
1005 |
+
endpoint,
|
1006 |
+
query,
|
1007 |
+
selector: reportStoreSelector,
|
1008 |
+
tableQuery,
|
1009 |
+
filters,
|
1010 |
+
advancedFilters,
|
1011 |
+
defaultDateRange
|
1012 |
+
});
|
1013 |
+
const extendedTableData = extendedStoreSelector ? extendTableData(extendedStoreSelector, props, queriedTableData) : queriedTableData;
|
1014 |
+
return {
|
1015 |
+
primaryData,
|
1016 |
+
ids: itemIdField && extendedTableData.items.data ? extendedTableData.items.data.map(item => item[itemIdField]) : EMPTY_ARRAY,
|
1017 |
+
tableData: extendedTableData,
|
1018 |
+
query
|
1019 |
+
};
|
1020 |
+
}), Object(external_wp_data_["withDispatch"])(dispatch => {
|
1021 |
+
const {
|
1022 |
+
startExport
|
1023 |
+
} = dispatch(external_wc_data_["EXPORT_STORE_NAME"]);
|
1024 |
+
const {
|
1025 |
+
createNotice
|
1026 |
+
} = dispatch('core/notices');
|
1027 |
+
const {
|
1028 |
+
addCesSurveyForCustomerSearch
|
1029 |
+
} = dispatch(constants["c" /* STORE_KEY */]);
|
1030 |
+
return {
|
1031 |
+
createNotice,
|
1032 |
+
startExport,
|
1033 |
+
addCesSurveyForCustomerSearch
|
1034 |
+
};
|
1035 |
+
}))(ReportTable));
|
1036 |
+
|
1037 |
+
/***/ }),
|
1038 |
+
|
1039 |
+
/***/ 510:
|
1040 |
+
/***/ (function(module, __webpack_exports__, __webpack_require__) {
|
1041 |
+
|
1042 |
+
"use strict";
|
1043 |
+
|
1044 |
+
// UNUSED EXPORTS: ReportChart
|
1045 |
+
|
1046 |
+
// EXTERNAL MODULE: external ["wp","element"]
|
1047 |
+
var external_wp_element_ = __webpack_require__(0);
|
1048 |
+
|
1049 |
+
// EXTERNAL MODULE: external ["wp","i18n"]
|
1050 |
+
var external_wp_i18n_ = __webpack_require__(2);
|
1051 |
+
|
1052 |
+
// EXTERNAL MODULE: external ["wp","compose"]
|
1053 |
+
var external_wp_compose_ = __webpack_require__(14);
|
1054 |
+
|
1055 |
+
// EXTERNAL MODULE: external ["wp","date"]
|
1056 |
+
var external_wp_date_ = __webpack_require__(61);
|
1057 |
+
|
1058 |
+
// EXTERNAL MODULE: external ["wp","data"]
|
1059 |
+
var external_wp_data_ = __webpack_require__(7);
|
1060 |
+
|
1061 |
+
// EXTERNAL MODULE: external "lodash"
|
1062 |
+
var external_lodash_ = __webpack_require__(4);
|
1063 |
+
|
1064 |
+
// EXTERNAL MODULE: ./node_modules/prop-types/index.js
|
1065 |
+
var prop_types = __webpack_require__(1);
|
1066 |
+
var prop_types_default = /*#__PURE__*/__webpack_require__.n(prop_types);
|
1067 |
+
|
1068 |
+
// EXTERNAL MODULE: external ["wc","components"]
|
1069 |
+
var external_wc_components_ = __webpack_require__(21);
|
1070 |
+
|
1071 |
+
// EXTERNAL MODULE: external ["wc","data"]
|
1072 |
+
var external_wc_data_ = __webpack_require__(11);
|
1073 |
+
|
1074 |
+
// EXTERNAL MODULE: external ["wc","date"]
|
1075 |
+
var external_wc_date_ = __webpack_require__(20);
|
1076 |
+
|
1077 |
+
// EXTERNAL MODULE: ./client/lib/currency-context.js
|
1078 |
+
var currency_context = __webpack_require__(503);
|
1079 |
+
|
1080 |
+
// EXTERNAL MODULE: ./client/analytics/components/report-error/index.js
|
1081 |
+
var report_error = __webpack_require__(506);
|
1082 |
+
|
1083 |
+
// EXTERNAL MODULE: external ["wc","navigation"]
|
1084 |
+
var external_wc_navigation_ = __webpack_require__(12);
|
1085 |
+
|
1086 |
+
// CONCATENATED MODULE: ./client/analytics/components/report-chart/utils.js
|
1087 |
+
/**
|
1088 |
+
* External dependencies
|
1089 |
+
*/
|
1090 |
+
|
1091 |
+
|
1092 |
+
const DEFAULT_FILTER = 'all';
|
1093 |
+
function getSelectedFilter(filters, query, selectedFilterArgs = {}) {
|
1094 |
+
if (!filters || filters.length === 0) {
|
1095 |
+
return null;
|
1096 |
+
}
|
1097 |
+
|
1098 |
+
const clonedFilters = filters.slice(0);
|
1099 |
+
const filterConfig = clonedFilters.pop();
|
1100 |
+
|
1101 |
+
if (filterConfig.showFilters(query, selectedFilterArgs)) {
|
1102 |
+
const allFilters = Object(external_wc_navigation_["flattenFilters"])(filterConfig.filters);
|
1103 |
+
const value = query[filterConfig.param] || filterConfig.defaultValue || DEFAULT_FILTER;
|
1104 |
+
return Object(external_lodash_["find"])(allFilters, {
|
1105 |
+
value
|
1106 |
+
});
|
1107 |
+
}
|
1108 |
+
|
1109 |
+
return getSelectedFilter(clonedFilters, query, selectedFilterArgs);
|
1110 |
+
}
|
1111 |
+
function getChartMode(selectedFilter, query) {
|
1112 |
+
if (selectedFilter && query) {
|
1113 |
+
const selectedFilterParam = Object(external_lodash_["get"])(selectedFilter, ['settings', 'param']);
|
1114 |
+
|
1115 |
+
if (!selectedFilterParam || Object.keys(query).includes(selectedFilterParam)) {
|
1116 |
+
return Object(external_lodash_["get"])(selectedFilter, ['chartMode']);
|
1117 |
+
}
|
1118 |
+
}
|
1119 |
+
|
1120 |
+
return null;
|
1121 |
+
}
|
1122 |
+
// CONCATENATED MODULE: ./client/analytics/components/report-chart/index.js
|
1123 |
+
|
1124 |
+
|
1125 |
+
/**
|
1126 |
+
* External dependencies
|
1127 |
+
*/
|
1128 |
+
|
1129 |
+
|
1130 |
+
|
1131 |
+
|
1132 |
+
|
1133 |
+
|
1134 |
+
|
1135 |
+
|
1136 |
+
|
1137 |
+
|
1138 |
+
/**
|
1139 |
+
* Internal dependencies
|
1140 |
+
*/
|
1141 |
+
|
1142 |
+
|
1143 |
+
|
1144 |
+
|
1145 |
+
/**
|
1146 |
+
* Component that renders the chart in reports.
|
1147 |
+
*/
|
1148 |
+
|
1149 |
+
class report_chart_ReportChart extends external_wp_element_["Component"] {
|
1150 |
+
shouldComponentUpdate(nextProps) {
|
1151 |
+
if (nextProps.isRequesting !== this.props.isRequesting || nextProps.primaryData.isRequesting !== this.props.primaryData.isRequesting || nextProps.secondaryData.isRequesting !== this.props.secondaryData.isRequesting || !Object(external_lodash_["isEqual"])(nextProps.query, this.props.query)) {
|
1152 |
+
return true;
|
1153 |
+
}
|
1154 |
+
|
1155 |
+
return false;
|
1156 |
+
}
|
1157 |
+
|
1158 |
+
getItemChartData() {
|
1159 |
+
const {
|
1160 |
+
primaryData,
|
1161 |
+
selectedChart
|
1162 |
+
} = this.props;
|
1163 |
+
const chartData = primaryData.data.intervals.map(function (interval) {
|
1164 |
+
const intervalData = {};
|
1165 |
+
interval.subtotals.segments.forEach(function (segment) {
|
1166 |
+
if (segment.segment_label) {
|
1167 |
+
const label = intervalData[segment.segment_label] ? segment.segment_label + ' (#' + segment.segment_id + ')' : segment.segment_label;
|
1168 |
+
intervalData[segment.segment_id] = {
|
1169 |
+
label,
|
1170 |
+
value: segment.subtotals[selectedChart.key] || 0
|
1171 |
+
};
|
1172 |
+
}
|
1173 |
+
});
|
1174 |
+
return {
|
1175 |
+
date: Object(external_wp_date_["format"])('Y-m-d\\TH:i:s', interval.date_start),
|
1176 |
+
...intervalData
|
1177 |
+
};
|
1178 |
+
});
|
1179 |
+
return chartData;
|
1180 |
+
}
|
1181 |
+
|
1182 |
+
getTimeChartData() {
|
1183 |
+
const {
|
1184 |
+
query,
|
1185 |
+
primaryData,
|
1186 |
+
secondaryData,
|
1187 |
+
selectedChart,
|
1188 |
+
defaultDateRange
|
1189 |
+
} = this.props;
|
1190 |
+
const currentInterval = Object(external_wc_date_["getIntervalForQuery"])(query);
|
1191 |
+
const {
|
1192 |
+
primary,
|
1193 |
+
secondary
|
1194 |
+
} = Object(external_wc_date_["getCurrentDates"])(query, defaultDateRange);
|
1195 |
+
const chartData = primaryData.data.intervals.map(function (interval, index) {
|
1196 |
+
const secondaryDate = Object(external_wc_date_["getPreviousDate"])(interval.date_start, primary.after, secondary.after, query.compare, currentInterval);
|
1197 |
+
const secondaryInterval = secondaryData.data.intervals[index];
|
1198 |
+
return {
|
1199 |
+
date: Object(external_wp_date_["format"])('Y-m-d\\TH:i:s', interval.date_start),
|
1200 |
+
primary: {
|
1201 |
+
label: `${primary.label} (${primary.range})`,
|
1202 |
+
labelDate: interval.date_start,
|
1203 |
+
value: interval.subtotals[selectedChart.key] || 0
|
1204 |
+
},
|
1205 |
+
secondary: {
|
1206 |
+
label: `${secondary.label} (${secondary.range})`,
|
1207 |
+
labelDate: secondaryDate.format('YYYY-MM-DD HH:mm:ss'),
|
1208 |
+
value: secondaryInterval && secondaryInterval.subtotals[selectedChart.key] || 0
|
1209 |
+
}
|
1210 |
+
};
|
1211 |
+
});
|
1212 |
+
return chartData;
|
1213 |
+
}
|
1214 |
+
|
1215 |
+
getTimeChartTotals() {
|
1216 |
+
const {
|
1217 |
+
primaryData,
|
1218 |
+
secondaryData,
|
1219 |
+
selectedChart
|
1220 |
+
} = this.props;
|
1221 |
+
return {
|
1222 |
+
primary: Object(external_lodash_["get"])(primaryData, ['data', 'totals', selectedChart.key], null),
|
1223 |
+
secondary: Object(external_lodash_["get"])(secondaryData, ['data', 'totals', selectedChart.key], null)
|
1224 |
+
};
|
1225 |
+
}
|
1226 |
+
|
1227 |
+
renderChart(mode, isRequesting, chartData, legendTotals) {
|
1228 |
+
const {
|
1229 |
+
emptySearchResults,
|
1230 |
+
filterParam,
|
1231 |
+
interactiveLegend,
|
1232 |
+
itemsLabel,
|
1233 |
+
legendPosition,
|
1234 |
+
path,
|
1235 |
+
query,
|
1236 |
+
selectedChart,
|
1237 |
+
showHeaderControls,
|
1238 |
+
primaryData
|
1239 |
+
} = this.props;
|
1240 |
+
const currentInterval = Object(external_wc_date_["getIntervalForQuery"])(query);
|
1241 |
+
const allowedIntervals = Object(external_wc_date_["getAllowedIntervalsForQuery"])(query);
|
1242 |
+
const formats = Object(external_wc_date_["getDateFormatsForInterval"])(currentInterval, primaryData.data.intervals.length);
|
1243 |
+
const emptyMessage = emptySearchResults ? Object(external_wp_i18n_["__"])('No data for the current search', 'woocommerce-admin') : Object(external_wp_i18n_["__"])('No data for the selected date range', 'woocommerce-admin');
|
1244 |
+
const {
|
1245 |
+
formatAmount,
|
1246 |
+
getCurrencyConfig
|
1247 |
+
} = this.context;
|
1248 |
+
return Object(external_wp_element_["createElement"])(external_wc_components_["Chart"], {
|
1249 |
+
allowedIntervals: allowedIntervals,
|
1250 |
+
data: chartData,
|
1251 |
+
dateParser: '%Y-%m-%dT%H:%M:%S',
|
1252 |
+
emptyMessage: emptyMessage,
|
1253 |
+
filterParam: filterParam,
|
1254 |
+
interactiveLegend: interactiveLegend,
|
1255 |
+
interval: currentInterval,
|
1256 |
+
isRequesting: isRequesting,
|
1257 |
+
itemsLabel: itemsLabel,
|
1258 |
+
legendPosition: legendPosition,
|
1259 |
+
legendTotals: legendTotals,
|
1260 |
+
mode: mode,
|
1261 |
+
path: path,
|
1262 |
+
query: query,
|
1263 |
+
screenReaderFormat: formats.screenReaderFormat,
|
1264 |
+
showHeaderControls: showHeaderControls,
|
1265 |
+
title: selectedChart.label,
|
1266 |
+
tooltipLabelFormat: formats.tooltipLabelFormat,
|
1267 |
+
tooltipTitle: mode === 'time-comparison' && selectedChart.label || null,
|
1268 |
+
tooltipValueFormat: Object(external_wc_data_["getTooltipValueFormat"])(selectedChart.type, formatAmount),
|
1269 |
+
chartType: Object(external_wc_date_["getChartTypeForQuery"])(query),
|
1270 |
+
valueType: selectedChart.type,
|
1271 |
+
xFormat: formats.xFormat,
|
1272 |
+
x2Format: formats.x2Format,
|
1273 |
+
currency: getCurrencyConfig()
|
1274 |
+
});
|
1275 |
+
}
|
1276 |
+
|
1277 |
+
renderItemComparison() {
|
1278 |
+
const {
|
1279 |
+
isRequesting,
|
1280 |
+
primaryData
|
1281 |
+
} = this.props;
|
1282 |
+
|
1283 |
+
if (primaryData.isError) {
|
1284 |
+
return Object(external_wp_element_["createElement"])(report_error["a" /* default */], null);
|
1285 |
+
}
|
1286 |
+
|
1287 |
+
const isChartRequesting = isRequesting || primaryData.isRequesting;
|
1288 |
+
const chartData = this.getItemChartData();
|
1289 |
+
return this.renderChart('item-comparison', isChartRequesting, chartData);
|
1290 |
+
}
|
1291 |
+
|
1292 |
+
renderTimeComparison() {
|
1293 |
+
const {
|
1294 |
+
isRequesting,
|
1295 |
+
primaryData,
|
1296 |
+
secondaryData
|
1297 |
+
} = this.props;
|
1298 |
+
|
1299 |
+
if (!primaryData || primaryData.isError || secondaryData.isError) {
|
1300 |
+
return Object(external_wp_element_["createElement"])(report_error["a" /* default */], null);
|
1301 |
+
}
|
1302 |
+
|
1303 |
+
const isChartRequesting = isRequesting || primaryData.isRequesting || secondaryData.isRequesting;
|
1304 |
+
const chartData = this.getTimeChartData();
|
1305 |
+
const legendTotals = this.getTimeChartTotals();
|
1306 |
+
return this.renderChart('time-comparison', isChartRequesting, chartData, legendTotals);
|
1307 |
+
}
|
1308 |
+
|
1309 |
+
render() {
|
1310 |
+
const {
|
1311 |
+
mode
|
1312 |
+
} = this.props;
|
1313 |
+
|
1314 |
+
if (mode === 'item-comparison') {
|
1315 |
+
return this.renderItemComparison();
|
1316 |
+
}
|
1317 |
+
|
1318 |
+
return this.renderTimeComparison();
|
1319 |
+
}
|
1320 |
+
|
1321 |
+
}
|
1322 |
+
report_chart_ReportChart.contextType = currency_context["a" /* CurrencyContext */];
|
1323 |
+
report_chart_ReportChart.propTypes = {
|
1324 |
+
/**
|
1325 |
+
* Filters available for that report.
|
1326 |
+
*/
|
1327 |
+
filters: prop_types_default.a.array,
|
1328 |
+
|
1329 |
+
/**
|
1330 |
+
* Whether there is an API call running.
|
1331 |
+
*/
|
1332 |
+
isRequesting: prop_types_default.a.bool,
|
1333 |
+
|
1334 |
+
/**
|
1335 |
+
* Label describing the legend items.
|
1336 |
+
*/
|
1337 |
+
itemsLabel: prop_types_default.a.string,
|
1338 |
+
|
1339 |
+
/**
|
1340 |
+
* Allows specifying properties different from the `endpoint` that will be used
|
1341 |
+
* to limit the items when there is an active search.
|
1342 |
+
*/
|
1343 |
+
limitProperties: prop_types_default.a.array,
|
1344 |
+
|
1345 |
+
/**
|
1346 |
+
* `items-comparison` (default) or `time-comparison`, this is used to generate correct
|
1347 |
+
* ARIA properties.
|
1348 |
+
*/
|
1349 |
+
mode: prop_types_default.a.string,
|
1350 |
+
|
1351 |
+
/**
|
1352 |
+
* Current path
|
1353 |
+
*/
|
1354 |
+
path: prop_types_default.a.string.isRequired,
|
1355 |
+
|
1356 |
+
/**
|
1357 |
+
* Primary data to display in the chart.
|
1358 |
+
*/
|
1359 |
+
primaryData: prop_types_default.a.object,
|
1360 |
+
|
1361 |
+
/**
|
1362 |
+
* The query string represented in object form.
|
1363 |
+
*/
|
1364 |
+
query: prop_types_default.a.object.isRequired,
|
1365 |
+
|
1366 |
+
/**
|
1367 |
+
* Secondary data to display in the chart.
|
1368 |
+
*/
|
1369 |
+
secondaryData: prop_types_default.a.object,
|
1370 |
+
|
1371 |
+
/**
|
1372 |
+
* Properties of the selected chart.
|
1373 |
+
*/
|
1374 |
+
selectedChart: prop_types_default.a.shape({
|
1375 |
+
/**
|
1376 |
+
* Key of the selected chart.
|
1377 |
+
*/
|
1378 |
+
key: prop_types_default.a.string.isRequired,
|
1379 |
+
|
1380 |
+
/**
|
1381 |
+
* Chart label.
|
1382 |
+
*/
|
1383 |
+
label: prop_types_default.a.string.isRequired,
|
1384 |
+
|
1385 |
+
/**
|
1386 |
+
* Order query argument.
|
1387 |
+
*/
|
1388 |
+
order: prop_types_default.a.oneOf(['asc', 'desc']),
|
1389 |
+
|
1390 |
+
/**
|
1391 |
+
* Order by query argument.
|
1392 |
+
*/
|
1393 |
+
orderby: prop_types_default.a.string,
|
1394 |
+
|
1395 |
+
/**
|
1396 |
+
* Number type for formatting.
|
1397 |
+
*/
|
1398 |
+
type: prop_types_default.a.oneOf(['average', 'number', 'currency']).isRequired
|
1399 |
+
}).isRequired
|
1400 |
+
};
|
1401 |
+
report_chart_ReportChart.defaultProps = {
|
1402 |
+
isRequesting: false,
|
1403 |
+
primaryData: {
|
1404 |
+
data: {
|
1405 |
+
intervals: []
|
1406 |
+
},
|
1407 |
+
isError: false,
|
1408 |
+
isRequesting: false
|
1409 |
+
},
|
1410 |
+
secondaryData: {
|
1411 |
+
data: {
|
1412 |
+
intervals: []
|
1413 |
+
},
|
1414 |
+
isError: false,
|
1415 |
+
isRequesting: false
|
1416 |
+
}
|
1417 |
+
};
|
1418 |
+
/* harmony default export */ var report_chart = __webpack_exports__["a"] = (Object(external_wp_compose_["compose"])(Object(external_wp_data_["withSelect"])((select, props) => {
|
1419 |
+
const {
|
1420 |
+
charts,
|
1421 |
+
endpoint,
|
1422 |
+
filters,
|
1423 |
+
isRequesting,
|
1424 |
+
limitProperties,
|
1425 |
+
query,
|
1426 |
+
advancedFilters
|
1427 |
+
} = props;
|
1428 |
+
const limitBy = limitProperties || [endpoint];
|
1429 |
+
const selectedFilter = getSelectedFilter(filters, query);
|
1430 |
+
const filterParam = Object(external_lodash_["get"])(selectedFilter, ['settings', 'param']);
|
1431 |
+
const chartMode = props.mode || getChartMode(selectedFilter, query) || 'time-comparison';
|
1432 |
+
const {
|
1433 |
+
woocommerce_default_date_range: defaultDateRange
|
1434 |
+
} = select(external_wc_data_["SETTINGS_STORE_NAME"]).getSetting('wc_admin', 'wcAdminSettings');
|
1435 |
+
/* eslint @wordpress/no-unused-vars-before-return: "off" */
|
1436 |
+
|
1437 |
+
const reportStoreSelector = select(external_wc_data_["REPORTS_STORE_NAME"]);
|
1438 |
+
const newProps = {
|
1439 |
+
mode: chartMode,
|
1440 |
+
filterParam,
|
1441 |
+
defaultDateRange
|
1442 |
+
};
|
1443 |
+
|
1444 |
+
if (isRequesting) {
|
1445 |
+
return newProps;
|
1446 |
+
}
|
1447 |
+
|
1448 |
+
const hasLimitByParam = limitBy.some(item => query[item] && query[item].length);
|
1449 |
+
|
1450 |
+
if (query.search && !hasLimitByParam) {
|
1451 |
+
return { ...newProps,
|
1452 |
+
emptySearchResults: true
|
1453 |
+
};
|
1454 |
+
}
|
1455 |
+
|
1456 |
+
const fields = charts && charts.map(chart => chart.key);
|
1457 |
+
const primaryData = Object(external_wc_data_["getReportChartData"])({
|
1458 |
+
endpoint,
|
1459 |
+
dataType: 'primary',
|
1460 |
+
query,
|
1461 |
+
selector: reportStoreSelector,
|
1462 |
+
limitBy,
|
1463 |
+
filters,
|
1464 |
+
advancedFilters,
|
1465 |
+
defaultDateRange,
|
1466 |
+
fields
|
1467 |
+
});
|
1468 |
+
|
1469 |
+
if (chartMode === 'item-comparison') {
|
1470 |
+
return { ...newProps,
|
1471 |
+
primaryData
|
1472 |
+
};
|
1473 |
+
}
|
1474 |
+
|
1475 |
+
const secondaryData = Object(external_wc_data_["getReportChartData"])({
|
1476 |
+
endpoint,
|
1477 |
+
dataType: 'secondary',
|
1478 |
+
query,
|
1479 |
+
selector: reportStoreSelector,
|
1480 |
+
limitBy,
|
1481 |
+
filters,
|
1482 |
+
advancedFilters,
|
1483 |
+
defaultDateRange,
|
1484 |
+
fields
|
1485 |
+
});
|
1486 |
+
return { ...newProps,
|
1487 |
+
primaryData,
|
1488 |
+
secondaryData
|
1489 |
+
};
|
1490 |
+
}))(report_chart_ReportChart));
|
1491 |
+
|
1492 |
+
/***/ }),
|
1493 |
+
|
1494 |
+
/***/ 512:
|
1495 |
+
/***/ (function(module, __webpack_exports__, __webpack_require__) {
|
1496 |
+
|
1497 |
+
"use strict";
|
1498 |
+
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "a", function() { return getSelectedChart; });
|
1499 |
+
/* harmony import */ var lodash__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(4);
|
1500 |
+
/* harmony import */ var lodash__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(lodash__WEBPACK_IMPORTED_MODULE_0__);
|
1501 |
+
/**
|
1502 |
+
* External dependencies
|
1503 |
+
*/
|
1504 |
+
|
1505 |
+
/**
|
1506 |
+
* Takes a chart name returns the configuration for that chart from and array
|
1507 |
+
* of charts. If the chart is not found it will return the first chart.
|
1508 |
+
*
|
1509 |
+
* @param {string} chartName - the name of the chart to get configuration for
|
1510 |
+
* @param {Array} charts - list of charts for a particular report
|
1511 |
+
* @return {Object} - chart configuration object
|
1512 |
+
*/
|
1513 |
+
|
1514 |
+
function getSelectedChart(chartName, charts = []) {
|
1515 |
+
const chart = Object(lodash__WEBPACK_IMPORTED_MODULE_0__["find"])(charts, {
|
1516 |
+
key: chartName
|
1517 |
+
});
|
1518 |
+
|
1519 |
+
if (chart) {
|
1520 |
+
return chart;
|
1521 |
+
}
|
1522 |
+
|
1523 |
+
return charts[0];
|
1524 |
+
}
|
1525 |
+
|
1526 |
+
/***/ }),
|
1527 |
+
|
1528 |
+
/***/ 513:
|
1529 |
+
/***/ (function(module, __webpack_exports__, __webpack_require__) {
|
1530 |
+
|
1531 |
+
"use strict";
|
1532 |
+
/* unused harmony export ReportSummary */
|
1533 |
+
/* harmony import */ var _wordpress_element__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(0);
|
1534 |
+
/* harmony import */ var _wordpress_element__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(_wordpress_element__WEBPACK_IMPORTED_MODULE_0__);
|
1535 |
+
/* harmony import */ var _wordpress_i18n__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(2);
|
1536 |
+
/* harmony import */ var _wordpress_i18n__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(_wordpress_i18n__WEBPACK_IMPORTED_MODULE_1__);
|
1537 |
+
/* harmony import */ var _wordpress_compose__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(14);
|
1538 |
+
/* harmony import */ var _wordpress_compose__WEBPACK_IMPORTED_MODULE_2___default = /*#__PURE__*/__webpack_require__.n(_wordpress_compose__WEBPACK_IMPORTED_MODULE_2__);
|
1539 |
+
/* harmony import */ var _wordpress_data__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(7);
|
1540 |
+
/* harmony import */ var _wordpress_data__WEBPACK_IMPORTED_MODULE_3___default = /*#__PURE__*/__webpack_require__.n(_wordpress_data__WEBPACK_IMPORTED_MODULE_3__);
|
1541 |
+
/* harmony import */ var prop_types__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(1);
|
1542 |
+
/* harmony import */ var prop_types__WEBPACK_IMPORTED_MODULE_4___default = /*#__PURE__*/__webpack_require__.n(prop_types__WEBPACK_IMPORTED_MODULE_4__);
|
1543 |
+
/* harmony import */ var _woocommerce_navigation__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(12);
|
1544 |
+
/* harmony import */ var _woocommerce_navigation__WEBPACK_IMPORTED_MODULE_5___default = /*#__PURE__*/__webpack_require__.n(_woocommerce_navigation__WEBPACK_IMPORTED_MODULE_5__);
|
1545 |
+
/* harmony import */ var _woocommerce_components__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(21);
|
1546 |
+
/* harmony import */ var _woocommerce_components__WEBPACK_IMPORTED_MODULE_6___default = /*#__PURE__*/__webpack_require__.n(_woocommerce_components__WEBPACK_IMPORTED_MODULE_6__);
|
1547 |
+
/* harmony import */ var _woocommerce_number__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__(120);
|
1548 |
+
/* harmony import */ var _woocommerce_number__WEBPACK_IMPORTED_MODULE_7___default = /*#__PURE__*/__webpack_require__.n(_woocommerce_number__WEBPACK_IMPORTED_MODULE_7__);
|
1549 |
+
/* harmony import */ var _woocommerce_data__WEBPACK_IMPORTED_MODULE_8__ = __webpack_require__(11);
|
1550 |
+
/* harmony import */ var _woocommerce_data__WEBPACK_IMPORTED_MODULE_8___default = /*#__PURE__*/__webpack_require__.n(_woocommerce_data__WEBPACK_IMPORTED_MODULE_8__);
|
1551 |
+
/* harmony import */ var _woocommerce_date__WEBPACK_IMPORTED_MODULE_9__ = __webpack_require__(20);
|
1552 |
+
/* harmony import */ var _woocommerce_date__WEBPACK_IMPORTED_MODULE_9___default = /*#__PURE__*/__webpack_require__.n(_woocommerce_date__WEBPACK_IMPORTED_MODULE_9__);
|
1553 |
+
/* harmony import */ var _woocommerce_tracks__WEBPACK_IMPORTED_MODULE_10__ = __webpack_require__(15);
|
1554 |
+
/* harmony import */ var _woocommerce_tracks__WEBPACK_IMPORTED_MODULE_10___default = /*#__PURE__*/__webpack_require__.n(_woocommerce_tracks__WEBPACK_IMPORTED_MODULE_10__);
|
1555 |
+
/* harmony import */ var _report_error__WEBPACK_IMPORTED_MODULE_11__ = __webpack_require__(506);
|
1556 |
+
/* harmony import */ var _lib_currency_context__WEBPACK_IMPORTED_MODULE_12__ = __webpack_require__(503);
|
1557 |
+
|
1558 |
+
|
1559 |
+
/**
|
1560 |
+
* External dependencies
|
1561 |
+
*/
|
1562 |
+
|
1563 |
+
|
1564 |
+
|
1565 |
+
|
1566 |
+
|
1567 |
+
|
1568 |
+
|
1569 |
+
|
1570 |
+
|
1571 |
+
|
1572 |
+
|
1573 |
+
/**
|
1574 |
+
* Internal dependencies
|
1575 |
+
*/
|
1576 |
+
|
1577 |
+
|
1578 |
+
|
1579 |
+
/**
|
1580 |
+
* Component to render summary numbers in reports.
|
1581 |
+
*/
|
1582 |
+
|
1583 |
+
class ReportSummary extends _wordpress_element__WEBPACK_IMPORTED_MODULE_0__["Component"] {
|
1584 |
+
formatVal(val, type) {
|
1585 |
+
const {
|
1586 |
+
formatAmount,
|
1587 |
+
getCurrencyConfig
|
1588 |
+
} = this.context;
|
1589 |
+
return type === 'currency' ? formatAmount(val) : Object(_woocommerce_number__WEBPACK_IMPORTED_MODULE_7__["formatValue"])(getCurrencyConfig(), type, val);
|
1590 |
+
}
|
1591 |
+
|
1592 |
+
getValues(key, type) {
|
1593 |
+
const {
|
1594 |
+
emptySearchResults,
|
1595 |
+
summaryData
|
1596 |
+
} = this.props;
|
1597 |
+
const {
|
1598 |
+
totals
|
1599 |
+
} = summaryData;
|
1600 |
+
const primaryTotal = totals.primary ? totals.primary[key] : 0;
|
1601 |
+
const secondaryTotal = totals.secondary ? totals.secondary[key] : 0;
|
1602 |
+
const primaryValue = emptySearchResults ? 0 : primaryTotal;
|
1603 |
+
const secondaryValue = emptySearchResults ? 0 : secondaryTotal;
|
1604 |
+
return {
|
1605 |
+
delta: Object(_woocommerce_number__WEBPACK_IMPORTED_MODULE_7__["calculateDelta"])(primaryValue, secondaryValue),
|
1606 |
+
prevValue: this.formatVal(secondaryValue, type),
|
1607 |
+
value: this.formatVal(primaryValue, type)
|
1608 |
+
};
|
1609 |
+
}
|
1610 |
+
|
1611 |
+
render() {
|
1612 |
+
const {
|
1613 |
+
charts,
|
1614 |
+
query,
|
1615 |
+
selectedChart,
|
1616 |
+
summaryData,
|
1617 |
+
endpoint,
|
1618 |
+
report,
|
1619 |
+
defaultDateRange
|
1620 |
+
} = this.props;
|
1621 |
+
const {
|
1622 |
+
isError,
|
1623 |
+
isRequesting
|
1624 |
+
} = summaryData;
|
1625 |
+
|
1626 |
+
if (isError) {
|
1627 |
+
return Object(_wordpress_element__WEBPACK_IMPORTED_MODULE_0__["createElement"])(_report_error__WEBPACK_IMPORTED_MODULE_11__[/* default */ "a"], null);
|
1628 |
+
}
|
1629 |
+
|
1630 |
+
if (isRequesting) {
|
1631 |
+
return Object(_wordpress_element__WEBPACK_IMPORTED_MODULE_0__["createElement"])(_woocommerce_components__WEBPACK_IMPORTED_MODULE_6__["SummaryListPlaceholder"], {
|
1632 |
+
numberOfItems: charts.length
|
1633 |
+
});
|
1634 |
+
}
|
1635 |
+
|
1636 |
+
const {
|
1637 |
+
compare
|
1638 |
+
} = Object(_woocommerce_date__WEBPACK_IMPORTED_MODULE_9__["getDateParamsFromQuery"])(query, defaultDateRange);
|
1639 |
+
|
1640 |
+
const renderSummaryNumbers = ({
|
1641 |
+
onToggle
|
1642 |
+
}) => charts.map(chart => {
|
1643 |
+
const {
|
1644 |
+
key,
|
1645 |
+
order,
|
1646 |
+
orderby,
|
1647 |
+
label,
|
1648 |
+
type,
|
1649 |
+
isReverseTrend
|
1650 |
+
} = chart;
|
1651 |
+
const newPath = {
|
1652 |
+
chart: key
|
1653 |
+
};
|
1654 |
+
|
1655 |
+
if (orderby) {
|
1656 |
+
newPath.orderby = orderby;
|
1657 |
+
}
|
1658 |
+
|
1659 |
+
if (order) {
|
1660 |
+
newPath.order = order;
|
1661 |
+
}
|
1662 |
+
|
1663 |
+
const href = Object(_woocommerce_navigation__WEBPACK_IMPORTED_MODULE_5__["getNewPath"])(newPath);
|
1664 |
+
const isSelected = selectedChart.key === key;
|
1665 |
+
const {
|
1666 |
+
delta,
|
1667 |
+
prevValue,
|
1668 |
+
value
|
1669 |
+
} = this.getValues(key, type);
|
1670 |
+
return Object(_wordpress_element__WEBPACK_IMPORTED_MODULE_0__["createElement"])(_woocommerce_components__WEBPACK_IMPORTED_MODULE_6__["SummaryNumber"], {
|
1671 |
+
key: key,
|
1672 |
+
delta: delta,
|
1673 |
+
href: href,
|
1674 |
+
label: label,
|
1675 |
+
reverseTrend: isReverseTrend,
|
1676 |
+
prevLabel: compare === 'previous_period' ? Object(_wordpress_i18n__WEBPACK_IMPORTED_MODULE_1__["__"])('Previous period:', 'woocommerce-admin') : Object(_wordpress_i18n__WEBPACK_IMPORTED_MODULE_1__["__"])('Previous year:', 'woocommerce-admin'),
|
1677 |
+
prevValue: prevValue,
|
1678 |
+
selected: isSelected,
|
1679 |
+
value: value,
|
1680 |
+
onLinkClickCallback: () => {
|
1681 |
+
// Wider than a certain breakpoint, there is no dropdown so avoid calling onToggle.
|
1682 |
+
if (onToggle) {
|
1683 |
+
onToggle();
|
1684 |
+
}
|
1685 |
+
|
1686 |
+
Object(_woocommerce_tracks__WEBPACK_IMPORTED_MODULE_10__["recordEvent"])('analytics_chart_tab_click', {
|
1687 |
+
report: report || endpoint,
|
1688 |
+
key
|
1689 |
+
});
|
1690 |
+
}
|
1691 |
+
});
|
1692 |
+
});
|
1693 |
+
|
1694 |
+
return Object(_wordpress_element__WEBPACK_IMPORTED_MODULE_0__["createElement"])(_woocommerce_components__WEBPACK_IMPORTED_MODULE_6__["SummaryList"], null, renderSummaryNumbers);
|
1695 |
+
}
|
1696 |
+
|
1697 |
+
}
|
1698 |
+
ReportSummary.propTypes = {
|
1699 |
+
/**
|
1700 |
+
* Properties of all the charts available for that report.
|
1701 |
+
*/
|
1702 |
+
charts: prop_types__WEBPACK_IMPORTED_MODULE_4___default.a.array.isRequired,
|
1703 |
+
|
1704 |
+
/**
|
1705 |
+
* The endpoint to use in API calls to populate the Summary Numbers.
|
1706 |
+
* For example, if `taxes` is provided, data will be fetched from the report
|
1707 |
+
* `taxes` endpoint (ie: `/wc-analytics/reports/taxes/stats`). If the provided endpoint
|
1708 |
+
* doesn't exist, an error will be shown to the user with `ReportError`.
|
1709 |
+
*/
|
1710 |
+
endpoint: prop_types__WEBPACK_IMPORTED_MODULE_4___default.a.string.isRequired,
|
1711 |
+
|
1712 |
+
/**
|
1713 |
+
* Allows specifying properties different from the `endpoint` that will be used
|
1714 |
+
* to limit the items when there is an active search.
|
1715 |
+
*/
|
1716 |
+
limitProperties: prop_types__WEBPACK_IMPORTED_MODULE_4___default.a.array,
|
1717 |
+
|
1718 |
+
/**
|
1719 |
+
* The query string represented in object form.
|
1720 |
+
*/
|
1721 |
+
query: prop_types__WEBPACK_IMPORTED_MODULE_4___default.a.object.isRequired,
|
1722 |
+
|
1723 |
+
/**
|
1724 |
+
* Properties of the selected chart.
|
1725 |
+
*/
|
1726 |
+
selectedChart: prop_types__WEBPACK_IMPORTED_MODULE_4___default.a.shape({
|
1727 |
+
/**
|
1728 |
+
* Key of the selected chart.
|
1729 |
+
*/
|
1730 |
+
key: prop_types__WEBPACK_IMPORTED_MODULE_4___default.a.string.isRequired,
|
1731 |
+
|
1732 |
+
/**
|
1733 |
+
* Chart label.
|
1734 |
+
*/
|
1735 |
+
label: prop_types__WEBPACK_IMPORTED_MODULE_4___default.a.string.isRequired,
|
1736 |
+
|
1737 |
+
/**
|
1738 |
+
* Order query argument.
|
1739 |
+
*/
|
1740 |
+
order: prop_types__WEBPACK_IMPORTED_MODULE_4___default.a.oneOf(['asc', 'desc']),
|
1741 |
+
|
1742 |
+
/**
|
1743 |
+
* Order by query argument.
|
1744 |
+
*/
|
1745 |
+
orderby: prop_types__WEBPACK_IMPORTED_MODULE_4___default.a.string,
|
1746 |
+
|
1747 |
+
/**
|
1748 |
+
* Number type for formatting.
|
1749 |
+
*/
|
1750 |
+
type: prop_types__WEBPACK_IMPORTED_MODULE_4___default.a.oneOf(['average', 'number', 'currency']).isRequired
|
1751 |
+
}).isRequired,
|
1752 |
+
|
1753 |
+
/**
|
1754 |
+
* Data to display in the SummaryNumbers.
|
1755 |
+
*/
|
1756 |
+
summaryData: prop_types__WEBPACK_IMPORTED_MODULE_4___default.a.object,
|
1757 |
+
|
1758 |
+
/**
|
1759 |
+
* Report name, if different than the endpoint.
|
1760 |
+
*/
|
1761 |
+
report: prop_types__WEBPACK_IMPORTED_MODULE_4___default.a.string
|
1762 |
+
};
|
1763 |
+
ReportSummary.defaultProps = {
|
1764 |
+
summaryData: {
|
1765 |
+
totals: {
|
1766 |
+
primary: {},
|
1767 |
+
secondary: {}
|
1768 |
+
},
|
1769 |
+
isError: false
|
1770 |
+
}
|
1771 |
+
};
|
1772 |
+
ReportSummary.contextType = _lib_currency_context__WEBPACK_IMPORTED_MODULE_12__[/* CurrencyContext */ "a"];
|
1773 |
+
/* harmony default export */ __webpack_exports__["a"] = (Object(_wordpress_compose__WEBPACK_IMPORTED_MODULE_2__["compose"])(Object(_wordpress_data__WEBPACK_IMPORTED_MODULE_3__["withSelect"])((select, props) => {
|
1774 |
+
const {
|
1775 |
+
charts,
|
1776 |
+
endpoint,
|
1777 |
+
limitProperties,
|
1778 |
+
query,
|
1779 |
+
filters,
|
1780 |
+
advancedFilters
|
1781 |
+
} = props;
|
1782 |
+
const limitBy = limitProperties || [endpoint];
|
1783 |
+
const hasLimitByParam = limitBy.some(item => query[item] && query[item].length);
|
1784 |
+
|
1785 |
+
if (query.search && !hasLimitByParam) {
|
1786 |
+
return {
|
1787 |
+
emptySearchResults: true
|
1788 |
+
};
|
1789 |
+
}
|
1790 |
+
|
1791 |
+
const fields = charts && charts.map(chart => chart.key);
|
1792 |
+
const {
|
1793 |
+
woocommerce_default_date_range: defaultDateRange
|
1794 |
+
} = select(_woocommerce_data__WEBPACK_IMPORTED_MODULE_8__["SETTINGS_STORE_NAME"]).getSetting('wc_admin', 'wcAdminSettings');
|
1795 |
+
const summaryData = Object(_woocommerce_data__WEBPACK_IMPORTED_MODULE_8__["getSummaryNumbers"])({
|
1796 |
+
endpoint,
|
1797 |
+
query,
|
1798 |
+
select,
|
1799 |
+
limitBy,
|
1800 |
+
filters,
|
1801 |
+
advancedFilters,
|
1802 |
+
defaultDateRange,
|
1803 |
+
fields
|
1804 |
+
});
|
1805 |
+
return {
|
1806 |
+
summaryData,
|
1807 |
+
defaultDateRange
|
1808 |
+
};
|
1809 |
+
}))(ReportSummary));
|
1810 |
+
|
1811 |
+
/***/ }),
|
1812 |
+
|
1813 |
+
/***/ 518:
|
1814 |
+
/***/ (function(module, exports, __webpack_require__) {
|
1815 |
+
|
1816 |
+
// extracted by mini-css-extract-plugin
|
1817 |
+
|
1818 |
+
/***/ })
|
1819 |
+
|
1820 |
+
}]);
|
trunk/dist/chunks/0.min.js
ADDED
@@ -0,0 +1 @@
|
|
|
1 |
+
(window.__wcAdmin_webpackJsonp=window.__wcAdmin_webpackJsonp||[]).push([[0],{503:function(e,t,r){"use strict";r.d(t,"b",(function(){return l})),r.d(t,"a",(function(){return d}));var a=r(0),s=r(31),n=r(89),o=r.n(n),i=r(13);const c=o()(i.a),l=e=>{const t=c.getCurrencyConfig(),r=Object(s.applyFilters)("woocommerce_admin_report_currency",t,e);return o()(r)},d=Object(a.createContext)(c)},506:function(e,t,r){"use strict";var a=r(0),s=r(2),n=r(1),o=r.n(n),i=r(21);function c({className:e}){const t=Object(s.__)("There was an error getting your stats. Please try again.","woocommerce-admin"),r=Object(s.__)("Reload","woocommerce-admin");return Object(a.createElement)(i.EmptyContent,{className:e,title:t,actionLabel:r,actionCallback:()=>{window.location.reload()}})}c.propTypes={className:o.a.string},t.a=c},508:function(e,t,r){"use strict";var a=r(0),s=r(14),n=r(1),o=r.n(n),i=r(4),c=r(7),l=r(21),d=r(13),m=r(11),u=r(20),p=r(15),b=r(503),y=r(55);class g extends a.Component{constructor(){super(),this.onDateSelect=this.onDateSelect.bind(this),this.onFilterSelect=this.onFilterSelect.bind(this),this.onAdvancedFilterAction=this.onAdvancedFilterAction.bind(this)}onDateSelect(e){const{report:t,addCesSurveyForAnalytics:r}=this.props;r(),Object(p.recordEvent)("datepicker_update",{report:t,...Object(i.omitBy)(e,i.isUndefined)})}onFilterSelect(e){const{report:t,addCesSurveyForAnalytics:r}=this.props,a=e.filter||e["filter-variations"];["single_product","single_category","single_coupon","single_variation"].includes(a)&&r();const s={report:t,filter:e.filter||"all"};"single_product"===e.filter&&(s.filter_variation=e["filter-variations"]||"all"),Object(p.recordEvent)("analytics_filter",s)}onAdvancedFilterAction(e,t){const{report:r,addCesSurveyForAnalytics:a}=this.props;switch(e){case"add":Object(p.recordEvent)("analytics_filters_add",{report:r,filter:t.key});break;case"remove":Object(p.recordEvent)("analytics_filters_remove",{report:r,filter:t.key});break;case"filter":const e=Object.keys(t).reduce((e,r)=>(e[Object(i.snakeCase)(r)]=t[r],e),{});a(),Object(p.recordEvent)("analytics_filters_filter",{report:r,...e});break;case"clear_all":Object(p.recordEvent)("analytics_filters_clear_all",{report:r});break;case"match":Object(p.recordEvent)("analytics_filters_all_any",{report:r,value:t.match})}}render(){const{advancedFilters:e,filters:t,path:r,query:s,showDatePicker:n,defaultDateRange:o}=this.props,{period:i,compare:c,before:m,after:p}=Object(u.getDateParamsFromQuery)(s,o),{primary:b,secondary:y}=Object(u.getCurrentDates)(s,o),g={period:i,compare:c,before:m,after:p,primaryDate:b,secondaryDate:y},h=this.context;return Object(a.createElement)(l.ReportFilters,{query:s,siteLocale:d.b.siteLocale,currency:h.getCurrencyConfig(),path:r,filters:t,advancedFilters:e,showDatePicker:n,onDateSelect:this.onDateSelect,onFilterSelect:this.onFilterSelect,onAdvancedFilterAction:this.onAdvancedFilterAction,dateQuery:g,isoDateFormat:u.isoDateFormat})}}g.contextType=b.a,t.a=Object(s.compose)(Object(c.withSelect)(e=>{const{woocommerce_default_date_range:t}=e(m.SETTINGS_STORE_NAME).getSetting("wc_admin","wcAdminSettings");return{defaultDateRange:t}}),Object(c.withDispatch)(e=>{const{addCesSurveyForAnalytics:t}=e(y.c);return{addCesSurveyForAnalytics:t}}))(g),g.propTypes={advancedFilters:o.a.object,filters:o.a.array,path:o.a.string.isRequired,query:o.a.object,showDatePicker:o.a.bool,report:o.a.string.isRequired}},509:function(e,t,r){"use strict";var a=r(36),s=r.n(a),n=r(0),o=r(3),i=r(31),c=r(14),l=r(91),d=r(7),m=r(4),u=r(2),p=r(1),b=r.n(p),y=r(21),g=r(12),h=r(476),f=r(11),_=r(15),O=()=>Object(n.createElement)("svg",{role:"img","aria-hidden":"true",focusable:"false",version:"1.1",xmlns:"http://www.w3.org/2000/svg",x:"0px",y:"0px",viewBox:"0 0 24 24"},Object(n.createElement)("path",{d:"M18,9c-0.009,0-0.017,0.002-0.025,0.003C17.72,5.646,14.922,3,11.5,3C7.91,3,5,5.91,5,9.5c0,0.524,0.069,1.031,0.186,1.519 C5.123,11.016,5.064,11,5,11c-2.209,0-4,1.791-4,4c0,1.202,0.541,2.267,1.38,3h18.593C22.196,17.089,23,15.643,23,14 C23,11.239,20.761,9,18,9z M12,16l-4-5h3V8h2v3h3L12,16z"})),j=r(506);var v=r(55);r(518);const C=e=>{const{getHeadersContent:t,getRowsContent:r,getSummary:a,isRequesting:c,primaryData:d,tableData:p,endpoint:b,itemIdField:v,tableQuery:C,compareBy:w,compareParam:R,searchBy:S,labels:D={},...E}=e,{query:q,columnPrefsKey:F}=e,{items:T,query:k}=p,x=q[R]?Object(g.getIdsFromQuery)(q[w]):[],[P,A]=Object(n.useState)(x),N=Object(n.useRef)(null),{updateUserPreferences:I,...Q}=Object(f.useUserPreferences)();if(p.isError||d.isError)return Object(n.createElement)(j.a,null);let B=[];F&&(B=Q&&Q[F]?Q[F]:B);const L=(e,s,n)=>{const o=a?a(s,n):null;return Object(i.applyFilters)("woocommerce_admin_report_table",{endpoint:b,headers:t(),rows:r(e),totals:s,summary:o,items:T})},V=t=>{const{ids:r}=e;A(t?r:[])},M=(t,r)=>{const{ids:a}=e;if(r)A(Object(m.uniq)([a[t],...P]));else{const e=P.indexOf(a[t]);A([...P.slice(0,e),...P.slice(e+1)])}},H=t=>{const{ids:r=[]}=e,a=-1!==P.indexOf(r[t]);return{display:Object(n.createElement)(o.CheckboxControl,{onChange:Object(m.partial)(M,t),checked:a}),value:!1}},Y=()=>{const{ids:t=[]}=e,r=t.length>0,a=r&&t.length===P.length;return{cellClassName:"is-checkbox-column",key:"compare",label:Object(n.createElement)(o.CheckboxControl,{onChange:V,"aria-label":Object(u.__)("Select All"),checked:a,disabled:!r}),required:!0}},U=c||p.isRequesting||d.isRequesting,G=Object(m.get)(d,["data","totals"],{}),$=T.totalResults||0,z=$>0,J=Object(g.getSearchWords)(q).map(e=>({key:e,label:e})),{data:K}=T,W=L(K,G,$);let{headers:X,rows:Z}=W;const{summary:ee}=W;w&&(Z=Z.map((e,t)=>[H(t),...e]),X=[Y(),...X]);const te=((e,t)=>t?e.map(e=>({...e,visible:e.required||!t.includes(e.key)})):e.map(e=>({...e,visible:e.required||!e.hiddenByDefault})))(X,B);return Object(n.createElement)(n.Fragment,null,Object(n.createElement)("div",{className:"woocommerce-report-table__scroll-point",ref:N,"aria-hidden":!0}),Object(n.createElement)(y.TableCard,s()({className:"woocommerce-report-table",hasSearch:!!S,actions:[w&&Object(n.createElement)(y.CompareButton,{key:"compare",className:"woocommerce-table__compare",count:P.length,helpText:D.helpText||Object(u.__)("Check at least two items below to compare","woocommerce-admin"),onClick:()=>{w&&Object(g.onQueryChange)("compare")(w,R,P.join(","))},disabled:!z},D.compareButton||Object(u.__)("Compare","woocommerce-admin")),S&&Object(n.createElement)(y.Search,{allowFreeTextSearch:!0,inlineTags:!0,key:"search",onChange:t=>{const{baseSearchQuery:r,addCesSurveyForCustomerSearch:a}=e,s=t.map(e=>e.label.replace(",","%2C"));s.length?(Object(g.updateQueryString)({filter:void 0,[R]:void 0,[S]:void 0,...r,search:Object(m.uniq)(s).join(",")}),a()):Object(g.updateQueryString)({search:void 0}),Object(_.recordEvent)("analytics_table_filter",{report:b})},placeholder:D.placeholder||Object(u.__)("Search by item name","woocommerce-admin"),selected:J,showClearButton:!0,type:S,disabled:!z}),z&&Object(n.createElement)(o.Button,{key:"download",className:"woocommerce-table__download-button",disabled:U,onClick:()=>{const{createNotice:t,startExport:r,title:a}=e,s=Object.assign({},q),{data:n,totalResults:o}=T;let i="browser";if(delete s.extended_info,s.search&&delete s[S],n&&n.length===o){const{headers:e,rows:t}=L(n,o);Object(h.downloadCSVFile)(Object(h.generateCSVFileName)(a,s),Object(h.generateCSVDataFromTable)(e,t))}else i="email",r(b,k).then(()=>t("success",Object(u.sprintf)(Object(u.__)("Your %s Report will be emailed to you.","woocommerce-admin"),a))).catch(e=>t("error",e.message||Object(u.sprintf)(Object(u.__)("There was a problem exporting your %s Report. Please try again.","woocommerce-admin"),a)));Object(_.recordEvent)("analytics_table_download",{report:b,rows:o,download_type:i})}},Object(n.createElement)(O,null),Object(n.createElement)("span",{className:"woocommerce-table__download-button__label"},D.downloadButton||Object(u.__)("Download","woocommerce-admin")))],headers:te,isLoading:U,onQueryChange:g.onQueryChange,onColumnsChange:(e,t)=>{const r=X.map(e=>e.key).filter(t=>!e.includes(t));if(F){I({[F]:r})}if(t){const r={report:b,column:t,status:e.includes(t)?"on":"off"};Object(_.recordEvent)("analytics_table_header_toggle",r)}},onSort:(e,t)=>{Object(g.onQueryChange)("sort")(e,t);const r={report:b,column:e,direction:t};Object(_.recordEvent)("analytics_table_sort",r)},onPageChange:(e,t)=>{N.current.scrollIntoView();const r=N.current.nextSibling.querySelector(".woocommerce-table__table"),a=l.focus.focusable.find(r);a.length&&a[0].focus(),t&&("goto"===t?Object(_.recordEvent)("analytics_table_go_to_page",{report:b,page:e}):Object(_.recordEvent)("analytics_table_page_click",{report:b,direction:t}))},rows:Z,rowsPerPage:parseInt(k.per_page,10)||f.QUERY_DEFAULTS.pageSize,summary:ee,totalRows:$},E)))};C.propTypes={baseSearchQuery:b.a.object,compareBy:b.a.string,compareParam:b.a.string,columnPrefsKey:b.a.string,endpoint:b.a.string,extendItemsMethodNames:b.a.shape({getError:b.a.string,isRequesting:b.a.string,load:b.a.string}),extendedItemsStoreName:b.a.string,getHeadersContent:b.a.func.isRequired,getRowsContent:b.a.func.isRequired,getSummary:b.a.func,itemIdField:b.a.string,labels:b.a.shape({compareButton:b.a.string,downloadButton:b.a.string,helpText:b.a.string,placeholder:b.a.string}),primaryData:b.a.object,searchBy:b.a.string,summaryFields:b.a.arrayOf(b.a.string),tableData:b.a.object.isRequired,tableQuery:b.a.object,title:b.a.string.isRequired},C.defaultProps={primaryData:{},tableData:{items:{data:[],totalResults:0},query:{}},tableQuery:{},compareParam:"filter",downloadable:!1,onSearch:m.noop,baseSearchQuery:{}};const w=[],R={};t.a=Object(c.compose)(Object(d.withSelect)((e,t)=>{const{endpoint:r,getSummary:a,isRequesting:s,itemIdField:n,query:o,tableData:i,tableQuery:c,filters:l,advancedFilters:d,summaryFields:u,extendedItemsStoreName:p}=t,b=e(f.REPORTS_STORE_NAME),y=p?e(p):null,{woocommerce_default_date_range:g}=e(f.SETTINGS_STORE_NAME).getSetting("wc_admin","wcAdminSettings");if(s)return R;const h="categories"===r?"products":r,_=a?Object(f.getReportChartData)({endpoint:h,selector:b,dataType:"primary",query:o,filters:l,advancedFilters:d,defaultDateRange:g,fields:u}):R,O=i||Object(f.getReportTableData)({endpoint:r,query:o,selector:b,tableQuery:c,filters:l,advancedFilters:d,defaultDateRange:g}),j=y?function(e,t,r){const{extendItemsMethodNames:a,itemIdField:s}=t,n=r.items.data;if(!(Array.isArray(n)&&n.length&&a&&s))return r;const{[a.getError]:o,[a.isRequesting]:i,[a.load]:c}=e,l={include:n.map(e=>e[s]).join(","),per_page:n.length},d=c(l),u=!!i&&i(l),p=!!o&&o(l),b=n.map(e=>{const t=Object(m.first)(d.filter(t=>e.id===t.id));return{...e,...t}}),y=r.isRequesting||u,g=r.isError||p;return{...r,isRequesting:y,isError:g,items:{...r.items,data:b}}}(y,t,O):O;return{primaryData:_,ids:n&&j.items.data?j.items.data.map(e=>e[n]):w,tableData:j,query:o}}),Object(d.withDispatch)(e=>{const{startExport:t}=e(f.EXPORT_STORE_NAME),{createNotice:r}=e("core/notices"),{addCesSurveyForCustomerSearch:a}=e(v.c);return{createNotice:r,startExport:t,addCesSurveyForCustomerSearch:a}}))(C)},510:function(e,t,r){"use strict";var a=r(0),s=r(2),n=r(14),o=r(61),i=r(7),c=r(4),l=r(1),d=r.n(l),m=r(21),u=r(11),p=r(20),b=r(503),y=r(506),g=r(12);class h extends a.Component{shouldComponentUpdate(e){return e.isRequesting!==this.props.isRequesting||e.primaryData.isRequesting!==this.props.primaryData.isRequesting||e.secondaryData.isRequesting!==this.props.secondaryData.isRequesting||!Object(c.isEqual)(e.query,this.props.query)}getItemChartData(){const{primaryData:e,selectedChart:t}=this.props;return e.data.intervals.map((function(e){const r={};return e.subtotals.segments.forEach((function(e){if(e.segment_label){const a=r[e.segment_label]?e.segment_label+" (#"+e.segment_id+")":e.segment_label;r[e.segment_id]={label:a,value:e.subtotals[t.key]||0}}})),{date:Object(o.format)("Y-m-d\\TH:i:s",e.date_start),...r}}))}getTimeChartData(){const{query:e,primaryData:t,secondaryData:r,selectedChart:a,defaultDateRange:s}=this.props,n=Object(p.getIntervalForQuery)(e),{primary:i,secondary:c}=Object(p.getCurrentDates)(e,s);return t.data.intervals.map((function(t,s){const l=Object(p.getPreviousDate)(t.date_start,i.after,c.after,e.compare,n),d=r.data.intervals[s];return{date:Object(o.format)("Y-m-d\\TH:i:s",t.date_start),primary:{label:`${i.label} (${i.range})`,labelDate:t.date_start,value:t.subtotals[a.key]||0},secondary:{label:`${c.label} (${c.range})`,labelDate:l.format("YYYY-MM-DD HH:mm:ss"),value:d&&d.subtotals[a.key]||0}}}))}getTimeChartTotals(){const{primaryData:e,secondaryData:t,selectedChart:r}=this.props;return{primary:Object(c.get)(e,["data","totals",r.key],null),secondary:Object(c.get)(t,["data","totals",r.key],null)}}renderChart(e,t,r,n){const{emptySearchResults:o,filterParam:i,interactiveLegend:c,itemsLabel:l,legendPosition:d,path:b,query:y,selectedChart:g,showHeaderControls:h,primaryData:f}=this.props,_=Object(p.getIntervalForQuery)(y),O=Object(p.getAllowedIntervalsForQuery)(y),j=Object(p.getDateFormatsForInterval)(_,f.data.intervals.length),v=o?Object(s.__)("No data for the current search","woocommerce-admin"):Object(s.__)("No data for the selected date range","woocommerce-admin"),{formatAmount:C,getCurrencyConfig:w}=this.context;return Object(a.createElement)(m.Chart,{allowedIntervals:O,data:r,dateParser:"%Y-%m-%dT%H:%M:%S",emptyMessage:v,filterParam:i,interactiveLegend:c,interval:_,isRequesting:t,itemsLabel:l,legendPosition:d,legendTotals:n,mode:e,path:b,query:y,screenReaderFormat:j.screenReaderFormat,showHeaderControls:h,title:g.label,tooltipLabelFormat:j.tooltipLabelFormat,tooltipTitle:"time-comparison"===e&&g.label||null,tooltipValueFormat:Object(u.getTooltipValueFormat)(g.type,C),chartType:Object(p.getChartTypeForQuery)(y),valueType:g.type,xFormat:j.xFormat,x2Format:j.x2Format,currency:w()})}renderItemComparison(){const{isRequesting:e,primaryData:t}=this.props;if(t.isError)return Object(a.createElement)(y.a,null);const r=e||t.isRequesting,s=this.getItemChartData();return this.renderChart("item-comparison",r,s)}renderTimeComparison(){const{isRequesting:e,primaryData:t,secondaryData:r}=this.props;if(!t||t.isError||r.isError)return Object(a.createElement)(y.a,null);const s=e||t.isRequesting||r.isRequesting,n=this.getTimeChartData(),o=this.getTimeChartTotals();return this.renderChart("time-comparison",s,n,o)}render(){const{mode:e}=this.props;return"item-comparison"===e?this.renderItemComparison():this.renderTimeComparison()}}h.contextType=b.a,h.propTypes={filters:d.a.array,isRequesting:d.a.bool,itemsLabel:d.a.string,limitProperties:d.a.array,mode:d.a.string,path:d.a.string.isRequired,primaryData:d.a.object,query:d.a.object.isRequired,secondaryData:d.a.object,selectedChart:d.a.shape({key:d.a.string.isRequired,label:d.a.string.isRequired,order:d.a.oneOf(["asc","desc"]),orderby:d.a.string,type:d.a.oneOf(["average","number","currency"]).isRequired}).isRequired},h.defaultProps={isRequesting:!1,primaryData:{data:{intervals:[]},isError:!1,isRequesting:!1},secondaryData:{data:{intervals:[]},isError:!1,isRequesting:!1}};t.a=Object(n.compose)(Object(i.withSelect)((e,t)=>{const{charts:r,endpoint:a,filters:s,isRequesting:n,limitProperties:o,query:i,advancedFilters:l}=t,d=o||[a],m=function e(t,r,a={}){if(!t||0===t.length)return null;const s=t.slice(0),n=s.pop();if(n.showFilters(r,a)){const e=Object(g.flattenFilters)(n.filters),t=r[n.param]||n.defaultValue||"all";return Object(c.find)(e,{value:t})}return e(s,r,a)}(s,i),p=Object(c.get)(m,["settings","param"]),b=t.mode||function(e,t){if(e&&t){const r=Object(c.get)(e,["settings","param"]);if(!r||Object.keys(t).includes(r))return Object(c.get)(e,["chartMode"])}return null}(m,i)||"time-comparison",{woocommerce_default_date_range:y}=e(u.SETTINGS_STORE_NAME).getSetting("wc_admin","wcAdminSettings"),h=e(u.REPORTS_STORE_NAME),f={mode:b,filterParam:p,defaultDateRange:y};if(n)return f;const _=d.some(e=>i[e]&&i[e].length);if(i.search&&!_)return{...f,emptySearchResults:!0};const O=r&&r.map(e=>e.key),j=Object(u.getReportChartData)({endpoint:a,dataType:"primary",query:i,selector:h,limitBy:d,filters:s,advancedFilters:l,defaultDateRange:y,fields:O});if("item-comparison"===b)return{...f,primaryData:j};const v=Object(u.getReportChartData)({endpoint:a,dataType:"secondary",query:i,selector:h,limitBy:d,filters:s,advancedFilters:l,defaultDateRange:y,fields:O});return{...f,primaryData:j,secondaryData:v}}))(h)},512:function(e,t,r){"use strict";r.d(t,"a",(function(){return s}));var a=r(4);function s(e,t=[]){const r=Object(a.find)(t,{key:e});return r||t[0]}},513:function(e,t,r){"use strict";var a=r(0),s=r(2),n=r(14),o=r(7),i=r(1),c=r.n(i),l=r(12),d=r(21),m=r(120),u=r(11),p=r(20),b=r(15),y=r(506),g=r(503);class h extends a.Component{formatVal(e,t){const{formatAmount:r,getCurrencyConfig:a}=this.context;return"currency"===t?r(e):Object(m.formatValue)(a(),t,e)}getValues(e,t){const{emptySearchResults:r,summaryData:a}=this.props,{totals:s}=a,n=s.primary?s.primary[e]:0,o=s.secondary?s.secondary[e]:0,i=r?0:n,c=r?0:o;return{delta:Object(m.calculateDelta)(i,c),prevValue:this.formatVal(c,t),value:this.formatVal(i,t)}}render(){const{charts:e,query:t,selectedChart:r,summaryData:n,endpoint:o,report:i,defaultDateRange:c}=this.props,{isError:m,isRequesting:u}=n;if(m)return Object(a.createElement)(y.a,null);if(u)return Object(a.createElement)(d.SummaryListPlaceholder,{numberOfItems:e.length});const{compare:g}=Object(p.getDateParamsFromQuery)(t,c);return Object(a.createElement)(d.SummaryList,null,({onToggle:t})=>e.map(e=>{const{key:n,order:c,orderby:m,label:u,type:p,isReverseTrend:y}=e,h={chart:n};m&&(h.orderby=m),c&&(h.order=c);const f=Object(l.getNewPath)(h),_=r.key===n,{delta:O,prevValue:j,value:v}=this.getValues(n,p);return Object(a.createElement)(d.SummaryNumber,{key:n,delta:O,href:f,label:u,reverseTrend:y,prevLabel:"previous_period"===g?Object(s.__)("Previous period:","woocommerce-admin"):Object(s.__)("Previous year:","woocommerce-admin"),prevValue:j,selected:_,value:v,onLinkClickCallback:()=>{t&&t(),Object(b.recordEvent)("analytics_chart_tab_click",{report:i||o,key:n})}})}))}}h.propTypes={charts:c.a.array.isRequired,endpoint:c.a.string.isRequired,limitProperties:c.a.array,query:c.a.object.isRequired,selectedChart:c.a.shape({key:c.a.string.isRequired,label:c.a.string.isRequired,order:c.a.oneOf(["asc","desc"]),orderby:c.a.string,type:c.a.oneOf(["average","number","currency"]).isRequired}).isRequired,summaryData:c.a.object,report:c.a.string},h.defaultProps={summaryData:{totals:{primary:{},secondary:{}},isError:!1}},h.contextType=g.a,t.a=Object(n.compose)(Object(o.withSelect)((e,t)=>{const{charts:r,endpoint:a,limitProperties:s,query:n,filters:o,advancedFilters:i}=t,c=s||[a],l=c.some(e=>n[e]&&n[e].length);if(n.search&&!l)return{emptySearchResults:!0};const d=r&&r.map(e=>e.key),{woocommerce_default_date_range:m}=e(u.SETTINGS_STORE_NAME).getSetting("wc_admin","wcAdminSettings");return{summaryData:Object(u.getSummaryNumbers)({endpoint:a,query:n,select:e,limitBy:c,filters:o,advancedFilters:i,defaultDateRange:m,fields:d}),defaultDateRange:m}}))(h)},518:function(e,t,r){}}]);
|
trunk/dist/chunks/0.style.css
ADDED
@@ -0,0 +1 @@
|
|
|
1 |
+
:root{--wp-admin-theme-color:#007cba;--wp-admin-theme-color-darker-10:#006ba1;--wp-admin-theme-color-darker-20:#005a87}body.admin-color-light{--wp-admin-theme-color:#0085ba;--wp-admin-theme-color-darker-10:#0073a1;--wp-admin-theme-color-darker-20:#006187}body.admin-color-modern{--wp-admin-theme-color:#3858e9;--wp-admin-theme-color-darker-10:#2145e6;--wp-admin-theme-color-darker-20:#183ad6}body.admin-color-blue{--wp-admin-theme-color:#096484;--wp-admin-theme-color-darker-10:#07526c;--wp-admin-theme-color-darker-20:#064054}body.admin-color-coffee{--wp-admin-theme-color:#46403c;--wp-admin-theme-color-darker-10:#383330;--wp-admin-theme-color-darker-20:#2b2724}body.admin-color-ectoplasm{--wp-admin-theme-color:#523f6d;--wp-admin-theme-color-darker-10:#46365d;--wp-admin-theme-color-darker-20:#3a2c4d}body.admin-color-midnight{--wp-admin-theme-color:#e14d43;--wp-admin-theme-color-darker-10:#dd382d;--wp-admin-theme-color-darker-20:#d02c21}body.admin-color-ocean{--wp-admin-theme-color:#627c83;--wp-admin-theme-color-darker-10:#576e74;--wp-admin-theme-color-darker-20:#4c6066}body.admin-color-sunrise{--wp-admin-theme-color:#dd823b;--wp-admin-theme-color-darker-10:#d97426;--wp-admin-theme-color-darker-20:#c36922}.woocommerce-report-table__scroll-point{position:relative;top:-48px}@media(max-width:782px){.woocommerce-report-table__scroll-point{top:-62px}}.woocommerce-feature-enabled-activity-panels .woocommerce-report-table__scroll-point{top:-108px}@media(max-width:782px){.woocommerce-feature-enabled-activity-panels .woocommerce-report-table__scroll-point{top:-122px}}.woocommerce-report-table .woocommerce-search{flex-grow:1}.woocommerce-report-table .components-card__header{display:grid;grid-gap:12px;grid-template-columns:min-content 1fr min-content}.woocommerce-report-table .woocommerce-table__compare.components-button{padding:8px}.woocommerce-report-table .woocommerce-ellipsis-menu{justify-self:flex-end}button.woocommerce-table__download-button{padding:6px 12px;color:#000;text-decoration:none;align-items:center}button.woocommerce-table__download-button svg{margin-right:8px;height:24px;width:24px}@media(max-width:782px){button.woocommerce-table__download-button svg{margin-right:0}button.woocommerce-table__download-button .woocommerce-table__download-button__label{display:none}}
|
trunk/dist/chunks/0.style.rtl.css
ADDED
@@ -0,0 +1 @@
|
|
|
1 |
+
:root{--wp-admin-theme-color:#007cba;--wp-admin-theme-color-darker-10:#006ba1;--wp-admin-theme-color-darker-20:#005a87}body.admin-color-light{--wp-admin-theme-color:#0085ba;--wp-admin-theme-color-darker-10:#0073a1;--wp-admin-theme-color-darker-20:#006187}body.admin-color-modern{--wp-admin-theme-color:#3858e9;--wp-admin-theme-color-darker-10:#2145e6;--wp-admin-theme-color-darker-20:#183ad6}body.admin-color-blue{--wp-admin-theme-color:#096484;--wp-admin-theme-color-darker-10:#07526c;--wp-admin-theme-color-darker-20:#064054}body.admin-color-coffee{--wp-admin-theme-color:#46403c;--wp-admin-theme-color-darker-10:#383330;--wp-admin-theme-color-darker-20:#2b2724}body.admin-color-ectoplasm{--wp-admin-theme-color:#523f6d;--wp-admin-theme-color-darker-10:#46365d;--wp-admin-theme-color-darker-20:#3a2c4d}body.admin-color-midnight{--wp-admin-theme-color:#e14d43;--wp-admin-theme-color-darker-10:#dd382d;--wp-admin-theme-color-darker-20:#d02c21}body.admin-color-ocean{--wp-admin-theme-color:#627c83;--wp-admin-theme-color-darker-10:#576e74;--wp-admin-theme-color-darker-20:#4c6066}body.admin-color-sunrise{--wp-admin-theme-color:#dd823b;--wp-admin-theme-color-darker-10:#d97426;--wp-admin-theme-color-darker-20:#c36922}.woocommerce-report-table__scroll-point{position:relative;top:-48px}@media(max-width:782px){.woocommerce-report-table__scroll-point{top:-62px}}.woocommerce-feature-enabled-activity-panels .woocommerce-report-table__scroll-point{top:-108px}@media(max-width:782px){.woocommerce-feature-enabled-activity-panels .woocommerce-report-table__scroll-point{top:-122px}}.woocommerce-report-table .woocommerce-search{flex-grow:1}.woocommerce-report-table .components-card__header{display:grid;grid-gap:12px;grid-template-columns:min-content 1fr min-content}.woocommerce-report-table .woocommerce-table__compare.components-button{padding:8px}.woocommerce-report-table .woocommerce-ellipsis-menu{justify-self:flex-end}button.woocommerce-table__download-button{padding:6px 12px;color:#000;text-decoration:none;align-items:center}button.woocommerce-table__download-button svg{margin-left:8px;height:24px;width:24px}@media(max-width:782px){button.woocommerce-table__download-button svg{margin-left:0}button.woocommerce-table__download-button .woocommerce-table__download-button__label{display:none}}
|
trunk/dist/chunks/1.js
ADDED
@@ -0,0 +1,1365 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|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p"] = window["__wcAdmin_webpackJsonp"] || []).push([[1],{
|
2 |
+
|
3 |
+
/***/ 53:
|
4 |
+
/***/ (function(module, exports, __webpack_require__) {
|
5 |
+
|
6 |
+
/*! @license DOMPurify | (c) Cure53 and other contributors | Released under the Apache license 2.0 and Mozilla Public License 2.0 | github.com/cure53/DOMPurify/blob/2.2.2/LICENSE */
|
7 |
+
|
8 |
+
(function (global, factory) {
|
9 |
+
true ? module.exports = factory() :
|
10 |
+
undefined;
|
11 |
+
}(this, function () { 'use strict';
|
12 |
+
|
13 |
+
function _toConsumableArray(arr) { if (Array.isArray(arr)) { for (var i = 0, arr2 = Array(arr.length); i < arr.length; i++) { arr2[i] = arr[i]; } return arr2; } else { return Array.from(arr); } }
|
14 |
+
|
15 |
+
var hasOwnProperty = Object.hasOwnProperty,
|
16 |
+
setPrototypeOf = Object.setPrototypeOf,
|
17 |
+
isFrozen = Object.isFrozen,
|
18 |
+
getPrototypeOf = Object.getPrototypeOf,
|
19 |
+
getOwnPropertyDescriptor = Object.getOwnPropertyDescriptor;
|
20 |
+
var freeze = Object.freeze,
|
21 |
+
seal = Object.seal,
|
22 |
+
create = Object.create; // eslint-disable-line import/no-mutable-exports
|
23 |
+
|
24 |
+
var _ref = typeof Reflect !== 'undefined' && Reflect,
|
25 |
+
apply = _ref.apply,
|
26 |
+
construct = _ref.construct;
|
27 |
+
|
28 |
+
if (!apply) {
|
29 |
+
apply = function apply(fun, thisValue, args) {
|
30 |
+
return fun.apply(thisValue, args);
|
31 |
+
};
|
32 |
+
}
|
33 |
+
|
34 |
+
if (!freeze) {
|
35 |
+
freeze = function freeze(x) {
|
36 |
+
return x;
|
37 |
+
};
|
38 |
+
}
|
39 |
+
|
40 |
+
if (!seal) {
|
41 |
+
seal = function seal(x) {
|
42 |
+
return x;
|
43 |
+
};
|
44 |
+
}
|
45 |
+
|
46 |
+
if (!construct) {
|
47 |
+
construct = function construct(Func, args) {
|
48 |
+
return new (Function.prototype.bind.apply(Func, [null].concat(_toConsumableArray(args))))();
|
49 |
+
};
|
50 |
+
}
|
51 |
+
|
52 |
+
var arrayForEach = unapply(Array.prototype.forEach);
|
53 |
+
var arrayPop = unapply(Array.prototype.pop);
|
54 |
+
var arrayPush = unapply(Array.prototype.push);
|
55 |
+
|
56 |
+
var stringToLowerCase = unapply(String.prototype.toLowerCase);
|
57 |
+
var stringMatch = unapply(String.prototype.match);
|
58 |
+
var stringReplace = unapply(String.prototype.replace);
|
59 |
+
var stringIndexOf = unapply(String.prototype.indexOf);
|
60 |
+
var stringTrim = unapply(String.prototype.trim);
|
61 |
+
|
62 |
+
var regExpTest = unapply(RegExp.prototype.test);
|
63 |
+
|
64 |
+
var typeErrorCreate = unconstruct(TypeError);
|
65 |
+
|
66 |
+
function unapply(func) {
|
67 |
+
return function (thisArg) {
|
68 |
+
for (var _len = arguments.length, args = Array(_len > 1 ? _len - 1 : 0), _key = 1; _key < _len; _key++) {
|
69 |
+
args[_key - 1] = arguments[_key];
|
70 |
+
}
|
71 |
+
|
72 |
+
return apply(func, thisArg, args);
|
73 |
+
};
|
74 |
+
}
|
75 |
+
|
76 |
+
function unconstruct(func) {
|
77 |
+
return function () {
|
78 |
+
for (var _len2 = arguments.length, args = Array(_len2), _key2 = 0; _key2 < _len2; _key2++) {
|
79 |
+
args[_key2] = arguments[_key2];
|
80 |
+
}
|
81 |
+
|
82 |
+
return construct(func, args);
|
83 |
+
};
|
84 |
+
}
|
85 |
+
|
86 |
+
/* Add properties to a lookup table */
|
87 |
+
function addToSet(set, array) {
|
88 |
+
if (setPrototypeOf) {
|
89 |
+
// Make 'in' and truthy checks like Boolean(set.constructor)
|
90 |
+
// independent of any properties defined on Object.prototype.
|
91 |
+
// Prevent prototype setters from intercepting set as a this value.
|
92 |
+
setPrototypeOf(set, null);
|
93 |
+
}
|
94 |
+
|
95 |
+
var l = array.length;
|
96 |
+
while (l--) {
|
97 |
+
var element = array[l];
|
98 |
+
if (typeof element === 'string') {
|
99 |
+
var lcElement = stringToLowerCase(element);
|
100 |
+
if (lcElement !== element) {
|
101 |
+
// Config presets (e.g. tags.js, attrs.js) are immutable.
|
102 |
+
if (!isFrozen(array)) {
|
103 |
+
array[l] = lcElement;
|
104 |
+
}
|
105 |
+
|
106 |
+
element = lcElement;
|
107 |
+
}
|
108 |
+
}
|
109 |
+
|
110 |
+
set[element] = true;
|
111 |
+
}
|
112 |
+
|
113 |
+
return set;
|
114 |
+
}
|
115 |
+
|
116 |
+
/* Shallow clone an object */
|
117 |
+
function clone(object) {
|
118 |
+
var newObject = create(null);
|
119 |
+
|
120 |
+
var property = void 0;
|
121 |
+
for (property in object) {
|
122 |
+
if (apply(hasOwnProperty, object, [property])) {
|
123 |
+
newObject[property] = object[property];
|
124 |
+
}
|
125 |
+
}
|
126 |
+
|
127 |
+
return newObject;
|
128 |
+
}
|
129 |
+
|
130 |
+
/* IE10 doesn't support __lookupGetter__ so lets'
|
131 |
+
* simulate it. It also automatically checks
|
132 |
+
* if the prop is function or getter and behaves
|
133 |
+
* accordingly. */
|
134 |
+
function lookupGetter(object, prop) {
|
135 |
+
while (object !== null) {
|
136 |
+
var desc = getOwnPropertyDescriptor(object, prop);
|
137 |
+
if (desc) {
|
138 |
+
if (desc.get) {
|
139 |
+
return unapply(desc.get);
|
140 |
+
}
|
141 |
+
|
142 |
+
if (typeof desc.value === 'function') {
|
143 |
+
return unapply(desc.value);
|
144 |
+
}
|
145 |
+
}
|
146 |
+
|
147 |
+
object = getPrototypeOf(object);
|
148 |
+
}
|
149 |
+
|
150 |
+
function fallbackValue(element) {
|
151 |
+
console.warn('fallback value for', element);
|
152 |
+
return null;
|
153 |
+
}
|
154 |
+
|
155 |
+
return fallbackValue;
|
156 |
+
}
|
157 |
+
|
158 |
+
var html = freeze(['a', 'abbr', 'acronym', 'address', 'area', 'article', 'aside', 'audio', 'b', 'bdi', 'bdo', 'big', 'blink', 'blockquote', 'body', 'br', 'button', 'canvas', 'caption', 'center', 'cite', 'code', 'col', 'colgroup', 'content', 'data', 'datalist', 'dd', 'decorator', 'del', 'details', 'dfn', 'dialog', 'dir', 'div', 'dl', 'dt', 'element', 'em', 'fieldset', 'figcaption', 'figure', 'font', 'footer', 'form', 'h1', 'h2', 'h3', 'h4', 'h5', 'h6', 'head', 'header', 'hgroup', 'hr', 'html', 'i', 'img', 'input', 'ins', 'kbd', 'label', 'legend', 'li', 'main', 'map', 'mark', 'marquee', 'menu', 'menuitem', 'meter', 'nav', 'nobr', 'ol', 'optgroup', 'option', 'output', 'p', 'picture', 'pre', 'progress', 'q', 'rp', 'rt', 'ruby', 's', 'samp', 'section', 'select', 'shadow', 'small', 'source', 'spacer', 'span', 'strike', 'strong', 'style', 'sub', 'summary', 'sup', 'table', 'tbody', 'td', 'template', 'textarea', 'tfoot', 'th', 'thead', 'time', 'tr', 'track', 'tt', 'u', 'ul', 'var', 'video', 'wbr']);
|
159 |
+
|
160 |
+
// SVG
|
161 |
+
var svg = freeze(['svg', 'a', 'altglyph', 'altglyphdef', 'altglyphitem', 'animatecolor', 'animatemotion', 'animatetransform', 'circle', 'clippath', 'defs', 'desc', 'ellipse', 'filter', 'font', 'g', 'glyph', 'glyphref', 'hkern', 'image', 'line', 'lineargradient', 'marker', 'mask', 'metadata', 'mpath', 'path', 'pattern', 'polygon', 'polyline', 'radialgradient', 'rect', 'stop', 'style', 'switch', 'symbol', 'text', 'textpath', 'title', 'tref', 'tspan', 'view', 'vkern']);
|
162 |
+
|
163 |
+
var svgFilters = freeze(['feBlend', 'feColorMatrix', 'feComponentTransfer', 'feComposite', 'feConvolveMatrix', 'feDiffuseLighting', 'feDisplacementMap', 'feDistantLight', 'feFlood', 'feFuncA', 'feFuncB', 'feFuncG', 'feFuncR', 'feGaussianBlur', 'feMerge', 'feMergeNode', 'feMorphology', 'feOffset', 'fePointLight', 'feSpecularLighting', 'feSpotLight', 'feTile', 'feTurbulence']);
|
164 |
+
|
165 |
+
// List of SVG elements that are disallowed by default.
|
166 |
+
// We still need to know them so that we can do namespace
|
167 |
+
// checks properly in case one wants to add them to
|
168 |
+
// allow-list.
|
169 |
+
var svgDisallowed = freeze(['animate', 'color-profile', 'cursor', 'discard', 'fedropshadow', 'feimage', 'font-face', 'font-face-format', 'font-face-name', 'font-face-src', 'font-face-uri', 'foreignobject', 'hatch', 'hatchpath', 'mesh', 'meshgradient', 'meshpatch', 'meshrow', 'missing-glyph', 'script', 'set', 'solidcolor', 'unknown', 'use']);
|
170 |
+
|
171 |
+
var mathMl = freeze(['math', 'menclose', 'merror', 'mfenced', 'mfrac', 'mglyph', 'mi', 'mlabeledtr', 'mmultiscripts', 'mn', 'mo', 'mover', 'mpadded', 'mphantom', 'mroot', 'mrow', 'ms', 'mspace', 'msqrt', 'mstyle', 'msub', 'msup', 'msubsup', 'mtable', 'mtd', 'mtext', 'mtr', 'munder', 'munderover']);
|
172 |
+
|
173 |
+
// Similarly to SVG, we want to know all MathML elements,
|
174 |
+
// even those that we disallow by default.
|
175 |
+
var mathMlDisallowed = freeze(['maction', 'maligngroup', 'malignmark', 'mlongdiv', 'mscarries', 'mscarry', 'msgroup', 'mstack', 'msline', 'msrow', 'semantics', 'annotation', 'annotation-xml', 'mprescripts', 'none']);
|
176 |
+
|
177 |
+
var text = freeze(['#text']);
|
178 |
+
|
179 |
+
var html$1 = freeze(['accept', 'action', 'align', 'alt', 'autocapitalize', 'autocomplete', 'autopictureinpicture', 'autoplay', 'background', 'bgcolor', 'border', 'capture', 'cellpadding', 'cellspacing', 'checked', 'cite', 'class', 'clear', 'color', 'cols', 'colspan', 'controls', 'controlslist', 'coords', 'crossorigin', 'datetime', 'decoding', 'default', 'dir', 'disabled', 'disablepictureinpicture', 'disableremoteplayback', 'download', 'draggable', 'enctype', 'enterkeyhint', 'face', 'for', 'headers', 'height', 'hidden', 'high', 'href', 'hreflang', 'id', 'inputmode', 'integrity', 'ismap', 'kind', 'label', 'lang', 'list', 'loading', 'loop', 'low', 'max', 'maxlength', 'media', 'method', 'min', 'minlength', 'multiple', 'muted', 'name', 'noshade', 'novalidate', 'nowrap', 'open', 'optimum', 'pattern', 'placeholder', 'playsinline', 'poster', 'preload', 'pubdate', 'radiogroup', 'readonly', 'rel', 'required', 'rev', 'reversed', 'role', 'rows', 'rowspan', 'spellcheck', 'scope', 'selected', 'shape', 'size', 'sizes', 'span', 'srclang', 'start', 'src', 'srcset', 'step', 'style', 'summary', 'tabindex', 'title', 'translate', 'type', 'usemap', 'valign', 'value', 'width', 'xmlns', 'slot']);
|
180 |
+
|
181 |
+
var svg$1 = freeze(['accent-height', 'accumulate', 'additive', 'alignment-baseline', 'ascent', 'attributename', 'attributetype', 'azimuth', 'basefrequency', 'baseline-shift', 'begin', 'bias', 'by', 'class', 'clip', 'clippathunits', 'clip-path', 'clip-rule', 'color', 'color-interpolation', 'color-interpolation-filters', 'color-profile', 'color-rendering', 'cx', 'cy', 'd', 'dx', 'dy', 'diffuseconstant', 'direction', 'display', 'divisor', 'dur', 'edgemode', 'elevation', 'end', 'fill', 'fill-opacity', 'fill-rule', 'filter', 'filterunits', 'flood-color', 'flood-opacity', 'font-family', 'font-size', 'font-size-adjust', 'font-stretch', 'font-style', 'font-variant', 'font-weight', 'fx', 'fy', 'g1', 'g2', 'glyph-name', 'glyphref', 'gradientunits', 'gradienttransform', 'height', 'href', 'id', 'image-rendering', 'in', 'in2', 'k', 'k1', 'k2', 'k3', 'k4', 'kerning', 'keypoints', 'keysplines', 'keytimes', 'lang', 'lengthadjust', 'letter-spacing', 'kernelmatrix', 'kernelunitlength', 'lighting-color', 'local', 'marker-end', 'marker-mid', 'marker-start', 'markerheight', 'markerunits', 'markerwidth', 'maskcontentunits', 'maskunits', 'max', 'mask', 'media', 'method', 'mode', 'min', 'name', 'numoctaves', 'offset', 'operator', 'opacity', 'order', 'orient', 'orientation', 'origin', 'overflow', 'paint-order', 'path', 'pathlength', 'patterncontentunits', 'patterntransform', 'patternunits', 'points', 'preservealpha', 'preserveaspectratio', 'primitiveunits', 'r', 'rx', 'ry', 'radius', 'refx', 'refy', 'repeatcount', 'repeatdur', 'restart', 'result', 'rotate', 'scale', 'seed', 'shape-rendering', 'specularconstant', 'specularexponent', 'spreadmethod', 'startoffset', 'stddeviation', 'stitchtiles', 'stop-color', 'stop-opacity', 'stroke-dasharray', 'stroke-dashoffset', 'stroke-linecap', 'stroke-linejoin', 'stroke-miterlimit', 'stroke-opacity', 'stroke', 'stroke-width', 'style', 'surfacescale', 'systemlanguage', 'tabindex', 'targetx', 'targety', 'transform', 'text-anchor', 'text-decoration', 'text-rendering', 'textlength', 'type', 'u1', 'u2', 'unicode', 'values', 'viewbox', 'visibility', 'version', 'vert-adv-y', 'vert-origin-x', 'vert-origin-y', 'width', 'word-spacing', 'wrap', 'writing-mode', 'xchannelselector', 'ychannelselector', 'x', 'x1', 'x2', 'xmlns', 'y', 'y1', 'y2', 'z', 'zoomandpan']);
|
182 |
+
|
183 |
+
var mathMl$1 = freeze(['accent', 'accentunder', 'align', 'bevelled', 'close', 'columnsalign', 'columnlines', 'columnspan', 'denomalign', 'depth', 'dir', 'display', 'displaystyle', 'encoding', 'fence', 'frame', 'height', 'href', 'id', 'largeop', 'length', 'linethickness', 'lspace', 'lquote', 'mathbackground', 'mathcolor', 'mathsize', 'mathvariant', 'maxsize', 'minsize', 'movablelimits', 'notation', 'numalign', 'open', 'rowalign', 'rowlines', 'rowspacing', 'rowspan', 'rspace', 'rquote', 'scriptlevel', 'scriptminsize', 'scriptsizemultiplier', 'selection', 'separator', 'separators', 'stretchy', 'subscriptshift', 'supscriptshift', 'symmetric', 'voffset', 'width', 'xmlns']);
|
184 |
+
|
185 |
+
var xml = freeze(['xlink:href', 'xml:id', 'xlink:title', 'xml:space', 'xmlns:xlink']);
|
186 |
+
|
187 |
+
// eslint-disable-next-line unicorn/better-regex
|
188 |
+
var MUSTACHE_EXPR = seal(/\{\{[\s\S]*|[\s\S]*\}\}/gm); // Specify template detection regex for SAFE_FOR_TEMPLATES mode
|
189 |
+
var ERB_EXPR = seal(/<%[\s\S]*|[\s\S]*%>/gm);
|
190 |
+
var DATA_ATTR = seal(/^data-[\-\w.\u00B7-\uFFFF]/); // eslint-disable-line no-useless-escape
|
191 |
+
var ARIA_ATTR = seal(/^aria-[\-\w]+$/); // eslint-disable-line no-useless-escape
|
192 |
+
var IS_ALLOWED_URI = seal(/^(?:(?:(?:f|ht)tps?|mailto|tel|callto|cid|xmpp):|[^a-z]|[a-z+.\-]+(?:[^a-z+.\-:]|$))/i // eslint-disable-line no-useless-escape
|
193 |
+
);
|
194 |
+
var IS_SCRIPT_OR_DATA = seal(/^(?:\w+script|data):/i);
|
195 |
+
var ATTR_WHITESPACE = seal(/[\u0000-\u0020\u00A0\u1680\u180E\u2000-\u2029\u205F\u3000]/g // eslint-disable-line no-control-regex
|
196 |
+
);
|
197 |
+
|
198 |
+
var _typeof = typeof Symbol === "function" && typeof Symbol.iterator === "symbol" ? function (obj) { return typeof obj; } : function (obj) { return obj && typeof Symbol === "function" && obj.constructor === Symbol && obj !== Symbol.prototype ? "symbol" : typeof obj; };
|
199 |
+
|
200 |
+
function _toConsumableArray$1(arr) { if (Array.isArray(arr)) { for (var i = 0, arr2 = Array(arr.length); i < arr.length; i++) { arr2[i] = arr[i]; } return arr2; } else { return Array.from(arr); } }
|
201 |
+
|
202 |
+
var getGlobal = function getGlobal() {
|
203 |
+
return typeof window === 'undefined' ? null : window;
|
204 |
+
};
|
205 |
+
|
206 |
+
/**
|
207 |
+
* Creates a no-op policy for internal use only.
|
208 |
+
* Don't export this function outside this module!
|
209 |
+
* @param {?TrustedTypePolicyFactory} trustedTypes The policy factory.
|
210 |
+
* @param {Document} document The document object (to determine policy name suffix)
|
211 |
+
* @return {?TrustedTypePolicy} The policy created (or null, if Trusted Types
|
212 |
+
* are not supported).
|
213 |
+
*/
|
214 |
+
var _createTrustedTypesPolicy = function _createTrustedTypesPolicy(trustedTypes, document) {
|
215 |
+
if ((typeof trustedTypes === 'undefined' ? 'undefined' : _typeof(trustedTypes)) !== 'object' || typeof trustedTypes.createPolicy !== 'function') {
|
216 |
+
return null;
|
217 |
+
}
|
218 |
+
|
219 |
+
// Allow the callers to control the unique policy name
|
220 |
+
// by adding a data-tt-policy-suffix to the script element with the DOMPurify.
|
221 |
+
// Policy creation with duplicate names throws in Trusted Types.
|
222 |
+
var suffix = null;
|
223 |
+
var ATTR_NAME = 'data-tt-policy-suffix';
|
224 |
+
if (document.currentScript && document.currentScript.hasAttribute(ATTR_NAME)) {
|
225 |
+
suffix = document.currentScript.getAttribute(ATTR_NAME);
|
226 |
+
}
|
227 |
+
|
228 |
+
var policyName = 'dompurify' + (suffix ? '#' + suffix : '');
|
229 |
+
|
230 |
+
try {
|
231 |
+
return trustedTypes.createPolicy(policyName, {
|
232 |
+
createHTML: function createHTML(html$$1) {
|
233 |
+
return html$$1;
|
234 |
+
}
|
235 |
+
});
|
236 |
+
} catch (_) {
|
237 |
+
// Policy creation failed (most likely another DOMPurify script has
|
238 |
+
// already run). Skip creating the policy, as this will only cause errors
|
239 |
+
// if TT are enforced.
|
240 |
+
console.warn('TrustedTypes policy ' + policyName + ' could not be created.');
|
241 |
+
return null;
|
242 |
+
}
|
243 |
+
};
|
244 |
+
|
245 |
+
function createDOMPurify() {
|
246 |
+
var window = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : getGlobal();
|
247 |
+
|
248 |
+
var DOMPurify = function DOMPurify(root) {
|
249 |
+
return createDOMPurify(root);
|
250 |
+
};
|
251 |
+
|
252 |
+
/**
|
253 |
+
* Version label, exposed for easier checks
|
254 |
+
* if DOMPurify is up to date or not
|
255 |
+
*/
|
256 |
+
DOMPurify.version = '2.2.9';
|
257 |
+
|
258 |
+
/**
|
259 |
+
* Array of elements that DOMPurify removed during sanitation.
|
260 |
+
* Empty if nothing was removed.
|
261 |
+
*/
|
262 |
+
DOMPurify.removed = [];
|
263 |
+
|
264 |
+
if (!window || !window.document || window.document.nodeType !== 9) {
|
265 |
+
// Not running in a browser, provide a factory function
|
266 |
+
// so that you can pass your own Window
|
267 |
+
DOMPurify.isSupported = false;
|
268 |
+
|
269 |
+
return DOMPurify;
|
270 |
+
}
|
271 |
+
|
272 |
+
var originalDocument = window.document;
|
273 |
+
|
274 |
+
var document = window.document;
|
275 |
+
var DocumentFragment = window.DocumentFragment,
|
276 |
+
HTMLTemplateElement = window.HTMLTemplateElement,
|
277 |
+
Node = window.Node,
|
278 |
+
Element = window.Element,
|
279 |
+
NodeFilter = window.NodeFilter,
|
280 |
+
_window$NamedNodeMap = window.NamedNodeMap,
|
281 |
+
NamedNodeMap = _window$NamedNodeMap === undefined ? window.NamedNodeMap || window.MozNamedAttrMap : _window$NamedNodeMap,
|
282 |
+
Text = window.Text,
|
283 |
+
Comment = window.Comment,
|
284 |
+
DOMParser = window.DOMParser,
|
285 |
+
trustedTypes = window.trustedTypes;
|
286 |
+
|
287 |
+
|
288 |
+
var ElementPrototype = Element.prototype;
|
289 |
+
|
290 |
+
var cloneNode = lookupGetter(ElementPrototype, 'cloneNode');
|
291 |
+
var getNextSibling = lookupGetter(ElementPrototype, 'nextSibling');
|
292 |
+
var getChildNodes = lookupGetter(ElementPrototype, 'childNodes');
|
293 |
+
var getParentNode = lookupGetter(ElementPrototype, 'parentNode');
|
294 |
+
|
295 |
+
// As per issue #47, the web-components registry is inherited by a
|
296 |
+
// new document created via createHTMLDocument. As per the spec
|
297 |
+
// (http://w3c.github.io/webcomponents/spec/custom/#creating-and-passing-registries)
|
298 |
+
// a new empty registry is used when creating a template contents owner
|
299 |
+
// document, so we use that as our parent document to ensure nothing
|
300 |
+
// is inherited.
|
301 |
+
if (typeof HTMLTemplateElement === 'function') {
|
302 |
+
var template = document.createElement('template');
|
303 |
+
if (template.content && template.content.ownerDocument) {
|
304 |
+
document = template.content.ownerDocument;
|
305 |
+
}
|
306 |
+
}
|
307 |
+
|
308 |
+
var trustedTypesPolicy = _createTrustedTypesPolicy(trustedTypes, originalDocument);
|
309 |
+
var emptyHTML = trustedTypesPolicy && RETURN_TRUSTED_TYPE ? trustedTypesPolicy.createHTML('') : '';
|
310 |
+
|
311 |
+
var _document = document,
|
312 |
+
implementation = _document.implementation,
|
313 |
+
createNodeIterator = _document.createNodeIterator,
|
314 |
+
createDocumentFragment = _document.createDocumentFragment;
|
315 |
+
var importNode = originalDocument.importNode;
|
316 |
+
|
317 |
+
|
318 |
+
var documentMode = {};
|
319 |
+
try {
|
320 |
+
documentMode = clone(document).documentMode ? document.documentMode : {};
|
321 |
+
} catch (_) {}
|
322 |
+
|
323 |
+
var hooks = {};
|
324 |
+
|
325 |
+
/**
|
326 |
+
* Expose whether this browser supports running the full DOMPurify.
|
327 |
+
*/
|
328 |
+
DOMPurify.isSupported = typeof getParentNode === 'function' && implementation && typeof implementation.createHTMLDocument !== 'undefined' && documentMode !== 9;
|
329 |
+
|
330 |
+
var MUSTACHE_EXPR$$1 = MUSTACHE_EXPR,
|
331 |
+
ERB_EXPR$$1 = ERB_EXPR,
|
332 |
+
DATA_ATTR$$1 = DATA_ATTR,
|
333 |
+
ARIA_ATTR$$1 = ARIA_ATTR,
|
334 |
+
IS_SCRIPT_OR_DATA$$1 = IS_SCRIPT_OR_DATA,
|
335 |
+
ATTR_WHITESPACE$$1 = ATTR_WHITESPACE;
|
336 |
+
var IS_ALLOWED_URI$$1 = IS_ALLOWED_URI;
|
337 |
+
|
338 |
+
/**
|
339 |
+
* We consider the elements and attributes below to be safe. Ideally
|
340 |
+
* don't add any new ones but feel free to remove unwanted ones.
|
341 |
+
*/
|
342 |
+
|
343 |
+
/* allowed element names */
|
344 |
+
|
345 |
+
var ALLOWED_TAGS = null;
|
346 |
+
var DEFAULT_ALLOWED_TAGS = addToSet({}, [].concat(_toConsumableArray$1(html), _toConsumableArray$1(svg), _toConsumableArray$1(svgFilters), _toConsumableArray$1(mathMl), _toConsumableArray$1(text)));
|
347 |
+
|
348 |
+
/* Allowed attribute names */
|
349 |
+
var ALLOWED_ATTR = null;
|
350 |
+
var DEFAULT_ALLOWED_ATTR = addToSet({}, [].concat(_toConsumableArray$1(html$1), _toConsumableArray$1(svg$1), _toConsumableArray$1(mathMl$1), _toConsumableArray$1(xml)));
|
351 |
+
|
352 |
+
/* Explicitly forbidden tags (overrides ALLOWED_TAGS/ADD_TAGS) */
|
353 |
+
var FORBID_TAGS = null;
|
354 |
+
|
355 |
+
/* Explicitly forbidden attributes (overrides ALLOWED_ATTR/ADD_ATTR) */
|
356 |
+
var FORBID_ATTR = null;
|
357 |
+
|
358 |
+
/* Decide if ARIA attributes are okay */
|
359 |
+
var ALLOW_ARIA_ATTR = true;
|
360 |
+
|
361 |
+
/* Decide if custom data attributes are okay */
|
362 |
+
var ALLOW_DATA_ATTR = true;
|
363 |
+
|
364 |
+
/* Decide if unknown protocols are okay */
|
365 |
+
var ALLOW_UNKNOWN_PROTOCOLS = false;
|
366 |
+
|
367 |
+
/* Output should be safe for common template engines.
|
368 |
+
* This means, DOMPurify removes data attributes, mustaches and ERB
|
369 |
+
*/
|
370 |
+
var SAFE_FOR_TEMPLATES = false;
|
371 |
+
|
372 |
+
/* Decide if document with <html>... should be returned */
|
373 |
+
var WHOLE_DOCUMENT = false;
|
374 |
+
|
375 |
+
/* Track whether config is already set on this instance of DOMPurify. */
|
376 |
+
var SET_CONFIG = false;
|
377 |
+
|
378 |
+
/* Decide if all elements (e.g. style, script) must be children of
|
379 |
+
* document.body. By default, browsers might move them to document.head */
|
380 |
+
var FORCE_BODY = false;
|
381 |
+
|
382 |
+
/* Decide if a DOM `HTMLBodyElement` should be returned, instead of a html
|
383 |
+
* string (or a TrustedHTML object if Trusted Types are supported).
|
384 |
+
* If `WHOLE_DOCUMENT` is enabled a `HTMLHtmlElement` will be returned instead
|
385 |
+
*/
|
386 |
+
var RETURN_DOM = false;
|
387 |
+
|
388 |
+
/* Decide if a DOM `DocumentFragment` should be returned, instead of a html
|
389 |
+
* string (or a TrustedHTML object if Trusted Types are supported) */
|
390 |
+
var RETURN_DOM_FRAGMENT = false;
|
391 |
+
|
392 |
+
/* If `RETURN_DOM` or `RETURN_DOM_FRAGMENT` is enabled, decide if the returned DOM
|
393 |
+
* `Node` is imported into the current `Document`. If this flag is not enabled the
|
394 |
+
* `Node` will belong (its ownerDocument) to a fresh `HTMLDocument`, created by
|
395 |
+
* DOMPurify.
|
396 |
+
*
|
397 |
+
* This defaults to `true` starting DOMPurify 2.2.0. Note that setting it to `false`
|
398 |
+
* might cause XSS from attacks hidden in closed shadowroots in case the browser
|
399 |
+
* supports Declarative Shadow: DOM https://web.dev/declarative-shadow-dom/
|
400 |
+
*/
|
401 |
+
var RETURN_DOM_IMPORT = true;
|
402 |
+
|
403 |
+
/* Try to return a Trusted Type object instead of a string, return a string in
|
404 |
+
* case Trusted Types are not supported */
|
405 |
+
var RETURN_TRUSTED_TYPE = false;
|
406 |
+
|
407 |
+
/* Output should be free from DOM clobbering attacks? */
|
408 |
+
var SANITIZE_DOM = true;
|
409 |
+
|
410 |
+
/* Keep element content when removing element? */
|
411 |
+
var KEEP_CONTENT = true;
|
412 |
+
|
413 |
+
/* If a `Node` is passed to sanitize(), then performs sanitization in-place instead
|
414 |
+
* of importing it into a new Document and returning a sanitized copy */
|
415 |
+
var IN_PLACE = false;
|
416 |
+
|
417 |
+
/* Allow usage of profiles like html, svg and mathMl */
|
418 |
+
var USE_PROFILES = {};
|
419 |
+
|
420 |
+
/* Tags to ignore content of when KEEP_CONTENT is true */
|
421 |
+
var FORBID_CONTENTS = addToSet({}, ['annotation-xml', 'audio', 'colgroup', 'desc', 'foreignobject', 'head', 'iframe', 'math', 'mi', 'mn', 'mo', 'ms', 'mtext', 'noembed', 'noframes', 'noscript', 'plaintext', 'script', 'style', 'svg', 'template', 'thead', 'title', 'video', 'xmp']);
|
422 |
+
|
423 |
+
/* Tags that are safe for data: URIs */
|
424 |
+
var DATA_URI_TAGS = null;
|
425 |
+
var DEFAULT_DATA_URI_TAGS = addToSet({}, ['audio', 'video', 'img', 'source', 'image', 'track']);
|
426 |
+
|
427 |
+
/* Attributes safe for values like "javascript:" */
|
428 |
+
var URI_SAFE_ATTRIBUTES = null;
|
429 |
+
var DEFAULT_URI_SAFE_ATTRIBUTES = addToSet({}, ['alt', 'class', 'for', 'id', 'label', 'name', 'pattern', 'placeholder', 'summary', 'title', 'value', 'style', 'xmlns']);
|
430 |
+
|
431 |
+
var MATHML_NAMESPACE = 'http://www.w3.org/1998/Math/MathML';
|
432 |
+
var SVG_NAMESPACE = 'http://www.w3.org/2000/svg';
|
433 |
+
var HTML_NAMESPACE = 'http://www.w3.org/1999/xhtml';
|
434 |
+
/* Document namespace */
|
435 |
+
var NAMESPACE = HTML_NAMESPACE;
|
436 |
+
var IS_EMPTY_INPUT = false;
|
437 |
+
|
438 |
+
/* Keep a reference to config to pass to hooks */
|
439 |
+
var CONFIG = null;
|
440 |
+
|
441 |
+
/* Ideally, do not touch anything below this line */
|
442 |
+
/* ______________________________________________ */
|
443 |
+
|
444 |
+
var formElement = document.createElement('form');
|
445 |
+
|
446 |
+
/**
|
447 |
+
* _parseConfig
|
448 |
+
*
|
449 |
+
* @param {Object} cfg optional config literal
|
450 |
+
*/
|
451 |
+
// eslint-disable-next-line complexity
|
452 |
+
var _parseConfig = function _parseConfig(cfg) {
|
453 |
+
if (CONFIG && CONFIG === cfg) {
|
454 |
+
return;
|
455 |
+
}
|
456 |
+
|
457 |
+
/* Shield configuration object from tampering */
|
458 |
+
if (!cfg || (typeof cfg === 'undefined' ? 'undefined' : _typeof(cfg)) !== 'object') {
|
459 |
+
cfg = {};
|
460 |
+
}
|
461 |
+
|
462 |
+
/* Shield configuration object from prototype pollution */
|
463 |
+
cfg = clone(cfg);
|
464 |
+
|
465 |
+
/* Set configuration parameters */
|
466 |
+
ALLOWED_TAGS = 'ALLOWED_TAGS' in cfg ? addToSet({}, cfg.ALLOWED_TAGS) : DEFAULT_ALLOWED_TAGS;
|
467 |
+
ALLOWED_ATTR = 'ALLOWED_ATTR' in cfg ? addToSet({}, cfg.ALLOWED_ATTR) : DEFAULT_ALLOWED_ATTR;
|
468 |
+
URI_SAFE_ATTRIBUTES = 'ADD_URI_SAFE_ATTR' in cfg ? addToSet(clone(DEFAULT_URI_SAFE_ATTRIBUTES), cfg.ADD_URI_SAFE_ATTR) : DEFAULT_URI_SAFE_ATTRIBUTES;
|
469 |
+
DATA_URI_TAGS = 'ADD_DATA_URI_TAGS' in cfg ? addToSet(clone(DEFAULT_DATA_URI_TAGS), cfg.ADD_DATA_URI_TAGS) : DEFAULT_DATA_URI_TAGS;
|
470 |
+
FORBID_TAGS = 'FORBID_TAGS' in cfg ? addToSet({}, cfg.FORBID_TAGS) : {};
|
471 |
+
FORBID_ATTR = 'FORBID_ATTR' in cfg ? addToSet({}, cfg.FORBID_ATTR) : {};
|
472 |
+
USE_PROFILES = 'USE_PROFILES' in cfg ? cfg.USE_PROFILES : false;
|
473 |
+
ALLOW_ARIA_ATTR = cfg.ALLOW_ARIA_ATTR !== false; // Default true
|
474 |
+
ALLOW_DATA_ATTR = cfg.ALLOW_DATA_ATTR !== false; // Default true
|
475 |
+
ALLOW_UNKNOWN_PROTOCOLS = cfg.ALLOW_UNKNOWN_PROTOCOLS || false; // Default false
|
476 |
+
SAFE_FOR_TEMPLATES = cfg.SAFE_FOR_TEMPLATES || false; // Default false
|
477 |
+
WHOLE_DOCUMENT = cfg.WHOLE_DOCUMENT || false; // Default false
|
478 |
+
RETURN_DOM = cfg.RETURN_DOM || false; // Default false
|
479 |
+
RETURN_DOM_FRAGMENT = cfg.RETURN_DOM_FRAGMENT || false; // Default false
|
480 |
+
RETURN_DOM_IMPORT = cfg.RETURN_DOM_IMPORT !== false; // Default true
|
481 |
+
RETURN_TRUSTED_TYPE = cfg.RETURN_TRUSTED_TYPE || false; // Default false
|
482 |
+
FORCE_BODY = cfg.FORCE_BODY || false; // Default false
|
483 |
+
SANITIZE_DOM = cfg.SANITIZE_DOM !== false; // Default true
|
484 |
+
KEEP_CONTENT = cfg.KEEP_CONTENT !== false; // Default true
|
485 |
+
IN_PLACE = cfg.IN_PLACE || false; // Default false
|
486 |
+
IS_ALLOWED_URI$$1 = cfg.ALLOWED_URI_REGEXP || IS_ALLOWED_URI$$1;
|
487 |
+
NAMESPACE = cfg.NAMESPACE || HTML_NAMESPACE;
|
488 |
+
if (SAFE_FOR_TEMPLATES) {
|
489 |
+
ALLOW_DATA_ATTR = false;
|
490 |
+
}
|
491 |
+
|
492 |
+
if (RETURN_DOM_FRAGMENT) {
|
493 |
+
RETURN_DOM = true;
|
494 |
+
}
|
495 |
+
|
496 |
+
/* Parse profile info */
|
497 |
+
if (USE_PROFILES) {
|
498 |
+
ALLOWED_TAGS = addToSet({}, [].concat(_toConsumableArray$1(text)));
|
499 |
+
ALLOWED_ATTR = [];
|
500 |
+
if (USE_PROFILES.html === true) {
|
501 |
+
addToSet(ALLOWED_TAGS, html);
|
502 |
+
addToSet(ALLOWED_ATTR, html$1);
|
503 |
+
}
|
504 |
+
|
505 |
+
if (USE_PROFILES.svg === true) {
|
506 |
+
addToSet(ALLOWED_TAGS, svg);
|
507 |
+
addToSet(ALLOWED_ATTR, svg$1);
|
508 |
+
addToSet(ALLOWED_ATTR, xml);
|
509 |
+
}
|
510 |
+
|
511 |
+
if (USE_PROFILES.svgFilters === true) {
|
512 |
+
addToSet(ALLOWED_TAGS, svgFilters);
|
513 |
+
addToSet(ALLOWED_ATTR, svg$1);
|
514 |
+
addToSet(ALLOWED_ATTR, xml);
|
515 |
+
}
|
516 |
+
|
517 |
+
if (USE_PROFILES.mathMl === true) {
|
518 |
+
addToSet(ALLOWED_TAGS, mathMl);
|
519 |
+
addToSet(ALLOWED_ATTR, mathMl$1);
|
520 |
+
addToSet(ALLOWED_ATTR, xml);
|
521 |
+
}
|
522 |
+
}
|
523 |
+
|
524 |
+
/* Merge configuration parameters */
|
525 |
+
if (cfg.ADD_TAGS) {
|
526 |
+
if (ALLOWED_TAGS === DEFAULT_ALLOWED_TAGS) {
|
527 |
+
ALLOWED_TAGS = clone(ALLOWED_TAGS);
|
528 |
+
}
|
529 |
+
|
530 |
+
addToSet(ALLOWED_TAGS, cfg.ADD_TAGS);
|
531 |
+
}
|
532 |
+
|
533 |
+
if (cfg.ADD_ATTR) {
|
534 |
+
if (ALLOWED_ATTR === DEFAULT_ALLOWED_ATTR) {
|
535 |
+
ALLOWED_ATTR = clone(ALLOWED_ATTR);
|
536 |
+
}
|
537 |
+
|
538 |
+
addToSet(ALLOWED_ATTR, cfg.ADD_ATTR);
|
539 |
+
}
|
540 |
+
|
541 |
+
if (cfg.ADD_URI_SAFE_ATTR) {
|
542 |
+
addToSet(URI_SAFE_ATTRIBUTES, cfg.ADD_URI_SAFE_ATTR);
|
543 |
+
}
|
544 |
+
|
545 |
+
/* Add #text in case KEEP_CONTENT is set to true */
|
546 |
+
if (KEEP_CONTENT) {
|
547 |
+
ALLOWED_TAGS['#text'] = true;
|
548 |
+
}
|
549 |
+
|
550 |
+
/* Add html, head and body to ALLOWED_TAGS in case WHOLE_DOCUMENT is true */
|
551 |
+
if (WHOLE_DOCUMENT) {
|
552 |
+
addToSet(ALLOWED_TAGS, ['html', 'head', 'body']);
|
553 |
+
}
|
554 |
+
|
555 |
+
/* Add tbody to ALLOWED_TAGS in case tables are permitted, see #286, #365 */
|
556 |
+
if (ALLOWED_TAGS.table) {
|
557 |
+
addToSet(ALLOWED_TAGS, ['tbody']);
|
558 |
+
delete FORBID_TAGS.tbody;
|
559 |
+
}
|
560 |
+
|
561 |
+
// Prevent further manipulation of configuration.
|
562 |
+
// Not available in IE8, Safari 5, etc.
|
563 |
+
if (freeze) {
|
564 |
+
freeze(cfg);
|
565 |
+
}
|
566 |
+
|
567 |
+
CONFIG = cfg;
|
568 |
+
};
|
569 |
+
|
570 |
+
var MATHML_TEXT_INTEGRATION_POINTS = addToSet({}, ['mi', 'mo', 'mn', 'ms', 'mtext']);
|
571 |
+
|
572 |
+
var HTML_INTEGRATION_POINTS = addToSet({}, ['foreignobject', 'desc', 'title', 'annotation-xml']);
|
573 |
+
|
574 |
+
/* Keep track of all possible SVG and MathML tags
|
575 |
+
* so that we can perform the namespace checks
|
576 |
+
* correctly. */
|
577 |
+
var ALL_SVG_TAGS = addToSet({}, svg);
|
578 |
+
addToSet(ALL_SVG_TAGS, svgFilters);
|
579 |
+
addToSet(ALL_SVG_TAGS, svgDisallowed);
|
580 |
+
|
581 |
+
var ALL_MATHML_TAGS = addToSet({}, mathMl);
|
582 |
+
addToSet(ALL_MATHML_TAGS, mathMlDisallowed);
|
583 |
+
|
584 |
+
/**
|
585 |
+
*
|
586 |
+
*
|
587 |
+
* @param {Element} element a DOM element whose namespace is being checked
|
588 |
+
* @returns {boolean} Return false if the element has a
|
589 |
+
* namespace that a spec-compliant parser would never
|
590 |
+
* return. Return true otherwise.
|
591 |
+
*/
|
592 |
+
var _checkValidNamespace = function _checkValidNamespace(element) {
|
593 |
+
var parent = getParentNode(element);
|
594 |
+
|
595 |
+
// In JSDOM, if we're inside shadow DOM, then parentNode
|
596 |
+
// can be null. We just simulate parent in this case.
|
597 |
+
if (!parent || !parent.tagName) {
|
598 |
+
parent = {
|
599 |
+
namespaceURI: HTML_NAMESPACE,
|
600 |
+
tagName: 'template'
|
601 |
+
};
|
602 |
+
}
|
603 |
+
|
604 |
+
var tagName = stringToLowerCase(element.tagName);
|
605 |
+
var parentTagName = stringToLowerCase(parent.tagName);
|
606 |
+
|
607 |
+
if (element.namespaceURI === SVG_NAMESPACE) {
|
608 |
+
// The only way to switch from HTML namespace to SVG
|
609 |
+
// is via <svg>. If it happens via any other tag, then
|
610 |
+
// it should be killed.
|
611 |
+
if (parent.namespaceURI === HTML_NAMESPACE) {
|
612 |
+
return tagName === 'svg';
|
613 |
+
}
|
614 |
+
|
615 |
+
// The only way to switch from MathML to SVG is via
|
616 |
+
// svg if parent is either <annotation-xml> or MathML
|
617 |
+
// text integration points.
|
618 |
+
if (parent.namespaceURI === MATHML_NAMESPACE) {
|
619 |
+
return tagName === 'svg' && (parentTagName === 'annotation-xml' || MATHML_TEXT_INTEGRATION_POINTS[parentTagName]);
|
620 |
+
}
|
621 |
+
|
622 |
+
// We only allow elements that are defined in SVG
|
623 |
+
// spec. All others are disallowed in SVG namespace.
|
624 |
+
return Boolean(ALL_SVG_TAGS[tagName]);
|
625 |
+
}
|
626 |
+
|
627 |
+
if (element.namespaceURI === MATHML_NAMESPACE) {
|
628 |
+
// The only way to switch from HTML namespace to MathML
|
629 |
+
// is via <math>. If it happens via any other tag, then
|
630 |
+
// it should be killed.
|
631 |
+
if (parent.namespaceURI === HTML_NAMESPACE) {
|
632 |
+
return tagName === 'math';
|
633 |
+
}
|
634 |
+
|
635 |
+
// The only way to switch from SVG to MathML is via
|
636 |
+
// <math> and HTML integration points
|
637 |
+
if (parent.namespaceURI === SVG_NAMESPACE) {
|
638 |
+
return tagName === 'math' && HTML_INTEGRATION_POINTS[parentTagName];
|
639 |
+
}
|
640 |
+
|
641 |
+
// We only allow elements that are defined in MathML
|
642 |
+
// spec. All others are disallowed in MathML namespace.
|
643 |
+
return Boolean(ALL_MATHML_TAGS[tagName]);
|
644 |
+
}
|
645 |
+
|
646 |
+
if (element.namespaceURI === HTML_NAMESPACE) {
|
647 |
+
// The only way to switch from SVG to HTML is via
|
648 |
+
// HTML integration points, and from MathML to HTML
|
649 |
+
// is via MathML text integration points
|
650 |
+
if (parent.namespaceURI === SVG_NAMESPACE && !HTML_INTEGRATION_POINTS[parentTagName]) {
|
651 |
+
return false;
|
652 |
+
}
|
653 |
+
|
654 |
+
if (parent.namespaceURI === MATHML_NAMESPACE && !MATHML_TEXT_INTEGRATION_POINTS[parentTagName]) {
|
655 |
+
return false;
|
656 |
+
}
|
657 |
+
|
658 |
+
// Certain elements are allowed in both SVG and HTML
|
659 |
+
// namespace. We need to specify them explicitly
|
660 |
+
// so that they don't get erronously deleted from
|
661 |
+
// HTML namespace.
|
662 |
+
var commonSvgAndHTMLElements = addToSet({}, ['title', 'style', 'font', 'a', 'script']);
|
663 |
+
|
664 |
+
// We disallow tags that are specific for MathML
|
665 |
+
// or SVG and should never appear in HTML namespace
|
666 |
+
return !ALL_MATHML_TAGS[tagName] && (commonSvgAndHTMLElements[tagName] || !ALL_SVG_TAGS[tagName]);
|
667 |
+
}
|
668 |
+
|
669 |
+
// The code should never reach this place (this means
|
670 |
+
// that the element somehow got namespace that is not
|
671 |
+
// HTML, SVG or MathML). Return false just in case.
|
672 |
+
return false;
|
673 |
+
};
|
674 |
+
|
675 |
+
/**
|
676 |
+
* _forceRemove
|
677 |
+
*
|
678 |
+
* @param {Node} node a DOM node
|
679 |
+
*/
|
680 |
+
var _forceRemove = function _forceRemove(node) {
|
681 |
+
arrayPush(DOMPurify.removed, { element: node });
|
682 |
+
try {
|
683 |
+
// eslint-disable-next-line unicorn/prefer-dom-node-remove
|
684 |
+
node.parentNode.removeChild(node);
|
685 |
+
} catch (_) {
|
686 |
+
try {
|
687 |
+
node.outerHTML = emptyHTML;
|
688 |
+
} catch (_) {
|
689 |
+
node.remove();
|
690 |
+
}
|
691 |
+
}
|
692 |
+
};
|
693 |
+
|
694 |
+
/**
|
695 |
+
* _removeAttribute
|
696 |
+
*
|
697 |
+
* @param {String} name an Attribute name
|
698 |
+
* @param {Node} node a DOM node
|
699 |
+
*/
|
700 |
+
var _removeAttribute = function _removeAttribute(name, node) {
|
701 |
+
try {
|
702 |
+
arrayPush(DOMPurify.removed, {
|
703 |
+
attribute: node.getAttributeNode(name),
|
704 |
+
from: node
|
705 |
+
});
|
706 |
+
} catch (_) {
|
707 |
+
arrayPush(DOMPurify.removed, {
|
708 |
+
attribute: null,
|
709 |
+
from: node
|
710 |
+
});
|
711 |
+
}
|
712 |
+
|
713 |
+
node.removeAttribute(name);
|
714 |
+
|
715 |
+
// We void attribute values for unremovable "is"" attributes
|
716 |
+
if (name === 'is' && !ALLOWED_ATTR[name]) {
|
717 |
+
if (RETURN_DOM || RETURN_DOM_FRAGMENT) {
|
718 |
+
try {
|
719 |
+
_forceRemove(node);
|
720 |
+
} catch (_) {}
|
721 |
+
} else {
|
722 |
+
try {
|
723 |
+
node.setAttribute(name, '');
|
724 |
+
} catch (_) {}
|
725 |
+
}
|
726 |
+
}
|
727 |
+
};
|
728 |
+
|
729 |
+
/**
|
730 |
+
* _initDocument
|
731 |
+
*
|
732 |
+
* @param {String} dirty a string of dirty markup
|
733 |
+
* @return {Document} a DOM, filled with the dirty markup
|
734 |
+
*/
|
735 |
+
var _initDocument = function _initDocument(dirty) {
|
736 |
+
/* Create a HTML document */
|
737 |
+
var doc = void 0;
|
738 |
+
var leadingWhitespace = void 0;
|
739 |
+
|
740 |
+
if (FORCE_BODY) {
|
741 |
+
dirty = '<remove></remove>' + dirty;
|
742 |
+
} else {
|
743 |
+
/* If FORCE_BODY isn't used, leading whitespace needs to be preserved manually */
|
744 |
+
var matches = stringMatch(dirty, /^[\r\n\t ]+/);
|
745 |
+
leadingWhitespace = matches && matches[0];
|
746 |
+
}
|
747 |
+
|
748 |
+
var dirtyPayload = trustedTypesPolicy ? trustedTypesPolicy.createHTML(dirty) : dirty;
|
749 |
+
/*
|
750 |
+
* Use the DOMParser API by default, fallback later if needs be
|
751 |
+
* DOMParser not work for svg when has multiple root element.
|
752 |
+
*/
|
753 |
+
if (NAMESPACE === HTML_NAMESPACE) {
|
754 |
+
try {
|
755 |
+
doc = new DOMParser().parseFromString(dirtyPayload, 'text/html');
|
756 |
+
} catch (_) {}
|
757 |
+
}
|
758 |
+
|
759 |
+
/* Use createHTMLDocument in case DOMParser is not available */
|
760 |
+
if (!doc || !doc.documentElement) {
|
761 |
+
doc = implementation.createDocument(NAMESPACE, 'template', null);
|
762 |
+
try {
|
763 |
+
doc.documentElement.innerHTML = IS_EMPTY_INPUT ? '' : dirtyPayload;
|
764 |
+
} catch (_) {
|
765 |
+
// Syntax error if dirtyPayload is invalid xml
|
766 |
+
}
|
767 |
+
}
|
768 |
+
|
769 |
+
var body = doc.body || doc.documentElement;
|
770 |
+
|
771 |
+
if (dirty && leadingWhitespace) {
|
772 |
+
body.insertBefore(document.createTextNode(leadingWhitespace), body.childNodes[0] || null);
|
773 |
+
}
|
774 |
+
|
775 |
+
/* Work on whole document or just its body */
|
776 |
+
return WHOLE_DOCUMENT ? doc.documentElement : body;
|
777 |
+
};
|
778 |
+
|
779 |
+
/**
|
780 |
+
* _createIterator
|
781 |
+
*
|
782 |
+
* @param {Document} root document/fragment to create iterator for
|
783 |
+
* @return {Iterator} iterator instance
|
784 |
+
*/
|
785 |
+
var _createIterator = function _createIterator(root) {
|
786 |
+
return createNodeIterator.call(root.ownerDocument || root, root, NodeFilter.SHOW_ELEMENT | NodeFilter.SHOW_COMMENT | NodeFilter.SHOW_TEXT, null, false);
|
787 |
+
};
|
788 |
+
|
789 |
+
/**
|
790 |
+
* _isClobbered
|
791 |
+
*
|
792 |
+
* @param {Node} elm element to check for clobbering attacks
|
793 |
+
* @return {Boolean} true if clobbered, false if safe
|
794 |
+
*/
|
795 |
+
var _isClobbered = function _isClobbered(elm) {
|
796 |
+
if (elm instanceof Text || elm instanceof Comment) {
|
797 |
+
return false;
|
798 |
+
}
|
799 |
+
|
800 |
+
if (typeof elm.nodeName !== 'string' || typeof elm.textContent !== 'string' || typeof elm.removeChild !== 'function' || !(elm.attributes instanceof NamedNodeMap) || typeof elm.removeAttribute !== 'function' || typeof elm.setAttribute !== 'function' || typeof elm.namespaceURI !== 'string' || typeof elm.insertBefore !== 'function') {
|
801 |
+
return true;
|
802 |
+
}
|
803 |
+
|
804 |
+
return false;
|
805 |
+
};
|
806 |
+
|
807 |
+
/**
|
808 |
+
* _isNode
|
809 |
+
*
|
810 |
+
* @param {Node} obj object to check whether it's a DOM node
|
811 |
+
* @return {Boolean} true is object is a DOM node
|
812 |
+
*/
|
813 |
+
var _isNode = function _isNode(object) {
|
814 |
+
return (typeof Node === 'undefined' ? 'undefined' : _typeof(Node)) === 'object' ? object instanceof Node : object && (typeof object === 'undefined' ? 'undefined' : _typeof(object)) === 'object' && typeof object.nodeType === 'number' && typeof object.nodeName === 'string';
|
815 |
+
};
|
816 |
+
|
817 |
+
/**
|
818 |
+
* _executeHook
|
819 |
+
* Execute user configurable hooks
|
820 |
+
*
|
821 |
+
* @param {String} entryPoint Name of the hook's entry point
|
822 |
+
* @param {Node} currentNode node to work on with the hook
|
823 |
+
* @param {Object} data additional hook parameters
|
824 |
+
*/
|
825 |
+
var _executeHook = function _executeHook(entryPoint, currentNode, data) {
|
826 |
+
if (!hooks[entryPoint]) {
|
827 |
+
return;
|
828 |
+
}
|
829 |
+
|
830 |
+
arrayForEach(hooks[entryPoint], function (hook) {
|
831 |
+
hook.call(DOMPurify, currentNode, data, CONFIG);
|
832 |
+
});
|
833 |
+
};
|
834 |
+
|
835 |
+
/**
|
836 |
+
* _sanitizeElements
|
837 |
+
*
|
838 |
+
* @protect nodeName
|
839 |
+
* @protect textContent
|
840 |
+
* @protect removeChild
|
841 |
+
*
|
842 |
+
* @param {Node} currentNode to check for permission to exist
|
843 |
+
* @return {Boolean} true if node was killed, false if left alive
|
844 |
+
*/
|
845 |
+
var _sanitizeElements = function _sanitizeElements(currentNode) {
|
846 |
+
var content = void 0;
|
847 |
+
|
848 |
+
/* Execute a hook if present */
|
849 |
+
_executeHook('beforeSanitizeElements', currentNode, null);
|
850 |
+
|
851 |
+
/* Check if element is clobbered or can clobber */
|
852 |
+
if (_isClobbered(currentNode)) {
|
853 |
+
_forceRemove(currentNode);
|
854 |
+
return true;
|
855 |
+
}
|
856 |
+
|
857 |
+
/* Check if tagname contains Unicode */
|
858 |
+
if (stringMatch(currentNode.nodeName, /[\u0080-\uFFFF]/)) {
|
859 |
+
_forceRemove(currentNode);
|
860 |
+
return true;
|
861 |
+
}
|
862 |
+
|
863 |
+
/* Now let's check the element's type and name */
|
864 |
+
var tagName = stringToLowerCase(currentNode.nodeName);
|
865 |
+
|
866 |
+
/* Execute a hook if present */
|
867 |
+
_executeHook('uponSanitizeElement', currentNode, {
|
868 |
+
tagName: tagName,
|
869 |
+
allowedTags: ALLOWED_TAGS
|
870 |
+
});
|
871 |
+
|
872 |
+
/* Detect mXSS attempts abusing namespace confusion */
|
873 |
+
if (!_isNode(currentNode.firstElementChild) && (!_isNode(currentNode.content) || !_isNode(currentNode.content.firstElementChild)) && regExpTest(/<[/\w]/g, currentNode.innerHTML) && regExpTest(/<[/\w]/g, currentNode.textContent)) {
|
874 |
+
_forceRemove(currentNode);
|
875 |
+
return true;
|
876 |
+
}
|
877 |
+
|
878 |
+
/* Remove element if anything forbids its presence */
|
879 |
+
if (!ALLOWED_TAGS[tagName] || FORBID_TAGS[tagName]) {
|
880 |
+
/* Keep content except for bad-listed elements */
|
881 |
+
if (KEEP_CONTENT && !FORBID_CONTENTS[tagName]) {
|
882 |
+
var parentNode = getParentNode(currentNode) || currentNode.parentNode;
|
883 |
+
var childNodes = getChildNodes(currentNode) || currentNode.childNodes;
|
884 |
+
|
885 |
+
if (childNodes && parentNode) {
|
886 |
+
var childCount = childNodes.length;
|
887 |
+
|
888 |
+
for (var i = childCount - 1; i >= 0; --i) {
|
889 |
+
parentNode.insertBefore(cloneNode(childNodes[i], true), getNextSibling(currentNode));
|
890 |
+
}
|
891 |
+
}
|
892 |
+
}
|
893 |
+
|
894 |
+
_forceRemove(currentNode);
|
895 |
+
return true;
|
896 |
+
}
|
897 |
+
|
898 |
+
/* Check whether element has a valid namespace */
|
899 |
+
if (currentNode instanceof Element && !_checkValidNamespace(currentNode)) {
|
900 |
+
_forceRemove(currentNode);
|
901 |
+
return true;
|
902 |
+
}
|
903 |
+
|
904 |
+
if ((tagName === 'noscript' || tagName === 'noembed') && regExpTest(/<\/no(script|embed)/i, currentNode.innerHTML)) {
|
905 |
+
_forceRemove(currentNode);
|
906 |
+
return true;
|
907 |
+
}
|
908 |
+
|
909 |
+
/* Sanitize element content to be template-safe */
|
910 |
+
if (SAFE_FOR_TEMPLATES && currentNode.nodeType === 3) {
|
911 |
+
/* Get the element's text content */
|
912 |
+
content = currentNode.textContent;
|
913 |
+
content = stringReplace(content, MUSTACHE_EXPR$$1, ' ');
|
914 |
+
content = stringReplace(content, ERB_EXPR$$1, ' ');
|
915 |
+
if (currentNode.textContent !== content) {
|
916 |
+
arrayPush(DOMPurify.removed, { element: currentNode.cloneNode() });
|
917 |
+
currentNode.textContent = content;
|
918 |
+
}
|
919 |
+
}
|
920 |
+
|
921 |
+
/* Execute a hook if present */
|
922 |
+
_executeHook('afterSanitizeElements', currentNode, null);
|
923 |
+
|
924 |
+
return false;
|
925 |
+
};
|
926 |
+
|
927 |
+
/**
|
928 |
+
* _isValidAttribute
|
929 |
+
*
|
930 |
+
* @param {string} lcTag Lowercase tag name of containing element.
|
931 |
+
* @param {string} lcName Lowercase attribute name.
|
932 |
+
* @param {string} value Attribute value.
|
933 |
+
* @return {Boolean} Returns true if `value` is valid, otherwise false.
|
934 |
+
*/
|
935 |
+
// eslint-disable-next-line complexity
|
936 |
+
var _isValidAttribute = function _isValidAttribute(lcTag, lcName, value) {
|
937 |
+
/* Make sure attribute cannot clobber */
|
938 |
+
if (SANITIZE_DOM && (lcName === 'id' || lcName === 'name') && (value in document || value in formElement)) {
|
939 |
+
return false;
|
940 |
+
}
|
941 |
+
|
942 |
+
/* Allow valid data-* attributes: At least one character after "-"
|
943 |
+
(https://html.spec.whatwg.org/multipage/dom.html#embedding-custom-non-visible-data-with-the-data-*-attributes)
|
944 |
+
XML-compatible (https://html.spec.whatwg.org/multipage/infrastructure.html#xml-compatible and http://www.w3.org/TR/xml/#d0e804)
|
945 |
+
We don't need to check the value; it's always URI safe. */
|
946 |
+
if (ALLOW_DATA_ATTR && regExpTest(DATA_ATTR$$1, lcName)) ; else if (ALLOW_ARIA_ATTR && regExpTest(ARIA_ATTR$$1, lcName)) ; else if (!ALLOWED_ATTR[lcName] || FORBID_ATTR[lcName]) {
|
947 |
+
return false;
|
948 |
+
|
949 |
+
/* Check value is safe. First, is attr inert? If so, is safe */
|
950 |
+
} else if (URI_SAFE_ATTRIBUTES[lcName]) ; else if (regExpTest(IS_ALLOWED_URI$$1, stringReplace(value, ATTR_WHITESPACE$$1, ''))) ; else if ((lcName === 'src' || lcName === 'xlink:href' || lcName === 'href') && lcTag !== 'script' && stringIndexOf(value, 'data:') === 0 && DATA_URI_TAGS[lcTag]) ; else if (ALLOW_UNKNOWN_PROTOCOLS && !regExpTest(IS_SCRIPT_OR_DATA$$1, stringReplace(value, ATTR_WHITESPACE$$1, ''))) ; else if (!value) ; else {
|
951 |
+
return false;
|
952 |
+
}
|
953 |
+
|
954 |
+
return true;
|
955 |
+
};
|
956 |
+
|
957 |
+
/**
|
958 |
+
* _sanitizeAttributes
|
959 |
+
*
|
960 |
+
* @protect attributes
|
961 |
+
* @protect nodeName
|
962 |
+
* @protect removeAttribute
|
963 |
+
* @protect setAttribute
|
964 |
+
*
|
965 |
+
* @param {Node} currentNode to sanitize
|
966 |
+
*/
|
967 |
+
var _sanitizeAttributes = function _sanitizeAttributes(currentNode) {
|
968 |
+
var attr = void 0;
|
969 |
+
var value = void 0;
|
970 |
+
var lcName = void 0;
|
971 |
+
var l = void 0;
|
972 |
+
/* Execute a hook if present */
|
973 |
+
_executeHook('beforeSanitizeAttributes', currentNode, null);
|
974 |
+
|
975 |
+
var attributes = currentNode.attributes;
|
976 |
+
|
977 |
+
/* Check if we have attributes; if not we might have a text node */
|
978 |
+
|
979 |
+
if (!attributes) {
|
980 |
+
return;
|
981 |
+
}
|
982 |
+
|
983 |
+
var hookEvent = {
|
984 |
+
attrName: '',
|
985 |
+
attrValue: '',
|
986 |
+
keepAttr: true,
|
987 |
+
allowedAttributes: ALLOWED_ATTR
|
988 |
+
};
|
989 |
+
l = attributes.length;
|
990 |
+
|
991 |
+
/* Go backwards over all attributes; safely remove bad ones */
|
992 |
+
while (l--) {
|
993 |
+
attr = attributes[l];
|
994 |
+
var _attr = attr,
|
995 |
+
name = _attr.name,
|
996 |
+
namespaceURI = _attr.namespaceURI;
|
997 |
+
|
998 |
+
value = stringTrim(attr.value);
|
999 |
+
lcName = stringToLowerCase(name);
|
1000 |
+
|
1001 |
+
/* Execute a hook if present */
|
1002 |
+
hookEvent.attrName = lcName;
|
1003 |
+
hookEvent.attrValue = value;
|
1004 |
+
hookEvent.keepAttr = true;
|
1005 |
+
hookEvent.forceKeepAttr = undefined; // Allows developers to see this is a property they can set
|
1006 |
+
_executeHook('uponSanitizeAttribute', currentNode, hookEvent);
|
1007 |
+
value = hookEvent.attrValue;
|
1008 |
+
/* Did the hooks approve of the attribute? */
|
1009 |
+
if (hookEvent.forceKeepAttr) {
|
1010 |
+
continue;
|
1011 |
+
}
|
1012 |
+
|
1013 |
+
/* Remove attribute */
|
1014 |
+
_removeAttribute(name, currentNode);
|
1015 |
+
|
1016 |
+
/* Did the hooks approve of the attribute? */
|
1017 |
+
if (!hookEvent.keepAttr) {
|
1018 |
+
continue;
|
1019 |
+
}
|
1020 |
+
|
1021 |
+
/* Work around a security issue in jQuery 3.0 */
|
1022 |
+
if (regExpTest(/\/>/i, value)) {
|
1023 |
+
_removeAttribute(name, currentNode);
|
1024 |
+
continue;
|
1025 |
+
}
|
1026 |
+
|
1027 |
+
/* Sanitize attribute content to be template-safe */
|
1028 |
+
if (SAFE_FOR_TEMPLATES) {
|
1029 |
+
value = stringReplace(value, MUSTACHE_EXPR$$1, ' ');
|
1030 |
+
value = stringReplace(value, ERB_EXPR$$1, ' ');
|
1031 |
+
}
|
1032 |
+
|
1033 |
+
/* Is `value` valid for this attribute? */
|
1034 |
+
var lcTag = currentNode.nodeName.toLowerCase();
|
1035 |
+
if (!_isValidAttribute(lcTag, lcName, value)) {
|
1036 |
+
continue;
|
1037 |
+
}
|
1038 |
+
|
1039 |
+
/* Handle invalid data-* attribute set by try-catching it */
|
1040 |
+
try {
|
1041 |
+
if (namespaceURI) {
|
1042 |
+
currentNode.setAttributeNS(namespaceURI, name, value);
|
1043 |
+
} else {
|
1044 |
+
/* Fallback to setAttribute() for browser-unrecognized namespaces e.g. "x-schema". */
|
1045 |
+
currentNode.setAttribute(name, value);
|
1046 |
+
}
|
1047 |
+
|
1048 |
+
arrayPop(DOMPurify.removed);
|
1049 |
+
} catch (_) {}
|
1050 |
+
}
|
1051 |
+
|
1052 |
+
/* Execute a hook if present */
|
1053 |
+
_executeHook('afterSanitizeAttributes', currentNode, null);
|
1054 |
+
};
|
1055 |
+
|
1056 |
+
/**
|
1057 |
+
* _sanitizeShadowDOM
|
1058 |
+
*
|
1059 |
+
* @param {DocumentFragment} fragment to iterate over recursively
|
1060 |
+
*/
|
1061 |
+
var _sanitizeShadowDOM = function _sanitizeShadowDOM(fragment) {
|
1062 |
+
var shadowNode = void 0;
|
1063 |
+
var shadowIterator = _createIterator(fragment);
|
1064 |
+
|
1065 |
+
/* Execute a hook if present */
|
1066 |
+
_executeHook('beforeSanitizeShadowDOM', fragment, null);
|
1067 |
+
|
1068 |
+
while (shadowNode = shadowIterator.nextNode()) {
|
1069 |
+
/* Execute a hook if present */
|
1070 |
+
_executeHook('uponSanitizeShadowNode', shadowNode, null);
|
1071 |
+
|
1072 |
+
/* Sanitize tags and elements */
|
1073 |
+
if (_sanitizeElements(shadowNode)) {
|
1074 |
+
continue;
|
1075 |
+
}
|
1076 |
+
|
1077 |
+
/* Deep shadow DOM detected */
|
1078 |
+
if (shadowNode.content instanceof DocumentFragment) {
|
1079 |
+
_sanitizeShadowDOM(shadowNode.content);
|
1080 |
+
}
|
1081 |
+
|
1082 |
+
/* Check attributes, sanitize if necessary */
|
1083 |
+
_sanitizeAttributes(shadowNode);
|
1084 |
+
}
|
1085 |
+
|
1086 |
+
/* Execute a hook if present */
|
1087 |
+
_executeHook('afterSanitizeShadowDOM', fragment, null);
|
1088 |
+
};
|
1089 |
+
|
1090 |
+
/**
|
1091 |
+
* Sanitize
|
1092 |
+
* Public method providing core sanitation functionality
|
1093 |
+
*
|
1094 |
+
* @param {String|Node} dirty string or DOM node
|
1095 |
+
* @param {Object} configuration object
|
1096 |
+
*/
|
1097 |
+
// eslint-disable-next-line complexity
|
1098 |
+
DOMPurify.sanitize = function (dirty, cfg) {
|
1099 |
+
var body = void 0;
|
1100 |
+
var importedNode = void 0;
|
1101 |
+
var currentNode = void 0;
|
1102 |
+
var oldNode = void 0;
|
1103 |
+
var returnNode = void 0;
|
1104 |
+
/* Make sure we have a string to sanitize.
|
1105 |
+
DO NOT return early, as this will return the wrong type if
|
1106 |
+
the user has requested a DOM object rather than a string */
|
1107 |
+
IS_EMPTY_INPUT = !dirty;
|
1108 |
+
if (IS_EMPTY_INPUT) {
|
1109 |
+
dirty = '<!-->';
|
1110 |
+
}
|
1111 |
+
|
1112 |
+
/* Stringify, in case dirty is an object */
|
1113 |
+
if (typeof dirty !== 'string' && !_isNode(dirty)) {
|
1114 |
+
// eslint-disable-next-line no-negated-condition
|
1115 |
+
if (typeof dirty.toString !== 'function') {
|
1116 |
+
throw typeErrorCreate('toString is not a function');
|
1117 |
+
} else {
|
1118 |
+
dirty = dirty.toString();
|
1119 |
+
if (typeof dirty !== 'string') {
|
1120 |
+
throw typeErrorCreate('dirty is not a string, aborting');
|
1121 |
+
}
|
1122 |
+
}
|
1123 |
+
}
|
1124 |
+
|
1125 |
+
/* Check we can run. Otherwise fall back or ignore */
|
1126 |
+
if (!DOMPurify.isSupported) {
|
1127 |
+
if (_typeof(window.toStaticHTML) === 'object' || typeof window.toStaticHTML === 'function') {
|
1128 |
+
if (typeof dirty === 'string') {
|
1129 |
+
return window.toStaticHTML(dirty);
|
1130 |
+
}
|
1131 |
+
|
1132 |
+
if (_isNode(dirty)) {
|
1133 |
+
return window.toStaticHTML(dirty.outerHTML);
|
1134 |
+
}
|
1135 |
+
}
|
1136 |
+
|
1137 |
+
return dirty;
|
1138 |
+
}
|
1139 |
+
|
1140 |
+
/* Assign config vars */
|
1141 |
+
if (!SET_CONFIG) {
|
1142 |
+
_parseConfig(cfg);
|
1143 |
+
}
|
1144 |
+
|
1145 |
+
/* Clean up removed elements */
|
1146 |
+
DOMPurify.removed = [];
|
1147 |
+
|
1148 |
+
/* Check if dirty is correctly typed for IN_PLACE */
|
1149 |
+
if (typeof dirty === 'string') {
|
1150 |
+
IN_PLACE = false;
|
1151 |
+
}
|
1152 |
+
|
1153 |
+
if (IN_PLACE) ; else if (dirty instanceof Node) {
|
1154 |
+
/* If dirty is a DOM element, append to an empty document to avoid
|
1155 |
+
elements being stripped by the parser */
|
1156 |
+
body = _initDocument('<!---->');
|
1157 |
+
importedNode = body.ownerDocument.importNode(dirty, true);
|
1158 |
+
if (importedNode.nodeType === 1 && importedNode.nodeName === 'BODY') {
|
1159 |
+
/* Node is already a body, use as is */
|
1160 |
+
body = importedNode;
|
1161 |
+
} else if (importedNode.nodeName === 'HTML') {
|
1162 |
+
body = importedNode;
|
1163 |
+
} else {
|
1164 |
+
// eslint-disable-next-line unicorn/prefer-dom-node-append
|
1165 |
+
body.appendChild(importedNode);
|
1166 |
+
}
|
1167 |
+
} else {
|
1168 |
+
/* Exit directly if we have nothing to do */
|
1169 |
+
if (!RETURN_DOM && !SAFE_FOR_TEMPLATES && !WHOLE_DOCUMENT &&
|
1170 |
+
// eslint-disable-next-line unicorn/prefer-includes
|
1171 |
+
dirty.indexOf('<') === -1) {
|
1172 |
+
return trustedTypesPolicy && RETURN_TRUSTED_TYPE ? trustedTypesPolicy.createHTML(dirty) : dirty;
|
1173 |
+
}
|
1174 |
+
|
1175 |
+
/* Initialize the document to work on */
|
1176 |
+
body = _initDocument(dirty);
|
1177 |
+
|
1178 |
+
/* Check we have a DOM node from the data */
|
1179 |
+
if (!body) {
|
1180 |
+
return RETURN_DOM ? null : emptyHTML;
|
1181 |
+
}
|
1182 |
+
}
|
1183 |
+
|
1184 |
+
/* Remove first element node (ours) if FORCE_BODY is set */
|
1185 |
+
if (body && FORCE_BODY) {
|
1186 |
+
_forceRemove(body.firstChild);
|
1187 |
+
}
|
1188 |
+
|
1189 |
+
/* Get node iterator */
|
1190 |
+
var nodeIterator = _createIterator(IN_PLACE ? dirty : body);
|
1191 |
+
|
1192 |
+
/* Now start iterating over the created document */
|
1193 |
+
while (currentNode = nodeIterator.nextNode()) {
|
1194 |
+
/* Fix IE's strange behavior with manipulated textNodes #89 */
|
1195 |
+
if (currentNode.nodeType === 3 && currentNode === oldNode) {
|
1196 |
+
continue;
|
1197 |
+
}
|
1198 |
+
|
1199 |
+
/* Sanitize tags and elements */
|
1200 |
+
if (_sanitizeElements(currentNode)) {
|
1201 |
+
continue;
|
1202 |
+
}
|
1203 |
+
|
1204 |
+
/* Shadow DOM detected, sanitize it */
|
1205 |
+
if (currentNode.content instanceof DocumentFragment) {
|
1206 |
+
_sanitizeShadowDOM(currentNode.content);
|
1207 |
+
}
|
1208 |
+
|
1209 |
+
/* Check attributes, sanitize if necessary */
|
1210 |
+
_sanitizeAttributes(currentNode);
|
1211 |
+
|
1212 |
+
oldNode = currentNode;
|
1213 |
+
}
|
1214 |
+
|
1215 |
+
oldNode = null;
|
1216 |
+
|
1217 |
+
/* If we sanitized `dirty` in-place, return it. */
|
1218 |
+
if (IN_PLACE) {
|
1219 |
+
return dirty;
|
1220 |
+
}
|
1221 |
+
|
1222 |
+
/* Return sanitized string or DOM */
|
1223 |
+
if (RETURN_DOM) {
|
1224 |
+
if (RETURN_DOM_FRAGMENT) {
|
1225 |
+
returnNode = createDocumentFragment.call(body.ownerDocument);
|
1226 |
+
|
1227 |
+
while (body.firstChild) {
|
1228 |
+
// eslint-disable-next-line unicorn/prefer-dom-node-append
|
1229 |
+
returnNode.appendChild(body.firstChild);
|
1230 |
+
}
|
1231 |
+
} else {
|
1232 |
+
returnNode = body;
|
1233 |
+
}
|
1234 |
+
|
1235 |
+
if (RETURN_DOM_IMPORT) {
|
1236 |
+
/*
|
1237 |
+
AdoptNode() is not used because internal state is not reset
|
1238 |
+
(e.g. the past names map of a HTMLFormElement), this is safe
|
1239 |
+
in theory but we would rather not risk another attack vector.
|
1240 |
+
The state that is cloned by importNode() is explicitly defined
|
1241 |
+
by the specs.
|
1242 |
+
*/
|
1243 |
+
returnNode = importNode.call(originalDocument, returnNode, true);
|
1244 |
+
}
|
1245 |
+
|
1246 |
+
return returnNode;
|
1247 |
+
}
|
1248 |
+
|
1249 |
+
var serializedHTML = WHOLE_DOCUMENT ? body.outerHTML : body.innerHTML;
|
1250 |
+
|
1251 |
+
/* Sanitize final string template-safe */
|
1252 |
+
if (SAFE_FOR_TEMPLATES) {
|
1253 |
+
serializedHTML = stringReplace(serializedHTML, MUSTACHE_EXPR$$1, ' ');
|
1254 |
+
serializedHTML = stringReplace(serializedHTML, ERB_EXPR$$1, ' ');
|
1255 |
+
}
|
1256 |
+
|
1257 |
+
return trustedTypesPolicy && RETURN_TRUSTED_TYPE ? trustedTypesPolicy.createHTML(serializedHTML) : serializedHTML;
|
1258 |
+
};
|
1259 |
+
|
1260 |
+
/**
|
1261 |
+
* Public method to set the configuration once
|
1262 |
+
* setConfig
|
1263 |
+
*
|
1264 |
+
* @param {Object} cfg configuration object
|
1265 |
+
*/
|
1266 |
+
DOMPurify.setConfig = function (cfg) {
|
1267 |
+
_parseConfig(cfg);
|
1268 |
+
SET_CONFIG = true;
|
1269 |
+
};
|
1270 |
+
|
1271 |
+
/**
|
1272 |
+
* Public method to remove the configuration
|
1273 |
+
* clearConfig
|
1274 |
+
*
|
1275 |
+
*/
|
1276 |
+
DOMPurify.clearConfig = function () {
|
1277 |
+
CONFIG = null;
|
1278 |
+
SET_CONFIG = false;
|
1279 |
+
};
|
1280 |
+
|
1281 |
+
/**
|
1282 |
+
* Public method to check if an attribute value is valid.
|
1283 |
+
* Uses last set config, if any. Otherwise, uses config defaults.
|
1284 |
+
* isValidAttribute
|
1285 |
+
*
|
1286 |
+
* @param {string} tag Tag name of containing element.
|
1287 |
+
* @param {string} attr Attribute name.
|
1288 |
+
* @param {string} value Attribute value.
|
1289 |
+
* @return {Boolean} Returns true if `value` is valid. Otherwise, returns false.
|
1290 |
+
*/
|
1291 |
+
DOMPurify.isValidAttribute = function (tag, attr, value) {
|
1292 |
+
/* Initialize shared config vars if necessary. */
|
1293 |
+
if (!CONFIG) {
|
1294 |
+
_parseConfig({});
|
1295 |
+
}
|
1296 |
+
|
1297 |
+
var lcTag = stringToLowerCase(tag);
|
1298 |
+
var lcName = stringToLowerCase(attr);
|
1299 |
+
return _isValidAttribute(lcTag, lcName, value);
|
1300 |
+
};
|
1301 |
+
|
1302 |
+
/**
|
1303 |
+
* AddHook
|
1304 |
+
* Public method to add DOMPurify hooks
|
1305 |
+
*
|
1306 |
+
* @param {String} entryPoint entry point for the hook to add
|
1307 |
+
* @param {Function} hookFunction function to execute
|
1308 |
+
*/
|
1309 |
+
DOMPurify.addHook = function (entryPoint, hookFunction) {
|
1310 |
+
if (typeof hookFunction !== 'function') {
|
1311 |
+
return;
|
1312 |
+
}
|
1313 |
+
|
1314 |
+
hooks[entryPoint] = hooks[entryPoint] || [];
|
1315 |
+
arrayPush(hooks[entryPoint], hookFunction);
|
1316 |
+
};
|
1317 |
+
|
1318 |
+
/**
|
1319 |
+
* RemoveHook
|
1320 |
+
* Public method to remove a DOMPurify hook at a given entryPoint
|
1321 |
+
* (pops it from the stack of hooks if more are present)
|
1322 |
+
*
|
1323 |
+
* @param {String} entryPoint entry point for the hook to remove
|
1324 |
+
*/
|
1325 |
+
DOMPurify.removeHook = function (entryPoint) {
|
1326 |
+
if (hooks[entryPoint]) {
|
1327 |
+
arrayPop(hooks[entryPoint]);
|
1328 |
+
}
|
1329 |
+
};
|
1330 |
+
|
1331 |
+
/**
|
1332 |
+
* RemoveHooks
|
1333 |
+
* Public method to remove all DOMPurify hooks at a given entryPoint
|
1334 |
+
*
|
1335 |
+
* @param {String} entryPoint entry point for the hooks to remove
|
1336 |
+
*/
|
1337 |
+
DOMPurify.removeHooks = function (entryPoint) {
|
1338 |
+
if (hooks[entryPoint]) {
|
1339 |
+
hooks[entryPoint] = [];
|
1340 |
+
}
|
1341 |
+
};
|
1342 |
+
|
1343 |
+
/**
|
1344 |
+
* RemoveAllHooks
|
1345 |
+
* Public method to remove all DOMPurify hooks
|
1346 |
+
*
|
1347 |
+
*/
|
1348 |
+
DOMPurify.removeAllHooks = function () {
|
1349 |
+
hooks = {};
|
1350 |
+
};
|
1351 |
+
|
1352 |
+
return DOMPurify;
|
1353 |
+
}
|
1354 |
+
|
1355 |
+
var purify = createDOMPurify();
|
1356 |
+
|
1357 |
+
return purify;
|
1358 |
+
|
1359 |
+
}));
|
1360 |
+
//# sourceMappingURL=purify.js.map
|
1361 |
+
|
1362 |
+
|
1363 |
+
/***/ })
|
1364 |
+
|
1365 |
+
}]);
|
trunk/dist/chunks/1.min.js
ADDED
@@ -0,0 +1,2 @@
|
|
|
|
|
1 |
+
/*! For license information please see 1.min.js.LICENSE.txt */
|
2 |
+
(window.__wcAdmin_webpackJsonp=window.__wcAdmin_webpackJsonp||[]).push([[1],{53:function(e,t,n){e.exports=function(){"use strict";var e=Object.hasOwnProperty,t=Object.setPrototypeOf,n=Object.isFrozen,r=Object.getPrototypeOf,o=Object.getOwnPropertyDescriptor,i=Object.freeze,a=Object.seal,l=Object.create,c="undefined"!=typeof Reflect&&Reflect,s=c.apply,u=c.construct;s||(s=function(e,t,n){return e.apply(t,n)}),i||(i=function(e){return e}),a||(a=function(e){return e}),u||(u=function(e,t){return new(Function.prototype.bind.apply(e,[null].concat(function(e){if(Array.isArray(e)){for(var t=0,n=Array(e.length);t<e.length;t++)n[t]=e[t];return n}return Array.from(e)}(t))))});var f,m=w(Array.prototype.forEach),p=w(Array.prototype.pop),d=w(Array.prototype.push),g=w(String.prototype.toLowerCase),h=w(String.prototype.match),y=w(String.prototype.replace),v=w(String.prototype.indexOf),b=w(String.prototype.trim),A=w(RegExp.prototype.test),T=(f=TypeError,function(){for(var e=arguments.length,t=Array(e),n=0;n<e;n++)t[n]=arguments[n];return u(f,t)});function w(e){return function(t){for(var n=arguments.length,r=Array(n>1?n-1:0),o=1;o<n;o++)r[o-1]=arguments[o];return s(e,t,r)}}function x(e,r){t&&t(e,null);for(var o=r.length;o--;){var i=r[o];if("string"==typeof i){var a=g(i);a!==i&&(n(r)||(r[o]=a),i=a)}e[i]=!0}return e}function S(t){var n=l(null),r=void 0;for(r in t)s(e,t,[r])&&(n[r]=t[r]);return n}function k(e,t){for(;null!==e;){var n=o(e,t);if(n){if(n.get)return w(n.get);if("function"==typeof n.value)return w(n.value)}e=r(e)}return function(e){return console.warn("fallback value for",e),null}}var _=i(["a","abbr","acronym","address","area","article","aside","audio","b","bdi","bdo","big","blink","blockquote","body","br","button","canvas","caption","center","cite","code","col","colgroup","content","data","datalist","dd","decorator","del","details","dfn","dialog","dir","div","dl","dt","element","em","fieldset","figcaption","figure","font","footer","form","h1","h2","h3","h4","h5","h6","head","header","hgroup","hr","html","i","img","input","ins","kbd","label","legend","li","main","map","mark","marquee","menu","menuitem","meter","nav","nobr","ol","optgroup","option","output","p","picture","pre","progress","q","rp","rt","ruby","s","samp","section","select","shadow","small","source","spacer","span","strike","strong","style","sub","summary","sup","table","tbody","td","template","textarea","tfoot","th","thead","time","tr","track","tt","u","ul","var","video","wbr"]),E=i(["svg","a","altglyph","altglyphdef","altglyphitem","animatecolor","animatemotion","animatetransform","circle","clippath","defs","desc","ellipse","filter","font","g","glyph","glyphref","hkern","image","line","lineargradient","marker","mask","metadata","mpath","path","pattern","polygon","polyline","radialgradient","rect","stop","style","switch","symbol","text","textpath","title","tref","tspan","view","vkern"]),R=i(["feBlend","feColorMatrix","feComponentTransfer","feComposite","feConvolveMatrix","feDiffuseLighting","feDisplacementMap","feDistantLight","feFlood","feFuncA","feFuncB","feFuncG","feFuncR","feGaussianBlur","feMerge","feMergeNode","feMorphology","feOffset","fePointLight","feSpecularLighting","feSpotLight","feTile","feTurbulence"]),D=i(["animate","color-profile","cursor","discard","fedropshadow","feimage","font-face","font-face-format","font-face-name","font-face-src","font-face-uri","foreignobject","hatch","hatchpath","mesh","meshgradient","meshpatch","meshrow","missing-glyph","script","set","solidcolor","unknown","use"]),N=i(["math","menclose","merror","mfenced","mfrac","mglyph","mi","mlabeledtr","mmultiscripts","mn","mo","mover","mpadded","mphantom","mroot","mrow","ms","mspace","msqrt","mstyle","msub","msup","msubsup","mtable","mtd","mtext","mtr","munder","munderover"]),O=i(["maction","maligngroup","malignmark","mlongdiv","mscarries","mscarry","msgroup","mstack","msline","msrow","semantics","annotation","annotation-xml","mprescripts","none"]),L=i(["#text"]),M=i(["accept","action","align","alt","autocapitalize","autocomplete","autopictureinpicture","autoplay","background","bgcolor","border","capture","cellpadding","cellspacing","checked","cite","class","clear","color","cols","colspan","controls","controlslist","coords","crossorigin","datetime","decoding","default","dir","disabled","disablepictureinpicture","disableremoteplayback","download","draggable","enctype","enterkeyhint","face","for","headers","height","hidden","high","href","hreflang","id","inputmode","integrity","ismap","kind","label","lang","list","loading","loop","low","max","maxlength","media","method","min","minlength","multiple","muted","name","noshade","novalidate","nowrap","open","optimum","pattern","placeholder","playsinline","poster","preload","pubdate","radiogroup","readonly","rel","required","rev","reversed","role","rows","rowspan","spellcheck","scope","selected","shape","size","sizes","span","srclang","start","src","srcset","step","style","summary","tabindex","title","translate","type","usemap","valign","value","width","xmlns","slot"]),F=i(["accent-height","accumulate","additive","alignment-baseline","ascent","attributename","attributetype","azimuth","basefrequency","baseline-shift","begin","bias","by","class","clip","clippathunits","clip-path","clip-rule","color","color-interpolation","color-interpolation-filters","color-profile","color-rendering","cx","cy","d","dx","dy","diffuseconstant","direction","display","divisor","dur","edgemode","elevation","end","fill","fill-opacity","fill-rule","filter","filterunits","flood-color","flood-opacity","font-family","font-size","font-size-adjust","font-stretch","font-style","font-variant","font-weight","fx","fy","g1","g2","glyph-name","glyphref","gradientunits","gradienttransform","height","href","id","image-rendering","in","in2","k","k1","k2","k3","k4","kerning","keypoints","keysplines","keytimes","lang","lengthadjust","letter-spacing","kernelmatrix","kernelunitlength","lighting-color","local","marker-end","marker-mid","marker-start","markerheight","markerunits","markerwidth","maskcontentunits","maskunits","max","mask","media","method","mode","min","name","numoctaves","offset","operator","opacity","order","orient","orientation","origin","overflow","paint-order","path","pathlength","patterncontentunits","patterntransform","patternunits","points","preservealpha","preserveaspectratio","primitiveunits","r","rx","ry","radius","refx","refy","repeatcount","repeatdur","restart","result","rotate","scale","seed","shape-rendering","specularconstant","specularexponent","spreadmethod","startoffset","stddeviation","stitchtiles","stop-color","stop-opacity","stroke-dasharray","stroke-dashoffset","stroke-linecap","stroke-linejoin","stroke-miterlimit","stroke-opacity","stroke","stroke-width","style","surfacescale","systemlanguage","tabindex","targetx","targety","transform","text-anchor","text-decoration","text-rendering","textlength","type","u1","u2","unicode","values","viewbox","visibility","version","vert-adv-y","vert-origin-x","vert-origin-y","width","word-spacing","wrap","writing-mode","xchannelselector","ychannelselector","x","x1","x2","xmlns","y","y1","y2","z","zoomandpan"]),I=i(["accent","accentunder","align","bevelled","close","columnsalign","columnlines","columnspan","denomalign","depth","dir","display","displaystyle","encoding","fence","frame","height","href","id","largeop","length","linethickness","lspace","lquote","mathbackground","mathcolor","mathsize","mathvariant","maxsize","minsize","movablelimits","notation","numalign","open","rowalign","rowlines","rowspacing","rowspan","rspace","rquote","scriptlevel","scriptminsize","scriptsizemultiplier","selection","separator","separators","stretchy","subscriptshift","supscriptshift","symmetric","voffset","width","xmlns"]),C=i(["xlink:href","xml:id","xlink:title","xml:space","xmlns:xlink"]),z=a(/\{\{[\s\S]*|[\s\S]*\}\}/gm),U=a(/<%[\s\S]*|[\s\S]*%>/gm),H=a(/^data-[\-\w.\u00B7-\uFFFF]/),j=a(/^aria-[\-\w]+$/),P=a(/^(?:(?:(?:f|ht)tps?|mailto|tel|callto|cid|xmpp):|[^a-z]|[a-z+.\-]+(?:[^a-z+.\-:]|$))/i),B=a(/^(?:\w+script|data):/i),W=a(/[\u0000-\u0020\u00A0\u1680\u180E\u2000-\u2029\u205F\u3000]/g),G="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e};function q(e){if(Array.isArray(e)){for(var t=0,n=Array(e.length);t<e.length;t++)n[t]=e[t];return n}return Array.from(e)}var K=function(){return"undefined"==typeof window?null:window},V=function(e,t){if("object"!==(void 0===e?"undefined":G(e))||"function"!=typeof e.createPolicy)return null;var n=null;t.currentScript&&t.currentScript.hasAttribute("data-tt-policy-suffix")&&(n=t.currentScript.getAttribute("data-tt-policy-suffix"));var r="dompurify"+(n?"#"+n:"");try{return e.createPolicy(r,{createHTML:function(e){return e}})}catch(e){return console.warn("TrustedTypes policy "+r+" could not be created."),null}};return function e(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:K(),n=function(t){return e(t)};if(n.version="2.2.9",n.removed=[],!t||!t.document||9!==t.document.nodeType)return n.isSupported=!1,n;var r=t.document,o=t.document,a=t.DocumentFragment,l=t.HTMLTemplateElement,c=t.Node,s=t.Element,u=t.NodeFilter,f=t.NamedNodeMap,w=void 0===f?t.NamedNodeMap||t.MozNamedAttrMap:f,Y=t.Text,J=t.Comment,X=t.DOMParser,$=t.trustedTypes,Z=s.prototype,Q=k(Z,"cloneNode"),ee=k(Z,"nextSibling"),te=k(Z,"childNodes"),ne=k(Z,"parentNode");if("function"==typeof l){var re=o.createElement("template");re.content&&re.content.ownerDocument&&(o=re.content.ownerDocument)}var oe=V($,r),ie=oe&&Ce?oe.createHTML(""):"",ae=o,le=ae.implementation,ce=ae.createNodeIterator,se=ae.createDocumentFragment,ue=r.importNode,fe={};try{fe=S(o).documentMode?o.documentMode:{}}catch(e){}var me={};n.isSupported="function"==typeof ne&&le&&void 0!==le.createHTMLDocument&&9!==fe;var pe=z,de=U,ge=H,he=j,ye=B,ve=W,be=P,Ae=null,Te=x({},[].concat(q(_),q(E),q(R),q(N),q(L))),we=null,xe=x({},[].concat(q(M),q(F),q(I),q(C))),Se=null,ke=null,_e=!0,Ee=!0,Re=!1,De=!1,Ne=!1,Oe=!1,Le=!1,Me=!1,Fe=!1,Ie=!0,Ce=!1,ze=!0,Ue=!0,He=!1,je={},Pe=x({},["annotation-xml","audio","colgroup","desc","foreignobject","head","iframe","math","mi","mn","mo","ms","mtext","noembed","noframes","noscript","plaintext","script","style","svg","template","thead","title","video","xmp"]),Be=null,We=x({},["audio","video","img","source","image","track"]),Ge=null,qe=x({},["alt","class","for","id","label","name","pattern","placeholder","summary","title","value","style","xmlns"]),Ke="http://www.w3.org/1998/Math/MathML",Ve="http://www.w3.org/2000/svg",Ye="http://www.w3.org/1999/xhtml",Je=Ye,Xe=!1,$e=null,Ze=o.createElement("form"),Qe=function(e){$e&&$e===e||(e&&"object"===(void 0===e?"undefined":G(e))||(e={}),e=S(e),Ae="ALLOWED_TAGS"in e?x({},e.ALLOWED_TAGS):Te,we="ALLOWED_ATTR"in e?x({},e.ALLOWED_ATTR):xe,Ge="ADD_URI_SAFE_ATTR"in e?x(S(qe),e.ADD_URI_SAFE_ATTR):qe,Be="ADD_DATA_URI_TAGS"in e?x(S(We),e.ADD_DATA_URI_TAGS):We,Se="FORBID_TAGS"in e?x({},e.FORBID_TAGS):{},ke="FORBID_ATTR"in e?x({},e.FORBID_ATTR):{},je="USE_PROFILES"in e&&e.USE_PROFILES,_e=!1!==e.ALLOW_ARIA_ATTR,Ee=!1!==e.ALLOW_DATA_ATTR,Re=e.ALLOW_UNKNOWN_PROTOCOLS||!1,De=e.SAFE_FOR_TEMPLATES||!1,Ne=e.WHOLE_DOCUMENT||!1,Me=e.RETURN_DOM||!1,Fe=e.RETURN_DOM_FRAGMENT||!1,Ie=!1!==e.RETURN_DOM_IMPORT,Ce=e.RETURN_TRUSTED_TYPE||!1,Le=e.FORCE_BODY||!1,ze=!1!==e.SANITIZE_DOM,Ue=!1!==e.KEEP_CONTENT,He=e.IN_PLACE||!1,be=e.ALLOWED_URI_REGEXP||be,Je=e.NAMESPACE||Ye,De&&(Ee=!1),Fe&&(Me=!0),je&&(Ae=x({},[].concat(q(L))),we=[],!0===je.html&&(x(Ae,_),x(we,M)),!0===je.svg&&(x(Ae,E),x(we,F),x(we,C)),!0===je.svgFilters&&(x(Ae,R),x(we,F),x(we,C)),!0===je.mathMl&&(x(Ae,N),x(we,I),x(we,C))),e.ADD_TAGS&&(Ae===Te&&(Ae=S(Ae)),x(Ae,e.ADD_TAGS)),e.ADD_ATTR&&(we===xe&&(we=S(we)),x(we,e.ADD_ATTR)),e.ADD_URI_SAFE_ATTR&&x(Ge,e.ADD_URI_SAFE_ATTR),Ue&&(Ae["#text"]=!0),Ne&&x(Ae,["html","head","body"]),Ae.table&&(x(Ae,["tbody"]),delete Se.tbody),i&&i(e),$e=e)},et=x({},["mi","mo","mn","ms","mtext"]),tt=x({},["foreignobject","desc","title","annotation-xml"]),nt=x({},E);x(nt,R),x(nt,D);var rt=x({},N);x(rt,O);var ot=function(e){var t=ne(e);t&&t.tagName||(t={namespaceURI:Ye,tagName:"template"});var n=g(e.tagName),r=g(t.tagName);if(e.namespaceURI===Ve)return t.namespaceURI===Ye?"svg"===n:t.namespaceURI===Ke?"svg"===n&&("annotation-xml"===r||et[r]):Boolean(nt[n]);if(e.namespaceURI===Ke)return t.namespaceURI===Ye?"math"===n:t.namespaceURI===Ve?"math"===n&&tt[r]:Boolean(rt[n]);if(e.namespaceURI===Ye){if(t.namespaceURI===Ve&&!tt[r])return!1;if(t.namespaceURI===Ke&&!et[r])return!1;var o=x({},["title","style","font","a","script"]);return!rt[n]&&(o[n]||!nt[n])}return!1},it=function(e){d(n.removed,{element:e});try{e.parentNode.removeChild(e)}catch(t){try{e.outerHTML=ie}catch(t){e.remove()}}},at=function(e,t){try{d(n.removed,{attribute:t.getAttributeNode(e),from:t})}catch(e){d(n.removed,{attribute:null,from:t})}if(t.removeAttribute(e),"is"===e&&!we[e])if(Me||Fe)try{it(t)}catch(e){}else try{t.setAttribute(e,"")}catch(e){}},lt=function(e){var t=void 0,n=void 0;if(Le)e="<remove></remove>"+e;else{var r=h(e,/^[\r\n\t ]+/);n=r&&r[0]}var i=oe?oe.createHTML(e):e;if(Je===Ye)try{t=(new X).parseFromString(i,"text/html")}catch(e){}if(!t||!t.documentElement){t=le.createDocument(Je,"template",null);try{t.documentElement.innerHTML=Xe?"":i}catch(e){}}var a=t.body||t.documentElement;return e&&n&&a.insertBefore(o.createTextNode(n),a.childNodes[0]||null),Ne?t.documentElement:a},ct=function(e){return ce.call(e.ownerDocument||e,e,u.SHOW_ELEMENT|u.SHOW_COMMENT|u.SHOW_TEXT,null,!1)},st=function(e){return!(e instanceof Y||e instanceof J||"string"==typeof e.nodeName&&"string"==typeof e.textContent&&"function"==typeof e.removeChild&&e.attributes instanceof w&&"function"==typeof e.removeAttribute&&"function"==typeof e.setAttribute&&"string"==typeof e.namespaceURI&&"function"==typeof e.insertBefore)},ut=function(e){return"object"===(void 0===c?"undefined":G(c))?e instanceof c:e&&"object"===(void 0===e?"undefined":G(e))&&"number"==typeof e.nodeType&&"string"==typeof e.nodeName},ft=function(e,t,r){me[e]&&m(me[e],(function(e){e.call(n,t,r,$e)}))},mt=function(e){var t=void 0;if(ft("beforeSanitizeElements",e,null),st(e))return it(e),!0;if(h(e.nodeName,/[\u0080-\uFFFF]/))return it(e),!0;var r=g(e.nodeName);if(ft("uponSanitizeElement",e,{tagName:r,allowedTags:Ae}),!ut(e.firstElementChild)&&(!ut(e.content)||!ut(e.content.firstElementChild))&&A(/<[/\w]/g,e.innerHTML)&&A(/<[/\w]/g,e.textContent))return it(e),!0;if(!Ae[r]||Se[r]){if(Ue&&!Pe[r]){var o=ne(e)||e.parentNode,i=te(e)||e.childNodes;if(i&&o)for(var a=i.length-1;a>=0;--a)o.insertBefore(Q(i[a],!0),ee(e))}return it(e),!0}return e instanceof s&&!ot(e)?(it(e),!0):"noscript"!==r&&"noembed"!==r||!A(/<\/no(script|embed)/i,e.innerHTML)?(De&&3===e.nodeType&&(t=e.textContent,t=y(t,pe," "),t=y(t,de," "),e.textContent!==t&&(d(n.removed,{element:e.cloneNode()}),e.textContent=t)),ft("afterSanitizeElements",e,null),!1):(it(e),!0)},pt=function(e,t,n){if(ze&&("id"===t||"name"===t)&&(n in o||n in Ze))return!1;if(Ee&&A(ge,t));else if(_e&&A(he,t));else{if(!we[t]||ke[t])return!1;if(Ge[t]);else if(A(be,y(n,ve,"")));else if("src"!==t&&"xlink:href"!==t&&"href"!==t||"script"===e||0!==v(n,"data:")||!Be[e])if(Re&&!A(ye,y(n,ve,"")));else if(n)return!1}return!0},dt=function(e){var t=void 0,r=void 0,o=void 0,i=void 0;ft("beforeSanitizeAttributes",e,null);var a=e.attributes;if(a){var l={attrName:"",attrValue:"",keepAttr:!0,allowedAttributes:we};for(i=a.length;i--;){var c=t=a[i],s=c.name,u=c.namespaceURI;if(r=b(t.value),o=g(s),l.attrName=o,l.attrValue=r,l.keepAttr=!0,l.forceKeepAttr=void 0,ft("uponSanitizeAttribute",e,l),r=l.attrValue,!l.forceKeepAttr&&(at(s,e),l.keepAttr))if(A(/\/>/i,r))at(s,e);else{De&&(r=y(r,pe," "),r=y(r,de," "));var f=e.nodeName.toLowerCase();if(pt(f,o,r))try{u?e.setAttributeNS(u,s,r):e.setAttribute(s,r),p(n.removed)}catch(e){}}}ft("afterSanitizeAttributes",e,null)}},gt=function e(t){var n=void 0,r=ct(t);for(ft("beforeSanitizeShadowDOM",t,null);n=r.nextNode();)ft("uponSanitizeShadowNode",n,null),mt(n)||(n.content instanceof a&&e(n.content),dt(n));ft("afterSanitizeShadowDOM",t,null)};return n.sanitize=function(e,o){var i=void 0,l=void 0,s=void 0,u=void 0,f=void 0;if((Xe=!e)&&(e="\x3c!--\x3e"),"string"!=typeof e&&!ut(e)){if("function"!=typeof e.toString)throw T("toString is not a function");if("string"!=typeof(e=e.toString()))throw T("dirty is not a string, aborting")}if(!n.isSupported){if("object"===G(t.toStaticHTML)||"function"==typeof t.toStaticHTML){if("string"==typeof e)return t.toStaticHTML(e);if(ut(e))return t.toStaticHTML(e.outerHTML)}return e}if(Oe||Qe(o),n.removed=[],"string"==typeof e&&(He=!1),He);else if(e instanceof c)1===(l=(i=lt("\x3c!----\x3e")).ownerDocument.importNode(e,!0)).nodeType&&"BODY"===l.nodeName||"HTML"===l.nodeName?i=l:i.appendChild(l);else{if(!Me&&!De&&!Ne&&-1===e.indexOf("<"))return oe&&Ce?oe.createHTML(e):e;if(!(i=lt(e)))return Me?null:ie}i&&Le&&it(i.firstChild);for(var m=ct(He?e:i);s=m.nextNode();)3===s.nodeType&&s===u||mt(s)||(s.content instanceof a&>(s.content),dt(s),u=s);if(u=null,He)return e;if(Me){if(Fe)for(f=se.call(i.ownerDocument);i.firstChild;)f.appendChild(i.firstChild);else f=i;return Ie&&(f=ue.call(r,f,!0)),f}var p=Ne?i.outerHTML:i.innerHTML;return De&&(p=y(p,pe," "),p=y(p,de," ")),oe&&Ce?oe.createHTML(p):p},n.setConfig=function(e){Qe(e),Oe=!0},n.clearConfig=function(){$e=null,Oe=!1},n.isValidAttribute=function(e,t,n){$e||Qe({});var r=g(e),o=g(t);return pt(r,o,n)},n.addHook=function(e,t){"function"==typeof t&&(me[e]=me[e]||[],d(me[e],t))},n.removeHook=function(e){me[e]&&p(me[e])},n.removeHooks=function(e){me[e]&&(me[e]=[])},n.removeAllHooks=function(){me={}},n}()}()}}]);
|
trunk/dist/chunks/10.style.css
ADDED
@@ -0,0 +1 @@
|
|
|
1 |
+
:root{--wp-admin-theme-color:#007cba;--wp-admin-theme-color-darker-10:#006ba1;--wp-admin-theme-color-darker-20:#005a87}body.admin-color-light{--wp-admin-theme-color:#0085ba;--wp-admin-theme-color-darker-10:#0073a1;--wp-admin-theme-color-darker-20:#006187}body.admin-color-modern{--wp-admin-theme-color:#3858e9;--wp-admin-theme-color-darker-10:#2145e6;--wp-admin-theme-color-darker-20:#183ad6}body.admin-color-blue{--wp-admin-theme-color:#096484;--wp-admin-theme-color-darker-10:#07526c;--wp-admin-theme-color-darker-20:#064054}body.admin-color-coffee{--wp-admin-theme-color:#46403c;--wp-admin-theme-color-darker-10:#383330;--wp-admin-theme-color-darker-20:#2b2724}body.admin-color-ectoplasm{--wp-admin-theme-color:#523f6d;--wp-admin-theme-color-darker-10:#46365d;--wp-admin-theme-color-darker-20:#3a2c4d}body.admin-color-midnight{--wp-admin-theme-color:#e14d43;--wp-admin-theme-color-darker-10:#dd382d;--wp-admin-theme-color-darker-20:#d02c21}body.admin-color-ocean{--wp-admin-theme-color:#627c83;--wp-admin-theme-color-darker-10:#576e74;--wp-admin-theme-color-darker-20:#4c6066}body.admin-color-sunrise{--wp-admin-theme-color:#dd823b;--wp-admin-theme-color-darker-10:#d97426;--wp-admin-theme-color-darker-20:#c36922}.woocommerce-orders-table__status{flex-direction:row-reverse}.woocommerce-orders-table__status .woocommerce-order-status__indicator{margin-right:0;margin-left:8px}
|
trunk/dist/chunks/10.style.rtl.css
ADDED
@@ -0,0 +1 @@
|
|
|
1 |
+
:root{--wp-admin-theme-color:#007cba;--wp-admin-theme-color-darker-10:#006ba1;--wp-admin-theme-color-darker-20:#005a87}body.admin-color-light{--wp-admin-theme-color:#0085ba;--wp-admin-theme-color-darker-10:#0073a1;--wp-admin-theme-color-darker-20:#006187}body.admin-color-modern{--wp-admin-theme-color:#3858e9;--wp-admin-theme-color-darker-10:#2145e6;--wp-admin-theme-color-darker-20:#183ad6}body.admin-color-blue{--wp-admin-theme-color:#096484;--wp-admin-theme-color-darker-10:#07526c;--wp-admin-theme-color-darker-20:#064054}body.admin-color-coffee{--wp-admin-theme-color:#46403c;--wp-admin-theme-color-darker-10:#383330;--wp-admin-theme-color-darker-20:#2b2724}body.admin-color-ectoplasm{--wp-admin-theme-color:#523f6d;--wp-admin-theme-color-darker-10:#46365d;--wp-admin-theme-color-darker-20:#3a2c4d}body.admin-color-midnight{--wp-admin-theme-color:#e14d43;--wp-admin-theme-color-darker-10:#dd382d;--wp-admin-theme-color-darker-20:#d02c21}body.admin-color-ocean{--wp-admin-theme-color:#627c83;--wp-admin-theme-color-darker-10:#576e74;--wp-admin-theme-color-darker-20:#4c6066}body.admin-color-sunrise{--wp-admin-theme-color:#dd823b;--wp-admin-theme-color-darker-10:#d97426;--wp-admin-theme-color-darker-20:#c36922}.woocommerce-table__product-categories>.woocommerce-table__breadcrumbs{display:inline-block;margin-left:12px}.woocommerce-table__product-categories .components-popover__content{padding:0 16px;text-align:right}.woocommerce-table__product-categories .components-popover__content .woocommerce-table__breadcrumbs{margin-top:12px;margin-bottom:12px}
|
trunk/dist/chunks/11.style.css
ADDED
@@ -0,0 +1 @@
|
|
|
1 |
+
:root{--wp-admin-theme-color:#007cba;--wp-admin-theme-color-darker-10:#006ba1;--wp-admin-theme-color-darker-20:#005a87}body.admin-color-light{--wp-admin-theme-color:#0085ba;--wp-admin-theme-color-darker-10:#0073a1;--wp-admin-theme-color-darker-20:#006187}body.admin-color-modern{--wp-admin-theme-color:#3858e9;--wp-admin-theme-color-darker-10:#2145e6;--wp-admin-theme-color-darker-20:#183ad6}body.admin-color-blue{--wp-admin-theme-color:#096484;--wp-admin-theme-color-darker-10:#07526c;--wp-admin-theme-color-darker-20:#064054}body.admin-color-coffee{--wp-admin-theme-color:#46403c;--wp-admin-theme-color-darker-10:#383330;--wp-admin-theme-color-darker-20:#2b2724}body.admin-color-ectoplasm{--wp-admin-theme-color:#523f6d;--wp-admin-theme-color-darker-10:#46365d;--wp-admin-theme-color-darker-20:#3a2c4d}body.admin-color-midnight{--wp-admin-theme-color:#e14d43;--wp-admin-theme-color-darker-10:#dd382d;--wp-admin-theme-color-darker-20:#d02c21}body.admin-color-ocean{--wp-admin-theme-color:#627c83;--wp-admin-theme-color-darker-10:#576e74;--wp-admin-theme-color-darker-20:#4c6066}body.admin-color-sunrise{--wp-admin-theme-color:#dd823b;--wp-admin-theme-color-darker-10:#d97426;--wp-admin-theme-color-darker-20:#c36922}.woocommerce-table__product-categories>.woocommerce-table__breadcrumbs{display:inline-block;margin-right:12px}.woocommerce-table__product-categories .components-popover__content{padding:0 16px;text-align:left}.woocommerce-table__product-categories .components-popover__content .woocommerce-table__breadcrumbs{margin-top:12px;margin-bottom:12px}
|
trunk/dist/chunks/11.style.rtl.css
ADDED
@@ -0,0 +1 @@
|
|
|
1 |
+
:root{--wp-admin-theme-color:#007cba;--wp-admin-theme-color-darker-10:#006ba1;--wp-admin-theme-color-darker-20:#005a87}body.admin-color-light{--wp-admin-theme-color:#0085ba;--wp-admin-theme-color-darker-10:#0073a1;--wp-admin-theme-color-darker-20:#006187}body.admin-color-modern{--wp-admin-theme-color:#3858e9;--wp-admin-theme-color-darker-10:#2145e6;--wp-admin-theme-color-darker-20:#183ad6}body.admin-color-blue{--wp-admin-theme-color:#096484;--wp-admin-theme-color-darker-10:#07526c;--wp-admin-theme-color-darker-20:#064054}body.admin-color-coffee{--wp-admin-theme-color:#46403c;--wp-admin-theme-color-darker-10:#383330;--wp-admin-theme-color-darker-20:#2b2724}body.admin-color-ectoplasm{--wp-admin-theme-color:#523f6d;--wp-admin-theme-color-darker-10:#46365d;--wp-admin-theme-color-darker-20:#3a2c4d}body.admin-color-midnight{--wp-admin-theme-color:#e14d43;--wp-admin-theme-color-darker-10:#dd382d;--wp-admin-theme-color-darker-20:#d02c21}body.admin-color-ocean{--wp-admin-theme-color:#627c83;--wp-admin-theme-color-darker-10:#576e74;--wp-admin-theme-color-darker-20:#4c6066}body.admin-color-sunrise{--wp-admin-theme-color:#dd823b;--wp-admin-theme-color-darker-10:#d97426;--wp-admin-theme-color-darker-20:#c36922}.woocommerce-orders-table__status{flex-direction:row-reverse}.woocommerce-orders-table__status .woocommerce-order-status__indicator{margin-left:0;margin-right:8px}
|
trunk/dist/chunks/12.style.css
ADDED
@@ -0,0 +1 @@
|
|
|
1 |
+
:root{--wp-admin-theme-color:#007cba;--wp-admin-theme-color-darker-10:#006ba1;--wp-admin-theme-color-darker-20:#005a87}body.admin-color-light{--wp-admin-theme-color:#0085ba;--wp-admin-theme-color-darker-10:#0073a1;--wp-admin-theme-color-darker-20:#006187}body.admin-color-modern{--wp-admin-theme-color:#3858e9;--wp-admin-theme-color-darker-10:#2145e6;--wp-admin-theme-color-darker-20:#183ad6}body.admin-color-blue{--wp-admin-theme-color:#096484;--wp-admin-theme-color-darker-10:#07526c;--wp-admin-theme-color-darker-20:#064054}body.admin-color-coffee{--wp-admin-theme-color:#46403c;--wp-admin-theme-color-darker-10:#383330;--wp-admin-theme-color-darker-20:#2b2724}body.admin-color-ectoplasm{--wp-admin-theme-color:#523f6d;--wp-admin-theme-color-darker-10:#46365d;--wp-admin-theme-color-darker-20:#3a2c4d}body.admin-color-midnight{--wp-admin-theme-color:#e14d43;--wp-admin-theme-color-darker-10:#dd382d;--wp-admin-theme-color-darker-20:#d02c21}body.admin-color-ocean{--wp-admin-theme-color:#627c83;--wp-admin-theme-color-darker-10:#576e74;--wp-admin-theme-color-darker-20:#4c6066}body.admin-color-sunrise{--wp-admin-theme-color:#dd823b;--wp-admin-theme-color-darker-10:#d97426;--wp-admin-theme-color-darker-20:#c36922}.woocommerce-table__product-categories>.woocommerce-table__breadcrumbs{display:inline-block;margin-right:12px}.woocommerce-table__product-categories .components-popover__content{padding:0 16px;text-align:left}.woocommerce-table__product-categories .components-popover__content .woocommerce-table__breadcrumbs{margin-top:12px;margin-bottom:12px}
|
trunk/dist/chunks/12.style.rtl.css
ADDED
@@ -0,0 +1 @@
|
|
|
1 |
+
:root{--wp-admin-theme-color:#007cba;--wp-admin-theme-color-darker-10:#006ba1;--wp-admin-theme-color-darker-20:#005a87}body.admin-color-light{--wp-admin-theme-color:#0085ba;--wp-admin-theme-color-darker-10:#0073a1;--wp-admin-theme-color-darker-20:#006187}body.admin-color-modern{--wp-admin-theme-color:#3858e9;--wp-admin-theme-color-darker-10:#2145e6;--wp-admin-theme-color-darker-20:#183ad6}body.admin-color-blue{--wp-admin-theme-color:#096484;--wp-admin-theme-color-darker-10:#07526c;--wp-admin-theme-color-darker-20:#064054}body.admin-color-coffee{--wp-admin-theme-color:#46403c;--wp-admin-theme-color-darker-10:#383330;--wp-admin-theme-color-darker-20:#2b2724}body.admin-color-ectoplasm{--wp-admin-theme-color:#523f6d;--wp-admin-theme-color-darker-10:#46365d;--wp-admin-theme-color-darker-20:#3a2c4d}body.admin-color-midnight{--wp-admin-theme-color:#e14d43;--wp-admin-theme-color-darker-10:#dd382d;--wp-admin-theme-color-darker-20:#d02c21}body.admin-color-ocean{--wp-admin-theme-color:#627c83;--wp-admin-theme-color-darker-10:#576e74;--wp-admin-theme-color-darker-20:#4c6066}body.admin-color-sunrise{--wp-admin-theme-color:#dd823b;--wp-admin-theme-color-darker-10:#d97426;--wp-admin-theme-color-darker-20:#c36922}.woocommerce-table__product-categories>.woocommerce-table__breadcrumbs{display:inline-block;margin-left:12px}.woocommerce-table__product-categories .components-popover__content{padding:0 16px;text-align:right}.woocommerce-table__product-categories .components-popover__content .woocommerce-table__breadcrumbs{margin-top:12px;margin-bottom:12px}
|
trunk/dist/chunks/13.style.css
ADDED
@@ -0,0 +1 @@
|
|
|
1 |
+
:root{--wp-admin-theme-color:#007cba;--wp-admin-theme-color-darker-10:#006ba1;--wp-admin-theme-color-darker-20:#005a87}body.admin-color-light{--wp-admin-theme-color:#0085ba;--wp-admin-theme-color-darker-10:#0073a1;--wp-admin-theme-color-darker-20:#006187}body.admin-color-modern{--wp-admin-theme-color:#3858e9;--wp-admin-theme-color-darker-10:#2145e6;--wp-admin-theme-color-darker-20:#183ad6}body.admin-color-blue{--wp-admin-theme-color:#096484;--wp-admin-theme-color-darker-10:#07526c;--wp-admin-theme-color-darker-20:#064054}body.admin-color-coffee{--wp-admin-theme-color:#46403c;--wp-admin-theme-color-darker-10:#383330;--wp-admin-theme-color-darker-20:#2b2724}body.admin-color-ectoplasm{--wp-admin-theme-color:#523f6d;--wp-admin-theme-color-darker-10:#46365d;--wp-admin-theme-color-darker-20:#3a2c4d}body.admin-color-midnight{--wp-admin-theme-color:#e14d43;--wp-admin-theme-color-darker-10:#dd382d;--wp-admin-theme-color-darker-20:#d02c21}body.admin-color-ocean{--wp-admin-theme-color:#627c83;--wp-admin-theme-color-darker-10:#576e74;--wp-admin-theme-color-darker-20:#4c6066}body.admin-color-sunrise{--wp-admin-theme-color:#dd823b;--wp-admin-theme-color-darker-10:#d97426;--wp-admin-theme-color-darker-20:#c36922}.woocommerce-report-table__scroll-point{position:relative;top:-48px}@media(max-width:782px){.woocommerce-report-table__scroll-point{top:-62px}}.woocommerce-feature-enabled-activity-panels .woocommerce-report-table__scroll-point{top:-108px}@media(max-width:782px){.woocommerce-feature-enabled-activity-panels .woocommerce-report-table__scroll-point{top:-122px}}.woocommerce-report-table .woocommerce-search{flex-grow:1}.woocommerce-report-table .components-card__header{display:grid;grid-gap:12px;grid-template-columns:min-content 1fr min-content}.woocommerce-report-table .woocommerce-table__compare.components-button{padding:8px}.woocommerce-report-table .woocommerce-ellipsis-menu{justify-self:flex-end}button.woocommerce-table__download-button{padding:6px 12px;color:#000;text-decoration:none;align-items:center}button.woocommerce-table__download-button svg{margin-right:8px;height:24px;width:24px}@media(max-width:782px){button.woocommerce-table__download-button svg{margin-right:0}button.woocommerce-table__download-button .woocommerce-table__download-button__label{display:none}}
|
trunk/dist/chunks/14.style.css
ADDED
@@ -0,0 +1 @@
|
|
|
1 |
+
:root{--wp-admin-theme-color:#007cba;--wp-admin-theme-color-darker-10:#006ba1;--wp-admin-theme-color-darker-20:#005a87}body.admin-color-light{--wp-admin-theme-color:#0085ba;--wp-admin-theme-color-darker-10:#0073a1;--wp-admin-theme-color-darker-20:#006187}body.admin-color-modern{--wp-admin-theme-color:#3858e9;--wp-admin-theme-color-darker-10:#2145e6;--wp-admin-theme-color-darker-20:#183ad6}body.admin-color-blue{--wp-admin-theme-color:#096484;--wp-admin-theme-color-darker-10:#07526c;--wp-admin-theme-color-darker-20:#064054}body.admin-color-coffee{--wp-admin-theme-color:#46403c;--wp-admin-theme-color-darker-10:#383330;--wp-admin-theme-color-darker-20:#2b2724}body.admin-color-ectoplasm{--wp-admin-theme-color:#523f6d;--wp-admin-theme-color-darker-10:#46365d;--wp-admin-theme-color-darker-20:#3a2c4d}body.admin-color-midnight{--wp-admin-theme-color:#e14d43;--wp-admin-theme-color-darker-10:#dd382d;--wp-admin-theme-color-darker-20:#d02c21}body.admin-color-ocean{--wp-admin-theme-color:#627c83;--wp-admin-theme-color-darker-10:#576e74;--wp-admin-theme-color-darker-20:#4c6066}body.admin-color-sunrise{--wp-admin-theme-color:#dd823b;--wp-admin-theme-color-darker-10:#d97426;--wp-admin-theme-color-darker-20:#c36922}.woocommerce-report-table__scroll-point{position:relative;top:-48px}@media(max-width:782px){.woocommerce-report-table__scroll-point{top:-62px}}.woocommerce-feature-enabled-activity-panels .woocommerce-report-table__scroll-point{top:-108px}@media(max-width:782px){.woocommerce-feature-enabled-activity-panels .woocommerce-report-table__scroll-point{top:-122px}}.woocommerce-report-table .woocommerce-search{flex-grow:1}.woocommerce-report-table .components-card__header{display:grid;grid-gap:12px;grid-template-columns:min-content 1fr min-content}.woocommerce-report-table .woocommerce-table__compare.components-button{padding:8px}.woocommerce-report-table .woocommerce-ellipsis-menu{justify-self:flex-end}button.woocommerce-table__download-button{padding:6px 12px;color:#000;text-decoration:none;align-items:center}button.woocommerce-table__download-button svg{margin-right:8px;height:24px;width:24px}@media(max-width:782px){button.woocommerce-table__download-button svg{margin-right:0}button.woocommerce-table__download-button .woocommerce-table__download-button__label{display:none}}
|
trunk/dist/chunks/14.style.rtl.css
ADDED
@@ -0,0 +1 @@
|
|
|
1 |
+
:root{--wp-admin-theme-color:#007cba;--wp-admin-theme-color-darker-10:#006ba1;--wp-admin-theme-color-darker-20:#005a87}body.admin-color-light{--wp-admin-theme-color:#0085ba;--wp-admin-theme-color-darker-10:#0073a1;--wp-admin-theme-color-darker-20:#006187}body.admin-color-modern{--wp-admin-theme-color:#3858e9;--wp-admin-theme-color-darker-10:#2145e6;--wp-admin-theme-color-darker-20:#183ad6}body.admin-color-blue{--wp-admin-theme-color:#096484;--wp-admin-theme-color-darker-10:#07526c;--wp-admin-theme-color-darker-20:#064054}body.admin-color-coffee{--wp-admin-theme-color:#46403c;--wp-admin-theme-color-darker-10:#383330;--wp-admin-theme-color-darker-20:#2b2724}body.admin-color-ectoplasm{--wp-admin-theme-color:#523f6d;--wp-admin-theme-color-darker-10:#46365d;--wp-admin-theme-color-darker-20:#3a2c4d}body.admin-color-midnight{--wp-admin-theme-color:#e14d43;--wp-admin-theme-color-darker-10:#dd382d;--wp-admin-theme-color-darker-20:#d02c21}body.admin-color-ocean{--wp-admin-theme-color:#627c83;--wp-admin-theme-color-darker-10:#576e74;--wp-admin-theme-color-darker-20:#4c6066}body.admin-color-sunrise{--wp-admin-theme-color:#dd823b;--wp-admin-theme-color-darker-10:#d97426;--wp-admin-theme-color-darker-20:#c36922}.woocommerce-report-table__scroll-point{position:relative;top:-48px}@media(max-width:782px){.woocommerce-report-table__scroll-point{top:-62px}}.woocommerce-feature-enabled-activity-panels .woocommerce-report-table__scroll-point{top:-108px}@media(max-width:782px){.woocommerce-feature-enabled-activity-panels .woocommerce-report-table__scroll-point{top:-122px}}.woocommerce-report-table .woocommerce-search{flex-grow:1}.woocommerce-report-table .components-card__header{display:grid;grid-gap:12px;grid-template-columns:min-content 1fr min-content}.woocommerce-report-table .woocommerce-table__compare.components-button{padding:8px}.woocommerce-report-table .woocommerce-ellipsis-menu{justify-self:flex-end}button.woocommerce-table__download-button{padding:6px 12px;color:#000;text-decoration:none;align-items:center}button.woocommerce-table__download-button svg{margin-left:8px;height:24px;width:24px}@media(max-width:782px){button.woocommerce-table__download-button svg{margin-left:0}button.woocommerce-table__download-button .woocommerce-table__download-button__label{display:none}}
|
trunk/dist/chunks/15.style.css
ADDED
@@ -0,0 +1 @@
|
|
|
1 |
+
:root{--wp-admin-theme-color:#007cba;--wp-admin-theme-color-darker-10:#006ba1;--wp-admin-theme-color-darker-20:#005a87}body.admin-color-light{--wp-admin-theme-color:#0085ba;--wp-admin-theme-color-darker-10:#0073a1;--wp-admin-theme-color-darker-20:#006187}body.admin-color-modern{--wp-admin-theme-color:#3858e9;--wp-admin-theme-color-darker-10:#2145e6;--wp-admin-theme-color-darker-20:#183ad6}body.admin-color-blue{--wp-admin-theme-color:#096484;--wp-admin-theme-color-darker-10:#07526c;--wp-admin-theme-color-darker-20:#064054}body.admin-color-coffee{--wp-admin-theme-color:#46403c;--wp-admin-theme-color-darker-10:#383330;--wp-admin-theme-color-darker-20:#2b2724}body.admin-color-ectoplasm{--wp-admin-theme-color:#523f6d;--wp-admin-theme-color-darker-10:#46365d;--wp-admin-theme-color-darker-20:#3a2c4d}body.admin-color-midnight{--wp-admin-theme-color:#e14d43;--wp-admin-theme-color-darker-10:#dd382d;--wp-admin-theme-color-darker-20:#d02c21}body.admin-color-ocean{--wp-admin-theme-color:#627c83;--wp-admin-theme-color-darker-10:#576e74;--wp-admin-theme-color-darker-20:#4c6066}body.admin-color-sunrise{--wp-admin-theme-color:#dd823b;--wp-admin-theme-color-darker-10:#d97426;--wp-admin-theme-color-darker-20:#c36922}.woocommerce-table__product-categories>.woocommerce-table__breadcrumbs{display:inline-block;margin-right:12px}.woocommerce-table__product-categories .components-popover__content{padding:0 16px;text-align:left}.woocommerce-table__product-categories .components-popover__content .woocommerce-table__breadcrumbs{margin-top:12px;margin-bottom:12px}
|
trunk/dist/chunks/15.style.rtl.css
ADDED
@@ -0,0 +1 @@
|
|
|
1 |
+
:root{--wp-admin-theme-color:#007cba;--wp-admin-theme-color-darker-10:#006ba1;--wp-admin-theme-color-darker-20:#005a87}body.admin-color-light{--wp-admin-theme-color:#0085ba;--wp-admin-theme-color-darker-10:#0073a1;--wp-admin-theme-color-darker-20:#006187}body.admin-color-modern{--wp-admin-theme-color:#3858e9;--wp-admin-theme-color-darker-10:#2145e6;--wp-admin-theme-color-darker-20:#183ad6}body.admin-color-blue{--wp-admin-theme-color:#096484;--wp-admin-theme-color-darker-10:#07526c;--wp-admin-theme-color-darker-20:#064054}body.admin-color-coffee{--wp-admin-theme-color:#46403c;--wp-admin-theme-color-darker-10:#383330;--wp-admin-theme-color-darker-20:#2b2724}body.admin-color-ectoplasm{--wp-admin-theme-color:#523f6d;--wp-admin-theme-color-darker-10:#46365d;--wp-admin-theme-color-darker-20:#3a2c4d}body.admin-color-midnight{--wp-admin-theme-color:#e14d43;--wp-admin-theme-color-darker-10:#dd382d;--wp-admin-theme-color-darker-20:#d02c21}body.admin-color-ocean{--wp-admin-theme-color:#627c83;--wp-admin-theme-color-darker-10:#576e74;--wp-admin-theme-color-darker-20:#4c6066}body.admin-color-sunrise{--wp-admin-theme-color:#dd823b;--wp-admin-theme-color-darker-10:#d97426;--wp-admin-theme-color-darker-20:#c36922}.woocommerce-table__product-categories>.woocommerce-table__breadcrumbs{display:inline-block;margin-left:12px}.woocommerce-table__product-categories .components-popover__content{padding:0 16px;text-align:right}.woocommerce-table__product-categories .components-popover__content .woocommerce-table__breadcrumbs{margin-top:12px;margin-bottom:12px}
|
trunk/dist/chunks/16.style.css
ADDED
@@ -0,0 +1 @@
|
|
|
1 |
+
@media(min-width:783px){.woocommerce-settings__wrapper{padding:0 13px}}.woocommerce-settings__actions{margin-bottom:40px}@media(min-width:1281px){.woocommerce-settings__actions{margin-left:15%}}.woocommerce-settings__actions button{margin-right:16px}.woocommerce-setting{display:flex;margin-bottom:24px}@media(max-width:1280px){.woocommerce-setting{flex-direction:column}}.woocommerce-setting__label{font-size:16px;font-size:1rem;margin-bottom:16px;padding-right:16px;font-weight:700}@media(min-width:1281px){.woocommerce-setting__label{width:15%}}.woocommerce-setting__input{display:flex;flex-direction:column}@media(min-width:1281px){.woocommerce-setting__input{width:35%}.woocommerce-setting__input .woocommerce-filters-filter{width:100%}}.woocommerce-setting__input label{width:100%;display:block;margin-bottom:12px;color:#757575}.woocommerce-setting__input .woocommerce-filters-filter label{margin-bottom:0}.woocommerce-setting__input button:not(.components-tab-panel__tabs-item){margin-bottom:12px;align-self:flex-start}.woocommerce-setting__input .components-base-control__field{display:flex}.woocommerce-setting__input .woocommerce-filters-date__content-controls{padding-bottom:0}.woocommerce-setting__options-group-label{display:block;font-weight:700;margin-bottom:12px}.woocommerce-setting__help{font-style:italic;color:#757575}:root{--wp-admin-theme-color:#007cba;--wp-admin-theme-color-darker-10:#006ba1;--wp-admin-theme-color-darker-20:#005a87}body.admin-color-light{--wp-admin-theme-color:#0085ba;--wp-admin-theme-color-darker-10:#0073a1;--wp-admin-theme-color-darker-20:#006187}body.admin-color-modern{--wp-admin-theme-color:#3858e9;--wp-admin-theme-color-darker-10:#2145e6;--wp-admin-theme-color-darker-20:#183ad6}body.admin-color-blue{--wp-admin-theme-color:#096484;--wp-admin-theme-color-darker-10:#07526c;--wp-admin-theme-color-darker-20:#064054}body.admin-color-coffee{--wp-admin-theme-color:#46403c;--wp-admin-theme-color-darker-10:#383330;--wp-admin-theme-color-darker-20:#2b2724}body.admin-color-ectoplasm{--wp-admin-theme-color:#523f6d;--wp-admin-theme-color-darker-10:#46365d;--wp-admin-theme-color-darker-20:#3a2c4d}body.admin-color-midnight{--wp-admin-theme-color:#e14d43;--wp-admin-theme-color-darker-10:#dd382d;--wp-admin-theme-color-darker-20:#d02c21}body.admin-color-ocean{--wp-admin-theme-color:#627c83;--wp-admin-theme-color-darker-10:#576e74;--wp-admin-theme-color-darker-20:#4c6066}body.admin-color-sunrise{--wp-admin-theme-color:#dd823b;--wp-admin-theme-color-darker-10:#d97426;--wp-admin-theme-color-darker-20:#c36922}.woocommerce-settings-historical-data__columns{display:grid;grid-column-gap:24px;grid-template-columns:calc(50% - 12px) calc(50% - 12px)}.woocommerce-settings-historical-data__columns .woocommerce-settings-historical-data__column{align-self:end;margin-top:12px}.woocommerce-settings-historical-data__columns .woocommerce-settings-historical-data__column:first-child{grid-column-start:1;grid-column-end:2;grid-row-start:1;grid-row-end:2}.woocommerce-settings-historical-data__columns .woocommerce-settings-historical-data__column:nth-child(2){grid-column-start:2;grid-column-end:3;grid-row-start:1;grid-row-end:2}@media(max-width:960px){.woocommerce-settings-historical-data__columns{grid-template-columns:100%}.woocommerce-settings-historical-data__columns .woocommerce-settings-historical-data__column:first-child{grid-column-start:1;grid-column-end:2;grid-row-start:1;grid-row-end:2}.woocommerce-settings-historical-data__columns .woocommerce-settings-historical-data__column:nth-child(2){grid-column-start:1;grid-column-end:2;grid-row-start:2;grid-row-end:3}}.woocommerce-settings-historical-data__columns .components-base-control__label,.woocommerce-settings-historical-data__columns .woocommerce-settings-historical-data__column-label{margin-bottom:12px}.woocommerce-settings-historical-data__columns .components-select-control__input{height:38px;padding:8px 2px}.woocommerce-settings-historical-data__columns .components-base-control__field{margin-bottom:0}.woocommerce-settings-historical-data__skip-checkbox{margin-top:24px}.woocommerce-settings-historical-data__skip-checkbox>.components-base-control__field{margin-bottom:0}.woocommerce-settings-historical-data__skip-checkbox>.components-base-control__field>.components-checkbox-control__label{display:inline-block;margin-bottom:0;width:auto}.woocommerce-settings-historical-data__progress-label{display:inline-block;font-weight:700;margin-bottom:12px;margin-top:24px}.woocommerce-settings-historical-data__progress-label+.woocommerce-settings-historical-data__progress-label{margin-left:.25em}.woocommerce-settings-historical-data__progress-bar{-webkit-appearance:none;appearance:none;border:0;height:8px;width:100%;background-color:#c4c4c4}.woocommerce-settings-historical-data__progress-bar::-moz-progress-bar{background-color:#0085ba}.woocommerce-settings-historical-data__progress-bar::-webkit-progress-bar{background-color:#c4c4c4}.woocommerce-settings-historical-data__progress-bar::-webkit-progress-value{background-color:#0085ba}.woocommerce-settings-historical-data__status{display:block;font-weight:700;margin-top:24px}.woocommerce-settings-historical-data__status>.components-spinner{float:none;height:12px;margin-left:6px;margin-right:6px;width:12px}.woocommerce-settings-historical-data__status>.components-spinner:before{left:2px;height:3px;top:2px;transform-origin:4px 4px;width:3px}.woocommerce-settings-historical-data__actions{align-items:center;display:flex}
|
trunk/dist/chunks/17.style.css
ADDED
@@ -0,0 +1 @@
|
|
|
1 |
+
@media(min-width:783px){.woocommerce-settings__wrapper{padding:0 13px}}.woocommerce-settings__actions{margin-bottom:40px}@media(min-width:1281px){.woocommerce-settings__actions{margin-left:15%}}.woocommerce-settings__actions button{margin-right:16px}.woocommerce-setting{display:flex;margin-bottom:24px}@media(max-width:1280px){.woocommerce-setting{flex-direction:column}}.woocommerce-setting__label{font-size:16px;font-size:1rem;margin-bottom:16px;padding-right:16px;font-weight:700}@media(min-width:1281px){.woocommerce-setting__label{width:15%}}.woocommerce-setting__input{display:flex;flex-direction:column}@media(min-width:1281px){.woocommerce-setting__input{width:35%}.woocommerce-setting__input .woocommerce-filters-filter{width:100%}}.woocommerce-setting__input label{width:100%;display:block;margin-bottom:12px;color:#757575}.woocommerce-setting__input .woocommerce-filters-filter label{margin-bottom:0}.woocommerce-setting__input button:not(.components-tab-panel__tabs-item){margin-bottom:12px;align-self:flex-start}.woocommerce-setting__input .components-base-control__field{display:flex}.woocommerce-setting__input .woocommerce-filters-date__content-controls{padding-bottom:0}.woocommerce-setting__options-group-label{display:block;font-weight:700;margin-bottom:12px}.woocommerce-setting__help{font-style:italic;color:#757575}:root{--wp-admin-theme-color:#007cba;--wp-admin-theme-color-darker-10:#006ba1;--wp-admin-theme-color-darker-20:#005a87}body.admin-color-light{--wp-admin-theme-color:#0085ba;--wp-admin-theme-color-darker-10:#0073a1;--wp-admin-theme-color-darker-20:#006187}body.admin-color-modern{--wp-admin-theme-color:#3858e9;--wp-admin-theme-color-darker-10:#2145e6;--wp-admin-theme-color-darker-20:#183ad6}body.admin-color-blue{--wp-admin-theme-color:#096484;--wp-admin-theme-color-darker-10:#07526c;--wp-admin-theme-color-darker-20:#064054}body.admin-color-coffee{--wp-admin-theme-color:#46403c;--wp-admin-theme-color-darker-10:#383330;--wp-admin-theme-color-darker-20:#2b2724}body.admin-color-ectoplasm{--wp-admin-theme-color:#523f6d;--wp-admin-theme-color-darker-10:#46365d;--wp-admin-theme-color-darker-20:#3a2c4d}body.admin-color-midnight{--wp-admin-theme-color:#e14d43;--wp-admin-theme-color-darker-10:#dd382d;--wp-admin-theme-color-darker-20:#d02c21}body.admin-color-ocean{--wp-admin-theme-color:#627c83;--wp-admin-theme-color-darker-10:#576e74;--wp-admin-theme-color-darker-20:#4c6066}body.admin-color-sunrise{--wp-admin-theme-color:#dd823b;--wp-admin-theme-color-darker-10:#d97426;--wp-admin-theme-color-darker-20:#c36922}.woocommerce-settings-historical-data__columns{display:grid;grid-column-gap:24px;grid-template-columns:calc(50% - 12px) calc(50% - 12px)}.woocommerce-settings-historical-data__columns .woocommerce-settings-historical-data__column{align-self:end;margin-top:12px}.woocommerce-settings-historical-data__columns .woocommerce-settings-historical-data__column:first-child{grid-column-start:1;grid-column-end:2;grid-row-start:1;grid-row-end:2}.woocommerce-settings-historical-data__columns .woocommerce-settings-historical-data__column:nth-child(2){grid-column-start:2;grid-column-end:3;grid-row-start:1;grid-row-end:2}@media(max-width:960px){.woocommerce-settings-historical-data__columns{grid-template-columns:100%}.woocommerce-settings-historical-data__columns .woocommerce-settings-historical-data__column:first-child{grid-column-start:1;grid-column-end:2;grid-row-start:1;grid-row-end:2}.woocommerce-settings-historical-data__columns .woocommerce-settings-historical-data__column:nth-child(2){grid-column-start:1;grid-column-end:2;grid-row-start:2;grid-row-end:3}}.woocommerce-settings-historical-data__columns .components-base-control__label,.woocommerce-settings-historical-data__columns .woocommerce-settings-historical-data__column-label{margin-bottom:12px}.woocommerce-settings-historical-data__columns .components-select-control__input{height:38px;padding:8px 2px}.woocommerce-settings-historical-data__columns .components-base-control__field{margin-bottom:0}.woocommerce-settings-historical-data__skip-checkbox{margin-top:24px}.woocommerce-settings-historical-data__skip-checkbox>.components-base-control__field{margin-bottom:0}.woocommerce-settings-historical-data__skip-checkbox>.components-base-control__field>.components-checkbox-control__label{display:inline-block;margin-bottom:0;width:auto}.woocommerce-settings-historical-data__progress-label{display:inline-block;font-weight:700;margin-bottom:12px;margin-top:24px}.woocommerce-settings-historical-data__progress-label+.woocommerce-settings-historical-data__progress-label{margin-left:.25em}.woocommerce-settings-historical-data__progress-bar{-webkit-appearance:none;appearance:none;border:0;height:8px;width:100%;background-color:#c4c4c4}.woocommerce-settings-historical-data__progress-bar::-moz-progress-bar{background-color:#0085ba}.woocommerce-settings-historical-data__progress-bar::-webkit-progress-bar{background-color:#c4c4c4}.woocommerce-settings-historical-data__progress-bar::-webkit-progress-value{background-color:#0085ba}.woocommerce-settings-historical-data__status{display:block;font-weight:700;margin-top:24px}.woocommerce-settings-historical-data__status>.components-spinner{float:none;height:12px;margin-left:6px;margin-right:6px;width:12px}.woocommerce-settings-historical-data__status>.components-spinner:before{left:2px;height:3px;top:2px;transform-origin:4px 4px;width:3px}.woocommerce-settings-historical-data__actions{align-items:center;display:flex}
|
trunk/dist/chunks/17.style.rtl.css
ADDED
@@ -0,0 +1 @@
|
|
|
1 |
+
@media(min-width:783px){.woocommerce-settings__wrapper{padding:0 13px}}.woocommerce-settings__actions{margin-bottom:40px}@media(min-width:1281px){.woocommerce-settings__actions{margin-right:15%}}.woocommerce-settings__actions button{margin-left:16px}.woocommerce-setting{display:flex;margin-bottom:24px}@media(max-width:1280px){.woocommerce-setting{flex-direction:column}}.woocommerce-setting__label{font-size:16px;font-size:1rem;margin-bottom:16px;padding-left:16px;font-weight:700}@media(min-width:1281px){.woocommerce-setting__label{width:15%}}.woocommerce-setting__input{display:flex;flex-direction:column}@media(min-width:1281px){.woocommerce-setting__input{width:35%}.woocommerce-setting__input .woocommerce-filters-filter{width:100%}}.woocommerce-setting__input label{width:100%;display:block;margin-bottom:12px;color:#757575}.woocommerce-setting__input .woocommerce-filters-filter label{margin-bottom:0}.woocommerce-setting__input button:not(.components-tab-panel__tabs-item){margin-bottom:12px;align-self:flex-start}.woocommerce-setting__input .components-base-control__field{display:flex}.woocommerce-setting__input .woocommerce-filters-date__content-controls{padding-bottom:0}.woocommerce-setting__options-group-label{display:block;font-weight:700;margin-bottom:12px}.woocommerce-setting__help{font-style:italic;color:#757575}:root{--wp-admin-theme-color:#007cba;--wp-admin-theme-color-darker-10:#006ba1;--wp-admin-theme-color-darker-20:#005a87}body.admin-color-light{--wp-admin-theme-color:#0085ba;--wp-admin-theme-color-darker-10:#0073a1;--wp-admin-theme-color-darker-20:#006187}body.admin-color-modern{--wp-admin-theme-color:#3858e9;--wp-admin-theme-color-darker-10:#2145e6;--wp-admin-theme-color-darker-20:#183ad6}body.admin-color-blue{--wp-admin-theme-color:#096484;--wp-admin-theme-color-darker-10:#07526c;--wp-admin-theme-color-darker-20:#064054}body.admin-color-coffee{--wp-admin-theme-color:#46403c;--wp-admin-theme-color-darker-10:#383330;--wp-admin-theme-color-darker-20:#2b2724}body.admin-color-ectoplasm{--wp-admin-theme-color:#523f6d;--wp-admin-theme-color-darker-10:#46365d;--wp-admin-theme-color-darker-20:#3a2c4d}body.admin-color-midnight{--wp-admin-theme-color:#e14d43;--wp-admin-theme-color-darker-10:#dd382d;--wp-admin-theme-color-darker-20:#d02c21}body.admin-color-ocean{--wp-admin-theme-color:#627c83;--wp-admin-theme-color-darker-10:#576e74;--wp-admin-theme-color-darker-20:#4c6066}body.admin-color-sunrise{--wp-admin-theme-color:#dd823b;--wp-admin-theme-color-darker-10:#d97426;--wp-admin-theme-color-darker-20:#c36922}.woocommerce-settings-historical-data__columns{display:grid;grid-column-gap:24px;grid-template-columns:calc(50% - 12px) calc(50% - 12px)}.woocommerce-settings-historical-data__columns .woocommerce-settings-historical-data__column{align-self:end;margin-top:12px}.woocommerce-settings-historical-data__columns .woocommerce-settings-historical-data__column:first-child{grid-column-start:1;grid-column-end:2;grid-row-start:1;grid-row-end:2}.woocommerce-settings-historical-data__columns .woocommerce-settings-historical-data__column:nth-child(2){grid-column-start:2;grid-column-end:3;grid-row-start:1;grid-row-end:2}@media(max-width:960px){.woocommerce-settings-historical-data__columns{grid-template-columns:100%}.woocommerce-settings-historical-data__columns .woocommerce-settings-historical-data__column:first-child{grid-column-start:1;grid-column-end:2;grid-row-start:1;grid-row-end:2}.woocommerce-settings-historical-data__columns .woocommerce-settings-historical-data__column:nth-child(2){grid-column-start:1;grid-column-end:2;grid-row-start:2;grid-row-end:3}}.woocommerce-settings-historical-data__columns .components-base-control__label,.woocommerce-settings-historical-data__columns .woocommerce-settings-historical-data__column-label{margin-bottom:12px}.woocommerce-settings-historical-data__columns .components-select-control__input{height:38px;padding:8px 2px}.woocommerce-settings-historical-data__columns .components-base-control__field{margin-bottom:0}.woocommerce-settings-historical-data__skip-checkbox{margin-top:24px}.woocommerce-settings-historical-data__skip-checkbox>.components-base-control__field{margin-bottom:0}.woocommerce-settings-historical-data__skip-checkbox>.components-base-control__field>.components-checkbox-control__label{display:inline-block;margin-bottom:0;width:auto}.woocommerce-settings-historical-data__progress-label{display:inline-block;font-weight:700;margin-bottom:12px;margin-top:24px}.woocommerce-settings-historical-data__progress-label+.woocommerce-settings-historical-data__progress-label{margin-right:.25em}.woocommerce-settings-historical-data__progress-bar{-webkit-appearance:none;appearance:none;border:0;height:8px;width:100%;background-color:#c4c4c4}.woocommerce-settings-historical-data__progress-bar::-moz-progress-bar{background-color:#0085ba}.woocommerce-settings-historical-data__progress-bar::-webkit-progress-bar{background-color:#c4c4c4}.woocommerce-settings-historical-data__progress-bar::-webkit-progress-value{background-color:#0085ba}.woocommerce-settings-historical-data__status{display:block;font-weight:700;margin-top:24px}.woocommerce-settings-historical-data__status>.components-spinner{float:none;height:12px;margin-right:6px;margin-left:6px;width:12px}.woocommerce-settings-historical-data__status>.components-spinner:before{right:2px;height:3px;top:2px;transform-origin:4px 4px;width:3px}.woocommerce-settings-historical-data__actions{align-items:center;display:flex}
|
trunk/dist/chunks/2.js
ADDED
@@ -0,0 +1,1143 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
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|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
(window["__wcAdmin_webpackJsonp"] = window["__wcAdmin_webpackJsonp"] || []).push([[2],{
|
2 |
+
|
3 |
+
/***/ 169:
|
4 |
+
/***/ (function(module, __webpack_exports__, __webpack_require__) {
|
5 |
+
|
6 |
+
"use strict";
|
7 |
+
|
8 |
+
// EXTERNAL MODULE: ./node_modules/@babel/runtime/helpers/esm/extends.js
|
9 |
+
var esm_extends = __webpack_require__(23);
|
10 |
+
|
11 |
+
// EXTERNAL MODULE: ./node_modules/@babel/runtime/helpers/esm/objectWithoutPropertiesLoose.js
|
12 |
+
var objectWithoutPropertiesLoose = __webpack_require__(22);
|
13 |
+
|
14 |
+
// EXTERNAL MODULE: ./node_modules/@babel/runtime/helpers/esm/inheritsLoose.js + 1 modules
|
15 |
+
var inheritsLoose = __webpack_require__(25);
|
16 |
+
|
17 |
+
// EXTERNAL MODULE: ./node_modules/prop-types/index.js
|
18 |
+
var prop_types = __webpack_require__(1);
|
19 |
+
|
20 |
+
// CONCATENATED MODULE: ./node_modules/dom-helpers/esm/hasClass.js
|
21 |
+
/**
|
22 |
+
* Checks if a given element has a CSS class.
|
23 |
+
*
|
24 |
+
* @param element the element
|
25 |
+
* @param className the CSS class name
|
26 |
+
*/
|
27 |
+
function hasClass(element, className) {
|
28 |
+
if (element.classList) return !!className && element.classList.contains(className);
|
29 |
+
return (" " + (element.className.baseVal || element.className) + " ").indexOf(" " + className + " ") !== -1;
|
30 |
+
}
|
31 |
+
// CONCATENATED MODULE: ./node_modules/dom-helpers/esm/addClass.js
|
32 |
+
|
33 |
+
/**
|
34 |
+
* Adds a CSS class to a given element.
|
35 |
+
*
|
36 |
+
* @param element the element
|
37 |
+
* @param className the CSS class name
|
38 |
+
*/
|
39 |
+
|
40 |
+
function addClass_addClass(element, className) {
|
41 |
+
if (element.classList) element.classList.add(className);else if (!hasClass(element, className)) if (typeof element.className === 'string') element.className = element.className + " " + className;else element.setAttribute('class', (element.className && element.className.baseVal || '') + " " + className);
|
42 |
+
}
|
43 |
+
// CONCATENATED MODULE: ./node_modules/dom-helpers/esm/removeClass.js
|
44 |
+
function replaceClassName(origClass, classToRemove) {
|
45 |
+
return origClass.replace(new RegExp("(^|\\s)" + classToRemove + "(?:\\s|$)", 'g'), '$1').replace(/\s+/g, ' ').replace(/^\s*|\s*$/g, '');
|
46 |
+
}
|
47 |
+
/**
|
48 |
+
* Removes a CSS class from a given element.
|
49 |
+
*
|
50 |
+
* @param element the element
|
51 |
+
* @param className the CSS class name
|
52 |
+
*/
|
53 |
+
|
54 |
+
|
55 |
+
function removeClass_removeClass(element, className) {
|
56 |
+
if (element.classList) {
|
57 |
+
element.classList.remove(className);
|
58 |
+
} else if (typeof element.className === 'string') {
|
59 |
+
element.className = replaceClassName(element.className, className);
|
60 |
+
} else {
|
61 |
+
element.setAttribute('class', replaceClassName(element.className && element.className.baseVal || '', className));
|
62 |
+
}
|
63 |
+
}
|
64 |
+
// EXTERNAL MODULE: external "React"
|
65 |
+
var external_React_ = __webpack_require__(5);
|
66 |
+
var external_React_default = /*#__PURE__*/__webpack_require__.n(external_React_);
|
67 |
+
|
68 |
+
// EXTERNAL MODULE: ./node_modules/react-transition-group/esm/Transition.js + 1 modules
|
69 |
+
var Transition = __webpack_require__(67);
|
70 |
+
|
71 |
+
// CONCATENATED MODULE: ./node_modules/react-transition-group/esm/CSSTransition.js
|
72 |
+
|
73 |
+
|
74 |
+
|
75 |
+
|
76 |
+
|
77 |
+
|
78 |
+
|
79 |
+
|
80 |
+
|
81 |
+
|
82 |
+
var _addClass = function addClass(node, classes) {
|
83 |
+
return node && classes && classes.split(' ').forEach(function (c) {
|
84 |
+
return addClass_addClass(node, c);
|
85 |
+
});
|
86 |
+
};
|
87 |
+
|
88 |
+
var CSSTransition_removeClass = function removeClass(node, classes) {
|
89 |
+
return node && classes && classes.split(' ').forEach(function (c) {
|
90 |
+
return removeClass_removeClass(node, c);
|
91 |
+
});
|
92 |
+
};
|
93 |
+
/**
|
94 |
+
* A transition component inspired by the excellent
|
95 |
+
* [ng-animate](https://docs.angularjs.org/api/ngAnimate) library, you should
|
96 |
+
* use it if you're using CSS transitions or animations. It's built upon the
|
97 |
+
* [`Transition`](https://reactcommunity.org/react-transition-group/transition)
|
98 |
+
* component, so it inherits all of its props.
|
99 |
+
*
|
100 |
+
* `CSSTransition` applies a pair of class names during the `appear`, `enter`,
|
101 |
+
* and `exit` states of the transition. The first class is applied and then a
|
102 |
+
* second `*-active` class in order to activate the CSS transition. After the
|
103 |
+
* transition, matching `*-done` class names are applied to persist the
|
104 |
+
* transition state.
|
105 |
+
*
|
106 |
+
* ```jsx
|
107 |
+
* function App() {
|
108 |
+
* const [inProp, setInProp] = useState(false);
|
109 |
+
* return (
|
110 |
+
* <div>
|
111 |
+
* <CSSTransition in={inProp} timeout={200} classNames="my-node">
|
112 |
+
* <div>
|
113 |
+
* {"I'll receive my-node-* classes"}
|
114 |
+
* </div>
|
115 |
+
* </CSSTransition>
|
116 |
+
* <button type="button" onClick={() => setInProp(true)}>
|
117 |
+
* Click to Enter
|
118 |
+
* </button>
|
119 |
+
* </div>
|
120 |
+
* );
|
121 |
+
* }
|
122 |
+
* ```
|
123 |
+
*
|
124 |
+
* When the `in` prop is set to `true`, the child component will first receive
|
125 |
+
* the class `example-enter`, then the `example-enter-active` will be added in
|
126 |
+
* the next tick. `CSSTransition` [forces a
|
127 |
+
* reflow](https://github.com/reactjs/react-transition-group/blob/5007303e729a74be66a21c3e2205e4916821524b/src/CSSTransition.js#L208-L215)
|
128 |
+
* between before adding the `example-enter-active`. This is an important trick
|
129 |
+
* because it allows us to transition between `example-enter` and
|
130 |
+
* `example-enter-active` even though they were added immediately one after
|
131 |
+
* another. Most notably, this is what makes it possible for us to animate
|
132 |
+
* _appearance_.
|
133 |
+
*
|
134 |
+
* ```css
|
135 |
+
* .my-node-enter {
|
136 |
+
* opacity: 0;
|
137 |
+
* }
|
138 |
+
* .my-node-enter-active {
|
139 |
+
* opacity: 1;
|
140 |
+
* transition: opacity 200ms;
|
141 |
+
* }
|
142 |
+
* .my-node-exit {
|
143 |
+
* opacity: 1;
|
144 |
+
* }
|
145 |
+
* .my-node-exit-active {
|
146 |
+
* opacity: 0;
|
147 |
+
* transition: opacity 200ms;
|
148 |
+
* }
|
149 |
+
* ```
|
150 |
+
*
|
151 |
+
* `*-active` classes represent which styles you want to animate **to**, so it's
|
152 |
+
* important to add `transition` declaration only to them, otherwise transitions
|
153 |
+
* might not behave as intended! This might not be obvious when the transitions
|
154 |
+
* are symmetrical, i.e. when `*-enter-active` is the same as `*-exit`, like in
|
155 |
+
* the example above (minus `transition`), but it becomes apparent in more
|
156 |
+
* complex transitions.
|
157 |
+
*
|
158 |
+
* **Note**: If you're using the
|
159 |
+
* [`appear`](http://reactcommunity.org/react-transition-group/transition#Transition-prop-appear)
|
160 |
+
* prop, make sure to define styles for `.appear-*` classes as well.
|
161 |
+
*/
|
162 |
+
|
163 |
+
|
164 |
+
var CSSTransition_CSSTransition = /*#__PURE__*/function (_React$Component) {
|
165 |
+
Object(inheritsLoose["a" /* default */])(CSSTransition, _React$Component);
|
166 |
+
|
167 |
+
function CSSTransition() {
|
168 |
+
var _this;
|
169 |
+
|
170 |
+
for (var _len = arguments.length, args = new Array(_len), _key = 0; _key < _len; _key++) {
|
171 |
+
args[_key] = arguments[_key];
|
172 |
+
}
|
173 |
+
|
174 |
+
_this = _React$Component.call.apply(_React$Component, [this].concat(args)) || this;
|
175 |
+
_this.appliedClasses = {
|
176 |
+
appear: {},
|
177 |
+
enter: {},
|
178 |
+
exit: {}
|
179 |
+
};
|
180 |
+
|
181 |
+
_this.onEnter = function (maybeNode, maybeAppearing) {
|
182 |
+
var _this$resolveArgument = _this.resolveArguments(maybeNode, maybeAppearing),
|
183 |
+
node = _this$resolveArgument[0],
|
184 |
+
appearing = _this$resolveArgument[1];
|
185 |
+
|
186 |
+
_this.removeClasses(node, 'exit');
|
187 |
+
|
188 |
+
_this.addClass(node, appearing ? 'appear' : 'enter', 'base');
|
189 |
+
|
190 |
+
if (_this.props.onEnter) {
|
191 |
+
_this.props.onEnter(maybeNode, maybeAppearing);
|
192 |
+
}
|
193 |
+
};
|
194 |
+
|
195 |
+
_this.onEntering = function (maybeNode, maybeAppearing) {
|
196 |
+
var _this$resolveArgument2 = _this.resolveArguments(maybeNode, maybeAppearing),
|
197 |
+
node = _this$resolveArgument2[0],
|
198 |
+
appearing = _this$resolveArgument2[1];
|
199 |
+
|
200 |
+
var type = appearing ? 'appear' : 'enter';
|
201 |
+
|
202 |
+
_this.addClass(node, type, 'active');
|
203 |
+
|
204 |
+
if (_this.props.onEntering) {
|
205 |
+
_this.props.onEntering(maybeNode, maybeAppearing);
|
206 |
+
}
|
207 |
+
};
|
208 |
+
|
209 |
+
_this.onEntered = function (maybeNode, maybeAppearing) {
|
210 |
+
var _this$resolveArgument3 = _this.resolveArguments(maybeNode, maybeAppearing),
|
211 |
+
node = _this$resolveArgument3[0],
|
212 |
+
appearing = _this$resolveArgument3[1];
|
213 |
+
|
214 |
+
var type = appearing ? 'appear' : 'enter';
|
215 |
+
|
216 |
+
_this.removeClasses(node, type);
|
217 |
+
|
218 |
+
_this.addClass(node, type, 'done');
|
219 |
+
|
220 |
+
if (_this.props.onEntered) {
|
221 |
+
_this.props.onEntered(maybeNode, maybeAppearing);
|
222 |
+
}
|
223 |
+
};
|
224 |
+
|
225 |
+
_this.onExit = function (maybeNode) {
|
226 |
+
var _this$resolveArgument4 = _this.resolveArguments(maybeNode),
|
227 |
+
node = _this$resolveArgument4[0];
|
228 |
+
|
229 |
+
_this.removeClasses(node, 'appear');
|
230 |
+
|
231 |
+
_this.removeClasses(node, 'enter');
|
232 |
+
|
233 |
+
_this.addClass(node, 'exit', 'base');
|
234 |
+
|
235 |
+
if (_this.props.onExit) {
|
236 |
+
_this.props.onExit(maybeNode);
|
237 |
+
}
|
238 |
+
};
|
239 |
+
|
240 |
+
_this.onExiting = function (maybeNode) {
|
241 |
+
var _this$resolveArgument5 = _this.resolveArguments(maybeNode),
|
242 |
+
node = _this$resolveArgument5[0];
|
243 |
+
|
244 |
+
_this.addClass(node, 'exit', 'active');
|
245 |
+
|
246 |
+
if (_this.props.onExiting) {
|
247 |
+
_this.props.onExiting(maybeNode);
|
248 |
+
}
|
249 |
+
};
|
250 |
+
|
251 |
+
_this.onExited = function (maybeNode) {
|
252 |
+
var _this$resolveArgument6 = _this.resolveArguments(maybeNode),
|
253 |
+
node = _this$resolveArgument6[0];
|
254 |
+
|
255 |
+
_this.removeClasses(node, 'exit');
|
256 |
+
|
257 |
+
_this.addClass(node, 'exit', 'done');
|
258 |
+
|
259 |
+
if (_this.props.onExited) {
|
260 |
+
_this.props.onExited(maybeNode);
|
261 |
+
}
|
262 |
+
};
|
263 |
+
|
264 |
+
_this.resolveArguments = function (maybeNode, maybeAppearing) {
|
265 |
+
return _this.props.nodeRef ? [_this.props.nodeRef.current, maybeNode] // here `maybeNode` is actually `appearing`
|
266 |
+
: [maybeNode, maybeAppearing];
|
267 |
+
};
|
268 |
+
|
269 |
+
_this.getClassNames = function (type) {
|
270 |
+
var classNames = _this.props.classNames;
|
271 |
+
var isStringClassNames = typeof classNames === 'string';
|
272 |
+
var prefix = isStringClassNames && classNames ? classNames + "-" : '';
|
273 |
+
var baseClassName = isStringClassNames ? "" + prefix + type : classNames[type];
|
274 |
+
var activeClassName = isStringClassNames ? baseClassName + "-active" : classNames[type + "Active"];
|
275 |
+
var doneClassName = isStringClassNames ? baseClassName + "-done" : classNames[type + "Done"];
|
276 |
+
return {
|
277 |
+
baseClassName: baseClassName,
|
278 |
+
activeClassName: activeClassName,
|
279 |
+
doneClassName: doneClassName
|
280 |
+
};
|
281 |
+
};
|
282 |
+
|
283 |
+
return _this;
|
284 |
+
}
|
285 |
+
|
286 |
+
var _proto = CSSTransition.prototype;
|
287 |
+
|
288 |
+
_proto.addClass = function addClass(node, type, phase) {
|
289 |
+
var className = this.getClassNames(type)[phase + "ClassName"];
|
290 |
+
|
291 |
+
var _this$getClassNames = this.getClassNames('enter'),
|
292 |
+
doneClassName = _this$getClassNames.doneClassName;
|
293 |
+
|
294 |
+
if (type === 'appear' && phase === 'done' && doneClassName) {
|
295 |
+
className += " " + doneClassName;
|
296 |
+
} // This is for to force a repaint,
|
297 |
+
// which is necessary in order to transition styles when adding a class name.
|
298 |
+
|
299 |
+
|
300 |
+
if (phase === 'active') {
|
301 |
+
/* eslint-disable no-unused-expressions */
|
302 |
+
node && node.scrollTop;
|
303 |
+
}
|
304 |
+
|
305 |
+
if (className) {
|
306 |
+
this.appliedClasses[type][phase] = className;
|
307 |
+
|
308 |
+
_addClass(node, className);
|
309 |
+
}
|
310 |
+
};
|
311 |
+
|
312 |
+
_proto.removeClasses = function removeClasses(node, type) {
|
313 |
+
var _this$appliedClasses$ = this.appliedClasses[type],
|
314 |
+
baseClassName = _this$appliedClasses$.base,
|
315 |
+
activeClassName = _this$appliedClasses$.active,
|
316 |
+
doneClassName = _this$appliedClasses$.done;
|
317 |
+
this.appliedClasses[type] = {};
|
318 |
+
|
319 |
+
if (baseClassName) {
|
320 |
+
CSSTransition_removeClass(node, baseClassName);
|
321 |
+
}
|
322 |
+
|
323 |
+
if (activeClassName) {
|
324 |
+
CSSTransition_removeClass(node, activeClassName);
|
325 |
+
}
|
326 |
+
|
327 |
+
if (doneClassName) {
|
328 |
+
CSSTransition_removeClass(node, doneClassName);
|
329 |
+
}
|
330 |
+
};
|
331 |
+
|
332 |
+
_proto.render = function render() {
|
333 |
+
var _this$props = this.props,
|
334 |
+
_ = _this$props.classNames,
|
335 |
+
props = Object(objectWithoutPropertiesLoose["a" /* default */])(_this$props, ["classNames"]);
|
336 |
+
|
337 |
+
return /*#__PURE__*/external_React_default.a.createElement(Transition["a" /* default */], Object(esm_extends["a" /* default */])({}, props, {
|
338 |
+
onEnter: this.onEnter,
|
339 |
+
onEntered: this.onEntered,
|
340 |
+
onEntering: this.onEntering,
|
341 |
+
onExit: this.onExit,
|
342 |
+
onExiting: this.onExiting,
|
343 |
+
onExited: this.onExited
|
344 |
+
}));
|
345 |
+
};
|
346 |
+
|
347 |
+
return CSSTransition;
|
348 |
+
}(external_React_default.a.Component);
|
349 |
+
|
350 |
+
CSSTransition_CSSTransition.defaultProps = {
|
351 |
+
classNames: ''
|
352 |
+
};
|
353 |
+
CSSTransition_CSSTransition.propTypes = false ? undefined : {};
|
354 |
+
/* harmony default export */ var esm_CSSTransition = __webpack_exports__["a"] = (CSSTransition_CSSTransition);
|
355 |
+
|
356 |
+
/***/ }),
|
357 |
+
|
358 |
+
/***/ 173:
|
359 |
+
/***/ (function(module, __webpack_exports__, __webpack_require__) {
|
360 |
+
|
361 |
+
"use strict";
|
362 |
+
|
363 |
+
// EXTERNAL MODULE: ./node_modules/@babel/runtime/helpers/esm/objectWithoutPropertiesLoose.js
|
364 |
+
var objectWithoutPropertiesLoose = __webpack_require__(22);
|
365 |
+
|
366 |
+
// EXTERNAL MODULE: ./node_modules/@babel/runtime/helpers/esm/extends.js
|
367 |
+
var esm_extends = __webpack_require__(23);
|
368 |
+
|
369 |
+
// CONCATENATED MODULE: ./node_modules/@babel/runtime/helpers/esm/assertThisInitialized.js
|
370 |
+
function _assertThisInitialized(self) {
|
371 |
+
if (self === void 0) {
|
372 |
+
throw new ReferenceError("this hasn't been initialised - super() hasn't been called");
|
373 |
+
}
|
374 |
+
|
375 |
+
return self;
|
376 |
+
}
|
377 |
+
// EXTERNAL MODULE: ./node_modules/@babel/runtime/helpers/esm/inheritsLoose.js + 1 modules
|
378 |
+
var inheritsLoose = __webpack_require__(25);
|
379 |
+
|
380 |
+
// EXTERNAL MODULE: ./node_modules/prop-types/index.js
|
381 |
+
var prop_types = __webpack_require__(1);
|
382 |
+
|
383 |
+
// EXTERNAL MODULE: external "React"
|
384 |
+
var external_React_ = __webpack_require__(5);
|
385 |
+
var external_React_default = /*#__PURE__*/__webpack_require__.n(external_React_);
|
386 |
+
|
387 |
+
// EXTERNAL MODULE: ./node_modules/react-transition-group/esm/TransitionGroupContext.js
|
388 |
+
var TransitionGroupContext = __webpack_require__(33);
|
389 |
+
|
390 |
+
// CONCATENATED MODULE: ./node_modules/react-transition-group/esm/utils/ChildMapping.js
|
391 |
+
|
392 |
+
/**
|
393 |
+
* Given `this.props.children`, return an object mapping key to child.
|
394 |
+
*
|
395 |
+
* @param {*} children `this.props.children`
|
396 |
+
* @return {object} Mapping of key to child
|
397 |
+
*/
|
398 |
+
|
399 |
+
function getChildMapping(children, mapFn) {
|
400 |
+
var mapper = function mapper(child) {
|
401 |
+
return mapFn && Object(external_React_["isValidElement"])(child) ? mapFn(child) : child;
|
402 |
+
};
|
403 |
+
|
404 |
+
var result = Object.create(null);
|
405 |
+
if (children) external_React_["Children"].map(children, function (c) {
|
406 |
+
return c;
|
407 |
+
}).forEach(function (child) {
|
408 |
+
// run the map function here instead so that the key is the computed one
|
409 |
+
result[child.key] = mapper(child);
|
410 |
+
});
|
411 |
+
return result;
|
412 |
+
}
|
413 |
+
/**
|
414 |
+
* When you're adding or removing children some may be added or removed in the
|
415 |
+
* same render pass. We want to show *both* since we want to simultaneously
|
416 |
+
* animate elements in and out. This function takes a previous set of keys
|
417 |
+
* and a new set of keys and merges them with its best guess of the correct
|
418 |
+
* ordering. In the future we may expose some of the utilities in
|
419 |
+
* ReactMultiChild to make this easy, but for now React itself does not
|
420 |
+
* directly have this concept of the union of prevChildren and nextChildren
|
421 |
+
* so we implement it here.
|
422 |
+
*
|
423 |
+
* @param {object} prev prev children as returned from
|
424 |
+
* `ReactTransitionChildMapping.getChildMapping()`.
|
425 |
+
* @param {object} next next children as returned from
|
426 |
+
* `ReactTransitionChildMapping.getChildMapping()`.
|
427 |
+
* @return {object} a key set that contains all keys in `prev` and all keys
|
428 |
+
* in `next` in a reasonable order.
|
429 |
+
*/
|
430 |
+
|
431 |
+
function mergeChildMappings(prev, next) {
|
432 |
+
prev = prev || {};
|
433 |
+
next = next || {};
|
434 |
+
|
435 |
+
function getValueForKey(key) {
|
436 |
+
return key in next ? next[key] : prev[key];
|
437 |
+
} // For each key of `next`, the list of keys to insert before that key in
|
438 |
+
// the combined list
|
439 |
+
|
440 |
+
|
441 |
+
var nextKeysPending = Object.create(null);
|
442 |
+
var pendingKeys = [];
|
443 |
+
|
444 |
+
for (var prevKey in prev) {
|
445 |
+
if (prevKey in next) {
|
446 |
+
if (pendingKeys.length) {
|
447 |
+
nextKeysPending[prevKey] = pendingKeys;
|
448 |
+
pendingKeys = [];
|
449 |
+
}
|
450 |
+
} else {
|
451 |
+
pendingKeys.push(prevKey);
|
452 |
+
}
|
453 |
+
}
|
454 |
+
|
455 |
+
var i;
|
456 |
+
var childMapping = {};
|
457 |
+
|
458 |
+
for (var nextKey in next) {
|
459 |
+
if (nextKeysPending[nextKey]) {
|
460 |
+
for (i = 0; i < nextKeysPending[nextKey].length; i++) {
|
461 |
+
var pendingNextKey = nextKeysPending[nextKey][i];
|
462 |
+
childMapping[nextKeysPending[nextKey][i]] = getValueForKey(pendingNextKey);
|
463 |
+
}
|
464 |
+
}
|
465 |
+
|
466 |
+
childMapping[nextKey] = getValueForKey(nextKey);
|
467 |
+
} // Finally, add the keys which didn't appear before any key in `next`
|
468 |
+
|
469 |
+
|
470 |
+
for (i = 0; i < pendingKeys.length; i++) {
|
471 |
+
childMapping[pendingKeys[i]] = getValueForKey(pendingKeys[i]);
|
472 |
+
}
|
473 |
+
|
474 |
+
return childMapping;
|
475 |
+
}
|
476 |
+
|
477 |
+
function getProp(child, prop, props) {
|
478 |
+
return props[prop] != null ? props[prop] : child.props[prop];
|
479 |
+
}
|
480 |
+
|
481 |
+
function getInitialChildMapping(props, onExited) {
|
482 |
+
return getChildMapping(props.children, function (child) {
|
483 |
+
return Object(external_React_["cloneElement"])(child, {
|
484 |
+
onExited: onExited.bind(null, child),
|
485 |
+
in: true,
|
486 |
+
appear: getProp(child, 'appear', props),
|
487 |
+
enter: getProp(child, 'enter', props),
|
488 |
+
exit: getProp(child, 'exit', props)
|
489 |
+
});
|
490 |
+
});
|
491 |
+
}
|
492 |
+
function getNextChildMapping(nextProps, prevChildMapping, onExited) {
|
493 |
+
var nextChildMapping = getChildMapping(nextProps.children);
|
494 |
+
var children = mergeChildMappings(prevChildMapping, nextChildMapping);
|
495 |
+
Object.keys(children).forEach(function (key) {
|
496 |
+
var child = children[key];
|
497 |
+
if (!Object(external_React_["isValidElement"])(child)) return;
|
498 |
+
var hasPrev = (key in prevChildMapping);
|
499 |
+
var hasNext = (key in nextChildMapping);
|
500 |
+
var prevChild = prevChildMapping[key];
|
501 |
+
var isLeaving = Object(external_React_["isValidElement"])(prevChild) && !prevChild.props.in; // item is new (entering)
|
502 |
+
|
503 |
+
if (hasNext && (!hasPrev || isLeaving)) {
|
504 |
+
// console.log('entering', key)
|
505 |
+
children[key] = Object(external_React_["cloneElement"])(child, {
|
506 |
+
onExited: onExited.bind(null, child),
|
507 |
+
in: true,
|
508 |
+
exit: getProp(child, 'exit', nextProps),
|
509 |
+
enter: getProp(child, 'enter', nextProps)
|
510 |
+
});
|
511 |
+
} else if (!hasNext && hasPrev && !isLeaving) {
|
512 |
+
// item is old (exiting)
|
513 |
+
// console.log('leaving', key)
|
514 |
+
children[key] = Object(external_React_["cloneElement"])(child, {
|
515 |
+
in: false
|
516 |
+
});
|
517 |
+
} else if (hasNext && hasPrev && Object(external_React_["isValidElement"])(prevChild)) {
|
518 |
+
// item hasn't changed transition states
|
519 |
+
// copy over the last transition props;
|
520 |
+
// console.log('unchanged', key)
|
521 |
+
children[key] = Object(external_React_["cloneElement"])(child, {
|
522 |
+
onExited: onExited.bind(null, child),
|
523 |
+
in: prevChild.props.in,
|
524 |
+
exit: getProp(child, 'exit', nextProps),
|
525 |
+
enter: getProp(child, 'enter', nextProps)
|
526 |
+
});
|
527 |
+
}
|
528 |
+
});
|
529 |
+
return children;
|
530 |
+
}
|
531 |
+
// CONCATENATED MODULE: ./node_modules/react-transition-group/esm/TransitionGroup.js
|
532 |
+
|
533 |
+
|
534 |
+
|
535 |
+
|
536 |
+
|
537 |
+
|
538 |
+
|
539 |
+
|
540 |
+
|
541 |
+
var values = Object.values || function (obj) {
|
542 |
+
return Object.keys(obj).map(function (k) {
|
543 |
+
return obj[k];
|
544 |
+
});
|
545 |
+
};
|
546 |
+
|
547 |
+
var defaultProps = {
|
548 |
+
component: 'div',
|
549 |
+
childFactory: function childFactory(child) {
|
550 |
+
return child;
|
551 |
+
}
|
552 |
+
};
|
553 |
+
/**
|
554 |
+
* The `<TransitionGroup>` component manages a set of transition components
|
555 |
+
* (`<Transition>` and `<CSSTransition>`) in a list. Like with the transition
|
556 |
+
* components, `<TransitionGroup>` is a state machine for managing the mounting
|
557 |
+
* and unmounting of components over time.
|
558 |
+
*
|
559 |
+
* Consider the example below. As items are removed or added to the TodoList the
|
560 |
+
* `in` prop is toggled automatically by the `<TransitionGroup>`.
|
561 |
+
*
|
562 |
+
* Note that `<TransitionGroup>` does not define any animation behavior!
|
563 |
+
* Exactly _how_ a list item animates is up to the individual transition
|
564 |
+
* component. This means you can mix and match animations across different list
|
565 |
+
* items.
|
566 |
+
*/
|
567 |
+
|
568 |
+
var TransitionGroup_TransitionGroup = /*#__PURE__*/function (_React$Component) {
|
569 |
+
Object(inheritsLoose["a" /* default */])(TransitionGroup, _React$Component);
|
570 |
+
|
571 |
+
function TransitionGroup(props, context) {
|
572 |
+
var _this;
|
573 |
+
|
574 |
+
_this = _React$Component.call(this, props, context) || this;
|
575 |
+
|
576 |
+
var handleExited = _this.handleExited.bind(_assertThisInitialized(_this)); // Initial children should all be entering, dependent on appear
|
577 |
+
|
578 |
+
|
579 |
+
_this.state = {
|
580 |
+
contextValue: {
|
581 |
+
isMounting: true
|
582 |
+
},
|
583 |
+
handleExited: handleExited,
|
584 |
+
firstRender: true
|
585 |
+
};
|
586 |
+
return _this;
|
587 |
+
}
|
588 |
+
|
589 |
+
var _proto = TransitionGroup.prototype;
|
590 |
+
|
591 |
+
_proto.componentDidMount = function componentDidMount() {
|
592 |
+
this.mounted = true;
|
593 |
+
this.setState({
|
594 |
+
contextValue: {
|
595 |
+
isMounting: false
|
596 |
+
}
|
597 |
+
});
|
598 |
+
};
|
599 |
+
|
600 |
+
_proto.componentWillUnmount = function componentWillUnmount() {
|
601 |
+
this.mounted = false;
|
602 |
+
};
|
603 |
+
|
604 |
+
TransitionGroup.getDerivedStateFromProps = function getDerivedStateFromProps(nextProps, _ref) {
|
605 |
+
var prevChildMapping = _ref.children,
|
606 |
+
handleExited = _ref.handleExited,
|
607 |
+
firstRender = _ref.firstRender;
|
608 |
+
return {
|
609 |
+
children: firstRender ? getInitialChildMapping(nextProps, handleExited) : getNextChildMapping(nextProps, prevChildMapping, handleExited),
|
610 |
+
firstRender: false
|
611 |
+
};
|
612 |
+
} // node is `undefined` when user provided `nodeRef` prop
|
613 |
+
;
|
614 |
+
|
615 |
+
_proto.handleExited = function handleExited(child, node) {
|
616 |
+
var currentChildMapping = getChildMapping(this.props.children);
|
617 |
+
if (child.key in currentChildMapping) return;
|
618 |
+
|
619 |
+
if (child.props.onExited) {
|
620 |
+
child.props.onExited(node);
|
621 |
+
}
|
622 |
+
|
623 |
+
if (this.mounted) {
|
624 |
+
this.setState(function (state) {
|
625 |
+
var children = Object(esm_extends["a" /* default */])({}, state.children);
|
626 |
+
|
627 |
+
delete children[child.key];
|
628 |
+
return {
|
629 |
+
children: children
|
630 |
+
};
|
631 |
+
});
|
632 |
+
}
|
633 |
+
};
|
634 |
+
|
635 |
+
_proto.render = function render() {
|
636 |
+
var _this$props = this.props,
|
637 |
+
Component = _this$props.component,
|
638 |
+
childFactory = _this$props.childFactory,
|
639 |
+
props = Object(objectWithoutPropertiesLoose["a" /* default */])(_this$props, ["component", "childFactory"]);
|
640 |
+
|
641 |
+
var contextValue = this.state.contextValue;
|
642 |
+
var children = values(this.state.children).map(childFactory);
|
643 |
+
delete props.appear;
|
644 |
+
delete props.enter;
|
645 |
+
delete props.exit;
|
646 |
+
|
647 |
+
if (Component === null) {
|
648 |
+
return /*#__PURE__*/external_React_default.a.createElement(TransitionGroupContext["a" /* default */].Provider, {
|
649 |
+
value: contextValue
|
650 |
+
}, children);
|
651 |
+
}
|
652 |
+
|
653 |
+
return /*#__PURE__*/external_React_default.a.createElement(TransitionGroupContext["a" /* default */].Provider, {
|
654 |
+
value: contextValue
|
655 |
+
}, /*#__PURE__*/external_React_default.a.createElement(Component, props, children));
|
656 |
+
};
|
657 |
+
|
658 |
+
return TransitionGroup;
|
659 |
+
}(external_React_default.a.Component);
|
660 |
+
|
661 |
+
TransitionGroup_TransitionGroup.propTypes = false ? undefined : {};
|
662 |
+
TransitionGroup_TransitionGroup.defaultProps = defaultProps;
|
663 |
+
/* harmony default export */ var esm_TransitionGroup = __webpack_exports__["a"] = (TransitionGroup_TransitionGroup);
|
664 |
+
|
665 |
+
/***/ }),
|
666 |
+
|
667 |
+
/***/ 33:
|
668 |
+
/***/ (function(module, __webpack_exports__, __webpack_require__) {
|
669 |
+
|
670 |
+
"use strict";
|
671 |
+
/* harmony import */ var react__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(5);
|
672 |
+
/* harmony import */ var react__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(react__WEBPACK_IMPORTED_MODULE_0__);
|
673 |
+
|
674 |
+
/* harmony default export */ __webpack_exports__["a"] = (react__WEBPACK_IMPORTED_MODULE_0___default.a.createContext(null));
|
675 |
+
|
676 |
+
/***/ }),
|
677 |
+
|
678 |
+
/***/ 67:
|
679 |
+
/***/ (function(module, __webpack_exports__, __webpack_require__) {
|
680 |
+
|
681 |
+
"use strict";
|
682 |
+
|
683 |
+
// UNUSED EXPORTS: UNMOUNTED, EXITED, ENTERING, ENTERED, EXITING
|
684 |
+
|
685 |
+
// EXTERNAL MODULE: ./node_modules/@babel/runtime/helpers/esm/objectWithoutPropertiesLoose.js
|
686 |
+
var objectWithoutPropertiesLoose = __webpack_require__(22);
|
687 |
+
|
688 |
+
// EXTERNAL MODULE: ./node_modules/@babel/runtime/helpers/esm/inheritsLoose.js + 1 modules
|
689 |
+
var inheritsLoose = __webpack_require__(25);
|
690 |
+
|
691 |
+
// EXTERNAL MODULE: ./node_modules/prop-types/index.js
|
692 |
+
var prop_types = __webpack_require__(1);
|
693 |
+
|
694 |
+
// EXTERNAL MODULE: external "React"
|
695 |
+
var external_React_ = __webpack_require__(5);
|
696 |
+
var external_React_default = /*#__PURE__*/__webpack_require__.n(external_React_);
|
697 |
+
|
698 |
+
// EXTERNAL MODULE: external "ReactDOM"
|
699 |
+
var external_ReactDOM_ = __webpack_require__(30);
|
700 |
+
var external_ReactDOM_default = /*#__PURE__*/__webpack_require__.n(external_ReactDOM_);
|
701 |
+
|
702 |
+
// CONCATENATED MODULE: ./node_modules/react-transition-group/esm/config.js
|
703 |
+
/* harmony default export */ var config = ({
|
704 |
+
disabled: false
|
705 |
+
});
|
706 |
+
// EXTERNAL MODULE: ./node_modules/react-transition-group/esm/TransitionGroupContext.js
|
707 |
+
var TransitionGroupContext = __webpack_require__(33);
|
708 |
+
|
709 |
+
// CONCATENATED MODULE: ./node_modules/react-transition-group/esm/Transition.js
|
710 |
+
|
711 |
+
|
712 |
+
|
713 |
+
|
714 |
+
|
715 |
+
|
716 |
+
|
717 |
+
|
718 |
+
var UNMOUNTED = 'unmounted';
|
719 |
+
var EXITED = 'exited';
|
720 |
+
var ENTERING = 'entering';
|
721 |
+
var ENTERED = 'entered';
|
722 |
+
var EXITING = 'exiting';
|
723 |
+
/**
|
724 |
+
* The Transition component lets you describe a transition from one component
|
725 |
+
* state to another _over time_ with a simple declarative API. Most commonly
|
726 |
+
* it's used to animate the mounting and unmounting of a component, but can also
|
727 |
+
* be used to describe in-place transition states as well.
|
728 |
+
*
|
729 |
+
* ---
|
730 |
+
*
|
731 |
+
* **Note**: `Transition` is a platform-agnostic base component. If you're using
|
732 |
+
* transitions in CSS, you'll probably want to use
|
733 |
+
* [`CSSTransition`](https://reactcommunity.org/react-transition-group/css-transition)
|
734 |
+
* instead. It inherits all the features of `Transition`, but contains
|
735 |
+
* additional features necessary to play nice with CSS transitions (hence the
|
736 |
+
* name of the component).
|
737 |
+
*
|
738 |
+
* ---
|
739 |
+
*
|
740 |
+
* By default the `Transition` component does not alter the behavior of the
|
741 |
+
* component it renders, it only tracks "enter" and "exit" states for the
|
742 |
+
* components. It's up to you to give meaning and effect to those states. For
|
743 |
+
* example we can add styles to a component when it enters or exits:
|
744 |
+
*
|
745 |
+
* ```jsx
|
746 |
+
* import { Transition } from 'react-transition-group';
|
747 |
+
*
|
748 |
+
* const duration = 300;
|
749 |
+
*
|
750 |
+
* const defaultStyle = {
|
751 |
+
* transition: `opacity ${duration}ms ease-in-out`,
|
752 |
+
* opacity: 0,
|
753 |
+
* }
|
754 |
+
*
|
755 |
+
* const transitionStyles = {
|
756 |
+
* entering: { opacity: 1 },
|
757 |
+
* entered: { opacity: 1 },
|
758 |
+
* exiting: { opacity: 0 },
|
759 |
+
* exited: { opacity: 0 },
|
760 |
+
* };
|
761 |
+
*
|
762 |
+
* const Fade = ({ in: inProp }) => (
|
763 |
+
* <Transition in={inProp} timeout={duration}>
|
764 |
+
* {state => (
|
765 |
+
* <div style={{
|
766 |
+
* ...defaultStyle,
|
767 |
+
* ...transitionStyles[state]
|
768 |
+
* }}>
|
769 |
+
* I'm a fade Transition!
|
770 |
+
* </div>
|
771 |
+
* )}
|
772 |
+
* </Transition>
|
773 |
+
* );
|
774 |
+
* ```
|
775 |
+
*
|
776 |
+
* There are 4 main states a Transition can be in:
|
777 |
+
* - `'entering'`
|
778 |
+
* - `'entered'`
|
779 |
+
* - `'exiting'`
|
780 |
+
* - `'exited'`
|
781 |
+
*
|
782 |
+
* Transition state is toggled via the `in` prop. When `true` the component
|
783 |
+
* begins the "Enter" stage. During this stage, the component will shift from
|
784 |
+
* its current transition state, to `'entering'` for the duration of the
|
785 |
+
* transition and then to the `'entered'` stage once it's complete. Let's take
|
786 |
+
* the following example (we'll use the
|
787 |
+
* [useState](https://reactjs.org/docs/hooks-reference.html#usestate) hook):
|
788 |
+
*
|
789 |
+
* ```jsx
|
790 |
+
* function App() {
|
791 |
+
* const [inProp, setInProp] = useState(false);
|
792 |
+
* return (
|
793 |
+
* <div>
|
794 |
+
* <Transition in={inProp} timeout={500}>
|
795 |
+
* {state => (
|
796 |
+
* // ...
|
797 |
+
* )}
|
798 |
+
* </Transition>
|
799 |
+
* <button onClick={() => setInProp(true)}>
|
800 |
+
* Click to Enter
|
801 |
+
* </button>
|
802 |
+
* </div>
|
803 |
+
* );
|
804 |
+
* }
|
805 |
+
* ```
|
806 |
+
*
|
807 |
+
* When the button is clicked the component will shift to the `'entering'` state
|
808 |
+
* and stay there for 500ms (the value of `timeout`) before it finally switches
|
809 |
+
* to `'entered'`.
|
810 |
+
*
|
811 |
+
* When `in` is `false` the same thing happens except the state moves from
|
812 |
+
* `'exiting'` to `'exited'`.
|
813 |
+
*/
|
814 |
+
|
815 |
+
var Transition_Transition = /*#__PURE__*/function (_React$Component) {
|
816 |
+
Object(inheritsLoose["a" /* default */])(Transition, _React$Component);
|
817 |
+
|
818 |
+
function Transition(props, context) {
|
819 |
+
var _this;
|
820 |
+
|
821 |
+
_this = _React$Component.call(this, props, context) || this;
|
822 |
+
var parentGroup = context; // In the context of a TransitionGroup all enters are really appears
|
823 |
+
|
824 |
+
var appear = parentGroup && !parentGroup.isMounting ? props.enter : props.appear;
|
825 |
+
var initialStatus;
|
826 |
+
_this.appearStatus = null;
|
827 |
+
|
828 |
+
if (props.in) {
|
829 |
+
if (appear) {
|
830 |
+
initialStatus = EXITED;
|
831 |
+
_this.appearStatus = ENTERING;
|
832 |
+
} else {
|
833 |
+
initialStatus = ENTERED;
|
834 |
+
}
|
835 |
+
} else {
|
836 |
+
if (props.unmountOnExit || props.mountOnEnter) {
|
837 |
+
initialStatus = UNMOUNTED;
|
838 |
+
} else {
|
839 |
+
initialStatus = EXITED;
|
840 |
+
}
|
841 |
+
}
|
842 |
+
|
843 |
+
_this.state = {
|
844 |
+
status: initialStatus
|
845 |
+
};
|
846 |
+
_this.nextCallback = null;
|
847 |
+
return _this;
|
848 |
+
}
|
849 |
+
|
850 |
+
Transition.getDerivedStateFromProps = function getDerivedStateFromProps(_ref, prevState) {
|
851 |
+
var nextIn = _ref.in;
|
852 |
+
|
853 |
+
if (nextIn && prevState.status === UNMOUNTED) {
|
854 |
+
return {
|
855 |
+
status: EXITED
|
856 |
+
};
|
857 |
+
}
|
858 |
+
|
859 |
+
return null;
|
860 |
+
} // getSnapshotBeforeUpdate(prevProps) {
|
861 |
+
// let nextStatus = null
|
862 |
+
// if (prevProps !== this.props) {
|
863 |
+
// const { status } = this.state
|
864 |
+
// if (this.props.in) {
|
865 |
+
// if (status !== ENTERING && status !== ENTERED) {
|
866 |
+
// nextStatus = ENTERING
|
867 |
+
// }
|
868 |
+
// } else {
|
869 |
+
// if (status === ENTERING || status === ENTERED) {
|
870 |
+
// nextStatus = EXITING
|
871 |
+
// }
|
872 |
+
// }
|
873 |
+
// }
|
874 |
+
// return { nextStatus }
|
875 |
+
// }
|
876 |
+
;
|
877 |
+
|
878 |
+
var _proto = Transition.prototype;
|
879 |
+
|
880 |
+
_proto.componentDidMount = function componentDidMount() {
|
881 |
+
this.updateStatus(true, this.appearStatus);
|
882 |
+
};
|
883 |
+
|
884 |
+
_proto.componentDidUpdate = function componentDidUpdate(prevProps) {
|
885 |
+
var nextStatus = null;
|
886 |
+
|
887 |
+
if (prevProps !== this.props) {
|
888 |
+
var status = this.state.status;
|
889 |
+
|
890 |
+
if (this.props.in) {
|
891 |
+
if (status !== ENTERING && status !== ENTERED) {
|
892 |
+
nextStatus = ENTERING;
|
893 |
+
}
|
894 |
+
} else {
|
895 |
+
if (status === ENTERING || status === ENTERED) {
|
896 |
+
nextStatus = EXITING;
|
897 |
+
}
|
898 |
+
}
|
899 |
+
}
|
900 |
+
|
901 |
+
this.updateStatus(false, nextStatus);
|
902 |
+
};
|
903 |
+
|
904 |
+
_proto.componentWillUnmount = function componentWillUnmount() {
|
905 |
+
this.cancelNextCallback();
|
906 |
+
};
|
907 |
+
|
908 |
+
_proto.getTimeouts = function getTimeouts() {
|
909 |
+
var timeout = this.props.timeout;
|
910 |
+
var exit, enter, appear;
|
911 |
+
exit = enter = appear = timeout;
|
912 |
+
|
913 |
+
if (timeout != null && typeof timeout !== 'number') {
|
914 |
+
exit = timeout.exit;
|
915 |
+
enter = timeout.enter; // TODO: remove fallback for next major
|
916 |
+
|
917 |
+
appear = timeout.appear !== undefined ? timeout.appear : enter;
|
918 |
+
}
|
919 |
+
|
920 |
+
return {
|
921 |
+
exit: exit,
|
922 |
+
enter: enter,
|
923 |
+
appear: appear
|
924 |
+
};
|
925 |
+
};
|
926 |
+
|
927 |
+
_proto.updateStatus = function updateStatus(mounting, nextStatus) {
|
928 |
+
if (mounting === void 0) {
|
929 |
+
mounting = false;
|
930 |
+
}
|
931 |
+
|
932 |
+
if (nextStatus !== null) {
|
933 |
+
// nextStatus will always be ENTERING or EXITING.
|
934 |
+
this.cancelNextCallback();
|
935 |
+
|
936 |
+
if (nextStatus === ENTERING) {
|
937 |
+
this.performEnter(mounting);
|
938 |
+
} else {
|
939 |
+
this.performExit();
|
940 |
+
}
|
941 |
+
} else if (this.props.unmountOnExit && this.state.status === EXITED) {
|
942 |
+
this.setState({
|
943 |
+
status: UNMOUNTED
|
944 |
+
});
|
945 |
+
}
|
946 |
+
};
|
947 |
+
|
948 |
+
_proto.performEnter = function performEnter(mounting) {
|
949 |
+
var _this2 = this;
|
950 |
+
|
951 |
+
var enter = this.props.enter;
|
952 |
+
var appearing = this.context ? this.context.isMounting : mounting;
|
953 |
+
|
954 |
+
var _ref2 = this.props.nodeRef ? [appearing] : [external_ReactDOM_default.a.findDOMNode(this), appearing],
|
955 |
+
maybeNode = _ref2[0],
|
956 |
+
maybeAppearing = _ref2[1];
|
957 |
+
|
958 |
+
var timeouts = this.getTimeouts();
|
959 |
+
var enterTimeout = appearing ? timeouts.appear : timeouts.enter; // no enter animation skip right to ENTERED
|
960 |
+
// if we are mounting and running this it means appear _must_ be set
|
961 |
+
|
962 |
+
if (!mounting && !enter || config.disabled) {
|
963 |
+
this.safeSetState({
|
964 |
+
status: ENTERED
|
965 |
+
}, function () {
|
966 |
+
_this2.props.onEntered(maybeNode);
|
967 |
+
});
|
968 |
+
return;
|
969 |
+
}
|
970 |
+
|
971 |
+
this.props.onEnter(maybeNode, maybeAppearing);
|
972 |
+
this.safeSetState({
|
973 |
+
status: ENTERING
|
974 |
+
}, function () {
|
975 |
+
_this2.props.onEntering(maybeNode, maybeAppearing);
|
976 |
+
|
977 |
+
_this2.onTransitionEnd(enterTimeout, function () {
|
978 |
+
_this2.safeSetState({
|
979 |
+
status: ENTERED
|
980 |
+
}, function () {
|
981 |
+
_this2.props.onEntered(maybeNode, maybeAppearing);
|
982 |
+
});
|
983 |
+
});
|
984 |
+
});
|
985 |
+
};
|
986 |
+
|
987 |
+
_proto.performExit = function performExit() {
|
988 |
+
var _this3 = this;
|
989 |
+
|
990 |
+
var exit = this.props.exit;
|
991 |
+
var timeouts = this.getTimeouts();
|
992 |
+
var maybeNode = this.props.nodeRef ? undefined : external_ReactDOM_default.a.findDOMNode(this); // no exit animation skip right to EXITED
|
993 |
+
|
994 |
+
if (!exit || config.disabled) {
|
995 |
+
this.safeSetState({
|
996 |
+
status: EXITED
|
997 |
+
}, function () {
|
998 |
+
_this3.props.onExited(maybeNode);
|
999 |
+
});
|
1000 |
+
return;
|
1001 |
+
}
|
1002 |
+
|
1003 |
+
this.props.onExit(maybeNode);
|
1004 |
+
this.safeSetState({
|
1005 |
+
status: EXITING
|
1006 |
+
}, function () {
|
1007 |
+
_this3.props.onExiting(maybeNode);
|
1008 |
+
|
1009 |
+
_this3.onTransitionEnd(timeouts.exit, function () {
|
1010 |
+
_this3.safeSetState({
|
1011 |
+
status: EXITED
|
1012 |
+
}, function () {
|
1013 |
+
_this3.props.onExited(maybeNode);
|
1014 |
+
});
|
1015 |
+
});
|
1016 |
+
});
|
1017 |
+
};
|
1018 |
+
|
1019 |
+
_proto.cancelNextCallback = function cancelNextCallback() {
|
1020 |
+
if (this.nextCallback !== null) {
|
1021 |
+
this.nextCallback.cancel();
|
1022 |
+
this.nextCallback = null;
|
1023 |
+
}
|
1024 |
+
};
|
1025 |
+
|
1026 |
+
_proto.safeSetState = function safeSetState(nextState, callback) {
|
1027 |
+
// This shouldn't be necessary, but there are weird race conditions with
|
1028 |
+
// setState callbacks and unmounting in testing, so always make sure that
|
1029 |
+
// we can cancel any pending setState callbacks after we unmount.
|
1030 |
+
callback = this.setNextCallback(callback);
|
1031 |
+
this.setState(nextState, callback);
|
1032 |
+
};
|
1033 |
+
|
1034 |
+
_proto.setNextCallback = function setNextCallback(callback) {
|
1035 |
+
var _this4 = this;
|
1036 |
+
|
1037 |
+
var active = true;
|
1038 |
+
|
1039 |
+
this.nextCallback = function (event) {
|
1040 |
+
if (active) {
|
1041 |
+
active = false;
|
1042 |
+
_this4.nextCallback = null;
|
1043 |
+
callback(event);
|
1044 |
+
}
|
1045 |
+
};
|
1046 |
+
|
1047 |
+
this.nextCallback.cancel = function () {
|
1048 |
+
active = false;
|
1049 |
+
};
|
1050 |
+
|
1051 |
+
return this.nextCallback;
|
1052 |
+
};
|
1053 |
+
|
1054 |
+
_proto.onTransitionEnd = function onTransitionEnd(timeout, handler) {
|
1055 |
+
this.setNextCallback(handler);
|
1056 |
+
var node = this.props.nodeRef ? this.props.nodeRef.current : external_ReactDOM_default.a.findDOMNode(this);
|
1057 |
+
var doesNotHaveTimeoutOrListener = timeout == null && !this.props.addEndListener;
|
1058 |
+
|
1059 |
+
if (!node || doesNotHaveTimeoutOrListener) {
|
1060 |
+
setTimeout(this.nextCallback, 0);
|
1061 |
+
return;
|
1062 |
+
}
|
1063 |
+
|
1064 |
+
if (this.props.addEndListener) {
|
1065 |
+
var _ref3 = this.props.nodeRef ? [this.nextCallback] : [node, this.nextCallback],
|
1066 |
+
maybeNode = _ref3[0],
|
1067 |
+
maybeNextCallback = _ref3[1];
|
1068 |
+
|
1069 |
+
this.props.addEndListener(maybeNode, maybeNextCallback);
|
1070 |
+
}
|
1071 |
+
|
1072 |
+
if (timeout != null) {
|
1073 |
+
setTimeout(this.nextCallback, timeout);
|
1074 |
+
}
|
1075 |
+
};
|
1076 |
+
|
1077 |
+
_proto.render = function render() {
|
1078 |
+
var status = this.state.status;
|
1079 |
+
|
1080 |
+
if (status === UNMOUNTED) {
|
1081 |
+
return null;
|
1082 |
+
}
|
1083 |
+
|
1084 |
+
var _this$props = this.props,
|
1085 |
+
children = _this$props.children,
|
1086 |
+
_in = _this$props.in,
|
1087 |
+
_mountOnEnter = _this$props.mountOnEnter,
|
1088 |
+
_unmountOnExit = _this$props.unmountOnExit,
|
1089 |
+
_appear = _this$props.appear,
|
1090 |
+
_enter = _this$props.enter,
|
1091 |
+
_exit = _this$props.exit,
|
1092 |
+
_timeout = _this$props.timeout,
|
1093 |
+
_addEndListener = _this$props.addEndListener,
|
1094 |
+
_onEnter = _this$props.onEnter,
|
1095 |
+
_onEntering = _this$props.onEntering,
|
1096 |
+
_onEntered = _this$props.onEntered,
|
1097 |
+
_onExit = _this$props.onExit,
|
1098 |
+
_onExiting = _this$props.onExiting,
|
1099 |
+
_onExited = _this$props.onExited,
|
1100 |
+
_nodeRef = _this$props.nodeRef,
|
1101 |
+
childProps = Object(objectWithoutPropertiesLoose["a" /* default */])(_this$props, ["children", "in", "mountOnEnter", "unmountOnExit", "appear", "enter", "exit", "timeout", "addEndListener", "onEnter", "onEntering", "onEntered", "onExit", "onExiting", "onExited", "nodeRef"]);
|
1102 |
+
|
1103 |
+
return (
|
1104 |
+
/*#__PURE__*/
|
1105 |
+
// allows for nested Transitions
|
1106 |
+
external_React_default.a.createElement(TransitionGroupContext["a" /* default */].Provider, {
|
1107 |
+
value: null
|
1108 |
+
}, typeof children === 'function' ? children(status, childProps) : external_React_default.a.cloneElement(external_React_default.a.Children.only(children), childProps))
|
1109 |
+
);
|
1110 |
+
};
|
1111 |
+
|
1112 |
+
return Transition;
|
1113 |
+
}(external_React_default.a.Component);
|
1114 |
+
|
1115 |
+
Transition_Transition.contextType = TransitionGroupContext["a" /* default */];
|
1116 |
+
Transition_Transition.propTypes = false ? undefined : {}; // Name the function so it is clearer in the documentation
|
1117 |
+
|
1118 |
+
function noop() {}
|
1119 |
+
|
1120 |
+
Transition_Transition.defaultProps = {
|
1121 |
+
in: false,
|
1122 |
+
mountOnEnter: false,
|
1123 |
+
unmountOnExit: false,
|
1124 |
+
appear: false,
|
1125 |
+
enter: true,
|
1126 |
+
exit: true,
|
1127 |
+
onEnter: noop,
|
1128 |
+
onEntering: noop,
|
1129 |
+
onEntered: noop,
|
1130 |
+
onExit: noop,
|
1131 |
+
onExiting: noop,
|
1132 |
+
onExited: noop
|
1133 |
+
};
|
1134 |
+
Transition_Transition.UNMOUNTED = UNMOUNTED;
|
1135 |
+
Transition_Transition.EXITED = EXITED;
|
1136 |
+
Transition_Transition.ENTERING = ENTERING;
|
1137 |
+
Transition_Transition.ENTERED = ENTERED;
|
1138 |
+
Transition_Transition.EXITING = EXITING;
|
1139 |
+
/* harmony default export */ var esm_Transition = __webpack_exports__["a"] = (Transition_Transition);
|
1140 |
+
|
1141 |
+
/***/ })
|
1142 |
+
|
1143 |
+
}]);
|
trunk/dist/chunks/2.min.js
ADDED
@@ -0,0 +1 @@
|
|
|
1 |
+
(window.__wcAdmin_webpackJsonp=window.__wcAdmin_webpackJsonp||[]).push([[2],{169:function(e,t,n){"use strict";var i=n(23),s=n(22),r=n(25);n(1);function a(e,t){return e.replace(new RegExp("(^|\\s)"+t+"(?:\\s|$)","g"),"$1").replace(/\s+/g," ").replace(/^\s*|\s*$/g,"")}var o=n(5),l=n.n(o),c=n(67),u=function(e,t){return e&&t&&t.split(" ").forEach((function(t){return i=t,void((n=e).classList?n.classList.remove(i):"string"==typeof n.className?n.className=a(n.className,i):n.setAttribute("class",a(n.className&&n.className.baseVal||"",i)));var n,i}))},p=function(e){function t(){for(var t,n=arguments.length,i=new Array(n),s=0;s<n;s++)i[s]=arguments[s];return(t=e.call.apply(e,[this].concat(i))||this).appliedClasses={appear:{},enter:{},exit:{}},t.onEnter=function(e,n){var i=t.resolveArguments(e,n),s=i[0],r=i[1];t.removeClasses(s,"exit"),t.addClass(s,r?"appear":"enter","base"),t.props.onEnter&&t.props.onEnter(e,n)},t.onEntering=function(e,n){var i=t.resolveArguments(e,n),s=i[0],r=i[1]?"appear":"enter";t.addClass(s,r,"active"),t.props.onEntering&&t.props.onEntering(e,n)},t.onEntered=function(e,n){var i=t.resolveArguments(e,n),s=i[0],r=i[1]?"appear":"enter";t.removeClasses(s,r),t.addClass(s,r,"done"),t.props.onEntered&&t.props.onEntered(e,n)},t.onExit=function(e){var n=t.resolveArguments(e)[0];t.removeClasses(n,"appear"),t.removeClasses(n,"enter"),t.addClass(n,"exit","base"),t.props.onExit&&t.props.onExit(e)},t.onExiting=function(e){var n=t.resolveArguments(e)[0];t.addClass(n,"exit","active"),t.props.onExiting&&t.props.onExiting(e)},t.onExited=function(e){var n=t.resolveArguments(e)[0];t.removeClasses(n,"exit"),t.addClass(n,"exit","done"),t.props.onExited&&t.props.onExited(e)},t.resolveArguments=function(e,n){return t.props.nodeRef?[t.props.nodeRef.current,e]:[e,n]},t.getClassNames=function(e){var n=t.props.classNames,i="string"==typeof n,s=i?""+(i&&n?n+"-":"")+e:n[e];return{baseClassName:s,activeClassName:i?s+"-active":n[e+"Active"],doneClassName:i?s+"-done":n[e+"Done"]}},t}Object(r.a)(t,e);var n=t.prototype;return n.addClass=function(e,t,n){var i=this.getClassNames(t)[n+"ClassName"],s=this.getClassNames("enter").doneClassName;"appear"===t&&"done"===n&&s&&(i+=" "+s),"active"===n&&e&&e.scrollTop,i&&(this.appliedClasses[t][n]=i,function(e,t){e&&t&&t.split(" ").forEach((function(t){return i=t,void((n=e).classList?n.classList.add(i):function(e,t){return e.classList?!!t&&e.classList.contains(t):-1!==(" "+(e.className.baseVal||e.className)+" ").indexOf(" "+t+" ")}(n,i)||("string"==typeof n.className?n.className=n.className+" "+i:n.setAttribute("class",(n.className&&n.className.baseVal||"")+" "+i)));var n,i}))}(e,i))},n.removeClasses=function(e,t){var n=this.appliedClasses[t],i=n.base,s=n.active,r=n.done;this.appliedClasses[t]={},i&&u(e,i),s&&u(e,s),r&&u(e,r)},n.render=function(){var e=this.props,t=(e.classNames,Object(s.a)(e,["classNames"]));return l.a.createElement(c.a,Object(i.a)({},t,{onEnter:this.onEnter,onEntered:this.onEntered,onEntering:this.onEntering,onExit:this.onExit,onExiting:this.onExiting,onExited:this.onExited}))},t}(l.a.Component);p.defaultProps={classNames:""},p.propTypes={};t.a=p},173:function(e,t,n){"use strict";var i=n(22),s=n(23);var r=n(25),a=(n(1),n(5)),o=n.n(a),l=n(33);function c(e,t){var n=Object.create(null);return e&&a.Children.map(e,(function(e){return e})).forEach((function(e){n[e.key]=function(e){return t&&Object(a.isValidElement)(e)?t(e):e}(e)})),n}function u(e,t,n){return null!=n[t]?n[t]:e.props[t]}function p(e,t,n){var i=c(e.children),s=function(e,t){function n(n){return n in t?t[n]:e[n]}e=e||{},t=t||{};var i,s=Object.create(null),r=[];for(var a in e)a in t?r.length&&(s[a]=r,r=[]):r.push(a);var o={};for(var l in t){if(s[l])for(i=0;i<s[l].length;i++){var c=s[l][i];o[s[l][i]]=n(c)}o[l]=n(l)}for(i=0;i<r.length;i++)o[r[i]]=n(r[i]);return o}(t,i);return Object.keys(s).forEach((function(r){var o=s[r];if(Object(a.isValidElement)(o)){var l=r in t,c=r in i,p=t[r],d=Object(a.isValidElement)(p)&&!p.props.in;!c||l&&!d?c||!l||d?c&&l&&Object(a.isValidElement)(p)&&(s[r]=Object(a.cloneElement)(o,{onExited:n.bind(null,o),in:p.props.in,exit:u(o,"exit",e),enter:u(o,"enter",e)})):s[r]=Object(a.cloneElement)(o,{in:!1}):s[r]=Object(a.cloneElement)(o,{onExited:n.bind(null,o),in:!0,exit:u(o,"exit",e),enter:u(o,"enter",e)})}})),s}var d=Object.values||function(e){return Object.keys(e).map((function(t){return e[t]}))},f=function(e){function t(t,n){var i,s=(i=e.call(this,t,n)||this).handleExited.bind(function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(i));return i.state={contextValue:{isMounting:!0},handleExited:s,firstRender:!0},i}Object(r.a)(t,e);var n=t.prototype;return n.componentDidMount=function(){this.mounted=!0,this.setState({contextValue:{isMounting:!1}})},n.componentWillUnmount=function(){this.mounted=!1},t.getDerivedStateFromProps=function(e,t){var n,i,s=t.children,r=t.handleExited;return{children:t.firstRender?(n=e,i=r,c(n.children,(function(e){return Object(a.cloneElement)(e,{onExited:i.bind(null,e),in:!0,appear:u(e,"appear",n),enter:u(e,"enter",n),exit:u(e,"exit",n)})}))):p(e,s,r),firstRender:!1}},n.handleExited=function(e,t){var n=c(this.props.children);e.key in n||(e.props.onExited&&e.props.onExited(t),this.mounted&&this.setState((function(t){var n=Object(s.a)({},t.children);return delete n[e.key],{children:n}})))},n.render=function(){var e=this.props,t=e.component,n=e.childFactory,s=Object(i.a)(e,["component","childFactory"]),r=this.state.contextValue,a=d(this.state.children).map(n);return delete s.appear,delete s.enter,delete s.exit,null===t?o.a.createElement(l.a.Provider,{value:r},a):o.a.createElement(l.a.Provider,{value:r},o.a.createElement(t,s,a))},t}(o.a.Component);f.propTypes={},f.defaultProps={component:"div",childFactory:function(e){return e}};t.a=f},33:function(e,t,n){"use strict";var i=n(5),s=n.n(i);t.a=s.a.createContext(null)},67:function(e,t,n){"use strict";var i=n(22),s=n(25),r=(n(1),n(5)),a=n.n(r),o=n(30),l=n.n(o),c=!1,u=n(33),p=function(e){function t(t,n){var i;i=e.call(this,t,n)||this;var s,r=n&&!n.isMounting?t.enter:t.appear;return i.appearStatus=null,t.in?r?(s="exited",i.appearStatus="entering"):s="entered":s=t.unmountOnExit||t.mountOnEnter?"unmounted":"exited",i.state={status:s},i.nextCallback=null,i}Object(s.a)(t,e),t.getDerivedStateFromProps=function(e,t){return e.in&&"unmounted"===t.status?{status:"exited"}:null};var n=t.prototype;return n.componentDidMount=function(){this.updateStatus(!0,this.appearStatus)},n.componentDidUpdate=function(e){var t=null;if(e!==this.props){var n=this.state.status;this.props.in?"entering"!==n&&"entered"!==n&&(t="entering"):"entering"!==n&&"entered"!==n||(t="exiting")}this.updateStatus(!1,t)},n.componentWillUnmount=function(){this.cancelNextCallback()},n.getTimeouts=function(){var e,t,n,i=this.props.timeout;return e=t=n=i,null!=i&&"number"!=typeof i&&(e=i.exit,t=i.enter,n=void 0!==i.appear?i.appear:t),{exit:e,enter:t,appear:n}},n.updateStatus=function(e,t){void 0===e&&(e=!1),null!==t?(this.cancelNextCallback(),"entering"===t?this.performEnter(e):this.performExit()):this.props.unmountOnExit&&"exited"===this.state.status&&this.setState({status:"unmounted"})},n.performEnter=function(e){var t=this,n=this.props.enter,i=this.context?this.context.isMounting:e,s=this.props.nodeRef?[i]:[l.a.findDOMNode(this),i],r=s[0],a=s[1],o=this.getTimeouts(),u=i?o.appear:o.enter;!e&&!n||c?this.safeSetState({status:"entered"},(function(){t.props.onEntered(r)})):(this.props.onEnter(r,a),this.safeSetState({status:"entering"},(function(){t.props.onEntering(r,a),t.onTransitionEnd(u,(function(){t.safeSetState({status:"entered"},(function(){t.props.onEntered(r,a)}))}))})))},n.performExit=function(){var e=this,t=this.props.exit,n=this.getTimeouts(),i=this.props.nodeRef?void 0:l.a.findDOMNode(this);t&&!c?(this.props.onExit(i),this.safeSetState({status:"exiting"},(function(){e.props.onExiting(i),e.onTransitionEnd(n.exit,(function(){e.safeSetState({status:"exited"},(function(){e.props.onExited(i)}))}))}))):this.safeSetState({status:"exited"},(function(){e.props.onExited(i)}))},n.cancelNextCallback=function(){null!==this.nextCallback&&(this.nextCallback.cancel(),this.nextCallback=null)},n.safeSetState=function(e,t){t=this.setNextCallback(t),this.setState(e,t)},n.setNextCallback=function(e){var t=this,n=!0;return this.nextCallback=function(i){n&&(n=!1,t.nextCallback=null,e(i))},this.nextCallback.cancel=function(){n=!1},this.nextCallback},n.onTransitionEnd=function(e,t){this.setNextCallback(t);var n=this.props.nodeRef?this.props.nodeRef.current:l.a.findDOMNode(this),i=null==e&&!this.props.addEndListener;if(n&&!i){if(this.props.addEndListener){var s=this.props.nodeRef?[this.nextCallback]:[n,this.nextCallback],r=s[0],a=s[1];this.props.addEndListener(r,a)}null!=e&&setTimeout(this.nextCallback,e)}else setTimeout(this.nextCallback,0)},n.render=function(){var e=this.state.status;if("unmounted"===e)return null;var t=this.props,n=t.children,s=(t.in,t.mountOnEnter,t.unmountOnExit,t.appear,t.enter,t.exit,t.timeout,t.addEndListener,t.onEnter,t.onEntering,t.onEntered,t.onExit,t.onExiting,t.onExited,t.nodeRef,Object(i.a)(t,["children","in","mountOnEnter","unmountOnExit","appear
|